crabatool 1.0.13 → 1.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.vscode/launch.json +17 -0
- package/{test/config.js → 8/craba.js} +41 -29
- package/8/package.json +17 -0
- package/8/readme.md +20 -0
- package/8/www/_Sys/UI/Grid/GridConfig.gspx +27 -0
- package/8/www/_Sys/UI/Grid/GridConfig.js +652 -0
- package/8/www/_Sys/UI/IFrame.gspx +7 -0
- package/8/www/_Sys/UI/IFrame.js +57 -0
- package/8/www/_Sys/UI/PanelConfig.gspx +55 -0
- package/8/www/_Sys/UI/PanelConfig.js +268 -0
- package/8/www/_Sys/UI/Print/ClientSelector.gspx +39 -0
- package/8/www/_Sys/UI/Print/ClientSelector.js +152 -0
- package/8/www/js/agency.js +2 -0
- package/8/www/js/craba.min.js +12 -0
- package/8/www/js/crabaEx.min.js +7 -0
- package/8/www/js/crabaNgp.js +1 -0
- package/8/www/js/echarts-all.js +1 -0
- package/8/www/js/math.min.js +10 -0
- package/8/www/skins/craba.min.css +174 -0
- package/8/www/skins/font/iconfont.eot +0 -0
- package/8/www/skins/font/iconfont.svg +1281 -0
- package/8/www/skins/font/iconfont.ttf +0 -0
- package/8/www/skins/font/iconfont.woff +0 -0
- package/8/www/skins/ui/icons/backTop.gif +0 -0
- package/8/www/skins/ui/icons/blank.gif +0 -0
- package/8/www/skins/ui/icons/browsers.jpg +0 -0
- package/8/www/skins/ui/icons/grid.png +0 -0
- package/8/www/skins/ui/icons/nodata.png +0 -0
- package/8/www/skins/ui/print/new.png +0 -0
- package/8/www/skins/ui/print/old.png +0 -0
- package/8/www/skins/ui/print/settings.gif +0 -0
- package/8/www/skins/ui/tree/first.gif +0 -0
- package/8/www/skins/ui/tree/firstNo.gif +0 -0
- package/8/www/skins/ui/tree/last.gif +0 -0
- package/8/www/skins/ui/tree/line.gif +0 -0
- package/8/www/skins/ui/tree/node.gif +0 -0
- package/8/www/skins/ui/tree/node0.gif +0 -0
- package/8/www/skins/ui/tree/none.gif +0 -0
- package/index.js +71 -28
- package/lib/config.js +19 -2
- package/lib/server.js +12 -10
- package/lib/utils.js +99 -21
- package/package.json +5 -3
- package/test/ngp.js +38 -3
- package/test/readme.md +10 -10
- package/test/test.js +38 -0
- package/tool/checkjs.js +93 -0
- package/{client → tool}/client.js +2 -2
- package/{merge → tool}/merge.js +11 -11
- package/{lib → tool}/ngptool.js +26 -26
- package/tool/progressbar.js +10 -6
- package/{lib → tool}/sockettool.js +9 -10
- package/tool/upgrade.js +121 -39
|
@@ -0,0 +1 @@
|
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(window,function(t){"use strict";function e(t){var e={},n=t.match(/Firefox\/([\d.]+)/),i=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),r=t.match(/Edge\/([\d.]+)/),o=/micromessenger/i.test(t);return n&&(e.firefox=!0,e.version=n[1]),i&&(e.ie=!0,e.version=i[1]),r&&(e.edge=!0,e.version=r[1]),o&&(e.weChat=!0),{browser:e,os:{},node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!e.ie&&!e.edge,pointerEventsSupported:"onpointerdown"in window&&(e.edge||e.ie&&e.version>=11),domSupported:"undefined"!=typeof document}}function n(t,e){"createCanvas"===t&&(yc=null),mc[t]=e}function i(t){if(null==t||"object"!=typeof t)return t;var e=t,n=uc.call(t);if("[object Array]"===n){if(!N(t)){e=[];for(var r=0,o=t.length;o>r;r++)e[r]=i(t[r])}}else if(lc[n]){if(!N(t)){var a=t.constructor;if(t.constructor.from)e=a.from(t);else{e=new a(t.length);for(var r=0,o=t.length;o>r;r++)e[r]=i(t[r])}}}else if(!sc[n]&&!N(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(!b(e)||!b(t))return n?i(e):t;for(var o in e)if(e.hasOwnProperty(o)){var a=t[o],s=e[o];!b(s)||!b(a)||x(s)||x(a)||I(s)||I(a)||S(s)||S(a)||N(s)||N(a)?!n&&o in t||(t[o]=i(e[o])):r(a,s,n)}return t}function o(t,e){for(var n=t[0],i=1,o=t.length;o>i;i++)n=r(n,t[i],e);return n}function a(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 yc||(yc=vc().getContext("2d")),yc}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)i.hasOwnProperty(r)&&(t.prototype[r]=i[r]);t.prototype.constructor=t,t.superClass=e}function c(t,e,n){s(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,n)}function d(t){return t?"string"!=typeof t&&"number"==typeof t.length:void 0}function f(t,e,n){if(t&&e)if(t.forEach&&t.forEach===cc)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 o in t)t.hasOwnProperty(o)&&e.call(n,t[o],o,t)}function p(t,e,n){if(t&&e){if(t.map&&t.map===pc)return t.map(e,n);for(var i=[],r=0,o=t.length;o>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===gc)return t.reduce(e,n,i);for(var r=0,o=t.length;o>r;r++)n=e.call(i,n,t[r],r,t);return n}}function m(t,e,n){if(t&&e){if(t.filter&&t.filter===dc)return t.filter(e,n);for(var i=[],r=0,o=t.length;o>r;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function v(t,e){var n=fc.call(arguments,2);return function(){return t.apply(e,n.concat(fc.call(arguments)))}}function y(t){var e=fc.call(arguments,1);return function(){return t.apply(this,e.concat(fc.call(arguments)))}}function x(t){return"[object Array]"===uc.call(t)}function _(t){return"function"==typeof t}function w(t){return"[object String]"===uc.call(t)}function b(t){var e=typeof t;return"function"===e||!!t&&"object"===e}function S(t){return!!sc[uc.call(t)]}function M(t){return!!lc[uc.call(t)]}function I(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function C(t){return t!=t}function T(){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 D(t,e,n){return null!=t?t:null!=e?e:n}function k(){return Function.call.apply(fc,arguments)}function P(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 L(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}function z(t){t[xc]=!0}function N(t){return t[xc]}function E(t){function e(t,e){n?i.set(t,e):i.set(e,t)}var n=x(t);this.data={};var i=this;t instanceof E?t.each(e):t&&f(t,e)}function B(t){return new E(t)}function R(){}function F(t,e){var n=new wc(2);return null==t&&(t=0),null==e&&(e=0),n[0]=t,n[1]=e,n}function V(t,e){return t[0]=e[0],t[1]=e[1],t}function G(t){var e=new wc(2);return e[0]=t[0],e[1]=t[1],e}function W(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function H(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function Z(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function X(t){return Math.sqrt(Y(t))}function Y(t){return t[0]*t[0]+t[1]*t[1]}function U(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function j(t,e){var n=X(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function q(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}function $(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}function K(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 Q(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function J(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}function tt(){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 et(t,e){return{target:t,topTarget:e&&e.topTarget}}function nt(t,e,n,i,r,o){var a=t._$handlers;if("function"==typeof n&&(r=i,i=n,n=null),!i||!e)return t;n=function(t,e){var n=t._$eventProcessor;return null!=e&&n&&n.normalizeQuery&&(e=n.normalizeQuery(e)),e}(t,n),a[e]||(a[e]=[]);for(var s=0;s<a[e].length;s++)if(a[e][s].h===i)return t;var l={h:i,one:o,query:n,ctx:r||t,callAtLast:i.zrEventfulCallAtLast},u=a[e].length-1,h=a[e][u];return h&&h.callAtLast?a[e].splice(u,0,l):a[e].push(l),t}function it(t,e,n,i,r,o){var a=i+"-"+r,s=t.length;if(o.hasOwnProperty(a))return o[a];if(1===e){var l=Math.round(Math.log((1<<s)-1&~r)/Dc);return t[n][l]}for(var u=i|1<<n,h=n+1;i&1<<h;)h++;for(var c=0,d=0,f=0;s>d;d++){var p=1<<d;p&r||(c+=(f%2?-1:1)*t[n][d]*it(t,e-1,h,u,r|p,o),f++)}return o[a]=c,c}function rt(t,e,n,i){return n=n||{},i||!ac.canvasSupported?ot(t,e,n):ac.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):ot(t,e,n),n}function ot(t,e,n){if(t.getBoundingClientRect&&ac.domSupported){var i=e.clientX,r=e.clientY;if("CANVAS"===t.nodeName.toUpperCase()){var o=t.getBoundingClientRect();return n.zrX=i-o.left,void(n.zrY=r-o.top)}var a=t[Oc]||(t[Oc]={}),s=function(t,e){for(var n=e.transformer,i=e.srcCoords,r=!0,o=[],a=[],s=0;4>s;s++){var l=t[s].getBoundingClientRect(),u=2*s,h=l.left,c=l.top;o.push(h,c),r&=i&&h===i[u]&&c===i[u+1],a.push(t[s].offsetLeft,t[s].offsetTop)}return r?n:(e.srcCoords=o,e.transformer=function(t,e){var n=[[t[0],t[1],1,0,0,0,-e[0]*t[0],-e[0]*t[1]],[0,0,0,t[0],t[1],1,-e[1]*t[0],-e[1]*t[1]],[t[2],t[3],1,0,0,0,-e[2]*t[2],-e[2]*t[3]],[0,0,0,t[2],t[3],1,-e[3]*t[2],-e[3]*t[3]],[t[4],t[5],1,0,0,0,-e[4]*t[4],-e[4]*t[5]],[0,0,0,t[4],t[5],1,-e[5]*t[4],-e[5]*t[5]],[t[6],t[7],1,0,0,0,-e[6]*t[6],-e[6]*t[7]],[0,0,0,t[6],t[7],1,-e[7]*t[6],-e[7]*t[7]]],i={},r=it(n,8,0,0,0,i);if(0!==r){for(var o=[],a=0;8>a;a++)for(var s=0;8>s;s++)null==o[s]&&(o[s]=0),o[s]+=((a+s)%2?-1:1)*it(n,7,0===a?1:0,1<<a,1<<s,i)/r*e[a];return function(t,e,n){var i=e*o[6]+n*o[7]+1;t[0]=(e*o[0]+n*o[1]+o[2])/i,t[1]=(e*o[3]+n*o[4]+o[5])/i}}}(o,a))}(function(t,e){var n=e.markers;if(n)return n;n=e.markers=[];for(var i=["left","right"],r=["top","bottom"],o=0;4>o;o++){var a=document.createElement("div"),s=a.style,l=o%2,u=(o>>1)%2;s.cssText=["position:absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","width:0","height:0",i[l]+":0",r[u]+":0",i[1-l]+":auto",r[1-u]+":auto",""].join("!important;"),t.appendChild(a),n.push(a)}return n}(t,a),a);if(s)return s(Lc,i,r),n.zrX=Lc[0],void(n.zrY=Lc[1])}n.zrX=n.zrY=0}function at(t,e,n){if(null!=(e=e||window.event).zrX)return e;var i=e.type;if(i&&i.indexOf("touch")>=0){var r="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];r&&rt(t,r,e,n)}else rt(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&&Pc.test(e.type)&&(e.which=1&o?1:2&o?3:4&o?2:0),e}function st(t,e,n){kc?t.addEventListener(e,n):t.attachEvent("on"+e,n)}function lt(t,e,n){kc?t.removeEventListener(e,n):t.detachEvent("on"+e,n)}function ut(t){return 2===t.which||3===t.which}function ht(t){var e=t[1][0]-t[0][0],n=t[1][1]-t[0][1];return Math.sqrt(e*e+n*n)}function ct(){zc(this.event)}function dt(){}function ft(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||Bc}return!1}function pt(){var t=new Vc(6);return gt(t),t}function gt(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function mt(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 vt(t,e,n){var i=e[0]*n[0]+e[2]*n[1],r=e[1]*n[0]+e[3]*n[1],o=e[0]*n[2]+e[2]*n[3],a=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]=o,t[3]=a,t[4]=s,t[5]=l,t}function yt(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 xt(t,e,n){var i=e[0],r=e[2],o=e[4],a=e[1],s=e[3],l=e[5],u=Math.sin(n),h=Math.cos(n);return t[0]=i*h+a*u,t[1]=-i*u+a*h,t[2]=r*h+s*u,t[3]=-r*u+h*s,t[4]=h*o+u*l,t[5]=h*l-u*o,t}function _t(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 wt(t,e){var n=e[0],i=e[2],r=e[4],o=e[1],a=e[3],s=e[5],l=n*a-o*i;return l?(l=1/l,t[0]=a*l,t[1]=-o*l,t[2]=-i*l,t[3]=n*l,t[4]=(i*s-a*r)*l,t[5]=(o*r-n*s)*l,t):null}function bt(t){return t>Hc||-Hc>t}function St(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null!=t.loop&&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 Mt(t){return 0>(t=Math.round(t))?0:t>255?255:t}function It(t){return 0>t?0:t>1?1:t}function Ct(t){return Mt(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100*255:parseInt(t,10))}function Tt(t){return It(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100:parseFloat(t))}function At(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 Dt(t,e,n){return t+(e-t)*n}function kt(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Pt(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function Ot(t,e){id&&Pt(id,e),id=nd.put(t,id||e.slice())}function Lt(t,e){if(t){e=e||[];var n=nd.get(t);if(n)return Pt(e,n);var i=(t+="").replace(/ /g,"").toLowerCase();if(i in ed)return Pt(e,ed[i]),Ot(t,e),e;if("#"!==i.charAt(0)){var r=i.indexOf("("),o=i.indexOf(")");if(-1!==r&&o+1===i.length){var a=i.substr(0,r),s=i.substr(r+1,o-(r+1)).split(","),l=1;switch(a){case"rgba":if(4!==s.length)return void kt(e,0,0,0,1);l=Tt(s.pop());case"rgb":return 3!==s.length?void kt(e,0,0,0,1):(kt(e,Ct(s[0]),Ct(s[1]),Ct(s[2]),l),Ot(t,e),e);case"hsla":return 4!==s.length?void kt(e,0,0,0,1):(s[3]=Tt(s[3]),zt(s,e),Ot(t,e),e);case"hsl":return 3!==s.length?void kt(e,0,0,0,1):(zt(s,e),Ot(t,e),e);default:return}}kt(e,0,0,0,1)}else{if(4===i.length){return(u=parseInt(i.substr(1),16))>=0&&4095>=u?(kt(e,(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,1),Ot(t,e),e):void kt(e,0,0,0,1)}if(7===i.length){var u=parseInt(i.substr(1),16);return u>=0&&16777215>=u?(kt(e,(16711680&u)>>16,(65280&u)>>8,255&u,1),Ot(t,e),e):void kt(e,0,0,0,1)}}}}function zt(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=Tt(t[1]),r=Tt(t[2]),o=.5>=r?r*(i+1):r+i-r*i,a=2*r-o;return e=e||[],kt(e,Mt(255*At(a,o,n+1/3)),Mt(255*At(a,o,n)),Mt(255*At(a,o,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Nt(t,e){var n=Lt(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,n[i]>255?n[i]=255:t[i]<0&&(n[i]=0);return Vt(n,4===n.length?"rgba":"rgb")}}function Et(t){var e=Lt(t);return e?((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1):void 0}function Bt(t,e,n){if(e&&e.length&&t>=0&&1>=t){n=n||[];var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=e[r],s=e[o],l=i-r;return n[0]=Mt(Dt(a[0],s[0],l)),n[1]=Mt(Dt(a[1],s[1],l)),n[2]=Mt(Dt(a[2],s[2],l)),n[3]=It(Dt(a[3],s[3],l)),n}}function Rt(t,e,n){if(e&&e.length&&t>=0&&1>=t){var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=Lt(e[r]),s=Lt(e[o]),l=i-r,u=Vt([Mt(Dt(a[0],s[0],l)),Mt(Dt(a[1],s[1],l)),Mt(Dt(a[2],s[2],l)),It(Dt(a[3],s[3],l))],"rgba");return n?{color:u,leftIndex:r,rightIndex:o,value:i}:u}}function Ft(t,e){return(t=Lt(t))&&null!=e?(t[3]=It(e),Vt(t,"rgba")):void 0}function Vt(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 Gt(t,e,n){return(e-t)*n+t}function Wt(t,e,n){return n>.5?e:t}function Ht(t,e,n,i,r){var o=t.length;if(1===r)for(s=0;o>s;s++)i[s]=Gt(t[s],e[s],n);else for(var a=o&&t[0].length,s=0;o>s;s++)for(var l=0;a>l;l++)i[s][l]=Gt(t[s][l],e[s][l],n)}function Zt(t,e,n){var i=t.length,r=e.length;if(i!==r){if(i>r)t.length=r;else for(a=i;r>a;a++)t.push(1===n?e[a]:sd.call(e[a]))}for(var o=t[0]&&t[0].length,a=0;a<t.length;a++)if(1===n)isNaN(t[a])&&(t[a]=e[a]);else for(var s=0;o>s;s++)isNaN(t[a][s])&&(t[a][s]=e[a][s])}function Xt(t,e,n){if(t===e)return!0;var i=t.length;if(i!==e.length)return!1;if(1===n){for(o=0;i>o;o++)if(t[o]!==e[o])return!1}else for(var r=t[0].length,o=0;i>o;o++)for(var a=0;r>a;a++)if(t[o][a]!==e[o][a])return!1;return!0}function Yt(t,e,n,i,r,o,a,s,l){var u=t.length;if(1===l)for(c=0;u>c;c++)s[c]=Ut(t[c],e[c],n[c],i[c],r,o,a);else for(var h=t[0].length,c=0;u>c;c++)for(var d=0;h>d;d++)s[c][d]=Ut(t[c][d],e[c][d],n[c][d],i[c][d],r,o,a)}function Ut(t,e,n,i,r,o,a){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*a+(-3*(e-n)-2*s-l)*o+s*r+e}function jt(t){if(d(t)){var e=t.length;if(d(t[0])){for(var n=[],i=0;e>i;i++)n.push(sd.call(t[i]));return n}return sd.call(t)}return t}function qt(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function $t(t,e,n,i,r,o){var a=t._getter,s=t._setter,l="spline"===e,u=i.length;if(u){var h,c=d(i[0].value),f=!1,p=!1,g=c?function(t){var e=t[t.length-1].value;return d(e&&e[0])?2:1}(i):0;i.sort(function(t,e){return t.time-e.time}),h=i[u-1].time;for(var m=[],v=[],y=i[0].value,x=!0,_=0;u>_;_++){m.push(i[_].time/h);var w=i[_].value;if(c&&Xt(w,y,g)||!c&&w===y||(x=!1),y=w,"string"==typeof w){var b=Lt(w);b?(w=b,f=!0):p=!0}v.push(w)}if(o||!x){for(var S=v[u-1],_=0;u-1>_;_++)c?Zt(v[_],S,g):!isNaN(v[_])||isNaN(S)||p||f||(v[_]=S);c&&Zt(a(t._target,r),S,g);var M,I,C,T,A,D,k=0,P=0;if(f)var O=[0,0,0,0];var L=new St({target:t._target,life:h,loop:t._loop,delay:t._delay,onframe:function(t,e){var n;if(0>e)n=0;else if(P>e){for(n=M=Math.min(k+1,u-1);n>=0&&!(m[n]<=e);n--);n=Math.min(n,u-2)}else{for(n=k;u>n&&!(m[n]>e);n++);n=Math.min(n-1,u-2)}k=n,P=e;var i=m[n+1]-m[n];if(0!==i)if(I=(e-m[n])/i,l)if(T=v[n],C=v[0===n?n:n-1],A=v[n>u-2?u-1:n+1],D=v[n>u-3?u-1:n+2],c)Yt(C,T,A,D,I,I*I,I*I*I,a(t,r),g);else{if(f)o=Yt(C,T,A,D,I,I*I,I*I*I,O,1),o=qt(O);else{if(p)return Wt(T,A,I);o=Ut(C,T,A,D,I,I*I,I*I*I)}s(t,r,o)}else if(c)Ht(v[n],v[n+1],I,a(t,r),g);else{var o;if(f)Ht(v[n],v[n+1],I,O,1),o=qt(O);else{if(p)return Wt(v[n],v[n+1],I);o=Gt(v[n],v[n+1],I)}s(t,r,o)}},ondestroy:n});return e&&"spline"!==e&&(L.easing=e),L}}}function Kt(t,e,n,i,r,o,a,s){function l(){--h||o&&o()}w(i)?(o=r,r=i,i=0):_(r)?(o=r,r="linear",i=0):_(i)?(o=i,i=0):_(n)?(o=n,n=500):n||(n=500),t.stopAnimation(),Qt(t,"",t,e,n,i,s);var u=t.animators.slice(),h=u.length;h||o&&o();for(var c=0;c<u.length;c++)u[c].done(l).start(r,a)}function Qt(t,e,n,i,r,o,a){var s={},l=0;for(var u in i)i.hasOwnProperty(u)&&(null!=n[u]?b(i[u])&&!d(i[u])?Qt(t,e?e+"."+u:u,n[u],i[u],r,o,a):(a?(s[u]=n[u],Jt(t,e,u,i[u])):s[u]=i[u],l++):null==i[u]||a||Jt(t,e,u,i[u]));l>0&&t.animate(e,!1).when(null==r?500:r,s).delay(o||0)}function Jt(t,e,n,i){if(e){var r={};r[e]={},r[e][n]=i,t.attr(r)}else t.attr(n,i)}function te(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 ee(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++;!function(t,e,n){for(n--;n>e;){var i=t[e];t[e++]=t[n],t[n--]=i}}(t,e,r)}else for(;n>r&&i(t[r],t[r-1])>=0;)r++;return r-e}function ne(t,e,n,i,r){for(i===e&&i++;n>i;i++){for(var o,a=t[i],s=e,l=i;l>s;)o=s+l>>>1,r(a,t[o])<0?l=o:s=o+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]=a}}function ie(t,e,n,i,r,o){var a=0,s=0,l=1;if(o(t,e[n+r])>0){for(s=i-r;s>l&&o(t,e[n+r+l])>0;)a=l,0>=(l=1+(l<<1))&&(l=s);l>s&&(l=s),a+=r,l+=r}else{for(s=r+1;s>l&&o(t,e[n+r-l])<=0;)a=l,0>=(l=1+(l<<1))&&(l=s);l>s&&(l=s);var u=a;a=r-l,l=r-u}for(a++;l>a;){var h=a+(l-a>>>1);o(t,e[n+h])>0?a=h+1:l=h}return l}function re(t,e,n,i,r,o){var a=0,s=0,l=1;if(o(t,e[n+r])<0){for(s=r+1;s>l&&o(t,e[n+r-l])<0;)a=l,0>=(l=1+(l<<1))&&(l=s);l>s&&(l=s);var u=a;a=r-l,l=r-u}else{for(s=i-r;s>l&&o(t,e[n+r+l])>=0;)a=l,0>=(l=1+(l<<1))&&(l=s);l>s&&(l=s),a+=r,l+=r}for(a++;l>a;){var h=a+(l-a>>>1);o(t,e[n+h])<0?l=h:a=h+1}return l}function oe(t,e,n,i){n||(n=0),i||(i=t.length);var r=i-n;if(!(2>r)){var o=0;if(xd>r)return o=ee(t,n,i,e),void ne(t,n,i,n+o,e);var a=new function(t,e){function n(n){var s=o[n],u=a[n],h=o[n+1],c=a[n+1];a[n]=u+c,n===l-3&&(o[n+1]=o[n+2],a[n+1]=a[n+2]),l--;var d=re(t[h],t,s,u,0,e);s+=d,0!=(u-=d)&&0!==(c=ie(t[s+u-1],t,h,c,c-1,e))&&(c>=u?i(s,u,h,c):r(s,u,h,c))}function i(n,i,r,o){var a=0;for(a=0;i>a;a++)u[a]=t[n+a];var l=0,h=r,c=n;if(t[c++]=t[h++],0!=--o){if(1===i){for(a=0;o>a;a++)t[c+a]=t[h+a];return void(t[c+o]=u[l])}for(var d,f,p,g=s;;){d=0,f=0,p=!1;do{if(e(t[h],u[l])<0){if(t[c++]=t[h++],f++,d=0,0==--o){p=!0;break}}else if(t[c++]=u[l++],d++,f=0,1==--i){p=!0;break}}while(g>(d|f));if(p)break;do{if(0!==(d=re(t[h],u,l,i,0,e))){for(a=0;d>a;a++)t[c+a]=u[l+a];if(c+=d,l+=d,1>=(i-=d)){p=!0;break}}if(t[c++]=t[h++],0==--o){p=!0;break}if(0!==(f=ie(u[l],t,h,o,0,e))){for(a=0;f>a;a++)t[c+a]=t[h+a];if(c+=f,h+=f,0==(o-=f)){p=!0;break}}if(t[c++]=u[l++],1==--i){p=!0;break}g--}while(d>=_d||f>=_d);if(p)break;0>g&&(g=0),g+=2}if(1>(s=g)&&(s=1),1===i){for(a=0;o>a;a++)t[c+a]=t[h+a];t[c+o]=u[l]}else{if(0===i)throw new Error;for(a=0;i>a;a++)t[c+a]=u[l+a]}}else for(a=0;i>a;a++)t[c+a]=u[l+a]}function r(n,i,r,o){var a=0;for(a=0;o>a;a++)u[a]=t[r+a];var l=n+i-1,h=o-1,c=r+o-1,d=0,f=0;if(t[c--]=t[l--],0!=--i){if(1===o){for(f=1+(c-=i),d=1+(l-=i),a=i-1;a>=0;a--)t[f+a]=t[d+a];return void(t[c]=u[h])}for(var p=s;;){var g=0,m=0,v=!1;do{if(e(u[h],t[l])<0){if(t[c--]=t[l--],g++,m=0,0==--i){v=!0;break}}else if(t[c--]=u[h--],m++,g=0,1==--o){v=!0;break}}while(p>(g|m));if(v)break;do{if(0!=(g=i-re(u[h],t,n,i,i-1,e))){for(i-=g,f=1+(c-=g),d=1+(l-=g),a=g-1;a>=0;a--)t[f+a]=t[d+a];if(0===i){v=!0;break}}if(t[c--]=u[h--],1==--o){v=!0;break}if(0!=(m=o-ie(t[l],u,0,o,o-1,e))){for(o-=m,f=1+(c-=m),d=1+(h-=m),a=0;m>a;a++)t[f+a]=u[d+a];if(1>=o){v=!0;break}}if(t[c--]=t[l--],0==--i){v=!0;break}p--}while(g>=_d||m>=_d);if(v)break;0>p&&(p=0),p+=2}if(1>(s=p)&&(s=1),1===o){for(f=1+(c-=i),d=1+(l-=i),a=i-1;a>=0;a--)t[f+a]=t[d+a];t[c]=u[h]}else{if(0===o)throw new Error;for(d=c-(o-1),a=0;o>a;a++)t[d+a]=u[a]}}else for(d=c-(o-1),a=0;o>a;a++)t[d+a]=u[a]}var o,a,s=_d,l=0,u=[];o=[],a=[],this.mergeRuns=function(){for(;l>1;){var t=l-2;if(t>=1&&a[t-1]<=a[t]+a[t+1]||t>=2&&a[t-2]<=a[t]+a[t-1])a[t-1]<a[t+1]&&t--;else if(a[t]>a[t+1])break;n(t)}},this.forceMergeRuns=function(){for(;l>1;){var t=l-2;t>0&&a[t-1]<a[t+1]&&t--,n(t)}},this.pushRun=function(t,e){o[l]=t,a[l]=e,l+=1}}(t,e),s=function(t){for(var e=0;t>=xd;)e|=1&t,t>>=1;return t+e}(r);do{if(o=ee(t,n,i,e),s>o){var l=r;l>s&&(l=s),ne(t,n,n+l,n+o,e),o=l}a.pushRun(n,o),a.mergeRuns(),r-=o,n+=o}while(0!==r);a.forceMergeRuns()}}function ae(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function se(){return!1}function le(t,e,n){var i=vc(),r=e.getWidth(),o=e.getHeight(),a=i.style;return a&&(a.position="absolute",a.left=0,a.top=0,a.width=r+"px",a.height=o+"px",i.setAttribute("data-zr-dom-id",t)),i.width=r*n,i.height=o*n,i}function ue(t){if("string"==typeof t){var e=zd.get(t);return e&&e.image}return t}function he(t,e,n,i,r){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!n)return e;var o=zd.get(t),a={hostEl:n,cb:i,cbPayload:r};return o?(e=o.image,!de(e)&&o.pending.push(a)):(e=new Image,e.onload=e.onerror=ce,zd.put(t,e.__cachedImgObj={image:e,pending:[a]}),e.src=e.__zrImageSrc=t),e}return t}return e}function ce(){var t=this.__cachedImgObj;this.onload=this.onerror=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 de(t){return t&&t.width&&t.height}function fe(t,e){var n=t+":"+(e=e||Fd);if(Nd[n])return Nd[n];for(var i=(t+"").split("\n"),r=0,o=0,a=i.length;a>o;o++)r=Math.max(function(t,e){return Vd.measureText(t,e)}(i[o],e).width,r);return Ed>Bd&&(Ed=0,Nd={}),Ed++,Nd[n]=r,r}function pe(t,e,n,i,r,o,a,s){return a?function(t,e,n,i,r,o,a,s){var l=Se(t,{rich:a,truncate:s,font:e,textAlign:n,textPadding:r,textLineHeight:o}),u=l.outerWidth,h=l.outerHeight,c=ge(0,u,n),d=me(0,h,i);return new te(c,d,u,h)}(t,e,n,i,r,o,a,s):function(t,e,n,i,r,o,a){var s=be(t,e,r,o,a),l=fe(t,e);r&&(l+=r[1]+r[3]);var u=s.outerHeight,h=ge(0,l,n),c=me(0,u,i),d=new te(h,c,l,u);return d.lineHeight=s.lineHeight,d}(t,e,n,i,r,o,s)}function ge(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function me(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function ve(t,e,n){var i=e.textPosition,r=e.textDistance,o=n.x,a=n.y;r=r||0;var s=n.height,l=n.width,u=s/2,h="left",c="top";switch(i){case"left":o-=r,a+=u,h="right",c="middle";break;case"right":o+=r+l,a+=u,c="middle";break;case"top":o+=l/2,a-=r,h="center",c="bottom";break;case"bottom":o+=l/2,a+=s+r,h="center";break;case"inside":o+=l/2,a+=u,h="center",c="middle";break;case"insideLeft":o+=r,a+=u,c="middle";break;case"insideRight":o+=l-r,a+=u,h="right",c="middle";break;case"insideTop":o+=l/2,a+=r,h="center";break;case"insideBottom":o+=l/2,a+=s-r,h="center",c="bottom";break;case"insideTopLeft":o+=r,a+=r;break;case"insideTopRight":o+=l-r,a+=r,h="right";break;case"insideBottomLeft":o+=r,a+=s-r,c="bottom";break;case"insideBottomRight":o+=l-r,a+=s-r,h="right",c="bottom"}return t=t||{},t.x=o,t.y=a,t.textAlign=h,t.textVerticalAlign=c,t}function ye(t,e,n,i,r){if(!e)return"";var o=(t+"").split("\n");r=xe(e,n,i,r);for(var a=0,s=o.length;s>a;a++)o[a]=_e(o[a],r);return o.join("\n")}function xe(t,e,n,i){(i=a({},i)).font=e;n=A(n,"...");i.maxIterations=A(i.maxIterations,2);var r=i.minChar=A(i.minChar,0);i.cnCharWidth=fe("国",e);var o=i.ascCharWidth=fe("a",e);i.placeholder=A(i.placeholder,"");for(var s=t=Math.max(0,t-1),l=0;r>l&&s>=o;l++)s-=o;var u=fe(n,e);return u>s&&(n="",u=0),s=t-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=s,i.containerWidth=t,i}function _e(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var o=fe(t,i);if(n>=o)return t;for(var a=0;;a++){if(r>=o||a>=e.maxIterations){t+=e.ellipsis;break}var s=0===a?function(t,e,n,i){for(var r=0,o=0,a=t.length;a>o&&e>r;o++){var s=t.charCodeAt(o);r+=s>=0&&127>=s?n:i}return o}(t,r,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*r/o):0;o=fe(t=t.substr(0,s),i)}return""===t&&(t=e.placeholder),t}function we(t){return fe("国",t)}function be(t,e,n,i,r){null!=t&&(t+="");var o=A(i,we(e)),a=t?t.split("\n"):[],s=a.length*o,l=s,u=!0;if(n&&(l+=n[0]+n[2]),t&&r){u=!1;var h=r.outerHeight,c=r.outerWidth;if(null!=h&&l>h)t="",a=[];else if(null!=c)for(var d=xe(c-(n?n[1]+n[3]:0),e,r.ellipsis,{minChar:r.minChar,placeholder:r.placeholder}),f=0,p=a.length;p>f;f++)a[f]=_e(a[f],d)}return{lines:a,height:s,outerHeight:l,lineHeight:o,canCacheByTextString:u}}function Se(t,e){var n={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return n;for(var i,r=Rd.lastIndex=0;null!=(i=Rd.exec(t));){var o=i.index;o>r&&Me(n,t.substring(r,o)),Me(n,i[2],i[1]),r=Rd.lastIndex}r<t.length&&Me(n,t.substring(r,t.length));var a=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(k=0;k<a.length;k++){for(var p=a[k],g=0,m=0,v=0;v<p.tokens.length;v++){var y=(P=p.tokens[v]).styleName&&e.rich[P.styleName]||{},x=P.textPadding=y.textPadding,_=P.font=y.font||e.font,w=P.textHeight=A(y.textHeight,we(_));if(x&&(w+=x[0]+x[2]),P.height=w,P.lineHeight=D(y.textLineHeight,e.textLineHeight,w),P.textAlign=y&&y.textAlign||e.textAlign,P.textVerticalAlign=y&&y.textVerticalAlign||"middle",null!=f&&s+P.lineHeight>f)return{lines:[],width:0,height:0};P.textWidth=fe(P.text,_);var b=y.textWidth,S=null==b||"auto"===b;if("string"==typeof b&&"%"===b.charAt(b.length-1))P.percentWidth=b,u.push(P),b=0;else{if(S){b=P.textWidth;var M=y.textBackgroundColor,I=M&&M.image;I&&(I=ue(I),de(I)&&(b=Math.max(b,I.width*w/I.height)))}var C=x?x[1]+x[3]:0;b+=C;var T=null!=d?d-m:null;null!=T&&b>T&&(!S||C>T?(P.text="",P.textWidth=b=0):(P.text=ye(P.text,T-C,_,c.ellipsis,{minChar:c.minChar}),P.textWidth=fe(P.text,_),b=P.textWidth+C))}m+=P.width=b,y&&(g=Math.max(g,P.lineHeight))}p.width=m,p.lineHeight=g,s+=g,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 k=0;k<u.length;k++){var P=u[k],O=P.percentWidth;P.width=parseInt(O,10)/100*l}return n}function Me(t,e,n){for(var i=""===e,r=e.split("\n"),o=t.lines,a=0;a<r.length;a++){var s=r[a],l={styleName:n,text:s,isLineHolder:!s&&!i};if(a)o.push({tokens:[l]});else{var u=(o[o.length-1]||(o[0]={tokens:[]})).tokens,h=u.length;1===h&&u[0].isLineHolder?u[0]=l:(s||!h||i)&&u.push(l)}}}function Ie(t){var e=(t.fontSize||t.fontFamily)&&[t.fontStyle,t.fontWeight,(t.fontSize||12)+"px",t.fontFamily||"sans-serif"].join(" ");return e&&L(e)||t.textFont||t.font}function Ce(t,e){var n,i,r,o,a=e.x,s=e.y,l=e.width,u=e.height,h=e.r;0>l&&(a+=l,l=-l),0>u&&(s+=u,u=-u),"number"==typeof h?n=i=r=o=h:h instanceof Array?1===h.length?n=i=r=o=h[0]:2===h.length?(n=r=h[0],i=o=h[1]):3===h.length?(n=h[0],i=o=h[1],r=h[2]):(n=h[0],i=h[1],r=h[2],o=h[3]):n=i=r=o=0;var c;n+i>l&&(c=n+i,n*=l/c,i*=l/c),r+o>l&&(c=r+o,r*=l/c,o*=l/c),i+r>u&&(c=i+r,i*=u/c,r*=u/c),n+o>u&&(c=n+o,n*=u/c,o*=u/c),t.moveTo(a+n,s),t.lineTo(a+l-i,s),0!==i&&t.arc(a+l-i,s+i,i,-Math.PI/2,0),t.lineTo(a+l,s+u-r),0!==r&&t.arc(a+l-r,s+u-r,r,0,Math.PI/2),t.lineTo(a+o,s+u),0!==o&&t.arc(a+o,s+u-o,o,Math.PI/2,Math.PI),t.lineTo(a,s+n),0!==n&&t.arc(a+n,s+n,n,Math.PI,1.5*Math.PI)}function Te(t){return Ae(t),f(t.rich,Ae),t}function Ae(t){if(t){t.font=Ie(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||Wd[e]?e:"left";var n=t.textVerticalAlign||t.textBaseline;"center"===n&&(n="middle"),t.textVerticalAlign=null==n||Hd[n]?n:"top";t.textPadding&&(t.textPadding=P(t.textPadding))}}function De(t,e,n,i,r,o){i.rich?function(t,e,n,i,r,o){o!==Id&&(e.__attrCachedBy=Md.NONE);var a=t.__textCotentBlock;(!a||t.__dirtyText)&&(a=t.__textCotentBlock=Se(n,i)),function(t,e,n,i,r){var o=n.width,a=n.outerWidth,s=n.outerHeight,l=i.textPadding,u=Ne(Yd,t,i,r),h=u.baseX,c=u.baseY,d=u.textAlign,f=u.textVerticalAlign;ke(e,i,r,h,c);var p=ge(h,a,d),g=me(c,s,f),m=p,v=g;l&&(m+=l[3],v+=l[0]);var y=m+o;Oe(i)&&Le(t,e,i,p,g,a,s);for(var x=0;x<n.lines.length;x++){for(var _,w=n.lines[x],b=w.tokens,S=b.length,M=w.lineHeight,I=w.width,C=0,T=m,A=y,D=S-1;S>C&&(!(_=b[C]).textAlign||"left"===_.textAlign);)Pe(t,e,_,i,M,v,T,"left"),I-=_.width,T+=_.width,C++;for(;D>=0&&"right"===(_=b[D]).textAlign;)Pe(t,e,_,i,M,v,A,"right"),I-=_.width,A-=_.width,D--;for(T+=(o-(T-m)-(y-A)-I)/2;D>=C;)_=b[C],Pe(t,e,_,i,M,v,T+_.width/2,"center"),T+=_.width,C++;v+=M}}(t,e,a,i,r)}(t,e,n,i,r,o):function(t,e,n,i,r,o){var a,s=Oe(i),l=!1,u=e.__attrCachedBy===Md.PLAIN_TEXT;o!==Id?(o&&(a=o.style,l=!s&&u&&a),e.__attrCachedBy=s?Md.NONE:Md.PLAIN_TEXT):u&&(e.__attrCachedBy=Md.NONE);var h=i.font||Gd;l&&h===(a.font||Gd)||(e.font=h);var c=t.__computedFont;t.__styleFont!==h&&(t.__styleFont=h,c=t.__computedFont=e.font);var d=i.textPadding,f=i.textLineHeight,p=t.__textCotentBlock;(!p||t.__dirtyText)&&(p=t.__textCotentBlock=be(n,c,d,f,i.truncate));var g=p.outerHeight,m=p.lines,v=p.lineHeight,y=Ne(Yd,t,i,r),x=y.baseX,_=y.baseY,w=y.textAlign||"left",b=y.textVerticalAlign;ke(e,i,r,x,_);var S=me(_,g,b),M=x,I=S;if(s||d){var C=fe(n,c);d&&(C+=d[1]+d[3]);var T=ge(x,C,w);s&&Le(t,e,i,T,S,C,g),d&&(M=Ve(x,w,d),I+=d[0])}e.textAlign=w,e.textBaseline="middle",e.globalAlpha=i.opacity||1;for(R=0;R<Zd.length;R++){var A=Zd[R],D=A[0],k=A[1],P=i[D];l&&P===a[D]||(e[k]=Sd(e,k,P||A[2]))}I+=v/2;var O=i.textStrokeWidth,L=l?a.textStrokeWidth:null,z=!l||O!==L,N=!l||z||i.textStroke!==a.textStroke,E=Be(i.textStroke,O),B=Re(i.textFill);if(E&&(z&&(e.lineWidth=O),N&&(e.strokeStyle=E)),B&&(l&&i.textFill===a.textFill||(e.fillStyle=B)),1===m.length)E&&e.strokeText(m[0],M,I),B&&e.fillText(m[0],M,I);else for(var R=0;R<m.length;R++)E&&e.strokeText(m[R],M,I),B&&e.fillText(m[R],M,I),I+=v}(t,e,n,i,r,o)}function ke(t,e,n,i,r){if(n&&e.textRotation){var o=e.textOrigin;"center"===o?(i=n.width/2+n.x,r=n.height/2+n.y):o&&(i=o[0]+n.x,r=o[1]+n.y),t.translate(i,r),t.rotate(-e.textRotation),t.translate(-i,-r)}}function Pe(t,e,n,i,r,o,a,s){var l=i.rich[n.styleName]||{};l.text=n.text;var u=n.textVerticalAlign,h=o+r/2;"top"===u?h=o+n.height/2:"bottom"===u&&(h=o+r-n.height/2),!n.isLineHolder&&Oe(l)&&Le(t,e,l,"right"===s?a-n.width:"center"===s?a-n.width/2:a,h-n.height/2,n.width,n.height);var c=n.textPadding;c&&(a=Ve(a,s,c),h-=n.height/2-c[2]-n.textHeight/2),Ee(e,"shadowBlur",D(l.textShadowBlur,i.textShadowBlur,0)),Ee(e,"shadowColor",l.textShadowColor||i.textShadowColor||"transparent"),Ee(e,"shadowOffsetX",D(l.textShadowOffsetX,i.textShadowOffsetX,0)),Ee(e,"shadowOffsetY",D(l.textShadowOffsetY,i.textShadowOffsetY,0)),Ee(e,"textAlign",s),Ee(e,"textBaseline","middle"),Ee(e,"font",n.font||Gd);var d=Be(l.textStroke||i.textStroke,p),f=Re(l.textFill||i.textFill),p=A(l.textStrokeWidth,i.textStrokeWidth);d&&(Ee(e,"lineWidth",p),Ee(e,"strokeStyle",d),e.strokeText(n.text,a,h)),f&&(Ee(e,"fillStyle",f),e.fillText(n.text,a,h))}function Oe(t){return!!(t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor)}function Le(t,e,n,i,r,o,a){var s=n.textBackgroundColor,l=n.textBorderWidth,u=n.textBorderColor,h=w(s);if(Ee(e,"shadowBlur",n.textBoxShadowBlur||0),Ee(e,"shadowColor",n.textBoxShadowColor||"transparent"),Ee(e,"shadowOffsetX",n.textBoxShadowOffsetX||0),Ee(e,"shadowOffsetY",n.textBoxShadowOffsetY||0),h||l&&u){e.beginPath();var c=n.textBorderRadius;c?Ce(e,{x:i,y:r,width:o,height:a,r:c}):e.rect(i,r,o,a),e.closePath()}if(h)if(Ee(e,"fillStyle",s),null!=n.fillOpacity){f=e.globalAlpha;e.globalAlpha=n.fillOpacity*n.opacity,e.fill(),e.globalAlpha=f}else e.fill();else if(b(s)){var d=s.image;(d=he(d,null,t,ze,s))&&de(d)&&e.drawImage(d,i,r,o,a)}if(l&&u)if(Ee(e,"lineWidth",l),Ee(e,"strokeStyle",u),null!=n.strokeOpacity){var f=e.globalAlpha;e.globalAlpha=n.strokeOpacity*n.opacity,e.stroke(),e.globalAlpha=f}else e.stroke()}function ze(t,e){e.image=t}function Ne(t,e,n,i){var r=n.x||0,o=n.y||0,a=n.textAlign,s=n.textVerticalAlign;if(i){var l=n.textPosition;if(l instanceof Array)r=i.x+Fe(l[0],i.width),o=i.y+Fe(l[1],i.height);else{var u=e&&e.calculateTextPosition?e.calculateTextPosition(Xd,n,i):ve(Xd,n,i);r=u.x,o=u.y,a=a||u.textAlign,s=s||u.textVerticalAlign}var h=n.textOffset;h&&(r+=h[0],o+=h[1])}return t=t||{},t.baseX=r,t.baseY=o,t.textAlign=a,t.textVerticalAlign=s,t}function Ee(t,e,n){return t[e]=Sd(t,e,n),t[e]}function Be(t,e){return null==t||0>=e||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function Re(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function Fe(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function Ve(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function Ge(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function We(t){t=t||{},pd.call(this,t);for(var e in t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new Td(t.style,this),this._rect=null,this.__clipPaths=null}function He(t){We.call(this,t)}function Ze(t){return parseInt(t,10)}function Xe(t){return"mousewheel"===t&&ac.browser.firefox?"DOMMouseScroll":t}function Ye(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}function Ue(t){var e=t.pointerType;return"pen"===e||"touch"===e}function je(t){function e(e,n){f(e,function(e){st(t,Xe(e),n._handlers[e])},n)}Ac.call(this),this.dom=t,this._touching=!1,this._touchTimer,this._handlers={},function(t){f(ef,function(e){t._handlers[e]=v(of[e],t)}),f(rf,function(e){t._handlers[e]=v(of[e],t)}),f(tf,function(e){t._handlers[e]=function(t,e){return function(){return e._touching?void 0:t.apply(e,arguments)}}(of[e],t)})}(this),ac.pointerEventsSupported?e(rf,this):(ac.touchEventsSupported&&e(ef,this),e(tf,this))}function qe(t,e){var n=new hf(rc(),t,e);return uf[n.id]=n,n}function $e(t){return t instanceof Array?t:null==t?[]:[t]}function Ke(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 o=n[i];!t.emphasis[e].hasOwnProperty(o)&&t[e].hasOwnProperty(o)&&(t.emphasis[e][o]=t[e][o])}}}function Qe(t){return!ff(t)||pf(t)||t instanceof Date?t:t.value}function Je(t,e){e=(e||[]).slice();var n=p(t||[],function(t){return{exist:t}});return df(e,function(t,i){if(ff(t)){for(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 o=n[r].exist;if(!(n[r].option||null!=o.id&&null!=t.id||null==t.name||nn(t)||nn(o)||o.name!==t.name+""))return n[r].option=t,void(e[i]=null)}}}),df(e,function(t){if(ff(t)){for(var e=0;e<n.length;e++){var i=n[e].exist;if(!n[e].option&&!nn(i)&&null==t.id){n[e].option=t;break}}e>=n.length&&n.push({option:t})}}),n}function tn(t){var e=B();df(t,function(t){var n=t.exist;n&&e.set(n.id,t)}),df(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={})}),df(t,function(t,n){var i=t.exist,r=t.option,o=t.keyInfo;if(ff(r)){if(o.name=null!=r.name?r.name+"":i?i.name:gf+n,i)o.id=i.id;else if(null!=r.id)o.id=r.id+"";else{var a=0;do{o.id="\0"+o.name+"\0"+a++}while(e.get(o.id))}e.set(o.id,t)}})}function en(t){var e=t.name;return!(!e||!e.indexOf(gf))}function nn(t){return ff(t)&&t.id&&0===(t.id+"").indexOf("\0_ec_\0")}function rn(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 on(){var t="__\0ec_inner_"+vf+++"_"+Math.random().toFixed(5);return function(e){return e[t]||(e[t]={})}}function an(t,e,n){if(w(e)){var i={};i[e+"Index"]=0,e=i}var r=n&&n.defaultMainType;!r||sn(e,r+"Index")||sn(e,r+"Id")||sn(e,r+"Name")||(e[r+"Index"]=0);var o={};return df(e,function(i,r){i=e[r];if("dataIndex"!==r&&"dataIndexInside"!==r){var a=r.match(/^(\w+)(Index|Id|Name)$/)||[],s=a[1],l=(a[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);o[s+"Models"]=c,o[s+"Model"]=c[0]}}else o[r]=i}),o}function sn(t,e){return t&&t.hasOwnProperty(e)}function ln(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function un(t){return"auto"===t?ac.domSupported?"html":"richText":t||"html"}function hn(t){var e={main:"",sub:""};return t&&(t=t.split(yf),e.main=t[0]||"",e.sub=t[1]||""),e}function cn(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 a(n.prototype,t),n.extend=this.extend,n.superCall=fn,n.superApply=pn,h(n,this),n.superClass=e,n}}function dn(t){var e=["__\0is_clz",_f++,Math.random().toFixed(3)].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function fn(t,e){var n=k(arguments,2);return this.superClass.prototype[e].apply(t,n)}function pn(t,e,n){return this.superClass.prototype[e].apply(t,n)}function gn(t,e){e=e||{};var n={};if(t.registerClass=function(t,e){if(e)if(function(t){O(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}(e),(e=hn(e)).sub){if(e.sub!==xf){((function(t){var e=n[t.main];return e&&e[xf]||(e=n[t.main]={},e[xf]=!0),e})(e))[e.sub]=t}}else n[e.main]=t;return t},t.getClass=function(t,e,i){var r=n[t];if(r&&r[xf]&&(r=e?r[e]:null),i&&!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=hn(t);var e=[],i=n[t.main];return i&&i[xf]?f(i,function(t,n){n!==xf&&e.push(t)}):e.push(i),e},t.hasClass=function(t){return t=hn(t),!!n[t.main]},t.getAllClassMainTypes=function(){var t=[];return f(n,function(e,n){t.push(n)}),t},t.hasSubTypes=function(t){t=hn(t);var e=n[t.main];return e&&e[xf]},t.parseClassType=hn,e.registerWhenExtend){var i=t.extend;i&&(t.extend=function(e){var n=i.call(this,e);return t.registerClass(n,e.type)})}return t}function mn(t){return t>-Af&&Af>t}function vn(t){return t>Af||-Af>t}function yn(t,e,n,i,r){var o=1-r;return o*o*(o*t+3*r*e)+r*r*(r*i+3*o*n)}function xn(t,e,n,i,r){var o=1-r;return 3*(((e-t)*o+2*(n-e)*r)*o+(i-n)*r*r)}function _n(t,e,n,i,r,o){var a=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),u=t-r,h=s*s-3*a*l,c=s*l-9*a*u,d=l*l-3*s*u,f=0;if(mn(h)&&mn(c))if(mn(s))o[0]=0;else{(M=-l/s)>=0&&1>=M&&(o[f++]=M)}else{var p=c*c-4*h*d;if(mn(p)){var g=c/h,m=-g/2;(M=-s/a+g)>=0&&1>=M&&(o[f++]=M),m>=0&&1>=m&&(o[f++]=m)}else if(p>0){var v=Tf(p),y=h*s+1.5*a*(-c+v),x=h*s+1.5*a*(-c-v);(M=(-s-((y=0>y?-Cf(-y,Pf):Cf(y,Pf))+(x=0>x?-Cf(-x,Pf):Cf(x,Pf))))/(3*a))>=0&&1>=M&&(o[f++]=M)}else{var _=(2*h*s-3*a*c)/(2*Tf(h*h*h)),w=Math.acos(_)/3,b=Tf(h),S=Math.cos(w),M=(-s-2*b*S)/(3*a),m=(-s+b*(S+kf*Math.sin(w)))/(3*a),I=(-s+b*(S-kf*Math.sin(w)))/(3*a);M>=0&&1>=M&&(o[f++]=M),m>=0&&1>=m&&(o[f++]=m),I>=0&&1>=I&&(o[f++]=I)}}return f}function wn(t,e,n,i,r){var o=6*n-12*e+6*t,a=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(mn(a)){if(vn(o)){(c=-s/o)>=0&&1>=c&&(r[l++]=c)}}else{var u=o*o-4*a*s;if(mn(u))r[0]=-o/(2*a);else if(u>0){var h=Tf(u),c=(-o+h)/(2*a),d=(-o-h)/(2*a);c>=0&&1>=c&&(r[l++]=c),d>=0&&1>=d&&(r[l++]=d)}}return l}function bn(t,e,n,i,r,o){var a=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,u=(s-a)*r+a,h=(l-s)*r+s,c=(h-u)*r+u;o[0]=t,o[1]=a,o[2]=u,o[3]=c,o[4]=c,o[5]=h,o[6]=l,o[7]=i}function Sn(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function Mn(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function In(t,e,n,i,r){var o=t-2*e+n,a=2*(e-t),s=t-i,l=0;if(mn(o)){if(vn(a)){(c=-s/a)>=0&&1>=c&&(r[l++]=c)}}else{var u=a*a-4*o*s;if(mn(u)){(c=-a/(2*o))>=0&&1>=c&&(r[l++]=c)}else if(u>0){var h=Tf(u),c=(-a+h)/(2*o),d=(-a-h)/(2*o);c>=0&&1>=c&&(r[l++]=c),d>=0&&1>=d&&(r[l++]=d)}}return l}function Cn(t,e,n){var i=t+n-2*e;return 0===i?.5:(t-e)/i}function Tn(t,e,n,i,r){var o=(e-t)*i+t,a=(n-e)*i+e,s=(a-o)*i+o;r[0]=t,r[1]=o,r[2]=s,r[3]=s,r[4]=a,r[5]=n}function An(t,e,n,i,r,o,a,s,l){var u,h=.005,c=1/0;Of[0]=a,Of[1]=s;for(var d=0;1>d;d+=.05){Lf[0]=Sn(t,n,r,d),Lf[1]=Sn(e,i,o,d);c>(m=Ic(Of,Lf))&&(u=d,c=m)}c=1/0;for(var f=0;32>f&&!(Df>h);f++){var p=u-h,g=u+h;Lf[0]=Sn(t,n,r,p),Lf[1]=Sn(e,i,o,p);var m=Ic(Lf,Of);if(p>=0&&c>m)u=p,c=m;else{zf[0]=Sn(t,n,r,g),zf[1]=Sn(e,i,o,g);var v=Ic(zf,Of);1>=g&&c>v?(u=g,c=v):h*=.5}}return l&&(l[0]=Sn(t,n,r,u),l[1]=Sn(e,i,o,u)),Tf(c)}function Dn(t,e,n){if(0!==t.length){var i,r=t[0],o=r[0],a=r[0],s=r[1],l=r[1];for(i=1;i<t.length;i++)r=t[i],o=Nf(o,r[0]),a=Ef(a,r[0]),s=Nf(s,r[1]),l=Ef(l,r[1]);e[0]=o,e[1]=s,n[0]=a,n[1]=l}}function kn(t,e,n,i,r,o){r[0]=Nf(t,n),r[1]=Nf(e,i),o[0]=Ef(t,n),o[1]=Ef(e,i)}function Pn(t,e,n,i,r,o,a,s,l,u){var h,c=wn,d=yn,f=c(t,n,r,a,Hf);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,a,Hf[h]);l[0]=Nf(p,l[0]),u[0]=Ef(p,u[0])}for(f=c(e,i,o,s,Zf),h=0;f>h;h++){var g=d(e,i,o,s,Zf[h]);l[1]=Nf(g,l[1]),u[1]=Ef(g,u[1])}l[0]=Nf(t,l[0]),u[0]=Ef(t,u[0]),l[0]=Nf(a,l[0]),u[0]=Ef(a,u[0]),l[1]=Nf(e,l[1]),u[1]=Ef(e,u[1]),l[1]=Nf(s,l[1]),u[1]=Ef(s,u[1])}function On(t,e,n,i,r,o,a,s){var l=Cn,u=Sn,h=Ef(Nf(l(t,n,r),1),0),c=Ef(Nf(l(e,i,o),1),0),d=u(t,n,r,h),f=u(e,i,o,c);a[0]=Nf(t,r,d),a[1]=Nf(e,o,f),s[0]=Ef(t,r,d),s[1]=Ef(e,o,f)}function Ln(t,e,n,i,r,o,a,s,l){var u=Q,h=J,c=Math.abs(r-o);if(1e-4>c%Ff&&c>1e-4)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(Vf[0]=Rf(r)*n+t,Vf[1]=Bf(r)*i+e,Gf[0]=Rf(o)*n+t,Gf[1]=Bf(o)*i+e,u(s,Vf,Gf),h(l,Vf,Gf),0>(r%=Ff)&&(r+=Ff),0>(o%=Ff)&&(o+=Ff),r>o&&!a?o+=Ff:o>r&&a&&(r+=Ff),a){var d=o;o=r,r=d}for(var f=0;o>f;f+=Math.PI/2)f>r&&(Wf[0]=Rf(f)*n+t,Wf[1]=Bf(f)*i+e,u(s,Wf,s),h(l,Wf,l))}function zn(t,e,n,i,r,o,a){if(0===r)return!1;var s=r,l=0,u=t;if(a>e+s&&a>i+s||e-s>a&&i-s>a||o>t+s&&o>n+s||t-s>o&&n-s>o)return!1;if(t===n)return Math.abs(o-t)<=s/2;var h=(l=(e-i)/(t-n))*o-a+(u=(t*i-n*e)/(t-n));return s/2*s/2>=h*h/(l*l+1)}function Nn(t,e,n,i,r,o,a,s,l,u,h){if(0===l)return!1;var c=l;if(h>e+c&&h>i+c&&h>o+c&&h>s+c||e-c>h&&i-c>h&&o-c>h&&s-c>h||u>t+c&&u>n+c&&u>r+c&&u>a+c||t-c>u&&n-c>u&&r-c>u&&a-c>u)return!1;var d=function(t,e,n,i,r,o,a,s,l,u,h){var c,d,f,p,g,m=.005,v=1/0;Of[0]=l,Of[1]=u;for(var y=0;1>y;y+=.05)Lf[0]=yn(t,n,r,a,y),Lf[1]=yn(e,i,o,s,y),p=Ic(Of,Lf),v>p&&(c=y,v=p);v=1/0;for(var x=0;32>x&&!(Df>m);x++)d=c-m,f=c+m,Lf[0]=yn(t,n,r,a,d),Lf[1]=yn(e,i,o,s,d),p=Ic(Lf,Of),d>=0&&v>p?(c=d,v=p):(zf[0]=yn(t,n,r,a,f),zf[1]=yn(e,i,o,s,f),g=Ic(zf,Of),1>=f&&v>g?(c=f,v=g):m*=.5);return h&&(h[0]=yn(t,n,r,a,c),h[1]=yn(e,i,o,s,c)),Tf(v)}(t,e,n,i,r,o,a,s,u,h,null);return c/2>=d}function En(t,e,n,i,r,o,a,s,l){if(0===a)return!1;var u=a;if(l>e+u&&l>i+u&&l>o+u||e-u>l&&i-u>l&&o-u>l||s>t+u&&s>n+u&&s>r+u||t-u>s&&n-u>s&&r-u>s)return!1;return u/2>=An(t,e,n,i,r,o,s,l,null)}function Bn(t){return 0>(t%=rp)&&(t+=rp),t}function Rn(t,e,n,i,r,o,a,s,l){if(0===a)return!1;var u=a;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)%op<1e-4)return!0;if(o){var c=i;i=Bn(r),r=Bn(c)}else i=Bn(i),r=Bn(r);i>r&&(r+=op);var d=Math.atan2(l,s);return 0>d&&(d+=op),d>=i&&r>=d||d+op>=i&&r>=d+op}function Fn(t,e,n,i,r,o){if(o>e&&o>i||e>o&&i>o)return 0;if(i===e)return 0;var a=e>i?1:-1,s=(o-e)/(i-e);(1===s||0===s)&&(a=e>i?.5:-.5);var l=s*(n-t)+t;return l===r?1/0:l>r?a:0}function Vn(){var t=hp[0];hp[0]=hp[1],hp[1]=t}function Gn(t,e,n,i,r,o,a,s,l,u){if(u>e&&u>i&&u>o&&u>s||e>u&&i>u&&o>u&&s>u)return 0;var h=_n(e,i,o,s,u,up);if(0===h)return 0;for(var c,d,f=0,p=-1,g=0;h>g;g++){var m=up[g],v=0===m||1===m?.5:1;l>yn(t,n,r,a,m)||(0>p&&(p=wn(e,i,o,s,hp),hp[1]<hp[0]&&p>1&&Vn(),c=yn(e,i,o,s,hp[0]),p>1&&(d=yn(e,i,o,s,hp[1]))),f+=2===p?m<hp[0]?e>c?v:-v:m<hp[1]?c>d?v:-v:d>s?v:-v:m<hp[0]?e>c?v:-v:c>s?v:-v)}return f}function Wn(t,e,n,i,r,o,a,s){if(s>e&&s>i&&s>o||e>s&&i>s&&o>s)return 0;var l=In(e,i,o,s,up);if(0===l)return 0;var u=Cn(e,i,o);if(u>=0&&1>=u){for(var h=0,c=Sn(e,i,o,u),d=0;l>d;d++){f=0===up[d]||1===up[d]?.5:1;a>(p=Sn(t,n,r,up[d]))||(h+=up[d]<u?e>c?f:-f:c>o?f:-f)}return h}var f=0===up[0]||1===up[0]?.5:1,p=Sn(t,n,r,up[0]);return a>p?0:e>o?f:-f}function Hn(t,e,n,i,r,o,a,s){if((s-=e)>n||-n>s)return 0;u=Math.sqrt(n*n-s*s);up[0]=-u,up[1]=u;var l=Math.abs(i-r);if(1e-4>l)return 0;if(1e-4>l%sp){i=0,r=sp;p=o?1:-1;return a>=up[0]+t&&a<=up[1]+t?p:0}if(o){var u=i;i=Bn(r),r=Bn(u)}else i=Bn(i),r=Bn(r);i>r&&(r+=sp);for(var h=0,c=0;2>c;c++){var d=up[c];if(d+t>a){var f=Math.atan2(s,d),p=o?1:-1;0>f&&(f=sp+f),(f>=i&&r>=f||f+sp>=i&&r>=f+sp)&&(f>Math.PI/2&&f<1.5*Math.PI&&(p=-p),h+=p)}}return h}function Zn(t,e,n,i,r){for(var o=0,a=0,s=0,l=0,u=0,h=0;h<t.length;){var c=t[h++];switch(c===ap.M&&h>1&&(n||(o+=Fn(a,s,l,u,i,r))),1===h&&(a=t[h],s=t[h+1],l=a,u=s),c){case ap.M:a=l=t[h++],s=u=t[h++];break;case ap.L:if(n){if(zn(a,s,t[h],t[h+1],e,i,r))return!0}else o+=Fn(a,s,t[h],t[h+1],i,r)||0;a=t[h++],s=t[h++];break;case ap.C:if(n){if(Nn(a,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],e,i,r))return!0}else o+=Gn(a,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],i,r)||0;a=t[h++],s=t[h++];break;case ap.Q:if(n){if(En(a,s,t[h++],t[h++],t[h],t[h+1],e,i,r))return!0}else o+=Wn(a,s,t[h++],t[h++],t[h],t[h+1],i,r)||0;a=t[h++],s=t[h++];break;case ap.A:var d=t[h++],f=t[h++],p=t[h++],g=t[h++],m=t[h++],v=t[h++];h+=1;var y=1-t[h++],x=Math.cos(m)*p+d,_=Math.sin(m)*g+f;h>1?o+=Fn(a,s,x,_,i,r):(l=x,u=_);var w=(i-d)*g/p+d;if(n){if(Rn(d,f,g,m,m+v,y,e,w,r))return!0}else o+=Hn(d,f,g,m,m+v,y,w,r);a=Math.cos(m+v)*p+d,s=Math.sin(m+v)*g+f;break;case ap.R:l=a=t[h++],u=s=t[h++];var x=l+t[h++],_=u+t[h++];if(n){if(zn(l,u,x,u,e,i,r)||zn(x,u,x,_,e,i,r)||zn(x,_,l,_,e,i,r)||zn(l,_,l,u,e,i,r))return!0}else o+=Fn(x,u,x,_,i,r),o+=Fn(l,_,l,u,i,r);break;case ap.Z:if(n){if(zn(a,s,l,u,e,i,r))return!0}else o+=Fn(a,s,l,u,i,r);a=l,s=u}}return n||function(t,e){return Math.abs(t-e)<lp}(s,u)||(o+=Fn(a,s,l,u,i,r)||0),0!==o}function Xn(t){We.call(this,t),this.path=null}function Yn(t,e,n,i,r,o,a,s,l,u,h){var c=l*(bp/180),d=wp(c)*(t-n)/2+_p(c)*(e-i)/2,f=-1*_p(c)*(t-n)/2+wp(c)*(e-i)/2,p=d*d/(a*a)+f*f/(s*s);p>1&&(a*=xp(p),s*=xp(p));var g=(r===o?-1:1)*xp((a*a*s*s-a*a*f*f-s*s*d*d)/(a*a*f*f+s*s*d*d))||0,m=g*a*f/s,v=g*-s*d/a,y=(t+n)/2+wp(c)*m-_p(c)*v,x=(e+i)/2+_p(c)*m+wp(c)*v,_=Ip([1,0],[(d-m)/a,(f-v)/s]),w=[(d-m)/a,(f-v)/s],b=[(-1*d-m)/a,(-1*f-v)/s],S=Ip(w,b);Mp(w,b)<=-1&&(S=bp),Mp(w,b)>=1&&(S=0),0===o&&S>0&&(S-=2*bp),1===o&&0>S&&(S+=2*bp),h.addData(u,y,x,a,s,_,S,c,o)}function Un(t,e){var n=function(t){if(!t)return new ip;for(var e,n=0,i=0,r=n,o=i,a=new ip,s=ip.CMD,l=t.match(Cp),u=0;u<l.length;u++){for(var h,c=l[u],d=c.charAt(0),f=c.match(Tp)||[],p=f.length,g=0;p>g;g++)f[g]=parseFloat(f[g]);for(var m=0;p>m;){var v,y,x,_,w,b,S,M=n,I=i;switch(d){case"l":n+=f[m++],i+=f[m++],h=s.L,a.addData(h,n,i);break;case"L":n=f[m++],i=f[m++],h=s.L,a.addData(h,n,i);break;case"m":n+=f[m++],i+=f[m++],h=s.M,a.addData(h,n,i),r=n,o=i,d="l";break;case"M":n=f[m++],i=f[m++],h=s.M,a.addData(h,n,i),r=n,o=i,d="L";break;case"h":n+=f[m++],h=s.L,a.addData(h,n,i);break;case"H":n=f[m++],h=s.L,a.addData(h,n,i);break;case"v":i+=f[m++],h=s.L,a.addData(h,n,i);break;case"V":i=f[m++],h=s.L,a.addData(h,n,i);break;case"C":h=s.C,a.addData(h,f[m++],f[m++],f[m++],f[m++],f[m++],f[m++]),n=f[m-2],i=f[m-1];break;case"c":h=s.C,a.addData(h,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i),n+=f[m-2],i+=f[m-1];break;case"S":v=n,y=i;var C=a.len(),T=a.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),h=s.C,M=f[m++],I=f[m++],n=f[m++],i=f[m++],a.addData(h,v,y,M,I,n,i);break;case"s":v=n,y=i;var C=a.len(),T=a.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),h=s.C,M=n+f[m++],I=i+f[m++],n+=f[m++],i+=f[m++],a.addData(h,v,y,M,I,n,i);break;case"Q":M=f[m++],I=f[m++],n=f[m++],i=f[m++],h=s.Q,a.addData(h,M,I,n,i);break;case"q":M=f[m++]+n,I=f[m++]+i,n+=f[m++],i+=f[m++],h=s.Q,a.addData(h,M,I,n,i);break;case"T":v=n,y=i;var C=a.len(),T=a.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n=f[m++],i=f[m++],h=s.Q,a.addData(h,v,y,n,i);break;case"t":v=n,y=i;var C=a.len(),T=a.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n+=f[m++],i+=f[m++],h=s.Q,a.addData(h,v,y,n,i);break;case"A":x=f[m++],_=f[m++],w=f[m++],b=f[m++],S=f[m++],Yn(M=n,I=i,n=f[m++],i=f[m++],b,S,x,_,w,h=s.A,a);break;case"a":x=f[m++],_=f[m++],w=f[m++],b=f[m++],S=f[m++],Yn(M=n,I=i,n+=f[m++],i+=f[m++],b,S,x,_,w,h=s.A,a)}}("z"===d||"Z"===d)&&(h=s.Z,a.addData(h),n=r,i=o),e=h}return a.toStatic(),a}(t);return e=e||{},e.buildPath=function(t){if(t.setData){t.setData(n.data);(e=t.getContext())&&t.rebuildPath(e)}else{var e=t;n.rebuildPath(e)}},e.applyTransform=function(t){yp(n,t),this.dirty(!0)},e}function jn(t,e){return new Xn(Un(t,e))}function qn(t,e,n,i,r,o,a){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*a+(-3*(e-n)-2*s-l)*o+s*r+e}function $n(t,e,n){var i=e.points,r=e.smooth;if(i&&i.length>=2){if(r&&"spline"!==r){var o=Np(i,r,n,e.smoothConstraint);t.moveTo(i[0][0],i[0][1]);for(var a=i.length,s=0;(n?a:a-1)>s;s++){var l=o[2*s],u=o[2*s+1],h=i[(s+1)%a];t.bezierCurveTo(l[0],l[1],u[0],u[1],h[0],h[1])}}else{"spline"===r&&(i=zp(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 Kn(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x1,o=e.x2,a=e.y1,s=e.y2;Rp(2*r)===Rp(2*o)?t.x1=t.x2=Jn(r,i,!0):(t.x1=r,t.x2=o),Rp(2*a)===Rp(2*s)?t.y1=t.y2=Jn(a,i,!0):(t.y1=a,t.y2=s)}}function Qn(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x,o=e.y,a=e.width,s=e.height;t.x=Jn(r,i,!0),t.y=Jn(o,i,!0),t.width=Math.max(Jn(r+a,i,!1)-t.x,0===a?0:1),t.height=Math.max(Jn(o+s,i,!1)-t.y,0===s?0:1)}}function Jn(t,e,n){var i=Rp(2*t);return(i+Rp(e))%2==0?i/2:(i+(n?1:-1))/2}function ti(t,e,n){var i=t.cpx2,r=t.cpy2;return null===i||null===r?[(n?xn:yn)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?xn:yn)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?Mn:Sn)(t.x1,t.cpx1,t.x2,e),(n?Mn:Sn)(t.y1,t.cpy1,t.y2,e)]}function ei(t){We.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}function ni(t){return Xn.extend(t)}function ii(t,e){og[t]=e}function ri(t){return og.hasOwnProperty(t)?og[t]:void 0}function oi(t,e,n,i){var r=jn(t,e);return n&&("center"===i&&(n=si(n,r.getBoundingRect())),li(r,n)),r}function ai(t,e,n){var i=new He({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(si(e,r))}}});return i}function si(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);return{x:t.x+t.width/2-r/2,y:t.y+t.height/2-n/2,width:r,height:n}}function li(t,e){if(t.applyTransform){var n=t.getBoundingRect().calculateTransform(e);t.applyTransform(n)}}function ui(t){return null!=t&&"none"!==t}function hi(t){var e=t.__hoverStl;if(e&&!t.__highlighted){var n=t.__zr,i=t.useHoverLayer&&n&&"canvas"===n.painter.type;if(t.__highlighted=i?"layer":"plain",!(t.isGroup||!n&&t.useHoverLayer)){var r=t,o=t.style;i&&(r=n.addHover(t),o=r.style),ki(o),i||function(t){if(t.__hoverStlDirty){t.__hoverStlDirty=!1;var e=t.__hoverStl;if(!e)return void(t.__cachedNormalStl=t.__cachedNormalZ2=null);var n=t.__cachedNormalStl={};t.__cachedNormalZ2=t.z2;var i=t.style;for(var r in e)null!=e[r]&&(n[r]=i[r]);n.fill=i.fill,n.stroke=i.stroke}}(r),o.extendFrom(e),ci(o,e,"fill"),ci(o,e,"stroke"),Di(o),i||(t.dirty(!1),t.z2+=tg)}}}function ci(t,e,n){!ui(e[n])&&ui(t[n])&&(t[n]=function(t){if("string"!=typeof t)return t;var e=lg.get(t);return e||(e=Nt(t,-.1),1e4>ug&&(lg.set(t,e),ug++)),e}(t[n]))}function di(t){var e=t.__highlighted;if(e&&(t.__highlighted=!1,!t.isGroup))if("layer"===e)t.__zr&&t.__zr.removeHover(t);else{var n=t.style,i=t.__cachedNormalStl;i&&(ki(n),t.setStyle(i),Di(n));var r=t.__cachedNormalZ2;null!=r&&t.z2-r===tg&&(t.z2=r)}}function fi(t,e,n){var i,r=ng,o=ng;t.__highlighted&&(r=eg,i=!0),e(t,n),t.__highlighted&&(o=eg,i=!0),t.isGroup&&t.traverse(function(t){!t.isGroup&&e(t,n)}),i&&t.__highDownOnUpdate&&t.__highDownOnUpdate(r,o)}function pi(t,e){e=t.__hoverStl=!1!==e&&(t.hoverStyle||e||{}),t.__hoverStlDirty=!0,t.__highlighted&&(t.__cachedNormalStl=null,di(t),hi(t))}function gi(t){!xi(this,t)&&!this.__highByOuter&&fi(this,hi)}function mi(t){!xi(this,t)&&!this.__highByOuter&&fi(this,di)}function vi(t){this.__highByOuter|=1<<(t||0),fi(this,hi)}function yi(t){!(this.__highByOuter&=~(1<<(t||0)))&&fi(this,di)}function xi(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function _i(t,e){wi(t,!0),fi(t,pi,e)}function wi(t,e){var n=!1===e;if(t.__highDownSilentOnTouch=t.highDownSilentOnTouch,t.__highDownOnUpdate=t.highDownOnUpdate,!n||t.__highDownDispatcher){var i=n?"off":"on";t[i]("mouseover",gi)[i]("mouseout",mi),t[i]("emphasis",vi)[i]("normal",yi),t.__highByOuter=t.__highByOuter||0,t.__highDownDispatcher=!n}}function bi(t){return!(!t||!t.__highDownDispatcher)}function Si(t){var e=rg[t];return null==e&&32>=ig&&(e=rg[t]=ig++),e}function Mi(t,e,n,i,r,o,a){var s,l=(r=r||Jp).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=_(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)&&(Ii(t,n,o,r),Ii(e,i,a,r,!0)),t.text=f,e.text=p}function Ii(t,e,n,i,r){return Ci(t,e,i,r),n&&a(t,n),t}function Ci(t,e,n,i){if((n=n||Jp).isRectText){var r;n.getTextPosition?r=n.getTextPosition(e,i):"outside"===(r=e.getShallow("position")||(i?null:"inside"))&&(r="top"),t.textPosition=r,t.textOffset=e.getShallow("offset");var o=e.getShallow("rotate");null!=o&&(o*=Math.PI/180),t.textRotation=o,t.textDistance=A(e.getShallow("distance"),i?null:5)}var a,s=e.ecModel,l=s&&s.option.textStyle,u=function(t){for(var e;t&&t!==t.ecModel;){var n=(t.option||Jp).rich;if(n){e=e||{};for(var i in n)n.hasOwnProperty(i)&&(e[i]=1)}t=t.parentModel}return e}(e);if(u){a={};for(var h in u)if(u.hasOwnProperty(h)){var c=e.getModel(["rich",h]);Ti(a[h]={},c,l,n,i)}}return t.rich=a,Ti(t,e,l,n,i,!0),n.forceRich&&!n.textStyle&&(n.textStyle={}),t}function Ti(t,e,n,i,r,o){n=!r&&n||Jp,t.textFill=Ai(e.getShallow("color"),i)||n.color,t.textStroke=Ai(e.getShallow("textBorderColor"),i)||n.textBorderColor,t.textStrokeWidth=A(e.getShallow("textBorderWidth"),n.textBorderWidth),r||(o&&(t.insideRollbackOpt=i,Di(t)),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"),o&&i.disableBox||(t.textBackgroundColor=Ai(e.getShallow("backgroundColor"),i),t.textPadding=e.getShallow("padding"),t.textBorderColor=Ai(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 Ai(t,e){return"auto"!==t?t:e&&e.autoColor?e.autoColor:null}function Di(t){var e,n=t.textPosition,i=t.insideRollbackOpt;if(i&&null==t.textFill){var r=i.autoColor,o=i.isRectText,a=i.useInsideStyle,s=!1!==a&&(!0===a||o&&n&&"string"==typeof n&&n.indexOf("inside")>=0),l=!s&&null!=r;(s||l)&&(e={textFill:t.textFill,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth}),s&&(t.textFill="#fff",null==t.textStroke&&(t.textStroke=r,null==t.textStrokeWidth&&(t.textStrokeWidth=2))),l&&(t.textFill=r)}t.insideRollback=e}function ki(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth,t.insideRollback=null)}function Pi(t,e){var n=e||e.getModel("textStyle");return L([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 Oi(t,e,n,i,r,o){"function"==typeof r&&(o=r,r=null);if(i&&i.isAnimationEnabled()){var a=t?"Update":"",s=i.getShallow("animationDuration"+a),l=i.getShallow("animationEasing"+a),u=i.getShallow("animationDelay"+a);"function"==typeof u&&(u=u(r,i.getAnimationDelayParams?i.getAnimationDelayParams(e,r):null)),"function"==typeof s&&(s=s(r)),s>0?e.animateTo(n,s,u||0,l,o,!!o):(e.stopAnimation(),e.attr(n),o&&o())}else e.stopAnimation(),e.attr(n),o&&o()}function Li(t,e,n,i,r){Oi(!0,t,e,n,i,r)}function zi(t,e,n,i,r){Oi(!1,t,e,n,i,r)}function Ni(t,e){for(var n=gt([]);t&&t!==e;)vt(n,t.getLocalTransform(),n),t=t.parent;return n}function Ei(t,e,n){return e&&!d(e)&&(e=Zc.getLocalTransform(e)),n&&(e=wt([],e)),K([],t,e)}function Bi(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]),o=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return o=Ei(o,e,n),Math.abs(o[0])>Math.abs(o[1])?o[0]>0?"right":"left":o[1]>0?"bottom":"top"}function Ri(t,e,n){function i(t){var e={position:G(t.position),rotation:t.rotation};return t.shape&&(e.shape=a({},t.shape)),e}if(t&&e){var r=function(t){var e={};return t.traverse(function(t){!t.isGroup&&t.anid&&(e[t.anid]=t)}),e}(t);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=r[t.anid];if(e){var o=i(t);t.attr(i(e)),Li(t,o,n,t.dataIndex)}}})}}function Fi(t,e){return p(t,function(t){var n=t[0];n=Kp(n,e.x),n=Qp(n,e.x+e.width);var i=t[1];return i=Kp(i,e.y),i=Qp(i,e.y+e.height),[n,i]})}function Vi(t,e,n){var i=(e=a({rectHover:!0},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 He(e)):oi(t.replace("path://",""),e,n,"center"):void 0}function Gi(t,e,n,i,r,o,a,s){var l=n-t,u=i-e,h=a-r,c=s-o,d=Wi(h,c,l,u);if(function(t){return 1e-6>=t&&t>=-1e-6}(d))return!1;var f=t-r,p=e-o,g=Wi(f,p,l,u)/d;if(0>g||g>1)return!1;var m=Wi(f,p,h,c)/d;return!(0>m||m>1)}function Wi(t,e,n,i){return t*i-n*e}function Hi(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function Zi(t,e,n){for(var i=0;i<e.length&&(!e[i]||null!=(t=t&&"object"==typeof t?t[e[i]]:null));i++);return null==t&&n&&(t=n.get(e)),t}function Xi(t,e){var n=mg(t).getParent;return n?n.call(t,e):t.parentModel}function Yi(t){return[t||"",vg++,Math.random().toFixed(5)].join("_")}function Ui(t,e,n,i){var r=e[1]-e[0],o=n[1]-n[0];if(0===r)return 0===o?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*o+n[0]}function ji(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?function(t){return t.replace(/^\s+|\s+$/g,"")}(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function qi(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function $i(t){return t.sort(function(t,e){return t-e}),t}function Ki(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 Qi(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 Ji(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),o=Math.round(n(Math.abs(e[1]-e[0]))/i),a=Math.min(Math.max(-r+o,0),20);return isFinite(a)?a:20}function tr(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),o=p(t,function(t){return(isNaN(t)?0:t)/i*r*100}),a=100*r,s=p(o,function(t){return Math.floor(t)}),l=g(s,function(t,e){return t+e},0),u=p(o,function(t,e){return t-s[e]});a>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 er(t){var e=2*Math.PI;return(t%e+e)%e}function nr(t){return t>-yg&&yg>t}function ir(t){if(t instanceof Date)return t;if("string"==typeof t){var e=xg.exec(t);if(!e)return new Date(NaN);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?NaN:Math.round(t))}function rr(t){return Math.pow(10,or(t))}function or(t){if(0===t)return 0;var e=Math.floor(Math.log(t)/Math.LN10);return t/Math.pow(10,e)>=10&&e++,e}function ar(t,e){var n,i=or(t),r=Math.pow(10,i),o=t/r;return n=e?1.5>o?1:2.5>o?2:4>o?3:7>o?5:10:1>o?1:2>o?2:3>o?3:5>o?5:10,t=n*r,i>=-20?+t.toFixed(0>i?-i:0):t}function sr(t){return isNaN(t)?"-":(t=(t+"").split("."))[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function lr(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 ur(t){return null==t?"":(t+"").replace(bg,function(t,e){return Sg[e]})}function hr(t,e,n){x(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],o=0;o<r.length;o++){var a=Mg[o];t=t.replace(Ig(a),Ig(a,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(Ig(Mg[l],s),n?ur(u):u)}return t}function cr(t,e){var n=(t=w(t)?{color:t,extraCssText:e}:t||{}).color,i=t.type,e=t.extraCssText,r=t.renderMode||"html",o=t.markerId||"X";return n?"html"===r?"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:'+ur(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:'+ur(n)+";"+(e||"")+'"></span>':{renderMode:r,content:"{marker"+o+"|} ",style:{color:n}}:""}function dr(t,e){return t+="","0000".substr(0,e-t.length)+t}function fr(t,e,n){("week"===t||"month"===t||"quarter"===t||"half-year"===t||"year"===t)&&(t="MM-dd\nyyyy");var i=ir(e),r=n?"UTC":"",o=i["get"+r+"FullYear"](),a=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"](),c=i["get"+r+"Milliseconds"]();return t=t.replace("MM",dr(a,2)).replace("M",a).replace("yyyy",o).replace("yy",o%100).replace("dd",dr(s,2)).replace("d",s).replace("hh",dr(l,2)).replace("h",l).replace("mm",dr(u,2)).replace("m",u).replace("ss",dr(h,2)).replace("s",h).replace("SSS",dr(c,3))}function pr(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function gr(t,e,n,i,r){var o=0,a=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 m=f.width+(g?-g.x+f.x:0);(h=o+m)>i||l.newline?(o=0,h=m,a+=s+n,s=f.height):s=Math.max(s,f.height)}else{var v=f.height+(g?-g.y+f.y:0);(c=a+v)>r||l.newline?(o+=s+n,a=0,c=v,s=f.width):s=Math.max(s,f.width)}l.newline||(d[0]=o,d[1]=a,"horizontal"===t?o=h+n:a=c+n)})}function mr(t,e,n){n=wg(n||0);var i=e.width,r=e.height,o=ji(t.left,i),a=ji(t.top,r),s=ji(t.right,i),l=ji(t.bottom,r),u=ji(t.width,i),h=ji(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(u)&&(u=i-s-d-o),isNaN(h)&&(h=r-l-c-a),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(o)&&(o=i-s-u-d),isNaN(a)&&(a=r-l-h-c),t.left||t.right){case"center":o=i/2-u/2-n[3];break;case"right":o=i-u-d}switch(t.top||t.bottom){case"middle":case"center":a=r/2-h/2-n[0];break;case"bottom":a=r-h-c}o=o||0,a=a||0,isNaN(u)&&(u=i-d-o-(s||0)),isNaN(h)&&(h=r-c-a-(l||0));var p=new te(o+n[3],a+n[0],u,h);return p.margin=n,p}function vr(t,e,n,i,r){var o=!r||!r.hv||r.hv[0],a=!r||!r.hv||r.hv[1],l=r&&r.boundingMode||"all";if(o||a){var u;if("raw"===l)u="group"===t.type?new te(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(u=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();(u=u.clone()).applyTransform(h)}e=mr(s({width:u.width,height:u.height},e),n,i);var c=t.position,d=o?e.x-u.x:0,f=a?e.y-u.y:0;t.attr("position","raw"===l?[d,f]:[c[0]+d,c[1]+f])}}function yr(t,e,n){function i(n,i){var a={},l=0,u={},h=0;if(Ag(n,function(e){u[e]=t[e]}),Ag(n,function(t){r(e,t)&&(a[t]=u[t]=e[t]),o(a,t)&&l++,o(u,t)&&h++}),s[i])return o(e,n[1])?u[n[2]]=null:o(e,n[2])&&(u[n[1]]=null),u;if(2!==h&&l){if(l>=2)return a;for(var c=0;c<n.length;c++){var d=n[c];if(!r(a,d)&&r(t,d)){a[d]=t[d];break}}return a}return u}function r(t,e){return t.hasOwnProperty(e)}function o(t,e){return null!=t[e]&&"auto"!==t[e]}function a(t,e,n){Ag(t,function(t){e[t]=n[t]})}!b(n)&&(n={});var s=n.ignoreSize;!x(s)&&(s=[s,s]);var l=i(kg[0],0),u=i(kg[1],1);a(kg[0],t,l),a(kg[1],t,u)}function xr(t){return _r({},t)}function _r(t,e){return e&&t&&Ag(Dg,function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function wr(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSysDims:[],axisMap:B(),categoryAxisMap:B()},i=Fg[e];return i?(i(t,n,n.axisMap,n.categoryAxisMap),n):void 0}function br(t){return"category"===t.get("type")}function Sr(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===Hg?{}:[]),this.sourceFormat=t.sourceFormat||Zg,this.seriesLayoutBy=t.seriesLayoutBy||Yg,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&B(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}function Mr(t){var e=t.option,n=e.data,i=M(n)?Xg:Vg,r=!1,o=e.seriesLayoutBy,a=e.sourceHeader,s=e.dimensions,l=function(t){var e=t.option;return e.data?void 0:t.ecModel.getComponent("dataset",e.datasetIndex||0)}(t);if(l){var u=l.option;n=u.source,i=jg(l).sourceFormat,r=!0,o=o||u.seriesLayoutBy,null==a&&(a=u.sourceHeader),s=s||u.dimensions}var h=function(t,e,n,i,r){if(!t)return{dimensionsDefine:Ir(r)};var o,a,s;if(e===Gg)"auto"===i||null==i?Cr(function(t){null!=t&&"-"!==t&&(w(t)?null==a&&(a=1):a=0)},n,t,10):a=i?1:0,r||1!==a||(r=[],Cr(function(t,e){r[e]=null!=t?t:""},n,t)),o=r?r.length:n===Ug?t.length:t[0]?t[0].length:null;else if(e===Wg)r||(r=function(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}}(t),s=!0);else if(e===Hg)r||(r=[],s=!0,f(t,function(t,e){r.push(e)}));else if(e===Vg){var l=Qe(t[0]);o=x(l)&&l.length||1}var u;return s&&f(r,function(t,e){"name"===(b(t)?t.name:t)&&(u=e)}),{startIndex:a,dimensionsDefine:Ir(r),dimensionsDetectCount:o,potentialNameDimIndex:u}}(n,i,o,a,s),c=e.encode;!c&&l&&(c=function(t,e,n,i,r,o){var a=wr(t),s={},l=[],u=[],h=t.subType,c=B(["pie","map","funnel"]),d=B(["line","bar","pictorialBar","scatter","effectScatter","candlestick","boxplot"]);if(a&&null!=d.get(h)){var p=t.ecModel,g=jg(p).datasetMap,m=e.uid+"_"+r,v=g.get(m)||g.set(m,{categoryWayDim:1,valueWayDim:0});f(a.coordSysDims,function(t){if(null==a.firstCategoryDimIndex){e=v.valueWayDim++;s[t]=e,u.push(e)}else if(a.categoryAxisMap.get(t))s[t]=0,l.push(0);else{var e=v.categoryWayDim++;s[t]=e,u.push(e)}})}else if(null!=c.get(h)){for(var y,x=0;5>x&&null==y;x++)Ar(n,i,r,o.dimensionsDefine,o.startIndex,x)||(y=x);if(null!=y){s.value=y;var _=o.potentialNameDimIndex||Math.max(y-1,0);u.push(_),l.push(_)}}return l.length&&(s.itemName=l),u.length&&(s.seriesName=u),s}(t,l,n,i,o,h)),jg(t).source=new Sr({data:n,fromDataset:r,seriesLayoutBy:o,sourceFormat:i,dimensionsDefine:h.dimensionsDefine,startIndex:h.startIndex,dimensionsDetectCount:h.dimensionsDetectCount,encodeDefine:c})}function Ir(t){if(t){var e=B();return p(t,function(t){if(null==(t=a({},b(t)?t:{name: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 Cr(t,e,n,i){if(null==i&&(i=1/0),e===Ug)for(o=0;o<n.length&&i>o;o++)t(n[o]?n[o][0]:null,o);else for(var r=n[0]||[],o=0;o<r.length&&i>o;o++)t(r[o],o)}function Tr(t,e){return Ar(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,e)}function Ar(t,e,n,i,r,o){function a(t){return(null==t||!isFinite(t)||""===t)&&(!(!w(t)||"-"===t)||void 0)}var s;if(M(t))return!1;var l;if(i&&(l=i[o],l=b(l)?l.name:l),e===Gg)if(n===Ug){for(var u=t[o],h=0;h<(u||[]).length&&5>h;h++)if(null!=(s=a(u[r+h])))return s}else for(h=0;h<t.length&&5>h;h++){var c=t[r+h];if(c&&null!=(s=a(c[o])))return s}else if(e===Wg){if(!l)return;for(h=0;h<t.length&&5>h;h++){if((d=t[h])&&null!=(s=a(d[l])))return s}}else if(e===Hg){if(!l)return;if(!(u=t[l])||M(u))return!1;for(h=0;h<u.length&&5>h;h++)if(null!=(s=a(u[h])))return s}else if(e===Vg)for(h=0;h<t.length&&5>h;h++){var d=t[h],f=Qe(d);if(!x(f))return!1;if(null!=(s=a(f[o])))return s}return!1}function Dr(t){t=t,this.option={},this.option[qg]=1,this._componentsMap=B({series:[]}),this._seriesIndices,this._seriesIndicesMap,function(t,e){var n=t.color&&!t.colorLayer;f(e,function(e,o){"colorLayer"===o&&n||zg.hasClass(o)||("object"==typeof e?t[o]=t[o]?r(t[o],e,!1):i(e):null==t[o]&&(t[o]=e))})}(t,this._theme.option),r(t,Eg,!1),this.mergeOption(t)}function kr(t,e){t._seriesIndicesMap=B(t._seriesIndices=p(e,function(t){return t.componentIndex})||[])}function Pr(t,e){return e.hasOwnProperty("subType")?m(t,function(t){return t.subType===e.subType}):t}function Or(t){f(Kg,function(e){this[e]=v(t[e],t)},this)}function Lr(){this._coordinateSystems=[]}function zr(t){this._api=t,this._timelineOptions=[],this._mediaList=[],this._mediaDefault,this._currentMediaIndices=[],this._optionBackup,this._newBaseOption}function Nr(t,e,n){var i={width:e,height:n,aspectratio:e/n},r=!0;return f(t,function(t,e){var n=e.match(im);if(n&&n[1]&&n[2]){var o=n[1],a=n[2].toLowerCase();(function(t,e,n){return"min"===n?t>=e:"max"===n?e>=t:t===e})(i[a],t,o)||(r=!1)}}),r}function Er(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=am.length;i>n;n++){var o=am[n],a=e.normal,s=e.emphasis;a&&a[o]&&(t[o]=t[o]||{},t[o].normal?r(t[o].normal,a[o]):t[o].normal=a[o],a[o]=null),s&&s[o]&&(t[o]=t[o]||{},t[o].emphasis?r(t[o].emphasis,s[o]):t[o].emphasis=s[o],s[o]=null)}}function Br(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 Rr(t){Br(t,"itemStyle"),Br(t,"lineStyle"),Br(t,"areaStyle"),Br(t,"label"),Br(t,"labelLine"),Br(t,"upperLabel"),Br(t,"edgeLabel")}function Fr(t,e){var n=om(t)&&t[e],i=om(n)&&n.textStyle;if(i)for(var r=0,o=mf.length;o>r;r++){e=mf[r];i.hasOwnProperty(e)&&(n[e]=i[e])}}function Vr(t){t&&(Rr(t),Fr(t,"label"),t.emphasis&&Fr(t.emphasis,"label"))}function Gr(t){if(om(t)){Er(t),Rr(t),Fr(t,"label"),Fr(t,"upperLabel"),Fr(t,"edgeLabel"),t.emphasis&&(Fr(t.emphasis,"label"),Fr(t.emphasis,"upperLabel"),Fr(t.emphasis,"edgeLabel"));r=t.markPoint;r&&(Er(r),Vr(r));s=t.markLine;s&&(Er(s),Vr(s));var e=t.markArea;e&&Vr(e);var n=t.data;if("graph"===t.type){n=n||t.nodes;var i=t.links||t.edges;if(i&&!M(i))for(a=0;a<i.length;a++)Vr(i[a]);f(t.categories,function(t){Rr(t)})}if(n&&!M(n))for(a=0;a<n.length;a++)Vr(n[a]);var r;if((r=t.markPoint)&&r.data)for(var o=r.data,a=0;a<o.length;a++)Vr(o[a]);var s;if((s=t.markLine)&&s.data)for(var l=s.data,a=0;a<l.length;a++)x(l[a])?(Vr(l[a][0]),Vr(l[a][1])):Vr(l[a]);"gauge"===t.type?(Fr(t,"axisLabel"),Fr(t,"title"),Fr(t,"detail")):"treemap"===t.type?(Br(t.breadcrumb,"itemStyle"),f(t.levels,function(t){Rr(t)})):"tree"===t.type&&Rr(t.leaves)}}function Wr(t){return x(t)?t:t?[t]:[]}function Hr(t){return(x(t)?t[0]:t)||{}}function Zr(t){f(sm,function(e){e[0]in t&&!(e[1]in t)&&(t[e[1]]=t[e[0]])})}function Xr(t){f(t,function(e,n){var i=[],r=[NaN,NaN],o=[e.stackResultDimension,e.stackedOverDimension],a=e.data,s=e.isStackedByIndex,l=a.map(o,function(o,l,u){var h=a.get(e.stackedDimension,u);if(isNaN(h))return r;var c,d;s?d=a.getRawIndex(u):c=a.get(e.stackedByDimension,u);for(var f=NaN,p=n-1;p>=0;p--){var g=t[p];if(s||(d=g.data.rawIndexOf(g.stackedByDimension,c)),d>=0){var m=g.data.getByRawIndex(g.stackResultDimension,d);if(h>=0&&m>0||0>=h&&0>m){h+=m,f=m;break}}}return i[0]=h,i[1]=f,i});a.hostModel.setData(l),e.data=l})}function Yr(t,e){Sr.isInstance(t)||(t=Sr.seriesDataToSource(t)),this._source=t;var n=this._data=t.data,i=t.sourceFormat;i===Xg&&(this._offset=0,this._dimSize=e,this._data=n);a(this,cm[i===Gg?i+"_"+t.seriesLayoutBy:i])}function Ur(){return this._data.length}function jr(t){return this._data[t]}function qr(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}function $r(t,e,n){return null!=n?t[n]:t}function Kr(t,e,n,i){return Qr(t[i],this._dimensionInfos[e])}function Qr(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=+ir(t)),null==t||""===t?NaN:+t}function Jr(t,e,n){if(t){var i=t.getRawDataItem(e);if(null!=i){var r,o,a=t.getProvider().getSource().sourceFormat,s=t.getDimensionInfo(n);return s&&(r=s.name,o=s.index),dm[a](i,e,o,r)}}}function to(t,e,n){if(t){var i=t.getProvider().getSource().sourceFormat;if(i===Vg||i===Wg){var r=t.getRawDataItem(e);return i!==Vg||b(r)||(r=null),r?r[n]:void 0}}}function eo(t){return new no(t)}function no(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 io(t,e,n,i,r,o){vm.reset(n,i,r,o),t._callingProgress=e,t._callingProgress({start:n,end:i,count:i-n,next:vm.next},t.context)}function ro(t){var e=t.name;en(t)||(t.name=function(t){var e=t.getRawData(),n=[];return f(e.mapDimension("seriesName",!0),function(t){var i=e.getDimensionInfo(t);i.displayName&&n.push(i.displayName)}),n.join(" ")}(t)||e)}function oo(t){return t.model.getRawData().count()}function ao(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),function(t,e){t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}}function so(t,e){f(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,y(lo,e))})}function lo(t){var e=uo(t);e&&e.setOutputEnd(this.count())}function uo(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 ho(){this.group=new yd,this.uid=Yi("viewChart"),this.renderTask=eo({plan:po,reset:go}),this.renderTask.context={view:this}}function co(t,e,n){if(t&&(t.trigger(e,n),t.isGroup&&!bi(t)))for(var i=0,r=t.childCount();r>i;i++)co(t.childAt(i),e,n)}function fo(t,e,n){var i=rn(t,e),r=e&&null!=e.highlightKey?Si(e.highlightKey):null;null!=i?f($e(i),function(e){co(t.getItemGraphicEl(e),n,r)}):t.eachItemGraphicEl(function(t){co(t,n,r)})}function po(t){return Mm(t.model)}function go(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,o=e.pipelineContext.progressiveRender,a=t.view,s=r&&Sm(r).updateMethod,l=o?"incrementalPrepareRender":s&&a[s]?s:"render";return"render"!==l&&a[l](e,n,i,r),Cm[l]}function mo(t,e,n){function i(){h=(new Date).getTime(),c=null,t.apply(a,s||[])}var r,o,a,s,l,u=0,h=0,c=null;e=e||0;var d=function(){r=(new Date).getTime(),a=this,s=arguments;var t=l||e,d=l||n;l=null,o=r-(d?u:h)-t,clearTimeout(c),d?c=setTimeout(i,t):o>=0?i():c=setTimeout(i,-o),u=r};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(t){l=t},d}function vo(t,e,n,i){var r=t[e];if(r){var o=r[Tm]||r,a=r[Dm];if(r[Am]!==n||a!==i){if(null==n||!i)return t[e]=o;(r=t[e]=mo(o,n,"debounce"===i))[Tm]=o,r[Dm]=i,r[Am]=n}return r}}function yo(t,e){var n=t[e];n&&n[Tm]&&(t[e]=n[Tm])}function xo(t,e,n,i){this.ecInstance=t,this.api=e,this.unfinished;var n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice();this._allHandlers=n.concat(i),this._stageTaskMap=B()}function _o(t,e,n,i,r){function o(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}r=r||{};var a;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){o(r,t)&&(t.dirty(),h=!0)}),h&&u.dirty(),Nm(u,i);var d=t.getPerformArgs(u,r.block);c.each(function(t){t.perform(d)}),a|=u.perform(d)}else l&&l.each(function(s){o(r,s)&&s.dirty();var l=t.getPerformArgs(s,r.block);l.skip=!e.performRawSeries&&n.isSeriesFiltered(s.context.model),Nm(s,i),a|=s.perform(l)})}}),t.unfinished|=a}function wo(t){t.overallReset(t.ecModel,t.api,t.payload)}function bo(t){return t.overallProgress&&function(){this.agent.dirty(),this.getDownstream().dirty()}}function So(){this.agent&&this.agent.dirty()}function Mo(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function Io(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=$e(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length>1?p(e,function(t,e){return Co(e)}):Em}function Co(t){return function(e,n){var i=n.data,r=n.resetDefines[t];if(r&&r.dataEach)for(var o=e.start;o<e.end;o++)r.dataEach(i,o);else r&&r.progress&&r.progress(e,i)}}function To(t){return t.data.count()}function Ao(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 Do(t,e){for(var n in e.prototype)t[n]=R}function ko(t){if(w(t)){t=(new DOMParser).parseFromString(t,"text/xml")}for(9===t.nodeType&&(t=t.firstChild);"svg"!==t.nodeName.toLowerCase()||1!==t.nodeType;)t=t.nextSibling;return t}function Po(){this._defs={},this._root=null,this._isDefine=!1,this._isText=!1}function Oo(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),s(e.__inheritedStyle,t.__inheritedStyle))}function Lo(t){for(var e=L(t).split(Um),n=[],i=0;i<e.length;i+=2){var r=parseFloat(e[i]),o=parseFloat(e[i+1]);n.push([r,o])}return n}function zo(t,e,n,i){var r=e.__inheritedStyle||{},o="text"===e.type;if(1===t.nodeType&&(function(t,e){var n=t.getAttribute("transform");if(n){var i=null,r=[];(n=n.replace(/,/g," ")).replace(Qm,function(t,e,n){r.push(e,n)});for(var o=r.length-1;o>0;o-=2){var a=r[o],s=r[o-1];switch(i=i||pt(),s){case"translate":a=L(a).split(Um),yt(i,i,[parseFloat(a[0]),parseFloat(a[1]||0)]);break;case"scale":a=L(a).split(Um),_t(i,i,[parseFloat(a[0]),parseFloat(a[1]||a[0])]);break;case"rotate":a=L(a).split(Um),xt(i,i,parseFloat(a[0]));break;case"skew":a=L(a).split(Um),console.warn("Skew transform is not supported yet");break;case"matrix":a=L(a).split(Um);i[0]=parseFloat(a[0]),i[1]=parseFloat(a[1]),i[2]=parseFloat(a[2]),i[3]=parseFloat(a[3]),i[4]=parseFloat(a[4]),i[5]=parseFloat(a[5])}}e.setLocalTransform(i)}}(t,e),a(r,function(t){var e=t.getAttribute("style"),n={};if(!e)return n;var i={};Jm.lastIndex=0;for(var r;null!=(r=Jm.exec(e));)i[r[1]]=r[2];for(var o in $m)$m.hasOwnProperty(o)&&null!=i[o]&&(n[$m[o]]=i[o]);return n}(t)),!i))for(var s in $m)if($m.hasOwnProperty(s)){var l=t.getAttribute(s);null!=l&&(r[$m[s]]=l)}var u=o?"textFill":"fill",h=o?"textStroke":"stroke";e.style=e.style||new Td;var c=e.style;null!=r.fill&&c.set(u,No(r.fill,n)),null!=r.stroke&&c.set(h,No(r.stroke,n)),f(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(t){var e="lineWidth"===t&&o?"textStrokeWidth":t;null!=r[t]&&c.set(e,parseFloat(r[t]))}),r.textBaseline&&"auto"!==r.textBaseline||(r.textBaseline="alphabetic"),"alphabetic"===r.textBaseline&&(r.textBaseline="bottom"),"start"===r.textAlign&&(r.textAlign="left"),"end"===r.textAlign&&(r.textAlign="right"),f(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign","textBaseline"],function(t){null!=r[t]&&c.set(t,r[t])}),r.lineDash&&(e.style.lineDash=L(r.lineDash).split(Um)),c[h]&&"none"!==c[h]&&(e[h]=!0),e.__inheritedStyle=r}function No(t,e){var n=e&&t&&t.match(Km);if(n){return e[L(n[1])]}return t}function Eo(t,e){return function(n,i,r){(e||!this._disposed)&&(n=n&&n.toLowerCase(),Ac.prototype[t].call(this,n,i,r))}}function Bo(){Ac.call(this)}function Ro(t,e,n){function r(t,e){return t.__prio-e.__prio}n=n||{},"string"==typeof e&&(e=Mv[e]),this.id,this.group,this._dom=t;var o=this._zr=qe(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height});this._throttledZrFlush=mo(v(o.flush,o),17);(e=i(e))&&um(e,!0),this._theme=e,this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._coordSysMgr=new Lr;var a=this._api=Qo(this);oe(Sv,r),oe(_v,r),this._scheduler=new xo(this,a,_v,Sv),Ac.call(this,this._ecEventProcessor=new Jo),this._messageCenter=new Bo,this._initEvents(),this.resize=v(this.resize,this),this._pendingActions=[],o.animation.on("frame",this._onframe,this),function(t,e){t.on("rendered",function(){e.trigger("rendered"),!t.animation.isFinished()||e[fv]||e._scheduler.unfinished||e._pendingActions.length||e.trigger("finished")})}(o,this),z(this)}function Fo(t,e,n){if(!this._disposed){var i,r=this._model,o=this._coordSysMgr.getCoordinateSystems();e=an(r,e);for(var a=0;a<o.length;a++){var s=o[a];if(s[t]&&null!=(i=s[t](r,e,n)))return i}}}function Vo(t){var e=t._model,n=t._scheduler;n.restorePipelines(e),n.prepareStageTasks(),Yo(t,"component",e,n),Yo(t,"chart",e,n),n.plan()}function Go(t,e,n,i,r){function o(i){i&&i.__alive&&i[e]&&i[e](i.__model,a,t._api,n)}var a=t._model;if(i){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);var u=n.excludeSeriesId;null!=u&&(u=B($e(u))),a&&a.eachComponent(l,function(e){u&&null!=u.get(e.id)||o(t["series"===i?"_chartsMap":"_componentsMap"][e.__viewId])},t)}else rv(t._componentsViews.concat(t._chartsViews),o)}function Wo(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})}function Ho(t,e){var n=t.type,i=t.escapeConnect,r=yv[n],o=r.actionInfo,l=(o.update||"update").split(":"),u=l.pop();l=null!=l[0]&&sv(l[0]),this[dv]=!0;var h=[t],c=!1;t.batch&&(c=!0,h=p(t.batch,function(e){return e=s(a({},e),t),e.batch=null,e}));var d,f=[],g="highlight"===n||"downplay"===n;rv(h,function(t){(d=(d=r.action(t,this._model,this._api))||a({},t)).type=o.event||d.type,f.push(d),g?Go(this,u,t,"series"):l&&Go(this,u,t,l.main,l.sub)},this),"none"===u||g||l||(this[fv]?(Vo(this),mv.update.call(this,t),this[fv]=!1):mv[u].call(this,t)),d=c?{type:o.event||n,escapeConnect:i,batch:f}:f[0],this[dv]=!1,!e&&this._messageCenter.trigger(d.type,d)}function Zo(t){for(var e=this._pendingActions;e.length;){var n=e.shift();Ho.call(this,n,t)}}function Xo(t){!t&&this.trigger("updated")}function Yo(t,e,n,i){function r(t){var e="_ec_"+t.id+"_"+t.type,r=s[e];if(!r){var h=sv(t.type);(r=new(o?_m.getClass(h.main,h.sub):ho.getClass(h.sub))).init(n,u),s[e]=r,a.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},!o&&i.prepareView(r,t,n,u)}for(var o="component"===e,a=o?t._componentsViews:t._chartsViews,s=o?t._componentsMap:t._chartsMap,l=t._zr,u=t._api,h=0;h<a.length;h++)a[h].__alive=!1;o?n.eachComponent(function(t,e){"series"!==t&&r(e)}):n.eachSeries(r);for(h=0;h<a.length;){var c=a[h];c.__alive?h++:(!o&&c.renderTask.dispose(),l.remove(c.group),c.dispose(n,u),a.splice(h,1),delete s[c.__id],c.__id=c.group.__ecComponentInfo=null)}}function Uo(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})}function jo(t,e,n,i){(function(t,e,n,i,r){rv(r||t._componentsViews,function(t){var r=t.__model;t.render(r,e,n,i),Ko(r,t)})})(t,e,n,i),rv(t._chartsViews,function(t){t.__alive=!1}),qo(t,e,n,i),rv(t._chartsViews,function(t){t.__alive||t.remove(e,n)})}function qo(t,e,n,i,r){var o,a=t._scheduler;e.eachSeries(function(e){var n=t._chartsMap[e.__viewId];n.__alive=!0;var s=n.renderTask;a.updatePayload(s,i),r&&r.get(e.uid)&&s.dirty(),o|=s.perform(a.getPerformArgs(s)),n.group.silent=!!e.get("silent"),Ko(e,n),function(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)})})}(e,n)}),a.unfinished|=o,function(t,e){var n=0;t._zr.storage.traverse(function(){n++}),n>e.get("hoverLayerThreshold")&&!ac.node&&e.eachSeries(function(e){if(!e.preventUsingHoverLayer){var n=t._chartsMap[e.__viewId];n.__alive&&n.group.traverse(function(t){t.useHoverLayer=!0})}})}(t,e),Om(t._zr.dom,e)}function $o(t,e){rv(bv,function(n){n(t,e)})}function Ko(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 Qo(t){var e=t._coordSysMgr;return a(new Or(t),{getCoordinateSystems:v(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 Jo(){this.eventInfo}function ta(t){Tv[t]=!1}function ea(t){return Cv[function(t,e){return t.getAttribute?t.getAttribute(e):t[e]}(t,kv)]}function na(t,e){Mv[t]=e}function ia(t){wv.push(t)}function ra(t,e){la(_v,t,e,lv)}function oa(t,e,n){"function"==typeof e&&(n=e,e="");var i=av(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,iv(pv.test(i)&&pv.test(e)),yv[i]||(yv[i]={action:n,actionInfo:t}),xv[e]=i}function aa(t,e){la(Sv,t,e,uv,"layout")}function sa(t,e){la(Sv,t,e,hv,"visual")}function la(t,e,n,i,r){(ov(e)||av(e))&&(n=e,e=i);var o=xo.wrapStageHandler(n,r);return o.__prio=e,o.__raw=n,t.push(o),o}function ua(t,e){Iv[t]=e}function ha(t){return zg.extend(t)}function ca(t){return _m.extend(t)}function da(t){return xm.extend(t)}function fa(t){return ho.extend(t)}function pa(t){return t}function ga(t,e,n,i,r){this._old=t,this._new=e,this._oldKeyGetter=n||pa,this._newKeyGetter=i||pa,this.context=r}function ma(t,e,n,i,r){for(var o=0;o<t.length;o++){var a="_ec_"+r[i](t[o],o),s=e[a];null==s?(n.push(a),e[a]=o):(s.length||(e[a]=s=[s]),s.push(o))}}function va(t,e){return t.hasOwnProperty(e)||(t[e]=[]),t[e]}function ya(t){return t._rawCount>65535?Rv:Vv}function xa(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function _a(t,e){f(Gv.concat(e.__wrappedMethods||[]),function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t.__wrappedMethods=e.__wrappedMethods,f(Wv,function(n){t[n]=i(e[n])}),t._calculationInfo=a(e._calculationInfo)}function wa(t,e,n,i,r){var o=Bv[e.type],a=i-1,s=e.name,l=t[s][a];if(l&&l.length<n){for(var u=new o(Math.min(r-a*n,n)),h=0;h<l.length;h++)u[h]=l[h];t[s][a]=u}for(var c=i*n;r>c;c+=n)t[s].push(new o(Math.min(r-c,n)))}function ba(t){var e=t._invertedIndicesMap;f(e,function(n,i){var r=t._dimensionInfos[i].ordinalMeta;if(r){n=e[i]=new Fv(r.categories.length);for(o=0;o<n.length;o++)n[o]=Nv;for(var o=0;o<t._count;o++)n[t.get(i,o)]=o}})}function Sa(t,e,n){var i;if(null!=e){var r=t._chunkSize,o=Math.floor(n/r),a=n%r,s=t.dimensions[e],l=t._storage[s][o];if(l){i=l[a];var u=t._dimensionInfos[s].ordinalMeta;u&&u.categories.length&&(i=u.categories[i])}}return i}function Ma(t){return t}function Ia(t){return t<this._count&&t>=0?this._indices[t]:-1}function Ca(t,e){var n=t._idList[e];return null==n&&(n=Sa(t,t._idDimIdx,e)),null==n&&(n=Ev+e),n}function Ta(t){return x(t)||(t=[t]),t}function Aa(t,e){var n=t.dimensions,i=new Hv(p(n,t.getDimensionInfo,t),t.hostModel);_a(i,t);for(var r=i._storage={},o=t._storage,a=0;a<n.length;a++){var s=n[a];o[s]&&(u(e,s)>=0?(r[s]=function(t){for(var e=new Array(t.length),n=0;n<t.length;n++)e[n]=xa(t[n]);return e}(o[s]),i._rawExtent[s]=[1/0,-1/0],i._extent[s]=null):r[s]=o[s])}return i}function Da(t,e,n){function r(t,e,n){null!=Ov.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,h.set(e,!0))}Sr.isInstance(e)||(e=Sr.seriesDataToSource(e)),n=n||{},t=(t||[]).slice();for(var o=(n.dimsDef||[]).slice(),l=B(n.encodeDef),u=B(),h=B(),c=[],d=function(t,e,n,i){var r=Math.max(t.dimensionsDetectCount||1,e.length,n.length,i||0);return f(e,function(t){var e=t.dimsDef;e&&(r=Math.max(r,e.length))}),r}(e,t,o,n.dimCount),p=0;d>p;p++){var g=o[p]=a({},b(o[p])?o[p]:{name:o[p]}),m=g.name,v=c[p]={otherDims:{}};null!=m&&null==u.get(m)&&(v.name=v.displayName=m,u.set(m,p)),null!=g.type&&(v.type=g.type),null!=g.displayName&&(v.displayName=g.displayName)}l.each(function(t,e){if(1===(t=$e(t).slice()).length&&!w(t[0])&&t[0]<0)l.set(e,!1);else{var n=l.set(e,[]);f(t,function(t,i){w(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,n,o;if(w(t))e=t,t={};else{e=t.name;var a=t.ordinalMeta;t.ordinalMeta=null,(t=i(t)).ordinalMeta=a,n=t.dimsDef,o=t.otherDims,t.name=t.coordDim=t.coordDimIndex=t.dimsDef=t.otherDims=null}u=l.get(e);if(!1!==u){var u;if(!(u=$e(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,a){var l=c[i];if(r(s(l,t),e,a),null==l.name&&n){var u=n[a];!b(u)&&(u={name:u}),l.name=l.displayName=u.name,l.defaultTooltip=u.defaultTooltip}o&&s(l.otherDims,o)})}});var x=n.generateCoord,_=n.generateCoordCount,S=null!=_;_=x?_||1:0;for(var M=x||"value",I=0;d>I;I++){null==(v=c[I]=c[I]||{}).coordDim&&(v.coordDim=ka(M,h,S),v.coordDimIndex=0,(!x||0>=_)&&(v.isExtraCoord=!0),_--),null==v.name&&(v.name=ka(v.coordDim,u)),null==v.type&&Tr(e,I,v.name)&&(v.type="ordinal")}return c}function ka(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 Pa(t,e,n){var i,r,o,a,s=(n=n||{}).byIndex,l=n.stackedCoordDimension,u=!(!t||!t.get("stack"));if(f(e,function(t,n){w(t)&&(e[n]=t={name:t}),u&&!t.isExtraCoord&&(s||i||!t.ordinalMeta||(i=t),r||"ordinal"===t.type||"time"===t.type||l&&l!==t.coordDim||(r=t))}),!r||s||i||(s=!0),r){o="__\0ecstackresult",a="__\0ecstackedover",i&&(i.createInvertedIndices=!0);var h=r.coordDim,c=r.type,d=0;f(e,function(t){t.coordDim===h&&d++}),e.push({name:o,coordDim:h,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0}),d++,e.push({name:a,coordDim:a,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0})}return{stackedDimension:r&&r.name,stackedByDimension:i&&i.name,isStackedByIndex:s,stackedOverDimension:a,stackResultDimension:o}}function Oa(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function La(t,e){return Oa(t,e)?t.getCalculationInfo("stackResultDimension"):e}function za(t,e,n){n=n||{},Sr.isInstance(t)||(t=Sr.seriesDataToSource(t));var i,r=e.get("coordinateSystem"),o=Lr.get(r),a=wr(e);a&&(i=p(a.coordSysDims,function(t){var e={name:t},n=a.axisMap.get(t);if(n){var i=n.get("type");e.type=function(t){return"category"===t?"ordinal":"time"===t?"time":"float"}(i)}return e})),i||(i=o&&(o.getDimensionsInfo?o.getDimensionsInfo():o.dimensions.slice())||["x","y"]);var s,l,u=Yv(t,{coordDimensions:i,generateCoord:n.generateCoord});a&&f(u,function(t,e){var n=t.coordDim,i=a.categoryAxisMap.get(n);i&&(null==s&&(s=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(l=!0)}),l||null==s||(u[s].otherDims.itemName=0);var h=Pa(e,u),c=new Hv(u,e);c.setCalculationInfo(h);var d=null!=s&&function(t){if(t.sourceFormat===Vg){var e=function(t){for(var e=0;e<t.length&&null==t[e];)e++;return t[e]}(t.data||[]);return null!=e&&!x(Qe(e))}}(t)?function(t,e,n,i){return i===s?n:this.defaultDimValueGetter(t,e,n,i)}:null;return c.hasItemOption=!1,c.initData(t,null,d),c}function Na(t){this._setting=t||{},this._extent=[1/0,-1/0],this._interval=0,this.init&&this.init.apply(this,arguments)}function Ea(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this._map}function Ba(t){return t._map||(t._map=B(t.categories))}function Ra(t){return b(t)&&null!=t.value?t.value:t+""}function Fa(t){return Qi(t)+2}function Va(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function Ga(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),Va(t,0,e),Va(t,1,e),t[0]>t[1]&&(t[0]=t[1])}function Wa(t){return t.get("stack")||Jv+t.seriesIndex}function Ha(t){return t.dim+t.index}function Za(t,e){var n=[];return e.eachSeriesByType(t,function(t){Ua(t)&&!ja(t)&&n.push(t)}),n}function Xa(t){var e=function(t){var e={};f(t,function(t){var n=t.coordinateSystem.getBaseAxis();if("time"===n.type||"value"===n.type)for(var i=t.getData(),r=n.dim+"_"+n.index,o=i.mapDimension(n.dim),a=0,s=i.count();s>a;++a){var l=i.get(o,a);e[r]?e[r].push(l):e[r]=[l]}});var n=[];for(var i in e)if(e.hasOwnProperty(i)){var r=e[i];if(r){r.sort(function(t,e){return t-e});for(var o=null,a=1;a<r.length;++a){var s=r[a]-r[a-1];s>0&&(o=null===o?s:Math.min(o,s))}n[i]=o}}return n}(t),n=[];return f(t,function(t){var i,r=t.coordinateSystem.getBaseAxis(),o=r.getExtent();if("category"===r.type)i=r.getBandWidth();else if("value"===r.type||"time"===r.type){var a=r.dim+"_"+r.index,s=e[a],l=Math.abs(o[1]-o[0]),u=r.scale.getExtent(),h=Math.abs(u[1]-u[0]);i=s?l/h*s:l}else{var c=t.getData();i=Math.abs(o[1]-o[0])/c.count()}var d=ji(t.get("barWidth"),i),f=ji(t.get("barMaxWidth"),i),p=ji(t.get("barMinWidth")||1,i),g=t.get("barGap"),m=t.get("barCategoryGap");n.push({bandWidth:i,barWidth:d,barMaxWidth:f,barMinWidth:p,barGap:g,barCategoryGap:m,axisKey:Ha(r),stackId:Wa(t)})}),function(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:{}},o=r.stacks;e[n]=r;var a=t.stackId;o[a]||r.autoWidthCount++,o[a]=o[a]||{width:0,maxWidth:0};var s=t.barWidth;s&&!o[a].width&&(o[a].width=s,s=Math.min(r.remainedWidth,s),r.remainedWidth-=s);var l=t.barMaxWidth;l&&(o[a].maxWidth=l);var u=t.barMinWidth;u&&(o[a].minWidth=u);var h=t.barGap;null!=h&&(r.gap=h);var c=t.barCategoryGap;null!=c&&(r.categoryGap=c)});var n={};return f(e,function(t,e){n[e]={};var i=t.stacks,r=t.bandWidth,o=ji(t.categoryGap,r),a=ji(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,u=(s-o)/(l+(l-1)*a);u=Math.max(u,0),f(i,function(t){var e=t.maxWidth,n=t.minWidth;if(t.width){i=t.width;e&&(i=Math.min(i,e)),n&&(i=Math.max(i,n)),t.width=i,s-=i,l--}else{var i=u;e&&i>e&&(i=Math.min(e,s)),n&&n>i&&(i=n),i!==u&&(t.width=i,s-=i,l--)}}),u=(s-o)/(l+(l-1)*a),u=Math.max(u,0);var h,c=0;f(i,function(t){t.width||(t.width=u),h=t,c+=t.width*(1+a)}),h&&(c-=h.width*a);var d=-c/2;f(i,function(t,i){n[e][i]=n[e][i]||{bandWidth:r,offset:d,width:t.width},d+=t.width*(1+a)})}),n}(n)}function Ya(t,e,n){if(t&&e){var i=t[Ha(e)];return null!=i&&null!=n&&(i=i[Wa(n)]),i}}function Ua(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}function ja(t){return t.pipelineContext&&t.pipelineContext.large}function qa(t,e){return e.toGlobalCoord(e.dataToCoord("log"===e.type?1:0))}function $a(t,e){return dy(t,cy(e))}function Ka(t,e){var n,i,r,o=t.type,a=e.getMin(),s=e.getMax(),l=null!=a,u=null!=s,h=t.getExtent();"ordinal"===o?n=e.getCategories().length:(i=e.get("boundaryGap"),x(i)||(i=[i||0,i||0]),"boolean"==typeof i[0]&&(i=[0,0]),i[0]=ji(i[0],1),i[1]=ji(i[1],1),r=h[1]-h[0]||Math.abs(h[0])),null==a&&(a="ordinal"===o?n?0:NaN:h[0]-i[0]*r),null==s&&(s="ordinal"===o?n?n-1:NaN:h[1]+i[1]*r),"dataMin"===a?a=h[0]:"function"==typeof a&&(a=a({min:h[0],max:h[1]})),"dataMax"===s?s=h[1]:"function"==typeof s&&(s=s({min:h[0],max:h[1]})),(null==a||!isFinite(a))&&(a=NaN),(null==s||!isFinite(s))&&(s=NaN),t.setBlank(C(a)||C(s)||"ordinal"===o&&!t.getOrdinalMeta().categories.length),e.getNeedCrossZero()&&(a>0&&s>0&&!l&&(a=0),0>a&&0>s&&!u&&(s=0));var c=e.ecModel;if(c&&"time"===o){var d,p=Za("bar",c);if(f(p,function(t){d|=t.getBaseAxis()===e.axis}),d){var g=Xa(p),m=function(t,e,n,i){var r=n.axis.getExtent(),o=r[1]-r[0],a=Ya(i,n.axis);if(void 0===a)return{min:t,max:e};var s=1/0;f(a,function(t){s=Math.min(t.offset,s)});var l=-1/0;f(a,function(t){l=Math.max(t.offset+t.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,h=e-t,c=h/(1-(s+l)/o)-h;return e+=c*(l/u),t-=c*(s/u),{min:t,max:e}}(a,s,e,g);a=m.min,s=m.max}}return[a,s]}function Qa(t,e){var n=Ka(t,e),i=null!=e.getMin(),r=null!=e.getMax(),o=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var a=t.type;t.setExtent(n[0],n[1]),t.niceExtent({splitNumber:o,fixMin:i,fixMax:r,minInterval:"interval"===a||"time"===a?e.get("minInterval"):null,maxInterval:"interval"===a||"time"===a?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function Ja(t,e){if(e=e||t.get("type"))switch(e){case"category":return new qv(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new Qv;default:return(Na.getClass(e)||Qv).create(t)}}function ts(t){var e=t.getLabelModel().get("formatter"),n="category"===t.type?t.scale.getExtent()[0]:null;return"string"==typeof e?e=function(e){return function(n){return n=t.scale.getLabel(n),e.replace("{value}",null!=n?n:"")}}(e):"function"==typeof e?function(i,r){return null!=n&&(r=i-n),e(es(t,i),r)}:function(e){return t.scale.getLabel(e)}}function es(t,e){return"category"===t.type?t.scale.getLabel(e):e}function ns(t){var e=t.model,n=t.scale;if(e.get("axisLabel.show")&&!n.isBlank()){var i,r,o="category"===t.type,a=n.getExtent();o?r=n.count():(i=n.getTicks(),r=i.length);var s,l=t.getLabelModel(),u=ts(t),h=1;r>40&&(h=Math.ceil(r/40));for(var c=0;r>c;c+=h){var d=u(i?i[c]:a[0]+c),f=function(t,e){var n=e*Math.PI/180,i=t.plain(),r=i.width,o=i.height,a=r*Math.cos(n)+o*Math.sin(n),s=r*Math.sin(n)+o*Math.cos(n);return new te(i.x,i.y,a,s)}(l.getTextRect(d),l.get("rotate")||0);s?s.union(f):s=f}return s}}function is(t){var e=t.get("interval");return null==e?"auto":e}function rs(t){return"category"===t.type&&0===is(t.getLabelModel())}function os(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 as(t,e,n,i,r,o,a){var s=0===t.indexOf("empty");s&&(t=t.substr(5,1).toLowerCase()+t.substr(6));var l;return l=0===t.indexOf("image://")?ai(t.slice(8),new te(e,n,i,r),a?"center":"cover"):0===t.indexOf("path://")?oi(t.slice(7),{},new te(e,n,i,r),a?"center":"cover"):new Iy({shape:{symbolType:t,x:e,y:n,width:i,height:r}}),l.__isEmptyBrush=s,l.setColor=os,l.setColor(o),l}function ss(t,e){return Math.abs(t-e)<Ay}function ls(t,e,n){var i=0,r=t[0];if(!r)return!1;for(var o=1;o<t.length;o++){var a=t[o];i+=Fn(r[0],r[1],a[0],a[1],e,n),r=a}var s=t[0];return ss(r[0],s[0])&&ss(r[1],s[1])||(i+=Fn(r[0],r[1],s[0],s[1],e,n)),0!==i}function us(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 hs(t,e,n){for(var i=[],r=e[0],o=e[1],a=0;a<t.length;a+=2){var s=t.charCodeAt(a)-64,l=t.charCodeAt(a+1)-64;s=s>>1^-(1&s),l=l>>1^-(1&l),r=s+=r,o=l+=o,i.push([s/n,l/n])}return i}function cs(t){return"category"===t.type?function(t){var e=t.getLabelModel(),n=fs(t,e);return!e.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:n.labelCategoryInterval}:n}(t):function(t){var e=t.scale.getTicks(),n=ts(t);return{labels:p(e,function(e,i){return{formattedLabel:n(e,i),rawLabel:t.scale.getLabel(e),tickValue:e}})}}(t)}function ds(t,e){return"category"===t.type?function(t,e){var n=ps(t,"ticks"),i=is(e),r=gs(n,i);if(r)return r;var o,a;if((!e.get("show")||t.scale.isBlank())&&(o=[]),_(i))o=ys(t,i,!0);else if("auto"===i){var s=fs(t,t.getLabelModel());a=s.labelCategoryInterval,o=p(s.labels,function(t){return t.tickValue})}else a=i,o=vs(t,a,!0);return ms(n,i,{ticks:o,tickCategoryInterval:a})}(t,e):{ticks:t.scale.getTicks()}}function fs(t,e){var n=ps(t,"labels"),i=is(e),r=gs(n,i);if(r)return r;var o,a;return _(i)?o=ys(t,i):(a="auto"===i?function(t){var e=ky(t).autoInterval;return null!=e?e:ky(t).autoInterval=t.calculateCategoryInterval()}(t):i,o=vs(t,a)),ms(n,i,{labels:o,labelCategoryInterval:a})}function ps(t,e){return ky(t)[e]||(ky(t)[e]=[])}function gs(t,e){for(var n=0;n<t.length;n++)if(t[n].key===e)return t[n].value}function ms(t,e,n){return t.push({key:e,value:n}),n}function vs(t,e,n){function i(t){l.push(n?t:{formattedLabel:r(t),rawLabel:o.getLabel(t),tickValue:t})}var r=ts(t),o=t.scale,a=o.getExtent(),s=t.getLabelModel(),l=[],u=Math.max((e||0)+1,1),h=a[0],c=o.count();0!==h&&u>1&&c/u>2&&(h=Math.round(Math.ceil(h/u)*u));var d=rs(t),f=s.get("showMinLabel")||d,p=s.get("showMaxLabel")||d;f&&h!==a[0]&&i(a[0]);for(var g=h;g<=a[1];g+=u)i(g);return p&&g-u!==a[1]&&i(a[1]),l}function ys(t,e,n){var i=t.scale,r=ts(t),o=[];return f(i.getTicks(),function(t){var a=i.getLabel(t);e(t,a)&&o.push(n?t:{formattedLabel:r(t),rawLabel:a,tickValue:t})}),o}function xs(t,e){var n=(t[1]-t[0])/e/2;t[0]+=n,t[1]-=n}function _s(t){return this._axes[t]}function ws(t){Ey.call(this,t)}function bs(t,e){return e.type||(e.data?"category":"value")}function Ss(t,e){return t.getCoordSysModel()===e}function Ms(t,e,n){this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this._initCartesian(t,e,n),this.model=t}function Is(t,e,n,i){function r(t){return t.dim+"_"+t.index}n.getAxesOnZeroOf=function(){return o?[o]:[]};var o,a=t[e],s=n.model,l=s.get("axisLine.onZero"),u=s.get("axisLine.onZeroAxisIndex");if(l){if(null!=u)Cs(a[u])&&(o=a[u]);else for(var h in a)if(a.hasOwnProperty(h)&&Cs(a[h])&&!i[r(a[h])]){o=a[h];break}o&&(i[r(o)]=!0)}}function Cs(t){return t&&"category"!==t.type&&"time"!==t.type&&function(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(n>0&&i>0||0>n&&0>i)}(t)}function Ts(t){return p(Xy,function(e){return t.getReferringComponents(e)[0]})}function As(t){return"cartesian2d"===t.get("coordinateSystem")}function Ds(t,e){var n=t.mapDimension("defaultedLabel",!0),i=n.length;if(1===i)return Jr(t,e,n[0]);if(i){for(var r=[],o=0;o<n.length;o++){var a=Jr(t,e,n[o]);r.push(a)}return r.join(" ")}}function ks(t,e){"outside"===t.textPosition&&(t.textPosition=e)}function Ps(t,e,n){var i=t.getArea(),r=t.getBaseAxis().isHorizontal(),o=i.x,a=i.y,s=i.width,l=i.height,u=n.get("lineStyle.width")||2,h=new Vp({shape:{x:o-=u/2,y:a-=u/2,width:s+=u,height:l+=u}});return e&&(h.shape[r?"width":"height"]=0,zi(h,{shape:{width:s,height:l}},n)),h}function Os(t,e,n){var i=t.getArea(),r=new Op({shape:{cx:qi(t.cx,1),cy:qi(t.cy,1),r0:qi(i.r0,1),r:qi(i.r,1),startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}});return e&&(r.shape.endAngle=i.startAngle,zi(r,{shape:{endAngle:i.endAngle}},n)),r}function Ls(t,e,n){n.style.text=null,Li(n,{shape:{width:0}},e,t,function(){n.parent&&n.parent.remove(n)})}function zs(t,e,n){n.style.text=null,Li(n,{shape:{r:n.shape.r0}},e,t,function(){n.parent&&n.parent.remove(n)})}function Ns(t,e,n,i,r,o,a,l){var u=e.getItemVisual(n,"color"),h=e.getItemVisual(n,"opacity"),c=i.getModel("itemStyle"),d=i.getModel("emphasis.itemStyle").getBarItemStyle();l||t.setShape("r",c.get("barBorderRadius")||0),t.useStyle(s({fill:u,opacity:h},c.getBarItemStyle()));var f=i.getShallow("cursor");f&&t.attr("cursor",f);a?r.height:r.width;l||function(t,e,n,i,r,o){Mi(t,e,n.getModel("label"),n.getModel("emphasis.label"),{labelFetcher:r,labelDataIndex:o,defaultText:Ds(r.getData(),o),isRectText:!0,autoColor:i}),ks(t),ks(e)}(t.style,d,i,u,o,n),_i(t,d)}function Es(t,e,n){var i=t.getData(),r=[],o=i.getLayout("valueAxisHorizontal")?1:0;r[1-o]=i.getLayout("valueAxisStart");var a=new nx({shape:{points:i.getLayout("largePoints")},incremental:!!n,__startPoint:r,__baseDimIdx:o,__largeDataIndices:i.getLayout("largeDataIndices"),__barWidth:i.getLayout("barWidth")});e.add(a),function(t,e,n){var i=n.getVisual("borderColor")||n.getVisual("color"),r=e.getModel("itemStyle").getItemStyle(["color","borderColor"]);t.useStyle(r),t.style.fill=null,t.style.stroke=i,t.style.lineWidth=n.getLayout("barWidth")}(a,t,i),a.seriesIndex=t.seriesIndex,t.get("silent")||(a.on("mousedown",ix),a.on("mousemove",ix))}function Bs(t){t&&(t.ignore=!0)}function Rs(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=gt([]);return xt(r,r,-t.rotation),n.applyTransform(vt([],r,t.getLocalTransform())),i.applyTransform(vt([],r,e.getLocalTransform())),n.intersect(i)}}function Fs(t){return"middle"===t||"center"===t}function Vs(t,e){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return function(t,e,n){var i=e.getComponent("tooltip"),r=e.getComponent("axisPointer"),o=r.get("link",!0)||[],a=[];hx(n.getCoordinateSystems(),function(n){function s(i,s,l){var c=l.model.getModel("axisPointer",r),d=c.get("show");if(d&&("auto"!==d||i||Zs(c))){null==s&&(s=c.get("triggerTooltip"));var f=(c=i?Gs(l,h,r,e,i,s):c).get("snap"),p=Xs(l.model),g=s||f||"category"===l.type,m=t.axesInfo[p]={key:p,axis:l,coordSys:n,axisPointerModel:c,triggerTooltip:s,involveSeries:g,snap:f,useHandle:Zs(c),seriesModels:[]};u[p]=m,t.seriesInvolved|=g;var v=function(t,e){for(var n=e.model,i=e.dim,r=0;r<t.length;r++){var o=t[r]||{};if(Ws(o[i+"AxisId"],n.id)||Ws(o[i+"AxisIndex"],n.componentIndex)||Ws(o[i+"AxisName"],n.name))return r}}(o,l);if(null!=v){var y=a[v]||(a[v]={axesInfo:{}});y.axesInfo[p]=m,y.mapper=o[v].mapper,m.linkGroup=y}}}if(n.axisPointerEnabled){var l=Xs(n.model),u=t.coordSysAxesInfo[l]={};t.coordSysMap[l]=n;var h=n.model.getModel("tooltip",i);if(hx(n.getAxes(),cx(s,!1,null)),n.getTooltipAxes&&i&&h.get("show")){var c="axis"===h.get("trigger"),d="cross"===h.get("axisPointer.type"),f=n.getTooltipAxes(h.get("axisPointer.axis"));(c||d)&&hx(f.baseAxes,cx(s,!d||"cross",c)),d&&hx(f.otherAxes,cx(s,"cross",!1))}}})}(n,t,e),n.seriesInvolved&&function(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&&!1!==i&&"item"!==i&&!1!==r&&!1!==e.get("axisPointer.show",!0)&&hx(t.coordSysAxesInfo[Xs(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)}(n,t),n}function Gs(t,e,n,r,o,a){var l=e.getModel("axisPointer"),u={};hx(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){u[t]=i(l.get(t))}),u.snap="category"!==t.type&&!!a,"cross"===l.get("type")&&(u.type="line");var h=u.label||(u.label={});if(null==h.show&&(h.show=!1),"cross"===o){var c=l.get("label.show");if(h.show=null==c||c,!a){var d=u.lineStyle=l.get("crossStyle");d&&s(h,d.textStyle)}}return t.model.getModel("axisPointer",new Hi(u,n,r))}function Ws(t,e){return"all"===t||x(t)&&u(t,e)>=0||t===e}function Hs(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[Xs(t)]}function Zs(t){return!!t.get("handle.show")}function Xs(t){return t.type+"||"+t.id}function Ys(t,e,n,i,r,o){var a=dx.getAxisPointerClass(t.axisPointerClass);if(a){var s=function(t){var e=Hs(t);return e&&e.axisPointerModel}(e);s?(t._axisPointer||(t._axisPointer=new a)).render(e,s,i,o):Us(t,i)}}function Us(t,e,n){var i=t._axisPointer;i&&i.dispose(e,n),t._axisPointer=null}function js(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,o={},a=r.getAxesOnZeroOf()[0],s=r.position,l=a?"onZero":s,u=r.dim,h=i.getRect(),c=[h.x,h.x+h.width,h.y,h.y+h.height],d={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p="x"===u?[c[2]-f,c[3]+f]:[c[0]-f,c[1]+f];if(a){var g=a.toGlobalCoord(a.dataToCoord(0));p[d.onZero]=Math.max(Math.min(g,p[1]),p[0])}o.position=["y"===u?p[d[l]]:c[0],"x"===u?p[d[l]]:c[3]],o.rotation=Math.PI/2*("x"===u?0:1);o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],o.labelOffset=a?p[d[s]]-p[d.onZero]:0,e.get("axisTick.inside")&&(o.tickDirection=-o.tickDirection),T(n.labelInside,e.get("axisLabel.inside"))&&(o.labelDirection=-o.labelDirection);var m=e.get("axisLabel.rotate");return o.labelRotate="top"===l?-m:m,o.z2=1,o}function qs(t,e,n){yd.call(this),this.updateData(t,e,n)}function $s(t){return[t[0]/2,t[1]/2]}function Ks(t,e){this.parent.drift(t,e)}function Qs(t){this.group=new yd,this._symbolCtor=t||qs}function Js(t,e,n,i){return!(!e||isNaN(e[0])||isNaN(e[1])||i.isIgnore&&i.isIgnore(n)||i.clipShape&&!i.clipShape.contain(e[0],e[1])||"none"===t.getItemVisual(n,"symbol"))}function tl(t){return null==t||b(t)||(t={isIgnore:t}),t||{}}function el(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 nl(t,e,n){var i,r=t.getBaseAxis(),o=t.getOtherAxis(r),a=function(t,e){var n=0,i=t.scale.getExtent();return"start"===e?n=i[0]:"end"===e?n=i[1]:i[0]>0?n=i[0]:i[1]<0&&(n=i[1]),n}(o,n),s=r.dim,l=o.dim,u=e.mapDimension(l),h=e.mapDimension(s),c="x"===l||"radius"===l?1:0,d=p(t.dimensions,function(t){return e.mapDimension(t)}),f=e.getCalculationInfo("stackResultDimension");return(i|=Oa(e,d[0]))&&(d[0]=f),(i|=Oa(e,d[1]))&&(d[1]=f),{dataDimsForPoint:d,valueStart:a,valueAxisDim:l,baseAxisDim:s,stacked:!!i,valueDim:u,baseDim:h,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function il(t,e,n,i){var r=NaN;t.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=t.valueStart);var o=t.baseDataOffset,a=[];return a[o]=n.get(t.baseDim,i),a[1-o]=r,e.dataToPoint(a)}function rl(t){return isNaN(t[0])||isNaN(t[1])}function ol(t,e,n,i,r,o,a,s,l,u){return"none"!==u&&u?function(t,e,n,i,r,o,a,s,l,u,h){for(var c=0,d=n,f=0;i>f;f++){var p=e[d];if(d>=r||0>d)break;if(rl(p)){if(h){d+=o;continue}break}if(d===n)t[o>0?"moveTo":"lineTo"](p[0],p[1]);else if(l>0){var g=e[c],m="y"===u?1:0,v=(p[m]-g[m])*l;Ax(kx,g),kx[m]=g[m]+v,Ax(Px,p),Px[m]=p[m]-v,t.bezierCurveTo(kx[0],kx[1],Px[0],Px[1],p[0],p[1])}else t.lineTo(p[0],p[1]);c=d,d+=o}return f}.apply(this,arguments):function(t,e,n,i,r,o,a,s,l,u,h){for(var c=0,d=n,f=0;i>f;f++){var p=e[d];if(d>=r||0>d)break;if(rl(p)){if(h){d+=o;continue}break}if(d===n)t[o>0?"moveTo":"lineTo"](p[0],p[1]),Ax(kx,p);else if(l>0){var g=d+o,m=e[g];if(h)for(;m&&rl(e[g]);)g+=o,m=e[g];var v=.5,y=e[c];if(!(m=e[g])||rl(m))Ax(Px,p);else{rl(m)&&!h&&(m=p),Z(Dx,m,y);var x,_;if("x"===u||"y"===u){var w="x"===u?0:1;x=Math.abs(p[w]-y[w]),_=Math.abs(p[w]-m[w])}else x=Mc(p,y),_=Mc(p,m);Tx(Px,p,Dx,-l*(1-(v=_/(_+x))))}Ix(kx,kx,s),Cx(kx,kx,a),Ix(Px,Px,s),Cx(Px,Px,a),t.bezierCurveTo(kx[0],kx[1],Px[0],Px[1],p[0],p[1]),Tx(kx,p,Dx,l*v)}else t.lineTo(p[0],p[1]);c=d,d+=o}return f}.apply(this,arguments)}function al(t,e){var n=[1/0,1/0],i=[-1/0,-1/0];if(e)for(var r=0;r<t.length;r++){var o=t[r];o[0]<n[0]&&(n[0]=o[0]),o[1]<n[1]&&(n[1]=o[1]),o[0]>i[0]&&(i[0]=o[0]),o[1]>i[1]&&(i[1]=o[1])}return{min:e?n:i,max:e?i:n}}function sl(t,e){if(t.length===e.length){for(var n=0;n<t.length;n++){var i=t[n],r=e[n];if(i[0]!==r[0]||i[1]!==r[1])return}return!0}}function ll(t){return"number"==typeof t?t:t?.5:0}function ul(t,e,n){for(var i=e.getBaseAxis(),r="x"===i.dim||"radius"===i.dim?0:1,o=[],a=0;a<t.length-1;a++){var s=t[a+1],l=t[a];o.push(l);var u=[];switch(n){case"end":u[r]=s[r],u[1-r]=l[1-r],o.push(u);break;case"middle":var h=(l[r]+s[r])/2,c=[];u[r]=c[r]=h,u[1-r]=l[1-r],c[1-r]=s[1-r],o.push(u),o.push(c);break;default:u[r]=l[r],u[1-r]=s[1-r],o.push(u)}}return t[a]&&o.push(t[a]),o}function hl(t,e){var n=t.getVisual("visualMeta");if(n&&n.length&&t.count()&&"cartesian2d"===e.type){for(var i,r,o=n.length-1;o>=0;o--){var a=n[o].dimension,s=t.dimensions[a],l=t.getDimensionInfo(s);if("x"===(i=l&&l.coordDim)||"y"===i){r=n[o];break}}if(r){var u=e.getAxis(i),h=p(r.stops,function(t){return{coord:u.toGlobalCoord(u.dataToCoord(t.value)),color:t.color}}),c=h.length,d=r.outerColors.slice();c&&h[0].coord>h[c-1].coord&&(h.reverse(),d.reverse());var g=h[0].coord-10,m=h[c-1].coord+10,v=m-g;if(.001>v)return"transparent";f(h,function(t){t.offset=(t.coord-g)/v}),h.push({offset:c?h[c-1].offset:.5,color:d[1]||"transparent"}),h.unshift({offset:c?h[0].offset:.5,color:d[0]||"transparent"});var y=new jp(0,0,0,0,h,!0);return y[i]=g,y[i+"2"]=m,y}}}function cl(t,e,n){var i=t.get("showAllSymbol"),r="auto"===i;if(!i||r){var o=n.getAxesByScale("ordinal")[0];if(o&&(!r||!function(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var r=e.count(),o=Math.max(1,Math.round(r/5)),a=0;r>a;a+=o)if(1.5*qs.getSymbolSize(e,a)[t.isHorizontal()?1:0]>i)return!1;return!0}(o,e))){var a=e.mapDimension(o.dim),s={};return f(o.getViewLabels(),function(t){s[t.tickValue]=1}),function(t){return!s.hasOwnProperty(e.get(a,t))}}}}function dl(t,e,n){if("cartesian2d"===t.type){var i=t.getBaseAxis().isHorizontal(),r=Ps(t,e,n);if(!n.get("clip",!0)){var o=r.shape,a=Math.max(o.width,o.height);i?(o.y-=a,o.height+=2*a):(o.x-=a,o.width+=2*a)}return r}return Os(t,e,n)}function fl(t,e,n,i){var r=e.getData(),o=this.dataIndex,a=r.getName(o),s=e.get("selectedOffset");i.dispatchAction({type:"pieToggleSelect",from:t,name:a,seriesId:e.id}),r.each(function(t){pl(r.getItemGraphicEl(t),r.getItemLayout(t),e.isSelected(r.getName(t)),s,n)})}function pl(t,e,n,i,r){var o=(e.startAngle+e.endAngle)/2,a=Math.cos(o),s=Math.sin(o),l=n?i:0,u=[a*l,s*l];r?t.animate().when(200,{position:u}).start("bounceOut"):t.attr("position",u)}function gl(t,e){yd.call(this);var n=new Op({z2:2}),i=new Bp,r=new Ap;this.add(n),this.add(i),this.add(r),this.updateData(t,e,!0)}function ml(t,e,n,i,r,o,a){function s(e,n,i){for(var r=e;n>r;r++)if(t[r].y+=i,r>e&&n>r+1&&t[r+1].y>t[r].y+t[r].height)return void l(r,i/2);l(n-1,i/2)}function l(e,n){for(var i=e;i>=0&&(t[i].y-=n,!(i>0&&t[i].y>t[i-1].y+t[i-1].height));i--);}function u(t,e,n,i,r,o){for(var a=e?Number.MAX_VALUE:0,s=0,l=t.length;l>s;s++){var u=Math.abs(t[s].y-i),h=t[s].len,c=t[s].len2,d=r+h>u?Math.sqrt((r+h+c)*(r+h+c)-u*u):Math.abs(t[s].x-n);e&&d>=a&&(d=a-10),!e&&a>=d&&(d=a+10),t[s].x=n+d*o,a=d}}t.sort(function(t,e){return t.y-e.y});for(var h,c=0,d=t.length,f=[],p=[],g=0;d>g;g++)0>(h=t[g].y-c)&&s(g,d,-h),c=t[g].y+t[g].height;0>a-c&&l(d-1,c-a);for(g=0;d>g;g++)t[g].y>=n?p.push(t[g]):f.push(t[g]);u(f,!1,e,n,i,r),u(p,!0,e,n,i,r)}function vl(t){return"center"===t.position}function yl(t,e,n){var i,r={},o="toggleSelected"===t;return n.eachComponent("legend",function(n){o&&null!=i?n[i?"select":"unSelect"](e.name):"allSelect"===t||"inverseSelect"===t?n[t]():(n[t](e.name),i=n.isSelected(e.name));f(n.getData(),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}})}),"allSelect"===t||"inverseSelect"===t?{selected:r}:{name:e.name,selected:r}}function xl(t,e){var n=wg(e.get("padding")),i=e.getItemStyle(["color","opacity"]);i.fill=e.get("backgroundColor");return t=new Vp({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})}function _l(t,e,n,i,r,o){var a;return"line"!==e&&e.indexOf("empty")<0?(a=n.getItemStyle(),t.style.stroke=i,o||(a.stroke=r)):a=n.getItemStyle(["borderWidth","borderColor"]),t.setStyle(a)}function wl(t,e){e.dispatchAction({type:"legendToggleSelect",name:t})}function bl(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"highlight",seriesName:t,name:e,excludeSeriesId:i})}function Sl(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"downplay",seriesName:t,name:e,excludeSeriesId:i})}function Ml(t,e,n){var i=[1,1];i[t.getOrient().index]=0,yr(e,n,{type:"box",ignoreSize:i})}function Il(t,e,n,i,r){var o=t.axis;if(!o.scale.isBlank()&&o.containData(e)){if(!t.involveSeries)return void n.showPointer(t,e);var s=function(t,e){var n=e.axis,i=n.dim,r=t,o=[],a=Number.MAX_VALUE,s=-1;return i_(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,"category"===n.type?.5:null)).length)return;l=e.getData().get(h[0],u[0])}if(null!=l&&isFinite(l)){var d=t-l,f=Math.abs(d);a>=f&&((a>f||d>=0&&0>s)&&(a=f,s=d,r=l,o.length=0),i_(u,function(t){o.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:o,snapToValue:r}}(e,t),l=s.payloadBatch,u=s.snapToValue;l[0]&&null==r.seriesIndex&&a(r,l[0]),!i&&t.snap&&o.containData(u)&&null!=u&&(e=u),n.showPointer(t,e,l,r),n.showTooltip(t,s,u)}}function Cl(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function Tl(t,e,n,i){var r=n.payloadBatch,o=e.axis,a=o.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,u=Xs(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:o.dim,axisIndex:a.componentIndex,axisType:a.type,axisId:a.id,value:i,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:r.slice()})}}function Al(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",o=o_(i)[r]||{},a=o_(i)[r]={};i_(t,function(t){var e=t.axisPointerModel.option;"show"===e.status&&i_(e.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;a[e]=t})});var s=[],l=[];f(o,function(t,e){!a[e]&&l.push(t)}),f(a,function(t,e){!o[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 Dl(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 kl(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function Pl(t,e,n){if(!ac.node){var i=e.getZr();a_(i).records||(a_(i).records={}),function(t,e){function n(n,i){t.on(n,function(n){var r=function(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}}(e);s_(a_(t).records,function(t){t&&i(t,n,r.dispatchAction)}),function(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))}(r.pendings,e)})}a_(t).initialized||(a_(t).initialized=!0,n("click",y(Ll,"click")),n("mousemove",y(Ll,"mousemove")),n("globalout",Ol))}(i,e);(a_(i).records[t]||(a_(i).records[t]={})).handler=n}}function Ol(t,e,n){t.handler("leave",null,n)}function Ll(t,e,n,i){e.handler(t,n,i)}function zl(t,e){if(!ac.node){var n=e.getZr();(a_(n).records||{})[t]&&(a_(n).records[t]=null)}}function Nl(){}function El(t,e,n,i){Bl(u_(n).lastProp,i)||(u_(n).lastProp=i,e?Li(n,i,t):(n.stopAnimation(),n.attr(i)))}function Bl(t,e){if(b(t)&&b(e)){var n=!0;return f(e,function(e,i){n=n&&Bl(t[i],e)}),!!n}return t===e}function Rl(t,e){t[e.get("label.show")?"show":"hide"]()}function Fl(t){return{position:t.position.slice(),rotation:t.rotation||0}}function Vl(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 Gl(t,e,n,i,r){var o=Wl(n.get("value"),e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get("label.precision"),formatter:n.get("label.formatter")}),a=n.getModel("label"),s=wg(a.get("padding")||0),l=a.getFont(),u=pe(o,l),h=r.position,c=u.width+s[1]+s[3],d=u.height+s[0]+s[2],f=r.align;"right"===f&&(h[0]-=c),"center"===f&&(h[0]-=c/2);var p=r.verticalAlign;"bottom"===p&&(h[1]-=d),"middle"===p&&(h[1]-=d/2),function(t,e,n,i){var r=i.getWidth(),o=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,o)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}(h,c,d,i);var g=a.get("backgroundColor");g&&"auto"!==g||(g=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:c,height:d,r:a.get("borderRadius")},position:h.slice(),style:{text:o,textFont:l,textFill:a.getTextColor(),textPosition:"inside",textPadding:s,fill:g,stroke:a.get("borderColor")||"transparent",lineWidth:a.get("borderWidth")||0,shadowBlur:a.get("shadowBlur"),shadowColor:a.get("shadowColor"),shadowOffsetX:a.get("shadowOffsetX"),shadowOffsetY:a.get("shadowOffsetY")},z2:10}}function Wl(t,e,n,i,r){t=e.scale.parse(t);var o=e.scale.getLabel(t,{precision:r.precision}),a=r.formatter;if(a){var s={value:es(e,t),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};f(i,function(t){var e=n.getSeriesByIndex(t.seriesIndex),i=t.dataIndexInside,r=e&&e.getDataParams(i);r&&s.seriesData.push(r)}),w(a)?o=a.replace("{value}",o):_(a)&&(o=a(s))}return o}function Hl(t,e,n){var i=pt();return xt(i,i,n.rotation),yt(i,i,n.position),Ei([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function Zl(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}function Xl(t){return"x"===t.dim?0:1}function Yl(t){var e=[],n=t.get("transitionDuration"),i=t.get("backgroundColor"),r=t.getModel("textStyle"),o=t.get("padding");return n&&e.push(function(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",n="left "+t+"s "+e+",top "+t+"s "+e;return p(m_,function(t){return t+"transition:"+n}).join(";")}(n)),i&&(ac.canvasSupported?e.push("background-Color:"+i):(e.push("background-Color:#"+Et(i)),e.push("filter:alpha(opacity=70)"))),p_(["width","color","radius"],function(n){var i="border-"+n,r=g_(i),o=t.get(r);null!=o&&e.push(i+":"+o+("color"===n?"":"px"))}),e.push(function(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"),p_(["decoration","align"],function(n){var i=t.get(n);i&&e.push("text-"+n+":"+i)}),e.join(";")}(r)),null!=o&&e.push("padding:"+wg(o).join("px ")+"px"),e.join(";")+";"}function Ul(t,e){if(ac.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;at(t,e,!0),n.dispatch("mousemove",e)}},n.onmouseleave=function(){r._enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1}}function jl(t){this._zr=t.getZr(),this._show=!1,this._hideTimeout}function ql(t){for(var e=t.pop();t.length;){var n=t.pop();n&&(Hi.isInstance(n)&&(n=n.get("tooltip",!0)),"string"==typeof n&&(n={formatter:n}),e=new Hi(n,e,e.ecModel))}return e}function $l(t,e){return t.dispatchAction||v(e.dispatchAction,e)}function Kl(t){return"center"===t||"middle"===t}function Ql(t){Ke(t,"label",["show"])}function Jl(t,e,n,i,r,o){var a=[],s=Oa(e,i)?e.getCalculationInfo("stackResultDimension"):i,l=ru(e,s,t),u=e.indicesOfNearest(s,l)[0];a[r]=e.get(n,u),a[o]=e.get(i,u);var h=Ki(e.get(i,u));return(h=Math.min(h,20))>=0&&(a[o]=+a[o].toFixed(h)),a}function tu(t,e){var n=t.getData(),r=t.coordinateSystem;if(e&&!function(t){return!isNaN(parseFloat(t.x))&&!isNaN(parseFloat(t.y))}(e)&&!x(e.coord)&&r){var o=r.dimensions,a=eu(e,n,r,t);if((e=i(e)).type&&C_[e.type]&&a.baseAxis&&a.valueAxis){var s=M_(o,a.baseAxis.dim),l=M_(o,a.valueAxis.dim);e.coord=C_[e.type](n,a.baseDataDim,a.valueDataDim,s,l),e.value=e.coord[l]}else{for(var u=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis],h=0;2>h;h++)C_[u[h]]&&(u[h]=ru(n,n.mapDimension(o[h]),u[h]));e.coord=u}}return e}function eu(t,e,n,i){var r={};return null!=t.valueIndex||null!=t.valueDim?(r.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,r.valueAxis=n.getAxis(function(t,e){var n=t.getData(),i=n.dimensions;e=n.getDimension(e);for(var r=0;r<i.length;r++){var o=n.getDimensionInfo(i[r]);if(o.name===e)return o.coordDim}}(i,r.valueDataDim)),r.baseAxis=n.getOtherAxis(r.valueAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim)):(r.baseAxis=i.getBaseAxis(),r.valueAxis=n.getOtherAxis(r.baseAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim),r.valueDataDim=e.mapDimension(r.valueAxis.dim)),r}function nu(t,e){return!(t&&t.containData&&e.coord&&!function(t){return!(isNaN(parseFloat(t.x))&&isNaN(parseFloat(t.y)))}(e))||t.containData(e.coord)}function iu(t,e,n,i){return 2>i?t.coord&&t.coord[i]:t.value}function ru(t,e,n){if("average"===n){var i=0,r=0;return t.each(e,function(t){isNaN(t)||(i+=t,r++)}),i/r}return"median"===n?t.getMedian(e):t.getDataExtent(e,!0)["max"===n?1:0]}function ou(t,e,n){var i=e.coordinateSystem;t.each(function(r){var o,a=t.getItemModel(r),s=ji(a.get("x"),n.getWidth()),l=ji(a.get("y"),n.getHeight());if(isNaN(s)||isNaN(l)){if(e.getMarkerPosition)o=e.getMarkerPosition(t.getValues(t.dimensions,r));else if(i){var u=t.get(i.dimensions[0],r),h=t.get(i.dimensions[1],r);o=i.dataToPoint([u,h])}}else o=[s,l];isNaN(s)||(o[0]=s),isNaN(l)||(o[1]=l),t.setItemLayout(r,o)})}function au(t,e,n){var i;i=t?p(t&&t.dimensions,function(t){return s({name:t},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{})}):[{name:"value",type:"float"}];var r=new Hv(i,n),o=p(n.get("data"),y(tu,e));return t&&(o=m(o,y(nu,t))),r.initData(o,null,t?iu:function(t){return t.value}),r}function su(t){return isNaN(+t.cpx1)||isNaN(+t.cpy1)}function lu(t){return"_"+t+"Type"}function uu(t,e,n){var i=e.getItemVisual(n,"color"),r=e.getItemVisual(n,t),o=e.getItemVisual(n,t+"Size");if(r&&"none"!==r){x(o)||(o=[o,o]);var a=as(r,-o[0]/2,-o[1]/2,o[0],o[1],i);return a.name=t,a}}function hu(t,e){t.x1=e[0][0],t.y1=e[0][1],t.x2=e[1][0],t.y2=e[1][1],t.percent=1;var n=e[2];n?(t.cpx1=n[0],t.cpy1=n[1]):(t.cpx1=NaN,t.cpy1=NaN)}function cu(t,e,n){yd.call(this),this._createLine(t,e,n)}function du(t){this._ctor=t||cu,this.group=new yd}function fu(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 pu(t){return isNaN(t[0])||isNaN(t[1])}function gu(t){return!pu(t[0])&&!pu(t[1])}function mu(t){return!isNaN(t)&&!isFinite(t)}function vu(t,e,n,i){var r=1-t,o=i.dimensions[t];return mu(e[r])&&mu(n[r])&&e[t]===n[t]&&i.getAxis(o).containData(e[t])}function yu(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(vu(1,n,i,t)||vu(0,n,i,t)))return!0}return nu(t,e[0])&&nu(t,e[1])}function xu(t,e,n,i,r){var o,a=i.coordinateSystem,s=t.getItemModel(e),l=ji(s.get("x"),r.getWidth()),u=ji(s.get("y"),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition)o=i.getMarkerPosition(t.getValues(t.dimensions,e));else{var h=a.dimensions,c=t.get(h[0],e),d=t.get(h[1],e);o=a.dataToPoint([c,d])}if("cartesian2d"===a.type){var f=a.getAxis("x"),p=a.getAxis("y"),h=a.dimensions;mu(t.get(h[0],e))?o[0]=f.toGlobalCoord(f.getExtent()[n?0:1]):mu(t.get(h[1],e))&&(o[1]=p.toGlobalCoord(p.getExtent()[n?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}else o=[l,u];t.setItemLayout(e,o)}function _u(t,e,n){var i;i=t?p(t&&t.dimensions,function(t){return s({name:t},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{})}):[{name:"value",type:"float"}];var r=new Hv(i,n),o=new Hv(i,n),a=new Hv([],n),l=p(n.get("data"),y(z_,e,t,n));t&&(l=m(l,y(yu,t)));var u=t?iu:function(t){return t.value};return r.initData(p(l,function(t){return t[0]}),null,u),o.initData(p(l,function(t){return t[1]}),null,u),a.initData(p(l,function(t){return t[2]})),a.hasItemOption=!0,{from:r,to:o,line:a}}function wu(t){return!isNaN(t)&&!isFinite(t)}function bu(t,e,n){var i=1-t;return wu(e[i])&&wu(n[i])}function Su(t,e){var n=e.coord[0],i=e.coord[1];return!("cartesian2d"!==t.type||!n||!i||!bu(1,n,i)&&!bu(0,n,i))||(nu(t,{coord:n,x:e.x0,y:e.y0})||nu(t,{coord:i,x:e.x1,y:e.y1}))}function Mu(t,e,n,i,r){var o,a=i.coordinateSystem,s=t.getItemModel(e),l=ji(s.get(n[0]),r.getWidth()),u=ji(s.get(n[1]),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition)o=i.getMarkerPosition(t.getValues(n,e));else{var h=[f=t.get(n[0],e),p=t.get(n[1],e)];a.clampData&&a.clampData(h,h),o=a.dataToPoint(h,!0)}if("cartesian2d"===a.type){var c=a.getAxis("x"),d=a.getAxis("y"),f=t.get(n[0],e),p=t.get(n[1],e);wu(f)?o[0]=c.toGlobalCoord(c.getExtent()["x0"===n[0]?0:1]):wu(p)&&(o[1]=d.toGlobalCoord(d.getExtent()["y0"===n[1]?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}else o=[l,u];return o}function Iu(t){var e=t.itemStyle||(t.itemStyle={}),n=e.emphasis||(e.emphasis={}),i=t.label||t.label||{},r=i.normal||(i.normal={}),o={normal:1,emphasis:1};f(i,function(t,e){o[e]||Cu(r,e)||(r[e]=t)}),n.label&&!Cu(i,"emphasis")&&(i.emphasis=n.label,delete n.label)}function Cu(t,e){return t.hasOwnProperty(e)}function Tu(t,e,n,r){return oi(t.get(e).replace(/^path:\/\//,""),i(r||{}),new te(n[0],n[1],n[2],n[3]),"center")}function Au(t,e,n,i,o,a){var s=e.get("color");if(o)o.setColor(s),n.add(o),a&&a.onUpdate(o);else{(o=as(t.get("symbol"),-1,-1,2,2,s)).setStyle("strokeNoScale",!0),n.add(o),a&&a.onCreate(o)}var l=e.getItemStyle(["color","symbol","symbolSize"]);o.setStyle(l),i=r({rectHover:!0,z2:100},i,!0);var u=t.get("symbolSize");(u=u instanceof Array?u.slice():[+u,+u])[0]/=2,u[1]/=2,i.scale=u;var h=t.get("symbolOffset");if(h){var c=i.position=i.position||[0,0];c[0]+=ji(h[0],u[0]),c[1]+=ji(h[1],u[1])}var d=t.get("symbolRotate");return i.rotation=(d||0)*Math.PI/180||0,o.attr(i),o.updateTransform(),o}function Du(t,e,n,i,r){if(!t.dragging){var o=i.getModel("checkpointStyle"),a=n.dataToCoord(i.getData().get(["value"],e));r||!o.get("animation",!0)?t.attr({position:[a,0]}):(t.stopAnimation(!0),t.animateTo({position:[a,0]},o.get("animationDuration",!0),o.get("animationEasing",!0)))}}function ku(t,e,n){function i(t,i){var r=!1;return e(function(e){f(n(t,e)||[],function(t){i.records[e.name][t]&&(r=!0)})}),r}function r(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){!function(t,e){return u(e.nodes,t)>=0}(t,a)&&i(t,a)&&(r(t,a),s=!0)}var a={nodes:[],records:{}};if(e(function(t){a.records[t.name]={}}),!n)return a;r(n,a);var s;do{s=!1,t(o)}while(s);return a}}function Pu(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 Ou(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}function Lu(t,e){var n=t.getAxisModel(),i=t._percentWindow,r=t._valueWindow;if(i){var o=Ji(r,[0,500]);o=Math.min(o,20);var a=e||0===i[0]&&100===i[1];n.setRange(a?null:+r[0].toFixed(o),a?null:+r[1].toFixed(o))}}function zu(t){var e={};return q_(["start","end","startValue","endValue","throttle"],function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e}function Nu(t,e){var n=t._rangePropMode,i=t.get("rangeMode");q_([["start","startValue"],["end","endValue"]],function(t,r){var o=null!=e[t[0]],a=null!=e[t[1]];o&&!a?n[r]="percent":!o&&a?n[r]="value":i?n[r]=i[r]:o&&(n[r]="percent")})}function Eu(t){return"vertical"===t?"ns-resize":"ew-resize"}function Bu(t,e){return!!Ru(t)[e]}function Ru(t){return t[uw]||(t[uw]={})}function Fu(t){this.pointerChecker,this._zr=t,this._opt={};var e=v,n=e(Vu,this),r=e(Gu,this),o=e(Wu,this),a=e(Hu,this),l=e(Zu,this);Ac.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,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),null==e&&(e=!0),(!0===e||"move"===e||"pan"===e)&&(t.on("mousedown",n),t.on("mousemove",r),t.on("mouseup",o)),(!0===e||"scale"===e||"zoom"===e)&&(t.on("mousewheel",a),t.on("pinch",l))},this.disable=function(){t.off("mousedown",n),t.off("mousemove",r),t.off("mouseup",o),t.off("mousewheel",a),t.off("pinch",l)},this.dispose=this.disable,this.isDragging=function(){return this._dragging},this.isPinching=function(){return this._pinching}}function Vu(t){if(!(ut(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 Gu(t){if(this._dragging&&Uu("moveOnMouseMove",t,this._opt)&&"pinch"!==t.gestureEvent&&!Bu(this._zr,"globalPan")){var e=t.offsetX,n=t.offsetY,i=this._x,r=this._y,o=e-i,a=n-r;this._x=e,this._y=n,this._opt.preventDefaultMouseMove&&zc(t.event),Yu(this,"pan","moveOnMouseMove",t,{dx:o,dy:a,oldX:i,oldY:r,newX:e,newY:n})}}function Wu(t){ut(t)||(this._dragging=!1)}function Hu(t){var e=Uu("zoomOnMouseWheel",t,this._opt),n=Uu("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,r=Math.abs(i),o=t.offsetX,a=t.offsetY;if(0!==i&&(e||n)){if(e){var s=r>3?1.4:r>1?1.2:1.1;Xu(this,"zoom","zoomOnMouseWheel",t,{scale:i>0?s:1/s,originX:o,originY:a})}if(n){var l=Math.abs(i);Xu(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(i>0?1:-1)*(l>3?.4:l>1?.15:.05),originX:o,originY:a})}}}function Zu(t){if(!Bu(this._zr,"globalPan")){Xu(this,"zoom",null,t,{scale:t.pinchScale>1?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY})}}function Xu(t,e,n,i,r){t.pointerChecker&&t.pointerChecker(i,r.originX,r.originY)&&(zc(i.event),Yu(t,e,n,i,r))}function Yu(t,e,n,i,r){r.isAvailableBehavior=v(Uu,null,n,i),t.trigger(e,r)}function Uu(t,e,n){var i=n[t];return!t||i&&(!w(i)||e.event[i+"Key"])}function ju(t,e){var n=$u(t),i=e.dataZoomId,r=e.coordId;f(n,function(t){var n=t.dataZoomInfos;n[i]&&u(e.allCoordIds,r)<0&&(delete n[i],t.count--)}),Ku(n);var o=n[r];o||(o=n[r]={coordId:r,dataZoomInfos:{},count:0},o.controller=function(t,e){var n=new Fu(t.getZr());return f(["pan","zoom","scrollMove"],function(t){n.on(t,function(n){var i=[];f(e.dataZoomInfos,function(r){if(n.isAvailableBehavior(r.dataZoomModel.option)){var o=(r.getRange||{})[t],a=o&&o(e.controller,n);!r.dataZoomModel.get("disabled",!0)&&a&&i.push({dataZoomId:r.dataZoomId,start:a[0],end:a[1]})}}),i.length&&e.dispatchAction(i)})}),n}(t,o),o.dispatchAction=y(Qu,t)),!o.dataZoomInfos[i]&&o.count++,o.dataZoomInfos[i]=e;var a=function(t){var e,n="type_",i={type_true:2,type_move:1,type_false:0,type_undefined:-1},r=!0;return f(t,function(t){var o=t.dataZoomModel,a=!o.get("disabled",!0)&&(!o.get("zoomLock",!0)||"move");i[n+a]>i[n+e]&&(e=a),r&=o.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!r}}}(o.dataZoomInfos);o.controller.enable(a.controlType,a.opt),o.controller.setPointerChecker(e.containsPoint),vo(o,"dispatchAction",e.dataZoomModel.get("throttle",!0),"fixRate")}function qu(t){return t.type+"\0_"+t.id}function $u(t){var e=t.getZr();return e[hw]||(e[hw]={})}function Ku(t){f(t,function(e,n){e.count||(e.controller.dispose(),delete t[n])})}function Qu(t,e){t.dispatchAction({type:"dataZoom",batch:e})}function Ju(t){return function(e,n,i,r){var o=this._range,a=o.slice(),s=e.axisModels[0];if(s){var l=t(a,s,e,n,i,r);return X_(l,a,[0,100],"all"),this._range=a,o[0]!==a[0]||o[1]!==a[1]?a:void 0}}}function th(t,e){gw[t]=e}function eh(t){return gw[t]}function nh(t){this.model=t}function ih(t){this.model=t}function rh(t){var e=function(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 o=r.getBaseAxis();if("category"===o.type){var a=o.dim+"_"+o.index;e[a]||(e[a]={categoryAxis:o,valueAxis:r.getOtherAxis(o),series:[]},i.push({axisDim:o.dim,axisIndex:o.index})),e[a].series.push(t)}else n.push(t)}}),{seriesGroupByCategoryAxis:e,other:n,meta:i}}(t);return{value:m([function(t){var e=[];return f(t,function(t){var n=t.categoryAxis,i=t.valueAxis.dim,r=[" "].concat(p(t.series,function(t){return t.name})),o=[n.model.getCategories()];f(t.series,function(t){o.push(t.getRawData().mapArray(i,function(t){return t}))});for(var a=[r.join(Mw)],s=0;s<o[0].length;s++){for(var l=[],u=0;u<o.length;u++)l.push(o[u][s]);a.push(l.join(Mw))}e.push(a.join("\n"))}),e.join("\n\n"+Sw+"\n\n")}(e.seriesGroupByCategoryAxis),function(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],o=e.getName(r),a=0;t-1>a;a++)i[a]=arguments[a];n.push((o?o+Mw:"")+i.join(Mw))}),n.join("\n")}).join("\n\n"+Sw+"\n\n")}(e.other)],function(t){return t.replace(/[\n\t\s]/g,"")}).join("\n\n"+Sw+"\n\n"),meta:e.meta}}function oh(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function ah(t,e){var n={series:[]};return f(t.split(new RegExp("\n*"+Sw+"\n*","g")),function(t,i){if(function(t){return t.slice(0,t.indexOf("\n")).indexOf(Mw)>=0||void 0}(t)){var r=function(t){for(var e=t.split(/\n+/g),n=[],i=p(oh(e.shift()).split(Iw),function(t){return{name:t,data:[]}}),r=0;r<e.length;r++){var o=oh(e[r]).split(Iw);n.push(o.shift());for(var a=0;a<o.length;a++)i[a]&&(i[a].data[r]=o[a])}return{series:i,categories:n}}(t),o=e[i],a=o.axisDim+"Axis";o&&(n[a]=n[a]||[],n[a][o.axisIndex]={data:r.categories},n.series=n.series.concat(r.series))}else{r=function(t){for(var e=t.split(/\n+/g),n=oh(e.shift()),i=[],r=0;r<e.length;r++){var o,a=oh(e[r]).split(Iw),s="",l=!1;isNaN(a[0])?(l=!0,s=a[0],a=a.slice(1),i[r]={name:s,value:[]},o=i[r].value):o=i[r]=[];for(var u=0;u<a.length;u++)o.push(+a[u]);1===o.length&&(l?i[r].value=o[0]:i[r]=o[0])}return{name:n,data:i}}(t);n.series.push(r)}}),n}function sh(t){this._dom=null,this.model=t}function lh(t){Ac.call(this),this._zr=t,this.group=new yd,this._brushType,this._brushOption,this._panels,this._track=[],this._dragging,this._lastMouseMovePoint={},this._covers=[],this._creatingCover,this._creatingPanel,this._enableGlobalPan,this._uid="brushController_"+Fw++,this._handlers={},Tw(Vw,function(t,e){this._handlers[e]=v(t,this)},this)}function uh(t,e){var n=t._zr;t._enableGlobalPan||function(t,e,n){Ru(t)[e]=n}(n,Nw,t._uid),Tw(t._handlers,function(t,e){n.on(e,t)}),t._brushType=e.brushType,t._brushOption=r(i(Rw),e,!0)}function hh(t){var e=t._zr;(function(t,e,n){var i=Ru(t);i[e]===n&&(i[e]=null)})(e,Nw,t._uid),Tw(t._handlers,function(t,n){e.off(n,t)}),t._brushType=t._brushOption=null}function ch(t,e){var n=Gw[e.brushType].createCover(t,e);return n.__brushOption=e,ph(n,e),t.group.add(n),n}function dh(t,e){var n=mh(e);return n.endCreating&&(n.endCreating(t,e),ph(e,e.__brushOption)),e}function fh(t,e){var n=e.__brushOption;mh(e).updateCoverShape(t,e,n.range,n)}function ph(t,e){var n=e.z;null==n&&(n=Ow),t.traverse(function(t){t.z=n,t.z2=n})}function gh(t,e){mh(e).updateCommon(t,e),fh(t,e)}function mh(t){return Gw[t.__brushOption.brushType]}function vh(t,e,n){var i=t._panels;if(!i)return!0;var r,o=t._transform;return Tw(i,function(t){t.isTargetByCursor(e,n,o)&&(r=t)}),r}function yh(t,e){var n=t._panels;if(!n)return!0;var i=e.__brushOption.panelId;return null==i||n[i]}function xh(t){var e=t._covers,n=e.length;return Tw(e,function(e){t.group.remove(e)},t),e.length=0,!!n}function _h(t,e){var n=Aw(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 wh(t){var e=t.length-1;return 0>e&&(e=0),[t[0],t[e]]}function bh(t,e,n,i){var r=new yd;return r.add(new Vp({name:"main",style:Ch(n),silent:!0,draggable:!0,cursor:"move",drift:Cw(t,e,r,"nswe"),ondragend:Cw(_h,e,{isEnd:!0})})),Tw(i,function(n){r.add(new Vp({name:n,style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Cw(t,e,r,n),ondragend:Cw(_h,e,{isEnd:!0})}))}),r}function Sh(t,e,n,i){var r=i.brushStyle.lineWidth||0,o=kw(r,zw),a=n[0][0],s=n[1][0],l=a-r/2,u=s-r/2,h=n[0][1],c=n[1][1],d=h-o+r/2,f=c-o+r/2,p=h-a,g=c-s,m=p+r,v=g+r;Ih(t,e,"main",a,s,p,g),i.transformable&&(Ih(t,e,"w",l,u,o,v),Ih(t,e,"e",d,u,o,v),Ih(t,e,"n",l,u,m,o),Ih(t,e,"s",l,f,m,o),Ih(t,e,"nw",l,u,o,o),Ih(t,e,"ne",d,u,o,o),Ih(t,e,"sw",l,f,o,o),Ih(t,e,"se",d,f,o,o))}function Mh(t,e){var n=e.__brushOption,i=n.transformable,r=e.childAt(0);r.useStyle(Ch(n)),r.attr({silent:!i,cursor:i?"move":"default"}),Tw(["w","e","n","s","se","sw","ne","nw"],function(n){var r=e.childOfName(n),o=Ah(t,n);r&&r.attr({silent:!i,invisible:!i,cursor:i?Bw[o]+"-resize":null})})}function Ih(t,e,n,i,r,o,a){var s=e.childOfName(n);s&&s.setShape(function(t){var e=Dw(t[0][0],t[1][0]),n=Dw(t[0][1],t[1][1]),i=kw(t[0][0],t[1][0]),r=kw(t[0][1],t[1][1]);return{x:e,y:n,width:i-e,height:r-n}}(Oh(t,e,[[i,r],[i+o,r+a]])))}function Ch(t){return s({strokeNoScale:!0},t.brushStyle)}function Th(t,e,n,i){var r=[Dw(t,n),Dw(e,i)],o=[kw(t,n),kw(e,i)];return[[r[0],o[0]],[r[1],o[1]]]}function Ah(t,e){if(e.length>1){return("e"===(n=[Ah(t,(e=e.split(""))[0]),Ah(t,e[1])])[0]||"w"===n[0])&&n.reverse(),n.join("")}var n=Bi({w:"left",e:"right",n:"top",s:"bottom"}[e],function(t){return Ni(t.group)}(t));return{left:"w",right:"e",top:"n",bottom:"s"}[n]}function Dh(t,e,n,i,r,o,a){var s=i.__brushOption,l=t(s.range),u=Ph(n,o,a);Tw(r.split(""),function(t){var e=Ew[t];l[e[0]][e[1]]+=u[e[0]]}),s.range=e(Th(l[0][0],l[1][0],l[0][1],l[1][1])),gh(n,i),_h(n,{isEnd:!1})}function kh(t,e,n,i){var r=e.__brushOption.range,o=Ph(t,n,i);Tw(r,function(t){t[0]+=o[0],t[1]+=o[1]}),gh(t,e),_h(t,{isEnd:!1})}function Ph(t,e,n){var i=t.group,r=i.transformCoordToLocal(e,n),o=i.transformCoordToLocal(0,0);return[r[0]-o[0],r[1]-o[1]]}function Oh(t,e,n){var r=yh(t,e);return r&&!0!==r?r.clipPath(n,t._transform):i(n)}function Lh(t){var e=t.event;e.preventDefault&&e.preventDefault()}function zh(t,e,n){return t.childOfName("main").contain(e,n)}function Nh(t,e,n,r){var o,a=t._creatingCover,s=t._creatingPanel,l=t._brushOption;if(t._track.push(n.slice()),function(t){var e=t._track;if(!e.length)return!1;var n=e[e.length-1],i=e[0],r=n[0]-i[0],o=n[1]-i[1];return Pw(r*r+o*o,.5)>Lw}(t)||a){if(s&&!a){"single"===l.brushMode&&xh(t);var u=i(l);u.brushType=Eh(u.brushType,s),u.panelId=!0===s?null:s.panelId,a=t._creatingCover=ch(t,u),t._covers.push(a)}if(a){var h=Gw[Eh(t._brushType,s)];a.__brushOption.range=h.getCreatingRange(Oh(t,a,t._track)),r&&(dh(t,a),h.updateCommon(t,a)),fh(t,a),o={isEnd:r}}}else r&&"single"===l.brushMode&&l.removeOnClick&&vh(t,e,n)&&xh(t)&&(o={isEnd:r,removeOnClick:!0});return o}function Eh(t,e){return"auto"===t?e.defaultBrushType:t}function Bh(t,e,n){if(t._dragging){!n&&Lh(e);var i=e.offsetX,r=e.offsetY,o=t._lastMouseMovePoint;n&&(i=o.x,r=o.y);var a=Nh(t,e,t.group.transformCoordToLocal(i,r),!0);t._dragging=!1,t._track=[],t._creatingCover=null,a&&_h(t,a)}}function Rh(t){return{createCover:function(e,n){return bh(Cw(Dh,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=wh(e);return[Dw(n[0][t],n[1][t]),kw(n[0][t],n[1][t])]},updateCoverShape:function(e,n,i,r){var o,a=yh(e,n);if(!0!==a&&a.getLinearBrushOtherExtent)o=a.getLinearBrushOtherExtent(t,e._transform);else{var s=e._zr;o=[0,[s.getWidth(),s.getHeight()][1-t]]}var l=[i,o];t&&l.reverse(),Sh(e,n,l,r)},updateCommon:Mh,contain:zh}}function Fh(t,e,n){return t=Vh(t),function(i,r){return t.contain(r[0],r[1])&&!function(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!Ww[i.mainType]&&r&&r.model!==n}(i,e,n)}}function Vh(t){return te.create(t)}function Gh(t,e,n){var i=this._targetInfoList=[],r={},o=Hh(e,t);Hw(qw,function(t,e){(!n||!n.include||Zw(n.include,e)>=0)&&t(o,i,r)})}function Wh(t){return t[0]>t[1]&&t.reverse(),t}function Hh(t,e){return an(t,e,{includeMainTypes:Uw})}function Zh(t,e,n,i){var r=n.getAxis(["x","y"][t]),o=Wh(p([0,1],function(t){return e?r.coordToData(r.toLocalCoord(i[t])):r.toGlobalCoord(r.dataToCoord(i[t]))})),a=[];return a[t]=o,a[1-t]=[NaN,NaN],{values:o,xyMinMax:a}}function Xh(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function Yh(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}function Uh(t){var e=t[eb];return e||(e=t[eb]=[{}]),e}function jh(t,e,n){(this._brushController=new lh(n.getZr())).on("brush",v(this._onBrush,this)).mount(),this._isZoomActive}function qh(t){var e={};return f(["xAxisIndex","yAxisIndex"],function(n){e[n]=t[n],null==e[n]&&(e[n]="all"),(!1===e[n]||"none"===e[n])&&(e[n]=[])}),e}function $h(t,e){t.setIconStatus("back",function(t){return Uh(t).length}(e)>1?"emphasis":"normal")}function Kh(t){this.model=t}function Qh(t,e,n,i){var r=n.type,o=new(lb.hasOwnProperty(r)?lb[r]:ri(r))(n);e.add(o),i.set(t,o),o.__ecGraphicId=t}function Jh(t,e){var n=t&&t.parent;n&&("group"===t.type&&t.traverse(function(t){Jh(t,e)}),e.removeKey(t.__ecGraphicId),n.remove(t))}function tc(t){return t=a({},t),f(["id","parentId","$action","hv","bounding"].concat(Dg),function(e){delete t[e]}),t}function ec(t,e){var n;return f(e,function(e){null!=t[e]&&"auto"!==t[e]&&(n=!0)}),n}function nc(t,e,n){var i=a({},n),o=t[e],s=n.$action||"merge";"merge"===s?o?(r(o,i,!0),yr(o,i,{ignoreSize:!0}),_r(n,o)):t[e]=i:"replace"===s?t[e]=i:"remove"===s&&o&&(t[e]=null)}var ic=2311,rc=function(){return ic++},oc={},ac=oc="object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0,domSupported:!1}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0,domSupported:!1}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0,domSupported:!1}:e(navigator.userAgent),sc={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},lc={"[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},uc=Object.prototype.toString,hc=Array.prototype,cc=hc.forEach,dc=hc.filter,fc=hc.slice,pc=hc.map,gc=hc.reduce,mc={},vc=function(){return mc.createCanvas()};mc.createCanvas=function(){return document.createElement("canvas")};var yc,xc="__ec_primitive__";E.prototype={constructor:E,get:function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},set:function(t,e){return this.data[t]=e},each:function(t,e){void 0!==e&&(t=v(t,e));for(var n in this.data)this.data.hasOwnProperty(n)&&t(this.data[n],n)},removeKey:function(t){delete this.data[t]}};var _c=(Object.freeze||Object)({$override:n,clone:i,merge:r,mergeAll:o,extend:a,defaults:s,createCanvas:vc,getContext:l,indexOf:u,inherits:h,mixin:c,isArrayLike:d,each:f,map:p,reduce:g,filter:m,find:function(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]},bind:v,curry:y,isArray:x,isFunction:_,isString:w,isObject:b,isBuiltInObject:S,isTypedArray:M,isDom:I,eqNaN:C,retrieve:T,retrieve2:A,retrieve3:D,slice:k,normalizeCssArray:P,assert:O,trim:L,setAsPrimitive:z,isPrimitive:N,createHashMap:B,concatArray:function(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},noop:R}),wc="undefined"==typeof Float32Array?Array:Float32Array,bc=X,Sc=Y,Mc=q,Ic=$,Cc=(Object.freeze||Object)({create:F,copy:V,clone:G,set:function(t,e,n){return t[0]=e,t[1]=n,t},add:W,scaleAndAdd:H,sub:Z,len:X,length:bc,lenSquare:Y,lengthSquare:Sc,mul:function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},div:function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:U,normalize:j,distance:q,dist:Mc,distanceSquare:$,distSquare:Ic,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},lerp:function(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t},applyTransform:K,min:Q,max:J});tt.prototype={constructor:tt,_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(et(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,o=i-this._y;this._x=n,this._y=i,e.drift(r,o,t),this.dispatchToElement(et(e,t),"drag",t.event);var a=this.findHover(n,i,e).target,s=this._dropTarget;this._dropTarget=a,e!==a&&(s&&a!==s&&this.dispatchToElement(et(s,t),"dragleave",t.event),a&&a!==s&&this.dispatchToElement(et(a,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(et(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(et(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var Tc=Array.prototype.slice,Ac=function(t){this._$handlers={},this._$eventProcessor=t};Ac.prototype={constructor:Ac,one:function(t,e,n,i){return nt(this,t,e,n,i,!0)},on:function(t,e,n,i){return nt(this,t,e,n,i,!1)},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,o=n[t].length;o>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){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;r>3&&(i=Tc.call(i,1));for(var o=e.length,a=0;o>a;){var s=e[a];if(n&&n.filter&&null!=s.query&&!n.filter(t,s.query))a++;else{switch(r){case 1:s.h.call(s.ctx);break;case 2:s.h.call(s.ctx,i[1]);break;case 3:s.h.call(s.ctx,i[1],i[2]);break;default:s.h.apply(s.ctx,i)}s.one?(e.splice(a,1),o--):a++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this},triggerWithContext:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;r>4&&(i=Tc.call(i,1,i.length-1));for(var o=i[i.length-1],a=e.length,s=0;a>s;){var l=e[s];if(n&&n.filter&&null!=l.query&&!n.filter(t,l.query))s++;else{switch(r){case 1:l.h.call(o);break;case 2:l.h.call(o,i[1]);break;case 3:l.h.call(o,i[1],i[2]);break;default:l.h.apply(o,i)}l.one?(e.splice(s,1),a--):s++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this}};var Dc=Math.log(2),kc="undefined"!=typeof window&&!!window.addEventListener,Pc=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Oc="___zrEVENTSAVED",Lc=[],zc=kc?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0},Nc=function(){this._track=[]};Nc.prototype={constructor:Nc,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},o=0,a=i.length;a>o;o++){var s=i[o],l=rt(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},_recognize:function(t){for(var e in Ec)if(Ec.hasOwnProperty(e)){var n=Ec[e](this._track,t);if(n)return n}}};var Ec={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 o=ht(i)/ht(r);!isFinite(o)&&(o=1),e.pinchScale=o;var a=function(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}(i);return e.pinchX=a[0],e.pinchY=a[1],{type:"pinch",target:t[0].target,event:e}}}}},Bc="silent";dt.prototype.dispose=function(){};var Rc=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Fc=function(t,e,n,i){Ac.call(this),this.storage=t,this.painter=e,this.painterRoot=i,n=n||new dt,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,this._gestureMgr,tt.call(this),this.setHandlerProxy(n)};Fc.prototype={constructor:Fc,setHandlerProxy:function(t){this.proxy&&this.proxy.dispose(),t&&(f(Rc,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 o=this._hovered=this.findHover(e,n),a=o.target,s=this.proxy;s.setCursor&&s.setCursor(a?a.cursor:"default"),r&&a!==r&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(o,"mousemove",t),a&&a!==r&&this.dispatchToElement(o,"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){var i=(t=t||{}).target;if(!i||!i.silent){for(var r="on"+e,o=function(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,stop:ct}}(e,t,n);i&&(i[r]&&(o.cancelBubble=i[r].call(i,o)),i.trigger(e,o),i=i.parent,!o.cancelBubble););o.cancelBubble||(this.trigger(e,o),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[r]&&t[r].call(t,o),t.trigger&&t.trigger(e,o)}))}},findHover:function(t,e,n){for(var i=this.storage.getDisplayList(),r={x:t,y:e},o=i.length-1;o>=0;o--){var a;if(i[o]!==n&&!i[o].ignore&&(a=ft(i[o],t,e))&&(!r.topTarget&&(r.topTarget=i[o]),a!==Bc)){r.target=i[o];break}}return r},processGesture:function(t,e){this._gestureMgr||(this._gestureMgr=new Nc);var n=this._gestureMgr;"start"===e&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&n.clear(),i){var r=i.type;t.gestureEvent=r,this.dispatchToElement({target:i.target},r,i.event)}}},f(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){Fc.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||Mc(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,t,e)}}),c(Fc,Ac),c(Fc,tt);var Vc="undefined"==typeof Float32Array?Array:Float32Array,Gc=(Object.freeze||Object)({create:pt,identity:gt,copy:mt,mul:vt,translate:yt,rotate:xt,scale:_t,invert:wt,clone:function(t){var e=pt();return mt(e,t),e}}),Wc=gt,Hc=5e-5,Zc=function(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},Xc=Zc.prototype;Xc.transform=null,Xc.needLocalTransform=function(){return bt(this.rotation)||bt(this.position[0])||bt(this.position[1])||bt(this.scale[0]-1)||bt(this.scale[1]-1)};var Yc=[];Xc.updateTransform=function(){var t=this.parent,e=t&&t.transform,n=this.needLocalTransform(),i=this.transform;if(n||e){i=i||pt(),n?this.getLocalTransform(i):Wc(i),e&&(n?vt(i,t.transform,i):mt(i,t.transform)),this.transform=i;var r=this.globalScaleRatio;if(null!=r&&1!==r){this.getGlobalScale(Yc);var o=Yc[0]<0?-1:1,a=Yc[1]<0?-1:1,s=((Yc[0]-o)*r+o)/Yc[0]||0,l=((Yc[1]-a)*r+a)/Yc[1]||0;i[0]*=s,i[1]*=s,i[2]*=l,i[3]*=l}this.invTransform=this.invTransform||pt(),wt(this.invTransform,i)}else i&&Wc(i)},Xc.getLocalTransform=function(t){return Zc.getLocalTransform(this,t)},Xc.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)},Xc.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var Uc=[],jc=pt();Xc.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=this.position,r=this.scale;bt(e-1)&&(e=Math.sqrt(e)),bt(n-1)&&(n=Math.sqrt(n)),t[0]<0&&(e=-e),t[3]<0&&(n=-n),i[0]=t[4],i[1]=t[5],r[0]=e,r[1]=n,this.rotation=Math.atan2(-t[1]/n,t[0]/e)}},Xc.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(vt(Uc,t.invTransform,e),e=Uc);var n=this.origin;n&&(n[0]||n[1])&&(jc[4]=n[0],jc[5]=n[1],vt(Uc,e,jc),Uc[4]-=n[0],Uc[5]-=n[1],e=Uc),this.setLocalTransform(e)}},Xc.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},Xc.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&K(n,n,i),n},Xc.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&K(n,n,i),n},Zc.getLocalTransform=function(t,e){Wc(e=e||[]);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,o=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),_t(e,e,i),r&&xt(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=o[0],e[5]+=o[1],e};var qc={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*(2-Math.pow(2,-10*(t-1)))},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;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=.1):e=.4*Math.asin(1/n)/(2*Math.PI),-n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/.4))},elasticOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=.1):e=.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin(2*(t-e)*Math.PI/.4)+1)},elasticInOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=.1):e=.4*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/.4):n*Math.pow(2,-10*(t-=1))*Math.sin(2*(t-e)*Math.PI/.4)*.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-qc.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*qc.bounceIn(2*t):.5*qc.bounceOut(2*t-1)+.5}};St.prototype={constructor:St,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)this._pausedTime+=e;else{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?qc[i]:i,o="function"==typeof r?r(n):n;return this.fire("frame",o),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){this[t="on"+t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var $c=function(){this.head=null,this.tail=null,this._len=0},Kc=$c.prototype;Kc.insert=function(t){var e=new Qc(t);return this.insertEntry(e),e},Kc.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++},Kc.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--},Kc.len=function(){return this._len},Kc.clear=function(){this.head=this.tail=null,this._len=0};var Qc=function(t){this.value=t,this.next,this.prev},Jc=function(t){this._list=new $c,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null},td=Jc.prototype;td.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var o=n.len(),a=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}a?a.value=e:a=new Qc(e),a.key=t,n.insertEntry(a),i[t]=a}return r},td.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},td.clear=function(){this._list.clear(),this._map={}};var ed={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]},nd=new Jc(20),id=null,rd=Bt,od=Rt,ad=(Object.freeze||Object)({parse:Lt,lift:Nt,toHex:Et,fastLerp:Bt,fastMapToColor:rd,lerp:Rt,mapToColor:od,modifyHSL:function(t,e,n,i){return(t=Lt(t))?(t=function(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,o=t[2]/255,a=Math.min(i,r,o),s=Math.max(i,r,o),l=s-a,u=(s+a)/2;if(0===l)e=0,n=0;else{n=.5>u?l/(s+a):l/(2-s-a);var h=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,d=((s-o)/6+l/2)/l;i===s?e=d-c:r===s?e=1/3+h-d:o===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}}(t),null!=e&&(t[0]=function(t){return 0>(t=Math.round(t))?0:t>360?360:t}(e)),null!=n&&(t[1]=Tt(n)),null!=i&&(t[2]=Tt(i)),Vt(zt(t),"rgba")):void 0},modifyAlpha:Ft,stringify:Vt}),sd=Array.prototype.slice,ld=function(t,e,n,i){this._tracks={},this._target=t,this._loop=e||!1,this._getter=n||function(t,e){return t[e]},this._setter=i||function(t,e,n){t[e]=n},this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};ld.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:jt(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,o=function(){--r||i._doneCallback()};for(var a in this._tracks)if(this._tracks.hasOwnProperty(a)){var s=$t(this,t,o,this._tracks[a],a,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 ud=1;"undefined"!=typeof window&&(ud=Math.max(window.devicePixelRatio||1,1));var hd=ud,cd=function(){},dd=cd,fd=function(){this.animators=[]};fd.prototype={constructor:fd,animate:function(t,e){var n,i=!1,r=this,o=this.__zr;if(t){var a=t.split("."),s=r;i="shape"===a[0];for(var l=0,h=a.length;h>l;l++)s&&(s=s[a[l]]);s&&(n=s)}else n=r;{if(n){var c=r.animators,d=new ld(n,e);return d.during(function(){r.dirty(i)}).done(function(){c.splice(u(c,d),1)}),c.push(d),o&&o.animation.addAnimator(d),d}dd('Property "'+t+'" is not existed in element '+r.id)}},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,o){Kt(this,t,e,n,i,r,o)},animateFrom:function(t,e,n,i,r,o){Kt(this,t,e,n,i,r,o,!0)}};var pd=function(t){Zc.call(this,t),Ac.call(this,t),fd.call(this,t),this.id=t.id||rc()};pd.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(b(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(pd,fd),c(pd,Zc),c(pd,Ac);var gd=K,md=Math.min,vd=Math.max;te.prototype={constructor:te,union:function(t){var e=md(t.x,this.x),n=md(t.y,this.y);this.width=vd(t.x+t.width,this.x+this.width)-e,this.height=vd(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,gd(t,t,r),gd(e,e,r),gd(n,n,r),gd(i,i,r),this.x=md(t[0],e[0],n[0],i[0]),this.y=md(t[1],e[1],n[1],i[1]);var o=vd(t[0],e[0],n[0],i[0]),a=vd(t[1],e[1],n[1],i[1]);this.width=o-this.x,this.height=a-this.y}}}(),calculateTransform:function(t){var e=this,n=t.width/e.width,i=t.height/e.height,r=pt();return yt(r,r,[-e.x,-e.y]),_t(r,r,[n,i]),yt(r,r,[t.x,t.y]),r},intersect:function(t){if(!t)return!1;t instanceof te||(t=te.create(t));var e=this,n=e.x,i=e.x+e.width,r=e.y,o=e.y+e.height,a=t.x,s=t.x+t.width,l=t.y,u=t.y+t.height;return!(a>i||n>s||l>o||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 te(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}}},te.create=function(t){return new te(t.x,t.y,t.width,t.height)};var yd=function(t){t=t||{},pd.call(this,t);for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};yd.prototype={constructor:yd,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 yd&&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 yd&&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 yd&&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 yd&&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 yd&&n.delChildrenFromStorage(t)}},dirty:function(){return this.__dirty=!0,this.__zr&&this.__zr.refresh(),this},getBoundingRect:function(t){for(var e=null,n=new te(0,0,0,0),i=t||this._children,r=[],o=0;o<i.length;o++){var a=i[o];if(!a.ignore&&!a.invisible){var s=a.getBoundingRect(),l=a.getLocalTransform(r);l?(n.copy(s),n.applyTransform(l),(e=e||n.clone()).union(n)):(e=e||s.clone()).union(s)}}return e||n}},h(yd,pd);var xd=32,_d=7,wd=function(){this._roots=[],this._displayList=[],this._displayListLen=0};wd.prototype={constructor:wd,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,ac.canvasSupported&&oe(n,ae)},_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,o=t;r;)r.parent=o,r.updateTransform(),e.push(r),o=r,r=r.clipPath}if(t.isGroup){for(var a=t._children,s=0;s<a.length;s++){var l=a[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 yd&&t.addChildrenToStorage(this),this.addToStorage(t),this._roots.push(t))},delRoot:function(t){if(null==t){for(n=0;n<this._roots.length;n++){var e=this._roots[n];e instanceof yd&&e.delChildrenFromStorage(this)}return this._roots=[],this._displayList=[],void(this._displayListLen=0)}if(t instanceof Array)for(var n=0,i=t.length;i>n;n++)this.delRoot(t[n]);else{var r=u(this._roots,t);r>=0&&(this.delFromStorage(t),this._roots.splice(r,1),t instanceof yd&&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:ae};var bd={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},Sd=function(t,e,n){return bd.hasOwnProperty(e)?n*=t.dpr:n},Md={NONE:0,STYLE_BIND:1,PLAIN_TEXT:2},Id=9,Cd=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],Td=function(t){this.extendFrom(t,!1)};Td.prototype={constructor:Td,fill:"#000",stroke:null,opacity:1,fillOpacity:null,strokeOpacity:null,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){var i=this,r=n&&n.style,o=!r||t.__attrCachedBy!==Md.STYLE_BIND;t.__attrCachedBy=Md.STYLE_BIND;for(var a=0;a<Cd.length;a++){var s=Cd[a],l=s[0];(o||i[l]!==r[l])&&(t[l]=Sd(t,l,i[l]||s[1]))}if((o||i.fill!==r.fill)&&(t.fillStyle=i.fill),(o||i.stroke!==r.stroke)&&(t.strokeStyle=i.stroke),(o||i.opacity!==r.opacity)&&(t.globalAlpha=null==i.opacity?1:i.opacity),(o||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)||!0!==e&&(!1===e?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?function(t,e,n){var i=n.width,r=n.height,o=Math.min(i,r),a=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;return e.global||(a=a*i+n.x,s=s*r+n.y,l*=o),t.createRadialGradient(a,s,0,a,s,l)}:function(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,o=null==e.y?0:e.y,a=null==e.y2?0:e.y2;return e.global||(i=i*n.width+n.x,r=r*n.width+n.x,o=o*n.height+n.y,a=a*n.height+n.y),i=isNaN(i)?0:i,r=isNaN(r)?1:r,o=isNaN(o)?0:o,a=isNaN(a)?0:a,t.createLinearGradient(i,o,r,a)})(t,e,n),r=e.colorStops,o=0;o<r.length;o++)i.addColorStop(r[o].offset,r[o].color);return i}};for(var Ad=Td.prototype,Dd=0;Dd<Cd.length;Dd++){var kd=Cd[Dd];kd[0]in Ad||(Ad[kd[0]]=kd[1])}Td.getGradient=Ad.getGradient;var Pd=function(t,e){this.image=t,this.repeat=e,this.type="pattern"};Pd.prototype.getCanvasPattern=function(t){return t.createPattern(this.image,this.repeat||"repeat")};var Od=function(t,e,n){var i;n=n||hd,"string"==typeof t?i=le(t,e,n):b(t)&&(i=t,t=i.id),this.id=t,this.dom=i;var r=i.style;r&&(i.onselectstart=se,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};Od.prototype={constructor:Od,__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=le("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,o=this.domBack;r&&(r.width=t+"px",r.height=e+"px"),i.width=t*n,i.height=e*n,o&&(o.width=t*n,o.height=e*n,1!==n&&this.ctxBack.scale(n,n))},clear:function(t,e){var n=this.dom,i=this.ctx,r=n.width,o=n.height,e=e||this.clearColor,a=this.motionBlur&&!t,s=this.lastFrameAlpha,l=this.dpr;if(a&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(n,0,0,r/l,o/l)),i.clearRect(0,0,r,o),e&&"transparent"!==e){var u;e.colorStops?(u=e.__canvasGradient||Td.getGradient(i,e,{x:0,y:0,width:r,height:o}),e.__canvasGradient=u):e.image&&(u=Pd.prototype.getCanvasPattern.call(e,i)),i.save(),i.fillStyle=u||e,i.fillRect(0,0,r,o),i.restore()}if(a){var h=this.domBack;i.save(),i.globalAlpha=s,i.drawImage(h,0,0,r,o),i.restore()}}};var Ld="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)},zd=new Jc(50),Nd={},Ed=0,Bd=5e3,Rd=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g,Fd="12px sans-serif",Vd={};Vd.measureText=function(t,e){var n=l();return n.font=e||Fd,n.measureText(t)};var Gd=Fd,Wd={left:1,right:1,center:1},Hd={top:1,bottom:1,middle:1},Zd=[["textShadowBlur","shadowBlur",0],["textShadowOffsetX","shadowOffsetX",0],["textShadowOffsetY","shadowOffsetY",0],["textShadowColor","shadowColor","transparent"]],Xd={},Yd={},Ud=new te,jd=function(){};jd.prototype={constructor:jd,drawRectText:function(t,e){var n=this.style;e=n.textRect||e,this.__dirty&&Te(n);var i=n.text;if(null!=i&&(i+=""),Ge(i,n)){t.save();var r=this.transform;n.transformText?this.setTransform(t):r&&(Ud.copy(e),Ud.applyTransform(r),e=Ud),De(this,t,i,n,e,Id),t.restore()}}},We.prototype={constructor:We,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,globalScaleRatio: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);return this.getBoundingRect().contain(n[0],n[1])},dirty:function(){this.__dirty=this.__dirtyText=!0,this._rect=null,this.__zr&&this.__zr.refresh()},animateStyle:function(t){return this.animate("style",t)},attrKV:function(t,e){"style"!==t?pd.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 Td(t,this),this.dirty(!1),this},calculateTextPosition:null},h(We,pd),c(We,jd),He.prototype={constructor:He,type:"image",brush:function(t,e){var n=this.style,i=n.image;n.bind(t,this,e);var r=this._image=he(i,this._image,this,this.onload);if(r&&de(r)){var o=n.x||0,a=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,o,a,s,l)}else if(n.sx&&n.sy){var d=s-(h=n.sx),f=l-(c=n.sy);t.drawImage(r,h,c,d,f,o,a,s,l)}else t.drawImage(r,o,a,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 te(t.x||0,t.y||0,t.width||0,t.height||0)),this._rect}},h(He,We);var qd=314159,$d=new te(0,0,0,0),Kd=new te(0,0,0,0),Qd=function(t,e,n){this.type="canvas";var i=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=n=a({},n||{}),this.dpr=n.devicePixelRatio||hd,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 o=this._zlevelList=[],s=this._layers={};if(this._layerConfig={},this._needsManuallyCompositing=!1,i){var l=t.width,u=t.height;null!=n.width&&(l=n.width),null!=n.height&&(u=n.height),this.dpr=n.devicePixelRatio||1,t.width=l*this.dpr,t.height=u*this.dpr,this._width=l,this._height=u;var h=new Od(t,this,this.dpr);h.__builtin__=!0,h.initContext(),s[314159]=h,h.zlevel=qd,o.push(qd),this._domRoot=t}else{this._width=this._getSize(0),this._height=this._getSize(1);var c=this._domRoot=function(t,e){var n=document.createElement("div");return n.style.cssText=["position:relative","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",n}(this._width,this._height);t.appendChild(c)}this._hoverlayer=null,this._hoverElements=[]};Qd.prototype={constructor:Qd,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],o=this._layers[r];if(!o.__builtin__&&o.refresh){var a=0===i?this._backgroundColor:null;o.refresh(a)}}return this.refreshHover(),this},addHover:function(t,e){if(!t.__hoverMir){var n=new t.constructor({style:t.style,shape:t.shape,z:t.z,z2:t.z2,silent:t.silent});return n.__from=t,t.__hoverMir=n,e&&n.setStyle(e),this._hoverElements.push(n),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){oe(t,this.storage.displayableSortFunc),n||(n=this._hoverlayer=this.getLayer(1e5));var i={};n.ctx.save();for(var r=0;e>r;){var o=t[r],a=o.__from;a&&a.__zr?(r++,a.invisible||(o.transform=a.transform,o.invTransform=a.invTransform,o.__clipPaths=a.__clipPaths,this._doPaintEl(o,n,!0,i))):(t.splice(r,1),a.__hoverMir=null,e--)}n.ctx.restore()}},getHoverLayer:function(){return this.getLayer(1e5)},_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;Ld(function(){r._paintList(t,e,n)})}}},_compositeManually:function(){var t=this.getLayer(qd).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];(s=this._layers[r]).__builtin__&&s!==this._hoverlayer&&(s.__dirty||e)&&n.push(s)}for(var o=!0,a=0;a<n.length;a++){var s=n[a],l=s.ctx,u={};l.save();var h=e?s.__startIndex:s.__drawIndex,c=!e&&s.incremental&&Date.now,d=c&&Date.now(),p=s.zlevel===this._zlevelList[0]?this._backgroundColor:null;if(s.__startIndex===s.__endIndex)s.clear(!1,p);else if(h===s.__startIndex){var g=t[h];g.incremental&&g.notClear&&!e||s.clear(!1,p)}-1===h&&(console.error("For some unknown reason. drawIndex is -1"),h=s.__startIndex);for(var m=h;m<s.__endIndex;m++){var v=t[m];if(this._doPaintEl(v,s,e,u),v.__dirty=v.__dirtyText=!1,c){if(Date.now()-d>15)break}}s.__drawIndex=m,s.__drawIndex<s.__endIndex&&(o=!1),u.prevElClipPaths&&l.restore(),l.restore()}return ac.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,o=t.transform;if(!(!e.__dirty&&!n||t.invisible||0===t.style.opacity||o&&!o[0]&&!o[3]||t.culling&&function(t,e,n){return $d.copy(t.getBoundingRect()),t.transform&&$d.applyTransform(t.transform),Kd.width=e,Kd.height=n,!$d.intersect(Kd)}(t,this._width,this._height))){var a=t.__clipPaths,s=i.prevElClipPaths;(!s||function(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;return!1}(a,s))&&(s&&(r.restore(),i.prevElClipPaths=null,i.prevEl=null),a&&(r.save(),function(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)}}(a,r),i.prevElClipPaths=a)),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=qd);var n=this._layers[t];return n||(n=new Od("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,o=null,a=-1,s=this._domRoot;if(n[t])dd("ZLevel "+t+" has been used already");else if(function(t){return!!t&&(!!t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh)}(e)){if(r>0&&t>i[0]){for(a=0;r-1>a&&!(i[a]<t&&i[a+1]>t);a++);o=n[i[a]]}if(i.splice(a+1,0,t),n[t]=e,!e.virtual)if(o){var l=o.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)}else dd("Layer of zlevel "+t+" is not valid")},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,o=this._zlevelList;for(r=0;r<o.length;r++)i=o[r],(n=this._layers[i]).__builtin__&&t.call(e,n,i)},eachOtherLayer:function(t,e){var n,i,r,o=this._zlevelList;for(r=0;r<o.length;r++)i=o[r],(n=this._layers[i]).__builtin__||t.call(e,n,i)},getLayers:function(){return this._layers},_updateLayerStatus:function(t){function e(t){n&&(n.__endIndex!==t&&(n.__dirty=!0),n.__endIndex=t)}if(this.eachBuiltinLayer(function(t){t.__dirty=t.__used=!1}),this._singleCanvas)for(r=1;r<t.length;r++){if((a=t[r]).zlevel!==t[r-1].zlevel||a.incremental){this._needsManuallyCompositing=!0;break}}for(var n=null,i=0,r=0;r<t.length;r++){var o,a=t[r],s=a.zlevel;a.incremental?(o=this.getLayer(s+.001,this._needsManuallyCompositing),o.incremental=!0,i=1):o=this.getLayer(s+(i>0?.01:0),this._needsManuallyCompositing),o.__builtin__||dd("ZLevel "+s+" has been used by unkown layer "+o.id),o!==n&&(o.__used=!0,o.__startIndex!==r&&(o.__dirty=!0),o.__startIndex=r,o.__drawIndex=o.incremental?-1:r,e(r),n=o),a.__dirty&&(o.__dirty=!0,o.incremental&&o.__drawIndex<0&&(o.__drawIndex=r))}e(r),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()},setBackgroundColor:function(t){this._backgroundColor=t},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 o=this._zlevelList[i];if(o===t||o===t+.01){r(this._layers[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(qd).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[314159].dom;var e=new Od("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),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 o={},a=this.storage.getDisplayList(!0),s=0;s<a.length;s++){var l=a[s];this._doPaintEl(l,e,!0,o)}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],o=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var a=this.root,s=document.defaultView.getComputedStyle(a);return(a[i]||Ze(s[n])||Ze(a.style[n]))-(Ze(s[r])||0)-(Ze(s[o])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),r=t.getBoundingRect(),o=t.style,a=o.shadowBlur*e,s=o.shadowOffsetX*e,l=o.shadowOffsetY*e,u=o.hasStroke()?o.lineWidth:0,h=Math.max(u/2,-s+a),c=Math.max(u/2,s+a),d=Math.max(u/2,-l+a),f=Math.max(u/2,l+a),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 m={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 v=new He({style:{x:0,y:0,image:n}});return null!=m.position&&(v.position=t.position=m.position),null!=m.rotation&&(v.rotation=t.rotation=m.rotation),null!=m.scale&&(v.scale=t.scale=m.scale),v}};var Jd=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,Ac.call(this)};Jd.prototype={constructor:Jd,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=[],o=[],a=0;i>a;a++){var s=n[a],l=s.step(t,e);l&&(r.push(l),o.push(s))}for(a=0;i>a;)n[a]._needsRemove?(n[a]=n[i-1],n.pop(),i--):a++;i=r.length;for(a=0;i>a;a++)o[a].fire(r[a]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){function t(){e._running&&(Ld(t),!e._paused&&e._update())}var e=this;this._running=!0,Ld(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=[]},isFinished:function(){return!this._clips.length},animate:function(t,e){var n=new ld(t,(e=e||{}).loop,e.getter,e.setter);return this.addAnimator(n),n}},c(Jd,Ac);var tf=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],ef=["touchstart","touchend","touchmove"],nf={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},rf=p(tf,function(t){var e=t.replace("mouse","pointer");return nf[e]?e:t}),of={mousemove:function(t){t=at(this.dom,t),this.trigger("mousemove",t)},mouseout:function(t){var e=(t=at(this.dom,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=at(this.dom,t)).zrByTouch=!0,this._lastTouchMoment=new Date,this.handler.processGesture(t,"start"),of.mousemove.call(this,t),of.mousedown.call(this,t),Ye(this)},touchmove:function(t){(t=at(this.dom,t)).zrByTouch=!0,this.handler.processGesture(t,"change"),of.mousemove.call(this,t),Ye(this)},touchend:function(t){(t=at(this.dom,t)).zrByTouch=!0,this.handler.processGesture(t,"end"),of.mouseup.call(this,t),+new Date-this._lastTouchMoment<300&&of.click.call(this,t),Ye(this)},pointerdown:function(t){of.mousedown.call(this,t)},pointermove:function(t){Ue(t)||of.mousemove.call(this,t)},pointerup:function(t){of.mouseup.call(this,t)},pointerout:function(t){Ue(t)||of.mouseout.call(this,t)}};f(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){of[t]=function(e){e=at(this.dom,e),this.trigger(t,e)}});var af=je.prototype;af.dispose=function(){for(var t=tf.concat(ef),e=0;e<t.length;e++){var n=t[e];lt(this.dom,Xe(n),this._handlers[n])}},af.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},c(je,Ac);var sf=!ac.canvasSupported,lf={canvas:Qd},uf={},hf=function(t,e,n){n=n||{},this.dom=e,this.id=t;var i=this,r=new wd,o=n.renderer;if(sf){if(!lf.vml)throw new Error("You need to require 'zrender/vml/vml' to support IE8");o="vml"}else o&&lf[o]||(o="canvas");var a=new lf[o](e,r,n,t);this.storage=r,this.painter=a;var s=ac.node||ac.worker?null:new je(a.getViewportRoot());this.handler=new Fc(r,a,s,a.root),this.animation=new Jd({stage:{update:v(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)}};hf.prototype={constructor:hf,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&&this.painter.configLayer(t,e),this._needsRefresh=!0},setBackgroundColor:function(t){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this._needsRefresh=!0},refreshImmediately:function(){this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh(),this._needsRefresh=this._needsRefreshHover=!1},refresh:function(){this._needsRefresh=!0},flush:function(){var t;this._needsRefresh&&(t=!0,this.refreshImmediately()),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately()),t&&this.trigger("rendered")},addHover:function(t,e){if(this.painter.addHover){var n=this.painter.addHover(t,e);return this.refreshHover(),n}},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,function(t){delete uf[t]}(this.id)}};var cf=(Object.freeze||Object)({version:"4.1.2",init:qe,dispose:function(t){if(t)t.dispose();else{for(var e in uf)uf.hasOwnProperty(e)&&uf[e].dispose();uf={}}return this},getInstance:function(t){return uf[t]},registerPainter:function(t,e){lf[t]=e}}),df=f,ff=b,pf=x,gf="series\0",mf=["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"],vf=0,yf=".",xf="___EC__COMPONENT__CONTAINER___",_f=0,wf=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={},o=0;o<t.length;o++){var a=t[o][1];if(!(n&&u(n,a)>=0||i&&u(i,a)<0)){var s=e.getShallow(a);null!=s&&(r[t[o][0]]=s)}}return r}},bf=wf([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Sf={getLineStyle:function(t){var e=bf(this,t);return e.lineDash=this.getLineDash(e.lineWidth),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&&("dashed"===e?[i,i]:[n,n])}},Mf=wf([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),If={getAreaStyle:function(t,e){return Mf(this,t,e)}},Cf=Math.pow,Tf=Math.sqrt,Af=1e-8,Df=1e-4,kf=Tf(3),Pf=1/3,Of=F(),Lf=F(),zf=F(),Nf=Math.min,Ef=Math.max,Bf=Math.sin,Rf=Math.cos,Ff=2*Math.PI,Vf=F(),Gf=F(),Wf=F(),Hf=[],Zf=[],Xf={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Yf=[],Uf=[],jf=[],qf=[],$f=Math.min,Kf=Math.max,Qf=Math.cos,Jf=Math.sin,tp=Math.sqrt,ep=Math.abs,np="undefined"!=typeof Float32Array,ip=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};ip.prototype={constructor:ip,_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,n){n=n||0,this._ux=ep(n/hd/t)||0,this._uy=ep(n/hd/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(Xf.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=ep(t-this._xi)>this._ux||ep(e-this._yi)>this._uy||this._len<5;return this.addData(Xf.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,o){return this.addData(Xf.C,t,e,n,i,r,o),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,n,i,r,o):this._ctx.bezierCurveTo(t,e,n,i,r,o)),this._xi=r,this._yi=o,this},quadraticCurveTo:function(t,e,n,i){return this.addData(Xf.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,o){return this.addData(Xf.A,t,e,n,n,i,r-i,0,o?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,o),this._xi=Qf(r)*n+t,this._yi=Jf(r)*n+e,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(Xf.R,t,e,n,i),this},closePath:function(){this.addData(Xf.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||!np||(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();np&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(r=0;e>r;r++)for(var o=t[r].data,a=0;a<o.length;a++)this.data[i++]=o[a];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,o=this._dashOffset,a=this._lineDash,s=this._ctx,l=this._xi,u=this._yi,h=t-l,c=e-u,d=tp(h*h+c*c),f=l,p=u,g=a.length;for(h/=d,c/=d,0>o&&(o=r+o),f-=(o%=r)*h,p-=o*c;h>0&&t>=f||0>h&&f>=t||0===h&&(c>0&&e>=p||0>c&&p>=e);)i=this._dashIdx,n=a[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?$f(f,t):Kf(f,t),c>=0?$f(p,e):Kf(p,e));h=f-t,c=p-e,this._dashOffset=-tp(h*h+c*c)},_dashedBezierTo:function(t,e,n,i,r,o){var a,s,l,u,h,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,m=this._yi,v=yn,y=0,x=this._dashIdx,_=f.length,w=0;for(0>d&&(d=c+d),d%=c,a=0;1>a;a+=.1)s=v(g,t,n,r,a+.1)-v(g,t,n,r,a),l=v(m,e,i,o,a+.1)-v(m,e,i,o,a),y+=tp(s*s+l*l);for(;_>x&&!((w+=f[x])>d);x++);for(a=(w-d)/y;1>=a;)u=v(g,t,n,r,a),h=v(m,e,i,o,a),x%2?p.moveTo(u,h):p.lineTo(u,h),a+=f[x]/y,x=(x+1)%_;x%2!=0&&p.lineTo(r,o),s=r-u,l=o-h,this._dashOffset=-tp(s*s+l*l)},_dashedQuadraticTo:function(t,e,n,i){var r=n,o=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,o)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,np&&(this.data=new Float32Array(t)))},getBoundingRect:function(){Yf[0]=Yf[1]=jf[0]=jf[1]=Number.MAX_VALUE,Uf[0]=Uf[1]=qf[0]=qf[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,n=0,i=0,r=0,o=0;o<t.length;){var a=t[o++];switch(1===o&&(e=t[o],n=t[o+1],i=e,r=n),a){case Xf.M:e=i=t[o++],n=r=t[o++],jf[0]=i,jf[1]=r,qf[0]=i,qf[1]=r;break;case Xf.L:kn(e,n,t[o],t[o+1],jf,qf),e=t[o++],n=t[o++];break;case Xf.C:Pn(e,n,t[o++],t[o++],t[o++],t[o++],t[o],t[o+1],jf,qf),e=t[o++],n=t[o++];break;case Xf.Q:On(e,n,t[o++],t[o++],t[o],t[o+1],jf,qf),e=t[o++],n=t[o++];break;case Xf.A:var s=t[o++],l=t[o++],u=t[o++],h=t[o++],c=t[o++],d=t[o++]+c;o+=1;var f=1-t[o++];1===o&&(i=Qf(c)*u+s,r=Jf(c)*h+l),Ln(s,l,u,h,c,d,f,jf,qf),e=Qf(d)*u+s,n=Jf(d)*h+l;break;case Xf.R:kn(i=e=t[o++],r=n=t[o++],i+t[o++],r+t[o++],jf,qf);break;case Xf.Z:e=i,n=r}Q(Yf,Yf,jf),J(Uf,Uf,qf)}return 0===o&&(Yf[0]=Yf[1]=Uf[0]=Uf[1]=0),new te(Yf[0],Yf[1],Uf[0]-Yf[0],Uf[1]-Yf[1])},rebuildPath:function(t){for(var e,n,i,r,o,a,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 Xf.M:e=i=s[c++],n=r=s[c++],t.moveTo(i,r);break;case Xf.L:o=s[c++],a=s[c++],(ep(o-i)>l||ep(a-r)>u||c===h-1)&&(t.lineTo(o,a),i=o,r=a);break;case Xf.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 Xf.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Xf.A:var f=s[c++],p=s[c++],g=s[c++],m=s[c++],v=s[c++],y=s[c++],x=s[c++],_=s[c++],w=g>m?g:m,b=g>m?1:g/m,S=g>m?m/g:1,M=v+y;Math.abs(g-m)>.001?(t.translate(f,p),t.rotate(x),t.scale(b,S),t.arc(0,0,w,v,M,1-_),t.scale(1/b,1/S),t.rotate(-x),t.translate(-f,-p)):t.arc(f,p,w,v,M,1-_),1===c&&(e=Qf(v)*g+f,n=Jf(v)*m+p),i=Qf(M)*g+f,r=Jf(M)*m+p;break;case Xf.R:e=i=s[c],n=r=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case Xf.Z:t.closePath(),i=e,r=n}}}},ip.CMD=Xf;var rp=2*Math.PI,op=2*Math.PI,ap=ip.CMD,sp=2*Math.PI,lp=1e-4,up=[-1,-1,-1],hp=[-1,-1],cp=Pd.prototype.getCanvasPattern,dp=Math.abs,fp=new ip(!0);Xn.prototype={constructor:Xn,type:"path",__dirtyPath:!0,strokeContainThreshold:5,segmentIgnoreThreshold:0,subPixelOptimize:!1,brush:function(t,e){var n=this.style,i=this.path||fp,r=n.hasStroke(),o=n.hasFill(),a=n.fill,s=n.stroke,l=o&&!!a.colorStops,u=r&&!!s.colorStops,h=o&&!!a.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,a,d)),u&&(d=d||this.getBoundingRect(),this._strokeGradient=n.getGradient(t,s,d))}l?t.fillStyle=this._fillGradient:h&&(t.fillStyle=cp.call(a,t)),u?t.strokeStyle=this._strokeGradient:c&&(t.strokeStyle=cp.call(s,t));var f=n.lineDash,p=n.lineDashOffset,g=!!t.setLineDash,m=this.getGlobalScale();if(i.setScale(m[0],m[1],this.segmentIgnoreThreshold),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)),o)if(null!=n.fillOpacity){v=t.globalAlpha;t.globalAlpha=n.fillOpacity*n.opacity,i.fill(t),t.globalAlpha=v}else i.fill(t);if(f&&g&&(t.setLineDash(f),t.lineDashOffset=p),r)if(null!=n.strokeOpacity){var v=t.globalAlpha;t.globalAlpha=n.strokeOpacity*n.opacity,i.stroke(t),t.globalAlpha=v}else 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 ip},getBoundingRect:function(){var t=this._rect,e=this.style,n=!t;if(n){var i=this.path;i||(i=this.path=new ip),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 o=e.lineWidth,a=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(o=Math.max(o,this.strokeContainThreshold||4)),a>1e-10&&(r.width+=o/a,r.height+=o/a,r.x-=o/a/2,r.y-=o/a/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 o=this.path.data;if(r.hasStroke()){var a=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(r.hasFill()||(a=Math.max(a,this.strokeContainThreshold)),function(t,e,n,i){return Zn(t,e,!0,n,i)}(o,a/s,t,e)))return!0}if(r.hasFill())return function(t,e,n){return Zn(t,0,!1,e,n)}(o,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=this.__dirtyText=!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):We.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(b(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&&dp(t[0]-1)>1e-10&&dp(t[3]-1)>1e-10?Math.sqrt(dp(t[0]*t[3]-t[2]*t[1])):1}},Xn.extend=function(t){var e=function(e){Xn.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,Xn);for(var n in t)"style"!==n&&"shape"!==n&&(e.prototype[n]=t[n]);return e},h(Xn,We);var pp=ip.CMD,gp=[[],[],[]],mp=Math.sqrt,vp=Math.atan2,yp=function(t,e){var n,i,r,o,a,s=t.data,l=pp.M,u=pp.C,h=pp.L,c=pp.R,d=pp.A,f=pp.Q;for(r=0,o=0;r<s.length;){switch(n=s[r++],o=r,i=0,n){case l:case h:i=1;break;case u:i=3;break;case f:i=2;break;case d:var p=e[4],g=e[5],m=mp(e[0]*e[0]+e[1]*e[1]),v=mp(e[2]*e[2]+e[3]*e[3]),y=vp(-e[1]/v,e[0]/m);s[r]*=m,s[r++]+=p,s[r]*=v,s[r++]+=g,s[r++]*=m,s[r++]*=v,s[r++]+=y,s[r++]+=y,o=r+=2;break;case c:x[0]=s[r++],x[1]=s[r++],K(x,x,e),s[o++]=x[0],s[o++]=x[1],x[0]+=s[r++],x[1]+=s[r++],K(x,x,e),s[o++]=x[0],s[o++]=x[1]}for(a=0;i>a;a++){var x;(x=gp[a])[0]=s[r++],x[1]=s[r++],K(x,x,e),s[o++]=x[0],s[o++]=x[1]}}},xp=Math.sqrt,_p=Math.sin,wp=Math.cos,bp=Math.PI,Sp=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])},Mp=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(Sp(t)*Sp(e))},Ip=function(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(Mp(t,e))},Cp=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,Tp=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g,Ap=function(t){We.call(this,t)};Ap.prototype={constructor:Ap,type:"text",brush:function(t,e){var n=this.style;this.__dirty&&Te(n),n.fill=n.stroke=n.shadowBlur=n.shadowColor=n.shadowOffsetX=n.shadowOffsetY=null;var i=n.text;return null!=i&&(i+=""),Ge(i,n)?(this.setTransform(t),De(this,t,i,n,null,e),void this.restoreTransform(t)):void(t.__attrCachedBy=Md.NONE)},getBoundingRect:function(){var t=this.style;if(this.__dirty&&Te(t),!this._rect){var e=t.text;null!=e?e+="":e="";var n=pe(t.text+"",t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich);if(n.x+=t.x||0,n.y+=t.y||0,Be(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(Ap,We);var Dp=Xn.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)}}),kp=[["shadowBlur",0],["shadowColor","#000"],["shadowOffsetX",0],["shadowOffsetY",0]],Pp=function(t){return ac.browser.ie&&ac.browser.version>=11?function(){var e,n=this.__clipPaths,i=this.style;if(n)for(var r=0;r<n.length;r++){var o=n[r],a=o&&o.shape,s=o&&o.type;if(a&&("sector"===s&&a.startAngle===a.endAngle||"rect"===s&&(!a.width||!a.height))){for(l=0;l<kp.length;l++)kp[l][2]=i[kp[l][0]],i[kp[l][0]]=kp[l][1];e=!0;break}}if(t.apply(this,arguments),e)for(var l=0;l<kp.length;l++)i[kp[l][0]]=kp[l][2]}:t},Op=Xn.extend({type:"sector",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},brush:Pp(Xn.prototype.brush),buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),o=Math.max(e.r,0),a=e.startAngle,s=e.endAngle,l=e.clockwise,u=Math.cos(a),h=Math.sin(a);t.moveTo(u*r+n,h*r+i),t.lineTo(u*o+n,h*o+i),t.arc(n,i,o,a,s,!l),t.lineTo(Math.cos(s)*r+n,Math.sin(s)*r+i),0!==r&&t.arc(n,i,r,s,a,l),t.closePath()}}),Lp=Xn.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)}}),zp=function(t,e){for(var n=t.length,i=[],r=0,o=1;n>o;o++)r+=q(t[o-1],t[o]);var a=r/2;a=n>a?n:a;for(o=0;a>o;o++){var s,l,u,h=o/(a-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([qn(s[0],f[0],l[0],u[0],d,p,g),qn(s[1],f[1],l[1],u[1],d,p,g)])}return i},Np=function(t,e,n,i){var r,o,a,s,l=[],u=[],h=[],c=[];if(i){a=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;f>d;d++)Q(a,a,t[d]),J(s,s,t[d]);Q(a,a,i[0]),J(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],o=t[(d+1)%f];else{if(0===d||d===f-1){l.push(G(t[d]));continue}r=t[d-1],o=t[d+1]}Z(u,o,r),U(u,u,e);var g=q(p,r),m=q(p,o),v=g+m;0!==v&&(g/=v,m/=v),U(h,u,-g),U(c,u,m);var y=W([],p,h),x=W([],p,c);i&&(J(y,y,a),Q(y,y,s),J(x,x,a),Q(x,x,s)),l.push(y),l.push(x)}return n&&l.push(l.shift()),l},Ep=Xn.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){$n(t,e,!0)}}),Bp=Xn.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){$n(t,e,!1)}}),Rp=Math.round,Fp={},Vp=Xn.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var n,i,r,o;this.subPixelOptimize?(Qn(Fp,e,this.style),n=Fp.x,i=Fp.y,r=Fp.width,o=Fp.height,Fp.r=e.r,e=Fp):(n=e.x,i=e.y,r=e.width,o=e.height),e.r?Ce(t,e):t.rect(n,i,r,o),t.closePath()}}),Gp={},Wp=Xn.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,i,r,o;this.subPixelOptimize?(Kn(Gp,e,this.style),n=Gp.x1,i=Gp.y1,r=Gp.x2,o=Gp.y2):(n=e.x1,i=e.y1,r=e.x2,o=e.y2);var a=e.percent;0!==a&&(t.moveTo(n,i),1>a&&(r=n*(1-a)+r*a,o=i*(1-a)+o*a),t.lineTo(r,o))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}}),Hp=[],Zp=Xn.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,o=e.y2,a=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&&(Tn(n,a,r,h,Hp),a=Hp[1],r=Hp[2],Tn(i,s,o,h,Hp),s=Hp[1],o=Hp[2]),t.quadraticCurveTo(a,s,r,o)):(1>h&&(bn(n,a,l,r,h,Hp),a=Hp[1],l=Hp[2],r=Hp[3],bn(i,s,u,o,h,Hp),s=Hp[1],u=Hp[2],o=Hp[3]),t.bezierCurveTo(a,s,l,u,r,o)))},pointAt:function(t){return ti(this.shape,t,!1)},tangentAt:function(t){var e=ti(this.shape,t,!0);return j(e,e)}}),Xp=Xn.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),o=e.startAngle,a=e.endAngle,s=e.clockwise,l=Math.cos(o),u=Math.sin(o);t.moveTo(l*r+n,u*r+i),t.arc(n,i,r,o,a,!s)}}),Yp=Xn.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],t[n].segmentIgnoreThreshold)},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(),Xn.prototype.getBoundingRect.call(this)}}),Up=function(t){this.colorStops=t||[]};Up.prototype={constructor:Up,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}};var jp=function(t,e,n,i,r,o){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=o||!1,Up.call(this,r)};jp.prototype={constructor:jp},h(jp,Up);var qp=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,Up.call(this,i)};qp.prototype={constructor:qp},h(qp,Up),ei.prototype.incremental=!0,ei.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.dirty(),this.notClear=!1},ei.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.dirty()},ei.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},ei.prototype.eachPendingDisplayable=function(t){for(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])},ei.prototype.update=function(){this.updateTransform();for(t=this._cursor;t<this._displayables.length;t++){(e=this._displayables[t]).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}},ei.prototype.brush=function(t){for(e=this._cursor;e<this._displayables.length;e++){(n=this._displayables[e]).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 $p=[];ei.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new te(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($p)),t.union(i)}this._rect=t}return this._rect},ei.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e);if(this.getBoundingRect().contain(n[0],n[1]))for(var i=0;i<this._displayables.length;i++){if(this._displayables[i].contain(t,e))return!0}return!1},h(ei,We);var Kp=Math.max,Qp=Math.min,Jp={},tg=1,eg="emphasis",ng="normal",ig=1,rg={},og={},ag=function(t,e){for(var n=[],i=t.length,r=0;i>r;r++){var o=t[r];o.path||o.createPathProxy(),o.__dirtyPath&&o.buildPath(o.path,o.shape,!0),n.push(o.path)}var a=new Xn(e);return a.createPathProxy(),a.buildPath=function(t){t.appendPath(n);var e=t.getContext();e&&t.rebuildPath(e)},a},sg=Jn,lg=B(),ug=0;ii("circle",Dp),ii("sector",Op),ii("ring",Lp),ii("polygon",Ep),ii("polyline",Bp),ii("rect",Vp),ii("line",Wp),ii("bezierCurve",Zp),ii("arc",Xp);var hg=(Object.freeze||Object)({Z2_EMPHASIS_LIFT:tg,CACHED_LABEL_STYLE_PROPERTIES:{color:"textFill",textBorderColor:"textStroke",textBorderWidth:"textStrokeWidth"},extendShape:ni,extendPath:function(t,e){return function(t,e){return Xn.extend(Un(t,e))}(t,e)},registerShape:ii,getShapeClass:ri,makePath:oi,makeImage:ai,mergePath:ag,resizePath:li,subPixelOptimizeLine:function(t){return Kn(t.shape,t.shape,t.style),t},subPixelOptimizeRect:function(t){return Qn(t.shape,t.shape,t.style),t},subPixelOptimize:sg,setElementHoverStyle:pi,setHoverStyle:_i,setAsHighDownDispatcher:wi,isHighDownDispatcher:bi,getHighlightDigit:Si,setLabelStyle:Mi,modifyLabelStyle:function(t,e,n){var i=t.style;e&&(ki(i),t.setStyle(e),Di(i)),i=t.__hoverStl,n&&i&&(ki(i),a(i,n),Di(i))},setTextStyle:Ii,setText:function(t,e,n){var i,r={isRectText:!0};!1===n?i=!0:r.autoColor=n,Ci(t,e,r,i)},getFont:Pi,updateProps:Li,initProps:zi,getTransform:Ni,applyTransform:Ei,transformDirection:Bi,groupTransition:Ri,clipPointsByRect:Fi,clipRectByRect:function(t,e){var n=Kp(t.x,e.x),i=Qp(t.x+t.width,e.x+e.width),r=Kp(t.y,e.y),o=Qp(t.y+t.height,e.y+e.height);return i>=n&&o>=r?{x:n,y:r,width:i-n,height:o-r}:void 0},createIcon:Vi,linePolygonIntersect:function(t,e,n,i,r){for(var o=0,a=r[r.length-1];o<r.length;o++){var s=r[o];if(Gi(t,e,n,i,s[0],s[1],a[0],a[1]))return!0;a=s}},lineLineIntersect:Gi,Group:yd,Image:He,Text:Ap,Circle:Dp,Sector:Op,Ring:Lp,Polygon:Ep,Polyline:Bp,Rect:Vp,Line:Wp,BezierCurve:Zp,Arc:Xp,IncrementalDisplayable:ei,CompoundPath:Yp,LinearGradient:jp,RadialGradient:qp,BoundingRect:te}),cg=["textStyle","color"],dg={getTextColor:function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(cg):null)},getFont:function(){return Pi({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},getTextRect:function(t){return pe(t,this.getFont(),this.getShallow("align"),this.getShallow("verticalAlign")||this.getShallow("baseline"),this.getShallow("padding"),this.getShallow("lineHeight"),this.getShallow("rich"),this.getShallow("truncateText"))}},fg=wf([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["textPosition"],["textAlign"]]),pg={getItemStyle:function(t,e){var n=fg(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]}},gg=c,mg=on();Hi.prototype={constructor:Hi,init:null,mergeOption:function(t){r(this.option,t,!0)},get:function(t,e){return null==t?this.option:Zi(this.option,this.parsePath(t),!e&&Xi(this,t))},getShallow:function(t,e){var n=this.option,i=null==n?n:n[t],r=!e&&Xi(this,t);return null==i&&r&&(i=r.getShallow(t)),i},getModel:function(t,e){var n,i=null==t?this.option:Zi(this.option,t=this.parsePath(t));return e=e||(n=Xi(this,t))&&n.getModel(t),new Hi(i,e,this.ecModel)},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){return new(0,this.constructor)(i(this.option))},setReadOnly:function(){},parsePath:function(t){return"string"==typeof t&&(t=t.split(".")),t},customizeGetParent:function(t){mg(this).getParent=t},isAnimationEnabled:function(){if(!ac.node){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}}},cn(Hi),dn(Hi),gg(Hi,Sf),gg(Hi,If),gg(Hi,dg),gg(Hi,pg);var vg=0,yg=1e-4,xg=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d\d)(?::(\d\d)(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/,_g=(Object.freeze||Object)({linearMap:Ui,parsePercent:ji,round:qi,asc:$i,getPrecision:Ki,getPrecisionSafe:Qi,getPixelPrecision:Ji,getPercentWithPrecision:tr,MAX_SAFE_INTEGER:9007199254740991,remRadian:er,isRadianAroundZero:nr,parseDate:ir,quantity:rr,quantityExponent:or,nice:ar,quantile:function(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],o=n-i;return o?r+o*(t[i]-r):r},reformIntervals:function(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 o=t[r].interval,a=t[r].close,s=0;2>s;s++)o[s]<=n&&(o[s]=n,a[s]=s?1:1-i),n=o[s],i=a[s];o[0]===o[1]&&a[0]*a[1]!=1?t.splice(r,1):r++}return t},isNumeric:function(t){return t-parseFloat(t)>=0}}),wg=P,bg=/([&<>"'])/g,Sg={"&":"&","<":"<",">":">",'"':""","'":"'"},Mg=["a","b","c","d","e","f","g"],Ig=function(t,e){return"{"+t+(null==e?"":e)+"}"},Cg=ye,Tg=(Object.freeze||Object)({addCommas:sr,toCamelCase:lr,normalizeCssArray:wg,encodeHTML:ur,formatTpl:hr,formatTplSimple:function(t,e,n){return f(e,function(e,i){t=t.replace("{"+i+"}",n?ur(e):e)}),t},getTooltipMarker:cr,formatTime:fr,capitalFirst:pr,truncateText:Cg,getTextBoundingRect:function(t){return pe(t.text,t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich,t.truncate)},getTextRect:function(t,e,n,i,r,o,a,s){return pe(t,e,n,i,r,s,o,a)}}),Ag=f,Dg=["left","right","top","bottom","width","height"],kg=[["width","left","right"],["height","top","bottom"]],Pg=gr,Og=(y(gr,"vertical"),y(gr,"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")}}}),Lg=on(),zg=Hi.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){Hi.call(this,t,e,n,i),this.uid=Yi("ec_cpt_model")},init:function(t,e,n){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?xr(t):{};r(t,e.getTheme().get(this.mainType)),r(t,this.getDefaultOption()),n&&yr(t,i,n)},mergeOption:function(t){r(this.option,t,!0);var e=this.layoutMode;e&&yr(this.option,t,e)},optionUpdated:function(){},getDefaultOption:function(){var t=Lg(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 o={},a=e.length-1;a>=0;a--)o=r(o,e[a],!0);t.defaultOption=o}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});gn(zg,{registerWhenExtend:!0}),function(t){var e={};t.registerSubTypeDefaulter=function(t,n){t=hn(t),e[t.main]=n},t.determineSubType=function(n,i){var r=i.type;if(!r){var o=hn(n).main;t.hasSubTypes(n)&&e[o]&&(r=e[o](i))}return r}}(zg),function(t,e){function n(t){var n={},r=[];return f(t,function(o){var a=i(n,o),s=function(t,e){var n=[];return f(t,function(t){u(e,t)>=0&&n.push(t)}),n}(a.originalDeps=e(o),t);a.entryCount=s.length,0===a.entryCount&&r.push(o),f(s,function(t){u(a.predecessor,t)<0&&a.predecessor.push(t);var e=i(n,t);u(e.successor,t)<0&&e.successor.push(o)})}),{graph:n,noEntryList:r}}function i(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}t.topologicalTravel=function(t,e,i,r){function o(t){l[t].entryCount--,0===l[t].entryCount&&u.push(t)}function a(t){h[t]=!0,o(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?a:o)}f(h,function(){throw new Error("Circle dependency may exists")})}}}(zg,function(t){var e=[];return f(zg.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=p(e,function(t){return hn(t).main}),"dataset"!==t&&u(e,"dataset")<=0&&e.unshift("dataset"),e}),c(zg,Og);var Ng="";"undefined"!=typeof navigator&&(Ng=navigator.platform||"");var Eg={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:Ng.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},Bg=on(),Rg={clearColorPalette:function(){Bg(this).colorIdx=0,Bg(this).colorNameMap={}},getColorFromPalette:function(t,e,n){var i=Bg(e=e||this),r=i.colorIdx||0,o=i.colorNameMap=i.colorNameMap||{};if(o.hasOwnProperty(t))return o[t];var a=$e(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?function(t,e){for(var n=t.length,i=0;n>i;i++)if(t[i].length>e)return t[i];return t[n-1]}(s,n):a;if((l=l||a)&&l.length){var u=l[r];return t&&(o[t]=u),i.colorIdx=(r+1)%l.length,u}}},Fg={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],o=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",o),br(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),br(o)&&(i.set("y",o),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),br(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],o=r.findAxisModel("radiusAxis"),a=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",o),n.set("angle",a),br(o)&&(i.set("radius",o),e.firstCategoryDimIndex=0),br(a)&&(i.set("angle",a),e.firstCategoryDimIndex=1)},geo:function(t,e){e.coordSysDims=["lng","lat"]},parallel:function(t,e,n,i){var r=t.ecModel,o=r.getComponent("parallel",t.get("parallelIndex")),a=e.coordSysDims=o.dimensions.slice();f(o.parallelAxisIndex,function(t,o){var s=r.getComponent("parallelAxis",t),l=a[o];n.set(l,s),br(s)&&null==e.firstCategoryDimIndex&&(i.set(l,s),e.firstCategoryDimIndex=o)})}},Vg="original",Gg="arrayRows",Wg="objectRows",Hg="keyedColumns",Zg="unknown",Xg="typedArray",Yg="column",Ug="row";Sr.seriesDataToSource=function(t){return new Sr({data:t,sourceFormat:M(t)?Xg:Vg,fromDataset:!1})},dn(Sr);var jg=on(),qg="\0_ec_inner",$g=Hi.extend({init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new Hi(n),this._optionManager=i},setOption:function(t,e){O(!(qg 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)):Dr.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 o=n.getMediaOption(this,this._api);o.length&&f(o,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(t){var e=this.option,n=this._componentsMap,o=[];(function(t){jg(t).datasetMap=B()})(this),f(t,function(t,n){null!=t&&(zg.hasClass(n)?n&&o.push(n):e[n]=null==e[n]?i(t):r(e[n],t,!0))}),zg.topologicalTravel(o,zg.getAllClassMainTypes(),function(i,r){var o=$e(t[i]),s=Je(n.get(i),o);tn(s),f(s,function(t){var e=t.option;b(e)&&(t.keyInfo.mainType=i,t.keyInfo.subType=function(t,e,n){return e.type?e.type:n?n.subType:zg.determineSubType(t,e)}(i,e,t.exist))});var l=function(t,e){x(e)||(e=e?[e]:[]);var n={};return f(e,function(e){n[e]=(t.get(e)||[]).slice()}),n}(n,r);e[i]=[],n.set(i,[]),f(s,function(t,r){var o=t.exist,s=t.option;if(O(b(s)||o,"Empty component definition"),s){var u=zg.getClass(i,t.keyInfo.subType,!0);if(o&&o.constructor===u)o.name=t.keyInfo.name,o.mergeOption(s,this),o.optionUpdated(s,!1);else{var h=a({dependentModels:l,componentIndex:r},t.keyInfo);a(o=new u(s,this,this,h),h),o.init(s,this,this,h),o.optionUpdated(null,!0)}}else o.mergeOption({},this),o.optionUpdated({},!1);n.get(i)[r]=o,e[i][r]=o.option},this),"series"===i&&kr(this,n.get("series"))},this),this._seriesIndicesMap=B(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var t=i(this.option);return f(t,function(e,n){if(zg.hasClass(n)){for(var i=(e=$e(e)).length-1;i>=0;i--)nn(e[i])&&e.splice(i,1);t[n]=e}}),delete t[qg],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,o=this._componentsMap.get(e);if(!o||!o.length)return[];var a;if(null!=n)x(n)||(n=[n]),a=m(p(n,function(t){return o[t]}),function(t){return!!t});else if(null!=i){var s=x(i);a=m(o,function(t){return s&&u(i,t.id)>=0||!s&&t.id===i})}else if(null!=r){var l=x(r);a=m(o,function(t){return l&&u(r,t.name)>=0||!l&&t.name===r})}else a=o.slice();return Pr(a,t)},findComponents:function(t){var e=t.query,n=t.mainType,i=function(t){var e=n+"Index",i=n+"Id",r=n+"Name";return!t||null==t[e]&&null==t[i]&&null==t[r]?null:{mainType:n,index:t[e],id:t[i],name:t[r]}}(e);return function(e){return t.filter?m(e,t.filter):e}(Pr(i?this.queryComponents(i):this._componentsMap.get(n),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(w(t))f(i.get(t),e,n);else if(b(t)){f(this.findComponents(t),e,n)}},getSeriesByName:function(t){return m(this._componentsMap.get("series"),function(e){return e.name===t})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(t){return m(this._componentsMap.get("series"),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){kr(this,m(this._componentsMap.get("series"),t,e))},restoreData:function(t){var e=this._componentsMap;kr(this,e.get("series"));var n=[];e.each(function(t,e){n.push(e)}),zg.topologicalTravel(n,zg.getAllClassMainTypes(),function(n){f(e.get(n),function(e){("series"!==n||!function(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}}(e,t))&&e.restoreData()})})}});c($g,Rg);var Kg=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"],Qg={};Lr.prototype={constructor:Lr,create:function(t,e){var n=[];f(Qg,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()}},Lr.register=function(t,e){Qg[t]=e},Lr.get=function(t){return Qg[t]};var Jg=f,tm=i,em=p,nm=r,im=/^(min|max)?(.+)$/;zr.prototype={constructor:zr,setOption:function(t,e){t&&f($e(t.series),function(t){t&&t.data&&M(t.data)&&z(t.data)}),t=tm(t);var n=this._optionBackup,i=function(t,e,n){var i,r,o=[],a=[],s=t.timeline;if(t.baseOption&&(r=t.baseOption),(s||t.options)&&(r=r||{},o=(t.options||[]).slice()),t.media){r=r||{};var l=t.media;Jg(l,function(t){t&&t.option&&(t.query?a.push(t):i||(i=t))})}return r||(r=t),r.timeline||(r.timeline=s),Jg([r].concat(o).concat(p(a,function(t){return t.option})),function(t){Jg(e,function(e){e(t,n)})}),{baseOption:r,timelineOptions:o,mediaDefault:i,mediaList:a}}.call(this,t,e,!n);this._newBaseOption=i.baseOption,n?(function(t,e){Jg(e=e||{},function(e,n){if(null!=e){var i=t[n];if(zg.hasClass(n)){e=$e(e);var r=Je(i=$e(i),e);t[n]=em(r,function(t){return t.option&&t.exist?nm(t.exist,t.option,!0):t.exist||t.option})}else t[n]=nm(i,e,!0)}})}(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=em(e.timelineOptions,tm),this._mediaList=em(e.mediaList,tm),this._mediaDefault=tm(e.mediaDefault),this._currentMediaIndices=[],tm(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(e=tm(n[i.getCurrentIndex()],!0))}return e},getMediaOption:function(){var t=this._api.getWidth(),e=this._api.getHeight(),n=this._mediaList,i=this._mediaDefault,r=[],o=[];if(!n.length&&!i)return o;for(var a=0,s=n.length;s>a;a++)Nr(n[a].query,t,e)&&r.push(a);return!r.length&&i&&(r=[-1]),r.length&&!function(t,e){return t.join(",")===e.join(",")}(r,this._currentMediaIndices)&&(o=em(r,function(t){return tm(-1===t?i.option:n[t].option)})),this._currentMediaIndices=r,o}};var rm=f,om=b,am=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"],sm=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],lm=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],um=function(t,e){(function(t,e){rm(Wr(t.series),function(t){om(t)&&Gr(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),rm(n,function(e){rm(Wr(t[e]),function(t){t&&(Fr(t,"axisLabel"),Fr(t.axisPointer,"label"))})}),rm(Wr(t.parallel),function(t){var e=t&&t.parallelAxisDefault;Fr(e,"axisLabel"),Fr(e&&e.axisPointer,"label")}),rm(Wr(t.calendar),function(t){Br(t,"itemStyle"),Fr(t,"dayLabel"),Fr(t,"monthLabel"),Fr(t,"yearLabel")}),rm(Wr(t.radar),function(t){Fr(t,"name")}),rm(Wr(t.geo),function(t){om(t)&&(Vr(t),rm(Wr(t.regions),function(t){Vr(t)}))}),rm(Wr(t.timeline),function(t){Vr(t),Br(t,"label"),Br(t,"itemStyle"),Br(t,"controlStyle",!0);var e=t.data;x(e)&&f(e,function(t){b(t)&&(Br(t,"label"),Br(t,"itemStyle"))})}),rm(Wr(t.toolbox),function(t){Br(t,"iconStyle"),rm(t.feature,function(t){Br(t,"iconStyle")})}),Fr(Hr(t.axisPointer),"label"),Fr(Hr(t.tooltip).axisPointer,"label")})(t,e),t.series=$e(t.series),f(t.series,function(t){if(b(t)){var e=t.type;if("line"===e)null!=t.clipOverflow&&(t.clip=t.clipOverflow);else if("pie"===e||"gauge"===e)null!=t.clockWise&&(t.clockwise=t.clockWise);else if("gauge"===e){var n=function(t,e){e=e.split(",");for(var n=t,i=0;i<e.length&&null!=(n=n&&n[e[i]]);i++);return n}(t,"pointer.color");null!=n&&function(t,e,n,i){e=e.split(",");for(var r,o=t,a=0;a<e.length-1;a++)r=e[a],null==o[r]&&(o[r]={}),o=o[r];(i||null==o[e[a]])&&(o[e[a]]=n)}(t,"itemStyle.color",n)}Zr(t)}}),t.dataRange&&(t.visualMap=t.dataRange),f(lm,function(e){var n=t[e];n&&(x(n)||(n=[n]),f(n,function(t){Zr(t)}))})},hm=Yr.prototype;hm.pure=!1,hm.persistent=!0,hm.getSource=function(){return this._source};var cm={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:qr},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:Ur,getItem:jr,appendData:qr},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:Ur,getItem:jr,appendData:qr},typedArray:{persistent:!1,pure:!0,count:function(){return this._data?this._data.length/this._dimSize:0},getItem:function(t,e){t-=this._offset,e=e||[];for(var 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}}},dm={arrayRows:$r,objectRows:function(t,e,n,i){return null!=n?t[i]:t},keyedColumns:$r,original:function(t,e,n){var i=Qe(t);return null!=n&&i instanceof Array?i[n]:i},typedArray:$r},fm={arrayRows:Kr,objectRows:function(t,e){return Qr(t[e],this._dimensionInfos[e])},keyedColumns:Kr,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return!this._rawData.pure&&function(t){return ff(t)&&!(t instanceof Array)}(t)&&(this.hasItemOption=!0),Qr(r instanceof Array?r[i]:r,this._dimensionInfos[e])},typedArray:function(t,e,n,i){return t[i]}},pm=/\{@(.+?)\}/g,gm={getDataParams:function(t,e){var n=this.getData(e),i=this.getRawValue(t,e),r=n.getRawIndex(t),o=n.getName(t),a=n.getRawDataItem(t),s=n.getItemVisual(t,"color"),l=n.getItemVisual(t,"borderColor"),u=this.ecModel.getComponent("tooltip"),h=un(u&&u.get("renderMode")),c=this.mainType,d="series"===c,f=n.userOutput;return{componentType:c,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:d?this.subType:null,seriesIndex:this.seriesIndex,seriesId:d?this.id:null,seriesName:d?this.name:null,name:o,dataIndex:r,data:a,dataType:e,value:i,color:s,borderColor:l,dimensionNames:f?f.dimensionNames:null,encode:f?f.encode:null,marker:cr({color:s,renderMode:h}),$vars:["seriesName","name","value"]}},getFormattedLabel:function(t,e,n,i,r){e=e||"normal";var o=this.getData(n),a=o.getItemModel(t),s=this.getDataParams(t,n);null!=i&&s.value instanceof Array&&(s.value=s.value[i]);var l=a.get("normal"===e?[r||"label","formatter"]:[e,r||"label","formatter"]);if("function"==typeof l)return s.status=e,s.dimensionIndex=i,l(s);if("string"==typeof l){return hr(l,s).replace(pm,function(e,n){var i=n.length;return"["===n.charAt(0)&&"]"===n.charAt(i-1)&&(n=+n.slice(1,i-1)),Jr(o,t,n)})}},getRawValue:function(t,e){return Jr(this.getData(e),t)},formatTooltip:function(){}},mm=no.prototype;mm.perform=function(t){function e(t){return!(t>=1)&&(t=1),t}var n=this._upstream,i=t&&t.skip;if(this._dirty&&n){var r=this.context;r.data=r.outputData=n.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var o;this._plan&&!i&&(o=this._plan(this.context));var a=e(this._modBy),s=this._modDataCount||0,l=e(t&&t.modBy),u=t&&t.modDataCount||0;(a!==l||s!==u)&&(o="reset");var h;(this._dirty||"reset"===o)&&(this._dirty=!1,h=function(t,e){t._dueIndex=t._outputDueEnd=t._dueEnd=0,t._settedOutputEnd=null;var n,i;!e&&t._reset&&((n=t._reset(t.context))&&n.progress&&(i=n.forceFirstProgress,n=n.progress),x(n)&&!n.length&&(n=null)),t._progress=n,t._modBy=t._modDataCount=null;var r=t._downstream;return r&&r.dirty(),i}(this,i)),this._modBy=l,this._modDataCount=u;var c=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var d=this._dueIndex,f=Math.min(null!=c?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(h||f>d)){var p=this._progress;if(x(p))for(var g=0;g<p.length;g++)io(this,p[g],d,f,l,u);else io(this,p,d,f,l,u)}this._dueIndex=f;var m=null!=this._settedOutputEnd?this._settedOutputEnd:f;this._outputDueEnd=m}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()};var vm=function(){var t,e,n,i,r,o={reset:function(a,s,l,u){e=a,t=s,n=l,i=u,r=Math.ceil(i/n),o.next=n>1&&i>0?function(){var o=e%r*n+Math.ceil(e/r),a=e>=t?null:i>o?o:e;return e++,a}:function(){return t>e?e++:null}}};return o}();mm.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},mm.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},mm.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},mm.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},mm.getUpstream=function(){return this._upstream},mm.getDownstream=function(){return this._downstream},mm.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t};var ym=on(),xm=zg.extend({type:"series.__base__",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,visualColorAccessPath:"itemStyle.color",visualBorderColorAccessPath:"itemStyle.borderColor",layoutMode:null,init:function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=eo({count:oo,reset:ao}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),Mr(this);var i=this.getInitialData(t,n);so(i,this),this.dataTask.context.data=i,ym(this).dataBeforeProcessed=i,ro(this)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?xr(t):{},o=this.subType;zg.hasClass(o)&&(o+="Series"),r(t,e.getTheme().get(this.subType)),r(t,this.getDefaultOption()),Ke(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&yr(t,i,n)},mergeOption:function(t,e){t=r(this.option,t,!0),this.fillDataTextStyle(t.data);var n=this.layoutMode;n&&yr(this.option,t,n),Mr(this);var i=this.getInitialData(t,e);so(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,ym(this).dataBeforeProcessed=i,ro(this)},fillDataTextStyle:function(t){if(t&&!M(t))for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&Ke(t[n],"label",e)},getInitialData:function(){},appendData:function(t){this.getRawData().appendData(t.data)},getData:function(t){var e=uo(this);if(e){var n=e.context.data;return null==t?n:n.getLinkedData(t)}return ym(this).data},setData:function(t){var e=uo(this);if(e){var n=e.context;n.data!==t&&e.modifyOutputEnd&&e.setOutputEnd(t.count()),n.outputData=t,e!==this.dataTask&&(n.data=t)}ym(this).data=t},getSource:function(){return function(t){return jg(t).source}(this)},getRawData:function(){return ym(this).dataBeforeProcessed},getBaseAxis:function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},formatTooltip:function(t,e,n,i){var r=this,o="html"===(i=i||"html")?"<br/>":"\n",a="richText"===i,s={},l=0,u=this.getData(),h=u.mapDimension("defaultedTooltip",!0),c=h.length,d=this.getRawValue(t),p=x(d),m=u.getItemVisual(t,"color");b(m)&&m.colorStops&&(m=(m.colorStops[0]||{}).color),m=m||"transparent";var v=(c>1||p&&!c?function(n){function o(t,n){var o=u.getDimensionInfo(n);if(o&&!1!==o.otherDims.tooltip){var h=o.type,f="sub"+r.seriesIndex+"at"+l,p=cr({color:m,type:"subItem",renderMode:i,markerId:f}),g="string"==typeof p?p:p.content,v=(c?g+ur(o.displayName||"-")+": ":"")+ur("ordinal"===h?t+"":"time"===h?e?"":fr("yyyy/MM/dd hh:mm:ss",t):sr(t));v&&d.push(v),a&&(s[f]=m,++l)}}var c=g(n,function(t,e,n){var i=u.getDimensionInfo(n);return t|=i&&!1!==i.tooltip&&null!=i.displayName},0),d=[];h.length?f(h,function(e){o(Jr(u,t,e),e)}):f(n,o);var p=c?a?"\n":"<br/>":"",v=p+d.join(p||", ");return{renderMode:i,content:v,style:s}}(d):function(t){return{renderMode:i,content:ur(sr(t)),style:s}}(c?Jr(u,t,h[0]):p?d[0]:d)).content,y=r.seriesIndex+"at"+l,_=cr({color:m,type:"item",renderMode:i,markerId:y});s[y]=m,++l;var w=u.getName(t),S=this.name;en(this)||(S=""),S=S?ur(S)+(e?": ":o):"";var M="string"==typeof _?_:_.content;return{html:e?M+S+v:S+M+(w?ur(w)+": "+v:v),markers:s}},isAnimationEnabled:function(){if(ac.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=Rg.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(xm,gm),c(xm,Rg);var _m=function(){this.group=new yd,this.uid=Yi("viewComponent")};_m.prototype={constructor:_m,init:function(){},render:function(){},dispose:function(){},filterForExposedEvent:null};var wm=_m.prototype;wm.updateView=wm.updateLayout=wm.updateVisual=function(){},cn(_m),gn(_m,{registerWhenExtend:!0});var bm=function(){var t=on();return function(e){var n=t(e),i=e.pipelineContext,r=n.large,o=n.progressiveRender,a=n.large=i.large,s=n.progressiveRender=i.progressiveRender;return!!(r^a||o^s)&&"reset"}},Sm=on(),Mm=bm(),Im=ho.prototype={type:"chart",init:function(){},render:function(){},highlight:function(t,e,n,i){fo(t.getData(),i,"emphasis")},downplay:function(t,e,n,i){fo(t.getData(),i,"normal")},remove:function(){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null,filterForExposedEvent:null};Im.updateView=Im.updateLayout=Im.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},cn(ho),gn(ho,{registerWhenExtend:!0}),ho.markUpdateMethod=function(t,e){Sm(t).updateMethod=e};var Cm={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Tm="\0__throttleOriginMethod",Am="\0__throttleRate",Dm="\0__throttleType",km={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.name,null,e.getSeriesCount());n.setVisual("color",r);var o=(t.visualBorderColorAccessPath||"itemStyle.borderColor").split("."),a=t.get(o);if(n.setVisual("borderColor",a),!e.isSeriesFiltered(t)){"function"!=typeof r||r instanceof Up||n.each(function(e){n.setItemVisual(e,"color",r(t.getDataParams(e)))});return{dataEach:n.hasItemOption?function(t,e){var n=t.getItemModel(e),r=n.get(i,!0),a=n.get(o,!0);null!=r&&t.setItemVisual(e,"color",r),null!=a&&t.setItemVisual(e,"borderColor",a)}:null}}}},Pm={legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}},Om=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=r.get(t);if(null==e){for(var n=t.split("."),i=Pm.aria,o=0;o<n.length;++o)i=i[n[o]];return i}return e}var r=e.getModel("aria");if(r.get("show")){if(r.get("description"))return void t.setAttribute("aria-label",r.get("description"));var o=0;e.eachSeries(function(){++o},this);var a,s=r.get("data.maxCount")||10,l=r.get("series.maxCount")||10,u=Math.min(o,l);if(!(1>o)){var h=function(){var t=e.getModel("title").option;return t&&t.length&&(t=t[0]),t&&t.text}();a=h?n(i("general.withTitle"),{title:h}):i("general.withoutTitle");var c=[];a+=n(i(o>1?"series.multiple.prefix":"series.single.prefix"),{seriesCount:o}),e.eachSeries(function(t,e){if(u>e){var r,a=t.get("name"),l="series."+(o>1?"multiple":"single")+".";r=n(r=i(a?l+"withName":l+"withoutName"),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:function(t){return Pm.series.typeNames[t]||"自定义图"}(t.subType)});var h=t.getData();window.data=h,r+=h.count()>s?n(i("data.partialData"),{displayCnt:s}):i("data.allData");for(var d=[],f=0;f<h.count();f++)if(s>f){var p=h.getName(f),g=Jr(h,f);d.push(n(i(p?"data.withName":"data.withoutName"),{name:p,value:g}))}r+=d.join(i("data.separator.middle"))+i("data.separator.end"),c.push(r)}}),a+=c.join(i("series.multiple.separator.middle"))+i("series.multiple.separator.end"),t.setAttribute("aria-label",a)}}},Lm=Math.PI,zm=xo.prototype;zm.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(t){var e=t.overallTask;e&&e.dirty()})},zm.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,o=i&&i.modDataCount;return{step:r,modBy:null!=o?Math.ceil(o/r):null,modDataCount:o}}},zm.getPipeline=function(t){return this._pipelineMap.get(t)},zm.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),r=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,o=t.get("large")&&i>=t.get("largeThreshold"),a="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:r,modDataCount:a,large:o}},zm.restorePipelines=function(t){var e=this,n=e._pipelineMap=B();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()),blockIndex:-1,step:Math.round(i||700),count:0}),Ao(e,t,t.dataTask)})},zm.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.ecInstance.getModel(),n=this.api;f(this._allHandlers,function(i){var r=t.get(i.uid)||t.set(i.uid,[]);i.reset&&function(t,e,n,i,r){function o(n){var o=n.uid,s=a.get(o)||a.set(o,eo({plan:Mo,reset:Io,count:To}));s.context={model:n,ecModel:i,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:t},Ao(t,n,s)}var a=n.seriesTaskMap||(n.seriesTaskMap=B()),s=e.seriesType,l=e.getTargetSeries;e.createOnAllSeries?i.eachRawSeries(o):s?i.eachRawSeriesByType(s,o):l&&l(i,r).each(o);var u=t._pipelineMap;a.each(function(t,e){u.get(e)||(t.dispose(),a.removeKey(e))})}(this,i,r,e,n),i.overallReset&&function(t,e,n,i,r){function o(e){var n=e.uid,i=s.get(n);i||(i=s.set(n,eo({reset:bo,onDirty:So})),a.dirty()),i.context={model:e,overallProgress:h,modifyOutputEnd:c},i.agent=a,i.__block=h,Ao(t,e,i)}var a=n.overallTask=n.overallTask||eo({reset:wo});a.context={ecModel:i,api:r,overallReset:e.overallReset,scheduler:t};var s=a.agentStubMap=a.agentStubMap||B(),l=e.seriesType,u=e.getTargetSeries,h=!0,c=e.modifyOutputEnd;l?i.eachRawSeriesByType(l,o):u?u(i,r).each(o):(h=!1,f(i.getSeries(),o));var d=t._pipelineMap;s.each(function(t,e){d.get(e)||(t.dispose(),a.dirty(),s.removeKey(e))})}(this,i,r,e,n)},this)},zm.prepareView=function(t,e,n,i){var r=t.renderTask,o=r.context;o.model=e,o.ecModel=n,o.api=i,r.__block=!t.incrementalPrepareRender,Ao(this,e,r)},zm.performDataProcessorTasks=function(t,e){_o(this,this._dataProcessorHandlers,t,e,{block:!0})},zm.performVisualTasks=function(t,e,n){_o(this,this._visualHandlers,t,e,n)},zm.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},zm.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var Nm=zm.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},Em=Co(0);xo.wrapStageHandler=function(t,e){return _(t)&&(t={overallReset:t,seriesType:function(t){Bm=null;try{t(Rm,Fm)}catch(e){}return Bm}(t)}),t.uid=Yi("stageHandler"),e&&(t.visualType=e),t};var Bm,Rm={},Fm={};Do(Rm,$g),Do(Fm,Or),Rm.eachSeriesByType=Rm.eachRawSeriesByType=function(t){Bm=t},Rm.eachComponent=function(t){"series"===t.mainType&&t.subType&&(Bm=t.subType)};var Vm=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],Gm={color:Vm,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],Vm]},Wm="#eee",Hm=function(){return{axisLine:{lineStyle:{color:Wm}},axisTick:{lineStyle:{color:Wm}},axisLabel:{textStyle:{color:Wm}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:Wm}}}},Zm=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],Xm={color:Zm,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:Wm},crossStyle:{color:Wm}}},legend:{textStyle:{color:Wm}},textStyle:{color:Wm},title:{textStyle:{color:Wm}},toolbox:{iconStyle:{normal:{borderColor:Wm}}},dataZoom:{textStyle:{color:Wm}},visualMap:{textStyle:{color:Wm}},timeline:{lineStyle:{color:Wm},itemStyle:{normal:{color:Zm[1]}},label:{normal:{textStyle:{color:Wm}}},controlStyle:{normal:{color:Wm,borderColor:Wm}}},timeAxis:Hm(),logAxis:Hm(),valueAxis:Hm(),categoryAxis:Hm(),line:{symbol:"circle"},graph:{color:Zm},gauge:{title:{textStyle:{color:Wm}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};Xm.categoryAxis.splitLine.show=!1,zg.extend({type:"dataset",defaultOption:{seriesLayoutBy:Yg,sourceHeader:null,dimensions:null,source:null},optionUpdated:function(){!function(t){var e=t.option.source,n=Zg;if(M(e))n=Xg;else if(x(e)){0===e.length&&(n=Gg);for(var i=0,r=e.length;r>i;i++){var o=e[i];if(null!=o){if(x(o)){n=Gg;break}if(b(o)){n=Wg;break}}}}else if(b(e)){for(var a in e)if(e.hasOwnProperty(a)&&d(e[a])){n=Hg;break}}else if(null!=e)throw new Error("Invalid data");jg(t).sourceFormat=n}(this)}}),_m.extend({type:"dataset"});var Ym=Xn.extend({type:"ellipse",shape:{cx:0,cy:0,rx:0,ry:0},buildPath:function(t,e){var n=.5522848,i=e.cx,r=e.cy,o=e.rx,a=e.ry,s=o*n,l=a*n;t.moveTo(i-o,r),t.bezierCurveTo(i-o,r-l,i-s,r-a,i,r-a),t.bezierCurveTo(i+s,r-a,i+o,r-l,i+o,r),t.bezierCurveTo(i+o,r+l,i+s,r+a,i,r+a),t.bezierCurveTo(i-s,r+a,i-o,r+l,i-o,r),t.closePath()}}),Um=/[\s,]+/;Po.prototype.parse=function(t,e){e=e||{};var n=ko(t);if(!n)throw new Error("Illegal svg");var i=new yd;this._root=i;var r=n.getAttribute("viewBox")||"",o=parseFloat(n.getAttribute("width")||e.width),a=parseFloat(n.getAttribute("height")||e.height);isNaN(o)&&(o=null),isNaN(a)&&(a=null),zo(n,i,null,!0);for(var s=n.firstChild;s;)this._parseNode(s,i),s=s.nextSibling;var l,u;if(r){var h=L(r).split(Um);h.length>=4&&(l={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(l&&null!=o&&null!=a&&(u=function(t,e,n){var i=e/t.width,r=n/t.height,o=Math.min(i,r);return{scale:[o,o],position:[-(t.x+t.width/2)*o+e/2,-(t.y+t.height/2)*o+n/2]}}(l,o,a),!e.ignoreViewBox)){var c=i;(i=new yd).add(c),c.scale=u.scale.slice(),c.position=u.position.slice()}return e.ignoreRootClip||null==o||null==a||i.setClipPath(new Vp({shape:{x:0,y:0,width:o,height:a}})),{root:i,width:o,height:a,viewBoxRect:l,viewBoxTransform:u}},Po.prototype._parseNode=function(t,e){var n=t.nodeName.toLowerCase();"defs"===n?this._isDefine=!0:"text"===n&&(this._isText=!0);var i;if(this._isDefine){if(a=qm[n]){var r=a.call(this,t),o=t.getAttribute("id");o&&(this._defs[o]=r)}}else{var a=jm[n];a&&(i=a.call(this,t,e),e.add(i))}for(var s=t.firstChild;s;)1===s.nodeType&&this._parseNode(s,i),3===s.nodeType&&this._isText&&this._parseText(s,i),s=s.nextSibling;"defs"===n?this._isDefine=!1:"text"===n&&(this._isText=!1)},Po.prototype._parseText=function(t,e){if(1===t.nodeType){var n=t.getAttribute("dx")||0,i=t.getAttribute("dy")||0;this._textX+=parseFloat(n),this._textY+=parseFloat(i)}var r=new Ap({style:{text:t.textContent,transformText:!0},position:[this._textX||0,this._textY||0]});Oo(e,r),zo(t,r,this._defs);var o=r.style.fontSize;o&&9>o&&(r.style.fontSize=9,r.scale=r.scale||[1,1],r.scale[0]*=o/9,r.scale[1]*=o/9);var a=r.getBoundingRect();return this._textX+=a.width,e.add(r),r};var jm={g:function(t,e){var n=new yd;return Oo(e,n),zo(t,n,this._defs),n},rect:function(t,e){var n=new Vp;return Oo(e,n),zo(t,n,this._defs),n.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),n},circle:function(t,e){var n=new Dp;return Oo(e,n),zo(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),n},line:function(t,e){var n=new Wp;return Oo(e,n),zo(t,n,this._defs),n.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),n},ellipse:function(t,e){var n=new Ym;return Oo(e,n),zo(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),n},polygon:function(t,e){var n=t.getAttribute("points");n&&(n=Lo(n));var i=new Ep({shape:{points:n||[]}});return Oo(e,i),zo(t,i,this._defs),i},polyline:function(t,e){var n=new Xn;Oo(e,n),zo(t,n,this._defs);var i=t.getAttribute("points");i&&(i=Lo(i));return new Bp({shape:{points:i||[]}})},image:function(t,e){var n=new He;return Oo(e,n),zo(t,n,this._defs),n.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),n},text:function(t,e){var n=t.getAttribute("x")||0,i=t.getAttribute("y")||0,r=t.getAttribute("dx")||0,o=t.getAttribute("dy")||0;this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(o);var a=new yd;return Oo(e,a),zo(t,a,this._defs),a},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||0,o=t.getAttribute("dy")||0,a=new yd;return Oo(e,a),zo(t,a,this._defs),this._textX+=r,this._textY+=o,a},path:function(t,e){var n=jn(t.getAttribute("d")||"");return Oo(e,n),zo(t,n,this._defs),n}},qm={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),n=parseInt(t.getAttribute("y1")||0,10),i=parseInt(t.getAttribute("x2")||10,10),r=parseInt(t.getAttribute("y2")||0,10),o=new jp(e,n,i,r);return function(t,e){for(var n=t.firstChild;n;){if(1===n.nodeType){var i=n.getAttribute("offset");i=i.indexOf("%")>0?parseInt(i,10)/100:i?parseFloat(i):0;var r=n.getAttribute("stop-color")||"#000000";e.addColorStop(i,r)}n=n.nextSibling}}(t,o),o},radialgradient:function(){}},$m={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"},Km=/url\(\s*#(.*?)\)/,Qm=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g,Jm=/([^\s:;]+)\s*:\s*([^:;]+)/g,tv=B(),ev={registerMap:function(t,e,n){var i;return x(e)?i=e:e.svg?i=[{type:"svg",source:e.svg,specialAreas:e.specialAreas}]:(e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),i=[{type:"geoJSON",source:e,specialAreas:n}]),f(i,function(t){var e=t.type;"geoJson"===e&&(e=t.type="geoJSON");(0,nv[e])(t)}),tv.set(t,i)},retrieveMap:function(t){return tv.get(t)}},nv={geoJSON:function(t){var e=t.source;t.geoJSON=w(e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e},svg:function(t){t.svgXML=ko(t.source)}},iv=O,rv=f,ov=_,av=b,sv=zg.parseClassType,lv=1e3,uv=1e3,hv=3e3,cv={PROCESSOR:{FILTER:lv,SERIES_FILTER:800,STATISTIC:5e3},VISUAL:{LAYOUT:uv,PROGRESSIVE_LAYOUT:1100,GLOBAL:2e3,CHART:hv,POST_CHART_LAYOUT:3500,COMPONENT:4e3,BRUSH:5e3}},dv="__flagInMainProcess",fv="__optionUpdated",pv=/^[a-zA-Z0-9_]+$/;Bo.prototype.on=Eo("on",!0),Bo.prototype.off=Eo("off",!0),Bo.prototype.one=Eo("one",!0),c(Bo,Ac);var gv=Ro.prototype;gv._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[fv]){var e=this[fv].silent;this[dv]=!0,Vo(this),mv.update.call(this),this[dv]=!1,this[fv]=!1,Zo.call(this,e),Xo.call(this,e)}else if(t.unfinished){var n=1,i=this._model;this._api;t.unfinished=!1;do{var r=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),Wo(this,i),t.performVisualTasks(i),qo(this,this._model,0,"remain"),n-=+new Date-r}while(n>0&&t.unfinished);t.unfinished||this._zr.flush()}}},gv.getDom=function(){return this._dom},gv.getZr=function(){return this._zr},gv.setOption=function(t,e,n){if(!this._disposed){var i;if(av(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[dv]=!0,!this._model||e){var r=new zr(this._api),o=this._theme,a=this._model=new $g;a.scheduler=this._scheduler,a.init(null,null,o,r)}this._model.setOption(t,wv),n?(this[fv]={silent:i},this[dv]=!1):(Vo(this),mv.update.call(this),this._zr.flush(),this[fv]=!1,this[dv]=!1,Zo.call(this,i),Xo.call(this,i))}},gv.setTheme=function(){console.error("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},gv.getModel=function(){return this._model},gv.getOption=function(){return this._model&&this._model.getOption()},gv.getWidth=function(){return this._zr.getWidth()},gv.getHeight=function(){return this._zr.getHeight()},gv.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},gv.getRenderedCanvas=function(t){if(ac.canvasSupported){(t=t||{}).pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor");return this._zr.painter.getRenderedCanvas(t)}},gv.getSvgDataUrl=function(){if(ac.svgSupported){var t=this._zr;return f(t.storage.getDisplayList(),function(t){t.stopAnimation(!0)}),t.painter.pathToDataUrl()}},gv.getDataURL=function(t){if(!this._disposed){var e=(t=t||{}).excludeComponents,n=this._model,i=[],r=this;rv(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 o="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return rv(i,function(t){t.group.ignore=!1}),o}},gv.getConnectedDataURL=function(t){if(!this._disposed&&ac.canvasSupported){var e=this.group,n=Math.min,r=Math.max,o=1/0;if(Tv[e]){var a=o,s=o,l=-o,u=-o,h=[],c=t&&t.pixelRatio||1;f(Cv,function(o){if(o.group===e){var c=o.getRenderedCanvas(i(t)),d=o.getDom().getBoundingClientRect();a=n(d.left,a),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})}});var d=(l*=c)-(a*=c),p=(u*=c)-(s*=c),g=vc();g.width=d,g.height=p;var m=qe(g);return t.connectedBackgroundColor&&m.add(new Vp({shape:{x:0,y:0,width:d,height:p},style:{fill:t.connectedBackgroundColor}})),rv(h,function(t){var e=new He({style:{x:t.left*c-a,y:t.top*c-s,image:t.dom}});m.add(e)}),m.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},gv.convertToPixel=y(Fo,"convertToPixel"),gv.convertFromPixel=y(Fo,"convertFromPixel"),gv.containPixel=function(t,e){if(!this._disposed){var n;return t=an(this._model,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 o=this._chartsMap[t.__viewId];o&&o.containPoint&&(n|=o.containPoint(e,t))}},this)},this),!!n}},gv.getVisual=function(t,e){var n=(t=an(this._model,t,{defaultMainType:"series"})).seriesModel.getData(),i=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?n.indexOfRawIndex(t.dataIndex):null;return null!=i?n.getItemVisual(i,e):n.getVisual(e)},gv.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},gv.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var mv={prepareAndUpdate:function(t){Vo(this),mv.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,o=this._scheduler;if(e){o.restoreData(e,t),o.performSeriesTasks(e),r.create(e,n),o.performDataProcessorTasks(e,t),Wo(this,e),r.update(e,n),Uo(e),o.performVisualTasks(e,t),jo(this,e,n,t);var a=e.get("backgroundColor")||"transparent";if(ac.canvasSupported)i.setBackgroundColor(a);else{var s=Lt(a);a=Vt(s,"rgb"),0===s[3]&&(a="transparent")}$o(e,n)}},updateTransform:function(t){var e=this._model,n=this,i=this._api;if(e){var r=[];e.eachComponent(function(o,a){var s=n.getViewOfComponentModel(a);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(a,e,i,t);l&&l.update&&r.push(s)}else r.push(s)});var o=B();e.eachSeries(function(r){var a=n._chartsMap[r.__viewId];if(a.updateTransform){var s=a.updateTransform(r,e,i,t);s&&s.update&&o.set(r.uid,1)}else o.set(r.uid,1)}),Uo(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0,dirtyMap:o}),qo(n,e,0,t,o),$o(e,this._api)}},updateView:function(t){var e=this._model;e&&(ho.markUpdateMethod(t,"updateView"),Uo(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),jo(this,this._model,this._api,t),$o(e,this._api))},updateVisual:function(t){mv.update.call(this,t)},updateLayout:function(t){mv.update.call(this,t)}};gv.resize=function(t){if(!this._disposed){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[dv]=!0,n&&Vo(this),mv.update.call(this),this[dv]=!1,Zo.call(this,i),Xo.call(this,i)}}},gv.showLoading=function(t,e){if(!this._disposed&&(av(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),Iv[t])){var n=Iv[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},gv.hideLoading=function(){this._disposed||(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},gv.makeActionFromEvent=function(t){var e=a({},t);return e.type=xv[t.type],e},gv.dispatchAction=function(t,e){if(!this._disposed&&(av(e)||(e={silent:!!e}),yv[t.type]&&this._model)){if(this[dv])return void this._pendingActions.push(t);Ho.call(this,t,e.silent),e.flush?this._zr.flush(!0):!1!==e.flush&&ac.browser.weChat&&this._throttledZrFlush(),Zo.call(this,e.silent),Xo.call(this,e.silent)}},gv.appendData=function(t){if(!this._disposed){var e=t.seriesIndex;this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0}},gv.on=Eo("on",!1),gv.off=Eo("off",!1),gv.one=Eo("one",!1);var vv=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];gv._initEvents=function(){rv(vv,function(t){var e=function(e){var n,i=this.getModel(),r=e.target;if("globalout"===t)n={};else if(r&&null!=r.dataIndex){var o=r.dataModel||i.getSeriesByIndex(r.seriesIndex);n=o&&o.getDataParams(r.dataIndex,r.dataType,r)||{}}else r&&r.eventData&&(n=a({},r.eventData));if(n){var s=n.componentType,l=n.componentIndex;("markLine"===s||"markPoint"===s||"markArea"===s)&&(s="series",l=n.seriesIndex);var u=s&&null!=l&&i.getComponent(s,l),h=u&&this["series"===u.mainType?"_chartsMap":"_componentsMap"][u.__viewId];n.event=e,n.type=t,this._ecEventProcessor.eventInfo={targetEl:r,packedEvent:n,model:u,view:h},this.trigger(t,n)}};e.zrEventfulCallAtLast=!0,this._zr.on(t,e,this)},this),rv(xv,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},gv.isDisposed=function(){return this._disposed},gv.clear=function(){this._disposed||this.setOption({series:[]},!0)},gv.dispose=function(){if(!this._disposed){this._disposed=!0,ln(this.getDom(),kv,"");var t=this._api,e=this._model;rv(this._componentsViews,function(n){n.dispose(e,t)}),rv(this._chartsViews,function(n){n.dispose(e,t)}),this._zr.dispose(),delete Cv[this.id]}},c(Ro,Ac),Jo.prototype={constructor:Jo,normalizeQuery:function(t){var e={},n={},i={};if(w(t)){var r=sv(t);e.mainType=r.main||null,e.subType=r.sub||null}else{var o=["Index","Name","Id"],a={name:1,dataIndex:1,dataType:1};f(t,function(t,r){for(var s=!1,l=0;l<o.length;l++){var u=o[l],h=r.lastIndexOf(u);if(h>0&&h===r.length-u.length){var c=r.slice(0,h);"data"!==c&&(e.mainType=c,e[u.toLowerCase()]=t,s=!0)}}a.hasOwnProperty(r)&&(n[r]=t,s=!0),s||(i[r]=t)})}return{cptQuery:e,dataQuery:n,otherQuery:i}},filter:function(t,e){function n(t,e,n,i){return null==t[n]||e[i||n]===t[n]}var i=this.eventInfo;if(!i)return!0;var r=i.targetEl,o=i.packedEvent,a=i.model,s=i.view;if(!a||!s)return!0;var l=e.cptQuery,u=e.dataQuery;return n(l,a,"mainType")&&n(l,a,"subType")&&n(l,a,"index","componentIndex")&&n(l,a,"name")&&n(l,a,"id")&&n(u,o,"name")&&n(u,o,"dataIndex")&&n(u,o,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,r,o))},afterTrigger:function(){this.eventInfo=null}};var yv={},xv={},_v=[],wv=[],bv=[],Sv=[],Mv={},Iv={},Cv={},Tv={},Av=new Date-0,Dv=new Date-0,kv="_echarts_instance_",Pv=ta;sa(2e3,km),ia(um),ra(900,function(t){var e=B();t.eachSeries(function(t){var n=t.get("stack");if(n){var i=e.get(n)||e.set(n,[]),r=t.getData(),o={stackResultDimension:r.getCalculationInfo("stackResultDimension"),stackedOverDimension:r.getCalculationInfo("stackedOverDimension"),stackedDimension:r.getCalculationInfo("stackedDimension"),stackedByDimension:r.getCalculationInfo("stackedByDimension"),isStackedByIndex:r.getCalculationInfo("isStackedByIndex"),data:r,seriesModel:t};if(!o.stackedDimension||!o.isStackedByIndex&&!o.stackedByDimension)return;i.length&&r.setCalculationInfo("stackedOnSeries",i[i.length-1].seriesModel),i.push(o)}}),e.each(Xr)}),ua("default",function(t,e){s(e=e||{},{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var n=new Vp({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4}),i=new Xp({shape:{startAngle:-Lm/2,endAngle:-Lm/2+.1,r:10},style:{stroke:e.color,lineCap:"round",lineWidth:5},zlevel:e.zlevel,z:10001}),r=new Vp({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*Lm/2}).start("circularInOut"),i.animateShape(!0).when(1e3,{startAngle:3*Lm/2}).delay(300).start("circularInOut");var o=new yd;return o.add(i),o.add(r),o.add(n),o.resize=function(){var e=t.getWidth()/2,o=t.getHeight()/2;i.setShape({cx:e,cy:o});var a=i.shape.r;r.setShape({x:e-a,y:o-a,width:2*a,height:2*a}),n.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},o.resize(),o}),oa({type:"highlight",event:"highlight",update:"highlight"},R),oa({type:"downplay",event:"downplay",update:"downplay"},R),na("light",Gm),na("dark",Xm);ga.prototype={constructor:ga,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=this._old,e=this._new,n={},i=[],r=[];for(ma(t,{},i,"_oldKeyGetter",this),ma(e,n,r,"_newKeyGetter",this),o=0;o<t.length;o++){if(null!=(s=n[a=i[o]])){(u=s.length)?(1===u&&(n[a]=null),s=s.shift()):n[a]=null,this._update&&this._update(s,o)}else this._remove&&this._remove(o)}for(var o=0;o<r.length;o++){var a=r[o];if(n.hasOwnProperty(a)){var s=n[a];if(null==s)continue;if(s.length)for(var l=0,u=s.length;u>l;l++)this._add&&this._add(s[l]);else this._add&&this._add(s)}}}};var Ov=B(["tooltip","label","itemName","itemId","seriesName"]),Lv=b,zv="undefined",Nv=-1,Ev="e\0\0",Bv={"float":typeof Float64Array===zv?Array:Float64Array,"int":typeof Int32Array===zv?Array:Int32Array,ordinal:Array,number:Array,time:Array},Rv=typeof Uint32Array===zv?Array:Uint32Array,Fv=typeof Int32Array===zv?Array:Int32Array,Vv=typeof Uint16Array===zv?Array:Uint16Array,Gv=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_rawData","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],Wv=["_extent","_approximateExtent","_rawExtent"],Hv=function(t,e){t=t||["x","y"];for(var n={},i=[],r={},o=0;o<t.length;o++){var a=t[o];w(a)&&(a={name:a});var s=a.name;a.type=a.type||"float",a.coordDim||(a.coordDim=s,a.coordDimIndex=0),a.otherDims=a.otherDims||{},i.push(s),n[s]=a,a.index=o,a.createInvertedIndices&&(r[s]=[])}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._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=function(t){var e={},n=e.encode={},i=B(),r=[],o=[],a=e.userOutput={dimensionNames:t.dimensions.slice(),encode:{}};f(t.dimensions,function(e){var s=t.getDimensionInfo(e),l=s.coordDim;if(l){var u=s.coordDimIndex;va(n,l)[u]=e,s.isExtraCoord||(i.set(l,1),function(t){return!("ordinal"===t||"time"===t)}(s.type)&&(r[0]=e),va(a.encode,l)[u]=s.index),s.defaultTooltip&&o.push(e)}Ov.each(function(t,e){var i=va(n,e),r=s.otherDims[e];null!=r&&!1!==r&&(i[r]=s.name)})});var s=[],l={};i.each(function(t,e){var i=n[e];l[e]=i[0],s=s.concat(i)}),e.dataDimsOnCoord=s,e.encodeFirstDimNotExtra=l;var u=n.label;u&&u.length&&(r=u.slice());var h=n.tooltip;return h&&h.length?o=h.slice():o.length||(o=r.slice()),n.defaultedLabel=r,n.defaultedTooltip=o,e}(this),this._invertedIndicesMap=r,this._calculationInfo={},this.userOutput=this._dimensionsSummary.userOutput},Zv=Hv.prototype;Zv.type="list",Zv.hasItemOption=!0,Zv.getDimension=function(t){return("number"==typeof t||!isNaN(t)&&!this._dimensionInfos.hasOwnProperty(t))&&(t=this.dimensions[t]),t},Zv.getDimensionInfo=function(t){return this._dimensionInfos[this.getDimension(t)]},Zv.getDimensionsOnCoord=function(){return this._dimensionsSummary.dataDimsOnCoord.slice()},Zv.mapDimension=function(t,e){var n=this._dimensionsSummary;if(null==e)return n.encodeFirstDimNotExtra[t];var i=n.encode[t];return!0===e?(i||[]).slice():i&&i[e]},Zv.initData=function(t,e,n){(Sr.isInstance(t)||d(t))&&(t=new Yr(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=fm[this._rawData.getSource().sourceFormat],this._dimValueGetter=n=n||this.defaultDimValueGetter,this._dimValueGetterArrayRows=fm.arrayRows,this._rawExtent={},this._initDataFromProvider(0,t.count()),t.pure&&(this.hasItemOption=!1)},Zv.getProvider=function(){return this._rawData},Zv.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)},Zv.appendValues=function(t,e){for(var n=this._chunkSize,i=this._storage,r=this.dimensions,o=r.length,a=this._rawExtent,s=this.count(),l=s+Math.max(t.length,e?e.length:0),u=this._chunkCount,h=0;o>h;h++){a[v=r[h]]||(a[v]=[1/0,-1/0]),i[v]||(i[v]=[]),wa(i,this._dimensionInfos[v],n,u,l),this._chunkCount=i[v].length}for(var c=new Array(o),d=s;l>d;d++){for(var f=d-s,p=Math.floor(d/n),g=d%n,m=0;o>m;m++){var v=r[m],y=this._dimValueGetterArrayRows(t[f]||c,v,f,m);i[v][p][g]=y;var x=a[v];y<x[0]&&(x[0]=y),y>x[1]&&(x[1]=y)}e&&(this._nameList[d]=e[f])}this._rawCount=this._count=l,this._extent={},ba(this)},Zv._initDataFromProvider=function(t,e){if(!(t>=e)){for(var n,i=this._chunkSize,r=this._rawData,o=this._storage,a=this.dimensions,s=a.length,l=this._dimensionInfos,u=this._nameList,h=this._idList,c=this._rawExtent,d=this._nameRepeatCount={},f=this._chunkCount,p=0;s>p;p++){c[w=a[p]]||(c[w]=[1/0,-1/0]);var g=l[w];0===g.otherDims.itemName&&(n=this._nameDimIdx=p),0===g.otherDims.itemId&&(this._idDimIdx=p),o[w]||(o[w]=[]),wa(o,g,i,f,e),this._chunkCount=o[w].length}for(var m=new Array(s),v=t;e>v;v++){m=r.getItem(v,m);for(var y=Math.floor(v/i),x=v%i,_=0;s>_;_++){var w=a[_],b=o[w][y],S=this._dimValueGetter(m,w,v,_);b[x]=S;var M=c[w];S<M[0]&&(M[0]=S),S>M[1]&&(M[1]=S)}if(!r.pure){var I=u[v];if(m&&null==I)if(null!=m.name)u[v]=I=m.name;else if(null!=n){var C=a[n],T=o[C][y];if(T){I=T[x];var A=l[C].ordinalMeta;A&&A.categories.length&&(I=A.categories[I])}}var D=null==m?null:m.id;null==D&&null!=I&&(d[I]=d[I]||0,D=I,d[I]>0&&(D+="__ec__"+d[I]),d[I]++),null!=D&&(h[v]=D)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={},ba(this)}},Zv.count=function(){return this._count},Zv.getIndices=function(){var t=this._indices;if(t){var e=t.constructor,n=this._count;if(e===Array){i=new e(n);for(r=0;n>r;r++)i[r]=t[r]}else i=new e(t.buffer,0,n)}else for(var e=ya(this),i=new e(this.count()),r=0;r<i.length;r++)i[r]=r;return i},Zv.get=function(t,e){if(!(e>=0&&e<this._count))return NaN;var n=this._storage;if(!n[t])return NaN;e=this.getRawIndex(e);var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[t][i][r]},Zv.getByRawIndex=function(t,e){if(!(e>=0&&e<this._rawCount))return NaN;var n=this._storage[t];if(!n)return NaN;var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[i][r]},Zv._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%this._chunkSize;return this._storage[t][n][i]},Zv.getValues=function(t,e){var n=[];x(t)||(e=t,t=this.dimensions);for(var i=0,r=t.length;r>i;i++)n.push(this.get(t[i],e));return n},Zv.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=0,i=e.length;i>n;n++)if(isNaN(this.get(e[n],t)))return!1;return!0},Zv.getDataExtent=function(t){t=this.getDimension(t);var e=[1/0,-1/0];if(!this._storage[t])return e;var n,i=this.count();if(!this._indices)return this._rawExtent[t].slice();if(n=this._extent[t])return n.slice();for(var r=(n=e)[0],o=n[1],a=0;i>a;a++){var s=this._getFast(t,this.getRawIndex(a));r>s&&(r=s),s>o&&(o=s)}return n=[r,o],this._extent[t]=n,n},Zv.getApproximateExtent=function(t){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t)},Zv.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},Zv.getCalculationInfo=function(t){return this._calculationInfo[t]},Zv.setCalculationInfo=function(t,e){Lv(t)?a(this._calculationInfo,t):this._calculationInfo[t]=e},Zv.getSum=function(t){var e=0;if(this._storage[t])for(var n=0,i=this.count();i>n;n++){var r=this.get(t,n);isNaN(r)||(e+=r)}return e},Zv.getMedian=function(t){var e=[];this.each(t,function(t){isNaN(t)||e.push(t)});var n=[].concat(e).sort(function(t,e){return t-e}),i=this.count();return 0===i?0:i%2==1?n[(i-1)/2]:(n[i/2]+n[i/2-1])/2},Zv.rawIndexOf=function(t,e){var n=(t&&this._invertedIndicesMap[t])[e];return null==n||isNaN(n)?Nv:n},Zv.indexOfName=function(t){for(var e=0,n=this.count();n>e;e++)if(this.getName(e)===t)return e;return-1},Zv.indexOfRawIndex=function(t){if(t>=this._rawCount||0>t)return-1;if(!this._indices)return t;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 o=(i+r)/2|0;if(e[o]<t)i=o+1;else{if(!(e[o]>t))return o;r=o-1}}return-1},Zv.indicesOfNearest=function(t,e,n){var i=[];if(!this._storage[t])return i;null==n&&(n=1/0);for(var r=Number.MAX_VALUE,o=-1,a=0,s=this.count();s>a;a++){var l=e-this.get(t,a),u=Math.abs(l);n>=l&&r>=u&&((r>u||l>=0&&0>o)&&(r=u,o=l,i.length=0),i.push(a))}return i},Zv.getRawIndex=Ma,Zv.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},Zv.getName=function(t){var e=this.getRawIndex(t);return this._nameList[e]||Sa(this,this._nameDimIdx,e)||""},Zv.getId=function(t){return Ca(this,this.getRawIndex(t))},Zv.each=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;for(var r=(t=p(Ta(t),this.getDimension,this)).length,o=0;o<this.count();o++)switch(r){case 0:e.call(n,o);break;case 1:e.call(n,this.get(t[0],o),o);break;case 2:e.call(n,this.get(t[0],o),this.get(t[1],o),o);break;default:for(var a=0,s=[];r>a;a++)s[a]=this.get(t[a],o);s[a]=o,e.apply(n,s)}}},Zv.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this,t=p(Ta(t),this.getDimension,this);for(var r=this.count(),o=new(ya(this))(r),a=[],s=t.length,l=0,u=t[0],h=0;r>h;h++){var c,d=this.getRawIndex(h);if(0===s)c=e.call(n,h);else if(1===s){var f=this._getFast(u,d);c=e.call(n,f,h)}else{for(var g=0;s>g;g++)a[g]=this._getFast(u,d);a[g]=h,c=e.apply(n,a)}c&&(o[l++]=d)}return r>l&&(this._indices=o),this._count=l,this._extent={},this.getRawIndex=this._indices?Ia:Ma,this}},Zv.selectRange=function(t){if(this._count){var e=[];for(var n in t)t.hasOwnProperty(n)&&e.push(n);var i=e.length;if(i){var r=this.count(),o=new(ya(this))(r),a=0,s=e[0],l=t[s][0],u=t[s][1],h=!1;if(!this._indices){var c=0;if(1===i){for(var d=this._storage[e[0]],f=0;f<this._chunkCount;f++)for(var p=d[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;g>m;m++){((w=p[m])>=l&&u>=w||isNaN(w))&&(o[a++]=c),c++}h=!0}else if(2===i){for(var d=this._storage[s],v=this._storage[e[1]],y=t[e[1]][0],x=t[e[1]][1],f=0;f<this._chunkCount;f++)for(var p=d[f],_=v[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;g>m;m++){var w=p[m],b=_[m];(w>=l&&u>=w||isNaN(w))&&(b>=y&&x>=b||isNaN(b))&&(o[a++]=c),c++}h=!0}}if(!h)if(1===i)for(m=0;r>m;m++){M=this.getRawIndex(m);((w=this._getFast(s,M))>=l&&u>=w||isNaN(w))&&(o[a++]=M)}else for(m=0;r>m;m++){for(var S=!0,M=this.getRawIndex(m),f=0;i>f;f++){var I=e[f];((w=this._getFast(n,M))<t[I][0]||w>t[I][1])&&(S=!1)}S&&(o[a++]=this.getRawIndex(m))}return r>a&&(this._indices=o),this._count=a,this._extent={},this.getRawIndex=this._indices?Ia:Ma,this}}},Zv.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n),r},Zv.map=function(t,e,n,i){n=n||i||this;var r=Aa(this,t=p(Ta(t),this.getDimension,this));r._indices=this._indices,r.getRawIndex=r._indices?Ia:Ma;for(var o=r._storage,a=[],s=this._chunkSize,l=t.length,u=this.count(),h=[],c=r._rawExtent,d=0;u>d;d++){for(var f=0;l>f;f++)h[f]=this.get(t[f],d);h[l]=d;var g=e&&e.apply(n,h);if(null!=g){"object"!=typeof g&&(a[0]=g,g=a);for(var m=this.getRawIndex(d),v=Math.floor(m/s),y=m%s,x=0;x<g.length;x++){var _=t[x],w=g[x],b=c[_],S=o[_];S&&(S[v][y]=w),w<b[0]&&(b[0]=w),w>b[1]&&(b[1]=w)}}}return r},Zv.downSample=function(t,e,n,i){for(var r=Aa(this,[t]),o=r._storage,a=[],s=Math.floor(1/e),l=o[t],u=this.count(),h=this._chunkSize,c=r._rawExtent[t],d=new(ya(this))(u),f=0,p=0;u>p;p+=s){s>u-p&&(s=u-p,a.length=s);for(var g=0;s>g;g++){var m=this.getRawIndex(p+g),v=Math.floor(m/h),y=m%h;a[g]=l[v][y]}var x=n(a),_=this.getRawIndex(Math.min(p+i(a,x)||0,u-1)),w=_%h;l[Math.floor(_/h)][w]=x,x<c[0]&&(c[0]=x),x>c[1]&&(c[1]=x),d[f++]=_}return r._count=f,r._indices=d,r.getRawIndex=Ia,r},Zv.getItemModel=function(t){var e=this.hostModel;return new Hi(this.getRawDataItem(t),e,e&&e.ecModel)},Zv.diff=function(t){var e=this;return new ga(t?t.getIndices():[],this.getIndices(),function(e){return Ca(t,e)},function(t){return Ca(e,t)})},Zv.getVisual=function(t){var e=this._visual;return e&&e[t]},Zv.setVisual=function(t,e){if(Lv(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},Zv.setLayout=function(t,e){if(Lv(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},Zv.getLayout=function(t){return this._layout[t]},Zv.getItemLayout=function(t){return this._itemLayouts[t]},Zv.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?a(this._itemLayouts[t]||{},e):e},Zv.clearItemLayouts=function(){this._itemLayouts.length=0},Zv.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},Zv.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,Lv(e))for(var o in e)e.hasOwnProperty(o)&&(i[o]=e[o],r[o]=!0);else i[e]=n,r[e]=!0},Zv.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};var Xv=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType};Zv.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(Xv,e)),this._graphicEls[t]=e},Zv.getItemGraphicEl=function(t){return this._graphicEls[t]},Zv.eachItemGraphicEl=function(t,e){f(this._graphicEls,function(n,i){n&&t&&t.call(e,n,i)})},Zv.cloneShallow=function(t){if(!t){var e=p(this.dimensions,this.getDimensionInfo,this);t=new Hv(e,this.hostModel)}if(t._storage=this._storage,_a(t,this),this._indices){var n=this._indices.constructor;t._indices=new n(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?Ia:Ma,t},Zv.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(k(arguments)))})},Zv.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],Zv.CHANGABLE_METHODS=["filterSelf","selectRange"];var Yv=function(t,e){return e=e||{},Da(e.coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,generateCoord:e.generateCoord,generateCoordCount:e.generateCoordCount})};Na.prototype.parse=function(t){return t},Na.prototype.getSetting=function(t){return this._setting[t]},Na.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},Na.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},Na.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},Na.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},Na.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},Na.prototype.getExtent=function(){return this._extent.slice()},Na.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},Na.prototype.isBlank=function(){return this._isBlank},Na.prototype.setBlank=function(t){this._isBlank=t},Na.prototype.getLabel=null,cn(Na),gn(Na,{registerWhenExtend:!0}),Ea.createByAxisModel=function(t){var e=t.option,n=e.data,i=n&&p(n,Ra);return new Ea({categories:i,needCollect:!i,deduplication:!1!==e.dedplication})};var Uv=Ea.prototype;Uv.getOrdinal=function(t){return Ba(this).get(t)},Uv.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=Ba(this);return null==(e=i.get(t))&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=NaN),e};var jv=Na.prototype,qv=Na.extend({type:"ordinal",init:function(t,e){(!t||x(t))&&(t=new Ea({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),jv.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return jv.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(jv.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.isBlank()?void 0:this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},getOrdinalMeta:function(){return this._ordinalMeta},niceTicks:R,niceExtent:R});qv.create=function(){return new qv};var $v=qi,Kv=qi,Qv=Na.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]),Qv.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=Fa(t)},getTicks:function(){return function(t,e,n,i){var r=[];if(!t)return r;e[0]<n[0]&&r.push(e[0]);for(var o=n[0];o<=n[1]&&(r.push(o),(o=$v(o+t,i))!==r[r.length-1]);)if(r.length>1e4)return[];return e[1]>(r.length?r[r.length-1]:n[1])&&r.push(e[1]),r}(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getLabel:function(t,e){if(null==t)return"";var n=e&&e.precision;return null==n?n=Qi(t)||0:"auto"===n&&(n=this._intervalPrecision),t=Kv(t,n,!0),sr(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 o=function(t,e,n,i){var r={},o=t[1]-t[0],a=r.interval=ar(o/e,!0);null!=n&&n>a&&(a=r.interval=n),null!=i&&a>i&&(a=r.interval=i);var s=r.intervalPrecision=Fa(a);return Ga(r.niceTickExtent=[$v(Math.ceil(t[0]/a)*a,s),$v(Math.floor(t[1]/a)*a,s)],t),r}(i,t,e,n);this._intervalPrecision=o.intervalPrecision,this._interval=o.interval,this._niceExtent=o.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]=Kv(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=Kv(Math.ceil(e[1]/r)*r))}});Qv.create=function(){return new Qv};var Jv="__ec_stack_",ty="undefined"!=typeof Float32Array?Float32Array:Array,ey={seriesType:"bar",plan:bm(),reset:function(t){if(Ua(t)&&ja(t)){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=n.getOtherAxis(i),o=e.mapDimension(r.dim),a=e.mapDimension(i.dim),s=r.isHorizontal(),l=s?0:1,u=Ya(Xa([t]),i,t).width;return u>.5||(u=.5),{progress:function(t,e){for(var i,h=t.count,c=new ty(2*h),d=new ty(h),f=[],p=[],g=0,m=0;null!=(i=t.next());)p[l]=e.get(o,i),p[1-l]=e.get(a,i),f=n.dataToPoint(p,null,f),c[g++]=f[0],c[g++]=f[1],d[m++]=i;e.setLayout({largePoints:c,largeDataIndices:d,barWidth:u,valueAxisStart:qa(0,r),valueAxisHorizontal:s})}}}}},ny=Qv.prototype,iy=Math.ceil,ry=Math.floor,oy=36e5,ay=864e5,sy=Qv.extend({type:"time",getLabel:function(t){var e=this._stepLvl,n=new Date(t);return fr(e[0],n,this.getSetting("useUTC"))},niceExtent:function(t){var e=this._extent;if(e[0]===e[1]&&(e[0]-=ay,e[1]+=ay),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]-ay}this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var i=this._interval;t.fixMin||(e[0]=qi(ry(e[0]/i)*i)),t.fixMax||(e[1]=qi(iy(e[1]/i)*i))},niceTicks:function(t,e,n){t=t||10;var i=this._extent,r=i[1]-i[0],o=r/t;null!=e&&e>o&&(o=e),null!=n&&o>n&&(o=n);var a=ly.length,s=function(t,e,n,i){for(;i>n;){var r=n+i>>>1;t[r][1]<e?n=r+1:i=r}return n}(ly,o,0,a),l=ly[Math.min(s,a-1)],u=l[1];if("year"===l[0]){u*=ar(r/u/t,!0)}var h=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,c=[Math.round(iy((i[0]-h)/u)*u+h),Math.round(ry((i[1]-h)/u)*u+h)];Ga(c,i),this._stepLvl=l,this._interval=u,this._niceExtent=c},parse:function(t){return+ir(t)}});f(["contain","normalize"],function(t){sy.prototype[t]=function(e){return ny[t].call(this,this.parse(e))}});var ly=[["hh:mm:ss",1e3],["hh:mm:ss",5e3],["hh:mm:ss",1e4],["hh:mm:ss",15e3],["hh:mm:ss",3e4],["hh:mm\nMM-dd",6e4],["hh:mm\nMM-dd",3e5],["hh:mm\nMM-dd",6e5],["hh:mm\nMM-dd",9e5],["hh:mm\nMM-dd",18e5],["hh:mm\nMM-dd",oy],["hh:mm\nMM-dd",72e5],["hh:mm\nMM-dd",6*oy],["hh:mm\nMM-dd",432e5],["MM-dd\nyyyy",ay],["MM-dd\nyyyy",2*ay],["MM-dd\nyyyy",3*ay],["MM-dd\nyyyy",4*ay],["MM-dd\nyyyy",5*ay],["MM-dd\nyyyy",6*ay],["week",7*ay],["MM-dd\nyyyy",864e6],["week",14*ay],["week",21*ay],["month",31*ay],["week",42*ay],["month",62*ay],["week",70*ay],["quarter",95*ay],["month",31*ay*4],["month",13392e6],["half-year",16416e6],["month",31*ay*8],["month",26784e6],["year",380*ay]];sy.create=function(t){return new sy({useUTC:t.ecModel.get("useUTC")})};var uy=Na.prototype,hy=Qv.prototype,cy=Qi,dy=qi,fy=Math.floor,py=Math.ceil,gy=Math.pow,my=Math.log,vy=Na.extend({type:"log",base:10,$constructor:function(){Na.apply(this,arguments),this._originalScale=new Qv},getTicks:function(){var t=this._originalScale,e=this._extent,n=t.getExtent();return p(hy.getTicks.call(this),function(i){var r=qi(gy(this.base,i));return r=i===e[0]&&t.__fixMin?$a(r,n[0]):r,r=i===e[1]&&t.__fixMax?$a(r,n[1]):r},this)},getLabel:hy.getLabel,scale:function(t){return t=uy.scale.call(this,t),gy(this.base,t)},setExtent:function(t,e){var n=this.base;t=my(t)/my(n),e=my(e)/my(n),hy.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=uy.getExtent.call(this);e[0]=gy(t,e[0]),e[1]=gy(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=$a(e[0],i[0])),n.__fixMax&&(e[1]=$a(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=my(t[0])/my(e),t[1]=my(t[1])/my(e),uy.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(1/0===n||0>=n)){var i=rr(n);for(.5>=t/n*i&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var r=[qi(py(e[0]/i)*i),qi(fy(e[1]/i)*i)];this._interval=i,this._niceExtent=r}},niceExtent:function(t){hy.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});f(["contain","normalize"],function(t){vy.prototype[t]=function(e){return e=my(e)/my(this.base),uy[t].call(this,e)}}),vy.create=function(){return new vy};var yy={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&&!t.scale},getCoordSysModel:R,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},xy=ni({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,o=e.height/2;t.moveTo(n,i-o),t.lineTo(n+r,i+o),t.lineTo(n-r,i+o),t.closePath()}}),_y=ni({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,o=e.height/2;t.moveTo(n,i-o),t.lineTo(n+r,i),t.lineTo(n,i+o),t.lineTo(n-r,i),t.closePath()}}),wy=ni({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,o=Math.max(r,e.height),a=r/2,s=a*a/(o-a),l=i-o+a+s,u=Math.asin(s/a),h=Math.cos(u)*a,c=Math.sin(u),d=Math.cos(u),f=.6*a,p=.7*a;t.moveTo(n-h,l+s),t.arc(n,l,a,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()}}),by=ni({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,o=e.y,a=i/3*2;t.moveTo(r,o),t.lineTo(r+a,o+n),t.lineTo(r,o+n/4*3),t.lineTo(r-a,o+n),t.lineTo(r,o),t.closePath()}}),Sy={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 o=Math.min(n,i);r.x=t,r.y=e,r.width=o,r.height=o},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}},My={};f({line:Wp,rect:Vp,roundRect:Vp,square:Vp,circle:Dp,diamond:_y,pin:wy,arrow:by,triangle:xy},function(t,e){My[e]=new t});var Iy=ni({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,e,n){var i=ve(t,e,n),r=this.shape;return r&&"pin"===r.symbolType&&"inside"===e.textPosition&&(i.y=n.y+.4*n.height),i},buildPath:function(t,e,n){var i=e.symbolType;if("none"!==i){var r=My[i];r||(i="rect",r=My[i]),Sy[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n)}}}),Cy={isDimensionStacked:Oa,enableDataStack:Pa,getStackedDimension:La},Ty=(Object.freeze||Object)({createList:function(t){return za(t.getSource(),t)},getLayoutRect:mr,dataStack:Cy,createScale:function(t,e){var n=e;Hi.isInstance(e)||(n=new Hi(e),c(n,yy));var i=Ja(n);return i.setExtent(t[0],t[1]),Qa(i,n),i},mixinAxisModelCommonMethods:function(t){c(t,yy)},completeDimensions:Da,createDimensions:Yv,createSymbol:as}),Ay=1e-8;us.prototype={constructor:us,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=[],o=[],a=this.geometries,s=0;s<a.length;s++)if("polygon"===a[s].type){Dn(a[s].exterior,r,o),Q(n,n,r),J(i,i,o)}return 0===s&&(n[0]=n[1]=i[0]=i[1]=0),this._rect=new te(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 o=n[i].exterior,a=n[i].interiors;if(ls(o,t[0],t[1])){for(var s=0;s<(a?a.length:0);s++)if(ls(a[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),o=r.width/r.height;n?i||(i=n/o):n=o*i;for(var a=new te(t,e,n,i),s=r.calculateTransform(a),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++)K(h[d],h[d],s);for(var f=0;f<(c?c.length:0);f++)for(d=0;d<c[f].length;d++)K(c[f][d],c[f][d],s)}(r=this._rect).copy(a),this.center=[r.x+r.width/2,r.y+r.height/2]},cloneShallow:function(t){null==t&&(t=this.name);var e=new us(t,this.geometries,this.center);return e._rect=this._rect,e.transformTo=null,e}};var Dy=function(t){return function(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],o=r.geometry,a=o.coordinates,s=o.encodeOffsets,l=0;l<a.length;l++){var u=a[l];if("Polygon"===o.type)a[l]=hs(u,s[l],e);else if("MultiPolygon"===o.type)for(var h=0;h<u.length;h++){var c=u[h];u[h]=hs(c,s[l][h],e)}}t.UTF8Encoding=!1}(t),p(m(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 o=new us(e.name,r,e.cp);return o.properties=e,o})},ky=on(),Py=[0,1],Oy=function(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1};Oy.prototype={constructor:Oy,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 Ji(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(),xs(n,i.count())),Ui(t,Py,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&(n=n.slice(),xs(n,i.count()));var r=Ui(t,n,Py,e);return this.scale.scale(r)},pointToData:function(){},getTicksCoords:function(t){var e=(t=t||{}).tickModel||this.getTickModel(),n=p(ds(this,e).ticks,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this);return function(t,e,n,i){function r(t,e){return t=qi(t),e=qi(e),c?t>e:e>t}var o=e.length;if(t.onBand&&!n&&o){var a,s,l=t.getExtent();if(1===o)e[0].coord=l[0],a=e[1]={coord:l[0]};else{var u=e[o-1].tickValue-e[0].tickValue,h=(e[o-1].coord-e[0].coord)/u;f(e,function(t){t.coord-=h/2}),s=1+t.scale.getExtent()[1]-e[o-1].tickValue,a={coord:e[o-1].coord+h*s},e.push(a)}var c=l[0]>l[1];r(e[0].coord,l[0])&&(i?e[0].coord=l[0]:e.shift()),i&&r(l[0],e[0].coord)&&e.unshift({coord:l[0]}),r(l[1],a.coord)&&(i?a.coord=l[1]:e.pop()),i&&r(a.coord,l[1])&&e.push({coord:l[1]})}}(this,n,e.get("alignWithLabel"),t.clamp),n},getViewLabels:function(){return cs(this).labels},getLabelModel:function(){return this.model.getModel("axisLabel")},getTickModel:function(){return this.model.getModel("axisTick")},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,calculateCategoryInterval:function(){return function(t){var e=function(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}(t),n=ts(t),i=(e.axisRotate-e.labelRotate)/180*Math.PI,r=t.scale,o=r.getExtent(),a=r.count();if(o[1]-o[0]<1)return 0;var s=1;a>40&&(s=Math.max(1,Math.floor(a/40)));for(var l=o[0],u=t.dataToCoord(l+1)-t.dataToCoord(l),h=Math.abs(u*Math.cos(i)),c=Math.abs(u*Math.sin(i)),d=0,f=0;l<=o[1];l+=s){var p=0,g=0,m=pe(n(l),e.font,"center","top");p=1.3*m.width,g=1.3*m.height,d=Math.max(d,p,7),f=Math.max(f,g,7)}var v=d/h,y=f/c;isNaN(v)&&(v=1/0),isNaN(y)&&(y=1/0);var x=Math.max(0,Math.floor(Math.min(v,y))),_=ky(t.model),w=t.getExtent(),b=_.lastAutoInterval,S=_.lastTickCount;return null!=b&&null!=S&&Math.abs(b-x)<=1&&Math.abs(S-a)<=1&&b>x&&_.axisExtend0===w[0]&&_.axisExtend1===w[1]?x=b:(_.lastTickCount=a,_.lastAutoInterval=x,_.axisExtend0=w[0],_.axisExtend1=w[1]),x}(this)}};var Ly=Dy,zy={};f(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){zy[t]=_c[t]});var Ny={};f(["extendShape","extendPath","makePath","makeImage","mergePath","resizePath","createIcon","setHoverStyle","setLabelStyle","setTextStyle","setText","getFont","updateProps","initProps","getTransform","clipPointsByRect","clipRectByRect","registerShape","getShapeClass","Group","Image","Text","Circle","Sector","Ring","Polygon","Polyline","Rect","Line","BezierCurve","Arc","IncrementalDisplayable","CompoundPath","LinearGradient","RadialGradient","BoundingRect"],function(t){Ny[t]=hg[t]});var Ey=function(t){this._axes={},this._dimList=[],this.name=t||""};Ey.prototype={constructor:Ey,type:"cartesian",getAxis:function(t){return this._axes[t]},getAxes:function(){return p(this._dimList,_s,this)},getAxesByScale:function(t){return t=t.toLowerCase(),m(this.getAxes(),function(e){return e.scale.type===t})},addAxis:function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},dataToCoord:function(t){return this._dataCoordConvert(t,"dataToCoord")},coordToData:function(t){return this._dataCoordConvert(t,"coordToData")},_dataCoordConvert:function(t,e){for(var n=this._dimList,i=t instanceof Array?[]:{},r=0;r<n.length;r++){var o=n[r],a=this._axes[o];i[o]=a[e](t[o])}return i}},ws.prototype={constructor:ws,type:"cartesian2d",dimensions:["x","y"],getBaseAxis:function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},containPoint:function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},containData:function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},dataToPoint:function(t,e,n){var i=this.getAxis("x"),r=this.getAxis("y");return n=n||[],n[0]=i.toGlobalCoord(i.dataToCoord(t[0])),n[1]=r.toGlobalCoord(r.dataToCoord(t[1])),n},clampData:function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),o=i.getExtent(),a=n.parse(t[0]),s=i.parse(t[1]);return e=e||[],e[0]=Math.min(Math.max(Math.min(r[0],r[1]),a),Math.max(r[0],r[1])),e[1]=Math.min(Math.max(Math.min(o[0],o[1]),s),Math.max(o[0],o[1])),e},pointToData:function(t,e){var n=this.getAxis("x"),i=this.getAxis("y");return e=e||[],e[0]=n.coordToData(n.toLocalCoord(t[0])),e[1]=i.coordToData(i.toLocalCoord(t[1])),e},getOtherAxis:function(t){return this.getAxis("x"===t.dim?"y":"x")},getArea:function(){var t=this.getAxis("x").getGlobalExtent(),e=this.getAxis("y").getGlobalExtent(),n=Math.min(t[0],t[1]),i=Math.min(e[0],e[1]);return new te(n,i,Math.max(t[0],t[1])-n,Math.max(e[0],e[1])-i)}},h(ws,Ey);var By=function(t,e,n,i,r){Oy.call(this,t,e,n),this.type=i||"value",this.position=r||"bottom"};By.prototype={constructor:By,index:0,getAxesOnZeroOf:null,model:null,isHorizontal:function(){var t=this.position;return"top"===t||"bottom"===t},getGlobalExtent:function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},h(By,Oy);var Ry={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},Fy={};Fy.categoryAxis=r({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Ry),Fy.valueAxis=r({boundaryGap:[0,0],splitNumber:5},Ry),Fy.timeAxis=s({scale:!0,min:"dataMin",max:"dataMax"},Fy.valueAxis),Fy.logAxis=s({scale:!0,logBase:10},Fy.valueAxis);var Vy=["value","category","time","log"],Gy=function(t,e,n,i){f(Vy,function(a){e.extend({type:t+"Axis."+a,mergeDefaultAndTheme:function(e,i){var o=this.layoutMode,s=o?xr(e):{};r(e,i.getTheme().get(a+"Axis")),r(e,this.getDefaultOption()),e.type=n(t,e),o&&yr(e,s,o)},optionUpdated:function(){"category"===this.option.type&&(this.__ordinalMeta=Ea.createByAxisModel(this))},getCategories:function(t){var e=this.option;return"category"===e.type?t?e.data:this.__ordinalMeta.categories:void 0},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:o([{},Fy[a+"Axis"],i],!0)})}),zg.registerSubTypeDefaulter(t+"Axis",y(n,t))},Wy=zg.extend({type:"cartesian2dAxis",axis:null,init:function(){Wy.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){Wy.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){Wy.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});r(Wy.prototype,yy);var Hy={offset:0};Gy("x",Wy,bs,Hy),Gy("y",Wy,bs,Hy),zg.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var Zy=Ms.prototype;Zy.type="grid",Zy.axisPointerEnabled=!0,Zy.getRect=function(){return this._rect},Zy.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),f(n.x,function(t){Qa(t.scale,t.model)}),f(n.y,function(t){Qa(t.scale,t.model)});var i={};f(n.x,function(t){Is(n,"y",t,i)}),f(n.y,function(t){Is(n,"x",t,i)}),this.resize(this.model,e)},Zy.resize=function(t,e,n){function i(){f(o,function(t){var e=t.isHorizontal(),n=e?[0,r.width]:[0,r.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),function(t,e){var n=t.getExtent(),i=n[0]+n[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return i-t+e}}(t,e?r.x:r.y)})}var r=mr(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=r;var o=this._axesList;i(),!n&&t.get("containLabel")&&(f(o,function(t){if(!t.model.get("axisLabel.inside")){var e=ns(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get("axisLabel.margin");r[n]-=e[n]+i,"top"===t.position?r.y+=e.height+i:"left"===t.position&&(r.x+=e.width+i)}}}),i())},Zy.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n){if(null==e)for(var i in n)if(n.hasOwnProperty(i))return n[i];return n[e]}},Zy.getAxes=function(){return this._axesList.slice()},Zy.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}b(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===t||r[i].getAxis("y").index===e)return r[i]},Zy.getCartesians=function(){return this._coordsList.slice()},Zy.convertToPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},Zy.convertFromPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},Zy._findConvertTarget=function(t,e){var n,i,r=e.seriesModel,o=e.xAxisModel||r&&r.getReferringComponents("xAxis")[0],a=e.yAxisModel||r&&r.getReferringComponents("yAxis")[0],s=e.gridModel,l=this._coordsList;if(r)n=r.coordinateSystem,u(l,n)<0&&(n=null);else if(o&&a)n=this.getCartesian(o.componentIndex,a.componentIndex);else if(o)i=this.getAxis("x",o.componentIndex);else if(a)i=this.getAxis("y",a.componentIndex);else if(s){s.coordinateSystem===this&&(n=this._coordsList[0])}return{cartesian:n,axis:i}},Zy.containPoint=function(t){var e=this._coordsList[0];return e?e.containPoint(t):void 0},Zy._initCartesian=function(t,e){function n(e){return function(n,a){if(Ss(n,t)){var s=n.get("position");"x"===e?"top"!==s&&"bottom"!==s&&(s=i.bottom?"top":"bottom"):"left"!==s&&"right"!==s&&(s=i.left?"right":"left"),i[s]=!0;var l=new By(e,Ja(n),[0,0],n.get("type"),s),u="category"===l.type;l.onBand=u&&n.get("boundaryGap"),l.inverse=n.get("inverse"),n.axis=l,l.model=n,l.grid=this,l.index=a,this._axesList.push(l),r[e][a]=l,o[e]++}}}var i={left:!1,right:!1,top:!1,bottom:!1},r={x:{},y:{}},o={x:0,y:0};return e.eachComponent("xAxis",n("x"),this),e.eachComponent("yAxis",n("y"),this),o.x&&o.y?(this._axesMap=r,void f(r.x,function(e,n){f(r.y,function(i,r){var o="x"+n+"y"+r,a=new ws(o);a.grid=this,a.model=t,this._coordsMap[o]=a,this._coordsList.push(a),a.addAxis(e),a.addAxis(i)},this)},this)):(this._axesMap={},void(this._axesList=[]))},Zy._updateScale=function(t,e){function n(t,e){f(t.mapDimension(e.dim,!0),function(n){e.scale.unionExtentFromData(t,La(t,n))})}f(this._axesList,function(t){t.scale.setExtent(1/0,-1/0)}),t.eachSeries(function(t){if(As(t)){var i=Ts(t),r=i[0],o=i[1];if(!Ss(r,e)||!Ss(o,e))return;var a=this.getCartesian(r.componentIndex,o.componentIndex),s=t.getData(),l=a.getAxis("x"),u=a.getAxis("y");"list"===s.type&&(n(s,l),n(s,u))}},this)},Zy.getTooltipAxes=function(t){var e=[],n=[];return f(this.getCartesians(),function(i){var r=null!=t&&"auto"!==t?i.getAxis(t):i.getBaseAxis(),o=i.getOtherAxis(r);u(e,r)<0&&e.push(r),u(n,o)<0&&n.push(o)}),{baseAxes:e,otherAxes:n}};var Xy=["xAxis","yAxis"];Ms.create=function(t,e){var n=[];return t.eachComponent("grid",function(i,r){var o=new Ms(i,t,e);o.name="grid_"+r,o.resize(i,e,!0),i.coordinateSystem=o,n.push(o)}),t.eachSeries(function(t){if(As(t)){var e=Ts(t),n=e[0],i=e[1],r=n.getCoordSysModel().coordinateSystem;t.coordinateSystem=r.getCartesian(n.componentIndex,i.componentIndex)}}),n},Ms.dimensions=Ms.prototype.dimensions=ws.prototype.dimensions,Lr.register("cartesian2d",Ms);xm.extend({type:"series.__base_bar__",getInitialData:function(){return za(this.getSource(),this)},getMarkerPosition:function(t){var e=this.coordinateSystem;if(e){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),r=i.getLayout("offset"),o=i.getLayout("size");return n[e.getBaseAxis().isHorizontal()?0:1]+=r+o/2,n}return[NaN,NaN]},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",itemStyle:{},emphasis:{}}}).extend({type:"series.bar",dependencies:["grid","polar"],brushSelector:"rect",getProgressive:function(){return!!this.get("large")&&this.get("progressive")},getProgressiveThreshold:function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return e>t&&(t=e),t},defaultOption:{clip:!0,roundCap:!1}});var Yy=wf([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["stroke","barBorderColor"],["lineWidth","barBorderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Uy={getBarItemStyle:function(t){var e=Yy(this,t);if(this.getBorderLineDash){var n=this.getBorderLineDash();n&&(e.lineDash=n)}return e}},jy=ni({type:"sausage",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),o=Math.max(e.r,0),a=.5*(o-r),s=r+a,l=e.startAngle,u=e.endAngle,h=e.clockwise,c=Math.cos(l),d=Math.sin(l),f=Math.cos(u),p=Math.sin(u);(h?u-l<2*Math.PI:l-u<2*Math.PI)&&(t.moveTo(c*r+n,d*r+i),t.arc(c*s+n,d*s+i,a,-Math.PI+l,l,!h)),t.arc(n,i,o,l,u,!h),t.moveTo(f*o+n,p*o+i),t.arc(f*s+n,p*s+i,a,u-2*Math.PI,u-Math.PI,!h),0!==r&&(t.arc(n,i,r,u,l,h),t.moveTo(c*r+n,p*r+i)),t.closePath()}}),qy=["itemStyle","barBorderWidth"],$y=[0,0];a(Hi.prototype,Uy),fa({type:"bar",render:function(t,e,n){this._updateDrawMode(t);var i=t.get("coordinateSystem");return("cartesian2d"===i||"polar"===i)&&(this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n)),this.group},incrementalPrepareRender:function(t){this._clear(),this._updateDrawMode(t)},incrementalRender:function(t,e){this._incrementalRenderLarge(t,e)},_updateDrawMode:function(t){var e=t.pipelineContext.large;(null==this._isLargeDraw||e^this._isLargeDraw)&&(this._isLargeDraw=e,this._clear())},_renderNormal:function(t){var e,n=this.group,i=t.getData(),r=this._data,o=t.coordinateSystem,a=o.getBaseAxis();"cartesian2d"===o.type?e=a.isHorizontal():"polar"===o.type&&(e="angle"===a.dim);var s=t.isAnimationEnabled()?t:null,l=t.get("clip",!0),u=function(t,e){var n=t.getArea&&t.getArea();if("cartesian2d"===t.type){var i=t.getBaseAxis();if("category"!==i.type||!i.onBand){var r=e.getLayout("bandWidth");i.isHorizontal()?(n.x-=r,n.width+=2*r):(n.y-=r,n.height+=2*r)}}return n}(o,i);n.removeClipPath();var h=t.get("roundCap",!0);i.diff(r).add(function(r){if(i.hasValue(r)){var a=i.getItemModel(r),c=ex[o.type](i,r,a);if(l){if(Jy[o.type](u,c))return void n.remove(d)}var d=tx[o.type](r,c,e,s,!1,h);i.setItemGraphicEl(r,d),n.add(d),Ns(d,i,r,a,c,t,e,"polar"===o.type)}}).update(function(a,c){var d=r.getItemGraphicEl(c);if(i.hasValue(a)){var f=i.getItemModel(a),p=ex[o.type](i,a,f);if(l){if(Jy[o.type](u,p))return void n.remove(d)}d?Li(d,{shape:p},s,a):d=tx[o.type](a,p,e,s,!0,h),i.setItemGraphicEl(a,d),n.add(d),Ns(d,i,a,f,p,t,e,"polar"===o.type)}else n.remove(d)}).remove(function(t){var e=r.getItemGraphicEl(t);"cartesian2d"===o.type?e&&Ls(t,s,e):e&&zs(t,s,e)}).execute(),this._data=i},_renderLarge:function(t){this._clear(),Es(t,this.group);var e=t.get("clip",!0)?function(t,e,n){return t?"polar"===t.type?Os(t,e,n):"cartesian2d"===t.type?Ps(t,e,n):null:null}(t.coordinateSystem,!1,t):null;e?this.group.setClipPath(e):this.group.removeClipPath()},_incrementalRenderLarge:function(t,e){Es(e,this.group,!0)},dispose:R,remove:function(t){this._clear(t)},_clear:function(t){var e=this.group,n=this._data;t&&t.get("animation")&&n&&!this._isLargeDraw?n.eachItemGraphicEl(function(e){"sector"===e.type?zs(e.dataIndex,t,e):Ls(e.dataIndex,t,e)}):e.removeAll(),this._data=null}});var Ky=Math.max,Qy=Math.min,Jy={cartesian2d:function(t,e){var n=e.width<0?-1:1,i=e.height<0?-1:1;0>n&&(e.x+=e.width,e.width=-e.width),0>i&&(e.y+=e.height,e.height=-e.height);var r=Ky(e.x,t.x),o=Qy(e.x+e.width,t.x+t.width),a=Ky(e.y,t.y),s=Qy(e.y+e.height,t.y+t.height);e.x=r,e.y=a,e.width=o-r,e.height=s-a;var l=e.width<0||e.height<0;return 0>n&&(e.x+=e.width,e.width=-e.width),0>i&&(e.y+=e.height,e.height=-e.height),l},polar:function(){return!1}},tx={cartesian2d:function(t,e,n,i,r){var o=new Vp({shape:a({},e)});if(i){var s=o.shape,l=n?"height":"width",u={};s[l]=0,u[l]=e[l],hg[r?"updateProps":"initProps"](o,{shape:u},i,t)}return o},polar:function(t,e,n,i,r,o){var a=e.startAngle<e.endAngle,l=new(!n&&o?jy:Op)({shape:s({clockwise:a},e)});if(i){var u=l.shape,h=n?"r":"endAngle",c={};u[h]=n?0:e.startAngle,c[h]=e[h],hg[r?"updateProps":"initProps"](l,{shape:c},i,t)}return l}},ex={cartesian2d:function(t,e,n){var i=t.getItemLayout(e),r=function(t,e){var n=t.get(qy)||0;return Math.min(n,Math.abs(e.width),Math.abs(e.height))}(n,i),o=i.width>0?1:-1,a=i.height>0?1:-1;return{x:i.x+o*r/2,y:i.y+a*r/2,width:i.width-o*r,height:i.height-a*r}},polar:function(t,e){var n=t.getItemLayout(e);return{cx:n.cx,cy:n.cy,r0:n.r0,r:n.r,startAngle:n.startAngle,endAngle:n.endAngle}}},nx=Xn.extend({type:"largeBar",shape:{points:[]},buildPath:function(t,e){for(var n=e.points,i=this.__startPoint,r=this.__baseDimIdx,o=0;o<n.length;o+=2)i[r]=n[o+r],t.moveTo(i[0],i[1]),t.lineTo(n[o],n[o+1])}}),ix=mo(function(t){var e=function(t,e,n){var i=t.__baseDimIdx,r=1-i,o=t.shape.points,a=t.__largeDataIndices,s=Math.abs(t.__barWidth/2),l=t.__startPoint[r];$y[0]=e,$y[1]=n;for(var u=$y[i],h=$y[1-i],c=u-s,d=u+s,f=0,p=o.length/2;p>f;f++){var g=2*f,m=o[g+i],v=o[g+r];if(m>=c&&d>=m&&(v>=l?h>=l&&v>=h:h>=v&&l>=h))return a[f]}return-1}(this,t.offsetX,t.offsetY);this.dataIndex=e>=0?e:null},30,!1),rx=Math.PI,ox=function(t,e){this.opt=e,this.axisModel=t,s(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new yd;var n=new yd({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n};ox.prototype={constructor:ox,hasBuilder:function(t){return!!ax[t]},add:function(t){ax[t].call(this)},getGroup:function(){return this.group}};var ax={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],o=[n[1],0];i&&(K(r,r,i),K(o,o,i));var s=a({lineCap:"round"},e.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new Wp({anid:"line",subPixelOptimize:!0,shape:{x1:r[0],y1:r[1],x2:o[0],y2:o[1]},style:s,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1}));var l=e.get("axisLine.symbol"),u=e.get("axisLine.symbolSize"),h=e.get("axisLine.symbolOffset")||0;if("number"==typeof h&&(h=[h,h]),null!=l){"string"==typeof l&&(l=[l,l]),("string"==typeof u||"number"==typeof u)&&(u=[u,u]);var c=u[0],d=u[1];f([{rotate:t.rotation+Math.PI/2,offset:h[0],r:0},{rotate:t.rotation-Math.PI/2,offset:h[1],r:Math.sqrt((r[0]-o[0])*(r[0]-o[0])+(r[1]-o[1])*(r[1]-o[1]))}],function(e,n){if("none"!==l[n]&&null!=l[n]){var i=as(l[n],-c/2,-d/2,c,d,s.stroke,!0),o=e.r+e.offset,a=[r[0]+o*Math.cos(t.rotation),r[1]-o*Math.sin(t.rotation)];i.attr({rotation:e.rotate,position:a,silent:!0,z2:11}),this.group.add(i)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=function(t,e,n){var i=e.axis;if(e.get("axisTick.show")&&!i.scale.isBlank()){for(var r=e.getModel("axisTick"),o=r.getModel("lineStyle"),a=r.get("length"),l=i.getTicksCoords(),u=[],h=[],c=t._transform,d=[],f=0;f<l.length;f++){var p=l[f].coord;u[0]=p,u[1]=0,h[0]=p,h[1]=n.tickDirection*a,c&&(K(u,u,c),K(h,h,c));var g=new Wp({anid:"tick_"+l[f].tickValue,subPixelOptimize:!0,shape:{x1:u[0],y1:u[1],x2:h[0],y2:h[1]},style:s(o.getLineStyle(),{stroke:e.get("axisLine.lineStyle.color")}),z2:2,silent:!0});t.group.add(g),d.push(g)}return d}}(this,t,e);!function(t,e,n){if(!rs(t.axis)){var i=t.get("axisLabel.showMinLabel"),r=t.get("axisLabel.showMaxLabel");e=e||[],n=n||[];var o=e[0],a=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];!1===i?(Bs(o),Bs(u)):Rs(o,a)&&(i?(Bs(a),Bs(h)):(Bs(o),Bs(u))),!1===r?(Bs(s),Bs(c)):Rs(l,s)&&(r?(Bs(l),Bs(d)):(Bs(s),Bs(c)))}}(t,function(t,e,n){var i=e.axis;if(T(n.axisLabelShow,e.get("axisLabel.show"))&&!i.scale.isBlank()){var r=e.getModel("axisLabel"),o=r.get("margin"),a=i.getViewLabels(),s=(T(n.labelRotate,r.get("rotate"))||0)*rx/180,l=lx(n.rotation,s,n.labelDirection),u=e.getCategories&&e.getCategories(!0),h=[],c=ux(e),d=e.get("triggerEvent");return f(a,function(a,s){var f=a.tickValue,p=a.formattedLabel,g=a.rawLabel,m=r;u&&u[f]&&u[f].textStyle&&(m=new Hi(u[f].textStyle,r,e.ecModel));var v=m.getTextColor()||e.get("axisLine.lineStyle.color"),y=[i.dataToCoord(f),n.labelOffset+n.labelDirection*o],x=new Ap({anid:"label_"+f,position:y,rotation:l.rotation,silent:c,z2:10});Ii(x.style,m,{text:p,textAlign:m.getShallow("align",!0)||l.textAlign,textVerticalAlign:m.getShallow("verticalAlign",!0)||m.getShallow("baseline",!0)||l.textVerticalAlign,textFill:"function"==typeof v?v("category"===i.type?g:"value"===i.type?f+"":f,s):v}),d&&(x.eventData=sx(e),x.eventData.targetType="axisLabel",x.eventData.value=g),t._dumbGroup.add(x),x.updateTransform(),h.push(x),t.group.add(x),x.decomposeTransform()}),h}}(this,t,e),n)},axisName:function(){var t=this.opt,e=this.axisModel,n=T(t.axisName,e.get("name"));if(n){var i,r=e.get("nameLocation"),o=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,Fs(r)?t.labelOffset+o*l:0],d=e.get("nameRotate");null!=d&&(d=d*rx/180);var f;Fs(r)?i=lx(t.rotation,null!=d?d:t.rotation,o):(i=function(t,e,n,i){var r,o,a=er(n-t.rotation),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;return nr(a-rx/2)?(o=l?"bottom":"top",r="center"):nr(a-1.5*rx)?(o=l?"top":"bottom",r="center"):(o="middle",r=1.5*rx>a&&a>rx/2?l?"left":"right":l?"right":"left"),{rotation:a,textAlign:r,textVerticalAlign:o}}(t,r,d||0,u),null!=(f=t.axisNameAvailableWidth)&&(f=Math.abs(f/Math.sin(i.rotation)),!isFinite(f)&&(f=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,v=T(t.nameTruncateMaxWidth,g.maxWidth,f),y=null!=m&&null!=v?Cg(n,v,p,m,{minChar:2,placeholder:g.placeholder}):n,x=e.get("tooltip",!0),_=e.mainType,w={componentType:_,name:n,$vars:["name"]};w[_+"Index"]=e.componentIndex;var b=new Ap({anid:"name",__fullText:n,__truncatedText:y,position:c,rotation:i.rotation,silent:ux(e),z2:1,tooltip:x&&x.show?a({content:n,formatter:function(){return n},formatterParams:w},x):null});Ii(b.style,s,{text:y,textFont:p,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:s.get("align")||i.textAlign,textVerticalAlign:s.get("verticalAlign")||i.textVerticalAlign}),e.get("triggerEvent")&&(b.eventData=sx(e),b.eventData.targetType="axisName",b.eventData.name=n),this._dumbGroup.add(b),b.updateTransform(),this.group.add(b),b.decomposeTransform()}}},sx=ox.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},lx=ox.innerTextLayout=function(t,e,n){var i,r,o=er(e-t);return nr(o)?(r=n>0?"top":"bottom",i="center"):nr(o-rx)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=o>0&&rx>o?n>0?"right":"left":n>0?"left":"right"),{rotation:o,textAlign:i,textVerticalAlign:r}},ux=ox.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},hx=f,cx=y,dx=ca({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&function(t){var e=Hs(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,o=n.get("status"),a=n.get("value");null!=a&&(a=i.parse(a));var s=Zs(n);null==o&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==a||a>l[1])&&(a=l[1]),a<l[0]&&(a=l[0]),r.value=a,s&&(r.status=e.axis.scale.isBlank()?"hide":"show")}}(t),dx.superApply(this,"render",arguments),Ys(this,t,0,n,0,!0)},updateAxisPointer:function(t,e,n,i){Ys(this,t,0,n,0,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),dx.superApply(this,"remove",arguments)},dispose:function(t,e){Us(this,e),dx.superApply(this,"dispose",arguments)}}),fx=[];dx.registerAxisPointerClass=function(t,e){fx[t]=e},dx.getAxisPointerClass=function(t){return t&&fx[t]};var px=["axisLine","axisTickLabel","axisName"],gx=["splitArea","splitLine"],mx=dx.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(t,e,n,i){this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new yd,this.group.add(this._axisGroup),t.get("show")){var o=t.getCoordSysModel(),a=js(o,t),s=new ox(t,a);f(px,s.add,s),this._axisGroup.add(s.getGroup()),f(gx,function(e){t.get(e+".show")&&this["_"+e](t,o)},this),Ri(r,this._axisGroup,t),mx.superCall(this,"render",t,e,n,i)}},remove:function(){this._splitAreaColors=null},_splitLine:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitLine"),r=i.getModel("lineStyle"),o=r.get("color");o=x(o)?o:[o];for(var a=e.coordinateSystem.getRect(),l=n.isHorizontal(),u=0,h=n.getTicksCoords({tickModel:i}),c=[],d=[],f=r.getLineStyle(),p=0;p<h.length;p++){var g=n.toGlobalCoord(h[p].coord);l?(c[0]=g,c[1]=a.y,d[0]=g,d[1]=a.y+a.height):(c[0]=a.x,c[1]=g,d[0]=a.x+a.width,d[1]=g);var m=u++%o.length,v=h[p].tickValue;this._axisGroup.add(new Wp({anid:null!=v?"line_"+h[p].tickValue:null,subPixelOptimize:!0,shape:{x1:c[0],y1:c[1],x2:d[0],y2:d[1]},style:s({stroke:o[m]},f),silent:!0}))}}},_splitArea:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitArea"),r=i.getModel("areaStyle"),o=r.get("color"),a=e.coordinateSystem.getRect(),l=n.getTicksCoords({tickModel:i,clamp:!0});if(l.length){var u=o.length,h=this._splitAreaColors,c=B(),d=0;if(h)for(m=0;m<l.length;m++){var f=h.get(l[m].tickValue);if(null!=f){d=(f+(u-1)*m)%u;break}}var p=n.toGlobalCoord(l[0].coord),g=r.getAreaStyle();o=x(o)?o:[o];for(var m=1;m<l.length;m++){var v,y,_,w,b=n.toGlobalCoord(l[m].coord);n.isHorizontal()?(v=p,y=a.y,_=b-v,w=a.height,p=v+_):(v=a.x,y=p,_=a.width,w=b-y,p=y+w);var S=l[m-1].tickValue;null!=S&&c.set(S,d),this._axisGroup.add(new Vp({anid:null!=S?"area_"+S:null,shape:{x:v,y:y,width:_,height:w},style:s({fill:o[d]},g),silent:!0})),d=(d+1)%u}this._splitAreaColors=c}}}});mx.extend({type:"xAxis"}),mx.extend({type:"yAxis"}),ca({type:"grid",render:function(t){this.group.removeAll(),t.get("show")&&this.group.add(new Vp({shape:t.coordinateSystem.getRect(),style:s({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))}}),ia(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})}),aa(cv.VISUAL.LAYOUT,y(function(t,e){var n=Za(t,e),i=Xa(n),r={};f(n,function(t){var e=t.getData(),n=t.coordinateSystem,o=n.getBaseAxis(),a=Wa(t),s=i[Ha(o)][a],l=s.offset,u=s.width,h=n.getOtherAxis(o),c=t.get("barMinHeight")||0;r[a]=r[a]||[],e.setLayout({bandWidth:s.bandWidth,offset:l,size:u});for(var d=e.mapDimension(h.dim),f=e.mapDimension(o.dim),p=Oa(e,d),g=h.isHorizontal(),m=qa(0,h),v=0,y=e.count();y>v;v++){var x=e.get(d,v),_=e.get(f,v);if(!isNaN(x)&&!isNaN(_)){var w=x>=0?"p":"n",b=m;p&&(r[a][_]||(r[a][_]={p:m,n:m}),b=r[a][_][w]);var S,M,I,C;if(g)S=b,M=(T=n.dataToPoint([x,_]))[1]+l,I=T[0]-m,C=u,Math.abs(I)<c&&(I=(0>I?-1:1)*c),p&&(r[a][_][w]+=I);else{var T=n.dataToPoint([_,x]);S=T[0]+l,M=b,I=u,C=T[1]-m,Math.abs(C)<c&&(C=(0>=C?-1:1)*c),p&&(r[a][_][w]+=C)}e.setItemLayout(v,{x:S,y:M,width:I,height:C})}}},this)},"bar")),aa(cv.VISUAL.PROGRESSIVE_LAYOUT,ey),sa({seriesType:"bar",reset:function(t){t.getData().setVisual("legendSymbol","roundRect")}}),xm.extend({type:"series.line",dependencies:["grid","polar"],getInitialData:function(){return za(this.getSource(),this)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,clip:!0,label:{position:"top"},lineStyle:{width:2,type:"solid"},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0}});var vx=qs.prototype,yx=qs.getSymbolSize=function(t,e){var n=t.getItemVisual(e,"symbolSize");return n instanceof Array?n.slice():[+n,+n]};vx._createSymbol=function(t,e,n,i,r){this.removeAll();var o=as(t,-1,-1,2,2,e.getItemVisual(n,"color"),r);o.attr({z2:100,culling:!0,scale:$s(i)}),o.drift=Ks,this._symbolType=t,this.add(o)},vx.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},vx.getSymbolPath=function(){return this.childAt(0)},vx.getScale=function(){return this.childAt(0).scale},vx.highlight=function(){this.childAt(0).trigger("emphasis")},vx.downplay=function(){this.childAt(0).trigger("normal")},vx.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},vx.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":e.cursor},vx.updateData=function(t,e,n){this.silent=!1;var i=t.getItemVisual(e,"symbol")||"circle",r=t.hostModel,o=yx(t,e),a=i!==this._symbolType;if(a){var s=t.getItemVisual(e,"symbolKeepAspect");this._createSymbol(i,t,e,o,s)}else{(l=this.childAt(0)).silent=!1,Li(l,{scale:$s(o)},r,e)}if(this._updateCommon(t,e,o,n),a){var l=this.childAt(0),u=n&&n.fadeIn,h={scale:l.scale.slice()};u&&(h.style={opacity:l.style.opacity}),l.scale=[0,0],u&&(l.style.opacity=0),zi(l,h,r,e)}this._seriesModel=r};var xx=["itemStyle"],_x=["emphasis","itemStyle"],bx=["label"],Sx=["emphasis","label"];vx._updateCommon=function(t,e,n,i){var r=this.childAt(0),o=t.hostModel,s=t.getItemVisual(e,"color");"image"!==r.type?r.useStyle({strokeNoScale:!0}):r.setStyle({opacity:null,shadowBlur:null,shadowOffsetX:null,shadowOffsetY:null,shadowColor:null});var l=i&&i.itemStyle,u=i&&i.hoverItemStyle,h=i&&i.symbolRotate,c=i&&i.symbolOffset,d=i&&i.labelModel,f=i&&i.hoverLabelModel,p=i&&i.hoverAnimation,g=i&&i.cursorStyle;if(!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(e);l=m.getModel(xx).getItemStyle(["color"]),u=m.getModel(_x).getItemStyle(),h=m.getShallow("symbolRotate"),c=m.getShallow("symbolOffset"),d=m.getModel(bx),f=m.getModel(Sx),p=m.getShallow("hoverAnimation"),g=m.getShallow("cursor")}else u=a({},u);var v=r.style;r.attr("rotation",(h||0)*Math.PI/180||0),c&&r.attr("position",[ji(c[0],n[0]),ji(c[1],n[1])]),g&&r.attr("cursor",g),r.setColor(s,i&&i.symbolInnerColor),r.setStyle(l);var y=t.getItemVisual(e,"opacity");null!=y&&(v.opacity=y);var x=t.getItemVisual(e,"liftZ"),_=r.__z2Origin;null!=x?null==_&&(r.__z2Origin=r.z2,r.z2+=x):null!=_&&(r.z2=_,r.__z2Origin=null);var w=i&&i.useNameLabel;Mi(v,u,d,f,{labelFetcher:o,labelDataIndex:e,defaultText:function(e){return w?t.getName(e):Ds(t,e)},isRectText:!0,autoColor:s}),r.__symbolOriginalScale=$s(n),r.hoverStyle=u,r.highDownOnUpdate=p&&o.isAnimationEnabled()?function(t,e){if(!this.incremental&&!this.useHoverLayer)if("emphasis"===e){var n=this.__symbolOriginalScale,i=n[1]/n[0],r={scale:[Math.max(1.1*n[0],n[0]+3),Math.max(1.1*n[1],n[1]+3*i)]};this.animateTo(r,400,"elasticOut")}else"normal"===e&&this.animateTo({scale:this.__symbolOriginalScale},400,"elasticOut")}:null,_i(r)},vx.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,!(e&&e.keepLabel)&&(n.style.text=null),Li(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},h(qs,yd);var Mx=Qs.prototype;Mx.updateData=function(t,e){e=tl(e);var n=this.group,i=t.hostModel,r=this._data,o=this._symbolCtor,a=el(t);r||n.removeAll(),t.diff(r).add(function(i){var r=t.getItemLayout(i);if(Js(t,r,i,e)){var s=new o(t,i,a);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 Js(t,h,s,e)?(u?(u.updateData(t,s,a),Li(u,{position:h},i)):(u=new o(t,s)).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},Mx.isPersistent=function(){return!0},Mx.updateLayout=function(){var t=this._data;t&&t.eachItemGraphicEl(function(e,n){var i=t.getItemLayout(n);e.attr("position",i)})},Mx.incrementalPrepareUpdate=function(t){this._seriesScope=el(t),this._data=null,this.group.removeAll()},Mx.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}n=tl(n);for(var r=t.start;r<t.end;r++){var o=e.getItemLayout(r);if(Js(e,o,r,n)){var a=new this._symbolCtor(e,r,this._seriesScope);a.traverse(i),a.attr("position",o),this.group.add(a),e.setItemGraphicEl(r,a)}}},Mx.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 Ix=Q,Cx=J,Tx=H,Ax=V,Dx=[],kx=[],Px=[],Ox=Xn.extend({type:"ec-polyline",shape:{points:[],smooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},style:{fill:null,stroke:"#000"},brush:Pp(Xn.prototype.brush),buildPath:function(t,e){var n=e.points,i=0,r=n.length,o=al(n,e.smoothConstraint);if(e.connectNulls){for(;r>0&&rl(n[r-1]);r--);for(;r>i&&rl(n[i]);i++);}for(;r>i;)i+=ol(t,n,i,r,r,1,o.min,o.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),Lx=Xn.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:Pp(Xn.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,o=n.length,a=e.smoothMonotone,s=al(n,e.smoothConstraint),l=al(i,e.smoothConstraint);if(e.connectNulls){for(;o>0&&rl(n[o-1]);o--);for(;o>r&&rl(n[r]);r++);}for(;o>r;){var u=ol(t,n,r,o,o,1,s.min,s.max,e.smooth,a,e.connectNulls);ol(t,i,r+u-1,u,o,-1,l.min,l.max,e.stackedOnSmooth,a,e.connectNulls),r+=u+1,t.closePath()}}});ho.extend({type:"line",init:function(){var t=new yd,e=new Qs;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,o=t.getData(),a=t.getModel("lineStyle"),l=t.getModel("areaStyle"),u=o.mapArray(o.getItemLayout),h="polar"===i.type,c=this._coordSys,d=this._symbolDraw,f=this._polyline,p=this._polygon,g=this._lineGroup,m=t.get("animation"),v=!l.isEmpty(),y=l.get("origin"),x=function(t,e,n){if(!n.valueDim)return[];for(var i=[],r=0,o=e.count();o>r;r++)i.push(il(n,t,e,r));return i}(i,o,nl(i,o,y)),_=t.get("showSymbol"),w=_&&!h&&cl(t,o,i),b=this._data;b&&b.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),b.setItemGraphicEl(e,null))}),_||d.remove(),r.add(g);var S,M=!h&&t.get("step");i&&i.getArea&&(null!=(S=i.getArea()).width?(S.x-=.1,S.y-=.1,S.width+=.2,S.height+=.2):S.r0&&(S.r0-=.5,S.r1+=.5)),f&&c.type===i.type&&M===this._step?(v&&!p?p=this._newPolygon(u,x,i,m):p&&!v&&(g.remove(p),p=this._polygon=null),g.setClipPath(dl(i,!1,t)),_&&d.updateData(o,{isIgnore:w,clipShape:S}),o.eachItemGraphicEl(function(t){t.stopAnimation(!0)}),sl(this._stackedOnPoints,x)&&sl(this._points,u)||(m?this._updateAnimation(o,x,i,n,M,y):(M&&(u=ul(u,i,M),x=ul(x,i,M)),f.setShape({points:u}),p&&p.setShape({points:u,stackedOnPoints:x})))):(_&&d.updateData(o,{isIgnore:w,clipShape:S}),M&&(u=ul(u,i,M),x=ul(x,i,M)),f=this._newPolyline(u,i,m),v&&(p=this._newPolygon(u,x,i,m)),g.setClipPath(dl(i,!0,t)));var I=hl(o,i)||o.getVisual("color");f.useStyle(s(a.getLineStyle(),{fill:"none",stroke:I,lineJoin:"bevel"}));var C=t.get("smooth");if(C=ll(t.get("smooth")),f.setShape({smooth:C,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")}),p){var T=o.getCalculationInfo("stackedOnSeries"),A=0;p.useStyle(s(l.getAreaStyle(),{fill:I,opacity:.7,lineJoin:"bevel"})),T&&(A=ll(T.get("smooth"))),p.setShape({smooth:C,stackedOnSmooth:A,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")})}this._data=o,this._coordSys=i,this._stackedOnPoints=x,this._points=u,this._step=M,this._valueOrigin=y},dispose:function(){},highlight:function(t,e,n,i){var r=t.getData(),o=rn(r,i);if(!(o instanceof Array)&&null!=o&&o>=0){var a=r.getItemGraphicEl(o);if(!a){var s=r.getItemLayout(o);if(!s)return;(a=new qs(r,o)).position=s,a.setZ(t.get("zlevel"),t.get("z")),a.ignore=isNaN(s[0])||isNaN(s[1]),a.__temp=!0,r.setItemGraphicEl(o,a),a.stopSymbolAnimation(!0),this.group.add(a)}a.highlight()}else ho.prototype.highlight.call(this,t,e,n,i)},downplay:function(t,e,n,i){var r=t.getData(),o=rn(r,i);if(null!=o&&o>=0){var a=r.getItemGraphicEl(o);a&&(a.__temp?(r.setItemGraphicEl(o,null),this.group.remove(a)):a.downplay())}else ho.prototype.downplay.call(this,t,e,n,i)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new Ox({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e,e},_newPolygon:function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Lx({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(n),this._polygon=n,n},_updateAnimation:function(t,e,n,i,r,o){var a=this._polyline,s=this._polygon,l=t.hostModel,u=function(t,e,n,i,r,o,a,s){for(var l=function(t,e){var n=[];return e.diff(t).add(function(t){n.push({cmd:"+",idx:t})}).update(function(t,e){n.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){n.push({cmd:"-",idx:t})}).execute(),n}(t,e),u=[],h=[],c=[],d=[],f=[],p=[],g=[],m=nl(r,e,a),v=nl(o,t,s),y=0;y<l.length;y++){var x=l[y],_=!0;switch(x.cmd){case"=":var w=t.getItemLayout(x.idx),b=e.getItemLayout(x.idx1);(isNaN(w[0])||isNaN(w[1]))&&(w=b.slice()),u.push(w),h.push(b),c.push(n[x.idx]),d.push(i[x.idx1]),g.push(e.getRawIndex(x.idx1));break;case"+":S=x.idx,u.push(r.dataToPoint([e.get(m.dataDimsForPoint[0],S),e.get(m.dataDimsForPoint[1],S)])),h.push(e.getItemLayout(S).slice()),c.push(il(m,r,e,S)),d.push(i[S]),g.push(e.getRawIndex(S));break;case"-":var S=x.idx,M=t.getRawIndex(S);M!==S?(u.push(t.getItemLayout(S)),h.push(o.dataToPoint([t.get(v.dataDimsForPoint[0],S),t.get(v.dataDimsForPoint[1],S)])),c.push(n[S]),d.push(il(v,o,t,S)),g.push(M)):_=!1}_&&(f.push(x),p.push(p.length))}p.sort(function(t,e){return g[t]-g[e]});for(var I=[],C=[],T=[],A=[],D=[],y=0;y<p.length;y++)S=p[y],I[y]=u[S],C[y]=h[S],T[y]=c[S],A[y]=d[S],D[y]=f[S];return{current:I,next:C,stackedOnCurrent:T,stackedOnNext:A,status:D}}(this._data,t,this._stackedOnPoints,e,this._coordSys,n,this._valueOrigin,o),h=u.current,c=u.stackedOnCurrent,d=u.next,f=u.stackedOnNext;r&&(h=ul(u.current,n,r),c=ul(u.stackedOnCurrent,n,r),d=ul(u.next,n,r),f=ul(u.stackedOnNext,n,r)),a.shape.__points=u.current,a.shape.points=h,Li(a,{shape:{points:d}},l),s&&(s.setShape({points:h,stackedOnPoints:c}),Li(s,{shape:{points:d,stackedOnPoints:f}},l));for(var p=[],g=u.status,m=0;m<g.length;m++){if("="===g[m].cmd){var v=t.getItemGraphicEl(g[m].idx1);v&&p.push({el:v,ptIdx:m})}}a.animators&&a.animators.length&&a.animators[0].during(function(){for(var t=0;t<p.length;t++){p[t].el.attr("position",a.shape.__points[p[t].ptIdx])}})},remove:function(){var t=this.group,e=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),e&&e.eachItemGraphicEl(function(n,i){n.__temp&&(t.remove(n),e.setItemGraphicEl(i,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._data=null}});var zx={average:function(t){for(var e=0,n=0,i=0;i<t.length;i++)isNaN(t[i])||(e+=t[i],n++);return 0===n?NaN:e/n},sum:function(t){for(var e=0,n=0;n<t.length;n++)e+=t[n]||0;return e},max:function(t){for(var e=-1/0,n=0;n<t.length;n++)t[n]>e&&(e=t[n]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,n=0;n<t.length;n++)t[n]<e&&(e=t[n]);return isFinite(e)?e:NaN},nearest:function(t){return t[0]}},Nx=function(t){return Math.round(t.length/2)};sa(function(t,e,n){return{seriesType:t,performRawSeries:!0,reset:function(t,i){var r=t.getData(),o=t.get("symbol"),a=t.get("symbolSize"),s=t.get("symbolKeepAspect"),l=_(o),u=_(a),h=l||u,c=!l&&o?o:e,d=u?null:a;return r.setVisual({legendSymbol:n||c,symbol:c,symbolSize:d,symbolKeepAspect:s}),i.isSeriesFiltered(t)?void 0:{dataEach:r.hasItemOption||h?function(e,n){if(h){var i=t.getRawValue(n),r=t.getDataParams(n);l&&e.setItemVisual(n,"symbol",o(i,r)),u&&e.setItemVisual(n,"symbolSize",a(i,r))}if(e.hasItemOption){var s=e.getItemModel(n),c=s.getShallow("symbol",!0),d=s.getShallow("symbolSize",!0),f=s.getShallow("symbolKeepAspect",!0);null!=c&&e.setItemVisual(n,"symbol",c),null!=d&&e.setItemVisual(n,"symbolSize",d),null!=f&&e.setItemVisual(n,"symbolKeepAspect",f)}}:null}}}}("line","circle","line")),aa(function(t){return{seriesType:t,plan:bm(),reset:function(t){var e=t.getData(),n=t.coordinateSystem,i=t.pipelineContext.large;if(n){var r=p(n.dimensions,function(t){return e.mapDimension(t)}).slice(0,2),o=r.length,a=e.getCalculationInfo("stackResultDimension");return Oa(e,r[0])&&(r[0]=a),Oa(e,r[1])&&(r[1]=a),o&&{progress:function(t,e){for(var a=t.end-t.start,s=i&&new Float32Array(a*o),l=t.start,u=0,h=[],c=[];l<t.end;l++){var d;if(1===o)f=e.get(r[0],l),d=!isNaN(f)&&n.dataToPoint(f,null,c);else{var f=h[0]=e.get(r[0],l),p=h[1]=e.get(r[1],l);d=!isNaN(f)&&!isNaN(p)&&n.dataToPoint(h,null,c)}i?(s[u++]=d?d[0]:NaN,s[u++]=d?d[1]:NaN):e.setItemLayout(l,d&&d.slice()||[NaN,NaN])}i&&e.setLayout("symbolPoints",s)}}}}}}("line")),ra(cv.PROCESSOR.STATISTIC,function(t){return{seriesType:t,modifyOutputEnd:!0,reset:function(t){var e=t.getData(),n=t.get("sampling"),i=t.coordinateSystem;if("cartesian2d"===i.type&&n){var r=i.getBaseAxis(),o=i.getOtherAxis(r),a=r.getExtent(),s=a[1]-a[0],l=Math.round(e.count()/s);if(l>1){var u;"string"==typeof n?u=zx[n]:"function"==typeof n&&(u=n),u&&t.setData(e.downSample(e.mapDimension(o.dim),1/l,u,Nx))}}}}}("line"));var Ex={updateSelectedMap:function(t){this._targetList=x(t)?t.slice():[],this._selectTargetMap=g(t||[],function(t,e){return t.set(e.name,e),t},B())},select:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);"single"===this.get("selectedMode")&&this._selectTargetMap.each(function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);n&&(n.selected=!1)},toggleSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return null!=n?(this[n.selected?"unSelect":"select"](t,e),n.selected):void 0},isSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return n&&n.selected}},Bx=da({type:"series.pie",init:function(t){Bx.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this.updateSelectedMap(this._createSelectableList()),this._defaultLabelLine(t)},mergeOption:function(t){Bx.superCall(this,"mergeOption",t),this.updateSelectedMap(this._createSelectableList())},getInitialData:function(){return function(t,e,n){e=x(e)&&{coordDimensions:e}||a({},e);var i=t.getSource(),r=Yv(i,e),o=new Hv(r,t);return o.initData(i,n),o}(this,["value"])},_createSelectableList:function(){for(var t=this.getRawData(),e=t.mapDimension("value"),n=[],i=0,r=t.count();r>i;i++)n.push({name:t.getName(i),value:t.get(e,i),selected:to(t,i,"selected")});return n},getDataParams:function(t){var e=this.getData(),n=Bx.superCall(this,"getDataParams",t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=tr(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},_defaultLabelLine:function(t){Ke(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,hoverOffset:10,avoidLabelOverlap:!0,percentPrecision:2,stillShowZeroSum:!0,label:{rotate:!1,show:!0,position:"outer"},labelLine:{show:!0,length:15,length2:15,smooth:!1,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1},animationType:"expansion",animationTypeUpdate:"transition",animationEasing:"cubicOut"}});c(Bx,Ex);var Rx=gl.prototype;Rx.updateData=function(t,e,n){var i=this.childAt(0),r=this.childAt(1),o=this.childAt(2),l=t.hostModel,u=t.getItemModel(e),h=t.getItemLayout(e),c=a({},h);c.label=null;var d=l.getShallow("animationTypeUpdate");if(n){i.setShape(c);"scale"===l.getShallow("animationType")?(i.shape.r=h.r0,zi(i,{shape:{r:h.r}},l,e)):(i.shape.endAngle=h.startAngle,Li(i,{shape:{endAngle:h.endAngle}},l,e))}else"expansion"===d?i.setShape(c):Li(i,{shape:c},l,e);var f=t.getItemVisual(e,"color");i.useStyle(s({lineJoin:"bevel",fill:f},u.getModel("itemStyle").getItemStyle())),i.hoverStyle=u.getModel("emphasis.itemStyle").getItemStyle();var p=u.getShallow("cursor");p&&i.attr("cursor",p),pl(this,t.getItemLayout(e),l.isSelected(null,e),l.get("selectedOffset"),l.get("animation"));var g=!n&&"transition"===d;this._updateLabel(t,e,g),this.highDownOnUpdate=u.get("hoverAnimation")&&l.isAnimationEnabled()?function(t,e){"emphasis"===e?(r.ignore=r.hoverIgnore,o.ignore=o.hoverIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:h.r+l.get("hoverOffset")}},300,"elasticOut")):(r.ignore=r.normalIgnore,o.ignore=o.normalIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:h.r}},300,"elasticOut"))}:null,_i(this)},Rx._updateLabel=function(t,e,n){var i=this.childAt(1),r=this.childAt(2),o=t.hostModel,a=t.getItemModel(e),s=t.getItemLayout(e).label,l=t.getItemVisual(e,"color");if(!s||isNaN(s.x)||isNaN(s.y))r.ignore=r.normalIgnore=r.hoverIgnore=i.ignore=i.normalIgnore=i.hoverIgnore=!0;else{var u={points:s.linePoints||[[s.x,s.y],[s.x,s.y],[s.x,s.y]]},h={x:s.x,y:s.y};n?(Li(i,{shape:u},o,e),Li(r,{style:h},o,e)):(i.attr({shape:u}),r.attr({style:h})),r.attr({rotation:s.rotation,origin:[s.x,s.y],z2:10});var c=a.getModel("label"),d=a.getModel("emphasis.label"),f=a.getModel("labelLine"),p=a.getModel("emphasis.labelLine"),l=t.getItemVisual(e,"color");Mi(r.style,r.hoverStyle={},c,d,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:l,useInsideStyle:!!s.inside},{textAlign:s.textAlign,textVerticalAlign:s.verticalAlign,opacity:t.getItemVisual(e,"opacity")}),r.ignore=r.normalIgnore=!c.get("show"),r.hoverIgnore=!d.get("show"),i.ignore=i.normalIgnore=!f.get("show"),i.hoverIgnore=!p.get("show"),i.setStyle({stroke:l,opacity:t.getItemVisual(e,"opacity")}),i.setStyle(f.getModel("lineStyle").getLineStyle()),i.hoverStyle=p.getModel("lineStyle").getLineStyle();var g=f.get("smooth");g&&!0===g&&(g=.4),i.setShape({smooth:g})}},h(gl,yd);var Fx=(ho.extend({type:"pie",init:function(){var t=new yd;this._sectorGroup=t},render:function(t,e,n,i){if(!i||i.from!==this.uid){var r=t.getData(),o=this._data,a=this.group,s=e.get("animation"),l=!o,u=t.get("animationType"),h=t.get("animationTypeUpdate"),c=y(fl,this.uid,t,s,n),d=t.get("selectedMode");if(r.diff(o).add(function(t){var e=new gl(r,t);l&&"scale"!==u&&e.eachChild(function(t){t.stopAnimation(!0)}),d&&e.on("click",c),r.setItemGraphicEl(t,e),a.add(e)}).update(function(t,e){var n=o.getItemGraphicEl(e);l||"transition"===h||n.eachChild(function(t){t.stopAnimation(!0)}),n.updateData(r,t),n.off("click"),d&&n.on("click",c),a.add(n),r.setItemGraphicEl(t,n)}).remove(function(t){var e=o.getItemGraphicEl(t);a.remove(e)}).execute(),s&&r.count()>0&&(l?"scale"!==u:"transition"!==h)){for(var f=r.getItemLayout(0),p=1;isNaN(f.startAngle)&&p<r.count();++p)f=r.getItemLayout(p);var g=Math.max(n.getWidth(),n.getHeight())/2,m=v(a.removeClipPath,a);a.setClipPath(this._createClipPath(f.cx,f.cy,g,f.startAngle,f.clockwise,m,t,l))}else a.removeClipPath();this._data=r}},dispose:function(){},_createClipPath:function(t,e,n,i,r,o,a,s){var l=new Op({shape:{cx:t,cy:e,r0:0,r:n,startAngle:i,endAngle:i,clockwise:r}});return(s?zi:Li)(l,{shape:{endAngle:i+(r?1:-1)*Math.PI*2}},a,o),l},containPoint:function(t,e){var n=e.getData().getItemLayout(0);if(n){var i=t[0]-n.cx,r=t[1]-n.cy,o=Math.sqrt(i*i+r*r);return o<=n.r&&o>=n.r0}}}),function(t,e){f(e,function(e){e.update="updateView",oa(e,function(n,i){var r={};return i.eachComponent({mainType:"series",subType:t,query:n},function(t){t[e.method]&&t[e.method](n.name,n.dataIndex);var i=t.getData();i.each(function(e){var n=i.getName(e);r[n]=t.isSelected(n)||!1})}),{name:n.name,selected:r,seriesId:n.seriesId}})})}),Vx=Math.PI/180,Gx=function(t,e,n,i){var r,o,a=t.getData(),s=[],l=!1,u=(t.get("minShowLabelAngle")||0)*Vx;a.each(function(n){var i=a.getItemLayout(n),h=a.getItemModel(n),c=h.getModel("label"),d=c.get("position")||h.get("emphasis.label.position"),f=h.getModel("labelLine"),p=f.get("length"),g=f.get("length2");if(!(i.angle<u)){var m,v,y,x,_=(i.startAngle+i.endAngle)/2,w=Math.cos(_),b=Math.sin(_);r=i.cx,o=i.cy;var S="inside"===d||"inner"===d;if("center"===d)m=i.cx,v=i.cy,x="center";else{var M=(S?(i.r+i.r0)/2*w:i.r*w)+r,I=(S?(i.r+i.r0)/2*b:i.r*b)+o;if(m=M+3*w,v=I+3*b,!S){var C=M+w*(p+e-i.r),T=I+b*(p+e-i.r),A=C+(0>w?-1:1)*g;m=A+(0>w?-5:5),v=T,y=[[M,I],[C,T],[A,T]]}x=S?"center":w>0?"left":"right"}var D,k=c.getFont(),P=c.get("rotate");D="number"==typeof P?P*(Math.PI/180):P?0>w?-_+Math.PI:-_:0;var O=pe(t.getFormattedLabel(n,"normal")||a.getName(n),k,x,"top");l=!!D,i.label={x:m,y:v,position:d,height:O.height,len:p,len2:g,linePoints:y,textAlign:x,verticalAlign:"middle",rotation:D,inside:S},S||s.push(i.label)}}),!l&&t.get("avoidLabelOverlap")&&function(t,e,n,i,r,o){for(var a=[],s=[],l=0;l<t.length;l++)vl(t[l])||(t[l].x<e?a.push(t[l]):s.push(t[l]));for(ml(s,e,n,i,1,0,o),ml(a,e,n,i,-1,0,o),l=0;l<t.length;l++)if(!vl(t[l])){var u=t[l].linePoints;if(u){var h=u[1][0]-u[2][0];u[2][0]=t[l].x<e?t[l].x+3:t[l].x-3,u[1][1]=u[2][1]=t[l].y,u[1][0]=u[2][0]+h}}}(s,r,o,e,0,i)},Wx=2*Math.PI,Hx=Math.PI/180;Fx("pie",[{type:"pieToggleSelect",event:"pieselectchanged",method:"toggleSelected"},{type:"pieSelect",event:"pieselected",method:"select"},{type:"pieUnSelect",event:"pieunselected",method:"unSelect"}]),sa(function(t){return{getTargetSeries:function(e){var n={},i=B();return e.eachSeriesByType(t,function(t){t.__paletteScope=n,i.set(t.uid,t)}),i},reset:function(t){var e=t.getRawData(),n={},i=t.getData();i.each(function(t){var e=i.getRawIndex(t);n[e]=t}),e.each(function(r){var o,a=n[r],s=null!=a&&i.getItemVisual(a,"color",!0),l=null!=a&&i.getItemVisual(a,"borderColor",!0);if(s&&l||(o=e.getItemModel(r)),s)e.setItemVisual(r,"color",s);else{var u=o.get("itemStyle.color")||t.getColorFromPalette(e.getName(r)||r+"",t.__paletteScope,e.count());e.setItemVisual(r,"color",u),null!=a&&i.setItemVisual(a,"color",u)}if(l)e.setItemVisual(r,"borderColor",l);else{var h=o.get("itemStyle.borderColor");e.setItemVisual(r,"borderColor",h),null!=a&&i.setItemVisual(a,"borderColor",h)}})}}}("pie")),aa(y(function(t,e,n){e.eachSeriesByType(t,function(t){var e=t.getData(),i=e.mapDimension("value"),r=t.get("center"),o=t.get("radius");x(o)||(o=[0,o]),x(r)||(r=[r,r]);var a=n.getWidth(),s=n.getHeight(),l=Math.min(a,s),u=ji(r[0],a),h=ji(r[1],s),c=ji(o[0],l/2),d=ji(o[1],l/2),f=-t.get("startAngle")*Hx,p=t.get("minAngle")*Hx,g=0;e.each(i,function(t){!isNaN(t)&&g++});var m=e.getSum(i),v=Math.PI/(m||g)*2,y=t.get("clockwise"),_=t.get("roseType"),w=t.get("stillShowZeroSum"),b=e.getDataExtent(i);b[0]=0;var S=Wx,M=0,I=f,C=y?1:-1;if(e.each(i,function(t,n){var i;if(isNaN(t))e.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:y,cx:u,cy:h,r0:c,r:_?NaN:d});else{p>(i="area"!==_?0===m&&w?v:t*v:Wx/g)?(i=p,S-=p):M+=t;var r=I+C*i;e.setItemLayout(n,{angle:i,startAngle:I,endAngle:r,clockwise:y,cx:u,cy:h,r0:c,r:_?Ui(t,b,[c,d]):d}),I=r}}),Wx>S&&g)if(.001>=S){var T=Wx/g;e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n);i.angle=T,i.startAngle=f+C*n*T,i.endAngle=f+C*(n+1)*T}})}else v=S/M,I=f,e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n),r=i.angle===p?p:t*v;i.startAngle=I,i.endAngle=I+C*r,I+=C*r}});Gx(t,d,0,s)})},"pie")),ra(function(t){return{seriesType:t,reset:function(t,e){var n=e.findComponents({mainType:"legend"});if(n&&n.length){var i=t.getData();i.filterSelf(function(t){for(var e=i.getName(t),r=0;r<n.length;r++)if(!n[r].isSelected(e))return!1;return!0})}}}}("pie")),ha({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"}}}),ca({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),o=t.getModel("subtextStyle"),a=t.get("textAlign"),s=A(t.get("textBaseline"),t.get("textVerticalAlign")),l=new Ap({style:Ii({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),u=l.getBoundingRect(),h=t.get("subtext"),c=new Ap({style:Ii({},o,{text:h,textFill:o.getTextColor(),y:u.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink"),p=t.get("triggerEvent",!0);l.silent=!d&&!p,c.silent=!f&&!p,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),l.eventData=c.eventData=p?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(l),h&&i.add(c);var g=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=g.width,m.height=g.height;var v=mr(m,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));a||("middle"===(a=t.get("left")||t.get("right"))&&(a="center"),"right"===a?v.x+=v.width:"center"===a&&(v.x+=v.width/2)),s||("center"===(s=t.get("top")||t.get("bottom"))&&(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 y={textAlign:a,textVerticalAlign:s};l.setStyle(y),c.setStyle(y),g=i.getBoundingRect();var x=v.margin,_=t.getItemStyle(["color","opacity"]);_.fill=t.get("backgroundColor");var w=new Vp({shape:{x:g.x-x[3],y:g.y-x[0],width:g.width+x[1]+x[3],height:g.height+x[0]+x[2],r:t.get("borderRadius")},style:_,subPixelOptimize:!0,silent:!0});i.add(w)}}});var Zx=Pm.legend.selector,Xx={all:{type:"all",title:i(Zx.all)},inverse:{type:"inverse",title:i(Zx.inverse)}},Yx=ha({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},mergeOption:function(t){Yx.superCall(this,"mergeOption",t),this._updateSelector(t)},_updateSelector:function(t){var e=t.selector;!0===e&&(e=t.selector=["all","inverse"]),x(e)&&f(e,function(t,n){w(t)&&(t={type:t}),e[n]=r(t,Xx[t.type])})},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 o;if(i.legendDataProvider){var a=i.legendDataProvider(),s=a.mapArray(a.getName);t.isSeriesFiltered(i)||(n=n.concat(s)),s.length?e=e.concat(s):o=!0}else o=!0;o&&en(i)&&e.push(i.name)}),this._availableNames=n;var i=p(this.get("data")||e,function(t){return("string"==typeof t||"number"==typeof t)&&(t={name:t}),new Hi(t,this,this.ecModel)},this);this._data=i},getData:function(){return this._data},select:function(t){var e=this.option.selected;if("single"===this.get("selectedMode")){f(this._data,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)},allSelect:function(){var t=this._data,e=this.option.selected;f(t,function(t){e[t.get("name",!0)]=!0})},inverseSelect:function(){var t=this._data,e=this.option.selected;f(t,function(t){var n=t.get("name",!0);e.hasOwnProperty(n)||(e[n]=!0),e[n]=!e[n]})},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&u(this._availableNames,t)>=0},getOrient:function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},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",inactiveBorderColor:"#ccc",itemStyle:{borderWidth:0},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:" sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}}});oa("legendToggleSelect","legendselectchanged",y(yl,"toggleSelected")),oa("legendAllSelect","legendselectall",y(yl,"allSelect")),oa("legendInverseSelect","legendinverseselect",y(yl,"inverseSelect")),oa("legendSelect","legendselected",y(yl,"select")),oa("legendUnSelect","legendunselected",y(yl,"unSelect"));var Ux=y,jx=f,qx=yd,$x=ca({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new qx),this._backgroundEl,this.group.add(this._selectorGroup=new qx),this._isFirstRender=!0},getContentGroup:function(){return this._contentGroup},getSelectorGroup:function(){return this._selectorGroup},render:function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align"),o=t.get("orient");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===o?"right":"left");var a=t.get("selector",!0),l=t.get("selectorPosition",!0);!a||l&&"auto"!==l||(l="horizontal"===o?"end":"start"),this.renderInner(r,t,e,n,a,o,l);var u=t.getBoxLayoutParams(),h={width:n.getWidth(),height:n.getHeight()},c=t.get("padding"),d=mr(u,h,c),f=this.layoutInner(t,r,d,i,a,l),p=mr(s({width:f.width,height:f.height},u),h,c);this.group.attr("position",[p.x-f.x,p.y-f.y]),this.group.add(this._backgroundEl=xl(f,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},renderInner:function(t,e,n,i,r,o,a){var s=this.getContentGroup(),l=B(),u=e.get("selectedMode"),h=[];n.eachRawSeries(function(t){!t.get("legendHoverLink")&&h.push(t.id)}),jx(e.getData(),function(r,o){var a=r.get("name");if(this.newlineDisabled||""!==a&&"\n"!==a){var c=n.getSeriesByName(a)[0];if(!l.get(a))if(c){var d=c.getData(),f=d.getVisual("color"),p=d.getVisual("borderColor");"function"==typeof f&&(f=f(c.getDataParams(0))),"function"==typeof p&&(p=p(c.getDataParams(0)));var g=d.getVisual("legendSymbol")||"roundRect",m=d.getVisual("symbol");this._createItem(a,o,r,e,g,m,t,f,p,u).on("click",Ux(wl,a,i)).on("mouseover",Ux(bl,c.name,null,i,h)).on("mouseout",Ux(Sl,c.name,null,i,h)),l.set(a,!0)}else n.eachRawSeries(function(n){if(!l.get(a)&&n.legendDataProvider){var s=n.legendDataProvider(),c=s.indexOfName(a);if(0>c)return;var d=s.getItemVisual(c,"color"),f=s.getItemVisual(c,"borderColor");this._createItem(a,o,r,e,"roundRect",null,t,d,f,u).on("click",Ux(wl,a,i)).on("mouseover",Ux(bl,null,a,i,h)).on("mouseout",Ux(Sl,null,a,i,h)),l.set(a,!0)}},this)}else s.add(new qx({newline:!0}))},this),r&&this._createSelector(r,e,i,o,a)},_createSelector:function(t,e,n){var i=this.getSelectorGroup();jx(t,function(t){!function(t){var r=t.type,o=new Ap({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:"all"===r?"legendAllSelect":"legendInverseSelect"})}});i.add(o);var a=e.getModel("selectorLabel"),s=e.getModel("emphasis.selectorLabel");Mi(o.style,o.hoverStyle={},a,s,{defaultText:t.title,isRectText:!1}),_i(o)}(t)})},_createItem:function(t,e,n,i,r,o,s,l,u,h){var c=i.get("itemWidth"),d=i.get("itemHeight"),f=i.get("inactiveColor"),p=i.get("inactiveBorderColor"),g=i.get("symbolKeepAspect"),m=i.getModel("itemStyle"),v=i.isSelected(t),y=new qx,x=n.getModel("textStyle"),_=n.get("icon"),w=n.getModel("tooltip"),b=w.parentModel,S=as(r=_||r,0,0,c,d,v?l:f,null==g||g);if(y.add(_l(S,r,m,u,p,v)),!_&&o&&(o!==r||"none"===o)){var M=.8*d;"none"===o&&(o="circle");var I=as(o,(c-M)/2,(d-M)/2,M,M,v?l:f,null==g||g);y.add(_l(I,o,m,u,p,v))}var C="left"===s?c+5:-5,T=s,A=i.get("formatter"),D=t;"string"==typeof A&&A?D=A.replace("{name}",null!=t?t:""):"function"==typeof A&&(D=A(t)),y.add(new Ap({style:Ii({},x,{text:D,x:C,y:d/2,textFill:v?x.getTextColor():f,textAlign:T,textVerticalAlign:"middle"})}));var k=new Vp({shape:y.getBoundingRect(),invisible:!0,tooltip:w.get("show")?a({content:t,formatter:b.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},w.option):null});return y.add(k),y.eachChild(function(t){t.silent=!0}),k.silent=!h,this.getContentGroup().add(y),_i(y),y.__legendDataIndex=e,y},layoutInner:function(t,e,n,i,r,o){var a=this.getContentGroup(),s=this.getSelectorGroup();Pg(t.get("orient"),a,t.get("itemGap"),n.width,n.height);var l=a.getBoundingRect(),u=[-l.x,-l.y];if(r){Pg("horizontal",s,t.get("selectorItemGap",!0));var h=s.getBoundingRect(),c=[-h.x,-h.y],d=t.get("selectorButtonGap",!0),f=t.getOrient().index,p=0===f?"width":"height",g=0===f?"height":"width",m=0===f?"y":"x";"end"===o?c[f]+=l[p]+d:u[f]+=h[p]+d,c[1-f]+=l[g]/2-h[g]/2,s.attr("position",c),a.attr("position",u);var v={x:0,y:0};return v[p]=l[p]+d+h[p],v[g]=Math.max(l[g],h[g]),v[m]=Math.min(0,h[m]+c[1-f]),v}return a.attr("position",u),this.group.getBoundingRect()},remove:function(){this.getContentGroup().removeAll(),this._isFirstRender=!0}});ra(cv.PROCESSOR.SERIES_FILTER,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})}),zg.registerSubTypeDefaulter("legend",function(){return"plain"});var Kx=Yx.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=xr(t);Kx.superCall(this,"init",t,e,n,i),Ml(this,t,r)},mergeOption:function(t,e){Kx.superCall(this,"mergeOption",t,e),Ml(this,this.option,t)}}),Qx=yd,Jx=["width","height"],t_=["x","y"],e_=$x.extend({type:"legend.scroll",newlineDisabled:!0,init:function(){e_.superCall(this,"init"),this._currentIndex=0,this.group.add(this._containerGroup=new Qx),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new Qx),this._showController},resetInner:function(){e_.superCall(this,"resetInner"),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},renderInner:function(t,e,n,i,r,o,a){function s(t,n){var r=t+"DataIndex",o=Vi(e.get("pageIcons",!0)[e.getOrient().name][n],{onclick:v(l._pageGo,l,r,e,i)},{x:-h[0]/2,y:-h[1]/2,width:h[0],height:h[1]});o.name=t,u.add(o)}var l=this;e_.superCall(this,"renderInner",t,e,n,i,r,o,a);var u=this._controllerGroup,h=e.get("pageIconSize",!0);x(h)||(h=[h,h]),s("pagePrev",0);var c=e.getModel("pageTextStyle");u.add(new Ap({name:"pageText",style:{textFill:c.getTextColor(),font:c.getFont(),textVerticalAlign:"middle",textAlign:"center"},silent:!0})),s("pageNext",1)},layoutInner:function(t,e,n,r,o,a){var s=this.getSelectorGroup(),l=t.getOrient().index,u=Jx[l],h=t_[l],c=Jx[1-l],d=t_[1-l];o&&Pg("horizontal",s,t.get("selectorItemGap",!0));var f=t.get("selectorButtonGap",!0),p=s.getBoundingRect(),g=[-p.x,-p.y],m=i(n);o&&(m[u]=n[u]-p[u]-f);var v=this._layoutContentAndController(t,r,m,l,u,c,d);if(o){if("end"===a)g[l]+=v[u]+f;else{var y=p[u]+f;g[l]-=y,v[h]-=y}v[u]+=p[u]+f,g[1-l]+=v[d]+v[c]/2-p[c]/2,v[c]=Math.max(v[c],p[c]),v[d]=Math.min(v[d],p[d]+g[1-l]),s.attr("position",g)}return v},_layoutContentAndController:function(t,e,n,i,r,o,a){var s=this.getContentGroup(),l=this._containerGroup,u=this._controllerGroup;Pg(t.get("orient"),s,t.get("itemGap"),i?n.width:null,i?null:n.height),Pg("horizontal",u,t.get("pageButtonItemGap",!0));var h=s.getBoundingRect(),c=u.getBoundingRect(),d=this._showController=h[r]>n[r],f=[-h.x,-h.y];e||(f[i]=s.position[i]);var p=[0,0],g=[-c.x,-c.y],m=A(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){"end"===t.get("pageButtonPosition",!0)?g[i]+=n[r]-c[r]:p[i]+=c[r]+m}g[1-i]+=h[o]/2-c[o]/2,s.attr("position",f),l.attr("position",p),u.attr("position",g);var v={x:0,y:0};if(v[r]=d?n[r]:h[r],v[o]=Math.max(h[o],c[o]),v[a]=Math.min(0,c[a]+g[1-i]),l.__rectSize=n[r],d){var y={x:0,y:0};y[r]=Math.max(n[r]-c[r]-m,0),y[o]=v[o],l.setClipPath(new Vp({shape:y})),l.__rectSize=y[r]}else u.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(t);return null!=x.pageIndex&&Li(s,{position:x.contentPosition},!!d&&t),this._updatePageInfoView(t,x),v},_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"],o=n.childOfName(i);o&&(o.setStyle("fill",r?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),o.cursor=r?"pointer":"default")});var i=n.childOfName("pageText"),r=t.get("pageFormatter"),o=e.pageIndex,a=null!=o?o+1:0,s=e.pageCount;i&&r&&i.setStyle("text",w(r)?r.replace("{current}",a).replace("{total}",s):r({current:a,total:s}))},_getPageInfo:function(t){function e(t){if(t){var e=t.getBoundingRect(),n=e[l]+t.position[a];return{s:n,e:n+e[s],i:t.__legendDataIndex}}}function n(t,e){return t.e>=e&&t.s<=e+o}var i=t.get("scrollDataIndex",!0),r=this.getContentGroup(),o=this._containerGroup.__rectSize,a=t.getOrient().index,s=Jx[a],l=t_[a],u=this._findTargetItemIndex(i),h=r.children(),c=h[u],d=h.length,f=d?1:0,p={contentPosition:r.position.slice(),pageCount:f,pageIndex:f-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return p;var g=e(c);p.contentPosition[a]=-g.s;for(var m=u+1,v=g,y=g,x=null;d>=m;++m)(!(x=e(h[m]))&&y.e>v.s+o||x&&!n(x,v.s))&&(v=y.i>v.i?y:x)&&(null==p.pageNextDataIndex&&(p.pageNextDataIndex=v.i),++p.pageCount),y=x;for(var m=u-1,v=g,y=g,x=null;m>=-1;--m)(x=e(h[m]))&&n(y,x.s)||!(v.i<y.i)||(y=v,null==p.pagePrevDataIndex&&(p.pagePrevDataIndex=v.i),++p.pageCount,++p.pageIndex),v=x;return p},_findTargetItemIndex:function(t){var e,n,i=this.getContentGroup();return this._showController&&i.eachChild(function(i,r){var o=i.__legendDataIndex;null==n&&null!=o&&(n=r),o===t&&(e=r)}),null!=e?e:n}});oa("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 n_=function(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var o=n.getData(),a=rn(o,t);if(null==a||0>a||x(a))return{point:[]};var s=o.getItemGraphicEl(a),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(o.getValues(p(l.dimensions,function(t){return o.mapDimension(t)}),a,!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}},i_=f,r_=y,o_=on(),a_=(ha({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}}}),on()),s_=f,l_=ca({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";Pl("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){zl(e.getZr(),"axisPointer"),l_.superApply(this._model,"remove",arguments)},dispose:function(t,e){zl("axisPointer",e),l_.superApply(this._model,"dispose",arguments)}}),u_=on(),h_=i,c_=v;(Nl.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"),o=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==o){this._lastValue=r,this._lastStatus=o;var a=this._group,s=this._handle;if(!o||"hide"===o)return a&&a.hide(),void(s&&s.hide());a&&a.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(a){var c=y(El,e,h);this.updatePointerEl(a,l,c,e),this.updateLabelEl(a,l,c,e)}else a=this._group=new yd,this.createPointerEl(a,l,t,e),this.createLabelEl(a,l,t,e),n.getZr().add(a);Vl(a,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,o=e.get("snap");if(!o&&!r)return!1;if("auto"===n||null==n){var a=this.animationThreshold;if(r&&i.getBandWidth()>a)return!0;if(o){var s=Hs(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>a}return!1}return!0===n},makeElOption:function(){},createPointerEl:function(t,e){var n=e.pointer;if(n){var i=u_(t).pointerEl=new hg[n.type](h_(e.pointer));t.add(i)}},createLabelEl:function(t,e,n,i){if(e.label){var r=u_(t).labelEl=new Vp(h_(e.label));t.add(r),Rl(r,i)}},updatePointerEl:function(t,e,n){var i=u_(t).pointerEl;i&&e.pointer&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=u_(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),Rl(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"),o=e.get("status");if(!r.get("show")||!o||"hide"===o)return i&&n.remove(i),void(this._handle=null);var a;this._handle||(a=!0,i=this._handle=Vi(r.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){zc(t.event)},onmousedown:c_(this._onHandleDragMove,this,0,0),drift:c_(this._onHandleDragMove,this),ondragend:c_(this._onHandleDragEnd,this)}),n.add(i)),Vl(i,e,!1);i.setStyle(r.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=r.get("size");x(s)||(s=[s,s]),i.attr("scale",[s[0]/2,s[1]/2]),vo(this,"_doDispatchAxisPointer",r.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,a)}},_moveHandleToValue:function(t,e){El(this._axisPointerModel,!e&&this._moveAnimation,this._handle,Fl(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(Fl(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Fl(i)),u_(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},_onHandleDragEnd:function(){this._dragging=!1;if(this._handle){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),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]}}}).constructor=Nl,cn(Nl);var d_=Nl.extend({makeElOption:function(t,e,n,i,r){var o=n.axis,a=o.grid,s=i.get("type"),l=Zl(a,o).getOtherAxis(o).getGlobalExtent(),u=o.toGlobalCoord(o.dataToCoord(e,!0));if(s&&"none"!==s){var h=function(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}(i),c=f_[s](o,u,l);c.style=h,t.graphicKey=c.type,t.pointer=c}!function(t,e,n,i,r,o){var a=ox.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get("label.margin"),Gl(e,i,r,o,{position:Hl(i.axis,t,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}(e,t,js(a.model,n),n,i,r)},getHandleTransform:function(t,e,n){var i=js(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:Hl(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,o=i.getGlobalExtent(!0),a=Zl(r,i).getOtherAxis(i).getGlobalExtent(),s="x"===i.dim?0:1,l=t.position;l[s]+=e[s],l[s]=Math.min(o[1],l[s]),l[s]=Math.max(o[0],l[s]);var u=(a[1]+a[0])/2,h=[u,u];h[s]=l[s];return{position:l,rotation:t.rotation,cursorPoint:h,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][s]}}}),f_={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:function(t,e,n){return n=n||0,{x1:t[n],y1:t[1-n],x2:e[n],y2:e[1-n]}}([e,n[0]],[e,n[1]],Xl(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:function(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}([e-i/2,n[0]],[i,r],Xl(t))}}};dx.registerAxisPointerClass("CartesianAxisPointer",d_),ia(function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!x(e)&&(t.axisPointer.link=[e])}}),ra(cv.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=Vs(t,e)}),oa({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},function(t,e,n){var i=t.currTrigger,r=[t.x,t.y],o=t,a=t.dispatchAction||v(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){kl(r)&&(r=n_({seriesIndex:o.seriesIndex,dataIndex:o.dataIndex},e).point);var l=kl(r),u=o.axesInfo,h=s.axesInfo,c="leave"===i||kl(r),d={},f={},p={list:[],map:{}},g={showPointer:r_(Cl,f),showTooltip:r_(Tl,p)};i_(s.coordSysMap,function(t,e){var n=l||t.containPoint(r);i_(s.coordSysAxesInfo[e],function(t){var e=t.axis,i=function(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}}(u,t);if(!c&&n&&(!u||i)){var o=i&&i.value;null!=o||l||(o=e.pointToData(r)),null!=o&&Il(t,o,g,!1,d)}})});var m={};return i_(h,function(t,e){var n=t.linkGroup;n&&!f[e]&&i_(n.axesInfo,function(e,i){var r=f[i];if(e!==t&&r){var o=r.value;n.mapper&&(o=t.axis.scale.parse(n.mapper(o,Dl(e),Dl(t)))),m[t.key]=o}})}),i_(m,function(t,e){Il(h[e],t,g,!0,d)}),function(t,e,n){var i=d.axesInfo=[];i_(e,function(e,n){var r=e.axisPointerModel.option,o=t[n];o?(!e.useHandle&&(r.status="show"),r.value=o.value,r.seriesDataIndices=(o.payloadBatch||[]).slice()):!e.useHandle&&(r.status="hide"),"show"===r.status&&i.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:r.value})})}(f,h),function(t,e,n,i){if(!kl(e)&&t.list.length){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})}else i({type:"hideTip"})}(p,r,t,a),Al(h,0,n),d}}),ha({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",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 p_=f,g_=lr,m_=["","-webkit-","-moz-","-o-"];Ul.prototype={constructor:Ul,_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="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+Yl(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",e.style.pointerEvents=this._enterable?"auto":"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(v(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.el.clientWidth,e=this.el.clientHeight;if(document.defaultView&&document.defaultView.getComputedStyle){var n=document.defaultView.getComputedStyle(this.el);n&&(t+=parseInt(n.borderLeftWidth,10)+parseInt(n.borderRightWidth,10),e+=parseInt(n.borderTopWidth,10)+parseInt(n.borderBottomWidth,10))}return{width:t,height:e}}},jl.prototype={constructor:jl,_enterable:!0,update:function(){},show:function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.attr("show",!0),this._show=!0},setContent:function(t,e,n){this.el&&this._zr.remove(this.el);for(var i={},r=t,o="{marker",a=r.indexOf(o);a>=0;){var s=r.indexOf("|}"),l=r.substr(a+o.length,s-a-o.length);i["marker"+l]=l.indexOf("sub")>-1?{textWidth:4,textHeight:4,textBorderRadius:2,textBackgroundColor:e[l],textOffset:[3,0]}:{textWidth:10,textHeight:10,textBorderRadius:5,textBackgroundColor:e[l]},a=(r=r.substr(s+1)).indexOf("{marker")}this.el=new Ap({style:{rich:i,text:t,textLineHeight:20,textBackgroundColor:n.get("backgroundColor"),textBorderRadius:n.get("borderRadius"),textFill:n.get("textStyle.color"),textPadding:n.get("padding")},z:n.get("z")}),this._zr.add(this.el);var u=this;this.el.on("mouseover",function(){u._enterable&&(clearTimeout(u._hideTimeout),u._show=!0),u._inContent=!0}),this.el.on("mouseout",function(){u._enterable&&u._show&&u.hideLater(u._hideDelay),u._inContent=!1})},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el.getBoundingRect();return[t.width,t.height]},moveTo:function(t,e){this.el&&this.el.attr("position",[t,e])},hide:function(){this.el&&this.el.hide(),this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(v(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.getSize();return{width:t[0],height:t[1]}}};var v_=v,y_=f,x_=ji,__=new Vp({shape:{x:-1,y:-1,width:2,height:2}});ca({type:"tooltip",init:function(t,e){if(!ac.node){var n=t.getComponent("tooltip").get("renderMode");this._renderMode=un(n);var i;"html"===this._renderMode?(i=new Ul(e.getDom(),e),this._newLine="<br/>"):(i=new jl(e),this._newLine="\n"),this._tooltipContent=i}},render:function(t,e,n){if(!ac.node){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.get("triggerOn");Pl("itemTooltip",this._api,v_(function(e,n,i){"none"!==t&&(t.indexOf(e)>=0?this._tryShow(n,i):"leave"===e&&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(){!n.isDisposed()&&i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!ac.node){var r=$l(i,n);this._ticket="";var o=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var a=__;a.position=[i.x,i.y],a.update(),a.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:a},r)}else if(o)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=n_(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($l(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,o=i.dataIndex,a=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=o&&null!=a){var s=e.getSeriesByIndex(r);if(s){if("axis"===(t=ql([s.getData().getItemModel(o),s,(s.coordinateSystem||{}).model,t])).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:o,position:i.position}),!0}}},_tryShow:function(t,e){var n=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var i=t.dataByCoordSys;i&&i.length?this._showAxisTooltip(i,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=v(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var n=this._ecModel,i=this._tooltipModel,o=[e.offsetX,e.offsetY],a=[],s=[],l=ql([e.tooltipOption,i]),u=this._renderMode,h=this._newLine,c={};y_(t,function(t){y_(t.dataByAxis,function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),i=t.value,o=[];if(e&&null!=i){var l=Wl(i,e.axis,n,t.seriesDataIndices,t.valueLabelOpt);f(t.seriesDataIndices,function(a){var h=n.getSeriesByIndex(a.seriesIndex),d=a.dataIndexInside,f=h&&h.getDataParams(d);if(f.axisDim=t.axisDim,f.axisIndex=t.axisIndex,f.axisType=t.axisType,f.axisId=t.axisId,f.axisValue=es(e.axis,i),f.axisValueLabel=l,f){s.push(f);var p,g=h.formatTooltip(d,!0,null,u);if(b(g)){p=g.html;var m=g.markers;r(c,m)}else p=g;o.push(p)}});var d=l;a.push("html"!==u?o.join(h):(d?ur(d)+h:"")+o.join(h))}})},this),a.reverse(),a=a.join(this._newLine+this._newLine);var d=e.position;this._showOrMove(l,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(l,d,o[0],o[1],this._tooltipContent,s):this._showTooltipContent(l,a,s,Math.random(),o[0],o[1],d,void 0,c)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,o=i.getSeriesByIndex(r),a=e.dataModel||o,s=e.dataIndex,l=e.dataType,u=a.getData(),h=ql([u.getItemModel(s),a,o&&(o.coordinateSystem||{}).model,this._tooltipModel]),c=h.get("trigger");if(null==c||"item"===c){var d,f,p=a.getDataParams(s,l),g=a.formatTooltip(s,!1,l,this._renderMode);b(g)?(d=g.html,f=g.markers):(d=g,f=null);var m="item_"+a.name+"_"+s;this._showOrMove(h,function(){this._showTooltipContent(h,d,p,m,t.offsetX,t.offsetY,t.position,t.target,f)}),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){i={content:i,formatter:i}}var r=new Hi(i,this._tooltipModel,this._ecModel),o=r.get("content"),a=Math.random();this._showOrMove(r,function(){this._showTooltipContent(r,o,r.get("formatterParams")||{},a,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(t,e,n,i,r,o,a,s,l){if(this._ticket="",t.get("showContent")&&t.get("show")){var u=this._tooltipContent,h=t.get("formatter");a=a||t.get("position");var c=e;if(h&&"string"==typeof h)c=hr(h,n,!0);else if("function"==typeof h){var d=v_(function(e,i){e===this._ticket&&(u.setContent(i,l,t),this._updatePosition(t,a,r,o,u,n,s))},this);this._ticket=i,c=h(n,i,d)}u.setContent(c,l,t),u.show(t),this._updatePosition(t,a,r,o,u,n,s)}},_updatePosition:function(t,e,n,i,r,o,a){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=a&&a.getBoundingRect().clone();if(a&&d.applyTransform(a.transform),"function"==typeof e&&(e=e([n,i],o,r.el,d,{viewSize:[s,l],contentSize:u.slice()})),x(e))n=x_(e[0],s),i=x_(e[1],l);else if(b(e)){e.width=u[0],e.height=u[1];var f=mr(e,{width:s,height:l});n=f.x,i=f.y,h=null,c=null}else if("string"==typeof e&&a){n=(p=function(t,e,n){var i=n[0],r=n[1],o=0,a=0,s=e.width,l=e.height;switch(t){case"inside":o=e.x+s/2-i/2,a=e.y+l/2-r/2;break;case"top":o=e.x+s/2-i/2,a=e.y-r-5;break;case"bottom":o=e.x+s/2-i/2,a=e.y+l+5;break;case"left":o=e.x-i-5,a=e.y+l/2-r/2;break;case"right":o=e.x+s+5,a=e.y+l/2-r/2}return[o,a]}(e,d,u))[0],i=p[1]}else{n=(p=function(t,e,n,i,r,o,a){var s=n.getOuterSize(),l=s.width,u=s.height;return null!=o&&(t+l+o>i?t-=l+o:t+=o),null!=a&&(e+u+a>r?e-=u+a:e+=a),[t,e]}(n,i,r,s,l,h?null:20,c?null:20))[0],i=p[1]}if(h&&(n-=Kl(h)?u[0]/2:"right"===h?u[0]:0),c&&(i-=Kl(c)?u[1]/2:"bottom"===c?u[1]:0),t.get("confine")){var p=function(t,e,n,i,r){var o=n.getOuterSize(),a=o.width,s=o.height;return t=Math.min(t+a,i)-a,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}(n,i,r,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&&y_(e,function(e,i){var r=e.dataByAxis||{},o=(t[i]||{}).dataByAxis||[];(n&=r.length===o.length)&&y_(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)&&y_(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){ac.node||(this._tooltipContent.hide(),zl("itemTooltip",e))}}),oa({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),oa({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){});var w_=sr,b_=ur,S_=ha({type:"marker",dependencies:["series","grid","polar","geo"],init:function(t,e,n){this.mergeDefaultAndTheme(t,n),this._mergeOption(t,n,!1,!0)},isAnimationEnabled:function(){if(ac.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},mergeOption:function(t,e){this._mergeOption(t,e,!1,!1)},_mergeOption:function(t,e,n,i){var r=this.constructor,o=this.mainType+"Model";n||e.eachSeries(function(t){var n=t.get(this.mainType,!0),s=t[o];return n&&n.data?(s?s._mergeOption(n,e,!0):(i&&Ql(n),f(n.data,function(t){t instanceof Array?(Ql(t[0]),Ql(t[1])):Ql(t)}),s=new r(n,this,e),a(s,{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),s.__hostSeries=t),void(t[o]=s)):void(t[o]=null)},this)},formatTooltip:function(t){var e=this.getData(),n=this.getRawValue(t),i=x(n)?p(n,w_).join(", "):w_(n),r=e.getName(t),o=b_(this.name);return(null!=n||r)&&(o+="<br />"),r&&(o+=b_(r),null!=n&&(o+=" : ")),null!=n&&(o+=b_(i)),o},getData:function(){return this._data},setData:function(t){this._data=t}});c(S_,gm),S_.extend({type:"markPoint",defaultOption:{zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}}});var M_=u,I_=y,C_={min:I_(Jl,"min"),max:I_(Jl,"max"),average:I_(Jl,"average")},T_=ca({type:"marker",init:function(){this.markerGroupMap=B()},render:function(t,e,n){var i=this.markerGroupMap;i.each(function(t){t.__keep=!1});var r=this.type+"Model";e.eachSeries(function(t){var i=t[r];i&&this.renderSeries(t,i,e,n)},this),i.each(function(t){!t.__keep&&this.group.remove(t.group)},this)},renderSeries:function(){}});T_.extend({type:"markPoint",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markPointModel;e&&(ou(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout(e))},this)},renderSeries:function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,new Qs),u=au(r,t,e);e.setData(u),ou(e.getData(),t,i),u.each(function(t){var n=u.getItemModel(t),i=n.getShallow("symbol"),r=n.getShallow("symbolSize"),o=_(i),s=_(r);if(o||s){var l=e.getRawValue(t),h=e.getDataParams(t);o&&(i=i(l,h)),s&&(r=r(l,h))}u.setItemVisual(t,{symbol:i,symbolSize:r,color:n.get("itemStyle.color")||a.getVisual("color")})}),l.updateData(u),this.group.add(l.group),u.eachItemGraphicEl(function(t){t.traverse(function(t){t.dataModel=e})}),l.__keep=!0,l.group.silent=e.get("silent")||t.get("silent")}}),ia(function(t){t.markPoint=t.markPoint||{}}),S_.extend({type:"markLine",defaultOption:{zlevel:0,z:5,symbol:["circle","arrow"],symbolSize:[8,16],precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end"},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"}});var A_=Wp.prototype,D_=Zp.prototype,k_=ni({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){this[su(e)?"_buildPathLine":"_buildPathCurve"](t,e)},_buildPathLine:A_.buildPath,_buildPathCurve:D_.buildPath,pointAt:function(t){return this[su(this.shape)?"_pointAtLine":"_pointAtCurve"](t)},_pointAtLine:A_.pointAt,_pointAtCurve:D_.pointAt,tangentAt:function(t){var e=this.shape,n=su(e)?[e.x2-e.x1,e.y2-e.y1]:this._tangentAtCurve(t);return j(n,n)},_tangentAtCurve:D_.tangentAt}),P_=["fromSymbol","toSymbol"],O_=cu.prototype;O_.beforeUpdate=function(){var t=this,e=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),i=t.childOfName("label");if(e||n||!i.ignore){for(var r=1,o=this.parent;o;)o.scale&&(r/=o.scale[0]),o=o.parent;var a=t.childOfName("line");if(this.__dirty||a.__dirty){var s=a.shape.percent,l=a.pointAt(0),u=a.pointAt(s),h=Z([],u,l);if(j(h,h),e&&(e.attr("position",l),g=a.tangentAt(0),e.attr("rotation",Math.PI/2-Math.atan2(g[1],g[0])),e.attr("scale",[r*s,r*s])),n&&(n.attr("position",u),g=a.tangentAt(1),n.attr("rotation",-Math.PI/2-Math.atan2(g[1],g[0])),n.attr("scale",[r*s,r*s])),!i.ignore){i.attr("position",u);var c,d,f,p=5*r;if("end"===i.__position)c=[h[0]*p+u[0],h[1]*p+u[1]],d=h[0]>.8?"left":h[0]<-.8?"right":"center",f=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";else if("middle"===i.__position){var g,m=s/2,v=[(g=a.tangentAt(m))[1],-g[0]],y=a.pointAt(m);v[1]>0&&(v[0]=-v[0],v[1]=-v[1]),c=[y[0]+v[0]*p,y[1]+v[1]*p],d="center",f="bottom";var x=-Math.atan2(g[1],g[0]);u[0]<l[0]&&(x=Math.PI+x),i.attr("rotation",x)}else c=[-h[0]*p+l[0],-h[1]*p+l[1]],d=h[0]>.8?"right":h[0]<-.8?"left":"center",f=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";i.attr({style:{textVerticalAlign:i.__verticalAlign||f,textAlign:i.__textAlign||d},position:c,scale:[r,r]})}}}},O_._createLine=function(t,e,n){var i=t.hostModel,r=function(t){var e=new k_({name:"line",subPixelOptimize:!0});return hu(e.shape,t),e}(t.getItemLayout(e));r.shape.percent=0,zi(r,{shape:{percent:1}},i,e),this.add(r);var o=new Ap({name:"label",lineLabelOriginalOpacity:1});this.add(o),f(P_,function(n){var i=uu(n,t,e);this.add(i),this[lu(n)]=t.getItemVisual(e,n)},this),this._updateCommonStl(t,e,n)},O_.updateData=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),o=t.getItemLayout(e),a={shape:{}};hu(a.shape,o),Li(r,a,i,e),f(P_,function(n){var i=t.getItemVisual(e,n),r=lu(n);if(this[r]!==i){this.remove(this.childOfName(n));var o=uu(n,t,e);this.add(o)}this[r]=i},this),this._updateCommonStl(t,e,n)},O_._updateCommonStl=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),o=n&&n.lineStyle,a=n&&n.hoverLineStyle,l=n&&n.labelModel,u=n&&n.hoverLabelModel;if(!n||t.hasItemOption){var h=t.getItemModel(e);o=h.getModel("lineStyle").getLineStyle(),a=h.getModel("emphasis.lineStyle").getLineStyle(),l=h.getModel("label"),u=h.getModel("emphasis.label")}var c=t.getItemVisual(e,"color"),d=D(t.getItemVisual(e,"opacity"),o.opacity,1);r.useStyle(s({strokeNoScale:!0,fill:"none",stroke:c,opacity:d},o)),r.hoverStyle=a,f(P_,function(t){var e=this.childOfName(t);e&&(e.setColor(c),e.setStyle({opacity:d}))},this);var p,g,m=l.getShallow("show"),v=u.getShallow("show"),y=this.childOfName("label");if((m||v)&&(p=c||"#000",null==(g=i.getFormattedLabel(e,"normal",t.dataType)))){var x=i.getRawValue(e);g=null==x?t.getName(e):isFinite(x)?qi(x):x}var _=m?g:null,w=v?A(i.getFormattedLabel(e,"emphasis",t.dataType),g):null,b=y.style;(null!=_||null!=w)&&(Ii(y.style,l,{text:_},{autoColor:p}),y.__textAlign=b.textAlign,y.__verticalAlign=b.textVerticalAlign,y.__position=l.get("position")||"middle"),y.hoverStyle=null!=w?{text:w,textFill:u.getTextColor(!0),fontStyle:u.getShallow("fontStyle"),fontWeight:u.getShallow("fontWeight"),fontSize:u.getShallow("fontSize"),fontFamily:u.getShallow("fontFamily")}:{text:null},y.ignore=!m&&!v,_i(this)},O_.highlight=function(){this.trigger("emphasis")},O_.downplay=function(){this.trigger("normal")},O_.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},O_.setLinePoints=function(t){var e=this.childOfName("line");hu(e.shape,t),e.dirty()},h(cu,yd);var L_=du.prototype;L_.isPersistent=function(){return!0},L_.updateData=function(t){var e=this,n=e.group,i=e._lineData;e._lineData=t,i||n.removeAll();var r=fu(t);t.diff(i).add(function(n){!function(t,e,n,i){if(gu(e.getItemLayout(n))){var r=new t._ctor(e,n,i);e.setItemGraphicEl(n,r),t.group.add(r)}}(e,t,n,r)}).update(function(n,o){!function(t,e,n,i,r,o){var a=e.getItemGraphicEl(i);gu(n.getItemLayout(r))?(a?a.updateData(n,r,o):a=new t._ctor(n,r,o),n.setItemGraphicEl(r,a),t.group.add(a)):t.group.remove(a)}(e,i,t,o,n,r)}).remove(function(t){n.remove(i.getItemGraphicEl(t))}).execute()},L_.updateLayout=function(){var t=this._lineData;t&&t.eachItemGraphicEl(function(e,n){e.updateLayout(t,n)},this)},L_.incrementalPrepareUpdate=function(t){this._seriesScope=fu(t),this._lineData=null,this.group.removeAll()},L_.incrementalUpdate=function(t,e){function n(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}for(var i=t.start;i<t.end;i++){if(gu(e.getItemLayout(i))){var r=new this._ctor(e,i,this._seriesScope);r.traverse(n),this.group.add(r),e.setItemGraphicEl(i,r)}}},L_.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},L_._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()};var z_=function(t,e,n,o){var s=t.getData(),l=o.type;if(!x(o)&&("min"===l||"max"===l||"average"===l||"median"===l||null!=o.xAxis||null!=o.yAxis)){var u,h;if(null!=o.yAxis||null!=o.xAxis)u=e.getAxis(null!=o.yAxis?"y":"x"),h=T(o.yAxis,o.xAxis);else{var c=eu(o,s,e,t);u=c.valueAxis;h=ru(s,La(s,c.valueDataDim),l)}var d="x"===u.dim?0:1,f=1-d,p=i(o),g={};p.type=null,p.coord=[],g.coord=[],p.coord[f]=-1/0,g.coord[f]=1/0;var m=n.get("precision");m>=0&&"number"==typeof h&&(h=+h.toFixed(Math.min(m,20))),p.coord[d]=g.coord[d]=h,o=[p,g,{type:l,valueIndex:o.valueIndex,value:h}]}return o=[tu(t,o[0]),tu(t,o[1]),a({},o[2])],o[2].type=o[2].type||"",r(o[2],o[0]),r(o[2],o[1]),o};T_.extend({type:"markLine",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markLineModel;if(e){var i=e.getData(),r=e.__from,o=e.__to;r.each(function(e){xu(r,e,!0,t,n),xu(o,e,!1,t,n)}),i.each(function(t){i.setItemLayout(t,[r.getItemLayout(t),o.getItemLayout(t)])}),this.markerGroupMap.get(t.id).updateLayout()}},this)},renderSeries:function(t,e,n,i){function r(e,n,r){var o=e.getItemModel(n);xu(e,n,r,t,i),e.setItemVisual(n,{symbolSize:o.get("symbolSize")||g[r?0:1],symbol:o.get("symbol",!0)||p[r?0:1],color:o.get("itemStyle.color")||s.getVisual("color")})}var o=t.coordinateSystem,a=t.id,s=t.getData(),l=this.markerGroupMap,u=l.get(a)||l.set(a,new du);this.group.add(u.group);var h=_u(o,t,e),c=h.from,d=h.to,f=h.line;e.__from=c,e.__to=d,e.setData(f);var p=e.get("symbol"),g=e.get("symbolSize");x(p)||(p=[p,p]),"number"==typeof g&&(g=[g,g]),h.from.each(function(t){r(c,t,!0),r(d,t,!1)}),f.each(function(t){var e=f.getItemModel(t).get("lineStyle.color");f.setItemVisual(t,{color:e||c.getItemVisual(t,"color")}),f.setItemLayout(t,[c.getItemLayout(t),d.getItemLayout(t)]),f.setItemVisual(t,{fromSymbolSize:c.getItemVisual(t,"symbolSize"),fromSymbol:c.getItemVisual(t,"symbol"),toSymbolSize:d.getItemVisual(t,"symbolSize"),toSymbol:d.getItemVisual(t,"symbol")})}),u.updateData(f),h.line.eachItemGraphicEl(function(t){t.traverse(function(t){t.dataModel=e})}),u.__keep=!0,u.group.silent=e.get("silent")||t.get("silent")}}),ia(function(t){t.markLine=t.markLine||{}}),S_.extend({type:"markArea",defaultOption:{zlevel:0,z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}}});var N_=function(t,e,n,i){var r=tu(t,i[0]),a=tu(t,i[1]),s=T,l=r.coord,u=a.coord;l[0]=s(l[0],-1/0),l[1]=s(l[1],-1/0),u[0]=s(u[0],1/0),u[1]=s(u[1],1/0);var h=o([{},r,a]);return h.coord=[r.coord,a.coord],h.x0=r.x,h.y0=r.y,h.x1=a.x,h.y1=a.y,h},E_=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]];T_.extend({type:"markArea",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markAreaModel;if(e){var i=e.getData();i.each(function(e){var r=p(E_,function(r){return Mu(i,e,r,t,n)});i.setItemLayout(e,r);i.getItemGraphicEl(e).setShape("points",r)})}},this)},renderSeries:function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),l=this.markerGroupMap,u=l.get(o)||l.set(o,{group:new yd});this.group.add(u.group),u.__keep=!0;var h=function(t,e,n){var i,r;t?(i=p(t&&t.dimensions,function(t){var n=e.getData();return s({name:t},n.getDimensionInfo(n.mapDimension(t))||{})}),r=new Hv(p(["x0","y0","x1","y1"],function(t,e){return{name:t,type:i[e%2].type}}),n)):(i=[{name:"value",type:"float"}],r=new Hv(i,n));var o=p(n.get("data"),y(N_,e,t,n));t&&(o=m(o,y(Su,t)));var a=t?function(t,e,n,i){return t.coord[Math.floor(i/2)][i%2]}:function(t){return t.value};return r.initData(o,null,a),r.hasItemOption=!0,r}(r,t,e);e.setData(h),h.each(function(e){h.setItemLayout(e,p(E_,function(n){return Mu(h,e,n,t,i)})),h.setItemVisual(e,{color:a.getVisual("color")})}),h.diff(u.__data).add(function(t){var e=new Ep({shape:{points:h.getItemLayout(t)}});h.setItemGraphicEl(t,e),u.group.add(e)}).update(function(t,n){var i=u.__data.getItemGraphicEl(n);Li(i,{shape:{points:h.getItemLayout(t)}},e,t),u.group.add(i),h.setItemGraphicEl(t,i)}).remove(function(t){var e=u.__data.getItemGraphicEl(t);u.group.remove(e)}).execute(),h.eachItemGraphicEl(function(t,n){var i=h.getItemModel(n),r=i.getModel("label"),o=i.getModel("emphasis.label"),a=h.getItemVisual(n,"color");t.useStyle(s(i.getModel("itemStyle").getItemStyle(),{fill:Ft(a,.4),stroke:a})),t.hoverStyle=i.getModel("emphasis.itemStyle").getItemStyle(),Mi(t.style,t.hoverStyle,r,o,{labelFetcher:e,labelDataIndex:n,defaultText:h.getName(n)||"",isRectText:!0,autoColor:a}),_i(t,{}),t.dataModel=e}),u.__data=h,u.group.silent=e.get("silent")||t.get("silent")}}),ia(function(t){t.markArea=t.markArea||{}});zg.registerSubTypeDefaulter("timeline",function(){return"slider"}),oa({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(t,e){var n=e.getComponent("timeline");return n&&null!=t.currentIndex&&(n.setCurrentIndex(t.currentIndex),!n.get("loop",!0)&&n.isIndexMax()&&n.setPlayState(!1)),e.resetOption("timeline"),s({currentIndex:n.option.currentIndex},t)}),oa({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(t,e){var n=e.getComponent("timeline");n&&null!=t.playState&&n.setPlayState(t.playState)});var B_=zg.extend({type:"timeline",layoutMode:"box",defaultOption:{zlevel:0,z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},init:function(t,e,n){this._data,this._names,this.mergeDefaultAndTheme(t,n),this._initData()},mergeOption:function(){B_.superApply(this,"mergeOption",arguments),this._initData()},setCurrentIndex:function(t){null==t&&(t=this.option.currentIndex);var e=this._data.count();this.option.loop?t=(t%e+e)%e:(t>=e&&(t=e-1),0>t&&(t=0)),this.option.currentIndex=t},getCurrentIndex:function(){return this.option.currentIndex},isIndexMax:function(){return this.getCurrentIndex()>=this._data.count()-1},setPlayState:function(t){this.option.autoPlay=!!t},getPlayState:function(){return!!this.option.autoPlay},_initData:function(){var t=this.option,e=t.data||[],n=t.axisType,r=this._names=[];if("category"===n){var o=[];f(e,function(t,e){var n,a=Qe(t);b(t)?(n=i(t),n.value=e):n=e,o.push(n),w(a)||null!=a&&!isNaN(a)||(a=""),r.push(a+"")}),e=o}var a={category:"ordinal",time:"time"}[n]||"number";(this._data=new Hv([{name:"value",type:a}],this)).initData(e,r)},getData:function(){return this._data},getCategories:function(){return"category"===this.get("axisType")?this._names.slice():void 0}});c(B_.extend({type:"timeline.slider",defaultOption:{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"emptyCircle",symbolSize:10,lineStyle:{show:!0,width:2,color:"#304654"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#304654"},itemStyle:{color:"#304654",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:13,color:"#c23531",borderWidth:5,borderColor:"rgba(194,53,49, 0.5)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:22,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"path://M18.6,50.8l22.5-22.5c0.2-0.2,0.3-0.4,0.3-0.7c0-0.3-0.1-0.5-0.3-0.7L18.7,4.4c-0.1-0.1-0.2-0.3-0.2-0.5 c0-0.4,0.3-0.8,0.8-0.8c0.2,0,0.5,0.1,0.6,0.3l23.5,23.5l0,0c0.2,0.2,0.3,0.4,0.3,0.7c0,0.3-0.1,0.5-0.3,0.7l-0.1,0.1L19.7,52 c-0.1,0.1-0.3,0.2-0.5,0.2c-0.4,0-0.8-0.3-0.8-0.8C18.4,51.2,18.5,51,18.6,50.8z",prevIcon:"path://M43,52.8L20.4,30.3c-0.2-0.2-0.3-0.4-0.3-0.7c0-0.3,0.1-0.5,0.3-0.7L42.9,6.4c0.1-0.1,0.2-0.3,0.2-0.5 c0-0.4-0.3-0.8-0.8-0.8c-0.2,0-0.5,0.1-0.6,0.3L18.3,28.8l0,0c-0.2,0.2-0.3,0.4-0.3,0.7c0,0.3,0.1,0.5,0.3,0.7l0.1,0.1L41.9,54 c0.1,0.1,0.3,0.2,0.5,0.2c0.4,0,0.8-0.3,0.8-0.8C43.2,53.2,43.1,53,43,52.8z",color:"#304654",borderColor:"#304654",borderWidth:1},emphasis:{label:{show:!0,color:"#c23531"},itemStyle:{color:"#c23531"},controlStyle:{color:"#c23531",borderColor:"#c23531",borderWidth:2}},data:[]}}),gm);var R_=_m.extend({type:"timeline"}),F_=function(t,e,n,i){Oy.call(this,t,e,n),this.type=i||"value",this.model=null};F_.prototype={constructor:F_,getLabelModel:function(){return this.model.getModel("label")},isHorizontal:function(){return"horizontal"===this.model.get("orient")}},h(F_,Oy);var V_=v,G_=f,W_=Math.PI;R_.extend({type:"timeline.slider",init:function(t,e){this.api=e,this._axis,this._viewRect,this._timer,this._currentPointer,this._mainGroup,this._labelGroup},render:function(t,e,n){if(this.model=t,this.api=n,this.ecModel=e,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,n),r=this._createGroup("mainGroup"),o=this._createGroup("labelGroup"),a=this._axis=this._createAxis(i,t);t.formatTooltip=function(t){return ur(a.scale.getLabel(t))},G_(["AxisLine","AxisTick","Control","CurrentPointer"],function(e){this["_render"+e](i,r,a,t)},this),this._renderAxisLabel(i,o,a,t),this._position(i,t)}this._doPlayStop()},remove:function(){this._clearTimer(),this.group.removeAll()},dispose:function(){this._clearTimer()},_layout:function(t,e){var n=t.get("label.position"),i=t.get("orient"),r=function(t,e){return mr(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},t.get("padding"))}(t,e);null==n||"auto"===n?n="horizontal"===i?r.y+r.height/2<e.getHeight()/2?"-":"+":r.x+r.width/2<e.getWidth()/2?"+":"-":isNaN(n)&&(n={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[i][n]);var o={horizontal:"center",vertical:n>=0||"+"===n?"left":"right"},a={horizontal:n>=0||"+"===n?"top":"bottom",vertical:"middle"},s={horizontal:0,vertical:W_/2},l="vertical"===i?r.height:r.width,u=t.getModel("controlStyle"),h=u.get("show",!0),c=h?u.get("itemSize"):0,d=h?u.get("itemGap"):0,f=c+d,p=t.get("label.rotate")||0;p=p*W_/180;var g,m,v,y,x=u.get("position",!0),_=h&&u.get("showPlayBtn",!0),w=h&&u.get("showPrevBtn",!0),b=h&&u.get("showNextBtn",!0),S=0,M=l;return"left"===x||"bottom"===x?(_&&(g=[0,0],S+=f),w&&(m=[S,0],S+=f),b&&(v=[M-c,0],M-=f)):(_&&(g=[M-c,0],M-=f),w&&(m=[0,0],S+=f),b&&(v=[M-c,0],M-=f)),y=[S,M],t.get("inverse")&&y.reverse(),{viewRect:r,mainLength:l,orient:i,rotation:s[i],labelRotation:p,labelPosOpt:n,labelAlign:t.get("label.align")||o[i],labelBaseline:t.get("label.verticalAlign")||t.get("label.baseline")||a[i],playPosition:g,prevBtnPosition:m,nextBtnPosition:v,axisExtent:y,controlSize:c,controlGap:d}},_position:function(t){function e(t){var e=t.position;t.origin=[h[0][0]-e[0],h[1][0]-e[1]]}function n(t){return[[t.x,t.x+t.width],[t.y,t.y+t.height]]}function i(t,e,n,i,r){t[i]+=n[i][r]-e[i][r]}var r=this._mainGroup,o=this._labelGroup,a=t.viewRect;if("vertical"===t.orient){var s=pt(),l=a.x,u=a.y+a.height;yt(s,s,[-l,-u]),xt(s,s,-W_/2),yt(s,s,[l,u]),(a=a.clone()).applyTransform(s)}var h=n(a),c=n(r.getBoundingRect()),d=n(o.getBoundingRect()),f=r.position,p=o.position;p[0]=f[0]=h[0][0];var g=t.labelPosOpt;if(isNaN(g)){i(f,c,h,1,m="+"===g?0:1),i(p,d,h,1,1-m)}else{var m=g>=0?0:1;i(f,c,h,1,m),p[1]=f[1]+g}r.attr("position",f),o.attr("position",p),r.rotation=o.rotation=t.rotation,e(r),e(o)},_createAxis:function(t,e){var n=e.getData(),i=e.get("axisType"),r=Ja(e,i);r.getTicks=function(){return n.mapArray(["value"],function(t){return t})};var o=n.getDataExtent("value");r.setExtent(o[0],o[1]),r.niceTicks();var a=new F_("value",r,t.axisExtent,i);return a.model=e,a},_createGroup:function(t){var e=this["_"+t]=new yd;return this.group.add(e),e},_renderAxisLine:function(t,e,n,i){var r=n.getExtent();i.get("lineStyle.show")&&e.add(new Wp({shape:{x1:r[0],y1:0,x2:r[1],y2:0},style:a({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1}))},_renderAxisTick:function(t,e,n,i){var r=i.getData(),o=n.scale.getTicks();G_(o,function(t){var o=n.dataToCoord(t),a=r.getItemModel(t),s=a.getModel("itemStyle"),l=a.getModel("emphasis.itemStyle"),u={position:[o,0],onclick:V_(this._changeTimeline,this,t)},h=Au(a,s,e,u);_i(h,l.getItemStyle()),a.get("tooltip")?(h.dataIndex=t,h.dataModel=i):h.dataIndex=h.dataModel=null},this)},_renderAxisLabel:function(t,e,n,i){if(n.getLabelModel().get("show")){var r=i.getData(),o=n.getViewLabels();G_(o,function(i){var o=i.tickValue,a=r.getItemModel(o),s=a.getModel("label"),l=a.getModel("emphasis.label"),u=n.dataToCoord(i.tickValue),h=new Ap({position:[u,0],rotation:t.labelRotation-t.rotation,onclick:V_(this._changeTimeline,this,o),silent:!1});Ii(h.style,s,{text:i.formattedLabel,textAlign:t.labelAlign,textVerticalAlign:t.labelBaseline}),e.add(h),_i(h,Ii({},l))},this)}},_renderControl:function(t,e,n,i){function r(t,n,r,h){if(t){var c=Tu(i,n,u,{position:t,origin:[o/2,0],rotation:h?-a:0,rectHover:!0,style:s,onclick:r});e.add(c),_i(c,l)}}var o=t.controlSize,a=t.rotation,s=i.getModel("controlStyle").getItemStyle(),l=i.getModel("emphasis.controlStyle").getItemStyle(),u=[0,-o/2,o,o],h=i.getPlayState(),c=i.get("inverse",!0);r(t.nextBtnPosition,"controlStyle.nextIcon",V_(this._changeTimeline,this,c?"-":"+")),r(t.prevBtnPosition,"controlStyle.prevIcon",V_(this._changeTimeline,this,c?"+":"-")),r(t.playPosition,"controlStyle."+(h?"stopIcon":"playIcon"),V_(this._handlePlayClick,this,!h),!0)},_renderCurrentPointer:function(t,e,n,i){var r=i.getData(),o=i.getCurrentIndex(),a=r.getItemModel(o).getModel("checkpointStyle"),s=this,l={onCreate:function(t){t.draggable=!0,t.drift=V_(s._handlePointerDrag,s),t.ondragend=V_(s._handlePointerDragend,s),Du(t,o,n,i,!0)},onUpdate:function(t){Du(t,o,n,i)}};this._currentPointer=Au(a,a,this._mainGroup,{},this._currentPointer,l)},_handlePlayClick:function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},_handlePointerDrag:function(t,e,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},_handlePointerDragend:function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},_pointerChangeTimeline:function(t,e){var n=this._toAxisCoord(t)[0],i=$i(this._axis.getExtent().slice());n>i[1]&&(n=i[1]),n<i[0]&&(n=i[0]),this._currentPointer.position[0]=n,this._currentPointer.dirty();var r=this._findNearestTick(n),o=this.model;(e||r!==o.getCurrentIndex()&&o.get("realtime"))&&this._changeTimeline(r)},_doPlayStop:function(){this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(V_(function(){var t=this.model;this._changeTimeline(t.getCurrentIndex()+(t.get("rewind",!0)?-1:1))},this),this.model.get("playInterval")))},_toAxisCoord:function(t){return Ei(t,this._mainGroup.getLocalTransform(),!0)},_findNearestTick:function(t){var e,n=this.model.getData(),i=1/0,r=this._axis;return n.each(["value"],function(n,o){var a=r.dataToCoord(n),s=Math.abs(a-t);i>s&&(i=s,e=o)}),e},_clearTimer:function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},_changeTimeline:function(t){var e=this.model.getCurrentIndex();"+"===t?t=e+1:"-"===t&&(t=e-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})}}),ia(function(t){var e=t&&t.timeline;x(e)||(e=e?[e]:[]),f(e,function(t){t&&function(t){var e=t.type,n={number:"value",time:"time"};if(n[e]&&(t.axisType=n[e],delete t.type),Iu(t),Cu(t,"controlPosition")){var i=t.controlStyle||(t.controlStyle={});Cu(i,"position")||(i.position=t.controlPosition),"none"!==i.position||Cu(i,"show")||(i.show=!1,delete i.position),delete t.controlPosition}f(t.data||[],function(t){b(t)&&!x(t)&&(!Cu(t,"value")&&Cu(t,"name")&&(t.value=t.name),Iu(t))})}(t)})}),zg.registerSubTypeDefaulter("dataZoom",function(){return"slider"});var H_=["cartesian2d","polar","singleAxis"],Z_=function(t,e){var n=p(t=t.slice(),pr),i=p(e=(e||[]).slice(),pr);return function(r,o){f(t,function(t,a){for(var s={name:t,capital:n[a]},l=0;l<e.length;l++)s[e[l]]=t+i[l];r.call(o,s)})}}(["x","y","z","radius","angle","single"],["axisIndex","axis","index","id"]),X_=function(t,e,n,i,r,o){t=t||0;var a=n[1]-n[0];if(null!=r&&(r=Ou(r,[0,a])),null!=o&&(o=Math.max(o,null!=r?r:0)),"all"===i){var s=Math.abs(e[1]-e[0]);r=o=Ou(s=Ou(s,[0,a]),[r,o]),i=0}e[0]=Ou(e[0],n),e[1]=Ou(e[1],n);var l=Pu(e,i);e[i]+=t;var u=r||0,h=n.slice();l.sign<0?h[0]+=u:h[1]-=u,e[i]=Ou(e[i],h);c=Pu(e,i);null!=r&&(c.sign!==l.sign||c.span<r)&&(e[1-i]=e[i]+l.sign*r);var c=Pu(e,i);return null!=o&&c.span>o&&(e[1-i]=e[i]+c.sign*o),e},Y_=f,U_=$i,j_=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};j_.prototype={constructor:j_,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(function(t){return u(H_,t)>=0}(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();"x"===n||"y"===n?(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){function e(t,e,n,i,o){var a=o?"Span":"ValueSpan";X_(0,t,n,"all",u["min"+a],u["max"+a]);for(var s=0;2>s;s++)e[s]=Ui(t[s],n,i,!0),o&&(e[s]=r.parse(e[s]))}var n,i=this._dataExtent,r=this.getAxisModel().axis.scale,o=this._dataZoomModel.getRangePropMode(),a=[0,100],s=[],l=[];Y_(["start","end"],function(e,u){var h=t[e],c=t[e+"Value"];"percent"===o[u]?(null==h&&(h=a[u]),c=r.parse(Ui(h,a,i))):(n=!0,c=null==c?i[u]:r.parse(c),h=Ui(c,i,a)),l[u]=c,s[u]=h}),U_(l),U_(s);var u=this._minMaxSpan;return n?e(l,s,i,a,!1):e(s,l,a,i,!0),{valueWindow:l,percentWindow:s}},reset:function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=function(t,e,n){var i=[1/0,-1/0];return Y_(n,function(t){var n=t.getData();n&&Y_(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=[NaN,NaN]),function(t,e){var n=t.getAxisModel(),i=n.getMin(!0),r="category"===n.get("type"),o=r&&n.getCategories().length;null!=i&&"dataMin"!==i&&"function"!=typeof i?e[0]=i:r&&(e[0]=o>0?0:NaN);var a=n.getMax(!0);null!=a&&"dataMax"!==a&&"function"!=typeof a?e[1]=a:r&&(e[1]=o>0?o-1:NaN),n.get("scale",!0)||(e[0]>0&&(e[0]=0),e[1]<0&&(e[1]=0))}(t,i),i}(this,this._dimName,e),function(t){var e=t._minMaxSpan={},n=t._dataZoomModel,i=t._dataExtent;Y_(["min","max"],function(r){var o=n.get(r+"Span"),a=n.get(r+"ValueSpan");null!=a&&(a=t.getAxisModel().axis.scale.parse(a)),null!=a?o=Ui(i[0]+a,i,[0,100],!0):null!=o&&(a=Ui(o,[0,100],i,!0)-i[0]),e[r+"Span"]=o,e[r+"ValueSpan"]=a})}(this);var n=this.calculateDataWindow(t.settledOption);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,Lu(this)}},restore:function(t){t===this._dataZoomModel&&(this._valueWindow=this._percentWindow=null,Lu(this,!0))},filterData:function(t){if(t===this._dataZoomModel){var e=this._dimName,n=this.getTargetSeriesModels(),i=t.get("filterMode"),r=this._valueWindow;"none"!==i&&Y_(n,function(t){var n=t.getData(),o=n.mapDimension(e,!0);o.length&&("weakFilter"===i?n.filterSelf(function(t){for(var e,i,a,s=0;s<o.length;s++){var l=n.get(o[s],t),u=!isNaN(l),h=l<r[0],c=l>r[1];if(u&&!h&&!c)return!0;u&&(a=!0),h&&(e=!0),c&&(i=!0)}return a&&e&&i}):Y_(o,function(e){if("empty"===i)t.setData(n=n.map(e,function(t){return function(t){return t>=r[0]&&t<=r[1]}(t)?t:NaN}));else{var o={};o[e]=r,n.selectRange(o)}}),Y_(o,function(t){n.setApproximateExtent(r,t)}))})}}};var q_=f,$_=Z_,K_=ha({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=zu(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this.doInit(i)},mergeOption:function(t){var e=zu(t);r(this.option,t,!0),r(this.settledOption,e,!0),this.doInit(e)},doInit:function(t){var e=this.option;ac.canvasSupported||(e.realtime=!1),this._setDefaultThrottle(t),Nu(this,t);var n=this.settledOption;q_([["start","startValue"],["end","endValue"]],function(t,i){"value"===this._rangePropMode[i]&&(e[t[0]]=n[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 o=this.dependentModels[e.axis][n],a=o.__dzAxisProxy||(o.__dzAxisProxy=new j_(e.name,n,this,r));t[e.name+"_"+n]=a},this)},_resetTarget:function(){var t=this.option,e=this._judgeAutoMode();$_(function(e){var n=e.axisIndex;t[n]=$e(t[n])},this),"axisIndex"===e?this._autoSetAxisIndex():"orient"===e&&this._autoSetOrient()},_judgeAutoMode:function(){var t=this.option,e=!1;$_(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):q_(i.singleAxis,function(i){t&&i.get("orient",!0)===e&&(n.singleAxisIndex=[i.componentIndex],t=!1)})}t&&$_(function(e){if(t){var i=[],r=this.dependentModels[e.axis];if(r.length&&!i.length)for(var o=0,a=r.length;a>o;o++)"category"===r[o].get("type")&&i.push(o);n[e.axisIndex]=i,i.length&&(t=!1)}},this),t&&this.ecModel.eachSeries(function(t){this._isSeriesHasAllAxesTypeOf(t,"value")&&$_(function(e){var i=n[e.axisIndex],r=t.get(e.axisIndex),o=t.get(e.axisId);u(i,r=t.ecModel.queryComponents({mainType:e.axis,index:r,id:o})[0].componentIndex)<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 $_(function(i){var r=t.get(i.axisIndex),o=this.dependentModels[i.axis][r];o&&o.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 $_(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;$_(function(i){q_(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){var e=this.option,n=this.settledOption;q_([["start","startValue"],["end","endValue"]],function(i){(null!=t[i[0]]||null!=t[i[1]])&&(e[i[0]]=n[i[0]]=t[i[0]],e[i[1]]=n[i[1]]=t[i[1]])},this),Nu(this,t)},setCalculatedRange:function(t){var e=this.option;q_(["start","startValue","end","endValue"],function(n){e[n]=t[n]})},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()}}),Q_=_m.extend({type:"dataZoom",render:function(t,e,n){this.dataZoomModel=t,this.ecModel=e,this.api=n},getTargetCoordInfo:function(){var t=this.dataZoomModel,e=this.ecModel,n={};return t.eachTargetAxis(function(t,i){var r=e.getComponent(t.axis,i);if(r){var o=r.getCoordSysModel();o&&function(t,e,n,i){for(var r,o=0;o<n.length;o++)if(n[o].model===t){r=n[o];break}r||n.push(r={model:t,axisModels:[],coordIndex:i}),r.axisModels.push(e)}(o,r,n[o.mainType]||(n[o.mainType]=[]),o.componentIndex)}},this),n}}),J_=(K_.extend({type:"dataZoom.slider",layoutMode:"box",defaultOption:{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#2f4554",width:.5,opacity:.3},areaStyle:{color:"rgba(47,69,84,0.3)",opacity:.3}},borderColor:"#ddd",fillerColor:"rgba(167,183,204,0.4)",handleIcon:"M8.2,13.6V3.9H6.3v9.7H3.1v14.9h3.3v9.7h1.8v-9.7h3.3V13.6H8.2z M9.7,24.4H4.8v-1.4h4.9V24.4z M9.7,19.1H4.8v-1.4h4.9V19.1z",handleSize:"100%",handleStyle:{color:"#a7b7cc"},labelPrecision:null,labelFormatter:null,showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#333"}}}),Vp),tw=Ui,ew=$i,nw=v,iw=f,rw="horizontal",ow="vertical",aw=5,sw=["line","bar","candlestick","scatter"],lw=Q_.extend({type:"dataZoom.slider",init:function(t,e){this._displayables={},this._orient,this._range,this._handleEnds,this._size,this._handleWidth,this._handleHeight,this._location,this._dragging,this._dataShadowInfo,this.api=e},render:function(t,e,n,i){return lw.superApply(this,"render",arguments),vo(this,"_dispatchZoomAction",this.dataZoomModel.get("throttle"),"fixRate"),this._orient=t.get("orient"),!1===this.dataZoomModel.get("show")?void this.group.removeAll():(i&&"dataZoom"===i.type&&i.from===this.uid||this._buildView(),void this._updateView())},remove:function(){lw.superApply(this,"remove",arguments),yo(this,"_dispatchZoomAction")},dispose:function(){lw.superApply(this,"dispose",arguments),yo(this,"_dispatchZoomAction")},_buildView:function(){var t=this.group;t.removeAll(),this._resetLocation(),this._resetInterval();var e=this._displayables.barGroup=new yd;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},_resetLocation:function(){var t=this.dataZoomModel,e=this.api,n=this._findCoordRect(),i={width:e.getWidth(),height:e.getHeight()},r=this._orient===rw?{right:i.width-n.x-n.width,top:i.height-30-7,width:n.width,height:30}:{right:7,top:n.y,width:30,height:n.height},o=xr(t.option);f(["right","top","width","height"],function(t){"ph"===o[t]&&(o[t]=r[t])});var a=mr(o,i,t.padding);this._location={x:a.x,y:a.y},this._size=[a.width,a.height],this._orient===ow&&this._size.reverse()},_positionGroup:function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),o=this._displayables.barGroup,a=(this._dataShadowInfo||{}).otherAxisInverse;o.attr(n!==rw||r?n===rw&&r?{scale:a?[-1,1]:[-1,-1]}:n!==ow||r?{scale:a?[-1,-1]:[-1,1],rotation:Math.PI/2}:{scale:a?[1,-1]:[1,1],rotation:Math.PI/2}:{scale:a?[1,1]:[1,-1]});var s=t.getBoundingRect([o]);t.attr("position",[e.x-s.x,e.y-s.y])},_getViewExtent:function(){return[0,this._size[0]]},_renderBackground:function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.barGroup;n.add(new J_({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40})),n.add(new J_({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:v(this._onClickPanelClick,this)}))},_renderDataShadow:function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(t){var e=this._size,n=t.series,i=n.getRawData(),r=n.getShadowDim?n.getShadowDim():t.otherDim;if(null!=r){var o=i.getDataExtent(r),a=.3*(o[1]-o[0]);o=[o[0]-a,o[1]+a];var l,u=[0,e[1]],h=[0,e[0]],c=[[e[0],0],[0,0]],d=[],f=h[1]/(i.count()-1),p=0,g=Math.round(i.count()/e[0]);i.each([r],function(t,e){if(g>0&&e%g)p+=f;else{var n=null==t||isNaN(t)||""===t,i=n?0:tw(t,o,u,!0);n&&!l&&e?(c.push([c[c.length-1][0],0]),d.push([d[d.length-1][0],0])):!n&&l&&(c.push([p,0]),d.push([p,0])),c.push([p,i]),d.push([p,i]),p+=f,l=n}});var m=this.dataZoomModel;this._displayables.barGroup.add(new Ep({shape:{points:c},style:s({fill:m.get("dataBackgroundColor")},m.getModel("dataBackground.areaStyle").getAreaStyle()),silent:!0,z2:-20})),this._displayables.barGroup.add(new Bp({shape:{points:d},style:m.getModel("dataBackground.lineStyle").getLineStyle(),silent:!0,z2:-19}))}}},_prepareDataShadowInfo:function(){var t=this.dataZoomModel,e=t.get("showDataShadow");if(!1!==e){var n,i=this.ecModel;return t.eachTargetAxis(function(r,o){f(t.getAxisProxy(r.name,o).getTargetSeriesModels(),function(t){if(!(n||!0!==e&&u(sw,t.get("type"))<0)){var a,s=i.getComponent(r.axis,o).axis,l=function(t){return{x:"y",y:"x",radius:"angle",angle:"radius"}[t]}(r.name),h=t.coordinateSystem;null!=l&&h.getOtherAxis&&(a=h.getOtherAxis(s).inverse),l=t.getData().mapDimension(l),n={thisAxis:s,series:t,thisDim:r.name,otherDim:l,otherAxisInverse:a}}},this)},this),n}},_renderHandle:function(){var t=this._displayables,e=t.handles=[],n=t.handleLabels=[],i=this._displayables.barGroup,r=this._size,o=this.dataZoomModel;i.add(t.filler=new J_({draggable:!0,cursor:Eu(this._orient),drift:nw(this._onDragMove,this,"all"),onmousemove:function(t){zc(t.event)},ondragstart:nw(this._showDataInfo,this,!0),ondragend:nw(this._onDragEnd,this),onmouseover:nw(this._showDataInfo,this,!0),onmouseout:nw(this._showDataInfo,this,!1),style:{fill:o.get("fillerColor"),textPosition:"inside"}})),i.add(new J_({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{stroke:o.get("dataBackgroundColor")||o.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),iw([0,1],function(t){var r=Vi(o.get("handleIcon"),{cursor:Eu(this._orient),draggable:!0,drift:nw(this._onDragMove,this,t),onmousemove:function(t){zc(t.event)},ondragend:nw(this._onDragEnd,this),onmouseover:nw(this._showDataInfo,this,!0),onmouseout:nw(this._showDataInfo,this,!1)},{x:-1,y:0,width:2,height:2}),a=r.getBoundingRect();this._handleHeight=ji(o.get("handleSize"),this._size[1]),this._handleWidth=a.width/a.height*this._handleHeight,r.setStyle(o.getModel("handleStyle").getItemStyle());var s=o.get("handleColor");null!=s&&(r.style.fill=s),i.add(e[t]=r);var l=o.textStyleModel;this.group.add(n[t]=new Ap({silent:!0,invisible:!0,style:{x:0,y:0,text:"",textVerticalAlign:"middle",textAlign:"center",textFill:l.getTextColor(),textFont:l.getFont()},z2:10}))},this)},_resetInterval:function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[tw(t[0],[0,100],e,!0),tw(t[1],[0,100],e,!0)]},_updateInterval:function(t,e){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),o=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100];X_(e,i,r,n.get("zoomLock")?"all":t,null!=o.minSpan?tw(o.minSpan,a,r,!0):null,null!=o.maxSpan?tw(o.maxSpan,a,r,!0):null);var s=this._range,l=this._range=ew([tw(i[0],r,a,!0),tw(i[1],r,a,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},_updateView:function(t){var e=this._displayables,n=this._handleEnds,i=ew(n.slice()),r=this._size;iw([0,1],function(t){var i=e.handles[t],o=this._handleHeight;i.attr({scale:[o/2,o/2],position:[n[t],r[1]/2-o/2]})},this),e.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:r[1]}),this._updateDataInfo(t)},_updateDataInfo:function(t){function e(t){var e=Ni(i.handles[t].parent,this.group),n=Bi(0===t?"right":"left",e),s=this._handleWidth/2+aw,l=Ei([c[t]+(0===t?-s:s),this._size[1]/2],e);r[t].setStyle({x:l[0],y:l[1],textVerticalAlign:o===rw?"middle":n,textAlign:o===rw?n:"center",text:a[t]})}var n=this.dataZoomModel,i=this._displayables,r=i.handleLabels,o=this._orient,a=["",""];if(n.get("showDetail")){var s=n.findRepresentativeAxisProxy();if(s){var l=s.getAxisModel().axis,u=this._range,h=t?s.calculateDataWindow({start:u[0],end:u[1]}).valueWindow:s.getDataValueWindow();a=[this._formatLabel(h[0],l),this._formatLabel(h[1],l)]}}var c=ew(this._handleEnds.slice());e.call(this,0),e.call(this,1)},_formatLabel:function(t,e){var n=this.dataZoomModel,i=n.get("labelFormatter"),r=n.get("labelPrecision");(null==r||"auto"===r)&&(r=e.getPixelPrecision());var o=null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel(Math.round(t)):t.toFixed(Math.min(r,20));return _(i)?i(t,o):w(i)?i.replace("{value}",o):o},_showDataInfo:function(t){t=this._dragging||t;var e=this._displayables.handleLabels;e[0].attr("invisible",!t),e[1].attr("invisible",!t)},_onDragMove:function(t,e,n){this._dragging=!0;var i=Ei([e,n],this._displayables.barGroup.getLocalTransform(),!0),r=this._updateInterval(t,i[0]),o=this.dataZoomModel.get("realtime");this._updateView(!o),r&&o&&this._dispatchZoomAction()},_onDragEnd:function(){this._dragging=!1,this._showDataInfo(!1);!this.dataZoomModel.get("realtime")&&this._dispatchZoomAction()},_onClickPanelClick:function(t){var e=this._size,n=this._displayables.barGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(n[0]<0||n[0]>e[0]||n[1]<0||n[1]>e[1])){var i=this._handleEnds,r=(i[0]+i[1])/2,o=this._updateInterval("all",n[0]-r);this._updateView(),o&&this._dispatchZoomAction()}},_dispatchZoomAction:function(){var t=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})},_findCoordRect:function(){var t;if(iw(this.getTargetCoordInfo(),function(e){if(!t&&e.length){var n=e[0].model.coordinateSystem;t=n.getRect&&n.getRect()}}),!t){var e=this.api.getWidth(),n=this.api.getHeight();t={x:.2*e,y:.2*n,width:.6*e,height:.6*n}}return t}});ra({getTargetSeries:function(t){var e=B();return t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,n,i){f(i.getAxisProxy(t.name,n).getTargetSeriesModels(),function(t){e.set(t.uid,t)})})}),e},modifyOutputEnd:!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.setCalculatedRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]})})}}),oa("dataZoom",function(t,e){var n=ku(v(e.eachComponent,e,"dataZoom"),Z_,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})})}),K_.extend({type:"dataZoom.inside",defaultOption:{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}});var uw="\0_ec_interaction_mutex";oa({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),c(Fu,Ac);var hw="\0_ec_dataZoom_roams",cw=v,dw=Q_.extend({type:"dataZoom.inside",init:function(){this._range},render:function(t,e,n){dw.superApply(this,"render",arguments),this._range=t.getPercentRange(),f(this.getTargetCoordInfo(),function(e,i){var r=p(e,function(t){return qu(t.model)});f(e,function(e){var o=e.model,a={};f(["pan","zoom","scrollMove"],function(t){a[t]=cw(fw[t],this,e,i)},this),ju(n,{coordId:qu(o),allCoordIds:r,containsPoint:function(t,e,n){return o.coordinateSystem.containPoint([e,n])},dataZoomId:t.id,dataZoomModel:t,getRange:a})},this)},this)},dispose:function(){(function(t,e){var n=$u(t);f(n,function(t){t.controller.dispose();var n=t.dataZoomInfos;n[e]&&(delete n[e],t.count--)}),Ku(n)})(this.api,this.dataZoomModel.id),dw.superApply(this,"dispose",arguments),this._range=null}}),fw={zoom:function(t,e,n,i){var r=this._range,o=r.slice(),a=t.axisModels[0];if(a){var s=pw[e](null,[i.originX,i.originY],a,n,t),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(o[1]-o[0])+o[0],u=Math.max(1/i.scale,0);o[0]=(o[0]-l)*u+l,o[1]=(o[1]-l)*u+l;var h=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return X_(0,o,[0,100],0,h.minSpan,h.maxSpan),this._range=o,r[0]!==o[0]||r[1]!==o[1]?o:void 0}},pan:Ju(function(t,e,n,i,r,o){var a=pw[i]([o.oldX,o.oldY],[o.newX,o.newY],e,r,n);return a.signal*(t[1]-t[0])*a.pixel/a.pixelLength}),scrollMove:Ju(function(t,e,n,i,r,o){return pw[i]([0,0],[o.scrollDelta,o.scrollDelta],e,r,n).signal*(t[1]-t[0])*o.scrollDelta})},pw={grid:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem.getRect();return t=t||[0,0],"x"===o.dim?(a.pixel=e[0]-t[0],a.pixelLength=s.width,a.pixelStart=s.x,a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=s.height,a.pixelStart=s.y,a.signal=o.inverse?-1:1),a},polar:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===n.mainType?(a.pixel=e[0]-t[0],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=u[1]-u[0],a.pixelStart=u[0],a.signal=o.inverse?-1:1),a},singleAxis:function(t,e,n,i,r){var o=n.axis,a=r.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===o.orient?(s.pixel=e[0]-t[0],s.pixelLength=a.width,s.pixelStart=a.x,s.signal=o.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=a.height,s.pixelStart=a.y,s.signal=o.inverse?-1:1),s}},gw={},mw=ha({type:"toolbox",layoutMode:{type:"box",ignoreSize:!0},optionUpdated:function(){mw.superApply(this,"optionUpdated",arguments),f(this.option.feature,function(t,e){var n=eh(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"}},tooltip:{show:!1}}});ca({type:"toolbox",render:function(t,e,n,i){function r(r,a){var s,l=c[r],d=c[a],f=new Hi(u[l],t,t.ecModel);if(l&&!d){if(function(t){return 0===t.indexOf("my")}(l))s={model:f,onclick:f.option.onclick,featureName:l};else{var p=eh(l);if(!p)return;s=new p(f,e,n)}h[l]=s}else{if(!(s=h[d]))return;s.model=f,s.ecModel=e,s.api=n}return!l&&d?void(s.dispose&&s.dispose(e,n)):!f.get("show")||s.unusable?void(s.remove&&s.remove(e,n)):(o(f,s,l),f.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(f,e,n,i)))}function o(i,r,o){var u=i.getModel("iconStyle"),h=i.getModel("emphasis.iconStyle"),c=r.getIcons?r.getIcons():i.get("icon"),d=i.get("title")||{};if("string"==typeof c){var p=c,g=d;d={},(c={})[o]=p,d[o]=g}var m=i.iconPaths={};f(c,function(o,c){var f=Vi(o,{},{x:-l/2,y:-l/2,width:l,height:l});f.setStyle(u.getItemStyle()),f.hoverStyle=h.getItemStyle(),f.setStyle({text:d[c],textAlign:h.get("textAlign"),textBorderRadius:h.get("textBorderRadius"),textPadding:h.get("textPadding"),textFill:null});var p=t.getModel("tooltip");p&&p.get("show")&&f.attr("tooltip",a({content:d[c],formatter:p.get("formatter",!0)||function(){return d[c]},formatterParams:{componentType:"toolbox",name:c,title:d[c],$vars:["name","title"]},position:p.get("position",!0)||"bottom"},p.option)),_i(f),t.get("showTitle")&&(f.__title=d[c],f.on("mouseover",function(){var e=h.getItemStyle(),n="vertical"===t.get("orient")?null==t.get("right")?"right":"left":null==t.get("bottom")?"bottom":"top";f.setStyle({textFill:h.get("textFill")||e.fill||e.stroke||"#000",textBackgroundColor:h.get("textBackgroundColor"),textPosition:h.get("textPosition")||n})}).on("mouseout",function(){f.setStyle({textFill:null,textBackgroundColor:null})})),f.trigger(i.get("iconStatus."+c)||"normal"),s.add(f),f.on("click",v(r.onclick,r,e,n,c)),m[c]=f})}var s=this.group;if(s.removeAll(),t.get("show")){var l=+t.get("itemSize"),u=t.get("feature")||{},h=this._features||(this._features={}),c=[];f(u,function(t,e){c.push(e)}),new ga(this._featureNames||[],c).add(r).update(r).remove(y(r,null)).execute(),this._featureNames=c,function(t,e,n){var i=e.getBoxLayoutParams(),r=e.get("padding"),o={width:n.getWidth(),height:n.getHeight()},a=mr(i,o,r);Pg(e.get("orient"),t,e.get("itemGap"),a.width,a.height),vr(t,i,o,r)}(s,t,n),s.add(xl(s.getBoundingRect(),t)),s.eachChild(function(t){var e=t.__title,i=t.hoverStyle;if(i&&e){var r=pe(e,Ie(i)),o=t.position[0]+s.position[0],a=!1;t.position[1]+s.position[1]+l+r.height>n.getHeight()&&(i.textPosition="top",a=!0);var u=a?-5-r.height:l+8;o+r.width/2>n.getWidth()?(i.textPosition=["100%",u],i.textAlign="right"):o-r.width/2<0&&(i.textPosition=[0,u],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 vw=Pm.toolbox.saveAsImage;nh.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:vw.title,type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],pixelRatio:1,lang:vw.lang.slice()},nh.prototype.unusable=!ac.canvasSupported;nh.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",r=n.get("type",!0)||"png",o=e.getConnectedDataURL({type:r,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")});if("function"!=typeof MouseEvent||ac.browser.ie||ac.browser.edge)if(window.navigator.msSaveOrOpenBlob){for(var a=atob(o.split(",")[1]),s=a.length,l=new Uint8Array(s);s--;)l[s]=a.charCodeAt(s);var u=new Blob([l]);window.navigator.msSaveOrOpenBlob(u,i+"."+r)}else{var h=n.get("lang"),c='<body style="margin:0;"><img src="'+o+'" style="max-width:100%;" title="'+(h&&h[0]||"")+'" /></body>';window.open().document.write(c)}else{var d=document.createElement("a");d.download=i+"."+r,d.target="_blank",d.href=o;var f=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});d.dispatchEvent(f)}},th("saveAsImage",nh);var yw=Pm.toolbox.magicType;ih.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(yw.title),option:{},seriesIndex:{}};var xw=ih.prototype;xw.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 _w={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}},ww=[["line","bar"],["stack","tiled"]];xw.onclick=function(t,e,n){var i=this.model,r=i.get("seriesIndex."+n);if(_w[n]){var o={series:[]};f(ww,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}},function(e){var r=e.subType,a=e.id,l=_w[n](r,a,e,i);l&&(s(l,e.option),o.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+"Axis",d=t.queryComponents({mainType:c,index:e.get(name+"Index"),id:e.get(name+"Id")})[0].componentIndex;o[c]=o[c]||[];for(var f=0;d>=f;f++)o[c][d]=o[c][d]||{};o[c][d].boundaryGap="bar"===n}}}),e.dispatchAction({type:"changeMagicType",currentType:n,newOption:o})}},oa({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),th("magicType",ih);var bw=Pm.toolbox.dataView,Sw=new Array(60).join("-"),Mw=" ",Iw=new RegExp("["+Mw+"]+","g");sh.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(bw.title),lang:i(bw.lang),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"},sh.prototype.onclick=function(t,e){function n(){i.removeChild(o),x._dom=null}var i=e.getDom(),r=this.model;this._dom&&i.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",o.style.backgroundColor=r.get("backgroundColor")||"#fff";var a=document.createElement("h4"),s=r.get("lang")||[];a.innerHTML=s[0]||r.get("title"),a.style.cssText="margin: 10px 20px;",a.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=rh(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 m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",v=document.createElement("div"),y=document.createElement("div");m+=";background-color:"+r.get("buttonColor"),m+=";color:"+r.get("buttonTextColor");var x=this;st(v,"click",n),st(y,"click",function(){var t;try{t="function"==typeof c?c(l,e.getOption()):ah(u.value,p)}catch(i){throw n(),new Error("Data view format error "+i)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),n()}),v.innerHTML=s[1],y.innerHTML=s[2],y.style.cssText=m,v.style.cssText=m,!r.get("readOnly")&&g.appendChild(y),g.appendChild(v),o.appendChild(a),o.appendChild(l),o.appendChild(g),l.style.height=i.clientHeight-80+"px",i.appendChild(o),this._dom=o},sh.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},sh.prototype.dispose=function(t,e){this.remove(t,e)},th("dataView",sh),oa({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:function(t,e){return p(t,function(t,n){var i=e&&e[n];return b(i)&&!x(i)?(b(t)&&!x(t)&&(t=t.value),s({value:t},i)):t})}(t.data,r)})}else n.push(a({type:"scatter"},t))}),e.mergeOption(s({series:n},t.newOption))});var Cw=y,Tw=f,Aw=p,Dw=Math.min,kw=Math.max,Pw=Math.pow,Ow=1e4,Lw=6,zw=6,Nw="globalPan",Ew={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},Bw={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},Rw={brushStyle:{lineWidth:2,stroke:"rgba(0,0,0,0.3)",fill:"rgba(0,0,0,0.1)"},transformable:!0,brushMode:"single",removeOnClick:!1},Fw=0;lh.prototype={constructor:lh,enableBrush:function(t){return this._brushType&&hh(this),t.brushType&&uh(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){Tw(this._covers,t,e)},updateCovers:function(t){function e(t,e){return(null!=t.id?t.id:o+e)+"-"+t.brushType}function n(e,n){var i=t[e];if(null!=n&&a[n]===u)s[e]=a[n];else{var r=s[e]=null!=n?(a[n].__brushOption=i,a[n]):dh(l,ch(l,i));gh(l,r)}}t=p(t,function(t){return r(i(Rw),t,!0)});var o="\0-brush-index-",a=this._covers,s=this._covers=[],l=this,u=this._creatingCover;return new ga(a,t,function(t,n){return e(t.__brushOption,n)},e).add(n).update(n).remove(function(t){a[t]!==u&&l.group.remove(a[t])}).execute(),this},unmount:function(){return this.enableBrush(!1),xh(this),this._zr.remove(this.group),this},dispose:function(){this.unmount(),this.off()}},c(lh,Ac);var Vw={mousedown:function(t){if(this._dragging)Bh(this,t);else if(!t.target||!t.target.draggable){Lh(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);this._creatingCover=null;(this._creatingPanel=vh(this,t,e))&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(t){var e=this._lastMouseMovePoint;e.x=t.offsetX,e.y=t.offsetY;var n=this.group.transformCoordToLocal(e.x,e.y);if(function(t,e,n){if(t._brushType){var i=t._zr,r=t._covers,o=vh(t,e,n);if(!t._dragging)for(var a=0;a<r.length;a++){var s=r[a].__brushOption;if(o&&(!0===o||s.panelId===o.panelId)&&Gw[s.brushType].contain(r[a],n[0],n[1]))return}o&&i.setCursorStyle("crosshair")}}(this,t,n),this._dragging){Lh(t);var i=Nh(this,t,n,!1);i&&_h(this,i)}},mouseup:function(t){Bh(this,t)},globalout:function(t){Bh(this,t,!0)}},Gw={lineX:Rh(0),lineY:Rh(1),rect:{createCover:function(t,e){return bh(Cw(Dh,function(t){return t},function(t){return t}),t,e,["w","e","n","s","se","sw","ne","nw"])},getCreatingRange:function(t){var e=wh(t);return Th(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(t,e,n,i){Sh(t,e,n,i)},updateCommon:Mh,contain:zh},polygon:{createCover:function(t,e){var n=new yd;return n.add(new Bp({name:"main",style:Ch(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new Ep({name:"main",draggable:!0,drift:Cw(kh,t,e),ondragend:Cw(_h,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n){e.childAt(0).setShape({points:Oh(t,e,n)})},updateCommon:Mh,contain:zh}},Ww={axisPointer:1,tooltip:1,brush:1},Hw=f,Zw=u,Xw=y,Yw=["dataToPoint","pointToData"],Uw=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],jw=Gh.prototype;jw.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=Qw[t.brushType](0,n,e);t.__rangeOffset={offset:Jw[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})},jw.matchOutputRanges=function(t,e,n){Hw(t,function(t){var i=this.findTargetInfo(t,e);i&&!0!==i&&f(i.coordSyses,function(i){var r=Qw[t.brushType](1,i,t.range);n(t,r.values,i,e)})},this)},jw.setInputRanges=function(t,e){Hw(t,function(t){var n=this.findTargetInfo(t,e);if(t.range=t.range||[],n&&!0!==n){t.panelId=n.panelId;var i=Qw[t.brushType](0,n.coordSys,t.coordRange),r=t.__rangeOffset;t.range=r?Jw[t.brushType](i.values,r.offset,function(t,e){var n=Yh(t),i=Yh(e),r=[n[0]/i[0],n[1]/i[1]];return isNaN(r[0])&&(r[0]=1),isNaN(r[1])&&(r[1]=1),r}(i.xyMinMax,r.xyMinMax)):i.values}},this)},jw.makePanelOpts=function(t,e){return p(this._targetInfoList,function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:e&&e(n),clipPath:function(t){return t=Vh(t),function(e){return Fi(e,t)}}(i),isTargetByCursor:Fh(i,t,n.coordSysModel),getLinearBrushOtherExtent:function(t,e){return t=Vh(t),function(n){var i=null!=e?e:n,r=i?t.width:t.height,o=i?t.x:t.y;return[o,o+(r||0)]}}(i)}})},jw.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return!0===i||i&&Zw(i.coordSyses,e.coordinateSystem)>=0},jw.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=Hh(e,t),r=0;r<n.length;r++){var o=n[r],a=t.panelId;if(a){if(o.panelId===a)return o}else for(r=0;r<$w.length;r++)if($w[r](i,o))return o}return!0};var qw={grid:function(t,e){var n=t.xAxisModels,i=t.yAxisModels,r=t.gridModels,o=B(),a={},s={};(n||i||r)&&(Hw(n,function(t){var e=t.axis.grid.model;o.set(e.id,e),a[e.id]=!0}),Hw(i,function(t){var e=t.axis.grid.model;o.set(e.id,e),s[e.id]=!0}),Hw(r,function(t){o.set(t.id,t),a[t.id]=!0,s[t.id]=!0}),o.each(function(t){var r=t.coordinateSystem,o=[];Hw(r.getCartesians(),function(t){(Zw(n,t.getAxis("x").model)>=0||Zw(i,t.getAxis("y").model)>=0)&&o.push(t)}),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:o[0],coordSyses:o,getPanelRect:Kw.grid,xAxisDeclared:a[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,e){Hw(t.geoModels,function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:Kw.geo})})}},$w=[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}],Kw={grid:function(){return this.coordSys.grid.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Ni(t)),e}},Qw={lineX:Xw(Zh,0),lineY:Xw(Zh,1),rect:function(t,e,n){var i=e[Yw[t]]([n[0][0],n[1][0]]),r=e[Yw[t]]([n[0][1],n[1][1]]),o=[Wh([i[0],r[0]]),Wh([i[1],r[1]])];return{values:o,xyMinMax:o}},polygon:function(t,e,n){var i=[[1/0,-1/0],[1/0,-1/0]];return{values:p(n,function(n){var r=e[Yw[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}),xyMinMax:i}}},Jw={lineX:Xw(Xh,0),lineY:Xw(Xh,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]]})}},tb=f,eb="\0_ec_hist_store";K_.extend({type:"dataZoom.select"}),Q_.extend({type:"dataZoom.select"});var nb=Pm.toolbox.dataZoom,ib=f,rb="\0_ec_\0toolbox-dataZoom_";jh.defaultOption={show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:i(nb.title)};var ob=jh.prototype;ob.render=function(t,e,n,i){this.model=t,this.ecModel=e,this.api=n,function(t,e,n,i,r){var o=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(o="dataZoomSelect"===i.key&&i.dataZoomSelectActive),n._isZoomActive=o,t.setIconStatus("zoom",o?"emphasis":"normal");var a=new Gh(qh(t.option),e,{include:["grid"]});n._brushController.setPanels(a.makePanelOpts(r,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"})).enableBrush(!!o&&{brushType:"auto",brushStyle:{lineWidth:0,fill:"rgba(0,0,0,0.2)"}})}(t,e,this,i,n),$h(t,e)},ob.onclick=function(t,e,n){ab[n].call(this)},ob.remove=function(){this._brushController.unmount()},ob.dispose=function(){this._brushController.dispose()};var ab={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(function(t){var e=Uh(t),n=e[e.length-1];e.length>1&&e.pop();var i={};return tb(n,function(t,n){for(var r=e.length-1;r>=0;r--)if(t=e[r][n]){i[n]=t;break}}),i}(this.ecModel))}};ob._onBrush=function(t,e){function n(t,e,n){var o=e.getAxis(t),a=o.model,s=function(t,e,n){var i;return n.eachComponent({mainType:"dataZoom",subType:"select"},function(n){n.getAxisModel(t,e.componentIndex)&&(i=n)}),i}(t,a,r),l=s.findRepresentativeAxisProxy(a).getMinMaxSpan();(null!=l.minValueSpan||null!=l.maxValueSpan)&&(n=X_(0,n.slice(),o.scale.getExtent(),0,l.minValueSpan,l.maxValueSpan)),s&&(i[s.id]={dataZoomId:s.id,startValue:n[0],endValue:n[1]})}if(e.isEnd&&t.length){var i={},r=this.ecModel;this._brushController.updateCovers([]);new Gh(qh(this.model.option),r,{include:["grid"]}).matchOutputRanges(t,r,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)}}),function(t,e){var n=Uh(t);tb(e,function(e,i){for(var r=n.length-1;r>=0&&!n[r][i];r--);if(0>r){var o=t.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(o){var a=o.getPercentRange();n[0][i]={dataZoomId:i,start:a[0],end:a[1]}}}}),n.push(e)}(r,i),this._dispatchZoomAction(i)}},ob._dispatchZoomAction=function(t){var e=[];ib(t,function(t){e.push(i(t))}),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},th("dataZoom",jh),ia(function(t){function e(t,e){if(e){var r=t+"Index",o=e[r];null==o||"all"===o||x(o)||(o=!1===o||"none"===o?[]:[o]),n(t,function(n,a){if(null==o||"all"===o||-1!==u(o,a)){var s={type:"select",$fromToolbox:!0,filterMode:e.filterMode||"filter",id:rb+t+a};s[r]=a,i.push(s)}})}}function n(e,n){var i=t[e];x(i)||(i=i?[i]:[]),ib(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 o=r.feature.dataZoom;e("xAxis",o),e("yAxis",o)}}});var sb=Pm.toolbox.restore;Kh.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:sb.title};Kh.prototype.onclick=function(t,e){(function(t){t[eb]=null})(t),e.dispatchAction({type:"restore",from:this.uid})},th("restore",Kh),oa({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var lb={path:null,compoundPath:null,group:yd,image:He,text:Ap};ia(function(t){var e=t.graphic;x(e)?t.graphic=e[0]&&e[0].elements?[t.graphic[0]]:[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])});var ub=ha({type:"graphic",defaultOption:{elements:[],parentId:null},_elOptionsToUpdate:null,mergeOption:function(){var t=this.option.elements;this.option.elements=null,ub.superApply(this,"mergeOption",arguments),this.option.elements=t},optionUpdated:function(t,e){var n=this.option,i=(e?n:t).elements,r=n.elements=e?[]:n.elements,o=[];this._flatten(i,o);var a=Je(r,o);tn(a);var s=this._elOptionsToUpdate=[];f(a,function(t,e){var n=t.option;n&&(s.push(n),function(t,e){var n=t.exist;if(e.id=t.keyInfo.id,!e.type&&n&&(e.type=n.type),null==e.parentId){var i=e.parentOption;i?e.parentId=i.id:n&&(e.parentId=n.parentId)}e.parentOption=null}(t,n),nc(r,e,n),function(t,e){t&&(t.hv=e.hv=[ec(e,["left","right"]),ec(e,["top","bottom"])],"group"===t.type&&(null==t.width&&(t.width=e.width=0),null==t.height&&(t.height=e.height=0)))}(r[e],n))},this);for(var l=r.length-1;l>=0;l--)null==r[l]?r.splice(l,1):delete r[l].$action},_flatten:function(t,e,n){f(t,function(t){if(t){n&&(t.parentOption=n),e.push(t);var i=t.children;"group"===t.type&&i&&this._flatten(i,e,t),delete t.children}},this)},useElOptionsToUpdate:function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t}});ca({type:"graphic",init:function(){this._elMap=B(),this._lastGraphicModel},render:function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},_updateElements:function(t){var e=t.useElOptionsToUpdate();if(e){var n=this._elMap,i=this.group;f(e,function(e){var r=e.$action,o=e.id,a=n.get(o),s=e.parentId,l=null!=s?n.get(s):i,u=e.style;"text"===e.type&&u&&(e.hv&&e.hv[1]&&(u.textVerticalAlign=u.textBaseline=null),!u.hasOwnProperty("textFill")&&u.fill&&(u.textFill=u.fill),!u.hasOwnProperty("textStroke")&&u.stroke&&(u.textStroke=u.stroke));var h=tc(e);r&&"merge"!==r?"replace"===r?(Jh(a,n),Qh(o,l,h,n)):"remove"===r&&Jh(a,n):a?a.attr(h):Qh(o,l,h,n);var c=n.get(o);c&&(c.__ecGraphicWidthOption=e.width,c.__ecGraphicHeightOption=e.height,function(t,e){var n=t.eventData;t.silent||t.ignore||n||(n=t.eventData={componentType:"graphic",componentIndex:e.componentIndex,name:t.name}),n&&(n.info=t.info)}(c,t))})}},_relocate:function(t,e){for(var n=t.option.elements,i=this.group,r=this._elMap,o=e.getWidth(),a=e.getHeight(),s=0;s<n.length;s++){u=n[s];if((h=r.get(u.id))&&h.isGroup){var l=(c=h.parent)===i;h.__ecGraphicWidth=ji(h.__ecGraphicWidthOption,l?o:c.__ecGraphicWidth)||0,h.__ecGraphicHeight=ji(h.__ecGraphicHeightOption,l?a:c.__ecGraphicHeight)||0}}for(s=n.length-1;s>=0;s--){var u=n[s],h=r.get(u.id);if(h){var c=h.parent;vr(h,u,c===i?{width:o,height:a}:{width:c.__ecGraphicWidth,height:c.__ecGraphicHeight},null,{hv:u.hv,boundingMode:u.bounding})}}},_clear:function(){var t=this._elMap;t.each(function(e){Jh(e,t)}),this._elMap=B()},dispose:function(){this._clear()}}),t.version="4.5.0",t.dependencies={zrender:"4.1.2"},t.PRIORITY=cv,t.init=function(t,e,n){var i=ea(t);if(i)return i;var r=new Ro(t,e,n);return r.id="ec_"+Av++,Cv[r.id]=r,ln(t,kv,r.id),function(t){function e(t,e){for(var i=0;i<t.length;i++)t[i][n]=e}var n="__connectUpdateStatus";rv(xv,function(i,r){t._messageCenter.on(r,function(i){if(Tv[t.group]&&0!==t[n]){if(i&&i.escapeConnect)return;var r=t.makeActionFromEvent(i),o=[];rv(Cv,function(e){e!==t&&e.group===t.group&&o.push(e)}),e(o,0),rv(o,function(t){1!==t[n]&&t.dispatchAction(r)}),e(o,2)}})})}(r),r},t.connect=function(t){if(x(t)){var e=t;t=null,rv(e,function(e){null!=e.group&&(t=e.group)}),t=t||"g_"+Dv++,rv(e,function(e){e.group=t})}return Tv[t]=!0,t},t.disConnect=ta,t.disconnect=Pv,t.dispose=function(t){"string"==typeof t?t=Cv[t]:t instanceof Ro||(t=ea(t)),t instanceof Ro&&!t.isDisposed()&&t.dispose()},t.getInstanceByDom=ea,t.getInstanceById=function(t){return Cv[t]},t.registerTheme=na,t.registerPreprocessor=ia,t.registerProcessor=ra,t.registerPostUpdate=function(t){bv.push(t)},t.registerAction=oa,t.registerCoordinateSystem=function(t,e){Lr.register(t,e)},t.getCoordinateSystemDimensions=function(t){var e=Lr.get(t);return e?e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice():void 0},t.registerLayout=aa,t.registerVisual=sa,t.registerLoading=ua,t.extendComponentModel=ha,t.extendComponentView=ca,t.extendSeriesModel=da,t.extendChartView=fa,t.setCanvasCreator=function(t){n("createCanvas",t)},t.registerMap=function(t,e,n){ev.registerMap(t,e,n)},t.getMap=function(t){var e=ev.retrieveMap(t);return e&&e[0]&&{geoJson:e[0].geoJSON,specialAreas:e[0].specialAreas}},t.dataTool={},t.zrender=cf,t.number=_g,t.format=Tg,t.throttle=mo,t.helper=Ty,t.matrix=Gc,t.vector=Cc,t.color=ad,t.parseGeoJSON=Dy,t.parseGeoJson=Ly,t.util=zy,t.graphic=Ny,t.List=Hv,t.Model=Hi,t.Axis=Oy,t.env=ac});
|