import{i as $,r as rn,m as G,a as O,c as Z,e as w,b as j,d as ye,f as gt,g as ic,h as ct,j as kt,k as hb,l as B,n as X,L as Pm,P as It,o as pn,p as Wt,q as oc,s as pb,t as St,u as db,v as gb,w as yb,x as dv,y as is,T as qa,z as zi,A as Le,B as J,Z as ke,C as U,D as mb,E as Sb,F as ur,G as Em,S as Pe,R as Hs,H as Ee,I as me,J as ht,K as te,M as Ws,N as gv,O as xb,Q as wt,U as Rm,V as tt,W as _b,X as $s,Y as os,_ as Gt,$ as bb,a0 as ut,a1 as Gi,a2 as ot,a3 as K,a4 as jt,a5 as km,a6 as ge,a7 as Q,a8 as Re,a9 as bt,aa as W,ab as ss,ac as ls,ad as he,ae as sc,af as wb,ag as us,ah as Ab,ai as dn,aj as nh,ak as xl,al as Tb,am as Cb,an,ao as cs,ap as aa,aq as Nm,ar as Om,as as Us,at as oa,au as _l,av as Db,aw as Mb,ax as Vm,ay as sa,az as Ib,aA as Lb,aB as ih,aC as oh,aD as Pb,aE as gn,aF as Jt,aG as Fi,aH as Eb,aI as sh,aJ as Nr,aK as Rb,aL as kb,aM as Nb,aN as Sa,aO as Ob,aP as yn,aQ as ce,aR as yv,aS as Bm,aT as xa,aU as Vb,aV as bl,aW as Yo,aX as zm,aY as si,aZ as vs,a_ as Pr,a$ as Hi,b0 as Bb,b1 as zb,b2 as ja,b3 as lh,b4 as Gb,b5 as lc,b6 as Fb,b7 as Gm,b8 as Hb,b9 as Wb,ba as $b,bb as Ub,bc as uh,bd as Yb,be as mi,bf as Zb,bg as Fm,bh as ch,bi as Xb,bj as Kb,bk as qb,bl as jb,bm as Jb,bn as Qb,bo as tw,bp as ew}from"./zrender-bd06e061.js";/*! *****************************************************************************
Copyright (c) Microsoft Corporation.

Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */var uc=function(r,e){return uc=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,a){t.__proto__=a}||function(t,a){for(var n in a)Object.prototype.hasOwnProperty.call(a,n)&&(t[n]=a[n])},uc(r,e)};function R(r,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");uc(r,e);function t(){this.constructor=r}r.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var vh=1e-4,Hm=20;function rw(r){return r.replace(/^\s+|\s+$/g,"")}function mt(r,e,t,a){var n=e[0],i=e[1],o=t[0],s=t[1],l=i-n,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(a)if(l>0){if(r<=n)return o;if(r>=i)return s}else{if(r>=n)return o;if(r<=i)return s}else{if(r===n)return o;if(r===i)return s}return(r-n)/l*u+o}function F(r,e){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return $(r)?rw(r).match(/%$/)?parseFloat(r)/100*e:parseFloat(r):r==null?NaN:+r}function Vt(r,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),Hm),r=(+r).toFixed(e),t?r:+r}function Me(r){return r.sort(function(e,t){return e-t}),r}function Ke(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(Math.round(r*e)/e===r)return t}return aw(r)}function aw(r){var e=r.toString().toLowerCase(),t=e.indexOf("e"),a=t>0?+e.slice(t+1):0,n=t>0?t:e.length,i=e.indexOf("."),o=i<0?0:n-1-i;return Math.max(0,o-a)}function Wm(r,e){var t=Math.log,a=Math.LN10,n=Math.floor(t(r[1]-r[0])/a),i=Math.round(t(Math.abs(e[1]-e[0]))/a),o=Math.min(Math.max(-n+i,0),20);return isFinite(o)?o:20}function nw(r,e){var t=rn(r,function(h,p){return h+(isNaN(p)?0:p)},0);if(t===0)return[];for(var a=Math.pow(10,e),n=G(r,function(h){return(isNaN(h)?0:h)/t*a*100}),i=a*100,o=G(n,function(h){return Math.floor(h)}),s=rn(o,function(h,p){return h+p},0),l=G(n,function(h,p){return h-o[p]});s<i;){for(var u=Number.NEGATIVE_INFINITY,c=null,v=0,f=l.length;v<f;++v)l[v]>u&&(u=l[v],c=v);++o[c],l[c]=0,++s}return G(o,function(h){return h/a})}function iw(r,e){var t=Math.max(Ke(r),Ke(e)),a=r+e;return t>Hm?a:Vt(a,t)}var fh=9007199254740991;function $m(r){var e=Math.PI*2;return(r%e+e)%e}function fs(r){return r>-vh&&r<vh}var ow=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function tr(r){if(r instanceof Date)return r;if($(r)){var e=ow.exec(r);if(!e)return new Date(NaN);if(e[8]){var t=+e[4]||0;return e[8].toUpperCase()!=="Z"&&(t-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,t,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))}else return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0)}else if(r==null)return new Date(NaN);return new Date(Math.round(r))}function sw(r){return Math.pow(10,mv(r))}function mv(r){if(r===0)return 0;var e=Math.floor(Math.log(r)/Math.LN10);return r/Math.pow(10,e)>=10&&e++,e}function Um(r,e){var t=mv(r),a=Math.pow(10,t),n=r/a,i;return e?n<1.5?i=1:n<2.5?i=2:n<4?i=3:n<7?i=5:i=10:n<1?i=1:n<2?i=2:n<3?i=3:n<5?i=5:i=10,r=i*a,t>=-20?+r.toFixed(t<0?-t:0):r}function wl(r,e){var t=(r.length-1)*e+1,a=Math.floor(t),n=+r[a-1],i=t-a;return i?n+i*(r[a]-n):n}function hh(r){r.sort(function(l,u){return s(l,u,0)?-1:1});for(var e=-1/0,t=1,a=0;a<r.length;){for(var n=r[a].interval,i=r[a].close,o=0;o<2;o++)n[o]<=e&&(n[o]=e,i[o]=o?1:1-t),e=n[o],t=i[o];n[0]===n[1]&&i[0]*i[1]!==1?r.splice(a,1):a++}return r;function s(l,u,c){return l.interval[c]<u.interval[c]||l.interval[c]===u.interval[c]&&(l.close[c]-u.close[c]===(c?-1:1)||!c&&s(l,u,1))}}function cr(r){var e=parseFloat(r);return e==r&&(e!==0||!$(r)||r.indexOf("x")<=0)?e:NaN}function Ym(r){return!isNaN(cr(r))}function Zm(){return Math.round(Math.random()*9)}function Xm(r,e){return e===0?r:Xm(e,r%e)}function ph(r,e){return r==null?e:e==null?r:r*e/Xm(r,e)}function dt(r){throw new Error(r)}function dh(r,e,t){return(e-r)*t+r}var Km="series\0",qm="\0_ec_\0";function _t(r){return r instanceof Array?r:r==null?[]:[r]}function _a(r,e,t){if(r){r[e]=r[e]||{},r.emphasis=r.emphasis||{},r.emphasis[e]=r.emphasis[e]||{};for(var a=0,n=t.length;a<n;a++){var i=t[a];!r.emphasis[e].hasOwnProperty(i)&&r[e].hasOwnProperty(i)&&(r.emphasis[e][i]=r[e][i])}}}var gh=["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 mn(r){return j(r)&&!O(r)&&!(r instanceof Date)?r.value:r}function lw(r){return j(r)&&!(r instanceof Array)}function jm(r,e,t){var a=t==="normalMerge",n=t==="replaceMerge",i=t==="replaceAll";r=r||[],e=(e||[]).slice();var o=Z();w(e,function(l,u){if(!j(l)){e[u]=null;return}});var s=uw(r,o,t);return(a||n)&&cw(s,r,o,e),a&&vw(s,e),a||n?fw(s,e,n):i&&hw(s,e),pw(s),s}function uw(r,e,t){var a=[];if(t==="replaceAll")return a;for(var n=0;n<r.length;n++){var i=r[n];i&&i.id!=null&&e.set(i.id,n),a.push({existing:t==="replaceMerge"||Si(i)?null:i,newOption:null,keyInfo:null,brandNew:null})}return a}function cw(r,e,t,a){w(a,function(n,i){if(!(!n||n.id==null)){var o=li(n.id),s=t.get(o);if(s!=null){var l=r[s];ye(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=n,l.existing=e[s],a[i]=null}}})}function vw(r,e){w(e,function(t,a){if(!(!t||t.name==null))for(var n=0;n<r.length;n++){var i=r[n].existing;if(!r[n].newOption&&i&&(i.id==null||t.id==null)&&!Si(t)&&!Si(i)&&Jm("name",i,t)){r[n].newOption=t,e[a]=null;return}}})}function fw(r,e,t){w(e,function(a){if(a){for(var n,i=0;(n=r[i])&&(n.newOption||Si(n.existing)||n.existing&&a.id!=null&&!Jm("id",a,n.existing));)i++;n?(n.newOption=a,n.brandNew=t):r.push({newOption:a,brandNew:t,existing:null,keyInfo:null}),i++}})}function hw(r,e){w(e,function(t){r.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function pw(r){var e=Z();w(r,function(t){var a=t.existing;a&&e.set(a.id,t)}),w(r,function(t){var a=t.newOption;ye(!a||a.id==null||!e.get(a.id)||e.get(a.id)===t,"id duplicates: "+(a&&a.id)),a&&a.id!=null&&e.set(a.id,t),!t.keyInfo&&(t.keyInfo={})}),w(r,function(t,a){var n=t.existing,i=t.newOption,o=t.keyInfo;if(j(i)){if(o.name=i.name!=null?li(i.name):n?n.name:Km+a,n)o.id=li(n.id);else if(i.id!=null)o.id=li(i.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(e.get(o.id))}e.set(o.id,t)}})}function Jm(r,e,t){var a=Ut(e[r],null),n=Ut(t[r],null);return a!=null&&n!=null&&a===n}function li(r){return Ut(r,"")}function Ut(r,e){return r==null?e:$(r)?r:gt(r)||ic(r)?r+"":e}function Sv(r){var e=r.name;return!!(e&&e.indexOf(Km))}function Si(r){return r&&r.id!=null&&li(r.id).indexOf(qm)===0}function dw(r){return qm+r}function gw(r,e,t){w(r,function(a){var n=a.newOption;j(n)&&(a.keyInfo.mainType=e,a.keyInfo.subType=yw(e,n,a.existing,t))})}function yw(r,e,t,a){var n=e.type?e.type:t?t.subType:a.determineSubType(r,e);return n}function mw(r,e){var t={},a={};return n(r||[],t),n(e||[],a,t),[i(t),i(a)];function n(o,s,l){for(var u=0,c=o.length;u<c;u++){var v=Ut(o[u].seriesId,null);if(v==null)return;for(var f=_t(o[u].dataIndex),h=l&&l[v],p=0,d=f.length;p<d;p++){var g=f[p];h&&h[g]?h[g]=null:(s[v]||(s[v]={}))[g]=1}}}function i(o,s){var l=[];for(var u in o)if(o.hasOwnProperty(u)&&o[u]!=null)if(s)l.push(+u);else{var c=i(o[u],!0);c.length&&l.push({seriesId:u,dataIndex:c})}return l}}function ba(r,e){if(e.dataIndexInside!=null)return e.dataIndexInside;if(e.dataIndex!=null)return O(e.dataIndex)?G(e.dataIndex,function(t){return r.indexOfRawIndex(t)}):r.indexOfRawIndex(e.dataIndex);if(e.name!=null)return O(e.name)?G(e.name,function(t){return r.indexOfName(t)}):r.indexOfName(e.name)}function st(){var r="__ec_inner_"+Sw++;return function(e){return e[r]||(e[r]={})}}var Sw=Zm();function ui(r,e,t){var a=xv(e,t),n=a.mainTypeSpecified,i=a.queryOptionMap,o=a.others,s=o,l=t?t.defaultMainType:null;return!n&&l&&i.set(l,{}),i.each(function(u,c){var v=Wi(r,c,u,{useDefault:l===c,enableAll:t&&t.enableAll!=null?t.enableAll:!0,enableNone:t&&t.enableNone!=null?t.enableNone:!0});s[c+"Models"]=v.models,s[c+"Model"]=v.models[0]}),s}function xv(r,e){var t;if($(r)){var a={};a[r+"Index"]=0,t=a}else t=r;var n=Z(),i={},o=!1;return w(t,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){i[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],c=u[1],v=(u[2]||"").toLowerCase();if(!(!c||!v||e&&e.includeMainTypes&&ct(e.includeMainTypes,c)<0)){o=o||!!c;var f=n.get(c)||n.set(c,{});f[v]=s}}),{mainTypeSpecified:o,queryOptionMap:n,others:i}}var Ft={useDefault:!0,enableAll:!1,enableNone:!1},xw={useDefault:!1,enableAll:!0,enableNone:!0};function Wi(r,e,t,a){a=a||Ft;var n=t.index,i=t.id,o=t.name,s={models:null,specified:n!=null||i!=null||o!=null};if(!s.specified){var l=void 0;return s.models=a.useDefault&&(l=r.getComponent(e))?[l]:[],s}return n==="none"||n===!1?(ye(a.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[],s):(n==="all"&&(ye(a.enableAll,'`"all"` is not a valid value on index option.'),n=i=o=null),s.models=r.queryComponents({mainType:e,index:n,id:i,name:o}),s)}function Qm(r,e,t){r.setAttribute?r.setAttribute(e,t):r[e]=t}function _w(r,e){return r.getAttribute?r.getAttribute(e):r[e]}function bw(r){return r==="auto"?kt.domSupported?"html":"richText":r||"html"}function cc(r,e){var t=Z(),a=[];return w(r,function(n){var i=e(n);(t.get(i)||(a.push(i),t.set(i,[]))).push(n)}),{keys:a,buckets:t}}function t0(r,e,t,a,n){var i=e==null||e==="auto";if(a==null)return a;if(gt(a)){var o=dh(t||0,a,n);return Vt(o,i?Math.max(Ke(t||0),Ke(a)):e)}else{if($(a))return n<1?t:a;for(var s=[],l=t,u=a,c=Math.max(l?l.length:0,u.length),v=0;v<c;++v){var f=r.getDimensionInfo(v);if(f&&f.type==="ordinal")s[v]=(n<1&&l?l:u)[v];else{var h=l&&l[v]?l[v]:0,p=u[v],o=dh(h,p,n);s[v]=Vt(o,i?Math.max(Ke(h),Ke(p)):e)}}return s}}var ww=".",Ur="___EC__COMPONENT__CONTAINER___",e0="___EC__EXTENDED_CLASS___";function qe(r){var e={main:"",sub:""};if(r){var t=r.split(ww);e.main=t[0]||"",e.sub=t[1]||""}return e}function Aw(r){ye(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function Tw(r){return!!(r&&r[e0])}function _v(r,e){r.$constructor=r,r.extend=function(t){var a=this,n;return Cw(a)?n=function(i){R(o,i);function o(){return i.apply(this,arguments)||this}return o}(a):(n=function(){(t.$constructor||a).apply(this,arguments)},hb(n,this)),B(n.prototype,t),n[e0]=!0,n.extend=this.extend,n.superCall=Iw,n.superApply=Lw,n.superClass=a,n}}function Cw(r){return X(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function r0(r,e){r.extend=e.extend}var Dw=Math.round(Math.random()*10);function Mw(r){var e=["__\0is_clz",Dw++].join("_");r.prototype[e]=!0,r.isInstance=function(t){return!!(t&&t[e])}}function Iw(r,e){for(var t=[],a=2;a<arguments.length;a++)t[a-2]=arguments[a];return this.superClass.prototype[e].apply(r,t)}function Lw(r,e,t){return this.superClass.prototype[e].apply(r,t)}function Ys(r){var e={};r.registerClass=function(a){var n=a.type||a.prototype.type;if(n){Aw(n),a.prototype.type=n;var i=qe(n);if(!i.sub)e[i.main]=a;else if(i.sub!==Ur){var o=t(i);o[i.sub]=a}}return a},r.getClass=function(a,n,i){var o=e[a];if(o&&o[Ur]&&(o=n?o[n]:null),i&&!o)throw new Error(n?"Component "+a+"."+(n||"")+" is used but not imported.":a+".type should be specified.");return o},r.getClassesByMainType=function(a){var n=qe(a),i=[],o=e[n.main];return o&&o[Ur]?w(o,function(s,l){l!==Ur&&i.push(s)}):i.push(o),i},r.hasClass=function(a){var n=qe(a);return!!e[n.main]},r.getAllClassMainTypes=function(){var a=[];return w(e,function(n,i){a.push(i)}),a},r.hasSubTypes=function(a){var n=qe(a),i=e[n.main];return i&&i[Ur]};function t(a){var n=e[a.main];return(!n||!n[Ur])&&(n=e[a.main]={},n[Ur]=!0),n}}function wa(r,e){for(var t=0;t<r.length;t++)r[t][1]||(r[t][1]=r[t][0]);return e=e||!1,function(a,n,i){for(var o={},s=0;s<r.length;s++){var l=r[s][1];if(!(n&&ct(n,l)>=0||i&&ct(i,l)<0)){var u=a.getShallow(l,e);u!=null&&(o[r[s][0]]=u)}}return o}}var Pw=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Ew=wa(Pw),Rw=function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return Ew(this,e,t)},r}(),q=st(),vc=function(r,e,t,a){if(a){var n=q(a);n.dataIndex=t,n.dataType=e,n.seriesIndex=r,a.type==="group"&&a.traverse(function(i){var o=q(i);o.seriesIndex=r,o.dataIndex=t,o.dataType=e})}},yh=1,mh={},a0=st(),bv=st(),wv=0,$i=1,Zs=2,pe=["emphasis","blur","select"],xi=["normal","emphasis","blur","select"],Sn=10,kw=9,fa="highlight",Zo="downplay",ci="select",Xo="unselect",vi="toggleSelect";function ka(r){return r!=null&&r!=="none"}var Sh=new Pm(100);function xh(r){if($(r)){var e=Sh.get(r);return e||(e=oc(r,-.1),Sh.put(r,e)),e}else if(pb(r)){var t=B({},r);return t.colorStops=G(r.colorStops,function(a){return{offset:a.offset,color:oc(a.color,-.1)}}),t}return r}function Xs(r,e,t){r.onHoverStateChange&&(r.hoverState||0)!==t&&r.onHoverStateChange(e),r.hoverState=t}function n0(r){Xs(r,"emphasis",Zs)}function i0(r){r.hoverState===Zs&&Xs(r,"normal",wv)}function Av(r){Xs(r,"blur",$i)}function o0(r){r.hoverState===$i&&Xs(r,"normal",wv)}function Nw(r){r.selected=!0}function Ow(r){r.selected=!1}function _h(r,e,t){e(r,t)}function gr(r,e,t){_h(r,e,t),r.isGroup&&r.traverse(function(a){_h(a,e,t)})}function hs(r,e){switch(e){case"emphasis":r.hoverState=Zs;break;case"normal":r.hoverState=wv;break;case"blur":r.hoverState=$i;break;case"select":r.selected=!0}}function Vw(r,e,t,a){for(var n=r.style,i={},o=0;o<e.length;o++){var s=e[o],l=n[s];i[s]=l??(a&&a[s])}for(var o=0;o<r.animators.length;o++){var u=r.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(t)<0&&u.targetName==="style"&&u.saveTo(i,e)}return i}function Bw(r,e,t,a){var n=t&&ct(t,"select")>=0,i=!1;if(r instanceof It){var o=a0(r),s=n&&o.selectFill||o.normalFill,l=n&&o.selectStroke||o.normalStroke;if(ka(s)||ka(l)){a=a||{};var u=a.style||{};u.fill==="inherit"?(i=!0,a=B({},a),u=B({},u),u.fill=s):!ka(u.fill)&&ka(s)?(i=!0,a=B({},a),u=B({},u),u.fill=xh(s)):!ka(u.stroke)&&ka(l)&&(i||(a=B({},a),u=B({},u)),u.stroke=xh(l)),a.style=u}}if(a&&a.z2==null){i||(a=B({},a));var c=r.z2EmphasisLift;a.z2=r.z2+(c??Sn)}return a}function zw(r,e,t){if(t&&t.z2==null){t=B({},t);var a=r.z2SelectLift;t.z2=r.z2+(a??kw)}return t}function Gw(r,e,t){var a=ct(r.currentStates,e)>=0,n=r.style.opacity,i=a?null:Vw(r,["opacity"],e,{opacity:1});t=t||{};var o=t.style||{};return o.opacity==null&&(t=B({},t),o=B({opacity:a?n:i.opacity*.1},o),t.style=o),t}function Al(r,e){var t=this.states[r];if(this.style){if(r==="emphasis")return Bw(this,r,e,t);if(r==="blur")return Gw(this,r,t);if(r==="select")return zw(this,r,t)}return t}function Aa(r){r.stateProxy=Al;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=Al),t&&(t.stateProxy=Al)}function bh(r,e){!c0(r,e)&&!r.__highByOuter&&gr(r,n0)}function wh(r,e){!c0(r,e)&&!r.__highByOuter&&gr(r,i0)}function vr(r,e){r.__highByOuter|=1<<(e||0),gr(r,n0)}function fr(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&gr(r,i0)}function s0(r){gr(r,Av)}function Tv(r){gr(r,o0)}function l0(r){gr(r,Nw)}function u0(r){gr(r,Ow)}function c0(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function v0(r){var e=r.getModel(),t=[],a=[];e.eachComponent(function(n,i){var o=bv(i),s=n==="series",l=s?r.getViewOfSeriesModel(i):r.getViewOfComponentModel(i);!s&&a.push(l),o.isBlured&&(l.group.traverse(function(u){o0(u)}),s&&t.push(i)),o.isBlured=!1}),w(a,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(t,!1,e)})}function fc(r,e,t,a){var n=a.getModel();t=t||"coordinateSystem";function i(u,c){for(var v=0;v<c.length;v++){var f=u.getItemGraphicEl(c[v]);f&&Tv(f)}}if(r!=null&&!(!e||e==="none")){var o=n.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];n.eachSeries(function(u){var c=o===u,v=u.coordinateSystem;v&&v.master&&(v=v.master);var f=v&&s?v===s:c;if(!(t==="series"&&!c||t==="coordinateSystem"&&!f||e==="series"&&c)){var h=a.getViewOfSeriesModel(u);if(h.group.traverse(function(g){g.__highByOuter&&c&&e==="self"||Av(g)}),pn(e))i(u.getData(),e);else if(j(e))for(var p=Wt(e),d=0;d<p.length;d++)i(u.getData(p[d]),e[p[d]]);l.push(u),bv(u).isBlured=!0}}),n.eachComponent(function(u,c){if(u!=="series"){var v=a.getViewOfComponentModel(c);v&&v.toggleBlurSeries&&v.toggleBlurSeries(l,!0,n)}})}}function hc(r,e,t){if(!(r==null||e==null)){var a=t.getModel().getComponent(r,e);if(a){bv(a).isBlured=!0;var n=t.getViewOfComponentModel(a);!n||!n.focusBlurEnabled||n.group.traverse(function(i){Av(i)})}}}function Fw(r,e,t){var a=r.seriesIndex,n=r.getData(e.dataType);if(n){var i=ba(n,e);i=(O(i)?i[0]:i)||0;var o=n.getItemGraphicEl(i);if(!o)for(var s=n.count(),l=0;!o&&l<s;)o=n.getItemGraphicEl(l++);if(o){var u=q(o);fc(a,u.focus,u.blurScope,t)}else{var c=r.get(["emphasis","focus"]),v=r.get(["emphasis","blurScope"]);c!=null&&fc(a,c,v,t)}}}function Cv(r,e,t,a){var n={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||e==null||t==null)return n;var i=a.getModel().getComponent(r,e);if(!i)return n;var o=a.getViewOfComponentModel(i);if(!o||!o.findHighDownDispatchers)return n;for(var s=o.findHighDownDispatchers(t),l,u=0;u<s.length;u++)if(q(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function Hw(r,e,t){var a=q(r),n=Cv(a.componentMainType,a.componentIndex,a.componentHighDownName,t),i=n.dispatchers,o=n.focusSelf;i?(o&&hc(a.componentMainType,a.componentIndex,t),w(i,function(s){return bh(s,e)})):(fc(a.seriesIndex,a.focus,a.blurScope,t),a.focus==="self"&&hc(a.componentMainType,a.componentIndex,t),bh(r,e))}function Ww(r,e,t){v0(t);var a=q(r),n=Cv(a.componentMainType,a.componentIndex,a.componentHighDownName,t).dispatchers;n?w(n,function(i){return wh(i,e)}):wh(r,e)}function $w(r,e,t){if(dc(e)){var a=e.dataType,n=r.getData(a),i=ba(n,e);O(i)||(i=[i]),r[e.type===vi?"toggleSelect":e.type===ci?"select":"unselect"](i,a)}}function Ah(r){var e=r.getAllData();w(e,function(t){var a=t.data,n=t.type;a.eachItemGraphicEl(function(i,o){r.isSelected(o,n)?l0(i):u0(i)})})}function Uw(r){var e=[];return r.eachSeries(function(t){var a=t.getAllData();w(a,function(n){n.data;var i=n.type,o=t.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:t.seriesIndex};i!=null&&(s.dataType=i),e.push(s)}})}),e}function ha(r,e,t){la(r,!0),gr(r,Aa),pc(r,e,t)}function Yw(r){la(r,!1)}function Nt(r,e,t,a){a?Yw(r):ha(r,e,t)}function pc(r,e,t){var a=q(r);e!=null?(a.focus=e,a.blurScope=t):a.focus&&(a.focus=null)}var Th=["emphasis","blur","select"],Zw={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function re(r,e,t,a){t=t||"itemStyle";for(var n=0;n<Th.length;n++){var i=Th[n],o=e.getModel([i,t]),s=r.ensureState(i);s.style=a?a(o):o[Zw[t]]()}}function la(r,e){var t=e===!1,a=r;r.highDownSilentOnTouch&&(a.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!t||a.__highDownDispatcher)&&(a.__highByOuter=a.__highByOuter||0,a.__highDownDispatcher=!t)}function _i(r){return!!(r&&r.__highDownDispatcher)}function Xw(r,e,t){var a=q(r);a.componentMainType=e.mainType,a.componentIndex=e.componentIndex,a.componentHighDownName=t}function Kw(r){var e=mh[r];return e==null&&yh<=32&&(e=mh[r]=yh++),e}function dc(r){var e=r.type;return e===ci||e===Xo||e===vi}function Ch(r){var e=r.type;return e===fa||e===Zo}function qw(r){var e=a0(r);e.normalFill=r.style.fill,e.normalStroke=r.style.stroke;var t=r.states.select||{};e.selectFill=t.style&&t.style.fill||null,e.selectStroke=t.style&&t.style.stroke||null}var f0=st();function xn(r,e,t,a,n){var i;if(e&&e.ecModel){var o=e.ecModel.getUpdatePayload();i=o&&o.animation}var s=e&&e.isAnimationEnabled(),l=r==="update";if(s){var u=void 0,c=void 0,v=void 0;a?(u=St(a.duration,200),c=St(a.easing,"cubicOut"),v=0):(u=e.getShallow(l?"animationDurationUpdate":"animationDuration"),c=e.getShallow(l?"animationEasingUpdate":"animationEasing"),v=e.getShallow(l?"animationDelayUpdate":"animationDelay")),i&&(i.duration!=null&&(u=i.duration),i.easing!=null&&(c=i.easing),i.delay!=null&&(v=i.delay)),X(v)&&(v=v(t,n)),X(u)&&(u=u(t));var f={duration:u||0,delay:v,easing:c};return f}else return null}function Dv(r,e,t,a,n,i,o){var s=!1,l;X(n)?(o=i,i=n,n=null):j(n)&&(i=n.cb,o=n.during,s=n.isFrom,l=n.removeOpt,n=n.dataIndex);var u=r==="leave";u||e.stopAnimation("leave");var c=xn(r,a,n,u?l||{}:null,a&&a.getAnimationDelayParams?a.getAnimationDelayParams(e,n):null);if(c&&c.duration>0){var v=c.duration,f=c.delay,h=c.easing,p={duration:v,delay:f||0,easing:h,done:i,force:!!i||!!o,setToFinal:!u,scope:r,during:o};s?e.animateFrom(t,p):e.animateTo(t,p)}else e.stopAnimation(),!s&&e.attr(t),o&&o(1),i&&i()}function ft(r,e,t,a,n,i){Dv("update",r,e,t,a,n,i)}function Lt(r,e,t,a,n,i){Dv("enter",r,e,t,a,n,i)}function Ja(r){if(!r.__zr)return!0;for(var e=0;e<r.animators.length;e++){var t=r.animators[e];if(t.scope==="leave")return!0}return!1}function Or(r,e,t,a,n,i){Ja(r)||Dv("leave",r,e,t,a,n,i)}function Dh(r,e,t,a){r.removeTextContent(),r.removeTextGuideLine(),Or(r,{style:{opacity:0}},e,t,a)}function bi(r,e,t){function a(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(n){n.isGroup||Dh(n,e,t,a)}):Dh(r,e,t,a)}function We(r){f0(r).oldStyle=r.style}function jw(r){return f0(r).oldStyle}var ps=Math.max,ds=Math.min,gc={};function Jw(r){return It.extend(r)}var Qw=xb;function tA(r,e){return Qw(r,e)}function $e(r,e){gc[r]=e}function Mv(r){if(gc.hasOwnProperty(r))return gc[r]}function Ks(r,e,t,a){var n=mb(r,e);return t&&(a==="center"&&(t=p0(t,n.getBoundingRect())),d0(n,t)),n}function h0(r,e,t){var a=new ke({style:{image:r,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(n){if(t==="center"){var i={width:n.width,height:n.height};a.setStyle(p0(e,i))}}});return a}function p0(r,e){var t=e.width/e.height,a=r.height*t,n;a<=r.width?n=r.height:(a=r.width,n=a/t);var i=r.x+r.width/2,o=r.y+r.height/2;return{x:i-a/2,y:o-n/2,width:a,height:n}}var Ce=db;function d0(r,e){if(r.applyTransform){var t=r.getBoundingRect(),a=t.calculateTransform(e);r.applyTransform(a)}}function nn(r,e){return gb(r,r,{lineWidth:e}),r}function eA(r){return Sb(r.shape,r.shape,r.style),r}var Ko=yb;function pa(r,e){for(var t=dv([]);r&&r!==e;)is(t,r.getLocalTransform(),t),r=r.parent;return t}function He(r,e,t){return e&&!pn(e)&&(e=qa.getLocalTransform(e)),t&&(e=zi([],e)),Le([],r,e)}function qs(r,e,t){var a=e[4]===0||e[5]===0||e[0]===0?1:Math.abs(2*e[4]/e[0]),n=e[4]===0||e[5]===0||e[2]===0?1:Math.abs(2*e[4]/e[2]),i=[r==="left"?-a:r==="right"?a:0,r==="top"?-n:r==="bottom"?n:0];return i=He(i,e,t),Math.abs(i[0])>Math.abs(i[1])?i[0]>0?"right":"left":i[1]>0?"bottom":"top"}function Mh(r){return!r.isGroup}function rA(r){return r.shape!=null}function Ui(r,e,t){if(!r||!e)return;function a(o){var s={};return o.traverse(function(l){Mh(l)&&l.anid&&(s[l.anid]=l)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return rA(o)&&(s.shape=B({},o.shape)),s}var i=a(r);e.traverse(function(o){if(Mh(o)&&o.anid){var s=i[o.anid];if(s){var l=n(o);o.attr(n(s)),ft(o,l,t,q(o).dataIndex)}}})}function g0(r,e){return G(r,function(t){var a=t[0];a=ps(a,e.x),a=ds(a,e.x+e.width);var n=t[1];return n=ps(n,e.y),n=ds(n,e.y+e.height),[a,n]})}function aA(r,e){var t=ps(r.x,e.x),a=ds(r.x+r.width,e.x+e.width),n=ps(r.y,e.y),i=ds(r.y+r.height,e.y+e.height);if(a>=t&&i>=n)return{x:t,y:n,width:a-t,height:i-n}}function Yi(r,e,t){var a=B({rectHover:!0},e),n=a.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),J(n,t),new ke(a)):Ks(r.replace("path://",""),a,t,"center")}function ti(r,e,t,a,n){for(var i=0,o=n[n.length-1];i<n.length;i++){var s=n[i];if(y0(r,e,t,a,s[0],s[1],o[0],o[1]))return!0;o=s}}function y0(r,e,t,a,n,i,o,s){var l=t-r,u=a-e,c=o-n,v=s-i,f=Tl(c,v,l,u);if(nA(f))return!1;var h=r-n,p=e-i,d=Tl(h,p,l,u)/f;if(d<0||d>1)return!1;var g=Tl(h,p,c,v)/f;return!(g<0||g>1)}function Tl(r,e,t,a){return r*a-t*e}function nA(r){return r<=1e-6&&r>=-1e-6}function _n(r){var e=r.itemTooltipOption,t=r.componentModel,a=r.itemName,n=$(e)?{formatter:e}:e,i=t.mainType,o=t.componentIndex,s={componentType:i,name:a,$vars:["name"]};s[i+"Index"]=o;var l=r.formatterParamsExtra;l&&w(Wt(l),function(c){U(s,c)||(s[c]=l[c],s.$vars.push(c))});var u=q(r.el);u.componentMainType=i,u.componentIndex=o,u.tooltipConfig={name:a,option:J({content:a,formatterParams:s},n)}}function Ih(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function Wr(r,e){if(r)if(O(r))for(var t=0;t<r.length;t++)Ih(r[t],e);else Ih(r,e)}$e("circle",ur);$e("ellipse",Em);$e("sector",Pe);$e("ring",Hs);$e("polygon",Ee);$e("polyline",me);$e("rect",ht);$e("line",te);$e("bezierCurve",Ws);$e("arc",gv);const Zi=Object.freeze(Object.defineProperty({__proto__:null,Arc:gv,BezierCurve:Ws,BoundingRect:wt,Circle:ur,CompoundPath:Rm,Ellipse:Em,Group:tt,Image:ke,IncrementalDisplayable:_b,Line:te,LinearGradient:$s,OrientedBoundingRect:os,Path:It,Point:Gt,Polygon:Ee,Polyline:me,RadialGradient:bb,Rect:ht,Ring:Hs,Sector:Pe,Text:ut,applyTransform:He,clipPointsByRect:g0,clipRectByRect:aA,createIcon:Yi,extendPath:tA,extendShape:Jw,getShapeClass:Mv,getTransform:pa,groupTransition:Ui,initProps:Lt,isElementRemoved:Ja,lineLineIntersect:y0,linePolygonIntersect:ti,makeImage:h0,makePath:Ks,mergePath:Ce,registerShape:$e,removeElement:Or,removeElementWithFadeOut:bi,resizePath:d0,setTooltipConfig:_n,subPixelOptimize:Ko,subPixelOptimizeLine:nn,subPixelOptimizeRect:eA,transformDirection:qs,traverseElements:Wr,updateProps:ft},Symbol.toStringTag,{value:"Module"}));var js={};function m0(r,e){for(var t=0;t<pe.length;t++){var a=pe[t],n=e[a],i=r.ensureState(a);i.style=i.style||{},i.style.text=n}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:e.normal}),r.useStates(o,!0)}function yc(r,e,t){var a=r.labelFetcher,n=r.labelDataIndex,i=r.labelDimIndex,o=e.normal,s;a&&(s=a.getFormattedLabel(n,"normal",null,i,o&&o.get("formatter"),t!=null?{interpolatedValue:t}:null)),s==null&&(s=X(r.defaultText)?r.defaultText(n,r,t):r.defaultText);for(var l={normal:s},u=0;u<pe.length;u++){var c=pe[u],v=e[c];l[c]=St(a?a.getFormattedLabel(n,c,null,i,v&&v.get("formatter")):null,s)}return l}function ae(r,e,t,a){t=t||js;for(var n=r instanceof ut,i=!1,o=0;o<xi.length;o++){var s=e[xi[o]];if(s&&s.getShallow("show")){i=!0;break}}var l=n?r:r.getTextContent();if(i){n||(l||(l=new ut,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=yc(t,e),c=e.normal,v=!!c.getShallow("show"),f=Ct(c,a&&a.normal,t,!1,!n);f.text=u.normal,n||r.setTextConfig(gs(c,t,!1));for(var o=0;o<pe.length;o++){var h=pe[o],s=e[h];if(s){var p=l.ensureState(h),d=!!St(s.getShallow("show"),v);if(d!==v&&(p.ignore=!d),p.style=Ct(s,a&&a[h],t,!0,!n),p.style.text=u[h],!n){var g=r.ensureState(h);g.textConfig=gs(s,t,!0)}}}l.silent=!!c.getShallow("silent"),l.style.x!=null&&(f.x=l.style.x),l.style.y!=null&&(f.y=l.style.y),l.ignore=!v,l.useStyle(f),l.dirty(),t.enableTextSetter&&(bn(l).setLabelText=function(y){var m=yc(t,e,y);m0(l,m)})}else l&&(l.ignore=!0);r.dirty()}function Kt(r,e){e=e||"label";for(var t={normal:r.getModel(e)},a=0;a<pe.length;a++){var n=pe[a];t[n]=r.getModel([n,e])}return t}function Ct(r,e,t,a,n){var i={};return iA(i,r,t,a,n),e&&B(i,e),i}function gs(r,e,t){e=e||{};var a={},n,i=r.getShallow("rotate"),o=St(r.getShallow("distance"),t?null:5),s=r.getShallow("offset");return n=r.getShallow("position")||(t?null:"inside"),n==="outside"&&(n=e.defaultOutsidePosition||"top"),n!=null&&(a.position=n),s!=null&&(a.offset=s),i!=null&&(i*=Math.PI/180,a.rotation=i),o!=null&&(a.distance=o),a.outsideFill=r.get("color")==="inherit"?e.inheritColor||null:"auto",a}function iA(r,e,t,a,n){t=t||js;var i=e.ecModel,o=i&&i.option.textStyle,s=oA(e),l;if(s){l={};for(var u in s)if(s.hasOwnProperty(u)){var c=e.getModel(["rich",u]);Rh(l[u]={},c,o,t,a,n,!1,!0)}}l&&(r.rich=l);var v=e.get("overflow");v&&(r.overflow=v);var f=e.get("minMargin");f!=null&&(r.margin=f),Rh(r,e,o,t,a,n,!0,!1)}function oA(r){for(var e;r&&r!==r.ecModel;){var t=(r.option||js).rich;if(t){e=e||{};for(var a=Wt(t),n=0;n<a.length;n++){var i=a[n];e[i]=1}}r=r.parentModel}return e}var Lh=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],Ph=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],Eh=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Rh(r,e,t,a,n,i,o,s){t=!n&&t||js;var l=a&&a.inheritColor,u=e.getShallow("color"),c=e.getShallow("textBorderColor"),v=St(e.getShallow("opacity"),t.opacity);(u==="inherit"||u==="auto")&&(l?u=l:u=null),(c==="inherit"||c==="auto")&&(l?c=l:c=null),i||(u=u||t.color,c=c||t.textBorderColor),u!=null&&(r.fill=u),c!=null&&(r.stroke=c);var f=St(e.getShallow("textBorderWidth"),t.textBorderWidth);f!=null&&(r.lineWidth=f);var h=St(e.getShallow("textBorderType"),t.textBorderType);h!=null&&(r.lineDash=h);var p=St(e.getShallow("textBorderDashOffset"),t.textBorderDashOffset);p!=null&&(r.lineDashOffset=p),!n&&v==null&&!s&&(v=a&&a.defaultOpacity),v!=null&&(r.opacity=v),!n&&!i&&r.fill==null&&a.inheritColor&&(r.fill=a.inheritColor);for(var d=0;d<Lh.length;d++){var g=Lh[d],y=St(e.getShallow(g),t[g]);y!=null&&(r[g]=y)}for(var d=0;d<Ph.length;d++){var g=Ph[d],y=e.getShallow(g);y!=null&&(r[g]=y)}if(r.verticalAlign==null){var m=e.getShallow("baseline");m!=null&&(r.verticalAlign=m)}if(!o||!a.disableBox){for(var d=0;d<Eh.length;d++){var g=Eh[d],y=e.getShallow(g);y!=null&&(r[g]=y)}var S=e.getShallow("borderType");S!=null&&(r.borderDash=S),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&l&&(r.backgroundColor=l),(r.borderColor==="auto"||r.borderColor==="inherit")&&l&&(r.borderColor=l)}}function S0(r,e){var t=e&&e.getModel("textStyle");return Gi([r.fontStyle||t&&t.getShallow("fontStyle")||"",r.fontWeight||t&&t.getShallow("fontWeight")||"",(r.fontSize||t&&t.getShallow("fontSize")||12)+"px",r.fontFamily||t&&t.getShallow("fontFamily")||"sans-serif"].join(" "))}var bn=st();function x0(r,e,t,a){if(r){var n=bn(r);n.prevValue=n.value,n.value=t;var i=e.normal;n.valueAnimation=i.get("valueAnimation"),n.valueAnimation&&(n.precision=i.get("precision"),n.defaultInterpolatedText=a,n.statesModels=e)}}function _0(r,e,t,a,n){var i=bn(r);if(!i.valueAnimation||i.prevValue===i.value)return;var o=i.defaultInterpolatedText,s=St(i.interpolatedValue,i.prevValue),l=i.value;function u(c){var v=t0(t,i.precision,s,l,c);i.interpolatedValue=c===1?null:v;var f=yc({labelDataIndex:e,labelFetcher:n,defaultText:o?o(v):v+""},i.statesModels,v);m0(r,f)}r.percent=0,(i.prevValue==null?Lt:ft)(r,{percent:1},a,e,null,u)}var sA=["textStyle","color"],Cl=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Dl=new ut,lA=function(){function r(){}return r.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(sA):null)},r.prototype.getFont=function(){return S0({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},a=0;a<Cl.length;a++)t[Cl[a]]=this.getShallow(Cl[a]);return Dl.useStyle(t),Dl.update(),Dl.getBoundingRect()},r}();const uA=lA;var b0=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],cA=wa(b0),vA=function(){function r(){}return r.prototype.getLineStyle=function(e){return cA(this,e)},r}(),w0=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],fA=wa(w0),hA=function(){function r(){}return r.prototype.getItemStyle=function(e,t){return fA(this,e,t)},r}(),Ma=function(){function r(e,t,a){this.parentModel=t,this.ecModel=a,this.option=e}return r.prototype.init=function(e,t,a){},r.prototype.mergeOption=function(e,t){ot(this.option,e,!0)},r.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},r.prototype.getShallow=function(e,t){var a=this.option,n=a==null?a:a[e];if(n==null&&!t){var i=this.parentModel;i&&(n=i.getShallow(e))}return n},r.prototype.getModel=function(e,t){var a=e!=null,n=a?this.parsePath(e):null,i=a?this._doGet(n):this.option;return t=t||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(n)),new r(i,t,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var e=this.constructor;return new e(K(this.option))},r.prototype.parsePath=function(e){return typeof e=="string"?e.split("."):e},r.prototype.resolveParentPath=function(e){return e},r.prototype.isAnimationEnabled=function(){if(!kt.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(e,t){var a=this.option;if(!e)return a;for(var n=0;n<e.length&&!(e[n]&&(a=a&&typeof a=="object"?a[e[n]]:null,a==null));n++);return a==null&&t&&(a=t._doGet(this.resolveParentPath(e),t.parentModel)),a},r}();_v(Ma);Mw(Ma);jt(Ma,vA);jt(Ma,hA);jt(Ma,Rw);jt(Ma,uA);const Dt=Ma;var pA=Math.round(Math.random()*10);function wn(r){return[r||"",pA++].join("_")}function dA(r){var e={};r.registerSubTypeDefaulter=function(t,a){var n=qe(t);e[n.main]=a},r.determineSubType=function(t,a){var n=a.type;if(!n){var i=qe(t).main;r.hasSubTypes(t)&&e[i]&&(n=e[i](a))}return n}}function gA(r,e){r.topologicalTravel=function(i,o,s,l){if(!i.length)return;var u=t(o),c=u.graph,v=u.noEntryList,f={};for(w(i,function(m){f[m]=!0});v.length;){var h=v.pop(),p=c[h],d=!!f[h];d&&(s.call(l,h,p.originalDeps.slice()),delete f[h]),w(p.successor,d?y:g)}w(f,function(){var m="";throw new Error(m)});function g(m){c[m].entryCount--,c[m].entryCount===0&&v.push(m)}function y(m){f[m]=!0,g(m)}};function t(i){var o={},s=[];return w(i,function(l){var u=a(o,l),c=u.originalDeps=e(l),v=n(c,i);u.entryCount=v.length,u.entryCount===0&&s.push(l),w(v,function(f){ct(u.predecessor,f)<0&&u.predecessor.push(f);var h=a(o,f);ct(h.successor,f)<0&&h.successor.push(l)})}),{graph:o,noEntryList:s}}function a(i,o){return i[o]||(i[o]={predecessor:[],successor:[]}),i[o]}function n(i,o){var s=[];return w(i,function(l){ct(o,l)>=0&&s.push(l)}),s}}function $r(r,e){return ot(ot({},r,!0),e,!0)}const yA={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"}},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:". "}}}},mA={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:"旭日图"}},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 ys="ZH",Iv="EN",wi=Iv,qo={},Lv={},A0=kt.domSupported?function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage).toUpperCase();return r.indexOf(ys)>-1?ys:wi}():wi;function T0(r,e){r=r.toUpperCase(),Lv[r]=new Dt(e),qo[r]=e}function SA(r){if($(r)){var e=qo[r.toUpperCase()]||{};return r===ys||r===Iv?K(e):ot(K(e),K(qo[wi]),!1)}else return ot(K(r),K(qo[wi]),!1)}function mc(r){return Lv[r]}function xA(){return Lv[wi]}T0(Iv,yA);T0(ys,mA);var Pv=1e3,Ev=Pv*60,fi=Ev*60,De=fi*24,kh=De*365,ei={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},lo="{yyyy}-{MM}-{dd}",Nh={year:"{yyyy}",month:"{yyyy}-{MM}",day:lo,hour:lo+" "+ei.hour,minute:lo+" "+ei.minute,second:lo+" "+ei.second,millisecond:ei.none},Ml=["year","month","day","hour","minute","second","millisecond"],C0=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Sr(r,e){return r+="","0000".substr(0,e-r.length)+r}function Qa(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function _A(r){return r===Qa(r)}function bA(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function Js(r,e,t,a){var n=tr(r),i=n[Rv(t)](),o=n[tn(t)]()+1,s=Math.floor((o-1)/3)+1,l=n[Qs(t)](),u=n["get"+(t?"UTC":"")+"Day"](),c=n[Ai(t)](),v=(c-1)%12+1,f=n[tl(t)](),h=n[el(t)](),p=n[rl(t)](),d=a instanceof Dt?a:mc(a||A0)||xA(),g=d.getModel("time"),y=g.get("month"),m=g.get("monthAbbr"),S=g.get("dayOfWeek"),x=g.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,i+"").replace(/{yy}/g,Sr(i%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,y[o-1]).replace(/{MMM}/g,m[o-1]).replace(/{MM}/g,Sr(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,Sr(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,S[u]).replace(/{ee}/g,x[u]).replace(/{e}/g,u+"").replace(/{HH}/g,Sr(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,Sr(v+"",2)).replace(/{h}/g,v+"").replace(/{mm}/g,Sr(f,2)).replace(/{m}/g,f+"").replace(/{ss}/g,Sr(h,2)).replace(/{s}/g,h+"").replace(/{SSS}/g,Sr(p,3)).replace(/{S}/g,p+"")}function wA(r,e,t,a,n){var i=null;if($(t))i=t;else if(X(t))i=t(r.value,e,{level:r.level});else{var o=B({},ei);if(r.level>0)for(var s=0;s<Ml.length;++s)o[Ml[s]]="{primary|"+o[Ml[s]]+"}";var l=t?t.inherit===!1?t:J(t,o):o,u=D0(r.value,n);if(l[u])i=l[u];else if(l.inherit){for(var c=C0.indexOf(u),s=c-1;s>=0;--s)if(l[u]){i=l[u];break}i=i||o.none}if(O(i)){var v=r.level==null?0:r.level>=0?r.level:i.length+r.level;v=Math.min(v,i.length-1),i=i[v]}}return Js(new Date(r.value),i,n,a)}function D0(r,e){var t=tr(r),a=t[tn(e)]()+1,n=t[Qs(e)](),i=t[Ai(e)](),o=t[tl(e)](),s=t[el(e)](),l=t[rl(e)](),u=l===0,c=u&&s===0,v=c&&o===0,f=v&&i===0,h=f&&n===1,p=h&&a===1;return p?"year":h?"month":f?"day":v?"hour":c?"minute":u?"second":"millisecond"}function Oh(r,e,t){var a=gt(r)?tr(r):r;switch(e=e||D0(r,t),e){case"year":return a[Rv(t)]();case"half-year":return a[tn(t)]()>=6?1:0;case"quarter":return Math.floor((a[tn(t)]()+1)/4);case"month":return a[tn(t)]();case"day":return a[Qs(t)]();case"half-day":return a[Ai(t)]()/24;case"hour":return a[Ai(t)]();case"minute":return a[tl(t)]();case"second":return a[el(t)]();case"millisecond":return a[rl(t)]()}}function Rv(r){return r?"getUTCFullYear":"getFullYear"}function tn(r){return r?"getUTCMonth":"getMonth"}function Qs(r){return r?"getUTCDate":"getDate"}function Ai(r){return r?"getUTCHours":"getHours"}function tl(r){return r?"getUTCMinutes":"getMinutes"}function el(r){return r?"getUTCSeconds":"getSeconds"}function rl(r){return r?"getUTCMilliseconds":"getMilliseconds"}function AA(r){return r?"setUTCFullYear":"setFullYear"}function M0(r){return r?"setUTCMonth":"setMonth"}function I0(r){return r?"setUTCDate":"setDate"}function L0(r){return r?"setUTCHours":"setHours"}function P0(r){return r?"setUTCMinutes":"setMinutes"}function E0(r){return r?"setUTCSeconds":"setSeconds"}function R0(r){return r?"setUTCMilliseconds":"setMilliseconds"}function k0(r){if(!Ym(r))return $(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function N0(r,e){return r=(r||"").toLowerCase().replace(/-(.)/g,function(t,a){return a.toUpperCase()}),e&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var An=km;function Sc(r,e,t){var a="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(c){return c&&Gi(c)?c:"-"}function i(c){return!!(c!=null&&!isNaN(c)&&isFinite(c))}var o=e==="time",s=r instanceof Date;if(o||s){var l=o?tr(r):r;if(isNaN(+l)){if(s)return"-"}else return Js(l,a,t)}if(e==="ordinal")return ic(r)?n(r):gt(r)&&i(r)?r+"":"-";var u=cr(r);return i(u)?k0(u):ic(r)?n(r):typeof r=="boolean"?r+"":"-"}var Vh=["a","b","c","d","e","f","g"],Il=function(r,e){return"{"+r+(e??"")+"}"};function O0(r,e,t){O(e)||(e=[e]);var a=e.length;if(!a)return"";for(var n=e[0].$vars||[],i=0;i<n.length;i++){var o=Vh[i];r=r.replace(Il(o),Il(o,0))}for(var s=0;s<a;s++)for(var l=0;l<n.length;l++){var u=e[s][n[l]];r=r.replace(Il(Vh[l],s),t?ge(u):u)}return r}function TA(r,e,t){return w(e,function(a,n){r=r.replace("{"+n+"}",t?ge(a):a)}),r}function CA(r,e){var t=$(r)?{color:r,extraCssText:e}:r||{},a=t.color,n=t.type;e=t.extraCssText;var i=t.renderMode||"html";if(!a)return"";if(i==="html")return n==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+ge(a)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+ge(a)+";"+(e||"")+'"></span>';var o=t.markerId||"markerX";return{renderMode:i,content:"{"+o+"|}  ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:a}:{width:10,height:10,borderRadius:5,backgroundColor:a}}}function Ta(r,e){return e=e||"transparent",$(r)?r:j(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function ms(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var jo=w,V0=["left","right","top","bottom","width","height"],ua=[["width","left","right"],["height","top","bottom"]];function kv(r,e,t,a,n){var i=0,o=0;a==null&&(a=1/0),n==null&&(n=1/0);var s=0;e.eachChild(function(l,u){var c=l.getBoundingRect(),v=e.childAt(u+1),f=v&&v.getBoundingRect(),h,p;if(r==="horizontal"){var d=c.width+(f?-f.x+c.x:0);h=i+d,h>a||l.newline?(i=0,h=d,o+=s+t,s=c.height):s=Math.max(s,c.height)}else{var g=c.height+(f?-f.y+c.y:0);p=o+g,p>n||l.newline?(i+=s+t,o=0,p=g,s=c.width):s=Math.max(s,c.width)}l.newline||(l.x=i,l.y=o,l.markRedraw(),r==="horizontal"?i=h+t:o=p+t)})}var da=kv;Q(kv,"vertical");Q(kv,"horizontal");function DA(r,e,t){var a=e.width,n=e.height,i=F(r.left,a),o=F(r.top,n),s=F(r.right,a),l=F(r.bottom,n);return(isNaN(i)||isNaN(parseFloat(r.left)))&&(i=0),(isNaN(s)||isNaN(parseFloat(r.right)))&&(s=a),(isNaN(o)||isNaN(parseFloat(r.top)))&&(o=0),(isNaN(l)||isNaN(parseFloat(r.bottom)))&&(l=n),t=An(t||0),{width:Math.max(s-i-t[1]-t[3],0),height:Math.max(l-o-t[0]-t[2],0)}}function Yt(r,e,t){t=An(t||0);var a=e.width,n=e.height,i=F(r.left,a),o=F(r.top,n),s=F(r.right,a),l=F(r.bottom,n),u=F(r.width,a),c=F(r.height,n),v=t[2]+t[0],f=t[1]+t[3],h=r.aspect;switch(isNaN(u)&&(u=a-s-f-i),isNaN(c)&&(c=n-l-v-o),h!=null&&(isNaN(u)&&isNaN(c)&&(h>a/n?u=a*.8:c=n*.8),isNaN(u)&&(u=h*c),isNaN(c)&&(c=u/h)),isNaN(i)&&(i=a-s-u-f),isNaN(o)&&(o=n-l-c-v),r.left||r.right){case"center":i=a/2-u/2-t[3];break;case"right":i=a-u-f;break}switch(r.top||r.bottom){case"middle":case"center":o=n/2-c/2-t[0];break;case"bottom":o=n-c-v;break}i=i||0,o=o||0,isNaN(u)&&(u=a-f-i-(s||0)),isNaN(c)&&(c=n-v-o-(l||0));var p=new wt(i+t[3],o+t[0],u,c);return p.margin=t,p}function al(r,e,t,a,n,i){var o=!n||!n.hv||n.hv[0],s=!n||!n.hv||n.hv[1],l=n&&n.boundingMode||"all";if(i=i||r,i.x=r.x,i.y=r.y,!o&&!s)return!1;var u;if(l==="raw")u=r.type==="group"?new wt(0,0,+e.width||0,+e.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var c=r.getLocalTransform();u=u.clone(),u.applyTransform(c)}var v=Yt(J({width:u.width,height:u.height},e),t,a),f=o?v.x-u.x:0,h=s?v.y-u.y:0;return l==="raw"?(i.x=f,i.y=h):(i.x+=f,i.y+=h),i===r&&r.markRedraw(),!0}function MA(r,e){return r[ua[e][0]]!=null||r[ua[e][1]]!=null&&r[ua[e][2]]!=null}function Ti(r){var e=r.layoutMode||r.constructor.layoutMode;return j(e)?e:e?{type:e}:null}function Vr(r,e,t){var a=t&&t.ignoreSize;!O(a)&&(a=[a,a]);var n=o(ua[0],0),i=o(ua[1],1);u(ua[0],r,n),u(ua[1],r,i);function o(c,v){var f={},h=0,p={},d=0,g=2;if(jo(c,function(S){p[S]=r[S]}),jo(c,function(S){s(e,S)&&(f[S]=p[S]=e[S]),l(f,S)&&h++,l(p,S)&&d++}),a[v])return l(e,c[1])?p[c[2]]=null:l(e,c[2])&&(p[c[1]]=null),p;if(d===g||!h)return p;if(h>=g)return f;for(var y=0;y<c.length;y++){var m=c[y];if(!s(f,m)&&s(r,m)){f[m]=r[m];break}}return f}function s(c,v){return c.hasOwnProperty(v)}function l(c,v){return c[v]!=null&&c[v]!=="auto"}function u(c,v,f){jo(c,function(h){v[h]=f[h]})}}function Tn(r){return B0({},r)}function B0(r,e){return e&&r&&jo(V0,function(t){e.hasOwnProperty(t)&&(r[t]=e[t])}),r}var IA=st(),Cn=function(r){R(e,r);function e(t,a,n){var i=r.call(this,t,a,n)||this;return i.uid=wn("ec_cpt_model"),i}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=Ti(this),i=n?Tn(t):{},o=a.getTheme();ot(t,o.get(this.mainType)),ot(t,this.getDefaultOption()),n&&Vr(t,i,n)},e.prototype.mergeOption=function(t,a){ot(this.option,t,!0);var n=Ti(this);n&&Vr(this.option,t,n)},e.prototype.optionUpdated=function(t,a){},e.prototype.getDefaultOption=function(){var t=this.constructor;if(!Tw(t))return t.defaultOption;var a=IA(this);if(!a.defaultOption){for(var n=[],i=t;i;){var o=i.prototype.defaultOption;o&&n.push(o),i=i.superClass}for(var s={},l=n.length-1;l>=0;l--)s=ot(s,n[l],!0);a.defaultOption=s}return a.defaultOption},e.prototype.getReferringComponents=function(t,a){var n=t+"Index",i=t+"Id";return Wi(this.ecModel,t,{index:this.get(n,!0),id:this.get(i,!0)},a)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(Dt);r0(Cn,Dt);Ys(Cn);dA(Cn);gA(Cn,LA);function LA(r){var e=[];return w(Cn.getClassesByMainType(r),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=G(e,function(t){return qe(t).main}),r!=="dataset"&&ct(e,"dataset")<=0&&e.unshift("dataset"),e}const lt=Cn;var z0="";typeof navigator<"u"&&(z0=navigator.platform||"");var Na="rgba(0, 0, 0, 0.2)";const PA={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Na,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Na,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Na,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Na,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Na,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Na,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:z0.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 G0=Z(["tooltip","label","itemName","itemId","itemGroupId","seriesName"]),Ne="original",se="arrayRows",Oe="objectRows",er="keyedColumns",Er="typedArray",F0="unknown",Qe="column",Dn="row",Qt={Must:1,Might:2,Not:3},H0=st();function EA(r){H0(r).datasetMap=Z()}function W0(r,e,t){var a={},n=Ov(e);if(!n||!r)return a;var i=[],o=[],s=e.ecModel,l=H0(s).datasetMap,u=n.uid+"_"+t.seriesLayoutBy,c,v;r=r.slice(),w(r,function(d,g){var y=j(d)?d:r[g]={name:d};y.type==="ordinal"&&c==null&&(c=g,v=p(y)),a[y.name]=[]});var f=l.get(u)||l.set(u,{categoryWayDim:v,valueWayDim:0});w(r,function(d,g){var y=d.name,m=p(d);if(c==null){var S=f.valueWayDim;h(a[y],S,m),h(o,S,m),f.valueWayDim+=m}else if(c===g)h(a[y],0,m),h(i,0,m);else{var S=f.categoryWayDim;h(a[y],S,m),h(o,S,m),f.categoryWayDim+=m}});function h(d,g,y){for(var m=0;m<y;m++)d.push(g+m)}function p(d){var g=d.dimsDef;return g?g.length:1}return i.length&&(a.itemName=i),o.length&&(a.seriesName=o),a}function Nv(r,e,t){var a={},n=Ov(r);if(!n)return a;var i=e.sourceFormat,o=e.dimensionsDefine,s;(i===Oe||i===er)&&w(o,function(c,v){(j(c)?c.name:c)==="name"&&(s=v)});var l=function(){for(var c={},v={},f=[],h=0,p=Math.min(5,t);h<p;h++){var d=U0(e.data,i,e.seriesLayoutBy,o,e.startIndex,h);f.push(d);var g=d===Qt.Not;if(g&&c.v==null&&h!==s&&(c.v=h),(c.n==null||c.n===c.v||!g&&f[c.n]===Qt.Not)&&(c.n=h),y(c)&&f[c.n]!==Qt.Not)return c;g||(d===Qt.Might&&v.v==null&&h!==s&&(v.v=h),(v.n==null||v.n===v.v)&&(v.n=h))}function y(m){return m.v!=null&&m.n!=null}return y(c)?c:y(v)?v:null}();if(l){a.value=[l.v];var u=s??l.n;a.itemName=[u],a.seriesName=[u]}return a}function Ov(r){var e=r.get("data",!0);if(!e)return Wi(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Ft).models[0]}function RA(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:Wi(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Ft).models}function $0(r,e){return U0(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,e)}function U0(r,e,t,a,n,i){var o,s=5;if(Re(r))return Qt.Not;var l,u;if(a){var c=a[i];j(c)?(l=c.name,u=c.type):$(c)&&(l=c)}if(u!=null)return u==="ordinal"?Qt.Must:Qt.Not;if(e===se){var v=r;if(t===Dn){for(var f=v[i],h=0;h<(f||[]).length&&h<s;h++)if((o=x(f[n+h]))!=null)return o}else for(var h=0;h<v.length&&h<s;h++){var p=v[n+h];if(p&&(o=x(p[i]))!=null)return o}}else if(e===Oe){var d=r;if(!l)return Qt.Not;for(var h=0;h<d.length&&h<s;h++){var g=d[h];if(g&&(o=x(g[l]))!=null)return o}}else if(e===er){var y=r;if(!l)return Qt.Not;var f=y[l];if(!f||Re(f))return Qt.Not;for(var h=0;h<f.length&&h<s;h++)if((o=x(f[h]))!=null)return o}else if(e===Ne)for(var m=r,h=0;h<m.length&&h<s;h++){var g=m[h],S=mn(g);if(!O(S))return Qt.Not;if((o=x(S[i]))!=null)return o}function x(b){var _=$(b);if(b!=null&&isFinite(b)&&b!=="")return _?Qt.Might:Qt.Not;if(_&&b!=="-")return Qt.Must}return Qt.Not}var xc=Z();function kA(r,e){ye(xc.get(r)==null&&e),xc.set(r,e)}function NA(r,e,t){var a=xc.get(e);if(!a)return t;var n=a(r);return n?t.concat(n):t}var Bh=st(),OA=st(),Vv=function(){function r(){}return r.prototype.getColorFromPalette=function(e,t,a){var n=_t(this.get("color",!0)),i=this.get("colorLayer",!0);return Y0(this,Bh,n,i,e,t,a)},r.prototype.clearColorPalette=function(){BA(this,Bh)},r}();function _c(r,e,t,a){var n=_t(r.get(["aria","decal","decals"]));return Y0(r,OA,n,null,e,t,a)}function VA(r,e){for(var t=r.length,a=0;a<t;a++)if(r[a].length>e)return r[a];return r[t-1]}function Y0(r,e,t,a,n,i,o){i=i||r;var s=e(i),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(n))return u[n];var c=o==null||!a?t:VA(a,o);if(c=c||t,!(!c||!c.length)){var v=c[l];return n&&(u[n]=v),s.paletteIdx=(l+1)%c.length,v}}function BA(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var uo,Rn,zh,Gh="\0_ec_inner",zA=1,Z0=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t,a,n,i,o,s){i=i||{},this.option=null,this._theme=new Dt(i),this._locale=new Dt(o),this._optionManager=s},e.prototype.setOption=function(t,a,n){var i=Wh(a);this._optionManager.setOption(t,n,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,a){return this._resetOption(t,Wh(a))},e.prototype._resetOption=function(t,a){var n=!1,i=this._optionManager;if(!t||t==="recreate"){var o=i.mountOption(t==="recreate");!this.option||t==="recreate"?zh(this,o):(this.restoreData(),this._mergeOption(o,a)),n=!0}if((t==="timeline"||t==="media")&&this.restoreData(),!t||t==="recreate"||t==="timeline"){var s=i.getTimelineOption(this);s&&(n=!0,this._mergeOption(s,a))}if(!t||t==="recreate"||t==="media"){var l=i.getMediaOption(this);l.length&&w(l,function(u){n=!0,this._mergeOption(u,a)},this)}return n},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,a){var n=this.option,i=this._componentsMap,o=this._componentsCount,s=[],l=Z(),u=a&&a.replaceMergeMainTypeMap;EA(this),w(t,function(v,f){v!=null&&(lt.hasClass(f)?f&&(s.push(f),l.set(f,!0)):n[f]=n[f]==null?K(v):ot(n[f],v,!0))}),u&&u.each(function(v,f){lt.hasClass(f)&&!l.get(f)&&(s.push(f),l.set(f,!0))}),lt.topologicalTravel(s,lt.getAllClassMainTypes(),c,this);function c(v){var f=NA(this,v,_t(t[v])),h=i.get(v),p=h?u&&u.get(v)?"replaceMerge":"normalMerge":"replaceAll",d=jm(h,f,p);gw(d,v,lt),n[v]=null,i.set(v,null),o.set(v,0);var g=[],y=[],m=0,S;w(d,function(x,b){var _=x.existing,A=x.newOption;if(!A)_&&(_.mergeOption({},this),_.optionUpdated({},!1));else{var T=v==="series",C=lt.getClass(v,x.keyInfo.subType,!T);if(!C)return;if(v==="tooltip"){if(S)return;S=!0}if(_&&_.constructor===C)_.name=x.keyInfo.name,_.mergeOption(A,this),_.optionUpdated(A,!1);else{var M=B({componentIndex:b},x.keyInfo);_=new C(A,this,this,M),B(_,M),x.brandNew&&(_.__requireNewView=!0),_.init(A,this,this),_.optionUpdated(null,!0)}}_?(g.push(_.option),y.push(_),m++):(g.push(void 0),y.push(void 0))},this),n[v]=g,i.set(v,y),o.set(v,m),v==="series"&&uo(this)}this._seriesIndices||uo(this)},e.prototype.getOption=function(){var t=K(this.option);return w(t,function(a,n){if(lt.hasClass(n)){for(var i=_t(a),o=i.length,s=!1,l=o-1;l>=0;l--)i[l]&&!Si(i[l])?s=!0:(i[l]=null,!s&&o--);i.length=o,t[n]=i}}),delete t[Gh],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,a){var n=this._componentsMap.get(t);if(n){var i=n[a||0];if(i)return i;if(a==null){for(var o=0;o<n.length;o++)if(n[o])return n[o]}}},e.prototype.queryComponents=function(t){var a=t.mainType;if(!a)return[];var n=t.index,i=t.id,o=t.name,s=this._componentsMap.get(a);if(!s||!s.length)return[];var l;return n!=null?(l=[],w(_t(n),function(u){s[u]&&l.push(s[u])})):i!=null?l=Fh("id",i,s):o!=null?l=Fh("name",o,s):l=bt(s,function(u){return!!u}),Hh(l,t)},e.prototype.findComponents=function(t){var a=t.query,n=t.mainType,i=s(a),o=i?this.queryComponents(i):bt(this._componentsMap.get(n),function(u){return!!u});return l(Hh(o,t));function s(u){var c=n+"Index",v=n+"Id",f=n+"Name";return u&&(u[c]!=null||u[v]!=null||u[f]!=null)?{mainType:n,index:u[c],id:u[v],name:u[f]}:null}function l(u){return t.filter?bt(u,t.filter):u}},e.prototype.eachComponent=function(t,a,n){var i=this._componentsMap;if(X(t)){var o=a,s=t;i.each(function(v,f){for(var h=0;v&&h<v.length;h++){var p=v[h];p&&s.call(o,f,p,p.componentIndex)}})}else for(var l=$(t)?i.get(t):j(t)?this.findComponents(t):null,u=0;l&&u<l.length;u++){var c=l[u];c&&a.call(n,c,c.componentIndex)}},e.prototype.getSeriesByName=function(t){var a=Ut(t,null);return bt(this._componentsMap.get("series"),function(n){return!!n&&a!=null&&n.name===a})},e.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},e.prototype.getSeriesByType=function(t){return bt(this._componentsMap.get("series"),function(a){return!!a&&a.subType===t})},e.prototype.getSeries=function(){return bt(this._componentsMap.get("series"),function(t){return!!t})},e.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},e.prototype.eachSeries=function(t,a){Rn(this),w(this._seriesIndices,function(n){var i=this._componentsMap.get("series")[n];t.call(a,i,n)},this)},e.prototype.eachRawSeries=function(t,a){w(this._componentsMap.get("series"),function(n){n&&t.call(a,n,n.componentIndex)})},e.prototype.eachSeriesByType=function(t,a,n){Rn(this),w(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];o.subType===t&&a.call(n,o,i)},this)},e.prototype.eachRawSeriesByType=function(t,a,n){return w(this.getSeriesByType(t),a,n)},e.prototype.isSeriesFiltered=function(t){return Rn(this),this._seriesIndicesMap.get(t.componentIndex)==null},e.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},e.prototype.filterSeries=function(t,a){Rn(this);var n=[];w(this._seriesIndices,function(i){var o=this._componentsMap.get("series")[i];t.call(a,o,i)&&n.push(i)},this),this._seriesIndices=n,this._seriesIndicesMap=Z(n)},e.prototype.restoreData=function(t){uo(this);var a=this._componentsMap,n=[];a.each(function(i,o){lt.hasClass(o)&&n.push(o)}),lt.topologicalTravel(n,lt.getAllClassMainTypes(),function(i){w(a.get(i),function(o){o&&(i!=="series"||!GA(o,t))&&o.restoreData()})})},e.internalField=function(){uo=function(t){var a=t._seriesIndices=[];w(t._componentsMap.get("series"),function(n){n&&a.push(n.componentIndex)}),t._seriesIndicesMap=Z(a)},Rn=function(t){},zh=function(t,a){t.option={},t.option[Gh]=zA,t._componentsMap=Z({series:[]}),t._componentsCount=Z();var n=a.aria;j(n)&&n.enabled==null&&(n.enabled=!0),FA(a,t._theme.option),ot(a,PA,!1),t._mergeOption(a,null)}}(),e}(Dt);function GA(r,e){if(e){var t=e.seriesIndex,a=e.seriesId,n=e.seriesName;return t!=null&&r.componentIndex!==t||a!=null&&r.id!==a||n!=null&&r.name!==n}}function FA(r,e){var t=r.color&&!r.colorLayer;w(e,function(a,n){n==="colorLayer"&&t||lt.hasClass(n)||(typeof a=="object"?r[n]=r[n]?ot(r[n],a,!1):K(a):r[n]==null&&(r[n]=a))})}function Fh(r,e,t){if(O(e)){var a=Z();return w(e,function(i){if(i!=null){var o=Ut(i,null);o!=null&&a.set(i,!0)}}),bt(t,function(i){return i&&a.get(i[r])})}else{var n=Ut(e,null);return bt(t,function(i){return i&&n!=null&&i[r]===n})}}function Hh(r,e){return e.hasOwnProperty("subType")?bt(r,function(t){return t&&t.subType===e.subType}):r}function Wh(r){var e=Z();return r&&w(_t(r.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}jt(Z0,Vv);const X0=Z0;var HA=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],WA=function(){function r(e){w(HA,function(t){this[t]=W(e[t],e)},this)}return r}();const K0=WA;var Ll={},$A=function(){function r(){this._coordinateSystems=[]}return r.prototype.create=function(e,t){var a=[];w(Ll,function(n,i){var o=n.create(e,t);a=a.concat(o||[])}),this._coordinateSystems=a},r.prototype.update=function(e,t){w(this._coordinateSystems,function(a){a.update&&a.update(e,t)})},r.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},r.register=function(e,t){Ll[e]=t},r.get=function(e){return Ll[e]},r}();const Xi=$A;var UA=/^(min|max)?(.+)$/,YA=function(){function r(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return r.prototype.setOption=function(e,t,a){e&&(w(_t(e.series),function(o){o&&o.data&&Re(o.data)&&ss(o.data)}),w(_t(e.dataset),function(o){o&&o.source&&Re(o.source)&&ss(o.source)})),e=K(e);var n=this._optionBackup,i=ZA(e,t,!n);this._newBaseOption=i.baseOption,n?(i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},r.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],K(e?t.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(e){var t,a=this._timelineOptions;if(a.length){var n=e.getComponent("timeline");n&&(t=K(a[n.getCurrentIndex()]))}return t},r.prototype.getMediaOption=function(e){var t=this._api.getWidth(),a=this._api.getHeight(),n=this._mediaList,i=this._mediaDefault,o=[],s=[];if(!n.length&&!i)return s;for(var l=0,u=n.length;l<u;l++)XA(n[l].query,t,a)&&o.push(l);return!o.length&&i&&(o=[-1]),o.length&&!qA(o,this._currentMediaIndices)&&(s=G(o,function(c){return K(c===-1?i.option:n[c].option)})),this._currentMediaIndices=o,s},r}();function ZA(r,e,t){var a=[],n,i,o=r.baseOption,s=r.timeline,l=r.options,u=r.media,c=!!r.media,v=!!(l||s||o&&o.timeline);o?(i=o,i.timeline||(i.timeline=s)):((v||c)&&(r.options=r.media=null),i=r),c&&O(u)&&w(u,function(h){h&&h.option&&(h.query?a.push(h):n||(n=h))}),f(i),w(l,function(h){return f(h)}),w(a,function(h){return f(h.option)});function f(h){w(e,function(p){p(h,t)})}return{baseOption:i,timelineOptions:l||[],mediaDefault:n,mediaList:a}}function XA(r,e,t){var a={width:e,height:t,aspectratio:e/t},n=!0;return w(r,function(i,o){var s=o.match(UA);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();KA(a[u],i,l)||(n=!1)}}),n}function KA(r,e,t){return t==="min"?r>=e:t==="max"?r<=e:r===e}function qA(r,e){return r.join(",")===e.join(",")}const jA=YA;var Ve=w,Ci=j,$h=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Pl(r){var e=r&&r.itemStyle;if(e)for(var t=0,a=$h.length;t<a;t++){var n=$h[t],i=e.normal,o=e.emphasis;i&&i[n]&&(r[n]=r[n]||{},r[n].normal?ot(r[n].normal,i[n]):r[n].normal=i[n],i[n]=null),o&&o[n]&&(r[n]=r[n]||{},r[n].emphasis?ot(r[n].emphasis,o[n]):r[n].emphasis=o[n],o[n]=null)}}function oe(r,e,t){if(r&&r[e]&&(r[e].normal||r[e].emphasis)){var a=r[e].normal,n=r[e].emphasis;a&&(t?(r[e].normal=r[e].emphasis=null,J(r[e],a)):r[e]=a),n&&(r.emphasis=r.emphasis||{},r.emphasis[e]=n,n.focus&&(r.emphasis.focus=n.focus),n.blurScope&&(r.emphasis.blurScope=n.blurScope))}}function ri(r){oe(r,"itemStyle"),oe(r,"lineStyle"),oe(r,"areaStyle"),oe(r,"label"),oe(r,"labelLine"),oe(r,"upperLabel"),oe(r,"edgeLabel")}function zt(r,e){var t=Ci(r)&&r[e],a=Ci(t)&&t.textStyle;if(a)for(var n=0,i=gh.length;n<i;n++){var o=gh[n];a.hasOwnProperty(o)&&(t[o]=a[o])}}function we(r){r&&(ri(r),zt(r,"label"),r.emphasis&&zt(r.emphasis,"label"))}function JA(r){if(Ci(r)){Pl(r),ri(r),zt(r,"label"),zt(r,"upperLabel"),zt(r,"edgeLabel"),r.emphasis&&(zt(r.emphasis,"label"),zt(r.emphasis,"upperLabel"),zt(r.emphasis,"edgeLabel"));var e=r.markPoint;e&&(Pl(e),we(e));var t=r.markLine;t&&(Pl(t),we(t));var a=r.markArea;a&&we(a);var n=r.data;if(r.type==="graph"){n=n||r.nodes;var i=r.links||r.edges;if(i&&!Re(i))for(var o=0;o<i.length;o++)we(i[o]);w(r.categories,function(u){ri(u)})}if(n&&!Re(n))for(var o=0;o<n.length;o++)we(n[o]);if(e=r.markPoint,e&&e.data)for(var s=e.data,o=0;o<s.length;o++)we(s[o]);if(t=r.markLine,t&&t.data)for(var l=t.data,o=0;o<l.length;o++)O(l[o])?(we(l[o][0]),we(l[o][1])):we(l[o]);r.type==="gauge"?(zt(r,"axisLabel"),zt(r,"title"),zt(r,"detail")):r.type==="treemap"?(oe(r.breadcrumb,"itemStyle"),w(r.levels,function(u){ri(u)})):r.type==="tree"&&ri(r.leaves)}}function nr(r){return O(r)?r:r?[r]:[]}function Uh(r){return(O(r)?r[0]:r)||{}}function QA(r,e){Ve(nr(r.series),function(a){Ci(a)&&JA(a)});var t=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&t.push("valueAxis","categoryAxis","logAxis","timeAxis"),Ve(t,function(a){Ve(nr(r[a]),function(n){n&&(zt(n,"axisLabel"),zt(n.axisPointer,"label"))})}),Ve(nr(r.parallel),function(a){var n=a&&a.parallelAxisDefault;zt(n,"axisLabel"),zt(n&&n.axisPointer,"label")}),Ve(nr(r.calendar),function(a){oe(a,"itemStyle"),zt(a,"dayLabel"),zt(a,"monthLabel"),zt(a,"yearLabel")}),Ve(nr(r.radar),function(a){zt(a,"name"),a.name&&a.axisName==null&&(a.axisName=a.name,delete a.name),a.nameGap!=null&&a.axisNameGap==null&&(a.axisNameGap=a.nameGap,delete a.nameGap)}),Ve(nr(r.geo),function(a){Ci(a)&&(we(a),Ve(nr(a.regions),function(n){we(n)}))}),Ve(nr(r.timeline),function(a){we(a),oe(a,"label"),oe(a,"itemStyle"),oe(a,"controlStyle",!0);var n=a.data;O(n)&&w(n,function(i){j(i)&&(oe(i,"label"),oe(i,"itemStyle"))})}),Ve(nr(r.toolbox),function(a){oe(a,"iconStyle"),Ve(a.feature,function(n){oe(n,"iconStyle")})}),zt(Uh(r.axisPointer),"label"),zt(Uh(r.tooltip).axisPointer,"label")}function tT(r,e){for(var t=e.split(","),a=r,n=0;n<t.length&&(a=a&&a[t[n]],a!=null);n++);return a}function eT(r,e,t,a){for(var n=e.split(","),i=r,o,s=0;s<n.length-1;s++)o=n[s],i[o]==null&&(i[o]={}),i=i[o];(a||i[n[s]]==null)&&(i[n[s]]=t)}function Yh(r){r&&w(rT,function(e){e[0]in r&&!(e[1]in r)&&(r[e[1]]=r[e[0]])})}var rT=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],aT=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],El=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function kn(r){var e=r&&r.itemStyle;if(e)for(var t=0;t<El.length;t++){var a=El[t][1],n=El[t][0];e[a]!=null&&(e[n]=e[a])}}function Zh(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function Xh(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function nT(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function q0(r,e){if(r)for(var t=0;t<r.length;t++)e(r[t]),r[t]&&q0(r[t].children,e)}function j0(r,e){QA(r,e),r.series=_t(r.series),w(r.series,function(t){if(j(t)){var a=t.type;if(a==="line")t.clipOverflow!=null&&(t.clip=t.clipOverflow);else if(a==="pie"||a==="gauge"){t.clockWise!=null&&(t.clockwise=t.clockWise),Zh(t.label);var n=t.data;if(n&&!Re(n))for(var i=0;i<n.length;i++)Zh(n[i]);t.hoverOffset!=null&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if(a==="gauge"){var o=tT(t,"pointer.color");o!=null&&eT(t,"itemStyle.color",o)}else if(a==="bar"){kn(t),kn(t.backgroundStyle),kn(t.emphasis);var n=t.data;if(n&&!Re(n))for(var i=0;i<n.length;i++)typeof n[i]=="object"&&(kn(n[i]),kn(n[i]&&n[i].emphasis))}else if(a==="sunburst"){var s=t.highlightPolicy;s&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=s)),Xh(t),q0(t.data,Xh)}else a==="graph"||a==="sankey"?nT(t):a==="map"&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&J(t,t.mapLocation));t.hoverAnimation!=null&&(t.emphasis=t.emphasis||{},t.emphasis&&t.emphasis.scale==null&&(t.emphasis.scale=t.hoverAnimation)),Yh(t)}}),r.dataRange&&(r.visualMap=r.dataRange),w(aT,function(t){var a=r[t];a&&(O(a)||(a=[a]),w(a,function(n){Yh(n)}))})}function iT(r){var e=Z();r.eachSeries(function(t){var a=t.get("stack");if(a){var n=e.get(a)||e.set(a,[]),i=t.getData(),o={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;n.length&&i.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(o)}}),e.each(oT)}function oT(r){w(r,function(e,t){var a=[],n=[NaN,NaN],i=[e.stackResultDimension,e.stackedOverDimension],o=e.data,s=e.isStackedByIndex,l=e.seriesModel.get("stackStrategy")||"samesign";o.modify(i,function(u,c,v){var f=o.get(e.stackedDimension,v);if(isNaN(f))return n;var h,p;s?p=o.getRawIndex(v):h=o.get(e.stackedByDimension,v);for(var d=NaN,g=t-1;g>=0;g--){var y=r[g];if(s||(p=y.data.rawIndexOf(y.stackedByDimension,h)),p>=0){var m=y.data.getByRawIndex(y.stackResultDimension,p);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&f>=0&&m>0||l==="samesign"&&f<=0&&m<0){f=iw(f,m),d=m;break}}}return a[0]=f,a[1]=d,a})})}var nl=function(){function r(e){this.data=e.data||(e.sourceFormat===er?{}:[]),this.sourceFormat=e.sourceFormat||F0,this.seriesLayoutBy=e.seriesLayoutBy||Qe,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var a=0;a<t.length;a++){var n=t[a];n.type==null&&$0(this,a)===Qt.Must&&(n.type="ordinal")}}return r}();function Bv(r){return r instanceof nl}function bc(r,e,t){t=t||J0(r);var a=e.seriesLayoutBy,n=lT(r,t,a,e.sourceHeader,e.dimensions),i=new nl({data:r,sourceFormat:t,seriesLayoutBy:a,dimensionsDefine:n.dimensionsDefine,startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount,metaRawOption:K(e)});return i}function zv(r){return new nl({data:r,sourceFormat:Re(r)?Er:Ne})}function sT(r){return new nl({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:K(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function J0(r){var e=F0;if(Re(r))e=Er;else if(O(r)){r.length===0&&(e=se);for(var t=0,a=r.length;t<a;t++){var n=r[t];if(n!=null){if(O(n)){e=se;break}else if(j(n)){e=Oe;break}}}}else if(j(r)){for(var i in r)if(U(r,i)&&pn(r[i])){e=er;break}}return e}function lT(r,e,t,a,n){var i,o;if(!r)return{dimensionsDefine:Kh(n),startIndex:o,dimensionsDetectedCount:i};if(e===se){var s=r;a==="auto"||a==null?qh(function(u){u!=null&&u!=="-"&&($(u)?o==null&&(o=1):o=0)},t,s,10):o=gt(a)?a:a?1:0,!n&&o===1&&(n=[],qh(function(u,c){n[c]=u!=null?u+"":""},t,s,1/0)),i=n?n.length:t===Dn?s.length:s[0]?s[0].length:null}else if(e===Oe)n||(n=uT(r));else if(e===er)n||(n=[],w(r,function(u,c){n.push(c)}));else if(e===Ne){var l=mn(r[0]);i=O(l)&&l.length||1}return{startIndex:o,dimensionsDefine:Kh(n),dimensionsDetectedCount:i}}function uT(r){for(var e=0,t;e<r.length&&!(t=r[e++]););if(t)return Wt(t)}function Kh(r){if(r){var e=Z();return G(r,function(t,a){t=j(t)?t:{name:t};var n={name:t.name,displayName:t.displayName,type:t.type};if(n.name==null)return n;n.name+="",n.displayName==null&&(n.displayName=n.name);var i=e.get(n.name);return i?n.name+="-"+i.count++:e.set(n.name,{count:1}),n})}}function qh(r,e,t,a){if(e===Dn)for(var n=0;n<t.length&&n<a;n++)r(t[n]?t[n][0]:null,n);else for(var i=t[0]||[],n=0;n<i.length&&n<a;n++)r(i[n],n)}function Q0(r){var e=r.sourceFormat;return e===Oe||e===er}var Yr,Zr,Xr,jh,Jh,tS=function(){function r(e,t){var a=Bv(e)?e:zv(e);this._source=a;var n=this._data=a.data;a.sourceFormat===Er&&(this._offset=0,this._dimSize=t,this._data=n),Jh(this,n,a)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(e,t){},r.prototype.appendData=function(e){},r.prototype.clean=function(){},r.protoInitialize=function(){var e=r.prototype;e.pure=!1,e.persistent=!0}(),r.internalField=function(){var e;Jh=function(o,s,l){var u=l.sourceFormat,c=l.seriesLayoutBy,v=l.startIndex,f=l.dimensionsDefine,h=jh[Gv(u,c)];if(B(o,h),u===Er)o.getItem=t,o.count=n,o.fillStorage=a;else{var p=eS(u,c);o.getItem=W(p,null,s,v,f);var d=rS(u,c);o.count=W(d,null,s,v,f)}};var t=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,c=u*o,v=0;v<u;v++)s[v]=l[c+v];return s},a=function(o,s,l,u){for(var c=this._data,v=this._dimSize,f=0;f<v;f++){for(var h=u[f],p=h[0]==null?1/0:h[0],d=h[1]==null?-1/0:h[1],g=s-o,y=l[f],m=0;m<g;m++){var S=c[m*v+f];y[o+m]=S,S<p&&(p=S),S>d&&(d=S)}h[0]=p,h[1]=d}},n=function(){return this._data?this._data.length/this._dimSize:0};jh=(e={},e[se+"_"+Qe]={pure:!0,appendData:i},e[se+"_"+Dn]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Oe]={pure:!0,appendData:i},e[er]={pure:!0,appendData:function(o){var s=this._data;w(o,function(l,u){for(var c=s[u]||(s[u]=[]),v=0;v<(l||[]).length;v++)c.push(l[v])})}},e[Ne]={appendData:i},e[Er]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}}(),r}(),Qh=function(r,e,t,a){return r[a]},cT=(Yr={},Yr[se+"_"+Qe]=function(r,e,t,a){return r[a+e]},Yr[se+"_"+Dn]=function(r,e,t,a,n){a+=e;for(var i=n||[],o=r,s=0;s<o.length;s++){var l=o[s];i[s]=l?l[a]:null}return i},Yr[Oe]=Qh,Yr[er]=function(r,e,t,a,n){for(var i=n||[],o=0;o<t.length;o++){var s=t[o].name,l=r[s];i[o]=l?l[a]:null}return i},Yr[Ne]=Qh,Yr);function eS(r,e){var t=cT[Gv(r,e)];return t}var tp=function(r,e,t){return r.length},vT=(Zr={},Zr[se+"_"+Qe]=function(r,e,t){return Math.max(0,r.length-e)},Zr[se+"_"+Dn]=function(r,e,t){var a=r[0];return a?Math.max(0,a.length-e):0},Zr[Oe]=tp,Zr[er]=function(r,e,t){var a=t[0].name,n=r[a];return n?n.length:0},Zr[Ne]=tp,Zr);function rS(r,e){var t=vT[Gv(r,e)];return t}var Rl=function(r,e,t){return r[e]},fT=(Xr={},Xr[se]=Rl,Xr[Oe]=function(r,e,t){return r[t]},Xr[er]=Rl,Xr[Ne]=function(r,e,t){var a=mn(r);return a instanceof Array?a[e]:a},Xr[Er]=Rl,Xr);function aS(r){var e=fT[r];return e}function Gv(r,e){return r===se?r+"_"+e:r}function on(r,e,t){if(r){var a=r.getRawDataItem(e);if(a!=null){var n=r.getStore(),i=n.getSource().sourceFormat;if(t!=null){var o=r.getDimensionIndex(t),s=n.getDimensionProperty(o);return aS(i)(a,o,s)}else{var l=a;return i===Ne&&(l=mn(a)),l}}}}var hT=/\{@(.+?)\}/g,Fv=function(){function r(){}return r.prototype.getDataParams=function(e,t){var a=this.getData(t),n=this.getRawValue(e,t),i=a.getRawIndex(e),o=a.getName(e),s=a.getRawDataItem(e),l=a.getItemVisual(e,"style"),u=l&&l[a.getItemVisual(e,"drawType")||"fill"],c=l&&l.stroke,v=this.mainType,f=v==="series",h=a.userOutput&&a.userOutput.get();return{componentType:v,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:f?this.subType:null,seriesIndex:this.seriesIndex,seriesId:f?this.id:null,seriesName:f?this.name:null,name:o,dataIndex:i,data:s,dataType:t,value:n,color:u,borderColor:c,dimensionNames:h?h.fullDimensions:null,encode:h?h.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(e,t,a,n,i,o){t=t||"normal";var s=this.getData(a),l=this.getDataParams(e,a);if(o&&(l.value=o.interpolatedValue),n!=null&&O(l.value)&&(l.value=l.value[n]),!i){var u=s.getItemModel(e);i=u.get(t==="normal"?["label","formatter"]:[t,"label","formatter"])}if(X(i))return l.status=t,l.dimensionIndex=n,i(l);if($(i)){var c=O0(i,l);return c.replace(hT,function(v,f){var h=f.length,p=f;p.charAt(0)==="["&&p.charAt(h-1)==="]"&&(p=+p.slice(1,h-1));var d=on(s,e,p);if(o&&O(o.interpolatedValue)){var g=s.getDimensionIndex(p);g>=0&&(d=o.interpolatedValue[g])}return d!=null?d+"":""})}},r.prototype.getRawValue=function(e,t){return on(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,a){},r}();function ep(r){var e,t;return j(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function hi(r){return new pT(r)}var pT=function(){function r(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return r.prototype.perform=function(e){var t=this._upstream,a=e&&e.skip;if(this._dirty&&t){var n=this.context;n.data=n.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!a&&(i=this._plan(this.context));var o=c(this._modBy),s=this._modDataCount||0,l=c(e&&e.modBy),u=e&&e.modDataCount||0;(o!==l||s!==u)&&(i="reset");function c(m){return!(m>=1)&&(m=1),m}var v;(this._dirty||i==="reset")&&(this._dirty=!1,v=this._doReset(a)),this._modBy=l,this._modDataCount=u;var f=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var h=this._dueIndex,p=Math.min(f!=null?this._dueIndex+f:1/0,this._dueEnd);if(!a&&(v||h<p)){var d=this._progress;if(O(d))for(var g=0;g<d.length;g++)this._doProgress(d[g],h,p,l,u);else this._doProgress(d,h,p,l,u)}this._dueIndex=p;var y=this._settedOutputEnd!=null?this._settedOutputEnd:p;this._outputDueEnd=y}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(e,t,a,n,i){rp.reset(t,a,n,i),this._callingProgress=e,this._callingProgress({start:t,end:a,count:a-t,next:rp.next},this.context)},r.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var t,a;!e&&this._reset&&(t=this._reset(this.context),t&&t.progress&&(a=t.forceFirstProgress,t=t.progress),O(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var n=this._downstream;return n&&n.dirty(),a},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},r}(),rp=function(){var r,e,t,a,n,i={reset:function(l,u,c,v){e=l,r=u,t=c,a=v,n=Math.ceil(a/t),i.next=t>1&&a>0?s:o}};return i;function o(){return e<r?e++:null}function s(){var l=e%n*t+Math.ceil(e/n),u=e>=r?null:l<a?l:e;return e++,u}}();function Rr(r,e){var t=e&&e.type;return t==="ordinal"?r:(t==="time"&&!gt(r)&&r!=null&&r!=="-"&&(r=+tr(r)),r==null||r===""?NaN:+r)}var dT=Z({number:function(r){return parseFloat(r)},time:function(r){return+tr(r)},trim:function(r){return $(r)?Gi(r):r}});function nS(r){return dT.get(r)}var iS={lt:function(r,e){return r<e},lte:function(r,e){return r<=e},gt:function(r,e){return r>e},gte:function(r,e){return r>=e}},gT=function(){function r(e,t){if(!gt(t)){var a="";dt(a)}this._opFn=iS[e],this._rvalFloat=cr(t)}return r.prototype.evaluate=function(e){return gt(e)?this._opFn(e,this._rvalFloat):this._opFn(cr(e),this._rvalFloat)},r}(),oS=function(){function r(e,t){var a=e==="desc";this._resultLT=a?1:-1,t==null&&(t=a?"min":"max"),this._incomparable=t==="min"?-1/0:1/0}return r.prototype.evaluate=function(e,t){var a=gt(e)?e:cr(e),n=gt(t)?t:cr(t),i=isNaN(a),o=isNaN(n);if(i&&(a=this._incomparable),o&&(n=this._incomparable),i&&o){var s=$(e),l=$(t);s&&(a=l?e:0),l&&(n=s?t:0)}return a<n?this._resultLT:a>n?-this._resultLT:0},r}(),yT=function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=cr(t)}return r.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var a=typeof e;a!==this._rvalTypeof&&(a==="number"||this._rvalTypeof==="number")&&(t=cr(e)===this._rvalFloat)}return this._isEQ?t:!t},r}();function mT(r,e){return r==="eq"||r==="ne"?new yT(r==="eq",e):U(iS,r)?new gT(r,e):null}var ST=function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(e){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(e){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(e,t){},r.prototype.retrieveValueFromItem=function(e,t){},r.prototype.convertValue=function(e,t){return Rr(e,t)},r}();function xT(r,e){var t=new ST,a=r.data,n=t.sourceFormat=r.sourceFormat,i=r.startIndex,o="";r.seriesLayoutBy!==Qe&&dt(o);var s=[],l={},u=r.dimensionsDefine;if(u)w(u,function(d,g){var y=d.name,m={index:g,name:y,displayName:d.displayName};if(s.push(m),y!=null){var S="";U(l,y)&&dt(S),l[y]=m}});else for(var c=0;c<r.dimensionsDetectedCount;c++)s.push({index:c});var v=eS(n,Qe);e.__isBuiltIn&&(t.getRawDataItem=function(d){return v(a,i,s,d)},t.getRawData=W(_T,null,r)),t.cloneRawData=W(bT,null,r);var f=rS(n,Qe);t.count=W(f,null,a,i,s);var h=aS(n);t.retrieveValue=function(d,g){var y=v(a,i,s,d);return p(y,g)};var p=t.retrieveValueFromItem=function(d,g){if(d!=null){var y=s[g];if(y)return h(d,g,y.name)}};return t.getDimensionInfo=W(wT,null,s,l),t.cloneAllDimensionInfo=W(AT,null,s),t}function _T(r){var e=r.sourceFormat;if(!Hv(e)){var t="";dt(t)}return r.data}function bT(r){var e=r.sourceFormat,t=r.data;if(!Hv(e)){var a="";dt(a)}if(e===se){for(var n=[],i=0,o=t.length;i<o;i++)n.push(t[i].slice());return n}else if(e===Oe){for(var n=[],i=0,o=t.length;i<o;i++)n.push(B({},t[i]));return n}}function wT(r,e,t){if(t!=null){if(gt(t)||!isNaN(t)&&!U(e,t))return r[t];if(U(e,t))return e[t]}}function AT(r){return K(r)}var sS=Z();function TT(r){r=K(r);var e=r.type,t="";e||dt(t);var a=e.split(":");a.length!==2&&dt(t);var n=!1;a[0]==="echarts"&&(e=a[1],n=!0),r.__isBuiltIn=n,sS.set(e,r)}function CT(r,e,t){var a=_t(r),n=a.length,i="";n||dt(i);for(var o=0,s=n;o<s;o++){var l=a[o];e=DT(l,e),o!==s-1&&(e.length=Math.max(e.length,1))}return e}function DT(r,e,t,a){var n="";e.length||dt(n),j(r)||dt(n);var i=r.type,o=sS.get(i);o||dt(n);var s=G(e,function(u){return xT(u,o)}),l=_t(o.transform({upstream:s[0],upstreamList:s,config:K(r.config)}));return G(l,function(u,c){var v="";j(u)||dt(v),u.data||dt(v);var f=J0(u.data);Hv(f)||dt(v);var h,p=e[0];if(p&&c===0&&!u.dimensions){var d=p.startIndex;d&&(u.data=p.data.slice(0,d).concat(u.data)),h={seriesLayoutBy:Qe,sourceHeader:d,dimensions:p.metaRawOption.dimensions}}else h={seriesLayoutBy:Qe,sourceHeader:0,dimensions:u.dimensions};return bc(u.data,h,null)})}function Hv(r){return r===se||r===Oe}var il="undefined",MT=typeof Uint32Array===il?Array:Uint32Array,IT=typeof Uint16Array===il?Array:Uint16Array,lS=typeof Int32Array===il?Array:Int32Array,ap=typeof Float64Array===il?Array:Float64Array,uS={float:ap,int:lS,ordinal:Array,number:Array,time:ap},kl;function Nn(r){return r>65535?MT:IT}function Oa(){return[1/0,-1/0]}function LT(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function np(r,e,t,a,n){var i=uS[t||"float"];if(n){var o=r[e],s=o&&o.length;if(s!==a){for(var l=new i(a),u=0;u<s;u++)l[u]=o[u];r[e]=l}}else r[e]=new i(a)}var wc=function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=Z()}return r.prototype.initData=function(e,t,a){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var n=e.getSource(),i=this.defaultDimValueGetter=kl[n.sourceFormat];this._dimValueGetter=a||i,this._rawExtent=[],Q0(n),this._dimensions=G(t,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,e.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(e,t){var a=this._calcDimNameToIdx,n=this._dimensions,i=a.get(e);if(i!=null){if(n[i].type===t)return i}else i=n.length;return n[i]={type:t},a.set(e,i),this._chunks[i]=new uS[t||"float"](this._rawCount),this._rawExtent[i]=Oa(),i},r.prototype.collectOrdinalMeta=function(e,t){var a=this._chunks[e],n=this._dimensions[e],i=this._rawExtent,o=n.ordinalOffset||0,s=a.length;o===0&&(i[e]=Oa());for(var l=i[e],u=o;u<s;u++){var c=a[u]=t.parseAndCollect(a[u]);isNaN(c)||(l[0]=Math.min(c,l[0]),l[1]=Math.max(c,l[1]))}n.ordinalMeta=t,n.ordinalOffset=s,n.type="ordinal"},r.prototype.getOrdinalMeta=function(e){var t=this._dimensions[e],a=t.ordinalMeta;return a},r.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},r.prototype.appendData=function(e){var t=this._provider,a=this.count();t.appendData(e);var n=t.count();return t.persistent||(n+=a),a<n&&this._initDataFromProvider(a,n,!0),[a,n]},r.prototype.appendValues=function(e,t){for(var a=this._chunks,n=this._dimensions,i=n.length,o=this._rawExtent,s=this.count(),l=s+Math.max(e.length,t||0),u=0;u<i;u++){var c=n[u];np(a,u,c.type,l,!0)}for(var v=[],f=s;f<l;f++)for(var h=f-s,p=0;p<i;p++){var c=n[p],d=kl.arrayRows.call(this,e[h]||v,c.property,h,p);a[p][f]=d;var g=o[p];d<g[0]&&(g[0]=d),d>g[1]&&(g[1]=d)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(e,t,a){for(var n=this._provider,i=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=G(o,function(m){return m.property}),c=0;c<s;c++){var v=o[c];l[c]||(l[c]=Oa()),np(i,c,v.type,t,a)}if(n.fillStorage)n.fillStorage(e,t,i,l);else for(var f=[],h=e;h<t;h++){f=n.getItem(h,f);for(var p=0;p<s;p++){var d=i[p],g=this._dimValueGetter(f,u[p],h,p);d[h]=g;var y=l[p];g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=t,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var a=this._chunks[e];return a?a[this.getRawIndex(t)]:NaN},r.prototype.getValues=function(e,t){var a=[],n=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)n.push(i)}else n=e;for(var i=0,o=n.length;i<o;i++)a.push(this.get(n[i],t));return a},r.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var a=this._chunks[e];return a?a[t]:NaN},r.prototype.getSum=function(e){var t=this._chunks[e],a=0;if(t)for(var n=0,i=this.count();n<i;n++){var o=this.get(e,n);isNaN(o)||(a+=o)}return a},r.prototype.getMedian=function(e){var t=[];this.each([e],function(i){isNaN(i)||t.push(i)});var a=t.sort(function(i,o){return i-o}),n=this.count();return n===0?0:n%2===1?a[(n-1)/2]:(a[n/2]+a[n/2-1])/2},r.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,a=t[e];if(a!=null&&a<this._count&&a===e)return e;for(var n=0,i=this._count-1;n<=i;){var o=(n+i)/2|0;if(t[o]<e)n=o+1;else if(t[o]>e)i=o-1;else return o}return-1},r.prototype.indicesOfNearest=function(e,t,a){var n=this._chunks,i=n[e],o=[];if(!i)return o;a==null&&(a=1/0);for(var s=1/0,l=-1,u=0,c=0,v=this.count();c<v;c++){var f=this.getRawIndex(c),h=t-i[f],p=Math.abs(h);p<=a&&((p<s||p===s&&h>=0&&l<0)&&(s=p,l=h,u=0),h===l&&(o[u++]=c))}return o.length=u,o},r.prototype.getIndices=function(){var e,t=this._indices;if(t){var a=t.constructor,n=this._count;if(a===Array){e=new a(n);for(var i=0;i<n;i++)e[i]=t[i]}else e=new a(t.buffer,0,n)}else{var a=Nn(this._rawCount);e=new a(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},r.prototype.filter=function(e,t){if(!this._count)return this;for(var a=this.clone(),n=a.count(),i=Nn(a._rawCount),o=new i(n),s=[],l=e.length,u=0,c=e[0],v=a._chunks,f=0;f<n;f++){var h=void 0,p=a.getRawIndex(f);if(l===0)h=t(f);else if(l===1){var d=v[c][p];h=t(d,f)}else{for(var g=0;g<l;g++)s[g]=v[e[g]][p];s[g]=f,h=t.apply(null,s)}h&&(o[u++]=p)}return u<n&&(a._indices=o),a._count=u,a._extent=[],a._updateGetRawIdx(),a},r.prototype.selectRange=function(e){var t=this.clone(),a=t._count;if(!a)return this;var n=Wt(e),i=n.length;if(!i)return this;var o=t.count(),s=Nn(t._rawCount),l=new s(o),u=0,c=n[0],v=e[c][0],f=e[c][1],h=t._chunks,p=!1;if(!t._indices){var d=0;if(i===1){for(var g=h[n[0]],y=0;y<a;y++){var m=g[y];(m>=v&&m<=f||isNaN(m))&&(l[u++]=d),d++}p=!0}else if(i===2){for(var g=h[n[0]],S=h[n[1]],x=e[n[1]][0],b=e[n[1]][1],y=0;y<a;y++){var m=g[y],_=S[y];(m>=v&&m<=f||isNaN(m))&&(_>=x&&_<=b||isNaN(_))&&(l[u++]=d),d++}p=!0}}if(!p)if(i===1)for(var y=0;y<o;y++){var A=t.getRawIndex(y),m=h[n[0]][A];(m>=v&&m<=f||isNaN(m))&&(l[u++]=A)}else for(var y=0;y<o;y++){for(var T=!0,A=t.getRawIndex(y),C=0;C<i;C++){var M=n[C],m=h[M][A];(m<e[M][0]||m>e[M][1])&&(T=!1)}T&&(l[u++]=t.getRawIndex(y))}return u<o&&(t._indices=l),t._count=u,t._extent=[],t._updateGetRawIdx(),t},r.prototype.map=function(e,t){var a=this.clone(e);return this._updateDims(a,e,t),a},r.prototype.modify=function(e,t){this._updateDims(this,e,t)},r.prototype._updateDims=function(e,t,a){for(var n=e._chunks,i=[],o=t.length,s=e.count(),l=[],u=e._rawExtent,c=0;c<t.length;c++)u[t[c]]=Oa();for(var v=0;v<s;v++){for(var f=e.getRawIndex(v),h=0;h<o;h++)l[h]=n[t[h]][f];l[o]=v;var p=a&&a.apply(null,l);if(p!=null){typeof p!="object"&&(i[0]=p,p=i);for(var c=0;c<p.length;c++){var d=t[c],g=p[c],y=u[d],m=n[d];m&&(m[f]=g),g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}}},r.prototype.lttbDownSample=function(e,t){var a=this.clone([e],!0),n=a._chunks,i=n[e],o=this.count(),s=0,l=Math.floor(1/t),u=this.getRawIndex(0),c,v,f,h=new(Nn(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));h[s++]=u;for(var p=1;p<o-1;p+=l){for(var d=Math.min(p+l,o-1),g=Math.min(p+l*2,o),y=(g+d)/2,m=0,S=d;S<g;S++){var x=this.getRawIndex(S),b=i[x];isNaN(b)||(m+=b)}m/=g-d;var _=p,A=Math.min(p+l,o),T=p-1,C=i[u];c=-1,f=_;for(var M=-1,D=0,S=_;S<A;S++){var x=this.getRawIndex(S),b=i[x];if(isNaN(b)){D++,M<0&&(M=x);continue}v=Math.abs((T-y)*(b-C)-(T-S)*(m-C)),v>c&&(c=v,f=x)}D>0&&D<A-_&&(h[s++]=Math.min(M,f),f=Math.max(M,f)),h[s++]=f,u=f}return h[s++]=this.getRawIndex(o-1),a._count=s,a._indices=h,a.getRawIndex=this._getRawIdx,a},r.prototype.downSample=function(e,t,a,n){for(var i=this.clone([e],!0),o=i._chunks,s=[],l=Math.floor(1/t),u=o[e],c=this.count(),v=i._rawExtent[e]=Oa(),f=new(Nn(this._rawCount))(Math.ceil(c/l)),h=0,p=0;p<c;p+=l){l>c-p&&(l=c-p,s.length=l);for(var d=0;d<l;d++){var g=this.getRawIndex(p+d);s[d]=u[g]}var y=a(s),m=this.getRawIndex(Math.min(p+n(s,y)||0,c-1));u[m]=y,y<v[0]&&(v[0]=y),y>v[1]&&(v[1]=y),f[h++]=m}return i._count=h,i._indices=f,i._updateGetRawIdx(),i},r.prototype.each=function(e,t){if(this._count)for(var a=e.length,n=this._chunks,i=0,o=this.count();i<o;i++){var s=this.getRawIndex(i);switch(a){case 0:t(i);break;case 1:t(n[e[0]][s],i);break;case 2:t(n[e[0]][s],n[e[1]][s],i);break;default:for(var l=0,u=[];l<a;l++)u[l]=n[e[l]][s];u[l]=i,t.apply(null,u)}}},r.prototype.getDataExtent=function(e){var t=this._chunks[e],a=Oa();if(!t)return a;var n=this.count(),i=!this._indices,o;if(i)return this._rawExtent[e].slice();if(o=this._extent[e],o)return o.slice();o=a;for(var s=o[0],l=o[1],u=0;u<n;u++){var c=this.getRawIndex(u),v=t[c];v<s&&(s=v),v>l&&(l=v)}return o=[s,l],this._extent[e]=o,o},r.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var a=[],n=this._chunks,i=0;i<n.length;i++)a.push(n[i][t]);return a},r.prototype.clone=function(e,t){var a=new r,n=this._chunks,i=e&&rn(e,function(s,l){return s[l]=!0,s},{});if(i)for(var o=0;o<n.length;o++)a._chunks[o]=i[o]?LT(n[o]):n[o];else a._chunks=n;return this._copyCommonProps(a),t||(a._indices=this._cloneIndices()),a._updateGetRawIdx(),a},r.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=K(this._extent),e._rawExtent=K(this._rawExtent)},r.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var a=this._indices.length;t=new e(a);for(var n=0;n<a;n++)t[n]=this._indices[n]}else t=new e(this._indices);return t}return null},r.prototype._getRawIdxIdentity=function(e){return e},r.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=function(){function e(t,a,n,i){return Rr(t[i],this._dimensions[i])}kl={arrayRows:e,objectRows:function(t,a,n,i){return Rr(t[a],this._dimensions[i])},keyedColumns:e,original:function(t,a,n,i){var o=t&&(t.value==null?t:t.value);return Rr(o instanceof Array?o[i]:o,this._dimensions[i])},typedArray:function(t,a,n,i){return t[i]}}}(),r}(),cS=function(){function r(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),a=!!t.length,n,i;if(co(e)){var o=e,s=void 0,l=void 0,u=void 0;if(a){var c=t[0];c.prepareSource(),u=c.getSource(),s=u.data,l=u.sourceFormat,i=[c._getVersionSign()]}else s=o.get("data",!0),l=Re(s)?Er:Ne,i=[];var v=this._getSourceMetaRawOption()||{},f=u&&u.metaRawOption||{},h=St(v.seriesLayoutBy,f.seriesLayoutBy)||null,p=St(v.sourceHeader,f.sourceHeader),d=St(v.dimensions,f.dimensions),g=h!==f.seriesLayoutBy||!!p!=!!f.sourceHeader||d;n=g?[bc(s,{seriesLayoutBy:h,sourceHeader:p,dimensions:d},l)]:[]}else{var y=e;if(a){var m=this._applyTransform(t);n=m.sourceList,i=m.upstreamSignList}else{var S=y.get("source",!0);n=[bc(S,this._getSourceMetaRawOption(),null)],i=[]}}this._setLocalSource(n,i)},r.prototype._applyTransform=function(e){var t=this._sourceHost,a=t.get("transform",!0),n=t.get("fromTransformResult",!0);if(n!=null){var i="";e.length!==1&&op(i)}var o,s=[],l=[];return w(e,function(u){u.prepareSource();var c=u.getSource(n||0),v="";n!=null&&!c&&op(v),s.push(c),l.push(u._getVersionSign())}),a?o=CT(a,s,{datasetIndex:t.componentIndex}):n!=null&&(o=[sT(s[0])]),{sourceList:o,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var a=e[t];if(a._isDirty()||this._upstreamSignList[t]!==a._getVersionSign())return!0}},r.prototype.getSource=function(e){e=e||0;var t=this._sourceList[e];if(!t){var a=this._getUpstreamSourceManagers();return a[0]&&a[0].getSource(e)}return t},r.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},r.prototype._innerGetDataStore=function(e,t,a){var n=0,i=this._storeList,o=i[n];o||(o=i[n]={});var s=o[a];if(!s){var l=this._getUpstreamSourceManagers()[0];co(this._sourceHost)&&l?s=l._innerGetDataStore(e,t,a):(s=new wc,s.initData(new tS(t,e.length),e)),o[a]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(co(e)){var t=Ov(e);return t?[t.getSourceManager()]:[]}else return G(RA(e),function(a){return a.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,a,n;if(co(e))t=e.get("seriesLayoutBy",!0),a=e.get("sourceHeader",!0),n=e.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get("seriesLayoutBy",!0),a=i.get("sourceHeader",!0),n=i.get("dimensions",!0)}return{seriesLayoutBy:t,sourceHeader:a,dimensions:n}},r}();function ip(r){var e=r.option.transform;e&&ss(r.option.transform)}function co(r){return r.mainType==="series"}function op(r){throw new Error(r)}var vS="line-height:1";function fS(r,e){var t=r.color||"#6e7079",a=r.fontSize||12,n=r.fontWeight||"400",i=r.color||"#464646",o=r.fontSize||14,s=r.fontWeight||"900";return e==="html"?{nameStyle:"font-size:"+ge(a+"")+"px;color:"+ge(t)+";font-weight:"+ge(n+""),valueStyle:"font-size:"+ge(o+"")+"px;color:"+ge(i)+";font-weight:"+ge(s+"")}:{nameStyle:{fontSize:a,fill:t,fontWeight:n},valueStyle:{fontSize:o,fill:i,fontWeight:s}}}var PT=[0,10,20,30],ET=["",`
`,`

`,`


`];function qt(r,e){return e.type=r,e}function Ac(r){return r.type==="section"}function hS(r){return Ac(r)?RT:kT}function pS(r){if(Ac(r)){var e=0,t=r.blocks.length,a=t>1||t>0&&!r.noHeader;return w(r.blocks,function(n){var i=pS(n);i>=e&&(e=i+ +(a&&(!i||Ac(n)&&!n.noHeader)))}),e}return 0}function RT(r,e,t,a){var n=e.noHeader,i=NT(pS(e)),o=[],s=e.blocks||[];ye(!s||O(s)),s=s||[];var l=r.orderMode;if(e.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(U(u,l)){var c=new oS(u[l],null);s.sort(function(p,d){return c.evaluate(p.sortParam,d.sortParam)})}else l==="seriesDesc"&&s.reverse()}w(s,function(p,d){var g=e.valueFormatter,y=hS(p)(g?B(B({},r),{valueFormatter:g}):r,p,d>0?i.html:0,a);y!=null&&o.push(y)});var v=r.renderMode==="richText"?o.join(i.richText):Tc(o.join(""),n?t:i.html);if(n)return v;var f=Sc(e.header,"ordinal",r.useUTC),h=fS(a,r.renderMode).nameStyle;return r.renderMode==="richText"?dS(r,f,h)+i.richText+v:Tc('<div style="'+h+";"+vS+';">'+ge(f)+"</div>"+v,t)}function kT(r,e,t,a){var n=r.renderMode,i=e.noName,o=e.noValue,s=!e.markerType,l=e.name,u=r.useUTC,c=e.valueFormatter||r.valueFormatter||function(x){return x=O(x)?x:[x],G(x,function(b,_){return Sc(b,O(h)?h[_]:h,u)})};if(!(i&&o)){var v=s?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",n),f=i?"":Sc(l,"ordinal",u),h=e.valueType,p=o?[]:c(e.value),d=!s||!i,g=!s&&i,y=fS(a,n),m=y.nameStyle,S=y.valueStyle;return n==="richText"?(s?"":v)+(i?"":dS(r,f,m))+(o?"":BT(r,p,d,g,S)):Tc((s?"":v)+(i?"":OT(f,!s,m))+(o?"":VT(p,d,g,S)),t)}}function sp(r,e,t,a,n,i){if(r){var o=hS(r),s={useUTC:n,renderMode:t,orderMode:a,markupStyleCreator:e,valueFormatter:r.valueFormatter};return o(s,r,0,i)}}function NT(r){return{html:PT[r],richText:ET[r]}}function Tc(r,e){var t='<div style="clear:both"></div>',a="margin: "+e+"px 0 0";return'<div style="'+a+";"+vS+';">'+r+t+"</div>"}function OT(r,e,t){var a=e?"margin-left:2px":"";return'<span style="'+t+";"+a+'">'+ge(r)+"</span>"}function VT(r,e,t,a){var n=t?"10px":"20px",i=e?"float:right;margin-left:"+n:"";return r=O(r)?r:[r],'<span style="'+i+";"+a+'">'+G(r,function(o){return ge(o)}).join("&nbsp;&nbsp;")+"</span>"}function dS(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function BT(r,e,t,a,n){var i=[n],o=a?10:20;return t&&i.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(O(e)?e.join("  "):e,i)}function gS(r,e){var t=r.getData().getItemVisual(e,"style"),a=t[r.visualDrawType];return Ta(a)}function yS(r,e){var t=r.get("padding");return t??(e==="richText"?[8,10]:10)}var Nl=function(){function r(){this.richTextStyles={},this._nextStyleNameId=Zm()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(e,t,a){var n=a==="richText"?this._generateStyleName():null,i=CA({color:t,type:e,renderMode:a,markerId:n});return $(i)?i:(this.richTextStyles[n]=i.style,i.content)},r.prototype.wrapRichTextStyle=function(e,t){var a={};O(t)?w(t,function(i){return B(a,i)}):B(a,t);var n=this._generateStyleName();return this.richTextStyles[n]=a,"{"+n+"|"+e+"}"},r}();function mS(r){var e=r.series,t=r.dataIndex,a=r.multipleSeries,n=e.getData(),i=n.mapDimensionsAll("defaultedTooltip"),o=i.length,s=e.getRawValue(t),l=O(s),u=gS(e,t),c,v,f,h;if(o>1||l&&!o){var p=zT(s,e,t,i,u);c=p.inlineValues,v=p.inlineValueTypes,f=p.blocks,h=p.inlineValues[0]}else if(o){var d=n.getDimensionInfo(i[0]);h=c=on(n,t,i[0]),v=d.type}else h=c=l?s[0]:s;var g=Sv(e),y=g&&e.name||"",m=n.getName(t),S=a?y:m;return qt("section",{header:y,noHeader:a||!g,sortParam:h,blocks:[qt("nameValue",{markerType:"item",markerColor:u,name:S,noName:!Gi(S),value:c,valueType:v})].concat(f||[])})}function zT(r,e,t,a,n){var i=e.getData(),o=rn(r,function(v,f,h){var p=i.getDimensionInfo(h);return v=v||p&&p.tooltip!==!1&&p.displayName!=null},!1),s=[],l=[],u=[];a.length?w(a,function(v){c(on(i,t,v),v)}):w(r,c);function c(v,f){var h=i.getDimensionInfo(f);!h||h.otherDims.tooltip===!1||(o?u.push(qt("nameValue",{markerType:"subItem",markerColor:n,name:h.displayName,value:v,valueType:h.type})):(s.push(v),l.push(h.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var xr=st();function vo(r,e){return r.getName(e)||r.getId(e)}var Jo="__universalTransitionEnabled",ol=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return e.prototype.init=function(t,a,n){this.seriesIndex=this.componentIndex,this.dataTask=hi({count:FT,reset:HT}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);var i=xr(this).sourceManager=new cS(this);i.prepareSource();var o=this.getInitialData(t,n);up(o,this),this.dataTask.context.data=o,xr(this).dataBeforeProcessed=o,lp(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=Ti(this),i=n?Tn(t):{},o=this.subType;lt.hasClass(o)&&(o+="Series"),ot(t,a.getTheme().get(this.subType)),ot(t,this.getDefaultOption()),_a(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Vr(t,i,n)},e.prototype.mergeOption=function(t,a){t=ot(this.option,t,!0),this.fillDataTextStyle(t.data);var n=Ti(this);n&&Vr(this.option,t,n);var i=xr(this).sourceManager;i.dirty(),i.prepareSource();var o=this.getInitialData(t,a);up(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,xr(this).dataBeforeProcessed=o,lp(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(t){if(t&&!Re(t))for(var a=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&_a(t[n],"label",a)},e.prototype.getInitialData=function(t,a){},e.prototype.appendData=function(t){var a=this.getRawData();a.appendData(t.data)},e.prototype.getData=function(t){var a=Cc(this);if(a){var n=a.context.data;return t==null?n:n.getLinkedData(t)}else return xr(this).data},e.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},e.prototype.setData=function(t){var a=Cc(this);if(a){var n=a.context;n.outputData=t,a!==this.dataTask&&(n.data=t)}xr(this).data=t},e.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return Z(t)},e.prototype.getSourceManager=function(){return xr(this).sourceManager},e.prototype.getSource=function(){return this.getSourceManager().getSource()},e.prototype.getRawData=function(){return xr(this).dataBeforeProcessed},e.prototype.getColorBy=function(){var t=this.get("colorBy");return t||"series"},e.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},e.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},e.prototype.formatTooltip=function(t,a,n){return mS({series:this,dataIndex:t,multipleSeries:a})},e.prototype.isAnimationEnabled=function(){var t=this.ecModel;if(kt.node&&!(t&&t.ssr))return!1;var a=this.getShallow("animation");return a&&this.getData().count()>this.getShallow("animationThreshold")&&(a=!1),!!a},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,a,n){var i=this.ecModel,o=Vv.prototype.getColorFromPalette.call(this,t,a,n);return o||(o=i.getColorFromPalette(t,a,n)),o},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,a){this._innerSelect(this.getData(a),t)},e.prototype.unselect=function(t,a){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,o=this.getData(a);if(i==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<t.length;s++){var l=t[s],u=vo(o,l);n[u]=!1,this._selectedDataIndicesMap[u]=-1}}},e.prototype.toggleSelect=function(t,a){for(var n=[],i=0;i<t.length;i++)n[0]=t[i],this.isSelected(t[i],a)?this.unselect(n,a):this.select(n,a)},e.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,a=Wt(t),n=[],i=0;i<a.length;i++){var o=t[a[i]];o>=0&&n.push(o)}return n},e.prototype.isSelected=function(t,a){var n=this.option.selectedMap;if(!n)return!1;var i=this.getData(a);return(n==="all"||n[vo(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[Jo])return!0;var t=this.option.universalTransition;return t?t===!0?!0:t&&t.enabled:!1},e.prototype._innerSelect=function(t,a){var n,i,o=this.option,s=o.selectedMode,l=a.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){j(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,c=0;c<l;c++){var v=a[c],f=vo(t,v);u[f]=!0,this._selectedDataIndicesMap[f]=t.getRawIndex(v)}}else if(s==="single"||s===!0){var h=a[l-1],f=vo(t,h);o.selectedMap=(n={},n[f]=!0,n),this._selectedDataIndicesMap=(i={},i[f]=t.getRawIndex(h),i)}}},e.prototype._initSelectedMapFromData=function(t){if(!this.option.selectedMap){var a=[];t.hasItemOption&&t.each(function(n){var i=t.getRawDataItem(n);i&&i.selected&&a.push(n)}),a.length>0&&this._innerSelect(t,a)}},e.registerClass=function(t){return lt.registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(lt);jt(ol,Fv);jt(ol,Vv);r0(ol,lt);function lp(r){var e=r.name;Sv(r)||(r.name=GT(r)||e)}function GT(r){var e=r.getRawData(),t=e.mapDimensionsAll("seriesName"),a=[];return w(t,function(n){var i=e.getDimensionInfo(n);i.displayName&&a.push(i.displayName)}),a.join(" ")}function FT(r){return r.model.getRawData().count()}function HT(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),WT}function WT(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function up(r,e){w(ls(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,Q($T,e))})}function $T(r,e){var t=Cc(r);return t&&t.setOutputEnd((e||this).count()),e}function Cc(r){var e=(r.ecModel||{}).scheduler,t=e&&e.getPipeline(r.uid);if(t){var a=t.currentTask;if(a){var n=a.agentStubMap;n&&(a=n.get(r.uid))}return a}}const Et=ol;var Wv=function(){function r(){this.group=new tt,this.uid=wn("viewComponent")}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,a,n){},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,a,n){},r.prototype.updateLayout=function(e,t,a,n){},r.prototype.updateVisual=function(e,t,a,n){},r.prototype.toggleBlurSeries=function(e,t,a){},r.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},r}();_v(Wv);Ys(Wv);const Ot=Wv;function Mn(){var r=st();return function(e){var t=r(e),a=e.pipelineContext,n=!!t.large,i=!!t.progressiveRender,o=t.large=!!(a&&a.large),s=t.progressiveRender=!!(a&&a.progressiveRender);return(n!==o||i!==s)&&"reset"}}var SS=st(),UT=Mn(),$v=function(){function r(){this.group=new tt,this.uid=wn("viewChart"),this.renderTask=hi({plan:YT,reset:ZT}),this.renderTask.context={view:this}}return r.prototype.init=function(e,t){},r.prototype.render=function(e,t,a,n){},r.prototype.highlight=function(e,t,a,n){var i=e.getData(n&&n.dataType);i&&vp(i,n,"emphasis")},r.prototype.downplay=function(e,t,a,n){var i=e.getData(n&&n.dataType);i&&vp(i,n,"normal")},r.prototype.remove=function(e,t){this.group.removeAll()},r.prototype.dispose=function(e,t){},r.prototype.updateView=function(e,t,a,n){this.render(e,t,a,n)},r.prototype.updateLayout=function(e,t,a,n){this.render(e,t,a,n)},r.prototype.updateVisual=function(e,t,a,n){this.render(e,t,a,n)},r.prototype.eachRendered=function(e){Wr(this.group,e)},r.markUpdateMethod=function(e,t){SS(e).updateMethod=t},r.protoInitialize=function(){var e=r.prototype;e.type="chart"}(),r}();function cp(r,e,t){r&&_i(r)&&(e==="emphasis"?vr:fr)(r,t)}function vp(r,e,t){var a=ba(r,e),n=e&&e.highlightKey!=null?Kw(e.highlightKey):null;a!=null?w(_t(a),function(i){cp(r.getItemGraphicEl(i),t,n)}):r.eachItemGraphicEl(function(i){cp(i,t,n)})}_v($v);Ys($v);function YT(r){return UT(r.model)}function ZT(r){var e=r.model,t=r.ecModel,a=r.api,n=r.payload,i=e.pipelineContext.progressiveRender,o=r.view,s=n&&SS(n).updateMethod,l=i?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,t,a,n),XT[l]}var XT={incrementalPrepareRender:{progress:function(r,e){e.view.incrementalRender(r,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(r,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}};const Mt=$v;var Ss="\0__throttleOriginMethod",fp="\0__throttleRate",hp="\0__throttleType";function Uv(r,e,t){var a,n=0,i=0,o=null,s,l,u,c;e=e||0;function v(){i=new Date().getTime(),o=null,r.apply(l,u||[])}var f=function(){for(var h=[],p=0;p<arguments.length;p++)h[p]=arguments[p];a=new Date().getTime(),l=this,u=h;var d=c||e,g=c||t;c=null,s=a-(g?n:i)-d,clearTimeout(o),g?o=setTimeout(v,d):s>=0?v():o=setTimeout(v,-s),n=a};return f.clear=function(){o&&(clearTimeout(o),o=null)},f.debounceNextCall=function(h){c=h},f}function In(r,e,t,a){var n=r[e];if(n){var i=n[Ss]||n,o=n[hp],s=n[fp];if(s!==t||o!==a){if(t==null||!a)return r[e]=i;n=r[e]=Uv(i,t,a==="debounce"),n[Ss]=i,n[hp]=a,n[fp]=t}return n}}function Di(r,e){var t=r[e];t&&t[Ss]&&(t.clear&&t.clear(),r[e]=t[Ss])}var pp=st(),dp={itemStyle:wa(w0,!0),lineStyle:wa(b0,!0)},KT={lineStyle:"stroke",itemStyle:"fill"};function xS(r,e){var t=r.visualStyleMapper||dp[e];return t||(console.warn("Unknown style type '"+e+"'."),dp.itemStyle)}function _S(r,e){var t=r.visualDrawType||KT[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var qT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=r.getModel(a),i=xS(r,a),o=i(n),s=n.getShallow("decal");s&&(t.setVisual("decal",s),s.dirty=!0);var l=_S(r,a),u=o[l],c=X(u)?u:null,v=o.fill==="auto"||o.stroke==="auto";if(!o[l]||c||v){var f=r.getColorFromPalette(r.name,null,e.getSeriesCount());o[l]||(o[l]=f,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||X(o.fill)?f:o.fill,o.stroke=o.stroke==="auto"||X(o.stroke)?f:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&c)return t.setVisual("colorFromPalette",!1),{dataEach:function(h,p){var d=r.getDataParams(p),g=B({},o);g[l]=c(d),h.setItemVisual(p,"style",g)}}}},On=new Dt,jT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!(r.ignoreStyleOnData||e.isSeriesFiltered(r))){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=xS(r,a),i=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[a]){On.option=l[a];var u=n(On),c=o.ensureUniqueItemVisual(s,"style");B(c,u),On.option.decal&&(o.setItemVisual(s,"decal",On.option.decal),On.option.decal.dirty=!0),i in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},JT={performRawSeries:!0,overallReset:function(r){var e=Z();r.eachSeries(function(t){var a=t.getColorBy();if(!t.isColorBySeries()){var n=t.type+"-"+a,i=e.get(n);i||(i={},e.set(n,i)),pp(t).scope=i}}),r.eachSeries(function(t){if(!(t.isColorBySeries()||r.isSeriesFiltered(t))){var a=t.getRawData(),n={},i=t.getData(),o=pp(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=_S(t,s);i.each(function(u){var c=i.getRawIndex(u);n[c]=u}),a.each(function(u){var c=n[u],v=i.getItemVisual(c,"colorFromPalette");if(v){var f=i.ensureUniqueItemVisual(c,"style"),h=a.getName(u)||u+"",p=a.count();f[l]=t.getColorFromPalette(h,o,p)}})}})}},fo=Math.PI;function QT(r,e){e=e||{},J(e,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var t=new tt,a=new ht({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(a);var n=new ut({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),i=new ht({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});t.add(i);var o;return e.showSpinner&&(o=new gv({shape:{startAngle:-fo/2,endAngle:-fo/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:fo*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:fo*3/2}).delay(300).start("circularInOut"),t.add(o)),t.resize=function(){var s=n.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(r.getWidth()-l*2-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),c=r.getHeight()/2;e.showSpinner&&o.setShape({cx:u,cy:c}),i.setShape({x:u-l,y:c-l,width:l*2,height:l*2}),a.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},t.resize(),t}var tC=function(){function r(e,t,a,n){this._stageTaskMap=Z(),this.ecInstance=e,this.api=t,a=this._dataProcessorHandlers=a.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=a.concat(n)}return r.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(a){var n=a.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var a=this._pipelineMap.get(e.__pipeline.id),n=a.context,i=!t&&a.progressiveEnabled&&(!n||n.progressiveRender)&&e.__idxInPipeline>a.blockIndex,o=i?a.step:null,s=n&&n.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},r.prototype.updateStreamModes=function(e,t){var a=this._pipelineMap.get(e.uid),n=e.getData(),i=n.count(),o=a.progressiveEnabled&&t.incrementalPrepareRender&&i>=a.threshold,s=e.get("large")&&i>=e.get("largeThreshold"),l=e.get("progressiveChunkMode")==="mod"?i:null;e.pipelineContext=a.context={progressiveRender:o,modDataCount:l,large:s}},r.prototype.restorePipelines=function(e){var t=this,a=t._pipelineMap=Z();e.eachSeries(function(n){var i=n.getProgressive(),o=n.uid;a.set(o,{id:o,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:i&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),t._pipe(n,n.dataTask)})},r.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),a=this.api;w(this._allHandlers,function(n){var i=e.get(n.uid)||e.set(n.uid,{}),o="";ye(!(n.reset&&n.overallReset),o),n.reset&&this._createSeriesStageTask(n,i,t,a),n.overallReset&&this._createOverallStageTask(n,i,t,a)},this)},r.prototype.prepareView=function(e,t,a,n){var i=e.renderTask,o=i.context;o.model=t,o.ecModel=a,o.api=n,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},r.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},r.prototype.performVisualTasks=function(e,t,a){this._performStageTasks(this._visualHandlers,e,t,a)},r.prototype._performStageTasks=function(e,t,a,n){n=n||{};var i=!1,o=this;w(e,function(l,u){if(!(n.visualType&&n.visualType!==l.visualType)){var c=o._stageTaskMap.get(l.uid),v=c.seriesTaskMap,f=c.overallTask;if(f){var h,p=f.agentStubMap;p.each(function(g){s(n,g)&&(g.dirty(),h=!0)}),h&&f.dirty(),o.updatePayload(f,a);var d=o.getPerformArgs(f,n.block);p.each(function(g){g.perform(d)}),f.perform(d)&&(i=!0)}else v&&v.each(function(g,y){s(n,g)&&g.dirty();var m=o.getPerformArgs(g,n.block);m.skip=!l.performRawSeries&&t.isSeriesFiltered(g.context.model),o.updatePayload(g,a),g.perform(m)&&(i=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=i||this.unfinished},r.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(a){t=a.dataTask.perform()||t}),this.unfinished=t||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},r.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},r.prototype._createSeriesStageTask=function(e,t,a,n){var i=this,o=t.seriesTaskMap,s=t.seriesTaskMap=Z(),l=e.seriesType,u=e.getTargetSeries;e.createOnAllSeries?a.eachRawSeries(c):l?a.eachRawSeriesByType(l,c):u&&u(a,n).each(c);function c(v){var f=v.uid,h=s.set(f,o&&o.get(f)||hi({plan:iC,reset:oC,count:lC}));h.context={model:v,ecModel:a,api:n,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(v,h)}},r.prototype._createOverallStageTask=function(e,t,a,n){var i=this,o=t.overallTask=t.overallTask||hi({reset:eC});o.context={ecModel:a,api:n,overallReset:e.overallReset,scheduler:i};var s=o.agentStubMap,l=o.agentStubMap=Z(),u=e.seriesType,c=e.getTargetSeries,v=!0,f=!1,h="";ye(!e.createOnAllSeries,h),u?a.eachRawSeriesByType(u,p):c?c(a,n).each(p):(v=!1,w(a.getSeries(),p));function p(d){var g=d.uid,y=l.set(g,s&&s.get(g)||(f=!0,hi({reset:rC,onDirty:nC})));y.context={model:d,overallProgress:v},y.agent=o,y.__block=v,i._pipe(d,y)}f&&o.dirty()},r.prototype._pipe=function(e,t){var a=e.uid,n=this._pipelineMap.get(a);!n.head&&(n.head=t),n.tail&&n.tail.pipe(t),n.tail=t,t.__idxInPipeline=n.count++,t.__pipeline=n},r.wrapStageHandler=function(e,t){return X(e)&&(e={overallReset:e,seriesType:uC(e)}),e.uid=wn("stageHandler"),t&&(e.visualType=t),e},r}();function eC(r){r.overallReset(r.ecModel,r.api,r.payload)}function rC(r){return r.overallProgress&&aC}function aC(){this.agent.dirty(),this.getDownstream().dirty()}function nC(){this.agent&&this.agent.dirty()}function iC(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function oC(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=_t(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?G(e,function(t,a){return bS(a)}):sC}var sC=bS(0);function bS(r){return function(e,t){var a=t.data,n=t.resetDefines[r];if(n&&n.dataEach)for(var i=e.start;i<e.end;i++)n.dataEach(a,i);else n&&n.progress&&n.progress(e,a)}}function lC(r){return r.data.count()}function uC(r){xs=null;try{r(Mi,wS)}catch{}return xs}var Mi={},wS={},xs;AS(Mi,X0);AS(wS,K0);Mi.eachSeriesByType=Mi.eachRawSeriesByType=function(r){xs=r};Mi.eachComponent=function(r){r.mainType==="series"&&r.subType&&(xs=r.subType)};function AS(r,e){for(var t in e.prototype)r[t]=he}const TS=tC;var gp=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"];const cC={color:gp,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],gp]};var ue="#B9B8CE",yp="#100C2A",ho=function(){return{axisLine:{lineStyle:{color:ue}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}},mp=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],CS={darkMode:!0,color:mp,backgroundColor:yp,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:ue}},textStyle:{color:ue},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:ue}},dataZoom:{borderColor:"#71708A",textStyle:{color:ue},brushStyle:{color:"rgba(135,163,206,0.3)"},handleStyle:{color:"#353450",borderColor:"#C5CBE3"},moveHandleStyle:{color:"#B0B6C3",opacity:.3},fillerColor:"rgba(135,163,206,0.2)",emphasis:{handleStyle:{borderColor:"#91B7F2",color:"#4D587D"},moveHandleStyle:{color:"#636D9A",opacity:.7}},dataBackground:{lineStyle:{color:"#71708A",width:1},areaStyle:{color:"#71708A"}},selectedDataBackground:{lineStyle:{color:"#87A3CE"},areaStyle:{color:"#87A3CE"}}},visualMap:{textStyle:{color:ue}},timeline:{lineStyle:{color:ue},label:{color:ue},controlStyle:{color:ue,borderColor:ue}},calendar:{itemStyle:{color:yp},dayLabel:{color:ue},monthLabel:{color:ue},yearLabel:{color:ue}},timeAxis:ho(),logAxis:ho(),valueAxis:ho(),categoryAxis:ho(),line:{symbol:"circle"},graph:{color:mp},gauge:{title:{color:ue},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:ue},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};CS.categoryAxis.splitLine.show=!1;const vC=CS;var fC=function(){function r(){}return r.prototype.normalizeQuery=function(e){var t={},a={},n={};if($(e)){var i=qe(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};w(e,function(l,u){for(var c=!1,v=0;v<o.length;v++){var f=o[v],h=u.lastIndexOf(f);if(h>0&&h===u.length-f.length){var p=u.slice(0,h);p!=="data"&&(t.mainType=p,t[f.toLowerCase()]=l,c=!0)}}s.hasOwnProperty(u)&&(a[u]=l,c=!0),c||(n[u]=l)})}return{cptQuery:t,dataQuery:a,otherQuery:n}},r.prototype.filter=function(e,t){var a=this.eventInfo;if(!a)return!0;var n=a.targetEl,i=a.packedEvent,o=a.model,s=a.view;if(!o||!s)return!0;var l=t.cptQuery,u=t.dataQuery;return c(l,o,"mainType")&&c(l,o,"subType")&&c(l,o,"index","componentIndex")&&c(l,o,"name")&&c(l,o,"id")&&c(u,i,"name")&&c(u,i,"dataIndex")&&c(u,i,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,t.otherQuery,n,i));function c(v,f,h,p){return v[h]==null||f[p||h]===v[h]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r}(),Dc=["symbol","symbolSize","symbolRotate","symbolOffset"],Sp=Dc.concat(["symbolKeepAspect"]),hC={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData();if(r.legendIcon&&t.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var a={},n={},i=!1,o=0;o<Dc.length;o++){var s=Dc[o],l=r.get(s);X(l)?(i=!0,n[s]=l):a[s]=l}if(a.symbol=a.symbol||r.defaultSymbol,t.setVisual(B({legendIcon:r.legendIcon||a.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},a)),e.isSeriesFiltered(r))return;var u=Wt(n);function c(v,f){for(var h=r.getRawValue(f),p=r.getDataParams(f),d=0;d<u.length;d++){var g=u[d];v.setItemVisual(f,g,n[g](h,p))}}return{dataEach:i?c:null}}},pC={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!r.hasSymbolVisual||e.isSeriesFiltered(r))return;var t=r.getData();function a(n,i){for(var o=n.getItemModel(i),s=0;s<Sp.length;s++){var l=Sp[s],u=o.getShallow(l,!0);u!=null&&n.setItemVisual(i,l,u)}}return{dataEach:t.hasItemOption?a:null}}};function Yv(r,e,t){switch(t){case"color":var a=r.getItemVisual(e,"style");return a[r.getVisual("drawType")];case"opacity":return r.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(e,t)}}function Ki(r,e){switch(e){case"color":var t=r.getVisual("style");return t[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(e)}}function DS(r,e,t,a){switch(t){case"color":var n=r.ensureUniqueItemVisual(e,"style");n[r.getVisual("drawType")]=a,r.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":r.ensureUniqueItemVisual(e,"style").opacity=a;break;case"symbol":case"symbolSize":case"liftZ":r.setItemVisual(e,t,a);break}}function MS(r,e){function t(a,n){var i=[];return a.eachComponent({mainType:"series",subType:r,query:n},function(o){i.push(o.seriesIndex)}),i}w([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(a){e(a[0],function(n,i,o){n=B({},n),o.dispatchAction(B(n,{type:a[1],seriesIndex:t(i,n)}))})})}function Va(r,e,t,a,n){var i=r+e;t.isSilent(i)||a.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=n.selected,c=0;c<u.length;c++)if(u[c].seriesIndex===s){var v=o.getData(),f=ba(v,n.fromActionPayload);t.trigger(i,{type:i,seriesId:o.id,name:O(f)?v.getName(f[0]):v.getName(f),selected:$(l)?l:B({},l)})}})}function dC(r,e,t){r.on("selectchanged",function(a){var n=t.getModel();a.isFromClick?(Va("map","selectchanged",e,n,a),Va("pie","selectchanged",e,n,a)):a.fromAction==="select"?(Va("map","selected",e,n,a),Va("pie","selected",e,n,a)):a.fromAction==="unselect"&&(Va("map","unselected",e,n,a),Va("pie","unselected",e,n,a))})}function ca(r,e,t){for(var a;r&&!(e(r)&&(a=r,t));)r=r.__hostTarget||r.parent;return a}var gC=It.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,a=e.cy,n=e.width/2,i=e.height/2;r.moveTo(t,a-i),r.lineTo(t+n,a+i),r.lineTo(t-n,a+i),r.closePath()}}),yC=It.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,e){var t=e.cx,a=e.cy,n=e.width/2,i=e.height/2;r.moveTo(t,a-i),r.lineTo(t+n,a),r.lineTo(t,a+i),r.lineTo(t-n,a),r.closePath()}}),mC=It.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.x,a=e.y,n=e.width/5*3,i=Math.max(n,e.height),o=n/2,s=o*o/(i-o),l=a-i+o+s,u=Math.asin(s/o),c=Math.cos(u)*o,v=Math.sin(u),f=Math.cos(u),h=o*.6,p=o*.7;r.moveTo(t-c,l+s),r.arc(t,l,o,Math.PI-u,Math.PI*2+u),r.bezierCurveTo(t+c-v*h,l+s+f*h,t,a-p,t,a),r.bezierCurveTo(t,a-p,t-c+v*h,l+s+f*h,t-c,l+s),r.closePath()}}),SC=It.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,e){var t=e.height,a=e.width,n=e.x,i=e.y,o=a/3*2;r.moveTo(n,i),r.lineTo(n+o,i+t),r.lineTo(n,i+t/4*3),r.lineTo(n-o,i+t),r.lineTo(n,i),r.closePath()}}),xC={line:te,rect:ht,roundRect:ht,square:ht,circle:ur,diamond:yC,pin:mC,arrow:SC,triangle:gC},_C={line:function(r,e,t,a,n){n.x1=r,n.y1=e+a/2,n.x2=r+t,n.y2=e+a/2},rect:function(r,e,t,a,n){n.x=r,n.y=e,n.width=t,n.height=a},roundRect:function(r,e,t,a,n){n.x=r,n.y=e,n.width=t,n.height=a,n.r=Math.min(t,a)/4},square:function(r,e,t,a,n){var i=Math.min(t,a);n.x=r,n.y=e,n.width=i,n.height=i},circle:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.r=Math.min(t,a)/2},diamond:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.width=t,n.height=a},pin:function(r,e,t,a,n){n.x=r+t/2,n.y=e+a/2,n.width=t,n.height=a},arrow:function(r,e,t,a,n){n.x=r+t/2,n.y=e+a/2,n.width=t,n.height=a},triangle:function(r,e,t,a,n){n.cx=r+t/2,n.cy=e+a/2,n.width=t,n.height=a}},_s={};w(xC,function(r,e){_s[e]=new r});var bC=It.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,e,t){var a=sc(r,e,t),n=this.shape;return n&&n.symbolType==="pin"&&e.position==="inside"&&(a.y=t.y+t.height*.4),a},buildPath:function(r,e,t){var a=e.symbolType;if(a!=="none"){var n=_s[a];n||(a="rect",n=_s[a]),_C[a](e.x,e.y,e.width,e.height,n.shape),n.buildPath(r,n.shape,t)}}});function wC(r,e){if(this.type!=="image"){var t=this.style;this.__isEmptyBrush?(t.stroke=r,t.fill=e||"#fff",t.lineWidth=2):this.shape.symbolType==="line"?t.stroke=r:t.fill=r,this.markRedraw()}}function Ht(r,e,t,a,n,i,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var l;return r.indexOf("image://")===0?l=h0(r.slice(8),new wt(e,t,a,n),o?"center":"cover"):r.indexOf("path://")===0?l=Ks(r.slice(7),{},new wt(e,t,a,n),o?"center":"cover"):l=new bC({shape:{symbolType:r,x:e,y:t,width:a,height:n}}),l.__isEmptyBrush=s,l.setColor=wC,i&&l.setColor(i),l}function Ln(r){return O(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function Ia(r,e){if(r!=null)return O(r)||(r=[r,r]),[F(r[0],e[0])||0,F(St(r[1],r[0]),e[1])||0]}var Ol=new wb,xp=new Pm(100),_p=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function sn(r,e){if(r==="none")return null;var t=e.getDevicePixelRatio(),a=e.getZr(),n=a.painter.type==="svg";r.dirty&&Ol.delete(r);var i=Ol.get(r);if(i)return i;var o=J(r,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor==="none"&&(o.backgroundColor=null);var s={repeat:"repeat"};return l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=n?1:1/t,Ol.set(r,s),r.dirty=!1,s;function l(u){for(var c=[t],v=!0,f=0;f<_p.length;++f){var h=o[_p[f]];if(h!=null&&!O(h)&&!$(h)&&!gt(h)&&typeof h!="boolean"){v=!1;break}c.push(h)}var p;if(v){p=c.join(",")+(n?"-svg":"");var d=xp.get(p);d&&(n?u.svgElement=d:u.image=d)}var g=LS(o.dashArrayX),y=AC(o.dashArrayY),m=IS(o.symbol),S=TC(g),x=PS(y),b=!n&&us.createCanvas(),_=n&&{tag:"g",attrs:{},key:"dcl",children:[]},A=C(),T;b&&(b.width=A.width*t,b.height=A.height*t,T=b.getContext("2d")),M(),v&&xp.put(p,b||_),u.image=b,u.svgElement=_,u.svgWidth=A.width,u.svgHeight=A.height;function C(){for(var D=1,I=0,L=S.length;I<L;++I)D=ph(D,S[I]);for(var P=1,I=0,L=m.length;I<L;++I)P=ph(P,m[I].length);D*=P;var E=x*S.length*m.length;return{width:Math.max(1,Math.min(D,o.maxTileWidth)),height:Math.max(1,Math.min(E,o.maxTileHeight))}}function M(){T&&(T.clearRect(0,0,b.width,b.height),o.backgroundColor&&(T.fillStyle=o.backgroundColor,T.fillRect(0,0,b.width,b.height)));for(var D=0,I=0;I<y.length;++I)D+=y[I];if(D<=0)return;for(var L=-x,P=0,E=0,k=0;L<A.height;){if(P%2===0){for(var V=E/2%m.length,N=0,z=0,H=0;N<A.width*2;){for(var Y=0,I=0;I<g[k].length;++I)Y+=g[k][I];if(Y<=0)break;if(z%2===0){var et=(1-o.symbolSize)*.5,rt=N+g[k][z]*et,nt=L+y[P]*et,pt=g[k][z]*o.symbolSize,yt=y[P]*o.symbolSize,vt=H/2%m[V].length;at(rt,nt,pt,yt,m[V][vt])}N+=g[k][z],++H,++z,z===g[k].length&&(z=0)}++k,k===g.length&&(k=0)}L+=y[P],++E,++P,P===y.length&&(P=0)}function at(At,xt,Rt,Zt,ne){var Pt=n?1:t,$t=Ht(ne,At*Pt,xt*Pt,Rt*Pt,Zt*Pt,o.color,o.symbolKeepAspect);if(n){var Xt=a.painter.renderOneToVNode($t);Xt&&_.children.push(Xt)}else Ab(T,$t)}}}}function IS(r){if(!r||r.length===0)return[["rect"]];if($(r))return[[r]];for(var e=!0,t=0;t<r.length;++t)if(!$(r[t])){e=!1;break}if(e)return IS([r]);for(var a=[],t=0;t<r.length;++t)$(r[t])?a.push([r[t]]):a.push(r[t]);return a}function LS(r){if(!r||r.length===0)return[[0,0]];if(gt(r)){var e=Math.ceil(r);return[[e,e]]}for(var t=!0,a=0;a<r.length;++a)if(!gt(r[a])){t=!1;break}if(t)return LS([r]);for(var n=[],a=0;a<r.length;++a)if(gt(r[a])){var e=Math.ceil(r[a]);n.push([e,e])}else{var e=G(r[a],function(s){return Math.ceil(s)});e.length%2===1?n.push(e.concat(e)):n.push(e)}return n}function AC(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(gt(r)){var e=Math.ceil(r);return[e,e]}var t=G(r,function(a){return Math.ceil(a)});return r.length%2?t.concat(t):t}function TC(r){return G(r,function(e){return PS(e)})}function PS(r){for(var e=0,t=0;t<r.length;++t)e+=r[t];return r.length%2===1?e*2:e}function CC(r,e){r.eachRawSeries(function(t){if(!r.isSeriesFiltered(t)){var a=t.getData();a.hasItemVisual()&&a.each(function(o){var s=a.getItemVisual(o,"decal");if(s){var l=a.ensureUniqueItemVisual(o,"style");l.decal=sn(s,e)}});var n=a.getVisual("decal");if(n){var i=a.getVisual("style");i.decal=sn(n,e)}}})}var DC=new dn;const ze=DC;var ES={};function MC(r,e){ES[r]=e}function IC(r){return ES[r]}var LC=1,PC=800,EC=900,RC=1e3,kC=2e3,NC=5e3,RS=1e3,OC=1100,Zv=2e3,kS=3e3,VC=4e3,sl=4500,BC=4600,zC=5e3,GC=6e3,NS=7e3,FC={PROCESSOR:{FILTER:RC,SERIES_FILTER:PC,STATISTIC:NC},VISUAL:{LAYOUT:RS,PROGRESSIVE_LAYOUT:OC,GLOBAL:Zv,CHART:kS,POST_CHART_LAYOUT:BC,COMPONENT:VC,BRUSH:zC,CHART_ITEM:sl,ARIA:GC,DECAL:NS}},ie="__flagInMainProcess",de="__pendingUpdate",Vl="__needsUpdateStatus",bp=/^[a-zA-Z0-9_]+$/,Bl="__connectUpdateStatus",wp=0,HC=1,WC=2;function OS(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(this.isDisposed()){this.id;return}return BS(this,r,e)}}function VS(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return BS(this,r,e)}}function BS(r,e,t){return t[0]=t[0]&&t[0].toLowerCase(),dn.prototype[e].apply(r,t)}var zS=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e}(dn),GS=zS.prototype;GS.on=VS("on");GS.off=VS("off");var Ba,zl,po,_r,Gl,Fl,Hl,Vn,Bn,Ap,Tp,Wl,Cp,go,Dp,FS,xe,Mp,HS=function(r){R(e,r);function e(t,a,n){var i=r.call(this,new fC)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],n=n||{},$(a)&&(a=WS[a]),i._dom=t;var o="canvas",s="auto",l=!1,u=i._zr=nh(t,{renderer:n.renderer||o,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:St(n.useDirtyRect,l),useCoarsePointer:St(n.useCoarsePointer,s),pointerSize:n.pointerSize});i._ssr=n.ssr,i._throttledZrFlush=Uv(W(u.flush,u),17),a=K(a),a&&j0(a,!0),i._theme=a,i._locale=SA(n.locale||A0),i._coordSysMgr=new Xi;var c=i._api=Dp(i);function v(f,h){return f.__prio-h.__prio}return xl(ws,v),xl(Mc,v),i._scheduler=new TS(i,c,Mc,ws),i._messageCenter=new zS,i._initEvents(),i.resize=W(i.resize,i),u.animation.on("frame",i._onframe,i),Ap(u,i),Tp(u,i),ss(i),i}return e.prototype._onframe=function(){if(!this._disposed){Mp(this);var t=this._scheduler;if(this[de]){var a=this[de].silent;this[ie]=!0;try{Ba(this),_r.update.call(this,null,this[de].updateParams)}catch(l){throw this[ie]=!1,this[de]=null,l}this._zr.flush(),this[ie]=!1,this[de]=null,Vn.call(this,a),Bn.call(this,a)}else if(t.unfinished){var n=LC,i=this._model,o=this._api;t.unfinished=!1;do{var s=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),Fl(this,i),t.performVisualTasks(i),go(this,this._model,o,"remain",{}),n-=+new Date-s}while(n>0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,a,n){if(!this[ie]){if(this._disposed){this.id;return}var i,o,s;if(j(a)&&(n=a.lazyUpdate,i=a.silent,o=a.replaceMerge,s=a.transition,a=a.notMerge),this[ie]=!0,!this._model||a){var l=new jA(this._api),u=this._theme,c=this._model=new X0;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:o},Ic);var v={seriesTransition:s,optionChanged:!0};if(n)this[de]={silent:i,updateParams:v},this[ie]=!1,this.getZr().wakeUp();else{try{Ba(this),_r.update.call(this,null,v)}catch(f){throw this[de]=null,this[ie]=!1,f}this._ssr||this._zr.flush(),this[de]=null,this[ie]=!1,Vn.call(this,i),Bn.call(this,i)}}},e.prototype.setTheme=function(){},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||kt.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var a=this._zr.painter;return a.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var a=this._zr.painter;return a.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(kt.svgSupported){var t=this._zr,a=t.storage.getDisplayList();return w(a,function(n){n.stopAnimation(null,!0)}),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(this._disposed){this.id;return}t=t||{};var a=t.excludeComponents,n=this._model,i=[],o=this;w(a,function(l){n.eachComponent({mainType:l},function(u){var c=o._componentsMap[u.__viewId];c.group.ignore||(i.push(c),c.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return w(i,function(l){l.group.ignore=!1}),s},e.prototype.getConnectedDataURL=function(t){if(this._disposed){this.id;return}var a=t.type==="svg",n=this.group,i=Math.min,o=Math.max,s=1/0;if(Ip[n]){var l=s,u=s,c=-s,v=-s,f=[],h=t&&t.pixelRatio||this.getDevicePixelRatio();w(di,function(S,x){if(S.group===n){var b=a?S.getZr().painter.getSvgDom().innerHTML:S.renderToCanvas(K(t)),_=S.getDom().getBoundingClientRect();l=i(_.left,l),u=i(_.top,u),c=o(_.right,c),v=o(_.bottom,v),f.push({dom:b,left:_.left,top:_.top})}}),l*=h,u*=h,c*=h,v*=h;var p=c-l,d=v-u,g=us.createCanvas(),y=nh(g,{renderer:a?"svg":"canvas"});if(y.resize({width:p,height:d}),a){var m="";return w(f,function(S){var x=S.left-l,b=S.top-u;m+='<g transform="translate('+x+","+b+')">'+S.dom+"</g>"}),y.painter.getSvgRoot().innerHTML=m,t.connectedBackgroundColor&&y.painter.setBackgroundColor(t.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}else return t.connectedBackgroundColor&&y.add(new ht({shape:{x:0,y:0,width:p,height:d},style:{fill:t.connectedBackgroundColor}})),w(f,function(S){var x=new ke({style:{x:S.left*h-l,y:S.top*h-u,image:S.dom}});y.add(x)}),y.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,a){return Gl(this,"convertToPixel",t,a)},e.prototype.convertFromPixel=function(t,a){return Gl(this,"convertFromPixel",t,a)},e.prototype.containPixel=function(t,a){if(this._disposed){this.id;return}var n=this._model,i,o=ui(n,t);return w(o,function(s,l){l.indexOf("Models")>=0&&w(s,function(u){var c=u.coordinateSystem;if(c&&c.containPoint)i=i||!!c.containPoint(a);else if(l==="seriesModels"){var v=this._chartsMap[u.__viewId];v&&v.containPoint&&(i=i||v.containPoint(a,u))}},this)},this),!!i},e.prototype.getVisual=function(t,a){var n=this._model,i=ui(n,t,{defaultMainType:"series"}),o=i.seriesModel,s=o.getData(),l=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?s.indexOfRawIndex(i.dataIndex):null;return l!=null?Yv(s,l,a):Ki(s,a)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t=this;w($C,function(a){var n=function(i){var o=t.getModel(),s=i.target,l,u=a==="globalout";if(u?l={}:s&&ca(s,function(p){var d=q(p);if(d&&d.dataIndex!=null){var g=d.dataModel||o.getSeriesByIndex(d.seriesIndex);return l=g&&g.getDataParams(d.dataIndex,d.dataType,s)||{},!0}else if(d.eventData)return l=B({},d.eventData),!0},!0),l){var c=l.componentType,v=l.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",v=l.seriesIndex);var f=c&&v!=null&&o.getComponent(c,v),h=f&&t[f.mainType==="series"?"_chartsMap":"_componentsMap"][f.__viewId];l.event=i,l.type=a,t._$eventProcessor.eventInfo={targetEl:s,packedEvent:l,model:f,view:h},t.trigger(a,l)}};n.zrEventfulCallAtLast=!0,t._zr.on(a,n,t)}),w(pi,function(a,n){t._messageCenter.on(n,function(i){this.trigger(n,i)},t)}),w(["selectchanged"],function(a){t._messageCenter.on(a,function(n){this.trigger(a,n)},t)}),dC(this._messageCenter,this,this._api)},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var t=this.getDom();t&&Qm(this.getDom(),Kv,"");var a=this,n=a._api,i=a._model;w(a._componentsViews,function(o){o.dispose(i,n)}),w(a._chartsViews,function(o){o.dispose(i,n)}),a._zr.dispose(),a._dom=a._model=a._chartsMap=a._componentsMap=a._chartsViews=a._componentsViews=a._scheduler=a._api=a._zr=a._throttledZrFlush=a._theme=a._coordSysMgr=a._messageCenter=null,delete di[a.id]},e.prototype.resize=function(t){if(!this[ie]){if(this._disposed){this.id;return}this._zr.resize(t);var a=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!a){var n=a.resetOption("media"),i=t&&t.silent;this[de]&&(i==null&&(i=this[de].silent),n=!0,this[de]=null),this[ie]=!0;try{n&&Ba(this),_r.update.call(this,{type:"resize",animation:B({duration:0},t&&t.animation)})}catch(o){throw this[ie]=!1,o}this[ie]=!1,Vn.call(this,i),Bn.call(this,i)}}},e.prototype.showLoading=function(t,a){if(this._disposed){this.id;return}if(j(t)&&(a=t,t=""),t=t||"default",this.hideLoading(),!!Lc[t]){var n=Lc[t](this._api,a),i=this._zr;this._loadingFX=n,i.add(n)}},e.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},e.prototype.makeActionFromEvent=function(t){var a=B({},t);return a.type=pi[t.type],a},e.prototype.dispatchAction=function(t,a){if(this._disposed){this.id;return}if(j(a)||(a={silent:!!a}),!!bs[t.type]&&this._model){if(this[ie]){this._pendingActions.push(t);return}var n=a.silent;Hl.call(this,t,n);var i=a.flush;i?this._zr.flush():i!==!1&&kt.browser.weChat&&this._throttledZrFlush(),Vn.call(this,n),Bn.call(this,n)}},e.prototype.updateLabelLayout=function(){ze.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed){this.id;return}var a=t.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(a);i.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()},e.internalField=function(){Ba=function(v){var f=v._scheduler;f.restorePipelines(v._model),f.prepareStageTasks(),zl(v,!0),zl(v,!1),f.plan()},zl=function(v,f){for(var h=v._model,p=v._scheduler,d=f?v._componentsViews:v._chartsViews,g=f?v._componentsMap:v._chartsMap,y=v._zr,m=v._api,S=0;S<d.length;S++)d[S].__alive=!1;f?h.eachComponent(function(_,A){_!=="series"&&x(A)}):h.eachSeries(x);function x(_){var A=_.__requireNewView;_.__requireNewView=!1;var T="_ec_"+_.id+"_"+_.type,C=!A&&g[T];if(!C){var M=qe(_.type),D=f?Ot.getClass(M.main,M.sub):Mt.getClass(M.sub);C=new D,C.init(h,m),g[T]=C,d.push(C),y.add(C.group)}_.__viewId=C.__id=T,C.__alive=!0,C.__model=_,C.group.__ecComponentInfo={mainType:_.mainType,index:_.componentIndex},!f&&p.prepareView(C,_,h,m)}for(var S=0;S<d.length;){var b=d[S];b.__alive?S++:(!f&&b.renderTask.dispose(),y.remove(b.group),b.dispose(h,m),d.splice(S,1),g[b.__id]===b&&delete g[b.__id],b.__id=b.group.__ecComponentInfo=null)}},po=function(v,f,h,p,d){var g=v._model;if(g.setUpdatePayload(h),!p){w([].concat(v._componentsViews).concat(v._chartsViews),b);return}var y={};y[p+"Id"]=h[p+"Id"],y[p+"Index"]=h[p+"Index"],y[p+"Name"]=h[p+"Name"];var m={mainType:p,query:y};d&&(m.subType=d);var S=h.excludeSeriesId,x;S!=null&&(x=Z(),w(_t(S),function(_){var A=Ut(_,null);A!=null&&x.set(A,!0)})),g&&g.eachComponent(m,function(_){var A=x&&x.get(_.id)!=null;if(!A)if(Ch(h))if(_ instanceof Et)h.type===fa&&!h.notBlur&&!_.get(["emphasis","disabled"])&&Fw(_,h,v._api);else{var T=Cv(_.mainType,_.componentIndex,h.name,v._api),C=T.focusSelf,M=T.dispatchers;h.type===fa&&C&&!h.notBlur&&hc(_.mainType,_.componentIndex,v._api),M&&w(M,function(D){h.type===fa?vr(D):fr(D)})}else dc(h)&&_ instanceof Et&&($w(_,h,v._api),Ah(_),xe(v))},v),g&&g.eachComponent(m,function(_){var A=x&&x.get(_.id)!=null;A||b(v[p==="series"?"_chartsMap":"_componentsMap"][_.__viewId])},v);function b(_){_&&_.__alive&&_[f]&&_[f](_.__model,g,v._api,h)}},_r={prepareAndUpdate:function(v){Ba(this),_r.update.call(this,v,{optionChanged:v.newOption!=null})},update:function(v,f){var h=this._model,p=this._api,d=this._zr,g=this._coordSysMgr,y=this._scheduler;if(h){h.setUpdatePayload(v),y.restoreData(h,v),y.performSeriesTasks(h),g.create(h,p),y.performDataProcessorTasks(h,v),Fl(this,h),g.update(h,p),t(h),y.performVisualTasks(h,v),Wl(this,h,p,v,f);var m=h.get("backgroundColor")||"transparent",S=h.get("darkMode");d.setBackgroundColor(m),S!=null&&S!=="auto"&&d.setDarkMode(S),ze.trigger("afterupdate",h,p)}},updateTransform:function(v){var f=this,h=this._model,p=this._api;if(h){h.setUpdatePayload(v);var d=[];h.eachComponent(function(y,m){if(y!=="series"){var S=f.getViewOfComponentModel(m);if(S&&S.__alive)if(S.updateTransform){var x=S.updateTransform(m,h,p,v);x&&x.update&&d.push(S)}else d.push(S)}});var g=Z();h.eachSeries(function(y){var m=f._chartsMap[y.__viewId];if(m.updateTransform){var S=m.updateTransform(y,h,p,v);S&&S.update&&g.set(y.uid,1)}else g.set(y.uid,1)}),t(h),this._scheduler.performVisualTasks(h,v,{setDirty:!0,dirtyMap:g}),go(this,h,p,v,{},g),ze.trigger("afterupdate",h,p)}},updateView:function(v){var f=this._model;f&&(f.setUpdatePayload(v),Mt.markUpdateMethod(v,"updateView"),t(f),this._scheduler.performVisualTasks(f,v,{setDirty:!0}),Wl(this,f,this._api,v,{}),ze.trigger("afterupdate",f,this._api))},updateVisual:function(v){var f=this,h=this._model;h&&(h.setUpdatePayload(v),h.eachSeries(function(p){p.getData().clearAllVisual()}),Mt.markUpdateMethod(v,"updateVisual"),t(h),this._scheduler.performVisualTasks(h,v,{visualType:"visual",setDirty:!0}),h.eachComponent(function(p,d){if(p!=="series"){var g=f.getViewOfComponentModel(d);g&&g.__alive&&g.updateVisual(d,h,f._api,v)}}),h.eachSeries(function(p){var d=f._chartsMap[p.__viewId];d.updateVisual(p,h,f._api,v)}),ze.trigger("afterupdate",h,this._api))},updateLayout:function(v){_r.update.call(this,v)}},Gl=function(v,f,h,p){if(v._disposed){v.id;return}for(var d=v._model,g=v._coordSysMgr.getCoordinateSystems(),y,m=ui(d,h),S=0;S<g.length;S++){var x=g[S];if(x[f]&&(y=x[f](d,m,p))!=null)return y}},Fl=function(v,f){var h=v._chartsMap,p=v._scheduler;f.eachSeries(function(d){p.updateStreamModes(d,h[d.__viewId])})},Hl=function(v,f){var h=this,p=this.getModel(),d=v.type,g=v.escapeConnect,y=bs[d],m=y.actionInfo,S=(m.update||"update").split(":"),x=S.pop(),b=S[0]!=null&&qe(S[0]);this[ie]=!0;var _=[v],A=!1;v.batch&&(A=!0,_=G(v.batch,function(P){return P=J(B({},P),v),P.batch=null,P}));var T=[],C,M=dc(v),D=Ch(v);if(D&&v0(this._api),w(_,function(P){if(C=y.action(P,h._model,h._api),C=C||B({},P),C.type=m.event||C.type,T.push(C),D){var E=xv(v),k=E.queryOptionMap,V=E.mainTypeSpecified,N=V?k.keys()[0]:"series";po(h,x,P,N),xe(h)}else M?(po(h,x,P,"series"),xe(h)):b&&po(h,x,P,b.main,b.sub)}),x!=="none"&&!D&&!M&&!b)try{this[de]?(Ba(this),_r.update.call(this,v),this[de]=null):_r[x].call(this,v)}catch(P){throw this[ie]=!1,P}if(A?C={type:m.event||d,escapeConnect:g,batch:T}:C=T[0],this[ie]=!1,!f){var I=this._messageCenter;if(I.trigger(C.type,C),M){var L={type:"selectchanged",escapeConnect:g,selected:Uw(p),isFromClick:v.isFromClick||!1,fromAction:v.type,fromActionPayload:v};I.trigger(L.type,L)}}},Vn=function(v){for(var f=this._pendingActions;f.length;){var h=f.shift();Hl.call(this,h,v)}},Bn=function(v){!v&&this.trigger("updated")},Ap=function(v,f){v.on("rendered",function(h){f.trigger("rendered",h),v.animation.isFinished()&&!f[de]&&!f._scheduler.unfinished&&!f._pendingActions.length&&f.trigger("finished")})},Tp=function(v,f){v.on("mouseover",function(h){var p=h.target,d=ca(p,_i);d&&(Hw(d,h,f._api),xe(f))}).on("mouseout",function(h){var p=h.target,d=ca(p,_i);d&&(Ww(d,h,f._api),xe(f))}).on("click",function(h){var p=h.target,d=ca(p,function(m){return q(m).dataIndex!=null},!0);if(d){var g=d.selected?"unselect":"select",y=q(d);f._api.dispatchAction({type:g,dataType:y.dataType,dataIndexInside:y.dataIndex,seriesIndex:y.seriesIndex,isFromClick:!0})}})};function t(v){v.clearColorPalette(),v.eachSeries(function(f){f.clearColorPalette()})}function a(v){var f=[],h=[],p=!1;if(v.eachComponent(function(m,S){var x=S.get("zlevel")||0,b=S.get("z")||0,_=S.getZLevelKey();p=p||!!_,(m==="series"?h:f).push({zlevel:x,z:b,idx:S.componentIndex,type:m,key:_})}),p){var d=f.concat(h),g,y;xl(d,function(m,S){return m.zlevel===S.zlevel?m.z-S.z:m.zlevel-S.zlevel}),w(d,function(m){var S=v.getComponent(m.type,m.idx),x=m.zlevel,b=m.key;g!=null&&(x=Math.max(g,x)),b?(x===g&&b!==y&&x++,y=b):y&&(x===g&&x++,y=""),g=x,S.setZLevel(x)})}}Wl=function(v,f,h,p,d){a(f),Cp(v,f,h,p,d),w(v._chartsViews,function(g){g.__alive=!1}),go(v,f,h,p,d),w(v._chartsViews,function(g){g.__alive||g.remove(f,h)})},Cp=function(v,f,h,p,d,g){w(g||v._componentsViews,function(y){var m=y.__model;u(m,y),y.render(m,f,h,p),s(m,y),c(m,y)})},go=function(v,f,h,p,d,g){var y=v._scheduler;d=B(d||{},{updatedSeries:f.getSeries()}),ze.trigger("series:beforeupdate",f,h,d);var m=!1;f.eachSeries(function(S){var x=v._chartsMap[S.__viewId];x.__alive=!0;var b=x.renderTask;y.updatePayload(b,p),u(S,x),g&&g.get(S.uid)&&b.dirty(),b.perform(y.getPerformArgs(b))&&(m=!0),x.group.silent=!!S.get("silent"),o(S,x),Ah(S)}),y.unfinished=m||y.unfinished,ze.trigger("series:layoutlabels",f,h,d),ze.trigger("series:transition",f,h,d),f.eachSeries(function(S){var x=v._chartsMap[S.__viewId];s(S,x),c(S,x)}),i(v,f),ze.trigger("series:afterupdate",f,h,d)},xe=function(v){v[Vl]=!0,v.getZr().wakeUp()},Mp=function(v){v[Vl]&&(v.getZr().storage.traverse(function(f){Ja(f)||n(f)}),v[Vl]=!1)};function n(v){for(var f=[],h=v.currentStates,p=0;p<h.length;p++){var d=h[p];d==="emphasis"||d==="blur"||d==="select"||f.push(d)}v.selected&&v.states.select&&f.push("select"),v.hoverState===Zs&&v.states.emphasis?f.push("emphasis"):v.hoverState===$i&&v.states.blur&&f.push("blur"),v.useStates(f)}function i(v,f){var h=v._zr,p=h.storage,d=0;p.traverse(function(g){g.isGroup||d++}),d>f.get("hoverLayerThreshold")&&!kt.node&&!kt.worker&&f.eachSeries(function(g){if(!g.preventUsingHoverLayer){var y=v._chartsMap[g.__viewId];y.__alive&&y.eachRendered(function(m){m.states.emphasis&&(m.states.emphasis.hoverLayer=!0)})}})}function o(v,f){var h=v.get("blendMode")||null;f.eachRendered(function(p){p.isGroup||(p.style.blend=h)})}function s(v,f){if(!v.preventAutoZ){var h=v.get("z")||0,p=v.get("zlevel")||0;f.eachRendered(function(d){return l(d,h,p,-1/0),!0})}}function l(v,f,h,p){var d=v.getTextContent(),g=v.getTextGuideLine(),y=v.isGroup;if(y)for(var m=v.childrenRef(),S=0;S<m.length;S++)p=Math.max(l(m[S],f,h,p),p);else v.z=f,v.zlevel=h,p=Math.max(v.z2,p);if(d&&(d.z=f,d.zlevel=h,isFinite(p)&&(d.z2=p+2)),g){var x=v.textGuideLineConfig;g.z=f,g.zlevel=h,isFinite(p)&&(g.z2=p+(x&&x.showAbove?1:-1))}return p}function u(v,f){f.eachRendered(function(h){if(!Ja(h)){var p=h.getTextContent(),d=h.getTextGuideLine();h.stateTransition&&(h.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),h.hasState()?(h.prevStates=h.currentStates,h.clearStates()):h.prevStates&&(h.prevStates=null)}})}function c(v,f){var h=v.getModel("stateAnimation"),p=v.isAnimationEnabled(),d=h.get("duration"),g=d>0?{duration:d,delay:h.get("delay"),easing:h.get("easing")}:null;f.eachRendered(function(y){if(y.states&&y.states.emphasis){if(Ja(y))return;if(y instanceof It&&qw(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(p){y.stateTransition=g;var S=y.getTextContent(),x=y.getTextGuideLine();S&&(S.stateTransition=g),x&&(x.stateTransition=g)}y.__dirty&&n(y)}})}Dp=function(v){return new(function(f){R(h,f);function h(){return f!==null&&f.apply(this,arguments)||this}return h.prototype.getCoordinateSystems=function(){return v._coordSysMgr.getCoordinateSystems()},h.prototype.getComponentByElement=function(p){for(;p;){var d=p.__ecComponentInfo;if(d!=null)return v._model.getComponent(d.mainType,d.index);p=p.parent}},h.prototype.enterEmphasis=function(p,d){vr(p,d),xe(v)},h.prototype.leaveEmphasis=function(p,d){fr(p,d),xe(v)},h.prototype.enterBlur=function(p){s0(p),xe(v)},h.prototype.leaveBlur=function(p){Tv(p),xe(v)},h.prototype.enterSelect=function(p){l0(p),xe(v)},h.prototype.leaveSelect=function(p){u0(p),xe(v)},h.prototype.getModel=function(){return v.getModel()},h.prototype.getViewOfComponentModel=function(p){return v.getViewOfComponentModel(p)},h.prototype.getViewOfSeriesModel=function(p){return v.getViewOfSeriesModel(p)},h}(K0))(v)},FS=function(v){function f(h,p){for(var d=0;d<h.length;d++){var g=h[d];g[Bl]=p}}w(pi,function(h,p){v._messageCenter.on(p,function(d){if(Ip[v.group]&&v[Bl]!==wp){if(d&&d.escapeConnect)return;var g=v.makeActionFromEvent(d),y=[];w(di,function(m){m!==v&&m.group===v.group&&y.push(m)}),f(y,wp),w(y,function(m){m[Bl]!==HC&&m.dispatchAction(g)}),f(y,WC)}})})}}(),e}(dn),Xv=HS.prototype;Xv.on=OS("on");Xv.off=OS("off");Xv.one=function(r,e,t){var a=this;function n(){for(var i=[],o=0;o<arguments.length;o++)i[o]=arguments[o];e&&e.apply&&e.apply(this,i),a.off(r,n)}this.on.call(this,r,n,t)};var $C=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var bs={},pi={},Mc=[],Ic=[],ws=[],WS={},Lc={},di={},Ip={},UC=+new Date-0,Kv="_echarts_instance_";function W5(r,e,t){var a=!(t&&t.ssr);if(a){var n=YC(r);if(n)return n}var i=new HS(r,e,t);return i.id="ec_"+UC++,di[i.id]=i,a&&Qm(r,Kv,i.id),FS(i),ze.trigger("afterinit",i),i}function YC(r){return di[_w(r,Kv)]}function $S(r,e){WS[r]=e}function US(r){ct(Ic,r)<0&&Ic.push(r)}function YS(r,e){jv(Mc,r,e,kC)}function ZC(r){qv("afterinit",r)}function XC(r){qv("afterupdate",r)}function qv(r,e){ze.on(r,e)}function rr(r,e,t){X(e)&&(t=e,e="");var a=j(r)?r.type:[r,r={event:e}][0];r.event=(r.event||a).toLowerCase(),e=r.event,!pi[e]&&(ye(bp.test(a)&&bp.test(e)),bs[a]||(bs[a]={action:t,actionInfo:r}),pi[e]=a)}function KC(r,e){Xi.register(r,e)}function qC(r,e){jv(ws,r,e,RS,"layout")}function La(r,e){jv(ws,r,e,kS,"visual")}var Lp=[];function jv(r,e,t,a,n){if((X(e)||j(e))&&(t=e,e=a),!(ct(Lp,t)>=0)){Lp.push(t);var i=TS.wrapStageHandler(t,n);i.__prio=e,i.__raw=t,r.push(i)}}function ZS(r,e){Lc[r]=e}function jC(r,e,t){var a=IC("registerMap");a&&a(r,e,t)}var JC=TT;La(Zv,qT);La(sl,jT);La(sl,JT);La(Zv,hC);La(sl,pC);La(NS,CC);US(j0);YS(EC,iT);ZS("default",QT);rr({type:fa,event:fa,update:fa},he);rr({type:Zo,event:Zo,update:Zo},he);rr({type:ci,event:ci,update:ci},he);rr({type:Xo,event:Xo,update:Xo},he);rr({type:vi,event:vi,update:vi},he);$S("light",cC);$S("dark",vC);var Pp=[],QC={registerPreprocessor:US,registerProcessor:YS,registerPostInit:ZC,registerPostUpdate:XC,registerUpdateLifecycle:qv,registerAction:rr,registerCoordinateSystem:KC,registerLayout:qC,registerVisual:La,registerTransform:JC,registerLoading:ZS,registerMap:jC,registerImpl:MC,PRIORITY:FC,ComponentModel:lt,ComponentView:Ot,SeriesModel:Et,ChartView:Mt,registerComponentModel:function(r){lt.registerClass(r)},registerComponentView:function(r){Ot.registerClass(r)},registerSeriesModel:function(r){Et.registerClass(r)},registerChartView:function(r){Mt.registerClass(r)},registerSubTypeDefaulter:function(r,e){lt.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){Tb(r,e)}};function it(r){if(O(r)){w(r,function(e){it(e)});return}ct(Pp,r)>=0||(Pp.push(r),X(r)&&(r={install:r}),r.install(QC))}function zn(r){return r==null?0:r.length||1}function Ep(r){return r}var tD=function(){function r(e,t,a,n,i,o){this._old=e,this._new=t,this._oldKeyGetter=a||Ep,this._newKeyGetter=n||Ep,this.context=i,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(e){return this._add=e,this},r.prototype.update=function(e){return this._update=e,this},r.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},r.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},r.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},r.prototype.remove=function(e){return this._remove=e,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var e=this._old,t=this._new,a={},n=new Array(e.length),i=new Array(t.length);this._initIndexMap(e,null,n,"_oldKeyGetter"),this._initIndexMap(t,a,i,"_newKeyGetter");for(var o=0;o<e.length;o++){var s=n[o],l=a[s],u=zn(l);if(u>1){var c=l.shift();l.length===1&&(a[s]=l[0]),this._update&&this._update(c,o)}else u===1?(a[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(i,a)},r.prototype._executeMultiple=function(){var e=this._old,t=this._new,a={},n={},i=[],o=[];this._initIndexMap(e,a,i,"_oldKeyGetter"),this._initIndexMap(t,n,o,"_newKeyGetter");for(var s=0;s<i.length;s++){var l=i[s],u=a[l],c=n[l],v=zn(u),f=zn(c);if(v>1&&f===1)this._updateManyToOne&&this._updateManyToOne(c,u),n[l]=null;else if(v===1&&f>1)this._updateOneToMany&&this._updateOneToMany(c,u),n[l]=null;else if(v===1&&f===1)this._update&&this._update(c,u),n[l]=null;else if(v>1&&f>1)this._updateManyToMany&&this._updateManyToMany(c,u),n[l]=null;else if(v>1)for(var h=0;h<v;h++)this._remove&&this._remove(u[h]);else this._remove&&this._remove(u)}this._performRestAdd(o,n)},r.prototype._performRestAdd=function(e,t){for(var a=0;a<e.length;a++){var n=e[a],i=t[n],o=zn(i);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(i[s]);else o===1&&this._add&&this._add(i);t[n]=null}},r.prototype._initIndexMap=function(e,t,a,n){for(var i=this._diffModeMultiple,o=0;o<e.length;o++){var s="_ec_"+this[n](e[o],o);if(i||(a[o]=s),!!t){var l=t[s],u=zn(l);u===0?(t[s]=o,i&&a.push(s)):u===1?t[s]=[l,o]:l.push(o)}}},r}();const hr=tD;var eD=function(){function r(e,t){this._encode=e,this._schema=t}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r}();function rD(r,e){var t={},a=t.encode={},n=Z(),i=[],o=[],s={};w(r.dimensions,function(f){var h=r.getDimensionInfo(f),p=h.coordDim;if(p){var d=h.coordDimIndex;$l(a,p)[d]=f,h.isExtraCoord||(n.set(p,1),aD(h.type)&&(i[0]=f),$l(s,p)[d]=r.getDimensionIndex(h.name)),h.defaultTooltip&&o.push(f)}G0.each(function(g,y){var m=$l(a,y),S=h.otherDims[y];S!=null&&S!==!1&&(m[S]=h.name)})});var l=[],u={};n.each(function(f,h){var p=a[h];u[h]=p[0],l=l.concat(p)}),t.dataDimsOnCoord=l,t.dataDimIndicesOnCoord=G(l,function(f){return r.getDimensionInfo(f).storeDimIndex}),t.encodeFirstDimNotExtra=u;var c=a.label;c&&c.length&&(i=c.slice());var v=a.tooltip;return v&&v.length?o=v.slice():o.length||(o=i.slice()),a.defaultedLabel=i,a.defaultedTooltip=o,t.userOutput=new eD(s,e),t}function $l(r,e){return r.hasOwnProperty(e)||(r[e]=[]),r[e]}function As(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function aD(r){return!(r==="ordinal"||r==="time")}var nD=function(){function r(e){this.otherDims={},e!=null&&B(this,e)}return r}();const Qo=nD;var iD=st(),oD={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},XS=function(){function r(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||(this._dimNameMap=jS(this.source)))},r.prototype.getSourceDimensionIndex=function(e){return St(this._dimNameMap.get(e),-1)},r.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},r.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=Q0(this.source),a=!JS(e),n="",i=[],o=0,s=0;o<e;o++){var l=void 0,u=void 0,c=void 0,v=this.dimensions[s];if(v&&v.storeDimIndex===o)l=t?v.name:null,u=v.type,c=v.ordinalMeta,s++;else{var f=this.getSourceDimension(o);f&&(l=t?f.name:null,u=f.type)}i.push({property:l,type:u,ordinalMeta:c}),t&&l!=null&&(!v||!v.isCalculationCoord)&&(n+=a?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),n+="$",n+=oD[u]||"f",c&&(n+=c.uid),n+="$"}var h=this.source,p=[h.seriesLayoutBy,h.startIndex,n].join("$$");return{dimensions:i,hash:p}},r.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,a=0;t<this._fullDimCount;t++){var n=void 0,i=this.dimensions[a];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(n=i.name),a++;else{var o=this.getSourceDimension(t);o&&(n=o.name)}e.push(n)}return e},r.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r}();function KS(r){return r instanceof XS}function qS(r){for(var e=Z(),t=0;t<(r||[]).length;t++){var a=r[t],n=j(a)?a.name:a;n!=null&&e.get(n)==null&&e.set(n,t)}return e}function jS(r){var e=iD(r);return e.dimNameMap||(e.dimNameMap=qS(r.dimensionsDefine))}function JS(r){return r>30}var Gn=j,br=G,sD=typeof Int32Array>"u"?Array:Int32Array,lD="e\0\0",Rp=-1,uD=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],cD=["_approximateExtent"],kp,yo,Fn,Hn,Ul,mo,Yl,vD=function(){function r(e,t){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"];var a,n=!1;KS(e)?(a=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(n=!0,a=e),a=a||["x","y"];for(var i={},o=[],s={},l=!1,u={},c=0;c<a.length;c++){var v=a[c],f=$(v)?new Qo({name:v}):v instanceof Qo?v:new Qo(v),h=f.name;f.type=f.type||"float",f.coordDim||(f.coordDim=h,f.coordDimIndex=0);var p=f.otherDims=f.otherDims||{};o.push(h),i[h]=f,u[h]!=null&&(l=!0),f.createInvertedIndices&&(s[h]=[]),p.itemName===0&&(this._nameDimIdx=c),p.itemId===0&&(this._idDimIdx=c),n&&(f.storeDimIndex=c)}if(this.dimensions=o,this._dimInfos=i,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var d=this._dimIdxToName=Z();w(o,function(g){d.set(i[g].storeDimIndex,g)})}}return r.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var a=this._dimIdxToName.get(t);if(a!=null)return a;var n=this._schema.getSourceDimension(t);if(n)return n.name},r.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var a=this._getDimInfo(e);return a?a.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},r.prototype._recognizeDimIndex=function(e){if(gt(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},r.prototype._getStoreDimIndex=function(e){var t=this.getDimensionIndex(e);return t},r.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},r.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(a){return t.hasOwnProperty(a)?t[a]:void 0}:function(a){return t[a]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(e,t){var a=this._dimSummary;if(t==null)return a.encodeFirstDimNotExtra[e];var n=a.encode[e];return n?n[t]:null},r.prototype.mapDimensionsAll=function(e){var t=this._dimSummary,a=t.encode[e];return(a||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(e,t,a){var n=this,i;if(e instanceof wc&&(i=e),!i){var o=this.dimensions,s=Bv(e)||pn(e)?new tS(e,o.length):e;i=new wc;var l=br(o,function(u){return{type:n._dimInfos[u].type,property:u}});i.initData(s,l,a)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=rD(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},r.prototype.appendValues=function(e,t){var a=this._store.appendValues(e,t.length),n=a.start,i=a.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var s=n;s<i;s++){var l=s-n;this._nameList[s]=t[l],o&&Yl(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,a=0;a<t.length;a++){var n=this._dimInfos[t[a]];n.ordinalMeta&&e.collectOrdinalMeta(n.storeDimIndex,n.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==Er&&!e.fillStorage},r.prototype._doInit=function(e,t){if(!(e>=t)){var a=this._store,n=a.getProvider();this._updateOrdinalMeta();var i=this._nameList,o=this._idList,s=n.getSource().sourceFormat,l=s===Ne;if(l&&!n.pure)for(var u=[],c=e;c<t;c++){var v=n.getItem(c,u);if(!this.hasItemOption&&lw(v)&&(this.hasItemOption=!0),v){var f=v.name;i[c]==null&&f!=null&&(i[c]=Ut(f,null));var h=v.id;o[c]==null&&h!=null&&(o[c]=Ut(h,null))}}if(this._shouldMakeIdFromName())for(var c=e;c<t;c++)Yl(this,c);kp(this)}},r.prototype.getApproximateExtent=function(e){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},r.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},r.prototype.setCalculationInfo=function(e,t){Gn(e)?B(this._calculationInfo,e):this._calculationInfo[e]=t},r.prototype.getName=function(e){var t=this.getRawIndex(e),a=this._nameList[t];return a==null&&this._nameDimIdx!=null&&(a=Fn(this,this._nameDimIdx,t)),a==null&&(a=""),a},r.prototype._getCategory=function(e,t){var a=this._store.get(e,t),n=this._store.getOrdinalMeta(e);return n?n.categories[a]:a},r.prototype.getId=function(e){return yo(this,this.getRawIndex(e))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(e,t){var a=this._store,n=this._dimInfos[e];if(n)return a.get(n.storeDimIndex,t)},r.prototype.getByRawIndex=function(e,t){var a=this._store,n=this._dimInfos[e];if(n)return a.getByRawIndex(n.storeDimIndex,t)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e))},r.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},r.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},r.prototype.getValues=function(e,t){var a=this,n=this._store;return O(e)?n.getValues(br(e,function(i){return a._getStoreDimIndex(i)}),t):n.getValues(e)},r.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,a=0,n=t.length;a<n;a++)if(isNaN(this._store.get(t[a],e)))return!1;return!0},r.prototype.indexOfName=function(e){for(var t=0,a=this._store.count();t<a;t++)if(this.getName(t)===e)return t;return-1},r.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},r.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},r.prototype.rawIndexOf=function(e,t){var a=e&&this._invertedIndicesMap[e],n=a[t];return n==null||isNaN(n)?Rp:n},r.prototype.indicesOfNearest=function(e,t,a){return this._store.indicesOfNearest(this._getStoreDimIndex(e),t,a)},r.prototype.each=function(e,t,a){X(e)&&(a=t,t=e,e=[]);var n=a||this,i=br(Hn(e),this._getStoreDimIndex,this);this._store.each(i,n?W(t,n):t)},r.prototype.filterSelf=function(e,t,a){X(e)&&(a=t,t=e,e=[]);var n=a||this,i=br(Hn(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,n?W(t,n):t),this},r.prototype.selectRange=function(e){var t=this,a={},n=Wt(e);return w(n,function(i){var o=t._getStoreDimIndex(i);a[o]=e[i]}),this._store=this._store.selectRange(a),this},r.prototype.mapArray=function(e,t,a){X(e)&&(a=t,t=e,e=[]),a=a||this;var n=[];return this.each(e,function(){n.push(t&&t.apply(this,arguments))},a),n},r.prototype.map=function(e,t,a,n){var i=a||n||this,o=br(Hn(e),this._getStoreDimIndex,this),s=mo(this);return s._store=this._store.map(o,i?W(t,i):t),s},r.prototype.modify=function(e,t,a,n){var i=a||n||this,o=br(Hn(e),this._getStoreDimIndex,this);this._store.modify(o,i?W(t,i):t)},r.prototype.downSample=function(e,t,a,n){var i=mo(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,a,n),i},r.prototype.lttbDownSample=function(e,t){var a=mo(this);return a._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),a},r.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},r.prototype.getItemModel=function(e){var t=this.hostModel,a=this.getRawDataItem(e);return new Dt(a,t,t&&t.ecModel)},r.prototype.diff=function(e){var t=this;return new hr(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(a){return yo(e,a)},function(a){return yo(t,a)})},r.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},r.prototype.setVisual=function(e,t){this._visual=this._visual||{},Gn(e)?B(this._visual,e):this._visual[e]=t},r.prototype.getItemVisual=function(e,t){var a=this._itemVisuals[e],n=a&&a[t];return n??this.getVisual(t)},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(e,t){var a=this._itemVisuals,n=a[e];n||(n=a[e]={});var i=n[t];return i==null&&(i=this.getVisual(t),O(i)?i=i.slice():Gn(i)&&(i=B({},i)),n[t]=i),i},r.prototype.setItemVisual=function(e,t,a){var n=this._itemVisuals[e]||{};this._itemVisuals[e]=n,Gn(t)?B(n,t):n[t]=a},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){Gn(e)?B(this._layout,e):this._layout[e]=t},r.prototype.getLayout=function(e){return this._layout[e]},r.prototype.getItemLayout=function(e){return this._itemLayouts[e]},r.prototype.setItemLayout=function(e,t,a){this._itemLayouts[e]=a?B(this._itemLayouts[e]||{},t):t},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(e,t){var a=this.hostModel&&this.hostModel.seriesIndex;vc(a,this.dataType,e,t),this._graphicEls[e]=t},r.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},r.prototype.eachItemGraphicEl=function(e,t){w(this._graphicEls,function(a,n){a&&e&&e.call(t,a,n)})},r.prototype.cloneShallow=function(e){return e||(e=new r(this._schema?this._schema:br(this.dimensions,this._getDimInfo,this),this.hostModel)),Ul(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var a=this[e];X(a)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var n=a.apply(this,arguments);return t.apply(this,[n].concat(Cb(arguments)))})},r.internalField=function(){kp=function(e){var t=e._invertedIndicesMap;w(t,function(a,n){var i=e._dimInfos[n],o=i.ordinalMeta,s=e._store;if(o){a=t[n]=new sD(o.categories.length);for(var l=0;l<a.length;l++)a[l]=Rp;for(var l=0;l<s.count();l++)a[s.get(i.storeDimIndex,l)]=l}})},Fn=function(e,t,a){return Ut(e._getCategory(t,a),null)},yo=function(e,t){var a=e._idList[t];return a==null&&e._idDimIdx!=null&&(a=Fn(e,e._idDimIdx,t)),a==null&&(a=lD+t),a},Hn=function(e){return O(e)||(e=e!=null?[e]:[]),e},mo=function(e){var t=new r(e._schema?e._schema:br(e.dimensions,e._getDimInfo,e),e.hostModel);return Ul(t,e),t},Ul=function(e,t){w(uD.concat(t.__wrappedMethods||[]),function(a){t.hasOwnProperty(a)&&(e[a]=t[a])}),e.__wrappedMethods=t.__wrappedMethods,w(cD,function(a){e[a]=K(t[a])}),e._calculationInfo=B({},t._calculationInfo)},Yl=function(e,t){var a=e._nameList,n=e._idList,i=e._nameDimIdx,o=e._idDimIdx,s=a[t],l=n[t];if(s==null&&i!=null&&(a[t]=s=Fn(e,i,t)),l==null&&o!=null&&(n[t]=l=Fn(e,o,t)),l==null&&s!=null){var u=e._nameRepeatCount,c=u[s]=(u[s]||0)+1;l=s,c>1&&(l+="__ec__"+c),n[t]=l}}}(),r}();const fe=vD;function qi(r,e){Bv(r)||(r=zv(r)),e=e||{};var t=e.coordDimensions||[],a=e.dimensionsDefine||r.dimensionsDefine||[],n=Z(),i=[],o=hD(r,t,a,e.dimensionsCount),s=e.canOmitUnusedDimensions&&JS(o),l=a===r.dimensionsDefine,u=l?jS(r):qS(a),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(r,o));for(var v=Z(c),f=new lS(o),h=0;h<f.length;h++)f[h]=-1;function p(C){var M=f[C];if(M<0){var D=a[C],I=j(D)?D:{name:D},L=new Qo,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 E=i.length;return f[C]=E,L.storeDimIndex=C,i.push(L),L}return i[M]}if(!s)for(var h=0;h<o;h++)p(h);v.each(function(C,M){var D=_t(C).slice();if(D.length===1&&!$(D[0])&&D[0]<0){v.set(M,!1);return}var I=v.set(M,[]);w(D,function(L,P){var E=$(L)?u.get(L):L;E!=null&&E<o&&(I[P]=E,g(p(E),M,P))})});var d=0;w(t,function(C){var M,D,I,L;if($(C))M=C,L={};else{L=C,M=L.name;var P=L.ordinalMeta;L.ordinalMeta=null,L=B({},L),L.ordinalMeta=P,D=L.dimsDef,I=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var E=v.get(M);if(E!==!1){if(E=_t(E),!E.length)for(var k=0;k<(D&&D.length||1);k++){for(;d<o&&p(d).coordDim!=null;)d++;d<o&&E.push(d++)}w(E,function(V,N){var z=p(V);if(l&&L.type!=null&&(z.type=L.type),g(J(z,L),M,N),z.name==null&&D){var H=D[N];!j(H)&&(H={name:H}),z.name=z.displayName=H.name,z.defaultTooltip=H.defaultTooltip}I&&J(z.otherDims,I)})}});function g(C,M,D){G0.get(M)!=null?C.otherDims[M]=D:(C.coordDim=M,C.coordDimIndex=D,n.set(M,!0))}var y=e.generateCoord,m=e.generateCoordCount,S=m!=null;m=y?m||1:0;var x=y||"value";function b(C){C.name==null&&(C.name=C.coordDim)}if(s)w(i,function(C){b(C)}),i.sort(function(C,M){return C.storeDimIndex-M.storeDimIndex});else for(var _=0;_<o;_++){var A=p(_),T=A.coordDim;T==null&&(A.coordDim=pD(x,n,S),A.coordDimIndex=0,(!y||m<=0)&&(A.isExtraCoord=!0),m--),b(A),A.type==null&&($0(r,_)===Qt.Must||A.isExtraCoord&&(A.otherDims.itemName!=null||A.otherDims.seriesName!=null))&&(A.type="ordinal")}return fD(i),new XS({source:r,dimensions:i,fullDimensionCount:o,dimensionOmitted:s})}function fD(r){for(var e=Z(),t=0;t<r.length;t++){var a=r[t],n=a.name,i=e.get(n)||0;i>0&&(a.name=n+(i-1)),i++,e.set(n,i)}}function hD(r,e,t,a){var n=Math.max(r.dimensionsDetectedCount||1,e.length,t.length,a||0);return w(e,function(i){var o;j(i)&&(o=i.dimsDef)&&(n=Math.max(n,o.length))}),n}function pD(r,e,t){if(t||e.hasKey(r)){for(var a=0;e.hasKey(r+a);)a++;r+=a}return e.set(r,!0),r}var dD=function(){function r(e){this.coordSysDims=[],this.axisMap=Z(),this.categoryAxisMap=Z(),this.coordSysName=e}return r}();function gD(r){var e=r.get("coordinateSystem"),t=new dD(e),a=yD[e];if(a)return a(r,t,t.axisMap,t.categoryAxisMap),t}var yD={cartesian2d:function(r,e,t,a){var n=r.getReferringComponents("xAxis",Ft).models[0],i=r.getReferringComponents("yAxis",Ft).models[0];e.coordSysDims=["x","y"],t.set("x",n),t.set("y",i),za(n)&&(a.set("x",n),e.firstCategoryDimIndex=0),za(i)&&(a.set("y",i),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,a){var n=r.getReferringComponents("singleAxis",Ft).models[0];e.coordSysDims=["single"],t.set("single",n),za(n)&&(a.set("single",n),e.firstCategoryDimIndex=0)},polar:function(r,e,t,a){var n=r.getReferringComponents("polar",Ft).models[0],i=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",i),t.set("angle",o),za(i)&&(a.set("radius",i),e.firstCategoryDimIndex=0),za(o)&&(a.set("angle",o),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(r,e,t,a){e.coordSysDims=["lng","lat"]},parallel:function(r,e,t,a){var n=r.ecModel,i=n.getComponent("parallel",r.get("parallelIndex")),o=e.coordSysDims=i.dimensions.slice();w(i.parallelAxisIndex,function(s,l){var u=n.getComponent("parallelAxis",s),c=o[l];t.set(c,u),za(u)&&(a.set(c,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})}};function za(r){return r.get("type")==="category"}function mD(r,e,t){t=t||{};var a=t.byIndex,n=t.stackedCoordDimension,i,o,s;SD(e)?i=e:(o=e.schema,i=o.dimensions,s=e.store);var l=!!(r&&r.get("stack")),u,c,v,f;if(w(i,function(m,S){$(m)&&(i[S]=m={name:m}),l&&!m.isExtraCoord&&(!a&&!u&&m.ordinalMeta&&(u=m),!c&&m.type!=="ordinal"&&m.type!=="time"&&(!n||n===m.coordDim)&&(c=m))}),c&&!a&&!u&&(a=!0),c){v="__\0ecstackresult_"+r.id,f="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var h=c.coordDim,p=c.type,d=0;w(i,function(m){m.coordDim===h&&d++});var g={name:v,coordDim:h,coordDimIndex:d,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},y={name:f,coordDim:f,coordDimIndex:d+1,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(f,p),y.storeDimIndex=s.ensureCalculationDimension(v,p)),o.appendCalculationDimension(g),o.appendCalculationDimension(y)):(i.push(g),i.push(y))}return{stackedDimension:c&&c.name,stackedByDimension:u&&u.name,isStackedByIndex:a,stackedOverDimension:f,stackResultDimension:v}}function SD(r){return!KS(r.schema)}function Br(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function QS(r,e){return Br(r,e)?r.getCalculationInfo("stackResultDimension"):e}function xD(r,e){var t=r.get("coordinateSystem"),a=Xi.get(t),n;return e&&e.coordSysDims&&(n=G(e.coordSysDims,function(i){var o={name:i},s=e.axisMap.get(i);if(s){var l=s.get("type");o.type=As(l)}return o})),n||(n=a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]),n}function _D(r,e,t){var a,n;return t&&w(r,function(i,o){var s=i.coordDim,l=t.categoryAxisMap.get(s);l&&(a==null&&(a=o),i.ordinalMeta=l.getOrdinalMeta(),e&&(i.createInvertedIndices=!0)),i.otherDims.itemName!=null&&(n=!0)}),!n&&a!=null&&(r[a].otherDims.itemName=0),a}function yr(r,e,t){t=t||{};var a=e.getSourceManager(),n,i=!1;r?(i=!0,n=zv(r)):(n=a.getSource(),i=n.sourceFormat===Ne);var o=gD(e),s=xD(e,o),l=t.useEncodeDefaulter,u=X(l)?l:l?Q(W0,s,e):null,c={coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!i},v=qi(n,c),f=_D(v.dimensions,t.createInvertedIndices,o),h=i?null:a.getSharedDataStore(v),p=mD(e,{schema:v,store:h}),d=new fe(v,e);d.setCalculationInfo(p);var g=f!=null&&bD(n)?function(y,m,S,x){return x===f?S:this.defaultDimValueGetter(y,m,S,x)}:null;return d.hasItemOption=!1,d.initData(i?n:h,null,g),d}function bD(r){if(r.sourceFormat===Ne){var e=wD(r.data||[]);return!O(mn(e))}}function wD(r){for(var e=0;e<r.length&&r[e]==null;)e++;return r[e]}var tx=function(){function r(e){this._setting=e||{},this._extent=[1/0,-1/0]}return r.prototype.getSetting=function(e){return this._setting[e]},r.prototype.unionExtent=function(e){var t=this._extent;e[0]<t[0]&&(t[0]=e[0]),e[1]>t[1]&&(t[1]=e[1])},r.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(e,t){var a=this._extent;isNaN(e)||(a[0]=e),isNaN(t)||(a[1]=t)},r.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(e){this._isBlank=e},r}();Ys(tx);const mr=tx;var AD=0,TD=function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++AD}return r.createByAxisModel=function(e){var t=e.option,a=t.data,n=a&&G(a,CD);return new r({categories:n,needCollect:!n,deduplication:t.dedplication!==!1})},r.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},r.prototype.parseAndCollect=function(e){var t,a=this._needCollect;if(!$(e)&&!a)return e;if(a&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,t;var n=this._getOrCreateMap();return t=n.get(e),t==null&&(a?(t=this.categories.length,this.categories[t]=e,n.set(e,t)):t=NaN),t},r.prototype._getOrCreateMap=function(){return this._map||(this._map=Z(this.categories))},r}();function CD(r){return j(r)&&r.value!=null?r.value:r+""}const Pc=TD;function Ec(r){return r.type==="interval"||r.type==="log"}function DD(r,e,t,a){var n={},i=r[1]-r[0],o=n.interval=Um(i/e,!0);t!=null&&o<t&&(o=n.interval=t),a!=null&&o>a&&(o=n.interval=a);var s=n.intervalPrecision=ex(o),l=n.niceTickExtent=[Vt(Math.ceil(r[0]/o)*o,s),Vt(Math.floor(r[1]/o)*o,s)];return MD(l,r),n}function Zl(r){var e=Math.pow(10,mv(r)),t=r/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,Vt(t*e)}function ex(r){return Ke(r)+2}function Np(r,e,t){r[e]=Math.max(Math.min(r[e],t[1]),t[0])}function MD(r,e){!isFinite(r[0])&&(r[0]=e[0]),!isFinite(r[1])&&(r[1]=e[1]),Np(r,0,e),Np(r,1,e),r[0]>r[1]&&(r[0]=r[1])}function ll(r,e){return r>=e[0]&&r<=e[1]}function ul(r,e){return e[1]===e[0]?.5:(r-e[0])/(e[1]-e[0])}function cl(r,e){return r*(e[1]-e[0])+e[0]}var rx=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;a.type="ordinal";var n=a.getSetting("ordinalMeta");return n||(n=new Pc({})),O(n)&&(n=new Pc({categories:G(n,function(i){return j(i)?i.value:i})})),a._ordinalMeta=n,a._extent=a.getSetting("extent")||[0,n.categories.length-1],a}return e.prototype.parse=function(t){return t==null?NaN:$(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return t=this.parse(t),ll(t,this._extent)&&this._ordinalMeta.categories[t]!=null},e.prototype.normalize=function(t){return t=this._getTickNumber(this.parse(t)),ul(t,this._extent)},e.prototype.scale=function(t){return t=Math.round(cl(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],a=this._extent,n=a[0];n<=a[1];)t.push({value:n}),n++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var a=t.ordinalNumbers,n=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Math.min(s,a.length);o<l;++o){var u=a[o];n[o]=u,i[u]=o}for(var c=0;o<s;++o){for(;i[c]!=null;)c++;n.push(c),i[c]=o}},e.prototype._getTickNumber=function(t){var a=this._ticksByOrdinalNumber;return a&&t>=0&&t<a.length?a[t]:t},e.prototype.getRawOrdinalNumber=function(t){var a=this._ordinalNumbersByTick;return a&&t>=0&&t<a.length?a[t]:t},e.prototype.getLabel=function(t){if(!this.isBlank()){var a=this.getRawOrdinalNumber(t.value),n=this._ordinalMeta.categories[a];return n==null?"":n+""}},e.prototype.count=function(){return this._extent[1]-this._extent[0]+1},e.prototype.unionExtentFromData=function(t,a){this.unionExtent(t.getApproximateExtent(a))},e.prototype.isInExtentRange=function(t){return t=this._getTickNumber(t),this._extent[0]<=t&&this._extent[1]>=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(mr);mr.registerClass(rx);const Jv=rx;var Kr=Vt,ax=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return ll(t,this._extent)},e.prototype.normalize=function(t){return ul(t,this._extent)},e.prototype.scale=function(t){return cl(t,this._extent)},e.prototype.setExtent=function(t,a){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(a)||(n[1]=parseFloat(a))},e.prototype.unionExtent=function(t){var a=this._extent;t[0]<a[0]&&(a[0]=t[0]),t[1]>a[1]&&(a[1]=t[1]),this.setExtent(a[0],a[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=ex(t)},e.prototype.getTicks=function(t){var a=this._interval,n=this._extent,i=this._niceExtent,o=this._intervalPrecision,s=[];if(!a)return s;var l=1e4;n[0]<i[0]&&(t?s.push({value:Kr(i[0]-a,o)}):s.push({value:n[0]}));for(var u=i[0];u<=i[1]&&(s.push({value:u}),u=Kr(u+a,o),u!==s[s.length-1].value);)if(s.length>l)return[];var c=s.length?s[s.length-1].value:i[1];return n[1]>c&&(t?s.push({value:Kr(c+a,o)}):s.push({value:n[1]})),s},e.prototype.getMinorTicks=function(t){for(var a=this.getTicks(!0),n=[],i=this.getExtent(),o=1;o<a.length;o++){for(var s=a[o],l=a[o-1],u=0,c=[],v=s.value-l.value,f=v/t;u<t-1;){var h=Kr(l.value+(u+1)*f);h>i[0]&&h<i[1]&&c.push(h),u++}n.push(c)}return n},e.prototype.getLabel=function(t,a){if(t==null)return"";var n=a&&a.precision;n==null?n=Ke(t.value)||0:n==="auto"&&(n=this._intervalPrecision);var i=Kr(t.value,n,!0);return k0(i)},e.prototype.calcNiceTicks=function(t,a,n){t=t||5;var i=this._extent,o=i[1]-i[0];if(isFinite(o)){o<0&&(o=-o,i.reverse());var s=DD(i,t,a,n);this._intervalPrecision=s.intervalPrecision,this._interval=s.interval,this._niceExtent=s.niceTickExtent}},e.prototype.calcNiceExtent=function(t){var a=this._extent;if(a[0]===a[1])if(a[0]!==0){var n=Math.abs(a[0]);t.fixMax||(a[1]+=n/2),a[0]-=n/2}else a[1]=1;var i=a[1]-a[0];isFinite(i)||(a[0]=0,a[1]=1),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval);var o=this._interval;t.fixMin||(a[0]=Kr(Math.floor(a[0]/o)*o)),t.fixMax||(a[1]=Kr(Math.ceil(a[1]/o)*o))},e.prototype.setNiceExtent=function(t,a){this._niceExtent=[t,a]},e.type="interval",e}(mr);mr.registerClass(ax);const zr=ax;var nx=typeof Float32Array<"u",ID=nx?Float32Array:Array;function je(r){return O(r)?nx?new Float32Array(r):r:new ID(r)}var Rc="__ec_stack_";function Qv(r){return r.get("stack")||Rc+r.seriesIndex}function tf(r){return r.dim+r.index}function LD(r){var e=[],t=r.axis,a="axis0";if(t.type==="category"){for(var n=t.getBandWidth(),i=0;i<r.count;i++)e.push(J({bandWidth:n,axisKey:a,stackId:Rc+i},r));for(var o=sx(e),s=[],i=0;i<r.count;i++){var l=o[a][Rc+i];l.offsetCenter=l.offset+l.width/2,s.push(l)}return s}}function ix(r,e){var t=[];return e.eachSeriesByType(r,function(a){cx(a)&&t.push(a)}),t}function PD(r){var e={};w(r,function(l){var u=l.coordinateSystem,c=u.getBaseAxis();if(!(c.type!=="time"&&c.type!=="value"))for(var v=l.getData(),f=c.dim+"_"+c.index,h=v.getDimensionIndex(v.mapDimension(c.dim)),p=v.getStore(),d=0,g=p.count();d<g;++d){var y=p.get(h,d);e[f]?e[f].push(y):e[f]=[y]}});var t={};for(var a in e)if(e.hasOwnProperty(a)){var n=e[a];if(n){n.sort(function(l,u){return l-u});for(var i=null,o=1;o<n.length;++o){var s=n[o]-n[o-1];s>0&&(i=i===null?s:Math.min(i,s))}t[a]=i}}return t}function ox(r){var e=PD(r),t=[];return w(r,function(a){var n=a.coordinateSystem,i=n.getBaseAxis(),o=i.getExtent(),s;if(i.type==="category")s=i.getBandWidth();else if(i.type==="value"||i.type==="time"){var l=i.dim+"_"+i.index,u=e[l],c=Math.abs(o[1]-o[0]),v=i.scale.getExtent(),f=Math.abs(v[1]-v[0]);s=u?c/f*u:c}else{var h=a.getData();s=Math.abs(o[1]-o[0])/h.count()}var p=F(a.get("barWidth"),s),d=F(a.get("barMaxWidth"),s),g=F(a.get("barMinWidth")||(vx(a)?.5:1),s),y=a.get("barGap"),m=a.get("barCategoryGap");t.push({bandWidth:s,barWidth:p,barMaxWidth:d,barMinWidth:g,barGap:y,barCategoryGap:m,axisKey:tf(i),stackId:Qv(a)})}),sx(t)}function sx(r){var e={};w(r,function(a,n){var i=a.axisKey,o=a.bandWidth,s=e[i]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},l=s.stacks;e[i]=s;var u=a.stackId;l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var c=a.barWidth;c&&!l[u].width&&(l[u].width=c,c=Math.min(s.remainedWidth,c),s.remainedWidth-=c);var v=a.barMaxWidth;v&&(l[u].maxWidth=v);var f=a.barMinWidth;f&&(l[u].minWidth=f);var h=a.barGap;h!=null&&(s.gap=h);var p=a.barCategoryGap;p!=null&&(s.categoryGap=p)});var t={};return w(e,function(a,n){t[n]={};var i=a.stacks,o=a.bandWidth,s=a.categoryGap;if(s==null){var l=Wt(i).length;s=Math.max(35-l*4,15)+"%"}var u=F(s,o),c=F(a.gap,1),v=a.remainedWidth,f=a.autoWidthCount,h=(v-u)/(f+(f-1)*c);h=Math.max(h,0),w(i,function(y){var m=y.maxWidth,S=y.minWidth;if(y.width){var x=y.width;m&&(x=Math.min(x,m)),S&&(x=Math.max(x,S)),y.width=x,v-=x+c*x,f--}else{var x=h;m&&m<x&&(x=Math.min(m,v)),S&&S>x&&(x=S),x!==h&&(y.width=x,v-=x+c*x,f--)}}),h=(v-u)/(f+(f-1)*c),h=Math.max(h,0);var p=0,d;w(i,function(y,m){y.width||(y.width=h),d=y,p+=y.width*(1+c)}),d&&(p-=d.width*c);var g=-p/2;w(i,function(y,m){t[n][m]=t[n][m]||{bandWidth:o,offset:g,width:y.width},g+=y.width*(1+c)})}),t}function ED(r,e,t){if(r&&e){var a=r[tf(e)];return a!=null&&t!=null?a[Qv(t)]:a}}function lx(r,e){var t=ix(r,e),a=ox(t);w(t,function(n){var i=n.getData(),o=n.coordinateSystem,s=o.getBaseAxis(),l=Qv(n),u=a[tf(s)][l],c=u.offset,v=u.width;i.setLayout({bandWidth:u.bandWidth,offset:c,size:v})})}function ux(r){return{seriesType:r,plan:Mn(),reset:function(e){if(cx(e)){var t=e.getData(),a=e.coordinateSystem,n=a.getBaseAxis(),i=a.getOtherAxis(n),o=t.getDimensionIndex(t.mapDimension(i.dim)),s=t.getDimensionIndex(t.mapDimension(n.dim)),l=e.get("showBackground",!0),u=t.mapDimension(i.dim),c=t.getCalculationInfo("stackResultDimension"),v=Br(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),f=i.isHorizontal(),h=RD(n,i),p=vx(e),d=e.get("barMinHeight")||0,g=c&&t.getDimensionIndex(c),y=t.getLayout("size"),m=t.getLayout("offset");return{progress:function(S,x){for(var b=S.count,_=p&&je(b*3),A=p&&l&&je(b*3),T=p&&je(b),C=a.master.getRect(),M=f?C.width:C.height,D,I=x.getStore(),L=0;(D=S.next())!=null;){var P=I.get(v?g:o,D),E=I.get(s,D),k=h,V=void 0;v&&(V=+P-I.get(o,D));var N=void 0,z=void 0,H=void 0,Y=void 0;if(f){var et=a.dataToPoint([P,E]);if(v){var rt=a.dataToPoint([V,E]);k=rt[0]}N=k,z=et[1]+m,H=et[0]-k,Y=y,Math.abs(H)<d&&(H=(H<0?-1:1)*d)}else{var et=a.dataToPoint([E,P]);if(v){var rt=a.dataToPoint([E,V]);k=rt[1]}N=et[0]+m,z=k,H=y,Y=et[1]-k,Math.abs(Y)<d&&(Y=(Y<=0?-1:1)*d)}p?(_[L]=N,_[L+1]=z,_[L+2]=f?H:Y,A&&(A[L]=f?C.x:N,A[L+1]=f?z:C.y,A[L+2]=M),T[D]=D):x.setItemLayout(D,{x:N,y:z,width:H,height:Y}),L+=3}p&&x.setLayout({largePoints:_,largeDataIndices:T,largeBackgroundPoints:A,valueAxisHorizontal:f})}}}}}}function cx(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function vx(r){return r.pipelineContext&&r.pipelineContext.large}function RD(r,e){return e.toGlobalCoord(e.dataToCoord(e.type==="log"?1:0))}var kD=function(r,e,t,a){for(;t<a;){var n=t+a>>>1;r[n][1]<e?t=n+1:a=n}return t},fx=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="time",a}return e.prototype.getLabel=function(t){var a=this.getSetting("useUTC");return Js(t.value,Nh[bA(Qa(this._minLevelUnit))]||Nh.second,a,this.getSetting("locale"))},e.prototype.getFormattedLabel=function(t,a,n){var i=this.getSetting("useUTC"),o=this.getSetting("locale");return wA(t,a,n,o,i)},e.prototype.getTicks=function(){var t=this._interval,a=this._extent,n=[];if(!t)return n;n.push({value:a[0],level:0});var i=this.getSetting("useUTC"),o=FD(this._minLevelUnit,this._approxInterval,i,a);return n=n.concat(o),n.push({value:a[1],level:0}),n},e.prototype.calcNiceExtent=function(t){var a=this._extent;if(a[0]===a[1]&&(a[0]-=De,a[1]+=De),a[1]===-1/0&&a[0]===1/0){var n=new Date;a[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),a[0]=a[1]-De}this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval)},e.prototype.calcNiceTicks=function(t,a,n){t=t||10;var i=this._extent,o=i[1]-i[0];this._approxInterval=o/t,a!=null&&this._approxInterval<a&&(this._approxInterval=a),n!=null&&this._approxInterval>n&&(this._approxInterval=n);var s=So.length,l=Math.min(kD(So,this._approxInterval,0,s),s-1);this._interval=So[l][1],this._minLevelUnit=So[Math.max(l-1,0)][0]},e.prototype.parse=function(t){return gt(t)?t:+tr(t)},e.prototype.contain=function(t){return ll(this.parse(t),this._extent)},e.prototype.normalize=function(t){return ul(this.parse(t),this._extent)},e.prototype.scale=function(t){return cl(t,this._extent)},e.type="time",e}(zr),So=[["second",Pv],["minute",Ev],["hour",fi],["quarter-day",fi*6],["half-day",fi*12],["day",De*1.2],["half-week",De*3.5],["week",De*7],["month",De*31],["quarter",De*95],["half-year",kh/2],["year",kh]];function ND(r,e,t,a){var n=tr(e),i=tr(t),o=function(p){return Oh(n,p,a)===Oh(i,p,a)},s=function(){return o("year")},l=function(){return s()&&o("month")},u=function(){return l()&&o("day")},c=function(){return u()&&o("hour")},v=function(){return c()&&o("minute")},f=function(){return v()&&o("second")},h=function(){return f()&&o("millisecond")};switch(r){case"year":return s();case"month":return l();case"day":return u();case"hour":return c();case"minute":return v();case"second":return f();case"millisecond":return h()}}function OD(r,e){return r/=De,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function VD(r){var e=30*De;return r/=e,r>6?6:r>3?3:r>2?2:1}function BD(r){return r/=fi,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function Op(r,e){return r/=e?Ev:Pv,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function zD(r){return Um(r,!0)}function GD(r,e,t){var a=new Date(r);switch(Qa(e)){case"year":case"month":a[M0(t)](0);case"day":a[I0(t)](1);case"hour":a[L0(t)](0);case"minute":a[P0(t)](0);case"second":a[E0(t)](0),a[R0(t)](0)}return a.getTime()}function FD(r,e,t,a){var n=1e4,i=C0,o=0;function s(M,D,I,L,P,E,k){for(var V=new Date(D),N=D,z=V[L]();N<I&&N<=a[1];)k.push({value:N}),z+=M,V[P](z),N=V.getTime();k.push({value:N,notAdd:!0})}function l(M,D,I){var L=[],P=!D.length;if(!ND(Qa(M),a[0],a[1],t)){P&&(D=[{value:GD(new Date(a[0]),M,t)},{value:a[1]}]);for(var E=0;E<D.length-1;E++){var k=D[E].value,V=D[E+1].value;if(k!==V){var N=void 0,z=void 0,H=void 0,Y=!1;switch(M){case"year":N=Math.max(1,Math.round(e/De/365)),z=Rv(t),H=AA(t);break;case"half-year":case"quarter":case"month":N=VD(e),z=tn(t),H=M0(t);break;case"week":case"half-week":case"day":N=OD(e),z=Qs(t),H=I0(t),Y=!0;break;case"half-day":case"quarter-day":case"hour":N=BD(e),z=Ai(t),H=L0(t);break;case"minute":N=Op(e,!0),z=tl(t),H=P0(t);break;case"second":N=Op(e,!1),z=el(t),H=E0(t);break;case"millisecond":N=zD(e),z=rl(t),H=R0(t);break}s(N,k,V,z,H,Y,L),M==="year"&&I.length>1&&E===0&&I.unshift({value:I[0].value-N})}}for(var E=0;E<L.length;E++)I.push(L[E]);return L}}for(var u=[],c=[],v=0,f=0,h=0;h<i.length&&o++<n;++h){var p=Qa(i[h]);if(_A(i[h])){l(i[h],u[u.length-1]||[],c);var d=i[h+1]?Qa(i[h+1]):null;if(p!==d){if(c.length){f=v,c.sort(function(M,D){return M.value-D.value});for(var g=[],y=0;y<c.length;++y){var m=c[y].value;(y===0||c[y-1].value!==m)&&(g.push(c[y]),m>=a[0]&&m<=a[1]&&v++)}var S=(a[1]-a[0])/e;if(v>S*1.5&&f>S/1.5||(u.push(g),v>S||r===i[h]))break}c=[]}}}for(var x=bt(G(u,function(M){return bt(M,function(D){return D.value>=a[0]&&D.value<=a[1]&&!D.notAdd})}),function(M){return M.length>0}),b=[],_=x.length-1,h=0;h<x.length;++h)for(var A=x[h],T=0;T<A.length;++T)b.push({value:A[T].value,level:_-h});b.sort(function(M,D){return M.value-D.value});for(var C=[],h=0;h<b.length;++h)(h===0||b[h].value!==b[h-1].value)&&C.push(b[h]);return C}mr.registerClass(fx);const hx=fx;var Vp=mr.prototype,gi=zr.prototype,HD=Vt,WD=Math.floor,$D=Math.ceil,xo=Math.pow,Be=Math.log,ef=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new zr,t._interval=0,t}return e.prototype.getTicks=function(t){var a=this._originalScale,n=this._extent,i=a.getExtent(),o=gi.getTicks.call(this,t);return G(o,function(s){var l=s.value,u=Vt(xo(this.base,l));return u=l===n[0]&&this._fixMin?_o(u,i[0]):u,u=l===n[1]&&this._fixMax?_o(u,i[1]):u,{value:u}},this)},e.prototype.setExtent=function(t,a){var n=Be(this.base);t=Be(Math.max(0,t))/n,a=Be(Math.max(0,a))/n,gi.setExtent.call(this,t,a)},e.prototype.getExtent=function(){var t=this.base,a=Vp.getExtent.call(this);a[0]=xo(t,a[0]),a[1]=xo(t,a[1]);var n=this._originalScale,i=n.getExtent();return this._fixMin&&(a[0]=_o(a[0],i[0])),this._fixMax&&(a[1]=_o(a[1],i[1])),a},e.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var a=this.base;t[0]=Be(t[0])/Be(a),t[1]=Be(t[1])/Be(a),Vp.unionExtent.call(this,t)},e.prototype.unionExtentFromData=function(t,a){this.unionExtent(t.getApproximateExtent(a))},e.prototype.calcNiceTicks=function(t){t=t||10;var a=this._extent,n=a[1]-a[0];if(!(n===1/0||n<=0)){var i=sw(n),o=t/n*i;for(o<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var s=[Vt($D(a[0]/i)*i),Vt(WD(a[1]/i)*i)];this._interval=i,this._niceExtent=s}},e.prototype.calcNiceExtent=function(t){gi.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return t=Be(t)/Be(this.base),ll(t,this._extent)},e.prototype.normalize=function(t){return t=Be(t)/Be(this.base),ul(t,this._extent)},e.prototype.scale=function(t){return t=cl(t,this._extent),xo(this.base,t)},e.type="log",e}(mr),px=ef.prototype;px.getMinorTicks=gi.getMinorTicks;px.getLabel=gi.getLabel;function _o(r,e){return HD(r,Ke(e))}mr.registerClass(ef);const UD=ef;var YD=function(){function r(e,t,a){this._prepareParams(e,t,a)}return r.prototype._prepareParams=function(e,t,a){a[1]<a[0]&&(a=[NaN,NaN]),this._dataMin=a[0],this._dataMax=a[1];var n=this._isOrdinal=e.type==="ordinal";this._needCrossZero=e.type==="interval"&&t.getNeedCrossZero&&t.getNeedCrossZero();var i=this._modelMinRaw=t.get("min",!0);X(i)?this._modelMinNum=bo(e,i({min:a[0],max:a[1]})):i!=="dataMin"&&(this._modelMinNum=bo(e,i));var o=this._modelMaxRaw=t.get("max",!0);if(X(o)?this._modelMaxNum=bo(e,o({min:a[0],max:a[1]})):o!=="dataMax"&&(this._modelMaxNum=bo(e,o)),n)this._axisDataLen=t.getCategories().length;else{var s=t.get("boundaryGap"),l=O(s)?s:[s||0,s||0];typeof l[0]=="boolean"||typeof l[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[an(l[0],1),an(l[1],1)]}},r.prototype.calculate=function(){var e=this._isOrdinal,t=this._dataMin,a=this._dataMax,n=this._axisDataLen,i=this._boundaryGapInner,o=e?null:a-t||Math.abs(t),s=this._modelMinRaw==="dataMin"?t:this._modelMinNum,l=this._modelMaxRaw==="dataMax"?a:this._modelMaxNum,u=s!=null,c=l!=null;s==null&&(s=e?n?0:NaN:t-i[0]*o),l==null&&(l=e?n?n-1:NaN:a+i[1]*o),(s==null||!isFinite(s))&&(s=NaN),(l==null||!isFinite(l))&&(l=NaN);var v=cs(s)||cs(l)||e&&!n;this._needCrossZero&&(s>0&&l>0&&!u&&(s=0),s<0&&l<0&&!c&&(l=0));var f=this._determinedMin,h=this._determinedMax;return f!=null&&(s=f,u=!0),h!=null&&(l=h,c=!0),{min:s,max:l,minFixed:u,maxFixed:c,isBlank:v}},r.prototype.modifyDataMinMax=function(e,t){this[XD[e]]=t},r.prototype.setDeterminedMinMax=function(e,t){var a=ZD[e];this[a]=t},r.prototype.freeze=function(){this.frozen=!0},r}(),ZD={min:"_determinedMin",max:"_determinedMax"},XD={min:"_dataMin",max:"_dataMax"};function dx(r,e,t){var a=r.rawExtentInfo;return a||(a=new YD(r,e,t),r.rawExtentInfo=a,a)}function bo(r,e){return e==null?null:cs(e)?NaN:r.parse(e)}function gx(r,e){var t=r.type,a=dx(r,e,r.getExtent()).calculate();r.setBlank(a.isBlank);var n=a.min,i=a.max,o=e.ecModel;if(o&&t==="time"){var s=ix("bar",o),l=!1;if(w(s,function(v){l=l||v.getBaseAxis()===e.axis}),l){var u=ox(s),c=KD(n,i,e,u);n=c.min,i=c.max}}return{extent:[n,i],fixMin:a.minFixed,fixMax:a.maxFixed}}function KD(r,e,t,a){var n=t.axis.getExtent(),i=n[1]-n[0],o=ED(a,t.axis);if(o===void 0)return{min:r,max:e};var s=1/0;w(o,function(h){s=Math.min(h.offset,s)});var l=-1/0;w(o,function(h){l=Math.max(h.offset+h.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,c=e-r,v=1-(s+l)/i,f=c/v-c;return e+=f*(l/u),r-=f*(s/u),{min:r,max:e}}function ln(r,e){var t=e,a=gx(r,t),n=a.extent,i=t.get("splitNumber");r instanceof UD&&(r.base=t.get("logBase"));var o=r.type,s=t.get("interval"),l=o==="interval"||o==="time";r.setExtent(n[0],n[1]),r.calcNiceExtent({splitNumber:i,fixMin:a.fixMin,fixMax:a.fixMax,minInterval:l?t.get("minInterval"):null,maxInterval:l?t.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function vl(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new Jv({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new hx({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(mr.getClass(e)||zr)}}function qD(r){var e=r.scale.getExtent(),t=e[0],a=e[1];return!(t>0&&a>0||t<0&&a<0)}function ji(r){var e=r.getLabelModel().get("formatter"),t=r.type==="category"?r.scale.getExtent()[0]:null;return r.scale.type==="time"?function(a){return function(n,i){return r.scale.getFormattedLabel(n,i,a)}}(e):$(e)?function(a){return function(n){var i=r.scale.getLabel(n),o=a.replace("{value}",i??"");return o}}(e):X(e)?function(a){return function(n,i){return t!=null&&(i=n.value-t),a(rf(r,n),i,n.level!=null?{level:n.level}:null)}}(e):function(a){return r.scale.getLabel(a)}}function rf(r,e){return r.type==="category"?r.scale.getLabel(e):e.value}function jD(r){var e=r.model,t=r.scale;if(!(!e.get(["axisLabel","show"])||t.isBlank())){var a,n,i=t.getExtent();t instanceof Jv?n=t.count():(a=t.getTicks(),n=a.length);var o=r.getLabelModel(),s=ji(r),l,u=1;n>40&&(u=Math.ceil(n/40));for(var c=0;c<n;c+=u){var v=a?a[c]:{value:i[0]+c},f=s(v,c),h=o.getTextRect(f),p=JD(h,o.get("rotate")||0);l?l.union(p):l=p}return l}}function JD(r,e){var t=e*Math.PI/180,a=r.width,n=r.height,i=a*Math.abs(Math.cos(t))+Math.abs(n*Math.sin(t)),o=a*Math.abs(Math.sin(t))+Math.abs(n*Math.cos(t)),s=new wt(r.x,r.y,i,o);return s}function af(r){var e=r.get("interval");return e??"auto"}function yx(r){return r.type==="category"&&af(r.getLabelModel())===0}function Ts(r,e){var t={};return w(r.mapDimensionsAll(e),function(a){t[QS(r,a)]=!0}),Wt(t)}function QD(r,e,t){e&&w(Ts(e,t),function(a){var n=e.getApproximateExtent(a);n[0]<r[0]&&(r[0]=n[0]),n[1]>r[1]&&(r[1]=n[1])})}var Ji=function(){function r(){}return r.prototype.getNeedCrossZero=function(){var e=this.option;return!e.scale},r.prototype.getCoordSysModel=function(){},r}(),tM=[];function Xl(r,e){for(var t=0;t<r.length;t++)Le(r[t],r[t],e)}function Bp(r,e,t,a){for(var n=0;n<r.length;n++){var i=r[n];a&&(i=a.project(i)),i&&isFinite(i[0])&&isFinite(i[1])&&(Nm(e,e,i),Om(t,t,i))}}function eM(r){for(var e=0,t=0,a=0,n=r.length,i=r[n-1][0],o=r[n-1][1],s=0;s<n;s++){var l=r[s][0],u=r[s][1],c=i*u-l*o;e+=c,t+=(i+l)*c,a+=(o+u)*c,i=l,o=u}return e?[t/e/3,a/e/3,e]:[r[0][0]||0,r[0][1]||0]}var mx=function(){function r(e){this.name=e}return r.prototype.setCenter=function(e){this._center=e},r.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},r}(),zp=function(){function r(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return r}(),Gp=function(){function r(e){this.type="linestring",this.points=e}return r}(),Sx=function(r){R(e,r);function e(t,a,n){var i=r.call(this,t)||this;return i.type="geoJSON",i.geometries=a,i._center=n&&[n[0],n[1]],i}return e.prototype.calcCenter=function(){for(var t=this.geometries,a,n=0,i=0;i<t.length;i++){var o=t[i],s=o.exterior,l=s&&s.length;l>n&&(a=o,n=l)}if(a)return eM(a.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var a=this._rect;if(a&&!t)return a;var n=[1/0,1/0],i=[-1/0,-1/0],o=this.geometries;return w(o,function(s){s.type==="polygon"?Bp(s.exterior,n,i,t):w(s.points,function(l){Bp(l,n,i,t)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])||(n[0]=n[1]=i[0]=i[1]=0),a=new wt(n[0],n[1],i[0]-n[0],i[1]-n[1]),t||(this._rect=a),a},e.prototype.contain=function(t){var a=this.getBoundingRect(),n=this.geometries;if(!a.contain(t[0],t[1]))return!1;t:for(var i=0,o=n.length;i<o;i++){var s=n[i];if(s.type==="polygon"){var l=s.exterior,u=s.interiors;if(aa(l,t[0],t[1])){for(var c=0;c<(u?u.length:0);c++)if(aa(u[c],t[0],t[1]))continue t;return!0}}}return!1},e.prototype.transformTo=function(t,a,n,i){var o=this.getBoundingRect(),s=o.width/o.height;n?i||(i=n/s):n=s*i;for(var l=new wt(t,a,n,i),u=o.calculateTransform(l),c=this.geometries,v=0;v<c.length;v++){var f=c[v];f.type==="polygon"?(Xl(f.exterior,u),w(f.interiors,function(h){Xl(h,u)})):w(f.points,function(h){Xl(h,u)})}o=this._rect,o.copy(l),this._center=[o.x+o.width/2,o.y+o.height/2]},e.prototype.cloneShallow=function(t){t==null&&(t=this.name);var a=new e(t,this.geometries,this._center);return a._rect=this._rect,a.transformTo=null,a},e}(mx),rM=function(r){R(e,r);function e(t,a){var n=r.call(this,t)||this;return n.type="geoSVG",n._elOnlyForCalculate=a,n}return e.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,a=t.getBoundingRect(),n=[a.x+a.width/2,a.y+a.height/2],i=dv(tM),o=t;o&&!o.isGeoSVGGraphicRoot;)is(i,o.getLocalTransform(),i),o=o.parent;return zi(i,i),Le(n,n,i),n},e}(mx);function aM(r){if(!r.UTF8Encoding)return r;var e=r,t=e.UTF8Scale;t==null&&(t=1024);var a=e.features;return w(a,function(n){var i=n.geometry,o=i.encodeOffsets,s=i.coordinates;if(o)switch(i.type){case"LineString":i.coordinates=xx(s,o,t);break;case"Polygon":Kl(s,o,t);break;case"MultiLineString":Kl(s,o,t);break;case"MultiPolygon":w(s,function(l,u){return Kl(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function Kl(r,e,t){for(var a=0;a<r.length;a++)r[a]=xx(r[a],e[a],t)}function xx(r,e,t){for(var a=[],n=e[0],i=e[1],o=0;o<r.length;o+=2){var s=r.charCodeAt(o)-64,l=r.charCodeAt(o+1)-64;s=s>>1^-(s&1),l=l>>1^-(l&1),s+=n,l+=i,n=s,i=l,a.push([s/t,l/t])}return a}function nM(r,e){return r=aM(r),G(bt(r.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var a=t.properties,n=t.geometry,i=[];switch(n.type){case"Polygon":var o=n.coordinates;i.push(new zp(o[0],o.slice(1)));break;case"MultiPolygon":w(n.coordinates,function(l){l[0]&&i.push(new zp(l[0],l.slice(1)))});break;case"LineString":i.push(new Gp([n.coordinates]));break;case"MultiLineString":i.push(new Gp(n.coordinates))}var s=new Sx(a[e||"name"],i,a.cp);return s.properties=a,s})}var Ii=st();function iM(r){return r.type==="category"?sM(r):uM(r)}function oM(r,e){return r.type==="category"?lM(r,e):{ticks:G(r.scale.getTicks(),function(t){return t.value})}}function sM(r){var e=r.getLabelModel(),t=_x(r,e);return!e.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:t.labelCategoryInterval}:t}function _x(r,e){var t=bx(r,"labels"),a=af(e),n=wx(t,a);if(n)return n;var i,o;return X(a)?i=Cx(r,a):(o=a==="auto"?cM(r):a,i=Tx(r,o)),Ax(t,a,{labels:i,labelCategoryInterval:o})}function lM(r,e){var t=bx(r,"ticks"),a=af(e),n=wx(t,a);if(n)return n;var i,o;if((!e.get("show")||r.scale.isBlank())&&(i=[]),X(a))i=Cx(r,a,!0);else if(a==="auto"){var s=_x(r,r.getLabelModel());o=s.labelCategoryInterval,i=G(s.labels,function(l){return l.tickValue})}else o=a,i=Tx(r,o,!0);return Ax(t,a,{ticks:i,tickCategoryInterval:o})}function uM(r){var e=r.scale.getTicks(),t=ji(r);return{labels:G(e,function(a,n){return{level:a.level,formattedLabel:t(a,n),rawLabel:r.scale.getLabel(a),tickValue:a.value}})}}function bx(r,e){return Ii(r)[e]||(Ii(r)[e]=[])}function wx(r,e){for(var t=0;t<r.length;t++)if(r[t].key===e)return r[t].value}function Ax(r,e,t){return r.push({key:e,value:t}),t}function cM(r){var e=Ii(r).autoInterval;return e??(Ii(r).autoInterval=r.calculateCategoryInterval())}function vM(r){var e=fM(r),t=ji(r),a=(e.axisRotate-e.labelRotate)/180*Math.PI,n=r.scale,i=n.getExtent(),o=n.count();if(i[1]-i[0]<1)return 0;var s=1;o>40&&(s=Math.max(1,Math.floor(o/40)));for(var l=i[0],u=r.dataToCoord(l+1)-r.dataToCoord(l),c=Math.abs(u*Math.cos(a)),v=Math.abs(u*Math.sin(a)),f=0,h=0;l<=i[1];l+=s){var p=0,d=0,g=Us(t({value:l}),e.font,"center","top");p=g.width*1.3,d=g.height*1.3,f=Math.max(f,p,7),h=Math.max(h,d,7)}var y=f/c,m=h/v;isNaN(y)&&(y=1/0),isNaN(m)&&(m=1/0);var S=Math.max(0,Math.floor(Math.min(y,m))),x=Ii(r.model),b=r.getExtent(),_=x.lastAutoInterval,A=x.lastTickCount;return _!=null&&A!=null&&Math.abs(_-S)<=1&&Math.abs(A-o)<=1&&_>S&&x.axisExtent0===b[0]&&x.axisExtent1===b[1]?S=_:(x.lastTickCount=o,x.lastAutoInterval=S,x.axisExtent0=b[0],x.axisExtent1=b[1]),S}function fM(r){var e=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function Tx(r,e,t){var a=ji(r),n=r.scale,i=n.getExtent(),o=r.getLabelModel(),s=[],l=Math.max((e||0)+1,1),u=i[0],c=n.count();u!==0&&l>1&&c/l>2&&(u=Math.round(Math.ceil(u/l)*l));var v=yx(r),f=o.get("showMinLabel")||v,h=o.get("showMaxLabel")||v;f&&u!==i[0]&&d(i[0]);for(var p=u;p<=i[1];p+=l)d(p);h&&p-l!==i[1]&&d(i[1]);function d(g){var y={value:g};s.push(t?g:{formattedLabel:a(y),rawLabel:n.getLabel(y),tickValue:g})}return s}function Cx(r,e,t){var a=r.scale,n=ji(r),i=[];return w(a.getTicks(),function(o){var s=a.getLabel(o),l=o.value;e(o.value,s)&&i.push(t?l:{formattedLabel:n(o),rawLabel:s,tickValue:l})}),i}var Fp=[0,1],hM=function(){function r(e,t,a){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=a||[0,0]}return r.prototype.contain=function(e){var t=this._extent,a=Math.min(t[0],t[1]),n=Math.max(t[0],t[1]);return e>=a&&e<=n},r.prototype.containData=function(e){return this.scale.contain(e)},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(e){return Wm(e||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(e,t){var a=this._extent;a[0]=e,a[1]=t},r.prototype.dataToCoord=function(e,t){var a=this._extent,n=this.scale;return e=n.normalize(e),this.onBand&&n.type==="ordinal"&&(a=a.slice(),Hp(a,n.count())),mt(e,Fp,a,t)},r.prototype.coordToData=function(e,t){var a=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(a=a.slice(),Hp(a,n.count()));var i=mt(e,a,Fp,t);return this.scale.scale(i)},r.prototype.pointToData=function(e,t){},r.prototype.getTicksCoords=function(e){e=e||{};var t=e.tickModel||this.getTickModel(),a=oM(this,t),n=a.ticks,i=G(n,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=t.get("alignWithLabel");return pM(this,i,o,e.clamp),i},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var e=this.model.getModel("minorTick"),t=e.get("splitNumber");t>0&&t<100||(t=5);var a=this.scale.getMinorTicks(t),n=G(a,function(i){return G(i,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return n},r.prototype.getViewLabels=function(){return iM(this).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),a=t[1]-t[0]+(this.onBand?1:0);a===0&&(a=1);var n=Math.abs(e[1]-e[0]);return Math.abs(n)/a},r.prototype.calculateCategoryInterval=function(){return vM(this)},r}();function Hp(r,e){var t=r[1]-r[0],a=e,n=t/a/2;r[0]+=n,r[1]-=n}function pM(r,e,t,a){var n=e.length;if(!r.onBand||t||!n)return;var i=r.getExtent(),o,s;if(n===1)e[0].coord=i[0],o=e[1]={coord:i[1]};else{var l=e[n-1].tickValue-e[0].tickValue,u=(e[n-1].coord-e[0].coord)/l;w(e,function(h){h.coord-=u/2});var c=r.scale.getExtent();s=1+c[1]-e[n-1].tickValue,o={coord:e[n-1].coord+u*s},e.push(o)}var v=i[0]>i[1];f(e[0].coord,i[0])&&(a?e[0].coord=i[0]:e.shift()),a&&f(i[0],e[0].coord)&&e.unshift({coord:i[0]}),f(i[1],o.coord)&&(a?o.coord=i[1]:e.pop()),a&&f(o.coord,i[1])&&e.push({coord:i[1]});function f(h,p){return h=Vt(h),p=Vt(p),v?h>p:h<p}}const Ue=hM;var Wn=Math.PI*2,qr=Vm.CMD,dM=["top","right","bottom","left"];function gM(r,e,t,a,n){var i=t.width,o=t.height;switch(r){case"top":a.set(t.x+i/2,t.y-e),n.set(0,-1);break;case"bottom":a.set(t.x+i/2,t.y+o+e),n.set(0,1);break;case"left":a.set(t.x-e,t.y+o/2),n.set(-1,0);break;case"right":a.set(t.x+i+e,t.y+o/2),n.set(1,0);break}}function yM(r,e,t,a,n,i,o,s,l){o-=r,s-=e;var u=Math.sqrt(o*o+s*s);o/=u,s/=u;var c=o*t+r,v=s*t+e;if(Math.abs(a-n)%Wn<1e-4)return l[0]=c,l[1]=v,u-t;if(i){var f=a;a=sa(n),n=sa(f)}else a=sa(a),n=sa(n);a>n&&(n+=Wn);var h=Math.atan2(s,o);if(h<0&&(h+=Wn),h>=a&&h<=n||h+Wn>=a&&h+Wn<=n)return l[0]=c,l[1]=v,u-t;var p=t*Math.cos(a)+r,d=t*Math.sin(a)+e,g=t*Math.cos(n)+r,y=t*Math.sin(n)+e,m=(p-o)*(p-o)+(d-s)*(d-s),S=(g-o)*(g-o)+(y-s)*(y-s);return m<S?(l[0]=p,l[1]=d,Math.sqrt(m)):(l[0]=g,l[1]=y,Math.sqrt(S))}function Cs(r,e,t,a,n,i,o,s){var l=n-r,u=i-e,c=t-r,v=a-e,f=Math.sqrt(c*c+v*v);c/=f,v/=f;var h=l*c+u*v,p=h/f;s&&(p=Math.min(Math.max(p,0),1)),p*=f;var d=o[0]=r+p*c,g=o[1]=e+p*v;return Math.sqrt((d-n)*(d-n)+(g-i)*(g-i))}function Dx(r,e,t,a,n,i,o){t<0&&(r=r+t,t=-t),a<0&&(e=e+a,a=-a);var s=r+t,l=e+a,u=o[0]=Math.min(Math.max(n,r),s),c=o[1]=Math.min(Math.max(i,e),l);return Math.sqrt((u-n)*(u-n)+(c-i)*(c-i))}var Ge=[];function mM(r,e,t){var a=Dx(e.x,e.y,e.width,e.height,r.x,r.y,Ge);return t.set(Ge[0],Ge[1]),a}function SM(r,e,t){for(var a=0,n=0,i=0,o=0,s,l,u=1/0,c=e.data,v=r.x,f=r.y,h=0;h<c.length;){var p=c[h++];h===1&&(a=c[h],n=c[h+1],i=a,o=n);var d=u;switch(p){case qr.M:i=c[h++],o=c[h++],a=i,n=o;break;case qr.L:d=Cs(a,n,c[h],c[h+1],v,f,Ge,!0),a=c[h++],n=c[h++];break;case qr.C:d=Mb(a,n,c[h++],c[h++],c[h++],c[h++],c[h],c[h+1],v,f,Ge),a=c[h++],n=c[h++];break;case qr.Q:d=Db(a,n,c[h++],c[h++],c[h],c[h+1],v,f,Ge),a=c[h++],n=c[h++];break;case qr.A:var g=c[h++],y=c[h++],m=c[h++],S=c[h++],x=c[h++],b=c[h++];h+=1;var _=!!(1-c[h++]);s=Math.cos(x)*m+g,l=Math.sin(x)*S+y,h<=1&&(i=s,o=l);var A=(v-g)*S/m+g;d=yM(g,y,S,x,x+b,_,A,f,Ge),a=Math.cos(x+b)*m+g,n=Math.sin(x+b)*S+y;break;case qr.R:i=a=c[h++],o=n=c[h++];var T=c[h++],C=c[h++];d=Dx(i,o,T,C,v,f,Ge);break;case qr.Z:d=Cs(a,n,i,o,v,f,Ge,!0),a=i,n=o;break}d<u&&(u=d,t.set(Ge[0],Ge[1]))}return u}var Fe=new Gt,Tt=new Gt,Bt=new Gt,Je=new Gt,Xe=new Gt;function Wp(r,e){if(r){var t=r.getTextGuideLine(),a=r.getTextContent();if(a&&t){var n=r.textGuideLineConfig||{},i=[[0,0],[0,0],[0,0]],o=n.candidates||dM,s=a.getBoundingRect().clone();s.applyTransform(a.getComputedTransform());var l=1/0,u=n.anchor,c=r.getComputedTransform(),v=c&&zi([],c),f=e.get("length2")||0;u&&Bt.copy(u);for(var h=0;h<o.length;h++){var p=o[h];gM(p,0,s,Fe,Je),Gt.scaleAndAdd(Tt,Fe,Je,f),Tt.transform(v);var d=r.getBoundingRect(),g=u?u.distance(Tt):r instanceof It?SM(Tt,r.path,Bt):mM(Tt,d,Bt);g<l&&(l=g,Tt.transform(c),Bt.transform(c),Bt.toArray(i[0]),Tt.toArray(i[1]),Fe.toArray(i[2]))}Mx(i,e.get("minTurnAngle")),t.setShape({points:i})}}}var Ds=[],ve=new Gt;function Mx(r,e){if(e<=180&&e>0){e=e/180*Math.PI,Fe.fromArray(r[0]),Tt.fromArray(r[1]),Bt.fromArray(r[2]),Gt.sub(Je,Fe,Tt),Gt.sub(Xe,Bt,Tt);var t=Je.len(),a=Xe.len();if(!(t<.001||a<.001)){Je.scale(1/t),Xe.scale(1/a);var n=Je.dot(Xe),i=Math.cos(e);if(i<n){var o=Cs(Tt.x,Tt.y,Bt.x,Bt.y,Fe.x,Fe.y,Ds,!1);ve.fromArray(Ds),ve.scaleAndAdd(Xe,o/Math.tan(Math.PI-e));var s=Bt.x!==Tt.x?(ve.x-Tt.x)/(Bt.x-Tt.x):(ve.y-Tt.y)/(Bt.y-Tt.y);if(isNaN(s))return;s<0?Gt.copy(ve,Tt):s>1&&Gt.copy(ve,Bt),ve.toArray(r[1])}}}}function xM(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,Fe.fromArray(r[0]),Tt.fromArray(r[1]),Bt.fromArray(r[2]),Gt.sub(Je,Tt,Fe),Gt.sub(Xe,Bt,Tt);var a=Je.len(),n=Xe.len();if(!(a<.001||n<.001)){Je.scale(1/a),Xe.scale(1/n);var i=Je.dot(e),o=Math.cos(t);if(i<o){var s=Cs(Tt.x,Tt.y,Bt.x,Bt.y,Fe.x,Fe.y,Ds,!1);ve.fromArray(Ds);var l=Math.PI/2,u=Math.acos(Xe.dot(e)),c=l+u-t;if(c>=l)Gt.copy(ve,Bt);else{ve.scaleAndAdd(Xe,s/Math.tan(Math.PI/2-c));var v=Bt.x!==Tt.x?(ve.x-Tt.x)/(Bt.x-Tt.x):(ve.y-Tt.y)/(Bt.y-Tt.y);if(isNaN(v))return;v<0?Gt.copy(ve,Tt):v>1&&Gt.copy(ve,Bt)}ve.toArray(r[1])}}}}function $p(r,e,t,a){var n=t==="normal",i=n?r:r.ensureState(t);i.ignore=e;var o=a.get("smooth");o&&o===!0&&(o=.3),i.shape=i.shape||{},o>0&&(i.shape.smooth=o);var s=a.getModel("lineStyle").getLineStyle();n?r.useStyle(s):i.style=s}function _M(r,e){var t=e.smooth,a=e.points;if(a)if(r.moveTo(a[0][0],a[0][1]),t>0&&a.length>=3){var n=oa(a[0],a[1]),i=oa(a[1],a[2]);if(!n||!i){r.lineTo(a[1][0],a[1][1]),r.lineTo(a[2][0],a[2][1]);return}var o=Math.min(n,i)*t,s=_l([],a[1],a[0],o/n),l=_l([],a[1],a[2],o/i),u=_l([],s,l,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],a[2][0],a[2][1])}else for(var c=1;c<a.length;c++)r.lineTo(a[c][0],a[c][1])}function nf(r,e,t){var a=r.getTextGuideLine(),n=r.getTextContent();if(!n){a&&r.removeTextGuideLine();return}for(var i=e.normal,o=i.get("show"),s=n.ignore,l=0;l<xi.length;l++){var u=xi[l],c=e[u],v=u==="normal";if(c){var f=c.get("show"),h=v?s:St(n.states[u]&&n.states[u].ignore,s);if(h||!St(f,o)){var p=v?a:a&&a.states[u];p&&(p.ignore=!0);continue}a||(a=new me,r.setTextGuideLine(a),!v&&(s||!o)&&$p(a,!0,"normal",e.normal),r.stateProxy&&(a.stateProxy=r.stateProxy)),$p(a,!1,u,c)}}if(a){J(a.style,t),a.style.fill=null;var d=i.get("showAbove"),g=r.textGuideLineConfig=r.textGuideLineConfig||{};g.showAbove=d||!1,a.buildPath=_M}}function of(r,e){e=e||"labelLine";for(var t={normal:r.getModel(e)},a=0;a<pe.length;a++){var n=pe[a];t[n]=r.getModel([n,e])}return t}function Ix(r){for(var e=[],t=0;t<r.length;t++){var a=r[t];if(!a.defaultAttr.ignore){var n=a.label,i=n.getComputedTransform(),o=n.getBoundingRect(),s=!i||i[1]<1e-5&&i[2]<1e-5,l=n.style.margin||0,u=o.clone();u.applyTransform(i),u.x-=l/2,u.y-=l/2,u.width+=l,u.height+=l;var c=s?new os(o,i):null;e.push({label:n,labelLine:a.labelLine,rect:u,localRect:o,obb:c,priority:a.priority,defaultAttr:a.defaultAttr,layoutOption:a.computedLayoutOption,axisAligned:s,transform:i})}}return e}function Lx(r,e,t,a,n,i){var o=r.length;if(o<2)return;r.sort(function(T,C){return T.rect[e]-C.rect[e]});for(var s=0,l,u=!1,c=0,v=0;v<o;v++){var f=r[v],h=f.rect;l=h[e]-s,l<0&&(h[e]-=l,f.label[e]-=l,u=!0);var p=Math.max(-l,0);c+=p,s=h[e]+h[t]}c>0&&i&&b(-c/o,0,o);var d=r[0],g=r[o-1],y,m;S(),y<0&&_(-y,.8),m<0&&_(m,.8),S(),x(y,m,1),x(m,y,-1),S(),y<0&&A(-y),m<0&&A(m);function S(){y=d.rect[e]-a,m=n-g.rect[e]-g.rect[t]}function x(T,C,M){if(T<0){var D=Math.min(C,-T);if(D>0){b(D*M,0,o);var I=D+T;I<0&&_(-I*M,1)}else _(-T*M,1)}}function b(T,C,M){T!==0&&(u=!0);for(var D=C;D<M;D++){var I=r[D],L=I.rect;L[e]+=T,I.label[e]+=T}}function _(T,C){for(var M=[],D=0,I=1;I<o;I++){var L=r[I-1].rect,P=Math.max(r[I].rect[e]-L[e]-L[t],0);M.push(P),D+=P}if(D){var E=Math.min(Math.abs(T)/D,C);if(T>0)for(var I=0;I<o-1;I++){var k=M[I]*E;b(k,0,I+1)}else for(var I=o-1;I>0;I--){var k=M[I-1]*E;b(-k,I,o)}}}function A(T){var C=T<0?-1:1;T=Math.abs(T);for(var M=Math.ceil(T/(o-1)),D=0;D<o-1;D++)if(C>0?b(M,0,D+1):b(-M,o-D-1,o),T-=M,T<=0)return}return u}function bM(r,e,t,a){return Lx(r,"x","width",e,t,a)}function Px(r,e,t,a){return Lx(r,"y","height",e,t,a)}function Ex(r){var e=[];r.sort(function(d,g){return g.priority-d.priority});var t=new wt(0,0,0,0);function a(d){if(!d.ignore){var g=d.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}d.ignore=!0}for(var n=0;n<r.length;n++){var i=r[n],o=i.axisAligned,s=i.localRect,l=i.transform,u=i.label,c=i.labelLine;t.copy(i.rect),t.width-=.1,t.height-=.1,t.x+=.05,t.y+=.05;for(var v=i.obb,f=!1,h=0;h<e.length;h++){var p=e[h];if(t.intersect(p.rect)){if(o&&p.axisAligned){f=!0;break}if(p.obb||(p.obb=new os(p.localRect,p.transform)),v||(v=new os(s,l)),v.intersect(p.obb)){f=!0;break}}}f?(a(u),c&&a(c)):(u.attr("ignore",i.defaultAttr.ignore),c&&c.attr("ignore",i.defaultAttr.labelGuideIgnore),e.push(i))}}function wM(r){if(r){for(var e=[],t=0;t<r.length;t++)e.push(r[t].slice());return e}}function AM(r,e){var t=r.label,a=e&&e.getTextGuideLine();return{dataIndex:r.dataIndex,dataType:r.dataType,seriesIndex:r.seriesModel.seriesIndex,text:r.label.style.text,rect:r.hostRect,labelRect:r.rect,align:t.style.align,verticalAlign:t.style.verticalAlign,labelLinePoints:wM(a&&a.shape.points)}}var Up=["align","verticalAlign","width","height","fontSize"],le=new qa,ql=st(),TM=st();function wo(r,e,t){for(var a=0;a<t.length;a++){var n=t[a];e[n]!=null&&(r[n]=e[n])}}var Ao=["x","y","rotation"],CM=function(){function r(){this._labelList=[],this._chartViewList=[]}return r.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},r.prototype._addLabel=function(e,t,a,n,i){var o=n.style,s=n.__hostTarget,l=s.textConfig||{},u=n.getComputedTransform(),c=n.getBoundingRect().plain();wt.applyTransform(c,c,u),u?le.setLocalTransform(u):(le.x=le.y=le.rotation=le.originX=le.originY=0,le.scaleX=le.scaleY=1),le.rotation=sa(le.rotation);var v=n.__hostTarget,f;if(v){f=v.getBoundingRect().plain();var h=v.getComputedTransform();wt.applyTransform(f,f,h)}var p=f&&v.getTextGuideLine();this._labelList.push({label:n,labelLine:p,seriesModel:a,dataIndex:e,dataType:t,layoutOption:i,computedLayoutOption:null,rect:c,hostRect:f,priority:f?f.width*f.height:0,defaultAttr:{ignore:n.ignore,labelGuideIgnore:p&&p.ignore,x:le.x,y:le.y,scaleX:le.scaleX,scaleY:le.scaleY,rotation:le.rotation,style:{x:o.x,y:o.y,align:o.align,verticalAlign:o.verticalAlign,width:o.width,height:o.height,fontSize:o.fontSize},cursor:n.cursor,attachedPos:l.position,attachedRot:l.rotation}})},r.prototype.addLabelsOfSeries=function(e){var t=this;this._chartViewList.push(e);var a=e.__model,n=a.get("labelLayout");(X(n)||Wt(n).length)&&e.group.traverse(function(i){if(i.ignore)return!0;var o=i.getTextContent(),s=q(i);o&&!o.disableLabelLayout&&t._addLabel(s.dataIndex,s.dataType,a,o,n)})},r.prototype.updateLayoutConfig=function(e){var t=e.getWidth(),a=e.getHeight();function n(S,x){return function(){Wp(S,x)}}for(var i=0;i<this._labelList.length;i++){var o=this._labelList[i],s=o.label,l=s.__hostTarget,u=o.defaultAttr,c=void 0;X(o.layoutOption)?c=o.layoutOption(AM(o,l)):c=o.layoutOption,c=c||{},o.computedLayoutOption=c;var v=Math.PI/180;l&&l.setTextConfig({local:!1,position:c.x!=null||c.y!=null?null:u.attachedPos,rotation:c.rotate!=null?c.rotate*v:u.attachedRot,offset:[c.dx||0,c.dy||0]});var f=!1;if(c.x!=null?(s.x=F(c.x,t),s.setStyle("x",0),f=!0):(s.x=u.x,s.setStyle("x",u.style.x)),c.y!=null?(s.y=F(c.y,a),s.setStyle("y",0),f=!0):(s.y=u.y,s.setStyle("y",u.style.y)),c.labelLinePoints){var h=l.getTextGuideLine();h&&(h.setShape({points:c.labelLinePoints}),f=!1)}var p=ql(s);p.needsUpdateLabelLine=f,s.rotation=c.rotate!=null?c.rotate*v:u.rotation,s.scaleX=u.scaleX,s.scaleY=u.scaleY;for(var d=0;d<Up.length;d++){var g=Up[d];s.setStyle(g,c[g]!=null?c[g]:u.style[g])}if(c.draggable){if(s.draggable=!0,s.cursor="move",l){var y=o.seriesModel;if(o.dataIndex!=null){var m=o.seriesModel.getData(o.dataType);y=m.getItemModel(o.dataIndex)}s.on("drag",n(l,y.getModel("labelLine")))}}else s.off("drag"),s.cursor=u.cursor}},r.prototype.layout=function(e){var t=e.getWidth(),a=e.getHeight(),n=Ix(this._labelList),i=bt(n,function(l){return l.layoutOption.moveOverlap==="shiftX"}),o=bt(n,function(l){return l.layoutOption.moveOverlap==="shiftY"});bM(i,0,t),Px(o,0,a);var s=bt(n,function(l){return l.layoutOption.hideOverlap});Ex(s)},r.prototype.processLabelsOverall=function(){var e=this;w(this._chartViewList,function(t){var a=t.__model,n=t.ignoreLabelLineUpdate,i=a.isAnimationEnabled();t.group.traverse(function(o){if(o.ignore&&!o.forceLabelAnimation)return!0;var s=!n,l=o.getTextContent();!s&&l&&(s=ql(l).needsUpdateLabelLine),s&&e._updateLabelLine(o,a),i&&e._animateLabels(o,a)})})},r.prototype._updateLabelLine=function(e,t){var a=e.getTextContent(),n=q(e),i=n.dataIndex;if(a&&i!=null){var o=t.getData(n.dataType),s=o.getItemModel(i),l={},u=o.getItemVisual(i,"style");if(u){var c=o.getVisual("drawType");l.stroke=u[c]}var v=s.getModel("labelLine");nf(e,of(s),l),Wp(e,v)}},r.prototype._animateLabels=function(e,t){var a=e.getTextContent(),n=e.getTextGuideLine();if(a&&(e.forceLabelAnimation||!a.ignore&&!a.invisible&&!e.disableLabelAnimation&&!Ja(e))){var i=ql(a),o=i.oldLayout,s=q(e),l=s.dataIndex,u={x:a.x,y:a.y,rotation:a.rotation},c=t.getData(s.dataType);if(o){a.attr(o);var f=e.prevStates;f&&(ct(f,"select")>=0&&a.attr(i.oldLayoutSelect),ct(f,"emphasis")>=0&&a.attr(i.oldLayoutEmphasis)),ft(a,u,t,l)}else if(a.attr(u),!bn(a).valueAnimation){var v=St(a.style.opacity,1);a.style.opacity=0,Lt(a,{style:{opacity:v}},t,l)}if(i.oldLayout=u,a.states.select){var h=i.oldLayoutSelect={};wo(h,u,Ao),wo(h,a.states.select,Ao)}if(a.states.emphasis){var p=i.oldLayoutEmphasis={};wo(p,u,Ao),wo(p,a.states.emphasis,Ao)}_0(a,l,c,t,t)}if(n&&!n.ignore&&!n.invisible){var i=TM(n),o=i.oldLayout,d={points:n.shape.points};o?(n.attr({shape:o}),ft(n,{shape:d},t)):(n.setShape(d),n.style.strokePercent=0,Lt(n,{style:{strokePercent:1}},t)),i.oldLayout=d}},r}();const DM=CM;var jl=st();function MM(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){var n=jl(t).labelManager;n||(n=jl(t).labelManager=new DM),n.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,a){var n=jl(t).labelManager;a.updatedSeries.forEach(function(i){n.addLabelsOfSeries(t.getViewOfSeriesModel(i))}),n.updateLayoutConfig(t),n.layout(t),n.processLabelsOverall()})}function IM(r){r.registerPainter("svg",Ib)}function LM(r){r.registerPainter("canvas",Lb)}var PM=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t){return yr(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var a=new tt,n=Ht("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);a.add(n),n.setStyle(t.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=i==="none"?"circle":i,l=t.itemHeight*.8,u=Ht(s,(t.itemWidth-l)/2,(t.itemHeight-l)/2,l,l,t.itemStyle.fill);a.add(u),u.setStyle(t.itemStyle);var c=t.iconRotate==="inherit"?o:t.iconRotate||0;return u.rotation=c*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill="#fff",u.style.lineWidth=2),a},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(Et);const EM=PM;function un(r,e){var t=r.mapDimensionsAll("defaultedLabel"),a=t.length;if(a===1){var n=on(r,e,t[0]);return n!=null?n+"":null}else if(a){for(var i=[],o=0;o<t.length;o++)i.push(on(r,e,t[o]));return i.join(" ")}}function Rx(r,e){var t=r.mapDimensionsAll("defaultedLabel");if(!O(e))return e+"";for(var a=[],n=0;n<t.length;n++){var i=r.getDimensionIndex(t[n]);i>=0&&a.push(e[i])}return a.join(" ")}var RM=function(r){R(e,r);function e(t,a,n,i){var o=r.call(this)||this;return o.updateData(t,a,n,i),o}return e.prototype._createSymbol=function(t,a,n,i,o){this.removeAll();var s=Ht(t,-1,-1,2,2,null,o);s.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),s.drift=kM,this._symbolType=t,this.add(s)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){vr(this.childAt(0))},e.prototype.downplay=function(){fr(this.childAt(0))},e.prototype.setZ=function(t,a){var n=this.childAt(0);n.zlevel=t,n.z=a},e.prototype.setDraggable=function(t,a){var n=this.childAt(0);n.draggable=t,n.cursor=!a&&t?"move":n.cursor},e.prototype.updateData=function(t,a,n,i){this.silent=!1;var o=t.getItemVisual(a,"symbol")||"circle",s=t.hostModel,l=e.getSymbolSize(t,a),u=o!==this._symbolType,c=i&&i.disableAnimation;if(u){var v=t.getItemVisual(a,"symbolKeepAspect");this._createSymbol(o,t,a,l,v)}else{var f=this.childAt(0);f.silent=!1;var h={scaleX:l[0]/2,scaleY:l[1]/2};c?f.attr(h):ft(f,h,s,a),We(f)}if(this._updateCommon(t,a,l,n,i),u){var f=this.childAt(0);if(!c){var h={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:f.style.opacity}};f.scaleX=f.scaleY=0,f.style.opacity=0,Lt(f,h,s,a)}}c&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,a,n,i,o){var s=this.childAt(0),l=t.hostModel,u,c,v,f,h,p,d,g,y;if(i&&(u=i.emphasisItemStyle,c=i.blurItemStyle,v=i.selectItemStyle,f=i.focus,h=i.blurScope,d=i.labelStatesModels,g=i.hoverScale,y=i.cursorStyle,p=i.emphasisDisabled),!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(a),S=m.getModel("emphasis");u=S.getModel("itemStyle").getItemStyle(),v=m.getModel(["select","itemStyle"]).getItemStyle(),c=m.getModel(["blur","itemStyle"]).getItemStyle(),f=S.get("focus"),h=S.get("blurScope"),p=S.get("disabled"),d=Kt(m),g=S.getShallow("scale"),y=m.getShallow("cursor")}var x=t.getItemVisual(a,"symbolRotate");s.attr("rotation",(x||0)*Math.PI/180||0);var b=Ia(t.getItemVisual(a,"symbolOffset"),n);b&&(s.x=b[0],s.y=b[1]),y&&s.attr("cursor",y);var _=t.getItemVisual(a,"style"),A=_.fill;if(s instanceof ke){var T=s.style;s.useStyle(B({image:T.image,x:T.x,y:T.y,width:T.width,height:T.height},_))}else s.__isEmptyBrush?s.useStyle(B({},_)):s.useStyle(_),s.style.decal=null,s.setColor(A,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var C=t.getItemVisual(a,"liftZ"),M=this._z2;C!=null?M==null&&(this._z2=s.z2,s.z2+=C):M!=null&&(s.z2=M,this._z2=null);var D=o&&o.useNameLabel;ae(s,d,{labelFetcher:l,labelDataIndex:a,defaultText:I,inheritColor:A,defaultOpacity:_.opacity});function I(E){return D?t.getName(E):un(t,E)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var L=s.ensureState("emphasis");L.style=u,s.ensureState("select").style=v,s.ensureState("blur").style=c;var P=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;L.scaleX=this._sizeX*P,L.scaleY=this._sizeY*P,this.setSymbolScale(1),Nt(this,f,h,p)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,a,n){var i=this.childAt(0),o=q(this).dataIndex,s=n&&n.animation;if(this.silent=i.silent=!0,n&&n.fadeLabel){var l=i.getTextContent();l&&Or(l,{style:{opacity:0}},a,{dataIndex:o,removeOpt:s,cb:function(){i.removeTextContent()}})}else i.removeTextContent();Or(i,{style:{opacity:0},scaleX:0,scaleY:0},a,{dataIndex:o,cb:t,removeOpt:s})},e.getSymbolSize=function(t,a){return Ln(t.getItemVisual(a,"symbolSize"))},e}(tt);function kM(r,e){this.parent.drift(r,e)}const Qi=RM;function Jl(r,e,t,a){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(a.isIgnore&&a.isIgnore(t))&&!(a.clipShape&&!a.clipShape.contain(e[0],e[1]))&&r.getItemVisual(t,"symbol")!=="none"}function Yp(r){return r!=null&&!j(r)&&(r={isIgnore:r}),r||{}}function Zp(r){var e=r.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:Kt(e),cursorStyle:e.get("cursor")}}var NM=function(){function r(e){this.group=new tt,this._SymbolCtor=e||Qi}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=Yp(t);var a=this.group,n=e.hostModel,i=this._data,o=this._SymbolCtor,s=t.disableAnimation,l=Zp(e),u={disableAnimation:s},c=t.getSymbolPoint||function(v){return e.getItemLayout(v)};i||a.removeAll(),e.diff(i).add(function(v){var f=c(v);if(Jl(e,f,v,t)){var h=new o(e,v,l,u);h.setPosition(f),e.setItemGraphicEl(v,h),a.add(h)}}).update(function(v,f){var h=i.getItemGraphicEl(f),p=c(v);if(!Jl(e,p,v,t)){a.remove(h);return}var d=e.getItemVisual(v,"symbol")||"circle",g=h&&h.getSymbolType&&h.getSymbolType();if(!h||g&&g!==d)a.remove(h),h=new o(e,v,l,u),h.setPosition(p);else{h.updateData(e,v,l,u);var y={x:p[0],y:p[1]};s?h.attr(y):ft(h,y,n)}a.add(h),e.setItemGraphicEl(v,h)}).remove(function(v){var f=i.getItemGraphicEl(v);f&&f.fadeOut(function(){a.remove(f)},n)}).execute(),this._getSymbolPoint=c,this._data=e},r.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(a,n){var i=e._getSymbolPoint(n);a.setPosition(i),a.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=Zp(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,a){this._progressiveEls=[],a=Yp(a);function n(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var i=e.start;i<e.end;i++){var o=t.getItemLayout(i);if(Jl(t,o,i,a)){var s=new this._SymbolCtor(t,i,this._seriesScope);s.traverse(n),s.setPosition(o),this.group.add(s),t.setItemGraphicEl(i,s),this._progressiveEls.push(s)}}},r.prototype.eachRendered=function(e){Wr(this._progressiveEls||this.group,e)},r.prototype.remove=function(e){var t=this.group,a=this._data;a&&e?a.eachItemGraphicEl(function(n){n.fadeOut(function(){t.remove(n)},a.hostModel)}):t.removeAll()},r}();const to=NM;function kx(r,e,t){var a=r.getBaseAxis(),n=r.getOtherAxis(a),i=OM(n,t),o=a.dim,s=n.dim,l=e.mapDimension(s),u=e.mapDimension(o),c=s==="x"||s==="radius"?1:0,v=G(r.dimensions,function(p){return e.mapDimension(p)}),f=!1,h=e.getCalculationInfo("stackResultDimension");return Br(e,v[0])&&(f=!0,v[0]=h),Br(e,v[1])&&(f=!0,v[1]=h),{dataDimsForPoint:v,valueStart:i,valueAxisDim:s,baseAxisDim:o,stacked:!!f,valueDim:l,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function OM(r,e){var t=0,a=r.scale.getExtent();return e==="start"?t=a[0]:e==="end"?t=a[1]:gt(e)&&!isNaN(e)?t=e:a[0]>0?t=a[0]:a[1]<0&&(t=a[1]),t}function Nx(r,e,t,a){var n=NaN;r.stacked&&(n=t.get(t.getCalculationInfo("stackedOverDimension"),a)),isNaN(n)&&(n=r.valueStart);var i=r.baseDataOffset,o=[];return o[i]=t.get(r.baseDim,a),o[1-i]=n,e.dataToPoint(o)}function VM(r,e){var t=[];return e.diff(r).add(function(a){t.push({cmd:"+",idx:a})}).update(function(a,n){t.push({cmd:"=",idx:n,idx1:a})}).remove(function(a){t.push({cmd:"-",idx:a})}).execute(),t}function BM(r,e,t,a,n,i,o,s){for(var l=VM(r,e),u=[],c=[],v=[],f=[],h=[],p=[],d=[],g=kx(n,e,o),y=r.getLayout("points")||[],m=e.getLayout("points")||[],S=0;S<l.length;S++){var x=l[S],b=!0,_=void 0,A=void 0;switch(x.cmd){case"=":_=x.idx*2,A=x.idx1*2;var T=y[_],C=y[_+1],M=m[A],D=m[A+1];(isNaN(T)||isNaN(C))&&(T=M,C=D),u.push(T,C),c.push(M,D),v.push(t[_],t[_+1]),f.push(a[A],a[A+1]),d.push(e.getRawIndex(x.idx1));break;case"+":var I=x.idx,L=g.dataDimsForPoint,P=n.dataToPoint([e.get(L[0],I),e.get(L[1],I)]);A=I*2,u.push(P[0],P[1]),c.push(m[A],m[A+1]);var E=Nx(g,n,e,I);v.push(E[0],E[1]),f.push(a[A],a[A+1]),d.push(e.getRawIndex(I));break;case"-":b=!1}b&&(h.push(x),p.push(p.length))}p.sort(function(pt,yt){return d[pt]-d[yt]});for(var k=u.length,V=je(k),N=je(k),z=je(k),H=je(k),Y=[],S=0;S<p.length;S++){var et=p[S],rt=S*2,nt=et*2;V[rt]=u[nt],V[rt+1]=u[nt+1],N[rt]=c[nt],N[rt+1]=c[nt+1],z[rt]=v[nt],z[rt+1]=v[nt+1],H[rt]=f[nt],H[rt+1]=f[nt+1],Y[S]=h[et]}return{current:V,next:N,stackedOnCurrent:z,stackedOnNext:H,status:Y}}var wr=Math.min,Ar=Math.max;function ga(r,e){return isNaN(r)||isNaN(e)}function kc(r,e,t,a,n,i,o,s,l){for(var u,c,v,f,h,p,d=t,g=0;g<a;g++){var y=e[d*2],m=e[d*2+1];if(d>=n||d<0)break;if(ga(y,m)){if(l){d+=i;continue}break}if(d===t)r[i>0?"moveTo":"lineTo"](y,m),v=y,f=m;else{var S=y-u,x=m-c;if(S*S+x*x<.5){d+=i;continue}if(o>0){for(var b=d+i,_=e[b*2],A=e[b*2+1];_===y&&A===m&&g<a;)g++,b+=i,d+=i,_=e[b*2],A=e[b*2+1],y=e[d*2],m=e[d*2+1],S=y-u,x=m-c;var T=g+1;if(l)for(;ga(_,A)&&T<a;)T++,b+=i,_=e[b*2],A=e[b*2+1];var C=.5,M=0,D=0,I=void 0,L=void 0;if(T>=a||ga(_,A))h=y,p=m;else{M=_-u,D=A-c;var P=y-u,E=_-y,k=m-c,V=A-m,N=void 0,z=void 0;if(s==="x"){N=Math.abs(P),z=Math.abs(E);var H=M>0?1:-1;h=y-H*N*o,p=m,I=y+H*z*o,L=m}else if(s==="y"){N=Math.abs(k),z=Math.abs(V);var Y=D>0?1:-1;h=y,p=m-Y*N*o,I=y,L=m+Y*z*o}else N=Math.sqrt(P*P+k*k),z=Math.sqrt(E*E+V*V),C=z/(z+N),h=y-M*o*(1-C),p=m-D*o*(1-C),I=y+M*o*C,L=m+D*o*C,I=wr(I,Ar(_,y)),L=wr(L,Ar(A,m)),I=Ar(I,wr(_,y)),L=Ar(L,wr(A,m)),M=I-y,D=L-m,h=y-M*N/z,p=m-D*N/z,h=wr(h,Ar(u,y)),p=wr(p,Ar(c,m)),h=Ar(h,wr(u,y)),p=Ar(p,wr(c,m)),M=y-h,D=m-p,I=y+M*z/N,L=m+D*z/N}r.bezierCurveTo(v,f,h,p,y,m),v=I,f=L}else r.lineTo(y,m)}u=y,c=m,d+=i}return g}var Ox=function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r}(),zM=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-polyline",a}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Ox},e.prototype.buildPath=function(t,a){var n=a.points,i=0,o=n.length/2;if(a.connectNulls){for(;o>0&&ga(n[o*2-2],n[o*2-1]);o--);for(;i<o&&ga(n[i*2],n[i*2+1]);i++);}for(;i<o;)i+=kc(t,n,i,o,o,1,a.smooth,a.smoothMonotone,a.connectNulls)+1},e.prototype.getPointOn=function(t,a){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path,i=n.data,o=Vm.CMD,s,l,u=a==="x",c=[],v=0;v<i.length;){var f=i[v++],h=void 0,p=void 0,d=void 0,g=void 0,y=void 0,m=void 0,S=void 0;switch(f){case o.M:s=i[v++],l=i[v++];break;case o.L:if(h=i[v++],p=i[v++],S=u?(t-s)/(h-s):(t-l)/(p-l),S<=1&&S>=0){var x=u?(p-l)*S+l:(h-s)*S+s;return u?[t,x]:[x,t]}s=h,l=p;break;case o.C:h=i[v++],p=i[v++],d=i[v++],g=i[v++],y=i[v++],m=i[v++];var b=u?ih(s,h,d,y,t,c):ih(l,p,g,m,t,c);if(b>0)for(var _=0;_<b;_++){var A=c[_];if(A<=1&&A>=0){var x=u?oh(l,p,g,m,A):oh(s,h,d,y,A);return u?[t,x]:[x,t]}}s=y,l=m;break}}},e}(It),GM=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e}(Ox),Vx=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-polygon",a}return e.prototype.getDefaultShape=function(){return new GM},e.prototype.buildPath=function(t,a){var n=a.points,i=a.stackedOnPoints,o=0,s=n.length/2,l=a.smoothMonotone;if(a.connectNulls){for(;s>0&&ga(n[s*2-2],n[s*2-1]);s--);for(;o<s&&ga(n[o*2],n[o*2+1]);o++);}for(;o<s;){var u=kc(t,n,o,s,s,1,a.smooth,l,a.connectNulls);kc(t,i,o+u-1,u,s,-1,a.stackedOnSmooth,l,a.connectNulls),o+=u+1,t.closePath()}},e}(It);function Bx(r,e,t,a,n){var i=r.getArea(),o=i.x,s=i.y,l=i.width,u=i.height,c=t.get(["lineStyle","width"])||2;o-=c/2,s-=c/2,l+=c,u+=c,o=Math.floor(o),l=Math.round(l);var v=new ht({shape:{x:o,y:s,width:l,height:u}});if(e){var f=r.getBaseAxis(),h=f.isHorizontal(),p=f.inverse;h?(p&&(v.shape.x+=l),v.shape.width=0):(p||(v.shape.y+=u),v.shape.height=0);var d=X(n)?function(g){n(g,v)}:null;Lt(v,{shape:{width:l,height:u,x:o,y:s}},t,null,a,d)}return v}function zx(r,e,t){var a=r.getArea(),n=Vt(a.r0,1),i=Vt(a.r,1),o=new Pe({shape:{cx:Vt(r.cx,1),cy:Vt(r.cy,1),r0:n,r:i,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}});if(e){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=a.startAngle:o.shape.r=n,Lt(o,{shape:{endAngle:a.endAngle,r:i}},t)}return o}function fl(r,e,t,a,n){if(r){if(r.type==="polar")return zx(r,e,t);if(r.type==="cartesian2d")return Bx(r,e,t,a,n)}else return null;return null}function Pa(r,e){return r.type===e}function Xp(r,e){if(r.length===e.length){for(var t=0;t<r.length;t++)if(r[t]!==e[t])return;return!0}}function Kp(r){for(var e=1/0,t=1/0,a=-1/0,n=-1/0,i=0;i<r.length;){var o=r[i++],s=r[i++];isNaN(o)||(e=Math.min(o,e),a=Math.max(o,a)),isNaN(s)||(t=Math.min(s,t),n=Math.max(s,n))}return[[e,t],[a,n]]}function qp(r,e){var t=Kp(r),a=t[0],n=t[1],i=Kp(e),o=i[0],s=i[1];return Math.max(Math.abs(a[0]-o[0]),Math.abs(a[1]-o[1]),Math.abs(n[0]-s[0]),Math.abs(n[1]-s[1]))}function jp(r){return gt(r)?r:r?.5:0}function FM(r,e,t){if(!t.valueDim)return[];for(var a=e.count(),n=je(a*2),i=0;i<a;i++){var o=Nx(t,r,e,i);n[i*2]=o[0],n[i*2+1]=o[1]}return n}function Tr(r,e,t,a){var n=e.getBaseAxis(),i=n.dim==="x"||n.dim==="radius"?0:1,o=[],s=0,l=[],u=[],c=[],v=[];if(a){for(s=0;s<r.length;s+=2)!isNaN(r[s])&&!isNaN(r[s+1])&&v.push(r[s],r[s+1]);r=v}for(s=0;s<r.length-2;s+=2)switch(c[0]=r[s+2],c[1]=r[s+3],u[0]=r[s],u[1]=r[s+1],o.push(u[0],u[1]),t){case"end":l[i]=c[i],l[1-i]=u[1-i],o.push(l[0],l[1]);break;case"middle":var f=(u[i]+c[i])/2,h=[];l[i]=h[i]=f,l[1-i]=u[1-i],h[1-i]=c[1-i],o.push(l[0],l[1]),o.push(h[0],h[1]);break;default:l[i]=u[i],l[1-i]=c[1-i],o.push(l[0],l[1])}return o.push(r[s++],r[s++]),o}function HM(r,e){var t=[],a=r.length,n,i;function o(c,v,f){var h=c.coord,p=(f-h)/(v.coord-h),d=Pb(p,[c.color,v.color]);return{coord:f,color:d}}for(var s=0;s<a;s++){var l=r[s],u=l.coord;if(u<0)n=l;else if(u>e){i?t.push(o(i,l,e)):n&&t.push(o(n,l,0),o(n,l,e));break}else n&&(t.push(o(n,l,0)),n=null),t.push(l),i=l}return t}function WM(r,e,t){var a=r.getVisual("visualMeta");if(!(!a||!a.length||!r.count())&&e.type==="cartesian2d"){for(var n,i,o=a.length-1;o>=0;o--){var s=r.getDimensionInfo(a[o].dimension);if(n=s&&s.coordDim,n==="x"||n==="y"){i=a[o];break}}if(i){var l=e.getAxis(n),u=G(i.stops,function(S){return{coord:l.toGlobalCoord(l.dataToCoord(S.value)),color:S.color}}),c=u.length,v=i.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),v.reverse());var f=HM(u,n==="x"?t.getWidth():t.getHeight()),h=f.length;if(!h&&c)return u[0].coord<0?v[1]?v[1]:u[c-1].color:v[0]?v[0]:u[0].color;var p=10,d=f[0].coord-p,g=f[h-1].coord+p,y=g-d;if(y<.001)return"transparent";w(f,function(S){S.offset=(S.coord-d)/y}),f.push({offset:h?f[h-1].offset:.5,color:v[1]||"transparent"}),f.unshift({offset:h?f[0].offset:.5,color:v[0]||"transparent"});var m=new $s(0,0,0,0,f,!0);return m[n]=d,m[n+"2"]=g,m}}}function $M(r,e,t){var a=r.get("showAllSymbol"),n=a==="auto";if(!(a&&!n)){var i=t.getAxesByScale("ordinal")[0];if(i&&!(n&&UM(i,e))){var o=e.mapDimension(i.dim),s={};return w(i.getViewLabels(),function(l){var u=i.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(e.get(o,l))}}}}function UM(r,e){var t=r.getExtent(),a=Math.abs(t[1]-t[0])/r.scale.count();isNaN(a)&&(a=0);for(var n=e.count(),i=Math.max(1,Math.round(n/5)),o=0;o<n;o+=i)if(Qi.getSymbolSize(e,o)[r.isHorizontal()?1:0]*1.5>a)return!1;return!0}function YM(r,e){return isNaN(r)||isNaN(e)}function ZM(r){for(var e=r.length/2;e>0&&YM(r[e*2-2],r[e*2-1]);e--);return e-1}function Jp(r,e){return[r[e*2],r[e*2+1]]}function XM(r,e,t){for(var a=r.length/2,n=t==="x"?0:1,i,o,s=0,l=-1,u=0;u<a;u++)if(o=r[u*2+n],!(isNaN(o)||isNaN(r[u*2+1-n]))){if(u===0){i=o;continue}if(i<=e&&o>=e||i>=e&&o<=e){l=u;break}s=u,i=o}return{range:[s,l],t:(e-i)/(o-i)}}function Gx(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e<pe.length;e++)if(r.get([pe[e],"endLabel","show"]))return!0;return!1}function Ql(r,e,t,a){if(Pa(e,"cartesian2d")){var n=a.getModel("endLabel"),i=n.get("valueAnimation"),o=a.getData(),s={lastFrameIndex:0},l=Gx(a)?function(h,p){r._endLabelOnDuring(h,p,o,s,i,n,e)}:null,u=e.getBaseAxis().isHorizontal(),c=Bx(e,t,a,function(){var h=r._endLabel;h&&t&&s.originalX!=null&&h.attr({x:s.originalX,y:s.originalY})},l);if(!a.get("clip",!0)){var v=c.shape,f=Math.max(v.width,v.height);u?(v.y-=f,v.height+=f*2):(v.x-=f,v.width+=f*2)}return l&&l(1,c),c}else return zx(e,t,a)}function KM(r,e){var t=e.getBaseAxis(),a=t.isHorizontal(),n=t.inverse,i=a?n?"right":"left":"center",o=a?"middle":n?"top":"bottom";return{normal:{align:r.get("align")||i,verticalAlign:r.get("verticalAlign")||o}}}var qM=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=new tt,a=new to;this.group.add(a.group),this._symbolDraw=a,this._lineGroup=t},e.prototype.render=function(t,a,n){var i=this,o=t.coordinateSystem,s=this.group,l=t.getData(),u=t.getModel("lineStyle"),c=t.getModel("areaStyle"),v=l.getLayout("points")||[],f=o.type==="polar",h=this._coordSys,p=this._symbolDraw,d=this._polyline,g=this._polygon,y=this._lineGroup,m=!a.ssr&&t.isAnimationEnabled(),S=!c.isEmpty(),x=c.get("origin"),b=kx(o,l,x),_=S&&FM(o,l,b),A=t.get("showSymbol"),T=t.get("connectNulls"),C=A&&!f&&$M(t,l,o),M=this._data;M&&M.eachItemGraphicEl(function(yt,vt){yt.__temp&&(s.remove(yt),M.setItemGraphicEl(vt,null))}),A||p.remove(),s.add(y);var D=f?!1:t.get("step"),I;o&&o.getArea&&t.get("clip",!0)&&(I=o.getArea(),I.width!=null?(I.x-=.1,I.y-=.1,I.width+=.2,I.height+=.2):I.r0&&(I.r0-=.5,I.r+=.5)),this._clipShapeForSymbol=I;var L=WM(l,o,n)||l.getVisual("style")[l.getVisual("drawType")];if(!(d&&h.type===o.type&&D===this._step))A&&p.updateData(l,{isIgnore:C,clipShape:I,disableAnimation:!0,getSymbolPoint:function(yt){return[v[yt*2],v[yt*2+1]]}}),m&&this._initSymbolLabelAnimation(l,o,I),D&&(v=Tr(v,o,D,T),_&&(_=Tr(_,o,D,T))),d=this._newPolyline(v),S?g=this._newPolygon(v,_):g&&(y.remove(g),g=this._polygon=null),f||this._initOrUpdateEndLabel(t,o,Ta(L)),y.setClipPath(Ql(this,o,!0,t));else{S&&!g?g=this._newPolygon(v,_):g&&!S&&(y.remove(g),g=this._polygon=null),f||this._initOrUpdateEndLabel(t,o,Ta(L));var P=y.getClipPath();if(P){var E=Ql(this,o,!1,t);Lt(P,{shape:E.shape},t)}else y.setClipPath(Ql(this,o,!0,t));A&&p.updateData(l,{isIgnore:C,clipShape:I,disableAnimation:!0,getSymbolPoint:function(yt){return[v[yt*2],v[yt*2+1]]}}),(!Xp(this._stackedOnPoints,_)||!Xp(this._points,v))&&(m?this._doUpdateAnimation(l,_,o,n,D,x,T):(D&&(v=Tr(v,o,D,T),_&&(_=Tr(_,o,D,T))),d.setShape({points:v}),g&&g.setShape({points:v,stackedOnPoints:_})))}var k=t.getModel("emphasis"),V=k.get("focus"),N=k.get("blurScope"),z=k.get("disabled");if(d.useStyle(J(u.getLineStyle(),{fill:"none",stroke:L,lineJoin:"bevel"})),re(d,t,"lineStyle"),d.style.lineWidth>0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var H=d.getState("emphasis").style;H.lineWidth=+d.style.lineWidth+1}q(d).seriesIndex=t.seriesIndex,Nt(d,V,N,z);var Y=jp(t.get("smooth")),et=t.get("smoothMonotone");if(d.setShape({smooth:Y,smoothMonotone:et,connectNulls:T}),g){var rt=l.getCalculationInfo("stackedOnSeries"),nt=0;g.useStyle(J(c.getAreaStyle(),{fill:L,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),rt&&(nt=jp(rt.get("smooth"))),g.setShape({smooth:Y,stackedOnSmooth:nt,smoothMonotone:et,connectNulls:T}),re(g,t,"areaStyle"),q(g).seriesIndex=t.seriesIndex,Nt(g,V,N,z)}var pt=function(yt){i._changePolyState(yt)};l.eachItemGraphicEl(function(yt){yt&&(yt.onHoverStateChange=pt)}),this._polyline.onHoverStateChange=pt,this._data=l,this._coordSys=o,this._stackedOnPoints=_,this._points=v,this._step=D,this._valueOrigin=x,t.get("triggerLineEvent")&&(this.packEventData(t,d),g&&this.packEventData(t,g))},e.prototype.packEventData=function(t,a){q(a).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,a,n,i){var o=t.getData(),s=ba(o,i);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var c=l[s*2],v=l[s*2+1];if(isNaN(c)||isNaN(v)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(c,v))return;var f=t.get("zlevel")||0,h=t.get("z")||0;u=new Qi(o,s),u.x=c,u.y=v,u.setZ(f,h);var p=u.getSymbolPath().getTextContent();p&&(p.zlevel=f,p.z=h,p.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else Mt.prototype.highlight.call(this,t,a,n,i)},e.prototype.downplay=function(t,a,n,i){var o=t.getData(),s=ba(o,i);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 Mt.prototype.downplay.call(this,t,a,n,i)},e.prototype._changePolyState=function(t){var a=this._polygon;hs(this._polyline,t),a&&hs(a,t)},e.prototype._newPolyline=function(t){var a=this._polyline;return a&&this._lineGroup.remove(a),a=new zM({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(a),this._polyline=a,a},e.prototype._newPolygon=function(t,a){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Vx({shape:{points:t,stackedOnPoints:a},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},e.prototype._initSymbolLabelAnimation=function(t,a,n){var i,o,s=a.getBaseAxis(),l=s.inverse;a.type==="cartesian2d"?(i=s.isHorizontal(),o=!1):a.type==="polar"&&(i=s.dim==="angle",o=!0);var u=t.hostModel,c=u.get("animationDuration");X(c)&&(c=c(null));var v=u.get("animationDelay")||0,f=X(v)?v(null):v;t.eachItemGraphicEl(function(h,p){var d=h;if(d){var g=[h.x,h.y],y=void 0,m=void 0,S=void 0;if(n)if(o){var x=n,b=a.pointToCoord(g);i?(y=x.startAngle,m=x.endAngle,S=-b[1]/180*Math.PI):(y=x.r0,m=x.r,S=b[0])}else{var _=n;i?(y=_.x,m=_.x+_.width,S=h.x):(y=_.y+_.height,m=_.y,S=h.y)}var A=m===y?0:(S-y)/(m-y);l&&(A=1-A);var T=X(v)?v(p):c*A+f,C=d.getSymbolPath(),M=C.getTextContent();d.attr({scaleX:0,scaleY:0}),d.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:T}),M&&M.animateFrom({style:{opacity:0}},{duration:300,delay:T}),C.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,a,n){var i=t.getModel("endLabel");if(Gx(t)){var o=t.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 ut({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var c=ZM(l);c>=0&&(ae(s,Kt(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:c,defaultText:function(v,f,h){return h!=null?Rx(o,h):un(o,v)},enableTextSetter:!0},KM(i,a)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,a,n,i,o,s,l){var u=this._endLabel,c=this._polyline;if(u){t<1&&i.originalX==null&&(i.originalX=u.x,i.originalY=u.y);var v=n.getLayout("points"),f=n.hostModel,h=f.get("connectNulls"),p=s.get("precision"),d=s.get("distance")||0,g=l.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,S=a.shape,x=m?y?S.x:S.y+S.height:y?S.x+S.width:S.y,b=(y?d:0)*(m?-1:1),_=(y?0:-d)*(m?-1:1),A=y?"x":"y",T=XM(v,x,A),C=T.range,M=C[1]-C[0],D=void 0;if(M>=1){if(M>1&&!h){var I=Jp(v,C[0]);u.attr({x:I[0]+b,y:I[1]+_}),o&&(D=f.getRawValue(C[0]))}else{var I=c.getPointOn(x,A);I&&u.attr({x:I[0]+b,y:I[1]+_});var L=f.getRawValue(C[0]),P=f.getRawValue(C[1]);o&&(D=t0(n,p,L,P,T.t))}i.lastFrameIndex=C[0]}else{var E=t===1||i.lastFrameIndex>0?C[0]:0,I=Jp(v,E);o&&(D=f.getRawValue(E)),u.attr({x:I[0]+b,y:I[1]+_})}if(o){var k=bn(u);typeof k.setLabelText=="function"&&k.setLabelText(D)}}},e.prototype._doUpdateAnimation=function(t,a,n,i,o,s,l){var u=this._polyline,c=this._polygon,v=t.hostModel,f=BM(this._data,t,this._stackedOnPoints,a,this._coordSys,n,this._valueOrigin),h=f.current,p=f.stackedOnCurrent,d=f.next,g=f.stackedOnNext;if(o&&(h=Tr(f.current,n,o,l),p=Tr(f.stackedOnCurrent,n,o,l),d=Tr(f.next,n,o,l),g=Tr(f.stackedOnNext,n,o,l)),qp(h,d)>3e3||c&&qp(p,g)>3e3){u.stopAnimation(),u.setShape({points:d}),c&&(c.stopAnimation(),c.setShape({points:d,stackedOnPoints:g}));return}u.shape.__points=f.current,u.shape.points=h;var y={shape:{points:d}};f.current!==h&&(y.shape.__points=f.next),u.stopAnimation(),ft(u,y,v),c&&(c.setShape({points:h,stackedOnPoints:p}),c.stopAnimation(),ft(c,{shape:{stackedOnPoints:g}},v),u.shape.points!==c.shape.points&&(c.shape.points=u.shape.points));for(var m=[],S=f.status,x=0;x<S.length;x++){var b=S[x].cmd;if(b==="="){var _=t.getItemGraphicEl(S[x].idx1);_&&m.push({el:_,ptIdx:x})}}u.animators&&u.animators.length&&u.animators[0].during(function(){c&&c.dirtyShape();for(var A=u.shape.__points,T=0;T<m.length;T++){var C=m[T].el,M=m[T].ptIdx*2;C.x=A[M],C.y=A[M+1],C.markRedraw()}})},e.prototype.remove=function(t){var a=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(i,o){i.__temp&&(a.remove(i),n.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},e.type="line",e}(Mt);const jM=qM;function eo(r,e){return{seriesType:r,plan:Mn(),reset:function(t){var a=t.getData(),n=t.coordinateSystem,i=t.pipelineContext,o=e||i.large;if(n){var s=G(n.dimensions,function(h){return a.mapDimension(h)}).slice(0,2),l=s.length,u=a.getCalculationInfo("stackResultDimension");Br(a,s[0])&&(s[0]=u),Br(a,s[1])&&(s[1]=u);var c=a.getStore(),v=a.getDimensionIndex(s[0]),f=a.getDimensionIndex(s[1]);return l&&{progress:function(h,p){for(var d=h.end-h.start,g=o&&je(d*l),y=[],m=[],S=h.start,x=0;S<h.end;S++){var b=void 0;if(l===1){var _=c.get(v,S);b=n.dataToPoint(_,null,m)}else y[0]=c.get(v,S),y[1]=c.get(f,S),b=n.dataToPoint(y,null,m);o?(g[x++]=b[0],g[x++]=b[1]):p.setItemLayout(S,b.slice())}o&&p.setLayout("points",g)}}}}}}var JM={average:function(r){for(var e=0,t=0,a=0;a<r.length;a++)isNaN(r[a])||(e+=r[a],t++);return t===0?NaN:e/t},sum:function(r){for(var e=0,t=0;t<r.length;t++)e+=r[t]||0;return e},max:function(r){for(var e=-1/0,t=0;t<r.length;t++)r[t]>e&&(e=r[t]);return isFinite(e)?e:NaN},min:function(r){for(var e=1/0,t=0;t<r.length;t++)r[t]<e&&(e=r[t]);return isFinite(e)?e:NaN},nearest:function(r){return r[0]}},QM=function(r){return Math.round(r.length/2)};function Fx(r){return{seriesType:r,reset:function(e,t,a){var n=e.getData(),i=e.get("sampling"),o=e.coordinateSystem,s=n.count();if(s>10&&o.type==="cartesian2d"&&i){var l=o.getBaseAxis(),u=o.getOtherAxis(l),c=l.getExtent(),v=a.getDevicePixelRatio(),f=Math.abs(c[1]-c[0])*(v||1),h=Math.round(s/f);if(isFinite(h)&&h>1){i==="lttb"&&e.setData(n.lttbDownSample(n.mapDimension(u.dim),1/h));var p=void 0;$(i)?p=JM[i]:X(i)&&(p=i),p&&e.setData(n.downSample(n.mapDimension(u.dim),1/h,p,QM))}}}}}function tI(r){r.registerChartView(jM),r.registerSeriesModel(EM),r.registerLayout(eo("line",!0)),r.registerVisual({seriesType:"line",reset:function(e){var t=e.getData(),a=e.getModel("lineStyle").getLineStyle();a&&!a.stroke&&(a.stroke=t.getVisual("style").fill),t.setVisual("legendLineStyle",a)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Fx("line"))}var Hx=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){return yr(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,a,n){var i=this.coordinateSystem;if(i&&i.clampData){var o=i.clampData(t),s=i.dataToPoint(o);if(n)w(i.getAxes(),function(f,h){if(f.type==="category"&&a!=null){var p=f.getTicksCoords(),d=o[h],g=a[h]==="x1"||a[h]==="y1";if(g&&(d+=1),p.length<2)return;if(p.length===2){s[h]=f.toGlobalCoord(f.getExtent()[g?1:0]);return}for(var y=void 0,m=void 0,S=1,x=0;x<p.length;x++){var b=p[x].coord,_=x===p.length-1?p[x-1].tickValue+S:p[x].tickValue;if(_===d){m=b;break}else if(_<d)y=b;else if(y!=null&&_>d){m=(b+y)/2;break}x===1&&(S=_-p[0].tickValue)}m==null&&(y?y&&(m=p[p.length-1].coord):m=p[0].coord),s[h]=f.toGlobalCoord(m)}});else{var l=this.getData(),u=l.getLayout("offset"),c=l.getLayout("size"),v=i.getBaseAxis().isHorizontal()?0:1;s[v]+=u+c/2}return s}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(Et);Et.registerClass(Hx);const Ms=Hx;var eI=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(){return yr(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),a=this.get("largeThreshold");return a>t&&(t=a),t},e.prototype.brushSelector=function(t,a,n){return n.rect(a.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=$r(Ms.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),e}(Ms);const rI=eI;var aI=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r}(),nI=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="sausage",a}return e.prototype.getDefaultShape=function(){return new aI},e.prototype.buildPath=function(t,a){var n=a.cx,i=a.cy,o=Math.max(a.r0||0,0),s=Math.max(a.r,0),l=(s-o)*.5,u=o+l,c=a.startAngle,v=a.endAngle,f=a.clockwise,h=Math.PI*2,p=f?v-c<h:c-v<h;p||(c=v-(f?h:-h));var d=Math.cos(c),g=Math.sin(c),y=Math.cos(v),m=Math.sin(v);p?(t.moveTo(d*o+n,g*o+i),t.arc(d*u+n,g*u+i,l,-Math.PI+c,c,!f)):t.moveTo(d*s+n,g*s+i),t.arc(n,i,s,c,v,!f),t.arc(y*u+n,m*u+i,l,v-Math.PI*2,v-Math.PI,!f),o!==0&&t.arc(n,i,o,v,c,f)},e}(It);const Is=nI;function iI(r,e){e=e||{};var t=e.isRoundCap;return function(a,n,i){var o=n.position;if(!o||o instanceof Array)return sc(a,n,i);var s=r(o),l=n.distance!=null?n.distance:5,u=this.shape,c=u.cx,v=u.cy,f=u.r,h=u.r0,p=(f+h)/2,d=u.startAngle,g=u.endAngle,y=(d+g)/2,m=t?Math.abs(f-h)/2:0,S=Math.cos,x=Math.sin,b=c+f*S(d),_=v+f*x(d),A="left",T="top";switch(s){case"startArc":b=c+(h-l)*S(y),_=v+(h-l)*x(y),A="center",T="top";break;case"insideStartArc":b=c+(h+l)*S(y),_=v+(h+l)*x(y),A="center",T="bottom";break;case"startAngle":b=c+p*S(d)+To(d,l+m,!1),_=v+p*x(d)+Co(d,l+m,!1),A="right",T="middle";break;case"insideStartAngle":b=c+p*S(d)+To(d,-l+m,!1),_=v+p*x(d)+Co(d,-l+m,!1),A="left",T="middle";break;case"middle":b=c+p*S(y),_=v+p*x(y),A="center",T="middle";break;case"endArc":b=c+(f+l)*S(y),_=v+(f+l)*x(y),A="center",T="bottom";break;case"insideEndArc":b=c+(f-l)*S(y),_=v+(f-l)*x(y),A="center",T="top";break;case"endAngle":b=c+p*S(g)+To(g,l+m,!0),_=v+p*x(g)+Co(g,l+m,!0),A="left",T="middle";break;case"insideEndAngle":b=c+p*S(g)+To(g,-l+m,!0),_=v+p*x(g)+Co(g,-l+m,!0),A="right",T="middle";break;default:return sc(a,n,i)}return a=a||{},a.x=b,a.y=_,a.align=A,a.verticalAlign=T,a}}function oI(r,e,t,a){if(gt(a)){r.setTextConfig({rotation:a});return}else if(O(e)){r.setTextConfig({rotation:0});return}var n=r.shape,i=n.clockwise?n.startAngle:n.endAngle,o=n.clockwise?n.endAngle:n.startAngle,s=(i+o)/2,l,u=t(e);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":l=s;break;case"startAngle":case"insideStartAngle":l=i;break;case"endAngle":case"insideEndAngle":l=o;break;default:r.setTextConfig({rotation:0});return}var c=Math.PI*1.5-l;u==="middle"&&c>Math.PI/2&&c<Math.PI*1.5&&(c-=Math.PI),r.setTextConfig({rotation:c})}function To(r,e,t){return e*Math.sin(r)*(t?-1:1)}function Co(r,e,t){return e*Math.cos(r)*(t?1:-1)}function va(r,e,t){var a=r.get("borderRadius");if(a==null)return t?{cornerRadius:0}:null;O(a)||(a=[a,a,a,a]);var n=Math.abs(e.r||0-e.r0||0);return{cornerRadius:G(a,function(i){return an(i,n)})}}var tu=Math.max,eu=Math.min;function sI(r,e){var t=r.getArea&&r.getArea();if(Pa(r,"cartesian2d")){var a=r.getBaseAxis();if(a.type!=="category"||!a.onBand){var n=e.getLayout("bandWidth");a.isHorizontal()?(t.x-=n,t.width+=n*2):(t.y-=n,t.height+=n*2)}}return t}var lI=function(r){R(e,r);function e(){var t=r.call(this)||this;return t.type=e.type,t._isFirstFrame=!0,t}return e.prototype.render=function(t,a,n,i){this._model=t,this._removeOnRenderedListener(n),this._updateDrawMode(t);var o=t.get("coordinateSystem");(o==="cartesian2d"||o==="polar")&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,a,n):this._renderNormal(t,a,n,i))},e.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},e.prototype.incrementalRender=function(t,a){this._progressiveEls=[],this._incrementalRenderLarge(t,a)},e.prototype.eachRendered=function(t){Wr(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var a=t.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},e.prototype._renderNormal=function(t,a,n,i){var o=this.group,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.getBaseAxis(),v;u.type==="cartesian2d"?v=c.isHorizontal():u.type==="polar"&&(v=c.dim==="angle");var f=t.isAnimationEnabled()?t:null,h=uI(t,u);h&&this._enableRealtimeSort(h,s,n);var p=t.get("clip",!0)||h,d=sI(u,s);o.removeClipPath();var g=t.get("roundCap",!0),y=t.get("showBackground",!0),m=t.getModel("backgroundStyle"),S=m.get("borderRadius")||0,x=[],b=this._backgroundEls,_=i&&i.isInitSort,A=i&&i.type==="changeAxisOrder";function T(D){var I=Do[u.type](s,D),L=gI(u,v,I);return L.useStyle(m.getItemStyle()),u.type==="cartesian2d"?L.setShape("r",S):L.setShape("cornerRadius",S),x[D]=L,L}s.diff(l).add(function(D){var I=s.getItemModel(D),L=Do[u.type](s,D,I);if(y&&T(D),!(!s.hasValue(D)||!ad[u.type](L))){var P=!1;p&&(P=Qp[u.type](d,L));var E=td[u.type](t,s,D,L,v,f,c.model,!1,g);h&&(E.forceLabelAnimation=!0),nd(E,s,D,I,L,t,v,u.type==="polar"),_?E.attr({shape:L}):h?ed(h,f,E,L,D,v,!1,!1):Lt(E,{shape:L},t,D),s.setItemGraphicEl(D,E),o.add(E),E.ignore=P}}).update(function(D,I){var L=s.getItemModel(D),P=Do[u.type](s,D,L);if(y){var E=void 0;b.length===0?E=T(I):(E=b[I],E.useStyle(m.getItemStyle()),u.type==="cartesian2d"?E.setShape("r",S):E.setShape("cornerRadius",S),x[D]=E);var k=Do[u.type](s,D),V=$x(v,k,u);ft(E,{shape:V},f,D)}var N=l.getItemGraphicEl(I);if(!s.hasValue(D)||!ad[u.type](P)){o.remove(N);return}var z=!1;if(p&&(z=Qp[u.type](d,P),z&&o.remove(N)),N?We(N):N=td[u.type](t,s,D,P,v,f,c.model,!!N,g),h&&(N.forceLabelAnimation=!0),A){var H=N.getTextContent();if(H){var Y=bn(H);Y.prevValue!=null&&(Y.prevValue=Y.value)}}else nd(N,s,D,L,P,t,v,u.type==="polar");_?N.attr({shape:P}):h?ed(h,f,N,P,D,v,!0,A):ft(N,{shape:P},t,D,null),s.setItemGraphicEl(D,N),N.ignore=z,o.add(N)}).remove(function(D){var I=l.getItemGraphicEl(D);I&&bi(I,t,D)}).execute();var C=this._backgroundGroup||(this._backgroundGroup=new tt);C.removeAll();for(var M=0;M<x.length;++M)C.add(x[M]);o.add(C),this._backgroundEls=x,this._data=s},e.prototype._renderLarge=function(t,a,n){this._clear(),od(t,this.group),this._updateLargeClip(t)},e.prototype._incrementalRenderLarge=function(t,a){this._removeBackground(),od(a,this.group,this._progressiveEls,!0)},e.prototype._updateLargeClip=function(t){var a=t.get("clip",!0)&&fl(t.coordinateSystem,!1,t),n=this.group;a?n.setClipPath(a):n.removeClipPath()},e.prototype._enableRealtimeSort=function(t,a,n){var i=this;if(a.count()){var o=t.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(a,t,n),this._isFirstFrame=!1;else{var s=function(l){var u=a.getItemGraphicEl(l),c=u&&u.shape;return c&&Math.abs(o.isHorizontal()?c.height:c.width)||0};this._onRendered=function(){i._updateSortWithinSameData(a,s,o,n)},n.getZr().on("rendered",this._onRendered)}}},e.prototype._dataSort=function(t,a,n){var i=[];return t.each(t.mapDimension(a.dim),function(o,s){var l=n(s);l=l??NaN,i.push({dataIndex:s,mappedValue:l,ordinalNumber:o})}),i.sort(function(o,s){return s.mappedValue-o.mappedValue}),{ordinalNumbers:G(i,function(o){return o.ordinalNumber})}},e.prototype._isOrderChangedWithinSameData=function(t,a,n){for(var i=n.scale,o=t.mapDimension(n.dim),s=Number.MAX_VALUE,l=0,u=i.getOrdinalMeta().categories.length;l<u;++l){var c=t.rawIndexOf(o,i.getRawOrdinalNumber(l)),v=c<0?Number.MIN_VALUE:a(t.indexOfRawIndex(c));if(v>s)return!0;s=v}return!1},e.prototype._isOrderDifferentInView=function(t,a){for(var n=a.scale,i=n.getExtent(),o=Math.max(0,i[0]),s=Math.min(i[1],n.getOrdinalMeta().categories.length-1);o<=s;++o)if(t.ordinalNumbers[o]!==n.getRawOrdinalNumber(o))return!0},e.prototype._updateSortWithinSameData=function(t,a,n,i){if(this._isOrderChangedWithinSameData(t,a,n)){var o=this._dataSort(t,n,a);this._isOrderDifferentInView(o,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:o}))}},e.prototype._dispatchInitSort=function(t,a,n){var i=a.baseAxis,o=this._dataSort(t,i,function(s){return t.get(t.mapDimension(a.otherAxis.dim),s)});n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},e.prototype.remove=function(t,a){this._clear(this._model),this._removeOnRenderedListener(a)},e.prototype.dispose=function(t,a){this._removeOnRenderedListener(a)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var a=this.group,n=this._data;t&&t.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(i){bi(i,t,q(i).dataIndex)})):a.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(Mt),Qp={cartesian2d:function(r,e){var t=e.width<0?-1:1,a=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),a<0&&(e.y+=e.height,e.height=-e.height);var n=r.x+r.width,i=r.y+r.height,o=tu(e.x,r.x),s=eu(e.x+e.width,n),l=tu(e.y,r.y),u=eu(e.y+e.height,i),c=s<o,v=u<l;return e.x=c&&o>n?s:o,e.y=v&&l>i?u:l,e.width=c?0:s-o,e.height=v?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),a<0&&(e.y+=e.height,e.height=-e.height),c||v},polar:function(r,e){var t=e.r0<=e.r?1:-1;if(t<0){var a=e.r;e.r=e.r0,e.r0=a}var n=eu(e.r,r.r),i=tu(e.r0,r.r0);e.r=n,e.r0=i;var o=n-i<0;if(t<0){var a=e.r;e.r=e.r0,e.r0=a}return o}},td={cartesian2d:function(r,e,t,a,n,i,o,s,l){var u=new ht({shape:B({},a),z2:1});if(u.__dataIndex=t,u.name="item",i){var c=u.shape,v=n?"height":"width";c[v]=0}return u},polar:function(r,e,t,a,n,i,o,s,l){var u=!n&&l?Is:Pe,c=new u({shape:a,z2:1});c.name="item";var v=Wx(n);if(c.calculateTextPosition=iI(v,{isRoundCap:u===Is}),i){var f=c.shape,h=n?"r":"endAngle",p={};f[h]=n?a.r0:a.startAngle,p[h]=a[h],(s?ft:Lt)(c,{shape:p},i)}return c}};function uI(r,e){var t=r.get("realtimeSort",!0),a=e.getBaseAxis();if(t&&a.type==="category"&&e.type==="cartesian2d")return{baseAxis:a,otherAxis:e.getOtherAxis(a)}}function ed(r,e,t,a,n,i,o,s){var l,u;i?(u={x:a.x,width:a.width},l={y:a.y,height:a.height}):(u={y:a.y,height:a.height},l={x:a.x,width:a.width}),s||(o?ft:Lt)(t,{shape:l},e,n,null);var c=e?r.baseAxis.model:null;(o?ft:Lt)(t,{shape:u},c,n)}function rd(r,e){for(var t=0;t<e.length;t++)if(!isFinite(r[e[t]]))return!0;return!1}var cI=["x","y","width","height"],vI=["cx","cy","r","startAngle","endAngle"],ad={cartesian2d:function(r){return!rd(r,cI)},polar:function(r){return!rd(r,vI)}},Do={cartesian2d:function(r,e,t){var a=r.getItemLayout(e),n=t?hI(t,a):0,i=a.width>0?1:-1,o=a.height>0?1:-1;return{x:a.x+i*n/2,y:a.y+o*n/2,width:a.width-i*n,height:a.height-o*n}},polar:function(r,e,t){var a=r.getItemLayout(e);return{cx:a.cx,cy:a.cy,r0:a.r0,r:a.r,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}}};function fI(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function Wx(r){return function(e){var t=e?"Arc":"Angle";return function(a){switch(a){case"start":case"insideStart":case"end":case"insideEnd":return a+t;default:return a}}}(r)}function nd(r,e,t,a,n,i,o,s){var l=e.getItemVisual(t,"style");if(s){if(!i.get("roundCap")){var c=r.shape,v=va(a.getModel("itemStyle"),c,!0);B(c,v),r.setShape(c)}}else{var u=a.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var f=a.getShallow("cursor");f&&r.attr("cursor",f);var h=s?o?n.r>=n.r0?"endArc":"startArc":n.endAngle>=n.startAngle?"endAngle":"startAngle":o?n.height>=0?"bottom":"top":n.width>=0?"right":"left",p=Kt(a);ae(r,p,{labelFetcher:i,labelDataIndex:t,defaultText:un(i.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:h});var d=r.getTextContent();if(s&&d){var g=a.get(["label","position"]);r.textConfig.inside=g==="middle"?!0:null,oI(r,g==="outside"?h:g,Wx(o),a.get(["label","rotate"]))}x0(d,p,i.getRawValue(t),function(m){return Rx(e,m)});var y=a.getModel(["emphasis"]);Nt(r,y.get("focus"),y.get("blurScope"),y.get("disabled")),re(r,a),fI(n)&&(r.style.fill="none",r.style.stroke="none",w(r.states,function(m){m.style&&(m.style.fill=m.style.stroke="none")}))}function hI(r,e){var t=r.get(["itemStyle","borderColor"]);if(!t||t==="none")return 0;var a=r.get(["itemStyle","borderWidth"])||0,n=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),i=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(a,n,i)}var pI=function(){function r(){}return r}(),id=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeBar",a}return e.prototype.getDefaultShape=function(){return new pI},e.prototype.buildPath=function(t,a){for(var n=a.points,i=this.baseDimIdx,o=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,c=0;c<n.length;c+=3)l[i]=u,l[o]=n[c+2],s[i]=n[c+i],s[o]=n[c+o],t.rect(s[0],s[1],l[0],l[1])},e}(It);function od(r,e,t,a){var n=r.getData(),i=n.getLayout("valueAxisHorizontal")?1:0,o=n.getLayout("largeDataIndices"),s=n.getLayout("size"),l=r.getModel("backgroundStyle"),u=n.getLayout("largeBackgroundPoints");if(u){var c=new id({shape:{points:u},incremental:!!a,silent:!0,z2:0});c.baseDimIdx=i,c.largeDataIndices=o,c.barWidth=s,c.useStyle(l.getItemStyle()),e.add(c),t&&t.push(c)}var v=new id({shape:{points:n.getLayout("largePoints")},incremental:!!a,ignoreCoarsePointer:!0,z2:1});v.baseDimIdx=i,v.largeDataIndices=o,v.barWidth=s,e.add(v),v.useStyle(n.getVisual("style")),q(v).seriesIndex=r.seriesIndex,r.get("silent")||(v.on("mousedown",sd),v.on("mousemove",sd)),t&&t.push(v)}var sd=Uv(function(r){var e=this,t=dI(e,r.offsetX,r.offsetY);q(e).dataIndex=t>=0?t:null},30,!1);function dI(r,e,t){for(var a=r.baseDimIdx,n=1-a,i=r.shape.points,o=r.largeDataIndices,s=[],l=[],u=r.barWidth,c=0,v=i.length/3;c<v;c++){var f=c*3;if(l[a]=u,l[n]=i[f+2],s[a]=i[f+a],s[n]=i[f+n],l[n]<0&&(s[n]+=l[n],l[n]=-l[n]),e>=s[0]&&e<=s[0]+l[0]&&t>=s[1]&&t<=s[1]+l[1])return o[c]}return-1}function $x(r,e,t){if(Pa(t,"cartesian2d")){var a=e,n=t.getArea();return{x:r?a.x:n.x,y:r?n.y:a.y,width:r?a.width:n.width,height:r?n.height:a.height}}else{var n=t.getArea(),i=e;return{cx:n.cx,cy:n.cy,r0:r?n.r0:i.r0,r:r?n.r:i.r,startAngle:r?i.startAngle:0,endAngle:r?i.endAngle:Math.PI*2}}}function gI(r,e,t){var a=r.type==="polar"?Pe:ht;return new a({shape:$x(e,t,r),silent:!0,z2:0})}const yI=lI;function mI(r){r.registerChartView(yI),r.registerSeriesModel(rI),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Q(lx,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,ux("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Fx("bar")),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var a=e.componentType||"series";t.eachComponent({mainType:a,query:e},function(n){e.sortInfo&&n.axis.setCategorySortInfo(e.sortInfo)})})}var Mo=Math.PI*2,ld=Math.PI/180;function Ux(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function Yx(r,e){var t=Ux(r,e),a=r.get("center"),n=r.get("radius");O(n)||(n=[0,n]);var i=F(t.width,e.getWidth()),o=F(t.height,e.getHeight()),s=Math.min(i,o),l=F(n[0],s/2),u=F(n[1],s/2),c,v,f=r.coordinateSystem;if(f){var h=f.dataToPoint(a);c=h[0]||0,v=h[1]||0}else O(a)||(a=[a,a]),c=F(a[0],i)+t.x,v=F(a[1],o)+t.y;return{cx:c,cy:v,r0:l,r:u}}function SI(r,e,t){e.eachSeriesByType(r,function(a){var n=a.getData(),i=n.mapDimension("value"),o=Ux(a,t),s=Yx(a,t),l=s.cx,u=s.cy,c=s.r,v=s.r0,f=-a.get("startAngle")*ld,h=a.get("minAngle")*ld,p=0;n.each(i,function(M){!isNaN(M)&&p++});var d=n.getSum(i),g=Math.PI/(d||p)*2,y=a.get("clockwise"),m=a.get("roseType"),S=a.get("stillShowZeroSum"),x=n.getDataExtent(i);x[0]=0;var b=Mo,_=0,A=f,T=y?1:-1;if(n.setLayout({viewRect:o,r:c}),n.each(i,function(M,D){var I;if(isNaN(M)){n.setItemLayout(D,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:y,cx:l,cy:u,r0:v,r:m?NaN:c});return}m!=="area"?I=d===0&&S?g:M*g:I=Mo/p,I<h?(I=h,b-=h):_+=M;var L=A+T*I;n.setItemLayout(D,{angle:I,startAngle:A,endAngle:L,clockwise:y,cx:l,cy:u,r0:v,r:m?mt(M,x,[v,c]):c}),A=L}),b<Mo&&p)if(b<=.001){var C=Mo/p;n.each(i,function(M,D){if(!isNaN(M)){var I=n.getItemLayout(D);I.angle=C,I.startAngle=f+T*D*C,I.endAngle=f+T*(D+1)*C}})}else g=b/_,A=f,n.each(i,function(M,D){if(!isNaN(M)){var I=n.getItemLayout(D),L=I.angle===h?h:M*g;I.startAngle=A,I.endAngle=A+T*L,A+=T*L}})})}function ro(r){return{seriesType:r,reset:function(e,t){var a=t.findComponents({mainType:"legend"});if(!(!a||!a.length)){var n=e.getData();n.filterSelf(function(i){for(var o=n.getName(i),s=0;s<a.length;s++)if(!a[s].isSelected(o))return!1;return!0})}}}}var xI=Math.PI/180;function ud(r,e,t,a,n,i,o,s,l,u){if(r.length<2)return;function c(d){for(var g=d.rB,y=g*g,m=0;m<d.list.length;m++){var S=d.list[m],x=Math.abs(S.label.y-t),b=a+S.len,_=b*b,A=Math.sqrt((1-Math.abs(x*x/y))*_),T=e+(A+S.len2)*n,C=T-S.label.x,M=S.targetTextWidth-C*n;Zx(S,M,!0),S.label.x=T}}function v(d){for(var g={list:[],maxY:0},y={list:[],maxY:0},m=0;m<d.length;m++)if(d[m].labelAlignTo==="none"){var S=d[m],x=S.label.y>t?y:g,b=Math.abs(S.label.y-t);if(b>=x.maxY){var _=S.label.x-e-S.len2*n,A=a+S.len,T=Math.abs(_)<A?Math.sqrt(b*b/(1-_*_/A/A)):A;x.rB=T,x.maxY=b}x.list.push(S)}c(g),c(y)}for(var f=r.length,h=0;h<f;h++)if(r[h].position==="outer"&&r[h].labelAlignTo==="labelLine"){var p=r[h].label.x-u;r[h].linePoints[1][0]+=p,r[h].label.x=u}Px(r,l,l+o)&&v(r)}function _I(r,e,t,a,n,i,o,s){for(var l=[],u=[],c=Number.MAX_VALUE,v=-Number.MAX_VALUE,f=0;f<r.length;f++){var h=r[f].label;ru(r[f])||(h.x<e?(c=Math.min(c,h.x),l.push(r[f])):(v=Math.max(v,h.x),u.push(r[f])))}for(var f=0;f<r.length;f++){var p=r[f];if(!ru(p)&&p.linePoints){if(p.labelStyleWidth!=null)continue;var h=p.label,d=p.linePoints,g=void 0;p.labelAlignTo==="edge"?h.x<e?g=d[2][0]-p.labelDistance-o-p.edgeDistance:g=o+n-p.edgeDistance-d[2][0]-p.labelDistance:p.labelAlignTo==="labelLine"?h.x<e?g=c-o-p.bleedMargin:g=o+n-v-p.bleedMargin:h.x<e?g=h.x-o-p.bleedMargin:g=o+n-h.x-p.bleedMargin,p.targetTextWidth=g,Zx(p,g)}}ud(u,e,t,a,1,n,i,o,s,v),ud(l,e,t,a,-1,n,i,o,s,c);for(var f=0;f<r.length;f++){var p=r[f];if(!ru(p)&&p.linePoints){var h=p.label,d=p.linePoints,y=p.labelAlignTo==="edge",m=h.style.padding,S=m?m[1]+m[3]:0,x=h.style.backgroundColor?0:S,b=p.rect.width+x,_=d[1][0]-d[2][0];y?h.x<e?d[2][0]=o+p.edgeDistance+b+p.labelDistance:d[2][0]=o+n-p.edgeDistance-b-p.labelDistance:(h.x<e?d[2][0]=h.x+p.labelDistance:d[2][0]=h.x-p.labelDistance,d[1][0]=d[2][0]+_),d[1][1]=d[2][1]=h.y}}}function Zx(r,e,t){if(t===void 0&&(t=!1),r.labelStyleWidth==null){var a=r.label,n=a.style,i=r.rect,o=n.backgroundColor,s=n.padding,l=s?s[1]+s[3]:0,u=n.overflow,c=i.width+(o?0:l);if(e<c||t){var v=i.height;if(u&&u.match("break")){a.setStyle("backgroundColor",null),a.setStyle("width",e-l);var f=a.getBoundingRect();a.setStyle("width",Math.ceil(f.width)),a.setStyle("backgroundColor",o)}else{var h=e-l,p=e<c?h:t?h>r.unconstrainedWidth?null:h:null;a.setStyle("width",p)}var d=a.getBoundingRect();i.width=d.width;var g=(a.style.margin||0)+2.1;i.height=d.height+g,i.y-=(i.height-v)/2}}}function ru(r){return r.position==="center"}function bI(r){var e=r.getData(),t=[],a,n,i=!1,o=(r.get("minShowLabelAngle")||0)*xI,s=e.getLayout("viewRect"),l=e.getLayout("r"),u=s.width,c=s.x,v=s.y,f=s.height;function h(_){_.ignore=!0}function p(_){if(!_.ignore)return!0;for(var A in _.states)if(_.states[A].ignore===!1)return!0;return!1}e.each(function(_){var A=e.getItemGraphicEl(_),T=A.shape,C=A.getTextContent(),M=A.getTextGuideLine(),D=e.getItemModel(_),I=D.getModel("label"),L=I.get("position")||D.get(["emphasis","label","position"]),P=I.get("distanceToLabelLine"),E=I.get("alignTo"),k=F(I.get("edgeDistance"),u),V=I.get("bleedMargin"),N=D.getModel("labelLine"),z=N.get("length");z=F(z,u);var H=N.get("length2");if(H=F(H,u),Math.abs(T.endAngle-T.startAngle)<o){w(C.states,h),C.ignore=!0,M&&(w(M.states,h),M.ignore=!0);return}if(p(C)){var Y=(T.startAngle+T.endAngle)/2,et=Math.cos(Y),rt=Math.sin(Y),nt,pt,yt,vt;a=T.cx,n=T.cy;var at=L==="inside"||L==="inner";if(L==="center")nt=T.cx,pt=T.cy,vt="center";else{var At=(at?(T.r+T.r0)/2*et:T.r*et)+a,xt=(at?(T.r+T.r0)/2*rt:T.r*rt)+n;if(nt=At+et*3,pt=xt+rt*3,!at){var Rt=At+et*(z+l-T.r),Zt=xt+rt*(z+l-T.r),ne=Rt+(et<0?-1:1)*H,Pt=Zt;E==="edge"?nt=et<0?c+k:c+u-k:nt=ne+(et<0?-P:P),pt=Pt,yt=[[At,xt],[Rt,Zt],[ne,Pt]]}vt=at?"center":E==="edge"?et>0?"right":"left":et>0?"left":"right"}var $t=Math.PI,Xt=0,Se=I.get("rotate");if(gt(Se))Xt=Se*($t/180);else if(L==="center")Xt=0;else if(Se==="radial"||Se===!0){var so=et<0?-Y+$t:-Y;Xt=so}else if(Se==="tangential"&&L!=="outside"&&L!=="outer"){var ar=Math.atan2(et,rt);ar<0&&(ar=$t*2+ar);var fb=rt>0;fb&&(ar=$t+ar),Xt=ar-$t}if(i=!!Xt,C.x=nt,C.y=pt,C.rotation=Xt,C.setStyle({verticalAlign:"middle"}),at){C.setStyle({align:vt});var Sl=C.states.select;Sl&&(Sl.x+=C.x,Sl.y+=C.y)}else{var En=C.getBoundingRect().clone();En.applyTransform(C.getComputedTransform());var ah=(C.style.margin||0)+2.1;En.y-=ah/2,En.height+=ah,t.push({label:C,labelLine:M,position:L,len:z,len2:H,minTurnAngle:N.get("minTurnAngle"),maxSurfaceAngle:N.get("maxSurfaceAngle"),surfaceNormal:new Gt(et,rt),linePoints:yt,textAlign:vt,labelDistance:P,labelAlignTo:E,edgeDistance:k,bleedMargin:V,rect:En,unconstrainedWidth:En.width,labelStyleWidth:C.style.width})}A.setTextConfig({inside:at})}}),!i&&r.get("avoidLabelOverlap")&&_I(t,a,n,l,u,f,c,v);for(var d=0;d<t.length;d++){var g=t[d],y=g.label,m=g.labelLine,S=isNaN(y.x)||isNaN(y.y);if(y){y.setStyle({align:g.textAlign}),S&&(w(y.states,h),y.ignore=!0);var x=y.states.select;x&&(x.x+=y.x,x.y+=y.y)}if(m){var b=g.linePoints;S||!b?(w(m.states,h),m.ignore=!0):(Mx(b,g.minTurnAngle),xM(b,g.surfaceNormal,g.maxSurfaceAngle),m.setShape({points:b}),y.__hostTarget.textGuideLineConfig={anchor:new Gt(b[0][0],b[0][1])})}}}var wI=function(r){R(e,r);function e(t,a,n){var i=r.call(this)||this;i.z2=2;var o=new ut;return i.setTextContent(o),i.updateData(t,a,n,!0),i}return e.prototype.updateData=function(t,a,n,i){var o=this,s=t.hostModel,l=t.getItemModel(a),u=l.getModel("emphasis"),c=t.getItemLayout(a),v=B(va(l.getModel("itemStyle"),c,!0),c);if(isNaN(v.startAngle)){o.setShape(v);return}if(i){o.setShape(v);var f=s.getShallow("animationType");s.ecModel.ssr?(Lt(o,{scaleX:0,scaleY:0},s,{dataIndex:a,isFrom:!0}),o.originX=v.cx,o.originY=v.cy):f==="scale"?(o.shape.r=c.r0,Lt(o,{shape:{r:c.r}},s,a)):n!=null?(o.setShape({startAngle:n,endAngle:n}),Lt(o,{shape:{startAngle:c.startAngle,endAngle:c.endAngle}},s,a)):(o.shape.endAngle=c.startAngle,ft(o,{shape:{endAngle:c.endAngle}},s,a))}else We(o),ft(o,{shape:v},s,a);o.useStyle(t.getItemVisual(a,"style")),re(o,l);var h=(c.startAngle+c.endAngle)/2,p=s.get("selectedOffset"),d=Math.cos(h)*p,g=Math.sin(h)*p,y=l.getShallow("cursor");y&&o.attr("cursor",y),this._updateLabel(s,t,a),o.ensureState("emphasis").shape=B({r:c.r+(u.get("scale")&&u.get("scaleSize")||0)},va(u.getModel("itemStyle"),c)),B(o.ensureState("select"),{x:d,y:g,shape:va(l.getModel(["select","itemStyle"]),c)}),B(o.ensureState("blur"),{shape:va(l.getModel(["blur","itemStyle"]),c)});var m=o.getTextGuideLine(),S=o.getTextContent();m&&B(m.ensureState("select"),{x:d,y:g}),B(S.ensureState("select"),{x:d,y:g}),Nt(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,a,n){var i=this,o=a.getItemModel(n),s=o.getModel("labelLine"),l=a.getItemVisual(n,"style"),u=l&&l.fill,c=l&&l.opacity;ae(i,Kt(o),{labelFetcher:a.hostModel,labelDataIndex:n,inheritColor:u,defaultOpacity:c,defaultText:t.getFormattedLabel(n,"normal")||a.getName(n)});var v=i.getTextContent();i.setTextConfig({position:null,rotation:null}),v.attr({z2:10});var f=t.get(["label","position"]);if(f!=="outside"&&f!=="outer")i.removeTextGuideLine();else{var h=this.getTextGuideLine();h||(h=new me,this.setTextGuideLine(h)),nf(this,of(o),{stroke:u,opacity:gn(s.get(["lineStyle","opacity"]),c,1)})}},e}(Pe),AI=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,a,n,i){var o=t.getData(),s=this._data,l=this.group,u;if(!s&&o.count()>0){for(var c=o.getItemLayout(0),v=1;isNaN(c&&c.startAngle)&&v<o.count();++v)c=o.getItemLayout(v);c&&(u=c.startAngle)}if(this._emptyCircleSector&&l.remove(this._emptyCircleSector),o.count()===0&&t.get("showEmptyCircle")){var f=new Pe({shape:Yx(t,n)});f.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=f,l.add(f)}o.diff(s).add(function(h){var p=new wI(o,h,u);o.setItemGraphicEl(h,p),l.add(p)}).update(function(h,p){var d=s.getItemGraphicEl(p);d.updateData(o,h,u),d.off("click"),l.add(d),o.setItemGraphicEl(h,d)}).remove(function(h){var p=s.getItemGraphicEl(h);bi(p,t,h)}).execute(),bI(t),t.get("animationTypeUpdate")!=="expansion"&&(this._data=o)},e.prototype.dispose=function(){},e.prototype.containPoint=function(t,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="pie",e}(Mt);const TI=AI;function Pn(r,e,t){e=O(e)&&{coordDimensions:e}||B({encodeDefine:r.getEncode()},e);var a=r.getSource(),n=qi(a,e).dimensions,i=new fe(n,r);return i.initData(a,t),i}var CI=function(){function r(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return r.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},r.prototype.containName=function(e){var t=this._getRawData();return t.indexOfName(e)>=0},r.prototype.indexOfName=function(e){var t=this._getDataWithEncodedVisual();return t.indexOfName(e)},r.prototype.getItemVisual=function(e,t){var a=this._getDataWithEncodedVisual();return a.getItemVisual(e,t)},r}();const ao=CI;var DI=st(),MI=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new ao(W(this.getData,this),W(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Pn(this,{coordDimensions:["value"],encodeDefaulter:Q(Nv,this)})},e.prototype.getDataParams=function(t){var a=this.getData(),n=DI(a),i=n.seats;if(!i){var o=[];a.each(a.mapDimension("value"),function(l){o.push(l)}),i=n.seats=nw(o,a.hostModel.get("percentPrecision"))}var s=r.prototype.getDataParams.call(this,t);return s.percent=i[t]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(t){_a(t,"labelLine",["show"]);var a=t.labelLine,n=t.emphasis.labelLine;a.show=a.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(Et);const II=MI;function LI(r){return{seriesType:r,reset:function(e,t){var a=e.getData();a.filterSelf(function(n){var i=a.mapDimension("value"),o=a.get(i,n);return!(gt(o)&&!isNaN(o)&&o<0)})}}}function PI(r){r.registerChartView(TI),r.registerSeriesModel(II),MS("pie",r.registerAction),r.registerLayout(Q(SI,"pie")),r.registerProcessor(ro("pie")),r.registerProcessor(LI("pie"))}var EI=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,a){return yr(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?5e3:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?1e4:this.get("progressiveThreshold"))},e.prototype.brushSelector=function(t,a,n){return n.point(a.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},e}(Et);const RI=EI;var Xx=4,kI=function(){function r(){}return r}(),NI=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a._off=0,a.hoverDataIdx=-1,a}return e.prototype.getDefaultShape=function(){return new kI},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,a){var n=a.points,i=a.size,o=this.symbolProxy,s=o.shape,l=t.getContext?t.getContext():t,u=l&&i[0]<Xx,c=this.softClipShape,v;if(u){this._ctx=l;return}for(this._ctx=null,v=this._off;v<n.length;){var f=n[v++],h=n[v++];isNaN(f)||isNaN(h)||c&&!c.contain(f,h)||(s.x=f-i[0]/2,s.y=h-i[1]/2,s.width=i[0],s.height=i[1],o.buildPath(t,s,!0))}this.incremental&&(this._off=v,this.notClear=!0)},e.prototype.afterBrush=function(){var t=this.shape,a=t.points,n=t.size,i=this._ctx,o=this.softClipShape,s;if(i){for(s=this._off;s<a.length;){var l=a[s++],u=a[s++];isNaN(l)||isNaN(u)||o&&!o.contain(l,u)||i.fillRect(l-n[0]/2,u-n[1]/2,n[0],n[1])}this.incremental&&(this._off=s,this.notClear=!0)}},e.prototype.findDataIndex=function(t,a){for(var n=this.shape,i=n.points,o=n.size,s=Math.max(o[0],4),l=Math.max(o[1],4),u=i.length/2-1;u>=0;u--){var c=u*2,v=i[c]-s/2,f=i[c+1]-l/2;if(t>=v&&a>=f&&t<=v+s&&a<=f+l)return u}return-1},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();if(t=n[0],a=n[1],i.contain(t,a)){var o=this.hoverDataIdx=this.findDataIndex(t,a);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var a=this.shape,n=a.points,i=a.size,o=i[0],s=i[1],l=1/0,u=1/0,c=-1/0,v=-1/0,f=0;f<n.length;){var h=n[f++],p=n[f++];l=Math.min(h,l),c=Math.max(h,c),u=Math.min(p,u),v=Math.max(p,v)}t=this._rect=new wt(l-o/2,u-s/2,c-l+o,v-u+s)}return t},e}(It),OI=function(){function r(){this.group=new tt}return r.prototype.updateData=function(e,t){this._clear();var a=this._create();a.setShape({points:e.getLayout("points")}),this._setCommon(a,e,t)},r.prototype.updateLayout=function(e){var t=e.getLayout("points");this.group.eachChild(function(a){if(a.startIndex!=null){var n=(a.endIndex-a.startIndex)*2,i=a.startIndex*4*2;t=new Float32Array(t.buffer,i,n)}a.setShape("points",t),a.reset()})},r.prototype.incrementalPrepareUpdate=function(e){this._clear()},r.prototype.incrementalUpdate=function(e,t,a){var n=this._newAdded[0],i=t.getLayout("points"),o=n&&n.shape.points;if(o&&o.length<2e4){var s=o.length,l=new Float32Array(s+i.length);l.set(o),l.set(i,s),n.endIndex=e.end,n.setShape({points:l})}else{this._newAdded=[];var u=this._create();u.startIndex=e.start,u.endIndex=e.end,u.incremental=!0,u.setShape({points:i}),this._setCommon(u,t,a)}},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new NI({cursor:"default"});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},r.prototype._setCommon=function(e,t,a){var n=t.hostModel;a=a||{};var i=t.getVisual("symbolSize");e.setShape("size",i instanceof Array?i:[i,i]),e.softClipShape=a.clipShape||null,e.symbolProxy=Ht(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<Xx;e.useStyle(n.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var s=t.getVisual("style"),l=s&&s.fill;l&&e.setColor(l);var u=q(e);u.seriesIndex=n.seriesIndex,e.on("mousemove",function(c){u.dataIndex=null;var v=e.hoverDataIdx;v>=0&&(u.dataIndex=v+(e.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}();const VI=OI;var BI=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,a,n){var i=t.getData(),o=this._updateSymbolDraw(i,t);o.incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,a,n){this._symbolDraw.incrementalUpdate(t,a.getData(),{clipShape:this._getClipShape(a)}),this._finished=t.end===a.getData().count()},e.prototype.updateTransform=function(t,a,n){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var o=eo("").reset(t,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){var a=t.coordinateSystem,n=a&&a.getArea&&a.getArea();return t.get("clip",!0)?n:null},e.prototype._updateSymbolDraw=function(t,a){var n=this._symbolDraw,i=a.pipelineContext,o=i.large;return(!n||o!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=o?new VI:new to,this._isLargeDraw=o,this.group.removeAll()),this.group.add(n.group),n},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e}(Mt);const zI=BI;var GI=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(lt);const FI=GI;var Nc=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Ft).models[0]},e.type="cartesian2dAxis",e}(lt);jt(Nc,Ji);var Kx={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},HI=ot({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Kx),sf=ot({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},Kx),WI=ot({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},sf),$I=J({logBase:10},sf);const qx={category:HI,value:sf,time:WI,log:$I};var UI={value:1,category:1,time:1,log:1};function cn(r,e,t,a){w(UI,function(n,i){var o=ot(ot({},qx[i],!0),a,!0),s=function(l){R(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=e+"Axis."+i,c}return u.prototype.mergeDefaultAndTheme=function(c,v){var f=Ti(this),h=f?Tn(c):{},p=v.getTheme();ot(c,p.get(i+"Axis")),ot(c,this.getDefaultOption()),c.type=cd(c),f&&Vr(c,h,f)},u.prototype.optionUpdated=function(){var c=this.option;c.type==="category"&&(this.__ordinalMeta=Pc.createByAxisModel(this))},u.prototype.getCategories=function(c){var v=this.option;if(v.type==="category")return c?v.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.type=e+"Axis."+i,u.defaultOption=o,u}(t);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(e+"Axis",cd)}function cd(r){return r.type||(r.data?"category":"value")}var YI=function(){function r(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return r.prototype.getAxis=function(e){return this._axes[e]},r.prototype.getAxes=function(){return G(this._dimList,function(e){return this._axes[e]},this)},r.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),bt(this.getAxes(),function(t){return t.scale.type===e})},r.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},r}();const ZI=YI;var Oc=["x","y"];function vd(r){return r.type==="interval"||r.type==="time"}var XI=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=Oc,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,a=this.getAxis("y").scale;if(!(!vd(t)||!vd(a))){var n=t.getExtent(),i=a.getExtent(),o=this.dataToPoint([n[0],i[0]]),s=this.dataToPoint([n[1],i[1]]),l=n[1]-n[0],u=i[1]-i[0];if(!(!l||!u)){var c=(s[0]-o[0])/l,v=(s[1]-o[1])/u,f=o[0]-n[0]*c,h=o[1]-i[0]*v,p=this._transform=[c,0,0,v,f,h];this._invTransform=zi([],p)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var a=this.getAxis("x"),n=this.getAxis("y");return a.contain(a.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,a){var n=this.dataToPoint(t),i=this.dataToPoint(a),o=this.getArea(),s=new wt(n[0],n[1],i[0]-n[0],i[1]-n[1]);return o.intersect(s)},e.prototype.dataToPoint=function(t,a,n){n=n||[];var i=t[0],o=t[1];if(this._transform&&i!=null&&isFinite(i)&&o!=null&&isFinite(o))return Le(n,t,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return n[0]=s.toGlobalCoord(s.dataToCoord(i,a)),n[1]=l.toGlobalCoord(l.dataToCoord(o,a)),n},e.prototype.clampData=function(t,a){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,o=n.getExtent(),s=i.getExtent(),l=n.parse(t[0]),u=i.parse(t[1]);return a=a||[],a[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),a[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),a},e.prototype.pointToData=function(t,a){var n=[];if(this._invTransform)return Le(n,t,this._invTransform);var i=this.getAxis("x"),o=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(t[0]),a),n[1]=o.coordToData(o.toLocalCoord(t[1]),a),n},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(){var t=this.getAxis("x").getGlobalExtent(),a=this.getAxis("y").getGlobalExtent(),n=Math.min(t[0],t[1]),i=Math.min(a[0],a[1]),o=Math.max(t[0],t[1])-n,s=Math.max(a[0],a[1])-i;return new wt(n,i,o,s)},e}(ZI),KI=function(r){R(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.index=0,s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var a=this.getExtent();return a[0]=this.toGlobalCoord(a[0]),a[1]=this.toGlobalCoord(a[1]),t&&a[0]>a[1]&&a.reverse(),a},e.prototype.pointToData=function(t,a){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),a)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(Ue);const qI=KI;function Vc(r,e,t){t=t||{};var a=r.coordinateSystem,n=e.axis,i={},o=n.getAxesOnZeroOf()[0],s=n.position,l=o?"onZero":s,u=n.dim,c=a.getRect(),v=[c.x,c.x+c.width,c.y,c.y+c.height],f={left:0,right:1,top:0,bottom:1,onZero:2},h=e.get("offset")||0,p=u==="x"?[v[2]-h,v[3]+h]:[v[0]-h,v[1]+h];if(o){var d=o.toGlobalCoord(o.dataToCoord(0));p[f.onZero]=Math.max(Math.min(d,p[1]),p[0])}i.position=[u==="y"?p[f[l]]:v[0],u==="x"?p[f[l]]:v[3]],i.rotation=Math.PI/2*(u==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};i.labelDirection=i.tickDirection=i.nameDirection=g[s],i.labelOffset=o?p[f[s]]-p[f.onZero]:0,e.get(["axisTick","inside"])&&(i.tickDirection=-i.tickDirection),Jt(t.labelInside,e.get(["axisLabel","inside"]))&&(i.labelDirection=-i.labelDirection);var y=e.get(["axisLabel","rotate"]);return i.labelRotate=l==="top"?-y:y,i.z2=1,i}function fd(r){return r.get("coordinateSystem")==="cartesian2d"}function hd(r){var e={xAxisModel:null,yAxisModel:null};return w(e,function(t,a){var n=a.replace(/Model$/,""),i=r.getReferringComponents(n,Ft).models[0];e[a]=i}),e}var au=Math.log;function jx(r,e,t){var a=zr.prototype,n=a.getTicks.call(t),i=a.getTicks.call(t,!0),o=n.length-1,s=a.getInterval.call(t),l=gx(r,e),u=l.extent,c=l.fixMin,v=l.fixMax;if(r.type==="log"){var f=au(r.base);u=[au(u[0])/f,au(u[1])/f]}r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:c,fixMax:v});var h=a.getExtent.call(r);c&&(u[0]=h[0]),v&&(u[1]=h[1]);var p=a.getInterval.call(r),d=u[0],g=u[1];if(c&&v)p=(g-d)/o;else if(c)for(g=u[0]+p*o;g<u[1]&&isFinite(g)&&isFinite(u[1]);)p=Zl(p),g=u[0]+p*o;else if(v)for(d=u[1]-p*o;d>u[0]&&isFinite(d)&&isFinite(u[0]);)p=Zl(p),d=u[1]-p*o;else{var y=r.getTicks().length-1;y>o&&(p=Zl(p));var m=p*o;g=Math.ceil(u[1]/p)*p,d=Vt(g-m),d<0&&u[0]>=0?(d=0,g=Vt(m)):g>0&&u[1]<=0&&(g=0,d=-Vt(m))}var S=(n[0].value-i[0].value)/s,x=(n[o].value-i[o].value)/s;a.setExtent.call(r,d+p*S,g+p*x),a.setInterval.call(r,p),(S||x)&&a.setNiceExtent.call(r,d+p,g-p)}var jI=function(){function r(e,t,a){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Oc,this._initCartesian(e,t,a),this.model=e}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(e,t){var a=this._axesMap;this._updateScale(e,this.model);function n(o){var s,l=Wt(o),u=l.length;if(u){for(var c=[],v=u-1;v>=0;v--){var f=+l[v],h=o[f],p=h.model,d=h.scale;Ec(d)&&p.get("alignTicks")&&p.get("interval")==null?c.push(h):(ln(d,p),Ec(d)&&(s=h))}c.length&&(s||(s=c.pop(),ln(s.scale,s.model)),w(c,function(g){jx(g.scale,g.model,s.scale)}))}}n(a.x),n(a.y);var i={};w(a.x,function(o){pd(a,"y",o,i)}),w(a.y,function(o){pd(a,"x",o,i)}),this.resize(this.model,t)},r.prototype.resize=function(e,t,a){var n=e.getBoxLayoutParams(),i=!a&&e.get("containLabel"),o=Yt(n,{width:t.getWidth(),height:t.getHeight()});this._rect=o;var s=this._axesList;l(),i&&(w(s,function(u){if(!u.model.get(["axisLabel","inside"])){var c=jD(u);if(c){var v=u.isHorizontal()?"height":"width",f=u.model.get(["axisLabel","margin"]);o[v]-=c[v]+f,u.position==="top"?o.y+=c.height+f:u.position==="left"&&(o.x+=c.width+f)}}}),l()),w(this._coordsList,function(u){u.calcAffineTransform()});function l(){w(s,function(u){var c=u.isHorizontal(),v=c?[0,o.width]:[0,o.height],f=u.inverse?1:0;u.setExtent(v[f],v[1-f]),JI(u,c?o.x:o.y)})}},r.prototype.getAxis=function(e,t){var a=this._axesMap[e];if(a!=null)return a[t||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var a="x"+e+"y"+t;return this._coordsMap[a]}j(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var n=0,i=this._coordsList;n<i.length;n++)if(i[n].getAxis("x").index===e||i[n].getAxis("y").index===t)return i[n]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(e,t,a){var n=this._findConvertTarget(t);return n.cartesian?n.cartesian.dataToPoint(a):n.axis?n.axis.toGlobalCoord(n.axis.dataToCoord(a)):null},r.prototype.convertFromPixel=function(e,t,a){var n=this._findConvertTarget(t);return n.cartesian?n.cartesian.pointToData(a):n.axis?n.axis.coordToData(n.axis.toLocalCoord(a)):null},r.prototype._findConvertTarget=function(e){var t=e.seriesModel,a=e.xAxisModel||t&&t.getReferringComponents("xAxis",Ft).models[0],n=e.yAxisModel||t&&t.getReferringComponents("yAxis",Ft).models[0],i=e.gridModel,o=this._coordsList,s,l;if(t)s=t.coordinateSystem,ct(o,s)<0&&(s=null);else if(a&&n)s=this.getCartesian(a.componentIndex,n.componentIndex);else if(a)l=this.getAxis("x",a.componentIndex);else if(n)l=this.getAxis("y",n.componentIndex);else if(i){var u=i.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},r.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},r.prototype._initCartesian=function(e,t,a){var n=this,i=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(t.eachComponent("xAxis",u("x"),this),t.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,w(s.x,function(c,v){w(s.y,function(f,h){var p="x"+v+"y"+h,d=new XI(p);d.master=n,d.model=e,n._coordsMap[p]=d,n._coordsList.push(d),d.addAxis(c),d.addAxis(f)})});function u(c){return function(v,f){if(nu(v,e)){var h=v.get("position");c==="x"?h!=="top"&&h!=="bottom"&&(h=o.bottom?"top":"bottom"):h!=="left"&&h!=="right"&&(h=o.left?"right":"left"),o[h]=!0;var p=new qI(c,vl(v),[0,0],v.get("type"),h),d=p.type==="category";p.onBand=d&&v.get("boundaryGap"),p.inverse=v.get("inverse"),v.axis=p,p.model=v,p.grid=i,p.index=f,i._axesList.push(p),s[c][f]=p,l[c]++}}}},r.prototype._updateScale=function(e,t){w(this._axesList,function(n){if(n.scale.setExtent(1/0,-1/0),n.type==="category"){var i=n.model.get("categorySortInfo");n.scale.setSortInfo(i)}}),e.eachSeries(function(n){if(fd(n)){var i=hd(n),o=i.xAxisModel,s=i.yAxisModel;if(!nu(o,t)||!nu(s,t))return;var l=this.getCartesian(o.componentIndex,s.componentIndex),u=n.getData(),c=l.getAxis("x"),v=l.getAxis("y");a(u,c),a(u,v)}},this);function a(n,i){w(Ts(n,i.dim),function(o){i.scale.unionExtentFromData(n,o)})}},r.prototype.getTooltipAxes=function(e){var t=[],a=[];return w(this.getCartesians(),function(n){var i=e!=null&&e!=="auto"?n.getAxis(e):n.getBaseAxis(),o=n.getOtherAxis(i);ct(t,i)<0&&t.push(i),ct(a,o)<0&&a.push(o)}),{baseAxes:t,otherAxes:a}},r.create=function(e,t){var a=[];return e.eachComponent("grid",function(n,i){var o=new r(n,e,t);o.name="grid_"+i,o.resize(n,t,!0),n.coordinateSystem=o,a.push(o)}),e.eachSeries(function(n){if(fd(n)){var i=hd(n),o=i.xAxisModel,s=i.yAxisModel,l=o.getCoordSysModel(),u=l.coordinateSystem;n.coordinateSystem=u.getCartesian(o.componentIndex,s.componentIndex)}}),a},r.dimensions=Oc,r}();function nu(r,e){return r.getCoordSysModel()===e}function pd(r,e,t,a){t.getAxesOnZeroOf=function(){return i?[i]:[]};var n=r[e],i,o=t.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)dd(n[l])&&(i=n[l]);else for(var u in n)if(n.hasOwnProperty(u)&&dd(n[u])&&!a[c(n[u])]){i=n[u];break}i&&(a[c(i)]=!0);function c(v){return v.dim+"_"+v.index}}function dd(r){return r&&r.type!=="category"&&r.type!=="time"&&qD(r)}function JI(r,e){var t=r.getExtent(),a=t[0]+t[1];r.toGlobalCoord=r.dim==="x"?function(n){return n+e}:function(n){return a-n+e},r.toLocalCoord=r.dim==="x"?function(n){return n-e}:function(n){return a-n+e}}const QI=jI;var Mr=Math.PI,ya=function(){function r(e,t){this.group=new tt,this.opt=t,this.axisModel=e,J(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var a=new tt({x:t.position[0],y:t.position[1],rotation:t.rotation});a.updateTransform(),this._transformGroup=a}return r.prototype.hasBuilder=function(e){return!!gd[e]},r.prototype.add=function(e){gd[e](this.opt,this.axisModel,this.group,this._transformGroup)},r.prototype.getGroup=function(){return this.group},r.innerTextLayout=function(e,t,a){var n=$m(t-e),i,o;return fs(n)?(o=a>0?"top":"bottom",i="center"):fs(n-Mr)?(o=a>0?"bottom":"top",i="center"):(o="middle",n>0&&n<Mr?i=a>0?"right":"left":i=a>0?"left":"right"),{rotation:n,textAlign:i,textVerticalAlign:o}},r.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},r.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},r}(),gd={axisLine:function(r,e,t,a){var n=e.get(["axisLine","show"]);if(n==="auto"&&r.handleAutoShown&&(n=r.handleAutoShown("axisLine")),!!n){var i=e.axis.getExtent(),o=a.transform,s=[i[0],0],l=[i[1],0],u=s[0]>l[0];o&&(Le(s,s,o),Le(l,l,o));var c=B({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),v=new te({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:c,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});nn(v.shape,v.style.lineWidth),v.anid="line",t.add(v);var f=e.get(["axisLine","symbol"]);if(f!=null){var h=e.get(["axisLine","symbolSize"]);$(f)&&(f=[f,f]),($(h)||gt(h))&&(h=[h,h]);var p=Ia(e.get(["axisLine","symbolOffset"])||0,h),d=h[0],g=h[1];w([{rotate:r.rotation+Math.PI/2,offset:p[0],r:0},{rotate:r.rotation-Math.PI/2,offset:p[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(y,m){if(f[m]!=="none"&&f[m]!=null){var S=Ht(f[m],-d/2,-g/2,d,g,c.stroke,!0),x=y.r+y.offset,b=u?l:s;S.attr({rotation:y.rotate,x:b[0]+x*Math.cos(r.rotation),y:b[1]-x*Math.sin(r.rotation),silent:!0,z2:11}),t.add(S)}})}}},axisTickLabel:function(r,e,t,a){var n=rL(t,a,e,r),i=nL(t,a,e,r);if(eL(e,i,n),aL(t,a,e,r.tickDirection),e.get(["axisLabel","hideOverlap"])){var o=Ix(G(i,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));Ex(o)}},axisName:function(r,e,t,a){var n=Jt(r.axisName,e.get("name"));if(n){var i=e.get("nameLocation"),o=r.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,u=e.axis.getExtent(),c=u[0]>u[1]?-1:1,v=[i==="start"?u[0]-c*l:i==="end"?u[1]+c*l:(u[0]+u[1])/2,md(i)?r.labelOffset+o*l:0],f,h=e.get("nameRotate");h!=null&&(h=h*Mr/180);var p;md(i)?f=ya.innerTextLayout(r.rotation,h??r.rotation,o):(f=tL(r.rotation,i,h||0,u),p=r.axisNameAvailableWidth,p!=null&&(p=Math.abs(p/Math.sin(f.rotation)),!isFinite(p)&&(p=null)));var d=s.getFont(),g=e.get("nameTruncate",!0)||{},y=g.ellipsis,m=Jt(r.nameTruncateMaxWidth,g.maxWidth,p),S=new ut({x:v[0],y:v[1],rotation:f.rotation,silent:ya.isLabelSilent(e),style:Ct(s,{text:n,font:d,overflow:"truncate",width:m,ellipsis:y,fill:s.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:s.get("align")||f.textAlign,verticalAlign:s.get("verticalAlign")||f.textVerticalAlign}),z2:1});if(_n({el:S,componentModel:e,itemName:n}),S.__fullText=n,S.anid="name",e.get("triggerEvent")){var x=ya.makeAxisEventDataBase(e);x.targetType="axisName",x.name=n,q(S).eventData=x}a.add(S),S.updateTransform(),t.add(S),S.decomposeTransform()}}};function tL(r,e,t,a){var n=$m(t-r),i,o,s=a[0]>a[1],l=e==="start"&&!s||e!=="start"&&s;return fs(n-Mr/2)?(o=l?"bottom":"top",i="center"):fs(n-Mr*1.5)?(o=l?"top":"bottom",i="center"):(o="middle",n<Mr*1.5&&n>Mr/2?i=l?"left":"right":i=l?"right":"left"),{rotation:n,textAlign:i,textVerticalAlign:o}}function eL(r,e,t){if(!yx(r.axis)){var a=r.get(["axisLabel","showMinLabel"]),n=r.get(["axisLabel","showMaxLabel"]);e=e||[],t=t||[];var i=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],u=t[0],c=t[1],v=t[t.length-1],f=t[t.length-2];a===!1?(_e(i),_e(u)):yd(i,o)&&(a?(_e(o),_e(c)):(_e(i),_e(u))),n===!1?(_e(s),_e(v)):yd(l,s)&&(n?(_e(l),_e(f)):(_e(s),_e(v)))}}function _e(r){r&&(r.ignore=!0)}function yd(r,e){var t=r&&r.getBoundingRect().clone(),a=e&&e.getBoundingRect().clone();if(!(!t||!a)){var n=dv([]);return Fi(n,n,-r.rotation),t.applyTransform(is([],n,r.getLocalTransform())),a.applyTransform(is([],n,e.getLocalTransform())),t.intersect(a)}}function md(r){return r==="middle"||r==="center"}function Jx(r,e,t,a,n){for(var i=[],o=[],s=[],l=0;l<r.length;l++){var u=r[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=t,e&&(Le(o,o,e),Le(s,s,e));var c=new te({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:a,z2:2,autoBatch:!0,silent:!0});nn(c.shape,c.style.lineWidth),c.anid=n+"_"+r[l].tickValue,i.push(c)}return i}function rL(r,e,t,a){var n=t.axis,i=t.getModel("axisTick"),o=i.get("show");if(o==="auto"&&a.handleAutoShown&&(o=a.handleAutoShown("axisTick")),!(!o||n.scale.isBlank())){for(var s=i.getModel("lineStyle"),l=a.tickDirection*i.get("length"),u=n.getTicksCoords(),c=Jx(u,e.transform,l,J(s.getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])}),"ticks"),v=0;v<c.length;v++)r.add(c[v]);return c}}function aL(r,e,t,a){var n=t.axis,i=t.getModel("minorTick");if(!(!i.get("show")||n.scale.isBlank())){var o=n.getMinorTicksCoords();if(o.length)for(var s=i.getModel("lineStyle"),l=a*i.get("length"),u=J(s.getLineStyle(),J(t.getModel("axisTick").getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])})),c=0;c<o.length;c++)for(var v=Jx(o[c],e.transform,l,u,"minorticks_"+c),f=0;f<v.length;f++)r.add(v[f])}}function nL(r,e,t,a){var n=t.axis,i=Jt(a.axisLabelShow,t.get(["axisLabel","show"]));if(!(!i||n.scale.isBlank())){var o=t.getModel("axisLabel"),s=o.get("margin"),l=n.getViewLabels(),u=(Jt(a.labelRotate,o.get("rotate"))||0)*Mr/180,c=ya.innerTextLayout(a.rotation,u,a.labelDirection),v=t.getCategories&&t.getCategories(!0),f=[],h=ya.isLabelSilent(t),p=t.get("triggerEvent");return w(l,function(d,g){var y=n.scale.type==="ordinal"?n.scale.getRawOrdinalNumber(d.tickValue):d.tickValue,m=d.formattedLabel,S=d.rawLabel,x=o;if(v&&v[y]){var b=v[y];j(b)&&b.textStyle&&(x=new Dt(b.textStyle,o,t.ecModel))}var _=x.getTextColor()||t.get(["axisLine","lineStyle","color"]),A=n.dataToCoord(y),T=new ut({x:A,y:a.labelOffset+a.labelDirection*s,rotation:c.rotation,silent:h,z2:10+(d.level||0),style:Ct(x,{text:m,align:x.getShallow("align",!0)||c.textAlign,verticalAlign:x.getShallow("verticalAlign",!0)||x.getShallow("baseline",!0)||c.textVerticalAlign,fill:X(_)?_(n.type==="category"?S:n.type==="value"?y+"":y,g):_})});if(T.anid="label_"+y,p){var C=ya.makeAxisEventDataBase(t);C.targetType="axisLabel",C.value=S,C.tickIndex=g,n.type==="category"&&(C.dataIndex=y),q(T).eventData=C}e.add(T),T.updateTransform(),f.push(T),r.add(T),T.decomposeTransform()}),f}}const pr=ya;function iL(r,e){var t={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return oL(t,r,e),t.seriesInvolved&&lL(t,r),t}function oL(r,e,t){var a=e.getComponent("tooltip"),n=e.getComponent("axisPointer"),i=n.get("link",!0)||[],o=[];w(t.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=Li(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var c=s.model,v=c.getModel("tooltip",a);if(w(s.getAxes(),Q(d,!1,null)),s.getTooltipAxes&&a&&v.get("show")){var f=v.get("trigger")==="axis",h=v.get(["axisPointer","type"])==="cross",p=s.getTooltipAxes(v.get(["axisPointer","axis"]));(f||h)&&w(p.baseAxes,Q(d,h?"cross":!0,f)),h&&w(p.otherAxes,Q(d,"cross",!1))}function d(g,y,m){var S=m.model.getModel("axisPointer",n),x=S.get("show");if(!(!x||x==="auto"&&!g&&!Bc(S))){y==null&&(y=S.get("triggerTooltip")),S=g?sL(m,v,n,e,g,y):S;var b=S.get("snap"),_=S.get("triggerEmphasis"),A=Li(m.model),T=y||b||m.type==="category",C=r.axesInfo[A]={key:A,axis:m,coordSys:s,axisPointerModel:S,triggerTooltip:y,triggerEmphasis:_,involveSeries:T,snap:b,useHandle:Bc(S),seriesModels:[],linkGroup:null};u[A]=C,r.seriesInvolved=r.seriesInvolved||T;var M=uL(i,m);if(M!=null){var D=o[M]||(o[M]={axesInfo:{}});D.axesInfo[A]=C,D.mapper=i[M].mapper,C.linkGroup=D}}}})}function sL(r,e,t,a,n,i){var o=e.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};w(s,function(f){l[f]=K(o.get(f))}),l.snap=r.type!=="category"&&!!i,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),n==="cross"){var c=o.get(["label","show"]);if(u.show=c??!0,!i){var v=l.lineStyle=o.get("crossStyle");v&&J(u,v.textStyle)}}return r.model.getModel("axisPointer",new Dt(l,t,a))}function lL(r,e){e.eachSeries(function(t){var a=t.coordinateSystem,n=t.get(["tooltip","trigger"],!0),i=t.get(["tooltip","show"],!0);!a||n==="none"||n===!1||n==="item"||i===!1||t.get(["axisPointer","show"],!0)===!1||w(r.coordSysAxesInfo[Li(a.model)],function(o){var s=o.axis;a.getAxis(s.dim)===s&&(o.seriesModels.push(t),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=t.getData().count())})})}function uL(r,e){for(var t=e.model,a=e.dim,n=0;n<r.length;n++){var i=r[n]||{};if(iu(i[a+"AxisId"],t.id)||iu(i[a+"AxisIndex"],t.componentIndex)||iu(i[a+"AxisName"],t.name))return n}}function iu(r,e){return r==="all"||O(r)&&ct(r,e)>=0||r===e}function cL(r){var e=lf(r);if(e){var t=e.axisPointerModel,a=e.axis.scale,n=t.option,i=t.get("status"),o=t.get("value");o!=null&&(o=a.parse(o));var s=Bc(t);i==null&&(n.status=s?"show":"hide");var l=a.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),n.value=o,s&&(n.status=e.axis.scale.isBlank()?"hide":"show")}}function lf(r){var e=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[Li(r)]}function vL(r){var e=lf(r);return e&&e.axisPointerModel}function Bc(r){return!!r.get(["handle","show"])}function Li(r){return r.type+"||"+r.id}var Sd={},fL=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this.axisPointerClass&&cL(t),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,n,!0)},e.prototype.updateAxisPointer=function(t,a,n,i){this._doUpdateAxisPointerClass(t,n,!1)},e.prototype.remove=function(t,a){var n=this._axisPointer;n&&n.remove(a)},e.prototype.dispose=function(t,a){this._disposeAxisPointer(a),r.prototype.dispose.apply(this,arguments)},e.prototype._doUpdateAxisPointerClass=function(t,a,n){var i=e.getAxisPointerClass(this.axisPointerClass);if(i){var o=vL(t);o?(this._axisPointer||(this._axisPointer=new i)).render(t,o,a,n):this._disposeAxisPointer(a)}},e.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},e.registerAxisPointerClass=function(t,a){Sd[t]=a},e.getAxisPointerClass=function(t){return t&&Sd[t]},e.type="axis",e}(Ot);const Ea=fL;var zc=st();function Qx(r,e,t,a){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitArea"),o=i.getModel("areaStyle"),s=o.get("color"),l=a.coordinateSystem.getRect(),u=n.getTicksCoords({tickModel:i,clamp:!0});if(u.length){var c=s.length,v=zc(r).splitAreaColors,f=Z(),h=0;if(v)for(var p=0;p<u.length;p++){var d=v.get(u[p].tickValue);if(d!=null){h=(d+(c-1)*p)%c;break}}var g=n.toGlobalCoord(u[0].coord),y=o.getAreaStyle();s=O(s)?s:[s];for(var p=1;p<u.length;p++){var m=n.toGlobalCoord(u[p].coord),S=void 0,x=void 0,b=void 0,_=void 0;n.isHorizontal()?(S=g,x=l.y,b=m-S,_=l.height,g=S+b):(S=l.x,x=g,b=l.width,_=m-x,g=x+_);var A=u[p-1].tickValue;A!=null&&f.set(A,h),e.add(new ht({anid:A!=null?"area_"+A:null,shape:{x:S,y:x,width:b,height:_},style:J({fill:s[h]},y),autoBatch:!0,silent:!0})),h=(h+1)%c}zc(r).splitAreaColors=f}}}function t_(r){zc(r).splitAreaColors=null}var hL=["axisLine","axisTickLabel","axisName"],pL=["splitArea","splitLine","minorSplitLine"],e_=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="CartesianAxisPointer",t}return e.prototype.render=function(t,a,n,i){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new tt,this.group.add(this._axisGroup),!!t.get("show")){var s=t.getCoordSysModel(),l=Vc(s,t),u=new pr(t,B({handleAutoShown:function(v){for(var f=s.coordinateSystem.getCartesians(),h=0;h<f.length;h++)if(Ec(f[h].getOtherAxis(t.axis).scale))return!0;return!1}},l));w(hL,u.add,u),this._axisGroup.add(u.getGroup()),w(pL,function(v){t.get([v,"show"])&&dL[v](this,this._axisGroup,t,s)},this);var c=i&&i.type==="changeAxisOrder"&&i.isInitSort;c||Ui(o,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)}},e.prototype.remove=function(){t_(this)},e.type="cartesianAxis",e}(Ea),dL={splitLine:function(r,e,t,a){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitLine"),o=i.getModel("lineStyle"),s=o.get("color");s=O(s)?s:[s];for(var l=a.coordinateSystem.getRect(),u=n.isHorizontal(),c=0,v=n.getTicksCoords({tickModel:i}),f=[],h=[],p=o.getLineStyle(),d=0;d<v.length;d++){var g=n.toGlobalCoord(v[d].coord);u?(f[0]=g,f[1]=l.y,h[0]=g,h[1]=l.y+l.height):(f[0]=l.x,f[1]=g,h[0]=l.x+l.width,h[1]=g);var y=c++%s.length,m=v[d].tickValue,S=new te({anid:m!=null?"line_"+v[d].tickValue:null,autoBatch:!0,shape:{x1:f[0],y1:f[1],x2:h[0],y2:h[1]},style:J({stroke:s[y]},p),silent:!0});nn(S.shape,p.lineWidth),e.add(S)}}},minorSplitLine:function(r,e,t,a){var n=t.axis,i=t.getModel("minorSplitLine"),o=i.getModel("lineStyle"),s=a.coordinateSystem.getRect(),l=n.isHorizontal(),u=n.getMinorTicksCoords();if(u.length)for(var c=[],v=[],f=o.getLineStyle(),h=0;h<u.length;h++)for(var p=0;p<u[h].length;p++){var d=n.toGlobalCoord(u[h][p].coord);l?(c[0]=d,c[1]=s.y,v[0]=d,v[1]=s.y+s.height):(c[0]=s.x,c[1]=d,v[0]=s.x+s.width,v[1]=d);var g=new te({anid:"minor_line_"+u[h][p].tickValue,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:v[0],y2:v[1]},style:f,silent:!0});nn(g.shape,f.lineWidth),e.add(g)}},splitArea:function(r,e,t,a){Qx(r,e,t,a)}},r_=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="xAxis",e}(e_),gL=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=r_.type,t}return e.type="yAxis",e}(e_),yL=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="grid",t}return e.prototype.render=function(t,a){this.group.removeAll(),t.get("show")&&this.group.add(new ht({shape:t.coordinateSystem.getRect(),style:J({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},e.type="grid",e}(Ot),xd={offset:0};function a_(r){r.registerComponentView(yL),r.registerComponentModel(FI),r.registerCoordinateSystem("cartesian2d",QI),cn(r,"x",Nc,xd),cn(r,"y",Nc,xd),r.registerComponentView(r_),r.registerComponentView(gL),r.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function mL(r){it(a_),r.registerSeriesModel(RI),r.registerChartView(zI),r.registerLayout(eo("scatter"))}function SL(r){r.eachSeriesByType("radar",function(e){var t=e.getData(),a=[],n=e.coordinateSystem;if(n){var i=n.getIndicatorAxes();w(i,function(o,s){t.each(t.mapDimension(i[s].dim),function(l,u){a[u]=a[u]||[];var c=n.dataToPoint(l,s);a[u][s]=_d(c)?c:bd(n)})}),t.each(function(o){var s=Eb(a[o],function(l){return _d(l)})||bd(n);a[o].push(s.slice()),t.setItemLayout(o,a[o])})}})}function _d(r){return!isNaN(r[0])&&!isNaN(r[1])}function bd(r){return[r.cx,r.cy]}function xL(r){var e=r.polar;if(e){O(e)||(e=[e]);var t=[];w(e,function(a,n){a.indicator?(a.type&&!a.shape&&(a.shape=a.type),r.radar=r.radar||[],O(r.radar)||(r.radar=[r.radar]),r.radar.push(a)):t.push(a)}),r.polar=t}w(r.series,function(a){a&&a.type==="radar"&&a.polarIndex&&(a.radarIndex=a.polarIndex)})}var _L=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=this._data;function u(f,h){var p=f.getItemVisual(h,"symbol")||"circle";if(p!=="none"){var d=Ln(f.getItemVisual(h,"symbolSize")),g=Ht(p,-1,-1,2,2),y=f.getItemVisual(h,"symbolRotate")||0;return g.attr({style:{strokeNoScale:!0},z2:100,scaleX:d[0]/2,scaleY:d[1]/2,rotation:y*Math.PI/180||0}),g}}function c(f,h,p,d,g,y){p.removeAll();for(var m=0;m<h.length-1;m++){var S=u(d,g);S&&(S.__dimIdx=m,f[m]?(S.setPosition(f[m]),Zi[y?"initProps":"updateProps"](S,{x:h[m][0],y:h[m][1]},t,g)):S.setPosition(h[m]),p.add(S))}}function v(f){return G(f,function(h){return[i.cx,i.cy]})}s.diff(l).add(function(f){var h=s.getItemLayout(f);if(h){var p=new Ee,d=new me,g={shape:{points:h}};p.shape.points=v(h),d.shape.points=v(h),Lt(p,g,t,f),Lt(d,g,t,f);var y=new tt,m=new tt;y.add(d),y.add(p),y.add(m),c(d.shape.points,h,m,s,f,!0),s.setItemGraphicEl(f,y)}}).update(function(f,h){var p=l.getItemGraphicEl(h),d=p.childAt(0),g=p.childAt(1),y=p.childAt(2),m={shape:{points:s.getItemLayout(f)}};m.shape.points&&(c(d.shape.points,m.shape.points,y,s,f,!1),We(g),We(d),ft(d,m,t),ft(g,m,t),s.setItemGraphicEl(f,p))}).remove(function(f){o.remove(l.getItemGraphicEl(f))}).execute(),s.eachItemGraphicEl(function(f,h){var p=s.getItemModel(h),d=f.childAt(0),g=f.childAt(1),y=f.childAt(2),m=s.getItemVisual(h,"style"),S=m.fill;o.add(f),d.useStyle(J(p.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:S})),re(d,p,"lineStyle"),re(g,p,"areaStyle");var x=p.getModel("areaStyle"),b=x.isEmpty()&&x.parentModel.isEmpty();g.ignore=b,w(["emphasis","select","blur"],function(T){var C=p.getModel([T,"areaStyle"]),M=C.isEmpty()&&C.parentModel.isEmpty();g.ensureState(T).ignore=M&&b}),g.useStyle(J(x.getAreaStyle(),{fill:S,opacity:.7,decal:m.decal}));var _=p.getModel("emphasis"),A=_.getModel("itemStyle").getItemStyle();y.eachChild(function(T){if(T instanceof ke){var C=T.style;T.useStyle(B({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},m))}else T.useStyle(m),T.setColor(S),T.style.strokeNoScale=!0;var M=T.ensureState("emphasis");M.style=K(A);var D=s.getStore().get(s.getDimensionIndex(T.__dimIdx),h);(D==null||isNaN(D))&&(D=""),ae(T,Kt(p),{labelFetcher:s.hostModel,labelDataIndex:h,labelDimIndex:T.__dimIdx,defaultText:D,inheritColor:S,defaultOpacity:m.opacity})}),Nt(f,_.get("focus"),_.get("blurScope"),_.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type="radar",e}(Mt);const bL=_L;var wL=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new ao(W(this.getData,this),W(this.getRawData,this))},e.prototype.getInitialData=function(t,a){return Pn(this,{generateCoord:"indicator_",generateCoordCount:1/0})},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.coordinateSystem,s=o.getIndicatorAxes(),l=this.getData().getName(t),u=l===""?this.name:l,c=gS(this,t);return qt("section",{header:u,sortBlocks:!0,blocks:G(s,function(v){var f=i.get(i.mapDimension(v.dim),t);return qt("nameValue",{markerType:"subItem",markerColor:c,name:v.name,value:f,sortParam:f})})})},e.prototype.getTooltipPosition=function(t){if(t!=null){for(var a=this.getData(),n=this.coordinateSystem,i=a.getValues(G(n.dimensions,function(u){return a.mapDimension(u)}),t),o=0,s=i.length;o<s;o++)if(!isNaN(i[o])){var l=n.getIndicatorAxes();return n.coordToPoint(l[o].dataToCoord(i[o]),o)}}},e.type="series.radar",e.dependencies=["radar"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},e}(Et);const AL=wL;var $n=qx.value;function Io(r,e){return J({show:e},r)}var TL=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),a=this.get("splitNumber"),n=this.get("scale"),i=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),l=this.get("axisName"),u=this.get(["axisName","show"]),c=this.get(["axisName","formatter"]),v=this.get("axisNameGap"),f=this.get("triggerEvent"),h=G(this.get("indicator")||[],function(p){p.max!=null&&p.max>0&&!p.min?p.min=0:p.min!=null&&p.min<0&&!p.max&&(p.max=0);var d=l;p.color!=null&&(d=J({color:p.color},l));var g=ot(K(p),{boundaryGap:t,splitNumber:a,scale:n,axisLine:i,axisTick:o,axisLabel:s,name:p.text,showName:u,nameLocation:"end",nameGap:v,nameTextStyle:d,triggerEvent:f},!1);if($(c)){var y=g.name;g.name=c.replace("{value}",y??"")}else X(c)&&(g.name=c(g.name,g));var m=new Dt(g,null,this.ecModel);return jt(m,Ji.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=h},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:ot({lineStyle:{color:"#bbb"}},$n.axisLine),axisLabel:Io($n.axisLabel,!1),axisTick:Io($n.axisTick,!1),splitLine:Io($n.splitLine,!0),splitArea:Io($n.splitArea,!0),indicator:[]},e}(lt);const CL=TL;var DL=["axisLine","axisTickLabel","axisName"],ML=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=this.group;i.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var a=t.coordinateSystem,n=a.getIndicatorAxes(),i=G(n,function(o){var s=o.model.get("showName")?o.name:"",l=new pr(o.model,{axisName:s,position:[a.cx,a.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return l});w(i,function(o){w(DL,o.add,o),this.group.add(o.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var a=t.coordinateSystem,n=a.getIndicatorAxes();if(!n.length)return;var i=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),c=o.get("show"),v=s.get("show"),f=l.get("color"),h=u.get("color"),p=O(f)?f:[f],d=O(h)?h:[h],g=[],y=[];function m(E,k,V){var N=V%k.length;return E[N]=E[N]||[],N}if(i==="circle")for(var S=n[0].getTicksCoords(),x=a.cx,b=a.cy,_=0;_<S.length;_++){if(c){var A=m(g,p,_);g[A].push(new ur({shape:{cx:x,cy:b,r:S[_].coord}}))}if(v&&_<S.length-1){var A=m(y,d,_);y[A].push(new Hs({shape:{cx:x,cy:b,r0:S[_].coord,r:S[_+1].coord}}))}}else for(var T,C=G(n,function(E,k){var V=E.getTicksCoords();return T=T==null?V.length-1:Math.min(V.length-1,T),G(V,function(N){return a.coordToPoint(N.coord,k)})}),M=[],_=0;_<=T;_++){for(var D=[],I=0;I<n.length;I++)D.push(C[I][_]);if(D[0]&&D.push(D[0].slice()),c){var A=m(g,p,_);g[A].push(new me({shape:{points:D}}))}if(v&&M){var A=m(y,d,_-1);y[A].push(new Ee({shape:{points:D.concat(M)}}))}M=D.slice().reverse()}var L=l.getLineStyle(),P=u.getAreaStyle();w(y,function(E,k){this.group.add(Ce(E,{style:J({stroke:"none",fill:d[k%d.length]},P),silent:!0}))},this),w(g,function(E,k){this.group.add(Ce(E,{style:J({fill:"none",stroke:p[k%p.length]},L),silent:!0}))},this)},e.type="radar",e}(Ot);const IL=ML;var LL=function(r){R(e,r);function e(t,a,n){var i=r.call(this,t,a,n)||this;return i.type="value",i.angle=0,i.name="",i}return e}(Ue);const PL=LL;var EL=function(){function r(e,t,a){this.dimensions=[],this._model=e,this._indicatorAxes=G(e.getIndicatorModels(),function(n,i){var o="indicator_"+i,s=new PL(o,new zr);return s.name=n.get("name"),s.model=n,n.axis=s,this.dimensions.push(o),s},this),this.resize(e,a)}return r.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r.prototype.dataToPoint=function(e,t){var a=this._indicatorAxes[t];return this.coordToPoint(a.dataToCoord(e),t)},r.prototype.coordToPoint=function(e,t){var a=this._indicatorAxes[t],n=a.angle,i=this.cx+e*Math.cos(n),o=this.cy-e*Math.sin(n);return[i,o]},r.prototype.pointToData=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,n=Math.sqrt(t*t+a*a);t/=n,a/=n;for(var i=Math.atan2(-a,t),o=1/0,s,l=-1,u=0;u<this._indicatorAxes.length;u++){var c=this._indicatorAxes[u],v=Math.abs(i-c.angle);v<o&&(s=c,l=u,o=v)}return[l,+(s&&s.coordToData(n))]},r.prototype.resize=function(e,t){var a=e.get("center"),n=t.getWidth(),i=t.getHeight(),o=Math.min(n,i)/2;this.cx=F(a[0],n),this.cy=F(a[1],i),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");($(s)||gt(s))&&(s=[0,s]),this.r0=F(s[0],o),this.r=F(s[1],o),w(this._indicatorAxes,function(l,u){l.setExtent(this.r0,this.r);var c=this.startAngle+u*Math.PI*2/this._indicatorAxes.length;c=Math.atan2(Math.sin(c),Math.cos(c)),l.angle=c},this)},r.prototype.update=function(e,t){var a=this._indicatorAxes,n=this._model;w(a,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,l){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==n)){var u=s.getData();w(a,function(c){c.scale.unionExtentFromData(u,u.mapDimension(c.dim))})}},this);var i=n.get("splitNumber"),o=new zr;o.setExtent(0,i),o.setInterval(1),w(a,function(s,l){jx(s.scale,s.model,o)})},r.prototype.convertToPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.convertFromPixel=function(e,t,a){return console.warn("Not implemented."),null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.create=function(e,t){var a=[];return e.eachComponent("radar",function(n){var i=new r(n,e,t);a.push(i),n.coordinateSystem=i}),e.eachSeriesByType("radar",function(n){n.get("coordinateSystem")==="radar"&&(n.coordinateSystem=a[n.get("radarIndex")||0])}),a},r.dimensions=[],r}();const RL=EL;function kL(r){r.registerCoordinateSystem("radar",RL),r.registerComponentModel(CL),r.registerComponentView(IL),r.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(a){t.setItemVisual(a,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}function NL(r){it(kL),r.registerChartView(bL),r.registerSeriesModel(AL),r.registerLayout(SL),r.registerProcessor(ro("radar")),r.registerPreprocessor(xL)}var wd="\0_ec_interaction_mutex";function OL(r,e,t){var a=uf(r);a[e]=t}function VL(r,e,t){var a=uf(r),n=a[e];n===t&&(a[e]=null)}function Ad(r,e){return!!uf(r)[e]}function uf(r){return r[wd]||(r[wd]={})}rr({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},he);var BL=function(r){R(e,r);function e(t){var a=r.call(this)||this;a._zr=t;var n=W(a._mousedownHandler,a),i=W(a._mousemoveHandler,a),o=W(a._mouseupHandler,a),s=W(a._mousewheelHandler,a),l=W(a._pinchHandler,a);return a.enable=function(u,c){this.disable(),this._opt=J(K(c)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),u==null&&(u=!0),(u===!0||u==="move"||u==="pan")&&(t.on("mousedown",n),t.on("mousemove",i),t.on("mouseup",o)),(u===!0||u==="scale"||u==="zoom")&&(t.on("mousewheel",s),t.on("pinch",l))},a.disable=function(){t.off("mousedown",n),t.off("mousemove",i),t.off("mouseup",o),t.off("mousewheel",s),t.off("pinch",l)},a}return e.prototype.isDragging=function(){return this._dragging},e.prototype.isPinching=function(){return this._pinching},e.prototype.setPointerChecker=function(t){this.pointerChecker=t},e.prototype.dispose=function(){this.disable()},e.prototype._mousedownHandler=function(t){if(!sh(t)){for(var a=t.target;a;){if(a.draggable)return;a=a.__hostTarget||a.parent}var n=t.offsetX,i=t.offsetY;this.pointerChecker&&this.pointerChecker(t,n,i)&&(this._x=n,this._y=i,this._dragging=!0)}},e.prototype._mousemoveHandler=function(t){if(!(!this._dragging||!ts("moveOnMouseMove",t,this._opt)||t.gestureEvent==="pinch"||Ad(this._zr,"globalPan"))){var a=t.offsetX,n=t.offsetY,i=this._x,o=this._y,s=a-i,l=n-o;this._x=a,this._y=n,this._opt.preventDefaultMouseMove&&Nr(t.event),n_(this,"pan","moveOnMouseMove",t,{dx:s,dy:l,oldX:i,oldY:o,newX:a,newY:n,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){sh(t)||(this._dragging=!1)},e.prototype._mousewheelHandler=function(t){var a=ts("zoomOnMouseWheel",t,this._opt),n=ts("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),s=t.offsetX,l=t.offsetY;if(!(i===0||!a&&!n)){if(a){var u=o>3?1.4:o>1?1.2:1.1,c=i>0?u:1/u;ou(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:s,originY:l,isAvailableBehavior:null})}if(n){var v=Math.abs(i),f=(i>0?1:-1)*(v>3?.4:v>1?.15:.05);ou(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:f,originX:s,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!Ad(this._zr,"globalPan")){var a=t.pinchScale>1?1.1:1/1.1;ou(this,"zoom",null,t,{scale:a,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e}(dn);function ou(r,e,t,a,n){r.pointerChecker&&r.pointerChecker(a,n.originX,n.originY)&&(Nr(a.event),n_(r,e,t,a,n))}function n_(r,e,t,a,n){n.isAvailableBehavior=W(ts,null,t,a),r.trigger(e,n)}function ts(r,e,t){var a=t[r];return!r||a&&(!$(a)||e.event[a+"Key"])}const no=BL;function cf(r,e,t){var a=r.target;a.x+=e,a.y+=t,a.dirty()}function vf(r,e,t,a){var n=r.target,i=r.zoomLimit,o=r.zoom=r.zoom||1;if(o*=e,i){var s=i.min||0,l=i.max||1/0;o=Math.max(Math.min(l,o),s)}var u=o/r.zoom;r.zoom=o,n.x-=(t-n.x)*(u-1),n.y-=(a-n.y)*(u-1),n.scaleX*=u,n.scaleY*=u,n.dirty()}var zL={axisPointer:1,tooltip:1,brush:1};function hl(r,e,t){var a=e.getComponentByElement(r.topTarget),n=a&&a.coordinateSystem;return a&&a!==t&&!zL.hasOwnProperty(a.mainType)&&n&&n.model!==t}var GL=Z(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),FL=function(){function r(e,t){this.type="geoSVG",this._usedGraphicMap=Z(),this._freedGraphics=[],this._mapName=e,this._parsedXML=Rb(t)}return r.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t=WL(e.named),a=t.regions,n=t.regionsMap;this._regions=a,this._regionsMap=n}return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},r.prototype._buildGraphic=function(e){var t,a;try{t=e&&kb(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},a=t.root,ye(a!=null)}catch(g){throw new Error(`Invalid svg format
`+g.message)}var n=new tt;n.add(a),n.isGeoSVGGraphicRoot=!0;var i=t.width,o=t.height,s=t.viewBoxRect,l=this._boundingRect;if(!l){var u=void 0,c=void 0,v=void 0,f=void 0;if(i!=null?(u=0,v=i):s&&(u=s.x,v=s.width),o!=null?(c=0,f=o):s&&(c=s.y,f=s.height),u==null||c==null){var h=a.getBoundingRect();u==null&&(u=h.x,v=h.width),c==null&&(c=h.y,f=h.height)}l=this._boundingRect=new wt(u,c,v,f)}if(s){var p=Nb(s,l);a.scaleX=a.scaleY=p.scale,a.x=p.x,a.y=p.y}n.setClipPath(new ht({shape:l.plain()}));var d=[];return w(t.named,function(g){GL.get(g.svgNodeTagLower)!=null&&(d.push(g),HL(g.el))}),{root:n,boundingRect:l,named:d}},r.prototype.useGraphic=function(e){var t=this._usedGraphicMap,a=t.get(e);return a||(a=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,a),a)},r.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,a=t.get(e);a&&(t.removeKey(e),this._freedGraphics.push(a))},r}();function HL(r){r.silent=!1,r.isGroup&&r.traverse(function(e){e.silent=!1})}function WL(r){var e=[],t=Z();return w(r,function(a){if(a.namedFrom==null){var n=new rM(a.name,a.el);e.push(n),t.set(a.name,n)}}),{regions:e,regionsMap:t}}var Gc=[126,25],Td="南海诸岛",Jr=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]];for(var jr=0;jr<Jr.length;jr++)for(var Ga=0;Ga<Jr[jr].length;Ga++)Jr[jr][Ga][0]/=10.5,Jr[jr][Ga][1]/=-10.5/.75,Jr[jr][Ga][0]+=Gc[0],Jr[jr][Ga][1]+=Gc[1];function $L(r,e){if(r==="china"){for(var t=0;t<e.length;t++)if(e[t].name===Td)return;e.push(new Sx(Td,G(Jr,function(a){return{type:"polygon",exterior:a}}),Gc))}}var UL={南海诸岛:[32,80],广东:[0,-10],香港:[10,5],澳门:[-10,10],天津:[5,5]};function YL(r,e){if(r==="china"){var t=UL[e.name];if(t){var a=e.getCenter();a[0]+=t[0]/10.5,a[1]+=-t[1]/(10.5/.75),e.setCenter(a)}}}var ZL=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function XL(r,e){r==="china"&&e.name==="台湾"&&e.geometries.push({type:"polygon",exterior:ZL[0]})}var KL="name",qL=function(){function r(e,t,a){this.type="geoJSON",this._parsedMap=Z(),this._mapName=e,this._specialAreas=a,this._geoJSON=JL(t)}return r.prototype.load=function(e,t){t=t||KL;var a=this._parsedMap.get(t);if(!a){var n=this._parseToRegions(t);a=this._parsedMap.set(t,{regions:n,boundingRect:jL(n)})}var i=Z(),o=[];return w(a.regions,function(s){var l=s.name;e&&U(e,l)&&(s=s.cloneShallow(l=e[l])),o.push(s),i.set(l,s)}),{regions:o,boundingRect:a.boundingRect||new wt(0,0,0,0),regionsMap:i}},r.prototype._parseToRegions=function(e){var t=this._mapName,a=this._geoJSON,n;try{n=a?nM(a,e):[]}catch(i){throw new Error(`Invalid geoJson format
`+i.message)}return $L(t,n),w(n,function(i){var o=i.name;YL(t,i),XL(t,i);var s=this._specialAreas&&this._specialAreas[o];s&&i.transformTo(s.left,s.top,s.width,s.height)},this),n},r.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},r}();function jL(r){for(var e,t=0;t<r.length;t++){var a=r[t].getBoundingRect();e=e||a.clone(),e.union(a)}return e}function JL(r){return $(r)?typeof JSON<"u"&&JSON.parse?JSON.parse(r):new Function("return ("+r+");")():r}var Un=Z();const dr={registerMap:function(r,e,t){if(e.svg){var a=new FL(r,e.svg);Un.set(r,a)}else{var n=e.geoJson||e.geoJSON;n&&!e.features?t=e.specialAreas:n=e;var a=new qL(r,n,t);Un.set(r,a)}},getGeoResource:function(r){return Un.get(r)},getMapForUser:function(r){var e=Un.get(r);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(r,e,t){var a=Un.get(r);if(a)return a.load(e,t)}};var ff=["rect","circle","line","ellipse","polygon","polyline","path"],QL=Z(ff),tP=Z(ff.concat(["g"])),eP=Z(ff.concat(["g"])),i_=st();function Lo(r){var e=r.getItemStyle(),t=r.get("areaColor");return t!=null&&(e.fill=t),e}function Cd(r){var e=r.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var rP=function(){function r(e){var t=new tt;this.uid=wn("ec_map_draw"),this._controller=new no(e.getZr()),this._controllerHost={target:t},this.group=t,t.add(this._regionsGroup=new tt),t.add(this._svgGroup=new tt)}return r.prototype.draw=function(e,t,a,n,i){var o=e.mainType==="geo",s=e.getData&&e.getData();o&&t.eachComponent({mainType:"series",subType:"map"},function(y){!s&&y.getHostGeoModel()===e&&(s=y.getData())});var l=e.coordinateSystem,u=this._regionsGroup,c=this.group,v=l.getTransformInfo(),f=v.raw,h=v.roam,p=!u.childAt(0)||i;p?(c.x=h.x,c.y=h.y,c.scaleX=h.scaleX,c.scaleY=h.scaleY,c.dirty()):ft(c,h,e);var d=s&&s.getVisual("visualMeta")&&s.getVisual("visualMeta").length>0,g={api:a,geo:l,mapOrGeoModel:e,data:s,isVisualEncodedByVisualMap:d,isGeo:o,transformInfoRaw:f};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(e,t,a),this._updateMapSelectHandler(e,u,a,n)},r.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=Z(),a=Z(),n=this._regionsGroup,i=e.transformInfoRaw,o=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function c(h,p){return p&&(h=p(h)),h&&[h[0]*i.scaleX+i.x,h[1]*i.scaleY+i.y]}function v(h){for(var p=[],d=!u&&l&&l.project,g=0;g<h.length;++g){var y=c(h[g],d);y&&p.push(y)}return p}function f(h){return{shape:{points:v(h)}}}n.removeAll(),w(e.geo.regions,function(h){var p=h.name,d=t.get(p),g=a.get(p)||{},y=g.dataIdx,m=g.regionModel;d||(d=t.set(p,new tt),n.add(d),y=s?s.indexOfName(p):null,m=e.isGeo?o.getRegionModel(p):s?s.getItemModel(y):null,a.set(p,{dataIdx:y,regionModel:m}));var S=[],x=[];w(h.geometries,function(A){if(A.type==="polygon"){var T=[A.exterior].concat(A.interiors||[]);u&&(T=Ed(T,u)),w(T,function(M){S.push(new Ee(f(M)))})}else{var C=A.points;u&&(C=Ed(C,u,!0)),w(C,function(M){x.push(new me(f(M)))})}});var b=c(h.getCenter(),l&&l.project);function _(A,T){if(A.length){var C=new Rm({culling:!0,segmentIgnoreThreshold:1,shape:{paths:A}});d.add(C),Dd(e,C,y,m),Md(e,C,p,m,o,y,b),T&&(Cd(C),w(C.states,Cd))}}_(S),_(x,!0)}),t.each(function(h,p){var d=a.get(p),g=d.dataIdx,y=d.regionModel;Id(e,h,p,y,o,g),Ld(e,h,p,y,o),Pd(e,h,p,y,o)},this)},r.prototype._buildSVG=function(e){var t=e.geo.map,a=e.transformInfoRaw;this._svgGroup.x=a.x,this._svgGroup.y=a.y,this._svgGroup.scaleX=a.scaleX,this._svgGroup.scaleY=a.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var n=this._svgDispatcherMap=Z(),i=!1;w(this._svgGraphicRecord.named,function(o){var s=o.name,l=e.mapOrGeoModel,u=e.data,c=o.svgNodeTagLower,v=o.el,f=u?u.indexOfName(s):null,h=l.getRegionModel(s);if(QL.get(c)!=null&&v instanceof Sa&&Dd(e,v,f,h),v instanceof Sa&&(v.culling=!0),v.z2EmphasisLift=0,!o.namedFrom&&(eP.get(c)!=null&&Md(e,v,s,h,l,f,null),Id(e,v,s,h,l,f),Ld(e,v,s,h,l),tP.get(c)!=null)){var p=Pd(e,v,s,h,l);p==="self"&&(i=!0);var d=n.get(s)||n.set(s,[]);d.push(v)}},this),this._enableBlurEntireSVG(i,e)},r.prototype._enableBlurEntireSVG=function(e,t){if(e&&t.isGeo){var a=t.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle(),n=a.opacity;this._svgGraphicRecord.root.traverse(function(i){if(!i.isGroup){Aa(i);var o=i.ensureState("blur").style||{};o.opacity==null&&n!=null&&(o.opacity=n),i.ensureState("emphasis")}})}},r.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},r.prototype.findHighDownDispatchers=function(e,t){if(e==null)return[];var a=t.coordinateSystem;if(a.resourceType==="geoJSON"){var n=this._regionsGroupByName;if(n){var i=n.get(e);return i?[i]:[]}}else if(a.resourceType==="geoSVG")return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},r.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},r.prototype._useSVG=function(e){var t=dr.getGeoResource(e);if(t&&t.type==="geoSVG"){var a=t.useGraphic(this.uid);this._svgGroup.add(a.root),this._svgGraphicRecord=a,this._svgMapName=e}},r.prototype._freeSVG=function(){var e=this._svgMapName;if(e!=null){var t=dr.getGeoResource(e);t&&t.type==="geoSVG"&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},r.prototype._updateController=function(e,t,a){var n=e.coordinateSystem,i=this._controller,o=this._controllerHost;o.zoomLimit=e.get("scaleLimit"),o.zoom=n.getZoom(),i.enable(e.get("roam")||!1);var s=e.mainType;function l(){var u={type:"geoRoam",componentType:s};return u[s+"Id"]=e.id,u}i.off("pan").on("pan",function(u){this._mouseDownFlag=!1,cf(o,u.dx,u.dy),a.dispatchAction(B(l(),{dx:u.dx,dy:u.dy,animation:{duration:0}}))},this),i.off("zoom").on("zoom",function(u){this._mouseDownFlag=!1,vf(o,u.scale,u.originX,u.originY),a.dispatchAction(B(l(),{zoom:u.scale,originX:u.originX,originY:u.originY,animation:{duration:0}}))},this),i.setPointerChecker(function(u,c,v){return n.containPoint([c,v])&&!hl(u,a,e)})},r.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=i_(t).ignore)})},r.prototype._updateMapSelectHandler=function(e,t,a,n){var i=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){i._mouseDownFlag=!0}),t.on("click",function(o){i._mouseDownFlag&&(i._mouseDownFlag=!1)}))},r}();function Dd(r,e,t,a){var n=a.getModel("itemStyle"),i=a.getModel(["emphasis","itemStyle"]),o=a.getModel(["blur","itemStyle"]),s=a.getModel(["select","itemStyle"]),l=Lo(n),u=Lo(i),c=Lo(s),v=Lo(o),f=r.data;if(f){var h=f.getItemVisual(t,"style"),p=f.getItemVisual(t,"decal");r.isVisualEncodedByVisualMap&&h.fill&&(l.fill=h.fill),p&&(l.decal=sn(p,r.api))}e.setStyle(l),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=u,e.ensureState("select").style=c,e.ensureState("blur").style=v,Aa(e)}function Md(r,e,t,a,n,i,o){var s=r.data,l=r.isGeo,u=s&&isNaN(s.get(s.mapDimension("value"),i)),c=s&&s.getItemLayout(i);if(l||u||c&&c.showLabel){var v=l?t:i,f=void 0;(!s||i>=0)&&(f=n);var h=o?{normal:{align:"center",verticalAlign:"middle"}}:null;ae(e,Kt(a),{labelFetcher:f,labelDataIndex:v,defaultText:t},h);var p=e.getTextContent();if(p&&(i_(p).ignore=p.ignore,e.textConfig&&o)){var d=e.getBoundingRect().clone();e.textConfig.layoutRect=d,e.textConfig.position=[(o[0]-d.x)/d.width*100+"%",(o[1]-d.y)/d.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function Id(r,e,t,a,n,i){r.data?r.data.setItemGraphicEl(i,e):q(e).eventData={componentType:"geo",componentIndex:n.componentIndex,geoIndex:n.componentIndex,name:t,region:a&&a.option||{}}}function Ld(r,e,t,a,n){r.data||_n({el:e,componentModel:n,itemName:t,itemTooltipOption:a.get("tooltip")})}function Pd(r,e,t,a,n){e.highDownSilentOnTouch=!!n.get("selectedMode");var i=a.getModel("emphasis"),o=i.get("focus");return Nt(e,o,i.get("blurScope"),i.get("disabled")),r.isGeo&&Xw(e,n,t),o}function Ed(r,e,t){var a=[],n;function i(){n=[]}function o(){n.length&&(a.push(n),n=[])}var s=e({polygonStart:i,polygonEnd:o,lineStart:i,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&n.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),w(r,function(l){s.lineStart();for(var u=0;u<l.length;u++)s.point(l[u][0],l[u][1]);s.lineEnd()}),!t&&s.polygonEnd(),a}const o_=rP;var aP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){if(!(i&&i.type==="mapToggleSelect"&&i.from===this.uid)){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){if(this._mapDraw&&i&&i.type==="geoRoam"&&this._mapDraw.resetForLabelLayout(),i&&i.type==="geoRoam"&&i.componentType==="series"&&i.seriesId===t.id){var s=this._mapDraw;s&&o.add(s.group)}else if(t.needsDrawMap){var s=this._mapDraw||new o_(n);o.add(s.group),s.draw(t,a,n,this,i),this._mapDraw=s}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&a.getComponent("legend")&&this._renderSymbols(t,a,n)}}},e.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},e.prototype._renderSymbols=function(t,a,n){var i=t.originalData,o=this.group;i.each(i.mapDimension("value"),function(s,l){if(!isNaN(s)){var u=i.getItemLayout(l);if(!(!u||!u.point)){var c=u.point,v=u.offset,f=new ur({style:{fill:t.getData().getVisual("style").fill},shape:{cx:c[0]+v*9,cy:c[1],r:3},silent:!0,z2:8+(v?0:Sn+1)});if(!v){var h=t.mainSeries.getData(),p=i.getName(l),d=h.indexOfName(p),g=i.getItemModel(l),y=g.getModel("label"),m=h.getItemGraphicEl(d);ae(f,Kt(g),{labelFetcher:{getFormattedLabel:function(S,x){return t.getFormattedLabel(d,x)}},defaultText:p}),f.disableLabelAnimation=!0,y.get("position")||f.setTextConfig({position:"bottom"}),m.onHoverStateChange=function(S){hs(f,S)}}o.add(f)}}})},e.type="map",e}(Mt);const nP=aP;var iP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(a){if(a!=null){var n=this.getData().getName(a),i=this.coordinateSystem,o=i.getRegion(n);return o&&i.dataToPoint(o.getCenter())}},t}return e.prototype.getInitialData=function(t){for(var a=Pn(this,{coordDimensions:["value"],encodeDefaulter:Q(Nv,this)}),n=Z(),i=[],o=0,s=a.count();o<s;o++){var l=a.getName(o);n.set(l,!0)}var u=dr.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return w(u.regions,function(c){var v=c.name;n.get(v)||i.push(v)}),a.appendValues([],i),a},e.prototype.getHostGeoModel=function(){var t=this.option.geoIndex;return t!=null?this.ecModel.getComponent("geo",t):null},e.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},e.prototype.getRawValue=function(t){var a=this.getData();return a.get(a.mapDimension("value"),t)},e.prototype.getRegionModel=function(t){var a=this.getData();return a.getItemModel(a.indexOfName(t))},e.prototype.formatTooltip=function(t,a,n){for(var i=this.getData(),o=this.getRawValue(t),s=i.getName(t),l=this.seriesGroup,u=[],c=0;c<l.length;c++){var v=l[c].originalData.indexOfName(s),f=i.mapDimension("value");isNaN(l[c].originalData.get(f,v))||u.push(l[c].name)}return qt("section",{header:u.join(", "),noHeader:!u.length,blocks:[qt("nameValue",{name:s,value:o})]})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.getLegendIcon=function(t){var a=t.icon||"roundRect",n=Ht(a,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return n.setStyle(t.itemStyle),n.style.stroke="none",a.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(Et);const oP=iP;function sP(r,e){var t={};return w(r,function(a){a.each(a.mapDimension("value"),function(n,i){var o="ec-"+a.getName(i);t[o]=t[o]||[],isNaN(n)||t[o].push(n)})}),r[0].map(r[0].mapDimension("value"),function(a,n){for(var i="ec-"+r[0].getName(n),o=0,s=1/0,l=-1/0,u=t[i].length,c=0;c<u;c++)s=Math.min(s,t[i][c]),l=Math.max(l,t[i][c]),o+=t[i][c];var v;return e==="min"?v=s:e==="max"?v=l:e==="average"?v=o/u:v=o,u===0?NaN:v})}function lP(r){var e={};r.eachSeriesByType("map",function(t){var a=t.getHostGeoModel(),n=a?"o"+a.id:"i"+t.getMapType();(e[n]=e[n]||[]).push(t)}),w(e,function(t,a){for(var n=sP(G(t,function(o){return o.getData()}),t[0].get("mapValueCalculation")),i=0;i<t.length;i++)t[i].originalData=t[i].getData();for(var i=0;i<t.length;i++)t[i].seriesGroup=t,t[i].needsDrawMap=i===0&&!t[i].getHostGeoModel(),t[i].setData(n.cloneShallow()),t[i].mainSeries=t[0]})}function uP(r){var e={};r.eachSeriesByType("map",function(t){var a=t.getMapType();if(!(t.getHostGeoModel()||e[a])){var n={};w(t.seriesGroup,function(o){var s=o.coordinateSystem,l=o.originalData;o.get("showLegendSymbol")&&r.getComponent("legend")&&l.each(l.mapDimension("value"),function(u,c){var v=l.getName(c),f=s.getRegion(v);if(!(!f||isNaN(u))){var h=n[v]||0,p=s.dataToPoint(f.getCenter());n[v]=h+1,l.setItemLayout(c,{point:p,offset:h})}})});var i=t.getData();i.each(function(o){var s=i.getName(o),l=i.getItemLayout(o)||{};l.showLabel=!n[s],i.setItemLayout(o,l)}),e[a]=!0}})}var Rd=Le,cP=function(r){R(e,r);function e(t){var a=r.call(this)||this;return a.type="view",a.dimensions=["x","y"],a._roamTransformable=new qa,a._rawTransformable=new qa,a.name=t,a}return e.prototype.setBoundingRect=function(t,a,n,i){return this._rect=new wt(t,a,n,i),this._rect},e.prototype.getBoundingRect=function(){return this._rect},e.prototype.setViewRect=function(t,a,n,i){this._transformTo(t,a,n,i),this._viewRect=new wt(t,a,n,i)},e.prototype._transformTo=function(t,a,n,i){var o=this.getBoundingRect(),s=this._rawTransformable;s.transform=o.calculateTransform(new wt(t,a,n,i));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},e.prototype.setCenter=function(t,a){t&&(this._center=[F(t[0],a.getWidth()),F(t[1],a.getHeight())],this._updateCenterAndZoom())},e.prototype.setZoom=function(t){t=t||1;var a=this.zoomLimit;a&&(a.max!=null&&(t=Math.min(a.max,t)),a.min!=null&&(t=Math.max(a.min,t))),this._zoom=t,this._updateCenterAndZoom()},e.prototype.getDefaultCenter=function(){var t=this.getBoundingRect(),a=t.x+t.width/2,n=t.y+t.height/2;return[a,n]},e.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},e.prototype.getZoom=function(){return this._zoom||1},e.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},e.prototype._updateCenterAndZoom=function(){var t=this._rawTransformable.getLocalTransform(),a=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),o=this.getZoom();i=Le([],i,t),n=Le([],n,t),a.originX=i[0],a.originY=i[1],a.x=n[0]-i[0],a.y=n[1]-i[1],a.scaleX=a.scaleY=o,this._updateTransform()},e.prototype._updateTransform=function(){var t=this._roamTransformable,a=this._rawTransformable;a.parent=t,t.updateTransform(),a.updateTransform(),Ob(this.transform||(this.transform=[]),a.transform||yn()),this._rawTransform=a.getLocalTransform(),this.invTransform=this.invTransform||[],zi(this.invTransform,this.transform),this.decomposeTransform()},e.prototype.getTransformInfo=function(){var t=this._rawTransformable,a=this._roamTransformable,n=new qa;return n.transform=a.transform,n.decomposeTransform(),{roam:{x:n.x,y:n.y,scaleX:n.scaleX,scaleY:n.scaleY},raw:{x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY}}},e.prototype.getViewRect=function(){return this._viewRect},e.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},e.prototype.dataToPoint=function(t,a,n){var i=a?this._rawTransform:this.transform;return n=n||[],i?Rd(n,t,i):ce(n,t)},e.prototype.pointToData=function(t){var a=this.invTransform;return a?Rd([],t,a):[t[0],t[1]]},e.prototype.convertToPixel=function(t,a,n){var i=kd(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=kd(a);return i===this?i.pointToData(n):null},e.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},e.dimensions=["x","y"],e}(qa);function kd(r){var e=r.seriesModel;return e?e.coordinateSystem:null}const io=cP;var vP={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},s_=["lng","lat"],l_=function(r){R(e,r);function e(t,a,n){var i=r.call(this,t)||this;i.dimensions=s_,i.type="geo",i._nameCoordMap=Z(),i.map=a;var o=n.projection,s=dr.load(a,n.nameMap,n.nameProperty),l=dr.getGeoResource(a);i.resourceType=l?l.type:null;var u=i.regions=s.regions,c=vP[l.type];i._regionsMap=s.regionsMap,i.regions=s.regions,i.projection=o;var v;if(o)for(var f=0;f<u.length;f++){var h=u[f].getBoundingRect(o);v=v||h.clone(),v.union(h)}else v=s.boundingRect;return i.setBoundingRect(v.x,v.y,v.width,v.height),i.aspectScale=o?1:St(n.aspectScale,c.aspectScale),i._invertLongitute=o?!1:c.invertLongitute,i}return e.prototype._transformTo=function(t,a,n,i){var o=this.getBoundingRect(),s=this._invertLongitute;o=o.clone(),s&&(o.y=-o.y-o.height);var l=this._rawTransformable;l.transform=o.calculateTransform(new wt(t,a,n,i));var u=l.parent;l.parent=null,l.decomposeTransform(),l.parent=u,s&&(l.scaleY=-l.scaleY),this._updateTransform()},e.prototype.getRegion=function(t){return this._regionsMap.get(t)},e.prototype.getRegionByCoord=function(t){for(var a=this.regions,n=0;n<a.length;n++){var i=a[n];if(i.type==="geoJSON"&&i.contain(t))return a[n]}},e.prototype.addGeoCoord=function(t,a){this._nameCoordMap.set(t,a)},e.prototype.getGeoCoord=function(t){var a=this._regionsMap.get(t);return this._nameCoordMap.get(t)||a&&a.getCenter()},e.prototype.dataToPoint=function(t,a,n){if($(t)&&(t=this.getGeoCoord(t)),t){var i=this.projection;return i&&(t=i.project(t)),t&&this.projectedToPoint(t,a,n)}},e.prototype.pointToData=function(t){var a=this.projection;return a&&(t=a.unproject(t)),t&&this.pointToProjected(t)},e.prototype.pointToProjected=function(t){return r.prototype.pointToData.call(this,t)},e.prototype.projectedToPoint=function(t,a,n){return r.prototype.dataToPoint.call(this,t,a,n)},e.prototype.convertToPixel=function(t,a,n){var i=Nd(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=Nd(a);return i===this?i.pointToData(n):null},e}(io);jt(l_,io);function Nd(r){var e=r.geoModel,t=r.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",Ft).models[0]||{}).coordinateSystem:null}const Od=l_;function Vd(r,e){var t=r.get("boundingCoords");if(t!=null){var a=t[0],n=t[1];if(isFinite(a[0])&&isFinite(a[1])&&isFinite(n[0])&&isFinite(n[1])){var i=this.projection;if(i){var o=a[0],s=a[1],l=n[0],u=n[1];a=[1/0,1/0],n=[-1/0,-1/0];var c=function(_,A,T,C){for(var M=T-_,D=C-A,I=0;I<=100;I++){var L=I/100,P=i.project([_+M*L,A+D*L]);Nm(a,a,P),Om(n,n,P)}};c(o,s,l,s),c(l,s,l,u),c(l,u,o,u),c(o,u,l,s)}this.setBoundingRect(a[0],a[1],n[0]-a[0],n[1]-a[1])}}var v=this.getBoundingRect(),f=r.get("layoutCenter"),h=r.get("layoutSize"),p=e.getWidth(),d=e.getHeight(),g=v.width/v.height*this.aspectScale,y=!1,m,S;f&&h&&(m=[F(f[0],p),F(f[1],d)],S=F(h,Math.min(p,d)),!isNaN(m[0])&&!isNaN(m[1])&&!isNaN(S)&&(y=!0));var x;if(y)x={},g>1?(x.width=S,x.height=S/g):(x.height=S,x.width=S*g),x.y=m[1]-x.height/2,x.x=m[0]-x.width/2;else{var b=r.getBoxLayoutParams();b.aspect=g,x=Yt(b,{width:p,height:d})}this.setViewRect(x.x,x.y,x.width,x.height),this.setCenter(r.get("center"),e),this.setZoom(r.get("zoom"))}function fP(r,e){w(e.get("geoCoord"),function(t,a){r.addGeoCoord(a,t)})}var hP=function(){function r(){this.dimensions=s_}return r.prototype.create=function(e,t){var a=[];function n(o){return{nameProperty:o.get("nameProperty"),aspectScale:o.get("aspectScale"),projection:o.get("projection")}}e.eachComponent("geo",function(o,s){var l=o.get("map"),u=new Od(l+s,l,B({nameMap:o.get("nameMap")},n(o)));u.zoomLimit=o.get("scaleLimit"),a.push(u),o.coordinateSystem=u,u.model=o,u.resize=Vd,u.resize(o,t)}),e.eachSeries(function(o){var s=o.get("coordinateSystem");if(s==="geo"){var l=o.get("geoIndex")||0;o.coordinateSystem=a[l]}});var i={};return e.eachSeriesByType("map",function(o){if(!o.getHostGeoModel()){var s=o.getMapType();i[s]=i[s]||[],i[s].push(o)}}),w(i,function(o,s){var l=G(o,function(c){return c.get("nameMap")}),u=new Od(s,s,B({nameMap:yv(l)},n(o[0])));u.zoomLimit=Jt.apply(null,G(o,function(c){return c.get("scaleLimit")})),a.push(u),u.resize=Vd,u.resize(o[0],t),w(o,function(c){c.coordinateSystem=u,fP(u,c)})}),a},r.prototype.getFilledRegions=function(e,t,a,n){for(var i=(e||[]).slice(),o=Z(),s=0;s<i.length;s++)o.set(i[s].name,i[s]);var l=dr.load(t,a,n);return w(l.regions,function(u){var c=u.name;!o.get(c)&&i.push({name:c})}),i},r}(),pP=new hP;const u_=pP;var dP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a,n){var i=dr.getGeoResource(t.map);if(i&&i.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color="#eee")}this.mergeDefaultAndTheme(t,n),_a(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,a=this.option;a.regions=u_.getFilledRegions(a.regions,a.map,a.nameMap,a.nameProperty);var n={};this._optionModelMap=rn(a.regions||[],function(i,o){var s=o.name;return s&&(i.set(s,new Dt(o,t,t.ecModel)),o.selected&&(n[s]=!0)),i},Z()),a.selectedMap||(a.selectedMap=n)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new Dt(null,this,this.ecModel)},e.prototype.getFormattedLabel=function(t,a){var n=this.getRegionModel(t),i=a==="normal"?n.get(["label","formatter"]):n.get(["emphasis","label","formatter"]),o={name:t};if(X(i))return o.status=a,i(o);if($(i))return i.replace("{a}",t??"")},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.select=function(t){var a=this.option,n=a.selectedMode;if(n){n!=="multiple"&&(a.selectedMap=null);var i=a.selectedMap||(a.selectedMap={});i[t]=!0}},e.prototype.unSelect=function(t){var a=this.option.selectedMap;a&&(a[t]=!1)},e.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},e.prototype.isSelected=function(t){var a=this.option.selectedMap;return!!(a&&a[t])},e.type="geo",e.layoutMode="box",e.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},e}(lt);const gP=dP;function Bd(r,e){return r.pointToProjected?r.pointToProjected(e):r.pointToData(e)}function hf(r,e,t,a){var n=r.getZoom(),i=r.getCenter(),o=e.zoom,s=r.projectedToPoint?r.projectedToPoint(i):r.dataToPoint(i);if(e.dx!=null&&e.dy!=null&&(s[0]-=e.dx,s[1]-=e.dy,r.setCenter(Bd(r,s),a)),o!=null){if(t){var l=t.min||0,u=t.max||1/0;o=Math.max(Math.min(n*o,u),l)/n}r.scaleX*=o,r.scaleY*=o;var c=(e.originX-r.x)*(o-1),v=(e.originY-r.y)*(o-1);r.x-=c,r.y-=v,r.updateTransform(),r.setCenter(Bd(r,s),a),r.setZoom(o*n)}return{center:r.getCenter(),zoom:r.getZoom()}}var yP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.focusBlurEnabled=!0,t}return e.prototype.init=function(t,a){this._api=a},e.prototype.render=function(t,a,n,i){if(this._model=t,!t.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new o_(n));var o=this._mapDraw;o.draw(t,a,n,this,i),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,a,n)},e.prototype._handleRegionClick=function(t){var a;ca(t.target,function(n){return(a=q(n).eventData)!=null},!0),a&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:a.name})},e.prototype.updateSelectStatus=function(t,a,n){var i=this;this._mapDraw.group.traverse(function(o){var s=q(o).eventData;if(s)return i._model.isSelected(s.name)?n.enterSelect(o):n.leaveSelect(o),!0})},e.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},e.type="geo",e}(Ot);const mP=yP;function SP(r,e,t){dr.registerMap(r,e,t)}function c_(r){r.registerCoordinateSystem("geo",u_),r.registerComponentModel(gP),r.registerComponentView(mP),r.registerImpl("registerMap",SP),r.registerImpl("getMap",function(t){return dr.getMapForUser(t)});function e(t,a){a.update="geo:updateSelectStatus",r.registerAction(a,function(n,i){var o={},s=[];return i.eachComponent({mainType:"geo",query:n},function(l){l[t](n.name);var u=l.coordinateSystem;w(u.regions,function(v){o[v.name]=l.isSelected(v.name)||!1});var c=[];w(o,function(v,f){o[f]&&c.push(f)}),s.push({geoIndex:l.componentIndex,name:c})}),{selected:o,allSelected:s,name:n.name}})}e("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),e("select",{type:"geoSelect",event:"geoselected"}),e("unSelect",{type:"geoUnSelect",event:"geounselected"}),r.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,a,n){var i=t.componentType||"series";a.eachComponent({mainType:i,query:t},function(o){var s=o.coordinateSystem;if(s.type==="geo"){var l=hf(s,t,o.get("scaleLimit"),n);o.setCenter&&o.setCenter(l.center),o.setZoom&&o.setZoom(l.zoom),i==="series"&&w(o.seriesGroup,function(u){u.setCenter(l.center),u.setZoom(l.zoom)})}})})}function xP(r){it(c_),r.registerChartView(nP),r.registerSeriesModel(oP),r.registerLayout(uP),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,lP),MS("map",r.registerAction)}function _P(r){var e=r;e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var t=[e],a,n;a=t.pop();)if(n=a.children,a.isExpand&&n.length)for(var i=n.length,o=i-1;o>=0;o--){var s=n[o];s.hierNode={defaultAncestor:null,ancestor:s,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},t.push(s)}}function bP(r,e){var t=r.isExpand?r.children:[],a=r.parentNode.children,n=r.hierNode.i?a[r.hierNode.i-1]:null;if(t.length){TP(r);var i=(t[0].hierNode.prelim+t[t.length-1].hierNode.prelim)/2;n?(r.hierNode.prelim=n.hierNode.prelim+e(r,n),r.hierNode.modifier=r.hierNode.prelim-i):r.hierNode.prelim=i}else n&&(r.hierNode.prelim=n.hierNode.prelim+e(r,n));r.parentNode.hierNode.defaultAncestor=CP(r,n,r.parentNode.hierNode.defaultAncestor||a[0],e)}function wP(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function zd(r){return arguments.length?r:IP}function ai(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function AP(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function TP(r){for(var e=r.children,t=e.length,a=0,n=0;--t>=0;){var i=e[t];i.hierNode.prelim+=a,i.hierNode.modifier+=a,n+=i.hierNode.change,a+=i.hierNode.shift+n}}function CP(r,e,t,a){if(e){for(var n=r,i=r,o=i.parentNode.children[0],s=e,l=n.hierNode.modifier,u=i.hierNode.modifier,c=o.hierNode.modifier,v=s.hierNode.modifier;s=su(s),i=lu(i),s&&i;){n=su(n),o=lu(o),n.hierNode.ancestor=r;var f=s.hierNode.prelim+v-i.hierNode.prelim-u+a(s,i);f>0&&(MP(DP(s,r,t),r,f),u+=f,l+=f),v+=s.hierNode.modifier,u+=i.hierNode.modifier,l+=n.hierNode.modifier,c+=o.hierNode.modifier}s&&!su(n)&&(n.hierNode.thread=s,n.hierNode.modifier+=v-l),i&&!lu(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-c,t=r)}return t}function su(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function lu(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function DP(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function MP(r,e,t){var a=t/(e.hierNode.i-r.hierNode.i);e.hierNode.change-=a,e.hierNode.shift+=t,e.hierNode.modifier+=t,e.hierNode.prelim+=t,r.hierNode.change+=a}function IP(r,e){return r.parentNode===e.parentNode?1:2}var LP=function(){function r(){this.parentPoint=[],this.childPoints=[]}return r}(),PP=function(r){R(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new LP},e.prototype.buildPath=function(t,a){var n=a.childPoints,i=n.length,o=a.parentPoint,s=n[0],l=n[i-1];if(i===1){t.moveTo(o[0],o[1]),t.lineTo(s[0],s[1]);return}var u=a.orient,c=u==="TB"||u==="BT"?0:1,v=1-c,f=F(a.forkPosition,1),h=[];h[c]=o[c],h[v]=o[v]+(l[v]-o[v])*f,t.moveTo(o[0],o[1]),t.lineTo(h[0],h[1]),t.moveTo(s[0],s[1]),h[c]=s[c],t.lineTo(h[0],h[1]),h[c]=l[c],t.lineTo(h[0],h[1]),t.lineTo(l[0],l[1]);for(var p=1;p<i-1;p++){var d=n[p];t.moveTo(d[0],d[1]),h[c]=d[c],t.lineTo(h[0],h[1])}},e}(It),EP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._mainGroup=new tt,t}return e.prototype.init=function(t,a){this._controller=new no(a.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},e.prototype.render=function(t,a,n){var i=t.getData(),o=t.layoutInfo,s=this._mainGroup,l=t.get("layout");l==="radial"?(s.x=o.x+o.width/2,s.y=o.y+o.height/2):(s.x=o.x,s.y=o.y),this._updateViewCoordSys(t,n),this._updateController(t,a,n);var u=this._data;i.diff(u).add(function(c){Gd(i,c)&&Fd(i,c,null,s,t)}).update(function(c,v){var f=u.getItemGraphicEl(v);if(!Gd(i,c)){f&&Wd(u,v,f,s,t);return}Fd(i,c,f,s,t)}).remove(function(c){var v=u.getItemGraphicEl(c);v&&Wd(u,c,v,s,t)}).execute(),this._nodeScaleRatio=t.get("nodeScaleRatio"),this._updateNodeAndLinkScale(t),t.get("expandAndCollapse")===!0&&i.eachItemGraphicEl(function(c,v){c.off("click").on("click",function(){n.dispatchAction({type:"treeExpandAndCollapse",seriesId:t.id,dataIndex:v})})}),this._data=i},e.prototype._updateViewCoordSys=function(t,a){var n=t.getData(),i=[];n.each(function(v){var f=n.getItemLayout(v);f&&!isNaN(f.x)&&!isNaN(f.y)&&i.push([+f.x,+f.y])});var o=[],s=[];Bm(i,o,s);var l=this._min,u=this._max;s[0]-o[0]===0&&(o[0]=l?l[0]:o[0]-1,s[0]=u?u[0]:s[0]+1),s[1]-o[1]===0&&(o[1]=l?l[1]:o[1]-1,s[1]=u?u[1]:s[1]+1);var c=t.coordinateSystem=new io;c.zoomLimit=t.get("scaleLimit"),c.setBoundingRect(o[0],o[1],s[0]-o[0],s[1]-o[1]),c.setCenter(t.get("center"),a),c.setZoom(t.get("zoom")),this.group.attr({x:c.x,y:c.y,scaleX:c.scaleX,scaleY:c.scaleY}),this._min=o,this._max=s},e.prototype._updateController=function(t,a,n){var i=this,o=this._controller,s=this._controllerHost,l=this.group;o.setPointerChecker(function(u,c,v){var f=l.getBoundingRect();return f.applyTransform(l.transform),f.contain(c,v)&&!hl(u,n,t)}),o.enable(t.get("roam")),s.zoomLimit=t.get("scaleLimit"),s.zoom=t.coordinateSystem.getZoom(),o.off("pan").off("zoom").on("pan",function(u){cf(s,u.dx,u.dy),n.dispatchAction({seriesId:t.id,type:"treeRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){vf(s,u.scale,u.originX,u.originY),n.dispatchAction({seriesId:t.id,type:"treeRoam",zoom:u.scale,originX:u.originX,originY:u.originY}),i._updateNodeAndLinkScale(t),n.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(t){var a=t.getData(),n=this._getNodeGlobalScale(t);a.eachItemGraphicEl(function(i,o){i.setSymbolScale(n)})},e.prototype._getNodeGlobalScale=function(t){var a=t.coordinateSystem;if(a.type!=="view")return 1;var n=this._nodeScaleRatio,i=a.scaleX||1,o=a.getZoom(),s=(o-1)*n+1;return s/i},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},e.type="tree",e}(Mt);function Gd(r,e){var t=r.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function Fd(r,e,t,a,n){var i=!t,o=r.tree.getNodeByDataIndex(e),s=o.getModel(),l=o.getVisual("style").fill,u=o.isExpand===!1&&o.children.length!==0?l:"#fff",c=r.tree.root,v=o.parentNode===c?o:o.parentNode||o,f=r.getItemGraphicEl(v.dataIndex),h=v.getLayout(),p=f?{x:f.__oldX,y:f.__oldY,rawX:f.__radialOldRawX,rawY:f.__radialOldRawY}:h,d=o.getLayout();i?(t=new Qi(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.x=p.x,t.y=p.y):t.updateData(r,e,null,{symbolInnerColor:u,useNameLabel:!0}),t.__radialOldRawX=t.__radialRawX,t.__radialOldRawY=t.__radialRawY,t.__radialRawX=d.rawX,t.__radialRawY=d.rawY,a.add(t),r.setItemGraphicEl(e,t),t.__oldX=t.x,t.__oldY=t.y,ft(t,{x:d.x,y:d.y},n);var g=t.getSymbolPath();if(n.get("layout")==="radial"){var y=c.children[0],m=y.getLayout(),S=y.children.length,x=void 0,b=void 0;if(d.x===m.x&&o.isExpand===!0&&y.children.length){var _={x:(y.children[0].getLayout().x+y.children[S-1].getLayout().x)/2,y:(y.children[0].getLayout().y+y.children[S-1].getLayout().y)/2};x=Math.atan2(_.y-m.y,_.x-m.x),x<0&&(x=Math.PI*2+x),b=_.x<m.x,b&&(x=x-Math.PI)}else x=Math.atan2(d.y-m.y,d.x-m.x),x<0&&(x=Math.PI*2+x),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(b=d.x<m.x,b&&(x=x-Math.PI)):(b=d.x>m.x,b||(x=x-Math.PI));var A=b?"left":"right",T=s.getModel("label"),C=T.get("rotate"),M=C*(Math.PI/180),D=g.getTextContent();D&&(g.setTextConfig({position:T.get("position")||A,rotation:C==null?-x:M,origin:"center"}),D.setStyle("verticalAlign","middle"))}var I=s.get(["emphasis","focus"]),L=I==="relative"?ls(o.getAncestorsIndices(),o.getDescendantIndices()):I==="ancestor"?o.getAncestorsIndices():I==="descendant"?o.getDescendantIndices():null;L&&(q(t).focus=L),RP(n,o,c,t,p,h,d,a),t.__edge&&(t.onHoverStateChange=function(P){if(P!=="blur"){var E=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);E&&E.hoverState===$i||hs(t.__edge,P)}})}function RP(r,e,t,a,n,i,o,s){var l=e.getModel(),u=r.get("edgeShape"),c=r.get("layout"),v=r.getOrient(),f=r.get(["lineStyle","curveness"]),h=r.get("edgeForkPosition"),p=l.getModel("lineStyle").getLineStyle(),d=a.__edge;if(u==="curve")e.parentNode&&e.parentNode!==t&&(d||(d=a.__edge=new Ws({shape:Fc(c,v,f,n,n)})),ft(d,{shape:Fc(c,v,f,i,o)},r));else if(u==="polyline"&&c==="orthogonal"&&e!==t&&e.children&&e.children.length!==0&&e.isExpand===!0){for(var g=e.children,y=[],m=0;m<g.length;m++){var S=g[m].getLayout();y.push([S.x,S.y])}d||(d=a.__edge=new PP({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:v,forkPosition:h}})),ft(d,{shape:{parentPoint:[o.x,o.y],childPoints:y}},r)}d&&!(u==="polyline"&&!e.isExpand)&&(d.useStyle(J({strokeNoScale:!0,fill:null},p)),re(d,l,"lineStyle"),Aa(d),s.add(d))}function Hd(r,e,t,a,n){var i=e.tree.root,o=v_(i,r),s=o.source,l=o.sourceLayout,u=e.getItemGraphicEl(r.dataIndex);if(u){var c=e.getItemGraphicEl(s.dataIndex),v=c.__edge,f=u.__edge||(s.isExpand===!1||s.children.length===1?v:void 0),h=a.get("edgeShape"),p=a.get("layout"),d=a.get("orient"),g=a.get(["lineStyle","curveness"]);f&&(h==="curve"?Or(f,{shape:Fc(p,d,g,l,l),style:{opacity:0}},a,{cb:function(){t.remove(f)},removeOpt:n}):h==="polyline"&&a.get("layout")==="orthogonal"&&Or(f,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},a,{cb:function(){t.remove(f)},removeOpt:n}))}}function v_(r,e){for(var t=e.parentNode===r?e:e.parentNode||e,a;a=t.getLayout(),a==null;)t=t.parentNode===r?t:t.parentNode||t;return{source:t,sourceLayout:a}}function Wd(r,e,t,a,n){var i=r.tree.getNodeByDataIndex(e),o=r.tree.root,s=v_(o,i).sourceLayout,l={duration:n.get("animationDurationUpdate"),easing:n.get("animationEasingUpdate")};Or(t,{x:s.x+1,y:s.y+1},n,{cb:function(){a.remove(t),r.setItemGraphicEl(e,null)},removeOpt:l}),t.fadeOut(null,r.hostModel,{fadeLabel:!0,animation:l}),i.children.forEach(function(u){Hd(u,r,a,n,l)}),Hd(i,r,a,n,l)}function Fc(r,e,t,a,n){var i,o,s,l,u,c,v,f;if(r==="radial"){u=a.rawX,v=a.rawY,c=n.rawX,f=n.rawY;var h=ai(u,v),p=ai(u,v+(f-v)*t),d=ai(c,f+(v-f)*t),g=ai(c,f);return{x1:h.x||0,y1:h.y||0,x2:g.x||0,y2:g.y||0,cpx1:p.x||0,cpy1:p.y||0,cpx2:d.x||0,cpy2:d.y||0}}else u=a.x,v=a.y,c=n.x,f=n.y,(e==="LR"||e==="RL")&&(i=u+(c-u)*t,o=v,s=c+(u-c)*t,l=f),(e==="TB"||e==="BT")&&(i=u,o=v+(f-v)*t,s=c,l=f+(v-f)*t);return{x1:u,y1:v,x2:c,y2:f,cpx1:i,cpy1:o,cpx2:s,cpy2:l}}const kP=EP;var Ie=st();function f_(r){var e=r.mainData,t=r.datas;t||(t={main:e},r.datasAttr={main:"data"}),r.datas=r.mainData=null,h_(e,t,r),w(t,function(a){w(e.TRANSFERABLE_METHODS,function(n){a.wrapMethod(n,Q(NP,r))})}),e.wrapMethod("cloneShallow",Q(VP,r)),w(e.CHANGABLE_METHODS,function(a){e.wrapMethod(a,Q(OP,r))}),ye(t[e.dataType]===e)}function NP(r,e){if(GP(this)){var t=B({},Ie(this).datas);t[this.dataType]=e,h_(e,t,r)}else pf(e,this.dataType,Ie(this).mainData,r);return e}function OP(r,e){return r.struct&&r.struct.update(),e}function VP(r,e){return w(Ie(e).datas,function(t,a){t!==e&&pf(t.cloneShallow(),a,e,r)}),e}function BP(r){var e=Ie(this).mainData;return r==null||e==null?e:Ie(e).datas[r]}function zP(){var r=Ie(this).mainData;return r==null?[{data:r}]:G(Wt(Ie(r).datas),function(e){return{type:e,data:Ie(r).datas[e]}})}function GP(r){return Ie(r).mainData===r}function h_(r,e,t){Ie(r).datas={},w(e,function(a,n){pf(a,n,r,t)})}function pf(r,e,t,a){Ie(t).datas[e]=r,Ie(r).mainData=t,r.dataType=e,a.struct&&(r[a.structAttr]=a.struct,a.struct[a.datasAttr[e]]=r),r.getLinkedData=BP,r.getLinkedDataAll=zP}var FP=function(){function r(e,t){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=e||"",this.hostTree=t}return r.prototype.isRemoved=function(){return this.dataIndex<0},r.prototype.eachNode=function(e,t,a){X(e)&&(a=t,t=e,e=null),e=e||{},$(e)&&(e={order:e});var n=e.order||"preorder",i=this[e.attr||"children"],o;n==="preorder"&&(o=t.call(a,this));for(var s=0;!o&&s<i.length;s++)i[s].eachNode(e,t,a);n==="postorder"&&t.call(a,this)},r.prototype.updateDepthAndHeight=function(e){var t=0;this.depth=e;for(var a=0;a<this.children.length;a++){var n=this.children[a];n.updateDepthAndHeight(e+1),n.height>t&&(t=n.height)}this.height=t+1},r.prototype.getNodeById=function(e){if(this.getId()===e)return this;for(var t=0,a=this.children,n=a.length;t<n;t++){var i=a[t].getNodeById(e);if(i)return i}},r.prototype.contains=function(e){if(e===this)return!0;for(var t=0,a=this.children,n=a.length;t<n;t++){var i=a[t].contains(e);if(i)return i}},r.prototype.getAncestors=function(e){for(var t=[],a=e?this:this.parentNode;a;)t.push(a),a=a.parentNode;return t.reverse(),t},r.prototype.getAncestorsIndices=function(){for(var e=[],t=this;t;)e.push(t.dataIndex),t=t.parentNode;return e.reverse(),e},r.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},r.prototype.getValue=function(e){var t=this.hostTree.data;return t.getStore().get(t.getDimensionIndex(e||"value"),this.dataIndex)},r.prototype.setLayout=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,e,t)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostTree,a=t.data.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(e,t){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,e,t)},r.prototype.getVisual=function(e){return this.hostTree.data.getItemVisual(this.dataIndex,e)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.prototype.getChildIndex=function(){if(this.parentNode){for(var e=this.parentNode.children,t=0;t<e.length;++t)if(e[t]===this)return t;return-1}return-1},r.prototype.isAncestorOf=function(e){for(var t=e.parentNode;t;){if(t===this)return!0;t=t.parentNode}return!1},r.prototype.isDescendantOf=function(e){return e!==this&&e.isAncestorOf(this)},r}(),HP=function(){function r(e){this.type="tree",this._nodes=[],this.hostModel=e}return r.prototype.eachNode=function(e,t,a){this.root.eachNode(e,t,a)},r.prototype.getNodeByDataIndex=function(e){var t=this.data.getRawIndex(e);return this._nodes[t]},r.prototype.getNodeById=function(e){return this.root.getNodeById(e)},r.prototype.update=function(){for(var e=this.data,t=this._nodes,a=0,n=t.length;a<n;a++)t[a].dataIndex=-1;for(var a=0,n=e.count();a<n;a++)t[e.getRawIndex(a)].dataIndex=a},r.prototype.clearLayouts=function(){this.data.clearItemLayouts()},r.createTree=function(e,t,a){var n=new r(t),i=[],o=1;s(e);function s(c,v){var f=c.value;o=Math.max(o,O(f)?f.length:1),i.push(c);var h=new FP(Ut(c.name,""),n);v?WP(h,v):n.root=h,n._nodes.push(h);var p=c.children;if(p)for(var d=0;d<p.length;d++)s(p[d],h)}n.root.updateDepthAndHeight(0);var l=qi(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new fe(l,t);return u.initData(i),a&&a(u),f_({mainData:u,struct:n,structAttr:"tree"}),n.update(),n},r}();function WP(r,e){var t=e.children;r.parentNode!==e&&(t.push(r),r.parentNode=e)}const df=HP;function Pi(r,e,t){if(r&&ct(e,r.type)>=0){var a=t.getData().tree.root,n=r.targetNode;if($(n)&&(n=a.getNodeById(n)),n&&a.contains(n))return{node:n};var i=r.targetNodeId;if(i!=null&&(n=a.getNodeById(i)))return{node:n}}}function p_(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function gf(r,e){var t=p_(r);return ct(t,e)>=0}function pl(r,e){for(var t=[];r;){var a=r.dataIndex;t.push({name:r.name,dataIndex:a,value:e.getRawValue(a)}),r=r.parentNode}return t.reverse(),t}var $P=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t){var a={name:t.name,children:t.data},n=t.leaves||{},i=new Dt(n,this,this.ecModel),o=df.createTree(a,this,s);function s(v){v.wrapMethod("getItemModel",function(f,h){var p=o.getNodeByDataIndex(h);return p&&p.children.length&&p.isExpand||(f.parentModel=i),f})}var l=0;o.eachNode("preorder",function(v){v.depth>l&&(l=v.depth)});var u=t.expandAndCollapse,c=u&&t.initialTreeDepth>=0?t.initialTreeDepth:l;return o.root.eachNode("preorder",function(v){var f=v.hostTree.data.getRawDataItem(v.dataIndex);v.isExpand=f&&f.collapsed!=null?!f.collapsed:v.depth<=c}),o.data},e.prototype.getOrient=function(){var t=this.get("orient");return t==="horizontal"?t="LR":t==="vertical"&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,a,n){for(var i=this.getData().tree,o=i.root.children[0],s=i.getNodeByDataIndex(t),l=s.getValue(),u=s.name;s&&s!==o;)u=s.parentNode.name+"."+u,s=s.parentNode;return qt("nameValue",{name:u,value:l,noValue:isNaN(l)||l==null})},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treeAncestors=pl(n,this),a.collapsed=!n.isExpand,a},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e}(Et);const UP=$P;function YP(r,e,t){for(var a=[r],n=[],i;i=a.pop();)if(n.push(i),i.isExpand){var o=i.children;if(o.length)for(var s=0;s<o.length;s++)a.push(o[s])}for(;i=n.pop();)e(i,t)}function Yn(r,e){for(var t=[r],a;a=t.pop();)if(e(a),a.isExpand){var n=a.children;if(n.length)for(var i=n.length-1;i>=0;i--)t.push(n[i])}}function ZP(r,e){r.eachSeriesByType("tree",function(t){XP(t,e)})}function XP(r,e){var t=AP(r,e);r.layoutInfo=t;var a=r.get("layout"),n=0,i=0,o=null;a==="radial"?(n=2*Math.PI,i=Math.min(t.height,t.width)/2,o=zd(function(S,x){return(S.parentNode===x.parentNode?1:2)/S.depth})):(n=t.width,i=t.height,o=zd());var s=r.getData().tree.root,l=s.children[0];if(l){_P(s),YP(l,bP,o),s.hierNode.modifier=-l.hierNode.prelim,Yn(l,wP);var u=l,c=l,v=l;Yn(l,function(S){var x=S.getLayout().x;x<u.getLayout().x&&(u=S),x>c.getLayout().x&&(c=S),S.depth>v.depth&&(v=S)});var f=u===c?1:o(u,c)/2,h=f-u.getLayout().x,p=0,d=0,g=0,y=0;if(a==="radial")p=n/(c.getLayout().x+f+h),d=i/(v.depth-1||1),Yn(l,function(S){g=(S.getLayout().x+h)*p,y=(S.depth-1)*d;var x=ai(g,y);S.setLayout({x:x.x,y:x.y,rawX:g,rawY:y},!0)});else{var m=r.getOrient();m==="RL"||m==="LR"?(d=i/(c.getLayout().x+f+h),p=n/(v.depth-1||1),Yn(l,function(S){y=(S.getLayout().x+h)*d,g=m==="LR"?(S.depth-1)*p:n-(S.depth-1)*p,S.setLayout({x:g,y},!0)})):(m==="TB"||m==="BT")&&(p=n/(c.getLayout().x+f+h),d=i/(v.depth-1||1),Yn(l,function(S){g=(S.getLayout().x+h)*p,y=m==="TB"?(S.depth-1)*d:i-(S.depth-1)*d,S.setLayout({x:g,y},!0)}))}}}function KP(r){r.eachSeriesByType("tree",function(e){var t=e.getData(),a=t.tree;a.eachNode(function(n){var i=n.getModel(),o=i.getModel("itemStyle").getItemStyle(),s=t.ensureUniqueItemVisual(n.dataIndex,"style");B(s,o)})})}function qP(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"tree",query:e},function(a){var n=e.dataIndex,i=a.getData().tree,o=i.getNodeByDataIndex(n);o.isExpand=!o.isExpand})}),r.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(e,t,a){t.eachComponent({mainType:"series",subType:"tree",query:e},function(n){var i=n.coordinateSystem,o=hf(i,e,void 0,a);n.setCenter&&n.setCenter(o.center),n.setZoom&&n.setZoom(o.zoom)})})}function jP(r){r.registerChartView(kP),r.registerSeriesModel(UP),r.registerLayout(ZP),r.registerVisual(KP),qP(r)}var $d=["treemapZoomToNode","treemapRender","treemapMove"];function JP(r){for(var e=0;e<$d.length;e++)r.registerAction({type:$d[e],update:"updateView"},he);r.registerAction({type:"treemapRootToNode",update:"updateView"},function(t,a){a.eachComponent({mainType:"series",subType:"treemap",query:t},n);function n(i,o){var s=["treemapZoomToNode","treemapRootToNode"],l=Pi(t,s,i);if(l){var u=i.getViewRoot();u&&(t.direction=gf(u,l.node)?"rollUp":"drillDown"),i.resetViewRoot(l.node)}}})}function d_(r){var e=r.getData(),t=e.tree,a={};t.eachNode(function(n){for(var i=n;i&&i.depth>1;)i=i.parentNode;var o=_c(r.ecModel,i.name||i.dataIndex+"",a);n.setVisual("decal",o)})}var QP=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventUsingHoverLayer=!0,t}return e.prototype.getInitialData=function(t,a){var n={name:t.name,children:t.data};g_(n);var i=t.levels||[],o=this.designatedVisualItemStyle={},s=new Dt({itemStyle:o},this,a);i=t.levels=t2(i,a);var l=G(i||[],function(v){return new Dt(v,s,a)},this),u=df.createTree(n,this,c);function c(v){v.wrapMethod("getItemModel",function(f,h){var p=u.getNodeByDataIndex(h),d=p?l[p.depth]:null;return f.parentModel=d||s,f})}return u.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return qt("nameValue",{name:s,value:o})},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treeAncestors=pl(n,this),a.treePathInfo=a.treeAncestors,a},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},B(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var a=this._idIndexMap;a||(a=this._idIndexMap=Z(),this._idIndexMapCount=0);var n=a.get(t);return n==null&&a.set(t,n=this._idIndexMapCount++),n},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var a=this.getRawData().tree.root;(!t||t!==a&&!a.contains(t))&&(this._viewRoot=a)},e.prototype.enableAriaDecal=function(){d_(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.32*.32,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e}(Et);function g_(r){var e=0;w(r.children,function(a){g_(a);var n=a.value;O(n)&&(n=n[0]),e+=n});var t=r.value;O(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),O(r.value)?r.value[0]=t:r.value=t}function t2(r,e){var t=_t(e.get("color")),a=_t(e.get(["aria","decal","decals"]));if(t){r=r||[];var n,i;w(r,function(s){var l=new Dt(s),u=l.get("color"),c=l.get("decal");(l.get(["itemStyle","color"])||u&&u!=="none")&&(n=!0),(l.get(["itemStyle","decal"])||c&&c!=="none")&&(i=!0)});var o=r[0]||(r[0]={});return n||(o.color=t.slice()),!i&&a&&(o.decal=a.slice()),r}}const e2=QP;var r2=8,Ud=8,uu=5,a2=function(){function r(e){this.group=new tt,e.add(this.group)}return r.prototype.render=function(e,t,a,n){var i=e.getModel("breadcrumb"),o=this.group;if(o.removeAll(),!(!i.get("show")||!a)){var s=i.getModel("itemStyle"),l=i.getModel("emphasis"),u=s.getModel("textStyle"),c=l.getModel(["itemStyle","textStyle"]),v={pos:{left:i.get("left"),right:i.get("right"),top:i.get("top"),bottom:i.get("bottom")},box:{width:t.getWidth(),height:t.getHeight()},emptyItemWidth:i.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(a,v,u),this._renderContent(e,v,s,l,u,c,n),al(o,v.pos,v.box)}},r.prototype._prepare=function(e,t,a){for(var n=e;n;n=n.parentNode){var i=Ut(n.getModel().get("name"),""),o=a.getTextRect(i),s=Math.max(o.width+r2*2,t.emptyItemWidth);t.totalWidth+=s+Ud,t.renderList.push({node:n,text:i,width:s})}},r.prototype._renderContent=function(e,t,a,n,i,o,s){for(var l=0,u=t.emptyItemWidth,c=e.get(["breadcrumb","height"]),v=DA(t.pos,t.box),f=t.totalWidth,h=t.renderList,p=n.getModel("itemStyle").getItemStyle(),d=h.length-1;d>=0;d--){var g=h[d],y=g.node,m=g.width,S=g.text;f>v.width&&(f-=m-u,m=u,S=null);var x=new Ee({shape:{points:n2(l,0,m,c,d===h.length-1,d===0)},style:J(a.getItemStyle(),{lineJoin:"bevel"}),textContent:new ut({style:Ct(i,{text:S})}),textConfig:{position:"inside"},z2:Sn*1e4,onclick:Q(s,y)});x.disableLabelAnimation=!0,x.getTextContent().ensureState("emphasis").style=Ct(o,{text:S}),x.ensureState("emphasis").style=p,Nt(x,n.get("focus"),n.get("blurScope"),n.get("disabled")),this.group.add(x),i2(x,e,y),l+=m+Ud}},r.prototype.remove=function(){this.group.removeAll()},r}();function n2(r,e,t,a,n,i){var o=[[n?r:r-uu,e],[r+t,e],[r+t,e+a],[n?r:r-uu,e+a]];return!i&&o.splice(2,0,[r+t+uu,e+a/2]),!n&&o.push([r,e+a/2]),o}function i2(r,e,t){q(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:t&&t.dataIndex,name:t&&t.name},treePathInfo:t&&pl(t,e)}}const o2=a2;var s2=function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(e,t,a,n,i){return this._elExistsMap[e.id]?!1:(this._elExistsMap[e.id]=!0,this._storage.push({el:e,target:t,duration:a,delay:n,easing:i}),!0)},r.prototype.finished=function(e){return this._finishedCallback=e,this},r.prototype.start=function(){for(var e=this,t=this._storage.length,a=function(){t--,t<=0&&(e._storage.length=0,e._elExistsMap={},e._finishedCallback&&e._finishedCallback())},n=0,i=this._storage.length;n<i;n++){var o=this._storage[n];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:a,aborted:a})}return this},r}();function l2(){return new s2}var Hc=tt,Yd=ht,Zd=3,Xd="label",Kd="upperLabel",u2=Sn*10,c2=Sn*2,v2=Sn*3,Qr=wa([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),qd=function(r){var e=Qr(r);return e.stroke=e.fill=e.lineWidth=null,e},Ls=st(),f2=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._state="ready",t._storage=Zn(),t}return e.prototype.render=function(t,a,n,i){var o=a.findComponents({mainType:"series",subType:"treemap",query:i});if(!(ct(o,t)<0)){this.seriesModel=t,this.api=n,this.ecModel=a;var s=["treemapZoomToNode","treemapRootToNode"],l=Pi(i,s,t),u=i&&i.type,c=t.layoutInfo,v=!this._oldTree,f=this._storage,h=u==="treemapRootToNode"&&l&&f?{rootNodeGroup:f.nodeGroup[l.node.getRawIndex()],direction:i.direction}:null,p=this._giveContainerGroup(c),d=t.get("animation"),g=this._doRender(p,t,h);d&&!v&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(p,g,t,h):g.renderFinally(),this._resetController(n),this._renderBreadcrumb(t,n,l)}},e.prototype._giveContainerGroup=function(t){var a=this._containerGroup;return a||(a=this._containerGroup=new Hc,this._initEvents(a),this.group.add(a)),a.x=t.x,a.y=t.y,a},e.prototype._doRender=function(t,a,n){var i=a.getData().tree,o=this._oldTree,s=Zn(),l=Zn(),u=this._storage,c=[];function v(g,y,m,S){return h2(a,l,u,n,s,c,g,y,m,S)}h(i.root?[i.root]:[],o&&o.root?[o.root]:[],t,i===o||!o,0);var f=p(u);return this._oldTree=i,this._storage=l,{lastsForAnimation:s,willDeleteEls:f,renderFinally:d};function h(g,y,m,S,x){S?(y=g,w(g,function(A,T){!A.isRemoved()&&_(T,T)})):new hr(y,g,b,b).add(_).update(_).remove(Q(_,null)).execute();function b(A){return A.getId()}function _(A,T){var C=A!=null?g[A]:null,M=T!=null?y[T]:null,D=v(C,M,m,x);D&&h(C&&C.viewChildren||[],M&&M.viewChildren||[],D,S,x+1)}}function p(g){var y=Zn();return g&&w(g,function(m,S){var x=y[S];w(m,function(b){b&&(x.push(b),Ls(b).willDelete=!0)})}),y}function d(){w(f,function(g){w(g,function(y){y.parent&&y.parent.remove(y)})}),w(c,function(g){g.invisible=!0,g.dirty()})}},e.prototype._doAnimation=function(t,a,n,i){var o=n.get("animationDurationUpdate"),s=n.get("animationEasing"),l=(X(o)?0:o)||0,u=(X(s)?null:s)||"cubicOut",c=l2();w(a.willDeleteEls,function(v,f){w(v,function(h,p){if(!h.invisible){var d=h.parent,g,y=Ls(d);if(i&&i.direction==="drillDown")g=d===i.rootNodeGroup?{shape:{x:0,y:0,width:y.nodeWidth,height:y.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var m=0,S=0;y.willDelete||(m=y.nodeWidth/2,S=y.nodeHeight/2),g=f==="nodeGroup"?{x:m,y:S,style:{opacity:0}}:{shape:{x:m,y:S,width:0,height:0},style:{opacity:0}}}g&&c.add(h,g,l,0,u)}})}),w(this._storage,function(v,f){w(v,function(h,p){var d=a.lastsForAnimation[f][p],g={};d&&(h instanceof tt?d.oldX!=null&&(g.x=h.x,g.y=h.y,h.x=d.oldX,h.y=d.oldY):(d.oldShape&&(g.shape=B({},h.shape),h.setShape(d.oldShape)),d.fadein?(h.setStyle("opacity",0),g.style={opacity:1}):h.style.opacity!==1&&(g.style={opacity:1})),c.add(h,g,l,0,u))})},this),this._state="animating",c.finished(W(function(){this._state="ready",a.renderFinally()},this)).start()},e.prototype._resetController=function(t){var a=this._controller;a||(a=this._controller=new no(t.getZr()),a.enable(this.seriesModel.get("roam")),a.on("pan",W(this._onPan,this)),a.on("zoom",W(this._onZoom,this)));var n=new wt(0,0,t.getWidth(),t.getHeight());a.setPointerChecker(function(i,o,s){return n.contain(o,s)})},e.prototype._clearController=function(){var t=this._controller;t&&(t.dispose(),t=null)},e.prototype._onPan=function(t){if(this._state!=="animating"&&(Math.abs(t.dx)>Zd||Math.abs(t.dy)>Zd)){var a=this.seriesModel.getData().tree.root;if(!a)return;var n=a.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+t.dx,y:n.y+t.dy,width:n.width,height:n.height}})}},e.prototype._onZoom=function(t){var a=t.originX,n=t.originY;if(this._state!=="animating"){var i=this.seriesModel.getData().tree.root;if(!i)return;var o=i.getLayout();if(!o)return;var s=new wt(o.x,o.y,o.width,o.height),l=this.seriesModel.layoutInfo;a-=l.x,n-=l.y;var u=yn();xa(u,u,[-a,-n]),Vb(u,u,[t.scale,t.scale]),xa(u,u,[a,n]),s.applyTransform(u),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:s.x,y:s.y,width:s.width,height:s.height}})}},e.prototype._initEvents=function(t){var a=this;t.on("click",function(n){if(a._state==="ready"){var i=a.seriesModel.get("nodeClick",!0);if(i){var o=a.findTarget(n.offsetX,n.offsetY);if(o){var s=o.node;if(s.getLayout().isLeafRoot)a._rootToNode(o);else if(i==="zoomToNode")a._zoomToNode(o);else if(i==="link"){var l=s.hostTree.data.getItemModel(s.dataIndex),u=l.get("link",!0),c=l.get("target",!0)||"blank";u&&ms(u,c)}}}}},this)},e.prototype._renderBreadcrumb=function(t,a,n){var i=this;n||(n=t.get("leafDepth",!0)!=null?{node:t.getViewRoot()}:this.findTarget(a.getWidth()/2,a.getHeight()/2),n||(n={node:t.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new o2(this.group))).render(t,a,n.node,function(o){i._state!=="animating"&&(gf(t.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=Zn(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,a){var n,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},function(o){var s=this._storage.background[o.getRawIndex()];if(s){var l=s.transformCoordToLocal(t,a),u=s.shape;if(u.x<=l[0]&&l[0]<=u.x+u.width&&u.y<=l[1]&&l[1]<=u.y+u.height)n={node:o,offsetX:l[0],offsetY:l[1]};else return!1}},this),n},e.type="treemap",e}(Mt);function Zn(){return{nodeGroup:[],background:[],content:[]}}function h2(r,e,t,a,n,i,o,s,l,u){if(!o)return;var c=o.getLayout(),v=r.getData(),f=o.getModel();if(v.setItemGraphicEl(o.dataIndex,null),!c||!c.isInView)return;var h=c.width,p=c.height,d=c.borderWidth,g=c.invisible,y=o.getRawIndex(),m=s&&s.getRawIndex(),S=o.viewChildren,x=c.upperHeight,b=S&&S.length,_=f.getModel("itemStyle"),A=f.getModel(["emphasis","itemStyle"]),T=f.getModel(["blur","itemStyle"]),C=f.getModel(["select","itemStyle"]),M=_.get("borderRadius")||0,D=nt("nodeGroup",Hc);if(!D)return;if(l.add(D),D.x=c.x||0,D.y=c.y||0,D.markRedraw(),Ls(D).nodeWidth=h,Ls(D).nodeHeight=p,c.isAboveViewRoot)return D;var I=nt("background",Yd,u,c2);I&&z(D,I,b&&c.upperLabelHeight);var L=f.getModel("emphasis"),P=L.get("focus"),E=L.get("blurScope"),k=L.get("disabled"),V=P==="ancestor"?o.getAncestorsIndices():P==="descendant"?o.getDescendantIndices():P;if(b)_i(D)&&la(D,!1),I&&(la(I,!k),v.setItemGraphicEl(o.dataIndex,I),pc(I,V,E));else{var N=nt("content",Yd,u,v2);N&&H(D,N),I.disableMorphing=!0,I&&_i(I)&&la(I,!1),la(D,!k),v.setItemGraphicEl(o.dataIndex,D),pc(D,V,E)}return D;function z(vt,at,At){var xt=q(at);if(xt.dataIndex=o.dataIndex,xt.seriesIndex=r.seriesIndex,at.setShape({x:0,y:0,width:h,height:p,r:M}),g)Y(at);else{at.invisible=!1;var Rt=o.getVisual("style"),Zt=Rt.stroke,ne=qd(_);ne.fill=Zt;var Pt=Qr(A);Pt.fill=A.get("borderColor");var $t=Qr(T);$t.fill=T.get("borderColor");var Xt=Qr(C);if(Xt.fill=C.get("borderColor"),At){var Se=h-2*d;et(at,Zt,Rt.opacity,{x:d,y:0,width:Se,height:x})}else at.removeTextContent();at.setStyle(ne),at.ensureState("emphasis").style=Pt,at.ensureState("blur").style=$t,at.ensureState("select").style=Xt,Aa(at)}vt.add(at)}function H(vt,at){var At=q(at);At.dataIndex=o.dataIndex,At.seriesIndex=r.seriesIndex;var xt=Math.max(h-2*d,0),Rt=Math.max(p-2*d,0);if(at.culling=!0,at.setShape({x:d,y:d,width:xt,height:Rt,r:M}),g)Y(at);else{at.invisible=!1;var Zt=o.getVisual("style"),ne=Zt.fill,Pt=qd(_);Pt.fill=ne,Pt.decal=Zt.decal;var $t=Qr(A),Xt=Qr(T),Se=Qr(C);et(at,ne,Zt.opacity,null),at.setStyle(Pt),at.ensureState("emphasis").style=$t,at.ensureState("blur").style=Xt,at.ensureState("select").style=Se,Aa(at)}vt.add(at)}function Y(vt){!vt.invisible&&i.push(vt)}function et(vt,at,At,xt){var Rt=f.getModel(xt?Kd:Xd),Zt=Ut(f.get("name"),null),ne=Rt.getShallow("show");ae(vt,Kt(f,xt?Kd:Xd),{defaultText:ne?Zt:null,inheritColor:at,defaultOpacity:At,labelFetcher:r,labelDataIndex:o.dataIndex});var Pt=vt.getTextContent();if(Pt){var $t=Pt.style,Xt=km($t.padding||0);xt&&(vt.setTextConfig({layoutRect:xt}),Pt.disableLabelLayout=!0),Pt.beforeUpdate=function(){var so=Math.max((xt?xt.width:vt.shape.width)-Xt[1]-Xt[3],0),ar=Math.max((xt?xt.height:vt.shape.height)-Xt[0]-Xt[2],0);($t.width!==so||$t.height!==ar)&&Pt.setStyle({width:so,height:ar})},$t.truncateMinChar=2,$t.lineOverflow="truncate",rt($t,xt,c);var Se=Pt.getState("emphasis");rt(Se?Se.style:null,xt,c)}}function rt(vt,at,At){var xt=vt?vt.text:null;if(!at&&At.isLeafRoot&&xt!=null){var Rt=r.get("drillDownIcon",!0);vt.text=Rt?Rt+" "+xt:xt}}function nt(vt,at,At,xt){var Rt=m!=null&&t[vt][m],Zt=n[vt];return Rt?(t[vt][m]=null,pt(Zt,Rt)):g||(Rt=new at,Rt instanceof Sa&&(Rt.z2=p2(At,xt)),yt(Zt,Rt)),e[vt][y]=Rt}function pt(vt,at){var At=vt[y]={};at instanceof Hc?(At.oldX=at.x,At.oldY=at.y):At.oldShape=B({},at.shape)}function yt(vt,at){var At=vt[y]={},xt=o.parentNode,Rt=at instanceof tt;if(xt&&(!a||a.direction==="drillDown")){var Zt=0,ne=0,Pt=n.background[xt.getRawIndex()];!a&&Pt&&Pt.oldShape&&(Zt=Pt.oldShape.width,ne=Pt.oldShape.height),Rt?(At.oldX=0,At.oldY=ne):At.oldShape={x:Zt,y:ne,width:0,height:0}}At.fadein=!Rt}}function p2(r,e){return r*u2+e}const d2=f2;var Ei=w,g2=j,Ps=-1,yf=function(){function r(e){var t=e.mappingMethod,a=e.type,n=this.option=K(e);this.type=a,this.mappingMethod=t,this._normalizeData=S2[t];var i=r.visualHandlers[a];this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[t],t==="piecewise"?(cu(n),y2(n)):t==="category"?n.categories?m2(n):cu(n,!0):(ye(t!=="linear"||n.dataExtent),cu(n))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return W(this._normalizeData,this)},r.listVisualTypes=function(){return Wt(r.visualHandlers)},r.isValidType=function(e){return r.visualHandlers.hasOwnProperty(e)},r.eachVisual=function(e,t,a){j(e)?w(e,t,a):t.call(a,e)},r.mapVisual=function(e,t,a){var n,i=O(e)?[]:j(e)?{}:(n=!0,null);return r.eachVisual(e,function(o,s){var l=t.call(a,o,s);n?i=l:i[s]=l}),i},r.retrieveVisuals=function(e){var t={},a;return e&&Ei(r.visualHandlers,function(n,i){e.hasOwnProperty(i)&&(t[i]=e[i],a=!0)}),a?t:null},r.prepareVisualTypes=function(e){if(O(e))e=e.slice();else if(g2(e)){var t=[];Ei(e,function(a,n){t.push(n)}),e=t}else return[];return e.sort(function(a,n){return n==="color"&&a!=="color"&&a.indexOf("color")===0?1:-1}),e},r.dependsOn=function(e,t){return t==="color"?!!(e&&e.indexOf(t)===0):e===t},r.findPieceIndex=function(e,t,a){for(var n,i=1/0,o=0,s=t.length;o<s;o++){var l=t[o].value;if(l!=null){if(l===e||$(l)&&l===e+"")return o;a&&f(l,o)}}for(var o=0,s=t.length;o<s;o++){var u=t[o],c=u.interval,v=u.close;if(c){if(c[0]===-1/0){if(Eo(v[1],e,c[1]))return o}else if(c[1]===1/0){if(Eo(v[0],c[0],e))return o}else if(Eo(v[0],c[0],e)&&Eo(v[1],e,c[1]))return o;a&&f(c[0],o),a&&f(c[1],o)}}if(a)return e===1/0?t.length-1:e===-1/0?0:n;function f(h,p){var d=Math.abs(h-e);d<i&&(i=d,n=p)}},r.visualHandlers={color:{applyVisual:Xn("color"),getColorMapper:function(){var e=this.option;return W(e.mappingMethod==="category"?function(t,a){return!a&&(t=this._normalizeData(t)),ni.call(this,t)}:function(t,a,n){var i=!!n;return!a&&(t=this._normalizeData(t)),n=bl(t,e.parsedVisual,n),i?n:Yo(n,"rgba")},this)},_normalizedToVisual:{linear:function(e){return Yo(bl(e,this.option.parsedVisual),"rgba")},category:ni,piecewise:function(e,t){var a=$c.call(this,t);return a==null&&(a=Yo(bl(e,this.option.parsedVisual),"rgba")),a},fixed:ta}},colorHue:Po(function(e,t){return si(e,t)}),colorSaturation:Po(function(e,t){return si(e,null,t)}),colorLightness:Po(function(e,t){return si(e,null,null,t)}),colorAlpha:Po(function(e,t){return vs(e,t)}),decal:{applyVisual:Xn("decal"),_normalizedToVisual:{linear:null,category:ni,piecewise:null,fixed:null}},opacity:{applyVisual:Xn("opacity"),_normalizedToVisual:Wc([0,1])},liftZ:{applyVisual:Xn("liftZ"),_normalizedToVisual:{linear:ta,category:ta,piecewise:ta,fixed:ta}},symbol:{applyVisual:function(e,t,a){var n=this.mapValueToVisual(e);a("symbol",n)},_normalizedToVisual:{linear:jd,category:ni,piecewise:function(e,t){var a=$c.call(this,t);return a==null&&(a=jd.call(this,e)),a},fixed:ta}},symbolSize:{applyVisual:Xn("symbolSize"),_normalizedToVisual:Wc([0,1])}},r}();function y2(r){var e=r.pieceList;r.hasSpecialVisual=!1,w(e,function(t,a){t.originIndex=a,t.visual!=null&&(r.hasSpecialVisual=!0)})}function m2(r){var e=r.categories,t=r.categoryMap={},a=r.visual;if(Ei(e,function(o,s){t[o]=s}),!O(a)){var n=[];j(a)?Ei(a,function(o,s){var l=t[s];n[l??Ps]=o}):n[Ps]=a,a=y_(r,n)}for(var i=e.length-1;i>=0;i--)a[i]==null&&(delete t[e[i]],e.pop())}function cu(r,e){var t=r.visual,a=[];j(t)?Ei(t,function(i){a.push(i)}):t!=null&&a.push(t);var n={color:1,symbol:1};!e&&a.length===1&&!n.hasOwnProperty(r.type)&&(a[1]=a[0]),y_(r,a)}function Po(r){return{applyVisual:function(e,t,a){var n=this.mapValueToVisual(e);a("color",r(t("color"),n))},_normalizedToVisual:Wc([0,1])}}function jd(r){var e=this.option.visual;return e[Math.round(mt(r,[0,1],[0,e.length-1],!0))]||{}}function Xn(r){return function(e,t,a){a(r,this.mapValueToVisual(e))}}function ni(r){var e=this.option.visual;return e[this.option.loop&&r!==Ps?r%e.length:r]}function ta(){return this.option.visual[0]}function Wc(r){return{linear:function(e){return mt(e,r,this.option.visual,!0)},category:ni,piecewise:function(e,t){var a=$c.call(this,t);return a==null&&(a=mt(e,r,this.option.visual,!0)),a},fixed:ta}}function $c(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var a=yf.findPieceIndex(r,t),n=t[a];if(n&&n.visual)return n.visual[this.type]}}function y_(r,e){return r.visual=e,r.type==="color"&&(r.parsedVisual=G(e,function(t){var a=zm(t);return a||[0,0,0,1]})),e}var S2={linear:function(r){return mt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=yf.findPieceIndex(r,e,!0);if(t!=null)return mt(t,[0,e.length-1],[0,1],!0)},category:function(r){var e=this.option.categories?this.option.categoryMap[r]:r;return e??Ps},fixed:he};function Eo(r,e,t){return r?e<=t:e<t}const ee=yf;var x2="itemStyle",m_=st();const _2={seriesType:"treemap",reset:function(r){var e=r.getData().tree,t=e.root;t.isRemoved()||S_(t,{},r.getViewRoot().getAncestors(),r)}};function S_(r,e,t,a){var n=r.getModel(),i=r.getLayout(),o=r.hostTree.data;if(!(!i||i.invisible||!i.isInView)){var s=n.getModel(x2),l=b2(s,e,a),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),c=s.get("borderColor"),v=s.get("borderColorSaturation"),f;v!=null&&(f=Jd(l),c=w2(v,f)),u.stroke=c;var h=r.viewChildren;if(!h||!h.length)f=Jd(l),u.fill=f;else{var p=A2(r,n,i,s,l,h);w(h,function(d,g){if(d.depth>=t.length||d===t[d.depth]){var y=T2(n,l,d,g,p,a);S_(d,y,t,a)}})}}}function b2(r,e,t){var a=B({},e),n=t.designatedVisualItemStyle;return w(["color","colorAlpha","colorSaturation"],function(i){n[i]=e[i];var o=r.get(i);n[i]=null,o!=null&&(a[i]=o)}),a}function Jd(r){var e=vu(r,"color");if(e){var t=vu(r,"colorAlpha"),a=vu(r,"colorSaturation");return a&&(e=si(e,null,null,a)),t&&(e=vs(e,t)),e}}function w2(r,e){return e!=null?si(e,null,null,r):null}function vu(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function A2(r,e,t,a,n,i){if(!(!i||!i.length)){var o=fu(e,"color")||n.color!=null&&n.color!=="none"&&(fu(e,"colorAlpha")||fu(e,"colorSaturation"));if(o){var s=e.get("visualMin"),l=e.get("visualMax"),u=t.dataExtent.slice();s!=null&&s<u[0]&&(u[0]=s),l!=null&&l>u[1]&&(u[1]=l);var c=e.get("colorMappingBy"),v={type:o.name,dataExtent:u,visual:o.range};v.type==="color"&&(c==="index"||c==="id")?(v.mappingMethod="category",v.loop=!0):v.mappingMethod="linear";var f=new ee(v);return m_(f).drColorMappingBy=c,f}}}function fu(r,e){var t=r.get(e);return O(t)&&t.length?{name:e,range:t}:null}function T2(r,e,t,a,n,i){var o=B({},e);if(n){var s=n.type,l=s==="color"&&m_(n).drColorMappingBy,u=l==="index"?a:l==="id"?i.mapIdToIndex(t.getId()):t.getValue(r.get("visualDimension"));o[s]=n.mapValueToVisual(u)}return o}var Ri=Math.max,Es=Math.min,Qd=Jt,mf=w,x_=["itemStyle","borderWidth"],C2=["itemStyle","gapWidth"],D2=["upperLabel","show"],M2=["upperLabel","height"];const I2={seriesType:"treemap",reset:function(r,e,t,a){var n=t.getWidth(),i=t.getHeight(),o=r.option,s=Yt(r.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),l=o.size||[],u=F(Qd(s.width,l[0]),n),c=F(Qd(s.height,l[1]),i),v=a&&a.type,f=["treemapZoomToNode","treemapRootToNode"],h=Pi(a,f,r),p=v==="treemapRender"||v==="treemapMove"?a.rootRect:null,d=r.getViewRoot(),g=p_(d);if(v!=="treemapMove"){var y=v==="treemapZoomToNode"?N2(r,h,d,u,c):p?[p.width,p.height]:[u,c],m=o.sort;m&&m!=="asc"&&m!=="desc"&&(m="desc");var S={squareRatio:o.squareRatio,sort:m,leafDepth:o.leafDepth};d.hostTree.clearLayouts();var x={x:0,y:0,width:y[0],height:y[1],area:y[0]*y[1]};d.setLayout(x),__(d,S,!1,0),x=d.getLayout(),mf(g,function(_,A){var T=(g[A+1]||d).getValue();_.setLayout(B({dataExtent:[T,T],borderWidth:0,upperHeight:0},x))})}var b=r.getData().tree.root;b.setLayout(O2(s,p,h),!0),r.setLayoutInfo(s),b_(b,new wt(-s.x,-s.y,n,i),g,d,0)}};function __(r,e,t,a){var n,i;if(!r.isRemoved()){var o=r.getLayout();n=o.width,i=o.height;var s=r.getModel(),l=s.get(x_),u=s.get(C2)/2,c=w_(s),v=Math.max(l,c),f=l-u,h=v-u;r.setLayout({borderWidth:l,upperHeight:v,upperLabelHeight:c},!0),n=Ri(n-2*f,0),i=Ri(i-f-h,0);var p=n*i,d=L2(r,s,p,e,t,a);if(d.length){var g={x:f,y:h,width:n,height:i},y=Es(n,i),m=1/0,S=[];S.area=0;for(var x=0,b=d.length;x<b;){var _=d[x];S.push(_),S.area+=_.getLayout().area;var A=k2(S,y,e.squareRatio);A<=m?(x++,m=A):(S.area-=S.pop().getLayout().area,tg(S,y,g,u,!1),y=Es(g.width,g.height),S.length=S.area=0,m=1/0)}if(S.length&&tg(S,y,g,u,!0),!t){var T=s.get("childrenVisibleMin");T!=null&&p<T&&(t=!0)}for(var x=0,b=d.length;x<b;x++)__(d[x],e,t,a+1)}}}function L2(r,e,t,a,n,i){var o=r.children||[],s=a.sort;s!=="asc"&&s!=="desc"&&(s=null);var l=a.leafDepth!=null&&a.leafDepth<=i;if(n&&!l)return r.viewChildren=[];o=bt(o,function(h){return!h.isRemoved()}),E2(o,s);var u=R2(e,o,s);if(u.sum===0)return r.viewChildren=[];if(u.sum=P2(e,t,u.sum,s,o),u.sum===0)return r.viewChildren=[];for(var c=0,v=o.length;c<v;c++){var f=o[c].getValue()/u.sum*t;o[c].setLayout({area:f})}return l&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function P2(r,e,t,a,n){if(!a)return t;for(var i=r.get("visibleMin"),o=n.length,s=o,l=o-1;l>=0;l--){var u=n[a==="asc"?o-l-1:l].getValue();u/t*e<i&&(s=l,t-=u)}return a==="asc"?n.splice(0,o-s):n.splice(s,o-s),t}function E2(r,e){return e&&r.sort(function(t,a){var n=e==="asc"?t.getValue()-a.getValue():a.getValue()-t.getValue();return n===0?e==="asc"?t.dataIndex-a.dataIndex:a.dataIndex-t.dataIndex:n}),r}function R2(r,e,t){for(var a=0,n=0,i=e.length;n<i;n++)a+=e[n].getValue();var o=r.get("visualDimension"),s;return!e||!e.length?s=[NaN,NaN]:o==="value"&&t?(s=[e[e.length-1].getValue(),e[0].getValue()],t==="asc"&&s.reverse()):(s=[1/0,-1/0],mf(e,function(l){var u=l.getValue(o);u<s[0]&&(s[0]=u),u>s[1]&&(s[1]=u)})),{sum:a,dataExtent:s}}function k2(r,e,t){for(var a=0,n=1/0,i=0,o=void 0,s=r.length;i<s;i++)o=r[i].getLayout().area,o&&(o<n&&(n=o),o>a&&(a=o));var l=r.area*r.area,u=e*e*t;return l?Ri(u*a/l,l/(u*n)):1/0}function tg(r,e,t,a,n){var i=e===t.width?0:1,o=1-i,s=["x","y"],l=["width","height"],u=t[s[i]],c=e?r.area/e:0;(n||c>t[l[o]])&&(c=t[l[o]]);for(var v=0,f=r.length;v<f;v++){var h=r[v],p={},d=c?h.getLayout().area/c:0,g=p[l[o]]=Ri(c-2*a,0),y=t[s[i]]+t[l[i]]-u,m=v===f-1||y<d?y:d,S=p[l[i]]=Ri(m-2*a,0);p[s[o]]=t[s[o]]+Es(a,g/2),p[s[i]]=u+Es(a,S/2),u+=m,h.setLayout(p,!0)}t[s[o]]+=c,t[l[o]]-=c}function N2(r,e,t,a,n){var i=(e||{}).node,o=[a,n];if(!i||i===t)return o;for(var s,l=a*n,u=l*r.option.zoomToNodeRatio;s=i.parentNode;){for(var c=0,v=s.children,f=0,h=v.length;f<h;f++)c+=v[f].getValue();var p=i.getValue();if(p===0)return o;u*=c/p;var d=s.getModel(),g=d.get(x_),y=Math.max(g,w_(d));u+=4*g*g+(3*g+y)*Math.pow(u,.5),u>fh&&(u=fh),i=s}u<l&&(u=l);var m=Math.pow(u/l,.5);return[a*m,n*m]}function O2(r,e,t){if(e)return{x:e.x,y:e.y};var a={x:0,y:0};if(!t)return a;var n=t.node,i=n.getLayout();if(!i)return a;for(var o=[i.width/2,i.height/2],s=n;s;){var l=s.getLayout();o[0]+=l.x,o[1]+=l.y,s=s.parentNode}return{x:r.width/2-o[0],y:r.height/2-o[1]}}function b_(r,e,t,a,n){var i=r.getLayout(),o=t[n],s=o&&o===r;if(!(o&&!s||n===t.length&&r!==a)){r.setLayout({isInView:!0,invisible:!s&&!e.intersect(i),isAboveViewRoot:s},!0);var l=new wt(e.x-i.x,e.y-i.y,e.width,e.height);mf(r.viewChildren||[],function(u){b_(u,l,t,a,n+1)})}}function w_(r){return r.get(D2)?r.get(M2):0}function V2(r){r.registerSeriesModel(e2),r.registerChartView(d2),r.registerVisual(_2),r.registerLayout(I2),JP(r)}function B2(r){var e=r.findComponents({mainType:"legend"});!e||!e.length||r.eachSeriesByType("graph",function(t){var a=t.getCategoriesData(),n=t.getGraph(),i=n.data,o=a.mapArray(a.getName);i.filterSelf(function(s){var l=i.getItemModel(s),u=l.getShallow("category");if(u!=null){gt(u)&&(u=o[u]);for(var c=0;c<e.length;c++)if(!e[c].isSelected(u))return!1}return!0})})}function z2(r){var e={};r.eachSeriesByType("graph",function(t){var a=t.getCategoriesData(),n=t.getData(),i={};a.each(function(o){var s=a.getName(o);i["ec-"+s]=o;var l=a.getItemModel(o),u=l.getModel("itemStyle").getItemStyle();u.fill||(u.fill=t.getColorFromPalette(s,e)),a.setItemVisual(o,"style",u);for(var c=["symbol","symbolSize","symbolKeepAspect"],v=0;v<c.length;v++){var f=l.getShallow(c[v],!0);f!=null&&a.setItemVisual(o,c[v],f)}}),a.count()&&n.each(function(o){var s=n.getItemModel(o),l=s.getShallow("category");if(l!=null){$(l)&&(l=i["ec-"+l]);var u=a.getItemVisual(l,"style"),c=n.ensureUniqueItemVisual(o,"style");B(c,u);for(var v=["symbol","symbolSize","symbolKeepAspect"],f=0;f<v.length;f++)n.setItemVisual(o,v[f],a.getItemVisual(l,v[f]))}})})}function Ro(r){return r instanceof Array||(r=[r,r]),r}function G2(r){r.eachSeriesByType("graph",function(e){var t=e.getGraph(),a=e.getEdgeData(),n=Ro(e.get("edgeSymbol")),i=Ro(e.get("edgeSymbolSize"));a.setVisual("fromSymbol",n&&n[0]),a.setVisual("toSymbol",n&&n[1]),a.setVisual("fromSymbolSize",i&&i[0]),a.setVisual("toSymbolSize",i&&i[1]),a.setVisual("style",e.getModel("lineStyle").getLineStyle()),a.each(function(o){var s=a.getItemModel(o),l=t.getEdgeByIndex(o),u=Ro(s.getShallow("symbol",!0)),c=Ro(s.getShallow("symbolSize",!0)),v=s.getModel("lineStyle").getLineStyle(),f=a.ensureUniqueItemVisual(o,"style");switch(B(f,v),f.stroke){case"source":{var h=l.node1.getVisual("style");f.stroke=h&&h.fill;break}case"target":{var h=l.node2.getVisual("style");f.stroke=h&&h.fill;break}}u[0]&&l.setVisual("fromSymbol",u[0]),u[1]&&l.setVisual("toSymbol",u[1]),c[0]&&l.setVisual("fromSymbolSize",c[0]),c[1]&&l.setVisual("toSymbolSize",c[1])})})}var Uc="-->",dl=function(r){return r.get("autoCurveness")||null},A_=function(r,e){var t=dl(r),a=20,n=[];if(gt(t))a=t;else if(O(t)){r.__curvenessList=t;return}e>a&&(a=e);var i=a%2?a+2:a+3;n=[];for(var o=0;o<i;o++)n.push((o%2?o+1:o)/10*(o%2?-1:1));r.__curvenessList=n},ki=function(r,e,t){var a=[r.id,r.dataIndex].join("."),n=[e.id,e.dataIndex].join(".");return[t.uid,a,n].join(Uc)},T_=function(r){var e=r.split(Uc);return[e[0],e[2],e[1]].join(Uc)},F2=function(r,e){var t=ki(r.node1,r.node2,e);return e.__edgeMap[t]},H2=function(r,e){var t=Yc(ki(r.node1,r.node2,e),e),a=Yc(ki(r.node2,r.node1,e),e);return t+a},Yc=function(r,e){var t=e.__edgeMap;return t[r]?t[r].length:0};function W2(r){dl(r)&&(r.__curvenessList=[],r.__edgeMap={},A_(r))}function $2(r,e,t,a){if(dl(t)){var n=ki(r,e,t),i=t.__edgeMap,o=i[T_(n)];i[n]&&!o?i[n].isForward=!0:o&&i[n]&&(o.isForward=!0,i[n].isForward=!1),i[n]=i[n]||[],i[n].push(a)}}function Sf(r,e,t,a){var n=dl(e),i=O(n);if(!n)return null;var o=F2(r,e);if(!o)return null;for(var s=-1,l=0;l<o.length;l++)if(o[l]===t){s=l;break}var u=H2(r,e);A_(e,u),r.lineStyle=r.lineStyle||{};var c=ki(r.node1,r.node2,e),v=e.__curvenessList,f=i||u%2?0:1;if(o.isForward)return v[f+s];var h=T_(c),p=Yc(h,e),d=v[s+p+f];return a?i?n&&n[0]===0?(p+f)%2?d:-d:((p%2?0:1)+f)%2?d:-d:(p+f)%2?d:-d:v[s+p+f]}function C_(r){var e=r.coordinateSystem;if(!(e&&e.type!=="view")){var t=r.getGraph();t.eachNode(function(a){var n=a.getModel();a.setLayout([+n.get("x"),+n.get("y")])}),xf(t,r)}}function xf(r,e){r.eachEdge(function(t,a){var n=gn(t.getModel().get(["lineStyle","curveness"]),-Sf(t,e,a,!0),0),i=Pr(t.node1.getLayout()),o=Pr(t.node2.getLayout()),s=[i,o];+n&&s.push([(i[0]+o[0])/2-(i[1]-o[1])*n,(i[1]+o[1])/2-(o[0]-i[0])*n]),t.setLayout(s)})}function U2(r,e){r.eachSeriesByType("graph",function(t){var a=t.get("layout"),n=t.coordinateSystem;if(n&&n.type!=="view"){var i=t.getData(),o=[];w(n.dimensions,function(f){o=o.concat(i.mapDimensionsAll(f))});for(var s=0;s<i.count();s++){for(var l=[],u=!1,c=0;c<o.length;c++){var v=i.get(o[c],s);isNaN(v)||(u=!0),l.push(v)}u?i.setItemLayout(s,n.dataToPoint(l)):i.setItemLayout(s,[NaN,NaN])}xf(i.graph,t)}else(!a||a==="none")&&C_(t)})}function ii(r){var e=r.coordinateSystem;if(e.type!=="view")return 1;var t=r.option.nodeScaleRatio,a=e.scaleX,n=e.getZoom(),i=(n-1)*t+1;return i/a}function oi(r){var e=r.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),+e}var eg=Math.PI,hu=[];function _f(r,e,t,a){var n=r.coordinateSystem;if(!(n&&n.type!=="view")){var i=n.getBoundingRect(),o=r.getData(),s=o.graph,l=i.width/2+i.x,u=i.height/2+i.y,c=Math.min(i.width,i.height)/2,v=o.count();if(o.setLayout({cx:l,cy:u}),!!v){if(t){var f=n.pointToData(a),h=f[0],p=f[1],d=[h-l,p-u];Hi(d,d),Bb(d,d,c),t.setLayout([l+d[0],u+d[1]],!0);var g=r.get(["circular","rotateLabel"]);D_(t,g,l,u)}Y2[e](r,s,o,c,l,u,v),s.eachEdge(function(y,m){var S=gn(y.getModel().get(["lineStyle","curveness"]),Sf(y,r,m),0),x=Pr(y.node1.getLayout()),b=Pr(y.node2.getLayout()),_,A=(x[0]+b[0])/2,T=(x[1]+b[1])/2;+S&&(S*=3,_=[l*S+A*(1-S),u*S+T*(1-S)]),y.setLayout([x,b,_])})}}}var Y2={value:function(r,e,t,a,n,i,o){var s=0,l=t.getSum("value"),u=Math.PI*2/(l||o);e.eachNode(function(c){var v=c.getValue("value"),f=u*(l?v:1)/2;s+=f,c.setLayout([a*Math.cos(s)+n,a*Math.sin(s)+i]),s+=f})},symbolSize:function(r,e,t,a,n,i,o){var s=0;hu.length=o;var l=ii(r);e.eachNode(function(v){var f=oi(v);isNaN(f)&&(f=2),f<0&&(f=0),f*=l;var h=Math.asin(f/2/a);isNaN(h)&&(h=eg/2),hu[v.dataIndex]=h,s+=h*2});var u=(2*eg-s)/o/2,c=0;e.eachNode(function(v){var f=u+hu[v.dataIndex];c+=f,(!v.getLayout()||!v.getLayout().fixed)&&v.setLayout([a*Math.cos(c)+n,a*Math.sin(c)+i]),c+=f})}};function D_(r,e,t,a){var n=r.getGraphicEl();if(n){var i=r.getModel(),o=i.get(["label","rotate"])||0,s=n.getSymbolPath();if(e){var l=r.getLayout(),u=Math.atan2(l[1]-a,l[0]-t);u<0&&(u=Math.PI*2+u);var c=l[0]<t;c&&(u=u-Math.PI);var v=c?"left":"right";s.setTextConfig({rotation:-u,position:v,origin:"center"});var f=s.ensureState("emphasis");B(f.textConfig||(f.textConfig={}),{position:v})}else s.setTextConfig({rotation:o*=Math.PI/180})}}function Z2(r){r.eachSeriesByType("graph",function(e){e.get("layout")==="circular"&&_f(e,"symbolSize")})}var Fa=lc;function X2(r,e,t){for(var a=r,n=e,i=t.rect,o=i.width,s=i.height,l=[i.x+o/2,i.y+s/2],u=t.gravity==null?.1:t.gravity,c=0;c<a.length;c++){var v=a[c];v.p||(v.p=zb(o*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),v.pp=Pr(v.p),v.edges=null}var f=t.friction==null?.6:t.friction,h=f,p,d;return{warmUp:function(){h=f*.8},setFixed:function(g){a[g].fixed=!0},setUnfixed:function(g){a[g].fixed=!1},beforeStep:function(g){p=g},afterStep:function(g){d=g},step:function(g){p&&p(a,n);for(var y=[],m=a.length,S=0;S<n.length;S++){var x=n[S];if(!x.ignoreForceLayout){var b=x.n1,_=x.n2;ja(y,_.p,b.p);var A=lh(y)-x.d,T=_.w/(b.w+_.w);isNaN(T)&&(T=0),Hi(y,y),!b.fixed&&Fa(b.p,b.p,y,T*A*h),!_.fixed&&Fa(_.p,_.p,y,-(1-T)*A*h)}}for(var S=0;S<m;S++){var C=a[S];C.fixed||(ja(y,l,C.p),Fa(C.p,C.p,y,u*h))}for(var S=0;S<m;S++)for(var b=a[S],M=S+1;M<m;M++){var _=a[M];ja(y,_.p,b.p);var A=lh(y);A===0&&(Gb(y,Math.random()-.5,Math.random()-.5),A=1);var D=(b.rep+_.rep)/A/A;!b.fixed&&Fa(b.pp,b.pp,y,D),!_.fixed&&Fa(_.pp,_.pp,y,-D)}for(var I=[],S=0;S<m;S++){var C=a[S];C.fixed||(ja(I,C.p,C.pp),Fa(C.p,C.p,I,h),ce(C.pp,C.p))}h=h*.992;var L=h<.01;d&&d(a,n,L),g&&g(L)}}}function K2(r){r.eachSeriesByType("graph",function(e){var t=e.coordinateSystem;if(!(t&&t.type!=="view"))if(e.get("layout")==="force"){var a=e.preservedPoints||{},n=e.getGraph(),i=n.data,o=n.edgeData,s=e.getModel("force"),l=s.get("initLayout");e.preservedPoints?i.each(function(S){var x=i.getId(S);i.setItemLayout(S,a[x]||[NaN,NaN])}):!l||l==="none"?C_(e):l==="circular"&&_f(e,"value");var u=i.getDataExtent("value"),c=o.getDataExtent("value"),v=s.get("repulsion"),f=s.get("edgeLength"),h=O(v)?v:[v,v],p=O(f)?f:[f,f];p=[p[1],p[0]];var d=i.mapArray("value",function(S,x){var b=i.getItemLayout(x),_=mt(S,u,h);return isNaN(_)&&(_=(h[0]+h[1])/2),{w:_,rep:_,fixed:i.getItemModel(x).get("fixed"),p:!b||isNaN(b[0])||isNaN(b[1])?null:b}}),g=o.mapArray("value",function(S,x){var b=n.getEdgeByIndex(x),_=mt(S,c,p);isNaN(_)&&(_=(p[0]+p[1])/2);var A=b.getModel(),T=gn(b.getModel().get(["lineStyle","curveness"]),-Sf(b,e,x,!0),0);return{n1:d[b.node1.dataIndex],n2:d[b.node2.dataIndex],d:_,curveness:T,ignoreForceLayout:A.get("ignoreForceLayout")}}),y=t.getBoundingRect(),m=X2(d,g,{rect:y,gravity:s.get("gravity"),friction:s.get("friction")});m.beforeStep(function(S,x){for(var b=0,_=S.length;b<_;b++)S[b].fixed&&ce(S[b].p,n.getNodeByIndex(b).getLayout())}),m.afterStep(function(S,x,b){for(var _=0,A=S.length;_<A;_++)S[_].fixed||n.getNodeByIndex(_).setLayout(S[_].p),a[i.getId(_)]=S[_].p;for(var _=0,A=x.length;_<A;_++){var T=x[_],C=n.getEdgeByIndex(_),M=T.n1.p,D=T.n2.p,I=C.getLayout();I=I?I.slice():[],I[0]=I[0]||[],I[1]=I[1]||[],ce(I[0],M),ce(I[1],D),+T.curveness&&(I[2]=[(M[0]+D[0])/2-(M[1]-D[1])*T.curveness,(M[1]+D[1])/2-(D[0]-M[0])*T.curveness]),C.setLayout(I)}}),e.forceLayout=m,e.preservedPoints=a,m.step()}else e.forceLayout=null})}function q2(r,e,t){var a=B(r.getBoxLayoutParams(),{aspect:t});return Yt(a,{width:e.getWidth(),height:e.getHeight()})}function j2(r,e){var t=[];return r.eachSeriesByType("graph",function(a){var n=a.get("coordinateSystem");if(!n||n==="view"){var i=a.getData(),o=i.mapArray(function(g){var y=i.getItemModel(g);return[+y.get("x"),+y.get("y")]}),s=[],l=[];Bm(o,s,l),l[0]-s[0]===0&&(l[0]+=1,s[0]-=1),l[1]-s[1]===0&&(l[1]+=1,s[1]-=1);var u=(l[0]-s[0])/(l[1]-s[1]),c=q2(a,e,u);isNaN(u)&&(s=[c.x,c.y],l=[c.x+c.width,c.y+c.height]);var v=l[0]-s[0],f=l[1]-s[1],h=c.width,p=c.height,d=a.coordinateSystem=new io;d.zoomLimit=a.get("scaleLimit"),d.setBoundingRect(s[0],s[1],v,f),d.setViewRect(c.x,c.y,h,p),d.setCenter(a.get("center"),e),d.setZoom(a.get("zoom")),t.push(d)}}),t}var rg=te.prototype,pu=Ws.prototype,M_=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r}();(function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(M_);function du(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var J2=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="ec-line",a}return e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new M_},e.prototype.buildPath=function(t,a){du(a)?rg.buildPath.call(this,t,a):pu.buildPath.call(this,t,a)},e.prototype.pointAt=function(t){return du(this.shape)?rg.pointAt.call(this,t):pu.pointAt.call(this,t)},e.prototype.tangentAt=function(t){var a=this.shape,n=du(a)?[a.x2-a.x1,a.y2-a.y1]:pu.tangentAt.call(this,t);return Hi(n,n)},e}(It);const Q2=J2;var gu=["fromSymbol","toSymbol"];function ag(r){return"_"+r+"Type"}function ng(r,e,t){var a=e.getItemVisual(t,r);if(!a||a==="none")return a;var n=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=Ln(n),u=Ia(o||0,l);return a+l+u+(i||"")+(s||"")}function ig(r,e,t){var a=e.getItemVisual(t,r);if(!(!a||a==="none")){var n=e.getItemVisual(t,r+"Size"),i=e.getItemVisual(t,r+"Rotate"),o=e.getItemVisual(t,r+"Offset"),s=e.getItemVisual(t,r+"KeepAspect"),l=Ln(n),u=Ia(o||0,l),c=Ht(a,-l[0]/2+u[0],-l[1]/2+u[1],l[0],l[1],null,s);return c.__specifiedRotation=i==null||isNaN(i)?void 0:+i*Math.PI/180||0,c.name=r,c}}function tE(r){var e=new Q2({name:"line",subPixelOptimize:!0});return Zc(e.shape,r),e}function Zc(r,e){r.x1=e[0][0],r.y1=e[0][1],r.x2=e[1][0],r.y2=e[1][1],r.percent=1;var t=e[2];t?(r.cpx1=t[0],r.cpy1=t[1]):(r.cpx1=NaN,r.cpy1=NaN)}var eE=function(r){R(e,r);function e(t,a,n){var i=r.call(this)||this;return i._createLine(t,a,n),i}return e.prototype._createLine=function(t,a,n){var i=t.hostModel,o=t.getItemLayout(a),s=tE(o);s.shape.percent=0,Lt(s,{shape:{percent:1}},i,a),this.add(s),w(gu,function(l){var u=ig(l,t,a);this.add(u),this[ag(l)]=ng(l,t,a)},this),this._updateCommonStl(t,a,n)},e.prototype.updateData=function(t,a,n){var i=t.hostModel,o=this.childOfName("line"),s=t.getItemLayout(a),l={shape:{}};Zc(l.shape,s),ft(o,l,i,a),w(gu,function(u){var c=ng(u,t,a),v=ag(u);if(this[v]!==c){this.remove(this.childOfName(u));var f=ig(u,t,a);this.add(f)}this[v]=c},this),this._updateCommonStl(t,a,n)},e.prototype.getLinePath=function(){return this.childAt(0)},e.prototype._updateCommonStl=function(t,a,n){var i=t.hostModel,o=this.childOfName("line"),s=n&&n.emphasisLineStyle,l=n&&n.blurLineStyle,u=n&&n.selectLineStyle,c=n&&n.labelStatesModels,v=n&&n.emphasisDisabled,f=n&&n.focus,h=n&&n.blurScope;if(!n||t.hasItemOption){var p=t.getItemModel(a),d=p.getModel("emphasis");s=d.getModel("lineStyle").getLineStyle(),l=p.getModel(["blur","lineStyle"]).getLineStyle(),u=p.getModel(["select","lineStyle"]).getLineStyle(),v=d.get("disabled"),f=d.get("focus"),h=d.get("blurScope"),c=Kt(p)}var g=t.getItemVisual(a,"style"),y=g.stroke;o.useStyle(g),o.style.fill=null,o.style.strokeNoScale=!0,o.ensureState("emphasis").style=s,o.ensureState("blur").style=l,o.ensureState("select").style=u,w(gu,function(_){var A=this.childOfName(_);if(A){A.setColor(y),A.style.opacity=g.opacity;for(var T=0;T<pe.length;T++){var C=pe[T],M=o.getState(C);if(M){var D=M.style||{},I=A.ensureState(C),L=I.style||(I.style={});D.stroke!=null&&(L[A.__isEmptyBrush?"stroke":"fill"]=D.stroke),D.opacity!=null&&(L.opacity=D.opacity)}}A.markRedraw()}},this);var m=i.getRawValue(a);ae(this,c,{labelDataIndex:a,labelFetcher:{getFormattedLabel:function(_,A){return i.getFormattedLabel(_,A,t.dataType)}},inheritColor:y||"#000",defaultOpacity:g.opacity,defaultText:(m==null?t.getName(a):isFinite(m)?Vt(m):m)+""});var S=this.getTextContent();if(S){var x=c.normal;S.__align=S.style.align,S.__verticalAlign=S.style.verticalAlign,S.__position=x.get("position")||"middle";var b=x.get("distance");O(b)||(b=[b,b]),S.__labelDistance=b}this.setTextConfig({position:null,local:!0,inside:!1}),Nt(this,f,h,v)},e.prototype.highlight=function(){vr(this)},e.prototype.downplay=function(){fr(this)},e.prototype.updateLayout=function(t,a){this.setLinePoints(t.getItemLayout(a))},e.prototype.setLinePoints=function(t){var a=this.childOfName("line");Zc(a.shape,t),a.dirty()},e.prototype.beforeUpdate=function(){var t=this,a=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),i=t.getTextContent();if(!a&&!n&&(!i||i.ignore))return;for(var o=1,s=this.parent;s;)s.scaleX&&(o/=s.scaleX),s=s.parent;var l=t.childOfName("line");if(!this.__dirty&&!l.__dirty)return;var u=l.shape.percent,c=l.pointAt(0),v=l.pointAt(u),f=ja([],v,c);Hi(f,f);function h(M,D){var I=M.__specifiedRotation;if(I==null){var L=l.tangentAt(D);M.attr("rotation",(D===1?-1:1)*Math.PI/2-Math.atan2(L[1],L[0]))}else M.attr("rotation",I)}if(a&&(a.setPosition(c),h(a,0),a.scaleX=a.scaleY=o*u,a.markRedraw()),n&&(n.setPosition(v),h(n,1),n.scaleX=n.scaleY=o*u,n.markRedraw()),i&&!i.ignore){i.x=i.y=0,i.originX=i.originY=0;var p=void 0,d=void 0,g=i.__labelDistance,y=g[0]*o,m=g[1]*o,S=u/2,x=l.tangentAt(S),b=[x[1],-x[0]],_=l.pointAt(S);b[1]>0&&(b[0]=-b[0],b[1]=-b[1]);var A=x[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var T=-Math.atan2(x[1],x[0]);v[0]<c[0]&&(T=Math.PI+T),i.rotation=T}var C=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":C=-m,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":C=m,d="top";break;default:C=0,d="middle"}switch(i.__position){case"end":i.x=f[0]*y+v[0],i.y=f[1]*m+v[1],p=f[0]>.8?"left":f[0]<-.8?"right":"center",d=f[1]>.8?"top":f[1]<-.8?"bottom":"middle";break;case"start":i.x=-f[0]*y+c[0],i.y=-f[1]*m+c[1],p=f[0]>.8?"right":f[0]<-.8?"left":"center",d=f[1]>.8?"bottom":f[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=y*A+c[0],i.y=c[1]+C,p=x[0]<0?"right":"left",i.originX=-y*A,i.originY=-C;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=_[0],i.y=_[1]+C,p="center",i.originY=-C;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-y*A+v[0],i.y=v[1]+C,p=x[0]>=0?"right":"left",i.originX=y*A,i.originY=-C;break}i.scaleX=i.scaleY=o,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||p})}},e}(tt);const bf=eE;var rE=function(){function r(e){this.group=new tt,this._LineCtor=e||bf}return r.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var a=this,n=a.group,i=a._lineData;a._lineData=e,i||n.removeAll();var o=og(e);e.diff(i).add(function(s){t._doAdd(e,s,o)}).update(function(s,l){t._doUpdate(i,e,l,s,o)}).remove(function(s){n.remove(i.getItemGraphicEl(s))}).execute()},r.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,a){t.updateLayout(e,a)},this)},r.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=og(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function a(s){!s.isGroup&&!aE(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var n=e.start;n<e.end;n++){var i=t.getItemLayout(n);if(yu(i)){var o=new this._LineCtor(t,n,this._seriesScope);o.traverse(a),this.group.add(o),t.setItemGraphicEl(n,o),this._progressiveEls.push(o)}}},r.prototype.remove=function(){this.group.removeAll()},r.prototype.eachRendered=function(e){Wr(this._progressiveEls||this.group,e)},r.prototype._doAdd=function(e,t,a){var n=e.getItemLayout(t);if(yu(n)){var i=new this._LineCtor(e,t,a);e.setItemGraphicEl(t,i),this.group.add(i)}},r.prototype._doUpdate=function(e,t,a,n,i){var o=e.getItemGraphicEl(a);if(!yu(t.getItemLayout(n))){this.group.remove(o);return}o?o.updateData(t,n,i):o=new this._LineCtor(t,n,i),t.setItemGraphicEl(n,o),this.group.add(o)},r}();function aE(r){return r.animators&&r.animators.length>0}function og(r){var e=r.hostModel,t=e.getModel("emphasis");return{lineStyle:e.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:e.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:e.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:t.get("disabled"),blurScope:t.get("blurScope"),focus:t.get("focus"),labelStatesModels:Kt(e)}}function sg(r){return isNaN(r[0])||isNaN(r[1])}function yu(r){return r&&!sg(r[0])&&!sg(r[1])}const wf=rE;var mu=[],Su=[],xu=[],Ha=Gm,_u=Hb,lg=Math.abs;function ug(r,e,t){for(var a=r[0],n=r[1],i=r[2],o=1/0,s,l=t*t,u=.1,c=.1;c<=.9;c+=.1){mu[0]=Ha(a[0],n[0],i[0],c),mu[1]=Ha(a[1],n[1],i[1],c);var v=lg(_u(mu,e)-l);v<o&&(o=v,s=c)}for(var f=0;f<32;f++){var h=s+u;Su[0]=Ha(a[0],n[0],i[0],s),Su[1]=Ha(a[1],n[1],i[1],s),xu[0]=Ha(a[0],n[0],i[0],h),xu[1]=Ha(a[1],n[1],i[1],h);var v=_u(Su,e)-l;if(lg(v)<.01)break;var p=_u(xu,e)-l;u/=2,v<0?p>=0?s=s+u:s=s-u:p>=0?s=s-u:s=s+u}return s}function bu(r,e){var t=[],a=Fb,n=[[],[],[]],i=[[],[]],o=[];e/=2,r.eachEdge(function(s,l){var u=s.getLayout(),c=s.getVisual("fromSymbol"),v=s.getVisual("toSymbol");u.__original||(u.__original=[Pr(u[0]),Pr(u[1])],u[2]&&u.__original.push(Pr(u[2])));var f=u.__original;if(u[2]!=null){if(ce(n[0],f[0]),ce(n[1],f[2]),ce(n[2],f[1]),c&&c!=="none"){var h=oi(s.node1),p=ug(n,f[0],h*e);a(n[0][0],n[1][0],n[2][0],p,t),n[0][0]=t[3],n[1][0]=t[4],a(n[0][1],n[1][1],n[2][1],p,t),n[0][1]=t[3],n[1][1]=t[4]}if(v&&v!=="none"){var h=oi(s.node2),p=ug(n,f[1],h*e);a(n[0][0],n[1][0],n[2][0],p,t),n[1][0]=t[1],n[2][0]=t[2],a(n[0][1],n[1][1],n[2][1],p,t),n[1][1]=t[1],n[2][1]=t[2]}ce(u[0],n[0]),ce(u[1],n[2]),ce(u[2],n[1])}else{if(ce(i[0],f[0]),ce(i[1],f[1]),ja(o,i[1],i[0]),Hi(o,o),c&&c!=="none"){var h=oi(s.node1);lc(i[0],i[0],o,h*e)}if(v&&v!=="none"){var h=oi(s.node2);lc(i[1],i[1],o,-h*e)}ce(u[0],i[0]),ce(u[1],i[1])}})}function cg(r){return r.type==="view"}var nE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){var n=new to,i=new wf,o=this.group;this._controller=new no(a.getZr()),this._controllerHost={target:o},o.add(n.group),o.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},e.prototype.render=function(t,a,n){var i=this,o=t.coordinateSystem;this._model=t;var s=this._symbolDraw,l=this._lineDraw,u=this.group;if(cg(o)){var c={x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY};this._firstRender?u.attr(c):ft(u,c,t)}bu(t.getGraph(),ii(t));var v=t.getData();s.updateData(v);var f=t.getEdgeData();l.updateData(f),this._updateNodeAndLinkScale(),this._updateController(t,a,n),clearTimeout(this._layoutTimeout);var h=t.forceLayout,p=t.get(["force","layoutAnimation"]);h&&this._startForceLayoutIteration(h,p);var d=t.get("layout");v.graph.eachNode(function(S){var x=S.dataIndex,b=S.getGraphicEl(),_=S.getModel();if(b){b.off("drag").off("dragend");var A=_.get("draggable");A&&b.on("drag",function(C){switch(d){case"force":h.warmUp(),!i._layouting&&i._startForceLayoutIteration(h,p),h.setFixed(x),v.setItemLayout(x,[b.x,b.y]);break;case"circular":v.setItemLayout(x,[b.x,b.y]),S.setLayout({fixed:!0},!0),_f(t,"symbolSize",S,[C.offsetX,C.offsetY]),i.updateLayout(t);break;case"none":default:v.setItemLayout(x,[b.x,b.y]),xf(t.getGraph(),t),i.updateLayout(t);break}}).on("dragend",function(){h&&h.setUnfixed(x)}),b.setDraggable(A,!!_.get("cursor"));var T=_.get(["emphasis","focus"]);T==="adjacency"&&(q(b).focus=S.getAdjacentDataIndices())}}),v.graph.eachEdge(function(S){var x=S.getGraphicEl(),b=S.getModel().get(["emphasis","focus"]);x&&b==="adjacency"&&(q(x).focus={edge:[S.dataIndex],node:[S.node1.dataIndex,S.node2.dataIndex]})});var g=t.get("layout")==="circular"&&t.get(["circular","rotateLabel"]),y=v.getLayout("cx"),m=v.getLayout("cy");v.graph.eachNode(function(S){D_(S,g,y,m)}),this._firstRender=!1},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._startForceLayoutIteration=function(t,a){var n=this;(function i(){t.step(function(o){n.updateLayout(n._model),(n._layouting=!o)&&(a?n._layoutTimeout=setTimeout(i,16):i())})})()},e.prototype._updateController=function(t,a,n){var i=this,o=this._controller,s=this._controllerHost,l=this.group;if(o.setPointerChecker(function(u,c,v){var f=l.getBoundingRect();return f.applyTransform(l.transform),f.contain(c,v)&&!hl(u,n,t)}),!cg(t.coordinateSystem)){o.disable();return}o.enable(t.get("roam")),s.zoomLimit=t.get("scaleLimit"),s.zoom=t.coordinateSystem.getZoom(),o.off("pan").off("zoom").on("pan",function(u){cf(s,u.dx,u.dy),n.dispatchAction({seriesId:t.id,type:"graphRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){vf(s,u.scale,u.originX,u.originY),n.dispatchAction({seriesId:t.id,type:"graphRoam",zoom:u.scale,originX:u.originX,originY:u.originY}),i._updateNodeAndLinkScale(),bu(t.getGraph(),ii(t)),i._lineDraw.updateLayout(),n.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,a=t.getData(),n=ii(t);a.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(n)})},e.prototype.updateLayout=function(t){bu(t.getGraph(),ii(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},e.type="graph",e}(Mt);const iE=nE;function Wa(r){return"_EC_"+r}var oE=function(){function r(e){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=e||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(e,t){e=e==null?""+t:""+e;var a=this._nodesMap;if(!a[Wa(e)]){var n=new ea(e,t);return n.hostGraph=this,this.nodes.push(n),a[Wa(e)]=n,n}},r.prototype.getNodeByIndex=function(e){var t=this.data.getRawIndex(e);return this.nodes[t]},r.prototype.getNodeById=function(e){return this._nodesMap[Wa(e)]},r.prototype.addEdge=function(e,t,a){var n=this._nodesMap,i=this._edgesMap;if(gt(e)&&(e=this.nodes[e]),gt(t)&&(t=this.nodes[t]),e instanceof ea||(e=n[Wa(e)]),t instanceof ea||(t=n[Wa(t)]),!(!e||!t)){var o=e.id+"-"+t.id,s=new I_(e,t,a);return s.hostGraph=this,this._directed&&(e.outEdges.push(s),t.inEdges.push(s)),e.edges.push(s),e!==t&&t.edges.push(s),this.edges.push(s),i[o]=s,s}},r.prototype.getEdgeByIndex=function(e){var t=this.edgeData.getRawIndex(e);return this.edges[t]},r.prototype.getEdge=function(e,t){e instanceof ea&&(e=e.id),t instanceof ea&&(t=t.id);var a=this._edgesMap;return this._directed?a[e+"-"+t]:a[e+"-"+t]||a[t+"-"+e]},r.prototype.eachNode=function(e,t){for(var a=this.nodes,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&e.call(t,a[i],i)},r.prototype.eachEdge=function(e,t){for(var a=this.edges,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&a[i].node1.dataIndex>=0&&a[i].node2.dataIndex>=0&&e.call(t,a[i],i)},r.prototype.breadthFirstTraverse=function(e,t,a,n){if(t instanceof ea||(t=this._nodesMap[Wa(t)]),!!t){for(var i=a==="out"?"outEdges":a==="in"?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!e.call(n,t,null))for(var s=[t];s.length;)for(var l=s.shift(),u=l[i],o=0;o<u.length;o++){var c=u[o],v=c.node1===l?c.node2:c.node1;if(!v.__visited){if(e.call(n,v,l))return;s.push(v),v.__visited=!0}}}},r.prototype.update=function(){for(var e=this.data,t=this.edgeData,a=this.nodes,n=this.edges,i=0,o=a.length;i<o;i++)a[i].dataIndex=-1;for(var i=0,o=e.count();i<o;i++)a[e.getRawIndex(i)].dataIndex=i;t.filterSelf(function(s){var l=n[t.getRawIndex(s)];return l.node1.dataIndex>=0&&l.node2.dataIndex>=0});for(var i=0,o=n.length;i<o;i++)n[i].dataIndex=-1;for(var i=0,o=t.count();i<o;i++)n[t.getRawIndex(i)].dataIndex=i},r.prototype.clone=function(){for(var e=new r(this._directed),t=this.nodes,a=this.edges,n=0;n<t.length;n++)e.addNode(t[n].id,t[n].dataIndex);for(var n=0;n<a.length;n++){var i=a[n];e.addEdge(i.node1.id,i.node2.id,i.dataIndex)}return e},r}(),ea=function(){function r(e,t){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=e??"",this.dataIndex=t??-1}return r.prototype.degree=function(){return this.edges.length},r.prototype.inDegree=function(){return this.inEdges.length},r.prototype.outDegree=function(){return this.outEdges.length},r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,a=t.data.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){for(var e={edge:[],node:[]},t=0;t<this.edges.length;t++){var a=this.edges[t];a.dataIndex<0||(e.edge.push(a.dataIndex),e.node.push(a.node1.dataIndex,a.node2.dataIndex))}return e},r.prototype.getTrajectoryDataIndices=function(){for(var e=Z(),t=Z(),a=0;a<this.edges.length;a++){var n=this.edges[a];if(!(n.dataIndex<0)){e.set(n.dataIndex,!0);for(var i=[n.node1],o=[n.node2],s=0;s<i.length;){var l=i[s];s++,t.set(l.dataIndex,!0);for(var u=0;u<l.inEdges.length;u++)e.set(l.inEdges[u].dataIndex,!0),i.push(l.inEdges[u].node1)}for(s=0;s<o.length;){var c=o[s];s++,t.set(c.dataIndex,!0);for(var u=0;u<c.outEdges.length;u++)e.set(c.outEdges[u].dataIndex,!0),o.push(c.outEdges[u].node2)}}}return{edge:e.keys(),node:t.keys()}},r}(),I_=function(){function r(e,t,a){this.dataIndex=-1,this.node1=e,this.node2=t,this.dataIndex=a??-1}return r.prototype.getModel=function(e){if(!(this.dataIndex<0)){var t=this.hostGraph,a=t.edgeData.getItemModel(this.dataIndex);return a.getModel(e)}},r.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},r.prototype.getTrajectoryDataIndices=function(){var e=Z(),t=Z();e.set(this.dataIndex,!0);for(var a=[this.node1],n=[this.node2],i=0;i<a.length;){var o=a[i];i++,t.set(o.dataIndex,!0);for(var s=0;s<o.inEdges.length;s++)e.set(o.inEdges[s].dataIndex,!0),a.push(o.inEdges[s].node1)}for(i=0;i<n.length;){var l=n[i];i++,t.set(l.dataIndex,!0);for(var s=0;s<l.outEdges.length;s++)e.set(l.outEdges[s].dataIndex,!0),n.push(l.outEdges[s].node2)}return{edge:e.keys(),node:t.keys()}},r}();function L_(r,e){return{getValue:function(t){var a=this[r][e];return a.getStore().get(a.getDimensionIndex(t||"value"),this.dataIndex)},setVisual:function(t,a){this.dataIndex>=0&&this[r][e].setItemVisual(this.dataIndex,t,a)},getVisual:function(t){return this[r][e].getItemVisual(this.dataIndex,t)},setLayout:function(t,a){this.dataIndex>=0&&this[r][e].setItemLayout(this.dataIndex,t,a)},getLayout:function(){return this[r][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][e].getRawIndex(this.dataIndex)}}}jt(ea,L_("hostGraph","data"));jt(I_,L_("hostGraph","edgeData"));const sE=oE;function P_(r,e,t,a,n){for(var i=new sE(a),o=0;o<r.length;o++)i.addNode(Jt(r[o].id,r[o].name,o),o);for(var s=[],l=[],u=0,o=0;o<e.length;o++){var c=e[o],v=c.source,f=c.target;i.addEdge(v,f,u)&&(l.push(c),s.push(Jt(Ut(c.id,null),v+" > "+f)),u++)}var h=t.get("coordinateSystem"),p;if(h==="cartesian2d"||h==="polar")p=yr(r,t);else{var d=Xi.get(h),g=d?d.dimensions||[]:[];ct(g,"value")<0&&g.concat(["value"]);var y=qi(r,{coordDimensions:g,encodeDefine:t.getEncode()}).dimensions;p=new fe(y,t),p.initData(r)}var m=new fe(["value"],t);return m.initData(l,s),n&&n(p,m),f_({mainData:p,struct:i,structAttr:"graph",datas:{node:p,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var lE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments);var a=this;function n(){return a._categoriesData}this.legendVisualProvider=new ao(n,n),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(t){r.prototype.mergeDefaultAndTheme.apply(this,arguments),_a(t,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,a){var n=t.edges||t.links||[],i=t.data||t.nodes||[],o=this;if(i&&n){W2(this);var s=P_(i,n,this,!0,l);return w(s.edges,function(u){$2(u.node1,u.node2,this,u.dataIndex)},this),s.data}function l(u,c){u.wrapMethod("getItemModel",function(p){var d=o._categoriesModels,g=p.getShallow("category"),y=d[g];return y&&(y.parentModel=p.parentModel,p.parentModel=y),p});var v=Dt.prototype.getModel;function f(p,d){var g=v.call(this,p,d);return g.resolveParentPath=h,g}c.wrapMethod("getItemModel",function(p){return p.resolveParentPath=h,p.getModel=f,p});function h(p){if(p&&(p[0]==="label"||p[1]==="label")){var d=p.slice();return p[0]==="label"?d[0]="edgeLabel":p[1]==="label"&&(d[1]="edgeLabel"),d}return p}}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,a,n){if(n==="edge"){var i=this.getData(),o=this.getDataParams(t,n),s=i.graph.getEdgeByIndex(t),l=i.getName(s.node1.dataIndex),u=i.getName(s.node2.dataIndex),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),qt("nameValue",{name:c.join(" > "),value:o.value,noValue:o.value==null})}var v=mS({series:this,dataIndex:t,multipleSeries:a});return v},e.prototype._updateCategoriesData=function(){var t=G(this.option.categories||[],function(n){return n.value!=null?n:B({value:0},n)}),a=new fe(["value"],this);a.initData(t),this._categoriesData=a,this._categoriesModels=a.mapArray(function(n){return a.getItemModel(n)})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Et);const uE=lE;var cE={type:"graphRoam",event:"graphRoam",update:"none"};function vE(r){r.registerChartView(iE),r.registerSeriesModel(uE),r.registerProcessor(B2),r.registerVisual(z2),r.registerVisual(G2),r.registerLayout(U2),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,Z2),r.registerLayout(K2),r.registerCoordinateSystem("graphView",{dimensions:io.dimensions,create:j2}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},he),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},he),r.registerAction(cE,function(e,t,a){t.eachComponent({mainType:"series",query:e},function(n){var i=n.coordinateSystem,o=hf(i,e,void 0,a);n.setCenter&&n.setCenter(o.center),n.setZoom&&n.setZoom(o.zoom)})})}var fE=function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r}(),hE=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="pointer",a}return e.prototype.getDefaultShape=function(){return new fE},e.prototype.buildPath=function(t,a){var n=Math.cos,i=Math.sin,o=a.r,s=a.width,l=a.angle,u=a.x-n(l)*s*(s>=o/3?1:2),c=a.y-i(l)*s*(s>=o/3?1:2);l=a.angle-Math.PI/2,t.moveTo(u,c),t.lineTo(a.x+n(l)*s,a.y+i(l)*s),t.lineTo(a.x+n(a.angle)*o,a.y+i(a.angle)*o),t.lineTo(a.x-n(l)*s,a.y-i(l)*s),t.lineTo(u,c)},e}(It);const pE=hE;function dE(r,e){var t=r.get("center"),a=e.getWidth(),n=e.getHeight(),i=Math.min(a,n),o=F(t[0],e.getWidth()),s=F(t[1],e.getHeight()),l=F(r.get("radius"),i/2);return{cx:o,cy:s,r:l}}function ko(r,e){var t=r==null?"":r+"";return e&&($(e)?t=e.replace("{value}",t):X(e)&&(t=e(r))),t}var gE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),o=dE(t,n);this._renderMain(t,a,n,i,o),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,a,n,i,o){var s=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,c=-t.get("endAngle")/180*Math.PI,v=t.getModel("axisLine"),f=v.get("roundCap"),h=f?Is:Pe,p=v.get("show"),d=v.getModel("lineStyle"),g=d.get("width"),y=[u,c];Wb(y,!l),u=y[0],c=y[1];for(var m=c-u,S=u,x=[],b=0;p&&b<i.length;b++){var _=Math.min(Math.max(i[b][0],0),1);c=u+m*_;var A=new h({shape:{startAngle:S,endAngle:c,cx:o.cx,cy:o.cy,clockwise:l,r0:o.r-g,r:o.r},silent:!0});A.setStyle({fill:i[b][1]}),A.setStyle(d.getLineStyle(["color","width"])),x.push(A),S=c}x.reverse(),w(x,function(C){return s.add(C)});var T=function(C){if(C<=0)return i[0][1];var M;for(M=0;M<i.length;M++)if(i[M][0]>=C&&(M===0?0:i[M-1][0])<C)return i[M][1];return i[M-1][1]};this._renderTicks(t,a,n,T,o,u,c,l,g),this._renderTitleAndDetail(t,a,n,T,o),this._renderAnchor(t,o),this._renderPointer(t,a,n,T,o,u,c,l,g)},e.prototype._renderTicks=function(t,a,n,i,o,s,l,u,c){for(var v=this.group,f=o.cx,h=o.cy,p=o.r,d=+t.get("min"),g=+t.get("max"),y=t.getModel("splitLine"),m=t.getModel("axisTick"),S=t.getModel("axisLabel"),x=t.get("splitNumber"),b=m.get("splitNumber"),_=F(y.get("length"),p),A=F(m.get("length"),p),T=s,C=(l-s)/x,M=C/b,D=y.getModel("lineStyle").getLineStyle(),I=m.getModel("lineStyle").getLineStyle(),L=y.get("distance"),P,E,k=0;k<=x;k++){if(P=Math.cos(T),E=Math.sin(T),y.get("show")){var V=L?L+c:c,N=new te({shape:{x1:P*(p-V)+f,y1:E*(p-V)+h,x2:P*(p-_-V)+f,y2:E*(p-_-V)+h},style:D,silent:!0});D.stroke==="auto"&&N.setStyle({stroke:i(k/x)}),v.add(N)}if(S.get("show")){var V=S.get("distance")+L,z=ko(Vt(k/x*(g-d)+d),S.get("formatter")),H=i(k/x),Y=P*(p-_-V)+f,et=E*(p-_-V)+h,rt=S.get("rotate"),nt=0;rt==="radial"?(nt=-T+2*Math.PI,nt>Math.PI/2&&(nt+=Math.PI)):rt==="tangential"?nt=-T-Math.PI/2:gt(rt)&&(nt=rt*Math.PI/180),nt===0?v.add(new ut({style:Ct(S,{text:z,x:Y,y:et,verticalAlign:E<-.8?"top":E>.8?"bottom":"middle",align:P<-.4?"left":P>.4?"right":"center"},{inheritColor:H}),silent:!0})):v.add(new ut({style:Ct(S,{text:z,x:Y,y:et,verticalAlign:"middle",align:"center"},{inheritColor:H}),silent:!0,originX:Y,originY:et,rotation:nt}))}if(m.get("show")&&k!==x){var V=m.get("distance");V=V?V+c:c;for(var pt=0;pt<=b;pt++){P=Math.cos(T),E=Math.sin(T);var yt=new te({shape:{x1:P*(p-V)+f,y1:E*(p-V)+h,x2:P*(p-A-V)+f,y2:E*(p-A-V)+h},silent:!0,style:I});I.stroke==="auto"&&yt.setStyle({stroke:i((k+pt/b)/x)}),v.add(yt),T+=M}T-=M}else T+=C}},e.prototype._renderPointer=function(t,a,n,i,o,s,l,u,c){var v=this.group,f=this._data,h=this._progressEls,p=[],d=t.get(["pointer","show"]),g=t.getModel("progress"),y=g.get("show"),m=t.getData(),S=m.mapDimension("value"),x=+t.get("min"),b=+t.get("max"),_=[x,b],A=[s,l];function T(M,D){var I=m.getItemModel(M),L=I.getModel("pointer"),P=F(L.get("width"),o.r),E=F(L.get("length"),o.r),k=t.get(["pointer","icon"]),V=L.get("offsetCenter"),N=F(V[0],o.r),z=F(V[1],o.r),H=L.get("keepAspect"),Y;return k?Y=Ht(k,N-P/2,z-E,P,E,null,H):Y=new pE({shape:{angle:-Math.PI/2,width:P,r:E,x:N,y:z}}),Y.rotation=-(D+Math.PI/2),Y.x=o.cx,Y.y=o.cy,Y}function C(M,D){var I=g.get("roundCap"),L=I?Is:Pe,P=g.get("overlap"),E=P?g.get("width"):c/m.count(),k=P?o.r-E:o.r-(M+1)*E,V=P?o.r:o.r-M*E,N=new L({shape:{startAngle:s,endAngle:D,cx:o.cx,cy:o.cy,clockwise:u,r0:k,r:V}});return P&&(N.z2=b-m.get(S,M)%b),N}(y||d)&&(m.diff(f).add(function(M){var D=m.get(S,M);if(d){var I=T(M,s);Lt(I,{rotation:-((isNaN(+D)?A[0]:mt(D,_,A,!0))+Math.PI/2)},t),v.add(I),m.setItemGraphicEl(M,I)}if(y){var L=C(M,s),P=g.get("clip");Lt(L,{shape:{endAngle:mt(D,_,A,P)}},t),v.add(L),vc(t.seriesIndex,m.dataType,M,L),p[M]=L}}).update(function(M,D){var I=m.get(S,M);if(d){var L=f.getItemGraphicEl(D),P=L?L.rotation:s,E=T(M,P);E.rotation=P,ft(E,{rotation:-((isNaN(+I)?A[0]:mt(I,_,A,!0))+Math.PI/2)},t),v.add(E),m.setItemGraphicEl(M,E)}if(y){var k=h[D],V=k?k.shape.endAngle:s,N=C(M,V),z=g.get("clip");ft(N,{shape:{endAngle:mt(I,_,A,z)}},t),v.add(N),vc(t.seriesIndex,m.dataType,M,N),p[M]=N}}).execute(),m.each(function(M){var D=m.getItemModel(M),I=D.getModel("emphasis"),L=I.get("focus"),P=I.get("blurScope"),E=I.get("disabled");if(d){var k=m.getItemGraphicEl(M),V=m.getItemVisual(M,"style"),N=V.fill;if(k instanceof ke){var z=k.style;k.useStyle(B({image:z.image,x:z.x,y:z.y,width:z.width,height:z.height},V))}else k.useStyle(V),k.type!=="pointer"&&k.setColor(N);k.setStyle(D.getModel(["pointer","itemStyle"]).getItemStyle()),k.style.fill==="auto"&&k.setStyle("fill",i(mt(m.get(S,M),_,[0,1],!0))),k.z2EmphasisLift=0,re(k,D),Nt(k,L,P,E)}if(y){var H=p[M];H.useStyle(m.getItemVisual(M,"style")),H.setStyle(D.getModel(["progress","itemStyle"]).getItemStyle()),H.z2EmphasisLift=0,re(H,D),Nt(H,L,P,E)}}),this._progressEls=p)},e.prototype._renderAnchor=function(t,a){var n=t.getModel("anchor"),i=n.get("show");if(i){var o=n.get("size"),s=n.get("icon"),l=n.get("offsetCenter"),u=n.get("keepAspect"),c=Ht(s,a.cx-o/2+F(l[0],a.r),a.cy-o/2+F(l[1],a.r),o,o,null,u);c.z2=n.get("showAbove")?1:0,c.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(c)}},e.prototype._renderTitleAndDetail=function(t,a,n,i,o){var s=this,l=t.getData(),u=l.mapDimension("value"),c=+t.get("min"),v=+t.get("max"),f=new tt,h=[],p=[],d=t.isAnimationEnabled(),g=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(y){h[y]=new ut({silent:!0}),p[y]=new ut({silent:!0})}).update(function(y,m){h[y]=s._titleEls[m],p[y]=s._detailEls[m]}).execute(),l.each(function(y){var m=l.getItemModel(y),S=l.get(u,y),x=new tt,b=i(mt(S,[c,v],[0,1],!0)),_=m.getModel("title");if(_.get("show")){var A=_.get("offsetCenter"),T=o.cx+F(A[0],o.r),C=o.cy+F(A[1],o.r),M=h[y];M.attr({z2:g?0:2,style:Ct(_,{x:T,y:C,text:l.getName(y),align:"center",verticalAlign:"middle"},{inheritColor:b})}),x.add(M)}var D=m.getModel("detail");if(D.get("show")){var I=D.get("offsetCenter"),L=o.cx+F(I[0],o.r),P=o.cy+F(I[1],o.r),E=F(D.get("width"),o.r),k=F(D.get("height"),o.r),V=t.get(["progress","show"])?l.getItemVisual(y,"style").fill:b,M=p[y],N=D.get("formatter");M.attr({z2:g?0:2,style:Ct(D,{x:L,y:P,text:ko(S,N),width:isNaN(E)?null:E,height:isNaN(k)?null:k,align:"center",verticalAlign:"middle"},{inheritColor:V})}),x0(M,{normal:D},S,function(H){return ko(H,N)}),d&&_0(M,y,l,t,{getFormattedLabel:function(H,Y,et,rt,nt,pt){return ko(pt?pt.interpolatedValue:S,N)}}),x.add(M)}f.add(x)}),this.group.add(f),this._titleEls=h,this._detailEls=p},e.type="gauge",e}(Mt);const yE=gE;var mE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return e.prototype.getInitialData=function(t,a){return Pn(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(Et);const SE=mE;function xE(r){r.registerChartView(yE),r.registerSeriesModel(SE)}var _E=["itemStyle","opacity"],bE=function(r){R(e,r);function e(t,a){var n=r.call(this)||this,i=n,o=new me,s=new ut;return i.setTextContent(s),n.setTextGuideLine(o),n.updateData(t,a,!0),n}return e.prototype.updateData=function(t,a,n){var i=this,o=t.hostModel,s=t.getItemModel(a),l=t.getItemLayout(a),u=s.getModel("emphasis"),c=s.get(_E);c=c??1,n||We(i),i.useStyle(t.getItemVisual(a,"style")),i.style.lineJoin="round",n?(i.setShape({points:l.points}),i.style.opacity=0,Lt(i,{style:{opacity:c}},o,a)):ft(i,{style:{opacity:c},shape:{points:l.points}},o,a),re(i,s),this._updateLabel(t,a),Nt(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t,a){var n=this,i=this.getTextGuideLine(),o=n.getTextContent(),s=t.hostModel,l=t.getItemModel(a),u=t.getItemLayout(a),c=u.label,v=t.getItemVisual(a,"style"),f=v.fill;ae(o,Kt(l),{labelFetcher:t.hostModel,labelDataIndex:a,defaultOpacity:v.opacity,defaultText:t.getName(a)},{normal:{align:c.textAlign,verticalAlign:c.verticalAlign}}),n.setTextConfig({local:!0,inside:!!c.inside,insideStroke:f,outsideFill:f});var h=c.linePoints;i.setShape({points:h}),n.textGuideLineConfig={anchor:h?new Gt(h[0][0],h[0][1]):null},ft(o,{style:{x:c.x,y:c.y}},s,a),o.attr({rotation:c.rotation,originX:c.x,originY:c.y,z2:10}),nf(n,of(l),{stroke:f})},e}(Ee),wE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreLabelLineUpdate=!0,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._data,s=this.group;i.diff(o).add(function(l){var u=new bE(i,l);i.setItemGraphicEl(l,u),s.add(u)}).update(function(l,u){var c=o.getItemGraphicEl(u);c.updateData(i,l),s.add(c),i.setItemGraphicEl(l,c)}).remove(function(l){var u=o.getItemGraphicEl(l);bi(u,t,l)}).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e}(Mt);const AE=wE;var TE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new ao(W(this.getData,this),W(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,a){return Pn(this,{coordDimensions:["value"],encodeDefaulter:Q(Nv,this)})},e.prototype._defaultLabelLine=function(t){_a(t,"labelLine",["show"]);var a=t.labelLine,n=t.emphasis.labelLine;a.show=a.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.prototype.getDataParams=function(t){var a=this.getData(),n=r.prototype.getDataParams.call(this,t),i=a.mapDimension("value"),o=a.getSum(i);return n.percent=o?+(a.get(i,t)/o*100).toFixed(2):0,n.$vars.push("percent"),n},e.type="series.funnel",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(Et);const CE=TE;function DE(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function ME(r,e){for(var t=r.mapDimension("value"),a=r.mapArray(t,function(l){return l}),n=[],i=e==="ascending",o=0,s=r.count();o<s;o++)n[o]=o;return X(e)?n.sort(e):e!=="none"&&n.sort(function(l,u){return i?a[l]-a[u]:a[u]-a[l]}),n}function IE(r){var e=r.hostModel,t=e.get("orient");r.each(function(a){var n=r.getItemModel(a),i=n.getModel("label"),o=i.get("position"),s=n.getModel("labelLine"),l=r.getItemLayout(a),u=l.points,c=o==="inner"||o==="inside"||o==="center"||o==="insideLeft"||o==="insideRight",v,f,h,p;if(c)o==="insideLeft"?(f=(u[0][0]+u[3][0])/2+5,h=(u[0][1]+u[3][1])/2,v="left"):o==="insideRight"?(f=(u[1][0]+u[2][0])/2-5,h=(u[1][1]+u[2][1])/2,v="right"):(f=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,h=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,v="center"),p=[[f,h],[f,h]];else{var d=void 0,g=void 0,y=void 0,m=void 0,S=s.get("length");o==="left"?(d=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,y=d-S,f=y-5,v="right"):o==="right"?(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,y=d+S,f=y+5,v="left"):o==="top"?(d=(u[3][0]+u[0][0])/2,g=(u[3][1]+u[0][1])/2,m=g-S,h=m-5,v="center"):o==="bottom"?(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,m=g+S,h=m+5,v="center"):o==="rightTop"?(d=t==="horizontal"?u[3][0]:u[1][0],g=t==="horizontal"?u[3][1]:u[1][1],t==="horizontal"?(m=g-S,h=m-5,v="center"):(y=d+S,f=y+5,v="top")):o==="rightBottom"?(d=u[2][0],g=u[2][1],t==="horizontal"?(m=g+S,h=m+5,v="center"):(y=d+S,f=y+5,v="bottom")):o==="leftTop"?(d=u[0][0],g=t==="horizontal"?u[0][1]:u[1][1],t==="horizontal"?(m=g-S,h=m-5,v="center"):(y=d-S,f=y-5,v="right")):o==="leftBottom"?(d=t==="horizontal"?u[1][0]:u[3][0],g=t==="horizontal"?u[1][1]:u[2][1],t==="horizontal"?(m=g+S,h=m+5,v="center"):(y=d-S,f=y-5,v="right")):(d=(u[1][0]+u[2][0])/2,g=(u[1][1]+u[2][1])/2,t==="horizontal"?(m=g+S,h=m+5,v="center"):(y=d+S,f=y+5,v="left")),t==="horizontal"?(y=d,f=y):(m=g,h=m),p=[[d,g],[y,m]]}l.label={linePoints:p,x:f,y:h,verticalAlign:"middle",textAlign:v,inside:c}})}function LE(r,e){r.eachSeriesByType("funnel",function(t){var a=t.getData(),n=a.mapDimension("value"),i=t.get("sort"),o=DE(t,e),s=t.get("orient"),l=o.width,u=o.height,c=ME(a,i),v=o.x,f=o.y,h=s==="horizontal"?[F(t.get("minSize"),u),F(t.get("maxSize"),u)]:[F(t.get("minSize"),l),F(t.get("maxSize"),l)],p=a.getDataExtent(n),d=t.get("min"),g=t.get("max");d==null&&(d=Math.min(p[0],0)),g==null&&(g=p[1]);var y=t.get("funnelAlign"),m=t.get("gap"),S=s==="horizontal"?l:u,x=(S-m*(a.count()-1))/a.count(),b=function(P,E){if(s==="horizontal"){var k=a.get(n,P)||0,V=mt(k,[d,g],h,!0),N=void 0;switch(y){case"top":N=f;break;case"center":N=f+(u-V)/2;break;case"bottom":N=f+(u-V);break}return[[E,N],[E,N+V]]}var z=a.get(n,P)||0,H=mt(z,[d,g],h,!0),Y;switch(y){case"left":Y=v;break;case"center":Y=v+(l-H)/2;break;case"right":Y=v+l-H;break}return[[Y,E],[Y+H,E]]};i==="ascending"&&(x=-x,m=-m,s==="horizontal"?v+=l:f+=u,c=c.reverse());for(var _=0;_<c.length;_++){var A=c[_],T=c[_+1],C=a.getItemModel(A);if(s==="horizontal"){var M=C.get(["itemStyle","width"]);M==null?M=x:(M=F(M,l),i==="ascending"&&(M=-M));var D=b(A,v),I=b(T,v+M);v+=M+m,a.setItemLayout(A,{points:D.concat(I.slice().reverse())})}else{var L=C.get(["itemStyle","height"]);L==null?L=x:(L=F(L,u),i==="ascending"&&(L=-L));var D=b(A,f),I=b(T,f+L);f+=L+m,a.setItemLayout(A,{points:D.concat(I.slice().reverse())})}}IE(a)})}function PE(r){r.registerChartView(AE),r.registerSeriesModel(CE),r.registerLayout(LE),r.registerProcessor(ro("funnel"))}var EE=.3,RE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._dataGroup=new tt,t._initialized=!1,t}return e.prototype.init=function(){this.group.add(this._dataGroup)},e.prototype.render=function(t,a,n,i){this._progressiveEls=null;var o=this._dataGroup,s=t.getData(),l=this._data,u=t.coordinateSystem,c=u.dimensions,v=fg(t);s.diff(l).add(f).update(h).remove(p).execute();function f(g){var y=vg(s,o,g,c,u);wu(y,s,g,v)}function h(g,y){var m=l.getItemGraphicEl(y),S=E_(s,g,c,u);s.setItemGraphicEl(g,m),ft(m,{shape:{points:S}},t,g),We(m),wu(m,s,g,v)}function p(g){var y=l.getItemGraphicEl(g);o.remove(y)}if(!this._initialized){this._initialized=!0;var d=kE(u,t,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(d)}this._data=s},e.prototype.incrementalPrepareRender=function(t,a,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},e.prototype.incrementalRender=function(t,a,n){for(var i=a.getData(),o=a.coordinateSystem,s=o.dimensions,l=fg(a),u=this._progressiveEls=[],c=t.start;c<t.end;c++){var v=vg(i,this._dataGroup,c,s,o);v.incremental=!0,wu(v,i,c,l),u.push(v)}},e.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},e.type="parallel",e}(Mt);function kE(r,e,t){var a=r.model,n=r.getRect(),i=new ht({shape:{x:n.x,y:n.y,width:n.width,height:n.height}}),o=a.get("layout")==="horizontal"?"width":"height";return i.setShape(o,0),Lt(i,{shape:{width:n.width,height:n.height}},e,t),i}function E_(r,e,t,a){for(var n=[],i=0;i<t.length;i++){var o=t[i],s=r.get(r.mapDimension(o),e);NE(s,a.getAxis(o).type)||n.push(a.dataToPoint(s,o))}return n}function vg(r,e,t,a,n){var i=E_(r,t,a,n),o=new me({shape:{points:i},z2:10});return e.add(o),r.setItemGraphicEl(t,o),o}function fg(r){var e=r.get("smooth",!0);return e===!0&&(e=EE),e=cr(e),cs(e)&&(e=0),{smooth:e}}function wu(r,e,t,a){r.useStyle(e.getItemVisual(t,"style")),r.style.fill=null,r.setShape("smooth",a.smooth);var n=e.getItemModel(t),i=n.getModel("emphasis");re(r,n,"lineStyle"),Nt(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function NE(r,e){return e==="category"?r==null:r==null||isNaN(r)}const OE=RE;var VE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.getInitialData=function(t,a){return yr(null,this,{useEncodeDefaulter:W(BE,null,this)})},e.prototype.getRawIndicesByActiveState=function(t){var a=this.coordinateSystem,n=this.getData(),i=[];return a.eachActiveState(n,function(o,s){t===o&&i.push(n.getRawIndex(s))}),i},e.type="series.parallel",e.dependencies=["parallel"],e.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"},e}(Et);function BE(r){var e=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(e){var t={};return w(e.dimensions,function(a){var n=zE(a);t[a]=n}),t}}function zE(r){return+r.replace("dim","")}const GE=VE;var FE=["lineStyle","opacity"],HE={seriesType:"parallel",reset:function(r,e){var t=r.coordinateSystem,a={normal:r.get(["lineStyle","opacity"]),active:r.get("activeOpacity"),inactive:r.get("inactiveOpacity")};return{progress:function(n,i){t.eachActiveState(i,function(o,s){var l=a[o];if(o==="normal"&&i.hasItemOption){var u=i.getItemModel(s).get(FE,!0);u!=null&&(l=u)}var c=i.ensureUniqueItemVisual(s,"style");c.opacity=l},n.start,n.end)}}}};const WE=HE;function $E(r){UE(r),YE(r)}function UE(r){if(!r.parallel){var e=!1;w(r.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(r.parallel=[{}])}}function YE(r){var e=_t(r.parallelAxis);w(e,function(t){if(j(t)){var a=t.parallelIndex||0,n=_t(r.parallel)[a];n&&n.parallelAxisDefault&&ot(t,n.parallelAxisDefault,!1)}})}var ZE=5,XE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this._model=t,this._api=n,this._handlers||(this._handlers={},w(KE,function(i,o){n.getZr().on(o,this._handlers[o]=W(i,this))},this)),In(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,a){Di(this,"_throttledDispatchExpand"),w(this._handlers,function(n,i){a.getZr().off(i,n)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(B({type:"parallelAxisExpand"},t))},e.type="parallel",e}(Ot),KE={mousedown:function(r){Au(this,"click")&&(this._mouseDownPoint=[r.offsetX,r.offsetY])},mouseup:function(r){var e=this._mouseDownPoint;if(Au(this,"click")&&e){var t=[r.offsetX,r.offsetY],a=Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2);if(a>ZE)return;var n=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);n.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:n.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!Au(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),a=t.behavior;a==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(a==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:a==="jump"?null:{duration:0}})}}};function Au(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}const qE=XE;var jE=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var a=this.option;t&&ot(a,t,!0),this._initDimensions()},e.prototype.contains=function(t,a){var n=t.get("parallelIndex");return n!=null&&a.getComponent("parallel",n)===this},e.prototype.setAxisExpand=function(t){w(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(a){t.hasOwnProperty(a)&&(this.option[a]=t[a])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],a=this.parallelAxisIndex=[],n=bt(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(i){return(i.get("parallelIndex")||0)===this.componentIndex},this);w(n,function(i){t.push("dim"+i.get("dim")),a.push(i.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(lt);const JE=jE;var QE=function(r){R(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.type=i||"value",s.axisIndex=o,s}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e}(Ue);const tR=QE;function Ra(r,e,t,a,n,i){r=r||0;var o=t[1]-t[0];if(n!=null&&(n=$a(n,[0,o])),i!=null&&(i=Math.max(i,n??0)),a==="all"){var s=Math.abs(e[1]-e[0]);s=$a(s,[0,o]),n=i=$a(s,[n,i]),a=0}e[0]=$a(e[0],t),e[1]=$a(e[1],t);var l=Tu(e,a);e[a]+=r;var u=n||0,c=t.slice();l.sign<0?c[0]+=u:c[1]-=u,e[a]=$a(e[a],c);var v;return v=Tu(e,a),n!=null&&(v.sign!==l.sign||v.span<n)&&(e[1-a]=e[a]+l.sign*n),v=Tu(e,a),i!=null&&v.span>i&&(e[1-a]=e[a]+v.sign*i),e}function Tu(r,e){var t=r[e]-r[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function $a(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var Cu=w,R_=Math.min,k_=Math.max,hg=Math.floor,eR=Math.ceil,pg=Vt,rR=Math.PI,aR=function(){function r(e,t,a){this.type="parallel",this._axesMap=Z(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,a)}return r.prototype._init=function(e,t,a){var n=e.dimensions,i=e.parallelAxisIndex;Cu(n,function(o,s){var l=i[s],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(o,new tR(o,vl(u),[0,0],u.get("type"),l)),v=c.type==="category";c.onBand=v&&u.get("boundaryGap"),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},r.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),a=t.axisBase,n=t.layoutBase,i=t.pixelDimIndex,o=e[1-i],s=e[i];return o>=a&&o<=a+t.axisLength&&s>=n&&s<=n+t.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(a){if(e.contains(a,t)){var n=a.getData();Cu(this.dimensions,function(i){var o=this._axesMap.get(i);o.scale.unionExtentFromData(n,n.mapDimension(i)),ln(o.scale,o.model)},this)}},this)},r.prototype.resize=function(e,t){this._rect=Yt(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,a=["x","y"],n=["width","height"],i=e.get("layout"),o=i==="horizontal"?0:1,s=t[n[o]],l=[0,s],u=this.dimensions.length,c=No(e.get("axisExpandWidth"),l),v=No(e.get("axisExpandCount")||0,[0,u]),f=e.get("axisExpandable")&&u>3&&u>v&&v>1&&c>0&&s>0,h=e.get("axisExpandWindow"),p;if(h)p=No(h[1]-h[0],l),h[1]=h[0]+p;else{p=No(c*(v-1),l);var d=e.get("axisExpandCenter")||hg(u/2);h=[c*d-p/2],h[1]=h[0]+p}var g=(s-p)/(u-v);g<3&&(g=0);var y=[hg(pg(h[0]/c,1))+1,eR(pg(h[1]/c,1))-1],m=g/c*h[0];return{layout:i,pixelDimIndex:o,layoutBase:t[a[o]],layoutLength:s,axisBase:t[a[1-o]],axisLength:t[n[1-o]],axisExpandable:f,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:h,axisCount:u,winInnerIndices:y,axisExpandWindow0Pos:m}},r.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,a=this.dimensions,n=this._makeLayoutInfo(),i=n.layout;t.each(function(o){var s=[0,n.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),Cu(a,function(o,s){var l=(n.axisExpandable?iR:nR)(s,n),u={horizontal:{x:l.position,y:n.axisLength},vertical:{x:0,y:l.position}},c={horizontal:rR/2,vertical:0},v=[u[i].x+e.x,u[i].y+e.y],f=c[i],h=yn();Fi(h,h,f),xa(h,h,v),this._axesLayout[o]={position:v,rotation:f,transform:h,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(e){return this._axesMap.get(e)},r.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},r.prototype.eachActiveState=function(e,t,a,n){a==null&&(a=0),n==null&&(n=e.count());var i=this._axesMap,o=this.dimensions,s=[],l=[];w(o,function(g){s.push(e.mapDimension(g)),l.push(i.get(g).model)});for(var u=this.hasAxisBrushed(),c=a;c<n;c++){var v=void 0;if(!u)v="normal";else{v="active";for(var f=e.getValues(s,c),h=0,p=o.length;h<p;h++){var d=l[h].getActiveState(f[h]);if(d==="inactive"){v="inactive";break}}}t(v,c)}},r.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,a=!1,n=0,i=e.length;n<i;n++)t.get(e[n]).model.getActiveState()!=="normal"&&(a=!0);return a},r.prototype.axisCoordToPoint=function(e,t){var a=this._axesLayout[t];return He([e,0],a.transform)},r.prototype.getAxisLayout=function(e){return K(this._axesLayout[e])},r.prototype.getSlidedAxisExpandWindow=function(e){var t=this._makeLayoutInfo(),a=t.pixelDimIndex,n=t.axisExpandWindow.slice(),i=n[1]-n[0],o=[0,t.axisExpandWidth*(t.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:n};var s=e[a]-t.layoutBase-t.axisExpandWindow0Pos,l,u="slide",c=t.axisCollapseWidth,v=this._model.get("axisExpandSlideTriggerArea"),f=v[0]!=null;if(c)f&&c&&s<i*v[0]?(u="jump",l=s-i*v[2]):f&&c&&s>i*(1-v[0])?(u="jump",l=s-i*(1-v[2])):(l=s-i*v[1])>=0&&(l=s-i*(1-v[1]))<=0&&(l=0),l*=t.axisExpandWidth/c,l?Ra(l,n,o,"all"):u="none";else{var h=n[1]-n[0],p=o[1]*s/h;n=[k_(0,p-h/2)],n[1]=R_(o[1],n[0]+h),n[0]=n[1]-h}return{axisExpandWindow:n,behavior:u}},r}();function No(r,e){return R_(k_(r,e[0]),e[1])}function nR(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function iR(r,e){var t=e.layoutLength,a=e.axisExpandWidth,n=e.axisCount,i=e.axisCollapseWidth,o=e.winInnerIndices,s,l=i,u=!1,c;return r<o[0]?(s=r*i,c=i):r<=o[1]?(s=e.axisExpandWindow0Pos+r*a-e.axisExpandWindow[0],l=a,u=!0):(s=t-(n-1-r)*i,c=i),{position:s,axisNameAvailableWidth:l,axisLabelShow:u,nameTruncateMaxWidth:c}}const oR=aR;function sR(r,e){var t=[];return r.eachComponent("parallel",function(a,n){var i=new oR(a,r,e);i.name="parallel_"+n,i.resize(a,e),a.coordinateSystem=i,i.model=a,t.push(i)}),r.eachSeries(function(a){if(a.get("coordinateSystem")==="parallel"){var n=a.getReferringComponents("parallel",Ft).models[0];a.coordinateSystem=n.coordinateSystem}}),t}var lR={create:sR};const uR=lR;var N_=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.activeIntervals=[],t}return e.prototype.getAreaSelectStyle=function(){return wa([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var a=this.activeIntervals=K(t);if(a)for(var n=a.length-1;n>=0;n--)Me(a[n])},e.prototype.getActiveState=function(t){var a=this.activeIntervals;if(!a.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(a.length===1){var n=a[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var i=0,o=a.length;i<o;i++)if(a[i][0]<=t&&t<=a[i][1])return"active";return"inactive"},e}(lt);jt(N_,Ji);const dg=N_;var Ca=!0,Ni=Math.min,vn=Math.max,cR=Math.pow,vR=1e4,fR=6,hR=6,gg="globalPan",pR={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},dR={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},yg={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},gR=0,yR=function(r){R(e,r);function e(t){var a=r.call(this)||this;return a._track=[],a._covers=[],a._handlers={},a._zr=t,a.group=new tt,a._uid="brushController_"+gR++,w(AR,function(n,i){this._handlers[i]=W(n,this)},a),a}return e.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},e.prototype._doEnableBrush=function(t){var a=this._zr;this._enableGlobalPan||OL(a,gg,this._uid),w(this._handlers,function(n,i){a.on(i,n)}),this._brushType=t.brushType,this._brushOption=ot(K(yg),t,!0)},e.prototype._doDisableBrush=function(){var t=this._zr;VL(t,gg,this._uid),w(this._handlers,function(a,n){t.off(n,a)}),this._brushType=this._brushOption=null},e.prototype.setPanels=function(t){if(t&&t.length){var a=this._panels={};w(t,function(n){a[n.panelId]=K(n)})}else this._panels=null;return this},e.prototype.mount=function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var a=this.group;return this._zr.add(a),a.attr({x:t.x||0,y:t.y||0,rotation:t.rotation||0,scaleX:t.scaleX||1,scaleY:t.scaleY||1}),this._transform=a.getLocalTransform(),this},e.prototype.updateCovers=function(t){t=G(t,function(f){return ot(K(yg),f,!0)});var a="\0-brush-index-",n=this._covers,i=this._covers=[],o=this,s=this._creatingCover;return new hr(n,t,u,l).add(c).update(c).remove(v).execute(),this;function l(f,h){return(f.id!=null?f.id:a+h)+"-"+f.brushType}function u(f,h){return l(f.__brushOption,h)}function c(f,h){var p=t[f];if(h!=null&&n[h]===s)i[f]=n[h];else{var d=i[f]=h!=null?(n[h].__brushOption=p,n[h]):V_(o,O_(o,p));Af(o,d)}}function v(f){n[f]!==s&&o.group.remove(n[f])}},e.prototype.unmount=function(){return this.enableBrush(!1),Xc(this),this._zr.remove(this.group),this},e.prototype.dispose=function(){this.unmount(),this.off()},e}(dn);function O_(r,e){var t=gl[e.brushType].createCover(r,e);return t.__brushOption=e,z_(t,e),r.group.add(t),t}function V_(r,e){var t=Tf(e);return t.endCreating&&(t.endCreating(r,e),z_(e,e.__brushOption)),e}function B_(r,e){var t=e.__brushOption;Tf(e).updateCoverShape(r,e,t.range,t)}function z_(r,e){var t=e.z;t==null&&(t=vR),r.traverse(function(a){a.z=t,a.z2=t})}function Af(r,e){Tf(e).updateCommon(r,e),B_(r,e)}function Tf(r){return gl[r.__brushOption.brushType]}function Cf(r,e,t){var a=r._panels;if(!a)return Ca;var n,i=r._transform;return w(a,function(o){o.isTargetByCursor(e,t,i)&&(n=o)}),n}function G_(r,e){var t=r._panels;if(!t)return Ca;var a=e.__brushOption.panelId;return a!=null?t[a]:Ca}function Xc(r){var e=r._covers,t=e.length;return w(e,function(a){r.group.remove(a)},r),e.length=0,!!t}function Da(r,e){var t=G(r._covers,function(a){var n=a.__brushOption,i=K(n.range);return{brushType:n.brushType,panelId:n.panelId,range:i}});r.trigger("brush",{areas:t,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function mR(r){var e=r._track;if(!e.length)return!1;var t=e[e.length-1],a=e[0],n=t[0]-a[0],i=t[1]-a[1],o=cR(n*n+i*i,.5);return o>fR}function F_(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function H_(r,e,t,a){var n=new tt;return n.add(new ht({name:"main",style:Df(t),silent:!0,draggable:!0,cursor:"move",drift:Q(mg,r,e,n,["n","s","w","e"]),ondragend:Q(Da,e,{isEnd:!0})})),w(a,function(i){n.add(new ht({name:i.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Q(mg,r,e,n,i),ondragend:Q(Da,e,{isEnd:!0})}))}),n}function W_(r,e,t,a){var n=a.brushStyle.lineWidth||0,i=vn(n,hR),o=t[0][0],s=t[1][0],l=o-n/2,u=s-n/2,c=t[0][1],v=t[1][1],f=c-i+n/2,h=v-i+n/2,p=c-o,d=v-s,g=p+n,y=d+n;ir(r,e,"main",o,s,p,d),a.transformable&&(ir(r,e,"w",l,u,i,y),ir(r,e,"e",f,u,i,y),ir(r,e,"n",l,u,g,i),ir(r,e,"s",l,h,g,i),ir(r,e,"nw",l,u,i,i),ir(r,e,"ne",f,u,i,i),ir(r,e,"sw",l,h,i,i),ir(r,e,"se",f,h,i,i))}function Kc(r,e){var t=e.__brushOption,a=t.transformable,n=e.childAt(0);n.useStyle(Df(t)),n.attr({silent:!a,cursor:a?"move":"default"}),w([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(i){var o=e.childOfName(i.join("")),s=i.length===1?qc(r,i[0]):xR(r,i);o&&o.attr({silent:!a,invisible:!a,cursor:a?dR[s]+"-resize":null})})}function ir(r,e,t,a,n,i,o){var s=e.childOfName(t);s&&s.setShape(bR(Mf(r,e,[[a,n],[a+i,n+o]])))}function Df(r){return J({strokeNoScale:!0},r.brushStyle)}function $_(r,e,t,a){var n=[Ni(r,t),Ni(e,a)],i=[vn(r,t),vn(e,a)];return[[n[0],i[0]],[n[1],i[1]]]}function SR(r){return pa(r.group)}function qc(r,e){var t={w:"left",e:"right",n:"top",s:"bottom"},a={left:"w",right:"e",top:"n",bottom:"s"},n=qs(t[e],SR(r));return a[n]}function xR(r,e){var t=[qc(r,e[0]),qc(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function mg(r,e,t,a,n,i){var o=t.__brushOption,s=r.toRectRange(o.range),l=U_(e,n,i);w(a,function(u){var c=pR[u];s[c[0]][c[1]]+=l[c[0]]}),o.range=r.fromRectRange($_(s[0][0],s[1][0],s[0][1],s[1][1])),Af(e,t),Da(e,{isEnd:!1})}function _R(r,e,t,a){var n=e.__brushOption.range,i=U_(r,t,a);w(n,function(o){o[0]+=i[0],o[1]+=i[1]}),Af(r,e),Da(r,{isEnd:!1})}function U_(r,e,t){var a=r.group,n=a.transformCoordToLocal(e,t),i=a.transformCoordToLocal(0,0);return[n[0]-i[0],n[1]-i[1]]}function Mf(r,e,t){var a=G_(r,e);return a&&a!==Ca?a.clipPath(t,r._transform):K(t)}function bR(r){var e=Ni(r[0][0],r[1][0]),t=Ni(r[0][1],r[1][1]),a=vn(r[0][0],r[1][0]),n=vn(r[0][1],r[1][1]);return{x:e,y:t,width:a-e,height:n-t}}function wR(r,e,t){if(!(!r._brushType||TR(r,e.offsetX,e.offsetY))){var a=r._zr,n=r._covers,i=Cf(r,e,t);if(!r._dragging)for(var o=0;o<n.length;o++){var s=n[o].__brushOption;if(i&&(i===Ca||s.panelId===i.panelId)&&gl[s.brushType].contain(n[o],t[0],t[1]))return}i&&a.setCursorStyle("crosshair")}}function jc(r){var e=r.event;e.preventDefault&&e.preventDefault()}function Jc(r,e,t){return r.childOfName("main").contain(e,t)}function Y_(r,e,t,a){var n=r._creatingCover,i=r._creatingPanel,o=r._brushOption,s;if(r._track.push(t.slice()),mR(r)||n){if(i&&!n){o.brushMode==="single"&&Xc(r);var l=K(o);l.brushType=Sg(l.brushType,i),l.panelId=i===Ca?null:i.panelId,n=r._creatingCover=O_(r,l),r._covers.push(n)}if(n){var u=gl[Sg(r._brushType,i)],c=n.__brushOption;c.range=u.getCreatingRange(Mf(r,n,r._track)),a&&(V_(r,n),u.updateCommon(r,n)),B_(r,n),s={isEnd:a}}}else a&&o.brushMode==="single"&&o.removeOnClick&&Cf(r,e,t)&&Xc(r)&&(s={isEnd:a,removeOnClick:!0});return s}function Sg(r,e){return r==="auto"?e.defaultBrushType:r}var AR={mousedown:function(r){if(this._dragging)xg(this,r);else if(!r.target||!r.target.draggable){jc(r);var e=this.group.transformCoordToLocal(r.offsetX,r.offsetY);this._creatingCover=null;var t=this._creatingPanel=Cf(this,r,e);t&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(r){var e=r.offsetX,t=r.offsetY,a=this.group.transformCoordToLocal(e,t);if(wR(this,r,a),this._dragging){jc(r);var n=Y_(this,r,a,!1);n&&Da(this,n)}},mouseup:function(r){xg(this,r)}};function xg(r,e){if(r._dragging){jc(e);var t=e.offsetX,a=e.offsetY,n=r.group.transformCoordToLocal(t,a),i=Y_(r,e,n,!0);r._dragging=!1,r._track=[],r._creatingCover=null,i&&Da(r,i)}}function TR(r,e,t){var a=r._zr;return e<0||e>a.getWidth()||t<0||t>a.getHeight()}var gl={lineX:_g(0),lineY:_g(1),rect:{createCover:function(r,e){function t(a){return a}return H_({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=F_(r);return $_(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,a){W_(r,e,t,a)},updateCommon:Kc,contain:Jc},polygon:{createCover:function(r,e){var t=new tt;return t.add(new me({name:"main",style:Df(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new Ee({name:"main",draggable:!0,drift:Q(_R,r,e),ondragend:Q(Da,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,a){e.childAt(0).setShape({points:Mf(r,e,t)})},updateCommon:Kc,contain:Jc}};function _g(r){return{createCover:function(e,t){return H_({toRectRange:function(a){var n=[a,[0,100]];return r&&n.reverse(),n},fromRectRange:function(a){return a[r]}},e,t,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(e){var t=F_(e),a=Ni(t[0][r],t[1][r]),n=vn(t[0][r],t[1][r]);return[a,n]},updateCoverShape:function(e,t,a,n){var i,o=G_(e,t);if(o!==Ca&&o.getLinearBrushOtherExtent)i=o.getLinearBrushOtherExtent(r);else{var s=e._zr;i=[0,[s.getWidth(),s.getHeight()][1-r]]}var l=[a,i];r&&l.reverse(),W_(e,t,l,n)},updateCommon:Kc,contain:Jc}}const If=yR;function Z_(r){return r=Lf(r),function(e){return g0(e,r)}}function X_(r,e){return r=Lf(r),function(t){var a=e??t,n=a?r.width:r.height,i=a?r.x:r.y;return[i,i+(n||0)]}}function K_(r,e,t){var a=Lf(r);return function(n,i){return a.contain(i[0],i[1])&&!hl(n,e,t)}}function Lf(r){return wt.create(r)}var CR=["axisLine","axisTickLabel","axisName"],DR=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){r.prototype.init.apply(this,arguments),(this._brushController=new If(a.getZr())).on("brush",W(this._onBrush,this))},e.prototype.render=function(t,a,n,i){if(!MR(t,a,i)){this.axisModel=t,this.api=n,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new tt,this.group.add(this._axisGroup),!!t.get("show")){var s=LR(t,a),l=s.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,v=t.axis.dim,f=l.getAxisLayout(v),h=B({strokeContainThreshold:c},f),p=new pr(t,h);w(CR,p.add,p),this._axisGroup.add(p.getGroup()),this._refreshBrushController(h,u,t,s,c,n),Ui(o,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,a,n,i,o,s){var l=n.axis.getExtent(),u=l[1]-l[0],c=Math.min(30,Math.abs(u)*.1),v=wt.create({x:l[0],y:-o/2,width:u,height:o});v.x-=c,v.width+=2*c,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:Z_(v),isTargetByCursor:K_(v,s,i),getLinearBrushOtherExtent:X_(v,0)}]).enableBrush({brushType:"lineX",brushStyle:a,removeOnClick:!0}).updateCovers(IR(n))},e.prototype._onBrush=function(t){var a=t.areas,n=this.axisModel,i=n.axis,o=G(a,function(s){return[i.coordToData(s.range[0],!0),i.coordToData(s.range[1],!0)]});(!n.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:o})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e}(Ot);function MR(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function IR(r){var e=r.axis;return G(r.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function LR(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}const PR=DR;var ER={type:"axisAreaSelect",event:"axisAreaSelected"};function RR(r){r.registerAction(ER,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(a){a.axis.model.setActiveIntervals(e.intervals)})}),r.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(a){a.setAxisExpand(e)})})}var kR={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function q_(r){r.registerComponentView(qE),r.registerComponentModel(JE),r.registerCoordinateSystem("parallel",uR),r.registerPreprocessor($E),r.registerComponentModel(dg),r.registerComponentView(PR),cn(r,"parallel",dg,kR),RR(r)}function NR(r){it(q_),r.registerChartView(OE),r.registerSeriesModel(GE),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,WE)}var OR=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r}(),VR=function(r){R(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new OR},e.prototype.buildPath=function(t,a){var n=a.extent;t.moveTo(a.x1,a.y1),t.bezierCurveTo(a.cpx1,a.cpy1,a.cpx2,a.cpy2,a.x2,a.y2),a.orient==="vertical"?(t.lineTo(a.x2+n,a.y2),t.bezierCurveTo(a.cpx2+n,a.cpy2,a.cpx1+n,a.cpy1,a.x1+n,a.y1)):(t.lineTo(a.x2,a.y2+n),t.bezierCurveTo(a.cpx2,a.cpy2+n,a.cpx1,a.cpy1+n,a.x1,a.y1+n)),t.closePath()},e.prototype.highlight=function(){vr(this)},e.prototype.downplay=function(){fr(this)},e}(It),BR=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._focusAdjacencyDisabled=!1,t}return e.prototype.render=function(t,a,n){var i=this,o=t.getGraph(),s=this.group,l=t.layoutInfo,u=l.width,c=l.height,v=t.getData(),f=t.getData("edge"),h=t.get("orient");this._model=t,s.removeAll(),s.x=l.x,s.y=l.y,o.eachEdge(function(p){var d=new VR,g=q(d);g.dataIndex=p.dataIndex,g.seriesIndex=t.seriesIndex,g.dataType="edge";var y=p.getModel(),m=y.getModel("lineStyle"),S=m.get("curveness"),x=p.node1.getLayout(),b=p.node1.getModel(),_=b.get("localX"),A=b.get("localY"),T=p.node2.getLayout(),C=p.node2.getModel(),M=C.get("localX"),D=C.get("localY"),I=p.getLayout(),L,P,E,k,V,N,z,H;d.shape.extent=Math.max(1,I.dy),d.shape.orient=h,h==="vertical"?(L=(_!=null?_*u:x.x)+I.sy,P=(A!=null?A*c:x.y)+x.dy,E=(M!=null?M*u:T.x)+I.ty,k=D!=null?D*c:T.y,V=L,N=P*(1-S)+k*S,z=E,H=P*S+k*(1-S)):(L=(_!=null?_*u:x.x)+x.dx,P=(A!=null?A*c:x.y)+I.sy,E=M!=null?M*u:T.x,k=(D!=null?D*c:T.y)+I.ty,V=L*(1-S)+E*S,N=P,z=L*S+E*(1-S),H=k),d.setShape({x1:L,y1:P,x2:E,y2:k,cpx1:V,cpy1:N,cpx2:z,cpy2:H}),d.useStyle(m.getItemStyle()),bg(d.style,h,p);var Y=""+y.get("value"),et=Kt(y,"edgeLabel");ae(d,et,{labelFetcher:{getFormattedLabel:function(pt,yt,vt,at,At,xt){return t.getFormattedLabel(pt,yt,"edge",at,gn(At,et.normal&&et.normal.get("formatter"),Y),xt)}},labelDataIndex:p.dataIndex,defaultText:Y}),d.setTextConfig({position:"inside"});var rt=y.getModel("emphasis");re(d,y,"lineStyle",function(pt){var yt=pt.getItemStyle();return bg(yt,h,p),yt}),s.add(d),f.setItemGraphicEl(p.dataIndex,d);var nt=rt.get("focus");Nt(d,nt==="adjacency"?p.getAdjacentDataIndices():nt==="trajectory"?p.getTrajectoryDataIndices():nt,rt.get("blurScope"),rt.get("disabled"))}),o.eachNode(function(p){var d=p.getLayout(),g=p.getModel(),y=g.get("localX"),m=g.get("localY"),S=g.getModel("emphasis"),x=new ht({shape:{x:y!=null?y*u:d.x,y:m!=null?m*c:d.y,width:d.dx,height:d.dy},style:g.getModel("itemStyle").getItemStyle(),z2:10});ae(x,Kt(g),{labelFetcher:{getFormattedLabel:function(_,A){return t.getFormattedLabel(_,A,"node")}},labelDataIndex:p.dataIndex,defaultText:p.id}),x.disableLabelAnimation=!0,x.setStyle("fill",p.getVisual("color")),x.setStyle("decal",p.getVisual("style").decal),re(x,g),s.add(x),v.setItemGraphicEl(p.dataIndex,x),q(x).dataType="node";var b=S.get("focus");Nt(x,b==="adjacency"?p.getAdjacentDataIndices():b==="trajectory"?p.getTrajectoryDataIndices():b,S.get("blurScope"),S.get("disabled"))}),v.eachItemGraphicEl(function(p,d){var g=v.getItemModel(d);g.get("draggable")&&(p.drift=function(y,m){i._focusAdjacencyDisabled=!0,this.shape.x+=y,this.shape.y+=m,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:t.id,dataIndex:v.getRawIndex(d),localX:this.shape.x/u,localY:this.shape.y/c})},p.ondragend=function(){i._focusAdjacencyDisabled=!1},p.draggable=!0,p.cursor="move")}),!this._data&&t.isAnimationEnabled()&&s.setClipPath(zR(s.getBoundingRect(),t,function(){s.removeClipPath()})),this._data=t.getData()},e.prototype.dispose=function(){},e.type="sankey",e}(Mt);function bg(r,e,t){switch(r.fill){case"source":r.fill=t.node1.getVisual("color"),r.decal=t.node1.getVisual("style").decal;break;case"target":r.fill=t.node2.getVisual("color"),r.decal=t.node2.getVisual("style").decal;break;case"gradient":var a=t.node1.getVisual("color"),n=t.node2.getVisual("color");$(a)&&$(n)&&(r.fill=new $s(0,0,+(e==="horizontal"),+(e==="vertical"),[{color:a,offset:0},{color:n,offset:1}]))}}function zR(r,e,t){var a=new ht({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Lt(a,{shape:{width:r.width+20}},e,t),a}const GR=BR;var FR=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){var n=t.edges||t.links,i=t.data||t.nodes,o=t.levels;this.levelModels=[];for(var s=this.levelModels,l=0;l<o.length;l++)o[l].depth!=null&&o[l].depth>=0&&(s[o[l].depth]=new Dt(o[l],this,a));if(i&&n){var u=P_(i,n,this,!0,c);return u.data}function c(v,f){v.wrapMethod("getItemModel",function(h,p){var d=h.parentModel,g=d.getData().getItemLayout(p);if(g){var y=g.depth,m=d.levelModels[y];m&&(h.parentModel=m)}return h}),f.wrapMethod("getItemModel",function(h,p){var d=h.parentModel,g=d.getGraph().getEdgeByIndex(p),y=g.node1.getLayout();if(y){var m=y.depth,S=d.levelModels[m];S&&(h.parentModel=S)}return h})}},e.prototype.setNodePosition=function(t,a){var n=this.option.data||this.option.nodes,i=n[t];i.localX=a[0],i.localY=a[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,a,n){function i(h){return isNaN(h)||h==null}if(n==="edge"){var o=this.getDataParams(t,n),s=o.data,l=o.value,u=s.source+" -- "+s.target;return qt("nameValue",{name:u,value:l,noValue:i(l)})}else{var c=this.getGraph().getNodeByIndex(t),v=c.getLayout().value,f=this.getDataParams(t,n).data.name;return qt("nameValue",{name:f!=null?f+"":null,value:v,noValue:i(v)})}},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(t,a){var n=r.prototype.getDataParams.call(this,t,a);if(n.value==null&&a==="node"){var i=this.getGraph().getNodeByIndex(t),o=i.getLayout().value;n.value=o}return n},e.type="series.sankey",e.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},e}(Et);const HR=FR;function WR(r,e){r.eachSeriesByType("sankey",function(t){var a=t.get("nodeWidth"),n=t.get("nodeGap"),i=$R(t,e);t.layoutInfo=i;var o=i.width,s=i.height,l=t.getGraph(),u=l.nodes,c=l.edges;YR(u);var v=bt(u,function(d){return d.getLayout().value===0}),f=v.length!==0?0:t.get("layoutIterations"),h=t.get("orient"),p=t.get("nodeAlign");UR(u,c,a,n,o,s,f,h,p)})}function $R(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function UR(r,e,t,a,n,i,o,s,l){ZR(r,e,t,n,i,s,l),jR(r,e,i,n,a,o,s),ok(r,s)}function YR(r){w(r,function(e){var t=kr(e.outEdges,Rs),a=kr(e.inEdges,Rs),n=e.getValue()||0,i=Math.max(t,a,n);e.setLayout({value:i},!0)})}function ZR(r,e,t,a,n,i,o){for(var s=[],l=[],u=[],c=[],v=0,f=0;f<e.length;f++)s[f]=1;for(var f=0;f<r.length;f++)l[f]=r[f].inEdges.length,l[f]===0&&u.push(r[f]);for(var h=-1;u.length;){for(var p=0;p<u.length;p++){var d=u[p],g=d.hostGraph.data.getRawDataItem(d.dataIndex),y=g.depth!=null&&g.depth>=0;y&&g.depth>h&&(h=g.depth),d.setLayout({depth:y?g.depth:v},!0),i==="vertical"?d.setLayout({dy:t},!0):d.setLayout({dx:t},!0);for(var m=0;m<d.outEdges.length;m++){var S=d.outEdges[m],x=e.indexOf(S);s[x]=0;var b=S.node2,_=r.indexOf(b);--l[_]===0&&c.indexOf(b)<0&&c.push(b)}}++v,u=c,c=[]}for(var f=0;f<s.length;f++)if(s[f]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var A=h>v-1?h:v-1;o&&o!=="left"&&XR(r,o,i,A);var T=i==="vertical"?(n-t)/A:(a-t)/A;qR(r,T,i)}function j_(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function XR(r,e,t,a){if(e==="right"){for(var n=[],i=r,o=0;i.length;){for(var s=0;s<i.length;s++){var l=i[s];l.setLayout({skNodeHeight:o},!0);for(var u=0;u<l.inEdges.length;u++){var c=l.inEdges[u];n.indexOf(c.node1)<0&&n.push(c.node1)}}i=n,n=[],++o}w(r,function(v){j_(v)||v.setLayout({depth:Math.max(0,a-v.getLayout().skNodeHeight)},!0)})}else e==="justify"&&KR(r,a)}function KR(r,e){w(r,function(t){!j_(t)&&!t.outEdges.length&&t.setLayout({depth:e},!0)})}function qR(r,e,t){w(r,function(a){var n=a.getLayout().depth*e;t==="vertical"?a.setLayout({y:n},!0):a.setLayout({x:n},!0)})}function jR(r,e,t,a,n,i,o){var s=JR(r,o);QR(s,e,t,a,n,o),Du(s,n,t,a,o);for(var l=1;i>0;i--)l*=.99,tk(s,l,o),Du(s,n,t,a,o),ik(s,l,o),Du(s,n,t,a,o)}function JR(r,e){var t=[],a=e==="vertical"?"y":"x",n=cc(r,function(i){return i.getLayout()[a]});return n.keys.sort(function(i,o){return i-o}),w(n.keys,function(i){t.push(n.buckets.get(i))}),t}function QR(r,e,t,a,n,i){var o=1/0;w(r,function(s){var l=s.length,u=0;w(s,function(v){u+=v.getLayout().value});var c=i==="vertical"?(a-(l-1)*n)/u:(t-(l-1)*n)/u;c<o&&(o=c)}),w(r,function(s){w(s,function(l,u){var c=l.getLayout().value*o;i==="vertical"?(l.setLayout({x:u},!0),l.setLayout({dx:c},!0)):(l.setLayout({y:u},!0),l.setLayout({dy:c},!0))})}),w(e,function(s){var l=+s.getValue()*o;s.setLayout({dy:l},!0)})}function Du(r,e,t,a,n){var i=n==="vertical"?"x":"y";w(r,function(o){o.sort(function(d,g){return d.getLayout()[i]-g.getLayout()[i]});for(var s,l,u,c=0,v=o.length,f=n==="vertical"?"dx":"dy",h=0;h<v;h++)l=o[h],u=c-l.getLayout()[i],u>0&&(s=l.getLayout()[i]+u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]+l.getLayout()[f]+e;var p=n==="vertical"?a:t;if(u=c-e-p,u>0){s=l.getLayout()[i]-u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0),c=s;for(var h=v-2;h>=0;--h)l=o[h],u=l.getLayout()[i]+l.getLayout()[f]+e-c,u>0&&(s=l.getLayout()[i]-u,n==="vertical"?l.setLayout({x:s},!0):l.setLayout({y:s},!0)),c=l.getLayout()[i]}})}function tk(r,e,t){w(r.slice().reverse(),function(a){w(a,function(n){if(n.outEdges.length){var i=kr(n.outEdges,ek,t)/kr(n.outEdges,Rs);if(isNaN(i)){var o=n.outEdges.length;i=o?kr(n.outEdges,rk,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-Gr(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-Gr(n,t))*e;n.setLayout({y:l},!0)}}})})}function ek(r,e){return Gr(r.node2,e)*r.getValue()}function rk(r,e){return Gr(r.node2,e)}function ak(r,e){return Gr(r.node1,e)*r.getValue()}function nk(r,e){return Gr(r.node1,e)}function Gr(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function Rs(r){return r.getValue()}function kr(r,e,t){for(var a=0,n=r.length,i=-1;++i<n;){var o=+e(r[i],t);isNaN(o)||(a+=o)}return a}function ik(r,e,t){w(r,function(a){w(a,function(n){if(n.inEdges.length){var i=kr(n.inEdges,ak,t)/kr(n.inEdges,Rs);if(isNaN(i)){var o=n.inEdges.length;i=o?kr(n.inEdges,nk,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-Gr(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-Gr(n,t))*e;n.setLayout({y:l},!0)}}})})}function ok(r,e){var t=e==="vertical"?"x":"y";w(r,function(a){a.outEdges.sort(function(n,i){return n.node2.getLayout()[t]-i.node2.getLayout()[t]}),a.inEdges.sort(function(n,i){return n.node1.getLayout()[t]-i.node1.getLayout()[t]})}),w(r,function(a){var n=0,i=0;w(a.outEdges,function(o){o.setLayout({sy:n},!0),n+=o.getLayout().dy}),w(a.inEdges,function(o){o.setLayout({ty:i},!0),i+=o.getLayout().dy})})}function sk(r){r.eachSeriesByType("sankey",function(e){var t=e.getGraph(),a=t.nodes,n=t.edges;if(a.length){var i=1/0,o=-1/0;w(a,function(s){var l=s.getLayout().value;l<i&&(i=l),l>o&&(o=l)}),w(a,function(s){var l=new ee({type:"color",mappingMethod:"linear",dataExtent:[i,o],visual:e.get("color")}),u=l.mapValueToVisual(s.getLayout().value),c=s.getModel().get(["itemStyle","color"]);c!=null?(s.setVisual("color",c),s.setVisual("style",{fill:c})):(s.setVisual("color",u),s.setVisual("style",{fill:u}))})}n.length&&w(n,function(s){var l=s.getModel().get("lineStyle");s.setVisual("style",l)})})}function lk(r){r.registerChartView(GR),r.registerSeriesModel(HR),r.registerLayout(WR),r.registerVisual(sk),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(a){a.setNodePosition(e.dataIndex,[e.localX,e.localY])})})}var J_=function(){function r(){}return r.prototype.getInitialData=function(e,t){var a,n=t.getComponent("xAxis",this.get("xAxisIndex")),i=t.getComponent("yAxis",this.get("yAxisIndex")),o=n.get("type"),s=i.get("type"),l;o==="category"?(e.layout="horizontal",a=n.getOrdinalMeta(),l=!0):s==="category"?(e.layout="vertical",a=i.getOrdinalMeta(),l=!0):e.layout=e.layout||"horizontal";var u=["x","y"],c=e.layout==="horizontal"?0:1,v=this._baseAxisDim=u[c],f=u[1-c],h=[n,i],p=h[c].get("type"),d=h[1-c].get("type"),g=e.data;if(g&&l){var y=[];w(g,function(x,b){var _;O(x)?(_=x.slice(),x.unshift(b)):O(x.value)?(_=B({},x),_.value=_.value.slice(),x.value.unshift(b)):_=x,y.push(_)}),e.data=y}var m=this.defaultValueDimensions,S=[{name:v,type:As(p),ordinalMeta:a,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:f,type:As(d),dimsDef:m.slice()}];return Pn(this,{coordDimensions:S,dimensionsCount:m.length+1,encodeDefaulter:Q(W0,S,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r}(),Q_=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}return e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},e}(Et);jt(Q_,J_,!0);const uk=Q_;var ck=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this.group,s=this._data;this._data||o.removeAll();var l=t.get("layout")==="horizontal"?1:0;i.diff(s).add(function(u){if(i.hasValue(u)){var c=i.getItemLayout(u),v=wg(c,i,u,l,!0);i.setItemGraphicEl(u,v),o.add(v)}}).update(function(u,c){var v=s.getItemGraphicEl(c);if(!i.hasValue(u)){o.remove(v);return}var f=i.getItemLayout(u);v?(We(v),t1(f,v,i,u)):v=wg(f,i,u,l),o.add(v),i.setItemGraphicEl(u,v)}).remove(function(u){var c=s.getItemGraphicEl(u);c&&o.remove(c)}).execute(),this._data=i},e.prototype.remove=function(t){var a=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(i){i&&a.remove(i)})},e.type="boxplot",e}(Mt),vk=function(){function r(){}return r}(),fk=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="boxplotBoxPath",a}return e.prototype.getDefaultShape=function(){return new vk},e.prototype.buildPath=function(t,a){var n=a.points,i=0;for(t.moveTo(n[i][0],n[i][1]),i++;i<4;i++)t.lineTo(n[i][0],n[i][1]);for(t.closePath();i<n.length;i++)t.moveTo(n[i][0],n[i][1]),i++,t.lineTo(n[i][0],n[i][1])},e}(It);function wg(r,e,t,a,n){var i=r.ends,o=new fk({shape:{points:n?hk(i,a,r):i}});return t1(r,o,e,t,n),o}function t1(r,e,t,a,n){var i=t.hostModel,o=Zi[n?"initProps":"updateProps"];o(e,{shape:{points:r.ends}},i,a),e.useStyle(t.getItemVisual(a,"style")),e.style.strokeNoScale=!0,e.z2=100;var s=t.getItemModel(a),l=s.getModel("emphasis");re(e,s),Nt(e,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function hk(r,e,t){return G(r,function(a){return a=a.slice(),a[e]=t.initBaseline,a})}const pk=ck;var yi=w;function dk(r){var e=gk(r);yi(e,function(t){var a=t.seriesModels;a.length&&(yk(t),yi(a,function(n,i){mk(n,t.boxOffsetList[i],t.boxWidthList[i])}))})}function gk(r){var e=[],t=[];return r.eachSeriesByType("boxplot",function(a){var n=a.getBaseAxis(),i=ct(t,n);i<0&&(i=t.length,t[i]=n,e[i]={axis:n,seriesModels:[]}),e[i].seriesModels.push(a)}),e}function yk(r){var e=r.axis,t=r.seriesModels,a=t.length,n=r.boxWidthList=[],i=r.boxOffsetList=[],o=[],s;if(e.type==="category")s=e.getBandWidth();else{var l=0;yi(t,function(p){l=Math.max(l,p.getData().count())});var u=e.getExtent();s=Math.abs(u[1]-u[0])/l}yi(t,function(p){var d=p.get("boxWidth");O(d)||(d=[d,d]),o.push([F(d[0],s)||0,F(d[1],s)||0])});var c=s*.8-2,v=c/a*.3,f=(c-v*(a-1))/a,h=f/2-c/2;yi(t,function(p,d){i.push(h),h+=v+f,n.push(Math.min(Math.max(f,o[d][0]),o[d][1]))})}function mk(r,e,t){var a=r.coordinateSystem,n=r.getData(),i=t/2,o=r.get("layout")==="horizontal"?0:1,s=1-o,l=["x","y"],u=n.mapDimension(l[o]),c=n.mapDimensionsAll(l[s]);if(u==null||c.length<5)return;for(var v=0;v<n.count();v++){var f=n.get(u,v),h=S(f,c[2],v),p=S(f,c[0],v),d=S(f,c[1],v),g=S(f,c[3],v),y=S(f,c[4],v),m=[];x(m,d,!1),x(m,g,!0),m.push(p,d,y,g),b(m,p),b(m,y),b(m,h),n.setItemLayout(v,{initBaseline:h[s],ends:m})}function S(_,A,T){var C=n.get(A,T),M=[];M[o]=_,M[s]=C;var D;return isNaN(_)||isNaN(C)?D=[NaN,NaN]:(D=a.dataToPoint(M),D[o]+=e),D}function x(_,A,T){var C=A.slice(),M=A.slice();C[o]+=i,M[o]-=i,T?_.push(C,M):_.push(M,C)}function b(_,A){var T=A.slice(),C=A.slice();T[o]-=i,C[o]+=i,_.push(T,C)}}function Sk(r,e){e=e||{};for(var t=[],a=[],n=e.boundIQR,i=n==="none"||n===0,o=0;o<r.length;o++){var s=Me(r[o].slice()),l=wl(s,.25),u=wl(s,.5),c=wl(s,.75),v=s[0],f=s[s.length-1],h=(n??1.5)*(c-l),p=i?v:Math.max(v,l-h),d=i?f:Math.min(f,c+h),g=e.itemNameFormatter,y=X(g)?g({value:o}):$(g)?g.replace("{value}",o+""):o+"";t.push([y,p,l,u,c,d]);for(var m=0;m<s.length;m++){var S=s[m];if(S<p||S>d){var x=[y,S];a.push(x)}}}return{boxData:t,outliers:a}}var xk={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==se){var a="";dt(a)}var n=Sk(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}};function _k(r){r.registerSeriesModel(uk),r.registerChartView(pk),r.registerLayout(dk),r.registerTransform(xk)}var bk=["color","borderColor"],wk=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,a,n){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,a,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,a):this._incrementalRenderNormal(t,a)},e.prototype.eachRendered=function(t){Wr(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var a=t.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},e.prototype._renderNormal=function(t){var a=t.getData(),n=this._data,i=this.group,o=a.getLayout("isSimpleBox"),s=t.get("clip",!0),l=t.coordinateSystem,u=l.getArea&&l.getArea();this._data||i.removeAll(),a.diff(n).add(function(c){if(a.hasValue(c)){var v=a.getItemLayout(c);if(s&&Ag(u,v))return;var f=Mu(v,c,!0);Lt(f,{shape:{points:v.ends}},t,c),Iu(f,a,c,o),i.add(f),a.setItemGraphicEl(c,f)}}).update(function(c,v){var f=n.getItemGraphicEl(v);if(!a.hasValue(c)){i.remove(f);return}var h=a.getItemLayout(c);if(s&&Ag(u,h)){i.remove(f);return}f?(ft(f,{shape:{points:h.ends}},t,c),We(f)):f=Mu(h),Iu(f,a,c,o),i.add(f),a.setItemGraphicEl(c,f)}).remove(function(c){var v=n.getItemGraphicEl(c);v&&i.remove(v)}).execute(),this._data=a},e.prototype._renderLarge=function(t){this._clear(),Tg(t,this.group);var a=t.get("clip",!0)?fl(t.coordinateSystem,!1,t):null;a?this.group.setClipPath(a):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,a){for(var n=a.getData(),i=n.getLayout("isSimpleBox"),o;(o=t.next())!=null;){var s=n.getItemLayout(o),l=Mu(s);Iu(l,n,o,i),l.incremental=!0,this.group.add(l),this._progressiveEls.push(l)}},e.prototype._incrementalRenderLarge=function(t,a){Tg(a,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e}(Mt),Ak=function(){function r(){}return r}(),Tk=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="normalCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new Ak},e.prototype.buildPath=function(t,a){var n=a.points;this.__simpleBox?(t.moveTo(n[4][0],n[4][1]),t.lineTo(n[6][0],n[6][1])):(t.moveTo(n[0][0],n[0][1]),t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]),t.lineTo(n[3][0],n[3][1]),t.closePath(),t.moveTo(n[4][0],n[4][1]),t.lineTo(n[5][0],n[5][1]),t.moveTo(n[6][0],n[6][1]),t.lineTo(n[7][0],n[7][1]))},e}(It);function Mu(r,e,t){var a=r.ends;return new Tk({shape:{points:t?Ck(a,r):a},z2:100})}function Ag(r,e){for(var t=!0,a=0;a<e.ends.length;a++)if(r.contain(e.ends[a][0],e.ends[a][1])){t=!1;break}return t}function Iu(r,e,t,a){var n=e.getItemModel(t);r.useStyle(e.getItemVisual(t,"style")),r.style.strokeNoScale=!0,r.__simpleBox=a,re(r,n)}function Ck(r,e){return G(r,function(t){return t=t.slice(),t[1]=e.initBaseline,t})}var Dk=function(){function r(){}return r}(),Lu=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new Dk},e.prototype.buildPath=function(t,a){for(var n=a.points,i=0;i<n.length;)if(this.__sign===n[i++]){var o=n[i++];t.moveTo(o,n[i++]),t.lineTo(o,n[i++])}else i+=3},e}(It);function Tg(r,e,t,a){var n=r.getData(),i=n.getLayout("largePoints"),o=new Lu({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});e.add(o);var s=new Lu({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});e.add(s);var l=new Lu({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});e.add(l),Pu(1,o,r),Pu(-1,s,r),Pu(0,l,r),a&&(o.incremental=!0,s.incremental=!0),t&&t.push(o,s)}function Pu(r,e,t,a){var n=t.get(["itemStyle",r>0?"borderColor":"borderColor0"])||t.get(["itemStyle",r>0?"color":"color0"]);r===0&&(n=t.get(["itemStyle","borderColorDoji"]));var i=t.getModel("itemStyle").getItemStyle(bk);e.useStyle(i),e.style.fill=null,e.style.stroke=n}const Mk=wk;var e1=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}return e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,a,n){var i=a.getItemLayout(t);return i&&n.rect(i.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e}(Et);jt(e1,J_,!0);const Ik=e1;function Lk(r){!r||!O(r.series)||w(r.series,function(e){j(e)&&e.type==="k"&&(e.type="candlestick")})}var Pk=["itemStyle","borderColor"],Ek=["itemStyle","borderColor0"],Rk=["itemStyle","borderColorDoji"],kk=["itemStyle","color"],Nk=["itemStyle","color0"],Ok={seriesType:"candlestick",plan:Mn(),performRawSeries:!0,reset:function(r,e){function t(i,o){return o.get(i>0?kk:Nk)}function a(i,o){return o.get(i===0?Rk:i>0?Pk:Ek)}if(!e.isSeriesFiltered(r)){var n=r.pipelineContext.large;return!n&&{progress:function(i,o){for(var s;(s=i.next())!=null;){var l=o.getItemModel(s),u=o.getItemLayout(s).sign,c=l.getItemStyle();c.fill=t(u,l),c.stroke=a(u,l)||c.fill;var v=o.ensureUniqueItemVisual(s,"style");B(v,c)}}}}}};const Vk=Ok;var Bk={seriesType:"candlestick",plan:Mn(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),a=zk(r,t),n=0,i=1,o=["x","y"],s=t.getDimensionIndex(t.mapDimension(o[n])),l=G(t.mapDimensionsAll(o[i]),t.getDimensionIndex,t),u=l[0],c=l[1],v=l[2],f=l[3];if(t.setLayout({candleWidth:a,isSimpleBox:a<=1.3}),s<0||l.length<4)return;return{progress:r.pipelineContext.large?p:h};function h(d,g){for(var y,m=g.getStore();(y=d.next())!=null;){var S=m.get(s,y),x=m.get(u,y),b=m.get(c,y),_=m.get(v,y),A=m.get(f,y),T=Math.min(x,b),C=Math.max(x,b),M=V(T,S),D=V(C,S),I=V(_,S),L=V(A,S),P=[];N(P,D,0),N(P,M,1),P.push(H(L),H(D),H(I),H(M));var E=g.getItemModel(y),k=!!E.get(["itemStyle","borderColorDoji"]);g.setItemLayout(y,{sign:Cg(m,y,x,b,c,k),initBaseline:x>b?D[i]:M[i],ends:P,brushRect:z(_,A,S)})}function V(Y,et){var rt=[];return rt[n]=et,rt[i]=Y,isNaN(et)||isNaN(Y)?[NaN,NaN]:e.dataToPoint(rt)}function N(Y,et,rt){var nt=et.slice(),pt=et.slice();nt[n]=Ko(nt[n]+a/2,1,!1),pt[n]=Ko(pt[n]-a/2,1,!0),rt?Y.push(nt,pt):Y.push(pt,nt)}function z(Y,et,rt){var nt=V(Y,rt),pt=V(et,rt);return nt[n]-=a/2,pt[n]-=a/2,{x:nt[0],y:nt[1],width:a,height:pt[1]-nt[1]}}function H(Y){return Y[n]=Ko(Y[n],1),Y}}function p(d,g){for(var y=je(d.count*4),m=0,S,x=[],b=[],_,A=g.getStore(),T=!!r.get(["itemStyle","borderColorDoji"]);(_=d.next())!=null;){var C=A.get(s,_),M=A.get(u,_),D=A.get(c,_),I=A.get(v,_),L=A.get(f,_);if(isNaN(C)||isNaN(I)||isNaN(L)){y[m++]=NaN,m+=3;continue}y[m++]=Cg(A,_,M,D,c,T),x[n]=C,x[i]=I,S=e.dataToPoint(x,null,b),y[m++]=S?S[0]:NaN,y[m++]=S?S[1]:NaN,x[i]=L,S=e.dataToPoint(x,null,b),y[m++]=S?S[1]:NaN}g.setLayout("largePoints",y)}}};function Cg(r,e,t,a,n,i){var o;return t>a?o=-1:t<a?o=1:o=i?0:e>0?r.get(n,e-1)<=a?1:-1:1,o}function zk(r,e){var t=r.getBaseAxis(),a,n=t.type==="category"?t.getBandWidth():(a=t.getExtent(),Math.abs(a[1]-a[0])/e.count()),i=F(St(r.get("barMaxWidth"),n),n),o=F(St(r.get("barMinWidth"),1),n),s=r.get("barWidth");return s!=null?F(s,n):Math.max(Math.min(n/2,i),o)}const Gk=Bk;function Fk(r){r.registerChartView(Mk),r.registerSeriesModel(Ik),r.registerPreprocessor(Lk),r.registerVisual(Vk),r.registerLayout(Gk)}function Dg(r,e){var t=e.rippleEffectColor||e.color;r.eachChild(function(a){a.attr({z:e.z,zlevel:e.zlevel,style:{stroke:e.brushType==="stroke"?t:null,fill:e.brushType==="fill"?t:null}})})}var Hk=function(r){R(e,r);function e(t,a){var n=r.call(this)||this,i=new Qi(t,a),o=new tt;return n.add(i),n.add(o),n.updateData(t,a),n}return e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var a=t.symbolType,n=t.color,i=t.rippleNumber,o=this.childAt(1),s=0;s<i;s++){var l=Ht(a,-1,-1,2,2,n);l.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var u=-s/i*t.period+t.effectOffset;l.animate("",!0).when(t.period,{scaleX:t.rippleScale/2,scaleY:t.rippleScale/2}).delay(u).start(),l.animateStyle(!0).when(t.period,{opacity:0}).delay(u).start(),o.add(l)}Dg(o,t)},e.prototype.updateEffectAnimation=function(t){for(var a=this._effectCfg,n=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var s=i[o];if(a[s]!==t[s]){this.stopEffectAnimation(),this.startEffectAnimation(t);return}}Dg(n,t)},e.prototype.highlight=function(){vr(this)},e.prototype.downplay=function(){fr(this)},e.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},e.prototype.updateData=function(t,a){var n=this,i=t.hostModel;this.childAt(0).updateData(t,a);var o=this.childAt(1),s=t.getItemModel(a),l=t.getItemVisual(a,"symbol"),u=Ln(t.getItemVisual(a,"symbolSize")),c=t.getItemVisual(a,"style"),v=c&&c.fill,f=s.getModel("emphasis");o.setScale(u),o.traverse(function(g){g.setStyle("fill",v)});var h=Ia(t.getItemVisual(a,"symbolOffset"),u);h&&(o.x=h[0],o.y=h[1]);var p=t.getItemVisual(a,"symbolRotate");o.rotation=(p||0)*Math.PI/180||0;var d={};d.showEffectOn=i.get("showEffectOn"),d.rippleScale=s.get(["rippleEffect","scale"]),d.brushType=s.get(["rippleEffect","brushType"]),d.period=s.get(["rippleEffect","period"])*1e3,d.effectOffset=a/t.count(),d.z=i.getShallow("z")||0,d.zlevel=i.getShallow("zlevel")||0,d.symbolType=l,d.color=v,d.rippleEffectColor=s.get(["rippleEffect","color"]),d.rippleNumber=s.get(["rippleEffect","number"]),d.showEffectOn==="render"?(this._effectCfg?this.updateEffectAnimation(d):this.startEffectAnimation(d),this._effectCfg=d):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(g){g==="emphasis"?d.showEffectOn!=="render"&&n.startEffectAnimation(d):g==="normal"&&d.showEffectOn!=="render"&&n.stopEffectAnimation()}),this._effectCfg=d,Nt(this,f.get("focus"),f.get("blurScope"),f.get("disabled"))},e.prototype.fadeOut=function(t){t&&t()},e}(tt);const Wk=Hk;var $k=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._symbolDraw=new to(Wk)},e.prototype.render=function(t,a,n){var i=t.getData(),o=this._symbolDraw;o.updateData(i,{clipShape:this._getClipShape(t)}),this.group.add(o.group)},e.prototype._getClipShape=function(t){var a=t.coordinateSystem,n=a&&a.getArea&&a.getArea();return t.get("clip",!0)?n:null},e.prototype.updateTransform=function(t,a,n){var i=t.getData();this.group.dirty();var o=eo("").reset(t,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},e.prototype._updateGroupTransform=function(t){var a=t.coordinateSystem;a&&a.getRoamTransform&&(this.group.transform=$b(a.getRoamTransform()),this.group.decomposeTransform())},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(!0)},e.type="effectScatter",e}(Mt);const Uk=$k;var Yk=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.getInitialData=function(t,a){return yr(null,this,{useEncodeDefaulter:!0})},e.prototype.brushSelector=function(t,a,n){return n.point(a.getItemLayout(t))},e.type="series.effectScatter",e.dependencies=["grid","polar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},e}(Et);const Zk=Yk;function Xk(r){r.registerChartView(Uk),r.registerSeriesModel(Zk),r.registerLayout(eo("effectScatter"))}var Kk=function(r){R(e,r);function e(t,a,n){var i=r.call(this)||this;return i.add(i.createLine(t,a,n)),i._updateEffectSymbol(t,a),i}return e.prototype.createLine=function(t,a,n){return new bf(t,a,n)},e.prototype._updateEffectSymbol=function(t,a){var n=t.getItemModel(a),i=n.getModel("effect"),o=i.get("symbolSize"),s=i.get("symbol");O(o)||(o=[o,o]);var l=t.getItemVisual(a,"style"),u=i.get("color")||l&&l.stroke,c=this.childAt(1);this._symbolType!==s&&(this.remove(c),c=Ht(s,-.5,-.5,1,1,u),c.z2=100,c.culling=!0,this.add(c)),c&&(c.setStyle("shadowColor",u),c.setStyle(i.getItemStyle(["color"])),c.scaleX=o[0],c.scaleY=o[1],c.setColor(u),this._symbolType=s,this._symbolScale=o,this._updateEffectAnimation(t,i,a))},e.prototype._updateEffectAnimation=function(t,a,n){var i=this.childAt(1);if(i){var o=t.getItemLayout(n),s=a.get("period")*1e3,l=a.get("loop"),u=a.get("roundTrip"),c=a.get("constantSpeed"),v=Jt(a.get("delay"),function(h){return h/t.count()*s/3});if(i.ignore=!0,this._updateAnimationPoints(i,o),c>0&&(s=this._getLineLength(i)/c*1e3),s!==this._period||l!==this._loop||u!==this._roundTrip){i.stopAnimation();var f=void 0;X(v)?f=v(n):f=v,i.__t>0&&(f=-s*i.__t),this._animateSymbol(i,s,f,l,u)}this._period=s,this._loop=l,this._roundTrip=u}},e.prototype._animateSymbol=function(t,a,n,i,o){if(a>0){t.__t=0;var s=this,l=t.animate("",i).when(o?a*2:a,{__t:o?2:1}).delay(n).during(function(){s._updateSymbolPosition(t)});i||l.done(function(){s.remove(t)}),l.start()}},e.prototype._getLineLength=function(t){return oa(t.__p1,t.__cp1)+oa(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,a){t.__p1=a[0],t.__p2=a[1],t.__cp1=a[2]||[(a[0][0]+a[1][0])/2,(a[0][1]+a[1][1])/2]},e.prototype.updateData=function(t,a,n){this.childAt(0).updateData(t,a,n),this._updateEffectSymbol(t,a)},e.prototype._updateSymbolPosition=function(t){var a=t.__p1,n=t.__p2,i=t.__cp1,o=t.__t<1?t.__t:2-t.__t,s=[t.x,t.y],l=s.slice(),u=Gm,c=Ub;s[0]=u(a[0],i[0],n[0],o),s[1]=u(a[1],i[1],n[1],o);var v=t.__t<1?c(a[0],i[0],n[0],o):c(n[0],i[0],a[0],1-o),f=t.__t<1?c(a[1],i[1],n[1],o):c(n[1],i[1],a[1],1-o);t.rotation=-Math.atan2(f,v)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT<t.__t?(t.scaleY=oa(l,s)*1.05,o===1&&(s[0]=l[0]+(s[0]-l[0])/2,s[1]=l[1]+(s[1]-l[1])/2)):t.__lastT===1?t.scaleY=2*oa(a,s):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=s[0],t.y=s[1]},e.prototype.updateLayout=function(t,a){this.childAt(0).updateLayout(t,a);var n=t.getItemModel(a).getModel("effect");this._updateEffectAnimation(t,n,a)},e}(tt);const r1=Kk;var qk=function(r){R(e,r);function e(t,a,n){var i=r.call(this)||this;return i._createPolyline(t,a,n),i}return e.prototype._createPolyline=function(t,a,n){var i=t.getItemLayout(a),o=new me({shape:{points:i}});this.add(o),this._updateCommonStl(t,a,n)},e.prototype.updateData=function(t,a,n){var i=t.hostModel,o=this.childAt(0),s={shape:{points:t.getItemLayout(a)}};ft(o,s,i,a),this._updateCommonStl(t,a,n)},e.prototype._updateCommonStl=function(t,a,n){var i=this.childAt(0),o=t.getItemModel(a),s=n&&n.emphasisLineStyle,l=n&&n.focus,u=n&&n.blurScope,c=n&&n.emphasisDisabled;if(!n||t.hasItemOption){var v=o.getModel("emphasis");s=v.getModel("lineStyle").getLineStyle(),c=v.get("disabled"),l=v.get("focus"),u=v.get("blurScope")}i.useStyle(t.getItemVisual(a,"style")),i.style.fill=null,i.style.strokeNoScale=!0;var f=i.ensureState("emphasis");f.style=s,Nt(this,l,u,c)},e.prototype.updateLayout=function(t,a){var n=this.childAt(0);n.setShape("points",t.getItemLayout(a))},e}(tt);const a1=qk;var jk=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}return e.prototype.createLine=function(t,a,n){return new a1(t,a,n)},e.prototype._updateAnimationPoints=function(t,a){this._points=a;for(var n=[0],i=0,o=1;o<a.length;o++){var s=a[o-1],l=a[o];i+=oa(s,l),n.push(i)}if(i===0){this._length=0;return}for(var o=0;o<n.length;o++)n[o]/=i;this._offsets=n,this._length=i},e.prototype._getLineLength=function(){return this._length},e.prototype._updateSymbolPosition=function(t){var a=t.__t<1?t.__t:2-t.__t,n=this._points,i=this._offsets,o=n.length;if(i){var s=this._lastFrame,l;if(a<this._lastFramePercent){var u=Math.min(s+1,o-1);for(l=u;l>=0&&!(i[l]<=a);l--);l=Math.min(l,o-2)}else{for(l=s;l<o&&!(i[l]>a);l++);l=Math.min(l-1,o-2)}var c=(a-i[l])/(i[l+1]-i[l]),v=n[l],f=n[l+1];t.x=v[0]*(1-c)+c*f[0],t.y=v[1]*(1-c)+c*f[1];var h=t.__t<1?f[0]-v[0]:v[0]-f[0],p=t.__t<1?f[1]-v[1]:v[1]-f[1];t.rotation=-Math.atan2(p,h)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=a,t.ignore=!1}},e}(r1);const Jk=jk;var Qk=function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r}(),tN=function(r){R(e,r);function e(t){var a=r.call(this,t)||this;return a._off=0,a.hoverDataIdx=-1,a}return e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new Qk},e.prototype.buildPath=function(t,a){var n=a.segs,i=a.curveness,o;if(a.polyline)for(o=this._off;o<n.length;){var s=n[o++];if(s>0){t.moveTo(n[o++],n[o++]);for(var l=1;l<s;l++)t.lineTo(n[o++],n[o++])}}else for(o=this._off;o<n.length;){var u=n[o++],c=n[o++],v=n[o++],f=n[o++];if(t.moveTo(u,c),i>0){var h=(u+v)/2-(c-f)*i,p=(c+f)/2-(v-u)*i;t.quadraticCurveTo(h,p,v,f)}else t.lineTo(v,f)}this.incremental&&(this._off=o,this.notClear=!0)},e.prototype.findDataIndex=function(t,a){var n=this.shape,i=n.segs,o=n.curveness,s=this.style.lineWidth;if(n.polyline)for(var l=0,u=0;u<i.length;){var c=i[u++];if(c>0)for(var v=i[u++],f=i[u++],h=1;h<c;h++){var p=i[u++],d=i[u++];if(uh(v,f,p,d,s,t,a))return l}l++}else for(var l=0,u=0;u<i.length;){var v=i[u++],f=i[u++],p=i[u++],d=i[u++];if(o>0){var g=(v+p)/2-(f-d)*o,y=(f+d)/2-(p-v)*o;if(Yb(v,f,g,y,p,d,s,t,a))return l}else if(uh(v,f,p,d,s,t,a))return l;l++}return-1},e.prototype.contain=function(t,a){var n=this.transformCoordToLocal(t,a),i=this.getBoundingRect();if(t=n[0],a=n[1],i.contain(t,a)){var o=this.hoverDataIdx=this.findDataIndex(t,a);return o>=0}return this.hoverDataIdx=-1,!1},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var a=this.shape,n=a.segs,i=1/0,o=1/0,s=-1/0,l=-1/0,u=0;u<n.length;){var c=n[u++],v=n[u++];i=Math.min(c,i),s=Math.max(c,s),o=Math.min(v,o),l=Math.max(v,l)}t=this._rect=new wt(i,o,s,l)}return t},e}(It),eN=function(){function r(){this.group=new tt}return r.prototype.updateData=function(e){this._clear();var t=this._create();t.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(t,e)},r.prototype.incrementalPrepareUpdate=function(e){this.group.removeAll(),this._clear()},r.prototype.incrementalUpdate=function(e,t){var a=this._newAdded[0],n=t.getLayout("linesPoints"),i=a&&a.shape.segs;if(i&&i.length<2e4){var o=i.length,s=new Float32Array(o+n.length);s.set(i),s.set(n,o),a.setShape({segs:s})}else{this._newAdded=[];var l=this._create();l.incremental=!0,l.setShape({segs:n}),this._setCommon(l,t),l.__startIndex=e.start}},r.prototype.remove=function(){this._clear()},r.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},r.prototype._create=function(){var e=new tN({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(e),this.group.add(e),e},r.prototype._setCommon=function(e,t,a){var n=t.hostModel;e.setShape({polyline:n.get("polyline"),curveness:n.get(["lineStyle","curveness"])}),e.useStyle(n.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var i=t.getVisual("style");i&&i.stroke&&e.setStyle("stroke",i.stroke),e.setStyle("fill",null);var o=q(e);o.seriesIndex=n.seriesIndex,e.on("mousemove",function(s){o.dataIndex=null;var l=e.hoverDataIdx;l>0&&(o.dataIndex=l+e.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}();const rN=eN;var aN={seriesType:"lines",plan:Mn(),reset:function(r){var e=r.coordinateSystem;if(e){var t=r.get("polyline"),a=r.pipelineContext.large;return{progress:function(n,i){var o=[];if(a){var s=void 0,l=n.end-n.start;if(t){for(var u=0,c=n.start;c<n.end;c++)u+=r.getLineCoordsCount(c);s=new Float32Array(l+u*2)}else s=new Float32Array(l*4);for(var v=0,f=[],c=n.start;c<n.end;c++){var h=r.getLineCoords(c,o);t&&(s[v++]=h);for(var p=0;p<h;p++)f=e.dataToPoint(o[p],!1,f),s[v++]=f[0],s[v++]=f[1]}i.setLayout("linesPoints",s)}else for(var c=n.start;c<n.end;c++){var d=i.getItemModel(c),h=r.getLineCoords(c,o),g=[];if(t)for(var y=0;y<h;y++)g.push(e.dataToPoint(o[y]));else{g[0]=e.dataToPoint(o[0]),g[1]=e.dataToPoint(o[1]);var m=d.get(["lineStyle","curveness"]);+m&&(g[2]=[(g[0][0]+g[1][0])/2-(g[0][1]-g[1][1])*m,(g[0][1]+g[1][1])/2-(g[1][0]-g[0][0])*m])}i.setItemLayout(c,g)}}}}}};const n1=aN;var nN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this._updateLineDraw(i,t),s=t.get("zlevel"),l=t.get(["effect","trailLength"]),u=n.getZr(),c=u.painter.getType()==="svg";c||u.painter.getLayer(s).clear(!0),this._lastZlevel!=null&&!c&&u.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&l>0&&(c||u.configLayer(s,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(l/10+.9,1),0)})),o.updateData(i);var v=t.get("clip",!0)&&fl(t.coordinateSystem,!1,t);v?this.group.setClipPath(v):this.group.removeClipPath(),this._lastZlevel=s,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,a,n){var i=t.getData(),o=this._updateLineDraw(i,t);o.incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},e.prototype.incrementalRender=function(t,a,n){this._lineDraw.incrementalUpdate(t,a.getData()),this._finished=t.end===a.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,a,n){var i=t.getData(),o=t.pipelineContext;if(!this._finished||o.large||o.progressiveRender)return{update:!0};var s=n1.reset(t,a,n);s.progress&&s.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},e.prototype._updateLineDraw=function(t,a){var n=this._lineDraw,i=this._showEffect(a),o=!!a.get("polyline"),s=a.pipelineContext,l=s.large;return(!n||i!==this._hasEffet||o!==this._isPolyline||l!==this._isLargeDraw)&&(n&&n.remove(),n=this._lineDraw=l?new rN:new wf(o?i?Jk:a1:i?r1:bf),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=l),this.group.add(n.group),n},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var a=t.getZr(),n=a.painter.getType()==="svg";!n&&this._lastZlevel!=null&&a.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,a){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(a)},e.prototype.dispose=function(t,a){this.remove(t,a)},e.type="lines",e}(Mt);const iN=nN;var oN=typeof Uint32Array>"u"?Array:Uint32Array,sN=typeof Float64Array>"u"?Array:Float64Array;function Mg(r){var e=r.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(r.data=G(e,function(t){var a=[t[0].coord,t[1].coord],n={coords:a};return t[0].name&&(n.fromName=t[0].name),t[1].name&&(n.toName=t[1].name),yv([n,t[0],t[1]])}))}var lN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}return e.prototype.init=function(t){t.data=t.data||[],Mg(t);var a=this._processFlatCoordsArray(t.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(t.data=new Float32Array(a.count)),r.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(t){if(Mg(t),t.data){var a=this._processFlatCoordsArray(t.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(t.data=new Float32Array(a.count))}r.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var a=this._processFlatCoordsArray(t.data);a.flatCoords&&(this._flatCoords?(this._flatCoords=ls(this._flatCoords,a.flatCoords),this._flatCoordsOffset=ls(this._flatCoordsOffset,a.flatCoordsOffset)):(this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset),t.data=new Float32Array(a.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var a=this.getData().getItemModel(t),n=a.option instanceof Array?a.option:a.getShallow("coords");return n},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[t*2+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,a){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[t*2],i=this._flatCoordsOffset[t*2+1],o=0;o<i;o++)a[o]=a[o]||[],a[o][0]=this._flatCoords[n+o*2],a[o][1]=this._flatCoords[n+o*2+1];return i}else{for(var s=this._getCoordsFromItemModel(t),o=0;o<s.length;o++)a[o]=a[o]||[],a[o][0]=s[o][0],a[o][1]=s[o][1];return s.length}},e.prototype._processFlatCoordsArray=function(t){var a=0;if(this._flatCoords&&(a=this._flatCoords.length),gt(t[0])){for(var n=t.length,i=new oN(n),o=new sN(n),s=0,l=0,u=0,c=0;c<n;){u++;var v=t[c++];i[l++]=s+a,i[l++]=v;for(var f=0;f<v;f++){var h=t[c++],p=t[c++];o[s++]=h,o[s++]=p}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,l),flatCoords:o,count:u}}return{flatCoordsOffset:null,flatCoords:null,count:t.length}},e.prototype.getInitialData=function(t,a){var n=new fe(["value"],this);return n.hasItemOption=!1,n.initData(t.data,[],function(i,o,s,l){if(i instanceof Array)return NaN;n.hasItemOption=!0;var u=i.value;if(u!=null)return u instanceof Array?u[l]:u}),n},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=i.getItemModel(t),s=o.get("name");if(s)return s;var l=o.get("fromName"),u=o.get("toName"),c=[];return l!=null&&c.push(l),u!=null&&c.push(u),qt("nameValue",{name:c.join(" > ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return t??(this.option.large?1e4:this.get("progressive"))},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return t??(this.option.large?2e4:this.get("progressiveThreshold"))},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),a=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&a>0?a+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e}(Et);const uN=lN;function Oo(r){return r instanceof Array||(r=[r,r]),r}var cN={seriesType:"lines",reset:function(r){var e=Oo(r.get("symbol")),t=Oo(r.get("symbolSize")),a=r.getData();a.setVisual("fromSymbol",e&&e[0]),a.setVisual("toSymbol",e&&e[1]),a.setVisual("fromSymbolSize",t&&t[0]),a.setVisual("toSymbolSize",t&&t[1]);function n(i,o){var s=i.getItemModel(o),l=Oo(s.getShallow("symbol",!0)),u=Oo(s.getShallow("symbolSize",!0));l[0]&&i.setItemVisual(o,"fromSymbol",l[0]),l[1]&&i.setItemVisual(o,"toSymbol",l[1]),u[0]&&i.setItemVisual(o,"fromSymbolSize",u[0]),u[1]&&i.setItemVisual(o,"toSymbolSize",u[1])}return{dataEach:a.hasItemOption?n:null}}};const vN=cN;function fN(r){r.registerChartView(iN),r.registerSeriesModel(uN),r.registerLayout(n1),r.registerVisual(vN)}var hN=256,pN=function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=us.createCanvas();this.canvas=e}return r.prototype.update=function(e,t,a,n,i,o){var s=this._getBrush(),l=this._getGradient(i,"inRange"),u=this._getGradient(i,"outOfRange"),c=this.pointSize+this.blurSize,v=this.canvas,f=v.getContext("2d"),h=e.length;v.width=t,v.height=a;for(var p=0;p<h;++p){var d=e[p],g=d[0],y=d[1],m=d[2],S=n(m);f.globalAlpha=S,f.drawImage(s,g-c,y-c)}if(!v.width||!v.height)return v;for(var x=f.getImageData(0,0,v.width,v.height),b=x.data,_=0,A=b.length,T=this.minOpacity,C=this.maxOpacity,M=C-T;_<A;){var S=b[_+3]/256,D=Math.floor(S*(hN-1))*4;if(S>0){var I=o(S)?l:u;S>0&&(S=S*M+T),b[_++]=I[D],b[_++]=I[D+1],b[_++]=I[D+2],b[_++]=I[D+3]*S*256}else _+=4}return f.putImageData(x,0,0),v},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=us.createCanvas()),t=this.pointSize+this.blurSize,a=t*2;e.width=a,e.height=a;var n=e.getContext("2d");return n.clearRect(0,0,a,a),n.shadowOffsetX=a,n.shadowBlur=this.blurSize,n.shadowColor="#000",n.beginPath(),n.arc(-t,t,this.pointSize,0,Math.PI*2,!0),n.closePath(),n.fill(),e},r.prototype._getGradient=function(e,t){for(var a=this._gradientPixels,n=a[t]||(a[t]=new Uint8ClampedArray(256*4)),i=[0,0,0,0],o=0,s=0;s<256;s++)e[t](s/255,!0,i),n[o++]=i[0],n[o++]=i[1],n[o++]=i[2],n[o++]=i[3];return n},r}();const dN=pN;function gN(r,e,t){var a=r[1]-r[0];e=G(e,function(o){return{interval:[(o.interval[0]-r[0])/a,(o.interval[1]-r[0])/a]}});var n=e.length,i=0;return function(o){var s;for(s=i;s<n;s++){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}if(s===n)for(s=i-1;s>=0;s--){var l=e[s].interval;if(l[0]<=o&&o<=l[1]){i=s;break}}return s>=0&&s<n&&t[s]}}function yN(r,e){var t=r[1]-r[0];return e=[(e[0]-r[0])/t,(e[1]-r[0])/t],function(a){return a>=e[0]&&a<=e[1]}}function Ig(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"}var mN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i;a.eachComponent("visualMap",function(s){s.eachTargetSeries(function(l){l===t&&(i=s)})}),this._progressiveEls=null,this.group.removeAll();var o=t.coordinateSystem;o.type==="cartesian2d"||o.type==="calendar"?this._renderOnCartesianAndCalendar(t,n,0,t.getData().count()):Ig(o)&&this._renderOnGeo(o,t,i,n)},e.prototype.incrementalPrepareRender=function(t,a,n){this.group.removeAll()},e.prototype.incrementalRender=function(t,a,n,i){var o=a.coordinateSystem;o&&(Ig(o)?this.render(a,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(a,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){Wr(this._progressiveEls||this.group,t)},e.prototype._renderOnCartesianAndCalendar=function(t,a,n,i,o){var s=t.coordinateSystem,l=Pa(s,"cartesian2d"),u,c,v,f;if(l){var h=s.getAxis("x"),p=s.getAxis("y");u=h.getBandWidth()+.5,c=p.getBandWidth()+.5,v=h.scale.getExtent(),f=p.scale.getExtent()}for(var d=this.group,g=t.getData(),y=t.getModel(["emphasis","itemStyle"]).getItemStyle(),m=t.getModel(["blur","itemStyle"]).getItemStyle(),S=t.getModel(["select","itemStyle"]).getItemStyle(),x=t.get(["itemStyle","borderRadius"]),b=Kt(t),_=t.getModel("emphasis"),A=_.get("focus"),T=_.get("blurScope"),C=_.get("disabled"),M=l?[g.mapDimension("x"),g.mapDimension("y"),g.mapDimension("value")]:[g.mapDimension("time"),g.mapDimension("value")],D=n;D<i;D++){var I=void 0,L=g.getItemVisual(D,"style");if(l){var P=g.get(M[0],D),E=g.get(M[1],D);if(isNaN(g.get(M[2],D))||isNaN(P)||isNaN(E)||P<v[0]||P>v[1]||E<f[0]||E>f[1])continue;var k=s.dataToPoint([P,E]);I=new ht({shape:{x:k[0]-u/2,y:k[1]-c/2,width:u,height:c},style:L})}else{if(isNaN(g.get(M[1],D)))continue;I=new ht({z2:1,shape:s.dataToRect([g.get(M[0],D)]).contentShape,style:L})}if(g.hasItemOption){var V=g.getItemModel(D),N=V.getModel("emphasis");y=N.getModel("itemStyle").getItemStyle(),m=V.getModel(["blur","itemStyle"]).getItemStyle(),S=V.getModel(["select","itemStyle"]).getItemStyle(),x=V.get(["itemStyle","borderRadius"]),A=N.get("focus"),T=N.get("blurScope"),C=N.get("disabled"),b=Kt(V)}I.shape.r=x;var z=t.getRawValue(D),H="-";z&&z[2]!=null&&(H=z[2]+""),ae(I,b,{labelFetcher:t,labelDataIndex:D,defaultOpacity:L.opacity,defaultText:H}),I.ensureState("emphasis").style=y,I.ensureState("blur").style=m,I.ensureState("select").style=S,Nt(I,A,T,C),I.incremental=o,o&&(I.states.emphasis.hoverLayer=!0),d.add(I),g.setItemGraphicEl(D,I),this._progressiveEls&&this._progressiveEls.push(I)}},e.prototype._renderOnGeo=function(t,a,n,i){var o=n.targetVisuals.inRange,s=n.targetVisuals.outOfRange,l=a.getData(),u=this._hmLayer||this._hmLayer||new dN;u.blurSize=a.get("blurSize"),u.pointSize=a.get("pointSize"),u.minOpacity=a.get("minOpacity"),u.maxOpacity=a.get("maxOpacity");var c=t.getViewRect().clone(),v=t.getRoamTransform();c.applyTransform(v);var f=Math.max(c.x,0),h=Math.max(c.y,0),p=Math.min(c.width+c.x,i.getWidth()),d=Math.min(c.height+c.y,i.getHeight()),g=p-f,y=d-h,m=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],S=l.mapArray(m,function(A,T,C){var M=t.dataToPoint([A,T]);return M[0]-=f,M[1]-=h,M.push(C),M}),x=n.getExtent(),b=n.type==="visualMap.continuous"?yN(x,n.option.range):gN(x,n.getPieceList(),n.option.selected);u.update(S,g,y,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:s.color.getColorMapper()},b);var _=new ke({style:{width:g,height:y,x:f,y:h,image:u.canvas},silent:!0});this.group.add(_)},e.type="heatmap",e}(Mt);const SN=mN;var xN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getInitialData=function(t,a){return yr(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=Xi.get(this.get("coordinateSystem"));if(t&&t.dimensions)return t.dimensions[0]==="lng"&&t.dimensions[1]==="lat"},e.type="series.heatmap",e.dependencies=["grid","geo","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},e}(Et);const _N=xN;function bN(r){r.registerChartView(SN),r.registerSeriesModel(_N)}var wN=["itemStyle","borderWidth"],Lg=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],Eu=new ur,AN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),c=u.isHorizontal(),v=l.master.getRect(),f={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[v.x,v.x+v.width],[v.y,v.y+v.height]],isHorizontal:c,valueDim:Lg[+c],categoryDim:Lg[1-+c]};return o.diff(s).add(function(h){if(o.hasValue(h)){var p=Eg(o,h),d=Pg(o,h,p,f),g=Rg(o,f,d);o.setItemGraphicEl(h,g),i.add(g),Ng(g,f,d)}}).update(function(h,p){var d=s.getItemGraphicEl(p);if(!o.hasValue(h)){i.remove(d);return}var g=Eg(o,h),y=Pg(o,h,g,f),m=c1(o,y);d&&m!==d.__pictorialShapeStr&&(i.remove(d),o.setItemGraphicEl(h,null),d=null),d?PN(d,f,y):d=Rg(o,f,y,!0),o.setItemGraphicEl(h,d),d.__pictorialSymbolMeta=y,i.add(d),Ng(d,f,y)}).remove(function(h){var p=s.getItemGraphicEl(h);p&&kg(s,h,p.__pictorialSymbolMeta.animationModel,p)}).execute(),this._data=o,this.group},e.prototype.remove=function(t,a){var n=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl(function(o){kg(i,q(o).dataIndex,t,o)}):n.removeAll()},e.type="pictorialBar",e}(Mt);function Pg(r,e,t,a){var n=r.getItemLayout(e),i=t.get("symbolRepeat"),o=t.get("symbolClip"),s=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=t.get("symbolPatternSize")||2,v=t.isAnimationEnabled(),f={dataIndex:e,layout:n,itemModel:t,symbolType:r.getItemVisual(e,"symbol")||"circle",style:r.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:i,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:v?t:null,hoverScale:v&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};TN(t,i,n,a,f),CN(r,e,n,i,o,f.boundingLength,f.pxSign,c,a,f),DN(t,f.symbolScale,u,a,f);var h=f.symbolSize,p=Ia(t.get("symbolOffset"),h);return MN(t,h,n,i,o,p,s,f.valueLineWidth,f.boundingLength,f.repeatCutLength,a,f),f}function TN(r,e,t,a,n){var i=a.valueDim,o=r.get("symbolBoundingData"),s=a.coordSys.getOtherAxis(a.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(t[i.wh]<=0),c;if(O(o)){var v=[Ru(s,o[0])-l,Ru(s,o[1])-l];v[1]<v[0]&&v.reverse(),c=v[u]}else o!=null?c=Ru(s,o)-l:e?c=a.coordSysExtent[i.index][u]-l:c=t[i.wh];n.boundingLength=c,e&&(n.repeatCutLength=t[i.wh]),n.pxSign=c>0?1:-1}function Ru(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function CN(r,e,t,a,n,i,o,s,l,u){var c=l.valueDim,v=l.categoryDim,f=Math.abs(t[v.wh]),h=r.getItemVisual(e,"symbolSize"),p;O(h)?p=h.slice():h==null?p=["100%","100%"]:p=[h,h],p[v.index]=F(p[v.index],f),p[c.index]=F(p[c.index],a?f:Math.abs(i)),u.symbolSize=p;var d=u.symbolScale=[p[0]/s,p[1]/s];d[c.index]*=(l.isHorizontal?-1:1)*o}function DN(r,e,t,a,n){var i=r.get(wN)||0;i&&(Eu.attr({scaleX:e[0],scaleY:e[1],rotation:t}),Eu.updateTransform(),i/=Eu.getLineScale(),i*=e[a.valueDim.index]),n.valueLineWidth=i||0}function MN(r,e,t,a,n,i,o,s,l,u,c,v){var f=c.categoryDim,h=c.valueDim,p=v.pxSign,d=Math.max(e[h.index]+s,0),g=d;if(a){var y=Math.abs(l),m=Jt(r.get("symbolMargin"),"15%")+"",S=!1;m.lastIndexOf("!")===m.length-1&&(S=!0,m=m.slice(0,m.length-1));var x=F(m,e[h.index]),b=Math.max(d+x*2,0),_=S?0:x*2,A=Ym(a),T=A?a:Og((y+_)/b),C=y-T*d;x=C/2/(S?T:Math.max(T-1,1)),b=d+x*2,_=S?0:x*2,!A&&a!=="fixed"&&(T=u?Og((Math.abs(u)+_)/b):0),g=T*b-_,v.repeatTimes=T,v.symbolMargin=x}var M=p*(g/2),D=v.pathPosition=[];D[f.index]=t[f.wh]/2,D[h.index]=o==="start"?M:o==="end"?l-M:l/2,i&&(D[0]+=i[0],D[1]+=i[1]);var I=v.bundlePosition=[];I[f.index]=t[f.xy],I[h.index]=t[h.xy];var L=v.barRectShape=B({},t);L[h.wh]=p*Math.max(Math.abs(t[h.wh]),Math.abs(D[h.index]+M)),L[f.wh]=t[f.wh];var P=v.clipShape={};P[f.xy]=-t[f.xy],P[f.wh]=c.ecSize[f.wh],P[h.xy]=0,P[h.wh]=t[h.wh]}function i1(r){var e=r.symbolPatternSize,t=Ht(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function o1(r,e,t,a){var n=r.__pictorialBundle,i=t.symbolSize,o=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,c=0,v=i[e.valueDim.index]+o+t.symbolMargin*2;for(Pf(r,function(d){d.__pictorialAnimationIndex=c,d.__pictorialRepeatTimes=u,c<u?en(d,null,p(c),t,a):en(d,null,{scaleX:0,scaleY:0},t,a,function(){n.remove(d)}),c++});c<u;c++){var f=i1(t);f.__pictorialAnimationIndex=c,f.__pictorialRepeatTimes=u,n.add(f);var h=p(c);en(f,{x:h.x,y:h.y,scaleX:0,scaleY:0},{scaleX:h.scaleX,scaleY:h.scaleY,rotation:h.rotation},t,a)}function p(d){var g=s.slice(),y=t.pxSign,m=d;return(t.symbolRepeatDirection==="start"?y>0:y<0)&&(m=u-1-d),g[l.index]=v*(m-u/2+.5)+s[l.index],{x:g[0],y:g[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function s1(r,e,t,a){var n=r.__pictorialBundle,i=r.__pictorialMainPath;i?en(i,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,a):(i=r.__pictorialMainPath=i1(t),n.add(i),en(i,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,a))}function l1(r,e,t){var a=B({},e.barRectShape),n=r.__pictorialBarRect;n?en(n,null,{shape:a},e,t):(n=r.__pictorialBarRect=new ht({z2:2,shape:a,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function u1(r,e,t,a){if(t.symbolClip){var n=r.__pictorialClipPath,i=B({},t.clipShape),o=e.valueDim,s=t.animationModel,l=t.dataIndex;if(n)ft(n,{shape:i},s,l);else{i[o.wh]=0,n=new ht({shape:i}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[o.wh]=t.clipShape[o.wh],Zi[a?"updateProps":"initProps"](n,{shape:u},s,l)}}}function Eg(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=IN,t.isAnimationEnabled=LN,t}function IN(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function LN(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Rg(r,e,t,a){var n=new tt,i=new tt;return n.add(i),n.__pictorialBundle=i,i.x=t.bundlePosition[0],i.y=t.bundlePosition[1],t.symbolRepeat?o1(n,e,t):s1(n,e,t),l1(n,t,a),u1(n,e,t,a),n.__pictorialShapeStr=c1(r,t),n.__pictorialSymbolMeta=t,n}function PN(r,e,t){var a=t.animationModel,n=t.dataIndex,i=r.__pictorialBundle;ft(i,{x:t.bundlePosition[0],y:t.bundlePosition[1]},a,n),t.symbolRepeat?o1(r,e,t,!0):s1(r,e,t,!0),l1(r,t,!0),u1(r,e,t,!0)}function kg(r,e,t,a){var n=a.__pictorialBarRect;n&&n.removeTextContent();var i=[];Pf(a,function(o){i.push(o)}),a.__pictorialMainPath&&i.push(a.__pictorialMainPath),a.__pictorialClipPath&&(t=null),w(i,function(o){Or(o,{scaleX:0,scaleY:0},t,e,function(){a.parent&&a.parent.remove(a)})}),r.setItemGraphicEl(e,null)}function c1(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function Pf(r,e,t){w(r.__pictorialBundle.children(),function(a){a!==r.__pictorialBarRect&&e.call(t,a)})}function en(r,e,t,a,n,i){e&&r.attr(e),a.symbolClip&&!n?t&&r.attr(t):t&&Zi[n?"updateProps":"initProps"](r,t,a.animationModel,a.dataIndex,i)}function Ng(r,e,t){var a=t.dataIndex,n=t.itemModel,i=n.getModel("emphasis"),o=i.getModel("itemStyle").getItemStyle(),s=n.getModel(["blur","itemStyle"]).getItemStyle(),l=n.getModel(["select","itemStyle"]).getItemStyle(),u=n.getShallow("cursor"),c=i.get("focus"),v=i.get("blurScope"),f=i.get("scale");Pf(r,function(d){if(d instanceof ke){var g=d.style;d.useStyle(B({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},t.style))}else d.useStyle(t.style);var y=d.ensureState("emphasis");y.style=o,f&&(y.scaleX=d.scaleX*1.1,y.scaleY=d.scaleY*1.1),d.ensureState("blur").style=s,d.ensureState("select").style=l,u&&(d.cursor=u),d.z2=t.z2});var h=e.valueDim.posDesc[+(t.boundingLength>0)],p=r.__pictorialBarRect;ae(p,Kt(n),{labelFetcher:e.seriesModel,labelDataIndex:a,defaultText:un(e.seriesModel.getData(),a),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:h}),Nt(r,c,v,i.get("disabled"))}function Og(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}const EN=AN;var RN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,r.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=$r(Ms.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(Ms);const kN=RN;function NN(r){r.registerChartView(EN),r.registerSeriesModel(kN),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,Q(lx,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,ux("pictorialBar"))}var ON=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._layers=[],t}return e.prototype.render=function(t,a,n){var i=t.getData(),o=this,s=this.group,l=t.getLayerSeries(),u=i.getLayout("layoutInfo"),c=u.rect,v=u.boundaryGap;s.x=0,s.y=c.y+v[0];function f(g){return g.name}var h=new hr(this._layersSeries||[],l,f,f),p=[];h.add(W(d,this,"add")).update(W(d,this,"update")).remove(W(d,this,"remove")).execute();function d(g,y,m){var S=o._layers;if(g==="remove"){s.remove(S[y]);return}for(var x=[],b=[],_,A=l[y].indices,T=0;T<A.length;T++){var C=i.getItemLayout(A[T]),M=C.x,D=C.y0,I=C.y;x.push(M,D),b.push(M,D+I),_=i.getItemVisual(A[T],"style")}var L,P=i.getItemLayout(A[0]),E=t.getModel("label"),k=E.get("margin"),V=t.getModel("emphasis");if(g==="add"){var N=p[y]=new tt;L=new Vx({shape:{points:x,stackedOnPoints:b,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),N.add(L),s.add(N),t.isAnimationEnabled()&&L.setClipPath(VN(L.getBoundingRect(),t,function(){L.removeClipPath()}))}else{var N=S[m];L=N.childAt(0),s.add(N),p[y]=N,ft(L,{shape:{points:x,stackedOnPoints:b}},t),We(L)}ae(L,Kt(t),{labelDataIndex:A[T-1],defaultText:i.getName(A[T-1]),inheritColor:_.fill},{normal:{verticalAlign:"middle"}}),L.setTextConfig({position:null,local:!0});var z=L.getTextContent();z&&(z.x=P.x-k,z.y=P.y0+P.y/2),L.useStyle(_),i.setItemGraphicEl(y,L),re(L,t),Nt(L,V.get("focus"),V.get("blurScope"),V.get("disabled"))}this._layersSeries=l,this._layers=p},e.type="themeRiver",e}(Mt);function VN(r,e,t){var a=new ht({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Lt(a,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},e,t),a}const BN=ON;var ku=2,zN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new ao(W(this.getData,this),W(this.getRawData,this))},e.prototype.fixData=function(t){var a=t.length,n={},i=cc(t,function(f){return n.hasOwnProperty(f[0]+"")||(n[f[0]+""]=-1),f[2]}),o=[];i.buckets.each(function(f,h){o.push({name:h,dataList:f})});for(var s=o.length,l=0;l<s;++l){for(var u=o[l].name,c=0;c<o[l].dataList.length;++c){var v=o[l].dataList[c][0]+"";n[v]=l}for(var v in n)n.hasOwnProperty(v)&&n[v]!==l&&(n[v]=l,t[a]=[v,0,u],a++)}return t},e.prototype.getInitialData=function(t,a){for(var n=this.getReferringComponents("singleAxis",Ft).models[0],i=n.get("type"),o=bt(t.data,function(p){return p[2]!==void 0}),s=this.fixData(o||[]),l=[],u=this.nameMap=Z(),c=0,v=0;v<s.length;++v)l.push(s[v][ku]),u.get(s[v][ku])||(u.set(s[v][ku],c),c++);var f=qi(s,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:As(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,h=new fe(f,this);return h.initData(s),h},e.prototype.getLayerSeries=function(){for(var t=this.getData(),a=t.count(),n=[],i=0;i<a;++i)n[i]=i;var o=t.mapDimension("single"),s=cc(n,function(u){return t.get("name",u)}),l=[];return s.buckets.each(function(u,c){u.sort(function(v,f){return t.get(o,v)-t.get(o,f)}),l.push({name:c,indices:u})}),l},e.prototype.getAxisTooltipData=function(t,a,n){O(t)||(t=t?[t]:[]);for(var i=this.getData(),o=this.getLayerSeries(),s=[],l=o.length,u,c=0;c<l;++c){for(var v=Number.MAX_VALUE,f=-1,h=o[c].indices.length,p=0;p<h;++p){var d=i.get(t[0],o[c].indices[p]),g=Math.abs(d-a);g<=v&&(u=d,v=g,f=o[c].indices[p])}s.push(f)}return{dataIndices:s,nestestValue:u}},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=i.getName(t),s=i.get(i.mapDimension("value"),t);return qt("nameValue",{name:o,value:s})},e.type="series.themeRiver",e.dependencies=["singleAxis"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},e}(Et);const GN=zN;function FN(r,e){r.eachSeriesByType("themeRiver",function(t){var a=t.getData(),n=t.coordinateSystem,i={},o=n.getRect();i.rect=o;var s=t.get("boundaryGap"),l=n.getAxis();if(i.boundaryGap=s,l.orient==="horizontal"){s[0]=F(s[0],o.height),s[1]=F(s[1],o.height);var u=o.height-s[0]-s[1];Vg(a,t,u)}else{s[0]=F(s[0],o.width),s[1]=F(s[1],o.width);var c=o.width-s[0]-s[1];Vg(a,t,c)}a.setLayout("layoutInfo",i)})}function Vg(r,e,t){if(r.count())for(var a=e.coordinateSystem,n=e.getLayerSeries(),i=r.mapDimension("single"),o=r.mapDimension("value"),s=G(n,function(g){return G(g.indices,function(y){var m=a.dataToPoint(r.get(i,y));return m[1]=r.get(o,y),m})}),l=HN(s),u=l.y0,c=t/l.max,v=n.length,f=n[0].indices.length,h,p=0;p<f;++p){h=u[p]*c,r.setItemLayout(n[0].indices[p],{layerIndex:0,x:s[0][p][0],y0:h,y:s[0][p][1]*c});for(var d=1;d<v;++d)h+=s[d-1][p][1]*c,r.setItemLayout(n[d].indices[p],{layerIndex:d,x:s[d][p][0],y0:h,y:s[d][p][1]*c})}}function HN(r){for(var e=r.length,t=r[0].length,a=[],n=[],i=0,o=0;o<t;++o){for(var s=0,l=0;l<e;++l)s+=r[l][o][1];s>i&&(i=s),a.push(s)}for(var u=0;u<t;++u)n[u]=(i-a[u])/2;i=0;for(var c=0;c<t;++c){var v=a[c]+n[c];v>i&&(i=v)}return{y0:n,max:i}}function WN(r){r.registerChartView(BN),r.registerSeriesModel(GN),r.registerLayout(FN),r.registerProcessor(ro("themeRiver"))}var $N=2,UN=4,YN=function(r){R(e,r);function e(t,a,n,i){var o=r.call(this)||this;o.z2=$N,o.textConfig={inside:!0},q(o).seriesIndex=a.seriesIndex;var s=new ut({z2:UN,silent:t.getModel().get(["label","silent"])});return o.setTextContent(s),o.updateData(!0,t,a,n,i),o}return e.prototype.updateData=function(t,a,n,i,o){this.node=a,a.piece=this,n=n||this._seriesModel,i=i||this._ecModel;var s=this;q(s).dataIndex=a.dataIndex;var l=a.getModel(),u=l.getModel("emphasis"),c=a.getLayout(),v=B({},c);v.label=null;var f=a.getVisual("style");f.lineJoin="bevel";var h=a.getVisual("decal");h&&(f.decal=sn(h,o));var p=va(l.getModel("itemStyle"),v,!0);B(v,p),w(pe,function(m){var S=s.ensureState(m),x=l.getModel([m,"itemStyle"]);S.style=x.getItemStyle();var b=va(x,v);b&&(S.shape=b)}),t?(s.setShape(v),s.shape.r=c.r0,Lt(s,{shape:{r:c.r}},n,a.dataIndex)):(ft(s,{shape:v},n),We(s)),s.useStyle(f),this._updateLabel(n);var d=l.getShallow("cursor");d&&s.attr("cursor",d),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;var g=u.get("focus"),y=g==="ancestor"?a.getAncestorsIndices():g==="descendant"?a.getDescendantIndices():g;Nt(this,y,u.get("blurScope"),u.get("disabled"))},e.prototype._updateLabel=function(t){var a=this,n=this.node.getModel(),i=n.getModel("label"),o=this.node.getLayout(),s=o.endAngle-o.startAngle,l=(o.startAngle+o.endAngle)/2,u=Math.cos(l),c=Math.sin(l),v=this,f=v.getTextContent(),h=this.node.dataIndex,p=i.get("minAngle")/180*Math.PI,d=i.get("show")&&!(p!=null&&Math.abs(s)<p);f.ignore=!d,w(xi,function(y){var m=y==="normal"?n.getModel("label"):n.getModel([y,"label"]),S=y==="normal",x=S?f:f.ensureState(y),b=t.getFormattedLabel(h,y);S&&(b=b||a.node.name),x.style=Ct(m,{},null,y!=="normal",!0),b&&(x.style.text=b);var _=m.get("show");_!=null&&!S&&(x.ignore=!_);var A=g(m,"position"),T=S?v:v.states[y],C=T.style.fill;T.textConfig={outsideFill:m.get("color")==="inherit"?C:null,inside:A!=="outside"};var M,D=g(m,"distance")||0,I=g(m,"align");A==="outside"?(M=o.r+D,I=l>Math.PI/2?"right":"left"):!I||I==="center"?(s===2*Math.PI&&o.r0===0?M=0:M=(o.r+o.r0)/2,I="center"):I==="left"?(M=o.r0+D,l>Math.PI/2&&(I="right")):I==="right"&&(M=o.r-D,l>Math.PI/2&&(I="left")),x.style.align=I,x.style.verticalAlign=g(m,"verticalAlign")||"middle",x.x=M*u+o.cx,x.y=M*c+o.cy;var L=g(m,"rotate"),P=0;L==="radial"?(P=sa(-l),P>Math.PI/2&&P<Math.PI*1.5&&(P+=Math.PI)):L==="tangential"?(P=Math.PI/2-l,P>Math.PI/2?P-=Math.PI:P<-Math.PI/2&&(P+=Math.PI)):gt(L)&&(P=L*Math.PI/180),x.rotation=sa(P)});function g(y,m){var S=y.get(m);return S??i.get(m)}f.dirtyStyle()},e}(Pe);const Bg=YN;var Qc="sunburstRootToNode",zg="sunburstHighlight",ZN="sunburstUnhighlight";function XN(r){r.registerAction({type:Qc,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},a);function a(n,i){var o=Pi(e,[Qc],n);if(o){var s=n.getViewRoot();s&&(e.direction=gf(s,o.node)?"rollUp":"drillDown"),n.resetViewRoot(o.node)}}}),r.registerAction({type:zg,update:"none"},function(e,t,a){e=B({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},n);function n(i){var o=Pi(e,[zg],i);o&&(e.dataIndex=o.node.dataIndex)}a.dispatchAction(B(e,{type:"highlight"}))}),r.registerAction({type:ZN,update:"updateView"},function(e,t,a){e=B({},e),a.dispatchAction(B(e,{type:"downplay"}))})}var KN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){var o=this;this.seriesModel=t,this.api=n,this.ecModel=a;var s=t.getData(),l=s.tree.root,u=t.getViewRoot(),c=this.group,v=t.get("renderLabelForZeroData"),f=[];u.eachNode(function(m){f.push(m)});var h=this._oldChildren||[];p(f,h),y(l,u),this._initEvents(),this._oldChildren=f;function p(m,S){if(m.length===0&&S.length===0)return;new hr(S,m,x,x).add(b).update(b).remove(Q(b,null)).execute();function x(_){return _.getId()}function b(_,A){var T=_==null?null:m[_],C=A==null?null:S[A];d(T,C)}}function d(m,S){if(!v&&m&&!m.getValue()&&(m=null),m!==l&&S!==l){if(S&&S.piece)m?(S.piece.updateData(!1,m,t,a,n),s.setItemGraphicEl(m.dataIndex,S.piece)):g(S);else if(m){var x=new Bg(m,t,a,n);c.add(x),s.setItemGraphicEl(m.dataIndex,x)}}}function g(m){m&&m.piece&&(c.remove(m.piece),m.piece=null)}function y(m,S){S.depth>0?(o.virtualPiece?o.virtualPiece.updateData(!1,m,t,a,n):(o.virtualPiece=new Bg(m,t,a,n),c.add(o.virtualPiece)),S.piece.off("click"),o.virtualPiece.on("click",function(x){o._rootToNode(S.parentNode)})):o.virtualPiece&&(c.remove(o.virtualPiece),o.virtualPiece=null)}},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",function(a){var n=!1,i=t.seriesModel.getViewRoot();i.eachNode(function(o){if(!n&&o.piece&&o.piece===a.target){var s=o.getModel().get("nodeClick");if(s==="rootToNode")t._rootToNode(o);else if(s==="link"){var l=o.getModel(),u=l.get("link");if(u){var c=l.get("target",!0)||"_blank";ms(u,c)}}n=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:Qc,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=t[0]-i.cx,s=t[1]-i.cy,l=Math.sqrt(o*o+s*s);return l<=i.r&&l>=i.r0}},e.type="sunburst",e}(Mt);const qN=KN;var jN=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.ignoreStyleOnData=!0,t}return e.prototype.getInitialData=function(t,a){var n={name:t.name,children:t.data};v1(n);var i=this._levelModels=G(t.levels||[],function(l){return new Dt(l,this,a)},this),o=df.createTree(n,this,s);function s(l){l.wrapMethod("getItemModel",function(u,c){var v=o.getNodeByDataIndex(c),f=i[v.depth];return f&&(u.parentModel=f),u})}return o.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(t){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(t);return a.treePathInfo=pl(n,this),a},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var a=this.getRawData().tree.root;(!t||t!==a&&!a.contains(t))&&(this._viewRoot=a)},e.prototype.enableAriaDecal=function(){d_(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e}(Et);function v1(r){var e=0;w(r.children,function(a){v1(a);var n=a.value;O(n)&&(n=n[0]),e+=n});var t=r.value;O(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),O(r.value)?r.value[0]=t:r.value=t}const JN=jN;var Gg=Math.PI/180;function QN(r,e,t){e.eachSeriesByType(r,function(a){var n=a.get("center"),i=a.get("radius");O(i)||(i=[0,i]),O(n)||(n=[n,n]);var o=t.getWidth(),s=t.getHeight(),l=Math.min(o,s),u=F(n[0],o),c=F(n[1],s),v=F(i[0],l/2),f=F(i[1],l/2),h=-a.get("startAngle")*Gg,p=a.get("minAngle")*Gg,d=a.getData().tree.root,g=a.getViewRoot(),y=g.depth,m=a.get("sort");m!=null&&f1(g,m);var S=0;w(g.children,function(k){!isNaN(k.getValue())&&S++});var x=g.getValue(),b=Math.PI/(x||S)*2,_=g.depth>0,A=g.height-(_?-1:1),T=(f-v)/(A||1),C=a.get("clockwise"),M=a.get("stillShowZeroSum"),D=C?1:-1,I=function(k,V){if(k){var N=V;if(k!==d){var z=k.getValue(),H=x===0&&M?b:z*b;H<p&&(H=p),N=V+D*H;var Y=k.depth-y-(_?-1:1),et=v+T*Y,rt=v+T*(Y+1),nt=a.getLevelModel(k);if(nt){var pt=nt.get("r0",!0),yt=nt.get("r",!0),vt=nt.get("radius",!0);vt!=null&&(pt=vt[0],yt=vt[1]),pt!=null&&(et=F(pt,l/2)),yt!=null&&(rt=F(yt,l/2))}k.setLayout({angle:H,startAngle:V,endAngle:N,clockwise:C,cx:u,cy:c,r0:et,r:rt})}if(k.children&&k.children.length){var at=0;w(k.children,function(At){at+=I(At,V+at)})}return N-V}};if(_){var L=v,P=v+T,E=Math.PI*2;d.setLayout({angle:E,startAngle:h,endAngle:h+E,clockwise:C,cx:u,cy:c,r0:L,r:P})}I(g,h)})}function f1(r,e){var t=r.children||[];r.children=tO(t,e),t.length&&w(r.children,function(a){f1(a,e)})}function tO(r,e){if(X(e)){var t=G(r,function(n,i){var o=n.getValue();return{params:{depth:n.depth,height:n.height,dataIndex:n.dataIndex,getValue:function(){return o}},index:i}});return t.sort(function(n,i){return e(n.params,i.params)}),G(t,function(n){return r[n.index]})}else{var a=e==="asc";return r.sort(function(n,i){var o=(n.getValue()-i.getValue())*(a?1:-1);return o===0?(n.dataIndex-i.dataIndex)*(a?-1:1):o})}}function eO(r){var e={};function t(a,n,i){for(var o=a;o&&o.depth>1;)o=o.parentNode;var s=n.getColorFromPalette(o.name||o.dataIndex+"",e);return a.depth>1&&$(s)&&(s=oc(s,(a.depth-1)/(i-1)*.5)),s}r.eachSeriesByType("sunburst",function(a){var n=a.getData(),i=n.tree;i.eachNode(function(o){var s=o.getModel(),l=s.getModel("itemStyle").getItemStyle();l.fill||(l.fill=t(o,a,i.root.height));var u=n.ensureUniqueItemVisual(o.dataIndex,"style");B(u,l)})})}function rO(r){r.registerChartView(qN),r.registerSeriesModel(JN),r.registerLayout(Q(QN,"sunburst")),r.registerProcessor(Q(ro,"sunburst")),r.registerVisual(eO),XN(r)}var Fg={color:"fill",borderColor:"stroke"},aO={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},sr=st(),nO=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,a){return yr(null,this)},e.prototype.getDataParams=function(t,a,n){var i=r.prototype.getDataParams.call(this,t,a);return n&&(i.info=sr(n).info),i},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e}(Et);const iO=nO;function oO(r,e){return e=e||[0,0],G(["x","y"],function(t,a){var n=this.getAxis(t),i=e[a],o=r[a]/2;return n.type==="category"?n.getBandWidth():Math.abs(n.dataToCoord(i-o)-n.dataToCoord(i+o))},this)}function sO(r){var e=r.master.getRect();return{coordSys:{type:"cartesian2d",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:W(oO,r)}}}function lO(r,e){return e=e||[0,0],G([0,1],function(t){var a=e[t],n=r[t]/2,i=[],o=[];return i[t]=a-n,o[t]=a+n,i[1-t]=o[1-t]=e[1-t],Math.abs(this.dataToPoint(i)[t]-this.dataToPoint(o)[t])},this)}function uO(r){var e=r.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:r.getZoom()},api:{coord:function(t){return r.dataToPoint(t)},size:W(lO,r)}}}function cO(r,e){var t=this.getAxis(),a=e instanceof Array?e[0]:e,n=(r instanceof Array?r[0]:r)/2;return t.type==="category"?t.getBandWidth():Math.abs(t.dataToCoord(a-n)-t.dataToCoord(a+n))}function vO(r){var e=r.getRect();return{coordSys:{type:"singleAxis",x:e.x,y:e.y,width:e.width,height:e.height},api:{coord:function(t){return r.dataToPoint(t)},size:W(cO,r)}}}function fO(r,e){return e=e||[0,0],G(["Radius","Angle"],function(t,a){var n="get"+t+"Axis",i=this[n](),o=e[a],s=r[a]/2,l=i.type==="category"?i.getBandWidth():Math.abs(i.dataToCoord(o-s)-i.dataToCoord(o+s));return t==="Angle"&&(l=l*Math.PI/180),l},this)}function hO(r){var e=r.getRadiusAxis(),t=r.getAngleAxis(),a=e.getExtent();return a[0]>a[1]&&a.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:a[1],r0:a[0]},api:{coord:function(n){var i=e.dataToRadius(n[0]),o=t.dataToAngle(n[1]),s=r.coordToPoint([i,o]);return s.push(i,o*Math.PI/180),s},size:W(fO,r)}}}function pO(r){var e=r.getRect(),t=r.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:t.start,end:t.end,weeks:t.weeks,dayCount:t.allDay}},api:{coord:function(a,n){return r.dataToPoint(a,n)}}}}function h1(r,e,t,a){return r&&(r.legacy||r.legacy!==!1&&!t&&!a&&e!=="tspan"&&(e==="text"||U(r,"text")))}function p1(r,e,t){var a=r,n,i,o;if(e==="text")o=a;else{o={},U(a,"text")&&(o.text=a.text),U(a,"rich")&&(o.rich=a.rich),U(a,"textFill")&&(o.fill=a.textFill),U(a,"textStroke")&&(o.stroke=a.textStroke),U(a,"fontFamily")&&(o.fontFamily=a.fontFamily),U(a,"fontSize")&&(o.fontSize=a.fontSize),U(a,"fontStyle")&&(o.fontStyle=a.fontStyle),U(a,"fontWeight")&&(o.fontWeight=a.fontWeight),i={type:"text",style:o,silent:!0},n={};var s=U(a,"textPosition");t?n.position=s?a.textPosition:"inside":s&&(n.position=a.textPosition),U(a,"textPosition")&&(n.position=a.textPosition),U(a,"textOffset")&&(n.offset=a.textOffset),U(a,"textRotation")&&(n.rotation=a.textRotation),U(a,"textDistance")&&(n.distance=a.textDistance)}return Hg(o,r),w(o.rich,function(l){Hg(l,l)}),{textConfig:n,textContent:i}}function Hg(r,e){e&&(e.font=e.textFont||e.font,U(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),U(e,"textAlign")&&(r.align=e.textAlign),U(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),U(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),U(e,"textWidth")&&(r.width=e.textWidth),U(e,"textHeight")&&(r.height=e.textHeight),U(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),U(e,"textPadding")&&(r.padding=e.textPadding),U(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),U(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),U(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),U(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),U(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),U(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),U(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function Wg(r,e,t){var a=r;a.textPosition=a.textPosition||t.position||"inside",t.offset!=null&&(a.textOffset=t.offset),t.rotation!=null&&(a.textRotation=t.rotation),t.distance!=null&&(a.textDistance=t.distance);var n=a.textPosition.indexOf("inside")>=0,i=r.fill||"#000";$g(a,e);var o=a.textFill==null;return n?o&&(a.textFill=t.insideFill||"#fff",!a.textStroke&&t.insideStroke&&(a.textStroke=t.insideStroke),!a.textStroke&&(a.textStroke=i),a.textStrokeWidth==null&&(a.textStrokeWidth=2)):(o&&(a.textFill=r.fill||t.outsideFill||"#000"),!a.textStroke&&t.outsideStroke&&(a.textStroke=t.outsideStroke)),a.text=e.text,a.rich=e.rich,w(e.rich,function(s){$g(s,s)}),a}function $g(r,e){e&&(U(e,"fill")&&(r.textFill=e.fill),U(e,"stroke")&&(r.textStroke=e.fill),U(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),U(e,"font")&&(r.font=e.font),U(e,"fontStyle")&&(r.fontStyle=e.fontStyle),U(e,"fontWeight")&&(r.fontWeight=e.fontWeight),U(e,"fontSize")&&(r.fontSize=e.fontSize),U(e,"fontFamily")&&(r.fontFamily=e.fontFamily),U(e,"align")&&(r.textAlign=e.align),U(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),U(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),U(e,"width")&&(r.textWidth=e.width),U(e,"height")&&(r.textHeight=e.height),U(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),U(e,"padding")&&(r.textPadding=e.padding),U(e,"borderColor")&&(r.textBorderColor=e.borderColor),U(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),U(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),U(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),U(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),U(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),U(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),U(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),U(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),U(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),U(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}var d1={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},Ug=Wt(d1);rn(mi,function(r,e){return r[e]=1,r},{});mi.join(", ");var ks=["","style","shape","extra"],fn=st();function Ef(r,e,t,a,n){var i=r+"Animation",o=xn(r,a,n)||{},s=fn(e).userDuring;return o.duration>0&&(o.during=s?W(SO,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=r),B(o,t[i]),o}function es(r,e,t,a){a=a||{};var n=a.dataIndex,i=a.isInit,o=a.clearStyle,s=t.isAnimationEnabled(),l=fn(r),u=e.style;l.userDuring=e.during;var c={},v={};if(_O(r,e,v),Zg("shape",e,v),Zg("extra",e,v),!i&&s&&(xO(r,e,c),Yg("shape",r,e,c),Yg("extra",r,e,c),bO(r,e,u,c)),v.style=u,dO(r,v,o),yO(r,e),s)if(i){var f={};w(ks,function(p){var d=p?e[p]:e;d&&d.enterFrom&&(p&&(f[p]=f[p]||{}),B(p?f[p]:f,d.enterFrom))});var h=Ef("enter",r,e,t,n);h.duration>0&&r.animateFrom(f,h)}else gO(r,e,n||0,t,c);g1(r,e),u?r.dirty():r.markRedraw()}function g1(r,e){for(var t=fn(r).leaveToProps,a=0;a<ks.length;a++){var n=ks[a],i=n?e[n]:e;i&&i.leaveTo&&(t||(t=fn(r).leaveToProps={}),n&&(t[n]=t[n]||{}),B(n?t[n]:t,i.leaveTo))}}function yl(r,e,t,a){if(r){var n=r.parent,i=fn(r).leaveToProps;if(i){var o=Ef("update",r,e,t,0);o.done=function(){n.remove(r),a&&a()},r.animateTo(i,o)}else n.remove(r),a&&a()}}function ma(r){return r==="all"}function dO(r,e,t){var a=e.style;if(!r.isGroup&&a){if(t){r.useStyle({});for(var n=r.animators,i=0;i<n.length;i++){var o=n[i];o.targetName==="style"&&o.changeTarget(r.style)}}r.setStyle(a)}e&&(e.style=null,e&&r.attr(e),e.style=a)}function gO(r,e,t,a,n){if(n){var i=Ef("update",r,e,a,t);i.duration>0&&r.animateFrom(n,i)}}function yO(r,e){U(e,"silent")&&(r.silent=e.silent),U(e,"ignore")&&(r.ignore=e.ignore),r instanceof Sa&&U(e,"invisible")&&(r.invisible=e.invisible),r instanceof It&&U(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var Ye={},mO={setTransform:function(r,e){return Ye.el[r]=e,this},getTransform:function(r){return Ye.el[r]},setShape:function(r,e){var t=Ye.el,a=t.shape||(t.shape={});return a[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=Ye.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=Ye.el,a=t.style;return a&&(a[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=Ye.el.style;if(e)return e[r]},setExtra:function(r,e){var t=Ye.el.extra||(Ye.el.extra={});return t[r]=e,this},getExtra:function(r){var e=Ye.el.extra;if(e)return e[r]}};function SO(){var r=this,e=r.el;if(e){var t=fn(e).userDuring,a=r.userDuring;if(t!==a){r.el=r.userDuring=null;return}Ye.el=e,a(mO)}}function Yg(r,e,t,a){var n=t[r];if(n){var i=e[r],o;if(i){var s=t.transition,l=n.transition;if(l)if(!o&&(o=a[r]={}),ma(l))B(o,i);else for(var u=_t(l),c=0;c<u.length;c++){var v=u[c],f=i[v];o[v]=f}else if(ma(s)||ct(s,r)>=0){!o&&(o=a[r]={});for(var h=Wt(i),c=0;c<h.length;c++){var v=h[c],f=i[v];wO(n[v],f)&&(o[v]=f)}}}}}function Zg(r,e,t){var a=e[r];if(a)for(var n=t[r]={},i=Wt(a),o=0;o<i.length;o++){var s=i[o];n[s]=Zb(a[s])}}function xO(r,e,t){for(var a=e.transition,n=ma(a)?mi:_t(a||[]),i=0;i<n.length;i++){var o=n[i];if(!(o==="style"||o==="shape"||o==="extra")){var s=r[o];t[o]=s}}}function _O(r,e,t){for(var a=0;a<Ug.length;a++){var n=Ug[a],i=d1[n],o=e[n];o&&(t[i[0]]=o[0],t[i[1]]=o[1])}for(var a=0;a<mi.length;a++){var s=mi[a];e[s]!=null&&(t[s]=e[s])}}function bO(r,e,t,a){if(t){var n=r.style,i;if(n){var o=t.transition,s=e.transition;if(o&&!ma(o)){var l=_t(o);!i&&(i=a.style={});for(var u=0;u<l.length;u++){var c=l[u],v=n[c];i[c]=v}}else if(r.getAnimationStyleProps&&(ma(s)||ma(o)||ct(s,"style")>=0)){var f=r.getAnimationStyleProps(),h=f?f.style:null;if(h){!i&&(i=a.style={});for(var p=Wt(t),u=0;u<p.length;u++){var c=p[u];if(h[c]){var v=n[c];i[c]=v}}}}}}}function wO(r,e){return pn(r)?r!==e:r!=null&&isFinite(r)}var y1=st(),AO=["percent","easing","shape","style","extra"];function m1(r){r.stopAnimation("keyframe"),r.attr(y1(r))}function Ns(r,e,t){if(!(!t.isAnimationEnabled()||!e)){if(O(e)){w(e,function(s){Ns(r,s,t)});return}var a=e.keyframes,n=e.duration;if(t&&n==null){var i=xn("enter",t,0);n=i&&i.duration}if(!(!a||!n)){var o=y1(r);w(ks,function(s){if(!(s&&!r[s])){var l;a.sort(function(u,c){return u.percent-c.percent}),w(a,function(u){var c=r.animators,v=s?u[s]:u;if(v){var f=Wt(v);if(s||(f=bt(f,function(d){return ct(AO,d)<0})),!!f.length){l||(l=r.animate(s,e.loop,!0),l.scope="keyframe");for(var h=0;h<c.length;h++)c[h]!==l&&c[h].targetName===l.targetName&&c[h].stopTracks(f);s&&(o[s]=o[s]||{});var p=s?o[s]:o;w(f,function(d){p[d]=((s?r[s]:r)||{})[d]}),l.whenWithKeys(n*u.percent,v,f,u.easing)}}}),l&&l.delay(e.delay||0).duration(n).start(e.easing)}})}}}var lr="emphasis",Ir="normal",Rf="blur",kf="select",Fr=[Ir,lr,Rf,kf],Nu={normal:["itemStyle"],emphasis:[lr,"itemStyle"],blur:[Rf,"itemStyle"],select:[kf,"itemStyle"]},Ou={normal:["label"],emphasis:[lr,"label"],blur:[Rf,"label"],select:[kf,"label"]},TO=["x","y"],CO="e\0\0",be={normal:{},emphasis:{},blur:{},select:{}},DO={cartesian2d:sO,geo:uO,single:vO,polar:hO,calendar:pO};function tv(r){return r instanceof It}function ev(r){return r instanceof Sa}function MO(r,e){e.copyTransform(r),ev(e)&&ev(r)&&(e.setStyle(r.style),e.z=r.z,e.z2=r.z2,e.zlevel=r.zlevel,e.invisible=r.invisible,e.ignore=r.ignore,tv(e)&&tv(r)&&e.setShape(r.shape))}var IO=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this._progressiveEls=null;var o=this._data,s=t.getData(),l=this.group,u=Xg(t,s,a,n);o||l.removeAll(),s.diff(o).add(function(v){Vu(n,null,v,u(v,i),t,l,s)}).remove(function(v){var f=o.getItemGraphicEl(v);f&&yl(f,sr(f).option,t)}).update(function(v,f){var h=o.getItemGraphicEl(f);Vu(n,h,v,u(v,i),t,l,s)}).execute();var c=t.get("clip",!0)?fl(t.coordinateSystem,!1,t):null;c?l.setClipPath(c):l.removeClipPath(),this._data=s},e.prototype.incrementalPrepareRender=function(t,a,n){this.group.removeAll(),this._data=null},e.prototype.incrementalRender=function(t,a,n,i,o){var s=a.getData(),l=Xg(a,s,n,i),u=this._progressiveEls=[];function c(h){h.isGroup||(h.incremental=!0,h.ensureState("emphasis").hoverLayer=!0)}for(var v=t.start;v<t.end;v++){var f=Vu(null,null,v,l(v,o),a,this.group,s);f&&(f.traverse(c),u.push(f))}},e.prototype.eachRendered=function(t){Wr(this._progressiveEls||this.group,t)},e.prototype.filterForExposedEvent=function(t,a,n,i){var o=a.element;if(o==null||n.name===o)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===o)return!0;return!1},e.type="custom",e}(Mt);const LO=IO;function Nf(r){var e=r.type,t;if(e==="path"){var a=r.shape,n=a.width!=null&&a.height!=null?{x:a.x||0,y:a.y||0,width:a.width,height:a.height}:null,i=_1(a);t=Ks(i,null,n,a.layout||"center"),sr(t).customPathData=i}else if(e==="image")t=new ke({}),sr(t).customImagePath=r.style.image;else if(e==="text")t=new ut({});else if(e==="group")t=new tt;else{if(e==="compoundPath")throw new Error('"compoundPath" is not supported yet.');var o=Mv(e);if(!o){var s="";dt(s)}t=new o}return sr(t).customGraphicType=e,t.name=r.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function Of(r,e,t,a,n,i,o){m1(e);var s=n&&n.normal.cfg;s&&e.setTextConfig(s),a&&a.transition==null&&(a.transition=TO);var l=a&&a.style;if(l){if(e.type==="text"){var u=l;U(u,"textFill")&&(u.fill=u.textFill),U(u,"textStroke")&&(u.stroke=u.textStroke)}var c=void 0,v=tv(e)?l.decal:null;r&&v&&(v.dirty=!0,c=sn(v,r)),l.__decalPattern=c}if(ev(e)&&l){var c=l.__decalPattern;c&&(l.decal=c)}es(e,a,i,{dataIndex:t,isInit:o,clearStyle:!0}),Ns(e,a.keyframeAnimation,i)}function S1(r,e,t,a,n){var i=e.isGroup?null:e,o=n&&n[r].cfg;if(i){var s=i.ensureState(r);if(a===!1){var l=i.getState(r);l&&(l.style=null)}else s.style=a||null;o&&(s.textConfig=o),Aa(i)}}function PO(r,e,t){if(!r.isGroup){var a=r,n=t.currentZ,i=t.currentZLevel;a.z=n,a.zlevel=i;var o=e.z2;o!=null&&(a.z2=o||0);for(var s=0;s<Fr.length;s++)EO(a,e,Fr[s])}}function EO(r,e,t){var a=t===Ir,n=a?e:Os(e,t),i=n?n.z2:null,o;i!=null&&(o=a?r:r.ensureState(t),o.z2=i||0)}function Xg(r,e,t,a){var n=r.get("renderItem"),i=r.coordinateSystem,o={};i&&(o=i.prepareCustoms?i.prepareCustoms(i):DO[i.type](i));for(var s=J({getWidth:a.getWidth,getHeight:a.getHeight,getZr:a.getZr,getDevicePixelRatio:a.getDevicePixelRatio,value:x,style:_,ordinalRawValue:b,styleEmphasis:A,visual:M,barLayout:D,currentSeriesIndices:I,font:L},o.api||{}),l={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:o.coordSys,dataInsideLength:e.count(),encode:RO(r.getData())},u,c,v={},f={},h={},p={},d=0;d<Fr.length;d++){var g=Fr[d];h[g]=r.getModel(Nu[g]),p[g]=r.getModel(Ou[g])}function y(P){return P===u?c||(c=e.getItemModel(P)):e.getItemModel(P)}function m(P,E){return e.hasItemOption?P===u?v[E]||(v[E]=y(P).getModel(Nu[E])):y(P).getModel(Nu[E]):h[E]}function S(P,E){return e.hasItemOption?P===u?f[E]||(f[E]=y(P).getModel(Ou[E])):y(P).getModel(Ou[E]):p[E]}return function(P,E){return u=P,c=null,v={},f={},n&&n(J({dataIndexInside:P,dataIndex:e.getRawIndex(P),actionType:E?E.type:null},l),s)};function x(P,E){return E==null&&(E=u),e.getStore().get(e.getDimensionIndex(P||0),E)}function b(P,E){E==null&&(E=u),P=P||0;var k=e.getDimensionInfo(P);if(!k){var V=e.getDimensionIndex(P);return V>=0?e.getStore().get(V,E):void 0}var N=e.get(k.name,E),z=k&&k.ordinalMeta;return z?z.categories[N]:N}function _(P,E){E==null&&(E=u);var k=e.getItemVisual(E,"style"),V=k&&k.fill,N=k&&k.opacity,z=m(E,Ir).getItemStyle();V!=null&&(z.fill=V),N!=null&&(z.opacity=N);var H={inheritColor:$(V)?V:"#000"},Y=S(E,Ir),et=Ct(Y,null,H,!1,!0);et.text=Y.getShallow("show")?St(r.getFormattedLabel(E,Ir),un(e,E)):null;var rt=gs(Y,H,!1);return C(P,z),z=Wg(z,et,rt),P&&T(z,P),z.legacy=!0,z}function A(P,E){E==null&&(E=u);var k=m(E,lr).getItemStyle(),V=S(E,lr),N=Ct(V,null,null,!0,!0);N.text=V.getShallow("show")?gn(r.getFormattedLabel(E,lr),r.getFormattedLabel(E,Ir),un(e,E)):null;var z=gs(V,null,!0);return C(P,k),k=Wg(k,N,z),P&&T(k,P),k.legacy=!0,k}function T(P,E){for(var k in E)U(E,k)&&(P[k]=E[k])}function C(P,E){P&&(P.textFill&&(E.textFill=P.textFill),P.textPosition&&(E.textPosition=P.textPosition))}function M(P,E){if(E==null&&(E=u),U(Fg,P)){var k=e.getItemVisual(E,"style");return k?k[Fg[P]]:null}if(U(aO,P))return e.getItemVisual(E,P)}function D(P){if(i.type==="cartesian2d"){var E=i.getBaseAxis();return LD(J({axis:E},P))}}function I(){return t.getCurrentSeriesIndices()}function L(P){return S0(P,t)}}function RO(r){var e={};return w(r.dimensions,function(t){var a=r.getDimensionInfo(t);if(!a.isExtraCoord){var n=a.coordDim,i=e[n]=e[n]||[];i[a.coordDimIndex]=r.getDimensionIndex(t)}}),e}function Vu(r,e,t,a,n,i,o){if(!a){i.remove(e);return}var s=Vf(r,e,t,a,n,i);return s&&o.setItemGraphicEl(t,s),s&&Nt(s,a.focus,a.blurScope,a.emphasisDisabled),s}function Vf(r,e,t,a,n,i){var o=-1,s=e;e&&x1(e,a,n)&&(o=ct(i.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=Nf(a),s&&MO(s,u)),a.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),be.normal.cfg=be.normal.conOpt=be.emphasis.cfg=be.emphasis.conOpt=be.blur.cfg=be.blur.conOpt=be.select.cfg=be.select.conOpt=null,be.isLegacy=!1,NO(u,t,a,n,l,be),kO(u,t,a,n,l),Of(r,u,t,a,be,n,l),U(a,"info")&&(sr(u).info=a.info);for(var c=0;c<Fr.length;c++){var v=Fr[c];if(v!==Ir){var f=Os(a,v),h=Bf(a,f,v);S1(v,u,f,h,be)}}return PO(u,a,n),a.type==="group"&&OO(r,u,t,a,n),o>=0?i.replaceAt(u,o):i.add(u),u}function x1(r,e,t){var a=sr(r),n=e.type,i=e.shape,o=e.style;return t.isUniversalTransitionEnabled()||n!=null&&n!==a.customGraphicType||n==="path"&&GO(i)&&_1(i)!==a.customPathData||n==="image"&&U(o,"image")&&o.image!==a.customImagePath}function kO(r,e,t,a,n){var i=t.clipPath;if(i===!1)r&&r.getClipPath()&&r.removeClipPath();else if(i){var o=r.getClipPath();o&&x1(o,i,a)&&(o=null),o||(o=Nf(i),r.setClipPath(o)),Of(null,o,e,i,null,a,n)}}function NO(r,e,t,a,n,i){if(!r.isGroup){Kg(t,null,i),Kg(t,lr,i);var o=i.normal.conOpt,s=i.emphasis.conOpt,l=i.blur.conOpt,u=i.select.conOpt;if(o!=null||s!=null||u!=null||l!=null){var c=r.getTextContent();if(o===!1)c&&r.removeTextContent();else{o=i.normal.conOpt=o||{type:"text"},c?c.clearStates():(c=Nf(o),r.setTextContent(c)),Of(null,c,e,o,null,a,n);for(var v=o&&o.style,f=0;f<Fr.length;f++){var h=Fr[f];if(h!==Ir){var p=i[h].conOpt;S1(h,c,p,Bf(o,p,h),null)}}v?c.dirty():c.markRedraw()}}}}function Kg(r,e,t){var a=e?Os(r,e):r,n=e?Bf(r,a,lr):r.style,i=r.type,o=a?a.textConfig:null,s=r.textContent,l=s?e?Os(s,e):s:null;if(n&&(t.isLegacy||h1(n,i,!!o,!!l))){t.isLegacy=!0;var u=p1(n,i,!e);!o&&u.textConfig&&(o=u.textConfig),!l&&u.textContent&&(l=u.textContent)}if(!e&&l){var c=l;!c.type&&(c.type="text")}var v=e?t[e]:t.normal;v.cfg=o,v.conOpt=l}function Os(r,e){return e?r?r[e]:null:r}function Bf(r,e,t){var a=e&&e.style;return a==null&&t===lr&&r&&(a=r.styleEmphasis),a}function OO(r,e,t,a,n){var i=a.children,o=i?i.length:0,s=a.$mergeChildren,l=s==="byName"||a.diffChildrenByName,u=s===!1;if(!(!o&&!l&&!u)){if(l){BO({api:r,oldChildren:e.children()||[],newChildren:i||[],dataIndex:t,seriesModel:n,group:e});return}u&&e.removeAll();for(var c=0;c<o;c++){var v=i[c],f=e.childAt(c);v?(v.ignore==null&&(v.ignore=!1),Vf(r,f,t,v,n,e)):f.ignore=!0}for(var h=e.childCount()-1;h>=c;h--){var p=e.childAt(h);VO(e,p,n)}}}function VO(r,e,t){e&&yl(e,sr(r).option,t)}function BO(r){new hr(r.oldChildren,r.newChildren,qg,qg,r).add(jg).update(jg).remove(zO).execute()}function qg(r,e){var t=r&&r.name;return t??CO+e}function jg(r,e){var t=this.context,a=r!=null?t.newChildren[r]:null,n=e!=null?t.oldChildren[e]:null;Vf(t.api,n,t.dataIndex,a,t.seriesModel,t.group)}function zO(r){var e=this.context,t=e.oldChildren[r];t&&yl(t,sr(t).option,e.seriesModel)}function _1(r){return r&&(r.pathData||r.d)}function GO(r){return r&&(U(r,"pathData")||U(r,"d"))}function FO(r){r.registerChartView(LO),r.registerSeriesModel(iO)}var na=st(),Jg=K,Bu=W,HO=function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(e,t,a,n){var i=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=a,!(!n&&this._lastValue===i&&this._lastStatus===o)){this._lastValue=i,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,i,e,t,a);var c=u.graphicKey;c!==this._lastGraphicKey&&this.clear(a),this._lastGraphicKey=c;var v=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new tt,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),a.getZr().add(s);else{var f=Q(Qg,t,v);this.updatePointerEl(s,u,f),this.updateLabelEl(s,u,f,t)}ey(s,t,!0),this._renderHandle(i)}},r.prototype.remove=function(e){this.clear(e)},r.prototype.dispose=function(e){this.clear(e)},r.prototype.determineAnimation=function(e,t){var a=t.get("animation"),n=e.axis,i=n.type==="category",o=t.get("snap");if(!o&&!i)return!1;if(a==="auto"||a==null){var s=this.animationThreshold;if(i&&n.getBandWidth()>s)return!0;if(o){var l=lf(e).seriesDataCount,u=n.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return a===!0},r.prototype.makeElOption=function(e,t,a,n,i){},r.prototype.createPointerEl=function(e,t,a,n){var i=t.pointer;if(i){var o=na(e).pointerEl=new Zi[i.type](Jg(t.pointer));e.add(o)}},r.prototype.createLabelEl=function(e,t,a,n){if(t.label){var i=na(e).labelEl=new ut(Jg(t.label));e.add(i),ty(i,n)}},r.prototype.updatePointerEl=function(e,t,a){var n=na(e).pointerEl;n&&t.pointer&&(n.setStyle(t.pointer.style),a(n,{shape:t.pointer.shape}))},r.prototype.updateLabelEl=function(e,t,a,n){var i=na(e).labelEl;i&&(i.setStyle(t.label.style),a(i,{x:t.label.x,y:t.label.y}),ty(i,n))},r.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,a=this._api.getZr(),n=this._handle,i=t.getModel("handle"),o=t.get("status");if(!i.get("show")||!o||o==="hide"){n&&a.remove(n),this._handle=null;return}var s;this._handle||(s=!0,n=this._handle=Yi(i.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Nr(u.event)},onmousedown:Bu(this._onHandleDragMove,this,0,0),drift:Bu(this._onHandleDragMove,this),ondragend:Bu(this._onHandleDragEnd,this)}),a.add(n)),ey(n,t,!1),n.setStyle(i.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=i.get("size");O(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,In(this,"_doDispatchAxisPointer",i.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},r.prototype._moveHandleToValue=function(e,t){Qg(this._axisPointerModel,!t&&this._moveAnimation,this._handle,zu(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(e,t){var a=this._handle;if(a){this._dragging=!0;var n=this.updateHandleTransform(zu(a),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=n,a.stopAnimation(),a.attr(zu(n)),na(a).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(e){var t=this._payloadInfo,a=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:a.axis.dim,axisIndex:a.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),a=this._group,n=this._handle;t&&a&&(this._lastGraphicKey=null,a&&t.remove(a),n&&t.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),Di(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(e,t,a){return a=a||0,{x:e[a],y:e[1-a],width:t[a],height:t[1-a]}},r}();function Qg(r,e,t,a){b1(na(t).lastProp,a)||(na(t).lastProp=a,e?ft(t,a,r):(t.stopAnimation(),t.attr(a)))}function b1(r,e){if(j(r)&&j(e)){var t=!0;return w(e,function(a,n){t=t&&b1(r[n],a)}),!!t}else return r===e}function ty(r,e){r[e.get(["label","show"])?"show":"hide"]()}function zu(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function ey(r,e,t){var a=e.get("z"),n=e.get("zlevel");r&&r.traverse(function(i){i.type!=="group"&&(a!=null&&(i.z=a),n!=null&&(i.zlevel=n),i.silent=t)})}const zf=HO;function Gf(r){var e=r.get("type"),t=r.getModel(e+"Style"),a;return e==="line"?(a=t.getLineStyle(),a.fill=null):e==="shadow"&&(a=t.getAreaStyle(),a.stroke=null),a}function w1(r,e,t,a,n){var i=t.get("value"),o=A1(i,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=An(s.get("padding")||0),u=s.getFont(),c=Us(o,u),v=n.position,f=c.width+l[1]+l[3],h=c.height+l[0]+l[2],p=n.align;p==="right"&&(v[0]-=f),p==="center"&&(v[0]-=f/2);var d=n.verticalAlign;d==="bottom"&&(v[1]-=h),d==="middle"&&(v[1]-=h/2),WO(v,f,h,a);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),r.label={x:v[0],y:v[1],style:Ct(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function WO(r,e,t,a){var n=a.getWidth(),i=a.getHeight();r[0]=Math.min(r[0]+e,n)-e,r[1]=Math.min(r[1]+t,i)-t,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function A1(r,e,t,a,n){r=e.scale.parse(r);var i=e.scale.getLabel({value:r},{precision:n.precision}),o=n.formatter;if(o){var s={value:rf(e,{value:r}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};w(a,function(l){var u=t.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,v=u&&u.getDataParams(c);v&&s.seriesData.push(v)}),$(o)?i=o.replace("{value}",i):X(o)&&(i=o(s))}return i}function Ff(r,e,t){var a=yn();return Fi(a,a,t.rotation),xa(a,a,t.position),He([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],a)}function T1(r,e,t,a,n,i){var o=pr.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=n.get(["label","margin"]),w1(e,a,n,i,{position:Ff(a.axis,r,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Hf(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function C1(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function ry(r,e,t,a,n,i){return{cx:r,cy:e,r0:t,r:a,startAngle:n,endAngle:i,clockwise:!0}}var $O=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis,l=s.grid,u=i.get("type"),c=ay(l,s).getOtherAxis(s).getGlobalExtent(),v=s.toGlobalCoord(s.dataToCoord(a,!0));if(u&&u!=="none"){var f=Gf(i),h=UO[u](s,v,c);h.style=f,t.graphicKey=h.type,t.pointer=h}var p=Vc(l.model,n);T1(a,t,p,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=Vc(a.axis.grid.model,a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=Ff(a.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,a,n,i){var o=n.axis,s=o.grid,l=o.getGlobalExtent(!0),u=ay(s,o).getOtherAxis(o).getGlobalExtent(),c=o.dim==="x"?0:1,v=[t.x,t.y];v[c]+=a[c],v[c]=Math.min(l[1],v[c]),v[c]=Math.max(l[0],v[c]);var f=(u[1]+u[0])/2,h=[f,f];h[c]=v[c];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:v[0],y:v[1],rotation:t.rotation,cursorPoint:h,tooltipOption:p[c]}},e}(zf);function ay(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var UO={line:function(r,e,t){var a=Hf([e,t[0]],[e,t[1]],ny(r));return{type:"Line",subPixelOptimize:!0,shape:a}},shadow:function(r,e,t){var a=Math.max(1,r.getBandWidth()),n=t[1]-t[0];return{type:"Rect",shape:C1([e-a/2,t[0]],[a,n],ny(r))}}};function ny(r){return r.dim==="x"?0:1}const YO=$O;var ZO=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(lt);const XO=ZO;var or=st(),KO=w;function D1(r,e,t){if(!kt.node){var a=e.getZr();or(a).records||(or(a).records={}),qO(a,e);var n=or(a).records[r]||(or(a).records[r]={});n.handler=t}}function qO(r,e){if(or(r).initialized)return;or(r).initialized=!0,t("click",Q(iy,"click")),t("mousemove",Q(iy,"mousemove")),t("globalout",JO);function t(a,n){r.on(a,function(i){var o=QO(e);KO(or(r).records,function(s){s&&n(s,i,o.dispatchAction)}),jO(o.pendings,e)})}}function jO(r,e){var t=r.showTip.length,a=r.hideTip.length,n;t?n=r.showTip[t-1]:a&&(n=r.hideTip[a-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function JO(r,e,t){r.handler("leave",null,t)}function iy(r,e,t,a){e.handler(r,t,a)}function QO(r){var e={showTip:[],hideTip:[]},t=function(a){var n=e[a.type];n?n.push(a):(a.dispatchAction=t,r.dispatchAction(a))};return{dispatchAction:t,pendings:e}}function rv(r,e){if(!kt.node){var t=e.getZr(),a=(or(t).records||{})[r];a&&(or(t).records[r]=null)}}var tV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=a.getComponent("tooltip"),o=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";D1("axisPointer",n,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,a){rv("axisPointer",a)},e.prototype.dispose=function(t,a){rv("axisPointer",a)},e.type="axisPointer",e}(Ot);const eV=tV;function M1(r,e){var t=[],a=r.seriesIndex,n;if(a==null||!(n=e.getSeriesByIndex(a)))return{point:[]};var i=n.getData(),o=ba(i,r);if(o==null||o<0||O(o))return{point:[]};var s=i.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)t=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),v=c.dim,f=u.dim,h=v==="x"||v==="radius"?1:0,p=i.mapDimension(f),d=[];d[h]=i.get(p,o),d[1-h]=i.get(i.getCalculationInfo("stackResultDimension"),o),t=l.dataToPoint(d)||[]}else t=l.dataToPoint(i.getValues(G(l.dimensions,function(y){return i.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),t=[g.x+g.width/2,g.y+g.height/2]}return{point:t,el:s}}var oy=st();function rV(r,e,t){var a=r.currTrigger,n=[r.x,r.y],i=r,o=r.dispatchAction||W(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){rs(n)&&(n=M1({seriesIndex:i.seriesIndex,dataIndex:i.dataIndex},e).point);var l=rs(n),u=i.axesInfo,c=s.axesInfo,v=a==="leave"||rs(n),f={},h={},p={list:[],map:{}},d={showPointer:Q(nV,h),showTooltip:Q(iV,p)};w(s.coordSysMap,function(y,m){var S=l||y.containPoint(n);w(s.coordSysAxesInfo[m],function(x,b){var _=x.axis,A=uV(u,x);if(!v&&S&&(!u||A)){var T=A&&A.value;T==null&&!l&&(T=_.pointToData(n)),T!=null&&sy(x,T,d,!1,f)}})});var g={};return w(c,function(y,m){var S=y.linkGroup;S&&!h[m]&&w(S.axesInfo,function(x,b){var _=h[b];if(x!==y&&_){var A=_.value;S.mapper&&(A=y.axis.scale.parse(S.mapper(A,ly(x),ly(y)))),g[y.key]=A}})}),w(g,function(y,m){sy(c[m],y,d,!0,f)}),oV(h,c,f),sV(p,n,r,o),lV(c,o,t),f}}function sy(r,e,t,a,n){var i=r.axis;if(!(i.scale.isBlank()||!i.containData(e))){if(!r.involveSeries){t.showPointer(r,e);return}var o=aV(e,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&n.seriesIndex==null&&B(n,s[0]),!a&&r.snap&&i.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,s),t.showTooltip(r,o,l)}}function aV(r,e){var t=e.axis,a=t.dim,n=r,i=[],o=Number.MAX_VALUE,s=-1;return w(e.seriesModels,function(l,u){var c=l.getData().mapDimensionsAll(a),v,f;if(l.getAxisTooltipData){var h=l.getAxisTooltipData(c,r,t);f=h.dataIndices,v=h.nestestValue}else{if(f=l.getData().indicesOfNearest(c[0],r,t.type==="category"?.5:null),!f.length)return;v=l.getData().get(c[0],f[0])}if(!(v==null||!isFinite(v))){var p=r-v,d=Math.abs(p);d<=o&&((d<o||p>=0&&s<0)&&(o=d,s=p,n=v,i.length=0),w(f,function(g){i.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:i,snapToValue:n}}function nV(r,e,t,a){r[e.key]={value:t,payloadBatch:a}}function iV(r,e,t,a){var n=t.payloadBatch,i=e.axis,o=i.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!n.length)){var l=e.coordSys.model,u=Li(l),c=r.map[u];c||(c=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(c)),c.dataByAxis.push({axisDim:i.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:a,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:n.slice()})}}function oV(r,e,t){var a=t.axesInfo=[];w(e,function(n,i){var o=n.axisPointerModel.option,s=r[i];s?(!n.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!n.useHandle&&(o.status="hide"),o.status==="show"&&a.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:o.value})})}function sV(r,e,t,a){if(rs(e)||!r.list.length){a({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};a({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function lV(r,e,t){var a=t.getZr(),n="axisPointerLastHighlights",i=oy(a)[n]||{},o=oy(a)[n]={};w(r,function(u,c){var v=u.axisPointerModel.option;v.status==="show"&&u.triggerEmphasis&&w(v.seriesDataIndices,function(f){var h=f.seriesIndex+" | "+f.dataIndex;o[h]=f})});var s=[],l=[];w(i,function(u,c){!o[c]&&l.push(u)}),w(o,function(u,c){!i[c]&&s.push(u)}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function uV(r,e){for(var t=0;t<(r||[]).length;t++){var a=r[t];if(e.axis.dim===a.axisDim&&e.axis.model.componentIndex===a.axisIndex)return a}}function ly(r){var e=r.axis.model,t={},a=t.axisDim=r.axis.dim;return t.axisIndex=t[a+"AxisIndex"]=e.componentIndex,t.axisName=t[a+"AxisName"]=e.name,t.axisId=t[a+"AxisId"]=e.id,t}function rs(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function oo(r){Ea.registerAxisPointerClass("CartesianAxisPointer",YO),r.registerComponentModel(XO),r.registerComponentView(eV),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!O(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=iL(e,t)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},rV)}function cV(r){it(a_),it(oo)}var vV=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s),c=u.getExtent(),v=s.dataToCoord(a),f=i.get("type");if(f&&f!=="none"){var h=Gf(i),p=hV[f](s,l,v,c);p.style=h,t.graphicKey=p.type,t.pointer=p}var d=i.get(["label","margin"]),g=fV(a,n,i,l,d);w1(t,n,i,o,g)},e}(zf);function fV(r,e,t,a,n){var i=e.axis,o=i.dataToCoord(r),s=a.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=a.getRadiusAxis().getExtent(),u,c,v;if(i.dim==="radius"){var f=yn();Fi(f,f,s),xa(f,f,[a.cx,a.cy]),u=He([o,-n],f);var h=e.getModel("axisLabel").get("rotate")||0,p=pr.innerTextLayout(s,h*Math.PI/180,-1);c=p.textAlign,v=p.textVerticalAlign}else{var d=l[1];u=a.coordToPoint([d+n,o]);var g=a.cx,y=a.cy;c=Math.abs(u[0]-g)/d<.3?"center":u[0]>g?"left":"right",v=Math.abs(u[1]-y)/d<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:c,verticalAlign:v}}var hV={line:function(r,e,t,a){return r.dim==="angle"?{type:"Line",shape:Hf(e.coordToPoint([a[0],t]),e.coordToPoint([a[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(r,e,t,a){var n=Math.max(1,r.getBandWidth()),i=Math.PI/180;return r.dim==="angle"?{type:"Sector",shape:ry(e.cx,e.cy,a[0],a[1],(-t-n/2)*i,(-t+n/2)*i)}:{type:"Sector",shape:ry(e.cx,e.cy,t-n/2,t+n/2,0,Math.PI*2)}}};const pV=vV;var dV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var a,n=this.ecModel;return n.eachComponent(t,function(i){i.getCoordSysModel()===this&&(a=i)},this),a},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(lt);const gV=dV;var Wf=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Ft).models[0]},e.type="polarAxis",e}(lt);jt(Wf,Ji);var yV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e}(Wf),mV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e}(Wf),$f=function(r){R(e,r);function e(t,a){return r.call(this,"radius",t,a)||this}return e.prototype.pointToData=function(t,a){return this.polar.pointToData(t,a)[this.dim==="radius"?0:1]},e}(Ue);$f.prototype.dataToRadius=Ue.prototype.dataToCoord;$f.prototype.radiusToData=Ue.prototype.coordToData;const SV=$f;var xV=st(),Uf=function(r){R(e,r);function e(t,a){return r.call(this,"angle",t,a||[0,360])||this}return e.prototype.pointToData=function(t,a){return this.polar.pointToData(t,a)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,a=t.getLabelModel(),n=t.scale,i=n.getExtent(),o=n.count();if(i[1]-i[0]<1)return 0;var s=i[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),c=Us(s==null?"":s+"",a.getFont(),"center","top"),v=Math.max(c.height,7),f=v/u;isNaN(f)&&(f=1/0);var h=Math.max(0,Math.floor(f)),p=xV(t.model),d=p.lastAutoInterval,g=p.lastTickCount;return d!=null&&g!=null&&Math.abs(d-h)<=1&&Math.abs(g-o)<=1&&d>h?h=d:(p.lastTickCount=o,p.lastAutoInterval=h),h},e}(Ue);Uf.prototype.dataToAngle=Ue.prototype.dataToCoord;Uf.prototype.angleToData=Ue.prototype.coordToData;const _V=Uf;var I1=["radius","angle"],bV=function(){function r(e){this.dimensions=I1,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new SV,this._angleAxis=new _V,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},r.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},r.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(e){var t=[],a=this._angleAxis,n=this._radiusAxis;return a.scale.type===e&&t.push(a),n.scale.type===e&&t.push(n),t},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},r.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},r.prototype.pointToData=function(e,t){var a=this.pointToCoord(e);return[this._radiusAxis.radiusToData(a[0],t),this._angleAxis.angleToData(a[1],t)]},r.prototype.pointToCoord=function(e){var t=e[0]-this.cx,a=e[1]-this.cy,n=this.getAngleAxis(),i=n.getExtent(),o=Math.min(i[0],i[1]),s=Math.max(i[0],i[1]);n.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+a*a);t/=l,a/=l;for(var u=Math.atan2(-a,t)/Math.PI*180,c=u<o?1:-1;u<o||u>s;)u+=c*360;return[l,u]},r.prototype.coordToPoint=function(e){var t=e[0],a=e[1]/180*Math.PI,n=Math.cos(a)*t+this.cx,i=-Math.sin(a)*t+this.cy;return[n,i]},r.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),a=t.getExtent().slice();a[0]>a[1]&&a.reverse();var n=e.getExtent(),i=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:a[0],r:a[1],startAngle:-n[0]*i,endAngle:-n[1]*i,clockwise:e.inverse,contain:function(o,s){var l=o-this.cx,u=s-this.cy,c=l*l+u*u-1e-4,v=this.r,f=this.r0;return c<=v*v&&c>=f*f}}},r.prototype.convertToPixel=function(e,t,a){var n=uy(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=uy(t);return n===this?this.pointToData(a):null},r}();function uy(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}const wV=bV;function AV(r,e,t){var a=e.get("center"),n=t.getWidth(),i=t.getHeight();r.cx=F(a[0],n),r.cy=F(a[1],i);var o=r.getRadiusAxis(),s=Math.min(n,i)/2,l=e.get("radius");l==null?l=[0,"100%"]:O(l)||(l=[0,l]);var u=[F(l[0],s),F(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function TV(r,e){var t=this,a=t.getAngleAxis(),n=t.getRadiusAxis();if(a.scale.setExtent(1/0,-1/0),n.scale.setExtent(1/0,-1/0),r.eachSeries(function(s){if(s.coordinateSystem===t){var l=s.getData();w(Ts(l,"radius"),function(u){n.scale.unionExtentFromData(l,u)}),w(Ts(l,"angle"),function(u){a.scale.unionExtentFromData(l,u)})}}),ln(a.scale,a.model),ln(n.scale,n.model),a.type==="category"&&!a.onBand){var i=a.getExtent(),o=360/a.scale.count();a.inverse?i[1]+=o:i[1]-=o,a.setExtent(i[0],i[1])}}function CV(r){return r.mainType==="angleAxis"}function cy(r,e){if(r.type=e.get("type"),r.scale=vl(e),r.onBand=e.get("boundaryGap")&&r.type==="category",r.inverse=e.get("inverse"),CV(e)){r.inverse=r.inverse!==e.get("clockwise");var t=e.get("startAngle");r.setExtent(t,t+(r.inverse?-360:360))}e.axis=r,r.model=e}var DV={dimensions:I1,create:function(r,e){var t=[];return r.eachComponent("polar",function(a,n){var i=new wV(n+"");i.update=TV;var o=i.getRadiusAxis(),s=i.getAngleAxis(),l=a.findAxisModel("radiusAxis"),u=a.findAxisModel("angleAxis");cy(o,l),cy(s,u),AV(i,a,e),t.push(i),a.coordinateSystem=i,i.model=a}),r.eachSeries(function(a){if(a.get("coordinateSystem")==="polar"){var n=a.getReferringComponents("polar",Ft).models[0];a.coordinateSystem=n.coordinateSystem}}),t}};const MV=DV;var IV=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Vo(r,e,t){e[1]>e[0]&&(e=e.slice().reverse());var a=r.coordToPoint([e[0],t]),n=r.coordToPoint([e[1],t]);return{x1:a[0],y1:a[1],x2:n[0],y2:n[1]}}function Bo(r){var e=r.getRadiusAxis();return e.inverse?0:1}function vy(r){var e=r[0],t=r[r.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&r.pop()}var LV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,a){if(this.group.removeAll(),!!t.get("show")){var n=t.axis,i=n.polar,o=i.getRadiusAxis().getExtent(),s=n.getTicksCoords(),l=n.getMinorTicksCoords(),u=G(n.getViewLabels(),function(c){c=K(c);var v=n.scale,f=v.type==="ordinal"?v.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=n.dataToCoord(f),c});vy(u),vy(s),w(IV,function(c){t.get([c,"show"])&&(!n.scale.isBlank()||c==="axisLine")&&PV[c](this.group,t,i,s,l,o,u)},this)}},e.type="angleAxis",e}(Ea),PV={axisLine:function(r,e,t,a,n,i){var o=e.getModel(["axisLine","lineStyle"]),s=Bo(t),l=s?0:1,u;i[l]===0?u=new ur({shape:{cx:t.cx,cy:t.cy,r:i[s]},style:o.getLineStyle(),z2:1,silent:!0}):u=new Hs({shape:{cx:t.cx,cy:t.cy,r:i[s],r0:i[l]},style:o.getLineStyle(),z2:1,silent:!0}),u.style.fill=null,r.add(u)},axisTick:function(r,e,t,a,n,i){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=i[Bo(t)],u=G(a,function(c){return new te({shape:Vo(t,[l,l+s],c.coord)})});r.add(Ce(u,{style:J(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,e,t,a,n,i){if(n.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=i[Bo(t)],c=[],v=0;v<n.length;v++)for(var f=0;f<n[v].length;f++)c.push(new te({shape:Vo(t,[u,u+l],n[v][f].coord)}));r.add(Ce(c,{style:J(s.getModel("lineStyle").getLineStyle(),J(o.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(r,e,t,a,n,i,o){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),c=e.get("triggerEvent");w(o,function(v,f){var h=l,p=v.tickValue,d=i[Bo(t)],g=t.coordToPoint([d+u,v.coord]),y=t.cx,m=t.cy,S=Math.abs(g[0]-y)/d<.3?"center":g[0]>y?"left":"right",x=Math.abs(g[1]-m)/d<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[p]){var b=s[p];j(b)&&b.textStyle&&(h=new Dt(b.textStyle,l,l.ecModel))}var _=new ut({silent:pr.isLabelSilent(e),style:Ct(h,{x:g[0],y:g[1],fill:h.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:v.formattedLabel,align:S,verticalAlign:x})});if(r.add(_),c){var A=pr.makeAxisEventDataBase(e);A.targetType="axisLabel",A.value=v.rawLabel,q(_).eventData=A}},this)},splitLine:function(r,e,t,a,n,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],v=0;v<a.length;v++){var f=u++%l.length;c[f]=c[f]||[],c[f].push(new te({shape:Vo(t,i,a[v].coord)}))}for(var v=0;v<c.length;v++)r.add(Ce(c[v],{style:J({stroke:l[v%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(r,e,t,a,n,i){if(n.length){for(var o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=[],u=0;u<n.length;u++)for(var c=0;c<n[u].length;c++)l.push(new te({shape:Vo(t,i,n[u][c].coord)}));r.add(Ce(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(r,e,t,a,n,i){if(a.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],v=Math.PI/180,f=-a[0].coord*v,h=Math.min(i[0],i[1]),p=Math.max(i[0],i[1]),d=e.get("clockwise"),g=1,y=a.length;g<=y;g++){var m=g===y?a[0].coord:a[g].coord,S=u++%l.length;c[S]=c[S]||[],c[S].push(new Pe({shape:{cx:t.cx,cy:t.cy,r0:h,r:p,startAngle:f,endAngle:-m*v,clockwise:d},silent:!0})),f=-m*v}for(var g=0;g<c.length;g++)r.add(Ce(c[g],{style:J({fill:l[g%l.length]},s.getAreaStyle()),silent:!0}))}}};const EV=LV;var RV=["axisLine","axisTickLabel","axisName"],kV=["splitLine","splitArea","minorSplitLine"],NV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,a){if(this.group.removeAll(),!!t.get("show")){var n=this._axisGroup,i=this._axisGroup=new tt;this.group.add(i);var o=t.axis,s=o.polar,l=s.getAngleAxis(),u=o.getTicksCoords(),c=o.getMinorTicksCoords(),v=l.getExtent()[0],f=o.getExtent(),h=VV(s,t,v),p=new pr(t,h);w(RV,p.add,p),i.add(p.getGroup()),Ui(n,i,t),w(kV,function(d){t.get([d,"show"])&&!o.scale.isBlank()&&OV[d](this.group,t,s,v,f,u,c)},this)}},e.type="radiusAxis",e}(Ea),OV={splitLine:function(r,e,t,a,n,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],v=0;v<i.length;v++){var f=u++%l.length;c[f]=c[f]||[],c[f].push(new ur({shape:{cx:t.cx,cy:t.cy,r:Math.max(i[v].coord,0)}}))}for(var v=0;v<c.length;v++)r.add(Ce(c[v],{style:J({stroke:l[v%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(r,e,t,a,n,i,o){if(o.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],c=0;c<o.length;c++)for(var v=0;v<o[c].length;v++)u.push(new ur({shape:{cx:t.cx,cy:t.cy,r:o[c][v].coord}}));r.add(Ce(u,{style:J({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(r,e,t,a,n,i){if(i.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],v=i[0].coord,f=1;f<i.length;f++){var h=u++%l.length;c[h]=c[h]||[],c[h].push(new Pe({shape:{cx:t.cx,cy:t.cy,r0:v,r:i[f].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),v=i[f].coord}for(var f=0;f<c.length;f++)r.add(Ce(c[f],{style:J({fill:l[f%l.length]},s.getAreaStyle()),silent:!0}))}}};function VV(r,e,t){return{position:[r.cx,r.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}const BV=NV;function L1(r){return r.get("stack")||"__ec_stack_"+r.seriesIndex}function P1(r,e){return e.dim+r.model.componentIndex}function zV(r,e,t){var a={},n=GV(bt(e.getSeriesByType(r),function(i){return!e.isSeriesFiltered(i)&&i.coordinateSystem&&i.coordinateSystem.type==="polar"}));e.eachSeriesByType(r,function(i){if(i.coordinateSystem.type==="polar"){var o=i.getData(),s=i.coordinateSystem,l=s.getBaseAxis(),u=P1(s,l),c=L1(i),v=n[u][c],f=v.offset,h=v.width,p=s.getOtherAxis(l),d=i.coordinateSystem.cx,g=i.coordinateSystem.cy,y=i.get("barMinHeight")||0,m=i.get("barMinAngle")||0;a[c]=a[c]||[];for(var S=o.mapDimension(p.dim),x=o.mapDimension(l.dim),b=Br(o,S),_=l.dim!=="radius"||!i.get("roundCap",!0),A=p.dataToCoord(0),T=0,C=o.count();T<C;T++){var M=o.get(S,T),D=o.get(x,T),I=M>=0?"p":"n",L=A;b&&(a[c][D]||(a[c][D]={p:A,n:A}),L=a[c][D][I]);var P=void 0,E=void 0,k=void 0,V=void 0;if(p.dim==="radius"){var N=p.dataToCoord(M)-A,z=l.dataToCoord(D);Math.abs(N)<y&&(N=(N<0?-1:1)*y),P=L,E=L+N,k=z-f,V=k-h,b&&(a[c][D][I]=E)}else{var H=p.dataToCoord(M,_)-A,Y=l.dataToCoord(D);Math.abs(H)<m&&(H=(H<0?-1:1)*m),P=Y+f,E=P+h,k=L,V=L+H,b&&(a[c][D][I]=V)}o.setItemLayout(T,{cx:d,cy:g,r0:P,r:E,startAngle:-k*Math.PI/180,endAngle:-V*Math.PI/180,clockwise:k>=V})}}})}function GV(r){var e={};w(r,function(a,n){var i=a.getData(),o=a.coordinateSystem,s=o.getBaseAxis(),l=P1(o,s),u=s.getExtent(),c=s.type==="category"?s.getBandWidth():Math.abs(u[1]-u[0])/i.count(),v=e[l]||{bandWidth:c,remainedWidth:c,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},f=v.stacks;e[l]=v;var h=L1(a);f[h]||v.autoWidthCount++,f[h]=f[h]||{width:0,maxWidth:0};var p=F(a.get("barWidth"),c),d=F(a.get("barMaxWidth"),c),g=a.get("barGap"),y=a.get("barCategoryGap");p&&!f[h].width&&(p=Math.min(v.remainedWidth,p),f[h].width=p,v.remainedWidth-=p),d&&(f[h].maxWidth=d),g!=null&&(v.gap=g),y!=null&&(v.categoryGap=y)});var t={};return w(e,function(a,n){t[n]={};var i=a.stacks,o=a.bandWidth,s=F(a.categoryGap,o),l=F(a.gap,1),u=a.remainedWidth,c=a.autoWidthCount,v=(u-s)/(c+(c-1)*l);v=Math.max(v,0),w(i,function(d,g){var y=d.maxWidth;y&&y<v&&(y=Math.min(y,u),d.width&&(y=Math.min(y,d.width)),u-=y,d.width=y,c--)}),v=(u-s)/(c+(c-1)*l),v=Math.max(v,0);var f=0,h;w(i,function(d,g){d.width||(d.width=v),h=d,f+=d.width*(1+l)}),h&&(f-=h.width*l);var p=-f/2;w(i,function(d,g){t[n][g]=t[n][g]||{offset:p,width:d.width},p+=d.width*(1+l)})}),t}var FV={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},HV={splitNumber:5},WV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e}(Ot);function $V(r){it(oo),Ea.registerAxisPointerClass("PolarAxisPointer",pV),r.registerCoordinateSystem("polar",MV),r.registerComponentModel(gV),r.registerComponentView(WV),cn(r,"angle",yV,FV),cn(r,"radius",mV,HV),r.registerComponentView(EV),r.registerComponentView(BV),r.registerLayout(Q(zV,"bar"))}function av(r,e){e=e||{};var t=r.coordinateSystem,a=r.axis,n={},i=a.position,o=a.orient,s=t.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};n.position=[o==="vertical"?u.vertical[i]:l[0],o==="horizontal"?u.horizontal[i]:l[3]];var c={horizontal:0,vertical:1};n.rotation=Math.PI/2*c[o];var v={top:-1,bottom:1,right:1,left:-1};n.labelDirection=n.tickDirection=n.nameDirection=v[i],r.get(["axisTick","inside"])&&(n.tickDirection=-n.tickDirection),Jt(e.labelInside,r.get(["axisLabel","inside"]))&&(n.labelDirection=-n.labelDirection);var f=e.rotate;return f==null&&(f=r.get(["axisLabel","rotate"])),n.labelRotation=i==="top"?-f:f,n.z2=1,n}var UV=["axisLine","axisTickLabel","axisName"],YV=["splitArea","splitLine"],ZV=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="SingleAxisPointer",t}return e.prototype.render=function(t,a,n,i){var o=this.group;o.removeAll();var s=this._axisGroup;this._axisGroup=new tt;var l=av(t),u=new pr(t,l);w(UV,u.add,u),o.add(this._axisGroup),o.add(u.getGroup()),w(YV,function(c){t.get([c,"show"])&&XV[c](this,this.group,this._axisGroup,t)},this),Ui(s,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)},e.prototype.remove=function(){t_(this)},e.type="singleAxis",e}(Ea),XV={splitLine:function(r,e,t,a){var n=a.axis;if(!n.scale.isBlank()){var i=a.getModel("splitLine"),o=i.getModel("lineStyle"),s=o.get("color");s=s instanceof Array?s:[s];for(var l=o.get("width"),u=a.coordinateSystem.getRect(),c=n.isHorizontal(),v=[],f=0,h=n.getTicksCoords({tickModel:i}),p=[],d=[],g=0;g<h.length;++g){var y=n.toGlobalCoord(h[g].coord);c?(p[0]=y,p[1]=u.y,d[0]=y,d[1]=u.y+u.height):(p[0]=u.x,p[1]=y,d[0]=u.x+u.width,d[1]=y);var m=new te({shape:{x1:p[0],y1:p[1],x2:d[0],y2:d[1]},silent:!0});nn(m.shape,l);var S=f++%s.length;v[S]=v[S]||[],v[S].push(m)}for(var x=o.getLineStyle(["color"]),g=0;g<v.length;++g)e.add(Ce(v[g],{style:J({stroke:s[g%s.length]},x),silent:!0}))}},splitArea:function(r,e,t,a){Qx(r,t,a,a)}};const KV=ZV;var E1=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type="singleAxis",e.layoutMode="box",e.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}}},e}(lt);jt(E1,Ji.prototype);const Gu=E1;var qV=function(r){R(e,r);function e(t,a,n,i,o){var s=r.call(this,t,a,n)||this;return s.type=i||"value",s.position=o||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.pointToData=function(t,a){return this.coordinateSystem.pointToData(t)[0]},e}(Ue);const jV=qV;var R1=["single"],JV=function(){function r(e,t,a){this.type="single",this.dimension="single",this.dimensions=R1,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,a)}return r.prototype._init=function(e,t,a){var n=this.dimension,i=new jV(n,vl(e),[0,0],e.get("type"),e.get("position")),o=i.type==="category";i.onBand=o&&e.get("boundaryGap"),i.inverse=e.get("inverse"),i.orient=e.get("orient"),e.axis=i,i.model=e,i.coordinateSystem=this,this._axis=i},r.prototype.update=function(e,t){e.eachSeries(function(a){if(a.coordinateSystem===this){var n=a.getData();w(n.mapDimensionsAll(this.dimension),function(i){this._axis.scale.unionExtentFromData(n,i)},this),ln(this._axis.scale,this._axis.model)}},this)},r.prototype.resize=function(e,t){this._rect=Yt({left:e.get("left"),top:e.get("top"),right:e.get("right"),bottom:e.get("bottom"),width:e.get("width"),height:e.get("height")},{width:t.getWidth(),height:t.getHeight()}),this._adjustAxis()},r.prototype.getRect=function(){return this._rect},r.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,a=t.isHorizontal(),n=a?[0,e.width]:[0,e.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),this._updateAxisTransform(t,a?e.x:e.y)},r.prototype._updateAxisTransform=function(e,t){var a=e.getExtent(),n=a[0]+a[1],i=e.isHorizontal();e.toGlobalCoord=i?function(o){return o+t}:function(o){return n-o+t},e.toLocalCoord=i?function(o){return o-t}:function(o){return n-o+t}},r.prototype.getAxis=function(){return this._axis},r.prototype.getBaseAxis=function(){return this._axis},r.prototype.getAxes=function(){return[this._axis]},r.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},r.prototype.containPoint=function(e){var t=this.getRect(),a=this.getAxis(),n=a.orient;return n==="horizontal"?a.contain(a.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:a.contain(a.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},r.prototype.pointToData=function(e){var t=this.getAxis();return[t.coordToData(t.toLocalCoord(e[t.orient==="horizontal"?0:1]))]},r.prototype.dataToPoint=function(e){var t=this.getAxis(),a=this.getRect(),n=[],i=t.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),n[i]=t.toGlobalCoord(t.dataToCoord(+e)),n[1-i]=i===0?a.y+a.height/2:a.x+a.width/2,n},r.prototype.convertToPixel=function(e,t,a){var n=fy(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=fy(t);return n===this?this.pointToData(a):null},r}();function fy(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function QV(r,e){var t=[];return r.eachComponent("singleAxis",function(a,n){var i=new JV(a,r,e);i.name="single_"+n,i.resize(a,e),a.coordinateSystem=i,t.push(i)}),r.eachSeries(function(a){if(a.get("coordinateSystem")==="singleAxis"){var n=a.getReferringComponents("singleAxis",Ft).models[0];a.coordinateSystem=n&&n.coordinateSystem}}),t}var tB={create:QV,dimensions:R1};const eB=tB;var hy=["x","y"],rB=["width","height"],aB=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,a,n,i,o){var s=n.axis,l=s.coordinateSystem,u=Fu(l,1-Vs(s)),c=l.dataToPoint(a)[0],v=i.get("type");if(v&&v!=="none"){var f=Gf(i),h=nB[v](s,c,u);h.style=f,t.graphicKey=h.type,t.pointer=h}var p=av(n);T1(a,t,p,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=av(a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=Ff(a.axis,t,i);return{x:o[0],y:o[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,a,n,i){var o=n.axis,s=o.coordinateSystem,l=Vs(o),u=Fu(s,l),c=[t.x,t.y];c[l]+=a[l],c[l]=Math.min(u[1],c[l]),c[l]=Math.max(u[0],c[l]);var v=Fu(s,1-l),f=(v[1]+v[0])/2,h=[f,f];return h[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:h,tooltipOption:{verticalAlign:"middle"}}},e}(zf),nB={line:function(r,e,t){var a=Hf([e,t[0]],[e,t[1]],Vs(r));return{type:"Line",subPixelOptimize:!0,shape:a}},shadow:function(r,e,t){var a=r.getBandWidth(),n=t[1]-t[0];return{type:"Rect",shape:C1([e-a/2,t[0]],[a,n],Vs(r))}}};function Vs(r){return r.isHorizontal()?0:1}function Fu(r,e){var t=r.getRect();return[t[hy[e]],t[hy[e]]+t[rB[e]]]}const iB=aB;var oB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e}(Ot);function sB(r){it(oo),Ea.registerAxisPointerClass("SingleAxisPointer",iB),r.registerComponentView(oB),r.registerComponentView(KV),r.registerComponentModel(Gu),cn(r,"single",Gu,Gu.defaultOption),r.registerCoordinateSystem("single",eB)}var lB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a,n){var i=Tn(t);r.prototype.init.apply(this,arguments),py(t,i)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),py(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(lt);function py(r,e){var t=r.cellSize,a;O(t)?a=t:a=r.cellSize=[t,t],a.length===1&&(a[1]=a[0]);var n=G([0,1],function(i){return MA(e,i)&&(a[i]="auto"),a[i]!=null&&a[i]!=="auto"});Vr(r,e,{type:"box",ignoreSize:n})}const uB=lB;var cB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){var i=this.group;i.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.getOrient(),u=a.getLocaleModel();this._renderDayRect(t,s,i),this._renderLines(t,s,l,i),this._renderYearText(t,s,l,i),this._renderMonthText(t,u,l,i),this._renderWeekText(t,u,s,l,i)},e.prototype._renderDayRect=function(t,a,n){for(var i=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),s=i.getCellWidth(),l=i.getCellHeight(),u=a.start.time;u<=a.end.time;u=i.getNextNDay(u,1).time){var c=i.dataToRect([u],!1).tl,v=new ht({shape:{x:c[0],y:c[1],width:s,height:l},cursor:"default",style:o});n.add(v)}},e.prototype._renderLines=function(t,a,n,i){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var v=a.start,f=0;v.time<=a.end.time;f++){p(v.formatedDate),f===0&&(v=s.getDateInfo(a.start.y+"-"+a.start.m));var h=v.date;h.setMonth(h.getMonth()+1),v=s.getDateInfo(h)}p(s.getNextNDay(a.end.time,1).formatedDate);function p(d){o._firstDayOfMonth.push(s.getDateInfo(d)),o._firstDayPoints.push(s.dataToRect([d],!1).tl);var g=o._getLinePointsOfOneWeek(t,d,n);o._tlpoints.push(g[0]),o._blpoints.push(g[g.length-1]),u&&o._drawSplitline(g,l,i)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,c,n),l,i),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,c,n),l,i)},e.prototype._getEdgesPoints=function(t,a,n){var i=[t[0].slice(),t[t.length-1].slice()],o=n==="horizontal"?0:1;return i[0][o]=i[0][o]-a/2,i[1][o]=i[1][o]+a/2,i},e.prototype._drawSplitline=function(t,a,n){var i=new me({z2:20,shape:{points:t},style:a});n.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,a,n){for(var i=t.coordinateSystem,o=i.getDateInfo(a),s=[],l=0;l<7;l++){var u=i.getNextNDay(o.time,l),c=i.dataToRect([u.time],!1);s[2*u.day]=c.tl,s[2*u.day+1]=c[n==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,a){return $(t)&&t?TA(t,a):X(t)?t(a):a.nameMap},e.prototype._yearTextPositionControl=function(t,a,n,i,o){var s=a[0],l=a[1],u=["center","bottom"];i==="bottom"?(l+=o,u=["center","top"]):i==="left"?s-=o:i==="right"?(s+=o,u=["center","top"]):l-=o;var c=0;return(i==="left"||i==="right")&&(c=Math.PI/2),{rotation:c,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,a,n,i){var o=t.getModel("yearLabel");if(o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=n!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,v=(u[0][1]+u[1][1])/2,f=n==="horizontal"?0:1,h={top:[c,u[f][1]],bottom:[c,u[1-f][1]],left:[u[1-f][0],v],right:[u[f][0],v]},p=a.start.y;+a.end.y>+a.start.y&&(p=p+"-"+a.end.y);var d=o.get("formatter"),g={start:a.start.y,end:a.end.y,nameMap:p},y=this._formatterLabel(d,g),m=new ut({z2:30,style:Ct(o,{text:y})});m.attr(this._yearTextPositionControl(m,h[l],n,l,s)),i.add(m)}},e.prototype._monthTextPositionControl=function(t,a,n,i,o){var s="left",l="top",u=t[0],c=t[1];return n==="horizontal"?(c=c+o,a&&(s="center"),i==="start"&&(l="bottom")):(u=u+o,a&&(l="middle"),i==="start"&&(s="right")),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,a,n,i){var o=t.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),c=o.get("align"),v=[this._tlpoints,this._blpoints];(!s||$(s))&&(s&&(a=mc(s)||a),s=a.get(["time","monthAbbr"])||[]);var f=u==="start"?0:1,h=n==="horizontal"?0:1;l=u==="start"?-l:l;for(var p=c==="center",d=0;d<v[f].length-1;d++){var g=v[f][d].slice(),y=this._firstDayOfMonth[d];if(p){var m=this._firstDayPoints[d];g[h]=(m[h]+v[0][d+1][h])/2}var S=o.get("formatter"),x=s[+y.m-1],b={yyyy:y.y,yy:(y.y+"").slice(2),MM:y.m,M:+y.m,nameMap:x},_=this._formatterLabel(S,b),A=new ut({z2:30,style:B(Ct(o,{text:_}),this._monthTextPositionControl(g,p,n,u,l))});i.add(A)}}},e.prototype._weekTextPositionControl=function(t,a,n,i,o){var s="center",l="middle",u=t[0],c=t[1],v=n==="start";return a==="horizontal"?(u=u+i+(v?1:-1)*o[0]/2,s=v?"right":"left"):(c=c+i+(v?1:-1)*o[1]/2,l=v?"bottom":"top"),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,a,n,i,o){var s=t.getModel("dayLabel");if(s.get("show")){var l=t.coordinateSystem,u=s.get("position"),c=s.get("nameMap"),v=s.get("margin"),f=l.getFirstDayOfWeek();if(!c||$(c)){c&&(a=mc(c)||a);var h=a.get(["time","dayOfWeekShort"]);c=h||G(a.get(["time","dayOfWeekAbbr"]),function(b){return b[0]})}var p=l.getNextNDay(n.end.time,7-n.lweek).time,d=[l.getCellWidth(),l.getCellHeight()];v=F(v,Math.min(d[1],d[0])),u==="start"&&(p=l.getNextNDay(n.start.time,-(7+n.fweek)).time,v=-v);for(var g=0;g<7;g++){var y=l.getNextNDay(p,g),m=l.dataToRect([y.time],!1).center,S=g;S=Math.abs((g+f)%7);var x=new ut({z2:30,style:B(Ct(s,{text:c[S]}),this._weekTextPositionControl(m,i,u,v,d))});o.add(x)}}},e.type="calendar",e}(Ot);const vB=cB;var Hu=864e5,fB=function(){function r(e,t,a){this.type="calendar",this.dimensions=r.dimensions,this.getDimensionsInfo=r.getDimensionsInfo,this._model=e}return r.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},r.prototype.getRangeInfo=function(){return this._rangeInfo},r.prototype.getModel=function(){return this._model},r.prototype.getRect=function(){return this._rect},r.prototype.getCellWidth=function(){return this._sw},r.prototype.getCellHeight=function(){return this._sh},r.prototype.getOrient=function(){return this._orient},r.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},r.prototype.getDateInfo=function(e){e=tr(e);var t=e.getFullYear(),a=e.getMonth()+1,n=a<10?"0"+a:""+a,i=e.getDate(),o=i<10?"0"+i:""+i,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:n,d:o,day:s,time:e.getTime(),formatedDate:t+"-"+n+"-"+o,date:e}},r.prototype.getNextNDay=function(e,t){return t=t||0,t===0?this.getDateInfo(e):(e=new Date(this.getDateInfo(e).time),e.setDate(e.getDate()+t),this.getDateInfo(e))},r.prototype.update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var a=this._rangeInfo.weeks||1,n=["width","height"],i=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[a,7]:[7,a];w([0,1],function(v){c(i,v)&&(o[n[v]]=i[v]*s[v])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=Yt(o,l);w([0,1],function(v){c(i,v)||(i[v]=u[n[v]]/s[v])});function c(v,f){return v[f]!=null&&v[f]!=="auto"}this._sw=i[0],this._sh=i[1]},r.prototype.dataToPoint=function(e,t){O(e)&&(e=e[0]),t==null&&(t=!0);var a=this.getDateInfo(e),n=this._rangeInfo,i=a.formatedDate;if(t&&!(a.time>=n.start.time&&a.time<n.end.time+Hu))return[NaN,NaN];var o=a.day,s=this._getRangeInfo([n.start.time,i]).nthWeek;return this._orient==="vertical"?[this._rect.x+o*this._sw+this._sw/2,this._rect.y+s*this._sh+this._sh/2]:[this._rect.x+s*this._sw+this._sw/2,this._rect.y+o*this._sh+this._sh/2]},r.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},r.prototype.dataToRect=function(e,t){var a=this.dataToPoint(e,t);return{contentShape:{x:a[0]-(this._sw-this._lineWidth)/2,y:a[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},center:a,tl:[a[0]-this._sw/2,a[1]-this._sh/2],tr:[a[0]+this._sw/2,a[1]-this._sh/2],br:[a[0]+this._sw/2,a[1]+this._sh/2],bl:[a[0]-this._sw/2,a[1]+this._sh/2]}},r.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,a=Math.floor((e[1]-this._rect.y)/this._sh)+1,n=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(a,t-1,n):this._getDateByWeeksAndDay(t,a-1,n)},r.prototype.convertToPixel=function(e,t,a){var n=dy(t);return n===this?n.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=dy(t);return n===this?n.pointToData(a):null},r.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},r.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(O(e)&&e.length===1&&(e=e[0]),O(e))t=e;else{var a=e.toString();if(/^\d{4}$/.test(a)&&(t=[a+"-01-01",a+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(a)){var n=this.getDateInfo(a),i=n.date;i.setMonth(i.getMonth()+1);var o=this.getNextNDay(i,-1);t=[n.formatedDate,o.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(a)&&(t=[a,a])}if(!t)return e;var s=this._getRangeInfo(t);return s.start.time>s.end.time&&t.reverse(),t},r.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],a;t[0].time>t[1].time&&(a=!0,t.reverse());var n=Math.floor(t[1].time/Hu)-Math.floor(t[0].time/Hu)+1,i=new Date(t[0].time),o=i.getDate(),s=t[1].date.getDate();i.setDate(o+n-1);var l=i.getDate();if(l!==s)for(var u=i.getTime()-t[1].time>0?1:-1;(l=i.getDate())!==s&&(i.getTime()-t[1].time)*u>0;)n-=u,i.setDate(l-u);var c=Math.floor((n+t[0].day+6)/7),v=a?-c+1:c-1;return a&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:n,weeks:c,nthWeek:v,fweek:t[0].day,lweek:t[1].day}},r.prototype._getDateByWeeksAndDay=function(e,t,a){var n=this._getRangeInfo(a);if(e>n.weeks||e===0&&t<n.fweek||e===n.weeks&&t>n.lweek)return null;var i=(e-1)*7-n.fweek+t,o=new Date(n.start.time);return o.setDate(+n.start.d+i),this.getDateInfo(o)},r.create=function(e,t){var a=[];return e.eachComponent("calendar",function(n){var i=new r(n);a.push(i),n.coordinateSystem=i}),e.eachSeries(function(n){n.get("coordinateSystem")==="calendar"&&(n.coordinateSystem=a[n.get("calendarIndex")||0])}),a},r.dimensions=["time","value"],r}();function dy(r){var e=r.calendarModel,t=r.seriesModel,a=e?e.coordinateSystem:t?t.coordinateSystem:null;return a}const hB=fB;function pB(r){r.registerComponentModel(uB),r.registerComponentView(vB),r.registerCoordinateSystem("calendar",hB)}function dB(r,e){var t=r.existing;if(e.id=r.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var a=e.parentOption;a?e.parentId=a.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function gy(r,e){var t;return w(e,function(a){r[a]!=null&&r[a]!=="auto"&&(t=!0)}),t}function gB(r,e,t){var a=B({},t),n=r[e],i=t.$action||"merge";i==="merge"?n?(ot(n,a,!0),Vr(n,a,{ignoreSize:!0}),B0(t,n),zo(t,n),zo(t,n,"shape"),zo(t,n,"style"),zo(t,n,"extra"),t.clipPath=n.clipPath):r[e]=a:i==="replace"?r[e]=a:i==="remove"&&n&&(r[e]=null)}var k1=["transition","enterFrom","leaveTo"],yB=k1.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function zo(r,e,t){if(t&&(!r[t]&&e[t]&&(r[t]={}),r=r[t],e=e[t]),!(!r||!e))for(var a=t?k1:yB,n=0;n<a.length;n++){var i=a[n];r[i]==null&&e[i]!=null&&(r[i]=e[i])}}function mB(r,e){if(r&&(r.hv=e.hv=[gy(e,["left","right"]),gy(e,["top","bottom"])],r.type==="group")){var t=r,a=e;t.width==null&&(t.width=a.width=0),t.height==null&&(t.height=a.height=0)}}var SB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,a){var n=this.option.elements;this.option.elements=null,r.prototype.mergeOption.call(this,t,a),this.option.elements=n},e.prototype.optionUpdated=function(t,a){var n=this.option,i=(a?n:t).elements,o=n.elements=a?[]:n.elements,s=[];this._flatten(i,s,null);var l=jm(o,s,"normalMerge"),u=this._elOptionsToUpdate=[];w(l,function(c,v){var f=c.newOption;f&&(u.push(f),dB(c,f),gB(o,v,f),mB(o[v],f))},this),n.elements=bt(o,function(c){return c&&delete c.$action,c!=null})},e.prototype._flatten=function(t,a,n){w(t,function(i){if(i){n&&(i.parentOption=n),a.push(i);var o=i.children;o&&o.length&&this._flatten(o,a,i),delete i.children}},this)},e.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},e.type="graphic",e.defaultOption={elements:[]},e}(lt),yy={path:null,compoundPath:null,group:tt,image:ke,text:ut},Ae=st(),xB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=Z()},e.prototype.render=function(t,a,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},e.prototype._updateElements=function(t){var a=t.useElOptionsToUpdate();if(a){var n=this._elMap,i=this.group,o=t.get("z"),s=t.get("zlevel");w(a,function(l){var u=Ut(l.id,null),c=u!=null?n.get(u):null,v=Ut(l.parentId,null),f=v!=null?n.get(v):i,h=l.type,p=l.style;h==="text"&&p&&l.hv&&l.hv[1]&&(p.textVerticalAlign=p.textBaseline=p.verticalAlign=p.align=null);var d=l.textContent,g=l.textConfig;if(p&&h1(p,h,!!g,!!d)){var y=p1(p,h,!0);!g&&y.textConfig&&(g=l.textConfig=y.textConfig),!d&&y.textContent&&(d=y.textContent)}var m=_B(l),S=l.$action||"merge",x=S==="merge",b=S==="replace";if(x){var _=!c,A=c;_?A=my(u,f,l.type,n):(A&&(Ae(A).isNew=!1),m1(A)),A&&(es(A,m,t,{isInit:_}),Sy(A,l,o,s))}else if(b){as(c,l,n,t);var T=my(u,f,l.type,n);T&&(es(T,m,t,{isInit:!0}),Sy(T,l,o,s))}else S==="remove"&&(g1(c,l),as(c,l,n,t));var C=n.get(u);if(C&&d)if(x){var M=C.getTextContent();M?M.attr(d):C.setTextContent(new ut(d))}else b&&C.setTextContent(new ut(d));if(C){var D=l.clipPath;if(D){var I=D.type,L=void 0,_=!1;if(x){var P=C.getClipPath();_=!P||Ae(P).type!==I,L=_?nv(I):P}else b&&(_=!0,L=nv(I));C.setClipPath(L),es(L,D,t,{isInit:_}),Ns(L,D.keyframeAnimation,t)}var E=Ae(C);C.setTextConfig(g),E.option=l,bB(C,t,l),_n({el:C,componentModel:t,itemName:C.name,itemTooltipOption:l.tooltip}),Ns(C,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,a){for(var n=t.option.elements,i=this.group,o=this._elMap,s=a.getWidth(),l=a.getHeight(),u=["x","y"],c=0;c<n.length;c++){var v=n[c],f=Ut(v.id,null),h=f!=null?o.get(f):null;if(!(!h||!h.isGroup)){var p=h.parent,d=p===i,g=Ae(h),y=Ae(p);g.width=F(g.option.width,d?s:y.width)||0,g.height=F(g.option.height,d?l:y.height)||0}}for(var c=n.length-1;c>=0;c--){var v=n[c],f=Ut(v.id,null),h=f!=null?o.get(f):null;if(h){var p=h.parent,y=Ae(p),m=p===i?{width:s,height:l}:{width:y.width,height:y.height},S={},x=al(h,v,m,null,{hv:v.hv,boundingMode:v.bounding},S);if(!Ae(h).isNew&&x){for(var b=v.transition,_={},A=0;A<u.length;A++){var T=u[A],C=S[T];b&&(ma(b)||ct(b,T)>=0)?_[T]=C:h[T]=C}ft(h,_,t,0)}else h.attr(S)}}},e.prototype._clear=function(){var t=this,a=this._elMap;a.each(function(n){as(n,Ae(n).option,a,t._lastGraphicModel)}),this._elMap=Z()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}(Ot);function nv(r){var e=U(yy,r)?yy[r]:Mv(r),t=new e({});return Ae(t).type=r,t}function my(r,e,t,a){var n=nv(t);return e.add(n),a.set(r,n),Ae(n).id=r,Ae(n).isNew=!0,n}function as(r,e,t,a){var n=r&&r.parent;n&&(r.type==="group"&&r.traverse(function(i){as(i,e,t,a)}),yl(r,e,a),t.removeKey(Ae(r).id))}function Sy(r,e,t,a){r.isGroup||w([["cursor",Sa.prototype.cursor],["zlevel",a||0],["z",t||0],["z2",0]],function(n){var i=n[0];U(e,i)?r[i]=St(e[i],n[1]):r[i]==null&&(r[i]=n[1])}),w(Wt(e),function(n){if(n.indexOf("on")===0){var i=e[n];r[n]=X(i)?i:null}}),U(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function _B(r){return r=B({},r),w(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(V0),function(e){delete r[e]}),r}function bB(r,e,t){var a=q(r).eventData;!r.silent&&!r.ignore&&!a&&(a=q(r).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:r.name}),a&&(a.info=t.info)}function wB(r){r.registerComponentModel(SB),r.registerComponentView(xB),r.registerPreprocessor(function(e){var t=e.graphic;O(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var xy=["x","y","radius","angle","single"],AB=["cartesian2d","polar","singleAxis"];function TB(r){var e=r.get("coordinateSystem");return ct(AB,e)>=0}function Lr(r){return r+"Axis"}function CB(r,e){var t=Z(),a=[],n=Z();r.eachComponent({mainType:"dataZoom",query:e},function(c){n.get(c.uid)||s(c)});var i;do i=!1,r.eachComponent("dataZoom",o);while(i);function o(c){!n.get(c.uid)&&l(c)&&(s(c),i=!0)}function s(c){n.set(c.uid,!0),a.push(c),u(c)}function l(c){var v=!1;return c.eachTargetAxis(function(f,h){var p=t.get(f);p&&p[h]&&(v=!0)}),v}function u(c){c.eachTargetAxis(function(v,f){(t.get(v)||t.set(v,[]))[f]=!0})}return a}function N1(r){var e=r.ecModel,t={infoList:[],infoMap:Z()};return r.eachTargetAxis(function(a,n){var i=e.getComponent(Lr(a),n);if(i){var o=i.getCoordSysModel();if(o){var s=o.uid,l=t.infoMap.get(s);l||(l={model:o,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(i)}}}),t}var Wu=function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},r}(),DB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,a,n){var i=_y(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},e.prototype.mergeOption=function(t){var a=_y(t);ot(this.option,t,!0),ot(this.settledOption,a,!0),this._doInit(a)},e.prototype._doInit=function(t){var a=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var n=this.settledOption;w([["start","startValue"],["end","endValue"]],function(i,o){this._rangePropMode[o]==="value"&&(a[i[0]]=n[i[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),a=this._targetAxisInfoMap=Z(),n=this._fillSpecifiedTargetAxis(a);n?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(a,this._orient)),this._noTarget=!0,a.each(function(i){i.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var a=!1;return w(xy,function(n){var i=this.getReferringComponents(Lr(n),xw);if(i.specified){a=!0;var o=new Wu;w(i.models,function(s){o.add(s.componentIndex)}),t.set(n,o)}},this),a},e.prototype._fillAutoTargetAxisByOrient=function(t,a){var n=this.ecModel,i=!0;if(i){var o=a==="vertical"?"y":"x",s=n.findComponents({mainType:o+"Axis"});l(s,o)}if(i){var s=n.findComponents({mainType:"singleAxis",filter:function(c){return c.get("orient",!0)===a}});l(s,"single")}function l(u,c){var v=u[0];if(v){var f=new Wu;if(f.add(v.componentIndex),t.set(c,f),i=!1,c==="x"||c==="y"){var h=v.getReferringComponents("grid",Ft).models[0];h&&w(u,function(p){v.componentIndex!==p.componentIndex&&h===p.getReferringComponents("grid",Ft).models[0]&&f.add(p.componentIndex)})}}}i&&w(xy,function(u){if(i){var c=n.findComponents({mainType:Lr(u),filter:function(f){return f.get("type",!0)==="category"}});if(c[0]){var v=new Wu;v.add(c[0].componentIndex),t.set(u,v),i=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(a){!t&&(t=a)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var a=this.ecModel.option;this.option.throttle=a.animation&&a.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var a=this._rangePropMode,n=this.get("rangeMode");w([["start","startValue"],["end","endValue"]],function(i,o){var s=t[i[0]]!=null,l=t[i[1]]!=null;s&&!l?a[o]="percent":!s&&l?a[o]="value":n?a[o]=n[o]:s&&(a[o]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(a,n){t==null&&(t=this.ecModel.getComponent(Lr(a),n))},this),t},e.prototype.eachTargetAxis=function(t,a){this._targetAxisInfoMap.each(function(n,i){w(n.indexList,function(o){t.call(a,i,o)})})},e.prototype.getAxisProxy=function(t,a){var n=this.getAxisModel(t,a);if(n)return n.__dzAxisProxy},e.prototype.getAxisModel=function(t,a){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[a])return this.ecModel.getComponent(Lr(t),a)},e.prototype.setRawRange=function(t){var a=this.option,n=this.settledOption;w([["start","startValue"],["end","endValue"]],function(i){(t[i[0]]!=null||t[i[1]]!=null)&&(a[i[0]]=n[i[0]]=t[i[0]],a[i[1]]=n[i[1]]=t[i[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var a=this.option;w(["start","startValue","end","endValue"],function(n){a[n]=t[n]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,a){if(t==null&&a==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()}else return this.getAxisProxy(t,a).getDataValueWindow()},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var a,n=this._targetAxisInfoMap.keys(),i=0;i<n.length;i++)for(var o=n[i],s=this._targetAxisInfoMap.get(o),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(o,s.indexList[l]);if(u.hostedBy(this))return u;a||(a=u)}return a},e.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},e.prototype.getOrient=function(){return this._orient},e.type="dataZoom",e.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],e.defaultOption={z:4,filterMode:"filter",start:0,end:100},e}(lt);function _y(r){var e={};return w(["start","end","startValue","endValue","throttle"],function(t){r.hasOwnProperty(t)&&(e[t]=r[t])}),e}const Oi=DB;var MB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e}(Oi);const IB=MB;var LB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n,i){this.dataZoomModel=t,this.ecModel=a,this.api=n},e.type="dataZoom",e}(Ot);const Yf=LB;var PB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e}(Yf);const EB=PB;var Xa=w,by=Me,RB=function(){function r(e,t,a,n){this._dimName=e,this._axisIndex=t,this.ecModel=n,this._dataZoomModel=a}return r.prototype.hostedBy=function(e){return this._dataZoomModel===e},r.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},r.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},r.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(TB(t)){var a=Lr(this._dimName),n=t.getReferringComponents(a,Ft).models[0];n&&this._axisIndex===n.componentIndex&&e.push(t)}},this),e},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return K(this._minMaxSpan)},r.prototype.calculateDataWindow=function(e){var t=this._dataExtent,a=this.getAxisModel(),n=a.axis.scale,i=this._dataZoomModel.getRangePropMode(),o=[0,100],s=[],l=[],u;Xa(["start","end"],function(f,h){var p=e[f],d=e[f+"Value"];i[h]==="percent"?(p==null&&(p=o[h]),d=n.parse(mt(p,o,t))):(u=!0,d=d==null?t[h]:n.parse(d),p=mt(d,t,o)),l[h]=d==null||isNaN(d)?t[h]:d,s[h]=p==null||isNaN(p)?o[h]:p}),by(l),by(s);var c=this._minMaxSpan;u?v(l,s,t,o,!1):v(s,l,o,t,!0);function v(f,h,p,d,g){var y=g?"Span":"ValueSpan";Ra(0,f,p,"all",c["min"+y],c["max"+y]);for(var m=0;m<2;m++)h[m]=mt(f[m],p,d,!0),g&&(h[m]=n.parse(h[m]))}return{valueWindow:l,percentWindow:s}},r.prototype.reset=function(e){if(e===this._dataZoomModel){var t=this.getTargetSeriesModels();this._dataExtent=kB(this,this._dimName,t),this._updateMinMaxSpan();var a=this.calculateDataWindow(e.settledOption);this._valueWindow=a.valueWindow,this._percentWindow=a.percentWindow,this._setAxisModel()}},r.prototype.filterData=function(e,t){if(e!==this._dataZoomModel)return;var a=this._dimName,n=this.getTargetSeriesModels(),i=e.get("filterMode"),o=this._valueWindow;if(i==="none")return;Xa(n,function(l){var u=l.getData(),c=u.mapDimensionsAll(a);if(c.length){if(i==="weakFilter"){var v=u.getStore(),f=G(c,function(h){return u.getDimensionIndex(h)},u);u.filterSelf(function(h){for(var p,d,g,y=0;y<c.length;y++){var m=v.get(f[y],h),S=!isNaN(m),x=m<o[0],b=m>o[1];if(S&&!x&&!b)return!0;S&&(g=!0),x&&(p=!0),b&&(d=!0)}return g&&p&&d})}else Xa(c,function(h){if(i==="empty")l.setData(u=u.map(h,function(d){return s(d)?d:NaN}));else{var p={};p[h]=o,u.selectRange(p)}});Xa(c,function(h){u.setApproximateExtent(o,h)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,a=this._dataExtent;Xa(["min","max"],function(n){var i=t.get(n+"Span"),o=t.get(n+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?i=mt(a[0]+o,a,[0,100],!0):i!=null&&(o=mt(i,[0,100],a,!0)-a[0]),e[n+"Span"]=i,e[n+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,a=this._valueWindow;if(t){var n=Wm(a,[0,500]);n=Math.min(n,20);var i=e.axis.scale.rawExtentInfo;t[0]!==0&&i.setDeterminedMinMax("min",+a[0].toFixed(n)),t[1]!==100&&i.setDeterminedMinMax("max",+a[1].toFixed(n)),i.freeze()}},r}();function kB(r,e,t){var a=[1/0,-1/0];Xa(t,function(o){QD(a,o.getData(),e)});var n=r.getAxisModel(),i=dx(n.axis.scale,n,a).calculate();return[i.min,i.max]}const NB=RB;var OB={getTargetSeries:function(r){function e(n){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(o,s){var l=r.getComponent(Lr(o),s);n(o,s,l,i)})})}e(function(n,i,o,s){o.__dzAxisProxy=null});var t=[];e(function(n,i,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new NB(n,i,s,r),t.push(o.__dzAxisProxy))});var a=Z();return w(t,function(n){w(n.getTargetSeriesModels(),function(i){a.set(i.uid,i)})}),a},overallReset:function(r,e){r.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(a,n){t.getAxisProxy(a,n).reset(t)}),t.eachTargetAxis(function(a,n){t.getAxisProxy(a,n).filterData(t,e)})}),r.eachComponent("dataZoom",function(t){var a=t.findRepresentativeAxisProxy();if(a){var n=a.getDataPercentWindow(),i=a.getDataValueWindow();t.setCalculatedRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]})}})}};const VB=OB;function BB(r){r.registerAction("dataZoom",function(e,t){var a=CB(t,e);w(a,function(n){n.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var wy=!1;function Zf(r){wy||(wy=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,VB),BB(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function zB(r){r.registerComponentModel(IB),r.registerComponentView(EB),Zf(r)}var Te=function(){function r(){}return r}(),O1={};function Ka(r,e){O1[r]=e}function V1(r){return O1[r]}var GB=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){r.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;w(this.option.feature,function(a,n){var i=V1(n);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(t)),ot(a,i.defaultOption))})},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(lt);const FB=GB;function HB(r,e,t){var a=e.getBoxLayoutParams(),n=e.get("padding"),i={width:t.getWidth(),height:t.getHeight()},o=Yt(a,i,n);da(e.get("orient"),r,e.get("itemGap"),o.width,o.height),al(r,a,i,n)}function B1(r,e){var t=An(e.get("padding")),a=e.getItemStyle(["color","opacity"]);return a.fill=e.get("backgroundColor"),r=new ht({shape:{x:r.x-t[3],y:r.y-t[0],width:r.width+t[1]+t[3],height:r.height+t[0]+t[2],r:e.get("borderRadius")},style:a,silent:!0,z2:-1}),r}var WB=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n,i){var o=this.group;if(o.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},c=this._features||(this._features={}),v=[];w(u,function(p,d){v.push(d)}),new hr(this._featureNames||[],v).add(f).update(f).remove(Q(f,null)).execute(),this._featureNames=v;function f(p,d){var g=v[p],y=v[d],m=u[g],S=new Dt(m,t,t.ecModel),x;if(i&&i.newTitle!=null&&i.featureName===g&&(m.title=i.newTitle),g&&!y){if($B(g))x={onclick:S.option.onclick,featureName:g};else{var b=V1(g);if(!b)return;x=new b}c[g]=x}else if(x=c[y],!x)return;x.uid=wn("toolbox-feature"),x.model=S,x.ecModel=a,x.api=n;var _=x instanceof Te;if(!g&&y){_&&x.dispose&&x.dispose(a,n);return}if(!S.get("show")||_&&x.unusable){_&&x.remove&&x.remove(a,n);return}h(S,x,g),S.setIconStatus=function(A,T){var C=this.option,M=this.iconPaths;C.iconStatus=C.iconStatus||{},C.iconStatus[A]=T,M[A]&&(T==="emphasis"?vr:fr)(M[A])},x instanceof Te&&x.render&&x.render(S,a,n,i)}function h(p,d,g){var y=p.getModel("iconStyle"),m=p.getModel(["emphasis","iconStyle"]),S=d instanceof Te&&d.getIcons?d.getIcons():p.get("icon"),x=p.get("title")||{},b,_;$(S)?(b={},b[g]=S):b=S,$(x)?(_={},_[g]=x):_=x;var A=p.iconPaths={};w(b,function(T,C){var M=Yi(T,{},{x:-s/2,y:-s/2,width:s,height:s});M.setStyle(y.getItemStyle());var D=M.ensureState("emphasis");D.style=m.getItemStyle();var I=new ut({style:{text:_[C],align:m.get("textAlign"),borderRadius:m.get("textBorderRadius"),padding:m.get("textPadding"),fill:null},ignore:!0});M.setTextContent(I),_n({el:M,componentModel:t,itemName:C,formatterParamsExtra:{title:_[C]}}),M.__title=_[C],M.on("mouseover",function(){var L=m.getItemStyle(),P=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";I.setStyle({fill:m.get("textFill")||L.fill||L.stroke||"#000",backgroundColor:m.get("textBackgroundColor")}),M.setTextConfig({position:m.get("textPosition")||P}),I.ignore=!t.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){p.get(["iconStatus",C])!=="emphasis"&&n.leaveEmphasis(this),I.hide()}),(p.get(["iconStatus",C])==="emphasis"?vr:fr)(M),o.add(M),M.on("click",W(d.onclick,d,a,n,C)),A[C]=M})}HB(o,t,n),o.add(B1(o.getBoundingRect(),t)),l||o.eachChild(function(p){var d=p.__title,g=p.ensureState("emphasis"),y=g.textConfig||(g.textConfig={}),m=p.getTextContent(),S=m&&m.ensureState("emphasis");if(S&&!X(S)&&d){var x=S.style||(S.style={}),b=Us(d,ut.makeFont(x)),_=p.x+o.x,A=p.y+o.y+s,T=!1;A+b.height>n.getHeight()&&(y.position="top",T=!0);var C=T?-5-b.height:s+10;_+b.width/2>n.getWidth()?(y.position=["100%",C],x.align="right"):_-b.width/2<0&&(y.position=[0,C],x.align="left")}})},e.prototype.updateView=function(t,a,n,i){w(this._features,function(o){o instanceof Te&&o.updateView&&o.updateView(o.model,a,n,i)})},e.prototype.remove=function(t,a){w(this._features,function(n){n instanceof Te&&n.remove&&n.remove(t,a)}),this.group.removeAll()},e.prototype.dispose=function(t,a){w(this._features,function(n){n instanceof Te&&n.dispose&&n.dispose(t,a)})},e.type="toolbox",e}(Ot);function $B(r){return r.indexOf("my")===0}const UB=WB;var YB=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",o=a.getZr().painter.getType()==="svg",s=o?"svg":n.get("type",!0)||"png",l=a.getConnectedDataURL({type:s,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),u=kt.browser;if(X(MouseEvent)&&(u.newEdge||!u.ie&&!u.edge)){var c=document.createElement("a");c.download=i+"."+s,c.target="_blank",c.href=l;var v=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(v)}else if(window.navigator.msSaveOrOpenBlob||o){var f=l.split(","),h=f[0].indexOf("base64")>-1,p=o?decodeURIComponent(f[1]):f[1];h&&(p=window.atob(p));var d=i+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var g=p.length,y=new Uint8Array(g);g--;)y[g]=p.charCodeAt(g);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,d)}else{var S=document.createElement("iframe");document.body.appendChild(S);var x=S.contentWindow,b=x.document;b.open("image/svg+xml","replace"),b.write(p),b.close(),x.focus(),b.execCommand("SaveAs",!0,d),document.body.removeChild(S)}}else{var _=n.get("lang"),A='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(_&&_[0]||"")+'" /></body>',T=window.open();T.document.write(A),T.document.title=i}},e.getDefaultOption=function(t){var a={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return a},e}(Te);const ZB=YB;var Ay="__ec_magicType_stack__",XB=[["line","bar"],["stack"]],KB=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,a=t.get("icon"),n={};return w(t.get("type"),function(i){a[i]&&(n[i]=a[i])}),n},e.getDefaultOption=function(t){var a={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return a},e.prototype.onclick=function(t,a,n){var i=this.model,o=i.get(["seriesIndex",n]);if(Ty[n]){var s={series:[]},l=function(v){var f=v.subType,h=v.id,p=Ty[n](f,h,v,i);p&&(J(p,v.option),s.series.push(p));var d=v.coordinateSystem;if(d&&d.type==="cartesian2d"&&(n==="line"||n==="bar")){var g=d.getAxesByScale("ordinal")[0];if(g){var y=g.dim,m=y+"Axis",S=v.getReferringComponents(m,Ft).models[0],x=S.componentIndex;s[m]=s[m]||[];for(var b=0;b<=x;b++)s[m][x]=s[m][x]||{};s[m][x].boundaryGap=n==="bar"}}};w(XB,function(v){ct(v,n)>=0&&w(v,function(f){i.setIconStatus(f,"normal")})}),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,c=n;n==="stack"&&(u=ot({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),i.get(["iconStatus",n])!=="emphasis"&&(c="tiled")),a.dispatchAction({type:"changeMagicType",currentType:c,newOption:s,newTitle:u,featureName:"magicType"})}},e}(Te),Ty={line:function(r,e,t,a){if(r==="bar")return ot({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},a.get(["option","line"])||{},!0)},bar:function(r,e,t,a){if(r==="line")return ot({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},a.get(["option","bar"])||{},!0)},stack:function(r,e,t,a){var n=t.get("stack")===Ay;if(r==="line"||r==="bar")return a.setIconStatus("stack",n?"normal":"emphasis"),ot({id:e,stack:n?"":Ay},a.get(["option","stack"])||{},!0)}};rr({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});const qB=KB;var ml=new Array(60).join("-"),hn="	";function jB(r){var e={},t=[],a=[];return r.eachRawSeries(function(n){var i=n.coordinateSystem;if(i&&(i.type==="cartesian2d"||i.type==="polar")){var o=i.getBaseAxis();if(o.type==="category"){var s=o.dim+"_"+o.index;e[s]||(e[s]={categoryAxis:o,valueAxis:i.getOtherAxis(o),series:[]},a.push({axisDim:o.dim,axisIndex:o.index})),e[s].series.push(n)}else t.push(n)}else t.push(n)}),{seriesGroupByCategoryAxis:e,other:t,meta:a}}function JB(r){var e=[];return w(r,function(t,a){var n=t.categoryAxis,i=t.valueAxis,o=i.dim,s=[" "].concat(G(t.series,function(h){return h.name})),l=[n.model.getCategories()];w(t.series,function(h){var p=h.getRawData();l.push(h.getRawData().mapArray(p.mapDimension(o),function(d){return d}))});for(var u=[s.join(hn)],c=0;c<l[0].length;c++){for(var v=[],f=0;f<l.length;f++)v.push(l[f][c]);u.push(v.join(hn))}e.push(u.join(`
`))}),e.join(`

`+ml+`

`)}function QB(r){return G(r,function(e){var t=e.getRawData(),a=[e.name],n=[];return t.each(t.dimensions,function(){for(var i=arguments.length,o=arguments[i-1],s=t.getName(o),l=0;l<i-1;l++)n[l]=arguments[l];a.push((s?s+hn:"")+n.join(hn))}),a.join(`
`)}).join(`

`+ml+`

`)}function tz(r){var e=jB(r);return{value:bt([JB(e.seriesGroupByCategoryAxis),QB(e.other)],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join(`

`+ml+`

`),meta:e.meta}}function Bs(r){return r.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function ez(r){var e=r.slice(0,r.indexOf(`
`));if(e.indexOf(hn)>=0)return!0}var iv=new RegExp("["+hn+"]+","g");function rz(r){for(var e=r.split(/\n+/g),t=Bs(e.shift()).split(iv),a=[],n=G(t,function(l){return{name:l,data:[]}}),i=0;i<e.length;i++){var o=Bs(e[i]).split(iv);a.push(o.shift());for(var s=0;s<o.length;s++)n[s]&&(n[s].data[i]=o[s])}return{series:n,categories:a}}function az(r){for(var e=r.split(/\n+/g),t=Bs(e.shift()),a=[],n=0;n<e.length;n++){var i=Bs(e[n]);if(i){var o=i.split(iv),s="",l=void 0,u=!1;isNaN(o[0])?(u=!0,s=o[0],o=o.slice(1),a[n]={name:s,value:[]},l=a[n].value):l=a[n]=[];for(var c=0;c<o.length;c++)l.push(+o[c]);l.length===1&&(u?a[n].value=l[0]:a[n]=l[0])}}return{name:t,data:a}}function nz(r,e){var t=r.split(new RegExp(`
*`+ml+`
*`,"g")),a={series:[]};return w(t,function(n,i){if(ez(n)){var o=rz(n),s=e[i],l=s.axisDim+"Axis";s&&(a[l]=a[l]||[],a[l][s.axisIndex]={data:o.categories},a.series=a.series.concat(o.series))}else{var o=az(n);a.series.push(o)}}),a}var iz=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){setTimeout(function(){a.dispatchAction({type:"hideTip"})});var n=a.getDom(),i=this.model;this._dom&&n.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",o.style.backgroundColor=i.get("backgroundColor")||"#fff";var s=document.createElement("h4"),l=i.get("lang")||[];s.innerHTML=l[0]||i.get("title"),s.style.cssText="margin:10px 20px",s.style.color=i.get("textColor");var u=document.createElement("div"),c=document.createElement("textarea");u.style.cssText="overflow:auto";var v=i.get("optionToContent"),f=i.get("contentToOption"),h=tz(t);if(X(v)){var p=v(a.getOption());$(p)?u.innerHTML=p:Fm(p)&&u.appendChild(p)}else{c.readOnly=i.get("readOnly");var d=c.style;d.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",d.color=i.get("textColor"),d.borderColor=i.get("textareaBorderColor"),d.backgroundColor=i.get("textareaColor"),c.value=h.value,u.appendChild(c)}var g=h.meta,y=document.createElement("div");y.style.cssText="position:absolute;bottom:5px;left:0;right:0";var m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",S=document.createElement("div"),x=document.createElement("div");m+=";background-color:"+i.get("buttonColor"),m+=";color:"+i.get("buttonTextColor");var b=this;function _(){n.removeChild(o),b._dom=null}ch(S,"click",_),ch(x,"click",function(){if(f==null&&v!=null||f!=null&&v==null){_();return}var A;try{X(f)?A=f(u,a.getOption()):A=nz(c.value,g)}catch(T){throw _(),new Error("Data view format error "+T)}A&&a.dispatchAction({type:"changeDataView",newOption:A}),_()}),S.innerHTML=l[1],x.innerHTML=l[2],x.style.cssText=S.style.cssText=m,!i.get("readOnly")&&y.appendChild(x),y.appendChild(S),o.appendChild(s),o.appendChild(u),o.appendChild(y),u.style.height=n.clientHeight-80+"px",n.appendChild(o),this._dom=o},e.prototype.remove=function(t,a){this._dom&&a.getDom().removeChild(this._dom)},e.prototype.dispose=function(t,a){this.remove(t,a)},e.getDefaultOption=function(t){var a={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"};return a},e}(Te);function oz(r,e){return G(r,function(t,a){var n=e&&e[a];if(j(n)&&!O(n)){var i=j(t)&&!O(t);i||(t={value:t});var o=n.name!=null&&t.name==null;return t=J(t,n),o&&delete t.name,t}else return t})}rr({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(r,e){var t=[];w(r.newOption.series,function(a){var n=e.getSeriesByName(a.name)[0];if(!n)t.push(B({type:"scatter"},a));else{var i=n.get("data");t.push({name:a.name,data:oz(a.data,i)})}}),e.mergeOption(J({series:t},r.newOption))});const sz=iz;var z1=w,G1=st();function lz(r,e){var t=Xf(r);z1(e,function(a,n){for(var i=t.length-1;i>=0;i--){var o=t[i];if(o[n])break}if(i<0){var s=r.queryComponents({mainType:"dataZoom",subType:"select",id:n})[0];if(s){var l=s.getPercentRange();t[0][n]={dataZoomId:n,start:l[0],end:l[1]}}}}),t.push(e)}function uz(r){var e=Xf(r),t=e[e.length-1];e.length>1&&e.pop();var a={};return z1(t,function(n,i){for(var o=e.length-1;o>=0;o--)if(n=e[o][i],n){a[i]=n;break}}),a}function cz(r){G1(r).snapshots=null}function vz(r){return Xf(r).length}function Xf(r){var e=G1(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var fz=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){cz(t),a.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var a={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])};return a},e}(Te);rr({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});const hz=fz;var pz=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],dz=function(){function r(e,t,a){var n=this;this._targetInfoList=[];var i=Cy(t,e);w(gz,function(o,s){(!a||!a.include||ct(a.include,s)>=0)&&o(i,n._targetInfoList)})}return r.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(a,n,i){if((a.coordRanges||(a.coordRanges=[])).push(n),!a.coordRange){a.coordRange=n;var o=$u[a.brushType](0,i,n);a.__rangeOffset={offset:Ly[a.brushType](o.values,a.range,[1,1]),xyMinMax:o.xyMinMax}}}),e},r.prototype.matchOutputRanges=function(e,t,a){w(e,function(n){var i=this.findTargetInfo(n,t);i&&i!==!0&&w(i.coordSyses,function(o){var s=$u[n.brushType](1,o,n.range,!0);a(n,s.values,o,t)})},this)},r.prototype.setInputRanges=function(e,t){w(e,function(a){var n=this.findTargetInfo(a,t);if(a.range=a.range||[],n&&n!==!0){a.panelId=n.panelId;var i=$u[a.brushType](0,n.coordSys,a.coordRange),o=a.__rangeOffset;a.range=o?Ly[a.brushType](i.values,o.offset,yz(i.xyMinMax,o.xyMinMax)):i.values}},this)},r.prototype.makePanelOpts=function(e,t){return G(this._targetInfoList,function(a){var n=a.getPanelRect();return{panelId:a.panelId,defaultBrushType:t?t(a):null,clipPath:Z_(n),isTargetByCursor:K_(n,e,a.coordSysModel),getLinearBrushOtherExtent:X_(n)}})},r.prototype.controlSeries=function(e,t,a){var n=this.findTargetInfo(e,a);return n===!0||n&&ct(n.coordSyses,t.coordinateSystem)>=0},r.prototype.findTargetInfo=function(e,t){for(var a=this._targetInfoList,n=Cy(t,e),i=0;i<a.length;i++){var o=a[i],s=e.panelId;if(s){if(o.panelId===s)return o}else for(var l=0;l<Dy.length;l++)if(Dy[l](n,o))return o}return!0},r}();function ov(r){return r[0]>r[1]&&r.reverse(),r}function Cy(r,e){return ui(r,e,{includeMainTypes:pz})}var gz={grid:function(r,e){var t=r.xAxisModels,a=r.yAxisModels,n=r.gridModels,i=Z(),o={},s={};!t&&!a&&!n||(w(t,function(l){var u=l.axis.grid.model;i.set(u.id,u),o[u.id]=!0}),w(a,function(l){var u=l.axis.grid.model;i.set(u.id,u),s[u.id]=!0}),w(n,function(l){i.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),i.each(function(l){var u=l.coordinateSystem,c=[];w(u.getCartesians(),function(v,f){(ct(t,v.getAxis("x").model)>=0||ct(a,v.getAxis("y").model)>=0)&&c.push(v)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:c[0],coordSyses:c,getPanelRect:My.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(r,e){w(r.geoModels,function(t){var a=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:a,coordSyses:[a],getPanelRect:My.geo})})}},Dy=[function(r,e){var t=r.xAxisModel,a=r.yAxisModel,n=r.gridModel;return!n&&t&&(n=t.axis.grid.model),!n&&a&&(n=a.axis.grid.model),n&&n===e.gridModel},function(r,e){var t=r.geoModel;return t&&t===e.geoModel}],My={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,e=r.getBoundingRect().clone();return e.applyTransform(pa(r)),e}},$u={lineX:Q(Iy,0),lineY:Q(Iy,1),rect:function(r,e,t,a){var n=r?e.pointToData([t[0][0],t[1][0]],a):e.dataToPoint([t[0][0],t[1][0]],a),i=r?e.pointToData([t[0][1],t[1][1]],a):e.dataToPoint([t[0][1],t[1][1]],a),o=[ov([n[0],i[0]]),ov([n[1],i[1]])];return{values:o,xyMinMax:o}},polygon:function(r,e,t,a){var n=[[1/0,-1/0],[1/0,-1/0]],i=G(t,function(o){var s=r?e.pointToData(o,a):e.dataToPoint(o,a);return n[0][0]=Math.min(n[0][0],s[0]),n[1][0]=Math.min(n[1][0],s[1]),n[0][1]=Math.max(n[0][1],s[0]),n[1][1]=Math.max(n[1][1],s[1]),s});return{values:i,xyMinMax:n}}};function Iy(r,e,t,a){var n=t.getAxis(["x","y"][r]),i=ov(G([0,1],function(s){return e?n.coordToData(n.toLocalCoord(a[s]),!0):n.toGlobalCoord(n.dataToCoord(a[s]))})),o=[];return o[r]=i,o[1-r]=[NaN,NaN],{values:i,xyMinMax:o}}var Ly={lineX:Q(Py,0),lineY:Q(Py,1),rect:function(r,e,t){return[[r[0][0]-t[0]*e[0][0],r[0][1]-t[0]*e[0][1]],[r[1][0]-t[1]*e[1][0],r[1][1]-t[1]*e[1][1]]]},polygon:function(r,e,t){return G(r,function(a,n){return[a[0]-t[0]*e[n][0],a[1]-t[1]*e[n][1]]})}};function Py(r,e,t,a){return[e[0]-a[r]*t[0],e[1]-a[r]*t[1]]}function yz(r,e){var t=Ey(r),a=Ey(e),n=[t[0]/a[0],t[1]/a[1]];return isNaN(n[0])&&(n[0]=1),isNaN(n[1])&&(n[1]=1),n}function Ey(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}const Kf=dz;var sv=w,mz=dw("toolbox-dataZoom_"),Sz=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n,i){this._brushController||(this._brushController=new If(n.getZr()),this._brushController.on("brush",W(this._onBrush,this)).mount()),bz(t,a,this,i,n),_z(t,a)},e.prototype.onclick=function(t,a,n){xz[n].call(this)},e.prototype.remove=function(t,a){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,a){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var a=t.areas;if(!t.isEnd||!a.length)return;var n={},i=this.ecModel;this._brushController.updateCovers([]);var o=new Kf(qf(this.model),i,{include:["grid"]});o.matchOutputRanges(a,i,function(u,c,v){if(v.type==="cartesian2d"){var f=u.brushType;f==="rect"?(s("x",v,c[0]),s("y",v,c[1])):s({lineX:"x",lineY:"y"}[f],v,c)}}),lz(i,n),this._dispatchZoomAction(n);function s(u,c,v){var f=c.getAxis(u),h=f.model,p=l(u,h,i),d=p.findRepresentativeAxisProxy(h).getMinMaxSpan();(d.minValueSpan!=null||d.maxValueSpan!=null)&&(v=Ra(0,v.slice(),f.scale.getExtent(),0,d.minValueSpan,d.maxValueSpan)),p&&(n[p.id]={dataZoomId:p.id,startValue:v[0],endValue:v[1]})}function l(u,c,v){var f;return v.eachComponent({mainType:"dataZoom",subType:"select"},function(h){var p=h.getAxisModel(u,c.componentIndex);p&&(f=h)}),f}},e.prototype._dispatchZoomAction=function(t){var a=[];sv(t,function(n,i){a.push(K(n))}),a.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:a})},e.getDefaultOption=function(t){var a={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}};return a},e}(Te),xz={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(uz(this.ecModel))}};function qf(r){var e={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function _z(r,e){r.setIconStatus("back",vz(e)>1?"emphasis":"normal")}function bz(r,e,t,a,n){var i=t._isZoomActive;a&&a.type==="takeGlobalCursor"&&(i=a.key==="dataZoomSelect"?a.dataZoomSelectActive:!1),t._isZoomActive=i,r.setIconStatus("zoom",i?"emphasis":"normal");var o=new Kf(qf(r),e,{include:["grid"]}),s=o.makePanelOpts(n,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(i&&s.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}kA("dataZoom",function(r){var e=r.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var a=e.getModel(t),n=[],i=qf(a),o=ui(r,i);sv(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),sv(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,c){var v=l.componentIndex,f={type:"select",$fromToolbox:!0,filterMode:a.get("filterMode",!0)||"filter",id:mz+u+v};f[c]=v,n.push(f)}return n});const wz=Sz;function Az(r){r.registerComponentModel(FB),r.registerComponentView(UB),Ka("saveAsImage",ZB),Ka("magicType",qB),Ka("dataView",sz),Ka("dataZoom",wz),Ka("restore",hz),it(zB)}var Tz=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(lt);const Cz=Tz;function F1(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function H1(r){if(kt.domSupported){for(var e=document.documentElement.style,t=0,a=r.length;t<a;t++)if(r[t]in e)return r[t]}}var W1=H1(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),Dz=H1(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function $1(r,e){if(!r)return e;e=N0(e,!0);var t=r.indexOf(e);return r=t===-1?e:"-"+r.slice(0,t)+"-"+e,r.toLowerCase()}function Mz(r,e){var t=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return t?e?t[e]:t:null}var Iz=$1(Dz,"transition"),jf=$1(W1,"transform"),Lz="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(kt.transform3dSupported?"will-change:transform;":"");function Pz(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function Ez(r,e,t){if(!$(t)||t==="inside")return"";var a=r.get("backgroundColor"),n=r.get("borderWidth");e=Ta(e);var i=Pz(t),o=Math.max(Math.round(n)*1.5,6),s="",l=jf+":",u;ct(["left","right"],i)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=i==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=i==="top"?225:45)+"deg)");var c=u*Math.PI/180,v=o+n,f=v*Math.abs(Math.cos(c))+v*Math.abs(Math.sin(c)),h=Math.round(((f-Math.SQRT2*n)/2+Math.SQRT2*n-(f-v)/2)*100)/100;s+=";"+i+":-"+h+"px";var p=e+" solid "+n+"px;",d=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+p,"border-right:"+p,"background-color:"+a+";"];return'<div style="'+d.join("")+'"></div>'}function Rz(r,e){var t="cubic-bezier(0.23,1,0.32,1)",a=" "+r/2+"s "+t,n="opacity"+a+",visibility"+a;return e||(a=" "+r+"s "+t,n+=kt.transformSupported?","+jf+a:",left"+a+",top"+a),Iz+":"+n}function Ry(r,e,t){var a=r.toFixed(0)+"px",n=e.toFixed(0)+"px";if(!kt.transformSupported)return t?"top:"+n+";left:"+a+";":[["top",n],["left",a]];var i=kt.transform3dSupported,o="translate"+(i?"3d":"")+"("+a+","+n+(i?",0":"")+")";return t?"top:0;left:0;"+jf+":"+o+";":[["top",0],["left",0],[W1,o]]}function kz(r){var e=[],t=r.get("fontSize"),a=r.getTextColor();a&&e.push("color:"+a),e.push("font:"+r.getFont()),t&&e.push("line-height:"+Math.round(t*3/2)+"px");var n=r.get("textShadowColor"),i=r.get("textShadowBlur")||0,o=r.get("textShadowOffsetX")||0,s=r.get("textShadowOffsetY")||0;return n&&i&&e.push("text-shadow:"+o+"px "+s+"px "+i+"px "+n),w(["decoration","align"],function(l){var u=r.get(l);u&&e.push("text-"+l+":"+u)}),e.join(";")}function Nz(r,e,t){var a=[],n=r.get("transitionDuration"),i=r.get("backgroundColor"),o=r.get("shadowBlur"),s=r.get("shadowColor"),l=r.get("shadowOffsetX"),u=r.get("shadowOffsetY"),c=r.getModel("textStyle"),v=yS(r,"html"),f=l+"px "+u+"px "+o+"px "+s;return a.push("box-shadow:"+f),e&&n&&a.push(Rz(n,t)),i&&a.push("background-color:"+i),w(["width","color","radius"],function(h){var p="border-"+h,d=N0(p),g=r.get(d);g!=null&&a.push(p+":"+g+(h==="color"?"":"px"))}),a.push(kz(c)),v!=null&&a.push("padding:"+An(v).join("px ")+"px"),a.join(";")+";"}function ky(r,e,t,a,n){var i=e&&e.painter;if(t){var o=i&&i.getViewportRoot();o&&Kb(r,o,document.body,a,n)}else{r[0]=a,r[1]=n;var s=i&&i.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var Oz=function(){function r(e,t,a){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,kt.wxa)return null;var n=document.createElement("div");n.domBelongToZr=!0,this.el=n;var i=this._zr=t.getZr(),o=this._appendToBody=a&&a.appendToBody;ky(this._styleCoord,i,o,t.getWidth()/2,t.getHeight()/2),o?document.body.appendChild(n):e.appendChild(n),this._container=e;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,c=i.painter.getViewportRoot();Xb(c,l,!0),u.dispatch("mousemove",l)}},n.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(e){var t=this._container,a=Mz(t,"position"),n=t.style;n.position!=="absolute"&&a!=="absolute"&&(n.position="relative");var i=e.get("alwaysShowContent");i&&this._moveIfResized(),this._alwaysShowContent=i,this.el.className=e.get("className")||""},r.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var a=this.el,n=a.style,i=this._styleCoord;a.innerHTML?n.cssText=Lz+Nz(e,!this._firstShow,this._longHide)+Ry(i[0],i[1],!0)+("border-color:"+Ta(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(e,t,a,n,i){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if($(i)&&a.get("trigger")==="item"&&!F1(a)&&(s=Ez(a,n,i)),$(e))o.innerHTML=e+s;else if(e){o.innerHTML="",O(e)||(e=[e]);for(var l=0;l<e.length;l++)Fm(e[l])&&e[l].parentNode!==o&&o.appendChild(e[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el;return[e.offsetWidth,e.offsetHeight]},r.prototype.moveTo=function(e,t){var a=this._styleCoord;if(ky(a,this._zr,this._appendToBody,e,t),a[0]!=null&&a[1]!=null){var n=this.el.style,i=Ry(a[0],a[1]);w(i,function(o){n[o[0]]=o[1]})}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){var e=this,t=this.el.style;t.visibility="hidden",t.opacity="0",kt.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(W(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this.el.parentNode.removeChild(this.el)},r}();const Vz=Oz;var Bz=function(){function r(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),Oy(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return r.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(e,t,a,n,i){var o=this;j(e)&&dt(""),this.el&&this._zr.remove(this.el);var s=a.getModel("textStyle");this.el=new ut({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:n,textShadowColor:s.get("textShadowColor"),fill:a.get(["textStyle","color"]),padding:yS(a,"richText"),verticalAlign:"top",align:"left"},z:a.get("z")}),w(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=a.get(u)}),w(["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})},r.prototype.setEnterable=function(e){this._enterable=e},r.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),a=Ny(e.style);return[t.width+a.left+a.right,t.height+a.top+a.bottom]},r.prototype.moveTo=function(e,t){var a=this.el;if(a){var n=this._styleCoord;Oy(n,this._zr,e,t),e=n[0],t=n[1];var i=a.style,o=Cr(i.borderWidth||0),s=Ny(i);a.x=e+o+s.left,a.y=t+o+s.top,a.markRedraw()}},r.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(W(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r}();function Cr(r){return Math.max(0,r)}function Ny(r){var e=Cr(r.shadowBlur||0),t=Cr(r.shadowOffsetX||0),a=Cr(r.shadowOffsetY||0);return{left:Cr(e-t),right:Cr(e+t),top:Cr(e-a),bottom:Cr(e+a)}}function Oy(r,e,t,a){r[0]=t,r[1]=a,r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}const zz=Bz;var Gz=new ht({shape:{x:-1,y:-1,width:2,height:2}}),Fz=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){if(!(kt.node||!a.getDom())){var n=t.getComponent("tooltip"),i=this._renderMode=bw(n.get("renderMode"));this._tooltipContent=i==="richText"?new zz(a):new Vz(a.getDom(),a,{appendToBody:n.get("appendToBody",!0)})}},e.prototype.render=function(t,a,n){if(!(kt.node||!n.getDom())){this.group.removeAll(),this._tooltipModel=t,this._ecModel=a,this._api=n;var i=this._tooltipContent;i.update(t),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&t.get("transitionDuration")?In(this,"_updatePosition",50,"fixRate"):Di(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,a=t.get("triggerOn");D1("itemTooltip",this._api,W(function(n,i,o){a!=="none"&&(a.indexOf(n)>=0?this._tryShow(i,o):n==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,a=this._ecModel,n=this._api,i=t.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&i!=="none"&&i!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&o.manuallyShowTip(t,a,n,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,a,n,i){if(!(i.from===this.uid||kt.node||!n.getDom())){var o=Vy(i,n);this._ticket="";var s=i.dataByCoordSys,l=Uz(i,a,n);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:i.position,positionDefault:"bottom"},o)}else if(i.tooltip&&i.x!=null&&i.y!=null){var c=Gz;c.x=i.x,c.y=i.y,c.update(),q(c).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:c},o)}else if(s)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:s,tooltipOption:i.tooltipOption},o);else if(i.seriesIndex!=null){if(this._manuallyAxisShowTip(t,a,n,i))return;var v=M1(i,a),f=v.point[0],h=v.point[1];f!=null&&h!=null&&this._tryShow({offsetX:f,offsetY:h,target:v.el,position:i.position,positionDefault:"bottom"},o)}else i.x!=null&&i.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target},o))}},e.prototype.manuallyHideTip=function(t,a,n,i){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(Vy(i,n))},e.prototype._manuallyAxisShowTip=function(t,a,n,i){var o=i.seriesIndex,s=i.dataIndex,l=a.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=a.getSeriesByIndex(o);if(u){var c=u.getData(),v=Kn([c.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(v.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:i.position}),!0}}},e.prototype._tryShow=function(t,a){var n=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(n){this._lastDataByCoordSys=null;var s,l;ca(n,function(u){if(q(u).dataIndex!=null)return s=u,!0;if(q(u).tooltipConfig!=null)return l=u,!0},!0),s?this._showSeriesItemTooltip(t,s,a):l?this._showComponentItemTooltip(t,l,a):this._hide(a)}else this._lastDataByCoordSys=null,this._hide(a)}},e.prototype._showOrMove=function(t,a){var n=t.get("showDelay");a=W(a,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(a,n):a()},e.prototype._showAxisTooltip=function(t,a){var n=this._ecModel,i=this._tooltipModel,o=[a.offsetX,a.offsetY],s=Kn([a.tooltipOption],i),l=this._renderMode,u=[],c=qt("section",{blocks:[],noHeader:!0}),v=[],f=new Nl;w(t,function(m){w(m.dataByAxis,function(S){var x=n.getComponent(S.axisDim+"Axis",S.axisIndex),b=S.value;if(!(!x||b==null)){var _=A1(b,x.axis,n,S.seriesDataIndices,S.valueLabelOpt),A=qt("section",{header:_,noHeader:!Gi(_),sortBlocks:!0,blocks:[]});c.blocks.push(A),w(S.seriesDataIndices,function(T){var C=n.getSeriesByIndex(T.seriesIndex),M=T.dataIndexInside,D=C.getDataParams(M);if(!(D.dataIndex<0)){D.axisDim=S.axisDim,D.axisIndex=S.axisIndex,D.axisType=S.axisType,D.axisId=S.axisId,D.axisValue=rf(x.axis,{value:b}),D.axisValueLabel=_,D.marker=f.makeTooltipMarker("item",Ta(D.color),l);var I=ep(C.formatTooltip(M,!0,null)),L=I.frag;if(L){var P=Kn([C],i).get("valueFormatter");A.blocks.push(P?B({valueFormatter:P},L):L)}I.text&&v.push(I.text),u.push(D)}})}})}),c.blocks.reverse(),v.reverse();var h=a.position,p=s.get("order"),d=sp(c,f,l,p,n.get("useUTC"),s.get("textStyle"));d&&v.unshift(d);var g=l==="richText"?`

`:"<br/>",y=v.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,h,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],h,null,f)})},e.prototype._showSeriesItemTooltip=function(t,a,n){var i=this._ecModel,o=q(a),s=o.seriesIndex,l=i.getSeriesByIndex(s),u=o.dataModel||l,c=o.dataIndex,v=o.dataType,f=u.getData(v),h=this._renderMode,p=t.positionDefault,d=Kn([f.getItemModel(c),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),g=d.get("trigger");if(!(g!=null&&g!=="item")){var y=u.getDataParams(c,v),m=new Nl;y.marker=m.makeTooltipMarker("item",Ta(y.color),h);var S=ep(u.formatTooltip(c,!1,v)),x=d.get("order"),b=d.get("valueFormatter"),_=S.frag,A=_?sp(b?B({valueFormatter:b},_):_,m,h,x,i.get("useUTC"),d.get("textStyle")):S.text,T="item_"+u.name+"_"+c;this._showOrMove(d,function(){this._showTooltipContent(d,A,y,T,t.offsetX,t.offsetY,t.position,t.target,m)}),n({type:"showTip",dataIndexInside:c,dataIndex:f.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,a,n){var i=q(a),o=i.tooltipConfig,s=o.option||{};if($(s)){var l=s;s={content:l,formatter:l}}var u=[s],c=this._ecModel.getComponent(i.componentMainType,i.componentIndex);c&&u.push(c),u.push({formatter:s.content});var v=t.positionDefault,f=Kn(u,this._tooltipModel,v?{position:v}:null),h=f.get("content"),p=Math.random()+"",d=new Nl;this._showOrMove(f,function(){var g=K(f.get("formatterParams")||{});this._showTooltipContent(f,h,g,p,t.offsetX,t.offsetY,t.position,a,d)}),n({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,a,n,i,o,s,l,u,c){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var v=this._tooltipContent;v.setEnterable(t.get("enterable"));var f=t.get("formatter");l=l||t.get("position");var h=a,p=this._getNearestPoint([o,s],n,t.get("trigger"),t.get("borderColor")),d=p.color;if(f)if($(f)){var g=t.ecModel.get("useUTC"),y=O(n)?n[0]:n,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;h=f,m&&(h=Js(y.axisValue,h,g)),h=O0(h,n,!0)}else if(X(f)){var S=W(function(x,b){x===this._ticket&&(v.setContent(b,c,t,d,l),this._updatePosition(t,l,o,s,v,n,u))},this);this._ticket=i,h=f(n,i,S)}else h=f;v.setContent(h,c,t,d,l),v.show(t,d),this._updatePosition(t,l,o,s,v,n,u)}},e.prototype._getNearestPoint=function(t,a,n,i){if(n==="axis"||O(a))return{color:i||(this._renderMode==="html"?"#fff":"none")};if(!O(a))return{color:i||a.color||a.borderColor}},e.prototype._updatePosition=function(t,a,n,i,o,s,l){var u=this._api.getWidth(),c=this._api.getHeight();a=a||t.get("position");var v=o.getSize(),f=t.get("align"),h=t.get("verticalAlign"),p=l&&l.getBoundingRect().clone();if(l&&p.applyTransform(l.transform),X(a)&&(a=a([n,i],s,o.el,p,{viewSize:[u,c],contentSize:v.slice()})),O(a))n=F(a[0],u),i=F(a[1],c);else if(j(a)){var d=a;d.width=v[0],d.height=v[1];var g=Yt(d,{width:u,height:c});n=g.x,i=g.y,f=null,h=null}else if($(a)&&l){var y=$z(a,p,v,t.get("borderWidth"));n=y[0],i=y[1]}else{var y=Hz(n,i,o,u,c,f?null:20,h?null:20);n=y[0],i=y[1]}if(f&&(n-=By(f)?v[0]/2:f==="right"?v[0]:0),h&&(i-=By(h)?v[1]/2:h==="bottom"?v[1]:0),F1(t)){var y=Wz(n,i,o,u,c);n=y[0],i=y[1]}o.moveTo(n,i)},e.prototype._updateContentNotChangedOnAxis=function(t,a){var n=this._lastDataByCoordSys,i=this._cbParamsList,o=!!n&&n.length===t.length;return o&&w(n,function(s,l){var u=s.dataByAxis||[],c=t[l]||{},v=c.dataByAxis||[];o=o&&u.length===v.length,o&&w(u,function(f,h){var p=v[h]||{},d=f.seriesDataIndices||[],g=p.seriesDataIndices||[];o=o&&f.value===p.value&&f.axisType===p.axisType&&f.axisId===p.axisId&&d.length===g.length,o&&w(d,function(y,m){var S=g[m];o=o&&y.seriesIndex===S.seriesIndex&&y.dataIndex===S.dataIndex}),i&&w(f.seriesDataIndices,function(y){var m=y.seriesIndex,S=a[m],x=i[m];S&&x&&x.data!==S.data&&(o=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=a,!!o},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,a){kt.node||!a.getDom()||(Di(this,"_updatePosition"),this._tooltipContent.dispose(),rv("itemTooltip",a))},e.type="tooltip",e}(Ot);function Kn(r,e,t){var a=e.ecModel,n;t?(n=new Dt(t,a,a),n=new Dt(e.option,n,a)):n=e;for(var i=r.length-1;i>=0;i--){var o=r[i];o&&(o instanceof Dt&&(o=o.get("tooltip",!0)),$(o)&&(o={formatter:o}),o&&(n=new Dt(o,n,a)))}return n}function Vy(r,e){return r.dispatchAction||W(e.dispatchAction,e)}function Hz(r,e,t,a,n,i,o){var s=t.getSize(),l=s[0],u=s[1];return i!=null&&(r+l+i+2>a?r-=l+i:r+=i),o!=null&&(e+u+o>n?e-=u+o:e+=o),[r,e]}function Wz(r,e,t,a,n){var i=t.getSize(),o=i[0],s=i[1];return r=Math.min(r+o,a)-o,e=Math.min(e+s,n)-s,r=Math.max(r,0),e=Math.max(e,0),[r,e]}function $z(r,e,t,a){var n=t[0],i=t[1],o=Math.ceil(Math.SQRT2*a)+8,s=0,l=0,u=e.width,c=e.height;switch(r){case"inside":s=e.x+u/2-n/2,l=e.y+c/2-i/2;break;case"top":s=e.x+u/2-n/2,l=e.y-i-o;break;case"bottom":s=e.x+u/2-n/2,l=e.y+c+o;break;case"left":s=e.x-n-o,l=e.y+c/2-i/2;break;case"right":s=e.x+u+o,l=e.y+c/2-i/2}return[s,l]}function By(r){return r==="center"||r==="middle"}function Uz(r,e,t){var a=xv(r).queryOptionMap,n=a.keys()[0];if(!(!n||n==="series")){var i=Wi(e,n,a.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),o=i.models[0];if(o){var s=t.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var c=q(u).tooltipConfig;if(c&&c.name===r.name)return l=u,!0}),l)return{componentMainType:n,componentIndex:o.componentIndex,el:l}}}}const Yz=Fz;function Zz(r){it(oo),r.registerComponentModel(Cz),r.registerComponentView(Yz),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},he),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},he)}var Xz=["rect","polygon","keep","clear"];function Kz(r,e){var t=_t(r?r.brush:[]);if(t.length){var a=[];w(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(a=a.concat(u))});var n=r&&r.toolbox;O(n)&&(n=n[0]),n||(n={feature:{}},r.toolbox=[n]);var i=n.feature||(n.feature={}),o=i.brush||(i.brush={}),s=o.type||(o.type=[]);s.push.apply(s,a),qz(s),e&&!s.length&&s.push.apply(s,Xz)}}function qz(r){var e={};w(r,function(t){e[t]=1}),r.length=0,w(e,function(t,a){r.push(a)})}var zy=w;function Gy(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function lv(r,e,t){var a={};return zy(e,function(i){var o=a[i]=n();zy(r[i],function(s,l){if(ee.isValidType(l)){var u={type:l,visual:s};t&&t(u,i),o[l]=new ee(u),l==="opacity"&&(u=K(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new ee(u))}})}),a;function n(){var i=function(){};i.prototype.__hidden=i.prototype;var o=new i;return o}}function U1(r,e,t){var a;w(t,function(n){e.hasOwnProperty(n)&&Gy(e[n])&&(a=!0)}),a&&w(t,function(n){e.hasOwnProperty(n)&&Gy(e[n])?r[n]=K(e[n]):delete r[n]})}function jz(r,e,t,a,n,i){var o={};w(r,function(v){var f=ee.prepareVisualTypes(e[v]);o[v]=f});var s;function l(v){return Yv(t,s,v)}function u(v,f){DS(t,s,v,f)}i==null?t.each(c):t.each([i],c);function c(v,f){s=i==null?v:f;var h=t.getRawDataItem(s);if(!(h&&h.visualMap===!1))for(var p=a.call(n,v),d=e[p],g=o[p],y=0,m=g.length;y<m;y++){var S=g[y];d[S]&&d[S].applyVisual(v,l,u)}}}function Jz(r,e,t,a){var n={};return w(r,function(i){var o=ee.prepareVisualTypes(e[i]);n[i]=o}),{progress:function(o,s){var l;a!=null&&(l=s.getDimensionIndex(a));function u(b){return Yv(s,v,b)}function c(b,_){DS(s,v,b,_)}for(var v,f=s.getStore();(v=o.next())!=null;){var h=s.getRawDataItem(v);if(!(h&&h.visualMap===!1))for(var p=a!=null?f.get(l,v):v,d=t(p),g=e[d],y=n[d],m=0,S=y.length;m<S;m++){var x=y[m];g[x]&&g[x].applyVisual(p,u,c)}}}}}function Qz(r){var e=r.brushType,t={point:function(a){return Fy[e].point(a,t,r)},rect:function(a){return Fy[e].rect(a,t,r)}};return t}var Fy={lineX:Hy(0),lineY:Hy(1),rect:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])},rect:function(r,e,t){return r&&t.boundingRect.intersect(r)}},polygon:{point:function(r,e,t){return r&&t.boundingRect.contain(r[0],r[1])&&aa(t.range,r[0],r[1])},rect:function(r,e,t){var a=t.range;if(!r||a.length<=1)return!1;var n=r.x,i=r.y,o=r.width,s=r.height,l=a[0];if(aa(a,n,i)||aa(a,n+o,i)||aa(a,n,i+s)||aa(a,n+o,i+s)||wt.create(r).contain(l[0],l[1])||ti(n,i,n+o,i,a)||ti(n,i,n,i+s,a)||ti(n+o,i,n+o,i+s,a)||ti(n,i+s,n+o,i+s,a))return!0}}};function Hy(r){var e=["x","y"],t=["width","height"];return{point:function(a,n,i){if(a){var o=i.range,s=a[r];return qn(s,o)}},rect:function(a,n,i){if(a){var o=i.range,s=[a[e[r]],a[e[r]]+a[t[r]]];return s[1]<s[0]&&s.reverse(),qn(s[0],o)||qn(s[1],o)||qn(o[0],s)||qn(o[1],s)}}}}function qn(r,e){return e[0]<=r&&r<=e[1]}var Wy=["inBrush","outOfBrush"],Uu="__ecBrushSelect",uv="__ecInBrushSelectEvent";function Y1(r){r.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new Kf(e.option,r);t.setInputRanges(e.areas,r)})}function tG(r,e,t){var a=[],n,i;r.eachComponent({mainType:"brush"},function(o){t&&t.type==="takeGlobalCursor"&&o.setBrushOption(t.key==="brush"?t.brushOption:{brushType:!1})}),Y1(r),r.eachComponent({mainType:"brush"},function(o,s){var l={brushId:o.id,brushIndex:s,brushName:o.name,areas:K(o.areas),selected:[]};a.push(l);var u=o.option,c=u.brushLink,v=[],f=[],h=[],p=!1;s||(n=u.throttleType,i=u.throttleDelay);var d=G(o.areas,function(b){var _=nG[b.brushType],A=J({boundingRect:_?_(b):void 0},b);return A.selectors=Qz(A),A}),g=lv(o.option,Wy,function(b){b.mappingMethod="fixed"});O(c)&&w(c,function(b){v[b]=1});function y(b){return c==="all"||!!v[b]}function m(b){return!!b.length}r.eachSeries(function(b,_){var A=h[_]=[];b.subType==="parallel"?S(b,_):x(b,_,A)});function S(b,_){var A=b.coordinateSystem;p=p||A.hasAxisBrushed(),y(_)&&A.eachActiveState(b.getData(),function(T,C){T==="active"&&(f[C]=1)})}function x(b,_,A){if(!(!b.brushSelector||aG(o,_))&&(w(d,function(C){o.brushTargetManager.controlSeries(C,b,r)&&A.push(C),p=p||m(A)}),y(_)&&m(A))){var T=b.getData();T.each(function(C){$y(b,A,T,C)&&(f[C]=1)})}}r.eachSeries(function(b,_){var A={seriesId:b.id,seriesIndex:_,seriesName:b.name,dataIndex:[]};l.selected.push(A);var T=h[_],C=b.getData(),M=y(_)?function(D){return f[D]?(A.dataIndex.push(C.getRawIndex(D)),"inBrush"):"outOfBrush"}:function(D){return $y(b,T,C,D)?(A.dataIndex.push(C.getRawIndex(D)),"inBrush"):"outOfBrush"};(y(_)?p:m(T))&&jz(Wy,g,C,M)})}),eG(e,n,i,a,t)}function eG(r,e,t,a,n){if(n){var i=r.getZr();if(!i[uv]){i[Uu]||(i[Uu]=rG);var o=In(i,Uu,t,e);o(r,a)}}}function rG(r,e){if(!r.isDisposed()){var t=r.getZr();t[uv]=!0,r.dispatchAction({type:"brushSelect",batch:e}),t[uv]=!1}}function $y(r,e,t,a){for(var n=0,i=e.length;n<i;n++){var o=e[n];if(r.brushSelector(a,t,o.selectors,o))return!0}}function aG(r,e){var t=r.option.seriesIndex;return t!=null&&t!=="all"&&(O(t)?ct(t,e)<0:e!==t)}var nG={rect:function(r){return Uy(r.range)},polygon:function(r){for(var e,t=r.range,a=0,n=t.length;a<n;a++){e=e||[[1/0,-1/0],[1/0,-1/0]];var i=t[a];i[0]<e[0][0]&&(e[0][0]=i[0]),i[0]>e[0][1]&&(e[0][1]=i[0]),i[1]<e[1][0]&&(e[1][0]=i[1]),i[1]>e[1][1]&&(e[1][1]=i[1])}return e&&Uy(e)}};function Uy(r){return new wt(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var iG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){this.ecModel=t,this.api=a,this.model,(this._brushController=new If(a.getZr())).on("brush",W(this._onBrush,this)).mount()},e.prototype.render=function(t,a,n,i){this.model=t,this._updateController(t,a,n,i)},e.prototype.updateTransform=function(t,a,n,i){Y1(a),this._updateController(t,a,n,i)},e.prototype.updateVisual=function(t,a,n,i){this.updateTransform(t,a,n,i)},e.prototype.updateView=function(t,a,n,i){this._updateController(t,a,n,i)},e.prototype._updateController=function(t,a,n,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var a=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:a,areas:K(n),$from:a}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:a,areas:K(n),$from:a})},e.type="brush",e}(Ot);const oG=iG;var sG="#ddd",lG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,a){var n=this.option;!a&&U1(n,t,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:sG},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=G(t,function(a){return Yy(this.option,a)},this))},e.prototype.setBrushOption=function(t){this.brushOption=Yy(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},e}(lt);function Yy(r,e){return ot({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new Dt(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}const uG=lG;var cG=["rect","polygon","lineX","lineY","keep","clear"],vG=function(r){R(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.render=function(t,a,n){var i,o,s;a.eachComponent({mainType:"brush"},function(l){i=l.brushType,o=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=i,this._brushMode=o,w(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?o==="multiple":l==="clear"?s:l===i)?"emphasis":"normal")})},e.prototype.updateView=function(t,a,n){this.render(t,a,n)},e.prototype.getIcons=function(){var t=this.model,a=t.get("icon",!0),n={};return w(t.get("type",!0),function(i){a[i]&&(n[i]=a[i])}),n},e.prototype.onclick=function(t,a,n){var i=this._brushType,o=this._brushMode;n==="clear"?(a.dispatchAction({type:"axisAreaSelect",intervals:[]}),a.dispatchAction({type:"brush",command:"clear",areas:[]})):a.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:n==="keep"?i:i===n?!1:n,brushMode:n==="keep"?o==="multiple"?"single":"multiple":o}})},e.getDefaultOption=function(t){var a={show:!0,type:cG.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return a},e}(Te);const fG=vG;function hG(r){r.registerComponentView(oG),r.registerComponentModel(uG),r.registerPreprocessor(Kz),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,tG),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(a){a.setAreas(e.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},he),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},he),Ka("brush",fG)}var pG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},e}(lt),dG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,a,n){if(this.group.removeAll(),!!t.get("show")){var i=this.group,o=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=St(t.get("textBaseline"),t.get("textVerticalAlign")),c=new ut({style:Ct(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),v=c.getBoundingRect(),f=t.get("subtext"),h=new ut({style:Ct(s,{text:f,fill:s.getTextColor(),y:v.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),p=t.get("link"),d=t.get("sublink"),g=t.get("triggerEvent",!0);c.silent=!p&&!g,h.silent=!d&&!g,p&&c.on("click",function(){ms(p,"_"+t.get("target"))}),d&&h.on("click",function(){ms(d,"_"+t.get("subtarget"))}),q(c).eventData=q(h).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(c),f&&i.add(h);var y=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=y.width,m.height=y.height;var S=Yt(m,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?S.x+=S.width:l==="center"&&(S.x+=S.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?S.y+=S.height:u==="middle"&&(S.y+=S.height/2),u=u||"top"),i.x=S.x,i.y=S.y,i.markRedraw();var x={align:l,verticalAlign:u};c.setStyle(x),h.setStyle(x),y=i.getBoundingRect();var b=S.margin,_=t.getItemStyle(["color","opacity"]);_.fill=t.get("backgroundColor");var A=new ht({shape:{x:y.x-b[3],y:y.y-b[0],width:y.width+b[1]+b[3],height:y.height+b[0]+b[2],r:t.get("borderRadius")},style:_,subPixelOptimize:!0,silent:!0});i.add(A)}},e.type="title",e}(Ot);function gG(r){r.registerComponentModel(pG),r.registerComponentView(dG)}var yG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),this._initData()},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var a=this._data.count();this.option.loop?t=(t%a+a)%a:(t>=a&&(t=a-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,a=t.data||[],n=t.axisType,i=this._names=[],o;n==="category"?(o=[],w(a,function(u,c){var v=Ut(mn(u),""),f;j(u)?(f=K(u),f.value=c):f=c,o.push(f),i.push(v)})):o=a;var s={category:"ordinal",time:"time",value:"number"}[n]||"number",l=this._data=new fe([{name:"value",type:s}],this);l.initData(o,i)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(lt);const Zy=yG;var Z1=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=$r(Zy.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(Zy);jt(Z1,Fv.prototype);const mG=Z1;var SG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e}(Ot);const xG=SG;var _G=function(r){R(e,r);function e(t,a,n,i){var o=r.call(this,t,a,n)||this;return o.type=i||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e}(Ue);const bG=_G;var Yu=Math.PI,Xy=st(),wG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,a){this.api=a},e.prototype.render=function(t,a,n){if(this.model=t,this.api=n,this.ecModel=a,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,n),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(i,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return qt("nameValue",{noName:!0,value:c})},w(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](i,o,l,t)},this),this._renderAxisLabel(i,s,l,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,a){var n=t.get(["label","position"]),i=t.get("orient"),o=TG(t,a),s;n==null||n==="auto"?s=i==="horizontal"?o.y+o.height/2<a.getHeight()/2?"-":"+":o.x+o.width/2<a.getWidth()/2?"+":"-":$(n)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[i][n]:s=n;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:Yu/2},v=i==="vertical"?o.height:o.width,f=t.getModel("controlStyle"),h=f.get("show",!0),p=h?f.get("itemSize"):0,d=h?f.get("itemGap"):0,g=p+d,y=t.get(["label","rotate"])||0;y=y*Yu/180;var m,S,x,b=f.get("position",!0),_=h&&f.get("showPlayBtn",!0),A=h&&f.get("showPrevBtn",!0),T=h&&f.get("showNextBtn",!0),C=0,M=v;b==="left"||b==="bottom"?(_&&(m=[0,0],C+=g),A&&(S=[C,0],C+=g),T&&(x=[M-p,0],M-=g)):(_&&(m=[M-p,0],M-=g),A&&(S=[0,0],C+=g),T&&(x=[M-p,0],M-=g));var D=[C,M];return t.get("inverse")&&D.reverse(),{viewRect:o,mainLength:v,orient:i,rotation:c[i],labelRotation:y,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[i],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[i],playPosition:m,prevBtnPosition:S,nextBtnPosition:x,axisExtent:D,controlSize:p,controlGap:d}},e.prototype._position=function(t,a){var n=this._mainGroup,i=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=yn(),l=o.x,u=o.y+o.height;xa(s,s,[-l,-u]),Fi(s,s,-Yu/2),xa(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=m(o),v=m(n.getBoundingRect()),f=m(i.getBoundingRect()),h=[n.x,n.y],p=[i.x,i.y];p[0]=h[0]=c[0][0];var d=t.labelPosOpt;if(d==null||$(d)){var g=d==="+"?0:1;S(h,v,c,1,g),S(p,f,c,1,1-g)}else{var g=d>=0?0:1;S(h,v,c,1,g),p[1]=h[1]+d}n.setPosition(h),i.setPosition(p),n.rotation=i.rotation=t.rotation,y(n),y(i);function y(x){x.originX=c[0][0]-x.x,x.originY=c[1][0]-x.y}function m(x){return[[x.x,x.x+x.width],[x.y,x.y+x.height]]}function S(x,b,_,A,T){x[A]+=_[A][T]-b[A][T]}},e.prototype._createAxis=function(t,a){var n=a.getData(),i=a.get("axisType"),o=AG(a,i);o.getTicks=function(){return n.mapArray(["value"],function(u){return{value:u}})};var s=n.getDataExtent("value");o.setExtent(s[0],s[1]),o.calcNiceTicks();var l=new bG("value",o,t.axisExtent,i);return l.model=a,l},e.prototype._createGroup=function(t){var a=this[t]=new tt;return this.group.add(a),a},e.prototype._renderAxisLine=function(t,a,n,i){var o=n.getExtent();if(i.get(["lineStyle","show"])){var s=new te({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:B({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});a.add(s);var l=this._progressLine=new te({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:J({lineCap:"round",lineWidth:s.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});a.add(l)}},e.prototype._renderAxisTick=function(t,a,n,i){var o=this,s=i.getData(),l=n.scale.getTicks();this._tickSymbols=[],w(l,function(u){var c=n.dataToCoord(u.value),v=s.getItemModel(u.value),f=v.getModel("itemStyle"),h=v.getModel(["emphasis","itemStyle"]),p=v.getModel(["progress","itemStyle"]),d={x:c,y:0,onclick:W(o._changeTimeline,o,u.value)},g=Ky(v,f,a,d);g.ensureState("emphasis").style=h.getItemStyle(),g.ensureState("progress").style=p.getItemStyle(),ha(g);var y=q(g);v.get("tooltip")?(y.dataIndex=u.value,y.dataModel=i):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,a,n,i){var o=this,s=n.getLabelModel();if(s.get("show")){var l=i.getData(),u=n.getViewLabels();this._tickLabels=[],w(u,function(c){var v=c.tickValue,f=l.getItemModel(v),h=f.getModel("label"),p=f.getModel(["emphasis","label"]),d=f.getModel(["progress","label"]),g=n.dataToCoord(c.tickValue),y=new ut({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:W(o._changeTimeline,o,v),silent:!1,style:Ct(h,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=Ct(p),y.ensureState("progress").style=Ct(d),a.add(y),ha(y),Xy(y).dataIndex=v,o._tickLabels.push(y)})}},e.prototype._renderControl=function(t,a,n,i){var o=t.controlSize,s=t.rotation,l=i.getModel("controlStyle").getItemStyle(),u=i.getModel(["emphasis","controlStyle"]).getItemStyle(),c=i.getPlayState(),v=i.get("inverse",!0);f(t.nextBtnPosition,"next",W(this._changeTimeline,this,v?"-":"+")),f(t.prevBtnPosition,"prev",W(this._changeTimeline,this,v?"+":"-")),f(t.playPosition,c?"stop":"play",W(this._handlePlayClick,this,!c),!0);function f(h,p,d,g){if(h){var y=an(St(i.get(["controlStyle",p+"BtnSize"]),o),o),m=[0,-y/2,y,y],S=CG(i,p+"Icon",m,{x:h[0],y:h[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:d});S.ensureState("emphasis").style=u,a.add(S),ha(S)}}},e.prototype._renderCurrentPointer=function(t,a,n,i){var o=i.getData(),s=i.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,c={onCreate:function(v){v.draggable=!0,v.drift=W(u._handlePointerDrag,u),v.ondragend=W(u._handlePointerDragend,u),qy(v,u._progressLine,s,n,i,!0)},onUpdate:function(v){qy(v,u._progressLine,s,n,i)}};this._currentPointer=Ky(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,a,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,a){var n=this._toAxisCoord(t)[0],i=this._axis,o=Me(i.getExtent().slice());n>o[1]&&(n=o[1]),n<o[0]&&(n=o[0]),this._currentPointer.x=n,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=n,s.dirty());var l=this._findNearestTick(n),u=this.model;(a||l!==u.getCurrentIndex()&&u.get("realtime"))&&this._changeTimeline(l)},e.prototype._doPlayStop=function(){var t=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var a=t.model;t._changeTimeline(a.getCurrentIndex()+(a.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},e.prototype._toAxisCoord=function(t){var a=this._mainGroup.getLocalTransform();return He(t,a,!0)},e.prototype._findNearestTick=function(t){var a=this.model.getData(),n=1/0,i,o=this._axis;return a.each(["value"],function(s,l){var u=o.dataToCoord(s),c=Math.abs(u-t);c<n&&(n=c,i=l)}),i},e.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},e.prototype._changeTimeline=function(t){var a=this.model.getCurrentIndex();t==="+"?t=a+1:t==="-"&&(t=a-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})},e.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),a=this._tickSymbols,n=this._tickLabels;if(a)for(var i=0;i<a.length;i++)a&&a[i]&&a[i].toggleState("progress",i<t);if(n)for(var i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",Xy(n[i]).dataIndex<=t)},e.type="timeline.slider",e}(xG);function AG(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new Jv({ordinalMeta:r.getCategories(),extent:[1/0,-1/0]});case"time":return new hx({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new zr}}function TG(r,e){return Yt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},r.get("padding"))}function CG(r,e,t,a){var n=a.style,i=Yi(r.get(["controlStyle",e]),a||{},new wt(t[0],t[1],t[2],t[3]));return n&&i.setStyle(n),i}function Ky(r,e,t,a,n,i){var o=e.get("color");if(n)n.setColor(o),t.add(n),i&&i.onUpdate(n);else{var s=r.get("symbol");n=Ht(s,-1,-1,2,2,o),n.setStyle("strokeNoScale",!0),t.add(n),i&&i.onCreate(n)}var l=e.getItemStyle(["color"]);n.setStyle(l),a=ot({rectHover:!0,z2:100},a,!0);var u=Ln(r.get("symbolSize"));a.scaleX=u[0]/2,a.scaleY=u[1]/2;var c=Ia(r.get("symbolOffset"),u);c&&(a.x=(a.x||0)+c[0],a.y=(a.y||0)+c[1]);var v=r.get("symbolRotate");return a.rotation=(v||0)*Math.PI/180||0,n.attr(a),n.updateTransform(),n}function qy(r,e,t,a,n,i){if(!r.dragging){var o=n.getModel("checkpointStyle"),s=a.dataToCoord(n.getData().get("value",t));if(i||!o.get("animation",!0))r.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:o.get("animationDuration",!0),easing:o.get("animationEasing",!0)};r.stopAnimation(null,!0),r.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}const DG=wG;function MG(r){r.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,a){var n=t.getComponent("timeline");return n&&e.currentIndex!=null&&(n.setCurrentIndex(e.currentIndex),!n.get("loop",!0)&&n.isIndexMax()&&n.getPlayState()&&(n.setPlayState(!1),a.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:n.get("replaceMerge",!0)}),J({currentIndex:n.option.currentIndex},e)}),r.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var a=t.getComponent("timeline");a&&e.playState!=null&&a.setPlayState(e.playState)})}function IG(r){var e=r&&r.timeline;O(e)||(e=e?[e]:[]),w(e,function(t){t&&LG(t)})}function LG(r){var e=r.type,t={number:"value",time:"time"};if(t[e]&&(r.axisType=t[e],delete r.type),jy(r),ia(r,"controlPosition")){var a=r.controlStyle||(r.controlStyle={});ia(a,"position")||(a.position=r.controlPosition),a.position==="none"&&!ia(a,"show")&&(a.show=!1,delete a.position),delete r.controlPosition}w(r.data||[],function(n){j(n)&&!O(n)&&(!ia(n,"value")&&ia(n,"name")&&(n.value=n.name),jy(n))})}function jy(r){var e=r.itemStyle||(r.itemStyle={}),t=e.emphasis||(e.emphasis={}),a=r.label||r.label||{},n=a.normal||(a.normal={}),i={normal:1,emphasis:1};w(a,function(o,s){!i[s]&&!ia(n,s)&&(n[s]=o)}),t.label&&!ia(a,"emphasis")&&(a.emphasis=t.label,delete t.label)}function ia(r,e){return r.hasOwnProperty(e)}function PG(r){r.registerComponentModel(mG),r.registerComponentView(DG),r.registerSubTypeDefaulter("timeline",function(){return"slider"}),MG(r),r.registerPreprocessor(IG)}function Jf(r,e){if(!r)return!1;for(var t=O(r)?r:[r],a=0;a<t.length;a++)if(t[a]&&t[a][e])return!0;return!1}function Go(r){_a(r,"label",["show"])}var Fo=st(),X1=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.createdBySelf=!1,t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),this._mergeOption(t,n,!1,!0)},e.prototype.isAnimationEnabled=function(){if(kt.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},e.prototype.mergeOption=function(t,a){this._mergeOption(t,a,!1,!1)},e.prototype._mergeOption=function(t,a,n,i){var o=this.mainType;n||a.eachSeries(function(s){var l=s.get(this.mainType,!0),u=Fo(s)[o];if(!l||!l.data){Fo(s)[o]=null;return}u?u._mergeOption(l,a,!0):(i&&Go(l),w(l.data,function(c){c instanceof Array?(Go(c[0]),Go(c[1])):Go(c)}),u=this.createMarkerModelFromSeries(l,this,a),B(u,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),u.__hostSeries=s),Fo(s)[o]=u},this)},e.prototype.formatTooltip=function(t,a,n){var i=this.getData(),o=this.getRawValue(t),s=i.getName(t);return qt("section",{header:this.name,blocks:[qt("nameValue",{name:s,value:o,noName:!s,noValue:o==null})]})},e.prototype.getData=function(){return this._data},e.prototype.setData=function(t){this._data=t},e.getMarkerModelFromSeries=function(t,a){return Fo(t)[a]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e}(lt);jt(X1,Fv.prototype);const Hr=X1;var EG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markPoint",e.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},e}(Hr);const RG=EG;function cv(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function kG(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function Ho(r,e,t,a,n,i){var o=[],s=Br(e,a),l=s?e.getCalculationInfo("stackResultDimension"):a,u=Qf(e,l,r),c=e.indicesOfNearest(l,u)[0];o[n]=e.get(t,c),o[i]=e.get(l,c);var v=e.get(a,c),f=Ke(e.get(a,c));return f=Math.min(f,20),f>=0&&(o[i]=+o[i].toFixed(f)),[o,v]}var Zu={min:Q(Ho,"min"),max:Q(Ho,"max"),average:Q(Ho,"average"),median:Q(Ho,"median")};function Vi(r,e){if(e){var t=r.getData(),a=r.coordinateSystem,n=a&&a.dimensions;if(!kG(e)&&!O(e.coord)&&O(n)){var i=K1(e,t,a,r);if(e=K(e),e.type&&Zu[e.type]&&i.baseAxis&&i.valueAxis){var o=ct(n,i.baseAxis.dim),s=ct(n,i.valueAxis.dim),l=Zu[e.type](t,i.baseDataDim,i.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null||!O(n))e.coord=[];else for(var u=e.coord,c=0;c<2;c++)Zu[u[c]]&&(u[c]=Qf(t,t.mapDimension(n[c]),u[c]));return e}}function K1(r,e,t,a){var n={};return r.valueIndex!=null||r.valueDim!=null?(n.valueDataDim=r.valueIndex!=null?e.getDimension(r.valueIndex):r.valueDim,n.valueAxis=t.getAxis(NG(a,n.valueDataDim)),n.baseAxis=t.getOtherAxis(n.valueAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim)):(n.baseAxis=a.getBaseAxis(),n.valueAxis=t.getOtherAxis(n.baseAxis),n.baseDataDim=e.mapDimension(n.baseAxis.dim),n.valueDataDim=e.mapDimension(n.valueAxis.dim)),n}function NG(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function Bi(r,e){return r&&r.containData&&e.coord&&!cv(e)?r.containData(e.coord):!0}function OG(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!cv(e)&&!cv(t)?r.containZone(e.coord,t.coord):!0}function q1(r,e){return r?function(t,a,n,i){var o=i<2?t.coord&&t.coord[i]:t.value;return Rr(o,e[i])}:function(t,a,n,i){return Rr(t.value,e[i])}}function Qf(r,e,t){if(t==="average"){var a=0,n=0;return r.each(e,function(i,o){isNaN(i)||(a+=i,n++)}),a/n}else return t==="median"?r.getMedian(e):r.getDataExtent(e)[t==="max"?1:0]}var Xu=st(),VG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=Z()},e.prototype.render=function(t,a,n){var i=this,o=this.markerGroupMap;o.each(function(s){Xu(s).keep=!1}),a.eachSeries(function(s){var l=Hr.getMarkerModelFromSeries(s,i.type);l&&i.renderSeries(s,l,a,n)}),o.each(function(s){!Xu(s).keep&&i.group.remove(s.group)})},e.prototype.markKeep=function(t){Xu(t).keep=!0},e.prototype.toggleBlurSeries=function(t,a){var n=this;w(t,function(i){var o=Hr.getMarkerModelFromSeries(i,n.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(a?s0(l):Tv(l))})}})},e.type="marker",e}(Ot);const th=VG;function Jy(r,e,t){var a=e.coordinateSystem;r.each(function(n){var i=r.getItemModel(n),o,s=F(i.get("x"),t.getWidth()),l=F(i.get("y"),t.getHeight());if(!isNaN(s)&&!isNaN(l))o=[s,l];else if(e.getMarkerPosition)o=e.getMarkerPosition(r.getValues(r.dimensions,n));else if(a){var u=r.get(a.dimensions[0],n),c=r.get(a.dimensions[1],n);o=a.dataToPoint([u,c])}isNaN(s)||(o[0]=s),isNaN(l)||(o[1]=l),r.setItemLayout(n,o)})}var BG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Hr.getMarkerModelFromSeries(i,"markPoint");o&&(Jy(o.getData(),i,n),this.markerGroupMap.get(i.id).updateLayout())},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new to),v=zG(o,t,a);a.setData(v),Jy(a.getData(),t,i),v.each(function(f){var h=v.getItemModel(f),p=h.getShallow("symbol"),d=h.getShallow("symbolSize"),g=h.getShallow("symbolRotate"),y=h.getShallow("symbolOffset"),m=h.getShallow("symbolKeepAspect");if(X(p)||X(d)||X(g)||X(y)){var S=a.getRawValue(f),x=a.getDataParams(f);X(p)&&(p=p(S,x)),X(d)&&(d=d(S,x)),X(g)&&(g=g(S,x)),X(y)&&(y=y(S,x))}var b=h.getModel("itemStyle").getItemStyle(),_=Ki(l,"color");b.fill||(b.fill=_),v.setItemVisual(f,{symbol:p,symbolSize:d,symbolRotate:g,symbolOffset:y,symbolKeepAspect:m,style:b})}),c.updateData(v),this.group.add(c.group),v.eachItemGraphicEl(function(f){f.traverse(function(h){q(h).dataModel=a})}),this.markKeep(c),c.group.silent=a.get("silent")||t.get("silent")},e.type="markPoint",e}(th);function zG(r,e,t){var a;r?a=G(r&&r.dimensions,function(s){var l=e.getData().getDimensionInfo(e.getData().mapDimension(s))||{};return B(B({},l),{name:s,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new fe(a,t),i=G(t.get("data"),Q(Vi,e));r&&(i=bt(i,Q(Bi,r)));var o=q1(!!r,a);return n.initData(i,null,o),n}const GG=BG;function FG(r){r.registerComponentModel(RG),r.registerComponentView(GG),r.registerPreprocessor(function(e){Jf(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var HG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e}(Hr);const WG=HG;var Wo=st(),$G=function(r,e,t,a){var n=r.getData(),i;if(O(a))i=a;else{var o=a.type;if(o==="min"||o==="max"||o==="average"||o==="median"||a.xAxis!=null||a.yAxis!=null){var s=void 0,l=void 0;if(a.yAxis!=null||a.xAxis!=null)s=e.getAxis(a.yAxis!=null?"y":"x"),l=Jt(a.yAxis,a.xAxis);else{var u=K1(a,n,e,r);s=u.valueAxis;var c=QS(n,u.valueDataDim);l=Qf(n,c,o)}var v=s.dim==="x"?0:1,f=1-v,h=K(a),p={coord:[]};h.type=null,h.coord=[],h.coord[f]=-1/0,p.coord[f]=1/0;var d=t.get("precision");d>=0&&gt(l)&&(l=+l.toFixed(Math.min(d,20))),h.coord[v]=p.coord[v]=l,i=[h,p,{type:o,valueIndex:a.valueIndex,value:l}]}else i=[]}var g=[Vi(r,i[0]),Vi(r,i[1]),B({},i[2])];return g[2].type=g[2].type||null,ot(g[2],g[0]),ot(g[2],g[1]),g};function zs(r){return!isNaN(r)&&!isFinite(r)}function Qy(r,e,t,a){var n=1-r,i=a.dimensions[r];return zs(e[n])&&zs(t[n])&&e[r]===t[r]&&a.getAxis(i).containData(e[r])}function UG(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,a=e[1].coord;if(t&&a&&(Qy(1,t,a,r)||Qy(0,t,a,r)))return!0}return Bi(r,e[0])&&Bi(r,e[1])}function Ku(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=F(o.get("x"),n.getWidth()),u=F(o.get("y"),n.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(a.getMarkerPosition)s=a.getMarkerPosition(r.getValues(r.dimensions,e));else{var c=i.dimensions,v=r.get(c[0],e),f=r.get(c[1],e);s=i.dataToPoint([v,f])}if(Pa(i,"cartesian2d")){var h=i.getAxis("x"),p=i.getAxis("y"),c=i.dimensions;zs(r.get(c[0],e))?s[0]=h.toGlobalCoord(h.getExtent()[t?0:1]):zs(r.get(c[1],e))&&(s[1]=p.toGlobalCoord(p.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}r.setItemLayout(e,s)}var YG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Hr.getMarkerModelFromSeries(i,"markLine");if(o){var s=o.getData(),l=Wo(o).from,u=Wo(o).to;l.each(function(c){Ku(l,c,!0,i,n),Ku(u,c,!1,i,n)}),s.each(function(c){s.setItemLayout(c,[l.getItemLayout(c),u.getItemLayout(c)])}),this.markerGroupMap.get(i.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new wf);this.group.add(c.group);var v=ZG(o,t,a),f=v.from,h=v.to,p=v.line;Wo(a).from=f,Wo(a).to=h,a.setData(p);var d=a.get("symbol"),g=a.get("symbolSize"),y=a.get("symbolRotate"),m=a.get("symbolOffset");O(d)||(d=[d,d]),O(g)||(g=[g,g]),O(y)||(y=[y,y]),O(m)||(m=[m,m]),v.from.each(function(x){S(f,x,!0),S(h,x,!1)}),p.each(function(x){var b=p.getItemModel(x).getModel("lineStyle").getLineStyle();p.setItemLayout(x,[f.getItemLayout(x),h.getItemLayout(x)]),b.stroke==null&&(b.stroke=f.getItemVisual(x,"style").fill),p.setItemVisual(x,{fromSymbolKeepAspect:f.getItemVisual(x,"symbolKeepAspect"),fromSymbolOffset:f.getItemVisual(x,"symbolOffset"),fromSymbolRotate:f.getItemVisual(x,"symbolRotate"),fromSymbolSize:f.getItemVisual(x,"symbolSize"),fromSymbol:f.getItemVisual(x,"symbol"),toSymbolKeepAspect:h.getItemVisual(x,"symbolKeepAspect"),toSymbolOffset:h.getItemVisual(x,"symbolOffset"),toSymbolRotate:h.getItemVisual(x,"symbolRotate"),toSymbolSize:h.getItemVisual(x,"symbolSize"),toSymbol:h.getItemVisual(x,"symbol"),style:b})}),c.updateData(p),v.line.eachItemGraphicEl(function(x){q(x).dataModel=a,x.traverse(function(b){q(b).dataModel=a})});function S(x,b,_){var A=x.getItemModel(b);Ku(x,b,_,t,i);var T=A.getModel("itemStyle").getItemStyle();T.fill==null&&(T.fill=Ki(l,"color")),x.setItemVisual(b,{symbolKeepAspect:A.get("symbolKeepAspect"),symbolOffset:St(A.get("symbolOffset",!0),m[_?0:1]),symbolRotate:St(A.get("symbolRotate",!0),y[_?0:1]),symbolSize:St(A.get("symbolSize"),g[_?0:1]),symbol:St(A.get("symbol",!0),d[_?0:1]),style:T})}this.markKeep(c),c.group.silent=a.get("silent")||t.get("silent")},e.type="markLine",e}(th);function ZG(r,e,t){var a;r?a=G(r&&r.dimensions,function(u){var c=e.getData().getDimensionInfo(e.getData().mapDimension(u))||{};return B(B({},c),{name:u,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new fe(a,t),i=new fe(a,t),o=new fe([],t),s=G(t.get("data"),Q($G,e,r,t));r&&(s=bt(s,Q(UG,r)));var l=q1(!!r,a);return n.initData(G(s,function(u){return u[0]}),null,l),i.initData(G(s,function(u){return u[1]}),null,l),o.initData(G(s,function(u){return u[2]})),o.hasItemOption=!0,{from:n,to:i,line:o}}const XG=YG;function KG(r){r.registerComponentModel(WG),r.registerComponentView(XG),r.registerPreprocessor(function(e){Jf(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var qG=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,a,n){return new e(t,a,n)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e}(Hr);const jG=qG;var $o=st(),JG=function(r,e,t,a){var n=a[0],i=a[1];if(!(!n||!i)){var o=Vi(r,n),s=Vi(r,i),l=o.coord,u=s.coord;l[0]=Jt(l[0],-1/0),l[1]=Jt(l[1],-1/0),u[0]=Jt(u[0],1/0),u[1]=Jt(u[1],1/0);var c=yv([{},o,s]);return c.coord=[o.coord,s.coord],c.x0=o.x,c.y0=o.y,c.x1=s.x,c.y1=s.y,c}};function Gs(r){return!isNaN(r)&&!isFinite(r)}function tm(r,e,t,a){var n=1-r;return Gs(e[n])&&Gs(t[n])}function QG(r,e){var t=e.coord[0],a=e.coord[1],n={coord:t,x:e.x0,y:e.y0},i={coord:a,x:e.x1,y:e.y1};return Pa(r,"cartesian2d")?t&&a&&(tm(1,t,a)||tm(0,t,a))?!0:OG(r,n,i):Bi(r,n)||Bi(r,i)}function em(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=F(o.get(t[0]),n.getWidth()),u=F(o.get(t[1]),n.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(a.getMarkerPosition){var c=r.getValues(["x0","y0"],e),v=r.getValues(["x1","y1"],e),f=i.clampData(c),h=i.clampData(v),p=[];t[0]==="x0"?p[0]=f[0]>h[0]?v[0]:c[0]:p[0]=f[0]>h[0]?c[0]:v[0],t[1]==="y0"?p[1]=f[1]>h[1]?v[1]:c[1]:p[1]=f[1]>h[1]?c[1]:v[1],s=a.getMarkerPosition(p,t,!0)}else{var d=r.get(t[0],e),g=r.get(t[1],e),y=[d,g];i.clampData&&i.clampData(y,y),s=i.dataToPoint(y,!0)}if(Pa(i,"cartesian2d")){var m=i.getAxis("x"),S=i.getAxis("y"),d=r.get(t[0],e),g=r.get(t[1],e);Gs(d)?s[0]=m.toGlobalCoord(m.getExtent()[t[0]==="x0"?0:1]):Gs(g)&&(s[1]=S.toGlobalCoord(S.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var rm=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],tF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,a,n){a.eachSeries(function(i){var o=Hr.getMarkerModelFromSeries(i,"markArea");if(o){var s=o.getData();s.each(function(l){var u=G(rm,function(v){return em(s,l,v,i,n)});s.setItemLayout(l,u);var c=s.getItemGraphicEl(l);c.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,a,n,i){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,{group:new tt});this.group.add(c.group),this.markKeep(c);var v=eF(o,t,a);a.setData(v),v.each(function(f){var h=G(rm,function(T){return em(v,f,T,t,i)}),p=o.getAxis("x").scale,d=o.getAxis("y").scale,g=p.getExtent(),y=d.getExtent(),m=[p.parse(v.get("x0",f)),p.parse(v.get("x1",f))],S=[d.parse(v.get("y0",f)),d.parse(v.get("y1",f))];Me(m),Me(S);var x=!(g[0]>m[1]||g[1]<m[0]||y[0]>S[1]||y[1]<S[0]),b=!x;v.setItemLayout(f,{points:h,allClipped:b});var _=v.getItemModel(f).getModel("itemStyle").getItemStyle(),A=Ki(l,"color");_.fill||(_.fill=A,$(_.fill)&&(_.fill=vs(_.fill,.4))),_.stroke||(_.stroke=A),v.setItemVisual(f,"style",_)}),v.diff($o(c).data).add(function(f){var h=v.getItemLayout(f);if(!h.allClipped){var p=new Ee({shape:{points:h.points}});v.setItemGraphicEl(f,p),c.group.add(p)}}).update(function(f,h){var p=$o(c).data.getItemGraphicEl(h),d=v.getItemLayout(f);d.allClipped?p&&c.group.remove(p):(p?ft(p,{shape:{points:d.points}},a,f):p=new Ee({shape:{points:d.points}}),v.setItemGraphicEl(f,p),c.group.add(p))}).remove(function(f){var h=$o(c).data.getItemGraphicEl(f);c.group.remove(h)}).execute(),v.eachItemGraphicEl(function(f,h){var p=v.getItemModel(h),d=v.getItemVisual(h,"style");f.useStyle(v.getItemVisual(h,"style")),ae(f,Kt(p),{labelFetcher:a,labelDataIndex:h,defaultText:v.getName(h)||"",inheritColor:$(d.fill)?vs(d.fill,1):"#000"}),re(f,p),Nt(f,null,null,p.get(["emphasis","disabled"])),q(f).dataModel=a}),$o(c).data=v,c.group.silent=a.get("silent")||t.get("silent")},e.type="markArea",e}(th);function eF(r,e,t){var a,n,i=["x0","y0","x1","y1"];if(r){var o=G(r&&r.dimensions,function(u){var c=e.getData(),v=c.getDimensionInfo(c.mapDimension(u))||{};return B(B({},v),{name:u,ordinalMeta:null})});n=G(i,function(u,c){return{name:u,type:o[c%2].type}}),a=new fe(n,t)}else n=[{name:"value",type:"float"}],a=new fe(n,t);var s=G(t.get("data"),Q(JG,e,r,t));r&&(s=bt(s,Q(QG,r)));var l=r?function(u,c,v,f){var h=u.coord[Math.floor(f/2)][f%2];return Rr(h,n[f])}:function(u,c,v,f){return Rr(u.value,n[f])};return a.initData(s,null,l),a.hasItemOption=!0,a}const rF=tF;function aF(r){r.registerComponentModel(jG),r.registerComponentView(rF),r.registerPreprocessor(function(e){Jf(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var nF=function(r,e){if(e==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},iF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),this._updateSelector(t)},e.prototype._updateSelector=function(t){var a=t.selector,n=this.ecModel;a===!0&&(a=t.selector=["all","inverse"]),O(a)&&w(a,function(i,o){$(i)&&(i={type:i}),a[o]=ot(i,nF(n,i.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var a=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),a=!0;break}}!a&&this.select(t[0].get("name"))}},e.prototype._updateData=function(t){var a=[],n=[];t.eachRawSeries(function(l){var u=l.name;n.push(u);var c;if(l.legendVisualProvider){var v=l.legendVisualProvider,f=v.getAllNames();t.isSeriesFiltered(l)||(n=n.concat(f)),f.length?a=a.concat(f):c=!0}else c=!0;c&&Sv(l)&&a.push(l.name)}),this._availableNames=n;var i=this.get("data")||a,o=Z(),s=G(i,function(l){return($(l)||gt(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new Dt(l,this,this.ecModel))},this);this._data=bt(s,function(l){return!!l})},e.prototype.getData=function(){return this._data},e.prototype.select=function(t){var a=this.option.selected,n=this.get("selectedMode");if(n==="single"){var i=this._data;w(i,function(o){a[o.get("name")]=!1})}a[t]=!0},e.prototype.unSelect=function(t){this.get("selectedMode")!=="single"&&(this.option.selected[t]=!1)},e.prototype.toggleSelected=function(t){var a=this.option.selected;a.hasOwnProperty(t)||(a[t]=!0),this[a[t]?"unSelect":"select"](t)},e.prototype.allSelect=function(){var t=this._data,a=this.option.selected;w(t,function(n){a[n.get("name",!0)]=!0})},e.prototype.inverseSelect=function(){var t=this._data,a=this.option.selected;w(t,function(n){var i=n.get("name",!0);a.hasOwnProperty(i)||(a[i]=!0),a[i]=!a[i]})},e.prototype.isSelected=function(t){var a=this.option.selected;return!(a.hasOwnProperty(t)&&!a[t])&&ct(this._availableNames,t)>=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(lt);const vv=iF;var Ua=Q,fv=w,Uo=tt,oF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new Uo),this.group.add(this._selectorGroup=new Uo),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,a,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var o=t.get("align"),s=t.get("orient");(!o||o==="auto")&&(o=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,t,a,n,l,s,u);var c=t.getBoxLayoutParams(),v={width:n.getWidth(),height:n.getHeight()},f=t.get("padding"),h=Yt(c,v,f),p=this.layoutInner(t,o,h,i,l,u),d=Yt(J({width:p.width,height:p.height},c),v,f);this.group.x=d.x-p.x,this.group.y=d.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=B1(p,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,a,n,i,o,s,l){var u=this.getContentGroup(),c=Z(),v=a.get("selectedMode"),f=[];n.eachRawSeries(function(h){!h.get("legendHoverLink")&&f.push(h.id)}),fv(a.getData(),function(h,p){var d=h.get("name");if(!this.newlineDisabled&&(d===""||d===`
`)){var g=new Uo;g.newline=!0,u.add(g);return}var y=n.getSeriesByName(d)[0];if(!c.get(d))if(y){var m=y.getData(),S=m.getVisual("legendLineStyle")||{},x=m.getVisual("legendIcon"),b=m.getVisual("style"),_=this._createItem(y,d,p,h,a,t,S,b,x,v,i);_.on("click",Ua(am,d,null,i,f)).on("mouseover",Ua(hv,y.name,null,i,f)).on("mouseout",Ua(pv,y.name,null,i,f)),c.set(d,!0)}else n.eachRawSeries(function(A){if(!c.get(d)&&A.legendVisualProvider){var T=A.legendVisualProvider;if(!T.containName(d))return;var C=T.indexOfName(d),M=T.getItemVisual(C,"style"),D=T.getItemVisual(C,"legendIcon"),I=zm(M.fill);I&&I[3]===0&&(I[3]=.2,M=B(B({},M),{fill:Yo(I,"rgba")}));var L=this._createItem(A,d,p,h,a,t,{},M,D,v,i);L.on("click",Ua(am,null,d,i,f)).on("mouseover",Ua(hv,null,d,i,f)).on("mouseout",Ua(pv,null,d,i,f)),c.set(d,!0)}},this)},this),o&&this._createSelector(o,a,i,s,l)},e.prototype._createSelector=function(t,a,n,i,o){var s=this.getSelectorGroup();fv(t,function(u){var c=u.type,v=new ut({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect"})}});s.add(v);var f=a.getModel("selectorLabel"),h=a.getModel(["emphasis","selectorLabel"]);ae(v,{normal:f,emphasis:h},{defaultText:u.title}),ha(v)})},e.prototype._createItem=function(t,a,n,i,o,s,l,u,c,v,f){var h=t.visualDrawType,p=o.get("itemWidth"),d=o.get("itemHeight"),g=o.isSelected(a),y=i.get("symbolRotate"),m=i.get("symbolKeepAspect"),S=i.get("icon");c=S||c||"roundRect";var x=sF(c,i,l,u,h,g,f),b=new Uo,_=i.getModel("textStyle");if(X(t.getLegendIcon)&&(!S||S==="inherit"))b.add(t.getLegendIcon({itemWidth:p,itemHeight:d,icon:c,iconRotate:y,itemStyle:x.itemStyle,lineStyle:x.lineStyle,symbolKeepAspect:m}));else{var A=S==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;b.add(lF({itemWidth:p,itemHeight:d,icon:c,iconRotate:A,itemStyle:x.itemStyle,lineStyle:x.lineStyle,symbolKeepAspect:m}))}var T=s==="left"?p+5:-5,C=s,M=o.get("formatter"),D=a;$(M)&&M?D=M.replace("{name}",a??""):X(M)&&(D=M(a));var I=g?_.getTextColor():i.get("inactiveColor");b.add(new ut({style:Ct(_,{text:D,x:T,y:d/2,fill:I,align:C,verticalAlign:"middle"},{inheritColor:I})}));var L=new ht({shape:b.getBoundingRect(),invisible:!0}),P=i.getModel("tooltip");return P.get("show")&&_n({el:L,componentModel:o,itemName:a,itemTooltipOption:P.option}),b.add(L),b.eachChild(function(E){E.silent=!0}),L.silent=!v,this.getContentGroup().add(b),ha(b),b.__legendDataIndex=n,b},e.prototype.layoutInner=function(t,a,n,i,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();da(t.get("orient"),l,t.get("itemGap"),n.width,n.height);var c=l.getBoundingRect(),v=[-c.x,-c.y];if(u.markRedraw(),l.markRedraw(),o){da("horizontal",u,t.get("selectorItemGap",!0));var f=u.getBoundingRect(),h=[-f.x,-f.y],p=t.get("selectorButtonGap",!0),d=t.getOrient().index,g=d===0?"width":"height",y=d===0?"height":"width",m=d===0?"y":"x";s==="end"?h[d]+=c[g]+p:v[d]+=f[g]+p,h[1-d]+=c[y]/2-f[y]/2,u.x=h[0],u.y=h[1],l.x=v[0],l.y=v[1];var S={x:0,y:0};return S[g]=c[g]+p+f[g],S[y]=Math.max(c[y],f[y]),S[m]=Math.min(0,f[m]+h[1-d]),S}else return l.x=v[0],l.y=v[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}(Ot);function sF(r,e,t,a,n,i,o){function s(g,y){g.lineWidth==="auto"&&(g.lineWidth=y.lineWidth>0?2:0),fv(g,function(m,S){g[S]==="inherit"&&(g[S]=y[S])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=r.lastIndexOf("empty",0)===0?"fill":"stroke",v=l.getShallow("decal");u.decal=!v||v==="inherit"?a.decal:sn(v,o),u.fill==="inherit"&&(u.fill=a[n]),u.stroke==="inherit"&&(u.stroke=a[c]),u.opacity==="inherit"&&(u.opacity=(n==="fill"?a:t).opacity),s(u,a);var f=e.getModel("lineStyle"),h=f.getLineStyle();if(s(h,t),u.fill==="auto"&&(u.fill=a.fill),u.stroke==="auto"&&(u.stroke=a.fill),h.stroke==="auto"&&(h.stroke=a.fill),!i){var p=e.get("inactiveBorderWidth"),d=u[c];u.lineWidth=p==="auto"?a.lineWidth>0&&d?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),h.stroke=f.get("inactiveColor"),h.lineWidth=f.get("inactiveWidth")}return{itemStyle:u,lineStyle:h}}function lF(r){var e=r.icon||"roundRect",t=Ht(e,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return t.setStyle(r.itemStyle),t.rotation=(r.iconRotate||0)*Math.PI/180,t.setOrigin([r.itemWidth/2,r.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill="#fff",t.style.lineWidth=2),t}function am(r,e,t,a){pv(r,e,t,a),t.dispatchAction({type:"legendToggleSelect",name:r??e}),hv(r,e,t,a)}function j1(r){for(var e=r.getZr().storage.getDisplayList(),t,a=0,n=e.length;a<n&&!(t=e[a].states.emphasis);)a++;return t&&t.hoverLayer}function hv(r,e,t,a){j1(t)||t.dispatchAction({type:"highlight",seriesName:r,name:e,excludeSeriesId:a})}function pv(r,e,t,a){j1(t)||t.dispatchAction({type:"downplay",seriesName:r,name:e,excludeSeriesId:a})}const J1=oF;function uF(r){var e=r.findComponents({mainType:"legend"});e&&e.length&&r.filterSeries(function(t){for(var a=0;a<e.length;a++)if(!e[a].isSelected(t.name))return!1;return!0})}function jn(r,e,t){var a={},n=r==="toggleSelected",i;return t.eachComponent("legend",function(o){n&&i!=null?o[i?"select":"unSelect"](e.name):r==="allSelect"||r==="inverseSelect"?o[r]():(o[r](e.name),i=o.isSelected(e.name));var s=o.getData();w(s,function(l){var u=l.get("name");if(!(u===`
`||u==="")){var c=o.isSelected(u);a.hasOwnProperty(u)?a[u]=a[u]&&c:a[u]=c}})}),r==="allSelect"||r==="inverseSelect"?{selected:a}:{name:e.name,selected:a}}function cF(r){r.registerAction("legendToggleSelect","legendselectchanged",Q(jn,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",Q(jn,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",Q(jn,"inverseSelect")),r.registerAction("legendSelect","legendselected",Q(jn,"select")),r.registerAction("legendUnSelect","legendunselected",Q(jn,"unSelect"))}function Q1(r){r.registerComponentModel(vv),r.registerComponentView(J1),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,uF),r.registerSubTypeDefaulter("legend",function(){return"plain"}),cF(r)}var vF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},e.prototype.init=function(t,a,n){var i=Tn(t);r.prototype.init.call(this,t,a,n),nm(this,t,i)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),nm(this,this.option,t)},e.type="legend.scroll",e.defaultOption=$r(vv.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:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800}),e}(vv);function nm(r,e,t){var a=r.getOrient(),n=[1,1];n[a.index]=0,Vr(e,t,{type:"box",ignoreSize:!!n})}const fF=vF;var im=tt,qu=["width","height"],ju=["x","y"],hF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!0,t._currentIndex=0,t}return e.prototype.init=function(){r.prototype.init.call(this),this.group.add(this._containerGroup=new im),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new im)},e.prototype.resetInner=function(){r.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},e.prototype.renderInner=function(t,a,n,i,o,s,l){var u=this;r.prototype.renderInner.call(this,t,a,n,i,o,s,l);var c=this._controllerGroup,v=a.get("pageIconSize",!0),f=O(v)?v:[v,v];p("pagePrev",0);var h=a.getModel("pageTextStyle");c.add(new ut({name:"pageText",style:{text:"xx/xx",fill:h.getTextColor(),font:h.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),p("pageNext",1);function p(d,g){var y=d+"DataIndex",m=Yi(a.get("pageIcons",!0)[a.getOrient().name][g],{onclick:W(u._pageGo,u,y,a,i)},{x:-f[0]/2,y:-f[1]/2,width:f[0],height:f[1]});m.name=d,c.add(m)}},e.prototype.layoutInner=function(t,a,n,i,o,s){var l=this.getSelectorGroup(),u=t.getOrient().index,c=qu[u],v=ju[u],f=qu[1-u],h=ju[1-u];o&&da("horizontal",l,t.get("selectorItemGap",!0));var p=t.get("selectorButtonGap",!0),d=l.getBoundingRect(),g=[-d.x,-d.y],y=K(n);o&&(y[c]=n[c]-d[c]-p);var m=this._layoutContentAndController(t,i,y,u,c,f,h,v);if(o){if(s==="end")g[u]+=m[c]+p;else{var S=d[c]+p;g[u]-=S,m[v]-=S}m[c]+=d[c]+p,g[1-u]+=m[h]+m[f]/2-d[f]/2,m[f]=Math.max(m[f],d[f]),m[h]=Math.min(m[h],d[h]+g[1-u]),l.x=g[0],l.y=g[1],l.markRedraw()}return m},e.prototype._layoutContentAndController=function(t,a,n,i,o,s,l,u){var c=this.getContentGroup(),v=this._containerGroup,f=this._controllerGroup;da(t.get("orient"),c,t.get("itemGap"),i?n.width:null,i?null:n.height),da("horizontal",f,t.get("pageButtonItemGap",!0));var h=c.getBoundingRect(),p=f.getBoundingRect(),d=this._showController=h[o]>n[o],g=[-h.x,-h.y];a||(g[i]=c[u]);var y=[0,0],m=[-p.x,-p.y],S=St(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var x=t.get("pageButtonPosition",!0);x==="end"?m[i]+=n[o]-p[o]:y[i]+=p[o]+S}m[1-i]+=h[s]/2-p[s]/2,c.setPosition(g),v.setPosition(y),f.setPosition(m);var b={x:0,y:0};if(b[o]=d?n[o]:h[o],b[s]=Math.max(h[s],p[s]),b[l]=Math.min(0,p[l]+m[1-i]),v.__rectSize=n[o],d){var _={x:0,y:0};_[o]=Math.max(n[o]-p[o]-S,0),_[s]=b[s],v.setClipPath(new ht({shape:_})),v.__rectSize=_[o]}else f.eachChild(function(T){T.attr({invisible:!0,silent:!0})});var A=this._getPageInfo(t);return A.pageIndex!=null&&ft(c,{x:A.contentPosition[0],y:A.contentPosition[1]},d?t:null),this._updatePageInfoView(t,A),b},e.prototype._pageGo=function(t,a,n){var i=this._getPageInfo(a)[t];i!=null&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:a.id})},e.prototype._updatePageInfoView=function(t,a){var n=this._controllerGroup;w(["pagePrev","pageNext"],function(c){var v=c+"DataIndex",f=a[v]!=null,h=n.childOfName(c);h&&(h.setStyle("fill",f?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),h.cursor=f?"pointer":"default")});var i=n.childOfName("pageText"),o=t.get("pageFormatter"),s=a.pageIndex,l=s!=null?s+1:0,u=a.pageCount;i&&o&&i.setStyle("text",$(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},e.prototype._getPageInfo=function(t){var a=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,o=t.getOrient().index,s=qu[o],l=ju[o],u=this._findTargetItemIndex(a),c=n.children(),v=c[u],f=c.length,h=f?1:0,p={contentPosition:[n.x,n.y],pageCount:h,pageIndex:h-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!v)return p;var d=x(v);p.contentPosition[o]=-d.s;for(var g=u+1,y=d,m=d,S=null;g<=f;++g)S=x(c[g]),(!S&&m.e>y.s+i||S&&!b(S,y.s))&&(m.i>y.i?y=m:y=S,y&&(p.pageNextDataIndex==null&&(p.pageNextDataIndex=y.i),++p.pageCount)),m=S;for(var g=u-1,y=d,m=d,S=null;g>=-1;--g)S=x(c[g]),(!S||!b(m,S.s))&&y.i<m.i&&(m=y,p.pagePrevDataIndex==null&&(p.pagePrevDataIndex=y.i),++p.pageCount,++p.pageIndex),y=S;return p;function x(_){if(_){var A=_.getBoundingRect(),T=A[l]+_[l];return{s:T,e:T+A[s],i:_.__legendDataIndex}}}function b(_,A){return _.e>=A&&_.s<=A+i}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var a,n=this.getContentGroup(),i;return n.eachChild(function(o,s){var l=o.__legendDataIndex;i==null&&l!=null&&(i=s),l===t&&(a=s)}),a??i},e.type="legend.scroll",e}(J1);const pF=hF;function dF(r){r.registerAction("legendScroll","legendscroll",function(e,t){var a=e.scrollDataIndex;a!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(n){n.setScrollDataIndex(a)})})}function gF(r){it(Q1),r.registerComponentModel(fF),r.registerComponentView(pF),dF(r)}function yF(r){it(Q1),it(gF)}var mF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=$r(Oi.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(Oi);const SF=mF;var eh=st();function xF(r,e,t){eh(r).coordSysRecordMap.each(function(a){var n=a.dataZoomInfoMap.get(e.uid);n&&(n.getRange=t)})}function _F(r,e){for(var t=eh(r).coordSysRecordMap,a=t.keys(),n=0;n<a.length;n++){var i=a[n],o=t.get(i),s=o.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||tb(t,o))}}}function tb(r,e){if(e){r.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function bF(r,e){var t={model:e,containsPoint:Q(AF,e),dispatchAction:Q(wF,r),dataZoomInfoMap:null,controller:null},a=t.controller=new no(r.getZr());return w(["pan","zoom","scrollMove"],function(n){a.on(n,function(i){var o=[];t.dataZoomInfoMap.each(function(s){if(i.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[n],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,i);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&t.dispatchAction(o)})}),t}function wF(r,e){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function AF(r,e,t,a){return r.coordinateSystem.containPoint([t,a])}function TF(r){var e,t="type_",a={type_true:2,type_move:1,type_false:0,type_undefined:-1},n=!0;return r.each(function(i){var o=i.model,s=o.get("disabled",!0)?!1:o.get("zoomLock",!0)?"move":!0;a[t+s]>a[t+e]&&(e=s),n=n&&o.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!n}}}function CF(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(e,t){var a=eh(t),n=a.coordSysRecordMap||(a.coordSysRecordMap=Z());n.each(function(i){i.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(i){var o=N1(i);w(o.infoList,function(s){var l=s.model.uid,u=n.get(l)||n.set(l,bF(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=Z());c.set(i.uid,{dzReferCoordSysInfo:s,model:i,getRange:null})})}),n.each(function(i){var o=i.controller,s,l=i.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){tb(n,i);return}var c=TF(l);o.enable(c.controlType,c.opt),o.setPointerChecker(i.containsPoint),In(i,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var DF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,a,n){if(r.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),xF(n,t,{pan:W(Ju.pan,this),zoom:W(Ju.zoom,this),scrollMove:W(Ju.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){_F(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e}(Yf),Ju={zoom:function(r,e,t,a){var n=this.range,i=n.slice(),o=r.axisModels[0];if(o){var s=Qu[e](null,[a.originX,a.originY],o,t,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(i[1]-i[0])+i[0],u=Math.max(1/a.scale,0);i[0]=(i[0]-l)*u+l,i[1]=(i[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Ra(0,i,[0,100],0,c.minSpan,c.maxSpan),this.range=i,n[0]!==i[0]||n[1]!==i[1])return i}},pan:om(function(r,e,t,a,n,i){var o=Qu[a]([i.oldX,i.oldY],[i.newX,i.newY],e,n,t);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:om(function(r,e,t,a,n,i){var o=Qu[a]([0,0],[i.scrollDelta,i.scrollDelta],e,n,t);return o.signal*(r[1]-r[0])*i.scrollDelta})};function om(r){return function(e,t,a,n){var i=this.range,o=i.slice(),s=e.axisModels[0];if(s){var l=r(o,s,e,t,a,n);if(Ra(l,o,[0,100],"all"),this.range=o,i[0]!==o[0]||i[1]!==o[1])return o}}}var Qu={grid:function(r,e,t,a,n){var i=t.axis,o={},s=n.model.coordinateSystem.getRect();return r=r||[0,0],i.dim==="x"?(o.pixel=e[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=i.inverse?-1:1),o},polar:function(r,e,t,a,n){var i=t.axis,o={},s=n.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=i.inverse?1:-1):(o.pixel=e[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=i.inverse?-1:1),o},singleAxis:function(r,e,t,a,n){var i=t.axis,o=n.model.coordinateSystem.getRect(),s={};return r=r||[0,0],i.orient==="horizontal"?(s.pixel=e[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=i.inverse?1:-1):(s.pixel=e[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=i.inverse?-1:1),s}};const MF=DF;function eb(r){Zf(r),r.registerComponentModel(SF),r.registerComponentView(MF),CF(r)}var IF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=$r(Oi.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(Oi);const LF=IF;var Jn=ht,sm=7,PF=1,tc=30,EF=7,Qn="horizontal",lm="vertical",RF=5,kF=["line","bar","candlestick","scatter"],NF={easing:"cubicOut",duration:100,delay:0},OF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,a){this.api=a,this._onBrush=W(this._onBrush,this),this._onBrushEnd=W(this._onBrushEnd,this)},e.prototype.render=function(t,a,n,i){if(r.prototype.render.apply(this,arguments),In(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!i||i.type!=="dataZoom"||i.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Di(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var a=this._displayables.sliderGroup=new tt;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(a),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,a=this.api,n=t.get("brushSelect"),i=n?EF:0,o=this._findCoordRect(),s={width:a.getWidth(),height:a.getHeight()},l=this._orient===Qn?{right:s.width-o.x-o.width,top:s.height-tc-sm-i,width:o.width,height:tc}:{right:sm,top:o.y,width:tc,height:o.height},u=Tn(t.option);w(["right","top","width","height"],function(v){u[v]==="ph"&&(u[v]=l[v])});var c=Yt(u,s);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===lm&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,a=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),o=i&&i.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(n===Qn&&!o?{scaleY:l?1:-1,scaleX:1}:n===Qn&&o?{scaleY:l?1:-1,scaleX:-1}:n===lm&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]);t.x=a.x-u.x,t.y=a.y-u.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,a=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect");n.add(new Jn({silent:!0,shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new Jn({shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:"transparent"},z2:0,onclick:W(this._onClickPanel,this)}),s=this.api.getZr();i?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),n.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var a=this._size,n=this._shadowSize||[],i=t.series,o=i.getRawData(),s=i.getShadowDim&&i.getShadowDim(),l=s&&o.getDimensionInfo(s)?i.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||a[0]!==n[0]||a[1]!==n[1]){var v=o.getDataExtent(l),f=(v[1]-v[0])*.3;v=[v[0]-f,v[1]+f];var h=[0,a[1]],p=[0,a[0]],d=[[a[0],0],[0,0]],g=[],y=p[1]/(o.count()-1),m=0,S=Math.round(o.count()/a[0]),x;o.each([l],function(C,M){if(S>0&&M%S){m+=y;return}var D=C==null||isNaN(C)||C==="",I=D?0:mt(C,v,h,!0);D&&!x&&M?(d.push([d[d.length-1][0],0]),g.push([g[g.length-1][0],0])):!D&&x&&(d.push([m,0]),g.push([m,0])),d.push([m,I]),g.push([m,I]),m+=y,x=D}),u=this._shadowPolygonPts=d,c=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=l,this._shadowSize=[a[0],a[1]];var b=this.dataZoomModel;function _(C){var M=b.getModel(C?"selectedDataBackground":"dataBackground"),D=new tt,I=new Ee({shape:{points:u},segmentIgnoreThreshold:1,style:M.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),L=new me({shape:{points:c},segmentIgnoreThreshold:1,style:M.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return D.add(I),D.add(L),D}for(var A=0;A<3;A++){var T=_(A===1);this._displayables.sliderGroup.add(T),this._displayables.dataShadowSegs.push(T)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,a=t.get("showDataShadow");if(a!==!1){var n,i=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();w(l,function(u){if(!n&&!(a!==!0&&ct(kF,u.get("type"))<0)){var c=i.getComponent(Lr(o),s).axis,v=VF(o),f,h=u.coordinateSystem;v!=null&&h.getOtherAxis&&(f=h.getOtherAxis(c).inverse),v=u.getData().mapDimension(v),n={thisAxis:c,series:u,thisDim:o,otherDim:v,otherAxisInverse:f}}},this)},this),n}},e.prototype._renderHandle=function(){var t=this.group,a=this._displayables,n=a.handles=[null,null],i=a.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,v=l.get("brushSelect"),f=a.filler=new Jn({silent:v,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(f),o.add(new Jn({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:PF,fill:"rgba(0,0,0,0)"}})),w([0,1],function(S){var x=l.get("handleIcon");!_s[x]&&x.indexOf("path://")<0&&x.indexOf("image://")<0&&(x="path://"+x);var b=Ht(x,-1,0,2,2,null,!0);b.attr({cursor:um(this._orient),draggable:!0,drift:W(this._onDragMove,this,S),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1),z2:5});var _=b.getBoundingRect(),A=l.get("handleSize");this._handleHeight=F(A,this._size[1]),this._handleWidth=_.width/_.height*this._handleHeight,b.setStyle(l.getModel("handleStyle").getItemStyle()),b.style.strokeNoScale=!0,b.rectHover=!0,b.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),ha(b);var T=l.get("handleColor");T!=null&&(b.style.fill=T),o.add(n[S]=b);var C=l.getModel("textStyle");t.add(i[S]=new ut({silent:!0,invisible:!0,style:Ct(C,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:C.getTextColor(),font:C.getFont()}),z2:10}))},this);var h=f;if(v){var p=F(l.get("moveHandleSize"),s[1]),d=a.moveHandle=new ht({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:p}}),g=p*.8,y=a.moveHandleIcon=Ht(l.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);y.silent=!0,y.y=s[1]+p/2-.5,d.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(p,10));h=a.moveZone=new ht({invisible:!0,shape:{y:s[1]-m,height:p+m}}),h.on("mouseover",function(){u.enterEmphasis(d)}).on("mouseout",function(){u.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(h)}h.attr({draggable:!0,cursor:um(this._orient),drift:W(this._onDragMove,this,"all"),ondragstart:W(this._showDataInfo,this,!0),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),a=this._getViewExtent();this._handleEnds=[mt(t[0],[0,100],a,!0),mt(t[1],[0,100],a,!0)]},e.prototype._updateInterval=function(t,a){var n=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),s=n.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Ra(a,i,o,n.get("zoomLock")?"all":t,s.minSpan!=null?mt(s.minSpan,l,o,!0):null,s.maxSpan!=null?mt(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=Me([mt(i[0],o,l,!0),mt(i[1],o,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var a=this._displayables,n=this._handleEnds,i=Me(n.slice()),o=this._size;w([0,1],function(h){var p=a.handles[h],d=this._handleHeight;p.attr({scaleX:d/2,scaleY:d/2,x:n[h]+(h?-1:1),y:o[1]/2-d/2})},this),a.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:o[1]});var s={x:i[0],width:i[1]-i[0]};a.moveHandle&&(a.moveHandle.setShape(s),a.moveZone.setShape(s),a.moveZone.getBoundingRect(),a.moveHandleIcon&&a.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=a.dataShadowSegs,u=[0,i[0],i[1],o[0]],c=0;c<l.length;c++){var v=l[c],f=v.getClipPath();f||(f=new ht,v.setClipPath(f)),f.setShape({x:u[c],y:0,width:u[c+1]-u[c],height:o[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var a=this.dataZoomModel,n=this._displayables,i=n.handleLabels,o=this._orient,s=["",""];if(a.get("showDetail")){var l=a.findRepresentativeAxisProxy();if(l){var u=l.getAxisModel().axis,c=this._range,v=t?l.calculateDataWindow({start:c[0],end:c[1]}).valueWindow:l.getDataValueWindow();s=[this._formatLabel(v[0],u),this._formatLabel(v[1],u)]}}var f=Me(this._handleEnds.slice());h.call(this,0),h.call(this,1);function h(p){var d=pa(n.handles[p].parent,this.group),g=qs(p===0?"right":"left",d),y=this._handleWidth/2+RF,m=He([f[p]+(p===0?-y:y),this._size[1]/2],d);i[p].setStyle({x:m[0],y:m[1],verticalAlign:o===Qn?"middle":g,align:o===Qn?g:"center",text:s[p]})}},e.prototype._formatLabel=function(t,a){var n=this.dataZoomModel,i=n.get("labelFormatter"),o=n.get("labelPrecision");(o==null||o==="auto")&&(o=a.getPixelPrecision());var s=t==null||isNaN(t)?"":a.type==="category"||a.type==="time"?a.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(o,20));return X(i)?i(t,s):$(i)?i.replace("{value}",s):s},e.prototype._showDataInfo=function(t){t=this._dragging||t;var a=this._displayables,n=a.handleLabels;n[0].attr("invisible",!t),n[1].attr("invisible",!t),a.moveHandle&&this.api[t?"enterEmphasis":"leaveEmphasis"](a.moveHandle,1)},e.prototype._onDragMove=function(t,a,n,i){this._dragging=!0,Nr(i.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=He([a,n],o,!0),l=this._updateInterval(t,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},e.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var a=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(n[0]<0||n[0]>a[0]||n[1]<0||n[1]>a[1])){var i=this._handleEnds,o=(i[0]+i[1])/2,s=this._updateInterval("all",n[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var a=t.offsetX,n=t.offsetY;this._brushStart=new Gt(a,n),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var a=this._displayables.brushRect;if(this._brushing=!1,!!a){a.attr("ignore",!0);var n=a.shape,i=+new Date;if(!(i-this._brushStartTime<200&&Math.abs(n.width)<5)){var o=this._getViewExtent(),s=[0,100];this._range=Me([mt(n.x,o,s,!0),mt(n.x+n.width,o,s,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(Nr(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,a){var n=this._displayables,i=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new Jn({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,a),c=l.transformCoordToLocal(s.x,s.y),v=this._size;u[0]=Math.max(Math.min(v[0],u[0]),0),o.setShape({x:c[0],y:0,width:u[0]-c[0],height:v[1]})},e.prototype._dispatchZoomAction=function(t){var a=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?NF:null,start:a[0],end:a[1]})},e.prototype._findCoordRect=function(){var t,a=N1(this.dataZoomModel).infoList;if(!t&&a.length){var n=a[0].model.coordinateSystem;t=n.getRect&&n.getRect()}if(!t){var i=this.api.getWidth(),o=this.api.getHeight();t={x:i*.2,y:o*.2,width:i*.6,height:o*.6}}return t},e.type="dataZoom.slider",e}(Yf);function VF(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function um(r){return r==="vertical"?"ns-resize":"ew-resize"}const BF=OF;function rb(r){r.registerComponentModel(LF),r.registerComponentView(BF),Zf(r)}function zF(r){it(eb),it(rb)}var GF={get:function(r,e,t){var a=K((FF[r]||{})[e]);return t&&O(a)?a[a.length-1]:a}},FF={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}};const ab=GF;var cm=ee.mapVisual,HF=ee.eachVisual,WF=O,vm=w,$F=Me,UF=mt,YF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n)},e.prototype.optionUpdated=function(t,a){var n=this.option;!a&&U1(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var a=this.stateList;t=W(t,this),this.controllerVisuals=lv(this.option.controller,a,t),this.targetVisuals=lv(this.option.target,a,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,a=[];return t==null||t==="all"?this.ecModel.eachSeries(function(n,i){a.push(i)}):a=_t(t),a},e.prototype.eachTargetSeries=function(t,a){w(this.getTargetSeriesIndices(),function(n){var i=this.ecModel.getSeriesByIndex(n);i&&t.call(a,i)},this)},e.prototype.isTargetSeries=function(t){var a=!1;return this.eachTargetSeries(function(n){n===t&&(a=!0)}),a},e.prototype.formatValueText=function(t,a,n){var i=this.option,o=i.precision,s=this.dataBound,l=i.formatter,u;n=n||["<",">"],O(t)&&(t=t.slice(),u=!0);var c=a?t:u?[v(t[0]),v(t[1])]:v(t);if($(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(X(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?n[0]+" "+c[1]:t[1]===s[1]?n[1]+" "+c[0]:c[0]+" - "+c[1];return c;function v(f){return f===s[0]?"min":f===s[1]?"max":(+f).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,a=$F([t.min,t.max]);this._dataExtent=a},e.prototype.getDataDimensionIndex=function(t){var a=this.option.dimension;if(a!=null)return t.getDimensionIndex(a);for(var n=t.dimensions,i=n.length-1;i>=0;i--){var o=n[i],s=t.getDimensionInfo(o);if(!s.isCalculationCoord)return s.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,a=this.option,n={inRange:a.inRange,outOfRange:a.outOfRange},i=a.target||(a.target={}),o=a.controller||(a.controller={});ot(i,n),ot(o,n);var s=this.isCategory();l.call(this,i),l.call(this,o),u.call(this,i,"inRange","outOfRange"),c.call(this,o);function l(v){WF(a.color)&&!v.inRange&&(v.inRange={color:a.color.slice().reverse()}),v.inRange=v.inRange||{color:t.get("gradientColor")}}function u(v,f,h){var p=v[f],d=v[h];p&&!d&&(d=v[h]={},vm(p,function(g,y){if(ee.isValidType(y)){var m=ab.get(y,"inactive",s);m!=null&&(d[y]=m,y==="color"&&!d.hasOwnProperty("opacity")&&!d.hasOwnProperty("colorAlpha")&&(d.opacity=[0,0]))}}))}function c(v){var f=(v.inRange||{}).symbol||(v.outOfRange||{}).symbol,h=(v.inRange||{}).symbolSize||(v.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),d=this.getItemSymbol(),g=d||"roundRect";vm(this.stateList,function(y){var m=this.itemSize,S=v[y];S||(S=v[y]={color:s?p:[p]}),S.symbol==null&&(S.symbol=f&&K(f)||(s?g:[g])),S.symbolSize==null&&(S.symbolSize=h&&K(h)||(s?m[0]:[m[0],m[0]])),S.symbol=cm(S.symbol,function(_){return _==="none"?g:_});var x=S.symbolSize;if(x!=null){var b=-1/0;HF(x,function(_){_>b&&(b=_)}),S.symbolSize=cm(x,function(_){return UF(_,[0,b],[0,m[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(lt);const Fs=YF;var fm=[20,140],ZF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,a){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(n){n.mappingMethod="linear",n.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=fm[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=fm[1])},e.prototype._resetRange=function(){var t=this.getExtent(),a=this.option.range;!a||a.auto?(t.auto=1,this.option.range=t):O(a)&&(a[0]>a[1]&&a.reverse(),a[0]=Math.max(a[0],t[0]),a[1]=Math.min(a[1],t[1]))},e.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),w(this.stateList,function(t){var a=this.option.controller[t].symbolSize;a&&a[0]!==a[1]&&(a[0]=a[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),a=Me((this.get("range")||[]).slice());return a[0]>t[1]&&(a[0]=t[1]),a[1]>t[1]&&(a[1]=t[1]),a[0]<t[0]&&(a[0]=t[0]),a[1]<t[0]&&(a[1]=t[0]),a},e.prototype.getValueState=function(t){var a=this.option.range,n=this.getExtent();return(a[0]<=n[0]||a[0]<=t)&&(a[1]>=n[1]||t<=a[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var a=[];return this.eachTargetSeries(function(n){var i=[],o=n.getData();o.each(this.getDataDimensionIndex(o),function(s,l){t[0]<=s&&s<=t[1]&&i.push(l)},this),a.push({seriesId:n.id,dataIndex:i})},this),a},e.prototype.getVisualMeta=function(t){var a=hm(this,"outOfRange",this.getExtent()),n=hm(this,"inRange",this.option.range.slice()),i=[];function o(h,p){i.push({value:h,color:t(h,p)})}for(var s=0,l=0,u=n.length,c=a.length;l<c&&(!n.length||a[l]<=n[0]);l++)a[l]<n[s]&&o(a[l],"outOfRange");for(var v=1;s<u;s++,v=0)v&&i.length&&o(n[s],"outOfRange"),o(n[s],"inRange");for(var v=1;l<c;l++)(!n.length||n[n.length-1]<a[l])&&(v&&(i.length&&o(i[i.length-1].value,"outOfRange"),v=0),o(a[l],"outOfRange"));var f=i.length;return{stops:i,outerColors:[f?i[0].color:"transparent",f?i[f-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=$r(Fs.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:"#fff",borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}}),e}(Fs);function hm(r,e,t){if(t[0]===t[1])return t.slice();for(var a=200,n=(t[1]-t[0])/a,i=t[0],o=[],s=0;s<=a&&i<t[1];s++)o.push(i),i+=n;return o.push(t[1]),o}const XF=ZF;var KF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}return e.prototype.init=function(t,a){this.ecModel=t,this.api=a},e.prototype.render=function(t,a,n,i){if(this.visualMapModel=t,t.get("show")===!1){this.group.removeAll();return}this.doRender(t,a,n,i)},e.prototype.renderBackground=function(t){var a=this.visualMapModel,n=An(a.get("padding")||0),i=t.getBoundingRect();t.add(new ht({z2:-1,silent:!0,shape:{x:i.x-n[3],y:i.y-n[0],width:i.width+n[3]+n[1],height:i.height+n[0]+n[2]},style:{fill:a.get("backgroundColor"),stroke:a.get("borderColor"),lineWidth:a.get("borderWidth")}}))},e.prototype.getControllerVisual=function(t,a,n){n=n||{};var i=n.forceState,o=this.visualMapModel,s={};if(a==="color"){var l=o.get("contentColor");s.color=l}function u(h){return s[h]}function c(h,p){s[h]=p}var v=o.controllerVisuals[i||o.getValueState(t)],f=ee.prepareVisualTypes(v);return w(f,function(h){var p=v[h];n.convertOpacityToAlpha&&h==="opacity"&&(h="colorAlpha",p=v.__alphaForOpacity),ee.dependsOn(h,a)&&p&&p.applyVisual(t,u,c)}),s[a]},e.prototype.positionGroup=function(t){var a=this.visualMapModel,n=this.api;al(t,a.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})},e.prototype.doRender=function(t,a,n,i){},e.type="visualMap",e}(Ot);const nb=KF;var pm=[["left","right","width"],["top","bottom","height"]];function ib(r,e,t){var a=r.option,n=a.align;if(n!=null&&n!=="auto")return n;for(var i={width:e.getWidth(),height:e.getHeight()},o=a.orient==="horizontal"?1:0,s=pm[o],l=[0,null,10],u={},c=0;c<3;c++)u[pm[1-o][c]]=l[c],u[s[c]]=c===2?t[0]:a[s[c]];var v=[["x","width",3],["y","height",0]][o],f=Yt(u,i,a.padding);return s[(f.margin[v[2]]||0)+f[v[0]]+f[v[1]]*.5<i[v[1]]*.5?0:1]}function ns(r,e){return w(r||[],function(t){t.dataIndex!=null&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),r}var Ze=mt,qF=w,dm=Math.min,ec=Math.max,jF=12,JF=6,QF=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}return e.prototype.doRender=function(t,a,n,i){this._api=n,(!i||i.type!=="selectDataRange"||i.from!==this.uid)&&this._buildView()},e.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,a=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(a);var n=t.get("text");this._renderEndsText(a,n,0),this._renderEndsText(a,n,1),this._updateView(!0),this.renderBackground(a),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(a)},e.prototype._renderEndsText=function(t,a,n){if(a){var i=a[1-n];i=i!=null?i+"":"";var o=this.visualMapModel,s=o.get("textGap"),l=o.itemSize,u=this._shapes.mainGroup,c=this._applyTransform([l[0]/2,n===0?-s:l[1]+s],u),v=this._applyTransform(n===0?"bottom":"top",u),f=this._orient,h=this.visualMapModel.textStyleModel;this.group.add(new ut({style:Ct(h,{x:c[0],y:c[1],verticalAlign:f==="horizontal"?"middle":v,align:f==="horizontal"?v:"center",text:i})}))}},e.prototype._renderBar=function(t){var a=this.visualMapModel,n=this._shapes,i=a.itemSize,o=this._orient,s=this._useHandle,l=ib(a,this.api,i),u=n.mainGroup=this._createBarGroup(l),c=new tt;u.add(c),c.add(n.outOfRange=gm()),c.add(n.inRange=gm(null,s?mm(this._orient):null,W(this._dragHandle,this,"all",!1),W(this._dragHandle,this,"all",!0))),c.setClipPath(new ht({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));var v=a.textStyleModel.getTextRect("国"),f=ec(v.width,v.height);s&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(a,u,0,i,f,o),this._createHandle(a,u,1,i,f,o)),this._createIndicator(a,u,i,f,o),t.add(u)},e.prototype._createHandle=function(t,a,n,i,o,s){var l=W(this._dragHandle,this,n,!1),u=W(this._dragHandle,this,n,!0),c=an(t.get("handleSize"),i[0]),v=Ht(t.get("handleIcon"),-c/2,-c/2,c,c,null,!0),f=mm(this._orient);v.attr({cursor:f,draggable:!0,drift:l,ondragend:u,onmousemove:function(y){Nr(y.event)}}),v.x=i[0]/2,v.useStyle(t.getModel("handleStyle").getItemStyle()),v.setStyle({strokeNoScale:!0,strokeFirst:!0}),v.style.lineWidth*=2,v.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),la(v,!0),a.add(v);var h=this.visualMapModel.textStyleModel,p=new ut({cursor:f,draggable:!0,drift:l,onmousemove:function(y){Nr(y.event)},ondragend:u,style:Ct(h,{x:0,y:0,text:""})});p.ensureState("blur").style={opacity:.1},p.stateTransition={duration:200},this.group.add(p);var d=[c,0],g=this._shapes;g.handleThumbs[n]=v,g.handleLabelPoints[n]=d,g.handleLabels[n]=p},e.prototype._createIndicator=function(t,a,n,i,o){var s=an(t.get("indicatorSize"),n[0]),l=Ht(t.get("indicatorIcon"),-s/2,-s/2,s,s,null,!0);l.attr({cursor:"move",invisible:!0,silent:!0,x:n[0]/2});var u=t.getModel("indicatorStyle").getItemStyle();if(l instanceof ke){var c=l.style;l.useStyle(B({image:c.image,x:c.x,y:c.y,width:c.width,height:c.height},u))}else l.useStyle(u);a.add(l);var v=this.visualMapModel.textStyleModel,f=new ut({silent:!0,invisible:!0,style:Ct(v,{x:0,y:0,text:""})});this.group.add(f);var h=[(o==="horizontal"?i/2:JF)+n[0]/2,0],p=this._shapes;p.indicator=l,p.indicatorLabel=f,p.indicatorLabelPoint=h,this._firstShowIndicator=!0},e.prototype._dragHandle=function(t,a,n,i){if(this._useHandle){if(this._dragging=!a,!a){var o=this._applyTransform([n,i],this._shapes.mainGroup,!0);this._updateInterval(t,o[1]),this._hideIndicator(),this._updateView()}a===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),a?!this._hovering&&this._clearHoverLinkToSeries():ym(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1)}},e.prototype._resetInterval=function(){var t=this.visualMapModel,a=this._dataInterval=t.getSelected(),n=t.getExtent(),i=[0,t.itemSize[1]];this._handleEnds=[Ze(a[0],n,i,!0),Ze(a[1],n,i,!0)]},e.prototype._updateInterval=function(t,a){a=a||0;var n=this.visualMapModel,i=this._handleEnds,o=[0,n.itemSize[1]];Ra(a,i,o,t,0);var s=n.getExtent();this._dataInterval=[Ze(i[0],o,s,!0),Ze(i[1],o,s,!0)]},e.prototype._updateView=function(t){var a=this.visualMapModel,n=a.getExtent(),i=this._shapes,o=[0,a.itemSize[1]],s=t?o:this._handleEnds,l=this._createBarVisual(this._dataInterval,n,s,"inRange"),u=this._createBarVisual(n,n,o,"outOfRange");i.inRange.setStyle({fill:l.barColor}).setShape("points",l.barPoints),i.outOfRange.setStyle({fill:u.barColor}).setShape("points",u.barPoints),this._updateHandle(s,l)},e.prototype._createBarVisual=function(t,a,n,i){var o={forceState:i,convertOpacityToAlpha:!0},s=this._makeColorGradient(t,o),l=[this.getControllerVisual(t[0],"symbolSize",o),this.getControllerVisual(t[1],"symbolSize",o)],u=this._createBarPoints(n,l);return{barColor:new $s(0,0,0,1,s),barPoints:u,handlesColor:[s[0].color,s[s.length-1].color]}},e.prototype._makeColorGradient=function(t,a){var n=100,i=[],o=(t[1]-t[0])/n;i.push({color:this.getControllerVisual(t[0],"color",a),offset:0});for(var s=1;s<n;s++){var l=t[0]+o*s;if(l>t[1])break;i.push({color:this.getControllerVisual(l,"color",a),offset:s/n})}return i.push({color:this.getControllerVisual(t[1],"color",a),offset:1}),i},e.prototype._createBarPoints=function(t,a){var n=this.visualMapModel.itemSize;return[[n[0]-a[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-a[1],t[1]]]},e.prototype._createBarGroup=function(t){var a=this._orient,n=this.visualMapModel.get("inverse");return new tt(a==="horizontal"&&!n?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:a==="horizontal"&&n?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:a==="vertical"&&!n?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,a){if(this._useHandle){var n=this._shapes,i=this.visualMapModel,o=n.handleThumbs,s=n.handleLabels,l=i.itemSize,u=i.getExtent();qF([0,1],function(c){var v=o[c];v.setStyle("fill",a.handlesColor[c]),v.y=t[c];var f=Ze(t[c],[0,l[1]],u,!0),h=this.getControllerVisual(f,"symbolSize");v.scaleX=v.scaleY=h/l[0],v.x=l[0]-h/2;var p=He(n.handleLabelPoints[c],pa(v,this.group));s[c].setStyle({x:p[0],y:p[1],text:i.formatValueText(this._dataInterval[c]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",n.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,a,n,i){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],c=this._shapes,v=c.indicator;if(v){v.attr("invisible",!1);var f={convertOpacityToAlpha:!0},h=this.getControllerVisual(t,"color",f),p=this.getControllerVisual(t,"symbolSize"),d=Ze(t,s,u,!0),g=l[0]-p/2,y={x:v.x,y:v.y};v.y=d,v.x=g;var m=He(c.indicatorLabelPoint,pa(v,this.group)),S=c.indicatorLabel;S.attr("invisible",!1);var x=this._applyTransform("left",c.mainGroup),b=this._orient,_=b==="horizontal";S.setStyle({text:(n||"")+o.formatValueText(a),verticalAlign:_?x:"middle",align:_?"center":x});var A={x:g,y:d,style:{fill:h}},T={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var C={duration:100,easing:"cubicInOut",additive:!0};v.x=y.x,v.y=y.y,v.animateTo(A,C),S.animateTo(T,C)}else v.attr(A),S.attr(T);this._firstShowIndicator=!1;var M=this._shapes.handleLabels;if(M)for(var D=0;D<M.length;D++)this._api.enterBlur(M[D])}},e.prototype._enableHoverLinkToSeries=function(){var t=this;this._shapes.mainGroup.on("mousemove",function(a){if(t._hovering=!0,!t._dragging){var n=t.visualMapModel.itemSize,i=t._applyTransform([a.offsetX,a.offsetY],t._shapes.mainGroup,!0,!0);i[1]=dm(ec(0,i[1]),n[1]),t._doHoverLinkToSeries(i[1],0<=i[0]&&i[0]<=n[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},e.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},e.prototype._doHoverLinkToSeries=function(t,a){var n=this.visualMapModel,i=n.itemSize;if(n.option.hoverLink){var o=[0,i[1]],s=n.getExtent();t=dm(ec(o[0],t),o[1]);var l=t5(n,s,o),u=[t-l,t+l],c=Ze(t,o,s,!0),v=[Ze(u[0],o,s,!0),Ze(u[1],o,s,!0)];u[0]<o[0]&&(v[0]=-1/0),u[1]>o[1]&&(v[1]=1/0),a&&(v[0]===-1/0?this._showIndicator(c,v[1],"< ",l):v[1]===1/0?this._showIndicator(c,v[0],"> ",l):this._showIndicator(c,c,"≈ ",l));var f=this._hoverLinkDataIndices,h=[];(a||ym(n))&&(h=this._hoverLinkDataIndices=n.findTargetDataIndices(v));var p=mw(f,h);this._dispatchHighDown("downplay",ns(p[0],n)),this._dispatchHighDown("highlight",ns(p[1],n))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var a;if(ca(t.target,function(l){var u=q(l);if(u.dataIndex!=null)return a=u,!0},!0),!!a){var n=this.ecModel.getSeriesByIndex(a.seriesIndex),i=this.visualMapModel;if(i.isTargetSeries(n)){var o=n.getData(a.dataType),s=o.getStore().get(i.getDataDimensionIndex(o),a.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var a=this._shapes.handleLabels;if(a)for(var n=0;n<a.length;n++)this._api.leaveBlur(a[n])},e.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",ns(t,this.visualMapModel)),t.length=0},e.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},e.prototype._applyTransform=function(t,a,n,i){var o=pa(a,i?null:this.group);return O(t)?He(t,o,n):qs(t,o,n)},e.prototype._dispatchHighDown=function(t,a){a&&a.length&&this.api.dispatchAction({type:t,batch:a})},e.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.prototype.remove=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.type="visualMap.continuous",e}(nb);function gm(r,e,t,a){return new Ee({shape:{points:r},draggable:!!t,cursor:e,drift:t,onmousemove:function(n){Nr(n.event)},ondragend:a})}function t5(r,e,t){var a=jF/2,n=r.get("hoverLinkDataSize");return n&&(a=Ze(n,e,t,!0)/2),a}function ym(r){var e=r.get("hoverLinkOnHandle");return!!(e??r.get("realtime"))}function mm(r){return r==="vertical"?"ns-resize":"ew-resize"}const e5=QF;var r5={type:"selectDataRange",event:"dataRangeSelected",update:"update"},a5=function(r,e){e.eachComponent({mainType:"visualMap",query:r},function(t){t.setSelected(r.selected)})},n5=[{createOnAllSeries:!0,reset:function(r,e){var t=[];return e.eachComponent("visualMap",function(a){var n=r.pipelineContext;!a.isTargetSeries(r)||n&&n.large||t.push(Jz(a.stateList,a.targetVisuals,W(a.getValueState,a),a.getDataDimensionIndex(r.getData())))}),t}},{createOnAllSeries:!0,reset:function(r,e){var t=r.getData(),a=[];e.eachComponent("visualMap",function(n){if(n.isTargetSeries(r)){var i=n.getVisualMeta(W(i5,null,r,n))||{stops:[],outerColors:[]},o=n.getDataDimensionIndex(t);o>=0&&(i.dimension=o,a.push(i))}}),r.getData().setVisual("visualMeta",a)}}];function i5(r,e,t,a){for(var n=e.targetVisuals[a],i=ee.prepareVisualTypes(n),o={color:Ki(r.getData(),"color")},s=0,l=i.length;s<l;s++){var u=i[s],c=n[u==="opacity"?"__alphaForOpacity":u];c&&c.applyVisual(t,v,f)}return o.color;function v(h){return o[h]}function f(h,p){o[h]=p}}var Sm=w;function o5(r){var e=r&&r.visualMap;O(e)||(e=e?[e]:[]),Sm(e,function(t){if(t){Ya(t,"splitList")&&!Ya(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var a=t.pieces;a&&O(a)&&Sm(a,function(n){j(n)&&(Ya(n,"start")&&!Ya(n,"min")&&(n.min=n.start),Ya(n,"end")&&!Ya(n,"max")&&(n.max=n.end))})}})}function Ya(r,e){return r&&r.hasOwnProperty&&r.hasOwnProperty(e)}var xm=!1;function ob(r){xm||(xm=!0,r.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(r5,a5),w(n5,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(o5))}function sb(r){r.registerComponentModel(XF),r.registerComponentView(e5),ob(r)}var s5=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,a){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode();this._pieceList=[],l5[this._mode].call(this,this._pieceList),this._resetSelected(t,a);var i=this.option.categories;this.resetVisual(function(o,s){n==="categories"?(o.mappingMethod="category",o.categories=K(i)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=G(this._pieceList,function(l){return l=K(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,a={},n=ee.listVisualTypes(),i=this.isCategory();w(t.pieces,function(s){w(n,function(l){s.hasOwnProperty(l)&&(a[l]=1)})}),w(a,function(s,l){var u=!1;w(this.stateList,function(c){u=u||o(t,c,l)||o(t.target,c,l)},this),!u&&w(this.stateList,function(c){(t[c]||(t[c]={}))[l]=ab.get(l,c==="inRange"?"active":"inactive",i)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,a){var n=this.option,i=this._pieceList,o=(a?n:t).selected||{};if(n.selected=o,w(i,function(l,u){var c=this.getSelectedMapKey(l);o.hasOwnProperty(c)||(o[c]=!0)},this),n.selectedMode==="single"){var s=!1;w(i,function(l,u){var c=this.getSelectedMapKey(l);o[c]&&(s?o[c]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=K(t)},e.prototype.getValueState=function(t){var a=ee.findPieceIndex(t,this._pieceList);return a!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[a])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var a=[],n=this._pieceList;return this.eachTargetSeries(function(i){var o=[],s=i.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var c=ee.findPieceIndex(l,n);c===t&&o.push(u)},this),a.push({seriesId:i.id,dataIndex:o})},this),a},e.prototype.getRepresentValue=function(t){var a;if(this.isCategory())a=t.value;else if(t.value!=null)a=t.value;else{var n=t.interval||[];a=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return a},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var a=[],n=["",""],i=this;function o(c,v){var f=i.getRepresentValue({interval:c});v||(v=i.getValueState(f));var h=t(f,v);c[0]===-1/0?n[0]=h:c[1]===1/0?n[1]=h:a.push({value:c[0],color:h},{value:c[1],color:h})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return w(s,function(c){var v=c.interval;v&&(v[0]>u&&o([u,v[0]],"outOfRange"),o(v.slice()),u=v[1])},this),{stops:a,outerColors:n}},e.type="visualMap.piecewise",e.defaultOption=$r(Fs.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(Fs),l5={splitNumber:function(r){var e=this.option,t=Math.min(e.precision,20),a=this.getExtent(),n=e.splitNumber;n=Math.max(parseInt(n,10),1),e.splitNumber=n;for(var i=(a[1]-a[0])/n;+i.toFixed(t)!==i&&t<5;)t++;e.precision=t,i=+i.toFixed(t),e.minOpen&&r.push({interval:[-1/0,a[0]],close:[0,0]});for(var o=0,s=a[0];o<n;s+=i,o++){var l=o===n-1?a[1]:s+i;r.push({interval:[s,l],close:[1,1]})}e.maxOpen&&r.push({interval:[a[1],1/0],close:[0,0]}),hh(r),w(r,function(u,c){u.index=c,u.text=this.formatValueText(u.interval)},this)},categories:function(r){var e=this.option;w(e.categories,function(t){r.push({text:this.formatValueText(t,!0),value:t})},this),_m(e,r)},pieces:function(r){var e=this.option;w(e.pieces,function(t,a){j(t)||(t={value:t});var n={text:"",index:a};if(t.label!=null&&(n.text=t.label),t.hasOwnProperty("value")){var i=n.value=t.value;n.interval=[i,i],n.close=[1,1]}else{for(var o=n.interval=[],s=n.close=[0,0],l=[1,0,1],u=[-1/0,1/0],c=[],v=0;v<2;v++){for(var f=[["gte","gt","min"],["lte","lt","max"]][v],h=0;h<3&&o[v]==null;h++)o[v]=t[f[h]],s[v]=l[h],c[v]=h===2;o[v]==null&&(o[v]=u[v])}c[0]&&o[1]===1/0&&(s[0]=0),c[1]&&o[0]===-1/0&&(s[1]=0),o[0]===o[1]&&s[0]&&s[1]&&(n.value=o[0])}n.visual=ee.retrieveVisuals(t),r.push(n)},this),_m(e,r),hh(r),w(r,function(t){var a=t.close,n=[["<","≤"][a[1]],[">","≥"][a[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,n)},this)}};function _m(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}const u5=s5;var c5=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var a=this.visualMapModel,n=a.get("textGap"),i=a.textStyleModel,o=i.getFont(),s=i.getTextColor(),l=this._getItemAlign(),u=a.itemSize,c=this._getViewData(),v=c.endsText,f=Jt(a.get("showLabel",!0),!v);v&&this._renderEndsText(t,v[0],u,f,l),w(c.viewPieceList,function(h){var p=h.piece,d=new tt;d.onclick=W(this._onItemClick,this,p),this._enableHoverLink(d,h.indexInModelPieceList);var g=a.getRepresentValue(p);if(this._createItemSymbol(d,g,[0,0,u[0],u[1]]),f){var y=this.visualMapModel.getValueState(g);d.add(new ut({style:{x:l==="right"?-n:u[0]+n,y:u[1]/2,text:p.text,verticalAlign:"middle",align:l,font:o,fill:s,opacity:y==="outOfRange"?.5:1}}))}t.add(d)},this),v&&this._renderEndsText(t,v[1],u,f,l),da(a.get("orient"),t,a.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,a){var n=this;t.on("mouseover",function(){return i("highlight")}).on("mouseout",function(){return i("downplay")});var i=function(o){var s=n.visualMapModel;s.option.hoverLink&&n.api.dispatchAction({type:o,batch:ns(s.findTargetDataIndices(a),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,a=t.option;if(a.orient==="vertical")return ib(t,this.api,t.itemSize);var n=a.align;return(!n||n==="auto")&&(n="left"),n},e.prototype._renderEndsText=function(t,a,n,i,o){if(a){var s=new tt,l=this.visualMapModel.textStyleModel;s.add(new ut({style:Ct(l,{x:i?o==="right"?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?o:"center",text:a})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,a=G(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),n=t.get("text"),i=t.get("orient"),o=t.get("inverse");return(i==="horizontal"?o:!o)?a.reverse():n&&(n=n.slice().reverse()),{viewPieceList:a,endsText:n}},e.prototype._createItemSymbol=function(t,a,n){t.add(Ht(this.getControllerVisual(a,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(a,"color")))},e.prototype._onItemClick=function(t){var a=this.visualMapModel,n=a.option,i=n.selectedMode;if(i){var o=K(n.selected),s=a.getSelectedMapKey(t);i==="single"||i===!0?(o[s]=!0,w(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},e.type="visualMap.piecewise",e}(nb);const v5=c5;function lb(r){r.registerComponentModel(u5),r.registerComponentView(v5),ob(r)}function f5(r){it(sb),it(lb)}var h5={label:{enabled:!0},decal:{show:!1}},bm=st(),p5={};function d5(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var a=K(h5);ot(a.label,r.getLocaleModel().get("aria"),!1),ot(t.option,a,!1),n(),i();function n(){var u=t.getModel("decal"),c=u.get("show");if(c){var v=Z();r.eachSeries(function(f){if(!f.isColorBySeries()){var h=v.get(f.type);h||(h={},v.set(f.type,h)),bm(f).scope=h}}),r.eachRawSeries(function(f){if(r.isSeriesFiltered(f))return;if(X(f.enableAriaDecal)){f.enableAriaDecal();return}var h=f.getData();if(f.isColorBySeries()){var m=_c(f.ecModel,f.name,p5,r.getSeriesCount()),S=h.getVisual("decal");h.setVisual("decal",x(S,m))}else{var p=f.getRawData(),d={},g=bm(f).scope;h.each(function(b){var _=h.getRawIndex(b);d[_]=b});var y=p.count();p.each(function(b){var _=d[b],A=p.getName(b)||b+"",T=_c(f.ecModel,A,g,y),C=h.getItemVisual(_,"decal");h.setItemVisual(_,"decal",x(C,T))})}function x(b,_){var A=b?B(B({},_),b):_;return A.dirty=!0,A}})}}function i(){var u=r.getLocaleModel().get("aria"),c=t.getModel("label");if(c.option=J(c.option,u),!!c.get("enabled")){var v=e.getZr().dom;if(c.get("description")){v.setAttribute("aria-label",c.get("description"));return}var f=r.getSeriesCount(),h=c.get(["data","maxCount"])||10,p=c.get(["series","maxCount"])||10,d=Math.min(f,p),g;if(!(f<1)){var y=s();if(y){var m=c.get(["general","withTitle"]);g=o(m,{title:y})}else g=c.get(["general","withoutTitle"]);var S=[],x=f>1?c.get(["series","multiple","prefix"]):c.get(["series","single","prefix"]);g+=o(x,{seriesCount:f}),r.eachSeries(function(T,C){if(C<d){var M=void 0,D=T.get("name"),I=D?"withName":"withoutName";M=f>1?c.get(["series","multiple",I]):c.get(["series","single",I]),M=o(M,{seriesId:T.seriesIndex,seriesName:T.get("name"),seriesType:l(T.subType)});var L=T.getData();if(L.count()>h){var P=c.get(["data","partialData"]);M+=o(P,{displayCnt:h})}else M+=c.get(["data","allData"]);for(var E=c.get(["data","separator","middle"]),k=c.get(["data","separator","end"]),V=[],N=0;N<L.count();N++)if(N<h){var z=L.getName(N),H=L.getValues(N),Y=c.get(["data",z?"withName":"withoutName"]);V.push(o(Y,{name:z,value:H.join(E)}))}M+=V.join(E)+k,S.push(M)}});var b=c.getModel(["series","multiple","separator"]),_=b.get("middle"),A=b.get("end");g+=S.join(_)+A,v.setAttribute("aria-label",g)}}}function o(u,c){if(!$(u))return u;var v=u;return w(c,function(f,h){v=v.replace(new RegExp("\\{\\s*"+h+"\\s*\\}","g"),f)}),v}function s(){var u=r.get("title");return u&&u.length&&(u=u[0]),u&&u.text}function l(u){return r.getLocaleModel().get(["series","typeNames"])[u]||"自定义图"}}function g5(r){if(!(!r||!r.aria)){var e=r.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},w(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function y5(r){r.registerPreprocessor(g5),r.registerVisual(r.PRIORITY.VISUAL.ARIA,d5)}var wm={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},m5=function(){function r(e){var t=this._condVal=$(e)?new RegExp(e):qb(e)?e:null;if(t==null){var a="";dt(a)}}return r.prototype.evaluate=function(e){var t=typeof e;return $(t)?this._condVal.test(e):gt(t)?this._condVal.test(e+""):!1},r}(),S5=function(){function r(){}return r.prototype.evaluate=function(){return this.value},r}(),x5=function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},r}(),_5=function(){function r(){}return r.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},r}(),b5=function(){function r(){}return r.prototype.evaluate=function(){return!this.child.evaluate()},r}(),w5=function(){function r(){}return r.prototype.evaluate=function(){for(var e=!!this.valueParser,t=this.getValue,a=t(this.valueGetterParam),n=e?this.valueParser(a):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(e?n:a))return!1;return!0},r}();function rh(r,e){if(r===!0||r===!1){var t=new S5;return t.value=r,t}var a="";return ub(r)||dt(a),r.and?Am("and",r,e):r.or?Am("or",r,e):r.not?A5(r,e):T5(r,e)}function Am(r,e,t){var a=e[r],n="";O(a)||dt(n),a.length||dt(n);var i=r==="and"?new x5:new _5;return i.children=G(a,function(o){return rh(o,t)}),i.children.length||dt(n),i}function A5(r,e){var t=r.not,a="";ub(t)||dt(a);var n=new b5;return n.child=rh(t,e),n.child||dt(a),n}function T5(r,e){for(var t="",a=e.prepareGetValue(r),n=[],i=Wt(r),o=r.parser,s=o?nS(o):null,l=0;l<i.length;l++){var u=i[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var c=U(wm,u)?wm[u]:u,v=r[u],f=s?s(v):v,h=mT(c,f)||c==="reg"&&new m5(f);h||dt(t),n.push(h)}}n.length||dt(t);var p=new w5;return p.valueGetterParam=a,p.valueParser=s,p.getValue=e.getValue,p.subCondList=n,p}function ub(r){return j(r)&&!pn(r)}var C5=function(){function r(e,t){this._cond=rh(e,t)}return r.prototype.evaluate=function(){return this._cond.evaluate()},r}();function D5(r,e){return new C5(r,e)}var M5={type:"echarts:filter",transform:function(r){for(var e=r.upstream,t,a=D5(r.config,{valueGetterAttrMap:Z({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;U(s,"dimension")||dt(l);var c=e.getDimensionInfo(u);return c||dt(l),{dimIdx:c.index}},getValue:function(s){return e.retrieveValueFromItem(t,s.dimIdx)}}),n=[],i=0,o=e.count();i<o;i++)t=e.getRawDataItem(i),a.evaluate()&&n.push(t);return{data:n}}},I5={type:"echarts:sort",transform:function(r){var e=r.upstream,t=r.config,a="",n=_t(t);n.length||dt(a);var i=[];w(n,function(c){var v=c.dimension,f=c.order,h=c.parser,p=c.incomparable;if(v==null&&dt(a),f!=="asc"&&f!=="desc"&&dt(a),p&&p!=="min"&&p!=="max"){var d="";dt(d)}if(f!=="asc"&&f!=="desc"){var g="";dt(g)}var y=e.getDimensionInfo(v);y||dt(a);var m=h?nS(h):null;h&&!m&&dt(a),i.push({dimIdx:y.index,parser:m,comparator:new oS(f,p)})});var o=e.sourceFormat;o!==se&&o!==Oe&&dt(a);for(var s=[],l=0,u=e.count();l<u;l++)s.push(e.getRawDataItem(l));return s.sort(function(c,v){for(var f=0;f<i.length;f++){var h=i[f],p=e.retrieveValueFromItem(c,h.dimIdx),d=e.retrieveValueFromItem(v,h.dimIdx);h.parser&&(p=h.parser(p),d=h.parser(d));var g=h.comparator.evaluate(p,d);if(g!==0)return g}return 0}),{data:s}}};function L5(r){r.registerTransform(M5),r.registerTransform(I5)}var P5=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.prototype.init=function(t,a,n){r.prototype.init.call(this,t,a,n),this._sourceManager=new cS(this),ip(this)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),ip(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:Qe},e}(lt),E5=function(r){R(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e}(Ot);function R5(r){r.registerComponentModel(P5),r.registerComponentView(E5)}function Tm(r){return O(r[0])}function Cm(r,e){for(var t=[],a=r.length,n=0;n<a;n++)t.push({one:r[n],many:[]});for(var n=0;n<e.length;n++){var i=e[n].length,o=void 0;for(o=0;o<i;o++)t[o%a].many.push(e[n][o])}for(var s=0,n=a-1;n>=0;n--)if(!t[n].many.length){var l=t[s].many;if(l.length<=1)if(s)s=0;else return t;var i=l.length,u=Math.ceil(i/2);t[n].many=l.slice(u,i),t[s].many=l.slice(0,u),s++}return t}var k5={clone:function(r){for(var e=[],t=1-Math.pow(1-r.path.style.opacity,1/r.count),a=0;a<r.count;a++){var n=ew(r.path);n.setStyle("opacity",t),e.push(n)}return e},split:null};function rc(r,e,t,a,n,i){if(!r.length||!e.length)return;var o=xn("update",a,n);if(!(o&&o.duration>0))return;var s=a.getModel("universalTransition").get("delay"),l=Object.assign({setToFinal:!0},o),u,c;Tm(r)&&(u=r,c=e),Tm(e)&&(u=e,c=r);function v(y,m,S,x,b){var _=y.many,A=y.one;if(_.length===1&&!b){var T=m?_[0]:A,C=m?A:_[0];if(jb(T))v({many:[T],one:C},!0,S,x,!0);else{var M=s?J({delay:s(S,x)},l):l;Jb(T,C,M),i(T,C,T,C,M)}}else for(var D=J({dividePath:k5[t],individualDelay:s&&function(V,N,z,H){return s(V+S,x)}},l),I=m?Qb(_,A,D):tw(A,_,D),L=I.fromIndividuals,P=I.toIndividuals,E=L.length,k=0;k<E;k++){var M=s?J({delay:s(k,E)},l):l;i(L[k],P[k],m?_[k]:y.one,m?y.one:_[k],M)}}for(var f=u?u===r:r.length>e.length,h=u?Cm(c,u):Cm(f?e:r,[f?r:e]),p=0,d=0;d<h.length;d++)p+=h[d].many.length;for(var g=0,d=0;d<h.length;d++)v(h[d],f,g,p),g+=h[d].many.length}function ra(r){if(!r)return[];if(O(r)){for(var e=[],t=0;t<r.length;t++)e.push(ra(r[t]));return e}var a=[];return r.traverse(function(n){n instanceof It&&!n.disableMorphing&&!n.invisible&&!n.ignore&&a.push(n)}),a}var cb=1e4,N5=st();function O5(r){for(var e=r.dimensions,t=0;t<e.length;t++){var a=r.getDimensionInfo(e[t]);if(a&&a.otherDims.itemGroupId===0)return e[t]}}function Dm(r){var e=[];return w(r,function(t){var a=t.data;if(!(a.count()>cb))for(var n=a.getIndices(),i=O5(a),o=0;o<n.length;o++)e.push({dataGroupId:t.dataGroupId,data:a,dim:t.dim||i,divide:t.divide,dataIndex:o})}),e}function ac(r,e,t){r.traverse(function(a){a instanceof It&&Lt(a,{style:{opacity:0}},e,{dataIndex:t,isFrom:!0})})}function nc(r){if(r.parent){var e=r.getComputedTransform();r.setLocalTransform(e),r.parent.remove(r)}}function Za(r){r.stopAnimation(),r.isGroup&&r.traverse(function(e){e.stopAnimation()})}function V5(r,e,t){var a=xn("update",t,e);a&&r.traverse(function(n){if(n instanceof Sa){var i=jw(n);i&&n.animateFrom({style:i},a)}})}function B5(r,e){var t=r.length;if(t!==e.length)return!1;for(var a=0;a<t;a++){var n=r[a],i=e[a];if(n.data.getId(n.dataIndex)!==i.data.getId(i.dataIndex))return!1}return!0}function vb(r,e,t){var a=Dm(r),n=Dm(e);function i(y,m,S,x,b){(S||y)&&m.animateFrom({style:S&&S!==y?B(B({},S.style),y.style):y.style},b)}function o(y){for(var m=0;m<y.length;m++)if(y[m].dim)return y[m].dim}var s=o(a),l=o(n),u=!1;function c(y,m){return function(S){var x=S.data,b=S.dataIndex;if(m)return x.getId(b);var _=S.dataGroupId,A=y?s||l:l||s,T=A&&x.getDimensionInfo(A),C=T&&T.ordinalMeta;if(T){var M=x.get(T.name,b);return C&&C.categories[M]||M+""}var D=x.getRawDataItem(b);return D&&D.groupId?D.groupId+"":_||x.getId(b)}}var v=B5(a,n),f={};if(!v)for(var h=0;h<n.length;h++){var p=n[h],d=p.data.getItemGraphicEl(p.dataIndex);d&&(f[d.id]=!0)}function g(y,m){var S=a[m],x=n[y],b=x.data.hostModel,_=S.data.getItemGraphicEl(S.dataIndex),A=x.data.getItemGraphicEl(x.dataIndex);if(_===A){A&&V5(A,x.dataIndex,b);return}_&&f[_.id]||A&&(Za(A),_?(Za(_),nc(_),u=!0,rc(ra(_),ra(A),x.divide,b,y,i)):ac(A,b,y))}new hr(a,n,c(!0,v),c(!1,v),null,"multiple").update(g).updateManyToOne(function(y,m){var S=n[y],x=S.data,b=x.hostModel,_=x.getItemGraphicEl(S.dataIndex),A=bt(G(m,function(T){return a[T].data.getItemGraphicEl(a[T].dataIndex)}),function(T){return T&&T!==_&&!f[T.id]});_&&(Za(_),A.length?(w(A,function(T){Za(T),nc(T)}),u=!0,rc(ra(A),ra(_),S.divide,b,y,i)):ac(_,b,S.dataIndex))}).updateOneToMany(function(y,m){var S=a[m],x=S.data.getItemGraphicEl(S.dataIndex);if(!(x&&f[x.id])){var b=bt(G(y,function(A){return n[A].data.getItemGraphicEl(n[A].dataIndex)}),function(A){return A&&A!==x}),_=n[y[0]].data.hostModel;b.length&&(w(b,function(A){return Za(A)}),x?(Za(x),nc(x),u=!0,rc(ra(x),ra(b),S.divide,_,y[0],i)):w(b,function(A){return ac(A,_,y[0])}))}}).updateManyToMany(function(y,m){new hr(m,y,function(S){return a[S].data.getId(a[S].dataIndex)},function(S){return n[S].data.getId(n[S].dataIndex)}).update(function(S,x){g(y[S],m[x])}).execute()}).execute(),u&&w(e,function(y){var m=y.data,S=m.hostModel,x=S&&t.getViewOfSeriesModel(S),b=xn("update",S,0);x&&S.isAnimationEnabled()&&b&&b.duration>0&&x.group.traverse(function(_){_ instanceof It&&!_.animators.length&&_.animateFrom({style:{opacity:0}},b)})})}function Mm(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function Im(r){return O(r)?r.sort().join(","):r}function Dr(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function z5(r,e){var t=Z(),a=Z(),n=Z();return w(r.oldSeries,function(i,o){var s=r.oldDataGroupIds[o],l=r.oldData[o],u=Mm(i),c=Im(u);a.set(c,{dataGroupId:s,data:l}),O(u)&&w(u,function(v){n.set(v,{key:c,dataGroupId:s,data:l})})}),w(e.updatedSeries,function(i){if(i.isUniversalTransitionEnabled()&&i.isAnimationEnabled()){var o=i.get("dataGroupId"),s=i.getData(),l=Mm(i),u=Im(l),c=a.get(u);if(c)t.set(u,{oldSeries:[{dataGroupId:c.dataGroupId,divide:Dr(c.data),data:c.data}],newSeries:[{dataGroupId:o,divide:Dr(s),data:s}]});else if(O(l)){var v=[];w(l,function(p){var d=a.get(p);d.data&&v.push({dataGroupId:d.dataGroupId,divide:Dr(d.data),data:d.data})}),v.length&&t.set(u,{oldSeries:v,newSeries:[{dataGroupId:o,data:s,divide:Dr(s)}]})}else{var f=n.get(l);if(f){var h=t.get(f.key);h||(h={oldSeries:[{dataGroupId:f.dataGroupId,data:f.data,divide:Dr(f.data)}],newSeries:[]},t.set(f.key,h)),h.newSeries.push({dataGroupId:o,data:s,divide:Dr(s)})}}}}),t}function Lm(r,e){for(var t=0;t<r.length;t++){var a=e.seriesIndex!=null&&e.seriesIndex===r[t].seriesIndex||e.seriesId!=null&&e.seriesId===r[t].id;if(a)return t}}function G5(r,e,t,a){var n=[],i=[];w(_t(r.from),function(o){var s=Lm(e.oldSeries,o);s>=0&&n.push({dataGroupId:e.oldDataGroupIds[s],data:e.oldData[s],divide:Dr(e.oldData[s]),dim:o.dimension})}),w(_t(r.to),function(o){var s=Lm(t.updatedSeries,o);if(s>=0){var l=t.updatedSeries[s].getData();i.push({dataGroupId:e.oldDataGroupIds[s],data:l,divide:Dr(l),dim:o.dimension})}}),n.length>0&&i.length>0&&vb(n,i,a)}function F5(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){w(_t(a.seriesTransition),function(n){w(_t(n.to),function(i){for(var o=a.updatedSeries,s=0;s<o.length;s++)(i.seriesIndex!=null&&i.seriesIndex===o[s].seriesIndex||i.seriesId!=null&&i.seriesId===o[s].id)&&(o[s][Jo]=!0)})})}),r.registerUpdateLifecycle("series:transition",function(e,t,a){var n=N5(t);if(n.oldSeries&&a.updatedSeries&&a.optionChanged){var i=a.seriesTransition;if(i)w(_t(i),function(h){G5(h,n,a,t)});else{var o=z5(n,a);w(o.keys(),function(h){var p=o.get(h);vb(p.oldSeries,p.newSeries,t)})}w(a.updatedSeries,function(h){h[Jo]&&(h[Jo]=!1)})}for(var s=e.getSeries(),l=n.oldSeries=[],u=n.oldDataGroupIds=[],c=n.oldData=[],v=0;v<s.length;v++){var f=s[v].getData();f.count()<cb&&(l.push(s[v]),u.push(s[v].get("dataGroupId")),c.push(f))}})}it([LM]);it([IM]);it([tI,mI,PI,mL,NL,xP,jP,V2,vE,xE,PE,NR,lk,_k,Fk,Xk,fN,bN,NN,WN,rO,FO]);it(cV);it($V);it(c_);it(sB);it(q_);it(pB);it(wB);it(Az);it(Zz);it(oo);it(hG);it(gG);it(PG);it(FG);it(KG);it(aF);it(yF);it(zF);it(eb);it(rb);it(f5);it(sb);it(lb);it(y5);it(L5);it(R5);it(F5);it(MM);export{W5 as i};
//# sourceMappingURL=echart-372a619d.js.map
