-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathhtmltpl.go
120 lines (118 loc) · 386 KB
/
htmltpl.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
package main
const tpl = `<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title> </title>
<style>
html, body, #main {
width: 100%%;
height: 100%%;
margin: 0;
padding: 0;
}
</style>
<script>
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(this,function(t){"use strict";function e(t){var e={},n={},i=t.match(/Firefox\/([\d.]+)/),r=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),a=t.match(/Edge\/([\d.]+)/),o=/micromessenger/i.test(t);return i&&(n.firefox=!0,n.version=i[1]),r&&(n.ie=!0,n.version=r[1]),a&&(n.edge=!0,n.version=a[1]),o&&(n.weChat=!0),{browser:n,os:e,node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!n.ie&&!n.edge,pointerEventsSupported:"onpointerdown"in window&&(n.edge||n.ie&&n.version>=11)}}function n(t,e){"createCanvas"===t&&(Rp=null),Op[t]=e}function i(t){if(null==t||"object"!=typeof t)return t;var e=t,n=Ip.call(t);if("[object Array]"===n){if(!z(t)){e=[];for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}else if(Tp[n]){if(!z(t)){var o=t.constructor;if(t.constructor.from)e=o.from(t);else{e=new o(t.length);for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}}else if(!Mp[n]&&!z(t)&&!I(t)){e={};for(var s in t)t.hasOwnProperty(s)&&(e[s]=i(t[s]))}return e}function r(t,e,n){if(!S(e)||!S(t))return n?i(e):t;for(var a in e)if(e.hasOwnProperty(a)){var o=t[a],s=e[a];!S(s)||!S(o)||x(s)||x(o)||I(s)||I(o)||M(s)||M(o)||z(s)||z(o)?!n&&a in t||(t[a]=i(e[a],!0)):r(o,s,n)}return t}function a(t,e){for(var n=t[0],i=1,a=t.length;a>i;i++)n=r(n,t[i],e);return n}function o(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function s(t,e,n){for(var i in e)e.hasOwnProperty(i)&&(n?null!=e[i]:null==t[i])&&(t[i]=e[i]);return t}function l(){return Rp||(Rp=Ep().getContext("2d")),Rp}function u(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;i>n;n++)if(t[n]===e)return n}return-1}function h(t,e){function n(){}var i=t.prototype;n.prototype=e.prototype,t.prototype=new n;for(var r in i)t.prototype[r]=i[r];t.prototype.constructor=t,t.superClass=e}function c(t,e,n){t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,s(t,e,n)}function d(t){return t?"string"==typeof t?!1:"number"==typeof t.length:void 0}function f(t,e,n){if(t&&e)if(t.forEach&&t.forEach===Dp)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;r>i;i++)e.call(n,t[i],i,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(n,t[a],a,t)}function p(t,e,n){if(t&&e){if(t.map&&t.map===Pp)return t.map(e,n);for(var i=[],r=0,a=t.length;a>r;r++)i.push(e.call(n,t[r],r,t));return i}}function g(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===Lp)return t.reduce(e,n,i);for(var r=0,a=t.length;a>r;r++)n=e.call(i,n,t[r],r,t);return n}}function v(t,e,n){if(t&&e){if(t.filter&&t.filter===Ap)return t.filter(e,n);for(var i=[],r=0,a=t.length;a>r;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function m(t,e,n){if(t&&e)for(var i=0,r=t.length;r>i;i++)if(e.call(n,t[i],i,t))return t[i]}function y(t,e){var n=kp.call(arguments,2);return function(){return t.apply(e,n.concat(kp.call(arguments)))}}function _(t){var e=kp.call(arguments,1);return function(){return t.apply(this,e.concat(kp.call(arguments)))}}function x(t){return"[object Array]"===Ip.call(t)}function w(t){return"function"==typeof t}function b(t){return"[object String]"===Ip.call(t)}function S(t){var e=typeof t;return"function"===e||!!t&&"object"==e}function M(t){return!!Mp[Ip.call(t)]}function T(t){return!!Tp[Ip.call(t)]}function I(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function C(t){return t!==t}function D(){for(var t=0,e=arguments.length;e>t;t++)if(null!=arguments[t])return arguments[t]}function A(t,e){return null!=t?t:e}function k(t,e,n){return null!=t?t:null!=e?e:n}function P(){return Function.call.apply(kp,arguments)}function L(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function O(t,e){if(!t)throw new Error(e)}function E(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}function R(t){t[zp]=!0}function z(t){return t[zp]}function B(t){function e(t,e){n?i.set(t,e):i.set(e,t)}var n=x(t),i=this;t instanceof B?t.each(e):t&&f(t,e)}function N(t){return new B(t)}function V(t,e){for(var n=new t.constructor(t.length+e.length),i=0;i<t.length;i++)n[i]=t[i];var r=t.length;for(i=0;i<e.length;i++)n[i+r]=e[i];return n}function F(){}function H(t,e){var n=new Np(2);return null==t&&(t=0),null==e&&(e=0),n[0]=t,n[1]=e,n}function W(t,e){return t[0]=e[0],t[1]=e[1],t}function G(t){var e=new Np(2);return e[0]=t[0],e[1]=t[1],e}function j(t,e,n){return t[0]=e,t[1]=n,t}function U(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function Z(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function X(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function Y(t){return Math.sqrt(q(t))}function q(t){return t[0]*t[0]+t[1]*t[1]}function $(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t}function K(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t}function Q(t,e){return t[0]*e[0]+t[1]*e[1]}function J(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function te(t,e){var n=Y(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function ee(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}function ne(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}function ie(t,e){return t[0]=-e[0],t[1]=-e[1],t}function re(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t}function ae(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}function oe(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function se(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}function le(){this.on("mousedown",this._dragStart,this),this.on("mousemove",this._drag,this),this.on("mouseup",this._dragEnd,this),this.on("globalout",this._dragEnd,this)}function ue(t,e){return{target:t,topTarget:e&&e.topTarget}}function he(t,e,n){return{type:t,event:n,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which}}function ce(){}function de(t,e,n){if(t[t.rectHover?"rectContain":"contain"](e,n)){for(var i,r=t;r;){if(r.clipPath&&!r.clipPath.contain(e,n))return!1;r.silent&&(i=!0),r=r.parent}return i?Zp:!0}return!1}function fe(){var t=new qp(6);return pe(t),t}function pe(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function ge(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t}function ve(t,e,n){var i=e[0]*n[0]+e[2]*n[1],r=e[1]*n[0]+e[3]*n[1],a=e[0]*n[2]+e[2]*n[3],o=e[1]*n[2]+e[3]*n[3],s=e[0]*n[4]+e[2]*n[5]+e[4],l=e[1]*n[4]+e[3]*n[5]+e[5];return t[0]=i,t[1]=r,t[2]=a,t[3]=o,t[4]=s,t[5]=l,t}function me(t,e,n){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+n[0],t[5]=e[5]+n[1],t}function ye(t,e,n){var i=e[0],r=e[2],a=e[4],o=e[1],s=e[3],l=e[5],u=Math.sin(n),h=Math.cos(n);return t[0]=i*h+o*u,t[1]=-i*u+o*h,t[2]=r*h+s*u,t[3]=-r*u+h*s,t[4]=h*a+u*l,t[5]=h*l-u*a,t}function _e(t,e,n){var i=n[0],r=n[1];return t[0]=e[0]*i,t[1]=e[1]*r,t[2]=e[2]*i,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*r,t}function xe(t,e){var n=e[0],i=e[2],r=e[4],a=e[1],o=e[3],s=e[5],l=n*o-a*i;return l?(l=1/l,t[0]=o*l,t[1]=-a*l,t[2]=-i*l,t[3]=n*l,t[4]=(i*s-o*r)*l,t[5]=(a*r-n*s)*l,t):null}function we(t){var e=fe();return ge(e,t),e}function be(t){return t>Qp||-Qp>t}function Se(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null==t.loop?!1:t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}function Me(t){return t=Math.round(t),0>t?0:t>255?255:t}function Te(t){return t=Math.round(t),0>t?0:t>360?360:t}function Ie(t){return 0>t?0:t>1?1:t}function Ce(t){return Me(t.length&&"%%"===t.charAt(t.length-1)?parseFloat(t)/100*255:parseInt(t,10))}function De(t){return Ie(t.length&&"%%"===t.charAt(t.length-1)?parseFloat(t)/100:parseFloat(t))}function Ae(t,e,n){return 0>n?n+=1:n>1&&(n-=1),1>6*n?t+(e-t)*n*6:1>2*n?e:2>3*n?t+(e-t)*(2/3-n)*6:t}function ke(t,e,n){return t+(e-t)*n}function Pe(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Le(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function Oe(t,e){hg&&Le(hg,e),hg=ug.put(t,hg||e.slice())}function Ee(t,e){if(t){e=e||[];var n=ug.get(t);if(n)return Le(e,n);t+="";var i=t.replace(/ /g,"").toLowerCase();if(i in lg)return Le(e,lg[i]),Oe(t,e),e;if("#"!==i.charAt(0)){var r=i.indexOf("("),a=i.indexOf(")");if(-1!==r&&a+1===i.length){var o=i.substr(0,r),s=i.substr(r+1,a-(r+1)).split(","),l=1;switch(o){case"rgba":if(4!==s.length)return void Pe(e,0,0,0,1);l=De(s.pop());case"rgb":return 3!==s.length?void Pe(e,0,0,0,1):(Pe(e,Ce(s[0]),Ce(s[1]),Ce(s[2]),l),Oe(t,e),e);case"hsla":return 4!==s.length?void Pe(e,0,0,0,1):(s[3]=De(s[3]),Re(s,e),Oe(t,e),e);case"hsl":return 3!==s.length?void Pe(e,0,0,0,1):(Re(s,e),Oe(t,e),e);default:return}}Pe(e,0,0,0,1)}else{if(4===i.length){var u=parseInt(i.substr(1),16);return u>=0&&4095>=u?(Pe(e,(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,1),Oe(t,e),e):void Pe(e,0,0,0,1)}if(7===i.length){var u=parseInt(i.substr(1),16);return u>=0&&16777215>=u?(Pe(e,(16711680&u)>>16,(65280&u)>>8,255&u,1),Oe(t,e),e):void Pe(e,0,0,0,1)}}}}function Re(t,e){var n=(parseFloat(t[0])%%360+360)%%360/360,i=De(t[1]),r=De(t[2]),a=.5>=r?r*(i+1):r+i-r*i,o=2*r-a;return e=e||[],Pe(e,Me(255*Ae(o,a,n+1/3)),Me(255*Ae(o,a,n)),Me(255*Ae(o,a,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function ze(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,u=(s+o)/2;if(0===l)e=0,n=0;else{n=.5>u?l/(s+o):l/(2-s-o);var h=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-c:r===s?e=1/3+h-d:a===s&&(e=2/3+c-h),0>e&&(e+=1),e>1&&(e-=1)}var f=[360*e,n,u];return null!=t[3]&&f.push(t[3]),f}}function Be(t,e){var n=Ee(t);if(n){for(var i=0;3>i;i++)n[i]=0>e?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0;return Ge(n,4===n.length?"rgba":"rgb")}}function Ne(t){var e=Ee(t);return e?((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1):void 0}function Ve(t,e,n){if(e&&e.length&&t>=0&&1>=t){n=n||[];var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=e[r],s=e[a],l=i-r;return n[0]=Me(ke(o[0],s[0],l)),n[1]=Me(ke(o[1],s[1],l)),n[2]=Me(ke(o[2],s[2],l)),n[3]=Ie(ke(o[3],s[3],l)),n}}function Fe(t,e,n){if(e&&e.length&&t>=0&&1>=t){var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=Ee(e[r]),s=Ee(e[a]),l=i-r,u=Ge([Me(ke(o[0],s[0],l)),Me(ke(o[1],s[1],l)),Me(ke(o[2],s[2],l)),Ie(ke(o[3],s[3],l))],"rgba");return n?{color:u,leftIndex:r,rightIndex:a,value:i}:u}}function He(t,e,n,i){return t=Ee(t),t?(t=ze(t),null!=e&&(t[0]=Te(e)),null!=n&&(t[1]=De(n)),null!=i&&(t[2]=De(i)),Ge(Re(t),"rgba")):void 0}function We(t,e){return t=Ee(t),t&&null!=e?(t[3]=Ie(e),Ge(t,"rgba")):void 0}function Ge(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return("rgba"===e||"hsva"===e||"hsla"===e)&&(n+=","+t[3]),e+"("+n+")"}}function je(t,e){return t[e]}function Ue(t,e,n){t[e]=n}function Ze(t,e,n){return(e-t)*n+t}function Xe(t,e,n){return n>.5?e:t}function Ye(t,e,n,i,r){var a=t.length;if(1==r)for(var o=0;a>o;o++)i[o]=Ze(t[o],e[o],n);else for(var s=a&&t[0].length,o=0;a>o;o++)for(var l=0;s>l;l++)i[o][l]=Ze(t[o][l],e[o][l],n)}function qe(t,e,n){var i=t.length,r=e.length;if(i!==r){var a=i>r;if(a)t.length=r;else for(var o=i;r>o;o++)t.push(1===n?e[o]:pg.call(e[o]))}for(var s=t[0]&&t[0].length,o=0;o<t.length;o++)if(1===n)isNaN(t[o])&&(t[o]=e[o]);else for(var l=0;s>l;l++)isNaN(t[o][l])&&(t[o][l]=e[o][l])}function $e(t,e,n){if(t===e)return!0;var i=t.length;if(i!==e.length)return!1;if(1===n){for(var r=0;i>r;r++)if(t[r]!==e[r])return!1}else for(var a=t[0].length,r=0;i>r;r++)for(var o=0;a>o;o++)if(t[r][o]!==e[r][o])return!1;return!0}function Ke(t,e,n,i,r,a,o,s,l){var u=t.length;if(1==l)for(var h=0;u>h;h++)s[h]=Qe(t[h],e[h],n[h],i[h],r,a,o);else for(var c=t[0].length,h=0;u>h;h++)for(var d=0;c>d;d++)s[h][d]=Qe(t[h][d],e[h][d],n[h][d],i[h][d],r,a,o)}function Qe(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Je(t){if(d(t)){var e=t.length;if(d(t[0])){for(var n=[],i=0;e>i;i++)n.push(pg.call(t[i]));return n}return pg.call(t)}return t}function tn(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function en(t){var e=t[t.length-1].value;return d(e&&e[0])?2:1}function nn(t,e,n,i,r,a){var o=t._getter,s=t._setter,l="spline"===e,u=i.length;if(u){var h,c=i[0].value,f=d(c),p=!1,g=!1,v=f?en(i):0;i.sort(function(t,e){return t.time-e.time}),h=i[u-1].time;for(var m=[],y=[],_=i[0].value,x=!0,w=0;u>w;w++){m.push(i[w].time/h);var b=i[w].value;if(f&&$e(b,_,v)||!f&&b===_||(x=!1),_=b,"string"==typeof b){var S=Ee(b);S?(b=S,p=!0):g=!0}y.push(b)}if(a||!x){for(var M=y[u-1],w=0;u-1>w;w++)f?qe(y[w],M,v):!isNaN(y[w])||isNaN(M)||g||p||(y[w]=M);f&&qe(o(t._target,r),M,v);var T,I,C,D,A,k,P=0,L=0;if(p)var O=[0,0,0,0];var E=function(t,e){var n;if(0>e)n=0;else if(L>e){for(T=Math.min(P+1,u-1),n=T;n>=0&&!(m[n]<=e);n--);n=Math.min(n,u-2)}else{for(n=P;u>n&&!(m[n]>e);n++);n=Math.min(n-1,u-2)}P=n,L=e;var i=m[n+1]-m[n];if(0!==i)if(I=(e-m[n])/i,l)if(D=y[n],C=y[0===n?n:n-1],A=y[n>u-2?u-1:n+1],k=y[n>u-3?u-1:n+2],f)Ke(C,D,A,k,I,I*I,I*I*I,o(t,r),v);else{var a;if(p)a=Ke(C,D,A,k,I,I*I,I*I*I,O,1),a=tn(O);else{if(g)return Xe(D,A,I);a=Qe(C,D,A,k,I,I*I,I*I*I)}s(t,r,a)}else if(f)Ye(y[n],y[n+1],I,o(t,r),v);else{var a;if(p)Ye(y[n],y[n+1],I,O,1),a=tn(O);else{if(g)return Xe(y[n],y[n+1],I);a=Ze(y[n],y[n+1],I)}s(t,r,a)}},R=new Se({target:t._target,life:h,loop:t._loop,delay:t._delay,onframe:E,ondestroy:n});return e&&"spline"!==e&&(R.easing=e),R}}}function rn(t,e,n,i){0>n&&(t+=n,n=-n),0>i&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}function an(t){for(var e=0;t>=Cg;)e|=1&t,t>>=1;return t+e}function on(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){for(;n>r&&i(t[r],t[r-1])<0;)r++;sn(t,e,r)}else for(;n>r&&i(t[r],t[r-1])>=0;)r++;return r-e}function sn(t,e,n){for(n--;n>e;){var i=t[e];t[e++]=t[n],t[n--]=i}}function ln(t,e,n,i,r){for(i===e&&i++;n>i;i++){for(var a,o=t[i],s=e,l=i;l>s;)a=s+l>>>1,r(o,t[a])<0?l=a:s=a+1;var u=i-s;switch(u){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;u>0;)t[s+u]=t[s+u-1],u--}t[s]=o}}function un(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])>0){for(s=i-r;s>l&&a(t,e[n+r+l])>0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s),o+=r,l+=r}else{for(s=r+1;s>l&&a(t,e[n+r-l])<=0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s);var u=o;o=r-l,l=r-u}for(o++;l>o;){var h=o+(l-o>>>1);a(t,e[n+h])>0?o=h+1:l=h}return l}function hn(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])<0){for(s=r+1;s>l&&a(t,e[n+r-l])<0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s);var u=o;o=r-l,l=r-u}else{for(s=i-r;s>l&&a(t,e[n+r+l])>=0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s),o+=r,l+=r}for(o++;l>o;){var h=o+(l-o>>>1);a(t,e[n+h])<0?l=h:o=h+1}return l}function cn(t,e){function n(t,e){l[c]=t,u[c]=e,c+=1}function i(){for(;c>1;){var t=c-2;if(t>=1&&u[t-1]<=u[t]+u[t+1]||t>=2&&u[t-2]<=u[t]+u[t-1])u[t-1]<u[t+1]&&t--;else if(u[t]>u[t+1])break;a(t)}}function r(){for(;c>1;){var t=c-2;t>0&&u[t-1]<u[t+1]&&t--,a(t)}}function a(n){var i=l[n],r=u[n],a=l[n+1],h=u[n+1];u[n]=r+h,n===c-3&&(l[n+1]=l[n+2],u[n+1]=u[n+2]),c--;var d=hn(t[a],t,i,r,0,e);i+=d,r-=d,0!==r&&(h=un(t[i+r-1],t,a,h,h-1,e),0!==h&&(h>=r?o(i,r,a,h):s(i,r,a,h)))}function o(n,i,r,a){var o=0;for(o=0;i>o;o++)d[o]=t[n+o];var s=0,l=r,u=n;if(t[u++]=t[l++],0!==--a){if(1===i){for(o=0;a>o;o++)t[u+o]=t[l+o];return void(t[u+a]=d[s])}for(var c,f,p,g=h;;){c=0,f=0,p=!1;do if(e(t[l],d[s])<0){if(t[u++]=t[l++],f++,c=0,0===--a){p=!0;break}}else if(t[u++]=d[s++],c++,f=0,1===--i){p=!0;break}while(g>(c|f));if(p)break;do{if(c=hn(t[l],d,s,i,0,e),0!==c){for(o=0;c>o;o++)t[u+o]=d[s+o];if(u+=c,s+=c,i-=c,1>=i){p=!0;break}}if(t[u++]=t[l++],0===--a){p=!0;break}if(f=un(d[s],t,l,a,0,e),0!==f){for(o=0;f>o;o++)t[u+o]=t[l+o];if(u+=f,l+=f,a-=f,0===a){p=!0;break}}if(t[u++]=d[s++],1===--i){p=!0;break}g--}while(c>=Dg||f>=Dg);if(p)break;0>g&&(g=0),g+=2}if(h=g,1>h&&(h=1),1===i){for(o=0;a>o;o++)t[u+o]=t[l+o];t[u+a]=d[s]}else{if(0===i)throw new Error;for(o=0;i>o;o++)t[u+o]=d[s+o]}}else for(o=0;i>o;o++)t[u+o]=d[s+o]}function s(n,i,r,a){var o=0;for(o=0;a>o;o++)d[o]=t[r+o];var s=n+i-1,l=a-1,u=r+a-1,c=0,f=0;if(t[u--]=t[s--],0!==--i){if(1===a){for(u-=i,s-=i,f=u+1,c=s+1,o=i-1;o>=0;o--)t[f+o]=t[c+o];return void(t[u]=d[l])}for(var p=h;;){var g=0,v=0,m=!1;do if(e(d[l],t[s])<0){if(t[u--]=t[s--],g++,v=0,0===--i){m=!0;break}}else if(t[u--]=d[l--],v++,g=0,1===--a){m=!0;break}while(p>(g|v));if(m)break;do{if(g=i-hn(d[l],t,n,i,i-1,e),0!==g){for(u-=g,s-=g,i-=g,f=u+1,c=s+1,o=g-1;o>=0;o--)t[f+o]=t[c+o];if(0===i){m=!0;break}}if(t[u--]=d[l--],1===--a){m=!0;break}if(v=a-un(t[s],d,0,a,a-1,e),0!==v){for(u-=v,l-=v,a-=v,f=u+1,c=l+1,o=0;v>o;o++)t[f+o]=d[c+o];if(1>=a){m=!0;break}}if(t[u--]=t[s--],0===--i){m=!0;break}p--}while(g>=Dg||v>=Dg);if(m)break;0>p&&(p=0),p+=2}if(h=p,1>h&&(h=1),1===a){for(u-=i,s-=i,f=u+1,c=s+1,o=i-1;o>=0;o--)t[f+o]=t[c+o];t[u]=d[l]}else{if(0===a)throw new Error;for(c=u-(a-1),o=0;a>o;o++)t[c+o]=d[o]}}else for(c=u-(a-1),o=0;a>o;o++)t[c+o]=d[o]}var l,u,h=Dg,c=0,d=[];l=[],u=[],this.mergeRuns=i,this.forceMergeRuns=r,this.pushRun=n}function dn(t,e,n,i){n||(n=0),i||(i=t.length);var r=i-n;if(!(2>r)){var a=0;if(Cg>r)return a=on(t,n,i,e),void ln(t,n,i,n+a,e);var o=new cn(t,e),s=an(r);do{if(a=on(t,n,i,e),s>a){var l=r;l>s&&(l=s),ln(t,n,n+l,n+a,e),a=l}o.pushRun(n,a),o.mergeRuns(),r-=a,n+=a}while(0!==r);o.forceMergeRuns()}}function fn(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function pn(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,a=null==e.y?0:e.y,o=null==e.y2?0:e.y2;e.global||(i=i*n.width+n.x,r=r*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y);var s=t.createLinearGradient(i,a,r,o);return s}function gn(t,e,n){var i=n.width,r=n.height,a=Math.min(i,r),o=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;e.global||(o=o*i+n.x,s=s*r+n.y,l*=a);var u=t.createRadialGradient(o,s,0,o,s,l);return u}function vn(){return!1}function mn(t,e,n){var i=Ep(),r=e.getWidth(),a=e.getHeight(),o=i.style;return o&&(o.position="absolute",o.left=0,o.top=0,o.width=r+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",t)),i.width=r*n,i.height=a*n,i}function yn(t){if("string"==typeof t){var e=Fg.get(t);return e&&e.image}return t}function _n(t,e,n,i,r){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!n)return e;var a=Fg.get(t),o={hostEl:n,cb:i,cbPayload:r};return a?(e=a.image,!wn(e)&&a.pending.push(o)):(!e&&(e=new Image),e.onload=xn,Fg.put(t,e.__cachedImgObj={image:e,pending:[o]}),e.src=e.__zrImageSrc=t),e}return t}return e}function xn(){var t=this.__cachedImgObj;this.onload=this.__cachedImgObj=null;for(var e=0;e<t.pending.length;e++){var n=t.pending[e],i=n.cb;i&&i(this,n.cbPayload),n.hostEl.dirty()}t.pending.length=0}function wn(t){return t&&t.width&&t.height}function bn(t,e){Zg[t]=e}function Sn(t,e){e=e||Ug;var n=t+":"+e;if(Hg[n])return Hg[n];for(var i=(t+"").split("\n"),r=0,a=0,o=i.length;o>a;a++)r=Math.max(Rn(i[a],e).width,r);return Wg>Gg&&(Wg=0,Hg={}),Wg++,Hg[n]=r,r}function Mn(t,e,n,i,r,a,o){return a?In(t,e,n,i,r,a,o):Tn(t,e,n,i,r,o)}function Tn(t,e,n,i,r,a){var o=zn(t,e,r,a),s=Sn(t,e);r&&(s+=r[1]+r[3]);var l=o.outerHeight,u=Cn(0,s,n),h=Dn(0,l,i),c=new rn(u,h,s,l);return c.lineHeight=o.lineHeight,c}function In(t,e,n,i,r,a,o){var s=Bn(t,{rich:a,truncate:o,font:e,textAlign:n,textPadding:r}),l=s.outerWidth,u=s.outerHeight,h=Cn(0,l,n),c=Dn(0,u,i);return new rn(h,c,l,u)}function Cn(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function Dn(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function An(t,e,n){var i=e.x,r=e.y,a=e.height,o=e.width,s=a/2,l="left",u="top";switch(t){case"left":i-=n,r+=s,l="right",u="middle";break;case"right":i+=n+o,r+=s,u="middle";break;case"top":i+=o/2,r-=n,l="center",u="bottom";break;case"bottom":i+=o/2,r+=a+n,l="center";break;case"inside":i+=o/2,r+=s,l="center",u="middle";break;case"insideLeft":i+=n,r+=s,u="middle";break;case"insideRight":i+=o-n,r+=s,l="right",u="middle";break;case"insideTop":i+=o/2,r+=n,l="center";break;case"insideBottom":i+=o/2,r+=a-n,l="center",u="bottom";break;case"insideTopLeft":i+=n,r+=n;break;case"insideTopRight":i+=o-n,r+=n,l="right";break;case"insideBottomLeft":i+=n,r+=a-n,u="bottom";break;case"insideBottomRight":i+=o-n,r+=a-n,l="right",u="bottom"}return{x:i,y:r,textAlign:l,textVerticalAlign:u}}function kn(t,e,n,i,r){if(!e)return"";var a=(t+"").split("\n");r=Pn(e,n,i,r);for(var o=0,s=a.length;s>o;o++)a[o]=Ln(a[o],r);return a.join("\n")}function Pn(t,e,n,i){i=o({},i),i.font=e;var n=A(n,"...");i.maxIterations=A(i.maxIterations,2);var r=i.minChar=A(i.minChar,0);i.cnCharWidth=Sn("国",e);var a=i.ascCharWidth=Sn("a",e);i.placeholder=A(i.placeholder,"");for(var s=t=Math.max(0,t-1),l=0;r>l&&s>=a;l++)s-=a;var u=Sn(n);return u>s&&(n="",u=0),s=t-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=s,i.containerWidth=t,i}function Ln(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var a=Sn(t,i);if(n>=a)return t;for(var o=0;;o++){if(r>=a||o>=e.maxIterations){t+=e.ellipsis;break}var s=0===o?On(t,r,e.ascCharWidth,e.cnCharWidth):a>0?Math.floor(t.length*r/a):0;t=t.substr(0,s),a=Sn(t,i)}return""===t&&(t=e.placeholder),t}function On(t,e,n,i){for(var r=0,a=0,o=t.length;o>a&&e>r;a++){var s=t.charCodeAt(a);r+=s>=0&&127>=s?n:i}return a}function En(t){return Sn("国",t)}function Rn(t,e){return Zg.measureText(t,e)}function zn(t,e,n,i){null!=t&&(t+="");var r=En(e),a=t?t.split("\n"):[],o=a.length*r,s=o;if(n&&(s+=n[0]+n[2]),t&&i){var l=i.outerHeight,u=i.outerWidth;if(null!=l&&s>l)t="",a=[];else if(null!=u)for(var h=Pn(u-(n?n[1]+n[3]:0),e,i.ellipsis,{minChar:i.minChar,placeholder:i.placeholder}),c=0,d=a.length;d>c;c++)a[c]=Ln(a[c],h)}return{lines:a,height:o,outerHeight:s,lineHeight:r}}function Bn(t,e){var n={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return n;for(var i,r=jg.lastIndex=0;null!=(i=jg.exec(t));){var a=i.index;a>r&&Nn(n,t.substring(r,a)),Nn(n,i[2],i[1]),r=jg.lastIndex}r<t.length&&Nn(n,t.substring(r,t.length));var o=n.lines,s=0,l=0,u=[],h=e.textPadding,c=e.truncate,d=c&&c.outerWidth,f=c&&c.outerHeight;h&&(null!=d&&(d-=h[1]+h[3]),null!=f&&(f-=h[0]+h[2]));for(var p=0;p<o.length;p++){for(var g=o[p],v=0,m=0,y=0;y<g.tokens.length;y++){var _=g.tokens[y],x=_.styleName&&e.rich[_.styleName]||{},w=_.textPadding=x.textPadding,b=_.font=x.font||e.font,S=_.textHeight=A(x.textHeight,En(b));if(w&&(S+=w[0]+w[2]),_.height=S,_.lineHeight=k(x.textLineHeight,e.textLineHeight,S),_.textAlign=x&&x.textAlign||e.textAlign,_.textVerticalAlign=x&&x.textVerticalAlign||"middle",null!=f&&s+_.lineHeight>f)return{lines:[],width:0,height:0};_.textWidth=Sn(_.text,b);var M=x.textWidth,T=null==M||"auto"===M;if("string"==typeof M&&"%%"===M.charAt(M.length-1))_.percentWidth=M,u.push(_),M=0;else{if(T){M=_.textWidth;var I=x.textBackgroundColor,C=I&&I.image;C&&(C=yn(C),wn(C)&&(M=Math.max(M,C.width*S/C.height)))}var D=w?w[1]+w[3]:0;M+=D;var P=null!=d?d-m:null;null!=P&&M>P&&(!T||D>P?(_.text="",_.textWidth=M=0):(_.text=kn(_.text,P-D,b,c.ellipsis,{minChar:c.minChar}),_.textWidth=Sn(_.text,b),M=_.textWidth+D))}m+=_.width=M,x&&(v=Math.max(v,_.lineHeight))}g.width=m,g.lineHeight=v,s+=v,l=Math.max(l,m)}n.outerWidth=n.width=A(e.textWidth,l),n.outerHeight=n.height=A(e.textHeight,s),h&&(n.outerWidth+=h[1]+h[3],n.outerHeight+=h[0]+h[2]);for(var p=0;p<u.length;p++){var _=u[p],L=_.percentWidth;_.width=parseInt(L,10)/100*l}return n}function Nn(t,e,n){for(var i=""===e,r=e.split("\n"),a=t.lines,o=0;o<r.length;o++){var s=r[o],l={styleName:n,text:s,isLineHolder:!s&&!i};if(o)a.push({tokens:[l]});else{var u=(a[a.length-1]||(a[0]={tokens:[]})).tokens,h=u.length;1===h&&u[0].isLineHolder?u[0]=l:(s||!h||i)&&u.push(l)}}}function Vn(t){var e=(t.fontSize||t.fontFamily)&&[t.fontStyle,t.fontWeight,(t.fontSize||12)+"px",t.fontFamily||"sans-serif"].join(" ");return e&&E(e)||t.textFont||t.font}function Fn(t,e){var n,i,r,a,o=e.x,s=e.y,l=e.width,u=e.height,h=e.r;0>l&&(o+=l,l=-l),0>u&&(s+=u,u=-u),"number"==typeof h?n=i=r=a=h:h instanceof Array?1===h.length?n=i=r=a=h[0]:2===h.length?(n=r=h[0],i=a=h[1]):3===h.length?(n=h[0],i=a=h[1],r=h[2]):(n=h[0],i=h[1],r=h[2],a=h[3]):n=i=r=a=0;var c;n+i>l&&(c=n+i,n*=l/c,i*=l/c),r+a>l&&(c=r+a,r*=l/c,a*=l/c),i+r>u&&(c=i+r,i*=u/c,r*=u/c),n+a>u&&(c=n+a,n*=u/c,a*=u/c),t.moveTo(o+n,s),t.lineTo(o+l-i,s),0!==i&&t.quadraticCurveTo(o+l,s,o+l,s+i),t.lineTo(o+l,s+u-r),0!==r&&t.quadraticCurveTo(o+l,s+u,o+l-r,s+u),t.lineTo(o+a,s+u),0!==a&&t.quadraticCurveTo(o,s+u,o,s+u-a),t.lineTo(o,s+n),0!==n&&t.quadraticCurveTo(o,s,o+n,s)}function Hn(t){return Wn(t),f(t.rich,Wn),t}function Wn(t){if(t){t.font=Vn(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||Xg[e]?e:"left";var n=t.textVerticalAlign||t.textBaseline;"center"===n&&(n="middle"),t.textVerticalAlign=null==n||Yg[n]?n:"top";var i=t.textPadding;i&&(t.textPadding=L(t.textPadding))}}function Gn(t,e,n,i,r){i.rich?Un(t,e,n,i,r):jn(t,e,n,i,r)}function jn(t,e,n,i,r){var a=Jn(e,"font",i.font||Ug),o=i.textPadding,s=t.__textCotentBlock;(!s||t.__dirty)&&(s=t.__textCotentBlock=zn(n,a,o,i.truncate));var l=s.outerHeight,u=s.lines,h=s.lineHeight,c=Qn(l,i,r),d=c.baseX,f=c.baseY,p=c.textAlign,g=c.textVerticalAlign;Xn(e,i,r,d,f);var v=Dn(f,l,g),m=d,y=v,_=qn(i);if(_||o){var x=Sn(n,a),w=x;o&&(w+=o[1]+o[3]);var b=Cn(d,w,p);_&&$n(t,e,i,b,v,w,l),o&&(m=ii(d,p,o),y+=o[0])}Jn(e,"textAlign",p||"left"),Jn(e,"textBaseline","middle"),Jn(e,"shadowBlur",i.textShadowBlur||0),Jn(e,"shadowColor",i.textShadowColor||"transparent"),Jn(e,"shadowOffsetX",i.textShadowOffsetX||0),Jn(e,"shadowOffsetY",i.textShadowOffsetY||0),y+=h/2;var S=i.textStrokeWidth,M=ti(i.textStroke,S),T=ei(i.textFill);M&&(Jn(e,"lineWidth",S),Jn(e,"strokeStyle",M)),T&&Jn(e,"fillStyle",T);for(var I=0;I<u.length;I++)M&&e.strokeText(u[I],m,y),T&&e.fillText(u[I],m,y),y+=h}function Un(t,e,n,i,r){var a=t.__textCotentBlock;(!a||t.__dirty)&&(a=t.__textCotentBlock=Bn(n,i)),Zn(t,e,a,i,r)}function Zn(t,e,n,i,r){var a=n.width,o=n.outerWidth,s=n.outerHeight,l=i.textPadding,u=Qn(s,i,r),h=u.baseX,c=u.baseY,d=u.textAlign,f=u.textVerticalAlign;Xn(e,i,r,h,c);var p=Cn(h,o,d),g=Dn(c,s,f),v=p,m=g;l&&(v+=l[3],m+=l[0]);var y=v+a;qn(i)&&$n(t,e,i,p,g,o,s);for(var _=0;_<n.lines.length;_++){for(var x,w=n.lines[_],b=w.tokens,S=b.length,M=w.lineHeight,T=w.width,I=0,C=v,D=y,A=S-1;S>I&&(x=b[I],!x.textAlign||"left"===x.textAlign);)Yn(t,e,x,i,M,m,C,"left"),T-=x.width,C+=x.width,I++;for(;A>=0&&(x=b[A],"right"===x.textAlign);)Yn(t,e,x,i,M,m,D,"right"),T-=x.width,D-=x.width,A--;for(C+=(a-(C-v)-(y-D)-T)/2;A>=I;)x=b[I],Yn(t,e,x,i,M,m,C+x.width/2,"center"),C+=x.width,I++;m+=M}}function Xn(t,e,n,i,r){if(n&&e.textRotation){var a=e.textOrigin;"center"===a?(i=n.width/2+n.x,r=n.height/2+n.y):a&&(i=a[0]+n.x,r=a[1]+n.y),t.translate(i,r),t.rotate(-e.textRotation),t.translate(-i,-r)}}function Yn(t,e,n,i,r,a,o,s){var l=i.rich[n.styleName]||{},u=n.textVerticalAlign,h=a+r/2;"top"===u?h=a+n.height/2:"bottom"===u&&(h=a+r-n.height/2),!n.isLineHolder&&qn(l)&&$n(t,e,l,"right"===s?o-n.width:"center"===s?o-n.width/2:o,h-n.height/2,n.width,n.height);var c=n.textPadding;c&&(o=ii(o,s,c),h-=n.height/2-c[2]-n.textHeight/2),Jn(e,"shadowBlur",k(l.textShadowBlur,i.textShadowBlur,0)),Jn(e,"shadowColor",l.textShadowColor||i.textShadowColor||"transparent"),Jn(e,"shadowOffsetX",k(l.textShadowOffsetX,i.textShadowOffsetX,0)),Jn(e,"shadowOffsetY",k(l.textShadowOffsetY,i.textShadowOffsetY,0)),Jn(e,"textAlign",s),Jn(e,"textBaseline","middle"),Jn(e,"font",n.font||Ug);var d=ti(l.textStroke||i.textStroke,p),f=ei(l.textFill||i.textFill),p=A(l.textStrokeWidth,i.textStrokeWidth);d&&(Jn(e,"lineWidth",p),Jn(e,"strokeStyle",d),e.strokeText(n.text,o,h)),f&&(Jn(e,"fillStyle",f),e.fillText(n.text,o,h))}function qn(t){return t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor}function $n(t,e,n,i,r,a,o){var s=n.textBackgroundColor,l=n.textBorderWidth,u=n.textBorderColor,h=b(s);if(Jn(e,"shadowBlur",n.textBoxShadowBlur||0),Jn(e,"shadowColor",n.textBoxShadowColor||"transparent"),Jn(e,"shadowOffsetX",n.textBoxShadowOffsetX||0),Jn(e,"shadowOffsetY",n.textBoxShadowOffsetY||0),h||l&&u){e.beginPath();var c=n.textBorderRadius;c?Fn(e,{x:i,y:r,width:a,height:o,r:c}):e.rect(i,r,a,o),e.closePath()}if(h)Jn(e,"fillStyle",s),e.fill();else if(S(s)){var d=s.image;d=_n(d,null,t,Kn,s),d&&wn(d)&&e.drawImage(d,i,r,a,o)}l&&u&&(Jn(e,"lineWidth",l),Jn(e,"strokeStyle",u),e.stroke())}function Kn(t,e){e.image=t}function Qn(t,e,n){var i=e.x||0,r=e.y||0,a=e.textAlign,o=e.textVerticalAlign;if(n){var s=e.textPosition;if(s instanceof Array)i=n.x+ni(s[0],n.width),r=n.y+ni(s[1],n.height);else{var l=An(s,n,e.textDistance);i=l.x,r=l.y,a=a||l.textAlign,o=o||l.textVerticalAlign}var u=e.textOffset;u&&(i+=u[0],r+=u[1])}return{baseX:i,baseY:r,textAlign:a,textVerticalAlign:o}}function Jn(t,e,n){return t[e]=Pg(t,e,n),t[e]}function ti(t,e){return null==t||0>=e||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function ei(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function ni(t,e){return"string"==typeof t?t.lastIndexOf("%%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function ii(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function ri(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function ai(t){t=t||{},bg.call(this,t);for(var e in t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new Og(t.style,this),this._rect=null,this.__clipPaths=[]}function oi(t){ai.call(this,t)}function si(t){return parseInt(t,10)}function li(t){return t?t.__builtin__?!0:"function"!=typeof t.resize||"function"!=typeof t.refresh?!1:!0:!1}function ui(t,e,n){return ev.copy(t.getBoundingRect()),t.transform&&ev.applyTransform(t.transform),nv.width=e,nv.height=n,!ev.intersect(nv)}function hi(t,e){if(t==e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!0}function ci(t,e){for(var n=0;n<t.length;n++){var i=t[n];i.setTransform(e),e.beginPath(),i.buildPath(e,i.shape),e.clip(),i.restoreTransform(e)}}function di(t,e){var n=document.createElement("div");return n.style.cssText=["position:relative","overflow:hidden","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",n}function fi(t){return t.getBoundingClientRect?t.getBoundingClientRect():{left:0,top:0}}function pi(t,e,n,i){return n=n||{},i||!Sp.canvasSupported?gi(t,e,n):Sp.browser.firefox&&null!=e.layerX&&e.layerX!==e.offsetX?(n.zrX=e.layerX,n.zrY=e.layerY):null!=e.offsetX?(n.zrX=e.offsetX,n.zrY=e.offsetY):gi(t,e,n),n}function gi(t,e,n){var i=fi(t);n.zrX=e.clientX-i.left,n.zrY=e.clientY-i.top}function vi(t,e,n){if(e=e||window.event,null!=e.zrX)return e;var i=e.type,r=i&&i.indexOf("touch")>=0;if(r){var a="touchend"!=i?e.targetTouches[0]:e.changedTouches[0];a&&pi(t,a,e,n)}else pi(t,e,e,n),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var o=e.button;return null==e.which&&void 0!==o&&av.test(e.type)&&(e.which=1&o?1:2&o?3:4&o?2:0),e}function mi(t,e,n){rv?t.addEventListener(e,n):t.attachEvent("on"+e,n)}function yi(t,e,n){rv?t.removeEventListener(e,n):t.detachEvent("on"+e,n)}function _i(t){return t.which>1}function xi(t){var e=t[1][0]-t[0][0],n=t[1][1]-t[0][1];return Math.sqrt(e*e+n*n)}function wi(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}function bi(t){return"mousewheel"===t&&Sp.browser.firefox?"DOMMouseScroll":t}function Si(t,e,n){var i=t._gestureMgr;"start"===n&&i.clear();var r=i.recognize(e,t.handler.findHover(e.zrX,e.zrY,null).target,t.dom);if("end"===n&&i.clear(),r){var a=r.type;e.gestureEvent=a,t.handler.dispatchToElement({target:r.target},a,r.event)}}function Mi(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}function Ti(t){var e=t.pointerType;return"pen"===e||"touch"===e}function Ii(t){function e(t,e){return function(){return e._touching?void 0:t.apply(e,arguments)}}f(dv,function(e){t._handlers[e]=y(gv[e],t)}),f(pv,function(e){t._handlers[e]=y(gv[e],t)}),f(cv,function(n){t._handlers[n]=e(gv[n],t)})}function Ci(t){function e(e,n){f(e,function(e){mi(t,bi(e),n._handlers[e])},n)}Up.call(this),this.dom=t,this._touching=!1,this._touchTimer,this._gestureMgr=new lv,this._handlers={},Ii(this),Sp.pointerEventsSupported?e(pv,this):(Sp.touchEventsSupported&&e(dv,this),e(cv,this))}function Di(t,e){var n=new wv(wp(),t,e);return _v[n.id]=n,n}function Ai(t){if(t)t.dispose();else{for(var e in _v)_v.hasOwnProperty(e)&&_v[e].dispose();_v={}}return this}function ki(t){return _v[t]}function Pi(t,e){yv[t]=e}function Li(t){delete _v[t]}function Oi(t){return t instanceof Array?t:null==t?[]:[t]}function Ei(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,r=n.length;r>i;i++){var a=n[i];!t.emphasis[e].hasOwnProperty(a)&&t[e].hasOwnProperty(a)&&(t.emphasis[e][a]=t[e][a])}}}function Ri(t){return!Mv(t)||Tv(t)||t instanceof Date?t:t.value}function zi(t){return Mv(t)&&!(t instanceof Array)}function Bi(t,e){e=(e||[]).slice();var n=p(t||[],function(t){return{exist:t}});return Sv(e,function(t,i){if(Mv(t)){for(var r=0;r<n.length;r++)if(!n[r].option&&null!=t.id&&n[r].exist.id===t.id+"")return n[r].option=t,void(e[i]=null);for(var r=0;r<n.length;r++){var a=n[r].exist;if(!(n[r].option||null!=a.id&&null!=t.id||null==t.name||Vi(t)||Vi(a)||a.name!==t.name+""))return n[r].option=t,void(e[i]=null)}}}),Sv(e,function(t){if(Mv(t)){for(var e=0;e<n.length;e++){var i=n[e].exist;if(!n[e].option&&!Vi(i)&&null==t.id){n[e].option=t;break}}e>=n.length&&n.push({option:t})}}),n}function Ni(t){var e=N();Sv(t,function(t){var n=t.exist;n&&e.set(n.id,t)}),Sv(t,function(t){var n=t.option;O(!n||null==n.id||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),Sv(t,function(t){var n=t.exist,i=t.option,r=t.keyInfo;if(Mv(i)){if(r.name=null!=i.name?i.name+"":n?n.name:Iv,n)r.id=n.id;else if(null!=i.id)r.id=i.id+"";else{var a=0;do r.id="\x00"+r.name+"\x00"+a++;while(e.get(r.id))}e.set(r.id,t)}})}function Vi(t){return Mv(t)&&t.id&&0===(t.id+"").indexOf("\x00_ec_\x00")}function Fi(t,e){return null!=e.dataIndexInside?e.dataIndexInside:null!=e.dataIndex?x(e.dataIndex)?p(e.dataIndex,function(e){return t.indexOfRawIndex(e)}):t.indexOfRawIndex(e.dataIndex):null!=e.name?x(e.name)?p(e.name,function(e){return t.indexOfName(e)}):t.indexOfName(e.name):void 0}function Hi(){var t="__\x00ec_inner_"+Dv++ +"_"+Math.random().toFixed(5);return function(e){return e[t]||(e[t]={})}}function Wi(t,e,n){if(b(e)){var i={};i[e+"Index"]=0,e=i}var r=n&&n.defaultMainType;!r||Gi(e,r+"Index")||Gi(e,r+"Id")||Gi(e,r+"Name")||(e[r+"Index"]=0);var a={};return Sv(e,function(i,r){var i=e[r];if("dataIndex"===r||"dataIndexInside"===r)return void(a[r]=i);var o=r.match(/^(\w+)(Index|Id|Name)$/)||[],s=o[1],l=(o[2]||"").toLowerCase();if(!(!s||!l||null==i||"index"===l&&"none"===i||n&&n.includeMainTypes&&u(n.includeMainTypes,s)<0)){var h={mainType:s};("index"!==l||"all"!==i)&&(h[l]=i);var c=t.queryComponents(h);a[s+"Models"]=c,a[s+"Model"]=c[0]}}),a}function Gi(t,e){return t&&t.hasOwnProperty(e)}function ji(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function Ui(t,e){return t.getAttribute?t.getAttribute(e):t[e]}function Zi(t){var e={main:"",sub:""};return t&&(t=t.split(Av),e.main=t[0]||"",e.sub=t[1]||""),e}function Xi(t){O(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}function Yi(t){t.$constructor=t,t.extend=function(t){var e=this,n=function(){t.$constructor?t.$constructor.apply(this,arguments):e.apply(this,arguments)};return o(n.prototype,t),n.extend=this.extend,n.superCall=$i,n.superApply=Ki,h(n,this),n.superClass=e,n}}function qi(t){var e=["__\x00is_clz",Pv++,Math.random().toFixed(3)].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function $i(t,e){var n=P(arguments,2);return this.superClass.prototype[e].apply(t,n)}function Ki(t,e,n){return this.superClass.prototype[e].apply(t,n)}function Qi(t,e){function n(t){var e=i[t.main];return e&&e[kv]||(e=i[t.main]={},e[kv]=!0),e}e=e||{};var i={};if(t.registerClass=function(t,e){if(e)if(Xi(e),e=Zi(e),e.sub){if(e.sub!==kv){var r=n(e);r[e.sub]=t}}else i[e.main]=t;return t},t.getClass=function(t,e,n){var r=i[t];if(r&&r[kv]&&(r=e?r[e]:null),n&&!r)throw new Error(e?"Component "+t+"."+(e||"")+" not exists. Load it first.":t+".type should be specified.");return r},t.getClassesByMainType=function(t){t=Zi(t);var e=[],n=i[t.main];return n&&n[kv]?f(n,function(t,n){n!==kv&&e.push(t)}):e.push(n),e},t.hasClass=function(t){return t=Zi(t),!!i[t.main]},t.getAllClassMainTypes=function(){var t=[];return f(i,function(e,n){t.push(n)}),t},t.hasSubTypes=function(t){t=Zi(t);var e=i[t.main];return e&&e[kv]},t.parseClassType=Zi,e.registerWhenExtend){var r=t.extend;r&&(t.extend=function(e){var n=r.call(this,e);return t.registerClass(n,e.type)})}return t}function Ji(t){return t>-Vv&&Vv>t}function tr(t){return t>Vv||-Vv>t}function er(t,e,n,i,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*i+3*a*n)}function nr(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function ir(t,e,n,i,r,a){var o=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),u=t-r,h=s*s-3*o*l,c=s*l-9*o*u,d=l*l-3*s*u,f=0;if(Ji(h)&&Ji(c))if(Ji(s))a[0]=0;else{var p=-l/s;p>=0&&1>=p&&(a[f++]=p)}else{var g=c*c-4*h*d;if(Ji(g)){var v=c/h,p=-s/o+v,m=-v/2;p>=0&&1>=p&&(a[f++]=p),m>=0&&1>=m&&(a[f++]=m)}else if(g>0){var y=Nv(g),_=h*s+1.5*o*(-c+y),x=h*s+1.5*o*(-c-y);_=0>_?-Bv(-_,Wv):Bv(_,Wv),x=0>x?-Bv(-x,Wv):Bv(x,Wv);var p=(-s-(_+x))/(3*o);p>=0&&1>=p&&(a[f++]=p)}else{var w=(2*h*s-3*o*c)/(2*Nv(h*h*h)),b=Math.acos(w)/3,S=Nv(h),M=Math.cos(b),p=(-s-2*S*M)/(3*o),m=(-s+S*(M+Hv*Math.sin(b)))/(3*o),T=(-s+S*(M-Hv*Math.sin(b)))/(3*o);p>=0&&1>=p&&(a[f++]=p),m>=0&&1>=m&&(a[f++]=m),T>=0&&1>=T&&(a[f++]=T)}}return f}function rr(t,e,n,i,r){var a=6*n-12*e+6*t,o=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(Ji(o)){if(tr(a)){var u=-s/a;u>=0&&1>=u&&(r[l++]=u)}}else{var h=a*a-4*o*s;if(Ji(h))r[0]=-a/(2*o);else if(h>0){var c=Nv(h),u=(-a+c)/(2*o),d=(-a-c)/(2*o);u>=0&&1>=u&&(r[l++]=u),d>=0&&1>=d&&(r[l++]=d)}}return l}function ar(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,u=(s-o)*r+o,h=(l-s)*r+s,c=(h-u)*r+u;a[0]=t,a[1]=o,a[2]=u,a[3]=c,a[4]=c,a[5]=h,a[6]=l,a[7]=i}function or(t,e,n,i,r,a,o,s,l,u,h){var c,d,f,p,g,v=.005,m=1/0;Gv[0]=l,Gv[1]=u;for(var y=0;1>y;y+=.05)jv[0]=er(t,n,r,o,y),jv[1]=er(e,i,a,s,y),p=Wp(Gv,jv),m>p&&(c=y,m=p);m=1/0;for(var _=0;32>_&&!(Fv>v);_++)d=c-v,f=c+v,jv[0]=er(t,n,r,o,d),jv[1]=er(e,i,a,s,d),p=Wp(jv,Gv),d>=0&&m>p?(c=d,m=p):(Uv[0]=er(t,n,r,o,f),Uv[1]=er(e,i,a,s,f),g=Wp(Uv,Gv),1>=f&&m>g?(c=f,m=g):v*=.5);return h&&(h[0]=er(t,n,r,o,c),h[1]=er(e,i,a,s,c)),Nv(m)}function sr(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function lr(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function ur(t,e,n,i,r){var a=t-2*e+n,o=2*(e-t),s=t-i,l=0;if(Ji(a)){if(tr(o)){var u=-s/o;u>=0&&1>=u&&(r[l++]=u)}}else{var h=o*o-4*a*s;if(Ji(h)){var u=-o/(2*a);u>=0&&1>=u&&(r[l++]=u)}else if(h>0){var c=Nv(h),u=(-o+c)/(2*a),d=(-o-c)/(2*a);u>=0&&1>=u&&(r[l++]=u),d>=0&&1>=d&&(r[l++]=d)}}return l}function hr(t,e,n){var i=t+n-2*e;return 0===i?.5:(t-e)/i}function cr(t,e,n,i,r){var a=(e-t)*i+t,o=(n-e)*i+e,s=(o-a)*i+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=n}function dr(t,e,n,i,r,a,o,s,l){var u,h=.005,c=1/0;Gv[0]=o,Gv[1]=s;for(var d=0;1>d;d+=.05){jv[0]=sr(t,n,r,d),jv[1]=sr(e,i,a,d);var f=Wp(Gv,jv);c>f&&(u=d,c=f)}c=1/0;for(var p=0;32>p&&!(Fv>h);p++){var g=u-h,v=u+h;jv[0]=sr(t,n,r,g),jv[1]=sr(e,i,a,g);var f=Wp(jv,Gv);if(g>=0&&c>f)u=g,c=f;else{Uv[0]=sr(t,n,r,v),Uv[1]=sr(e,i,a,v);var m=Wp(Uv,Gv);1>=v&&c>m?(u=v,c=m):h*=.5}}return l&&(l[0]=sr(t,n,r,u),l[1]=sr(e,i,a,u)),Nv(c)}function fr(t,e,n){if(0!==t.length){var i,r=t[0],a=r[0],o=r[0],s=r[1],l=r[1];for(i=1;i<t.length;i++)r=t[i],a=Zv(a,r[0]),o=Xv(o,r[0]),s=Zv(s,r[1]),l=Xv(l,r[1]);e[0]=a,e[1]=s,n[0]=o,n[1]=l}}function pr(t,e,n,i,r,a){r[0]=Zv(t,n),r[1]=Zv(e,i),a[0]=Xv(t,n),a[1]=Xv(e,i)}function gr(t,e,n,i,r,a,o,s,l,u){var h,c=rr,d=er,f=c(t,n,r,o,tm);for(l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0,h=0;f>h;h++){var p=d(t,n,r,o,tm[h]);l[0]=Zv(p,l[0]),u[0]=Xv(p,u[0])}for(f=c(e,i,a,s,em),h=0;f>h;h++){var g=d(e,i,a,s,em[h]);l[1]=Zv(g,l[1]),u[1]=Xv(g,u[1])}l[0]=Zv(t,l[0]),u[0]=Xv(t,u[0]),l[0]=Zv(o,l[0]),u[0]=Xv(o,u[0]),l[1]=Zv(e,l[1]),u[1]=Xv(e,u[1]),l[1]=Zv(s,l[1]),u[1]=Xv(s,u[1])}function vr(t,e,n,i,r,a,o,s){var l=hr,u=sr,h=Xv(Zv(l(t,n,r),1),0),c=Xv(Zv(l(e,i,a),1),0),d=u(t,n,r,h),f=u(e,i,a,c);o[0]=Zv(t,r,d),o[1]=Zv(e,a,f),s[0]=Xv(t,r,d),s[1]=Xv(e,a,f)}function mr(t,e,n,i,r,a,o,s,l){var u=oe,h=se,c=Math.abs(r-a);if(1e-4>c%%$v&&c>1e-4)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(Kv[0]=qv(r)*n+t,Kv[1]=Yv(r)*i+e,Qv[0]=qv(a)*n+t,Qv[1]=Yv(a)*i+e,u(s,Kv,Qv),h(l,Kv,Qv),r%%=$v,0>r&&(r+=$v),a%%=$v,0>a&&(a+=$v),r>a&&!o?a+=$v:a>r&&o&&(r+=$v),o){var d=a;a=r,r=d}for(var f=0;a>f;f+=Math.PI/2)f>r&&(Jv[0]=qv(f)*n+t,Jv[1]=Yv(f)*i+e,u(s,Jv,s),h(l,Jv,l))}function yr(t,e,n,i,r,a,o){if(0===r)return!1;var s=r,l=0,u=t;if(o>e+s&&o>i+s||e-s>o&&i-s>o||a>t+s&&a>n+s||t-s>a&&n-s>a)return!1;if(t===n)return Math.abs(a-t)<=s/2;l=(e-i)/(t-n),u=(t*i-n*e)/(t-n);var h=l*a-o+u,c=h*h/(l*l+1);return s/2*s/2>=c}function _r(t,e,n,i,r,a,o,s,l,u,h){if(0===l)return!1;var c=l;if(h>e+c&&h>i+c&&h>a+c&&h>s+c||e-c>h&&i-c>h&&a-c>h&&s-c>h||u>t+c&&u>n+c&&u>r+c&&u>o+c||t-c>u&&n-c>u&&r-c>u&&o-c>u)return!1;var d=or(t,e,n,i,r,a,o,s,u,h,null);return c/2>=d}function xr(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var u=o;if(l>e+u&&l>i+u&&l>a+u||e-u>l&&i-u>l&&a-u>l||s>t+u&&s>n+u&&s>r+u||t-u>s&&n-u>s&&r-u>s)return!1;var h=dr(t,e,n,i,r,a,s,l,null);return u/2>=h}function wr(t){return t%%=gm,0>t&&(t+=gm),t}function br(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var u=o;s-=t,l-=e;var h=Math.sqrt(s*s+l*l);if(h-u>n||n>h+u)return!1;if(Math.abs(i-r)%%vm<1e-4)return!0;if(a){var c=i;i=wr(r),r=wr(c)}else i=wr(i),r=wr(r);i>r&&(r+=vm);var d=Math.atan2(l,s);return 0>d&&(d+=vm),d>=i&&r>=d||d+vm>=i&&r>=d+vm}function Sr(t,e,n,i,r,a){if(a>e&&a>i||e>a&&i>a)return 0;if(i===e)return 0;var o=e>i?1:-1,s=(a-e)/(i-e);(1===s||0===s)&&(o=e>i?.5:-.5);var l=s*(n-t)+t;return l>r?o:0}function Mr(t,e){return Math.abs(t-e)<_m}function Tr(){var t=wm[0];wm[0]=wm[1],wm[1]=t}function Ir(t,e,n,i,r,a,o,s,l,u){if(u>e&&u>i&&u>a&&u>s||e>u&&i>u&&a>u&&s>u)return 0;var h=ir(e,i,a,s,u,xm);if(0===h)return 0;for(var c,d,f=0,p=-1,g=0;h>g;g++){var v=xm[g],m=0===v||1===v?.5:1,y=er(t,n,r,o,v);l>y||(0>p&&(p=rr(e,i,a,s,wm),wm[1]<wm[0]&&p>1&&Tr(),c=er(e,i,a,s,wm[0]),p>1&&(d=er(e,i,a,s,wm[1]))),f+=2==p?v<wm[0]?e>c?m:-m:v<wm[1]?c>d?m:-m:d>s?m:-m:v<wm[0]?e>c?m:-m:c>s?m:-m)}return f}function Cr(t,e,n,i,r,a,o,s){if(s>e&&s>i&&s>a||e>s&&i>s&&a>s)return 0;var l=ur(e,i,a,s,xm);if(0===l)return 0;var u=hr(e,i,a);if(u>=0&&1>=u){for(var h=0,c=sr(e,i,a,u),d=0;l>d;d++){var f=0===xm[d]||1===xm[d]?.5:1,p=sr(t,n,r,xm[d]);o>p||(h+=xm[d]<u?e>c?f:-f:c>a?f:-f)}return h}var f=0===xm[0]||1===xm[0]?.5:1,p=sr(t,n,r,xm[0]);return o>p?0:e>a?f:-f}function Dr(t,e,n,i,r,a,o,s){if(s-=e,s>n||-n>s)return 0;var l=Math.sqrt(n*n-s*s);xm[0]=-l,xm[1]=l;var u=Math.abs(i-r);if(1e-4>u)return 0;if(1e-4>u%%ym){i=0,r=ym;var h=a?1:-1;return o>=xm[0]+t&&o<=xm[1]+t?h:0}if(a){var l=i;i=wr(r),r=wr(l)}else i=wr(i),r=wr(r);i>r&&(r+=ym);for(var c=0,d=0;2>d;d++){var f=xm[d];if(f+t>o){var p=Math.atan2(s,f),h=a?1:-1;0>p&&(p=ym+p),(p>=i&&r>=p||p+ym>=i&&r>=p+ym)&&(p>Math.PI/2&&p<1.5*Math.PI&&(h=-h),c+=h)}}return c}function Ar(t,e,n,i,r){for(var a=0,o=0,s=0,l=0,u=0,h=0;h<t.length;){var c=t[h++];switch(c===mm.M&&h>1&&(n||(a+=Sr(o,s,l,u,i,r))),1==h&&(o=t[h],s=t[h+1],l=o,u=s),c){case mm.M:l=t[h++],u=t[h++],o=l,s=u;break;case mm.L:if(n){if(yr(o,s,t[h],t[h+1],e,i,r))return!0}else a+=Sr(o,s,t[h],t[h+1],i,r)||0;o=t[h++],s=t[h++];break;case mm.C:if(n){if(_r(o,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],e,i,r))return!0}else a+=Ir(o,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],i,r)||0;o=t[h++],s=t[h++];break;case mm.Q:if(n){if(xr(o,s,t[h++],t[h++],t[h],t[h+1],e,i,r))return!0}else a+=Cr(o,s,t[h++],t[h++],t[h],t[h+1],i,r)||0;o=t[h++],s=t[h++];break;case mm.A:var d=t[h++],f=t[h++],p=t[h++],g=t[h++],v=t[h++],m=t[h++],y=(t[h++],1-t[h++]),_=Math.cos(v)*p+d,x=Math.sin(v)*g+f;h>1?a+=Sr(o,s,_,x,i,r):(l=_,u=x);var w=(i-d)*g/p+d;if(n){if(br(d,f,g,v,v+m,y,e,w,r))return!0}else a+=Dr(d,f,g,v,v+m,y,w,r);o=Math.cos(v+m)*p+d,s=Math.sin(v+m)*g+f;break;case mm.R:l=o=t[h++],u=s=t[h++];var b=t[h++],S=t[h++],_=l+b,x=u+S;if(n){if(yr(l,u,_,u,e,i,r)||yr(_,u,_,x,e,i,r)||yr(_,x,l,x,e,i,r)||yr(l,x,l,u,e,i,r))return!0}else a+=Sr(_,u,_,x,i,r),a+=Sr(l,x,l,u,i,r);break;case mm.Z:if(n){if(yr(o,s,l,u,e,i,r))return!0}else a+=Sr(o,s,l,u,i,r);o=l,s=u}}return n||Mr(s,u)||(a+=Sr(o,s,l,u,i,r)||0),0!==a}function kr(t,e,n){return Ar(t,0,!1,e,n)}function Pr(t,e,n,i){return Ar(t,e,!0,n,i)}function Lr(t){ai.call(this,t),this.path=null}function Or(t,e,n,i,r,a,o,s,l,u,h){var c=l*(Em/180),d=Om(c)*(t-n)/2+Lm(c)*(e-i)/2,f=-1*Lm(c)*(t-n)/2+Om(c)*(e-i)/2,p=d*d/(o*o)+f*f/(s*s);p>1&&(o*=Pm(p),s*=Pm(p));var g=(r===a?-1:1)*Pm((o*o*s*s-o*o*f*f-s*s*d*d)/(o*o*f*f+s*s*d*d))||0,v=g*o*f/s,m=g*-s*d/o,y=(t+n)/2+Om(c)*v-Lm(c)*m,_=(e+i)/2+Lm(c)*v+Om(c)*m,x=Bm([1,0],[(d-v)/o,(f-m)/s]),w=[(d-v)/o,(f-m)/s],b=[(-1*d-v)/o,(-1*f-m)/s],S=Bm(w,b);zm(w,b)<=-1&&(S=Em),zm(w,b)>=1&&(S=0),0===a&&S>0&&(S-=2*Em),1===a&&0>S&&(S+=2*Em),h.addData(u,y,_,o,s,x,S,c,a)}function Er(t){if(!t)return[];var e,n=t.replace(/-/g," -").replace(/ /g," ").replace(/ /g,",").replace(/,,/g,",");for(e=0;e<km.length;e++)n=n.replace(new RegExp(km[e],"g"),"|"+km[e]);var i,r=n.split("|"),a=0,o=0,s=new pm,l=pm.CMD;for(e=1;e<r.length;e++){var u,h=r[e],c=h.charAt(0),d=0,f=h.slice(1).replace(/e,-/g,"e-").split(",");f.length>0&&""===f[0]&&f.shift();for(var p=0;p<f.length;p++)f[p]=parseFloat(f[p]);for(;d<f.length&&!isNaN(f[d])&&!isNaN(f[0]);){var g,v,m,y,_,x,w,b=a,S=o;switch(c){case"l":a+=f[d++],o+=f[d++],u=l.L,s.addData(u,a,o);break;case"L":a=f[d++],o=f[d++],u=l.L,s.addData(u,a,o);break;case"m":a+=f[d++],o+=f[d++],u=l.M,s.addData(u,a,o),c="l";break;case"M":a=f[d++],o=f[d++],u=l.M,s.addData(u,a,o),c="L";break;case"h":a+=f[d++],u=l.L,s.addData(u,a,o);break;case"H":a=f[d++],u=l.L,s.addData(u,a,o);break;case"v":o+=f[d++],u=l.L,s.addData(u,a,o);break;case"V":o=f[d++],u=l.L,s.addData(u,a,o);break;case"C":u=l.C,s.addData(u,f[d++],f[d++],f[d++],f[d++],f[d++],f[d++]),a=f[d-2],o=f[d-1];break;case"c":u=l.C,s.addData(u,f[d++]+a,f[d++]+o,f[d++]+a,f[d++]+o,f[d++]+a,f[d++]+o),a+=f[d-2],o+=f[d-1];break;case"S":g=a,v=o;var M=s.len(),T=s.data;i===l.C&&(g+=a-T[M-4],v+=o-T[M-3]),u=l.C,b=f[d++],S=f[d++],a=f[d++],o=f[d++],s.addData(u,g,v,b,S,a,o);break;case"s":g=a,v=o;var M=s.len(),T=s.data;i===l.C&&(g+=a-T[M-4],v+=o-T[M-3]),u=l.C,b=a+f[d++],S=o+f[d++],a+=f[d++],o+=f[d++],s.addData(u,g,v,b,S,a,o);break;case"Q":b=f[d++],S=f[d++],a=f[d++],o=f[d++],u=l.Q,s.addData(u,b,S,a,o);break;case"q":b=f[d++]+a,S=f[d++]+o,a+=f[d++],o+=f[d++],u=l.Q,s.addData(u,b,S,a,o);break;case"T":g=a,v=o;var M=s.len(),T=s.data;i===l.Q&&(g+=a-T[M-4],v+=o-T[M-3]),a=f[d++],o=f[d++],u=l.Q,s.addData(u,g,v,a,o);break;case"t":g=a,v=o;var M=s.len(),T=s.data;i===l.Q&&(g+=a-T[M-4],v+=o-T[M-3]),a+=f[d++],o+=f[d++],u=l.Q,s.addData(u,g,v,a,o);break;case"A":m=f[d++],y=f[d++],_=f[d++],x=f[d++],w=f[d++],b=a,S=o,a=f[d++],o=f[d++],u=l.A,Or(b,S,a,o,x,w,m,y,_,u,s);break;case"a":m=f[d++],y=f[d++],_=f[d++],x=f[d++],w=f[d++],b=a,S=o,a+=f[d++],o+=f[d++],u=l.A,Or(b,S,a,o,x,w,m,y,_,u,s)}}("z"===c||"Z"===c)&&(u=l.Z,s.addData(u)),i=u}return s.toStatic(),s}function Rr(t,e){var n=Er(t);return e=e||{},e.buildPath=function(t){if(t.setData){t.setData(n.data);var e=t.getContext();e&&t.rebuildPath(e)}else{var e=t;n.rebuildPath(e)}},e.applyTransform=function(t){Am(n,t),this.dirty(!0)},e}function zr(t,e){return new Lr(Rr(t,e))}function Br(t,e){return Lr.extend(Rr(t,e))}function Nr(t,e){for(var n=[],i=t.length,r=0;i>r;r++){var a=t[r];a.path||a.createPathProxy(),a.__dirtyPath&&a.buildPath(a.path,a.shape,!0),n.push(a.path)}var o=new Lr(e);return o.createPathProxy(),o.buildPath=function(t){t.appendPath(n);var e=t.getContext();e&&t.rebuildPath(e)},o}function Vr(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Fr(t,e,n){var i=e.points,r=e.smooth;if(i&&i.length>=2){if(r&&"spline"!==r){var a=Um(i,r,n,e.smoothConstraint);t.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;(n?o:o-1)>s;s++){var l=a[2*s],u=a[2*s+1],h=i[(s+1)%%o];t.bezierCurveTo(l[0],l[1],u[0],u[1],h[0],h[1])}}else{"spline"===r&&(i=jm(i,n)),t.moveTo(i[0][0],i[0][1]);for(var s=1,c=i.length;c>s;s++)t.lineTo(i[s][0],i[s][1])}n&&t.closePath()}}function Hr(t,e,n){var i=t.cpx2,r=t.cpy2;return null===i||null===r?[(n?nr:er)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?nr:er)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?lr:sr)(t.x1,t.cpx1,t.x2,e),(n?lr:sr)(t.y1,t.cpy1,t.y2,e)]}function Wr(t){ai.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}function Gr(t){return Lr.extend(t)}function jr(t,e){return Br(t,e)}function Ur(t,e,n,i){var r=zr(t,e),a=r.getBoundingRect();return n&&("center"===i&&(n=Xr(n,a)),Yr(r,n)),r}function Zr(t,e,n){var i=new oi({style:{image:t,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(t){if("center"===n){var r={width:t.width,height:t.height};i.setStyle(Xr(e,r))}}});return i}function Xr(t,e){var n,i=e.width/e.height,r=t.height*i;r<=t.width?n=t.height:(r=t.width,n=r/i);var a=t.x+t.width/2,o=t.y+t.height/2;return{x:a-r/2,y:o-n/2,width:r,height:n}}function Yr(t,e){if(t.applyTransform){var n=t.getBoundingRect(),i=n.calculateTransform(e);t.applyTransform(i)}}function qr(t){var e=t.shape,n=t.style.lineWidth;return ry(2*e.x1)===ry(2*e.x2)&&(e.x1=e.x2=Kr(e.x1,n,!0)),ry(2*e.y1)===ry(2*e.y2)&&(e.y1=e.y2=Kr(e.y1,n,!0)),t}function $r(t){var e=t.shape,n=t.style.lineWidth,i=e.x,r=e.y,a=e.width,o=e.height;return e.x=Kr(e.x,n,!0),e.y=Kr(e.y,n,!0),e.width=Math.max(Kr(i+a,n,!1)-e.x,0===a?0:1),e.height=Math.max(Kr(r+o,n,!1)-e.y,0===o?0:1),t}function Kr(t,e,n){var i=ry(2*t);return(i+ry(e))%%2===0?i/2:(i+(n?1:-1))/2}function Qr(t){return null!=t&&"none"!=t}function Jr(t){return"string"==typeof t?Be(t,-.1):t}function ta(t){if(t.__hoverStlDirty){var e=t.style.stroke,n=t.style.fill,i=t.__hoverStl;i.fill=i.fill||(Qr(n)?Jr(n):null),i.stroke=i.stroke||(Qr(e)?Jr(e):null);var r={};for(var a in i)null!=i[a]&&(r[a]=t.style[a]);t.__normalStl=r,t.__hoverStlDirty=!1}}function ea(t){if(!t.__isHover){if(ta(t),t.useHoverLayer)t.__zr&&t.__zr.addHover(t,t.__hoverStl);else{var e=t.style,n=e.insideRollbackOpt;n&&_a(e),e.extendFrom(t.__hoverStl),n&&(ya(e,e.insideOriginalTextPosition,n),null==e.textFill&&(e.textFill=n.autoColor)),t.dirty(!1),t.z2+=1}t.__isHover=!0}}function na(t){if(t.__isHover){var e=t.__normalStl;t.useHoverLayer?t.__zr&&t.__zr.removeHover(t):(e&&t.setStyle(e),t.z2-=1),t.__isHover=!1}}function ia(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&ea(t)}):ea(t)}function ra(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&na(t)}):na(t)}function aa(t,e){t.__hoverStl=t.hoverStyle||e||{},t.__hoverStlDirty=!0,t.__isHover&&ta(t)}function oa(t){this.__hoverSilentOnTouch&&t.zrByTouch||!this.__isEmphasis&&ia(this)}function sa(t){this.__hoverSilentOnTouch&&t.zrByTouch||!this.__isEmphasis&&ra(this)}function la(){this.__isEmphasis=!0,ia(this)}function ua(){this.__isEmphasis=!1,ra(this)}function ha(t,e,n){t.__hoverSilentOnTouch=n&&n.hoverSilentOnTouch,"group"===t.type?t.traverse(function(t){"group"!==t.type&&aa(t,e)}):aa(t,e),t.on("mouseover",oa).on("mouseout",sa),t.on("emphasis",la).on("normal",ua)}function ca(t,e,n,i,r,a,o){r=r||sy;var s,l=r.labelFetcher,u=r.labelDataIndex,h=r.labelDimIndex,c=n.getShallow("show"),d=i.getShallow("show");(c||d)&&(l&&(s=l.getFormattedLabel(u,"normal",null,h)),null==s&&(s=w(r.defaultText)?r.defaultText(u,r):r.defaultText));var f=c?s:null,p=d?A(l?l.getFormattedLabel(u,"emphasis",null,h):null,s):null;(null!=f||null!=p)&&(da(t,n,a,r),da(e,i,o,r,!0)),t.text=f,e.text=p}function da(t,e,n,i,r){return pa(t,e,i,r),n&&o(t,n),t.host&&t.host.dirty&&t.host.dirty(!1),t}function fa(t,e,n){var i,r={isRectText:!0};n===!1?i=!0:r.autoColor=n,pa(t,e,r,i),t.host&&t.host.dirty&&t.host.dirty(!1)}function pa(t,e,n,i){if(n=n||sy,n.isRectText){var r=e.getShallow("position")||(i?null:"inside");"outside"===r&&(r="top"),t.textPosition=r,t.textOffset=e.getShallow("offset");var a=e.getShallow("rotate");null!=a&&(a*=Math.PI/180),t.textRotation=a,t.textDistance=A(e.getShallow("distance"),i?null:5)}var o,s=e.ecModel,l=s&&s.option.textStyle,u=ga(e);if(u){o={};for(var h in u)if(u.hasOwnProperty(h)){var c=e.getModel(["rich",h]);va(o[h]={},c,l,n,i)}}return t.rich=o,va(t,e,l,n,i,!0),n.forceRich&&!n.textStyle&&(n.textStyle={}),t}function ga(t){for(var e;t&&t!==t.ecModel;){var n=(t.option||sy).rich;if(n){e=e||{};for(var i in n)n.hasOwnProperty(i)&&(e[i]=1)}t=t.parentModel}return e}function va(t,e,n,i,r,a){if(n=!r&&n||sy,t.textFill=ma(e.getShallow("color"),i)||n.color,t.textStroke=ma(e.getShallow("textBorderColor"),i)||n.textBorderColor,t.textStrokeWidth=A(e.getShallow("textBorderWidth"),n.textBorderWidth),!r){if(a){var o=t.textPosition;t.insideRollback=ya(t,o,i),t.insideOriginalTextPosition=o,t.insideRollbackOpt=i}null==t.textFill&&(t.textFill=i.autoColor)}t.fontStyle=e.getShallow("fontStyle")||n.fontStyle,t.fontWeight=e.getShallow("fontWeight")||n.fontWeight,t.fontSize=e.getShallow("fontSize")||n.fontSize,t.fontFamily=e.getShallow("fontFamily")||n.fontFamily,t.textAlign=e.getShallow("align"),t.textVerticalAlign=e.getShallow("verticalAlign")||e.getShallow("baseline"),t.textLineHeight=e.getShallow("lineHeight"),t.textWidth=e.getShallow("width"),t.textHeight=e.getShallow("height"),t.textTag=e.getShallow("tag"),a&&i.disableBox||(t.textBackgroundColor=ma(e.getShallow("backgroundColor"),i),t.textPadding=e.getShallow("padding"),t.textBorderColor=ma(e.getShallow("borderColor"),i),t.textBorderWidth=e.getShallow("borderWidth"),t.textBorderRadius=e.getShallow("borderRadius"),t.textBoxShadowColor=e.getShallow("shadowColor"),t.textBoxShadowBlur=e.getShallow("shadowBlur"),t.textBoxShadowOffsetX=e.getShallow("shadowOffsetX"),t.textBoxShadowOffsetY=e.getShallow("shadowOffsetY")),t.textShadowColor=e.getShallow("textShadowColor")||n.textShadowColor,t.textShadowBlur=e.getShallow("textShadowBlur")||n.textShadowBlur,t.textShadowOffsetX=e.getShallow("textShadowOffsetX")||n.textShadowOffsetX,t.textShadowOffsetY=e.getShallow("textShadowOffsetY")||n.textShadowOffsetY}function ma(t,e){return"auto"!==t?t:e&&e.autoColor?e.autoColor:null}function ya(t,e,n){var i,r=n.useInsideStyle;return null==t.textFill&&r!==!1&&(r===!0||n.isRectText&&e&&"string"==typeof e&&e.indexOf("inside")>=0)&&(i={textFill:null,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth},t.textFill="#fff",null==t.textStroke&&(t.textStroke=n.autoColor,null==t.textStrokeWidth&&(t.textStrokeWidth=2))),i}function _a(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth)}function xa(t,e){var n=e||e.getModel("textStyle");return E([t.fontStyle||n&&n.getShallow("fontStyle")||"",t.fontWeight||n&&n.getShallow("fontWeight")||"",(t.fontSize||n&&n.getShallow("fontSize")||12)+"px",t.fontFamily||n&&n.getShallow("fontFamily")||"sans-serif"].join(" "))}function wa(t,e,n,i,r,a){"function"==typeof r&&(a=r,r=null);var o=i&&i.isAnimationEnabled();if(o){var s=t?"Update":"",l=i.getShallow("animationDuration"+s),u=i.getShallow("animationEasing"+s),h=i.getShallow("animationDelay"+s);"function"==typeof h&&(h=h(r,i.getAnimationDelayParams?i.getAnimationDelayParams(e,r):null)),"function"==typeof l&&(l=l(r)),l>0?e.animateTo(n,l,h||0,u,a,!!a):(e.stopAnimation(),e.attr(n),a&&a())}else e.stopAnimation(),e.attr(n),a&&a()}function ba(t,e,n,i,r){wa(!0,t,e,n,i,r)}function Sa(t,e,n,i,r){wa(!1,t,e,n,i,r)}function Ma(t,e){for(var n=pe([]);t&&t!==e;)ve(n,t.getLocalTransform(),n),t=t.parent;return n}function Ta(t,e,n){return e&&!d(e)&&(e=Jp.getLocalTransform(e)),n&&(e=xe([],e)),ae([],t,e)}function Ia(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return a=Ta(a,e,n),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Ca(t,e,n){function i(t){var e={};return t.traverse(function(t){!t.isGroup&&t.anid&&(e[t.anid]=t)}),e}function r(t){var e={position:G(t.position),rotation:t.rotation};return t.shape&&(e.shape=o({},t.shape)),e}if(t&&e){var a=i(t);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=a[t.anid];if(e){var i=r(t);t.attr(r(e)),ba(t,i,n,t.dataIndex)}}})}}function Da(t,e){return p(t,function(t){var n=t[0];n=ay(n,e.x),n=oy(n,e.x+e.width);var i=t[1];return i=ay(i,e.y),i=oy(i,e.y+e.height),[n,i]})}function Aa(t,e){var n=ay(t.x,e.x),i=oy(t.x+t.width,e.x+e.width),r=ay(t.y,e.y),a=oy(t.y+t.height,e.y+e.height);return i>=n&&a>=r?{x:n,y:r,width:i-n,height:a-r}:void 0}function ka(t,e,n){e=o({rectHover:!0},e);var i=e.style={strokeNoScale:!0};return n=n||{x:-1,y:-1,width:2,height:2},t?0===t.indexOf("image://")?(i.image=t.slice(8),s(i,n),new oi(e)):Ur(t.replace("path://",""),e,n,"center"):void 0}function Pa(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function La(t,e,n){for(var i=0;i<e.length&&(!e[i]||(t=t&&"object"==typeof t?t[e[i]]:null,null!=t));i++);return null==t&&n&&(t=n.get(e)),t}function Oa(t,e){var n=gy(t).getParent;return n?n.call(t,e):t.parentModel}function Ea(t){return[t||"",vy++,Math.random().toFixed(5)].join("_")}function Ra(t){var e={};return t.registerSubTypeDefaulter=function(t,n){t=Zi(t),e[t.main]=n},t.determineSubType=function(n,i){var r=i.type;if(!r){var a=Zi(n).main;t.hasSubTypes(n)&&e[a]&&(r=e[a](i))}return r},t}function za(t,e){function n(t){var n={},a=[];return f(t,function(o){var s=i(n,o),l=s.originalDeps=e(o),h=r(l,t);s.entryCount=h.length,0===s.entryCount&&a.push(o),f(h,function(t){u(s.predecessor,t)<0&&s.predecessor.push(t);var e=i(n,t);u(e.successor,t)<0&&e.successor.push(o)})}),{graph:n,noEntryList:a}}function i(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}function r(t,e){var n=[];return f(t,function(t){u(e,t)>=0&&n.push(t)}),n}t.topologicalTravel=function(t,e,i,r){function a(t){l[t].entryCount--,0===l[t].entryCount&&u.push(t)}function o(t){h[t]=!0,a(t)}if(t.length){var s=n(e),l=s.graph,u=s.noEntryList,h={};for(f(t,function(t){h[t]=!0});u.length;){var c=u.pop(),d=l[c],p=!!h[c];p&&(i.call(r,c,d.originalDeps.slice()),delete h[c]),f(d.successor,p?o:a)}f(h,function(){throw new Error("Circle dependency may exists")})}}}function Ba(t){return t.replace(/^\s+/,"").replace(/\s+$/,"")}function Na(t,e,n,i){var r=e[1]-e[0],a=n[1]-n[0];if(0===r)return 0===a?n[0]:(n[0]+n[1])/2;if(i)if(r>0){if(t<=e[0])return n[0];if(t>=e[1])return n[1]}else{if(t>=e[0])return n[0];if(t<=e[1])return n[1]}else{if(t===e[0])return n[0];if(t===e[1])return n[1]}return(t-e[0])/r*a+n[0]}function Va(t,e){switch(t){case"center":case"middle":t="50%%";break;case"left":case"top":t="0%%";break;case"right":case"bottom":t="100%%"}return"string"==typeof t?Ba(t).match(/%%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?0/0:+t}function Fa(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function Ha(t){return t.sort(function(t,e){return t-e}),t}function Wa(t){if(t=+t,isNaN(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n}function Ga(t){var e=t.toString(),n=e.indexOf("e");if(n>0){var i=+e.slice(n+1);return 0>i?-i:0}var r=e.indexOf(".");return 0>r?0:e.length-1-r}function ja(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),a=Math.round(n(Math.abs(e[1]-e[0]))/i),o=Math.min(Math.max(-r+a,0),20);return isFinite(o)?o:20}function Ua(t,e,n){if(!t[e])return 0;var i=g(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===i)return 0;for(var r=Math.pow(10,n),a=p(t,function(t){return(isNaN(t)?0:t)/i*r*100}),o=100*r,s=p(a,function(t){return Math.floor(t)}),l=g(s,function(t,e){return t+e},0),u=p(a,function(t,e){return t-s[e]});o>l;){for(var h=Number.NEGATIVE_INFINITY,c=null,d=0,f=u.length;f>d;++d)u[d]>h&&(h=u[d],c=d);++s[c],u[c]=0,++l}return s[e]/r}function Za(t){var e=2*Math.PI;return(t%%e+e)%%e}function Xa(t){return t>-my&&my>t}function Ya(t){if(t instanceof Date)return t;if("string"==typeof t){var e=_y.exec(t);if(!e)return new Date(0/0);if(e[8]){var n=+e[4]||0;return"Z"!==e[8].toUpperCase()&&(n-=e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,n,+(e[5]||0),+e[6]||0,+e[7]||0))}return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,+e[7]||0)}return new Date(null==t?0/0:Math.round(t))}function qa(t){return Math.pow(10,$a(t))}function $a(t){return Math.floor(Math.log(t)/Math.LN10)}function Ka(t,e){var n,i=$a(t),r=Math.pow(10,i),a=t/r;return n=e?1.5>a?1:2.5>a?2:4>a?3:7>a?5:10:1>a?1:2>a?2:3>a?3:5>a?5:10,t=n*r,i>=-20?+t.toFixed(0>i?-i:0):t}function Qa(t){function e(t,n,i){return t.interval[i]<n.interval[i]||t.interval[i]===n.interval[i]&&(t.close[i]-n.close[i]===(i?-1:1)||!i&&e(t,n,1))}t.sort(function(t,n){return e(t,n,0)?-1:1});for(var n=-1/0,i=1,r=0;r<t.length;){for(var a=t[r].interval,o=t[r].close,s=0;2>s;s++)a[s]<=n&&(a[s]=n,o[s]=s?1:1-i),n=a[s],i=o[s];a[0]===a[1]&&o[0]*o[1]!==1?t.splice(r,1):r++}return t}function Ja(t){return t-parseFloat(t)>=0}function to(t){return isNaN(t)?"-":(t=(t+"").split("."),t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:""))}function eo(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}function no(t){return String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function io(t,e,n){x(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],a=0;a<r.length;a++){var o=by[a];t=t.replace(Sy(o),Sy(o,0))}for(var s=0;i>s;s++)for(var l=0;l<r.length;l++){var u=e[s][r[l]];t=t.replace(Sy(by[l],s),n?no(u):u)}return t}function ro(t,e,n){return f(e,function(e,i){t=t.replace("{"+i+"}",n?no(e):e)}),t}function ao(t,e){t=b(t)?{color:t,extraCssText:e}:t||{};var n=t.color,i=t.type,e=t.extraCssText;return n?"subItem"===i?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+no(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:'+no(n)+";"+(e||"")+'"></span>':""}function oo(t,e,n){("week"===t||"month"===t||"quarter"===t||"half-year"===t||"year"===t)&&(t="MM-dd\nyyyy");var i=Ya(e),r=n?"UTC":"",a=i["get"+r+"FullYear"](),o=i["get"+r+"Month"]()+1,s=i["get"+r+"Date"](),l=i["get"+r+"Hours"](),u=i["get"+r+"Minutes"](),h=i["get"+r+"Seconds"]();return t=t.replace("MM",My(o)).replace("M",o).replace("yyyy",a).replace("yy",a%%100).replace("dd",My(s)).replace("d",s).replace("hh",My(l)).replace("h",l).replace("mm",My(u)).replace("m",u).replace("ss",My(h)).replace("s",h)}function so(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function lo(t,e,n,i,r){var a=0,o=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;e.eachChild(function(l,u){var h,c,d=l.position,f=l.getBoundingRect(),p=e.childAt(u+1),g=p&&p.getBoundingRect();if("horizontal"===t){var v=f.width+(g?-g.x+f.x:0);h=a+v,h>i||l.newline?(a=0,h=v,o+=s+n,s=f.height):s=Math.max(s,f.height)}else{var m=f.height+(g?-g.y+f.y:0);c=o+m,c>r||l.newline?(a+=s+n,o=0,c=m,s=f.width):s=Math.max(s,f.width)}l.newline||(d[0]=a,d[1]=o,"horizontal"===t?a=h+n:o=c+n)})}function uo(t,e,n){n=wy(n||0);var i=e.width,r=e.height,a=Va(t.left,i),o=Va(t.top,r),s=Va(t.right,i),l=Va(t.bottom,r),u=Va(t.width,i),h=Va(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(u)&&(u=i-s-d-a),isNaN(h)&&(h=r-l-c-o),null!=f&&(isNaN(u)&&isNaN(h)&&(f>i/r?u=.8*i:h=.8*r),isNaN(u)&&(u=f*h),isNaN(h)&&(h=u/f)),isNaN(a)&&(a=i-s-u-d),isNaN(o)&&(o=r-l-h-c),t.left||t.right){case"center":a=i/2-u/2-n[3];break;case"right":a=i-u-d}switch(t.top||t.bottom){case"middle":case"center":o=r/2-h/2-n[0];break;case"bottom":o=r-h-c}a=a||0,o=o||0,isNaN(u)&&(u=i-d-a-(s||0)),isNaN(h)&&(h=r-c-o-(l||0));var p=new rn(a+n[3],o+n[0],u,h);return p.margin=n,p}function ho(t,e,n,i,r){var a=!r||!r.hv||r.hv[0],o=!r||!r.hv||r.hv[1],l=r&&r.boundingMode||"all";if(a||o){var u;if("raw"===l)u="group"===t.type?new rn(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(u=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();u=u.clone(),u.applyTransform(h)}e=uo(s({width:u.width,height:u.height},e),n,i);var c=t.position,d=a?e.x-u.x:0,f=o?e.y-u.y:0;t.attr("position","raw"===l?[d,f]:[c[0]+d,c[1]+f])}}function co(t,e,n){function i(n,i){var o={},l=0,u={},h=0,c=2;if(Dy(n,function(e){u[e]=t[e]}),Dy(n,function(t){r(e,t)&&(o[t]=u[t]=e[t]),a(o,t)&&l++,a(u,t)&&h++}),s[i])return a(e,n[1])?u[n[2]]=null:a(e,n[2])&&(u[n[1]]=null),u;if(h!==c&&l){if(l>=c)return o;for(var d=0;d<n.length;d++){var f=n[d];if(!r(o,f)&&r(t,f)){o[f]=t[f];break}}return o}return u}function r(t,e){return t.hasOwnProperty(e)}function a(t,e){return null!=t[e]&&"auto"!==t[e]}function o(t,e,n){Dy(t,function(t){e[t]=n[t]})}!S(n)&&(n={});var s=n.ignoreSize;!x(s)&&(s=[s,s]);var l=i(ky[0],0),u=i(ky[1],1);o(ky[0],t,l),o(ky[1],t,u)}function fo(t){return po({},t)}function po(t,e){return e&&t&&Dy(Ay,function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function go(t){var e=[];return f(Ey.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=p(e,function(t){return Zi(t).main}),"dataset"!==t&&u(e,"dataset")<=0&&e.unshift("dataset"),e}function vo(t,e){for(var n=t.length,i=0;n>i;i++)if(t[i].length>e)return t[i];return t[n-1]}function mo(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSysDims:[],axisMap:N(),categoryAxisMap:N()},i=Vy[e];return i?(i(t,n,n.axisMap,n.categoryAxisMap),n):void 0}function yo(t){return"category"===t.get("type")}function _o(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===Gy?{}:[]),this.sourceFormat=t.sourceFormat||jy,this.seriesLayoutBy=t.seriesLayoutBy||Zy,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&N(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}function xo(t){return Yy(t).source}function wo(t){Yy(t).datasetMap=N()}function bo(t){var e=t.option,n=e.data,i=T(n)?Uy:Fy,r=!1,a=e.seriesLayoutBy,o=e.sourceHeader,s=e.dimensions,l=Do(t);if(l){var u=l.option;n=u.source,i=Yy(l).sourceFormat,r=!0,a=a||u.seriesLayoutBy,null==o&&(o=u.sourceHeader),s=s||u.dimensions}var h=So(n,i,a,o,s),c=e.encode;!c&&l&&(c=Co(t,l,n,i,a,h)),Yy(t).source=new _o({data:n,fromDataset:r,seriesLayoutBy:a,sourceFormat:i,dimensionsDefine:h.dimensionsDefine,startIndex:h.startIndex,dimensionsDetectCount:h.dimensionsDetectCount,encodeDefine:c})}function So(t,e,n,i,r){if(!t)return{dimensionsDefine:Mo(r)};var a,o,s;if(e===Hy)"auto"===i||null==i?To(function(t){null!=t&&"-"!==t&&(b(t)?null==o&&(o=1):o=0)},n,t,10):o=i?1:0,r||1!==o||(r=[],To(function(t,e){r[e]=null!=t?t:""},n,t)),a=r?r.length:n===Xy?t.length:t[0]?t[0].length:null;else if(e===Wy)r||(r=Io(t),s=!0);else if(e===Gy)r||(r=[],s=!0,f(t,function(t,e){r.push(e)}));else if(e===Fy){var l=Ri(t[0]);a=x(l)&&l.length||1}var u;return s&&f(r,function(t,e){"name"===(S(t)?t.name:t)&&(u=e)}),{startIndex:o,dimensionsDefine:Mo(r),dimensionsDetectCount:a,potentialNameDimIndex:u}}function Mo(t){if(t){var e=N();return p(t,function(t){if(t=o({},S(t)?t:{name:t}),null==t.name)return t;t.name+="",null==t.displayName&&(t.displayName=t.name);var n=e.get(t.name);return n?t.name+="-"+n.count++:e.set(t.name,{count:1}),t})}}function To(t,e,n,i){if(null==i&&(i=1/0),e===Xy)for(var r=0;r<n.length&&i>r;r++)t(n[r]?n[r][0]:null,r);else for(var a=n[0]||[],r=0;r<a.length&&i>r;r++)t(a[r],r)}function Io(t){for(var e,n=0;n<t.length&&!(e=t[n++]););if(e){var i=[];return f(e,function(t,e){i.push(e)}),i}}function Co(t,e,n,i,r,a){var o=mo(t),s={},l=[],u=[],h=t.subType,c=N(["pie","map","funnel"]),d=N(["line","bar","pictorialBar","scatter","effectScatter","candlestick","boxplot"]);if(o&&null!=d.get(h)){var p=t.ecModel,g=Yy(p).datasetMap,v=e.uid+"_"+r,m=g.get(v)||g.set(v,{categoryWayDim:1,valueWayDim:0});f(o.coordSysDims,function(t){if(null==o.firstCategoryDimIndex){var e=m.valueWayDim++;s[t]=e,u.push(e)}else if(o.categoryAxisMap.get(t))s[t]=0,l.push(0);else{var e=m.categoryWayDim++;s[t]=e,u.push(e)}})}else if(null!=c.get(h)){for(var y,_=0;5>_&&null==y;_++)ko(n,i,r,a.dimensionsDefine,a.startIndex,_)||(y=_);if(null!=y){s.value=y;var x=a.potentialNameDimIndex||Math.max(y-1,0);u.push(x),l.push(x)}}return l.length&&(s.itemName=l),u.length&&(s.seriesName=u),s}function Do(t){var e=t.option,n=e.data;return n?void 0:t.ecModel.getComponent("dataset",e.datasetIndex||0)}function Ao(t,e){return ko(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,e)}function ko(t,e,n,i,r,a){function o(t){return null!=t&&isFinite(t)&&""!==t?!1:b(t)&&"-"!==t?!0:void 0}var s,l=5;if(T(t))return!1;var u;if(i&&(u=i[a],u=S(u)?u.name:u),e===Hy)if(n===Xy){for(var h=t[a],c=0;c<(h||[]).length&&l>c;c++)if(null!=(s=o(h[r+c])))return s}else for(var c=0;c<t.length&&l>c;c++){var d=t[r+c];if(d&&null!=(s=o(d[a])))return s}else if(e===Wy){if(!u)return;for(var c=0;c<t.length&&l>c;c++){var f=t[c];if(f&&null!=(s=o(f[u])))return s}}else if(e===Gy){if(!u)return;var h=t[u];if(!h||T(h))return!1;for(var c=0;c<h.length&&l>c;c++)if(null!=(s=o(h[c])))return s}else if(e===Fy)for(var c=0;c<t.length&&l>c;c++){var f=t[c],p=Ri(f);if(!x(p))return!1;if(null!=(s=o(p[a])))return s}return!1}function Po(t,e){if(e){var n=e.seiresIndex,i=e.seriesId,r=e.seriesName;return null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=r&&t.name!==r}}function Lo(t,e){f(e,function(e,n){Ey.hasClass(n)||("object"==typeof e?t[n]=t[n]?r(t[n],e,!1):i(e):null==t[n]&&(t[n]=e))})}function Oo(t){t=t,this.option={},this.option[qy]=1,this._componentsMap=N({series:[]}),this._seriesIndices,this._seriesIndicesMap,Lo(t,this._theme.option),r(t,zy,!1),this.mergeOption(t)}function Eo(t,e){x(e)||(e=e?[e]:[]);var n={};return f(e,function(e){n[e]=(t.get(e)||[]).slice()}),n}function Ro(t,e,n){var i=e.type?e.type:n?n.subType:Ey.determineSubType(t,e);return i}function zo(t,e){t._seriesIndicesMap=N(t._seriesIndices=p(e,function(t){return t.componentIndex})||[])}function Bo(t,e){return e.hasOwnProperty("subType")?v(t,function(t){return t.subType===e.subType}):t}function No(t){f(Ky,function(e){this[e]=y(t[e],t)},this)}function Vo(){this._coordinateSystems=[]}function Fo(t){this._api=t,this._timelineOptions=[],this._mediaList=[],this._mediaDefault,this._currentMediaIndices=[],this._optionBackup,this._newBaseOption}function Ho(t,e,n){var i,r,a=[],o=[],s=t.timeline;if(t.baseOption&&(r=t.baseOption),(s||t.options)&&(r=r||{},a=(t.options||[]).slice()),t.media){r=r||{};var l=t.media;Jy(l,function(t){t&&t.option&&(t.query?o.push(t):i||(i=t))})}return r||(r=t),r.timeline||(r.timeline=s),Jy([r].concat(a).concat(p(o,function(t){return t.option})),function(t){Jy(e,function(e){e(t,n)})}),{baseOption:r,timelineOptions:a,mediaDefault:i,mediaList:o}}function Wo(t,e,n){var i={width:e,height:n,aspectratio:e/n},r=!0;return f(t,function(t,e){var n=e.match(i_);if(n&&n[1]&&n[2]){var a=n[1],o=n[2].toLowerCase();Go(i[o],t,a)||(r=!1)}}),r}function Go(t,e,n){return"min"===n?t>=e:"max"===n?e>=t:t===e}function jo(t,e){return t.join(",")===e.join(",")}function Uo(t,e){e=e||{},Jy(e,function(e,n){if(null!=e){var i=t[n];if(Ey.hasClass(n)){e=Oi(e),i=Oi(i);var r=Bi(i,e);t[n]=e_(r,function(t){return t.option&&t.exist?n_(t.exist,t.option,!0):t.exist||t.option})}else t[n]=n_(i,e,!0)}})}function Zo(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=o_.length;i>n;n++){var a=o_[n],o=e.normal,s=e.emphasis;o&&o[a]&&(t[a]=t[a]||{},t[a].normal?r(t[a].normal,o[a]):t[a].normal=o[a],o[a]=null),s&&s[a]&&(t[a]=t[a]||{},t[a].emphasis?r(t[a].emphasis,s[a]):t[a].emphasis=s[a],s[a]=null)}}function Xo(t,e,n){if(t&&t[e]&&(t[e].normal||t[e].emphasis)){var i=t[e].normal,r=t[e].emphasis;i&&(n?(t[e].normal=t[e].emphasis=null,s(t[e],i)):t[e]=i),r&&(t.emphasis=t.emphasis||{},t.emphasis[e]=r)}}function Yo(t){Xo(t,"itemStyle"),Xo(t,"lineStyle"),Xo(t,"areaStyle"),Xo(t,"label"),Xo(t,"labelLine"),Xo(t,"upperLabel"),Xo(t,"edgeLabel")}function qo(t){var e=a_(t)&&t.textStyle;if(e)for(var n=0,i=Cv.length;i>n;n++){var r=Cv[n];e.hasOwnProperty(r)&&(t[r]=e[r])}}function $o(t){t&&(Yo(t),qo(t.label),t.emphasis&&qo(t.emphasis.label))}function Ko(t){if(a_(t)){Zo(t),Yo(t),qo(t.label),qo(t.upperLabel),qo(t.edgeLabel),t.emphasis&&(qo(t.emphasis.label),qo(t.emphasis.upperLabel),qo(t.emphasis.edgeLabel));var e=t.markPoint;e&&(Zo(e),$o(e));var n=t.markLine;n&&(Zo(n),$o(n));var i=t.markArea;i&&$o(i);var r=t.data;if("graph"===t.type){r=r||t.nodes;var a=t.links||t.edges;if(a&&!T(a))for(var o=0;o<a.length;o++)$o(a[o]);f(t.categories,function(t){Yo(t)})}if(r&&!T(r))for(var o=0;o<r.length;o++)$o(r[o]);var e=t.markPoint;if(e&&e.data)for(var s=e.data,o=0;o<s.length;o++)$o(s[o]);var n=t.markLine;if(n&&n.data)for(var l=n.data,o=0;o<l.length;o++)x(l[o])?($o(l[o][0]),$o(l[o][1])):$o(l[o]);"gauge"===t.type?(qo(t,"axisLabel"),qo(t,"title"),qo(t,"detail")):"treemap"===t.type&&(Xo(t.breadcrumb,"itemStyle"),f(t.levels,function(t){Yo(t)}))}}function Qo(t){return x(t)?t:t?[t]:[]}function Jo(t){return(x(t)?t[0]:t)||{}}function ts(t,e){e=e.split(",");for(var n=t,i=0;i<e.length&&(n=n&&n[e[i]],null!=n);i++);return n}function es(t,e,n,i){e=e.split(",");for(var r,a=t,o=0;o<e.length-1;o++)r=e[o],null==a[r]&&(a[r]={}),a=a[r];(i||null==a[e[o]])&&(a[e[o]]=n)}function ns(t){f(l_,function(e){e[0]in t&&!(e[1]in t)&&(t[e[1]]=t[e[0]])})}function is(t,e){_o.isInstance(t)||(t=_o.seriesDataToSource(t)),this._source=t;var n=this._data=t.data,i=t.sourceFormat;i===Uy&&(this._offset=0,this._dimSize=e,this._data=n);var r=d_[i===Hy?i+"_"+t.seriesLayoutBy:i];o(this,r)}function rs(){return this._data.length}function as(t){return this._data[t]}function os(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}function ss(t,e,n){return null!=n?t[n]:t}function ls(t,e,n,i){return us(t[i],this._dimensionInfos[e])}function us(t,e){var n=e&&e.type;if("ordinal"===n){var i=e&&e.ordinalMeta;return i?i.parseAndCollect(t):t}return"time"===n&&"number"!=typeof t&&null!=t&&"-"!==t&&(t=+Ya(t)),null==t||""===t?0/0:+t}function hs(t,e,n){if(t){var i=t.getRawDataItem(e);if(null!=i){var r,a,o=t.getProvider().getSource().sourceFormat,s=t.getDimensionInfo(n);return s&&(r=s.name,a=s.index),f_[o](i,e,a,r)}}}function cs(t){return new ds(t)}function ds(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0,this.context}function fs(t,e){t._dueIndex=t._outputDueEnd=t._dueEnd=0,t._settedOutputEnd=null,t._progress=!e&&t._reset&&t._reset(t.context);var n=t._downstream;n&&n.dirty()}function ps(t){var e=t.name;Iv===e&&(t.name=gs(t)||e)}function gs(t){var e=t.getRawData(),n=e.mapDimension("seriesName",!0),i=[];return f(n,function(t){var n=e.getDimensionInfo(t);n.displayName&&i.push(n.displayName)}),i.join(" ")}function vs(t){return t.model.getRawData().count()}function ms(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),ys}function ys(t,e){t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function _s(t,e){f(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,_(xs,e))})}function xs(t){var e=ws(t);e&&e.setOutputEnd(this.count())}function ws(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}function bs(){this.group=new Ig,this.uid=Ea("viewChart"),this.renderTask=cs({plan:Ts,reset:Is}),this.renderTask.context={view:this}}function Ss(t,e){if(t&&(t.trigger(e),"group"===t.type))for(var n=0;n<t.childCount();n++)Ss(t.childAt(n),e)}function Ms(t,e,n){var i=Fi(t,e);null!=i?f(Oi(i),function(e){Ss(t.getItemGraphicEl(e),n)}):t.eachItemGraphicEl(function(t){Ss(t,n)})}function Ts(t){return M_(t.model)}function Is(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,a=e.pipelineContext.incrementalRender,o=t.view,s=r&&S_(r).updateMethod,l=a&&o.incrementalPrepareRender?"incrementalPrepareRender":s&&o[s]?s:"render";return o[l](e,n,i,r),a?Cs:null}function Cs(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}function Ds(t,e,n){function i(){h=(new Date).getTime(),c=null,t.apply(o,s||[])}var r,a,o,s,l,u=0,h=0,c=null;e=e||0;var d=function(){r=(new Date).getTime(),o=this,s=arguments;var t=l||e,d=l||n;l=null,a=r-(d?u:h)-t,clearTimeout(c),d?c=setTimeout(i,t):a>=0?i():c=setTimeout(i,-a),u=r};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(t){l=t},d}function As(t,e,n,i){var r=t[e];if(r){var a=r[I_]||r,o=r[D_],s=r[C_];if(s!==n||o!==i){if(null==n||!i)return t[e]=a;r=t[e]=Ds(a,n,"debounce"===i),r[I_]=a,r[D_]=i,r[C_]=n}return r}}function ks(t,e){this.ecInstance=t,this.api=e,this.unfinished,this._stageTaskMap=N()}function Ps(t,e,n,i,r){function a(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}r=r||{};var o;f(e,function(e){if(!r.visualType||r.visualType===e.visualType){var s=t._stageTaskMap.get(e.uid),l=s.seriesTaskMap,u=s.overallTask;if(u){var h,c=u.agentStubMap;c.each(function(t){a(r,t)&&(t.dirty(),h=!0)}),h&&u.dirty(),R_(u,i);var d=t.getPerformArgs(u,r.block);c.each(function(t){t.perform(d)}),o|=u.perform(d)}else l&&l.each(function(s){a(r,s)&&s.dirty();var l=t.getPerformArgs(s,r.block);l.skip=!e.performRawSeries&&n.isSeriesFiltered(s.context.model),R_(s,i),o|=s.perform(l)})}}),t.unfinished|=o}function Ls(t,e,n,i,r){function a(n){var a=n.uid,s=o.get(a)||o.set(a,cs({plan:Ns,reset:Vs,count:Hs}));s.context={model:n,ecModel:i,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:t},Ws(t,n,s)}var o=n.seriesTaskMap||(n.seriesTaskMap=N()),s=e.seriesType,l=e.getTargetSeries;e.createOnAllSeries?i.eachRawSeries(a):s?i.eachRawSeriesByType(s,a):l&&l(i,r).each(a);var u=t._pipelineMap;o.each(function(t,e){u.get(e)||(t.dispose(),o.removeKey(e))})}function Os(t,e,n,i,r){function a(e){var n=e.uid,i=s.get(n)||s.set(n,cs({reset:Rs,onDirty:Bs}));i.context={model:e,overallProgress:h,isOverallFilter:c},i.agent=o,i.__block=h,Ws(t,e,i)}var o=n.overallTask=n.overallTask||cs({reset:Es});o.context={ecModel:i,api:r,overallReset:e.overallReset,scheduler:t};var s=o.agentStubMap=o.agentStubMap||N(),l=e.seriesType,u=e.getTargetSeries,h=!0,c=e.isOverallFilter;l?i.eachRawSeriesByType(l,a):u?u(i,r).each(a):(h=!1,f(i.getSeries(),a));var d=t._pipelineMap;s.each(function(t,e){d.get(e)||(t.dispose(),s.removeKey(e))})}function Es(t){t.overallReset(t.ecModel,t.api,t.payload)}function Rs(t){return t.overallProgress&&zs}function zs(){this.agent.dirty(),this.getDownstream().dirty()}function Bs(){this.agent&&this.agent.dirty()}function Ns(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function Vs(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=Oi(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length?Fs:void 0}function Fs(t,e){for(var n=e.data,i=e.resetDefines,r=0;r<i.length;r++){var a=i[r];if(a&&a.dataEach)for(var o=t.start;o<t.end;o++)a.dataEach(n,o);else a&&a.progress&&a.progress(t,n)}}function Hs(t){return t.data.count()}function Ws(t,e,n){var i=e.uid,r=t._pipelineMap.get(i);!r.head&&(r.head=n),r.tail&&r.tail.pipe(n),r.tail=n,n.__idxInPipeline=r.count++,n.__pipeline=r}function Gs(t){z_=null;try{t(B_,N_)}catch(e){}return z_}function js(t,e){for(var n in e.prototype)t[n]=F}function Us(t){return function(e,n,i){e=e&&e.toLowerCase(),Up.prototype[t].call(this,e,n,i)}}function Zs(){Up.call(this)}function Xs(t,e,n){function r(t,e){return t.__prio-e.__prio}n=n||{},"string"==typeof e&&(e=xx[e]),this.id,this.group,this._dom=t;var a="canvas",o=this._zr=Di(t,{renderer:n.renderer||a,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height});this._throttledZrFlush=Ds(y(o.flush,o),17);var e=i(e);e&&h_(e,!0),this._theme=e,this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._coordSysMgr=new Vo;var s=this._api=dl(this);this._scheduler=new ks(this,s),Up.call(this),this._messageCenter=new Zs,this._initEvents(),this.resize=y(this.resize,this),this._pendingActions=[],dn(_x,r),dn(vx,r),o.animation.on("frame",this._onframe,this),R(this)}function Ys(t,e,n){var i,r=this._model,a=this._coordSysMgr.getCoordinateSystems();e=Wi(r,e);for(var o=0;o<a.length;o++){var s=a[o];if(s[t]&&null!=(i=s[t](r,e,n)))return i}}function qs(t){var e=t._model,n=t._scheduler;n.restorePipelines(e),n.prepareStageTasks(vx),n.prepareStageTasks(_x),nl(t,"component",e,n),nl(t,"chart",e,n),n.plan()}function $s(t,e,n,i,r){function a(i){i&&i.__alive&&i[e]&&i[e](i.__model,o,t._api,n)}var o=t._model;if(!i)return void Z_(t._componentsViews.concat(t._chartsViews),a);var s={};s[i+"Id"]=n[i+"Id"],s[i+"Index"]=n[i+"Index"],s[i+"Name"]=n[i+"Name"];var l={mainType:i,query:s};r&&(l.subType=r),o&&o.eachComponent(l,function(e){a(t["series"===i?"_chartsMap":"_componentsMap"][e.__viewId])},t)}function Ks(t,e,n){t[sx]=!0,e&&qs(t),dx.update.call(t),t[sx]=!1,tl.call(t,n),el.call(t,n)}function Qs(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})}function Js(t,e){var n=t.type,i=t.escapeConnect,r=px[n],a=r.actionInfo,l=(a.update||"update").split(":"),u=l.pop();l=null!=l[0]&&q_(l[0]),this[sx]=!0;var h=[t],c=!1;t.batch&&(c=!0,h=p(t.batch,function(e){return e=s(o({},e),t),e.batch=null,e}));var d,f=[],g="highlight"===n||"downplay"===n;Z_(h,function(t){d=r.action(t,this._model,this._api),d=d||o({},t),d.type=a.event||d.type,f.push(d),g?$s(this,u,t,"series"):l&&$s(this,u,t,l.main,l.sub)},this),"none"===u||g||l||(this[ux]?(qs(this),dx.update.call(this,t),this[ux]=!1):dx[u].call(this,t)),d=c?{type:a.event||n,escapeConnect:i,batch:f}:f[0],this[sx]=!1,!e&&this._messageCenter.trigger(d.type,d)}function tl(t){for(var e=this._pendingActions;e.length;){var n=e.shift();Js.call(this,n,t)}}function el(t){!t&&this.trigger("updated")}function nl(t,e,n,i){function r(t){var e="_ec_"+t.id+"_"+t.type,r=s[e];if(!r){var h=q_(t.type),c=a?x_.getClass(h.main,h.sub):bs.getClass(h.sub);r=new c,r.init(n,u),s[e]=r,o.push(r),l.add(r.group)}t.__viewId=r.__id=e,r.__alive=!0,r.__model=t,r.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},!a&&i.prepareView(r,t,n,u)}for(var a="component"===e,o=a?t._componentsViews:t._chartsViews,s=a?t._componentsMap:t._chartsMap,l=t._zr,u=t._api,h=0;h<o.length;h++)o[h].__alive=!1;a?n.eachComponent(function(t,e){"series"!==t&&r(e)}):n.eachSeries(r);for(var h=0;h<o.length;){var c=o[h];c.__alive?h++:(!a&&c.renderTask.dispose(),l.remove(c.group),c.dispose(n,u),o.splice(h,1),delete s[c.__id],c.__id=c.group.__ecComponentInfo=null)}}function il(t){var e={};t.eachSeries(function(t){var n=t.get("stack"),i=t.getData();if(n&&"list"===i.type){var r=e[n];e.hasOwnProperty(n)&&r&&(i.stackedOn=r),e[n]=i}})}function rl(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})}function al(t,e,n,i){ol(t,e,n,i),Z_(t._chartsViews,function(t){t.__alive=!1}),sl(t,e,n,i),Z_(t._chartsViews,function(t){t.__alive||t.remove(e,n)})}function ol(t,e,n,i,r){Z_(r||t._componentsViews,function(t){var r=t.__model;t.render(r,e,n,i),cl(r,t)})}function sl(t,e,n,i,r){var a,o=t._scheduler;e.eachSeries(function(e){var n=t._chartsMap[e.__viewId];n.__alive=!0;var s=n.renderTask;o.updatePayload(s,i),r&&r.get(e.uid)&&s.dirty(),a|=s.perform(o.getPerformArgs(s)),n.group.silent=!!e.get("silent"),cl(e,n),hl(e,n)}),o.unfinished|=a,ul(t._zr,e),P_(t._zr.dom,e)}function ll(t,e){Z_(yx,function(n){n(t,e)})}function ul(t,e){var n=t.storage,i=0;n.traverse(function(t){t.isGroup||i++}),i>e.get("hoverLayerThreshold")&&!Sp.node&&n.traverse(function(t){t.isGroup||(t.useHoverLayer=!0)})}function hl(t,e){var n=t.get("blendMode")||null;e.group.traverse(function(t){t.isGroup||t.style.blend!==n&&t.setStyle("blend",n),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.setStyle("blend",n)})})}function cl(t,e){var n=t.get("z"),i=t.get("zlevel");e.group.traverse(function(t){"group"!==t.type&&(null!=n&&(t.z=n),null!=i&&(t.zlevel=i))})}function dl(t){var e=t._coordSysMgr;return o(new No(t),{getCoordinateSystems:y(e.getCoordinateSystems,e),getComponentByElement:function(e){for(;e;){var n=e.__ecComponentInfo;if(null!=n)return t._model.getComponent(n.mainType,n.index);e=e.parent}}})}function fl(t){function e(t,e){for(var n=0;n<t.length;n++){var i=t[n];i[a]=e}}var n=0,i=1,r=2,a="__connectUpdateStatus";Z_(gx,function(o,s){t._messageCenter.on(s,function(o){if(Mx[t.group]&&t[a]!==n){if(o&&o.escapeConnect)return;var s=t.makeActionFromEvent(o),l=[];Z_(Sx,function(e){e!==t&&e.group===t.group&&l.push(e)}),e(l,n),Z_(l,function(t){t[a]!==i&&t.dispatchAction(s)}),e(l,r)}})})}function pl(t,e,n){var i=yl(t);if(i)return i;var r=new Xs(t,e,n);return r.id="ec_"+Tx++,Sx[r.id]=r,ji(t,Cx,r.id),fl(r),r}function gl(t){if(x(t)){var e=t;t=null,Z_(e,function(e){null!=e.group&&(t=e.group)}),t=t||"g_"+Ix++,Z_(e,function(e){e.group=t})}return Mx[t]=!0,t}function vl(t){Mx[t]=!1}function ml(t){"string"==typeof t?t=Sx[t]:t instanceof Xs||(t=yl(t)),t instanceof Xs&&!t.isDisposed()&&t.dispose()}function yl(t){return Sx[Ui(t,Cx)]}function _l(t){return Sx[t]}function xl(t,e){xx[t]=e}function wl(t){mx.push(t)}function bl(t,e){Al(vx,t,e,J_)}function Sl(t){yx.push(t)}function Ml(t,e,n){"function"==typeof e&&(n=e,e="");var i=Y_(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,U_(hx.test(i)&&hx.test(e)),px[i]||(px[i]={action:n,actionInfo:t}),gx[e]=i}function Tl(t,e){Vo.register(t,e)}function Il(t){var e=Vo.get(t);return e?e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice():void 0}function Cl(t,e){Al(_x,t,e,ex,"layout")}function Dl(t,e){Al(_x,t,e,ix,"visual")}function Al(t,e,n,i,r){(X_(e)||Y_(e))&&(n=e,e=i);var a=ks.wrapStageHandler(n,r);return a.__prio=e,a.__raw=n,t.push(a),a}function kl(t,e){bx[t]=e}function Pl(t){return Ey.extend(t)}function Ll(t){return x_.extend(t)}function Ol(t){return __.extend(t)}function El(t){return bs.extend(t)}function Rl(t){n("createCanvas",t)}function zl(t,e,n){e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),"string"==typeof e&&(e="undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")()),Dx[t]={geoJson:e,specialAreas:n}}function Bl(t){return Dx[t]}function Nl(t){return t}function Vl(t,e,n,i,r){this._old=t,this._new=e,this._oldKeyGetter=n||Nl,this._newKeyGetter=i||Nl,this.context=r}function Fl(t,e,n,i,r){for(var a=0;a<t.length;a++){var o="_ec_"+r[i](t[a],a),s=e[o];null==s?(n.push(o),e[o]=a):(s.length||(e[o]=s=[s]),s.push(a))}}function Hl(t){var e={},n=e.encode={},i=e.coordDimMap=N(),r=[];f(t.dimensions,function(e){var a=t.getDimensionInfo(e),o=a.coordDim;if(o){var s=n[o];n.hasOwnProperty(o)||(s=n[o]=[]),s[a.coordDimIndex]=e,a.isSysCoord&&Gl(a.type)&&(r[0]=e),i.set(o,1)}Px.each(function(t,e){var i=n[e];n.hasOwnProperty(e)||(i=n[e]=[]);var r=a.otherDims[e];null!=r&&r!==!1&&(i[r]=a.name)})});var a=[];i.each(function(t,e){a=a.concat(n[e])}),e.dataDimsOnCoord=a;var o=n.label;o&&o.length&&(r=o.slice());var s=r.slice(),l=n.tooltip;return l&&l.length&&(s=l.slice()),n.defaultedLabel=r,n.defaultedTooltip=s,e}function Wl(t){return"category"===t?"ordinal":"time"===t?"time":"float"}function Gl(t){return!("ordinal"===t||"time"===t)}function jl(t){var e=typeof Ex.Uint32Array===Ox?Array:Ex.Uint32Array,n=typeof Ex.Uint16Array===Ox?Array:Ex.Uint16Array;return t._rawCount>65535?e:n}function Ul(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function Zl(t,e){f(Bx.concat(e.__wrappedMethods||[]),function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t.__wrappedMethods=e.__wrappedMethods}function Xl(t){return t}function Yl(t){return t<this._count&&t>=0?this._indices[t]:-1}function ql(t,e){var n=t._idList[e];return null==n&&(n=t._getIdFromStore(e)),null==n&&(n=Rx+e),n}function $l(t){return x(t)||(t=[t]),t}function Kl(t,e){var n=t.dimensions,i=new Nx(p(n,t.getDimensionInfo,t),t.hostModel);Zl(i,t);for(var r=i._storage={},a=t._storage,o=0;o<n.length;o++){var s=n[o];a[s]&&(r[s]=u(e,s)>=0?Ql(a[s]):a[s])}return i}function Ql(t){for(var e=new Array(t.length),n=0;n<t.length;n++)e[n]=Ul(t[n]);return e}function Jl(t,e,n){function r(t,e,n){null!=Px.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,h.set(e,!0))}_o.isInstance(e)||(e=_o.seriesDataToSource(e)),n=n||{},t=(t||[]).slice();for(var a=(n.dimsDef||[]).slice(),l=N(n.encodeDef),u=N(),h=N(),c=[],d=tu(e,t,a,n.dimCount),p=0;d>p;p++){var g=a[p]=o({},S(a[p])?a[p]:{name:a[p]}),v=g.name,m=c[p]={otherDims:{}};null!=v&&null==u.get(v)&&(m.name=m.displayName=v,u.set(v,p)),null!=g.type&&(m.type=g.type),null!=g.displayName&&(m.displayName=g.displayName)}l.each(function(t,e){t=Oi(t).slice();var n=l.set(e,[]);f(t,function(t,i){b(t)&&(t=u.get(t)),null!=t&&d>t&&(n[i]=t,r(c[t],e,i))})});var y=0;f(t,function(t){var e,t,n,a;if(b(t))e=t,t={};else{e=t.name;var o=t.ordinalMeta;t.ordinalMeta=null,t=i(t),t.ordinalMeta=o,n=t.dimsDef,a=t.otherDims,t.name=t.coordDim=t.coordDimIndex=t.dimsDef=t.otherDims=null}var u=Oi(l.get(e));if(!u.length)for(var h=0;h<(n&&n.length||1);h++){for(;y<c.length&&null!=c[y].coordDim;)y++;y<c.length&&u.push(y++)}f(u,function(i,o){var l=c[i];r(s(l,t),e,o),null==l.name&&n&&(l.name=l.displayName=n[o]),l.isSysCoord=!0,a&&s(l.otherDims,a)})});for(var _=n.extraPrefix||"value",x=0;d>x;x++){var m=c[x]=c[x]||{},w=m.coordDim;null==w&&(m.coordDim=eu(_,h,n.extraFromZero),m.coordDimIndex=0,m.isExtraCoord=!0),null==m.name&&(m.name=eu(m.coordDim,u)),null==m.type&&Ao(e,x,m.name)&&(m.type="ordinal")}return c}function tu(t,e,n,i){return null==i&&(i=Math.max(t.dimensionsDetectCount||1,e.length,n.length),f(e,function(t){var e=t.dimsDef;e&&(i=Math.max(i,e.length))})),i}function eu(t,e,n){if(n||null!=e.get(t)){for(var i=0;null!=e.get(t+i);)i++;t+=i}return e.set(t,!0),t}function nu(t,e){_o.isInstance(t)||(t=_o.seriesDataToSource(t));var n,i=e.get("coordinateSystem"),r=Vo.get(i),a=mo(e);a&&(n=p(a.coordSysDims,function(t){var e={name:t},n=a.axisMap.get(t);if(n){var i=n.get("type");e.type=Wl(i),e.stackable=iu(i)}return e})),n||(n=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||["x","y"]);var o,s,l=Hx(t,{coordDimensions:n});a&&f(l,function(t,e){var n=t.coordDim,i=a.categoryAxisMap.get(n);i&&(null==o&&(o=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(s=!0)}),s||null==o||(l[o].otherDims.itemName=0);var u=new Nx(l,e),h=null!=o&&ru(t)?function(t,e,n,i){return i===o?n:this.defaultDimValueGetter(t,e,n,i)}:null;return u.hasItemOption=!1,u.initData(t,null,h),u}function iu(t){return"category"!==t&&"time"!==t}function ru(t){if(t.sourceFormat===Fy){var e=au(t.data||[]);return null!=e&&!x(Ri(e))}}function au(t){for(var e=0;e<t.length&&null==t[e];)e++;return t[e]}function ou(t){this._setting=t||{},this._extent=[1/0,-1/0],this._interval=0,this.init&&this.init.apply(this,arguments)}function su(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this._map}function lu(t){return t._map||(t._map=N(t.categories))}function uu(t){return S(t)&&null!=t.value?t.value:t+""}function hu(t,e,n,i){var r={},a=t[1]-t[0],o=r.interval=Ka(a/e,!0);null!=n&&n>o&&(o=r.interval=n),null!=i&&o>i&&(o=r.interval=i);var s=r.intervalPrecision=cu(o),l=r.niceTickExtent=[Ux(Math.ceil(t[0]/o)*o,s),Ux(Math.floor(t[1]/o)*o,s)];return fu(l,t),r}function cu(t){return Ga(t)+2}function du(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function fu(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),du(t,0,e),du(t,1,e),t[0]>t[1]&&(t[0]=t[1])}function pu(t,e,n,i){var r=[];if(!t)return r;var a=1e4;e[0]<n[0]&&r.push(e[0]);for(var o=n[0];o<=n[1]&&(r.push(o),o=Ux(o+t,i),o!==r[r.length-1]);)if(r.length>a)return[];return e[1]>(r.length?r[r.length-1]:n[1])&&r.push(e[1]),r}function gu(t){return t.get("stack")||Yx+t.seriesIndex}function vu(t){return t.dim+t.index}function mu(t,e){var n=p(t,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=i.getExtent(),a="category"===i.type?i.getBandWidth():Math.abs(r[1]-r[0])/e.count(),o=Va(t.get("barWidth"),a),s=Va(t.get("barMaxWidth"),a),l=t.get("barGap"),u=t.get("barCategoryGap");return{bandWidth:a,barWidth:o,barMaxWidth:s,barGap:l,barCategoryGap:u,axisKey:vu(i),stackId:gu(t)}});return yu(n,e)}function yu(t){var e={};f(t,function(t){var n=t.axisKey,i=t.bandWidth,r=e[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:"20%%",gap:"30%%",stacks:{}},a=r.stacks;e[n]=r;var o=t.stackId;a[o]||r.autoWidthCount++,a[o]=a[o]||{width:0,maxWidth:0};var s=t.barWidth;s&&!a[o].width&&(a[o].width=s,s=Math.min(r.remainedWidth,s),r.remainedWidth-=s);var l=t.barMaxWidth;l&&(a[o].maxWidth=l);var u=t.barGap;null!=u&&(r.gap=u);var h=t.barCategoryGap;null!=h&&(r.categoryGap=h)});var n={};return f(e,function(t,e){n[e]={};var i=t.stacks,r=t.bandWidth,a=Va(t.categoryGap,r),o=Va(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,u=(s-a)/(l+(l-1)*o);u=Math.max(u,0),f(i,function(t){var e=t.maxWidth;e&&u>e&&(e=Math.min(e,s),t.width&&(e=Math.min(e,t.width)),s-=e,t.width=e,l--)}),u=(s-a)/(l+(l-1)*o),u=Math.max(u,0);var h,c=0;f(i,function(t){t.width||(t.width=u),h=t,c+=t.width*(1+o)}),h&&(c-=h.width*o);var d=-c/2;f(i,function(t,i){n[e][i]=n[e][i]||{offset:d,width:t.width},d+=t.width*(1+o)})}),n}function _u(t,e){return lw(t,sw(e))}function xu(t,e){var n,i,r,a=t.type,o=e.getMin(),s=e.getMax(),l=null!=o,u=null!=s,h=t.getExtent();"ordinal"===a?n=e.getCategories().length:(i=e.get("boundaryGap"),x(i)||(i=[i||0,i||0]),"boolean"==typeof i[0]&&(i=[0,0]),i[0]=Va(i[0],1),i[1]=Va(i[1],1),r=h[1]-h[0]||Math.abs(h[0])),null==o&&(o="ordinal"===a?n?0:0/0:h[0]-i[0]*r),null==s&&(s="ordinal"===a?n?n-1:0/0:h[1]+i[1]*r),"dataMin"===o?o=h[0]:"function"==typeof o&&(o=o({min:h[0],max:h[1]})),"dataMax"===s?s=h[1]:"function"==typeof s&&(s=s({min:h[0],max:h[1]})),(null==o||!isFinite(o))&&(o=0/0),(null==s||!isFinite(s))&&(s=0/0),t.setBlank(C(o)||C(s)),e.getNeedCrossZero()&&(o>0&&s>0&&!l&&(o=0),0>o&&0>s&&!u&&(s=0));var c=e.ecModel;if(c){var d=v(c.getSeriesByType("bar"),function(t){return t.getBaseAxis()===e.axis}).length>0;if(("time"===a||"interval"===a)&&d){var f=wu(o,s,e);o=f.min,s=f.max}}return[o,s]}function wu(t,e,n){var i=n.ecModel,r=n.axis.getExtent(),a=r[1]-r[0],o=mu(v(i.getSeriesByType("bar"),function(t){return!i.isSeriesFiltered(t)&&t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type})),s=n.axis.dim+n.axis.index,l=o[s];if(void 0===l)return{min:t,max:e};var u=1/0;f(l,function(t){u=Math.min(t.offset,u)});var h=-1/0;f(l,function(t){h=Math.max(t.offset+t.width,h)});var c=Math.abs(u)+h,d=e-t,p=1-(u+h)/a,g=d/p-d;return e+=g*(h/c),t-=g*(u/c),{min:t,max:e}}function bu(t,e){var n=xu(t,e),i=null!=e.getMin(),r=null!=e.getMax(),a=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var o=t.type;t.setExtent(n[0],n[1]),t.niceExtent({splitNumber:a,fixMin:i,fixMax:r,minInterval:"interval"===o||"time"===o?e.get("minInterval"):null,maxInterval:"interval"===o||"time"===o?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function Su(t,e){if(e=e||t.get("type"))switch(e){case"category":return new jx(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new Xx;default:return(ou.getClass(e)||Xx).create(t)}}function Mu(t,e,n,i,r){var a,o=0,s=0,l=(i-r)/180*Math.PI,u=1;e.length>40&&(u=Math.floor(e.length/40));for(var h=0;h<t.length;h+=u){var c=t[h],d=Mn(e[h],n,"center","top");d.x+=c*Math.cos(l),d.y+=c*Math.sin(l),d.width*=1.3,d.height*=1.3,a?a.intersect(d)?(s++,o=Math.max(o,s)):(a.union(d),s=0):a=d.clone()}return 0===o&&u>1?u:(o+1)*u-1}function Tu(t,e){var n=t.scale,i=n.getTicksLabels(),r=n.getTicks();return"string"==typeof e?(e=function(t){return function(e){return t.replace("{value}",null!=e?e:"")}}(e),p(i,e)):"function"==typeof e?p(r,function(n,i){return e(Iu(t,n),i)},this):i}function Iu(t,e){return"category"===t.type?t.scale.getLabel(e):e}function Cu(t,e){if("image"!==this.type){var n=this.style,i=this.shape;i&&"line"===i.symbolType?n.stroke=t:this.__isEmptyBrush?(n.stroke=t,n.fill=e||"#fff"):(n.fill&&(n.fill=t),n.stroke&&(n.stroke=t)),this.dirty(!1)}}function Du(t,e,n,i,r,a,o){var s=0===t.indexOf("empty");s&&(t=t.substr(5,1).toLowerCase()+t.substr(6));var l;return l=0===t.indexOf("image://")?Zr(t.slice(8),new rn(e,n,i,r),o?"center":"cover"):0===t.indexOf("path://")?Ur(t.slice(7),{},new rn(e,n,i,r),o?"center":"cover"):new bw({shape:{symbolType:t,x:e,y:n,width:i,height:r}}),l.__isEmptyBrush=s,l.setColor=Cu,l.setColor(a),l}function Au(t){return nu(t.getSource(),t)}function ku(t,e){var n=e;Pa.isInstance(e)||(n=new Pa(e),c(n,pw));var i=Su(n);return i.setExtent(t[0],t[1]),bu(i,n),i}function Pu(t){c(t,pw)}function Lu(t,e){return Math.abs(t-e)<Mw}function Ou(t,e,n){var i=0,r=t[0];if(!r)return!1;for(var a=1;a<t.length;a++){var o=t[a];i+=Sr(r[0],r[1],o[0],o[1],e,n),r=o}var s=t[0];return Lu(r[0],s[0])&&Lu(r[1],s[1])||(i+=Sr(r[0],r[1],s[0],s[1],e,n)),0!==i}function Eu(t,e,n){if(this.name=t,this.geometries=e,n)n=[n[0],n[1]];else{var i=this.getBoundingRect();n=[i.x+i.width/2,i.y+i.height/2]}this.center=n}function Ru(t){if(!t.UTF8Encoding)return t;var e=t.UTF8Scale;null==e&&(e=1024);for(var n=t.features,i=0;i<n.length;i++)for(var r=n[i],a=r.geometry,o=a.coordinates,s=a.encodeOffsets,l=0;l<o.length;l++){var u=o[l];if("Polygon"===a.type)o[l]=zu(u,s[l],e);else if("MultiPolygon"===a.type)for(var h=0;h<u.length;h++){var c=u[h];u[h]=zu(c,s[l][h],e)}}return t.UTF8Encoding=!1,t}function zu(t,e,n){for(var i=[],r=e[0],a=e[1],o=0;o<t.length;o+=2){var s=t.charCodeAt(o)-64,l=t.charCodeAt(o+1)-64;s=s>>1^-(1&s),l=l>>1^-(1&l),s+=r,l+=a,r=s,a=l,i.push([s/n,l/n])}return i}function Bu(t,e){var n=t[1]-t[0],i=e,r=n/i/2;t[0]+=r,t[1]-=r}function Nu(t){return"_EC_"+t}function Vu(t,e){this.id=null==t?"":t,this.inEdges=[],this.outEdges=[],this.edges=[],this.hostGraph,this.dataIndex=null==e?-1:e}function Fu(t,e,n){this.node1=t,this.node2=e,this.dataIndex=null==n?-1:n}function Hu(t){var e=t.mainData,n=t.datas;n||(n={main:e},t.datasAttr={main:"data"}),t.datas=t.mainData=null,Xu(e,n,t),Ew(n,function(n){Ew(e.TRANSFERABLE_METHODS,function(e){n.wrapMethod(e,_(Wu,t))})}),e.wrapMethod("cloneShallow",_(ju,t)),Ew(e.CHANGABLE_METHODS,function(n){e.wrapMethod(n,_(Gu,t))}),O(n[e.dataType]===e)}function Wu(t,e){if(Zu(this)){var n=o({},this[Rw]);n[this.dataType]=e,Xu(e,n,t)}else Yu(e,this.dataType,this[zw],t);return e}function Gu(t,e){return t.struct&&t.struct.update(this),e}function ju(t,e){return Ew(e[Rw],function(n,i){n!==e&&Yu(n.cloneShallow(),i,e,t)}),e}function Uu(t){var e=this[zw];return null==t||null==e?e:e[Rw][t]}function Zu(t){return t[zw]===t}function Xu(t,e,n){t[Rw]={},Ew(e,function(e,i){Yu(e,i,t,n)})}function Yu(t,e,n,i){n[Rw][e]=t,t[zw]=n,t.dataType=e,i.struct&&(t[i.structAttr]=i.struct,i.struct[i.datasAttr[e]]=t),t.getLinkedData=Uu}function qu(t,e){var n=t.mapDimension("defaultedLabel",!0),i=n.length;if(1===i)return hs(t,e,n[0]);if(i){for(var r=[],a=0;a<n.length;a++){var o=hs(t,e,n[a]);r.push(o)}return r.join(" ")}}function $u(t,e){var n=t.getItemVisual(e,"symbolSize");return n instanceof Array?n.slice():[+n,+n]}function Ku(t){return[t[0]/2,t[1]/2]}function Qu(t,e,n){Ig.call(this),this.updateData(t,e,n)}function Ju(t,e){this.parent.drift(t,e)}function th(t){this.group=new Ig,this._symbolCtor=t||Qu}function eh(t,e,n,i){return!(!e||isNaN(e[0])||isNaN(e[1])||i&&i(n)||"none"===t.getItemVisual(n,"symbol"))}function nh(t){var e=t.hostModel;return{itemStyle:e.getModel("itemStyle").getItemStyle(["color"]),hoverItemStyle:e.getModel("emphasis.itemStyle").getItemStyle(),symbolRotate:e.get("symbolRotate"),symbolOffset:e.get("symbolOffset"),hoverAnimation:e.get("hoverAnimation"),labelModel:e.getModel("label"),hoverLabelModel:e.getModel("emphasis.label"),cursorStyle:e.get("cursor")}}function ih(t){return isNaN(+t.cpx1)||isNaN(+t.cpy1)}function rh(t){return"_"+t+"Type"}function ah(t,e,n){var i=e.getItemVisual(n,"color"),r=e.getItemVisual(n,t),a=e.getItemVisual(n,t+"Size");if(r&&"none"!==r){x(a)||(a=[a,a]);var o=Du(r,-a[0]/2,-a[1]/2,a[0],a[1],i);return o.name=t,o}}function oh(t){var e=new Xw({name:"line"});return sh(e.shape,t),e}function sh(t,e){var n=e[0],i=e[1],r=e[2];t.x1=n[0],t.y1=n[1],t.x2=i[0],t.y2=i[1],t.percent=1,r?(t.cpx1=r[0],t.cpy1=r[1]):(t.cpx1=0/0,t.cpy1=0/0)}function lh(){var t=this,e=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),i=t.childOfName("label");if(e||n||!i.ignore){for(var r=1,a=this.parent;a;)a.scale&&(r/=a.scale[0]),a=a.parent;var o=t.childOfName("line");if(this.__dirty||o.__dirty){var s=o.shape.percent,l=o.pointAt(0),u=o.pointAt(s),h=X([],u,l);if(te(h,h),e){e.attr("position",l);var c=o.tangentAt(0);e.attr("rotation",Math.PI/2-Math.atan2(c[1],c[0])),e.attr("scale",[r*s,r*s])}if(n){n.attr("position",u);var c=o.tangentAt(1);n.attr("rotation",-Math.PI/2-Math.atan2(c[1],c[0])),n.attr("scale",[r*s,r*s])}if(!i.ignore){i.attr("position",u);var d,f,p,g=5*r;if("end"===i.__position)d=[h[0]*g+u[0],h[1]*g+u[1]],f=h[0]>.8?"left":h[0]<-.8?"right":"center",p=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";else if("middle"===i.__position){var v=s/2,c=o.tangentAt(v),m=[c[1],-c[0]],y=o.pointAt(v);m[1]>0&&(m[0]=-m[0],m[1]=-m[1]),d=[y[0]+m[0]*g,y[1]+m[1]*g],f="center",p="bottom";var _=-Math.atan2(c[1],c[0]);u[0]<l[0]&&(_=Math.PI+_),i.attr("rotation",_)}else d=[-h[0]*g+l[0],-h[1]*g+l[1]],f=h[0]>.8?"right":h[0]<-.8?"left":"center",p=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";i.attr({style:{textVerticalAlign:i.__verticalAlign||p,textAlign:i.__textAlign||f},position:d,scale:[r,r]})}}}}function uh(t,e,n){Ig.call(this),this._createLine(t,e,n)}function hh(t){this._ctor=t||uh,this.group=new Ig}function ch(t,e,n,i){var r=e.getItemLayout(n);if(gh(r)){var a=new t._ctor(e,n,i);e.setItemGraphicEl(n,a),t.group.add(a)}}function dh(t,e,n,i,r,a){var o=e.getItemGraphicEl(i);return gh(n.getItemLayout(r))?(o?o.updateData(n,r,a):o=new t._ctor(n,r,a),n.setItemGraphicEl(r,o),void t.group.add(o)):void t.group.remove(o)}function fh(t){var e=t.hostModel;return{lineStyle:e.getModel("lineStyle").getLineStyle(),hoverLineStyle:e.getModel("emphasis.lineStyle").getLineStyle(),labelModel:e.getModel("label"),hoverLabelModel:e.getModel("emphasis.label")}}function ph(t){return isNaN(t[0])||isNaN(t[1])}function gh(t){return!ph(t[0])&&!ph(t[1])}function vh(t,e,n){var i=_h(t);i[e]=n}function mh(t,e,n){var i=_h(t),r=i[e];r===n&&(i[e]=null)}function yh(t,e){return!!_h(t)[e]}function _h(t){return t[Kw]||(t[Kw]={})}function xh(t){this.pointerChecker,this._zr=t,this._opt={};var e=y,n=e(wh,this),r=e(bh,this),a=e(Sh,this),o=e(Mh,this),l=e(Th,this);Up.call(this),this.setPointerChecker=function(t){this.pointerChecker=t},this.enable=function(e,u){this.disable(),this._opt=s(i(u)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,preventDefaultMouseMove:!0}),null==e&&(e=!0),(e===!0||"move"===e||"pan"===e)&&(t.on("mousedown",n),t.on("mousemove",r),t.on("mouseup",a)),(e===!0||"scale"===e||"zoom"===e)&&(t.on("mousewheel",o),t.on("pinch",l))},this.disable=function(){t.off("mousedown",n),t.off("mousemove",r),t.off("mouseup",a),t.off("mousewheel",o),t.off("pinch",l)},this.dispose=this.disable,this.isDragging=function(){return this._dragging},this.isPinching=function(){return this._pinching}}function wh(t){if(!(_i(t)||t.target&&t.target.draggable)){var e=t.offsetX,n=t.offsetY;this.pointerChecker&&this.pointerChecker(t,e,n)&&(this._x=e,this._y=n,this._dragging=!0)}}function bh(t){if(!_i(t)&&Ch(this,"moveOnMouseMove",t)&&this._dragging&&"pinch"!==t.gestureEvent&&!yh(this._zr,"globalPan")){var e=t.offsetX,n=t.offsetY,i=this._x,r=this._y,a=e-i,o=n-r;this._x=e,this._y=n,this._opt.preventDefaultMouseMove&&ov(t.event),this.trigger("pan",a,o,i,r,e,n)}}function Sh(t){_i(t)||(this._dragging=!1)}function Mh(t){if(Ch(this,"zoomOnMouseWheel",t)&&0!==t.wheelDelta){var e=t.wheelDelta>0?1.1:1/1.1;Ih.call(this,t,e,t.offsetX,t.offsetY)}}function Th(t){if(!yh(this._zr,"globalPan")){var e=t.pinchScale>1?1.1:1/1.1;Ih.call(this,t,e,t.pinchX,t.pinchY)}}function Ih(t,e,n,i){this.pointerChecker&&this.pointerChecker(t,n,i)&&(ov(t.event),this.trigger("zoom",e,n,i))}function Ch(t,e,n){var i=t._opt[e];return i&&(!b(i)||n.event[i+"Key"])}function Dh(t,e,n){var i=t.target,r=i.position;r[0]+=e,r[1]+=n,i.dirty()}function Ah(t,e,n,i){var r=t.target,a=t.zoomLimit,o=r.position,s=r.scale,l=t.zoom=t.zoom||1;if(l*=e,a){var u=a.min||0,h=a.max||1/0;l=Math.max(Math.min(h,l),u)}var c=l/t.zoom;t.zoom=l,o[0]-=(n-o[0])*(c-1),o[1]-=(i-o[1])*(c-1),s[0]*=c,s[1]*=c,r.dirty()}function kh(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!Qw[i.mainType]&&r&&r.model!==n}function Ph(t,e,n){for(var i,r=t[0],a=t[1],o=t[2],s=1/0,l=n*n,u=.1,h=.1;.9>=h;h+=.1){Jw[0]=nb(r[0],a[0],o[0],h),Jw[1]=nb(r[1],a[1],o[1],h);var c=rb(ib(Jw,e)-l);s>c&&(s=c,i=h)}for(var d=0;32>d;d++){var f=i+u;tb[0]=nb(r[0],a[0],o[0],i),tb[1]=nb(r[1],a[1],o[1],i),eb[0]=nb(r[0],a[0],o[0],f),eb[1]=nb(r[1],a[1],o[1],f);var c=ib(tb,e)-l;if(rb(c)<.01)break;var p=ib(eb,e)-l;u/=2,0>c?p>=0?i+=u:i-=u:p>=0?i-=u:i+=u}return i}function Lh(t,e){return t.getVisual("opacity")||t.getModel().get(e)}function Oh(t,e,n){var i=t.getGraphicEl(),r=Lh(t,e);null!=n&&(null==r&&(r=1),r*=n),i.downplay&&i.downplay(),i.traverse(function(t){"group"!==t.type&&t.setStyle("opacity",r)})}function Eh(t,e){var n=Lh(t,e),i=t.getGraphicEl();i.highlight&&i.highlight(),i.traverse(function(t){"group"!==t.type&&t.setStyle("opacity",n)})}function Rh(t,e,n){var i=t.getZoom(),r=t.getCenter(),a=e.zoom,o=t.dataToPoint(r);if(null!=e.dx&&null!=e.dy){o[0]-=e.dx,o[1]-=e.dy;var r=t.pointToData(o);t.setCenter(r)}if(null!=a){if(n){var s=n.min||0,l=n.max||1/0;a=Math.max(Math.min(i*a,l),s)/i}t.scale[0]*=a,t.scale[1]*=a;var u=t.position,h=(e.originX-u[0])*(a-1),c=(e.originY-u[1])*(a-1);u[0]-=h,u[1]-=c,t.updateTransform();var r=t.pointToData(o);t.setCenter(r),t.setZoom(a*i)}return{center:t.getCenter(),zoom:t.getZoom()}}function zh(t){return t instanceof Array||(t=[t,t]),t}function Bh(t){var e=t.coordinateSystem;if(!e||"view"===e.type){var n=t.getGraph();n.eachNode(function(t){var e=t.getModel();t.setLayout([+e.get("x"),+e.get("y")])}),Nh(n)}}function Nh(t){t.eachEdge(function(t){var e=t.getModel().get("lineStyle.curveness")||0,n=G(t.node1.getLayout()),i=G(t.node2.getLayout()),r=[n,i];+e&&r.push([(n[0]+i[0])/2-(n[1]-i[1])*e,(n[1]+i[1])/2-(i[0]-n[0])*e]),t.setLayout(r)})}function Vh(t){var e=t.coordinateSystem;if(!e||"view"===e.type){var n=e.getBoundingRect(),i=t.getData(),r=i.graph,a=0,o=i.getSum("value"),s=2*Math.PI/(o||i.count()),l=n.width/2+n.x,u=n.height/2+n.y,h=Math.min(n.width,n.height)/2;r.eachNode(function(t){var e=t.getValue("value");a+=s*(o?e:1)/2,t.setLayout([h*Math.cos(a)+l,h*Math.sin(a)+u]),a+=s*(o?e:1)/2}),i.setLayout({cx:l,cy:u}),r.eachEdge(function(t){var e,n=t.getModel().get("lineStyle.curveness")||0,i=G(t.node1.getLayout()),r=G(t.node2.getLayout()),a=(i[0]+r[0])/2,o=(i[1]+r[1])/2;+n&&(n*=3,e=[l*n+a*(1-n),u*n+o*(1-n)]),t.setLayout([i,r,e])})}}function Fh(t,e,n){for(var i=n.rect,r=i.width,a=i.height,o=[i.x+r/2,i.y+a/2],s=null==n.gravity?.1:n.gravity,l=0;l<t.length;l++){var u=t[l];u.p||(u.p=H(r*(Math.random()-.5)+o[0],a*(Math.random()-.5)+o[1])),u.pp=G(u.p),u.edges=null}var h=.6;return{warmUp:function(){h=.5},setFixed:function(e){t[e].fixed=!0},setUnfixed:function(e){t[e].fixed=!1},step:function(n){for(var i=[],r=t.length,a=0;a<e.length;a++){var l=e[a],u=l.n1,c=l.n2;X(i,c.p,u.p);var d=Y(i)-l.d,f=c.w/(u.w+c.w);isNaN(f)&&(f=0),te(i,i),!u.fixed&&gb(u.p,u.p,i,f*d*h),!c.fixed&&gb(c.p,c.p,i,-(1-f)*d*h)}for(var a=0;r>a;a++){var p=t[a];p.fixed||(X(i,o,p.p),gb(p.p,p.p,i,s*h))}for(var a=0;r>a;a++)for(var u=t[a],g=a+1;r>g;g++){var c=t[g];X(i,c.p,u.p);var d=Y(i);0===d&&(j(i,Math.random()-.5,Math.random()-.5),d=1);var v=(u.rep+c.rep)/d/d;!u.fixed&&gb(u.pp,u.pp,i,v),!c.fixed&&gb(c.pp,c.pp,i,-v)}for(var m=[],a=0;r>a;a++){var p=t[a];p.fixed||(X(m,p.p,p.pp),gb(p.p,p.p,m,h),W(p.pp,p.p))}h=.992*h,n&&n(t,e,.01>h)}}}function Hh(){Jp.call(this)}function Wh(t){this.name=t,this.zoomLimit,Jp.call(this),this._roamTransformable=new Hh,this._rawTransformable=new Hh,this._center,this._zoom}function Gh(t,e,n,i){var r=n.seriesModel,a=r?r.coordinateSystem:null;return a===this?a[t](i):null}function jh(t,e,n){var i=t.getBoxLayoutParams();return i.aspect=n,uo(i,{width:e.getWidth(),height:e.getHeight()})}function Uh(t,e,n){var i,r={},a="toggleSelected"===t;return n.eachComponent("legend",function(n){a&&null!=i?n[i?"select":"unSelect"](e.name):(n[t](e.name),i=n.isSelected(e.name));var o=n.getData();f(o,function(t){var e=t.get("name");if("\n"!==e&&""!==e){var i=n.isSelected(e);r[e]=r.hasOwnProperty(e)?r[e]&&i:i}})}),{name:e.name,selected:r}}function Zh(t,e,n){var i=e.getBoxLayoutParams(),r=e.get("padding"),a={width:n.getWidth(),height:n.getHeight()},o=uo(i,a,r);Py(e.get("orient"),t,e.get("itemGap"),o.width,o.height),ho(t,i,a,r)}function Xh(t,e){var n=wy(e.get("padding")),i=e.getItemStyle(["color","opacity"]);i.fill=e.get("backgroundColor");var t=new Ym({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1});return t}function Yh(t,e){e.dispatchAction({type:"legendToggleSelect",name:t})}function qh(t,e,n){var i=n.getZr().storage.getDisplayList()[0];i&&i.useHoverLayer||t.get("legendHoverLink")&&n.dispatchAction({type:"highlight",seriesName:t.name,name:e})}function $h(t,e,n){var i=n.getZr().storage.getDisplayList()[0];i&&i.useHoverLayer||t.get("legendHoverLink")&&n.dispatchAction({type:"downplay",seriesName:t.name,name:e})}function Kh(t,e,n){var i=t.getOrient(),r=[1,1];r[i.index]=0,co(e,n,{type:"box",ignoreSize:r})}function Qh(t,e){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return Jh(n,t,e),n.seriesInvolved&&ec(n,t),n}function Jh(t,e,n){var i=e.getComponent("tooltip"),r=e.getComponent("axisPointer"),a=r.get("link",!0)||[],o=[];kb(n.getCoordinateSystems(),function(n){function s(i,s,l){var h=l.model.getModel("axisPointer",r),d=h.get("show");if(d&&("auto"!==d||i||sc(h))){null==s&&(s=h.get("triggerTooltip")),h=i?tc(l,c,r,e,i,s):h;var f=h.get("snap"),p=lc(l.model),g=s||f||"category"===l.type,v=t.axesInfo[p]={key:p,axis:l,coordSys:n,axisPointerModel:h,triggerTooltip:s,involveSeries:g,snap:f,useHandle:sc(h),seriesModels:[]};u[p]=v,t.seriesInvolved|=g;var m=nc(a,l);if(null!=m){var y=o[m]||(o[m]={axesInfo:{}});y.axesInfo[p]=v,y.mapper=a[m].mapper,v.linkGroup=y}}}if(n.axisPointerEnabled){var l=lc(n.model),u=t.coordSysAxesInfo[l]={};t.coordSysMap[l]=n;var h=n.model,c=h.getModel("tooltip",i);if(kb(n.getAxes(),Pb(s,!1,null)),n.getTooltipAxes&&i&&c.get("show")){var d="axis"===c.get("trigger"),f="cross"===c.get("axisPointer.type"),p=n.getTooltipAxes(c.get("axisPointer.axis"));(d||f)&&kb(p.baseAxes,Pb(s,f?"cross":!0,d)),f&&kb(p.otherAxes,Pb(s,"cross",!1))}}})}function tc(t,e,n,r,a,o){var l=e.getModel("axisPointer"),u={};kb(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){u[t]=i(l.get(t))}),u.snap="category"!==t.type&&!!o,"cross"===l.get("type")&&(u.type="line");var h=u.label||(u.label={});if(null==h.show&&(h.show=!1),"cross"===a&&(h.show=!0,!o)){var c=u.lineStyle=l.get("crossStyle");c&&s(h,c.textStyle)}return t.model.getModel("axisPointer",new Pa(u,n,r))}function ec(t,e){e.eachSeries(function(e){var n=e.coordinateSystem,i=e.get("tooltip.trigger",!0),r=e.get("tooltip.show",!0);n&&"none"!==i&&i!==!1&&"item"!==i&&r!==!1&&e.get("axisPointer.show",!0)!==!1&&kb(t.coordSysAxesInfo[lc(n.model)],function(t){var i=t.axis;n.getAxis(i.dim)===i&&(t.seriesModels.push(e),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=e.getData().count())})},this)}function nc(t,e){for(var n=e.model,i=e.dim,r=0;r<t.length;r++){var a=t[r]||{};if(ic(a[i+"AxisId"],n.id)||ic(a[i+"AxisIndex"],n.componentIndex)||ic(a[i+"AxisName"],n.name))return r}}function ic(t,e){return"all"===t||x(t)&&u(t,e)>=0||t===e}function rc(t){var e=ac(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,a=n.get("status"),o=n.get("value");null!=o&&(o=i.parse(o));var s=sc(n);null==a&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==o||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),r.value=o,s&&(r.status=e.axis.scale.isBlank()?"hide":"show")}}function ac(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[lc(t)]}function oc(t){var e=ac(t);return e&&e.axisPointerModel}function sc(t){return!!t.get("handle.show")}function lc(t){return t.type+"||"+t.id}function uc(t,e,n,i,r){var a=t.axis;if(!a.scale.isBlank()&&a.containData(e)){if(!t.involveSeries)return void n.showPointer(t,e);var s=hc(e,t),l=s.payloadBatch,u=s.snapToValue;l[0]&&null==r.seriesIndex&&o(r,l[0]),!i&&t.snap&&a.containData(u)&&null!=u&&(e=u),n.showPointer(t,e,l,r),n.showTooltip(t,s,u)}}function hc(t,e){var n=e.axis,i=n.dim,r=t,a=[],o=Number.MAX_VALUE,s=-1;return Ob(e.seriesModels,function(e){var l,u,h=e.getData().mapDimension(i,!0);if(e.getAxisTooltipData){var c=e.getAxisTooltipData(h,t,n);u=c.dataIndices,l=c.nestestValue}else{if(u=e.getData().indicesOfNearest(h[0],t,!1,"category"===n.type?.5:null),!u.length)return;l=e.getData().get(h[0],u[0])}if(null!=l&&isFinite(l)){var d=t-l,f=Math.abs(d);o>=f&&((o>f||d>=0&&0>s)&&(o=f,s=d,r=l,a.length=0),Ob(u,function(t){a.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:a,snapToValue:r}}function cc(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function dc(t,e,n,i){var r=n.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,u=lc(l),h=t.map[u];h||(h=t.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(h)),h.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:r.slice()})}}function fc(t,e,n){var i=n.axesInfo=[];Ob(e,function(e,n){var r=e.axisPointerModel.option,a=t[n];a?(!e.useHandle&&(r.status="show"),r.value=a.value,r.seriesDataIndices=(a.payloadBatch||[]).slice()):!e.useHandle&&(r.status="hide"),"show"===r.status&&i.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:r.value})})}function pc(t,e,n,i){if(yc(e)||!t.list.length)return void i({type:"hideTip"});var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}function gc(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",a=Rb(i)[r]||{},o=Rb(i)[r]={};Ob(t,function(t){var e=t.axisPointerModel.option;"show"===e.status&&Ob(e.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;o[e]=t})});var s=[],l=[];f(a,function(t,e){!o[e]&&l.push(t)}),f(o,function(t,e){!a[e]&&s.push(t)}),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,batch:s})}function vc(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}function mc(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function yc(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function _c(t,e,n){if(!Sp.node){var i=e.getZr();Bb(i).records||(Bb(i).records={}),xc(i,e);var r=Bb(i).records[t]||(Bb(i).records[t]={});r.handler=n}}function xc(t,e){function n(n,i){t.on(n,function(n){var r=Mc(e);Nb(Bb(t).records,function(t){t&&i(t,n,r.dispatchAction)}),wc(r.pendings,e)})}Bb(t).initialized||(Bb(t).initialized=!0,n("click",_(Sc,"click")),n("mousemove",_(Sc,"mousemove")),n("globalout",bc))}function wc(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function bc(t,e,n){t.handler("leave",null,n)}function Sc(t,e,n,i){e.handler(t,n,i)}function Mc(t){var e={showTip:[],hideTip:[]},n=function(i){var r=e[i.type];r?r.push(i):(i.dispatchAction=n,t.dispatchAction(i))};return{dispatchAction:n,pendings:e}}function Tc(t,e){if(!Sp.node){var n=e.getZr(),i=(Bb(n).records||{})[t];i&&(Bb(n).records[t]=null)}}function Ic(){}function Cc(t,e,n,i){Dc(Fb(n).lastProp,i)||(Fb(n).lastProp=i,e?ba(n,i,t):(n.stopAnimation(),n.attr(i)))}function Dc(t,e){if(S(t)&&S(e)){var n=!0;return f(e,function(e,i){n=n&&Dc(t[i],e)}),!!n}return t===e}function Ac(t,e){t[e.get("label.show")?"show":"hide"]()}function kc(t){return{position:t.position.slice(),rotation:t.rotation||0}}function Pc(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)})}function Lc(t){var e={componentType:t.mainType};return e[t.mainType+"Index"]=t.componentIndex,e}function Oc(t,e,n,i){var r,a,o=Za(n-t.rotation),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;return Xa(o-Gb/2)?(a=l?"bottom":"top",r="center"):Xa(o-1.5*Gb)?(a=l?"top":"bottom",r="center"):(a="middle",r=1.5*Gb>o&&o>Gb/2?l?"left":"right":l?"right":"left"),{rotation:o,textAlign:r,textVerticalAlign:a}}function Ec(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)}function Rc(t,e,n){var i=t.get("axisLabel.showMinLabel"),r=t.get("axisLabel.showMaxLabel");e=e||[],n=n||[];var a=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],u=n[0],h=n[1],c=n[n.length-1],d=n[n.length-2];i===!1?(zc(a),zc(u)):Bc(a,o)&&(i?(zc(o),zc(h)):(zc(a),zc(u))),r===!1?(zc(s),zc(c)):Bc(l,s)&&(r?(zc(l),zc(d)):(zc(s),zc(c)))}function zc(t){t&&(t.ignore=!0)}function Bc(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=pe([]);return ye(r,r,-t.rotation),n.applyTransform(ve([],r,t.getLocalTransform())),i.applyTransform(ve([],r,e.getLocalTransform())),n.intersect(i)}}function Nc(t){return"middle"===t||"center"===t}function Vc(t,e,n){var i=e.axis;if(e.get("axisTick.show")&&!i.scale.isBlank()){for(var r=e.getModel("axisTick"),a=r.getModel("lineStyle"),o=r.get("length"),l=Yb(r,n.labelInterval),u=i.getTicksCoords(r.get("alignWithLabel")),h=i.scale.getTicks(),c=e.get("axisLabel.showMinLabel"),d=e.get("axisLabel.showMaxLabel"),f=[],p=[],g=t._transform,v=[],m=u.length,y=0;m>y;y++)if(!Xb(i,y,l,m,c,d)){var _=u[y];f[0]=_,f[1]=0,p[0]=_,p[1]=n.tickDirection*o,g&&(ae(f,f,g),ae(p,p,g));var x=new qm(qr({anid:"tick_"+h[y],shape:{x1:f[0],y1:f[1],x2:p[0],y2:p[1]},style:s(a.getLineStyle(),{stroke:e.get("axisLine.lineStyle.color")}),z2:2,silent:!0}));t.group.add(x),v.push(x)}return v}}function Fc(t,e,n){var i=e.axis,r=D(n.axisLabelShow,e.get("axisLabel.show"));if(r&&!i.scale.isBlank()){var a=e.getModel("axisLabel"),o=a.get("margin"),s=i.scale.getTicks(),l=e.getFormattedLabels(),u=(D(n.labelRotate,a.get("rotate"))||0)*Gb/180,h=Zb(n.rotation,u,n.labelDirection),c=e.getCategories(),d=[],p=Ec(e),g=e.get("triggerEvent"),v=e.get("axisLabel.showMinLabel"),m=e.get("axisLabel.showMaxLabel");return f(s,function(r,u){if(!Xb(i,u,n.labelInterval,s.length,v,m)){var f=a;c&&c[r]&&c[r].textStyle&&(f=new Pa(c[r].textStyle,a,e.ecModel));var y=f.getTextColor()||e.get("axisLine.lineStyle.color"),_=i.dataToCoord(r),x=[_,n.labelOffset+n.labelDirection*o],w=i.scale.getLabel(r),b=new Nm({anid:"label_"+r,position:x,rotation:h.rotation,silent:p,z2:10});da(b.style,f,{text:l[u],textAlign:f.getShallow("align",!0)||h.textAlign,textVerticalAlign:f.getShallow("verticalAlign",!0)||f.getShallow("baseline",!0)||h.textVerticalAlign,textFill:"function"==typeof y?y("category"===i.type?w:"value"===i.type?r+"":r,u):y}),g&&(b.eventData=Lc(e),b.eventData.targetType="axisLabel",b.eventData.value=w),t._dumbGroup.add(b),b.updateTransform(),d.push(b),t.group.add(b),b.decomposeTransform()}}),d}}function Hc(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle(),e.fill=null):"shadow"===n&&(e=i.getAreaStyle(),e.stroke=null),e}function Wc(t,e,n,i,r){var a=n.get("value"),o=jc(a,e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get("label.precision"),formatter:n.get("label.formatter")}),s=n.getModel("label"),l=wy(s.get("padding")||0),u=s.getFont(),h=Mn(o,u),c=r.position,d=h.width+l[1]+l[3],f=h.height+l[0]+l[2],p=r.align;"right"===p&&(c[0]-=d),"center"===p&&(c[0]-=d/2);var g=r.verticalAlign;"bottom"===g&&(c[1]-=f),"middle"===g&&(c[1]-=f/2),Gc(c,d,f,i);var v=s.get("backgroundColor");v&&"auto"!==v||(v=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:d,height:f,r:s.get("borderRadius")},position:c.slice(),style:{text:o,textFont:u,textFill:s.getTextColor(),textPosition:"inside",fill:v,stroke:s.get("borderColor")||"transparent",lineWidth:s.get("borderWidth")||0,shadowBlur:s.get("shadowBlur"),shadowColor:s.get("shadowColor"),shadowOffsetX:s.get("shadowOffsetX"),shadowOffsetY:s.get("shadowOffsetY")},z2:10}}function Gc(t,e,n,i){var r=i.getWidth(),a=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,a)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}function jc(t,e,n,i,r){var a=e.scale.getLabel(t,{precision:r.precision}),o=r.formatter;if(o){var s={value:Iu(e,t),seriesData:[]};f(i,function(t){var e=n.getSeriesByIndex(t.seriesIndex),i=t.dataIndexInside,r=e&&e.getDataParams(i);r&&s.seriesData.push(r)}),b(o)?a=o.replace("{value}",a):w(o)&&(a=o(s))}return a}function Uc(t,e,n){var i=fe();return ye(i,i,n.rotation),me(i,i,n.position),Ta([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function Zc(t,e,n,i,r,a){var o=jb.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get("label.margin"),Wc(e,i,r,a,{position:Uc(i.axis,t,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Xc(t,e,n){return n=n||0,{x1:t[n],y1:t[1-n],x2:e[n],y2:e[1-n]}}function Yc(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}function qc(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,a={},o=r.position,s=r.onZero?"onZero":o,l=r.dim,u=i.getRect(),h=[u.x,u.x+u.width,u.y,u.y+u.height],c={left:0,right:1,top:0,bottom:1,onZero:2},d=e.get("offset")||0,f="x"===l?[h[2]-d,h[3]+d]:[h[0]-d,h[1]+d];if(r.onZero){var p=i.getAxis("x"===l?"y":"x",r.onZeroAxisIndex),g=p.toGlobalCoord(p.dataToCoord(0));f[c.onZero]=Math.max(Math.min(g,f[1]),f[0])}a.position=["y"===l?f[c[s]]:h[0],"x"===l?f[c[s]]:h[3]],a.rotation=Math.PI/2*("x"===l?0:1);var v={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=v[o],a.labelOffset=r.onZero?f[c[o]]-f[c.onZero]:0,e.get("axisTick.inside")&&(a.tickDirection=-a.tickDirection),D(n.labelInside,e.get("axisLabel.inside"))&&(a.labelDirection=-a.labelDirection);var m=e.get("axisLabel.rotate");return a.labelRotate="top"===s?-m:m,a.labelInterval=r.getLabelInterval(),a.z2=1,a}function $c(t,e,n,i,r,a){var o=qb.getAxisPointerClass(t.axisPointerClass);if(o){var s=oc(e);s?(t._axisPointer||(t._axisPointer=new o)).render(e,s,i,a):Kc(t,i)}}function Kc(t,e,n){var i=t._axisPointer;i&&i.dispose(e,n),t._axisPointer=null}function Qc(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}function Jc(t){return"x"===t.dim?0:1}function td(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",n="left "+t+"s "+e+",top "+t+"s "+e;return p(eS,function(t){return t+"transition:"+n}).join(";")}function ed(t){var e=[],n=t.get("fontSize"),i=t.getTextColor();return i&&e.push("color:"+i),e.push("font:"+t.getFont()),n&&e.push("line-height:"+Math.round(3*n/2)+"px"),Jb(["decoration","align"],function(n){var i=t.get(n);i&&e.push("text-"+n+":"+i)}),e.join(";")}function nd(t){var e=[],n=t.get("transitionDuration"),i=t.get("backgroundColor"),r=t.getModel("textStyle"),a=t.get("padding");return n&&e.push(td(n)),i&&(Sp.canvasSupported?e.push("background-Color:"+i):(e.push("background-Color:#"+Ne(i)),e.push("filter:alpha(opacity=70)"))),Jb(["width","color","radius"],function(n){var i="border-"+n,r=tS(i),a=t.get(r);null!=a&&e.push(i+":"+a+("color"===n?"":"px"))}),e.push(ed(r)),null!=a&&e.push("padding:"+wy(a).join("px ")+"px"),e.join(";")+";"}function id(t,e){if(Sp.wxa)return null;var n=document.createElement("div"),i=this._zr=e.getZr();this.el=n,this._x=e.getWidth()/2,this._y=e.getHeight()/2,t.appendChild(n),this._container=t,this._show=!1,this._hideTimeout;var r=this;n.onmouseenter=function(){r._enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},n.onmousemove=function(e){if(e=e||window.event,!r._enterable){var n=i.handler;vi(t,e,!0),n.dispatch("mousemove",e)}},n.onmouseleave=function(){r._enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1}}function rd(t){for(var e=t.pop();t.length;){var n=t.pop();n&&(Pa.isInstance(n)&&(n=n.get("tooltip",!0)),"string"==typeof n&&(n={formatter:n}),e=new Pa(n,e,e.ecModel))}return e}function ad(t,e){return t.dispatchAction||y(e.dispatchAction,e)}function od(t,e,n,i,r,a,o){var s=ld(n),l=s.width,u=s.height;return null!=a&&(t+l+a>i?t-=l+a:t+=a),null!=o&&(e+u+o>r?e-=u+o:e+=o),[t,e]}function sd(t,e,n,i,r){var a=ld(n),o=a.width,s=a.height;return t=Math.min(t+o,i)-o,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}function ld(t){var e=t.clientWidth,n=t.clientHeight;if(document.defaultView&&document.defaultView.getComputedStyle){var i=document.defaultView.getComputedStyle(t);i&&(e+=parseInt(i.paddingLeft,10)+parseInt(i.paddingRight,10)+parseInt(i.borderLeftWidth,10)+parseInt(i.borderRightWidth,10),n+=parseInt(i.paddingTop,10)+parseInt(i.paddingBottom,10)+parseInt(i.borderTopWidth,10)+parseInt(i.borderBottomWidth,10))}return{width:e,height:n}}function ud(t,e,n){var i=n[0],r=n[1],a=5,o=0,s=0,l=e.width,u=e.height;switch(t){case"inside":o=e.x+l/2-i/2,s=e.y+u/2-r/2;break;case"top":o=e.x+l/2-i/2,s=e.y-r-a;break;case"bottom":o=e.x+l/2-i/2,s=e.y+u+a;break;case"left":o=e.x-i-a,s=e.y+u/2-r/2;break;case"right":o=e.x+l+a,s=e.y+u/2-r/2}return[o,s]}function hd(t){return"center"===t||"middle"===t}function cd(t,e){sS[t]=e}function dd(t){return sS[t]}function fd(t){return 0===t.indexOf("my")}function pd(t){this.model=t}function gd(t){this.model=t}function vd(t){var e={},n=[],i=[];return t.eachRawSeries(function(t){var r=t.coordinateSystem;if(!r||"cartesian2d"!==r.type&&"polar"!==r.type)n.push(t);else{var a=r.getBaseAxis();if("category"===a.type){var o=a.dim+"_"+a.index;e[o]||(e[o]={categoryAxis:a,valueAxis:r.getOtherAxis(a),series:[]},i.push({axisDim:a.dim,axisIndex:a.index})),e[o].series.push(t)}else n.push(t)}}),{seriesGroupByCategoryAxis:e,other:n,meta:i}}function md(t){var e=[];return f(t,function(t){var n=t.categoryAxis,i=t.valueAxis,r=i.dim,a=[" "].concat(p(t.series,function(t){return t.name})),o=[n.model.getCategories()];f(t.series,function(t){o.push(t.getRawData().mapArray(r,function(t){return t}))});for(var s=[a.join(mS)],l=0;l<o[0].length;l++){for(var u=[],h=0;h<o.length;h++)u.push(o[h][l]);s.push(u.join(mS))}e.push(s.join("\n"))}),e.join("\n\n"+vS+"\n\n")}function yd(t){return p(t,function(t){var e=t.getRawData(),n=[t.name],i=[];return e.each(e.dimensions,function(){for(var t=arguments.length,r=arguments[t-1],a=e.getName(r),o=0;t-1>o;o++)i[o]=arguments[o];n.push((a?a+mS:"")+i.join(mS))}),n.join("\n")}).join("\n\n"+vS+"\n\n")}function _d(t){var e=vd(t);return{value:v([md(e.seriesGroupByCategoryAxis),yd(e.other)],function(t){return t.replace(/[\n\t\s]/g,"")}).join("\n\n"+vS+"\n\n"),meta:e.meta}}function xd(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function wd(t){var e=t.slice(0,t.indexOf("\n"));return e.indexOf(mS)>=0?!0:void 0}function bd(t){for(var e=t.split(/\n+/g),n=xd(e.shift()).split(yS),i=[],r=p(n,function(t){return{name:t,data:[]}}),a=0;a<e.length;a++){var o=xd(e[a]).split(yS);i.push(o.shift());for(var s=0;s<o.length;s++)r[s]&&(r[s].data[a]=o[s])}return{series:r,categories:i}}function Sd(t){for(var e=t.split(/\n+/g),n=xd(e.shift()),i=[],r=0;r<e.length;r++){var a,o=xd(e[r]).split(yS),s="",l=!1;isNaN(o[0])?(l=!0,s=o[0],o=o.slice(1),i[r]={name:s,value:[]},a=i[r].value):a=i[r]=[];for(var u=0;u<o.length;u++)a.push(+o[u]);1===a.length&&(l?i[r].value=a[0]:i[r]=a[0])}return{name:n,data:i}}function Md(t,e){var n=t.split(new RegExp("\n*"+vS+"\n*","g")),i={series:[]};return f(n,function(t,n){if(wd(t)){var r=bd(t),a=e[n],o=a.axisDim+"Axis";a&&(i[o]=i[o]||[],i[o][a.axisIndex]={data:r.categories},i.series=i.series.concat(r.series))}else{var r=Sd(t);i.series.push(r)}}),i}function Td(t){this._dom=null,this.model=t}function Id(t,e){return p(t,function(t,n){var i=e&&e[n];return S(i)&&!x(i)?(S(t)&&!x(t)&&(t=t.value),s({value:t},i)):t})}function Cd(t){Up.call(this),this._zr=t,this.group=new Ig,this._brushType,this._brushOption,this._panels,this._track=[],this._dragging,this._covers=[],this._creatingCover,this._creatingPanel,this._enableGlobalPan,this._uid="brushController_"+LS++,this._handlers={},xS(OS,function(t,e){this._handlers[e]=y(t,this)},this)}function Dd(t,e){var n=t._zr;t._enableGlobalPan||vh(n,DS,t._uid),xS(t._handlers,function(t,e){n.on(e,t)}),t._brushType=e.brushType,t._brushOption=r(i(PS),e,!0)}function Ad(t){var e=t._zr;mh(e,DS,t._uid),xS(t._handlers,function(t,n){e.off(n,t)}),t._brushType=t._brushOption=null}function kd(t,e){var n=ES[e.brushType].createCover(t,e);return n.__brushOption=e,Od(n,e),t.group.add(n),n}function Pd(t,e){var n=Rd(e);return n.endCreating&&(n.endCreating(t,e),Od(e,e.__brushOption)),e}function Ld(t,e){var n=e.__brushOption;Rd(e).updateCoverShape(t,e,n.range,n)}function Od(t,e){var n=e.z;null==n&&(n=TS),t.traverse(function(t){t.z=n,t.z2=n})}function Ed(t,e){Rd(e).updateCommon(t,e),Ld(t,e)}function Rd(t){return ES[t.__brushOption.brushType]}function zd(t,e,n){var i=t._panels;if(!i)return!0;var r,a=t._transform;return xS(i,function(t){t.isTargetByCursor(e,n,a)&&(r=t)}),r}function Bd(t,e){var n=t._panels;if(!n)return!0;var i=e.__brushOption.panelId;return null!=i?n[i]:!0}function Nd(t){var e=t._covers,n=e.length;return xS(e,function(e){t.group.remove(e)},t),e.length=0,!!n}function Vd(t,e){var n=wS(t._covers,function(t){var e=t.__brushOption,n=i(e.range);return{brushType:e.brushType,panelId:e.panelId,range:n}});t.trigger("brush",n,{isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function Fd(t){var e=t._track;if(!e.length)return!1;var n=e[e.length-1],i=e[0],r=n[0]-i[0],a=n[1]-i[1],o=MS(r*r+a*a,.5);return o>IS}function Hd(t){var e=t.length-1;return 0>e&&(e=0),[t[0],t[e]]}function Wd(t,e,n,i){var r=new Ig;return r.add(new Ym({name:"main",style:Zd(n),silent:!0,draggable:!0,cursor:"move",drift:_S(t,e,r,"nswe"),ondragend:_S(Vd,e,{isEnd:!0})})),xS(i,function(n){r.add(new Ym({name:n,style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:_S(t,e,r,n),ondragend:_S(Vd,e,{isEnd:!0})}))}),r}function Gd(t,e,n,i){var r=i.brushStyle.lineWidth||0,a=SS(r,CS),o=n[0][0],s=n[1][0],l=o-r/2,u=s-r/2,h=n[0][1],c=n[1][1],d=h-a+r/2,f=c-a+r/2,p=h-o,g=c-s,v=p+r,m=g+r;Ud(t,e,"main",o,s,p,g),i.transformable&&(Ud(t,e,"w",l,u,a,m),Ud(t,e,"e",d,u,a,m),Ud(t,e,"n",l,u,v,a),Ud(t,e,"s",l,f,v,a),Ud(t,e,"nw",l,u,a,a),Ud(t,e,"ne",d,u,a,a),Ud(t,e,"sw",l,f,a,a),Ud(t,e,"se",d,f,a,a))}function jd(t,e){var n=e.__brushOption,i=n.transformable,r=e.childAt(0);r.useStyle(Zd(n)),r.attr({silent:!i,cursor:i?"move":"default"}),xS(["w","e","n","s","se","sw","ne","nw"],function(n){var r=e.childOfName(n),a=qd(t,n);r&&r.attr({silent:!i,invisible:!i,cursor:i?kS[a]+"-resize":null})})}function Ud(t,e,n,i,r,a,o){var s=e.childOfName(n);s&&s.setShape(tf(Jd(t,e,[[i,r],[i+a,r+o]])))}function Zd(t){return s({strokeNoScale:!0},t.brushStyle)}function Xd(t,e,n,i){var r=[bS(t,n),bS(e,i)],a=[SS(t,n),SS(e,i)];return[[r[0],a[0]],[r[1],a[1]]]}function Yd(t){return Ma(t.group)}function qd(t,e){if(e.length>1){e=e.split("");var n=[qd(t,e[0]),qd(t,e[1])];return("e"===n[0]||"w"===n[0])&&n.reverse(),n.join("")}var i={w:"left",e:"right",n:"top",s:"bottom"},r={left:"w",right:"e",top:"n",bottom:"s"},n=Ia(i[e],Yd(t));return r[n]}function $d(t,e,n,i,r,a,o){var s=i.__brushOption,l=t(s.range),u=Qd(n,a,o);xS(r.split(""),function(t){var e=AS[t];l[e[0]][e[1]]+=u[e[0]]}),s.range=e(Xd(l[0][0],l[1][0],l[0][1],l[1][1])),Ed(n,i),Vd(n,{isEnd:!1})}function Kd(t,e,n,i){var r=e.__brushOption.range,a=Qd(t,n,i);xS(r,function(t){t[0]+=a[0],t[1]+=a[1]}),Ed(t,e),Vd(t,{isEnd:!1})}function Qd(t,e,n){var i=t.group,r=i.transformCoordToLocal(e,n),a=i.transformCoordToLocal(0,0);return[r[0]-a[0],r[1]-a[1]]}function Jd(t,e,n){var r=Bd(t,e);return r&&r!==!0?r.clipPath(n,t._transform):i(n)}function tf(t){var e=bS(t[0][0],t[1][0]),n=bS(t[0][1],t[1][1]),i=SS(t[0][0],t[1][0]),r=SS(t[0][1],t[1][1]);return{x:e,y:n,width:i-e,height:r-n}}function ef(t,e,n){if(t._brushType){var i=t._zr,r=t._covers,a=zd(t,e,n);if(!t._dragging)for(var o=0;o<r.length;o++){var s=r[o].__brushOption;if(a&&(a===!0||s.panelId===a.panelId)&&ES[s.brushType].contain(r[o],n[0],n[1]))return}a&&i.setCursorStyle("crosshair")}}function nf(t){var e=t.event;e.preventDefault&&e.preventDefault()}function rf(t,e,n){return t.childOfName("main").contain(e,n)}function af(t,e,n,r){var a,o=t._creatingCover,s=t._creatingPanel,l=t._brushOption;if(t._track.push(n.slice()),Fd(t)||o){if(s&&!o){"single"===l.brushMode&&Nd(t);var u=i(l);u.brushType=of(u.brushType,s),u.panelId=s===!0?null:s.panelId,o=t._creatingCover=kd(t,u),t._covers.push(o)}if(o){var h=ES[of(t._brushType,s)],c=o.__brushOption;c.range=h.getCreatingRange(Jd(t,o,t._track)),r&&(Pd(t,o),h.updateCommon(t,o)),Ld(t,o),a={isEnd:r}}}else r&&"single"===l.brushMode&&l.removeOnClick&&zd(t,e,n)&&Nd(t)&&(a={isEnd:r,removeOnClick:!0});return a}function of(t,e){return"auto"===t?e.defaultBrushType:t}function sf(t){if(this._dragging){nf(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY),n=af(this,t,e,!0);this._dragging=!1,this._track=[],this._creatingCover=null,n&&Vd(this,n)}}function lf(t){return{createCover:function(e,n){return Wd(_S($d,function(e){var n=[e,[0,100]];return t&&n.reverse(),n},function(e){return e[t]}),e,n,[["w","e"],["n","s"]][t])},getCreatingRange:function(e){var n=Hd(e),i=bS(n[0][t],n[1][t]),r=SS(n[0][t],n[1][t]);return[i,r]},updateCoverShape:function(e,n,i,r){var a,o=Bd(e,n);if(o!==!0&&o.getLinearBrushOtherExtent)a=o.getLinearBrushOtherExtent(t,e._transform);else{var s=e._zr;a=[0,[s.getWidth(),s.getHeight()][1-t]]}var l=[i,a];t&&l.reverse(),Gd(e,n,l,r)},updateCommon:jd,contain:rf}}function uf(t){return t=df(t),function(e){return Da(e,t)}}function hf(t,e){return t=df(t),function(n){var i=null!=e?e:n,r=i?t.width:t.height,a=i?t.x:t.y;return[a,a+(r||0)]}}function cf(t,e,n){return t=df(t),function(i,r){return t.contain(r[0],r[1])&&!kh(i,e,n)}}function df(t){return rn.create(t)}function ff(t,e,n){var i=this._targetInfoList=[],r={},a=gf(e,t);RS(HS,function(t,e){(!n||!n.include||zS(n.include,e)>=0)&&t(a,i,r)})}function pf(t){return t[0]>t[1]&&t.reverse(),t}function gf(t,e){return Wi(t,e,{includeMainTypes:VS})}function vf(t,e,n,i){var r=n.getAxis(["x","y"][t]),a=pf(p([0,1],function(t){return e?r.coordToData(r.toLocalCoord(i[t])):r.toGlobalCoord(r.dataToCoord(i[t]))})),o=[];return o[t]=a,o[1-t]=[0/0,0/0],{values:a,xyMinMax:o}}function mf(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function yf(t,e){var n=_f(t),i=_f(e),r=[n[0]/i[0],n[1]/i[1]];return isNaN(r[0])&&(r[0]=1),isNaN(r[1])&&(r[1]=1),r}function _f(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[0/0,0/0]}function xf(t,e){var n=Mf(t);ZS(e,function(e,i){for(var r=n.length-1;r>=0;r--){var a=n[r];if(a[i])break}if(0>r){var o=t.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(o){var s=o.getPercentRange();n[0][i]={dataZoomId:i,start:s[0],end:s[1]}}}}),n.push(e)}function wf(t){var e=Mf(t),n=e[e.length-1];e.length>1&&e.pop();var i={};return ZS(n,function(t,n){for(var r=e.length-1;r>=0;r--){var t=e[r][n];if(t){i[n]=t;break}}}),i}function bf(t){t[XS]=null}function Sf(t){return Mf(t).length}function Mf(t){var e=t[XS];return e||(e=t[XS]=[{}]),e}function Tf(t,e){var n=t[e]-t[1-e];return{span:Math.abs(n),sign:n>0?-1:0>n?1:e?-1:1}}function If(t,e){return Math.min(e[1],Math.max(e[0],t))}function Cf(t){return u($S,t)>=0}function Df(t,e){t=t.slice();var n=p(t,so);e=(e||[]).slice();var i=p(e,so);return function(r,a){f(t,function(t,o){for(var s={name:t,capital:n[o]},l=0;l<e.length;l++)s[e[l]]=t+i[l];r.call(a,s)})}}function Af(t,e,n){function i(t,e){return u(e.nodes,t)>=0}function r(t,i){var r=!1;return e(function(e){f(n(t,e)||[],function(t){i.records[e.name][t]&&(r=!0)})}),r}function a(t,i){i.nodes.push(t),e(function(e){f(n(t,e)||[],function(t){i.records[e.name][t]=!0})})}return function(n){function o(t){!i(t,s)&&r(t,s)&&(a(t,s),l=!0)}var s={nodes:[],records:{}};if(e(function(t){s.records[t.name]={}}),!n)return s;a(n,s);var l;do l=!1,t(o);while(l);return s}}function kf(t,e,n){var i=[1/0,-1/0];return QS(n,function(t){var n=t.getData();n&&QS(n.mapDimension(e,!0),function(t){var e=n.getApproximateExtent(t);e[0]<i[0]&&(i[0]=e[0]),e[1]>i[1]&&(i[1]=e[1])})}),i[1]<i[0]&&(i=[0/0,0/0]),Pf(t,i),i}function Pf(t,e){var n=t.getAxisModel(),i=n.getMin(!0),r="category"===n.get("type"),a=r&&n.getCategories().length;null!=i&&"dataMin"!==i&&"function"!=typeof i?e[0]=i:r&&(e[0]=a>0?0:0/0);var o=n.getMax(!0);return null!=o&&"dataMax"!==o&&"function"!=typeof o?e[1]=o:r&&(e[1]=a>0?a-1:0/0),n.get("scale",!0)||(e[0]>0&&(e[0]=0),e[1]<0&&(e[1]=0)),e}function Lf(t,e){var n=t.getAxisModel(),i=t._percentWindow,r=t._valueWindow;if(i){var a=ja(r,[0,500]);a=Math.min(a,20);var o=e||0===i[0]&&100===i[1];n.setRange(o?null:+r[0].toFixed(a),o?null:+r[1].toFixed(a))}}function Of(t){var e=t._minMaxSpan={},n=t._dataZoomModel;QS(["min","max"],function(i){e[i+"Span"]=n.get(i+"Span");var r=n.get(i+"ValueSpan");if(null!=r&&(e[i+"ValueSpan"]=r,r=t.getAxisModel().axis.scale.parse(r),null!=r)){var a=t._dataExtent;e[i+"Span"]=Na(a[0]+r,a,[0,100],!0)}})}function Ef(t){var e={};return eM(["start","end","startValue","endValue","throttle"],function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e}function Rf(t,e){var n=t._rangePropMode,i=t.get("rangeMode");eM([["start","startValue"],["end","endValue"]],function(t,r){var a=null!=e[t[0]],o=null!=e[t[1]];a&&!o?n[r]="percent":!a&&o?n[r]="value":i?n[r]=i[r]:a&&(n[r]="percent")})}function zf(t,e,n){(this._brushController=new Cd(n.getZr())).on("brush",y(this._onBrush,this)).mount(),this._isZoomActive}function Bf(t){var e={};return f(["xAxisIndex","yAxisIndex"],function(n){e[n]=t[n],null==e[n]&&(e[n]="all"),(e[n]===!1||"none"===e[n])&&(e[n]=[])}),e}function Nf(t,e){t.setIconStatus("back",Sf(e)>1?"emphasis":"normal")}function Vf(t,e,n,i,r){var a=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(a="dataZoomSelect"===i.key?i.dataZoomSelectActive:!1),n._isZoomActive=a,t.setIconStatus("zoom",a?"emphasis":"normal");var o=new ff(Bf(t.option),e,{include:["grid"]});n._brushController.setPanels(o.makePanelOpts(r,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"})).enableBrush(a?{brushType:"auto",brushStyle:{lineWidth:0,fill:"rgba(0,0,0,0.2)"}}:!1)}function Ff(t){this.model=t}function Hf(t){return dM(t)}function Wf(){if(!gM&&vM){gM=!0;var t=vM.styleSheets;t.length<31?vM.createStyleSheet().addRule(".zrvml","behavior:url(#default#VML)"):t[0].addRule(".zrvml","behavior:url(#default#VML)")}}function Gf(t){return parseInt(t,10)}function jf(t,e){Wf(),this.root=t,this.storage=e;var n=document.createElement("div"),i=document.createElement("div");n.style.cssText="display:inline-block;overflow:hidden;position:relative;width:300px;height:150px;",i.style.cssText="position:absolute;left:0;top:0;",t.appendChild(n),this._vmlRoot=i,this._vmlViewport=n,this.resize();var r=e.delFromStorage,a=e.addToStorage;e.delFromStorage=function(t){r.call(e,t),t&&t.onRemove&&t.onRemove(i)},e.addToStorage=function(t){t.onAdd&&t.onAdd(i),a.call(e,t)},this._firstPaint=!0}function Uf(t){return function(){xg('In IE8.0 VML mode painter not support method "'+t+'"')}}function Zf(t){return document.createElementNS(oT,t)}function Xf(t){return hT(1e4*t)/1e4}function Yf(t){return vT>t&&t>-vT}function qf(t,e){var n=e?t.textFill:t.fill;return null!=n&&n!==uT}function $f(t,e){var n=e?t.textStroke:t.stroke;return null!=n&&n!==uT}function Kf(t,e){e&&Qf(t,"transform","matrix("+lT.call(e,",")+")")}function Qf(t,e,n){(!n||"linear"!==n.type&&"radial"!==n.type)&&t.setAttribute(e,n)}function Jf(t,e,n){t.setAttributeNS("http://www.w3.org/1999/xlink",e,n)}function tp(t,e,n){if(qf(e,n)){var i=n?e.textFill:e.fill;i="transparent"===i?uT:i,"none"!==t.getAttribute("clip-path")&&i===uT&&(i="rgba(0, 0, 0, 0.002)"),Qf(t,"fill",i),Qf(t,"fill-opacity",e.opacity)}else Qf(t,"fill",uT);if($f(e,n)){var r=n?e.textStroke:e.stroke;r="transparent"===r?uT:r,Qf(t,"stroke",r);var a=n?e.textStrokeWidth:e.lineWidth,o=!n&&e.strokeNoScale?e.host.getLineScale():1;Qf(t,"stroke-width",a/o),Qf(t,"paint-order",n?"stroke":"fill"),Qf(t,"stroke-opacity",e.opacity);var s=e.lineDash;s?(Qf(t,"stroke-dasharray",e.lineDash.join(",")),Qf(t,"stroke-dashoffset",hT(e.lineDashOffset||0))):Qf(t,"stroke-dasharray",""),e.lineCap&&Qf(t,"stroke-linecap",e.lineCap),e.lineJoin&&Qf(t,"stroke-linejoin",e.lineJoin),e.miterLimit&&Qf(t,"stroke-miterlimit",e.miterLimit)}else Qf(t,"stroke",uT)}function ep(t){for(var e=[],n=t.data,i=t.len(),r=0;i>r;){var a=n[r++],o="",s=0;switch(a){case sT.M:o="M",s=2;break;case sT.L:o="L",s=2;break;case sT.Q:o="Q",s=4;break;case sT.C:o="C",s=6;break;case sT.A:var l=n[r++],u=n[r++],h=n[r++],c=n[r++],d=n[r++],f=n[r++],p=n[r++],g=n[r++],v=Math.abs(f),m=Yf(v-pT)&&!Yf(v),y=!1;y=v>=pT?!0:Yf(v)?!1:(f>-fT&&0>f||f>fT)==!!g;var _=Xf(l+h*dT(d)),x=Xf(u+c*cT(d));m&&(f=g?pT-1e-4:-pT+1e-4,y=!0,9===r&&e.push("M",_,x));var w=Xf(l+h*dT(d+f)),b=Xf(u+c*cT(d+f));e.push("A",Xf(h),Xf(c),hT(p*gT),+y,+g,w,b);break;case sT.Z:o="Z";break;case sT.R:var w=Xf(n[r++]),b=Xf(n[r++]),S=Xf(n[r++]),M=Xf(n[r++]);e.push("M",w,b,"L",w+S,b,"L",w+S,b+M,"L",w,b+M,"L",w,b)}o&&e.push(o);for(var T=0;s>T;T++)e.push(Xf(n[r++]))}return e.join(" ")}function np(t){return"middle"===t?"middle":"bottom"===t?"baseline":"hanging"}function ip(){}function rp(t,e){for(var n=0,i=e.length,r=0,a=0;i>n;n++){var o=e[n];if(o.removed){for(var s=[],l=a;l<a+o.count;l++)s.push(l);o.indices=s,a+=o.count}else{for(var s=[],l=r;l<r+o.count;l++)s.push(l);o.indices=s,r+=o.count,o.added||(a+=o.count)}}return e}function ap(t){return{newPos:t.newPos,components:t.components.slice(0)}}function op(t,e,n,i,r){this._zrId=t,this._svgRoot=e,this._tagNames="string"==typeof n?[n]:n,this._markLabel=i,this._domName=r||"_dom",this.nextId=0}function sp(t,e){op.call(this,t,e,["linearGradient","radialGradient"],"__gradient_in_use__")}function lp(t,e){op.call(this,t,e,"clipPath","__clippath_in_use__")}function up(t,e){op.call(this,t,e,["filter"],"__filter_in_use__","_shadowDom")}function hp(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY||t.textShadowBlur||t.textShadowOffsetX||t.textShadowOffsetY)}function cp(t){return parseInt(t,10)}function dp(t){return t instanceof Lr?mT:t instanceof oi?yT:t instanceof Nm?_T:mT}function fp(t,e){return e&&t&&e.parentNode!==t}function pp(t,e,n){if(fp(t,e)&&n){var i=n.nextSibling;i?t.insertBefore(e,i):t.appendChild(e)}}function gp(t,e){if(fp(t,e)){var n=t.firstChild;n?t.insertBefore(e,n):t.appendChild(e)}}function vp(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)}function mp(t){return t.__textSvgEl}function yp(t){return t.__svgEl}function _p(t){return function(){xg('In SVG mode painter not support method "'+t+'"')}}var xp=2311,wp=function(){return xp++},bp={};bp="undefined"!=typeof wx?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0}:e(navigator.userAgent);var Sp=bp,Mp={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},Tp={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},Ip=Object.prototype.toString,Cp=Array.prototype,Dp=Cp.forEach,Ap=Cp.filter,kp=Cp.slice,Pp=Cp.map,Lp=Cp.reduce,Op={},Ep=function(){return Op.createCanvas()};Op.createCanvas=function(){return document.createElement("canvas")};var Rp,zp="__ec_primitive__";B.prototype={constructor:B,get:function(t){return this.hasOwnProperty(t)?this[t]:null},set:function(t,e){return this[t]=e},each:function(t,e){void 0!==e&&(t=y(t,e));for(var n in this)this.hasOwnProperty(n)&&t(this[n],n)},removeKey:function(t){delete this[t]}};var Bp=(Object.freeze||Object)({$override:n,clone:i,merge:r,mergeAll:a,extend:o,defaults:s,createCanvas:Ep,getContext:l,indexOf:u,inherits:h,mixin:c,isArrayLike:d,each:f,map:p,reduce:g,filter:v,find:m,bind:y,curry:_,isArray:x,isFunction:w,isString:b,isObject:S,isBuiltInObject:M,isTypedArray:T,isDom:I,eqNaN:C,retrieve:D,retrieve2:A,retrieve3:k,slice:P,normalizeCssArray:L,assert:O,trim:E,setAsPrimitive:R,isPrimitive:z,createHashMap:N,concatArray:V,noop:F}),Np="undefined"==typeof Float32Array?Array:Float32Array,Vp=Y,Fp=q,Hp=ee,Wp=ne,Gp=(Object.freeze||Object)({create:H,copy:W,clone:G,set:j,add:U,scaleAndAdd:Z,sub:X,len:Y,length:Vp,lenSquare:q,lengthSquare:Fp,mul:$,div:K,dot:Q,scale:J,normalize:te,distance:ee,dist:Hp,distanceSquare:ne,distSquare:Wp,negate:ie,lerp:re,applyTransform:ae,min:oe,max:se});le.prototype={constructor:le,_dragStart:function(t){var e=t.target;e&&e.draggable&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.dispatchToElement(ue(e,t),"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var n=t.offsetX,i=t.offsetY,r=n-this._x,a=i-this._y;this._x=n,this._y=i,e.drift(r,a,t),this.dispatchToElement(ue(e,t),"drag",t.event);var o=this.findHover(n,i,e).target,s=this._dropTarget;this._dropTarget=o,e!==o&&(s&&o!==s&&this.dispatchToElement(ue(s,t),"dragleave",t.event),o&&o!==s&&this.dispatchToElement(ue(o,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(ue(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(ue(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var jp=Array.prototype.slice,Up=function(){this._$handlers={}};Up.prototype={constructor:Up,one:function(t,e,n){var i=this._$handlers;if(!e||!t)return this;i[t]||(i[t]=[]);for(var r=0;r<i[t].length;r++)if(i[t][r].h===e)return this;return i[t].push({h:e,one:!0,ctx:n||this}),this},on:function(t,e,n){var i=this._$handlers;if(!e||!t)return this;i[t]||(i[t]=[]);for(var r=0;r<i[t].length;r++)if(i[t][r].h===e)return this;return i[t].push({h:e,one:!1,ctx:n||this}),this},isSilent:function(t){var e=this._$handlers;return e[t]&&e[t].length},off:function(t,e){var n=this._$handlers;if(!t)return this._$handlers={},this;if(e){if(n[t]){for(var i=[],r=0,a=n[t].length;a>r;r++)n[t][r].h!=e&&i.push(n[t][r]);n[t]=i}n[t]&&0===n[t].length&&delete n[t]}else delete n[t];return this},trigger:function(t){if(this._$handlers[t]){var e=arguments,n=e.length;n>3&&(e=jp.call(e,1));for(var i=this._$handlers[t],r=i.length,a=0;r>a;){switch(n){case 1:i[a].h.call(i[a].ctx);break;case 2:i[a].h.call(i[a].ctx,e[1]);break;case 3:i[a].h.call(i[a].ctx,e[1],e[2]);break;default:i[a].h.apply(i[a].ctx,e)}i[a].one?(i.splice(a,1),r--):a++}}return this},triggerWithContext:function(t){if(this._$handlers[t]){var e=arguments,n=e.length;n>4&&(e=jp.call(e,1,e.length-1));for(var i=e[e.length-1],r=this._$handlers[t],a=r.length,o=0;a>o;){switch(n){case 1:r[o].h.call(i);break;case 2:r[o].h.call(i,e[1]);break;case 3:r[o].h.call(i,e[1],e[2]);break;default:r[o].h.apply(i,e)}r[o].one?(r.splice(o,1),a--):o++}}return this}};var Zp="silent";ce.prototype.dispose=function(){};var Xp=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Yp=function(t,e,n,i){Up.call(this),this.storage=t,this.painter=e,this.painterRoot=i,n=n||new ce,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,le.call(this),this.setHandlerProxy(n)};Yp.prototype={constructor:Yp,setHandlerProxy:function(t){this.proxy&&this.proxy.dispose(),t&&(f(Xp,function(e){t.on&&t.on(e,this[e],this)},this),t.handler=this),this.proxy=t},mousemove:function(t){var e=t.zrX,n=t.zrY,i=this._hovered,r=i.target;r&&!r.__zr&&(i=this.findHover(i.x,i.y),r=i.target);var a=this._hovered=this.findHover(e,n),o=a.target,s=this.proxy;s.setCursor&&s.setCursor(o?o.cursor:"default"),r&&o!==r&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(a,"mousemove",t),o&&o!==r&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){this.dispatchToElement(this._hovered,"mouseout",t);var e,n=t.toElement||t.relatedTarget;do n=n&&n.parentNode;while(n&&9!=n.nodeType&&!(e=n===this.painterRoot));!e&&this.trigger("globalout",{event:t})},resize:function(){this._hovered={}},dispatch:function(t,e){var n=this[t];n&&n.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,n){t=t||{};var i=t.target;if(!i||!i.silent){for(var r="on"+e,a=he(e,t,n);i&&(i[r]&&(a.cancelBubble=i[r].call(i,a)),i.trigger(e,a),i=i.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[r]&&t[r].call(t,a),t.trigger&&t.trigger(e,a)}))}},findHover:function(t,e,n){for(var i=this.storage.getDisplayList(),r={x:t,y:e},a=i.length-1;a>=0;a--){var o;if(i[a]!==n&&!i[a].ignore&&(o=de(i[a],t,e))&&(!r.topTarget&&(r.topTarget=i[a]),o!==Zp)){r.target=i[a];break}}return r}},f(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){Yp.prototype[t]=function(e){var n=this.findHover(e.zrX,e.zrY),i=n.target;if("mousedown"===t)this._downEl=i,this._downPoint=[e.zrX,e.zrY],this._upEl=i;else if("mouseup"===t)this._upEl=i;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||Hp(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,t,e)}}),c(Yp,Up),c(Yp,le);var qp="undefined"==typeof Float32Array?Array:Float32Array,$p=(Object.freeze||Object)({create:fe,identity:pe,copy:ge,mul:ve,translate:me,rotate:ye,scale:_e,invert:xe,clone:we}),Kp=pe,Qp=5e-5,Jp=function(t){t=t||{},t.position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},tg=Jp.prototype;tg.transform=null,tg.needLocalTransform=function(){return be(this.rotation)||be(this.position[0])||be(this.position[1])||be(this.scale[0]-1)||be(this.scale[1]-1)},tg.updateTransform=function(){var t=this.parent,e=t&&t.transform,n=this.needLocalTransform(),i=this.transform;return n||e?(i=i||fe(),n?this.getLocalTransform(i):Kp(i),e&&(n?ve(i,t.transform,i):ge(i,t.transform)),this.transform=i,this.invTransform=this.invTransform||fe(),void xe(this.invTransform,i)):void(i&&Kp(i))},tg.getLocalTransform=function(t){return Jp.getLocalTransform(this,t)},tg.setTransform=function(t){var e=this.transform,n=t.dpr||1;e?t.setTransform(n*e[0],n*e[1],n*e[2],n*e[3],n*e[4],n*e[5]):t.setTransform(n,0,0,n,0,0)},tg.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var eg=[];tg.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(ve(eg,t.invTransform,e),e=eg);var n=e[0]*e[0]+e[1]*e[1],i=e[2]*e[2]+e[3]*e[3],r=this.position,a=this.scale;be(n-1)&&(n=Math.sqrt(n)),be(i-1)&&(i=Math.sqrt(i)),e[0]<0&&(n=-n),e[3]<0&&(i=-i),r[0]=e[4],r[1]=e[5],a[0]=n,a[1]=i,this.rotation=Math.atan2(-e[1]/i,e[0]/n)}},tg.getGlobalScale=function(){var t=this.transform;if(!t)return[1,1];var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]),n=Math.sqrt(t[2]*t[2]+t[3]*t[3]);return t[0]<0&&(e=-e),t[3]<0&&(n=-n),[e,n]},tg.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&ae(n,n,i),n},tg.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&ae(n,n,i),n},Jp.getLocalTransform=function(t,e){e=e||[],Kp(e);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,a=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),_e(e,e,i),r&&ye(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=a[0],e[5]+=a[1],e};var ng={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(-Math.pow(2,-10*(t-1))+2)},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),-(n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i)))},elasticOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin(2*(t-e)*Math.PI/i)+1)},elasticInOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?-.5*n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i):n*Math.pow(2,-10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?.5*t*t*((e+1)*t-e):.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-ng.bounceOut(1-t)},bounceOut:function(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return.5>t?.5*ng.bounceIn(2*t):.5*ng.bounceOut(2*t-1)+.5}};Se.prototype={constructor:Se,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)return void(this._pausedTime+=e);var n=(t-this._startTime-this._pausedTime)/this._life;if(!(0>n)){n=Math.min(n,1);var i=this.easing,r="string"==typeof i?ng[i]:i,a="function"==typeof r?r(n):n;return this.fire("frame",a),1==n?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){t="on"+t,this[t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var ig=function(){this.head=null,this.tail=null,this._len=0},rg=ig.prototype;rg.insert=function(t){var e=new ag(t);return this.insertEntry(e),e},rg.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},rg.remove=function(t){var e=t.prev,n=t.next;e?e.next=n:this.head=n,n?n.prev=e:this.tail=e,t.next=t.prev=null,this._len--},rg.len=function(){return this._len},rg.clear=function(){this.head=this.tail=null,this._len=0};var ag=function(t){this.value=t,this.next,this.prev},og=function(t){this._list=new ig,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null},sg=og.prototype;sg.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}o?o.value=e:o=new ag(e),o.key=t,n.insertEntry(o),i[t]=o}return r},sg.get=function(t){var e=this._map[t],n=this._list;return null!=e?(e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value):void 0},sg.clear=function(){this._list.clear(),this._map={}};var lg={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]},ug=new og(20),hg=null,cg=Ve,dg=Fe,fg=(Object.freeze||Object)({parse:Ee,lift:Be,toHex:Ne,fastLerp:Ve,fastMapToColor:cg,lerp:Fe,mapToColor:dg,modifyHSL:He,modifyAlpha:We,stringify:Ge}),pg=Array.prototype.slice,gg=function(t,e,n,i){this._tracks={},this._target=t,this._loop=e||!1,this._getter=n||je,this._setter=i||Ue,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};gg.prototype={when:function(t,e){var n=this._tracks;for(var i in e)if(e.hasOwnProperty(i)){if(!n[i]){n[i]=[];var r=this._getter(this._target,i);if(null==r)continue;0!==t&&n[i].push({time:0,value:Je(r)})}n[i].push({time:t,value:e[i]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].pause();this._paused=!0},resume:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].resume();this._paused=!1},isPaused:function(){return!!this._paused},_doneCallback:function(){this._tracks={},this._clipList.length=0;for(var t=this._doneList,e=t.length,n=0;e>n;n++)t[n].call(this)},start:function(t,e){var n,i=this,r=0,a=function(){r--,r||i._doneCallback()};for(var o in this._tracks)if(this._tracks.hasOwnProperty(o)){var s=nn(this,t,a,this._tracks[o],o,e);s&&(this._clipList.push(s),r++,this.animation&&this.animation.addClip(s),n=s)}if(n){var l=n.onframe;n.onframe=function(t,e){l(t,e);for(var n=0;n<i._onframeList.length;n++)i._onframeList[n](t,e)}}return r||this._doneCallback(),this},stop:function(t){for(var e=this._clipList,n=this.animation,i=0;i<e.length;i++){var r=e[i];t&&r.onframe(this._target,1),n&&n.removeClip(r)}e.length=0},delay:function(t){return this._delay=t,this},done:function(t){return t&&this._doneList.push(t),this},getClips:function(){return this._clipList}};var vg=1;"undefined"!=typeof window&&(vg=Math.max(window.devicePixelRatio||1,1));var mg=0,yg=vg,_g=function(){};1===mg?_g=function(){for(var t in arguments)throw new Error(arguments[t])}:mg>1&&(_g=function(){for(var t in arguments)console.log(arguments[t])});var xg=_g,wg=function(){this.animators=[]};wg.prototype={constructor:wg,animate:function(t,e){var n,i=!1,r=this,a=this.__zr;if(t){var o=t.split("."),s=r;i="shape"===o[0];for(var l=0,h=o.length;h>l;l++)s&&(s=s[o[l]]);s&&(n=s)}else n=r;if(!n)return void xg('Property "'+t+'" is not existed in element '+r.id);var c=r.animators,d=new gg(n,e);return d.during(function(){r.dirty(i)}).done(function(){c.splice(u(c,d),1)}),c.push(d),a&&a.animation.addAnimator(d),d},stopAnimation:function(t){for(var e=this.animators,n=e.length,i=0;n>i;i++)e[i].stop(t);return e.length=0,this},animateTo:function(t,e,n,i,r,a){function o(){l--,l||r&&r()}b(n)?(r=i,i=n,n=0):w(i)?(r=i,i="linear",n=0):w(n)?(r=n,n=0):w(e)?(r=e,e=500):e||(e=500),this.stopAnimation(),this._animateToShallow("",this,t,e,n);var s=this.animators.slice(),l=s.length;l||r&&r();for(var u=0;u<s.length;u++)s[u].done(o).start(i,a)},_animateToShallow:function(t,e,n,i,r){var a={},o=0;for(var s in n)if(n.hasOwnProperty(s))if(null!=e[s])S(n[s])&&!d(n[s])?this._animateToShallow(t?t+"."+s:s,e[s],n[s],i,r):(a[s]=n[s],o++);else if(null!=n[s])if(t){var l={};l[t]={},l[t][s]=n[s],this.attr(l)}else this.attr(s,n[s]);return o>0&&this.animate(t,!1).when(null==i?500:i,a).delay(r||0),this}};var bg=function(t){Jp.call(this,t),Up.call(this,t),wg.call(this,t),this.id=t.id||wp()};bg.prototype={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,isGroup:!1,drift:function(t,e){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=t,n[5]+=e,this.decomposeTransform(),this.dirty(!1)},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(){},attrKV:function(t,e){if("position"===t||"scale"===t||"origin"===t){if(e){var n=this[t];n||(n=this[t]=[]),n[0]=e[0],n[1]=e[1]}}else this[t]=e},hide:function(){this.ignore=!0,this.__zr&&this.__zr.refresh()},show:function(){this.ignore=!1,this.__zr&&this.__zr.refresh()},attr:function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(S(t))for(var n in t)t.hasOwnProperty(n)&&this.attrKV(n,t[n]);return this.dirty(!1),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),this.clipPath=t,t.__zr=e,t.__clipTarget=this,this.dirty(!1)},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty(!1))},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.addAnimator(e[n]);this.clipPath&&this.clipPath.addSelfToZr(t)},removeSelfFromZr:function(t){this.__zr=null;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.removeAnimator(e[n]);this.clipPath&&this.clipPath.removeSelfFromZr(t)}},c(bg,wg),c(bg,Jp),c(bg,Up);var Sg=ae,Mg=Math.min,Tg=Math.max;rn.prototype={constructor:rn,union:function(t){var e=Mg(t.x,this.x),n=Mg(t.y,this.y);this.width=Tg(t.x+t.width,this.x+this.width)-e,this.height=Tg(t.y+t.height,this.y+this.height)-n,this.x=e,this.y=n},applyTransform:function(){var t=[],e=[],n=[],i=[];return function(r){if(r){t[0]=n[0]=this.x,t[1]=i[1]=this.y,e[0]=i[0]=this.x+this.width,e[1]=n[1]=this.y+this.height,Sg(t,t,r),Sg(e,e,r),Sg(n,n,r),Sg(i,i,r),this.x=Mg(t[0],e[0],n[0],i[0]),this.y=Mg(t[1],e[1],n[1],i[1]);var a=Tg(t[0],e[0],n[0],i[0]),o=Tg(t[1],e[1],n[1],i[1]);this.width=a-this.x,this.height=o-this.y}}}(),calculateTransform:function(t){var e=this,n=t.width/e.width,i=t.height/e.height,r=fe();return me(r,r,[-e.x,-e.y]),_e(r,r,[n,i]),me(r,r,[t.x,t.y]),r},intersect:function(t){if(!t)return!1;t instanceof rn||(t=rn.create(t));var e=this,n=e.x,i=e.x+e.width,r=e.y,a=e.y+e.height,o=t.x,s=t.x+t.width,l=t.y,u=t.y+t.height;return!(o>i||n>s||l>a||r>u)},contain:function(t,e){var n=this;return t>=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},clone:function(){return new rn(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},rn.create=function(t){return new rn(t.x,t.y,t.width,t.height)};var Ig=function(t){t=t||{},bg.call(this,t);for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};Ig.prototype={constructor:Ig,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,n=0;n<e.length;n++)if(e[n].name===t)return e[n]},childCount:function(){return this._children.length},add:function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},addBefore:function(t,e){if(t&&t!==this&&t.parent!==this&&e&&e.parent===this){var n=this._children,i=n.indexOf(e);i>=0&&(n.splice(i,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__storage,n=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof Ig&&t.addChildrenToStorage(e)),n&&n.refresh()},remove:function(t){var e=this.__zr,n=this.__storage,i=this._children,r=u(i,t);return 0>r?this:(i.splice(r,1),t.parent=null,n&&(n.delFromStorage(t),t instanceof Ig&&t.delChildrenFromStorage(n)),e&&e.refresh(),this)},removeAll:function(){var t,e,n=this._children,i=this.__storage;for(e=0;e<n.length;e++)t=n[e],i&&(i.delFromStorage(t),t instanceof Ig&&t.delChildrenFromStorage(i)),t.parent=null;return n.length=0,this},eachChild:function(t,e){for(var n=this._children,i=0;i<n.length;i++){var r=n[i];t.call(e,r,i)}return this},traverse:function(t,e){for(var n=0;n<this._children.length;n++){var i=this._children[n];t.call(e,i),"group"===i.type&&i.traverse(t,e)}return this},addChildrenToStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.addToStorage(n),n instanceof Ig&&n.addChildrenToStorage(t)}},delChildrenFromStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.delFromStorage(n),n instanceof Ig&&n.delChildrenFromStorage(t)}},dirty:function(){return this.__dirty=!0,this.__zr&&this.__zr.refresh(),this},getBoundingRect:function(t){for(var e=null,n=new rn(0,0,0,0),i=t||this._children,r=[],a=0;a<i.length;a++){var o=i[a];if(!o.ignore&&!o.invisible){var s=o.getBoundingRect(),l=o.getLocalTransform(r);l?(n.copy(s),n.applyTransform(l),e=e||n.clone(),e.union(n)):(e=e||s.clone(),e.union(s))}}return e||n}},h(Ig,bg);var Cg=32,Dg=7,Ag=function(){this._roots=[],this._displayList=[],this._displayListLen=0};Ag.prototype={constructor:Ag,traverse:function(t,e){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,e)},getDisplayList:function(t,e){return e=e||!1,t&&this.updateDisplayList(e),this._displayList},updateDisplayList:function(t){this._displayListLen=0;for(var e=this._roots,n=this._displayList,i=0,r=e.length;r>i;i++)this._updateAndAddDisplayable(e[i],null,t);n.length=this._displayListLen,Sp.canvasSupported&&dn(n,fn)},_updateAndAddDisplayable:function(t,e,n){if(!t.ignore||n){t.beforeUpdate(),t.__dirty&&t.update(),t.afterUpdate();var i=t.clipPath;if(i){e=e?e.slice():[];for(var r=i,a=t;r;)r.parent=a,r.updateTransform(),e.push(r),a=r,r=r.clipPath}if(t.isGroup){for(var o=t._children,s=0;s<o.length;s++){var l=o[s];t.__dirty&&(l.__dirty=!0),this._updateAndAddDisplayable(l,e,n)}t.__dirty=!1}else t.__clipPaths=e,this._displayList[this._displayListLen++]=t}},addRoot:function(t){t.__storage!==this&&(t instanceof Ig&&t.addChildrenToStorage(this),this.addToStorage(t),this._roots.push(t))},delRoot:function(t){if(null==t){for(var e=0;e<this._roots.length;e++){var n=this._roots[e];n instanceof Ig&&n.delChildrenFromStorage(this)}return this._roots=[],this._displayList=[],void(this._displayListLen=0)}if(t instanceof Array)for(var e=0,i=t.length;i>e;e++)this.delRoot(t[e]);else{var r=u(this._roots,t);r>=0&&(this.delFromStorage(t),this._roots.splice(r,1),t instanceof Ig&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:fn};var kg={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},Pg=function(t,e,n){return kg.hasOwnProperty(e)?n*=t.dpr:n},Lg=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],Og=function(t,e){this.extendFrom(t,!1),this.host=e};Og.prototype={constructor:Og,host:null,fill:"#000",stroke:null,opacity:1,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,n){for(var i=this,r=n&&n.style,a=!r,o=0;o<Lg.length;o++){var s=Lg[o],l=s[0];(a||i[l]!==r[l])&&(t[l]=Pg(t,l,i[l]||s[1]))}if((a||i.fill!==r.fill)&&(t.fillStyle=i.fill),(a||i.stroke!==r.stroke)&&(t.strokeStyle=i.stroke),(a||i.opacity!==r.opacity)&&(t.globalAlpha=null==i.opacity?1:i.opacity),(a||i.blend!==r.blend)&&(t.globalCompositeOperation=i.blend||"source-over"),this.hasStroke()){var u=i.lineWidth;t.lineWidth=u/(this.strokeNoScale&&e&&e.getLineScale?e.getLineScale():1)}},hasFill:function(){var t=this.fill;return null!=t&&"none"!==t},hasStroke:function(){var t=this.stroke;return null!=t&&"none"!==t&&this.lineWidth>0},extendFrom:function(t,e){if(t)for(var n in t)!t.hasOwnProperty(n)||e!==!0&&(e===!1?this.hasOwnProperty(n):null==t[n])||(this[n]=t[n])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,n){for(var i="radial"===e.type?gn:pn,r=i(t,e,n),a=e.colorStops,o=0;o<a.length;o++)r.addColorStop(a[o].offset,a[o].color);return r}};for(var Eg=Og.prototype,Rg=0;Rg<Lg.length;Rg++){var zg=Lg[Rg];zg[0]in Eg||(Eg[zg[0]]=zg[1])}Og.getGradient=Eg.getGradient;var Bg=function(t,e){this.image=t,this.repeat=e,this.type="pattern"};Bg.prototype.getCanvasPattern=function(t){return t.createPattern(this.image,this.repeat||"repeat")};var Ng=function(t,e,n){var i;n=n||yg,"string"==typeof t?i=mn(t,e,n):S(t)&&(i=t,t=i.id),this.id=t,this.dom=i;var r=i.style;r&&(i.onselectstart=vn,r["-webkit-user-select"]="none",r["user-select"]="none",r["-webkit-touch-callout"]="none",r["-webkit-tap-highlight-color"]="rgba(0,0,0,0)",r.padding=0,r.margin=0,r["border-width"]=0),this.domBack=null,this.ctxBack=null,this.painter=e,this.config=null,this.clearColor=0,this.motionBlur=!1,this.lastFrameAlpha=.7,this.dpr=n};Ng.prototype={constructor:Ng,__dirty:!0,__used:!1,__drawIndex:0,__startIndex:0,__endIndex:0,incremental:!1,getElementCount:function(){return this.__endIndex-this.__startIndex},initContext:function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},createBackBuffer:function(){var t=this.dpr;this.domBack=mn("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!=t&&this.ctxBack.scale(t,t)},resize:function(t,e){var n=this.dpr,i=this.dom,r=i.style,a=this.domBack;r.width=t+"px",r.height=e+"px",i.width=t*n,i.height=e*n,a&&(a.width=t*n,a.height=e*n,1!=n&&this.ctxBack.scale(n,n))},clear:function(t){var e=this.dom,n=this.ctx,i=e.width,r=e.height,a=this.clearColor,o=this.motionBlur&&!t,s=this.lastFrameAlpha,l=this.dpr;if(o&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(e,0,0,i/l,r/l)),n.clearRect(0,0,i,r),a){var u;a.colorStops?(u=a.__canvasGradient||Og.getGradient(n,a,{x:0,y:0,width:i,height:r}),a.__canvasGradient=u):a.image&&(u=Bg.prototype.getCanvasPattern.call(a,n)),n.save(),n.fillStyle=u||a,n.fillRect(0,0,i,r),n.restore()}if(o){var h=this.domBack;n.save(),n.globalAlpha=s,n.drawImage(h,0,0,i,r),n.restore()}}};var Vg="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)},Fg=new og(50),Hg={},Wg=0,Gg=5e3,jg=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g,Ug="12px sans-serif",Zg={};Zg.measureText=function(t,e){var n=l();return n.font=e||Ug,n.measureText(t)};var Xg={left:1,right:1,center:1},Yg={top:1,bottom:1,middle:1},qg=new rn,$g=function(){};$g.prototype={constructor:$g,drawRectText:function(t,e){var n=this.style;e=n.textRect||e,this.__dirty&&Hn(n,!0);var i=n.text;if(null!=i&&(i+=""),ri(i,n)){t.save();var r=this.transform;n.transformText?this.setTransform(t):r&&(qg.copy(e),qg.applyTransform(r),e=qg),Gn(this,t,i,n,e),t.restore()}}},ai.prototype={constructor:ai,type:"displayable",__dirty:!0,invisible:!1,z:0,z2:0,zlevel:0,draggable:!1,dragging:!1,silent:!1,culling:!1,cursor:"pointer",rectHover:!1,progressive:!1,incremental:!1,inplace:!1,beforeBrush:function(){},afterBrush:function(){},brush:function(){},getBoundingRect:function(){},contain:function(t,e){return this.rectContain(t,e)},traverse:function(t,e){t.call(e,this)},rectContain:function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();return i.contain(n[0],n[1])},dirty:function(){this.__dirty=!0,this._rect=null,this.__zr&&this.__zr.refresh()},animateStyle:function(t){return this.animate("style",t)},attrKV:function(t,e){"style"!==t?bg.prototype.attrKV.call(this,t,e):this.style.set(e)},setStyle:function(t,e){return this.style.set(t,e),this.dirty(!1),this},useStyle:function(t){return this.style=new Og(t,this),this.dirty(!1),this}},h(ai,bg),c(ai,$g),oi.prototype={constructor:oi,type:"image",brush:function(t,e){var n=this.style,i=n.image;n.bind(t,this,e);var r=this._image=_n(i,this._image,this,this.onload);if(r&&wn(r)){var a=n.x||0,o=n.y||0,s=n.width,l=n.height,u=r.width/r.height;if(null==s&&null!=l?s=l*u:null==l&&null!=s?l=s/u:null==s&&null==l&&(s=r.width,l=r.height),this.setTransform(t),n.sWidth&&n.sHeight){var h=n.sx||0,c=n.sy||0;t.drawImage(r,h,c,n.sWidth,n.sHeight,a,o,s,l)}else if(n.sx&&n.sy){var h=n.sx,c=n.sy,d=s-h,f=l-c;t.drawImage(r,h,c,d,f,a,o,s,l)}else t.drawImage(r,a,o,s,l);null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))}},getBoundingRect:function(){var t=this.style;return this._rect||(this._rect=new rn(t.x||0,t.y||0,t.width||0,t.height||0)),this._rect}},h(oi,ai);var Kg=1e5,Qg=314159,Jg=.01,tv=.001,ev=new rn(0,0,0,0),nv=new rn(0,0,0,0),iv=function(t,e,n){this.type="canvas";var i=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=n=o({},n||{}),this.dpr=n.devicePixelRatio||yg,this._singleCanvas=i,this.root=t;var r=t.style;r&&(r["-webkit-tap-highlight-color"]="transparent",r["-webkit-user-select"]=r["user-select"]=r["-webkit-touch-callout"]="none",t.innerHTML=""),this.storage=e;var a=this._zlevelList=[],s=this._layers={};if(this._layerConfig={},this._needsManuallyCompositing=!1,i){null!=n.width&&(t.width=n.width),null!=n.height&&(t.height=n.height);var l=t.width,u=t.height;this._width=l,this._height=u;var h=new Ng(t,this,1);h.__builtin__=!0,h.initContext(),s[Qg]=h,a.push(Qg),this._domRoot=t}else{this._width=this._getSize(0),this._height=this._getSize(1);var c=this._domRoot=di(this._width,this._height);t.appendChild(c)}this._hoverlayer=null,this._hoverElements=[]};iv.prototype={constructor:iv,getType:function(){return"canvas"},isSingleCanvas:function(){return this._singleCanvas},getViewportRoot:function(){return this._domRoot},getViewportRootOffset:function(){var t=this.getViewportRoot();return t?{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}:void 0},refresh:function(t){var e=this.storage.getDisplayList(!0),n=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,t,this._redrawId);for(var i=0;i<n.length;i++){var r=n[i],a=this._layers[r];!a.__builtin__&&a.refresh&&a.refresh()}return this.refreshHover(),this},addHover:function(t,e){if(!t.__hoverMir){var n=new t.constructor({style:t.style,shape:t.shape});n.__from=t,t.__hoverMir=n,n.setStyle(e),this._hoverElements.push(n)}},removeHover:function(t){var e=t.__hoverMir,n=this._hoverElements,i=u(n,e);i>=0&&n.splice(i,1),t.__hoverMir=null},clearHover:function(){for(var t=this._hoverElements,e=0;e<t.length;e++){var n=t[e].__from;n&&(n.__hoverMir=null)}t.length=0},refreshHover:function(){var t=this._hoverElements,e=t.length,n=this._hoverlayer;if(n&&n.clear(),e){dn(t,this.storage.displayableSortFunc),n||(n=this._hoverlayer=this.getLayer(Kg));var i={};n.ctx.save();for(var r=0;e>r;){var a=t[r],o=a.__from;o&&o.__zr?(r++,o.invisible||(a.transform=o.transform,a.invTransform=o.invTransform,a.__clipPaths=o.__clipPaths,this._doPaintEl(a,n,!0,i))):(t.splice(r,1),o.__hoverMir=null,e--)}n.ctx.restore()}},getHoverLayer:function(){return this.getLayer(Kg)},_paintList:function(t,e,n){if(this._redrawId===n){e=e||!1,this._updateLayerStatus(t);var i=this._doPaintList(t,e);if(this._needsManuallyCompositing&&this._compositeManually(),!i){var r=this;Vg(function(){r._paintList(t,e,n)})}}},_compositeManually:function(){var t=this.getLayer(Qg).ctx,e=this._domRoot.width,n=this._domRoot.height;t.clearRect(0,0,e,n),this.eachBuiltinLayer(function(i){i.virtual&&t.drawImage(i.dom,0,0,e,n)})},_doPaintList:function(t,e){for(var n=[],i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i],a=this._layers[r];a.__builtin__&&a!==this._hoverlayer&&(a.__dirty||e)&&n.push(a)}for(var o=!0,s=0;s<n.length;s++){var a=n[s],l=a.ctx,u={};l.save();var h=e?a.__startIndex:a.__drawIndex,c=!e&&a.incremental&&Date.now,d=c&&Date.now();if(a.__startIndex===a.__endIndex)a.clear();else if(h===a.__startIndex){var p=t[h];p.incremental&&p.notClear&&!e||a.clear()}-1===h&&(console.error("For some unknown reason. drawIndex is -1"),h=a.__startIndex);for(var g=h;g<a.__endIndex;g++){var v=t[g];if(this._doPaintEl(v,a,e,u),v.__dirty=!1,c){var m=Date.now()-d;if(m>15)break}}a.__drawIndex=g,a.__drawIndex<a.__endIndex&&(o=!1),u.prevElClipPaths&&l.restore(),l.restore()}return Sp.wxa&&f(this._layers,function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()}),o},_doPaintEl:function(t,e,n,i){var r=e.ctx,a=t.transform;if(!(!e.__dirty&&!n||t.invisible||0===t.style.opacity||a&&!a[0]&&!a[3]||t.culling&&ui(t,this._width,this._height))){var o=t.__clipPaths;(!i.prevElClipPaths||hi(o,i.prevElClipPaths))&&(i.prevElClipPaths&&(e.ctx.restore(),i.prevElClipPaths=null,i.prevEl=null),o&&(r.save(),ci(o,r),i.prevElClipPaths=o)),t.beforeBrush&&t.beforeBrush(r),t.brush(r,i.prevEl||null),i.prevEl=t,t.afterBrush&&t.afterBrush(r)}},getLayer:function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=Qg);var n=this._layers[t];return n||(n=new Ng("zr_"+t,this,this.dpr),n.zlevel=t,n.__builtin__=!0,this._layerConfig[t]&&r(n,this._layerConfig[t],!0),e&&(n.virtual=e),this.insertLayer(t,n),n.initContext()),n},insertLayer:function(t,e){var n=this._layers,i=this._zlevelList,r=i.length,a=null,o=-1,s=this._domRoot;if(n[t])return void xg("ZLevel "+t+" has been used already");if(!li(e))return void xg("Layer of zlevel "+t+" is not valid");if(r>0&&t>i[0]){for(o=0;r-1>o&&!(i[o]<t&&i[o+1]>t);o++);a=n[i[o]]}if(i.splice(o+1,0,t),n[t]=e,!e.virtual)if(a){var l=a.dom;l.nextSibling?s.insertBefore(e.dom,l.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)},eachLayer:function(t,e){var n,i,r=this._zlevelList;for(i=0;i<r.length;i++)n=r[i],t.call(e,this._layers[n],n)},eachBuiltinLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],n=this._layers[i],n.__builtin__&&t.call(e,n,i)},eachOtherLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],n=this._layers[i],n.__builtin__||t.call(e,n,i)},getLayers:function(){return this._layers},_updateLayerStatus:function(t){function e(t){r&&(r.__endIndex!==t&&(r.__dirty=!0),r.__endIndex=t)}if(this.eachBuiltinLayer(function(t){t.__dirty=t.__used=!1}),this._singleCanvas)for(var n=1;n<t.length;n++){var i=t[n];if(i.zlevel!==t[n-1].zlevel||i.incremental){this._needsManuallyCompositing=!0;break}}for(var r=null,a=0,n=0;n<t.length;n++){var o,i=t[n],s=i.zlevel;i.incremental?(o=this.getLayer(s+tv,this._needsManuallyCompositing),o.incremental=!0,a=1):o=this.getLayer(s+(a>0?Jg:0),this._needsManuallyCompositing),o.__builtin__||xg("ZLevel "+s+" has been used by unkown layer "+o.id),o!==r&&(o.__used=!0,o.__startIndex!==n&&(o.__dirty=!0),o.__startIndex=n,o.__drawIndex=o.incremental?-1:n,e(n),r=o),i.__dirty&&(o.__dirty=!0,o.incremental&&o.__drawIndex<0&&(o.__drawIndex=n))}e(n),this.eachBuiltinLayer(function(t){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},configLayer:function(t,e){if(e){var n=this._layerConfig;n[t]?r(n[t],e,!0):n[t]=e;for(var i=0;i<this._zlevelList.length;i++){var a=this._zlevelList[i];if(a===t||a===t+Jg){var o=this._layers[a];r(o,n[t],!0)}}}},delLayer:function(t){var e=this._layers,n=this._zlevelList,i=e[t];i&&(i.dom.parentNode.removeChild(i.dom),delete e[t],n.splice(u(n,t),1))},resize:function(t,e){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var i=this._opts;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width!=t||e!=this._height){n.style.width=t+"px",n.style.height=e+"px";for(var r in this._layers)this._layers.hasOwnProperty(r)&&this._layers[r].resize(t,e);f(this._progressiveLayers,function(n){n.resize(t,e)}),this.refresh(!0)}this._width=t,this._height=e}else{if(null==t||null==e)return;this._width=t,this._height=e,this.getLayer(Qg).resize(t,e)}return this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[Qg].dom;var e=new Ng("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clearColor=t.backgroundColor,e.clear(),t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,i=e.dom.height,r=e.ctx;this.eachLayer(function(t){t.__builtin__?r.drawImage(t.dom,0,0,n,i):t.renderToCanvas&&(e.ctx.save(),t.renderToCanvas(e.ctx),e.ctx.restore())})}else for(var a={},o=this.storage.getDisplayList(!0),s=0;s<o.length;s++){var l=o[s];this._doPaintEl(l,e,!0,a)}return e.dom},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||si(s[n])||si(o.style[n]))-(si(s[r])||0)-(si(s[a])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),r=t.getBoundingRect(),a=t.style,o=a.shadowBlur*e,s=a.shadowOffsetX*e,l=a.shadowOffsetY*e,u=a.hasStroke()?a.lineWidth:0,h=Math.max(u/2,-s+o),c=Math.max(u/2,s+o),d=Math.max(u/2,-l+o),f=Math.max(u/2,l+o),p=r.width+h+c,g=r.height+d+f;n.width=p*e,n.height=g*e,i.scale(e,e),i.clearRect(0,0,p,g),i.dpr=e;var v={position:t.position,rotation:t.rotation,scale:t.scale};t.position=[h-r.x,d-r.y],t.rotation=0,t.scale=[1,1],t.updateTransform(),t&&t.brush(i);var m=oi,y=new m({style:{x:0,y:0,image:n}});return null!=v.position&&(y.position=t.position=v.position),null!=v.rotation&&(y.rotation=t.rotation=v.rotation),null!=v.scale&&(y.scale=t.scale=v.scale),y}};var rv="undefined"!=typeof window&&!!window.addEventListener,av=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ov=rv?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0},sv=function(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time,this._pausedTime,this._pauseStart,this._paused=!1,Up.call(this)};sv.prototype={constructor:sv,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t.animation=this;for(var e=t.getClips(),n=0;n<e.length;n++)this.addClip(e[n])},removeClip:function(t){var e=u(this._clips,t);e>=0&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),n=0;n<e.length;n++)this.removeClip(e[n]);t.animation=null},_update:function(){for(var t=(new Date).getTime()-this._pausedTime,e=t-this._time,n=this._clips,i=n.length,r=[],a=[],o=0;i>o;o++){var s=n[o],l=s.step(t,e);l&&(r.push(l),a.push(s))}for(var o=0;i>o;)n[o]._needsRemove?(n[o]=n[i-1],n.pop(),i--):o++;i=r.length;for(var o=0;i>o;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){function t(){e._running&&(Vg(t),!e._paused&&e._update())}var e=this;this._running=!0,Vg(t)},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},resume:function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},clear:function(){this._clips=[]},animate:function(t,e){e=e||{};var n=new gg(t,e.loop,e.getter,e.setter);return this.addAnimator(n),n}},c(sv,Up);var lv=function(){this._track=[]};lv.prototype={constructor:lv,recognize:function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},clear:function(){return this._track.length=0,this},_doTrack:function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},a=0,o=i.length;o>a;a++){var s=i[a],l=pi(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},_recognize:function(t){for(var e in uv)if(uv.hasOwnProperty(e)){var n=uv[e](this._track,t);if(n)return n}}};var uv={pinch:function(t,e){var n=t.length;if(n){var i=(t[n-1]||{}).points,r=(t[n-2]||{}).points||i;if(r&&r.length>1&&i&&i.length>1){var a=xi(i)/xi(r);!isFinite(a)&&(a=1),e.pinchScale=a;var o=wi(i);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:t[0].target,event:e}}}}},hv=300,cv=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],dv=["touchstart","touchend","touchmove"],fv={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},pv=p(cv,function(t){var e=t.replace("mouse","pointer");return fv[e]?e:t}),gv={mousemove:function(t){t=vi(this.dom,t),this.trigger("mousemove",t)},mouseout:function(t){t=vi(this.dom,t);var e=t.toElement||t.relatedTarget;if(e!=this.dom)for(;e&&9!=e.nodeType;){if(e===this.dom)return;e=e.parentNode}this.trigger("mouseout",t)},touchstart:function(t){t=vi(this.dom,t),t.zrByTouch=!0,this._lastTouchMoment=new Date,Si(this,t,"start"),gv.mousemove.call(this,t),gv.mousedown.call(this,t),Mi(this)},touchmove:function(t){t=vi(this.dom,t),t.zrByTouch=!0,Si(this,t,"change"),gv.mousemove.call(this,t),Mi(this)},touchend:function(t){t=vi(this.dom,t),t.zrByTouch=!0,Si(this,t,"end"),gv.mouseup.call(this,t),+new Date-this._lastTouchMoment<hv&&gv.click.call(this,t),Mi(this)},pointerdown:function(t){gv.mousedown.call(this,t)},pointermove:function(t){Ti(t)||gv.mousemove.call(this,t)},pointerup:function(t){gv.mouseup.call(this,t)},pointerout:function(t){Ti(t)||gv.mouseout.call(this,t)}};f(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){gv[t]=function(e){e=vi(this.dom,e),this.trigger(t,e)}});var vv=Ci.prototype;vv.dispose=function(){for(var t=cv.concat(dv),e=0;e<t.length;e++){var n=t[e];yi(this.dom,bi(n),this._handlers[n])}},vv.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},c(Ci,Up);var mv=!Sp.canvasSupported,yv={canvas:iv},_v={},xv="4.0.1",wv=function(t,e,n){n=n||{},this.dom=e,this.id=t;var i=this,r=new Ag,a=n.renderer;if(mv){if(!yv.vml)throw new Error("You need to require 'zrender/vml/vml' to support IE8");a="vml"}else a&&yv[a]||(a="canvas");var o=new yv[a](e,r,n,t);this.storage=r,this.painter=o;var s=Sp.node||Sp.worker?null:new Ci(o.getViewportRoot());this.handler=new Yp(r,o,s,o.root),this.animation=new sv({stage:{update:y(this.flush,this)}}),this.animation.start(),this._needsRefresh;var l=r.delFromStorage,u=r.addToStorage;r.delFromStorage=function(t){l.call(r,t),t&&t.removeSelfFromZr(i)},r.addToStorage=function(t){u.call(r,t),t.addSelfToZr(i)}};wv.prototype={constructor:wv,getId:function(){return this.id},add:function(t){this.storage.addRoot(t),this._needsRefresh=!0},remove:function(t){this.storage.delRoot(t),this._needsRefresh=!0},configLayer:function(t,e){this.painter.configLayer(t,e),this._needsRefresh=!0},refreshImmediately:function(){this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1},refresh:function(){this._needsRefresh=!0},flush:function(){this._needsRefresh&&this.refreshImmediately(),this._needsRefreshHover&&this.refreshHoverImmediately()},addHover:function(t,e){this.painter.addHover&&(this.painter.addHover(t,e),this.refreshHover())},removeHover:function(t){this.painter.removeHover&&(this.painter.removeHover(t),this.refreshHover())},clearHover:function(){this.painter.clearHover&&(this.painter.clearHover(),this.refreshHover())},refreshHover:function(){this._needsRefreshHover=!0},refreshHoverImmediately:function(){this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.refreshHover()},resize:function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},clearAnimation:function(){this.animation.clear()},getWidth:function(){return this.painter.getWidth()},getHeight:function(){return this.painter.getHeight()},pathToImage:function(t,e){return this.painter.pathToImage(t,e)},setCursorStyle:function(t){this.handler.setCursorStyle(t)},findHover:function(t,e){return this.handler.findHover(t,e)},on:function(t,e,n){this.handler.on(t,e,n)},off:function(t,e){this.handler.off(t,e)},trigger:function(t,e){this.handler.trigger(t,e)},clear:function(){this.storage.delRoot(),this.painter.clear()},dispose:function(){this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,Li(this.id)}};var bv=(Object.freeze||Object)({version:xv,init:Di,dispose:Ai,getInstance:ki,registerPainter:Pi}),Sv=f,Mv=S,Tv=x,Iv="\x00-",Cv=["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"],Dv=0,Av=".",kv="___EC__COMPONENT__CONTAINER___",Pv=0,Lv=function(t){for(var e=0;e<t.length;e++)t[e][1]||(t[e][1]=t[e][0]);return function(e,n,i){for(var r={},a=0;a<t.length;a++){var o=t[a][1];if(!(n&&u(n,o)>=0||i&&u(i,o)<0)){var s=e.getShallow(o);null!=s&&(r[t[a][0]]=s)}}return r}},Ov=Lv([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Ev={getLineStyle:function(t){var e=Ov(this,t),n=this.getLineDash(e.lineWidth);return n&&(e.lineDash=n),e},getLineDash:function(t){null==t&&(t=1);var e=this.get("type"),n=Math.max(t,2),i=4*t;return"solid"===e||null==e?null:"dashed"===e?[i,i]:[n,n]}},Rv=Lv([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),zv={getAreaStyle:function(t,e){return Rv(this,t,e)}},Bv=Math.pow,Nv=Math.sqrt,Vv=1e-8,Fv=1e-4,Hv=Nv(3),Wv=1/3,Gv=H(),jv=H(),Uv=H(),Zv=Math.min,Xv=Math.max,Yv=Math.sin,qv=Math.cos,$v=2*Math.PI,Kv=H(),Qv=H(),Jv=H(),tm=[],em=[],nm={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},im=[],rm=[],am=[],om=[],sm=Math.min,lm=Math.max,um=Math.cos,hm=Math.sin,cm=Math.sqrt,dm=Math.abs,fm="undefined"!=typeof Float32Array,pm=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};pm.prototype={constructor:pm,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e){this._ux=dm(1/yg/t)||0,this._uy=dm(1/yg/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return this._ctx=t,t&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(nm.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var n=dm(t-this._xi)>this._ux||dm(e-this._yi)>this._uy||this._len<5;return this.addData(nm.L,t,e),this._ctx&&n&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),n&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,n,i,r,a){return this.addData(nm.C,t,e,n,i,r,a),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,n,i,r,a):this._ctx.bezierCurveTo(t,e,n,i,r,a)),this._xi=r,this._yi=a,this},quadraticCurveTo:function(t,e,n,i){return this.addData(nm.Q,t,e,n,i),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,n,i):this._ctx.quadraticCurveTo(t,e,n,i)),this._xi=n,this._yi=i,this},arc:function(t,e,n,i,r,a){return this.addData(nm.A,t,e,n,n,i,r-i,0,a?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,a),this._xi=um(r)*n+t,this._yi=hm(r)*n+t,this},arcTo:function(t,e,n,i,r){return this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},rect:function(t,e,n,i){return this._ctx&&this._ctx.rect(t,e,n,i),this.addData(nm.R,t,e,n,i),this},closePath:function(){this.addData(nm.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,n),t.closePath()),this._xi=e,this._yi=n,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t,this._dashIdx=0;for(var e=0,n=0;n<t.length;n++)e+=t[n];this._dashSum=e}return this},setLineDashOffset:function(t){return this._dashOffset=t,this},len:function(){return this._len},setData:function(t){var e=t.length;this.data&&this.data.length==e||!fm||(this.data=new Float32Array(e));for(var n=0;e>n;n++)this.data[n]=t[n];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t.length,n=0,i=this._len,r=0;e>r;r++)n+=t[r].len();fm&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(var r=0;e>r;r++)for(var a=t[r].data,o=0;o<a.length;o++)this.data[i++]=a[o];this._len=i},addData:function(t){if(this._saveData){var e=this.data;this._len+arguments.length>e.length&&(this._expandData(),e=this.data);for(var n=0;n<arguments.length;n++)e[this._len++]=arguments[n];this._prevCmd=t}},_expandData:function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},_needsDash:function(){return this._lineDash},_dashedLineTo:function(t,e){var n,i,r=this._dashSum,a=this._dashOffset,o=this._lineDash,s=this._ctx,l=this._xi,u=this._yi,h=t-l,c=e-u,d=cm(h*h+c*c),f=l,p=u,g=o.length;for(h/=d,c/=d,0>a&&(a=r+a),a%%=r,f-=a*h,p-=a*c;h>0&&t>=f||0>h&&f>=t||0==h&&(c>0&&e>=p||0>c&&p>=e);)i=this._dashIdx,n=o[i],f+=h*n,p+=c*n,this._dashIdx=(i+1)%%g,h>0&&l>f||0>h&&f>l||c>0&&u>p||0>c&&p>u||s[i%%2?"moveTo":"lineTo"](h>=0?sm(f,t):lm(f,t),c>=0?sm(p,e):lm(p,e));h=f-t,c=p-e,this._dashOffset=-cm(h*h+c*c)},_dashedBezierTo:function(t,e,n,i,r,a){var o,s,l,u,h,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,v=this._yi,m=er,y=0,_=this._dashIdx,x=f.length,w=0;for(0>d&&(d=c+d),d%%=c,o=0;1>o;o+=.1)s=m(g,t,n,r,o+.1)-m(g,t,n,r,o),l=m(v,e,i,a,o+.1)-m(v,e,i,a,o),y+=cm(s*s+l*l);for(;x>_&&(w+=f[_],!(w>d));_++);for(o=(w-d)/y;1>=o;)u=m(g,t,n,r,o),h=m(v,e,i,a,o),_%%2?p.moveTo(u,h):p.lineTo(u,h),o+=f[_]/y,_=(_+1)%%x;_%%2!==0&&p.lineTo(r,a),s=r-u,l=a-h,this._dashOffset=-cm(s*s+l*l)},_dashedQuadraticTo:function(t,e,n,i){var r=n,a=i;n=(n+2*t)/3,i=(i+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,n,i,r,a)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,fm&&(this.data=new Float32Array(t)))},getBoundingRect:function(){im[0]=im[1]=am[0]=am[1]=Number.MAX_VALUE,rm[0]=rm[1]=om[0]=om[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,n=0,i=0,r=0,a=0;a<t.length;){var o=t[a++];switch(1==a&&(e=t[a],n=t[a+1],i=e,r=n),o){case nm.M:i=t[a++],r=t[a++],e=i,n=r,am[0]=i,am[1]=r,om[0]=i,om[1]=r;break;case nm.L:pr(e,n,t[a],t[a+1],am,om),e=t[a++],n=t[a++];break;case nm.C:gr(e,n,t[a++],t[a++],t[a++],t[a++],t[a],t[a+1],am,om),e=t[a++],n=t[a++];break;case nm.Q:vr(e,n,t[a++],t[a++],t[a],t[a+1],am,om),e=t[a++],n=t[a++];break;case nm.A:var s=t[a++],l=t[a++],u=t[a++],h=t[a++],c=t[a++],d=t[a++]+c,f=(t[a++],1-t[a++]);1==a&&(i=um(c)*u+s,r=hm(c)*h+l),mr(s,l,u,h,c,d,f,am,om),e=um(d)*u+s,n=hm(d)*h+l;break;case nm.R:i=e=t[a++],r=n=t[a++];var p=t[a++],g=t[a++];pr(i,r,i+p,r+g,am,om);break;case nm.Z:e=i,n=r}oe(im,im,am),se(rm,rm,om)}return 0===a&&(im[0]=im[1]=rm[0]=rm[1]=0),new rn(im[0],im[1],rm[0]-im[0],rm[1]-im[1])},rebuildPath:function(t){for(var e,n,i,r,a,o,s=this.data,l=this._ux,u=this._uy,h=this._len,c=0;h>c;){var d=s[c++];switch(1==c&&(i=s[c],r=s[c+1],e=i,n=r),d){case nm.M:e=i=s[c++],n=r=s[c++],t.moveTo(i,r);break;case nm.L:a=s[c++],o=s[c++],(dm(a-i)>l||dm(o-r)>u||c===h-1)&&(t.lineTo(a,o),i=a,r=o);break;case nm.C:t.bezierCurveTo(s[c++],s[c++],s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case nm.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case nm.A:var f=s[c++],p=s[c++],g=s[c++],v=s[c++],m=s[c++],y=s[c++],_=s[c++],x=s[c++],w=g>v?g:v,b=g>v?1:g/v,S=g>v?v/g:1,M=Math.abs(g-v)>.001,T=m+y;M?(t.translate(f,p),t.rotate(_),t.scale(b,S),t.arc(0,0,w,m,T,1-x),t.scale(1/b,1/S),t.rotate(-_),t.translate(-f,-p)):t.arc(f,p,w,m,T,1-x),1==c&&(e=um(m)*g+f,n=hm(m)*v+p),i=um(T)*g+f,r=hm(T)*v+p;break;case nm.R:e=i=s[c],n=r=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case nm.Z:t.closePath(),i=e,r=n}}}},pm.CMD=nm;var gm=2*Math.PI,vm=2*Math.PI,mm=pm.CMD,ym=2*Math.PI,_m=1e-4,xm=[-1,-1,-1],wm=[-1,-1],bm=Bg.prototype.getCanvasPattern,Sm=Math.abs,Mm=new pm(!0);Lr.prototype={constructor:Lr,type:"path",__dirtyPath:!0,strokeContainThreshold:5,brush:function(t,e){var n=this.style,i=this.path||Mm,r=n.hasStroke(),a=n.hasFill(),o=n.fill,s=n.stroke,l=a&&!!o.colorStops,u=r&&!!s.colorStops,h=a&&!!o.image,c=r&&!!s.image;if(n.bind(t,this,e),this.setTransform(t),this.__dirty){var d;l&&(d=d||this.getBoundingRect(),this._fillGradient=n.getGradient(t,o,d)),u&&(d=d||this.getBoundingRect(),this._strokeGradient=n.getGradient(t,s,d))}l?t.fillStyle=this._fillGradient:h&&(t.fillStyle=bm.call(o,t)),u?t.strokeStyle=this._strokeGradient:c&&(t.strokeStyle=bm.call(s,t));var f=n.lineDash,p=n.lineDashOffset,g=!!t.setLineDash,v=this.getGlobalScale();i.setScale(v[0],v[1]),this.__dirtyPath||f&&!g&&r?(i.beginPath(t),f&&!g&&(i.setLineDash(f),i.setLineDashOffset(p)),this.buildPath(i,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),a&&i.fill(t),f&&g&&(t.setLineDash(f),t.lineDashOffset=p),r&&i.stroke(t),f&&g&&t.setLineDash([]),null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(){},createPathProxy:function(){this.path=new pm},getBoundingRect:function(){var t=this._rect,e=this.style,n=!t;if(n){var i=this.path;i||(i=this.path=new pm),this.__dirtyPath&&(i.beginPath(),this.buildPath(i,this.shape,!1)),t=i.getBoundingRect()}if(this._rect=t,e.hasStroke()){var r=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||n){r.copy(t);var a=e.lineWidth,o=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),o>1e-10&&(r.width+=a/o,r.height+=a/o,r.x-=a/o/2,r.y-=a/o/2)}return r}return t},contain:function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var a=this.path.data;if(r.hasStroke()){var o=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(r.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),Pr(a,o/s,t,e)))return!0}if(r.hasFill())return kr(a,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):ai.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(S(t))for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);else n[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&Sm(t[0]-1)>1e-10&&Sm(t[3]-1)>1e-10?Math.sqrt(Sm(t[0]*t[3]-t[2]*t[1])):1}},Lr.extend=function(t){var e=function(e){Lr.call(this,e),t.style&&this.style.extendFrom(t.style,!1);var n=t.shape;if(n){this.shape=this.shape||{};var i=this.shape;for(var r in n)!i.hasOwnProperty(r)&&n.hasOwnProperty(r)&&(i[r]=n[r])}t.init&&t.init.call(this,e)};h(e,Lr);for(var n in t)"style"!==n&&"shape"!==n&&(e.prototype[n]=t[n]);return e},h(Lr,ai);var Tm=pm.CMD,Im=[[],[],[]],Cm=Math.sqrt,Dm=Math.atan2,Am=function(t,e){var n,i,r,a,o,s,l=t.data,u=Tm.M,h=Tm.C,c=Tm.L,d=Tm.R,f=Tm.A,p=Tm.Q;for(r=0,a=0;r<l.length;){switch(n=l[r++],a=r,i=0,n){case u:i=1;break;case c:i=1;break;case h:i=3;break;case p:i=2;break;case f:var g=e[4],v=e[5],m=Cm(e[0]*e[0]+e[1]*e[1]),y=Cm(e[2]*e[2]+e[3]*e[3]),_=Dm(-e[1]/y,e[0]/m);l[r]*=m,l[r++]+=g,l[r]*=y,l[r++]+=v,l[r++]*=m,l[r++]*=y,l[r++]+=_,l[r++]+=_,r+=2,a=r;break;case d:s[0]=l[r++],s[1]=l[r++],ae(s,s,e),l[a++]=s[0],l[a++]=s[1],s[0]+=l[r++],s[1]+=l[r++],ae(s,s,e),l[a++]=s[0],l[a++]=s[1]}for(o=0;i>o;o++){var s=Im[o];s[0]=l[r++],s[1]=l[r++],ae(s,s,e),l[a++]=s[0],l[a++]=s[1]}}},km=["m","M","l","L","v","V","h","H","z","Z","c","C","q","Q","t","T","s","S","a","A"],Pm=Math.sqrt,Lm=Math.sin,Om=Math.cos,Em=Math.PI,Rm=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])},zm=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(Rm(t)*Rm(e))},Bm=function(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(zm(t,e))},Nm=function(t){ai.call(this,t)};Nm.prototype={constructor:Nm,type:"text",brush:function(t,e){var n=this.style;this.__dirty&&Hn(n,!0),n.fill=n.stroke=n.shadowBlur=n.shadowColor=n.shadowOffsetX=n.shadowOffsetY=null;var i=n.text;null!=i&&(i+=""),n.bind(t,this,e),ri(i,n)&&(this.setTransform(t),Gn(this,t,i,n),this.restoreTransform(t))},getBoundingRect:function(){var t=this.style;if(this.__dirty&&Hn(t,!0),!this._rect){var e=t.text;null!=e?e+="":e="";var n=Mn(t.text+"",t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.rich);if(n.x+=t.x||0,n.y+=t.y||0,ti(t.textStroke,t.textStrokeWidth)){var i=t.textStrokeWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect}},h(Nm,ai);var Vm=Lr.extend({type:"circle",shape:{cx:0,cy:0,r:0},buildPath:function(t,e,n){n&&t.moveTo(e.cx+e.r,e.cy),t.arc(e.cx,e.cy,e.r,0,2*Math.PI,!0)}}),Fm=[["shadowBlur",0],["shadowColor","#000"],["shadowOffsetX",0],["shadowOffsetY",0]],Hm=function(t){return Sp.browser.ie&&Sp.browser.version>=11?function(){var e,n=this.__clipPaths,i=this.style;if(n)for(var r=0;r<n.length;r++){var a=n[r],o=a&&a.shape,s=a&&a.type;if(o&&("sector"===s&&o.startAngle===o.endAngle||"rect"===s&&(!o.width||!o.height))){for(var l=0;l<Fm.length;l++)Fm[l][2]=i[Fm[l][0]],i[Fm[l][0]]=Fm[l][1];e=!0;break}}if(t.apply(this,arguments),e)for(var l=0;l<Fm.length;l++)i[Fm[l][0]]=Fm[l][2]}:t},Wm=Lr.extend({type:"sector",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},brush:Hm(Lr.prototype.brush),buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),a=Math.max(e.r,0),o=e.startAngle,s=e.endAngle,l=e.clockwise,u=Math.cos(o),h=Math.sin(o);t.moveTo(u*r+n,h*r+i),t.lineTo(u*a+n,h*a+i),t.arc(n,i,a,o,s,!l),t.lineTo(Math.cos(s)*r+n,Math.sin(s)*r+i),0!==r&&t.arc(n,i,r,s,o,l),t.closePath()}}),Gm=Lr.extend({type:"ring",shape:{cx:0,cy:0,r:0,r0:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=2*Math.PI;t.moveTo(n+e.r,i),t.arc(n,i,e.r,0,r,!1),t.moveTo(n+e.r0,i),t.arc(n,i,e.r0,0,r,!0)}}),jm=function(t,e){for(var n=t.length,i=[],r=0,a=1;n>a;a++)r+=ee(t[a-1],t[a]);var o=r/2;o=n>o?n:o;for(var a=0;o>a;a++){var s,l,u,h=a/(o-1)*(e?n:n-1),c=Math.floor(h),d=h-c,f=t[c%%n];e?(s=t[(c-1+n)%%n],l=t[(c+1)%%n],u=t[(c+2)%%n]):(s=t[0===c?c:c-1],l=t[c>n-2?n-1:c+1],u=t[c>n-3?n-1:c+2]);var p=d*d,g=d*p;i.push([Vr(s[0],f[0],l[0],u[0],d,p,g),Vr(s[1],f[1],l[1],u[1],d,p,g)])}return i},Um=function(t,e,n,i){var r,a,o,s,l=[],u=[],h=[],c=[];if(i){o=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;f>d;d++)oe(o,o,t[d]),se(s,s,t[d]);oe(o,o,i[0]),se(s,s,i[1])}for(var d=0,f=t.length;f>d;d++){var p=t[d];if(n)r=t[d?d-1:f-1],a=t[(d+1)%%f];else{if(0===d||d===f-1){l.push(G(t[d]));continue}r=t[d-1],a=t[d+1]}X(u,a,r),J(u,u,e);var g=ee(p,r),v=ee(p,a),m=g+v;0!==m&&(g/=m,v/=m),J(h,u,-g),J(c,u,v);var y=U([],p,h),_=U([],p,c);i&&(se(y,y,o),oe(y,y,s),se(_,_,o),oe(_,_,s)),l.push(y),l.push(_)}return n&&l.push(l.shift()),l},Zm=Lr.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){Fr(t,e,!0)}}),Xm=Lr.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){Fr(t,e,!1)}}),Ym=Lr.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width,a=e.height;e.r?Fn(t,e):t.rect(n,i,r,a),t.closePath()}}),qm=Lr.extend({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.percent;0!==o&&(t.moveTo(n,i),1>o&&(r=n*(1-o)+r*o,a=i*(1-o)+a*o),t.lineTo(r,a))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}}),$m=[],Km=Lr.extend({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.cpx1,s=e.cpy1,l=e.cpx2,u=e.cpy2,h=e.percent;0!==h&&(t.moveTo(n,i),null==l||null==u?(1>h&&(cr(n,o,r,h,$m),o=$m[1],r=$m[2],cr(i,s,a,h,$m),s=$m[1],a=$m[2]),t.quadraticCurveTo(o,s,r,a)):(1>h&&(ar(n,o,l,r,h,$m),o=$m[1],l=$m[2],r=$m[3],ar(i,s,u,a,h,$m),s=$m[1],u=$m[2],a=$m[3]),t.bezierCurveTo(o,s,l,u,r,a)))},pointAt:function(t){return Hr(this.shape,t,!1)},tangentAt:function(t){var e=Hr(this.shape,t,!0);return te(e,e)}}),Qm=Lr.extend({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r,0),a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),u=Math.sin(a);t.moveTo(l*r+n,u*r+i),t.arc(n,i,r,a,o,!s)}}),Jm=Lr.extend({type:"compound",shape:{paths:null},_updatePathDirty:function(){for(var t=this.__dirtyPath,e=this.shape.paths,n=0;n<e.length;n++)t=t||e[n].__dirtyPath;this.__dirtyPath=t,this.__dirty=this.__dirty||t},beforeBrush:function(){this._updatePathDirty();for(var t=this.shape.paths||[],e=this.getGlobalScale(),n=0;n<t.length;n++)t[n].path||t[n].createPathProxy(),t[n].path.setScale(e[0],e[1])},buildPath:function(t,e){for(var n=e.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},afterBrush:function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].__dirtyPath=!1},getBoundingRect:function(){return this._updatePathDirty(),Lr.prototype.getBoundingRect.call(this)}}),ty=function(t){this.colorStops=t||[]};ty.prototype={constructor:ty,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}};var ey=function(t,e,n,i,r,a){this.x=null==t?0:t,this.y=null==e?0:e,this.x2=null==n?1:n,this.y2=null==i?0:i,this.type="linear",this.global=a||!1,ty.call(this,r)};ey.prototype={constructor:ey},h(ey,ty);var ny=function(t,e,n,i,r){this.x=null==t?.5:t,this.y=null==e?.5:e,this.r=null==n?.5:n,this.type="radial",this.global=r||!1,ty.call(this,i)};ny.prototype={constructor:ny},h(ny,ty),Wr.prototype.incremental=!0,Wr.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.dirty(),this.notClear=!1},Wr.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.dirty()},Wr.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},Wr.prototype.eachPendingDisplayable=function(t){for(var e=this._cursor;e<this._displayables.length;e++)t&&t(this._displayables[e]);for(var e=0;e<this._temporaryDisplayables.length;e++)t&&t(this._temporaryDisplayables[e])},Wr.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){var e=this._displayables[t];e.parent=this,e.update(),e.parent=null}for(var t=0;t<this._temporaryDisplayables.length;t++){var e=this._temporaryDisplayables[t];e.parent=this,e.update(),e.parent=null}},Wr.prototype.brush=function(t){for(var e=this._cursor;e<this._displayables.length;e++){var n=this._temporaryDisplayables[e];n.beforeBrush&&n.beforeBrush(t),n.brush(t,e===this._cursor?null:this._displayables[e-1]),n.afterBrush&&n.afterBrush(t)}this._cursor=e;for(var e=0;e<this._temporaryDisplayables.length;e++){var n=this._temporaryDisplayables[e];n.beforeBrush&&n.beforeBrush(t),n.brush(t,0===e?null:this._temporaryDisplayables[e-1]),n.afterBrush&&n.afterBrush(t)}this._temporaryDisplayables=[],this.notClear=!0};var iy=[];Wr.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new rn(1/0,1/0,-1/0,-1/0),e=0;e<this._displayables.length;e++){var n=this._displayables[e],i=n.getBoundingRect().clone();n.needLocalTransform()&&i.applyTransform(n.getLocalTransform(iy)),t.union(i)}this._rect=t}return this._rect},Wr.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();if(i.contain(n[0],n[1]))for(var r=0;r<this._displayables.length;r++){var a=this._displayables[r];if(a.contain(t,e))return!0}return!1},h(Wr,ai);var ry=Math.round,ay=Math.max,oy=Math.min,sy={},ly=Nr,uy=(Object.freeze||Object)({extendShape:Gr,extendPath:jr,makePath:Ur,makeImage:Zr,mergePath:ly,resizePath:Yr,subPixelOptimizeLine:qr,subPixelOptimizeRect:$r,subPixelOptimize:Kr,setHoverStyle:ha,setLabelStyle:ca,setTextStyle:da,setText:fa,getFont:xa,updateProps:ba,initProps:Sa,getTransform:Ma,applyTransform:Ta,transformDirection:Ia,groupTransition:Ca,clipPointsByRect:Da,clipRectByRect:Aa,createIcon:ka,Group:Ig,Image:oi,Text:Nm,Circle:Vm,Sector:Wm,Ring:Gm,Polygon:Zm,Polyline:Xm,Rect:Ym,Line:qm,BezierCurve:Km,Arc:Qm,IncrementalDisplayable:Wr,CompoundPath:Jm,LinearGradient:ey,RadialGradient:ny,BoundingRect:rn}),hy=["textStyle","color"],cy={getTextColor:function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(hy):null)},getFont:function(){return xa({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},getTextRect:function(t){return Mn(t,this.getFont(),this.getShallow("align"),this.getShallow("verticalAlign")||this.getShallow("baseline"),this.getShallow("padding"),this.getShallow("rich"),this.getShallow("truncateText"))}},dy=Lv([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["textPosition"],["textAlign"]]),fy={getItemStyle:function(t,e){var n=dy(this,t,e),i=this.getBorderLineDash();return i&&(n.lineDash=i),n},getBorderLineDash:function(){var t=this.get("borderType");return"solid"===t||null==t?null:"dashed"===t?[5,5]:[1,1]}},py=c,gy=Hi();Pa.prototype={constructor:Pa,init:null,mergeOption:function(t){r(this.option,t,!0)},get:function(t,e){return null==t?this.option:La(this.option,this.parsePath(t),!e&&Oa(this,t))},getShallow:function(t,e){var n=this.option,i=null==n?n:n[t],r=!e&&Oa(this,t);return null==i&&r&&(i=r.getShallow(t)),i},getModel:function(t,e){var n,i=null==t?this.option:La(this.option,t=this.parsePath(t));return e=e||(n=Oa(this,t))&&n.getModel(t),new Pa(i,e,this.ecModel)},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){var t=this.constructor;return new t(i(this.option))},setReadOnly:function(){},parsePath:function(t){return"string"==typeof t&&(t=t.split(".")),t},customizeGetParent:function(t){gy(this).getParent=t},isAnimationEnabled:function(){if(!Sp.node){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}}},Yi(Pa),qi(Pa),py(Pa,Ev),py(Pa,zv),py(Pa,cy),py(Pa,fy);var vy=0,my=1e-4,yy=9007199254740991,_y=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d\d)(?::(\d\d)(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/,xy=(Object.freeze||Object)({linearMap:Na,parsePercent:Va,round:Fa,asc:Ha,getPrecision:Wa,getPrecisionSafe:Ga,getPixelPrecision:ja,getPercentWithPrecision:Ua,MAX_SAFE_INTEGER:yy,remRadian:Za,isRadianAroundZero:Xa,parseDate:Ya,quantity:qa,nice:Ka,reformIntervals:Qa,isNumeric:Ja}),wy=L,by=["a","b","c","d","e","f","g"],Sy=function(t,e){return"{"+t+(null==e?"":e)+"}"},My=function(t){return 10>t?"0"+t:t},Ty=kn,Iy=Mn,Cy=(Object.freeze||Object)({addCommas:to,toCamelCase:eo,normalizeCssArray:wy,encodeHTML:no,formatTpl:io,formatTplSimple:ro,getTooltipMarker:ao,formatTime:oo,capitalFirst:so,truncateText:Ty,getTextRect:Iy}),Dy=f,Ay=["left","right","top","bottom","width","height"],ky=[["width","left","right"],["height","top","bottom"]],Py=lo,Ly=(_(lo,"vertical"),_(lo,"horizontal"),{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}}),Oy=Hi(),Ey=Pa.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){Pa.call(this,t,e,n,i),this.uid=Ea("ec_cpt_model")},init:function(t,e,n){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?fo(t):{},a=e.getTheme();r(t,a.get(this.mainType)),r(t,this.getDefaultOption()),n&&co(t,i,n)},mergeOption:function(t){r(this.option,t,!0);var e=this.layoutMode;e&&co(this.option,t,e)},optionUpdated:function(){},getDefaultOption:function(){var t=Oy(this);if(!t.defaultOption){for(var e=[],n=this.constructor;n;){var i=n.prototype.defaultOption;i&&e.push(i),n=n.superClass}for(var a={},o=e.length-1;o>=0;o--)a=r(a,e[o],!0);t.defaultOption=a}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});Qi(Ey,{registerWhenExtend:!0}),Ra(Ey),za(Ey,go),c(Ey,Ly);var Ry="";"undefined"!=typeof navigator&&(Ry=navigator.platform||"");var zy={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:Ry.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},By=Hi(),Ny={clearColorPalette:function(){By(this).colorIdx=0,By(this).colorNameMap={}},getColorFromPalette:function(t,e,n){e=e||this;var i=By(e),r=i.colorIdx||0,a=i.colorNameMap=i.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var o=Oi(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?vo(s,n):o;if(l=l||o,l&&l.length){var u=l[r];return t&&(a[t]=u),i.colorIdx=(r+1)%%l.length,u}}},Vy={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",a),yo(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),yo(a)&&(i.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),yo(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],a=r.findAxisModel("radiusAxis"),o=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",a),n.set("angle",o),yo(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),yo(o)&&(i.set("angle",o),e.firstCategoryDimIndex=1)},geo:function(t,e){e.coordSysDims=["lng","lat"]},parallel:function(t,e,n,i){var r=t.ecModel,a=r.getComponent("parallel",t.get("parallelIndex")),o=e.coordSysDims=a.dimensions.slice();f(a.parallelAxisIndex,function(t,a){var s=r.getComponent("parallelAxis",t),l=o[a];n.set(l,s),yo(s)&&null==e.firstCategoryDimIndex&&(i.set(l,s),e.firstCategoryDimIndex=a)})}},Fy="original",Hy="arrayRows",Wy="objectRows",Gy="keyedColumns",jy="unknown",Uy="typedArray",Zy="column",Xy="row";_o.seriesDataToSource=function(t){return new _o({data:t,sourceFormat:T(t)?Uy:Fy,fromDataset:!1})},qi(_o);var Yy=Hi(),qy="\x00_ec_inner",$y=Pa.extend({constructor:$y,init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new Pa(n),this._optionManager=i},setOption:function(t,e){O(!(qy in t),"please use chart.getOption()"),this._optionManager.setOption(t,e),this.resetOption(null)},resetOption:function(t){var e=!1,n=this._optionManager;if(!t||"recreate"===t){var i=n.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this.mergeOption(i)):Oo.call(this,i),e=!0}if(("timeline"===t||"media"===t)&&this.restoreData(),!t||"recreate"===t||"timeline"===t){var r=n.getTimelineOption(this);r&&(this.mergeOption(r),e=!0)}if(!t||"recreate"===t||"media"===t){var a=n.getMediaOption(this,this._api);a.length&&f(a,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(t){function e(e,i){var r=Oi(t[e]),s=Bi(a.get(e),r);Ni(s),f(s,function(t){var n=t.option;S(n)&&(t.keyInfo.mainType=e,t.keyInfo.subType=Ro(e,n,t.exist))});var l=Eo(a,i);n[e]=[],a.set(e,[]),f(s,function(t,i){var r=t.exist,s=t.option;if(O(S(s)||r,"Empty component definition"),s){var u=Ey.getClass(e,t.keyInfo.subType,!0);if(r&&r instanceof u)r.name=t.keyInfo.name,r.mergeOption(s,this),r.optionUpdated(s,!1);else{var h=o({dependentModels:l,componentIndex:i},t.keyInfo);r=new u(s,this,this,h),o(r,h),r.init(s,this,this,h),r.optionUpdated(null,!0)}}else r.mergeOption({},this),r.optionUpdated({},!1);a.get(e)[i]=r,n[e][i]=r.option},this),"series"===e&&zo(this,a.get("series"))}var n=this.option,a=this._componentsMap,s=[];wo(this),f(t,function(t,e){null!=t&&(Ey.hasClass(e)?e&&s.push(e):n[e]=null==n[e]?i(t):r(n[e],t,!0))}),Ey.topologicalTravel(s,Ey.getAllClassMainTypes(),e,this),this._seriesIndicesMap=N(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var t=i(this.option);return f(t,function(e,n){if(Ey.hasClass(n)){for(var e=Oi(e),i=e.length-1;i>=0;i--)Vi(e[i])&&e.splice(i,1);t[n]=e}}),delete t[qy],t},getTheme:function(){return this._theme},getComponent:function(t,e){var n=this._componentsMap.get(t);return n?n[e||0]:void 0},queryComponents:function(t){var e=t.mainType;if(!e)return[];var n=t.index,i=t.id,r=t.name,a=this._componentsMap.get(e);if(!a||!a.length)return[];var o;if(null!=n)x(n)||(n=[n]),o=v(p(n,function(t){return a[t]}),function(t){return!!t});else if(null!=i){var s=x(i);o=v(a,function(t){return s&&u(i,t.id)>=0||!s&&t.id===i})}else if(null!=r){var l=x(r);o=v(a,function(t){return l&&u(r,t.name)>=0||!l&&t.name===r})}else o=a.slice();return Bo(o,t)},findComponents:function(t){function e(t){var e=r+"Index",n=r+"Id",i=r+"Name";return!t||null==t[e]&&null==t[n]&&null==t[i]?null:{mainType:r,index:t[e],id:t[n],name:t[i]}}function n(e){return t.filter?v(e,t.filter):e}var i=t.query,r=t.mainType,a=e(i),o=a?this.queryComponents(a):this._componentsMap.get(r);return n(Bo(o,t))},eachComponent:function(t,e,n){var i=this._componentsMap;if("function"==typeof t)n=e,e=t,i.each(function(t,i){f(t,function(t,r){e.call(n,i,t,r)})});else if(b(t))f(i.get(t),e,n);else if(S(t)){var r=this.findComponents(t);f(r,e,n)}},getSeriesByName:function(t){var e=this._componentsMap.get("series");return v(e,function(e){return e.name===t})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(t){var e=this._componentsMap.get("series");return v(e,function(e){return e.subType===t})},getSeries:function(){return this._componentsMap.get("series").slice()},getSeriesCount:function(){return this._componentsMap.get("series").length},eachSeries:function(t,e){f(this._seriesIndices,function(n){var i=this._componentsMap.get("series")[n];t.call(e,i,n)},this)},eachRawSeries:function(t,e){f(this._componentsMap.get("series"),t,e)},eachSeriesByType:function(t,e,n){f(this._seriesIndices,function(i){var r=this._componentsMap.get("series")[i];r.subType===t&&e.call(n,r,i)},this)},eachRawSeriesByType:function(t,e,n){return f(this.getSeriesByType(t),e,n)},isSeriesFiltered:function(t){return null==this._seriesIndicesMap.get(t.componentIndex)},getCurrentSeriesIndices:function(){return(this._seriesIndices||[]).slice()},filterSeries:function(t,e){var n=v(this._componentsMap.get("series"),t,e);zo(this,n)},restoreData:function(t){var e=this._componentsMap;zo(this,e.get("series"));var n=[];e.each(function(t,e){n.push(e)}),Ey.topologicalTravel(n,Ey.getAllClassMainTypes(),function(n){f(e.get(n),function(e){("series"!==n||!Po(e,t))&&e.restoreData()})})}});c($y,Ny);var Ky=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"],Qy={};Vo.prototype={constructor:Vo,create:function(t,e){var n=[];f(Qy,function(i){var r=i.create(t,e);n=n.concat(r||[])}),this._coordinateSystems=n},update:function(t,e){f(this._coordinateSystems,function(n){n.update&&n.update(t,e)})},getCoordinateSystems:function(){return this._coordinateSystems.slice()}},Vo.register=function(t,e){Qy[t]=e},Vo.get=function(t){return Qy[t]};var Jy=f,t_=i,e_=p,n_=r,i_=/^(min|max)?(.+)$/;Fo.prototype={constructor:Fo,setOption:function(t,e){t&&f(Oi(t.series),function(t){t&&t.data&&T(t.data)&&R(t.data)}),t=t_(t,!0);var n=this._optionBackup,i=Ho.call(this,t,e,!n);this._newBaseOption=i.baseOption,n?(Uo(n.baseOption,i.baseOption),i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},mountOption:function(t){var e=this._optionBackup;return this._timelineOptions=e_(e.timelineOptions,t_),this._mediaList=e_(e.mediaList,t_),this._mediaDefault=t_(e.mediaDefault),this._currentMediaIndices=[],t_(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(e=t_(n[i.getCurrentIndex()],!0))}return e},getMediaOption:function(){var t=this._api.getWidth(),e=this._api.getHeight(),n=this._mediaList,i=this._mediaDefault,r=[],a=[];if(!n.length&&!i)return a;for(var o=0,s=n.length;s>o;o++)Wo(n[o].query,t,e)&&r.push(o);return!r.length&&i&&(r=[-1]),r.length&&!jo(r,this._currentMediaIndices)&&(a=e_(r,function(t){return t_(-1===t?i.option:n[t].option)})),this._currentMediaIndices=r,a}};var r_=f,a_=S,o_=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"],s_=function(t,e){r_(Qo(t.series),function(t){a_(t)&&Ko(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),r_(n,function(e){r_(Qo(t[e]),function(t){t&&(qo(t,"axisLabel"),qo(t.axisPointer,"label"))})}),r_(Qo(t.parallel),function(t){var e=t&&t.parallelAxisDefault;qo(e,"axisLabel"),qo(e&&e.axisPointer,"label")}),r_(Qo(t.calendar),function(t){Xo(t,"itemStyle"),qo(t,"dayLabel"),qo(t,"monthLabel"),qo(t,"yearLabel")}),r_(Qo(t.radar),function(t){qo(t,"name")}),r_(Qo(t.geo),function(t){a_(t)&&($o(t),r_(Qo(t.regions),function(t){$o(t)}))}),r_(Qo(t.timeline),function(t){$o(t),Xo(t,"label"),Xo(t,"itemStyle"),Xo(t,"controlStyle",!0),Xo(t,"checkpointStyle");var e=t.data;x(e)&&f(e,function(t){S(t)&&(Xo(t,"label"),Xo(t,"itemStyle"))})}),r_(Qo(t.toolbox),function(t){Xo(t,"iconStyle"),r_(t.feature,function(t){Xo(t,"iconStyle")})}),qo(Jo(t.axisPointer),"label"),qo(Jo(t.tooltip).axisPointer,"label")},l_=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],u_=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],h_=function(t,e){s_(t,e),t.series=Oi(t.series),f(t.series,function(t){if(S(t)){var e=t.type;if(("pie"===e||"gauge"===e)&&null!=t.clockWise&&(t.clockwise=t.clockWise),"gauge"===e){var n=ts(t,"pointer.color");null!=n&&es(t,"itemStyle.normal.color",n)}ns(t)}}),t.dataRange&&(t.visualMap=t.dataRange),f(u_,function(e){var n=t[e];n&&(x(n)||(n=[n]),f(n,function(t){ns(t)}))})},c_=is.prototype;c_.pure=!1,c_.persistent=!0,c_.getSource=function(){return this._source};var d_={arrayRows_column:{pure:!0,count:function(){return Math.max(0,this._data.length-this._source.startIndex)},getItem:function(t){return this._data[t+this._source.startIndex]},appendData:os},arrayRows_row:{pure:!0,count:function(){var t=this._data[0];return t?Math.max(0,t.length-this._source.startIndex):0},getItem:function(t){t+=this._source.startIndex;for(var e=[],n=this._data,i=0;i<n.length;i++){var r=n[i];e.push(r?r[t]:null)}return e},appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},objectRows:{pure:!0,count:rs,getItem:as,appendData:os},keyedColumns:{pure:!0,count:function(){var t=this._source.dimensionsDefine[0].name,e=this._data[t];return e?e.length:0},getItem:function(t){for(var e=[],n=this._source.dimensionsDefine,i=0;i<n.length;i++){var r=this._data[n[i].name];e.push(r?r[t]:null)}return e},appendData:function(t){var e=this._data;f(t,function(t,n){for(var i=e[n]||(e[n]=[]),r=0;r<(t||[]).length;r++)i.push(t[r])})}},original:{count:rs,getItem:as,appendData:os},typedArray:{persistent:!1,pure:!0,count:function(){return this._data?this._data.length/this._dimSize:0},getItem:function(t){t-=this._offset;for(var e=[],n=this._dimSize*t,i=0;i<this._dimSize;i++)e[i]=this._data[n+i];return e},appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}}},f_={arrayRows:ss,objectRows:function(t,e,n,i){return null!=n?t[i]:t},keyedColumns:ss,original:function(t,e,n){var i=Ri(t);return null!=n&&i instanceof Array?i[n]:i},typedArray:ss},p_={arrayRows:ls,objectRows:function(t,e){return us(t[e],this._dimensionInfos[e])},keyedColumns:ls,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return!this._rawData.pure&&zi(t)&&(this.hasItemOption=!0),us(r instanceof Array?r[i]:r,this._dimensionInfos[e])},typedArray:function(t,e,n,i){return t[i]}},g_=/\{@(.+?)\}/g,v_={getDataParams:function(t,e){var n=this.getData(e),i=this.getRawValue(t,e),r=n.getRawIndex(t),a=n.getName(t,!0),o=n.getRawDataItem(t),s=n.getItemVisual(t,"color");return{componentType:this.mainType,componentSubType:this.subType,seriesType:"series"===this.mainType?this.subType:null,seriesIndex:this.seriesIndex,seriesId:this.id,seriesName:this.name,name:a,dataIndex:r,data:o,dataType:e,value:i,color:s,marker:ao(s),$vars:["seriesName","name","value"]}},getFormattedLabel:function(t,e,n,i,r){e=e||"normal";var a=this.getData(n),o=a.getItemModel(t),s=this.getDataParams(t,n);null!=i&&s.value instanceof Array&&(s.value=s.value[i]);var l=o.get("normal"===e?[r||"label","formatter"]:[e,r||"label","formatter"]);if("function"==typeof l)return s.status=e,l(s);if("string"==typeof l){var u=io(l,s);return u.replace(g_,function(e,n){var i=n.length;return"["===n.charAt(0)&&"]"===n.charAt(i-1)&&(n=+n.slice(1,i-1)),hs(a,t,n)})}},getRawValue:function(t,e){return hs(this.getData(e),t)},formatTooltip:function(){}},m_=ds.prototype;m_.perform=function(t){var e=this._upstream,n=t&&t.skip;if(this._dirty&&e){var i=this.context;i.data=i.outputData=e.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var r;this._plan&&!n&&(r=this._plan(this.context)),(this._dirty||"reset"===r)&&(this._dirty=!1,fs(this,n));var a=t&&t.step;if(this._dueEnd=e?e._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var o=this._dueIndex,s=Math.min(null!=a?this._dueIndex+a:1/0,this._dueEnd);!n&&s>o&&this._progress({start:o,end:s},this.context),this._dueIndex=s;var l=null!=this._settedOutputEnd?this._settedOutputEnd:s;this._outputDueEnd=l}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},m_.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},m_.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},m_.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},m_.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},m_.getUpstream=function(){return this._upstream},m_.getDownstream=function(){return this._downstream},m_.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t};var y_=Hi(),__=Ey.extend({type:"series.__base__",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,visualColorAccessPath:"itemStyle.color",layoutMode:null,init:function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=cs({count:vs,reset:ms}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),bo(this);var i=this.getInitialData(t,n);_s(i,this),this.dataTask.context.data=i,y_(this).dataBeforeProcessed=i,ps(this)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?fo(t):{},a=this.subType;Ey.hasClass(a)&&(a+="Series"),r(t,e.getTheme().get(this.subType)),r(t,this.getDefaultOption()),Ei(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&co(t,i,n)},mergeOption:function(t,e){t=r(this.option,t,!0),this.fillDataTextStyle(t.data);var n=this.layoutMode;n&&co(this.option,t,n),bo(this);var i=this.getInitialData(t,e);_s(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,y_(this).dataBeforeProcessed=i,ps(this)},fillDataTextStyle:function(t){if(t)for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&Ei(t[n],"label",e)},getInitialData:function(){},appendData:function(t){var e=this.getRawData();e.appendData(t.data)},getData:function(t){var e=ws(this);if(e){var n=e.context.data;return null==t?n:n.getLinkedData(t)}return y_(this).data},setData:function(t){var e=ws(this);if(e){var n=e.context;n.data!==t&&e.isOverallFilter&&e.setOutputEnd(t.count()),n.outputData=t,e!==this.dataTask&&(n.data=t)}y_(this).data=t},getSource:function(){return xo(this)},getRawData:function(){return y_(this).dataBeforeProcessed},getBaseAxis:function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},formatTooltip:function(t,e){function n(n){function i(t,n){var i=r.getDimensionInfo(n);if(i&&i.otherDims.tooltip!==!1){var a=i.type,l=ao({color:u,type:"subItem"}),h=(o?l+no(i.displayName||"-")+": ":"")+no("ordinal"===a?t+"":"time"===a?e?"":oo("yyyy/MM/dd hh:mm:ss",t):to(t));h&&s.push(h)}}var o=g(n,function(t,e,n){var i=r.getDimensionInfo(n);return t|=i&&i.tooltip!==!1&&null!=i.displayName},0),s=[];return a.length?f(a,function(e){i(hs(r,t,e),e)}):f(n,i),(o?"<br/>":"")+s.join(o?"<br/>":", ")}function i(t){return no(to(t))}var r=this.getData(),a=r.mapDimension("defaultedTooltip",!0),o=a.length,s=this.getRawValue(t),l=x(s),u=r.getItemVisual(t,"color");S(u)&&u.colorStops&&(u=(u.colorStops[0]||{}).color),u=u||"transparent";var h=o>1||l&&!o?n(s):i(o?hs(r,t,a[0]):l?s[0]:s),c=ao(u),d=r.getName(t),p=this.name;return p===Iv&&(p=""),p=p?no(p)+(e?": ":"<br/>"):"",e?c+p+h:p+c+(d?no(d)+": "+h:h)},isAnimationEnabled:function(){if(Sp.node)return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),t},restoreData:function(){this.dataTask.dirty()},getColorFromPalette:function(t,e,n){var i=this.ecModel,r=Ny.getColorFromPalette.call(this,t,e,n);return r||(r=i.getColorFromPalette(t,e,n)),r},coordDimToDataDim:function(t){return this.getRawData().mapDimension(t,!0)},getProgressive:function(){return this.get("progressive")},getProgressiveThreshold:function(){return this.get("progressiveThreshold")},getAxisTooltipData:null,getTooltipPosition:null,pipeTask:null,preventIncremental:null,pipelineContext:null});c(__,v_),c(__,Ny);var x_=function(){this.group=new Ig,this.uid=Ea("viewComponent")};x_.prototype={constructor:x_,init:function(){},render:function(){},dispose:function(){}};var w_=x_.prototype;w_.updateView=w_.updateLayout=w_.updateVisual=function(){},Yi(x_),Qi(x_,{registerWhenExtend:!0});var b_=function(){var t=Hi();return function(e){var n=t(e),i=e.pipelineContext,r=n.large,a=n.incrementalRender,o=n.large=i.large,s=n.incrementalRender=i.incrementalRender;return(r^o||a^s)&&"reset"}},S_=Hi(),M_=b_();bs.prototype={type:"chart",init:function(){},render:function(){},highlight:function(t,e,n,i){Ms(t.getData(),i,"emphasis")},downplay:function(t,e,n,i){Ms(t.getData(),i,"normal")},remove:function(){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null};var T_=bs.prototype;T_.updateView=T_.updateLayout=T_.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},Yi(bs,["dispose"]),Qi(bs,{registerWhenExtend:!0}),bs.markUpdateMethod=function(t,e){S_(t).updateMethod=e};var I_="\x00__throttleOriginMethod",C_="\x00__throttleRate",D_="\x00__throttleType",A_={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData(),i=(t.visualColorAccessPath||"itemStyle.color").split("."),r=t.get(i)||t.getColorFromPalette(t.get("name"),null,e.getSeriesCount());if(n.setVisual("color",r),!e.isSeriesFiltered(t)){"function"!=typeof r||r instanceof ty||n.each(function(e){n.setItemVisual(e,"color",r(t.getDataParams(e)))});var a=function(t,e){var n=t.getItemModel(e),r=n.get(i,!0);null!=r&&t.setItemVisual(e,"color",r)};return{dataEach:n.hasItemOption?a:null}}}},k_={toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}},P_=function(t,e){function n(t,e){if("string"!=typeof t)return t;var n=t;return f(e,function(t,e){n=n.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),n}function i(t){var e=o.get(t);if(null==e){for(var n=t.split("."),i=k_.aria,r=0;r<n.length;++r)i=i[n[r]];return i}return e}function r(){var t=e.getModel("title").option;return t&&t.length&&(t=t[0]),t&&t.text}function a(t){return k_.series.typeNames[t]||"自定义图"}var o=e.getModel("aria");if(o.get("show")){if(o.get("description"))return void t.setAttribute("aria-label",o.get("description"));var s=0;e.eachSeries(function(){++s},this);var l,u=o.get("data.maxCount")||10,h=o.get("series.maxCount")||10,c=Math.min(s,h);if(!(1>s)){var d=r();l=d?n(i("general.withTitle"),{title:d}):i("general.withoutTitle");var p=[],g=s>1?"series.multiple.prefix":"series.single.prefix";l+=n(i(g),{seriesCount:s}),e.eachSeries(function(t,e){if(c>e){var r,o=t.get("name"),l="series."+(s>1?"multiple":"single")+".";r=i(o?l+"withName":l+"withoutName"),r=n(r,{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:a(t.subType)});var h=t.getData();window.data=h,r+=h.count()>u?n(i("data.partialData"),{displayCnt:u}):i("data.allData");for(var d=[],f=0;f<h.count();f++)if(u>f){var g=h.getName(f),v=hs(h,f);d.push(n(i(g?"data.withName":"data.withoutName"),{name:g,value:v}))}r+=d.join(i("data.separator.middle"))+i("data.separator.end"),p.push(r)}}),l+=p.join(i("series.multiple.separator.middle"))+i("series.multiple.separator.end"),t.setAttribute("aria-label",l)}}},L_=Math.PI,O_=function(t,e){e=e||{},s(e,{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var n=new Ym({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4}),i=new Qm({shape:{startAngle:-L_/2,endAngle:-L_/2+.1,r:10},style:{stroke:e.color,lineCap:"round",lineWidth:5},zlevel:e.zlevel,z:10001}),r=new Ym({style:{fill:"none",text:e.text,textPosition:"right",textDistance:10,textFill:e.textColor},zlevel:e.zlevel,z:10001});i.animateShape(!0).when(1e3,{endAngle:3*L_/2}).start("circularInOut"),i.animateShape(!0).when(1e3,{startAngle:3*L_/2}).delay(300).start("circularInOut");var a=new Ig;return a.add(i),a.add(r),a.add(n),a.resize=function(){var e=t.getWidth()/2,a=t.getHeight()/2;i.setShape({cx:e,cy:a});var o=i.shape.r;r.setShape({x:e-o,y:a-o,width:2*o,height:2*o}),n.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},a.resize(),a},E_=ks.prototype;E_.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.incrementalRender)&&t.__idxInPipeline>n.bockIndex;return{step:r?n.step:null}}},E_.getPipeline=function(t){return this._pipelineMap.get(t)},E_.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData(),r=i.count(),a=n.progressiveEnabled&&e.incrementalPrepareRender&&r>=n.threshold,o=t.get("large")&&r>=t.get("largeThreshold");t.pipelineContext=n.context={incrementalRender:a,large:o}},E_.restorePipelines=function(t){var e=this,n=e._pipelineMap=N();t.eachSeries(function(t){var i=t.getProgressive(),r=t.uid;n.set(r,{id:r,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:i&&!(t.preventIncremental&&t.preventIncremental()),bockIndex:-1,step:i||700,count:0}),Ws(e,t,t.dataTask)})},E_.prepareStageTasks=function(t){var e=this._stageTaskMap,n=this.ecInstance.getModel(),i=this.api;f(t,function(t){var r=e.get(t.uid)||e.set(t.uid,[]);t.reset&&Ls(this,t,r,n,i),t.overallReset&&Os(this,t,r,n,i)},this)},E_.prepareView=function(t,e,n,i){var r=t.renderTask,a=r.context;a.model=e,a.ecModel=n,a.api=i,r.__block=!t.incrementalPrepareRender,Ws(this,e,r)},E_.performDataProcessorTasks=function(t,e,n){Ps(this,t,e,n,{block:!0})},E_.performVisualTasks=function(t,e,n,i){Ps(this,t,e,n,i)},E_.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},E_.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.bockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var R_=E_.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)};ks.wrapStageHandler=function(t,e){return w(t)&&(t={overallReset:t,seriesType:Gs(t)}),t.uid=Ea("stageHandler"),e&&(t.visualType=e),t};var z_,B_={},N_={};js(B_,$y),js(N_,No),B_.eachSeriesByType=B_.eachRawSeriesByType=function(t){z_=t},B_.eachComponent=function(t){"series"===t.mainType&&t.subType&&(z_=t.subType)};var V_=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],F_={color:V_,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],V_]},H_="#eee",W_=function(){return{axisLine:{lineStyle:{color:H_}},axisTick:{lineStyle:{color:H_}},axisLabel:{textStyle:{color:H_}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:H_}}}},G_=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],j_={color:G_,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:H_},crossStyle:{color:H_}}},legend:{textStyle:{color:H_}},textStyle:{color:H_},title:{textStyle:{color:H_}},toolbox:{iconStyle:{normal:{borderColor:H_}}},dataZoom:{textStyle:{color:H_}},visualMap:{textStyle:{color:H_}},timeline:{lineStyle:{color:H_},itemStyle:{normal:{color:G_[1]}},label:{normal:{textStyle:{color:H_}}},controlStyle:{normal:{color:H_,borderColor:H_}}},timeAxis:W_(),logAxis:W_(),valueAxis:W_(),categoryAxis:W_(),line:{symbol:"circle"},graph:{color:G_},gauge:{title:{textStyle:{color:H_}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};j_.categoryAxis.splitLine.show=!1;var U_=O,Z_=f,X_=w,Y_=S,q_=Ey.parseClassType,$_="4.0.2",K_={zrender:"4.0.1"},Q_=1,J_=1e3,tx=5e3,ex=1e3,nx=2e3,ix=3e3,rx=4e3,ax=5e3,ox={PROCESSOR:{FILTER:J_,STATISTIC:tx},VISUAL:{LAYOUT:ex,GLOBAL:nx,CHART:ix,COMPONENT:rx,BRUSH:ax}},sx="__flagInMainProcess",lx="__hasGradientOrPatternBg",ux="__optionUpdated",hx=/^[a-zA-Z0-9_]+$/;Zs.prototype.on=Us("on"),Zs.prototype.off=Us("off"),Zs.prototype.one=Us("one"),c(Zs,Up);var cx=Xs.prototype;cx._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[ux]){var e=this[ux].silent;this[sx]=!0,qs(this),dx.update.call(this),this[sx]=!1,this[ux]=!1,tl.call(this,e),el.call(this,e)}else if(t.unfinished){var n=Q_,i=this._model,r=this._api;t.unfinished=!1;do{var a=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(vx,i),Qs(this,i),t.performVisualTasks(_x,i),sl(this,this._model,r,"remain"),n-=+new Date-a}while(n>0&&t.unfinished);t.unfinished||(this._zr&&this._zr.flush(),this.trigger("finished"))}}},cx.getDom=function(){return this._dom},cx.getZr=function(){return this._zr},cx.setOption=function(t,e,n){var i;if(Y_(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[sx]=!0,!this._model||e){var r=new Fo(this._api),a=this._theme,o=this._model=new $y(null,null,a,r);o.scheduler=this._scheduler,o.init(null,null,a,r)}this._model.setOption(t,mx),n?(this[ux]={silent:i},this[sx]=!1):(qs(this),dx.update.call(this),this._zr.flush(),this[ux]=!1,this[sx]=!1,tl.call(this,i),el.call(this,i))},cx.setTheme=function(){console.log("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},cx.getModel=function(){return this._model},cx.getOption=function(){return this._model&&this._model.getOption()},cx.getWidth=function(){return this._zr.getWidth()},cx.getHeight=function(){return this._zr.getHeight()},cx.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},cx.getRenderedCanvas=function(t){if(Sp.canvasSupported){t=t||{},t.pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor");var e=this._zr,n=e.storage.getDisplayList();return f(n,function(t){t.stopAnimation(!0)}),e.painter.getRenderedCanvas(t)}},cx.getSvgDataUrl=function(){if(Sp.svgSupported){var t=this._zr,e=t.storage.getDisplayList();return f(e,function(t){t.stopAnimation(!0)}),t.painter.pathToSvg()}},cx.getDataURL=function(t){t=t||{};var e=t.excludeComponents,n=this._model,i=[],r=this;Z_(e,function(t){n.eachComponent({mainType:t},function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)})});var a="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return Z_(i,function(t){t.group.ignore=!1}),a},cx.getConnectedDataURL=function(t){if(Sp.canvasSupported){var e=this.group,n=Math.min,r=Math.max,a=1/0;if(Mx[e]){var o=a,s=a,l=-a,u=-a,h=[],c=t&&t.pixelRatio||1;f(Sx,function(a){if(a.group===e){var c=a.getRenderedCanvas(i(t)),d=a.getDom().getBoundingClientRect();o=n(d.left,o),s=n(d.top,s),l=r(d.right,l),u=r(d.bottom,u),h.push({dom:c,left:d.left,top:d.top})}}),o*=c,s*=c,l*=c,u*=c;var d=l-o,p=u-s,g=Ep();g.width=d,g.height=p;var v=Di(g);return Z_(h,function(t){var e=new oi({style:{x:t.left*c-o,y:t.top*c-s,image:t.dom}});v.add(e)}),v.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},cx.convertToPixel=_(Ys,"convertToPixel"),cx.convertFromPixel=_(Ys,"convertFromPixel"),cx.containPixel=function(t,e){var n,i=this._model;return t=Wi(i,t),f(t,function(t,i){i.indexOf("Models")>=0&&f(t,function(t){var r=t.coordinateSystem;if(r&&r.containPoint)n|=!!r.containPoint(e);else if("seriesModels"===i){var a=this._chartsMap[t.__viewId];a&&a.containPoint&&(n|=a.containPoint(e,t))}},this)},this),!!n},cx.getVisual=function(t,e){var n=this._model;t=Wi(n,t,{defaultMainType:"series"});var i=t.seriesModel,r=i.getData(),a=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?r.indexOfRawIndex(t.dataIndex):null;return null!=a?r.getItemVisual(a,e):r.getVisual(e)},cx.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},cx.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var dx={prepareAndUpdate:function(t){qs(this),dx.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,a=this._scheduler;if(e){e.restoreData(t),a.performSeriesTasks(e),r.create(e,n),a.performDataProcessorTasks(vx,e,t),Qs(this,e),il(e),r.update(e,n),rl(e),a.performVisualTasks(_x,e,t),al(this,e,n,t);var o=e.get("backgroundColor")||"transparent",s=i.painter;if(s.isSingleCanvas&&s.isSingleCanvas())i.configLayer(0,{clearColor:o});else{if(!Sp.canvasSupported){var l=Ee(o);o=Ge(l,"rgb"),0===l[3]&&(o="transparent")}o.colorStops||o.image?(i.configLayer(0,{clearColor:o}),this[lx]=!0,this._dom.style.background="transparent"):(this[lx]&&i.configLayer(0,{clearColor:null}),this[lx]=!1,this._dom.style.background=o)}ll(e,n)}},updateTransform:function(t){var e=this._model,n=this,i=this._api;if(e){var r=[];e.eachComponent(function(a,o){var s=n.getViewOfComponentModel(o);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(o,e,i,t);l&&l.update&&r.push(s)}else r.push(s)});var a=N();e.eachSeries(function(r){var o=n._chartsMap[r.__viewId];if(o.updateTransform){var s=o.updateTransform(r,e,i,t);s&&s.update&&a.set(r.uid,1)}else a.set(r.uid,1)}),rl(e),this._scheduler.performVisualTasks(_x,e,t,{setDirty:!0,dirtyMap:a}),sl(n,e,i,t,a),ll(e,this._api)}},updateView:function(t){var e=this._model;e&&(bs.markUpdateMethod(t,"updateView"),rl(e),this._scheduler.performVisualTasks(_x,e,t,{setDirty:!0}),al(this,this._model,this._api,t),ll(e,this._api))},updateVisual:function(t){dx.update.call(this,t)},updateLayout:function(t){dx.update.call(this,t)}};cx.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media");Ks(this,n,t&&t.silent)}},cx.showLoading=function(t,e){if(Y_(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),bx[t]){var n=bx[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},cx.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},cx.makeActionFromEvent=function(t){var e=o({},t);return e.type=gx[t.type],e},cx.dispatchAction=function(t,e){if(Y_(e)||(e={silent:!!e}),px[t.type]&&this._model){if(this[sx])return void this._pendingActions.push(t);Js.call(this,t,e.silent),e.flush?this._zr.flush(!0):e.flush!==!1&&Sp.browser.weChat&&this._throttledZrFlush(),tl.call(this,e.silent),el.call(this,e.silent)}},cx.appendData=function(t){var e=t.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(e);i.appendData(t),this._scheduler.unfinished=!0},cx.on=Us("on"),cx.off=Us("off"),cx.one=Us("one");var fx=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];cx._initEvents=function(){Z_(fx,function(t){this._zr.on(t,function(e){var n,i=this.getModel(),r=e.target;if("globalout"===t)n={};else if(r&&null!=r.dataIndex){var a=r.dataModel||i.getSeriesByIndex(r.seriesIndex);n=a&&a.getDataParams(r.dataIndex,r.dataType)||{}}else r&&r.eventData&&(n=o({},r.eventData));n&&(n.event=e,n.type=t,this.trigger(t,n))},this)},this),Z_(gx,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},cx.isDisposed=function(){return this._disposed},cx.clear=function(){this.setOption({series:[]},!0)},cx.dispose=function(){if(!this._disposed){this._disposed=!0,ji(this.getDom(),Cx,"");var t=this._api,e=this._model;Z_(this._componentsViews,function(n){n.dispose(e,t)}),Z_(this._chartsViews,function(n){n.dispose(e,t)}),this._zr.dispose(),delete Sx[this.id]}},c(Xs,Up);var px={},gx={},vx=[],mx=[],yx=[],_x=[],xx={},bx={},Sx={},Mx={},Tx=new Date-0,Ix=new Date-0,Cx="_echarts_instance_",Dx={},Ax=vl;Dl(nx,A_),wl(h_),kl("default",O_),Ml({type:"highlight",event:"highlight",update:"highlight"},F),Ml({type:"downplay",event:"downplay",update:"downplay"},F),xl("light",F_),xl("dark",j_);var kx={};Vl.prototype={constructor:Vl,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t,e=this._old,n=this._new,i={},r={},a=[],o=[];for(Fl(e,i,a,"_oldKeyGetter",this),Fl(n,r,o,"_newKeyGetter",this),t=0;t<e.length;t++){var s=a[t],l=r[s];if(null!=l){var u=l.length;u?(1===u&&(r[s]=null),l=l.unshift()):r[s]=null,this._update&&this._update(l,t)}else this._remove&&this._remove(t)}for(var t=0;t<o.length;t++){var s=o[t];if(r.hasOwnProperty(s)){var l=r[s];if(null==l)continue;if(l.length)for(var h=0,u=l.length;u>h;h++)this._add&&this._add(l[h]);else this._add&&this._add(l)}}}};var Px=N(["tooltip","label","itemName","itemId","seriesName"]),Lx=S,Ox="undefined",Ex=typeof window===Ox?global:window,Rx="e\x00\x00",zx={"float":typeof Ex.Float64Array===Ox?Array:Ex.Float64Array,"int":typeof Ex.Int32Array===Ox?Array:Ex.Int32Array,ordinal:Array,number:Array,time:Array},Bx=["stackedOn","hasItemOption","_nameList","_idList","_rawData","_rawExtent","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],Nx=function(t,e){t=t||["x","y"];for(var n={},i=[],r=0;r<t.length;r++){var a,o={};"string"==typeof t[r]?(a=t[r],o={name:a,coordDim:a,coordDimIndex:0,stackable:!1,type:"float"}):(o=t[r],a=o.name,o.type=o.type||"float",o.coordDim||(o.coordDim=a,o.coordDimIndex=0)),o.otherDims=o.otherDims||{},i.push(a),n[a]=o,o.index=r}this.dimensions=i,this._dimensionInfos=n,this.hostModel=e,this.dataType,this._indices=null,this._count=0,this._rawCount=0,this._storage={},this._nameList=[],this._idList=[],this._optionModels=[],this.stackedOn=null,this._visual={},this._layout={},this._itemVisuals=[],this.hasItemVisual={},this._itemLayouts=[],this._graphicEls=[],this._chunkSize=1e5,this._chunkCount=0,this._rawData,this._rawExtent={},this._extent={},this._approximateExtent={},this._dimensionsSummary=Hl(this)},Vx=Nx.prototype;Vx.type="list",Vx.hasItemOption=!0,Vx.getDimension=function(t){return isNaN(t)||(t=this.dimensions[t]||t),t},Vx.getDimensionInfo=function(t){return this._dimensionInfos[this.getDimension(t)]},Vx.getDimensionsOnCoord=function(){return this._dimensionsSummary.dataDimsOnCoord.slice()},Vx.mapDimension=function(t,e){var n=this._dimensionsSummary.encode[t];return e===!0?n&&n.slice()||[]:n?n[e||0]:null},Vx.initData=function(t,e,n){var i=_o.isInstance(t)||d(t);i&&(t=new is(t,this.dimensions.length)),this._rawData=t,this._storage={},this._indices=null,this._nameList=e||[],this._idList=[],this._nameRepeatCount={},n||(this.hasItemOption=!1),this.defaultDimValueGetter=p_[this._rawData.getSource().sourceFormat],this._dimValueGetter=n=n||this.defaultDimValueGetter,this._rawExtent={},this._initDataFromProvider(0,t.count()),t.pure&&(this.hasItemOption=!1)},Vx.getProvider=function(){return this._rawData},Vx.appendData=function(t){var e=this._rawData,n=this.count();e.appendData(t);var i=e.count();e.persistent||(i+=n),this._initDataFromProvider(n,i)},Vx._initDataFromProvider=function(t,e){if(!(t>=e)){for(var n,i=this._chunkSize,r=this._rawData,a=this._storage,o=this.dimensions,s=this._dimensionInfos,l=this._nameList,u=this._idList,h=this._rawExtent,c=this._nameRepeatCount={},d=this._chunkCount,f=d-1,p=0;p<o.length;p++){var g=o[p];h[g]||(h[g]=[1/0,-1/0]);var v=s[g];0===v.otherDims.itemName&&(n=this._nameDimIdx=p),0===v.otherDims.itemId&&(this._idDimIdx=p);var m=zx[v.type];a[g]||(a[g]=[]);var y=a[g][f];if(y&&y.length<i){for(var _=new m(Math.min(e-f*i,i)),x=0;x<y.length;x++)_[x]=y[x];a[g][f]=_}for(var w=d*i;e>w;w+=i)a[g].push(new m(Math.min(e-w,i)));this._chunkCount=a[g].length}for(var b=t;e>b;b++){for(var S=r.getItem(b),M=Math.floor(b/i),T=b%%i,w=0;w<o.length;w++){var g=o[w],I=a[g][M],C=this._dimValueGetter(S,g,b,w);I[T]=C,C<h[g][0]&&(h[g][0]=C),C>h[g][1]&&(h[g][1]=C)}if(!r.pure){var D=l[b];S&&!D&&(null!=n?D=this._getNameFromStore(b):null!=S.name&&(l[b]=D=S.name));var A=null==S?null:S.id;null==A&&null!=D&&(c[D]=c[D]||0,A=D,c[D]>0&&(A+="__ec__"+c[D]),c[D]++),null!=A&&(u[b]=A)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={}}},Vx._getNameFromStore=function(t){var e=this._nameDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%%n,a=this.dimensions[e],o=this._dimensionInfos[a].ordinalMeta;if(o)return o.categories[t];var s=this._storage[a][i];return s&&s[r]}},Vx._getIdFromStore=function(t){var e=this._idDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%%n,a=this.dimensions[e],o=this._dimensionInfos[a].ordinalMeta;if(o)return o.categories[t];var s=this._storage[a][i];return s&&s[r]}},Vx.count=function(){return this._count},Vx.getIndices=function(){if(this._indices){var t=this._indices.constructor;return new t(this._indices.buffer,0,this._count)}for(var t=jl(this),e=new t(this.count()),n=0;n<e.length;n++)e[n]=n;return e},Vx.get=function(t,e,n){if(!(e>=0&&e<this._count))return 0/0;var i=this._storage;if(!i[t])return 0/0;e=this.getRawIndex(e);var r=Math.floor(e/this._chunkSize),a=e%%this._chunkSize,o=i[t][r],s=o[a];if(n){var l=this._dimensionInfos[t];if(l&&l.stackable)for(var u=this.stackedOn;u;){var h=u.get(t,e);(s>=0&&h>0||0>=s&&0>h)&&(s+=h),u=u.stackedOn}}return s},Vx._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%%this._chunkSize,r=this._storage[t][n];return r[i]},Vx.getValues=function(t,e,n){var i=[];x(t)||(n=e,e=t,t=this.dimensions);for(var r=0,a=t.length;a>r;r++)i.push(this.get(t[r],e,n));return i},Vx.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=this._dimensionInfos,i=0,r=e.length;r>i;i++)if("ordinal"!==n[e[i]].type&&isNaN(this.get(e[i],t)))return!1;return!0},Vx.getDataExtent=function(t,e){t=this.getDimension(t);var n=this._storage[t],i=[1/0,-1/0];if(e=(e||!1)&&this.isStacked(t),!n)return i;var r,a=this.count(),o=[t,!!e].join("_"),s=!this._indices&&!e;if(s)return this._rawExtent[t].slice();if(r=this._extent[o])return r.slice();r=i;for(var l=r[0],u=r[1],h=0;a>h;h++){var c=e?this.get(t,h,!0):this._getFast(t,this.getRawIndex(h));l>c&&(l=c),c>u&&(u=c)}return r=[l,u],this._extent[o]=r,r},Vx.getApproximateExtent=function(t,e){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t,e)},Vx.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},Vx.isStacked=function(t){var e=this._dimensionInfos[t];return e&&e.stackable&&this.stackedOn},Vx.getSum=function(t,e){var n=this._storage[t],i=0;if(n)for(var r=0,a=this.count();a>r;r++){var o=this.get(t,r,e);isNaN(o)||(i+=o)}return i},Vx.indexOf=function(t,e){var n=this._storage,i=n[t],r=this._chunkSize;if(i)for(var a=0,o=this.count();o>a;a++){var s=Math.floor(a/r),l=a%%r;if(i[s][l]===e)return a}return-1},Vx.indexOfName=function(t){for(var e=0,n=this.count();n>e;e++)if(this.getName(e)===t)return e;return-1},Vx.indexOfRawIndex=function(t){if(!this._indices)return t;if(t>=this._rawCount||0>t)return-1;var e=this._indices,n=e[t];if(null!=n&&n<this._count&&n===t)return t;for(var i=0,r=this._count-1;r>=i;){var a=(i+r)/2|0;if(e[a]<t)i=a+1;else{if(!(e[a]>t))return a;r=a-1}}return-1},Vx.indicesOfNearest=function(t,e,n,i){var r=this._storage,a=r[t],o=[];if(!a)return o;null==i&&(i=1/0);for(var s=Number.MAX_VALUE,l=-1,u=0,h=this.count();h>u;u++){var c=e-this.get(t,u,n),d=Math.abs(c);i>=c&&s>=d&&((s>d||c>=0&&0>l)&&(s=d,l=c,o.length=0),o.push(u))}return o},Vx.getRawIndex=Xl,Vx.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],n=0;n<this.dimensions.length;n++){var i=this.dimensions[n];e.push(this.get(i,t))}return e},Vx.getName=function(t){var e=this.getRawIndex(t);return this._nameList[e]||this._getNameFromStore(e)||""},Vx.getId=function(t){return ql(this,this.getRawIndex(t))},Vx.each=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),t=p($l(t),this.getDimension,this);var r=t.length;i=i||this;for(var a=0;a<this.count();a++)switch(r){case 0:e.call(i,a);break;case 1:e.call(i,this.get(t[0],a,n),a);break;case 2:e.call(i,this.get(t[0],a,n),this.get(t[1],a,n),a);break;default:for(var o=0,s=[];r>o;o++)s[o]=this.get(t[o],a,n);s[o]=a,e.apply(i,s)}}},Vx.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||!1,i=i||this,t=p($l(t),this.getDimension,this);for(var r=this.count(),a=jl(this),o=new a(r),s=[],l=t.length,u=0,h=t[0],c=0;r>c;c++){var d,f=this.getRawIndex(c);if(0===l)d=e.call(i,c);else if(1===l){var g=n?this.get(h,c,!0):this._getFast(h,f);d=e.call(i,g,c)}else{for(var v=0;l>v;v++)s[v]=n?this.get(t[v],c,!0):this._getFast(h,f);s[v]=c,d=e.apply(i,s)}d&&(o[u++]=f)}return r>u&&(this._indices=o),this._count=u,this._extent={},this.getRawIndex=this._indices?Yl:Xl,this}},Vx.selectRange=function(t,e){if(this._count){e=e||!1;var n=[];for(var i in t)t.hasOwnProperty(i)&&n.push(i);var r=n.length;if(r){var a=this.count(),o=jl(this),s=new o(a),l=0,u=n[0],h=t[u][0],c=t[u][1],d=!1;if(!this._indices&&!e){var f=0;if(1===r){for(var p=this._storage[n[0]],g=0;g<this._chunkCount;g++)for(var v=p[g],m=Math.min(this._count-g*this._chunkSize,this._chunkSize),y=0;m>y;y++){var _=v[y];_>=h&&c>=_&&(s[l++]=f),f++}d=!0}else if(2===r){for(var p=this._storage[u],x=this._storage[n[1]],w=t[n[1]][0],b=t[n[1]][1],g=0;g<this._chunkCount;g++)for(var v=p[g],S=x[g],m=Math.min(this._count-g*this._chunkSize,this._chunkSize),y=0;m>y;y++){var _=v[y],M=S[y];_>=h&&c>=_&&M>=w&&b>=M&&(s[l++]=f),f++}d=!0}}if(!d)if(1===r){e=e||this.isStacked(u);for(var y=0;a>y;y++){var T=this.getRawIndex(y),_=e?this.get(u,y,!0):this._getFast(u,T);_>=h&&c>=_&&(s[l++]=T)}}else for(var y=0;a>y;y++){for(var I=!0,T=this.getRawIndex(y),g=0;r>g;g++){var C=n[g],_=e?this.get(C,y,!0):this._getFast(i,T);(_<t[C][0]||_>t[C][1])&&(I=!1)}I&&(s[l++]=this.getRawIndex(y))}return a>l&&(this._indices=s),this._count=l,this._extent={},this.getRawIndex=this._indices?Yl:Xl,this}}},Vx.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]);var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n,i),r},Vx.map=function(t,e,n,i){t=p($l(t),this.getDimension,this);var r=Kl(this,t);r._indices=this._indices,r.getRawIndex=r._indices?Yl:Xl;for(var a=r._storage,o=[],s=this._chunkSize,l=t.length,u=this.count(),h=[],c=0;u>c;c++){for(var d=0;l>d;d++)h[d]=this.get(t[d],c,n);h[l]=c;var f=e&&e.apply(i,h);if(null!=f){"object"!=typeof f&&(o[0]=f,f=o);for(var g=this.getRawIndex(c),v=Math.floor(g/s),m=g%%s,y=0;y<f.length;y++){var _=t[y],x=a[_];x&&(x[v][m]=f[y])}}}return r},Vx.downSample=function(t,e,n,i){for(var r=Kl(this,[t]),a=r._storage,o=[],s=Math.floor(1/e),l=a[t],u=this.count(),h=this._chunkSize,c=new(jl(this))(u),d=0,f=0;u>f;f+=s){s>u-f&&(s=u-f,o.length=s);for(var p=0;s>p;p++){var g=this.getRawIndex(f+p),v=Math.floor(g/h),m=g%%h;o[p]=l[v][m]}var y=n(o),_=this.getRawIndex(Math.min(f+i(o,y)||0,u-1)),x=Math.floor(_/h),w=_%%h;l[x][w]=y,c[d++]=_}return r._count=d,r._indices=c,r.getRawIndex=Yl,r},Vx.getItemModel=function(t){var e=this.hostModel;return new Pa(this.getRawDataItem(t),e,e&&e.ecModel)},Vx.diff=function(t){var e=this;return new Vl(t?t.getIndices():[],this.getIndices(),function(e){return ql(t,e)},function(t){return ql(e,t)})},Vx.getVisual=function(t){var e=this._visual;return e&&e[t]},Vx.setVisual=function(t,e){if(Lx(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},Vx.setLayout=function(t,e){if(Lx(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},Vx.getLayout=function(t){return this._layout[t]},Vx.getItemLayout=function(t){return this._itemLayouts[t]},Vx.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?o(this._itemLayouts[t]||{},e):e},Vx.clearItemLayouts=function(){this._itemLayouts.length=0},Vx.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},Vx.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,Lx(e))for(var a in e)e.hasOwnProperty(a)&&(i[a]=e[a],r[a]=!0);else i[e]=n,r[e]=!0},Vx.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};var Fx=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType};Vx.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse(Fx,e)),this._graphicEls[t]=e},Vx.getItemGraphicEl=function(t){return this._graphicEls[t]},Vx.eachItemGraphicEl=function(t,e){f(this._graphicEls,function(n,i){n&&t&&t.call(e,n,i)})},Vx.cloneShallow=function(t){if(!t){var e=p(this.dimensions,this.getDimensionInfo,this);t=new Nx(e,this.hostModel)}if(t._storage=this._storage,Zl(t,this),this._indices){var n=this._indices.constructor;t._indices=new n(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?Yl:Xl,t._extent=i(this._extent),t._approximateExtent=i(this._approximateExtent),t},Vx.wrapMethod=function(t,e){var n=this[t];"function"==typeof n&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(P(arguments)))})},Vx.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],Vx.CHANGABLE_METHODS=["filterSelf","selectRange"];var Hx=function(t,e){return e=e||{},Jl(e.coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,extraPrefix:e.extraPrefix,extraFromZero:e.extraFromZero})};ou.prototype.parse=function(t){return t},ou.prototype.getSetting=function(t){return this._setting[t]},ou.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},ou.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},ou.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},ou.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},ou.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e,!0))},ou.prototype.getExtent=function(){return this._extent.slice()},ou.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},ou.prototype.getTicksLabels=function(){for(var t=[],e=this.getTicks(),n=0;n<e.length;n++)t.push(this.getLabel(e[n]));return t},ou.prototype.isBlank=function(){return this._isBlank},ou.prototype.setBlank=function(t){this._isBlank=t},Yi(ou),Qi(ou,{registerWhenExtend:!0}),su.createByAxisModel=function(t){var e=t.option,n=e.data,i=n&&p(n,uu);return new su({categories:i,needCollect:!i,deduplication:e.dedplication!==!1})};var Wx=su.prototype;Wx.getOrdinal=function(t){return lu(this).get(t)},Wx.parseAndCollect=function(t){var e,n=this._needCollect;if("string"!=typeof t&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var i=lu(this);return e=i.get(t),null==e&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=0/0),e};var Gx=ou.prototype,jx=ou.extend({type:"ordinal",init:function(t,e){(!t||x(t))&&(t=new su({categories:t})),this._ordinalMeta=t,this._extent=e||[0,t.categories.length-1]},parse:function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},contain:function(t){return t=this.parse(t),Gx.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return Gx.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(Gx.scale.call(this,t))},getTicks:function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push(n),n++;return t},getLabel:function(t){return this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e,!1))},niceTicks:F,niceExtent:F});jx.create=function(){return new jx};var Ux=Fa,Zx=Fa,Xx=ou.extend({type:"interval",_interval:0,_intervalPrecision:2,setExtent:function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},unionExtent:function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]),Xx.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=cu(t)},getTicks:function(){return pu(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getTicksLabels:function(){for(var t=[],e=this.getTicks(),n=0;n<e.length;n++)t.push(this.getLabel(e[n]));return t},getLabel:function(t,e){if(null==t)return"";var n=e&&e.precision;return null==n?n=Ga(t)||0:"auto"===n&&(n=this._intervalPrecision),t=Zx(t,n,!0),to(t)},niceTicks:function(t,e,n){t=t||5;var i=this._extent,r=i[1]-i[0];if(isFinite(r)){0>r&&(r=-r,i.reverse());var a=hu(i,t,e,n);this._intervalPrecision=a.intervalPrecision,this._interval=a.interval,this._niceExtent=a.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var n=e[0];t.fixMax?e[0]-=n/2:(e[1]+=n/2,e[0]-=n/2)}else e[1]=1;var i=e[1]-e[0];isFinite(i)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var r=this._interval;t.fixMin||(e[0]=Zx(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=Zx(Math.ceil(e[1]/r)*r))}});Xx.create=function(){return new Xx};var Yx="__ec_stack_",qx=Xx.prototype,$x=Math.ceil,Kx=Math.floor,Qx=1e3,Jx=60*Qx,tw=60*Jx,ew=24*tw,nw=function(t,e,n,i){for(;i>n;){var r=n+i>>>1;t[r][1]<e?n=r+1:i=r}return n},iw=Xx.extend({type:"time",getLabel:function(t){var e=this._stepLvl,n=new Date(t);return oo(e[0],n,this.getSetting("useUTC"))},niceExtent:function(t){var e=this._extent;if(e[0]===e[1]&&(e[0]-=ew,e[1]+=ew),e[1]===-1/0&&1/0===e[0]){var n=new Date;e[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),e[0]=e[1]-ew}this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var i=this._interval;t.fixMin||(e[0]=Fa(Kx(e[0]/i)*i)),t.fixMax||(e[1]=Fa($x(e[1]/i)*i))},niceTicks:function(t,e,n){t=t||10;var i=this._extent,r=i[1]-i[0],a=r/t;null!=e&&e>a&&(a=e),null!=n&&a>n&&(a=n);var o=rw.length,s=nw(rw,a,0,o),l=rw[Math.min(s,o-1)],u=l[1];if("year"===l[0]){var h=r/u,c=Ka(h/t,!0);u*=c}var d=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,f=[Math.round($x((i[0]-d)/u)*u+d),Math.round(Kx((i[1]-d)/u)*u+d)];fu(f,i),this._stepLvl=l,this._interval=u,this._niceExtent=f},parse:function(t){return+Ya(t)}});f(["contain","normalize"],function(t){iw.prototype[t]=function(e){return qx[t].call(this,this.parse(e))}});var rw=[["hh:mm:ss",Qx],["hh:mm:ss",5*Qx],["hh:mm:ss",10*Qx],["hh:mm:ss",15*Qx],["hh:mm:ss",30*Qx],["hh:mm\nMM-dd",Jx],["hh:mm\nMM-dd",5*Jx],["hh:mm\nMM-dd",10*Jx],["hh:mm\nMM-dd",15*Jx],["hh:mm\nMM-dd",30*Jx],["hh:mm\nMM-dd",tw],["hh:mm\nMM-dd",2*tw],["hh:mm\nMM-dd",6*tw],["hh:mm\nMM-dd",12*tw],["MM-dd\nyyyy",ew],["MM-dd\nyyyy",2*ew],["MM-dd\nyyyy",3*ew],["MM-dd\nyyyy",4*ew],["MM-dd\nyyyy",5*ew],["MM-dd\nyyyy",6*ew],["week",7*ew],["MM-dd\nyyyy",10*ew],["week",14*ew],["week",21*ew],["month",31*ew],["week",42*ew],["month",62*ew],["week",42*ew],["quarter",380*ew/4],["month",31*ew*4],["month",31*ew*5],["half-year",380*ew/2],["month",31*ew*8],["month",31*ew*10],["year",380*ew]];iw.create=function(t){return new iw({useUTC:t.ecModel.get("useUTC")})};var aw=ou.prototype,ow=Xx.prototype,sw=Ga,lw=Fa,uw=Math.floor,hw=Math.ceil,cw=Math.pow,dw=Math.log,fw=ou.extend({type:"log",base:10,$constructor:function(){ou.apply(this,arguments),this._originalScale=new Xx},getTicks:function(){var t=this._originalScale,e=this._extent,n=t.getExtent();return p(ow.getTicks.call(this),function(i){var r=Fa(cw(this.base,i));return r=i===e[0]&&t.__fixMin?_u(r,n[0]):r,r=i===e[1]&&t.__fixMax?_u(r,n[1]):r},this)},getLabel:ow.getLabel,scale:function(t){return t=aw.scale.call(this,t),cw(this.base,t)},setExtent:function(t,e){var n=this.base;t=dw(t)/dw(n),e=dw(e)/dw(n),ow.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=aw.getExtent.call(this);e[0]=cw(t,e[0]),e[1]=cw(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=_u(e[0],i[0])),n.__fixMax&&(e[1]=_u(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=dw(t[0])/dw(e),t[1]=dw(t[1])/dw(e),aw.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e,!0,function(t){return t>0}))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(1/0===n||0>=n)){var i=qa(n),r=t/n*i;for(.5>=r&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var a=[Fa(hw(e[0]/i)*i),Fa(uw(e[1]/i)*i)];this._interval=i,this._niceExtent=a}},niceExtent:function(t){ow.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});f(["contain","normalize"],function(t){fw.prototype[t]=function(e){return e=dw(e)/dw(this.base),aw[t].call(this,e)}}),fw.create=function(){return new fw};var pw={getFormattedLabels:function(){return Tu(this.axis,this.get("axisLabel.formatter"))},getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null!=t.rangeStart||null!=t.rangeEnd?!1:!t.scale},getCoordSysModel:F,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},gw=Gr({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i+a),t.lineTo(n-r,i+a),t.closePath()}}),vw=Gr({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i),t.lineTo(n,i+a),t.lineTo(n-r,i),t.closePath()}}),mw=Gr({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,a=Math.max(r,e.height),o=r/2,s=o*o/(a-o),l=i-a+o+s,u=Math.asin(s/o),h=Math.cos(u)*o,c=Math.sin(u),d=Math.cos(u),f=.6*o,p=.7*o;t.moveTo(n-h,l+s),t.arc(n,l,o,Math.PI-u,2*Math.PI+u),t.bezierCurveTo(n+h-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-h+c*f,l+s+d*f,n-h,l+s),t.closePath()}}),yw=Gr({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,r=e.x,a=e.y,o=i/3*2;t.moveTo(r,a),t.lineTo(r+o,a+n),t.lineTo(r,a+n/4*3),t.lineTo(r-o,a+n),t.lineTo(r,a),t.closePath()}}),_w={line:qm,rect:Ym,roundRect:Ym,square:Ym,circle:Vm,diamond:vw,pin:mw,arrow:yw,triangle:gw},xw={line:function(t,e,n,i,r){r.x1=t,r.y1=e+i/2,r.x2=t+n,r.y2=e+i/2},rect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i},roundRect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(t,e,n,i,r){var a=Math.min(n,i);r.x=t,r.y=e,r.width=a,r.height=a},circle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.r=Math.min(n,i)/2},diamond:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i},pin:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},arrow:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},triangle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i}},ww={};f(_w,function(t,e){ww[e]=new t});var bw=Gr({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},beforeBrush:function(){var t=this.style,e=this.shape;"pin"===e.symbolType&&"inside"===t.textPosition&&(t.textPosition=["50%%","40%%"],t.textAlign="center",t.textVerticalAlign="middle")},buildPath:function(t,e,n){var i=e.symbolType,r=ww[i];"none"!==e.symbolType&&(r||(i="rect",r=ww[i]),xw[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n))}}),Sw=(Object.freeze||Object)({createList:Au,getLayoutRect:uo,createScale:ku,mixinAxisModelCommonMethods:Pu,completeDimensions:Jl,createDimensions:Hx,createSymbol:Du}),Mw=1e-8;Eu.prototype={constructor:Eu,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,n=[e,e],i=[-e,-e],r=[],a=[],o=this.geometries,s=0;s<o.length;s++)if("polygon"===o[s].type){var l=o[s].exterior;fr(l,r,a),oe(n,n,r),se(i,i,a)}return 0===s&&(n[0]=n[1]=i[0]=i[1]=0),this._rect=new rn(n[0],n[1],i[0]-n[0],i[1]-n[1])},contain:function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,r=n.length;r>i;i++)if("polygon"===n[i].type){var a=n[i].exterior,o=n[i].interiors;if(Ou(a,t[0],t[1])){for(var s=0;s<(o?o.length:0);s++)if(Ou(o[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=r.width/r.height;n?i||(i=n/a):n=a*i;for(var o=new rn(t,e,n,i),s=r.calculateTransform(o),l=this.geometries,u=0;u<l.length;u++)if("polygon"===l[u].type){for(var h=l[u].exterior,c=l[u].interiors,d=0;d<h.length;d++)ae(h[d],h[d],s);for(var f=0;f<(c?c.length:0);f++)for(var d=0;d<c[f].length;d++)ae(c[f][d],c[f][d],s)}r=this._rect,r.copy(o),this.center=[r.x+r.width/2,r.y+r.height/2]}};var Tw=function(t){return Ru(t),p(v(t.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,r=[];"Polygon"===n.type&&r.push({type:"polygon",exterior:i[0],interiors:i.slice(1)}),"MultiPolygon"===n.type&&f(i,function(t){t[0]&&r.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var a=new Eu(e.name,r,e.cp);return a.properties=e,a})},Iw=Na,Cw=[0,1],Dw=function(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1,this._labelInterval};Dw.prototype={constructor:Dw,contain:function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return t>=n&&i>=t},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return ja(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var n=this._extent;n[0]=t,n[1]=e},dataToCoord:function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&(n=n.slice(),Bu(n,i.count())),Iw(t,Cw,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&(n=n.slice(),Bu(n,i.count()));var r=Iw(t,n,Cw,e);return this.scale.scale(r)},pointToData:function(){},getTicksCoords:function(t){if(this.onBand&&!t){for(var e=this.getBands(),n=[],i=0;i<e.length;i++)n.push(e[i][0]);return e[i-1]&&n.push(e[i-1][1]),n}return p(this.scale.getTicks(),this.dataToCoord,this)},getLabelsCoords:function(){return p(this.scale.getTicks(),this.dataToCoord,this)},getBands:function(){for(var t=this.getExtent(),e=[],n=this.scale.count(),i=t[0],r=t[1],a=r-i,o=0;n>o;o++)e.push([a*o/n+i,a*(o+1)/n+i]);return e},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},isHorizontal:null,getRotate:null,getLabelInterval:function(){var t=this._labelInterval;if(!t){var e=this.model,n=e.getModel("axisLabel");t=n.get("interval"),"category"!==this.type||null!=t&&"auto"!==t||(t=Mu(p(this.scale.getTicks(),this.dataToCoord,this),e.getFormattedLabels(),n.getFont(),this.getRotate?this.getRotate():this.isHorizontal&&!this.isHorizontal()?90:0,n.get("rotate"))),this._labelInterval=t}return t}};var Aw=Tw,kw={};f(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){kw[t]=Bp[t]});var Pw=function(t){this._directed=t||!1,this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this.data,this.edgeData},Lw=Pw.prototype;Lw.type="graph",Lw.isDirected=function(){return this._directed},Lw.addNode=function(t,e){t=t||""+e;var n=this._nodesMap;if(!n[Nu(t)]){var i=new Vu(t,e);return i.hostGraph=this,this.nodes.push(i),n[Nu(t)]=i,i}},Lw.getNodeByIndex=function(t){var e=this.data.getRawIndex(t);return this.nodes[e]},Lw.getNodeById=function(t){return this._nodesMap[Nu(t)]},Lw.addEdge=function(t,e,n){var i=this._nodesMap,r=this._edgesMap;if("number"==typeof t&&(t=this.nodes[t]),"number"==typeof e&&(e=this.nodes[e]),Vu.isInstance(t)||(t=i[Nu(t)]),Vu.isInstance(e)||(e=i[Nu(e)]),t&&e){var a=t.id+"-"+e.id;if(!r[a]){var o=new Fu(t,e,n);return o.hostGraph=this,this._directed&&(t.outEdges.push(o),e.inEdges.push(o)),t.edges.push(o),t!==e&&e.edges.push(o),this.edges.push(o),r[a]=o,o}}},Lw.getEdgeByIndex=function(t){var e=this.edgeData.getRawIndex(t);return this.edges[e]},Lw.getEdge=function(t,e){Vu.isInstance(t)&&(t=t.id),Vu.isInstance(e)&&(e=e.id);var n=this._edgesMap;return this._directed?n[t+"-"+e]:n[t+"-"+e]||n[e+"-"+t]},Lw.eachNode=function(t,e){for(var n=this.nodes,i=n.length,r=0;i>r;r++)n[r].dataIndex>=0&&t.call(e,n[r],r)},Lw.eachEdge=function(t,e){for(var n=this.edges,i=n.length,r=0;i>r;r++)n[r].dataIndex>=0&&n[r].node1.dataIndex>=0&&n[r].node2.dataIndex>=0&&t.call(e,n[r],r)},Lw.breadthFirstTraverse=function(t,e,n,i){if(Vu.isInstance(e)||(e=this._nodesMap[Nu(e)]),e){for(var r="out"===n?"outEdges":"in"===n?"inEdges":"edges",a=0;a<this.nodes.length;a++)this.nodes[a].__visited=!1;if(!t.call(i,e,null))for(var o=[e];o.length;)for(var s=o.shift(),l=s[r],a=0;a<l.length;a++){var u=l[a],h=u.node1===s?u.node2:u.node1;if(!h.__visited){if(t.call(i,h,s))return;o.push(h),h.__visited=!0}}}},Lw.update=function(){for(var t=this.data,e=this.edgeData,n=this.nodes,i=this.edges,r=0,a=n.length;a>r;r++)n[r].dataIndex=-1;for(var r=0,a=t.count();a>r;r++)n[t.getRawIndex(r)].dataIndex=r;e.filterSelf(function(t){var n=i[e.getRawIndex(t)];return n.node1.dataIndex>=0&&n.node2.dataIndex>=0});for(var r=0,a=i.length;a>r;r++)i[r].dataIndex=-1;for(var r=0,a=e.count();a>r;r++)i[e.getRawIndex(r)].dataIndex=r},Lw.clone=function(){for(var t=new Pw(this._directed),e=this.nodes,n=this.edges,i=0;i<e.length;i++)t.addNode(e[i].id,e[i].dataIndex);for(var i=0;i<n.length;i++){var r=n[i];t.addEdge(r.node1.id,r.node2.id,r.dataIndex)}return t},Vu.prototype={constructor:Vu,degree:function(){return this.edges.length},inDegree:function(){return this.inEdges.length},outDegree:function(){return this.outEdges.length},getModel:function(t){if(!(this.dataIndex<0)){var e=this.hostGraph,n=e.data.getItemModel(this.dataIndex);return n.getModel(t)}}},Fu.prototype.getModel=function(t){if(!(this.dataIndex<0)){var e=this.hostGraph,n=e.edgeData.getItemModel(this.dataIndex);return n.getModel(t)}};var Ow=function(t,e){return{getValue:function(n){var i=this[t][e];return i.get(i.getDimension(n||"value"),this.dataIndex)},setVisual:function(n,i){this.dataIndex>=0&&this[t][e].setItemVisual(this.dataIndex,n,i)},getVisual:function(n,i){return this[t][e].getItemVisual(this.dataIndex,n,i)},setLayout:function(n,i){this.dataIndex>=0&&this[t][e].setItemLayout(this.dataIndex,n,i)},getLayout:function(){return this[t][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[t][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[t][e].getRawIndex(this.dataIndex)}}};c(Vu,Ow("hostGraph","data")),c(Fu,Ow("hostGraph","edgeData")),Pw.Node=Vu,Pw.Edge=Fu,qi(Vu),qi(Fu);var Ew=f,Rw="\x00__link_datas",zw="\x00__link_mainData",Bw=function(t,e,n,i,r){for(var a=new Pw(i),o=0;o<t.length;o++)a.addNode(D(t[o].id,t[o].name,o),o);for(var s=[],l=[],u=0,o=0;o<e.length;o++){var h=e[o],c=h.source,d=h.target;a.addEdge(c,d,u)&&(l.push(h),s.push(D(h.id,c+" > "+d)),u++)}var f,p=n.get("coordinateSystem");if("cartesian2d"===p||"polar"===p)f=nu(t,n);else{var g=Vo.get(p),v=Hx(t,{coordDimensions:(g&&"view"!==g.type?g.dimensions||[]:[]).concat(["value"])});f=new Nx(v,n),f.initData(t)}var m=new Nx(["value"],n);return m.initData(l,s),r&&r(f,m),Hu({mainData:f,struct:a,structAttr:"graph",datas:{node:f,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),a.update(),a},Nw=Ol({type:"series.graph",init:function(t){Nw.superApply(this,"init",arguments),this.legendDataProvider=function(){return this._categoriesData},this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},mergeOption:function(t){Nw.superApply(this,"mergeOption",arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},mergeDefaultAndTheme:function(t){Nw.superApply(this,"mergeDefaultAndTheme",arguments),Ei(t,["edgeLabel"],["show"])},getInitialData:function(t,e){function n(t,n){function i(t){return t=this.parsePath(t),t&&"label"===t[0]?o:this.parentModel}t.wrapMethod("getItemModel",function(t){var e=a._categoriesModels,n=t.getShallow("category"),i=e[n];return i&&(i.parentModel=t.parentModel,t.parentModel=i),t});var r=a.getModel("edgeLabel"),o=new Pa({label:r.option},r.parentModel,e);n.wrapMethod("getItemModel",function(t){return t.customizeGetParent(i),t})}var i=t.edges||t.links||[],r=t.data||t.nodes||[],a=this;return r&&i?Bw(r,i,this,!0,n).data:void 0},getGraph:function(){return this.getData().graph},getEdgeData:function(){return this.getGraph().edgeData},getCategoriesData:function(){return this._categoriesData},formatTooltip:function(t,e,n){if("edge"===n){var i=this.getData(),r=this.getDataParams(t,n),a=i.graph.getEdgeByIndex(t),o=i.getName(a.node1.dataIndex),s=i.getName(a.node2.dataIndex),l=[];return null!=o&&l.push(o),null!=s&&l.push(s),l=no(l.join(" > ")),r.value&&(l+=" : "+no(r.value)),l}return Nw.superApply(this,"formatTooltip",arguments)},_updateCategoriesData:function(){var t=p(this.option.categories||[],function(t){return null!=t.value?t:o({value:0},t)}),e=new Nx(["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray(function(t){return e.getItemModel(t,!0)})},setZoom:function(t){this.option.zoom=t},setCenter:function(t){this.option.center=t},isAnimationEnabled:function(){return Nw.superCall(this,"isAnimationEnabled")&&!("force"===this.get("layout")&&this.get("force.layoutAnimation"))},defaultOption:{zlevel:0,z:2,coordinateSystem:"view",legendHoverLink:!0,hoverAnimation:!0,layout:null,focusNodeAdjacency:!1,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle"},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,curveness:0,opacity:.5},emphasis:{label:{show:!0}}}}),Vw=Qu.prototype;Vw._createSymbol=function(t,e,n,i){this.removeAll();var r=e.getItemVisual(n,"color"),a=Du(t,-1,-1,2,2,r);a.attr({z2:100,culling:!0,scale:Ku(i)}),a.drift=Ju,this._symbolType=t,this.add(a)},Vw.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},Vw.getSymbolPath=function(){return this.childAt(0)},Vw.getScale=function(){return this.childAt(0).scale},Vw.highlight=function(){this.childAt(0).trigger("emphasis")},Vw.downplay=function(){this.childAt(0).trigger("normal")},Vw.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},Vw.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":"pointer"},Vw.updateData=function(t,e,n){this.silent=!1;var i=t.getItemVisual(e,"symbol")||"circle",r=t.hostModel,a=$u(t,e),o=i!==this._symbolType;if(o)this._createSymbol(i,t,e,a);else{var s=this.childAt(0);s.silent=!1,ba(s,{scale:Ku(a)},r,e)}if(this._updateCommon(t,e,a,n),o){var s=this.childAt(0),l=n&&n.fadeIn,u={scale:s.scale.slice()};l&&(u.style={opacity:s.style.opacity}),s.scale=[0,0],l&&(s.style.opacity=0),Sa(s,u,r,e)}this._seriesModel=r};var Fw=["itemStyle"],Hw=["emphasis","itemStyle"],Ww=["label"],Gw=["emphasis","label"];Vw._updateCommon=function(t,e,n,i){function r(e){return x?t.getName(e):qu(t,e)}var a=this.childAt(0),s=t.hostModel,l=t.getItemVisual(e,"color");"image"!==a.type&&a.useStyle({strokeNoScale:!0});var u=i&&i.itemStyle,h=i&&i.hoverItemStyle,c=i&&i.symbolRotate,d=i&&i.symbolOffset,f=i&&i.labelModel,p=i&&i.hoverLabelModel,g=i&&i.hoverAnimation,v=i&&i.cursorStyle;if(!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(e);u=m.getModel(Fw).getItemStyle(["color"]),h=m.getModel(Hw).getItemStyle(),c=m.getShallow("symbolRotate"),d=m.getShallow("symbolOffset"),f=m.getModel(Ww),p=m.getModel(Gw),g=m.getShallow("hoverAnimation"),v=m.getShallow("cursor")}else h=o({},h);var y=a.style;a.attr("rotation",(c||0)*Math.PI/180||0),d&&a.attr("position",[Va(d[0],n[0]),Va(d[1],n[1])]),v&&a.attr("cursor",v),a.setColor(l,i&&i.symbolInnerColor),a.setStyle(u);var _=t.getItemVisual(e,"opacity");null!=_&&(y.opacity=_);var x=i&&i.useNameLabel;ca(y,h,f,p,{labelFetcher:s,labelDataIndex:e,defaultText:r,isRectText:!0,autoColor:l}),a.off("mouseover").off("mouseout").off("emphasis").off("normal"),a.hoverStyle=h,ha(a);var w=Ku(n);if(g&&s.isAnimationEnabled()){var b=function(){var t=w[1]/w[0];this.animateTo({scale:[Math.max(1.1*w[0],w[0]+3),Math.max(1.1*w[1],w[1]+3*t)]},400,"elasticOut")},S=function(){this.animateTo({scale:w},400,"elasticOut")};a.on("mouseover",b).on("mouseout",S).on("emphasis",b).on("normal",S)}},Vw.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,!(e&&e.keepLabel)&&(n.style.text=null),ba(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},h(Qu,Ig);var jw=th.prototype;jw.updateData=function(t,e){var n=this.group,i=t.hostModel,r=this._data,a=this._symbolCtor,o=nh(t);r||n.removeAll(),t.diff(r).add(function(i){var r=t.getItemLayout(i);if(eh(t,r,i,e)){var s=new a(t,i,o);s.attr("position",r),t.setItemGraphicEl(i,s),n.add(s)}}).update(function(s,l){var u=r.getItemGraphicEl(l),h=t.getItemLayout(s);return eh(t,h,s,e)?(u?(u.updateData(t,s,o),ba(u,{position:h},i)):(u=new a(t,s),u.attr("position",h)),n.add(u),void t.setItemGraphicEl(s,u)):void n.remove(u)}).remove(function(t){var e=r.getItemGraphicEl(t);e&&e.fadeOut(function(){n.remove(e)})}).execute(),this._data=t},jw.isPersistent=function(){return!0},jw.updateLayout=function(){var t=this._data;t&&t.eachItemGraphicEl(function(e,n){var i=t.getItemLayout(n);e.attr("position",i)})},jw.incrementalPrepareUpdate=function(t){this._seriesScope=nh(t),this._data=null,this.group.removeAll()},jw.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}for(var r=t.start;r<t.end;r++){var a=e.getItemLayout(r);if(eh(e,a,r,n)){var o=new this._symbolCtor(e,r,this._seriesScope);o.traverse(i),o.attr("position",a),this.group.add(o),e.setItemGraphicEl(r,o)}}},jw.remove=function(t){var e=this.group,n=this._data;n&&(t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll())};var Uw=qm.prototype,Zw=Km.prototype,Xw=Gr({type:"ec-line",style:{stroke:"#000",fill:null},shape:{x1:0,y1:0,x2:0,y2:0,percent:1,cpx1:null,cpy1:null},buildPath:function(t,e){(ih(e)?Uw:Zw).buildPath(t,e)},pointAt:function(t){return ih(this.shape)?Uw.pointAt.call(this,t):Zw.pointAt.call(this,t)},tangentAt:function(t){var e=this.shape,n=ih(e)?[e.x2-e.x1,e.y2-e.y1]:Zw.tangentAt.call(this,t);return te(n,n)}}),Yw=["fromSymbol","toSymbol"],qw=uh.prototype;qw.beforeUpdate=lh,qw._createLine=function(t,e,n){var i=t.hostModel,r=t.getItemLayout(e),a=oh(r);a.shape.percent=0,Sa(a,{shape:{percent:1}},i,e),this.add(a);var o=new Nm({name:"label"});this.add(o),f(Yw,function(n){var i=ah(n,t,e);this.add(i),this[rh(n)]=t.getItemVisual(e,n)},this),this._updateCommonStl(t,e,n)},qw.updateData=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),a=t.getItemLayout(e),o={shape:{}};sh(o.shape,a),ba(r,o,i,e),f(Yw,function(n){var i=t.getItemVisual(e,n),r=rh(n);if(this[r]!==i){this.remove(this.childOfName(n));var a=ah(n,t,e);this.add(a)}this[r]=i},this),this._updateCommonStl(t,e,n)},qw._updateCommonStl=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),a=n&&n.lineStyle,o=n&&n.hoverLineStyle,l=n&&n.labelModel,u=n&&n.hoverLabelModel;if(!n||t.hasItemOption){var h=t.getItemModel(e);a=h.getModel("lineStyle").getLineStyle(),o=h.getModel("emphasis.lineStyle").getLineStyle(),l=h.getModel("label"),u=h.getModel("emphasis.label")}var c=t.getItemVisual(e,"color"),d=k(t.getItemVisual(e,"opacity"),a.opacity,1);r.useStyle(s({strokeNoScale:!0,fill:"none",stroke:c,opacity:d},a)),r.hoverStyle=o,f(Yw,function(t){var e=this.childOfName(t);e&&(e.setColor(c),e.setStyle({opacity:d}))},this);var p,g,v,m=l.getShallow("show"),y=u.getShallow("show"),_=this.childOfName("label");if(m||y){if(p=c||"#000",g=i.getFormattedLabel(e,"normal",t.dataType),null==g){var x=i.getRawValue(e);g=null==x?t.getName(e):isFinite(x)?Fa(x):x}v=A(i.getFormattedLabel(e,"emphasis",t.dataType),g)}if(m){var w=da(_.style,l,{text:g},{autoColor:p});_.__textAlign=w.textAlign,_.__verticalAlign=w.textVerticalAlign,_.__position=l.get("position")||"middle"}else _.setStyle("text",null);_.hoverStyle=y?{text:v,textFill:u.getTextColor(!0),fontStyle:u.getShallow("fontStyle"),fontWeight:u.getShallow("fontWeight"),fontSize:u.getShallow("fontSize"),fontFamily:u.getShallow("fontFamily")}:{text:null},_.ignore=!m&&!y,ha(this)},qw.highlight=function(){this.trigger("emphasis")},qw.downplay=function(){this.trigger("normal")},qw.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},qw.setLinePoints=function(t){var e=this.childOfName("line");sh(e.shape,t),e.dirty()},h(uh,Ig);var $w=hh.prototype;$w.isPersistent=function(){return!0},$w.updateData=function(t){var e=this,n=e.group,i=e._lineData;e._lineData=t,i||n.removeAll();var r=fh(t);t.diff(i).add(function(n){ch(e,t,n,r)}).update(function(n,a){dh(e,i,t,a,n,r)}).remove(function(t){n.remove(i.getItemGraphicEl(t))}).execute()},$w.updateLayout=function(){var t=this._lineData;t.eachItemGraphicEl(function(e,n){e.updateLayout(t,n)},this)},$w.incrementalPrepareUpdate=function(t){this._seriesScope=fh(t),this._lineData=null,this.group.removeAll()},$w.incrementalUpdate=function(t,e){function n(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}for(var i=t.start;i<t.end;i++){var r=e.getItemLayout(i);if(gh(r)){var a=new this._ctor(e,i,this._seriesScope);a.traverse(n),this.group.add(a)}}},$w.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},$w._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()};var Kw="\x00_ec_interaction_mutex";Ml({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),c(xh,Up);var Qw={axisPointer:1,tooltip:1,brush:1},Jw=[],tb=[],eb=[],nb=sr,ib=Wp,rb=Math.abs,ab=function(t,e){function n(t){var e=t.getVisual("symbolSize");return e instanceof Array&&(e=(e[0]+e[1])/2),e}var i=[],r=cr,a=[[],[],[]],o=[[],[]],s=[];e/=2,t.eachEdge(function(t){var l=t.getLayout(),u=t.getVisual("fromSymbol"),h=t.getVisual("toSymbol");l.__original||(l.__original=[G(l[0]),G(l[1])],l[2]&&l.__original.push(G(l[2])));var c=l.__original;if(null!=l[2]){if(W(a[0],c[0]),W(a[1],c[2]),W(a[2],c[1]),u&&"none"!=u){var d=n(t.node1),f=Ph(a,c[0],d*e);r(a[0][0],a[1][0],a[2][0],f,i),a[0][0]=i[3],a[1][0]=i[4],r(a[0][1],a[1][1],a[2][1],f,i),a[0][1]=i[3],a[1][1]=i[4]}if(h&&"none"!=h){var d=n(t.node2),f=Ph(a,c[1],d*e);r(a[0][0],a[1][0],a[2][0],f,i),a[1][0]=i[1],a[2][0]=i[2],r(a[0][1],a[1][1],a[2][1],f,i),a[1][1]=i[1],a[2][1]=i[2]}W(l[0],a[0]),W(l[1],a[2]),W(l[2],a[1])}else{if(W(o[0],c[0]),W(o[1],c[1]),X(s,o[1],o[0]),te(s,s),u&&"none"!=u){var d=n(t.node1);Z(o[0],o[0],s,d*e)}if(h&&"none"!=h){var d=n(t.node2);Z(o[1],o[1],s,-d*e)}W(l[0],o[0]),W(l[1],o[1])}})},ob=["itemStyle","opacity"],sb=["lineStyle","opacity"];El({type:"graph",init:function(t,e){var n=new th,i=new hh,r=this.group;this._controller=new xh(e.getZr()),this._controllerHost={target:r},r.add(n.group),r.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},render:function(t,e,n){var i=t.coordinateSystem;this._model=t,this._nodeScaleRatio=t.get("nodeScaleRatio");var r=this._symbolDraw,a=this._lineDraw,o=this.group;if("view"===i.type){var s={position:i.position,scale:i.scale};this._firstRender?o.attr(s):ba(o,s,t)}ab(t.getGraph(),this._getNodeGlobalScale(t));var l=t.getData();r.updateData(l);var u=t.getEdgeData();a.updateData(u),this._updateNodeAndLinkScale(),this._updateController(t,e,n),clearTimeout(this._layoutTimeout);var h=t.forceLayout,c=t.get("force.layoutAnimation");h&&this._startForceLayoutIteration(h,c),l.eachItemGraphicEl(function(e,i){var r=l.getItemModel(i);e.off("drag").off("dragend");var a=l.getItemModel(i).get("draggable");a&&e.on("drag",function(){h&&(h.warmUp(),!this._layouting&&this._startForceLayoutIteration(h,c),h.setFixed(i),l.setItemLayout(i,e.position))},this).on("dragend",function(){h&&h.setUnfixed(i)},this),e.setDraggable(a&&h),e.off("mouseover",e.__focusNodeAdjacency),e.off("mouseout",e.__unfocusNodeAdjacency),r.get("focusNodeAdjacency")&&(e.on("mouseover",e.__focusNodeAdjacency=function(){n.dispatchAction({type:"focusNodeAdjacency",seriesId:t.id,dataIndex:e.dataIndex})}),e.on("mouseout",e.__unfocusNodeAdjacency=function(){n.dispatchAction({type:"unfocusNodeAdjacency",seriesId:t.id})}))},this),l.graph.eachEdge(function(e){var i=e.getGraphicEl();i.off("mouseover",i.__focusNodeAdjacency),i.off("mouseout",i.__unfocusNodeAdjacency),e.getModel().get("focusNodeAdjacency")&&(i.on("mouseover",i.__focusNodeAdjacency=function(){n.dispatchAction({type:"focusNodeAdjacency",seriesId:t.id,edgeDataIndex:e.dataIndex})}),i.on("mouseout",i.__unfocusNodeAdjacency=function(){n.dispatchAction({type:"unfocusNodeAdjacency",seriesId:t.id})}))});var d="circular"===t.get("layout")&&t.get("circular.rotateLabel"),f=l.getLayout("cx"),p=l.getLayout("cy");l.eachItemGraphicEl(function(t,e){var n=t.getSymbolPath();if(d){var i=l.getItemLayout(e),r=Math.atan2(i[1]-p,i[0]-f);0>r&&(r=2*Math.PI+r);var a=i[0]<f;a&&(r-=Math.PI);var o=a?"left":"right";n.setStyle({textRotation:-r,textPosition:o,textOrigin:"center"}),n.hoverStyle&&(n.hoverStyle.textPosition=o)}else n.setStyle({textRotation:0})}),this._firstRender=!1},dispose:function(){this._controller&&this._controller.dispose(),this._controllerHost={}},focusNodeAdjacency:function(t,e,n,i){var r=this._model.getData(),a=r.graph,o=i.dataIndex,s=i.edgeDataIndex,l=a.getNodeByIndex(o),u=a.getEdgeByIndex(s);(l||u)&&(a.eachNode(function(t){Oh(t,ob,.1)}),a.eachEdge(function(t){Oh(t,sb,.1)}),l&&(Eh(l,ob),f(l.edges,function(t){t.dataIndex<0||(Eh(t,sb),Eh(t.node1,ob),Eh(t.node2,ob))})),u&&(Eh(u,sb),Eh(u.node1,ob),Eh(u.node2,ob)))},unfocusNodeAdjacency:function(){var t=this._model.getData().graph;t.eachNode(function(t){Oh(t,ob)}),t.eachEdge(function(t){Oh(t,sb)})},_startForceLayoutIteration:function(t,e){var n=this;!function i(){t.step(function(t){n.updateLayout(n._model),(n._layouting=!t)&&(e?n._layoutTimeout=setTimeout(i,16):i())})}()},_updateController:function(t,e,n){var i=this._controller,r=this._controllerHost,a=this.group;return i.setPointerChecker(function(e,i,r){var o=a.getBoundingRect();return o.applyTransform(a.transform),o.contain(i,r)&&!kh(e,n,t)}),"view"!==t.coordinateSystem.type?void i.disable():(i.enable(t.get("roam")),r.zoomLimit=t.get("scaleLimit"),r.zoom=t.coordinateSystem.getZoom(),void i.off("pan").off("zoom").on("pan",function(e,i){Dh(r,e,i),n.dispatchAction({seriesId:t.id,type:"graphRoam",dx:e,dy:i})}).on("zoom",function(e,i,a){Ah(r,e,i,a),n.dispatchAction({seriesId:t.id,type:"graphRoam",zoom:e,originX:i,originY:a}),this._updateNodeAndLinkScale(),ab(t.getGraph(),this._getNodeGlobalScale(t)),this._lineDraw.updateLayout()},this))},_updateNodeAndLinkScale:function(){var t=this._model,e=t.getData(),n=this._getNodeGlobalScale(t),i=[n,n];e.eachItemGraphicEl(function(t){t.attr("scale",i)})},_getNodeGlobalScale:function(t){var e=t.coordinateSystem;if("view"!==e.type)return 1;var n=this._nodeScaleRatio,i=e.scale,r=i&&i[0]||1,a=e.getZoom(),o=(a-1)*n+1;return o/r},updateLayout:function(t){ab(t.getGraph(),this._getNodeGlobalScale(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},remove:function(){this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()}});var lb={type:"graphRoam",event:"graphRoam",update:"none"};Ml(lb,function(t,e){e.eachComponent({mainType:"series",query:t},function(e){var n=e.coordinateSystem,i=Rh(n,t);e.setCenter&&e.setCenter(i.center),e.setZoom&&e.setZoom(i.zoom)})}),Ml({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series.graph:focusNodeAdjacency"},function(){}),Ml({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series.graph:unfocusNodeAdjacency"},function(){});var ub=function(t){var e=t.findComponents({mainType:"legend"});e&&e.length&&t.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),i=t.getGraph(),r=i.data,a=n.mapArray(n.getName);r.filterSelf(function(t){var n=r.getItemModel(t),i=n.getShallow("category");if(null!=i){"number"==typeof i&&(i=a[i]);for(var o=0;o<e.length;o++)if(!e[o].isSelected(i))return!1}return!0})},this)},hb=function(t,e,n){return{seriesType:t,performRawSeries:!0,reset:function(t,i){function r(e,n){if("function"==typeof s){var i=t.getRawValue(n),r=t.getDataParams(n);e.setItemVisual(n,"symbolSize",s(i,r))}if(e.hasItemOption){var a=e.getItemModel(n),o=a.getShallow("symbol",!0),l=a.getShallow("symbolSize",!0);null!=o&&e.setItemVisual(n,"symbol",o),null!=l&&e.setItemVisual(n,"symbolSize",l)}}var a=t.getData(),o=t.get("symbol")||e,s=t.get("symbolSize");if(a.setVisual({legendSymbol:n||o,symbol:o,symbolSize:s}),!i.isSeriesFiltered(t)){var l="function"==typeof s;return{dataEach:a.hasItemOption||l?r:null}}}}},cb=function(t){var e={};t.eachSeriesByType("graph",function(t){var n=t.getCategoriesData(),i=t.getData(),r={};n.each(function(i){var a=n.getName(i);r["ec-"+a]=i;var o=n.getItemModel(i),s=o.get("itemStyle.color")||t.getColorFromPalette(a,e);n.setItemVisual(i,"color",s)}),n.count()&&i.each(function(t){var e=i.getItemModel(t),a=e.getShallow("category");null!=a&&("string"==typeof a&&(a=r["ec-"+a]),i.getItemVisual(t,"color",!0)||i.setItemVisual(t,"color",n.getItemVisual(a,"color")))})})},db=function(t){t.eachSeriesByType("graph",function(t){var e=t.getGraph(),n=t.getEdgeData(),i=zh(t.get("edgeSymbol")),r=zh(t.get("edgeSymbolSize")),a="lineStyle.color".split("."),o="lineStyle.opacity".split(".");n.setVisual("fromSymbol",i&&i[0]),n.setVisual("toSymbol",i&&i[1]),n.setVisual("fromSymbolSize",r&&r[0]),n.setVisual("toSymbolSize",r&&r[1]),n.setVisual("color",t.get(a)),n.setVisual("opacity",t.get(o)),n.each(function(t){var i=n.getItemModel(t),r=e.getEdgeByIndex(t),s=zh(i.getShallow("symbol",!0)),l=zh(i.getShallow("symbolSize",!0)),u=i.get(a),h=i.get(o);switch(u){case"source":u=r.node1.getVisual("color");break;case"target":u=r.node2.getVisual("color")}s[0]&&r.setVisual("fromSymbol",s[0]),s[1]&&r.setVisual("toSymbol",s[1]),l[0]&&r.setVisual("fromSymbolSize",l[0]),l[1]&&r.setVisual("toSymbolSize",l[1]),r.setVisual("color",u),r.setVisual("opacity",h)})})},fb=function(t){t.eachSeriesByType("graph",function(t){var e=t.get("layout"),n=t.coordinateSystem;if(n&&"view"!==n.type){var i=t.getData(),r=[];f(n.dimensions,function(t){r=r.concat(i.mapDimension(t,!0))});for(var a=0;a<i.count();a++){for(var o=[],s=!1,l=0;l<r.length;l++){var u=i.get(r[l],a);isNaN(u)||(s=!0),o.push(u)}s?i.setItemLayout(a,n.dataToPoint(o)):i.setItemLayout(a,[0/0,0/0])}Nh(i.graph)}else e&&"none"!==e||Bh(t)})},pb=function(t){t.eachSeriesByType("graph",function(t){"circular"===t.get("layout")&&Vh(t)})},gb=Z,vb=function(t){t.eachSeriesByType("graph",function(t){var e=t.coordinateSystem;if(!e||"view"===e.type)if("force"===t.get("layout")){var n=t.preservedPoints||{},i=t.getGraph(),r=i.data,a=i.edgeData,o=t.getModel("force"),s=o.get("initLayout");t.preservedPoints?r.each(function(t){var e=r.getId(t);r.setItemLayout(t,n[e]||[0/0,0/0])}):s&&"none"!==s?"circular"===s&&Vh(t):Bh(t);var l=r.getDataExtent("value"),u=a.getDataExtent("value"),h=o.get("repulsion"),c=o.get("edgeLength");x(h)||(h=[h,h]),x(c)||(c=[c,c]),c=[c[1],c[0]];var d=r.mapArray("value",function(t,e){var n=r.getItemLayout(e),i=Na(t,l,h);return isNaN(i)&&(i=(h[0]+h[1])/2),{w:i,rep:i,fixed:r.getItemModel(e).get("fixed"),p:!n||isNaN(n[0])||isNaN(n[1])?null:n}}),f=a.mapArray("value",function(t,e){var n=i.getEdgeByIndex(e),r=Na(t,u,c);return isNaN(r)&&(r=(c[0]+c[1])/2),{n1:d[n.node1.dataIndex],n2:d[n.node2.dataIndex],d:r,curveness:n.getModel().get("lineStyle.curveness")||0}}),e=t.coordinateSystem,p=e.getBoundingRect(),g=Fh(d,f,{rect:p,gravity:o.get("gravity")}),v=g.step;g.step=function(t){for(var e=0,a=d.length;a>e;e++)d[e].fixed&&W(d[e].p,i.getNodeByIndex(e).getLayout());v(function(e,a,o){for(var s=0,l=e.length;l>s;s++)e[s].fixed||i.getNodeByIndex(s).setLayout(e[s].p),n[r.getId(s)]=e[s].p;for(var s=0,l=a.length;l>s;s++){var u=a[s],h=i.getEdgeByIndex(s),c=u.n1.p,d=u.n2.p,f=h.getLayout();f=f?f.slice():[],f[0]=f[0]||[],f[1]=f[1]||[],W(f[0],c),W(f[1],d),+u.curveness&&(f[2]=[(c[0]+d[0])/2-(c[1]-d[1])*u.curveness,(c[1]+d[1])/2-(d[0]-c[0])*u.curveness]),h.setLayout(f)}t&&t(o)})},t.forceLayout=g,t.preservedPoints=n,g.step()}else t.forceLayout=null})},mb=ae;c(Hh,Jp),Wh.prototype={constructor:Wh,type:"view",dimensions:["x","y"],setBoundingRect:function(t,e,n,i){return this._rect=new rn(t,e,n,i),this._rect},getBoundingRect:function(){return this._rect},setViewRect:function(t,e,n,i){this.transformTo(t,e,n,i),this._viewRect=new rn(t,e,n,i)},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=this._rawTransformable;a.transform=r.calculateTransform(new rn(t,e,n,i)),a.decomposeTransform(),this._updateTransform()},setCenter:function(t){t&&(this._center=t,this._updateCenterAndZoom())},setZoom:function(t){t=t||1;var e=this.zoomLimit;e&&(null!=e.max&&(t=Math.min(e.max,t)),null!=e.min&&(t=Math.max(e.min,t))),this._zoom=t,this._updateCenterAndZoom()},getDefaultCenter:function(){var t=this.getBoundingRect(),e=t.x+t.width/2,n=t.y+t.height/2;return[e,n]},getCenter:function(){return this._center||this.getDefaultCenter()},getZoom:function(){return this._zoom||1},getRoamTransform:function(){return this._roamTransformable.getLocalTransform()},_updateCenterAndZoom:function(){var t=this._rawTransformable.getLocalTransform(),e=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),r=this.getZoom();i=ae([],i,t),n=ae([],n,t),e.origin=i,e.position=[n[0]-i[0],n[1]-i[1]],e.scale=[r,r],this._updateTransform()},_updateTransform:function(){var t=this._roamTransformable,e=this._rawTransformable;e.parent=t,t.updateTransform(),e.updateTransform(),ge(this.transform||(this.transform=[]),e.transform||fe()),this._rawTransform=e.getLocalTransform(),this.invTransform=this.invTransform||[],xe(this.invTransform,this.transform),this.decomposeTransform()},getViewRect:function(){return this._viewRect},getViewRectAfterRoam:function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},dataToPoint:function(t,e,n){var i=e?this._rawTransform:this.transform;return n=n||[],i?mb(n,t,i):W(n,t)},pointToData:function(t){var e=this.invTransform;return e?mb([],t,e):[t[0],t[1]]},convertToPixel:_(Gh,"dataToPoint"),convertFromPixel:_(Gh,"pointToData"),containPoint:function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])}},c(Wh,Jp);var yb=function(t,e){var n=[];return t.eachSeriesByType("graph",function(t){var i=t.get("coordinateSystem");if(!i||"view"===i){var r=t.getData(),a=r.mapArray(function(t){var e=r.getItemModel(t);return[+e.get("x"),+e.get("y")]}),o=[],s=[];fr(a,o,s),s[0]-o[0]===0&&(s[0]+=1,o[0]-=1),s[1]-o[1]===0&&(s[1]+=1,o[1]-=1);var l=(s[0]-o[0])/(s[1]-o[1]),u=jh(t,e,l);isNaN(l)&&(o=[u.x,u.y],s=[u.x+u.width,u.y+u.height]);var h=s[0]-o[0],c=s[1]-o[1],d=u.width,f=u.height,p=t.coordinateSystem=new Wh;p.zoomLimit=t.get("scaleLimit"),p.setBoundingRect(o[0],o[1],h,c),p.setViewRect(u.x,u.y,d,f),p.setCenter(t.get("center")),p.setZoom(t.get("zoom")),n.push(p)}}),n};bl(ub),Dl(hb("graph","circle",null)),Dl(cb),Dl(db),Cl(fb),Cl(pb),Cl(vb),Tl("graphView",{create:yb}),Pl({type:"title",layoutMode:{type:"box",ignoreSize:!0},defaultOption:{zlevel:0,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:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}}}),Ll({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),s=t.get("textBaseline"),l=new Nm({style:da({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),u=l.getBoundingRect(),h=t.get("subtext"),c=new Nm({style:da({},a,{text:h,textFill:a.getTextColor(),y:u.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink");l.silent=!d,c.silent=!f,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),i.add(l),h&&i.add(c);var p=i.getBoundingRect(),g=t.getBoxLayoutParams();g.width=p.width,g.height=p.height;var v=uo(g,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));o||(o=t.get("left")||t.get("right"),"middle"===o&&(o="center"),"right"===o?v.x+=v.width:"center"===o&&(v.x+=v.width/2)),s||(s=t.get("top")||t.get("bottom"),"center"===s&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.attr("position",[v.x,v.y]);var m={textAlign:o,textVerticalAlign:s};l.setStyle(m),c.setStyle(m),p=i.getBoundingRect();var y=v.margin,_=t.getItemStyle(["color","opacity"]);_.fill=t.get("backgroundColor");var x=new Ym({shape:{x:p.x-y[3],y:p.y-y[0],width:p.width+y[1]+y[3],height:p.height+y[0]+y[2],r:t.get("borderRadius")},style:_,silent:!0});$r(x),i.add(x)}}});var _b=Pl({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{}},mergeOption:function(t){_b.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),e=!0;break}}!e&&this.select(t[0].get("name"))}},_updateData:function(t){var e=[],n=[];t.eachRawSeries(function(i){var r=i.name;n.push(r);var a;if(i.legendDataProvider){var o=i.legendDataProvider(),s=o.mapArray(o.getName);t.isSeriesFiltered(i)||(n=n.concat(s)),s.length?e=e.concat(s):a=r}else a=r;a&&a!==Iv&&e.push(a)}),this._availableNames=n;var i=this.get("data")||e,r=p(i,function(t){return("string"==typeof t||"number"==typeof t)&&(t={name:t}),new Pa(t,this,this.ecModel)},this);this._data=r},getData:function(){return this._data},select:function(t){var e=this.option.selected,n=this.get("selectedMode");if("single"===n){var i=this._data;f(i,function(t){e[t.get("name")]=!1})}e[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},toggleSelected:function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&u(this._availableNames,t)>=0},defaultOption:{zlevel:0,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,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});Ml("legendToggleSelect","legendselectchanged",_(Uh,"toggleSelected")),Ml("legendSelect","legendselected",_(Uh,"select")),Ml("legendUnSelect","legendunselected",_(Uh,"unSelect"));var xb=_,wb=f,bb=Ig,Sb=Ll({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new bb),this._backgroundEl},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){if(this.resetInner(),t.get("show",!0)){var i=t.get("align");i&&"auto"!==i||(i="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(i,t,e,n);var r=t.getBoxLayoutParams(),a={width:n.getWidth(),height:n.getHeight()},o=t.get("padding"),l=uo(r,a,o),u=this.layoutInner(t,i,l),h=uo(s({width:u.width,height:u.height},r),a,o);this.group.attr("position",[h.x-u.x,h.y-u.y]),this.group.add(this._backgroundEl=Xh(u,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(t,e,n,i){var r=this.getContentGroup(),a=N(),o=e.get("selectedMode");wb(e.getData(),function(s,l){var u=s.get("name");if(!this.newlineDisabled&&(""===u||"\n"===u))return void r.add(new bb({newline:!0}));var h=n.getSeriesByName(u)[0];if(!a.get(u))if(h){var c=h.getData(),d=c.getVisual("color");"function"==typeof d&&(d=d(h.getDataParams(0)));var f=c.getVisual("legendSymbol")||"roundRect",p=c.getVisual("symbol"),g=this._createItem(u,l,s,e,f,p,t,d,o);g.on("click",xb(Yh,u,i)).on("mouseover",xb(qh,h,null,i)).on("mouseout",xb($h,h,null,i)),a.set(u,!0)}else n.eachRawSeries(function(n){if(!a.get(u)&&n.legendDataProvider){var r=n.legendDataProvider(),h=r.indexOfName(u);if(0>h)return;var c=r.getItemVisual(h,"color"),d="roundRect",f=this._createItem(u,l,s,e,d,null,t,c,o);f.on("click",xb(Yh,u,i)).on("mouseover",xb(qh,n,u,i)).on("mouseout",xb($h,n,u,i)),a.set(u,!0)}},this)},this)},_createItem:function(t,e,n,i,r,a,s,l,u){var h=i.get("itemWidth"),c=i.get("itemHeight"),d=i.get("inactiveColor"),f=i.isSelected(t),p=new bb,g=n.getModel("textStyle"),v=n.get("icon"),m=n.getModel("tooltip"),y=m.parentModel;if(r=v||r,p.add(Du(r,0,0,h,c,f?l:d,!0)),!v&&a&&(a!==r||"none"==a)){var _=.8*c;"none"===a&&(a="circle"),p.add(Du(a,(h-_)/2,(c-_)/2,_,_,f?l:d))}var x="left"===s?h+5:-5,w=s,b=i.get("formatter"),S=t;"string"==typeof b&&b?S=b.replace("{name}",null!=t?t:""):"function"==typeof b&&(S=b(t)),p.add(new Nm({style:da({},g,{text:S,x:x,y:c/2,textFill:f?g.getTextColor():d,textAlign:w,textVerticalAlign:"middle"})}));var M=new Ym({shape:p.getBoundingRect(),invisible:!0,tooltip:m.get("show")?o({content:t,formatter:y.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},m.option):null});return p.add(M),p.eachChild(function(t){t.silent=!0}),M.silent=!u,this.getContentGroup().add(p),ha(p),p.__legendDataIndex=e,p},layoutInner:function(t,e,n){var i=this.getContentGroup();Py(t.get("orient"),i,t.get("itemGap"),n.width,n.height);var r=i.getBoundingRect();return i.attr("position",[-r.x,-r.y]),this.group.getBoundingRect()}}),Mb=function(t){var e=t.findComponents({mainType:"legend"});e&&e.length&&t.filterSeries(function(t){for(var n=0;n<e.length;n++)if(!e[n].isSelected(t.name))return!1;return!0})};bl(Mb),Ey.registerSubTypeDefaulter("legend",function(){return"plain"});var Tb=_b.extend({type:"legend.scroll",setScrollDataIndex:function(t){this.option.scrollDataIndex=t},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},init:function(t,e,n,i){var r=fo(t);Tb.superCall(this,"init",t,e,n,i),Kh(this,t,r)},mergeOption:function(t,e){Tb.superCall(this,"mergeOption",t,e),Kh(this,this.option,t)},getOrient:function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}}}),Ib=Ig,Cb=["width","height"],Db=["x","y"],Ab=Sb.extend({type:"legend.scroll",newlineDisabled:!0,init:function(){Ab.superCall(this,"init"),this._currentIndex=0,this.group.add(this._containerGroup=new Ib),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new Ib),this._showController},resetInner:function(){Ab.superCall(this,"resetInner"),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},renderInner:function(t,e,n,i){function r(t,n){var r=t+"DataIndex",l=ka(e.get("pageIcons",!0)[e.getOrient().name][n],{onclick:y(a._pageGo,a,r,e,i)},{x:-s[0]/2,y:-s[1]/2,width:s[0],height:s[1]});l.name=t,o.add(l)}var a=this;Ab.superCall(this,"renderInner",t,e,n,i);var o=this._controllerGroup,s=e.get("pageIconSize",!0);x(s)||(s=[s,s]),r("pagePrev",0);var l=e.getModel("pageTextStyle");o.add(new Nm({name:"pageText",style:{textFill:l.getTextColor(),font:l.getFont(),textVerticalAlign:"middle",textAlign:"center"},silent:!0})),r("pageNext",1)},layoutInner:function(t,e,n){var i=this.getContentGroup(),r=this._containerGroup,a=this._controllerGroup,o=t.getOrient().index,s=Cb[o],l=Cb[1-o],u=Db[1-o];Py(t.get("orient"),i,t.get("itemGap"),o?n.width:null,o?null:n.height),Py("horizontal",a,t.get("pageButtonItemGap",!0));var h=i.getBoundingRect(),c=a.getBoundingRect(),d=this._showController=h[s]>n[s],f=[-h.x,-h.y];f[o]=i.position[o];var p=[0,0],g=[-c.x,-c.y],v=A(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var m=t.get("pageButtonPosition",!0);"end"===m?g[o]+=n[s]-c[s]:p[o]+=c[s]+v}g[1-o]+=h[l]/2-c[l]/2,i.attr("position",f),r.attr("position",p),a.attr("position",g);var y=this.group.getBoundingRect(),y={x:0,y:0};if(y[s]=d?n[s]:h[s],y[l]=Math.max(h[l],c[l]),y[u]=Math.min(0,c[u]+g[1-o]),r.__rectSize=n[s],d){var _={x:0,y:0};_[s]=Math.max(n[s]-c[s]-v,0),_[l]=y[l],r.setClipPath(new Ym({shape:_})),r.__rectSize=_[s]}else a.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(t);return null!=x.pageIndex&&ba(i,{position:x.contentPosition},d?t:!1),this._updatePageInfoView(t,x),y},_pageGo:function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},_updatePageInfoView:function(t,e){var n=this._controllerGroup;f(["pagePrev","pageNext"],function(i){var r=null!=e[i+"DataIndex"],a=n.childOfName(i);a&&(a.setStyle("fill",r?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),a.cursor=r?"pointer":"default")});var i=n.childOfName("pageText"),r=t.get("pageFormatter"),a=e.pageIndex,o=null!=a?a+1:0,s=e.pageCount;i&&r&&i.setStyle("text",b(r)?r.replace("{current}",o).replace("{total}",s):r({current:o,total:s}))},_getPageInfo:function(t){function e(t){var e=t.getBoundingRect().clone();return e[f]+=t.position[h],e}var n,i,r,a,o=t.get("scrollDataIndex",!0),s=this.getContentGroup(),l=s.getBoundingRect(),u=this._containerGroup.__rectSize,h=t.getOrient().index,c=Cb[h],d=Cb[1-h],f=Db[h],p=s.position.slice();this._showController?s.eachChild(function(t){t.__legendDataIndex===o&&(a=t)}):a=s.childAt(0);var g=u?Math.ceil(l[c]/u):0;if(a){var v=a.getBoundingRect(),m=a.position[h]+v[f];p[h]=-m-l[f],n=Math.floor(g*(m+v[f]+u/2)/l[c]),n=l[c]&&g?Math.max(0,Math.min(g-1,n)):-1;var y={x:0,y:0};y[c]=u,y[d]=l[d],y[f]=-p[h]-l[f];var _,x=s.children();if(s.eachChild(function(t,n){var i=e(t);i.intersect(y)&&(null==_&&(_=n),r=t.__legendDataIndex),n===x.length-1&&i[f]+i[c]<=y[f]+y[c]&&(r=null)}),null!=_){var w=x[_],b=e(w);if(y[f]=b[f]+b[c]-y[c],0>=_&&b[f]>=y[f])i=null;else{for(;_>0&&e(x[_-1]).intersect(y);)_--;i=x[_].__legendDataIndex}}}return{contentPosition:p,pageIndex:n,pageCount:g,pagePrevDataIndex:i,pageNextDataIndex:r}}});Ml("legendScroll","legendscroll",function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(t){t.setScrollDataIndex(n)})});var kb=f,Pb=_,Lb=function(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var a=n.getData(),o=Fi(a,t);if(null==o||0>o||x(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(a.getValues(p(l.dimensions,function(t){return a.mapDimension(t)}),o,!0))||[];else if(s){var u=s.getBoundingRect().clone();u.applyTransform(s.transform),i=[u.x+u.width/2,u.y+u.height/2]}return{point:i,el:s}},Ob=f,Eb=_,Rb=Hi(),zb=function(t,e,n){var i=t.currTrigger,r=[t.x,t.y],a=t,o=t.dispatchAction||y(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){yc(r)&&(r=Lb({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=yc(r),u=a.axesInfo,h=s.axesInfo,c="leave"===i||yc(r),d={},f={},p={list:[],map:{}},g={showPointer:Eb(cc,f),showTooltip:Eb(dc,p)};Ob(s.coordSysMap,function(t,e){var n=l||t.containPoint(r);Ob(s.coordSysAxesInfo[e],function(t){var e=t.axis,i=vc(u,t);if(!c&&n&&(!u||i)){var a=i&&i.value;null!=a||l||(a=e.pointToData(r)),null!=a&&uc(t,a,g,!1,d)}})});var v={};return Ob(h,function(t,e){var n=t.linkGroup;n&&!f[e]&&Ob(n.axesInfo,function(e,i){var r=f[i];if(e!==t&&r){var a=r.value;n.mapper&&(a=t.axis.scale.parse(n.mapper(a,mc(e),mc(t)))),v[t.key]=a}})}),Ob(v,function(t,e){uc(h[e],t,g,!0,d)}),fc(f,h,d),pc(p,r,t,o),gc(h,o,n),d}},Bb=(Pl({type:"axisPointer",coordSysAxesInfo:null,defaultOption:{show:"auto",triggerOn:null,zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#aaa",width:1,type:"solid"},shadowStyle:{color:"rgba(150,150,150,0.3)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,shadowBlur:3,shadowColor:"#aaa"},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}}}),Hi()),Nb=f,Vb=Ll({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";_c("axisPointer",n,function(t,e,n){"none"!==r&&("leave"===t||r.indexOf(t)>=0)&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){Tc(e.getZr(),"axisPointer"),Vb.superApply(this._model,"remove",arguments)},dispose:function(t,e){Tc("axisPointer",e),Vb.superApply(this._model,"dispose",arguments)}}),Fb=Hi(),Hb=i,Wb=y;Ic.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,n,i){var r=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==a){this._lastValue=r,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(s&&s.hide());o&&o.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var u=l.graphicKey;u!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=u;var h=this._moveAnimation=this.determineAnimation(t,e);if(o){var c=_(Cc,e,h);this.updatePointerEl(o,l,c,e),this.updateLabelEl(o,l,c,e)}else o=this._group=new Ig,this.createPointerEl(o,l,t,e),this.createLabelEl(o,l,t,e),n.getZr().add(o);Pc(o,e,!0),this._renderHandle(r)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,a=e.get("snap");if(!a&&!r)return!1;if("auto"===n||null==n){var o=this.animationThreshold;if(r&&i.getBandWidth()>o)return!0;if(a){var s=ac(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>o}return!1}return n===!0},makeElOption:function(){},createPointerEl:function(t,e){var n=e.pointer;if(n){var i=Fb(t).pointerEl=new uy[n.type](Hb(e.pointer));t.add(i)}},createLabelEl:function(t,e,n,i){if(e.label){var r=Fb(t).labelEl=new Ym(Hb(e.label));t.add(r),Ac(r,i)}},updatePointerEl:function(t,e,n){var i=Fb(t).pointerEl;i&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=Fb(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),Ac(r,i))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e=this._axisPointerModel,n=this._api.getZr(),i=this._handle,r=e.getModel("handle"),a=e.get("status");if(!r.get("show")||!a||"hide"===a)return i&&n.remove(i),void(this._handle=null);var o;this._handle||(o=!0,i=this._handle=ka(r.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){ov(t.event)},onmousedown:Wb(this._onHandleDragMove,this,0,0),drift:Wb(this._onHandleDragMove,this),ondragend:Wb(this._onHandleDragEnd,this)}),n.add(i)),Pc(i,e,!1);var s=["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];i.setStyle(r.getItemStyle(null,s));var l=r.get("size");x(l)||(l=[l,l]),i.attr("scale",[l[0]/2,l[1]/2]),As(this,"_doDispatchAxisPointer",r.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,o)}},_moveHandleToValue:function(t,e){Cc(this._axisPointerModel,!e&&this._moveAnimation,this._handle,kc(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(kc(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(kc(i)),Fb(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){var t=this._handle;if(t){var e=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},_onHandleDragEnd:function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}},Ic.prototype.constructor=Ic,Yi(Ic);var Gb=Math.PI,jb=function(t,e){this.opt=e,this.axisModel=t,s(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new Ig;var n=new Ig({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n};jb.prototype={constructor:jb,hasBuilder:function(t){return!!Ub[t]},add:function(t){Ub[t].call(this)},getGroup:function(){return this.group}};var Ub={axisLine:function(){var t=this.opt,e=this.axisModel;if(e.get("axisLine.show")){var n=this.axisModel.axis.getExtent(),i=this._transform,r=[n[0],0],a=[n[1],0];i&&(ae(r,r,i),ae(a,a,i));var s=o({lineCap:"round"},e.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new qm(qr({anid:"line",shape:{x1:r[0],y1:r[1],x2:a[0],y2:a[1]},style:s,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1})));var l=e.get("axisLine.symbol"),u=e.get("axisLine.symbolSize");if(null!=l){"string"==typeof l&&(l=[l,l]),("string"==typeof u||"number"==typeof u)&&(u=[u,u]);var h=u[0],c=u[1];f([[t.rotation+Math.PI/2,r],[t.rotation-Math.PI/2,a]],function(t,e){if("none"!==l[e]&&null!=l[e]){var n=Du(l[e],-h/2,-c/2,h,c,s.stroke,!0);n.attr({rotation:t[0],position:t[1],silent:!0}),this.group.add(n)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=Vc(this,t,e),i=Fc(this,t,e);Rc(t,i,n)},axisName:function(){var t=this.opt,e=this.axisModel,n=D(t.axisName,e.get("name"));if(n){var i,r=e.get("nameLocation"),a=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,u=this.axisModel.axis.getExtent(),h=u[0]>u[1]?-1:1,c=["start"===r?u[0]-h*l:"end"===r?u[1]+h*l:(u[0]+u[1])/2,Nc(r)?t.labelOffset+a*l:0],d=e.get("nameRotate");null!=d&&(d=d*Gb/180);var f;Nc(r)?i=Zb(t.rotation,null!=d?d:t.rotation,a):(i=Oc(t,r,d||0,u),f=t.axisNameAvailableWidth,null!=f&&(f=Math.abs(f/Math.sin(i.rotation)),!isFinite(f)&&(f=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},v=g.ellipsis,m=D(t.nameTruncateMaxWidth,g.maxWidth,f),y=null!=v&&null!=m?Ty(n,m,p,v,{minChar:2,placeholder:g.placeholder}):n,_=e.get("tooltip",!0),x=e.mainType,w={componentType:x,name:n,$vars:["name"]};w[x+"Index"]=e.componentIndex;var b=new Nm({anid:"name",__fullText:n,__truncatedText:y,position:c,rotation:i.rotation,silent:Ec(e),z2:1,tooltip:_&&_.show?o({content:n,formatter:function(){return n},formatterParams:w},_):null});da(b.style,s,{text:y,textFont:p,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:i.textAlign,textVerticalAlign:i.textVerticalAlign}),e.get("triggerEvent")&&(b.eventData=Lc(e),b.eventData.targetType="axisName",b.eventData.name=n),this._dumbGroup.add(b),b.updateTransform(),this.group.add(b),b.decomposeTransform()}}},Zb=jb.innerTextLayout=function(t,e,n){var i,r,a=Za(e-t);return Xa(a)?(r=n>0?"top":"bottom",i="center"):Xa(a-Gb)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=a>0&&Gb>a?n>0?"right":"left":n>0?"left":"right"),{rotation:a,textAlign:i,textVerticalAlign:r}},Xb=jb.ifIgnoreOnTick=function(t,e,n,i,r,a){if(0===e&&r||e===i-1&&a)return!1;var o,s=t.scale;return"ordinal"===s.type&&("function"==typeof n?(o=s.getTicks()[e],!n(o,s.getLabel(o))):e%%(n+1))},Yb=jb.getInterval=function(t,e){var n=t.get("interval");return(null==n||"auto"==n)&&(n=e),n},qb=Ll({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&rc(t),qb.superApply(this,"render",arguments),$c(this,t,e,n,i,!0)},updateAxisPointer:function(t,e,n,i){$c(this,t,e,n,i,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),qb.superApply(this,"remove",arguments)},dispose:function(t,e){Kc(this,e),qb.superApply(this,"dispose",arguments)}}),$b=[];qb.registerAxisPointerClass=function(t,e){$b[t]=e},qb.getAxisPointerClass=function(t){return t&&$b[t]};var Kb=Ic.extend({makeElOption:function(t,e,n,i,r){var a=n.axis,o=a.grid,s=i.get("type"),l=Qc(o,a).getOtherAxis(a).getGlobalExtent(),u=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var h=Hc(i),c=Qb[s](a,u,l,h);c.style=h,t.graphicKey=c.type,t.pointer=c}var d=qc(o.model,n);Zc(e,t,d,n,i,r)},getHandleTransform:function(t,e,n){var i=qc(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:Uc(e.axis,t,i),rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,n){var i=n.axis,r=i.grid,a=i.getGlobalExtent(!0),o=Qc(r,i).getOtherAxis(i).getGlobalExtent(),s="x"===i.dim?0:1,l=t.position;l[s]+=e[s],l[s]=Math.min(a[1],l[s]),l[s]=Math.max(a[0],l[s]);var u=(o[1]+o[0])/2,h=[u,u];h[s]=l[s];var c=[{verticalAlign:"middle"},{align:"center"}];return{position:l,rotation:t.rotation,cursorPoint:h,tooltipOption:c[s]}}}),Qb={line:function(t,e,n,i){var r=Xc([e,n[0]],[e,n[1]],Jc(t));return qr({shape:r,style:i}),{type:"Line",shape:r}},shadow:function(t,e,n){var i=t.getBandWidth(),r=n[1]-n[0];return{type:"Rect",shape:Yc([e-i/2,n[0]],[i,r],Jc(t))}}};qb.registerAxisPointerClass("CartesianAxisPointer",Kb),wl(function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!x(e)&&(t.axisPointer.link=[e])}}),bl(ox.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=Qh(t,e)}),Ml({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},zb),Pl({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:8,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",confine:!1,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#fff",fontSize:14}}});var Jb=f,tS=eo,eS=["","-webkit-","-moz-","-o-"],nS="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;";id.prototype={constructor:id,_enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),n=t.style;"absolute"!==n.position&&"absolute"!==e.position&&(n.position="relative")},show:function(t){clearTimeout(this._hideTimeout);var e=this.el;e.style.cssText=nS+nd(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",this._show=!0},setContent:function(t){this.el.innerHTML=null==t?"":t},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el;return[t.clientWidth,t.clientHeight]},moveTo:function(t,e){var n,i=this._zr;i&&i.painter&&(n=i.painter.getViewportRootOffset())&&(t+=n.offsetLeft,e+=n.offsetTop);var r=this.el.style;r.left=t+"px",r.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(y(this.hide,this),t)):this.hide())},isShow:function(){return this._show}};var iS=y,rS=f,aS=Va,oS=new Ym({shape:{x:-1,y:-1,width:2,height:2}});Ll({type:"tooltip",init:function(t,e){if(!Sp.node){var n=new id(e.getDom(),e);this._tooltipContent=n}},render:function(t,e,n){if(!Sp.node&&!Sp.wxa){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var t=this._tooltipModel,e=t.get("triggerOn");_c("itemTooltip",this._api,iS(function(t,n,i){"none"!==e&&(e.indexOf(t)>=0?this._tryShow(n,i):"leave"===t&&this._hide(i))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,n=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!Sp.node){var r=ad(i,n);this._ticket="";var a=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var o=oS;o.position=[i.x,i.y],o.update(),o.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:o},r)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,event:{},dataByCoordSys:i.dataByCoordSys,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var s=Lb(i,e),l=s.point[0],u=s.point[1];null!=l&&null!=u&&this._tryShow({offsetX:l,offsetY:u,position:i.position,target:s.el,event:{}},r)}else null!=i.x&&null!=i.y&&(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,event:{}},r))}},manuallyHideTip:function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,i.from!==this.uid&&this._hide(ad(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,a=i.dataIndex,o=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=a&&null!=o){var s=e.getSeriesByIndex(r);if(s){var l=s.getData(),t=rd([l.getItemModel(a),s,(s.coordinateSystem||{}).model,t]);if("axis"===t.get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:a,position:i.position}),!0}}},_tryShow:function(t,e){var n=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var r=t.dataByCoordSys;r&&r.length?this._showAxisTooltip(r,t):n&&null!=n.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,n,e)):n&&n.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,n,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var n=t.get("showDelay");e=y(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var n=this._ecModel,i=this._tooltipModel,r=[e.offsetX,e.offsetY],a=[],o=[],s=rd([e.tooltipOption,i]);rS(t,function(t){rS(t.dataByAxis,function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),i=t.value,r=[];if(e&&null!=i){var s=jc(i,e.axis,n,t.seriesDataIndices,t.valueLabelOpt);f(t.seriesDataIndices,function(a){var l=n.getSeriesByIndex(a.seriesIndex),u=a.dataIndexInside,h=l&&l.getDataParams(u);h.axisDim=t.axisDim,h.axisIndex=t.axisIndex,h.axisType=t.axisType,h.axisId=t.axisId,h.axisValue=Iu(e.axis,i),h.axisValueLabel=s,h&&(o.push(h),r.push(l.formatTooltip(u,!0)))});var l=s;a.push((l?no(l)+"<br />":"")+r.join("<br />"))}})},this),a.reverse(),a=a.join("<br /><br />");var l=e.position;this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(s,l,r[0],r[1],this._tooltipContent,o):this._showTooltipContent(s,a,o,Math.random(),r[0],r[1],l)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,a=i.getSeriesByIndex(r),o=e.dataModel||a,s=e.dataIndex,l=e.dataType,u=o.getData(),h=rd([u.getItemModel(s),o,a&&(a.coordinateSystem||{}).model,this._tooltipModel]),c=h.get("trigger");if(null==c||"item"===c){var d=o.getDataParams(s,l),f=o.formatTooltip(s,!1,l),p="item_"+o.name+"_"+s;this._showOrMove(h,function(){this._showTooltipContent(h,f,d,p,t.offsetX,t.offsetY,t.position,t.target)}),n({type:"showTip",dataIndexInside:s,dataIndex:u.getRawIndex(s),seriesIndex:r,from:this.uid})}},_showComponentItemTooltip:function(t,e,n){var i=e.tooltip;if("string"==typeof i){var r=i;i={content:r,formatter:r}}var a=new Pa(i,this._tooltipModel,this._ecModel),o=a.get("content"),s=Math.random();this._showOrMove(a,function(){this._showTooltipContent(a,o,a.get("formatterParams")||{},s,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(t,e,n,i,r,a,o,s){if(this._ticket="",t.get("showContent")&&t.get("show")){var l=this._tooltipContent,u=t.get("formatter");o=o||t.get("position");var h=e;if(u&&"string"==typeof u)h=io(u,n,!0);else if("function"==typeof u){var c=iS(function(e,i){e===this._ticket&&(l.setContent(i),this._updatePosition(t,o,r,a,l,n,s))},this);this._ticket=i,h=u(n,i,c)}l.setContent(h),l.show(t),this._updatePosition(t,o,r,a,l,n,s)}},_updatePosition:function(t,e,n,i,r,a,o){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var u=r.getSize(),h=t.get("align"),c=t.get("verticalAlign"),d=o&&o.getBoundingRect().clone();if(o&&d.applyTransform(o.transform),"function"==typeof e&&(e=e([n,i],a,r.el,d,{viewSize:[s,l],contentSize:u.slice()})),x(e))n=aS(e[0],s),i=aS(e[1],l);else if(S(e)){e.width=u[0],e.height=u[1];var f=uo(e,{width:s,height:l});n=f.x,i=f.y,h=null,c=null}else if("string"==typeof e&&o){var p=ud(e,d,u);n=p[0],i=p[1]}else{var p=od(n,i,r.el,s,l,h?null:20,c?null:20);n=p[0],i=p[1]}if(h&&(n-=hd(h)?u[0]/2:"right"===h?u[0]:0),c&&(i-=hd(c)?u[1]/2:"bottom"===c?u[1]:0),t.get("confine")){var p=sd(n,i,r.el,s,l);n=p[0],i=p[1]}r.moveTo(n,i)},_updateContentNotChangedOnAxis:function(t){var e=this._lastDataByCoordSys,n=!!e&&e.length===t.length;return n&&rS(e,function(e,i){var r=e.dataByAxis||{},a=t[i]||{},o=a.dataByAxis||[];n&=r.length===o.length,n&&rS(r,function(t,e){var i=o[e]||{},r=t.seriesDataIndices||[],a=i.seriesDataIndices||[];n&=t.value===i.value&&t.axisType===i.axisType&&t.axisId===i.axisId&&r.length===a.length,n&&rS(r,function(t,e){var i=a[e];n&=t.seriesIndex===i.seriesIndex&&t.dataIndex===i.dataIndex})})}),this._lastDataByCoordSys=t,!!n},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){Sp.node||(this._tooltipContent.hide(),Tc("itemTooltip",e))}}),Ml({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),Ml({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){});var sS={},lS=Pl({type:"toolbox",layoutMode:{type:"box",ignoreSize:!0},mergeDefaultAndTheme:function(){lS.superApply(this,"mergeDefaultAndTheme",arguments),f(this.option.feature,function(t,e){var n=dd(e);n&&r(t,n.defaultOption)})},defaultOption:{show:!0,z:6,zlevel:0,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"}}}});Ll({type:"toolbox",render:function(t,e,n,i){function r(r,o){var s,c=h[r],d=h[o],f=l[c],p=new Pa(f,t,t.ecModel);if(c&&!d){if(fd(c))s={model:p,onclick:p.option.onclick,featureName:c};else{var g=dd(c);if(!g)return;s=new g(p,e,n)}u[c]=s}else{if(s=u[d],!s)return;s.model=p,s.ecModel=e,s.api=n}return!c&&d?void(s.dispose&&s.dispose(e,n)):!p.get("show")||s.unusable?void(s.remove&&s.remove(e,n)):(a(p,s,c),p.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&i[t].trigger(e)},void(s.render&&s.render(p,e,n,i)))}function a(i,r,a){var l=i.getModel("iconStyle"),u=i.getModel("emphasis.iconStyle"),h=r.getIcons?r.getIcons():i.get("icon"),c=i.get("title")||{};if("string"==typeof h){var d=h,p=c;h={},c={},h[a]=d,c[a]=p}var g=i.iconPaths={};f(h,function(a,h){var d=ka(a,{},{x:-s/2,y:-s/2,width:s,height:s});d.setStyle(l.getItemStyle()),d.hoverStyle=u.getItemStyle(),ha(d),t.get("showTitle")&&(d.__title=c[h],d.on("mouseover",function(){var t=u.getItemStyle();d.setStyle({text:c[h],textPosition:t.textPosition||"bottom",textFill:t.fill||t.stroke||"#000",textAlign:t.textAlign||"center"})}).on("mouseout",function(){d.setStyle({textFill:null})})),d.trigger(i.get("iconStatus."+h)||"normal"),o.add(d),d.on("click",y(r.onclick,r,e,n,h)),g[h]=d})}var o=this.group;if(o.removeAll(),t.get("show")){var s=+t.get("itemSize"),l=t.get("feature")||{},u=this._features||(this._features={}),h=[];f(l,function(t,e){h.push(e)}),new Vl(this._featureNames||[],h).add(r).update(r).remove(_(r,null)).execute(),this._featureNames=h,Zh(o,t,n),o.add(Xh(o.getBoundingRect(),t)),o.eachChild(function(t){var e=t.__title,i=t.hoverStyle;if(i&&e){var r=Mn(e,Vn(i)),a=t.position[0]+o.position[0],l=t.position[1]+o.position[1]+s,u=!1;l+r.height>n.getHeight()&&(i.textPosition="top",u=!0);var h=u?-5-r.height:s+8;a+r.width/2>n.getWidth()?(i.textPosition=["100%%",h],i.textAlign="right"):a-r.width/2<0&&(i.textPosition=[0,h],i.textAlign="left")}})}},updateView:function(t,e,n,i){f(this._features,function(t){t.updateView&&t.updateView(t.model,e,n,i)})},remove:function(t,e){f(this._features,function(n){n.remove&&n.remove(t,e)}),this.group.removeAll()},dispose:function(t,e){f(this._features,function(n){n.dispose&&n.dispose(t,e)})}});var uS=k_.toolbox.saveAsImage;pd.defaultOption={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:uS.title,type:"png",name:"",excludeComponents:["toolbox"],pixelRatio:1,lang:uS.lang.slice()},pd.prototype.unusable=!Sp.canvasSupported;var hS=pd.prototype;hS.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",r=document.createElement("a"),a=n.get("type",!0)||"png";r.download=i+"."+a,r.target="_blank";var o=e.getConnectedDataURL({type:a,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")});if(r.href=o,"function"!=typeof MouseEvent||Sp.browser.ie||Sp.browser.edge)if(window.navigator.msSaveOrOpenBlob){for(var s=atob(o.split(",")[1]),l=s.length,u=new Uint8Array(l);l--;)u[l]=s.charCodeAt(l);var h=new Blob([u]);window.navigator.msSaveOrOpenBlob(h,i+"."+a)}else{var c=n.get("lang"),d='<body style="margin:0;"><img src="'+o+'" style="max-width:100%%;" title="'+(c&&c[0]||"")+'" /></body>',f=window.open();f.document.write(d)}else{var p=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});r.dispatchEvent(p)}},cd("saveAsImage",pd);var cS=k_.toolbox.magicType;gd.defaultOption={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",tiled:"M2.3,2.2h22.8V25H2.3V2.2z M35,2.2h22.8V25H35V2.2zM2.3,35h22.8v22.8H2.3V35z M35,35h22.8v22.8H35V35z"},title:i(cS.title),option:{},seriesIndex:{}};var dS=gd.prototype;dS.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return f(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n};var fS={line:function(t,e,n,i){return"bar"===t?r({id:e,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get("option.line")||{},!0):void 0},bar:function(t,e,n,i){return"line"===t?r({id:e,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get("option.bar")||{},!0):void 0},stack:function(t,e,n,i){return"line"===t||"bar"===t?r({id:e,stack:"__ec_magicType_stack__"},i.get("option.stack")||{},!0):void 0},tiled:function(t,e,n,i){return"line"===t||"bar"===t?r({id:e,stack:""},i.get("option.tiled")||{},!0):void 0}},pS=[["line","bar"],["stack","tiled"]];dS.onclick=function(t,e,n){var i=this.model,r=i.get("seriesIndex."+n);if(fS[n]){var a={series:[]},o=function(e){var r=e.subType,o=e.id,l=fS[n](r,o,e,i);l&&(s(l,e.option),a.series.push(l));var u=e.coordinateSystem;if(u&&"cartesian2d"===u.type&&("line"===n||"bar"===n)){var h=u.getAxesByScale("ordinal")[0];if(h){var c=h.dim,d=c+"Axis",f=t.queryComponents({mainType:d,index:e.get(name+"Index"),id:e.get(name+"Id")})[0],p=f.componentIndex;a[d]=a[d]||[];for(var g=0;p>=g;g++)a[d][p]=a[d][p]||{};a[d][p].boundaryGap="bar"===n?!0:!1}}};f(pS,function(t){u(t,n)>=0&&f(t,function(t){i.setIconStatus(t,"normal")})}),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:null==r?null:{seriesIndex:r}},o),e.dispatchAction({type:"changeMagicType",currentType:n,newOption:a})}},Ml({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),cd("magicType",gd);var gS=k_.toolbox.dataView,vS=new Array(60).join("-"),mS=" ",yS=new RegExp("["+mS+"]+","g");Td.defaultOption={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:i(gS.title),lang:i(gS.lang),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"},Td.prototype.onclick=function(t,e){function n(){i.removeChild(a),_._dom=null}var i=e.getDom(),r=this.model;this._dom&&i.removeChild(this._dom);var a=document.createElement("div");a.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",a.style.backgroundColor=r.get("backgroundColor")||"#fff";var o=document.createElement("h4"),s=r.get("lang")||[];o.innerHTML=s[0]||r.get("title"),o.style.cssText="margin: 10px 20px;",o.style.color=r.get("textColor");var l=document.createElement("div"),u=document.createElement("textarea");l.style.cssText="display:block;width:100%%;overflow:auto;";var h=r.get("optionToContent"),c=r.get("contentToOption"),d=_d(t);if("function"==typeof h){var f=h(e.getOption());"string"==typeof f?l.innerHTML=f:I(f)&&l.appendChild(f)}else l.appendChild(u),u.readOnly=r.get("readOnly"),u.style.cssText="width:100%%;height:100%%;font-family:monospace;font-size:14px;line-height:1.6rem;",u.style.color=r.get("textColor"),u.style.borderColor=r.get("textareaBorderColor"),u.style.backgroundColor=r.get("textareaColor"),u.value=d.value;var p=d.meta,g=document.createElement("div");g.style.cssText="position:absolute;bottom:0;left:0;right:0;";var v="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",m=document.createElement("div"),y=document.createElement("div");v+=";background-color:"+r.get("buttonColor"),v+=";color:"+r.get("buttonTextColor");var _=this;mi(m,"click",n),mi(y,"click",function(){var t;try{t="function"==typeof c?c(l,e.getOption()):Md(u.value,p)}catch(i){throw n(),new Error("Data view format error "+i)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),n()}),m.innerHTML=s[1],y.innerHTML=s[2],y.style.cssText=v,m.style.cssText=v,!r.get("readOnly")&&g.appendChild(y),g.appendChild(m),mi(u,"keydown",function(t){if(9===(t.keyCode||t.which)){var e=this.value,n=this.selectionStart,i=this.selectionEnd;this.value=e.substring(0,n)+mS+e.substring(i),this.selectionStart=this.selectionEnd=n+1,ov(t)}}),a.appendChild(o),a.appendChild(l),a.appendChild(g),l.style.height=i.clientHeight-80+"px",i.appendChild(a),this._dom=a},Td.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},Td.prototype.dispose=function(t,e){this.remove(t,e)},cd("dataView",Td),Ml({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,e){var n=[];f(t.newOption.series,function(t){var i=e.getSeriesByName(t.name)[0];if(i){var r=i.get("data");n.push({name:t.name,data:Id(t.data,r)})}else n.push(o({type:"scatter"},t))}),e.mergeOption(s({series:n},t.newOption))});var _S=_,xS=f,wS=p,bS=Math.min,SS=Math.max,MS=Math.pow,TS=1e4,IS=6,CS=6,DS="globalPan",AS={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},kS={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},PS={brushStyle:{lineWidth:2,stroke:"rgba(0,0,0,0.3)",fill:"rgba(0,0,0,0.1)"},transformable:!0,brushMode:"single",removeOnClick:!1},LS=0;Cd.prototype={constructor:Cd,enableBrush:function(t){return this._brushType&&Ad(this),t.brushType&&Dd(this,t),this},setPanels:function(t){if(t&&t.length){var e=this._panels={};f(t,function(t){e[t.panelId]=i(t)})}else this._panels=null;return this},mount:function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var e=this.group;return this._zr.add(e),e.attr({position:t.position||[0,0],rotation:t.rotation||0,scale:t.scale||[1,1]}),this._transform=e.getLocalTransform(),this},eachCover:function(t,e){xS(this._covers,t,e)},updateCovers:function(t){function e(t,e){return(null!=t.id?t.id:s+e)+"-"+t.brushType}function n(t,n){return e(t.__brushOption,n)}function a(e,n){var i=t[e];if(null!=n&&l[n]===c)u[e]=l[n];else{var r=u[e]=null!=n?(l[n].__brushOption=i,l[n]):Pd(h,kd(h,i));Ed(h,r)}}function o(t){l[t]!==c&&h.group.remove(l[t])}t=p(t,function(t){return r(i(PS),t,!0)});var s="\x00-brush-index-",l=this._covers,u=this._covers=[],h=this,c=this._creatingCover;return new Vl(l,t,n,e).add(a).update(a).remove(o).execute(),this},unmount:function(){return this.enableBrush(!1),Nd(this),this._zr.remove(this.group),this},dispose:function(){this.unmount(),this.off()}},c(Cd,Up);var OS={mousedown:function(t){if(this._dragging)sf.call(this,t);else if(!t.target||!t.target.draggable){nf(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);this._creatingCover=null;var n=this._creatingPanel=zd(this,t,e);n&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(t){var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);if(ef(this,t,e),this._dragging){nf(t);var n=af(this,t,e,!1);n&&Vd(this,n)}},mouseup:sf},ES={lineX:lf(0),lineY:lf(1),rect:{createCover:function(t,e){return Wd(_S($d,function(t){return t},function(t){return t}),t,e,["w","e","n","s","se","sw","ne","nw"])},getCreatingRange:function(t){var e=Hd(t);return Xd(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(t,e,n,i){Gd(t,e,n,i)},updateCommon:jd,contain:rf},polygon:{createCover:function(t,e){var n=new Ig;return n.add(new Xm({name:"main",style:Zd(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new Zm({name:"main",draggable:!0,drift:_S(Kd,t,e),ondragend:_S(Vd,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n){e.childAt(0).setShape({points:Jd(t,e,n)})},updateCommon:jd,contain:rf}},RS=f,zS=u,BS=_,NS=["dataToPoint","pointToData"],VS=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],FS=ff.prototype;FS.setOutputRanges=function(t,e){this.matchOutputRanges(t,e,function(t,e,n){if((t.coordRanges||(t.coordRanges=[])).push(e),!t.coordRange){t.coordRange=e;var i=jS[t.brushType](0,n,e);t.__rangeOffset={offset:US[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})},FS.matchOutputRanges=function(t,e,n){RS(t,function(t){var i=this.findTargetInfo(t,e);i&&i!==!0&&f(i.coordSyses,function(i){var r=jS[t.brushType](1,i,t.range);n(t,r.values,i,e)})},this)},FS.setInputRanges=function(t,e){RS(t,function(t){var n=this.findTargetInfo(t,e);if(t.range=t.range||[],n&&n!==!0){t.panelId=n.panelId;var i=jS[t.brushType](0,n.coordSys,t.coordRange),r=t.__rangeOffset;t.range=r?US[t.brushType](i.values,r.offset,yf(i.xyMinMax,r.xyMinMax)):i.values}},this)},FS.makePanelOpts=function(t,e){return p(this._targetInfoList,function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:e&&e(n),clipPath:uf(i),isTargetByCursor:cf(i,t,n.coordSysModel),getLinearBrushOtherExtent:hf(i)}})},FS.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return i===!0||i&&zS(i.coordSyses,e.coordinateSystem)>=0},FS.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=gf(e,t),r=0;r<n.length;r++){var a=n[r],o=t.panelId;if(o){if(a.panelId===o)return a}else for(var r=0;r<WS.length;r++)if(WS[r](i,a))return a}return!0};var HS={grid:function(t,e){var n=t.xAxisModels,i=t.yAxisModels,r=t.gridModels,a=N(),o={},s={};(n||i||r)&&(RS(n,function(t){var e=t.axis.grid.model;a.set(e.id,e),o[e.id]=!0}),RS(i,function(t){var e=t.axis.grid.model;a.set(e.id,e),s[e.id]=!0}),RS(r,function(t){a.set(t.id,t),o[t.id]=!0,s[t.id]=!0}),a.each(function(t){var r=t.coordinateSystem,a=[];RS(r.getCartesians(),function(t){(zS(n,t.getAxis("x").model)>=0||zS(i,t.getAxis("y").model)>=0)&&a.push(t)}),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:a[0],coordSyses:a,getPanelRect:GS.grid,xAxisDeclared:o[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,e){RS(t.geoModels,function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:GS.geo})})}},WS=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,r=t.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(t,e){var n=t.geoModel;return n&&n===e.geoModel}],GS={grid:function(){return this.coordSys.grid.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Ma(t)),e}},jS={lineX:BS(vf,0),lineY:BS(vf,1),rect:function(t,e,n){var i=e[NS[t]]([n[0][0],n[1][0]]),r=e[NS[t]]([n[0][1],n[1][1]]),a=[pf([i[0],r[0]]),pf([i[1],r[1]])];return{values:a,xyMinMax:a}},polygon:function(t,e,n){var i=[[1/0,-1/0],[1/0,-1/0]],r=p(n,function(n){var r=e[NS[t]](n);return i[0][0]=Math.min(i[0][0],r[0]),i[1][0]=Math.min(i[1][0],r[1]),i[0][1]=Math.max(i[0][1],r[0]),i[1][1]=Math.max(i[1][1],r[1]),r});return{values:r,xyMinMax:i}}},US={lineX:BS(mf,0),lineY:BS(mf,1),rect:function(t,e,n){return[[t[0][0]-n[0]*e[0][0],t[0][1]-n[0]*e[0][1]],[t[1][0]-n[1]*e[1][0],t[1][1]-n[1]*e[1][1]]]},polygon:function(t,e,n){return p(t,function(t,i){return[t[0]-n[0]*e[i][0],t[1]-n[1]*e[i][1]]})}},ZS=f,XS="\x00_ec_hist_store",YS=function(t,e,n,i,r,a){e[0]=If(e[0],n),e[1]=If(e[1],n),t=t||0;var o=n[1]-n[0];null!=r&&(r=If(r,[0,o])),null!=a&&(a=Math.max(a,null!=r?r:0)),"all"===i&&(r=a=Math.abs(e[1]-e[0]),i=0);var s=Tf(e,i);e[i]+=t;var l=r||0,u=n.slice();s.sign<0?u[0]+=l:u[1]-=l,e[i]=If(e[i],u);var h=Tf(e,i);null!=r&&(h.sign!==s.sign||h.span<r)&&(e[1-i]=e[i]+s.sign*r);var h=Tf(e,i);return null!=a&&h.span>a&&(e[1-i]=e[i]+h.sign*a),e};Ey.registerSubTypeDefaulter("dataZoom",function(){return"slider"});var qS=["x","y","z","radius","angle","single"],$S=["cartesian2d","polar","singleAxis"],KS=Df(qS,["axisIndex","axis","index","id"]),QS=f,JS=Ha,tM=function(t,e,n,i){this._dimName=t,this._axisIndex=e,this._valueWindow,this._percentWindow,this._dataExtent,this._minMaxSpan,this.ecModel=i,this._dataZoomModel=n,this.hasSeriesStacked};tM.prototype={constructor:tM,hostedBy:function(t){return this._dataZoomModel===t},getDataValueWindow:function(){return this._valueWindow.slice()},getDataPercentWindow:function(){return this._percentWindow.slice()},getTargetSeriesModels:function(){var t=[],e=this.ecModel;return e.eachSeries(function(n){if(Cf(n.get("coordinateSystem"))){var i=this._dimName,r=e.queryComponents({mainType:i+"Axis",index:n.get(i+"AxisIndex"),id:n.get(i+"AxisId")})[0];this._axisIndex===(r&&r.componentIndex)&&t.push(n)}},this),t},getAxisModel:function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},getOtherAxisModel:function(){var t,e,n=this._dimName,i=this.ecModel,r=this.getAxisModel(),a="x"===n||"y"===n;a?(e="gridIndex",t="x"===n?"y":"x"):(e="polarIndex",t="angle"===n?"radius":"angle");var o;return i.eachComponent(t+"Axis",function(t){(t.get(e)||0)===(r.get(e)||0)&&(o=t)}),o},getMinMaxSpan:function(){return i(this._minMaxSpan)},calculateDataWindow:function(t){var e=this._dataExtent,n=this.getAxisModel(),i=n.axis.scale,r=this._dataZoomModel.getRangePropMode(),a=[0,100],o=[t.start,t.end],s=[];return QS(["startValue","endValue"],function(e){s.push(null!=t[e]?i.parse(t[e]):null)}),QS([0,1],function(t){var n=s[t],l=o[t];"percent"===r[t]?(null==l&&(l=a[t]),n=i.parse(Na(l,a,e,!0))):l=Na(n,e,a,!0),s[t]=n,o[t]=l}),{valueWindow:JS(s),percentWindow:JS(o)}},reset:function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=kf(this,this._dimName,e),this.hasSeriesStacked=!1,QS(e,function(t){var e=t.getData(),n=e.mapDimension(this._dimName);e.isStacked(n)&&(this.hasSeriesStacked=!0)},this);var n=this.calculateDataWindow(t.option);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,Of(this),Lf(this)}},restore:function(t){t===this._dataZoomModel&&(this._valueWindow=this._percentWindow=null,Lf(this,!0))},filterData:function(t){function e(t){return t>=a[0]&&t<=a[1]}if(t===this._dataZoomModel){var n=this._dimName,i=this.getTargetSeriesModels(),r=t.get("filterMode"),a=this._valueWindow;if("none"!==r){var o=this.getOtherAxisModel();t.get("$fromToolbox")&&o&&o.hasSeriesStacked&&(r="empty"),QS(i,function(t){var i=t.getData(),o=i.mapDimension(n,!0);"weakFilter"===r?i.filterSelf(function(t){for(var e,n,r,s=0;s<o.length;s++){var l=i.get(o[s],t),u=!isNaN(l),h=l<a[0],c=l>a[1];if(u&&!h&&!c)return!0;u&&(r=!0),h&&(e=!0),c&&(n=!0)}return r&&e&&n}):QS(o,function(n){if("empty"===r)t.setData(i.map(n,function(t){return e(t)?t:0/0}));else{var o={};o[n]=a,i.selectRange(o)}}),QS(o,function(t){i.setApproximateExtent(a,t)})})}}}};var eM=f,nM=KS,iM=Pl({type:"dataZoom",dependencies:["xAxis","yAxis","zAxis","radiusAxis","angleAxis","singleAxis","series"],defaultOption:{zlevel:0,z:4,orient:null,xAxisIndex:null,yAxisIndex:null,filterMode:"filter",throttle:null,start:0,end:100,startValue:null,endValue:null,minSpan:null,maxSpan:null,minValueSpan:null,maxValueSpan:null,rangeMode:null},init:function(t,e,n){this._dataIntervalByAxis={},this._dataInfo={},this._axisProxies={},this.textStyleModel,this._autoThrottle=!0,this._rangePropMode=["percent","percent"];var i=Ef(t);this.mergeDefaultAndTheme(t,n),this.doInit(i)},mergeOption:function(t){var e=Ef(t);r(this.option,t,!0),this.doInit(e)},doInit:function(t){var e=this.option;Sp.canvasSupported||(e.realtime=!1),this._setDefaultThrottle(t),Rf(this,t),eM([["start","startValue"],["end","endValue"]],function(t,n){"value"===this._rangePropMode[n]&&(e[t[0]]=null)},this),this.textStyleModel=this.getModel("textStyle"),this._resetTarget(),this._giveAxisProxies()},_giveAxisProxies:function(){var t=this._axisProxies;this.eachTargetAxis(function(e,n,i,r){var a=this.dependentModels[e.axis][n],o=a.__dzAxisProxy||(a.__dzAxisProxy=new tM(e.name,n,this,r));t[e.name+"_"+n]=o},this)},_resetTarget:function(){var t=this.option,e=this._judgeAutoMode();nM(function(e){var n=e.axisIndex;t[n]=Oi(t[n])},this),"axisIndex"===e?this._autoSetAxisIndex():"orient"===e&&this._autoSetOrient()},_judgeAutoMode:function(){var t=this.option,e=!1;nM(function(n){null!=t[n.axisIndex]&&(e=!0)},this);var n=t.orient;return null==n&&e?"orient":e?void 0:(null==n&&(t.orient="horizontal"),"axisIndex")},_autoSetAxisIndex:function(){var t=!0,e=this.get("orient",!0),n=this.option,i=this.dependentModels;if(t){var r="vertical"===e?"y":"x";i[r+"Axis"].length?(n[r+"AxisIndex"]=[0],t=!1):eM(i.singleAxis,function(i){t&&i.get("orient",!0)===e&&(n.singleAxisIndex=[i.componentIndex],t=!1)})}t&&nM(function(e){if(t){var i=[],r=this.dependentModels[e.axis];if(r.length&&!i.length)for(var a=0,o=r.length;o>a;a++)"category"===r[a].get("type")&&i.push(a);n[e.axisIndex]=i,i.length&&(t=!1)}},this),t&&this.ecModel.eachSeries(function(t){this._isSeriesHasAllAxesTypeOf(t,"value")&&nM(function(e){var i=n[e.axisIndex],r=t.get(e.axisIndex),a=t.get(e.axisId),o=t.ecModel.queryComponents({mainType:e.axis,index:r,id:a})[0];r=o.componentIndex,u(i,r)<0&&i.push(r)})},this)},_autoSetOrient:function(){var t;this.eachTargetAxis(function(e){!t&&(t=e.name)},this),this.option.orient="y"===t?"vertical":"horizontal"},_isSeriesHasAllAxesTypeOf:function(t,e){var n=!0;return nM(function(i){var r=t.get(i.axisIndex),a=this.dependentModels[i.axis][r];a&&a.get("type")===e||(n=!1)},this),n},_setDefaultThrottle:function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var e=this.ecModel.option;this.option.throttle=e.animation&&e.animationDurationUpdate>0?100:20}},getFirstTargetAxisModel:function(){var t;return nM(function(e){if(null==t){var n=this.get(e.axisIndex);n.length&&(t=this.dependentModels[e.axis][n[0]])}},this),t},eachTargetAxis:function(t,e){var n=this.ecModel;nM(function(i){eM(this.get(i.axisIndex),function(r){t.call(e,i,r,this,n)},this)},this)},getAxisProxy:function(t,e){return this._axisProxies[t+"_"+e]},getAxisModel:function(t,e){var n=this.getAxisProxy(t,e);return n&&n.getAxisModel()},setRawRange:function(t,e){var n=this.option;eM([["start","startValue"],["end","endValue"]],function(e){(null!=t[e[0]]||null!=t[e[1]])&&(n[e[0]]=t[e[0]],n[e[1]]=t[e[1]])},this),!e&&Rf(this,t)},getPercentRange:function(){var t=this.findRepresentativeAxisProxy();return t?t.getDataPercentWindow():void 0},getValueRange:function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var n=this.findRepresentativeAxisProxy();return n?n.getDataValueWindow():void 0},findRepresentativeAxisProxy:function(t){if(t)return t.__dzAxisProxy;var e=this._axisProxies;for(var n in e)if(e.hasOwnProperty(n)&&e[n].hostedBy(this))return e[n];for(var n in e)if(e.hasOwnProperty(n)&&!e[n].hostedBy(this))return e[n]},getRangePropMode:function(){return this._rangePropMode.slice()}}),rM=x_.extend({type:"dataZoom",render:function(t,e,n){this.dataZoomModel=t,this.ecModel=e,this.api=n},getTargetCoordInfo:function(){function t(t,e,n,i){for(var r,a=0;a<n.length;a++)if(n[a].model===t){r=n[a];break}r||n.push(r={model:t,axisModels:[],coordIndex:i}),r.axisModels.push(e)}var e=this.dataZoomModel,n=this.ecModel,i={};return e.eachTargetAxis(function(e,r){var a=n.getComponent(e.axis,r);if(a){var o=a.getCoordSysModel();o&&t(o,a,i[o.mainType]||(i[o.mainType]=[]),o.componentIndex)}},this),i}});iM.extend({type:"dataZoom.select"}),rM.extend({type:"dataZoom.select"}),bl({getTargetSeries:function(t){var e=N();return t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,n,i){var r=i.getAxisProxy(t.name,n);f(r.getTargetSeriesModels(),function(t){e.set(t.uid,t)})})}),e},isOverallFilter:!0,overallReset:function(t,e){t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,n,i){i.getAxisProxy(t.name,n).reset(i,e)}),t.eachTargetAxis(function(t,n,i){i.getAxisProxy(t.name,n).filterData(i,e)})}),t.eachComponent("dataZoom",function(t){var e=t.findRepresentativeAxisProxy(),n=e.getDataPercentWindow(),i=e.getDataValueWindow();t.setRawRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]},!0)})}}),Ml("dataZoom",function(t,e){var n=Af(y(e.eachComponent,e,"dataZoom"),KS,function(t,e){return t.get(e.axisIndex)}),i=[];e.eachComponent({mainType:"dataZoom",query:t},function(t){i.push.apply(i,n(t).nodes)}),f(i,function(e){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})});var aM=k_.toolbox.dataZoom,oM=f,sM="\x00_ec_\x00toolbox-dataZoom_";zf.defaultOption={show:!0,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:i(aM.title)};var lM=zf.prototype;lM.render=function(t,e,n,i){this.model=t,this.ecModel=e,this.api=n,Vf(t,e,this,i,n),Nf(t,e)},lM.onclick=function(t,e,n){uM[n].call(this)},lM.remove=function(){this._brushController.unmount()},lM.dispose=function(){this._brushController.dispose()};var uM={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(wf(this.ecModel))}};lM._onBrush=function(t,e){function n(t,e,n){var o=e.getAxis(t),s=o.model,l=i(t,s,a),u=l.findRepresentativeAxisProxy(s).getMinMaxSpan();(null!=u.minValueSpan||null!=u.maxValueSpan)&&(n=YS(0,n.slice(),o.scale.getExtent(),0,u.minValueSpan,u.maxValueSpan)),l&&(r[l.id]={dataZoomId:l.id,startValue:n[0],endValue:n[1]})}function i(t,e,n){var i;return n.eachComponent({mainType:"dataZoom",subType:"select"},function(n){var r=n.getAxisModel(t,e.componentIndex);r&&(i=n)}),i}if(e.isEnd&&t.length){var r={},a=this.ecModel;this._brushController.updateCovers([]);var o=new ff(Bf(this.model.option),a,{include:["grid"]});o.matchOutputRanges(t,a,function(t,e,i){if("cartesian2d"===i.type){var r=t.brushType;"rect"===r?(n("x",i,e[0]),n("y",i,e[1])):n({lineX:"x",lineY:"y"}[r],i,e)}}),xf(a,r),this._dispatchZoomAction(r)}},lM._dispatchZoomAction=function(t){var e=[];oM(t,function(t){e.push(i(t))}),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},cd("dataZoom",zf),wl(function(t){function e(t,e){if(e){var r=t+"Index",a=e[r];null==a||"all"==a||x(a)||(a=a===!1||"none"===a?[]:[a]),n(t,function(e,n){if(null==a||"all"==a||-1!==u(a,n)){var o={type:"select",$fromToolbox:!0,id:sM+t+n};o[r]=n,i.push(o)}})}}function n(e,n){var i=t[e];x(i)||(i=i?[i]:[]),oM(i,n)}if(t){var i=t.dataZoom||(t.dataZoom=[]);x(i)||(t.dataZoom=i=[i]);var r=t.toolbox;if(r&&(x(r)&&(r=r[0]),r&&r.feature)){var a=r.feature.dataZoom;e("xAxis",a),e("yAxis",a)}}});var hM=k_.toolbox.restore;Ff.defaultOption={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:hM.title};var cM=Ff.prototype;cM.onclick=function(t,e){bf(t),e.dispatchAction({type:"restore",from:this.uid})},cd("restore",Ff),Ml({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var dM,fM="urn:schemas-microsoft-com:vml",pM="undefined"==typeof window?null:window,gM=!1,vM=pM&&pM.document;if(vM&&!Sp.canvasSupported)try{!vM.namespaces.zrvml&&vM.namespaces.add("zrvml",fM),dM=function(t){return vM.createElement("<zrvml:"+t+' class="zrvml">')}}catch(mM){dM=function(t){return vM.createElement("<"+t+' xmlns="'+fM+'" class="zrvml">')}}var yM=pm.CMD,_M=Math.round,xM=Math.sqrt,wM=Math.abs,bM=Math.cos,SM=Math.sin,MM=Math.max;if(!Sp.canvasSupported){var TM=",",IM="progid:DXImageTransform.Microsoft",CM=21600,DM=CM/2,AM=1e5,kM=1e3,PM=function(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=CM+","+CM,t.coordorigin="0,0"},LM=function(t){return String(t).replace(/&/g,"&").replace(/"/g,""")},OM=function(t,e,n){return"rgb("+[t,e,n].join(",")+")"},EM=function(t,e){e&&t&&e.parentNode!==t&&t.appendChild(e)},RM=function(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)},zM=function(t,e,n){return(parseFloat(t)||0)*AM+(parseFloat(e)||0)*kM+n},BM=function(t,e){return"string"==typeof t?t.lastIndexOf("%%")>=0?parseFloat(t)/100*e:parseFloat(t):t},NM=function(t,e,n){var i=Ee(e);n=+n,isNaN(n)&&(n=1),i&&(t.color=OM(i[0],i[1],i[2]),t.opacity=n*i[3])},VM=function(t){var e=Ee(t);return[OM(e[0],e[1],e[2]),e[3]]},FM=function(t,e,n){var i=e.fill;if(null!=i)if(i instanceof ty){var r,a=0,o=[0,0],s=0,l=1,u=n.getBoundingRect(),h=u.width,c=u.height;if("linear"===i.type){r="gradient";var d=n.transform,f=[i.x*h,i.y*c],p=[i.x2*h,i.y2*c];d&&(ae(f,f,d),ae(p,p,d));var g=p[0]-f[0],v=p[1]-f[1];a=180*Math.atan2(g,v)/Math.PI,0>a&&(a+=360),1e-6>a&&(a=0)}else{r="gradientradial";var f=[i.x*h,i.y*c],d=n.transform,m=n.scale,y=h,_=c;o=[(f[0]-u.x)/y,(f[1]-u.y)/_],d&&ae(f,f,d),y/=m[0]*CM,_/=m[1]*CM;var x=MM(y,_);s=0/x,l=2*i.r/x-s}var w=i.colorStops.slice();w.sort(function(t,e){return t.offset-e.offset});for(var b=w.length,S=[],M=[],T=0;b>T;T++){var I=w[T],C=VM(I.color);M.push(I.offset*l+s+" "+C[0]),(0===T||T===b-1)&&S.push(C)}if(b>=2){var D=S[0][0],A=S[1][0],k=S[0][1]*e.opacity,P=S[1][1]*e.opacity;t.type=r,t.method="none",t.focus="100%%",t.angle=a,t.color=D,t.color2=A,t.colors=M.join(","),t.opacity=P,t.opacity2=k}"radial"===r&&(t.focusposition=o.join(","))}else NM(t,i,e.opacity)},HM=function(t,e){null!=e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e.stroke||e.stroke instanceof ty||NM(t,e.stroke,e.opacity)},WM=function(t,e,n,i){var r="fill"==e,a=t.getElementsByTagName(e)[0];null!=n[e]&&"none"!==n[e]&&(r||!r&&n.lineWidth)?(t[r?"filled":"stroked"]="true",n[e]instanceof ty&&RM(t,a),a||(a=Hf(e)),r?FM(a,n,i):HM(a,n),EM(t,a)):(t[r?"filled":"stroked"]="false",RM(t,a))},GM=[[],[],[]],jM=function(t,e){var n,i,r,a,o,s,l=yM.M,u=yM.C,h=yM.L,c=yM.A,d=yM.Q,f=[],p=t.data,g=t.len();for(a=0;g>a;){switch(r=p[a++],i="",n=0,r){case l:i=" m ",n=1,o=p[a++],s=p[a++],GM[0][0]=o,GM[0][1]=s;break;case h:i=" l ",n=1,o=p[a++],s=p[a++],GM[0][0]=o,GM[0][1]=s;break;case d:case u:i=" c ",n=3;var v,m,y=p[a++],_=p[a++],x=p[a++],w=p[a++];r===d?(v=x,m=w,x=(x+2*y)/3,w=(w+2*_)/3,y=(o+2*y)/3,_=(s+2*_)/3):(v=p[a++],m=p[a++]),GM[0][0]=y,GM[0][1]=_,GM[1][0]=x,GM[1][1]=w,GM[2][0]=v,GM[2][1]=m,o=v,s=m;break;case c:var b=0,S=0,M=1,T=1,I=0;e&&(b=e[4],S=e[5],M=xM(e[0]*e[0]+e[1]*e[1]),T=xM(e[2]*e[2]+e[3]*e[3]),I=Math.atan2(-e[1]/T,e[0]/M));var C=p[a++],D=p[a++],A=p[a++],k=p[a++],P=p[a++]+I,L=p[a++]+P+I;a++;var O=p[a++],E=C+bM(P)*A,R=D+SM(P)*k,y=C+bM(L)*A,_=D+SM(L)*k,z=O?" wa ":" at ";Math.abs(E-y)<1e-4&&(Math.abs(L-P)>.01?O&&(E+=270/CM):Math.abs(R-D)<1e-4?O&&C>E||!O&&E>C?_-=270/CM:_+=270/CM:O&&D>R||!O&&R>D?y+=270/CM:y-=270/CM),f.push(z,_M(((C-A)*M+b)*CM-DM),TM,_M(((D-k)*T+S)*CM-DM),TM,_M(((C+A)*M+b)*CM-DM),TM,_M(((D+k)*T+S)*CM-DM),TM,_M((E*M+b)*CM-DM),TM,_M((R*T+S)*CM-DM),TM,_M((y*M+b)*CM-DM),TM,_M((_*T+S)*CM-DM)),o=y,s=_;break;case yM.R:var B=GM[0],N=GM[1];B[0]=p[a++],B[1]=p[a++],N[0]=B[0]+p[a++],N[1]=B[1]+p[a++],e&&(ae(B,B,e),ae(N,N,e)),B[0]=_M(B[0]*CM-DM),N[0]=_M(N[0]*CM-DM),B[1]=_M(B[1]*CM-DM),N[1]=_M(N[1]*CM-DM),f.push(" m ",B[0],TM,B[1]," l ",N[0],TM,B[1]," l ",N[0],TM,N[1]," l ",B[0],TM,N[1]);break;case yM.Z:f.push(" x ")}if(n>0){f.push(i);for(var V=0;n>V;V++){var F=GM[V];e&&ae(F,F,e),f.push(_M(F[0]*CM-DM),TM,_M(F[1]*CM-DM),n-1>V?TM:"")}}}return f.join("")};Lr.prototype.brushVML=function(t){var e=this.style,n=this._vmlEl;n||(n=Hf("shape"),PM(n),this._vmlEl=n),WM(n,"fill",e,this),WM(n,"stroke",e,this);var i=this.transform,r=null!=i,a=n.getElementsByTagName("stroke")[0];if(a){var o=e.lineWidth;if(r&&!e.strokeNoScale){var s=i[0]*i[3]-i[1]*i[2];o*=xM(wM(s))}a.weight=o+"px"}var l=this.path||(this.path=new pm);this.__dirtyPath&&(l.beginPath(),this.buildPath(l,this.shape),l.toStatic(),this.__dirtyPath=!1),n.path=jM(l,this.transform),n.style.zIndex=zM(this.zlevel,this.z,this.z2),EM(t,n),null!=e.text?this.drawRectText(t,this.getBoundingRect()):this.removeRectText(t)},Lr.prototype.onRemove=function(t){RM(t,this._vmlEl),this.removeRectText(t)},Lr.prototype.onAdd=function(t){EM(t,this._vmlEl),this.appendRectText(t)};var UM=function(t){return"object"==typeof t&&t.tagName&&"IMG"===t.tagName.toUpperCase()};oi.prototype.brushVML=function(t){var e,n,i=this.style,r=i.image;if(UM(r)){var a=r.src;if(a===this._imageSrc)e=this._imageWidth,n=this._imageHeight;else{var o=r.runtimeStyle,s=o.width,l=o.height;o.width="auto",o.height="auto",e=r.width,n=r.height,o.width=s,o.height=l,this._imageSrc=a,this._imageWidth=e,this._imageHeight=n}r=a}else r===this._imageSrc&&(e=this._imageWidth,n=this._imageHeight);if(r){var u=i.x||0,h=i.y||0,c=i.width,d=i.height,f=i.sWidth,p=i.sHeight,g=i.sx||0,v=i.sy||0,m=f&&p,y=this._vmlEl;y||(y=vM.createElement("div"),PM(y),this._vmlEl=y);var _,x=y.style,w=!1,b=1,S=1;if(this.transform&&(_=this.transform,b=xM(_[0]*_[0]+_[1]*_[1]),S=xM(_[2]*_[2]+_[3]*_[3]),w=_[1]||_[2]),w){var M=[u,h],T=[u+c,h],I=[u,h+d],C=[u+c,h+d];ae(M,M,_),ae(T,T,_),ae(I,I,_),ae(C,C,_);var D=MM(M[0],T[0],I[0],C[0]),A=MM(M[1],T[1],I[1],C[1]),k=[];k.push("M11=",_[0]/b,TM,"M12=",_[2]/S,TM,"M21=",_[1]/b,TM,"M22=",_[3]/S,TM,"Dx=",_M(u*b+_[4]),TM,"Dy=",_M(h*S+_[5])),x.padding="0 "+_M(D)+"px "+_M(A)+"px 0",x.filter=IM+".Matrix("+k.join("")+", SizingMethod=clip)"}else _&&(u=u*b+_[4],h=h*S+_[5]),x.filter="",x.left=_M(u)+"px",x.top=_M(h)+"px";var P=this._imageEl,L=this._cropEl;P||(P=vM.createElement("div"),this._imageEl=P);var O=P.style;if(m){if(e&&n)O.width=_M(b*e*c/f)+"px",O.height=_M(S*n*d/p)+"px";else{var E=new Image,R=this;E.onload=function(){E.onload=null,e=E.width,n=E.height,O.width=_M(b*e*c/f)+"px",O.height=_M(S*n*d/p)+"px",R._imageWidth=e,R._imageHeight=n,R._imageSrc=r},E.src=r}L||(L=vM.createElement("div"),L.style.overflow="hidden",this._cropEl=L);var z=L.style;z.width=_M((c+g*c/f)*b),z.height=_M((d+v*d/p)*S),z.filter=IM+".Matrix(Dx="+-g*c/f*b+",Dy="+-v*d/p*S+")",L.parentNode||y.appendChild(L),P.parentNode!=L&&L.appendChild(P)}else O.width=_M(b*c)+"px",O.height=_M(S*d)+"px",y.appendChild(P),L&&L.parentNode&&(y.removeChild(L),this._cropEl=null);var B="",N=i.opacity;1>N&&(B+=".Alpha(opacity="+_M(100*N)+") "),B+=IM+".AlphaImageLoader(src="+r+", SizingMethod=scale)",O.filter=B,y.style.zIndex=zM(this.zlevel,this.z,this.z2),EM(t,y),null!=i.text&&this.drawRectText(t,this.getBoundingRect())}},oi.prototype.onRemove=function(t){RM(t,this._vmlEl),this._vmlEl=null,this._cropEl=null,this._imageEl=null,this.removeRectText(t)},oi.prototype.onAdd=function(t){EM(t,this._vmlEl),this.appendRectText(t)};var ZM,XM="normal",YM={},qM=0,$M=100,KM=document.createElement("div"),QM=function(t){var e=YM[t];if(!e){qM>$M&&(qM=0,YM={});var n,i=KM.style;try{i.font=t,n=i.fontFamily.split(",")[0]}catch(r){}e={style:i.fontStyle||XM,variant:i.fontVariant||XM,weight:i.fontWeight||XM,size:0|parseFloat(i.fontSize||12),family:n||"Microsoft YaHei"},YM[t]=e,qM++}return e};bn("measureText",function(t,e){var n=vM;ZM||(ZM=n.createElement("div"),ZM.style.cssText="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;",vM.body.appendChild(ZM));try{ZM.style.font=e}catch(i){}return ZM.innerHTML="",ZM.appendChild(n.createTextNode(t)),{width:ZM.offsetWidth}});for(var JM=new rn,tT=function(t,e,n,i){var r=this.style;this.__dirty&&Hn(r,!0);var a=r.text;if(null!=a&&(a+=""),a){if(r.rich){var o=Bn(a,r);a=[];for(var s=0;s<o.lines.length;s++){for(var l=o.lines[s].tokens,u=[],h=0;h<l.length;h++)u.push(l[h].text);a.push(u.join(""))}a=a.join("\n")}var c,d,f=r.textAlign,p=r.textVerticalAlign,g=QM(r.font),v=g.style+" "+g.variant+" "+g.weight+" "+g.size+'px "'+g.family+'"';n=n||Mn(a,v,f,p);var m=this.transform;if(m&&!i&&(JM.copy(e),JM.applyTransform(m),e=JM),i)c=e.x,d=e.y;else{var y=r.textPosition,_=r.textDistance;if(y instanceof Array)c=e.x+BM(y[0],e.width),d=e.y+BM(y[1],e.height),f=f||"left";else{var x=An(y,e,_);c=x.x,d=x.y,f=f||x.textAlign,p=p||x.textVerticalAlign}}c=Cn(c,n.width,f),d=Dn(d,n.height,p),d+=n.height/2;var w,b,S,M=Hf,T=this._textVmlEl;T?(S=T.firstChild,w=S.nextSibling,b=w.nextSibling):(T=M("line"),w=M("path"),b=M("textpath"),S=M("skew"),b.style["v-text-align"]="left",PM(T),w.textpathok=!0,b.on=!0,T.from="0 0",T.to="1000 0.05",EM(T,S),EM(T,w),EM(T,b),this._textVmlEl=T);var I=[c,d],C=T.style;m&&i?(ae(I,I,m),S.on=!0,S.matrix=m[0].toFixed(3)+TM+m[2].toFixed(3)+TM+m[1].toFixed(3)+TM+m[3].toFixed(3)+",0,0",S.offset=(_M(I[0])||0)+","+(_M(I[1])||0),S.origin="0 0",C.left="0px",C.top="0px"):(S.on=!1,C.left=_M(c)+"px",C.top=_M(d)+"px"),b.string=LM(a);try{b.style.font=v}catch(D){}WM(T,"fill",{fill:r.textFill,opacity:r.opacity},this),WM(T,"stroke",{stroke:r.textStroke,opacity:r.opacity,lineDash:r.lineDash},this),T.style.zIndex=zM(this.zlevel,this.z,this.z2),EM(t,T)}},eT=function(t){RM(t,this._textVmlEl),this._textVmlEl=null},nT=function(t){EM(t,this._textVmlEl)},iT=[$g,ai,oi,Lr,Nm],rT=0;rT<iT.length;rT++){var aT=iT[rT].prototype;aT.drawRectText=tT,aT.removeRectText=eT,aT.appendRectText=nT}Nm.prototype.brushVML=function(t){var e=this.style;null!=e.text?this.drawRectText(t,{x:e.x||0,y:e.y||0,width:0,height:0},this.getBoundingRect(),!0):this.removeRectText(t)},Nm.prototype.onRemove=function(t){this.removeRectText(t)},Nm.prototype.onAdd=function(t){this.appendRectText(t)}}jf.prototype={constructor:jf,getType:function(){return"vml"},getViewportRoot:function(){return this._vmlViewport},getViewportRootOffset:function(){var t=this.getViewportRoot();return t?{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}:void 0},refresh:function(){var t=this.storage.getDisplayList(!0,!0);this._paintList(t)},_paintList:function(t){for(var e=this._vmlRoot,n=0;n<t.length;n++){var i=t[n];i.invisible||i.ignore?(i.__alreadyNotVisible||i.onRemove(e),i.__alreadyNotVisible=!0):(i.__alreadyNotVisible&&i.onAdd(e),i.__alreadyNotVisible=!1,i.__dirty&&(i.beforeBrush&&i.beforeBrush(),(i.brushVML||i.brush).call(i,e),i.afterBrush&&i.afterBrush())),i.__dirty=!1}this._firstPaint&&(this._vmlViewport.appendChild(e),this._firstPaint=!1)},resize:function(t,e){var t=null==t?this._getWidth():t,e=null==e?this._getHeight():e;if(this._width!=t||this._height!=e){this._width=t,this._height=e;var n=this._vmlViewport.style;n.width=t+"px",n.height=e+"px"}},dispose:function(){this.root.innerHTML="",this._vmlRoot=this._vmlViewport=this.storage=null},getWidth:function(){return this._width},getHeight:function(){return this._height},clear:function(){this._vmlViewport&&this.root.removeChild(this._vmlViewport)},_getWidth:function(){var t=this.root,e=t.currentStyle;return(t.clientWidth||Gf(e.width))-Gf(e.paddingLeft)-Gf(e.paddingRight)|0},_getHeight:function(){var t=this.root,e=t.currentStyle;return(t.clientHeight||Gf(e.height))-Gf(e.paddingTop)-Gf(e.paddingBottom)|0}},f(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){jf.prototype[t]=Uf(t)}),Pi("vml",jf);var oT="http://www.w3.org/2000/svg",sT=pm.CMD,lT=Array.prototype.join,uT="none",hT=Math.round,cT=Math.sin,dT=Math.cos,fT=Math.PI,pT=2*Math.PI,gT=180/fT,vT=1e-4,mT={};mT.brush=function(t){var e=t.style,n=t.__svgEl;n||(n=Zf("path"),t.__svgEl=n),t.path||t.createPathProxy();var i=t.path;if(t.__dirtyPath){i.beginPath(),t.buildPath(i,t.shape),t.__dirtyPath=!1;var r=ep(i);r.indexOf("NaN")<0&&Qf(n,"d",r)}tp(n,e),Kf(n,t.transform),null!=e.text&&wT(t,t.getBoundingRect())};var yT={};yT.brush=function(t){var e=t.style,n=e.image;if(n instanceof HTMLImageElement){var i=n.src;n=i}if(n){var r=e.x||0,a=e.y||0,o=e.width,s=e.height,l=t.__svgEl;l||(l=Zf("image"),t.__svgEl=l),n!==t.__imageSrc&&(Jf(l,"href",n),t.__imageSrc=n),Qf(l,"width",o),Qf(l,"height",s),Qf(l,"x",r),Qf(l,"y",a),Kf(l,t.transform),null!=e.text&&wT(t,t.getBoundingRect())}};var _T={},xT=new rn,wT=function(t,e,n){var i=t.style;t.__dirty&&Hn(i,!0);var r=i.text;if(null!=r){r+="";var a=t.__textSvgEl;if(a||(a=Zf("text"),t.__textSvgEl=a),tp(a,i,!0),t instanceof Nm||t.style.transformText)Kf(a,t.transform);else if(t.transform)xT.copy(e),xT.applyTransform(t.transform),e=xT;else{var o=t.transformCoordToGlobal(e.x,e.y);e.x=o[0],e.y=o[1]}var s,l,u=i.textPosition,h=i.textDistance,c=i.textAlign||"left";"number"==typeof i.fontSize&&(i.fontSize+="px");var d=i.font||[i.fontStyle||"",i.fontWeight||"",i.fontSize||"",i.fontFamily||""].join(" ")||Ug,f=np(i.textVerticalAlign);n=Mn(r,d,c,f);var p=n.lineHeight;if(u instanceof Array)s=e.x+u[0],l=e.y+u[1];else{var g=An(u,e,h);s=g.x,l=g.y,f=np(g.textVerticalAlign),c=g.textAlign}Qf(a,"alignment-baseline",f),d&&(a.style.font=d);var v=i.textPadding;Qf(a,"x",s),Qf(a,"y",l);var m=r.split("\n"),y=m.length,_=c;"left"===_?(_="start",v&&(s+=v[3])):"right"===_?(_="end",v&&(s-=v[1])):"center"===_&&(_="middle",v&&(s+=(v[3]-v[1])/2));var x=0;if("baseline"===f?(x=-n.height+p,v&&(x-=v[2])):"middle"===f?(x=(-n.height+p)/2,v&&(l+=(v[0]-v[2])/2)):v&&(x+=v[0]),t.__text!==r||t.__textFont!==d){var w=t.__tspanList||[];t.__tspanList=w;for(var b=0;y>b;b++){var S=w[b];S?S.innerHTML="":(S=w[b]=Zf("tspan"),a.appendChild(S),Qf(S,"alignment-baseline",f),Qf(S,"text-anchor",_)),Qf(S,"x",s),Qf(S,"y",l+b*p+x),S.appendChild(document.createTextNode(m[b]))}for(;b<w.length;b++)a.removeChild(w[b]);w.length=y,t.__text=r,t.__textFont=d}else if(t.__tspanList.length)for(var M=t.__tspanList.length,b=0;M>b;++b){var S=t.__tspanList[b];S&&(Qf(S,"x",s),Qf(S,"y",l+b*p+x))}}};_T.drawRectText=wT,_T.brush=function(t){var e=t.style;null!=e.text&&(e.textPosition=[0,0],wT(t,{x:e.x||0,y:e.y||0,width:0,height:0},t.getBoundingRect()))},ip.prototype={diff:function(t,e,n){function i(){for(var n=-1*s;s>=n;n+=2){var i,l=u[n-1],h=u[n+1],c=(h?h.newPos:0)-n;l&&(u[n-1]=void 0);var d=l&&l.newPos+1<a,f=h&&c>=0&&o>c;if(d||f){if(!d||f&&l.newPos<h.newPos?(i=ap(h),r.pushComponent(i.components,void 0,!0)):(i=l,i.newPos++,r.pushComponent(i.components,!0,void 0)),c=r.extractCommon(i,e,t,n),i.newPos+1>=a&&c+1>=o)return rp(r,i.components,e,t);u[n]=i}else u[n]=void 0}s++}n||(n=function(t,e){return t===e}),this.equals=n;var r=this;t=t.slice(),e=e.slice();var a=e.length,o=t.length,s=1,l=a+o,u=[{newPos:-1,components:[]}],h=this.extractCommon(u[0],e,t,0);if(u[0].newPos+1>=a&&h+1>=o){for(var c=[],d=0;d<e.length;d++)c.push(d);return[{indices:c,count:e.length}]}for(;l>=s;){var f=i();if(f)return f}},pushComponent:function(t,e,n){var i=t[t.length-1];i&&i.added===e&&i.removed===n?t[t.length-1]={count:i.count+1,added:e,removed:n}:t.push({count:1,added:e,removed:n})},extractCommon:function(t,e,n,i){for(var r=e.length,a=n.length,o=t.newPos,s=o-i,l=0;r>o+1&&a>s+1&&this.equals(e[o+1],n[s+1]);)o++,s++,l++;return l&&t.components.push({count:l}),t.newPos=o,s},tokenize:function(t){return t.slice()},join:function(t){return t.slice()}};var bT=new ip,ST=function(t,e,n){return bT.diff(t,e,n)},MT="0",TT="1";op.prototype.createElement=Zf,op.prototype.getDefs=function(t){var e=this._svgRoot,n=this._svgRoot.getElementsByTagName("defs");return 0===n.length?t?(n=e.insertBefore(this.createElement("defs"),e.firstChild),n.contains||(n.contains=function(t){var e=n.children;if(!e)return!1;for(var i=e.length-1;i>=0;--i)if(e[i]===t)return!0;return!1}),n):null:n[0]},op.prototype.update=function(t,e){if(t){var n=this.getDefs(!1);if(t[this._domName]&&n.contains(t[this._domName]))"function"==typeof e&&e(t);else{var i=this.add(t);i&&(t[this._domName]=i)}}},op.prototype.addDom=function(t){var e=this.getDefs(!0);e.appendChild(t)},op.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},op.prototype.getDoms=function(){var t=this.getDefs(!1);if(!t)return[];var e=[];return f(this._tagNames,function(n){var i=t.getElementsByTagName(n);e=e.concat([].slice.call(i))}),e},op.prototype.markAllUnused=function(){var t=this.getDoms(),e=this;f(t,function(t){t[e._markLabel]=MT})},op.prototype.markUsed=function(t){t&&(t[this._markLabel]=TT)},op.prototype.removeUnused=function(){var t=this.getDefs(!1);if(t){var e=this.getDoms(),n=this;f(e,function(e){e[n._markLabel]!==TT&&t.removeChild(e)})}},op.prototype.getSvgProxy=function(t){return t instanceof Lr?mT:t instanceof oi?yT:t instanceof Nm?_T:mT},op.prototype.getTextSvgElement=function(t){return t.__textSvgEl},op.prototype.getSvgElement=function(t){return t.__svgEl},h(sp,op),sp.prototype.addWithoutUpdate=function(t,e){if(e&&e.style){var n=this;f(["fill","stroke"],function(i){if(e.style[i]&&("linear"===e.style[i].type||"radial"===e.style[i].type)){var r,a=e.style[i],o=n.getDefs(!0);a._dom?(r=a._dom,o.contains(a._dom)||n.addDom(r)):r=n.add(a),n.markUsed(e);var s=r.getAttribute("id");t.setAttribute(i,"url(#"+s+")")}})}},sp.prototype.add=function(t){var e;if("linear"===t.type)e=this.createElement("linearGradient");else{if("radial"!==t.type)return xg("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},sp.prototype.update=function(t){var e=this;op.prototype.update.call(this,t,function(){var n=t.type,i=t._dom.tagName;"linear"===n&&"linearGradient"===i||"radial"===n&&"radialGradient"===i?e.updateDom(t,t._dom):(e.removeDom(t),e.add(t))})},sp.prototype.updateDom=function(t,e){if("linear"===t.type)e.setAttribute("x1",t.x),e.setAttribute("y1",t.y),e.setAttribute("x2",t.x2),e.setAttribute("y2",t.y2);else{if("radial"!==t.type)return void xg("Illegal gradient type.");e.setAttribute("cx",t.x),e.setAttribute("cy",t.y),e.setAttribute("r",t.r)}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var n=t.colorStops,i=0,r=n.length;r>i;++i){var a=this.createElement("stop");a.setAttribute("offset",100*n[i].offset+"%%"),a.setAttribute("stop-color",n[i].color),e.appendChild(a)}t._dom=e},sp.prototype.markUsed=function(t){if(t.style){var e=t.style.fill;e&&e._dom&&op.prototype.markUsed.call(this,e._dom),e=t.style.stroke,e&&e._dom&&op.prototype.markUsed.call(this,e._dom)}},h(lp,op),lp.prototype.update=function(t){var e=this.getSvgElement(t);e&&this.updateDom(e,t.__clipPaths,!1);var n=this.getTextSvgElement(t);n&&this.updateDom(n,t.__clipPaths,!0),this.markUsed(t)},lp.prototype.updateDom=function(t,e,n){if(e&&e.length>0){var i,r,a=this.getDefs(!0),o=e[0],s=n?"_textDom":"_dom";o[s]?(r=o[s].getAttribute("id"),i=o[s],a.contains(i)||a.appendChild(i)):(r="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,i=this.createElement("clipPath"),i.setAttribute("id",r),a.appendChild(i),o[s]=i);var l=this.getSvgProxy(o);if(o.transform&&o.parent.invTransform&&!n){var u=Array.prototype.slice.call(o.transform);ve(o.transform,o.parent.invTransform,o.transform),l.brush(o),o.transform=u}else l.brush(o);var h=this.getSvgElement(o);i.innerHTML="",i.appendChild(h.cloneNode()),t.setAttribute("clip-path","url(#"+r+")"),e.length>1&&this.updateDom(i,e.slice(1),n)}else t&&t.setAttribute("clip-path","none")},lp.prototype.markUsed=function(t){var e=this;t.__clipPaths&&t.__clipPaths.length>0&&f(t.__clipPaths,function(t){t._dom&&op.prototype.markUsed.call(e,t._dom),t._textDom&&op.prototype.markUsed.call(e,t._textDom)})},h(up,op),up.prototype.addWithoutUpdate=function(t,e){if(e&&hp(e.style)){var n,i=e.style;if(i._shadowDom){n=i._shadowDom;var r=this.getDefs(!0);r.contains(i._shadowDom)||this.addDom(n)}else n=this.add(e);this.markUsed(e);var a=n.getAttribute("id");t.style.filter="url(#"+a+")"}},up.prototype.add=function(t){var e=this.createElement("filter"),n=t.style;return n._shadowDomId=n._shadowDomId||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-shadow-"+n._shadowDomId),this.updateDom(t,e),this.addDom(e),e},up.prototype.update=function(t,e){var n=e.style;if(hp(n)){var i=this;op.prototype.update.call(this,e,function(t){i.updateDom(e,t._shadowDom)})}else this.remove(t,n)},up.prototype.remove=function(t,e){null!=e._shadowDomId&&(this.removeDom(e),t.style.filter="")},up.prototype.updateDom=function(t,e){var n=e.getElementsByTagName("feDropShadow");n=0===n.length?this.createElement("feDropShadow"):n[0];var i,r,a,o,s=t.style,l=t.scale?t.scale[0]||1:1,u=t.scale?t.scale[1]||1:1;if(s.shadowBlur||s.shadowOffsetX||s.shadowOffsetY)i=s.shadowOffsetX||0,r=s.shadowOffsetY||0,a=s.shadowBlur,o=s.shadowColor;else{if(!s.textShadowBlur)return void this.removeDom(e,s);i=s.textShadowOffsetX||0,r=s.textShadowOffsetY||0,a=s.textShadowBlur,o=s.textShadowColor}n.setAttribute("dx",i/l),n.setAttribute("dy",r/u),n.setAttribute("flood-color",o);var h=a/2/l,c=a/2/u,d=h+" "+c;n.setAttribute("stdDeviation",d),e.setAttribute("x","-100%%"),e.setAttribute("y","-100%%"),e.setAttribute("width",Math.ceil(a/2*200)+"%%"),e.setAttribute("height",Math.ceil(a/2*200)+"%%"),e.appendChild(n),s._shadowDom=e},up.prototype.markUsed=function(t){var e=t.style;e&&e._shadowDom&&op.prototype.markUsed.call(this,e._shadowDom)};var IT=function(t,e,n,i){this.root=t,this.storage=e,this._opts=n=o({},n||{});var r=Zf("svg");r.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.setAttribute("version","1.1"),r.setAttribute("baseProfile","full"),r.style.cssText="user-select:none;position:absolute;left:0;top:0;",this.gradientManager=new sp(i,r),this.clipPathManager=new lp(i,r),this.shadowManager=new up(i,r);var a=document.createElement("div");a.style.cssText="overflow:hidden;position:relative",this._svgRoot=r,this._viewport=a,t.appendChild(a),a.appendChild(r),this.resize(n.width,n.height),this._visibleList=[]};IT.prototype={constructor:IT,getType:function(){return"svg"},getViewportRoot:function(){return this._viewport},getViewportRootOffset:function(){var t=this.getViewportRoot();return t?{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}:void 0},refresh:function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},_paintList:function(t){this.gradientManager.markAllUnused(),this.clipPathManager.markAllUnused(),this.shadowManager.markAllUnused();var e,n=this._svgRoot,i=this._visibleList,r=t.length,a=[];for(e=0;r>e;e++){var o=t[e],s=dp(o),l=yp(o)||mp(o);o.invisible||(o.__dirty&&(s&&s.brush(o),this.clipPathManager.update(o),o.style&&(this.gradientManager.update(o.style.fill),this.gradientManager.update(o.style.stroke),this.shadowManager.update(l,o)),o.__dirty=!1),a.push(o))}var u,h=ST(i,a);for(e=0;e<h.length;e++){var c=h[e];if(c.removed)for(var d=0;d<c.count;d++){var o=i[c.indices[d]],l=yp(o),f=mp(o);vp(n,l),vp(n,f)}}for(e=0;e<h.length;e++){var c=h[e];if(c.added)for(var d=0;d<c.count;d++){var o=a[c.indices[d]],l=yp(o),f=mp(o);u?pp(n,l,u):gp(n,l),l?pp(n,f,l):u?pp(n,f,u):gp(n,f),pp(n,f,l),u=f||l||u,this.gradientManager.addWithoutUpdate(l,o),this.shadowManager.addWithoutUpdate(u,o),this.clipPathManager.markUsed(o)}else if(!c.removed)for(var d=0;d<c.count;d++){var o=a[c.indices[d]];u=l=mp(o)||yp(o)||u,this.gradientManager.markUsed(o),this.gradientManager.addWithoutUpdate(l,o),this.shadowManager.markUsed(o),this.shadowManager.addWithoutUpdate(l,o),this.clipPathManager.markUsed(o)}}this.gradientManager.removeUnused(),this.clipPathManager.removeUnused(),this.shadowManager.removeUnused(),this._visibleList=a},_getDefs:function(t){var e=this._svgRoot,n=this._svgRoot.getElementsByTagName("defs");if(0===n.length){if(t){var n=e.insertBefore(Zf("defs"),e.firstChild);return n.contains||(n.contains=function(t){var e=n.children;if(!e)return!1;for(var i=e.length-1;i>=0;--i)if(e[i]===t)return!0;return!1}),n}return null}return n[0]},resize:function(t,e){var n=this._viewport;n.style.display="none";var i=this._opts;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width!==t||this._height!==e){this._width=t,this._height=e;var r=n.style;r.width=t+"px",r.height=e+"px";var a=this._svgRoot;a.setAttribute("width",t),a.setAttribute("height",e)}},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||cp(s[n])||cp(o.style[n]))-(cp(s[r])||0)-(cp(s[a])||0)|0},dispose:function(){this.root.innerHTML="",this._svgRoot=this._viewport=this.storage=null},clear:function(){this._viewport&&this.root.removeChild(this._viewport)},pathToSvg:function(){this.refresh();var t=this._svgRoot.outerHTML;return"data:img/svg+xml;utf-8,"+unescape(t)}},f(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){IT.prototype[t]=_p(t)}),Pi("svg",IT),t.version=$_,t.dependencies=K_,t.PRIORITY=ox,t.init=pl,t.connect=gl,t.disConnect=vl,t.disconnect=Ax,t.dispose=ml,t.getInstanceByDom=yl,t.getInstanceById=_l,t.registerTheme=xl,t.registerPreprocessor=wl,t.registerProcessor=bl,t.registerPostUpdate=Sl,t.registerAction=Ml,t.registerCoordinateSystem=Tl,t.getCoordinateSystemDimensions=Il,t.registerLayout=Cl,t.registerVisual=Dl,t.registerLoading=kl,t.extendComponentModel=Pl,t.extendComponentView=Ll,t.extendSeriesModel=Ol,t.extendChartView=El,t.setCanvasCreator=Rl,t.registerMap=zl,t.getMap=Bl,t.dataTool=kx,t.zrender=bv,t.graphic=uy,t.number=xy,t.format=Cy,t.throttle=Ds,t.helper=Sw,t.matrix=$p,t.vector=Gp,t.color=fg,t.parseGeoJSON=Tw,t.parseGeoJson=Aw,t.util=kw,t.List=Nx,t.Model=Pa,t.Axis=Dw,t.env=Sp});if(!Array.prototype.forEach){Array.prototype.forEach=function forEach(callback,thisArg){var T,k;if(this==null){throw new TypeError("this is null or not defined")}var O=Object(this);var len=O.length>>>0;if(typeof callback!=="function"){throw new TypeError(callback+" is not a function")}if(arguments.length>1){T=thisArg}k=0;while(k<len){var kValue;if(k in O){kValue=O[k];callback.call(T,kValue,k,O)}k++}}};
</script>
</head>
<body>
<!-- 为ECharts准备一个具备大小(宽高)的Dom -->
<div id="main"></div>
<script type="text/javascript">
// 基于准备好的dom,初始化echarts实例
var myChart = echarts.init(document.getElementById('main'),'dark');
// 指定图表的配置项和数据
var option = {
title: {
},
tooltip: {
formatter: '{b0}:<br/><pre>{c0}</pre>'
},
legend: [{
type: "scroll",
orient: "vertical",
align: "left",
left: 0,
itemGap: 5,
formatter: function(name) {
return name;
},
tooltip: {
show: true
},
data: %s
}],
toolbox: {
show: true,
feature: {
restore: {
show: true
},
saveAsImage: {
show: true
}
}
},
series: [
{
edgeSymbol: ['circle', 'arrow'],
type: 'graph',
layout: 'force',
focusNodeAdjacency: true,
legendHoverLink: true,
roam: true,
lineStyle: {
normal: {
color: 'source',
curveness: 0,
type: "solid"
}
},
force: {
edgeLength: 125,
repulsion: 200,
gravity: 0.075
},
edgeLabel: {
normal: {
show: true,
formatter: "{c}"
}
},
data: %s,
links: %s,
categories: %s,
label: {
normal: {
show: true,
position: 'top',
}
},
lineStyle: {
normal: {
color: 'source',
curveness: 0,
type: "solid"
}
}
}
]
};
var h = document.body.offsetHeight;
var w = document.body.offsetWidth;
option.series[0].data.forEach(function(fe){
if(fe.name === "%s"){
fe.x = w/2;
fe.y = h/2;
fe.fixed = true;
fe.label = {
fontSize: 20
};
}
});
// 使用刚指定的配置项和数据显示图表。
myChart.setOption(option);
</script>
</body>
</html>`