Files
zyt/server/public/admin/assets/echarts-CNLwa9wG.js
T
2026-05-11 17:49:38 +08:00

31 lines
804 KiB
JavaScript
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import{_ as E}from"./tslib-BDyQ-Jie.js";import{i as eb,e as z,a as K,b as w,c as Se,d as ct,f as Y,r as on,m as G,g as $,h as J,j as St,k as ic,l as B,n as Nt,o as yn,p as Ut,P as Mt,q as af,s as pt,Z as Ne,t as rb,u as ab,v as nb,w as Q,x as Z,T as Ja,y as Wi,z as Re,A as gv,B as ls,C as ib,D as ob,E as sb,F as Ca,G as Pm,S as Ee,R as Hs,H as ke,I as xe,J as dt,L as ee,K as Ws,M as yv,N as wt,O as Rm,Q as et,U as lb,V as Us,W as us,X as Ft,Y as ub,_ as vt,$ as Ui,a0 as nt,a1 as j,a2 as Jt,a3 as _e,a4 as U,a5 as cb,a6 as tt,a7 as Em,a8 as ye,a9 as cs,aa as _i,ab as oc,ac as km,ad as nf,ae as of,af as vb,ag as sn,ah as Nm,ai as sa,aj as _l,ak as hb,al as fb,am as lr,an as mn,ao as _t,ap as pe,aq as pb,ar as db,as as vs,at as gb,au as Sn,av as sf,aw as xl,ax as yb,ay as mb,az as hs,aA as Ys,aB as Qt,aC as Yi,aD as Sb,aE as lf,aF as Br,aG as na,aH as Om,aI as Vm,aJ as _b,aK as xb,aL as bb,aM as ma,aN as wb,aO as _n,aP as ce,aQ as mv,aR as Bm,aS as Sa,aT as Ab,aU as Xo,aV as bl,aW as zm,aX as fs,aY as ui,aZ as kr,a_ as Zi,a$ as Tb,b0 as Db,b1 as Qa,b2 as uf,b3 as Cb,b4 as sc,b5 as Mb,b6 as Gm,b7 as Ib,b8 as Lb,b9 as Pb,ba as cf,bb as Rb,bc as Eb,bd as xi,be as kb,bf as lc,bg as vf,bh as Nb,bi as Ob,bj as Vb,bk as Bb,bl as zb,bm as Gb,bn as Fb,bo as Hb,bp as Wb,bq as Ub}from"./zrender-DRNXw7y3.js";var Yb=".",Zr="___EC__COMPONENT__CONTAINER___",Fm="___EC__EXTENDED_CLASS___";function qe(r){var e={main:"",sub:""};if(r){var t=r.split(Yb);e.main=t[0]||"",e.sub=t[1]||""}return e}function Zb(r){Se(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function $b(r){return!!(r&&r[Fm])}function Sv(r,e){r.$constructor=r,r.extend=function(t){var a=this,n;return Xb(a)?n=(function(i){E(o,i);function o(){return i.apply(this,arguments)||this}return o})(a):(n=function(){(t.$constructor||a).apply(this,arguments)},eb(n,this)),z(n.prototype,t),n[Fm]=!0,n.extend=this.extend,n.superCall=jb,n.superApply=Jb,n.superClass=a,n}}function Xb(r){return K(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function Hm(r,e){r.extend=e.extend}var Kb=Math.round(Math.random()*10);function qb(r){var e=["__\0is_clz",Kb++].join("_");r.prototype[e]=!0,r.isInstance=function(t){return!!(t&&t[e])}}function jb(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 Jb(r,e,t){return this.superClass.prototype[e].apply(r,t)}function Zs(r){var e={};r.registerClass=function(a){var n=a.type||a.prototype.type;if(n){Zb(n),a.prototype.type=n;var i=qe(n);if(!i.sub)e[i.main]=a;else if(i.sub!==Zr){var o=t(i);o[i.sub]=a}}return a},r.getClass=function(a,n,i){var o=e[a];if(o&&o[Zr]&&(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[Zr]?w(o,function(s,l){l!==Zr&&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[Zr]};function t(a){var n=e[a.main];return(!n||!n[Zr])&&(n=e[a.main]={},n[Zr]=!0),n}}function _a(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 Qb=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],tw=_a(Qb),ew=(function(){function r(){}return r.prototype.getAreaStyle=function(e,t){return tw(this,e,t)},r})(),hf=1e-4,Wm=20;function rw(r){return r.replace(/^\s+|\s+$/g,"")}function yt(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 H(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 Y(r)?rw(r).match(/%$/)?parseFloat(r)/100*e:parseFloat(r):r==null?NaN:+r}function Ot(r,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),Wm),r=(+r).toFixed(e),t?r:+r}function Le(r){return r.sort(function(e,t){return e-t}),r}function je(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 Um(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=on(r,function(f,p){return f+(isNaN(p)?0:p)},0);if(t===0)return[];for(var a=Math.pow(10,e),n=G(r,function(f){return(isNaN(f)?0:f)/t*a*100}),i=a*100,o=G(n,function(f){return Math.floor(f)}),s=on(o,function(f,p){return f+p},0),l=G(n,function(f,p){return f-o[p]});s<i;){for(var u=Number.NEGATIVE_INFINITY,c=null,v=0,h=l.length;v<h;++v)l[v]>u&&(u=l[v],c=v);++o[c],l[c]=0,++s}return G(o,function(f){return f/a})}function iw(r,e){var t=Math.max(je(r),je(e)),a=r+e;return t>Wm?a:Ot(a,t)}var ff=9007199254740991;function Ym(r){var e=Math.PI*2;return(r%e+e)%e}function bi(r){return r>-hf&&r<hf}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 er(r){if(r instanceof Date)return r;if(Y(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,_v(r))}function _v(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 Zm(r,e){var t=_v(r),a=Math.pow(10,t),n=r/a,i;return n<1.5?i=1:n<2.5?i=2:n<4?i=3:n<7?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 pf(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 hr(r){var e=parseFloat(r);return e==r&&(e!==0||!Y(r)||r.indexOf("x")<=0)?e:NaN}function $m(r){return!isNaN(hr(r))}function Xm(){return Math.round(Math.random()*9)}function Km(r,e){return e===0?r:Km(e,r%e)}function df(r,e){return r==null?e:e==null?r:r*e/Km(r,e)}function gt(r){throw new Error(r)}function gf(r,e,t){return(e-r)*t+r}var qm="series\0",jm="\0_ec_\0";function xt(r){return r instanceof Array?r:r==null?[]:[r]}function xa(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 yf=["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 xn(r){return J(r)&&!B(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=$();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?hw(s,e,n):i&&fw(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"||wi(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=ci(n.id),s=t.get(o);if(s!=null){var l=r[s];Se(!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)&&!wi(t)&&!wi(i)&&Qm("name",i,t)){r[n].newOption=t,e[a]=null;return}}})}function hw(r,e,t){w(e,function(a){if(a){for(var n,i=0;(n=r[i])&&(n.newOption||wi(n.existing)||n.existing&&a.id!=null&&!Qm("id",a,n.existing));)i++;n?(n.newOption=a,n.brandNew=t):r.push({newOption:a,brandNew:t,existing:null,keyInfo:null}),i++}})}function fw(r,e){w(e,function(t){r.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function pw(r){var e=$();w(r,function(t){var a=t.existing;a&&e.set(a.id,t)}),w(r,function(t){var a=t.newOption;Se(!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?ci(i.name):n?n.name:qm+a,n)o.id=ci(n.id);else if(i.id!=null)o.id=ci(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 Qm(r,e,t){var a=Yt(e[r],null),n=Yt(t[r],null);return a!=null&&n!=null&&a===n}function ci(r){return Yt(r,"")}function Yt(r,e){return r==null?e:Y(r)?r:St(r)||ic(r)?r+"":e}function xv(r){var e=r.name;return!!(e&&e.indexOf(qm))}function wi(r){return r&&r.id!=null&&ci(r.id).indexOf(jm)===0}function dw(r){return jm+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=Yt(o[u].seriesId,null);if(v==null)return;for(var h=xt(o[u].dataIndex),f=l&&l[v],p=0,d=h.length;p<d;p++){var g=h[p];f&&f[g]?f[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 B(e.dataIndex)?G(e.dataIndex,function(t){return r.indexOfRawIndex(t)}):r.indexOfRawIndex(e.dataIndex);if(e.name!=null)return B(e.name)?G(e.name,function(t){return r.indexOfName(t)}):r.indexOfName(e.name)}function ut(){var r="__ec_inner_"+Sw++;return function(e){return e[r]||(e[r]={})}}var Sw=Xm();function vi(r,e,t){var a=bv(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=$i(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 bv(r,e){var t;if(Y(r)){var a={};a[r+"Index"]=0,t=a}else t=r;var n=$(),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 h=n.get(c)||n.set(c,{});h[v]=s}}),{mainTypeSpecified:o,queryOptionMap:n,others:i}}var Ht={useDefault:!0,enableAll:!1,enableNone:!1},_w={useDefault:!1,enableAll:!0,enableNone:!0};function $i(r,e,t,a){a=a||Ht;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?(Se(a.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[],s):(n==="all"&&(Se(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 t0(r,e,t){r.setAttribute?r.setAttribute(e,t):r[e]=t}function xw(r,e){return r.getAttribute?r.getAttribute(e):r[e]}function bw(r){return r==="auto"?Nt.domSupported?"html":"richText":r||"html"}function uc(r,e){var t=$(),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 e0(r,e,t,a,n){var i=e==null||e==="auto";if(a==null)return a;if(St(a)){var o=gf(t||0,a,n);return Ot(o,i?Math.max(je(t||0),je(a)):e)}else{if(Y(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 h=r.getDimensionInfo(v);if(h&&h.type==="ordinal")s[v]=(n<1&&l?l:u)[v];else{var f=l&&l[v]?l[v]:0,p=u[v],o=gf(f,p,n);s[v]=Ot(o,i?Math.max(je(f),je(p)):e)}}return s}}var q=ut(),cc=function(r,e,t,a){if(a){var n=q(a);n.dataIndex=t,n.dataType=e,n.seriesIndex=r,n.ssrType="chart",a.type==="group"&&a.traverse(function(i){var o=q(i);o.seriesIndex=r,o.dataIndex=t,o.dataType=e,o.ssrType="chart"})}},mf=1,Sf={},r0=ut(),wv=ut(),Av=0,Xi=1,$s=2,de=["emphasis","blur","select"],Ai=["normal","emphasis","blur","select"],bn=10,ww=9,ha="highlight",Ko="downplay",hi="select",qo="unselect",fi="toggleSelect";function Na(r){return r!=null&&r!=="none"}function Xs(r,e,t){r.onHoverStateChange&&(r.hoverState||0)!==t&&r.onHoverStateChange(e),r.hoverState=t}function a0(r){Xs(r,"emphasis",$s)}function n0(r){r.hoverState===$s&&Xs(r,"normal",Av)}function Tv(r){Xs(r,"blur",Xi)}function i0(r){r.hoverState===Xi&&Xs(r,"normal",Av)}function Aw(r){r.selected=!0}function Tw(r){r.selected=!1}function _f(r,e,t){e(r,t)}function Sr(r,e,t){_f(r,e,t),r.isGroup&&r.traverse(function(a){_f(a,e,t)})}function ps(r,e){switch(e){case"emphasis":r.hoverState=$s;break;case"normal":r.hoverState=Av;break;case"blur":r.hoverState=Xi;break;case"select":r.selected=!0}}function Dw(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 Cw(r,e,t,a){var n=t&&ct(t,"select")>=0,i=!1;if(r instanceof Mt){var o=r0(r),s=n&&o.selectFill||o.normalFill,l=n&&o.selectStroke||o.normalStroke;if(Na(s)||Na(l)){a=a||{};var u=a.style||{};u.fill==="inherit"?(i=!0,a=z({},a),u=z({},u),u.fill=s):!Na(u.fill)&&Na(s)?(i=!0,a=z({},a),u=z({},u),u.fill=af(s)):!Na(u.stroke)&&Na(l)&&(i||(a=z({},a),u=z({},u)),u.stroke=af(l)),a.style=u}}if(a&&a.z2==null){i||(a=z({},a));var c=r.z2EmphasisLift;a.z2=r.z2+(c??bn)}return a}function Mw(r,e,t){if(t&&t.z2==null){t=z({},t);var a=r.z2SelectLift;t.z2=r.z2+(a??ww)}return t}function Iw(r,e,t){var a=ct(r.currentStates,e)>=0,n=r.style.opacity,i=a?null:Dw(r,["opacity"],e,{opacity:1});t=t||{};var o=t.style||{};return o.opacity==null&&(t=z({},t),o=z({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 Cw(this,r,e,t);if(r==="blur")return Iw(this,r,t);if(r==="select")return Mw(this,r,t)}return t}function wa(r){r.stateProxy=Al;var e=r.getTextContent(),t=r.getTextGuideLine();e&&(e.stateProxy=Al),t&&(t.stateProxy=Al)}function xf(r,e){!u0(r,e)&&!r.__highByOuter&&Sr(r,a0)}function bf(r,e){!u0(r,e)&&!r.__highByOuter&&Sr(r,n0)}function fr(r,e){r.__highByOuter|=1<<(e||0),Sr(r,a0)}function pr(r,e){!(r.__highByOuter&=~(1<<(e||0)))&&Sr(r,n0)}function o0(r){Sr(r,Tv)}function Dv(r){Sr(r,i0)}function s0(r){Sr(r,Aw)}function l0(r){Sr(r,Tw)}function u0(r,e){return r.__highDownSilentOnTouch&&e.zrByTouch}function c0(r){var e=r.getModel(),t=[],a=[];e.eachComponent(function(n,i){var o=wv(i),s=n==="series",l=s?r.getViewOfSeriesModel(i):r.getViewOfComponentModel(i);!s&&a.push(l),o.isBlured&&(l.group.traverse(function(u){i0(u)}),s&&t.push(i)),o.isBlured=!1}),w(a,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(t,!1,e)})}function vc(r,e,t,a){var n=a.getModel();t=t||"coordinateSystem";function i(u,c){for(var v=0;v<c.length;v++){var h=u.getItemGraphicEl(c[v]);h&&Dv(h)}}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 h=v&&s?v===s:c;if(!(t==="series"&&!c||t==="coordinateSystem"&&!h||e==="series"&&c)){var f=a.getViewOfSeriesModel(u);if(f.group.traverse(function(g){g.__highByOuter&&c&&e==="self"||Tv(g)}),yn(e))i(u.getData(),e);else if(J(e))for(var p=Ut(e),d=0;d<p.length;d++)i(u.getData(p[d]),e[p[d]]);l.push(u),wv(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){wv(a).isBlured=!0;var n=t.getViewOfComponentModel(a);!n||!n.focusBlurEnabled||n.group.traverse(function(i){Tv(i)})}}}function Lw(r,e,t){var a=r.seriesIndex,n=r.getData(e.dataType);if(n){var i=ba(n,e);i=(B(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);vc(a,u.focus,u.blurScope,t)}else{var c=r.get(["emphasis","focus"]),v=r.get(["emphasis","blurScope"]);c!=null&&vc(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 Pw(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 xf(s,e)})):(vc(a.seriesIndex,a.focus,a.blurScope,t),a.focus==="self"&&hc(a.componentMainType,a.componentIndex,t),xf(r,e))}function Rw(r,e,t){c0(t);var a=q(r),n=Cv(a.componentMainType,a.componentIndex,a.componentHighDownName,t).dispatchers;n?w(n,function(i){return bf(i,e)}):bf(r,e)}function Ew(r,e,t){if(pc(e)){var a=e.dataType,n=r.getData(a),i=ba(n,e);B(i)||(i=[i]),r[e.type===fi?"toggleSelect":e.type===hi?"select":"unselect"](i,a)}}function wf(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)?s0(i):l0(i)})})}function kw(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 fa(r,e,t){la(r,!0),Sr(r,wa),fc(r,e,t)}function Nw(r){la(r,!1)}function kt(r,e,t,a){a?Nw(r):fa(r,e,t)}function fc(r,e,t){var a=q(r);e!=null?(a.focus=e,a.blurScope=t):a.focus&&(a.focus=null)}var Af=["emphasis","blur","select"],Ow={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function re(r,e,t,a){t=t||"itemStyle";for(var n=0;n<Af.length;n++){var i=Af[n],o=e.getModel([i,t]),s=r.ensureState(i);s.style=a?a(o):o[Ow[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 Ti(r){return!!(r&&r.__highDownDispatcher)}function Vw(r,e,t){var a=q(r);a.componentMainType=e.mainType,a.componentIndex=e.componentIndex,a.componentHighDownName=t}function Bw(r){var e=Sf[r];return e==null&&mf<=32&&(e=Sf[r]=mf++),e}function pc(r){var e=r.type;return e===hi||e===qo||e===fi}function Tf(r){var e=r.type;return e===ha||e===Ko}function zw(r){var e=r0(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 v0=ut();function wn(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=pt(a.duration,200),c=pt(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)),K(v)&&(v=v(t,n)),K(u)&&(u=u(t));var h={duration:u||0,delay:v,easing:c};return h}else return null}function Mv(r,e,t,a,n,i,o){var s=!1,l;K(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=wn(r,a,n,u?l||{}:null,a&&a.getAnimationDelayParams?a.getAnimationDelayParams(e,n):null);if(c&&c.duration>0){var v=c.duration,h=c.delay,f=c.easing,p={duration:v,delay:h||0,easing:f,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){Mv("update",r,e,t,a,n,i)}function Pt(r,e,t,a,n,i){Mv("enter",r,e,t,a,n,i)}function tn(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 zr(r,e,t,a,n,i){tn(r)||Mv("leave",r,e,t,a,n,i)}function Df(r,e,t,a){r.removeTextContent(),r.removeTextGuideLine(),zr(r,{style:{opacity:0}},e,t,a)}function Di(r,e,t){function a(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(n){n.isGroup||Df(n,e,t,a)}):Df(r,e,t,a)}function Ue(r){v0(r).oldStyle=r.style}function Gw(r){return v0(r).oldStyle}var ds=Math.max,gs=Math.min,dc={};function Fw(r){return Mt.extend(r)}var Hw=sb;function Ww(r,e){return Hw(r,e)}function Ye(r,e){dc[r]=e}function Iv(r){if(dc.hasOwnProperty(r))return dc[r]}function Ks(r,e,t,a){var n=rb(r,e);return t&&(a==="center"&&(t=f0(t,n.getBoundingRect())),p0(n,t)),n}function h0(r,e,t){var a=new Ne({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(f0(e,i))}}});return a}function f0(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 Me=ab;function p0(r,e){if(r.applyTransform){var t=r.getBoundingRect(),a=t.calculateTransform(e);r.applyTransform(a)}}function ln(r,e){return ib(r,r,{lineWidth:e}),r}function Uw(r){return ob(r.shape,r.shape,r.style),r}var jo=nb;function pa(r,e){for(var t=gv([]);r&&r!==e;)ls(t,r.getLocalTransform(),t),r=r.parent;return t}function We(r,e,t){return e&&!yn(e)&&(e=Ja.getLocalTransform(e)),t&&(e=Wi([],e)),Re([],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=We(i,e,t),Math.abs(i[0])>Math.abs(i[1])?i[0]>0?"right":"left":i[1]>0?"bottom":"top"}function Cf(r){return!r.isGroup}function Yw(r){return r.shape!=null}function Ki(r,e,t){if(!r||!e)return;function a(o){var s={};return o.traverse(function(l){Cf(l)&&l.anid&&(s[l.anid]=l)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return Yw(o)&&(s.shape=z({},o.shape)),s}var i=a(r);e.traverse(function(o){if(Cf(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 d0(r,e){return G(r,function(t){var a=t[0];a=ds(a,e.x),a=gs(a,e.x+e.width);var n=t[1];return n=ds(n,e.y),n=gs(n,e.y+e.height),[a,n]})}function Zw(r,e){var t=ds(r.x,e.x),a=gs(r.x+r.width,e.x+e.width),n=ds(r.y,e.y),i=gs(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 qi(r,e,t){var a=z({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),Q(n,t),new Ne(a)):Ks(r.replace("path://",""),a,t,"center")}function ri(r,e,t,a,n){for(var i=0,o=n[n.length-1];i<n.length;i++){var s=n[i];if(g0(r,e,t,a,s[0],s[1],o[0],o[1]))return!0;o=s}}function g0(r,e,t,a,n,i,o,s){var l=t-r,u=a-e,c=o-n,v=s-i,h=Tl(c,v,l,u);if($w(h))return!1;var f=r-n,p=e-i,d=Tl(f,p,l,u)/h;if(d<0||d>1)return!1;var g=Tl(f,p,c,v)/h;return!(g<0||g>1)}function Tl(r,e,t,a){return r*a-t*e}function $w(r){return r<=1e-6&&r>=-1e-6}function Ma(r){var e=r.itemTooltipOption,t=r.componentModel,a=r.itemName,n=Y(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(Ut(l),function(c){Z(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:Q({content:a,encodeHTMLContent:!0,formatterParams:s},n)}}function Mf(r,e){var t;r.isGroup&&(t=e(r)),t||r.traverse(e)}function Ur(r,e){if(r)if(B(r))for(var t=0;t<r.length;t++)Mf(r[t],e);else Mf(r,e)}Ye("circle",Ca);Ye("ellipse",Pm);Ye("sector",Ee);Ye("ring",Hs);Ye("polygon",ke);Ye("polyline",xe);Ye("rect",dt);Ye("line",ee);Ye("bezierCurve",Ws);Ye("arc",yv);const Ia=Object.freeze(Object.defineProperty({__proto__:null,Arc:yv,BezierCurve:Ws,BoundingRect:wt,Circle:Ca,CompoundPath:Rm,Ellipse:Pm,Group:et,Image:Ne,IncrementalDisplayable:lb,Line:ee,LinearGradient:Us,OrientedBoundingRect:us,Path:Mt,Point:Ft,Polygon:ke,Polyline:xe,RadialGradient:ub,Rect:dt,Ring:Hs,Sector:Ee,Text:vt,applyTransform:We,clipPointsByRect:d0,clipRectByRect:Zw,createIcon:qi,extendPath:Ww,extendShape:Fw,getShapeClass:Iv,getTransform:pa,groupTransition:Ki,initProps:Pt,isElementRemoved:tn,lineLineIntersect:g0,linePolygonIntersect:ri,makeImage:h0,makePath:Ks,mergePath:Me,registerShape:Ye,removeElement:zr,removeElementWithFadeOut:Di,resizePath:p0,setTooltipConfig:Ma,subPixelOptimize:jo,subPixelOptimizeLine:ln,subPixelOptimizeRect:Uw,transformDirection:qs,traverseElements:Ur,updateProps:ft},Symbol.toStringTag,{value:"Module"}));var js={};function y0(r,e){for(var t=0;t<de.length;t++){var a=de[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 gc(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=K(r.defaultText)?r.defaultText(n,r,t):r.defaultText);for(var l={normal:s},u=0;u<de.length;u++){var c=de[u],v=e[c];l[c]=pt(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 vt,i=!1,o=0;o<Ai.length;o++){var s=e[Ai[o]];if(s&&s.getShallow("show")){i=!0;break}}var l=n?r:r.getTextContent();if(i){n||(l||(l=new vt,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=gc(t,e),c=e.normal,v=!!c.getShallow("show"),h=Dt(c,a&&a.normal,t,!1,!n);h.text=u.normal,n||r.setTextConfig(ys(c,t,!1));for(var o=0;o<de.length;o++){var f=de[o],s=e[f];if(s){var p=l.ensureState(f),d=!!pt(s.getShallow("show"),v);if(d!==v&&(p.ignore=!d),p.style=Dt(s,a&&a[f],t,!0,!n),p.style.text=u[f],!n){var g=r.ensureState(f);g.textConfig=ys(s,t,!0)}}}l.silent=!!c.getShallow("silent"),l.style.x!=null&&(h.x=l.style.x),l.style.y!=null&&(h.y=l.style.y),l.ignore=!v,l.useStyle(h),l.dirty(),t.enableTextSetter&&(An(l).setLabelText=function(y){var m=gc(t,e,y);y0(l,m)})}else l&&(l.ignore=!0);r.dirty()}function qt(r,e){e=e||"label";for(var t={normal:r.getModel(e)},a=0;a<de.length;a++){var n=de[a];t[n]=r.getModel([n,e])}return t}function Dt(r,e,t,a,n){var i={};return Xw(i,r,t,a,n),e&&z(i,e),i}function ys(r,e,t){e=e||{};var a={},n,i=r.getShallow("rotate"),o=pt(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 Xw(r,e,t,a,n){t=t||js;var i=e.ecModel,o=i&&i.option.textStyle,s=Kw(e),l;if(s){l={};for(var u in s)if(s.hasOwnProperty(u)){var c=e.getModel(["rich",u]);Rf(l[u]={},c,o,t,a,n,!1,!0)}}l&&(r.rich=l);var v=e.get("overflow");v&&(r.overflow=v);var h=e.get("minMargin");h!=null&&(r.margin=h),Rf(r,e,o,t,a,n,!0,!1)}function Kw(r){for(var e;r&&r!==r.ecModel;){var t=(r.option||js).rich;if(t){e=e||{};for(var a=Ut(t),n=0;n<a.length;n++){var i=a[n];e[i]=1}}r=r.parentModel}return e}var If=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],Lf=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],Pf=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Rf(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=pt(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 h=pt(e.getShallow("textBorderWidth"),t.textBorderWidth);h!=null&&(r.lineWidth=h);var f=pt(e.getShallow("textBorderType"),t.textBorderType);f!=null&&(r.lineDash=f);var p=pt(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<If.length;d++){var g=If[d],y=pt(e.getShallow(g),t[g]);y!=null&&(r[g]=y)}for(var d=0;d<Lf.length;d++){var g=Lf[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<Pf.length;d++){var g=Pf[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 Lv(r,e){var t=e&&e.getModel("textStyle");return Ui([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 An=ut();function m0(r,e,t,a){if(r){var n=An(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 S0(r,e,t,a,n){var i=An(r);if(!i.valueAnimation||i.prevValue===i.value)return;var o=i.defaultInterpolatedText,s=pt(i.interpolatedValue,i.prevValue),l=i.value;function u(c){var v=e0(t,i.precision,s,l,c);i.interpolatedValue=c===1?null:v;var h=gc({labelDataIndex:e,labelFetcher:n,defaultText:o?o(v):v+""},i.statesModels,v);y0(r,h)}r.percent=0,(i.prevValue==null?Pt:ft)(r,{percent:1},a,e,null,u)}var qw=["textStyle","color"],Dl=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Cl=new vt,jw=(function(){function r(){}return r.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow("color")||(!e&&t?t.get(qw):null)},r.prototype.getFont=function(){return Lv({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<Dl.length;a++)t[Dl[a]]=this.getShallow(Dl[a]);return Cl.useStyle(t),Cl.update(),Cl.getBoundingRect()},r})(),_0=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],Jw=_a(_0),Qw=(function(){function r(){}return r.prototype.getLineStyle=function(e){return Jw(this,e)},r})(),x0=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],tA=_a(x0),eA=(function(){function r(){}return r.prototype.getItemStyle=function(e,t){return tA(this,e,t)},r})(),mt=(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){nt(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(j(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(!Nt.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})();Sv(mt);qb(mt);Jt(mt,Qw);Jt(mt,eA);Jt(mt,ew);Jt(mt,jw);function Nn(r){return r==null?0:r.length||1}function Ef(r){return r}var dr=(function(){function r(e,t,a,n,i,o){this._old=e,this._new=t,this._oldKeyGetter=a||Ef,this._newKeyGetter=n||Ef,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=Nn(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=Nn(u),h=Nn(c);if(v>1&&h===1)this._updateManyToOne&&this._updateManyToOne(c,u),n[l]=null;else if(v===1&&h>1)this._updateOneToMany&&this._updateOneToMany(c,u),n[l]=null;else if(v===1&&h===1)this._update&&this._update(c,u),n[l]=null;else if(v>1&&h>1)this._updateManyToMany&&this._updateManyToMany(c,u),n[l]=null;else if(v>1)for(var f=0;f<v;f++)this._remove&&this._remove(u[f]);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=Nn(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=Nn(l);u===0?(t[s]=o,i&&a.push(s)):u===1?t[s]=[l,o]:l.push(o)}}},r})(),b0=$(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),Oe="original",se="arrayRows",Ve="objectRows",rr="keyedColumns",Nr="typedArray",w0="unknown",tr="column",Tn="row",te={Must:1,Might:2,Not:3},A0=ut();function rA(r){A0(r).datasetMap=$()}function T0(r,e,t){var a={},n=Rv(e);if(!n||!r)return a;var i=[],o=[],s=e.ecModel,l=A0(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 h=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=h.valueWayDim;f(a[y],S,m),f(o,S,m),h.valueWayDim+=m}else if(c===g)f(a[y],0,m),f(i,0,m);else{var S=h.categoryWayDim;f(a[y],S,m),f(o,S,m),h.categoryWayDim+=m}});function f(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 Pv(r,e,t){var a={},n=Rv(r);if(!n)return a;var i=e.sourceFormat,o=e.dimensionsDefine,s;(i===Ve||i===rr)&&w(o,function(c,v){(J(c)?c.name:c)==="name"&&(s=v)});var l=(function(){for(var c={},v={},h=[],f=0,p=Math.min(5,t);f<p;f++){var d=C0(e.data,i,e.seriesLayoutBy,o,e.startIndex,f);h.push(d);var g=d===te.Not;if(g&&c.v==null&&f!==s&&(c.v=f),(c.n==null||c.n===c.v||!g&&h[c.n]===te.Not)&&(c.n=f),y(c)&&h[c.n]!==te.Not)return c;g||(d===te.Might&&v.v==null&&f!==s&&(v.v=f),(v.n==null||v.n===v.v)&&(v.n=f))}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 Rv(r){var e=r.get("data",!0);if(!e)return $i(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Ht).models[0]}function aA(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:$i(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Ht).models}function D0(r,e){return C0(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,e)}function C0(r,e,t,a,n,i){var o,s=5;if(_e(r))return te.Not;var l,u;if(a){var c=a[i];J(c)?(l=c.name,u=c.type):Y(c)&&(l=c)}if(u!=null)return u==="ordinal"?te.Must:te.Not;if(e===se){var v=r;if(t===Tn){for(var h=v[i],f=0;f<(h||[]).length&&f<s;f++)if((o=_(h[n+f]))!=null)return o}else for(var f=0;f<v.length&&f<s;f++){var p=v[n+f];if(p&&(o=_(p[i]))!=null)return o}}else if(e===Ve){var d=r;if(!l)return te.Not;for(var f=0;f<d.length&&f<s;f++){var g=d[f];if(g&&(o=_(g[l]))!=null)return o}}else if(e===rr){var y=r;if(!l)return te.Not;var h=y[l];if(!h||_e(h))return te.Not;for(var f=0;f<h.length&&f<s;f++)if((o=_(h[f]))!=null)return o}else if(e===Oe)for(var m=r,f=0;f<m.length&&f<s;f++){var g=m[f],S=xn(g);if(!B(S))return te.Not;if((o=_(S[i]))!=null)return o}function _(x){var b=Y(x);if(x!=null&&Number.isFinite(Number(x))&&x!=="")return b?te.Might:te.Not;if(b&&x!=="-")return te.Must}return te.Not}var Js=(function(){function r(e){this.data=e.data||(e.sourceFormat===rr?{}:[]),this.sourceFormat=e.sourceFormat||w0,this.seriesLayoutBy=e.seriesLayoutBy||tr,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&&D0(this,a)===te.Must&&(n.type="ordinal")}}return r})();function Ev(r){return r instanceof Js}function yc(r,e,t){t=t||M0(r);var a=e.seriesLayoutBy,n=iA(r,t,a,e.sourceHeader,e.dimensions),i=new Js({data:r,sourceFormat:t,seriesLayoutBy:a,dimensionsDefine:n.dimensionsDefine,startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount,metaRawOption:j(e)});return i}function kv(r){return new Js({data:r,sourceFormat:_e(r)?Nr:Oe})}function nA(r){return new Js({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:j(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function M0(r){var e=w0;if(_e(r))e=Nr;else if(B(r)){r.length===0&&(e=se);for(var t=0,a=r.length;t<a;t++){var n=r[t];if(n!=null){if(B(n)||_e(n)){e=se;break}else if(J(n)){e=Ve;break}}}}else if(J(r)){for(var i in r)if(Z(r,i)&&yn(r[i])){e=rr;break}}return e}function iA(r,e,t,a,n){var i,o;if(!r)return{dimensionsDefine:kf(n),startIndex:o,dimensionsDetectedCount:i};if(e===se){var s=r;a==="auto"||a==null?Nf(function(u){u!=null&&u!=="-"&&(Y(u)?o==null&&(o=1):o=0)},t,s,10):o=St(a)?a:a?1:0,!n&&o===1&&(n=[],Nf(function(u,c){n[c]=u!=null?u+"":""},t,s,1/0)),i=n?n.length:t===Tn?s.length:s[0]?s[0].length:null}else if(e===Ve)n||(n=oA(r));else if(e===rr)n||(n=[],w(r,function(u,c){n.push(c)}));else if(e===Oe){var l=xn(r[0]);i=B(l)&&l.length||1}return{startIndex:o,dimensionsDefine:kf(n),dimensionsDetectedCount:i}}function oA(r){for(var e=0,t;e<r.length&&!(t=r[e++]););if(t)return Ut(t)}function kf(r){if(r){var e=$();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 Nf(r,e,t,a){if(e===Tn)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 I0(r){var e=r.sourceFormat;return e===Ve||e===rr}var $r,Xr,Kr,Of,Vf,L0=(function(){function r(e,t){var a=Ev(e)?e:kv(e);this._source=a;var n=this._data=a.data;a.sourceFormat===Nr&&(this._offset=0,this._dimSize=t,this._data=n),Vf(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;Vf=function(o,s,l){var u=l.sourceFormat,c=l.seriesLayoutBy,v=l.startIndex,h=l.dimensionsDefine,f=Of[Nv(u,c)];if(z(o,f),u===Nr)o.getItem=t,o.count=n,o.fillStorage=a;else{var p=P0(u,c);o.getItem=U(p,null,s,v,h);var d=R0(u,c);o.count=U(d,null,s,v,h)}};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,h=0;h<v;h++){for(var f=u[h],p=f[0]==null?1/0:f[0],d=f[1]==null?-1/0:f[1],g=s-o,y=l[h],m=0;m<g;m++){var S=c[m*v+h];y[o+m]=S,S<p&&(p=S),S>d&&(d=S)}f[0]=p,f[1]=d}},n=function(){return this._data?this._data.length/this._dimSize:0};Of=(e={},e[se+"_"+tr]={pure:!0,appendData:i},e[se+"_"+Tn]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},e[Ve]={pure:!0,appendData:i},e[rr]={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[Oe]={appendData:i},e[Nr]={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})(),Bf=function(r,e,t,a){return r[a]},sA=($r={},$r[se+"_"+tr]=function(r,e,t,a){return r[a+e]},$r[se+"_"+Tn]=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},$r[Ve]=Bf,$r[rr]=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},$r[Oe]=Bf,$r);function P0(r,e){var t=sA[Nv(r,e)];return t}var zf=function(r,e,t){return r.length},lA=(Xr={},Xr[se+"_"+tr]=function(r,e,t){return Math.max(0,r.length-e)},Xr[se+"_"+Tn]=function(r,e,t){var a=r[0];return a?Math.max(0,a.length-e):0},Xr[Ve]=zf,Xr[rr]=function(r,e,t){var a=t[0].name,n=r[a];return n?n.length:0},Xr[Oe]=zf,Xr);function R0(r,e){var t=lA[Nv(r,e)];return t}var Ml=function(r,e,t){return r[e]},uA=(Kr={},Kr[se]=Ml,Kr[Ve]=function(r,e,t){return r[t]},Kr[rr]=Ml,Kr[Oe]=function(r,e,t){var a=xn(r);return a instanceof Array?a[e]:a},Kr[Nr]=Ml,Kr);function E0(r){var e=uA[r];return e}function Nv(r,e){return r===se?r+"_"+e:r}function un(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 E0(i)(a,o,s)}else{var l=a;return i===Oe&&(l=xn(a)),l}}}}var cA=(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 vA(r,e){var t={},a=t.encode={},n=$(),i=[],o=[],s={};w(r.dimensions,function(h){var f=r.getDimensionInfo(h),p=f.coordDim;if(p){var d=f.coordDimIndex;Il(a,p)[d]=h,f.isExtraCoord||(n.set(p,1),hA(f.type)&&(i[0]=h),Il(s,p)[d]=r.getDimensionIndex(f.name)),f.defaultTooltip&&o.push(h)}b0.each(function(g,y){var m=Il(a,y),S=f.otherDims[y];S!=null&&S!==!1&&(m[S]=f.name)})});var l=[],u={};n.each(function(h,f){var p=a[f];u[f]=p[0],l=l.concat(p)}),t.dataDimsOnCoord=l,t.dataDimIndicesOnCoord=G(l,function(h){return r.getDimensionInfo(h).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 cA(s,e),t}function Il(r,e){return r.hasOwnProperty(e)||(r[e]=[]),r[e]}function ms(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function hA(r){return!(r==="ordinal"||r==="time")}var Jo=(function(){function r(e){this.otherDims={},e!=null&&z(this,e)}return r})();function Or(r,e){var t=e&&e.type;return t==="ordinal"?r:(t==="time"&&!St(r)&&r!=null&&r!=="-"&&(r=+er(r)),r==null||r===""?NaN:Number(r))}var fA=$({number:function(r){return parseFloat(r)},time:function(r){return+er(r)},trim:function(r){return Y(r)?Ui(r):r}});function k0(r){return fA.get(r)}var N0={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}},pA=(function(){function r(e,t){if(!St(t)){var a="";gt(a)}this._opFn=N0[e],this._rvalFloat=hr(t)}return r.prototype.evaluate=function(e){return St(e)?this._opFn(e,this._rvalFloat):this._opFn(hr(e),this._rvalFloat)},r})(),O0=(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=St(e)?e:hr(e),n=St(t)?t:hr(t),i=isNaN(a),o=isNaN(n);if(i&&(a=this._incomparable),o&&(n=this._incomparable),i&&o){var s=Y(e),l=Y(t);s&&(a=l?e:0),l&&(n=s?t:0)}return a<n?this._resultLT:a>n?-this._resultLT:0},r})(),dA=(function(){function r(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=hr(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=hr(e)===this._rvalFloat)}return this._isEQ?t:!t},r})();function gA(r,e){return r==="eq"||r==="ne"?new dA(r==="eq",e):Z(N0,r)?new pA(r,e):null}var Qs="undefined",yA=typeof Uint32Array===Qs?Array:Uint32Array,mA=typeof Uint16Array===Qs?Array:Uint16Array,V0=typeof Int32Array===Qs?Array:Int32Array,Gf=typeof Float64Array===Qs?Array:Float64Array,B0={float:Gf,int:V0,ordinal:Array,number:Array,time:Gf},Ll;function Oa(r){return r>65535?yA:mA}function Va(){return[1/0,-1/0]}function SA(r){var e=r.constructor;return e===Array?r.slice():new e(r)}function Ff(r,e,t,a,n){var i=B0[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 mc=(function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=$()}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=Ll[n.sourceFormat];this._dimValueGetter=a||i,this._rawExtent=[],I0(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 B0[t||"float"](this._rawCount),this._rawExtent[i]=Va(),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]=Va());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];Ff(a,u,c.type,l,!0)}for(var v=[],h=s;h<l;h++)for(var f=h-s,p=0;p<i;p++){var c=n[p],d=Ll.arrayRows.call(this,e[f]||v,c.property,f,p);a[p][h]=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]=Va()),Ff(i,c,v.type,t,a)}if(n.fillStorage)n.fillStorage(e,t,i,l);else for(var h=[],f=e;f<t;f++){h=n.getItem(f,h);for(var p=0;p<s;p++){var d=i[p],g=this._dimValueGetter(h,u[p],f,p);d[f]=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 h=this.getRawIndex(c),f=t-i[h],p=Math.abs(f);p<=a&&((p<s||p===s&&f>=0&&l<0)&&(s=p,l=f,u=0),f===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=Oa(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=Oa(a._rawCount),o=new i(n),s=[],l=e.length,u=0,c=e[0],v=a._chunks,h=0;h<n;h++){var f=void 0,p=a.getRawIndex(h);if(l===0)f=t(h);else if(l===1){var d=v[c][p];f=t(d,h)}else{for(var g=0;g<l;g++)s[g]=v[e[g]][p];s[g]=h,f=t.apply(null,s)}f&&(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=Ut(e),i=n.length;if(!i)return this;var o=t.count(),s=Oa(t._rawCount),l=new s(o),u=0,c=n[0],v=e[c][0],h=e[c][1],f=t._chunks,p=!1;if(!t._indices){var d=0;if(i===1){for(var g=f[n[0]],y=0;y<a;y++){var m=g[y];(m>=v&&m<=h||isNaN(m))&&(l[u++]=d),d++}p=!0}else if(i===2){for(var g=f[n[0]],S=f[n[1]],_=e[n[1]][0],x=e[n[1]][1],y=0;y<a;y++){var m=g[y],b=S[y];(m>=v&&m<=h||isNaN(m))&&(b>=_&&b<=x||isNaN(b))&&(l[u++]=d),d++}p=!0}}if(!p)if(i===1)for(var y=0;y<o;y++){var A=t.getRawIndex(y),m=f[n[0]][A];(m>=v&&m<=h||isNaN(m))&&(l[u++]=A)}else for(var y=0;y<o;y++){for(var T=!0,A=t.getRawIndex(y),D=0;D<i;D++){var C=n[D],m=f[C][A];(m<e[C][0]||m>e[C][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]]=Va();for(var v=0;v<s;v++){for(var h=e.getRawIndex(v),f=0;f<o;f++)l[f]=n[t[f]][h];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[h]=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,h,f=new(Oa(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));f[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 _=this.getRawIndex(S),x=i[_];isNaN(x)||(m+=x)}m/=g-d;var b=p,A=Math.min(p+l,o),T=p-1,D=i[u];c=-1,h=b;for(var C=-1,M=0,S=b;S<A;S++){var _=this.getRawIndex(S),x=i[_];if(isNaN(x)){M++,C<0&&(C=_);continue}v=Math.abs((T-y)*(x-D)-(T-S)*(m-D)),v>c&&(c=v,h=_)}M>0&&M<A-b&&(f[s++]=Math.min(C,h),h=Math.max(C,h)),f[s++]=h,u=h}return f[s++]=this.getRawIndex(o-1),a._count=s,a._indices=f,a.getRawIndex=this._getRawIdx,a},r.prototype.minmaxDownSample=function(e,t){for(var a=this.clone([e],!0),n=a._chunks,i=Math.floor(1/t),o=n[e],s=this.count(),l=new(Oa(this._rawCount))(Math.ceil(s/i)*2),u=0,c=0;c<s;c+=i){var v=c,h=o[this.getRawIndex(v)],f=c,p=o[this.getRawIndex(f)],d=i;c+i>s&&(d=s-c);for(var g=0;g<d;g++){var y=this.getRawIndex(c+g),m=o[y];m<h&&(h=m,v=c+g),m>p&&(p=m,f=c+g)}var S=this.getRawIndex(v),_=this.getRawIndex(f);v<f?(l[u++]=S,l[u++]=_):(l[u++]=_,l[u++]=S)}return a._count=u,a._indices=l,a._updateGetRawIdx(),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]=Va(),h=new(Oa(this._rawCount))(Math.ceil(c/l)),f=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),h[f++]=m}return i._count=f,i._indices=h,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=Va();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&&on(e,function(s,l){return s[l]=!0,s},{});if(i)for(var o=0;o<n.length;o++)a._chunks[o]=i[o]?SA(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=j(this._extent),e._rawExtent=j(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 Or(t[i],this._dimensions[i])}Ll={arrayRows:e,objectRows:function(t,a,n,i){return Or(t[a],this._dimensions[i])},keyedColumns:e,original:function(t,a,n,i){var o=t&&(t.value==null?t:t.value);return Or(o instanceof Array?o[i]:o,this._dimensions[i])},typedArray:function(t,a,n,i){return t[i]}}})(),r})(),_A=ut(),xA={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},z0=(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=H0(this.source)))},r.prototype.getSourceDimensionIndex=function(e){return pt(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=I0(this.source),a=!W0(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 h=this.getSourceDimension(o);h&&(l=t?h.name:null,u=h.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+=xA[u]||"f",c&&(n+=c.uid),n+="$"}var f=this.source,p=[f.seriesLayoutBy,f.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 G0(r){return r instanceof z0}function F0(r){for(var e=$(),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 H0(r){var e=_A(r);return e.dimNameMap||(e.dimNameMap=F0(r.dimensionsDefine))}function W0(r){return r>30}var On=J,br=G,bA=typeof Int32Array>"u"?Array:Int32Array,wA="e\0\0",Hf=-1,AA=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],TA=["_approximateExtent"],Wf,vo,Vn,Bn,Pl,zn,Rl,he=(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","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var a,n=!1;G0(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],h=Y(v)?new Jo({name:v}):v instanceof Jo?v:new Jo(v),f=h.name;h.type=h.type||"float",h.coordDim||(h.coordDim=f,h.coordDimIndex=0);var p=h.otherDims=h.otherDims||{};o.push(f),i[f]=h,u[f]!=null&&(l=!0),h.createInvertedIndices&&(s[f]=[]),p.itemName===0&&(this._nameDimIdx=c),p.itemId===0&&(this._idDimIdx=c),n&&(h.storeDimIndex=c)}if(this.dimensions=o,this._dimInfos=i,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var d=this._dimIdxToName=$();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(St(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 mc&&(i=e),!i){var o=this.dimensions,s=Ev(e)||yn(e)?new L0(e,o.length):e;i=new mc;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=vA(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&&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&&Rl(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!==Nr&&!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===Oe;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 h=v.name;i[c]==null&&h!=null&&(i[c]=Yt(h,null));var f=v.id;o[c]==null&&f!=null&&(o[c]=Yt(f,null))}}if(this._shouldMakeIdFromName())for(var c=e;c<t;c++)Rl(this,c);Wf(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){On(e)?z(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=Vn(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 vo(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 B(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&&a[t];return n==null||isNaN(n)?Hf:n},r.prototype.indicesOfNearest=function(e,t,a){return this._store.indicesOfNearest(this._getStoreDimIndex(e),t,a)},r.prototype.each=function(e,t,a){K(e)&&(a=t,t=e,e=[]);var n=a||this,i=br(Bn(e),this._getStoreDimIndex,this);this._store.each(i,n?U(t,n):t)},r.prototype.filterSelf=function(e,t,a){K(e)&&(a=t,t=e,e=[]);var n=a||this,i=br(Bn(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,n?U(t,n):t),this},r.prototype.selectRange=function(e){var t=this,a={},n=Ut(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){K(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(Bn(e),this._getStoreDimIndex,this),s=zn(this);return s._store=this._store.map(o,i?U(t,i):t),s},r.prototype.modify=function(e,t,a,n){var i=a||n||this,o=br(Bn(e),this._getStoreDimIndex,this);this._store.modify(o,i?U(t,i):t)},r.prototype.downSample=function(e,t,a,n){var i=zn(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,a,n),i},r.prototype.minmaxDownSample=function(e,t){var a=zn(this);return a._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),a},r.prototype.lttbDownSample=function(e,t){var a=zn(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 mt(a,t,t&&t.ecModel)},r.prototype.diff=function(e){var t=this;return new dr(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(a){return vo(e,a)},function(a){return vo(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||{},On(e)?z(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),B(i)?i=i.slice():On(i)&&(i=z({},i)),n[t]=i),i},r.prototype.setItemVisual=function(e,t,a){var n=this._itemVisuals[e]||{};this._itemVisuals[e]=n,On(t)?z(n,t):n[t]=a},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(e,t){On(e)?z(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?z(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;cc(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)),Pl(e,this),e._store=this._store,e},r.prototype.wrapMethod=function(e,t){var a=this[e];K(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(){Wf=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 bA(o.categories.length);for(var l=0;l<a.length;l++)a[l]=Hf;for(var l=0;l<s.count();l++)a[s.get(i.storeDimIndex,l)]=l}})},Vn=function(e,t,a){return Yt(e._getCategory(t,a),null)},vo=function(e,t){var a=e._idList[t];return a==null&&e._idDimIdx!=null&&(a=Vn(e,e._idDimIdx,t)),a==null&&(a=wA+t),a},Bn=function(e){return B(e)||(e=e!=null?[e]:[]),e},zn=function(e){var t=new r(e._schema?e._schema:br(e.dimensions,e._getDimInfo,e),e.hostModel);return Pl(t,e),t},Pl=function(e,t){w(AA.concat(t.__wrappedMethods||[]),function(a){t.hasOwnProperty(a)&&(e[a]=t[a])}),e.__wrappedMethods=t.__wrappedMethods,w(TA,function(a){e[a]=j(t[a])}),e._calculationInfo=z({},t._calculationInfo)},Rl=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=Vn(e,i,t)),l==null&&o!=null&&(n[t]=l=Vn(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})();function ji(r,e){Ev(r)||(r=kv(r)),e=e||{};var t=e.coordDimensions||[],a=e.dimensionsDefine||r.dimensionsDefine||[],n=$(),i=[],o=CA(r,t,a,e.dimensionsCount),s=e.canOmitUnusedDimensions&&W0(o),l=a===r.dimensionsDefine,u=l?H0(r):F0(a),c=e.encodeDefine;!c&&e.encodeDefaulter&&(c=e.encodeDefaulter(r,o));for(var v=$(c),h=new V0(o),f=0;f<h.length;f++)h[f]=-1;function p(D){var C=h[D];if(C<0){var M=a[D],I=J(M)?M:{name:M},L=new Jo,R=I.name;R!=null&&u.get(R)!=null&&(L.name=L.displayName=R),I.type!=null&&(L.type=I.type),I.displayName!=null&&(L.displayName=I.displayName);var P=i.length;return h[D]=P,L.storeDimIndex=D,i.push(L),L}return i[C]}if(!s)for(var f=0;f<o;f++)p(f);v.each(function(D,C){var M=xt(D).slice();if(M.length===1&&!Y(M[0])&&M[0]<0){v.set(C,!1);return}var I=v.set(C,[]);w(M,function(L,R){var P=Y(L)?u.get(L):L;P!=null&&P<o&&(I[R]=P,g(p(P),C,R))})});var d=0;w(t,function(D){var C,M,I,L;if(Y(D))C=D,L={};else{L=D,C=L.name;var R=L.ordinalMeta;L.ordinalMeta=null,L=z({},L),L.ordinalMeta=R,M=L.dimsDef,I=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var P=v.get(C);if(P!==!1){if(P=xt(P),!P.length)for(var k=0;k<(M&&M.length||1);k++){for(;d<o&&p(d).coordDim!=null;)d++;d<o&&P.push(d++)}w(P,function(O,N){var V=p(O);if(l&&L.type!=null&&(V.type=L.type),g(Q(V,L),C,N),V.name==null&&M){var F=M[N];!J(F)&&(F={name:F}),V.name=V.displayName=F.name,V.defaultTooltip=F.defaultTooltip}I&&Q(V.otherDims,I)})}});function g(D,C,M){b0.get(C)!=null?D.otherDims[C]=M:(D.coordDim=C,D.coordDimIndex=M,n.set(C,!0))}var y=e.generateCoord,m=e.generateCoordCount,S=m!=null;m=y?m||1:0;var _=y||"value";function x(D){D.name==null&&(D.name=D.coordDim)}if(s)w(i,function(D){x(D)}),i.sort(function(D,C){return D.storeDimIndex-C.storeDimIndex});else for(var b=0;b<o;b++){var A=p(b),T=A.coordDim;T==null&&(A.coordDim=MA(_,n,S),A.coordDimIndex=0,(!y||m<=0)&&(A.isExtraCoord=!0),m--),x(A),A.type==null&&(D0(r,b)===te.Must||A.isExtraCoord&&(A.otherDims.itemName!=null||A.otherDims.seriesName!=null))&&(A.type="ordinal")}return DA(i),new z0({source:r,dimensions:i,fullDimensionCount:o,dimensionOmitted:s})}function DA(r){for(var e=$(),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 CA(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 MA(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 El={},Ji=(function(){function r(){this._coordinateSystems=[]}return r.prototype.create=function(e,t){var a=[];w(El,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){El[e]=t},r.get=function(e){return El[e]},r})(),IA=(function(){function r(e){this.coordSysDims=[],this.axisMap=$(),this.categoryAxisMap=$(),this.coordSysName=e}return r})();function LA(r){var e=r.get("coordinateSystem"),t=new IA(e),a=PA[e];if(a)return a(r,t,t.axisMap,t.categoryAxisMap),t}var PA={cartesian2d:function(r,e,t,a){var n=r.getReferringComponents("xAxis",Ht).models[0],i=r.getReferringComponents("yAxis",Ht).models[0];e.coordSysDims=["x","y"],t.set("x",n),t.set("y",i),Ba(n)&&(a.set("x",n),e.firstCategoryDimIndex=0),Ba(i)&&(a.set("y",i),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(r,e,t,a){var n=r.getReferringComponents("singleAxis",Ht).models[0];e.coordSysDims=["single"],t.set("single",n),Ba(n)&&(a.set("single",n),e.firstCategoryDimIndex=0)},polar:function(r,e,t,a){var n=r.getReferringComponents("polar",Ht).models[0],i=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],t.set("radius",i),t.set("angle",o),Ba(i)&&(a.set("radius",i),e.firstCategoryDimIndex=0),Ba(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),Ba(u)&&(a.set(c,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})}};function Ba(r){return r.get("type")==="category"}function RA(r,e,t){t=t||{};var a=t.byIndex,n=t.stackedCoordDimension,i,o,s;EA(e)?i=e:(o=e.schema,i=o.dimensions,s=e.store);var l=!!(r&&r.get("stack")),u,c,v,h;if(w(i,function(m,S){Y(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,h="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var f=c.coordDim,p=c.type,d=0;w(i,function(m){m.coordDim===f&&d++});var g={name:v,coordDim:f,coordDimIndex:d,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},y={name:h,coordDim:h,coordDimIndex:d+1,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(h,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:h,stackResultDimension:v}}function EA(r){return!G0(r.schema)}function Gr(r,e){return!!e&&e===r.getCalculationInfo("stackedDimension")}function U0(r,e){return Gr(r,e)?r.getCalculationInfo("stackResultDimension"):e}function kA(r,e){var t=r.get("coordinateSystem"),a=Ji.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=ms(l)}return o})),n||(n=a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]),n}function NA(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 _r(r,e,t){t=t||{};var a=e.getSourceManager(),n,i=!1;r?(i=!0,n=kv(r)):(n=a.getSource(),i=n.sourceFormat===Oe);var o=LA(e),s=kA(e,o),l=t.useEncodeDefaulter,u=K(l)?l:l?tt(T0,s,e):null,c={coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!i},v=ji(n,c),h=NA(v.dimensions,t.createInvertedIndices,o),f=i?null:a.getSharedDataStore(v),p=RA(e,{schema:v,store:f}),d=new he(v,e);d.setCalculationInfo(p);var g=h!=null&&OA(n)?function(y,m,S,_){return _===h?S:this.defaultDimValueGetter(y,m,S,_)}:null;return d.hasItemOption=!1,d.initData(i?n:f,null,g),d}function OA(r){if(r.sourceFormat===Oe){var e=VA(r.data||[]);return!B(xn(e))}}function VA(r){for(var e=0;e<r.length&&r[e]==null;)e++;return r[e]}var BA=Math.round(Math.random()*10);function Dn(r){return[r||"",BA++].join("_")}function zA(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,h={};for(w(i,function(m){h[m]=!0});v.length;){var f=v.pop(),p=c[f],d=!!h[f];d&&(s.call(l,f,p.originalDeps.slice()),delete h[f]),w(p.successor,d?y:g)}w(h,function(){var m="";throw new Error(m)});function g(m){c[m].entryCount--,c[m].entryCount===0&&v.push(m)}function y(m){h[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(h){ct(u.predecessor,h)<0&&u.predecessor.push(h);var f=a(o,h);ct(f.successor,h)<0&&f.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 Yr(r,e){return nt(nt({},r,!0),e,!0)}const FA={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}},HA={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType}",withoutName:"第{seriesId}个系列是一个{seriesType}",separator:{middle:"",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:"",end:""}}}};var Ss="ZH",Ov="EN",en=Ov,Qo={},Vv={},Y0=Nt.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||en).toUpperCase();return r.indexOf(Ss)>-1?Ss:en})():en;function Z0(r,e){r=r.toUpperCase(),Vv[r]=new mt(e),Qo[r]=e}function WA(r){if(Y(r)){var e=Qo[r.toUpperCase()]||{};return r===Ss||r===Ov?j(e):nt(j(e),j(Qo[en]),!1)}else return nt(j(r),j(Qo[en]),!1)}function Sc(r){return Vv[r]}function UA(){return Vv[en]}Z0(Ov,FA);Z0(Ss,HA);var Bv=1e3,zv=Bv*60,pi=zv*60,Ie=pi*24,Uf=Ie*365,ai={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}"},ho="{yyyy}-{MM}-{dd}",Yf={year:"{yyyy}",month:"{yyyy}-{MM}",day:ho,hour:ho+" "+ai.hour,minute:ho+" "+ai.minute,second:ho+" "+ai.second,millisecond:ai.none},kl=["year","month","day","hour","minute","second","millisecond"],$0=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function wr(r,e){return r+="","0000".substr(0,e-r.length)+r}function rn(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 YA(r){return r===rn(r)}function ZA(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function tl(r,e,t,a){var n=er(r),i=n[Gv(t)](),o=n[an(t)]()+1,s=Math.floor((o-1)/3)+1,l=n[el(t)](),u=n["get"+(t?"UTC":"")+"Day"](),c=n[Ci(t)](),v=(c-1)%12+1,h=n[rl(t)](),f=n[al(t)](),p=n[nl(t)](),d=c>=12?"pm":"am",g=d.toUpperCase(),y=a instanceof mt?a:Sc(a||Y0)||UA(),m=y.getModel("time"),S=m.get("month"),_=m.get("monthAbbr"),x=m.get("dayOfWeek"),b=m.get("dayOfWeekAbbr");return(e||"").replace(/{a}/g,d+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,i+"").replace(/{yy}/g,wr(i%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,S[o-1]).replace(/{MMM}/g,_[o-1]).replace(/{MM}/g,wr(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,wr(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,x[u]).replace(/{ee}/g,b[u]).replace(/{e}/g,u+"").replace(/{HH}/g,wr(c,2)).replace(/{H}/g,c+"").replace(/{hh}/g,wr(v+"",2)).replace(/{h}/g,v+"").replace(/{mm}/g,wr(h,2)).replace(/{m}/g,h+"").replace(/{ss}/g,wr(f,2)).replace(/{s}/g,f+"").replace(/{SSS}/g,wr(p,3)).replace(/{S}/g,p+"")}function $A(r,e,t,a,n){var i=null;if(Y(t))i=t;else if(K(t))i=t(r.value,e,{level:r.level});else{var o=z({},ai);if(r.level>0)for(var s=0;s<kl.length;++s)o[kl[s]]="{primary|"+o[kl[s]]+"}";var l=t?t.inherit===!1?t:Q(t,o):o,u=X0(r.value,n);if(l[u])i=l[u];else if(l.inherit){for(var c=$0.indexOf(u),s=c-1;s>=0;--s)if(l[u]){i=l[u];break}i=i||o.none}if(B(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 tl(new Date(r.value),i,n,a)}function X0(r,e){var t=er(r),a=t[an(e)]()+1,n=t[el(e)](),i=t[Ci(e)](),o=t[rl(e)](),s=t[al(e)](),l=t[nl(e)](),u=l===0,c=u&&s===0,v=c&&o===0,h=v&&i===0,f=h&&n===1,p=f&&a===1;return p?"year":f?"month":h?"day":v?"hour":c?"minute":u?"second":"millisecond"}function Zf(r,e,t){var a=St(r)?er(r):r;switch(e=e||X0(r,t),e){case"year":return a[Gv(t)]();case"half-year":return a[an(t)]()>=6?1:0;case"quarter":return Math.floor((a[an(t)]()+1)/4);case"month":return a[an(t)]();case"day":return a[el(t)]();case"half-day":return a[Ci(t)]()/24;case"hour":return a[Ci(t)]();case"minute":return a[rl(t)]();case"second":return a[al(t)]();case"millisecond":return a[nl(t)]()}}function Gv(r){return r?"getUTCFullYear":"getFullYear"}function an(r){return r?"getUTCMonth":"getMonth"}function el(r){return r?"getUTCDate":"getDate"}function Ci(r){return r?"getUTCHours":"getHours"}function rl(r){return r?"getUTCMinutes":"getMinutes"}function al(r){return r?"getUTCSeconds":"getSeconds"}function nl(r){return r?"getUTCMilliseconds":"getMilliseconds"}function XA(r){return r?"setUTCFullYear":"setFullYear"}function K0(r){return r?"setUTCMonth":"setMonth"}function q0(r){return r?"setUTCDate":"setDate"}function j0(r){return r?"setUTCHours":"setHours"}function J0(r){return r?"setUTCMinutes":"setMinutes"}function Q0(r){return r?"setUTCSeconds":"setSeconds"}function tS(r){return r?"setUTCMilliseconds":"setMilliseconds"}function eS(r){if(!$m(r))return Y(r)?r:"-";var e=(r+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function rS(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 Cn=Em;function _c(r,e,t){var a="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(c){return c&&Ui(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?er(r):r;if(isNaN(+l)){if(s)return"-"}else return tl(l,a,t)}if(e==="ordinal")return ic(r)?n(r):St(r)&&i(r)?r+"":"-";var u=hr(r);return i(u)?eS(u):ic(r)?n(r):typeof r=="boolean"?r+"":"-"}var $f=["a","b","c","d","e","f","g"],Nl=function(r,e){return"{"+r+(e??"")+"}"};function aS(r,e,t){B(e)||(e=[e]);var a=e.length;if(!a)return"";for(var n=e[0].$vars||[],i=0;i<n.length;i++){var o=$f[i];r=r.replace(Nl(o),Nl(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(Nl($f[l],s),t?ye(u):u)}return r}function KA(r,e,t){return w(e,function(a,n){r=r.replace("{"+n+"}",a)}),r}function qA(r,e){var t=Y(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:'+ye(a)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+ye(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 Aa(r,e){return e=e||"transparent",Y(r)?r:J(r)&&r.colorStops&&(r.colorStops[0]||{}).color||e}function _s(r,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=r}else window.open(r,e)}var ts=w,nS=["left","right","top","bottom","width","height"],ua=[["width","left","right"],["height","top","bottom"]];function Fv(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),h=v&&v.getBoundingRect(),f,p;if(r==="horizontal"){var d=c.width+(h?-h.x+c.x:0);f=i+d,f>a||l.newline?(i=0,f=d,o+=s+t,s=c.height):s=Math.max(s,c.height)}else{var g=c.height+(h?-h.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=f+t:o=p+t)})}var da=Fv;tt(Fv,"vertical");tt(Fv,"horizontal");function jA(r,e,t){var a=e.width,n=e.height,i=H(r.left,a),o=H(r.top,n),s=H(r.right,a),l=H(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=Cn(t||0),{width:Math.max(s-i-t[1]-t[3],0),height:Math.max(l-o-t[0]-t[2],0)}}function Zt(r,e,t){t=Cn(t||0);var a=e.width,n=e.height,i=H(r.left,a),o=H(r.top,n),s=H(r.right,a),l=H(r.bottom,n),u=H(r.width,a),c=H(r.height,n),v=t[2]+t[0],h=t[1]+t[3],f=r.aspect;switch(isNaN(u)&&(u=a-s-h-i),isNaN(c)&&(c=n-l-v-o),f!=null&&(isNaN(u)&&isNaN(c)&&(f>a/n?u=a*.8:c=n*.8),isNaN(u)&&(u=f*c),isNaN(c)&&(c=u/f)),isNaN(i)&&(i=a-s-u-h),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-h;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-h-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 il(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=Zt(Q({width:u.width,height:u.height},e),t,a),h=o?v.x-u.x:0,f=s?v.y-u.y:0;return l==="raw"?(i.x=h,i.y=f):(i.x+=h,i.y+=f),i===r&&r.markRedraw(),!0}function JA(r,e){return r[ua[e][0]]!=null||r[ua[e][1]]!=null&&r[ua[e][2]]!=null}function Mi(r){var e=r.layoutMode||r.constructor.layoutMode;return J(e)?e:e?{type:e}:null}function Fr(r,e,t){var a=t&&t.ignoreSize;!B(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 h={},f=0,p={},d=0,g=2;if(ts(c,function(S){p[S]=r[S]}),ts(c,function(S){s(e,S)&&(h[S]=p[S]=e[S]),l(h,S)&&f++,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||!f)return p;if(f>=g)return h;for(var y=0;y<c.length;y++){var m=c[y];if(!s(h,m)&&s(r,m)){h[m]=r[m];break}}return h}function s(c,v){return c.hasOwnProperty(v)}function l(c,v){return c[v]!=null&&c[v]!=="auto"}function u(c,v,h){ts(c,function(f){v[f]=h[f]})}}function Mn(r){return iS({},r)}function iS(r,e){return e&&r&&ts(nS,function(t){e.hasOwnProperty(t)&&(r[t]=e[t])}),r}var QA=ut(),lt=(function(r){E(e,r);function e(t,a,n){var i=r.call(this,t,a,n)||this;return i.uid=Dn("ec_cpt_model"),i}return e.prototype.init=function(t,a,n){this.mergeDefaultAndTheme(t,n)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=Mi(this),i=n?Mn(t):{},o=a.getTheme();nt(t,o.get(this.mainType)),nt(t,this.getDefaultOption()),n&&Fr(t,i,n)},e.prototype.mergeOption=function(t,a){nt(this.option,t,!0);var n=Mi(this);n&&Fr(this.option,t,n)},e.prototype.optionUpdated=function(t,a){},e.prototype.getDefaultOption=function(){var t=this.constructor;if(!$b(t))return t.defaultOption;var a=QA(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=nt(s,n[l],!0);a.defaultOption=s}return a.defaultOption},e.prototype.getReferringComponents=function(t,a){var n=t+"Index",i=t+"Id";return $i(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})(mt);Hm(lt,mt);Zs(lt);zA(lt);GA(lt,tT);function tT(r){var e=[];return w(lt.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}var Xf=ut(),eT=ut(),Hv=(function(){function r(){}return r.prototype.getColorFromPalette=function(e,t,a){var n=xt(this.get("color",!0)),i=this.get("colorLayer",!0);return oS(this,Xf,n,i,e,t,a)},r.prototype.clearColorPalette=function(){aT(this,Xf)},r})();function xc(r,e,t,a){var n=xt(r.get(["aria","decal","decals"]));return oS(r,eT,n,null,e,t,a)}function rT(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 oS(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:rT(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 aT(r,e){e(r).paletteIdx=0,e(r).paletteNameMap={}}var nT=/\{@(.+?)\}/g,ol=(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,h=v==="series",f=a.userOutput&&a.userOutput.get();return{componentType:v,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:h?this.subType:null,seriesIndex:this.seriesIndex,seriesId:h?this.id:null,seriesName:h?this.name:null,name:o,dataIndex:i,data:s,dataType:t,value:n,color:u,borderColor:c,dimensionNames:f?f.fullDimensions:null,encode:f?f.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&&B(l.value)&&(l.value=l.value[n]),!i){var u=s.getItemModel(e);i=u.get(t==="normal"?["label","formatter"]:[t,"label","formatter"])}if(K(i))return l.status=t,l.dimensionIndex=n,i(l);if(Y(i)){var c=aS(i,l);return c.replace(nT,function(v,h){var f=h.length,p=h;p.charAt(0)==="["&&p.charAt(f-1)==="]"&&(p=+p.slice(1,f-1));var d=un(s,e,p);if(o&&B(o.interpolatedValue)){var g=s.getDimensionIndex(p);g>=0&&(d=o.interpolatedValue[g])}return d!=null?d+"":""})}},r.prototype.getRawValue=function(e,t){return un(this.getData(t),e)},r.prototype.formatTooltip=function(e,t,a){},r})();function Kf(r){var e,t;return J(r)?r.type&&(t=r):e=r,{text:e,frag:t}}function di(r){return new iT(r)}var iT=(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 h=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var f=this._dueIndex,p=Math.min(h!=null?this._dueIndex+h:1/0,this._dueEnd);if(!a&&(v||f<p)){var d=this._progress;if(B(d))for(var g=0;g<d.length;g++)this._doProgress(d[g],f,p,l,u);else this._doProgress(d,f,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){qf.reset(t,a,n,i),this._callingProgress=e,this._callingProgress({start:t,end:a,count:a-t,next:qf.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),B(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})(),qf=(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}})(),oT=(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 Or(e,t)},r})();function sT(r,e){var t=new oT,a=r.data,n=t.sourceFormat=r.sourceFormat,i=r.startIndex,o="";r.seriesLayoutBy!==tr&&gt(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="";Z(l,y)&&gt(S),l[y]=m}});else for(var c=0;c<r.dimensionsDetectedCount;c++)s.push({index:c});var v=P0(n,tr);e.__isBuiltIn&&(t.getRawDataItem=function(d){return v(a,i,s,d)},t.getRawData=U(lT,null,r)),t.cloneRawData=U(uT,null,r);var h=R0(n,tr);t.count=U(h,null,a,i,s);var f=E0(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 f(d,g,y.name)}};return t.getDimensionInfo=U(cT,null,s,l),t.cloneAllDimensionInfo=U(vT,null,s),t}function lT(r){var e=r.sourceFormat;if(!Wv(e)){var t="";gt(t)}return r.data}function uT(r){var e=r.sourceFormat,t=r.data;if(!Wv(e)){var a="";gt(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===Ve){for(var n=[],i=0,o=t.length;i<o;i++)n.push(z({},t[i]));return n}}function cT(r,e,t){if(t!=null){if(St(t)||!isNaN(t)&&!Z(e,t))return r[t];if(Z(e,t))return e[t]}}function vT(r){return j(r)}var sS=$();function hT(r){r=j(r);var e=r.type,t="";e||gt(t);var a=e.split(":");a.length!==2&&gt(t);var n=!1;a[0]==="echarts"&&(e=a[1],n=!0),r.__isBuiltIn=n,sS.set(e,r)}function fT(r,e,t){var a=xt(r),n=a.length,i="";n||gt(i);for(var o=0,s=n;o<s;o++){var l=a[o];e=pT(l,e),o!==s-1&&(e.length=Math.max(e.length,1))}return e}function pT(r,e,t,a){var n="";e.length||gt(n),J(r)||gt(n);var i=r.type,o=sS.get(i);o||gt(n);var s=G(e,function(u){return sT(u,o)}),l=xt(o.transform({upstream:s[0],upstreamList:s,config:j(r.config)}));return G(l,function(u,c){var v="";J(u)||gt(v),u.data||gt(v);var h=M0(u.data);Wv(h)||gt(v);var f,p=e[0];if(p&&c===0&&!u.dimensions){var d=p.startIndex;d&&(u.data=p.data.slice(0,d).concat(u.data)),f={seriesLayoutBy:tr,sourceHeader:d,dimensions:p.metaRawOption.dimensions}}else f={seriesLayoutBy:tr,sourceHeader:0,dimensions:u.dimensions};return yc(u.data,f,null)})}function Wv(r){return r===se||r===Ve}var lS=(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(fo(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=_e(s)?Nr:Oe,i=[];var v=this._getSourceMetaRawOption()||{},h=u&&u.metaRawOption||{},f=pt(v.seriesLayoutBy,h.seriesLayoutBy)||null,p=pt(v.sourceHeader,h.sourceHeader),d=pt(v.dimensions,h.dimensions),g=f!==h.seriesLayoutBy||!!p!=!!h.sourceHeader||d;n=g?[yc(s,{seriesLayoutBy:f,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=[yc(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&&Jf(i)}var o,s=[],l=[];return w(e,function(u){u.prepareSource();var c=u.getSource(n||0),v="";n!=null&&!c&&Jf(v),s.push(c),l.push(u._getVersionSign())}),a?o=fT(a,s,{datasetIndex:t.componentIndex}):n!=null&&(o=[nA(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];fo(this._sourceHost)&&l?s=l._innerGetDataStore(e,t,a):(s=new mc,s.initData(new L0(t,e.length),e)),o[a]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if(fo(e)){var t=Rv(e);return t?[t.getSourceManager()]:[]}else return G(aA(e),function(a){return a.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,a,n;if(fo(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 jf(r){var e=r.option.transform;e&&cs(r.option.transform)}function fo(r){return r.mainType==="series"}function Jf(r){throw new Error(r)}var dT="line-height:1";function uS(r){var e=r.lineHeight;return e==null?dT:"line-height:"+ye(e+"")+"px"}function cS(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:"+ye(a+"")+"px;color:"+ye(t)+";font-weight:"+ye(n+""),valueStyle:"font-size:"+ye(o+"")+"px;color:"+ye(i)+";font-weight:"+ye(s+"")}:{nameStyle:{fontSize:a,fill:t,fontWeight:n},valueStyle:{fontSize:o,fill:i,fontWeight:s}}}var gT=[0,10,20,30],yT=["",`
`,`
`,`
`];function jt(r,e){return e.type=r,e}function bc(r){return r.type==="section"}function vS(r){return bc(r)?mT:ST}function hS(r){if(bc(r)){var e=0,t=r.blocks.length,a=t>1||t>0&&!r.noHeader;return w(r.blocks,function(n){var i=hS(n);i>=e&&(e=i+ +(a&&(!i||bc(n)&&!n.noHeader)))}),e}return 0}function mT(r,e,t,a){var n=e.noHeader,i=_T(hS(e)),o=[],s=e.blocks||[];Se(!s||B(s)),s=s||[];var l=r.orderMode;if(e.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(Z(u,l)){var c=new O0(u[l],null);s.sort(function(d,g){return c.evaluate(d.sortParam,g.sortParam)})}else l==="seriesDesc"&&s.reverse()}w(s,function(d,g){var y=e.valueFormatter,m=vS(d)(y?z(z({},r),{valueFormatter:y}):r,d,g>0?i.html:0,a);m!=null&&o.push(m)});var v=r.renderMode==="richText"?o.join(i.richText):wc(a,o.join(""),n?t:i.html);if(n)return v;var h=_c(e.header,"ordinal",r.useUTC),f=cS(a,r.renderMode).nameStyle,p=uS(a);return r.renderMode==="richText"?fS(r,h,f)+i.richText+v:wc(a,'<div style="'+f+";"+p+';">'+ye(h)+"</div>"+v,t)}function ST(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(_){return _=B(_)?_:[_],G(_,function(x,b){return _c(x,B(f)?f[b]:f,u)})};if(!(i&&o)){var v=s?"":r.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",n),h=i?"":_c(l,"ordinal",u),f=e.valueType,p=o?[]:c(e.value,e.dataIndex),d=!s||!i,g=!s&&i,y=cS(a,n),m=y.nameStyle,S=y.valueStyle;return n==="richText"?(s?"":v)+(i?"":fS(r,h,m))+(o?"":wT(r,p,d,g,S)):wc(a,(s?"":v)+(i?"":xT(h,!s,m))+(o?"":bT(p,d,g,S)),t)}}function Qf(r,e,t,a,n,i){if(r){var o=vS(r),s={useUTC:n,renderMode:t,orderMode:a,markupStyleCreator:e,valueFormatter:r.valueFormatter};return o(s,r,0,i)}}function _T(r){return{html:gT[r],richText:yT[r]}}function wc(r,e,t){var a='<div style="clear:both"></div>',n="margin: "+t+"px 0 0",i=uS(r);return'<div style="'+n+";"+i+';">'+e+a+"</div>"}function xT(r,e,t){var a=e?"margin-left:2px":"";return'<span style="'+t+";"+a+'">'+ye(r)+"</span>"}function bT(r,e,t,a){var n=t?"10px":"20px",i=e?"float:right;margin-left:"+n:"";return r=B(r)?r:[r],'<span style="'+i+";"+a+'">'+G(r,function(o){return ye(o)}).join("&nbsp;&nbsp;")+"</span>"}function fS(r,e,t){return r.markupStyleCreator.wrapRichTextStyle(e,t)}function wT(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(B(e)?e.join(" "):e,i)}function pS(r,e){var t=r.getData().getItemVisual(e,"style"),a=t[r.visualDrawType];return Aa(a)}function dS(r,e){var t=r.get("padding");return t??(e==="richText"?[8,10]:10)}var Ol=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=Xm()}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=qA({color:t,type:e,renderMode:a,markerId:n});return Y(i)?i:(this.richTextStyles[n]=i.style,i.content)},r.prototype.wrapRichTextStyle=function(e,t){var a={};B(t)?w(t,function(i){return z(a,i)}):z(a,t);var n=this._generateStyleName();return this.richTextStyles[n]=a,"{"+n+"|"+e+"}"},r})();function gS(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=B(s),u=pS(e,t),c,v,h,f;if(o>1||l&&!o){var p=AT(s,e,t,i,u);c=p.inlineValues,v=p.inlineValueTypes,h=p.blocks,f=p.inlineValues[0]}else if(o){var d=n.getDimensionInfo(i[0]);f=c=un(n,t,i[0]),v=d.type}else f=c=l?s[0]:s;var g=xv(e),y=g&&e.name||"",m=n.getName(t),S=a?y:m;return jt("section",{header:y,noHeader:a||!g,sortParam:f,blocks:[jt("nameValue",{markerType:"item",markerColor:u,name:S,noName:!Ui(S),value:c,valueType:v,dataIndex:t})].concat(h||[])})}function AT(r,e,t,a,n){var i=e.getData(),o=on(r,function(v,h,f){var p=i.getDimensionInfo(f);return v=v||p&&p.tooltip!==!1&&p.displayName!=null},!1),s=[],l=[],u=[];a.length?w(a,function(v){c(un(i,t,v),v)}):w(r,c);function c(v,h){var f=i.getDimensionInfo(h);!f||f.otherDims.tooltip===!1||(o?u.push(jt("nameValue",{markerType:"subItem",markerColor:n,name:f.displayName,value:v,valueType:f.type})):(s.push(v),l.push(f.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var Ar=ut();function po(r,e){return r.getName(e)||r.getId(e)}var es="__universalTransitionEnabled",Ct=(function(r){E(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=di({count:DT,reset:CT}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);var i=Ar(this).sourceManager=new lS(this);i.prepareSource();var o=this.getInitialData(t,n);ep(o,this),this.dataTask.context.data=o,Ar(this).dataBeforeProcessed=o,tp(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,a){var n=Mi(this),i=n?Mn(t):{},o=this.subType;lt.hasClass(o)&&(o+="Series"),nt(t,a.getTheme().get(this.subType)),nt(t,this.getDefaultOption()),xa(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Fr(t,i,n)},e.prototype.mergeOption=function(t,a){t=nt(this.option,t,!0),this.fillDataTextStyle(t.data);var n=Mi(this);n&&Fr(this.option,t,n);var i=Ar(this).sourceManager;i.dirty(),i.prepareSource();var o=this.getInitialData(t,a);ep(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,Ar(this).dataBeforeProcessed=o,tp(this),this._initSelectedMapFromData(o)},e.prototype.fillDataTextStyle=function(t){if(t&&!_e(t))for(var a=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&xa(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=Ac(this);if(a){var n=a.context.data;return t==null||!n.getLinkedData?n:n.getLinkedData(t)}else return Ar(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=Ac(this);if(a){var n=a.context;n.outputData=t,a!==this.dataTask&&(n.data=t)}Ar(this).data=t},e.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return $(t)},e.prototype.getSourceManager=function(){return Ar(this).sourceManager},e.prototype.getSource=function(){return this.getSourceManager().getSource()},e.prototype.getRawData=function(){return Ar(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 gS({series:this,dataIndex:t,multipleSeries:a})},e.prototype.isAnimationEnabled=function(){var t=this.ecModel;if(Nt.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=Hv.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=po(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=Ut(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[po(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[es])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],h=po(t,v);u[h]=!0,this._selectedDataIndicesMap[h]=t.getRawIndex(v)}}else if(s==="single"||s===!0){var f=a[l-1],h=po(t,f);o.selectedMap=(n={},n[h]=!0,n),this._selectedDataIndicesMap=(i={},i[h]=t.getRawIndex(f),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(Ct,ol);Jt(Ct,Hv);Hm(Ct,lt);function tp(r){var e=r.name;xv(r)||(r.name=TT(r)||e)}function TT(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 DT(r){return r.model.getRawData().count()}function CT(r){var e=r.model;return e.setData(e.getRawData().cloneShallow()),MT}function MT(r,e){e.outputData&&r.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function ep(r,e){w(_i(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(t){r.wrapMethod(t,tt(IT,e))})}function IT(r,e){var t=Ac(r);return t&&t.setOutputEnd((e||this).count()),e}function Ac(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}}var LT=Mt.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()}}),PT=Mt.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()}}),RT=Mt.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),h=Math.cos(u),f=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*f,l+s+h*f,t,a-p,t,a),r.bezierCurveTo(t,a-p,t-c+v*f,l+s+h*f,t-c,l+s),r.closePath()}}),ET=Mt.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()}}),kT={line:ee,rect:dt,roundRect:dt,square:dt,circle:Ca,diamond:PT,pin:RT,arrow:ET,triangle:LT},NT={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}},xs={};w(kT,function(r,e){xs[e]=new r});var OT=Mt.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,e,t){var a=oc(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=xs[a];n||(a="rect",n=xs[a]),NT[a](e.x,e.y,e.width,e.height,n.shape),n.buildPath(r,n.shape,t)}}});function VT(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 Wt(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 OT({shape:{symbolType:r,x:e,y:t,width:a,height:n}}),l.__isEmptyBrush=s,l.setColor=VT,i&&l.setColor(i),l}function In(r){return B(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function La(r,e){if(r!=null)return B(r)||(r=[r,r]),[H(r[0],e[0])||0,H(pt(r[1],r[0]),e[1])||0]}var BT=(function(r){E(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 _r(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var a=new et,n=Wt("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=Wt(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})(Ct);function cn(r,e){var t=r.mapDimensionsAll("defaultedLabel"),a=t.length;if(a===1){var n=un(r,e,t[0]);return n!=null?n+"":null}else if(a){for(var i=[],o=0;o<t.length;o++)i.push(un(r,e,t[o]));return i.join(" ")}}function yS(r,e){var t=r.mapDimensionsAll("defaultedLabel");if(!B(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 Qi=(function(r){E(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=Wt(t,-1,-1,2,2,null,o);s.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),s.drift=zT,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(){fr(this.childAt(0))},e.prototype.downplay=function(){pr(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 h=this.childAt(0);h.silent=!1;var f={scaleX:l[0]/2,scaleY:l[1]/2};c?h.attr(f):ft(h,f,s,a),Ue(h)}if(this._updateCommon(t,a,l,n,i),u){var h=this.childAt(0);if(!c){var f={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:h.style.opacity}};h.scaleX=h.scaleY=0,h.style.opacity=0,Pt(h,f,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,h,f,p,d,g,y;if(i&&(u=i.emphasisItemStyle,c=i.blurItemStyle,v=i.selectItemStyle,h=i.focus,f=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(),h=S.get("focus"),f=S.get("blurScope"),p=S.get("disabled"),d=qt(m),g=S.getShallow("scale"),y=m.getShallow("cursor")}var _=t.getItemVisual(a,"symbolRotate");s.attr("rotation",(_||0)*Math.PI/180||0);var x=La(t.getItemVisual(a,"symbolOffset"),n);x&&(s.x=x[0],s.y=x[1]),y&&s.attr("cursor",y);var b=t.getItemVisual(a,"style"),A=b.fill;if(s instanceof Ne){var T=s.style;s.useStyle(z({image:T.image,x:T.x,y:T.y,width:T.width,height:T.height},b))}else s.__isEmptyBrush?s.useStyle(z({},b)):s.useStyle(b),s.style.decal=null,s.setColor(A,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var D=t.getItemVisual(a,"liftZ"),C=this._z2;D!=null?C==null&&(this._z2=s.z2,s.z2+=D):C!=null&&(s.z2=C,this._z2=null);var M=o&&o.useNameLabel;ae(s,d,{labelFetcher:l,labelDataIndex:a,defaultText:I,inheritColor:A,defaultOpacity:b.opacity});function I(P){return M?t.getName(P):cn(t,P)}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 R=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;L.scaleX=this._sizeX*R,L.scaleY=this._sizeY*R,this.setSymbolScale(1),kt(this,h,f,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&&zr(l,{style:{opacity:0}},a,{dataIndex:o,removeOpt:s,cb:function(){i.removeTextContent()}})}else i.removeTextContent();zr(i,{style:{opacity:0},scaleX:0,scaleY:0},a,{dataIndex:o,cb:t,removeOpt:s})},e.getSymbolSize=function(t,a){return In(t.getItemVisual(a,"symbolSize"))},e})(et);function zT(r,e){this.parent.drift(r,e)}function Vl(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 rp(r){return r!=null&&!J(r)&&(r={isIgnore:r}),r||{}}function ap(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:qt(e),cursorStyle:e.get("cursor")}}var to=(function(){function r(e){this.group=new et,this._SymbolCtor=e||Qi}return r.prototype.updateData=function(e,t){this._progressiveEls=null,t=rp(t);var a=this.group,n=e.hostModel,i=this._data,o=this._SymbolCtor,s=t.disableAnimation,l=ap(e),u={disableAnimation:s},c=t.getSymbolPoint||function(v){return e.getItemLayout(v)};i||a.removeAll(),e.diff(i).add(function(v){var h=c(v);if(Vl(e,h,v,t)){var f=new o(e,v,l,u);f.setPosition(h),e.setItemGraphicEl(v,f),a.add(f)}}).update(function(v,h){var f=i.getItemGraphicEl(h),p=c(v);if(!Vl(e,p,v,t)){a.remove(f);return}var d=e.getItemVisual(v,"symbol")||"circle",g=f&&f.getSymbolType&&f.getSymbolType();if(!f||g&&g!==d)a.remove(f),f=new o(e,v,l,u),f.setPosition(p);else{f.updateData(e,v,l,u);var y={x:p[0],y:p[1]};s?f.attr(y):ft(f,y,n)}a.add(f),e.setItemGraphicEl(v,f)}).remove(function(v){var h=i.getItemGraphicEl(v);h&&h.fadeOut(function(){a.remove(h)},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=ap(e),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t,a){this._progressiveEls=[],a=rp(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(Vl(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){Ur(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})();function mS(r,e,t){var a=r.getBaseAxis(),n=r.getOtherAxis(a),i=GT(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)}),h=!1,f=e.getCalculationInfo("stackResultDimension");return Gr(e,v[0])&&(h=!0,v[0]=f),Gr(e,v[1])&&(h=!0,v[1]=f),{dataDimsForPoint:v,valueStart:i,valueAxisDim:s,baseAxisDim:o,stacked:!!h,valueDim:l,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function GT(r,e){var t=0,a=r.scale.getExtent();return e==="start"?t=a[0]:e==="end"?t=a[1]:St(e)&&!isNaN(e)?t=e:a[0]>0?t=a[0]:a[1]<0&&(t=a[1]),t}function SS(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)}var _S=typeof Float32Array<"u",FT=_S?Float32Array:Array;function Je(r){return B(r)?_S?new Float32Array(r):r:new FT(r)}function HT(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 WT(r,e,t,a,n,i,o,s){for(var l=HT(r,e),u=[],c=[],v=[],h=[],f=[],p=[],d=[],g=mS(n,e,o),y=r.getLayout("points")||[],m=e.getLayout("points")||[],S=0;S<l.length;S++){var _=l[S],x=!0,b=void 0,A=void 0;switch(_.cmd){case"=":b=_.idx*2,A=_.idx1*2;var T=y[b],D=y[b+1],C=m[A],M=m[A+1];(isNaN(T)||isNaN(D))&&(T=C,D=M),u.push(T,D),c.push(C,M),v.push(t[b],t[b+1]),h.push(a[A],a[A+1]),d.push(e.getRawIndex(_.idx1));break;case"+":var I=_.idx,L=g.dataDimsForPoint,R=n.dataToPoint([e.get(L[0],I),e.get(L[1],I)]);A=I*2,u.push(R[0],R[1]),c.push(m[A],m[A+1]);var P=SS(g,n,e,I);v.push(P[0],P[1]),h.push(a[A],a[A+1]),d.push(e.getRawIndex(I));break;case"-":x=!1}x&&(f.push(_),p.push(p.length))}p.sort(function(st,Vt){return d[st]-d[Vt]});for(var k=u.length,O=Je(k),N=Je(k),V=Je(k),F=Je(k),W=[],S=0;S<p.length;S++){var X=p[S],rt=S*2,at=X*2;O[rt]=u[at],O[rt+1]=u[at+1],N[rt]=c[at],N[rt+1]=c[at+1],V[rt]=v[at],V[rt+1]=v[at+1],F[rt]=h[at],F[rt+1]=h[at+1],W[S]=f[X]}return{current:O,next:N,stackedOnCurrent:V,stackedOnNext:F,status:W}}var Tr=Math.min,Dr=Math.max;function ga(r,e){return isNaN(r)||isNaN(e)}function Tc(r,e,t,a,n,i,o,s,l){for(var u,c,v,h,f,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,h=m;else{var S=y-u,_=m-c;if(S*S+_*_<.5){d+=i;continue}if(o>0){for(var x=d+i,b=e[x*2],A=e[x*2+1];b===y&&A===m&&g<a;)g++,x+=i,d+=i,b=e[x*2],A=e[x*2+1],y=e[d*2],m=e[d*2+1],S=y-u,_=m-c;var T=g+1;if(l)for(;ga(b,A)&&T<a;)T++,x+=i,b=e[x*2],A=e[x*2+1];var D=.5,C=0,M=0,I=void 0,L=void 0;if(T>=a||ga(b,A))f=y,p=m;else{C=b-u,M=A-c;var R=y-u,P=b-y,k=m-c,O=A-m,N=void 0,V=void 0;if(s==="x"){N=Math.abs(R),V=Math.abs(P);var F=C>0?1:-1;f=y-F*N*o,p=m,I=y+F*V*o,L=m}else if(s==="y"){N=Math.abs(k),V=Math.abs(O);var W=M>0?1:-1;f=y,p=m-W*N*o,I=y,L=m+W*V*o}else N=Math.sqrt(R*R+k*k),V=Math.sqrt(P*P+O*O),D=V/(V+N),f=y-C*o*(1-D),p=m-M*o*(1-D),I=y+C*o*D,L=m+M*o*D,I=Tr(I,Dr(b,y)),L=Tr(L,Dr(A,m)),I=Dr(I,Tr(b,y)),L=Dr(L,Tr(A,m)),C=I-y,M=L-m,f=y-C*N/V,p=m-M*N/V,f=Tr(f,Dr(u,y)),p=Tr(p,Dr(c,m)),f=Dr(f,Tr(u,y)),p=Dr(p,Tr(c,m)),C=y-f,M=m-p,I=y+C*V/N,L=m+M*V/N}r.bezierCurveTo(v,h,f,p,y,m),v=I,h=L}else r.lineTo(y,m)}u=y,c=m,d+=i}return g}var xS=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),UT=(function(r){E(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 xS},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+=Tc(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=km.CMD,s,l,u=a==="x",c=[],v=0;v<i.length;){var h=i[v++],f=void 0,p=void 0,d=void 0,g=void 0,y=void 0,m=void 0,S=void 0;switch(h){case o.M:s=i[v++],l=i[v++];break;case o.L:if(f=i[v++],p=i[v++],S=u?(t-s)/(f-s):(t-l)/(p-l),S<=1&&S>=0){var _=u?(p-l)*S+l:(f-s)*S+s;return u?[t,_]:[_,t]}s=f,l=p;break;case o.C:f=i[v++],p=i[v++],d=i[v++],g=i[v++],y=i[v++],m=i[v++];var x=u?nf(s,f,d,y,t,c):nf(l,p,g,m,t,c);if(x>0)for(var b=0;b<x;b++){var A=c[b];if(A<=1&&A>=0){var _=u?of(l,p,g,m,A):of(s,f,d,y,A);return u?[t,_]:[_,t]}}s=y,l=m;break}}},e})(Mt),YT=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(xS),bS=(function(r){E(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 YT},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=Tc(t,n,o,s,s,1,a.smooth,l,a.connectNulls);Tc(t,i,o+u-1,u,s,-1,a.stackedOnSmooth,l,a.connectNulls),o+=u+1,t.closePath()}},e})(Mt);function Ln(){var r=ut();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 wS=ut(),ZT=Ln(),bt=(function(){function r(){this.group=new et,this.uid=Dn("viewChart"),this.renderTask=di({plan:$T,reset:XT}),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&&ip(i,n,"emphasis")},r.prototype.downplay=function(e,t,a,n){var i=e.getData(n&&n.dataType);i&&ip(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){Ur(this.group,e)},r.markUpdateMethod=function(e,t){wS(e).updateMethod=t},r.protoInitialize=(function(){var e=r.prototype;e.type="chart"})(),r})();function np(r,e,t){r&&Ti(r)&&(e==="emphasis"?fr:pr)(r,t)}function ip(r,e,t){var a=ba(r,e),n=e&&e.highlightKey!=null?Bw(e.highlightKey):null;a!=null?w(xt(a),function(i){np(r.getItemGraphicEl(i),t,n)}):r.eachItemGraphicEl(function(i){np(i,t,n)})}Sv(bt);Zs(bt);function $T(r){return ZT(r.model)}function XT(r){var e=r.model,t=r.ecModel,a=r.api,n=r.payload,i=e.pipelineContext.progressiveRender,o=r.view,s=n&&wS(n).updateMethod,l=i?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](e,t,a,n),KT[l]}var KT={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)}}};function AS(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"])||0;o-=c/2,s-=c/2,l+=c,u+=c,l=Math.ceil(l),o!==Math.floor(o)&&(o=Math.floor(o),l++);var v=new dt({shape:{x:o,y:s,width:l,height:u}});if(e){var h=r.getBaseAxis(),f=h.isHorizontal(),p=h.inverse;f?(p&&(v.shape.x+=l),v.shape.width=0):(p||(v.shape.y+=u),v.shape.height=0);var d=K(n)?function(g){n(g,v)}:null;Pt(v,{shape:{width:l,height:u,x:o,y:s}},t,null,a,d)}return v}function TS(r,e,t){var a=r.getArea(),n=Ot(a.r0,1),i=Ot(a.r,1),o=new Ee({shape:{cx:Ot(r.cx,1),cy:Ot(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,Pt(o,{shape:{endAngle:a.endAngle,r:i}},t)}return o}function eo(r,e,t,a,n){if(r){if(r.type==="polar")return TS(r,e,t);if(r.type==="cartesian2d")return AS(r,e,t,a,n)}else return null;return null}function Pa(r,e){return r.type===e}function op(r,e){if(r.length===e.length){for(var t=0;t<r.length;t++)if(r[t]!==e[t])return;return!0}}function sp(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 lp(r,e){var t=sp(r),a=t[0],n=t[1],i=sp(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 up(r){return St(r)?r:r?.5:0}function qT(r,e,t){if(!t.valueDim)return[];for(var a=e.count(),n=Je(a*2),i=0;i<a;i++){var o=SS(t,r,e,i);n[i*2]=o[0],n[i*2+1]=o[1]}return n}function Cr(r,e,t,a,n){var i=t.getBaseAxis(),o=i.dim==="x"||i.dim==="radius"?0:1,s=[],l=0,u=[],c=[],v=[],h=[];if(n){for(l=0;l<r.length;l+=2){var f=e||r;!isNaN(f[l])&&!isNaN(f[l+1])&&h.push(r[l],r[l+1])}r=h}for(l=0;l<r.length-2;l+=2)switch(v[0]=r[l+2],v[1]=r[l+3],c[0]=r[l],c[1]=r[l+1],s.push(c[0],c[1]),a){case"end":u[o]=v[o],u[1-o]=c[1-o],s.push(u[0],u[1]);break;case"middle":var p=(c[o]+v[o])/2,d=[];u[o]=d[o]=p,u[1-o]=c[1-o],d[1-o]=v[1-o],s.push(u[0],u[1]),s.push(d[0],d[1]);break;default:u[o]=c[o],u[1-o]=v[1-o],s.push(u[0],u[1])}return s.push(r[l++],r[l++]),s}function jT(r,e){var t=[],a=r.length,n,i;function o(c,v,h){var f=c.coord,p=(h-f)/(v.coord-f),d=vb(p,[c.color,v.color]);return{coord:h,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 JT(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 h=jT(u,n==="x"?t.getWidth():t.getHeight()),f=h.length;if(!f&&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=h[0].coord-p,g=h[f-1].coord+p,y=g-d;if(y<.001)return"transparent";w(h,function(S){S.offset=(S.coord-d)/y}),h.push({offset:f?h[f-1].offset:.5,color:v[1]||"transparent"}),h.unshift({offset:f?h[0].offset:.5,color:v[0]||"transparent"});var m=new Us(0,0,0,0,h,!0);return m[n]=d,m[n+"2"]=g,m}}}function QT(r,e,t){var a=r.get("showAllSymbol"),n=a==="auto";if(!(a&&!n)){var i=t.getAxesByScale("ordinal")[0];if(i&&!(n&&tD(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 tD(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 eD(r,e){return isNaN(r)||isNaN(e)}function rD(r){for(var e=r.length/2;e>0&&eD(r[e*2-2],r[e*2-1]);e--);return e-1}function cp(r,e){return[r[e*2],r[e*2+1]]}function aD(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 DS(r){if(r.get(["endLabel","show"]))return!0;for(var e=0;e<de.length;e++)if(r.get([de[e],"endLabel","show"]))return!0;return!1}function Bl(r,e,t,a){if(Pa(e,"cartesian2d")){var n=a.getModel("endLabel"),i=n.get("valueAnimation"),o=a.getData(),s={lastFrameIndex:0},l=DS(a)?function(f,p){r._endLabelOnDuring(f,p,o,s,i,n,e)}:null,u=e.getBaseAxis().isHorizontal(),c=AS(e,t,a,function(){var f=r._endLabel;f&&t&&s.originalX!=null&&f.attr({x:s.originalX,y:s.originalY})},l);if(!a.get("clip",!0)){var v=c.shape,h=Math.max(v.width,v.height);u?(v.y-=h,v.height+=h*2):(v.x-=h,v.width+=h*2)}return l&&l(1,c),c}else return TS(e,t,a)}function nD(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 iD=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.init=function(){var t=new et,a=new to;this.group.add(a.group),this._symbolDraw=a,this._lineGroup=t,this._changePolyState=U(this._changePolyState,this)},e.prototype.render=function(t,a,n){var i=t.coordinateSystem,o=this.group,s=t.getData(),l=t.getModel("lineStyle"),u=t.getModel("areaStyle"),c=s.getLayout("points")||[],v=i.type==="polar",h=this._coordSys,f=this._symbolDraw,p=this._polyline,d=this._polygon,g=this._lineGroup,y=!a.ssr&&t.get("animation"),m=!u.isEmpty(),S=u.get("origin"),_=mS(i,s,S),x=m&&qT(i,s,_),b=t.get("showSymbol"),A=t.get("connectNulls"),T=b&&!v&&QT(t,s,i),D=this._data;D&&D.eachItemGraphicEl(function(st,Vt){st.__temp&&(o.remove(st),D.setItemGraphicEl(Vt,null))}),b||f.remove(),o.add(g);var C=v?!1:t.get("step"),M;i&&i.getArea&&t.get("clip",!0)&&(M=i.getArea(),M.width!=null?(M.x-=.1,M.y-=.1,M.width+=.2,M.height+=.2):M.r0&&(M.r0-=.5,M.r+=.5)),this._clipShapeForSymbol=M;var I=JT(s,i,n)||s.getVisual("style")[s.getVisual("drawType")];if(!(p&&h.type===i.type&&C===this._step))b&&f.updateData(s,{isIgnore:T,clipShape:M,disableAnimation:!0,getSymbolPoint:function(st){return[c[st*2],c[st*2+1]]}}),y&&this._initSymbolLabelAnimation(s,i,M),C&&(x&&(x=Cr(x,c,i,C,A)),c=Cr(c,null,i,C,A)),p=this._newPolyline(c),m?d=this._newPolygon(c,x):d&&(g.remove(d),d=this._polygon=null),v||this._initOrUpdateEndLabel(t,i,Aa(I)),g.setClipPath(Bl(this,i,!0,t));else{m&&!d?d=this._newPolygon(c,x):d&&!m&&(g.remove(d),d=this._polygon=null),v||this._initOrUpdateEndLabel(t,i,Aa(I));var L=g.getClipPath();if(L){var R=Bl(this,i,!1,t);Pt(L,{shape:R.shape},t)}else g.setClipPath(Bl(this,i,!0,t));b&&f.updateData(s,{isIgnore:T,clipShape:M,disableAnimation:!0,getSymbolPoint:function(st){return[c[st*2],c[st*2+1]]}}),(!op(this._stackedOnPoints,x)||!op(this._points,c))&&(y?this._doUpdateAnimation(s,x,i,n,C,S,A):(C&&(x&&(x=Cr(x,c,i,C,A)),c=Cr(c,null,i,C,A)),p.setShape({points:c}),d&&d.setShape({points:c,stackedOnPoints:x})))}var P=t.getModel("emphasis"),k=P.get("focus"),O=P.get("blurScope"),N=P.get("disabled");if(p.useStyle(Q(l.getLineStyle(),{fill:"none",stroke:I,lineJoin:"bevel"})),re(p,t,"lineStyle"),p.style.lineWidth>0&&t.get(["emphasis","lineStyle","width"])==="bolder"){var V=p.getState("emphasis").style;V.lineWidth=+p.style.lineWidth+1}q(p).seriesIndex=t.seriesIndex,kt(p,k,O,N);var F=up(t.get("smooth")),W=t.get("smoothMonotone");if(p.setShape({smooth:F,smoothMonotone:W,connectNulls:A}),d){var X=s.getCalculationInfo("stackedOnSeries"),rt=0;d.useStyle(Q(u.getAreaStyle(),{fill:I,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),X&&(rt=up(X.get("smooth"))),d.setShape({smooth:F,stackedOnSmooth:rt,smoothMonotone:W,connectNulls:A}),re(d,t,"areaStyle"),q(d).seriesIndex=t.seriesIndex,kt(d,k,O,N)}var at=this._changePolyState;s.eachItemGraphicEl(function(st){st&&(st.onHoverStateChange=at)}),this._polyline.onHoverStateChange=at,this._data=s,this._coordSys=i,this._stackedOnPoints=x,this._points=c,this._step=C,this._valueOrigin=S,t.get("triggerLineEvent")&&(this.packEventData(t,p),d&&this.packEventData(t,d))},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 h=t.get("zlevel")||0,f=t.get("z")||0;u=new Qi(o,s),u.x=c,u.y=v,u.setZ(h,f);var p=u.getSymbolPath().getTextContent();p&&(p.zlevel=h,p.z=f,p.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else bt.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 bt.prototype.downplay.call(this,t,a,n,i)},e.prototype._changePolyState=function(t){var a=this._polygon;ps(this._polyline,t),a&&ps(a,t)},e.prototype._newPolyline=function(t){var a=this._polyline;return a&&this._lineGroup.remove(a),a=new UT({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 bS({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");K(c)&&(c=c(null));var v=u.get("animationDelay")||0,h=K(v)?v(null):v;t.eachItemGraphicEl(function(f,p){var d=f;if(d){var g=[f.x,f.y],y=void 0,m=void 0,S=void 0;if(n)if(o){var _=n,x=a.pointToCoord(g);i?(y=_.startAngle,m=_.endAngle,S=-x[1]/180*Math.PI):(y=_.r0,m=_.r,S=x[0])}else{var b=n;i?(y=b.x,m=b.x+b.width,S=f.x):(y=b.y+b.height,m=b.y,S=f.y)}var A=m===y?0:(S-y)/(m-y);l&&(A=1-A);var T=K(v)?v(p):c*A+h,D=d.getSymbolPath(),C=D.getTextContent();d.attr({scaleX:0,scaleY:0}),d.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:T}),C&&C.animateFrom({style:{opacity:0}},{duration:300,delay:T}),D.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,a,n){var i=t.getModel("endLabel");if(DS(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 vt({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var c=rD(l);c>=0&&(ae(s,qt(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:c,defaultText:function(v,h,f){return f!=null?yS(o,f):cn(o,v)},enableTextSetter:!0},nD(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"),h=n.hostModel,f=h.get("connectNulls"),p=s.get("precision"),d=s.get("distance")||0,g=l.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,S=a.shape,_=m?y?S.x:S.y+S.height:y?S.x+S.width:S.y,x=(y?d:0)*(m?-1:1),b=(y?0:-d)*(m?-1:1),A=y?"x":"y",T=aD(v,_,A),D=T.range,C=D[1]-D[0],M=void 0;if(C>=1){if(C>1&&!f){var I=cp(v,D[0]);u.attr({x:I[0]+x,y:I[1]+b}),o&&(M=h.getRawValue(D[0]))}else{var I=c.getPointOn(_,A);I&&u.attr({x:I[0]+x,y:I[1]+b});var L=h.getRawValue(D[0]),R=h.getRawValue(D[1]);o&&(M=e0(n,p,L,R,T.t))}i.lastFrameIndex=D[0]}else{var P=t===1||i.lastFrameIndex>0?D[0]:0,I=cp(v,P);o&&(M=h.getRawValue(P)),u.attr({x:I[0]+x,y:I[1]+b})}if(o){var k=An(u);typeof k.setLabelText=="function"&&k.setLabelText(M)}}},e.prototype._doUpdateAnimation=function(t,a,n,i,o,s,l){var u=this._polyline,c=this._polygon,v=t.hostModel,h=WT(this._data,t,this._stackedOnPoints,a,this._coordSys,n,this._valueOrigin),f=h.current,p=h.stackedOnCurrent,d=h.next,g=h.stackedOnNext;if(o&&(p=Cr(h.stackedOnCurrent,h.current,n,o,l),f=Cr(h.current,null,n,o,l),g=Cr(h.stackedOnNext,h.next,n,o,l),d=Cr(h.next,null,n,o,l)),lp(f,d)>3e3||c&&lp(p,g)>3e3){u.stopAnimation(),u.setShape({points:d}),c&&(c.stopAnimation(),c.setShape({points:d,stackedOnPoints:g}));return}u.shape.__points=h.current,u.shape.points=f;var y={shape:{points:d}};h.current!==f&&(y.shape.__points=h.next),u.stopAnimation(),ft(u,y,v),c&&(c.setShape({points:f,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=h.status,_=0;_<S.length;_++){var x=S[_].cmd;if(x==="="){var b=t.getItemGraphicEl(S[_].idx1);b&&m.push({el:b,ptIdx:_})}}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 D=m[T].el,C=m[T].ptIdx*2;D.x=A[C],D.y=A[C+1],D.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})(bt);function ro(r,e){return{seriesType:r,plan:Ln(),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(f){return a.mapDimension(f)}).slice(0,2),l=s.length,u=a.getCalculationInfo("stackResultDimension");Gr(a,s[0])&&(s[0]=u),Gr(a,s[1])&&(s[1]=u);var c=a.getStore(),v=a.getDimensionIndex(s[0]),h=a.getDimensionIndex(s[1]);return l&&{progress:function(f,p){for(var d=f.end-f.start,g=o&&Je(d*l),y=[],m=[],S=f.start,_=0;S<f.end;S++){var x=void 0;if(l===1){var b=c.get(v,S);x=n.dataToPoint(b,null,m)}else y[0]=c.get(v,S),y[1]=c.get(h,S),x=n.dataToPoint(y,null,m);o?(g[_++]=x[0],g[_++]=x[1]):p.setItemLayout(S,x.slice())}o&&p.setLayout("points",g)}}}}}}var oD={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]}},sD=function(r){return Math.round(r.length/2)};function CS(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(),h=Math.abs(c[1]-c[0])*(v||1),f=Math.round(s/h);if(isFinite(f)&&f>1){i==="lttb"?e.setData(n.lttbDownSample(n.mapDimension(u.dim),1/f)):i==="minmax"&&e.setData(n.minmaxDownSample(n.mapDimension(u.dim),1/f));var p=void 0;Y(i)?p=oD[i]:K(i)&&(p=i),p&&e.setData(n.downSample(n.mapDimension(u.dim),1/f,p,sD))}}}}}function lD(r){r.registerChartView(iD),r.registerSeriesModel(BT),r.registerLayout(ro("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,CS("line"))}var Dc="__ec_stack_";function MS(r){return r.get("stack")||Dc+r.seriesIndex}function Uv(r){return r.dim+r.index}function uD(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(Q({bandWidth:n,axisKey:a,stackId:Dc+i},r));for(var o=PS(e),s=[],i=0;i<r.count;i++){var l=o[a][Dc+i];l.offsetCenter=l.offset+l.width/2,s.push(l)}return s}}function IS(r,e){var t=[];return e.eachSeriesByType(r,function(a){kS(a)&&t.push(a)}),t}function cD(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(),h=c.dim+"_"+c.index,f=v.getDimensionIndex(v.mapDimension(c.dim)),p=v.getStore(),d=0,g=p.count();d<g;++d){var y=p.get(f,d);e[h]?e[h].push(y):e[h]=[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 LS(r){var e=cD(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(),h=Math.abs(v[1]-v[0]);s=u?c/h*u:c}else{var f=a.getData();s=Math.abs(o[1]-o[0])/f.count()}var p=H(a.get("barWidth"),s),d=H(a.get("barMaxWidth"),s),g=H(a.get("barMinWidth")||(NS(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:Uv(i),stackId:MS(a)})}),PS(t)}function PS(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 h=a.barMinWidth;h&&(l[u].minWidth=h);var f=a.barGap;f!=null&&(s.gap=f);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=Ut(i).length;s=Math.max(35-l*4,15)+"%"}var u=H(s,o),c=H(a.gap,1),v=a.remainedWidth,h=a.autoWidthCount,f=(v-u)/(h+(h-1)*c);f=Math.max(f,0),w(i,function(y){var m=y.maxWidth,S=y.minWidth;if(y.width){var _=y.width;m&&(_=Math.min(_,m)),S&&(_=Math.max(_,S)),y.width=_,v-=_+c*_,h--}else{var _=f;m&&m<_&&(_=Math.min(m,v)),S&&S>_&&(_=S),_!==f&&(y.width=_,v-=_+c*_,h--)}}),f=(v-u)/(h+(h-1)*c),f=Math.max(f,0);var p=0,d;w(i,function(y,m){y.width||(y.width=f),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 vD(r,e,t){if(r&&e){var a=r[Uv(e)];return a}}function RS(r,e){var t=IS(r,e),a=LS(t);w(t,function(n){var i=n.getData(),o=n.coordinateSystem,s=o.getBaseAxis(),l=MS(n),u=a[Uv(s)][l],c=u.offset,v=u.width;i.setLayout({bandWidth:u.bandWidth,offset:c,size:v})})}function ES(r){return{seriesType:r,plan:Ln(),reset:function(e){if(kS(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=Gr(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),h=i.isHorizontal(),f=hD(n,i),p=NS(e),d=e.get("barMinHeight")||0,g=c&&t.getDimensionIndex(c),y=t.getLayout("size"),m=t.getLayout("offset");return{progress:function(S,_){for(var x=S.count,b=p&&Je(x*3),A=p&&l&&Je(x*3),T=p&&Je(x),D=a.master.getRect(),C=h?D.width:D.height,M,I=_.getStore(),L=0;(M=S.next())!=null;){var R=I.get(v?g:o,M),P=I.get(s,M),k=f,O=void 0;v&&(O=+R-I.get(o,M));var N=void 0,V=void 0,F=void 0,W=void 0;if(h){var X=a.dataToPoint([R,P]);if(v){var rt=a.dataToPoint([O,P]);k=rt[0]}N=k,V=X[1]+m,F=X[0]-k,W=y,Math.abs(F)<d&&(F=(F<0?-1:1)*d)}else{var X=a.dataToPoint([P,R]);if(v){var rt=a.dataToPoint([P,O]);k=rt[1]}N=X[0]+m,V=k,F=y,W=X[1]-k,Math.abs(W)<d&&(W=(W<=0?-1:1)*d)}p?(b[L]=N,b[L+1]=V,b[L+2]=h?F:W,A&&(A[L]=h?D.x:N,A[L+1]=h?V:D.y,A[L+2]=C),T[M]=M):_.setItemLayout(M,{x:N,y:V,width:F,height:W}),L+=3}p&&_.setLayout({largePoints:b,largeDataIndices:T,largeBackgroundPoints:A,valueAxisHorizontal:h})}}}}}}function kS(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function NS(r){return r.pipelineContext&&r.pipelineContext.large}function hD(r,e){var t=e.model.get("startValue");return t||(t=0),e.toGlobalCoord(e.dataToCoord(e.type==="log"?t>0?t:1:t))}var Ii=(function(r){E(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 _r(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(h,f){if(h.type==="category"&&a!=null){var p=h.getTicksCoords(),d=h.getTickModel().get("alignWithLabel"),g=o[f],y=a[f]==="x1"||a[f]==="y1";if(y&&!d&&(g+=1),p.length<2)return;if(p.length===2){s[f]=h.toGlobalCoord(h.getExtent()[y?1:0]);return}for(var m=void 0,S=void 0,_=1,x=0;x<p.length;x++){var b=p[x].coord,A=x===p.length-1?p[x-1].tickValue+_:p[x].tickValue;if(A===g){S=b;break}else if(A<g)m=b;else if(m!=null&&A>g){S=(b+m)/2;break}x===1&&(_=A-p[0].tickValue)}S==null&&(m?m&&(S=p[p.length-1].coord):S=p[0].coord),s[f]=h.toGlobalCoord(S)}});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})(Ct);Ct.registerClass(Ii);var fD=(function(r){E(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 _r(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=Yr(Ii.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})(Ii),bs="\0__throttleOriginMethod",vp="\0__throttleRate",hp="\0__throttleType";function Yv(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 h=function(){for(var f=[],p=0;p<arguments.length;p++)f[p]=arguments[p];a=new Date().getTime(),l=this,u=f;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 h.clear=function(){o&&(clearTimeout(o),o=null)},h.debounceNextCall=function(f){c=f},h}function Pn(r,e,t,a){var n=r[e];if(n){var i=n[bs]||n,o=n[hp],s=n[vp];if(s!==t||o!==a){if(t==null||!a)return r[e]=i;n=r[e]=Yv(i,t,a==="debounce"),n[bs]=i,n[hp]=a,n[vp]=t}return n}}function Li(r,e){var t=r[e];t&&t[bs]&&(t.clear&&t.clear(),r[e]=t[bs])}var pD=(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})(),ws=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="sausage",a}return e.prototype.getDefaultShape=function(){return new pD},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,h=a.clockwise,f=Math.PI*2,p=h?v-c<f:c-v<f;p||(c=v-(h?f:-f));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,!h)):t.moveTo(d*s+n,g*s+i),t.arc(n,i,s,c,v,!h),t.arc(y*u+n,m*u+i,l,v-Math.PI*2,v-Math.PI,!h),o!==0&&t.arc(n,i,o,v,c,h)},e})(Mt);function dD(r,e){e=e||{};var t=e.isRoundCap;return function(a,n,i){var o=n.position;if(!o||o instanceof Array)return oc(a,n,i);var s=r(o),l=n.distance!=null?n.distance:5,u=this.shape,c=u.cx,v=u.cy,h=u.r,f=u.r0,p=(h+f)/2,d=u.startAngle,g=u.endAngle,y=(d+g)/2,m=t?Math.abs(h-f)/2:0,S=Math.cos,_=Math.sin,x=c+h*S(d),b=v+h*_(d),A="left",T="top";switch(s){case"startArc":x=c+(f-l)*S(y),b=v+(f-l)*_(y),A="center",T="top";break;case"insideStartArc":x=c+(f+l)*S(y),b=v+(f+l)*_(y),A="center",T="bottom";break;case"startAngle":x=c+p*S(d)+go(d,l+m,!1),b=v+p*_(d)+yo(d,l+m,!1),A="right",T="middle";break;case"insideStartAngle":x=c+p*S(d)+go(d,-l+m,!1),b=v+p*_(d)+yo(d,-l+m,!1),A="left",T="middle";break;case"middle":x=c+p*S(y),b=v+p*_(y),A="center",T="middle";break;case"endArc":x=c+(h+l)*S(y),b=v+(h+l)*_(y),A="center",T="bottom";break;case"insideEndArc":x=c+(h-l)*S(y),b=v+(h-l)*_(y),A="center",T="top";break;case"endAngle":x=c+p*S(g)+go(g,l+m,!0),b=v+p*_(g)+yo(g,l+m,!0),A="left",T="middle";break;case"insideEndAngle":x=c+p*S(g)+go(g,-l+m,!0),b=v+p*_(g)+yo(g,-l+m,!0),A="right",T="middle";break;default:return oc(a,n,i)}return a=a||{},a.x=x,a.y=b,a.align=A,a.verticalAlign=T,a}}function gD(r,e,t,a){if(St(a)){r.setTextConfig({rotation:a});return}else if(B(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 go(r,e,t){return e*Math.sin(r)*(t?-1:1)}function yo(r,e,t){return e*Math.cos(r)*(t?1:-1)}function ca(r,e,t){var a=r.get("borderRadius");if(a==null)return t?{cornerRadius:0}:null;B(a)||(a=[a,a,a,a]);var n=Math.abs(e.r||0-e.r0||0);return{cornerRadius:G(a,function(i){return sn(i,n)})}}var zl=Math.max,Gl=Math.min;function yD(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 mD=(function(r){E(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){Ur(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 h=t.isAnimationEnabled()?t:null,f=SD(t,u);f&&this._enableRealtimeSort(f,s,n);var p=t.get("clip",!0)||f,d=yD(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=this._backgroundEls,b=i&&i.isInitSort,A=i&&i.type==="changeAxisOrder";function T(M){var I=mo[u.type](s,M),L=DD(u,v,I);return L.useStyle(m.getItemStyle()),u.type==="cartesian2d"?L.setShape("r",S):L.setShape("cornerRadius",S),_[M]=L,L}s.diff(l).add(function(M){var I=s.getItemModel(M),L=mo[u.type](s,M,I);if(y&&T(M),!(!s.hasValue(M)||!yp[u.type](L))){var R=!1;p&&(R=fp[u.type](d,L));var P=pp[u.type](t,s,M,L,v,h,c.model,!1,g);f&&(P.forceLabelAnimation=!0),mp(P,s,M,I,L,t,v,u.type==="polar"),b?P.attr({shape:L}):f?dp(f,h,P,L,M,v,!1,!1):Pt(P,{shape:L},t,M),s.setItemGraphicEl(M,P),o.add(P),P.ignore=R}}).update(function(M,I){var L=s.getItemModel(M),R=mo[u.type](s,M,L);if(y){var P=void 0;x.length===0?P=T(I):(P=x[I],P.useStyle(m.getItemStyle()),u.type==="cartesian2d"?P.setShape("r",S):P.setShape("cornerRadius",S),_[M]=P);var k=mo[u.type](s,M),O=VS(v,k,u);ft(P,{shape:O},h,M)}var N=l.getItemGraphicEl(I);if(!s.hasValue(M)||!yp[u.type](R)){o.remove(N);return}var V=!1;if(p&&(V=fp[u.type](d,R),V&&o.remove(N)),N?Ue(N):N=pp[u.type](t,s,M,R,v,h,c.model,!!N,g),f&&(N.forceLabelAnimation=!0),A){var F=N.getTextContent();if(F){var W=An(F);W.prevValue!=null&&(W.prevValue=W.value)}}else mp(N,s,M,L,R,t,v,u.type==="polar");b?N.attr({shape:R}):f?dp(f,h,N,R,M,v,!0,A):ft(N,{shape:R},t,M,null),s.setItemGraphicEl(M,N),N.ignore=V,o.add(N)}).remove(function(M){var I=l.getItemGraphicEl(M);I&&Di(I,t,M)}).execute();var D=this._backgroundGroup||(this._backgroundGroup=new et);D.removeAll();for(var C=0;C<_.length;++C)D.add(_[C]);o.add(D),this._backgroundEls=_,this._data=s},e.prototype._renderLarge=function(t,a,n){this._clear(),_p(t,this.group),this._updateLargeClip(t)},e.prototype._incrementalRenderLarge=function(t,a){this._removeBackground(),_p(a,this.group,this._progressiveEls,!0)},e.prototype._updateLargeClip=function(t){var a=t.get("clip",!0)&&eo(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){Di(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})(bt),fp={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=zl(e.x,r.x),s=Gl(e.x+e.width,n),l=zl(e.y,r.y),u=Gl(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=Gl(e.r,r.r),i=zl(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}},pp={cartesian2d:function(r,e,t,a,n,i,o,s,l){var u=new dt({shape:z({},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?ws:Ee,c=new u({shape:a,z2:1});c.name="item";var v=OS(n);if(c.calculateTextPosition=dD(v,{isRoundCap:u===ws}),i){var h=c.shape,f=n?"r":"endAngle",p={};h[f]=n?a.r0:a.startAngle,p[f]=a[f],(s?ft:Pt)(c,{shape:p},i)}return c}};function SD(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 dp(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:Pt)(t,{shape:l},e,n,null);var c=e?r.baseAxis.model:null;(o?ft:Pt)(t,{shape:u},c,n)}function gp(r,e){for(var t=0;t<e.length;t++)if(!isFinite(r[e[t]]))return!0;return!1}var _D=["x","y","width","height"],xD=["cx","cy","r","startAngle","endAngle"],yp={cartesian2d:function(r){return!gp(r,_D)},polar:function(r){return!gp(r,xD)}},mo={cartesian2d:function(r,e,t){var a=r.getItemLayout(e),n=t?wD(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 bD(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function OS(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 mp(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=ca(a.getModel("itemStyle"),c,!0);z(c,v),r.setShape(c)}}else{var u=a.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var h=a.getShallow("cursor");h&&r.attr("cursor",h);var f=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=qt(a);ae(r,p,{labelFetcher:i,labelDataIndex:t,defaultText:cn(i.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:f});var d=r.getTextContent();if(s&&d){var g=a.get(["label","position"]);r.textConfig.inside=g==="middle"?!0:null,gD(r,g==="outside"?f:g,OS(o),a.get(["label","rotate"]))}m0(d,p,i.getRawValue(t),function(m){return yS(e,m)});var y=a.getModel(["emphasis"]);kt(r,y.get("focus"),y.get("blurScope"),y.get("disabled")),re(r,a),bD(n)&&(r.style.fill="none",r.style.stroke="none",w(r.states,function(m){m.style&&(m.style.fill=m.style.stroke="none")}))}function wD(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 AD=(function(){function r(){}return r})(),Sp=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeBar",a}return e.prototype.getDefaultShape=function(){return new AD},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})(Mt);function _p(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 Sp({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 Sp({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")),v.style.stroke=null,q(v).seriesIndex=r.seriesIndex,r.get("silent")||(v.on("mousedown",xp),v.on("mousemove",xp)),t&&t.push(v)}var xp=Yv(function(r){var e=this,t=TD(e,r.offsetX,r.offsetY);q(e).dataIndex=t>=0?t:null},30,!1);function TD(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 h=c*3;if(l[a]=u,l[n]=i[h+2],s[a]=i[h+a],s[n]=i[h+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 VS(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 DD(r,e,t){var a=r.type==="polar"?Ee:dt;return new a({shape:VS(e,t,r),silent:!0,z2:0})}function CD(r){r.registerChartView(mD),r.registerSeriesModel(fD),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,tt(RS,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,ES("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,CS("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)})})}function BS(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=z({},n),o.dispatchAction(z(n,{type:a[1],seriesIndex:t(i,n)}))})})}function za(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(),h=ba(v,n.fromActionPayload);t.trigger(i,{type:i,seriesId:o.id,name:B(h)?v.getName(h[0]):v.getName(h),selected:Y(l)?l:z({},l)})}})}function MD(r,e,t){r.on("selectchanged",function(a){var n=t.getModel();a.isFromClick?(za("map","selectchanged",e,n,a),za("pie","selectchanged",e,n,a)):a.fromAction==="select"?(za("map","selected",e,n,a),za("pie","selected",e,n,a)):a.fromAction==="unselect"&&(za("map","unselected",e,n,a),za("pie","unselected",e,n,a))})}var bp=Math.PI*2,So=Math.PI/180;function zS(r,e){return Zt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function GS(r,e){var t=zS(r,e),a=r.get("center"),n=r.get("radius");B(n)||(n=[0,n]);var i=H(t.width,e.getWidth()),o=H(t.height,e.getHeight()),s=Math.min(i,o),l=H(n[0],s/2),u=H(n[1],s/2),c,v,h=r.coordinateSystem;if(h){var f=h.dataToPoint(a);c=f[0]||0,v=f[1]||0}else B(a)||(a=[a,a]),c=H(a[0],i)+t.x,v=H(a[1],o)+t.y;return{cx:c,cy:v,r0:l,r:u}}function ID(r,e,t){e.eachSeriesByType(r,function(a){var n=a.getData(),i=n.mapDimension("value"),o=zS(a,t),s=GS(a,t),l=s.cx,u=s.cy,c=s.r,v=s.r0,h=-a.get("startAngle")*So,f=a.get("endAngle"),p=a.get("padAngle")*So;f=f==="auto"?h-bp:-f*So;var d=a.get("minAngle")*So,g=d+p,y=0;n.each(i,function(O){!isNaN(O)&&y++});var m=n.getSum(i),S=Math.PI/(m||y)*2,_=a.get("clockwise"),x=a.get("roseType"),b=a.get("stillShowZeroSum"),A=n.getDataExtent(i);A[0]=0;var T=_?1:-1,D=[h,f],C=T*p/2;Nm(D,!_),h=D[0],f=D[1];var M=FS(a);M.startAngle=h,M.endAngle=f,M.clockwise=_;var I=Math.abs(f-h),L=I,R=0,P=h;if(n.setLayout({viewRect:o,r:c}),n.each(i,function(O,N){var V;if(isNaN(O)){n.setItemLayout(N,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:_,cx:l,cy:u,r0:v,r:x?NaN:c});return}x!=="area"?V=m===0&&b?S:O*S:V=I/y,V<g?(V=g,L-=g):R+=O;var F=P+T*V,W=0,X=0;p>V?(W=P+T*V/2,X=W):(W=P+C,X=F-C),n.setItemLayout(N,{angle:V,startAngle:W,endAngle:X,clockwise:_,cx:l,cy:u,r0:v,r:x?yt(O,A,[v,c]):c}),P=F}),L<bp&&y)if(L<=.001){var k=I/y;n.each(i,function(O,N){if(!isNaN(O)){var V=n.getItemLayout(N);V.angle=k;var F=0,W=0;k<p?(F=h+T*(N+1/2)*k,W=F):(F=h+T*N*k+C,W=h+T*(N+1)*k-C),V.startAngle=F,V.endAngle=W}})}else S=L/R,P=h,n.each(i,function(O,N){if(!isNaN(O)){var V=n.getItemLayout(N),F=V.angle===g?g:O*S,W=0,X=0;F<p?(W=P+T*F/2,X=W):(W=P+C,X=P+T*F-C),V.startAngle=W,V.endAngle=X,P+=T*F}})})}var FS=ut();function ao(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 Gn=Math.PI*2,qr=km.CMD,LD=["top","right","bottom","left"];function PD(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 RD(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)%Gn<1e-4)return l[0]=c,l[1]=v,u-t;if(i){var h=a;a=lr(n),n=lr(h)}else a=lr(a),n=lr(n);a>n&&(n+=Gn);var f=Math.atan2(s,o);if(f<0&&(f+=Gn),f>=a&&f<=n||f+Gn>=a&&f+Gn<=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 As(r,e,t,a,n,i,o,s){var l=n-r,u=i-e,c=t-r,v=a-e,h=Math.sqrt(c*c+v*v);c/=h,v/=h;var f=l*c+u*v,p=f/h;s&&(p=Math.min(Math.max(p,0),1)),p*=h;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 HS(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 Fe=[];function ED(r,e,t){var a=HS(e.x,e.y,e.width,e.height,r.x,r.y,Fe);return t.set(Fe[0],Fe[1]),a}function kD(r,e,t){for(var a=0,n=0,i=0,o=0,s,l,u=1/0,c=e.data,v=r.x,h=r.y,f=0;f<c.length;){var p=c[f++];f===1&&(a=c[f],n=c[f+1],i=a,o=n);var d=u;switch(p){case qr.M:i=c[f++],o=c[f++],a=i,n=o;break;case qr.L:d=As(a,n,c[f],c[f+1],v,h,Fe,!0),a=c[f++],n=c[f++];break;case qr.C:d=fb(a,n,c[f++],c[f++],c[f++],c[f++],c[f],c[f+1],v,h,Fe),a=c[f++],n=c[f++];break;case qr.Q:d=hb(a,n,c[f++],c[f++],c[f],c[f+1],v,h,Fe),a=c[f++],n=c[f++];break;case qr.A:var g=c[f++],y=c[f++],m=c[f++],S=c[f++],_=c[f++],x=c[f++];f+=1;var b=!!(1-c[f++]);s=Math.cos(_)*m+g,l=Math.sin(_)*S+y,f<=1&&(i=s,o=l);var A=(v-g)*S/m+g;d=RD(g,y,S,_,_+x,b,A,h,Fe),a=Math.cos(_+x)*m+g,n=Math.sin(_+x)*S+y;break;case qr.R:i=a=c[f++],o=n=c[f++];var T=c[f++],D=c[f++];d=HS(i,o,T,D,v,h,Fe);break;case qr.Z:d=As(a,n,i,o,v,h,Fe,!0),a=i,n=o;break}d<u&&(u=d,t.set(Fe[0],Fe[1]))}return u}var He=new Ft,Tt=new Ft,Bt=new Ft,Qe=new Ft,Ke=new Ft;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||LD,s=a.getBoundingRect().clone();s.applyTransform(a.getComputedTransform());var l=1/0,u=n.anchor,c=r.getComputedTransform(),v=c&&Wi([],c),h=e.get("length2")||0;u&&Bt.copy(u);for(var f=0;f<o.length;f++){var p=o[f];PD(p,0,s,He,Qe),Ft.scaleAndAdd(Tt,He,Qe,h),Tt.transform(v);var d=r.getBoundingRect(),g=u?u.distance(Tt):r instanceof Mt?kD(Tt,r.path,Bt):ED(Tt,d,Bt);g<l&&(l=g,Tt.transform(c),Bt.transform(c),Bt.toArray(i[0]),Tt.toArray(i[1]),He.toArray(i[2]))}WS(i,e.get("minTurnAngle")),t.setShape({points:i})}}}var Ts=[],ve=new Ft;function WS(r,e){if(e<=180&&e>0){e=e/180*Math.PI,He.fromArray(r[0]),Tt.fromArray(r[1]),Bt.fromArray(r[2]),Ft.sub(Qe,He,Tt),Ft.sub(Ke,Bt,Tt);var t=Qe.len(),a=Ke.len();if(!(t<.001||a<.001)){Qe.scale(1/t),Ke.scale(1/a);var n=Qe.dot(Ke),i=Math.cos(e);if(i<n){var o=As(Tt.x,Tt.y,Bt.x,Bt.y,He.x,He.y,Ts,!1);ve.fromArray(Ts),ve.scaleAndAdd(Ke,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?Ft.copy(ve,Tt):s>1&&Ft.copy(ve,Bt),ve.toArray(r[1])}}}}function ND(r,e,t){if(t<=180&&t>0){t=t/180*Math.PI,He.fromArray(r[0]),Tt.fromArray(r[1]),Bt.fromArray(r[2]),Ft.sub(Qe,Tt,He),Ft.sub(Ke,Bt,Tt);var a=Qe.len(),n=Ke.len();if(!(a<.001||n<.001)){Qe.scale(1/a),Ke.scale(1/n);var i=Qe.dot(e),o=Math.cos(t);if(i<o){var s=As(Tt.x,Tt.y,Bt.x,Bt.y,He.x,He.y,Ts,!1);ve.fromArray(Ts);var l=Math.PI/2,u=Math.acos(Ke.dot(e)),c=l+u-t;if(c>=l)Ft.copy(ve,Bt);else{ve.scaleAndAdd(Ke,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?Ft.copy(ve,Tt):v>1&&Ft.copy(ve,Bt)}ve.toArray(r[1])}}}}function Fl(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 OD(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=sa(a[0],a[1]),i=sa(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 Zv(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<Ai.length;l++){var u=Ai[l],c=e[u],v=u==="normal";if(c){var h=c.get("show"),f=v?s:pt(n.states[u]&&n.states[u].ignore,s);if(f||!pt(h,o)){var p=v?a:a&&a.states[u];p&&(p.ignore=!0),a&&Fl(a,!0,u,c);continue}a||(a=new xe,r.setTextGuideLine(a),!v&&(s||!o)&&Fl(a,!0,"normal",e.normal),r.stateProxy&&(a.stateProxy=r.stateProxy)),Fl(a,!1,u,c)}}if(a){Q(a.style,t),a.style.fill=null;var d=i.get("showAbove"),g=r.textGuideLineConfig=r.textGuideLineConfig||{};g.showAbove=d||!1,a.buildPath=OD}}function $v(r,e){e=e||"labelLine";for(var t={normal:r.getModel(e)},a=0;a<de.length;a++){var n=de[a];t[n]=r.getModel([n,e])}return t}function US(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 us(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 YS(r,e,t,a,n,i){var o=r.length;if(o<2)return;r.sort(function(b,A){return b.rect[e]-A.rect[e]});for(var s=0,l,u=!1,c=0;c<o;c++){var v=r[c],h=v.rect;l=h[e]-s,l<0&&(h[e]-=l,v.label[e]-=l,u=!0),s=h[e]+h[t]}var f=r[0],p=r[o-1],d,g;y(),d<0&&_(-d,.8),g<0&&_(g,.8),y(),m(d,g,1),m(g,d,-1),y(),d<0&&x(-d),g<0&&x(g);function y(){d=f.rect[e]-a,g=n-p.rect[e]-p.rect[t]}function m(b,A,T){if(b<0){var D=Math.min(A,-b);if(D>0){S(D*T,0,o);var C=D+b;C<0&&_(-C*T,1)}else _(-b*T,1)}}function S(b,A,T){b!==0&&(u=!0);for(var D=A;D<T;D++){var C=r[D],M=C.rect;M[e]+=b,C.label[e]+=b}}function _(b,A){for(var T=[],D=0,C=1;C<o;C++){var M=r[C-1].rect,I=Math.max(r[C].rect[e]-M[e]-M[t],0);T.push(I),D+=I}if(D){var L=Math.min(Math.abs(b)/D,A);if(b>0)for(var C=0;C<o-1;C++){var R=T[C]*L;S(R,0,C+1)}else for(var C=o-1;C>0;C--){var R=T[C-1]*L;S(-R,C,o)}}}function x(b){var A=b<0?-1:1;b=Math.abs(b);for(var T=Math.ceil(b/(o-1)),D=0;D<o-1;D++)if(A>0?S(T,0,D+1):S(-T,o-D-1,o),b-=T,b<=0)return}return u}function VD(r,e,t,a){return YS(r,"x","width",e,t)}function ZS(r,e,t,a){return YS(r,"y","height",e,t)}function $S(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,h=!1,f=0;f<e.length;f++){var p=e[f];if(t.intersect(p.rect)){if(o&&p.axisAligned){h=!0;break}if(p.obb||(p.obb=new us(p.localRect,p.transform)),v||(v=new us(s,l)),v.intersect(p.obb)){h=!0;break}}}h?(a(u),c&&a(c)):(u.attr("ignore",i.defaultAttr.ignore),c&&c.attr("ignore",i.defaultAttr.labelGuideIgnore),e.push(i))}}var BD=Math.PI/180;function Ap(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],_=Math.abs(S.label.y-t),x=a+S.len,b=x*x,A=Math.sqrt(Math.abs((1-_*_/y)*b)),T=e+(A+S.len2)*n,D=T-S.label.x,C=S.targetTextWidth-D*n;XS(S,C,!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],_=S.label.y>t?y:g,x=Math.abs(S.label.y-t);if(x>=_.maxY){var b=S.label.x-e-S.len2*n,A=a+S.len,T=Math.abs(b)<A?Math.sqrt(x*x/(1-b*b/A/A)):A;_.rB=T,_.maxY=x}_.list.push(S)}c(g),c(y)}for(var h=r.length,f=0;f<h;f++)if(r[f].position==="outer"&&r[f].labelAlignTo==="labelLine"){var p=r[f].label.x-u;r[f].linePoints[1][0]+=p,r[f].label.x=u}ZS(r,l,l+o)&&v(r)}function zD(r,e,t,a,n,i,o,s){for(var l=[],u=[],c=Number.MAX_VALUE,v=-Number.MAX_VALUE,h=0;h<r.length;h++){var f=r[h].label;Hl(r[h])||(f.x<e?(c=Math.min(c,f.x),l.push(r[h])):(v=Math.max(v,f.x),u.push(r[h])))}for(var h=0;h<r.length;h++){var p=r[h];if(!Hl(p)&&p.linePoints){if(p.labelStyleWidth!=null)continue;var f=p.label,d=p.linePoints,g=void 0;p.labelAlignTo==="edge"?f.x<e?g=d[2][0]-p.labelDistance-o-p.edgeDistance:g=o+n-p.edgeDistance-d[2][0]-p.labelDistance:p.labelAlignTo==="labelLine"?f.x<e?g=c-o-p.bleedMargin:g=o+n-v-p.bleedMargin:f.x<e?g=f.x-o-p.bleedMargin:g=o+n-f.x-p.bleedMargin,p.targetTextWidth=g,XS(p,g)}}Ap(u,e,t,a,1,n,i,o,s,v),Ap(l,e,t,a,-1,n,i,o,s,c);for(var h=0;h<r.length;h++){var p=r[h];if(!Hl(p)&&p.linePoints){var f=p.label,d=p.linePoints,y=p.labelAlignTo==="edge",m=f.style.padding,S=m?m[1]+m[3]:0,_=f.style.backgroundColor?0:S,x=p.rect.width+_,b=d[1][0]-d[2][0];y?f.x<e?d[2][0]=o+p.edgeDistance+x+p.labelDistance:d[2][0]=o+n-p.edgeDistance-x-p.labelDistance:(f.x<e?d[2][0]=f.x+p.labelDistance:d[2][0]=f.x-p.labelDistance,d[1][0]=d[2][0]+b),d[1][1]=d[2][1]=f.y}}}function XS(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 h=a.getBoundingRect();a.setStyle("width",Math.ceil(h.width)),a.setStyle("backgroundColor",o)}else{var f=e-l,p=e<c?f:t?f>r.unconstrainedWidth?null:f: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 Hl(r){return r.position==="center"}function GD(r){var e=r.getData(),t=[],a,n,i=!1,o=(r.get("minShowLabelAngle")||0)*BD,s=e.getLayout("viewRect"),l=e.getLayout("r"),u=s.width,c=s.x,v=s.y,h=s.height;function f(b){b.ignore=!0}function p(b){if(!b.ignore)return!0;for(var A in b.states)if(b.states[A].ignore===!1)return!0;return!1}e.each(function(b){var A=e.getItemGraphicEl(b),T=A.shape,D=A.getTextContent(),C=A.getTextGuideLine(),M=e.getItemModel(b),I=M.getModel("label"),L=I.get("position")||M.get(["emphasis","label","position"]),R=I.get("distanceToLabelLine"),P=I.get("alignTo"),k=H(I.get("edgeDistance"),u),O=I.get("bleedMargin"),N=M.getModel("labelLine"),V=N.get("length");V=H(V,u);var F=N.get("length2");if(F=H(F,u),Math.abs(T.endAngle-T.startAngle)<o){w(D.states,f),D.ignore=!0,C&&(w(C.states,f),C.ignore=!0);return}if(p(D)){var W=(T.startAngle+T.endAngle)/2,X=Math.cos(W),rt=Math.sin(W),at,st,Vt,me;a=T.cx,n=T.cy;var ht=L==="inside"||L==="inner";if(L==="center")at=T.cx,st=T.cy,me="center";else{var ot=(ht?(T.r+T.r0)/2*X:T.r*X)+a,It=(ht?(T.r+T.r0)/2*rt:T.r*rt)+n;if(at=ot+X*3,st=It+rt*3,!ht){var At=ot+X*(V+l-T.r),Et=It+rt*(V+l-T.r),$t=At+(X<0?-1:1)*F,Xt=Et;P==="edge"?at=X<0?c+k:c+u-k:at=$t+(X<0?-R:R),st=Xt,Vt=[[ot,It],[At,Et],[$t,Xt]]}me=ht?"center":P==="edge"?X>0?"right":"left":X>0?"left":"right"}var Lt=Math.PI,zt=0,le=I.get("rotate");if(St(le))zt=le*(Lt/180);else if(L==="center")zt=0;else if(le==="radial"||le===!0){var xr=X<0?-W+Lt:-W;zt=xr}else if(le==="tangential"&&L!=="outside"&&L!=="outer"){var ir=Math.atan2(X,rt);ir<0&&(ir=Lt*2+ir);var co=rt>0;co&&(ir=Lt+ir),zt=ir-Lt}if(i=!!zt,D.x=at,D.y=st,D.rotation=zt,D.setStyle({verticalAlign:"middle"}),ht){D.setStyle({align:me});var Sl=D.states.select;Sl&&(Sl.x+=D.x,Sl.y+=D.y)}else{var kn=D.getBoundingRect().clone();kn.applyTransform(D.getComputedTransform());var rf=(D.style.margin||0)+2.1;kn.y-=rf/2,kn.height+=rf,t.push({label:D,labelLine:C,position:L,len:V,len2:F,minTurnAngle:N.get("minTurnAngle"),maxSurfaceAngle:N.get("maxSurfaceAngle"),surfaceNormal:new Ft(X,rt),linePoints:Vt,textAlign:me,labelDistance:R,labelAlignTo:P,edgeDistance:k,bleedMargin:O,rect:kn,unconstrainedWidth:kn.width,labelStyleWidth:D.style.width})}A.setTextConfig({inside:ht})}}),!i&&r.get("avoidLabelOverlap")&&zD(t,a,n,l,u,h,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,f),y.ignore=!0);var _=y.states.select;_&&(_.x+=y.x,_.y+=y.y)}if(m){var x=g.linePoints;S||!x?(w(m.states,f),m.ignore=!0):(WS(x,g.minTurnAngle),ND(x,g.surfaceNormal,g.maxSurfaceAngle),m.setShape({points:x}),y.__hostTarget.textGuideLineConfig={anchor:new Ft(x[0][0],x[0][1])})}}}var FD=(function(r){E(e,r);function e(t,a,n){var i=r.call(this)||this;i.z2=2;var o=new vt;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=z(ca(l.getModel("itemStyle"),c,!0),c);if(isNaN(v.startAngle)){o.setShape(v);return}if(i){o.setShape(v);var h=s.getShallow("animationType");s.ecModel.ssr?(Pt(o,{scaleX:0,scaleY:0},s,{dataIndex:a,isFrom:!0}),o.originX=v.cx,o.originY=v.cy):h==="scale"?(o.shape.r=c.r0,Pt(o,{shape:{r:c.r}},s,a)):n!=null?(o.setShape({startAngle:n,endAngle:n}),Pt(o,{shape:{startAngle:c.startAngle,endAngle:c.endAngle}},s,a)):(o.shape.endAngle=c.startAngle,ft(o,{shape:{endAngle:c.endAngle}},s,a))}else Ue(o),ft(o,{shape:v},s,a);o.useStyle(t.getItemVisual(a,"style")),re(o,l);var f=(c.startAngle+c.endAngle)/2,p=s.get("selectedOffset"),d=Math.cos(f)*p,g=Math.sin(f)*p,y=l.getShallow("cursor");y&&o.attr("cursor",y),this._updateLabel(s,t,a),o.ensureState("emphasis").shape=z({r:c.r+(u.get("scale")&&u.get("scaleSize")||0)},ca(u.getModel("itemStyle"),c)),z(o.ensureState("select"),{x:d,y:g,shape:ca(l.getModel(["select","itemStyle"]),c)}),z(o.ensureState("blur"),{shape:ca(l.getModel(["blur","itemStyle"]),c)});var m=o.getTextGuideLine(),S=o.getTextContent();m&&z(m.ensureState("select"),{x:d,y:g}),z(S.ensureState("select"),{x:d,y:g}),kt(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,qt(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 h=t.get(["label","position"]);if(h!=="outside"&&h!=="outer")i.removeTextGuideLine();else{var f=this.getTextGuideLine();f||(f=new xe,this.setTextGuideLine(f)),Zv(this,$v(o),{stroke:u,opacity:mn(s.get(["lineStyle","opacity"]),c,1)})}},e})(Ee),HD=(function(r){E(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 h=FS(t),f=new Ee({shape:z(GS(t,n),h)});f.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=f,l.add(f)}o.diff(s).add(function(p){var d=new FD(o,p,u);o.setItemGraphicEl(p,d),l.add(d)}).update(function(p,d){var g=s.getItemGraphicEl(d);g.updateData(o,p,u),g.off("click"),l.add(g),o.setItemGraphicEl(p,g)}).remove(function(p){var d=s.getItemGraphicEl(p);Di(d,t,p)}).execute(),GD(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})(bt);function Rn(r,e,t){e=B(e)&&{coordDimensions:e}||z({encodeDefine:r.getEncode()},e);var a=r.getSource(),n=ji(a,e).dimensions,i=new he(n,r);return i.initData(a,t),i}var no=(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})(),WD=ut(),UD=(function(r){E(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 no(U(this.getData,this),U(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Rn(this,{coordDimensions:["value"],encodeDefaulter:tt(Pv,this)})},e.prototype.getDataParams=function(t){var a=this.getData(),n=WD(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){xa(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,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e})(Ct);function YD(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!(St(o)&&!isNaN(o)&&o<0)})}}}function ZD(r){r.registerChartView(HD),r.registerSeriesModel(UD),BS("pie",r.registerAction),r.registerLayout(tt(ID,"pie")),r.registerProcessor(ao("pie")),r.registerProcessor(YD("pie"))}var KS="";typeof navigator<"u"&&(KS=navigator.platform||"");var Ga="rgba(0, 0, 0, 0.2)";const $D={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Ga,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Ga,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Ga,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Ga,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Ga,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Ga,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:KS.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 Cc=$();function XD(r,e){Se(Cc.get(r)==null&&e),Cc.set(r,e)}function KD(r,e,t){var a=Cc.get(e);if(!a)return t;var n=a(r);return n?t.concat(n):t}var _o,Fn,Tp,Dp="\0_ec_inner",qD=1,Xv=(function(r){E(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 mt(i),this._locale=new mt(o),this._optionManager=s},e.prototype.setOption=function(t,a,n){var i=Ip(a);this._optionManager.setOption(t,n,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,a){return this._resetOption(t,Ip(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"?Tp(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=$(),u=a&&a.replaceMergeMainTypeMap;rA(this),w(t,function(v,h){v!=null&&(lt.hasClass(h)?h&&(s.push(h),l.set(h,!0)):n[h]=n[h]==null?j(v):nt(n[h],v,!0))}),u&&u.each(function(v,h){lt.hasClass(h)&&!l.get(h)&&(s.push(h),l.set(h,!0))}),lt.topologicalTravel(s,lt.getAllClassMainTypes(),c,this);function c(v){var h=KD(this,v,xt(t[v])),f=i.get(v),p=f?u&&u.get(v)?"replaceMerge":"normalMerge":"replaceAll",d=Jm(f,h,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){var b=_.existing,A=_.newOption;if(!A)b&&(b.mergeOption({},this),b.optionUpdated({},!1));else{var T=v==="series",D=lt.getClass(v,_.keyInfo.subType,!T);if(!D)return;if(v==="tooltip"){if(S)return;S=!0}if(b&&b.constructor===D)b.name=_.keyInfo.name,b.mergeOption(A,this),b.optionUpdated(A,!1);else{var C=z({componentIndex:x},_.keyInfo);b=new D(A,this,this,C),z(b,C),_.brandNew&&(b.__requireNewView=!0),b.init(A,this,this),b.optionUpdated(null,!0)}}b?(g.push(b.option),y.push(b),m++):(g.push(void 0),y.push(void 0))},this),n[v]=g,i.set(v,y),o.set(v,m),v==="series"&&_o(this)}this._seriesIndices||_o(this)},e.prototype.getOption=function(){var t=j(this.option);return w(t,function(a,n){if(lt.hasClass(n)){for(var i=xt(a),o=i.length,s=!1,l=o-1;l>=0;l--)i[l]&&!wi(i[l])?s=!0:(i[l]=null,!s&&o--);i.length=o,t[n]=i}}),delete t[Dp],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(xt(n),function(u){s[u]&&l.push(s[u])})):i!=null?l=Cp("id",i,s):o!=null?l=Cp("name",o,s):l=_t(s,function(u){return!!u}),Mp(l,t)},e.prototype.findComponents=function(t){var a=t.query,n=t.mainType,i=s(a),o=i?this.queryComponents(i):_t(this._componentsMap.get(n),function(u){return!!u});return l(Mp(o,t));function s(u){var c=n+"Index",v=n+"Id",h=n+"Name";return u&&(u[c]!=null||u[v]!=null||u[h]!=null)?{mainType:n,index:u[c],id:u[v],name:u[h]}:null}function l(u){return t.filter?_t(u,t.filter):u}},e.prototype.eachComponent=function(t,a,n){var i=this._componentsMap;if(K(t)){var o=a,s=t;i.each(function(v,h){for(var f=0;v&&f<v.length;f++){var p=v[f];p&&s.call(o,h,p,p.componentIndex)}})}else for(var l=Y(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=Yt(t,null);return _t(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 _t(this._componentsMap.get("series"),function(a){return!!a&&a.subType===t})},e.prototype.getSeries=function(){return _t(this._componentsMap.get("series"),function(t){return!!t})},e.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},e.prototype.eachSeries=function(t,a){Fn(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){Fn(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 Fn(this),this._seriesIndicesMap.get(t.componentIndex)==null},e.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},e.prototype.filterSeries=function(t,a){Fn(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=$(n)},e.prototype.restoreData=function(t){_o(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"||!jD(o,t))&&o.restoreData()})})},e.internalField=(function(){_o=function(t){var a=t._seriesIndices=[];w(t._componentsMap.get("series"),function(n){n&&a.push(n.componentIndex)}),t._seriesIndicesMap=$(a)},Fn=function(t){},Tp=function(t,a){t.option={},t.option[Dp]=qD,t._componentsMap=$({series:[]}),t._componentsCount=$();var n=a.aria;J(n)&&n.enabled==null&&(n.enabled=!0),JD(a,t._theme.option),nt(a,$D,!1),t._mergeOption(a,null)}})(),e})(mt);function jD(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 JD(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]?nt(r[n],a,!1):j(a):r[n]==null&&(r[n]=a))})}function Cp(r,e,t){if(B(e)){var a=$();return w(e,function(i){if(i!=null){var o=Yt(i,null);o!=null&&a.set(i,!0)}}),_t(t,function(i){return i&&a.get(i[r])})}else{var n=Yt(e,null);return _t(t,function(i){return i&&n!=null&&i[r]===n})}}function Mp(r,e){return e.hasOwnProperty("subType")?_t(r,function(t){return t&&t.subType===e.subType}):r}function Ip(r){var e=$();return r&&w(xt(r.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}Jt(Xv,Hv);var QD=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],qS=(function(){function r(e){w(QD,function(t){this[t]=U(e[t],e)},this)}return r})(),tC=/^(min|max)?(.+)$/,eC=(function(){function r(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return r.prototype.setOption=function(e,t,a){e&&(w(xt(e.series),function(o){o&&o.data&&_e(o.data)&&cs(o.data)}),w(xt(e.dataset),function(o){o&&o.source&&_e(o.source)&&cs(o.source)})),e=j(e);var n=this._optionBackup,i=rC(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=[],j(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=j(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++)aC(n[l].query,t,a)&&o.push(l);return!o.length&&i&&(o=[-1]),o.length&&!iC(o,this._currentMediaIndices)&&(s=G(o,function(c){return j(c===-1?i.option:n[c].option)})),this._currentMediaIndices=o,s},r})();function rC(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&&B(u)&&w(u,function(f){f&&f.option&&(f.query?a.push(f):n||(n=f))}),h(i),w(l,function(f){return h(f)}),w(a,function(f){return h(f.option)});function h(f){w(e,function(p){p(f,t)})}return{baseOption:i,timelineOptions:l||[],mediaDefault:n,mediaList:a}}function aC(r,e,t){var a={width:e,height:t,aspectratio:e/t},n=!0;return w(r,function(i,o){var s=o.match(tC);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();nC(a[u],i,l)||(n=!1)}}),n}function nC(r,e,t){return t==="min"?r>=e:t==="max"?r<=e:r===e}function iC(r,e){return r.join(",")===e.join(",")}var Be=w,Pi=J,Lp=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Wl(r){var e=r&&r.itemStyle;if(e)for(var t=0,a=Lp.length;t<a;t++){var n=Lp[t],i=e.normal,o=e.emphasis;i&&i[n]&&(r[n]=r[n]||{},r[n].normal?nt(r[n].normal,i[n]):r[n].normal=i[n],i[n]=null),o&&o[n]&&(r[n]=r[n]||{},r[n].emphasis?nt(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,Q(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 ni(r){oe(r,"itemStyle"),oe(r,"lineStyle"),oe(r,"areaStyle"),oe(r,"label"),oe(r,"labelLine"),oe(r,"upperLabel"),oe(r,"edgeLabel")}function Gt(r,e){var t=Pi(r)&&r[e],a=Pi(t)&&t.textStyle;if(a)for(var n=0,i=yf.length;n<i;n++){var o=yf[n];a.hasOwnProperty(o)&&(t[o]=a[o])}}function Te(r){r&&(ni(r),Gt(r,"label"),r.emphasis&&Gt(r.emphasis,"label"))}function oC(r){if(Pi(r)){Wl(r),ni(r),Gt(r,"label"),Gt(r,"upperLabel"),Gt(r,"edgeLabel"),r.emphasis&&(Gt(r.emphasis,"label"),Gt(r.emphasis,"upperLabel"),Gt(r.emphasis,"edgeLabel"));var e=r.markPoint;e&&(Wl(e),Te(e));var t=r.markLine;t&&(Wl(t),Te(t));var a=r.markArea;a&&Te(a);var n=r.data;if(r.type==="graph"){n=n||r.nodes;var i=r.links||r.edges;if(i&&!_e(i))for(var o=0;o<i.length;o++)Te(i[o]);w(r.categories,function(u){ni(u)})}if(n&&!_e(n))for(var o=0;o<n.length;o++)Te(n[o]);if(e=r.markPoint,e&&e.data)for(var s=e.data,o=0;o<s.length;o++)Te(s[o]);if(t=r.markLine,t&&t.data)for(var l=t.data,o=0;o<l.length;o++)B(l[o])?(Te(l[o][0]),Te(l[o][1])):Te(l[o]);r.type==="gauge"?(Gt(r,"axisLabel"),Gt(r,"title"),Gt(r,"detail")):r.type==="treemap"?(oe(r.breadcrumb,"itemStyle"),w(r.levels,function(u){ni(u)})):r.type==="tree"&&ni(r.leaves)}}function or(r){return B(r)?r:r?[r]:[]}function Pp(r){return(B(r)?r[0]:r)||{}}function sC(r,e){Be(or(r.series),function(a){Pi(a)&&oC(a)});var t=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&t.push("valueAxis","categoryAxis","logAxis","timeAxis"),Be(t,function(a){Be(or(r[a]),function(n){n&&(Gt(n,"axisLabel"),Gt(n.axisPointer,"label"))})}),Be(or(r.parallel),function(a){var n=a&&a.parallelAxisDefault;Gt(n,"axisLabel"),Gt(n&&n.axisPointer,"label")}),Be(or(r.calendar),function(a){oe(a,"itemStyle"),Gt(a,"dayLabel"),Gt(a,"monthLabel"),Gt(a,"yearLabel")}),Be(or(r.radar),function(a){Gt(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)}),Be(or(r.geo),function(a){Pi(a)&&(Te(a),Be(or(a.regions),function(n){Te(n)}))}),Be(or(r.timeline),function(a){Te(a),oe(a,"label"),oe(a,"itemStyle"),oe(a,"controlStyle",!0);var n=a.data;B(n)&&w(n,function(i){J(i)&&(oe(i,"label"),oe(i,"itemStyle"))})}),Be(or(r.toolbox),function(a){oe(a,"iconStyle"),Be(a.feature,function(n){oe(n,"iconStyle")})}),Gt(Pp(r.axisPointer),"label"),Gt(Pp(r.tooltip).axisPointer,"label")}function lC(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 uC(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];i[n[s]]==null&&(i[n[s]]=t)}function Rp(r){r&&w(cC,function(e){e[0]in r&&!(e[1]in r)&&(r[e[1]]=r[e[0]])})}var cC=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],vC=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Ul=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function Hn(r){var e=r&&r.itemStyle;if(e)for(var t=0;t<Ul.length;t++){var a=Ul[t][1],n=Ul[t][0];e[a]!=null&&(e[n]=e[a])}}function Ep(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function kp(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function hC(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function jS(r,e){if(r)for(var t=0;t<r.length;t++)e(r[t]),r[t]&&jS(r[t].children,e)}function JS(r,e){sC(r,e),r.series=xt(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),Ep(t.label);var n=t.data;if(n&&!_e(n))for(var i=0;i<n.length;i++)Ep(n[i]);t.hoverOffset!=null&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if(a==="gauge"){var o=lC(t,"pointer.color");o!=null&&uC(t,"itemStyle.color",o)}else if(a==="bar"){Hn(t),Hn(t.backgroundStyle),Hn(t.emphasis);var n=t.data;if(n&&!_e(n))for(var i=0;i<n.length;i++)typeof n[i]=="object"&&(Hn(n[i]),Hn(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)),kp(t),jS(t.data,kp)}else a==="graph"||a==="sankey"?hC(t):a==="map"&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&Q(t,t.mapLocation));t.hoverAnimation!=null&&(t.emphasis=t.emphasis||{},t.emphasis&&t.emphasis.scale==null&&(t.emphasis.scale=t.hoverAnimation)),Rp(t)}}),r.dataRange&&(r.visualMap=r.dataRange),w(vC,function(t){var a=r[t];a&&(B(a)||(a=[a]),w(a,function(n){Rp(n)}))})}function fC(r){var e=$();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(pC)}function pC(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 h=o.get(e.stackedDimension,v);if(isNaN(h))return n;var f,p;s?p=o.getRawIndex(v):f=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,f)),p>=0){var m=y.data.getByRawIndex(y.stackResultDimension,p);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&h>=0&&m>0||l==="samesign"&&h<=0&&m<0){h=iw(h,m),d=m;break}}}return a[0]=h,a[1]=d,a})})}var Rt=(function(){function r(){this.group=new et,this.uid=Dn("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})();Sv(Rt);Zs(Rt);var Np=ut(),Op={itemStyle:_a(x0,!0),lineStyle:_a(_0,!0)},dC={lineStyle:"stroke",itemStyle:"fill"};function QS(r,e){var t=r.visualStyleMapper||Op[e];return t||(console.warn("Unknown style type '"+e+"'."),Op.itemStyle)}function t_(r,e){var t=r.visualDrawType||dC[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var gC={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=r.getModel(a),i=QS(r,a),o=i(n),s=n.getShallow("decal");s&&(t.setVisual("decal",s),s.dirty=!0);var l=t_(r,a),u=o[l],c=K(u)?u:null,v=o.fill==="auto"||o.stroke==="auto";if(!o[l]||c||v){var h=r.getColorFromPalette(r.name,null,e.getSeriesCount());o[l]||(o[l]=h,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||K(o.fill)?h:o.fill,o.stroke=o.stroke==="auto"||K(o.stroke)?h:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",l),!e.isSeriesFiltered(r)&&c)return t.setVisual("colorFromPalette",!1),{dataEach:function(f,p){var d=r.getDataParams(p),g=z({},o);g[l]=c(d),f.setItemVisual(p,"style",g)}}}},Wn=new mt,yC={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,e){if(!(r.ignoreStyleOnData||e.isSeriesFiltered(r))){var t=r.getData(),a=r.visualStyleAccessPath||"itemStyle",n=QS(r,a),i=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[a]){Wn.option=l[a];var u=n(Wn),c=o.ensureUniqueItemVisual(s,"style");z(c,u),Wn.option.decal&&(o.setItemVisual(s,"decal",Wn.option.decal),Wn.option.decal.dirty=!0),i in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},mC={performRawSeries:!0,overallReset:function(r){var e=$();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)),Np(t).scope=i}}),r.eachSeries(function(t){if(!(t.isColorBySeries()||r.isSeriesFiltered(t))){var a=t.getRawData(),n={},i=t.getData(),o=Np(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=t_(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 h=i.ensureUniqueItemVisual(c,"style"),f=a.getName(u)||u+"",p=a.count();h[l]=t.getColorFromPalette(f,o,p)}})}})}},xo=Math.PI;function SC(r,e){e=e||{},Q(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 et,a=new dt({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(a);var n=new vt({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 dt({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 yv({shape:{startAngle:-xo/2,endAngle:-xo/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:xo*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:xo*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 e_=(function(){function r(e,t,a,n){this._stageTaskMap=$(),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=$();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="";Se(!(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,h=c.overallTask;if(h){var f,p=h.agentStubMap;p.each(function(g){s(n,g)&&(g.dirty(),f=!0)}),f&&h.dirty(),o.updatePayload(h,a);var d=o.getPerformArgs(h,n.block);p.each(function(g){g.perform(d)}),h.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=$(),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 h=v.uid,f=s.set(h,o&&o.get(h)||di({plan:AC,reset:TC,count:CC}));f.context={model:v,ecModel:a,api:n,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(v,f)}},r.prototype._createOverallStageTask=function(e,t,a,n){var i=this,o=t.overallTask=t.overallTask||di({reset:_C});o.context={ecModel:a,api:n,overallReset:e.overallReset,scheduler:i};var s=o.agentStubMap,l=o.agentStubMap=$(),u=e.seriesType,c=e.getTargetSeries,v=!0,h=!1,f="";Se(!e.createOnAllSeries,f),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)||(h=!0,di({reset:xC,onDirty:wC})));y.context={model:d,overallProgress:v},y.agent=o,y.__block=v,i._pipe(d,y)}h&&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 K(e)&&(e={overallReset:e,seriesType:MC(e)}),e.uid=Dn("stageHandler"),t&&(e.visualType=t),e},r})();function _C(r){r.overallReset(r.ecModel,r.api,r.payload)}function xC(r){return r.overallProgress&&bC}function bC(){this.agent.dirty(),this.getDownstream().dirty()}function wC(){this.agent&&this.agent.dirty()}function AC(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function TC(r){r.useClearVisual&&r.data.clearAllVisual();var e=r.resetDefines=xt(r.reset(r.model,r.ecModel,r.api,r.payload));return e.length>1?G(e,function(t,a){return r_(a)}):DC}var DC=r_(0);function r_(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 CC(r){return r.data.count()}function MC(r){Ds=null;try{r(Ri,a_)}catch{}return Ds}var Ri={},a_={},Ds;n_(Ri,Xv);n_(a_,qS);Ri.eachSeriesByType=Ri.eachRawSeriesByType=function(r){Ds=r};Ri.eachComponent=function(r){r.mainType==="series"&&r.subType&&(Ds=r.subType)};function n_(r,e){for(var t in e.prototype)r[t]=pe}var Vp=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"];const IC={color:Vp,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],Vp]};var ie="#B9B8CE",Bp="#100C2A",bo=function(){return{axisLine:{lineStyle:{color:ie}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}},zp=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],i_={darkMode:!0,color:zp,backgroundColor:Bp,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:ie},pageTextStyle:{color:ie}},textStyle:{color:ie},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:ie}},dataZoom:{borderColor:"#71708A",textStyle:{color:ie},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:ie}},timeline:{lineStyle:{color:ie},label:{color:ie},controlStyle:{color:ie,borderColor:ie}},calendar:{itemStyle:{color:Bp},dayLabel:{color:ie},monthLabel:{color:ie},yearLabel:{color:ie}},timeAxis:bo(),logAxis:bo(),valueAxis:bo(),categoryAxis:bo(),line:{symbol:"circle"},graph:{color:zp},gauge:{title:{color:ie},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:ie},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};i_.categoryAxis.splitLine.show=!1;var LC=(function(){function r(){}return r.prototype.normalizeQuery=function(e){var t={},a={},n={};if(Y(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 h=o[v],f=u.lastIndexOf(h);if(f>0&&f===u.length-h.length){var p=u.slice(0,f);p!=="data"&&(t.mainType=p,t[h.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,h,f,p){return v[f]==null||h[p||f]===v[f]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),Mc=["symbol","symbolSize","symbolRotate","symbolOffset"],Gp=Mc.concat(["symbolKeepAspect"]),PC={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<Mc.length;o++){var s=Mc[o],l=r.get(s);K(l)?(i=!0,n[s]=l):a[s]=l}if(a.symbol=a.symbol||r.defaultSymbol,t.setVisual(z({legendIcon:r.legendIcon||a.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},a)),e.isSeriesFiltered(r))return;var u=Ut(n);function c(v,h){for(var f=r.getRawValue(h),p=r.getDataParams(h),d=0;d<u.length;d++){var g=u[d];v.setItemVisual(h,g,n[g](f,p))}}return{dataEach:i?c:null}}},RC={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<Gp.length;s++){var l=Gp[s],u=o.getShallow(l,!0);u!=null&&n.setItemVisual(i,l,u)}}return{dataEach:t.hasItemOption?a:null}}};function Kv(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 io(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 o_(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 va(r,e,t){for(var a;r&&!(e(r)&&(a=r,t));)r=r.__hostTarget||r.parent;return a}var Yl=new pb,Fp=new db(100),Hp=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function vn(r,e){if(r==="none")return null;var t=e.getDevicePixelRatio(),a=e.getZr(),n=a.painter.type==="svg";r.dirty&&Yl.delete(r);var i=Yl.get(r);if(i)return i;var o=Q(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,Yl.set(r,s),r.dirty=!1,s;function l(u){for(var c=[t],v=!0,h=0;h<Hp.length;++h){var f=o[Hp[h]];if(f!=null&&!B(f)&&!Y(f)&&!St(f)&&typeof f!="boolean"){v=!1;break}c.push(f)}var p;if(v){p=c.join(",")+(n?"-svg":"");var d=Fp.get(p);d&&(n?u.svgElement=d:u.image=d)}var g=l_(o.dashArrayX),y=EC(o.dashArrayY),m=s_(o.symbol),S=kC(g),_=u_(y),x=!n&&vs.createCanvas(),b=n&&{tag:"g",attrs:{},key:"dcl",children:[]},A=D(),T;x&&(x.width=A.width*t,x.height=A.height*t,T=x.getContext("2d")),C(),v&&Fp.put(p,x||b),u.image=x,u.svgElement=b,u.svgWidth=A.width,u.svgHeight=A.height;function D(){for(var M=1,I=0,L=S.length;I<L;++I)M=df(M,S[I]);for(var R=1,I=0,L=m.length;I<L;++I)R=df(R,m[I].length);M*=R;var P=_*S.length*m.length;return{width:Math.max(1,Math.min(M,o.maxTileWidth)),height:Math.max(1,Math.min(P,o.maxTileHeight))}}function C(){T&&(T.clearRect(0,0,x.width,x.height),o.backgroundColor&&(T.fillStyle=o.backgroundColor,T.fillRect(0,0,x.width,x.height)));for(var M=0,I=0;I<y.length;++I)M+=y[I];if(M<=0)return;for(var L=-_,R=0,P=0,k=0;L<A.height;){if(R%2===0){for(var O=P/2%m.length,N=0,V=0,F=0;N<A.width*2;){for(var W=0,I=0;I<g[k].length;++I)W+=g[k][I];if(W<=0)break;if(V%2===0){var X=(1-o.symbolSize)*.5,rt=N+g[k][V]*X,at=L+y[R]*X,st=g[k][V]*o.symbolSize,Vt=y[R]*o.symbolSize,me=F/2%m[O].length;ht(rt,at,st,Vt,m[O][me])}N+=g[k][V],++F,++V,V===g[k].length&&(V=0)}++k,k===g.length&&(k=0)}L+=y[R],++P,++R,R===y.length&&(R=0)}function ht(ot,It,At,Et,$t){var Xt=n?1:t,Lt=Wt($t,ot*Xt,It*Xt,At*Xt,Et*Xt,o.color,o.symbolKeepAspect);if(n){var zt=a.painter.renderOneToVNode(Lt);zt&&b.children.push(zt)}else gb(T,Lt)}}}}function s_(r){if(!r||r.length===0)return[["rect"]];if(Y(r))return[[r]];for(var e=!0,t=0;t<r.length;++t)if(!Y(r[t])){e=!1;break}if(e)return s_([r]);for(var a=[],t=0;t<r.length;++t)Y(r[t])?a.push([r[t]]):a.push(r[t]);return a}function l_(r){if(!r||r.length===0)return[[0,0]];if(St(r)){var e=Math.ceil(r);return[[e,e]]}for(var t=!0,a=0;a<r.length;++a)if(!St(r[a])){t=!1;break}if(t)return l_([r]);for(var n=[],a=0;a<r.length;++a)if(St(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 EC(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(St(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 kC(r){return G(r,function(e){return u_(e)})}function u_(r){for(var e=0,t=0;t<r.length;++t)e+=r[t];return r.length%2===1?e*2:e}function NC(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=vn(s,e)}});var n=a.getVisual("decal");if(n){var i=a.getVisual("style");i.decal=vn(n,e)}}})}var Ge=new Sn,c_={};function OC(r,e){c_[r]=e}function VC(r){return c_[r]}var BC=1,zC=800,GC=900,FC=1e3,HC=2e3,WC=5e3,v_=1e3,UC=1100,qv=2e3,h_=3e3,YC=4e3,sl=4500,ZC=4600,$C=5e3,XC=6e3,f_=7e3,KC={PROCESSOR:{FILTER:FC,SERIES_FILTER:zC,STATISTIC:WC},VISUAL:{LAYOUT:v_,PROGRESSIVE_LAYOUT:UC,GLOBAL:qv,CHART:h_,POST_CHART_LAYOUT:ZC,COMPONENT:YC,BRUSH:$C,CHART_ITEM:sl,ARIA:XC,DECAL:f_}},ne="__flagInMainProcess",ge="__pendingUpdate",Zl="__needsUpdateStatus",Wp=/^[a-zA-Z0-9_]+$/,$l="__connectUpdateStatus",Up=0,qC=1,jC=2;function p_(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(this.isDisposed()){this.id;return}return g_(this,r,e)}}function d_(r){return function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return g_(this,r,e)}}function g_(r,e,t){return t[0]=t[0]&&t[0].toLowerCase(),Sn.prototype[e].apply(r,t)}var y_=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(Sn),m_=y_.prototype;m_.on=d_("on");m_.off=d_("off");var Fa,Xl,wo,Mr,Kl,ql,jl,Un,Yn,Yp,Zp,Jl,$p,Ao,Xp,S_,be,Kp,__=(function(r){E(e,r);function e(t,a,n){var i=r.call(this,new LC)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],n=n||{},Y(a)&&(a=x_[a]),i._dom=t;var o="canvas",s="auto",l=!1;n.ssr&&yb(function(h){var f=q(h),p=f.dataIndex;if(p!=null){var d=$();return d.set("series_index",f.seriesIndex),d.set("data_index",p),f.ssrType&&d.set("ssr_type",f.ssrType),d}});var u=i._zr=sf(t,{renderer:n.renderer||o,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:pt(n.useDirtyRect,l),useCoarsePointer:pt(n.useCoarsePointer,s),pointerSize:n.pointerSize});i._ssr=n.ssr,i._throttledZrFlush=Yv(U(u.flush,u),17),a=j(a),a&&JS(a,!0),i._theme=a,i._locale=WA(n.locale||Y0),i._coordSysMgr=new Ji;var c=i._api=Xp(i);function v(h,f){return h.__prio-f.__prio}return xl(Ms,v),xl(Ic,v),i._scheduler=new e_(i,c,Ic,Ms),i._messageCenter=new y_,i._initEvents(),i.resize=U(i.resize,i),u.animation.on("frame",i._onframe,i),Yp(u,i),Zp(u,i),cs(i),i}return e.prototype._onframe=function(){if(!this._disposed){Kp(this);var t=this._scheduler;if(this[ge]){var a=this[ge].silent;this[ne]=!0;try{Fa(this),Mr.update.call(this,null,this[ge].updateParams)}catch(l){throw this[ne]=!1,this[ge]=null,l}this._zr.flush(),this[ne]=!1,this[ge]=null,Un.call(this,a),Yn.call(this,a)}else if(t.unfinished){var n=BC,i=this._model,o=this._api;t.unfinished=!1;do{var s=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),ql(this,i),t.performVisualTasks(i),Ao(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[ne]){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[ne]=!0,!this._model||a){var l=new eC(this._api),u=this._theme,c=this._model=new Xv;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:o},Lc);var v={seriesTransition:s,optionChanged:!0};if(n)this[ge]={silent:i,updateParams:v},this[ne]=!1,this.getZr().wakeUp();else{try{Fa(this),Mr.update.call(this,null,v)}catch(h){throw this[ge]=null,this[ne]=!1,h}this._ssr||this._zr.flush(),this[ge]=null,this[ne]=!1,Un.call(this,i),Yn.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||Nt.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(Nt.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(qp[n]){var l=s,u=s,c=-s,v=-s,h=[],f=t&&t.pixelRatio||this.getDevicePixelRatio();w(yi,function(S,_){if(S.group===n){var x=a?S.getZr().painter.getSvgDom().innerHTML:S.renderToCanvas(j(t)),b=S.getDom().getBoundingClientRect();l=i(b.left,l),u=i(b.top,u),c=o(b.right,c),v=o(b.bottom,v),h.push({dom:x,left:b.left,top:b.top})}}),l*=f,u*=f,c*=f,v*=f;var p=c-l,d=v-u,g=vs.createCanvas(),y=sf(g,{renderer:a?"svg":"canvas"});if(y.resize({width:p,height:d}),a){var m="";return w(h,function(S){var _=S.left-l,x=S.top-u;m+='<g transform="translate('+_+","+x+')">'+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 dt({shape:{x:0,y:0,width:p,height:d},style:{fill:t.connectedBackgroundColor}})),w(h,function(S){var _=new Ne({style:{x:S.left*f-l,y:S.top*f-u,image:S.dom}});y.add(_)}),y.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}else return this.getDataURL(t)},e.prototype.convertToPixel=function(t,a){return Kl(this,"convertToPixel",t,a)},e.prototype.convertFromPixel=function(t,a){return Kl(this,"convertFromPixel",t,a)},e.prototype.containPixel=function(t,a){if(this._disposed){this.id;return}var n=this._model,i,o=vi(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=vi(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?Kv(s,l,a):io(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(JC,function(a){var n=function(i){var o=t.getModel(),s=i.target,l,u=a==="globalout";if(u?l={}:s&&va(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=z({},d.eventData),!0},!0),l){var c=l.componentType,v=l.componentIndex;(c==="markLine"||c==="markPoint"||c==="markArea")&&(c="series",v=l.seriesIndex);var h=c&&v!=null&&o.getComponent(c,v),f=h&&t[h.mainType==="series"?"_chartsMap":"_componentsMap"][h.__viewId];l.event=i,l.type=a,t._$eventProcessor.eventInfo={targetEl:s,packedEvent:l,model:h,view:f},t.trigger(a,l)}};n.zrEventfulCallAtLast=!0,t._zr.on(a,n,t)}),w(gi,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)}),MD(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&&t0(this.getDom(),Jv,"");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 yi[a.id]},e.prototype.resize=function(t){if(!this[ne]){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[ge]&&(i==null&&(i=this[ge].silent),n=!0,this[ge]=null),this[ne]=!0;try{n&&Fa(this),Mr.update.call(this,{type:"resize",animation:z({duration:0},t&&t.animation)})}catch(o){throw this[ne]=!1,o}this[ne]=!1,Un.call(this,i),Yn.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(),!!Pc[t]){var n=Pc[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=z({},t);return a.type=gi[t.type],a},e.prototype.dispatchAction=function(t,a){if(this._disposed){this.id;return}if(J(a)||(a={silent:!!a}),!!Cs[t.type]&&this._model){if(this[ne]){this._pendingActions.push(t);return}var n=a.silent;jl.call(this,t,n);var i=a.flush;i?this._zr.flush():i!==!1&&Nt.browser.weChat&&this._throttledZrFlush(),Un.call(this,n),Yn.call(this,n)}},e.prototype.updateLabelLayout=function(){Ge.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(){Fa=function(v){var h=v._scheduler;h.restorePipelines(v._model),h.prepareStageTasks(),Xl(v,!0),Xl(v,!1),h.plan()},Xl=function(v,h){for(var f=v._model,p=v._scheduler,d=h?v._componentsViews:v._chartsViews,g=h?v._componentsMap:v._chartsMap,y=v._zr,m=v._api,S=0;S<d.length;S++)d[S].__alive=!1;h?f.eachComponent(function(b,A){b!=="series"&&_(A)}):f.eachSeries(_);function _(b){var A=b.__requireNewView;b.__requireNewView=!1;var T="_ec_"+b.id+"_"+b.type,D=!A&&g[T];if(!D){var C=qe(b.type),M=h?Rt.getClass(C.main,C.sub):bt.getClass(C.sub);D=new M,D.init(f,m),g[T]=D,d.push(D),y.add(D.group)}b.__viewId=D.__id=T,D.__alive=!0,D.__model=b,D.group.__ecComponentInfo={mainType:b.mainType,index:b.componentIndex},!h&&p.prepareView(D,b,f,m)}for(var S=0;S<d.length;){var x=d[S];x.__alive?S++:(!h&&x.renderTask.dispose(),y.remove(x.group),x.dispose(f,m),d.splice(S,1),g[x.__id]===x&&delete g[x.__id],x.__id=x.group.__ecComponentInfo=null)}},wo=function(v,h,f,p,d){var g=v._model;if(g.setUpdatePayload(f),!p){w([].concat(v._componentsViews).concat(v._chartsViews),x);return}var y={};y[p+"Id"]=f[p+"Id"],y[p+"Index"]=f[p+"Index"],y[p+"Name"]=f[p+"Name"];var m={mainType:p,query:y};d&&(m.subType=d);var S=f.excludeSeriesId,_;S!=null&&(_=$(),w(xt(S),function(b){var A=Yt(b,null);A!=null&&_.set(A,!0)})),g&&g.eachComponent(m,function(b){var A=_&&_.get(b.id)!=null;if(!A)if(Tf(f))if(b instanceof Ct)f.type===ha&&!f.notBlur&&!b.get(["emphasis","disabled"])&&Lw(b,f,v._api);else{var T=Cv(b.mainType,b.componentIndex,f.name,v._api),D=T.focusSelf,C=T.dispatchers;f.type===ha&&D&&!f.notBlur&&hc(b.mainType,b.componentIndex,v._api),C&&w(C,function(M){f.type===ha?fr(M):pr(M)})}else pc(f)&&b instanceof Ct&&(Ew(b,f,v._api),wf(b),be(v))},v),g&&g.eachComponent(m,function(b){var A=_&&_.get(b.id)!=null;A||x(v[p==="series"?"_chartsMap":"_componentsMap"][b.__viewId])},v);function x(b){b&&b.__alive&&b[h]&&b[h](b.__model,g,v._api,f)}},Mr={prepareAndUpdate:function(v){Fa(this),Mr.update.call(this,v,{optionChanged:v.newOption!=null})},update:function(v,h){var f=this._model,p=this._api,d=this._zr,g=this._coordSysMgr,y=this._scheduler;if(f){f.setUpdatePayload(v),y.restoreData(f,v),y.performSeriesTasks(f),g.create(f,p),y.performDataProcessorTasks(f,v),ql(this,f),g.update(f,p),t(f),y.performVisualTasks(f,v),Jl(this,f,p,v,h);var m=f.get("backgroundColor")||"transparent",S=f.get("darkMode");d.setBackgroundColor(m),S!=null&&S!=="auto"&&d.setDarkMode(S),Ge.trigger("afterupdate",f,p)}},updateTransform:function(v){var h=this,f=this._model,p=this._api;if(f){f.setUpdatePayload(v);var d=[];f.eachComponent(function(y,m){if(y!=="series"){var S=h.getViewOfComponentModel(m);if(S&&S.__alive)if(S.updateTransform){var _=S.updateTransform(m,f,p,v);_&&_.update&&d.push(S)}else d.push(S)}});var g=$();f.eachSeries(function(y){var m=h._chartsMap[y.__viewId];if(m.updateTransform){var S=m.updateTransform(y,f,p,v);S&&S.update&&g.set(y.uid,1)}else g.set(y.uid,1)}),t(f),this._scheduler.performVisualTasks(f,v,{setDirty:!0,dirtyMap:g}),Ao(this,f,p,v,{},g),Ge.trigger("afterupdate",f,p)}},updateView:function(v){var h=this._model;h&&(h.setUpdatePayload(v),bt.markUpdateMethod(v,"updateView"),t(h),this._scheduler.performVisualTasks(h,v,{setDirty:!0}),Jl(this,h,this._api,v,{}),Ge.trigger("afterupdate",h,this._api))},updateVisual:function(v){var h=this,f=this._model;f&&(f.setUpdatePayload(v),f.eachSeries(function(p){p.getData().clearAllVisual()}),bt.markUpdateMethod(v,"updateVisual"),t(f),this._scheduler.performVisualTasks(f,v,{visualType:"visual",setDirty:!0}),f.eachComponent(function(p,d){if(p!=="series"){var g=h.getViewOfComponentModel(d);g&&g.__alive&&g.updateVisual(d,f,h._api,v)}}),f.eachSeries(function(p){var d=h._chartsMap[p.__viewId];d.updateVisual(p,f,h._api,v)}),Ge.trigger("afterupdate",f,this._api))},updateLayout:function(v){Mr.update.call(this,v)}},Kl=function(v,h,f,p){if(v._disposed){v.id;return}for(var d=v._model,g=v._coordSysMgr.getCoordinateSystems(),y,m=vi(d,f),S=0;S<g.length;S++){var _=g[S];if(_[h]&&(y=_[h](d,m,p))!=null)return y}},ql=function(v,h){var f=v._chartsMap,p=v._scheduler;h.eachSeries(function(d){p.updateStreamModes(d,f[d.__viewId])})},jl=function(v,h){var f=this,p=this.getModel(),d=v.type,g=v.escapeConnect,y=Cs[d],m=y.actionInfo,S=(m.update||"update").split(":"),_=S.pop(),x=S[0]!=null&&qe(S[0]);this[ne]=!0;var b=[v],A=!1;v.batch&&(A=!0,b=G(v.batch,function(R){return R=Q(z({},R),v),R.batch=null,R}));var T=[],D,C=pc(v),M=Tf(v);if(M&&c0(this._api),w(b,function(R){if(D=y.action(R,f._model,f._api),D=D||z({},R),D.type=m.event||D.type,T.push(D),M){var P=bv(v),k=P.queryOptionMap,O=P.mainTypeSpecified,N=O?k.keys()[0]:"series";wo(f,_,R,N),be(f)}else C?(wo(f,_,R,"series"),be(f)):x&&wo(f,_,R,x.main,x.sub)}),_!=="none"&&!M&&!C&&!x)try{this[ge]?(Fa(this),Mr.update.call(this,v),this[ge]=null):Mr[_].call(this,v)}catch(R){throw this[ne]=!1,R}if(A?D={type:m.event||d,escapeConnect:g,batch:T}:D=T[0],this[ne]=!1,!h){var I=this._messageCenter;if(I.trigger(D.type,D),C){var L={type:"selectchanged",escapeConnect:g,selected:kw(p),isFromClick:v.isFromClick||!1,fromAction:v.type,fromActionPayload:v};I.trigger(L.type,L)}}},Un=function(v){for(var h=this._pendingActions;h.length;){var f=h.shift();jl.call(this,f,v)}},Yn=function(v){!v&&this.trigger("updated")},Yp=function(v,h){v.on("rendered",function(f){h.trigger("rendered",f),v.animation.isFinished()&&!h[ge]&&!h._scheduler.unfinished&&!h._pendingActions.length&&h.trigger("finished")})},Zp=function(v,h){v.on("mouseover",function(f){var p=f.target,d=va(p,Ti);d&&(Pw(d,f,h._api),be(h))}).on("mouseout",function(f){var p=f.target,d=va(p,Ti);d&&(Rw(d,f,h._api),be(h))}).on("click",function(f){var p=f.target,d=va(p,function(m){return q(m).dataIndex!=null},!0);if(d){var g=d.selected?"unselect":"select",y=q(d);h._api.dispatchAction({type:g,dataType:y.dataType,dataIndexInside:y.dataIndex,seriesIndex:y.seriesIndex,isFromClick:!0})}})};function t(v){v.clearColorPalette(),v.eachSeries(function(h){h.clearColorPalette()})}function a(v){var h=[],f=[],p=!1;if(v.eachComponent(function(m,S){var _=S.get("zlevel")||0,x=S.get("z")||0,b=S.getZLevelKey();p=p||!!b,(m==="series"?f:h).push({zlevel:_,z:x,idx:S.componentIndex,type:m,key:b})}),p){var d=h.concat(f),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),_=m.zlevel,x=m.key;g!=null&&(_=Math.max(g,_)),x?(_===g&&x!==y&&_++,y=x):y&&(_===g&&_++,y=""),g=_,S.setZLevel(_)})}}Jl=function(v,h,f,p,d){a(h),$p(v,h,f,p,d),w(v._chartsViews,function(g){g.__alive=!1}),Ao(v,h,f,p,d),w(v._chartsViews,function(g){g.__alive||g.remove(h,f)})},$p=function(v,h,f,p,d,g){w(g||v._componentsViews,function(y){var m=y.__model;u(m,y),y.render(m,h,f,p),s(m,y),c(m,y)})},Ao=function(v,h,f,p,d,g){var y=v._scheduler;d=z(d||{},{updatedSeries:h.getSeries()}),Ge.trigger("series:beforeupdate",h,f,d);var m=!1;h.eachSeries(function(S){var _=v._chartsMap[S.__viewId];_.__alive=!0;var x=_.renderTask;y.updatePayload(x,p),u(S,_),g&&g.get(S.uid)&&x.dirty(),x.perform(y.getPerformArgs(x))&&(m=!0),_.group.silent=!!S.get("silent"),o(S,_),wf(S)}),y.unfinished=m||y.unfinished,Ge.trigger("series:layoutlabels",h,f,d),Ge.trigger("series:transition",h,f,d),h.eachSeries(function(S){var _=v._chartsMap[S.__viewId];s(S,_),c(S,_)}),i(v,h),Ge.trigger("series:afterupdate",h,f,d)},be=function(v){v[Zl]=!0,v.getZr().wakeUp()},Kp=function(v){v[Zl]&&(v.getZr().storage.traverse(function(h){tn(h)||n(h)}),v[Zl]=!1)};function n(v){for(var h=[],f=v.currentStates,p=0;p<f.length;p++){var d=f[p];d==="emphasis"||d==="blur"||d==="select"||h.push(d)}v.selected&&v.states.select&&h.push("select"),v.hoverState===$s&&v.states.emphasis?h.push("emphasis"):v.hoverState===Xi&&v.states.blur&&h.push("blur"),v.useStates(h)}function i(v,h){var f=v._zr,p=f.storage,d=0;p.traverse(function(g){g.isGroup||d++}),d>h.get("hoverLayerThreshold")&&!Nt.node&&!Nt.worker&&h.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,h){var f=v.get("blendMode")||null;h.eachRendered(function(p){p.isGroup||(p.style.blend=f)})}function s(v,h){if(!v.preventAutoZ){var f=v.get("z")||0,p=v.get("zlevel")||0;h.eachRendered(function(d){return l(d,f,p,-1/0),!0})}}function l(v,h,f,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],h,f,p),p);else v.z=h,v.zlevel=f,p=Math.max(v.z2,p);if(d&&(d.z=h,d.zlevel=f,isFinite(p)&&(d.z2=p+2)),g){var _=v.textGuideLineConfig;g.z=h,g.zlevel=f,isFinite(p)&&(g.z2=p+(_&&_.showAbove?1:-1))}return p}function u(v,h){h.eachRendered(function(f){if(!tn(f)){var p=f.getTextContent(),d=f.getTextGuideLine();f.stateTransition&&(f.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),f.hasState()?(f.prevStates=f.currentStates,f.clearStates()):f.prevStates&&(f.prevStates=null)}})}function c(v,h){var f=v.getModel("stateAnimation"),p=v.isAnimationEnabled(),d=f.get("duration"),g=d>0?{duration:d,delay:f.get("delay"),easing:f.get("easing")}:null;h.eachRendered(function(y){if(y.states&&y.states.emphasis){if(tn(y))return;if(y instanceof Mt&&zw(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(p){y.stateTransition=g;var S=y.getTextContent(),_=y.getTextGuideLine();S&&(S.stateTransition=g),_&&(_.stateTransition=g)}y.__dirty&&n(y)}})}Xp=function(v){return new((function(h){E(f,h);function f(){return h!==null&&h.apply(this,arguments)||this}return f.prototype.getCoordinateSystems=function(){return v._coordSysMgr.getCoordinateSystems()},f.prototype.getComponentByElement=function(p){for(;p;){var d=p.__ecComponentInfo;if(d!=null)return v._model.getComponent(d.mainType,d.index);p=p.parent}},f.prototype.enterEmphasis=function(p,d){fr(p,d),be(v)},f.prototype.leaveEmphasis=function(p,d){pr(p,d),be(v)},f.prototype.enterBlur=function(p){o0(p),be(v)},f.prototype.leaveBlur=function(p){Dv(p),be(v)},f.prototype.enterSelect=function(p){s0(p),be(v)},f.prototype.leaveSelect=function(p){l0(p),be(v)},f.prototype.getModel=function(){return v.getModel()},f.prototype.getViewOfComponentModel=function(p){return v.getViewOfComponentModel(p)},f.prototype.getViewOfSeriesModel=function(p){return v.getViewOfSeriesModel(p)},f})(qS))(v)},S_=function(v){function h(f,p){for(var d=0;d<f.length;d++){var g=f[d];g[$l]=p}}w(gi,function(f,p){v._messageCenter.on(p,function(d){if(qp[v.group]&&v[$l]!==Up){if(d&&d.escapeConnect)return;var g=v.makeActionFromEvent(d),y=[];w(yi,function(m){m!==v&&m.group===v.group&&y.push(m)}),h(y,Up),w(y,function(m){m[$l]!==qC&&m.dispatchAction(g)}),h(y,jC)}})})}})(),e})(Sn),jv=__.prototype;jv.on=p_("on");jv.off=p_("off");jv.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 JC=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var Cs={},gi={},Ic=[],Lc=[],Ms=[],x_={},Pc={},yi={},qp={},QC=+new Date-0,Jv="_echarts_instance_";function Cz(r,e,t){var a=!(t&&t.ssr);if(a){var n=tM(r);if(n)return n}var i=new __(r,e,t);return i.id="ec_"+QC++,yi[i.id]=i,a&&t0(r,Jv,i.id),S_(i),Ge.trigger("afterinit",i),i}function tM(r){return yi[xw(r,Jv)]}function b_(r,e){x_[r]=e}function w_(r){ct(Lc,r)<0&&Lc.push(r)}function A_(r,e){th(Ic,r,e,HC)}function eM(r){Qv("afterinit",r)}function rM(r){Qv("afterupdate",r)}function Qv(r,e){Ge.on(r,e)}function ar(r,e,t){K(e)&&(t=e,e="");var a=J(r)?r.type:[r,r={event:e}][0];r.event=(r.event||a).toLowerCase(),e=r.event,!gi[e]&&(Se(Wp.test(a)&&Wp.test(e)),Cs[a]||(Cs[a]={action:t,actionInfo:r}),gi[e]=a)}function aM(r,e){Ji.register(r,e)}function nM(r,e){th(Ms,r,e,v_,"layout")}function Ra(r,e){th(Ms,r,e,h_,"visual")}var jp=[];function th(r,e,t,a,n){if((K(e)||J(e))&&(t=e,e=a),!(ct(jp,t)>=0)){jp.push(t);var i=e_.wrapStageHandler(t,n);i.__prio=e,i.__raw=t,r.push(i)}}function T_(r,e){Pc[r]=e}function iM(r,e,t){var a=VC("registerMap");a&&a(r,e,t)}var oM=hT;Ra(qv,gC);Ra(sl,yC);Ra(sl,mC);Ra(qv,PC);Ra(sl,RC);Ra(f_,NC);w_(JS);A_(GC,fC);T_("default",SC);ar({type:ha,event:ha,update:ha},pe);ar({type:Ko,event:Ko,update:Ko},pe);ar({type:hi,event:hi,update:hi},pe);ar({type:qo,event:qo,update:qo},pe);ar({type:fi,event:fi,update:fi},pe);b_("light",IC);b_("dark",i_);var Jp=[],sM={registerPreprocessor:w_,registerProcessor:A_,registerPostInit:eM,registerPostUpdate:rM,registerUpdateLifecycle:Qv,registerAction:ar,registerCoordinateSystem:aM,registerLayout:nM,registerVisual:Ra,registerTransform:oM,registerLoading:T_,registerMap:iM,registerImpl:OC,PRIORITY:KC,ComponentModel:lt,ComponentView:Rt,SeriesModel:Ct,ChartView:bt,registerComponentModel:function(r){lt.registerClass(r)},registerComponentView:function(r){Rt.registerClass(r)},registerSeriesModel:function(r){Ct.registerClass(r)},registerChartView:function(r){bt.registerClass(r)},registerSubTypeDefaulter:function(r,e){lt.registerSubTypeDefaulter(r,e)},registerPainter:function(r,e){mb(r,e)}};function it(r){if(B(r)){w(r,function(e){it(e)});return}ct(Jp,r)>=0||(Jp.push(r),K(r)&&(r={install:r}),r.install(sM))}var lM=(function(r){E(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 _r(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})(Ct),D_=4,uM=(function(){function r(){}return r})(),cM=(function(r){E(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 uM},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]<D_,c=this.softClipShape,v;if(u){this._ctx=l;return}for(this._ctx=null,v=this._off;v<n.length;){var h=n[v++],f=n[v++];isNaN(h)||isNaN(f)||c&&!c.contain(h,f)||(s.x=h-i[0]/2,s.y=f-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,h=i[c+1]-l/2;if(t>=v&&a>=h&&t<=v+s&&a<=h+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,h=0;h<n.length;){var f=n[h++],p=n[h++];l=Math.min(f,l),c=Math.max(f,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})(Mt),vM=(function(){function r(){this.group=new et}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 cM({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=Wt(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;var o=e.shape.size[0]<D_;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})(),hM=(function(r){E(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=ro("").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){if(t.get("clip",!0)){var a=t.coordinateSystem;return a&&a.getArea&&a.getArea(.1)}},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 vM: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})(bt),fM=(function(r){E(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),oo=(function(){function r(){}return r.prototype.getNeedCrossZero=function(){var e=this.option;return!e.scale},r.prototype.getCoordSysModel=function(){},r})(),Rc=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Ht).models[0]},e.type="cartesian2dAxis",e})(lt);Jt(Rc,oo);var C_={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},pM=nt({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},C_),eh=nt({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}}},C_),dM=nt({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},eh),gM=Q({logBase:10},eh);const M_={category:pM,value:eh,time:dM,log:gM};var yM=0,Ec=(function(){function r(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++yM}return r.createByAxisModel=function(e){var t=e.option,a=t.data,n=a&&G(a,mM);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(!Y(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=$(this.categories))},r})();function mM(r){return J(r)&&r.value!=null?r.value:r+""}var SM={value:1,category:1,time:1,log:1};function hn(r,e,t,a){w(SM,function(n,i){var o=nt(nt({},M_[i],!0),a,!0),s=(function(l){E(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 h=Mi(this),f=h?Mn(c):{},p=v.getTheme();nt(c,p.get(i+"Axis")),nt(c,this.getDefaultOption()),c.type=Qp(c),h&&Fr(c,f,h)},u.prototype.optionUpdated=function(){var c=this.option;c.type==="category"&&(this.__ordinalMeta=Ec.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",Qp)}function Qp(r){return r.type||(r.data?"category":"value")}var nr=(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})();Zs(nr);function kc(r){return r.type==="interval"||r.type==="log"}function _M(r,e,t,a){var n={},i=r[1]-r[0],o=n.interval=Zm(i/e);t!=null&&o<t&&(o=n.interval=t),a!=null&&o>a&&(o=n.interval=a);var s=n.intervalPrecision=I_(o),l=n.niceTickExtent=[Ot(Math.ceil(r[0]/o)*o,s),Ot(Math.floor(r[1]/o)*o,s)];return xM(l,r),n}function Ql(r){var e=Math.pow(10,_v(r)),t=r/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,Ot(t*e)}function I_(r){return je(r)+2}function td(r,e,t){r[e]=Math.max(Math.min(r[e],t[1]),t[0])}function xM(r,e){!isFinite(r[0])&&(r[0]=e[0]),!isFinite(r[1])&&(r[1]=e[1]),td(r,0,e),td(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 vl=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;a.type="ordinal";var n=a.getSetting("ordinalMeta");return n||(n=new Ec({})),B(n)&&(n=new Ec({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:Y(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})(nr);nr.registerClass(vl);var jr=Ot,gr=(function(r){E(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=I_(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:jr(i[0]-a,o)}):s.push({value:n[0]}));for(var u=i[0];u<=i[1]&&(s.push({value:u}),u=jr(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:jr(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,h=v/t;u<t-1;){var f=jr(l.value+(u+1)*h);f>i[0]&&f<i[1]&&c.push(f),u++}n.push(c)}return n},e.prototype.getLabel=function(t,a){if(t==null)return"";var n=a&&a.precision;n==null?n=je(t.value)||0:n==="auto"&&(n=this._intervalPrecision);var i=jr(t.value,n,!0);return eS(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=_M(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]=jr(Math.floor(a[0]/o)*o)),t.fixMax||(a[1]=jr(Math.ceil(a[1]/o)*o))},e.prototype.setNiceExtent=function(t,a){this._niceExtent=[t,a]},e.type="interval",e})(nr);nr.registerClass(gr);var bM=function(r,e,t,a){for(;t<a;){var n=t+a>>>1;r[n][1]<e?t=n+1:a=n}return t},rh=(function(r){E(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 tl(t.value,Yf[ZA(rn(this._minLevelUnit))]||Yf.second,a,this.getSetting("locale"))},e.prototype.getFormattedLabel=function(t,a,n){var i=this.getSetting("useUTC"),o=this.getSetting("locale");return $A(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=IM(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]-=Ie,a[1]+=Ie),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]-Ie}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=To.length,l=Math.min(bM(To,this._approxInterval,0,s),s-1);this._interval=To[l][1],this._minLevelUnit=To[Math.max(l-1,0)][0]},e.prototype.parse=function(t){return St(t)?t:+er(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})(gr),To=[["second",Bv],["minute",zv],["hour",pi],["quarter-day",pi*6],["half-day",pi*12],["day",Ie*1.2],["half-week",Ie*3.5],["week",Ie*7],["month",Ie*31],["quarter",Ie*95],["half-year",Uf/2],["year",Uf]];function wM(r,e,t,a){var n=er(e),i=er(t),o=function(p){return Zf(n,p,a)===Zf(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")},h=function(){return v()&&o("second")},f=function(){return h()&&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 h();case"millisecond":return f()}}function AM(r,e){return r/=Ie,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function TM(r){var e=30*Ie;return r/=e,r>6?6:r>3?3:r>2?2:1}function DM(r){return r/=pi,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function ed(r,e){return r/=e?zv:Bv,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function CM(r){return Zm(r)}function MM(r,e,t){var a=new Date(r);switch(rn(e)){case"year":case"month":a[K0(t)](0);case"day":a[q0(t)](1);case"hour":a[j0(t)](0);case"minute":a[J0(t)](0);case"second":a[Q0(t)](0),a[tS(t)](0)}return a.getTime()}function IM(r,e,t,a){var n=1e4,i=$0,o=0;function s(C,M,I,L,R,P,k){for(var O=new Date(M),N=M,V=O[L]();N<I&&N<=a[1];)k.push({value:N}),V+=C,O[R](V),N=O.getTime();k.push({value:N,notAdd:!0})}function l(C,M,I){var L=[],R=!M.length;if(!wM(rn(C),a[0],a[1],t)){R&&(M=[{value:MM(new Date(a[0]),C,t)},{value:a[1]}]);for(var P=0;P<M.length-1;P++){var k=M[P].value,O=M[P+1].value;if(k!==O){var N=void 0,V=void 0,F=void 0,W=!1;switch(C){case"year":N=Math.max(1,Math.round(e/Ie/365)),V=Gv(t),F=XA(t);break;case"half-year":case"quarter":case"month":N=TM(e),V=an(t),F=K0(t);break;case"week":case"half-week":case"day":N=AM(e),V=el(t),F=q0(t),W=!0;break;case"half-day":case"quarter-day":case"hour":N=DM(e),V=Ci(t),F=j0(t);break;case"minute":N=ed(e,!0),V=rl(t),F=J0(t);break;case"second":N=ed(e,!1),V=al(t),F=Q0(t);break;case"millisecond":N=CM(e),V=nl(t),F=tS(t);break}s(N,k,O,V,F,W,L),C==="year"&&I.length>1&&P===0&&I.unshift({value:I[0].value-N})}}for(var P=0;P<L.length;P++)I.push(L[P]);return L}}for(var u=[],c=[],v=0,h=0,f=0;f<i.length&&o++<n;++f){var p=rn(i[f]);if(YA(i[f])){l(i[f],u[u.length-1]||[],c);var d=i[f+1]?rn(i[f+1]):null;if(p!==d){if(c.length){h=v,c.sort(function(C,M){return C.value-M.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&&h>S/1.5||(u.push(g),v>S||r===i[f]))break}c=[]}}}for(var _=_t(G(u,function(C){return _t(C,function(M){return M.value>=a[0]&&M.value<=a[1]&&!M.notAdd})}),function(C){return C.length>0}),x=[],b=_.length-1,f=0;f<_.length;++f)for(var A=_[f],T=0;T<A.length;++T)x.push({value:A[T].value,level:b-f});x.sort(function(C,M){return C.value-M.value});for(var D=[],f=0;f<x.length;++f)(f===0||x[f].value!==x[f-1].value)&&D.push(x[f]);return D}nr.registerClass(rh);var rd=nr.prototype,mi=gr.prototype,LM=Ot,PM=Math.floor,RM=Math.ceil,Do=Math.pow,ze=Math.log,ah=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new gr,t._interval=0,t}return e.prototype.getTicks=function(t){var a=this._originalScale,n=this._extent,i=a.getExtent(),o=mi.getTicks.call(this,t);return G(o,function(s){var l=s.value,u=Ot(Do(this.base,l));return u=l===n[0]&&this._fixMin?Co(u,i[0]):u,u=l===n[1]&&this._fixMax?Co(u,i[1]):u,{value:u}},this)},e.prototype.setExtent=function(t,a){var n=ze(this.base);t=ze(Math.max(0,t))/n,a=ze(Math.max(0,a))/n,mi.setExtent.call(this,t,a)},e.prototype.getExtent=function(){var t=this.base,a=rd.getExtent.call(this);a[0]=Do(t,a[0]),a[1]=Do(t,a[1]);var n=this._originalScale,i=n.getExtent();return this._fixMin&&(a[0]=Co(a[0],i[0])),this._fixMax&&(a[1]=Co(a[1],i[1])),a},e.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var a=this.base;t[0]=ze(t[0])/ze(a),t[1]=ze(t[1])/ze(a),rd.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=[Ot(RM(a[0]/i)*i),Ot(PM(a[1]/i)*i)];this._interval=i,this._niceExtent=s}},e.prototype.calcNiceExtent=function(t){mi.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=ze(t)/ze(this.base),ll(t,this._extent)},e.prototype.normalize=function(t){return t=ze(t)/ze(this.base),ul(t,this._extent)},e.prototype.scale=function(t){return t=cl(t,this._extent),Do(this.base,t)},e.type="log",e})(nr),L_=ah.prototype;L_.getMinorTicks=mi.getMinorTicks;L_.getLabel=mi.getLabel;function Co(r,e){return LM(r,je(e))}nr.registerClass(ah);var EM=(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=t.get("min",!0);i==null&&(i=t.get("startValue",!0));var o=this._modelMinRaw=i;K(o)?this._modelMinNum=Mo(e,o({min:a[0],max:a[1]})):o!=="dataMin"&&(this._modelMinNum=Mo(e,o));var s=this._modelMaxRaw=t.get("max",!0);if(K(s)?this._modelMaxNum=Mo(e,s({min:a[0],max:a[1]})):s!=="dataMax"&&(this._modelMaxNum=Mo(e,s)),n)this._axisDataLen=t.getCategories().length;else{var l=t.get("boundaryGap"),u=B(l)?l:[l||0,l||0];typeof u[0]=="boolean"||typeof u[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[sn(u[0],1),sn(u[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=hs(s)||hs(l)||e&&!n;this._needCrossZero&&(s>0&&l>0&&!u&&(s=0),s<0&&l<0&&!c&&(l=0));var h=this._determinedMin,f=this._determinedMax;return h!=null&&(s=h,u=!0),f!=null&&(l=f,c=!0),{min:s,max:l,minFixed:u,maxFixed:c,isBlank:v}},r.prototype.modifyDataMinMax=function(e,t){this[NM[e]]=t},r.prototype.setDeterminedMinMax=function(e,t){var a=kM[e];this[a]=t},r.prototype.freeze=function(){this.frozen=!0},r})(),kM={min:"_determinedMin",max:"_determinedMax"},NM={min:"_dataMin",max:"_dataMax"};function P_(r,e,t){var a=r.rawExtentInfo;return a||(a=new EM(r,e,t),r.rawExtentInfo=a,a)}function Mo(r,e){return e==null?null:hs(e)?NaN:r.parse(e)}function R_(r,e){var t=r.type,a=P_(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=IS("bar",o),l=!1;if(w(s,function(v){l=l||v.getBaseAxis()===e.axis}),l){var u=LS(s),c=OM(n,i,e,u);n=c.min,i=c.max}}return{extent:[n,i],fixMin:a.minFixed,fixMax:a.maxFixed}}function OM(r,e,t,a){var n=t.axis.getExtent(),i=Math.abs(n[1]-n[0]),o=vD(a,t.axis);if(o===void 0)return{min:r,max:e};var s=1/0;w(o,function(f){s=Math.min(f.offset,s)});var l=-1/0;w(o,function(f){l=Math.max(f.offset+f.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,c=e-r,v=1-(s+l)/i,h=c/v-c;return e+=h*(l/u),r-=h*(s/u),{min:r,max:e}}function fn(r,e){var t=e,a=R_(r,t),n=a.extent,i=t.get("splitNumber");r instanceof ah&&(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 hl(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new vl({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new rh({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(nr.getClass(e)||gr)}}function VM(r){var e=r.scale.getExtent(),t=e[0],a=e[1];return!(t>0&&a>0||t<0&&a<0)}function En(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):Y(e)?(function(a){return function(n){var i=r.scale.getLabel(n),o=a.replace("{value}",i??"");return o}})(e):K(e)?(function(a){return function(n,i){return t!=null&&(i=n.value-t),a(nh(r,n),i,n.level!=null?{level:n.level}:null)}})(e):function(a){return r.scale.getLabel(a)}}function nh(r,e){return r.type==="category"?r.scale.getLabel(e):e.value}function BM(r){var e=r.model,t=r.scale;if(!(!e.get(["axisLabel","show"])||t.isBlank())){var a,n,i=t.getExtent();t instanceof vl?n=t.count():(a=t.getTicks(),n=a.length);var o=r.getLabelModel(),s=En(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},h=s(v,c),f=o.getTextRect(h),p=zM(f,o.get("rotate")||0);l?l.union(p):l=p}return l}}function zM(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 ih(r){var e=r.get("interval");return e??"auto"}function E_(r){return r.type==="category"&&ih(r.getLabelModel())===0}function Is(r,e){var t={};return w(r.mapDimensionsAll(e),function(a){t[U0(r,a)]=!0}),Ut(t)}function GM(r,e,t){e&&w(Is(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 FM=(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(),_t(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})(),Nc=["x","y"];function ad(r){return r.type==="interval"||r.type==="time"}var HM=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=Nc,t}return e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,a=this.getAxis("y").scale;if(!(!ad(t)||!ad(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,h=o[0]-n[0]*c,f=o[1]-i[0]*v,p=this._transform=[c,0,0,v,h,f];this._invTransform=Wi([],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 Re(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 Re(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(t){t=t||0;var a=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),i=Math.min(a[0],a[1])-t,o=Math.min(n[0],n[1])-t,s=Math.max(a[0],a[1])-i+t,l=Math.max(n[0],n[1])-o+t;return new wt(i,o,s,l)},e})(FM),Ei=ut();function k_(r,e){var t=G(e,function(a){return r.scale.parse(a)});return r.type==="time"&&t.length>0&&(t.sort(),t.unshift(t[0]),t.push(t[t.length-1])),t}function WM(r){var e=r.getLabelModel().get("customValues");if(e){var t=En(r),a=r.scale.getExtent(),n=k_(r,e),i=_t(n,function(o){return o>=a[0]&&o<=a[1]});return{labels:G(i,function(o){var s={value:o};return{formattedLabel:t(s),rawLabel:r.scale.getLabel(s),tickValue:o}})}}return r.type==="category"?YM(r):$M(r)}function UM(r,e){var t=r.getTickModel().get("customValues");if(t){var a=r.scale.getExtent(),n=k_(r,t);return{ticks:_t(n,function(i){return i>=a[0]&&i<=a[1]})}}return r.type==="category"?ZM(r,e):{ticks:G(r.scale.getTicks(),function(i){return i.value})}}function YM(r){var e=r.getLabelModel(),t=N_(r,e);return!e.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:t.labelCategoryInterval}:t}function N_(r,e){var t=O_(r,"labels"),a=ih(e),n=V_(t,a);if(n)return n;var i,o;return K(a)?i=G_(r,a):(o=a==="auto"?XM(r):a,i=z_(r,o)),B_(t,a,{labels:i,labelCategoryInterval:o})}function ZM(r,e){var t=O_(r,"ticks"),a=ih(e),n=V_(t,a);if(n)return n;var i,o;if((!e.get("show")||r.scale.isBlank())&&(i=[]),K(a))i=G_(r,a,!0);else if(a==="auto"){var s=N_(r,r.getLabelModel());o=s.labelCategoryInterval,i=G(s.labels,function(l){return l.tickValue})}else o=a,i=z_(r,o,!0);return B_(t,a,{ticks:i,tickCategoryInterval:o})}function $M(r){var e=r.scale.getTicks(),t=En(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 O_(r,e){return Ei(r)[e]||(Ei(r)[e]=[])}function V_(r,e){for(var t=0;t<r.length;t++)if(r[t].key===e)return r[t].value}function B_(r,e,t){return r.push({key:e,value:t}),t}function XM(r){var e=Ei(r).autoInterval;return e??(Ei(r).autoInterval=r.calculateCategoryInterval())}function KM(r){var e=qM(r),t=En(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)),h=0,f=0;l<=i[1];l+=s){var p=0,d=0,g=Ys(t({value:l}),e.font,"center","top");p=g.width*1.3,d=g.height*1.3,h=Math.max(h,p,7),f=Math.max(f,d,7)}var y=h/c,m=f/v;isNaN(y)&&(y=1/0),isNaN(m)&&(m=1/0);var S=Math.max(0,Math.floor(Math.min(y,m))),_=Ei(r.model),x=r.getExtent(),b=_.lastAutoInterval,A=_.lastTickCount;return b!=null&&A!=null&&Math.abs(b-S)<=1&&Math.abs(A-o)<=1&&b>S&&_.axisExtent0===x[0]&&_.axisExtent1===x[1]?S=b:(_.lastTickCount=o,_.lastAutoInterval=S,_.axisExtent0=x[0],_.axisExtent1=x[1]),S}function qM(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 z_(r,e,t){var a=En(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=E_(r),h=o.get("showMinLabel")||v,f=o.get("showMaxLabel")||v;h&&u!==i[0]&&d(i[0]);for(var p=u;p<=i[1];p+=l)d(p);f&&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 G_(r,e,t){var a=r.scale,n=En(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 nd=[0,1],Ze=(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 Um(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(),id(a,n.count())),yt(e,nd,a,t)},r.prototype.coordToData=function(e,t){var a=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(a=a.slice(),id(a,n.count()));var i=yt(e,a,nd,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=UM(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 jM(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 WM(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 KM(this)},r})();function id(r,e){var t=r[1]-r[0],a=e,n=t/a/2;r[0]+=n,r[1]-=n}function jM(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],tickValue:e[0].tickValue};else{var l=e[n-1].tickValue-e[0].tickValue,u=(e[n-1].coord-e[0].coord)/l;w(e,function(f){f.coord-=u/2});var c=r.scale.getExtent();s=1+c[1]-e[n-1].tickValue,o={coord:e[n-1].coord+u*s,tickValue:c[1]+1},e.push(o)}var v=i[0]>i[1];h(e[0].coord,i[0])&&(a?e[0].coord=i[0]:e.shift()),a&&h(i[0],e[0].coord)&&e.unshift({coord:i[0]}),h(i[1],o.coord)&&(a?o.coord=i[1]:e.pop()),a&&h(o.coord,i[1])&&e.push({coord:i[1]});function h(f,p){return f=Ot(f),p=Ot(p),v?f>p:f<p}}var JM=(function(r){E(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})(Ze);function Oc(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],h={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p=u==="x"?[v[2]-f,v[3]+f]:[v[0]-f,v[1]+f];if(o){var d=o.toGlobalCoord(o.dataToCoord(0));p[h.onZero]=Math.max(Math.min(d,p[1]),p[0])}i.position=[u==="y"?p[h[l]]:v[0],u==="x"?p[h[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[h[s]]-p[h.onZero]:0,e.get(["axisTick","inside"])&&(i.tickDirection=-i.tickDirection),Qt(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 od(r){return r.get("coordinateSystem")==="cartesian2d"}function sd(r){var e={xAxisModel:null,yAxisModel:null};return w(e,function(t,a){var n=a.replace(/Model$/,""),i=r.getReferringComponents(n,Ht).models[0];e[a]=i}),e}var tu=Math.log;function F_(r,e,t){var a=gr.prototype,n=a.getTicks.call(t),i=a.getTicks.call(t,!0),o=n.length-1,s=a.getInterval.call(t),l=R_(r,e),u=l.extent,c=l.fixMin,v=l.fixMax;if(r.type==="log"){var h=tu(r.base);u=[tu(u[0])/h,tu(u[1])/h]}r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:c,fixMax:v});var f=a.getExtent.call(r);c&&(u[0]=f[0]),v&&(u[1]=f[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=Ql(p),g=u[0]+p*o;else if(v)for(d=u[1]-p*o;d>u[0]&&isFinite(d)&&isFinite(u[0]);)p=Ql(p),d=u[1]-p*o;else{var y=r.getTicks().length-1;y>o&&(p=Ql(p));var m=p*o;g=Math.ceil(u[1]/p)*p,d=Ot(g-m),d<0&&u[0]>=0?(d=0,g=Ot(m)):g>0&&u[1]<=0&&(g=0,d=-Ot(m))}var S=(n[0].value-i[0].value)/s,_=(n[o].value-i[o].value)/s;a.setExtent.call(r,d+p*S,g+p*_),a.setInterval.call(r,p),(S||_)&&a.setNiceExtent.call(r,d+p,g-p)}var QM=(function(){function r(e,t,a){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Nc,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=Ut(o),u=l.length;if(u){for(var c=[],v=u-1;v>=0;v--){var h=+l[v],f=o[h],p=f.model,d=f.scale;kc(d)&&p.get("alignTicks")&&p.get("interval")==null?c.push(f):(fn(d,p),kc(d)&&(s=f))}c.length&&(s||(s=c.pop(),fn(s.scale,s.model)),w(c,function(g){F_(g.scale,g.model,s.scale)}))}}n(a.x),n(a.y);var i={};w(a.x,function(o){ld(a,"y",o,i)}),w(a.y,function(o){ld(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=Zt(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=BM(u);if(c){var v=u.isHorizontal()?"height":"width",h=u.model.get(["axisLabel","margin"]);o[v]-=c[v]+h,u.position==="top"?o.y+=c.height+h:u.position==="left"&&(o.x+=c.width+h)}}}),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],h=u.inverse?1:0;u.setExtent(v[h],v[1-h]),tI(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",Ht).models[0],n=e.yAxisModel||t&&t.getReferringComponents("yAxis",Ht).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(h,f){var p="x"+v+"y"+f,d=new HM(p);d.master=n,d.model=e,n._coordsMap[p]=d,n._coordsList.push(d),d.addAxis(c),d.addAxis(h)})});function u(c){return function(v,h){if(eu(v,e)){var f=v.get("position");c==="x"?f!=="top"&&f!=="bottom"&&(f=o.bottom?"top":"bottom"):f!=="left"&&f!=="right"&&(f=o.left?"right":"left"),o[f]=!0;var p=new JM(c,hl(v),[0,0],v.get("type"),f),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=h,i._axesList.push(p),s[c][h]=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(od(n)){var i=sd(n),o=i.xAxisModel,s=i.yAxisModel;if(!eu(o,t)||!eu(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(Is(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(od(n)){var i=sd(n),o=i.xAxisModel,s=i.yAxisModel,l=o.getCoordSysModel(),u=l.coordinateSystem;n.coordinateSystem=u.getCartesian(o.componentIndex,s.componentIndex)}}),a},r.dimensions=Nc,r})();function eu(r,e){return r.getCoordSysModel()===e}function ld(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)ud(n[l])&&(i=n[l]);else for(var u in n)if(n.hasOwnProperty(u)&&ud(n[u])&&!a[c(n[u])]){i=n[u];break}i&&(a[c(i)]=!0);function c(v){return v.dim+"_"+v.index}}function ud(r){return r&&r.type!=="category"&&r.type!=="time"&&VM(r)}function tI(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}}var Pr=Math.PI,fe=(function(){function r(e,t){this.group=new et,this.opt=t,this.axisModel=e,Q(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var a=new et({x:t.position[0],y:t.position[1],rotation:t.rotation});a.updateTransform(),this._transformGroup=a}return r.prototype.hasBuilder=function(e){return!!cd[e]},r.prototype.add=function(e){cd[e](this.opt,this.axisModel,this.group,this._transformGroup)},r.prototype.getGroup=function(){return this.group},r.innerTextLayout=function(e,t,a){var n=Ym(t-e),i,o;return bi(n)?(o=a>0?"top":"bottom",i="center"):bi(n-Pr)?(o=a>0?"bottom":"top",i="center"):(o="middle",n>0&&n<Pr?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})(),cd={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&&(Re(s,s,o),Re(l,l,o));var c=z({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),v=new ee({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:c,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});ln(v.shape,v.style.lineWidth),v.anid="line",t.add(v);var h=e.get(["axisLine","symbol"]);if(h!=null){var f=e.get(["axisLine","symbolSize"]);Y(h)&&(h=[h,h]),(Y(f)||St(f))&&(f=[f,f]);var p=La(e.get(["axisLine","symbolOffset"])||0,f),d=f[0],g=f[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(h[m]!=="none"&&h[m]!=null){var S=Wt(h[m],-d/2,-g/2,d,g,c.stroke,!0),_=y.r+y.offset,x=u?l:s;S.attr({rotation:y.rotate,x:x[0]+_*Math.cos(r.rotation),y:x[1]-_*Math.sin(r.rotation),silent:!0,z2:11}),t.add(S)}})}}},axisTickLabel:function(r,e,t,a){var n=aI(t,a,e,r),i=iI(t,a,e,r);if(rI(e,i,n),nI(t,a,e,r.tickDirection),e.get(["axisLabel","hideOverlap"])){var o=US(G(i,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));$S(o)}},axisName:function(r,e,t,a){var n=Qt(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,hd(i)?r.labelOffset+o*l:0],h,f=e.get("nameRotate");f!=null&&(f=f*Pr/180);var p;hd(i)?h=fe.innerTextLayout(r.rotation,f??r.rotation,o):(h=eI(r.rotation,i,f||0,u),p=r.axisNameAvailableWidth,p!=null&&(p=Math.abs(p/Math.sin(h.rotation)),!isFinite(p)&&(p=null)));var d=s.getFont(),g=e.get("nameTruncate",!0)||{},y=g.ellipsis,m=Qt(r.nameTruncateMaxWidth,g.maxWidth,p),S=new vt({x:v[0],y:v[1],rotation:h.rotation,silent:fe.isLabelSilent(e),style:Dt(s,{text:n,font:d,overflow:"truncate",width:m,ellipsis:y,fill:s.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:s.get("align")||h.textAlign,verticalAlign:s.get("verticalAlign")||h.textVerticalAlign}),z2:1});if(Ma({el:S,componentModel:e,itemName:n}),S.__fullText=n,S.anid="name",e.get("triggerEvent")){var _=fe.makeAxisEventDataBase(e);_.targetType="axisName",_.name=n,q(S).eventData=_}a.add(S),S.updateTransform(),t.add(S),S.decomposeTransform()}}};function eI(r,e,t,a){var n=Ym(t-r),i,o,s=a[0]>a[1],l=e==="start"&&!s||e!=="start"&&s;return bi(n-Pr/2)?(o=l?"bottom":"top",i="center"):bi(n-Pr*1.5)?(o=l?"top":"bottom",i="center"):(o="middle",n<Pr*1.5&&n>Pr/2?i=l?"left":"right":i=l?"right":"left"),{rotation:n,textAlign:i,textVerticalAlign:o}}function rI(r,e,t){if(!E_(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],h=t[t.length-2];a===!1?(we(i),we(u)):vd(i,o)&&(a?(we(o),we(c)):(we(i),we(u))),n===!1?(we(s),we(v)):vd(l,s)&&(n?(we(l),we(h)):(we(s),we(v)))}}function we(r){r&&(r.ignore=!0)}function vd(r,e){var t=r&&r.getBoundingRect().clone(),a=e&&e.getBoundingRect().clone();if(!(!t||!a)){var n=gv([]);return Yi(n,n,-r.rotation),t.applyTransform(ls([],n,r.getLocalTransform())),a.applyTransform(ls([],n,e.getLocalTransform())),t.intersect(a)}}function hd(r){return r==="middle"||r==="center"}function H_(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&&(Re(o,o,e),Re(s,s,e));var c=new ee({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:a,z2:2,autoBatch:!0,silent:!0});ln(c.shape,c.style.lineWidth),c.anid=n+"_"+r[l].tickValue,i.push(c)}return i}function aI(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=H_(u,e.transform,l,Q(s.getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])}),"ticks"),v=0;v<c.length;v++)r.add(c[v]);return c}}function nI(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=Q(s.getLineStyle(),Q(t.getModel("axisTick").getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])})),c=0;c<o.length;c++)for(var v=H_(o[c],e.transform,l,u,"minorticks_"+c),h=0;h<v.length;h++)r.add(v[h])}}function iI(r,e,t,a){var n=t.axis,i=Qt(a.axisLabelShow,t.get(["axisLabel","show"]));if(!(!i||n.scale.isBlank())){var o=t.getModel("axisLabel"),s=o.get("margin"),l=n.getViewLabels(),u=(Qt(a.labelRotate,o.get("rotate"))||0)*Pr/180,c=fe.innerTextLayout(a.rotation,u,a.labelDirection),v=t.getCategories&&t.getCategories(!0),h=[],f=fe.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,_=o;if(v&&v[y]){var x=v[y];J(x)&&x.textStyle&&(_=new mt(x.textStyle,o,t.ecModel))}var b=_.getTextColor()||t.get(["axisLine","lineStyle","color"]),A=n.dataToCoord(y),T=_.getShallow("align",!0)||c.textAlign,D=pt(_.getShallow("alignMinLabel",!0),T),C=pt(_.getShallow("alignMaxLabel",!0),T),M=_.getShallow("verticalAlign",!0)||_.getShallow("baseline",!0)||c.textVerticalAlign,I=pt(_.getShallow("verticalAlignMinLabel",!0),M),L=pt(_.getShallow("verticalAlignMaxLabel",!0),M),R=new vt({x:A,y:a.labelOffset+a.labelDirection*s,rotation:c.rotation,silent:f,z2:10+(d.level||0),style:Dt(_,{text:m,align:g===0?D:g===l.length-1?C:T,verticalAlign:g===0?I:g===l.length-1?L:M,fill:K(b)?b(n.type==="category"?S:n.type==="value"?y+"":y,g):b})});if(R.anid="label_"+y,Ma({el:R,componentModel:t,itemName:m,formatterParamsExtra:{isTruncated:function(){return R.isTruncated},value:S,tickIndex:g}}),p){var P=fe.makeAxisEventDataBase(t);P.targetType="axisLabel",P.value=S,P.tickIndex=g,n.type==="category"&&(P.dataIndex=y),q(R).eventData=P}e.add(R),R.updateTransform(),h.push(R),r.add(R),R.decomposeTransform()}),h}}function oI(r,e){var t={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return sI(t,r,e),t.seriesInvolved&&uI(t,r),t}function sI(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=ki(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var c=s.model,v=c.getModel("tooltip",a);if(w(s.getAxes(),tt(d,!1,null)),s.getTooltipAxes&&a&&v.get("show")){var h=v.get("trigger")==="axis",f=v.get(["axisPointer","type"])==="cross",p=s.getTooltipAxes(v.get(["axisPointer","axis"]));(h||f)&&w(p.baseAxes,tt(d,f?"cross":!0,h)),f&&w(p.otherAxes,tt(d,"cross",!1))}function d(g,y,m){var S=m.model.getModel("axisPointer",n),_=S.get("show");if(!(!_||_==="auto"&&!g&&!Vc(S))){y==null&&(y=S.get("triggerTooltip")),S=g?lI(m,v,n,e,g,y):S;var x=S.get("snap"),b=S.get("triggerEmphasis"),A=ki(m.model),T=y||x||m.type==="category",D=r.axesInfo[A]={key:A,axis:m,coordSys:s,axisPointerModel:S,triggerTooltip:y,triggerEmphasis:b,involveSeries:T,snap:x,useHandle:Vc(S),seriesModels:[],linkGroup:null};u[A]=D,r.seriesInvolved=r.seriesInvolved||T;var C=cI(i,m);if(C!=null){var M=o[C]||(o[C]={axesInfo:{}});M.axesInfo[A]=D,M.mapper=i[C].mapper,D.linkGroup=M}}}})}function lI(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(h){l[h]=j(o.get(h))}),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&&Q(u,v.textStyle)}}return r.model.getModel("axisPointer",new mt(l,t,a))}function uI(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[ki(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 cI(r,e){for(var t=e.model,a=e.dim,n=0;n<r.length;n++){var i=r[n]||{};if(ru(i[a+"AxisId"],t.id)||ru(i[a+"AxisIndex"],t.componentIndex)||ru(i[a+"AxisName"],t.name))return n}}function ru(r,e){return r==="all"||B(r)&&ct(r,e)>=0||r===e}function vI(r){var e=oh(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=Vc(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 oh(r){var e=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[ki(r)]}function hI(r){var e=oh(r);return e&&e.axisPointerModel}function Vc(r){return!!r.get(["handle","show"])}function ki(r){return r.type+"||"+r.id}var fd={},Ea=(function(r){E(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&&vI(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=hI(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){fd[t]=a},e.getAxisPointerClass=function(t){return t&&fd[t]},e.type="axis",e})(Rt),Bc=ut();function W_(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=Bc(r).splitAreaColors,h=$(),f=0;if(v)for(var p=0;p<u.length;p++){var d=v.get(u[p].tickValue);if(d!=null){f=(d+(c-1)*p)%c;break}}var g=n.toGlobalCoord(u[0].coord),y=o.getAreaStyle();s=B(s)?s:[s];for(var p=1;p<u.length;p++){var m=n.toGlobalCoord(u[p].coord),S=void 0,_=void 0,x=void 0,b=void 0;n.isHorizontal()?(S=g,_=l.y,x=m-S,b=l.height,g=S+x):(S=l.x,_=g,x=l.width,b=m-_,g=_+b);var A=u[p-1].tickValue;A!=null&&h.set(A,f),e.add(new dt({anid:A!=null?"area_"+A:null,shape:{x:S,y:_,width:x,height:b},style:Q({fill:s[f]},y),autoBatch:!0,silent:!0})),f=(f+1)%c}Bc(r).splitAreaColors=h}}}function U_(r){Bc(r).splitAreaColors=null}var fI=["axisLine","axisTickLabel","axisName"],pI=["splitArea","splitLine","minorSplitLine"],Y_=(function(r){E(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 et,this.group.add(this._axisGroup),!!t.get("show")){var s=t.getCoordSysModel(),l=Oc(s,t),u=new fe(t,z({handleAutoShown:function(v){for(var h=s.coordinateSystem.getCartesians(),f=0;f<h.length;f++)if(kc(h[f].getOtherAxis(t.axis).scale))return!0;return!1}},l));w(fI,u.add,u),this._axisGroup.add(u.getGroup()),w(pI,function(v){t.get([v,"show"])&&dI[v](this,this._axisGroup,t,s)},this);var c=i&&i.type==="changeAxisOrder"&&i.isInitSort;c||Ki(o,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)}},e.prototype.remove=function(){U_(this)},e.type="cartesianAxis",e})(Ea),dI={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"),l=i.get("showMinLine")!==!1,u=i.get("showMaxLine")!==!1;s=B(s)?s:[s];for(var c=a.coordinateSystem.getRect(),v=n.isHorizontal(),h=0,f=n.getTicksCoords({tickModel:i}),p=[],d=[],g=o.getLineStyle(),y=0;y<f.length;y++){var m=n.toGlobalCoord(f[y].coord);if(!(y===0&&!l||y===f.length-1&&!u)){var S=f[y].tickValue;v?(p[0]=m,p[1]=c.y,d[0]=m,d[1]=c.y+c.height):(p[0]=c.x,p[1]=m,d[0]=c.x+c.width,d[1]=m);var _=h++%s.length,x=new ee({anid:S!=null?"line_"+S:null,autoBatch:!0,shape:{x1:p[0],y1:p[1],x2:d[0],y2:d[1]},style:Q({stroke:s[_]},g),silent:!0});ln(x.shape,g.lineWidth),e.add(x)}}}},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=[],h=o.getLineStyle(),f=0;f<u.length;f++)for(var p=0;p<u[f].length;p++){var d=n.toGlobalCoord(u[f][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 ee({anid:"minor_line_"+u[f][p].tickValue,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:v[0],y2:v[1]},style:h,silent:!0});ln(g.shape,h.lineWidth),e.add(g)}},splitArea:function(r,e,t,a){W_(r,e,t,a)}},Z_=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="xAxis",e})(Y_),gI=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=Z_.type,t}return e.type="yAxis",e})(Y_),yI=(function(r){E(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 dt({shape:t.coordinateSystem.getRect(),style:Q({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},e.type="grid",e})(Rt),pd={offset:0};function $_(r){r.registerComponentView(yI),r.registerComponentModel(fM),r.registerCoordinateSystem("cartesian2d",QM),hn(r,"x",Rc,pd),hn(r,"y",Rc,pd),r.registerComponentView(Z_),r.registerComponentView(gI),r.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function mI(r){it($_),r.registerSeriesModel(lM),r.registerChartView(hM),r.registerLayout(ro("scatter"))}function SI(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]=dd(c)?c:gd(n)})}),t.each(function(o){var s=Sb(a[o],function(l){return dd(l)})||gd(n);a[o].push(s.slice()),t.setItemLayout(o,a[o])})}})}function dd(r){return!isNaN(r[0])&&!isNaN(r[1])}function gd(r){return[r.cx,r.cy]}function _I(r){var e=r.polar;if(e){B(e)||(e=[e]);var t=[];w(e,function(a,n){a.indicator?(a.type&&!a.shape&&(a.shape=a.type),r.radar=r.radar||[],B(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 xI=(function(r){E(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(h,f){var p=h.getItemVisual(f,"symbol")||"circle";if(p!=="none"){var d=In(h.getItemVisual(f,"symbolSize")),g=Wt(p,-1,-1,2,2),y=h.getItemVisual(f,"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(h,f,p,d,g,y){p.removeAll();for(var m=0;m<f.length-1;m++){var S=u(d,g);S&&(S.__dimIdx=m,h[m]?(S.setPosition(h[m]),Ia[y?"initProps":"updateProps"](S,{x:f[m][0],y:f[m][1]},t,g)):S.setPosition(f[m]),p.add(S))}}function v(h){return G(h,function(f){return[i.cx,i.cy]})}s.diff(l).add(function(h){var f=s.getItemLayout(h);if(f){var p=new ke,d=new xe,g={shape:{points:f}};p.shape.points=v(f),d.shape.points=v(f),Pt(p,g,t,h),Pt(d,g,t,h);var y=new et,m=new et;y.add(d),y.add(p),y.add(m),c(d.shape.points,f,m,s,h,!0),s.setItemGraphicEl(h,y)}}).update(function(h,f){var p=l.getItemGraphicEl(f),d=p.childAt(0),g=p.childAt(1),y=p.childAt(2),m={shape:{points:s.getItemLayout(h)}};m.shape.points&&(c(d.shape.points,m.shape.points,y,s,h,!1),Ue(g),Ue(d),ft(d,m,t),ft(g,m,t),s.setItemGraphicEl(h,p))}).remove(function(h){o.remove(l.getItemGraphicEl(h))}).execute(),s.eachItemGraphicEl(function(h,f){var p=s.getItemModel(f),d=h.childAt(0),g=h.childAt(1),y=h.childAt(2),m=s.getItemVisual(f,"style"),S=m.fill;o.add(h),d.useStyle(Q(p.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:S})),re(d,p,"lineStyle"),re(g,p,"areaStyle");var _=p.getModel("areaStyle"),x=_.isEmpty()&&_.parentModel.isEmpty();g.ignore=x,w(["emphasis","select","blur"],function(T){var D=p.getModel([T,"areaStyle"]),C=D.isEmpty()&&D.parentModel.isEmpty();g.ensureState(T).ignore=C&&x}),g.useStyle(Q(_.getAreaStyle(),{fill:S,opacity:.7,decal:m.decal}));var b=p.getModel("emphasis"),A=b.getModel("itemStyle").getItemStyle();y.eachChild(function(T){if(T instanceof Ne){var D=T.style;T.useStyle(z({image:D.image,x:D.x,y:D.y,width:D.width,height:D.height},m))}else T.useStyle(m),T.setColor(S),T.style.strokeNoScale=!0;var C=T.ensureState("emphasis");C.style=j(A);var M=s.getStore().get(s.getDimensionIndex(T.__dimIdx),f);(M==null||isNaN(M))&&(M=""),ae(T,qt(p),{labelFetcher:s.hostModel,labelDataIndex:f,labelDimIndex:T.__dimIdx,defaultText:M,inheritColor:S,defaultOpacity:m.opacity})}),kt(h,b.get("focus"),b.get("blurScope"),b.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type="radar",e})(bt),bI=(function(r){E(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 no(U(this.getData,this),U(this.getRawData,this))},e.prototype.getInitialData=function(t,a){return Rn(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=pS(this,t);return jt("section",{header:u,sortBlocks:!0,blocks:G(s,function(v){var h=i.get(i.mapDimension(v.dim),t);return jt("nameValue",{markerType:"subItem",markerColor:c,name:v.name,value:h,sortParam:h})})})},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})(Ct),Zn=M_.value;function Io(r,e){return Q({show:e},r)}var wI=(function(r){E(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"),h=this.get("triggerEvent"),f=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=Q({color:p.color},l));var g=nt(j(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:h},!1);if(Y(c)){var y=g.name;g.name=c.replace("{value}",y??"")}else K(c)&&(g.name=c(g.name,g));var m=new mt(g,null,this.ecModel);return Jt(m,oo.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=f},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:nt({lineStyle:{color:"#bbb"}},Zn.axisLine),axisLabel:Io(Zn.axisLabel,!1),axisTick:Io(Zn.axisTick,!1),splitLine:Io(Zn.splitLine,!0),splitArea:Io(Zn.splitArea,!0),indicator:[]},e})(lt),AI=["axisLine","axisTickLabel","axisName"],TI=(function(r){E(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 fe(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(AI,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"),h=l.get("color"),f=u.get("color"),p=B(h)?h:[h],d=B(f)?f:[f],g=[],y=[];function m(P,k,O){var N=O%k.length;return P[N]=P[N]||[],N}if(i==="circle")for(var S=n[0].getTicksCoords(),_=a.cx,x=a.cy,b=0;b<S.length;b++){if(c){var A=m(g,p,b);g[A].push(new Ca({shape:{cx:_,cy:x,r:S[b].coord}}))}if(v&&b<S.length-1){var A=m(y,d,b);y[A].push(new Hs({shape:{cx:_,cy:x,r0:S[b].coord,r:S[b+1].coord}}))}}else for(var T,D=G(n,function(P,k){var O=P.getTicksCoords();return T=T==null?O.length-1:Math.min(O.length-1,T),G(O,function(N){return a.coordToPoint(N.coord,k)})}),C=[],b=0;b<=T;b++){for(var M=[],I=0;I<n.length;I++)M.push(D[I][b]);if(M[0]&&M.push(M[0].slice()),c){var A=m(g,p,b);g[A].push(new xe({shape:{points:M}}))}if(v&&C){var A=m(y,d,b-1);y[A].push(new ke({shape:{points:M.concat(C)}}))}C=M.slice().reverse()}var L=l.getLineStyle(),R=u.getAreaStyle();w(y,function(P,k){this.group.add(Me(P,{style:Q({stroke:"none",fill:d[k%d.length]},R),silent:!0}))},this),w(g,function(P,k){this.group.add(Me(P,{style:Q({fill:"none",stroke:p[k%p.length]},L),silent:!0}))},this)},e.type="radar",e})(Rt),DI=(function(r){E(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})(Ze),CI=(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 DI(o,new gr);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=H(a[0],n),this.cy=H(a[1],i),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(Y(s)||St(s))&&(s=[0,s]),this.r0=H(s[0],o),this.r=H(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 gr;o.setExtent(0,i),o.setInterval(1),w(a,function(s,l){F_(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})();function MI(r){r.registerCoordinateSystem("radar",CI),r.registerComponentModel(wI),r.registerComponentView(TI),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 II(r){it(MI),r.registerChartView(xI),r.registerSeriesModel(bI),r.registerLayout(SI),r.registerProcessor(ao("radar")),r.registerPreprocessor(_I)}var yd="\0_ec_interaction_mutex";function LI(r,e,t){var a=sh(r);a[e]=t}function PI(r,e,t){var a=sh(r),n=a[e];n===t&&(a[e]=null)}function md(r,e){return!!sh(r)[e]}function sh(r){return r[yd]||(r[yd]={})}ar({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},pe);var so=(function(r){E(e,r);function e(t){var a=r.call(this)||this;a._zr=t;var n=U(a._mousedownHandler,a),i=U(a._mousemoveHandler,a),o=U(a._mouseupHandler,a),s=U(a._mousewheelHandler,a),l=U(a._pinchHandler,a);return a.enable=function(u,c){this.disable(),this._opt=Q(j(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(!lf(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||!rs("moveOnMouseMove",t,this._opt)||t.gestureEvent==="pinch"||md(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&&Br(t.event),X_(this,"pan","moveOnMouseMove",t,{dx:s,dy:l,oldX:i,oldY:o,newX:a,newY:n,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){lf(t)||(this._dragging=!1)},e.prototype._mousewheelHandler=function(t){var a=rs("zoomOnMouseWheel",t,this._opt),n=rs("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;au(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:s,originY:l,isAvailableBehavior:null})}if(n){var v=Math.abs(i),h=(i>0?1:-1)*(v>3?.4:v>1?.15:.05);au(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:h,originX:s,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!md(this._zr,"globalPan")){var a=t.pinchScale>1?1.1:1/1.1;au(this,"zoom",null,t,{scale:a,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e})(Sn);function au(r,e,t,a,n){r.pointerChecker&&r.pointerChecker(a,n.originX,n.originY)&&(Br(a.event),X_(r,e,t,a,n))}function X_(r,e,t,a,n){n.isAvailableBehavior=U(rs,null,t,a),r.trigger(e,n)}function rs(r,e,t){var a=t[r];return!r||a&&(!Y(a)||e.event[a+"Key"])}function lh(r,e,t){var a=r.target;a.x+=e,a.y+=t,a.dirty()}function uh(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 RI={axisPointer:1,tooltip:1,brush:1};function fl(r,e,t){var a=e.getComponentByElement(r.topTarget),n=a&&a.coordinateSystem;return a&&a!==t&&!RI.hasOwnProperty(a.mainType)&&n&&n.model!==t}var EI=[];function nu(r,e){for(var t=0;t<r.length;t++)Re(r[t],r[t],e)}function Sd(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])&&(Om(e,e,i),Vm(t,t,i))}}function kI(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 K_=(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})(),_d=(function(){function r(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return r})(),xd=(function(){function r(e){this.type="linestring",this.points=e}return r})(),q_=(function(r){E(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 kI(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"?Sd(s.exterior,n,i,t):w(s.points,function(l){Sd(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(na(l,t[0],t[1])){for(var c=0;c<(u?u.length:0);c++)if(na(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 h=c[v];h.type==="polygon"?(nu(h.exterior,u),w(h.interiors,function(f){nu(f,u)})):w(h.points,function(f){nu(f,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})(K_),NI=(function(r){E(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=gv(EI),o=t;o&&!o.isGeoSVGGraphicRoot;)ls(i,o.getLocalTransform(),i),o=o.parent;return Wi(i,i),Re(n,n,i),n},e})(K_),OI=$(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),VI=(function(){function r(e,t){this.type="geoSVG",this._usedGraphicMap=$(),this._freedGraphics=[],this._mapName=e,this._parsedXML=_b(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=zI(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&&xb(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},a=t.root,Se(a!=null)}catch(g){throw new Error(`Invalid svg format
`+g.message)}var n=new et;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,h=void 0;if(i!=null?(u=0,v=i):s&&(u=s.x,v=s.width),o!=null?(c=0,h=o):s&&(c=s.y,h=s.height),u==null||c==null){var f=a.getBoundingRect();u==null&&(u=f.x,v=f.width),c==null&&(c=f.y,h=f.height)}l=this._boundingRect=new wt(u,c,v,h)}if(s){var p=bb(s,l);a.scaleX=a.scaleY=p.scale,a.x=p.x,a.y=p.y}n.setClipPath(new dt({shape:l.plain()}));var d=[];return w(t.named,function(g){OI.get(g.svgNodeTagLower)!=null&&(d.push(g),BI(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 BI(r){r.silent=!1,r.isGroup&&r.traverse(function(e){e.silent=!1})}function zI(r){var e=[],t=$();return w(r,function(a){if(a.namedFrom==null){var n=new NI(a.name,a.el);e.push(n),t.set(a.name,n)}}),{regions:e,regionsMap:t}}function GI(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=j_(s,o,t);break;case"Polygon":iu(s,o,t);break;case"MultiLineString":iu(s,o,t);break;case"MultiPolygon":w(s,function(l,u){return iu(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function iu(r,e,t){for(var a=0;a<r.length;a++)r[a]=j_(r[a],e[a],t)}function j_(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 FI(r,e){return r=GI(r),G(_t(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 _d(o[0],o.slice(1)));break;case"MultiPolygon":w(n.coordinates,function(l){l[0]&&i.push(new _d(l[0],l.slice(1)))});break;case"LineString":i.push(new xd([n.coordinates]));break;case"MultiLineString":i.push(new xd(n.coordinates))}var s=new q_(a[e||"name"],i,a.cp);return s.properties=a,s})}var zc=[126,25],bd="南海诸岛",Qr=[[[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<Qr.length;Jr++)for(var Ha=0;Ha<Qr[Jr].length;Ha++)Qr[Jr][Ha][0]/=10.5,Qr[Jr][Ha][1]/=-10.5/.75,Qr[Jr][Ha][0]+=zc[0],Qr[Jr][Ha][1]+=zc[1];function HI(r,e){if(r==="china"){for(var t=0;t<e.length;t++)if(e[t].name===bd)return;e.push(new q_(bd,G(Qr,function(a){return{type:"polygon",exterior:a}}),zc))}}var WI={南海诸岛:[32,80],广东:[0,-10],香港:[10,5],澳门:[-10,10],天津:[5,5]};function UI(r,e){if(r==="china"){var t=WI[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 YI=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function ZI(r,e){r==="china"&&e.name==="台湾"&&e.geometries.push({type:"polygon",exterior:YI[0]})}var $I="name",XI=(function(){function r(e,t,a){this.type="geoJSON",this._parsedMap=$(),this._mapName=e,this._specialAreas=a,this._geoJSON=qI(t)}return r.prototype.load=function(e,t){t=t||$I;var a=this._parsedMap.get(t);if(!a){var n=this._parseToRegions(t);a=this._parsedMap.set(t,{regions:n,boundingRect:KI(n)})}var i=$(),o=[];return w(a.regions,function(s){var l=s.name;e&&Z(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?FI(a,e):[]}catch(i){throw new Error(`Invalid geoJson format
`+i.message)}return HI(t,n),w(n,function(i){var o=i.name;UI(t,i),ZI(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 KI(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 qI(r){return Y(r)?typeof JSON<"u"&&JSON.parse?JSON.parse(r):new Function("return ("+r+");")():r}var $n=$();const yr={registerMap:function(r,e,t){if(e.svg){var a=new VI(r,e.svg);$n.set(r,a)}else{var n=e.geoJson||e.geoJSON;n&&!e.features?t=e.specialAreas:n=e;var a=new XI(r,n,t);$n.set(r,a)}},getGeoResource:function(r){return $n.get(r)},getMapForUser:function(r){var e=$n.get(r);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(r,e,t){var a=$n.get(r);if(a)return a.load(e,t)}};var ch=["rect","circle","line","ellipse","polygon","polyline","path"],jI=$(ch),JI=$(ch.concat(["g"])),QI=$(ch.concat(["g"])),J_=ut();function Lo(r){var e=r.getItemStyle(),t=r.get("areaColor");return t!=null&&(e.fill=t),e}function wd(r){var e=r.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var Q_=(function(){function r(e){var t=new et;this.uid=Dn("ec_map_draw"),this._controller=new so(e.getZr()),this._controllerHost={target:t},this.group=t,t.add(this._regionsGroup=new et),t.add(this._svgGroup=new et)}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(),h=v.raw,f=v.roam,p=!u.childAt(0)||i;p?(c.x=f.x,c.y=f.y,c.scaleX=f.scaleX,c.scaleY=f.scaleY,c.dirty()):ft(c,f,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:h};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=$(),a=$(),n=this._regionsGroup,i=e.transformInfoRaw,o=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function c(f,p){return p&&(f=p(f)),f&&[f[0]*i.scaleX+i.x,f[1]*i.scaleY+i.y]}function v(f){for(var p=[],d=!u&&l&&l.project,g=0;g<f.length;++g){var y=c(f[g],d);y&&p.push(y)}return p}function h(f){return{shape:{points:v(f)}}}n.removeAll(),w(e.geo.regions,function(f){var p=f.name,d=t.get(p),g=a.get(p)||{},y=g.dataIdx,m=g.regionModel;if(!d){d=t.set(p,new et),n.add(d),y=s?s.indexOfName(p):null,m=e.isGeo?o.getRegionModel(p):s?s.getItemModel(y):null;var S=m.get("silent",!0);S!=null&&(d.silent=S),a.set(p,{dataIdx:y,regionModel:m})}var _=[],x=[];w(f.geometries,function(T){if(T.type==="polygon"){var D=[T.exterior].concat(T.interiors||[]);u&&(D=Id(D,u)),w(D,function(M){_.push(new ke(h(M)))})}else{var C=T.points;u&&(C=Id(C,u,!0)),w(C,function(M){x.push(new xe(h(M)))})}});var b=c(f.getCenter(),l&&l.project);function A(T,D){if(T.length){var C=new Rm({culling:!0,segmentIgnoreThreshold:1,shape:{paths:T}});d.add(C),Ad(e,C,y,m),Td(e,C,p,m,o,y,b),D&&(wd(C),w(C.states,wd))}}A(_),A(x,!0)}),t.each(function(f,p){var d=a.get(p),g=d.dataIdx,y=d.regionModel;Dd(e,f,p,y,o,g),Cd(e,f,p,y,o),Md(e,f,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=$(),i=!1;w(this._svgGraphicRecord.named,function(o){var s=o.name,l=e.mapOrGeoModel,u=e.data,c=o.svgNodeTagLower,v=o.el,h=u?u.indexOfName(s):null,f=l.getRegionModel(s);jI.get(c)!=null&&v instanceof ma&&Ad(e,v,h,f),v instanceof ma&&(v.culling=!0);var p=f.get("silent",!0);if(p!=null&&(v.silent=p),v.z2EmphasisLift=0,!o.namedFrom&&(QI.get(c)!=null&&Td(e,v,s,f,l,h,null),Dd(e,v,s,f,l,h),Cd(e,v,s,f,l),JI.get(c)!=null)){var d=Md(e,v,s,f,l);d==="self"&&(i=!0);var g=n.get(s)||n.set(s,[]);g.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){wa(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=yr.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=yr.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,lh(o,u.dx,u.dy),a.dispatchAction(z(l(),{dx:u.dx,dy:u.dy,animation:{duration:0}}))},this),i.off("zoom").on("zoom",function(u){this._mouseDownFlag=!1,uh(o,u.scale,u.originX,u.originY),a.dispatchAction(z(l(),{totalZoom:o.zoom,zoom:u.scale,originX:u.originX,originY:u.originY,animation:{duration:0}}))},this),i.setPointerChecker(function(u,c,v){return n.containPoint([c,v])&&!fl(u,a,e)})},r.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=J_(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 Ad(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),h=r.data;if(h){var f=h.getItemVisual(t,"style"),p=h.getItemVisual(t,"decal");r.isVisualEncodedByVisualMap&&f.fill&&(l.fill=f.fill),p&&(l.decal=vn(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,wa(e)}function Td(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,h=void 0;(!s||i>=0)&&(h=n);var f=o?{normal:{align:"center",verticalAlign:"middle"}}:null;ae(e,qt(a),{labelFetcher:h,labelDataIndex:v,defaultText:t},f);var p=e.getTextContent();if(p&&(J_(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 Dd(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 Cd(r,e,t,a,n){r.data||Ma({el:e,componentModel:n,itemName:t,itemTooltipOption:a.get("tooltip")})}function Md(r,e,t,a,n){e.highDownSilentOnTouch=!!n.get("selectedMode");var i=a.getModel("emphasis"),o=i.get("focus");return kt(e,o,i.get("blurScope"),i.get("disabled")),r.isGeo&&Vw(e,n,t),o}function Id(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}var tL=(function(r){E(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 Q_(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,h=new Ca({style:{fill:t.getData().getVisual("style").fill},shape:{cx:c[0]+v*9,cy:c[1],r:3},silent:!0,z2:8+(v?0:bn+1)});if(!v){var f=t.mainSeries.getData(),p=i.getName(l),d=f.indexOfName(p),g=i.getItemModel(l),y=g.getModel("label"),m=f.getItemGraphicEl(d);ae(h,qt(g),{labelFetcher:{getFormattedLabel:function(S,_){return t.getFormattedLabel(d,_)}},defaultText:p}),h.disableLabelAnimation=!0,y.get("position")||h.setTextConfig({position:"bottom"}),m.onHoverStateChange=function(S){ps(h,S)}}o.add(h)}}})},e.type="map",e})(bt),eL=(function(r){E(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=Rn(this,{coordDimensions:["value"],encodeDefaulter:tt(Pv,this)}),n=$(),i=[],o=0,s=a.count();o<s;o++){var l=a.getName(o);n.set(l,o)}var u=yr.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return w(u.regions,function(c){var v=c.name,h=n.get(v),f=c.properties&&c.properties.echartsStyle,p;h==null?(p={name:v},i.push(p)):p=a.getRawDataItem(h),f&&nt(p,f)}),a.appendData(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),h=i.mapDimension("value");isNaN(l[c].originalData.get(h,v))||u.push(l[c].name)}return jt("section",{header:u.join(", "),noHeader:!u.length,blocks:[jt("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=Wt(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})(Ct);function rL(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 aL(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=rL(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 nL(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),h=s.getRegion(v);if(!(!h||isNaN(u))){var f=n[v]||0,p=s.dataToPoint(h.getCenter());n[v]=f+1,l.setItemLayout(c,{point:p,offset:f})}})});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 Ld=Re,lo=(function(r){E(e,r);function e(t){var a=r.call(this)||this;return a.type="view",a.dimensions=["x","y"],a._roamTransformable=new Ja,a._rawTransformable=new Ja,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=[H(t[0],a.getWidth()),H(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=Re([],i,t),n=Re([],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(),wb(this.transform||(this.transform=[]),a.transform||_n()),this._rawTransform=a.getLocalTransform(),this.invTransform=this.invTransform||[],Wi(this.invTransform,this.transform),this.decomposeTransform()},e.prototype.getTransformInfo=function(){var t=this._rawTransformable,a=this._roamTransformable,n=new Ja;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?Ld(n,t,i):ce(n,t)},e.prototype.pointToData=function(t){var a=this.invTransform;return a?Ld([],t,a):[t[0],t[1]]},e.prototype.convertToPixel=function(t,a,n){var i=Pd(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=Pd(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})(Ja);function Pd(r){var e=r.seriesModel;return e?e.coordinateSystem:null}var iL={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},tx=["lng","lat"],Gc=(function(r){E(e,r);function e(t,a,n){var i=r.call(this,t)||this;i.dimensions=tx,i.type="geo",i._nameCoordMap=$(),i.map=a;var o=n.projection,s=yr.load(a,n.nameMap,n.nameProperty),l=yr.getGeoResource(a);i.resourceType=l?l.type:null;var u=i.regions=s.regions,c=iL[l.type];i._regionsMap=s.regionsMap,i.regions=s.regions,i.projection=o;var v;if(o)for(var h=0;h<u.length;h++){var f=u[h].getBoundingRect(o);v=v||f.clone(),v.union(f)}else v=s.boundingRect;return i.setBoundingRect(v.x,v.y,v.width,v.height),i.aspectScale=o?1:pt(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(Y(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=Rd(a);return i===this?i.dataToPoint(n):null},e.prototype.convertFromPixel=function(t,a,n){var i=Rd(a);return i===this?i.pointToData(n):null},e})(lo);Jt(Gc,lo);function Rd(r){var e=r.geoModel,t=r.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",Ht).models[0]||{}).coordinateSystem:null}function Ed(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(b,A,T,D){for(var C=T-b,M=D-A,I=0;I<=100;I++){var L=I/100,R=i.project([b+C*L,A+M*L]);Om(a,a,R),Vm(n,n,R)}};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(),h=r.get("layoutCenter"),f=r.get("layoutSize"),p=e.getWidth(),d=e.getHeight(),g=v.width/v.height*this.aspectScale,y=!1,m,S;h&&f&&(m=[H(h[0],p),H(h[1],d)],S=H(f,Math.min(p,d)),!isNaN(m[0])&&!isNaN(m[1])&&!isNaN(S)&&(y=!0));var _;if(y)_={},g>1?(_.width=S,_.height=S/g):(_.height=S,_.width=S*g),_.y=m[1]-_.height/2,_.x=m[0]-_.width/2;else{var x=r.getBoxLayoutParams();x.aspect=g,_=Zt(x,{width:p,height:d})}this.setViewRect(_.x,_.y,_.width,_.height),this.setCenter(r.get("center"),e),this.setZoom(r.get("zoom"))}function oL(r,e){w(e.get("geoCoord"),function(t,a){r.addGeoCoord(a,t)})}var sL=(function(){function r(){this.dimensions=tx}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 Gc(l+s,l,z({nameMap:o.get("nameMap")},n(o)));u.zoomLimit=o.get("scaleLimit"),a.push(u),o.coordinateSystem=u,u.model=o,u.resize=Ed,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 Gc(s,s,z({nameMap:mv(l)},n(o[0])));u.zoomLimit=Qt.apply(null,G(o,function(c){return c.get("scaleLimit")})),a.push(u),u.resize=Ed,u.resize(o[0],t),w(o,function(c){c.coordinateSystem=u,oL(u,c)})}),a},r.prototype.getFilledRegions=function(e,t,a,n){for(var i=(e||[]).slice(),o=$(),s=0;s<i.length;s++)o.set(i[s].name,i[s]);var l=yr.load(t,a,n);return w(l.regions,function(u){var c=u.name,v=o.get(c),h=u.properties&&u.properties.echartsStyle;v||(v={name:c},i.push(v)),h&&nt(v,h)}),i},r})(),ex=new sL,lL=(function(r){E(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=yr.getGeoResource(t.map);if(i&&i.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color="#eee")}this.mergeDefaultAndTheme(t,n),xa(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,a=this.option;a.regions=ex.getFilledRegions(a.regions,a.map,a.nameMap,a.nameProperty);var n={};this._optionModelMap=on(a.regions||[],function(i,o){var s=o.name;return s&&(i.set(s,new mt(o,t,t.ecModel)),o.selected&&(n[s]=!0)),i},$()),a.selectedMap||(a.selectedMap=n)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new mt(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(K(i))return o.status=a,i(o);if(Y(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);function kd(r,e){return r.pointToProjected?r.pointToProjected(e):r.pointToData(e)}function vh(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(kd(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(kd(r,s),a),r.setZoom(o*n)}return{center:r.getCenter(),zoom:r.getZoom()}}var uL=(function(r){E(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 Q_(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;va(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})(Rt);function cL(r,e,t){yr.registerMap(r,e,t)}function rx(r){r.registerCoordinateSystem("geo",ex),r.registerComponentModel(lL),r.registerComponentView(uL),r.registerImpl("registerMap",cL),r.registerImpl("getMap",function(t){return yr.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,h){o[h]&&c.push(h)}),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=vh(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 vL(r){it(rx),r.registerChartView(tL),r.registerSeriesModel(eL),r.registerLayout(nL),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,aL),BS("map",r.registerAction)}function hL(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 fL(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){gL(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=yL(r,n,r.parentNode.hierNode.defaultAncestor||a[0],e)}function pL(r){var e=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:e},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function Nd(r){return arguments.length?r:_L}function ii(r,e){return r-=Math.PI/2,{x:e*Math.cos(r),y:e*Math.sin(r)}}function dL(r,e){return Zt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function gL(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 yL(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=ou(s),i=su(i),s&&i;){n=ou(n),o=su(o),n.hierNode.ancestor=r;var h=s.hierNode.prelim+v-i.hierNode.prelim-u+a(s,i);h>0&&(SL(mL(s,r,t),r,h),u+=h,l+=h),v+=s.hierNode.modifier,u+=i.hierNode.modifier,l+=n.hierNode.modifier,c+=o.hierNode.modifier}s&&!ou(n)&&(n.hierNode.thread=s,n.hierNode.modifier+=v-l),i&&!su(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-c,t=r)}return t}function ou(r){var e=r.children;return e.length&&r.isExpand?e[e.length-1]:r.hierNode.thread}function su(r){var e=r.children;return e.length&&r.isExpand?e[0]:r.hierNode.thread}function mL(r,e,t){return r.hierNode.ancestor.parentNode===e.parentNode?r.hierNode.ancestor:t}function SL(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 _L(r,e){return r.parentNode===e.parentNode?1:2}var xL=(function(){function r(){this.parentPoint=[],this.childPoints=[]}return r})(),bL=(function(r){E(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 xL},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,h=H(a.forkPosition,1),f=[];f[c]=o[c],f[v]=o[v]+(l[v]-o[v])*h,t.moveTo(o[0],o[1]),t.lineTo(f[0],f[1]),t.moveTo(s[0],s[1]),f[c]=s[c],t.lineTo(f[0],f[1]),f[c]=l[c],t.lineTo(f[0],f[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]),f[c]=d[c],t.lineTo(f[0],f[1])}},e})(Mt),wL=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._mainGroup=new et,t}return e.prototype.init=function(t,a){this._controller=new so(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){Od(i,c)&&Vd(i,c,null,s,t)}).update(function(c,v){var h=u.getItemGraphicEl(v);if(!Od(i,c)){h&&zd(u,v,h,s,t);return}Vd(i,c,h,s,t)}).remove(function(c){var v=u.getItemGraphicEl(c);v&&zd(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 h=n.getItemLayout(v);h&&!isNaN(h.x)&&!isNaN(h.y)&&i.push([+h.x,+h.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 lo;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 h=l.getBoundingRect();return h.applyTransform(l.transform),h.contain(c,v)&&!fl(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){lh(s,u.dx,u.dy),n.dispatchAction({seriesId:t.id,type:"treeRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){uh(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})(bt);function Od(r,e){var t=r.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function Vd(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,h=r.getItemGraphicEl(v.dataIndex),f=v.getLayout(),p=h?{x:h.__oldX,y:h.__oldY,rawX:h.__radialOldRawX,rawY:h.__radialOldRawY}:f,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,_=void 0,x=void 0;if(d.x===m.x&&o.isExpand===!0&&y.children.length){var b={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};_=Math.atan2(b.y-m.y,b.x-m.x),_<0&&(_=Math.PI*2+_),x=b.x<m.x,x&&(_=_-Math.PI)}else _=Math.atan2(d.y-m.y,d.x-m.x),_<0&&(_=Math.PI*2+_),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(x=d.x<m.x,x&&(_=_-Math.PI)):(x=d.x>m.x,x||(_=_-Math.PI));var A=x?"left":"right",T=s.getModel("label"),D=T.get("rotate"),C=D*(Math.PI/180),M=g.getTextContent();M&&(g.setTextConfig({position:T.get("position")||A,rotation:D==null?-_:C,origin:"center"}),M.setStyle("verticalAlign","middle"))}var I=s.get(["emphasis","focus"]),L=I==="relative"?_i(o.getAncestorsIndices(),o.getDescendantIndices()):I==="ancestor"?o.getAncestorsIndices():I==="descendant"?o.getDescendantIndices():null;L&&(q(t).focus=L),AL(n,o,c,t,p,f,d,a),t.__edge&&(t.onHoverStateChange=function(R){if(R!=="blur"){var P=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);P&&P.hoverState===Xi||ps(t.__edge,R)}})}function AL(r,e,t,a,n,i,o,s){var l=e.getModel(),u=r.get("edgeShape"),c=r.get("layout"),v=r.getOrient(),h=r.get(["lineStyle","curveness"]),f=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,h,n,n)})),ft(d,{shape:Fc(c,v,h,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 bL({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:v,forkPosition:f}})),ft(d,{shape:{parentPoint:[o.x,o.y],childPoints:y}},r)}d&&!(u==="polyline"&&!e.isExpand)&&(d.useStyle(Q({strokeNoScale:!0,fill:null},p)),re(d,l,"lineStyle"),wa(d),s.add(d))}function Bd(r,e,t,a,n){var i=e.tree.root,o=ax(i,r),s=o.source,l=o.sourceLayout,u=e.getItemGraphicEl(r.dataIndex);if(u){var c=e.getItemGraphicEl(s.dataIndex),v=c.__edge,h=u.__edge||(s.isExpand===!1||s.children.length===1?v:void 0),f=a.get("edgeShape"),p=a.get("layout"),d=a.get("orient"),g=a.get(["lineStyle","curveness"]);h&&(f==="curve"?zr(h,{shape:Fc(p,d,g,l,l),style:{opacity:0}},a,{cb:function(){t.remove(h)},removeOpt:n}):f==="polyline"&&a.get("layout")==="orthogonal"&&zr(h,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},a,{cb:function(){t.remove(h)},removeOpt:n}))}}function ax(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 zd(r,e,t,a,n){var i=r.tree.getNodeByDataIndex(e),o=r.tree.root,s=ax(o,i).sourceLayout,l={duration:n.get("animationDurationUpdate"),easing:n.get("animationEasingUpdate")};zr(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){Bd(u,r,a,n,l)}),Bd(i,r,a,n,l)}function Fc(r,e,t,a,n){var i,o,s,l,u,c,v,h;if(r==="radial"){u=a.rawX,v=a.rawY,c=n.rawX,h=n.rawY;var f=ii(u,v),p=ii(u,v+(h-v)*t),d=ii(c,h+(v-h)*t),g=ii(c,h);return{x1:f.x||0,y1:f.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,h=n.y,(e==="LR"||e==="RL")&&(i=u+(c-u)*t,o=v,s=c+(u-c)*t,l=h),(e==="TB"||e==="BT")&&(i=u,o=v+(h-v)*t,s=c,l=h+(v-h)*t);return{x1:u,y1:v,x2:c,y2:h,cpx1:i,cpy1:o,cpx2:s,cpy2:l}}var Pe=ut();function nx(r){var e=r.mainData,t=r.datas;t||(t={main:e},r.datasAttr={main:"data"}),r.datas=r.mainData=null,ix(e,t,r),w(t,function(a){w(e.TRANSFERABLE_METHODS,function(n){a.wrapMethod(n,tt(TL,r))})}),e.wrapMethod("cloneShallow",tt(CL,r)),w(e.CHANGABLE_METHODS,function(a){e.wrapMethod(a,tt(DL,r))}),Se(t[e.dataType]===e)}function TL(r,e){if(LL(this)){var t=z({},Pe(this).datas);t[this.dataType]=e,ix(e,t,r)}else hh(e,this.dataType,Pe(this).mainData,r);return e}function DL(r,e){return r.struct&&r.struct.update(),e}function CL(r,e){return w(Pe(e).datas,function(t,a){t!==e&&hh(t.cloneShallow(),a,e,r)}),e}function ML(r){var e=Pe(this).mainData;return r==null||e==null?e:Pe(e).datas[r]}function IL(){var r=Pe(this).mainData;return r==null?[{data:r}]:G(Ut(Pe(r).datas),function(e){return{type:e,data:Pe(r).datas[e]}})}function LL(r){return Pe(r).mainData===r}function ix(r,e,t){Pe(r).datas={},w(e,function(a,n){hh(a,n,r,t)})}function hh(r,e,t,a){Pe(t).datas[e]=r,Pe(r).mainData=t,r.dataType=e,a.struct&&(r[a.structAttr]=a.struct,a.struct[a.datasAttr[e]]=r),r.getLinkedData=ML,r.getLinkedDataAll=IL}var PL=(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){K(e)&&(a=t,t=e,e=null),e=e||{},Y(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})(),fh=(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 h=c.value;o=Math.max(o,B(h)?h.length:1),i.push(c);var f=new PL(Yt(c.name,""),n);v?RL(f,v):n.root=f,n._nodes.push(f);var p=c.children;if(p)for(var d=0;d<p.length;d++)s(p[d],f)}n.root.updateDepthAndHeight(0);var l=ji(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new he(l,t);return u.initData(i),a&&a(u),nx({mainData:u,struct:n,structAttr:"tree"}),n.update(),n},r})();function RL(r,e){var t=e.children;r.parentNode!==e&&(t.push(r),r.parentNode=e)}function Ni(r,e,t){if(r&&ct(e,r.type)>=0){var a=t.getData().tree.root,n=r.targetNode;if(Y(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 ox(r){for(var e=[];r;)r=r.parentNode,r&&e.push(r);return e.reverse()}function ph(r,e){var t=ox(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 EL=(function(r){E(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 mt(n,this,this.ecModel),o=fh.createTree(a,this,s);function s(v){v.wrapMethod("getItemModel",function(h,f){var p=o.getNodeByDataIndex(f);return p&&p.children.length&&p.isExpand||(h.parentModel=i),h})}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 h=v.hostTree.data.getRawDataItem(v.dataIndex);v.isExpand=h&&h.collapsed!=null?!h.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 jt("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})(Ct);function kL(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 Xn(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 NL(r,e){r.eachSeriesByType("tree",function(t){OL(t,e)})}function OL(r,e){var t=dL(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=Nd(function(S,_){return(S.parentNode===_.parentNode?1:2)/S.depth})):(n=t.width,i=t.height,o=Nd());var s=r.getData().tree.root,l=s.children[0];if(l){hL(s),kL(l,fL,o),s.hierNode.modifier=-l.hierNode.prelim,Xn(l,pL);var u=l,c=l,v=l;Xn(l,function(S){var _=S.getLayout().x;_<u.getLayout().x&&(u=S),_>c.getLayout().x&&(c=S),S.depth>v.depth&&(v=S)});var h=u===c?1:o(u,c)/2,f=h-u.getLayout().x,p=0,d=0,g=0,y=0;if(a==="radial")p=n/(c.getLayout().x+h+f),d=i/(v.depth-1||1),Xn(l,function(S){g=(S.getLayout().x+f)*p,y=(S.depth-1)*d;var _=ii(g,y);S.setLayout({x:_.x,y:_.y,rawX:g,rawY:y},!0)});else{var m=r.getOrient();m==="RL"||m==="LR"?(d=i/(c.getLayout().x+h+f),p=n/(v.depth-1||1),Xn(l,function(S){y=(S.getLayout().x+f)*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+h+f),d=i/(v.depth-1||1),Xn(l,function(S){g=(S.getLayout().x+f)*p,y=m==="TB"?(S.depth-1)*d:i-(S.depth-1)*d,S.setLayout({x:g,y},!0)}))}}}function VL(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");z(s,o)})})}function BL(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=vh(i,e,void 0,a);n.setCenter&&n.setCenter(o.center),n.setZoom&&n.setZoom(o.zoom)})})}function zL(r){r.registerChartView(wL),r.registerSeriesModel(EL),r.registerLayout(NL),r.registerVisual(VL),BL(r)}var Gd=["treemapZoomToNode","treemapRender","treemapMove"];function GL(r){for(var e=0;e<Gd.length;e++)r.registerAction({type:Gd[e],update:"updateView"},pe);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=Ni(t,s,i);if(l){var u=i.getViewRoot();u&&(t.direction=ph(u,l.node)?"rollUp":"drillDown"),i.resetViewRoot(l.node)}}})}function sx(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=xc(r.ecModel,i.name||i.dataIndex+"",a);n.setVisual("decal",o)})}var FL=(function(r){E(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};lx(n);var i=t.levels||[],o=this.designatedVisualItemStyle={},s=new mt({itemStyle:o},this,a);i=t.levels=HL(i,a);var l=G(i||[],function(v){return new mt(v,s,a)},this),u=fh.createTree(n,this,c);function c(v){v.wrapMethod("getItemModel",function(h,f){var p=u.getNodeByDataIndex(f),d=p?l[p.depth]:null;return h.parentModel=d||s,h})}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 jt("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||{},z(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var a=this._idIndexMap;a||(a=this._idIndexMap=$(),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(){sx(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,scaleLimit:null,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})(Ct);function lx(r){var e=0;w(r.children,function(a){lx(a);var n=a.value;B(n)&&(n=n[0]),e+=n});var t=r.value;B(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),B(r.value)?r.value[0]=t:r.value=t}function HL(r,e){var t=xt(e.get("color")),a=xt(e.get(["aria","decal","decals"]));if(t){r=r||[];var n,i;w(r,function(s){var l=new mt(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}}var WL=8,Fd=8,lu=5,UL=(function(){function r(e){this.group=new et,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),il(o,v.pos,v.box)}},r.prototype._prepare=function(e,t,a){for(var n=e;n;n=n.parentNode){var i=Yt(n.getModel().get("name"),""),o=a.getTextRect(i),s=Math.max(o.width+WL*2,t.emptyItemWidth);t.totalWidth+=s+Fd,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=jA(t.pos,t.box),h=t.totalWidth,f=t.renderList,p=n.getModel("itemStyle").getItemStyle(),d=f.length-1;d>=0;d--){var g=f[d],y=g.node,m=g.width,S=g.text;h>v.width&&(h-=m-u,m=u,S=null);var _=new ke({shape:{points:YL(l,0,m,c,d===f.length-1,d===0)},style:Q(a.getItemStyle(),{lineJoin:"bevel"}),textContent:new vt({style:Dt(i,{text:S})}),textConfig:{position:"inside"},z2:bn*1e4,onclick:tt(s,y)});_.disableLabelAnimation=!0,_.getTextContent().ensureState("emphasis").style=Dt(o,{text:S}),_.ensureState("emphasis").style=p,kt(_,n.get("focus"),n.get("blurScope"),n.get("disabled")),this.group.add(_),ZL(_,e,y),l+=m+Fd}},r.prototype.remove=function(){this.group.removeAll()},r})();function YL(r,e,t,a,n,i){var o=[[n?r:r-lu,e],[r+t,e],[r+t,e+a],[n?r:r-lu,e+a]];return!i&&o.splice(2,0,[r+t+lu,e+a/2]),!n&&o.push([r,e+a/2]),o}function ZL(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)}}var $L=(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 XL(){return new $L}var Hc=et,Hd=dt,Wd=3,Ud="label",Yd="upperLabel",KL=bn*10,qL=bn*2,jL=bn*3,ta=_a([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Zd=function(r){var e=ta(r);return e.stroke=e.fill=e.lineWidth=null,e},Ls=ut(),JL=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._state="ready",t._storage=Kn(),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=Ni(i,s,t),u=i&&i.type,c=t.layoutInfo,v=!this._oldTree,h=this._storage,f=u==="treemapRootToNode"&&l&&h?{rootNodeGroup:h.nodeGroup[l.node.getRawIndex()],direction:i.direction}:null,p=this._giveContainerGroup(c),d=t.get("animation"),g=this._doRender(p,t,f);d&&!v&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(p,g,t,f):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=Kn(),l=Kn(),u=this._storage,c=[];function v(m,S,_,x){return QL(a,l,u,n,s,c,m,S,_,x)}d(i.root?[i.root]:[],o&&o.root?[o.root]:[],t,i===o||!o,0);var h=g(u);if(this._oldTree=i,this._storage=l,this._controllerHost){var f=this.seriesModel.layoutInfo,p=i.root.getLayout();p.width===f.width&&p.height===f.height&&(this._controllerHost.zoom=1)}return{lastsForAnimation:s,willDeleteEls:h,renderFinally:y};function d(m,S,_,x,b){x?(S=m,w(m,function(D,C){!D.isRemoved()&&T(C,C)})):new dr(S,m,A,A).add(T).update(T).remove(tt(T,null)).execute();function A(D){return D.getId()}function T(D,C){var M=D!=null?m[D]:null,I=C!=null?S[C]:null,L=v(M,I,_,b);L&&d(M&&M.viewChildren||[],I&&I.viewChildren||[],L,x,b+1)}}function g(m){var S=Kn();return m&&w(m,function(_,x){var b=S[x];w(_,function(A){A&&(b.push(A),Ls(A).willDelete=!0)})}),S}function y(){w(h,function(m){w(m,function(S){S.parent&&S.parent.remove(S)})}),w(c,function(m){m.invisible=!0,m.dirty()})}},e.prototype._doAnimation=function(t,a,n,i){var o=n.get("animationDurationUpdate"),s=n.get("animationEasing"),l=(K(o)?0:o)||0,u=(K(s)?null:s)||"cubicOut",c=XL();w(a.willDeleteEls,function(v,h){w(v,function(f,p){if(!f.invisible){var d=f.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=h==="nodeGroup"?{x:m,y:S,style:{opacity:0}}:{shape:{x:m,y:S,width:0,height:0},style:{opacity:0}}}g&&c.add(f,g,l,0,u)}})}),w(this._storage,function(v,h){w(v,function(f,p){var d=a.lastsForAnimation[h][p],g={};d&&(f instanceof et?d.oldX!=null&&(g.x=f.x,g.y=f.y,f.x=d.oldX,f.y=d.oldY):(d.oldShape&&(g.shape=z({},f.shape),f.setShape(d.oldShape)),d.fadein?(f.setStyle("opacity",0),g.style={opacity:1}):f.style.opacity!==1&&(g.style={opacity:1})),c.add(f,g,l,0,u))})},this),this._state="animating",c.finished(U(function(){this._state="ready",a.renderFinally()},this)).start()},e.prototype._resetController=function(t){var a=this._controller,n=this._controllerHost;n||(this._controllerHost={target:this.group},n=this._controllerHost),a||(a=this._controller=new so(t.getZr()),a.enable(this.seriesModel.get("roam")),n.zoomLimit=this.seriesModel.get("scaleLimit"),n.zoom=this.seriesModel.get("zoom"),a.on("pan",U(this._onPan,this)),a.on("zoom",U(this._onZoom,this)));var i=new wt(0,0,t.getWidth(),t.getHeight());a.setPointerChecker(function(o,s,l){return i.contain(s,l)})},e.prototype._clearController=function(){var t=this._controller;this._controllerHost=null,t&&(t.dispose(),t=null)},e.prototype._onPan=function(t){if(this._state!=="animating"&&(Math.abs(t.dx)>Wd||Math.abs(t.dy)>Wd)){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,i=t.scale;if(this._state!=="animating"){var o=this.seriesModel.getData().tree.root;if(!o)return;var s=o.getLayout();if(!s)return;var l=new wt(s.x,s.y,s.width,s.height),u=null,c=this._controllerHost;u=c.zoomLimit;var v=c.zoom=c.zoom||1;if(v*=i,u){var h=u.min||0,f=u.max||1/0;v=Math.max(Math.min(f,v),h)}var p=v/c.zoom;c.zoom=v;var d=this.seriesModel.layoutInfo;a-=d.x,n-=d.y;var g=_n();Sa(g,g,[-a,-n]),Ab(g,g,[p,p]),Sa(g,g,[a,n]),l.applyTransform(g),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:l.x,y:l.y,width:l.width,height:l.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&&_s(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 UL(this.group))).render(t,a,n.node,function(o){i._state!=="animating"&&(ph(t.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=Kn(),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})(bt);function Kn(){return{nodeGroup:[],background:[],content:[]}}function QL(r,e,t,a,n,i,o,s,l,u){if(!o)return;var c=o.getLayout(),v=r.getData(),h=o.getModel();if(v.setItemGraphicEl(o.dataIndex,null),!c||!c.isInView)return;var f=c.width,p=c.height,d=c.borderWidth,g=c.invisible,y=o.getRawIndex(),m=s&&s.getRawIndex(),S=o.viewChildren,_=c.upperHeight,x=S&&S.length,b=h.getModel("itemStyle"),A=h.getModel(["emphasis","itemStyle"]),T=h.getModel(["blur","itemStyle"]),D=h.getModel(["select","itemStyle"]),C=b.get("borderRadius")||0,M=st("nodeGroup",Hc);if(!M)return;if(l.add(M),M.x=c.x||0,M.y=c.y||0,M.markRedraw(),Ls(M).nodeWidth=f,Ls(M).nodeHeight=p,c.isAboveViewRoot)return M;var I=st("background",Hd,u,qL);I&&F(M,I,x&&c.upperLabelHeight);var L=h.getModel("emphasis"),R=L.get("focus"),P=L.get("blurScope"),k=L.get("disabled"),O=R==="ancestor"?o.getAncestorsIndices():R==="descendant"?o.getDescendantIndices():R;if(x)Ti(M)&&la(M,!1),I&&(la(I,!k),v.setItemGraphicEl(o.dataIndex,I),fc(I,O,P));else{var N=st("content",Hd,u,jL);N&&W(M,N),I.disableMorphing=!0,I&&Ti(I)&&la(I,!1),la(M,!k),v.setItemGraphicEl(o.dataIndex,M);var V=h.getShallow("cursor");V&&N.attr("cursor",V),fc(M,O,P)}return M;function F(ht,ot,It){var At=q(ot);if(At.dataIndex=o.dataIndex,At.seriesIndex=r.seriesIndex,ot.setShape({x:0,y:0,width:f,height:p,r:C}),g)X(ot);else{ot.invisible=!1;var Et=o.getVisual("style"),$t=Et.stroke,Xt=Zd(b);Xt.fill=$t;var Lt=ta(A);Lt.fill=A.get("borderColor");var zt=ta(T);zt.fill=T.get("borderColor");var le=ta(D);if(le.fill=D.get("borderColor"),It){var xr=f-2*d;rt(ot,$t,Et.opacity,{x:d,y:0,width:xr,height:_})}else ot.removeTextContent();ot.setStyle(Xt),ot.ensureState("emphasis").style=Lt,ot.ensureState("blur").style=zt,ot.ensureState("select").style=le,wa(ot)}ht.add(ot)}function W(ht,ot){var It=q(ot);It.dataIndex=o.dataIndex,It.seriesIndex=r.seriesIndex;var At=Math.max(f-2*d,0),Et=Math.max(p-2*d,0);if(ot.culling=!0,ot.setShape({x:d,y:d,width:At,height:Et,r:C}),g)X(ot);else{ot.invisible=!1;var $t=o.getVisual("style"),Xt=$t.fill,Lt=Zd(b);Lt.fill=Xt,Lt.decal=$t.decal;var zt=ta(A),le=ta(T),xr=ta(D);rt(ot,Xt,$t.opacity,null),ot.setStyle(Lt),ot.ensureState("emphasis").style=zt,ot.ensureState("blur").style=le,ot.ensureState("select").style=xr,wa(ot)}ht.add(ot)}function X(ht){!ht.invisible&&i.push(ht)}function rt(ht,ot,It,At){var Et=h.getModel(At?Yd:Ud),$t=Yt(h.get("name"),null),Xt=Et.getShallow("show");ae(ht,qt(h,At?Yd:Ud),{defaultText:Xt?$t:null,inheritColor:ot,defaultOpacity:It,labelFetcher:r,labelDataIndex:o.dataIndex});var Lt=ht.getTextContent();if(Lt){var zt=Lt.style,le=Em(zt.padding||0);At&&(ht.setTextConfig({layoutRect:At}),Lt.disableLabelLayout=!0),Lt.beforeUpdate=function(){var ir=Math.max((At?At.width:ht.shape.width)-le[1]-le[3],0),co=Math.max((At?At.height:ht.shape.height)-le[0]-le[2],0);(zt.width!==ir||zt.height!==co)&&Lt.setStyle({width:ir,height:co})},zt.truncateMinChar=2,zt.lineOverflow="truncate",at(zt,At,c);var xr=Lt.getState("emphasis");at(xr?xr.style:null,At,c)}}function at(ht,ot,It){var At=ht?ht.text:null;if(!ot&&It.isLeafRoot&&At!=null){var Et=r.get("drillDownIcon",!0);ht.text=Et?Et+" "+At:At}}function st(ht,ot,It,At){var Et=m!=null&&t[ht][m],$t=n[ht];return Et?(t[ht][m]=null,Vt($t,Et)):g||(Et=new ot,Et instanceof ma&&(Et.z2=tP(It,At)),me($t,Et)),e[ht][y]=Et}function Vt(ht,ot){var It=ht[y]={};ot instanceof Hc?(It.oldX=ot.x,It.oldY=ot.y):It.oldShape=z({},ot.shape)}function me(ht,ot){var It=ht[y]={},At=o.parentNode,Et=ot instanceof et;if(At&&(!a||a.direction==="drillDown")){var $t=0,Xt=0,Lt=n.background[At.getRawIndex()];!a&&Lt&&Lt.oldShape&&($t=Lt.oldShape.width,Xt=Lt.oldShape.height),Et?(It.oldX=0,It.oldY=Xt):It.oldShape={x:$t,y:Xt,width:0,height:0}}It.fadein=!Et}}function tP(r,e){return r*KL+e}var Oi=w,eP=J,Ps=-1,Kt=(function(){function r(e){var t=e.mappingMethod,a=e.type,n=this.option=j(e);this.type=a,this.mappingMethod=t,this._normalizeData=nP[t];var i=r.visualHandlers[a];this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[t],t==="piecewise"?(uu(n),rP(n)):t==="category"?n.categories?aP(n):uu(n,!0):(Se(t!=="linear"||n.dataExtent),uu(n))}return r.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},r.prototype.getNormalizer=function(){return U(this._normalizeData,this)},r.listVisualTypes=function(){return Ut(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=B(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&&Oi(r.visualHandlers,function(n,i){e.hasOwnProperty(i)&&(t[i]=e[i],a=!0)}),a?t:null},r.prepareVisualTypes=function(e){if(B(e))e=e.slice();else if(eP(e)){var t=[];Oi(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||Y(l)&&l===e+"")return o;a&&h(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(Ro(v[1],e,c[1]))return o}else if(c[1]===1/0){if(Ro(v[0],c[0],e))return o}else if(Ro(v[0],c[0],e)&&Ro(v[1],e,c[1]))return o;a&&h(c[0],o),a&&h(c[1],o)}}if(a)return e===1/0?t.length-1:e===-1/0?0:n;function h(f,p){var d=Math.abs(f-e);d<i&&(i=d,n=p)}},r.visualHandlers={color:{applyVisual:qn("color"),getColorMapper:function(){var e=this.option;return U(e.mappingMethod==="category"?function(t,a){return!a&&(t=this._normalizeData(t)),oi.call(this,t)}:function(t,a,n){var i=!!n;return!a&&(t=this._normalizeData(t)),n=bl(t,e.parsedVisual,n),i?n:Xo(n,"rgba")},this)},_normalizedToVisual:{linear:function(e){return Xo(bl(e,this.option.parsedVisual),"rgba")},category:oi,piecewise:function(e,t){var a=Uc.call(this,t);return a==null&&(a=Xo(bl(e,this.option.parsedVisual),"rgba")),a},fixed:ea}},colorHue:Po(function(e,t){return ui(e,t)}),colorSaturation:Po(function(e,t){return ui(e,null,t)}),colorLightness:Po(function(e,t){return ui(e,null,null,t)}),colorAlpha:Po(function(e,t){return fs(e,t)}),decal:{applyVisual:qn("decal"),_normalizedToVisual:{linear:null,category:oi,piecewise:null,fixed:null}},opacity:{applyVisual:qn("opacity"),_normalizedToVisual:Wc([0,1])},liftZ:{applyVisual:qn("liftZ"),_normalizedToVisual:{linear:ea,category:ea,piecewise:ea,fixed:ea}},symbol:{applyVisual:function(e,t,a){var n=this.mapValueToVisual(e);a("symbol",n)},_normalizedToVisual:{linear:$d,category:oi,piecewise:function(e,t){var a=Uc.call(this,t);return a==null&&(a=$d.call(this,e)),a},fixed:ea}},symbolSize:{applyVisual:qn("symbolSize"),_normalizedToVisual:Wc([0,1])}},r})();function rP(r){var e=r.pieceList;r.hasSpecialVisual=!1,w(e,function(t,a){t.originIndex=a,t.visual!=null&&(r.hasSpecialVisual=!0)})}function aP(r){var e=r.categories,t=r.categoryMap={},a=r.visual;if(Oi(e,function(o,s){t[o]=s}),!B(a)){var n=[];J(a)?Oi(a,function(o,s){var l=t[s];n[l??Ps]=o}):n[Ps]=a,a=ux(r,n)}for(var i=e.length-1;i>=0;i--)a[i]==null&&(delete t[e[i]],e.pop())}function uu(r,e){var t=r.visual,a=[];J(t)?Oi(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]),ux(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 $d(r){var e=this.option.visual;return e[Math.round(yt(r,[0,1],[0,e.length-1],!0))]||{}}function qn(r){return function(e,t,a){a(r,this.mapValueToVisual(e))}}function oi(r){var e=this.option.visual;return e[this.option.loop&&r!==Ps?r%e.length:r]}function ea(){return this.option.visual[0]}function Wc(r){return{linear:function(e){return yt(e,r,this.option.visual,!0)},category:oi,piecewise:function(e,t){var a=Uc.call(this,t);return a==null&&(a=yt(e,r,this.option.visual,!0)),a},fixed:ea}}function Uc(r){var e=this.option,t=e.pieceList;if(e.hasSpecialVisual){var a=Kt.findPieceIndex(r,t),n=t[a];if(n&&n.visual)return n.visual[this.type]}}function ux(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 nP={linear:function(r){return yt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var e=this.option.pieceList,t=Kt.findPieceIndex(r,e,!0);if(t!=null)return yt(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:pe};function Ro(r,e,t){return r?e<=t:e<t}var iP="itemStyle",cx=ut();const oP={seriesType:"treemap",reset:function(r){var e=r.getData().tree,t=e.root;t.isRemoved()||vx(t,{},r.getViewRoot().getAncestors(),r)}};function vx(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(iP),l=sP(s,e,a),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),c=s.get("borderColor"),v=s.get("borderColorSaturation"),h;v!=null&&(h=Xd(l),c=lP(v,h)),u.stroke=c;var f=r.viewChildren;if(!f||!f.length)h=Xd(l),u.fill=h;else{var p=uP(r,n,i,s,l,f);w(f,function(d,g){if(d.depth>=t.length||d===t[d.depth]){var y=cP(n,l,d,g,p,a);vx(d,y,t,a)}})}}}function sP(r,e,t){var a=z({},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 Xd(r){var e=cu(r,"color");if(e){var t=cu(r,"colorAlpha"),a=cu(r,"colorSaturation");return a&&(e=ui(e,null,null,a)),t&&(e=fs(e,t)),e}}function lP(r,e){return e!=null?ui(e,null,null,r):null}function cu(r,e){var t=r[e];if(t!=null&&t!=="none")return t}function uP(r,e,t,a,n,i){if(!(!i||!i.length)){var o=vu(e,"color")||n.color!=null&&n.color!=="none"&&(vu(e,"colorAlpha")||vu(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 h=new Kt(v);return cx(h).drColorMappingBy=c,h}}}function vu(r,e){var t=r.get(e);return B(t)&&t.length?{name:e,range:t}:null}function cP(r,e,t,a,n,i){var o=z({},e);if(n){var s=n.type,l=s==="color"&&cx(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 Vi=Math.max,Rs=Math.min,Kd=Qt,dh=w,hx=["itemStyle","borderWidth"],vP=["itemStyle","gapWidth"],hP=["upperLabel","show"],fP=["upperLabel","height"];const pP={seriesType:"treemap",reset:function(r,e,t,a){var n=t.getWidth(),i=t.getHeight(),o=r.option,s=Zt(r.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),l=o.size||[],u=H(Kd(s.width,l[0]),n),c=H(Kd(s.height,l[1]),i),v=a&&a.type,h=["treemapZoomToNode","treemapRootToNode"],f=Ni(a,h,r),p=v==="treemapRender"||v==="treemapMove"?a.rootRect:null,d=r.getViewRoot(),g=ox(d);if(v!=="treemapMove"){var y=v==="treemapZoomToNode"?_P(r,f,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:0,y:0,width:y[0],height:y[1],area:y[0]*y[1]};d.setLayout(_),fx(d,S,!1,0),_=d.getLayout(),dh(g,function(b,A){var T=(g[A+1]||d).getValue();b.setLayout(z({dataExtent:[T,T],borderWidth:0,upperHeight:0},_))})}var x=r.getData().tree.root;x.setLayout(xP(s,p,f),!0),r.setLayoutInfo(s),px(x,new wt(-s.x,-s.y,n,i),g,d,0)}};function fx(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(hx),u=s.get(vP)/2,c=dx(s),v=Math.max(l,c),h=l-u,f=v-u;r.setLayout({borderWidth:l,upperHeight:v,upperLabelHeight:c},!0),n=Vi(n-2*h,0),i=Vi(i-h-f,0);var p=n*i,d=dP(r,s,p,e,t,a);if(d.length){var g={x:h,y:f,width:n,height:i},y=Rs(n,i),m=1/0,S=[];S.area=0;for(var _=0,x=d.length;_<x;){var b=d[_];S.push(b),S.area+=b.getLayout().area;var A=SP(S,y,e.squareRatio);A<=m?(_++,m=A):(S.area-=S.pop().getLayout().area,qd(S,y,g,u,!1),y=Rs(g.width,g.height),S.length=S.area=0,m=1/0)}if(S.length&&qd(S,y,g,u,!0),!t){var T=s.get("childrenVisibleMin");T!=null&&p<T&&(t=!0)}for(var _=0,x=d.length;_<x;_++)fx(d[_],e,t,a+1)}}}function dP(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=_t(o,function(f){return!f.isRemoved()}),yP(o,s);var u=mP(e,o,s);if(u.sum===0)return r.viewChildren=[];if(u.sum=gP(e,t,u.sum,s,o),u.sum===0)return r.viewChildren=[];for(var c=0,v=o.length;c<v;c++){var h=o[c].getValue()/u.sum*t;o[c].setLayout({area:h})}return l&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function gP(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 yP(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 mP(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],dh(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 SP(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?Vi(u*a/l,l/(u*n)):1/0}function qd(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,h=r.length;v<h;v++){var f=r[v],p={},d=c?f.getLayout().area/c:0,g=p[l[o]]=Vi(c-2*a,0),y=t[s[i]]+t[l[i]]-u,m=v===h-1||y<d?y:d,S=p[l[i]]=Vi(m-2*a,0);p[s[o]]=t[s[o]]+Rs(a,g/2),p[s[i]]=u+Rs(a,S/2),u+=m,f.setLayout(p,!0)}t[s[o]]+=c,t[l[o]]-=c}function _P(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,h=0,f=v.length;h<f;h++)c+=v[h].getValue();var p=i.getValue();if(p===0)return o;u*=c/p;var d=s.getModel(),g=d.get(hx),y=Math.max(g,dx(d));u+=4*g*g+(3*g+y)*Math.pow(u,.5),u>ff&&(u=ff),i=s}u<l&&(u=l);var m=Math.pow(u/l,.5);return[a*m,n*m]}function xP(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 px(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);dh(r.viewChildren||[],function(u){px(u,l,t,a,n+1)})}}function dx(r){return r.get(hP)?r.get(fP):0}function bP(r){r.registerSeriesModel(FL),r.registerChartView(JL),r.registerVisual(oP),r.registerLayout(pP),GL(r)}function wP(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){St(u)&&(u=o[u]);for(var c=0;c<e.length;c++)if(!e[c].isSelected(u))return!1}return!0})})}function AP(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 h=l.getShallow(c[v],!0);h!=null&&a.setItemVisual(o,c[v],h)}}),a.count()&&n.each(function(o){var s=n.getItemModel(o),l=s.getShallow("category");if(l!=null){Y(l)&&(l=i["ec-"+l]);var u=a.getItemVisual(l,"style"),c=n.ensureUniqueItemVisual(o,"style");z(c,u);for(var v=["symbol","symbolSize","symbolKeepAspect"],h=0;h<v.length;h++)n.setItemVisual(o,v[h],a.getItemVisual(l,v[h]))}})})}function Eo(r){return r instanceof Array||(r=[r,r]),r}function TP(r){r.eachSeriesByType("graph",function(e){var t=e.getGraph(),a=e.getEdgeData(),n=Eo(e.get("edgeSymbol")),i=Eo(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=Eo(s.getShallow("symbol",!0)),c=Eo(s.getShallow("symbolSize",!0)),v=s.getModel("lineStyle").getLineStyle(),h=a.ensureUniqueItemVisual(o,"style");switch(z(h,v),h.stroke){case"source":{var f=l.node1.getVisual("style");h.stroke=f&&f.fill;break}case"target":{var f=l.node2.getVisual("style");h.stroke=f&&f.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 Yc="-->",dl=function(r){return r.get("autoCurveness")||null},gx=function(r,e){var t=dl(r),a=20,n=[];if(St(t))a=t;else if(B(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},Bi=function(r,e,t){var a=[r.id,r.dataIndex].join("."),n=[e.id,e.dataIndex].join(".");return[t.uid,a,n].join(Yc)},yx=function(r){var e=r.split(Yc);return[e[0],e[2],e[1]].join(Yc)},DP=function(r,e){var t=Bi(r.node1,r.node2,e);return e.__edgeMap[t]},CP=function(r,e){var t=Zc(Bi(r.node1,r.node2,e),e),a=Zc(Bi(r.node2,r.node1,e),e);return t+a},Zc=function(r,e){var t=e.__edgeMap;return t[r]?t[r].length:0};function MP(r){dl(r)&&(r.__curvenessList=[],r.__edgeMap={},gx(r))}function IP(r,e,t,a){if(dl(t)){var n=Bi(r,e,t),i=t.__edgeMap,o=i[yx(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 gh(r,e,t,a){var n=dl(e),i=B(n);if(!n)return null;var o=DP(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=CP(r,e);gx(e,u),r.lineStyle=r.lineStyle||{};var c=Bi(r.node1,r.node2,e),v=e.__curvenessList,h=i||u%2?0:1;if(o.isForward)return v[h+s];var f=yx(c),p=Zc(f,e),d=v[s+p+h];return a?i?n&&n[0]===0?(p+h)%2?d:-d:((p%2?0:1)+h)%2?d:-d:(p+h)%2?d:-d:v[s+p+h]}function mx(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")])}),yh(t,r)}}function yh(r,e){r.eachEdge(function(t,a){var n=mn(t.getModel().get(["lineStyle","curveness"]),-gh(t,e,a,!0),0),i=kr(t.node1.getLayout()),o=kr(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 LP(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(h){o=o.concat(i.mapDimensionsAll(h))});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])}yh(i.graph,t)}else(!a||a==="none")&&mx(t)})}function si(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 li(r){var e=r.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),+e}var jd=Math.PI,hu=[];function mh(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 h=n.pointToData(a),f=h[0],p=h[1],d=[f-l,p-u];Zi(d,d),Tb(d,d,c),t.setLayout([l+d[0],u+d[1]],!0);var g=r.get(["circular","rotateLabel"]);Sx(t,g,l,u)}PP[e](r,s,o,c,l,u,v),s.eachEdge(function(y,m){var S=mn(y.getModel().get(["lineStyle","curveness"]),gh(y,r,m),0),_=kr(y.node1.getLayout()),x=kr(y.node2.getLayout()),b,A=(_[0]+x[0])/2,T=(_[1]+x[1])/2;+S&&(S*=3,b=[l*S+A*(1-S),u*S+T*(1-S)]),y.setLayout([_,x,b])})}}}var PP={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"),h=u*(l?v:1)/2;s+=h,c.setLayout([a*Math.cos(s)+n,a*Math.sin(s)+i]),s+=h})},symbolSize:function(r,e,t,a,n,i,o){var s=0;hu.length=o;var l=si(r);e.eachNode(function(v){var h=li(v);isNaN(h)&&(h=2),h<0&&(h=0),h*=l;var f=Math.asin(h/2/a);isNaN(f)&&(f=jd/2),hu[v.dataIndex]=f,s+=f*2});var u=(2*jd-s)/o/2,c=0;e.eachNode(function(v){var h=u+hu[v.dataIndex];c+=h,(!v.getLayout()||!v.getLayout().fixed)&&v.setLayout([a*Math.cos(c)+n,a*Math.sin(c)+i]),c+=h})}};function Sx(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 h=s.ensureState("emphasis");z(h.textConfig||(h.textConfig={}),{position:v})}else s.setTextConfig({rotation:o*=Math.PI/180})}}function RP(r){r.eachSeriesByType("graph",function(e){e.get("layout")==="circular"&&mh(e,"symbolSize")})}var Wa=sc;function EP(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=Db(o*(Math.random()-.5)+l[0],s*(Math.random()-.5)+l[1])),v.pp=kr(v.p),v.edges=null}var h=t.friction==null?.6:t.friction,f=h,p,d;return{warmUp:function(){f=h*.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 _=n[S];if(!_.ignoreForceLayout){var x=_.n1,b=_.n2;Qa(y,b.p,x.p);var A=uf(y)-_.d,T=b.w/(x.w+b.w);isNaN(T)&&(T=0),Zi(y,y),!x.fixed&&Wa(x.p,x.p,y,T*A*f),!b.fixed&&Wa(b.p,b.p,y,-(1-T)*A*f)}}for(var S=0;S<m;S++){var D=a[S];D.fixed||(Qa(y,l,D.p),Wa(D.p,D.p,y,u*f))}for(var S=0;S<m;S++)for(var x=a[S],C=S+1;C<m;C++){var b=a[C];Qa(y,b.p,x.p);var A=uf(y);A===0&&(Cb(y,Math.random()-.5,Math.random()-.5),A=1);var M=(x.rep+b.rep)/A/A;!x.fixed&&Wa(x.pp,x.pp,y,M),!b.fixed&&Wa(b.pp,b.pp,y,-M)}for(var I=[],S=0;S<m;S++){var D=a[S];D.fixed||(Qa(I,D.p,D.pp),Wa(D.p,D.p,I,f),ce(D.pp,D.p))}f=f*.992;var L=f<.01;d&&d(a,n,L),g&&g(L)}}}function kP(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 _=i.getId(S);i.setItemLayout(S,a[_]||[NaN,NaN])}):!l||l==="none"?mx(e):l==="circular"&&mh(e,"value");var u=i.getDataExtent("value"),c=o.getDataExtent("value"),v=s.get("repulsion"),h=s.get("edgeLength"),f=B(v)?v:[v,v],p=B(h)?h:[h,h];p=[p[1],p[0]];var d=i.mapArray("value",function(S,_){var x=i.getItemLayout(_),b=yt(S,u,f);return isNaN(b)&&(b=(f[0]+f[1])/2),{w:b,rep:b,fixed:i.getItemModel(_).get("fixed"),p:!x||isNaN(x[0])||isNaN(x[1])?null:x}}),g=o.mapArray("value",function(S,_){var x=n.getEdgeByIndex(_),b=yt(S,c,p);isNaN(b)&&(b=(p[0]+p[1])/2);var A=x.getModel(),T=mn(x.getModel().get(["lineStyle","curveness"]),-gh(x,e,_,!0),0);return{n1:d[x.node1.dataIndex],n2:d[x.node2.dataIndex],d:b,curveness:T,ignoreForceLayout:A.get("ignoreForceLayout")}}),y=t.getBoundingRect(),m=EP(d,g,{rect:y,gravity:s.get("gravity"),friction:s.get("friction")});m.beforeStep(function(S,_){for(var x=0,b=S.length;x<b;x++)S[x].fixed&&ce(S[x].p,n.getNodeByIndex(x).getLayout())}),m.afterStep(function(S,_,x){for(var b=0,A=S.length;b<A;b++)S[b].fixed||n.getNodeByIndex(b).setLayout(S[b].p),a[i.getId(b)]=S[b].p;for(var b=0,A=_.length;b<A;b++){var T=_[b],D=n.getEdgeByIndex(b),C=T.n1.p,M=T.n2.p,I=D.getLayout();I=I?I.slice():[],I[0]=I[0]||[],I[1]=I[1]||[],ce(I[0],C),ce(I[1],M),+T.curveness&&(I[2]=[(C[0]+M[0])/2-(C[1]-M[1])*T.curveness,(C[1]+M[1])/2-(M[0]-C[0])*T.curveness]),D.setLayout(I)}}),e.forceLayout=m,e.preservedPoints=a,m.step()}else e.forceLayout=null})}function NP(r,e,t){var a=z(r.getBoxLayoutParams(),{aspect:t});return Zt(a,{width:e.getWidth(),height:e.getHeight()})}function OP(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=NP(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],h=l[1]-s[1],f=c.width,p=c.height,d=a.coordinateSystem=new lo;d.zoomLimit=a.get("scaleLimit"),d.setBoundingRect(s[0],s[1],v,h),d.setViewRect(c.x,c.y,f,p),d.setCenter(a.get("center"),e),d.setZoom(a.get("zoom")),t.push(d)}}),t}var Jd=ee.prototype,fu=Ws.prototype,_x=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})();(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e})(_x);function pu(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var VP=(function(r){E(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 _x},e.prototype.buildPath=function(t,a){pu(a)?Jd.buildPath.call(this,t,a):fu.buildPath.call(this,t,a)},e.prototype.pointAt=function(t){return pu(this.shape)?Jd.pointAt.call(this,t):fu.pointAt.call(this,t)},e.prototype.tangentAt=function(t){var a=this.shape,n=pu(a)?[a.x2-a.x1,a.y2-a.y1]:fu.tangentAt.call(this,t);return Zi(n,n)},e})(Mt),du=["fromSymbol","toSymbol"];function Qd(r){return"_"+r+"Type"}function tg(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=In(n),u=La(o||0,l);return a+l+u+(i||"")+(s||"")}function eg(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=In(n),u=La(o||0,l),c=Wt(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 BP(r){var e=new VP({name:"line",subPixelOptimize:!0});return $c(e.shape,r),e}function $c(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 Sh=(function(r){E(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=BP(o);s.shape.percent=0,Pt(s,{shape:{percent:1}},i,a),this.add(s),w(du,function(l){var u=eg(l,t,a);this.add(u),this[Qd(l)]=tg(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:{}};$c(l.shape,s),ft(o,l,i,a),w(du,function(u){var c=tg(u,t,a),v=Qd(u);if(this[v]!==c){this.remove(this.childOfName(u));var h=eg(u,t,a);this.add(h)}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,h=n&&n.focus,f=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"),h=d.get("focus"),f=d.get("blurScope"),c=qt(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(du,function(b){var A=this.childOfName(b);if(A){A.setColor(y),A.style.opacity=g.opacity;for(var T=0;T<de.length;T++){var D=de[T],C=o.getState(D);if(C){var M=C.style||{},I=A.ensureState(D),L=I.style||(I.style={});M.stroke!=null&&(L[A.__isEmptyBrush?"stroke":"fill"]=M.stroke),M.opacity!=null&&(L.opacity=M.opacity)}}A.markRedraw()}},this);var m=i.getRawValue(a);ae(this,c,{labelDataIndex:a,labelFetcher:{getFormattedLabel:function(b,A){return i.getFormattedLabel(b,A,t.dataType)}},inheritColor:y||"#000",defaultOpacity:g.opacity,defaultText:(m==null?t.getName(a):isFinite(m)?Ot(m):m)+""});var S=this.getTextContent();if(S){var _=c.normal;S.__align=S.style.align,S.__verticalAlign=S.style.verticalAlign,S.__position=_.get("position")||"middle";var x=_.get("distance");B(x)||(x=[x,x]),S.__labelDistance=x}this.setTextConfig({position:null,local:!0,inside:!1}),kt(this,h,f,v)},e.prototype.highlight=function(){fr(this)},e.prototype.downplay=function(){pr(this)},e.prototype.updateLayout=function(t,a){this.setLinePoints(t.getItemLayout(a))},e.prototype.setLinePoints=function(t){var a=this.childOfName("line");$c(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),h=Qa([],v,c);Zi(h,h);function f(C,M){var I=C.__specifiedRotation;if(I==null){var L=l.tangentAt(M);C.attr("rotation",(M===1?-1:1)*Math.PI/2-Math.atan2(L[1],L[0]))}else C.attr("rotation",I)}if(a&&(a.setPosition(c),f(a,0),a.scaleX=a.scaleY=o*u,a.markRedraw()),n&&(n.setPosition(v),f(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,_=l.tangentAt(S),x=[_[1],-_[0]],b=l.pointAt(S);x[1]>0&&(x[0]=-x[0],x[1]=-x[1]);var A=_[0]<0?-1:1;if(i.__position!=="start"&&i.__position!=="end"){var T=-Math.atan2(_[1],_[0]);v[0]<c[0]&&(T=Math.PI+T),i.rotation=T}var D=void 0;switch(i.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":D=-m,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":D=m,d="top";break;default:D=0,d="middle"}switch(i.__position){case"end":i.x=h[0]*y+v[0],i.y=h[1]*m+v[1],p=h[0]>.8?"left":h[0]<-.8?"right":"center",d=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*y+c[0],i.y=-h[1]*m+c[1],p=h[0]>.8?"right":h[0]<-.8?"left":"center",d=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=y*A+c[0],i.y=c[1]+D,p=_[0]<0?"right":"left",i.originX=-y*A,i.originY=-D;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=b[0],i.y=b[1]+D,p="center",i.originY=-D;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-y*A+v[0],i.y=v[1]+D,p=_[0]>=0?"right":"left",i.originX=y*A,i.originY=-D;break}i.scaleX=i.scaleY=o,i.setStyle({verticalAlign:i.__verticalAlign||d,align:i.__align||p})}},e})(et),_h=(function(){function r(e){this.group=new et,this._LineCtor=e||Sh}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=rg(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=rg(e),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(e,t){this._progressiveEls=[];function a(s){!s.isGroup&&!zP(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var n=e.start;n<e.end;n++){var i=t.getItemLayout(n);if(gu(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){Ur(this._progressiveEls||this.group,e)},r.prototype._doAdd=function(e,t,a){var n=e.getItemLayout(t);if(gu(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(!gu(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 zP(r){return r.animators&&r.animators.length>0}function rg(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:qt(e)}}function ag(r){return isNaN(r[0])||isNaN(r[1])}function gu(r){return r&&!ag(r[0])&&!ag(r[1])}var yu=[],mu=[],Su=[],Ua=Gm,_u=Ib,ng=Math.abs;function ig(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){yu[0]=Ua(a[0],n[0],i[0],c),yu[1]=Ua(a[1],n[1],i[1],c);var v=ng(_u(yu,e)-l);v<o&&(o=v,s=c)}for(var h=0;h<32;h++){var f=s+u;mu[0]=Ua(a[0],n[0],i[0],s),mu[1]=Ua(a[1],n[1],i[1],s),Su[0]=Ua(a[0],n[0],i[0],f),Su[1]=Ua(a[1],n[1],i[1],f);var v=_u(mu,e)-l;if(ng(v)<.01)break;var p=_u(Su,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 xu(r,e){var t=[],a=Mb,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=[kr(u[0]),kr(u[1])],u[2]&&u.__original.push(kr(u[2])));var h=u.__original;if(u[2]!=null){if(ce(n[0],h[0]),ce(n[1],h[2]),ce(n[2],h[1]),c&&c!=="none"){var f=li(s.node1),p=ig(n,h[0],f*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 f=li(s.node2),p=ig(n,h[1],f*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],h[0]),ce(i[1],h[1]),Qa(o,i[1],i[0]),Zi(o,o),c&&c!=="none"){var f=li(s.node1);sc(i[0],i[0],o,f*e)}if(v&&v!=="none"){var f=li(s.node2);sc(i[1],i[1],o,-f*e)}ce(u[0],i[0]),ce(u[1],i[1])}})}function og(r){return r.type==="view"}var GP=(function(r){E(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 _h,o=this.group;this._controller=new so(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(og(o)){var c={x:o.x,y:o.y,scaleX:o.scaleX,scaleY:o.scaleY};this._firstRender?u.attr(c):ft(u,c,t)}xu(t.getGraph(),si(t));var v=t.getData();s.updateData(v);var h=t.getEdgeData();l.updateData(h),this._updateNodeAndLinkScale(),this._updateController(t,a,n),clearTimeout(this._layoutTimeout);var f=t.forceLayout,p=t.get(["force","layoutAnimation"]);f&&this._startForceLayoutIteration(f,p);var d=t.get("layout");v.graph.eachNode(function(S){var _=S.dataIndex,x=S.getGraphicEl(),b=S.getModel();if(x){x.off("drag").off("dragend");var A=b.get("draggable");A&&x.on("drag",function(D){switch(d){case"force":f.warmUp(),!i._layouting&&i._startForceLayoutIteration(f,p),f.setFixed(_),v.setItemLayout(_,[x.x,x.y]);break;case"circular":v.setItemLayout(_,[x.x,x.y]),S.setLayout({fixed:!0},!0),mh(t,"symbolSize",S,[D.offsetX,D.offsetY]),i.updateLayout(t);break;case"none":default:v.setItemLayout(_,[x.x,x.y]),yh(t.getGraph(),t),i.updateLayout(t);break}}).on("dragend",function(){f&&f.setUnfixed(_)}),x.setDraggable(A,!!b.get("cursor"));var T=b.get(["emphasis","focus"]);T==="adjacency"&&(q(x).focus=S.getAdjacentDataIndices())}}),v.graph.eachEdge(function(S){var _=S.getGraphicEl(),x=S.getModel().get(["emphasis","focus"]);_&&x==="adjacency"&&(q(_).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){Sx(S,g,y,m)}),this._firstRender=!1},e.prototype.dispose=function(){this.remove(),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 h=l.getBoundingRect();return h.applyTransform(l.transform),h.contain(c,v)&&!fl(u,n,t)}),!og(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){lh(s,u.dx,u.dy),n.dispatchAction({seriesId:t.id,type:"graphRoam",dx:u.dx,dy:u.dy})}).on("zoom",function(u){uh(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(),xu(t.getGraph(),si(t)),i._lineDraw.updateLayout(),n.updateLabelLayout()})},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,a=t.getData(),n=si(t);a.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(n)})},e.prototype.updateLayout=function(t){xu(t.getGraph(),si(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},e.prototype.remove=function(){clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},e.type="graph",e})(bt);function Ya(r){return"_EC_"+r}var FP=(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[Ya(e)]){var n=new ra(e,t);return n.hostGraph=this,this.nodes.push(n),a[Ya(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[Ya(e)]},r.prototype.addEdge=function(e,t,a){var n=this._nodesMap,i=this._edgesMap;if(St(e)&&(e=this.nodes[e]),St(t)&&(t=this.nodes[t]),e instanceof ra||(e=n[Ya(e)]),t instanceof ra||(t=n[Ya(t)]),!(!e||!t)){var o=e.id+"-"+t.id,s=new xx(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 ra&&(e=e.id),t instanceof ra&&(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 ra||(t=this._nodesMap[Ya(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})(),ra=(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=$(),t=$(),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})(),xx=(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=$(),t=$();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 bx(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(ra,bx("hostGraph","data"));Jt(xx,bx("hostGraph","edgeData"));function wx(r,e,t,a,n){for(var i=new FP(a),o=0;o<r.length;o++)i.addNode(Qt(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,h=c.target;i.addEdge(v,h,u)&&(l.push(c),s.push(Qt(Yt(c.id,null),v+" > "+h)),u++)}var f=t.get("coordinateSystem"),p;if(f==="cartesian2d"||f==="polar")p=_r(r,t);else{var d=Ji.get(f),g=d?d.dimensions||[]:[];ct(g,"value")<0&&g.concat(["value"]);var y=ji(r,{coordDimensions:g,encodeDefine:t.getEncode()}).dimensions;p=new he(y,t),p.initData(r)}var m=new he(["value"],t);return m.initData(l,s),n&&n(p,m),nx({mainData:p,struct:i,structAttr:"graph",datas:{node:p,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var HP=(function(r){E(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 no(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),xa(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){MP(this);var s=wx(i,n,this,!0,l);return w(s.edges,function(u){IP(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=mt.prototype.getModel;function h(p,d){var g=v.call(this,p,d);return g.resolveParentPath=f,g}c.wrapMethod("getItemModel",function(p){return p.resolveParentPath=f,p.getModel=h,p});function f(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),jt("nameValue",{name:c.join(" > "),value:o.value,noValue:o.value==null})}var v=gS({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:z({value:0},n)}),a=new he(["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})(Ct),WP={type:"graphRoam",event:"graphRoam",update:"none"};function UP(r){r.registerChartView(GP),r.registerSeriesModel(HP),r.registerProcessor(wP),r.registerVisual(AP),r.registerVisual(TP),r.registerLayout(LP),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,RP),r.registerLayout(kP),r.registerCoordinateSystem("graphView",{dimensions:lo.dimensions,create:OP}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},pe),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},pe),r.registerAction(WP,function(e,t,a){t.eachComponent({mainType:"series",query:e},function(n){var i=n.coordinateSystem,o=vh(i,e,void 0,a);n.setCenter&&n.setCenter(o.center),n.setZoom&&n.setZoom(o.zoom)})})}var YP=(function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r})(),ZP=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="pointer",a}return e.prototype.getDefaultShape=function(){return new YP},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})(Mt);function $P(r,e){var t=r.get("center"),a=e.getWidth(),n=e.getHeight(),i=Math.min(a,n),o=H(t[0],e.getWidth()),s=H(t[1],e.getHeight()),l=H(r.get("radius"),i/2);return{cx:o,cy:s,r:l}}function ko(r,e){var t=r==null?"":r+"";return e&&(Y(e)?t=e.replace("{value}",t):K(e)&&(t=e(r))),t}var XP=(function(r){E(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=$P(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"),h=v.get("roundCap"),f=h?ws:Ee,p=v.get("show"),d=v.getModel("lineStyle"),g=d.get("width"),y=[u,c];Nm(y,!l),u=y[0],c=y[1];for(var m=c-u,S=u,_=[],x=0;p&&x<i.length;x++){var b=Math.min(Math.max(i[x][0],0),1);c=u+m*b;var A=new f({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[x][1]}),A.setStyle(d.getLineStyle(["color","width"])),_.push(A),S=c}_.reverse(),w(_,function(D){return s.add(D)});var T=function(D){if(D<=0)return i[0][1];var C;for(C=0;C<i.length;C++)if(i[C][0]>=D&&(C===0?0:i[C-1][0])<D)return i[C][1];return i[C-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,h=o.cx,f=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"),_=t.get("splitNumber"),x=m.get("splitNumber"),b=H(y.get("length"),p),A=H(m.get("length"),p),T=s,D=(l-s)/_,C=D/x,M=y.getModel("lineStyle").getLineStyle(),I=m.getModel("lineStyle").getLineStyle(),L=y.get("distance"),R,P,k=0;k<=_;k++){if(R=Math.cos(T),P=Math.sin(T),y.get("show")){var O=L?L+c:c,N=new ee({shape:{x1:R*(p-O)+h,y1:P*(p-O)+f,x2:R*(p-b-O)+h,y2:P*(p-b-O)+f},style:M,silent:!0});M.stroke==="auto"&&N.setStyle({stroke:i(k/_)}),v.add(N)}if(S.get("show")){var O=S.get("distance")+L,V=ko(Ot(k/_*(g-d)+d),S.get("formatter")),F=i(k/_),W=R*(p-b-O)+h,X=P*(p-b-O)+f,rt=S.get("rotate"),at=0;rt==="radial"?(at=-T+2*Math.PI,at>Math.PI/2&&(at+=Math.PI)):rt==="tangential"?at=-T-Math.PI/2:St(rt)&&(at=rt*Math.PI/180),at===0?v.add(new vt({style:Dt(S,{text:V,x:W,y:X,verticalAlign:P<-.8?"top":P>.8?"bottom":"middle",align:R<-.4?"left":R>.4?"right":"center"},{inheritColor:F}),silent:!0})):v.add(new vt({style:Dt(S,{text:V,x:W,y:X,verticalAlign:"middle",align:"center"},{inheritColor:F}),silent:!0,originX:W,originY:X,rotation:at}))}if(m.get("show")&&k!==_){var O=m.get("distance");O=O?O+c:c;for(var st=0;st<=x;st++){R=Math.cos(T),P=Math.sin(T);var Vt=new ee({shape:{x1:R*(p-O)+h,y1:P*(p-O)+f,x2:R*(p-A-O)+h,y2:P*(p-A-O)+f},silent:!0,style:I});I.stroke==="auto"&&Vt.setStyle({stroke:i((k+st/x)/_)}),v.add(Vt),T+=C}T-=C}else T+=D}},e.prototype._renderPointer=function(t,a,n,i,o,s,l,u,c){var v=this.group,h=this._data,f=this._progressEls,p=[],d=t.get(["pointer","show"]),g=t.getModel("progress"),y=g.get("show"),m=t.getData(),S=m.mapDimension("value"),_=+t.get("min"),x=+t.get("max"),b=[_,x],A=[s,l];function T(C,M){var I=m.getItemModel(C),L=I.getModel("pointer"),R=H(L.get("width"),o.r),P=H(L.get("length"),o.r),k=t.get(["pointer","icon"]),O=L.get("offsetCenter"),N=H(O[0],o.r),V=H(O[1],o.r),F=L.get("keepAspect"),W;return k?W=Wt(k,N-R/2,V-P,R,P,null,F):W=new ZP({shape:{angle:-Math.PI/2,width:R,r:P,x:N,y:V}}),W.rotation=-(M+Math.PI/2),W.x=o.cx,W.y=o.cy,W}function D(C,M){var I=g.get("roundCap"),L=I?ws:Ee,R=g.get("overlap"),P=R?g.get("width"):c/m.count(),k=R?o.r-P:o.r-(C+1)*P,O=R?o.r:o.r-C*P,N=new L({shape:{startAngle:s,endAngle:M,cx:o.cx,cy:o.cy,clockwise:u,r0:k,r:O}});return R&&(N.z2=yt(m.get(S,C),[_,x],[100,0],!0)),N}(y||d)&&(m.diff(h).add(function(C){var M=m.get(S,C);if(d){var I=T(C,s);Pt(I,{rotation:-((isNaN(+M)?A[0]:yt(M,b,A,!0))+Math.PI/2)},t),v.add(I),m.setItemGraphicEl(C,I)}if(y){var L=D(C,s),R=g.get("clip");Pt(L,{shape:{endAngle:yt(M,b,A,R)}},t),v.add(L),cc(t.seriesIndex,m.dataType,C,L),p[C]=L}}).update(function(C,M){var I=m.get(S,C);if(d){var L=h.getItemGraphicEl(M),R=L?L.rotation:s,P=T(C,R);P.rotation=R,ft(P,{rotation:-((isNaN(+I)?A[0]:yt(I,b,A,!0))+Math.PI/2)},t),v.add(P),m.setItemGraphicEl(C,P)}if(y){var k=f[M],O=k?k.shape.endAngle:s,N=D(C,O),V=g.get("clip");ft(N,{shape:{endAngle:yt(I,b,A,V)}},t),v.add(N),cc(t.seriesIndex,m.dataType,C,N),p[C]=N}}).execute(),m.each(function(C){var M=m.getItemModel(C),I=M.getModel("emphasis"),L=I.get("focus"),R=I.get("blurScope"),P=I.get("disabled");if(d){var k=m.getItemGraphicEl(C),O=m.getItemVisual(C,"style"),N=O.fill;if(k instanceof Ne){var V=k.style;k.useStyle(z({image:V.image,x:V.x,y:V.y,width:V.width,height:V.height},O))}else k.useStyle(O),k.type!=="pointer"&&k.setColor(N);k.setStyle(M.getModel(["pointer","itemStyle"]).getItemStyle()),k.style.fill==="auto"&&k.setStyle("fill",i(yt(m.get(S,C),b,[0,1],!0))),k.z2EmphasisLift=0,re(k,M),kt(k,L,R,P)}if(y){var F=p[C];F.useStyle(m.getItemVisual(C,"style")),F.setStyle(M.getModel(["progress","itemStyle"]).getItemStyle()),F.z2EmphasisLift=0,re(F,M),kt(F,L,R,P)}}),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=Wt(s,a.cx-o/2+H(l[0],a.r),a.cy-o/2+H(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"),h=new et,f=[],p=[],d=t.isAnimationEnabled(),g=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(y){f[y]=new vt({silent:!0}),p[y]=new vt({silent:!0})}).update(function(y,m){f[y]=s._titleEls[m],p[y]=s._detailEls[m]}).execute(),l.each(function(y){var m=l.getItemModel(y),S=l.get(u,y),_=new et,x=i(yt(S,[c,v],[0,1],!0)),b=m.getModel("title");if(b.get("show")){var A=b.get("offsetCenter"),T=o.cx+H(A[0],o.r),D=o.cy+H(A[1],o.r),C=f[y];C.attr({z2:g?0:2,style:Dt(b,{x:T,y:D,text:l.getName(y),align:"center",verticalAlign:"middle"},{inheritColor:x})}),_.add(C)}var M=m.getModel("detail");if(M.get("show")){var I=M.get("offsetCenter"),L=o.cx+H(I[0],o.r),R=o.cy+H(I[1],o.r),P=H(M.get("width"),o.r),k=H(M.get("height"),o.r),O=t.get(["progress","show"])?l.getItemVisual(y,"style").fill:x,C=p[y],N=M.get("formatter");C.attr({z2:g?0:2,style:Dt(M,{x:L,y:R,text:ko(S,N),width:isNaN(P)?null:P,height:isNaN(k)?null:k,align:"center",verticalAlign:"middle"},{inheritColor:O})}),m0(C,{normal:M},S,function(F){return ko(F,N)}),d&&S0(C,y,l,t,{getFormattedLabel:function(F,W,X,rt,at,st){return ko(st?st.interpolatedValue:S,N)}}),_.add(C)}h.add(_)}),this.group.add(h),this._titleEls=f,this._detailEls=p},e.type="gauge",e})(bt),KP=(function(r){E(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 Rn(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})(Ct);function qP(r){r.registerChartView(XP),r.registerSeriesModel(KP)}var jP=["itemStyle","opacity"],JP=(function(r){E(e,r);function e(t,a){var n=r.call(this)||this,i=n,o=new xe,s=new vt;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(jP);c=c??1,n||Ue(i),i.useStyle(t.getItemVisual(a,"style")),i.style.lineJoin="round",n?(i.setShape({points:l.points}),i.style.opacity=0,Pt(i,{style:{opacity:c}},o,a)):ft(i,{style:{opacity:c},shape:{points:l.points}},o,a),re(i,s),this._updateLabel(t,a),kt(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"),h=v.fill;ae(o,qt(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:h,outsideFill:h});var f=c.linePoints;i.setShape({points:f}),n.textGuideLineConfig={anchor:f?new Ft(f[0][0],f[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}),Zv(n,$v(l),{stroke:h})},e})(ke),QP=(function(r){E(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 JP(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);Di(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})(bt),t2=(function(r){E(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 no(U(this.getData,this),U(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.getInitialData=function(t,a){return Rn(this,{coordDimensions:["value"],encodeDefaulter:tt(Pv,this)})},e.prototype._defaultLabelLine=function(t){xa(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})(Ct);function e2(r,e){return Zt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function r2(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 K(e)?n.sort(e):e!=="none"&&n.sort(function(l,u){return i?a[l]-a[u]:a[u]-a[l]}),n}function a2(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,h,f,p;if(c)o==="insideLeft"?(h=(u[0][0]+u[3][0])/2+5,f=(u[0][1]+u[3][1])/2,v="left"):o==="insideRight"?(h=(u[1][0]+u[2][0])/2-5,f=(u[1][1]+u[2][1])/2,v="right"):(h=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,f=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,v="center"),p=[[h,f],[h,f]];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,h=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,h=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,f=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,f=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,f=m-5,v="center"):(y=d+S,h=y+5,v="top")):o==="rightBottom"?(d=u[2][0],g=u[2][1],t==="horizontal"?(m=g+S,f=m+5,v="center"):(y=d+S,h=y+5,v="bottom")):o==="leftTop"?(d=u[0][0],g=t==="horizontal"?u[0][1]:u[1][1],t==="horizontal"?(m=g-S,f=m-5,v="center"):(y=d-S,h=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,f=m+5,v="center"):(y=d-S,h=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,f=m+5,v="center"):(y=d+S,h=y+5,v="left")),t==="horizontal"?(y=d,h=y):(m=g,f=m),p=[[d,g],[y,m]]}l.label={linePoints:p,x:h,y:f,verticalAlign:"middle",textAlign:v,inside:c}})}function n2(r,e){r.eachSeriesByType("funnel",function(t){var a=t.getData(),n=a.mapDimension("value"),i=t.get("sort"),o=e2(t,e),s=t.get("orient"),l=o.width,u=o.height,c=r2(a,i),v=o.x,h=o.y,f=s==="horizontal"?[H(t.get("minSize"),u),H(t.get("maxSize"),u)]:[H(t.get("minSize"),l),H(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,_=(S-m*(a.count()-1))/a.count(),x=function(R,P){if(s==="horizontal"){var k=a.get(n,R)||0,O=yt(k,[d,g],f,!0),N=void 0;switch(y){case"top":N=h;break;case"center":N=h+(u-O)/2;break;case"bottom":N=h+(u-O);break}return[[P,N],[P,N+O]]}var V=a.get(n,R)||0,F=yt(V,[d,g],f,!0),W;switch(y){case"left":W=v;break;case"center":W=v+(l-F)/2;break;case"right":W=v+l-F;break}return[[W,P],[W+F,P]]};i==="ascending"&&(_=-_,m=-m,s==="horizontal"?v+=l:h+=u,c=c.reverse());for(var b=0;b<c.length;b++){var A=c[b],T=c[b+1],D=a.getItemModel(A);if(s==="horizontal"){var C=D.get(["itemStyle","width"]);C==null?C=_:(C=H(C,l),i==="ascending"&&(C=-C));var M=x(A,v),I=x(T,v+C);v+=C+m,a.setItemLayout(A,{points:M.concat(I.slice().reverse())})}else{var L=D.get(["itemStyle","height"]);L==null?L=_:(L=H(L,u),i==="ascending"&&(L=-L));var M=x(A,h),I=x(T,h+L);h+=L+m,a.setItemLayout(A,{points:M.concat(I.slice().reverse())})}}a2(a)})}function i2(r){r.registerChartView(QP),r.registerSeriesModel(t2),r.registerLayout(n2),r.registerProcessor(ao("funnel"))}var o2=.3,s2=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t._dataGroup=new et,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=lg(t);s.diff(l).add(h).update(f).remove(p).execute();function h(g){var y=sg(s,o,g,c,u);bu(y,s,g,v)}function f(g,y){var m=l.getItemGraphicEl(y),S=Ax(s,g,c,u);s.setItemGraphicEl(g,m),ft(m,{shape:{points:S}},t,g),Ue(m),bu(m,s,g,v)}function p(g){var y=l.getItemGraphicEl(g);o.remove(y)}if(!this._initialized){this._initialized=!0;var d=l2(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=lg(a),u=this._progressiveEls=[],c=t.start;c<t.end;c++){var v=sg(i,this._dataGroup,c,s,o);v.incremental=!0,bu(v,i,c,l),u.push(v)}},e.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},e.type="parallel",e})(bt);function l2(r,e,t){var a=r.model,n=r.getRect(),i=new dt({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),Pt(i,{shape:{width:n.width,height:n.height}},e,t),i}function Ax(r,e,t,a){for(var n=[],i=0;i<t.length;i++){var o=t[i],s=r.get(r.mapDimension(o),e);u2(s,a.getAxis(o).type)||n.push(a.dataToPoint(s,o))}return n}function sg(r,e,t,a,n){var i=Ax(r,t,a,n),o=new xe({shape:{points:i},z2:10});return e.add(o),r.setItemGraphicEl(t,o),o}function lg(r){var e=r.get("smooth",!0);return e===!0&&(e=o2),e=hr(e),hs(e)&&(e=0),{smooth:e}}function bu(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"),kt(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function u2(r,e){return e==="category"?r==null:r==null||isNaN(r)}var c2=(function(r){E(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 _r(null,this,{useEncodeDefaulter:U(v2,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})(Ct);function v2(r){var e=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(e){var t={};return w(e.dimensions,function(a){var n=h2(a);t[a]=n}),t}}function h2(r){return+r.replace("dim","")}var f2=["lineStyle","opacity"],p2={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(f2,!0);u!=null&&(l=u)}var c=i.ensureUniqueItemVisual(s,"style");c.opacity=l},n.start,n.end)}}}};function d2(r){g2(r),y2(r)}function g2(r){if(!r.parallel){var e=!1;w(r.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(r.parallel=[{}])}}function y2(r){var e=xt(r.parallelAxis);w(e,function(t){if(J(t)){var a=t.parallelIndex||0,n=xt(r.parallel)[a];n&&n.parallelAxisDefault&&nt(t,n.parallelAxisDefault,!1)}})}var m2=5,S2=(function(r){E(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(_2,function(i,o){n.getZr().on(o,this._handlers[o]=U(i,this))},this)),Pn(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,a){Li(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(z({type:"parallelAxisExpand"},t))},e.type="parallel",e})(Rt),_2={mousedown:function(r){wu(this,"click")&&(this._mouseDownPoint=[r.offsetX,r.offsetY])},mouseup:function(r){var e=this._mouseDownPoint;if(wu(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>m2)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||!wu(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 wu(r,e){var t=r._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var x2=(function(r){E(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&&nt(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=_t(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),b2=(function(r){E(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})(Ze);function ka(r,e,t,a,n,i){r=r||0;var o=t[1]-t[0];if(n!=null&&(n=Za(n,[0,o])),i!=null&&(i=Math.max(i,n??0)),a==="all"){var s=Math.abs(e[1]-e[0]);s=Za(s,[0,o]),n=i=Za(s,[n,i]),a=0}e[0]=Za(e[0],t),e[1]=Za(e[1],t);var l=Au(e,a);e[a]+=r;var u=n||0,c=t.slice();l.sign<0?c[0]+=u:c[1]-=u,e[a]=Za(e[a],c);var v;return v=Au(e,a),n!=null&&(v.sign!==l.sign||v.span<n)&&(e[1-a]=e[a]+l.sign*n),v=Au(e,a),i!=null&&v.span>i&&(e[1-a]=e[a]+v.sign*i),e}function Au(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 Za(r,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,r))}var Tu=w,Tx=Math.min,Dx=Math.max,ug=Math.floor,w2=Math.ceil,cg=Ot,A2=Math.PI,T2=(function(){function r(e,t,a){this.type="parallel",this._axesMap=$(),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;Tu(n,function(o,s){var l=i[s],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(o,new b2(o,hl(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();Tu(this.dimensions,function(i){var o=this._axesMap.get(i);o.scale.unionExtentFromData(n,n.mapDimension(i)),fn(o.scale,o.model)},this)}},this)},r.prototype.resize=function(e,t){this._rect=Zt(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]),h=e.get("axisExpandable")&&u>3&&u>v&&v>1&&c>0&&s>0,f=e.get("axisExpandWindow"),p;if(f)p=No(f[1]-f[0],l),f[1]=f[0]+p;else{p=No(c*(v-1),l);var d=e.get("axisExpandCenter")||ug(u/2);f=[c*d-p/2],f[1]=f[0]+p}var g=(s-p)/(u-v);g<3&&(g=0);var y=[ug(cg(f[0]/c,1))+1,w2(cg(f[1]/c,1))-1],m=g/c*f[0];return{layout:i,pixelDimIndex:o,layoutBase:t[a[o]],layoutLength:s,axisBase:t[a[1-o]],axisLength:t[n[1-o]],axisExpandable:h,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:f,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])}),Tu(a,function(o,s){var l=(n.axisExpandable?C2:D2)(s,n),u={horizontal:{x:l.position,y:n.axisLength},vertical:{x:0,y:l.position}},c={horizontal:A2/2,vertical:0},v=[u[i].x+e.x,u[i].y+e.y],h=c[i],f=_n();Yi(f,f,h),Sa(f,f,v),this._axesLayout[o]={position:v,rotation:h,transform:f,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 h=e.getValues(s,c),f=0,p=o.length;f<p;f++){var d=l[f].getActiveState(h[f]);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 We([e,0],a.transform)},r.prototype.getAxisLayout=function(e){return j(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"),h=v[0]!=null;if(c)h&&c&&s<i*v[0]?(u="jump",l=s-i*v[2]):h&&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?ka(l,n,o,"all"):u="none";else{var f=n[1]-n[0],p=o[1]*s/f;n=[Dx(0,p-f/2)],n[1]=Tx(o[1],n[0]+f),n[0]=n[1]-f}return{axisExpandWindow:n,behavior:u}},r})();function No(r,e){return Tx(Dx(r,e[0]),e[1])}function D2(r,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*r,axisNameAvailableWidth:t,axisLabelShow:!0}}function C2(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}}function M2(r,e){var t=[];return r.eachComponent("parallel",function(a,n){var i=new T2(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",Ht).models[0];a.coordinateSystem=n.coordinateSystem}}),t}var I2={create:M2},Xc=(function(r){E(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 _a([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var a=this.activeIntervals=j(t);if(a)for(var n=a.length-1;n>=0;n--)Le(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(Xc,oo);var Ta=!0,zi=Math.min,pn=Math.max,L2=Math.pow,P2=1e4,R2=6,E2=6,vg="globalPan",k2={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},N2={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},hg={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},O2=0,xh=(function(r){E(e,r);function e(t){var a=r.call(this)||this;return a._track=[],a._covers=[],a._handlers={},a._zr=t,a.group=new et,a._uid="brushController_"+O2++,w(W2,function(n,i){this._handlers[i]=U(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||LI(a,vg,this._uid),w(this._handlers,function(n,i){a.on(i,n)}),this._brushType=t.brushType,this._brushOption=nt(j(hg),t,!0)},e.prototype._doDisableBrush=function(){var t=this._zr;PI(t,vg,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]=j(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(h){return nt(j(hg),h,!0)});var a="\0-brush-index-",n=this._covers,i=this._covers=[],o=this,s=this._creatingCover;return new dr(n,t,u,l).add(c).update(c).remove(v).execute(),this;function l(h,f){return(h.id!=null?h.id:a+f)+"-"+h.brushType}function u(h,f){return l(h.__brushOption,f)}function c(h,f){var p=t[h];if(f!=null&&n[f]===s)i[h]=n[f];else{var d=i[h]=f!=null?(n[f].__brushOption=p,n[f]):Mx(o,Cx(o,p));bh(o,d)}}function v(h){n[h]!==s&&o.group.remove(n[h])}},e.prototype.unmount=function(){return this.enableBrush(!1),Kc(this),this._zr.remove(this.group),this},e.prototype.dispose=function(){this.unmount(),this.off()},e})(Sn);function Cx(r,e){var t=gl[e.brushType].createCover(r,e);return t.__brushOption=e,Lx(t,e),r.group.add(t),t}function Mx(r,e){var t=wh(e);return t.endCreating&&(t.endCreating(r,e),Lx(e,e.__brushOption)),e}function Ix(r,e){var t=e.__brushOption;wh(e).updateCoverShape(r,e,t.range,t)}function Lx(r,e){var t=e.z;t==null&&(t=P2),r.traverse(function(a){a.z=t,a.z2=t})}function bh(r,e){wh(e).updateCommon(r,e),Ix(r,e)}function wh(r){return gl[r.__brushOption.brushType]}function Ah(r,e,t){var a=r._panels;if(!a)return Ta;var n,i=r._transform;return w(a,function(o){o.isTargetByCursor(e,t,i)&&(n=o)}),n}function Px(r,e){var t=r._panels;if(!t)return Ta;var a=e.__brushOption.panelId;return a!=null?t[a]:Ta}function Kc(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=j(n.range);return{brushType:n.brushType,panelId:n.panelId,range:i}});r.trigger("brush",{areas:t,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function V2(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=L2(n*n+i*i,.5);return o>R2}function Rx(r){var e=r.length-1;return e<0&&(e=0),[r[0],r[e]]}function Ex(r,e,t,a){var n=new et;return n.add(new dt({name:"main",style:Th(t),silent:!0,draggable:!0,cursor:"move",drift:tt(fg,r,e,n,["n","s","w","e"]),ondragend:tt(Da,e,{isEnd:!0})})),w(a,function(i){n.add(new dt({name:i.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:tt(fg,r,e,n,i),ondragend:tt(Da,e,{isEnd:!0})}))}),n}function kx(r,e,t,a){var n=a.brushStyle.lineWidth||0,i=pn(n,E2),o=t[0][0],s=t[1][0],l=o-n/2,u=s-n/2,c=t[0][1],v=t[1][1],h=c-i+n/2,f=v-i+n/2,p=c-o,d=v-s,g=p+n,y=d+n;sr(r,e,"main",o,s,p,d),a.transformable&&(sr(r,e,"w",l,u,i,y),sr(r,e,"e",h,u,i,y),sr(r,e,"n",l,u,g,i),sr(r,e,"s",l,f,g,i),sr(r,e,"nw",l,u,i,i),sr(r,e,"ne",h,u,i,i),sr(r,e,"sw",l,f,i,i),sr(r,e,"se",h,f,i,i))}function qc(r,e){var t=e.__brushOption,a=t.transformable,n=e.childAt(0);n.useStyle(Th(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?jc(r,i[0]):z2(r,i);o&&o.attr({silent:!a,invisible:!a,cursor:a?N2[s]+"-resize":null})})}function sr(r,e,t,a,n,i,o){var s=e.childOfName(t);s&&s.setShape(F2(Dh(r,e,[[a,n],[a+i,n+o]])))}function Th(r){return Q({strokeNoScale:!0},r.brushStyle)}function Nx(r,e,t,a){var n=[zi(r,t),zi(e,a)],i=[pn(r,t),pn(e,a)];return[[n[0],i[0]],[n[1],i[1]]]}function B2(r){return pa(r.group)}function jc(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],B2(r));return a[n]}function z2(r,e){var t=[jc(r,e[0]),jc(r,e[1])];return(t[0]==="e"||t[0]==="w")&&t.reverse(),t.join("")}function fg(r,e,t,a,n,i){var o=t.__brushOption,s=r.toRectRange(o.range),l=Ox(e,n,i);w(a,function(u){var c=k2[u];s[c[0]][c[1]]+=l[c[0]]}),o.range=r.fromRectRange(Nx(s[0][0],s[1][0],s[0][1],s[1][1])),bh(e,t),Da(e,{isEnd:!1})}function G2(r,e,t,a){var n=e.__brushOption.range,i=Ox(r,t,a);w(n,function(o){o[0]+=i[0],o[1]+=i[1]}),bh(r,e),Da(r,{isEnd:!1})}function Ox(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 Dh(r,e,t){var a=Px(r,e);return a&&a!==Ta?a.clipPath(t,r._transform):j(t)}function F2(r){var e=zi(r[0][0],r[1][0]),t=zi(r[0][1],r[1][1]),a=pn(r[0][0],r[1][0]),n=pn(r[0][1],r[1][1]);return{x:e,y:t,width:a-e,height:n-t}}function H2(r,e,t){if(!(!r._brushType||U2(r,e.offsetX,e.offsetY))){var a=r._zr,n=r._covers,i=Ah(r,e,t);if(!r._dragging)for(var o=0;o<n.length;o++){var s=n[o].__brushOption;if(i&&(i===Ta||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 Qc(r,e,t){return r.childOfName("main").contain(e,t)}function Vx(r,e,t,a){var n=r._creatingCover,i=r._creatingPanel,o=r._brushOption,s;if(r._track.push(t.slice()),V2(r)||n){if(i&&!n){o.brushMode==="single"&&Kc(r);var l=j(o);l.brushType=pg(l.brushType,i),l.panelId=i===Ta?null:i.panelId,n=r._creatingCover=Cx(r,l),r._covers.push(n)}if(n){var u=gl[pg(r._brushType,i)],c=n.__brushOption;c.range=u.getCreatingRange(Dh(r,n,r._track)),a&&(Mx(r,n),u.updateCommon(r,n)),Ix(r,n),s={isEnd:a}}}else a&&o.brushMode==="single"&&o.removeOnClick&&Ah(r,e,t)&&Kc(r)&&(s={isEnd:a,removeOnClick:!0});return s}function pg(r,e){return r==="auto"?e.defaultBrushType:r}var W2={mousedown:function(r){if(this._dragging)dg(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=Ah(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(H2(this,r,a),this._dragging){Jc(r);var n=Vx(this,r,a,!1);n&&Da(this,n)}},mouseup:function(r){dg(this,r)}};function dg(r,e){if(r._dragging){Jc(e);var t=e.offsetX,a=e.offsetY,n=r.group.transformCoordToLocal(t,a),i=Vx(r,e,n,!0);r._dragging=!1,r._track=[],r._creatingCover=null,i&&Da(r,i)}}function U2(r,e,t){var a=r._zr;return e<0||e>a.getWidth()||t<0||t>a.getHeight()}var gl={lineX:gg(0),lineY:gg(1),rect:{createCover:function(r,e){function t(a){return a}return Ex({toRectRange:t,fromRectRange:t},r,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var e=Rx(r);return Nx(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(r,e,t,a){kx(r,e,t,a)},updateCommon:qc,contain:Qc},polygon:{createCover:function(r,e){var t=new et;return t.add(new xe({name:"main",style:Th(e),silent:!0})),t},getCreatingRange:function(r){return r},endCreating:function(r,e){e.remove(e.childAt(0)),e.add(new ke({name:"main",draggable:!0,drift:tt(G2,r,e),ondragend:tt(Da,r,{isEnd:!0})}))},updateCoverShape:function(r,e,t,a){e.childAt(0).setShape({points:Dh(r,e,t)})},updateCommon:qc,contain:Qc}};function gg(r){return{createCover:function(e,t){return Ex({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=Rx(e),a=zi(t[0][r],t[1][r]),n=pn(t[0][r],t[1][r]);return[a,n]},updateCoverShape:function(e,t,a,n){var i,o=Px(e,t);if(o!==Ta&&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(),kx(e,t,l,n)},updateCommon:qc,contain:Qc}}function Bx(r){return r=Ch(r),function(e){return d0(e,r)}}function zx(r,e){return r=Ch(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 Gx(r,e,t){var a=Ch(r);return function(n,i){return a.contain(i[0],i[1])&&!fl(n,e,t)}}function Ch(r){return wt.create(r)}var Y2=["axisLine","axisTickLabel","axisName"],Z2=(function(r){E(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 xh(a.getZr())).on("brush",U(this._onBrush,this))},e.prototype.render=function(t,a,n,i){if(!$2(t,a,i)){this.axisModel=t,this.api=n,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new et,this.group.add(this._axisGroup),!!t.get("show")){var s=K2(t,a),l=s.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,v=t.axis.dim,h=l.getAxisLayout(v),f=z({strokeContainThreshold:c},h),p=new fe(t,f);w(Y2,p.add,p),this._axisGroup.add(p.getGroup()),this._refreshBrushController(f,u,t,s,c,n),Ki(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:Bx(v),isTargetByCursor:Gx(v,s,i),getLinearBrushOtherExtent:zx(v,0)}]).enableBrush({brushType:"lineX",brushStyle:a,removeOnClick:!0}).updateCovers(X2(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})(Rt);function $2(r,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===r}function X2(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 K2(r,e){return e.getComponent("parallel",r.get("parallelIndex"))}var q2={type:"axisAreaSelect",event:"axisAreaSelected"};function j2(r){r.registerAction(q2,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 J2={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function Fx(r){r.registerComponentView(S2),r.registerComponentModel(x2),r.registerCoordinateSystem("parallel",I2),r.registerPreprocessor(d2),r.registerComponentModel(Xc),r.registerComponentView(Z2),hn(r,"parallel",Xc,J2),j2(r)}function Q2(r){it(Fx),r.registerChartView(s2),r.registerSeriesModel(c2),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,p2)}var tR=(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})(),eR=(function(r){E(e,r);function e(t){return r.call(this,t)||this}return e.prototype.getDefaultShape=function(){return new tR},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(){fr(this)},e.prototype.downplay=function(){pr(this)},e})(Mt),rR=(function(r){E(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(),h=t.getData("edge"),f=t.get("orient");this._model=t,s.removeAll(),s.x=l.x,s.y=l.y,o.eachEdge(function(p){var d=new eR,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"),_=p.node1.getLayout(),x=p.node1.getModel(),b=x.get("localX"),A=x.get("localY"),T=p.node2.getLayout(),D=p.node2.getModel(),C=D.get("localX"),M=D.get("localY"),I=p.getLayout(),L,R,P,k,O,N,V,F;d.shape.extent=Math.max(1,I.dy),d.shape.orient=f,f==="vertical"?(L=(b!=null?b*u:_.x)+I.sy,R=(A!=null?A*c:_.y)+_.dy,P=(C!=null?C*u:T.x)+I.ty,k=M!=null?M*c:T.y,O=L,N=R*(1-S)+k*S,V=P,F=R*S+k*(1-S)):(L=(b!=null?b*u:_.x)+_.dx,R=(A!=null?A*c:_.y)+I.sy,P=C!=null?C*u:T.x,k=(M!=null?M*c:T.y)+I.ty,O=L*(1-S)+P*S,N=R,V=L*S+P*(1-S),F=k),d.setShape({x1:L,y1:R,x2:P,y2:k,cpx1:O,cpy1:N,cpx2:V,cpy2:F}),d.useStyle(m.getItemStyle()),yg(d.style,f,p);var W=""+y.get("value"),X=qt(y,"edgeLabel");ae(d,X,{labelFetcher:{getFormattedLabel:function(st,Vt,me,ht,ot,It){return t.getFormattedLabel(st,Vt,"edge",ht,mn(ot,X.normal&&X.normal.get("formatter"),W),It)}},labelDataIndex:p.dataIndex,defaultText:W}),d.setTextConfig({position:"inside"});var rt=y.getModel("emphasis");re(d,y,"lineStyle",function(st){var Vt=st.getItemStyle();return yg(Vt,f,p),Vt}),s.add(d),h.setItemGraphicEl(p.dataIndex,d);var at=rt.get("focus");kt(d,at==="adjacency"?p.getAdjacentDataIndices():at==="trajectory"?p.getTrajectoryDataIndices():at,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"),_=g.get(["itemStyle","borderRadius"])||0,x=new dt({shape:{x:y!=null?y*u:d.x,y:m!=null?m*c:d.y,width:d.dx,height:d.dy,r:_},style:g.getModel("itemStyle").getItemStyle(),z2:10});ae(x,qt(g),{labelFetcher:{getFormattedLabel:function(A,T){return t.getFormattedLabel(A,T,"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");kt(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(aR(s.getBoundingRect(),t,function(){s.removeClipPath()})),this._data=t.getData()},e.prototype.dispose=function(){},e.type="sankey",e})(bt);function yg(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");Y(a)&&Y(n)&&(r.fill=new Us(0,0,+(e==="horizontal"),+(e==="vertical"),[{color:a,offset:0},{color:n,offset:1}]))}}function aR(r,e,t){var a=new dt({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Pt(a,{shape:{width:r.width+20}},e,t),a}var nR=(function(r){E(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 mt(o[l],this,a));var u=wx(i,n,this,!0,c);return u.data;function c(v,h){v.wrapMethod("getItemModel",function(f,p){var d=f.parentModel,g=d.getData().getItemLayout(p);if(g){var y=g.depth,m=d.levelModels[y];m&&(f.parentModel=m)}return f}),h.wrapMethod("getItemModel",function(f,p){var d=f.parentModel,g=d.getGraph().getEdgeByIndex(p),y=g.node1.getLayout();if(y){var m=y.depth,S=d.levelModels[m];S&&(f.parentModel=S)}return f})}},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(f){return isNaN(f)||f==null}if(n==="edge"){var o=this.getDataParams(t,n),s=o.data,l=o.value,u=s.source+" -- "+s.target;return jt("nameValue",{name:u,value:l,noValue:i(l)})}else{var c=this.getGraph().getNodeByIndex(t),v=c.getLayout().value,h=this.getDataParams(t,n).data.name;return jt("nameValue",{name:h!=null?h+"":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})(Ct);function iR(r,e){r.eachSeriesByType("sankey",function(t){var a=t.get("nodeWidth"),n=t.get("nodeGap"),i=oR(t,e);t.layoutInfo=i;var o=i.width,s=i.height,l=t.getGraph(),u=l.nodes,c=l.edges;lR(u);var v=_t(u,function(d){return d.getLayout().value===0}),h=v.length!==0?0:t.get("layoutIterations"),f=t.get("orient"),p=t.get("nodeAlign");sR(u,c,a,n,o,s,h,f,p)})}function oR(r,e){return Zt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function sR(r,e,t,a,n,i,o,s,l){uR(r,e,t,n,i,s,l),fR(r,e,i,n,a,o,s),bR(r,s)}function lR(r){w(r,function(e){var t=Vr(e.outEdges,Es),a=Vr(e.inEdges,Es),n=e.getValue()||0,i=Math.max(t,a,n);e.setLayout({value:i},!0)})}function uR(r,e,t,a,n,i,o){for(var s=[],l=[],u=[],c=[],v=0,h=0;h<e.length;h++)s[h]=1;for(var h=0;h<r.length;h++)l[h]=r[h].inEdges.length,l[h]===0&&u.push(r[h]);for(var f=-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>f&&(f=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],_=e.indexOf(S);s[_]=0;var x=S.node2,b=r.indexOf(x);--l[b]===0&&c.indexOf(x)<0&&c.push(x)}}++v,u=c,c=[]}for(var h=0;h<s.length;h++)if(s[h]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var A=f>v-1?f:v-1;o&&o!=="left"&&cR(r,o,i,A);var T=i==="vertical"?(n-t)/A:(a-t)/A;hR(r,T,i)}function Hx(r){var e=r.hostGraph.data.getRawDataItem(r.dataIndex);return e.depth!=null&&e.depth>=0}function cR(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){Hx(v)||v.setLayout({depth:Math.max(0,a-v.getLayout().skNodeHeight)},!0)})}else e==="justify"&&vR(r,a)}function vR(r,e){w(r,function(t){!Hx(t)&&!t.outEdges.length&&t.setLayout({depth:e},!0)})}function hR(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 fR(r,e,t,a,n,i,o){var s=pR(r,o);dR(s,e,t,a,n,o),Du(s,n,t,a,o);for(var l=1;i>0;i--)l*=.99,gR(s,l,o),Du(s,n,t,a,o),xR(s,l,o),Du(s,n,t,a,o)}function pR(r,e){var t=[],a=e==="vertical"?"y":"x",n=uc(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 dR(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,h=n==="vertical"?"dx":"dy",f=0;f<v;f++)l=o[f],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()[h]+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 f=v-2;f>=0;--f)l=o[f],u=l.getLayout()[i]+l.getLayout()[h]+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 gR(r,e,t){w(r.slice().reverse(),function(a){w(a,function(n){if(n.outEdges.length){var i=Vr(n.outEdges,yR,t)/Vr(n.outEdges,Es);if(isNaN(i)){var o=n.outEdges.length;i=o?Vr(n.outEdges,mR,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-Hr(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-Hr(n,t))*e;n.setLayout({y:l},!0)}}})})}function yR(r,e){return Hr(r.node2,e)*r.getValue()}function mR(r,e){return Hr(r.node2,e)}function SR(r,e){return Hr(r.node1,e)*r.getValue()}function _R(r,e){return Hr(r.node1,e)}function Hr(r,e){return e==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function Es(r){return r.getValue()}function Vr(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 xR(r,e,t){w(r,function(a){w(a,function(n){if(n.inEdges.length){var i=Vr(n.inEdges,SR,t)/Vr(n.inEdges,Es);if(isNaN(i)){var o=n.inEdges.length;i=o?Vr(n.inEdges,_R,t)/o:0}if(t==="vertical"){var s=n.getLayout().x+(i-Hr(n,t))*e;n.setLayout({x:s},!0)}else{var l=n.getLayout().y+(i-Hr(n,t))*e;n.setLayout({y:l},!0)}}})})}function bR(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 wR(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 Kt({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 AR(r){r.registerChartView(rR),r.registerSeriesModel(nR),r.registerLayout(iR),r.registerVisual(wR),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 Wx=(function(){function r(){}return r.prototype._hasEncodeRule=function(e){var t=this.getEncode();return t&&t.get(e)!=null},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=!this._hasEncodeRule("x")):s==="category"?(e.layout="vertical",a=i.getOrdinalMeta(),l=!this._hasEncodeRule("y")):e.layout=e.layout||"horizontal";var u=["x","y"],c=e.layout==="horizontal"?0:1,v=this._baseAxisDim=u[c],h=u[1-c],f=[n,i],p=f[c].get("type"),d=f[1-c].get("type"),g=e.data;if(g&&l){var y=[];w(g,function(_,x){var b;B(_)?(b=_.slice(),_.unshift(x)):B(_.value)?(b=z({},_),b.value=b.value.slice(),_.value.unshift(x)):b=_,y.push(b)}),e.data=y}var m=this.defaultValueDimensions,S=[{name:v,type:ms(p),ordinalMeta:a,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:h,type:ms(d),dimsDef:m.slice()}];return Rn(this,{coordDimensions:S,dimensionsCount:m.length+1,encodeDefaulter:tt(T0,S,this)})},r.prototype.getBaseAxis=function(){var e=this._baseAxisDim;return this.ecModel.getComponent(e+"Axis",this.get(e+"AxisIndex")).axis},r})(),Ux=(function(r){E(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})(Ct);Jt(Ux,Wx,!0);var TR=(function(r){E(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=mg(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 h=i.getItemLayout(u);v?(Ue(v),Yx(h,v,i,u)):v=mg(h,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})(bt),DR=(function(){function r(){}return r})(),CR=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="boxplotBoxPath",a}return e.prototype.getDefaultShape=function(){return new DR},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})(Mt);function mg(r,e,t,a,n){var i=r.ends,o=new CR({shape:{points:n?MR(i,a,r):i}});return Yx(r,o,e,t,n),o}function Yx(r,e,t,a,n){var i=t.hostModel,o=Ia[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),kt(e,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function MR(r,e,t){return G(r,function(a){return a=a.slice(),a[e]=t.initBaseline,a})}var Si=w;function IR(r){var e=LR(r);Si(e,function(t){var a=t.seriesModels;a.length&&(PR(t),Si(a,function(n,i){RR(n,t.boxOffsetList[i],t.boxWidthList[i])}))})}function LR(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 PR(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;Si(t,function(p){l=Math.max(l,p.getData().count())});var u=e.getExtent();s=Math.abs(u[1]-u[0])/l}Si(t,function(p){var d=p.get("boxWidth");B(d)||(d=[d,d]),o.push([H(d[0],s)||0,H(d[1],s)||0])});var c=s*.8-2,v=c/a*.3,h=(c-v*(a-1))/a,f=h/2-c/2;Si(t,function(p,d){i.push(f),f+=v+h,n.push(Math.min(Math.max(h,o[d][0]),o[d][1]))})}function RR(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 h=n.get(u,v),f=S(h,c[2],v),p=S(h,c[0],v),d=S(h,c[1],v),g=S(h,c[3],v),y=S(h,c[4],v),m=[];_(m,d,!1),_(m,g,!0),m.push(p,d,y,g),x(m,p),x(m,y),x(m,f),n.setItemLayout(v,{initBaseline:f[s],ends:m})}function S(b,A,T){var D=n.get(A,T),C=[];C[o]=b,C[s]=D;var M;return isNaN(b)||isNaN(D)?M=[NaN,NaN]:(M=a.dataToPoint(C),M[o]+=e),M}function _(b,A,T){var D=A.slice(),C=A.slice();D[o]+=i,C[o]-=i,T?b.push(D,C):b.push(C,D)}function x(b,A){var T=A.slice(),D=A.slice();T[o]-=i,D[o]+=i,b.push(T,D)}}function ER(r,e){e=e||{};for(var t=[],a=[],n=e.boundIQR,i=n==="none"||n===0,o=0;o<r.length;o++){var s=Le(r[o].slice()),l=wl(s,.25),u=wl(s,.5),c=wl(s,.75),v=s[0],h=s[s.length-1],f=(n??1.5)*(c-l),p=i?v:Math.max(v,l-f),d=i?h:Math.min(h,c+f),g=e.itemNameFormatter,y=K(g)?g({value:o}):Y(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 _=[y,S];a.push(_)}}}return{boxData:t,outliers:a}}var kR={type:"echarts:boxplot",transform:function(e){var t=e.upstream;if(t.sourceFormat!==se){var a="";gt(a)}var n=ER(t.getRawData(),e.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}};function NR(r){r.registerSeriesModel(Ux),r.registerChartView(TR),r.registerLayout(IR),r.registerTransform(kR)}var OR=["itemStyle","borderColor"],VR=["itemStyle","borderColor0"],BR=["itemStyle","borderColorDoji"],zR=["itemStyle","color"],GR=["itemStyle","color0"];function Mh(r,e){return e.get(r>0?zR:GR)}function Ih(r,e){return e.get(r===0?BR:r>0?OR:VR)}var FR={seriesType:"candlestick",plan:Ln(),performRawSeries:!0,reset:function(r,e){if(!e.isSeriesFiltered(r)){var t=r.pipelineContext.large;return!t&&{progress:function(a,n){for(var i;(i=a.next())!=null;){var o=n.getItemModel(i),s=n.getItemLayout(i).sign,l=o.getItemStyle();l.fill=Mh(s,o),l.stroke=Ih(s,o)||l.fill;var u=n.ensureUniqueItemVisual(i,"style");z(u,l)}}}}}},HR=["color","borderColor"],WR=(function(r){E(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){Ur(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&&Sg(u,v))return;var h=Cu(v,c,!0);Pt(h,{shape:{points:v.ends}},t,c),Mu(h,a,c,o),i.add(h),a.setItemGraphicEl(c,h)}}).update(function(c,v){var h=n.getItemGraphicEl(v);if(!a.hasValue(c)){i.remove(h);return}var f=a.getItemLayout(c);if(s&&Sg(u,f)){i.remove(h);return}h?(ft(h,{shape:{points:f.ends}},t,c),Ue(h)):h=Cu(f),Mu(h,a,c,o),i.add(h),a.setItemGraphicEl(c,h)}).remove(function(c){var v=n.getItemGraphicEl(c);v&&i.remove(v)}).execute(),this._data=a},e.prototype._renderLarge=function(t){this._clear(),_g(t,this.group);var a=t.get("clip",!0)?eo(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=Cu(s);Mu(l,n,o,i),l.incremental=!0,this.group.add(l),this._progressiveEls.push(l)}},e.prototype._incrementalRenderLarge=function(t,a){_g(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})(bt),UR=(function(){function r(){}return r})(),YR=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="normalCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new UR},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})(Mt);function Cu(r,e,t){var a=r.ends;return new YR({shape:{points:t?ZR(a,r):a},z2:100})}function Sg(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 Mu(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);var i=e.getItemLayout(t).sign;w(r.states,function(s,l){var u=n.getModel(l),c=Mh(i,u),v=Ih(i,u)||c,h=s.style||(s.style={});c&&(h.fill=c),v&&(h.stroke=v)});var o=n.getModel("emphasis");kt(r,o.get("focus"),o.get("blurScope"),o.get("disabled"))}function ZR(r,e){return G(r,function(t){return t=t.slice(),t[1]=e.initBaseline,t})}var $R=(function(){function r(){}return r})(),Iu=(function(r){E(e,r);function e(t){var a=r.call(this,t)||this;return a.type="largeCandlestickBox",a}return e.prototype.getDefaultShape=function(){return new $R},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})(Mt);function _g(r,e,t,a){var n=r.getData(),i=n.getLayout("largePoints"),o=new Iu({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});e.add(o);var s=new Iu({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});e.add(s);var l=new Iu({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});e.add(l),Lu(1,o,r),Lu(-1,s,r),Lu(0,l,r),a&&(o.incremental=!0,s.incremental=!0),t&&t.push(o,s)}function Lu(r,e,t,a){var n=Ih(r,t)||Mh(r,t),i=t.getModel("itemStyle").getItemStyle(HR);e.useStyle(i),e.style.fill=null,e.style.stroke=n}var Zx=(function(r){E(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:{itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e})(Ct);Jt(Zx,Wx,!0);function XR(r){!r||!B(r.series)||w(r.series,function(e){J(e)&&e.type==="k"&&(e.type="candlestick")})}var KR={seriesType:"candlestick",plan:Ln(),reset:function(r){var e=r.coordinateSystem,t=r.getData(),a=qR(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],h=l[3];if(t.setLayout({candleWidth:a,isSimpleBox:a<=1.3}),s<0||l.length<4)return;return{progress:r.pipelineContext.large?p:f};function f(d,g){for(var y,m=g.getStore();(y=d.next())!=null;){var S=m.get(s,y),_=m.get(u,y),x=m.get(c,y),b=m.get(v,y),A=m.get(h,y),T=Math.min(_,x),D=Math.max(_,x),C=O(T,S),M=O(D,S),I=O(b,S),L=O(A,S),R=[];N(R,M,0),N(R,C,1),R.push(F(L),F(M),F(I),F(C));var P=g.getItemModel(y),k=!!P.get(["itemStyle","borderColorDoji"]);g.setItemLayout(y,{sign:xg(m,y,_,x,c,k),initBaseline:_>x?M[i]:C[i],ends:R,brushRect:V(b,A,S)})}function O(W,X){var rt=[];return rt[n]=X,rt[i]=W,isNaN(X)||isNaN(W)?[NaN,NaN]:e.dataToPoint(rt)}function N(W,X,rt){var at=X.slice(),st=X.slice();at[n]=jo(at[n]+a/2,1,!1),st[n]=jo(st[n]-a/2,1,!0),rt?W.push(at,st):W.push(st,at)}function V(W,X,rt){var at=O(W,rt),st=O(X,rt);return at[n]-=a/2,st[n]-=a/2,{x:at[0],y:at[1],width:a,height:st[1]-at[1]}}function F(W){return W[n]=jo(W[n],1),W}}function p(d,g){for(var y=Je(d.count*4),m=0,S,_=[],x=[],b,A=g.getStore(),T=!!r.get(["itemStyle","borderColorDoji"]);(b=d.next())!=null;){var D=A.get(s,b),C=A.get(u,b),M=A.get(c,b),I=A.get(v,b),L=A.get(h,b);if(isNaN(D)||isNaN(I)||isNaN(L)){y[m++]=NaN,m+=3;continue}y[m++]=xg(A,b,C,M,c,T),_[n]=D,_[i]=I,S=e.dataToPoint(_,null,x),y[m++]=S?S[0]:NaN,y[m++]=S?S[1]:NaN,_[i]=L,S=e.dataToPoint(_,null,x),y[m++]=S?S[1]:NaN}g.setLayout("largePoints",y)}}};function xg(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 qR(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=H(pt(r.get("barMaxWidth"),n),n),o=H(pt(r.get("barMinWidth"),1),n),s=r.get("barWidth");return s!=null?H(s,n):Math.max(Math.min(n/2,i),o)}function jR(r){r.registerChartView(WR),r.registerSeriesModel(Zx),r.registerPreprocessor(XR),r.registerVisual(FR),r.registerLayout(KR)}function bg(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 JR=(function(r){E(e,r);function e(t,a){var n=r.call(this)||this,i=new Qi(t,a),o=new et;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=Wt(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)}bg(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}}bg(n,t)},e.prototype.highlight=function(){fr(this)},e.prototype.downplay=function(){pr(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=In(t.getItemVisual(a,"symbolSize")),c=t.getItemVisual(a,"style"),v=c&&c.fill,h=s.getModel("emphasis");o.setScale(u),o.traverse(function(g){g.setStyle("fill",v)});var f=La(t.getItemVisual(a,"symbolOffset"),u);f&&(o.x=f[0],o.y=f[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,kt(this,h.get("focus"),h.get("blurScope"),h.get("disabled"))},e.prototype.fadeOut=function(t){t&&t()},e})(et),QR=(function(r){E(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(JR)},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=ro("").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=Lb(a.getRoamTransform()),this.group.decomposeTransform())},e.prototype.remove=function(t,a){this._symbolDraw&&this._symbolDraw.remove(!0)},e.type="effectScatter",e})(bt),tE=(function(r){E(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 _r(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})(Ct);function eE(r){r.registerChartView(QR),r.registerSeriesModel(tE),r.registerLayout(ro("effectScatter"))}var $x=(function(r){E(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 Sh(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");B(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=Wt(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=Qt(a.get("delay"),function(f){return f/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 h=void 0;K(v)?h=v(n):h=v,i.__t>0&&(h=-s*i.__t),this._animateSymbol(i,s,h,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 sa(t.__p1,t.__cp1)+sa(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=Pb;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),h=t.__t<1?c(a[1],i[1],n[1],o):c(n[1],i[1],a[1],1-o);t.rotation=-Math.atan2(h,v)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(t.__lastT!==void 0&&t.__lastT<t.__t?(t.scaleY=sa(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*sa(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})(et),Xx=(function(r){E(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 xe({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 h=i.ensureState("emphasis");h.style=s,kt(this,l,u,c)},e.prototype.updateLayout=function(t,a){var n=this.childAt(0);n.setShape("points",t.getItemLayout(a))},e})(et),rE=(function(r){E(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 Xx(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+=sa(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],h=n[l+1];t.x=v[0]*(1-c)+c*h[0],t.y=v[1]*(1-c)+c*h[1];var f=t.__t<1?h[0]-v[0]:v[0]-h[0],p=t.__t<1?h[1]-v[1]:v[1]-h[1];t.rotation=-Math.atan2(p,f)-Math.PI/2,this._lastFrame=l,this._lastFramePercent=a,t.ignore=!1}},e})($x),aE=(function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r})(),nE=(function(r){E(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 aE},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++],h=n[o++];if(t.moveTo(u,c),i>0){var f=(u+v)/2-(c-h)*i,p=(c+h)/2-(v-u)*i;t.quadraticCurveTo(f,p,v,h)}else t.lineTo(v,h)}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++],h=i[u++],f=1;f<c;f++){var p=i[u++],d=i[u++];if(cf(v,h,p,d,s,t,a))return l}l++}else for(var l=0,u=0;u<i.length;){var v=i[u++],h=i[u++],p=i[u++],d=i[u++];if(o>0){var g=(v+p)/2-(h-d)*o,y=(h+d)/2-(p-v)*o;if(Rb(v,h,g,y,p,d,s,t,a))return l}else if(cf(v,h,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})(Mt),iE=(function(){function r(){this.group=new et}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 nE({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})(),Kx={seriesType:"lines",plan:Ln(),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,h=[],c=n.start;c<n.end;c++){var f=r.getLineCoords(c,o);t&&(s[v++]=f);for(var p=0;p<f;p++)h=e.dataToPoint(o[p],!1,h),s[v++]=h[0],s[v++]=h[1]}i.setLayout("linesPoints",s)}else for(var c=n.start;c<n.end;c++){var d=i.getItemModel(c),f=r.getLineCoords(c,o),g=[];if(t)for(var y=0;y<f;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)}}}}}},oE=(function(r){E(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)&&eo(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=Kx.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 iE:new _h(o?i?rE:Xx:i?$x:Sh),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})(bt),sE=typeof Uint32Array>"u"?Array:Uint32Array,lE=typeof Float64Array>"u"?Array:Float64Array;function wg(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),mv([n,t[0],t[1]])}))}var uE=(function(r){E(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||[],wg(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(wg(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=_i(this._flatCoords,a.flatCoords),this._flatCoordsOffset=_i(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),St(t[0])){for(var n=t.length,i=new sE(n),o=new lE(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 h=0;h<v;h++){var f=t[c++],p=t[c++];o[s++]=f,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 he(["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),jt("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})(Ct);function Oo(r){return r instanceof Array||(r=[r,r]),r}var cE={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}}};function vE(r){r.registerChartView(oE),r.registerSeriesModel(uE),r.registerLayout(Kx),r.registerVisual(cE)}var hE=256,fE=(function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var e=vs.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,h=v.getContext("2d"),f=e.length;v.width=t,v.height=a;for(var p=0;p<f;++p){var d=e[p],g=d[0],y=d[1],m=d[2],S=n(m);h.globalAlpha=S,h.drawImage(s,g-c,y-c)}if(!v.width||!v.height)return v;for(var _=h.getImageData(0,0,v.width,v.height),x=_.data,b=0,A=x.length,T=this.minOpacity,D=this.maxOpacity,C=D-T;b<A;){var S=x[b+3]/256,M=Math.floor(S*(hE-1))*4;if(S>0){var I=o(S)?l:u;S>0&&(S=S*C+T),x[b++]=I[M],x[b++]=I[M+1],x[b++]=I[M+2],x[b++]=I[M+3]*S*256}else b+=4}return h.putImageData(_,0,0),v},r.prototype._getBrush=function(){var e=this._brushCanvas||(this._brushCanvas=vs.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})();function pE(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 dE(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 Ag(r){var e=r.dimensions;return e[0]==="lng"&&e[1]==="lat"}var gE=(function(r){E(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()):Ag(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&&(Ag(o)?this.render(a,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(a,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){Ur(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,h;if(l){var f=s.getAxis("x"),p=s.getAxis("y");u=f.getBandWidth()+.5,c=p.getBandWidth()+.5,v=f.scale.getExtent(),h=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(),_=t.get(["itemStyle","borderRadius"]),x=qt(t),b=t.getModel("emphasis"),A=b.get("focus"),T=b.get("blurScope"),D=b.get("disabled"),C=l?[g.mapDimension("x"),g.mapDimension("y"),g.mapDimension("value")]:[g.mapDimension("time"),g.mapDimension("value")],M=n;M<i;M++){var I=void 0,L=g.getItemVisual(M,"style");if(l){var R=g.get(C[0],M),P=g.get(C[1],M);if(isNaN(g.get(C[2],M))||isNaN(R)||isNaN(P)||R<v[0]||R>v[1]||P<h[0]||P>h[1])continue;var k=s.dataToPoint([R,P]);I=new dt({shape:{x:k[0]-u/2,y:k[1]-c/2,width:u,height:c},style:L})}else{if(isNaN(g.get(C[1],M)))continue;I=new dt({z2:1,shape:s.dataToRect([g.get(C[0],M)]).contentShape,style:L})}if(g.hasItemOption){var O=g.getItemModel(M),N=O.getModel("emphasis");y=N.getModel("itemStyle").getItemStyle(),m=O.getModel(["blur","itemStyle"]).getItemStyle(),S=O.getModel(["select","itemStyle"]).getItemStyle(),_=O.get(["itemStyle","borderRadius"]),A=N.get("focus"),T=N.get("blurScope"),D=N.get("disabled"),x=qt(O)}I.shape.r=_;var V=t.getRawValue(M),F="-";V&&V[2]!=null&&(F=V[2]+""),ae(I,x,{labelFetcher:t,labelDataIndex:M,defaultOpacity:L.opacity,defaultText:F}),I.ensureState("emphasis").style=y,I.ensureState("blur").style=m,I.ensureState("select").style=S,kt(I,A,T,D),I.incremental=o,o&&(I.states.emphasis.hoverLayer=!0),d.add(I),g.setItemGraphicEl(M,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 fE;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 h=Math.max(c.x,0),f=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-h,y=d-f,m=[l.mapDimension("lng"),l.mapDimension("lat"),l.mapDimension("value")],S=l.mapArray(m,function(A,T,D){var C=t.dataToPoint([A,T]);return C[0]-=h,C[1]-=f,C.push(D),C}),_=n.getExtent(),x=n.type==="visualMap.continuous"?dE(_,n.option.range):pE(_,n.getPieceList(),n.option.selected);u.update(S,g,y,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:s.color.getColorMapper()},x);var b=new Ne({style:{width:g,height:y,x:h,y:f,image:u.canvas},silent:!0});this.group.add(b)},e.type="heatmap",e})(bt),yE=(function(r){E(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 _r(null,this,{generateCoord:"value"})},e.prototype.preventIncremental=function(){var t=Ji.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})(Ct);function mE(r){r.registerChartView(gE),r.registerSeriesModel(yE)}var SE=["itemStyle","borderWidth"],Tg=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],Pu=new Ca,_E=(function(r){E(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(),h={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:Tg[+c],categoryDim:Tg[1-+c]};o.diff(s).add(function(p){if(o.hasValue(p)){var d=Cg(o,p),g=Dg(o,p,d,h),y=Mg(o,h,g);o.setItemGraphicEl(p,y),i.add(y),Lg(y,h,g)}}).update(function(p,d){var g=s.getItemGraphicEl(d);if(!o.hasValue(p)){i.remove(g);return}var y=Cg(o,p),m=Dg(o,p,y,h),S=e1(o,m);g&&S!==g.__pictorialShapeStr&&(i.remove(g),o.setItemGraphicEl(p,null),g=null),g?CE(g,h,m):g=Mg(o,h,m,!0),o.setItemGraphicEl(p,g),g.__pictorialSymbolMeta=m,i.add(g),Lg(g,h,m)}).remove(function(p){var d=s.getItemGraphicEl(p);d&&Ig(s,p,d.__pictorialSymbolMeta.animationModel,d)}).execute();var f=t.get("clip",!0)?eo(t.coordinateSystem,!1,t):null;return f?i.setClipPath(f):i.removeClipPath(),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){Ig(i,q(o).dataIndex,t,o)}):n.removeAll()},e.type="pictorialBar",e})(bt);function Dg(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(),h={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};xE(t,i,n,a,h),bE(r,e,n,i,o,h.boundingLength,h.pxSign,c,a,h),wE(t,h.symbolScale,u,a,h);var f=h.symbolSize,p=La(t.get("symbolOffset"),f);return AE(t,f,n,i,o,p,s,h.valueLineWidth,h.boundingLength,h.repeatCutLength,a,h),h}function xE(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(B(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]);var h=i.xy==="x",f=s.inverse;n.pxSign=h&&!f||!h&&f?c>=0?1:-1:c>0?1:-1}function Ru(r,e){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(e)))}function bE(r,e,t,a,n,i,o,s,l,u){var c=l.valueDim,v=l.categoryDim,h=Math.abs(t[v.wh]),f=r.getItemVisual(e,"symbolSize"),p;B(f)?p=f.slice():f==null?p=["100%","100%"]:p=[f,f],p[v.index]=H(p[v.index],h),p[c.index]=H(p[c.index],a?h: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 wE(r,e,t,a,n){var i=r.get(SE)||0;i&&(Pu.attr({scaleX:e[0],scaleY:e[1],rotation:t}),Pu.updateTransform(),i/=Pu.getLineScale(),i*=e[a.valueDim.index]),n.valueLineWidth=i||0}function AE(r,e,t,a,n,i,o,s,l,u,c,v){var h=c.categoryDim,f=c.valueDim,p=v.pxSign,d=Math.max(e[f.index]+s,0),g=d;if(a){var y=Math.abs(l),m=Qt(r.get("symbolMargin"),"15%")+"",S=!1;m.lastIndexOf("!")===m.length-1&&(S=!0,m=m.slice(0,m.length-1));var _=H(m,e[f.index]),x=Math.max(d+_*2,0),b=S?0:_*2,A=$m(a),T=A?a:Pg((y+b)/x),D=y-T*d;_=D/2/(S?T:Math.max(T-1,1)),x=d+_*2,b=S?0:_*2,!A&&a!=="fixed"&&(T=u?Pg((Math.abs(u)+b)/x):0),g=T*x-b,v.repeatTimes=T,v.symbolMargin=_}var C=p*(g/2),M=v.pathPosition=[];M[h.index]=t[h.wh]/2,M[f.index]=o==="start"?C:o==="end"?l-C:l/2,i&&(M[0]+=i[0],M[1]+=i[1]);var I=v.bundlePosition=[];I[h.index]=t[h.xy],I[f.index]=t[f.xy];var L=v.barRectShape=z({},t);L[f.wh]=p*Math.max(Math.abs(t[f.wh]),Math.abs(M[f.index]+C)),L[h.wh]=t[h.wh];var R=v.clipShape={};R[h.xy]=-t[h.xy],R[h.wh]=c.ecSize[h.wh],R[f.xy]=0,R[f.wh]=t[f.wh]}function qx(r){var e=r.symbolPatternSize,t=Wt(r.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function jx(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(Lh(r,function(d){d.__pictorialAnimationIndex=c,d.__pictorialRepeatTimes=u,c<u?nn(d,null,p(c),t,a):nn(d,null,{scaleX:0,scaleY:0},t,a,function(){n.remove(d)}),c++});c<u;c++){var h=qx(t);h.__pictorialAnimationIndex=c,h.__pictorialRepeatTimes=u,n.add(h);var f=p(c);nn(h,{x:f.x,y:f.y,scaleX:0,scaleY:0},{scaleX:f.scaleX,scaleY:f.scaleY,rotation:f.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 Jx(r,e,t,a){var n=r.__pictorialBundle,i=r.__pictorialMainPath;i?nn(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=qx(t),n.add(i),nn(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 Qx(r,e,t){var a=z({},e.barRectShape),n=r.__pictorialBarRect;n?nn(n,null,{shape:a},e,t):(n=r.__pictorialBarRect=new dt({z2:2,shape:a,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function t1(r,e,t,a){if(t.symbolClip){var n=r.__pictorialClipPath,i=z({},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 dt({shape:i}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[o.wh]=t.clipShape[o.wh],Ia[a?"updateProps":"initProps"](n,{shape:u},s,l)}}}function Cg(r,e){var t=r.getItemModel(e);return t.getAnimationDelayParams=TE,t.isAnimationEnabled=DE,t}function TE(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function DE(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Mg(r,e,t,a){var n=new et,i=new et;return n.add(i),n.__pictorialBundle=i,i.x=t.bundlePosition[0],i.y=t.bundlePosition[1],t.symbolRepeat?jx(n,e,t):Jx(n,e,t),Qx(n,t,a),t1(n,e,t,a),n.__pictorialShapeStr=e1(r,t),n.__pictorialSymbolMeta=t,n}function CE(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?jx(r,e,t,!0):Jx(r,e,t,!0),Qx(r,t,!0),t1(r,e,t,!0)}function Ig(r,e,t,a){var n=a.__pictorialBarRect;n&&n.removeTextContent();var i=[];Lh(a,function(o){i.push(o)}),a.__pictorialMainPath&&i.push(a.__pictorialMainPath),a.__pictorialClipPath&&(t=null),w(i,function(o){zr(o,{scaleX:0,scaleY:0},t,e,function(){a.parent&&a.parent.remove(a)})}),r.setItemGraphicEl(e,null)}function e1(r,e){return[r.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function Lh(r,e,t){w(r.__pictorialBundle.children(),function(a){a!==r.__pictorialBarRect&&e.call(t,a)})}function nn(r,e,t,a,n,i){e&&r.attr(e),a.symbolClip&&!n?t&&r.attr(t):t&&Ia[n?"updateProps":"initProps"](r,t,a.animationModel,a.dataIndex,i)}function Lg(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"),h=i.get("scale");Lh(r,function(d){if(d instanceof Ne){var g=d.style;d.useStyle(z({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,h&&(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 f=e.valueDim.posDesc[+(t.boundingLength>0)],p=r.__pictorialBarRect;p.ignoreClip=!0,ae(p,qt(n),{labelFetcher:e.seriesModel,labelDataIndex:a,defaultText:cn(e.seriesModel.getData(),a),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:f}),kt(r,c,v,i.get("disabled"))}function Pg(r){var e=Math.round(r);return Math.abs(r-e)<1e-4?e:Math.ceil(r)}var ME=(function(r){E(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=Yr(Ii.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e})(Ii);function IE(r){r.registerChartView(_E),r.registerSeriesModel(ME),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,tt(RS,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,ES("pictorialBar"))}var LE=(function(r){E(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 h(g){return g.name}var f=new dr(this._layersSeries||[],l,h,h),p=[];f.add(U(d,this,"add")).update(U(d,this,"update")).remove(U(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 D=i.getItemLayout(A[T]),C=D.x,M=D.y0,I=D.y;_.push(C,M),x.push(C,M+I),b=i.getItemVisual(A[T],"style")}var L,R=i.getItemLayout(A[0]),P=t.getModel("label"),k=P.get("margin"),O=t.getModel("emphasis");if(g==="add"){var N=p[y]=new et;L=new bS({shape:{points:_,stackedOnPoints:x,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),N.add(L),s.add(N),t.isAnimationEnabled()&&L.setClipPath(PE(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:_,stackedOnPoints:x}},t),Ue(L)}ae(L,qt(t),{labelDataIndex:A[T-1],defaultText:i.getName(A[T-1]),inheritColor:b.fill},{normal:{verticalAlign:"middle"}}),L.setTextConfig({position:null,local:!0});var V=L.getTextContent();V&&(V.x=R.x-k,V.y=R.y0+R.y/2),L.useStyle(b),i.setItemGraphicEl(y,L),re(L,t),kt(L,O.get("focus"),O.get("blurScope"),O.get("disabled"))}this._layersSeries=l,this._layers=p},e.type="themeRiver",e})(bt);function PE(r,e,t){var a=new dt({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return Pt(a,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},e,t),a}var Eu=2,RE=(function(r){E(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 no(U(this.getData,this),U(this.getRawData,this))},e.prototype.fixData=function(t){var a=t.length,n={},i=uc(t,function(h){return n.hasOwnProperty(h[0]+"")||(n[h[0]+""]=-1),h[2]}),o=[];i.buckets.each(function(h,f){o.push({name:f,dataList:h})});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",Ht).models[0],i=n.get("type"),o=_t(t.data,function(p){return p[2]!==void 0}),s=this.fixData(o||[]),l=[],u=this.nameMap=$(),c=0,v=0;v<s.length;++v)l.push(s[v][Eu]),u.get(s[v][Eu])||(u.set(s[v][Eu],c),c++);var h=ji(s,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:ms(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,f=new he(h,this);return f.initData(s),f},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=uc(n,function(u){return t.get("name",u)}),l=[];return s.buckets.each(function(u,c){u.sort(function(v,h){return t.get(o,v)-t.get(o,h)}),l.push({name:c,indices:u})}),l},e.prototype.getAxisTooltipData=function(t,a,n){B(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,h=-1,f=o[c].indices.length,p=0;p<f;++p){var d=i.get(t[0],o[c].indices[p]),g=Math.abs(d-a);g<=v&&(u=d,v=g,h=o[c].indices[p])}s.push(h)}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 jt("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})(Ct);function EE(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]=H(s[0],o.height),s[1]=H(s[1],o.height);var u=o.height-s[0]-s[1];Rg(a,t,u)}else{s[0]=H(s[0],o.width),s[1]=H(s[1],o.width);var c=o.width-s[0]-s[1];Rg(a,t,c)}a.setLayout("layoutInfo",i)})}function Rg(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=kE(s),u=l.y0,c=t/l.max,v=n.length,h=n[0].indices.length,f,p=0;p<h;++p){f=u[p]*c,r.setItemLayout(n[0].indices[p],{layerIndex:0,x:s[0][p][0],y0:f,y:s[0][p][1]*c});for(var d=1;d<v;++d)f+=s[d-1][p][1]*c,r.setItemLayout(n[d].indices[p],{layerIndex:d,x:s[d][p][0],y0:f,y:s[d][p][1]*c})}}function kE(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 NE(r){r.registerChartView(LE),r.registerSeriesModel(RE),r.registerLayout(EE),r.registerProcessor(ao("themeRiver"))}var OE=2,VE=4,Eg=(function(r){E(e,r);function e(t,a,n,i){var o=r.call(this)||this;o.z2=OE,o.textConfig={inside:!0},q(o).seriesIndex=a.seriesIndex;var s=new vt({z2:VE,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=z({},c);v.label=null;var h=a.getVisual("style");h.lineJoin="bevel";var f=a.getVisual("decal");f&&(h.decal=vn(f,o));var p=ca(l.getModel("itemStyle"),v,!0);z(v,p),w(de,function(m){var S=s.ensureState(m),_=l.getModel([m,"itemStyle"]);S.style=_.getItemStyle();var x=ca(_,v);x&&(S.shape=x)}),t?(s.setShape(v),s.shape.r=c.r0,Pt(s,{shape:{r:c.r}},n,a.dataIndex)):(ft(s,{shape:v},n),Ue(s)),s.useStyle(h),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==="relative"?_i(a.getAncestorsIndices(),a.getDescendantIndices()):g==="ancestor"?a.getAncestorsIndices():g==="descendant"?a.getDescendantIndices():g;kt(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,h=v.getTextContent(),f=this.node.dataIndex,p=i.get("minAngle")/180*Math.PI,d=i.get("show")&&!(p!=null&&Math.abs(s)<p);h.ignore=!d,w(Ai,function(y){var m=y==="normal"?n.getModel("label"):n.getModel([y,"label"]),S=y==="normal",_=S?h:h.ensureState(y),x=t.getFormattedLabel(f,y);S&&(x=x||a.node.name),_.style=Dt(m,{},null,y!=="normal",!0),x&&(_.style.text=x);var b=m.get("show");b!=null&&!S&&(_.ignore=!b);var A=g(m,"position"),T=S?v:v.states[y],D=T.style.fill;T.textConfig={outsideFill:m.get("color")==="inherit"?D:null,inside:A!=="outside"};var C,M=g(m,"distance")||0,I=g(m,"align"),L=g(m,"rotate"),R=Math.PI*.5,P=Math.PI*1.5,k=lr(L==="tangential"?Math.PI/2-l:l),O=k>R&&!bi(k-R)&&k<P;A==="outside"?(C=o.r+M,I=O?"right":"left"):!I||I==="center"?(s===2*Math.PI&&o.r0===0?C=0:C=(o.r+o.r0)/2,I="center"):I==="left"?(C=o.r0+M,I=O?"right":"left"):I==="right"&&(C=o.r-M,I=O?"left":"right"),_.style.align=I,_.style.verticalAlign=g(m,"verticalAlign")||"middle",_.x=C*u+o.cx,_.y=C*c+o.cy;var N=0;L==="radial"?N=lr(-l)+(O?Math.PI:0):L==="tangential"?N=lr(Math.PI/2-l)+(O?Math.PI:0):St(L)&&(N=L*Math.PI/180),_.rotation=lr(N)});function g(y,m){var S=y.get(m);return S??i.get(m)}h.dirtyStyle()},e})(Ee),tv="sunburstRootToNode",kg="sunburstHighlight",BE="sunburstUnhighlight";function zE(r){r.registerAction({type:tv,update:"updateView"},function(e,t){t.eachComponent({mainType:"series",subType:"sunburst",query:e},a);function a(n,i){var o=Ni(e,[tv],n);if(o){var s=n.getViewRoot();s&&(e.direction=ph(s,o.node)?"rollUp":"drillDown"),n.resetViewRoot(o.node)}}}),r.registerAction({type:kg,update:"none"},function(e,t,a){e=z({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},n);function n(i){var o=Ni(e,[kg],i);o&&(e.dataIndex=o.node.dataIndex)}a.dispatchAction(z(e,{type:"highlight"}))}),r.registerAction({type:BE,update:"updateView"},function(e,t,a){e=z({},e),a.dispatchAction(z(e,{type:"downplay"}))})}var GE=(function(r){E(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"),h=[];u.eachNode(function(m){h.push(m)});var f=this._oldChildren||[];p(h,f),y(l,u),this._initEvents(),this._oldChildren=h;function p(m,S){if(m.length===0&&S.length===0)return;new dr(S,m,_,_).add(x).update(x).remove(tt(x,null)).execute();function _(b){return b.getId()}function x(b,A){var T=b==null?null:m[b],D=A==null?null:S[A];d(T,D)}}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 _=new Eg(m,t,a,n);c.add(_),s.setItemGraphicEl(m.dataIndex,_)}}}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 Eg(m,t,a,n),c.add(o.virtualPiece)),S.piece.off("click"),o.virtualPiece.on("click",function(_){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";_s(u,c)}}n=!0}})})},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:tv,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})(bt),FE=(function(r){E(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};r1(n);var i=this._levelModels=G(t.levels||[],function(l){return new mt(l,this,a)},this),o=fh.createTree(n,this,s);function s(l){l.wrapMethod("getItemModel",function(u,c){var v=o.getNodeByDataIndex(c),h=i[v.depth];return h&&(u.parentModel=h),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(){sx(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})(Ct);function r1(r){var e=0;w(r.children,function(a){r1(a);var n=a.value;B(n)&&(n=n[0]),e+=n});var t=r.value;B(t)&&(t=t[0]),(t==null||isNaN(t))&&(t=e),t<0&&(t=0),B(r.value)?r.value[0]=t:r.value=t}var Ng=Math.PI/180;function HE(r,e,t){e.eachSeriesByType(r,function(a){var n=a.get("center"),i=a.get("radius");B(i)||(i=[0,i]),B(n)||(n=[n,n]);var o=t.getWidth(),s=t.getHeight(),l=Math.min(o,s),u=H(n[0],o),c=H(n[1],s),v=H(i[0],l/2),h=H(i[1],l/2),f=-a.get("startAngle")*Ng,p=a.get("minAngle")*Ng,d=a.getData().tree.root,g=a.getViewRoot(),y=g.depth,m=a.get("sort");m!=null&&a1(g,m);var S=0;w(g.children,function(k){!isNaN(k.getValue())&&S++});var _=g.getValue(),x=Math.PI/(_||S)*2,b=g.depth>0,A=g.height-(b?-1:1),T=(h-v)/(A||1),D=a.get("clockwise"),C=a.get("stillShowZeroSum"),M=D?1:-1,I=function(k,O){if(k){var N=O;if(k!==d){var V=k.getValue(),F=_===0&&C?x:V*x;F<p&&(F=p),N=O+M*F;var W=k.depth-y-(b?-1:1),X=v+T*W,rt=v+T*(W+1),at=a.getLevelModel(k);if(at){var st=at.get("r0",!0),Vt=at.get("r",!0),me=at.get("radius",!0);me!=null&&(st=me[0],Vt=me[1]),st!=null&&(X=H(st,l/2)),Vt!=null&&(rt=H(Vt,l/2))}k.setLayout({angle:F,startAngle:O,endAngle:N,clockwise:D,cx:u,cy:c,r0:X,r:rt})}if(k.children&&k.children.length){var ht=0;w(k.children,function(ot){ht+=I(ot,O+ht)})}return N-O}};if(b){var L=v,R=v+T,P=Math.PI*2;d.setLayout({angle:P,startAngle:f,endAngle:f+P,clockwise:D,cx:u,cy:c,r0:L,r:R})}I(g,f)})}function a1(r,e){var t=r.children||[];r.children=WE(t,e),t.length&&w(r.children,function(a){a1(a,e)})}function WE(r,e){if(K(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 UE(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&&Y(s)&&(s=Eb(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");z(u,l)})})}function YE(r){r.registerChartView(GE),r.registerSeriesModel(FE),r.registerLayout(tt(HE,"sunburst")),r.registerProcessor(tt(ao,"sunburst")),r.registerVisual(UE),zE(r)}var Og={color:"fill",borderColor:"stroke"},ZE={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},cr=ut(),$E=(function(r){E(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 _r(null,this)},e.prototype.getDataParams=function(t,a,n){var i=r.prototype.getDataParams.call(this,t,a);return n&&(i.info=cr(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})(Ct);function XE(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 KE(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:U(XE,r)}}}function qE(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 jE(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:U(qE,r)}}}function JE(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 QE(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:U(JE,r)}}}function tk(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 ek(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:U(tk,r)}}}function rk(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 n1(r,e,t,a){return r&&(r.legacy||r.legacy!==!1&&!t&&!a&&e!=="tspan"&&(e==="text"||Z(r,"text")))}function i1(r,e,t){var a=r,n,i,o;if(e==="text")o=a;else{o={},Z(a,"text")&&(o.text=a.text),Z(a,"rich")&&(o.rich=a.rich),Z(a,"textFill")&&(o.fill=a.textFill),Z(a,"textStroke")&&(o.stroke=a.textStroke),Z(a,"fontFamily")&&(o.fontFamily=a.fontFamily),Z(a,"fontSize")&&(o.fontSize=a.fontSize),Z(a,"fontStyle")&&(o.fontStyle=a.fontStyle),Z(a,"fontWeight")&&(o.fontWeight=a.fontWeight),i={type:"text",style:o,silent:!0},n={};var s=Z(a,"textPosition");t?n.position=s?a.textPosition:"inside":s&&(n.position=a.textPosition),Z(a,"textPosition")&&(n.position=a.textPosition),Z(a,"textOffset")&&(n.offset=a.textOffset),Z(a,"textRotation")&&(n.rotation=a.textRotation),Z(a,"textDistance")&&(n.distance=a.textDistance)}return Vg(o,r),w(o.rich,function(l){Vg(l,l)}),{textConfig:n,textContent:i}}function Vg(r,e){e&&(e.font=e.textFont||e.font,Z(e,"textStrokeWidth")&&(r.lineWidth=e.textStrokeWidth),Z(e,"textAlign")&&(r.align=e.textAlign),Z(e,"textVerticalAlign")&&(r.verticalAlign=e.textVerticalAlign),Z(e,"textLineHeight")&&(r.lineHeight=e.textLineHeight),Z(e,"textWidth")&&(r.width=e.textWidth),Z(e,"textHeight")&&(r.height=e.textHeight),Z(e,"textBackgroundColor")&&(r.backgroundColor=e.textBackgroundColor),Z(e,"textPadding")&&(r.padding=e.textPadding),Z(e,"textBorderColor")&&(r.borderColor=e.textBorderColor),Z(e,"textBorderWidth")&&(r.borderWidth=e.textBorderWidth),Z(e,"textBorderRadius")&&(r.borderRadius=e.textBorderRadius),Z(e,"textBoxShadowColor")&&(r.shadowColor=e.textBoxShadowColor),Z(e,"textBoxShadowBlur")&&(r.shadowBlur=e.textBoxShadowBlur),Z(e,"textBoxShadowOffsetX")&&(r.shadowOffsetX=e.textBoxShadowOffsetX),Z(e,"textBoxShadowOffsetY")&&(r.shadowOffsetY=e.textBoxShadowOffsetY))}function Bg(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";zg(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){zg(s,s)}),a}function zg(r,e){e&&(Z(e,"fill")&&(r.textFill=e.fill),Z(e,"stroke")&&(r.textStroke=e.fill),Z(e,"lineWidth")&&(r.textStrokeWidth=e.lineWidth),Z(e,"font")&&(r.font=e.font),Z(e,"fontStyle")&&(r.fontStyle=e.fontStyle),Z(e,"fontWeight")&&(r.fontWeight=e.fontWeight),Z(e,"fontSize")&&(r.fontSize=e.fontSize),Z(e,"fontFamily")&&(r.fontFamily=e.fontFamily),Z(e,"align")&&(r.textAlign=e.align),Z(e,"verticalAlign")&&(r.textVerticalAlign=e.verticalAlign),Z(e,"lineHeight")&&(r.textLineHeight=e.lineHeight),Z(e,"width")&&(r.textWidth=e.width),Z(e,"height")&&(r.textHeight=e.height),Z(e,"backgroundColor")&&(r.textBackgroundColor=e.backgroundColor),Z(e,"padding")&&(r.textPadding=e.padding),Z(e,"borderColor")&&(r.textBorderColor=e.borderColor),Z(e,"borderWidth")&&(r.textBorderWidth=e.borderWidth),Z(e,"borderRadius")&&(r.textBorderRadius=e.borderRadius),Z(e,"shadowColor")&&(r.textBoxShadowColor=e.shadowColor),Z(e,"shadowBlur")&&(r.textBoxShadowBlur=e.shadowBlur),Z(e,"shadowOffsetX")&&(r.textBoxShadowOffsetX=e.shadowOffsetX),Z(e,"shadowOffsetY")&&(r.textBoxShadowOffsetY=e.shadowOffsetY),Z(e,"textShadowColor")&&(r.textShadowColor=e.textShadowColor),Z(e,"textShadowBlur")&&(r.textShadowBlur=e.textShadowBlur),Z(e,"textShadowOffsetX")&&(r.textShadowOffsetX=e.textShadowOffsetX),Z(e,"textShadowOffsetY")&&(r.textShadowOffsetY=e.textShadowOffsetY))}var o1={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},Gg=Ut(o1);on(xi,function(r,e){return r[e]=1,r},{});xi.join(", ");var ks=["","style","shape","extra"],dn=ut();function Ph(r,e,t,a,n){var i=r+"Animation",o=wn(r,a,n)||{},s=dn(e).userDuring;return o.duration>0&&(o.during=s?U(sk,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=r),z(o,t[i]),o}function as(r,e,t,a){a=a||{};var n=a.dataIndex,i=a.isInit,o=a.clearStyle,s=t.isAnimationEnabled(),l=dn(r),u=e.style;l.userDuring=e.during;var c={},v={};if(uk(r,e,v),Hg("shape",e,v),Hg("extra",e,v),!i&&s&&(lk(r,e,c),Fg("shape",r,e,c),Fg("extra",r,e,c),ck(r,e,u,c)),v.style=u,ak(r,v,o),ik(r,e),s)if(i){var h={};w(ks,function(p){var d=p?e[p]:e;d&&d.enterFrom&&(p&&(h[p]=h[p]||{}),z(p?h[p]:h,d.enterFrom))});var f=Ph("enter",r,e,t,n);f.duration>0&&r.animateFrom(h,f)}else nk(r,e,n||0,t,c);s1(r,e),u?r.dirty():r.markRedraw()}function s1(r,e){for(var t=dn(r).leaveToProps,a=0;a<ks.length;a++){var n=ks[a],i=n?e[n]:e;i&&i.leaveTo&&(t||(t=dn(r).leaveToProps={}),n&&(t[n]=t[n]||{}),z(n?t[n]:t,i.leaveTo))}}function yl(r,e,t,a){if(r){var n=r.parent,i=dn(r).leaveToProps;if(i){var o=Ph("update",r,e,t,0);o.done=function(){n.remove(r)},r.animateTo(i,o)}else n.remove(r)}}function ya(r){return r==="all"}function ak(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 nk(r,e,t,a,n){if(n){var i=Ph("update",r,e,a,t);i.duration>0&&r.animateFrom(n,i)}}function ik(r,e){Z(e,"silent")&&(r.silent=e.silent),Z(e,"ignore")&&(r.ignore=e.ignore),r instanceof ma&&Z(e,"invisible")&&(r.invisible=e.invisible),r instanceof Mt&&Z(e,"autoBatch")&&(r.autoBatch=e.autoBatch)}var $e={},ok={setTransform:function(r,e){return $e.el[r]=e,this},getTransform:function(r){return $e.el[r]},setShape:function(r,e){var t=$e.el,a=t.shape||(t.shape={});return a[r]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(r){var e=$e.el.shape;if(e)return e[r]},setStyle:function(r,e){var t=$e.el,a=t.style;return a&&(a[r]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(r){var e=$e.el.style;if(e)return e[r]},setExtra:function(r,e){var t=$e.el.extra||($e.el.extra={});return t[r]=e,this},getExtra:function(r){var e=$e.el.extra;if(e)return e[r]}};function sk(){var r=this,e=r.el;if(e){var t=dn(e).userDuring,a=r.userDuring;if(t!==a){r.el=r.userDuring=null;return}$e.el=e,a(ok)}}function Fg(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]={}),ya(l))z(o,i);else for(var u=xt(l),c=0;c<u.length;c++){var v=u[c],h=i[v];o[v]=h}else if(ya(s)||ct(s,r)>=0){!o&&(o=a[r]={});for(var f=Ut(i),c=0;c<f.length;c++){var v=f[c],h=i[v];vk(n[v],h)&&(o[v]=h)}}}}}function Hg(r,e,t){var a=e[r];if(a)for(var n=t[r]={},i=Ut(a),o=0;o<i.length;o++){var s=i[o];n[s]=kb(a[s])}}function lk(r,e,t){for(var a=e.transition,n=ya(a)?xi:xt(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 uk(r,e,t){for(var a=0;a<Gg.length;a++){var n=Gg[a],i=o1[n],o=e[n];o&&(t[i[0]]=o[0],t[i[1]]=o[1])}for(var a=0;a<xi.length;a++){var s=xi[a];e[s]!=null&&(t[s]=e[s])}}function ck(r,e,t,a){if(t){var n=r.style,i;if(n){var o=t.transition,s=e.transition;if(o&&!ya(o)){var l=xt(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&&(ya(s)||ya(o)||ct(s,"style")>=0)){var h=r.getAnimationStyleProps(),f=h?h.style:null;if(f){!i&&(i=a.style={});for(var p=Ut(t),u=0;u<p.length;u++){var c=p[u];if(f[c]){var v=n[c];i[c]=v}}}}}}}function vk(r,e){return yn(r)?r!==e:r!=null&&isFinite(r)}var l1=ut(),hk=["percent","easing","shape","style","extra"];function u1(r){r.stopAnimation("keyframe"),r.attr(l1(r))}function Ns(r,e,t){if(!(!t.isAnimationEnabled()||!e)){if(B(e)){w(e,function(s){Ns(r,s,t)});return}var a=e.keyframes,n=e.duration;if(t&&n==null){var i=wn("enter",t,0);n=i&&i.duration}if(!(!a||!n)){var o=l1(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 h=Ut(v);if(s||(h=_t(h,function(d){return ct(hk,d)<0})),!!h.length){l||(l=r.animate(s,e.loop,!0),l.scope="keyframe");for(var f=0;f<c.length;f++)c[f]!==l&&c[f].targetName===l.targetName&&c[f].stopTracks(h);s&&(o[s]=o[s]||{});var p=s?o[s]:o;w(h,function(d){p[d]=((s?r[s]:r)||{})[d]}),l.whenWithKeys(n*u.percent,v,h,u.easing)}}}),l&&l.delay(e.delay||0).duration(n).start(e.easing)}})}}}var vr="emphasis",Rr="normal",Rh="blur",Eh="select",Wr=[Rr,vr,Rh,Eh],ku={normal:["itemStyle"],emphasis:[vr,"itemStyle"],blur:[Rh,"itemStyle"],select:[Eh,"itemStyle"]},Nu={normal:["label"],emphasis:[vr,"label"],blur:[Rh,"label"],select:[Eh,"label"]},fk=["x","y"],pk="e\0\0",Ae={normal:{},emphasis:{},blur:{},select:{}},dk={cartesian2d:KE,geo:jE,single:QE,polar:ek,calendar:rk};function ev(r){return r instanceof Mt}function rv(r){return r instanceof ma}function gk(r,e){e.copyTransform(r),rv(e)&&rv(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,ev(e)&&ev(r)&&e.setShape(r.shape))}var yk=(function(r){E(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=Wg(t,s,a,n);o||l.removeAll(),s.diff(o).add(function(v){Ou(n,null,v,u(v,i),t,l,s)}).remove(function(v){var h=o.getItemGraphicEl(v);h&&yl(h,cr(h).option,t)}).update(function(v,h){var f=o.getItemGraphicEl(h);Ou(n,f,v,u(v,i),t,l,s)}).execute();var c=t.get("clip",!0)?eo(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=Wg(a,s,n,i),u=this._progressiveEls=[];function c(f){f.isGroup||(f.incremental=!0,f.ensureState("emphasis").hoverLayer=!0)}for(var v=t.start;v<t.end;v++){var h=Ou(null,null,v,l(v,o),a,this.group,s);h&&(h.traverse(c),u.push(h))}},e.prototype.eachRendered=function(t){Ur(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})(bt);function kh(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=h1(a);t=Ks(i,null,n,a.layout||"center"),cr(t).customPathData=i}else if(e==="image")t=new Ne({}),cr(t).customImagePath=r.style.image;else if(e==="text")t=new vt({});else if(e==="group")t=new et;else{if(e==="compoundPath")throw new Error('"compoundPath" is not supported yet.');var o=Iv(e);if(!o){var s="";gt(s)}t=new o}return cr(t).customGraphicType=e,t.name=r.name,t.z2EmphasisLift=1,t.z2SelectLift=1,t}function Nh(r,e,t,a,n,i,o){u1(e);var s=n&&n.normal.cfg;s&&e.setTextConfig(s),a&&a.transition==null&&(a.transition=fk);var l=a&&a.style;if(l){if(e.type==="text"){var u=l;Z(u,"textFill")&&(u.fill=u.textFill),Z(u,"textStroke")&&(u.stroke=u.textStroke)}var c=void 0,v=ev(e)?l.decal:null;r&&v&&(v.dirty=!0,c=vn(v,r)),l.__decalPattern=c}if(rv(e)&&l){var c=l.__decalPattern;c&&(l.decal=c)}as(e,a,i,{dataIndex:t,isInit:o,clearStyle:!0}),Ns(e,a.keyframeAnimation,i)}function c1(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),wa(i)}}function mk(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<Wr.length;s++)Sk(a,e,Wr[s])}}function Sk(r,e,t){var a=t===Rr,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 Wg(r,e,t,a){var n=r.get("renderItem"),i=r.coordinateSystem,o={};i&&(o=i.prepareCustoms?i.prepareCustoms(i):dk[i.type](i));for(var s=Q({getWidth:a.getWidth,getHeight:a.getHeight,getZr:a.getZr,getDevicePixelRatio:a.getDevicePixelRatio,value:_,style:b,ordinalRawValue:x,styleEmphasis:A,visual:C,barLayout:M,currentSeriesIndices:I,font:L},o.api||{}),l={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:o.coordSys,dataInsideLength:e.count(),encode:_k(r.getData())},u,c,v={},h={},f={},p={},d=0;d<Wr.length;d++){var g=Wr[d];f[g]=r.getModel(ku[g]),p[g]=r.getModel(Nu[g])}function y(R){return R===u?c||(c=e.getItemModel(R)):e.getItemModel(R)}function m(R,P){return e.hasItemOption?R===u?v[P]||(v[P]=y(R).getModel(ku[P])):y(R).getModel(ku[P]):f[P]}function S(R,P){return e.hasItemOption?R===u?h[P]||(h[P]=y(R).getModel(Nu[P])):y(R).getModel(Nu[P]):p[P]}return function(R,P){return u=R,c=null,v={},h={},n&&n(Q({dataIndexInside:R,dataIndex:e.getRawIndex(R),actionType:P?P.type:null},l),s)};function _(R,P){return P==null&&(P=u),e.getStore().get(e.getDimensionIndex(R||0),P)}function x(R,P){P==null&&(P=u),R=R||0;var k=e.getDimensionInfo(R);if(!k){var O=e.getDimensionIndex(R);return O>=0?e.getStore().get(O,P):void 0}var N=e.get(k.name,P),V=k&&k.ordinalMeta;return V?V.categories[N]:N}function b(R,P){P==null&&(P=u);var k=e.getItemVisual(P,"style"),O=k&&k.fill,N=k&&k.opacity,V=m(P,Rr).getItemStyle();O!=null&&(V.fill=O),N!=null&&(V.opacity=N);var F={inheritColor:Y(O)?O:"#000"},W=S(P,Rr),X=Dt(W,null,F,!1,!0);X.text=W.getShallow("show")?pt(r.getFormattedLabel(P,Rr),cn(e,P)):null;var rt=ys(W,F,!1);return D(R,V),V=Bg(V,X,rt),R&&T(V,R),V.legacy=!0,V}function A(R,P){P==null&&(P=u);var k=m(P,vr).getItemStyle(),O=S(P,vr),N=Dt(O,null,null,!0,!0);N.text=O.getShallow("show")?mn(r.getFormattedLabel(P,vr),r.getFormattedLabel(P,Rr),cn(e,P)):null;var V=ys(O,null,!0);return D(R,k),k=Bg(k,N,V),R&&T(k,R),k.legacy=!0,k}function T(R,P){for(var k in P)Z(P,k)&&(R[k]=P[k])}function D(R,P){R&&(R.textFill&&(P.textFill=R.textFill),R.textPosition&&(P.textPosition=R.textPosition))}function C(R,P){if(P==null&&(P=u),Z(Og,R)){var k=e.getItemVisual(P,"style");return k?k[Og[R]]:null}if(Z(ZE,R))return e.getItemVisual(P,R)}function M(R){if(i.type==="cartesian2d"){var P=i.getBaseAxis();return uD(Q({axis:P},R))}}function I(){return t.getCurrentSeriesIndices()}function L(R){return Lv(R,t)}}function _k(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 Ou(r,e,t,a,n,i,o){if(!a){i.remove(e);return}var s=Oh(r,e,t,a,n,i);return s&&o.setItemGraphicEl(t,s),s&&kt(s,a.focus,a.blurScope,a.emphasisDisabled),s}function Oh(r,e,t,a,n,i){var o=-1,s=e;e&&v1(e,a,n)&&(o=ct(i.childrenRef(),e),e=null);var l=!e,u=e;u?u.clearStates():(u=kh(a),s&&gk(s,u)),a.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),Ae.normal.cfg=Ae.normal.conOpt=Ae.emphasis.cfg=Ae.emphasis.conOpt=Ae.blur.cfg=Ae.blur.conOpt=Ae.select.cfg=Ae.select.conOpt=null,Ae.isLegacy=!1,bk(u,t,a,n,l,Ae),xk(u,t,a,n,l),Nh(r,u,t,a,Ae,n,l),Z(a,"info")&&(cr(u).info=a.info);for(var c=0;c<Wr.length;c++){var v=Wr[c];if(v!==Rr){var h=Os(a,v),f=Vh(a,h,v);c1(v,u,h,f,Ae)}}return mk(u,a,n),a.type==="group"&&wk(r,u,t,a,n),o>=0?i.replaceAt(u,o):i.add(u),u}function v1(r,e,t){var a=cr(r),n=e.type,i=e.shape,o=e.style;return t.isUniversalTransitionEnabled()||n!=null&&n!==a.customGraphicType||n==="path"&&Ck(i)&&h1(i)!==a.customPathData||n==="image"&&Z(o,"image")&&o.image!==a.customImagePath}function xk(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&&v1(o,i,a)&&(o=null),o||(o=kh(i),r.setClipPath(o)),Nh(null,o,e,i,null,a,n)}}function bk(r,e,t,a,n,i){if(!r.isGroup){Ug(t,null,i),Ug(t,vr,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=kh(o),r.setTextContent(c)),Nh(null,c,e,o,null,a,n);for(var v=o&&o.style,h=0;h<Wr.length;h++){var f=Wr[h];if(f!==Rr){var p=i[f].conOpt;c1(f,c,p,Vh(o,p,f),null)}}v?c.dirty():c.markRedraw()}}}}function Ug(r,e,t){var a=e?Os(r,e):r,n=e?Vh(r,a,vr):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||n1(n,i,!!o,!!l))){t.isLegacy=!0;var u=i1(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 Vh(r,e,t){var a=e&&e.style;return a==null&&t===vr&&r&&(a=r.styleEmphasis),a}function wk(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){Tk({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],h=e.childAt(c);v?(v.ignore==null&&(v.ignore=!1),Oh(r,h,t,v,n,e)):h.ignore=!0}for(var f=e.childCount()-1;f>=c;f--){var p=e.childAt(f);Ak(e,p,n)}}}function Ak(r,e,t){e&&yl(e,cr(r).option,t)}function Tk(r){new dr(r.oldChildren,r.newChildren,Yg,Yg,r).add(Zg).update(Zg).remove(Dk).execute()}function Yg(r,e){var t=r&&r.name;return t??pk+e}function Zg(r,e){var t=this.context,a=r!=null?t.newChildren[r]:null,n=e!=null?t.oldChildren[e]:null;Oh(t.api,n,t.dataIndex,a,t.seriesModel,t.group)}function Dk(r){var e=this.context,t=e.oldChildren[r];t&&yl(t,cr(t).option,e.seriesModel)}function h1(r){return r&&(r.pathData||r.d)}function Ck(r){return r&&(Z(r,"pathData")||Z(r,"d"))}function Mk(r){r.registerChartView(yk),r.registerSeriesModel($E)}var ia=ut(),$g=j,Vu=U,Bh=(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 et,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),a.getZr().add(s);else{var h=tt(Xg,t,v);this.updatePointerEl(s,u,h),this.updateLabelEl(s,u,h,t)}qg(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=oh(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=ia(e).pointerEl=new Ia[i.type]($g(t.pointer));e.add(o)}},r.prototype.createLabelEl=function(e,t,a,n){if(t.label){var i=ia(e).labelEl=new vt($g(t.label));e.add(i),Kg(i,n)}},r.prototype.updatePointerEl=function(e,t,a){var n=ia(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=ia(e).labelEl;i&&(i.setStyle(t.label.style),a(i,{x:t.label.x,y:t.label.y}),Kg(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=qi(i.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Br(u.event)},onmousedown:Vu(this._onHandleDragMove,this,0,0),drift:Vu(this._onHandleDragMove,this),ondragend:Vu(this._onHandleDragEnd,this)}),a.add(n)),qg(n,t,!1),n.setStyle(i.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=i.get("size");B(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,Pn(this,"_doDispatchAxisPointer",i.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},r.prototype._moveHandleToValue=function(e,t){Xg(this._axisPointerModel,!t&&this._moveAnimation,this._handle,Bu(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(Bu(a),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=n,a.stopAnimation(),a.attr(Bu(n)),ia(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),Li(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 Xg(r,e,t,a){f1(ia(t).lastProp,a)||(ia(t).lastProp=a,e?ft(t,a,r):(t.stopAnimation(),t.attr(a)))}function f1(r,e){if(J(r)&&J(e)){var t=!0;return w(e,function(a,n){t=t&&f1(r[n],a)}),!!t}else return r===e}function Kg(r,e){r[e.get(["label","show"])?"show":"hide"]()}function Bu(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function qg(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)})}function zh(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 p1(r,e,t,a,n){var i=t.get("value"),o=d1(i,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=Cn(s.get("padding")||0),u=s.getFont(),c=Ys(o,u),v=n.position,h=c.width+l[1]+l[3],f=c.height+l[0]+l[2],p=n.align;p==="right"&&(v[0]-=h),p==="center"&&(v[0]-=h/2);var d=n.verticalAlign;d==="bottom"&&(v[1]-=f),d==="middle"&&(v[1]-=f/2),Ik(v,h,f,a);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),r.label={x:v[0],y:v[1],style:Dt(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function Ik(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 d1(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:nh(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)}),Y(o)?i=o.replace("{value}",i):K(o)&&(i=o(s))}return i}function Gh(r,e,t){var a=_n();return Yi(a,a,t.rotation),Sa(a,a,t.position),We([r.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],a)}function g1(r,e,t,a,n,i){var o=fe.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=n.get(["label","margin"]),p1(e,a,n,i,{position:Gh(a.axis,r,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Fh(r,e,t){return t=t||0,{x1:r[t],y1:r[1-t],x2:e[t],y2:e[1-t]}}function y1(r,e,t){return t=t||0,{x:r[t],y:r[1-t],width:e[t],height:e[1-t]}}function jg(r,e,t,a,n,i){return{cx:r,cy:e,r0:t,r:a,startAngle:n,endAngle:i,clockwise:!0}}var Lk=(function(r){E(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=Jg(l,s).getOtherAxis(s).getGlobalExtent(),v=s.toGlobalCoord(s.dataToCoord(a,!0));if(u&&u!=="none"){var h=zh(i),f=Pk[u](s,v,c);f.style=h,t.graphicKey=f.type,t.pointer=f}var p=Oc(l.model,n);g1(a,t,p,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=Oc(a.axis.grid.model,a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=Gh(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=Jg(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 h=(u[1]+u[0])/2,f=[h,h];f[c]=v[c];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:v[0],y:v[1],rotation:t.rotation,cursorPoint:f,tooltipOption:p[c]}},e})(Bh);function Jg(r,e){var t={};return t[e.dim+"AxisIndex"]=e.index,r.getCartesian(t)}var Pk={line:function(r,e,t){var a=Fh([e,t[0]],[e,t[1]],Qg(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:y1([e-a/2,t[0]],[a,n],Qg(r))}}};function Qg(r){return r.dim==="x"?0:1}var Rk=(function(r){E(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),ur=ut(),Ek=w;function m1(r,e,t){if(!Nt.node){var a=e.getZr();ur(a).records||(ur(a).records={}),kk(a,e);var n=ur(a).records[r]||(ur(a).records[r]={});n.handler=t}}function kk(r,e){if(ur(r).initialized)return;ur(r).initialized=!0,t("click",tt(ty,"click")),t("mousemove",tt(ty,"mousemove")),t("globalout",Ok);function t(a,n){r.on(a,function(i){var o=Vk(e);Ek(ur(r).records,function(s){s&&n(s,i,o.dispatchAction)}),Nk(o.pendings,e)})}}function Nk(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 Ok(r,e,t){r.handler("leave",null,t)}function ty(r,e,t,a){e.handler(r,t,a)}function Vk(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 av(r,e){if(!Nt.node){var t=e.getZr(),a=(ur(t).records||{})[r];a&&(ur(t).records[r]=null)}}var Bk=(function(r){E(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";m1("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){av("axisPointer",a)},e.prototype.dispose=function(t,a){av("axisPointer",a)},e.type="axisPointer",e})(Rt);function S1(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||B(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,h=u.dim,f=v==="x"||v==="radius"?1:0,p=i.mapDimension(h),d=[];d[f]=i.get(p,o),d[1-f]=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 ey=ut();function zk(r,e,t){var a=r.currTrigger,n=[r.x,r.y],i=r,o=r.dispatchAction||U(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){ns(n)&&(n=S1({seriesIndex:i.seriesIndex,dataIndex:i.dataIndex},e).point);var l=ns(n),u=i.axesInfo,c=s.axesInfo,v=a==="leave"||ns(n),h={},f={},p={list:[],map:{}},d={showPointer:tt(Fk,f),showTooltip:tt(Hk,p)};w(s.coordSysMap,function(y,m){var S=l||y.containPoint(n);w(s.coordSysAxesInfo[m],function(_,x){var b=_.axis,A=Zk(u,_);if(!v&&S&&(!u||A)){var T=A&&A.value;T==null&&!l&&(T=b.pointToData(n)),T!=null&&ry(_,T,d,!1,h)}})});var g={};return w(c,function(y,m){var S=y.linkGroup;S&&!f[m]&&w(S.axesInfo,function(_,x){var b=f[x];if(_!==y&&b){var A=b.value;S.mapper&&(A=y.axis.scale.parse(S.mapper(A,ay(_),ay(y)))),g[y.key]=A}})}),w(g,function(y,m){ry(c[m],y,d,!0,h)}),Wk(f,c,h),Uk(p,n,r,o),Yk(c,o,t),h}}function ry(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=Gk(e,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&n.seriesIndex==null&&z(n,s[0]),!a&&r.snap&&i.containData(l)&&l!=null&&(e=l),t.showPointer(r,e,s),t.showTooltip(r,o,l)}}function Gk(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,h;if(l.getAxisTooltipData){var f=l.getAxisTooltipData(c,r,t);h=f.dataIndices,v=f.nestestValue}else{if(h=l.getData().indicesOfNearest(c[0],r,t.type==="category"?.5:null),!h.length)return;v=l.getData().get(c[0],h[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(h,function(g){i.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:i,snapToValue:n}}function Fk(r,e,t,a){r[e.key]={value:t,payloadBatch:a}}function Hk(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=ki(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 Wk(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 Uk(r,e,t,a){if(ns(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 Yk(r,e,t){var a=t.getZr(),n="axisPointerLastHighlights",i=ey(a)[n]||{},o=ey(a)[n]={};w(r,function(u,c){var v=u.axisPointerModel.option;v.status==="show"&&u.triggerEmphasis&&w(v.seriesDataIndices,function(h){var f=h.seriesIndex+" | "+h.dataIndex;o[f]=h})});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 Zk(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 ay(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 ns(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function uo(r){Ea.registerAxisPointerClass("CartesianAxisPointer",Lk),r.registerComponentModel(Rk),r.registerComponentView(Bk),r.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!B(t)&&(e.axisPointer.link=[t])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=oI(e,t)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},zk)}function $k(r){it($_),it(uo)}var Xk=(function(r){E(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),h=i.get("type");if(h&&h!=="none"){var f=zh(i),p=qk[h](s,l,v,c);p.style=f,t.graphicKey=p.type,t.pointer=p}var d=i.get(["label","margin"]),g=Kk(a,n,i,l,d);p1(t,n,i,o,g)},e})(Bh);function Kk(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 h=_n();Yi(h,h,s),Sa(h,h,[a.cx,a.cy]),u=We([o,-n],h);var f=e.getModel("axisLabel").get("rotate")||0,p=fe.innerTextLayout(s,f*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 qk={line:function(r,e,t,a){return r.dim==="angle"?{type:"Line",shape:Fh(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:jg(e.cx,e.cy,a[0],a[1],(-t-n/2)*i,(-t+n/2)*i)}:{type:"Sector",shape:jg(e.cx,e.cy,t-n/2,t+n/2,0,Math.PI*2)}}},jk=(function(r){E(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),Hh=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Ht).models[0]},e.type="polarAxis",e})(lt);Jt(Hh,oo);var Jk=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e})(Hh),Qk=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e})(Hh),Wh=(function(r){E(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})(Ze);Wh.prototype.dataToRadius=Ze.prototype.dataToCoord;Wh.prototype.radiusToData=Ze.prototype.coordToData;var tN=ut(),Uh=(function(r){E(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=Ys(s==null?"":s+"",a.getFont(),"center","top"),v=Math.max(c.height,7),h=v/u;isNaN(h)&&(h=1/0);var f=Math.max(0,Math.floor(h)),p=tN(t.model),d=p.lastAutoInterval,g=p.lastTickCount;return d!=null&&g!=null&&Math.abs(d-f)<=1&&Math.abs(g-o)<=1&&d>f?f=d:(p.lastTickCount=o,p.lastAutoInterval=f),f},e})(Ze);Uh.prototype.dataToAngle=Ze.prototype.dataToCoord;Uh.prototype.angleToData=Ze.prototype.coordToData;var _1=["radius","angle"],eN=(function(){function r(e){this.dimensions=_1,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new Wh,this._angleAxis=new Uh,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,o=1e-4;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(s,l){var u=s-this.cx,c=l-this.cy,v=u*u+c*c,h=this.r,f=this.r0;return h!==f&&v-o<=h*h&&v+o>=f*f}}},r.prototype.convertToPixel=function(e,t,a){var n=ny(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=ny(t);return n===this?this.pointToData(a):null},r})();function ny(r){var e=r.seriesModel,t=r.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function rN(r,e,t){var a=e.get("center"),n=t.getWidth(),i=t.getHeight();r.cx=H(a[0],n),r.cy=H(a[1],i);var o=r.getRadiusAxis(),s=Math.min(n,i)/2,l=e.get("radius");l==null?l=[0,"100%"]:B(l)||(l=[0,l]);var u=[H(l[0],s),H(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function aN(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(Is(l,"radius"),function(u){n.scale.unionExtentFromData(l,u)}),w(Is(l,"angle"),function(u){a.scale.unionExtentFromData(l,u)})}}),fn(a.scale,a.model),fn(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 nN(r){return r.mainType==="angleAxis"}function iy(r,e){var t;if(r.type=e.get("type"),r.scale=hl(e),r.onBand=e.get("boundaryGap")&&r.type==="category",r.inverse=e.get("inverse"),nN(e)){r.inverse=r.inverse!==e.get("clockwise");var a=e.get("startAngle"),n=(t=e.get("endAngle"))!==null&&t!==void 0?t:a+(r.inverse?-360:360);r.setExtent(a,n)}e.axis=r,r.model=e}var iN={dimensions:_1,create:function(r,e){var t=[];return r.eachComponent("polar",function(a,n){var i=new eN(n+"");i.update=aN;var o=i.getRadiusAxis(),s=i.getAngleAxis(),l=a.findAxisModel("radiusAxis"),u=a.findAxisModel("angleAxis");iy(o,l),iy(s,u),rN(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",Ht).models[0];a.coordinateSystem=n.coordinateSystem}}),t}},oN=["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 oy(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 sN=(function(r){E(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=j(c);var v=n.scale,h=v.type==="ordinal"?v.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=n.dataToCoord(h),c});oy(u),oy(s),w(oN,function(c){t.get([c,"show"])&&(!n.scale.isBlank()||c==="axisLine")&&lN[c](this.group,t,i,s,l,o,u)},this)}},e.type="angleAxis",e})(Ea),lN={axisLine:function(r,e,t,a,n,i){var o=e.getModel(["axisLine","lineStyle"]),s=t.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),c=Bo(t),v=c?0:1,h,f=Math.abs(u[1]-u[0])===360?"Circle":"Arc";i[v]===0?h=new Ia[f]({shape:{cx:t.cx,cy:t.cy,r:i[c],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:o.getLineStyle(),z2:1,silent:!0}):h=new Hs({shape:{cx:t.cx,cy:t.cy,r:i[c],r0:i[v]},style:o.getLineStyle(),z2:1,silent:!0}),h.style.fill=null,r.add(h)},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 ee({shape:Vo(t,[l,l+s],c.coord)})});r.add(Me(u,{style:Q(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 h=0;h<n[v].length;h++)c.push(new ee({shape:Vo(t,[u,u+l],n[v][h].coord)}));r.add(Me(c,{style:Q(s.getModel("lineStyle").getLineStyle(),Q(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,h){var f=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",_=Math.abs(g[1]-m)/d<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[p]){var x=s[p];J(x)&&x.textStyle&&(f=new mt(x.textStyle,l,l.ecModel))}var b=new vt({silent:fe.isLabelSilent(e),style:Dt(f,{x:g[0],y:g[1],fill:f.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:v.formattedLabel,align:S,verticalAlign:_})});if(r.add(b),c){var A=fe.makeAxisEventDataBase(e);A.targetType="axisLabel",A.value=v.rawLabel,q(b).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 h=u++%l.length;c[h]=c[h]||[],c[h].push(new ee({shape:Vo(t,i,a[v].coord)}))}for(var v=0;v<c.length;v++)r.add(Me(c[v],{style:Q({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 ee({shape:Vo(t,i,n[u][c].coord)}));r.add(Me(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,h=-a[0].coord*v,f=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 Ee({shape:{cx:t.cx,cy:t.cy,r0:f,r:p,startAngle:h,endAngle:-m*v,clockwise:d},silent:!0})),h=-m*v}for(var g=0;g<c.length;g++)r.add(Me(c[g],{style:Q({fill:l[g%l.length]},s.getAreaStyle()),silent:!0}))}}},uN=["axisLine","axisTickLabel","axisName"],cN=["splitLine","splitArea","minorSplitLine"],vN=(function(r){E(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 et;this.group.add(i);var o=t.axis,s=o.polar,l=s.getAngleAxis(),u=o.getTicksCoords(),c=o.getMinorTicksCoords(),v=l.getExtent()[0],h=o.getExtent(),f=fN(s,t,v),p=new fe(t,f);w(uN,p.add,p),i.add(p.getGroup()),Ki(n,i,t),w(cN,function(d){t.get([d,"show"])&&!o.scale.isBlank()&&hN[d](this.group,t,s,v,h,u,c)},this)}},e.type="radiusAxis",e})(Ea),hN={splitLine:function(r,e,t,a,n,i){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0,c=t.getAngleAxis(),v=Math.PI/180,h=c.getExtent(),f=Math.abs(h[1]-h[0])===360?"Circle":"Arc";l=l instanceof Array?l:[l];for(var p=[],d=0;d<i.length;d++){var g=u++%l.length;p[g]=p[g]||[],p[g].push(new Ia[f]({shape:{cx:t.cx,cy:t.cy,r:Math.max(i[d].coord,0),startAngle:-h[0]*v,endAngle:-h[1]*v,clockwise:c.inverse}}))}for(var d=0;d<p.length;d++)r.add(Me(p[d],{style:Q({stroke:l[d%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 Ca({shape:{cx:t.cx,cy:t.cy,r:o[c][v].coord}}));r.add(Me(u,{style:Q({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,h=1;h<i.length;h++){var f=u++%l.length;c[f]=c[f]||[],c[f].push(new Ee({shape:{cx:t.cx,cy:t.cy,r0:v,r:i[h].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),v=i[h].coord}for(var h=0;h<c.length;h++)r.add(Me(c[h],{style:Q({fill:l[h%l.length]},s.getAreaStyle()),silent:!0}))}}};function fN(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}}function x1(r){return r.get("stack")||"__ec_stack_"+r.seriesIndex}function b1(r,e){return e.dim+r.model.componentIndex}function pN(r,e,t){var a={},n=dN(_t(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=b1(s,l),c=x1(i),v=n[u][c],h=v.offset,f=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),_=o.mapDimension(l.dim),x=Gr(o,S),b=l.dim!=="radius"||!i.get("roundCap",!0),A=p.model,T=A.get("startValue"),D=p.dataToCoord(T||0),C=0,M=o.count();C<M;C++){var I=o.get(S,C),L=o.get(_,C),R=I>=0?"p":"n",P=D;x&&(a[c][L]||(a[c][L]={p:D,n:D}),P=a[c][L][R]);var k=void 0,O=void 0,N=void 0,V=void 0;if(p.dim==="radius"){var F=p.dataToCoord(I)-D,W=l.dataToCoord(L);Math.abs(F)<y&&(F=(F<0?-1:1)*y),k=P,O=P+F,N=W-h,V=N-f,x&&(a[c][L][R]=O)}else{var X=p.dataToCoord(I,b)-D,rt=l.dataToCoord(L);Math.abs(X)<m&&(X=(X<0?-1:1)*m),k=rt+h,O=k+f,N=P,V=P+X,x&&(a[c][L][R]=V)}o.setItemLayout(C,{cx:d,cy:g,r0:k,r:O,startAngle:-N*Math.PI/180,endAngle:-V*Math.PI/180,clockwise:N>=V})}}})}function dN(r){var e={};w(r,function(a,n){var i=a.getData(),o=a.coordinateSystem,s=o.getBaseAxis(),l=b1(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:{}},h=v.stacks;e[l]=v;var f=x1(a);h[f]||v.autoWidthCount++,h[f]=h[f]||{width:0,maxWidth:0};var p=H(a.get("barWidth"),c),d=H(a.get("barMaxWidth"),c),g=a.get("barGap"),y=a.get("barCategoryGap");p&&!h[f].width&&(p=Math.min(v.remainedWidth,p),h[f].width=p,v.remainedWidth-=p),d&&(h[f].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=H(a.categoryGap,o),l=H(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 h=0,f;w(i,function(d,g){d.width||(d.width=v),f=d,h+=d.width*(1+l)}),f&&(h-=f.width*l);var p=-h/2;w(i,function(d,g){t[n][g]=t[n][g]||{offset:p,width:d.width},p+=d.width*(1+l)})}),t}var gN={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},yN={splitNumber:5},mN=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e})(Rt);function SN(r){it(uo),Ea.registerAxisPointerClass("PolarAxisPointer",Xk),r.registerCoordinateSystem("polar",iN),r.registerComponentModel(jk),r.registerComponentView(mN),hn(r,"angle",Jk,gN),hn(r,"radius",Qk,yN),r.registerComponentView(sN),r.registerComponentView(vN),r.registerLayout(tt(pN,"bar"))}function nv(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),Qt(e.labelInside,r.get(["axisLabel","inside"]))&&(n.labelDirection=-n.labelDirection);var h=e.rotate;return h==null&&(h=r.get(["axisLabel","rotate"])),n.labelRotation=i==="top"?-h:h,n.z2=1,n}var _N=["axisLine","axisTickLabel","axisName"],xN=["splitArea","splitLine"],bN=(function(r){E(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 et;var l=nv(t),u=new fe(t,l);w(_N,u.add,u),o.add(this._axisGroup),o.add(u.getGroup()),w(xN,function(c){t.get([c,"show"])&&wN[c](this,this.group,this._axisGroup,t)},this),Ki(s,this._axisGroup,t),r.prototype.render.call(this,t,a,n,i)},e.prototype.remove=function(){U_(this)},e.type="singleAxis",e})(Ea),wN={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=[],h=0,f=n.getTicksCoords({tickModel:i}),p=[],d=[],g=0;g<f.length;++g){var y=n.toGlobalCoord(f[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 ee({shape:{x1:p[0],y1:p[1],x2:d[0],y2:d[1]},silent:!0});ln(m.shape,l);var S=h++%s.length;v[S]=v[S]||[],v[S].push(m)}for(var _=o.getLineStyle(["color"]),g=0;g<v.length;++g)e.add(Me(v[g],{style:Q({stroke:s[g%s.length]},_),silent:!0}))}},splitArea:function(r,e,t,a){W_(r,t,a,a)}},is=(function(r){E(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(is,oo.prototype);var AN=(function(r){E(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})(Ze),w1=["single"],TN=(function(){function r(e,t,a){this.type="single",this.dimension="single",this.dimensions=w1,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 AN(n,hl(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),fn(this._axis.scale,this._axis.model)}},this)},r.prototype.resize=function(e,t){this._rect=Zt({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=sy(t);return n===this?this.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=sy(t);return n===this?this.pointToData(a):null},r})();function sy(r){var e=r.seriesModel,t=r.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function DN(r,e){var t=[];return r.eachComponent("singleAxis",function(a,n){var i=new TN(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",Ht).models[0];a.coordinateSystem=n&&n.coordinateSystem}}),t}var CN={create:DN,dimensions:w1},ly=["x","y"],MN=["width","height"],IN=(function(r){E(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=zu(l,1-Vs(s)),c=l.dataToPoint(a)[0],v=i.get("type");if(v&&v!=="none"){var h=zh(i),f=LN[v](s,c,u);f.style=h,t.graphicKey=f.type,t.pointer=f}var p=nv(n);g1(a,t,p,n,i,o)},e.prototype.getHandleTransform=function(t,a,n){var i=nv(a,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var o=Gh(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=zu(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=zu(s,1-l),h=(v[1]+v[0])/2,f=[h,h];return f[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:f,tooltipOption:{verticalAlign:"middle"}}},e})(Bh),LN={line:function(r,e,t){var a=Fh([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:y1([e-a/2,t[0]],[a,n],Vs(r))}}};function Vs(r){return r.isHorizontal()?0:1}function zu(r,e){var t=r.getRect();return[t[ly[e]],t[ly[e]]+t[MN[e]]]}var PN=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e})(Rt);function RN(r){it(uo),Ea.registerAxisPointerClass("SingleAxisPointer",IN),r.registerComponentView(PN),r.registerComponentView(bN),r.registerComponentModel(is),hn(r,"single",is,is.defaultOption),r.registerCoordinateSystem("single",CN)}var EN=(function(r){E(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=Mn(t);r.prototype.init.apply(this,arguments),uy(t,i)},e.prototype.mergeOption=function(t){r.prototype.mergeOption.apply(this,arguments),uy(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 uy(r,e){var t=r.cellSize,a;B(t)?a=t:a=r.cellSize=[t,t],a.length===1&&(a[1]=a[0]);var n=G([0,1],function(i){return JA(e,i)&&(a[i]="auto"),a[i]!=null&&a[i]!=="auto"});Fr(r,e,{type:"box",ignoreSize:n})}var kN=(function(r){E(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 dt({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,h=0;v.time<=a.end.time;h++){p(v.formatedDate),h===0&&(v=s.getDateInfo(a.start.y+"-"+a.start.m));var f=v.date;f.setMonth(f.getMonth()+1),v=s.getDateInfo(f)}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 xe({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 Y(t)&&t?KA(t,a):K(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,h=n==="horizontal"?0:1,f={top:[c,u[h][1]],bottom:[c,u[1-h][1]],left:[u[1-h][0],v],right:[u[h][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 vt({z2:30,style:Dt(o,{text:y}),silent:o.get("silent")});m.attr(this._yearTextPositionControl(m,f[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||Y(s))&&(s&&(a=Sc(s)||a),s=a.get(["time","monthAbbr"])||[]);var h=u==="start"?0:1,f=n==="horizontal"?0:1;l=u==="start"?-l:l;for(var p=c==="center",d=o.get("silent"),g=0;g<v[h].length-1;g++){var y=v[h][g].slice(),m=this._firstDayOfMonth[g];if(p){var S=this._firstDayPoints[g];y[f]=(S[f]+v[0][g+1][f])/2}var _=o.get("formatter"),x=s[+m.m-1],b={yyyy:m.y,yy:(m.y+"").slice(2),MM:m.m,M:+m.m,nameMap:x},A=this._formatterLabel(_,b),T=new vt({z2:30,style:z(Dt(o,{text:A}),this._monthTextPositionControl(y,p,n,u,l)),silent:d});i.add(T)}}},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"),h=l.getFirstDayOfWeek();if(!c||Y(c)){c&&(a=Sc(c)||a);var f=a.get(["time","dayOfWeekShort"]);c=f||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=H(v,Math.min(d[1],d[0])),u==="start"&&(p=l.getNextNDay(n.start.time,-(7+n.fweek)).time,v=-v);for(var g=s.get("silent"),y=0;y<7;y++){var m=l.getNextNDay(p,y),S=l.dataToRect([m.time],!1).center,_=y;_=Math.abs((y+h)%7);var x=new vt({z2:30,style:z(Dt(s,{text:c[_]}),this._weekTextPositionControl(S,i,u,v,d)),silent:g});o.add(x)}}},e.type="calendar",e})(Rt),Gu=864e5,NN=(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=er(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=Zt(o,l);w([0,1],function(v){c(i,v)||(i[v]=u[n[v]]/s[v])});function c(v,h){return v[h]!=null&&v[h]!=="auto"}this._sw=i[0],this._sh=i[1]},r.prototype.dataToPoint=function(e,t){B(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+Gu))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=cy(t);return n===this?n.dataToPoint(a):null},r.prototype.convertFromPixel=function(e,t,a){var n=cy(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(B(e)&&e.length===1&&(e=e[0]),B(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/Gu)-Math.floor(t[0].time/Gu)+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 cy(r){var e=r.calendarModel,t=r.seriesModel,a=e?e.coordinateSystem:t?t.coordinateSystem:null;return a}function ON(r){r.registerComponentModel(EN),r.registerComponentView(kN),r.registerCoordinateSystem("calendar",NN)}function VN(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 vy(r,e){var t;return w(e,function(a){r[a]!=null&&r[a]!=="auto"&&(t=!0)}),t}function BN(r,e,t){var a=z({},t),n=r[e],i=t.$action||"merge";i==="merge"?n?(nt(n,a,!0),Fr(n,a,{ignoreSize:!0}),iS(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 A1=["transition","enterFrom","leaveTo"],zN=A1.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?A1:zN,n=0;n<a.length;n++){var i=a[n];r[i]==null&&e[i]!=null&&(r[i]=e[i])}}function GN(r,e){if(r&&(r.hv=e.hv=[vy(e,["left","right"]),vy(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 FN=(function(r){E(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 h=c.newOption;h&&(u.push(h),VN(c,h),BN(o,v,h),GN(o[v],h))},this),n.elements=_t(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),hy={path:null,compoundPath:null,group:et,image:Ne,text:vt},De=ut(),HN=(function(r){E(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=$()},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=Yt(l.id,null),c=u!=null?n.get(u):null,v=Yt(l.parentId,null),h=v!=null?n.get(v):i,f=l.type,p=l.style;f==="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&&n1(p,f,!!g,!!d)){var y=i1(p,f,!0);!g&&y.textConfig&&(g=l.textConfig=y.textConfig),!d&&y.textContent&&(d=y.textContent)}var m=WN(l),S=l.$action||"merge",_=S==="merge",x=S==="replace";if(_){var b=!c,A=c;b?A=fy(u,h,l.type,n):(A&&(De(A).isNew=!1),u1(A)),A&&(as(A,m,t,{isInit:b}),py(A,l,o,s))}else if(x){os(c,l,n,t);var T=fy(u,h,l.type,n);T&&(as(T,m,t,{isInit:!0}),py(T,l,o,s))}else S==="remove"&&(s1(c,l),os(c,l,n,t));var D=n.get(u);if(D&&d)if(_){var C=D.getTextContent();C?C.attr(d):D.setTextContent(new vt(d))}else x&&D.setTextContent(new vt(d));if(D){var M=l.clipPath;if(M){var I=M.type,L=void 0,b=!1;if(_){var R=D.getClipPath();b=!R||De(R).type!==I,L=b?iv(I):R}else x&&(b=!0,L=iv(I));D.setClipPath(L),as(L,M,t,{isInit:b}),Ns(L,M.keyframeAnimation,t)}var P=De(D);D.setTextConfig(g),P.option=l,UN(D,t,l),Ma({el:D,componentModel:t,itemName:D.name,itemTooltipOption:l.tooltip}),Ns(D,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],h=Yt(v.id,null),f=h!=null?o.get(h):null;if(!(!f||!f.isGroup)){var p=f.parent,d=p===i,g=De(f),y=De(p);g.width=H(g.option.width,d?s:y.width)||0,g.height=H(g.option.height,d?l:y.height)||0}}for(var c=n.length-1;c>=0;c--){var v=n[c],h=Yt(v.id,null),f=h!=null?o.get(h):null;if(f){var p=f.parent,y=De(p),m=p===i?{width:s,height:l}:{width:y.width,height:y.height},S={},_=il(f,v,m,null,{hv:v.hv,boundingMode:v.bounding},S);if(!De(f).isNew&&_){for(var x=v.transition,b={},A=0;A<u.length;A++){var T=u[A],D=S[T];x&&(ya(x)||ct(x,T)>=0)?b[T]=D:f[T]=D}ft(f,b,t,0)}else f.attr(S)}}},e.prototype._clear=function(){var t=this,a=this._elMap;a.each(function(n){os(n,De(n).option,a,t._lastGraphicModel)}),this._elMap=$()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e})(Rt);function iv(r){var e=Z(hy,r)?hy[r]:Iv(r),t=new e({});return De(t).type=r,t}function fy(r,e,t,a){var n=iv(t);return e.add(n),a.set(r,n),De(n).id=r,De(n).isNew=!0,n}function os(r,e,t,a){var n=r&&r.parent;n&&(r.type==="group"&&r.traverse(function(i){os(i,e,t,a)}),yl(r,e,a),t.removeKey(De(r).id))}function py(r,e,t,a){r.isGroup||w([["cursor",ma.prototype.cursor],["zlevel",a||0],["z",t||0],["z2",0]],function(n){var i=n[0];Z(e,i)?r[i]=pt(e[i],n[1]):r[i]==null&&(r[i]=n[1])}),w(Ut(e),function(n){if(n.indexOf("on")===0){var i=e[n];r[n]=K(i)?i:null}}),Z(e,"draggable")&&(r.draggable=e.draggable),e.name!=null&&(r.name=e.name),e.id!=null&&(r.id=e.id)}function WN(r){return r=z({},r),w(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(nS),function(e){delete r[e]}),r}function UN(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 YN(r){r.registerComponentModel(FN),r.registerComponentView(HN),r.registerPreprocessor(function(e){var t=e.graphic;B(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var dy=["x","y","radius","angle","single"],ZN=["cartesian2d","polar","singleAxis"];function $N(r){var e=r.get("coordinateSystem");return ct(ZN,e)>=0}function Er(r){return r+"Axis"}function XN(r,e){var t=$(),a=[],n=$();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(h,f){var p=t.get(h);p&&p[f]&&(v=!0)}),v}function u(c){c.eachTargetAxis(function(v,h){(t.get(v)||t.set(v,[]))[h]=!0})}return a}function T1(r){var e=r.ecModel,t={infoList:[],infoMap:$()};return r.eachTargetAxis(function(a,n){var i=e.getComponent(Er(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 Fu=(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})(),Gi=(function(r){E(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=gy(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},e.prototype.mergeOption=function(t){var a=gy(t);nt(this.option,t,!0),nt(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=$(),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(dy,function(n){var i=this.getReferringComponents(Er(n),_w);if(i.specified){a=!0;var o=new Fu;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 h=new Fu;if(h.add(v.componentIndex),t.set(c,h),i=!1,c==="x"||c==="y"){var f=v.getReferringComponents("grid",Ht).models[0];f&&w(u,function(p){v.componentIndex!==p.componentIndex&&f===p.getReferringComponents("grid",Ht).models[0]&&h.add(p.componentIndex)})}}}i&&w(dy,function(u){if(i){var c=n.findComponents({mainType:Er(u),filter:function(h){return h.get("type",!0)==="category"}});if(c[0]){var v=new Fu;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(Er(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(Er(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 gy(r){var e={};return w(["start","end","startValue","endValue","throttle"],function(t){r.hasOwnProperty(t)&&(e[t]=r[t])}),e}var KN=(function(r){E(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})(Gi),Yh=(function(r){E(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})(Rt),qN=(function(r){E(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})(Yh),qa=w,yy=Le,jN=(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($N(t)){var a=Er(this._dimName),n=t.getReferringComponents(a,Ht).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 j(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;qa(["start","end"],function(h,f){var p=e[h],d=e[h+"Value"];i[f]==="percent"?(p==null&&(p=o[f]),d=n.parse(yt(p,o,t))):(u=!0,d=d==null?t[f]:n.parse(d),p=yt(d,t,o)),l[f]=d==null||isNaN(d)?t[f]:d,s[f]=p==null||isNaN(p)?o[f]:p}),yy(l),yy(s);var c=this._minMaxSpan;u?v(l,s,t,o,!1):v(s,l,o,t,!0);function v(h,f,p,d,g){var y=g?"Span":"ValueSpan";ka(0,h,p,"all",c["min"+y],c["max"+y]);for(var m=0;m<2;m++)f[m]=yt(h[m],p,d,!0),g&&(f[m]=n.parse(f[m]))}return{valueWindow:l,percentWindow:s}},r.prototype.reset=function(e){if(e===this._dataZoomModel){var t=this.getTargetSeriesModels();this._dataExtent=JN(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;qa(n,function(l){var u=l.getData(),c=u.mapDimensionsAll(a);if(c.length){if(i==="weakFilter"){var v=u.getStore(),h=G(c,function(f){return u.getDimensionIndex(f)},u);u.filterSelf(function(f){for(var p,d,g,y=0;y<c.length;y++){var m=v.get(h[y],f),S=!isNaN(m),_=m<o[0],x=m>o[1];if(S&&!_&&!x)return!0;S&&(g=!0),_&&(p=!0),x&&(d=!0)}return g&&p&&d})}else qa(c,function(f){if(i==="empty")l.setData(u=u.map(f,function(d){return s(d)?d:NaN}));else{var p={};p[f]=o,u.selectRange(p)}});qa(c,function(f){u.setApproximateExtent(o,f)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,a=this._dataExtent;qa(["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=yt(a[0]+o,a,[0,100],!0):i!=null&&(o=yt(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=Um(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 JN(r,e,t){var a=[1/0,-1/0];qa(t,function(o){GM(a,o.getData(),e)});var n=r.getAxisModel(),i=P_(n.axis.scale,n,a).calculate();return[i.min,i.max]}var QN={getTargetSeries:function(r){function e(n){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(o,s){var l=r.getComponent(Er(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 jN(n,i,s,r),t.push(o.__dzAxisProxy))});var a=$();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]})}})}};function tO(r){r.registerAction("dataZoom",function(e,t){var a=XN(t,e);w(a,function(n){n.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var my=!1;function Zh(r){my||(my=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,QN),tO(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function eO(r){r.registerComponentModel(KN),r.registerComponentView(qN),Zh(r)}var Ce=(function(){function r(){}return r})(),D1={};function ja(r,e){D1[r]=e}function C1(r){return D1[r]}var rO=(function(r){E(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=C1(n);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(t)),nt(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);function aO(r,e,t){var a=e.getBoxLayoutParams(),n=e.get("padding"),i={width:t.getWidth(),height:t.getHeight()},o=Zt(a,i,n);da(e.get("orient"),r,e.get("itemGap"),o.width,o.height),il(r,a,i,n)}function M1(r,e){var t=Cn(e.get("padding")),a=e.getItemStyle(["color","opacity"]);return a.fill=e.get("backgroundColor"),r=new dt({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 nO=(function(r){E(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 dr(this._featureNames||[],v).add(h).update(h).remove(tt(h,null)).execute(),this._featureNames=v;function h(p,d){var g=v[p],y=v[d],m=u[g],S=new mt(m,t,t.ecModel),_;if(i&&i.newTitle!=null&&i.featureName===g&&(m.title=i.newTitle),g&&!y){if(iO(g))_={onclick:S.option.onclick,featureName:g};else{var x=C1(g);if(!x)return;_=new x}c[g]=_}else if(_=c[y],!_)return;_.uid=Dn("toolbox-feature"),_.model=S,_.ecModel=a,_.api=n;var b=_ instanceof Ce;if(!g&&y){b&&_.dispose&&_.dispose(a,n);return}if(!S.get("show")||b&&_.unusable){b&&_.remove&&_.remove(a,n);return}f(S,_,g),S.setIconStatus=function(A,T){var D=this.option,C=this.iconPaths;D.iconStatus=D.iconStatus||{},D.iconStatus[A]=T,C[A]&&(T==="emphasis"?fr:pr)(C[A])},_ instanceof Ce&&_.render&&_.render(S,a,n,i)}function f(p,d,g){var y=p.getModel("iconStyle"),m=p.getModel(["emphasis","iconStyle"]),S=d instanceof Ce&&d.getIcons?d.getIcons():p.get("icon"),_=p.get("title")||{},x,b;Y(S)?(x={},x[g]=S):x=S,Y(_)?(b={},b[g]=_):b=_;var A=p.iconPaths={};w(x,function(T,D){var C=qi(T,{},{x:-s/2,y:-s/2,width:s,height:s});C.setStyle(y.getItemStyle());var M=C.ensureState("emphasis");M.style=m.getItemStyle();var I=new vt({style:{text:b[D],align:m.get("textAlign"),borderRadius:m.get("textBorderRadius"),padding:m.get("textPadding"),fill:null,font:Lv({fontStyle:m.get("textFontStyle"),fontFamily:m.get("textFontFamily"),fontSize:m.get("textFontSize"),fontWeight:m.get("textFontWeight")},a)},ignore:!0});C.setTextContent(I),Ma({el:C,componentModel:t,itemName:D,formatterParamsExtra:{title:b[D]}}),C.__title=b[D],C.on("mouseover",function(){var L=m.getItemStyle(),R=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")}),C.setTextConfig({position:m.get("textPosition")||R}),I.ignore=!t.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){p.get(["iconStatus",D])!=="emphasis"&&n.leaveEmphasis(this),I.hide()}),(p.get(["iconStatus",D])==="emphasis"?fr:pr)(C),o.add(C),C.on("click",U(d.onclick,d,a,n,D)),A[D]=C})}aO(o,t,n),o.add(M1(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&&!K(S)&&d){var _=S.style||(S.style={}),x=Ys(d,vt.makeFont(_)),b=p.x+o.x,A=p.y+o.y+s,T=!1;A+x.height>n.getHeight()&&(y.position="top",T=!0);var D=T?-5-x.height:s+10;b+x.width/2>n.getWidth()?(y.position=["100%",D],_.align="right"):b-x.width/2<0&&(y.position=[0,D],_.align="left")}})},e.prototype.updateView=function(t,a,n,i){w(this._features,function(o){o instanceof Ce&&o.updateView&&o.updateView(o.model,a,n,i)})},e.prototype.remove=function(t,a){w(this._features,function(n){n instanceof Ce&&n.remove&&n.remove(t,a)}),this.group.removeAll()},e.prototype.dispose=function(t,a){w(this._features,function(n){n instanceof Ce&&n.dispose&&n.dispose(t,a)})},e.type="toolbox",e})(Rt);function iO(r){return r.indexOf("my")===0}var oO=(function(r){E(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=Nt.browser;if(typeof MouseEvent=="function"&&(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 h=l.split(","),f=h[0].indexOf("base64")>-1,p=o?decodeURIComponent(h[1]):h[1];f&&(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 _=S.contentWindow,x=_.document;x.open("image/svg+xml","replace"),x.write(p),x.close(),_.focus(),x.execCommand("SaveAs",!0,d),document.body.removeChild(S)}}else{var b=n.get("lang"),A='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(b&&b[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})(Ce),Sy="__ec_magicType_stack__",sO=[["line","bar"],["stack"]],lO=(function(r){E(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(_y[n]){var s={series:[]},l=function(v){var h=v.subType,f=v.id,p=_y[n](h,f,v,i);p&&(Q(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,Ht).models[0],_=S.componentIndex;s[m]=s[m]||[];for(var x=0;x<=_;x++)s[m][_]=s[m][_]||{};s[m][_].boundaryGap=n==="bar"}}};w(sO,function(v){ct(v,n)>=0&&w(v,function(h){i.setIconStatus(h,"normal")})}),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,c=n;n==="stack"&&(u=nt({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})(Ce),_y={line:function(r,e,t,a){if(r==="bar")return nt({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 nt({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")===Sy;if(r==="line"||r==="bar")return a.setIconStatus("stack",n?"normal":"emphasis"),nt({id:e,stack:n?"":Sy},a.get(["option","stack"])||{},!0)}};ar({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,e){e.mergeOption(r.newOption)});var ml=new Array(60).join("-"),gn=" ";function uO(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 cO(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(f){return f.name})),l=[n.model.getCategories()];w(t.series,function(f){var p=f.getRawData();l.push(f.getRawData().mapArray(p.mapDimension(o),function(d){return d}))});for(var u=[s.join(gn)],c=0;c<l[0].length;c++){for(var v=[],h=0;h<l.length;h++)v.push(l[h][c]);u.push(v.join(gn))}e.push(u.join(`
`))}),e.join(`
`+ml+`
`)}function vO(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+gn:"")+n.join(gn))}),a.join(`
`)}).join(`
`+ml+`
`)}function hO(r){var e=uO(r);return{value:_t([cO(e.seriesGroupByCategoryAxis),vO(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 fO(r){var e=r.slice(0,r.indexOf(`
`));if(e.indexOf(gn)>=0)return!0}var ov=new RegExp("["+gn+"]+","g");function pO(r){for(var e=r.split(/\n+/g),t=Bs(e.shift()).split(ov),a=[],n=G(t,function(l){return{name:l,data:[]}}),i=0;i<e.length;i++){var o=Bs(e[i]).split(ov);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 dO(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(ov),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 gO(r,e){var t=r.split(new RegExp(`
*`+ml+`
*`,"g")),a={series:[]};return w(t,function(n,i){if(fO(n)){var o=pO(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=dO(n);a.series.push(o)}}),a}var yO=(function(r){E(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"),h=i.get("contentToOption"),f=hO(t);if(K(v)){var p=v(a.getOption());Y(p)?u.innerHTML=p:lc(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=f.value,u.appendChild(c)}var g=f.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"),_=document.createElement("div");m+=";background-color:"+i.get("buttonColor"),m+=";color:"+i.get("buttonTextColor");var x=this;function b(){n.removeChild(o),x._dom=null}vf(S,"click",b),vf(_,"click",function(){if(h==null&&v!=null||h!=null&&v==null){b();return}var A;try{K(h)?A=h(u,a.getOption()):A=gO(c.value,g)}catch(T){throw b(),new Error("Data view format error "+T)}A&&a.dispatchAction({type:"changeDataView",newOption:A}),b()}),S.innerHTML=l[1],_.innerHTML=l[2],_.style.cssText=S.style.cssText=m,!i.get("readOnly")&&y.appendChild(_),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})(Ce);function mO(r,e){return G(r,function(t,a){var n=e&&e[a];if(J(n)&&!B(n)){var i=J(t)&&!B(t);i||(t={value:t});var o=n.name!=null&&t.name==null;return t=Q(t,n),o&&delete t.name,t}else return t})}ar({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(z({type:"scatter"},a));else{var i=n.get("data");t.push({name:a.name,data:mO(a.data,i)})}}),e.mergeOption(Q({series:t},r.newOption))});var I1=w,L1=ut();function SO(r,e){var t=$h(r);I1(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 _O(r){var e=$h(r),t=e[e.length-1];e.length>1&&e.pop();var a={};return I1(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 xO(r){L1(r).snapshots=null}function bO(r){return $h(r).length}function $h(r){var e=L1(r);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var wO=(function(r){E(e,r);function e(){return r!==null&&r.apply(this,arguments)||this}return e.prototype.onclick=function(t,a){xO(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})(Ce);ar({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,e){e.resetOption("recreate")});var AO=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],Xh=(function(){function r(e,t,a){var n=this;this._targetInfoList=[];var i=xy(t,e);w(TO,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=Hu[a.brushType](0,i,n);a.__rangeOffset={offset:Ty[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=Hu[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=Hu[a.brushType](0,n.coordSys,a.coordRange),o=a.__rangeOffset;a.range=o?Ty[a.brushType](i.values,o.offset,DO(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:Bx(n),isTargetByCursor:Gx(n,e,a.coordSysModel),getLinearBrushOtherExtent:zx(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=xy(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<by.length;l++)if(by[l](n,o))return o}return!0},r})();function sv(r){return r[0]>r[1]&&r.reverse(),r}function xy(r,e){return vi(r,e,{includeMainTypes:AO})}var TO={grid:function(r,e){var t=r.xAxisModels,a=r.yAxisModels,n=r.gridModels,i=$(),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,h){(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:wy.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:wy.geo})})}},by=[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}],wy={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,e=r.getBoundingRect().clone();return e.applyTransform(pa(r)),e}},Hu={lineX:tt(Ay,0),lineY:tt(Ay,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=[sv([n[0],i[0]]),sv([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 Ay(r,e,t,a){var n=t.getAxis(["x","y"][r]),i=sv(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 Ty={lineX:tt(Dy,0),lineY:tt(Dy,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 Dy(r,e,t,a){return[e[0]-a[r]*t[0],e[1]-a[r]*t[1]]}function DO(r,e){var t=Cy(r),a=Cy(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 Cy(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var lv=w,CO=dw("toolbox-dataZoom_"),MO=(function(r){E(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 xh(n.getZr()),this._brushController.on("brush",U(this._onBrush,this)).mount()),PO(t,a,this,i,n),LO(t,a)},e.prototype.onclick=function(t,a,n){IO[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 Xh(Kh(this.model),i,{include:["grid"]});o.matchOutputRanges(a,i,function(u,c,v){if(v.type==="cartesian2d"){var h=u.brushType;h==="rect"?(s("x",v,c[0]),s("y",v,c[1])):s({lineX:"x",lineY:"y"}[h],v,c)}}),SO(i,n),this._dispatchZoomAction(n);function s(u,c,v){var h=c.getAxis(u),f=h.model,p=l(u,f,i),d=p.findRepresentativeAxisProxy(f).getMinMaxSpan();(d.minValueSpan!=null||d.maxValueSpan!=null)&&(v=ka(0,v.slice(),h.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 h;return v.eachComponent({mainType:"dataZoom",subType:"select"},function(f){var p=f.getAxisModel(u,c.componentIndex);p&&(h=f)}),h}},e.prototype._dispatchZoomAction=function(t){var a=[];lv(t,function(n,i){a.push(j(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})(Ce),IO={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(_O(this.ecModel))}};function Kh(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 LO(r,e){r.setIconStatus("back",bO(e)>1?"emphasis":"normal")}function PO(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 Xh(Kh(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)}XD("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=Kh(a),o=vi(r,i);lv(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),lv(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,c){var v=l.componentIndex,h={type:"select",$fromToolbox:!0,filterMode:a.get("filterMode",!0)||"filter",id:CO+u+v};h[c]=v,n.push(h)}return n});function RO(r){r.registerComponentModel(rO),r.registerComponentView(nO),ja("saveAsImage",oO),ja("magicType",lO),ja("dataView",yO),ja("dataZoom",MO),ja("restore",wO),it(eO)}var EO=(function(r){E(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);function P1(r){var e=r.get("confine");return e!=null?!!e:r.get("renderMode")==="richText"}function R1(r){if(Nt.domSupported){for(var e=document.documentElement.style,t=0,a=r.length;t<a;t++)if(r[t]in e)return r[t]}}var E1=R1(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),kO=R1(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function k1(r,e){if(!r)return e;e=rS(e,!0);var t=r.indexOf(e);return r=t===-1?e:"-"+r.slice(0,t)+"-"+e,r.toLowerCase()}function NO(r,e){var t=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return t?t[e]:null}var OO=k1(kO,"transition"),qh=k1(E1,"transform"),VO="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(Nt.transform3dSupported?"will-change:transform;":"");function BO(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function zO(r,e,t){if(!Y(t)||t==="inside")return"";var a=r.get("backgroundColor"),n=r.get("borderWidth");e=Aa(e);var i=BO(t),o=Math.max(Math.round(n)*1.5,6),s="",l=qh+":",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,h=v*Math.abs(Math.cos(c))+v*Math.abs(Math.sin(c)),f=Math.round(((h-Math.SQRT2*n)/2+Math.SQRT2*n-(h-v)/2)*100)/100;s+=";"+i+":-"+f+"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 GO(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+=Nt.transformSupported?","+qh+a:",left"+a+",top"+a),OO+":"+n}function My(r,e,t){var a=r.toFixed(0)+"px",n=e.toFixed(0)+"px";if(!Nt.transformSupported)return t?"top:"+n+";left:"+a+";":[["top",n],["left",a]];var i=Nt.transform3dSupported,o="translate"+(i?"3d":"")+"("+a+","+n+(i?",0":"")+")";return t?"top:0;left:0;"+qh+":"+o+";":[["top",0],["left",0],[E1,o]]}function FO(r){var e=[],t=r.get("fontSize"),a=r.getTextColor();a&&e.push("color:"+a),e.push("font:"+r.getFont());var n=pt(r.get("lineHeight"),Math.round(t*3/2));t&&e.push("line-height:"+n+"px");var i=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,l=r.get("textShadowOffsetY")||0;return i&&o&&e.push("text-shadow:"+s+"px "+l+"px "+o+"px "+i),w(["decoration","align"],function(u){var c=r.get(u);c&&e.push("text-"+u+":"+c)}),e.join(";")}function HO(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=dS(r,"html"),h=l+"px "+u+"px "+o+"px "+s;return a.push("box-shadow:"+h),e&&n&&a.push(GO(n,t)),i&&a.push("background-color:"+i),w(["width","color","radius"],function(f){var p="border-"+f,d=rS(p),g=r.get(d);g!=null&&a.push(p+":"+g+(f==="color"?"":"px"))}),a.push(FO(c)),v!=null&&a.push("padding:"+Cn(v).join("px ")+"px"),a.join(";")+";"}function Iy(r,e,t,a,n){var i=e&&e.painter;if(t){var o=i&&i.getViewportRoot();o&&Ob(r,o,t,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 WO=(function(){function r(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,Nt.wxa)return null;var a=document.createElement("div");a.domBelongToZr=!0,this.el=a;var n=this._zr=e.getZr(),i=t.appendTo,o=i&&(Y(i)?document.querySelector(i):lc(i)?i:K(i)&&i(e.getDom()));Iy(this._styleCoord,n,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(a),this._api=e,this._container=o;var s=this;a.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},a.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=n.handler,c=n.painter.getViewportRoot();Nb(c,l,!0),u.dispatch("mousemove",l)}},a.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),a=NO(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=VO+HO(e,!this._firstShow,this._longHide)+My(i[0],i[1],!0)+("border-color:"+Aa(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(Y(i)&&a.get("trigger")==="item"&&!P1(a)&&(s=zO(a,n,i)),Y(e))o.innerHTML=e+s;else if(e){o.innerHTML="",B(e)||(e=[e]);for(var l=0;l<e.length;l++)lc(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?[e.offsetWidth,e.offsetHeight]:[0,0]},r.prototype.moveTo=function(e,t){if(this.el){var a=this._styleCoord;if(Iy(a,this._zr,this._container,e,t),a[0]!=null&&a[1]!=null){var n=this.el.style,i=My(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",Nt.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(U(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this.el.parentNode;e&&e.removeChild(this.el),this.el=this._container=null},r})(),UO=(function(){function r(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),Py(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)&&gt(""),this.el&&this._zr.remove(this.el);var s=a.getModel("textStyle");this.el=new vt({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:n,textShadowColor:s.get("textShadowColor"),fill:a.get(["textStyle","color"]),padding:dS(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=Ly(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;Py(n,this._zr,e,t),e=n[0],t=n[1];var i=a.style,o=Ir(i.borderWidth||0),s=Ly(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(U(this.hide,this),e)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r})();function Ir(r){return Math.max(0,r)}function Ly(r){var e=Ir(r.shadowBlur||0),t=Ir(r.shadowOffsetX||0),a=Ir(r.shadowOffsetY||0);return{left:Ir(e-t),right:Ir(e+t),top:Ir(e-a),bottom:Ir(e+a)}}function Py(r,e,t,a){r[0]=t,r[1]=a,r[2]=r[0]/e.getWidth(),r[3]=r[1]/e.getHeight()}var YO=new dt({shape:{x:-1,y:-1,width:2,height:2}}),ZO=(function(r){E(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(!(Nt.node||!a.getDom())){var n=t.getComponent("tooltip"),i=this._renderMode=bw(n.get("renderMode"));this._tooltipContent=i==="richText"?new UO(a):new WO(a,{appendTo:n.get("appendToBody",!0)?"body":n.get("appendTo",!0)})}},e.prototype.render=function(t,a,n){if(!(Nt.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")?Pn(this,"_updatePosition",50,"fixRate"):Li(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,a=t.get("triggerOn");m1("itemTooltip",this._api,U(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||Nt.node||!n.getDom())){var o=Ry(i,n);this._ticket="";var s=i.dataByCoordSys,l=qO(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=YO;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=S1(i,a),h=v.point[0],f=v.point[1];h!=null&&f!=null&&this._tryShow({offsetX:h,offsetY:f,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(Ry(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=jn([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){var s=q(n);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,u;va(n,function(c){if(q(c).dataIndex!=null)return l=c,!0;if(q(c).tooltipConfig!=null)return u=c,!0},!0),l?this._showSeriesItemTooltip(t,l,a):u?this._showComponentItemTooltip(t,u,a):this._hide(a)}else this._lastDataByCoordSys=null,this._hide(a)}},e.prototype._showOrMove=function(t,a){var n=t.get("showDelay");a=U(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=jn([a.tooltipOption],i),l=this._renderMode,u=[],c=jt("section",{blocks:[],noHeader:!0}),v=[],h=new Ol;w(t,function(m){w(m.dataByAxis,function(S){var _=n.getComponent(S.axisDim+"Axis",S.axisIndex),x=S.value;if(!(!_||x==null)){var b=d1(x,_.axis,n,S.seriesDataIndices,S.valueLabelOpt),A=jt("section",{header:b,noHeader:!Ui(b),sortBlocks:!0,blocks:[]});c.blocks.push(A),w(S.seriesDataIndices,function(T){var D=n.getSeriesByIndex(T.seriesIndex),C=T.dataIndexInside,M=D.getDataParams(C);if(!(M.dataIndex<0)){M.axisDim=S.axisDim,M.axisIndex=S.axisIndex,M.axisType=S.axisType,M.axisId=S.axisId,M.axisValue=nh(_.axis,{value:x}),M.axisValueLabel=b,M.marker=h.makeTooltipMarker("item",Aa(M.color),l);var I=Kf(D.formatTooltip(C,!0,null)),L=I.frag;if(L){var R=jn([D],i).get("valueFormatter");A.blocks.push(R?z({valueFormatter:R},L):L)}I.text&&v.push(I.text),u.push(M)}})}})}),c.blocks.reverse(),v.reverse();var f=a.position,p=s.get("order"),d=Qf(c,h,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,f,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],f,null,h)})},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,h=u.getData(v),f=this._renderMode,p=t.positionDefault,d=jn([h.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 Ol;y.marker=m.makeTooltipMarker("item",Aa(y.color),f);var S=Kf(u.formatTooltip(c,!1,v)),_=d.get("order"),x=d.get("valueFormatter"),b=S.frag,A=b?Qf(x?z({valueFormatter:x},b):b,m,f,_,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:h.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,a,n){var i=this._renderMode==="html",o=q(a),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(Y(l)){var c=l;l={content:c,formatter:c},u=!0}u&&i&&l.content&&(l=j(l),l.content=ye(l.content));var v=[l],h=this._ecModel.getComponent(o.componentMainType,o.componentIndex);h&&v.push(h),v.push({formatter:l.content});var f=t.positionDefault,p=jn(v,this._tooltipModel,f?{position:f}:null),d=p.get("content"),g=Math.random()+"",y=new Ol;this._showOrMove(p,function(){var m=j(p.get("formatterParams")||{});this._showTooltipContent(p,d,m,g,t.offsetX,t.offsetY,t.position,a,y)}),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 h=t.get("formatter");l=l||t.get("position");var f=a,p=this._getNearestPoint([o,s],n,t.get("trigger"),t.get("borderColor")),d=p.color;if(h)if(Y(h)){var g=t.ecModel.get("useUTC"),y=B(n)?n[0]:n,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;f=h,m&&(f=tl(y.axisValue,f,g)),f=aS(f,n,!0)}else if(K(h)){var S=U(function(_,x){_===this._ticket&&(v.setContent(x,c,t,d,l),this._updatePosition(t,l,o,s,v,n,u))},this);this._ticket=i,f=h(n,i,S)}else f=h;v.setContent(f,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"||B(a))return{color:i||(this._renderMode==="html"?"#fff":"none")};if(!B(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(),h=t.get("align"),f=t.get("verticalAlign"),p=l&&l.getBoundingRect().clone();if(l&&p.applyTransform(l.transform),K(a)&&(a=a([n,i],s,o.el,p,{viewSize:[u,c],contentSize:v.slice()})),B(a))n=H(a[0],u),i=H(a[1],c);else if(J(a)){var d=a;d.width=v[0],d.height=v[1];var g=Zt(d,{width:u,height:c});n=g.x,i=g.y,h=null,f=null}else if(Y(a)&&l){var y=KO(a,p,v,t.get("borderWidth"));n=y[0],i=y[1]}else{var y=$O(n,i,o,u,c,h?null:20,f?null:20);n=y[0],i=y[1]}if(h&&(n-=Ey(h)?v[0]/2:h==="right"?v[0]:0),f&&(i-=Ey(f)?v[1]/2:f==="bottom"?v[1]:0),P1(t)){var y=XO(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(h,f){var p=v[f]||{},d=h.seriesDataIndices||[],g=p.seriesDataIndices||[];o=o&&h.value===p.value&&h.axisType===p.axisType&&h.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(h.seriesDataIndices,function(y){var m=y.seriesIndex,S=a[m],_=i[m];S&&_&&_.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){Nt.node||!a.getDom()||(Li(this,"_updatePosition"),this._tooltipContent.dispose(),av("itemTooltip",a))},e.type="tooltip",e})(Rt);function jn(r,e,t){var a=e.ecModel,n;t?(n=new mt(t,a,a),n=new mt(e.option,n,a)):n=e;for(var i=r.length-1;i>=0;i--){var o=r[i];o&&(o instanceof mt&&(o=o.get("tooltip",!0)),Y(o)&&(o={formatter:o}),o&&(n=new mt(o,n,a)))}return n}function Ry(r,e){return r.dispatchAction||U(e.dispatchAction,e)}function $O(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 XO(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 KO(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 Ey(r){return r==="center"||r==="middle"}function qO(r,e,t){var a=bv(r).queryOptionMap,n=a.keys()[0];if(!(!n||n==="series")){var i=$i(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}}}}function jO(r){it(uo),r.registerComponentModel(EO),r.registerComponentView(ZO),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},pe),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},pe)}var JO=["rect","polygon","keep","clear"];function QO(r,e){var t=xt(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;B(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),tV(s),e&&!s.length&&s.push.apply(s,JO)}}function tV(r){var e={};w(r,function(t){e[t]=1}),r.length=0,w(e,function(t,a){r.push(a)})}var ky=w;function Ny(r){if(r){for(var e in r)if(r.hasOwnProperty(e))return!0}}function uv(r,e,t){var a={};return ky(e,function(i){var o=a[i]=n();ky(r[i],function(s,l){if(Kt.isValidType(l)){var u={type:l,visual:s};t&&t(u,i),o[l]=new Kt(u),l==="opacity"&&(u=j(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new Kt(u))}})}),a;function n(){var i=function(){};i.prototype.__hidden=i.prototype;var o=new i;return o}}function N1(r,e,t){var a;w(t,function(n){e.hasOwnProperty(n)&&Ny(e[n])&&(a=!0)}),a&&w(t,function(n){e.hasOwnProperty(n)&&Ny(e[n])?r[n]=j(e[n]):delete r[n]})}function eV(r,e,t,a,n,i){var o={};w(r,function(v){var h=Kt.prepareVisualTypes(e[v]);o[v]=h});var s;function l(v){return Kv(t,s,v)}function u(v,h){o_(t,s,v,h)}t.each(c);function c(v,h){s=v;var f=t.getRawDataItem(s);if(!(f&&f.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 rV(r,e,t,a){var n={};return w(r,function(i){var o=Kt.prepareVisualTypes(e[i]);n[i]=o}),{progress:function(o,s){var l;a!=null&&(l=s.getDimensionIndex(a));function u(x){return Kv(s,v,x)}function c(x,b){o_(s,v,x,b)}for(var v,h=s.getStore();(v=o.next())!=null;){var f=s.getRawDataItem(v);if(!(f&&f.visualMap===!1))for(var p=a!=null?h.get(l,v):v,d=t(p),g=e[d],y=n[d],m=0,S=y.length;m<S;m++){var _=y[m];g[_]&&g[_].applyVisual(p,u,c)}}}}}function aV(r){var e=r.brushType,t={point:function(a){return Oy[e].point(a,t,r)},rect:function(a){return Oy[e].rect(a,t,r)}};return t}var Oy={lineX:Vy(0),lineY:Vy(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])&&na(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(na(a,n,i)||na(a,n+o,i)||na(a,n,i+s)||na(a,n+o,i+s)||wt.create(r).contain(l[0],l[1])||ri(n,i,n+o,i,a)||ri(n,i,n,i+s,a)||ri(n+o,i,n+o,i+s,a)||ri(n,i+s,n+o,i+s,a))return!0}}};function Vy(r){var e=["x","y"],t=["width","height"];return{point:function(a,n,i){if(a){var o=i.range,s=a[r];return Jn(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(),Jn(s[0],o)||Jn(s[1],o)||Jn(o[0],s)||Jn(o[1],s)}}}}function Jn(r,e){return e[0]<=r&&r<=e[1]}var By=["inBrush","outOfBrush"],Wu="__ecBrushSelect",cv="__ecInBrushSelectEvent";function O1(r){r.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new Xh(e.option,r);t.setInputRanges(e.areas,r)})}function nV(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})}),O1(r),r.eachComponent({mainType:"brush"},function(o,s){var l={brushId:o.id,brushIndex:s,brushName:o.name,areas:j(o.areas),selected:[]};a.push(l);var u=o.option,c=u.brushLink,v=[],h=[],f=[],p=!1;s||(n=u.throttleType,i=u.throttleDelay);var d=G(o.areas,function(x){var b=lV[x.brushType],A=Q({boundingRect:b?b(x):void 0},x);return A.selectors=aV(A),A}),g=uv(o.option,By,function(x){x.mappingMethod="fixed"});B(c)&&w(c,function(x){v[x]=1});function y(x){return c==="all"||!!v[x]}function m(x){return!!x.length}r.eachSeries(function(x,b){var A=f[b]=[];x.subType==="parallel"?S(x,b):_(x,b,A)});function S(x,b){var A=x.coordinateSystem;p=p||A.hasAxisBrushed(),y(b)&&A.eachActiveState(x.getData(),function(T,D){T==="active"&&(h[D]=1)})}function _(x,b,A){if(!(!x.brushSelector||sV(o,b))&&(w(d,function(D){o.brushTargetManager.controlSeries(D,x,r)&&A.push(D),p=p||m(A)}),y(b)&&m(A))){var T=x.getData();T.each(function(D){zy(x,A,T,D)&&(h[D]=1)})}}r.eachSeries(function(x,b){var A={seriesId:x.id,seriesIndex:b,seriesName:x.name,dataIndex:[]};l.selected.push(A);var T=f[b],D=x.getData(),C=y(b)?function(M){return h[M]?(A.dataIndex.push(D.getRawIndex(M)),"inBrush"):"outOfBrush"}:function(M){return zy(x,T,D,M)?(A.dataIndex.push(D.getRawIndex(M)),"inBrush"):"outOfBrush"};(y(b)?p:m(T))&&eV(By,g,D,C)})}),iV(e,n,i,a,t)}function iV(r,e,t,a,n){if(n){var i=r.getZr();if(!i[cv]){i[Wu]||(i[Wu]=oV);var o=Pn(i,Wu,t,e);o(r,a)}}}function oV(r,e){if(!r.isDisposed()){var t=r.getZr();t[cv]=!0,r.dispatchAction({type:"brushSelect",batch:e}),t[cv]=!1}}function zy(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 sV(r,e){var t=r.option.seriesIndex;return t!=null&&t!=="all"&&(B(t)?ct(t,e)<0:e!==t)}var lV={rect:function(r){return Gy(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&&Gy(e)}};function Gy(r){return new wt(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var uV=(function(r){E(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 xh(a.getZr())).on("brush",U(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){O1(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:j(n),$from:a}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:a,areas:j(n),$from:a})},e.type="brush",e})(Rt),cV="#ddd",vV=(function(r){E(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&&N1(n,t,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:cV},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=G(t,function(a){return Fy(this.option,a)},this))},e.prototype.setBrushOption=function(t){this.brushOption=Fy(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 Fy(r,e){return nt({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new mt(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},e,!0)}var hV=["rect","polygon","lineX","lineY","keep","clear"],fV=(function(r){E(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:hV.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})(Ce);function pV(r){r.registerComponentView(uV),r.registerComponentModel(vV),r.registerPreprocessor(QO),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,nV),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"},pe),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},pe),ja("brush",fV)}var dV=(function(r){E(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),gV=(function(r){E(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=pt(t.get("textBaseline"),t.get("textVerticalAlign")),c=new vt({style:Dt(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),v=c.getBoundingRect(),h=t.get("subtext"),f=new vt({style:Dt(s,{text:h,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,f.silent=!d&&!g,p&&c.on("click",function(){_s(p,"_"+t.get("target"))}),d&&f.on("click",function(){_s(d,"_"+t.get("subtarget"))}),q(c).eventData=q(f).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(c),h&&i.add(f);var y=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=y.width,m.height=y.height;var S=Zt(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 _={align:l,verticalAlign:u};c.setStyle(_),f.setStyle(_),y=i.getBoundingRect();var x=S.margin,b=t.getItemStyle(["color","opacity"]);b.fill=t.get("backgroundColor");var A=new dt({shape:{x:y.x-x[3],y:y.y-x[0],width:y.width+x[1]+x[3],height:y.height+x[0]+x[2],r:t.get("borderRadius")},style:b,subPixelOptimize:!0,silent:!0});i.add(A)}},e.type="title",e})(Rt);function yV(r){r.registerComponentModel(dV),r.registerComponentView(gV)}var Hy=(function(r){E(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=Yt(xn(u),""),h;J(u)?(h=j(u),h.value=c):h=c,o.push(h),i.push(v)})):o=a;var s={category:"ordinal",time:"time",value:"number"}[n]||"number",l=this._data=new he([{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),V1=(function(r){E(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=Yr(Hy.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})(Hy);Jt(V1,ol.prototype);var mV=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e})(Rt),SV=(function(r){E(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})(Ze),Uu=Math.PI,Wy=ut(),_V=(function(r){E(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 jt("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=bV(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?"+":"-":Y(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:Uu/2},v=i==="vertical"?o.height:o.width,h=t.getModel("controlStyle"),f=h.get("show",!0),p=f?h.get("itemSize"):0,d=f?h.get("itemGap"):0,g=p+d,y=t.get(["label","rotate"])||0;y=y*Uu/180;var m,S,_,x=h.get("position",!0),b=f&&h.get("showPlayBtn",!0),A=f&&h.get("showPrevBtn",!0),T=f&&h.get("showNextBtn",!0),D=0,C=v;x==="left"||x==="bottom"?(b&&(m=[0,0],D+=g),A&&(S=[D,0],D+=g),T&&(_=[C-p,0],C-=g)):(b&&(m=[C-p,0],C-=g),A&&(S=[0,0],D+=g),T&&(_=[C-p,0],C-=g));var M=[D,C];return t.get("inverse")&&M.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:_,axisExtent:M,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=_n(),l=o.x,u=o.y+o.height;Sa(s,s,[-l,-u]),Yi(s,s,-Uu/2),Sa(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=m(o),v=m(n.getBoundingRect()),h=m(i.getBoundingRect()),f=[n.x,n.y],p=[i.x,i.y];p[0]=f[0]=c[0][0];var d=t.labelPosOpt;if(d==null||Y(d)){var g=d==="+"?0:1;S(f,v,c,1,g),S(p,h,c,1,1-g)}else{var g=d>=0?0:1;S(f,v,c,1,g),p[1]=f[1]+d}n.setPosition(f),i.setPosition(p),n.rotation=i.rotation=t.rotation,y(n),y(i);function y(_){_.originX=c[0][0]-_.x,_.originY=c[1][0]-_.y}function m(_){return[[_.x,_.x+_.width],[_.y,_.y+_.height]]}function S(_,x,b,A,T){_[A]+=b[A][T]-x[A][T]}},e.prototype._createAxis=function(t,a){var n=a.getData(),i=a.get("axisType"),o=xV(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 SV("value",o,t.axisExtent,i);return l.model=a,l},e.prototype._createGroup=function(t){var a=this[t]=new et;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 ee({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:z({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});a.add(s);var l=this._progressLine=new ee({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:Q({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),h=v.getModel("itemStyle"),f=v.getModel(["emphasis","itemStyle"]),p=v.getModel(["progress","itemStyle"]),d={x:c,y:0,onclick:U(o._changeTimeline,o,u.value)},g=Uy(v,h,a,d);g.ensureState("emphasis").style=f.getItemStyle(),g.ensureState("progress").style=p.getItemStyle(),fa(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,h=l.getItemModel(v),f=h.getModel("label"),p=h.getModel(["emphasis","label"]),d=h.getModel(["progress","label"]),g=n.dataToCoord(c.tickValue),y=new vt({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:U(o._changeTimeline,o,v),silent:!1,style:Dt(f,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=Dt(p),y.ensureState("progress").style=Dt(d),a.add(y),fa(y),Wy(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);h(t.nextBtnPosition,"next",U(this._changeTimeline,this,v?"-":"+")),h(t.prevBtnPosition,"prev",U(this._changeTimeline,this,v?"+":"-")),h(t.playPosition,c?"stop":"play",U(this._handlePlayClick,this,!c),!0);function h(f,p,d,g){if(f){var y=sn(pt(i.get(["controlStyle",p+"BtnSize"]),o),o),m=[0,-y/2,y,y],S=wV(i,p+"Icon",m,{x:f[0],y:f[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:d});S.ensureState("emphasis").style=u,a.add(S),fa(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=U(u._handlePointerDrag,u),v.ondragend=U(u._handlePointerDragend,u),Yy(v,u._progressLine,s,n,i,!0)},onUpdate:function(v){Yy(v,u._progressLine,s,n,i)}};this._currentPointer=Uy(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=Le(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 We(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",Wy(n[i]).dataIndex<=t)},e.type="timeline.slider",e})(mV);function xV(r,e){if(e=e||r.get("type"),e)switch(e){case"category":return new vl({ordinalMeta:r.getCategories(),extent:[1/0,-1/0]});case"time":return new rh({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new gr}}function bV(r,e){return Zt(r.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},r.get("padding"))}function wV(r,e,t,a){var n=a.style,i=qi(r.get(["controlStyle",e]),a||{},new wt(t[0],t[1],t[2],t[3]));return n&&i.setStyle(n),i}function Uy(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=Wt(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=nt({rectHover:!0,z2:100},a,!0);var u=In(r.get("symbolSize"));a.scaleX=u[0]/2,a.scaleY=u[1]/2;var c=La(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 Yy(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)}}}function AV(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)}),Q({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 TV(r){var e=r&&r.timeline;B(e)||(e=e?[e]:[]),w(e,function(t){t&&DV(t)})}function DV(r){var e=r.type,t={number:"value",time:"time"};if(t[e]&&(r.axisType=t[e],delete r.type),Zy(r),oa(r,"controlPosition")){var a=r.controlStyle||(r.controlStyle={});oa(a,"position")||(a.position=r.controlPosition),a.position==="none"&&!oa(a,"show")&&(a.show=!1,delete a.position),delete r.controlPosition}w(r.data||[],function(n){J(n)&&!B(n)&&(!oa(n,"value")&&oa(n,"name")&&(n.value=n.name),Zy(n))})}function Zy(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]&&!oa(n,s)&&(n[s]=o)}),t.label&&!oa(a,"emphasis")&&(a.emphasis=t.label,delete t.label)}function oa(r,e){return r.hasOwnProperty(e)}function CV(r){r.registerComponentModel(V1),r.registerComponentView(_V),r.registerSubTypeDefaulter("timeline",function(){return"slider"}),AV(r),r.registerPreprocessor(TV)}function jh(r,e){if(!r)return!1;for(var t=B(r)?r:[r],a=0;a<t.length;a++)if(t[a]&&t[a][e])return!0;return!1}function Go(r){xa(r,"label",["show"])}var Fo=ut(),mr=(function(r){E(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(Nt.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),z(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 jt("section",{header:this.name,blocks:[jt("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.prototype.getDataParams=function(t,a){var n=ol.prototype.getDataParams.call(this,t,a),i=this.__hostSeries;return i&&(n.seriesId=i.id,n.seriesName=i.name,n.seriesType=i.subType),n},e.getMarkerModelFromSeries=function(t,a){return Fo(t)[a]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e})(lt);Jt(mr,ol.prototype);var MV=(function(r){E(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})(mr);function vv(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function IV(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function Ho(r,e,t,a,n,i){var o=[],s=Gr(e,a),l=s?e.getCalculationInfo("stackResultDimension"):a,u=Jh(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),h=je(e.get(a,c));return h=Math.min(h,20),h>=0&&(o[i]=+o[i].toFixed(h)),[o,v]}var Yu={min:tt(Ho,"min"),max:tt(Ho,"max"),average:tt(Ho,"average"),median:tt(Ho,"median")};function Fi(r,e){if(e){var t=r.getData(),a=r.coordinateSystem,n=a&&a.dimensions;if(!IV(e)&&!B(e.coord)&&B(n)){var i=B1(e,t,a,r);if(e=j(e),e.type&&Yu[e.type]&&i.baseAxis&&i.valueAxis){var o=ct(n,i.baseAxis.dim),s=ct(n,i.valueAxis.dim),l=Yu[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||!B(n))e.coord=[];else for(var u=e.coord,c=0;c<2;c++)Yu[u[c]]&&(u[c]=Jh(t,t.mapDimension(n[c]),u[c]));return e}}function B1(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(LV(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 LV(r,e){var t=r.getData().getDimensionInfo(e);return t&&t.coordDim}function Hi(r,e){return r&&r.containData&&e.coord&&!vv(e)?r.containData(e.coord):!0}function PV(r,e,t){return r&&r.containZone&&e.coord&&t.coord&&!vv(e)&&!vv(t)?r.containZone(e.coord,t.coord):!0}function z1(r,e){return r?function(t,a,n,i){var o=i<2?t.coord&&t.coord[i]:t.value;return Or(o,e[i])}:function(t,a,n,i){return Or(t.value,e[i])}}function Jh(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 Zu=ut(),Qh=(function(r){E(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=$()},e.prototype.render=function(t,a,n){var i=this,o=this.markerGroupMap;o.each(function(s){Zu(s).keep=!1}),a.eachSeries(function(s){var l=mr.getMarkerModelFromSeries(s,i.type);l&&i.renderSeries(s,l,a,n)}),o.each(function(s){!Zu(s).keep&&i.group.remove(s.group)})},e.prototype.markKeep=function(t){Zu(t).keep=!0},e.prototype.toggleBlurSeries=function(t,a){var n=this;w(t,function(i){var o=mr.getMarkerModelFromSeries(i,n.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(a?o0(l):Dv(l))})}})},e.type="marker",e})(Rt);function $y(r,e,t){var a=e.coordinateSystem;r.each(function(n){var i=r.getItemModel(n),o,s=H(i.get("x"),t.getWidth()),l=H(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 RV=(function(r){E(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=mr.getMarkerModelFromSeries(i,"markPoint");o&&($y(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=EV(o,t,a);a.setData(v),$y(a.getData(),t,i),v.each(function(h){var f=v.getItemModel(h),p=f.getShallow("symbol"),d=f.getShallow("symbolSize"),g=f.getShallow("symbolRotate"),y=f.getShallow("symbolOffset"),m=f.getShallow("symbolKeepAspect");if(K(p)||K(d)||K(g)||K(y)){var S=a.getRawValue(h),_=a.getDataParams(h);K(p)&&(p=p(S,_)),K(d)&&(d=d(S,_)),K(g)&&(g=g(S,_)),K(y)&&(y=y(S,_))}var x=f.getModel("itemStyle").getItemStyle(),b=io(l,"color");x.fill||(x.fill=b),v.setItemVisual(h,{symbol:p,symbolSize:d,symbolRotate:g,symbolOffset:y,symbolKeepAspect:m,style:x})}),c.updateData(v),this.group.add(c.group),v.eachItemGraphicEl(function(h){h.traverse(function(f){q(f).dataModel=a})}),this.markKeep(c),c.group.silent=a.get("silent")||t.get("silent")},e.type="markPoint",e})(Qh);function EV(r,e,t){var a;r?a=G(r&&r.dimensions,function(s){var l=e.getData().getDimensionInfo(e.getData().mapDimension(s))||{};return z(z({},l),{name:s,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new he(a,t),i=G(t.get("data"),tt(Fi,e));r&&(i=_t(i,tt(Hi,r)));var o=z1(!!r,a);return n.initData(i,null,o),n}function kV(r){r.registerComponentModel(MV),r.registerComponentView(RV),r.registerPreprocessor(function(e){jh(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var NV=(function(r){E(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})(mr),Wo=ut(),OV=function(r,e,t,a){var n=r.getData(),i;if(B(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=Qt(a.yAxis,a.xAxis);else{var u=B1(a,n,e,r);s=u.valueAxis;var c=U0(n,u.valueDataDim);l=Jh(n,c,o)}var v=s.dim==="x"?0:1,h=1-v,f=j(a),p={coord:[]};f.type=null,f.coord=[],f.coord[h]=-1/0,p.coord[h]=1/0;var d=t.get("precision");d>=0&&St(l)&&(l=+l.toFixed(Math.min(d,20))),f.coord[v]=p.coord[v]=l,i=[f,p,{type:o,valueIndex:a.valueIndex,value:l}]}else i=[]}var g=[Fi(r,i[0]),Fi(r,i[1]),z({},i[2])];return g[2].type=g[2].type||null,nt(g[2],g[0]),nt(g[2],g[1]),g};function zs(r){return!isNaN(r)&&!isFinite(r)}function Xy(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 VV(r,e){if(r.type==="cartesian2d"){var t=e[0].coord,a=e[1].coord;if(t&&a&&(Xy(1,t,a,r)||Xy(0,t,a,r)))return!0}return Hi(r,e[0])&&Hi(r,e[1])}function $u(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=H(o.get("x"),n.getWidth()),u=H(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),h=r.get(c[1],e);s=i.dataToPoint([v,h])}if(Pa(i,"cartesian2d")){var f=i.getAxis("x"),p=i.getAxis("y"),c=i.dimensions;zs(r.get(c[0],e))?s[0]=f.toGlobalCoord(f.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 BV=(function(r){E(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=mr.getMarkerModelFromSeries(i,"markLine");if(o){var s=o.getData(),l=Wo(o).from,u=Wo(o).to;l.each(function(c){$u(l,c,!0,i,n),$u(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 _h);this.group.add(c.group);var v=zV(o,t,a),h=v.from,f=v.to,p=v.line;Wo(a).from=h,Wo(a).to=f,a.setData(p);var d=a.get("symbol"),g=a.get("symbolSize"),y=a.get("symbolRotate"),m=a.get("symbolOffset");B(d)||(d=[d,d]),B(g)||(g=[g,g]),B(y)||(y=[y,y]),B(m)||(m=[m,m]),v.from.each(function(_){S(h,_,!0),S(f,_,!1)}),p.each(function(_){var x=p.getItemModel(_).getModel("lineStyle").getLineStyle();p.setItemLayout(_,[h.getItemLayout(_),f.getItemLayout(_)]),x.stroke==null&&(x.stroke=h.getItemVisual(_,"style").fill),p.setItemVisual(_,{fromSymbolKeepAspect:h.getItemVisual(_,"symbolKeepAspect"),fromSymbolOffset:h.getItemVisual(_,"symbolOffset"),fromSymbolRotate:h.getItemVisual(_,"symbolRotate"),fromSymbolSize:h.getItemVisual(_,"symbolSize"),fromSymbol:h.getItemVisual(_,"symbol"),toSymbolKeepAspect:f.getItemVisual(_,"symbolKeepAspect"),toSymbolOffset:f.getItemVisual(_,"symbolOffset"),toSymbolRotate:f.getItemVisual(_,"symbolRotate"),toSymbolSize:f.getItemVisual(_,"symbolSize"),toSymbol:f.getItemVisual(_,"symbol"),style:x})}),c.updateData(p),v.line.eachItemGraphicEl(function(_){q(_).dataModel=a,_.traverse(function(x){q(x).dataModel=a})});function S(_,x,b){var A=_.getItemModel(x);$u(_,x,b,t,i);var T=A.getModel("itemStyle").getItemStyle();T.fill==null&&(T.fill=io(l,"color")),_.setItemVisual(x,{symbolKeepAspect:A.get("symbolKeepAspect"),symbolOffset:pt(A.get("symbolOffset",!0),m[b?0:1]),symbolRotate:pt(A.get("symbolRotate",!0),y[b?0:1]),symbolSize:pt(A.get("symbolSize"),g[b?0:1]),symbol:pt(A.get("symbol",!0),d[b?0:1]),style:T})}this.markKeep(c),c.group.silent=a.get("silent")||t.get("silent")},e.type="markLine",e})(Qh);function zV(r,e,t){var a;r?a=G(r&&r.dimensions,function(u){var c=e.getData().getDimensionInfo(e.getData().mapDimension(u))||{};return z(z({},c),{name:u,ordinalMeta:null})}):a=[{name:"value",type:"float"}];var n=new he(a,t),i=new he(a,t),o=new he([],t),s=G(t.get("data"),tt(OV,e,r,t));r&&(s=_t(s,tt(VV,r)));var l=z1(!!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}}function GV(r){r.registerComponentModel(NV),r.registerComponentView(BV),r.registerPreprocessor(function(e){jh(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var FV=(function(r){E(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})(mr),Uo=ut(),HV=function(r,e,t,a){var n=a[0],i=a[1];if(!(!n||!i)){var o=Fi(r,n),s=Fi(r,i),l=o.coord,u=s.coord;l[0]=Qt(l[0],-1/0),l[1]=Qt(l[1],-1/0),u[0]=Qt(u[0],1/0),u[1]=Qt(u[1],1/0);var c=mv([{},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 Ky(r,e,t,a){var n=1-r;return Gs(e[n])&&Gs(t[n])}function WV(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&&(Ky(1,t,a)||Ky(0,t,a))?!0:PV(r,n,i):Hi(r,n)||Hi(r,i)}function qy(r,e,t,a,n){var i=a.coordinateSystem,o=r.getItemModel(e),s,l=H(o.get(t[0]),n.getWidth()),u=H(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),h=i.clampData(c),f=i.clampData(v),p=[];t[0]==="x0"?p[0]=h[0]>f[0]?v[0]:c[0]:p[0]=h[0]>f[0]?c[0]:v[0],t[1]==="y0"?p[1]=h[1]>f[1]?v[1]:c[1]:p[1]=h[1]>f[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 jy=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],UV=(function(r){E(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=mr.getMarkerModelFromSeries(i,"markArea");if(o){var s=o.getData();s.each(function(l){var u=G(jy,function(v){return qy(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 et});this.group.add(c.group),this.markKeep(c);var v=YV(o,t,a);a.setData(v),v.each(function(h){var f=G(jy,function(T){return qy(v,h,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",h)),p.parse(v.get("x1",h))],S=[d.parse(v.get("y0",h)),d.parse(v.get("y1",h))];Le(m),Le(S);var _=!(g[0]>m[1]||g[1]<m[0]||y[0]>S[1]||y[1]<S[0]),x=!_;v.setItemLayout(h,{points:f,allClipped:x});var b=v.getItemModel(h).getModel("itemStyle").getItemStyle(),A=io(l,"color");b.fill||(b.fill=A,Y(b.fill)&&(b.fill=fs(b.fill,.4))),b.stroke||(b.stroke=A),v.setItemVisual(h,"style",b)}),v.diff(Uo(c).data).add(function(h){var f=v.getItemLayout(h);if(!f.allClipped){var p=new ke({shape:{points:f.points}});v.setItemGraphicEl(h,p),c.group.add(p)}}).update(function(h,f){var p=Uo(c).data.getItemGraphicEl(f),d=v.getItemLayout(h);d.allClipped?p&&c.group.remove(p):(p?ft(p,{shape:{points:d.points}},a,h):p=new ke({shape:{points:d.points}}),v.setItemGraphicEl(h,p),c.group.add(p))}).remove(function(h){var f=Uo(c).data.getItemGraphicEl(h);c.group.remove(f)}).execute(),v.eachItemGraphicEl(function(h,f){var p=v.getItemModel(f),d=v.getItemVisual(f,"style");h.useStyle(v.getItemVisual(f,"style")),ae(h,qt(p),{labelFetcher:a,labelDataIndex:f,defaultText:v.getName(f)||"",inheritColor:Y(d.fill)?fs(d.fill,1):"#000"}),re(h,p),kt(h,null,null,p.get(["emphasis","disabled"])),q(h).dataModel=a}),Uo(c).data=v,c.group.silent=a.get("silent")||t.get("silent")},e.type="markArea",e})(Qh);function YV(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 z(z({},v),{name:u,ordinalMeta:null})});n=G(i,function(u,c){return{name:u,type:o[c%2].type}}),a=new he(n,t)}else n=[{name:"value",type:"float"}],a=new he(n,t);var s=G(t.get("data"),tt(HV,e,r,t));r&&(s=_t(s,tt(WV,r)));var l=r?function(u,c,v,h){var f=u.coord[Math.floor(h/2)][h%2];return Or(f,n[h])}:function(u,c,v,h){return Or(u.value,n[h])};return a.initData(s,null,l),a.hasItemOption=!0,a}function ZV(r){r.registerComponentModel(FV),r.registerComponentView(UV),r.registerPreprocessor(function(e){jh(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var $V=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"])}},hv=(function(r){E(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"]),B(a)&&w(a,function(i,o){Y(i)&&(i={type:i}),a[o]=nt(i,$V(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,h=v.getAllNames();t.isSeriesFiltered(l)||(n=n.concat(h)),h.length?a=a.concat(h):c=!0}else c=!0;c&&xv(l)&&a.push(l.name)}),this._availableNames=n;var i=this.get("data")||a,o=$(),s=G(i,function(l){return(Y(l)||St(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new mt(l,this,this.ecModel))},this);this._data=_t(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),$a=tt,fv=w,Yo=et,G1=(function(r){E(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 Yo),this.group.add(this._selectorGroup=new Yo),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()},h=t.get("padding"),f=Zt(c,v,h),p=this.layoutInner(t,o,f,i,l,u),d=Zt(Q({width:p.width,height:p.height},c),v,h);this.group.x=d.x-p.x,this.group.y=d.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=M1(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=$(),v=a.get("selectedMode"),h=[];n.eachRawSeries(function(f){!f.get("legendHoverLink")&&h.push(f.id)}),fv(a.getData(),function(f,p){var d=f.get("name");if(!this.newlineDisabled&&(d===""||d===`
`)){var g=new Yo;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")||{},_=m.getVisual("legendIcon"),x=m.getVisual("style"),b=this._createItem(y,d,p,f,a,t,S,x,_,v,i);b.on("click",$a(Jy,d,null,i,h)).on("mouseover",$a(pv,y.name,null,i,h)).on("mouseout",$a(dv,y.name,null,i,h)),n.ssr&&b.eachChild(function(A){var T=q(A);T.seriesIndex=y.seriesIndex,T.dataIndex=p,T.ssrType="legend"}),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 D=T.indexOfName(d),C=T.getItemVisual(D,"style"),M=T.getItemVisual(D,"legendIcon"),I=zm(C.fill);I&&I[3]===0&&(I[3]=.2,C=z(z({},C),{fill:Xo(I,"rgba")}));var L=this._createItem(A,d,p,f,a,t,{},C,M,v,i);L.on("click",$a(Jy,null,d,i,h)).on("mouseover",$a(pv,null,d,i,h)).on("mouseout",$a(dv,null,d,i,h)),n.ssr&&L.eachChild(function(R){var P=q(R);P.seriesIndex=A.seriesIndex,P.dataIndex=p,P.ssrType="legend"}),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 vt({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect",legendId:a.id})}});s.add(v);var h=a.getModel("selectorLabel"),f=a.getModel(["emphasis","selectorLabel"]);ae(v,{normal:h,emphasis:f},{defaultText:u.title}),fa(v)})},e.prototype._createItem=function(t,a,n,i,o,s,l,u,c,v,h){var f=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 _=XV(c,i,l,u,f,g,h),x=new Yo,b=i.getModel("textStyle");if(K(t.getLegendIcon)&&(!S||S==="inherit"))x.add(t.getLegendIcon({itemWidth:p,itemHeight:d,icon:c,iconRotate:y,itemStyle:_.itemStyle,lineStyle:_.lineStyle,symbolKeepAspect:m}));else{var A=S==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;x.add(KV({itemWidth:p,itemHeight:d,icon:c,iconRotate:A,itemStyle:_.itemStyle,symbolKeepAspect:m}))}var T=s==="left"?p+5:-5,D=s,C=o.get("formatter"),M=a;Y(C)&&C?M=C.replace("{name}",a??""):K(C)&&(M=C(a));var I=g?b.getTextColor():i.get("inactiveColor");x.add(new vt({style:Dt(b,{text:M,x:T,y:d/2,fill:I,align:D,verticalAlign:"middle"},{inheritColor:I})}));var L=new dt({shape:x.getBoundingRect(),style:{fill:"transparent"}}),R=i.getModel("tooltip");return R.get("show")&&Ma({el:L,componentModel:o,itemName:a,itemTooltipOption:R.option}),x.add(L),x.eachChild(function(P){P.silent=!0}),L.silent=!v,this.getContentGroup().add(x),fa(x),x.__legendDataIndex=n,x},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 h=u.getBoundingRect(),f=[-h.x,-h.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"?f[d]+=c[g]+p:v[d]+=h[g]+p,f[1-d]+=c[y]/2-h[y]/2,u.x=f[0],u.y=f[1],l.x=v[0],l.y=v[1];var S={x:0,y:0};return S[g]=c[g]+p+h[g],S[y]=Math.max(c[y],h[y]),S[m]=Math.min(0,h[m]+f[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})(Rt);function XV(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:vn(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 h=e.getModel("lineStyle"),f=h.getLineStyle();if(s(f,t),u.fill==="auto"&&(u.fill=a.fill),u.stroke==="auto"&&(u.stroke=a.fill),f.stroke==="auto"&&(f.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"),f.stroke=h.get("inactiveColor"),f.lineWidth=h.get("inactiveWidth")}return{itemStyle:u,lineStyle:f}}function KV(r){var e=r.icon||"roundRect",t=Wt(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 Jy(r,e,t,a){dv(r,e,t,a),t.dispatchAction({type:"legendToggleSelect",name:r??e}),pv(r,e,t,a)}function F1(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 pv(r,e,t,a){F1(t)||t.dispatchAction({type:"highlight",seriesName:r,name:e,excludeSeriesId:a})}function dv(r,e,t,a){F1(t)||t.dispatchAction({type:"downplay",seriesName:r,name:e,excludeSeriesId:a})}function qV(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 Qn(r,e,t){var a=r==="allSelect"||r==="inverseSelect",n={},i=[];t.eachComponent({mainType:"legend",query:e},function(s){a?s[r]():s[r](e.name),Qy(s,n),i.push(s.componentIndex)});var o={};return t.eachComponent("legend",function(s){w(n,function(l,u){s[l?"select":"unSelect"](u)}),Qy(s,o)}),a?{selected:o,legendIndex:i}:{name:e.name,selected:o}}function Qy(r,e){var t=e||{};return w(r.getData(),function(a){var n=a.get("name");if(!(n===`
`||n==="")){var i=r.isSelected(n);Z(t,n)?t[n]=t[n]&&i:t[n]=i}}),t}function jV(r){r.registerAction("legendToggleSelect","legendselectchanged",tt(Qn,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",tt(Qn,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",tt(Qn,"inverseSelect")),r.registerAction("legendSelect","legendselected",tt(Qn,"select")),r.registerAction("legendUnSelect","legendunselected",tt(Qn,"unSelect"))}function H1(r){r.registerComponentModel(hv),r.registerComponentView(G1),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,qV),r.registerSubTypeDefaulter("legend",function(){return"plain"}),jV(r)}var JV=(function(r){E(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=Mn(t);r.prototype.init.call(this,t,a,n),tm(this,t,i)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),tm(this,this.option,t)},e.type="legend.scroll",e.defaultOption=Yr(hv.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})(hv);function tm(r,e,t){var a=r.getOrient(),n=[1,1];n[a.index]=0,Fr(e,t,{type:"box",ignoreSize:!!n})}var em=et,Xu=["width","height"],Ku=["x","y"],QV=(function(r){E(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 em),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new em)},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),h=B(v)?v:[v,v];p("pagePrev",0);var f=a.getModel("pageTextStyle");c.add(new vt({name:"pageText",style:{text:"xx/xx",fill:f.getTextColor(),font:f.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),p("pageNext",1);function p(d,g){var y=d+"DataIndex",m=qi(a.get("pageIcons",!0)[a.getOrient().name][g],{onclick:U(u._pageGo,u,y,a,i)},{x:-h[0]/2,y:-h[1]/2,width:h[0],height:h[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=Xu[u],v=Ku[u],h=Xu[1-u],f=Ku[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=j(n);o&&(y[c]=n[c]-d[c]-p);var m=this._layoutContentAndController(t,i,y,u,c,h,f,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[f]+m[h]/2-d[h]/2,m[h]=Math.max(m[h],d[h]),m[f]=Math.min(m[f],d[f]+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,h=this._controllerGroup;da(t.get("orient"),c,t.get("itemGap"),i?n.width:null,i?null:n.height),da("horizontal",h,t.get("pageButtonItemGap",!0));var f=c.getBoundingRect(),p=h.getBoundingRect(),d=this._showController=f[o]>n[o],g=[-f.x,-f.y];a||(g[i]=c[u]);var y=[0,0],m=[-p.x,-p.y],S=pt(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var _=t.get("pageButtonPosition",!0);_==="end"?m[i]+=n[o]-p[o]:y[i]+=p[o]+S}m[1-i]+=f[s]/2-p[s]/2,c.setPosition(g),v.setPosition(y),h.setPosition(m);var x={x:0,y:0};if(x[o]=d?n[o]:f[o],x[s]=Math.max(f[s],p[s]),x[l]=Math.min(0,p[l]+m[1-i]),v.__rectSize=n[o],d){var b={x:0,y:0};b[o]=Math.max(n[o]-p[o]-S,0),b[s]=x[s],v.setClipPath(new dt({shape:b})),v.__rectSize=b[o]}else h.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),x},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",h=a[v]!=null,f=n.childOfName(c);f&&(f.setStyle("fill",h?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),f.cursor=h?"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",Y(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=Xu[o],l=Ku[o],u=this._findTargetItemIndex(a),c=n.children(),v=c[u],h=c.length,f=h?1:0,p={contentPosition:[n.x,n.y],pageCount:f,pageIndex:f-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!v)return p;var d=_(v);p.contentPosition[o]=-d.s;for(var g=u+1,y=d,m=d,S=null;g<=h;++g)S=_(c[g]),(!S&&m.e>y.s+i||S&&!x(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=_(c[g]),(!S||!x(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 _(b){if(b){var A=b.getBoundingRect(),T=A[l]+b[l];return{s:T,e:T+A[s],i:b.__legendDataIndex}}}function x(b,A){return b.e>=A&&b.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})(G1);function tB(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 eB(r){it(H1),r.registerComponentModel(JV),r.registerComponentView(QV),tB(r)}function rB(r){it(H1),it(eB)}var aB=(function(r){E(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=Yr(Gi.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e})(Gi),tf=ut();function nB(r,e,t){tf(r).coordSysRecordMap.each(function(a){var n=a.dataZoomInfoMap.get(e.uid);n&&(n.getRange=t)})}function iB(r,e){for(var t=tf(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||W1(t,o))}}}function W1(r,e){if(e){r.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function oB(r,e){var t={model:e,containsPoint:tt(lB,e),dispatchAction:tt(sB,r),dataZoomInfoMap:null,controller:null},a=t.controller=new so(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 sB(r,e){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function lB(r,e,t,a){return r.coordinateSystem.containPoint([t,a])}function uB(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 cB(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(e,t){var a=tf(t),n=a.coordSysRecordMap||(a.coordSysRecordMap=$());n.each(function(i){i.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(i){var o=T1(i);w(o.infoList,function(s){var l=s.model.uid,u=n.get(l)||n.set(l,oB(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=$());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){W1(n,i);return}var c=uB(l);o.enable(c.controlType,c.opt),o.setPointerChecker(i.containsPoint),Pn(i,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var vB=(function(r){E(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(),nB(n,t,{pan:U(qu.pan,this),zoom:U(qu.zoom,this),scrollMove:U(qu.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){iB(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e})(Yh),qu={zoom:function(r,e,t,a){var n=this.range,i=n.slice(),o=r.axisModels[0];if(o){var s=ju[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(ka(0,i,[0,100],0,c.minSpan,c.maxSpan),this.range=i,n[0]!==i[0]||n[1]!==i[1])return i}},pan:rm(function(r,e,t,a,n,i){var o=ju[a]([i.oldX,i.oldY],[i.newX,i.newY],e,n,t);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:rm(function(r,e,t,a,n,i){var o=ju[a]([0,0],[i.scrollDelta,i.scrollDelta],e,n,t);return o.signal*(r[1]-r[0])*i.scrollDelta})};function rm(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(ka(l,o,[0,100],"all"),this.range=o,i[0]!==o[0]||i[1]!==o[1])return o}}}var ju={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}};function U1(r){Zh(r),r.registerComponentModel(aB),r.registerComponentView(vB),cB(r)}var hB=(function(r){E(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=Yr(Gi.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e})(Gi),ti=dt,am=7,fB=1,Ju=30,pB=7,ei="horizontal",nm="vertical",dB=5,gB=["line","bar","candlestick","scatter"],yB={easing:"cubicOut",duration:100,delay:0},mB=(function(r){E(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=U(this._onBrush,this),this._onBrushEnd=U(this._onBrushEnd,this)},e.prototype.render=function(t,a,n,i){if(r.prototype.render.apply(this,arguments),Pn(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(){Li(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 et;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?pB:0,o=this._findCoordRect(),s={width:a.getWidth(),height:a.getHeight()},l=this._orient===ei?{right:s.width-o.x-o.width,top:s.height-Ju-am-i,width:o.width,height:Ju}:{right:am,top:o.y,width:Ju,height:o.height},u=Mn(t.option);w(["right","top","width","height"],function(v){u[v]==="ph"&&(u[v]=l[v])});var c=Zt(u,s);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===nm&&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===ei&&!o?{scaleY:l?1:-1,scaleX:1}:n===ei&&o?{scaleY:l?1:-1,scaleX:-1}:n===nm&&!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 ti({silent:!0,shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new ti({shape:{x:0,y:0,width:a[0],height:a[1]},style:{fill:"transparent"},z2:0,onclick:U(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),h=(v[1]-v[0])*.3;v=[v[0]-h,v[1]+h];var f=[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]),_;o.each([l],function(D,C){if(S>0&&C%S){m+=y;return}var M=D==null||isNaN(D)||D==="",I=M?0:yt(D,v,f,!0);M&&!_&&C?(d.push([d[d.length-1][0],0]),g.push([g[g.length-1][0],0])):!M&&_&&(d.push([m,0]),g.push([m,0])),d.push([m,I]),g.push([m,I]),m+=y,_=M}),u=this._shadowPolygonPts=d,c=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=l,this._shadowSize=[a[0],a[1]];var x=this.dataZoomModel;function b(D){var C=x.getModel(D?"selectedDataBackground":"dataBackground"),M=new et,I=new ke({shape:{points:u},segmentIgnoreThreshold:1,style:C.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),L=new xe({shape:{points:c},segmentIgnoreThreshold:1,style:C.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return M.add(I),M.add(L),M}for(var A=0;A<3;A++){var T=b(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(gB,u.get("type"))<0)){var c=i.getComponent(Er(o),s).axis,v=SB(o),h,f=u.coordinateSystem;v!=null&&f.getOtherAxis&&(h=f.getOtherAxis(c).inverse),v=u.getData().mapDimension(v),n={thisAxis:c,series:u,thisDim:o,otherDim:v,otherAxisInverse:h}}},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"),h=a.filler=new ti({silent:v,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(h),o.add(new ti({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:fB,fill:"rgba(0,0,0,0)"}})),w([0,1],function(S){var _=l.get("handleIcon");!xs[_]&&_.indexOf("path://")<0&&_.indexOf("image://")<0&&(_="path://"+_);var x=Wt(_,-1,0,2,2,null,!0);x.attr({cursor:im(this._orient),draggable:!0,drift:U(this._onDragMove,this,S),ondragend:U(this._onDragEnd,this),onmouseover:U(this._showDataInfo,this,!0),onmouseout:U(this._showDataInfo,this,!1),z2:5});var b=x.getBoundingRect(),A=l.get("handleSize");this._handleHeight=H(A,this._size[1]),this._handleWidth=b.width/b.height*this._handleHeight,x.setStyle(l.getModel("handleStyle").getItemStyle()),x.style.strokeNoScale=!0,x.rectHover=!0,x.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),fa(x);var T=l.get("handleColor");T!=null&&(x.style.fill=T),o.add(n[S]=x);var D=l.getModel("textStyle"),C=l.get("handleLabel")||{},M=C.show||!1;t.add(i[S]=new vt({silent:!0,invisible:!M,style:Dt(D,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:D.getTextColor(),font:D.getFont()}),z2:10}))},this);var f=h;if(v){var p=H(l.get("moveHandleSize"),s[1]),d=a.moveHandle=new dt({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=Wt(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));f=a.moveZone=new dt({invisible:!0,shape:{y:s[1]-m,height:p+m}}),f.on("mouseover",function(){u.enterEmphasis(d)}).on("mouseout",function(){u.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(f)}f.attr({draggable:!0,cursor:im(this._orient),drift:U(this._onDragMove,this,"all"),ondragstart:U(this._showDataInfo,this,!0),ondragend:U(this._onDragEnd,this),onmouseover:U(this._showDataInfo,this,!0),onmouseout:U(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),a=this._getViewExtent();this._handleEnds=[yt(t[0],[0,100],a,!0),yt(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];ka(a,i,o,n.get("zoomLock")?"all":t,s.minSpan!=null?yt(s.minSpan,l,o,!0):null,s.maxSpan!=null?yt(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=Le([yt(i[0],o,l,!0),yt(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=Le(n.slice()),o=this._size;w([0,1],function(f){var p=a.handles[f],d=this._handleHeight;p.attr({scaleX:d/2,scaleY:d/2,x:n[f]+(f?-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],h=v.getClipPath();h||(h=new dt,v.setClipPath(h)),h.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 h=Le(this._handleEnds.slice());f.call(this,0),f.call(this,1);function f(p){var d=pa(n.handles[p].parent,this.group),g=qs(p===0?"right":"left",d),y=this._handleWidth/2+dB,m=We([h[p]+(p===0?-y:y),this._size[1]/2],d);i[p].setStyle({x:m[0],y:m[1],verticalAlign:o===ei?"middle":g,align:o===ei?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 K(i)?i(t,s):Y(i)?i.replace("{value}",s):s},e.prototype._showDataInfo=function(t){var a=this.dataZoomModel.get("handleLabel")||{},n=a.show||!1,i=this.dataZoomModel.getModel(["emphasis","handleLabel"]),o=i.get("show")||!1,s=t||this._dragging?o:n,l=this._displayables,u=l.handleLabels;u[0].attr("invisible",!s),u[1].attr("invisible",!s),l.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](l.moveHandle,1)},e.prototype._onDragMove=function(t,a,n,i){this._dragging=!0,Br(i.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=We([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 Ft(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=Le([yt(n.x,o,s,!0),yt(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&&(Br(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 ti({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?yB:null,start:a[0],end:a[1]})},e.prototype._findCoordRect=function(){var t,a=T1(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})(Yh);function SB(r){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[r]}function im(r){return r==="vertical"?"ns-resize":"ew-resize"}function Y1(r){r.registerComponentModel(hB),r.registerComponentView(mB),Zh(r)}function _B(r){it(U1),it(Y1)}var Z1={get:function(r,e,t){var a=j((xB[r]||{})[e]);return t&&B(a)?a[a.length-1]:a}},xB={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]}},om=Kt.mapVisual,bB=Kt.eachVisual,wB=B,sm=w,AB=Le,TB=yt,Fs=(function(r){E(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&&N1(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var a=this.stateList;t=U(t,this),this.controllerVisuals=uv(this.option.controller,a,t),this.targetVisuals=uv(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=xt(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||["<",">"],B(t)&&(t=t.slice(),u=!0);var c=a?t:u?[v(t[0]),v(t[1])]:v(t);if(Y(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(K(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(h){return h===s[0]?"min":h===s[1]?"max":(+h).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,a=AB([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={});nt(i,n),nt(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){wB(a.color)&&!v.inRange&&(v.inRange={color:a.color.slice().reverse()}),v.inRange=v.inRange||{color:t.get("gradientColor")}}function u(v,h,f){var p=v[h],d=v[f];p&&!d&&(d=v[f]={},sm(p,function(g,y){if(Kt.isValidType(y)){var m=Z1.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 h=(v.inRange||{}).symbol||(v.outOfRange||{}).symbol,f=(v.inRange||{}).symbolSize||(v.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),d=this.getItemSymbol(),g=d||"roundRect";sm(this.stateList,function(y){var m=this.itemSize,S=v[y];S||(S=v[y]={color:s?p:[p]}),S.symbol==null&&(S.symbol=h&&j(h)||(s?g:[g])),S.symbolSize==null&&(S.symbolSize=f&&j(f)||(s?m[0]:[m[0],m[0]])),S.symbol=om(S.symbol,function(b){return b==="none"?g:b});var _=S.symbolSize;if(_!=null){var x=-1/0;bB(_,function(b){b>x&&(x=b)}),S.symbolSize=om(_,function(b){return TB(b,[0,x],[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),lm=[20,140],DB=(function(r){E(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]=lm[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=lm[1])},e.prototype._resetRange=function(){var t=this.getExtent(),a=this.option.range;!a||a.auto?(t.auto=1,this.option.range=t):B(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=Le((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=um(this,"outOfRange",this.getExtent()),n=um(this,"inRange",this.option.range.slice()),i=[];function o(f,p){i.push({value:f,color:t(f,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 h=i.length;return{stops:i,outerColors:[h?i[0].color:"transparent",h?i[h-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=Yr(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 um(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}var $1=(function(r){E(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=Cn(a.get("padding")||0),i=t.getBoundingRect();t.add(new dt({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(f){return s[f]}function c(f,p){s[f]=p}var v=o.controllerVisuals[i||o.getValueState(t)],h=Kt.prepareVisualTypes(v);return w(h,function(f){var p=v[f];n.convertOpacityToAlpha&&f==="opacity"&&(f="colorAlpha",p=v.__alphaForOpacity),Kt.dependsOn(f,a)&&p&&p.applyVisual(t,u,c)}),s[a]},e.prototype.positionGroup=function(t){var a=this.visualMapModel,n=this.api;il(t,a.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})},e.prototype.doRender=function(t,a,n,i){},e.type="visualMap",e})(Rt),cm=[["left","right","width"],["top","bottom","height"]];function X1(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=cm[o],l=[0,null,10],u={},c=0;c<3;c++)u[cm[1-o][c]]=l[c],u[s[c]]=c===2?t[0]:a[s[c]];var v=[["x","width",3],["y","height",0]][o],h=Zt(u,i,a.padding);return s[(h.margin[v[2]]||0)+h[v[0]]+h[v[1]]*.5<i[v[1]]*.5?0:1]}function ss(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 Xe=yt,CB=w,vm=Math.min,Qu=Math.max,MB=12,IB=6,LB=(function(r){E(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.init=function(t,a){r.prototype.init.call(this,t,a),this._hoverLinkFromSeriesMouseOver=U(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=U(this._hideIndicator,this)},e.prototype.doRender=function(t,a,n,i){(!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),h=this._orient,f=this.visualMapModel.textStyleModel;this.group.add(new vt({style:Dt(f,{x:c[0],y:c[1],verticalAlign:h==="horizontal"?"middle":v,align:h==="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=X1(a,this.api,i),u=n.mainGroup=this._createBarGroup(l),c=new et;u.add(c),c.add(n.outOfRange=hm()),c.add(n.inRange=hm(null,s?pm(this._orient):null,U(this._dragHandle,this,"all",!1),U(this._dragHandle,this,"all",!0))),c.setClipPath(new dt({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));var v=a.textStyleModel.getTextRect("国"),h=Qu(v.width,v.height);s&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(a,u,0,i,h,o),this._createHandle(a,u,1,i,h,o)),this._createIndicator(a,u,i,h,o),t.add(u)},e.prototype._createHandle=function(t,a,n,i,o,s){var l=U(this._dragHandle,this,n,!1),u=U(this._dragHandle,this,n,!0),c=sn(t.get("handleSize"),i[0]),v=Wt(t.get("handleIcon"),-c/2,-c/2,c,c,null,!0),h=pm(this._orient);v.attr({cursor:h,draggable:!0,drift:l,ondragend:u,onmousemove:function(y){Br(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 f=this.visualMapModel.textStyleModel,p=new vt({cursor:h,draggable:!0,drift:l,onmousemove:function(y){Br(y.event)},ondragend:u,style:Dt(f,{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=sn(t.get("indicatorSize"),n[0]),l=Wt(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 Ne){var c=l.style;l.useStyle(z({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,h=new vt({silent:!0,invisible:!0,style:Dt(v,{x:0,y:0,text:""})});this.group.add(h);var f=[(o==="horizontal"?i/2:IB)+n[0]/2,0],p=this._shapes;p.indicator=l,p.indicatorLabel=h,p.indicatorLabelPoint=f,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():fm(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=[Xe(a[0],n,i,!0),Xe(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]];ka(a,i,o,t,0);var s=n.getExtent();this._dataInterval=[Xe(i[0],o,s,!0),Xe(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 Us(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 et(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(),c=this._applyTransform("left",n.mainGroup);CB([0,1],function(v){var h=o[v];h.setStyle("fill",a.handlesColor[v]),h.y=t[v];var f=Xe(t[v],[0,l[1]],u,!0),p=this.getControllerVisual(f,"symbolSize");h.scaleX=h.scaleY=p/l[0],h.x=l[0]-p/2;var d=We(n.handleLabelPoints[v],pa(h,this.group));if(this._orient==="horizontal"){var g=c==="left"||c==="top"?(l[0]-p)/2:(l[0]-p)/-2;d[1]+=g}s[v].setStyle({x:d[0],y:d[1],text:i.formatValueText(this._dataInterval[v]),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 h={convertOpacityToAlpha:!0},f=this.getControllerVisual(t,"color",h),p=this.getControllerVisual(t,"symbolSize"),d=Xe(t,s,u,!0),g=l[0]-p/2,y={x:v.x,y:v.y};v.y=d,v.x=g;var m=We(c.indicatorLabelPoint,pa(v,this.group)),S=c.indicatorLabel;S.attr("invisible",!1);var _=this._applyTransform("left",c.mainGroup),x=this._orient,b=x==="horizontal";S.setStyle({text:(n||"")+o.formatValueText(a),verticalAlign:b?_:"middle",align:b?"center":_});var A={x:g,y:d,style:{fill:f}},T={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var D={duration:100,easing:"cubicInOut",additive:!0};v.x=y.x,v.y=y.y,v.animateTo(A,D),S.animateTo(T,D)}else v.attr(A),S.attr(T);this._firstShowIndicator=!1;var C=this._shapes.handleLabels;if(C)for(var M=0;M<C.length;M++)this.api.enterBlur(C[M])}},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]=vm(Qu(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=vm(Qu(o[0],t),o[1]);var l=PB(n,s,o),u=[t-l,t+l],c=Xe(t,o,s,!0),v=[Xe(u[0],o,s,!0),Xe(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 h=this._hoverLinkDataIndices,f=[];(a||fm(n))&&(f=this._hoverLinkDataIndices=n.findTargetDataIndices(v));var p=mw(h,f);this._dispatchHighDown("downplay",ss(p[0],n)),this._dispatchHighDown("highlight",ss(p[1],n))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var a;if(va(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",ss(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 B(t)?We(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.type="visualMap.continuous",e})($1);function hm(r,e,t,a){return new ke({shape:{points:r},draggable:!!t,cursor:e,drift:t,onmousemove:function(n){Br(n.event)},ondragend:a})}function PB(r,e,t){var a=MB/2,n=r.get("hoverLinkDataSize");return n&&(a=Xe(n,e,t,!0)/2),a}function fm(r){var e=r.get("hoverLinkOnHandle");return!!(e??r.get("realtime"))}function pm(r){return r==="vertical"?"ns-resize":"ew-resize"}var RB={type:"selectDataRange",event:"dataRangeSelected",update:"update"},EB=function(r,e){e.eachComponent({mainType:"visualMap",query:r},function(t){t.setSelected(r.selected)})},kB=[{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(rV(a.stateList,a.targetVisuals,U(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(U(NB,null,r,n))||{stops:[],outerColors:[]},o=n.getDataDimensionIndex(t);o>=0&&(i.dimension=o,a.push(i))}}),r.getData().setVisual("visualMeta",a)}}];function NB(r,e,t,a){for(var n=e.targetVisuals[a],i=Kt.prepareVisualTypes(n),o={color:io(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,h)}return o.color;function v(f){return o[f]}function h(f,p){o[f]=p}}var dm=w;function OB(r){var e=r&&r.visualMap;B(e)||(e=e?[e]:[]),dm(e,function(t){if(t){Xa(t,"splitList")&&!Xa(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var a=t.pieces;a&&B(a)&&dm(a,function(n){J(n)&&(Xa(n,"start")&&!Xa(n,"min")&&(n.min=n.start),Xa(n,"end")&&!Xa(n,"max")&&(n.max=n.end))})}})}function Xa(r,e){return r&&r.hasOwnProperty&&r.hasOwnProperty(e)}var gm=!1;function K1(r){gm||(gm=!0,r.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),r.registerAction(RB,EB),w(kB,function(e){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,e)}),r.registerPreprocessor(OB))}function q1(r){r.registerComponentModel(DB),r.registerComponentView(LB),K1(r)}var VB=(function(r){E(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=[],BB[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=j(i)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=G(this._pieceList,function(l){return l=j(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,a={},n=Kt.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]=Z1.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=j(t)},e.prototype.getValueState=function(t){var a=Kt.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=Kt.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 h=i.getRepresentValue({interval:c});v||(v=i.getValueState(h));var f=t(h,v);c[0]===-1/0?n[0]=f:c[1]===1/0?n[1]=f:a.push({value:c[0],color:f},{value:c[1],color:f})}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=Yr(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),BB={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]}),pf(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),ym(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 h=[["gte","gt","min"],["lte","lt","max"]][v],f=0;f<3&&o[v]==null;f++)o[v]=t[h[f]],s[v]=l[f],c[v]=f===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=Kt.retrieveVisuals(t),r.push(n)},this),ym(e,r),pf(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 ym(r,e){var t=r.inverse;(r.orient==="vertical"?!t:t)&&e.reverse()}var zB=(function(r){E(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,h=Qt(a.get("showLabel",!0),!v),f=!a.get("selectedMode");v&&this._renderEndsText(t,v[0],u,h,l),w(c.viewPieceList,function(p){var d=p.piece,g=new et;g.onclick=U(this._onItemClick,this,d),this._enableHoverLink(g,p.indexInModelPieceList);var y=a.getRepresentValue(d);if(this._createItemSymbol(g,y,[0,0,u[0],u[1]],f),h){var m=this.visualMapModel.getValueState(y);g.add(new vt({style:{x:l==="right"?-n:u[0]+n,y:u[1]/2,text:d.text,verticalAlign:"middle",align:l,font:o,fill:s,opacity:m==="outOfRange"?.5:1},silent:f}))}t.add(g)},this),v&&this._renderEndsText(t,v[1],u,h,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:ss(s.findTargetDataIndices(a),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,a=t.option;if(a.orient==="vertical")return X1(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 et,l=this.visualMapModel.textStyleModel;s.add(new vt({style:Dt(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,i){var o=Wt(this.getControllerVisual(a,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(a,"color"));o.silent=i,t.add(o)},e.prototype._onItemClick=function(t){var a=this.visualMapModel,n=a.option,i=n.selectedMode;if(i){var o=j(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})($1);function j1(r){r.registerComponentModel(VB),r.registerComponentView(zB),K1(r)}function GB(r){it(q1),it(j1)}var FB={label:{enabled:!0},decal:{show:!1}},mm=ut(),HB={};function WB(r,e){var t=r.getModel("aria");if(!t.get("enabled"))return;var a=j(FB);nt(a.label,r.getLocaleModel().get("aria"),!1),nt(t.option,a,!1),n(),i();function n(){var u=t.getModel("decal"),c=u.get("show");if(c){var v=$();r.eachSeries(function(h){if(!h.isColorBySeries()){var f=v.get(h.type);f||(f={},v.set(h.type,f)),mm(h).scope=f}}),r.eachRawSeries(function(h){if(r.isSeriesFiltered(h))return;if(K(h.enableAriaDecal)){h.enableAriaDecal();return}var f=h.getData();if(h.isColorBySeries()){var m=xc(h.ecModel,h.name,HB,r.getSeriesCount()),S=f.getVisual("decal");f.setVisual("decal",_(S,m))}else{var p=h.getRawData(),d={},g=mm(h).scope;f.each(function(x){var b=f.getRawIndex(x);d[b]=x});var y=p.count();p.each(function(x){var b=d[x],A=p.getName(x)||x+"",T=xc(h.ecModel,A,g,y),D=f.getItemVisual(b,"decal");f.setItemVisual(b,"decal",_(D,T))})}function _(x,b){var A=x?z(z({},b),x):b;return A.dirty=!0,A}})}}function i(){var u=e.getZr().dom;if(u){var c=r.getLocaleModel().get("aria"),v=t.getModel("label");if(v.option=Q(v.option,c),!!v.get("enabled")){if(u.setAttribute("role","img"),v.get("description")){u.setAttribute("aria-label",v.get("description"));return}var h=r.getSeriesCount(),f=v.get(["data","maxCount"])||10,p=v.get(["series","maxCount"])||10,d=Math.min(h,p),g;if(!(h<1)){var y=s();if(y){var m=v.get(["general","withTitle"]);g=o(m,{title:y})}else g=v.get(["general","withoutTitle"]);var S=[],_=h>1?v.get(["series","multiple","prefix"]):v.get(["series","single","prefix"]);g+=o(_,{seriesCount:h}),r.eachSeries(function(T,D){if(D<d){var C=void 0,M=T.get("name"),I=M?"withName":"withoutName";C=h>1?v.get(["series","multiple",I]):v.get(["series","single",I]),C=o(C,{seriesId:T.seriesIndex,seriesName:T.get("name"),seriesType:l(T.subType)});var L=T.getData();if(L.count()>f){var R=v.get(["data","partialData"]);C+=o(R,{displayCnt:f})}else C+=v.get(["data","allData"]);for(var P=v.get(["data","separator","middle"]),k=v.get(["data","separator","end"]),O=v.get(["data","excludeDimensionId"]),N=[],V=0;V<L.count();V++)if(V<f){var F=L.getName(V),W=O?_t(L.getValues(V),function(rt,at){return ct(O,at)===-1}):L.getValues(V),X=v.get(["data",F?"withName":"withoutName"]);N.push(o(X,{name:F,value:W.join(P)}))}C+=N.join(P)+k,S.push(C)}});var x=v.getModel(["series","multiple","separator"]),b=x.get("middle"),A=x.get("end");g+=S.join(b)+A,u.setAttribute("aria-label",g)}}}}function o(u,c){if(!Y(u))return u;var v=u;return w(c,function(h,f){v=v.replace(new RegExp("\\{\\s*"+f+"\\s*\\}","g"),h)}),v}function s(){var u=r.get("title");return u&&u.length&&(u=u[0]),u&&u.text}function l(u){var c=r.getLocaleModel().get(["series","typeNames"]);return c[u]||c.chart}}function UB(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 YB(r){r.registerPreprocessor(UB),r.registerVisual(r.PRIORITY.VISUAL.ARIA,WB)}var Sm={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},ZB=(function(){function r(e){var t=this._condVal=Y(e)?new RegExp(e):Vb(e)?e:null;if(t==null){var a="";gt(a)}}return r.prototype.evaluate=function(e){var t=typeof e;return Y(t)?this._condVal.test(e):St(t)?this._condVal.test(e+""):!1},r})(),$B=(function(){function r(){}return r.prototype.evaluate=function(){return this.value},r})(),XB=(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})(),KB=(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})(),qB=(function(){function r(){}return r.prototype.evaluate=function(){return!this.child.evaluate()},r})(),jB=(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 ef(r,e){if(r===!0||r===!1){var t=new $B;return t.value=r,t}var a="";return J1(r)||gt(a),r.and?_m("and",r,e):r.or?_m("or",r,e):r.not?JB(r,e):QB(r,e)}function _m(r,e,t){var a=e[r],n="";B(a)||gt(n),a.length||gt(n);var i=r==="and"?new XB:new KB;return i.children=G(a,function(o){return ef(o,t)}),i.children.length||gt(n),i}function JB(r,e){var t=r.not,a="";J1(t)||gt(a);var n=new qB;return n.child=ef(t,e),n.child||gt(a),n}function QB(r,e){for(var t="",a=e.prepareGetValue(r),n=[],i=Ut(r),o=r.parser,s=o?k0(o):null,l=0;l<i.length;l++){var u=i[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var c=Z(Sm,u)?Sm[u]:u,v=r[u],h=s?s(v):v,f=gA(c,h)||c==="reg"&&new ZB(h);f||gt(t),n.push(f)}}n.length||gt(t);var p=new jB;return p.valueGetterParam=a,p.valueParser=s,p.getValue=e.getValue,p.subCondList=n,p}function J1(r){return J(r)&&!yn(r)}var tz=(function(){function r(e,t){this._cond=ef(e,t)}return r.prototype.evaluate=function(){return this._cond.evaluate()},r})();function ez(r,e){return new tz(r,e)}var rz={type:"echarts:filter",transform:function(r){for(var e=r.upstream,t,a=ez(r.config,{valueGetterAttrMap:$({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;Z(s,"dimension")||gt(l);var c=e.getDimensionInfo(u);return c||gt(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}}},az={type:"echarts:sort",transform:function(r){var e=r.upstream,t=r.config,a="",n=xt(t);n.length||gt(a);var i=[];w(n,function(c){var v=c.dimension,h=c.order,f=c.parser,p=c.incomparable;if(v==null&&gt(a),h!=="asc"&&h!=="desc"&&gt(a),p&&p!=="min"&&p!=="max"){var d="";gt(d)}if(h!=="asc"&&h!=="desc"){var g="";gt(g)}var y=e.getDimensionInfo(v);y||gt(a);var m=f?k0(f):null;f&&!m&&gt(a),i.push({dimIdx:y.index,parser:m,comparator:new O0(h,p)})});var o=e.sourceFormat;o!==se&&o!==Ve&&gt(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 h=0;h<i.length;h++){var f=i[h],p=e.retrieveValueFromItem(c,f.dimIdx),d=e.retrieveValueFromItem(v,f.dimIdx);f.parser&&(p=f.parser(p),d=f.parser(d));var g=f.comparator.evaluate(p,d);if(g!==0)return g}return 0}),{data:s}}};function nz(r){r.registerTransform(rz),r.registerTransform(az)}var iz=(function(r){E(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 lS(this),jf(this)},e.prototype.mergeOption=function(t,a){r.prototype.mergeOption.call(this,t,a),jf(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:tr},e})(lt),oz=(function(r){E(e,r);function e(){var t=r!==null&&r.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e})(Rt);function sz(r){r.registerComponentModel(iz),r.registerComponentView(oz)}function lz(r){if(r){for(var e=[],t=0;t<r.length;t++)e.push(r[t].slice());return e}}function uz(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:lz(a&&a.shape.points)}}var xm=["align","verticalAlign","width","height","fontSize"],ue=new Ja,tc=ut(),cz=ut();function Zo(r,e,t){for(var a=0;a<t.length;a++){var n=t[a];e[n]!=null&&(r[n]=e[n])}}var $o=["x","y","rotation"],vz=(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?ue.setLocalTransform(u):(ue.x=ue.y=ue.rotation=ue.originX=ue.originY=0,ue.scaleX=ue.scaleY=1),ue.rotation=lr(ue.rotation);var v=n.__hostTarget,h;if(v){h=v.getBoundingRect().plain();var f=v.getComputedTransform();wt.applyTransform(h,h,f)}var p=h&&v.getTextGuideLine();this._labelList.push({label:n,labelLine:p,seriesModel:a,dataIndex:e,dataType:t,layoutOption:i,computedLayoutOption:null,rect:c,hostRect:h,priority:h?h.width*h.height:0,defaultAttr:{ignore:n.ignore,labelGuideIgnore:p&&p.ignore,x:ue.x,y:ue.y,scaleX:ue.scaleX,scaleY:ue.scaleY,rotation:ue.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");(K(n)||Ut(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,_){return function(){wp(S,_)}}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;K(o.layoutOption)?c=o.layoutOption(uz(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 h=!1;if(c.x!=null?(s.x=H(c.x,t),s.setStyle("x",0),h=!0):(s.x=u.x,s.setStyle("x",u.style.x)),c.y!=null?(s.y=H(c.y,a),s.setStyle("y",0),h=!0):(s.y=u.y,s.setStyle("y",u.style.y)),c.labelLinePoints){var f=l.getTextGuideLine();f&&(f.setShape({points:c.labelLinePoints}),h=!1)}var p=tc(s);p.needsUpdateLabelLine=h,s.rotation=c.rotate!=null?c.rotate*v:u.rotation,s.scaleX=u.scaleX,s.scaleY=u.scaleY;for(var d=0;d<xm.length;d++){var g=xm[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=US(this._labelList),i=_t(n,function(l){return l.layoutOption.moveOverlap==="shiftX"}),o=_t(n,function(l){return l.layoutOption.moveOverlap==="shiftY"});VD(i,0,t),ZS(o,0,a);var s=_t(n,function(l){return l.layoutOption.hideOverlap});$S(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=tc(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");Zv(e,$v(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&&!tn(e))){var i=tc(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 h=e.prevStates;h&&(ct(h,"select")>=0&&a.attr(i.oldLayoutSelect),ct(h,"emphasis")>=0&&a.attr(i.oldLayoutEmphasis)),ft(a,u,t,l)}else if(a.attr(u),!An(a).valueAnimation){var v=pt(a.style.opacity,1);a.style.opacity=0,Pt(a,{style:{opacity:v}},t,l)}if(i.oldLayout=u,a.states.select){var f=i.oldLayoutSelect={};Zo(f,u,$o),Zo(f,a.states.select,$o)}if(a.states.emphasis){var p=i.oldLayoutEmphasis={};Zo(p,u,$o),Zo(p,a.states.emphasis,$o)}S0(a,l,c,t,t)}if(n&&!n.ignore&&!n.invisible){var i=cz(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,Pt(n,{style:{strokePercent:1}},t)),i.oldLayout=d}},r})(),ec=ut();function hz(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){var n=ec(t).labelManager;n||(n=ec(t).labelManager=new vz),n.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(e,t,a){var n=ec(t).labelManager;a.updatedSeries.forEach(function(i){n.addLabelsOfSeries(t.getViewOfSeriesModel(i))}),n.updateLayoutConfig(t),n.layout(t),n.processLabelsOverall()})}function bm(r){return B(r[0])}function wm(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 fz={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=Hb(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=wn("update",a,n);if(!(o&&o.duration>0))return;var s=a.getModel("universalTransition").get("delay"),l=Object.assign({setToFinal:!0},o),u,c;bm(r)&&(u=r,c=e),bm(e)&&(u=e,c=r);function v(y,m,S,_,x){var b=y.many,A=y.one;if(b.length===1&&!x){var T=m?b[0]:A,D=m?A:b[0];if(Bb(T))v({many:[T],one:D},!0,S,_,!0);else{var C=s?Q({delay:s(S,_)},l):l;zb(T,D,C),i(T,D,T,D,C)}}else for(var M=Q({dividePath:fz[t],individualDelay:s&&function(O,N,V,F){return s(O+S,_)}},l),I=m?Gb(b,A,M):Fb(A,b,M),L=I.fromIndividuals,R=I.toIndividuals,P=L.length,k=0;k<P;k++){var C=s?Q({delay:s(k,P)},l):l;i(L[k],R[k],m?b[k]:y.one,m?y.one:b[k],C)}}for(var h=u?u===r:r.length>e.length,f=u?wm(c,u):wm(h?e:r,[h?r:e]),p=0,d=0;d<f.length;d++)p+=f[d].many.length;for(var g=0,d=0;d<f.length;d++)v(f[d],h,g,p),g+=f[d].many.length}function aa(r){if(!r)return[];if(B(r)){for(var e=[],t=0;t<r.length;t++)e.push(aa(r[t]));return e}var a=[];return r.traverse(function(n){n instanceof Mt&&!n.disableMorphing&&!n.invisible&&!n.ignore&&a.push(n)}),a}var Q1=1e4,pz=0,Am=1,Tm=2,dz=ut();function gz(r,e){for(var t=r.dimensions,a=0;a<t.length;a++){var n=r.getDimensionInfo(t[a]);if(n&&n.otherDims[e]===0)return t[a]}}function yz(r,e,t){var a=r.getDimensionInfo(t),n=a&&a.ordinalMeta;if(a){var i=r.get(a.name,e);return n&&n.categories[i]||i+""}}function Dm(r,e,t,a){var n=a?"itemChildGroupId":"itemGroupId",i=gz(r,n);if(i){var o=yz(r,e,i);return o}var s=r.getRawDataItem(e),l=a?"childGroupId":"groupId";if(s&&s[l])return s[l]+"";if(!a)return t||r.getId(e)}function Cm(r){var e=[];return w(r,function(t){var a=t.data,n=t.dataGroupId;if(!(a.count()>Q1))for(var i=a.getIndices(),o=0;o<i.length;o++)e.push({data:a,groupId:Dm(a,o,n,!1),childGroupId:Dm(a,o,n,!0),divide:t.divide,dataIndex:o})}),e}function ac(r,e,t){r.traverse(function(a){a instanceof Mt&&Pt(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 Ka(r){r.stopAnimation(),r.isGroup&&r.traverse(function(e){e.stopAnimation()})}function mz(r,e,t){var a=wn("update",t,e);a&&r.traverse(function(n){if(n instanceof ma){var i=Gw(n);i&&n.animateFrom({style:i},a)}})}function Sz(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 tb(r,e,t){var a=Cm(r),n=Cm(e);function i(S,_,x,b,A){(x||S)&&_.animateFrom({style:x&&x!==S?z(z({},x.style),S.style):S.style},A)}var o=!1,s=pz,l=$(),u=$();a.forEach(function(S){S.groupId&&l.set(S.groupId,!0),S.childGroupId&&u.set(S.childGroupId,!0)});for(var c=0;c<n.length;c++){var v=n[c].groupId;if(u.get(v)){s=Am;break}var h=n[c].childGroupId;if(h&&l.get(h)){s=Tm;break}}function f(S,_){return function(x){var b=x.data,A=x.dataIndex;return _?b.getId(A):S?s===Am?x.childGroupId:x.groupId:s===Tm?x.childGroupId:x.groupId}}var p=Sz(a,n),d={};if(!p)for(var c=0;c<n.length;c++){var g=n[c],y=g.data.getItemGraphicEl(g.dataIndex);y&&(d[y.id]=!0)}function m(S,_){var x=a[_],b=n[S],A=b.data.hostModel,T=x.data.getItemGraphicEl(x.dataIndex),D=b.data.getItemGraphicEl(b.dataIndex);if(T===D){D&&mz(D,b.dataIndex,A);return}T&&d[T.id]||D&&(Ka(D),T?(Ka(T),nc(T),o=!0,rc(aa(T),aa(D),b.divide,A,S,i)):ac(D,A,S))}new dr(a,n,f(!0,p),f(!1,p),null,"multiple").update(m).updateManyToOne(function(S,_){var x=n[S],b=x.data,A=b.hostModel,T=b.getItemGraphicEl(x.dataIndex),D=_t(G(_,function(C){return a[C].data.getItemGraphicEl(a[C].dataIndex)}),function(C){return C&&C!==T&&!d[C.id]});T&&(Ka(T),D.length?(w(D,function(C){Ka(C),nc(C)}),o=!0,rc(aa(D),aa(T),x.divide,A,S,i)):ac(T,A,x.dataIndex))}).updateOneToMany(function(S,_){var x=a[_],b=x.data.getItemGraphicEl(x.dataIndex);if(!(b&&d[b.id])){var A=_t(G(S,function(D){return n[D].data.getItemGraphicEl(n[D].dataIndex)}),function(D){return D&&D!==b}),T=n[S[0]].data.hostModel;A.length&&(w(A,function(D){return Ka(D)}),b?(Ka(b),nc(b),o=!0,rc(aa(b),aa(A),x.divide,T,S[0],i)):w(A,function(D){return ac(D,T,S[0])}))}}).updateManyToMany(function(S,_){new dr(_,S,function(x){return a[x].data.getId(a[x].dataIndex)},function(x){return n[x].data.getId(n[x].dataIndex)}).update(function(x,b){m(S[x],_[b])}).execute()}).execute(),o&&w(e,function(S){var _=S.data,x=_.hostModel,b=x&&t.getViewOfSeriesModel(x),A=wn("update",x,0);b&&x.isAnimationEnabled()&&A&&A.duration>0&&b.group.traverse(function(T){T instanceof Mt&&!T.animators.length&&T.animateFrom({style:{opacity:0}},A)})})}function Mm(r){var e=r.getModel("universalTransition").get("seriesKey");return e||r.id}function Im(r){return B(r)?r.sort().join(","):r}function Lr(r){if(r.hostModel)return r.hostModel.getModel("universalTransition").get("divideShape")}function _z(r,e){var t=$(),a=$(),n=$();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}),B(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:Lr(c.data),data:c.data}],newSeries:[{dataGroupId:o,divide:Lr(s),data:s}]});else if(B(l)){var v=[];w(l,function(p){var d=a.get(p);d.data&&v.push({dataGroupId:d.dataGroupId,divide:Lr(d.data),data:d.data})}),v.length&&t.set(u,{oldSeries:v,newSeries:[{dataGroupId:o,data:s,divide:Lr(s)}]})}else{var h=n.get(l);if(h){var f=t.get(h.key);f||(f={oldSeries:[{dataGroupId:h.dataGroupId,data:h.data,divide:Lr(h.data)}],newSeries:[]},t.set(h.key,f)),f.newSeries.push({dataGroupId:o,data:s,divide:Lr(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 xz(r,e,t,a){var n=[],i=[];w(xt(r.from),function(o){var s=Lm(e.oldSeries,o);s>=0&&n.push({dataGroupId:e.oldDataGroupIds[s],data:e.oldData[s],divide:Lr(e.oldData[s]),groupIdDim:o.dimension})}),w(xt(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:Lr(l),groupIdDim:o.dimension})}}),n.length>0&&i.length>0&&tb(n,i,a)}function bz(r){r.registerUpdateLifecycle("series:beforeupdate",function(e,t,a){w(xt(a.seriesTransition),function(n){w(xt(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][es]=!0)})})}),r.registerUpdateLifecycle("series:transition",function(e,t,a){var n=dz(t);if(n.oldSeries&&a.updatedSeries&&a.optionChanged){var i=a.seriesTransition;if(i)w(xt(i),function(f){xz(f,n,a,t)});else{var o=_z(n,a);w(o.keys(),function(f){var p=o.get(f);tb(p.oldSeries,p.newSeries,t)})}w(a.updatedSeries,function(f){f[es]&&(f[es]=!1)})}for(var s=e.getSeries(),l=n.oldSeries=[],u=n.oldDataGroupIds=[],c=n.oldData=[],v=0;v<s.length;v++){var h=s[v].getData();h.count()<Q1&&(l.push(s[v]),u.push(s[v].get("dataGroupId")),c.push(h))}})}function wz(r){r.registerPainter("svg",Wb)}function Az(r){r.registerPainter("canvas",Ub)}it([Az]);it([wz]);it([lD,CD,ZD,mI,II,vL,zL,bP,UP,qP,i2,Q2,AR,NR,jR,eE,vE,mE,IE,NE,YE,Mk]);it($k);it(SN);it(rx);it(RN);it(Fx);it(ON);it(YN);it(RO);it(jO);it(uo);it(pV);it(yV);it(CV);it(kV);it(GV);it(ZV);it(rB);it(_B);it(U1);it(Y1);it(GB);it(q1);it(j1);it(YB);it(nz);it(sz);it(bz);it(hz);export{hz as A,bz as B,rB as a,yV as b,jO as c,$k as d,SN as e,YB as f,Fx as g,CD as h,Cz as i,i2 as j,lD as k,ZD as l,vL as m,II as n,IE as o,MI as p,RO as q,_B as r,GB as s,Yv as t,it as u,CV as v,ON as w,YN as x,mI as y,Az as z};