home~threejshb.cebfb226.js 969 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([["home~threejshb"],{"28d5":function(t,e,n){},4066:function(t,e,n){},"539b":function(t,e,n){"use strict";var p={};n.r(p),n.d(p,"updateProps",function(){return Wl}),n.d(p,"initProps",function(){return Ul}),n.d(p,"removeElement",function(){return Xl}),n.d(p,"removeElementWithFadeOut",function(){return jl}),n.d(p,"isElementRemoved",function(){return Yl}),n.d(p,"extendShape",function(){return Py}),n.d(p,"extendPath",function(){return Ry}),n.d(p,"registerShape",function(){return Ny}),n.d(p,"getShapeClass",function(){return zy}),n.d(p,"makePath",function(){return Ey}),n.d(p,"makeImage",function(){return Vy}),n.d(p,"mergePath",function(){return Fy}),n.d(p,"resizePath",function(){return Gy}),n.d(p,"subPixelOptimizeLine",function(){return Hy}),n.d(p,"subPixelOptimizeRect",function(){return Wy}),n.d(p,"subPixelOptimize",function(){return Uy}),n.d(p,"getTransform",function(){return Yy}),n.d(p,"applyTransform",function(){return Xy}),n.d(p,"transformDirection",function(){return Zy}),n.d(p,"groupTransition",function(){return qy}),n.d(p,"clipPointsByRect",function(){return Ky}),n.d(p,"clipRectByRect",function(){return Jy}),n.d(p,"createIcon",function(){return Qy}),n.d(p,"linePolygonIntersect",function(){return $y}),n.d(p,"lineLineIntersect",function(){return tm}),n.d(p,"setTooltipConfig",function(){return em}),n.d(p,"Group",function(){return ro}),n.d(p,"Image",function(){return ys}),n.d(p,"Text",function(){return Fs}),n.d(p,"Circle",function(){return $f}),n.d(p,"Ellipse",function(){return Ig}),n.d(p,"Sector",function(){return Wg}),n.d(p,"Ring",function(){return Xg}),n.d(p,"Polygon",function(){return $g}),n.d(p,"Polyline",function(){return ny}),n.d(p,"Rect",function(){return Ts}),n.d(p,"Line",function(){return Kf}),n.d(p,"BezierCurve",function(){return py}),n.d(p,"Arc",function(){return gf}),n.d(p,"IncrementalDisplayable",function(){return wy}),n.d(p,"CompoundPath",function(){return dy}),n.d(p,"LinearGradient",function(){return fy}),n.d(p,"RadialGradient",function(){return gy}),n.d(p,"BoundingRect",function(){return ki}),n.d(p,"OrientedBoundingRect",function(){return _y}),n.d(p,"Point",function(){return bi}),n.d(p,"Path",function(){return as});var a=n("d4ec"),i=n("bee2"),s=n("257e"),l=n("262e"),u=n("2caf"),h=n("ade3"),o=(n("e9c4"),n("99af"),n("2b0e")),r=n("2fe1"),c=function(t,e){return(c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function d(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}c(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var f=function(){return(f=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};Object.create,Object.create;var g=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},y=new function(){this.browser=new g,this.node=!1,this.wxa=!1,this.worker=!1,this.canvasSupported=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(y.wxa=!0,y.canvasSupported=!0,y.touchEventsSupported=!0):"undefined"==typeof document&&"undefined"!=typeof self?(y.worker=!0,y.canvasSupported=!0):"undefined"==typeof navigator?(y.node=!0,y.canvasSupported=!0,y.svgSupported=!0):(ur=navigator.userAgent,mu=(gr=y).browser,Ki=ur.match(/Firefox\/([\d.]+)/),no=ur.match(/MSIE\s([\d.]+)/)||ur.match(/Trident\/.+?rv:(([\d.]+))/),io=ur.match(/Edge?\/([\d.]+)/),ur=/micromessenger/i.test(ur),Ki&&(mu.firefox=!0,mu.version=Ki[1]),no&&(mu.ie=!0,mu.version=no[1]),io&&(mu.edge=!0,mu.version=io[1],mu.newEdge=18<+io[1].split(".")[0]),ur&&(mu.weChat=!0),gr.canvasSupported=!!document.createElement("canvas").getContext,gr.svgSupported="undefined"!=typeof SVGRect,gr.touchEventsSupported="ontouchstart"in window&&!mu.ie&&!mu.edge,gr.pointerEventsSupported="onpointerdown"in window&&(mu.edge||mu.ie&&11<=+mu.version),gr.domSupported="undefined"!=typeof document,ur=document.documentElement.style,gr.transform3dSupported=(mu.ie&&"transition"in ur||mu.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in ur)&&!("OTransition"in ur),gr.transformSupported=gr.transform3dSupported||mu.ie&&9<=+mu.version);var w=y,m={"[object Function]":!0,"[object RegExp]":!0,"[object Date]":!0,"[object Error]":!0,"[object CanvasGradient]":!0,"[object CanvasPattern]":!0,"[object Image]":!0,"[object Canvas]":!0},v={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0},x=Object.prototype.toString,_=Array.prototype,b=_.forEach,S=_.filter,M=_.slice,I=_.map,T=function(){}.constructor,C=T?T.prototype:null,D="__proto__",A={},k=2311;function L(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e]}function P(t){if(null==t||"object"!=typeof t)return t;var e=t,n=x.call(t);if("[object Array]"===n){if(!dt(t))for(var e=[],i=0,o=t.length;i<o;i++)e[i]=P(t[i])}else if(v[n]){if(!dt(t)){var r=t.constructor;if(r.from)e=r.from(t);else for(e=new r(t.length),i=0,o=t.length;i<o;i++)e[i]=P(t[i])}}else if(!m[n]&&!dt(t)&&!nt(t))for(var a in e={},t)t.hasOwnProperty(a)&&a!==D&&(e[a]=P(t[a]));return e}function O(t,e,n){if(!$(e)||!$(t))return n?P(e):t;for(var i in e){var o,r;e.hasOwnProperty(i)&&i!==D&&(o=t[i],!$(r=e[i])||!$(o)||j(r)||j(o)||nt(r)||nt(o)||tt(r)||tt(o)||dt(r)||dt(o)?!n&&i in t||(t[i]=P(e[i])):O(o,r,n))}return t}function R(t,e){for(var n=t[0],i=1,o=t.length;i<o;i++)n=O(n,t[i],e);return n}function N(t,e){if(Object.assign)Object.assign(t,e);else for(var n in e)e.hasOwnProperty(n)&&n!==D&&(t[n]=e[n]);return t}function z(t,e,n){for(var i=Y(e),o=0;o<i.length;o++){var r=i[o];(n?null!=e[r]:null==t[r])&&(t[r]=e[r])}return t}var E=function(){return A.createCanvas()};function V(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;n<i;n++)if(t[n]===e)return n}return-1}function B(t,e,n){if(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(e),o=0;o<i.length;o++){var r=i[o];"constructor"!==r&&(n?null!=e[r]:null==t[r])&&(t[r]=e[r])}else z(t,e,n)}function F(t){return!!t&&"string"!=typeof t&&"number"==typeof t.length}function G(t,e,n){if(t&&e)if(t.forEach&&t.forEach===b)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,o=t.length;i<o;i++)e.call(n,t[i],i,t);else for(var r in t)t.hasOwnProperty(r)&&e.call(n,t[r],r,t)}function H(t,e,n){if(!t)return[];if(!e)return st(t);if(t.map&&t.map===I)return t.map(e,n);for(var i=[],o=0,r=t.length;o<r;o++)i.push(e.call(n,t[o],o,t));return i}function W(t,e,n,i){if(t&&e){for(var o=0,r=t.length;o<r;o++)n=e.call(i,n,t[o],o,t);return n}}function U(t,e,n){if(!t)return[];if(!e)return st(t);if(t.filter&&t.filter===S)return t.filter(e,n);for(var i=[],o=0,r=t.length;o<r;o++)e.call(n,t[o],o,t)&&i.push(t[o]);return i}function Y(t){if(!t)return[];if(Object.keys)return Object.keys(t);var e,n=[];for(e in t)t.hasOwnProperty(e)&&n.push(e);return n}A.createCanvas=function(){return document.createElement("canvas")};var X=C&&q(C.bind)?C.call.bind(C.bind):function(t,e){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];return function(){return t.apply(e,n.concat(M.call(arguments)))}};function Z(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return function(){return t.apply(this,e.concat(M.call(arguments)))}}function j(t){return Array.isArray?Array.isArray(t):"[object Array]"===x.call(t)}function q(t){return"function"==typeof t}function K(t){return"string"==typeof t}function J(t){return"[object String]"===x.call(t)}function Q(t){return"number"==typeof t}function $(t){var e=typeof t;return"function"==e||!!t&&"object"==e}function tt(t){return m[x.call(t)]}function et(t){return v[x.call(t)]}function nt(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function it(t){return t!=t}function ot(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var n=0,i=t.length;n<i;n++)if(null!=t[n])return t[n]}function rt(t,e){return null!=t?t:e}function at(t,e,n){return null!=t?t:null!=e?e:n}function st(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return M.apply(t,e)}function lt(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 ut(t,e){if(!t)throw new Error(e)}function ht(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var ct="__ec_primitive__";function pt(t){t[ct]=!0}function dt(t){return t[ct]}var ft=(gt.prototype.get=function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},gt.prototype.set=function(t,e){return this.data[t]=e},gt.prototype.each=function(t,e){for(var n in this.data)this.data.hasOwnProperty(n)&&t.call(e,this.data[n],n)},gt.prototype.keys=function(){return Y(this.data)},gt.prototype.removeKey=function(t){delete this.data[t]},gt);function gt(t){this.data={};var n=j(t);this.data={};var i=this;function e(t,e){n?i.set(t,e):i.set(e,t)}t instanceof gt?t.each(e):t&&G(t,e)}function yt(t){return new ft(t)}function mt(t,e){for(var n=new t.constructor(t.length+e.length),i=0;i<t.length;i++)n[i]=t[i];for(var o=t.length,i=0;i<e.length;i++)n[i+o]=e[i];return n}function vt(t,e){var n=Object.create?Object.create(t):((n=function(){}).prototype=t,new n);return e&&N(n,e),n}function xt(t,e){return t.hasOwnProperty(e)}function _t(){}var bt=function(t,e){return(bt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function wt(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}bt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function St(t,e){return[t=null==t?0:t,e=null==e?0:e]}function Mt(t,e){return t[0]=e[0],t[1]=e[1],t}function It(t){return[t[0],t[1]]}function Tt(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function Ct(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function Dt(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function At(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function kt(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function Lt(t,e){var n=At(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function Pt(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}Object.create,Object.create;var Ot=Pt;var Rt=function(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])};function Nt(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t}function zt(t,e,n){var i=e[0],e=e[1];return t[0]=n[0]*i+n[2]*e+n[4],t[1]=n[1]*i+n[3]*e+n[5],t}function Et(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function Vt(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}var Bt=function(t,e){this.target=t,this.topTarget=e&&e.topTarget},Ft=(Ut.prototype._dragStart=function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent;e&&((this._draggingTarget=e).dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new Bt(e,t),"dragstart",t.event))},Ut.prototype._drag=function(t){var e,n,i,o,r=this._draggingTarget;r&&(i=t.offsetX,o=t.offsetY,e=i-this._x,n=o-this._y,this._x=i,this._y=o,r.drift(e,n,t),this.handler.dispatchToElement(new Bt(r,t),"drag",t.event),i=this.handler.findHover(i,o,r).target,o=this._dropTarget,r!==(this._dropTarget=i)&&(o&&i!==o&&this.handler.dispatchToElement(new Bt(o,t),"dragleave",t.event),i&&i!==o&&this.handler.dispatchToElement(new Bt(i,t),"dragenter",t.event)))},Ut.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new Bt(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new Bt(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},Ut),Gt=(Wt.prototype.on=function(t,e,n,i){this._$handlers||(this._$handlers={});var o=this._$handlers;if("function"==typeof e&&(i=n,n=e,e=null),!n||!t)return this;var r=this._$eventProcessor;null!=e&&r&&r.normalizeQuery&&(e=r.normalizeQuery(e)),o[t]||(o[t]=[]);for(var a=0;a<o[t].length;a++)if(o[t][a].h===n)return this;r={h:n,query:e,ctx:i||this,callAtLast:n.zrEventfulCallAtLast},e=o[t].length-1,i=o[t][e];return i&&i.callAtLast?o[t].splice(e,0,r):o[t].push(r),this},Wt.prototype.isSilent=function(t){var e=this._$handlers;return!e||!e[t]||!e[t].length},Wt.prototype.off=function(t,e){var n=this._$handlers;if(!n)return this;if(!t)return this._$handlers={},this;if(e){if(n[t]){for(var i=[],o=0,r=n[t].length;o<r;o++)n[t][o].h!==e&&i.push(n[t][o]);n[t]=i}n[t]&&0===n[t].length&&delete n[t]}else delete n[t];return this},Wt.prototype.trigger=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[t],o=this._$eventProcessor;if(i)for(var r=e.length,a=i.length,s=0;s<a;s++){var l=i[s];if(!o||!o.filter||null==l.query||o.filter(t,l.query))switch(r){case 0:l.h.call(l.ctx);break;case 1:l.h.call(l.ctx,e[0]);break;case 2:l.h.call(l.ctx,e[0],e[1]);break;default:l.h.apply(l.ctx,e)}}return o&&o.afterTrigger&&o.afterTrigger(t),this},Wt.prototype.triggerWithContext=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[t],o=this._$eventProcessor;if(i)for(var r=e.length,a=e[r-1],s=i.length,l=0;l<s;l++){var u=i[l];if(!o||!o.filter||null==u.query||o.filter(t,u.query))switch(r){case 0:u.h.call(a);break;case 1:u.h.call(a,e[0]);break;case 2:u.h.call(a,e[0],e[1]);break;default:u.h.apply(a,e.slice(1,r-1))}}return o&&o.afterTrigger&&o.afterTrigger(t),this},Wt),Ht=Math.log(2);function Wt(t){t&&(this._$eventProcessor=t)}function Ut(t){(this.handler=t).on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}function Yt(t,e,n,i,o,r){var a=i+"-"+o,s=t.length;if(r.hasOwnProperty(a))return r[a];if(1===e){var l=Math.round(Math.log((1<<s)-1&~o)/Ht);return t[n][l]}for(var u=i|1<<n,h=n+1;i&1<<h;)h++;for(var c=0,p=0,d=0;p<s;p++){var f=1<<p;f&o||(c+=(d%2?-1:1)*t[n][p]*Yt(t,e-1,h,u,o|f,r),d++)}return r[a]=c}function Xt(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={},o=Yt(n,8,0,0,0,i);if(0!==o){for(var r=[],a=0;a<8;a++)for(var s=0;s<8;s++)null==r[s]&&(r[s]=0),r[s]+=((a+s)%2?-1:1)*Yt(n,7,0===a?1:0,1<<a,1<<s,i)/o*e[a];return function(t,e,n){var i=e*r[6]+n*r[7]+1;t[0]=(e*r[0]+n*r[1]+r[2])/i,t[1]=(e*r[3]+n*r[4]+r[5])/i}}}var Zt="___zrEVENTSAVED",jt=[];function qt(t,e,n,i,o){if(e.getBoundingClientRect&&w.domSupported&&!Kt(e)){var r=e[Zt]||(e[Zt]={}),o=function(t,e,n){for(var i=n?"invTrans":"trans",o=e[i],r=e.srcCoords,a=[],s=[],l=!0,u=0;u<4;u++){var h=t[u].getBoundingClientRect(),c=2*u,p=h.left,h=h.top;a.push(p,h),l=l&&r&&p===r[c]&&h===r[1+c],s.push(t[u].offsetLeft,t[u].offsetTop)}return l&&o?o:(e.srcCoords=a,e[i]=n?Xt(s,a):Xt(a,s))}(function(t,e){var n=e.markers;if(n)return n;n=e.markers=[];for(var i=["left","right"],o=["top","bottom"],r=0;r<4;r++){var a=document.createElement("div"),s=a.style,l=r%2,u=(r>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",o[u]+":0",i[1-l]+":auto",o[1-u]+":auto",""].join("!important;"),t.appendChild(a),n.push(a)}return n}(e,r),r,o);if(o)return o(t,n,i),!0}return!1}function Kt(t){return"CANVAS"===t.nodeName.toUpperCase()}var Jt="undefined"!=typeof window&&!!window.addEventListener,Qt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,$t=[];function te(t,e,n,i){return n=n||{},i||!w.canvasSupported?ee(t,e,n):w.browser.firefox&&w.browser.version<"39"&&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):ee(t,e,n),n}function ee(t,e,n){if(w.domSupported&&t.getBoundingClientRect){var i=e.clientX,o=e.clientY;if(Kt(t)){e=t.getBoundingClientRect();return n.zrX=i-e.left,n.zrY=o-e.top,0}if(qt($t,t,i,o))return n.zrX=$t[0],n.zrY=$t[1],0}n.zrX=n.zrY=0}function ne(t){return t||window.event}function ie(t,e,n){if(null!=(e=ne(e)).zrX)return e;var i=e.type;i&&0<=i.indexOf("touch")?(i=("touchend"!==i?e.targetTouches:e.changedTouches)[0])&&te(t,i,e,n):(te(t,e,e,n),o=function(t){var e=t.wheelDelta;if(e)return e;var n=t.deltaX,t=t.deltaY;return null==n||null==t?e:3*(0!==t?Math.abs(t):Math.abs(n))*(0<t||!(t<0)&&0<n?-1:1)}(e),e.zrDelta=o?o/120:-(e.detail||0)/3);var o=e.button;return null==e.which&&void 0!==o&&Qt.test(e.type)&&(e.which=1&o?1:2&o?3:4&o?2:0),e}function oe(t,e,n,i){Jt?t.addEventListener(e,n,i):t.attachEvent("on"+e,n)}var re=Jt?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0};function ae(t){return 2===t.which||3===t.which}var se=(le.prototype.recognize=function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},le.prototype.clear=function(){return this._track.length=0,this},le.prototype._doTrack=function(t,e,n){var i=t.touches;if(i){for(var o={points:[],touches:[],target:e,event:t},r=0,a=i.length;r<a;r++){var s=i[r],l=te(n,s,{});o.points.push([l.zrX,l.zrY]),o.touches.push(s)}this._track.push(o)}},le.prototype._recognize=function(t){for(var e in he)if(he.hasOwnProperty(e)){e=he[e](this._track,t);if(e)return e}},le);function le(){this._track=[]}function ue(t){var e=t[1][0]-t[0][0],t=t[1][1]-t[0][1];return Math.sqrt(e*e+t*t)}var he={pinch:function(t,e){var n=t.length;if(n){var i=(t[n-1]||{}).points,n=(t[n-2]||{}).points||i;if(n&&1<n.length&&i&&1<i.length){n=ue(i)/ue(n);isFinite(n)||(n=1),e.pinchScale=n;i=[(i[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2];return e.pinchX=i[0],e.pinchY=i[1],{type:"pinch",target:t[0].target,event:e}}}}};function ce(){re(this.event)}var pe,de,fe=(wt(xe,de=Gt),xe.prototype.dispose=function(){},xe.prototype.setCursor=function(){},xe),ge=function(t,e){this.x=t,this.y=e},ye=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],me=(wt(ve,pe=Gt),ve.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(G(ye,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},ve.prototype.mousemove=function(t){var e=t.zrX,n=t.zrY,i=_e(this,e,n),o=this._hovered,r=o.target;r&&!r.__zr&&(r=(o=this.findHover(o.x,o.y)).target);i=this._hovered=i?new ge(e,n):this.findHover(e,n),e=i.target,n=this.proxy;n.setCursor&&n.setCursor(e?e.cursor:"default"),r&&e!==r&&this.dispatchToElement(o,"mouseout",t),this.dispatchToElement(i,"mousemove",t),e&&e!==r&&this.dispatchToElement(i,"mouseover",t)},ve.prototype.mouseout=function(t){var e=t.zrEventControl;"only_globalout"!==e&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==e&&this.trigger("globalout",{type:"globalout",event:t})},ve.prototype.resize=function(){this._hovered=new ge(0,0)},ve.prototype.dispatch=function(t,e){t=this[t];t&&t.call(this,e)},ve.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},ve.prototype.setCursorStyle=function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},ve.prototype.dispatchToElement=function(t,e,n){var i=(t=t||{}).target;if(!i||!i.silent){for(var o="on"+e,r={type:e,event:n,target:(t=t).target,topTarget:t.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:ce};i&&(i[o]&&(r.cancelBubble=!!i[o].call(i,r)),i.trigger(e,r),i=i.__hostTarget||i.parent,!r.cancelBubble););r.cancelBubble||(this.trigger(e,r),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(t){"function"==typeof t[o]&&t[o].call(t,r),t.trigger&&t.trigger(e,r)}))}},ve.prototype.findHover=function(t,e,n){for(var i=this.storage.getDisplayList(),o=new ge(t,e),r=i.length-1;0<=r;r--){var a=void 0;if(i[r]!==n&&!i[r].ignore&&(a=function(t,e,n){if(t[t.rectHover?"rectContain":"contain"](e,n)){for(var i=t,o=void 0,r=!1;i;){if(!(r=i.ignoreClip?!0:r)){var a=i.getClipPath();if(a&&!a.contain(e,n))return!1;i.silent&&(o=!0)}a=i.__hostTarget;i=a||i.parent}return!o||"silent"}return!1}(i[r],t,e))&&(o.topTarget||(o.topTarget=i[r]),"silent"!==a)){o.target=i[r];break}}return o},ve.prototype.processGesture=function(t,e){this._gestureMgr||(this._gestureMgr=new se);var n=this._gestureMgr;"start"===e&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);"end"===e&&n.clear(),i&&(n=i.type,t.gestureEvent=n,(t=new ge).target=i.target,this.dispatchToElement(t,n,i.event))},ve);function ve(t,e,n,i){var o=pe.call(this)||this;return o._hovered=new ge(0,0),o.storage=t,o.painter=e,o.painterRoot=i,n=n||new fe,o.proxy=null,o.setHandlerProxy(n),o._draggingMgr=new Ft(o),o}function xe(){var t=null!==de&&de.apply(this,arguments)||this;return t.handler=null,t}function _e(t,e,n){t=t.painter;return e<0||e>t.getWidth()||n<0||n>t.getHeight()}G(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(a){me.prototype[a]=function(t){var e,n,i=t.zrX,o=t.zrY,r=_e(this,i,o);if("mouseup"===a&&r||(n=(e=this.findHover(i,o)).target),"mousedown"===a)this._downEl=n,this._downPoint=[t.zrX,t.zrY],this._upEl=n;else if("mouseup"===a)this._upEl=n;else if("click"===a){if(this._downEl!==this._upEl||!this._downPoint||4<Ot(this._downPoint,[t.zrX,t.zrY]))return;this._downPoint=null}this.dispatchToElement(e,a,t)}});var be=me,we=32,Se=7;function Me(t,e,n,i){var o=e+1;if(o===n)return 1;if(i(t[o++],t[e])<0){for(;o<n&&i(t[o],t[o-1])<0;)o++;!function(t,e,n){n--;for(;e<n;){var i=t[e];t[e++]=t[n],t[n--]=i}}(t,e,o)}else for(;o<n&&0<=i(t[o],t[o-1]);)o++;return o-e}function Ie(t,e,n,i,o){for(i===e&&i++;i<n;i++){for(var r,a=t[i],s=e,l=i;s<l;)o(a,t[r=s+l>>>1])<0?l=r:s=1+r;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(;0<u;)t[s+u]=t[s+u-1],u--}t[s]=a}}function Te(t,e,n,i,o,r){var a=0,s=0,l=1;if(0<r(t,e[n+o])){for(s=i-o;l<s&&0<r(t,e[n+o+l]);)(l=1+((a=l)<<1))<=0&&(l=s);s<l&&(l=s),a+=o,l+=o}else{for(s=o+1;l<s&&r(t,e[n+o-l])<=0;)(l=1+((a=l)<<1))<=0&&(l=s);i=a,a=o-(l=s<l?s:l),l=o-i}for(a++;a<l;){var u=a+(l-a>>>1);0<r(t,e[n+u])?a=u+1:l=u}return l}function Ce(t,e,n,i,o,r){var a=0,s=0,l=1;if(r(t,e[n+o])<0){for(s=o+1;l<s&&r(t,e[n+o-l])<0;)(l=1+((a=l)<<1))<=0&&(l=s);var u=a,a=o-(l=s<l?s:l),l=o-u}else{for(s=i-o;l<s&&0<=r(t,e[n+o+l]);)(l=1+((a=l)<<1))<=0&&(l=s);s<l&&(l=s),a+=o,l+=o}for(a++;a<l;){var h=a+(l-a>>>1);r(t,e[n+h])<0?l=h:a=h+1}return l}function De(f,g){var r,a,y=Se,s=0,m=(f.length,[]);function e(t){var e=r[t],n=a[t],i=r[t+1],o=a[t+1];a[t]=n+o,t===s-3&&(r[t+1]=r[t+2],a[t+1]=a[t+2]),s--;t=Ce(f[i],f,e,n,0,g);e+=t,0==(n-=t)||0!==(o=Te(f[e+n-1],f,i,o,o-1,g))&&(n<=o?function(t,e,n,i){var o=0;for(o=0;o<e;o++)m[o]=f[t+o];var r=0,a=n,s=t;if(f[s++]=f[a++],0!=--i)if(1!==e){for(var l,u,h,c=y;;){u=l=0,h=!1;do{if(g(f[a],m[r])<0){if(f[s++]=f[a++],u++,(l=0)==--i){h=!0;break}}else if(f[s++]=m[r++],l++,u=0,1==--e){h=!0;break}}while((l|u)<c);if(h)break;do{if(0!==(l=Ce(f[a],m,r,e,0,g))){for(o=0;o<l;o++)f[s+o]=m[r+o];if(s+=l,r+=l,(e-=l)<=1){h=!0;break}}if(f[s++]=f[a++],0==--i){h=!0;break}if(0!==(u=Te(m[r],f,a,i,0,g))){for(o=0;o<u;o++)f[s+o]=f[a+o];if(s+=u,a+=u,0===(i-=u)){h=!0;break}}if(f[s++]=m[r++],1==--e){h=!0;break}}while(c--,Se<=l||Se<=u);if(h)break;c<0&&(c=0),c+=2}if((y=c)<1&&(y=1),1===e){for(o=0;o<i;o++)f[s+o]=f[a+o];f[s+i]=m[r]}else{if(0===e)throw new Error;for(o=0;o<e;o++)f[s+o]=m[r+o]}}else{for(o=0;o<i;o++)f[s+o]=f[a+o];f[s+i]=m[r]}else for(o=0;o<e;o++)f[s+o]=m[r+o]}:function(t,e,n,i){var o=0;for(o=0;o<i;o++)m[o]=f[n+o];var r=t+e-1,a=i-1,s=n+i-1,l=0,u=0;if(f[s--]=f[r--],0!=--e)if(1!==i){for(var h=y;;){var c=0,p=0,d=!1;do{if(g(m[a],f[r])<0){if(f[s--]=f[r--],c++,(p=0)==--e){d=!0;break}}else if(f[s--]=m[a--],p++,c=0,1==--i){d=!0;break}}while((c|p)<h);if(d)break;do{if(0!==(c=e-Ce(m[a],f,t,e,e-1,g))){for(e-=c,u=(s-=c)+1,l=(r-=c)+1,o=c-1;0<=o;o--)f[u+o]=f[l+o];if(0===e){d=!0;break}}if(f[s--]=m[a--],1==--i){d=!0;break}if(0!==(p=i-Te(f[r],m,0,i,i-1,g))){for(i-=p,u=(s-=p)+1,l=(a-=p)+1,o=0;o<p;o++)f[u+o]=m[l+o];if(i<=1){d=!0;break}}if(f[s--]=f[r--],0==--e){d=!0;break}}while(h--,Se<=c||Se<=p);if(d)break;h<0&&(h=0),h+=2}if((y=h)<1&&(y=1),1===i){for(u=(s-=e)+1,l=(r-=e)+1,o=e-1;0<=o;o--)f[u+o]=f[l+o];f[s]=m[a]}else{if(0===i)throw new Error;for(l=s-(i-1),o=0;o<i;o++)f[l+o]=m[o]}}else{for(u=(s-=e)+1,l=(r-=e)+1,o=e-1;0<=o;o--)f[u+o]=f[l+o];f[s]=m[a]}else for(l=s-(i-1),o=0;o<i;o++)f[l+o]=m[o]})(e,n,i,o)}return r=[],a=[],{mergeRuns:function(){for(;1<s;){var t=s-2;if(1<=t&&a[t-1]<=a[t]+a[t+1]||2<=t&&a[t-2]<=a[t]+a[t-1])a[t-1]<a[t+1]&&t--;else if(a[t]>a[t+1])break;e(t)}},forceMergeRuns:function(){for(;1<s;){var t=s-2;0<t&&a[t-1]<a[t+1]&&t--,e(t)}},pushRun:function(t,e){r[s]=t,a[s]=e,s+=1}}}function Ae(t,e,n,i){var o=(i=i||t.length)-(n=n||0);if(!(o<2)){var r=0;if(o<we)return Ie(t,n,i,n+(r=Me(t,n,i,e)),e),0;var a,s=De(t,e),l=function(t){for(var e=0;we<=t;)e|=1&t,t>>=1;return t+e}(o);do{}while((r=Me(t,n,i,e))<l&&(Ie(t,n,n+(a=l<(a=o)?l:o),n+r,e),r=a),s.pushRun(n,r),s.mergeRuns(),n+=r,0!==(o-=r));s.forceMergeRuns()}}var ke=1,Le=4;function Pe(){0}function Oe(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}var Re=(Ne.prototype.traverse=function(t,e){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,e)},Ne.prototype.getDisplayList=function(t,e){e=e||!1;var n=this._displayList;return!t&&n.length||this.updateDisplayList(e),n},Ne.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var e=this._roots,n=this._displayList,i=0,o=e.length;i<o;i++)this._updateAndAddDisplayable(e[i],null,t);n.length=this._displayListLen,w.canvasSupported&&Ae(n,Oe)},Ne.prototype._updateAndAddDisplayable=function(t,e,n){if(!t.ignore||n){t.beforeUpdate(),t.update(),t.afterUpdate();var i=t.getClipPath();if(t.ignoreClip)e=null;else if(i){e=e?e.slice():[];for(var o=i,r=t;o;)o.parent=r,o.updateTransform(),e.push(o),o=(r=o).getClipPath()}if(t.childrenRef){for(var a=t.childrenRef(),s=0;s<a.length;s++){var l=a[s];t.__dirty&&(l.__dirty|=ke),this._updateAndAddDisplayable(l,e,n)}t.__dirty=0}else{var u=t;e&&e.length?u.__clipPaths=e:u.__clipPaths&&0<u.__clipPaths.length&&(u.__clipPaths=[]),isNaN(u.z)&&(Pe(),u.z=0),isNaN(u.z2)&&(Pe(),u.z2=0),isNaN(u.zlevel)&&(Pe(),u.zlevel=0),this._displayList[this._displayListLen++]=u}u=t.getDecalElement&&t.getDecalElement();u&&this._updateAndAddDisplayable(u,e,n);u=t.getTextGuideLine();u&&this._updateAndAddDisplayable(u,e,n);u=t.getTextContent();u&&this._updateAndAddDisplayable(u,e,n)}},Ne.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},Ne.prototype.delRoot=function(t){if(t instanceof Array)for(var e=0,n=t.length;e<n;e++)this.delRoot(t[e]);else{var i=V(this._roots,t);0<=i&&this._roots.splice(i,1)}},Ne.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},Ne.prototype.getRoots=function(){return this._roots},Ne.prototype.dispose=function(){this._displayList=null,this._roots=null},Ne);function Ne(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Oe}var ze="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)},Ee={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:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),-n*Math.pow(2,10*--t)*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?n*Math.pow(2,10*--t)*Math.sin((t-e)*(2*Math.PI)/.4)*-.5:n*Math.pow(2,-10*--t)*Math.sin((t-e)*(2*Math.PI)/.4)*.5+1)},backIn:function(t){return t*t*(2.70158*t-1.70158)},backOut:function(t){return--t*t*(2.70158*t+1.70158)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((1+e)*t-e)*.5:.5*((t-=2)*t*((1+e)*t+e)+2)},bounceIn:function(t){return 1-Ee.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*Ee.bounceIn(2*t):.5*Ee.bounceOut(2*t-1)+.5}},Ve=Ee,Be=(Xe.prototype.step=function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),!this._paused){(n=(t-this._startTime-this._pausedTime)/this._life)<0&&(n=0);var n=Math.min(n,1),i=this.easing,i="string"==typeof i?Ve[i]:i,i="function"==typeof i?i(n):n;if(this.onframe&&this.onframe(i),1===n){if(!this.loop)return!0;this._restart(t),this.onrestart&&this.onrestart()}return!1}this._pausedTime+=e},Xe.prototype._restart=function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0},Xe.prototype.pause=function(){this._paused=!0},Xe.prototype.resume=function(){this._paused=!1},Xe),Fe=function(t){this.value=t},Ge=(Ye.prototype.insert=function(t){t=new Fe(t);return this.insertEntry(t),t},Ye.prototype.insertEntry=function(t){this.head?((this.tail.next=t).prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},Ye.prototype.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--},Ye.prototype.len=function(){return this._len},Ye.prototype.clear=function(){this.head=this.tail=null,this._len=0},Ye),He=(Ue.prototype.put=function(t,e){var n,i,o=this._list,r=this._map,a=null;return null==r[t]&&(i=o.len(),n=this._lastRemovedEntry,i>=this._maxSize&&0<i&&(i=o.head,o.remove(i),delete r[i.key],a=i.value,this._lastRemovedEntry=i),n?n.value=e:n=new Fe(e),n.key=t,o.insertEntry(n),r[t]=n),a},Ue.prototype.get=function(t){var e=this._map[t],t=this._list;if(null!=e)return e!==t.tail&&(t.remove(e),t.insertEntry(e)),e.value},Ue.prototype.clear=function(){this._list.clear(),this._map={}},Ue.prototype.len=function(){return this._list.len()},Ue),We={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function Ue(t){this._list=new Ge,this._maxSize=10,this._map={},this._maxSize=t}function Ye(){this._len=0}function Xe(t){this._initialized=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,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}function Ze(t){return(t=Math.round(t))<0?0:255<t?255:t}function je(t){return t<0?0:1<t?1:t}function qe(t){return t.length&&"%"===t.charAt(t.length-1)?Ze(parseFloat(t)/100*255):Ze(parseInt(t,10))}function Ke(t){return t.length&&"%"===t.charAt(t.length-1)?je(parseFloat(t)/100):je(parseFloat(t))}function Je(t,e,n){return n<0?n+=1:1<n&&--n,6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function Qe(t,e,n){return t+(e-t)*n}function $e(t,e,n,i,o){return t[0]=e,t[1]=n,t[2]=i,t[3]=o,t}function tn(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var en=new He(20),nn=null;function on(t,e){nn&&tn(nn,e),nn=en.put(t,nn||e.slice())}function rn(t,e){if(t){e=e||[];var n=en.get(t);if(n)return tn(e,n);var i=(t+="").replace(/ /g,"").toLowerCase();if(i in We)return tn(e,We[i]),on(t,e),e;var o=i.length;if("#"!==i.charAt(0)){var r=i.indexOf("("),a=i.indexOf(")");if(-1!==r&&a+1===o){var n=i.substr(0,r),s=i.substr(r+1,a-(r+1)).split(","),l=1;switch(n){case"rgba":if(4!==s.length)return 3===s.length?$e(e,+s[0],+s[1],+s[2],1):$e(e,0,0,0,1);l=Ke(s.pop());case"rgb":return 3!==s.length?void $e(e,0,0,0,1):($e(e,qe(s[0]),qe(s[1]),qe(s[2]),l),on(t,e),e);case"hsla":return 4!==s.length?void $e(e,0,0,0,1):(s[3]=Ke(s[3]),an(s,e),on(t,e),e);case"hsl":return 3!==s.length?void $e(e,0,0,0,1):(an(s,e),on(t,e),e);default:return}}$e(e,0,0,0,1)}else{if(4===o||5===o){var u=parseInt(i.slice(1,4),16);return 0<=u&&u<=4095?($e(e,(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,5===o?parseInt(i.slice(4),16)/15:1),on(t,e),e):void $e(e,0,0,0,1)}if(7===o||9===o)return 0<=(u=parseInt(i.slice(1,7),16))&&u<=16777215?($e(e,(16711680&u)>>16,(65280&u)>>8,255&u,9===o?parseInt(i.slice(7),16)/255:1),on(t,e),e):void $e(e,0,0,0,1)}}}function an(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=Ke(t[1]),o=Ke(t[2]),i=o<=.5?o*(i+1):o+i-o*i,o=2*o-i;return $e(e=e||[],Ze(255*Je(o,i,n+1/3)),Ze(255*Je(o,i,n)),Ze(255*Je(o,i,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function sn(t,e){var n=rn(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0,255<n[i]?n[i]=255:n[i]<0&&(n[i]=0);return pn(n,4===n.length?"rgba":"rgb")}}function ln(t){t=rn(t);if(t)return((1<<24)+(t[0]<<16)+(t[1]<<8)+ +t[2]).toString(16).slice(1)}function un(t,e,n){if(e&&e.length&&0<=t&&t<=1){n=n||[];var i=t*(e.length-1),o=Math.floor(i),r=Math.ceil(i),t=e[o],r=e[r],o=i-o;return n[0]=Ze(Qe(t[0],r[0],o)),n[1]=Ze(Qe(t[1],r[1],o)),n[2]=Ze(Qe(t[2],r[2],o)),n[3]=je(Qe(t[3],r[3],o)),n}}function hn(t,e,n,i){var o=rn(t);if(t)return o=function(t){if(t){var e,n,i,o=t[0]/255,r=t[1]/255,a=t[2]/255,s=Math.min(o,r,a),l=Math.max(o,r,a),u=l-s,h=(l+s)/2;0==u?n=e=0:(n=h<.5?u/(l+s):u/(2-l-s),i=((l-o)/6+u/2)/u,s=((l-r)/6+u/2)/u,u=((l-a)/6+u/2)/u,o===l?e=u-s:r===l?e=1/3+i-u:a===l&&(e=2/3+s-i),e<0&&(e+=1),1<e&&--e);h=[360*e,n,h];return null!=t[3]&&h.push(t[3]),h}}(o),null!=e&&(o[0]=(e=e,(e=Math.round(e))<0?0:360<e?360:e)),null!=n&&(o[1]=Ke(n)),null!=i&&(o[2]=Ke(i)),pn(an(o),"rgba")}function cn(t,e){t=rn(t);if(t&&null!=e)return t[3]=je(e),pn(t,"rgba")}function pn(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 dn(t,e){t=rn(t);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}var fn=Array.prototype.slice;function gn(t,e,n){return(e-t)*n+t}function yn(t,e,n,i){for(var o=e.length,r=0;r<o;r++)t[r]=gn(e[r],n[r],i)}function mn(t,e,n,i){for(var o=e.length,r=0;r<o;r++)t[r]=e[r]+n[r]*i;return t}function vn(t,e,n,i){for(var o=e.length,r=o&&e[0].length,a=0;a<o;a++){t[a]||(t[a]=[]);for(var s=0;s<r;s++)t[a][s]=e[a][s]+n[a][s]*i}return t}function xn(t,e){var n=t.length;if(n===e.length){for(var i=0;i<n;i++)if(t[i]!==e[i])return;return 1}}function _n(t,e,n,i,o,r,a){t=.5*(n-t),i=.5*(i-e);return(2*(e-n)+t+i)*a+(-3*(e-n)-2*t-i)*r+t*o+e}function bn(t,e,n,i,o,r,a,s){for(var l=e.length,u=0;u<l;u++)t[u]=_n(e[u],n[u],i[u],o[u],r,a,s)}function wn(t){if(F(t)){var e=t.length;if(F(t[0])){for(var n=[],i=0;i<e;i++)n.push(fn.call(t[i]));return n}return fn.call(t)}return t}function Sn(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}var Mn,In,Tn=[0,0,0,0],Cn=(En.prototype.isFinished=function(){return this._finished},En.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},En.prototype.needsAnimate=function(){return!this._isAllValueEqual&&2<=this.keyframes.length&&this.interpolable&&0<this.maxTime},En.prototype.getAdditiveTrack=function(){return this._additiveTrack},En.prototype.addKeyframe=function(t,e){t>=this.maxTime?this.maxTime=t:this._needsSort=!0;var n=this.keyframes,i=n.length;if(this.interpolable)if(F(e)){var o,r=F((r=e)&&r[0])?2:1;if(0<i&&this.arrDim!==r)return void(this.interpolable=!1);if(1==r&&"number"!=typeof e[0]||2==r&&"number"!=typeof e[0][0])return void(this.interpolable=!1);0<i&&(o=n[i-1],this._isAllValueEqual&&(1==r&&xn(e,o.value)||(this._isAllValueEqual=!1))),this.arrDim=r}else{if(0<this.arrDim)return void(this.interpolable=!1);if("string"==typeof e){r=rn(e);r?(e=r,this.isValueColor=!0):this.interpolable=!1}else if("number"!=typeof e||isNaN(e))return void(this.interpolable=!1);this._isAllValueEqual&&0<i&&(o=n[i-1],(this.isValueColor&&!xn(o.value,e)||o.value!==e)&&(this._isAllValueEqual=!1))}e={time:t,value:e,percent:0};return this.keyframes.push(e),e},En.prototype.prepare=function(t){var e=this.keyframes;this._needsSort&&e.sort(function(t,e){return t.time-e.time});for(var n=this.arrDim,i=e.length,o=e[i-1],r=0;r<i;r++)e[r].percent=e[r].time/this.maxTime,0<n&&r!==i-1&&function(t,e,n){var i=t,o=e;if(i.push&&o.push){var e=i.length,r=o.length;if(e!==r)if(r<e)i.length=r;else for(var a=e;a<r;a++)i.push(1===n?o[a]:fn.call(o[a]));for(var s=i[0]&&i[0].length,a=0;a<i.length;a++)if(1===n)isNaN(i[a])&&(i[a]=o[a]);else for(var l=0;l<s;l++)isNaN(i[a][l])&&(i[a][l]=o[a][l])}}(e[r].value,o.value,n);if(t&&this.needsAnimate()&&t.needsAnimate()&&n===t.arrDim&&this.isValueColor===t.isValueColor&&!t._finished){this._additiveTrack=t;for(var a=e[0].value,r=0;r<i;r++)0===n?this.isValueColor?e[r].additiveValue=mn([],e[r].value,a,-1):e[r].additiveValue=e[r].value-a:1===n?e[r].additiveValue=mn([],e[r].value,a,-1):2===n&&(e[r].additiveValue=vn([],e[r].value,a,-1))}},En.prototype.step=function(t,e){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=null!=this._additiveTrack,i=n?"additiveValue":"value",o=this.keyframes,r=this.keyframes.length,a=this.propName,s=this.arrDim,l=this.isValueColor;if(e<0)u=0;else if(e<this._lastFramePercent){for(var u=Math.min(this._lastFrame+1,r-1);0<=u&&!(o[u].percent<=e);u--);u=Math.min(u,r-2)}else{for(u=this._lastFrame;u<r&&!(o[u].percent>e);u++);u=Math.min(u-1,r-2)}var h,c,p,d,f,g,y,m=o[u+1],v=o[u];v&&m&&(this._lastFrame=u,this._lastFramePercent=e,0!=(g=m.percent-v.percent)&&(h=(e-v.percent)/g,c=n?this._additiveValue:l?Tn:t[a],(0<s||l)&&!c&&(c=this._additiveValue=[]),this.useSpline?(p=o[u][i],d=o[0===u?u:u-1][i],f=o[r-2<u?r-1:u+1][i],g=o[r-3<u?r-1:u+2][i],0<s?(1===s?bn:function(t,e,n,i,o,r,a,s){for(var l=e.length,u=e[0].length,h=0;h<l;h++){t[h]||(t[1]=[]);for(var c=0;c<u;c++)t[h][c]=_n(e[h][c],n[h][c],i[h][c],o[h][c],r,a,s)}})(c,d,p,f,g,h,h*h,h*h*h):l?(bn(c,d,p,f,g,h,h*h,h*h*h),n||(t[a]=Sn(c))):(y=void 0,y=this.interpolable?_n(d,p,f,g,h,h*h,h*h*h):f,n?this._additiveValue=y:t[a]=y)):0<s?(1===s?yn:function(t,e,n,i){for(var o=e.length,r=o&&e[0].length,a=0;a<o;a++){t[a]||(t[a]=[]);for(var s=0;s<r;s++)t[a][s]=gn(e[a][s],n[a][s],i)}})(c,v[i],m[i],h):l?(yn(c,v[i],m[i],h),n||(t[a]=Sn(c))):(y=void 0,y=this.interpolable?gn(v[i],m[i],h):(v=v[i],i=m[i],.5<h?i:v),n?this._additiveValue=y:t[a]=y),n&&this._addToTarget(t)))}},En.prototype._addToTarget=function(t){var e=this.arrDim,n=this.propName,i=this._additiveValue;0===e?this.isValueColor?(rn(t[n],Tn),mn(Tn,Tn,i,1),t[n]=Sn(Tn)):t[n]=t[n]+i:1===e?mn(t[n],t[n],i,1):2===e&&vn(t[n],t[n],i,1)},En),Dn=(zn.prototype.getTarget=function(){return this._target},zn.prototype.changeTarget=function(t){this._target=t},zn.prototype.when=function(t,e){return this.whenWithKeys(t,e,Y(e))},zn.prototype.whenWithKeys=function(t,e,n){for(var i=this._tracks,o=0;o<n.length;o++){var r=n[o];if(!(s=i[r])){var a,s=i[r]=new Cn(r),l=void 0,u=this._getAdditiveTrack(r);if(u?(l=(a=u.keyframes[u.keyframes.length-1])&&a.value,u.isValueColor&&l&&(l=Sn(l))):l=this._target[r],null==l)continue;0!==t&&s.addKeyframe(0,wn(l)),this._trackKeys.push(r)}s.addKeyframe(t,wn(e[r]))}return this._maxTime=Math.max(this._maxTime,t),this},zn.prototype.pause=function(){this._clip.pause(),this._paused=!0},zn.prototype.resume=function(){this._clip.resume(),this._paused=!1},zn.prototype.isPaused=function(){return!!this._paused},zn.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,n=0;n<e;n++)t[n].call(this)},zn.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,e=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,e)for(var n=0;n<e.length;n++)e[n].call(this)},zn.prototype._setTracksFinished=function(){for(var t=this._tracks,e=this._trackKeys,n=0;n<e.length;n++)t[e[n]].setFinished()},zn.prototype._getAdditiveTrack=function(t){var e,n=this._additiveAnimators;if(n)for(var i=0;i<n.length;i++){var o=n[i].getTrack(t);o&&(e=o)}return e},zn.prototype.start=function(t,e){if(!(0<this._started)){this._started=1;for(var r=this,a=[],n=0;n<this._trackKeys.length;n++){var i=this._trackKeys[n],o=this._tracks[i],s=this._getAdditiveTrack(i),i=o.keyframes;o.prepare(s),o.needsAnimate()?a.push(o):o.interpolable||(i=i[i.length-1])&&(r._target[o.propName]=i.value)}return a.length||e?(e=new Be({life:this._maxTime,loop:this._loop,delay:this._delay,onframe:function(t){r._started=2;var e=r._additiveAnimators;if(e){for(var n=!1,i=0;i<e.length;i++)if(e[i]._clip){n=!0;break}n||(r._additiveAnimators=null)}for(i=0;i<a.length;i++)a[i].step(r._target,t);var o=r._onframeCbs;if(o)for(i=0;i<o.length;i++)o[i](r._target,t)},ondestroy:function(){r._doneCallback()}}),this._clip=e,this.animation&&this.animation.addClip(e),t&&"spline"!==t&&(e.easing=t)):this._doneCallback(),this}},zn.prototype.stop=function(t){var e;this._clip&&(e=this._clip,t&&e.onframe(1),this._abortedCallback())},zn.prototype.delay=function(t){return this._delay=t,this},zn.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},zn.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},zn.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},zn.prototype.getClip=function(){return this._clip},zn.prototype.getTrack=function(t){return this._tracks[t]},zn.prototype.stopTracks=function(t,e){if(!t.length||!this._clip)return!0;for(var n=this._tracks,i=this._trackKeys,o=0;o<t.length;o++){var r=n[t[o]];r&&(e?r.step(this._target,1):1===this._started&&r.step(this._target,0),r.setFinished())}for(var a=!0,o=0;o<i.length;o++)if(!n[i[o]].isFinished()){a=!1;break}return a&&this._abortedCallback(),a},zn.prototype.saveFinalToTarget=function(t,e){if(t){e=e||this._trackKeys;for(var n=0;n<e.length;n++){var i,o=e[n],r=this._tracks[o];!r||r.isFinished()||(i=(i=r.keyframes)[i.length-1])&&(i=wn(i.value),r.isValueColor&&(i=Sn(i)),t[o]=i)}}},zn.prototype.__changeFinalValue=function(t,e){e=e||Y(t);for(var n=0;n<e.length;n++){var i,o=e[n],r=this._tracks[o];!r||1<(i=r.keyframes).length&&(i=i.pop(),r.addKeyframe(i.time,t[o]),r.prepare(r.getAdditiveTrack()))}},zn),An=(wt(Nn,In=Gt),Nn.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._clipsHead?((this._clipsTail.next=t).prev=this._clipsTail,t.next=null,this._clipsTail=t):this._clipsHead=this._clipsTail=t,t.animation=this},Nn.prototype.addAnimator=function(t){t.animation=this;t=t.getClip();t&&this.addClip(t)},Nn.prototype.removeClip=function(t){var e,n;t.animation&&(e=t.prev,n=t.next,e?e.next=n:this._clipsHead=n,n?n.prev=e:this._clipsTail=e,t.next=t.prev=t.animation=null)},Nn.prototype.removeAnimator=function(t){var e=t.getClip();e&&this.removeClip(e),t.animation=null},Nn.prototype.update=function(t){for(var e=(new Date).getTime()-this._pausedTime,n=e-this._time,i=this._clipsHead;i;)var o=i.next,i=(i.step(e,n)&&(i.ondestroy&&i.ondestroy(),this.removeClip(i)),o);this._time=e,t||(this.onframe(n),this.trigger("frame",n),this.stage.update&&this.stage.update())},Nn.prototype._startLoop=function(){var e=this;this._running=!0,ze(function t(){e._running&&(ze(t),e._paused||e.update())})},Nn.prototype.start=function(){this._running||(this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop())},Nn.prototype.stop=function(){this._running=!1},Nn.prototype.pause=function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},Nn.prototype.resume=function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},Nn.prototype.clear=function(){for(var t=this._clipsHead;t;){var e=t.next;t.prev=t.next=t.animation=null,t=e}this._clipsHead=this._clipsTail=null},Nn.prototype.isFinished=function(){return null==this._clipsHead},Nn.prototype.animate=function(t,e){e=e||{},this.start();e=new Dn(t,e.loop);return this.addAnimator(e),e},Nn),kn=w.domSupported,Ln=(Mn={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:fs=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:H(fs,function(t){var e=t.replace("mouse","pointer");return Mn.hasOwnProperty(e)?e:t})}),Pn=["mousemove","mouseup"],On=["pointermove","pointerup"],Rn=!1;function Nn(t){var e=In.call(this)||this;return e._running=!1,e._time=0,e._pausedTime=0,e._pauseStart=0,e._paused=!1,e.stage=(t=t||{}).stage||{},e.onframe=t.onframe||function(){},e}function zn(t,e,n){this._tracks={},this._trackKeys=[],this._delay=0,this._maxTime=0,this._paused=!1,this._started=0,this._clip=null,this._target=t,(this._loop=e)&&n?L("Can' use additive animation on looped animation."):this._additiveAnimators=n}function En(t){this.keyframes=[],this.maxTime=0,this.arrDim=0,this.interpolable=!0,this._needsSort=!1,this._isAllValueEqual=!0,this._lastFrame=0,this._lastFramePercent=0,this.propName=t}function Vn(t){t=t.pointerType;return"pen"===t||"touch"===t}function Bn(t){t&&(t.zrByTouch=!0)}function Fn(t,e){for(var n=e,i=!1;n&&9!==n.nodeType&&!(i=n.domBelongToZr||n!==e&&n===t.painterRoot);)n=n.parentNode;return i}var Gn=function(t,e){this.stopPropagation=_t,this.stopImmediatePropagation=_t,this.preventDefault=_t,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY},Hn={mousedown:function(t){t=ie(this.dom,t),this.__mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=ie(this.dom,t);var e=this.__mayPointerCapture;!e||t.zrX===e[0]&&t.zrY===e[1]||this.__togglePointerCapture(!0),this.trigger("mousemove",t)},mouseup:function(t){t=ie(this.dom,t),this.__togglePointerCapture(!1),this.trigger("mouseup",t)},mouseout:function(t){Fn(this,(t=ie(this.dom,t)).toElement||t.relatedTarget)||(this.__pointerCapturing&&(t.zrEventControl="no_globalout"),this.trigger("mouseout",t))},wheel:function(t){Rn=!0,t=ie(this.dom,t),this.trigger("mousewheel",t)},mousewheel:function(t){Rn||(t=ie(this.dom,t),this.trigger("mousewheel",t))},touchstart:function(t){Bn(t=ie(this.dom,t)),this.__lastTouchMoment=new Date,this.handler.processGesture(t,"start"),Hn.mousemove.call(this,t),Hn.mousedown.call(this,t)},touchmove:function(t){Bn(t=ie(this.dom,t)),this.handler.processGesture(t,"change"),Hn.mousemove.call(this,t)},touchend:function(t){Bn(t=ie(this.dom,t)),this.handler.processGesture(t,"end"),Hn.mouseup.call(this,t),+new Date-+this.__lastTouchMoment<300&&Hn.click.call(this,t)},pointerdown:function(t){Hn.mousedown.call(this,t)},pointermove:function(t){Vn(t)||Hn.mousemove.call(this,t)},pointerup:function(t){Hn.mouseup.call(this,t)},pointerout:function(t){Vn(t)||Hn.mouseout.call(this,t)}};G(["click","dblclick","contextmenu"],function(e){Hn[e]=function(t){t=ie(this.dom,t),this.trigger(e,t)}});var Wn={pointermove:function(t){Vn(t)||Wn.mousemove.call(this,t)},pointerup:function(t){Wn.mouseup.call(this,t)},mousemove:function(t){this.trigger("mousemove",t)},mouseup:function(t){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",t),e&&(t.zrEventControl="only_globalout",this.trigger("mouseout",t))}};function Un(i,o){var r=o.domHandlers;w.pointerEventsSupported?G(Ln.pointer,function(e){Xn(o,e,function(t){r[e].call(i,t)})}):(w.touchEventsSupported&&G(Ln.touch,function(n){Xn(o,n,function(t){var e;r[n].call(i,t),(e=o).touching=!0,null!=e.touchTimer&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)})}),G(Ln.mouse,function(e){Xn(o,e,function(t){t=ne(t),o.touching||r[e].call(i,t)})}))}function Yn(i,o){function t(n){Xn(o,n,function(t){var e;t=ne(t),Fn(i,t.target)||(e=t,t=ie(i.dom,new Gn(i,e),!0),o.domHandlers[n].call(i,t))},{capture:!0})}w.pointerEventsSupported?G(On,t):w.touchEventsSupported||G(Pn,t)}function Xn(t,e,n,i){t.mounted[e]=n,t.listenerOpts[e]=i,oe(t.domTarget,e,n,i)}function Zn(t){var e,n,i,o,r,a=t.mounted;for(e in a)a.hasOwnProperty(e)&&(n=t.domTarget,i=e,o=a[e],r=t.listenerOpts[e],Jt?n.removeEventListener(i,o,r):n.detachEvent("on"+i,o));t.mounted={}}var jn,qn=function(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e},Kn=(wt(Qn,jn=Gt),Qn.prototype.dispose=function(){Zn(this._localHandlerScope),kn&&Zn(this._globalHandlerScope)},Qn.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},Qn.prototype.__togglePointerCapture=function(t){var e;this.__mayPointerCapture=null,kn&&+this.__pointerCapturing^+t&&(this.__pointerCapturing=t,e=this._globalHandlerScope,t?Yn(this,e):Zn(e))},Qn),Jn=1;function Qn(t,e){var n=jn.call(this)||this;return n.__pointerCapturing=!1,n.dom=t,n.painterRoot=e,n._localHandlerScope=new qn(t,Hn),kn&&(n._globalHandlerScope=new qn(document,Wn)),Un(n,n._localHandlerScope),n}var $n=Jn="undefined"!=typeof window?Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1):Jn,ti="#333",ei="#ccc";function ni(){return[1,0,0,1,0,0]}function ii(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function oi(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 ri(t,e,n){var i=e[0]*n[0]+e[2]*n[1],o=e[1]*n[0]+e[3]*n[1],r=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],e=e[1]*n[4]+e[3]*n[5]+e[5];return t[0]=i,t[1]=o,t[2]=r,t[3]=a,t[4]=s,t[5]=e,t}function ai(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 si(t,e,n){var i=e[0],o=e[2],r=e[4],a=e[1],s=e[3],l=e[5],e=Math.sin(n),n=Math.cos(n);return t[0]=i*n+a*e,t[1]=-i*e+a*n,t[2]=o*n+s*e,t[3]=-o*e+n*s,t[4]=n*r+e*l,t[5]=n*l-e*r,t}function li(t,e,n){var i=n[0],n=n[1];return t[0]=e[0]*i,t[1]=e[1]*n,t[2]=e[2]*i,t[3]=e[3]*n,t[4]=e[4]*i,t[5]=e[5]*n,t}function ui(t,e){var n=e[0],i=e[2],o=e[4],r=e[1],a=e[3],s=e[5],e=n*a-r*i;return e?(t[0]=a*(e=1/e),t[1]=-r*e,t[2]=-i*e,t[3]=n*e,t[4]=(i*s-a*o)*e,t[5]=(r*o-n*s)*e,t):null}var hi=ii;function ci(t){return 5e-5<t||t<-5e-5}var pi,di,fi=[],gi=[],yi=ni(),mi=Math.abs,vi=(Ni.prototype.getLocalTransform=function(t){return Ni.getLocalTransform(this,t)},Ni.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},Ni.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},Ni.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},Ni.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},Ni.prototype.needLocalTransform=function(){return ci(this.rotation)||ci(this.x)||ci(this.y)||ci(this.scaleX-1)||ci(this.scaleY-1)},Ni.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),n=this.transform;e||t?(n=n||ni(),e?this.getLocalTransform(n):hi(n),t&&(e?ri(n,t,n):oi(n,t)),this.transform=n,this._resolveGlobalScaleRatio(n)):n&&hi(n)},Ni.prototype._resolveGlobalScaleRatio=function(t){var e,n,i=this.globalScaleRatio;null!=i&&1!==i&&(this.getGlobalScale(fi),n=((fi[1]-(e=fi[1]<0?-1:1))*i+e)/fi[1]||0,t[0]*=e=((fi[0]-(e=fi[0]<0?-1:1))*i+e)/fi[0]||0,t[1]*=e,t[2]*=n,t[3]*=n),this.invTransform=this.invTransform||ni(),ui(this.invTransform,t)},Ni.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},Ni.prototype.setLocalTransform=function(t){var e,n,i,o;t&&(o=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],e=Math.atan2(t[1],t[0]),n=Math.PI/2+e-Math.atan2(t[3],t[2]),i=Math.sqrt(i)*Math.cos(n),o=Math.sqrt(o),this.skewX=n,this.skewY=0,this.rotation=-e,this.x=+t[4],this.y=+t[5],this.scaleX=o,this.scaleY=i,this.originX=0,this.originY=0)},Ni.prototype.decomposeTransform=function(){var t,e,n;this.transform&&(n=this.parent,t=this.transform,n&&n.transform&&(ri(gi,n.invTransform,t),t=gi),e=this.originX,n=this.originY,(e||n)&&(yi[4]=e,yi[5]=n,ri(gi,t,yi),gi[4]-=e,gi[5]-=n,t=gi),this.setLocalTransform(t))},Ni.prototype.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[0]=1,t[1]=1),t},Ni.prototype.transformCoordToLocal=function(t,e){t=[t,e],e=this.invTransform;return e&&zt(t,t,e),t},Ni.prototype.transformCoordToGlobal=function(t,e){t=[t,e],e=this.transform;return e&&zt(t,t,e),t},Ni.prototype.getLineScale=function(){var t=this.transform;return t&&1e-10<mi(t[0]-1)&&1e-10<mi(t[3]-1)?Math.sqrt(mi(t[0]*t[3]-t[2]*t[1])):1},Ni.prototype.copyTransform=function(t){for(var e=0;e<xi.length;e++){var n=xi[e];this[n]=t[n]}},Ni.getLocalTransform=function(t,e){e=e||[];var n=t.originX||0,i=t.originY||0,o=t.scaleX,r=t.scaleY,a=t.rotation||0,s=t.x,l=t.y,u=t.skewX?Math.tan(t.skewX):0,t=t.skewY?Math.tan(-t.skewY):0;return n||i?(e[4]=-n*o-u*i*r,e[5]=-i*r-t*n*o):e[4]=e[5]=0,e[0]=o,e[3]=r,e[1]=t*o,e[2]=u*r,a&&si(e,e,a),e[4]+=n+s,e[5]+=i+l,e},Ni.initDefaultProps=((fu=Ni.prototype).x=0,fu.y=0,fu.scaleX=1,fu.scaleY=1,fu.originX=0,fu.originY=0,fu.skewX=0,fu.skewY=0,fu.rotation=0,void(fu.globalScaleRatio=1)),Ni),xi=["x","y","originX","originY","rotation","scaleX","scaleY","skewX","skewY"],_i=vi,bi=(Ri.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},Ri.prototype.clone=function(){return new Ri(this.x,this.y)},Ri.prototype.set=function(t,e){return this.x=t,this.y=e,this},Ri.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},Ri.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},Ri.prototype.scale=function(t){this.x*=t,this.y*=t},Ri.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},Ri.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},Ri.prototype.dot=function(t){return this.x*t.x+this.y*t.y},Ri.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},Ri.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},Ri.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},Ri.prototype.distance=function(t){var e=this.x-t.x,t=this.y-t.y;return Math.sqrt(e*e+t*t)},Ri.prototype.distanceSquare=function(t){var e=this.x-t.x,t=this.y-t.y;return e*e+t*t},Ri.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},Ri.prototype.transform=function(t){if(t){var e=this.x,n=this.y;return this.x=t[0]*e+t[2]*n+t[4],this.y=t[1]*e+t[3]*n+t[5],this}},Ri.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},Ri.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},Ri.set=function(t,e,n){t.x=e,t.y=n},Ri.copy=function(t,e){t.x=e.x,t.y=e.y},Ri.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},Ri.lenSquare=function(t){return t.x*t.x+t.y*t.y},Ri.dot=function(t,e){return t.x*e.x+t.y*e.y},Ri.add=function(t,e,n){t.x=e.x+n.x,t.y=e.y+n.y},Ri.sub=function(t,e,n){t.x=e.x-n.x,t.y=e.y-n.y},Ri.scale=function(t,e,n){t.x=e.x*n,t.y=e.y*n},Ri.scaleAndAdd=function(t,e,n,i){t.x=e.x+n.x*i,t.y=e.y+n.y*i},Ri.lerp=function(t,e,n,i){var o=1-i;t.x=o*e.x+i*n.x,t.y=o*e.y+i*n.y},Ri),wi=Math.min,Si=Math.max,Mi=new bi,Ii=new bi,Ti=new bi,Ci=new bi,Di=new bi,Ai=new bi,ki=(Oi.prototype.union=function(t){var e=wi(t.x,this.x),n=wi(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Si(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=Si(t.y+t.height,this.y+this.height)-n:this.height=t.height,this.x=e,this.y=n},Oi.prototype.applyTransform=function(t){Oi.applyTransform(this,this,t)},Oi.prototype.calculateTransform=function(t){var e=t.width/this.width,n=t.height/this.height,i=ni();return ai(i,i,[-this.x,-this.y]),li(i,i,[e,n]),ai(i,i,[t.x,t.y]),i},Oi.prototype.intersect=function(t,e){if(!t)return!1;t instanceof Oi||(t=Oi.create(t));var n,i,o,r,a,s,l,u=this.x,h=this.x+this.width,c=this.y,p=this.y+this.height,d=t.x,f=t.x+t.width,g=t.y,y=t.y+t.height,m=!(h<d||f<u||p<g||y<c);return e&&(n=1/0,i=0,o=Math.abs(h-d),r=Math.abs(f-u),a=Math.abs(p-g),s=Math.abs(y-c),l=Math.min(o,r),t=Math.min(a,s),h<d||f<u?i<l&&(i=l,o<r?bi.set(Ai,-o,0):bi.set(Ai,r,0)):l<n&&(n=l,o<r?bi.set(Di,o,0):bi.set(Di,-r,0)),p<g||y<c?i<t&&(i=t,a<s?bi.set(Ai,0,-a):bi.set(Ai,0,s)):l<n&&(n=l,a<s?bi.set(Di,0,a):bi.set(Di,0,-s))),e&&bi.copy(e,m?Di:Ai),m},Oi.prototype.contain=function(t,e){return t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height},Oi.prototype.clone=function(){return new Oi(this.x,this.y,this.width,this.height)},Oi.prototype.copy=function(t){Oi.copy(this,t)},Oi.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},Oi.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},Oi.prototype.isZero=function(){return 0===this.width||0===this.height},Oi.create=function(t){return new Oi(t.x,t.y,t.width,t.height)},Oi.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},Oi.applyTransform=function(t,e,n){if(n){if(n[1]<1e-5&&-1e-5<n[1]&&n[2]<1e-5&&-1e-5<n[2]){var i=n[0],o=n[3],r=n[4],a=n[5];return t.x=e.x*i+r,t.y=e.y*o+a,t.width=e.width*i,t.height=e.height*o,t.width<0&&(t.x+=t.width,t.width=-t.width),void(t.height<0&&(t.y+=t.height,t.height=-t.height))}Mi.x=Ti.x=e.x,Mi.y=Ci.y=e.y,Ii.x=Ci.x=e.x+e.width,Ii.y=Ti.y=e.y+e.height,Mi.transform(n),Ci.transform(n),Ii.transform(n),Ti.transform(n),t.x=wi(Mi.x,Ii.x,Ti.x,Ci.x),t.y=wi(Mi.y,Ii.y,Ti.y,Ci.y);o=Si(Mi.x,Ii.x,Ti.x,Ci.x),n=Si(Mi.y,Ii.y,Ti.y,Ci.y);t.width=o-t.x,t.height=n-t.y}else t!==e&&Oi.copy(t,e)},Oi),Li={},Pi="12px sans-serif";function Oi(t,e,n,i){n<0&&(t+=n,n=-n),i<0&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}function Ri(t,e){this.x=t||0,this.y=e||0}function Ni(){}var zi={measureText:function(t,e){return pi=pi||E().getContext("2d"),di!==e&&(di=pi.font=e||Pi),pi.measureText(t)}};function Ei(t,e){var n=Li[e=e||Pi],i=(n=n||(Li[e]=new He(500))).get(t);return null==i&&(i=zi.measureText(t,e).width,n.put(t,i)),i}function Vi(t,e,n,i){t=Ei(t,e),e=Hi(e),n=Fi(0,t,n),i=Gi(0,e,i);return new ki(n,i,t,e)}function Bi(t,e,n,i){var o=((t||"")+"").split("\n");if(1===o.length)return Vi(o[0],e,n,i);for(var r=new ki(0,0,0,0),a=0;a<o.length;a++){var s=Vi(o[a],e,n,i);0===a?r.copy(s):r.union(s)}return r}function Fi(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function Gi(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function Hi(t){return Ei("国",t)}function Wi(t,e){return"string"==typeof t?0<=t.lastIndexOf("%")?parseFloat(t)/100*e:parseFloat(t):t}function Ui(t,e,n){var i=e.position||"inside",o=null!=e.distance?e.distance:5,r=n.height,a=n.width,s=r/2,l=n.x,u=n.y,h="left",c="top";if(i instanceof Array)l+=Wi(i[0],n.width),u+=Wi(i[1],n.height),c=h=null;else switch(i){case"left":l-=o,u+=s,h="right",c="middle";break;case"right":l+=o+a,u+=s,c="middle";break;case"top":l+=a/2,u-=o,h="center",c="bottom";break;case"bottom":l+=a/2,u+=r+o,h="center";break;case"inside":l+=a/2,u+=s,h="center",c="middle";break;case"insideLeft":l+=o,u+=s,c="middle";break;case"insideRight":l+=a-o,u+=s,h="right",c="middle";break;case"insideTop":l+=a/2,u+=o,h="center";break;case"insideBottom":l+=a/2,u+=r-o,h="center",c="bottom";break;case"insideTopLeft":l+=o,u+=o;break;case"insideTopRight":l+=a-o,u+=o,h="right";break;case"insideBottomLeft":l+=o,u+=r-o,c="bottom";break;case"insideBottomRight":l+=a-o,u+=r-o,h="right",c="bottom"}return(t=t||{}).x=l,t.y=u,t.align=h,t.verticalAlign=c,t}var Yi="__zr_normal__",Xi=["x","y","scaleX","scaleY","originX","originY","rotation","ignore"],Zi={x:!0,y:!0,scaleX:!0,scaleY:!0,originX:!0,originY:!0,rotation:!0,ignore:!1},ji={},qi=new ki(0,0,0,0),Ki=(Ji.prototype._init=function(t){this.attr(t)},Ji.prototype.drift=function(t,e,n){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var i=this.transform;(i=i||(this.transform=[1,0,0,1,0,0]))[4]+=t,i[5]+=e,this.decomposeTransform(),this.markRedraw()},Ji.prototype.beforeUpdate=function(){},Ji.prototype.afterUpdate=function(){},Ji.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},Ji.prototype.updateInnerText=function(t){var e,n,i,o,r,a,s,l,u,h,c=this._textContent;!c||c.ignore&&!t||(this.textConfig||(this.textConfig={}),a=(e=this.textConfig).local,o=i=void 0,n=!1,(u=c.innerTransformable).parent=a?this:null,l=!1,u.copyTransform(c),null!=e.position&&(s=qi,e.layoutRect?s.copy(e.layoutRect):s.copy(this.getBoundingRect()),a||s.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(ji,e,s):Ui(ji,e,s),u.x=ji.x,u.y=ji.y,i=ji.align,o=ji.verticalAlign,(r=e.origin)&&null!=e.rotation&&(h=t=void 0,h="center"===r?(t=.5*s.width,.5*s.height):(t=Wi(r[0],s.width),Wi(r[1],s.height)),l=!0,u.originX=-u.x+t+(a?0:s.x),u.originY=-u.y+h+(a?0:s.y))),null!=e.rotation&&(u.rotation=e.rotation),(h=e.offset)&&(u.x+=h[0],u.y+=h[1],l||(u.originX=-h[0],u.originY=-h[1])),a=null==e.inside?"string"==typeof e.position&&0<=e.position.indexOf("inside"):e.inside,s=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),h=u=l=void 0,a&&this.canBeInsideText()?(l=e.insideFill,u=e.insideStroke,null!=l&&"auto"!==l||(l=this.getInsideTextFill()),null!=u&&"auto"!==u||(u=this.getInsideTextStroke(l),h=!0)):(l=e.outsideFill,u=e.outsideStroke,null!=l&&"auto"!==l||(l=this.getOutsideFill()),null!=u&&"auto"!==u||(u=this.getOutsideStroke(l),h=!0)),(l=l||"#000")===s.fill&&u===s.stroke&&h===s.autoStroke&&i===s.align&&o===s.verticalAlign||(n=!0,s.fill=l,s.stroke=u,s.autoStroke=h,s.align=i,s.verticalAlign=o,c.setDefaultTextStyle(s)),c.__dirty|=ke,n&&c.dirtyStyle(!0))},Ji.prototype.canBeInsideText=function(){return!0},Ji.prototype.getInsideTextFill=function(){return"#fff"},Ji.prototype.getInsideTextStroke=function(t){return"#000"},Ji.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?ei:ti},Ji.prototype.getOutsideStroke=function(t){for(var e=this.__zr&&this.__zr.getBackgroundColor(),n="string"==typeof e&&rn(e),i=(n=n||[255,255,255,1])[3],o=this.__zr.isDarkMode(),r=0;r<3;r++)n[r]=n[r]*i+(o?0:255)*(1-i);return n[3]=1,pn(n,"rgba")},Ji.prototype.traverse=function(t,e){},Ji.prototype.attrKV=function(t,e){"textConfig"===t?this.setTextConfig(e):"textContent"===t?this.setTextContent(e):"clipPath"===t?this.setClipPath(e):"extra"===t?(this.extra=this.extra||{},N(this.extra,e)):this[t]=e},Ji.prototype.hide=function(){this.ignore=!0,this.markRedraw()},Ji.prototype.show=function(){this.ignore=!1,this.markRedraw()},Ji.prototype.attr=function(t,e){if("string"==typeof t)this.attrKV(t,e);else if($(t))for(var n=Y(t),i=0;i<n.length;i++){var o=n[i];this.attrKV(o,t[o])}return this.markRedraw(),this},Ji.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var e=this._normalState,n=0;n<this.animators.length;n++){var i=this.animators[n],o=i.__fromStateTransition;o&&o!==Yi||(o=(o=i.targetName)?e[o]:e,i.saveFinalToTarget(o))}},Ji.prototype._innerSaveToNormal=function(t){var e=(e=this._normalState)||(this._normalState={});t.textConfig&&!e.textConfig&&(e.textConfig=this.textConfig),this._savePrimaryToNormal(t,e,Xi)},Ji.prototype._savePrimaryToNormal=function(t,e,n){for(var i=0;i<n.length;i++){var o=n[i];null==t[o]||o in e||(e[o]=this[o])}},Ji.prototype.hasState=function(){return 0<this.currentStates.length},Ji.prototype.getState=function(t){return this.states[t]},Ji.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},Ji.prototype.clearStates=function(t){this.useState(Yi,!1,t)},Ji.prototype.useState=function(t,e,n,i){var o=t===Yi;if(this.hasState()||!o){var r,a=this.currentStates,s=this.stateTransition;if(!(0<=V(a,t))||!e&&1!==a.length){if((r=(r=this.stateProxy&&!o?this.stateProxy(t):r)||this.states&&this.states[t])||o){o||this.saveCurrentToNormalState(r);a=!!(r&&r.hoverLayer||i);a&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,r,this._normalState,e,!n&&!this.__inHover&&s&&0<s.duration,s);i=this._textContent,s=this._textGuide;return i&&i.useState(t,e,n,a),s&&s.useState(t,e,n,a),o?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!a&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~ke),r}L("State "+t+" not exists.")}}},Ji.prototype.useStates=function(t,e,n){if(t.length){var i=[],o=this.currentStates,r=t.length,a=r===o.length;if(a)for(var s=0;s<r;s++)if(t[s]!==o[s]){a=!1;break}if(!a){for(s=0;s<r;s++){var l=t[s],u=void 0;(u=(u=this.stateProxy?this.stateProxy(l,t):u)||this.states[l])&&i.push(u)}var h=i[r-1],c=!!(h&&h.hoverLayer||n);c&&this._toggleHoverLayerFlag(!0);h=this._mergeStates(i),n=this.stateTransition;this.saveCurrentToNormalState(h),this._applyStateObj(t.join(","),h,this._normalState,!1,!e&&!this.__inHover&&n&&0<n.duration,n);h=this._textContent,n=this._textGuide;h&&h.useStates(t,e,c),n&&n.useStates(t,e,c),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~ke)}}else this.clearStates()},Ji.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var e=this.animators[t];e.targetName&&e.changeTarget(this[e.targetName])}},Ji.prototype.removeState=function(t){var e=V(this.currentStates,t);0<=e&&((t=this.currentStates.slice()).splice(e,1),this.useStates(t))},Ji.prototype.replaceState=function(t,e,n){var i=this.currentStates.slice(),o=V(i,t),t=0<=V(i,e);0<=o?t?i.splice(o,1):i[o]=e:n&&!t&&i.push(e),this.useStates(i)},Ji.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},Ji.prototype._mergeStates=function(t){for(var e,n={},i=0;i<t.length;i++){var o=t[i];N(n,o),o.textConfig&&N(e=e||{},o.textConfig)}return e&&(n.textConfig=e),n},Ji.prototype._applyStateObj=function(t,e,n,i,o,r){var a=!(e&&i);e&&e.textConfig?(this.textConfig=N({},(i?this:n).textConfig),N(this.textConfig,e.textConfig)):a&&n.textConfig&&(this.textConfig=n.textConfig);for(var s={},l=!1,u=0;u<Xi.length;u++){var h=Xi[u],c=o&&Zi[h];e&&null!=e[h]?c?(l=!0,s[h]=e[h]):this[h]=e[h]:a&&null!=n[h]&&(c?(l=!0,s[h]=n[h]):this[h]=n[h])}if(!o)for(u=0;u<this.animators.length;u++){var p=this.animators[u],d=p.targetName;p.__changeFinalValue(d?(e||n)[d]:e||n)}l&&this._transitionState(t,s,r)},Ji.prototype._attachComponent=function(t){if(t.__zr&&!t.__hostTarget)throw new Error("Text element has been added to zrender.");if(t===this)throw new Error("Recursive component attachment.");var e=this.__zr;e&&t.addSelfToZr(e),t.__zr=e,t.__hostTarget=this},Ji.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},Ji.prototype.getClipPath=function(){return this._clipPath},Ji.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},Ji.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},Ji.prototype.getTextContent=function(){return this._textContent},Ji.prototype.setTextContent=function(t){var e=this._textContent;if(e!==t){if(e&&e!==t&&this.removeTextContent(),t.__zr&&!t.__hostTarget)throw new Error("Text element has been added to zrender.");t.innerTransformable=new _i,this._attachComponent(t),this._textContent=t,this.markRedraw()}},Ji.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),N(this.textConfig,t),this.markRedraw()},Ji.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},Ji.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},Ji.prototype.getTextGuideLine=function(){return this._textGuide},Ji.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},Ji.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},Ji.prototype.markRedraw=function(){this.__dirty|=ke;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},Ji.prototype.dirty=function(){this.markRedraw()},Ji.prototype._toggleHoverLayerFlag=function(t){this.__inHover=t;var e=this._textContent,n=this._textGuide;e&&(e.__inHover=t),n&&(n.__inHover=t)},Ji.prototype.addSelfToZr=function(t){if(this.__zr!==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),this._textContent&&this._textContent.addSelfToZr(t),this._textGuide&&this._textGuide.addSelfToZr(t)}},Ji.prototype.removeSelfFromZr=function(t){if(this.__zr){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),this._textContent&&this._textContent.removeSelfFromZr(t),this._textGuide&&this._textGuide.removeSelfFromZr(t)}},Ji.prototype.animate=function(t,e){var n=t?this[t]:this;if(n){e=new Dn(n,e);return this.addAnimator(e,t),e}L('Property "'+t+'" is not existed in element '+this.id)},Ji.prototype.addAnimator=function(n,t){var e=this.__zr,i=this;n.during(function(){i.updateDuringAnimation(t)}).done(function(){var t=i.animators,e=V(t,n);0<=e&&t.splice(e,1)}),this.animators.push(n),e&&e.animation.addAnimator(n),e&&e.wakeUp()},Ji.prototype.updateDuringAnimation=function(t){this.markRedraw()},Ji.prototype.stopAnimation=function(t,e){for(var n=this.animators,i=n.length,o=[],r=0;r<i;r++){var a=n[r];t&&t!==a.scope?o.push(a):a.stop(e)}return this.animators=o,this},Ji.prototype.animateTo=function(t,e,n){Qi(this,t,e,n)},Ji.prototype.animateFrom=function(t,e,n){Qi(this,t,e,n,!0)},Ji.prototype._transitionState=function(t,e,n,i){for(var o=Qi(this,e,n,i),r=0;r<o.length;r++)o[r].__fromStateTransition=t},Ji.prototype.getBoundingRect=function(){return null},Ji.prototype.getPaintRect=function(){return null},Ji.initDefaultProps=function(){var t=Ji.prototype;t.type="element",t.name="",t.ignore=!1,t.silent=!1,t.isGroup=!1,t.draggable=!1,t.dragging=!1,t.ignoreClip=!1,t.__inHover=!1,t.__dirty=ke;var i={};function a(t,e,n){i[t+e+n]||(i[t+e+n]=!0)}function e(e,n,i,o){function r(e,t){Object.defineProperty(t,0,{get:function(){return e[i]},set:function(t){e[i]=t}}),Object.defineProperty(t,1,{get:function(){return e[o]},set:function(t){e[o]=t}})}Object.defineProperty(t,e,{get:function(){var t;return a(e,i,o),this[n]||(t=this[n]=[],r(this,t)),this[n]},set:function(t){a(e,i,o),this[i]=t[0],this[o]=t[1],this[n]=t,r(this,t)}})}Object.defineProperty&&(!w.browser.ie||8<w.browser.version)&&(e("position","_legacyPos","x","y"),e("scale","_legacyScale","scaleX","scaleY"),e("origin","_legacyOrigin","originX","originY"))}(),Ji);function Ji(t){this.id=k++,this.animators=[],this.currentStates=[],this.states={},this._init(t)}function Qi(t,e,n,i,o){var r=[];!function t(e,n,i,o,r,a,s,l){for(var u=[],h=[],c=Y(o),p=r.duration,d=r.delay,f=r.additive,g=r.setToFinal,y=!$(a),m=0;m<c.length;m++){var v=c[m];null!=i[v]&&null!=o[v]&&(y||a[v])?$(o[v])&&!F(o[v])?n?l||(i[v]=o[v],e.updateDuringAnimation(n)):t(e,v,i[v],o[v],r,a&&a[v],s,l):(u.push(v),h.push(v)):l||(i[v]=o[v],e.updateDuringAnimation(n),h.push(v))}var x=u.length;if(0<x||r.force&&!s.length){for(var _=e.animators,b=[],w=0;w<_.length;w++)_[w].targetName===n&&b.push(_[w]);if(!f&&b.length)for(w=0;w<b.length;w++){var S=b[w].stopTracks(h);S&&(S=V(_,b[w]),_.splice(S,1))}var M=void 0,I=void 0,T=void 0;if(l)for(I={},g&&(M={}),w=0;w<x;w++)v=u[w],I[v]=i[v],g?M[v]=o[v]:i[v]=o[v];else if(g)for(T={},w=0;w<x;w++)v=u[w],T[v]=wn(i[v]),to(i,o,v);f=new Dn(i,!1,f?b:null);f.targetName=n,r.scope&&(f.scope=r.scope),g&&M&&f.whenWithKeys(0,M,u),T&&f.whenWithKeys(0,T,u),f.whenWithKeys(null==p?500:p,l?I:o,u).delay(d||0),e.addAnimator(f,n),s.push(f)}}(t,"",t,e,n=n||{},i,r,o);function a(){u=!0,--l<=0&&(u?h&&h():c&&c())}function s(){--l<=0&&(u?h&&h():c&&c())}var l=r.length,u=!1,h=n.done,c=n.aborted;l||h&&h(),0<r.length&&n.during&&r[0].during(function(t,e){n.during(e)});for(var p=0;p<r.length;p++){var d=r[p];d.done(a),d.aborted(s),d.start(n.easing,n.force)}return r}function $i(t,e,n){for(var i=0;i<n;i++)t[i]=e[i]}function to(t,e,n){if(F(e[n]))if(F(t[n])||(t[n]=[]),et(e[n])){var i=e[n].length;t[n].length!==i&&(t[n]=new e[n].constructor(i),$i(t[n],e[n],i))}else{var o=e[n],r=t[n],a=o.length;if(F(o[0]))for(var s=o[0].length,l=0;l<a;l++)r[l]?$i(r[l],o[l],s):r[l]=Array.prototype.slice.call(o[l]);else $i(r,o,a);r.length=o.length}else t[n]=e[n]}B(Ki,Gt),B(Ki,_i);var eo,no=Ki,io=(wt(oo,eo=no),oo.prototype.childrenRef=function(){return this._children},oo.prototype.children=function(){return this._children.slice()},oo.prototype.childAt=function(t){return this._children[t]},oo.prototype.childOfName=function(t){for(var e=this._children,n=0;n<e.length;n++)if(e[n].name===t)return e[n]},oo.prototype.childCount=function(){return this._children.length},oo.prototype.add=function(t){if(t&&(t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),t.__hostTarget))throw"This elemenet has been used as an attachment";return this},oo.prototype.addBefore=function(t,e){var n;return t&&t!==this&&t.parent!==this&&e&&e.parent===this&&(0<=(e=(n=this._children).indexOf(e))&&(n.splice(e,0,t),this._doAdd(t))),this},oo.prototype.replace=function(t,e){t=V(this._children,t);return 0<=t&&this.replaceAt(e,t),this},oo.prototype.replaceAt=function(t,e){var n=this._children,i=n[e];return t&&t!==this&&t.parent!==this&&t!==i&&(n[e]=t,i.parent=null,(e=this.__zr)&&i.removeSelfFromZr(e),this._doAdd(t)),this},oo.prototype._doAdd=function(t){t.parent&&t.parent.remove(t);var e=(t.parent=this).__zr;e&&e!==t.__zr&&t.addSelfToZr(e),e&&e.refresh()},oo.prototype.remove=function(t){var e=this.__zr,n=this._children,i=V(n,t);return i<0||(n.splice(i,1),t.parent=null,e&&t.removeSelfFromZr(e),e&&e.refresh()),this},oo.prototype.removeAll=function(){for(var t=this._children,e=this.__zr,n=0;n<t.length;n++){var i=t[n];e&&i.removeSelfFromZr(e),i.parent=null}return t.length=0,this},oo.prototype.eachChild=function(t,e){for(var n=this._children,i=0;i<n.length;i++){var o=n[i];t.call(e,o,i)}return this},oo.prototype.traverse=function(t,e){for(var n=0;n<this._children.length;n++){var i=this._children[n],o=t.call(e,i);i.isGroup&&!o&&i.traverse(t,e)}return this},oo.prototype.addSelfToZr=function(t){eo.prototype.addSelfToZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].addSelfToZr(t)},oo.prototype.removeSelfFromZr=function(t){eo.prototype.removeSelfFromZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].removeSelfFromZr(t)},oo.prototype.getBoundingRect=function(t){for(var e=new ki(0,0,0,0),n=t||this._children,i=[],o=null,r=0;r<n.length;r++){var a,s=n[r];s.ignore||s.invisible||(a=s.getBoundingRect(),(s=s.getLocalTransform(i))?(ki.applyTransform(e,a,s),(o=o||e.clone()).union(e)):(o=o||a.clone()).union(a))}return o||e},oo);function oo(t){var e=eo.call(this)||this;return e.isGroup=!0,e._children=[],e.attr(t),e}io.prototype.type="group";var ro=io,ao=!w.canvasSupported,so={},lo={};var uo=(ho.prototype.add=function(t){t&&(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},ho.prototype.remove=function(t){t&&(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},ho.prototype.configLayer=function(t,e){this.painter.configLayer&&this.painter.configLayer(t,e),this.refresh()},ho.prototype.setBackgroundColor=function(t){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=function(t){if(!t)return!1;if("string"==typeof t)return dn(t,1)<.4;if(t.colorStops){for(var e=t.colorStops,n=0,i=e.length,o=0;o<i;o++)n+=dn(e[o].color,1);return(n/=i)<.4}return!1}(t)},ho.prototype.getBackgroundColor=function(){return this._backgroundColor},ho.prototype.setDarkMode=function(t){this._darkMode=t},ho.prototype.isDarkMode=function(){return this._darkMode},ho.prototype.refreshImmediately=function(t){t||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1},ho.prototype.refresh=function(){this._needsRefresh=!0,this.animation.start()},ho.prototype.flush=function(){this._flush(!1)},ho.prototype._flush=function(t){var e,n=(new Date).getTime();this._needsRefresh&&(e=!0,this.refreshImmediately(t)),this._needsRefreshHover&&(e=!0,this.refreshHoverImmediately());t=(new Date).getTime();e?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:t-n})):0<this._sleepAfterStill&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},ho.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},ho.prototype.wakeUp=function(){this.animation.start(),this._stillFrameAccum=0},ho.prototype.addHover=function(t){},ho.prototype.removeHover=function(t){},ho.prototype.clearHover=function(){},ho.prototype.refreshHover=function(){this._needsRefreshHover=!0},ho.prototype.refreshHoverImmediately=function(){this._needsRefreshHover=!1,this.painter.refreshHover&&"canvas"===this.painter.getType()&&this.painter.refreshHover()},ho.prototype.resize=function(t){this.painter.resize((t=t||{}).width,t.height),this.handler.resize()},ho.prototype.clearAnimation=function(){this.animation.clear()},ho.prototype.getWidth=function(){return this.painter.getWidth()},ho.prototype.getHeight=function(){return this.painter.getHeight()},ho.prototype.pathToImage=function(t,e){if(this.painter.pathToImage)return this.painter.pathToImage(t,e)},ho.prototype.setCursorStyle=function(t){this.handler.setCursorStyle(t)},ho.prototype.findHover=function(t,e){return this.handler.findHover(t,e)},ho.prototype.on=function(t,e,n){return this.handler.on(t,e,n),this},ho.prototype.off=function(t,e){this.handler.off(t,e)},ho.prototype.trigger=function(t,e){this.handler.trigger(t,e)},ho.prototype.clear=function(){for(var t=this.storage.getRoots(),e=0;e<t.length;e++)t[e]instanceof ro&&t[e].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()},ho.prototype.dispose=function(){var t;this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,t=this.id,delete lo[t]},ho);function ho(t,e,n){var i=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=e,this.id=t;var o=new Re,r=n.renderer||"canvas";if(ao)throw new Error("IE8 support has been dropped since 5.0");if(so[r]||(r=Y(so)[0]),!so[r])throw new Error("Renderer '"+r+"' is not imported. Please import it first.");n.useDirtyRect=null!=n.useDirtyRect&&n.useDirtyRect;n=new so[r](e,o,n,t);this.storage=o,this.painter=n;t=w.node||w.worker?null:new Kn(n.getViewportRoot(),n.root);this.handler=new be(o,n,t,n.root),this.animation=new An({stage:{update:function(){return i._flush(!0)}}}),this.animation.start()}function co(t,e){e=new uo(k++,t,e);return lo[e.id]=e}var po=20;function fo(t,e,n,i){var o=e[0],r=e[1],a=n[0],s=n[1],e=r-o,n=s-a;if(0==e)return 0==n?a:(a+s)/2;if(i)if(0<e){if(t<=o)return a;if(r<=t)return s}else{if(o<=t)return a;if(t<=r)return s}else{if(t===o)return a;if(t===r)return s}return(t-o)/e*n+a}function go(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?t.replace(/^\s+|\s+$/g,"").match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function yo(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),po),t=(+t).toFixed(e),n?t:+t}function mo(t){return t.sort(function(t,e){return t-e}),t}function vo(t){if(t=+t,isNaN(t))return 0;if(1e-14<t)for(var e=1,n=0;n<15;n++,e*=10)if(Math.round(t*e)/e===t)return n;return o=(i=t).toString().toLowerCase(),r=o.indexOf("e"),i=0<r?+o.slice(r+1):0,r=0<r?r:o.length,o=(o=o.indexOf("."))<0?0:r-1-o,Math.max(0,o-i);var i,o,r}function xo(t,e){var n=Math.log,i=Math.LN10,t=Math.floor(n(t[1]-t[0])/i),i=Math.round(n(Math.abs(e[1]-e[0]))/i),i=Math.min(Math.max(-t+i,0),20);return isFinite(i)?i:20}var _o=9007199254740991;function bo(t){var e=2*Math.PI;return(t%e+e)%e}function wo(t){return-1e-4<t&&t<1e-4}var So=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function Mo(t){if(t instanceof Date)return t;if("string"!=typeof t)return null==t?new Date(NaN):new Date(Math.round(t));var e=So.exec(t);if(!e)return new Date(NaN);if(e[8]){t=+e[4]||0;return"Z"!==e[8].toUpperCase()&&(t-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,t,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))}return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0)}function Io(t){if(0===t)return 0;var e=Math.floor(Math.log(t)/Math.LN10);return 10<=t/Math.pow(10,e)&&e++,e}function To(t,e){var n=Io(t),i=Math.pow(10,n),o=t/i;return t=(e?o<1.5?1:o<2.5?2:o<4?3:o<7?5:10:o<1?1:o<2?2:o<3?3:o<5?5:10)*i,-20<=n?+t.toFixed(n<0?-n:0):t}function Co(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),e=+t[i-1],n=n-i;return n?e+n*(t[i]-e):e}function Do(t){t.sort(function(t,e){return function t(e,n,i){return e.interval[i]<n.interval[i]||e.interval[i]===n.interval[i]&&(e.close[i]-n.close[i]==(i?-1:1)||!i&&t(e,n,1))}(t,e,0)?-1:1});for(var e=-1/0,n=1,i=0;i<t.length;){for(var o=t[i].interval,r=t[i].close,a=0;a<2;a++)o[a]<=e&&(o[a]=e,r[a]=a?1:1-n),e=o[a],n=r[a];o[0]===o[1]&&r[0]*r[1]!=1?t.splice(i,1):i++}return t}function Ao(t){var e=parseFloat(t);return e==t&&(0!==e||"string"!=typeof t||t.indexOf("x")<=0)?e:NaN}function ko(t){return!isNaN(Ao(t))}function Lo(){return Math.round(9*Math.random())}function Po(t,e){return null==t?e:null==e?t:t*e/function t(e,n){return 0===n?e:t(n,e%n)}(t,e)}var Oo="series\0",Ro="\0_ec_\0";function No(t){return t instanceof Array?t:null==t?[]:[t]}function zo(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,o=n.length;i<o;i++){var r=n[i];!t.emphasis[e].hasOwnProperty(r)&&t[e].hasOwnProperty(r)&&(t.emphasis[e][r]=t[e][r])}}}var Eo=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function Vo(t){return!$(t)||j(t)||t instanceof Date?t:t.value}function Bo(t,n,e){var i="normalMerge"===e,o="replaceMerge"===e,r="replaceAll"===e;t=t||[],n=(n||[]).slice();var a=yt();G(n,function(t,e){$(t)||(n[e]=null)});var s,l,u,h,c,p,d,f,g,y,e=function(t,e,n){var i=[];if("replaceAll"===n)return i;for(var o=0;o<t.length;o++){var r=t[o];r&&null!=r.id&&e.set(r.id,o),i.push({existing:"replaceMerge"===n||Uo(r)?null:r,newOption:null,keyInfo:null,brandNew:null})}return i}(t,a,e);return(i||o)&&(d=e,f=t,g=a,G(y=n,function(t,e){var n,i,o;t&&null!=t.id&&(n=Go(t.id),null!=(i=g.get(n))&&(ut(!(o=d[i]).newOption,'Duplicated option on id "'+n+'".'),o.newOption=t,o.existing=f[i],y[e]=null))})),i&&(c=e,G(p=n,function(t,e){if(t&&null!=t.name)for(var n=0;n<c.length;n++){var i=c[n].existing;if(!c[n].newOption&&i&&(null==i.id||null==t.id)&&!Uo(t)&&!Uo(i)&&Fo("name",i,t))return c[n].newOption=t,void(p[e]=null)}})),i||o?(u=e,h=o,G(n,function(t){if(t){for(var e,n=0;(e=u[n])&&(e.newOption||Uo(e.existing)||e.existing&&null!=t.id&&!Fo("id",t,e.existing));)n++;e?(e.newOption=t,e.brandNew=h):u.push({newOption:t,brandNew:h,existing:null,keyInfo:null}),n++}})):r&&(l=e,G(n,function(t){l.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})),r=e,s=yt(),G(r,function(t){var e=t.existing;e&&s.set(e.id,t)}),G(r,function(t){var e=t.newOption;ut(!e||null==e.id||!s.get(e.id)||s.get(e.id)===t,"id duplicates: "+(e&&e.id)),e&&null!=e.id&&s.set(e.id,t),t.keyInfo||(t.keyInfo={})}),G(r,function(t,e){var n=t.existing,i=t.newOption,o=t.keyInfo;if($(i)){if(o.name=null!=i.name?Go(i.name):n?n.name:Oo+e,n)o.id=Go(n.id);else if(null!=i.id)o.id=Go(i.id);else for(var r=0;o.id="\0"+o.name+"\0"+r++,s.get(o.id););s.set(o.id,t)}}),e}function Fo(t,e,n){e=Ho(e[t],null),t=Ho(n[t],null);return null!=e&&null!=t&&e===t}function Go(t){return Ho(t,"")}function Ho(t,e){if(null==t)return e;var n=typeof t;return"string"==n?t:"number"==n||J(t)?t+"":e}function Wo(t){t=t.name;return!(!t||!t.indexOf(Oo))}function Uo(t){return t&&null!=t.id&&0===Go(t.id).indexOf(Ro)}function Yo(t,o,r){G(t,function(t){var e,n,i=t.newOption;$(i)&&(t.keyInfo.mainType=o,t.keyInfo.subType=(e=o,n=i,i=t.existing,t=r,n.type||(i?i.subType:t.determineSubType(e,n))))})}function Xo(e,t){return null!=t.dataIndexInside?t.dataIndexInside:null!=t.dataIndex?j(t.dataIndex)?H(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex):null!=t.name?j(t.name)?H(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name):void 0}function Zo(){var e="__ec_inner_"+jo++;return function(t){return t[e]||(t[e]={})}}var jo=Lo();function qo(n,t,i){var e=Ko(t,i),o=e.mainTypeSpecified,t=e.queryOptionMap,r=e.others,a=i?i.defaultMainType:null;return!o&&a&&t.set(a,{}),t.each(function(t,e){t=$o(n,e,t,{useDefault:a===e,enableAll:!i||null==i.enableAll||i.enableAll,enableNone:!i||null==i.enableNone||i.enableNone});r[e+"Models"]=t.models,r[e+"Model"]=t.models[0]}),r}function Ko(t,o){var e,t=K(t)?((e={})[t+"Index"]=0,e):t,r=yt(),a={},s=!1;return G(t,function(t,e){var n,i;"dataIndex"!==e&&"dataIndexInside"!==e?(n=(i=e.match(/^(\w+)(Index|Id|Name)$/)||[])[1],i=(i[2]||"").toLowerCase(),!n||!i||o&&o.includeMainTypes&&V(o.includeMainTypes,n)<0||(s=s||!!n,(r.get(n)||r.set(n,{}))[i]=t)):a[e]=t}),{mainTypeSpecified:s,queryOptionMap:r,others:a}}var Jo={useDefault:!0,enableAll:!1,enableNone:!1},Qo={useDefault:!1,enableAll:!0,enableNone:!0};function $o(t,e,n,i){i=i||Jo;var o=n.index,r=n.id,a=n.name,n={models:null,specified:null!=o||null!=r||null!=a};if(n.specified)return"none"===o||!1===o?(ut(i.enableNone,'`"none"` or `false` is not a valid value on index option.'),n.models=[]):("all"===o&&(ut(i.enableAll,'`"all"` is not a valid value on index option.'),o=r=a=null),n.models=t.queryComponents({mainType:e,index:o,id:r,name:a})),n;a=void 0;return n.models=i.useDefault&&(a=t.getComponent(e))?[a]:[],n}function tr(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function er(t,n){var i=yt(),o=[];return G(t,function(t){var e=n(t);(i.get(e)||(o.push(e),i.set(e,[]))).push(t)}),{keys:o,buckets:i}}function nr(t,e,n,i,o){var r=null==e||"auto"===e;if(null==i)return i;if("number"==typeof i){var a=gn(n||0,i,o);return yo(a,r?Math.max(vo(n||0),vo(i)):e)}if("string"==typeof i)return o<1?n:i;for(var s=[],l=n,u=i,h=Math.max(l?l.length:0,u.length),c=0;c<h;++c){var p,d=t.getDimensionInfo(c);d&&"ordinal"===d.type?s[c]=(o<1&&l?l:u)[c]:(a=gn(p=l&&l[c]?l[c]:0,d=u[c],o),s[c]=yo(a,r?Math.max(vo(p),vo(d)):e))}return s}var ir=".",or="___EC__COMPONENT__CONTAINER___",rr="___EC__EXTENDED_CLASS___";function ar(t){var e={main:"",sub:""};return t&&(t=t.split(ir),e.main=t[0]||"",e.sub=t[1]||""),e}function sr(t){(t.$constructor=t).extend=function(i){var o=this;function r(){for(var t,e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];if(i.$constructor)i.$constructor.apply(this,arguments);else{if("function"==typeof(t=o)&&/^class\s/.test(Function.prototype.toString.call(t)))return vt(r.prototype,new(o.bind.apply(o,function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o<r;o++)!i&&o in e||((i=i||Array.prototype.slice.call(e,0,o))[o]=e[o]);return t.concat(i||e)}([void 0],e))));o.apply(this,arguments)}}return r[rr]=!0,N(r.prototype,i),r.extend=this.extend,r.superCall=hr,r.superApply=cr,function(t,e){var n,i=t.prototype;function o(){}for(n in o.prototype=e.prototype,t.prototype=new o,i)i.hasOwnProperty(n)&&(t.prototype[n]=i[n]);(t.prototype.constructor=t).superClass=e}(r,this),r.superClass=o,r}}function lr(t,e){t.extend=e.extend}var ur=Math.round(10*Math.random());function hr(t,e){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];return this.superClass.prototype[e].apply(t,n)}function cr(t,e,n){return this.superClass.prototype[e].apply(t,n)}function pr(t){var o={};t.registerClass=function(t){var e,n,i=t.type||t.prototype.type;return i&&(ut(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(n=i),'componentType "'+n+'" illegal'),(e=ar(t.prototype.type=i)).sub?e.sub!==or&&(((i=o[(n=e).main])&&i[or]||((i=o[n.main]={})[or]=!0),i)[e.sub]=t):o[e.main]=t),t},t.getClass=function(t,e,n){var i=o[t];if(i&&i[or]&&(i=e?i[e]:null),n&&!i)throw new Error(e?"Component "+t+"."+(e||"")+" is used but not imported.":t+".type should be specified.");return i},t.getClassesByMainType=function(t){var t=ar(t),n=[],t=o[t.main];return t&&t[or]?G(t,function(t,e){e!==or&&n.push(t)}):n.push(t),n},t.hasClass=function(t){t=ar(t);return!!o[t.main]},t.getAllClassMainTypes=function(){var n=[];return G(o,function(t,e){n.push(e)}),n},t.hasSubTypes=function(t){t=ar(t),t=o[t.main];return t&&t[or]}}function dr(a,s){for(var t=0;t<a.length;t++)a[t][1]||(a[t][1]=a[t][0]);return s=s||!1,function(t,e,n){for(var i={},o=0;o<a.length;o++){var r=a[o][1];e&&0<=V(e,r)||n&&V(n,r)<0||null!=(r=t.getShallow(r,s))&&(i[a[o][0]]=r)}return i}}var fr=dr([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),gr=(mr.prototype.getAreaStyle=function(t,e){return fr(this,t,e)},mr),yr=new He(50);function mr(){}function vr(t,e,n,i,o){if(t){if("string"!=typeof t)return t;if(e&&e.__zrImageSrc===t||!n)return e;var r=yr.get(t),o={hostEl:n,cb:i,cbPayload:o};return r?_r(e=r.image)||r.pending.push(o):((e=new Image).onload=e.onerror=xr,yr.put(t,e.__cachedImgObj={image:e,pending:[o]}),e.src=e.__zrImageSrc=t),e}return e}function xr(){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 _r(t){return t&&t.width&&t.height}var br=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function wr(t,e,n,i){var o=N({},i=i||{});o.font=e,n=rt(n,"..."),o.maxIterations=rt(i.maxIterations,2);var r=o.minChar=rt(i.minChar,0);o.cnCharWidth=Ei("国",e);var a=o.ascCharWidth=Ei("a",e);o.placeholder=rt(i.placeholder,"");for(var s=t=Math.max(0,t-1),l=0;l<r&&a<=s;l++)s-=a;e=Ei(n,e);return s<e&&(n="",e=0),s=t-e,o.ellipsis=n,o.ellipsisWidth=e,o.contentWidth=s,o.containerWidth=t,o}function Sr(t,e){var n=e.containerWidth,i=e.font,o=e.contentWidth;if(!n)return"";if((s=Ei(t,i))<=n)return t;for(var r=0;;r++){if(s<=o||r>=e.maxIterations){t+=e.ellipsis;break}var a=0===r?function(t,e,n,i){for(var o=0,r=0,a=t.length;r<a&&o<e;r++){var s=t.charCodeAt(r);o+=0<=s&&s<=127?n:i}return r}(t,o,e.ascCharWidth,e.cnCharWidth):0<s?Math.floor(t.length*o/s):0,s=Ei(t=t.substr(0,a),i)}return t=""===t?e.placeholder:t}var Mr=function(){},Ir=function(t){this.tokens=[],t&&(this.tokens=t)},Tr=function(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[]};function Cr(t,e){var n=new Tr;if(null!=t&&(t+=""),!t)return n;for(var i,o=e.width,r=e.height,a=e.overflow,s="break"!==a&&"breakAll"!==a||null==o?null:{width:o,accumWidth:0,breakAll:"breakAll"===a},l=br.lastIndex=0;null!=(i=br.exec(t));){var u=i.index;l<u&&Dr(n,t.substring(l,u),e,s),Dr(n,i[2],e,s,i[1]),l=br.lastIndex}l<t.length&&Dr(n,t.substring(l,t.length),e,s);var h=[],c=0,p=0,d=e.padding,f="truncate"===a,g="truncate"===e.lineOverflow;function y(t,e,n){t.width=e,t.lineHeight=n,c+=n,p=Math.max(p,e)}t:for(var m=0;m<n.lines.length;m++){for(var v=n.lines[m],x=0,_=0,b=0;b<v.tokens.length;b++){var w=v.tokens[b],S=w.styleName&&e.rich[w.styleName]||{},M=w.textPadding=S.padding,I=M?M[1]+M[3]:0,T=w.font=S.font||e.font;w.contentHeight=Hi(T);var C=rt(S.height,w.contentHeight);if(w.innerHeight=C,M&&(C+=M[0]+M[2]),w.height=C,w.lineHeight=at(S.lineHeight,e.lineHeight,C),w.align=S&&S.align||e.align,w.verticalAlign=S&&S.verticalAlign||"middle",g&&null!=r&&c+w.lineHeight>r){0<b?(v.tokens=v.tokens.slice(0,b),y(v,_,x),n.lines=n.lines.slice(0,m+1)):n.lines=n.lines.slice(0,m);break t}var D,A=S.width,M=null==A||"auto"===A;"string"==typeof A&&"%"===A.charAt(A.length-1)?(w.percentWidth=A,h.push(w),w.contentWidth=Ei(w.text,T)):(M&&(!(D=(A=S.backgroundColor)&&A.image)||_r(D="string"!=typeof(A=D)?A:(A=yr.get(A))&&A.image)&&(w.width=Math.max(w.width,D.width*C/D.height))),null!=(D=f&&null!=o?o-_:null)&&D<w.width?!M||D<I?(w.text="",w.width=w.contentWidth=0):(w.text=function(t,e,n,i,o){if(!e)return"";var r=(t+"").split("\n");o=wr(e,n,i,o);for(var a=0,s=r.length;a<s;a++)r[a]=Sr(r[a],o);return r.join("\n")}(w.text,D-I,T,e.ellipsis,{minChar:e.truncateMinChar}),w.width=w.contentWidth=Ei(w.text,T)):w.contentWidth=Ei(w.text,T)),w.width+=I,_+=w.width,S&&(x=Math.max(x,w.lineHeight))}y(v,_,x)}for(n.outerWidth=n.width=rt(o,p),n.outerHeight=n.height=rt(r,c),n.contentHeight=c,n.contentWidth=p,d&&(n.outerWidth+=d[1]+d[3],n.outerHeight+=d[0]+d[2]),m=0;m<h.length;m++){var k=(w=h[m]).percentWidth;w.width=parseInt(k,10)/100*n.width}return n}function Dr(t,e,n,i,o){var r,a,s,l=""===e,u=o&&n.rich[o]||{},h=t.lines,c=u.font||n.font,p=!1;i?(n=(n=u.padding)?n[1]+n[3]:0,null!=u.width&&"auto"!==u.width?(s=Wi(u.width,i.width)+n,0<h.length&&s+i.accumWidth>i.width&&(r=e.split("\n"),p=!0),i.accumWidth=s):(s=kr(e,c,i.width,i.breakAll,i.accumWidth),i.accumWidth=s.accumWidth+n,a=s.linesWidths,r=s.lines)):r=e.split("\n");for(var d=0;d<r.length;d++){var f,g,y=r[d],m=new Mr;m.styleName=o,m.text=y,m.isLineHolder=!y&&!l,"number"==typeof u.width?m.width=u.width:m.width=a?a[d]:Ei(y,c),d||p?h.push(new Ir([m])):1===(g=(f=(h[h.length-1]||(h[0]=new Ir)).tokens).length)&&f[0].isLineHolder?f[0]=m:!y&&g&&!l||f.push(m)}}var Ar=W(",&?/;] ".split(""),function(t,e){return t[e]=!0,t},{});function kr(t,e,n,i,o){for(var r,a=[],s=[],l="",u="",h=0,c=0,p=0;p<t.length;p++){var d,f,g=t.charAt(p);"\n"!==g?(d=Ei(g,e),f=!(i||(r=void 0,!(33<=(r=(r=f=g).charCodeAt(0))&&r<=255)||Ar[f])),(a.length?n<c+d:n<o+c+d)?c?(l||u)&&(c=f?(l||(l=u,u="",c=h=0),a.push(l),s.push(c-h),u+=g,l="",h+=d):(u&&(l+=u,c+=h,u="",h=0),a.push(l),s.push(c),l=g,d)):f?(a.push(u),s.push(h),u=g,h=d):(a.push(g),s.push(d)):(c+=d,f?(u+=g,h+=d):(u&&(l+=u,u="",h=0),l+=g))):(u&&(l+=u,c+=h),a.push(l),s.push(c),u=l="",c=h=0)}return a.length||l||(l=t,u="",h=0),u&&(l+=u),l&&(a.push(l),s.push(c)),1===a.length&&(c+=o),{accumWidth:c,lines:a,linesWidths:s}}var Lr="__zr_style_"+Math.round(10*Math.random()),Pr={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},Or={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};Pr[Lr]=!0;var Rr,Nr=["z","z2","invisible"],zr=["invisible"],y=(wt(Br,Rr=no),Br.prototype._init=function(t){for(var e=Y(t),n=0;n<e.length;n++){var i=e[n];"style"===i?this.useStyle(t[i]):Rr.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},Br.prototype.beforeBrush=function(){},Br.prototype.afterBrush=function(){},Br.prototype.innerBeforeBrush=function(){},Br.prototype.innerAfterBrush=function(){},Br.prototype.shouldBePainted=function(t,e,n,i){var o,r=this.transform;if(this.ignore||this.invisible||0===this.style.opacity||this.culling&&(o=this,t=t,e=e,Er.copy(o.getBoundingRect()),o.transform&&Er.applyTransform(o.transform),Vr.width=t,Vr.height=e,!Er.intersect(Vr))||r&&!r[0]&&!r[3])return!1;if(n&&this.__clipPaths)for(var a=0;a<this.__clipPaths.length;++a)if(this.__clipPaths[a].isZeroArea())return!1;if(i&&this.parent)for(var s=this.parent;s;){if(s.ignore)return!1;s=s.parent}return!0},Br.prototype.contain=function(t,e){return this.rectContain(t,e)},Br.prototype.traverse=function(t,e){t.call(e,this)},Br.prototype.rectContain=function(t,e){e=this.transformCoordToLocal(t,e);return this.getBoundingRect().contain(e[0],e[1])},Br.prototype.getPaintRect=function(){var t,e,n,i,o,r=this._paintRect;return this._paintRect&&!this.__dirty||(t=this.transform,e=this.getBoundingRect(),o=(i=this.style).shadowBlur||0,n=i.shadowOffsetX||0,i=i.shadowOffsetY||0,r=this._paintRect||(this._paintRect=new ki(0,0,0,0)),t?ki.applyTransform(r,e,t):r.copy(e),(o||n||i)&&(r.width+=2*o+Math.abs(n),r.height+=2*o+Math.abs(i),r.x=Math.min(r.x,r.x+n-o),r.y=Math.min(r.y,r.y+i-o)),o=this.dirtyRectTolerance,r.isZero()||(r.x=Math.floor(r.x-o),r.y=Math.floor(r.y-o),r.width=Math.ceil(r.width+1+2*o),r.height=Math.ceil(r.height+1+2*o))),r},Br.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new ki(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},Br.prototype.getPrevPaintRect=function(){return this._prevPaintRect},Br.prototype.animateStyle=function(t){return this.animate("style",t)},Br.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():this.markRedraw()},Br.prototype.attrKV=function(t,e){"style"!==t?Rr.prototype.attrKV.call(this,t,e):this.style?this.setStyle(e):this.useStyle(e)},Br.prototype.setStyle=function(t,e){return"string"==typeof t?this.style[t]=e:N(this.style,t),this.dirtyStyle(),this},Br.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=2,this._rect&&(this._rect=null)},Br.prototype.dirty=function(){this.dirtyStyle()},Br.prototype.styleChanged=function(){return!!(2&this.__dirty)},Br.prototype.styleUpdated=function(){this.__dirty&=-3},Br.prototype.createStyle=function(t){return vt(Pr,t)},Br.prototype.useStyle=function(t){t[Lr]||(t=this.createStyle(t)),this.__inHover?this.__hoverStyle=t:this.style=t,this.dirtyStyle()},Br.prototype.isStyleObject=function(t){return t[Lr]},Br.prototype._innerSaveToNormal=function(t){Rr.prototype._innerSaveToNormal.call(this,t);var e=this._normalState;t.style&&!e.style&&(e.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,e,Nr)},Br.prototype._applyStateObj=function(t,e,n,i,o,r){Rr.prototype._applyStateObj.call(this,t,e,n,i,o,r);var a,s=!(e&&i);if(e&&e.style?o?i?a=e.style:(a=this._mergeStyle(this.createStyle(),n.style),this._mergeStyle(a,e.style)):(a=this._mergeStyle(this.createStyle(),(i?this:n).style),this._mergeStyle(a,e.style)):s&&(a=n.style),a)if(o){var l=this.style;if(this.style=this.createStyle(s?{}:l),s)for(var u=Y(l),h=0;h<u.length;h++){var c=u[h];c in a&&(a[c]=a[c],this.style[c]=l[c])}for(var p=Y(a),h=0;h<p.length;h++)c=p[h],this.style[c]=this.style[c];this._transitionState(t,{style:a},r,this.getAnimationStyleProps())}else this.useStyle(a);var d=this.__inHover?zr:Nr;for(h=0;h<d.length;h++)c=d[h],e&&null!=e[c]?this[c]=e[c]:s&&null!=n[c]&&(this[c]=n[c])},Br.prototype._mergeStates=function(t){for(var e,n=Rr.prototype._mergeStates.call(this,t),i=0;i<t.length;i++){var o=t[i];o.style&&this._mergeStyle(e=e||{},o.style)}return e&&(n.style=e),n},Br.prototype._mergeStyle=function(t,e){return N(t,e),t},Br.prototype.getAnimationStyleProps=function(){return Or},Br.initDefaultProps=((mu=Br.prototype).type="displayable",mu.invisible=!1,mu.z=0,mu.z2=0,mu.zlevel=0,mu.culling=!1,mu.cursor="pointer",mu.rectHover=!1,mu.incremental=!1,mu._rect=null,mu.dirtyRectTolerance=0,void(mu.__dirty=2|ke)),Br),Er=new ki(0,0,0,0),Vr=new ki(0,0,0,0);function Br(t){return Rr.call(this,t)||this}var Fr=y,Gr=Math.pow,Hr=Math.sqrt,Wr=1e-8,Ur=1e-4,Yr=Hr(3),Xr=St(),Zr=St(),jr=St();function qr(t){return-Wr<t&&t<Wr}function Kr(t){return Wr<t||t<-Wr}function Jr(t,e,n,i,o){var r=1-o;return r*r*(r*t+3*o*e)+o*o*(o*i+3*r*n)}function Qr(t,e,n,i,o){var r=1-o;return 3*(((e-t)*r+2*(n-e)*o)*r+(i-n)*o*o)}function $r(t,e,n,i,o,r){var a,s,l,u=i+3*(e-n)-t,h=3*(n-2*e+t),i=3*(e-t),n=t-o,e=h*h-3*u*i,t=h*i-9*u*n,o=i*i-3*h*n,n=0;return qr(e)&&qr(t)?qr(h)?r[0]=0:0<=(s=-i/h)&&s<=1&&(r[n++]=s):qr(i=t*t-4*e*o)?(a=-(o=t/e)/2,0<=(s=-h/u+o)&&s<=1&&(r[n++]=s),0<=a&&a<=1&&(r[n++]=a)):0<i?(l=e*h+1.5*u*(-t-(i=Hr(i))),0<=(s=(-h-((i=(i=e*h+1.5*u*(-t+i))<0?-Gr(-i,1/3):Gr(i,1/3))+(l=l<0?-Gr(-l,1/3):Gr(l,1/3))))/(3*u))&&s<=1&&(r[n++]=s)):(l=(2*e*h-3*u*t)/(2*Hr(e*e*e)),t=Math.acos(l)/3,s=(-h-2*(l=Hr(e))*(e=Math.cos(t)))/(3*u),a=(-h+l*(e+Yr*Math.sin(t)))/(3*u),u=(-h+l*(e-Yr*Math.sin(t)))/(3*u),0<=s&&s<=1&&(r[n++]=s),0<=a&&a<=1&&(r[n++]=a),0<=u&&u<=1&&(r[n++]=u)),n}function ta(t,e,n,i,o){var r,a=6*n-12*e+6*t,i=9*e+3*i-3*t-9*n,n=3*e-3*t,e=0;return qr(i)?!Kr(a)||0<=(r=-n/a)&&r<=1&&(o[e++]=r):qr(t=a*a-4*i*n)?o[0]=-a/(2*i):0<t&&(t=(-a-(n=Hr(t)))/(2*i),0<=(r=(-a+n)/(2*i))&&r<=1&&(o[e++]=r),0<=t&&t<=1&&(o[e++]=t)),e}function ea(t,e,n,i,o,r){var a=(e-t)*o+t,s=(n-e)*o+e,e=(i-n)*o+n,n=(s-a)*o+a,s=(e-s)*o+s,o=(s-n)*o+n;r[0]=t,r[1]=a,r[2]=n,r[3]=o,r[4]=o,r[5]=s,r[6]=e,r[7]=i}function na(t,e,n,i,o,r,a,s,l,u,h){var c,p,d,f,g=.005,y=1/0;Xr[0]=l,Xr[1]=u;for(var m=0;m<1;m+=.05)Zr[0]=Jr(t,n,o,a,m),Zr[1]=Jr(e,i,r,s,m),(d=Rt(Xr,Zr))<y&&(c=m,y=d);for(var y=1/0,v=0;v<32&&!(g<Ur);v++)p=c+g,Zr[0]=Jr(t,n,o,a,f=c-g),Zr[1]=Jr(e,i,r,s,f),d=Rt(Zr,Xr),0<=f&&d<y?(c=f,y=d):(jr[0]=Jr(t,n,o,a,p),jr[1]=Jr(e,i,r,s,p),f=Rt(jr,Xr),p<=1&&f<y?(c=p,y=f):g*=.5);return h&&(h[0]=Jr(t,n,o,a,c),h[1]=Jr(e,i,r,s,c)),Hr(y)}function ia(t,e,n,i){var o=1-i;return o*(o*t+2*i*e)+i*i*n}function oa(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function ra(t,e,n){n=t+n-2*e;return 0==n?.5:(t-e)/n}function aa(t,e,n,i,o){var r=(e-t)*i+t,e=(n-e)*i+e,i=(e-r)*i+r;o[0]=t,o[1]=r,o[2]=i,o[3]=i,o[4]=e,o[5]=n}function sa(t,e,n,i,o,r,a,s,l){var u,h=.005,c=1/0;Xr[0]=a,Xr[1]=s;for(var p=0;p<1;p+=.05){Zr[0]=ia(t,n,o,p),Zr[1]=ia(e,i,r,p);var d=Rt(Xr,Zr);d<c&&(u=p,c=d)}for(var c=1/0,f=0;f<32&&!(h<Ur);f++){var g=u-h,y=u+h;Zr[0]=ia(t,n,o,g),Zr[1]=ia(e,i,r,g),d=Rt(Zr,Xr),0<=g&&d<c?(u=g,c=d):(jr[0]=ia(t,n,o,y),jr[1]=ia(e,i,r,y),g=Rt(jr,Xr),y<=1&&g<c?(u=y,c=g):h*=.5)}return l&&(l[0]=ia(t,n,o,u),l[1]=ia(e,i,r,u)),Hr(c)}var la=Math.min,ua=Math.max,ha=Math.sin,ca=Math.cos,pa=2*Math.PI,da=St(),fa=St(),ga=St();function ya(t,e,n){if(0!==t.length){for(var i=t[0],o=i[0],r=i[0],a=i[1],s=i[1],l=1;l<t.length;l++)i=t[l],o=la(o,i[0]),r=ua(r,i[0]),a=la(a,i[1]),s=ua(s,i[1]);e[0]=o,e[1]=a,n[0]=r,n[1]=s}}function ma(t,e,n,i,o,r){o[0]=la(t,n),o[1]=la(e,i),r[0]=ua(t,n),r[1]=ua(e,i)}var va=[],xa=[];var _a={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},ba=[],wa=[],Sa=[],Ma=[],Ia=[],Ta=[],Ca=Math.min,Da=Math.max,Aa=Math.cos,ka=Math.sin,La=Math.sqrt,Pa=Math.abs,Oa=Math.PI,Ra=2*Oa,Na="undefined"!=typeof Float32Array,za=[];function Ea(t){return Math.round(t/Oa*1e8)/1e8%2*Oa}function Va(t,e){var n=Ea(t[0]);n<0&&(n+=Ra);var i=n-t[0],o=t[1];o+=i,!e&&Ra<=o-n?o=n+Ra:e&&Ra<=n-o?o=n-Ra:!e&&o<n?o=n+(Ra-Ea(n-o)):e&&n<o&&(o=n-(Ra-Ea(o-n))),t[0]=n,t[1]=o}var Ba=(Fa.prototype.increaseVersion=function(){this._version++},Fa.prototype.getVersion=function(){return this._version},Fa.prototype.setScale=function(t,e,n){0<(n=n||0)&&(this._ux=Pa(n/$n/t)||0,this._uy=Pa(n/$n/e)||0)},Fa.prototype.setDPR=function(t){this.dpr=t},Fa.prototype.setContext=function(t){this._ctx=t},Fa.prototype.getContext=function(){return this._ctx},Fa.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},Fa.prototype.reset=function(){this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},Fa.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(_a.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},Fa.prototype.lineTo=function(t,e){var n=Pa(t-this._xi),i=Pa(e-this._yi),o=n>this._ux||i>this._uy;return this.addData(_a.L,t,e),this._ctx&&o&&(this._needsDash?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),o?(this._xi=t,this._yi=e,this._pendingPtDist=0):(i=n*n+i*i)>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=i),this},Fa.prototype.bezierCurveTo=function(t,e,n,i,o,r){return this._drawPendingPt(),this.addData(_a.C,t,e,n,i,o,r),this._ctx&&(this._needsDash?this._dashedBezierTo(t,e,n,i,o,r):this._ctx.bezierCurveTo(t,e,n,i,o,r)),this._xi=o,this._yi=r,this},Fa.prototype.quadraticCurveTo=function(t,e,n,i){return this._drawPendingPt(),this.addData(_a.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},Fa.prototype.arc=function(t,e,n,i,o,r){return this._drawPendingPt(),za[0]=i,za[1]=o,Va(za,r),i=za[0],o=za[1],this.addData(_a.A,t,e,n,n,i,o-i,0,r?0:1),this._ctx&&this._ctx.arc(t,e,n,i,o,r),this._xi=Aa(o)*n+t,this._yi=ka(o)*n+e,this},Fa.prototype.arcTo=function(t,e,n,i,o){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,n,i,o),this},Fa.prototype.rect=function(t,e,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,n,i),this.addData(_a.R,t,e,n,i),this},Fa.prototype.closePath=function(){this._drawPendingPt(),this.addData(_a.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},Fa.prototype.fill=function(t){t&&t.fill(),this.toStatic()},Fa.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},Fa.prototype.setLineDash=function(t){if(t instanceof Array){this._lineDash=t;for(var e=this._dashIdx=0,n=0;n<t.length;n++)e+=t[n];this._dashSum=e,this._needsDash=!0}else this._lineDash=null,this._needsDash=!1;return this},Fa.prototype.setLineDashOffset=function(t){return this._dashOffset=t,this},Fa.prototype.len=function(){return this._len},Fa.prototype.setData=function(t){var e=t.length;this.data&&this.data.length===e||!Na||(this.data=new Float32Array(e));for(var n=0;n<e;n++)this.data[n]=t[n];this._len=e},Fa.prototype.appendPath=function(t){for(var e=(t=!(t instanceof Array)?[t]:t).length,n=0,i=this._len,o=0;o<e;o++)n+=t[o].len();for(Na&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n)),o=0;o<e;o++)for(var r=t[o].data,a=0;a<r.length;a++)this.data[i++]=r[a];this._len=i},Fa.prototype.addData=function(t,e,n,i,o,r,a,s,l){if(this._saveData){var u=this.data;this._len+arguments.length>u.length&&(this._expandData(),u=this.data);for(var h=0;h<arguments.length;h++)u[this._len++]=arguments[h]}},Fa.prototype._drawPendingPt=function(){0<this._pendingPtDist&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},Fa.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},Fa.prototype._dashedLineTo=function(t,e){var n,i,o=this._dashSum,r=this._lineDash,a=this._ctx,s=this._dashOffset,l=this._xi,u=this._yi,h=t-l,c=e-u,p=La(h*h+c*c),d=l,f=u,g=r.length;for(s<0&&(s=o+s),d-=(s%=o)*(h/=p),f-=s*(c/=p);0<h&&d<=t||h<0&&t<=d||0===h&&(0<c&&f<=e||c<0&&e<=f);)d+=h*(n=r[i=this._dashIdx]),f+=c*n,this._dashIdx=(i+1)%g,0<h&&d<l||h<0&&l<d||0<c&&f<u||c<0&&u<f||a[i%2?"moveTo":"lineTo"]((0<=h?Ca:Da)(d,t),(0<=c?Ca:Da)(f,e));this._dashOffset=-La((h=d-t)*h+(c=f-e)*c)},Fa.prototype._dashedBezierTo=function(t,e,n,i,o,r){var a,s,l,u,h,c=this._ctx,p=this._dashSum,d=this._dashOffset,f=this._lineDash,g=this._xi,y=this._yi,m=0,v=this._dashIdx,x=f.length,_=0;for(d<0&&(d=p+d),d%=p,a=0;a<1;a+=.1)s=Jr(g,t,n,o,a+.1)-Jr(g,t,n,o,a),l=Jr(y,e,i,r,a+.1)-Jr(y,e,i,r,a),m+=La(s*s+l*l);for(;v<x&&!(d<(_+=f[v]));v++);for(a=(_-d)/m;a<=1;)u=Jr(g,t,n,o,a),h=Jr(y,e,i,r,a),v%2?c.moveTo(u,h):c.lineTo(u,h),a+=f[v]/m,v=(v+1)%x;v%2!=0&&c.lineTo(o,r),this._dashOffset=-La((s=o-u)*s+(l=r-h)*l)},Fa.prototype._dashedQuadraticTo=function(t,e,n,i){var o=n,r=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,o,r)},Fa.prototype.toStatic=function(){var t;this._saveData&&(this._drawPendingPt(),(t=this.data)instanceof Array&&(t.length=this._len,Na&&11<this._len&&(this.data=new Float32Array(t))))},Fa.prototype.getBoundingRect=function(){Sa[0]=Sa[1]=Ia[0]=Ia[1]=Number.MAX_VALUE,Ma[0]=Ma[1]=Ta[0]=Ta[1]=-Number.MAX_VALUE;for(var t,e,n,i,o=this.data,r=0,a=0,s=0,l=0,u=0;u<this._len;){var h=o[u++],c=1===u;switch(c&&(s=r=o[u],l=a=o[u+1]),h){case _a.M:r=s=o[u++],a=l=o[u++],Ia[0]=s,Ia[1]=l,Ta[0]=s,Ta[1]=l;break;case _a.L:ma(r,a,o[u],o[u+1],Ia,Ta),r=o[u++],a=o[u++];break;case _a.C:(function(t,e,n,i,o,r,a,s,l,u){var h=ta,c=Jr,p=h(t,n,o,a,va);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var d=0;d<p;d++){var f=c(t,n,o,a,va[d]);l[0]=la(f,l[0]),u[0]=ua(f,u[0])}for(p=h(e,i,r,s,xa),d=0;d<p;d++){var g=c(e,i,r,s,xa[d]);l[1]=la(g,l[1]),u[1]=ua(g,u[1])}l[0]=la(t,l[0]),u[0]=ua(t,u[0]),l[0]=la(a,l[0]),u[0]=ua(a,u[0]),l[1]=la(e,l[1]),u[1]=ua(e,u[1]),l[1]=la(s,l[1]),u[1]=ua(s,u[1])})(r,a,o[u++],o[u++],o[u++],o[u++],o[u],o[u+1],Ia,Ta),r=o[u++],a=o[u++];break;case _a.Q:p=r,y=a,t=o[u++],e=o[u++],d=o[u],m=o[u+1],n=Ia,g=Ta,v=f=v=f=i=void 0,i=ia,f=ua(la((v=ra)(p,t,d),1),0),v=ua(la(v(y,e,m),1),0),f=i(p,t,d,f),v=i(y,e,m,v),n[0]=la(p,d,f),n[1]=la(y,m,v),g[0]=ua(p,d,f),g[1]=ua(y,m,v),r=o[u++],a=o[u++];break;case _a.A:var p=o[u++],d=o[u++],f=o[u++],g=o[u++],y=o[u++],m=o[u++]+y;u+=1;var v=!o[u++];c&&(s=Aa(y)*f+p,l=ka(y)*g+d),function(t,e,n,i,o,r,a,s,l){var u=Et,h=Vt,c=Math.abs(o-r);if(c%pa<1e-4&&1e-4<c)return s[0]=t-n,s[1]=e-i,l[0]=t+n,l[1]=e+i;da[0]=ca(o)*n+t,da[1]=ha(o)*i+e,fa[0]=ca(r)*n+t,fa[1]=ha(r)*i+e,u(s,da,fa),h(l,da,fa),(o%=pa)<0&&(o+=pa),(r%=pa)<0&&(r+=pa),r<o&&!a?r+=pa:o<r&&a&&(o+=pa),a&&(a=r,r=o,o=a);for(var p=0;p<r;p+=Math.PI/2)o<p&&(ga[0]=ca(p)*n+t,ga[1]=ha(p)*i+e,u(s,ga,s),h(l,ga,l))}(p,d,f,g,y,m,v,Ia,Ta),r=Aa(m)*f+p,a=ka(m)*g+d;break;case _a.R:ma(s=r=o[u++],l=a=o[u++],s+o[u++],l+o[u++],Ia,Ta);break;case _a.Z:r=s,a=l}Et(Sa,Sa,Ia),Vt(Ma,Ma,Ta)}return 0===u&&(Sa[0]=Sa[1]=Ma[0]=Ma[1]=0),new ki(Sa[0],Sa[1],Ma[0]-Sa[0],Ma[1]-Sa[1])},Fa.prototype._calculateLength=function(){var t=this.data,e=this._len,n=this._ux,i=this._uy,o=0,r=0,a=0,s=0;this._pathSegLen||(this._pathSegLen=[]);for(var l=this._pathSegLen,u=0,h=0,c=0;c<e;){var p=t[c++],d=1===c;d&&(a=o=t[c],s=r=t[c+1]);var f=-1;switch(p){case _a.M:o=a=t[c++],r=s=t[c++];break;case _a.L:var g=t[c++],y=t[c++],m=g-o,v=y-r;(Pa(m)>n||Pa(v)>i||c===e-1)&&(f=Math.sqrt(m*m+v*v),o=g,r=y);break;case _a.C:var x=t[c++],_=t[c++],b=(g=t[c++],y=t[c++],t[c++]),w=t[c++],f=function(t,e,n,i,o,r,a,s,l){for(var u=t,h=e,c=0,p=1/l,d=1;d<=l;d++){var f=d*p,g=Jr(t,n,o,a,f),y=Jr(e,i,r,s,f),m=g-u,f=y-h;c+=Math.sqrt(m*m+f*f),u=g,h=y}return c}(o,r,x,_,g,y,b,w,10),o=b,r=w;break;case _a.Q:f=function(t,e,n,i,o,r,a){for(var s=t,l=e,u=0,h=1/a,c=1;c<=a;c++){var p=c*h,d=ia(t,n,o,p),f=ia(e,i,r,p),g=d-s,p=f-l;u+=Math.sqrt(g*g+p*p),s=d,l=f}return u}(o,r,x=t[c++],_=t[c++],g=t[c++],y=t[c++],10),o=g,r=y;break;case _a.A:var S=t[c++],M=t[c++],I=t[c++],T=t[c++],C=t[c++],b=t[c++],w=b+C;c+=1,t[c++],d&&(a=Aa(C)*I+S,s=ka(C)*T+M),f=Da(I,T)*Ca(Ra,Math.abs(b)),o=Aa(w)*I+S,r=ka(w)*T+M;break;case _a.R:a=o=t[c++],s=r=t[c++];f=2*t[c++]+2*t[c++];break;case _a.Z:m=a-o,v=s-r,f=Math.sqrt(m*m+v*v),o=a,r=s}0<=f&&(u+=l[h++]=f)}return this._pathLen=u},Fa.prototype.rebuildPath=function(t,e){var n,i,o,r,a,s,l,u,h=this.data,c=this._ux,p=this._uy,d=this._len,f=e<1,g=0,y=0,m=0;if(!f||(this._pathSegLen||this._calculateLength(),a=this._pathSegLen,s=e*this._pathLen))t:for(var v=0;v<d;){var x=h[v++],_=1===v;switch(_&&(n=o=h[v],i=r=h[v+1]),x!==_a.L&&0<m&&(t.lineTo(l,u),m=0),x){case _a.M:n=o=h[v++],i=r=h[v++],t.moveTo(o,r);break;case _a.L:var b=h[v++],w=h[v++],S=Pa(b-o),M=Pa(w-r);if(c<S||p<M){if(f){var I=a[y++];if(s<g+I){var T=(s-g)/I;t.lineTo(o*(1-T)+b*T,r*(1-T)+w*T);break t}g+=I}t.lineTo(b,w),o=b,r=w,m=0}else{var C=S*S+M*M;m<C&&(l=b,u=w,m=C)}break;case _a.C:var D=h[v++],A=h[v++],k=h[v++],L=h[v++],P=h[v++],O=h[v++];if(f){if(s<g+(I=a[y++])){ea(o,D,k,P,T=(s-g)/I,ba),ea(r,A,L,O,T,wa),t.bezierCurveTo(ba[1],wa[1],ba[2],wa[2],ba[3],wa[3]);break t}g+=I}t.bezierCurveTo(D,A,k,L,P,O),o=P,r=O;break;case _a.Q:if(D=h[v++],A=h[v++],k=h[v++],L=h[v++],f){if(s<g+(I=a[y++])){aa(o,D,k,T=(s-g)/I,ba),aa(r,A,L,T,wa),t.quadraticCurveTo(ba[1],wa[1],ba[2],wa[2]);break t}g+=I}t.quadraticCurveTo(D,A,k,L),o=k,r=L;break;case _a.A:var R=h[v++],N=h[v++],z=h[v++],E=h[v++],V=h[v++],B=h[v++],S=h[v++],M=!h[v++],C=E<z?z:E,P=.001<Pa(z-E),F=V+B,O=!1;if(f&&(s<g+(I=a[y++])&&(F=V+B*(s-g)/I,O=!0),g+=I),P&&t.ellipse?t.ellipse(R,N,z,E,S,V,F,M):t.arc(R,N,C,V,F,M),O)break t;_&&(n=Aa(V)*z+R,i=ka(V)*E+N),o=Aa(F)*z+R,r=ka(F)*E+N;break;case _a.R:n=o=h[v],i=r=h[v+1],b=h[v++],w=h[v++];F=h[v++],E=h[v++];if(f){if(s<g+(I=a[y++])){N=s-g;t.moveTo(b,w),t.lineTo(b+Ca(N,F),w),0<(N-=F)&&t.lineTo(b+F,w+Ca(N,E)),0<(N-=E)&&t.lineTo(b+Da(F-N,0),w+E),0<(N-=F)&&t.lineTo(b,w+Da(E-N,0));break t}g+=I}t.rect(b,w,F,E);break;case _a.Z:if(f){if(s<g+(I=a[y++])){t.lineTo(o*(1-(T=(s-g)/I))+n*T,r*(1-T)+i*T);break t}g+=I}t.closePath(),o=n,r=i}}},Fa.prototype.clone=function(){var t=new Fa,e=this.data;return t.data=e.slice?e.slice():Array.prototype.slice.call(e),t._len=this._len,t},Fa.CMD=_a,Fa.initDefaultProps=((_=Fa.prototype)._saveData=!0,_._needsDash=!1,_._dashOffset=0,_._dashIdx=0,_._dashSum=0,_._ux=0,_._uy=0,_._pendingPtDist=0,void(_._version=0)),Fa);function Fa(t){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,t&&(this._saveData=!1),this._saveData&&(this.data=[])}function Ga(t,e,n,i,o,r,a){if(0!==o){var s=o,o=0;if(!(e+s<a&&i+s<a||a<e-s&&a<i-s||t+s<r&&n+s<r||r<t-s&&r<n-s)){if(t===n)return Math.abs(r-t)<=s/2;n=(o=(e-i)/(t-n))*r-a+(t*i-n*e)/(t-n);return n*n/(o*o+1)<=s/2*s/2}}}function Ha(t,e,n,i,o,r,a,s,l){if(0!==a){a=a;return e+a<l&&i+a<l&&r+a<l||l<e-a&&l<i-a&&l<r-a||t+a<s&&n+a<s&&o+a<s||s<t-a&&s<n-a&&s<o-a?void 0:sa(t,e,n,i,o,r,s,l,null)<=a/2}}var Wa=2*Math.PI;function Ua(t){return(t%=Wa)<0&&(t+=Wa),t}var Ya=2*Math.PI;function Xa(t,e,n,i,o,r){if(e<r&&i<r||r<e&&r<i)return 0;if(i===e)return 0;var a=(r-e)/(i-e),r=i<e?1:-1;1!=a&&0!=a||(r=i<e?.5:-.5);t=a*(n-t)+t;return t===o?1/0:o<t?r:0}var Za=Ba.CMD,ja=2*Math.PI,qa=1e-4;var Ka=[-1,-1,-1],Ja=[-1,-1];function Qa(t,e,n,i,o,r,a,s,l,u){if(e<u&&i<u&&r<u&&s<u||u<e&&u<i&&u<r&&u<s)return 0;var h=$r(e,i,r,s,u,Ka);if(0===h)return 0;for(var c,p=0,d=-1,f=void 0,g=void 0,y=0;y<h;y++){var m=Ka[y],v=0===m||1===m?.5:1;Jr(t,n,o,a,m)<l||(d<0&&(d=ta(e,i,r,s,Ja),Ja[1]<Ja[0]&&1<d&&(c=void 0,c=Ja[0],Ja[0]=Ja[1],Ja[1]=c),f=Jr(e,i,r,s,Ja[0]),1<d&&(g=Jr(e,i,r,s,Ja[1]))),2===d?m<Ja[0]?p+=f<e?v:-v:m<Ja[1]?p+=g<f?v:-v:p+=s<g?v:-v:m<Ja[0]?p+=f<e?v:-v:p+=s<f?v:-v)}return p}function $a(t,e,n,i,o,r,a,s){if(e<s&&i<s&&r<s||s<e&&s<i&&s<r)return 0;var l,u,h,c,p,d,f=(c=Ka,d=(l=e)-2*(u=i)+(h=r),h=2*(u-l),u=l-(s=s),l=0,qr(d)?!Kr(h)||0<=(p=-u/h)&&p<=1&&(c[l++]=p):qr(s=h*h-4*d*u)?0<=(p=-h/(2*d))&&p<=1&&(c[l++]=p):0<s&&(s=(-h-(u=Hr(s)))/(2*d),0<=(p=(-h+u)/(2*d))&&p<=1&&(c[l++]=p),0<=s&&s<=1&&(c[l++]=s)),l);if(0===f)return 0;var g=ra(e,i,r);if(0<=g&&g<=1){for(var y=0,m=ia(e,i,r,g),v=0;v<f;v++){var x=0===Ka[v]||1===Ka[v]?.5:1,_=ia(t,n,o,Ka[v]);_<a||(Ka[v]<g?y+=m<e?x:-x:y+=r<m?x:-x)}return y}return x=0===Ka[0]||1===Ka[0]?.5:1,(_=ia(t,n,o,Ka[0]))<a?0:r<e?x:-x}function ts(t,e,n,i,o){for(var r,a=t.data,s=t.len(),l=0,u=0,h=0,c=0,p=0,d=0;d<s;){var f=a[d++],g=1===d;switch(f===Za.M&&1<d&&(n||(l+=Xa(u,h,c,p,i,o))),g&&(c=u=a[d],p=h=a[d+1]),f){case Za.M:u=c=a[d++],h=p=a[d++];break;case Za.L:if(n){if(Ga(u,h,a[d],a[d+1],e,i,o))return!0}else l+=Xa(u,h,a[d],a[d+1],i,o)||0;u=a[d++],h=a[d++];break;case Za.C:if(n){if(function(t,e,n,i,o,r,a,s,l,u,h){if(0!==l){l=l;return e+l<h&&i+l<h&&r+l<h&&s+l<h||h<e-l&&h<i-l&&h<r-l&&h<s-l||t+l<u&&n+l<u&&o+l<u&&a+l<u||u<t-l&&u<n-l&&u<o-l&&u<a-l?void 0:na(t,e,n,i,o,r,a,s,u,h,null)<=l/2}}(u,h,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],e,i,o))return!0}else l+=Qa(u,h,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],i,o)||0;u=a[d++],h=a[d++];break;case Za.Q:if(n){if(Ha(u,h,a[d++],a[d++],a[d],a[d+1],e,i,o))return!0}else l+=$a(u,h,a[d++],a[d++],a[d],a[d+1],i,o)||0;u=a[d++],h=a[d++];break;case Za.A:var y=a[d++],m=a[d++],v=a[d++],x=a[d++],_=a[d++],b=a[d++];d+=1;var w=!!(1-a[d++]),S=Math.cos(_)*v+y,M=Math.sin(_)*x+m;g?(c=S,p=M):l+=Xa(u,h,S,M,i,o);var I=(i-y)*x/v+y;if(n){if(function(t,e,n,i,o,r,a,s,l){if(0!==a){a=a;s-=t,l-=e;e=Math.sqrt(s*s+l*l);if(!(n<e-a||e+a<n)){if(Math.abs(i-o)%Ya<1e-4)return 1;(o=r?(r=i,i=Ua(o),Ua(r)):(i=Ua(i),Ua(o)))<i&&(o+=Ya);s=Math.atan2(l,s);return s<0&&(s+=Ya),i<=s&&s<=o||i<=s+Ya&&s+Ya<=o}}}(y,m,x,_,_+b,w,e,I,o))return!0}else l+=function(t,e,n,i,o,r,a,s){if(n<(s-=e)||s<-n)return 0;if(n=Math.sqrt(n*n-s*s),Ka[0]=-n,Ka[1]=n,(n=Math.abs(i-o))<1e-4)return 0;if(ja-1e-4<=n){o=ja;var l=r?1:-1;return a>=Ka[i=0]+t&&a<=Ka[1]+t?l:0}o<i&&(n=i,i=o,o=n),i<0&&(i+=ja,o+=ja);for(var u=0,h=0;h<2;h++){var c=Ka[h];a<c+t&&(l=r?1:-1,(i<=(c=(c=Math.atan2(s,c))<0?ja+c:c)&&c<=o||i<=c+ja&&c+ja<=o)&&(u+=l=c>Math.PI/2&&c<1.5*Math.PI?-l:l))}return u}(y,m,x,_,_+b,w,I,o);u=Math.cos(_+b)*v+y,h=Math.sin(_+b)*x+m;break;case Za.R:c=u=a[d++],p=h=a[d++];if(S=c+a[d++],M=p+a[d++],n){if(Ga(c,p,S,p,e,i,o)||Ga(S,p,S,M,e,i,o)||Ga(S,M,c,M,e,i,o)||Ga(c,M,c,p,e,i,o))return!0}else l+=Xa(S,p,S,M,i,o),l+=Xa(c,M,c,p,i,o);break;case Za.Z:if(n){if(Ga(u,h,c,p,e,i,o))return!0}else l+=Xa(u,h,c,p,i,o);u=c,h=p}}return n||(r=h,t=p,Math.abs(r-t)<qa)||(l+=Xa(u,h,c,p,i,o)||0),0!==l}var es,ns,is=z({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},Pr),os={style:z({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},Or.style)},rs=["x","y","rotation","scaleX","scaleY","originX","originY","invisible","culling","z","z2","zlevel","parent"],as=(wt(us,ns=Fr),us.prototype.update=function(){var e=this;ns.prototype.update.call(this);var t=this.style;if(t.decal){var n=this._decalEl=this._decalEl||new us;n.buildPath===us.prototype.buildPath&&(n.buildPath=function(t){e.buildPath(t,e.shape)}),n.silent=!0;var i,o=n.style;for(i in t)o[i]!==t[i]&&(o[i]=t[i]);o.fill=t.fill?t.decal:null,o.decal=null,o.shadowColor=null,t.strokeFirst&&(o.stroke=null);for(var r=0;r<rs.length;++r)n[rs[r]]=this[rs[r]];n.__dirty|=ke}else this._decalEl&&(this._decalEl=null)},us.prototype.getDecalElement=function(){return this._decalEl},us.prototype._init=function(t){var e=Y(t);this.shape=this.getDefaultShape();var n=this.getDefaultStyle();n&&this.useStyle(n);for(var i=0;i<e.length;i++){var o=e[i],r=t[o];"style"===o?this.style?N(this.style,r):this.useStyle(r):"shape"===o?N(this.shape,r):ns.prototype.attrKV.call(this,o,r)}this.style||this.useStyle({})},us.prototype.getDefaultStyle=function(){return null},us.prototype.getDefaultShape=function(){return{}},us.prototype.canBeInsideText=function(){return this.hasFill()},us.prototype.getInsideTextFill=function(){var t=this.style.fill;if("none"!==t){if(K(t)){var e=dn(t,0);return.5<e?ti:.2<e?"#eee":ei}if(t)return ei}return ti},us.prototype.getInsideTextStroke=function(t){var e=this.style.fill;if(K(e)){var n=this.__zr;if(!(!n||!n.isDarkMode())==dn(t,0)<.4)return e}},us.prototype.buildPath=function(t,e,n){},us.prototype.pathUpdated=function(){this.__dirty&=~Le},us.prototype.getUpdatedPathProxy=function(t){return this.path||this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},us.prototype.createPathProxy=function(){this.path=new Ba(!1)},us.prototype.hasStroke=function(){var t=this.style,e=t.stroke;return!(null==e||"none"===e||!(0<t.lineWidth))},us.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},us.prototype.getBoundingRect=function(){var t=this._rect,e=this.style,n=!t;if(n&&(o=!1,this.path||(o=!0,this.createPathProxy()),i=this.path,(o||this.__dirty&Le)&&(i.beginPath(),this.buildPath(i,this.shape,!1),this.pathUpdated()),t=i.getBoundingRect()),this._rect=t,this.hasStroke()&&this.path&&0<this.path.len()){var i,o=this._rectWithStroke||(this._rectWithStroke=t.clone());return(this.__dirty||n)&&(o.copy(t),i=e.strokeNoScale?this.getLineScale():1,n=e.lineWidth,this.hasFill()||(e=this.strokeContainThreshold,n=Math.max(n,null==e?4:e)),1e-10<i&&(o.width+=n/i,o.height+=n/i,o.x-=n/i/2,o.y-=n/i/2)),o}return t},us.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),o=this.style;if(t=n[0],e=n[1],i.contain(t,e)){n=this.path;if(this.hasStroke()){i=o.lineWidth,o=o.strokeNoScale?this.getLineScale():1;if(1e-10<o&&(this.hasFill()||(i=Math.max(i,this.strokeContainThreshold)),ts(n,i/o,!0,t,e)))return!0}if(this.hasFill())return ts(n,0,!1,t,e)}return!1},us.prototype.dirtyShape=function(){this.__dirty|=Le,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},us.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},us.prototype.animateShape=function(t){return this.animate("shape",t)},us.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():"shape"===t?this.dirtyShape():this.markRedraw()},us.prototype.attrKV=function(t,e){"shape"===t?this.setShape(e):ns.prototype.attrKV.call(this,t,e)},us.prototype.setShape=function(t,e){var n=(n=this.shape)||(this.shape={});return"string"==typeof t?n[t]=e:N(n,t),this.dirtyShape(),this},us.prototype.shapeChanged=function(){return!!(this.__dirty&Le)},us.prototype.createStyle=function(t){return vt(is,t)},us.prototype._innerSaveToNormal=function(t){ns.prototype._innerSaveToNormal.call(this,t);var e=this._normalState;t.shape&&!e.shape&&(e.shape=N({},this.shape))},us.prototype._applyStateObj=function(t,e,n,i,o,r){ns.prototype._applyStateObj.call(this,t,e,n,i,o,r);var a,s=!(e&&i);if(e&&e.shape?o?i?a=e.shape:(a=N({},n.shape),N(a,e.shape)):(a=N({},(i?this:n).shape),N(a,e.shape)):s&&(a=n.shape),a)if(o){this.shape=N({},this.shape);for(var l={},u=Y(a),h=0;h<u.length;h++){var c=u[h];"object"==typeof a[c]?this.shape[c]=a[c]:l[c]=a[c]}this._transitionState(t,{shape:l},r)}else this.shape=a,this.dirtyShape()},us.prototype._mergeStates=function(t){for(var e,n=ns.prototype._mergeStates.call(this,t),i=0;i<t.length;i++){var o=t[i];o.shape&&this._mergeStyle(e=e||{},o.shape)}return e&&(n.shape=e),n},us.prototype.getAnimationStyleProps=function(){return os},us.prototype.isZeroArea=function(){return!1},us.extend=function(n){var i,t,e=(wt(o,i=us),o.prototype.getDefaultStyle=function(){return P(n.style)},o.prototype.getDefaultShape=function(){return P(n.shape)},o);function o(t){var e=i.call(this,t)||this;return n.init&&n.init.call(e,t),e}for(t in n)"function"==typeof n[t]&&(e.prototype[t]=n[t]);return e},us.initDefaultProps=((T=us.prototype).type="path",T.strokeContainThreshold=5,T.segmentIgnoreThreshold=0,T.subPixelOptimize=!1,T.autoBatch=!1,void(T.__dirty=2|ke|Le)),us),ss=z({strokeFirst:!0,font:Pi,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},is),C=(wt(ls,es=Fr),ls.prototype.hasStroke=function(){var t=this.style,e=t.stroke;return null!=e&&"none"!==e&&0<t.lineWidth},ls.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},ls.prototype.createStyle=function(t){return vt(ss,t)},ls.prototype.setBoundingRect=function(t){this._rect=t},ls.prototype.getBoundingRect=function(){var t,e=this.style;return this._rect||(null!=(t=e.text)?t+="":t="",(t=Bi(t,e.font,e.textAlign,e.textBaseline)).x+=e.x||0,t.y+=e.y||0,this.hasStroke()&&(e=e.lineWidth,t.x-=e/2,t.y-=e/2,t.width+=e,t.height+=e),this._rect=t),this._rect},ls.initDefaultProps=void(ls.prototype.dirtyRectTolerance=10),ls);function ls(){return null!==es&&es.apply(this,arguments)||this}function us(t){return ns.call(this,t)||this}C.prototype.type="tspan";var hs=C,cs=z({x:0,y:0},Pr),ps={style:z({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},Or.style)};var ds,fs=(wt(gs,ds=Fr),gs.prototype.createStyle=function(t){return vt(cs,t)},gs.prototype._getSize=function(t){var e=this.style,n=e[t];if(null!=n)return n;n=(i=e.image)&&"string"!=typeof i&&i.width&&i.height?e.image:this.__image;if(!n)return 0;var i="width"===t?"height":"width",e=e[i];return null==e?n[t]:n[t]/n[i]*e},gs.prototype.getWidth=function(){return this._getSize("width")},gs.prototype.getHeight=function(){return this._getSize("height")},gs.prototype.getAnimationStyleProps=function(){return ps},gs.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new ki(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},gs);function gs(){return null!==ds&&ds.apply(this,arguments)||this}fs.prototype.type="image";var ys=fs;var ms=Math.round;function vs(t,e,n){if(e){var i=e.x1,o=e.x2,r=e.y1,e=e.y2;t.x1=i,t.x2=o,t.y1=r,t.y2=e;n=n&&n.lineWidth;return n&&(ms(2*i)===ms(2*o)&&(t.x1=t.x2=_s(i,n,!0)),ms(2*r)===ms(2*e)&&(t.y1=t.y2=_s(r,n,!0))),t}}function xs(t,e,n){if(e){var i=e.x,o=e.y,r=e.width,e=e.height;t.x=i,t.y=o,t.width=r,t.height=e;n=n&&n.lineWidth;return n&&(t.x=_s(i,n,!0),t.y=_s(o,n,!0),t.width=Math.max(_s(i+r,n,!1)-t.x,0===r?0:1),t.height=Math.max(_s(o+e,n,!1)-t.y,0===e?0:1)),t}}function _s(t,e,n){if(!e)return t;t=ms(2*t);return(t+ms(e))%2==0?t/2:(t+(n?1:-1))/2}var bs,ws=function(){this.x=0,this.y=0,this.width=0,this.height=0},Ss={},Jn=(wt(Ms,bs=as),Ms.prototype.getDefaultShape=function(){return new ws},Ms.prototype.buildPath=function(t,e){var n,i,o,r,a,s,l,u,h,c,p,d,f,g;this.subPixelOptimize?(n=(g=xs(Ss,e,this.style)).x,i=g.y,o=g.width,r=g.height,g.r=e.r,e=g):(n=e.x,i=e.y,o=e.width,r=e.height),e.r?(a=t,d=(s=e).x,f=s.y,g=s.width,e=s.height,s=s.r,g<0&&(d+=g,g=-g),e<0&&(f+=e,e=-e),"number"==typeof s?l=u=h=c=s:s instanceof Array?1===s.length?l=u=h=c=s[0]:2===s.length?(l=h=s[0],u=c=s[1]):3===s.length?(l=s[0],u=c=s[1],h=s[2]):(l=s[0],u=s[1],h=s[2],c=s[3]):l=u=h=c=0,g<l+u&&(l*=g/(p=l+u),u*=g/p),g<h+c&&(h*=g/(p=h+c),c*=g/p),e<u+h&&(u*=e/(p=u+h),h*=e/p),e<l+c&&(l*=e/(p=l+c),c*=e/p),a.moveTo(d+l,f),a.lineTo(d+g-u,f),0!==u&&a.arc(d+g-u,f+u,u,-Math.PI/2,0),a.lineTo(d+g,f+e-h),0!==h&&a.arc(d+g-h,f+e-h,h,0,Math.PI/2),a.lineTo(d+c,f+e),0!==c&&a.arc(d+c,f+e-c,c,Math.PI/2,Math.PI),a.lineTo(d,f+l),0!==l&&a.arc(d+l,f+l,l,Math.PI,1.5*Math.PI)):t.rect(n,i,o,r)},Ms.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},Ms);function Ms(t){return bs.call(this,t)||this}Jn.prototype.type="rect";var Is,Ts=Jn,Cs={fill:"#000"},Ds={style:z({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},Or.style)},As=(wt(Ps,Is=Fr),Ps.prototype.childrenRef=function(){return this._children},Ps.prototype.update=function(){Is.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var e=this._children[t];e.zlevel=this.zlevel,e.z=this.z,e.z2=this.z2,e.culling=this.culling,e.cursor=this.cursor,e.invisible=this.invisible}},Ps.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):Is.prototype.updateTransform.call(this)},Ps.prototype.getLocalTransform=function(t){var e=this.innerTransformable;return e?e.getLocalTransform(t):Is.prototype.getLocalTransform.call(this,t)},Ps.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),Is.prototype.getComputedTransform.call(this)},Ps.prototype._updateSubTexts=function(){var t;this._childCursor=0,Os(t=this.style),G(t.rich,Os),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},Ps.prototype.addSelfToZr=function(t){Is.prototype.addSelfToZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].__zr=t},Ps.prototype.removeSelfFromZr=function(t){Is.prototype.removeSelfFromZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].__zr=null},Ps.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new ki(0,0,0,0),e=this._children,n=[],i=null,o=0;o<e.length;o++){var r=e[o],a=r.getBoundingRect(),r=r.getLocalTransform(n);r?(t.copy(a),t.applyTransform(r),(i=i||t.clone()).union(t)):(i=i||a.clone()).union(a)}this._rect=i||t}return this._rect},Ps.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||Cs},Ps.prototype.setTextContent=function(t){throw new Error("Can't attach text on another text")},Ps.prototype._mergeStyle=function(t,e){if(!e)return t;var n=e.rich,i=t.rich||n&&{};return N(t,e),n&&i?(this._mergeRich(i,n),t.rich=i):i&&(t.rich=i),t},Ps.prototype._mergeRich=function(t,e){for(var n=Y(e),i=0;i<n.length;i++){var o=n[i];t[o]=t[o]||{},N(t[o],e[o])}},Ps.prototype.getAnimationStyleProps=function(){return Ds},Ps.prototype._getOrCreateChild=function(t){var e=this._children[this._childCursor];return e&&e instanceof t||(e=new t),(this._children[this._childCursor++]=e).__zr=this.__zr,e.parent=this,e},Ps.prototype._updatePlainTexts=function(){var t,e,n=this.style,i=n.font||Pi,o=n.padding,r=function(t,e){null!=t&&(t+="");var n,i=e.overflow,o=e.padding,r=e.font,a="truncate"===i,s=Hi(r),l=rt(e.lineHeight,s),u="truncate"===e.lineOverflow,h=e.width,c=(n=null!=h&&"break"===i||"breakAll"===i?t?kr(t,e.font,h,"breakAll"===i,0).lines:[]:t?t.split("\n"):[]).length*l;(i=rt(e.height,c))<c&&u&&(p=Math.floor(i/l),n=n.slice(0,p));var u=i,p=h;if(o&&(u+=o[0]+o[2],null!=p&&(p+=o[1]+o[3])),t&&a&&null!=p)for(var d=wr(h,r,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),f=0;f<n.length;f++)n[f]=Sr(n[f],d);if(null==h){for(var g=0,f=0;f<n.length;f++)g=Math.max(Ei(n[f],r),g);h=g}return{lines:n,height:i,outerHeight:u,lineHeight:l,calculatedLineHeight:s,contentHeight:c,width:h}}(Es(n),n),a=Vs(n),s=!!n.backgroundColor,l=r.outerHeight,u=r.lines,h=r.lineHeight,c=this._defaultStyle,p=n.x||0,d=n.y||0,f=n.align||c.align||"left",g=n.verticalAlign||c.verticalAlign||"top",y=p,m=Gi(d,r.contentHeight,g);(a||o)&&(t=r.width,o&&(t+=o[1]+o[3]),e=Fi(p,t,f),d=Gi(d,l,g),a&&this._renderBackground(n,n,e,d,t,l)),m+=h/2,o&&(y=zs(p,f,o),"top"===g?m+=o[0]:"bottom"===g&&(m-=o[2]));for(var v=0,o=!1,x=(Ns("fill"in n?n.fill:(o=!0,c.fill))),_=(Rs("stroke"in n?n.stroke:s||c.autoStroke&&!o?null:(v=2,c.stroke))),b=0<n.textShadowBlur,w=null!=n.width&&("truncate"===n.overflow||"break"===n.overflow||"breakAll"===n.overflow),S=r.calculatedLineHeight,M=0;M<u.length;M++){var I=this._getOrCreateChild(hs),T=I.createStyle();I.useStyle(T),T.text=u[M],T.x=y,T.y=m,f&&(T.textAlign=f),T.textBaseline="middle",T.opacity=n.opacity,T.strokeFirst=!0,b&&(T.shadowBlur=n.textShadowBlur||0,T.shadowColor=n.textShadowColor||"transparent",T.shadowOffsetX=n.textShadowOffsetX||0,T.shadowOffsetY=n.textShadowOffsetY||0),_&&(T.stroke=_,T.lineWidth=n.lineWidth||v,T.lineDash=n.lineDash,T.lineDashOffset=n.lineDashOffset||0),x&&(T.fill=x),T.font=i,m+=h,w&&I.setBoundingRect(new ki(Fi(T.x,n.width,T.textAlign),Gi(T.y,S,T.textBaseline),n.width,S))}},Ps.prototype._updateRichTexts=function(){var t=this.style,e=Cr(Es(t),t),n=e.width,i=e.outerWidth,o=e.outerHeight,r=t.padding,a=t.x||0,s=t.y||0,l=this._defaultStyle,u=t.align||l.align,l=t.verticalAlign||l.verticalAlign,u=Fi(a,i,u),l=Gi(s,o,l),h=u,c=l;r&&(h+=r[3],c+=r[0]);var p=h+n;Vs(t)&&this._renderBackground(t,t,u,l,i,o);for(var d=!!t.backgroundColor,f=0;f<e.lines.length;f++){for(var g=e.lines[f],y=g.tokens,m=y.length,v=g.lineHeight,x=g.width,_=0,b=h,w=p,S=m-1,M=void 0;_<m&&(!(M=y[_]).align||"left"===M.align);)this._placeToken(M,t,v,c,b,"left",d),x-=M.width,b+=M.width,_++;for(;0<=S&&"right"===(M=y[S]).align;)this._placeToken(M,t,v,c,w,"right",d),x-=M.width,w-=M.width,S--;for(b+=(n-(b-h)-(p-w)-x)/2;_<=S;)M=y[_],this._placeToken(M,t,v,c,b+M.width/2,"center",d),b+=M.width,_++;c+=v}},Ps.prototype._placeToken=function(t,e,n,i,o,r,a){var s=e.rich[t.styleName]||{};s.text=t.text;var l=t.verticalAlign,u=i+n/2;"top"===l?u=i+t.height/2:"bottom"===l&&(u=i+n-t.height/2),!t.isLineHolder&&Vs(s)&&this._renderBackground(s,e,"right"===r?o-t.width:"center"===r?o-t.width/2:o,u-t.height/2,t.width,t.height);var h=!!s.backgroundColor,c=t.textPadding;c&&(o=zs(o,r,c),u-=t.height/2-c[0]-t.innerHeight/2);var p=this._getOrCreateChild(hs),d=p.createStyle();p.useStyle(d);l=this._defaultStyle,i=!1,n=0,c=Ns("fill"in s?s.fill:"fill"in e?e.fill:(i=!0,l.fill)),i=Rs("stroke"in s?s.stroke:"stroke"in e?e.stroke:h||a||l.autoStroke&&!i?null:(n=2,l.stroke)),l=0<s.textShadowBlur||0<e.textShadowBlur;d.text=t.text,d.x=o,d.y=u,l&&(d.shadowBlur=s.textShadowBlur||e.textShadowBlur||0,d.shadowColor=s.textShadowColor||e.textShadowColor||"transparent",d.shadowOffsetX=s.textShadowOffsetX||e.textShadowOffsetX||0,d.shadowOffsetY=s.textShadowOffsetY||e.textShadowOffsetY||0),d.textAlign=r,d.textBaseline="middle",d.font=t.font||Pi,d.opacity=at(s.opacity,e.opacity,1),i&&(d.lineWidth=at(s.lineWidth,e.lineWidth,n),d.lineDash=rt(s.lineDash,e.lineDash),d.lineDashOffset=e.lineDashOffset||0,d.stroke=i),c&&(d.fill=c);c=t.contentWidth,t=t.contentHeight;p.setBoundingRect(new ki(Fi(d.x,c,d.textAlign),Gi(d.y,t,d.textBaseline),c,t))},Ps.prototype._renderBackground=function(t,e,n,i,o,r){var a,s,l,u=t.backgroundColor,h=t.borderWidth,c=t.borderColor,p=u&&u.image,d=u&&!p,f=t.borderRadius,g=this;(d||t.lineHeight||h&&c)&&((a=this._getOrCreateChild(Ts)).useStyle(a.createStyle()),a.style.fill=null,(s=a.shape).x=n,s.y=i,s.width=o,s.height=r,s.r=f,a.dirtyShape()),d?((l=a.style).fill=u||null,l.fillOpacity=rt(t.fillOpacity,1)):p&&((y=this._getOrCreateChild(ys)).onload=function(){g.dirtyStyle()},(p=y.style).image=u.image,p.x=n,p.y=i,p.width=o,p.height=r),h&&c&&((l=a.style).lineWidth=h,l.stroke=c,l.strokeOpacity=rt(t.strokeOpacity,1),l.lineDash=t.borderDash,l.lineDashOffset=t.borderDashOffset||0,a.strokeContainThreshold=0,a.hasFill()&&a.hasStroke()&&(l.strokeFirst=!0,l.lineWidth*=2));var y=(a||y).style;y.shadowBlur=t.shadowBlur||0,y.shadowColor=t.shadowColor||"transparent",y.shadowOffsetX=t.shadowOffsetX||0,y.shadowOffsetY=t.shadowOffsetY||0,y.opacity=at(t.opacity,e.opacity,1)},Ps.makeFont=function(t){var e,n="";return(t.fontSize||t.fontFamily||t.fontWeight)&&(e="",e="string"!=typeof t.fontSize||-1===t.fontSize.indexOf("px")&&-1===t.fontSize.indexOf("rem")&&-1===t.fontSize.indexOf("em")?isNaN(+t.fontSize)?"12px":t.fontSize+"px":t.fontSize,n=[t.fontStyle,t.fontWeight,e,t.fontFamily||"sans-serif"].join(" ")),n&&ht(n)||t.textFont||t.font},Ps),ks={left:!0,right:1,center:1},Ls={top:1,bottom:1,middle:1};function Ps(t){var e=Is.call(this)||this;return e.type="text",e._children=[],e._defaultStyle=Cs,e.attr(t),e}function Os(t){var e;t&&(t.font=As.makeFont(t),e=t.align,t.align=null==(e="middle"===e?"center":e)||ks[e]?e:"left",e=t.verticalAlign,t.verticalAlign=null==(e="center"===e?"middle":e)||Ls[e]?e:"top",t.padding&&(t.padding=lt(t.padding)))}function Rs(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function Ns(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function zs(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function Es(t){t=t.text;return null!=t&&(t+=""),t}function Vs(t){return!!(t.backgroundColor||t.lineHeight||t.borderWidth&&t.borderColor)}function Bs(e,n,i,t){var o;t&&((o=Gs(t)).dataIndex=i,o.dataType=n,o.seriesIndex=e,"group"===t.type&&t.traverse(function(t){t=Gs(t);t.seriesIndex=e,t.dataIndex=i,t.dataType=n}))}var Fs=As,Gs=Zo(),Hs=1,Ws={},Us=Zo(),Ys=0,Xs=1,Zs=2,js=["emphasis","blur","select"],qs=["normal","emphasis","blur","select"],Ks="highlight",Js="downplay",Qs="select",$s="unselect",tl="toggleSelect";function el(t){return null!=t&&"none"!==t}var nl=new He(100);function il(t){if("string"!=typeof t)return t;var e=nl.get(t);return e||(e=sn(t,-.1),nl.put(t,e)),e}function ol(t,e,n){t.onHoverStateChange&&(t.hoverState||0)!==n&&t.onHoverStateChange(e),t.hoverState=n}function rl(t){ol(t,"emphasis",Zs)}function al(t){t.hoverState===Zs&&ol(t,"normal",Ys)}function sl(t){ol(t,"blur",Xs)}function ll(t){t.hoverState===Xs&&ol(t,"normal",Ys)}function ul(t){t.selected=!0}function hl(t){t.selected=!1}function cl(t,e,n){e(t,n)}function pl(t,e,n){cl(t,e,n),t.isGroup&&t.traverse(function(t){cl(t,e,n)})}function dl(t,e){switch(e){case"emphasis":t.hoverState=Zs;break;case"normal":t.hoverState=Ys;break;case"blur":t.hoverState=Xs;break;case"select":t.selected=!0}}function fl(t,e,n){var i=0<=V(t.currentStates,e),o=t.style.opacity,t=i?null:function(t,e,n,i){for(var o=t.style,r={},a=0;a<e.length;a++){var s=e[a],l=o[s];r[s]=null==l?i&&i[s]:l}for(a=0;a<t.animators.length;a++){var u=t.animators[a];u.__fromStateTransition&&u.__fromStateTransition.indexOf(n)<0&&"style"===u.targetName&&u.saveFinalToTarget(r,e)}return r}(t,["opacity"],e,{opacity:1}),e=(n=n||{}).style||{};return null==e.opacity&&(n=N({},n),e=N({opacity:i?o:.1*t.opacity},e),n.style=e),n}function gl(t,e){var n,i,o,r,a,s=this.states[t];if(this.style){if("emphasis"===t)return n=this,o=s,r=(i=e)&&0<=V(i,"select"),a=!1,n instanceof as&&(e=Us(n),i=r&&e.selectFill||e.normalFill,r=r&&e.selectStroke||e.normalStroke,(el(i)||el(r))&&("inherit"===(e=(o=o||{}).style||{}).fill?(a=!0,o=N({},o),(e=N({},e)).fill=i):!el(e.fill)&&el(i)?(a=!0,o=N({},o),(e=N({},e)).fill=il(i)):!el(e.stroke)&&el(r)&&(a||(o=N({},o),e=N({},e)),e.stroke=il(r)),o.style=e)),o&&null==o.z2&&(a||(o=N({},o)),a=n.z2EmphasisLift,o.z2=n.z2+(null!=a?a:10)),o;if("blur"===t)return fl(this,t,s);if("select"===t)return a=this,(o=s)&&null==o.z2&&(o=N({},o),t=a.z2SelectLift,o.z2=a.z2+(null!=t?t:9)),o}return s}function yl(t){t.stateProxy=gl;var e=t.getTextContent(),t=t.getTextGuideLine();e&&(e.stateProxy=gl),t&&(t.stateProxy=gl)}function ml(t,e){Il(t,e)||t.__highByOuter||pl(t,rl)}function vl(t,e){Il(t,e)||t.__highByOuter||pl(t,al)}function xl(t,e){t.__highByOuter|=1<<(e||0),pl(t,rl)}function _l(t,e){(t.__highByOuter&=~(1<<(e||0)))||pl(t,al)}function bl(t){pl(t,sl)}function wl(t){pl(t,ll)}function Sl(t){pl(t,ul)}function Ml(t){pl(t,hl)}function Il(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function Tl(n){n.getModel().eachComponent(function(t,e){("series"===t?n.getViewOfSeriesModel(e):n.getViewOfComponentModel(e)).group.traverse(function(t){ll(t)})})}function Cl(t,r,a,s){var l,u,h,n=s.getModel();function c(t,e){for(var n=0;n<e.length;n++){var i=t.getItemGraphicEl(e[n]);i&&wl(i)}}a=a||"coordinateSystem",null!=t&&r&&"none"!==r&&(l=n.getSeriesByIndex(t),(u=l.coordinateSystem)&&u.master&&(u=u.master),h=[],n.eachSeries(function(t){var e=l===t,n=t.coordinateSystem;if(n&&n.master&&(n=n.master),!("series"===a&&!e||"coordinateSystem"===a&&!(n&&u?n===u:e)||"series"===r&&e)){if(s.getViewOfSeriesModel(t).group.traverse(function(t){sl(t)}),F(r))c(t.getData(),r);else if($(r))for(var i=Y(r),o=0;o<i.length;o++)c(t.getData(i[o]),r[i[o]]);h.push(t)}}),n.eachComponent(function(t,e){"series"===t||(e=s.getViewOfComponentModel(e))&&e.blurSeries&&e.blurSeries(h,n)}))}function Dl(t,e,n){null!=t&&null!=e&&(!(e=n.getModel().getComponent(t,e))||(e=n.getViewOfComponentModel(e))&&e.focusBlurEnabled&&e.group.traverse(function(t){sl(t)}))}function Al(t,e,n,i){var o={focusSelf:!1,dispatchers:null};if(null==t||"series"===t||null==e||null==n)return o;e=i.getModel().getComponent(t,e);if(!e)return o;e=i.getViewOfComponentModel(e);if(!e||!e.findHighDownDispatchers)return o;for(var r,a=e.findHighDownDispatchers(n),s=0;s<a.length;s++)if("self"===Gs(a[s]).focus){r=!0;break}return{focusSelf:r,dispatchers:a}}function kl(i){G(i.getAllData(),function(t){var e=t.data,n=t.type;e.eachItemGraphicEl(function(t,e){(i.isSelected(e,n)?Sl:Ml)(t)})})}function Ll(t,e,n){zl(t,!0),pl(t,yl),Pl(t,e,n)}function Pl(t,e,n){t=Gs(t);null!=e?(t.focus=e,t.blurScope=n):t.focus&&(t.focus=null)}var Ol=["emphasis","blur","select"],Rl={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function Nl(t,e,n,i){n=n||"itemStyle";for(var o=0;o<Ol.length;o++){var r=Ol[o],a=e.getModel([r,n]);t.ensureState(r).style=i?i(a):a[Rl[n]]()}}function zl(t,e){var n=!1===e,e=t;t.highDownSilentOnTouch&&(e.__highDownSilentOnTouch=t.highDownSilentOnTouch),n&&!e.__highDownDispatcher||(e.__highByOuter=e.__highByOuter||0,e.__highDownDispatcher=!n)}function El(t){return!(!t||!t.__highDownDispatcher)}function Vl(t){t=t.type;return t===Qs||t===$s||t===tl}function Bl(t){t=t.type;return t===Ks||t===Js}var Fl=Zo();function Gl(t,e,n,i,o){var r;e&&e.ecModel&&(r=(l=e.ecModel.getUpdatePayload())&&l.animation);var a="update"===t;if(e&&e.isAnimationEnabled()){var s=void 0,l=void 0,t=void 0,t=i?(s=rt(i.duration,200),l=rt(i.easing,"cubicOut"),0):(s=e.getShallow(a?"animationDurationUpdate":"animationDuration"),l=e.getShallow(a?"animationEasingUpdate":"animationEasing"),e.getShallow(a?"animationDelayUpdate":"animationDelay"));return r&&(null!=r.duration&&(s=r.duration),null!=r.easing&&(l=r.easing),null!=r.delay&&(t=r.delay)),"function"==typeof t&&(t=t(n,o)),{duration:(s="function"==typeof s?s(n):s)||0,delay:t,easing:l}}return null}function Hl(t,e,n,i,o,r,a){var s,l=!1;"function"==typeof o?(a=r,r=o,o=null):$(o)&&(r=o.cb,a=o.during,l=o.isFrom,s=o.removeOpt,o=o.dataIndex);var u="remove"===t;u||e.stopAnimation("remove");o=Gl(t,i,o,u?s||{}:null,i&&i.getAnimationDelayParams?i.getAnimationDelayParams(e,o):null);o&&0<o.duration?(t={duration:o.duration,delay:o.delay||0,easing:o.easing,done:r,force:!!r||!!a,setToFinal:!u,scope:t,during:a},l?e.animateFrom(n,t):e.animateTo(n,t)):(e.stopAnimation(),l||e.attr(n),a&&a(1),r&&r())}function Wl(t,e,n,i,o,r){Hl("update",t,e,n,i,o,r)}function Ul(t,e,n,i,o,r){Hl("init",t,e,n,i,o,r)}function Yl(t){if(!t.__zr)return!0;for(var e=0;e<t.animators.length;e++)if("remove"===t.animators[e].scope)return!0;return!1}function Xl(t,e,n,i,o,r){Yl(t)||Hl("remove",t,e,n,i,o,r)}function Zl(t,e,n,i){t.removeTextContent(),t.removeTextGuideLine(),Xl(t,{style:{opacity:0}},e,n,i)}function jl(t,e,n){function i(){t.parent&&t.parent.remove(t)}t.isGroup?t.traverse(function(t){t.isGroup||Zl(t,e,n,i)}):Zl(t,e,n,i)}function ql(t){Fl(t).oldStyle=t.style}var Kl={};function Jl(t,e){for(var n=0;n<js.length;n++){var i=js[n],o=e[i],i=t.ensureState(i);i.style=i.style||{},i.style.text=o}var r=t.currentStates.slice();t.clearStates(!0),t.setStyle({text:e.normal}),t.useStates(r,!0)}function Ql(t,e,n){for(var i,o=t.labelFetcher,r=t.labelDataIndex,a=t.labelDimIndex,s=e.normal,l={normal:i=null==(i=o?o.getFormattedLabel(r,"normal",null,a,s&&s.get("formatter"),null!=n?{interpolatedValue:n}:null):i)?q(t.defaultText)?t.defaultText(r,t,n):t.defaultText:i},u=0;u<js.length;u++){var h=js[u],c=e[h];l[h]=rt(o?o.getFormattedLabel(r,h,null,a,c&&c.get("formatter")):null,i)}return l}function $l(t,e,n,i){n=n||Kl;for(var o=t instanceof Fs,r=!1,a=0;a<qs.length;a++){var s=e[qs[a]];if(s&&s.getShallow("show")){r=!0;break}}var l=o?t:t.getTextContent();if(r){o||(l||(l=new Fs,t.setTextContent(l)),t.stateProxy&&(l.stateProxy=t.stateProxy));var u=Ql(n,e),h=e.normal,c=!!h.getShallow("show"),p=eu(h,i&&i.normal,n,!1,!o);for(p.text=u.normal,o||t.setTextConfig(nu(h,n,!1)),a=0;a<js.length;a++){var d,f,g=js[a];(s=e[g])&&(d=l.ensureState(g),(f=!!rt(s.getShallow("show"),c))!=c&&(d.ignore=!f),d.style=eu(s,i&&i[g],n,!0,!o),d.style.text=u[g],o||(t.ensureState(g).textConfig=nu(s,n,!0)))}l.silent=!!h.getShallow("silent"),null!=l.style.x&&(p.x=l.style.x),null!=l.style.y&&(p.y=l.style.y),l.ignore=!c,l.useStyle(p),l.dirty(),n.enableTextSetter&&(lu(l).setLabelText=function(t){t=Ql(n,e,t);Jl(l,t)})}else l&&(l.ignore=!0);t.dirty()}function tu(t,e){for(var n={normal:t.getModel(e=e||"label")},i=0;i<js.length;i++){var o=js[i];n[o]=t.getModel([o,e])}return n}function eu(t,e,n,i,o){var r={};return function(t,e,n,i,o){n=n||Kl;var r,a=e.ecModel,s=a&&a.option.textStyle,l=function(t){var e;for(;t&&t!==t.ecModel;){var n=(t.option||Kl).rich;if(n){e=e||{};for(var i=Y(n),o=0;o<i.length;o++){var r=i[o];e[r]=1}}t=t.parentModel}return e}(e);if(l)for(var u in r={},l){var h;l.hasOwnProperty(u)&&(h=e.getModel(["rich",u]),au(r[u]={},h,s,n,i,o,!1,!0))}r&&(t.rich=r);a=e.get("overflow");a&&(t.overflow=a);a=e.get("minMargin");null!=a&&(t.margin=a),au(t,e,s,n,i,o,!0,!1)}(r,t,n,i,o),e&&N(r,e),r}function nu(t,e,n){e=e||{};var i={},o=t.getShallow("rotate"),r=rt(t.getShallow("distance"),n?null:5),a=t.getShallow("offset"),n=t.getShallow("position")||(n?null:"inside");return null!=(n="outside"===n?e.defaultOutsidePosition||"top":n)&&(i.position=n),null!=a&&(i.offset=a),null!=o&&(o*=Math.PI/180,i.rotation=o),null!=r&&(i.distance=r),i.outsideFill="inherit"===t.get("color")?e.inheritColor||null:"auto",i}var iu=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],ou=["align","lineHeight","width","height","tag","verticalAlign"],ru=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function au(t,e,n,i,o,r,a,s){n=!o&&n||Kl;var l=i&&i.inheritColor,u=e.getShallow("color"),h=e.getShallow("textBorderColor"),c=rt(e.getShallow("opacity"),n.opacity);"inherit"!==u&&"auto"!==u||(u=l||null),"inherit"!==h&&"auto"!==h||(h=l||null),r||(u=u||n.color,h=h||n.textBorderColor),null!=u&&(t.fill=u),null!=h&&(t.stroke=h);h=rt(e.getShallow("textBorderWidth"),n.textBorderWidth);null!=h&&(t.lineWidth=h);h=rt(e.getShallow("textBorderType"),n.textBorderType);null!=h&&(t.lineDash=h);h=rt(e.getShallow("textBorderDashOffset"),n.textBorderDashOffset);null!=h&&(t.lineDashOffset=h),null!=(c=!o&&null==c&&!s?i&&i.defaultOpacity:c)&&(t.opacity=c),o||r||null==t.fill&&i.inheritColor&&(t.fill=i.inheritColor);for(var p=0;p<iu.length;p++){var d=iu[p],f=rt(e.getShallow(d),n[d]);null!=f&&(t[d]=f)}for(p=0;p<ou.length;p++)d=ou[p],null!=(f=e.getShallow(d))&&(t[d]=f);if(null!=t.verticalAlign||null!=(r=e.getShallow("baseline"))&&(t.verticalAlign=r),!a||!i.disableBox){for(p=0;p<ru.length;p++)d=ru[p],null!=(f=e.getShallow(d))&&(t[d]=f);i=e.getShallow("borderType");null!=i&&(t.borderDash=i),"auto"!==t.backgroundColor&&"inherit"!==t.backgroundColor||!l||(t.backgroundColor=l),"auto"!==t.borderColor&&"inherit"!==t.borderColor||!l||(t.borderColor=l)}}function su(t,e){e=e&&e.getModel("textStyle");return ht([t.fontStyle||e&&e.getShallow("fontStyle")||"",t.fontWeight||e&&e.getShallow("fontWeight")||"",(t.fontSize||e&&e.getShallow("fontSize")||12)+"px",t.fontFamily||e&&e.getShallow("fontFamily")||"sans-serif"].join(" "))}var lu=Zo();function uu(t,e,n,i){t&&((t=lu(t)).prevValue=t.value,t.value=n,n=e.normal,t.valueAnimation=n.get("valueAnimation"),t.valueAnimation&&(t.precision=n.get("precision"),t.defaultInterpolatedText=i,t.statesModels=e))}function hu(n,i,o,t,r){var a,s,l,u=lu(n);u.valueAnimation&&u.prevValue!==u.value&&(a=u.defaultInterpolatedText,s=rt(u.interpolatedValue,u.prevValue),l=u.value,n.percent=0,(null==u.prevValue?Ul:Wl)(n,{percent:1},t,i,null,function(t){var e=nr(o,u.precision,s,l,t);u.interpolatedValue=1===t?null:e;e=Ql({labelDataIndex:i,labelFetcher:r,defaultText:a?a(e):e+""},u.statesModels,e);Jl(n,e)}))}var cu,pu=["textStyle","color"],du=new Fs,fu=(bu.prototype.getTextColor=function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(pu):null)},bu.prototype.getFont=function(){return su({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},bu.prototype.getTextRect=function(t){return du.useStyle({text:t,fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily"),verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline"),padding:this.getShallow("padding"),lineHeight:this.getShallow("lineHeight"),rich:this.getShallow("rich")}),du.update(),du.getBoundingRect()},bu),vi=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],gu=dr(vi),Ki=(_u.prototype.getLineStyle=function(t){return gu(this,t)},_u),io=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],yu=dr(io),no=(xu.prototype.getItemStyle=function(t,e){return yu(this,t,e)},xu),mu=(vu.prototype.init=function(t,e,n){for(var i=[],o=3;o<arguments.length;o++)i[o-3]=arguments[o]},vu.prototype.mergeOption=function(t,e){O(this.option,t,!0)},vu.prototype.get=function(t,e){return null==t?this.option:this._doGet(this.parsePath(t),!e&&this.parentModel)},vu.prototype.getShallow=function(t,e){var n=this.option,n=null==n?n:n[t];return null!=n||e||(e=this.parentModel)&&(n=e.getShallow(t)),n},vu.prototype.getModel=function(t,e){var n=null!=t,t=n?this.parsePath(t):null;return new vu(n?this._doGet(t):this.option,e=e||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(t)),this.ecModel)},vu.prototype.isEmpty=function(){return null==this.option},vu.prototype.restoreData=function(){},vu.prototype.clone=function(){return new this.constructor(P(this.option))},vu.prototype.parsePath=function(t){return"string"==typeof t?t.split("."):t},vu.prototype.resolveParentPath=function(t){return t},vu.prototype.isAnimationEnabled=function(){if(!w.node&&this.option)return null!=this.option.animation?!!this.option.animation:this.parentModel?this.parentModel.isAnimationEnabled():void 0},vu.prototype._doGet=function(t,e){var n=this.option;if(!t)return n;for(var i=0;i<t.length&&(!t[i]||null!=(n=n&&"object"==typeof n?n[t[i]]:null));i++);return n=null==n&&e?e._doGet(this.resolveParentPath(t),e.parentModel):n},vu);function vu(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function xu(){}function _u(){}function bu(){}sr(mu),y=mu,cu=["__\0is_clz",ur++].join("_"),y.prototype[cu]=!0,y.isInstance=function(t){return!(!t||!t[cu])},B(mu,Ki),B(mu,no),B(mu,gr),B(mu,fu);var wu=mu,Su=Math.round(10*Math.random());function Mu(t){return[t||"",Su++].join("_")}function Iu(t,e){return O(O({},t,!0),e,!0)}var Tu="ZH",Cu="EN",Du=Cu,Au={},ku={},Lu=w.domSupported&&-1<(document.documentElement.lang||navigator.language||navigator.browserLanguage).toUpperCase().indexOf(Tu)?Tu:Du;function Pu(t,e){t=t.toUpperCase(),ku[t]=new wu(e),Au[t]=e}function Ou(t){return ku[t]}Pu(Cu,{time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}}),Pu(Tu,{time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}});var Ru=1e3,Nu=60*Ru,zu=60*Nu,Eu=24*zu,_=365*Eu,Vu={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},T="{yyyy}-{MM}-{dd}",Bu={year:"{yyyy}",month:"{yyyy}-{MM}",day:T,hour:T+" "+Vu.hour,minute:T+" "+Vu.minute,second:T+" "+Vu.second,millisecond:Vu.none},Fu=["year","month","day","hour","minute","second","millisecond"],Gu=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Hu(t,e){return"0000".substr(0,e-(t+="").length)+t}function Wu(t){switch(t){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return t}}function Uu(t,e,n,i){var o=Mo(t),r=o[Zu(n)](),a=o[ju(n)]()+1,s=Math.floor((a-1)/4)+1,l=o[qu(n)](),u=o["get"+(n?"UTC":"")+"Day"](),h=o[Ku(n)](),c=(h-1)%12+1,p=o[Ju(n)](),d=o[Qu(n)](),f=o[$u(n)](),t=(i instanceof wu?i:Ou(i||Lu)||ku[Du]).getModel("time"),o=t.get("month"),n=t.get("monthAbbr"),i=t.get("dayOfWeek"),t=t.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,r+"").replace(/{yy}/g,r%100+"").replace(/{Q}/g,s+"").replace(/{MMMM}/g,o[a-1]).replace(/{MMM}/g,n[a-1]).replace(/{MM}/g,Hu(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,Hu(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,i[u]).replace(/{ee}/g,t[u]).replace(/{e}/g,u+"").replace(/{HH}/g,Hu(h,2)).replace(/{H}/g,h+"").replace(/{hh}/g,Hu(c+"",2)).replace(/{h}/g,c+"").replace(/{mm}/g,Hu(p,2)).replace(/{m}/g,p+"").replace(/{ss}/g,Hu(d,2)).replace(/{s}/g,d+"").replace(/{SSS}/g,Hu(f,3)).replace(/{S}/g,f+"")}function Yu(t,e){var n=Mo(t),i=n[ju(e)]()+1,o=n[qu(e)](),r=n[Ku(e)](),a=n[Ju(e)](),t=n[Qu(e)](),e=0===n[$u(e)](),t=e&&0===t,a=t&&0===a,r=a&&0===r,o=r&&1===o;return o&&1===i?"year":o?"month":r?"day":a?"hour":t?"minute":e?"second":"millisecond"}function Xu(t,e,n){var i="number"==typeof t?Mo(t):t;switch(e=e||Yu(t,n)){case"year":return i[Zu(n)]();case"half-year":return 6<=i[ju(n)]()?1:0;case"quarter":return Math.floor((i[ju(n)]()+1)/4);case"month":return i[ju(n)]();case"day":return i[qu(n)]();case"half-day":return i[Ku(n)]()/24;case"hour":return i[Ku(n)]();case"minute":return i[Ju(n)]();case"second":return i[Qu(n)]();case"millisecond":return i[$u(n)]()}}function Zu(t){return t?"getUTCFullYear":"getFullYear"}function ju(t){return t?"getUTCMonth":"getMonth"}function qu(t){return t?"getUTCDate":"getDate"}function Ku(t){return t?"getUTCHours":"getHours"}function Ju(t){return t?"getUTCMinutes":"getMinutes"}function Qu(t){return t?"getUTCSeconds":"getSeconds"}function $u(t){return t?"getUTCMilliseconds":"getMilliseconds"}function th(t){return t?"setUTCMonth":"setMonth"}function eh(t){return t?"setUTCDate":"setDate"}function nh(t){return t?"setUTCHours":"setHours"}function ih(t){return t?"setUTCMinutes":"setMinutes"}function oh(t){return t?"setUTCSeconds":"setSeconds"}function rh(t){return t?"setUTCMilliseconds":"setMilliseconds"}function ah(t){if(!ko(t))return K(t)?t:"-";t=(t+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(1<t.length?"."+t[1]:"")}function sh(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),t=e&&t?t.charAt(0).toUpperCase()+t.slice(1):t}var lh=lt,uh=/([&<>"'])/g,hh={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function ch(t){return null==t?"":(t+"").replace(uh,function(t,e){return hh[e]})}function ph(t,e,n){function i(t){return t&&ht(t)?t:"-"}function o(t){return null!=t&&!isNaN(t)&&isFinite(t)}var r="time"===e,a=t instanceof Date;if(r||a){r=r?Mo(t):t;if(!isNaN(+r))return Uu(r,"{yyyy}-{MM}-{dd} {hh}:{mm}:{ss}",n);if(a)return"-"}if("ordinal"===e)return J(t)?i(t):Q(t)&&o(t)?t+"":"-";e=Ao(t);return o(e)?ah(e):J(t)?i(t):"boolean"==typeof t?t+"":"-"}function dh(t,e){return"{"+t+(null==e?"":e)+"}"}var fh=["a","b","c","d","e","f","g"];function gh(t,e,n){var i=(e=!j(e)?[e]:e).length;if(!i)return"";for(var o=e[0].$vars||[],r=0;r<o.length;r++){var a=fh[r];t=t.replace(dh(a),dh(a,0))}for(var s=0;s<i;s++)for(var l=0;l<o.length;l++){var u=e[s][o[l]];t=t.replace(dh(fh[l],s),n?ch(u):u)}return t}function yh(t,e){return e=e||"transparent",K(t)?t:$(t)&&t.colorStops&&(t.colorStops[0]||{}).color||e}function mh(t,e){var n;"_blank"===e||"blank"===e?((n=window.open()).opener=null,n.location.href=t):window.open(t,e)}var vh=G,xh=["left","right","top","bottom","width","height"],_h=[["width","left","right"],["height","top","bottom"]];function bh(a,s,l,u,h){var c=0,p=0;null==u&&(u=1/0),null==h&&(h=1/0);var d=0;s.eachChild(function(t,e){var n,i,o=t.getBoundingRect(),r=s.childAt(e+1),e=r&&r.getBoundingRect();d="horizontal"===a?(r=o.width+(e?-e.x+o.x:0),u<(n=c+r)||t.newline?(c=0,n=r,p+=d+l,o.height):Math.max(d,o.height)):(e=o.height+(e?-e.y+o.y:0),h<(i=p+e)||t.newline?(c+=d+l,p=0,i=e,o.width):Math.max(d,o.width)),t.newline||(t.x=c,t.y=p,t.markRedraw(),"horizontal"===a?c=n+l:p=i+l)})}var wh=bh;function Sh(t,e,n){n=lh(n||0);var i=e.width,o=e.height,r=go(t.left,i),a=go(t.top,o),s=go(t.right,i),l=go(t.bottom,o),u=go(t.width,i),h=go(t.height,o),c=n[2]+n[0],p=n[1]+n[3],e=t.aspect;switch(isNaN(u)&&(u=i-s-p-r),isNaN(h)&&(h=o-l-c-a),null!=e&&(isNaN(u)&&isNaN(h)&&(i/o<e?u=.8*i:h=.8*o),isNaN(u)&&(u=e*h),isNaN(h)&&(h=u/e)),isNaN(r)&&(r=i-s-u-p),isNaN(a)&&(a=o-l-h-c),t.left||t.right){case"center":r=i/2-u/2-n[3];break;case"right":r=i-u-p}switch(t.top||t.bottom){case"middle":case"center":a=o/2-h/2-n[0];break;case"bottom":a=o-h-c}r=r||0,a=a||0,isNaN(u)&&(u=i-p-r-(s||0)),isNaN(h)&&(h=o-c-a-(l||0));l=new ki(r+n[3],a+n[0],u,h);return l.margin=n,l}function Mh(t,e,n,i,o){var r,a=!o||!o.hv||o.hv[0],s=!o||!o.hv||o.hv[1],l=o&&o.boundingMode||"all";(a||s)&&("raw"===l?r="group"===t.type?new ki(0,0,+e.width||0,+e.height||0):t.getBoundingRect():(r=t.getBoundingRect(),t.needLocalTransform()&&(o=t.getLocalTransform(),(r=r.clone()).applyTransform(o))),i=Sh(z({width:r.width,height:r.height},e),n,i),a=a?i.x-r.x:0,r=s?i.y-r.y:0,"raw"===l?(t.x=a,t.y=r):(t.x+=a,t.y+=r),t.markRedraw())}function Ih(t){t=t.layoutMode||t.constructor.layoutMode;return $(t)?t:t?{type:t}:null}function Th(l,u,t){var h=t&&t.ignoreSize;j(h)||(h=[h,h]);var e=n(_h[0],0),t=n(_h[1],1);function n(t,e){var n={},i=0,o={},r=0;if(vh(t,function(t){o[t]=l[t]}),vh(t,function(t){c(u,t)&&(n[t]=o[t]=u[t]),p(n,t)&&i++,p(o,t)&&r++}),h[e])return p(u,t[1])?o[t[2]]=null:p(u,t[2])&&(o[t[1]]=null),o;if(2!==r&&i){if(2<=i)return n;for(var a=0;a<t.length;a++){var s=t[a];if(!c(n,s)&&c(l,s)){n[s]=l[s];break}}return n}return o}function c(t,e){return t.hasOwnProperty(e)}function p(t,e){return null!=t[e]&&"auto"!==t[e]}function i(t,e,n){vh(t,function(t){e[t]=n[t]})}i(_h[0],l,e),i(_h[1],l,t)}function Ch(t){return Dh({},t)}function Dh(e,n){return n&&e&&vh(xh,function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e}Z(bh,"vertical"),Z(bh,"horizontal");var Ah,kh,Lh,Ph,Oh=Zo(),Rh=(d(Nh,Ah=wu),Nh.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},Nh.prototype.mergeDefaultAndTheme=function(t,e){var n=Ih(this),i=n?Ch(t):{};O(t,e.getTheme().get(this.mainType)),O(t,this.getDefaultOption()),n&&Th(t,i,n)},Nh.prototype.mergeOption=function(t,e){O(this.option,t,!0);var n=Ih(this);n&&Th(this.option,t,n)},Nh.prototype.optionUpdated=function(t,e){},Nh.prototype.getDefaultOption=function(){var t=this.constructor;if(!(e=t)||!e[rr])return t.defaultOption;var e=Oh(this);if(!e.defaultOption){for(var n=[],i=t;i;){var o=i.prototype.defaultOption;o&&n.push(o),i=i.superClass}for(var r={},a=n.length-1;0<=a;a--)r=O(r,n[a],!0);e.defaultOption=r}return e.defaultOption},Nh.prototype.getReferringComponents=function(t,e){var n=t+"Id";return $o(this.ecModel,t,{index:this.get(t+"Index",!0),id:this.get(n,!0)},e)},Nh.prototype.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")}},Nh.protoInitialize=((C=Nh.prototype).type="component",C.id="",C.name="",C.mainType="",C.subType="",void(C.componentIndex=0)),Nh);function Nh(t,e,n){n=Ah.call(this,t,e,n)||this;return n.uid=Mu("ec_cpt_model"),n}function zh(r){var a={},s=[];return G(r,function(n){var e,i,o=Eh(a,n),t=o.originalDeps=kh(n),t=(e=r,i=[],G(t,function(t){0<=V(e,t)&&i.push(t)}),i);o.entryCount=t.length,0===o.entryCount&&s.push(n),G(t,function(t){V(o.predecessor,t)<0&&o.predecessor.push(t);var e=Eh(a,t);V(e.successor,t)<0&&e.successor.push(n)})}),{graph:a,noEntryList:s}}function Eh(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}lr(Rh,wu),pr(Rh),Ph={},(Lh=Rh).registerSubTypeDefaulter=function(t,e){t=ar(t);Ph[t.main]=e},Lh.determineSubType=function(t,e){var n,i=e.type;return i||(n=ar(t).main,Lh.hasSubTypes(t)&&Ph[n]&&(i=Ph[n](e))),i},kh=function(t){var e=[];return G(Rh.getClassesByMainType(t),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=H(e,function(t){return ar(t).main}),"dataset"!==t&&V(e,"dataset")<=0&&e.unshift("dataset"),e},Rh.topologicalTravel=function(t,e,n,i){if(t.length){var e=zh(e),o=e.graph,r=e.noEntryList,a={};for(G(t,function(t){a[t]=!0});r.length;){var s=r.pop(),l=o[s],u=!!a[s];u&&(n.call(i,s,l.originalDeps.slice()),delete a[s]),G(l.successor,u?c:h)}G(a,function(){throw new Error("")})}function h(t){o[t].entryCount--,0===o[t].entryCount&&r.push(t)}function c(t){a[t]=!0,h(t)}};var Vh=Rh,fs="";"undefined"!=typeof navigator&&(fs=navigator.platform||"");var Jn="rgba(0, 0, 0, 0.2)",Bh={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Jn,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Jn,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Jn,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Jn,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Jn,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Jn,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:fs.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},Fh=yt(["tooltip","label","itemName","itemId","itemGroupId","seriesName"]),Gh="original",Hh="arrayRows",Wh="objectRows",Uh="keyedColumns",Yh="typedArray",Xh="unknown",Zh="column",jh="row",qh={Must:1,Might:2,Not:3},Kh=Zo();function Jh(n,t,e){var o={},i=$h(t);if(!i||!n)return o;var r,a,s=[],l=[],t=t.ecModel,t=Kh(t).datasetMap,e=i.uid+"_"+e.seriesLayoutBy;G(n=n.slice(),function(t,e){t=$(t)?t:n[e]={name:t};"ordinal"===t.type&&null==r&&(r=e,a=c(t)),o[t.name]=[]});var u=t.get(e)||t.set(e,{categoryWayDim:a,valueWayDim:0});function h(t,e,n){for(var i=0;i<n;i++)t.push(e+i)}function c(t){t=t.dimsDef;return t?t.length:1}return G(n,function(t,e){var n,i=t.name,t=c(t);null==r?(n=u.valueWayDim,h(o[i],n,t),h(l,n,t),u.valueWayDim+=t):r===e?(h(o[i],0,t),h(s,0,t)):(n=u.categoryWayDim,h(o[i],n,t),h(l,n,t),u.categoryWayDim+=t)}),s.length&&(o.itemName=s),l.length&&(o.seriesName=l),o}function Qh(t,l,u){var e={};if(!$h(t))return e;var h,c=l.sourceFormat,p=l.dimensionsDefine;c!==Wh&&c!==Uh||G(p,function(t,e){"name"===($(t)?t.name:t)&&(h=e)});var t=function(){for(var t={},e={},n=[],i=0,o=Math.min(5,u);i<o;i++){var r=ec(l.data,c,l.seriesLayoutBy,p,l.startIndex,i);n.push(r);var a=r===qh.Not;if(a&&null==t.v&&i!==h&&(t.v=i),null!=t.n&&t.n!==t.v&&(a||n[t.n]!==qh.Not)||(t.n=i),s(t)&&n[t.n]!==qh.Not)return t;a||(r===qh.Might&&null==e.v&&i!==h&&(e.v=i),null!=e.n&&e.n!==e.v||(e.n=i))}function s(t){return null!=t.v&&null!=t.n}return s(t)?t:s(e)?e:null}();return t&&(e.value=[t.v],t=null!=h?h:t.n,e.itemName=[t],e.seriesName=[t]),e}function $h(t){if(!t.get("data",!0))return $o(t.ecModel,"dataset",{index:t.get("datasetIndex",!0),id:t.get("datasetId",!0)},Jo).models[0]}function tc(t,e){return ec(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,e)}function ec(t,e,n,i,o,r){var a,s,l;if(et(t))return qh.Not;if(i&&($(i=i[r])?(s=i.name,l=i.type):K(i)&&(s=i)),null!=l)return"ordinal"===l?qh.Must:qh.Not;if(e===Hh){var u=t;if(n===jh){for(var h=u[r],c=0;c<(h||[]).length&&c<5;c++)if(null!=(a=m(h[o+c])))return a}else for(c=0;c<u.length&&c<5;c++){var p=u[o+c];if(p&&null!=(a=m(p[r])))return a}}else if(e===Wh){var d=t;if(!s)return qh.Not;for(c=0;c<d.length&&c<5;c++){var f=d[c];if(f&&null!=(a=m(f[s])))return a}}else if(e===Uh){if(!s)return qh.Not;if(!(h=t[s])||et(h))return qh.Not;for(c=0;c<h.length&&c<5;c++)if(null!=(a=m(h[c])))return a}else if(e===Gh)for(var g=t,c=0;c<g.length&&c<5;c++){var y=Vo(f=g[c]);if(!j(y))return qh.Not;if(null!=(a=m(y[r])))return a}function m(t){var e=K(t);return null!=t&&isFinite(t)&&""!==t?e?qh.Might:qh.Not:e&&"-"!==t?qh.Must:void 0}return qh.Not}var nc=yt();var ic,oc,rc,ac=Zo(),sc=Zo(),lc=(uc.prototype.getColorFromPalette=function(t,e,n){var i=No(this.get("color",!0)),o=this.get("colorLayer",!0);return cc(this,ac,i,o,t,e,n)},uc.prototype.clearColorPalette=function(){var t,e;(e=ac)(t=this).paletteIdx=0,e(t).paletteNameMap={}},uc);function uc(){}function hc(t,e,n,i){var o=No(t.get(["aria","decal","decals"]));return cc(t,sc,o,null,e,n,i)}function cc(t,e,n,i,o,r,a){e=e(r=r||t),t=e.paletteIdx||0,r=e.paletteNameMap=e.paletteNameMap||{};if(r.hasOwnProperty(o))return r[o];if((a=(a=null!=a&&i?function(t,e){for(var n=t.length,i=0;i<n;i++)if(t[i].length>e)return t[i];return t[n-1]}(i,a):n)||n)&&a.length){n=a[t];return o&&(r[o]=n),e.paletteIdx=(t+1)%a.length,n}}function pc(t){throw new Error(t)}var dc,fc="\0_ec_inner",ur=(d(gc,dc=wu),gc.prototype.init=function(t,e,n,i,o,r){i=i||{},this.option=null,this._theme=new wu(i),this._locale=new wu(o),this._optionManager=r},gc.prototype.setOption=function(t,e,n){e=vc(e);this._optionManager.setOption(t,n,e),this._resetOption(null,e)},gc.prototype.resetOption=function(t,e){return this._resetOption(t,vc(e))},gc.prototype._resetOption=function(t,e){var n,i=!1,o=this._optionManager;return t&&"recreate"!==t||(n=o.mountOption("recreate"===t),this.option&&"recreate"!==t?(this.restoreData(),this._mergeOption(n,e)):rc(this,n),i=!0),"timeline"!==t&&"media"!==t||this.restoreData(),t&&"recreate"!==t&&"timeline"!==t||(n=o.getTimelineOption(this))&&(i=!0,this._mergeOption(n,e)),t&&"recreate"!==t&&"media"!==t||(o=o.getMediaOption(this)).length&&G(o,function(t){i=!0,this._mergeOption(t,e)},this),i},gc.prototype.mergeOption=function(t){this._mergeOption(t,null)},gc.prototype._mergeOption=function(i,t){var o=this.option,u=this._componentsMap,h=this._componentsCount,n=[],r=yt(),c=t&&t.replaceMergeMainTypeMap;Kh(this).datasetMap=yt(),G(i,function(t,e){null!=t&&(Vh.hasClass(e)?e&&(n.push(e),r.set(e,!0)):o[e]=null==o[e]?P(t):O(o[e],t,!0))}),c&&c.each(function(t,e){Vh.hasClass(e)&&!r.get(e)&&(n.push(e),r.set(e,!0))}),Vh.topologicalTravel(n,Vh.getAllClassMainTypes(),function(r){var t,e=(e=this,n=No(i[t=r]),(t=nc.get(t))&&(e=t(e))?n.concat(e):n),n=u.get(r);Yo(n=Bo(n,e,n?c&&c.get(r)?"replaceMerge":"normalMerge":"replaceAll"),r,Vh),o[r]=null,u.set(r,null),h.set(r,0);var a=[],s=[],l=0;G(n,function(t,e){var n=t.existing,i=t.newOption;if(i){var o=Vh.getClass(r,t.keyInfo.subType,!("series"===r));if(!o)return;n&&n.constructor===o?(n.name=t.keyInfo.name,n.mergeOption(i,this),n.optionUpdated(i,!1)):(e=N({componentIndex:e},t.keyInfo),N(n=new o(i,this,this,e),e),t.brandNew&&(n.__requireNewView=!0),n.init(i,this,this),n.optionUpdated(null,!0))}else n&&(n.mergeOption({},this),n.optionUpdated({},!1));n?(a.push(n.option),s.push(n),l++):(a.push(void 0),s.push(void 0))},this),o[r]=a,u.set(r,s),h.set(r,l),"series"===r&&ic(this)},this),this._seriesIndices||ic(this)},gc.prototype.getOption=function(){var a=P(this.option);return G(a,function(t,e){if(Vh.hasClass(e)){for(var n=No(t),i=n.length,o=!1,r=i-1;0<=r;r--)n[r]&&!Uo(n[r])?o=!0:(n[r]=null,o||i--);n.length=i,a[e]=n}}),delete a[fc],a},gc.prototype.getTheme=function(){return this._theme},gc.prototype.getLocaleModel=function(){return this._locale},gc.prototype.setUpdatePayload=function(t){this._payload=t},gc.prototype.getUpdatePayload=function(){return this._payload},gc.prototype.getComponent=function(t,e){var n=this._componentsMap.get(t);if(n){t=n[e||0];if(t)return t;if(null==e)for(var i=0;i<n.length;i++)if(n[i])return n[i]}},gc.prototype.queryComponents=function(t){var e=t.mainType;if(!e)return[];var n,i=t.index,o=t.id,r=t.name,a=this._componentsMap.get(e);return a&&a.length?(null!=i?(n=[],G(No(i),function(t){a[t]&&n.push(a[t])})):n=null!=o?yc("id",o,a):null!=r?yc("name",r,a):U(a,function(t){return!!t}),mc(n,t)):[]},gc.prototype.findComponents=function(t){var e,n,i=t.query,o=t.mainType,r=(e=o+"Index",n=o+"Id",r=o+"Name",!(i=i)||null==i[e]&&null==i[n]&&null==i[r]?null:{mainType:o,index:i[e],id:i[n],name:i[r]}),o=r?this.queryComponents(r):U(this._componentsMap.get(o),function(t){return!!t});return o=mc(o,t),t.filter?U(o,t.filter):o},gc.prototype.eachComponent=function(t,e,n){var i=this._componentsMap;if(q(t)){var o=e,r=t;i.each(function(t,e){for(var n=0;t&&n<t.length;n++){var i=t[n];i&&r.call(o,e,i,i.componentIndex)}})}else for(var a=K(t)?i.get(t):$(t)?this.findComponents(t):null,s=0;a&&s<a.length;s++){var l=a[s];l&&e.call(n,l,l.componentIndex)}},gc.prototype.getSeriesByName=function(t){var e=Ho(t,null);return U(this._componentsMap.get("series"),function(t){return!!t&&null!=e&&t.name===e})},gc.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},gc.prototype.getSeriesByType=function(e){return U(this._componentsMap.get("series"),function(t){return!!t&&t.subType===e})},gc.prototype.getSeries=function(){return U(this._componentsMap.get("series"),function(t){return!!t})},gc.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},gc.prototype.eachSeries=function(n,i){oc(this),G(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];n.call(i,e,t)},this)},gc.prototype.eachRawSeries=function(e,n){G(this._componentsMap.get("series"),function(t){t&&e.call(n,t,t.componentIndex)})},gc.prototype.eachSeriesByType=function(n,i,o){oc(this),G(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];e.subType===n&&i.call(o,e,t)},this)},gc.prototype.eachRawSeriesByType=function(t,e,n){return G(this.getSeriesByType(t),e,n)},gc.prototype.isSeriesFiltered=function(t){return oc(this),null==this._seriesIndicesMap.get(t.componentIndex)},gc.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},gc.prototype.filterSeries=function(n,i){oc(this);var o=[];G(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];n.call(i,e,t)&&o.push(t)},this),this._seriesIndices=o,this._seriesIndicesMap=yt(o)},gc.prototype.restoreData=function(n){ic(this);var t=this._componentsMap,i=[];t.each(function(t,e){Vh.hasClass(e)&&i.push(e)}),Vh.topologicalTravel(i,Vh.getAllClassMainTypes(),function(e){G(t.get(e),function(t){!t||"series"===e&&function(t,e){if(e){var n=e.seriesIndex,i=e.seriesId,e=e.seriesName;return null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=e&&t.name!==e}}(t,n)||t.restoreData()})})},gc.internalField=(ic=function(t){var e=t._seriesIndices=[];G(t._componentsMap.get("series"),function(t){t&&e.push(t.componentIndex)}),t._seriesIndicesMap=yt(e)},oc=function(t){},void(rc=function(t,e){t.option={},t.option[fc]=1,t._componentsMap=yt({series:[]}),t._componentsCount=yt();var n,i,o=e.aria;$(o)&&null==o.enabled&&(o.enabled=!0),n=e,o=t._theme.option,i=n.color&&!n.colorLayer,G(o,function(t,e){"colorLayer"===e&&i||Vh.hasClass(e)||("object"==typeof t?n[e]=n[e]?O(n[e],t,!1):P(t):null==n[e]&&(n[e]=t))}),O(e,Bh,!1),t._mergeOption(e,null)})),gc);function gc(){return null!==dc&&dc.apply(this,arguments)||this}function yc(e,t,n){if(j(t)){var i=yt();return G(t,function(t){null!=t&&null!=Ho(t,null)&&i.set(t,!0)}),U(n,function(t){return t&&i.get(t[e])})}var o=Ho(t,null);return U(n,function(t){return t&&null!=o&&t[e]===o})}function mc(t,e){return e.hasOwnProperty("subType")?U(t,function(t){return t&&t.subType===e.subType}):t}function vc(t){var e=yt();return t&&G(No(t.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}B(ur,lc);function xc(e){G(bc,function(t){this[t]=X(e[t],e)},this)}var _c=ur,bc=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],wc={},Sc=(Tc.prototype.create=function(n,i){var o=[];G(wc,function(t,e){t=t.create(n,i);o=o.concat(t||[])}),this._coordinateSystems=o},Tc.prototype.update=function(e,n){G(this._coordinateSystems,function(t){t.update&&t.update(e,n)})},Tc.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},Tc.register=function(t,e){wc[t]=e},Tc.get=function(t){return wc[t]},Tc),Mc=/^(min|max)?(.+)$/;function Ic(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}function Tc(){this._coordinateSystems=[]}var Cc=(Ic.prototype.setOption=function(t,e,n){t&&(G(No(t.series),function(t){t&&t.data&&et(t.data)&&pt(t.data)}),G(No(t.dataset),function(t){t&&t.source&&et(t.source)&&pt(t.source)})),t=P(t);var i,o,r,a,s,l,u,h,c,p=this._optionBackup,d=(o=e,r=!p,l=[],u=(i=t).baseOption,h=i.timeline,d=i.options,c=i.media,e=!!i.media,t=!!(d||h||u&&u.timeline),u?(s=u).timeline||(s.timeline=h):((t||e)&&(i.options=i.media=null),s=i),e&&j(c)&&G(c,function(t){t&&t.option&&(t.query?l.push(t):a=a||t)}),f(s),G(d,f),G(l,function(t){return f(t.option)}),{baseOption:s,timelineOptions:d||[],mediaDefault:a,mediaList:l});function f(e){G(o,function(t){t(e,r)})}this._newBaseOption=d.baseOption,p?(d.timelineOptions.length&&(p.timelineOptions=d.timelineOptions),d.mediaList.length&&(p.mediaList=d.mediaList),d.mediaDefault&&(p.mediaDefault=d.mediaDefault)):this._optionBackup=d},Ic.prototype.mountOption=function(t){var e=this._optionBackup;return this._timelineOptions=e.timelineOptions,this._mediaList=e.mediaList,this._mediaDefault=e.mediaDefault,this._currentMediaIndices=[],P(t?e.baseOption:this._newBaseOption)},Ic.prototype.getTimelineOption=function(t){var e,n=this._timelineOptions;return!n.length||(t=t.getComponent("timeline"))&&(e=P(n[t.getCurrentIndex()])),e},Ic.prototype.getMediaOption=function(t){var e=this._api.getWidth(),n=this._api.getHeight(),i=this._mediaList,o=this._mediaDefault,r=[],a=[];if(!i.length&&!o)return a;for(var s,l,u=0,h=i.length;u<h;u++)!function(t,e,n){var i={width:e,height:n,aspectratio:e/n},o=!0;return G(t,function(t,e){var n=e.match(Mc);n&&n[1]&&n[2]&&(e=n[1],n=n[2].toLowerCase(),n=i[n],t=t,("min"===(e=e)?t<=n:"max"===e?n<=t:n===t)||(o=!1))}),o}(i[u].query,e,n)||r.push(u);return(r=!r.length&&o?[-1]:r).length&&(s=r,l=this._currentMediaIndices,s.join(",")!==l.join(","))&&(a=H(r,function(t){return P((-1===t?o:i[t]).option)})),this._currentMediaIndices=r,a},Ic),Dc=G,Ac=$,kc=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Lc(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=kc.length;n<i;n++){var o=kc[n],r=e.normal,a=e.emphasis;r&&r[o]&&(t[o]=t[o]||{},t[o].normal?O(t[o].normal,r[o]):t[o].normal=r[o],r[o]=null),a&&a[o]&&(t[o]=t[o]||{},t[o].emphasis?O(t[o].emphasis,a[o]):t[o].emphasis=a[o],a[o]=null)}}function Pc(t,e,n){var i,o;t&&t[e]&&(t[e].normal||t[e].emphasis)&&(i=t[e].normal,o=t[e].emphasis,i&&(n?(t[e].normal=t[e].emphasis=null,z(t[e],i)):t[e]=i),o&&(t.emphasis=t.emphasis||{},(t.emphasis[e]=o).focus&&(t.emphasis.focus=o.focus),o.blurScope&&(t.emphasis.blurScope=o.blurScope)))}function Oc(t){Pc(t,"itemStyle"),Pc(t,"lineStyle"),Pc(t,"areaStyle"),Pc(t,"label"),Pc(t,"labelLine"),Pc(t,"upperLabel"),Pc(t,"edgeLabel")}function Rc(t,e){var n=Ac(t)&&t[e],i=Ac(n)&&n.textStyle;if(i)for(var o=0,r=Eo.length;o<r;o++){var a=Eo[o];i.hasOwnProperty(a)&&(n[a]=i[a])}}function Nc(t){t&&(Oc(t),Rc(t,"label"),t.emphasis&&Rc(t.emphasis,"label"))}function zc(t){return j(t)?t:t?[t]:[]}function Ec(t){return(j(t)?t[0]:t)||{}}function Vc(e,t){Dc(zc(e.series),function(t){Ac(t)&&function(t){if(Ac(t)){Lc(t),Oc(t),Rc(t,"label"),Rc(t,"upperLabel"),Rc(t,"edgeLabel"),t.emphasis&&(Rc(t.emphasis,"label"),Rc(t.emphasis,"upperLabel"),Rc(t.emphasis,"edgeLabel"));var e=t.markPoint;e&&(Lc(e),Nc(e));var n=t.markLine;n&&(Lc(n),Nc(n));var i=t.markArea;i&&Nc(i);var o=t.data;if("graph"===t.type){var o=o||t.nodes,r=t.links||t.edges;if(r&&!et(r))for(var a=0;a<r.length;a++)Nc(r[a]);G(t.categories,function(t){Oc(t)})}if(o&&!et(o))for(a=0;a<o.length;a++)Nc(o[a]);if((e=t.markPoint)&&e.data)for(var s=e.data,a=0;a<s.length;a++)Nc(s[a]);if((n=t.markLine)&&n.data){var l=n.data;for(a=0;a<l.length;a++)j(l[a])?(Nc(l[a][0]),Nc(l[a][1])):Nc(l[a])}"gauge"===t.type?(Rc(t,"axisLabel"),Rc(t,"title"),Rc(t,"detail")):"treemap"===t.type?(Pc(t.breadcrumb,"itemStyle"),G(t.levels,function(t){Oc(t)})):"tree"===t.type&&Oc(t.leaves)}}(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),Dc(n,function(t){Dc(zc(e[t]),function(t){t&&(Rc(t,"axisLabel"),Rc(t.axisPointer,"label"))})}),Dc(zc(e.parallel),function(t){t=t&&t.parallelAxisDefault;Rc(t,"axisLabel"),Rc(t&&t.axisPointer,"label")}),Dc(zc(e.calendar),function(t){Pc(t,"itemStyle"),Rc(t,"dayLabel"),Rc(t,"monthLabel"),Rc(t,"yearLabel")}),Dc(zc(e.radar),function(t){Rc(t,"name"),t.name&&null==t.axisName&&(t.axisName=t.name,delete t.name),null!=t.nameGap&&null==t.axisNameGap&&(t.axisNameGap=t.nameGap,delete t.nameGap)}),Dc(zc(e.geo),function(t){Ac(t)&&(Nc(t),Dc(zc(t.regions),function(t){Nc(t)}))}),Dc(zc(e.timeline),function(t){Nc(t),Pc(t,"label"),Pc(t,"itemStyle"),Pc(t,"controlStyle",!0);t=t.data;j(t)&&G(t,function(t){$(t)&&(Pc(t,"label"),Pc(t,"itemStyle"))})}),Dc(zc(e.toolbox),function(t){Pc(t,"iconStyle"),Dc(t.feature,function(t){Pc(t,"iconStyle")})}),Rc(Ec(e.axisPointer),"label"),Rc(Ec(e.tooltip).axisPointer,"label")}function Bc(e){e&&G(Fc,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var Fc=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Gc=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Hc=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function Wc(t){var e=t&&t.itemStyle;if(e)for(var n=0;n<Hc.length;n++){var i=Hc[n][1],o=Hc[n][0];null!=e[i]&&(e[o]=e[i])}}function Uc(t){t&&"edge"===t.alignTo&&null!=t.margin&&null==t.edgeDistance&&(t.edgeDistance=t.margin)}function Yc(t){t&&t.downplay&&!t.blur&&(t.blur=t.downplay)}function Xc(e,t){Vc(e,t),e.series=No(e.series),G(e.series,function(t){if($(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),Uc(t.label);var n=t.data;if(n&&!et(n))for(var i=0;i<n.length;i++)Uc(n[i]);null!=t.hoverOffset&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if("gauge"===e){var o=function(t,e){for(var n=e.split(","),i=t,o=0;o<n.length&&null!=(i=i&&i[n[o]]);o++);return i}(t,"pointer.color");null!=o&&function(t,e,n,i){for(var o,r=e.split(","),a=t,s=0;s<r.length-1;s++)null==a[o=r[s]]&&(a[o]={}),a=a[o];!i&&null!=a[r[s]]||(a[r[s]]=n)}(t,"itemStyle.color",o)}else if("bar"===e){if(Wc(t),Wc(t.backgroundStyle),Wc(t.emphasis),(n=t.data)&&!et(n))for(i=0;i<n.length;i++)"object"==typeof n[i]&&(Wc(n[i]),Wc(n[i]&&n[i].emphasis))}else"sunburst"===e?((r=t.highlightPolicy)&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=r)),Yc(t),function t(e,n){if(e)for(var i=0;i<e.length;i++)n(e[i]),e[i]&&t(e[i].children,n)}(t.data,Yc)):"graph"===e||"sankey"===e?(r=t)&&null!=r.focusNodeAdjacency&&(r.emphasis=r.emphasis||{},null==r.emphasis.focus&&(r.emphasis.focus="adjacency")):"map"===e&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&z(t,t.mapLocation));null!=t.hoverAnimation&&(t.emphasis=t.emphasis||{},t.emphasis&&null==t.emphasis.scale&&(t.emphasis.scale=t.hoverAnimation)),Bc(t)}var r}),e.dataRange&&(e.visualMap=e.dataRange),G(Gc,function(t){t=e[t];t&&G(t=!j(t)?[t]:t,function(t){Bc(t)})})}function Zc(v){G(v,function(p,d){var f=[],g=[NaN,NaN],t=[p.stackResultDimension,p.stackedOverDimension],y=p.data,m=p.isStackedByIndex;y.modify(t,function(t,e,n){var i,o,r=y.get(p.stackedDimension,n);if(isNaN(r))return g;m?o=y.getRawIndex(n):i=y.get(p.stackedByDimension,n);for(var a,s,l=NaN,u=d-1;0<=u;u--){var h=v[u];if(0<=(o=!m?h.data.rawIndexOf(h.stackedByDimension,i):o)){var c=h.data.getByRawIndex(h.stackResultDimension,o);if(0<=r&&0<c||r<=0&&c<0){a=r,s=c,h=void 0,h=Math.max(vo(a),vo(s)),s=a+s,r=po<h?s:yo(s,h),l=c;break}}}return f[0]=r,f[1]=l,f})})}var jc,qc,Kc=function(t){this.data=t.data||(t.sourceFormat===Uh?{}:[]),this.sourceFormat=t.sourceFormat||Xh,this.seriesLayoutBy=t.seriesLayoutBy||Zh,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var n=0;n<e.length;n++){var i=e[n];null==i.type&&tc(this,n)===qh.Must&&(i.type="ordinal")}};function Jc(t){return t instanceof Kc}function Qc(t,e,n){n=n||tp(t);var i=e.seriesLayoutBy,o=function(t,e,n,i,o){var r,a;if(!t)return{dimensionsDefine:ep(o),startIndex:a,dimensionsDetectedCount:r};{var s;e===Hh?(s=t,"auto"===i||null==i?np(function(t){null!=t&&"-"!==t&&(K(t)?null==a&&(a=1):a=0)},n,s,10):a=Q(i)?i:i?1:0,o||1!==a||(o=[],np(function(t,e){o[e]=null!=t?t+"":""},n,s,1/0)),r=o?o.length:n===jh?s.length:s[0]?s[0].length:null):e===Wh?o=o||function(t){var e,n=0;for(;n<t.length&&!(e=t[n++]););if(e){var i=[];return G(e,function(t,e){i.push(e)}),i}}(t):e===Uh?o||(o=[],G(t,function(t,e){o.push(e)})):e===Gh&&(t=Vo(t[0]),r=j(t)&&t.length||1)}return{startIndex:a,dimensionsDefine:ep(o),dimensionsDetectedCount:r}}(t,n,i,e.sourceHeader,e.dimensions);return new Kc({data:t,sourceFormat:n,seriesLayoutBy:i,dimensionsDefine:o.dimensionsDefine,startIndex:o.startIndex,dimensionsDetectedCount:o.dimensionsDetectedCount,metaRawOption:P(e)})}function $c(t){return new Kc({data:t,sourceFormat:et(t)?Yh:Gh})}function tp(t){var e=Xh;if(et(t))e=Yh;else if(j(t)){0===t.length&&(e=Hh);for(var n=0,i=t.length;n<i;n++){var o=t[n];if(null!=o){if(j(o)){e=Hh;break}if($(o)){e=Wh;break}}}}else if($(t))for(var r in t)if(xt(t,r)&&F(t[r])){e=Uh;break}return e}function ep(t){if(t){var i=yt();return H(t,function(t,e){var n={name:(t=$(t)?t:{name:t}).name,displayName:t.displayName,type:t.type};if(null==n.name)return n;n.name+="",null==n.displayName&&(n.displayName=n.name);t=i.get(n.name);return t?n.name+="-"+t.count++:i.set(n.name,{count:1}),n})}}function np(t,e,n,i){if(e===jh)for(var o=0;o<n.length&&o<i;o++)t(n[o]?n[o][0]:null,o);else for(var r=n[0]||[],o=0;o<r.length&&o<i;o++)t(r[o],o)}function ip(t){t=t.sourceFormat;return t===Wh||t===Uh}function op(t,e,n,i){return t[i]}var rp=(sp.prototype.getSource=function(){return this._source},sp.prototype.count=function(){return 0},sp.prototype.getItem=function(t,e){},sp.prototype.appendData=function(t){},sp.prototype.clean=function(){},sp.protoInitialize=((y=sp.prototype).pure=!1,void(y.persistent=!0)),sp.internalField=function(){var t;qc=function(t,e,n){var i=n.sourceFormat,o=n.seriesLayoutBy,r=n.startIndex,a=n.dimensionsDefine;N(t,jc[gp(i,o)]),i===Yh?(t.getItem=s,t.count=u,t.fillStorage=l):(n=lp(i,o),t.getItem=X(n,null,e,r,a),o=cp(i,o),t.count=X(o,null,e,r,a))};var s=function(t,e){t-=this._offset,e=e||[];for(var n=this._data,i=this._dimSize,o=i*t,r=0;r<i;r++)e[r]=n[o+r];return e},l=function(t,e,n,i){for(var o=this._data,r=this._dimSize,a=0;a<r;a++){for(var s=i[a],l=null==s[0]?1/0:s[0],u=null==s[1]?-1/0:s[1],h=e-t,c=n[a],p=0;p<h;p++){var d=o[p*r+a];(c[t+p]=d)<l&&(l=d),u<d&&(u=d)}s[0]=l,s[1]=u}},u=function(){return this._data?this._data.length/this._dimSize:0};function e(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}(t={})[Hh+"_"+Zh]={pure:!0,appendData:e},t[Hh+"_"+jh]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[Wh]={pure:!0,appendData:e},t[Uh]={pure:!0,appendData:function(t){var o=this._data;G(t,function(t,e){for(var n=o[e]||(o[e]=[]),i=0;i<(t||[]).length;i++)n.push(t[i])})}},t[Gh]={appendData:e},t[Yh]={persistent:!1,pure:!0,appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}},jc=t}(),sp),ap=((Ki={})[Hh+"_"+Zh]=function(t,e,n,i){return t[i+e]},Ki[Hh+"_"+jh]=function(t,e,n,i,o){i+=e;for(var r=o||[],a=t,s=0;s<a.length;s++){var l=a[s];r[s]=l?l[i]:null}return r},Ki[Wh]=op,Ki[Uh]=function(t,e,n,i,o){for(var r=o||[],a=0;a<n.length;a++){var s=t[n[a].name];r[a]=s?s[i]:null}return r},Ki[Gh]=op,Ki);function sp(t,e){var n=Jc(t)?t:$c(t);this._source=n;t=this._data=n.data;n.sourceFormat===Yh&&(this._offset=0,this._dimSize=e,this._data=t),qc(this,t,n)}function lp(t,e){return ap[gp(t,e)]}function up(t,e,n){return t.length}var hp=((no={})[Hh+"_"+Zh]=function(t,e,n){return Math.max(0,t.length-e)},no[Hh+"_"+jh]=function(t,e,n){t=t[0];return t?Math.max(0,t.length-e):0},no[Wh]=up,no[Uh]=function(t,e,n){n=t[n[0].name];return n?n.length:0},no[Gh]=up,no);function cp(t,e){return hp[gp(t,e)]}function pp(t,e,n){return t[e]}var dp=((gr={})[Hh]=pp,gr[Wh]=function(t,e,n){return t[n]},gr[Uh]=pp,gr[Gh]=function(t,e,n){t=Vo(t);return t instanceof Array?t[e]:t},gr[Yh]=pp,gr);function fp(t){return dp[t]}function gp(t,e){return t===Hh?t+"_"+e:t}function yp(t,e,n){if(t){var i=t.getRawDataItem(e);if(null!=i){var o=t.getStore(),e=o.getSource().sourceFormat;if(null!=n){var n=t.getDimensionIndex(n),r=o.getDimensionProperty(n);return fp(e)(i,n,r)}r=i;return r=e===Gh?Vo(i):r}}}var mp=/\{@(.+?)\}/g,fu=(vp.prototype.getDataParams=function(t,e){var n=this.getData(e),i=this.getRawValue(t,e),o=n.getRawIndex(t),r=n.getName(t),a=n.getRawDataItem(t),s=n.getItemVisual(t,"style"),l=s&&s[n.getItemVisual(t,"drawType")||"fill"],u=s&&s.stroke,t=this.mainType,s="series"===t,n=n.userOutput&&n.userOutput.get();return{componentType:t,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:s?this.subType:null,seriesIndex:this.seriesIndex,seriesId:s?this.id:null,seriesName:s?this.name:null,name:r,dataIndex:o,data:a,dataType:e,value:i,color:l,borderColor:u,dimensionNames:n?n.fullDimensions:null,encode:n?n.encode:null,$vars:["seriesName","name","value"]}},vp.prototype.getFormattedLabel=function(i,t,e,n,o,r){t=t||"normal";var a=this.getData(e),e=this.getDataParams(i,e);return r&&(e.value=r.interpolatedValue),null!=n&&j(e.value)&&(e.value=e.value[n]),"function"==typeof(o=o||a.getItemModel(i).get("normal"===t?["label","formatter"]:[t,"label","formatter"]))?(e.status=t,e.dimensionIndex=n,o(e)):"string"==typeof o?gh(o,e).replace(mp,function(t,e){var n=e.length,e=e;"["===e.charAt(0)&&"]"===e.charAt(n-1)&&(e=+e.slice(1,n-1));n=yp(a,i,e);return r&&j(r.interpolatedValue)&&(0<=(e=a.getDimensionIndex(e))&&(n=r.interpolatedValue[e])),null!=n?n+"":""}):void 0},vp.prototype.getRawValue=function(t,e){return yp(this.getData(e),t)},vp.prototype.formatTooltip=function(t,e,n){},vp);function vp(){}function xp(t){var e,n;return $(t)?t.type&&(n=t):e=t,{markupText:e,markupFragment:n}}function _p(t){return new Cp(t)}var bp,wp,Sp,Mp,Ip,Tp,Cp=(Lp.prototype.perform=function(t){var e,n=this._upstream,i=t&&t.skip;this._dirty&&n&&((r=this.context).data=r.outputData=n.context.outputData),this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!i&&(e=this._plan(this.context));var o=l(this._modBy),r=this._modDataCount||0,a=l(t&&t.modBy),s=t&&t.modDataCount||0;function l(t){return t=!(1<=t)?1:t}o===a&&r===s||(e="reset"),!this._dirty&&"reset"!==e||(this._dirty=!1,d=this._doReset(i)),this._modBy=a,this._modDataCount=s;t=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var u=this._dueIndex,h=Math.min(null!=t?this._dueIndex+t:1/0,this._dueEnd);if(!i&&(d||u<h)){var c=this._progress;if(j(c))for(var p=0;p<c.length;p++)this._doProgress(c[p],u,h,a,s);else this._doProgress(c,u,h,a,s)}this._dueIndex=h;var d=null!=this._settedOutputEnd?this._settedOutputEnd:h;this._outputDueEnd=d}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},Lp.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},Lp.prototype._doProgress=function(t,e,n,i,o){Dp.reset(e,n,i,o),this._callingProgress=t,this._callingProgress({start:e,end:n,count:n-e,next:Dp.next},this.context)},Lp.prototype._doReset=function(t){var e;this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null,!t&&this._reset&&((n=this._reset(this.context))&&n.progress&&(e=n.forceFirstProgress,n=n.progress),j(n)&&!n.length&&(n=null)),this._progress=n,this._modBy=this._modDataCount=null;var n=this._downstream;return n&&n.dirty(),e},Lp.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},Lp.prototype.pipe=function(t){this._downstream===t&&!this._dirty||((this._downstream=t)._upstream=this,t.dirty())},Lp.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},Lp.prototype.getUpstream=function(){return this._upstream},Lp.prototype.getDownstream=function(){return this._downstream},Lp.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t},Lp),Dp=Tp={reset:function(t,e,n,i){wp=t,bp=e,Sp=n,Mp=i,Ip=Math.ceil(Mp/Sp),Tp.next=1<Sp&&0<Mp?kp:Ap}};function Ap(){return wp<bp?wp++:null}function kp(){var t=wp%Ip*Sp+Math.ceil(wp/Ip),t=bp<=wp?null:t<Mp?t:wp;return wp++,t}function Lp(t){this._reset=(t=t||{}).reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}function Pp(t,e){e=e&&e.type;return"ordinal"===e?t:null==(t="time"===e&&"number"!=typeof t&&null!=t&&"-"!==t?+Mo(t):t)||""===t?NaN:+t}var Op=yt({number:function(t){return parseFloat(t)},time:function(t){return+Mo(t)},trim:function(t){return"string"==typeof t?ht(t):t}});function Rp(t){return Op.get(t)}var Np={lt:function(t,e){return t<e},lte:function(t,e){return t<=e},gt:function(t,e){return e<t},gte:function(t,e){return e<=t}},zp=(Gp.prototype.evaluate=function(t){return"number"==typeof t?this._opFn(t,this._rvalFloat):this._opFn(Ao(t),this._rvalFloat)},Gp),Ep=(Fp.prototype.evaluate=function(t,e){var n=typeof t,i=typeof e,o="number"==n?t:Ao(t),r="number"==i?e:Ao(e),a=isNaN(o),s=isNaN(r);return a&&(o=this._incomparable),s&&(r=this._incomparable),a&&s&&(i="string"==i,(n="string"==n)&&(o=i?t:0),i&&(r=n?e:0)),o<r?this._resultLT:r<o?-this._resultLT:0},Fp),Vp=(Bp.prototype.evaluate=function(t){var e,n=t===this._rval;return n||((e=typeof t)===this._rvalTypeof||"number"!=e&&"number"!==this._rvalTypeof||(n=Ao(t)===this._rvalFloat)),this._isEQ?n:!n},Bp);function Bp(t,e){this._rval=e,this._isEQ=t,this._rvalTypeof=typeof e,this._rvalFloat=Ao(e)}function Fp(t,e){t="desc"===t;this._resultLT=t?1:-1,this._incomparable="min"===(e=null==e?t?"min":"max":e)?-1/0:1/0}function Gp(t,e){"number"!=typeof e&&pc(""),this._opFn=Np[t],this._rvalFloat=Ao(e)}var Hp=(Wp.prototype.getRawData=function(){throw new Error("not supported")},Wp.prototype.getRawDataItem=function(t){throw new Error("not supported")},Wp.prototype.cloneRawData=function(){},Wp.prototype.getDimensionInfo=function(t){},Wp.prototype.cloneAllDimensionInfo=function(){},Wp.prototype.count=function(){},Wp.prototype.retrieveValue=function(t,e){},Wp.prototype.retrieveValueFromItem=function(t,e){},Wp.prototype.convertValue=Pp,Wp);function Wp(){}function Up(t){return Kp(t.sourceFormat)||pc(""),t.data}function Yp(t){var e=t.sourceFormat,n=t.data;if(Kp(e)||pc(""),e===Hh){for(var i=[],o=0,r=n.length;o<r;o++)i.push(n[o].slice());return i}if(e===Wh){for(i=[],o=0,r=n.length;o<r;o++)i.push(N({},n[o]));return i}}function Xp(t,e,n){if(null!=n)return"number"==typeof n||!isNaN(n)&&!xt(e,n)?t[n]:xt(e,n)?e[n]:void 0}function Zp(t){return P(t)}var jp=yt();function qp(t,e){var n=No(t),t=n.length;t||pc("");for(var i=0,o=t;i<o;i++)e=function(t,i){i.length||pc(""),$(t)||pc("");var e=t.type,n=jp.get(e);n||pc("");e=H(i,function(t){return function(t,e){var n=new Hp,i=t.data,o=n.sourceFormat=t.sourceFormat,r=t.startIndex;t.seriesLayoutBy!==Zh&&pc("");var a=[],s={},l=t.dimensionsDefine;if(l)G(l,function(t,e){var n=t.name,t={index:e,name:n,displayName:t.displayName};a.push(t),null!=n&&(xt(s,n)&&pc(""),s[n]=t)});else for(var u=0;u<t.dimensionsDetectedCount;u++)a.push({index:u});var h=lp(o,Zh);e.__isBuiltIn&&(n.getRawDataItem=function(t){return h(i,r,a,t)},n.getRawData=X(Up,null,t)),n.cloneRawData=X(Yp,null,t),e=cp(o,Zh),n.count=X(e,null,i,r,a);var c=fp(o);n.retrieveValue=function(t,e){t=h(i,r,a,t);return p(t,e)};var p=n.retrieveValueFromItem=function(t,e){if(null!=t){var n=a[e];return n?c(t,e,n.name):void 0}};return n.getDimensionInfo=X(Xp,null,a,s),n.cloneAllDimensionInfo=X(Zp,null,a),n}(t,n)});return H(No(n.transform({upstream:e[0],upstreamList:e,config:P(t.config)})),function(t,e){$(t)||pc(""),t.data||pc(""),Kp(tp(t.data))||pc("");var n=i[0],n=n&&0===e&&!t.dimensions?((e=n.startIndex)&&(t.data=n.data.slice(0,e).concat(t.data)),{seriesLayoutBy:Zh,sourceHeader:e,dimensions:n.metaRawOption.dimensions}):{seriesLayoutBy:Zh,sourceHeader:0,dimensions:t.dimensions};return Qc(t.data,n,null)})}(n[i],e),i!==o-1&&(e.length=Math.max(e.length,1));return e}function Kp(t){return t===Hh||t===Wh}var Jp,mu="undefined",Qp=typeof Uint32Array==mu?Array:Uint32Array,$p=typeof Uint16Array==mu?Array:Uint16Array,td=typeof Int32Array==mu?Array:Int32Array,T=typeof Float64Array==mu?Array:Float64Array,ed={float:T,int:td,ordinal:Array,number:Array,time:T};function nd(t){return 65535<t?Qp:$p}function id(){return[1/0,-1/0]}function od(t,e,n,i,o){n=ed[n||"float"];if(o){var r=t[e],a=r&&r.length;if(a!==i){for(var s=new n(i),l=0;l<a;l++)s[l]=r[l];t[e]=s}}else t[e]=new n(i)}var rd=(ld.prototype.initData=function(t,e,n){this._provider=t,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var i=t.getSource(),o=this.defaultDimValueGetter=Jp[i.sourceFormat];this._dimValueGetter=n||o,this._rawExtent=[],ip(i),this._dimensions=H(e,function(t){return{type:t.type,property:t.property}}),this._initDataFromProvider(0,t.count())},ld.prototype.getProvider=function(){return this._provider},ld.prototype.getSource=function(){return this._provider.getSource()},ld.prototype.ensureCalculationDimension=function(t,e){var n=this._calcDimNameToIdx,i=this._dimensions,o=n.get(t);if(null!=o){if(i[o].type===e)return o}else o=i.length;return i[o]={type:e},n.set(t,o),this._chunks[o]=new ed[e||"float"](this._rawCount),this._rawExtent[o]=id(),o},ld.prototype.collectOrdinalMeta=function(t,e){var n=this._chunks[t],i=this._dimensions[t],o=this._rawExtent,r=i.ordinalOffset||0,a=n.length;0===r&&(o[t]=id());for(var s=o[t],l=r;l<a;l++){var u=n[l]=e.parseAndCollect(n[l]);s[0]=Math.min(u,s[0]),s[1]=Math.max(u,s[1])}i.ordinalMeta=e,i.ordinalOffset=a,i.type="ordinal"},ld.prototype.getOrdinalMeta=function(t){return this._dimensions[t].ordinalMeta},ld.prototype.getDimensionProperty=function(t){t=this._dimensions[t];return t&&t.property},ld.prototype.appendData=function(t){var e=this._provider,n=this.count();e.appendData(t);t=e.count();return e.persistent||(t+=n),n<t&&this._initDataFromProvider(n,t,!0),[n,t]},ld.prototype.appendValues=function(t,e){for(var n=this._chunks,i=this._dimensions,o=i.length,r=this._rawExtent,a=this.count(),s=a+Math.max(t.length,e||0),l=0;l<o;l++){var u=i[l];od(n,l,u.type,s,!0)}for(var h=[],c=a;c<s;c++)for(var p=c-a,d=0;d<o;d++){var u=i[d],f=Jp.arrayRows.call(this,t[p]||h,u.property,p,d);n[d][c]=f;var g=r[d];f<g[0]&&(g[0]=f),f>g[1]&&(g[1]=f)}return{start:a,end:this._rawCount=this._count=s}},ld.prototype._initDataFromProvider=function(t,e,n){for(var i=this._provider,o=this._chunks,r=this._dimensions,a=r.length,s=this._rawExtent,l=H(r,function(t){return t.property}),u=0;u<a;u++){var h=r[u];s[u]||(s[u]=id()),od(o,u,h.type,e,n)}if(i.fillStorage)i.fillStorage(t,e,o,s);else for(var c=[],p=t;p<e;p++)for(var c=i.getItem(p,c),d=0;d<a;d++){var f=o[d],g=this._dimValueGetter(c,l[d],p,d);f[p]=g;f=s[d];g<f[0]&&(f[0]=g),g>f[1]&&(f[1]=g)}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=e,this._extent=[]},ld.prototype.count=function(){return this._count},ld.prototype.get=function(t,e){if(!(0<=e&&e<this._count))return NaN;t=this._chunks[t];return t?t[this.getRawIndex(e)]:NaN},ld.prototype.getValues=function(t,e){var n=[],i=[];if(null==e){e=t,t=[];for(var o=0;o<this._dimensions.length;o++)i.push(o)}else i=t;for(var o=0,r=i.length;o<r;o++)n.push(this.get(i[o],e));return n},ld.prototype.getByRawIndex=function(t,e){if(!(0<=e&&e<this._rawCount))return NaN;t=this._chunks[t];return t?t[e]:NaN},ld.prototype.getSum=function(t){var e=0;if(this._chunks[t])for(var n=0,i=this.count();n<i;n++){var o=this.get(t,n);isNaN(o)||(e+=o)}return e},ld.prototype.getMedian=function(t){var e=[];this.each([t],function(t){isNaN(t)||e.push(t)});var n=e.sort(function(t,e){return t-e}),t=this.count();return 0===t?0:t%2==1?n[(t-1)/2]:(n[t/2]+n[t/2-1])/2},ld.prototype.indexOfRawIndex=function(t){if(t>=this._rawCount||t<0)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,o=this._count-1;i<=o;){var r=(i+o)/2|0;if(e[r]<t)i=1+r;else{if(!(e[r]>t))return r;o=r-1}}return-1},ld.prototype.indicesOfNearest=function(t,e,n){var i=this._chunks[t],o=[];if(!i)return o;null==n&&(n=1/0);for(var r=1/0,a=-1,s=0,l=0,u=this.count();l<u;l++){var h=e-i[this.getRawIndex(l)],c=Math.abs(h);c<=n&&((c<r||c===r&&0<=h&&a<0)&&(r=c,a=h,s=0),h===a&&(o[s++]=l))}return o.length=s,o},ld.prototype.getIndices=function(){var t=this._indices;if(t){var e=t.constructor,n=this._count;if(e===Array)for(var i=new e(n),o=0;o<n;o++)i[o]=t[o];else i=new e(t.buffer,0,n)}else for(i=new(e=nd(this._rawCount))(this.count()),o=0;o<i.length;o++)i[o]=o;return i},ld.prototype.filter=function(t,e){if(!this._count)return this;for(var n=this.clone(),i=n.count(),o=new(nd(n._rawCount))(i),r=[],a=t.length,s=0,l=t[0],u=n._chunks,h=0;h<i;h++){var c=void 0,p=n.getRawIndex(h);if(0===a)c=e(h);else if(1===a)c=e(u[l][p],h);else{for(var d=0;d<a;d++)r[d]=u[t[d]][p];r[d]=h,c=e.apply(null,r)}c&&(o[s++]=p)}return s<i&&(n._indices=o),n._count=s,n._extent=[],n._updateGetRawIdx(),n},ld.prototype.selectRange=function(t){var e=this.clone(),n=e._count;if(!n)return this;var i=Y(t),o=i.length;if(!o)return this;var r=e.count(),a=new(nd(e._rawCount))(r),s=0,l=i[0],u=t[l][0],h=t[l][1],c=e._chunks,l=!1;if(!e._indices){var p=0;if(1===o){for(var d=c[i[0]],f=0;f<n;f++){var g=d[f];(u<=g&&g<=h||isNaN(g))&&(a[s++]=p),p++}l=!0}else if(2===o){for(var d=c[i[0]],y=c[i[1]],m=t[i[1]][0],v=t[i[1]][1],f=0;f<n;f++){var g=d[f],x=y[f];(u<=g&&g<=h||isNaN(g))&&(m<=x&&x<=v||isNaN(x))&&(a[s++]=p),p++}l=!0}}if(!l)if(1===o)for(f=0;f<r;f++){var _=e.getRawIndex(f);(u<=(g=c[i[0]][_])&&g<=h||isNaN(g))&&(a[s++]=_)}else for(f=0;f<r;f++){for(var b=!0,w=(_=e.getRawIndex(f),0);w<o;w++){var S=i[w];((g=c[S][_])<t[S][0]||g>t[S][1])&&(b=!1)}b&&(a[s++]=e.getRawIndex(f))}return s<r&&(e._indices=a),e._count=s,e._extent=[],e._updateGetRawIdx(),e},ld.prototype.map=function(t,e){var n=this.clone(t);return this._updateDims(n,t,e),n},ld.prototype.modify=function(t,e){this._updateDims(this,t,e)},ld.prototype._updateDims=function(t,e,n){for(var i=t._chunks,o=[],r=e.length,a=t.count(),s=[],l=t._rawExtent,u=0;u<e.length;u++)l[e[u]]=id();for(var h=0;h<a;h++){for(var c=t.getRawIndex(h),p=0;p<r;p++)s[p]=i[e[p]][c];s[r]=h;var d=n&&n.apply(null,s);if(null!=d)for("object"!=typeof d&&(o[0]=d,d=o),u=0;u<d.length;u++){var f=e[u],g=d[u],y=l[f],f=i[f];f&&(f[c]=g),g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}},ld.prototype.lttbDownSample=function(t,e){var n,i=this.clone([t],!0),o=i._chunks[t],r=this.count(),a=0,s=Math.floor(1/e),l=this.getRawIndex(0),u=new(nd(this._rawCount))(Math.ceil(r/s)+2);u[a++]=l;for(var h=1;h<r-1;h+=s){for(var c=Math.min(h+s,r-1),p=Math.min(h+2*s,r),d=(p+c)/2,f=0,g=c;g<p;g++){var y=this.getRawIndex(g),m=o[y];isNaN(m)||(f+=m)}f/=p-c;for(var c=h,v=Math.min(h+s,r),x=h-1,_=o[l],b=-1,w=c,g=c;g<v;g++)m=o[y=this.getRawIndex(g)],isNaN(m)||b<(n=Math.abs((x-d)*(m-_)-(x-g)*(f-_)))&&(b=n,w=y);l=u[a++]=w}return u[a++]=this.getRawIndex(r-1),i._count=a,i._indices=u,i.getRawIndex=this._getRawIdx,i},ld.prototype.downSample=function(t,e,n,i){for(var o=this.clone([t],!0),r=o._chunks,a=[],s=Math.floor(1/e),l=r[t],u=this.count(),h=o._rawExtent[t]=id(),c=new(nd(this._rawCount))(Math.ceil(u/s)),p=0,d=0;d<u;d+=s){u-d<s&&(a.length=s=u-d);for(var f=0;f<s;f++){var g=this.getRawIndex(d+f);a[f]=l[g]}var y=n(a),m=this.getRawIndex(Math.min(d+i(a,y)||0,u-1));(l[m]=y)<h[0]&&(h[0]=y),y>h[1]&&(h[1]=y),c[p++]=m}return o._count=p,o._indices=c,o._updateGetRawIdx(),o},ld.prototype.each=function(t,e){if(this._count)for(var n=t.length,i=this._chunks,o=0,r=this.count();o<r;o++){var a=this.getRawIndex(o);switch(n){case 0:e(o);break;case 1:e(i[t[0]][a],o);break;case 2:e(i[t[0]][a],i[t[1]][a],o);break;default:for(var s=0,l=[];s<n;s++)l[s]=i[t[s]][a];l[s]=o,e.apply(null,l)}}},ld.prototype.getDataExtent=function(t){var e=this._chunks[t],n=id();if(!e)return n;var i=this.count();if(!this._indices)return this._rawExtent[t].slice();if(o=this._extent[t])return o.slice();for(var o,r=(o=n)[0],a=o[1],s=0;s<i;s++){var l=e[this.getRawIndex(s)];l<r&&(r=l),a<l&&(a=l)}return this._extent[t]=o=[r,a]},ld.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var n=[],i=this._chunks,o=0;o<i.length;o++)n.push(i[o][e]);return n},ld.prototype.clone=function(t,e){var n,i,o=new ld,r=this._chunks,a=t&&W(t,function(t,e){return t[e]=!0,t},{});if(a)for(var s=0;s<r.length;s++)o._chunks[s]=a[s]?(n=r[s],i=void 0,(i=n.constructor)===Array?n.slice():new i(n)):r[s];else o._chunks=r;return this._copyCommonProps(o),e||(o._indices=this._cloneIndices()),o._updateGetRawIdx(),o},ld.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=P(this._extent),t._rawExtent=P(this._rawExtent)},ld.prototype._cloneIndices=function(){if(this._indices){var t=this._indices.constructor,e=void 0;if(t===Array)for(var n=this._indices.length,e=new t(n),i=0;i<n;i++)e[i]=this._indices[i];else e=new t(this._indices);return e}return null},ld.prototype._getRawIdxIdentity=function(t){return t},ld.prototype._getRawIdx=function(t){return t<this._count&&0<=t?this._indices[t]:-1},ld.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},ld.internalField=void(Jp={arrayRows:ud,objectRows:function(t,e,n,i){return Pp(t[e],this._dimensions[i])},keyedColumns:ud,original:function(t,e,n,i){t=t&&(null==t.value?t:t.value);return Pp(t instanceof Array?t[i]:t,this._dimensions[i])},typedArray:function(t,e,n,i){return t[i]}}),ld),ad=(sd.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},sd.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,9e10<this._versionSignBase&&(this._versionSignBase=0)},sd.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},sd.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},sd.prototype._createSource=function(){this._setLocalSource([],[]);var t,e,n,i,o,r,a,s=this._sourceHost,l=this._getUpstreamSourceManagers(),u=!!l.length;cd(s)?(i=s,o=a=t=void 0,e=u?((n=l[0]).prepareSource(),t=(o=n.getSource()).data,a=o.sourceFormat,[n._getVersionSign()]):(a=et(t=i.get("data",!0))?Yh:Gh,[]),r=this._getSourceMetaRawOption()||{},n=o&&o.metaRawOption||{},i=rt(r.seriesLayoutBy,n.seriesLayoutBy)||null,o=rt(r.sourceHeader,n.sourceHeader)||null,r=rt(r.dimensions,n.dimensions),a=i!==n.seriesLayoutBy||!!o!=!!n.sourceHeader||r?[Qc(t,{seriesLayoutBy:i,sourceHeader:o,dimensions:r},a)]:[]):(s=s,e=u?(a=(l=this._applyTransform(l)).sourceList,l.upstreamSignList):(a=[Qc(s.get("source",!0),this._getSourceMetaRawOption(),null)],[])),this._setLocalSource(a,e)},sd.prototype._applyTransform=function(t){var e,n=this._sourceHost,i=n.get("transform",!0),o=n.get("fromTransformResult",!0);null==o||1!==t.length&&pd("");var r=[],a=[];return G(t,function(t){t.prepareSource();var e=t.getSource(o||0);null==o||e||pd(""),r.push(e),a.push(t._getVersionSign())}),i?e=qp(i,r,n.componentIndex):null!=o&&(e=[(n=r[0],new Kc({data:n.data,sourceFormat:n.sourceFormat,seriesLayoutBy:n.seriesLayoutBy,dimensionsDefine:P(n.dimensionsDefine),startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount}))]),{sourceList:e,upstreamSignList:a}},sd.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),e=0;e<t.length;e++){var n=t[e];if(n._isDirty()||this._upstreamSignList[e]!==n._getVersionSign())return!0}},sd.prototype.getSource=function(t){var e=this._sourceList[t=t||0];if(e)return e;e=this._getUpstreamSourceManagers();return e[0]&&e[0].getSource(t)},sd.prototype.getSharedDataStore=function(t){var e=t.makeStoreSchema();return this._innerGetDataStore(e.dimensions,t.source,e.hash)},sd.prototype._innerGetDataStore=function(t,e,n){var i=this._storeList,o=i[0],r=(o=o||(i[0]={}))[n];return r||(i=this._getUpstreamSourceManagers()[0],cd(this._sourceHost)&&i?r=i._innerGetDataStore(t,e,n):(r=new rd).initData(new rp(e,t.length),t),o[n]=r),r},sd.prototype._getUpstreamSourceManagers=function(){var t=this._sourceHost;if(cd(t)){var e=$h(t);return e?[e.getSourceManager()]:[]}return H((t=t).get("transform",!0)||t.get("fromTransformResult",!0)?$o(t.ecModel,"dataset",{index:t.get("fromDatasetIndex",!0),id:t.get("fromDatasetId",!0)},Jo).models:[],function(t){return t.getSourceManager()})},sd.prototype._getSourceMetaRawOption=function(){var t,e,n,i=this._sourceHost;return cd(i)?(t=i.get("seriesLayoutBy",!0),e=i.get("sourceHeader",!0),n=i.get("dimensions",!0)):this._getUpstreamSourceManagers().length||(t=(i=i).get("seriesLayoutBy",!0),e=i.get("sourceHeader",!0),n=i.get("dimensions",!0)),{seriesLayoutBy:t,sourceHeader:e,dimensions:n}},sd);function sd(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}function ld(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=yt()}function ud(t,e,n,i){return Pp(t[i],this._dimensions[i])}function hd(t){t.option.transform&&pt(t.option.transform)}function cd(t){return"series"===t.mainType}function pd(t){throw new Error(t)}var dd="line-height:1";function fd(t,e){var n=t.color||"#6e7079",i=t.fontSize||12,o=t.fontWeight||"400",r=t.color||"#464646",a=t.fontSize||14,t=t.fontWeight||"900";return"html"===e?{nameStyle:"font-size:"+ch(i+"")+"px;color:"+ch(n)+";font-weight:"+ch(o+""),valueStyle:"font-size:"+ch(a+"")+"px;color:"+ch(r)+";font-weight:"+ch(t+"")}:{nameStyle:{fontSize:i,fill:n,fontWeight:o},valueStyle:{fontSize:a,fill:r,fontWeight:t}}}var gd=[0,10,20,30],yd=["","\n","\n\n","\n\n\n"];function md(t,e){return e.type=t,e}function vd(t){return xt(xd,t.type)&&xd[t.type]}var xd={section:{planLayout:function(t){var e=t.blocks.length,n=1<e||0<e&&!t.noHeader,i=0;G(t.blocks,function(t){vd(t).planLayout(t);var e=t.__gapLevelBetweenSubBlocks;i<=e&&(i=e+(!n||e&&("section"!==t.type||t.noHeader)?0:1))}),t.__gapLevelBetweenSubBlocks=i},build:function(t,e,n,i){var o=e.noHeader,r=bd(e),a=function(n,t,e,i){var o=[],r=t.blocks||[];ut(!r||j(r)),r=r||[];var a=n.orderMode;{var s,l;t.sortBlocks&&a&&(r=r.slice(),xt(s={valueAsc:"asc",valueDesc:"desc"},a)?(l=new Ep(s[a],null),r.sort(function(t,e){return l.evaluate(t.sortParam,e.sortParam)})):"seriesDesc"===a&&r.reverse())}var u=bd(t);if(G(r,function(t,e){e=vd(t).build(n,t,0<e?u.html:0,i);null!=e&&o.push(e)}),o.length)return"richText"===n.renderMode?o.join(u.richText):wd(o.join(""),e)}(t,e,o?n:r.html,i);if(o)return a;e=ph(e.header,"ordinal",t.useUTC),i=fd(i,t.renderMode).nameStyle;return"richText"===t.renderMode?Sd(t,e,i)+r.richText+a:wd('<div style="'+i+";"+dd+';">'+ch(e)+"</div>"+a,n)}},nameValue:{planLayout:function(t){t.__gapLevelBetweenSubBlocks=0},build:function(t,e,n,i){var o=t.renderMode,r=e.noName,a=e.noValue,s=!e.markerType,l=e.name,u=e.value,h=t.useUTC;if(!r||!a){var c=s?"":t.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",o),p=r?"":ph(l,"ordinal",h),d=e.valueType,f=a?[]:j(u)?H(u,function(t,e){return ph(t,j(d)?d[e]:d,h)}):[ph(u,j(d)?d[0]:d,h)],l=!s||!r,e=!s&&r,u=fd(i,o),i=u.nameStyle,u=u.valueStyle;return"richText"===o?(s?"":c)+(r?"":Sd(t,p,i))+(a?"":function(t,e,n,i,o){o=[o],i=i?10:20;return n&&o.push({padding:[0,0,0,i],align:"right"}),t.markupStyleCreator.wrapRichTextStyle(e.join(" "),o)}(t,f,l,e,u)):wd((s?"":c)+(r?"":'<span style="'+i+";"+(!s?"margin-left:2px":"")+'">'+ch(p)+"</span>")+(a?"":function(t,e,n,i){n=n?"10px":"20px";return'<span style="'+(e?"float:right;margin-left:"+n:"")+";"+i+'">'+H(t,ch).join("&nbsp;&nbsp;")+"</span>"}(f,l,e,u)),n)}}}};function _d(t,e,n,i,o,r){if(t){var a=vd(t);return a.planLayout(t),a.build({useUTC:o,renderMode:n,orderMode:i,markupStyleCreator:e},t,0,r)}}function bd(t){t=t.__gapLevelBetweenSubBlocks;return{html:gd[t],richText:yd[t]}}function wd(t,e){return'<div style="'+("margin: "+e+"px 0 0")+";"+dd+';">'+t+'<div style="clear:both"></div></div>'}function Sd(t,e,n){return t.markupStyleCreator.wrapRichTextStyle(e,n)}function Md(t,e){return yh(t.getData().getItemVisual(e,"style")[t.visualDrawType])}function Id(t,e){t=t.get("padding");return null!=t?t:"richText"===e?[8,10]:10}var Td=(Cd.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},Cd.prototype.makeTooltipMarker=function(t,e,n){var i,o,r="richText"===n?this._generateStyleName():null,t=(e=K(i={color:e,type:t,renderMode:n,markerId:r})?{color:i,extraCssText:o}:i||{},t=e.color,n=e.type,o=e.extraCssText,i=e.renderMode||"html",t?"html"===i?"subItem"===n?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+ch(t)+";"+(o||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+ch(t)+";"+(o||"")+'"></span>':{renderMode:i,content:"{"+(e.markerId||"markerX")+"|} ",style:"subItem"===n?{width:4,height:4,borderRadius:2,backgroundColor:t}:{width:10,height:10,borderRadius:5,backgroundColor:t}}:"");return K(t)?t:(this.richTextStyles[r]=t.style,t.content)},Cd.prototype.wrapRichTextStyle=function(t,e){var n={};j(e)?G(e,function(t){return N(n,t)}):N(n,e);e=this._generateStyleName();return this.richTextStyles[e]=n,"{"+e+"|"+t+"}"},Cd);function Cd(){this.richTextStyles={},this._nextStyleNameId=Lo()}function Dd(t){var e,n,i,o,r,a,s,l,u,h,c,p=t.series,d=t.dataIndex,f=t.multipleSeries,g=p.getData(),y=g.mapDimensionsAll("defaultedTooltip"),m=y.length,v=p.getRawValue(d),x=j(v),t=Md(p,d);function _(t,e){e=s.getDimensionInfo(e);e&&!1!==e.otherDims.tooltip&&(l?c.push(md("nameValue",{markerType:"subItem",markerColor:a,name:e.displayName,value:t,valueType:e.type})):(u.push(t),h.push(e.type)))}1<m||x&&!m?(e=(n=(i=v,o=d,r=y,a=t,s=p.getData(),l=W(i,function(t,e,n){n=s.getDimensionInfo(n);return t||n&&!1!==n.tooltip&&null!=n.displayName},!1),u=[],h=[],c=[],r.length?G(r,function(t){_(yp(s,o,t),t)}):G(i,_),{inlineValues:u,inlineValueTypes:h,blocks:c})).inlineValueTypes,r=n.blocks,n=(i=n.inlineValues)[0]):m?(m=g.getDimensionInfo(y[0]),n=i=yp(g,d,y[0]),e=m.type):n=i=x?v[0]:v;v=Wo(p),p=v&&p.name||"",d=g.getName(d),d=f?p:d;return md("section",{header:p,noHeader:f||!v,sortParam:n,blocks:[md("nameValue",{markerType:"item",markerColor:t,name:d,noName:!ht(d),value:i,valueType:e})].concat(r||[])})}var Ad=Zo();function kd(t,e){return t.getName(e)||t.getId(e)}var Ld,Pd="__universalTransitionEnabled",Jn=(d(Od,Ld=Vh),Od.prototype.init=function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=_p({count:Nd,reset:zd}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),(Ad(this).sourceManager=new ad(this)).prepareSource();n=this.getInitialData(t,n);Vd(n,this),this.dataTask.context.data=n,Ad(this).dataBeforeProcessed=n,Rd(this),this._initSelectedMapFromData(n)},Od.prototype.mergeDefaultAndTheme=function(t,e){var n=Ih(this),i=n?Ch(t):{},o=this.subType;Vh.hasClass(o),O(t,e.getTheme().get(this.subType)),O(t,this.getDefaultOption()),zo(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Th(t,i,n)},Od.prototype.mergeOption=function(t,e){t=O(this.option,t,!0),this.fillDataTextStyle(t.data);var n=Ih(this);n&&Th(this.option,t,n);n=Ad(this).sourceManager;n.dirty(),n.prepareSource();e=this.getInitialData(t,e);Vd(e,this),this.dataTask.dirty(),this.dataTask.context.data=e,Ad(this).dataBeforeProcessed=e,Rd(this),this._initSelectedMapFromData(e)},Od.prototype.fillDataTextStyle=function(t){if(t&&!et(t))for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&zo(t[n],"label",e)},Od.prototype.getInitialData=function(t,e){},Od.prototype.appendData=function(t){this.getRawData().appendData(t.data)},Od.prototype.getData=function(t){var e=Fd(this);if(e){e=e.context.data;return null==t?e:e.getLinkedData(t)}return Ad(this).data},Od.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},Od.prototype.setData=function(t){var e,n=Fd(this);n&&((e=n.context).outputData=t,n!==this.dataTask&&(e.data=t)),Ad(this).data=t},Od.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return yt(t)},Od.prototype.getSourceManager=function(){return Ad(this).sourceManager},Od.prototype.getSource=function(){return this.getSourceManager().getSource()},Od.prototype.getRawData=function(){return Ad(this).dataBeforeProcessed},Od.prototype.getColorBy=function(){return this.get("colorBy")||"series"},Od.prototype.isColorBySeries=function(){return"series"===this.getColorBy()},Od.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},Od.prototype.formatTooltip=function(t,e,n){return Dd({series:this,dataIndex:t,multipleSeries:e})},Od.prototype.isAnimationEnabled=function(){if(w.node)return!1;var t=this.getShallow("animation");return!!(t=t&&this.getData().count()>this.getShallow("animationThreshold")?!1:t)},Od.prototype.restoreData=function(){this.dataTask.dirty()},Od.prototype.getColorFromPalette=function(t,e,n){var i=this.ecModel;return lc.prototype.getColorFromPalette.call(this,t,e,n)||i.getColorFromPalette(t,e,n)},Od.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},Od.prototype.getProgressive=function(){return this.get("progressive")},Od.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},Od.prototype.select=function(t,e){this._innerSelect(this.getData(e),t)},Od.prototype.unselect=function(t,e){var n=this.option.selectedMap;if(n)for(var i=this.getData(e),o=0;o<t.length;o++){var r=kd(i,t[o]);n[r]=!1,this._selectedDataIndicesMap[r]=-1}},Od.prototype.toggleSelect=function(t,e){for(var n=[],i=0;i<t.length;i++)n[0]=t[i],this.isSelected(t[i],e)?this.unselect(n,e):this.select(n,e)},Od.prototype.getSelectedDataIndices=function(){for(var t=this._selectedDataIndicesMap,e=Y(t),n=[],i=0;i<e.length;i++){var o=t[e[i]];0<=o&&n.push(o)}return n},Od.prototype.isSelected=function(t,e){var n=this.option.selectedMap;return n&&n[kd(this.getData(e),t)]||!1},Od.prototype.isUniversalTransitionEnabled=function(){if(this[Pd])return!0;var t=this.option.universalTransition;return!!t&&(!0===t||t&&t.enabled)},Od.prototype._innerSelect=function(t,e){var n,i=this.option.selectedMode,o=e.length;if(i&&o)if("multiple"===i)for(var r=this.option.selectedMap||(this.option.selectedMap={}),a=0;a<o;a++){var s=e[a],l=kd(t,s);r[l]=!0,this._selectedDataIndicesMap[l]=t.getRawIndex(s)}else"single"!==i&&!0!==i||(l=kd(t,n=e[o-1]),this.option.selectedMap=((i={})[l]=!0,i),this._selectedDataIndicesMap=((i={})[l]=t.getRawIndex(n),i))},Od.prototype._initSelectedMapFromData=function(n){var i;this.option.selectedMap||(i=[],n.hasItemOption&&n.each(function(t){var e=n.getRawDataItem(t);e&&e.selected&&i.push(t)}),0<i.length&&this._innerSelect(n,i))},Od.registerClass=function(t){return Vh.registerClass(t)},Od.protoInitialize=((C=Od.prototype).type="series.__base__",C.seriesIndex=0,C.ignoreStyleOnData=!1,C.hasSymbolVisual=!1,C.defaultSymbol="circle",C.visualStyleAccessPath="itemStyle",void(C.visualDrawType="fill")),Od);function Od(){var t=null!==Ld&&Ld.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}function Rd(t){var e,n,i=t.name;Wo(t)||(t.name=(t=(e=(t=t).getRawData()).mapDimensionsAll("seriesName"),n=[],G(t,function(t){t=e.getDimensionInfo(t);t.displayName&&n.push(t.displayName)}),n.join(" ")||i))}function Nd(t){return t.model.getRawData().count()}function zd(t){t=t.model;return t.setData(t.getRawData().cloneShallow()),Ed}function Ed(t,e){e.outputData&&t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Vd(e,n){G(mt(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(t){e.wrapMethod(t,Z(Bd,n))})}function Bd(t,e){t=Fd(t);return t&&t.setOutputEnd((e||this).count()),e}function Fd(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){e=n.currentTask;return!e||(n=e.agentStubMap)&&(e=n.get(t.uid)),e}}B(Jn,fu),B(Jn,lc),lr(Jn,Vh);var Gd=Jn,fs=(Hd.prototype.init=function(t,e){},Hd.prototype.render=function(t,e,n,i){},Hd.prototype.dispose=function(t,e){},Hd.prototype.updateView=function(t,e,n,i){},Hd.prototype.updateLayout=function(t,e,n,i){},Hd.prototype.updateVisual=function(t,e,n,i){},Hd.prototype.blurSeries=function(t,e){},Hd);function Hd(){this.group=new ro,this.uid=Mu("viewComponent")}sr(fs),pr(fs);var Wd=fs;function Ud(){var r=Zo();return function(t){var e=r(t),n=t.pipelineContext,i=!!e.large,o=!!e.progressiveRender,t=e.large=!(!n||!n.large),n=e.progressiveRender=!(!n||!n.progressiveRender);return!(i==t&&o==n)&&"reset"}}var Yd=Zo(),Xd=Ud(),ur=(Zd.prototype.init=function(t,e){},Zd.prototype.render=function(t,e,n,i){},Zd.prototype.highlight=function(t,e,n,i){qd(t.getData(),i,"emphasis")},Zd.prototype.downplay=function(t,e,n,i){qd(t.getData(),i,"normal")},Zd.prototype.remove=function(t,e){this.group.removeAll()},Zd.prototype.dispose=function(t,e){},Zd.prototype.updateView=function(t,e,n,i){this.render(t,e,n,i)},Zd.prototype.updateLayout=function(t,e,n,i){this.render(t,e,n,i)},Zd.prototype.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},Zd.markUpdateMethod=function(t,e){Yd(t).updateMethod=e},Zd.protoInitialize=void(Zd.prototype.type="chart"),Zd);function Zd(){this.group=new ro,this.uid=Mu("viewChart"),this.renderTask=_p({plan:Kd,reset:Jd}),this.renderTask.context={view:this}}function jd(t,e,n){t&&("emphasis"===e?xl:_l)(t,n)}function qd(e,t,n){var i,o=Xo(e,t),r=t&&null!=t.highlightKey?(i=t.highlightKey,t=null==(t=Ws[i])&&Hs<=32?Ws[i]=Hs++:t):null;null!=o?G(No(o),function(t){jd(e.getItemGraphicEl(t),n,r)}):e.eachItemGraphicEl(function(t){jd(t,n,r)})}function Kd(t){return Xd(t.model)}function Jd(t){var e=t.model,n=t.ecModel,i=t.api,o=t.payload,r=e.pipelineContext.progressiveRender,a=t.view,t=o&&Yd(o).updateMethod,t=r?"incrementalPrepareRender":t&&a[t]?t:"render";return"render"!==t&&a[t](e,n,i,o),Qd[t]}sr(ur),pr(ur);var Qd={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)}}},$d=ur,tf="\0__throttleOriginMethod",ef="\0__throttleRate",nf="\0__throttleType";function of(t,o,r){var a,s,l,u,h,c=0,p=0,d=null;function f(){p=(new Date).getTime(),d=null,t.apply(l,u||[])}o=o||0;function e(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];a=(new Date).getTime(),l=this,u=t;var n=h||o,i=h||r;h=null,s=a-(i?c:p)-n,clearTimeout(d),i?d=setTimeout(f,n):0<=s?f():d=setTimeout(f,-s),c=a}return e.clear=function(){d&&(clearTimeout(d),d=null)},e.debounceNextCall=function(t){h=t},e}function rf(t,e,n,i){var o=t[e];if(o){var r=o[tf]||o,a=o[nf];if(o[ef]!==n||a!==i){if(null==n||!i)return t[e]=r;(o=t[e]=of(r,n,"debounce"===i))[tf]=r,o[nf]=i,o[ef]=n}return o}}var af=Zo(),sf={itemStyle:dr(io,!0),lineStyle:dr(vi,!0)},lf={lineStyle:"stroke",itemStyle:"fill"};function uf(t,e){return t.visualStyleMapper||sf[e]||sf.itemStyle}function hf(t,e){return t.visualDrawType||lf[e]||"fill"}var cf,y={createOnAllSeries:!0,performRawSeries:!0,reset:function(o,t){var e=o.getData(),n=o.visualStyleAccessPath||"itemStyle",i=o.getModel(n),r=uf(o,n)(i),i=i.getShallow("decal");i&&(e.setVisual("decal",i),i.dirty=!0);var a=hf(o,n),n=r[a],s=q(n)?n:null,n="auto"===r.fill||"auto"===r.stroke;if(r[a]&&!s&&!n||(n=o.getColorFromPalette(o.name,null,t.getSeriesCount()),r[a]||(r[a]=n,e.setVisual("colorFromPalette",!0)),r.fill="auto"===r.fill||"function"==typeof r.fill?n:r.fill,r.stroke="auto"===r.stroke||"function"==typeof r.stroke?n:r.stroke),e.setVisual("style",r),e.setVisual("drawType",a),!t.isSeriesFiltered(o)&&s)return e.setVisual("colorFromPalette",!1),{dataEach:function(t,e){var n=o.getDataParams(e),i=N({},r);i[a]=s(n),t.setItemVisual(e,"style",i)}}}},pf=new wu,Ki={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(!t.ignoreStyleOnData&&!e.isSeriesFiltered(t)){var e=t.getData(),i=t.visualStyleAccessPath||"itemStyle",o=uf(t,i),r=e.getVisual("drawType");return{dataEach:e.hasItemOption?function(t,e){var n=t.getRawDataItem(e);n&&n[i]&&(pf.option=n[i],n=o(pf),N(t.ensureUniqueItemVisual(e,"style"),n),pf.option.decal&&(t.setItemVisual(e,"decal",pf.option.decal),pf.option.decal.dirty=!0),r in n&&t.setItemVisual(e,"colorFromPalette",!1))}:null}}}},no={performRawSeries:!0,overallReset:function(e){var i=yt();e.eachSeries(function(t){var e,n=t.getColorBy();t.isColorBySeries()||(e=t.type+"-"+n,(n=i.get(e))||i.set(e,n={}),af(t).scope=n)}),e.eachSeries(function(i){var o,r,a,s,t,l;i.isColorBySeries()||e.isSeriesFiltered(i)||(o=i.getRawData(),r={},a=i.getData(),s=af(i).scope,t=i.visualStyleAccessPath||"itemStyle",l=hf(i,t),a.each(function(t){var e=a.getRawIndex(t);r[e]=t}),o.each(function(t){var e,n=r[t];a.getItemVisual(n,"colorFromPalette")&&(e=a.ensureUniqueItemVisual(n,"style"),n=o.getName(t)||t+"",t=o.count(),e[l]=i.getColorFromPalette(n,s,t))}))})}},df=function(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},gr=(wt(ff,cf=as),ff.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},ff.prototype.getDefaultShape=function(){return new df},ff.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=Math.max(e.r,0),r=e.startAngle,a=e.endAngle,s=e.clockwise,l=Math.cos(r),e=Math.sin(r);t.moveTo(l*o+n,e*o+i),t.arc(n,i,o,r,a,!s)},ff);function ff(t){return cf.call(this,t)||this}gr.prototype.type="arc";var gf=gr,yf=Math.PI;mf.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(t){t=t.overallTask;t&&t.dirty()})},mf.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,n=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,i=i&&i.modDataCount;return{step:n,modBy:null!=i?Math.ceil(i/n):null,modDataCount:i}}},mf.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},mf.prototype.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),o=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,e=t.get("large")&&i>=t.get("largeThreshold"),i="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:o,modDataCount:i,large:e}},mf.prototype.restorePipelines=function(t){var i=this,o=i._pipelineMap=yt();t.eachSeries(function(t){var e=t.getProgressive(),n=t.uid;o.set(n,{id:n,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:e&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(e||700),count:0}),i._pipe(t,t.dataTask)})},mf.prototype.prepareStageTasks=function(){var n=this._stageTaskMap,i=this.api.getModel(),o=this.api;G(this._allHandlers,function(t){var e=n.get(t.uid)||n.set(t.uid,{});ut(!(t.reset&&t.overallReset),""),t.reset&&this._createSeriesStageTask(t,e,i,o),t.overallReset&&this._createOverallStageTask(t,e,i,o)},this)},mf.prototype.prepareView=function(t,e,n,i){var o=t.renderTask,r=o.context;r.model=e,r.ecModel=n,r.api=i,o.__block=!t.incrementalPrepareRender,this._pipe(e,o)},mf.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},mf.prototype.performVisualTasks=function(t,e,n){this._performStageTasks(this._visualHandlers,t,e,n)},mf.prototype._performStageTasks=function(t,s,l,u){u=u||{};var h=!1,c=this;function p(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}G(t,function(i,t){var e,n,o,r,a;u.visualType&&u.visualType!==i.visualType||(e=(r=c._stageTaskMap.get(i.uid)).seriesTaskMap,(n=r.overallTask)?((r=n.agentStubMap).each(function(t){p(u,t)&&(t.dirty(),o=!0)}),o&&n.dirty(),c.updatePayload(n,l),a=c.getPerformArgs(n,u.block),r.each(function(t){t.perform(a)}),n.perform(a)&&(h=!0)):e&&e.each(function(t,e){p(u,t)&&t.dirty();var n=c.getPerformArgs(t,u.block);n.skip=!i.performRawSeries&&s.isSeriesFiltered(t.context.model),c.updatePayload(t,l),t.perform(n)&&(h=!0)}))}),this.unfinished=h||this.unfinished},mf.prototype.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e=t.dataTask.perform()||e}),this.unfinished=e||this.unfinished},mf.prototype.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}}while(e=e.getUpstream())})},mf.prototype.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},mf.prototype._createSeriesStageTask=function(n,t,i,o){var r=this,a=t.seriesTaskMap,s=t.seriesTaskMap=yt(),e=n.seriesType,t=n.getTargetSeries;function l(t){var e=t.uid,e=s.set(e,a&&a.get(e)||_p({plan:wf,reset:Sf,count:Tf}));e.context={model:t,ecModel:i,api:o,useClearVisual:n.isVisual&&!n.isLayout,plan:n.plan,reset:n.reset,scheduler:r},r._pipe(t,e)}n.createOnAllSeries?i.eachRawSeries(l):e?i.eachRawSeriesByType(e,l):t&&t(i,o).each(l)},mf.prototype._createOverallStageTask=function(t,e,n,i){var o=this,r=e.overallTask=e.overallTask||_p({reset:vf});r.context={ecModel:n,api:i,overallReset:t.overallReset,scheduler:o};var a=r.agentStubMap,s=r.agentStubMap=yt(),l=t.seriesType,e=t.getTargetSeries,u=!0,h=!1;function c(t){var e=t.uid,e=s.set(e,a&&a.get(e)||(h=!0,_p({reset:xf,onDirty:bf})));e.context={model:t,overallProgress:u},e.agent=r,e.__block=u,o._pipe(t,e)}ut(!t.createOnAllSeries,""),l?n.eachRawSeriesByType(l,c):e?e(n,i).each(c):(u=!1,G(n.getSeries(),c)),h&&r.dirty()},mf.prototype._pipe=function(t,e){t=t.uid,t=this._pipelineMap.get(t);t.head||(t.head=e),t.tail&&t.tail.pipe(e),(t.tail=e).__idxInPipeline=t.count++,e.__pipeline=t},mf.wrapStageHandler=function(t,e){return(t=q(t)?{overallReset:t,seriesType:function(t){Cf=null;try{t(Df,Af)}catch(t){}return Cf}(t)}:t).uid=Mu("stageHandler"),e&&(t.visualType=e),t},mu=mf;function mf(t,e,n,i){this._stageTaskMap=yt(),this.ecInstance=t,this.api=e,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}function vf(t){t.overallReset(t.ecModel,t.api,t.payload)}function xf(t){return t.overallProgress&&_f}function _f(){this.agent.dirty(),this.getDownstream().dirty()}function bf(){this.agent&&this.agent.dirty()}function wf(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function Sf(t){t.useClearVisual&&t.data.clearAllVisual();t=t.resetDefines=No(t.reset(t.model,t.ecModel,t.api,t.payload));return 1<t.length?H(t,function(t,e){return If(e)}):Mf}var Mf=If(0);function If(r){return function(t,e){var n=e.data,i=e.resetDefines[r];if(i&&i.dataEach)for(var o=t.start;o<t.end;o++)i.dataEach(n,o);else i&&i.progress&&i.progress(t,n)}}function Tf(t){return t.data.count()}var Cf,Df={},Af={};function kf(t,e){for(var n in e.prototype)t[n]=_t}kf(Df,_c),kf(Af,xc),Df.eachSeriesByType=Df.eachRawSeriesByType=function(t){Cf=t},Df.eachComponent=function(t){"series"===t.mainType&&t.subType&&(Cf=t.subType)};function Lf(){return{axisLine:{lineStyle:{color:Of}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}}var Pf=mu,T=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],C={color:T,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],T]},Of="#B9B8CE",Jn="#100C2A",fs=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],ur={darkMode:!0,color:fs,backgroundColor:Jn,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:Of}},textStyle:{color:Of},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:Of}},dataZoom:{borderColor:"#71708A",textStyle:{color:Of},brushStyle:{color:"rgba(135,163,206,0.3)"},handleStyle:{color:"#353450",borderColor:"#C5CBE3"},moveHandleStyle:{color:"#B0B6C3",opacity:.3},fillerColor:"rgba(135,163,206,0.2)",emphasis:{handleStyle:{borderColor:"#91B7F2",color:"#4D587D"},moveHandleStyle:{color:"#636D9A",opacity:.7}},dataBackground:{lineStyle:{color:"#71708A",width:1},areaStyle:{color:"#71708A"}},selectedDataBackground:{lineStyle:{color:"#87A3CE"},areaStyle:{color:"#87A3CE"}}},visualMap:{textStyle:{color:Of}},timeline:{lineStyle:{color:Of},label:{color:Of},controlStyle:{color:Of,borderColor:Of}},calendar:{itemStyle:{color:Jn},dayLabel:{color:Of},monthLabel:{color:Of},yearLabel:{color:Of}},timeAxis:Lf(),logAxis:Lf(),valueAxis:Lf(),categoryAxis:Lf(),line:{symbol:"circle"},graph:{color:fs},gauge:{title:{color:Of},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:Of},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};ur.categoryAxis.splitLine.show=!1;var io=ur,Rf=(Nf.prototype.normalizeQuery=function(t){var e,a,s,l={},u={},h={};return K(t)?(e=ar(t),l.mainType=e.main||null,l.subType=e.sub||null):(a=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1},G(t,function(t,e){for(var n=!1,i=0;i<a.length;i++){var o=a[i],r=e.lastIndexOf(o);0<r&&r===e.length-o.length&&("data"!==(r=e.slice(0,r))&&(l.mainType=r,l[o.toLowerCase()]=t,n=!0))}s.hasOwnProperty(e)&&(u[e]=t,n=!0),n||(h[e]=t)})),{cptQuery:l,dataQuery:u,otherQuery:h}},Nf.prototype.filter=function(t,e){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,o=n.packedEvent,r=n.model,a=n.view;if(!r||!a)return!0;var s=e.cptQuery,n=e.dataQuery;return l(s,r,"mainType")&&l(s,r,"subType")&&l(s,r,"index","componentIndex")&&l(s,r,"name")&&l(s,r,"id")&&l(n,o,"name")&&l(n,o,"dataIndex")&&l(n,o,"dataType")&&(!a.filterForExposedEvent||a.filterForExposedEvent(t,e.otherQuery,i,o));function l(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},Nf.prototype.afterTrigger=function(){this.eventInfo=null},Nf),vi={createOnAllSeries:!0,performRawSeries:!0,reset:function(o,t){var e=o.getData();if(o.legendIcon&&e.setVisual("legendIcon",o.legendIcon),o.hasSymbolVisual){var r=o.get("symbol"),a=o.get("symbolSize"),n=o.get("symbolKeepAspect"),s=o.get("symbolRotate"),l=o.get("symbolOffset"),u=q(r),h=q(a),c=q(s),p=q(l),i=u||h||c||p,d=!u&&r?r:o.defaultSymbol;if(e.setVisual({legendIcon:o.legendIcon||d,symbol:d,symbolSize:h?null:a,symbolKeepAspect:n,symbolRotate:c?null:s,symbolOffset:p?null:l}),!t.isSeriesFiltered(o))return{dataEach:i?function(t,e){var n=o.getRawValue(e),i=o.getDataParams(e);u&&t.setItemVisual(e,"symbol",r(n,i)),h&&t.setItemVisual(e,"symbolSize",a(n,i)),c&&t.setItemVisual(e,"symbolRotate",s(n,i)),p&&t.setItemVisual(e,"symbolOffset",l(n,i))}:null}}}},gr={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(t.hasSymbolVisual&&!e.isSeriesFiltered(t))return{dataEach:t.getData().hasItemOption?function(t,e){var n=t.getItemModel(e),i=n.getShallow("symbol",!0),o=n.getShallow("symbolSize",!0),r=n.getShallow("symbolRotate",!0),a=n.getShallow("symbolOffset",!0),n=n.getShallow("symbolKeepAspect",!0);null!=i&&t.setItemVisual(e,"symbol",i),null!=o&&t.setItemVisual(e,"symbolSize",o),null!=r&&t.setItemVisual(e,"symbolRotate",r),null!=a&&t.setItemVisual(e,"symbolOffset",a),null!=n&&t.setItemVisual(e,"symbolKeepAspect",n)}:null}}};function Nf(){}function zf(t,e,n){switch(n){case"color":return t.getItemVisual(e,"style")[t.getVisual("drawType")];case"opacity":return t.getItemVisual(e,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getItemVisual(e,n)}}function Ef(t,e){switch(e){case"color":return t.getVisual("style")[t.getVisual("drawType")];case"opacity":return t.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getVisual(e)}}function Vf(t,e,n,i){switch(n){case"color":t.ensureUniqueItemVisual(e,"style")[t.getVisual("drawType")]=i,t.setItemVisual(e,"colorFromPalette",!1);break;case"opacity":t.ensureUniqueItemVisual(e,"style").opacity=i;break;case"symbol":case"symbolSize":case"liftZ":t.setItemVisual(e,n,i)}}function Bf(r,t){G([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(o){t(o[0],function(t,e,n){var i;t=N({},t),n.dispatchAction(N(t,{type:o[1],seriesIndex:(t=t,i=[],e.eachComponent({mainType:"series",subType:r,query:t},function(t){i.push(t.seriesIndex)}),i)}))})})}function Ff(t,e,a,n,s){var l=t+e;a.isSilent(l)||n.eachComponent({mainType:"series",subType:"pie"},function(t){for(var e,n,i=t.seriesIndex,o=s.selected,r=0;r<o.length;r++)o[r].seriesIndex===i&&(n=Xo(e=t.getData(),s.fromActionPayload),a.trigger(l,{type:l,seriesId:t.id,name:j(n)?e.getName(n[0]):e.getName(n),selected:N({},t.option.selectedMap)}))})}function Gf(t,e,n){for(var i;t&&(!e(t)||(i=t,!n));)t=t.__hostTarget||t.parent;return i}var Hf,Wf=Math.round(9*Math.random()),Uf="function"==typeof Object.defineProperty,mu=(jf.prototype.get=function(t){return this._guard(t)[this._id]},jf.prototype.set=function(t,e){t=this._guard(t);return Uf?Object.defineProperty(t,this._id,{value:e,enumerable:!1,configurable:!0}):t[this._id]=e,this},jf.prototype.delete=function(t){return!!this.has(t)&&(delete this._guard(t)[this._id],!0)},jf.prototype.has=function(t){return!!this._guard(t)[this._id]},jf.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},jf),Yf={},Xf=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1},T=(wt(Zf,Hf=as),Zf.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Zf.prototype.getDefaultShape=function(){return new Xf},Zf.prototype.buildPath=function(t,e){var n,i,o,r;r=this.subPixelOptimize?(n=(r=vs(Yf,e,this.style)).x1,i=r.y1,o=r.x2,r.y2):(n=e.x1,i=e.y1,o=e.x2,e.y2);e=e.percent;0!==e&&(t.moveTo(n,i),e<1&&(o=n*(1-e)+o*e,r=i*(1-e)+r*e),t.lineTo(o,r))},Zf.prototype.pointAt=function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]},Zf);function Zf(t){return Hf.call(this,t)||this}function jf(){this._id="__ec_inner_"+Wf++}T.prototype.type="line";var qf,Kf=T,Jf=function(){this.cx=0,this.cy=0,this.r=0},Jn=(wt(Qf,qf=as),Qf.prototype.getDefaultShape=function(){return new Jf},Qf.prototype.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)},Qf);function Qf(t){return qf.call(this,t)||this}Jn.prototype.type="circle";var $f=Jn,tg=Ba.CMD,eg=[[],[],[]],ng=Math.sqrt,ig=Math.atan2;function og(t,e){if(e){for(var n,i,o,r,a=t.data,s=t.len(),l=tg.M,u=tg.C,h=tg.L,c=tg.R,p=tg.A,d=tg.Q,f=0,g=0;f<s;){switch(n=a[f++],g=f,i=0,n){case l:case h:i=1;break;case u:i=3;break;case d:i=2;break;case p:var y=e[4],m=e[5],v=ng(e[0]*e[0]+e[1]*e[1]),x=ng(e[2]*e[2]+e[3]*e[3]),_=ig(-e[1]/x,e[0]/v);a[f]*=v,a[f++]+=y,a[f]*=x,a[f++]+=m,a[f++]*=v,a[f++]*=x,a[f++]+=_,a[f++]+=_,g=f+=2;break;case c:r[0]=a[f++],r[1]=a[f++],zt(r,r,e),a[g++]=r[0],a[g++]=r[1],r[0]+=a[f++],r[1]+=a[f++],zt(r,r,e),a[g++]=r[0],a[g++]=r[1]}for(o=0;o<i;o++){var b=eg[o];b[0]=a[f++],b[1]=a[f++],zt(b,b,e),a[g++]=b[0],a[g++]=b[1]}}t.increaseVersion()}}var rg=Math.sqrt,ag=Math.sin,sg=Math.cos,lg=Math.PI;function ug(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function hg(t,e){return(t[0]*e[0]+t[1]*e[1])/(ug(t)*ug(e))}function cg(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(hg(t,e))}function pg(t,e,n,i,o,r,a,s,l,u,h){var c=l*(lg/180),p=sg(c)*(t-n)/2+ag(c)*(e-i)/2,d=-1*ag(c)*(t-n)/2+sg(c)*(e-i)/2,l=p*p/(a*a)+d*d/(s*s);1<l&&(a*=rg(l),s*=rg(l));var l=(o===r?-1:1)*rg((a*a*(s*s)-a*a*(d*d)-s*s*(p*p))/(a*a*(d*d)+s*s*(p*p)))||0,o=l*a*d/s,l=l*-s*p/a,t=(t+n)/2+sg(c)*o-ag(c)*l,n=(e+i)/2+ag(c)*o+sg(c)*l,e=cg([1,0],[(p-o)/a,(d-l)/s]),i=[(p-o)/a,(d-l)/s],d=[(-1*p-o)/a,(-1*d-l)/s],l=cg(i,d);hg(i,d)<=-1&&(l=lg),(l=1<=hg(i,d)?0:l)<0&&(d=Math.round(l/lg*1e6)/1e6,l=2*lg+d%2*lg),h.addData(u,t,n,a,s,e,l,c,r)}var dg=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,fg=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;var gg,yg=(wt(mg,gg=as),mg.prototype.applyTransform=function(t){},mg);function mg(){return null!==gg&&gg.apply(this,arguments)||this}function vg(t){return null!=t.setData}function xg(t,e){var n=function(t){var e=new Ba;if(!t)return e;var n,i=0,o=0,r=i,a=o,s=Ba.CMD,l=t.match(dg);if(!l)return e;for(var u=0;u<l.length;u++){for(var h=l[u],c=h.charAt(0),p=void 0,d=h.match(fg)||[],f=d.length,g=0;g<f;g++)d[g]=parseFloat(d[g]);for(var y=0;y<f;){var m=void 0,v=void 0,x=void 0,_=void 0,b=void 0,w=void 0,S=void 0,M=i,I=o,T=void 0,C=void 0;switch(c){case"l":i+=d[y++],o+=d[y++],p=s.L,e.addData(p,i,o);break;case"L":i=d[y++],o=d[y++],p=s.L,e.addData(p,i,o);break;case"m":i+=d[y++],o+=d[y++],p=s.M,e.addData(p,i,o),r=i,a=o,c="l";break;case"M":i=d[y++],o=d[y++],p=s.M,e.addData(p,i,o),r=i,a=o,c="L";break;case"h":i+=d[y++],p=s.L,e.addData(p,i,o);break;case"H":i=d[y++],p=s.L,e.addData(p,i,o);break;case"v":o+=d[y++],p=s.L,e.addData(p,i,o);break;case"V":o=d[y++],p=s.L,e.addData(p,i,o);break;case"C":p=s.C,e.addData(p,d[y++],d[y++],d[y++],d[y++],d[y++],d[y++]),i=d[y-2],o=d[y-1];break;case"c":p=s.C,e.addData(p,d[y++]+i,d[y++]+o,d[y++]+i,d[y++]+o,d[y++]+i,d[y++]+o),i+=d[y-2],o+=d[y-1];break;case"S":m=i,v=o,T=e.len(),C=e.data,n===s.C&&(m+=i-C[T-4],v+=o-C[T-3]),p=s.C,M=d[y++],I=d[y++],i=d[y++],o=d[y++],e.addData(p,m,v,M,I,i,o);break;case"s":m=i,v=o,T=e.len(),C=e.data,n===s.C&&(m+=i-C[T-4],v+=o-C[T-3]),p=s.C,M=i+d[y++],I=o+d[y++],i+=d[y++],o+=d[y++],e.addData(p,m,v,M,I,i,o);break;case"Q":M=d[y++],I=d[y++],i=d[y++],o=d[y++],p=s.Q,e.addData(p,M,I,i,o);break;case"q":M=d[y++]+i,I=d[y++]+o,i+=d[y++],o+=d[y++],p=s.Q,e.addData(p,M,I,i,o);break;case"T":m=i,v=o,T=e.len(),C=e.data,n===s.Q&&(m+=i-C[T-4],v+=o-C[T-3]),i=d[y++],o=d[y++],p=s.Q,e.addData(p,m,v,i,o);break;case"t":m=i,v=o,T=e.len(),C=e.data,n===s.Q&&(m+=i-C[T-4],v+=o-C[T-3]),i+=d[y++],o+=d[y++],p=s.Q,e.addData(p,m,v,i,o);break;case"A":x=d[y++],_=d[y++],b=d[y++],w=d[y++],S=d[y++],pg(M=i,I=o,i=d[y++],o=d[y++],w,S,x,_,b,p=s.A,e);break;case"a":x=d[y++],_=d[y++],b=d[y++],w=d[y++],S=d[y++],pg(M=i,I=o,i+=d[y++],o+=d[y++],w,S,x,_,b,p=s.A,e)}}"z"!==c&&"Z"!==c||(p=s.Z,e.addData(p),i=r,o=a),n=p}return e.toStatic(),e}(t),e=N({},e);return e.buildPath=function(t){var e;vg(t)?(t.setData(n.data),(e=t.getContext())&&t.rebuildPath(e,1)):n.rebuildPath(e=t,1)},e.applyTransform=function(t){og(n,t),this.dirtyShape()},e}function _g(t,e){return new yg(xg(t,e))}function bg(t,e){e=e||{};var n=new as;return t.shape&&n.setShape(t.shape),n.setStyle(t.style),e.bakeTransform?og(n.path,t.getComputedTransform()):e.toLocal?n.setLocalTransform(t.getComputedTransform()):n.copyTransform(t),n.buildPath=t.buildPath,n.applyTransform=n.applyTransform,n.z=t.z,n.z2=t.z2,n.zlevel=t.zlevel,n}var wg,Sg=function(){this.cx=0,this.cy=0,this.rx=0,this.ry=0},fs=(wt(Mg,wg=as),Mg.prototype.getDefaultShape=function(){return new Sg},Mg.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=e.rx,r=e.ry,a=.5522848*o,e=.5522848*r;t.moveTo(n-o,i),t.bezierCurveTo(n-o,i-e,n-a,i-r,n,i-r),t.bezierCurveTo(n+a,i-r,n+o,i-e,n+o,i),t.bezierCurveTo(n+o,i+e,n+a,i+r,n,i+r),t.bezierCurveTo(n-a,i+r,n-o,i+e,n-o,i),t.closePath()},Mg);function Mg(t){return wg.call(this,t)||this}fs.prototype.type="ellipse";var Ig=fs,Tg=Math.PI,Cg=2*Tg,Dg=Math.sin,Ag=Math.cos,kg=Math.acos,Lg=Math.atan2,Pg=Math.abs,Og=Math.sqrt,Rg=Math.max,Ng=Math.min,zg=1e-4;function Eg(t,e,n,i,o,r,a){var s=t-n,l=e-i,u=(a?r:-r)/Og(s*s+l*l),h=u*l,c=-u*s,p=t+h,d=e+c,a=n+h,l=i+c,u=(p+a)/2,s=(d+l)/2,t=a-p,e=l-d,n=t*t+e*e,i=o-r,r=p*l-a*d,p=(e<0?-1:1)*Og(Rg(0,i*i*n-r*r)),l=(r*e-t*p)/n,a=(-r*t-e*p)/n,d=(r*e+t*p)/n,e=(-r*t+e*p)/n,p=l-u,n=a-s,u=d-u,s=e-s;return u*u+s*s<p*p+n*n&&(l=d,a=e),{cx:l,cy:a,x01:-h,y01:-c,x11:l*(o/i-1),y11:a*(o/i-1)}}function Vg(t,e){var n,i,o,r,a,s,l,u,h,c,p,d,f,g,y,m,v,x,_,b,w,S,M,I=Rg(e.r,0),T=Rg(e.r0||0,0),C=0<I;(C||0<T)&&(C||(I=T,T=0),I<T&&(y=I,I=T,T=y),n=!!e.clockwise,r=(i=e.startAngle)===(o=e.endAngle)?0:(Va(_=[i,o],!n),Pg(_[0]-_[1])),a=e.cx,s=e.cy,m=e.cornerRadius||0,x=e.innerCornerRadius||0,zg<I?Cg-zg<r?(t.moveTo(a+I*Ag(i),s+I*Dg(i)),t.arc(a,s,I,i,o,!n),zg<T&&(t.moveTo(a+T*Ag(o),s+T*Dg(o)),t.arc(a,s,T,o,i,n))):(v=Pg(I-T)/2,l=Ng(v,m),b=u=Ng(v,x),w=l,h=I*Ag(i),c=I*Dg(i),p=T*Ag(o),d=T*Dg(o),y=C=g=f=void 0,(zg<l||zg<u)&&(f=I*Ag(o),g=I*Dg(o),C=T*Ag(i),y=T*Dg(i),r<Tg)&&((_=function(t,e,n,i,o,r,a,s){var l=n-t,n=i-e,i=a-o;if(!((s=(a=s-r)*l-i*n)*s<zg))return[t+(s=(i*(e-r)-a*(t-o))/s)*l,e+s*n]}(h,c,C,y,f,g,p,d))&&(e=h-_[0],m=c-_[1],v=f-_[0],x=g-_[1],x=1/Dg(kg((e*v+m*x)/(Og(e*e+m*m)*Og(v*v+x*x)))/2),_=Og(_[0]*_[0]+_[1]*_[1]),b=Ng(u,(T-_)/(x-1)),w=Ng(l,(I-_)/(1+x)))),zg<r?zg<w?(S=Eg(C,y,h,c,I,w,n),M=Eg(f,g,p,d,I,w,n),t.moveTo(a+S.cx+S.x01,s+S.cy+S.y01),w<l?t.arc(a+S.cx,s+S.cy,w,Lg(S.y01,S.x01),Lg(M.y01,M.x01),!n):(t.arc(a+S.cx,s+S.cy,w,Lg(S.y01,S.x01),Lg(S.y11,S.x11),!n),t.arc(a,s,I,Lg(S.cy+S.y11,S.cx+S.x11),Lg(M.cy+M.y11,M.cx+M.x11),!n),t.arc(a+M.cx,s+M.cy,w,Lg(M.y11,M.x11),Lg(M.y01,M.x01),!n))):(t.moveTo(a+h,s+c),t.arc(a,s,I,i,o,!n)):t.moveTo(a+h,s+c),zg<T&&zg<r?zg<b?(S=Eg(p,d,f,g,T,-b,n),M=Eg(h,c,C,y,T,-b,n),t.lineTo(a+S.cx+S.x01,s+S.cy+S.y01),b<u?t.arc(a+S.cx,s+S.cy,b,Lg(S.y01,S.x01),Lg(M.y01,M.x01),!n):(t.arc(a+S.cx,s+S.cy,b,Lg(S.y01,S.x01),Lg(S.y11,S.x11),!n),t.arc(a,s,T,Lg(S.cy+S.y11,S.cx+S.x11),Lg(M.cy+M.y11,M.cx+M.x11),n),t.arc(a+M.cx,s+M.cy,b,Lg(M.y11,M.x11),Lg(M.y01,M.x01),!n))):(t.lineTo(a+p,s+d),t.arc(a,s,T,o,i,n)):t.lineTo(a+p,s+d)):t.moveTo(a,s),t.closePath())}var Bg,Fg=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0,this.innerCornerRadius=0},ur=(wt(Gg,Bg=as),Gg.prototype.getDefaultShape=function(){return new Fg},Gg.prototype.buildPath=function(t,e){Vg(t,e)},Gg.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},Gg);function Gg(t){return Bg.call(this,t)||this}ur.prototype.type="sector";var Hg,Wg=ur,Ug=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},T=(wt(Yg,Hg=as),Yg.prototype.getDefaultShape=function(){return new Ug},Yg.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=2*Math.PI;t.moveTo(n+e.r,i),t.arc(n,i,e.r,0,o,!1),t.moveTo(n+e.r0,i),t.arc(n,i,e.r0,0,o,!0)},Yg);function Yg(t){return Hg.call(this,t)||this}T.prototype.type="ring";var Xg=T;function Zg(t,e,n,i,o,r,a){t=.5*(n-t),i=.5*(i-e);return(2*(e-n)+t+i)*a+(-3*(e-n)-2*t-i)*r+t*o+e}function jg(t,e,n){var i=e.smooth,o=e.points;if(o&&2<=o.length){if(i&&"spline"!==i){var r=function(t,e,n,i){var o,r,a=[],s=[],l=[],u=[];if(i){for(var h=[1/0,1/0],c=[-1/0,-1/0],p=0,d=t.length;p<d;p++)Et(h,h,t[p]),Vt(c,c,t[p]);Et(h,h,i[0]),Vt(c,c,i[1])}for(p=0,d=t.length;p<d;p++){var f=t[p];if(n)o=t[p?p-1:d-1],r=t[(p+1)%d];else{if(0===p||p===d-1){a.push(It(t[p]));continue}o=t[p-1],r=t[p+1]}Dt(s,r,o),kt(s,s,e);var g=Pt(f,o),y=Pt(f,r),m=g+y;0!==m&&(g/=m,y/=m),kt(l,s,-g),kt(u,s,y);y=Tt([],f,l),f=Tt([],f,u);i&&(Vt(y,y,h),Et(y,y,c),Vt(f,f,h),Et(f,f,c)),a.push(y),a.push(f)}return n&&a.push(a.shift()),a}(o,i,n,e.smoothConstraint);t.moveTo(o[0][0],o[0][1]);for(var a=o.length,s=0;s<(n?a:a-1);s++){var l=r[2*s],u=r[2*s+1],h=o[(s+1)%a];t.bezierCurveTo(l[0],l[1],u[0],u[1],h[0],h[1])}}else{"spline"===i&&(o=function(t,e){for(var n=t.length,i=[],o=0,r=1;r<n;r++)o+=Pt(t[r-1],t[r]);for(var a=(a=o/2)<n?n:a,r=0;r<a;r++){var s=r/(a-1)*(e?n:n-1),l=Math.floor(s),u=s-l,h=void 0,c=t[l%n],p=void 0,d=void 0,d=e?(h=t[(l-1+n)%n],p=t[(l+1)%n],t[(l+2)%n]):(h=t[0===l?l:l-1],p=t[n-2<l?n-1:l+1],t[n-3<l?n-1:l+2]),s=u*u,l=u*s;i.push([Zg(h[0],c[0],p[0],d[0],u,s,l),Zg(h[1],c[1],p[1],d[1],u,s,l)])}return i}(o,n)),t.moveTo(o[0][0],o[0][1]);for(var s=1,c=o.length;s<c;s++)t.lineTo(o[s][0],o[s][1])}n&&t.closePath()}}var qg,Kg=function(){this.points=null,this.smooth=0,this.smoothConstraint=null},Jn=(wt(Jg,qg=as),Jg.prototype.getDefaultShape=function(){return new Kg},Jg.prototype.buildPath=function(t,e){jg(t,e,!0)},Jg);function Jg(t){return qg.call(this,t)||this}Jn.prototype.type="polygon";var Qg,$g=Jn,ty=function(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null},fs=(wt(ey,Qg=as),ey.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},ey.prototype.getDefaultShape=function(){return new ty},ey.prototype.buildPath=function(t,e){jg(t,e,!1)},ey);function ey(t){return Qg.call(this,t)||this}fs.prototype.type="polyline";var ny=fs,iy=[],oy=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1};function ry(t,e,n){var i=t.cpx2,o=t.cpy2;return null===i||null===o?[(n?Qr:Jr)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?Qr:Jr)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?oa:ia)(t.x1,t.cpx1,t.x2,e),(n?oa:ia)(t.y1,t.cpy1,t.y2,e)]}var ay,ur=(wt(sy,ay=as),sy.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},sy.prototype.getDefaultShape=function(){return new oy},sy.prototype.buildPath=function(t,e){var n=e.x1,i=e.y1,o=e.x2,r=e.y2,a=e.cpx1,s=e.cpy1,l=e.cpx2,u=e.cpy2,e=e.percent;0!==e&&(t.moveTo(n,i),null==l||null==u?(e<1&&(aa(n,a,o,e,iy),a=iy[1],o=iy[2],aa(i,s,r,e,iy),s=iy[1],r=iy[2]),t.quadraticCurveTo(a,s,o,r)):(e<1&&(ea(n,a,l,o,e,iy),a=iy[1],l=iy[2],o=iy[3],ea(i,s,u,r,e,iy),s=iy[1],u=iy[2],r=iy[3]),t.bezierCurveTo(a,s,l,u,o,r)))},sy.prototype.pointAt=function(t){return ry(this.shape,t,!1)},sy.prototype.tangentAt=function(t){t=ry(this.shape,t,!0);return Lt(t,t)},sy);function sy(t){return ay.call(this,t)||this}ur.prototype.type="bezier-curve";var ly,uy,hy,cy,py=ur,dy=(wt(Ly,cy=as),Ly.prototype._updatePathDirty=function(){for(var t=this.shape.paths,e=this.shapeChanged(),n=0;n<t.length;n++)e=e||t[n].shapeChanged();e&&this.dirtyShape()},Ly.prototype.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)},Ly.prototype.buildPath=function(t,e){for(var n=e.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},Ly.prototype.afterBrush=function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].pathUpdated()},Ly.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),as.prototype.getBoundingRect.call(this)},Ly),T=(ky.prototype.addColorStop=function(t,e){this.colorStops.push({offset:t,color:e})},ky),fy=(wt(Ay,hy=T),Ay),gy=(wt(Dy,uy=T),Dy),yy=[0,0],my=[0,0],vy=new bi,xy=new bi,_y=(Cy.prototype.fromBoundingRect=function(t,e){var n=this._corners,i=this._axes,o=t.x,r=t.y,a=o+t.width,t=r+t.height;if(n[0].set(o,r),n[1].set(a,r),n[2].set(a,t),n[3].set(o,t),e)for(var s=0;s<4;s++)n[s].transform(e);for(bi.sub(i[0],n[1],n[0]),bi.sub(i[1],n[3],n[0]),i[0].normalize(),i[1].normalize(),s=0;s<2;s++)this._origin[s]=i[s].dot(n[0])},Cy.prototype.intersect=function(t,e){var n=!0,i=!e;return vy.set(1/0,1/0),xy.set(0,0),!this._intersectCheckOneSide(this,t,vy,xy,i,1)&&(n=!1,i)||!this._intersectCheckOneSide(t,this,vy,xy,i,-1)&&(n=!1,i)||i||bi.copy(e,n?vy:xy),n},Cy.prototype._intersectCheckOneSide=function(t,e,n,i,o,r){for(var a=!0,s=0;s<2;s++){var l=this._axes[s];if(this._getProjMinMaxOnAxis(s,t._corners,yy),this._getProjMinMaxOnAxis(s,e._corners,my),yy[1]<my[0]||my[1]<yy[0]){if(a=!1,o)return a;var u=Math.abs(my[0]-yy[1]),h=Math.abs(yy[0]-my[1]);Math.min(u,h)>i.len()&&(u<h?bi.scale(i,l,-u*r):bi.scale(i,l,h*r))}else n&&(u=Math.abs(my[0]-yy[1]),h=Math.abs(yy[0]-my[1]),Math.min(u,h)<n.len()&&(u<h?bi.scale(n,l,u*r):bi.scale(n,l,-h*r)))}return a},Cy.prototype._getProjMinMaxOnAxis=function(t,e,n){for(var i=this._axes[t],o=this._origin,r=e[0].dot(i)+o[t],a=r,s=r,l=1;l<e.length;l++)var u=e[l].dot(i)+o[t],a=Math.min(u,a),s=Math.max(u,s);n[0]=a,n[1]=s},Cy),by=[],wy=(wt(Ty,ly=Fr),Ty.prototype.traverse=function(t,e){t.call(e,this)},Ty.prototype.useStyle=function(){this.style={}},Ty.prototype.getCursor=function(){return this._cursor},Ty.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},Ty.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},Ty.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},Ty.prototype.addDisplayable=function(t,e){(e?this._temporaryDisplayables:this._displayables).push(t),this.markRedraw()},Ty.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},Ty.prototype.getDisplayables=function(){return this._displayables},Ty.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},Ty.prototype.eachPendingDisplayable=function(t){for(var e=this._cursor;e<this._displayables.length;e++)t&&t(this._displayables[e]);for(e=0;e<this._temporaryDisplayables.length;e++)t&&t(this._temporaryDisplayables[e])},Ty.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){var e=this._displayables[t];e.parent=this,e.update(),e.parent=null}for(t=0;t<this._temporaryDisplayables.length;t++)(e=this._temporaryDisplayables[t]).parent=this,e.update(),e.parent=null},Ty.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new ki(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(by)),t.union(i)}this._rect=t}return this._rect},Ty.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},Ty),Sy=Math.max,My=Math.min,Iy={};function Ty(){var t=null!==ly&&ly.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}function Cy(t,e){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new bi;for(n=0;n<2;n++)this._axes[n]=new bi;t&&this.fromBoundingRect(t,e)}function Dy(t,e,n,i,o){i=uy.call(this,i)||this;return i.x=null==t?.5:t,i.y=null==e?.5:e,i.r=null==n?.5:n,i.type="radial",i.global=o||!1,i}function Ay(t,e,n,i,o,r){o=hy.call(this,o)||this;return o.x=null==t?0:t,o.y=null==e?0:e,o.x2=null==n?1:n,o.y2=null==i?0:i,o.type="linear",o.global=r||!1,o}function ky(t){this.colorStops=t||[]}function Ly(){var t=null!==cy&&cy.apply(this,arguments)||this;return t.type="compound",t}function Py(t){return as.extend(t)}var Oy=function(t,e){var n,i=xg(t,e);function o(t){t=n.call(this,t)||this;return t.applyTransform=i.applyTransform,t.buildPath=i.buildPath,t}return wt(o,n=yg),o};function Ry(t,e){return Oy(t,e)}function Ny(t,e){Iy[t]=e}function zy(t){if(Iy.hasOwnProperty(t))return Iy[t]}function Ey(t,e,n,i){e=_g(t,e);return n&&("center"===i&&(n=By(n,e.getBoundingRect())),Gy(e,n)),e}function Vy(t,e,n){var i=new ys({style:{image:t,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(t){"center"===n&&(t={width:t.width,height:t.height},i.setStyle(By(e,t)))}});return i}function By(t,e){var n=e.width/e.height,e=t.height*n,n=e<=t.width?t.height:(e=t.width)/n;return{x:t.x+t.width/2-e/2,y:t.y+t.height/2-n/2,width:e,height:n}}var Fy=function(t,e){for(var n=[],i=t.length,o=0;o<i;o++){var r=t[o];n.push(r.getUpdatedPathProxy(!0))}return(e=new as(e)).createPathProxy(),e.buildPath=function(t){var e;vg(t)&&(t.appendPath(n),(e=t.getContext())&&t.rebuildPath(e,1))},e};function Gy(t,e){t.applyTransform&&(e=t.getBoundingRect().calculateTransform(e),t.applyTransform(e))}function Hy(t){return vs(t.shape,t.shape,t.style),t}function Wy(t){return xs(t.shape,t.shape,t.style),t}var Uy=_s;function Yy(t,e){for(var n=ii([]);t&&t!==e;)ri(n,t.getLocalTransform(),n),t=t.parent;return n}function Xy(t,e,n){return e&&!F(e)&&(e=_i.getLocalTransform(e)),zt([],t,e=n?ui([],e):e)}function Zy(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),o=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),o=Xy(o=["left"===t?-i:"right"===t?i:0,"top"===t?-o:"bottom"===t?o:0],e,n);return Math.abs(o[0])>Math.abs(o[1])?0<o[0]?"right":"left":0<o[1]?"bottom":"top"}function jy(t){return!t.isGroup}function qy(t,e,i){var o,n;function r(t){var e={x:t.x,y:t.y,rotation:t.rotation};return null!=t.shape&&(e.shape=N({},t.shape)),e}t&&e&&(n={},t.traverse(function(t){jy(t)&&t.anid&&(n[t.anid]=t)}),o=n,e.traverse(function(t){var e,n;jy(t)&&t.anid&&((e=o[t.anid])&&(n=r(t),t.attr(r(e)),Wl(t,n,i,Gs(t).dataIndex)))}))}function Ky(t,n){return H(t,function(t){var e=t[0],e=Sy(e,n.x);e=My(e,n.x+n.width);t=t[1],t=Sy(t,n.y);return[e,My(t,n.y+n.height)]})}function Jy(t,e){var n=Sy(t.x,e.x),i=My(t.x+t.width,e.x+e.width),o=Sy(t.y,e.y),e=My(t.y+t.height,e.y+e.height);if(n<=i&&o<=e)return{x:n,y:o,width:i-n,height:e-o}}function Qy(t,e,n){var i=N({rectHover:!0},e),e=i.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(e.image=t.slice(8),z(e,n),new ys(i)):Ey(t.replace("path://",""),i,n,"center")}function $y(t,e,n,i,o){for(var r=0,a=o[o.length-1];r<o.length;r++){var s=o[r];if(tm(t,e,n,i,s[0],s[1],a[0],a[1]))return!0;a=s}}function tm(t,e,n,i,o,r,a,s){var l=n-t,u=i-e,n=a-o,i=s-r,a=n*u-l*i;if((s=a)<=1e-6&&-1e-6<=s)return!1;o=t-o,r=e-r,l=(o*u-l*r)/a;if(l<0||1<l)return!1;a=(o*i-n*r)/a;return!(a<0||1<a)}function em(t){var e=t.itemTooltipOption,n=t.componentModel,i=t.itemName,o=K(e)?{formatter:e}:e,e=n.mainType,n=n.componentIndex,r={componentType:e,name:i,$vars:["name"]};r[e+"Index"]=n;var a=t.formatterParamsExtra;a&&G(Y(a),function(t){xt(r,t)||(r[t]=a[t],r.$vars.push(t))});t=Gs(t.el);t.componentMainType=e,t.componentIndex=n,t.tooltipConfig={name:i,option:z({content:i,formatterParams:r},o)}}Ny("circle",$f),Ny("ellipse",Ig),Ny("sector",Wg),Ny("ring",Xg),Ny("polygon",$g),Ny("polyline",ny),Ny("rect",Ts),Ny("line",Kf),Ny("bezierCurve",py),Ny("arc",gf);var Jn=as.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,o=e.width/2,e=e.height/2;t.moveTo(n,i-e),t.lineTo(n+o,i+e),t.lineTo(n-o,i+e),t.closePath()}}),fs=as.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,o=e.width/2,e=e.height/2;t.moveTo(n,i-e),t.lineTo(n+o,i),t.lineTo(n,i+e),t.lineTo(n-o,i),t.closePath()}}),ur=as.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,o=e.width/5*3,r=Math.max(o,e.height),a=o/2,s=a*a/(r-a),l=i-r+a+s,u=Math.asin(s/a),h=Math.cos(u)*a,c=Math.sin(u),e=Math.cos(u),o=.6*a,r=.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*o,l+s+e*o,n,i-r,n,i),t.bezierCurveTo(n,i-r,n-h+c*o,l+s+e*o,n-h,l+s),t.closePath()}}),T=as.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,o=e.x,e=e.y,i=i/3*2;t.moveTo(o,e),t.lineTo(o+i,e+n),t.lineTo(o,e+n/4*3),t.lineTo(o-i,e+n),t.lineTo(o,e),t.closePath()}}),nm={line:function(t,e,n,i,o){o.x1=t,o.y1=e+i/2,o.x2=t+n,o.y2=e+i/2},rect:function(t,e,n,i,o){o.x=t,o.y=e,o.width=n,o.height=i},roundRect:function(t,e,n,i,o){o.x=t,o.y=e,o.width=n,o.height=i,o.r=Math.min(n,i)/4},square:function(t,e,n,i,o){i=Math.min(n,i);o.x=t,o.y=e,o.width=i,o.height=i},circle:function(t,e,n,i,o){o.cx=t+n/2,o.cy=e+i/2,o.r=Math.min(n,i)/2},diamond:function(t,e,n,i,o){o.cx=t+n/2,o.cy=e+i/2,o.width=n,o.height=i},pin:function(t,e,n,i,o){o.x=t+n/2,o.y=e+i/2,o.width=n,o.height=i},arrow:function(t,e,n,i,o){o.x=t+n/2,o.y=e+i/2,o.width=n,o.height=i},triangle:function(t,e,n,i,o){o.cx=t+n/2,o.cy=e+i/2,o.width=n,o.height=i}},im={};G({line:Kf,rect:Ts,roundRect:Ts,square:Ts,circle:$f,diamond:fs,pin:ur,arrow:T,triangle:Jn},function(t,e){im[e]=new t});var om=as.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,e,n){var i=Ui(t,e,n),t=this.shape;return t&&"pin"===t.symbolType&&"inside"===e.position&&(i.y=n.y+.4*n.height),i},buildPath:function(t,e,n){var i,o=e.symbolType;"none"!==o&&((i=im[o])||(i=im[o="rect"]),nm[o](e.x,e.y,e.width,e.height,i.shape),i.buildPath(t,i.shape,n))}});function rm(t,e){var n;"image"!==this.type&&(n=this.style,this.__isEmptyBrush?(n.stroke=t,n.fill=e||"#fff",n.lineWidth=2):"line"===this.shape.symbolType?n.stroke=t:n.fill=t,this.markRedraw())}function am(t,e,n,i,o,r,a){var s=0===t.indexOf("empty");return(o=0===(t=s?t.substr(5,1).toLowerCase()+t.substr(6):t).indexOf("image://")?Vy(t.slice(8),new ki(e,n,i,o),a?"center":"cover"):0===t.indexOf("path://")?Ey(t.slice(7),{},new ki(e,n,i,o),a?"center":"cover"):new om({shape:{symbolType:t,x:e,y:n,width:i,height:o}})).__isEmptyBrush=s,o.setColor=rm,r&&o.setColor(r),o}function sm(t){return[(t=!j(t)?[+t,+t]:t)[0]||0,t[1]||0]}function lm(t,e){if(null!=t)return[go((t=!j(t)?[t,t]:t)[0],e[0])||0,go(rt(t[1],t[0]),e[1])||0]}function um(t,e,n){for(var i,o,r,a,s,l,u,h,c,p="radial"===e.type?(i=t,o=e,a=(r=n).width,s=r.height,l=Math.min(a,s),u=null==o.x?.5:o.x,h=null==o.y?.5:o.y,c=null==o.r?.5:o.r,o.global||(u=u*a+r.x,h=h*s+r.y,c*=l),i.createRadialGradient(u,h,0,u,h,c)):(l=t,i=n,h=null==(u=e).x?0:u.x,c=null==u.x2?1:u.x2,t=null==u.y?0:u.y,n=null==u.y2?0:u.y2,u.global||(h=h*i.width+i.x,c=c*i.width+i.x,t=t*i.height+i.y,n=n*i.height+i.y),h=isNaN(h)?0:h,c=isNaN(c)?1:c,t=isNaN(t)?0:t,n=isNaN(n)?0:n,l.createLinearGradient(h,t,c,n)),d=e.colorStops,f=0;f<d.length;f++)p.addColorStop(d[f].offset,d[f].color);return p}function hm(t,e){if(t!==e&&(t||e)){if(!t||!e||t.length!==e.length)return 1;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return 1}}function cm(t,e){return t&&"solid"!==t&&0<e?(e=e||1,"dashed"===t?[4*e,2*e]:"dotted"===t?[e]:Q(t)?[t]:j(t)?t:null):null}var pm=new Ba(!0);function dm(t){var e=t.stroke;return!(null==e||"none"===e||!(0<t.lineWidth))}function fm(t){return"string"==typeof t&&"none"!==t}function gm(t){t=t.fill;return null!=t&&"none"!==t}function ym(t,e){var n;null!=e.fillOpacity&&1!==e.fillOpacity?(n=t.globalAlpha,t.globalAlpha=e.fillOpacity*e.opacity,t.fill(),t.globalAlpha=n):t.fill()}function mm(t,e){var n;null!=e.strokeOpacity&&1!==e.strokeOpacity?(n=t.globalAlpha,t.globalAlpha=e.strokeOpacity*e.opacity,t.stroke(),t.globalAlpha=n):t.stroke()}function vm(t,e,n){n=vr(e.image,e.__image,n);if(_r(n)){t=t.createPattern(n,e.repeat||"repeat");return"function"==typeof DOMMatrix&&t.setTransform&&((n=new DOMMatrix).rotateSelf(0,0,(e.rotation||0)/Math.PI*180),n.scaleSelf(e.scaleX||1,e.scaleY||1),n.translateSelf(e.x||0,e.y||0),t.setTransform(n)),t}}var xm=["shadowBlur","shadowOffsetX","shadowOffsetY"],_m=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function bm(t,e,n,i,o){var r,a=!1;if(!i&&e===(n=n||{}))return!1;!i&&e.opacity===n.opacity||(a||(Dm(t,o),a=!0),r=Math.max(Math.min(e.opacity,1),0),t.globalAlpha=isNaN(r)?Pr.opacity:r),!i&&e.blend===n.blend||(a||(Dm(t,o),a=!0),t.globalCompositeOperation=e.blend||Pr.blend);for(var s=0;s<xm.length;s++){var l=xm[s];!i&&e[l]===n[l]||(a||(Dm(t,o),a=!0),t[l]=t.dpr*(e[l]||0))}return!i&&e.shadowColor===n.shadowColor||(a||(Dm(t,o),a=!0),t.shadowColor=e.shadowColor||Pr.shadowColor),a}function wm(t,e,n,i,o){var r=Am(e,o.inHover),a=i?null:n&&Am(n,o.inHover)||{};if(r!==a){var s=bm(t,r,a,i,o);!i&&r.fill===a.fill||(s||(Dm(t,o),s=!0),fm(r.fill)&&(t.fillStyle=r.fill)),!i&&r.stroke===a.stroke||(s||(Dm(t,o),s=!0),fm(r.stroke)&&(t.strokeStyle=r.stroke)),!i&&r.opacity===a.opacity||(s||(Dm(t,o),s=!0),t.globalAlpha=null==r.opacity?1:r.opacity),e.hasStroke()&&(e=r.lineWidth/(r.strokeNoScale&&e&&e.getLineScale?e.getLineScale():1),t.lineWidth!==e&&(s||(Dm(t,o),s=!0),t.lineWidth=e));for(var l=0;l<_m.length;l++){var u=_m[l],h=u[0];!i&&r[h]===a[h]||(s||(Dm(t,o),s=!0),t[h]=r[h]||u[1])}return s}}function Sm(t,e){var n=e.transform,e=t.dpr||1;n?t.setTransform(e*n[0],e*n[1],e*n[2],e*n[3],e*n[4],e*n[5]):t.setTransform(e,0,0,e,0,0)}var Mm=1,Im=2,Tm=3,Cm=4;function Dm(t,e){e.batchFill&&t.fill(),e.batchStroke&&t.stroke(),e.batchFill="",e.batchStroke=""}function Am(t,e){return e&&t.__hoverStyle||t.style}function km(t,e){Lm(t,e,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function Lm(t,e,n,i){var o=e.transform;if(!e.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1))return e.__dirty&=~ke,e.__isRendered=!1;var r,a,s,l,u,h,c,p,d,f,g,y,m,v=e.__clipPaths,x=n.prevElClipPaths,_=!1,b=!1;x&&!hm(v,x)||(x&&x.length&&(Dm(t,n),t.restore(),b=_=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),v&&v.length&&(Dm(t,n),t.save(),function(t,e,n){for(var i=!1,o=0;o<t.length;o++){var r=t[o],i=i||r.isZeroArea();Sm(e,r),e.beginPath(),r.buildPath(e,r.shape),e.clip()}n.allClipped=i}(v,t,n),_=!0),n.prevElClipPaths=v),n.allClipped?e.__isRendered=!1:(e.beforeBrush&&e.beforeBrush(),e.innerBeforeBrush(),(s=n.prevEl)||(b=_=!0),m=e instanceof as&&e.autoBatch&&(m=e.style,x=gm(m),v=dm(m),!(m.lineDash||!(+x^+v)||x&&"string"!=typeof m.fill||v&&"string"!=typeof m.stroke||m.strokePercent<1||m.strokeOpacity<1||m.fillOpacity<1)),_||(g=o,y=s.transform,g&&y?g[0]!==y[0]||g[1]!==y[1]||g[2]!==y[2]||g[3]!==y[3]||g[4]!==y[4]||g[5]!==y[5]:g||y)?(Dm(t,n),Sm(t,e)):m||Dm(t,n),g=Am(e,n.inHover),e instanceof as?(n.lastDrawType!==Mm&&(b=!0,n.lastDrawType=Mm),wm(t,e,s,b,n),m&&(n.batchFill||n.batchStroke)||t.beginPath(),function(t,e,n,i){var o=dm(n),r=gm(n),a=n.strokePercent,s=a<1,l=!e.path;e.silent&&!s||!l||e.createPathProxy();var u,h,c,p,d,f,g,y=e.path||pm;i||(u=n.fill,h=n.stroke,c=r&&!!u.colorStops,v=o&&!!h.colorStops,p=r&&!!u.image,_=o&&!!h.image,g=b=f=x=d=void 0,(c||v)&&(g=e.getBoundingRect()),c&&(d=e.__dirty?um(t,u,g):e.__canvasFillGradient,e.__canvasFillGradient=d),v&&(x=e.__dirty?um(t,h,g):e.__canvasStrokeGradient,e.__canvasStrokeGradient=x),p&&(f=e.__dirty||!e.__canvasFillPattern?vm(t,u,e):e.__canvasFillPattern,e.__canvasFillPattern=f),_&&(b=e.__dirty||!e.__canvasStrokePattern?vm(t,h,e):e.__canvasStrokePattern,e.__canvasStrokePattern=f),c?t.fillStyle=d:p&&(f?t.fillStyle=f:r=!1),v?t.strokeStyle=x:_&&(b?t.strokeStyle=b:o=!1));var m,v=n.lineDash&&0<n.lineWidth&&cm(n.lineDash,n.lineWidth),x=n.lineDashOffset,_=!!t.setLineDash,b=e.getGlobalScale();y.setScale(b[0],b[1],e.segmentIgnoreThreshold),v&&(m=n.strokeNoScale&&e.getLineScale?e.getLineScale():1)&&1!==m&&(v=H(v,function(t){return t/m}),x/=m),b=!0,(l||e.__dirty&Le||v&&!_&&o)&&(y.setDPR(t.dpr),s?y.setContext(null):(y.setContext(t),b=!1),y.reset(),v&&!_&&(y.setLineDash(v),y.setLineDashOffset(x)),e.buildPath(y,e.shape,i),y.toStatic(),e.pathUpdated()),b&&y.rebuildPath(t,s?a:1),v&&_&&(t.setLineDash(v),t.lineDashOffset=x),i||(n.strokeFirst?(o&&mm(t,n),r&&ym(t,n)):(r&&ym(t,n),o&&mm(t,n))),v&&_&&t.setLineDash([])}(t,e,g,m),m&&(n.batchFill=g.fill||"",n.batchStroke=g.stroke||"")):e instanceof hs?(n.lastDrawType!==Tm&&(b=!0,n.lastDrawType=Tm),wm(t,e,s,b,n),l=t,y=e,null!=(f=(u=g).text)&&(f+=""),f&&(l.font=u.font||Pi,l.textAlign=u.textAlign,l.textBaseline=u.textBaseline,h=void 0,l.setLineDash&&(c=u.lineDash&&0<u.lineWidth&&cm(u.lineDash,u.lineWidth),p=u.lineDashOffset,c&&((d=u.strokeNoScale&&y.getLineScale?y.getLineScale():1)&&1!==d&&(c=H(c,function(t){return t/d}),p/=d),l.setLineDash(c),l.lineDashOffset=p,h=!0)),u.strokeFirst?(dm(u)&&l.strokeText(f,u.x,u.y),gm(u)&&l.fillText(f,u.x,u.y)):(gm(u)&&l.fillText(f,u.x,u.y),dm(u)&&l.strokeText(f,u.x,u.y)),h&&l.setLineDash([]))):e instanceof ys?(n.lastDrawType!==Im&&(b=!0,n.lastDrawType=Im),c=s,p=b,bm(t,Am(e,(f=n).inHover),c&&Am(c,f.inHover),p,f),u=t,h=g,(s=(l=e).__image=vr(h.image,l.__image,l,l.onload))&&_r(s)&&(c=h.x||0,p=h.y||0,f=l.getWidth(),g=l.getHeight(),l=s.width/s.height,null==f&&null!=g?f=g*l:null==g&&null!=f?g=f/l:null==f&&null==g&&(f=s.width,g=s.height),h.sWidth&&h.sHeight?(r=h.sx||0,a=h.sy||0,u.drawImage(s,r,a,h.sWidth,h.sHeight,c,p,f,g)):h.sx&&h.sy?(r=h.sx,a=h.sy,u.drawImage(s,r,a,f-r,g-a,c,p,f,g)):u.drawImage(s,c,p,f,g))):e instanceof wy&&(n.lastDrawType!==Cm&&(b=!0,n.lastDrawType=Cm),function(t,e,n){var i=e.getDisplayables(),o=e.getTemporalDisplayables();t.save();var r,a,s={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover};for(r=e.getCursor(),a=i.length;r<a;r++){var l=i[r];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Lm(t,l,s,r===a-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),s.prevEl=l}for(var u=0,h=o.length;u<h;u++)(l=o[u]).beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),Lm(t,l,s,u===h-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),s.prevEl=l;e.clearTemporalDisplayables(),e.notClear=!0,t.restore()}(t,e,n)),m&&i&&Dm(t,n),e.innerAfterBrush(),e.afterBrush&&e.afterBrush(),(n.prevEl=e).__dirty=0,e.__isRendered=!0)}var Pm,Om=new mu,Rm=new He(100),Nm=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function zm(t,e){if("none"===t)return null;var I=e.getDevicePixelRatio(),T=e.getZr(),C="svg"===T.painter.type;t.dirty&&Om.delete(t);e=Om.get(t);if(e)return e;var D=z(t,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});"none"===D.backgroundColor&&(D.backgroundColor=null);e={repeat:"repeat"};return function(t){for(var e,n=[I],i=!0,o=0;o<Nm.length;++o){var r=D[Nm[o]],a=typeof r;if(null!=r&&!j(r)&&"string"!=a&&"number"!=a&&"boolean"!=a){i=!1;break}n.push(r)}{var s;i&&(e=n.join(",")+(C?"-svg":""),(s=Rm.get(e))&&(C?t.svgElement=s:t.image=s))}var m,v=function t(e){if(!e||0===e.length)return[[0,0]];if("number"==typeof e){var n=Math.ceil(e);return[[n,n]]}for(var i=!0,o=0;o<e.length;++o)if("number"!=typeof e[o]){i=!1;break}if(i)return t([e]);var r=[];for(o=0;o<e.length;++o)"number"==typeof e[o]?(n=Math.ceil(e[o]),r.push([n,n])):(n=H(e[o],function(t){return Math.ceil(t)})).length%2==1?r.push(n.concat(n)):r.push(n);return r}(D.dashArrayX),x=function(t){if(!t||"object"==typeof t&&0===t.length)return[0,0];if("number"==typeof t){var e=Math.ceil(t);return[e,e]}e=H(t,function(t){return Math.ceil(t)});return t.length%2?e.concat(e):e}(D.dashArrayY),_=function t(e){if(!e||0===e.length)return[["rect"]];if("string"==typeof e)return[[e]];for(var n=!0,i=0;i<e.length;++i)if("string"!=typeof e[i]){n=!1;break}if(n)return t([e]);var o=[];for(i=0;i<e.length;++i)"string"==typeof e[i]?o.push([e[i]]):o.push(e[i]);return o}(D.symbol),l=function(t){return H(t,Em)}(v),b=Em(x),w=!C&&E(),S=C&&T.painter.createSVGElement("g"),M=function(){for(var t=1,e=0,n=l.length;e<n;++e)t=Po(t,l[e]);var i=1;for(e=0,n=_.length;e<n;++e)i=Po(i,_[e].length);t*=i;var o=b*l.length*_.length;return{width:Math.max(1,Math.min(t,D.maxTileWidth)),height:Math.max(1,Math.min(o,D.maxTileHeight))}}();w&&(w.width=M.width*I,w.height=M.height*I,m=w.getContext("2d")),function(){m&&(m.clearRect(0,0,w.width,w.height),D.backgroundColor&&(m.fillStyle=D.backgroundColor,m.fillRect(0,0,w.width,w.height)));for(var t=0,e=0;e<x.length;++e)t+=x[e];if(!(t<=0))for(var n=-b,i=0,o=0,r=0;n<M.height;){if(i%2==0){for(var a=o/2%_.length,s=0,l=0,u=0;s<2*M.width;){for(var h,c,p,d,f,g,y=0,e=0;e<v[r].length;++e)y+=v[r][e];if(y<=0)break;l%2==0&&(h=.5*(1-D.symbolSize),c=s+v[r][l]*h,p=n+x[i]*h,d=v[r][l]*D.symbolSize,f=x[i]*D.symbolSize,g=u/2%_[a].length,h=_[a][g],g=void 0,g=am(h,c*(g=C?1:I),p*g,d*g,f*g,D.color,D.symbolKeepAspect),C?S.appendChild(T.painter.paintOne(g)):km(m,g)),s+=v[r][l],++u,++l===v[r].length&&(l=0)}++r===v.length&&(r=0)}n+=x[i],++o,++i===x.length&&(i=0)}}(),i&&Rm.put(e,w||S),t.image=w,t.svgElement=S,t.svgWidth=M.width,t.svgHeight=M.height}(e),e.rotation=D.rotation,e.scaleX=e.scaleY=C?1:1/I,Om.set(t,e),t.dirty=!1,e}function Em(t){for(var e=0,n=0;n<t.length;++n)e+=t[n];return t.length%2==1?2*e:e}function Vm(t){var e=t=K(t)?(new DOMParser).parseFromString(t,"text/xml"):t;for(9===e.nodeType&&(e=e.firstChild);"svg"!==e.nodeName.toLowerCase()||1!==e.nodeType;)e=e.nextSibling;return e}var Bm={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-anchor":"textAlign",visibility:"visibility",display:"display"},Fm=Y(Bm),Gm={"alignment-baseline":"textBaseline","stop-color":"stopColor"},Hm=Y(Gm),Wm=(Ym.prototype.parse=function(t,e){e=e||{};var n=Vm(t);if(!n)throw new Error("Illegal svg");this._defsUsePending=[];var i=new ro;this._root=i;var o=[],r=n.getAttribute("viewBox")||"",a=parseFloat(n.getAttribute("width")||e.width),t=parseFloat(n.getAttribute("height")||e.height);isNaN(a)&&(a=null),isNaN(t)&&(t=null),Km(n,i,null,!0,!1);for(var s,l,u,h=n.firstChild;h;)this._parseNode(h,i,o,null,!1,!1),h=h.nextSibling;return function(t,e){for(var n=0;n<e.length;n++){var i=e[n];i[0].style[i[1]]=t[i[2]]}}(this._defs,this._defsUsePending),this._defsUsePending=[],(s=r&&4<=(u=t0(r)).length?{x:parseFloat(u[0]||0),y:parseFloat(u[1]||0),width:parseFloat(u[2]),height:parseFloat(u[3])}:s)&&null!=a&&null!=t&&(l=r0(s,{x:0,y:0,width:a,height:t}),!e.ignoreViewBox)&&(u=i,(i=new ro).add(u),u.scaleX=u.scaleY=l.scale,u.x=l.x,u.y=l.y),e.ignoreRootClip||null==a||null==t||i.setClipPath(new Ts({shape:{x:0,y:0,width:a,height:t}})),{root:i,width:a,height:t,viewBoxRect:s,viewBoxTransform:l,named:o}},Ym.prototype._parseNode=function(t,e,n,i,o,r){var a,s,l=t.nodeName.toLowerCase(),u=i;if("defs"===l&&(o=!0),"text"===l&&(r=!0),"defs"===l||"switch"===l?a=e:(o||(s=Pm[l])&&xt(Pm,l)&&(a=s.call(this,t,e),(s=t.getAttribute("name"))?(n.push(s={name:s,namedFrom:null,svgNodeTagLower:l,el:a}),"g"===l&&(u=s)):i&&n.push({name:i.name,namedFrom:i,svgNodeTagLower:l,el:a}),e.add(a)),(e=Um[l])&&xt(Um,l)&&(l=e.call(this,t),(e=t.getAttribute("id"))&&(this._defs[e]=l))),a&&a.isGroup)for(var h=t.firstChild;h;)1===h.nodeType?this._parseNode(h,a,n,u,o,r):3===h.nodeType&&r&&this._parseText(h,a),h=h.nextSibling},Ym.prototype._parseText=function(t,e){var n=new hs({style:{text:t.textContent},silent:!0,x:this._textX||0,y:this._textY||0});jm(e,n),Km(t,n,this._defsUsePending,!1,!1),function(t,e){var n=e.__selfStyle;n&&(n=n.textBaseline,!(i=n)||"auto"===n||"baseline"===n?i="alphabetic":"before-edge"===n||"text-before-edge"===n?i="top":"after-edge"===n||"text-after-edge"===n?i="bottom":"central"!==n&&"mathematical"!==n||(i="middle"),t.style.textBaseline=i);var i=e.__inheritedStyle;i&&(e=i.textAlign,(i=e)&&("middle"===e&&(i="center"),t.style.textAlign=i))}(n,e);var i=n.style,t=i.fontSize;t&&t<9&&(i.fontSize=9,n.scaleX*=t/9,n.scaleY*=t/9);t=(i.fontSize||i.fontFamily)&&[i.fontStyle,i.fontWeight,(i.fontSize||12)+"px",i.fontFamily||"sans-serif"].join(" ");i.font=t;t=n.getBoundingRect();return this._textX+=t.width,e.add(n),n},Ym.internalField=void(Pm={g:function(t,e){var n=new ro;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),n},rect:function(t,e){var n=new Ts;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),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.silent=!0,n},circle:function(t,e){var n=new $f;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),r:parseFloat(t.getAttribute("r")||"0")}),n.silent=!0,n},line:function(t,e){var n=new Kf;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),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.silent=!0,n},ellipse:function(t,e){var n=new Ig;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),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.silent=!0,n},polygon:function(t,e){var n=t.getAttribute("points");n&&(i=qm(n));var i=new $g({shape:{points:i||[]},silent:!0});return jm(e,i),Km(t,i,this._defsUsePending,!1,!1),i},polyline:function(t,e){var n=t.getAttribute("points");n&&(i=qm(n));var i=new ny({shape:{points:i||[]},silent:!0});return jm(e,i),Km(t,i,this._defsUsePending,!1,!1),i},image:function(t,e){var n=new ys;return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),n.setStyle({image:t.getAttribute("xlink:href")||t.getAttribute("href"),x:+t.getAttribute("x"),y:+t.getAttribute("y"),width:+t.getAttribute("width"),height:+t.getAttribute("height")}),n.silent=!0,n},text:function(t,e){var n=t.getAttribute("x")||"0",i=t.getAttribute("y")||"0",o=t.getAttribute("dx")||"0",r=t.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(o),this._textY=parseFloat(i)+parseFloat(r);r=new ro;return jm(e,r),Km(t,r,this._defsUsePending,!1,!0),r},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 o=t.getAttribute("dx")||"0",n=t.getAttribute("dy")||"0",i=new ro;return jm(e,i),Km(t,i,this._defsUsePending,!1,!0),this._textX+=parseFloat(o),this._textY+=parseFloat(n),i},path:function(t,e){var n=_g(t.getAttribute("d")||"");return jm(e,n),Km(t,n,this._defsUsePending,!1,!1),n.silent=!0,n}}),Ym),Um={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),o=parseInt(t.getAttribute("y2")||"0",10),o=new fy(e,n,i,o);return Xm(t,o),Zm(t,o),o},radialgradient:function(t){var e=parseInt(t.getAttribute("cx")||"0",10),n=parseInt(t.getAttribute("cy")||"0",10),i=parseInt(t.getAttribute("r")||"0",10),i=new gy(e,n,i);return Xm(t,i),Zm(t,i),i}};function Ym(){this._defs={},this._root=null}function Xm(t,e){"userSpaceOnUse"===t.getAttribute("gradientUnits")&&(e.global=!0)}function Zm(t,e){for(var n,i,o=t.firstChild;o;)1===o.nodeType&&"stop"===o.nodeName.toLocaleLowerCase()&&(n=void 0,n=(i=o.getAttribute("offset"))&&0<i.indexOf("%")?parseInt(i,10)/100:i?parseFloat(i):0,o0(o,i={},i),i=i.stopColor||o.getAttribute("stop-color")||"#000000",e.colorStops.push({offset:n,color:i})),o=o.nextSibling}function jm(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),z(e.__inheritedStyle,t.__inheritedStyle))}function qm(t){for(var e=t0(t),n=[],i=0;i<e.length;i+=2){var o=parseFloat(e[i]),r=parseFloat(e[i+1]);n.push([o,r])}return n}function Km(t,e,n,i,o){var r=e,a=r.__inheritedStyle=r.__inheritedStyle||{},s={};1===t.nodeType&&(function(t,e){t=t.getAttribute("transform");if(t){t=t.replace(/,/g," ");var i=[],n=null;t.replace(e0,function(t,e,n){return i.push(e,n),""});for(var o=i.length-1;0<o;o-=2){var r=i[o],a=i[o-1],s=t0(r);switch(n=n||ni(),a){case"translate":ai(n,n,[parseFloat(s[0]),parseFloat(s[1]||"0")]);break;case"scale":li(n,n,[parseFloat(s[0]),parseFloat(s[1]||s[0])]);break;case"rotate":si(n,n,-parseFloat(s[0])*n0);break;case"skewX":var l=Math.tan(parseFloat(s[0])*n0);ri(n,[1,0,l,1,0,0],n);break;case"skewY":l=Math.tan(parseFloat(s[0])*n0);ri(n,[1,l,0,1,0,0],n);break;case"matrix":n[0]=parseFloat(s[0]),n[1]=parseFloat(s[1]),n[2]=parseFloat(s[2]),n[3]=parseFloat(s[3]),n[4]=parseFloat(s[4]),n[5]=parseFloat(s[5])}}e.setLocalTransform(n)}}(t,e),o0(t,a,s),i||function(t,e,n){for(var i=0;i<Fm.length;i++){var o=Fm[i],r=t.getAttribute(o);null!=r&&(e[Bm[o]]=r)}for(i=0;i<Hm.length;i++)o=Hm[i],null!=(r=t.getAttribute(o))&&(n[Gm[o]]=r)}(t,a,s)),r.style=r.style||{},null!=a.fill&&(r.style.fill=Qm(r,"fill",a.fill,n)),null!=a.stroke&&(r.style.stroke=Qm(r,"stroke",a.stroke,n)),G(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(t){null!=a[t]&&(r.style[t]=parseFloat(a[t]))}),G(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(t){null!=a[t]&&(r.style[t]=a[t])}),o&&(r.__selfStyle=s),a.lineDash&&(r.style.lineDash=H(t0(a.lineDash),function(t){return parseFloat(t)})),"hidden"!==a.visibility&&"collapse"!==a.visibility||(r.invisible=!0),"none"===a.display&&(r.ignore=!0)}var Jm=/^url\(\s*#(.*?)\)/;function Qm(t,e,n,i){var o=n&&n.match(Jm);if(!o)return n="none"===n?null:n;o=ht(o[1]);i.push([t,e,o])}var $m=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function t0(t){return t.match($m)||[]}var e0=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,n0=Math.PI/180;var i0=/([^\s:;]+)\s*:\s*([^:;]+)/g;function o0(t,e,n){var i,o=t.getAttribute("style");if(o)for(i0.lastIndex=0;null!=(i=i0.exec(o));){var r=i[1],a=xt(Bm,r)?Bm[r]:null;a&&(e[a]=i[2]);r=xt(Gm,r)?Gm[r]:null;r&&(n[r]=i[2])}}function r0(t,e){var n=e.width/t.width,i=e.height/t.height,i=Math.min(n,i);return{scale:i,x:-(t.x+t.width/2)*i+(e.x+e.width/2),y:-(t.y+t.height/2)*i+(e.y+e.height/2)}}var a0=1e-8;function s0(t,e){return Math.abs(t-e)<a0}function l0(t,e,n){var i=0,o=t[0];if(!o)return!1;for(var r=1;r<t.length;r++){var a=t[r];i+=Xa(o[0],o[1],a[0],a[1],e,n),o=a}var s=t[0];return s0(o[0],s[0])&&s0(o[1],s[1])||(i+=Xa(o[0],o[1],s[0],s[1],e,n)),0!==i}var u0,h0,c0=[],T=(x0.prototype.getCenter=function(){},x0),p0=(d(v0,h0=T),v0.prototype.getBoundingRect=function(){var t=this._rect;if(t)return t;for(var t=Number.MAX_VALUE,e=[t,t],n=[-t,-t],i=[],o=[],r=this.geometries,a=0;a<r.length;a++)"polygon"===r[a].type&&(ya(r[a].exterior,i,o),Et(e,e,i),Vt(n,n,o));return 0===a&&(e[0]=e[1]=n[0]=n[1]=0),this._rect=new ki(e[0],e[1],n[0]-e[0],n[1]-e[1])},v0.prototype.contain=function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,o=n.length;i<o;i++)if("polygon"===n[i].type){var r=n[i].exterior,a=n[i].interiors;if(l0(r,t[0],t[1])){for(var s=0;s<(a?a.length:0);s++)if(l0(a[s],t[0],t[1]))continue t;return!0}}return!1},v0.prototype.transformTo=function(t,e,n,i){var o=this.getBoundingRect(),r=o.width/o.height;n?i=i||n/r:n=r*i;for(var i=new ki(t,e,n,i),a=o.calculateTransform(i),s=this.geometries,l=0;l<s.length;l++)if("polygon"===s[l].type){for(var u=s[l].exterior,h=s[l].interiors,c=0;c<u.length;c++)zt(u[c],u[c],a);for(var p=0;p<(h?h.length:0);p++)for(c=0;c<h[p].length;c++)zt(h[p][c],h[p][c],a)}(o=this._rect).copy(i),this._center=[o.x+o.width/2,o.y+o.height/2]},v0.prototype.cloneShallow=function(t){t=new v0(t=null==t?this.name:t,this.geometries,this._center);return t._rect=this._rect,t.transformTo=null,t},v0.prototype.getCenter=function(){return this._center},v0.prototype.setCenter=function(t){this._center=t},v0),d0=(d(m0,u0=T),m0.prototype.getCenter=function(){return this._center||(this._center=this._calculateCenter())},m0.prototype._calculateCenter=function(){for(var t=this._elOnlyForCalculate,e=t.getBoundingRect(),e=[e.x+e.width/2,e.y+e.height/2],n=ii(c0),i=t;i&&!i.isGeoSVGGraphicRoot;)ri(n,i.getLocalTransform(),n),i=i.parent;return ui(n,n),zt(e,e,n),e},m0),f0=yt(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),g0=(y0.prototype.load=function(){var t,e,n,i;return(t=this._firstGraphic)||(t=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(t),this._boundingRect=this._firstGraphic.boundingRect.clone(),e=t.named,n=[],i=yt(),G(e,function(t){var e;null==t.namedFrom&&(e=new d0(t.name,t.el),n.push(e),i.set(t.name,e))}),e=(t={regions:n,regionsMap:i}).regionsMap,this._regions=t.regions,this._regionsMap=e),{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},y0.prototype._buildGraphic=function(t){var e,n;try{ut(null!=(n=(e=t&&(r=t,a={ignoreViewBox:!0,ignoreRootClip:!0},(new Wm).parse(r,a))||{}).root))}catch(t){throw new Error("Invalid svg format\n"+t.message)}var i=new ro;i.add(n),i.isGeoSVGGraphicRoot=!0;var o,r,a,s=e.width,l=e.height,u=e.viewBoxRect,h=this._boundingRect;h||(a=r=t=o=void 0,null!=s?(o=0,r=s):u&&(o=u.x,r=u.width),null!=l?(t=0,a=l):u&&(t=u.y,a=u.height),null!=o&&null!=t||(l=n.getBoundingRect(),null==o&&(o=l.x,r=l.width),null==t&&(t=l.y,a=l.height)),h=this._boundingRect=new ki(o,t,r,a)),u&&(u=r0(u,h),n.scaleX=n.scaleY=u.scale,n.x=u.x,n.y=u.y),i.setClipPath(new Ts({shape:h.plain()}));var c=[];return G(e.named,function(t){null!=f0.get(t.svgNodeTagLower)&&(c.push(t),(t=t.el).silent=!1,t.isGroup&&t.traverse(function(t){t.silent=!1}))}),{root:i,boundingRect:h,named:c}},y0.prototype.useGraphic=function(t){var e,n=this._usedGraphicMap;return(e=n.get(t))||(e=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),n.set(t,e),e)},y0.prototype.freeGraphic=function(t){var e=this._usedGraphicMap,n=e.get(t);n&&(e.removeKey(t),this._freedGraphics.push(n))},y0);function y0(t,e){this.type="geoSVG",this._usedGraphicMap=yt(),this._freedGraphics=[],this._mapName=t,this._parsedXML=Vm(e)}function m0(t,e){t=u0.call(this,t)||this;return t.type="geoSVG",t._elOnlyForCalculate=e,t}function v0(t,e,n){t=h0.call(this,t)||this;return t.type="geoJSON",t.geometries=e,n=n?[n[0],n[1]]:[(e=t.getBoundingRect()).x+e.width/2,e.y+e.height/2],t._center=n,t}function x0(t){this.name=t}function _0(t,e,n){for(var i=[],o=e[0],r=e[1],a=0;a<t.length;a+=2){var s=(s=t.charCodeAt(a)-64)>>1^-(1&s),l=(l=t.charCodeAt(a+1)-64)>>1^-(1&l);s+=o,l+=r,i.push([(o=s)/n,(r=l)/n])}return i}function b0(t,o){return H(U((t=function(t){if(!t.UTF8Encoding)return t;var e=(t=t).UTF8Scale;null==e&&(e=1024);for(var n=t.features,i=0;i<n.length;i++){var o=n[i].geometry;if("Polygon"===o.type)for(var r=o.coordinates,a=0;a<r.length;a++)r[a]=_0(r[a],o.encodeOffsets[a],e);else if("MultiPolygon"===o.type)for(r=o.coordinates,a=0;a<r.length;a++)for(var s=r[a],l=0;l<s.length;l++)s[l]=_0(s[l],o.encodeOffsets[a][l],e)}return t.UTF8Encoding=!1,t}(t)).features,function(t){return t.geometry&&t.properties&&0<t.geometry.coordinates.length}),function(t){var e=t.properties,t=t.geometry,n=[];"Polygon"===t.type&&(i=t.coordinates,n.push({type:"polygon",exterior:i[0],interiors:i.slice(1)})),"MultiPolygon"===t.type&&G(i=t.coordinates,function(t){t[0]&&n.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var i=new p0(e[o||"name"],n,e.cp);return i.properties=e,i})}for(var w0=[126,25],S0=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]],M0=0;M0<S0.length;M0++)for(var I0=0;I0<S0[M0].length;I0++)S0[M0][I0][0]/=10.5,S0[M0][I0][1]/=-14,S0[M0][I0][0]+=w0[0],S0[M0][I0][1]+=w0[1];var T0={"南海诸岛":[32,80],"广东":[0,-10],"香港":[10,5],"澳门":[-10,10],"天津":[5,5]};var C0={Russia:[100,60],"United States":[-99,38],"United States of America":[-99,38]};var D0=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];var A0=(k0.prototype.load=function(n,t){var e,i=this._parsedMap.get(t=t||"name");i||(e=this._parseToRegions(t),i=this._parsedMap.set(t,{regions:e,boundingRect:function(t){for(var e,n=0;n<t.length;n++){var i=t[n].getBoundingRect();(e=e||i.clone()).union(i)}return e}(e)}));var o=yt(),r=[];return G(i.regions,function(t){var e=t.name;n&&n.hasOwnProperty(e)&&(t=t.cloneShallow(e=n[e])),r.push(t),o.set(e,t)}),{regions:r,boundingRect:i.boundingRect||new ki(0,0,0,0),regionsMap:o}},k0.prototype._parseToRegions=function(t){var e,r=this._mapName,n=this._geoJSON;try{e=n?b0(n,t):[]}catch(t){throw new Error("Invalid geoJson format\n"+t.message)}return function(t,e){if("china"===t){for(var n=0;n<e.length;n++)if("南海诸岛"===e[n].name)return;e.push(new p0("南海诸岛",H(S0,function(t){return{type:"polygon",exterior:t}}),w0))}}(r,e),G(e,function(t){var e,n,i,o=t.name;n=t,"china"!==(e=r)||(i=T0[n.name])&&((e=n.getCenter())[0]+=i[0]/10.5,e[1]+=-i[1]/14,n.setCenter(e)),n=t,"world"!==(e=r)||(e=C0[n.name])&&(e=[e[0],e[1]],n.setCenter(e)),e=t,"china"===r&&"台湾"===e.name&&e.geometries.push({type:"polygon",exterior:D0[0]});o=this._specialAreas&&this._specialAreas[o];o&&t.transformTo(o.left,o.top,o.width,o.height)},this),e},k0.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},k0);function k0(t,e,n){this.type="geoJSON",this._parsedMap=yt(),this._mapName=t,this._specialAreas=n,this._geoJSON=K(e=e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e}var L0=yt(),P0=function(t,e,n){var i,n=e.svg?new g0(t,e.svg):((i=e.geoJson||e.geoJSON)&&!e.features?n=e.specialAreas:i=e,new A0(t,i,n));L0.set(t,n)},O0=function(t){return L0.get(t)},R0=function(t,e,n){t=L0.get(t);if(t)return t.load(e,n)},N0=new Gt,z0="undefined"!=typeof window,Jn={PROCESSOR:{FILTER:1e3,SERIES_FILTER:800,STATISTIC:5e3},VISUAL:{LAYOUT:1e3,PROGRESSIVE_LAYOUT:1100,GLOBAL:2e3,CHART:3e3,POST_CHART_LAYOUT:4600,COMPONENT:4e3,BRUSH:5e3,CHART_ITEM:4500,ARIA:6e3,DECAL:7e3}},E0="__flagInMainProcess",V0="__pendingUpdate",B0="__needsUpdateStatus",F0=/^[a-zA-Z0-9_]+$/,G0="__connectUpdateStatus";function H0(n){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(!this.isDisposed())return U0(this,n,t);bv(this.id)}}function W0(n){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return U0(this,n,t)}}function U0(t,e,n){return n[0]=n[0]&&n[0].toLowerCase(),Gt.prototype[e].apply(t,n)}var Y0,X0,Z0,j0,q0,K0,J0,Q0,$0,tv,ev,nv,iv,ov,rv,av,sv,lv,uv,hv,cv=(d(pv,hv=Gt),pv),T=cv.prototype;function pv(){return null!==hv&&hv.apply(this,arguments)||this}T.on=W0("on"),T.off=W0("off");var dv,fv=(d(gv,dv=Gt),gv.prototype._onframe=function(){if(!this._disposed){uv(this);var t=this._scheduler;if(this[V0]){var e=this[V0].silent;this[E0]=!0,Y0(this),j0.update.call(this,null,this[V0].updateParams),this._zr.flush(),this[E0]=!1,this[V0]=null,Q0.call(this,e),$0.call(this,e)}else if(t.unfinished){var n=1,i=this._model,o=this._api;t.unfinished=!1;do{var r=+new Date}while(t.performSeriesTasks(i),t.performDataProcessorTasks(i),K0(this,i),t.performVisualTasks(i),rv(this,this._model,o,"remain",{}),0<(n-=+new Date-r)&&t.unfinished);t.unfinished||this._zr.flush()}}},gv.prototype.getDom=function(){return this._dom},gv.prototype.getId=function(){return this.id},gv.prototype.getZr=function(){return this._zr},gv.prototype.setOption=function(t,e,n){var i,o,r,a,s;this._disposed?bv(this.id):($(e)&&(n=e.lazyUpdate,i=e.silent,o=e.replaceMerge,s=e.transition,e=e.notMerge),this[E0]=!0,this._model&&!e||(r=new Cc(this._api),a=this._theme,(e=this._model=new _c).scheduler=this._scheduler,e.init(null,null,null,a,this._locale,r)),this._model.setOption(t,{replaceMerge:o},Iv),s={seriesTransition:s,optionChanged:!0},n?(this[V0]={silent:i,updateParams:s},this[E0]=!1,this.getZr().wakeUp()):(Y0(this),j0.update.call(this,null,s),this._zr.flush(),this[V0]=null,this[E0]=!1,Q0.call(this,i),$0.call(this,i)))},gv.prototype.setTheme=function(){},gv.prototype.getModel=function(){return this._model},gv.prototype.getOption=function(){return this._model&&this._model.getOption()},gv.prototype.getWidth=function(){return this._zr.getWidth()},gv.prototype.getHeight=function(){return this._zr.getHeight()},gv.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||z0&&window.devicePixelRatio||1},gv.prototype.getRenderedCanvas=function(t){if(w.canvasSupported)return this._zr.painter.getRenderedCanvas({backgroundColor:(t=t||{}).backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},gv.prototype.getSvgDataURL=function(){if(w.svgSupported){var t=this._zr;return G(t.storage.getDisplayList(),function(t){t.stopAnimation(null,!0)}),t.painter.toDataURL()}},gv.prototype.getDataURL=function(t){if(!this._disposed){var e=(t=t||{}).excludeComponents,n=this._model,i=[],o=this;G(e,function(t){n.eachComponent({mainType:t},function(t){t=o._componentsMap[t.__viewId];t.group.ignore||(i.push(t),t.group.ignore=!0)})});t="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return G(i,function(t){t.group.ignore=!1}),t}bv(this.id)},gv.prototype.getConnectedDataURL=function(i){if(this._disposed)bv(this.id);else if(w.canvasSupported){var o="svg"===i.type,r=this.group,a=Math.min,s=Math.max;if(kv[r]){var l=1/0,u=1/0,h=-1/0,c=-1/0,p=[],e=i&&i.pixelRatio||this.getDevicePixelRatio();G(Av,function(t,e){var n;t.group===r&&(n=o?t.getZr().painter.getSvgDom().innerHTML:t.getRenderedCanvas(P(i)),t=t.getDom().getBoundingClientRect(),l=a(t.left,l),u=a(t.top,u),h=s(t.right,h),c=s(t.bottom,c),p.push({dom:n,left:t.left,top:t.top}))});var t=(h*=e)-(l*=e),n=(c*=e)-(u*=e),d=E(),f=co(d,{renderer:o?"svg":"canvas"});if(f.resize({width:t,height:n}),o){var g="";return G(p,function(t){var e=t.left-l,n=t.top-u;g+='<g transform="translate('+e+","+n+')">'+t.dom+"</g>"}),f.painter.getSvgRoot().innerHTML=g,i.connectedBackgroundColor&&f.painter.setBackgroundColor(i.connectedBackgroundColor),f.refreshImmediately(),f.painter.toDataURL()}return i.connectedBackgroundColor&&f.add(new Ts({shape:{x:0,y:0,width:t,height:n},style:{fill:i.connectedBackgroundColor}})),G(p,function(t){t=new ys({style:{x:t.left*e-l,y:t.top*e-u,image:t.dom}});f.add(t)}),f.refreshImmediately(),d.toDataURL("image/"+(i&&i.type||"png"))}return this.getDataURL(i)}},gv.prototype.convertToPixel=function(t,e){return q0(this,"convertToPixel",t,e)},gv.prototype.convertFromPixel=function(t,e){return q0(this,"convertFromPixel",t,e)},gv.prototype.containPixel=function(t,i){var o;if(!this._disposed)return G(qo(this._model,t),function(t,n){0<=n.indexOf("Models")&&G(t,function(t){var e=t.coordinateSystem;e&&e.containPoint?o=o||!!e.containPoint(i):"seriesModels"!==n||(e=this._chartsMap[t.__viewId])&&e.containPoint&&(o=o||e.containPoint(i,t))},this)},this),!!o;bv(this.id)},gv.prototype.getVisual=function(t,e){var n=qo(this._model,t,{defaultMainType:"series"}),t=n.seriesModel.getData(),n=n.hasOwnProperty("dataIndexInside")?n.dataIndexInside:n.hasOwnProperty("dataIndex")?t.indexOfRawIndex(n.dataIndex):null;return null!=n?zf(t,n,e):Ef(t,e)},gv.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},gv.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},gv.prototype._initEvents=function(){var t,n,i,s=this;G(_v,function(a){function t(t){var n,e,i,o=s.getModel(),r=t.target;"globalout"===a?n={}:r&&Gf(r,function(t){var e=Gs(t);if(e&&null!=e.dataIndex){t=e.dataModel||o.getSeriesByIndex(e.seriesIndex);return n=t&&t.getDataParams(e.dataIndex,e.dataType)||{},1}return e.eventData&&(n=N({},e.eventData),1)},!0),n&&(e=n.componentType,i=n.componentIndex,"markLine"!==e&&"markPoint"!==e&&"markArea"!==e||(e="series",i=n.seriesIndex),i=(e=e&&null!=i&&o.getComponent(e,i))&&s["series"===e.mainType?"_chartsMap":"_componentsMap"][e.__viewId],n.event=t,n.type=a,s._$eventProcessor.eventInfo={targetEl:r,packedEvent:n,model:e,view:i},s.trigger(a,n))}t.zrEventfulCallAtLast=!0,s._zr.on(a,t,s)}),G(Sv,function(t,e){s._messageCenter.on(e,function(t){this.trigger(e,t)},s)}),G(["selectchanged"],function(e){s._messageCenter.on(e,function(t){this.trigger(e,t)},s)}),t=this._messageCenter,i=(n=this)._api,t.on("selectchanged",function(t){var e=i.getModel();t.isFromClick?(Ff("map","selectchanged",n,e,t),Ff("pie","selectchanged",n,e,t)):"select"===t.fromAction?(Ff("map","selected",n,e,t),Ff("pie","selected",n,e,t)):"unselect"===t.fromAction&&(Ff("map","unselected",n,e,t),Ff("pie","unselected",n,e,t))})},gv.prototype.isDisposed=function(){return this._disposed},gv.prototype.clear=function(){this._disposed?bv(this.id):this.setOption({series:[]},!0)},gv.prototype.dispose=function(){var t,e,n;this._disposed?bv(this.id):(this._disposed=!0,tr(this.getDom(),Pv,""),e=(t=this)._api,n=t._model,G(t._componentsViews,function(t){t.dispose(n,e)}),G(t._chartsViews,function(t){t.dispose(n,e)}),t._zr.dispose(),t._dom=t._model=t._chartsMap=t._componentsMap=t._chartsViews=t._componentsViews=t._scheduler=t._api=t._zr=t._throttledZrFlush=t._theme=t._coordSysMgr=t._messageCenter=null,delete Av[t.id])},gv.prototype.resize=function(t){var e,n;this._disposed?bv(this.id):(this._zr.resize(t),n=this._model,this._loadingFX&&this._loadingFX.resize(),n&&(e=n.resetOption("media"),n=t&&t.silent,this[V0]&&(null==n&&(n=this[V0].silent),e=!0,this[V0]=null),this[E0]=!0,e&&Y0(this),j0.update.call(this,{type:"resize",animation:N({duration:0},t&&t.animation)}),this[E0]=!1,Q0.call(this,n),$0.call(this,n)))},gv.prototype.showLoading=function(t,e){this._disposed?bv(this.id):($(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),Dv[t]&&(t=Dv[t](this._api,e),e=this._zr,this._loadingFX=t,e.add(t)))},gv.prototype.hideLoading=function(){this._disposed?bv(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},gv.prototype.makeActionFromEvent=function(t){var e=N({},t);return e.type=Sv[t.type],e},gv.prototype.dispatchAction=function(t,e){var n;this._disposed?bv(this.id):($(e)||(e={silent:!!e}),wv[t.type]&&this._model&&(this[E0]?this._pendingActions.push(t):(n=e.silent,J0.call(this,t,n),(e=e.flush)?this._zr.flush():!1!==e&&w.browser.weChat&&this._throttledZrFlush(),Q0.call(this,n),$0.call(this,n))))},gv.prototype.updateLabelLayout=function(){N0.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},gv.prototype.appendData=function(t){var e;this._disposed?bv(this.id):(e=t.seriesIndex,this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp())},gv.internalField=(Y0=function(t){var e=t._scheduler;e.restorePipelines(t._model),e.prepareStageTasks(),X0(t,!0),X0(t,!1),e.plan()},X0=function(t,o){for(var r=t._model,a=t._scheduler,s=o?t._componentsViews:t._chartsViews,l=o?t._componentsMap:t._chartsMap,u=t._zr,h=t._api,e=0;e<s.length;e++)s[e].__alive=!1;function n(t){var e=t.__requireNewView;t.__requireNewView=!1;var n="_ec_"+t.id+"_"+t.type,i=!e&&l[n];i||(e=ar(t.type),(i=new(o?Wd.getClass(e.main,e.sub):$d.getClass(e.sub))).init(r,h),l[n]=i,s.push(i),u.add(i.group)),t.__viewId=i.__id=n,i.__alive=!0,i.__model=t,i.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},o||a.prepareView(i,t,r,h)}for(o?r.eachComponent(function(t,e){"series"!==t&&n(e)}):r.eachSeries(n),e=0;e<s.length;){var i=s[e];i.__alive?e++:(o||i.renderTask.dispose(),u.remove(i.group),i.dispose(r,h),s.splice(e,1),l[i.__id]===i&&delete l[i.__id],i.__id=i.group.__ecComponentInfo=null)}},Z0=function(r,e,a,n,t){var i,s,o=r._model;function l(t){t&&t.__alive&&t[e]&&t[e](t.__model,o,r._api,a)}o.setUpdatePayload(a),n?((i={})[n+"Id"]=a[n+"Id"],i[n+"Index"]=a[n+"Index"],i[n+"Name"]=a[n+"Name"],i={mainType:n,query:i},t&&(i.subType=t),null!=(t=a.excludeSeriesId)&&(s=yt(),G(No(t),function(t){t=Ho(t,null);null!=t&&s.set(t,!0)})),Bl(a)&&Tl(r._api),o&&o.eachComponent(i,function(t){var e,n,i,o;s&&null!==s.get(t.id)||(Bl(a)?t instanceof Gd?a.type!==Ks||a.notBlur||function(t,e,n){var i,o=t.seriesIndex,r=t.getData(e.dataType),e=(j(e=Xo(r,e))?e[0]:e)||0,a=r.getItemGraphicEl(e);if(!a)for(var s=r.count(),l=0;!a&&l<s;)a=r.getItemGraphicEl(l++);a?Cl(o,(i=Gs(a)).focus,i.blurScope,n):(i=t.get(["emphasis","focus"]),t=t.get(["emphasis","blurScope"]),null!=i&&Cl(o,i,t,n))}(t,a,r._api):(i=(n=Al(t.mainType,t.componentIndex,a.name,r._api)).focusSelf,o=n.dispatchers,a.type===Ks&&i&&!a.notBlur&&Dl(t.mainType,t.componentIndex,r._api),o&&G(o,function(t){(a.type===Ks?xl:_l)(t)})):Vl(a)&&t instanceof Gd&&(e=t,n=a,r._api,Vl(n)&&(i=n.dataType,j(o=Xo(e.getData(i),n))||(o=[o]),e[n.type===tl?"toggleSelect":n.type===Qs?"select":"unselect"](o,i)),kl(t),lv(r)))},r),o&&o.eachComponent(i,function(t){s&&null!==s.get(t.id)||l(r["series"===n?"_chartsMap":"_componentsMap"][t.__viewId])},r)):G([].concat(r._componentsViews).concat(r._chartsViews),l)},j0={prepareAndUpdate:function(t){Y0(this),j0.update.call(this,t,{optionChanged:null!=t.newOption})},update:function(t,e){var n=this._model,i=this._api,o=this._zr,r=this._coordSysMgr,a=this._scheduler;n&&(n.setUpdatePayload(t),a.restoreData(n,t),a.performSeriesTasks(n),r.create(n,i),a.performDataProcessorTasks(n,t),K0(this,n),r.update(n,i),nv(n),a.performVisualTasks(n,t),iv(this,n,i,t,e),t=n.get("backgroundColor")||"transparent",e=n.get("darkMode"),w.canvasSupported?(o.setBackgroundColor(t),null!=e&&"auto"!==e&&o.setDarkMode(e)):(t=pn(e=rn(t),"rgb"),0===e[3]&&(t="transparent")),N0.trigger("afterupdate",n,i))},updateTransform:function(n){var i,o,r=this,a=this._model,s=this._api;a&&(a.setUpdatePayload(n),i=[],a.eachComponent(function(t,e){"series"===t||(t=r.getViewOfComponentModel(e))&&t.__alive&&(!t.updateTransform||(e=t.updateTransform(e,a,s,n))&&e.update)&&i.push(t)}),o=yt(),a.eachSeries(function(t){var e=r._chartsMap[t.__viewId];(!e.updateTransform||(e=e.updateTransform(t,a,s,n))&&e.update)&&o.set(t.uid,1)}),nv(a),this._scheduler.performVisualTasks(a,n,{setDirty:!0,dirtyMap:o}),rv(this,a,s,n,{},o),N0.trigger("afterupdate",a,s))},updateView:function(t){var e=this._model;e&&(e.setUpdatePayload(t),$d.markUpdateMethod(t,"updateView"),nv(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),iv(this,e,this._api,t,{}),N0.trigger("afterupdate",e,this._api))},updateVisual:function(n){var i=this,o=this._model;o&&(o.setUpdatePayload(n),o.eachSeries(function(t){t.getData().clearAllVisual()}),$d.markUpdateMethod(n,"updateVisual"),nv(o),this._scheduler.performVisualTasks(o,n,{visualType:"visual",setDirty:!0}),o.eachComponent(function(t,e){"series"===t||(t=i.getViewOfComponentModel(e))&&t.__alive&&t.updateVisual(e,o,i._api,n)}),o.eachSeries(function(t){i._chartsMap[t.__viewId].updateVisual(t,o,i._api,n)}),N0.trigger("afterupdate",o,this._api))},updateLayout:function(t){j0.update.call(this,t)}},q0=function(t,e,n,i){if(t._disposed)bv(t.id);else for(var o,r=t._model,a=t._coordSysMgr.getCoordinateSystems(),s=qo(r,n),l=0;l<a.length;l++){var u=a[l];if(u[e]&&null!=(o=u[e](r,s,i)))return o}},K0=function(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})},J0=function(i,t){var o=this,e=this.getModel(),n=i.type,r=i.escapeConnect,a=wv[n],s=a.actionInfo,l=(s.update||"update").split(":"),u=l.pop(),h=null!=l[0]&&ar(l[0]);this[E0]=!0;var c=[i],l=!1;i.batch&&(l=!0,c=H(i.batch,function(t){return(t=z(N({},t),i)).batch=null,t}));var p,d,f=[],g=Vl(i),y=Bl(i);G(c,function(t){var e,n;(p=(p=a.action(t,o._model,o._api))||N({},t)).type=s.event||p.type,f.push(p),y?(n=(e=Ko(i)).queryOptionMap,n=e.mainTypeSpecified?n.keys()[0]:"series",Z0(o,u,t,n),lv(o)):g?(Z0(o,u,t,"series"),lv(o)):h&&Z0(o,u,t,h.main,h.sub)}),"none"===u||y||g||h||(this[V0]?(Y0(this),j0.update.call(this,i),this[V0]=null):j0[u].call(this,i)),p=l?{type:s.event||n,escapeConnect:r,batch:f}:f[0],this[E0]=!1,t||((t=this._messageCenter).trigger(p.type,p),g&&(e={type:"selectchanged",escapeConnect:r,selected:(d=[],e.eachSeries(function(n){G(n.getAllData(),function(t){t.data;var e=t.type,t=n.getSelectedDataIndices();0<t.length&&(t={dataIndex:t,seriesIndex:n.seriesIndex},null!=e&&(t.dataType=e),d.push(t))})}),d),isFromClick:i.isFromClick||!1,fromAction:i.type,fromActionPayload:i},t.trigger(e.type,e)))},Q0=function(t){for(var e=this._pendingActions;e.length;){var n=e.shift();J0.call(this,n,t)}},$0=function(t){t||this.trigger("updated")},tv=function(e,n){e.on("rendered",function(t){n.trigger("rendered",t),!e.animation.isFinished()||n[V0]||n._scheduler.unfinished||n._pendingActions.length||n.trigger("finished")})},ev=function(t,a){t.on("mouseover",function(t){var e,n,i,o,r=Gf(t.target,El);r&&(e=r,n=t,i=a._api,o=Gs(e),t=(r=Al(o.componentMainType,o.componentIndex,o.componentHighDownName,i)).dispatchers,r=r.focusSelf,t?(r&&Dl(o.componentMainType,o.componentIndex,i),G(t,function(t){return ml(t,n)})):(Cl(o.seriesIndex,o.focus,o.blurScope,i),"self"===o.focus&&Dl(o.componentMainType,o.componentIndex,i),ml(e,n)),lv(a))}).on("mouseout",function(t){var e=Gf(t.target,El);e&&(function(t,e,n){Tl(n);var i=Gs(t);(n=Al(i.componentMainType,i.componentIndex,i.componentHighDownName,n).dispatchers)?G(n,function(t){return vl(t,e)}):vl(t,e)}(e,t,a._api),lv(a))}).on("click",function(t){var e=Gf(t.target,function(t){return null!=Gs(t).dataIndex},!0);e&&(t=e.selected?"unselect":"select",e=Gs(e),a._api.dispatchAction({type:t,dataType:e.dataType,dataIndexInside:e.dataIndex,seriesIndex:e.seriesIndex,isFromClick:!0}))})},nv=function(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})},iv=function(t,e,n,i,o){ov(t,e,n,i,o),G(t._chartsViews,function(t){t.__alive=!1}),rv(t,e,n,i,o),G(t._chartsViews,function(t){t.__alive||t.remove(e,n)})},ov=function(t,n,i,o,e,r){G(r||t._componentsViews,function(t){var e=t.__model;vv(0,t),t.render(e,n,i,o),mv(e,t),xv(e,t)})},rv=function(o,t,e,r,n,a){var s=o._scheduler;n=N(n||{},{updatedSeries:t.getSeries()}),N0.trigger("series:beforeupdate",t,e,n);var i,l,u,h,c=!1;t.eachSeries(function(t){var e=o._chartsMap[t.__viewId];e.__alive=!0;var n,i=e.renderTask;s.updatePayload(i,r),vv(0,e),a&&a.get(t.uid)&&i.dirty(),i.perform(s.getPerformArgs(i))&&(c=!0),e.group.silent=!!t.get("silent"),e=e,n=t.get("blendMode")||null,e.group.traverse(function(t){t.isGroup||(t.style.blend=n),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.style.blend=n})}),kl(t)}),s.unfinished=c||s.unfinished,N0.trigger("series:layoutlabels",t,e,n),N0.trigger("series:transition",t,e,n),t.eachSeries(function(t){var e=o._chartsMap[t.__viewId];mv(t,e),xv(t,e)}),l=t,u=(i=o)._zr.storage,h=0,u.traverse(function(t){t.isGroup||h++}),h>l.get("hoverLayerThreshold")&&!w.node&&!w.worker&&l.eachSeries(function(t){t.preventUsingHoverLayer||(t=i._chartsMap[t.__viewId]).__alive&&t.group.traverse(function(t){t.states.emphasis&&(t.states.emphasis.hoverLayer=!0)})}),N0.trigger("series:afterupdate",t,e,n)},lv=function(t){t[B0]=!0,t.getZr().wakeUp()},uv=function(t){t[B0]&&(t.getZr().storage.traverse(function(t){Yl(t)||yv(t)}),t[B0]=!1)},av=function(n){return d(t,e=xc),t.prototype.getCoordinateSystems=function(){return n._coordSysMgr.getCoordinateSystems()},t.prototype.getComponentByElement=function(t){for(;t;){var e=t.__ecComponentInfo;if(null!=e)return n._model.getComponent(e.mainType,e.index);t=t.parent}},t.prototype.enterEmphasis=function(t,e){xl(t,e),lv(n)},t.prototype.leaveEmphasis=function(t,e){_l(t,e),lv(n)},t.prototype.enterBlur=function(t){bl(t),lv(n)},t.prototype.leaveBlur=function(t){wl(t),lv(n)},t.prototype.enterSelect=function(t){Sl(t),lv(n)},t.prototype.leaveSelect=function(t){Ml(t),lv(n)},t.prototype.getModel=function(){return n.getModel()},t.prototype.getViewOfComponentModel=function(t){return n.getViewOfComponentModel(t)},t.prototype.getViewOfSeriesModel=function(t){return n.getViewOfSeriesModel(t)},new t(n);function t(){return null!==e&&e.apply(this,arguments)||this}var e},void(sv=function(i){function o(t,e){for(var n=0;n<t.length;n++)t[n][G0]=e}G(Sv,function(t,e){i._messageCenter.on(e,function(t){var e,n;kv[i.group]&&0!==i[G0]&&(t&&t.escapeConnect||(e=i.makeActionFromEvent(t),n=[],G(Av,function(t){t!==i&&t.group===i.group&&n.push(t)}),o(n,0),G(n,function(t){1!==t[G0]&&t.dispatchAction(e)}),o(n,2)))})})})),gv),T=fv.prototype;function gv(t,e,n){var i=dv.call(this,new Rf)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],n=n||{},"string"==typeof e&&(e=Cv[e]),i._dom=t;t=i._zr=co(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,useDirtyRect:null!=n.useDirtyRect&&n.useDirtyRect});i._throttledZrFlush=of(X(t.flush,t),17),(e=P(e))&&Xc(e,!0),i._theme=e,i._locale=function(t){if(K(t)){var e=Au[t.toUpperCase()]||{};return t===Tu||t===Cu?P(e):O(P(e),P(Au[Du]),!1)}return O(P(t),P(Au[Du]),!1)}(n.locale||Lu),i._coordSysMgr=new Sc;n=i._api=av(i);function o(t,e){return t.__prio-e.__prio}return Ae(Tv,o),Ae(Mv,o),i._scheduler=new Pf(i,n,Mv,Tv),i._messageCenter=new cv,i._initEvents(),i.resize=X(i.resize,i),t.animation.on("frame",i._onframe,i),tv(t,i),ev(t,i),pt(i),i}function yv(t){for(var e=[],n=t.currentStates,i=0;i<n.length;i++){var o=n[i];"emphasis"!==o&&"blur"!==o&&"select"!==o&&e.push(o)}t.selected&&t.states.select&&e.push("select"),t.hoverState===Zs&&t.states.emphasis?e.push("emphasis"):t.hoverState===Xs&&t.states.blur&&e.push("blur"),t.useStates(e)}function mv(t,e){t.preventAutoZ||function t(e,n,i,o){var r=e.getTextContent(),a=e.getTextGuideLine(),s=e.isGroup;if(s)for(var l=e.childrenRef(),u=0;u<l.length;u++)o=Math.max(t(l[u],n,i,o),o);else e.z=n,e.zlevel=i,o=Math.max(e.z2,o);r&&(r.z=n,r.zlevel=i,isFinite(o)&&(r.z2=o+2)),a&&(e=e.textGuideLineConfig,a.z=n,a.zlevel=i,isFinite(o)&&(a.z2=o+(e&&e.showAbove?1:-1)));return o}(e.group,t.get("z")||0,t.get("zlevel")||0,-1/0)}function vv(t,e){e.group.traverse(function(t){var e,n;Yl(t)||(e=t.getTextContent(),n=t.getTextGuideLine(),t.stateTransition&&(t.stateTransition=null),e&&e.stateTransition&&(e.stateTransition=null),n&&n.stateTransition&&(n.stateTransition=null),t.hasState()?(t.prevStates=t.currentStates,t.clearStates()):t.prevStates&&(t.prevStates=null))})}function xv(t,e){var n=t.getModel("stateAnimation"),o=t.isAnimationEnabled(),t=n.get("duration"),r=0<t?{duration:t,delay:n.get("delay"),easing:n.get("easing")}:null;e.group.traverse(function(t){var e,n,i;t.states&&t.states.emphasis&&(Yl(t)||(t instanceof as&&((i=Us(n=t)).normalFill=n.style.fill,i.normalStroke=n.style.stroke,n=n.states.select||{},i.selectFill=n.style&&n.style.fill||null,i.selectStroke=n.style&&n.style.stroke||null),t.__dirty&&(e=t.prevStates)&&t.useStates(e),o&&(t.stateTransition=r,n=t.getTextContent(),e=t.getTextGuideLine(),n&&(n.stateTransition=r),e&&(e.stateTransition=r)),t.__dirty&&yv(t)))})}T.on=H0("on"),T.off=H0("off"),T.one=function(i,o,t){var r=this;this.on.call(this,i,function t(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];o&&o.apply&&o.apply(this,e),r.off(i,t)},t)};var _v=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];function bv(){}var wv={},Sv={},Mv=[],Iv=[],Tv=[],Cv={},Dv={},Av={},kv={},Lv=+new Date,Pv=(new Date,"_echarts_instance_");function Ov(t,e,n){var i=Av[function(t,e){return t.getAttribute?t.getAttribute(e):t[e]}(t,Pv)];if(i)return i;n=new fv(t,e,n);return n.id="ec_"+Lv++,Av[n.id]=n,tr(t,Pv,n.id),sv(n),N0.trigger("afterinit",n),n}function Rv(t,e){Cv[t]=e}function Nv(t){V(Iv,t)<0&&Iv.push(t)}function zv(t,e){Gv(Mv,t,e,2e3)}function Ev(t,e){N0.on(t,e)}function Vv(t,e,n){"function"==typeof e&&(n=e,e="");var i=$(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,Sv[e]||(ut(F0.test(i)&&F0.test(e)),wv[i]||(wv[i]={action:n,actionInfo:t}),Sv[e]=i)}function Bv(t,e){Gv(Tv,t,e,3e3,"visual")}var Fv=[];function Gv(t,e,n,i,o){(q(e)||$(e))&&(n=e,e=i),0<=V(Fv,n)||(Fv.push(n),(o=Pf.wrapStageHandler(n,o)).__prio=e,o.__raw=n,t.push(o))}function Hv(t,e){Dv[t]=e}function Wv(t){var e=(t=P(t)).type;e||pc("");var n=e.split(":");2!==n.length&&pc("");var i=!1;"echarts"===n[0]&&(e=n[1],i=!0),t.__isBuiltIn=i,jp.set(e,t)}Bv(2e3,y),Bv(4500,Ki),Bv(4500,no),Bv(2e3,vi),Bv(4500,gr),Bv(7e3,function(e,i){e.eachRawSeries(function(t){var n;e.isSeriesFiltered(t)||((n=t.getData()).hasItemVisual()&&n.each(function(t){var e=n.getItemVisual(t,"decal");e&&(n.ensureUniqueItemVisual(t,"style").decal=zm(e,i))}),(t=n.getVisual("decal"))&&(n.getVisual("style").decal=zm(t,i)))})}),Nv(Xc),zv(900,function(t){var i=yt();t.eachSeries(function(t){var e,n=t.get("stack");n&&(e=i.get(n)||i.set(n,[]),(t={stackResultDimension:(n=t.getData()).getCalculationInfo("stackResultDimension"),stackedOverDimension:n.getCalculationInfo("stackedOverDimension"),stackedDimension:n.getCalculationInfo("stackedDimension"),stackedByDimension:n.getCalculationInfo("stackedByDimension"),isStackedByIndex:n.getCalculationInfo("isStackedByIndex"),data:n,seriesModel:t}).stackedDimension&&(t.isStackedByIndex||t.stackedByDimension)&&(e.length&&n.setCalculationInfo("stackedOnSeries",e[e.length-1].seriesModel),e.push(t)))}),i.each(Zc)}),Hv("default",function(i,o){z(o=o||{},{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var t=new ro,r=new Ts({style:{fill:o.maskColor},zlevel:o.zlevel,z:1e4});t.add(r);var a,s=new Fs({style:{text:o.text,fill:o.textColor,fontSize:o.fontSize,fontWeight:o.fontWeight,fontStyle:o.fontStyle,fontFamily:o.fontFamily},zlevel:o.zlevel,z:10001}),l=new Ts({style:{fill:"none"},textContent:s,textConfig:{position:"right",distance:10},zlevel:o.zlevel,z:10001});return t.add(l),o.showSpinner&&((a=new gf({shape:{startAngle:-yf/2,endAngle:-yf/2+.1,r:o.spinnerRadius},style:{stroke:o.color,lineCap:"round",lineWidth:o.lineWidth},zlevel:o.zlevel,z:10001})).animateShape(!0).when(1e3,{endAngle:3*yf/2}).start("circularInOut"),a.animateShape(!0).when(1e3,{startAngle:3*yf/2}).delay(300).start("circularInOut"),t.add(a)),t.resize=function(){var t=s.getBoundingRect().width,e=o.showSpinner?o.spinnerRadius:0,n=(i.getWidth()-2*e-(o.showSpinner&&t?10:0)-t)/2-(o.showSpinner&&t?0:5+t/2)+(o.showSpinner?0:t/2)+(t?0:e),t=i.getHeight()/2;o.showSpinner&&a.setShape({cx:n,cy:t}),l.setShape({x:n-e,y:t-e,width:2*e,height:2*e}),r.setShape({x:0,y:0,width:i.getWidth(),height:i.getHeight()})},t.resize(),t}),Vv({type:Ks,event:Ks,update:Ks},_t),Vv({type:Js,event:Js,update:Js},_t),Vv({type:Qs,event:Qs,update:Qs},_t),Vv({type:$s,event:$s,update:$s},_t),Vv({type:tl,event:tl,update:tl},_t),Rv("light",C),Rv("dark",io);var Uv=[],Yv={registerPreprocessor:Nv,registerProcessor:zv,registerPostInit:function(t){Ev("afterinit",t)},registerPostUpdate:function(t){Ev("afterupdate",t)},registerUpdateLifecycle:Ev,registerAction:Vv,registerCoordinateSystem:function(t,e){Sc.register(t,e)},registerLayout:function(t,e){Gv(Tv,t,e,1e3,"layout")},registerVisual:Bv,registerTransform:Wv,registerLoading:Hv,registerMap:function(t,e,n){P0(t,e,n)},PRIORITY:Jn,ComponentModel:Vh,ComponentView:Wd,SeriesModel:Gd,ChartView:$d,registerComponentModel:function(t){Vh.registerClass(t)},registerComponentView:function(t){Wd.registerClass(t)},registerSeriesModel:function(t){Gd.registerClass(t)},registerChartView:function(t){$d.registerClass(t)},registerSubTypeDefaulter:function(t,e){Vh.registerSubTypeDefaulter(t,e)},registerPainter:function(t,e){so[t]=e}};function Xv(t){j(t)?G(t,function(t){Xv(t)}):0<=V(Uv,t)||(Uv.push(t),(t=q(t)?{install:t}:t).install(Yv))}var Zv=2*Math.PI,jv=Ba.CMD,qv=["top","right","bottom","left"];function Kv(t,e,n,i,o,r,a,s){var l=o-t,u=r-e,h=n-t,n=i-e,i=Math.sqrt(h*h+n*n),u=(l*(h/=i)+u*(n/=i))/i;s&&(u=Math.min(Math.max(u,0),1));h=a[0]=t+(u*=i)*h,n=a[1]=e+u*n;return Math.sqrt((h-o)*(h-o)+(n-r)*(n-r))}function Jv(t,e,n,i,o,r,a){n<0&&(t+=n,n=-n),i<0&&(e+=i,i=-i);n=t+n,i=e+i,n=a[0]=Math.min(Math.max(o,t),n),i=a[1]=Math.min(Math.max(r,e),i);return Math.sqrt((n-o)*(n-o)+(i-r)*(i-r))}var Qv=[];function $v(t,e,n){for(var i=0,o=0,r=0,a=0,s=1/0,l=e.data,u=t.x,h=t.y,c=0;c<l.length;){var p=l[c++];1===c&&(r=i=l[c],a=o=l[c+1]);var d=s;switch(p){case jv.M:i=r=l[c++],o=a=l[c++];break;case jv.L:d=Kv(i,o,l[c],l[c+1],u,h,Qv,!0),i=l[c++],o=l[c++];break;case jv.C:d=na(i,o,l[c++],l[c++],l[c++],l[c++],l[c],l[c+1],u,h,Qv),i=l[c++],o=l[c++];break;case jv.Q:d=sa(i,o,l[c++],l[c++],l[c],l[c+1],u,h,Qv),i=l[c++],o=l[c++];break;case jv.A:var f=l[c++],g=l[c++],y=l[c++],m=l[c++],v=l[c++],x=l[c++];c+=1;var _=!!(1-l[c++]),b=Math.cos(v)*y+f,w=Math.sin(v)*m+g;c<=1&&(r=b,a=w);d=function(t,e,n,i,o,r,a,s,l){a-=t,s-=e;var u=Math.sqrt(a*a+s*s),h=(a/=u)*n+t,c=(s/=u)*n+e;if(Math.abs(i-o)%Zv<1e-4)return l[0]=h,l[1]=c,u-n;(o=r?(p=i,i=Ua(o),Ua(p)):(i=Ua(i),Ua(o)))<i&&(o+=Zv);var p=Math.atan2(s,a);return p<0&&(p+=Zv),i<=p&&p<=o||i<=p+Zv&&p+Zv<=o?(l[0]=h,l[1]=c,u-n):(u=n*Math.cos(i)+t,i=n*Math.sin(i)+e,t=n*Math.cos(o)+t,o=n*Math.sin(o)+e,(e=(u-a)*(u-a)+(i-s)*(i-s))<(s=(t-a)*(t-a)+(o-s)*(o-s))?(l[0]=u,l[1]=i,Math.sqrt(e)):(l[0]=t,l[1]=o,Math.sqrt(s)))}(f,g,m,v,v+x,_,(u-f)*m/y+f,h,Qv),i=Math.cos(v+x)*y+f,o=Math.sin(v+x)*m+g;break;case jv.R:d=Jv(r=i=l[c++],a=o=l[c++],l[c++],l[c++],u,h,Qv);break;case jv.Z:d=Kv(i,o,r,a,u,h,Qv,!0),i=r,o=a}d<s&&(s=d,n.set(Qv[0],Qv[1]))}return s}var t1=new bi,e1=new bi,n1=new bi,i1=new bi,o1=new bi;function r1(t,e){if(t){var n=t.getTextGuideLine(),i=t.getTextContent();if(i&&n){var o=t.textGuideLineConfig||{},r=[[0,0],[0,0],[0,0]],a=o.candidates||qv,s=i.getBoundingRect().clone();s.applyTransform(i.getComputedTransform());var l=1/0,u=o.anchor,h=t.getComputedTransform(),c=h&&ui([],h),p=e.get("length2")||0;u&&n1.copy(u);for(var d=0;d<a.length;d++){(function(t,e,n,i,o){var r=n.width,a=n.height;switch(t){case"top":i.set(n.x+r/2,n.y-e),o.set(0,-1);break;case"bottom":i.set(n.x+r/2,n.y+a+e),o.set(0,1);break;case"left":i.set(n.x-e,n.y+a/2),o.set(-1,0);break;case"right":i.set(n.x+r+e,n.y+a/2),o.set(1,0)}})(a[d],0,s,t1,i1),bi.scaleAndAdd(e1,t1,i1,p),e1.transform(c);var f=t.getBoundingRect(),g=u?u.distance(e1):t instanceof as?$v(e1,t.path,n1):(g=e1,y=n1,g=Jv(f.x,f.y,f.width,f.height,e1.x,e1.y,Qv),y.set(Qv[0],Qv[1]),g);g<l&&(l=g,e1.transform(h),n1.transform(h),n1.toArray(r[0]),e1.toArray(r[1]),t1.toArray(r[2]))}l1(r,e.get("minTurnAngle")),n.setShape({points:r})}}var g,y}var a1=[],s1=new bi;function l1(t,e){var n,i;e<=180&&0<e&&(e=e/180*Math.PI,t1.fromArray(t[0]),e1.fromArray(t[1]),n1.fromArray(t[2]),bi.sub(i1,t1,e1),bi.sub(o1,n1,e1),n=i1.len(),i=o1.len(),n<.001||i<.001||(i1.scale(1/n),o1.scale(1/i),i=i1.dot(o1),Math.cos(e)<i&&(i=Kv(e1.x,e1.y,n1.x,n1.y,t1.x,t1.y,a1,!1),s1.fromArray(a1),s1.scaleAndAdd(o1,i/Math.tan(Math.PI-e)),e=n1.x!==e1.x?(s1.x-e1.x)/(n1.x-e1.x):(s1.y-e1.y)/(n1.y-e1.y),isNaN(e)||(e<0?bi.copy(s1,e1):1<e&&bi.copy(s1,n1),s1.toArray(t[1])))))}function u1(t,e,n,i){var o="normal"===n,n=o?t:t.ensureState(n);n.ignore=e;e=i.get("smooth");e&&!0===e&&(e=.3),n.shape=n.shape||{},0<e&&(n.shape.smooth=e);i=i.getModel("lineStyle").getLineStyle();o?t.useStyle(i):n.style=i}function h1(t,e){var n=e.smooth,i=e.points;if(i)if(t.moveTo(i[0][0],i[0][1]),0<n&&3<=i.length){var o=Ot(i[0],i[1]),e=Ot(i[1],i[2]);if(!o||!e)return t.lineTo(i[1][0],i[1][1]),void t.lineTo(i[2][0],i[2][1]);n=Math.min(o,e)*n,o=Nt([],i[1],i[0],n/o),n=Nt([],i[1],i[2],n/e),e=Nt([],o,n,.5);t.bezierCurveTo(o[0],o[1],o[0],o[1],e[0],e[1]),t.bezierCurveTo(n[0],n[1],n[0],n[1],i[2][0],i[2][1])}else for(var r=1;r<i.length;r++)t.lineTo(i[r][0],i[r][1])}function c1(t,e,n){var i=t.getTextGuideLine(),o=t.getTextContent();if(o){for(var r=e.normal,a=r.get("show"),s=o.ignore,l=0;l<qs.length;l++){var u,h=qs[l],c=e[h],p="normal"===h;c&&(u=c.get("show"),!(p?s:rt(o.states[h]&&o.states[h].ignore,s))&&rt(u,a)?(i||(i=new ny,t.setTextGuideLine(i),p||!s&&a||u1(i,!0,"normal",e.normal),t.stateProxy&&(i.stateProxy=t.stateProxy)),u1(i,!1,h,c)):(p=p?i:i&&i.states.normal)&&(p.ignore=!0))}i&&(z(i.style,n),i.style.fill=null,r=r.get("showAbove"),(t.textGuideLineConfig=t.textGuideLineConfig||{}).showAbove=r||!1,i.buildPath=h1)}else i&&t.removeTextGuideLine()}function p1(t,e){for(var n={normal:t.getModel(e=e||"labelLine")},i=0;i<js.length;i++){var o=js[i];n[o]=t.getModel([o,e])}return n}function d1(t){for(var e=[],n=0;n<t.length;n++){var i,o,r,a,s,l,u=t[n];u.defaultAttr.ignore||(o=(i=u.label).getComputedTransform(),r=i.getBoundingRect(),a=!o||o[1]<1e-5&&o[2]<1e-5,l=i.style.margin||0,(s=r.clone()).applyTransform(o),s.x-=l/2,s.y-=l/2,s.width+=l,s.height+=l,l=a?new _y(r,o):null,e.push({label:i,labelLine:u.labelLine,rect:s,localRect:r,obb:l,priority:u.priority,defaultAttr:u.defaultAttr,layoutOption:u.computedLayoutOption,axisAligned:a,transform:o}))}return e}function f1(l,u,h,t,e,n){var c=l.length;if(!(c<2)){l.sort(function(t,e){return t.rect[u]-e.rect[u]});for(var i=0,r=!1,o=[],a=0,s=0;s<c;s++){var p=l[s],d=p.rect;(f=d[u]-i)<0&&(d[u]-=f,p.label[u]-=f,r=!0);var f=Math.max(-f,0);o.push(f),a+=f,i=d[u]+d[h]}0<a&&n&&b(-a/c,0,c);var g,y,m=l[0],v=l[c-1];return x(),g<0&&w(-g,.8),y<0&&w(y,.8),x(),_(g,y,1),_(y,g,-1),x(),g<0&&S(-g),y<0&&S(y),r}function x(){g=m.rect[u]-t,y=e-v.rect[u]-v.rect[h]}function _(t,e,n){t<0&&(0<(e=Math.min(e,-t))?(b(e*n,0,c),(e=e+t)<0&&w(-e*n,1)):w(-t*n,1))}function b(t,e,n){0!==t&&(r=!0);for(var i=e;i<n;i++){var o=l[i];o.rect[u]+=t,o.label[u]+=t}}function w(t,e){for(var n=[],i=0,o=1;o<c;o++){var r=l[o-1].rect,r=Math.max(l[o].rect[u]-r[u]-r[h],0);n.push(r),i+=r}if(i){var a=Math.min(Math.abs(t)/i,e);if(0<t)for(o=0;o<c-1;o++){var s=n[o]*a;b(s,0,o+1)}else for(o=c-1;0<o;o--)b(-(s=n[o-1]*a),o,c)}}function S(t){var e=t<0?-1:1;t=Math.abs(t);for(var n=Math.ceil(t/(c-1)),i=0;i<c-1;i++)if(0<e?b(n,0,i+1):b(-n,c-i-1,c),(t-=n)<=0)return}}function g1(t,e,n,i){return f1(t,"y","height",e,n,i)}function y1(t){var e=[];t.sort(function(t,e){return e.priority-t.priority});var n=new ki(0,0,0,0);function i(t){var e;t.ignore||null==(e=t.ensureState("emphasis")).ignore&&(e.ignore=!1),t.ignore=!0}for(var o=0;o<t.length;o++){var r=t[o],a=r.axisAligned,s=r.localRect,l=r.transform,u=r.label,h=r.labelLine;n.copy(r.rect),n.width-=.1,n.height-=.1,n.x+=.05,n.y+=.05;for(var c=r.obb,p=!1,d=0;d<e.length;d++){var f=e[d];if(n.intersect(f.rect)){if(a&&f.axisAligned){p=!0;break}if(f.obb||(f.obb=new _y(f.localRect,f.transform)),(c=c||new _y(s,l)).intersect(f.obb)){p=!0;break}}}p?(i(u),h&&i(h)):(u.attr("ignore",r.defaultAttr.ignore),h&&h.attr("ignore",r.defaultAttr.labelGuideIgnore),e.push(r))}}function m1(t,e){var n=t.label,e=e&&e.getTextGuideLine();return{dataIndex:t.dataIndex,dataType:t.dataType,seriesIndex:t.seriesModel.seriesIndex,text:t.label.style.text,rect:t.hostRect,labelRect:t.rect,align:n.style.align,verticalAlign:n.style.verticalAlign,labelLinePoints:function(t){if(t){for(var e=[],n=0;n<t.length;n++)e.push(t[n].slice());return e}}(e&&e.shape.points)}}var v1=["align","verticalAlign","width","height","fontSize"],x1=new _i,_1=Zo(),b1=Zo();function w1(t,e,n){for(var i=0;i<n.length;i++){var o=n[i];null!=e[o]&&(t[o]=e[o])}}var S1=["x","y","rotation"],M1=(T1.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},T1.prototype._addLabel=function(t,e,n,i,o){var r=i.style,a=i.__hostTarget.textConfig||{},s=i.getComputedTransform(),l=i.getBoundingRect().plain();ki.applyTransform(l,l,s),s?x1.setLocalTransform(s):(x1.x=x1.y=x1.rotation=x1.originX=x1.originY=0,x1.scaleX=x1.scaleY=1);var u,h=i.__hostTarget;h&&(u=h.getBoundingRect().plain(),s=h.getComputedTransform(),ki.applyTransform(u,u,s));h=u&&h.getTextGuideLine();this._labelList.push({label:i,labelLine:h,seriesModel:n,dataIndex:t,dataType:e,layoutOption:o,computedLayoutOption:null,rect:l,hostRect:u,priority:u?u.width*u.height:0,defaultAttr:{ignore:i.ignore,labelGuideIgnore:h&&h.ignore,x:x1.x,y:x1.y,scaleX:x1.scaleX,scaleY:x1.scaleY,rotation:x1.rotation,style:{x:r.x,y:r.y,align:r.align,verticalAlign:r.verticalAlign,width:r.width,height:r.height,fontSize:r.fontSize},cursor:i.cursor,attachedPos:a.position,attachedRot:a.rotation}})},T1.prototype.addLabelsOfSeries=function(t){var n=this;this._chartViewList.push(t);var i=t.__model,o=i.get("labelLayout");(q(o)||Y(o).length)&&t.group.traverse(function(t){if(t.ignore)return!0;var e=t.getTextContent(),t=Gs(t);e&&!e.disableLabelLayout&&n._addLabel(t.dataIndex,t.dataType,i,e,o)})},T1.prototype.updateLayoutConfig=function(t){var e=t.getWidth(),n=t.getHeight();for(var i=0;i<this._labelList.length;i++){var o=this._labelList[i],r=o.label,a=r.__hostTarget,s=o.defaultAttr,l="function"==typeof o.layoutOption?o.layoutOption(m1(o,a)):o.layoutOption;o.computedLayoutOption=l=l||{};var u=Math.PI/180;a&&a.setTextConfig({local:!1,position:null!=l.x||null!=l.y?null:s.attachedPos,rotation:null!=l.rotate?l.rotate*u:s.attachedRot,offset:[l.dx||0,l.dy||0]});var h,c=!1;null!=l.x?(r.x=go(l.x,e),r.setStyle("x",0),c=!0):(r.x=s.x,r.setStyle("x",s.style.x)),null!=l.y?(r.y=go(l.y,n),r.setStyle("y",0),c=!0):(r.y=s.y,r.setStyle("y",s.style.y)),l.labelLinePoints&&(h=a.getTextGuideLine())&&(h.setShape({points:l.labelLinePoints}),c=!1),_1(r).needsUpdateLabelLine=c,r.rotation=null!=l.rotate?l.rotate*u:s.rotation,r.scaleX=s.scaleX,r.scaleY=s.scaleY;for(var p=0;p<v1.length;p++){var d=v1[p];r.setStyle(d,(null!=l[d]?l:s.style)[d])}l.draggable?(r.draggable=!0,r.cursor="move",a&&(u=o.seriesModel,null!=o.dataIndex&&(u=o.seriesModel.getData(o.dataType).getItemModel(o.dataIndex)),r.on("drag",function(t,e){return function(){r1(t,e)}}(a,u.getModel("labelLine"))))):(r.off("drag"),r.cursor=s.cursor)}},T1.prototype.layout=function(t){var e,n=t.getWidth(),i=t.getHeight(),o=d1(this._labelList),r=U(o,function(t){return"shiftX"===t.layoutOption.moveOverlap}),t=U(o,function(t){return"shiftY"===t.layoutOption.moveOverlap});f1(r,"x","width",0,n,e),g1(t,0,i),y1(U(o,function(t){return t.layoutOption.hideOverlap}))},T1.prototype.processLabelsOverall=function(){var a=this;G(this._chartViewList,function(t){var i=t.__model,o=t.ignoreLabelLineUpdate,r=i.isAnimationEnabled();t.group.traverse(function(t){if(t.ignore&&!t.forceLabelAnimation)return!0;var e=!o,n=t.getTextContent();(e=!e&&n?_1(n).needsUpdateLabelLine:e)&&a._updateLabelLine(t,i),r&&a._animateLabels(t,i)})})},T1.prototype._updateLabelLine=function(t,e){var n=t.getTextContent(),i=Gs(t),o=i.dataIndex;n&&null!=o&&(e=(n=e.getData(i.dataType)).getItemModel(o),i={},o=n.getItemVisual(o,"style"),n=n.getVisual("drawType"),i.stroke=o[n],n=e.getModel("labelLine"),c1(t,p1(e),i),r1(t,n))},T1.prototype._animateLabels=function(t,e){var n,i,o,r,a,s,l,u=t.getTextContent(),h=t.getTextGuideLine();!u||!t.forceLabelAnimation&&(u.ignore||u.invisible||t.disableLabelAnimation||Yl(t))||(s=(a=_1(u)).oldLayout,n=(l=Gs(t)).dataIndex,i={x:u.x,y:u.y,rotation:u.rotation},l=e.getData(l.dataType),s?(u.attr(s),(o=t.prevStates)&&(0<=V(o,"select")&&u.attr(a.oldLayoutSelect),0<=V(o,"emphasis")&&u.attr(a.oldLayoutEmphasis)),Wl(u,i,e,n)):(u.attr(i),lu(u).valueAnimation||(o=rt(u.style.opacity,1),u.style.opacity=0,Ul(u,{style:{opacity:o}},e,n))),a.oldLayout=i,u.states.select&&(w1(r=a.oldLayoutSelect={},i,S1),w1(r,u.states.select,S1)),u.states.emphasis&&(w1(r=a.oldLayoutEmphasis={},i,S1),w1(r,u.states.emphasis,S1)),hu(u,n,l,e,e)),!h||h.ignore||h.invisible||(s=(a=b1(h)).oldLayout,l={points:h.shape.points},s?(h.attr({shape:s}),Wl(h,{shape:l},e)):(h.setShape(l),h.style.strokePercent=0,Ul(h,{style:{strokePercent:1}},e)),a.oldLayout=l)},T1),I1=Zo();function T1(){this._labelList=[],this._chartViewList=[]}function C1(t){t.registerUpdateLifecycle("series:beforeupdate",function(t,e,n){(I1(e).labelManager||(I1(e).labelManager=new M1)).clearLabels()}),t.registerUpdateLifecycle("series:layoutlabels",function(t,e,n){var i=I1(e).labelManager;n.updatedSeries.forEach(function(t){i.addLabelsOfSeries(e.getViewOfSeriesModel(t))}),i.updateLayoutConfig(e),i.layout(e),i.processLabelsOverall()})}function D1(){return!1}function A1(t,e,n){var i=E(),o=e.getWidth(),r=e.getHeight(),e=i.style;return e&&(e.position="absolute",e.left="0",e.top="0",e.width=o+"px",e.height=r+"px",i.setAttribute("data-zr-dom-id",t)),i.width=o*n,i.height=r*n,i}Xv(C1);var k1,L1=(wt(O1,k1=Gt),O1.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},O1.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},O1.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},O1.prototype.setUnpainted=function(){this.__firstTimePaint=!0},O1.prototype.createBackBuffer=function(){var t=this.dpr;this.domBack=A1("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!==t&&this.ctxBack.scale(t,t)},O1.prototype.createRepaintRects=function(t,e,n,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o,l=[],u=this.maxRepaintRectCount,h=!1,c=new ki(0,0,0,0);function r(t){if(t.isFinite()&&!t.isZero())if(0===l.length){var e=new ki(0,0,0,0);e.copy(t),l.push(e)}else{for(var n=!1,i=1/0,o=0,r=0;r<l.length;++r){var a=l[r];if(a.intersect(t)){var s=new ki(0,0,0,0);s.copy(a),s.union(t),l[r]=s,n=!0;break}h&&(c.copy(t),c.union(a),s=t.width*t.height,a=a.width*a.height,(a=c.width*c.height-s-a)<i&&(i=a,o=r))}h&&(l[o].union(t),n=!0),n||((e=new ki(0,0,0,0)).copy(t),l.push(e)),h=h||l.length>=u}}for(var a=this.__startIndex;a<this.__endIndex;++a){var s,p,d,f=t[a];f&&(s=f.shouldBePainted(n,i,!0,!0),(p=f.__isRendered&&(f.__dirty&ke||!s)?f.getPrevPaintRect():null)&&r(p),(d=s&&(f.__dirty&ke||!f.__isRendered)?f.getPaintRect():null)&&r(d))}for(a=this.__prevStartIndex;a<this.__prevEndIndex;++a)s=(f=e[a]).shouldBePainted(n,i,!0,!0),!f||s&&f.__zr||!f.__isRendered||(p=f.getPrevPaintRect())&&r(p);do{for(o=!1,a=0;a<l.length;)if(l[a].isZero())l.splice(a,1);else{for(var g=a+1;g<l.length;)l[a].intersect(l[g])?(o=!0,l[a].union(l[g]),l.splice(g,1)):g++;a++}}while(o);return this._paintRects=l},O1.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},O1.prototype.resize=function(t,e){var n=this.dpr,i=this.dom,o=i.style,r=this.domBack;o&&(o.width=t+"px",o.height=e+"px"),i.width=t*n,i.height=e*n,r&&(r.width=t*n,r.height=e*n,1!==n&&this.ctxBack.scale(n,n))},O1.prototype.clear=function(t,r,e){var n=this.dom,a=this.ctx,i=n.width,o=n.height;r=r||this.clearColor;var s=this.motionBlur&&!t,l=this.lastFrameAlpha,u=this.dpr,h=this;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(n,0,0,i/u,o/u));var c=this.domBack;function p(t,e,n,i){var o;a.clearRect(t,e,n,i),r&&"transparent"!==r&&(o=void 0,null!=r.colorStops?(o=r.__canvasGradient||um(a,r,{x:0,y:0,width:n,height:i}),r.__canvasGradient=o):null!=r.image&&(o=vm(a,r,{dirty:function(){h.setUnpainted(),h.__painter.refresh()}})),a.save(),a.fillStyle=o||r,a.fillRect(t,e,n,i),a.restore()),s&&(a.save(),a.globalAlpha=l,a.drawImage(c,t,e,n,i),a.restore())}!e||s?p(0,0,i,o):e.length&&G(e,function(t){p(t.x*u,t.y*u,t.width*u,t.height*u)})},O1),P1=314159;function O1(t,e,n){var i,o=k1.call(this)||this;o.motionBlur=!1,o.lastFrameAlpha=.7,o.dpr=1,o.virtual=!1,o.config={},o.incremental=!1,o.zlevel=0,o.maxRepaintRectCount=5,o.__dirty=!0,o.__firstTimePaint=!0,o.__used=!1,o.__drawIndex=0,o.__startIndex=0,o.__endIndex=0,o.__prevStartIndex=null,o.__prevEndIndex=null,n=n||$n,"string"==typeof t?i=A1(t,e,n):$(t)&&(t=(i=t).id),o.id=t;t=(o.dom=i).style;return t&&(i.onselectstart=D1,t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none",t.padding="0",t.margin="0",t.borderWidth="0"),o.domBack=null,o.ctxBack=null,o.painter=e,o.config=null,o.dpr=n,o}function R1(t){return parseInt(t,10)}var N1=(z1.prototype.getType=function(){return"canvas"},z1.prototype.isSingleCanvas=function(){return this._singleCanvas},z1.prototype.getViewportRoot=function(){return this._domRoot},z1.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},z1.prototype.refresh=function(t){var e=this.storage.getDisplayList(!0),n=this._prevDisplayList,i=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,n,t,this._redrawId);for(var o=0;o<i.length;o++){var r=i[o],a=this._layers[r];!a.__builtin__&&a.refresh&&(r=0===o?this._backgroundColor:null,a.refresh(r))}return this._opts.useDirtyRect&&(this._prevDisplayList=e.slice()),this},z1.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},z1.prototype._paintHoverList=function(t){var e=t.length,n=this._hoverlayer;if(n&&n.clear(),e){for(var i,o={inHover:!0,viewWidth:this._width,viewHeight:this._height},r=0;r<e;r++){var a=t[r];a.__inHover&&(n=n||(this._hoverlayer=this.getLayer(1e5)),i||(i=n.ctx).save(),Lm(i,a,o,r===e-1))}i&&i.restore()}},z1.prototype.getHoverLayer=function(){return this.getLayer(1e5)},z1.prototype.paintOne=function(t,e){km(t,e)},z1.prototype._paintList=function(t,e,n,i){var o,r,a;this._redrawId===i&&(n=n||!1,this._updateLayerStatus(t),o=(r=this._doPaintList(t,e,n)).finished,r=r.needsRefreshHover,this._needsManuallyCompositing&&this._compositeManually(),r&&this._paintHoverList(t),o?this.eachLayer(function(t){t.afterBrush&&t.afterBrush()}):(a=this,ze(function(){a._paintList(t,e,n,i)})))},z1.prototype._compositeManually=function(){var e=this.getLayer(P1).ctx,n=this._domRoot.width,i=this._domRoot.height;e.clearRect(0,0,n,i),this.eachBuiltinLayer(function(t){t.virtual&&e.drawImage(t.dom,0,0,n,i)})},z1.prototype._doPaintList=function(d,f,g){for(var y=this,m=[],v=this._opts.useDirtyRect,t=0;t<this._zlevelList.length;t++){var e=this._zlevelList[t],e=this._layers[e];e.__builtin__&&e!==this._hoverlayer&&(e.__dirty||g)&&m.push(e)}for(var x=!0,_=!1,b=this,n=0;n<m.length;n++)!function(t){var i,o=m[t],r=o.ctx,e=v&&o.createRepaintRects(d,f,b._width,b._height),a=g?o.__startIndex:o.__drawIndex,s=!g&&o.incremental&&Date.now,l=s&&Date.now(),n=o.zlevel===b._zlevelList[0]?b._backgroundColor:null;o.__startIndex===o.__endIndex?o.clear(!1,n,e):a===o.__startIndex&&((t=d[a]).incremental&&t.notClear&&!g||o.clear(!1,n,e)),-1===a&&(a=o.__startIndex);function u(t){var e={inHover:!1,allClipped:!1,prevEl:null,viewWidth:y._width,viewHeight:y._height};for(i=a;i<o.__endIndex;i++){var n=d[i];if(n.__inHover&&(_=!0),y._doPaintEl(n,o,v,t,e,i===o.__endIndex-1),s)if(15<Date.now()-l)break}e.prevElClipPaths&&r.restore()}if(e)if(0===e.length)i=o.__endIndex;else for(var h=b.dpr,c=0;c<e.length;++c){var p=e[c];r.save(),r.beginPath(),r.rect(p.x*h,p.y*h,p.width*h,p.height*h),r.clip(),u(p),r.restore()}else r.save(),u(),r.restore();o.__drawIndex=i,o.__drawIndex<o.__endIndex&&(x=!1)}(n);return w.wxa&&G(this._layers,function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()}),{finished:x,needsRefreshHover:_}},z1.prototype._doPaintEl=function(t,e,n,i,o,r){e=e.ctx;n?(n=t.getPaintRect(),(!i||n&&n.intersect(i))&&(Lm(e,t,o,r),t.setPrevPaintRect(n))):Lm(e,t,o,r)},z1.prototype.getLayer=function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=P1);var n=this._layers[t];return n||((n=new L1("zr_"+t,this,this.dpr)).zlevel=t,n.__builtin__=!0,this._layerConfig[t]?O(n,this._layerConfig[t],!0):this._layerConfig[t-.01]&&O(n,this._layerConfig[t-.01],!0),e&&(n.virtual=e),this.insertLayer(t,n),n.initContext()),n},z1.prototype.insertLayer=function(t,e){var n,i=this._layers,o=this._zlevelList,r=o.length,a=this._domRoot,s=null,l=-1;if(i[t])L("ZLevel "+t+" has been used already");else if((n=e)&&(n.__builtin__||"function"==typeof n.resize&&"function"==typeof n.refresh)){if(0<r&&t>o[0]){for(l=0;l<r-1&&!(o[l]<t&&o[l+1]>t);l++);s=i[o[l]]}o.splice(l+1,0,t),(i[t]=e).virtual||(s?(s=s.dom).nextSibling?a.insertBefore(e.dom,s.nextSibling):a.appendChild(e.dom):a.firstChild?a.insertBefore(e.dom,a.firstChild):a.appendChild(e.dom)),e.__painter=this}else L("Layer of zlevel "+t+" is not valid")},z1.prototype.eachLayer=function(t,e){for(var n=this._zlevelList,i=0;i<n.length;i++){var o=n[i];t.call(e,this._layers[o],o)}},z1.prototype.eachBuiltinLayer=function(t,e){for(var n=this._zlevelList,i=0;i<n.length;i++){var o=n[i],r=this._layers[o];r.__builtin__&&t.call(e,r,o)}},z1.prototype.eachOtherLayer=function(t,e){for(var n=this._zlevelList,i=0;i<n.length;i++){var o=n[i],r=this._layers[o];r.__builtin__||t.call(e,r,o)}},z1.prototype.getLayers=function(){return this._layers},z1.prototype._updateLayerStatus=function(t){function e(t){r&&(r.__endIndex!==t&&(r.__dirty=!0),r.__endIndex=t)}if(this.eachBuiltinLayer(function(t,e){t.__dirty=t.__used=!1}),this._singleCanvas)for(var n=1;n<t.length;n++){var i=t[n];if(i.zlevel!==t[n-1].zlevel||i.incremental){this._needsManuallyCompositing=!0;break}}for(var o,r=null,a=0,s=0;s<t.length;s++){var l=(i=t[s]).zlevel,u=void 0;o!==l&&(o=l,a=0),i.incremental?((u=this.getLayer(l+.001,this._needsManuallyCompositing)).incremental=!0,a=1):u=this.getLayer(l+(0<a?.01:0),this._needsManuallyCompositing),u.__builtin__||L("ZLevel "+l+" has been used by unkown layer "+u.id),u!==r&&(u.__used=!0,u.__startIndex!==s&&(u.__dirty=!0),u.__startIndex=s,u.incremental?u.__drawIndex=-1:u.__drawIndex=s,e(s),r=u),i.__dirty&ke&&!i.__inHover&&(u.__dirty=!0,u.incremental&&u.__drawIndex<0&&(u.__drawIndex=s))}e(s),this.eachBuiltinLayer(function(t,e){!t.__used&&0<t.getElementCount()&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},z1.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},z1.prototype._clearLayer=function(t){t.clear()},z1.prototype.setBackgroundColor=function(t){this._backgroundColor=t,G(this._layers,function(t){t.setUnpainted()})},z1.prototype.configLayer=function(t,e){if(e){var n=this._layerConfig;n[t]?O(n[t],e,!0):n[t]=e;for(var i=0;i<this._zlevelList.length;i++){var o=this._zlevelList[i];o!==t&&o!==t+.01||O(this._layers[o],n[t],!0)}}},z1.prototype.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(V(n,t),1))},z1.prototype.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){for(var o in n.style.width=t+"px",n.style.height=e+"px",this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].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(P1).resize(t,e)}return this},z1.prototype.clearLayer=function(t){t=this._layers[t];t&&t.clear()},z1.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},z1.prototype.getRenderedCanvas=function(t){if(this._singleCanvas&&!this._compositeManually)return this._layers[P1].dom;var e=new L1("image",this,(t=t||{}).pixelRatio||this.dpr);e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor);var n=e.ctx;if(t.pixelRatio<=this.dpr){this.refresh();var i=e.dom.width,o=e.dom.height;this.eachLayer(function(t){t.__builtin__?n.drawImage(t.dom,0,0,i,o):t.renderToCanvas&&(n.save(),t.renderToCanvas(n),n.restore())})}else for(var r={inHover:!1,viewWidth:this._width,viewHeight:this._height},a=this.storage.getDisplayList(!0),s=0,l=a.length;s<l;s++){var u=a[s];Lm(n,u,r,s===l-1)}return e.dom},z1.prototype.getWidth=function(){return this._width},z1.prototype.getHeight=function(){return this._height},z1.prototype._getSize=function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],o=["paddingLeft","paddingTop"][t],r=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);t=this.root,e=document.defaultView.getComputedStyle(t);return(t[i]||R1(e[n])||R1(t.style[n]))-(R1(e[o])||0)-(R1(e[r])||0)|0},z1.prototype.pathToImage=function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),o=t.getBoundingRect(),r=t.style,a=r.shadowBlur*e,s=r.shadowOffsetX*e,l=r.shadowOffsetY*e,u=t.hasStroke()?r.lineWidth:0,h=Math.max(u/2,a-s),r=Math.max(u/2,s+a),s=Math.max(u/2,a-l),a=Math.max(u/2,l+a),r=o.width+h+r,a=o.height+s+a;n.width=r*e,n.height=a*e,i.scale(e,e),i.clearRect(0,0,r,a),i.dpr=e;e={x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY,rotation:t.rotation,originX:t.originX,originY:t.originY};t.x=h-o.x,t.y=s-o.y,t.rotation=0,t.scaleX=1,t.scaleY=1,t.updateTransform(),t&&Lm(i,t,{inHover:!1,viewWidth:this._width,viewHeight:this._height},!0);n=new ys({style:{x:0,y:0,image:n}});return N(t,e),n},z1);function z1(t,e,n,i){this.type="canvas",this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas";var o=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=n=N({},n||{}),this.dpr=n.devicePixelRatio||$n,this._singleCanvas=o;var r=(this.root=t).style;r&&(r.webkitTapHighlightColor="transparent",r.webkitUserSelect="none",r.userSelect="none",r["-webkit-touch-callout"]="none",t.innerHTML=""),this.storage=e;var a=this._zlevelList;this._prevDisplayList=[];var s,r=this._layers;o?(e=(s=t).width,o=s.height,null!=n.width&&(e=n.width),null!=n.height&&(o=n.height),this.dpr=n.devicePixelRatio||1,s.width=e*this.dpr,s.height=o*this.dpr,this._width=e,this._height=o,(s=new L1(s,this,this.dpr)).__builtin__=!0,s.initContext(),(r[P1]=s).zlevel=P1,a.push(P1),this._domRoot=t):(this._width=this._getSize(0),this._height=this._getSize(1),a=this._domRoot=(r=this._width,s=this._height,(a=document.createElement("div")).style.cssText=["position:relative","width:"+r+"px","height:"+s+"px","padding:0","margin:0","border-width:0"].join(";")+";",a),t.appendChild(a))}function E1(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function V1(t){var e,n;return t&&"transparent"!==t?"string"==typeof t&&-1<t.indexOf("rgba")&&((n=rn(t))&&(t="rgb("+n[0]+","+n[1]+","+n[2]+")",e=n[3])):t="none",{color:t,opacity:null==e?1:e}}function B1(s,l,u){u=u||function(t,e){return t===e},s=s.slice();var h=(l=l.slice()).length,c=s.length,p=1,t=h+c,d=[{newPos:-1,components:[]}],e=F1(d[0],l,s,0,u);if(d[0].newPos+1>=h&&c<=e+1){for(var n=[],i=0;i<l.length;i++)n.push(i);return[{indices:n,count:l.length,added:!1,removed:!1}]}function o(){for(var t=-1*p;t<=p;t+=2){var e,n=d[t-1],i=d[t+1],o=(i?i.newPos:0)-t;n&&(d[t-1]=void 0);var r=n&&n.newPos+1<h,a=i&&0<=o&&o<c;if(r||a){if(!r||a&&n.newPos<i.newPos?G1((e={newPos:i.newPos,components:i.components.slice(0)}).components,!1,!0):((e=n).newPos++,G1(e.components,!0,!1)),o=F1(e,l,s,t,u),e.newPos+1>=h&&c<=o+1)return function(t){for(var e=0,n=t.length,i=0,o=0;e<n;e++){var r=t[e];if(r.removed){for(s=o;s<o+r.count;s++)r.indices.push(s);o+=r.count}else{for(var a=[],s=i;s<i+r.count;s++)a.push(s);r.indices=a,i+=r.count,r.added||(o+=r.count)}}return t}(e.components);d[t]=e}else d[t]=void 0}p++}for(;p<=t;){var r=o();if(r)return r}}function F1(t,e,n,i,o){for(var r=e.length,a=n.length,s=t.newPos,l=s-i,u=0;s+1<r&&l+1<a&&o(e[s+1],n[l+1]);)s++,l++,u++;return u&&t.components.push({count:u,added:!1,removed:!1,indices:[]}),t.newPos=s,l}function G1(t,e,n){var i=t[t.length-1];i&&i.added===e&&i.removed===n?t[t.length-1]={count:i.count+1,added:e,removed:n,indices:[]}:t.push({count:1,added:e,removed:n,indices:[]})}var H1="none",W1=Math.round,U1=Math.sin,Y1=Math.cos,X1=Math.PI,Z1=2*Math.PI,j1=180/X1;function q1(t){return W1(1e3*t)/1e3}function K1(t){return W1(1e4*t)/1e4}function J1(t){return t<1e-4&&-1e-4<t}function Q1(t,e){e&&$1(t,"transform","matrix("+q1(e[0])+","+q1(e[1])+","+q1(e[2])+","+q1(e[3])+","+K1(e[4])+","+K1(e[5])+")")}function $1(t,e,n){n&&("linear"===n.type||"radial"===n.type)||t.setAttribute(e,n)}function tx(t,e,n){var i,o,r,a=null==e.opacity?1:e.opacity;n instanceof ys?$1(t,"opacity",a+""):(null!=(r=(r=e).fill)&&r!==H1?($1(t,"fill",(i=V1(e.fill)).color),$1(t,"fill-opacity",(null!=e.fillOpacity?e.fillOpacity*i.opacity*a:i.opacity*a)+"")):$1(t,"fill",H1),null!=(r=(r=e).stroke)&&r!==H1?($1(t,"stroke",(i=V1(e.stroke)).color),r=e.lineWidth,$1(t,"stroke-width",((o=e.strokeNoScale?n.getLineScale():1)?r/o:0)+""),$1(t,"paint-order",e.strokeFirst?"stroke":"fill"),$1(t,"stroke-opacity",(null!=e.strokeOpacity?e.strokeOpacity*i.opacity*a:i.opacity*a)+""),(a=e.lineDash&&0<r&&cm(e.lineDash,r))?(r=e.lineDashOffset,o&&1!==o&&(a=H(a,function(t){return t/o}),r&&(r=W1(r/=o))),$1(t,"stroke-dasharray",a.join(",")),$1(t,"stroke-dashoffset",(r||0)+"")):$1(t,"stroke-dasharray",H1),e.lineCap&&$1(t,"stroke-linecap",e.lineCap),e.lineJoin&&$1(t,"stroke-linejoin",e.lineJoin),e.miterLimit&&$1(t,"stroke-miterlimit",e.miterLimit+"")):$1(t,"stroke",H1))}var ex=(rx.prototype.reset=function(){this._d=[],this._str=""},rx.prototype.moveTo=function(t,e){this._add("M",t,e)},rx.prototype.lineTo=function(t,e){this._add("L",t,e)},rx.prototype.bezierCurveTo=function(t,e,n,i,o,r){this._add("C",t,e,n,i,o,r)},rx.prototype.quadraticCurveTo=function(t,e,n,i){this._add("Q",t,e,n,i)},rx.prototype.arc=function(t,e,n,i,o,r){this.ellipse(t,e,n,n,0,i,o,r)},rx.prototype.ellipse=function(t,e,n,i,o,r,a,s){var l=0===this._d.length,u=a-r,h=!s,c=Math.abs(u),p=J1(c-Z1)||(h?Z1<=u:Z1<=-u),a=!1,a=!!p||!J1(c)&&X1<=(0<u?u%Z1:u%Z1+Z1)==!!h,s=K1(t+n*Y1(r)),c=K1(e+i*U1(r));p&&(u=h?Z1-1e-4:1e-4-Z1,a=!0,l&&this._d.push("M",s,c));t=K1(t+n*Y1(r+u)),u=K1(e+i*U1(r+u));if(isNaN(s)||isNaN(c)||isNaN(n)||isNaN(i)||isNaN(o)||isNaN(j1)||isNaN(t)||isNaN(u))return"";this._d.push("A",K1(n),K1(i),W1(o*j1),+a,+h,t,u)},rx.prototype.rect=function(t,e,n,i){this._add("M",t,e),this._add("L",t+n,e),this._add("L",t+n,e+i),this._add("L",t,e+i),this._add("L",t,e),this._add("Z")},rx.prototype.closePath=function(){0<this._d.length&&this._add("Z")},rx.prototype._add=function(t,e,n,i,o,r,a,s,l){this._d.push(t);for(var u=1;u<arguments.length;u++){var h=arguments[u];if(isNaN(h))return void(this._invalid=!0);this._d.push(K1(h))}},rx.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(" "),this._d=[]},rx.prototype.getStr=function(){return this._str},rx),nx={brush:function(t){var e=t.style,n=t.__svgEl;n||(n=E1("path"),t.__svgEl=n),t.path||t.createPathProxy();var i=t.path;t.shapeChanged()&&(i.beginPath(),t.buildPath(i,t.shape),t.pathUpdated());var o=i.getVersion(),r=t,a=r.__svgPathBuilder;(r.__svgPathVersion!==o||!a||t.style.strokePercent<1)&&((a=a||(r.__svgPathBuilder=new ex)).reset(),i.rebuildPath(a,t.style.strokePercent),a.generateStr(),r.__svgPathVersion=o),$1(n,"d",a.getStr()),tx(n,e,t),Q1(n,t.transform)}},ix={brush:function(t){var e,n,i,o,r,a,s,l=t.style,u=l.image;u instanceof HTMLImageElement?u=u.src:u instanceof HTMLCanvasElement&&(u=u.toDataURL()),u&&(e=l.x||0,n=l.y||0,i=l.width,o=l.height,(r=t.__svgEl)||(r=E1("image"),t.__svgEl=r),u!==t.__imageSrc&&(a="href",s=u,r.setAttributeNS("http://www.w3.org/1999/xlink",a,s),t.__imageSrc=u),$1(r,"width",i+""),$1(r,"height",o+""),$1(r,"x",e+""),$1(r,"y",n+""),tx(r,l,t),Q1(r,t.transform))}},ox={left:"start",right:"end",center:"middle",middle:"middle"};function rx(){}var ax={brush:function(t){var e,n,i,o=t.style,r=o.text;null!=r&&(r+=""),!r||isNaN(o.x)||isNaN(o.y)||((e=t.__svgEl)||(e=E1("text"),n="xml:space",i="preserve",e.setAttributeNS("http://www.w3.org/XML/1998/namespace",n,i),t.__svgEl=e),n=o.font||Pi,e.style.font=n,e.textContent=r,tx(e,o,t),Q1(e,t.transform),i=o.x||0,r=o.y||0,t=Hi(n),"top"===(n=o.textBaseline)?r+=t/2:"bottom"===n&&(r-=t/2),r=r,o=ox[o.textAlign]||o.textAlign,$1(e,"dominant-baseline","central"),$1(e,"text-anchor",o),$1(e,"x",i+""),$1(e,"y",r+""))}},gr=(sx.prototype.getDefs=function(t){var e=this._svgRoot,n=this._svgRoot.getElementsByTagName("defs");if(0!==n.length)return n[0];if(t){var i=e.insertBefore(this.createElement("defs"),e.firstChild);return i.contains||(i.contains=function(t){var e=i.children;if(!e)return!1;for(var n=e.length-1;0<=n;--n)if(e[n]===t)return!0;return!1}),i}return null},sx.prototype.doUpdate=function(t,e){var n;t&&(n=this.getDefs(!1),t[this._domName]&&n.contains(t[this._domName])?"function"==typeof e&&e(t):(e=this.add(t))&&(t[this._domName]=e))},sx.prototype.add=function(t){return null},sx.prototype.addDom=function(t){var e=this.getDefs(!0);t.parentNode!==e&&e.appendChild(t)},sx.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},sx.prototype.getDoms=function(){var i=this.getDefs(!1);if(!i)return[];var o=[];return G(this._tagNames,function(t){for(var e=i.getElementsByTagName(t),n=0;n<e.length;n++)o.push(e[n])}),o},sx.prototype.markAllUnused=function(){var t=this.getDoms(),e=this;G(t,function(t){t[e._markLabel]="0"})},sx.prototype.markDomUsed=function(t){t&&(t[this._markLabel]="1")},sx.prototype.markDomUnused=function(t){t&&(t[this._markLabel]="0")},sx.prototype.isDomUnused=function(t){return t&&"1"!==t[this._markLabel]},sx.prototype.removeUnused=function(){var e=this,n=this.getDefs(!1);n&&G(this.getDoms(),function(t){e.isDomUnused(t)&&n.removeChild(t)})},sx.prototype.getSvgProxy=function(t){return t instanceof as?nx:t instanceof ys?ix:t instanceof hs?ax:nx},sx.prototype.getSvgElement=function(t){return t.__svgEl},sx);function sx(t,e,n,i,o){this.nextId=0,this._domName="_dom",this.createElement=E1,this._zrId=t,this._svgRoot=e,this._tagNames="string"==typeof n?[n]:n,this._markLabel=i,o&&(this._domName=o)}function lx(t){return"linear"===t.type}function ux(t){return"radial"===t.type}function hx(t){return t&&("linear"===t.type||"radial"===t.type)}var cx,px=(wt(dx,cx=gr),dx.prototype.addWithoutUpdate=function(o,r){var a;r&&r.style&&(a=this,G(["fill","stroke"],function(t){var e,n,i=r.style[t];hx(i)&&(e=i,n=a.getDefs(!0),i=void 0,e.__dom?(i=e.__dom,n.contains(e.__dom)||a.addDom(i)):i=a.add(e),a.markUsed(r),i=i.getAttribute("id"),o.setAttribute(t,"url(#"+i+")"))}))},dx.prototype.add=function(t){var e;if(lx(t))e=this.createElement("linearGradient");else{if(!ux(t))return L("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},dx.prototype.update=function(n){var i;hx(n)&&(i=this).doUpdate(n,function(){var t,e=n.__dom;e&&(t=e.tagName,"linear"===(e=n.type)&&"linearGradient"===t||"radial"===e&&"radialGradient"===t?i.updateDom(n,n.__dom):(i.removeDom(n),i.add(n)))})},dx.prototype.updateDom=function(t,e){if(lx(t))e.setAttribute("x1",t.x+""),e.setAttribute("y1",t.y+""),e.setAttribute("x2",t.x2+""),e.setAttribute("y2",t.y2+"");else{if(!ux(t))return void L("Illegal gradient type.");e.setAttribute("cx",t.x+""),e.setAttribute("cy",t.y+""),e.setAttribute("r",t.r+"")}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var n=t.colorStops,i=0,o=n.length;i<o;++i){var r=this.createElement("stop");r.setAttribute("offset",100*n[i].offset+"%");var a,s=n[i].color;-1<s.indexOf("rgba")?(a=rn(s)[3],s=ln(s),r.setAttribute("stop-color","#"+s),r.setAttribute("stop-opacity",a+"")):r.setAttribute("stop-color",n[i].color),e.appendChild(r)}t.__dom=e},dx.prototype.markUsed=function(t){var e;t.style&&((e=t.style.fill)&&e.__dom&&cx.prototype.markDomUsed.call(this,e.__dom),(e=t.style.stroke)&&e.__dom&&cx.prototype.markDomUsed.call(this,e.__dom))},dx);function dx(t,e){return cx.call(this,t,e,["linearGradient","radialGradient"],"__gradient_in_use__")||this}function fx(t){return t&&(t.image||t.svgElement)}var gx,yx=new mu,mx=(wt(vx,gx=gr),vx.prototype.addWithoutUpdate=function(o,r){var a;r&&r.style&&(a=this,G(["fill","stroke"],function(t){var e,n,i=r.style[t];fx(i)&&(e=a.getDefs(!0),(n=yx.get(i))?e.contains(n)||a.addDom(n):n=a.add(i),a.markUsed(r),n=n.getAttribute("id"),o.setAttribute(t,"url(#"+n+")"))}))},vx.prototype.add=function(t){if(fx(t)){var e=this.createElement("pattern");return t.id=null==t.id?this.nextId++:t.id,e.setAttribute("id","zr"+this._zrId+"-pattern-"+t.id),e.setAttribute("x","0"),e.setAttribute("y","0"),e.setAttribute("patternUnits","userSpaceOnUse"),this.updateDom(t,e),this.addDom(e),e}},vx.prototype.update=function(e){var n;fx(e)&&(n=this).doUpdate(e,function(){var t=yx.get(e);n.updateDom(e,t)})},vx.prototype.updateDom=function(t,e){var n=t.svgElement;if(n instanceof SVGElement)n.parentNode!==e&&(e.innerHTML="",e.appendChild(n),e.setAttribute("width",t.svgWidth+""),e.setAttribute("height",t.svgHeight+""));else{var i=void 0,o=e.getElementsByTagName("image");if(o.length){if(!t.image)return void e.removeChild(o[0]);i=o[0]}else t.image&&(i=this.createElement("image"));i&&(a=void 0,"string"==typeof(r=t.image)?a=r:r instanceof HTMLImageElement?a=r.src:r instanceof HTMLCanvasElement&&(a=r.toDataURL()),a&&(i.setAttribute("href",a),i.setAttribute("x","0"),i.setAttribute("y","0"),(s=vr(a,i,{dirty:function(){}},function(t){e.setAttribute("width",t.width+""),e.setAttribute("height",t.height+"")}))&&s.width&&s.height&&(e.setAttribute("width",s.width+""),e.setAttribute("height",s.height+"")),e.appendChild(i)))}var o=t.x||0,r=t.y||0,a=(t.rotation||0)/Math.PI*180,s=t.scaleX||1,i=t.scaleY||1;e.setAttribute("patternTransform","translate("+o+", "+r+") rotate("+a+") scale("+s+", "+i+")"),yx.set(t,e)},vx.prototype.markUsed=function(t){t.style&&(fx(t.style.fill)&&gx.prototype.markDomUsed.call(this,yx.get(t.style.fill)),fx(t.style.stroke)&&gx.prototype.markDomUsed.call(this,yx.get(t.style.stroke)))},vx);function vx(t,e){return gx.call(this,t,e,["pattern"],"__pattern_in_use__")||this}function xx(t){t=t.__clipPaths;return t&&0<t.length}var _x,bx,Sx=(wt(Tx,bx=gr),Tx.prototype.markAllUnused=function(){bx.prototype.markAllUnused.call(this);var t,e=this._refGroups;for(t in e)e.hasOwnProperty(t)&&this.markDomUnused(e[t]);this._keyDuplicateCount={}},Tx.prototype._getClipPathGroup=function(t,e){if(xx(t)){var n=t.__clipPaths,i=this._keyDuplicateCount,t=function(t){var e=[];if(t)for(var n=0;n<t.length;n++){var i=t[n];e.push(i.id)}return e.join(",")}(n);return hm(n,e&&e.__clipPaths)&&(i[t]=i[t]||0,i[t]&&(t+="-"+i[t]),i[t]++),this._refGroups[t]||(this._refGroups[t]=this.createElement("g"))}},Tx.prototype.update=function(t,e){e=this._getClipPathGroup(t,e);return e&&(this.markDomUsed(e),this.updateDom(e,t.__clipPaths)),e},Tx.prototype.updateDom=function(t,e){var n,i,o,r;e&&0<e.length?(n=this.getDefs(!0),o=i=void 0,(r=e[0])._dom?(o=r._dom.getAttribute("id"),i=r._dom,n.contains(i)||n.appendChild(i)):(o="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,(i=this.createElement("clipPath")).setAttribute("id",o),n.appendChild(i),r._dom=i),this.getSvgProxy(r).brush(r),r=this.getSvgElement(r),i.innerHTML="",i.appendChild(r),t.setAttribute("clip-path","url(#"+o+")"),1<e.length&&this.updateDom(i,e.slice(1))):t&&t.setAttribute("clip-path","none")},Tx.prototype.markUsed=function(t){var e=this;t.__clipPaths&&G(t.__clipPaths,function(t){t._dom&&bx.prototype.markDomUsed.call(e,t._dom)})},Tx.prototype.removeUnused=function(){bx.prototype.removeUnused.call(this);var t,e,n={},i=this._refGroups;for(t in i)i.hasOwnProperty(t)&&(e=i[t],this.isDomUnused(e)?e.parentNode&&e.parentNode.removeChild(e):n[t]=e);this._refGroups=n},Tx),Mx=(wt(Ix,_x=gr),Ix.prototype._getFromPool=function(){var t,e=this._shadowDomPool.pop();return e||((e=this.createElement("filter")).setAttribute("id","zr"+this._zrId+"-shadow-"+this.nextId++),t=this.createElement("feDropShadow"),e.appendChild(t),this.addDom(e)),e},Ix.prototype.update=function(t,e){var n,i=e.style;(n=i)&&(n.shadowBlur||n.shadowOffsetX||n.shadowOffsetY)?(n=(i=e).style,i=i.getGlobalScale(),n=[n.shadowColor,(n.shadowBlur||0).toFixed(2),(n.shadowOffsetX||0).toFixed(2),(n.shadowOffsetY||0).toFixed(2),i[0],i[1]].join(","),(i=e._shadowDom=this._shadowDomMap[n])||(i=this._getFromPool(),this._shadowDomMap[n]=i),this.updateDom(t,e,i)):this.remove(t,e)},Ix.prototype.remove=function(t,e){null!=e._shadowDom&&(e._shadowDom=null,t.removeAttribute("filter"))},Ix.prototype.updateDom=function(t,e,n){var i,o,r=n.children[0],a=e.style,s=e.getGlobalScale(),l=s[0],u=s[1];l&&u&&(i=a.shadowOffsetX||0,o=a.shadowOffsetY||0,s=a.shadowBlur,a=V1(a.shadowColor),r.setAttribute("dx",i/l+""),r.setAttribute("dy",o/u+""),r.setAttribute("flood-color",a.color),r.setAttribute("flood-opacity",a.opacity+""),r.setAttribute("stdDeviation",s/2/l+" "+s/2/u),n.setAttribute("x","-100%"),n.setAttribute("y","-100%"),n.setAttribute("width","300%"),n.setAttribute("height","300%"),n=(e._shadowDom=n).getAttribute("id"),t.setAttribute("filter","url(#"+n+")"))},Ix.prototype.removeUnused=function(){if(this.getDefs(!1)){var t,e=this._shadowDomPool,n=this._shadowDomMap;for(t in n)n.hasOwnProperty(t)&&e.push(n[t]);this._shadowDomMap={}}},Ix);function Ix(t,e){e=_x.call(this,t,e,["filter"],"__filter_in_use__","_shadowDom")||this;return e._shadowDomMap={},e._shadowDomPool=[],e}function Tx(t,e){e=bx.call(this,t,e,"clipPath","__clippath_in_use__")||this;return e._refGroups={},e._keyDuplicateCount={},e}function Cx(t){return parseInt(t,10)}function Dx(t){return t instanceof as?nx:t instanceof ys?ix:t instanceof hs?ax:nx}function Ax(t,e){return e&&t&&e.parentNode!==t}function kx(t,e,n){Ax(t,e)&&n&&((n=n.nextSibling)?t.insertBefore(e,n):t.appendChild(e))}function Lx(t,e){var n;Ax(t,e)&&((n=t.firstChild)?t.insertBefore(e,n):t.appendChild(e))}function Px(t){return t.__svgEl}function Ox(t,e,n,i){this.type="svg",this.refreshHover=Rx("refreshHover"),this.pathToImage=Rx("pathToImage"),this.configLayer=Rx("configLayer"),this.root=t,this.storage=e,this._opts=n=N({},n||{});var o=E1("svg");o.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns","http://www.w3.org/2000/svg"),o.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink"),o.setAttribute("version","1.1"),o.setAttribute("baseProfile","full"),o.style.cssText="user-select:none;position:absolute;left:0;top:0;";var r=E1("g");o.appendChild(r);e=E1("g");o.appendChild(e),this._gradientManager=new px(i,e),this._patternManager=new mx(i,e),this._clipPathManager=new Sx(i,e),this._shadowManager=new Mx(i,e);i=document.createElement("div");i.style.cssText="overflow:hidden;position:relative",this._svgDom=o,this._svgRoot=e,this._backgroundRoot=r,this._viewport=i,t.appendChild(i),i.appendChild(o),this.resize(n.width,n.height),this._visibleList=[]}function Rx(t){return function(){L('In SVG mode painter not support method "'+t+'"')}}var Nx=(Ox.prototype.getType=function(){return"svg"},Ox.prototype.getViewportRoot=function(){return this._viewport},Ox.prototype.getSvgDom=function(){return this._svgDom},Ox.prototype.getSvgRoot=function(){return this._svgRoot},Ox.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},Ox.prototype.refresh=function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},Ox.prototype.setBackgroundColor=function(t){this._backgroundRoot&&this._backgroundNode&&this._backgroundRoot.removeChild(this._backgroundNode);var e=E1("rect");e.setAttribute("width",this.getWidth()),e.setAttribute("height",this.getHeight()),e.setAttribute("x",0),e.setAttribute("y",0),e.setAttribute("id",0);var n=V1(t),t=n.color,n=n.opacity;e.setAttribute("fill",t),e.setAttribute("fill-opacity",n),this._backgroundRoot.appendChild(e),this._backgroundNode=e},Ox.prototype.createSVGElement=E1,Ox.prototype.paintOne=function(t){var e=Dx(t);return e&&e.brush(t),Px(t)},Ox.prototype._paintList=function(t){var e=this._gradientManager,n=this._patternManager,i=this._clipPathManager,o=this._shadowManager;e.markAllUnused(),n.markAllUnused(),i.markAllUnused(),o.markAllUnused();for(var r=this._svgRoot,a=this._visibleList,s=t.length,l=[],u=0;u<s;u++){var h=t[u],c=Dx(h),p=Px(h);h.invisible||(!h.__dirty&&p||(c&&c.brush(h),(p=Px(h))&&h.style&&(e.update(h.style.fill),e.update(h.style.stroke),n.update(h.style.fill),n.update(h.style.stroke),o.update(p,h)),h.__dirty=0),p&&l.push(h))}for(var d,f,g,y,m,v,x=B1(a,l),u=0;u<x.length;u++){var _=x[u];if(_.removed)for(var b=0;b<_.count;b++)p=Px(h=a[_.indices[b]]),xx(h)?(v=p)&&v.parentNode&&v.parentNode.removeChild(v):(m=r,(v=p)&&m&&v.parentNode===m&&m.removeChild(v))}for(u=0;u<x.length;u++)if(!(_=x[u]).removed)for(b=0;b<_.count;b++){var h=l[_.indices[b]],w=i.update(h,g);w!==y&&(d=f,w&&(d?kx(r,w,d):Lx(r,w),f=w,d=null),y=w),p=Px(h),d?kx(y||r,p,d):Lx(y||r,p),d=p||d,y||(f=d),e.markUsed(h),e.addWithoutUpdate(p,h),n.markUsed(h),n.addWithoutUpdate(p,h),i.markUsed(h),g=h}e.removeUnused(),n.removeUnused(),i.removeUnused(),o.removeUnused(),this._visibleList=l},Ox.prototype.resize=function(t,e){var n=this._viewport;n.style.display="none";var i=this._opts;null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width===t&&this._height===e||(this._width=t,this._height=e,(n=n.style).width=t+"px",n.height=e+"px",(n=this._svgDom).setAttribute("width",t+""),n.setAttribute("height",e+"")),this._backgroundNode&&(this._backgroundNode.setAttribute("width",t),this._backgroundNode.setAttribute("height",e))},Ox.prototype.getWidth=function(){return this._width},Ox.prototype.getHeight=function(){return this._height},Ox.prototype._getSize=function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],o=["paddingLeft","paddingTop"][t],r=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);t=this.root,e=document.defaultView.getComputedStyle(t);return(t[i]||Cx(e[n])||Cx(t.style[n]))-(Cx(e[o])||0)-(Cx(e[r])||0)|0},Ox.prototype.dispose=function(){this.root.innerHTML="",this._svgRoot=this._backgroundRoot=this._svgDom=this._backgroundNode=this._viewport=this.storage=null},Ox.prototype.clear=function(){var t=this._viewport;t&&t.parentNode&&t.parentNode.removeChild(t)},Ox.prototype.toDataURL=function(){this.refresh();var t=this._svgDom,t=t.outerHTML||(t.parentNode&&t.parentNode).innerHTML;return"data:image/svg+xml;charset=UTF-8,"+encodeURIComponent(t.replace(/></g,">\n\r<"))},Ox);function zx(t){return null==t?0:t.length||1}function Ex(t){return t}var Vx=(Gx.prototype.add=function(t){return this._add=t,this},Gx.prototype.update=function(t){return this._update=t,this},Gx.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},Gx.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},Gx.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},Gx.prototype.remove=function(t){return this._remove=t,this},Gx.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},Gx.prototype._executeOneToOne=function(){var t=this._old,e=this._new,n={},i=new Array(t.length),o=new Array(e.length);this._initIndexMap(t,null,i,"_oldKeyGetter"),this._initIndexMap(e,n,o,"_newKeyGetter");for(var r=0;r<t.length;r++){var a,s=i[r],l=n[s],u=zx(l);1<u?(a=l.shift(),1===l.length&&(n[s]=l[0]),this._update&&this._update(a,r)):1===u?(n[s]=null,this._update&&this._update(l,r)):this._remove&&this._remove(r)}this._performRestAdd(o,n)},Gx.prototype._executeMultiple=function(){var t=this._old,e=this._new,n={},i={},o=[],r=[];this._initIndexMap(t,n,o,"_oldKeyGetter"),this._initIndexMap(e,i,r,"_newKeyGetter");for(var a=0;a<o.length;a++){var s=o[a],l=n[s],u=i[s],h=zx(l),c=zx(u);if(1<h&&1===c)this._updateManyToOne&&this._updateManyToOne(u,l),i[s]=null;else if(1===h&&1<c)this._updateOneToMany&&this._updateOneToMany(u,l),i[s]=null;else if(1===h&&1===c)this._update&&this._update(u,l),i[s]=null;else if(1<h&&1<c)this._updateManyToMany&&this._updateManyToMany(u,l),i[s]=null;else if(1<h)for(var p=0;p<h;p++)this._remove&&this._remove(l[p]);else this._remove&&this._remove(l)}this._performRestAdd(r,i)},Gx.prototype._performRestAdd=function(t,e){for(var n=0;n<t.length;n++){var i=t[n],o=e[i],r=zx(o);if(1<r)for(var a=0;a<r;a++)this._add&&this._add(o[a]);else 1===r&&this._add&&this._add(o);e[i]=null}},Gx.prototype._initIndexMap=function(t,e,n,i){for(var o=this._diffModeMultiple,r=0;r<t.length;r++){var a,s,l="_ec_"+this[i](t[r],r);o||(n[r]=l),e&&(0===(s=zx(a=e[l]))?(e[l]=r,o&&n.push(l)):1===s?e[l]=[a,r]:a.push(r))}},Gx),Bx=(Fx.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},Fx.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},Fx);function Fx(t,e){this._encode=t,this._schema=e}function Gx(t,e,n,i,o,r){this._old=t,this._new=e,this._oldKeyGetter=n||Ex,this._newKeyGetter=i||Ex,this.context=o,this._diffModeMultiple="multiple"===r}function Hx(r,t){var e={},a=e.encode={},s=yt(),l=[],u=[],h={};G(r.dimensions,function(t){var e,n,i=r.getDimensionInfo(t),o=i.coordDim;o&&(e=i.coordDimIndex,Wx(a,o)[e]=t,i.isExtraCoord||(s.set(o,1),"ordinal"===(n=i.type)||"time"===n||(l[0]=t),Wx(h,o)[e]=r.getDimensionIndex(i.name)),i.defaultTooltip&&u.push(t)),Fh.each(function(t,e){var n=Wx(a,e),e=i.otherDims[e];null!=e&&!1!==e&&(n[e]=i.name)})});var i=[],o={};s.each(function(t,e){var n=a[e];o[e]=n[0],i=i.concat(n)}),e.dataDimsOnCoord=i,e.dataDimIndicesOnCoord=H(i,function(t){return r.getDimensionInfo(t).storeDimIndex}),e.encodeFirstDimNotExtra=o;var n=a.label;n&&n.length&&(l=n.slice());n=a.tooltip;return n&&n.length?u=n.slice():u.length||(u=l.slice()),a.defaultedLabel=l,a.defaultedTooltip=u,e.userOutput=new Bx(h,t),e}function Wx(t,e){return t.hasOwnProperty(e)||(t[e]=[]),t[e]}function Ux(t){return"category"===t?"ordinal":"time"===t?"time":"float"}var Yx=function(t){this.otherDims={},null!=t&&N(this,t)},Xx=Zo(),Zx={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},jx=(qx.prototype.isDimensionOmitted=function(){return this._dimOmitted},qx.prototype._updateDimOmitted=function(t){(this._dimOmitted=t)&&(this._dimNameMap||(this._dimNameMap=Qx(this.source)))},qx.prototype.getSourceDimensionIndex=function(t){return rt(this._dimNameMap.get(t),-1)},qx.prototype.getSourceDimension=function(t){var e=this.source.dimensionsDefine;if(e)return e[t]},qx.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,e=ip(this.source),n=!(30<t),i="",o=[],r=0,a=0;r<t;r++){var s,l=void 0,u=void 0,h=void 0,c=this.dimensions[a];c&&c.storeDimIndex===r?(l=e?c.name:null,u=c.type,h=c.ordinalMeta,a++):(s=this.getSourceDimension(r))&&(l=e?s.name:null,u=s.type),o.push({property:l,type:u,ordinalMeta:h}),!e||null==l||c&&c.isCalculationCoord||(i+=n?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),i+="$",i+=Zx[u]||"f",h&&(i+=h.uid),i+="$"}var p=this.source;return{dimensions:o,hash:[p.seriesLayoutBy,p.startIndex,i].join("$$")}},qx.prototype.makeOutputDimensionNames=function(){for(var t=[],e=0,n=0;e<this._fullDimCount;e++){var i=void 0,o=this.dimensions[n];o&&o.storeDimIndex===e?(o.isCalculationCoord||(i=o.name),n++):(o=this.getSourceDimension(e))&&(i=o.name),t.push(i)}return t},qx.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},qx);function qx(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}function Kx(t){return t instanceof jx}function Jx(t){for(var e=yt(),n=0;n<(t||[]).length;n++){var i=t[n],i=$(i)?i.name:i;null!=i&&null==e.get(i)&&e.set(i,n)}return e}function Qx(t){var e=Xx(t);return e.dimNameMap||(e.dimNameMap=Jx(t.dimensionsDefine))}var $x,t_,e_,n_,i_,o_,r_,a_=$,s_=H,l_="undefined"==typeof Int32Array?Array:Int32Array,u_=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],h_=["_approximateExtent"],c_=(p_.prototype.getDimension=function(t){if(null==(e=this._recognizeDimIndex(t)))return t;if(e=t,!this._dimOmitted)return this.dimensions[e];t=this._dimIdxToName.get(e);if(null!=t)return t;var e=this._schema.getSourceDimension(e);return e?e.name:void 0},p_.prototype.getDimensionIndex=function(t){var e=this._recognizeDimIndex(t);if(null!=e)return e;if(null==t)return-1;e=this._getDimInfo(t);return e?e.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},p_.prototype._recognizeDimIndex=function(t){if("number"==typeof t||null!=t&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},p_.prototype._getStoreDimIndex=function(t){return this.getDimensionIndex(t)},p_.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},p_.prototype._initGetDimensionInfo=function(t){var e=this._dimInfos;this._getDimInfo=t?function(t){return e.hasOwnProperty(t)?e[t]:void 0}:function(t){return e[t]}},p_.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},p_.prototype.mapDimension=function(t,e){var n=this._dimSummary;if(null==e)return n.encodeFirstDimNotExtra[t];t=n.encode[t];return t?t[e]:null},p_.prototype.mapDimensionsAll=function(t){return(this._dimSummary.encode[t]||[]).slice()},p_.prototype.getStore=function(){return this._store},p_.prototype.initData=function(t,e,n){var i,o,r=this;(i=t instanceof rd?t:i)||(o=this.dimensions,t=Jc(t)||F(t)?new rp(t,o.length):t,i=new rd,o=s_(o,function(t){return{type:r._dimInfos[t].type,property:t}}),i.initData(t,o,n)),this._store=i,this._nameList=(e||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=Hx(this,this._schema),this.userOutput=this._dimSummary.userOutput},p_.prototype.appendData=function(t){t=this._store.appendData(t);this._doInit(t[0],t[1])},p_.prototype.appendValues=function(t,e){var t=this._store.appendValues(t,e.length),n=t.start,i=t.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),e)for(var r=n;r<i;r++)this._nameList[r]=e[r-n],o&&r_(this,r)},p_.prototype._updateOrdinalMeta=function(){for(var t=this._store,e=this.dimensions,n=0;n<e.length;n++){var i=this._dimInfos[e[n]];i.ordinalMeta&&t.collectOrdinalMeta(i.storeDimIndex,i.ordinalMeta)}},p_.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return null==this._idDimIdx&&t.getSource().sourceFormat!==Yh&&!t.fillStorage},p_.prototype._doInit=function(t,e){if(!(e<=t)){var n=this._store.getProvider();this._updateOrdinalMeta();var i=this._nameList,o=this._idList;if(n.getSource().sourceFormat===Gh&&!n.pure)for(var r=[],a=t;a<e;a++){var s,l=n.getItem(a,r);this.hasItemOption||!$(u=l)||u instanceof Array||(this.hasItemOption=!0),l&&(s=l.name,null==i[a]&&null!=s&&(i[a]=Ho(s,null)),l=l.id,null==o[a]&&null!=l&&(o[a]=Ho(l,null)))}if(this._shouldMakeIdFromName())for(a=t;a<e;a++)r_(this,a);$x(this)}var u},p_.prototype.getApproximateExtent=function(t){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t))},p_.prototype.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},p_.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},p_.prototype.setCalculationInfo=function(t,e){a_(t)?N(this._calculationInfo,t):this._calculationInfo[t]=e},p_.prototype.getName=function(t){var e=this.getRawIndex(t),t=this._nameList[e];return t=null==(t=null==t&&null!=this._nameDimIdx?e_(this,this._nameDimIdx,e):t)?"":t},p_.prototype._getCategory=function(t,e){e=this._store.get(t,e),t=this._store.getOrdinalMeta(t);return t?t.categories[e]:e},p_.prototype.getId=function(t){return t_(this,this.getRawIndex(t))},p_.prototype.count=function(){return this._store.count()},p_.prototype.get=function(t,e){var n=this._store,t=this._dimInfos[t];if(t)return n.get(t.storeDimIndex,e)},p_.prototype.getByRawIndex=function(t,e){var n=this._store,t=this._dimInfos[t];if(t)return n.getByRawIndex(t.storeDimIndex,e)},p_.prototype.getIndices=function(){return this._store.getIndices()},p_.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t))},p_.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},p_.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},p_.prototype.getValues=function(t,e){var n=this,i=this._store;return j(t)?i.getValues(s_(t,function(t){return n._getStoreDimIndex(t)}),e):i.getValues(t)},p_.prototype.hasValue=function(t){for(var e=this._dimSummary.dataDimIndicesOnCoord,n=0,i=e.length;n<i;n++)if(isNaN(this._store.get(e[n],t)))return!1;return!0},p_.prototype.indexOfName=function(t){for(var e=0,n=this._store.count();e<n;e++)if(this.getName(e)===t)return e;return-1},p_.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},p_.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},p_.prototype.rawIndexOf=function(t,e){e=(t&&this._invertedIndicesMap[t])[e];return null==e||isNaN(e)?-1:e},p_.prototype.indicesOfNearest=function(t,e,n){return this._store.indicesOfNearest(this._getStoreDimIndex(t),e,n)},p_.prototype.each=function(t,e,n){"function"==typeof t&&(n=e,e=t,t=[]);n=n||this,t=s_(n_(t),this._getStoreDimIndex,this);this._store.each(t,n?X(e,n):e)},p_.prototype.filterSelf=function(t,e,n){"function"==typeof t&&(n=e,e=t,t=[]);n=n||this,t=s_(n_(t),this._getStoreDimIndex,this);return this._store=this._store.filter(t,n?X(e,n):e),this},p_.prototype.selectRange=function(n){var i=this,o={},t=Y(n),r=[];return G(t,function(t){var e=i._getStoreDimIndex(t);o[e]=n[t],r.push(e)}),this._store=this._store.selectRange(o),this},p_.prototype.mapArray=function(t,e,n){"function"==typeof t&&(n=e,e=t,t=[]);var i=[];return this.each(t,function(){i.push(e&&e.apply(this,arguments))},n=n||this),i},p_.prototype.map=function(t,e,n,i){n=n||i||this,i=s_(n_(t),this._getStoreDimIndex,this),t=o_(this);return t._store=this._store.map(i,n?X(e,n):e),t},p_.prototype.modify=function(t,e,n,i){i=n||i||this,t=s_(n_(t),this._getStoreDimIndex,this);this._store.modify(t,i?X(e,i):e)},p_.prototype.downSample=function(t,e,n,i){var o=o_(this);return o._store=this._store.downSample(this._getStoreDimIndex(t),e,n,i),o},p_.prototype.lttbDownSample=function(t,e){var n=o_(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(t),e),n},p_.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},p_.prototype.getItemModel=function(t){var e=this.hostModel,t=this.getRawDataItem(t);return new wu(t,e,e&&e.ecModel)},p_.prototype.diff=function(e){var n=this;return new Vx(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(t){return t_(e,t)},function(t){return t_(n,t)})},p_.prototype.getVisual=function(t){var e=this._visual;return e&&e[t]},p_.prototype.setVisual=function(t,e){this._visual=this._visual||{},a_(t)?N(this._visual,t):this._visual[t]=e},p_.prototype.getItemVisual=function(t,e){t=this._itemVisuals[t],t=t&&t[e];return null==t?this.getVisual(e):t},p_.prototype.hasItemVisual=function(){return 0<this._itemVisuals.length},p_.prototype.ensureUniqueItemVisual=function(t,e){var n=this._itemVisuals,i=n[t],t=(i=i||(n[t]={}))[e];return null==t&&(j(t=this.getVisual(e))?t=t.slice():a_(t)&&(t=N({},t)),i[e]=t),t},p_.prototype.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{};this._itemVisuals[t]=i,a_(e)?N(i,e):i[e]=n},p_.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},p_.prototype.setLayout=function(t,e){if(a_(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},p_.prototype.getLayout=function(t){return this._layout[t]},p_.prototype.getItemLayout=function(t){return this._itemLayouts[t]},p_.prototype.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?N(this._itemLayouts[t]||{},e):e},p_.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},p_.prototype.setItemGraphicEl=function(t,e){var n=this.hostModel&&this.hostModel.seriesIndex;Bs(n,this.dataType,t,e),this._graphicEls[t]=e},p_.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},p_.prototype.eachItemGraphicEl=function(n,i){G(this._graphicEls,function(t,e){t&&n&&n.call(i,t,e)})},p_.prototype.cloneShallow=function(t){return t=t||new p_(this._schema||s_(this.dimensions,this._getDimInfo,this),this.hostModel),i_(t,this),t._store=this._store,t},p_.prototype.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(st(arguments)))})},p_.internalField=($x=function(a){var s=a._invertedIndicesMap;G(s,function(t,e){var n=a._dimInfos[e],i=n.ordinalMeta,o=a._store;if(i){t=s[e]=new l_(i.categories.length);for(var r=0;r<t.length;r++)t[r]=-1;for(r=0;r<o.count();r++)t[o.get(n.storeDimIndex,r)]=r}})},e_=function(t,e,n){return Ho(t._getCategory(e,n),null)},t_=function(t,e){var n=t._idList[e];return n=null==(n=null==n&&null!=t._idDimIdx?e_(t,t._idDimIdx,e):n)?"e\0\0"+e:n},n_=function(t){return t=!j(t)?null!=t?[t]:[]:t},o_=function(t){var e=new p_(t._schema||s_(t.dimensions,t._getDimInfo,t),t.hostModel);return i_(e,t),e},i_=function(e,n){G(u_.concat(n.__wrappedMethods||[]),function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e.__wrappedMethods=n.__wrappedMethods,G(h_,function(t){e[t]=P(n[t])}),e._calculationInfo=N({},n._calculationInfo)},void(r_=function(t,e){var n=t._nameList,i=t._idList,o=t._nameDimIdx,r=t._idDimIdx,a=n[e],s=i[e];null==a&&null!=o&&(n[e]=a=e_(t,o,e)),null==s&&null!=r&&(i[e]=s=e_(t,r,e)),null==s&&null!=a&&(s=a,1<(a=(t=t._nameRepeatCount)[a]=(t[a]||0)+1)&&(s+="__ec__"+a),i[e]=s)})),p_);function p_(t,e){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"];var n=!(this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"]);Kx(t)?(o=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(n=!0,o=t);for(var i,o=o||["x","y"],r={},a=[],s={},l=!1,u={},h=0;h<o.length;h++){var c=o[h],p=K(c)?new Yx({name:c}):c instanceof Yx?c:new Yx(c),d=p.name;p.type=p.type||"float",p.coordDim||(p.coordDim=d,p.coordDimIndex=0);c=p.otherDims=p.otherDims||{};a.push(d),r[d]=p,null!=u[d]&&(l=!0),p.createInvertedIndices&&(s[d]=[]),0===c.itemName&&(this._nameDimIdx=h),0===c.itemId&&(this._idDimIdx=h),n&&(p.storeDimIndex=h)}this.dimensions=a,this._dimInfos=r,this._initGetDimensionInfo(l),this.hostModel=e,this._invertedIndicesMap=s,this._dimOmitted&&(i=this._dimIdxToName=yt(),G(a,function(t){i.set(r[t].storeDimIndex,t)}))}function d_(t,e){Jc(t)||(t=$c(t));for(var n,i,o=(e=e||{}).coordDimensions||[],r=e.dimensionsDefine||t.dimensionsDefine||[],a=yt(),s=[],l=(n=t,p=o,u=e.dimensionsCount,i=Math.max(n.dimensionsDetectedCount||1,p.length,r.length,u||0),G(p,function(t){var e;$(t)&&(e=t.dimsDef)&&(i=Math.max(i,e.length))}),i),u=e.canOmitUnusedDimensions&&30<l,h=r===t.dimensionsDefine,c=h?Qx(t):Jx(r),p=e.encodeDefine,d=yt(p=!p&&e.encodeDefaulter?e.encodeDefaulter(t,l):p),f=new td(l),g=0;g<f.length;g++)f[g]=-1;function y(t){var e=f[t];if(e<0){var n=r[t],i=$(n)?n:{name:n},o=new Yx,n=i.name;null!=n&&null!=c.get(n)&&(o.name=o.displayName=n),null!=i.type&&(o.type=i.type),null!=i.displayName&&(o.displayName=i.displayName);i=s.length;return f[t]=i,o.storeDimIndex=t,s.push(o),o}return s[e]}if(!u)for(g=0;g<l;g++)y(g);d.each(function(t,n){var i,t=No(t).slice();1===t.length&&!K(t[0])&&t[0]<0?d.set(n,!1):(i=d.set(n,[]),G(t,function(t,e){t=K(t)?c.get(t):t;null!=t&&t<l&&v(y(i[e]=t),n,e)}))});var m=0;function v(t,e,n){null!=Fh.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,a.set(e,!0))}G(o,function(t){var n,i,o,r;K(t)?(r=t,o={}):(r=(o=t).name,t=o.ordinalMeta,o.ordinalMeta=null,(o=N({},o)).ordinalMeta=t,n=o.dimsDef,i=o.otherDims,o.name=o.coordDim=o.coordDimIndex=o.dimsDef=o.otherDims=null);var e=d.get(r);if(!1!==e){if(!(e=No(e)).length)for(var a=0;a<(n&&n.length||1);a++){for(;m<l&&null!=y(m).coordDim;)m++;m<l&&e.push(m++)}G(e,function(t,e){t=y(t);h&&null!=o.type&&(t.type=o.type),v(z(t,o),r,e),null==t.name&&n&&($(e=n[e])||(e={name:e}),t.name=t.displayName=e.name,t.defaultTooltip=e.defaultTooltip),i&&z(t.otherDims,i)})}});var x=e.generateCoord,_=null!=(b=e.generateCoordCount),b=x?b||1:0,w=x||"value";function S(t){null==t.name&&(t.name=t.coordDim)}if(u)G(s,function(t){S(t)}),s.sort(function(t,e){return t.storeDimIndex-e.storeDimIndex});else for(var M=0;M<l;M++){var I=y(M);null==I.coordDim&&(I.coordDim=function(t,e,n){var i=e.data;if(n||i.hasOwnProperty(t)){for(var o=0;i.hasOwnProperty(t+o);)o++;t+=o}return e.set(t,!0),t}(w,a,_),I.coordDimIndex=0,(!x||b<=0)&&(I.isExtraCoord=!0),b--),S(I),null!=I.type||tc(t,M)!==qh.Must&&(!I.isExtraCoord||null==I.otherDims.itemName&&null==I.otherDims.seriesName)||(I.type="ordinal")}return function(t){for(var e=yt(),n=0;n<t.length;n++){var i=t[n],o=i.name,r=e.get(o)||0;0<r&&(i.name=o+(r-1)),r++,e.set(o,r)}}(s),new jx({source:t,dimensions:s,fullDimensionCount:l,dimensionOmitted:u})}var f_=function(t){this.coordSysDims=[],this.axisMap=yt(),this.categoryAxisMap=yt(),this.coordSysName=t};var g_={cartesian2d:function(t,e,n,i){var o=t.getReferringComponents("xAxis",Jo).models[0],t=t.getReferringComponents("yAxis",Jo).models[0];e.coordSysDims=["x","y"],n.set("x",o),n.set("y",t),y_(o)&&(i.set("x",o),e.firstCategoryDimIndex=0),y_(t)&&(i.set("y",t),null==e.firstCategoryDimIndex&&(e.firstCategoryDimIndex=1))},singleAxis:function(t,e,n,i){t=t.getReferringComponents("singleAxis",Jo).models[0];e.coordSysDims=["single"],n.set("single",t),y_(t)&&(i.set("single",t),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var o=t.getReferringComponents("polar",Jo).models[0],t=o.findAxisModel("radiusAxis"),o=o.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",t),n.set("angle",o),y_(t)&&(i.set("radius",t),e.firstCategoryDimIndex=0),y_(o)&&(i.set("angle",o),null==e.firstCategoryDimIndex&&(e.firstCategoryDimIndex=1))},geo:function(t,e,n,i){e.coordSysDims=["lng","lat"]},parallel:function(t,i,o,r){var a=t.ecModel,t=a.getComponent("parallel",t.get("parallelIndex")),s=i.coordSysDims=t.dimensions.slice();G(t.parallelAxisIndex,function(t,e){var n=a.getComponent("parallelAxis",t),t=s[e];o.set(t,n),y_(n)&&(r.set(t,n),null==i.firstCategoryDimIndex&&(i.firstCategoryDimIndex=e))})}};function y_(t){return"category"===t.get("type")}function m_(t,e,n){var i,o,r,a=(n=n||{}).byIndex,s=n.stackedCoordDimension;Kx(e.schema)?(o=e.schema,i=o.dimensions,r=e.store):i=e;var l,u,h,c,p,d,f=!(!t||!t.get("stack"));return G(i,function(t,e){K(t)&&(i[e]=t={name:t}),f&&!t.isExtraCoord&&(a||l||!t.ordinalMeta||(l=t),u||"ordinal"===t.type||"time"===t.type||s&&s!==t.coordDim||(u=t))}),!u||a||l||(a=!0),u&&(h="__\0ecstackresult_"+t.id,c="__\0ecstackedover_"+t.id,l&&(l.createInvertedIndices=!0),p=u.coordDim,n=u.type,d=0,G(i,function(t){t.coordDim===p&&d++}),e={name:h,coordDim:p,coordDimIndex:d,type:n,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},t={name:c,coordDim:c,coordDimIndex:d+1,type:n,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1},o?(r&&(e.storeDimIndex=r.ensureCalculationDimension(c,n),t.storeDimIndex=r.ensureCalculationDimension(h,n)),o.appendCalculationDimension(e),o.appendCalculationDimension(t)):(i.push(e),i.push(t))),{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:a,stackedOverDimension:c,stackResultDimension:h}}function v_(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function x_(t,e){return v_(t,e)?t.getCalculationInfo("stackResultDimension"):e}var __,b_,w_=function(t,e,n){n=n||{};var i,o=e.getSourceManager(),r=!1;t?(r=!0,i=$c(t)):r=(i=o.getSource()).sourceFormat===Gh;var a,s,l,u,h,c=function(t){var e=t.get("coordinateSystem"),n=new f_(e);if(e=g_[e])return e(t,n,n.axisMap,n.categoryAxisMap),n}(e),t=(h=c,t=(t=e).get("coordinateSystem"),t=Sc.get(t),p=(p=h&&h.coordSysDims?H(h.coordSysDims,function(t){var e={name:t},t=h.axisMap.get(t);return t&&(t=t.get("type"),e.type=Ux(t)),e}):p)||(t&&(t.getDimensionsInfo?t.getDimensionsInfo():t.dimensions.slice())||["x","y"])),p=q(p=n.useEncodeDefaulter)?p:p?Z(Jh,t,e):null,t=d_(i,{coordDimensions:t,generateCoord:n.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:p,canOmitUnusedDimensions:!r}),d=(p=t.dimensions,a=n.createInvertedIndices,(s=c)&&G(p,function(t,e){var n=t.coordDim,n=s.categoryAxisMap.get(n);n&&(null==l&&(l=e),t.ordinalMeta=n.getOrdinalMeta(),a&&(t.createInvertedIndices=!0)),null!=t.otherDims.itemName&&(u=!0)}),u||null==l||(p[l].otherDims.itemName=0),l),p=r?null:o.getSharedDataStore(t),o=m_(e,{schema:t,store:p});return(e=new c_(t,e)).setCalculationInfo(o),o=null!=d&&function(t){if(t.sourceFormat===Gh){t=function(t){var e=0;for(;e<t.length&&null==t[e];)e++;return t[e]}(t.data||[]);return null!=t&&!j(Vo(t))}}(i)?function(t,e,n,i){return i===d?n:this.defaultDimValueGetter(t,e,n,i)}:null,e.hasItemOption=!1,e.initData(r?i:p,null,o),e},S_=(d(M_,__=Gd),M_.prototype.getInitialData=function(t){return w_(null,this,{useEncodeDefaulter:!0})},M_.prototype.getLegendIcon=function(t){var e=new ro,n=am("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);e.add(n),n.setStyle(t.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),n="none"===i?"circle":i,i=.8*t.itemHeight,i=am(n,(t.itemWidth-i)/2,(t.itemHeight-i)/2,i,i,t.itemStyle.fill);e.add(i),i.setStyle(t.itemStyle);o="inherit"===t.iconRotate?o:t.iconRotate||0;return i.rotation=o*Math.PI/180,i.setOrigin([t.itemWidth/2,t.itemHeight/2]),-1<n.indexOf("empty")&&(i.style.stroke=i.style.fill,i.style.fill="#fff",i.style.lineWidth=2),e},M_.type="series.line",M_.dependencies=["grid","polar"],M_.defaultOption={zlevel:0,z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0,lineStyle:{width:"bolder"}},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},M_);function M_(){var t=null!==__&&__.apply(this,arguments)||this;return t.type=M_.type,t.hasSymbolVisual=!0,t}function I_(t,e){var n=t.mapDimensionsAll("defaultedLabel"),i=n.length;if(1===i){var o=yp(t,e,n[0]);return null!=o?o+"":null}if(i){for(var r=[],a=0;a<n.length;a++)r.push(yp(t,e,n[a]));return r.join(" ")}}function T_(t,e){var n=t.mapDimensionsAll("defaultedLabel");if(!j(e))return e+"";for(var i=[],o=0;o<n.length;o++){var r=t.getDimensionIndex(n[o]);0<=r&&i.push(e[r])}return i.join(" ")}function C_(t,e,n,i){var o=b_.call(this)||this;return o.updateData(t,e,n,i),o}function D_(t,e){this.parent.drift(t,e)}var A_=(d(C_,b_=ro),C_.prototype._createSymbol=function(t,e,n,i,o){this.removeAll();o=am(t,-1,-1,2,2,null,o);o.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),o.drift=D_,this._symbolType=t,this.add(o)},C_.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},C_.prototype.getSymbolType=function(){return this._symbolType},C_.prototype.getSymbolPath=function(){return this.childAt(0)},C_.prototype.highlight=function(){xl(this.childAt(0))},C_.prototype.downplay=function(){_l(this.childAt(0))},C_.prototype.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},C_.prototype.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":e.cursor},C_.prototype.updateData=function(t,e,n,i){this.silent=!1;var o,r,a,s=t.getItemVisual(e,"symbol")||"circle",l=t.hostModel,u=C_.getSymbolSize(t,e),h=s!==this._symbolType,c=i&&i.disableAnimation;h?(o=t.getItemVisual(e,"symbolKeepAspect"),this._createSymbol(s,t,e,u,o)):((r=this.childAt(0)).silent=!1,a={scaleX:u[0]/2,scaleY:u[1]/2},c?r.attr(a):Wl(r,a,l,e),ql(r)),this._updateCommon(t,e,u,n,i),h&&(r=this.childAt(0),c||(a={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:r.style.opacity}},r.scaleX=r.scaleY=0,r.style.opacity=0,Ul(r,a,l,e))),c&&this.childAt(0).stopAnimation("remove"),this._seriesModel=l},C_.prototype._updateCommon=function(e,t,n,i,o){var r,a,s,l,u,h,c=this.childAt(0),p=e.hostModel;i&&(r=i.emphasisItemStyle,s=i.blurItemStyle,a=i.selectItemStyle,l=i.focus,u=i.blurScope,h=i.labelStatesModels,v=i.hoverScale,g=i.cursorStyle),i&&!e.hasItemOption||(r=(d=(f=i&&i.itemModel?i.itemModel:e.getItemModel(t)).getModel("emphasis")).getModel("itemStyle").getItemStyle(),a=f.getModel(["select","itemStyle"]).getItemStyle(),s=f.getModel(["blur","itemStyle"]).getItemStyle(),l=d.get("focus"),u=d.get("blurScope"),h=tu(f),v=d.getShallow("scale"),g=f.getShallow("cursor"));var d=e.getItemVisual(t,"symbolRotate");c.attr("rotation",(d||0)*Math.PI/180||0);var f=lm(e.getItemVisual(t,"symbolOffset"),n);f&&(c.x=f[0],c.y=f[1]),g&&c.attr("cursor",g);d=e.getItemVisual(t,"style"),f=d.fill;c instanceof ys?(y=c.style,c.useStyle(N({image:y.image,x:y.x,y:y.y,width:y.width,height:y.height},d))):(c.__isEmptyBrush?c.useStyle(N({},d)):c.useStyle(d),c.style.decal=null,c.setColor(f,o&&o.symbolInnerColor),c.style.strokeNoScale=!0);var g=e.getItemVisual(t,"liftZ"),y=this._z2;null!=g?null==y&&(this._z2=c.z2,c.z2+=g):null!=y&&(c.z2=y,this._z2=null);var m=o&&o.useNameLabel;$l(c,h,{labelFetcher:p,labelDataIndex:t,defaultText:function(t){return m?e.getName(t):I_(e,t)},inheritColor:f,defaultOpacity:d.opacity}),this._sizeX=n[0]/2,this._sizeY=n[1]/2;var v,n=c.ensureState("emphasis");n.style=r,c.ensureState("select").style=a,c.ensureState("blur").style=s,v&&(v=Math.max(1.1,3/this._sizeY),n.scaleX=this._sizeX*v,n.scaleY=this._sizeY*v),this.setSymbolScale(1),Ll(this,l,u)},C_.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},C_.prototype.fadeOut=function(t,e){var n=this.childAt(0),i=this._seriesModel,o=Gs(this).dataIndex,r=e&&e.animation;this.silent=n.silent=!0,e&&e.fadeLabel?(e=n.getTextContent())&&Xl(e,{style:{opacity:0}},i,{dataIndex:o,removeOpt:r,cb:function(){n.removeTextContent()}}):n.removeTextContent(),Xl(n,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:o,cb:t,removeOpt:r})},C_.getSymbolSize=function(t,e){return sm(t.getItemVisual(e,"symbolSize"))},C_);function k_(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 L_(t){return(t=null!=t&&!$(t)?{isIgnore:t}:t)||{}}function P_(t){var e=t.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),hoverScale:t.get("scale"),labelStatesModels:tu(e),cursorStyle:e.get("cursor")}}var O_=(R_.prototype.updateData=function(r,a){a=L_(a);var s=this.group,l=r.hostModel,u=this._data,h=this._SymbolCtor,c=a.disableAnimation,p=P_(r),d={disableAnimation:c},f=a.getSymbolPoint||function(t){return r.getItemLayout(t)};u||s.removeAll(),r.diff(u).add(function(t){var e,n=f(t);k_(r,n,t,a)&&((e=new h(r,t,p,d)).setPosition(n),r.setItemGraphicEl(t,e),s.add(e))}).update(function(t,e){var n,i=u.getItemGraphicEl(e),o=f(t);k_(r,o,t,a)?(n=r.getItemVisual(t,"symbol")||"circle",e=i&&i.getSymbolType&&i.getSymbolType(),!i||e&&e!==n?(s.remove(i),(i=new h(r,t,p,d)).setPosition(o)):(i.updateData(r,t,p,d),o={x:o[0],y:o[1]},c?i.attr(o):Wl(i,o,l)),s.add(i),r.setItemGraphicEl(t,i)):s.remove(i)}).remove(function(t){var e=u.getItemGraphicEl(t);e&&e.fadeOut(function(){s.remove(e)})}).execute(),this._getSymbolPoint=f,this._data=r},R_.prototype.isPersistent=function(){return!0},R_.prototype.updateLayout=function(){var n=this,t=this._data;t&&t.eachItemGraphicEl(function(t,e){e=n._getSymbolPoint(e);t.setPosition(e),t.markRedraw()})},R_.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=P_(t),this._data=null,this.group.removeAll()},R_.prototype.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}n=L_(n);for(var o=t.start;o<t.end;o++){var r,a=e.getItemLayout(o);k_(e,a,o,n)&&((r=new this._SymbolCtor(e,o,this._seriesScope)).traverse(i),r.setPosition(a),this.group.add(r),e.setItemGraphicEl(o,r))}},R_.prototype.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll()},R_);function R_(t){this.group=new ro,this._SymbolCtor=t||A_}function N_(t,e,n){var i=t.getBaseAxis(),o=t.getOtherAxis(i),r=(s=n,u=0,l=(l=o).scale.getExtent(),"start"===s?u=l[0]:"end"===s?u=l[1]:0<l[0]?u=l[0]:l[1]<0&&(u=l[1]),u),a=i.dim,n=o.dim,s=e.mapDimension(n),l=e.mapDimension(a),u="x"===n||"radius"===n?1:0,i=H(t.dimensions,function(t){return e.mapDimension(t)}),o=!1,t=e.getCalculationInfo("stackResultDimension");return v_(e,i[0])&&(o=!0,i[0]=t),v_(e,i[1])&&(o=!0,i[1]=t),{dataDimsForPoint:i,valueStart:r,valueAxisDim:n,baseAxisDim:a,stacked:!!o,valueDim:s,baseDim:l,baseDataOffset:u,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function z_(t,e,n,i){var o=NaN;t.stacked&&(o=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(o)&&(o=t.valueStart);var r=t.baseDataOffset,a=[];return a[r]=n.get(t.baseDim,i),a[1-r]=o,e.dataToPoint(a)}var E_="undefined"!=typeof Float32Array,V_=E_?Float32Array:Array;function B_(t){return j(t)?E_?new Float32Array(t):t:new V_(t)}var F_=Math.min,G_=Math.max;function H_(t,e){return isNaN(t)||isNaN(e)}function W_(t,e,n,i,o,r,a,s,l){for(var u,h,c,p,d,f,g=n,y=0;y<i;y++){var m=e[2*g],v=e[2*g+1];if(o<=g||g<0)break;if(H_(m,v)){if(l){g+=r;continue}break}if(g===n)t[0<r?"moveTo":"lineTo"](m,v),c=m,p=v;else{var x=m-u,_=v-h;if(x*x+_*_<.5){g+=r;continue}if(0<a){for(var b=g+r,w=e[2*b],S=e[2*b+1];w===m&&S===v&&y<i;)y++,g+=r,w=e[2*(b+=r)],S=e[2*b+1],m=e[2*g],v=e[2*g+1];var M=y+1;if(l)for(;H_(w,S)&&M<i;)M++,w=e[2*(b+=r)],S=e[2*b+1];var I,T,C,D,A=0,k=0,L=void 0,P=void 0;i<=M||H_(w,S)?(d=m,f=v):(A=w-u,k=S-h,I=m-u,T=w-m,C=v-h,D=S-v,_=x=void 0,P="x"===s?(x=Math.abs(I),_=Math.abs(T),d=m-x*a,L=m+x*a,f=v):"y"===s?(x=Math.abs(C),_=Math.abs(D),f=v-x*a,L=d=m,v+x*a):(x=Math.sqrt(I*I+C*C),d=m-A*a*(1-(D=(_=Math.sqrt(T*T+D*D))/(_+x))),f=v-k*a*(1-D),P=v+k*a*D,L=F_(L=m+A*a*D,G_(w,m)),P=F_(P,G_(S,v)),L=G_(L,F_(w,m)),f=v-(k=(P=G_(P,F_(S,v)))-v)*x/_,d=F_(d=m-(A=L-m)*x/_,G_(u,m)),f=F_(f,G_(h,v)),L=m+(A=m-(d=G_(d,F_(u,m))))*_/x,v+(k=v-(f=G_(f,F_(h,v))))*_/x)),t.bezierCurveTo(c,p,d,f,m,v),c=L,p=P}else t.lineTo(m,v)}u=m,h=v,g+=r}return y}var U_,Y_,X_,Z_=function(){this.smooth=0,this.smoothConstraint=!0},j_=(d($_,X_=as),$_.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},$_.prototype.getDefaultShape=function(){return new Z_},$_.prototype.buildPath=function(t,e){var n=e.points,i=0,o=n.length/2;if(e.connectNulls){for(;0<o&&H_(n[2*o-2],n[2*o-1]);o--);for(;i<o&&H_(n[2*i],n[2*i+1]);i++);}for(;i<o;)i+=W_(t,n,i,o,o,1,e.smooth,e.smoothMonotone,e.connectNulls)+1},$_.prototype.getPointOn=function(t,e){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n,i,o=this.path.data,r=Ba.CMD,a="x"===e,s=[],l=0;l<o.length;){var u,h=void 0,c=void 0;switch(o[l++]){case r.M:n=o[l++],i=o[l++];break;case r.L:if(h=o[l++],c=o[l++],(u=a?(t-n)/(h-n):(t-i)/(c-i))<=1&&0<=u){var p=a?(c-i)*u+i:(h-n)*u+n;return a?[t,p]:[p,t]}n=h,i=c;break;case r.C:var h=o[l++],c=o[l++],d=o[l++],f=o[l++],g=o[l++],y=o[l++],m=a?$r(n,h,d,g,t,s):$r(i,c,f,y,t,s);if(0<m)for(var v=0;v<m;v++){var x=s[v];if(x<=1&&0<=x)return p=a?Jr(i,c,f,y,x):Jr(n,h,d,g,x),a?[t,p]:[p,t]}n=g,i=y}}},$_),q_=(d(Q_,Y_=Z_),Q_),K_=(d(J_,U_=as),J_.prototype.getDefaultShape=function(){return new q_},J_.prototype.buildPath=function(t,e){var n=e.points,i=e.stackedOnPoints,o=0,r=n.length/2,a=e.smoothMonotone;if(e.connectNulls){for(;0<r&&H_(n[2*r-2],n[2*r-1]);r--);for(;o<r&&H_(n[2*o],n[2*o+1]);o++);}for(;o<r;){var s=W_(t,n,o,r,r,1,e.smooth,a,e.connectNulls);W_(t,i,o+s-1,s,r,-1,e.stackedOnSmooth,a,e.connectNulls),o+=s+1,t.closePath()}},J_);function J_(t){t=U_.call(this,t)||this;return t.type="ec-polygon",t}function Q_(){return null!==Y_&&Y_.apply(this,arguments)||this}function $_(t){t=X_.call(this,t)||this;return t.type="ec-polyline",t}function tb(t,e,n,i,o){var r=t.getArea(),a=r.x,s=r.y,l=r.width,u=r.height,r=n.get(["lineStyle","width"])||2;a-=r/2,s-=r/2,l+=r,u+=r;var a=Math.floor(a),l=Math.round(l),h=new Ts({shape:{x:a,y:s,width:l,height:u}});return e&&(t=(e=t.getBaseAxis()).isHorizontal(),e=e.inverse,t?(e&&(h.shape.x+=l),h.shape.width=0):(e||(h.shape.y+=u),h.shape.height=0),Ul(h,{shape:{width:l,height:u,x:a,y:s}},n,null,i,"function"==typeof o?function(t){o(t,h)}:null)),h}function eb(t,e,n){var i=t.getArea(),o=yo(i.r0,1),r=yo(i.r,1),a=new Wg({shape:{cx:yo(t.cx,1),cy:yo(t.cy,1),r0:o,r:r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}});return e&&("angle"===t.getBaseAxis().dim?a.shape.endAngle=i.startAngle:a.shape.r=o,Ul(a,{shape:{endAngle:i.endAngle,r:r}},n)),a}function nb(t,e,n,i,o){return t?"polar"===t.type?eb(t,e,n):"cartesian2d"===t.type?tb(t,e,n,i,o):null:null}function ib(t,e){return t.type===e}function ob(t,e){if(t.length===e.length){for(var n=0;n<t.length;n++)if(t[n]!==e[n])return;return 1}}function rb(t){for(var e=1/0,n=1/0,i=-1/0,o=-1/0,r=0;r<t.length;){var a=t[r++],s=t[r++];isNaN(a)||(e=Math.min(a,e),i=Math.max(a,i)),isNaN(s)||(n=Math.min(s,n),o=Math.max(s,o))}return[[e,n],[i,o]]}function ab(t,e){var n=rb(t),i=n[0],t=n[1],n=rb(e),e=n[0],n=n[1];return Math.max(Math.abs(i[0]-e[0]),Math.abs(i[1]-e[1]),Math.abs(t[0]-n[0]),Math.abs(t[1]-n[1]))}function sb(t){return"number"==typeof t?t:t?.5:0}function lb(t,e,n){for(var e=e.getBaseAxis(),i="x"===e.dim||"radius"===e.dim?0:1,o=[],r=0,a=[],s=[],l=[];r<t.length-2;r+=2)switch(l[0]=t[r+2],l[1]=t[r+3],s[0]=t[r],s[1]=t[r+1],o.push(s[0],s[1]),n){case"end":a[i]=l[i],a[1-i]=s[1-i],o.push(a[0],a[1]);break;case"middle":var u=(s[i]+l[i])/2,h=[];a[i]=h[i]=u,a[1-i]=s[1-i],h[1-i]=l[1-i],o.push(a[0],a[1]),o.push(h[0],h[1]);break;default:a[i]=s[i],a[1-i]=l[1-i],o.push(a[0],a[1])}return o.push(t[r++],t[r++]),o}function ub(t,e){var n,i,o=[],r=t.length;function a(t,e,n){var i=t.coord;return{coord:n,color:function(t,e,n){if(e&&e.length&&0<=t&&t<=1){var i=t*(e.length-1),o=Math.floor(i),r=Math.ceil(i),a=rn(e[o]),t=rn(e[r]),e=i-o,e=pn([Ze(Qe(a[0],t[0],e)),Ze(Qe(a[1],t[1],e)),Ze(Qe(a[2],t[2],e)),je(Qe(a[3],t[3],e))],"rgba");return n?{color:e,leftIndex:o,rightIndex:r,value:i}:e}}((n-i)/(e.coord-i),[t.color,e.color])}}for(var s=0;s<r;s++){var l=t[s],u=l.coord;if(u<0)n=l;else{if(e<u){i?o.push(a(i,l,e)):n&&o.push(a(n,l,0),a(n,l,e));break}n&&(o.push(a(n,l,0)),n=null),o.push(l),i=l}}return o}function hb(t,e,n){var i=t.get("showAllSymbol"),t="auto"===i;if(!i||t){var o=n.getAxesByScale("ordinal")[0];if(o&&(!t||!function(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var o=e.count(),r=Math.max(1,Math.round(o/5)),a=0;a<o;a+=r)if(1.5*A_.getSymbolSize(e,a)[t.isHorizontal()?1:0]>i)return!1;return!0}(o,e))){var r=e.mapDimension(o.dim),a={};return G(o.getViewLabels(),function(t){t=o.scale.getRawOrdinalNumber(t.tickValue);a[t]=1}),function(t){return!a.hasOwnProperty(e.get(r,t))}}}}function cb(t){for(var e,n,i=t.length/2;0<i&&(e=t[2*i-2],n=t[2*i-1],isNaN(e)||isNaN(n));i--);return i-1}function pb(t,e){return[t[2*e],t[2*e+1]]}function db(t){if(t.get(["endLabel","show"]))return 1;for(var e=0;e<js.length;e++)if(t.get([js[e],"endLabel","show"]))return 1}function fb(n,i,e,t){if(ib(i,"cartesian2d")){var o,r,a=t.getModel("endLabel"),s=a.get("valueAnimation"),l=t.getData(),u={lastFrameIndex:0},h=db(t)?function(t,e){n._endLabelOnDuring(t,e,l,u,s,a,i)}:null,c=i.getBaseAxis().isHorizontal(),p=tb(i,e,t,function(){var t=n._endLabel;t&&e&&null!=u.originalX&&t.attr({x:u.originalX,y:u.originalY})},h);return t.get("clip",!0)||(o=p.shape,r=Math.max(o.width,o.height),c?(o.y-=r,o.height+=2*r):(o.x-=r,o.width+=2*r)),h&&h(1,p),p}return eb(i,e,t)}var gb,yb=(d(mb,gb=$d),mb.prototype.init=function(){var t=new ro,e=new O_;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},mb.prototype.render=function(t,e,n){var i=this,o=t.coordinateSystem,r=this.group,a=t.getData(),s=t.getModel("lineStyle"),l=t.getModel("areaStyle"),u=a.getLayout("points")||[],h="polar"===o.type,c=this._coordSys,p=this._symbolDraw,d=this._polyline,f=this._polygon,g=this._lineGroup,y=t.get("animation"),m=!l.isEmpty(),v=l.get("origin"),x=N_(o,a,v),_=m&&function(t,e,n){if(!n.valueDim)return[];for(var i=e.count(),o=B_(2*i),r=0;r<i;r++){var a=z_(n,t,e,r);o[2*r]=a[0],o[2*r+1]=a[1]}return o}(o,a,x),b=t.get("showSymbol"),w=b&&!h&&hb(t,a,o),S=this._data;S&&S.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),S.setItemGraphicEl(e,null))}),b||p.remove(),r.add(g);var M=!h&&t.get("step");o&&o.getArea&&t.get("clip",!0)&&(null!=(I=o.getArea()).width?(I.x-=.1,I.y-=.1,I.width+=.2,I.height+=.2):I.r0&&(I.r0-=.5,I.r+=.5)),this._clipShapeForSymbol=I;x=function(t,e,n){var i=t.getVisual("visualMeta");if(i&&i.length&&t.count()&&"cartesian2d"===e.type){for(var o,r=i.length-1;0<=r;r--){var a,s=t.getDimensionInfo(i[r].dimension);if("x"===(a=s&&s.coordDim)||"y"===a){o=i[r];break}}if(o){var l=e.getAxis(a),u=H(o.stops,function(t){return{coord:l.toGlobalCoord(l.dataToCoord(t.value)),color:t.color}}),h=u.length,c=o.outerColors.slice();h&&u[0].coord>u[h-1].coord&&(u.reverse(),c.reverse());e=ub(u,"x"===a?n.getWidth():n.getHeight()),n=e.length;if(!n&&h)return u[0].coord<0?c[1]||u[h-1].color:c[0]||u[0].color;var p=e[0].coord-10,u=e[n-1].coord+10,d=u-p;if(d<.001)return"transparent";G(e,function(t){t.offset=(t.coord-p)/d}),e.push({offset:n?e[n-1].offset:.5,color:c[1]||"transparent"}),e.unshift({offset:n?e[0].offset:.5,color:c[0]||"transparent"});e=new fy(0,0,0,0,e,!0);return e[a]=p,e[a+"2"]=u,e}}}(a,o,n)||a.getVisual("style")[a.getVisual("drawType")];d&&c.type===o.type&&M===this._step?(m&&!f?f=this._newPolygon(u,_):f&&!m&&(g.remove(f),f=this._polygon=null),h||this._initOrUpdateEndLabel(t,o,yh(x)),(c=g.getClipPath())?Ul(c,{shape:fb(this,o,!1,t).shape},t):g.setClipPath(fb(this,o,!0,t)),b&&p.updateData(a,{isIgnore:w,clipShape:I,disableAnimation:!0,getSymbolPoint:function(t){return[u[2*t],u[2*t+1]]}}),ob(this._stackedOnPoints,_)&&ob(this._points,u)||(y?this._doUpdateAnimation(a,_,o,n,M,v):(M&&(u=lb(u,o,M),_=_&&lb(_,o,M)),d.setShape({points:u}),f&&f.setShape({points:u,stackedOnPoints:_})))):(b&&p.updateData(a,{isIgnore:w,clipShape:I,disableAnimation:!0,getSymbolPoint:function(t){return[u[2*t],u[2*t+1]]}}),y&&this._initSymbolLabelAnimation(a,o,I),M&&(u=lb(u,o,M),_=_&&lb(_,o,M)),d=this._newPolyline(u),m&&(f=this._newPolygon(u,_)),h||this._initOrUpdateEndLabel(t,o,yh(x)),g.setClipPath(fb(this,o,!0,t)));w=t.get(["emphasis","focus"]),y=t.get(["emphasis","blurScope"]);d.useStyle(z(s.getLineStyle(),{fill:"none",stroke:x,lineJoin:"bevel"})),Nl(d,t,"lineStyle"),0<d.style.lineWidth&&"bolder"===t.get(["emphasis","lineStyle","width"])&&(d.getState("emphasis").style.lineWidth=+d.style.lineWidth+1),Gs(d).seriesIndex=t.seriesIndex,Ll(d,w,y);var I=sb(t.get("smooth")),m=t.get("smoothMonotone"),h=t.get("connectNulls");d.setShape({smooth:I,smoothMonotone:m,connectNulls:h}),f&&(g=a.getCalculationInfo("stackedOnSeries"),s=0,f.useStyle(z(l.getAreaStyle(),{fill:x,opacity:.7,lineJoin:"bevel",decal:a.getVisual("style").decal})),g&&(s=sb(g.get("smooth"))),f.setShape({smooth:I,stackedOnSmooth:s,smoothMonotone:m,connectNulls:h}),Nl(f,t,"areaStyle"),Gs(f).seriesIndex=t.seriesIndex,Ll(f,w,y));function T(t){i._changePolyState(t)}a.eachItemGraphicEl(function(t){t&&(t.onHoverStateChange=T)}),this._polyline.onHoverStateChange=T,this._data=a,this._coordSys=o,this._stackedOnPoints=_,this._points=u,this._step=M,this._valueOrigin=v,t.get("triggerLineEvent")&&(this.packEventData(t,d),f&&this.packEventData(t,f))},mb.prototype.packEventData=function(t,e){Gs(e).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},mb.prototype.highlight=function(t,e,n,i){var o=t.getData(),r=Xo(o,i);if(this._changePolyState("emphasis"),!(r instanceof Array)&&null!=r&&0<=r){var a=o.getLayout("points");if(!(u=o.getItemGraphicEl(r))){var s=a[2*r],l=a[2*r+1];if(isNaN(s)||isNaN(l))return;if(this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(s,l))return;var u,h=t.get("zlevel"),a=t.get("z");(u=new A_(o,r)).x=s,u.y=l,u.setZ(h,a);l=u.getSymbolPath().getTextContent();l&&(l.zlevel=h,l.z=a,l.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(r,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else $d.prototype.highlight.call(this,t,e,n,i)},mb.prototype.downplay=function(t,e,n,i){var o,r=t.getData(),a=Xo(r,i);this._changePolyState("normal"),null!=a&&0<=a?(o=r.getItemGraphicEl(a))&&(o.__temp?(r.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay()):$d.prototype.downplay.call(this,t,e,n,i)},mb.prototype._changePolyState=function(t){var e=this._polygon;dl(this._polyline,t),e&&dl(e,t)},mb.prototype._newPolyline=function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new j_({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(e),this._polyline=e},mb.prototype._newPolygon=function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new K_({shape:{points:t,stackedOnPoints:e},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n},mb.prototype._initSymbolLabelAnimation=function(t,l,u){var h,c,e=l.getBaseAxis(),p=e.inverse;"cartesian2d"===l.type?(h=e.isHorizontal(),c=!1):"polar"===l.type&&(h="angle"===e.dim,c=!0);var e=t.hostModel,d=e.get("animationDuration");"function"==typeof d&&(d=d(null));var f=e.get("animationDelay")||0,g="function"==typeof f?f(null):f;t.eachItemGraphicEl(function(t,e){var n,i,o,r,a,s=t;s&&(i=[t.x,t.y],o=a=r=void 0,u&&(o=c?(n=u,i=l.pointToCoord(i),h?(r=n.startAngle,a=n.endAngle,-i[1]/180*Math.PI):(r=n.r0,a=n.r,i[0])):h?(r=u.x,a=u.x+u.width,t.x):(r=u.y+u.height,a=u.y,t.y)),a=a===r?0:(o-r)/(a-r),p&&(a=1-a),r="function"==typeof f?f(e):d*a+g,a=(e=s.getSymbolPath()).getTextContent(),s.attr({scaleX:0,scaleY:0}),s.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:r}),a&&a.animateFrom({style:{opacity:0}},{duration:300,delay:r}),e.disableLabelAnimation=!0)})},mb.prototype._initOrUpdateEndLabel=function(t,e,n){var i,o,r,a=t.getModel("endLabel");db(t)?(i=t.getData(),o=this._polyline,this._endLabel||((this._endLabel=new Fs({z2:200})).ignoreClip=!0,o.setTextContent(this._endLabel),o.disableLabelAnimation=!0),0<=(r=cb(i.getLayout("points")))&&($l(o,tu(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:r,defaultText:function(t,e,n){return null!=n?T_(i,n):I_(i,t)},enableTextSetter:!0},(t=a,e=(a=(r=e).getBaseAxis()).isHorizontal(),r=a.inverse,a=e?r?"right":"left":"center",r=e?"middle":r?"top":"bottom",{normal:{align:t.get("align")||a,verticalAlign:t.get("verticalAlign")||r}})),o.textConfig.position=null)):this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},mb.prototype._endLabelOnDuring=function(t,e,n,i,o,r,a){var s,l,u,h,c,p,d,f,g,y,m=this._endLabel,v=this._polyline;m&&(t<1&&null==i.originalX&&(i.originalX=m.x,i.originalY=m.y),s=n.getLayout("points"),u=(l=n.hostModel).get("connectNulls"),h=r.get("precision"),f=r.get("distance")||0,p=(d=a.getBaseAxis()).isHorizontal(),c=d.inverse,g=e.shape,r=(p?f:0)*(c?-1:1),a=(p?0:-f)*(c?-1:1),d=void 0,1<=(p=(g=(c=function(t,e,n){for(var i,o,r=t.length/2,a="x"===n?0:1,s=0,l=-1,u=0;u<r;u++)if(o=t[2*u+a],!isNaN(o)&&!isNaN(t[2*u+1-a]))if(0!==u){if(i<=e&&e<=o||e<=i&&o<=e){l=u;break}s=u,i=o}else i=o;return{range:[s,l],t:(e-i)/(o-i)}}(s,e=c?p?g.x:g.y+g.height:p?g.x+g.width:g.y,f=p?"x":"y")).range)[1]-g[0])?(1<p&&!u?(y=pb(s,g[0]),m.attr({x:y[0]+r,y:y[1]+a}),o&&(d=l.getRawValue(g[0]))):((y=v.getPointOn(e,f))&&m.attr({x:y[0]+r,y:y[1]+a}),e=l.getRawValue(g[0]),f=l.getRawValue(g[1]),o&&(d=nr(n,h,e,f,c.t))),i.lastFrameIndex=g[0]):(y=pb(s,g=1===t||0<i.lastFrameIndex?g[0]:0),o&&(d=l.getRawValue(g)),m.attr({x:y[0]+r,y:y[1]+a})),o&&lu(m).setLabelText(d))},mb.prototype._doUpdateAnimation=function(t,e,n,i,o,r){var a=this._polyline,s=this._polygon,l=t.hostModel,u=function(t,e,n,i,o,r){for(var a,s=(a=[],e.diff(t).add(function(t){a.push({cmd:"+",idx:t})}).update(function(t,e){a.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){a.push({cmd:"-",idx:t})}).execute(),a),l=[],u=[],h=[],c=[],p=[],d=[],f=[],g=N_(o,e,r),y=t.getLayout("points")||[],m=e.getLayout("points")||[],v=0;v<s.length;v++){var x=s[v],_=!0,b=void 0;switch(x.cmd){case"=":var w=2*x.idx,b=2*x.idx1,S=y[w],M=y[1+w],I=m[b],T=m[b+1];(isNaN(S)||isNaN(M))&&(S=I,M=T),l.push(S,M),u.push(I,T),h.push(n[w],n[1+w]),c.push(i[b],i[b+1]),f.push(e.getRawIndex(x.idx1));break;case"+":T=x.idx,w=g.dataDimsForPoint,w=o.dataToPoint([e.get(w[0],T),e.get(w[1],T)]);b=2*T,l.push(w[0],w[1]),u.push(m[b],m[b+1]);w=z_(g,o,e,T);h.push(w[0],w[1]),c.push(i[b],i[b+1]),f.push(e.getRawIndex(T));break;case"-":_=!1}_&&(p.push(x),d.push(d.length))}d.sort(function(t,e){return f[t]-f[e]});for(var C=B_(t=l.length),D=B_(t),A=B_(t),k=B_(t),L=[],v=0;v<d.length;v++){var P=d[v],O=2*v,R=2*P;C[O]=l[R],C[1+O]=l[1+R],D[O]=u[R],D[1+O]=u[1+R],A[O]=h[R],A[1+O]=h[1+R],k[O]=c[R],k[1+O]=c[1+R],L[v]=p[P]}return{current:C,next:D,stackedOnCurrent:A,stackedOnNext:k,status:L}}(this._data,t,this._stackedOnPoints,e,this._coordSys,this._valueOrigin),h=u.current,c=u.stackedOnCurrent,p=u.next,e=u.stackedOnNext;if(o&&(h=lb(u.current,n,o),c=lb(u.stackedOnCurrent,n,o),p=lb(u.next,n,o),e=lb(u.stackedOnNext,n,o)),3e3<ab(h,p)||s&&3e3<ab(c,e))return a.stopAnimation(),a.setShape({points:p}),void(s&&(s.stopAnimation(),s.setShape({points:p,stackedOnPoints:e})));a.shape.__points=u.current,a.shape.points=h;p={shape:{points:p}};u.current!==h&&(p.shape.__points=u.next),a.stopAnimation(),Wl(a,p,l),s&&(s.setShape({points:h,stackedOnPoints:c}),s.stopAnimation(),Wl(s,{shape:{stackedOnPoints:e}},l),a.shape.points!==s.shape.points&&(s.shape.points=a.shape.points));for(var d,f=[],g=u.status,y=0;y<g.length;y++)"="!==g[y].cmd||(d=t.getItemGraphicEl(g[y].idx1))&&f.push({el:d,ptIdx:y});a.animators&&a.animators.length&&a.animators[0].during(function(){s&&s.dirtyShape();for(var t=a.shape.__points,e=0;e<f.length;e++){var n=f[e].el,i=2*f[e].ptIdx;n.x=t[i],n.y=t[1+i],n.markRedraw()}})},mb.prototype.remove=function(t){var n=this.group,i=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),i&&i.eachItemGraphicEl(function(t,e){t.__temp&&(n.remove(t),i.setItemGraphicEl(e,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},mb.type="line",mb);function mb(){return null!==gb&&gb.apply(this,arguments)||this}function vb(t,i){return{seriesType:t,plan:Ud(),reset:function(t){var e=t.getData(),h=t.coordinateSystem,n=t.pipelineContext,c=i||n.large;if(h){var t=H(h.dimensions,function(t){return e.mapDimension(t)}).slice(0,2),p=t.length,n=e.getCalculationInfo("stackResultDimension");v_(e,t[0])&&(t[0]=n),v_(e,t[1])&&(t[1]=n);var d=e.getStore(),f=e.getDimensionIndex(t[0]),g=e.getDimensionIndex(t[1]);return p&&{progress:function(t,e){for(var n=t.end-t.start,i=c&&B_(n*p),o=[],r=[],a=t.start,s=0;a<t.end;a++){var l,u=void 0;u=1===p?(l=d.get(f,a),h.dataToPoint(l,null,r)):(o[0]=d.get(f,a),o[1]=d.get(g,a),h.dataToPoint(o,null,r)),c?(i[s++]=u[0],i[s++]=u[1]):e.setItemLayout(a,u.slice())}c&&e.setLayout("points",i)}}}}}}var xb={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]}},_b=function(t){return Math.round(t.length/2)};function bb(t){return{seriesType:t,reset:function(t,e,n){var i,o=t.getData(),r=t.get("sampling"),a=t.coordinateSystem,s=o.count();10<s&&"cartesian2d"===a.type&&r&&(i=a.getBaseAxis(),a=a.getOtherAxis(i),i=i.getExtent(),n=n.getDevicePixelRatio(),n=Math.abs(i[1]-i[0])*(n||1),1<(s=Math.round(s/n))&&("lttb"===r&&t.setData(o.lttbDownSample(o.mapDimension(a.dim),1/s)),n=void 0,"string"==typeof r?n=xb[r]:"function"==typeof r&&(n=r),n&&t.setData(o.downSample(o.mapDimension(a.dim),1/s,n,_b))))}}}var wb="__ec_stack_",Sb="undefined"!=typeof Float32Array?Float32Array:Array;function Mb(t){return t.get("stack")||wb+t.seriesIndex}function Ib(t){return t.dim+t.index}function Tb(t,e){var n=[];return e.eachSeriesByType(t,function(t){Pb(t)&&!Ob(t)&&n.push(t)}),n}function Cb(t){var l=function(t){var l={};G(t,function(t){var e=t.coordinateSystem.getBaseAxis();if("time"===e.type||"value"===e.type)for(var t=t.getData(),n=e.dim+"_"+e.index,i=t.getDimensionIndex(t.mapDimension(e.dim)),o=t.getStore(),r=0,a=o.count();r<a;++r){var s=o.get(i,r);l[n]?l[n].push(s):l[n]=[s]}});var e,n={};for(e in l)if(l.hasOwnProperty(e)){var i=l[e];if(i){i.sort(function(t,e){return t-e});for(var o=null,r=1;r<i.length;++r){var a=i[r]-i[r-1];0<a&&(o=null===o?a:Math.min(o,a))}n[e]=o}}return n}(t),u=[];return G(t,function(t){var e,n=t.coordinateSystem.getBaseAxis(),i=n.getExtent();e="category"===n.type?n.getBandWidth():"value"===n.type||"time"===n.type?(o=n.dim+"_"+n.index,r=l[o],a=Math.abs(i[1]-i[0]),e=n.scale.getExtent(),o=Math.abs(e[1]-e[0]),r?a/o*r:a):(s=t.getData(),Math.abs(i[1]-i[0])/s.count());var o=go(t.get("barWidth"),e),r=go(t.get("barMaxWidth"),e),a=go(t.get("barMinWidth")||1,e),i=t.get("barGap"),s=t.get("barCategoryGap");u.push({bandWidth:e,barWidth:o,barMaxWidth:r,barMinWidth:a,barGap:i,barCategoryGap:s,axisKey:Ib(n),stackId:Mb(t)})}),Db(u)}function Db(t){var a={};G(t,function(t,e){var n=t.axisKey,i=t.bandWidth,o=a[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},r=o.stacks;a[n]=o;i=t.stackId;r[i]||o.autoWidthCount++,r[i]=r[i]||{width:0,maxWidth:0};n=t.barWidth;n&&!r[i].width&&(r[i].width=n,n=Math.min(o.remainedWidth,n),o.remainedWidth-=n);n=t.barMaxWidth;n&&(r[i].maxWidth=n);n=t.barMinWidth;n&&(r[i].minWidth=n);n=t.barGap;null!=n&&(o.gap=n);t=t.barCategoryGap;null!=t&&(o.categoryGap=t)});var d={};return G(a,function(t,n){d[n]={};var e,i=t.stacks,o=t.bandWidth,r=t.categoryGap;null==r&&(e=Y(i).length,r=Math.max(35-4*e,15)+"%");var r=go(r,o),a=go(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,u=(s-r)/(l+(l-1)*a),u=Math.max(u,0);G(i,function(t){var e,n=t.maxWidth,i=t.minWidth;t.width?(e=t.width,n&&(e=Math.min(e,n)),i&&(e=Math.max(e,i)),t.width=e,s-=e+a*e,l--):(e=u,n&&n<e&&(e=Math.min(n,s)),(e=i&&e<i?i:e)!==u&&(t.width=e,s-=e+a*e,l--))}),u=(s-r)/(l+(l-1)*a),u=Math.max(u,0);var h,c=0;G(i,function(t,e){t.width||(t.width=u),c+=(h=t).width*(1+a)}),h&&(c-=h.width*a);var p=-c/2;G(i,function(t,e){d[n][e]=d[n][e]||{bandWidth:o,offset:p,width:t.width},p+=t.width*(1+a)})}),d}function Ab(t,e,n){if(t&&e){e=t[Ib(e)];return null!=e&&null!=n?e[Mb(n)]:e}}function kb(t,e){var e=Tb(t,e),C=Cb(e),D={};G(e,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),o=Mb(t),r=C[Ib(i)][o],a=r.offset,s=r.width,l=n.getOtherAxis(i),u=t.get("barMinHeight")||0;D[o]=D[o]||[],e.setLayout({bandWidth:r.bandWidth,offset:a,size:s});for(var t=e.mapDimension(l.dim),r=e.mapDimension(i.dim),h=v_(e,t),c=l.isHorizontal(),p=Rb(0,l),d=e.getStore(),f=e.getDimensionIndex(t),g=e.getDimensionIndex(r),y=0,m=d.count();y<m;y++){var v=d.get(f,y),x=d.get(g,y),_=0<=v?"p":"n",b=p;h&&(D[o][x]||(D[o][x]={p:p,n:p}),b=D[o][x][_]);var w,S=void 0,M=void 0,I=void 0,T=void 0;c?(S=b,M=(w=n.dataToPoint([v,x]))[1]+a,I=w[0]-p,T=s,Math.abs(I)<u&&(I=(I<0?-1:1)*u),isNaN(I)||h&&(D[o][x][_]+=I)):(S=(w=n.dataToPoint([x,v]))[0]+a,M=b,I=s,T=w[1]-p,Math.abs(T)<u&&(T=(T<=0?-1:1)*u),isNaN(T)||h&&(D[o][x][_]+=T)),e.setItemLayout(y,{x:S,y:M,width:I,height:T})}})}var Lb={seriesType:"bar",plan:Ud(),reset:function(t){if(Pb(t)&&Ob(t)){var e=t.getData(),p=t.coordinateSystem,d=p.master.getRect(),n=p.getBaseAxis(),f=p.getOtherAxis(n),g=e.getDimensionIndex(e.mapDimension(f.dim)),y=e.getDimensionIndex(e.mapDimension(n.dim)),m=f.isHorizontal(),v=m?0:1,x=Ab(Cb([t]),n,t).width;return.5<x||(x=.5),{progress:function(t,e){for(var n,i,o=t.count,r=new Sb(2*o),a=new Sb(2*o),s=new Sb(o),l=[],u=0,h=0,c=e.getStore();null!=(n=t.next());)l[v]=c.get(g,n),l[1-v]=c.get(y,n),i=p.dataToPoint(l,null),a[u]=m?d.x+d.width:i[0],r[u++]=i[0],a[u]=m?i[1]:d.y+d.height,r[u++]=i[1],s[h++]=n;e.setLayout({largePoints:r,largeDataIndices:s,largeBackgroundPoints:a,barWidth:x,valueAxisStart:Rb(0,f),backgroundStart:m?d.x:d.y,valueAxisHorizontal:m})}}}}};function Pb(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}function Ob(t){return t.pipelineContext&&t.pipelineContext.large}function Rb(t,e){return e.toGlobalCoord(e.dataToCoord("log"===e.type?1:0))}var Nb,C=(d(zb,Nb=Gd),zb.prototype.getInitialData=function(t,e){return w_(null,this,{useEncodeDefaulter:!0})},zb.prototype.getMarkerPosition=function(t){var e=this.coordinateSystem;if(e&&e.clampData){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),t=i.getLayout("offset"),i=i.getLayout("size");return n[e.getBaseAxis().isHorizontal()?0:1]+=t+i/2,n}return[NaN,NaN]},zb.type="series.__base_bar__",zb.defaultOption={zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},zb);function zb(){var t=null!==Nb&&Nb.apply(this,arguments)||this;return t.type=zb.type,t}Gd.registerClass(C);var Eb,Vb,io=C,Bb=(d(Wb,Vb=io),Wb.prototype.getInitialData=function(){return w_(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},Wb.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},Wb.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return t=t<e?e:t},Wb.prototype.brushSelector=function(t,e,n){return n.rect(e.getItemLayout(t))},Wb.type="series.bar",Wb.dependencies=["grid","polar"],Wb.defaultOption=Iu(io.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),Wb),Fb=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},Gb=(d(Hb,Eb=as),Hb.prototype.getDefaultShape=function(){return new Fb},Hb.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=Math.max(e.r0||0,0),r=Math.max(e.r,0),a=.5*(r-o),s=o+a,l=e.startAngle,u=e.endAngle,h=e.clockwise,c=Math.cos(l),p=Math.sin(l),d=Math.cos(u),e=Math.sin(u);(h?u-l<2*Math.PI:l-u<2*Math.PI)&&(t.moveTo(c*o+n,p*o+i),t.arc(c*s+n,p*s+i,a,-Math.PI+l,l,!h)),t.arc(n,i,r,l,u,!h),t.moveTo(d*r+n,e*r+i),t.arc(d*s+n,e*s+i,a,u-2*Math.PI,u-Math.PI,!h),0!==o&&(t.arc(n,i,o,u,l,h),t.moveTo(c*o+n,e*o+i)),t.closePath()},Hb);function Hb(t){t=Eb.call(this,t)||this;return t.type="sausage",t}function Wb(){var t=null!==Vb&&Vb.apply(this,arguments)||this;return t.type=Wb.type,t}function Ub(t,e,n){return e*Math.sin(t)*(n?-1:1)}function Yb(t,e,n){return e*Math.cos(t)*(n?1:-1)}var Xb=[0,0],Zb=Math.max,jb=Math.min;var qb,Jn=(d(Qb,qb=$d),Qb.prototype.render=function(t,e,n,i){this._model=t,this._removeOnRenderedListener(n),this._updateDrawMode(t);var o=t.get("coordinateSystem");"cartesian2d"!==o&&"polar"!==o||(this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n,i))},Qb.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},Qb.prototype.incrementalRender=function(t,e){this._incrementalRenderLarge(t,e)},Qb.prototype._updateDrawMode=function(t){t=t.pipelineContext.large;null!=this._isLargeDraw&&t===this._isLargeDraw||(this._isLargeDraw=t,this._clear())},Qb.prototype._renderNormal=function(a,t,e,n){var s,l=this.group,u=a.getData(),h=this._data,c=a.coordinateSystem,p=c.getBaseAxis();"cartesian2d"===c.type?s=p.isHorizontal():"polar"===c.type&&(s="angle"===p.dim);var d=a.isAnimationEnabled()?a:null,f=function(t,e){var n=t.get("realtimeSort",!0),t=e.getBaseAxis();if(n&&"category"===t.type&&"cartesian2d"===e.type)return{baseAxis:t,otherAxis:e.getOtherAxis(t)}}(a,c);f&&this._enableRealtimeSort(f,u,e);var i,o,g=a.get("clip",!0)||f,y=(o=u,e=(i=c).getArea&&i.getArea(),ib(i,"cartesian2d")&&("category"===(i=i.getBaseAxis()).type&&i.onBand||(o=o.getLayout("bandWidth"),i.isHorizontal()?(e.x-=o,e.width+=2*o):(e.y-=o,e.height+=2*o))),e);l.removeClipPath();var m=a.get("roundCap",!0),v=a.get("showBackground",!0),x=a.getModel("backgroundStyle"),_=x.get("borderRadius")||0,b=[],w=this._backgroundEls,S=n&&n.isInitSort,M=n&&"changeAxisOrder"===n.type;function I(t){var e,n=ow[c.type](u,t),n=(e=s,new("polar"===c.type?Wg:Ts)({shape:dw(e,n,c),silent:!0,z2:0}));return n.useStyle(x.getItemStyle()),"cartesian2d"===c.type&&n.setShape("r",_),b[t]=n}u.diff(h).add(function(t){var e,n,i=u.getItemModel(t),o=ow[c.type](u,t,i);v&&I(t),u.hasValue(t)&&iw[c.type](o)&&(e=!1,g&&(e=Kb[c.type](y,o)),n=Jb[c.type](a,u,t,o,s,d,p.model,!1,m),f&&(n.forceLabelAnimation=!0),aw(n,u,t,i,o,a,s,"polar"===c.type),S?n.attr({shape:o}):f?$b(f,d,n,o,t,s,!1,!1):Ul(n,{shape:o},a,t),u.setItemGraphicEl(t,n),l.add(n),n.ignore=e)}).update(function(t,e){var n=u.getItemModel(t),i=ow[c.type](u,t,n);v&&(r=void 0,0===w.length?r=I(e):((r=w[e]).useStyle(x.getItemStyle()),"cartesian2d"===c.type&&r.setShape("r",_),b[t]=r),o=ow[c.type](u,t),Wl(r,{shape:dw(s,o,c)},d,t));var o,r=h.getItemGraphicEl(e);u.hasValue(t)&&iw[c.type](i)?(o=!1,!g||(o=Kb[c.type](y,i))&&l.remove(r),r?ql(r):r=Jb[c.type](a,u,t,i,s,d,p.model,!!r,m),f&&(r.forceLabelAnimation=!0),M&&(!(e=r.getTextContent())||null!=(e=lu(e)).prevValue&&(e.prevValue=e.value)),M||aw(r,u,t,n,i,a,s,"polar"===c.type),S?r.attr({shape:i}):f?$b(f,d,r,i,t,s,!0,M):Wl(r,{shape:i},a,t,null),u.setItemGraphicEl(t,r),r.ignore=o,l.add(r)):l.remove(r)}).remove(function(t){var e=h.getItemGraphicEl(t);e&&jl(e,a,t)}).execute();var r=this._backgroundGroup||(this._backgroundGroup=new ro);r.removeAll();for(var T=0;T<b.length;++T)r.add(b[T]);l.add(r),this._backgroundEls=b,this._data=u},Qb.prototype._renderLarge=function(t,e,n){this._clear(),cw(t,this.group),this._updateLargeClip(t)},Qb.prototype._incrementalRenderLarge=function(t,e){this._removeBackground(),cw(e,this.group,!0)},Qb.prototype._updateLargeClip=function(t){t=t.get("clip",!0)?nb(t.coordinateSystem,!1,t):null;t?this.group.setClipPath(t):this.group.removeClipPath()},Qb.prototype._enableRealtimeSort=function(t,e,n){var i,o,r=this;e.count()&&(i=t.baseAxis,this._isFirstFrame?(this._dispatchInitSort(e,t,n),this._isFirstFrame=!1):(o=function(t){t=e.getItemGraphicEl(t);if(t){t=t.shape;return(i.isHorizontal()?Math.abs(t.height):Math.abs(t.width))||0}return 0},this._onRendered=function(){r._updateSortWithinSameData(e,o,i,n)},n.getZr().on("rendered",this._onRendered)))},Qb.prototype._dataSort=function(t,e,i){var o=[];return t.each(t.mapDimension(e.dim),function(t,e){var n=null==(n=i(e))?NaN:n;o.push({dataIndex:e,mappedValue:n,ordinalNumber:t})}),o.sort(function(t,e){return e.mappedValue-t.mappedValue}),{ordinalNumbers:H(o,function(t){return t.ordinalNumber})}},Qb.prototype._isOrderChangedWithinSameData=function(t,e,n){for(var i=n.scale,o=t.mapDimension(n.dim),r=Number.MAX_VALUE,a=0,s=i.getOrdinalMeta().categories.length;a<s;++a){var l=t.rawIndexOf(o,i.getRawOrdinalNumber(a)),l=l<0?Number.MIN_VALUE:e(t.indexOfRawIndex(l));if(r<l)return!0;r=l}return!1},Qb.prototype._isOrderDifferentInView=function(t,e){for(var n=e.scale,e=n.getExtent(),i=Math.max(0,e[0]),o=Math.min(e[1],n.getOrdinalMeta().categories.length-1);i<=o;++i)if(t.ordinalNumbers[i]!==n.getRawOrdinalNumber(i))return!0},Qb.prototype._updateSortWithinSameData=function(t,e,n,i){this._isOrderChangedWithinSameData(t,e,n)&&(e=this._dataSort(t,n,e),this._isOrderDifferentInView(e,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:e})))},Qb.prototype._dispatchInitSort=function(e,n,t){var i=n.baseAxis,o=this._dataSort(e,i,function(t){return e.get(e.mapDimension(n.otherAxis.dim),t)});t.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},Qb.prototype.remove=function(t,e){this._clear(this._model),this._removeOnRenderedListener(e)},Qb.prototype.dispose=function(t,e){this._removeOnRenderedListener(e)},Qb.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},Qb.prototype._clear=function(e){var t=this.group,n=this._data;e&&e.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(t){jl(t,e,Gs(t).dataIndex)})):t.removeAll(),this._data=null,this._isFirstFrame=!0},Qb.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},Qb.type="bar",Qb),Kb={cartesian2d:function(t,e){var n=e.width<0?-1:1,i=e.height<0?-1:1;n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height);var o=t.x+t.width,r=t.y+t.height,a=Zb(e.x,t.x),s=jb(e.x+e.width,o),l=Zb(e.y,t.y),u=jb(e.y+e.height,r),h=s<a,t=u<l;return e.x=h&&o<a?s:a,e.y=t&&r<l?u:l,e.width=h?0:s-a,e.height=t?0:u-l,n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),h||t},polar:function(t,e){var n,i=e.r0<=e.r?1:-1;i<0&&(n=e.r,e.r=e.r0,e.r0=n);var o=jb(e.r,t.r),t=Zb(e.r0,t.r0),t=(e.r=o)-(e.r0=t)<0;return i<0&&(n=e.r,e.r=e.r0,e.r0=n),t}},Jb={cartesian2d:function(t,e,n,i,o,r,a,s,l){i=new Ts({shape:N({},i),z2:1});return i.__dataIndex=n,i.name="item",r&&(i.shape[o?"height":"width"]=0),i},polar:function(t,e,n,i,o,r,a,s,l){var u=!o&&l?Gb:Wg,h=new u({shape:i,z2:1});h.name="item";var b,w,l=rw(o);return h.calculateTextPosition=(b=l,w=({isRoundCap:u===Gb}||{}).isRoundCap,function(t,e,n){var i=e.position;if(!i||i instanceof Array)return Ui(t,e,n);var o=b(i),r=null!=e.distance?e.distance:5,i=this.shape,a=i.cx,s=i.cy,l=i.r,u=i.r0,h=(l+u)/2,c=i.startAngle,p=i.endAngle,d=(c+p)/2,f=w?Math.abs(l-u)/2:0,g=Math.cos,y=Math.sin,m=a+l*g(c),v=s+l*y(c),x="left",_="top";switch(o){case"startArc":m=a+(u-r)*g(d),v=s+(u-r)*y(d),x="center",_="top";break;case"insideStartArc":m=a+(u+r)*g(d),v=s+(u+r)*y(d),x="center",_="bottom";break;case"startAngle":m=a+h*g(c)+Ub(c,r+f,!1),v=s+h*y(c)+Yb(c,r+f,!1),x="right",_="middle";break;case"insideStartAngle":m=a+h*g(c)+Ub(c,f-r,!1),v=s+h*y(c)+Yb(c,f-r,!1),x="left",_="middle";break;case"middle":m=a+h*g(d),v=s+h*y(d),x="center",_="middle";break;case"endArc":m=a+(l+r)*g(d),v=s+(l+r)*y(d),x="center",_="bottom";break;case"insideEndArc":m=a+(l-r)*g(d),v=s+(l-r)*y(d),x="center",_="top";break;case"endAngle":m=a+h*g(p)+Ub(p,r+f,!0),v=s+h*y(p)+Yb(p,r+f,!0),x="left",_="middle";break;case"insideEndAngle":m=a+h*g(p)+Ub(p,f-r,!0),v=s+h*y(p)+Yb(p,f-r,!0),x="right",_="middle";break;default:return Ui(t,e,n)}return(t=t||{}).x=m,t.y=v,t.align=x,t.verticalAlign=_,t}),r&&(l={},h.shape[u=o?"r":"endAngle"]=o?0:i.startAngle,l[u]=i[u],(s?Wl:Ul)(h,{shape:l},r)),h}};function Qb(){var t=qb.call(this)||this;return t.type=Qb.type,t._isFirstFrame=!0,t}function $b(t,e,n,i,o,r,a,s){var l,i=r?(l={x:i.x,width:i.width},{y:i.y,height:i.height}):(l={y:i.y,height:i.height},{x:i.x,width:i.width});s||(a?Wl:Ul)(n,{shape:i},e,o,null),(a?Wl:Ul)(n,{shape:l},e?t.baseAxis.model:null,o)}function tw(t,e){for(var n=0;n<e.length;n++)if(!isFinite(t[e[n]]))return 1}var ew=["x","y","width","height"],nw=["cx","cy","r","startAngle","endAngle"],iw={cartesian2d:function(t){return!tw(t,ew)},polar:function(t){return!tw(t,nw)}},ow={cartesian2d:function(t,e,n){var i=t.getItemLayout(e),t=n?function(t,e){var n=t.get(["itemStyle","borderColor"]);if(!n||"none"===n)return 0;n=t.get(["itemStyle","borderWidth"])||0,t=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),e=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height);return Math.min(n,t,e)}(n,i):0,e=0<i.width?1:-1,n=0<i.height?1:-1;return{x:i.x+e*t/2,y:i.y+n*t/2,width:i.width-e*t,height:i.height-n*t}},polar:function(t,e,n){e=t.getItemLayout(e);return{cx:e.cx,cy:e.cy,r0:e.r0,r:e.r,startAngle:e.startAngle,endAngle:e.endAngle,clockwise:e.clockwise}}};function rw(t){return e=t?"Arc":"Angle",function(t){switch(t){case"start":case"insideStart":case"end":case"insideEnd":return t+e;default:return t}};var e}function aw(t,e,n,i,o,r,a,s){var l=e.getItemVisual(n,"style");s||t.setShape("r",i.get(["itemStyle","borderRadius"])||0),t.useStyle(l);var u=i.getShallow("cursor");u&&t.attr("cursor",u);var h=s?a?o.r>=o.r0?"endArc":"startArc":o.endAngle>=o.startAngle?"endAngle":"startAngle":a?0<=o.height?"bottom":"top":0<=o.width?"right":"left",u=tu(i);$l(t,u,{labelFetcher:r,labelDataIndex:n,defaultText:I_(r.getData(),n),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:h});l=t.getTextContent();s&&l&&(s=i.get(["label","position"]),t.textConfig.inside="middle"===s||null,function(t,e,n,i){if("number"!=typeof i)if(j(e))t.setTextConfig({rotation:0});else{var o,r=t.shape,a=r.clockwise?r.startAngle:r.endAngle,s=r.clockwise?r.endAngle:r.startAngle,l=(a+s)/2,n=n(e);switch(n){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":o=l;break;case"startAngle":case"insideStartAngle":o=a;break;case"endAngle":case"insideEndAngle":o=s;break;default:return t.setTextConfig({rotation:0})}e=1.5*Math.PI-o;"middle"===n&&e>Math.PI/2&&e<1.5*Math.PI&&(e-=Math.PI),t.setTextConfig({rotation:e})}else t.setTextConfig({rotation:i})}(t,"outside"===s?h:s,rw(a),i.get(["label","rotate"]))),uu(l,u,r.getRawValue(n),function(t){return T_(e,t)});n=i.getModel(["emphasis"]);Ll(t,n.get("focus"),n.get("blurScope")),Nl(t,i),null!=(o=o).startAngle&&null!=o.endAngle&&o.startAngle===o.endAngle&&(t.style.fill="none",t.style.stroke="none",G(t.states,function(t){t.style&&(t.style.fill=t.style.stroke="none")}))}var sw,lw=function(){},uw=(d(hw,sw=as),hw.prototype.getDefaultShape=function(){return new lw},hw.prototype.buildPath=function(t,e){for(var n=e.points,i=this.__startPoint,o=this.__baseDimIdx,r=0;r<n.length;r+=2)i[o]=n[r+o],t.moveTo(i[0],i[1]),t.lineTo(n[r],n[r+1])},hw);function hw(t){t=sw.call(this,t)||this;return t.type="largeBar",t}function cw(t,e,n){var i=t.getData(),o=[],r=i.getLayout("valueAxisHorizontal")?1:0;o[1-r]=i.getLayout("valueAxisStart");var a,s,l,u,h=i.getLayout("largeDataIndices"),c=i.getLayout("barWidth"),p=t.getModel("backgroundStyle");t.get("showBackground",!0)&&(u=i.getLayout("largeBackgroundPoints"),(l=[])[1-r]=i.getLayout("backgroundStart"),(a=new uw({shape:{points:u},incremental:!!n,silent:!0,z2:0})).__startPoint=l,a.__baseDimIdx=r,a.__largeDataIndices=h,a.__barWidth=c,s=a,u=i,p=(l=p).get("borderColor")||l.get("color"),l=l.getItemStyle(),s.useStyle(l),s.style.fill=null,s.style.stroke=p,s.style.lineWidth=u.getLayout("barWidth"),e.add(a));n=new uw({shape:{points:i.getLayout("largePoints")},incremental:!!n});n.__startPoint=o,n.__baseDimIdx=r,n.__largeDataIndices=h,n.__barWidth=c,e.add(n),c=n,i=(e=i).getVisual("style"),c.useStyle(N({},i)),c.style.fill=null,c.style.stroke=i.fill,c.style.lineWidth=e.getLayout("barWidth"),Gs(n).seriesIndex=t.seriesIndex,t.get("silent")||(n.on("mousedown",pw),n.on("mousemove",pw))}var pw=of(function(t){t=function(t,e,n){var i=t.__baseDimIdx,o=1-i,r=t.shape.points,a=t.__largeDataIndices,s=Math.abs(t.__barWidth/2),l=t.__startPoint[o];Xb[0]=e,Xb[1]=n;for(var n=Xb[i],u=Xb[1-i],h=n-s,c=n+s,p=0,d=r.length/2;p<d;p++){var f=2*p,g=r[f+i],f=r[f+o];if(h<=g&&g<=c&&(l<=f?l<=u&&u<=f:f<=u&&u<=l))return a[p]}return-1}(this,t.offsetX,t.offsetY);Gs(this).dataIndex=0<=t?t:null},30,!1);function dw(t,e,n){if(ib(n,"cartesian2d")){var i=e,o=n.getArea();return{x:(t?i:o).x,y:(t?o:i).y,width:(t?i:o).width,height:(t?o:i).height}}return{cx:(o=n.getArea()).cx,cy:o.cy,r0:(t?o:e).r0,r:(t?o:e).r,startAngle:t?e.startAngle:0,endAngle:t?e.endAngle:2*Math.PI}}var fw=Jn;var gw=2*Math.PI,yw=Math.PI/180;function mw(t,e){return Sh(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function vw(t,e){var n=mw(t,e),i=t.get("center"),o=t.get("radius");j(o)||(o=[0,o]),j(i)||(i=[i,i]);var r=go(n.width,e.getWidth()),t=go(n.height,e.getHeight()),e=Math.min(r,t);return{cx:go(i[0],r)+n.x,cy:go(i[1],t)+n.y,r0:go(o[0],e/2),r:go(o[1],e/2)}}function xw(t,e,S){e.eachSeriesByType(t,function(t){var o=t.getData(),e=o.mapDimension("value"),n=mw(t,S),i=vw(t,S),r=i.cx,a=i.cy,s=i.r,l=i.r0,u=-t.get("startAngle")*yw,h=t.get("minAngle")*yw,c=0;o.each(e,function(t){isNaN(t)||c++});var p=o.getSum(e),d=Math.PI/(p||c)*2,f=t.get("clockwise"),g=t.get("roseType"),y=t.get("stillShowZeroSum"),m=o.getDataExtent(e);m[0]=0;var v,x=gw,_=0,b=u,w=f?1:-1;o.setLayout({viewRect:n,r:s}),o.each(e,function(t,e){var n,i;isNaN(t)?o.setItemLayout(e,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:f,cx:r,cy:a,r0:l,r:g?NaN:s}):((n="area"!==g?0===p&&y?d:t*d:gw/c)<h?x-=n=h:_+=t,i=b+w*n,o.setItemLayout(e,{angle:n,startAngle:b,endAngle:i,clockwise:f,cx:r,cy:a,r0:l,r:g?fo(t,m,[l,s]):s}),b=i)}),x<gw&&c&&(x<=.001?(v=gw/c,o.each(e,function(t,e){isNaN(t)||((t=o.getItemLayout(e)).angle=v,t.startAngle=u+w*e*v,t.endAngle=u+w*(e+1)*v)})):(d=x/_,b=u,o.each(e,function(t,e){isNaN(t)||(t=(e=o.getItemLayout(e)).angle===h?h:t*d,e.startAngle=b,e.endAngle=b+w*t,b+=w*t)})))})}function _w(t){return{seriesType:t,reset:function(t,e){var i,o=e.findComponents({mainType:"legend"});o&&o.length&&(i=t.getData()).filterSelf(function(t){for(var e=i.getName(t),n=0;n<o.length;n++)if(!o[n].isSelected(e))return!1;return!0})}}}var bw=Math.PI/180;function ww(t,u,h,c,p,e,n,i,o,r){if(!(t.length<2)){for(var a,s=t.length,l=0;l<s;l++)"outer"===t[l].position&&"labelLine"===t[l].labelAlignTo&&(a=t[l].label.x-r,t[l].linePoints[1][0]+=a,t[l].label.x=r);g1(t,o,o+n)&&function(t){for(var e={list:[],maxY:0},n={list:[],maxY:0},i=0;i<t.length;i++){var o,r,a,s,l;"none"===t[i].labelAlignTo&&(o=t[i],r=o.label.y>h?n:e,(a=Math.abs(o.label.y-h))>r.maxY&&(s=o.label.x-u-o.len2*p,l=c+o.len,l=Math.abs(s)<l?Math.sqrt(a*a/(1-s*s/l/l)):l,r.rB=l,r.maxY=a),r.list.push(o))}d(e),d(n)}(t)}function d(t){for(var e=t.rB,n=e*e,i=0;i<t.list.length;i++){var o=t.list[i],r=Math.abs(o.label.y-h),a=c+o.len,a=a*a,a=Math.sqrt((1-Math.abs(r*r/n))*a);o.label.x=u+(a+o.len2)*p}}}function Sw(t){return"center"===t.position}function Mw(t){var T,C,D=t.getData(),A=[],k=!1,L=(t.get("minShowLabelAngle")||0)*bw,e=D.getLayout("viewRect"),P=D.getLayout("r"),O=e.width,R=e.x,n=e.y,e=e.height;function N(t){t.ignore=!0}D.each(function(t){var e,n,i,o,r,a,s,l,u,h,c,p=D.getItemGraphicEl(t),d=p.shape,f=p.getTextContent(),g=p.getTextGuideLine(),y=D.getItemModel(t),m=y.getModel("label"),v=m.get("position")||y.get(["emphasis","label","position"]),x=m.get("distanceToLabelLine"),_=m.get("alignTo"),b=go(m.get("edgeDistance"),O),w=m.get("bleedMargin"),S=y.getModel("labelLine"),M=go(M=S.get("length"),O),I=go(I=S.get("length2"),O);if(Math.abs(d.endAngle-d.startAngle)<L)return G(f.states,N),void(f.ignore=!0);!function(t){if(!t.ignore)return 1;for(var e in t.states)if(!1===t.states[e].ignore)return 1}(f)||(u=(d.startAngle+d.endAngle)/2,e=Math.cos(u),n=Math.sin(u),T=d.cx,C=d.cy,i="inside"===v||"inner"===v,l="center"===v?(r=d.cx,a=d.cy,"center"):(r=(o=(i?(d.r+d.r0)/2*e:d.r*e)+T)+3*e,a=(t=(i?(d.r+d.r0)/2*n:d.r*n)+C)+3*n,i||(y=o+e*(M+P-d.r),l=t+n*(M+P-d.r),s=y+(e<0?-1:1)*I,r="edge"===_?e<0?R+b:R+O-b:s+(e<0?-x:x),s=[[o,t],[y,a=l],[s,l]]),i?"center":"edge"===_?0<e?"right":"left":0<e?"left":"right"),"number"==typeof(m=m.get("rotate"))?h=m*(Math.PI/180):"center"===v?h=0:(u=e<0?-u+Math.PI:-u,"radial"===m||!0===m?h=u:"tangential"===m&&"outside"!==v&&"outer"!==v?(h=u+Math.PI/2)>Math.PI/2&&(h-=Math.PI):h=0),k=!!h,f.x=r,f.y=a,f.rotation=h,f.setStyle({verticalAlign:"middle"}),i?(f.setStyle({align:l}),(c=f.states.select)&&(c.x+=f.x,c.y+=f.y)):((h=f.getBoundingRect().clone()).applyTransform(f.getComputedTransform()),c=(f.style.margin||0)+2.1,h.y-=c/2,h.height+=c,A.push({label:f,labelLine:g,position:v,len:M,len2:I,minTurnAngle:S.get("minTurnAngle"),maxSurfaceAngle:S.get("maxSurfaceAngle"),surfaceNormal:new bi(e,n),linePoints:s,textAlign:l,labelDistance:x,labelAlignTo:_,edgeDistance:b,bleedMargin:w,rect:h})),p.setTextConfig({inside:i}))}),!k&&t.get("avoidLabelOverlap")&&function(t,e,n,i,o,r,a,s){for(var l=[],u=[],h=Number.MAX_VALUE,c=-Number.MAX_VALUE,p=0;p<t.length;p++){var d=t[p].label;Sw(t[p])||(d.x<e?(h=Math.min(h,d.x),l.push(t[p])):(c=Math.max(c,d.x),u.push(t[p])))}for(ww(u,e,n,i,1,0,r,0,s,c),ww(l,e,n,i,-1,0,r,0,s,h),p=0;p<t.length;p++){var f,g,y,m,v=t[p],d=v.label;Sw(v)||(f=v.linePoints)&&(g="edge"===v.labelAlignTo,y=v.rect.width,m=void 0,(m=g?d.x<e?f[2][0]-v.labelDistance-a-v.edgeDistance:a+o-v.edgeDistance-f[2][0]-v.labelDistance:d.x<e?d.x-a-v.bleedMargin:a+o-d.x-v.bleedMargin)<v.rect.width&&(v.label.style.width=m,"edge"===v.labelAlignTo&&(y=m)),m=f[1][0]-f[2][0],g?d.x<e?f[2][0]=a+v.edgeDistance+y+v.labelDistance:f[2][0]=a+o-v.edgeDistance-y-v.labelDistance:(d.x<e?f[2][0]=d.x+v.labelDistance:f[2][0]=d.x-v.labelDistance,f[1][0]=f[2][0]+m),f[1][1]=f[2][1]=d.y)}}(A,T,C,P,O,e,R,n);for(var i=0;i<A.length;i++){var o,r=A[i],a=r.label,s=r.labelLine,l=isNaN(a.x)||isNaN(a.y);a&&(a.setStyle({align:r.textAlign}),l&&(G(a.states,N),a.ignore=!0),(o=a.states.select)&&(o.x+=a.x,o.y+=a.y)),s&&(o=r.linePoints,l||!o?(G(s.states,N),s.ignore=!0):(l1(o,r.minTurnAngle),function(t,e,n){if(n<=180&&0<n){n=n/180*Math.PI,t1.fromArray(t[0]),e1.fromArray(t[1]),n1.fromArray(t[2]),bi.sub(i1,e1,t1),bi.sub(o1,n1,e1);var i=i1.len(),o=o1.len();if(!(i<.001||o<.001))if(i1.scale(1/i),o1.scale(1/o),i1.dot(e)<Math.cos(n)){i=Kv(e1.x,e1.y,n1.x,n1.y,t1.x,t1.y,a1,!1);s1.fromArray(a1);o=Math.PI/2,n=o+Math.acos(o1.dot(e))-n;if(o<=n)bi.copy(s1,n1);else{s1.scaleAndAdd(o1,i/Math.tan(Math.PI/2-n));n=n1.x!==e1.x?(s1.x-e1.x)/(n1.x-e1.x):(s1.y-e1.y)/(n1.y-e1.y);if(isNaN(n))return;n<0?bi.copy(s1,e1):1<n&&bi.copy(s1,n1)}s1.toArray(t[1])}}}(o,r.surfaceNormal,r.maxSurfaceAngle),s.setShape({points:o}),a.__hostTarget.textGuideLineConfig={anchor:new bi(o[0][0],o[0][1])}))}}function Iw(t,e,n){t=t.get("borderRadius");return null==t?n?{innerCornerRadius:0,cornerRadius:0}:null:{innerCornerRadius:Wi((t=!j(t)?[t,t]:t)[0],e.r0),cornerRadius:Wi(t[1],e.r)}}var Tw,Cw,Dw=(d(Lw,Cw=Wg),Lw.prototype.updateData=function(t,e,n,i){var o=this,r=t.hostModel,a=t.getItemModel(e),s=a.getModel("emphasis"),l=t.getItemLayout(e),u=N(Iw(a.getModel("itemStyle"),l,!0),l);isNaN(u.startAngle)?o.setShape(u):(i?(o.setShape(u),"scale"===r.getShallow("animationType")?(o.shape.r=l.r0,Ul(o,{shape:{r:l.r}},r,e)):null!=n?(o.setShape({startAngle:n,endAngle:n}),Ul(o,{shape:{startAngle:l.startAngle,endAngle:l.endAngle}},r,e)):(o.shape.endAngle=l.startAngle,Wl(o,{shape:{endAngle:l.endAngle}},r,e))):(ql(o),Wl(o,{shape:u},r,e)),o.useStyle(t.getItemVisual(e,"style")),Nl(o,a),i=(l.startAngle+l.endAngle)/2,n=r.get("selectedOffset"),u=Math.cos(i)*n,i=Math.sin(i)*n,(n=a.getShallow("cursor"))&&o.attr("cursor",n),this._updateLabel(r,t,e),o.ensureState("emphasis").shape=f({r:l.r+(s.get("scale")&&s.get("scaleSize")||0)},Iw(s.getModel("itemStyle"),l)),N(o.ensureState("select"),{x:u,y:i,shape:Iw(a.getModel(["select","itemStyle"]),l)}),N(o.ensureState("blur"),{shape:Iw(a.getModel(["blur","itemStyle"]),l)}),l=o.getTextGuideLine(),o=o.getTextContent(),l&&N(l.ensureState("select"),{x:u,y:i}),N(o.ensureState("select"),{x:u,y:i}),Ll(this,s.get("focus"),s.get("blurScope")))},Lw.prototype._updateLabel=function(t,e,n){var i=e.getItemModel(n),o=i.getModel("labelLine"),r=e.getItemVisual(n,"style"),a=r&&r.fill,r=r&&r.opacity;$l(this,tu(i),{labelFetcher:e.hostModel,labelDataIndex:n,inheritColor:a,defaultOpacity:r,defaultText:t.getFormattedLabel(n,"normal")||e.getName(n)});n=this.getTextContent();this.setTextConfig({position:null,rotation:null}),n.attr({z2:10});var t=t.get(["label","position"]);"outside"!==t&&"outer"!==t?this.removeTextGuideLine():((t=this.getTextGuideLine())||(t=new ny,this.setTextGuideLine(t)),c1(this,p1(i),{stroke:a,opacity:at(o.get(["lineStyle","opacity"]),r,1)}))},Lw),Aw=(d(kw,Tw=$d),kw.prototype.init=function(){var t=new ro;this._sectorGroup=t},kw.prototype.render=function(e,t,n,i){var o,r=e.getData(),a=this._data,s=this.group;if(!a&&0<r.count()){for(var l=r.getItemLayout(0),u=1;isNaN(l&&l.startAngle)&&u<r.count();++u)l=r.getItemLayout(u);l&&(o=l.startAngle)}this._emptyCircleSector&&s.remove(this._emptyCircleSector),0===r.count()&&e.get("showEmptyCircle")&&((n=new Wg({shape:vw(e,n)})).useStyle(e.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=n,s.add(n)),r.diff(a).add(function(t){var e=new Dw(r,t,o);r.setItemGraphicEl(t,e),s.add(e)}).update(function(t,e){e=a.getItemGraphicEl(e);e.updateData(r,t,o),e.off("click"),s.add(e),r.setItemGraphicEl(t,e)}).remove(function(t){jl(a.getItemGraphicEl(t),e,t)}).execute(),Mw(e),"expansion"!==e.get("animationTypeUpdate")&&(this._data=r)},kw.prototype.dispose=function(){},kw.prototype.containPoint=function(t,e){var n=e.getData().getItemLayout(0);if(n){e=t[0]-n.cx,t=t[1]-n.cy,t=Math.sqrt(e*e+t*t);return t<=n.r&&t>=n.r0}},kw.type="pie",kw);function kw(){var t=null!==Tw&&Tw.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}function Lw(t,e,n){var i=Cw.call(this)||this;i.z2=2;var o=new Fs;return i.setTextContent(o),i.updateData(t,e,n,!0),i}function Pw(t,e,n){e=j(e)?{coordDimensions:e}:N({encodeDefine:t.getEncode()},e);var i=t.getSource(),e=d_(i,e).dimensions,t=new c_(e,t);return t.initData(i,n),t}var Ow,Rw=(Ew.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},Ew.prototype.containName=function(t){return 0<=this._getRawData().indexOfName(t)},Ew.prototype.indexOfName=function(t){return this._getDataWithEncodedVisual().indexOfName(t)},Ew.prototype.getItemVisual=function(t,e){return this._getDataWithEncodedVisual().getItemVisual(t,e)},Ew),Nw=(d(zw,Ow=Gd),zw.prototype.init=function(t){Ow.prototype.init.apply(this,arguments),this.legendVisualProvider=new Rw(X(this.getData,this),X(this.getRawData,this)),this._defaultLabelLine(t)},zw.prototype.mergeOption=function(){Ow.prototype.mergeOption.apply(this,arguments)},zw.prototype.getInitialData=function(){return Pw(this,{coordDimensions:["value"],encodeDefaulter:Z(Qh,this)})},zw.prototype.getDataParams=function(t){var e=this.getData(),n=Ow.prototype.getDataParams.call(this,t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=function(t,e,n){if(!t[e])return 0;var i=W(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===i)return 0;for(var o=Math.pow(10,n),t=H(t,function(t){return(isNaN(t)?0:t)/i*o*100}),r=100*o,a=H(t,function(t){return Math.floor(t)}),s=W(a,function(t,e){return t+e},0),l=H(t,function(t,e){return t-a[e]});s<r;){for(var u=Number.NEGATIVE_INFINITY,h=null,c=0,p=l.length;c<p;++c)l[c]>u&&(u=l[c],h=c);++a[h],l[h]=0,++s}return a[e]/o}(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},zw.prototype._defaultLabelLine=function(t){zo(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},zw.type="series.pie",zw.defaultOption={zlevel:0,z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},zw);function zw(){return null!==Ow&&Ow.apply(this,arguments)||this}function Ew(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}var Vw,Bw,Fw,Gw,Hw,Ww=(d(iS,Hw=Gd),iS.prototype.getInitialData=function(t,e){return w_(null,this,{useEncodeDefaulter:!0})},iS.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},iS.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},iS.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},iS.type="series.scatter",iS.dependencies=["grid","polar","geo","singleAxis","calendar"],iS.defaultOption={coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},iS),Uw=function(){},Yw=(d(nS,Gw=as),nS.prototype.getDefaultShape=function(){return new Uw},nS.prototype.buildPath=function(t,e){var n=e.points,i=e.size,o=this.symbolProxy,r=o.shape,e=t.getContext?t.getContext():t;if(e&&i[0]<4)this._ctx=e;else{this._ctx=null;for(var a=0;a<n.length;){var s=n[a++],l=n[a++];isNaN(s)||isNaN(l)||this.softClipShape&&!this.softClipShape.contain(s,l)||(r.x=s-i[0]/2,r.y=l-i[1]/2,r.width=i[0],r.height=i[1],o.buildPath(t,r,!0))}}},nS.prototype.afterBrush=function(){var t=this.shape,e=t.points,n=t.size,i=this._ctx;if(i)for(var o=0;o<e.length;){var r=e[o++],a=e[o++];isNaN(r)||isNaN(a)||this.softClipShape&&!this.softClipShape.contain(r,a)||i.fillRect(r-n[0]/2,a-n[1]/2,n[0],n[1])}},nS.prototype.findDataIndex=function(t,e){for(var n=this.shape,i=n.points,n=n.size,o=Math.max(n[0],4),r=Math.max(n[1],4),a=i.length/2-1;0<=a;a--){var s=2*a,l=i[s]-o/2,s=i[1+s]-r/2;if(l<=t&&s<=e&&t<=l+o&&e<=s+r)return a}return-1},nS),Xw=(eS.prototype.isPersistent=function(){return!this._incremental},eS.prototype.updateData=function(t,e){this.group.removeAll();var n=new Yw({rectHover:!0,cursor:"default"});n.setShape({points:t.getLayout("points")}),this._setCommon(n,t,!1,e),this.group.add(n),this._incremental=null},eS.prototype.updateLayout=function(t){var i;this._incremental||(i=t.getLayout("points"),this.group.eachChild(function(t){var e,n;null!=t.startIndex&&(e=2*(t.endIndex-t.startIndex),n=4*t.startIndex*2,i=new Float32Array(i.buffer,n,e)),t.setShape("points",i)}))},eS.prototype.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),2e6<t.count()?(this._incremental||(this._incremental=new wy({silent:!0})),this.group.add(this._incremental)):this._incremental=null},eS.prototype.incrementalUpdate=function(t,e,n){var i;this._incremental?(i=new Yw,this._incremental.addDisplayable(i,!0)):((i=new Yw({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end})).incremental=!0,this.group.add(i)),i.setShape({points:e.getLayout("points")}),this._setCommon(i,e,!!this._incremental,n)},eS.prototype._setCommon=function(e,t,n,i){var o=t.hostModel;i=i||{};var r=t.getVisual("symbolSize");e.setShape("size",r instanceof Array?r:[r,r]),e.softClipShape=i.clipShape||null,e.symbolProxy=am(t.getVisual("symbol"),0,0,0,0),e.setColor=e.symbolProxy.setColor;i=e.shape.size[0]<4;e.useStyle(o.getModel("itemStyle").getItemStyle(i?["color","shadowBlur","shadowColor"]:["color"]));var a,t=t.getVisual("style"),t=t&&t.fill;t&&e.setColor(t),n||((a=Gs(e)).seriesIndex=o.seriesIndex,e.on("mousemove",function(t){a.dataIndex=null;t=e.findDataIndex(t.offsetX,t.offsetY);0<=t&&(a.dataIndex=t+(e.startIndex||0))}))},eS.prototype.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},eS.prototype._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},eS),Zw=(d(tS,Fw=$d),tS.prototype.render=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},tS.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},tS.prototype.incrementalRender=function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData(),{clipShape:this._getClipShape(e)}),this._finished=t.end===e.getData().count()},tS.prototype.updateTransform=function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||1e4<i.count()||!this._symbolDraw.isPersistent())return{update:!0};n=vb("").reset(t,e,n);n.progress&&n.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},tS.prototype._getClipShape=function(t){var e=t.coordinateSystem,e=e&&e.getArea&&e.getArea();return t.get("clip",!0)?e:null},tS.prototype._updateSymbolDraw=function(t,e){var n=this._symbolDraw,e=e.pipelineContext.large;return n&&e===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=new(e?Xw:O_),this._isLargeDraw=e,this.group.removeAll()),this.group.add(n.group),n},tS.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},tS.prototype.dispose=function(){},tS.type="scatter",tS),jw=(d($w,Bw=Vh),$w.type="grid",$w.dependencies=["xAxis","yAxis"],$w.layoutMode="box",$w.defaultOption={show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},$w),qw=(Qw.prototype.getNeedCrossZero=function(){return!this.option.scale},Qw.prototype.getCoordSysModel=function(){},Qw),Kw=(d(Jw,Vw=Vh),Jw.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Jo).models[0]},Jw.type="cartesian2dAxis",Jw);function Jw(){return null!==Vw&&Vw.apply(this,arguments)||this}function Qw(){}function $w(){return null!==Bw&&Bw.apply(this,arguments)||this}function tS(){var t=null!==Fw&&Fw.apply(this,arguments)||this;return t.type=tS.type,t}function eS(){this.group=new ro}function nS(t){return Gw.call(this,t)||this}function iS(){var t=null!==Hw&&Hw.apply(this,arguments)||this;return t.type=iS.type,t.hasSymbolVisual=!0,t}B(Kw,qw);var mu={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:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},gr=O({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},mu),C=O({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},mu),oS={category:gr,value:C,time:O({scale:!0,splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},C),log:z({scale:!0,logBase:10},C)},rS=0;function aS(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++rS}function sS(t){return $(t)&&null!=t.value?t.value:t+""}var lS=(aS.createByAxisModel=function(t){var e=t.option,t=e.data,t=t&&H(t,sS);return new aS({categories:t,needCollect:!t,deduplication:!1!==e.dedplication})},aS.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},aS.prototype.parseAndCollect=function(t){var e=this._needCollect;if("string"!=typeof t&&!e)return t;if(e&&!this._deduplication)return n=this.categories.length,this.categories[n]=t,n;var n,i=this._getOrCreateMap();return null==(n=i.get(t))&&(e?(n=this.categories.length,this.categories[n]=t,i.set(t,n)):n=NaN),n},aS.prototype._getOrCreateMap=function(){return this._map||(this._map=yt(this.categories))},aS),uS={value:1,category:1,time:1,log:1};function hS(r,a,s,l){G(uS,function(t,o){var e,n=O(O({},oS[o],!0),l,!0),n=(d(i,e=s),i.prototype.mergeDefaultAndTheme=function(t,e){var n=Ih(this),i=n?Ch(t):{};O(t,e.getTheme().get(o+"Axis")),O(t,this.getDefaultOption()),t.type=cS(t),n&&Th(t,i,n)},i.prototype.optionUpdated=function(){"category"===this.option.type&&(this.__ordinalMeta=lS.createByAxisModel(this))},i.prototype.getCategories=function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},i.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},i.type=a+"Axis."+o,i.defaultOption=n,i);function i(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=a+"Axis."+o,t}r.registerComponentModel(n)}),r.registerSubTypeDefaulter(a+"Axis",cS)}function cS(t){return t.type||(t.data?"category":"value")}pS.prototype.getSetting=function(t){return this._setting[t]},pS.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},pS.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},pS.prototype.getExtent=function(){return this._extent.slice()},pS.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},pS.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},pS.prototype.isBlank=function(){return this._isBlank},pS.prototype.setBlank=function(t){this._isBlank=t},Jn=pS;function pS(t){this._setting=t||{},this._extent=[1/0,-1/0]}pr(Jn);var dS=Jn,fS=yo;function gS(t,e,n,i){var o={},r=t[1]-t[0],e=o.interval=To(r/e,!0);null!=n&&e<n&&(e=o.interval=n),null!=i&&i<e&&(e=o.interval=i);var i=o.intervalPrecision=yS(e),i=o.niceTickExtent=[fS(Math.ceil(t[0]/e)*e,i),fS(Math.floor(t[1]/e)*e,i)];return i=i,t=t,isFinite(i[0])||(i[0]=t[0]),isFinite(i[1])||(i[1]=t[1]),mS(i,0,t),mS(i,1,t),i[0]>i[1]&&(i[0]=i[1]),o}function yS(t){return vo(t)+2}function mS(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function vS(t,e){return t>=e[0]&&t<=e[1]}function xS(t,e){return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])}function _S(t,e){return t*(e[1]-e[0])+e[0]}var bS,mu=(d(wS,bS=dS),wS.prototype.parse=function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},wS.prototype.contain=function(t){return vS(t=this.parse(t),this._extent)&&null!=this._ordinalMeta.categories[t]},wS.prototype.normalize=function(t){return xS(t=this._getTickNumber(this.parse(t)),this._extent)},wS.prototype.scale=function(t){return t=Math.round(_S(t,this._extent)),this.getRawOrdinalNumber(t)},wS.prototype.getTicks=function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push({value:n}),n++;return t},wS.prototype.getMinorTicks=function(t){},wS.prototype.setSortInfo=function(t){if(null!=t){for(var e=t.ordinalNumbers,n=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],o=0,r=this._ordinalMeta.categories.length,a=Math.min(r,e.length);o<a;++o){var s=e[o];i[n[o]=s]=o}for(var l=0;o<r;++o){for(;null!=i[l];)l++;n.push(l),i[l]=o}}else this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null},wS.prototype._getTickNumber=function(t){var e=this._ticksByOrdinalNumber;return e&&0<=t&&t<e.length?e[t]:t},wS.prototype.getRawOrdinalNumber=function(t){var e=this._ordinalNumbersByTick;return e&&0<=t&&t<e.length?e[t]:t},wS.prototype.getLabel=function(t){if(!this.isBlank()){t=this.getRawOrdinalNumber(t.value),t=this._ordinalMeta.categories[t];return null==t?"":t+""}},wS.prototype.count=function(){return this._extent[1]-this._extent[0]+1},wS.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},wS.prototype.isInExtentRange=function(t){return t=this._getTickNumber(t),this._extent[0]<=t&&this._extent[1]>=t},wS.prototype.getOrdinalMeta=function(){return this._ordinalMeta},wS.prototype.niceTicks=function(){},wS.prototype.niceExtent=function(){},wS.type="ordinal",wS);function wS(t){var e=bS.call(this,t)||this;e.type="ordinal";var t=e.getSetting("ordinalMeta");return j(t=t||new lS({}))&&(t=new lS({categories:H(t,function(t){return $(t)?t.value:t})})),e._ordinalMeta=t,e._extent=e.getSetting("extent")||[0,t.categories.length-1],e}dS.registerClass(mu);var SS,MS=mu,IS=yo,gr=(d(TS,SS=dS),TS.prototype.parse=function(t){return t},TS.prototype.contain=function(t){return vS(t,this._extent)},TS.prototype.normalize=function(t){return xS(t,this._extent)},TS.prototype.scale=function(t){return _S(t,this._extent)},TS.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},TS.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]),this.setExtent(e[0],e[1])},TS.prototype.getInterval=function(){return this._interval},TS.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=yS(t)},TS.prototype.getTicks=function(t){var e=this._interval,n=this._extent,i=this._niceExtent,o=this._intervalPrecision,r=[];if(!e)return r;n[0]<i[0]&&(t?r.push({value:IS(i[0]-e,o)}):r.push({value:n[0]}));for(var a=i[0];a<=i[1]&&(r.push({value:a}),(a=IS(a+e,o))!==r[r.length-1].value);)if(1e4<r.length)return[];var s=r.length?r[r.length-1].value:i[1];return n[1]>s&&(t?r.push({value:IS(s+e,o)}):r.push({value:n[1]})),r},TS.prototype.getMinorTicks=function(t){for(var e=this.getTicks(!0),n=[],i=this.getExtent(),o=1;o<e.length;o++){for(var r=e[o],a=e[o-1],s=0,l=[],u=(r.value-a.value)/t;s<t-1;){var h=IS(a.value+(s+1)*u);h>i[0]&&h<i[1]&&l.push(h),s++}n.push(l)}return n},TS.prototype.getLabel=function(t,e){if(null==t)return"";e=e&&e.precision;return null==e?e=vo(t.value)||0:"auto"===e&&(e=this._intervalPrecision),ah(IS(t.value,e,!0))},TS.prototype.niceTicks=function(t,e,n){t=t||5;var i=this._extent,o=i[1]-i[0];isFinite(o)&&(o<0&&(o=-o,i.reverse()),n=gS(i,t,e,n),this._intervalPrecision=n.intervalPrecision,this._interval=n.interval,this._niceExtent=n.niceTickExtent)},TS.prototype.niceExtent=function(t){var e=this._extent;e[0]===e[1]&&(0!==e[0]?(n=e[0],t.fixMax||(e[1]+=n/2),e[0]-=n/2):e[1]=1);var n=e[1]-e[0];isFinite(n)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);n=this._interval;t.fixMin||(e[0]=IS(Math.floor(e[0]/n)*n)),t.fixMax||(e[1]=IS(Math.ceil(e[1]/n)*n))},TS.type="interval",TS);function TS(){var t=null!==SS&&SS.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}dS.registerClass(gr);var CS,DS=gr,C=(d(kS,CS=DS),kS.prototype.getLabel=function(t){var e=this.getSetting("useUTC");return Uu(t.value,Bu[function(t){switch(t){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}(Wu(this._minLevelUnit))]||Bu.second,e,this.getSetting("locale"))},kS.prototype.getFormattedLabel=function(t,e,n){var i=this.getSetting("useUTC");return function(t,e,n,i,o){var r=null;if("string"==typeof n)r=n;else if("function"==typeof n)r=n(t.value,e,{level:t.level});else{var a=N({},Vu);if(0<t.level)for(var s=0;s<Fu.length;++s)a[Fu[s]]="{primary|"+a[Fu[s]]+"}";var l=n?!1===n.inherit?n:z(n,a):a,u=Yu(t.value,o);if(l[u])r=l[u];else if(l.inherit){for(s=Gu.indexOf(u)-1;0<=s;--s)if(l[u]){r=l[u];break}r=r||a.none}j(r)&&(n=null==t.level?0:0<=t.level?t.level:r.length+t.level,r=r[n=Math.min(n,r.length-1)])}return Uu(new Date(t.value),r,o,i)}(t,e,n,this.getSetting("locale"),i)},kS.prototype.getTicks=function(t){var e=this._interval,n=this._extent,i=[];if(!e)return i;i.push({value:n[0],level:0});e=this.getSetting("useUTC"),e=function(t,d,f,g){var e=Gu,n=0;function i(t,e,n){var i,o,r=[],a=!e.length;if(!function(t,e,n,i){function o(t){return Xu(c,t,i)===Xu(p,t,i)}function r(){return o("year")}function a(){return r()&&o("month")}function s(){return a()&&o("day")}function l(){return s()&&o("hour")}function u(){return l()&&o("minute")}function h(){return u()&&o("second")}var c=Mo(e),p=Mo(n);switch(t){case"year":return r();case"month":return a();case"day":return s();case"hour":return l();case"minute":return u();case"second":return h();case"millisecond":return h()&&o("millisecond")}}(Wu(t),g[0],g[1],f)){a&&(e=[{value:function(t,e,n){var i=new Date(t);switch(Wu(e)){case"year":case"month":i[th(n)](0);case"day":i[eh(n)](1);case"hour":i[nh(n)](0);case"minute":i[ih(n)](0);case"second":i[oh(n)](0),i[rh(n)](0)}return i.getTime()}(new Date(g[0]),t,f)},{value:g[1]}]);for(var s=0;s<e.length-1;s++){var l=e[s].value,u=e[s+1].value;if(l!==u){var h=void 0,c=void 0,p=void 0;switch(t){case"year":h=Math.max(1,Math.round(d/Eu/365)),c=Zu(f),p=f?"setUTCFullYear":"setFullYear";break;case"half-year":case"quarter":case"month":o=d,h=6<(o/=30*Eu)?6:3<o?3:2<o?2:1,c=ju(f),p=th(f);break;case"week":case"half-week":case"day":i=d,h=16<(i/=Eu)?16:7.5<i?7:3.5<i?4:1.5<i?2:1,c=qu(f),p=eh(f),0;break;case"half-day":case"quarter-day":case"hour":i=d,h=12<(i/=zu)?12:6<i?6:3.5<i?4:2<i?2:1,c=Ku(f),p=nh(f);break;case"minute":h=LS(d,!0),c=Ju(f),p=ih(f);break;case"second":h=LS(d,!1),c=Qu(f),p=oh(f);break;case"millisecond":h=To(d,!0),c=$u(f),p=rh(f)}(function(t,e,n,i,o,r){for(var a=new Date(e),s=e,l=a[i]();s<n&&s<=g[1];)r.push({value:s}),a[o](l+=t),s=a.getTime();r.push({value:s,notAdd:!0})})(h,l,u,c,p,r),"year"===t&&1<n.length&&0===s&&n.unshift({value:n[0].value-h})}}for(s=0;s<r.length;s++)n.push(r[s]);return 1}}for(var o=[],r=[],a=0,s=0,l=0;l<e.length&&n++<1e4;++l){var u=Wu(e[l]);if(function(t){return t===Wu(t)}(e[l])){i(e[l],o[o.length-1]||[],r);var h=e[l+1]?Wu(e[l+1]):null;if(u!==h){if(r.length){s=a,r.sort(function(t,e){return t.value-e.value});for(var c=[],p=0;p<r.length;++p){var y=r[p].value;0!==p&&r[p-1].value===y||(c.push(r[p]),y>=g[0]&&y<=g[1]&&a++)}h=(g[1]-g[0])/d;if(1.5*h<a&&h/1.5<s)break;if(o.push(c),h<a||t===e[l])break}r=[]}}}var m=U(H(o,function(t){return U(t,function(t){return t.value>=g[0]&&t.value<=g[1]&&!t.notAdd})}),function(t){return 0<t.length}),v=[],x=m.length-1;for(l=0;l<m.length;++l)for(var _=m[l],b=0;b<_.length;++b)v.push({value:_[b].value,level:x-l});v.sort(function(t,e){return t.value-e.value});var w=[];for(l=0;l<v.length;++l)0!==l&&v[l].value===v[l-1].value||w.push(v[l]);return w}(this._minLevelUnit,this._approxInterval,e,n);return(i=i.concat(e)).push({value:n[1],level:0}),i},kS.prototype.niceExtent=function(t){var e,n=this._extent;n[0]===n[1]&&(n[0]-=Eu,n[1]+=Eu),n[1]===-1/0&&n[0]===1/0&&(e=new Date,n[1]=+new Date(e.getFullYear(),e.getMonth(),e.getDate()),n[0]=n[1]-Eu),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval)},kS.prototype.niceTicks=function(t,e,n){var i=this._extent,i=i[1]-i[0];this._approxInterval=i/(t=t||10),null!=e&&this._approxInterval<e&&(this._approxInterval=e),null!=n&&this._approxInterval>n&&(this._approxInterval=n);n=AS.length,n=Math.min(function(t,e,n,i){for(;n<i;){var o=n+i>>>1;t[o][1]<e?n=1+o:i=o}return n}(AS,this._approxInterval,0,n),n-1);this._interval=AS[n][1],this._minLevelUnit=AS[Math.max(n-1,0)][0]},kS.prototype.parse=function(t){return"number"==typeof t?t:+Mo(t)},kS.prototype.contain=function(t){return vS(this.parse(t),this._extent)},kS.prototype.normalize=function(t){return xS(this.parse(t),this._extent)},kS.prototype.scale=function(t){return _S(t,this._extent)},kS.type="time",kS),AS=[["second",Ru],["minute",Nu],["hour",zu],["quarter-day",6*zu],["half-day",12*zu],["day",1.2*Eu],["half-week",3.5*Eu],["week",7*Eu],["month",31*Eu],["quarter",95*Eu],["half-year",_/2],["year",_]];function kS(t){t=CS.call(this,t)||this;return t.type="time",t}function LS(t,e){return 30<(t/=e?Nu:Ru)?30:20<t?20:15<t?15:10<t?10:5<t?5:2<t?2:1}dS.registerClass(C);var PS,OS=C,RS=dS.prototype,NS=DS.prototype,zS=yo,ES=Math.floor,VS=Math.ceil,BS=Math.pow,FS=Math.log,Jn=(d(GS,PS=dS),GS.prototype.getTicks=function(t){var e=this._originalScale,n=this._extent,i=e.getExtent();return H(NS.getTicks.call(this,t),function(t){var e=t.value,t=yo(BS(this.base,e)),t=e===n[0]&&this._fixMin?HS(t,i[0]):t;return{value:t=e===n[1]&&this._fixMax?HS(t,i[1]):t}},this)},GS.prototype.setExtent=function(t,e){var n=this.base;t=FS(t)/FS(n),e=FS(e)/FS(n),NS.setExtent.call(this,t,e)},GS.prototype.getExtent=function(){var t=this.base,e=RS.getExtent.call(this);e[0]=BS(t,e[0]),e[1]=BS(t,e[1]);t=this._originalScale.getExtent();return this._fixMin&&(e[0]=HS(e[0],t[0])),this._fixMax&&(e[1]=HS(e[1],t[1])),e},GS.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=FS(t[0])/FS(e),t[1]=FS(t[1])/FS(e),RS.unionExtent.call(this,t)},GS.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},GS.prototype.niceTicks=function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n==1/0||n<=0)){var i=Math.pow(10,Io(n));for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&0<Math.abs(i);)i*=10;e=[yo(VS(e[0]/i)*i),yo(ES(e[1]/i)*i)];this._interval=i,this._niceExtent=e}},GS.prototype.niceExtent=function(t){NS.niceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},GS.prototype.parse=function(t){return t},GS.prototype.contain=function(t){return vS(t=FS(t)/FS(this.base),this._extent)},GS.prototype.normalize=function(t){return xS(t=FS(t)/FS(this.base),this._extent)},GS.prototype.scale=function(t){return t=_S(t,this._extent),BS(this.base,t)},GS.type="log",GS),mu=Jn.prototype;function GS(){var t=null!==PS&&PS.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new DS,t._interval=0,t}function HS(t,e){return zS(t,vo(e))}mu.getMinorTicks=NS.getMinorTicks,mu.getLabel=NS.getLabel,dS.registerClass(Jn);var WS=Jn,US=(ZS.prototype._prepareParams=function(t,e,n){n[1]<n[0]&&(n=[NaN,NaN]),this._dataMin=n[0],this._dataMax=n[1];var i=this._isOrdinal="ordinal"===t.type;this._needCrossZero=e.getNeedCrossZero&&e.getNeedCrossZero();var o=this._modelMinRaw=e.get("min",!0);q(o)?this._modelMinNum=qS(t,o({min:n[0],max:n[1]})):"dataMin"!==o&&(this._modelMinNum=qS(t,o));o=this._modelMaxRaw=e.get("max",!0);q(o)?this._modelMaxNum=qS(t,o({min:n[0],max:n[1]})):"dataMax"!==o&&(this._modelMaxNum=qS(t,o)),i?this._axisDataLen=e.getCategories().length:"boolean"==typeof(e=j(e=e.get("boundaryGap"))?e:[e||0,e||0])[0]||"boolean"==typeof e[1]?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[Wi(e[0],1),Wi(e[1],1)]},ZS.prototype.calculate=function(){var t=this._isOrdinal,e=this._dataMin,n=this._dataMax,i=this._axisDataLen,o=this._boundaryGapInner,r=t?null:n-e||Math.abs(e),a="dataMin"===this._modelMinRaw?e:this._modelMinNum,s="dataMax"===this._modelMaxRaw?n:this._modelMaxNum,l=null!=a,u=null!=s;null==a&&(a=t?i?0:NaN:e-o[0]*r),null==s&&(s=t?i?i-1:NaN:n+o[1]*r),null!=a&&isFinite(a)||(a=NaN),null!=s&&isFinite(s)||(s=NaN);r=it(a)||it(s)||t&&!i;!this._needCrossZero||(a=0<a&&0<s&&!l?0:a)<0&&s<0&&!u&&(s=0);t=this._determinedMin,i=this._determinedMax;return null!=t&&(a=t,l=!0),null!=i&&(s=i,u=!0),{min:a,max:s,minFixed:l,maxFixed:u,isBlank:r}},ZS.prototype.modifyDataMinMax=function(t,e){this[XS[t]]=e},ZS.prototype.setDeterminedMinMax=function(t,e){this[YS[t]]=e},ZS.prototype.freeze=function(){this.frozen=!0},ZS),YS={min:"_determinedMin",max:"_determinedMax"},XS={min:"_dataMin",max:"_dataMax"};function ZS(t,e,n){this._prepareParams(t,e,n)}function jS(t,e,n){var i;return(i=t.rawExtentInfo)||(i=new US(t,e,n),t.rawExtentInfo=i)}function qS(t,e){return null==e?null:it(e)?NaN:t.parse(e)}function KS(t,e){var n=t.type,i=jS(t,e,t.getExtent()).calculate();t.setBlank(i.isBlank);var o,r=i.min,a=i.max,t=e.ecModel;return t&&"time"===n&&(t=Tb("bar",t),o=!1,G(t,function(t){o=o||t.getBaseAxis()===e.axis}),o&&(t=Cb(t),r=(t=function(t,e,n,i){var o=n.axis.getExtent(),o=o[1]-o[0],i=Ab(i,n.axis);if(void 0===i)return{min:t,max:e};var r=1/0;G(i,function(t){r=Math.min(t.offset,r)});var a=-1/0;G(i,function(t){a=Math.max(t.offset+t.width,a)}),r=Math.abs(r),a=Math.abs(a);n=r+a,i=e-t,i=i/(1-(r+a)/o)-i;return{min:t-=r/n*i,max:e+=a/n*i}}(r,a,e,t)).min,a=t.max)),{extent:[r,a],fixMin:i.minFixed,fixMax:i.maxFixed}}function JS(t,e){var n=e,i=KS(t,n),o=i.extent,r=n.get("splitNumber");t instanceof WS&&(t.base=n.get("logBase"));e=t.type;t.setExtent(o[0],o[1]),t.niceExtent({splitNumber:r,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:"interval"===e||"time"===e?n.get("minInterval"):null,maxInterval:"interval"===e||"time"===e?n.get("maxInterval"):null});n=n.get("interval");null!=n&&t.setInterval&&t.setInterval(n)}function QS(t,e){if(e=e||t.get("type"))switch(e){case"category":return new MS({ordinalMeta:t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),extent:[1/0,-1/0]});case"time":return new OS({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new(dS.getClass(e)||DS)}}function $S(n){var i,e,o,t=n.getLabelModel().get("formatter"),r="category"===n.type?n.scale.getExtent()[0]:null;return"time"===n.scale.type?(o=t,function(t,e){return n.scale.getFormattedLabel(t,e,o)}):"string"==typeof t?(e=t,function(t){t=n.scale.getLabel(t);return e.replace("{value}",null!=t?t:"")}):"function"==typeof t?(i=t,function(t,e){return null!=r&&(e=t.value-r),i(tM(n,t),e,null!=t.level?{level:t.level}:null)}):function(t){return n.scale.getLabel(t)}}function tM(t,e){return"category"===t.type?t.scale.getLabel(e):e.value}function eM(t){var e,n,i=t.model,o=t.scale;if(i.get(["axisLabel","show"])&&!o.isBlank()){var r,a,s=o.getExtent(),l=o instanceof MS?o.count():(r=o.getTicks()).length,u=t.getLabelModel(),h=$S(t),c=1;40<l&&(c=Math.ceil(l/40));for(var p=0;p<l;p+=c){var d=h(r?r[p]:{value:s[0]+p},p),f=u.getTextRect(d),g=(e=f,n=u.get("rotate")||0,g=f=d=g=void 0,g=n*Math.PI/180,d=e.width,f=e.height,n=d*Math.abs(Math.cos(g))+Math.abs(f*Math.sin(g)),g=d*Math.abs(Math.sin(g))+Math.abs(f*Math.cos(g)),new ki(e.x,e.y,n,g));a?a.union(g):a=g}return a}}function nM(t){t=t.get("interval");return null==t?"auto":t}function iM(t){return"category"===t.type&&0===nM(t.getLabelModel())}function oM(e,t){var n={};return G(e.mapDimensionsAll(t),function(t){n[x_(e,t)]=!0}),Y(n)}var gr=(aM.prototype.getAxis=function(t){return this._axes[t]},aM.prototype.getAxes=function(){return H(this._dimList,function(t){return this._axes[t]},this)},aM.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),U(this.getAxes(),function(t){return t.scale.type===e})},aM.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},aM),rM=["x","y"];function aM(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}function sM(t){return"interval"===t.type||"time"===t.type}var lM,uM=(d(cM,lM=gr),cM.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t,e,n,i,o=this.getAxis("x").scale,r=this.getAxis("y").scale;sM(o)&&sM(r)&&(n=o.getExtent(),i=r.getExtent(),t=this.dataToPoint([n[0],i[0]]),e=this.dataToPoint([n[1],i[1]]),o=n[1]-n[0],r=i[1]-i[0],o&&r&&(o=(e[0]-t[0])/o,r=(e[1]-t[1])/r,n=t[0]-n[0]*o,i=t[1]-i[0]*r,i=this._transform=[o,0,0,r,n,i],this._invTransform=ui([],i)))},cM.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},cM.prototype.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]))},cM.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},cM.prototype.dataToPoint=function(t,e,n){n=n||[];var i=t[0],o=t[1];if(this._transform&&null!=i&&isFinite(i)&&null!=o&&isFinite(o))return zt(n,t,this._transform);var r=this.getAxis("x"),t=this.getAxis("y");return n[0]=r.toGlobalCoord(r.dataToCoord(i,e)),n[1]=t.toGlobalCoord(t.dataToCoord(o,e)),n},cM.prototype.clampData=function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,o=n.getExtent(),r=i.getExtent(),n=n.parse(t[0]),t=i.parse(t[1]);return(e=e||[])[0]=Math.min(Math.max(Math.min(o[0],o[1]),n),Math.max(o[0],o[1])),e[1]=Math.min(Math.max(Math.min(r[0],r[1]),t),Math.max(r[0],r[1])),e},cM.prototype.pointToData=function(t,e){var n=[];if(this._invTransform)return zt(n,t,this._invTransform);var i=this.getAxis("x"),o=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(t[0]),e),n[1]=o.coordToData(o.toLocalCoord(t[1]),e),n},cM.prototype.getOtherAxis=function(t){return this.getAxis("x"===t.dim?"y":"x")},cM.prototype.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]),t=Math.max(t[0],t[1])-n,e=Math.max(e[0],e[1])-i;return new ki(n,i,t,e)},cM),hM=Zo();function cM(){var t=null!==lM&&lM.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=rM,t}function pM(t){return"category"===t.type?(o=(e=t).getLabelModel(),r=fM(e,o),!o.get("show")||e.scale.isBlank()?{labels:[],labelCategoryInterval:r.labelCategoryInterval}:r):(t=(n=t).scale.getTicks(),i=$S(n),{labels:H(t,function(t,e){return{level:t.level,formattedLabel:i(t,e),rawLabel:n.scale.getLabel(t),tickValue:t.value}})});var n,i,e,o,r}function dM(t,e){return"category"===t.type?function(t,e){var n,i,o=gM(t,"ticks"),r=nM(e),a=yM(o,r);if(a)return a;e.get("show")&&!t.scale.isBlank()||(n=[]),n=q(r)?xM(t,r,!0):"auto"===r?(e=fM(t,t.getLabelModel()),i=e.labelCategoryInterval,H(e.labels,function(t){return t.tickValue})):vM(t,i=r,!0);return mM(o,r,{ticks:n,tickCategoryInterval:i})}(t,e):{ticks:H(t.scale.getTicks(),function(t){return t.value})}}function fM(t,e){var n,i=gM(t,"labels"),e=nM(e);return yM(i,e)||mM(i,e,{labels:q(e)?xM(t,e):vM(t,n="auto"===e?null!=(t=hM(n=t).autoInterval)?t:hM(n).autoInterval=n.calculateCategoryInterval():e),labelCategoryInterval:n})}function gM(t,e){return hM(t)[e]||(hM(t)[e]=[])}function yM(t,e){for(var n=0;n<t.length;n++)if(t[n].key===e)return t[n].value}function mM(t,e,n){return t.push({key:e,value:n}),n}function vM(t,e,n){var i=$S(t),o=t.scale,r=o.getExtent(),a=t.getLabelModel(),s=[],l=Math.max((e||0)+1,1),u=r[0],e=o.count();0!==u&&1<l&&2<e/l&&(u=Math.round(Math.ceil(u/l)*l));e=iM(t),t=a.get("showMinLabel")||e,e=a.get("showMaxLabel")||e;t&&u!==r[0]&&c(r[0]);for(var h=u;h<=r[1];h+=l)c(h);function c(t){var e={value:t};s.push(n?t:{formattedLabel:i(e),rawLabel:o.getLabel(e),tickValue:t})}return e&&h-l!==r[1]&&c(r[1]),s}function xM(t,i,o){var r=t.scale,a=$S(t),s=[];return G(r.getTicks(),function(t){var e=r.getLabel(t),n=t.value;i(t.value,e)&&s.push(o?n:{formattedLabel:a(t),rawLabel:e,tickValue:n})}),s}var _M=[0,1];function bM(t,e,n){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=n||[0,0]}function wM(t,e){e=(t[1]-t[0])/e/2;t[0]+=e,t[1]-=e}var SM,_=(bM.prototype.contain=function(t){var e=this._extent,n=Math.min(e[0],e[1]),e=Math.max(e[0],e[1]);return n<=t&&t<=e},bM.prototype.containData=function(t){return this.scale.contain(t)},bM.prototype.getExtent=function(){return this._extent.slice()},bM.prototype.getPixelPrecision=function(t){return xo(t||this.scale.getExtent(),this._extent)},bM.prototype.setExtent=function(t,e){var n=this._extent;n[0]=t,n[1]=e},bM.prototype.dataToCoord=function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&wM(n=n.slice(),i.count()),fo(t,_M,n,e)},bM.prototype.coordToData=function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&wM(n=n.slice(),i.count());e=fo(t,n,_M,e);return this.scale.scale(e)},bM.prototype.pointToData=function(t,e){},bM.prototype.getTicksCoords=function(t){var e=(t=t||{}).tickModel||this.getTickModel(),n=H(dM(this,e).ticks,function(t){return{coord:this.dataToCoord("ordinal"===this.scale.type?this.scale.getRawOrdinalNumber(t):t),tickValue:t}},this);return function(t,e,n,i){var o=e.length;{var r,a,s,l;t.onBand&&!n&&o&&(a=t.getExtent(),1===o?(e[0].coord=a[0],r=e[1]={coord:a[0]}):(n=e[o-1].tickValue-e[0].tickValue,s=(e[o-1].coord-e[0].coord)/n,G(e,function(t){t.coord-=s/2}),t=t.scale.getExtent(),t=1+t[1]-e[o-1].tickValue,r={coord:e[o-1].coord+s*t},e.push(r)),l=a[0]>a[1],u(e[0].coord,a[0])&&(i?e[0].coord=a[0]:e.shift()),i&&u(a[0],e[0].coord)&&e.unshift({coord:a[0]}),u(a[1],r.coord)&&(i?r.coord=a[1]:e.pop()),i&&u(r.coord,a[1])&&e.push({coord:a[1]}))}function u(t,e){return t=yo(t),e=yo(e),l?e<t:t<e}}(this,n,e.get("alignWithLabel"),t.clamp),n},bM.prototype.getMinorTicksCoords=function(){if("ordinal"===this.scale.type)return[];var t=this.model.getModel("minorTick").get("splitNumber");return H(this.scale.getMinorTicks(t=!(0<t&&t<100)?5:t),function(t){return H(t,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this)},this)},bM.prototype.getViewLabels=function(){return pM(this).labels},bM.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},bM.prototype.getTickModel=function(){return this.model.getModel("axisTick")},bM.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),e=e[1]-e[0]+(this.onBand?1:0);0===e&&(e=1);t=Math.abs(t[1]-t[0]);return Math.abs(t)/e},bM.prototype.calculateCategoryInterval=function(){return function(t){var e=(u=(l=t).getLabelModel(),{axisRotate:l.getRotate?l.getRotate():l.isHorizontal&&!l.isHorizontal()?90:0,labelRotate:u.get("rotate")||0,font:u.getFont()}),n=$S(t),i=(e.axisRotate-e.labelRotate)/180*Math.PI,o=(h=t.scale).getExtent(),r=h.count();if(o[1]-o[0]<1)return 0;var a=1;40<r&&(a=Math.max(1,Math.floor(r/40)));for(var s=o[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l*Math.cos(i)),h=Math.abs(l*Math.sin(i)),c=0,p=0;s<=o[1];s+=a)var d=1.3*(f=Bi(n({value:s}),e.font,"center","top")).width,f=1.3*f.height,c=Math.max(c,d,7),p=Math.max(p,f,7);return l=c/u,i=p/h,isNaN(l)&&(l=1/0),isNaN(i)&&(i=1/0),u=Math.max(0,Math.floor(Math.min(l,i))),h=hM(t.model),l=t.getExtent(),i=h.lastAutoInterval,t=h.lastTickCount,null!=i&&null!=t&&Math.abs(i-u)<=1&&Math.abs(t-r)<=1&&u<i&&h.axisExtent0===l[0]&&h.axisExtent1===l[1]?u=i:(h.lastTickCount=r,h.lastAutoInterval=u,h.axisExtent0=l[0],h.axisExtent1=l[1]),u}(this)},bM),MM=(d(IM,SM=_),IM.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},IM.prototype.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},IM.prototype.pointToData=function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},IM.prototype.setCategorySortInfo=function(t){if("category"!==this.type)return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},IM);function IM(t,e,n,i,o){n=SM.call(this,t,e,n)||this;return n.index=0,n.type=i||"value",n.position=o||"bottom",n}function TM(t,e,n){n=n||{};var i=t.coordinateSystem,o=e.axis,r={},a=o.getAxesOnZeroOf()[0],s=o.position,l=a?"onZero":s,u=o.dim,h=i.getRect(),t=[h.x,h.x+h.width,h.y,h.y+h.height],o={left:0,right:1,top:0,bottom:1,onZero:2},i=e.get("offset")||0,h="x"===u?[t[2]-i,t[3]+i]:[t[0]-i,t[1]+i];a&&(i=a.toGlobalCoord(a.dataToCoord(0)),h[o.onZero]=Math.max(Math.min(i,h[1]),h[0])),r.position=["y"===u?h[o[l]]:t[0],"x"===u?h[o[l]]:t[3]],r.rotation=Math.PI/2*("x"===u?0:1);r.labelDirection=r.tickDirection=r.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],r.labelOffset=a?h[o[s]]-h[o.onZero]:0,e.get(["axisTick","inside"])&&(r.tickDirection=-r.tickDirection),ot(n.labelInside,e.get(["axisLabel","inside"]))&&(r.labelDirection=-r.labelDirection);e=e.get(["axisLabel","rotate"]);return r.labelRotate="top"===l?-e:e,r.z2=1,r}function CM(t){return"cartesian2d"===t.get("coordinateSystem")}function DM(i){var o={xAxisModel:null,yAxisModel:null};return G(o,function(t,e){var n=e.replace(/Model$/,""),n=i.getReferringComponents(n,Jo).models[0];o[e]=n}),o}function AM(t,e,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=rM,this._initCartesian(t,e,n),this.model=t}function kM(t,e){return t.getCoordSysModel()===e}function LM(t,e,n,i){n.getAxesOnZeroOf=function(){return o?[o]:[]};var o,r=t[e],e=n.model,n=e.get(["axisLine","onZero"]),e=e.get(["axisLine","onZeroAxisIndex"]);if(n){if(null!=e)PM(r[e])&&(o=r[e]);else for(var a in r)if(r.hasOwnProperty(a)&&PM(r[a])&&!i[s(r[a])]){o=r[a];break}o&&(i[s(o)]=!0)}function s(t){return t.dim+"_"+t.index}}function PM(t){return t&&"category"!==t.type&&"time"!==t.type&&(e=(t=(e=t).scale.getExtent())[0],t=t[1],!(0<e&&0<t||e<0&&t<0));var e}var OM=(AM.prototype.getRect=function(){return this._rect},AM.prototype.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),G(n.x,function(t){JS(t.scale,t.model)}),G(n.y,function(t){JS(t.scale,t.model)});var i={};G(n.x,function(t){LM(n,"y",t,i)}),G(n.y,function(t){LM(n,"x",t,i)}),this.resize(this.model,e)},AM.prototype.resize=function(t,e,n){var i=t.getBoxLayoutParams(),t=!n&&t.get("containLabel"),a=Sh(i,{width:e.getWidth(),height:e.getHeight()});this._rect=a;var o=this._axesList;function r(){G(o,function(t){var e,n,i=t.isHorizontal(),o=i?[0,a.width]:[0,a.height],r=t.inverse?1:0;t.setExtent(o[r],o[1-r]),t=t,e=i?a.x:a.y,i=t.getExtent(),n=i[0]+i[1],t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return n-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return n-t+e}})}r(),t&&(G(o,function(t){var e,n,i;t.model.get(["axisLabel","inside"])||(e=eM(t))&&(n=t.isHorizontal()?"height":"width",i=t.model.get(["axisLabel","margin"]),a[n]-=e[n]+i,"top"===t.position?a.y+=e.height+i:"left"===t.position&&(a.x+=e.width+i))}),r()),G(this._coordsList,function(t){t.calcAffineTransform()})},AM.prototype.getAxis=function(t,e){t=this._axesMap[t];if(null!=t)return t[e||0]},AM.prototype.getAxes=function(){return this._axesList.slice()},AM.prototype.getCartesian=function(t,e){if(null!=t&&null!=e)return this._coordsMap["x"+t+"y"+e];$(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var n=0,i=this._coordsList;n<i.length;n++)if(i[n].getAxis("x").index===t||i[n].getAxis("y").index===e)return i[n]},AM.prototype.getCartesians=function(){return this._coordsList.slice()},AM.prototype.convertToPixel=function(t,e,n){e=this._findConvertTarget(e);return e.cartesian?e.cartesian.dataToPoint(n):e.axis?e.axis.toGlobalCoord(e.axis.dataToCoord(n)):null},AM.prototype.convertFromPixel=function(t,e,n){e=this._findConvertTarget(e);return e.cartesian?e.cartesian.pointToData(n):e.axis?e.axis.coordToData(e.axis.toLocalCoord(n)):null},AM.prototype._findConvertTarget=function(t){var e,n,i=t.seriesModel,o=t.xAxisModel||i&&i.getReferringComponents("xAxis",Jo).models[0],r=t.yAxisModel||i&&i.getReferringComponents("yAxis",Jo).models[0],a=t.gridModel,t=this._coordsList;return i?V(t,e=i.coordinateSystem)<0&&(e=null):o&&r?e=this.getCartesian(o.componentIndex,r.componentIndex):o?n=this.getAxis("x",o.componentIndex):r?n=this.getAxis("y",r.componentIndex):a&&a.coordinateSystem===this&&(e=this._coordsList[0]),{cartesian:e,axis:n}},AM.prototype.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},AM.prototype._initCartesian=function(r,t,e){var a=this,s=this,l={left:!1,right:!1,top:!1,bottom:!1},u={x:{},y:{}},h={x:0,y:0};if(t.eachComponent("xAxis",n("x"),this),t.eachComponent("yAxis",n("y"),this),!h.x||!h.y)return this._axesMap={},void(this._axesList=[]);function n(o){return function(t,e){var n,i;kM(t,r)&&(i=t.get("position"),"x"===o?"top"!==i&&"bottom"!==i&&(i=l.bottom?"top":"bottom"):"left"!==i&&"right"!==i&&(i=l.left?"right":"left"),l[i]=!0,i="category"===(n=new MM(o,QS(t),[0,0],t.get("type"),i)).type,n.onBand=i&&t.get("boundaryGap"),n.inverse=t.get("inverse"),(t.axis=n).model=t,n.grid=s,n.index=e,s._axesList.push(n),u[o][e]=n,h[o]++)}}G((this._axesMap=u).x,function(i,o){G(u.y,function(t,e){var n="x"+o+"y"+e,e=new uM(n);e.master=a,e.model=r,a._coordsMap[n]=e,a._coordsList.push(e),e.addAxis(i),e.addAxis(t)})})},AM.prototype._updateScale=function(t,i){function o(e,n){G(oM(e,n.dim),function(t){n.scale.unionExtentFromData(e,t)})}G(this._axesList,function(t){var e;t.scale.setExtent(1/0,-1/0),"category"===t.type&&(e=t.model.get("categorySortInfo"),t.scale.setSortInfo(e))}),t.eachSeries(function(t){var e,n;CM(t)&&(n=(e=DM(t)).xAxisModel,e=e.yAxisModel,kM(n,i)&&kM(e,i)&&(n=this.getCartesian(n.componentIndex,e.componentIndex),e=t.getData(),t=n.getAxis("x"),n=n.getAxis("y"),"list"===e.type&&(o(e,t),o(e,n))))},this)},AM.prototype.getTooltipAxes=function(n){var i=[],o=[];return G(this.getCartesians(),function(t){var e=null!=n&&"auto"!==n?t.getAxis(n):t.getBaseAxis(),t=t.getOtherAxis(e);V(i,e)<0&&i.push(e),V(o,t)<0&&o.push(t)}),{baseAxes:i,otherAxes:o}},AM.create=function(i,o){var r=[];return i.eachComponent("grid",function(t,e){var n=new AM(t,i,o);n.name="grid_"+e,n.resize(t,o,!0),t.coordinateSystem=n,r.push(n)}),i.eachSeries(function(t){var e,n,i;CM(t)&&(e=(i=DM(t)).xAxisModel,n=i.yAxisModel,i=e.getCoordSysModel().coordinateSystem,t.coordinateSystem=i.getCartesian(e.componentIndex,n.componentIndex))}),r},AM.dimensions=rM,AM),RM=Math.PI,NM=(EM.prototype.hasBuilder=function(t){return!!zM[t]},EM.prototype.add=function(t){zM[t](this.opt,this.axisModel,this.group,this._transformGroup)},EM.prototype.getGroup=function(){return this.group},EM.innerTextLayout=function(t,e,n){var i,t=bo(e-t),n=wo(t)?(i=0<n?"top":"bottom","center"):wo(t-RM)?(i=0<n?"bottom":"top","center"):(i="middle",0<t&&t<RM?0<n?"right":"left":0<n?"left":"right");return{rotation:t,textAlign:n,textVerticalAlign:i}},EM.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},EM.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},EM),zM={axisLine:function(i,t,o,e){var r,a,s,l,u,n=t.get(["axisLine","show"]);(n="auto"===n&&i.handleAutoShown?i.handleAutoShown("axisLine"):n)&&(n=t.axis.getExtent(),e=e.transform,r=[n[0],0],n=[n[1],0],e&&(zt(r,r,e),zt(n,n,e)),a=N({lineCap:"round"},t.getModel(["axisLine","lineStyle"]).getLineStyle()),(e=new Kf({subPixelOptimize:!0,shape:{x1:r[0],y1:r[1],x2:n[0],y2:n[1]},style:a,strokeContainThreshold:i.strokeContainThreshold||5,silent:!0,z2:1})).anid="line",o.add(e),null!=(s=t.get(["axisLine","symbol"]))&&(e=t.get(["axisLine","symbolSize"]),"string"==typeof s&&(s=[s,s]),"string"!=typeof e&&"number"!=typeof e||(e=[e,e]),t=lm(t.get(["axisLine","symbolOffset"])||0,e),l=e[0],u=e[1],G([{rotate:i.rotation+Math.PI/2,offset:t[0],r:0},{rotate:i.rotation-Math.PI/2,offset:t[1],r:Math.sqrt((r[0]-n[0])*(r[0]-n[0])+(r[1]-n[1])*(r[1]-n[1]))}],function(t,e){var n;"none"!==s[e]&&null!=s[e]&&(n=am(s[e],-l/2,-u/2,l,u,a.stroke,!0),e=t.r+t.offset,n.attr({rotation:t.rotate,x:r[0]+e*Math.cos(i.rotation),y:r[1]-e*Math.sin(i.rotation),silent:!0,z2:11}),o.add(n))})))},axisTickLabel:function(t,e,n,i){var o=function(t,e,n,i){var o=n.axis,r=n.getModel("axisTick"),a=r.get("show");if((a="auto"===a&&i.handleAutoShown?i.handleAutoShown("axisTick"):a)&&!o.scale.isBlank()){for(var a=r.getModel("lineStyle"),r=i.tickDirection*r.get("length"),s=GM(o.getTicksCoords(),e.transform,r,z(a.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}),"ticks"),l=0;l<s.length;l++)t.add(s[l]);return s}}(n,i,e,t),r=function(l,u,h,c){var p=h.axis;if(ot(c.axisLabelShow,h.get(["axisLabel","show"]))&&!p.scale.isBlank()){var d=h.getModel("axisLabel"),f=d.get("margin"),t=p.getViewLabels(),e=(ot(c.labelRotate,d.get("rotate"))||0)*RM/180,g=NM.innerTextLayout(c.rotation,e,c.labelDirection),y=h.getCategories&&h.getCategories(!0),m=[],v=NM.isLabelSilent(h),x=h.get("triggerEvent");return G(t,function(t,e){var n="ordinal"===p.scale.type?p.scale.getRawOrdinalNumber(t.tickValue):t.tickValue,i=t.formattedLabel,o=t.rawLabel,r=d;y&&y[n]&&($(s=y[n])&&s.textStyle&&(r=new wu(s.textStyle,d,h.ecModel)));var a=r.getTextColor()||h.get(["axisLine","lineStyle","color"]),s=p.dataToCoord(n),a=new Fs({x:s,y:c.labelOffset+c.labelDirection*f,rotation:g.rotation,silent:v,z2:10+(t.level||0),style:eu(r,{text:i,align:r.getShallow("align",!0)||g.textAlign,verticalAlign:r.getShallow("verticalAlign",!0)||r.getShallow("baseline",!0)||g.textVerticalAlign,fill:"function"==typeof a?a("category"===p.type?o:"value"===p.type?n+"":n,e):a})});a.anid="label_"+n,x&&((n=NM.makeAxisEventDataBase(h)).targetType="axisLabel",n.value=o,Gs(a).eventData=n),u.add(a),a.updateTransform(),m.push(a),l.add(a),a.decomposeTransform()}),m}}(n,i,e,t);(function(t,e,n){{var i,o,r,a,s,l,u;iM(t.axis)||(i=t.get(["axisLabel","showMinLabel"]),o=t.get(["axisLabel","showMaxLabel"]),n=n||[],r=(e=e||[])[0],a=e[1],s=e[e.length-1],l=e[e.length-2],u=n[0],t=n[1],e=n[n.length-1],n=n[n.length-2],!1===i?(VM(r),VM(u)):BM(r,a)&&(i?(VM(a),VM(t)):(VM(r),VM(u))),!1===o?(VM(s),VM(e)):BM(l,s)&&(o?(VM(l),VM(n)):(VM(s),VM(e))))}})(e,r,o),function(t,e,n,i){var o=n.axis,r=n.getModel("minorTick");if(r.get("show")&&!o.scale.isBlank()){var a=o.getMinorTicksCoords();if(a.length)for(var o=r.getModel("lineStyle"),s=i*r.get("length"),l=z(o.getLineStyle(),z(n.getModel("axisTick").getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])})),u=0;u<a.length;u++)for(var h=GM(a[u],e.transform,s,l,"minorticks_"+u),c=0;c<h.length;c++)t.add(h[c])}}(n,i,e,t.tickDirection),e.get(["axisLabel","hideOverlap"])&&y1(d1(H(r,function(t){return{label:t,priority:t.z2,defaultAttr:{ignore:t.ignore}}})))},axisName:function(t,e,n,i){var o,r,a,s,l,u,h,c,p,d,f,g=ot(t.axisName,e.get("name"));g&&(o=e.get("nameLocation"),r=t.nameDirection,a=e.getModel("nameTextStyle"),u=e.get("nameGap")||0,l=(s=e.axis.getExtent())[0]>s[1]?-1:1,l=["start"===o?s[0]-l*u:"end"===o?s[1]+l*u:(s[0]+s[1])/2,FM(o)?t.labelOffset+r*u:0],null!=(u=e.get("nameRotate"))&&(u=u*RM/180),FM(o)?h=NM.innerTextLayout(t.rotation,null!=u?u:t.rotation,r):(c=t.rotation,p=o,d=s,c=bo((u||0)-c),d=d[0]>d[1],d="start"===p&&!d||"start"!==p&&d,d=wo(c-RM/2)?(f=d?"bottom":"top","center"):wo(c-1.5*RM)?(f=d?"top":"bottom","center"):(f="middle",c<1.5*RM&&RM/2<c?d?"left":"right":d?"right":"left"),h={rotation:c,textAlign:d,textVerticalAlign:f},null!=(p=t.axisNameAvailableWidth)&&(p=Math.abs(p/Math.sin(h.rotation)),isFinite(p)||(p=null))),c=a.getFont(),f=(d=e.get("nameTruncate",!0)||{}).ellipsis,p=ot(t.nameTruncateMaxWidth,d.maxWidth,p),em({el:h=new Fs({x:l[0],y:l[1],rotation:h.rotation,silent:NM.isLabelSilent(e),style:eu(a,{text:g,font:c,overflow:"truncate",width:p,ellipsis:f,fill:a.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:a.get("align")||h.textAlign,verticalAlign:a.get("verticalAlign")||h.textVerticalAlign}),z2:1}),componentModel:e,itemName:g}),h.__fullText=g,h.anid="name",e.get("triggerEvent")&&((e=NM.makeAxisEventDataBase(e)).targetType="axisName",e.name=g,Gs(h).eventData=e),i.add(h),h.updateTransform(),n.add(h),h.decomposeTransform())}};function EM(t,e){this.group=new ro,this.opt=e,this.axisModel=t,z(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});e=new ro({x:e.position[0],y:e.position[1],rotation:e.rotation});e.updateTransform(),this._transformGroup=e}function VM(t){t&&(t.ignore=!0)}function BM(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var o=ii([]);return si(o,o,-t.rotation),n.applyTransform(ri([],o,t.getLocalTransform())),i.applyTransform(ri([],o,e.getLocalTransform())),n.intersect(i)}}function FM(t){return"middle"===t||"center"===t}function GM(t,e,n,i,o){for(var r=[],a=[],s=[],l=0;l<t.length;l++){var u=t[l].coord;a[0]=u,s[a[1]=0]=u,s[1]=n,e&&(zt(a,a,e),zt(s,s,e));u=new Kf({subPixelOptimize:!0,shape:{x1:a[0],y1:a[1],x2:s[0],y2:s[1]},style:i,z2:2,autoBatch:!0,silent:!0});u.anid=o+"_"+t[l].tickValue,r.push(u)}return r}var HM=NM;function WM(t,e){var o,u,h,r,c,p,d,n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return u=n,e=e,r=(h=t).getComponent("tooltip"),c=h.getComponent("axisPointer"),p=c.get("link",!0)||[],d=[],G(e.getCoordinateSystems(),function(a){var s,l,t,e,n;function i(t,e,n){var i,o=n.model.getModel("axisPointer",c),r=o.get("show");r&&("auto"!==r||t||XM(o))&&(null==e&&(e=o.get("triggerTooltip")),i=(o=t?function(t,e,n,i,o,r){var a=e.getModel("axisPointer"),s={};G(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){s[t]=P(a.get(t))}),s.snap="category"!==t.type&&!!r,"cross"===a.get("type")&&(s.type="line");e=s.label||(s.label={});null==e.show&&(e.show=!1),"cross"===o&&(o=a.get(["label","show"]),e.show=null==o||o,r||(r=s.lineStyle=a.get("crossStyle"))&&z(e,r.textStyle));return t.model.getModel("axisPointer",new wu(s,n,i))}(n,l,c,h,t,e):o).get("snap"),r=ZM(n.model),t=e||i||"category"===n.type,o=u.axesInfo[r]={key:r,axis:n,coordSys:a,axisPointerModel:o,triggerTooltip:e,involveSeries:t,snap:i,useHandle:XM(o),seriesModels:[],linkGroup:null},s[r]=o,u.seriesInvolved=u.seriesInvolved||t,null!=(t=function(t,e){for(var n=e.model,i=e.dim,o=0;o<t.length;o++){var r=t[o]||{};if(UM(r[i+"AxisId"],n.id)||UM(r[i+"AxisIndex"],n.componentIndex)||UM(r[i+"AxisName"],n.name))return o}}(p,n))&&((n=d[t]||(d[t]={axesInfo:{}})).axesInfo[r]=o,n.mapper=p[t].mapper,o.linkGroup=n))}a.axisPointerEnabled&&(n=ZM(a.model),s=u.coordSysAxesInfo[n]={},l=(u.coordSysMap[n]=a).model.getModel("tooltip",r),G(a.getAxes(),Z(i,!1,null)),a.getTooltipAxes&&r&&l.get("show")&&(t="axis"===l.get("trigger"),e="cross"===l.get(["axisPointer","type"]),n=a.getTooltipAxes(l.get(["axisPointer","axis"])),(t||e)&&G(n.baseAxes,Z(i,!e||"cross",t)),e&&G(n.otherAxes,Z(i,"cross",!1))))}),n.seriesInvolved&&(o=n,t.eachSeries(function(n){var i=n.coordinateSystem,t=n.get(["tooltip","trigger"],!0),e=n.get(["tooltip","show"],!0);i&&"none"!==t&&!1!==t&&"item"!==t&&!1!==e&&!1!==n.get(["axisPointer","show"],!0)&&G(o.coordSysAxesInfo[ZM(i.model)],function(t){var e=t.axis;i.getAxis(e.dim)===e&&(t.seriesModels.push(n),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=n.getData().count())})})),n}function UM(t,e){return"all"===t||j(t)&&0<=V(t,e)||t===e}function YM(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[ZM(t)]}function XM(t){return!!t.get(["handle","show"])}function ZM(t){return t.type+"||"+t.id}var jM,qM={},KM=(d(QM,jM=Wd),QM.prototype.render=function(t,e,n,i){var o,r,a,s,l,u;this.axisPointerClass&&(u=YM(o=t))&&(s=u.axisPointerModel,l=u.axis.scale,r=s.option,a=s.get("status"),null!=(o=s.get("value"))&&(o=l.parse(o)),s=XM(s),null==a&&(r.status=s?"show":"hide"),(l=l.getExtent().slice())[0]>l[1]&&l.reverse(),(o=null==o||o>l[1]?l[1]:o)<l[0]&&(o=l[0]),r.value=o,s&&(r.status=u.axis.scale.isBlank()?"hide":"show")),jM.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,n,!0)},QM.prototype.updateAxisPointer=function(t,e,n,i){this._doUpdateAxisPointerClass(t,n,!1)},QM.prototype.remove=function(t,e){var n=this._axisPointer;n&&n.remove(e)},QM.prototype.dispose=function(t,e){this._disposeAxisPointer(e),jM.prototype.dispose.apply(this,arguments)},QM.prototype._doUpdateAxisPointerClass=function(t,e,n){var i,o=QM.getAxisPointerClass(this.axisPointerClass);o&&((i=(i=YM(i=t))&&i.axisPointerModel)?(this._axisPointer||(this._axisPointer=new o)).render(t,i,e,n):this._disposeAxisPointer(e))},QM.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},QM.registerAxisPointerClass=function(t,e){qM[t]=e},QM.getAxisPointerClass=function(t){return t&&qM[t]},QM.type="axis",QM),JM=Zo();function QM(){var t=null!==jM&&jM.apply(this,arguments)||this;return t.type=QM.type,t}function $M(t,e,n,i){var o=n.axis;if(!o.scale.isBlank()){var r=n.getModel("splitArea"),n=r.getModel("areaStyle"),a=n.get("color"),s=i.coordinateSystem.getRect(),l=o.getTicksCoords({tickModel:r,clamp:!0});if(l.length){var u=a.length,h=JM(t).splitAreaColors,c=yt(),p=0;if(h)for(var d=0;d<l.length;d++){var f=h.get(l[d].tickValue);if(null!=f){p=(f+(u-1)*d)%u;break}}for(var g=o.toGlobalCoord(l[0].coord),y=n.getAreaStyle(),a=j(a)?a:[a],d=1;d<l.length;d++){var m=o.toGlobalCoord(l[d].coord),v=void 0,x=void 0,_=void 0,b=void 0,g=o.isHorizontal()?(v=g,x=s.y,b=s.height,v+(_=m-v)):(v=s.x,x=g,_=s.width,x+(b=m-x)),m=l[d-1].tickValue;null!=m&&c.set(m,p),e.add(new Ts({anid:null!=m?"area_"+m:null,shape:{x:v,y:x,width:_,height:b},style:z({fill:a[p]},y),autoBatch:!0,silent:!0})),p=(p+1)%u}JM(t).splitAreaColors=c}}}function tI(t){JM(t).splitAreaColors=null}var eI,nI,iI,oI,rI=["axisLine","axisTickLabel","axisName"],aI=["splitArea","splitLine","minorSplitLine"],C=(d(gI,oI=KM),gI.prototype.render=function(o,t,e,n){this.group.removeAll();var r,i,a=this._axisGroup;this._axisGroup=new ro,this.group.add(this._axisGroup),o.get("show")&&(i=TM(r=o.getCoordSysModel(),o),i=new HM(o,N({handleAutoShown:function(t){for(var e=r.coordinateSystem.getCartesians(),n=0;n<e.length;n++){var i=e[n].getOtherAxis(o.axis).type;if("value"===i||"log"===i)return!0}return!1}},i)),G(rI,i.add,i),this._axisGroup.add(i.getGroup()),G(aI,function(t){o.get([t,"show"])&&sI[t](this,this._axisGroup,o,r)},this),n&&"changeAxisOrder"===n.type&&n.isInitSort||qy(a,this._axisGroup,o),oI.prototype.render.call(this,o,t,e,n))},gI.prototype.remove=function(){tI(this)},gI.type="cartesianAxis",gI),sI={splitLine:function(t,e,n,i){var o=n.axis;if(!o.scale.isBlank())for(var r=n.getModel("splitLine"),n=r.getModel("lineStyle"),a=j(a=n.get("color"))?a:[a],s=i.coordinateSystem.getRect(),l=o.isHorizontal(),u=0,h=o.getTicksCoords({tickModel:r}),c=[],p=[],d=n.getLineStyle(),f=0;f<h.length;f++){var g=o.toGlobalCoord(h[f].coord);l?(c[0]=g,c[1]=s.y,p[0]=g,p[1]=s.y+s.height):(c[0]=s.x,c[1]=g,p[0]=s.x+s.width,p[1]=g);var y=u++%a.length,g=h[f].tickValue;e.add(new Kf({anid:null!=g?"line_"+h[f].tickValue:null,subPixelOptimize:!0,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:p[0],y2:p[1]},style:z({stroke:a[y]},d),silent:!0}))}},minorSplitLine:function(t,e,n,i){var o=n.axis,n=n.getModel("minorSplitLine").getModel("lineStyle"),r=i.coordinateSystem.getRect(),a=o.isHorizontal(),s=o.getMinorTicksCoords();if(s.length)for(var l=[],u=[],h=n.getLineStyle(),c=0;c<s.length;c++)for(var p=0;p<s[c].length;p++){var d=o.toGlobalCoord(s[c][p].coord);a?(l[0]=d,l[1]=r.y,u[0]=d,u[1]=r.y+r.height):(l[0]=r.x,l[1]=d,u[0]=r.x+r.width,u[1]=d),e.add(new Kf({anid:"minor_line_"+s[c][p].tickValue,subPixelOptimize:!0,autoBatch:!0,shape:{x1:l[0],y1:l[1],x2:u[0],y2:u[1]},style:h,silent:!0}))}},splitArea:function(t,e,n,i){$M(t,e,n,i)}},lI=(d(fI,iI=C),fI.type="xAxis",fI),uI=(d(dI,nI=C),dI.type="yAxis",dI),hI=(d(pI,eI=Wd),pI.prototype.render=function(t,e){this.group.removeAll(),t.get("show")&&this.group.add(new Ts({shape:t.coordinateSystem.getRect(),style:z({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},pI.type="grid",pI),cI={offset:0};function pI(){var t=null!==eI&&eI.apply(this,arguments)||this;return t.type="grid",t}function dI(){var t=null!==nI&&nI.apply(this,arguments)||this;return t.type=lI.type,t}function fI(){var t=null!==iI&&iI.apply(this,arguments)||this;return t.type=fI.type,t}function gI(){var t=null!==oI&&oI.apply(this,arguments)||this;return t.type=gI.type,t.axisPointerClass="CartesianAxisPointer",t}function yI(t){t.registerComponentView(hI),t.registerComponentModel(jw),t.registerCoordinateSystem("cartesian2d",OM),hS(t,"x",Kw,cI),hS(t,"y",Kw,cI),t.registerComponentView(lI),t.registerComponentView(uI),t.registerPreprocessor(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})})}function mI(t){t.eachSeriesByType("radar",function(t){var e,i=t.getData(),o=[],r=t.coordinateSystem;r&&(G(e=r.getIndicatorAxes(),function(t,n){i.each(i.mapDimension(e[n].dim),function(t,e){o[e]=o[e]||[];t=r.dataToPoint(t,n);o[e][n]=vI(t)?t:xI(r)})}),i.each(function(t){var e=function(t,e,n){if(t&&e)for(var i=0,o=t.length;i<o;i++)if(e.call(n,t[i],i,t))return t[i]}(o[t],vI)||xI(r);o[t].push(e.slice()),i.setItemLayout(t,o[t])}))})}function vI(t){return!isNaN(t[0])&&!isNaN(t[1])}function xI(t){return[t.cx,t.cy]}function _I(n){var i,t=n.polar;t&&(j(t)||(t=[t]),i=[],G(t,function(t,e){t.indicator?(t.type&&!t.shape&&(t.shape=t.type),n.radar=n.radar||[],j(n.radar)||(n.radar=[n.radar]),n.radar.push(t)):i.push(t)}),n.polar=i),G(n.series,function(t){t&&"radar"===t.type&&t.polarIndex&&(t.radarIndex=t.polarIndex)})}var bI,wI,SI=(d(TI,wI=$d),TI.prototype.render=function(l,t,e){var n=l.coordinateSystem,h=this.group,c=l.getData(),a=this._data;function s(t,e,n,i,o,r){n.removeAll();for(var a=0;a<e.length-1;a++){var s=function(t,e){if("none"!==(i=t.getItemVisual(e,"symbol")||"circle")){var n=sm(t.getItemVisual(e,"symbolSize")),i=am(i,-1,-1,2,2),e=t.getItemVisual(e,"symbolRotate")||0;return i.attr({style:{strokeNoScale:!0},z2:100,scaleX:n[0]/2,scaleY:n[1]/2,rotation:e*Math.PI/180||0}),i}}(i,o);s&&(t[s.__dimIdx=a]?(s.setPosition(t[a]),p[r?"initProps":"updateProps"](s,{x:e[a][0],y:e[a][1]},l,o)):s.setPosition(e[a]),n.add(s))}}function u(t){return H(t,function(t){return[n.cx,n.cy]})}c.diff(a).add(function(t){var e,n,i,o,r=c.getItemLayout(t);r&&(e=new $g,n=new ny,o={shape:{points:r}},e.shape.points=u(r),n.shape.points=u(r),Ul(e,o,l,t),Ul(n,o,l,t),i=new ro,o=new ro,i.add(n),i.add(e),i.add(o),s(n.shape.points,r,o,c,t,!0),c.setItemGraphicEl(t,i))}).update(function(t,e){var n=a.getItemGraphicEl(e),i=n.childAt(0),o=n.childAt(1),r=n.childAt(2),e={shape:{points:c.getItemLayout(t)}};e.shape.points&&(s(i.shape.points,e.shape.points,r,c,t,!1),ql(o),ql(i),Wl(i,e,l),Wl(o,e,l),c.setItemGraphicEl(t,n))}).remove(function(t){h.remove(a.getItemGraphicEl(t))}).execute(),c.eachItemGraphicEl(function(t,n){var i=c.getItemModel(n),e=t.childAt(0),o=t.childAt(1),r=t.childAt(2),a=c.getItemVisual(n,"style"),s=a.fill;h.add(t),e.useStyle(z(i.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:s})),Nl(e,i,"lineStyle"),Nl(o,i,"areaStyle");var e=i.getModel("areaStyle"),l=e.isEmpty()&&e.parentModel.isEmpty();o.ignore=l,G(["emphasis","select","blur"],function(t){var e=i.getModel([t,"areaStyle"]),e=e.isEmpty()&&e.parentModel.isEmpty();o.ensureState(t).ignore=e&&l}),o.useStyle(z(e.getAreaStyle(),{fill:s,opacity:.7,decal:a.decal}));var e=i.getModel("emphasis"),u=e.getModel("itemStyle").getItemStyle();r.eachChild(function(t){t instanceof ys?(e=t.style,t.useStyle(N({image:e.image,x:e.x,y:e.y,width:e.width,height:e.height},a))):(t.useStyle(a),t.setColor(s),t.style.strokeNoScale=!0),t.ensureState("emphasis").style=P(u);var e=c.getStore().get(c.getDimensionIndex(t.__dimIdx),n);null!=e&&!isNaN(e)||(e=""),$l(t,tu(i),{labelFetcher:c.hostModel,labelDataIndex:n,labelDimIndex:t.__dimIdx,defaultText:e,inheritColor:s,defaultOpacity:a.opacity})}),Ll(t,e.get("focus"),e.get("blurScope"))}),this._data=c},TI.prototype.remove=function(){this.group.removeAll(),this._data=null},TI.type="radar",TI),MI=(d(II,bI=Gd),II.prototype.init=function(t){bI.prototype.init.apply(this,arguments),this.legendVisualProvider=new Rw(X(this.getData,this),X(this.getRawData,this))},II.prototype.getInitialData=function(t,e){return Pw(this,{generateCoord:"indicator_",generateCoordCount:1/0})},II.prototype.formatTooltip=function(n,t,e){var i=this.getData(),o=this.coordinateSystem.getIndicatorAxes(),r=this.getData().getName(n),r=""===r?this.name:r,a=Md(this,n);return md("section",{header:r,sortBlocks:!0,blocks:H(o,function(t){var e=i.get(i.mapDimension(t.dim),n);return md("nameValue",{markerType:"subItem",markerColor:a,name:t.name,value:e,sortParam:e})})})},II.prototype.getTooltipPosition=function(t){if(null!=t)for(var e=this.getData(),n=this.coordinateSystem,i=e.getValues(H(n.dimensions,function(t){return e.mapDimension(t)}),t),o=0,r=i.length;o<r;o++)if(!isNaN(i[o])){var a=n.getIndicatorAxes();return n.coordToPoint(a[o].dataToCoord(i[o]),o)}},II.type="series.radar",II.dependencies=["radar"],II.defaultOption={zlevel:0,z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},II),mu=oS.value;function II(){var t=null!==bI&&bI.apply(this,arguments)||this;return t.type=II.type,t.hasSymbolVisual=!0,t}function TI(){var t=null!==wI&&wI.apply(this,arguments)||this;return t.type=TI.type,t}function CI(t,e){return z({show:e},t)}var DI,AI,kI,LI=(d(BI,kI=Vh),BI.prototype.optionUpdated=function(){var n=this.get("boundaryGap"),i=this.get("splitNumber"),o=this.get("scale"),r=this.get("axisLine"),a=this.get("axisTick"),s=this.get("axisLabel"),l=this.get("axisName"),u=this.get(["axisName","show"]),h=this.get(["axisName","formatter"]),c=this.get("axisNameGap"),p=this.get("triggerEvent"),t=H(this.get("indicator")||[],function(t){null!=t.max&&0<t.max&&!t.min?t.min=0:null!=t.min&&t.min<0&&!t.max&&(t.max=0);var e=l;null!=t.color&&(e=z({color:t.color},l));t=O(P(t),{boundaryGap:n,splitNumber:i,scale:o,axisLine:r,axisTick:a,axisLabel:s,name:t.text,nameLocation:"end",nameGap:c,nameTextStyle:e,triggerEvent:p},!1);u||(t.name=""),"string"==typeof h?(e=t.name,t.name=h.replace("{value}",null!=e?e:"")):"function"==typeof h&&(t.name=h(t.name,t));t=new wu(t,null,this.ecModel);return B(t,qw.prototype),t.mainType="radar",t.componentIndex=this.componentIndex,t},this);this._indicatorModels=t},BI.prototype.getIndicatorModels=function(){return this._indicatorModels},BI.type="radar",BI.defaultOption={zlevel:0,z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:O({lineStyle:{color:"#bbb"}},mu.axisLine),axisLabel:CI(mu.axisLabel,!1),axisTick:CI(mu.axisTick,!1),splitLine:CI(mu.splitLine,!0),splitArea:CI(mu.splitArea,!0),indicator:[]},BI),PI=["axisLine","axisTickLabel","axisName"],OI=(d(VI,AI=Wd),VI.prototype.render=function(t,e,n){this.group.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},VI.prototype._buildAxes=function(t){var e=t.coordinateSystem;G(H(e.getIndicatorAxes(),function(t){return new HM(t.model,{position:[e.cx,e.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})}),function(t){G(PI,t.add,t),this.group.add(t.getGroup())},this)},VI.prototype._buildSplitLineAndArea=function(t){var n=t.coordinateSystem,e=n.getIndicatorAxes();if(e.length){var i=t.get("shape"),o=t.getModel("splitLine"),r=t.getModel("splitArea"),a=o.getModel("lineStyle"),t=r.getModel("areaStyle"),s=o.get("show"),l=r.get("show"),o=a.get("color"),r=t.get("color"),u=j(o)?o:[o],h=j(r)?r:[r],c=[],p=[];if("circle"===i)for(var d=e[0].getTicksCoords(),f=n.cx,g=n.cy,y=0;y<d.length;y++)s&&c[M(c,u,y)].push(new $f({shape:{cx:f,cy:g,r:d[y].coord}})),l&&y<d.length-1&&p[M(p,h,y)].push(new Xg({shape:{cx:f,cy:g,r0:d[y].coord,r:d[y+1].coord}}));else for(var m,v=H(e,function(t,e){t=t.getTicksCoords();return m=null==m?t.length-1:Math.min(t.length-1,m),H(t,function(t){return n.coordToPoint(t.coord,e)})}),x=[],y=0;y<=m;y++){for(var _=[],b=0;b<e.length;b++)_.push(v[b][y]);_[0]&&_.push(_[0].slice()),s&&c[M(c,u,y)].push(new ny({shape:{points:_}})),l&&x&&p[M(p,h,y-1)].push(new $g({shape:{points:_.concat(x)}})),x=_.slice().reverse()}var w=a.getLineStyle(),S=t.getAreaStyle();G(p,function(t,e){this.group.add(Fy(t,{style:z({stroke:"none",fill:h[e%h.length]},S),silent:!0}))},this),G(c,function(t,e){this.group.add(Fy(t,{style:z({fill:"none",stroke:u[e%u.length]},w),silent:!0}))},this)}function M(t,e,n){e=n%e.length;return t[e]=t[e]||[],e}},VI.type="radar",VI),RI=(d(EI,DI=_),EI),NI=(zI.prototype.getIndicatorAxes=function(){return this._indicatorAxes},zI.prototype.dataToPoint=function(t,e){var n=this._indicatorAxes[e];return this.coordToPoint(n.dataToCoord(t),e)},zI.prototype.coordToPoint=function(t,e){e=this._indicatorAxes[e].angle;return[this.cx+t*Math.cos(e),this.cy-t*Math.sin(e)]},zI.prototype.pointToData=function(t){var e=t[0]-this.cx,n=t[1]-this.cy,t=Math.sqrt(e*e+n*n);e/=t,n/=t;for(var i,o=Math.atan2(-n,e),r=1/0,a=-1,s=0;s<this._indicatorAxes.length;s++){var l=this._indicatorAxes[s],u=Math.abs(o-l.angle);u<r&&(i=l,a=s,r=u)}return[a,+(i&&i.coordToData(t))]},zI.prototype.resize=function(t,e){var n=t.get("center"),i=e.getWidth(),o=e.getHeight(),e=Math.min(i,o)/2;this.cx=go(n[0],i),this.cy=go(n[1],o),this.startAngle=t.get("startAngle")*Math.PI/180;t=t.get("radius");this.r0=go((t="string"==typeof t||"number"==typeof t?[0,t]:t)[0],e),this.r=go(t[1],e),G(this._indicatorAxes,function(t,e){t.setExtent(this.r0,this.r);e=this.startAngle+e*Math.PI*2/this._indicatorAxes.length,e=Math.atan2(Math.sin(e),Math.cos(e));t.angle=e},this)},zI.prototype.update=function(i,t){var o=this._indicatorAxes,r=this._model;G(o,function(t){t.scale.setExtent(1/0,-1/0)}),i.eachSeriesByType("radar",function(t,e){var n;"radar"===t.get("coordinateSystem")&&i.getComponent("radar",t.get("radarIndex"))===r&&(n=t.getData(),G(o,function(t){t.scale.unionExtentFromData(n,n.mapDimension(t.dim))}))},this);var h=r.get("splitNumber");function c(t){var e=Math.pow(10,Math.floor(Math.log(t)/Math.LN10)),t=t/e;return 2===t?t=5:t*=2,t*e}G(o,function(t,e){var n=KS(t.scale,t.model).extent;JS(t.scale,t.model);var i=t.model,o=t.scale,r=qS(o,i.get("min",!0)),a=qS(o,i.get("max",!0)),s=o.getInterval();if(null!=r&&null!=a)o.setExtent(+r,+a),o.setInterval((a-r)/h);else if(null!=r)for(var l=void 0;o.setExtent(+r,l=r+s*h),o.setInterval(s),s=c(s),l<n[1]&&isFinite(l)&&isFinite(n[1]););else if(null!=a)for(var u=void 0;o.setExtent(u=a-s*h,+a),o.setInterval(s),s=c(s),u>n[0]&&isFinite(u)&&isFinite(n[0]););else{i=o.getTicks().length-1;h<i&&(s=c(s)),u=yo((l=Math.ceil(n[1]/s)*s)-s*h),o.setExtent(u,l),o.setInterval(s)}})},zI.prototype.convertToPixel=function(t,e,n){return null},zI.prototype.convertFromPixel=function(t,e,n){return null},zI.prototype.containPoint=function(t){return!1},zI.create=function(t,n){var i=[];return t.eachComponent("radar",function(t){var e=new zI(t,0,n);i.push(e),t.coordinateSystem=e}),t.eachSeriesByType("radar",function(t){"radar"===t.get("coordinateSystem")&&(t.coordinateSystem=i[t.get("radarIndex")||0])}),i},zI.dimensions=[],zI);function zI(t,e,n){this.dimensions=[],this._model=t,this._indicatorAxes=H(t.getIndicatorModels(),function(t,e){var n="indicator_"+e,e=new RI(n,new DS);return e.name=t.get("name"),(e.model=t).axis=e,this.dimensions.push(n),e},this),this.resize(t,n)}function EI(t,e,n){n=DI.call(this,t,e,n)||this;return n.type="value",n.angle=0,n.name="",n}function VI(){var t=null!==AI&&AI.apply(this,arguments)||this;return t.type=VI.type,t}function BI(){var t=null!==kI&&kI.apply(this,arguments)||this;return t.type=BI.type,t}function FI(t){t.registerCoordinateSystem("radar",NI),t.registerComponentModel(LI),t.registerComponentView(OI),t.registerVisual({seriesType:"radar",reset:function(t){var e=t.getData();e.each(function(t){e.setItemVisual(t,"legendIcon","roundRect")}),e.setVisual("legendIcon","roundRect")}})}var GI,HI="\0_ec_interaction_mutex";function WI(t,e){return UI(t)[e]}function UI(t){return t[HI]||(t[HI]={})}function YI(n){var t=GI.call(this)||this;t._zr=n;var i=X(t._mousedownHandler,t),o=X(t._mousemoveHandler,t),r=X(t._mouseupHandler,t),a=X(t._mousewheelHandler,t),s=X(t._pinchHandler,t);return t.enable=function(t,e){this.disable(),this._opt=z(P(e)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),!0!==(t=null==t?!0:t)&&"move"!==t&&"pan"!==t||(n.on("mousedown",i),n.on("mousemove",o),n.on("mouseup",r)),!0!==t&&"scale"!==t&&"zoom"!==t||(n.on("mousewheel",a),n.on("pinch",s))},t.disable=function(){n.off("mousedown",i),n.off("mousemove",o),n.off("mouseup",r),n.off("mousewheel",a),n.off("pinch",s)},t}function XI(t,e,n,i,o){t.pointerChecker&&t.pointerChecker(i,o.originX,o.originY)&&(re(i.event),ZI(t,e,n,i,o))}function ZI(t,e,n,i,o){o.isAvailableBehavior=X(jI,null,n,i),t.trigger(e,o)}function jI(t,e,n){n=n[t];return!t||n&&(!K(n)||e.event[n+"Key"])}Vv({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){});var qI=(d(YI,GI=Gt),YI.prototype.isDragging=function(){return this._dragging},YI.prototype.isPinching=function(){return this._pinching},YI.prototype.setPointerChecker=function(t){this.pointerChecker=t},YI.prototype.dispose=function(){this.disable()},YI.prototype._mousedownHandler=function(t){var e,n;ae(t)||t.target&&t.target.draggable||(e=t.offsetX,n=t.offsetY,this.pointerChecker&&this.pointerChecker(t,e,n)&&(this._x=e,this._y=n,this._dragging=!0))},YI.prototype._mousemoveHandler=function(t){var e,n,i,o,r,a;this._dragging&&jI("moveOnMouseMove",t,this._opt)&&"pinch"!==t.gestureEvent&&!WI(this._zr,"globalPan")&&(e=t.offsetX,n=t.offsetY,r=e-(i=this._x),a=n-(o=this._y),this._x=e,this._y=n,this._opt.preventDefaultMouseMove&&re(t.event),ZI(this,"pan","moveOnMouseMove",t,{dx:r,dy:a,oldX:i,oldY:o,newX:e,newY:n,isAvailableBehavior:null}))},YI.prototype._mouseupHandler=function(t){ae(t)||(this._dragging=!1)},YI.prototype._mousewheelHandler=function(t){var e=jI("zoomOnMouseWheel",t,this._opt),n=jI("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),r=t.offsetX,a=t.offsetY;0!==i&&(e||n)&&(e&&(o=3<o?1.4:1<o?1.2:1.1,XI(this,"zoom","zoomOnMouseWheel",t,{scale:0<i?o:1/o,originX:r,originY:a,isAvailableBehavior:null})),n&&XI(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(0<i?1:-1)*(3<(i=Math.abs(i))?.4:1<i?.15:.05),originX:r,originY:a,isAvailableBehavior:null}))},YI.prototype._pinchHandler=function(t){WI(this._zr,"globalPan")||XI(this,"zoom",null,t,{scale:1<t.pinchScale?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})},YI);function KI(t,e,n){t=t.target;t.x+=e,t.y+=n,t.dirty()}function JI(t,e,n,i){var o=t.target,r=t.zoomLimit,a=t.zoom=t.zoom||1;a*=e,r&&(s=r.min||0,r=r.max||1/0,a=Math.max(Math.min(r,a),s));var s=a/t.zoom;t.zoom=a,o.x-=(n-o.x)*(s-1),o.y-=(i-o.y)*(s-1),o.scaleX*=s,o.scaleY*=s,o.dirty()}var QI={axisPointer:1,tooltip:1,brush:1};function $I(t,e,n){e=e.getComponentByElement(t.topTarget),t=e&&e.coordinateSystem;return e&&e!==n&&!QI.hasOwnProperty(e.mainType)&&t&&t.model!==n}var Jn=["rect","circle","line","ellipse","polygon","polyline","path"],t2=yt(Jn),e2=yt(Jn.concat(["g"])),n2=yt(Jn.concat(["g"])),i2=Zo();function o2(t){var e=t.getItemStyle(),t=t.get("areaColor");return null!=t&&(e.fill=t),e}function r2(t){var e=new ro;this.uid=Mu("ec_map_draw"),this._controller=new qI(t.getZr()),this._controllerHost={target:e},(this.group=e).add(this._regionsGroup=new ro),e.add(this._svgGroup=new ro)}function a2(t,e,n,i){var o=i.getModel("itemStyle"),r=i.getModel(["emphasis","itemStyle"]),a=i.getModel(["blur","itemStyle"]),s=i.getModel(["select","itemStyle"]),l=o2(o),i=o2(r),o=o2(s),r=o2(a),s=t.data;s&&(a=s.getItemVisual(n,"style"),n=s.getItemVisual(n,"decal"),t.isVisualEncodedByVisualMap&&a.fill&&(l.fill=a.fill),n&&(l.decal=zm(n,t.api))),e.setStyle(l),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=i,e.ensureState("select").style=o,e.ensureState("blur").style=r,yl(e)}function s2(t,e,n,i,o,r,a){var s=t.data,l=t.isGeo,u=s&&isNaN(s.get(s.mapDimension("value"),r)),t=s&&s.getItemLayout(r);l||u||t&&t.showLabel?(l=l?n:r,r=!s||0<=r?o:void 0,o=a?{normal:{align:"center",verticalAlign:"middle"}}:null,$l(e,tu(i),{labelFetcher:r,labelDataIndex:l,defaultText:n},o),(o=e.getTextContent())&&(i2(o).ignore=o.ignore,e.textConfig&&a)&&(o=e.getBoundingRect().clone(),e.textConfig.layoutRect=o,e.textConfig.position=[(a[0]-o.x)/o.width*100+"%",(a[1]-o.y)/o.height*100+"%"]),e.disableLabelAnimation=!0):(e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null)}function l2(t,e,n,i,o,r){t.data?t.data.setItemGraphicEl(r,e):Gs(e).eventData={componentType:"geo",componentIndex:o.componentIndex,geoIndex:o.componentIndex,name:n,region:i&&i.option||{}}}function u2(t,e,n,i,o){t.data||em({el:e,componentModel:o,itemName:n,itemTooltipOption:i.get("tooltip")})}function h2(t,e,n,i,o){e.highDownSilentOnTouch=!!o.get("selectedMode");var r=i.getModel("emphasis"),i=r.get("focus");return Ll(e,i,r.get("blurScope")),t.isGeo&&(o=o,n=n,(e=Gs(e=e)).componentMainType=o.mainType,e.componentIndex=o.componentIndex,e.componentHighDownName=n),i}var c2,p2,d2=(r2.prototype.draw=function(e,t,n,i,o){var r="geo"===e.mainType,a=e.getData&&e.getData();r&&t.eachComponent({mainType:"series",subType:"map"},function(t){a||t.getHostGeoModel()!==e||(a=t.getData())});var s=e.coordinateSystem,l=this._regionsGroup,u=this.group,h=s.getTransformInfo(),c=h.raw,h=h.roam;!l.childAt(0)||o?(u.x=h.x,u.y=h.y,u.scaleX=h.scaleX,u.scaleY=h.scaleY,u.dirty()):Wl(u,h,e);h=a&&a.getVisual("visualMeta")&&0<a.getVisual("visualMeta").length,c={api:n,geo:s,mapOrGeoModel:e,data:a,isVisualEncodedByVisualMap:h,isGeo:r,transformInfoRaw:c};"geoJSON"===s.resourceType?this._buildGeoJSON(c):"geoSVG"===s.resourceType&&this._buildSVG(c),this._updateController(e,t,n),this._updateMapSelectHandler(e,l,n,i)},r2.prototype._buildGeoJSON=function(r){function s(t){return[t[0]*e.scaleX+e.x,t[1]*e.scaleY+e.y]}var l=this._regionsGroupByName=yt(),u=yt(),h=this._regionsGroup,e=r.transformInfoRaw,c=r.mapOrGeoModel,p=r.data;h.removeAll(),G(r.geo.regions,function(t){var e=t.name,n=l.get(e),i=u.get(e)||{},o=i.dataIdx,i=i.regionModel;n||(n=l.set(e,new ro),h.add(n),o=p?p.indexOfName(e):null,i=r.isGeo?c.getRegionModel(e):p?p.getItemModel(o):null,u.set(e,{dataIdx:o,regionModel:i}));var a=new dy({segmentIgnoreThreshold:1,shape:{paths:[]}});n.add(a),G(t.geometries,function(t){if("polygon"===t.type){for(var e=[],n=0;n<t.exterior.length;++n)e.push(s(t.exterior[n]));for(a.shape.paths.push(new $g({segmentIgnoreThreshold:1,shape:{points:e}})),n=0;n<(t.interiors?t.interiors.length:0);++n){for(var i=t.interiors[n],o=[],r=0;r<i.length;++r)o.push(s(i[r]));a.shape.paths.push(new $g({segmentIgnoreThreshold:1,shape:{points:o}}))}}}),a2(r,a,o,i),a instanceof Fr&&(a.culling=!0);t=s(t.getCenter());s2(r,a,e,i,c,o,t)}),l.each(function(t,e){var n=u.get(e),i=n.dataIdx,n=n.regionModel;l2(r,t,e,n,c,i),u2(r,t,e,n,c),h2(r,t,e,n,c)},this)},r2.prototype._buildSVG=function(s){var t=s.geo.map,e=s.transformInfoRaw;this._svgGroup.x=e.x,this._svgGroup.y=e.y,this._svgGroup.scaleX=e.scaleX,this._svgGroup.scaleY=e.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var l=this._svgDispatcherMap=yt(),u=!1;G(this._svgGraphicRecord.named,function(t){var e=t.name,n=s.mapOrGeoModel,i=s.data,o=t.svgNodeTagLower,r=t.el,a=i?i.indexOfName(e):null,i=n.getRegionModel(e);null!=t2.get(o)&&r instanceof Fr&&a2(s,r,a,i),r instanceof Fr&&(r.culling=!0),r.z2EmphasisLift=0,t.namedFrom||(null!=n2.get(o)&&s2(s,r,e,i,n,a,null),l2(s,r,e,i,n,a),u2(s,r,e,i,n),null==e2.get(o))||("self"===h2(s,r,e,i,n)&&(u=!0),(l.get(e)||l.set(e,[])).push(r))},this),this._enableBlurEntireSVG(u,s)},r2.prototype._enableBlurEntireSVG=function(t,e){var n;t&&e.isGeo&&(n=e.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle().opacity,this._svgGraphicRecord.root.traverse(function(t){var e;t.isGroup||(yl(t),null==(e=t.ensureState("blur").style||{}).opacity&&null!=n&&(e.opacity=n),t.ensureState("emphasis"))}))},r2.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},r2.prototype.findHighDownDispatchers=function(t,e){if(null==t)return[];var n=e.coordinateSystem;if("geoJSON"===n.resourceType){e=this._regionsGroupByName;if(e){e=e.get(t);return e?[e]:[]}}else if("geoSVG"===n.resourceType)return this._svgDispatcherMap&&this._svgDispatcherMap.get(t)||[]},r2.prototype._svgResourceChanged=function(t){return this._svgMapName!==t},r2.prototype._useSVG=function(t){var e=O0(t);e&&"geoSVG"===e.type&&(e=e.useGraphic(this.uid),this._svgGroup.add(e.root),this._svgGraphicRecord=e,this._svgMapName=t)},r2.prototype._freeSVG=function(){var t=this._svgMapName;null!=t&&((t=O0(t))&&"geoSVG"===t.type&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null)},r2.prototype._updateController=function(i,t,o){var r=i.coordinateSystem,e=this._controller,n=this._controllerHost;n.zoomLimit=i.get("scaleLimit"),n.zoom=r.getZoom(),e.enable(i.get("roam")||!1);var a=i.mainType;function s(){var t={type:"geoRoam",componentType:a};return t[a+"Id"]=i.id,t}e.off("pan").on("pan",function(t){this._mouseDownFlag=!1,KI(n,t.dx,t.dy),o.dispatchAction(N(s(),{dx:t.dx,dy:t.dy}))},this),e.off("zoom").on("zoom",function(t){this._mouseDownFlag=!1,JI(n,t.scale,t.originX,t.originY),o.dispatchAction(N(s(),{zoom:t.scale,originX:t.originX,originY:t.originY}))},this),e.setPointerChecker(function(t,e,n){return r.containPoint([e,n])&&!$I(t,o,i)})},r2.prototype.resetForLabelLayout=function(){this.group.traverse(function(t){t=t.getTextContent();t&&(t.ignore=i2(t).ignore)})},r2.prototype._updateMapSelectHandler=function(t,e,n,i){var o=this;e.off("mousedown"),e.off("click"),t.get("selectedMode")&&(e.on("mousedown",function(){o._mouseDownFlag=!0}),e.on("click",function(t){o._mouseDownFlag&&(o._mouseDownFlag=!1)}))},r2),f2=(d(m2,p2=$d),m2.prototype.render=function(t,e,n,i){var o,r;i&&"mapToggleSelect"===i.type&&i.from===this.uid||((o=this.group).removeAll(),t.getHostGeoModel()||(this._mapDraw&&i&&"geoRoam"===i.type&&this._mapDraw.resetForLabelLayout(),i&&"geoRoam"===i.type&&"series"===i.componentType&&i.seriesId===t.id?(r=this._mapDraw)&&o.add(r.group):t.needsDrawMap?(r=this._mapDraw||new d2(n),o.add(r.group),r.draw(t,e,n,this,i),this._mapDraw=r):(this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null),t.get("showLegendSymbol")&&e.getComponent("legend")&&this._renderSymbols(t,e,n)))},m2.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},m2.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},m2.prototype._renderSymbols=function(r,t,e){var a=r.originalData,s=this.group;a.each(a.mapDimension("value"),function(t,e){var n,i,o;isNaN(t)||(o=a.getItemLayout(e))&&o.point&&(t=o.point,o=o.offset,n=new $f({style:{fill:r.getData().getVisual("style").fill},shape:{cx:t[0]+9*o,cy:t[1],r:3},silent:!0,z2:8+(o?0:11)}),o||(t=r.mainSeries.getData(),o=a.getName(e),i=t.indexOfName(o),e=(o=a.getItemModel(e)).getModel("label"),t=t.getItemGraphicEl(i),$l(n,tu(o),{labelFetcher:{getFormattedLabel:function(t,e){return r.getFormattedLabel(i,e)}}}),n.disableLabelAnimation=!0,e.get("position")||n.setTextConfig({position:"bottom"}),t.onHoverStateChange=function(t){dl(n,t)}),s.add(n))})},m2.type="map",m2),g2=(d(y2,c2=Gd),y2.prototype.getInitialData=function(t){for(var e=Pw(this,{coordDimensions:["value"],encodeDefaulter:Z(Qh,this)}),n=yt(),i=[],o=0,r=e.count();o<r;o++){var a=e.getName(o);n.set(a,!0)}return G(R0(this.getMapType(),this.option.nameMap,this.option.nameProperty).regions,function(t){t=t.name;n.get(t)||i.push(t)}),e.appendValues([],i),e},y2.prototype.getHostGeoModel=function(){var t=this.option.geoIndex;return null!=t?this.ecModel.getComponent("geo",t):null},y2.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},y2.prototype.getRawValue=function(t){var e=this.getData();return e.get(e.mapDimension("value"),t)},y2.prototype.getRegionModel=function(t){var e=this.getData();return e.getItemModel(e.indexOfName(t))},y2.prototype.formatTooltip=function(t,e,n){for(var i=this.getData(),o=this.getRawValue(t),r=i.getName(t),a=this.seriesGroup,s=[],l=0;l<a.length;l++){var u=a[l].originalData.indexOfName(r),h=i.mapDimension("value");isNaN(a[l].originalData.get(h,u))||s.push(a[l].name)}return md("section",{header:s.join(", "),noHeader:!s.length,blocks:[md("nameValue",{name:r,value:o})]})},y2.prototype.setZoom=function(t){this.option.zoom=t},y2.prototype.setCenter=function(t){this.option.center=t},y2.prototype.getLegendIcon=function(t){var e=t.icon||"roundRect",n=am(e,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return n.setStyle(t.itemStyle),n.style.stroke="none",-1<e.indexOf("empty")&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},y2.type="series.map",y2.dependencies=["geo"],y2.layoutMode="box",y2.defaultOption={zlevel:0,z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},y2);function y2(){var t=null!==c2&&c2.apply(this,arguments)||this;return t.type=y2.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(t){if(null!=t){var e=this.getData().getName(t),t=this.coordinateSystem,e=t.getRegion(e);return e&&t.dataToPoint(e.getCenter())}},t}function m2(){var t=null!==p2&&p2.apply(this,arguments)||this;return t.type=m2.type,t}function v2(t){var n={};t.eachSeriesByType("map",function(t){var e=t.getHostGeoModel(),e=e?"o"+e.id:"i"+t.getMapType();(n[e]=n[e]||[]).push(t)}),G(n,function(t,e){for(var l,u,h,n=(l=H(t,function(t){return t.getData()}),u=t[0].get("mapValueCalculation"),h={},G(l,function(n){n.each(n.mapDimension("value"),function(t,e){e="ec-"+n.getName(e);h[e]=h[e]||[],isNaN(t)||h[e].push(t)})}),l[0].map(l[0].mapDimension("value"),function(t,e){for(var n="ec-"+l[0].getName(e),i=0,o=1/0,r=-1/0,a=h[n].length,s=0;s<a;s++)o=Math.min(o,h[n][s]),r=Math.max(r,h[n][s]),i+=h[n][s];return 0===a?NaN:"min"===u?o:"max"===u?r:"average"===u?i/a:i})),i=0;i<t.length;i++)t[i].originalData=t[i].getData();for(i=0;i<t.length;i++)(t[i].seriesGroup=t)[i].needsDrawMap=0===i&&!t[i].getHostGeoModel(),t[i].setData(n.cloneShallow()),t[i].mainSeries=t[0]})}function x2(n){var o={};n.eachSeriesByType("map",function(t){var a,i,e=t.getMapType();t.getHostGeoModel()||o[e]||(a={},G(t.seriesGroup,function(t){var o=t.coordinateSystem,r=t.originalData;t.get("showLegendSymbol")&&n.getComponent("legend")&&r.each(r.mapDimension("value"),function(t,e){var n=r.getName(e),i=o.getRegion(n);i&&!isNaN(t)&&(t=a[n]||0,i=o.dataToPoint(i.getCenter()),a[n]=t+1,r.setItemLayout(e,{point:i,offset:t}))})}),(i=t.getData()).each(function(t){var e=i.getName(t),n=i.getItemLayout(t)||{};n.showLabel=!a[e],i.setItemLayout(t,n)}),o[e]=!0)})}var _2,b2=zt;function w2(t){var e=_2.call(this)||this;return e.type="view",e.dimensions=["x","y"],e._roamTransformable=new _i,e._rawTransformable=new _i,e.name=t,e}function S2(t){t=t.seriesModel;return t?t.coordinateSystem:null}var M2,I2=(d(w2,_2=_i),w2.prototype.setBoundingRect=function(t,e,n,i){return this._rect=new ki(t,e,n,i),this._rect},w2.prototype.getBoundingRect=function(){return this._rect},w2.prototype.setViewRect=function(t,e,n,i){this._transformTo(t,e,n,i),this._viewRect=new ki(t,e,n,i)},w2.prototype._transformTo=function(t,e,n,i){var o=this.getBoundingRect(),r=this._rawTransformable;r.transform=o.calculateTransform(new ki(t,e,n,i));i=r.parent;r.parent=null,r.decomposeTransform(),r.parent=i,this._updateTransform()},w2.prototype.setCenter=function(t){t&&(this._center=t,this._updateCenterAndZoom())},w2.prototype.setZoom=function(t){t=t||1;var e=this.zoomLimit;e&&(null!=e.max&&(t=Math.min(e.max,t)),null!=e.min&&(t=Math.max(e.min,t))),this._zoom=t,this._updateCenterAndZoom()},w2.prototype.getDefaultCenter=function(){var t=this.getBoundingRect();return[t.x+t.width/2,t.y+t.height/2]},w2.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},w2.prototype.getZoom=function(){return this._zoom||1},w2.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},w2.prototype._updateCenterAndZoom=function(){var t=this._rawTransformable.getLocalTransform(),e=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),o=this.getZoom(),i=zt([],i,t),n=zt([],n,t);e.originX=i[0],e.originY=i[1],e.x=n[0]-i[0],e.y=n[1]-i[1],e.scaleX=e.scaleY=o,this._updateTransform()},w2.prototype._updateTransform=function(){var t=this._roamTransformable,e=this._rawTransformable;(e.parent=t).updateTransform(),e.updateTransform(),oi(this.transform||(this.transform=[]),e.transform||ni()),this._rawTransform=e.getLocalTransform(),this.invTransform=this.invTransform||[],ui(this.invTransform,this.transform),this.decomposeTransform()},w2.prototype.getTransformInfo=function(){var t=this._rawTransformable,e=this._roamTransformable,n=new _i;return n.transform=e.transform,n.decomposeTransform(),{roam:{x:n.x,y:n.y,scaleX:n.scaleX,scaleY:n.scaleY},raw:{x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY}}},w2.prototype.getViewRect=function(){return this._viewRect},w2.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},w2.prototype.dataToPoint=function(t,e,n){e=e?this._rawTransform:this.transform;return n=n||[],e?b2(n,t,e):Mt(n,t)},w2.prototype.pointToData=function(t){var e=this.invTransform;return e?b2([],t,e):[t[0],t[1]]},w2.prototype.convertToPixel=function(t,e,n){e=S2(e);return e===this?e.dataToPoint(n):null},w2.prototype.convertFromPixel=function(t,e,n){e=S2(e);return e===this?e.pointToData(n):null},w2.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},w2.dimensions=["x","y"],w2),T2={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},C2=["lng","lat"],gr=(d(D2,M2=I2),D2.prototype._transformTo=function(t,e,n,i){var o=this.getBoundingRect(),r=this._invertLongitute,o=o.clone();r&&(o.y=-o.y-o.height);var a=this._rawTransformable;a.transform=o.calculateTransform(new ki(t,e,n,i));i=a.parent;a.parent=null,a.decomposeTransform(),a.parent=i,r&&(a.scaleY=-a.scaleY),this._updateTransform()},D2.prototype.getRegion=function(t){return this._regionsMap.get(t)},D2.prototype.getRegionByCoord=function(t){for(var e=this.regions,n=0;n<e.length;n++){var i=e[n];if("geoJSON"===i.type&&i.contain(t))return e[n]}},D2.prototype.addGeoCoord=function(t,e){this._nameCoordMap.set(t,e)},D2.prototype.getGeoCoord=function(t){var e=this._regionsMap.get(t);return this._nameCoordMap.get(t)||e&&e.getCenter()},D2.prototype.dataToPoint=function(t,e,n){if(t="string"==typeof t?this.getGeoCoord(t):t)return I2.prototype.dataToPoint.call(this,t,e,n)},D2.prototype.convertToPixel=function(t,e,n){e=A2(e);return e===this?e.dataToPoint(n):null},D2.prototype.convertFromPixel=function(t,e,n){e=A2(e);return e===this?e.pointToData(n):null},D2);function D2(t,e,n){var i=M2.call(this,t)||this;i.dimensions=C2,i.type="geo",i._nameCoordMap=yt(),i.map=e;t=R0(e,n.nameMap,n.nameProperty),e=O0(e);i.resourceType=e?e.type:null;e=T2[e.type];i._regionsMap=t.regionsMap,i._invertLongitute=e.invertLongitute,i.regions=t.regions,i.aspectScale=rt(n.aspectScale,e.aspectScale);t=t.boundingRect;return i.setBoundingRect(t.x,t.y,t.width,t.height),i}function A2(t){var e=t.geoModel,t=t.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",Jo).models[0]||{}).coordinateSystem:null}B(gr,I2);var k2=gr;function L2(t,e){var n=t.get("boundingCoords");null!=n&&(u=n[0],l=n[1],isNaN(u[0])||isNaN(u[1])||isNaN(l[0])||isNaN(l[1])||this.setBoundingRect(u[0],u[1],l[0]-u[0],l[1]-u[1]));var i,o,r,a=this.getBoundingRect(),s=t.get("layoutCenter"),n=t.get("layoutSize"),l=e.getWidth(),u=e.getHeight(),e=a.width/a.height*this.aspectScale,a=!1;s&&n&&(r=[go(s[0],l),go(s[1],u)],i=go(n,Math.min(l,u)),isNaN(r[0])||isNaN(r[1])||isNaN(i)||(a=!0)),a?(o={},1<e?(o.width=i,o.height=i/e):(o.height=i,o.width=i*e),o.y=r[1]-o.height/2,o.x=r[0]-o.width/2):((r=t.getBoxLayoutParams()).aspect=e,o=Sh(r,{width:l,height:u})),this.setViewRect(o.x,o.y,o.width,o.height),this.setCenter(t.get("center")),this.setZoom(t.get("zoom"))}var P2,O2=new(z2.prototype.create=function(t,o){var r=[];t.eachComponent("geo",function(t,e){var n=t.get("map"),n=new k2(n+e,n,{nameMap:t.get("nameMap"),nameProperty:t.get("nameProperty"),aspectScale:t.get("aspectScale")});n.zoomLimit=t.get("scaleLimit"),r.push(n),(t.coordinateSystem=n).model=t,n.resize=L2,n.resize(t,o)}),t.eachSeries(function(t){var e;"geo"===t.get("coordinateSystem")&&(e=t.get("geoIndex")||0,t.coordinateSystem=r[e])});var n={};return t.eachSeriesByType("map",function(t){var e;t.getHostGeoModel()||(e=t.getMapType(),n[e]=n[e]||[],n[e].push(t))}),G(n,function(t,e){var n=H(t,function(t){return t.get("nameMap")}),i=new k2(e,e,{nameMap:R(n),nameProperty:t[0].get("nameProperty"),aspectScale:t[0].get("aspectScale")});i.zoomLimit=ot.apply(null,H(t,function(t){return t.get("scaleLimit")})),r.push(i),i.resize=L2,i.resize(t[0],o),G(t,function(t){var n;t.coordinateSystem=i,n=i,G(t.get("geoCoord"),function(t,e){n.addGeoCoord(e,t)})})}),r},z2.prototype.getFilledRegions=function(t,e,n,i){for(var o=(t||[]).slice(),r=yt(),a=0;a<o.length;a++)r.set(o[a].name,o[a]);return G(R0(e,n,i).regions,function(t){t=t.name;r.get(t)||o.push({name:t})}),o},z2),R2=(d(N2,P2=Vh),N2.prototype.init=function(t,e,n){var i=O0(t.map);i&&"geoJSON"===i.type&&("color"in(i=t.itemStyle=t.itemStyle||{})||(i.color="#eee")),this.mergeDefaultAndTheme(t,n),zo(t,"label",["show"])},N2.prototype.optionUpdated=function(){var i=this,t=this.option;t.regions=O2.getFilledRegions(t.regions,t.map,t.nameMap,t.nameProperty);var o={};this._optionModelMap=W(t.regions||[],function(t,e){var n=e.name;return n&&(t.set(n,new wu(e,i,i.ecModel)),e.selected&&(o[n]=!0)),t},yt()),t.selectedMap||(t.selectedMap=o)},N2.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new wu(null,this,this.ecModel)},N2.prototype.getFormattedLabel=function(t,e){var n=this.getRegionModel(t),i="normal"===e?n.get(["label","formatter"]):n.get(["emphasis","label","formatter"]),n={name:t};return"function"==typeof i?(n.status=e,i(n)):"string"==typeof i?i.replace("{a}",null!=t?t:""):void 0},N2.prototype.setZoom=function(t){this.option.zoom=t},N2.prototype.setCenter=function(t){this.option.center=t},N2.prototype.select=function(t){var e=this.option,n=e.selectedMode;n&&("multiple"!==n&&(e.selectedMap=null),(e.selectedMap||(e.selectedMap={}))[t]=!0)},N2.prototype.unSelect=function(t){var e=this.option.selectedMap;e&&(e[t]=!1)},N2.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},N2.prototype.isSelected=function(t){var e=this.option.selectedMap;return!(!e||!e[t])},N2.type="geo",N2.layoutMode="box",N2.defaultOption={zlevel:0,z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},N2);function N2(){var t=null!==P2&&P2.apply(this,arguments)||this;return t.type=N2.type,t}function z2(){this.dimensions=C2}function E2(t,e,n){var i,o=t.getZoom(),r=t.getCenter(),a=e.zoom,r=t.dataToPoint(r);return null!=e.dx&&null!=e.dy&&(r[0]-=e.dx,r[1]-=e.dy,t.setCenter(t.pointToData(r))),null!=a&&(n&&(i=n.min||0,n=n.max||1/0,a=Math.max(Math.min(o*a,n),i)/o),t.scaleX*=a,t.scaleY*=a,i=(e.originX-t.x)*(a-1),e=(e.originY-t.y)*(a-1),t.x-=i,t.y-=e,t.updateTransform(),t.setCenter(t.pointToData(r)),t.setZoom(a*o)),{center:t.getCenter(),zoom:t.getZoom()}}var V2,B2=(d(F2,V2=Wd),F2.prototype.init=function(t,e){this._api=e},F2.prototype.render=function(t,e,n,i){if(!(this._model=t).get("show"))return this._mapDraw&&this._mapDraw.remove(),void(this._mapDraw=null);this._mapDraw||(this._mapDraw=new d2(n));var o=this._mapDraw;o.draw(t,e,n,this,i),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,e,n)},F2.prototype._handleRegionClick=function(t){var e;Gf(t.target,function(t){return null!=(e=Gs(t).eventData)},!0),e&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:e.name})},F2.prototype.updateSelectStatus=function(t,e,n){var i=this;this._mapDraw.group.traverse(function(t){var e=Gs(t).eventData;if(e)return i._model.isSelected(e.name)?n.enterSelect(t):n.leaveSelect(t),!0})},F2.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},F2.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},F2.type="geo",F2);function F2(){var t=null!==V2&&V2.apply(this,arguments)||this;return t.type=F2.type,t.focusBlurEnabled=!0,t}function G2(e){function t(r,t){t.update="geo:updateSelectStatus",e.registerAction(t,function(t,e){var i={},o=[];return e.eachComponent({mainType:"geo",query:t},function(e){e[r](t.name),G(e.coordinateSystem.regions,function(t){i[t.name]=e.isSelected(t.name)||!1});var n=[];G(i,function(t,e){i[e]&&n.push(e)}),o.push({geoIndex:e.componentIndex,name:n})}),{selected:i,allSelected:o,name:t.name}})}e.registerCoordinateSystem("geo",O2),e.registerComponentModel(R2),e.registerComponentView(B2),t("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),t("select",{type:"geoSelect",event:"geoselected"}),t("unSelect",{type:"geoUnSelect",event:"geounselected"}),e.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(i,t){var o=i.componentType||"series";t.eachComponent({mainType:o,query:i},function(t){var e,n=t.coordinateSystem;"geo"===n.type&&(e=E2(n,i,t.get("scaleLimit")),t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom),"series"===o&&G(t.seriesGroup,function(t){t.setCenter(e.center),t.setZoom(e.zoom)}))})})}function H2(t,e){var n=t.isExpand?t.children:[],i=t.parentNode.children,o=t.hierNode.i?i[t.hierNode.i-1]:null;n.length?(function(t){var e=t.children,n=e.length,i=0,o=0;for(;0<=--n;){var r=e[n];r.hierNode.prelim+=i,r.hierNode.modifier+=i,o+=r.hierNode.change,i+=r.hierNode.shift+o}}(t),n=(n[0].hierNode.prelim+n[n.length-1].hierNode.prelim)/2,o?(t.hierNode.prelim=o.hierNode.prelim+e(t,o),t.hierNode.modifier=t.hierNode.prelim-n):t.hierNode.prelim=n):o&&(t.hierNode.prelim=o.hierNode.prelim+e(t,o)),t.parentNode.hierNode.defaultAncestor=function(t,e,n,i){if(e){for(var o=t,r=t,a=r.parentNode.children[0],s=e,l=o.hierNode.modifier,u=r.hierNode.modifier,h=a.hierNode.modifier,c=s.hierNode.modifier;s=X2(s),r=Z2(r),s&&r;){o=X2(o),a=Z2(a),o.hierNode.ancestor=t;var p=s.hierNode.prelim+c-r.hierNode.prelim-u+i(s,r);0<p&&(function(t,e,n){var i=n/(e.hierNode.i-t.hierNode.i);e.hierNode.change-=i,e.hierNode.shift+=n,e.hierNode.modifier+=n,e.hierNode.prelim+=n,t.hierNode.change+=i}(function(t,e,n){return t.hierNode.ancestor.parentNode===e.parentNode?t.hierNode.ancestor:n}(s,t,n),t,p),u+=p,l+=p),c+=s.hierNode.modifier,u+=r.hierNode.modifier,l+=o.hierNode.modifier,h+=a.hierNode.modifier}s&&!X2(o)&&(o.hierNode.thread=s,o.hierNode.modifier+=c-l),r&&!Z2(a)&&(a.hierNode.thread=r,a.hierNode.modifier+=u-h,n=t)}return n}(t,o,t.parentNode.hierNode.defaultAncestor||i[0],e)}function W2(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function U2(t){return arguments.length?t:j2}function Y2(t,e){return t-=Math.PI/2,{x:e*Math.cos(t),y:e*Math.sin(t)}}function X2(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function Z2(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function j2(t,e){return t.parentNode===e.parentNode?1:2}var q2,K2,J2=function(){this.parentPoint=[],this.childPoints=[]},Q2=(d(tT,K2=as),tT.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},tT.prototype.getDefaultShape=function(){return new J2},tT.prototype.buildPath=function(t,e){var n=e.childPoints,i=n.length,o=e.parentPoint,r=n[0],a=n[i-1];if(1===i)return t.moveTo(o[0],o[1]),void t.lineTo(r[0],r[1]);var s=e.orient,l="TB"===s||"BT"===s?0:1,s=1-l,e=go(e.forkPosition,1),u=[];u[l]=o[l],u[s]=o[s]+(a[s]-o[s])*e,t.moveTo(o[0],o[1]),t.lineTo(u[0],u[1]),t.moveTo(r[0],r[1]),u[l]=r[l],t.lineTo(u[0],u[1]),u[l]=a[l],t.lineTo(u[0],u[1]),t.lineTo(a[0],a[1]);for(var h=1;h<i-1;h++){var c=n[h];t.moveTo(c[0],c[1]),u[l]=c[l],t.lineTo(u[0],u[1])}},tT);function $2(){var t=null!==q2&&q2.apply(this,arguments)||this;return t.type=$2.type,t._mainGroup=new ro,t}function tT(t){return K2.call(this,t)||this}function eT(t,e){e=t.getItemLayout(e);return e&&!isNaN(e.x)&&!isNaN(e.y)}function nT(n,t,i,e,o){var r=!i,a=n.tree.getNodeByDataIndex(t),s=a.getModel(),l=a.getVisual("style").fill,u=!1===a.isExpand&&0!==a.children.length?l:"#fff",h=n.tree.root,c=a.parentNode!==h&&a.parentNode||a,p=n.getItemGraphicEl(c.dataIndex),d=c.getLayout(),f=p?{x:p.__oldX,y:p.__oldY,rawX:p.__radialOldRawX,rawY:p.__radialOldRawY}:d,g=a.getLayout();r?((i=new A_(n,t,null,{symbolInnerColor:u,useNameLabel:!0})).x=f.x,i.y=f.y):i.updateData(n,t,null,{symbolInnerColor:u,useNameLabel:!0}),i.__radialOldRawX=i.__radialRawX,i.__radialOldRawY=i.__radialRawY,i.__radialRawX=g.rawX,i.__radialRawY=g.rawY,e.add(i),n.setItemGraphicEl(t,i),i.__oldX=i.x,i.__oldY=i.y,Wl(i,{x:g.x,y:g.y},o);var y,m,l=i.getSymbolPath();"radial"===o.get("layout")&&(p=(c=h.children[0]).getLayout(),r=c.children.length,t=u=void 0,g.x===p.x&&!0===a.isExpand?(m=(c.children[0].getLayout().x+c.children[r-1].getLayout().x)/2,y=(c.children[0].getLayout().y+c.children[r-1].getLayout().y)/2,(u=Math.atan2(y-p.y,m-p.x))<0&&(u=2*Math.PI+u),(t=m<p.x)&&(u-=Math.PI)):((u=Math.atan2(g.y-p.y,g.x-p.x))<0&&(u=2*Math.PI+u),0===a.children.length||0!==a.children.length&&!1===a.isExpand?(t=g.x<p.x)&&(u-=Math.PI):(t=g.x>p.x)||(u-=Math.PI)),r=t?"left":"right",p=(m=(y=s.getModel("label")).get("rotate"))*(Math.PI/180),(t=l.getTextContent())&&(l.setTextConfig({position:y.get("position")||r,rotation:null==m?-u:p,origin:"center"}),t.setStyle("verticalAlign","middle")));s=s.get(["emphasis","focus"]),s="ancestor"===s?a.getAncestorsIndices():"descendant"===s?a.getDescendantIndices():null;s&&(Gs(i).focus=s),function(t,e,n,i,o,r,a,s){var l=e.getModel(),u=t.get("edgeShape"),h=t.get("layout"),c=t.getOrient(),p=t.get(["lineStyle","curveness"]),d=t.get("edgeForkPosition"),f=l.getModel("lineStyle").getLineStyle(),g=i.__edge;if("curve"===u)e.parentNode&&e.parentNode!==n&&Wl(g=g||(i.__edge=new py({shape:aT(h,c,p,o,o)})),{shape:aT(h,c,p,r,a)},t);else if("polyline"===u&&"orthogonal"===h&&e!==n&&e.children&&0!==e.children.length&&!0===e.isExpand){for(var y=e.children,m=[],v=0;v<y.length;v++){var x=y[v].getLayout();m.push([x.x,x.y])}Wl(g=g||(i.__edge=new Q2({shape:{parentPoint:[a.x,a.y],childPoints:[[a.x,a.y]],orient:c,forkPosition:d}})),{shape:{parentPoint:[a.x,a.y],childPoints:m}},t)}g&&(g.useStyle(z({strokeNoScale:!0,fill:null},f)),Nl(g,l,"lineStyle"),yl(g),s.add(g))}(o,a,h,i,f,d,g,e),i.__edge&&(i.onHoverStateChange=function(t){var e;"blur"!==t&&((e=a.parentNode&&n.getItemGraphicEl(a.parentNode.dataIndex))&&e.hoverState===Xs||dl(i.__edge,t))})}function iT(t,e,n,i,o){var r,a=oT(e.tree.root,t),s=a.source,l=a.sourceLayout,a=e.getItemGraphicEl(t.dataIndex);a&&(t=e.getItemGraphicEl(s.dataIndex).__edge,r=a.__edge||(!1===s.isExpand||1===s.children.length?t:void 0),e=i.get("edgeShape"),a=i.get("layout"),s=i.get("orient"),t=i.get(["lineStyle","curveness"]),r&&("curve"===e?Xl(r,{shape:aT(a,s,t,l,l),style:{opacity:0}},i,{cb:function(){n.remove(r)},removeOpt:o}):"polyline"===e&&"orthogonal"===i.get("layout")&&Xl(r,{shape:{parentPoint:[l.x,l.y],childPoints:[[l.x,l.y]]},style:{opacity:0}},i,{cb:function(){n.remove(r)},removeOpt:o})))}function oT(t,e){for(var n,i=e.parentNode!==t&&e.parentNode||e;null==(n=i.getLayout());)i=i.parentNode!==t&&i.parentNode||i;return{source:i,sourceLayout:n}}function rT(e,t,n,i,o){var r=e.tree.getNodeByDataIndex(t),a=oT(e.tree.root,r).sourceLayout,s={duration:o.get("animationDurationUpdate"),easing:o.get("animationEasingUpdate")};Xl(n,{x:a.x+1,y:a.y+1},o,{cb:function(){i.remove(n),e.setItemGraphicEl(t,null)},removeOpt:s}),n.fadeOut(null,{fadeLabel:!0,animation:s}),r.children.forEach(function(t){iT(t,e,i,o,s)}),iT(r,e,i,o,s)}function aT(t,e,n,i,o){var r,a,s,l;if("radial"!==t)return u=i.x,h=i.y,c=o.x,p=o.y,"LR"!==e&&"RL"!==e||(r=u+(c-u)*n,a=h,s=c+(u-c)*n,l=p),"TB"!==e&&"BT"!==e||(r=u,a=h+(p-h)*n,s=c,l=p+(h-p)*n),{x1:u,y1:h,x2:c,y2:p,cpx1:r,cpy1:a,cpx2:s,cpy2:l};var u=i.rawX,h=i.rawY,c=o.rawX,p=o.rawY,o=Y2(u,h),u=Y2(u,h+(p-h)*n),n=Y2(c,p+(h-p)*n),p=Y2(c,p);return{x1:o.x||0,y1:o.y||0,x2:p.x||0,y2:p.y||0,cpx1:u.x||0,cpy1:u.y||0,cpx2:n.x||0,cpy2:n.y||0}}var sT=(d($2,q2=$d),$2.prototype.init=function(t,e){this._controller=new qI(e.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},$2.prototype.render=function(i,t,n){var o=i.getData(),e=i.layoutInfo,r=this._mainGroup;"radial"===i.get("layout")?(r.x=e.x+e.width/2,r.y=e.y+e.height/2):(r.x=e.x,r.y=e.y),this._updateViewCoordSys(i),this._updateController(i,t,n);var a=this._data;o.diff(a).add(function(t){eT(o,t)&&nT(o,t,null,r,i)}).update(function(t,e){var n=a.getItemGraphicEl(e);eT(o,t)?nT(o,t,n,r,i):n&&rT(a,e,n,r,i)}).remove(function(t){var e=a.getItemGraphicEl(t);e&&rT(a,t,e,r,i)}).execute(),this._nodeScaleRatio=i.get("nodeScaleRatio"),this._updateNodeAndLinkScale(i),!0===i.get("expandAndCollapse")&&o.eachItemGraphicEl(function(t,e){t.off("click").on("click",function(){n.dispatchAction({type:"treeExpandAndCollapse",seriesId:i.id,dataIndex:e})})}),this._data=o},$2.prototype._updateViewCoordSys=function(t){var e=t.getData(),n=[];e.each(function(t){t=e.getItemLayout(t);!t||isNaN(t.x)||isNaN(t.y)||n.push([+t.x,+t.y])});var i=[],o=[];ya(n,i,o);var r=this._min,a=this._max;o[0]-i[0]==0&&(i[0]=r?r[0]:i[0]-1,o[0]=a?a[0]:o[0]+1),o[1]-i[1]==0&&(i[1]=r?r[1]:i[1]-1,o[1]=a?a[1]:o[1]+1);a=t.coordinateSystem=new I2;a.zoomLimit=t.get("scaleLimit"),a.setBoundingRect(i[0],i[1],o[0]-i[0],o[1]-i[1]),a.setCenter(t.get("center")),a.setZoom(t.get("zoom")),this.group.attr({x:a.x,y:a.y,scaleX:a.scaleX,scaleY:a.scaleY}),this._min=i,this._max=o},$2.prototype._updateController=function(o,t,r){var e=this,n=this._controller,i=this._controllerHost,a=this.group;n.setPointerChecker(function(t,e,n){var i=a.getBoundingRect();return i.applyTransform(a.transform),i.contain(e,n)&&!$I(t,r,o)}),n.enable(o.get("roam")),i.zoomLimit=o.get("scaleLimit"),i.zoom=o.coordinateSystem.getZoom(),n.off("pan").off("zoom").on("pan",function(t){KI(i,t.dx,t.dy),r.dispatchAction({seriesId:o.id,type:"treeRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){JI(i,t.scale,t.originX,t.originY),r.dispatchAction({seriesId:o.id,type:"treeRoam",zoom:t.scale,originX:t.originX,originY:t.originY}),e._updateNodeAndLinkScale(o),r.updateLabelLayout()})},$2.prototype._updateNodeAndLinkScale=function(t){var e=t.getData(),n=this._getNodeGlobalScale(t);e.eachItemGraphicEl(function(t,e){t.setSymbolScale(n)})},$2.prototype._getNodeGlobalScale=function(t){var e=t.coordinateSystem;if("view"!==e.type)return 1;var n=this._nodeScaleRatio,t=e.scaleX||1;return((e.getZoom()-1)*n+1)/t},$2.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},$2.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},$2.type="tree",$2),lT=Zo();function uT(t,e){var n;return lT(n=this).mainData===n?fT((n=N({},lT(this).datas))[this.dataType]=e,n,t):gT(e,this.dataType,lT(this).mainData,t),e}function hT(t,e){return t.struct&&t.struct.update(),e}function cT(n,i){return G(lT(i).datas,function(t,e){t!==i&&gT(t.cloneShallow(),e,i,n)}),i}function pT(t){var e=lT(this).mainData;return null==t||null==e?e:lT(e).datas[t]}function dT(){var e=lT(this).mainData;return null==e?[{data:e}]:H(Y(lT(e).datas),function(t){return{type:t,data:lT(e).datas[t]}})}function fT(n,t,i){lT(n).datas={},G(t,function(t,e){gT(t,e,n,i)})}function gT(t,e,n,i){lT(n).datas[e]=t,lT(t).mainData=n,t.dataType=e,i.struct&&(t[i.structAttr]=i.struct,i.struct[i.datasAttr[e]]=t),t.getLinkedData=pT,t.getLinkedDataAll=dT}var yT=function(n){var i=n.mainData,t=n.datas;t||(t={main:i},n.datasAttr={main:"data"}),n.datas=n.mainData=null,fT(i,t,n),G(t,function(e){G(i.TRANSFERABLE_METHODS,function(t){e.wrapMethod(t,Z(uT,n))})}),i.wrapMethod("cloneShallow",Z(cT,n)),G(i.CHANGABLE_METHODS,function(t){i.wrapMethod(t,Z(hT,n))}),ut(t[i.dataType]===i)},mT=(xT.prototype.isRemoved=function(){return this.dataIndex<0},xT.prototype.eachNode=function(t,e,n){"function"==typeof t&&(n=e,e=t,t=null);var i,o=(t=K(t=t||{})?{order:t}:t).order||"preorder",r=this[t.attr||"children"];"preorder"===o&&(i=e.call(n,this));for(var a=0;!i&&a<r.length;a++)r[a].eachNode(t,e,n);"postorder"===o&&e.call(n,this)},xT.prototype.updateDepthAndHeight=function(t){var e=0;this.depth=t;for(var n=0;n<this.children.length;n++){var i=this.children[n];i.updateDepthAndHeight(t+1),i.height>e&&(e=i.height)}this.height=e+1},xT.prototype.getNodeById=function(t){if(this.getId()===t)return this;for(var e=0,n=this.children,i=n.length;e<i;e++){var o=n[e].getNodeById(t);if(o)return o}},xT.prototype.contains=function(t){if(t===this)return!0;for(var e=0,n=this.children,i=n.length;e<i;e++){var o=n[e].contains(t);if(o)return o}},xT.prototype.getAncestors=function(t){for(var e=[],n=t?this:this.parentNode;n;)e.push(n),n=n.parentNode;return e.reverse(),e},xT.prototype.getAncestorsIndices=function(){for(var t=[],e=this;e;)t.push(e.dataIndex),e=e.parentNode;return t.reverse(),t},xT.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},xT.prototype.getValue=function(t){var e=this.hostTree.data;return e.getStore().get(e.getDimensionIndex(t||"value"),this.dataIndex)},xT.prototype.setLayout=function(t,e){0<=this.dataIndex&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},xT.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},xT.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostTree.data.getItemModel(this.dataIndex).getModel(t)},xT.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},xT.prototype.setVisual=function(t,e){0<=this.dataIndex&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},xT.prototype.getVisual=function(t){return this.hostTree.data.getItemVisual(this.dataIndex,t)},xT.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},xT.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},xT.prototype.getChildIndex=function(){if(this.parentNode){for(var t=this.parentNode.children,e=0;e<t.length;++e)if(t[e]===this)return e;return-1}return-1},xT.prototype.isAncestorOf=function(t){for(var e=t.parentNode;e;){if(e===this)return!0;e=e.parentNode}return!1},xT.prototype.isDescendantOf=function(t){return t!==this&&t.isAncestorOf(this)},xT);function vT(t){this.type="tree",this._nodes=[],this.hostModel=t}function xT(t,e){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=t||"",this.hostTree=e}var _T=(vT.prototype.eachNode=function(t,e,n){this.root.eachNode(t,e,n)},vT.prototype.getNodeByDataIndex=function(t){t=this.data.getRawIndex(t);return this._nodes[t]},vT.prototype.getNodeById=function(t){return this.root.getNodeById(t)},vT.prototype.update=function(){for(var t=this.data,e=this._nodes,n=0,i=e.length;n<i;n++)e[n].dataIndex=-1;for(n=0,i=t.count();n<i;n++)e[t.getRawIndex(n)].dataIndex=n},vT.prototype.clearLayouts=function(){this.data.clearItemLayouts()},vT.createTree=function(t,e,n){var l=new vT(e),u=[],h=1;(function t(e,n){var i=e.value;h=Math.max(h,j(i)?i.length:1),u.push(e);var o,r=new mT(Ho(e.name,""),l);n?(o=r,n=(i=n).children,o.parentNode!==i&&(n.push(o),o.parentNode=i)):l.root=r,l._nodes.push(r);var a=e.children;if(a)for(var s=0;s<a.length;s++)t(a[s],r)})(t),l.root.updateDepthAndHeight(0);t=d_(u,{coordDimensions:["value"],dimensionsCount:h}).dimensions,e=new c_(t,e);return e.initData(u),n&&n(e),yT({mainData:e,struct:l,structAttr:"tree"}),l.update(),l},vT);function bT(t,e,n){if(t&&0<=V(e,t.type)){e=n.getData().tree.root,n=t.targetNode;if((n="string"==typeof n?e.getNodeById(n):n)&&e.contains(n))return{node:n};t=t.targetNodeId;return null!=t&&(n=e.getNodeById(t))?{node:n}:void 0}}function wT(t){for(var e=[];t;)(t=t.parentNode)&&e.push(t);return e.reverse()}function ST(t,e){return 0<=V(wT(t),e)}function MT(t,e){for(var n=[];t;){var i=t.dataIndex;n.push({name:t.name,dataIndex:i,value:e.getRawValue(i)}),t=t.parentNode}return n.reverse(),n}var IT,TT=(d(CT,IT=Gd),CT.prototype.getInitialData=function(t){var e={name:t.name,children:t.data},n=t.leaves||{},i=new wu(n,this,this.ecModel),o=_T.createTree(e,this,function(t){t.wrapMethod("getItemModel",function(t,e){e=o.getNodeByDataIndex(e);return e&&e.children.length&&e.isExpand||(t.parentModel=i),t})});var r=0;o.eachNode("preorder",function(t){t.depth>r&&(r=t.depth)});var a=t.expandAndCollapse&&0<=t.initialTreeDepth?t.initialTreeDepth:r;return o.root.eachNode("preorder",function(t){var e=t.hostTree.data.getRawDataItem(t.dataIndex);t.isExpand=e&&null!=e.collapsed?!e.collapsed:t.depth<=a}),o.data},CT.prototype.getOrient=function(){var t=this.get("orient");return"horizontal"===t?t="LR":"vertical"===t&&(t="TB"),t},CT.prototype.setZoom=function(t){this.option.zoom=t},CT.prototype.setCenter=function(t){this.option.center=t},CT.prototype.formatTooltip=function(t,e,n){for(var i=this.getData().tree,o=i.root.children[0],r=i.getNodeByDataIndex(t),t=r.getValue(),a=r.name;r&&r!==o;)a=r.parentNode.name+"."+a,r=r.parentNode;return md("nameValue",{name:a,value:t,noValue:isNaN(t)||null==t})},CT.prototype.getDataParams=function(t){var e=IT.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treeAncestors=MT(t,this),e},CT.type="series.tree",CT.layoutMode="box",CT.defaultOption={zlevel:0,z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},CT);function CT(){var t=null!==IT&&IT.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}function DT(t,e){for(var n,i=[t];n=i.pop();)if(e(n),n.isExpand){var o=n.children;if(o.length)for(var r=o.length-1;0<=r;r--)i.push(o[r])}}function AT(t,e){t.eachSeriesByType("tree",function(t){!function(t,e){var n=function(t,e){return Sh(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}(t,e);t.layoutInfo=n;var i=t.get("layout"),o=0,r=0,a=null;a="radial"===i?(o=2*Math.PI,r=Math.min(n.height,n.width)/2,U2(function(t,e){return(t.parentNode===e.parentNode?1:2)/t.depth})):(o=n.width,r=n.height,U2());e=t.getData().tree.root,n=e.children[0];{var s,l,u,h,c,p,d,f,g;n&&(function(t){t.hierNode={defaultAncestor:null,ancestor:t,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var e,n,i=[t];e=i.pop();)if(n=e.children,e.isExpand&&n.length)for(var o=n.length-1;0<=o;o--){var r=n[o];r.hierNode={defaultAncestor:null,ancestor:r,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},i.push(r)}}(e),function(t,e,n){for(var i,o=[t],r=[];i=o.pop();)if(r.push(i),i.isExpand){var a=i.children;if(a.length)for(var s=0;s<a.length;s++)o.push(a[s])}for(;i=r.pop();)e(i,n)}(n,H2,a),e.hierNode.modifier=-n.hierNode.prelim,DT(n,W2),DT(u=l=s=n,function(t){var e=t.getLayout().x;e<s.getLayout().x&&(s=t),e>l.getLayout().x&&(l=t),t.depth>u.depth&&(u=t)}),a=s===l?1:a(s,l)/2,h=a-s.getLayout().x,f=d=p=c=0,"radial"===i?(c=o/(l.getLayout().x+a+h),p=r/(u.depth-1||1),DT(n,function(t){d=(t.getLayout().x+h)*c,f=(t.depth-1)*p;var e=Y2(d,f);t.setLayout({x:e.x,y:e.y,rawX:d,rawY:f},!0)})):"RL"===(g=t.getOrient())||"LR"===g?(p=r/(l.getLayout().x+a+h),c=o/(u.depth-1||1),DT(n,function(t){f=(t.getLayout().x+h)*p,d="LR"===g?(t.depth-1)*c:o-(t.depth-1)*c,t.setLayout({x:d,y:f},!0)})):"TB"!==g&&"BT"!==g||(c=o/(l.getLayout().x+a+h),p=r/(u.depth-1||1),DT(n,function(t){d=(t.getLayout().x+h)*c,f="TB"===g?(t.depth-1)*p:r-(t.depth-1)*p,t.setLayout({x:d,y:f},!0)})))}}(t,e)})}function kT(t){t.eachSeriesByType("tree",function(t){var n=t.getData();n.tree.eachNode(function(t){var e=t.getModel().getModel("itemStyle").getItemStyle();N(n.ensureUniqueItemVisual(t.dataIndex,"style"),e)})})}var LT,PT=function(){},OT=["treemapZoomToNode","treemapRender","treemapMove"];function RT(t){for(var e=0;e<OT.length;e++)t.registerAction({type:OT[e],update:"updateView"},PT);t.registerAction({type:"treemapRootToNode",update:"updateView"},function(o,t){t.eachComponent({mainType:"series",subType:"treemap",query:o},function(t,e){var n,i=bT(o,["treemapZoomToNode","treemapRootToNode"],t);i&&((n=t.getViewRoot())&&(o.direction=ST(n,i.node)?"rollUp":"drillDown"),t.resetViewRoot(i.node))})})}function NT(i){var t=i.getData().tree,o={};t.eachNode(function(t){for(var e=t;e&&1<e.depth;)e=e.parentNode;var n=hc(i.ecModel,e.name||e.dataIndex+"",o);t.setVisual("decal",n)})}function zT(){var t=null!==LT&&LT.apply(this,arguments)||this;return t.type=zT.type,t.preventUsingHoverLayer=!0,t}var ET=(d(zT,LT=Gd),zT.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};!function e(t){var n=0;G(t.children,function(t){e(t);t=t.value;j(t)&&(t=t[0]),n+=t});var i=t.value;j(i)&&(i=i[0]),null!=i&&!isNaN(i)||(i=n),i<0&&(i=0),j(t.value)?t.value[0]=i:t.value=i}(n);var i=t.levels||[],o=this.designatedVisualItemStyle={},r=new wu({itemStyle:o},this,e),a=H((i=t.levels=function(t,e){var i,o,n=No(e.get("color")),r=No(e.get(["aria","decal","decals"]));if(n){G(t=t||[],function(t){var e=new wu(t),n=e.get("color"),t=e.get("decal");(e.get(["itemStyle","color"])||n&&"none"!==n)&&(i=!0),(e.get(["itemStyle","decal"])||t&&"none"!==t)&&(o=!0)});e=t[0]||(t[0]={});return i||(e.color=n.slice()),!o&&r&&(e.decal=r.slice()),t}}(i,e))||[],function(t){return new wu(t,r,e)},this),s=_T.createTree(n,this,function(t){t.wrapMethod("getItemModel",function(t,e){e=s.getNodeByDataIndex(e),e=e?a[e.depth]:null;return t.parentModel=e||r,t})});return s.data},zT.prototype.optionUpdated=function(){this.resetViewRoot()},zT.prototype.formatTooltip=function(t,e,n){var i=this.getData(),o=this.getRawValue(t);return md("nameValue",{name:i.getName(t),value:o})},zT.prototype.getDataParams=function(t){var e=LT.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treeAncestors=MT(t,this),e.treePathInfo=e.treeAncestors,e},zT.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},N(this.layoutInfo,t)},zT.prototype.mapIdToIndex=function(t){var e=this._idIndexMap;e||(e=this._idIndexMap=yt(),this._idIndexMapCount=0);var n=e.get(t);return null==n&&e.set(t,n=this._idIndexMapCount++),n},zT.prototype.getViewRoot=function(){return this._viewRoot},zT.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},zT.prototype.enableAriaDecal=function(){NT(this)},zT.type="series.treemap",zT.layoutMode="box",zT.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.1024,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],ellipsis:!0,verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},zT);function VT(t){this.group=new ro,t.add(this.group)}var BT=(VT.prototype.render=function(t,e,n,i){var o,r,a=t.getModel("breadcrumb"),s=this.group;s.removeAll(),a.get("show")&&n&&(r=(o=a.getModel("itemStyle")).getModel("textStyle"),a={pos:{left:a.get("left"),right:a.get("right"),top:a.get("top"),bottom:a.get("bottom")},box:{width:e.getWidth(),height:e.getHeight()},emptyItemWidth:a.get("emptyItemWidth"),totalWidth:0,renderList:[]},this._prepare(n,a,r),this._renderContent(t,a,o,r,i),Mh(s,a.pos,a.box))},VT.prototype._prepare=function(t,e,n){for(var i=t;i;i=i.parentNode){var o=Ho(i.getModel().get("name"),""),r=n.getTextRect(o),r=Math.max(r.width+16,e.emptyItemWidth);e.totalWidth+=r+8,e.renderList.push({node:i,text:o,width:r})}},VT.prototype._renderContent=function(t,e,n,i,o){for(var r,a,s,l,u,h,c,p,d,f,g,y,m,v=0,x=e.emptyItemWidth,_=t.get(["breadcrumb","height"]),b=(h=e.pos,c=e.box,d=c.width,f=c.height,g=go(h.left,d),y=go(h.top,f),m=go(h.right,d),c=go(h.bottom,f),(isNaN(g)||isNaN(parseFloat(h.left)))&&(g=0),(isNaN(m)||isNaN(parseFloat(h.right)))&&(m=d),(isNaN(y)||isNaN(parseFloat(h.top)))&&(y=0),(isNaN(c)||isNaN(parseFloat(h.bottom)))&&(c=f),p=lh(p||0),{width:Math.max(m-g-p[1]-p[3],0),height:Math.max(c-y-p[0]-p[2],0)}),w=e.totalWidth,S=e.renderList,M=S.length-1;0<=M;M--){var I=S[M],T=I.node,C=I.width,D=I.text;b.width<w&&(w-=C-x,C=x,D=null);I=new $g({shape:{points:(r=v,a=0,s=C,l=_,u=M===S.length-1,I=void 0,I=[[u?r:r-5,a],[r+s,a],[r+s,a+l],[u?r:r-5,a+l]],0===M||I.splice(2,0,[r+s+5,a+l/2]),u||I.push([r,a+l/2]),I)},style:z(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new Fs({style:{text:D,fill:i.getTextColor(),font:i.getFont()}}),textConfig:{position:"inside"},z2:1e5,onclick:Z(o,T)});I.disableLabelAnimation=!0,this.group.add(I),D=t,T=T,Gs(I).eventData={componentType:"series",componentSubType:"treemap",componentIndex:D.componentIndex,seriesIndex:D.seriesIndex,seriesName:D.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:T&&T.dataIndex,name:T&&T.name},treePathInfo:T&&MT(T,D)},v+=C+8}},VT.prototype.remove=function(){this.group.removeAll()},VT),FT=(GT.prototype.add=function(t,e,n,i,o){return!this._elExistsMap[t.id]&&(this._elExistsMap[t.id]=!0,this._storage.push({el:t,target:e,duration:n,delay:i,easing:o}),!0)},GT.prototype.finished=function(t){return this._finishedCallback=t,this},GT.prototype.start=function(){for(var t=this,e=this._storage.length,n=function(){--e<=0&&(t._storage.length=0,t._elExistsMap={},t._finishedCallback&&t._finishedCallback())},i=0,o=this._storage.length;i<o;i++){var r=this._storage[i];r.el.animateTo(r.target,{duration:r.duration,delay:r.delay,easing:r.easing,setToFinal:!0,done:n,aborted:n})}return this},GT);function GT(){this._storage=[],this._elExistsMap={}}var HT,WT=ro,UT=Ts,YT="label",XT="upperLabel",ZT=100,jT=20,qT=30,KT=dr([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),JT=function(t){t=KT(t);return t.stroke=t.fill=t.lineWidth=null,t},QT=Zo();function $T(){var t=null!==HT&&HT.apply(this,arguments)||this;return t.type=$T.type,t._state="ready",t._storage=tC(),t}function tC(){return{nodeGroup:[],background:[],content:[]}}var eC=(d($T,HT=$d),$T.prototype.render=function(t,e,n,i){var o,r,a,s,l;V(e.findComponents({mainType:"series",subType:"treemap",query:i}),t)<0||(this.seriesModel=t,this.api=n,this.ecModel=e,o=bT(i,["treemapZoomToNode","treemapRootToNode"],t),r=i&&i.type,l=t.layoutInfo,a=!this._oldTree,s=this._storage,e="treemapRootToNode"===r&&o&&s?{rootNodeGroup:s.nodeGroup[o.node.getRawIndex()],direction:i.direction}:null,s=this._giveContainerGroup(l),i=t.get("animation"),l=this._doRender(s,t,e),!i||a||r&&"treemapZoomToNode"!==r&&"treemapRootToNode"!==r?l.renderFinally():this._doAnimation(s,l,t,e),this._resetController(n),this._renderBreadcrumb(t,n,o))},$T.prototype._giveContainerGroup=function(t){var e=this._containerGroup;return e||(e=this._containerGroup=new WT,this._initEvents(e),this.group.add(e)),e.x=t.x,e.y=t.y,e},$T.prototype._doRender=function(t,o,r){var e=o.getData().tree,n=this._oldTree,a=tC(),s=tC(),l=this._storage,u=[];function h(t,e,n,i){return function(u,a,s,l,h,e,c,t,n,i){if(c){var p=c.getLayout(),o=u.getData(),d=c.getModel();if(o.setItemGraphicEl(c.dataIndex,null),p&&p.isInView){var f=p.width,g=p.height,y=p.borderWidth,m=p.invisible,v=c.getRawIndex(),x=t&&t.getRawIndex(),r=c.viewChildren,_=p.upperHeight,b=r&&r.length,w=d.getModel("itemStyle"),S=d.getModel(["emphasis","itemStyle"]),M=d.getModel(["blur","itemStyle"]),I=d.getModel(["select","itemStyle"]),T=w.get("borderRadius")||0,C=L("nodeGroup",WT);if(C){if(n.add(C),C.x=p.x||0,C.y=p.y||0,C.markRedraw(),QT(C).nodeWidth=f,QT(C).nodeHeight=g,p.isAboveViewRoot)return C;t=L("background",UT,i,jT);t&&function(t,e,n){var i=Gs(e);{var o,r,a,s,l;i.dataIndex=c.dataIndex,i.seriesIndex=u.seriesIndex,e.setShape({x:0,y:0,width:f,height:g,r:T}),m?D(e):(e.invisible=!1,o=c.getVisual("style"),r=o.stroke,(a=JT(w)).fill=r,(s=KT(S)).fill=S.get("borderColor"),(l=KT(M)).fill=M.get("borderColor"),(i=KT(I)).fill=I.get("borderColor"),n?(n=f-2*y,A(e,r,o.opacity,{x:y,y:0,width:n,height:_})):e.removeTextContent(),e.setStyle(a),e.ensureState("emphasis").style=s,e.ensureState("blur").style=l,e.ensureState("select").style=i,yl(e))}t.add(e)}(C,t,b&&p.upperLabelHeight);r=d.get(["emphasis","focus"]),n=d.get(["emphasis","blurScope"]),r="ancestor"===r?c.getAncestorsIndices():"descendant"===r?c.getDescendantIndices():r;return b?(El(C)&&zl(C,!1),t&&(zl(t,!0),o.setItemGraphicEl(c.dataIndex,t),Pl(t,r,n))):((i=L("content",UT,i,qT))&&function(t,e){var n=Gs(e);n.dataIndex=c.dataIndex,n.seriesIndex=u.seriesIndex;var i=Math.max(f-2*y,0),o=Math.max(g-2*y,0);{var r,a,s;e.culling=!0,e.setShape({x:y,y:y,width:i,height:o,r:T}),m?D(e):(e.invisible=!1,r=c.getVisual("style"),a=r.fill,(s=JT(w)).fill=a,s.decal=r.decal,n=KT(S),i=KT(M),o=KT(I),A(e,a,r.opacity,null),e.setStyle(s),e.ensureState("emphasis").style=n,e.ensureState("blur").style=i,e.ensureState("select").style=o,yl(e))}t.add(e)}(C,i),t.disableMorphing=!0,t&&El(t)&&zl(t,!1),zl(C,!0),o.setItemGraphicEl(c.dataIndex,C),Pl(C,r,n)),C}}}function D(t){t.invisible||e.push(t)}function A(n,t,e,i){var o=d.getModel(i?XT:YT),r=Ho(d.get("name"),null),o=o.getShallow("show");$l(n,tu(d,i?XT:YT),{defaultText:o?r:null,inheritColor:t,defaultOpacity:e,labelFetcher:u,labelDataIndex:c.dataIndex});var a,s,l=n.getTextContent();l&&(a=l.style,s=lt(a.padding||0),i&&(n.setTextConfig({layoutRect:i}),l.disableLabelLayout=!0),l.beforeUpdate=function(){var t=Math.max((i||n.shape).width-s[1]-s[3],0),e=Math.max((i||n.shape).height-s[0]-s[2],0);a.width===t&&a.height===e||l.setStyle({width:t,height:e})},a.truncateMinChar=2,a.lineOverflow="truncate",k(a,i,p),k((e=l.getState("emphasis"))?e.style:null,i,p))}function k(t,e,n){var i=t?t.text:null;!e&&n.isLeafRoot&&null!=i&&(n=u.get("drillDownIcon",!0),t.text=n?n+" "+i:i)}function L(t,e,n,i){var o=null!=x&&s[t][x],r=h[t];return o?(s[t][x]=null,function(t,e){t=t[v]={};e instanceof WT?(t.oldX=e.x,t.oldY=e.y):t.oldShape=N({},e.shape)}(r,o)):m||((o=new e)instanceof Fr&&(o.z2=n*ZT+i),function(t,e){var n=t[v]={},i=c.parentNode,o=e instanceof ro;!i||l&&"drillDown"!==l.direction||(e=t=0,i=h.background[i.getRawIndex()],!l&&i&&i.oldShape&&(t=i.oldShape.width,e=i.oldShape.height),o?(n.oldX=0,n.oldY=e):n.oldShape={x:t,y:e,width:0,height:0});n.fadein=!o}(r,o)),a[t][v]=o}}(o,s,l,r,a,u,t,e,n,i)}!function i(o,r,a,s,l){function t(t){return t.getId()}function n(t,e){var n=null!=t?o[t]:null,t=null!=e?r[e]:null,e=h(n,t,a,l);e&&i(n&&n.viewChildren||[],t&&t.viewChildren||[],e,s,l+1)}s?(r=o,G(o,function(t,e){t.isRemoved()||n(e,e)})):new Vx(r,o,t,t).add(n).update(n).remove(Z(n,null)).execute()}(e.root?[e.root]:[],n&&n.root?[n.root]:[],t,e===n||!n,0);var i,c=(i=tC(),(n=l)&&G(n,function(t,e){var n=i[e];G(t,function(t){t&&(n.push(t),QT(t).willDelete=!0)})}),i);return this._oldTree=e,this._storage=s,{lastsForAnimation:a,willDeleteEls:c,renderFinally:function(){G(c,function(t){G(t,function(t){t.parent&&t.parent.remove(t)})}),G(u,function(t){t.invisible=!0,t.dirty()})}}},$T.prototype._doAnimation=function(t,o,e,a){var n=e.get("animationDurationUpdate"),e=e.get("animationEasing"),s=(q(n)?0:n)||0,l=(q(e)?null:e)||"cubicOut",u=new FT;G(o.willDeleteEls,function(t,r){G(t,function(t,e){var n,i,o;t.invisible||(i=t.parent,n=QT(i),(o=a&&"drillDown"===a.direction?i===a.rootNodeGroup?{shape:{x:0,y:0,width:n.nodeWidth,height:n.nodeHeight},style:{opacity:0}}:{style:{opacity:0}}:(o=i=0,n.willDelete||(i=n.nodeWidth/2,o=n.nodeHeight/2),"nodeGroup"===r?{x:i,y:o,style:{opacity:0}}:{shape:{x:i,y:o,width:0,height:0},style:{opacity:0}}))&&u.add(t,o,s,0,l))})}),G(this._storage,function(t,i){G(t,function(t,e){var n=o.lastsForAnimation[i][e],e={};n&&(t instanceof ro?null!=n.oldX&&(e.x=t.x,e.y=t.y,t.x=n.oldX,t.y=n.oldY):(n.oldShape&&(e.shape=N({},t.shape),t.setShape(n.oldShape)),n.fadein?(t.setStyle("opacity",0),e.style={opacity:1}):1!==t.style.opacity&&(e.style={opacity:1})),u.add(t,e,s,0,l))})},this),this._state="animating",u.finished(X(function(){this._state="ready",o.renderFinally()},this)).start()},$T.prototype._resetController=function(t){var e=this._controller;e||((e=this._controller=new qI(t.getZr())).enable(this.seriesModel.get("roam")),e.on("pan",X(this._onPan,this)),e.on("zoom",X(this._onZoom,this)));var i=new ki(0,0,t.getWidth(),t.getHeight());e.setPointerChecker(function(t,e,n){return i.contain(e,n)})},$T.prototype._clearController=function(){var t=this._controller;t&&t.dispose()},$T.prototype._onPan=function(t){var e;"animating"!==this._state&&(3<Math.abs(t.dx)||3<Math.abs(t.dy))&&(!(e=this.seriesModel.getData().tree.root)||(e=e.getLayout())&&this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:e.x+t.dx,y:e.y+t.dy,width:e.width,height:e.height}}))},$T.prototype._onZoom=function(t){var e,n,i,o=t.originX,r=t.originY;"animating"!==this._state&&(!(i=this.seriesModel.getData().tree.root)||(n=i.getLayout())&&(e=new ki(n.x,n.y,n.width,n.height),ai(i=ni(),i,[-(o-=(n=this.seriesModel.layoutInfo).x),-(r-=n.y)]),li(i,i,[t.scale,t.scale]),ai(i,i,[o,r]),e.applyTransform(i),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:e.x,y:e.y,width:e.width,height:e.height}})))},$T.prototype._initEvents=function(t){var i=this;t.on("click",function(t){var e,n;"ready"===i._state&&(!(n=i.seriesModel.get("nodeClick",!0))||(e=i.findTarget(t.offsetX,t.offsetY))&&((t=e.node).getLayout().isLeafRoot?i._rootToNode(e):"zoomToNode"===n?i._zoomToNode(e):"link"===n&&(t=(n=t.hostTree.data.getItemModel(t.dataIndex)).get("link",!0),n=n.get("target",!0)||"blank",t&&mh(t,n))))},this)},$T.prototype._renderBreadcrumb=function(e,t,n){var i=this;n||(n=(n=null!=e.get("leafDepth",!0)?{node:e.getViewRoot()}:this.findTarget(t.getWidth()/2,t.getHeight()/2))||{node:e.getData().tree.root}),(this._breadcrumb||(this._breadcrumb=new BT(this.group))).render(e,t,n.node,function(t){"animating"!==i._state&&(ST(e.getViewRoot(),t)?i._rootToNode({node:t}):i._zoomToNode({node:t}))})},$T.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=tC(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},$T.prototype.dispose=function(){this._clearController()},$T.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},$T.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},$T.prototype.findTarget=function(i,o){var r;return this.seriesModel.getViewRoot().eachNode({attr:"viewChildren",order:"preorder"},function(t){var e=this._storage.background[t.getRawIndex()];if(e){var n=e.transformCoordToLocal(i,o),e=e.shape;if(!(e.x<=n[0]&&n[0]<=e.x+e.width&&e.y<=n[1]&&n[1]<=e.y+e.height))return!1;r={node:t,offsetX:n[0],offsetY:n[1]}}},this),r},$T.type="treemap",$T),nC=G,iC=$,oC=-1,rC=(aC.prototype.mapValueToVisual=function(t){var e=this._normalizeData(t);return this._normalizedToVisual(e,t)},aC.prototype.getNormalizer=function(){return X(this._normalizeData,this)},aC.listVisualTypes=function(){return Y(aC.visualHandlers)},aC.isValidType=function(t){return aC.visualHandlers.hasOwnProperty(t)},aC.eachVisual=function(t,e,n){$(t)?G(t,e,n):e.call(n,t)},aC.mapVisual=function(t,n,i){var o,r=j(t)?[]:$(t)?{}:(o=!0,null);return aC.eachVisual(t,function(t,e){t=n.call(i,t,e);o?r=t:r[e]=t}),r},aC.retrieveVisuals=function(n){var i,o={};return n&&nC(aC.visualHandlers,function(t,e){n.hasOwnProperty(e)&&(o[e]=n[e],i=!0)}),i?o:null},aC.prepareVisualTypes=function(t){if(j(t))t=t.slice();else{if(!iC(t))return[];var n=[];nC(t,function(t,e){n.push(e)}),t=n}return t.sort(function(t,e){return"color"===e&&"color"!==t&&0===t.indexOf("color")?1:-1}),t},aC.dependsOn=function(t,e){return"color"===e?!(!t||0!==t.indexOf(e)):t===e},aC.findPieceIndex=function(n,t,e){for(var i,o=1/0,r=0,a=t.length;r<a;r++){var s=t[r].value;if(null!=s){if(s===n||"string"==typeof s&&s===n+"")return r;e&&h(s,r)}}for(r=0,a=t.length;r<a;r++){var l=t[r],u=l.interval,l=l.close;if(u){if(u[0]===-1/0){if(mC(l[1],n,u[1]))return r}else if(u[1]===1/0){if(mC(l[0],u[0],n))return r}else if(mC(l[0],u[0],n)&&mC(l[1],n,u[1]))return r;e&&h(u[0],r),e&&h(u[1],r)}}if(e)return n===1/0?t.length-1:n===-1/0?0:i;function h(t,e){t=Math.abs(t-n);t<o&&(o=t,i=e)}},aC.visualHandlers={color:{applyVisual:hC("color"),getColorMapper:function(){var o=this.option;return X("category"===o.mappingMethod?function(t,e){return e||(t=this._normalizeData(t)),cC.call(this,t)}:function(t,e,n){var i=!!n;return n=un(t=!e?this._normalizeData(t):t,o.parsedVisual,n),i?n:pn(n,"rgba")},this)},_normalizedToVisual:{linear:function(t){return pn(un(t,this.option.parsedVisual),"rgba")},category:cC,piecewise:function(t,e){e=fC.call(this,e);return e=null==e?pn(un(t,this.option.parsedVisual),"rgba"):e},fixed:pC}},colorHue:lC(function(t,e){return hn(t,e)}),colorSaturation:lC(function(t,e){return hn(t,null,e)}),colorLightness:lC(function(t,e){return hn(t,null,null,e)}),colorAlpha:lC(cn),decal:{applyVisual:hC("decal"),_normalizedToVisual:{linear:null,category:cC,piecewise:null,fixed:null}},opacity:{applyVisual:hC("opacity"),_normalizedToVisual:dC([0,1])},liftZ:{applyVisual:hC("liftZ"),_normalizedToVisual:{linear:pC,category:pC,piecewise:pC,fixed:pC}},symbol:{applyVisual:function(t,e,n){n("symbol",this.mapValueToVisual(t))},_normalizedToVisual:{linear:uC,category:cC,piecewise:function(t,e){e=fC.call(this,e);return e=null==e?uC.call(this,t):e},fixed:pC}},symbolSize:{applyVisual:hC("symbolSize"),_normalizedToVisual:dC([0,1])}},aC);function aC(t){var e=t.mappingMethod,n=t.type,t=this.option=P(t);this.type=n,this.mappingMethod=e,this._normalizeData=yC[e];var i,n=aC.visualHandlers[n];this.applyVisual=n.applyVisual,this.getColorMapper=n.getColorMapper,this._normalizedToVisual=n._normalizedToVisual[e],"piecewise"===e?(sC(t),n=(i=t).pieceList,i.hasSpecialVisual=!1,G(n,function(t,e){t.originIndex=e,null!=t.visual&&(i.hasSpecialVisual=!0)})):"category"===e?t.categories?function(t){var e=t.categories,n=t.categoryMap={},i=t.visual;{var o;nC(e,function(t,e){n[t]=e}),j(i)||(o=[],$(i)?nC(i,function(t,e){e=n[e];o[null!=e?e:oC]=t}):o[oC]=i,i=gC(t,o))}for(var r=e.length-1;0<=r;r--)null==i[r]&&(delete n[e[r]],e.pop())}(t):sC(t,!0):(ut("linear"!==e||t.dataExtent),sC(t))}function sC(t,e){var n=t.visual,i=[];$(n)?nC(n,function(t){i.push(t)}):null!=n&&i.push(n);e||1!==i.length||{color:1,symbol:1}.hasOwnProperty(t.type)||(i[1]=i[0]),gC(t,i)}function lC(i){return{applyVisual:function(t,e,n){t=this.mapValueToVisual(t);n("color",i(e("color"),t))},_normalizedToVisual:dC([0,1])}}function uC(t){var e=this.option.visual;return e[Math.round(fo(t,[0,1],[0,e.length-1],!0))]||{}}function hC(i){return function(t,e,n){n(i,this.mapValueToVisual(t))}}function cC(t){var e=this.option.visual;return e[this.option.loop&&t!==oC?t%e.length:t]}function pC(){return this.option.visual[0]}function dC(n){return{linear:function(t){return fo(t,n,this.option.visual,!0)},category:cC,piecewise:function(t,e){e=fC.call(this,e);return e=null==e?fo(t,n,this.option.visual,!0):e},fixed:pC}}function fC(t){var e=this.option,n=e.pieceList;if(e.hasSpecialVisual){n=n[rC.findPieceIndex(t,n)];if(n&&n.visual)return n.visual[this.type]}}function gC(t,e){return t.visual=e,"color"===t.type&&(t.parsedVisual=H(e,function(t){return rn(t)})),e}var yC={linear:function(t){return fo(t,this.option.dataExtent,[0,1],!0)},piecewise:function(t){var e=this.option.pieceList,t=rC.findPieceIndex(t,e,!0);if(null!=t)return fo(t,[0,e.length-1],[0,1],!0)},category:function(t){t=this.option.categories?this.option.categoryMap[t]:t;return null==t?oC:t},fixed:_t};function mC(t,e,n){return t?e<=n:e<n}var vC=rC,xC="itemStyle",_C=Zo(),bC={seriesType:"treemap",reset:function(t){var e=t.getData().tree.root;e.isRemoved()||function n(t,e,i,o){var r=t.getModel(),a=t.getLayout(),s=t.hostTree.data;{var l,u,h,c,p;a&&!a.invisible&&a.isInView&&(u=r.getModel(xC),h=wC(u,e,o),c=s.ensureUniqueItemVisual(t.dataIndex,"style"),e=u.get("borderColor"),null!=(s=u.get("borderColorSaturation"))&&(l=SC(h),e=MC(s,l)),c.stroke=e,(e=t.viewChildren)&&e.length?(p=TC(0,r,a,0,h,e),G(e,function(t,e){(t.depth>=i.length||t===i[t.depth])&&(e=DC(r,h,t,e,p,o),n(t,e,i,o))})):(l=SC(h),c.fill=l))}}(e,{},t.getViewRoot().getAncestors(),t)}};function wC(n,i,t){var o=N({},i),r=t.designatedVisualItemStyle;return G(["color","colorAlpha","colorSaturation"],function(t){r[t]=i[t];var e=n.get(t);(r[t]=null)!=e&&(o[t]=e)}),o}function SC(t){var e=IC(t,"color");if(e){var n=IC(t,"colorAlpha"),t=IC(t,"colorSaturation");return t&&(e=hn(e,null,null,t)),e=n?cn(e,n):e}}function MC(t,e){return null!=e?hn(e,null,null,t):null}function IC(t,e){e=t[e];if(null!=e&&"none"!==e)return e}function TC(t,e,n,i,o,r){if(r&&r.length){var a=CC(e,"color")||null!=o.color&&"none"!==o.color&&(CC(e,"colorAlpha")||CC(e,"colorSaturation"));if(a){r=e.get("visualMin"),o=e.get("visualMax"),n=n.dataExtent.slice();null!=r&&r<n[0]&&(n[0]=r),null!=o&&o>n[1]&&(n[1]=o);e=e.get("colorMappingBy"),a={type:a.name,dataExtent:n,visual:a.range};"color"!==a.type||"index"!==e&&"id"!==e?a.mappingMethod="linear":(a.mappingMethod="category",a.loop=!0);a=new vC(a);return _C(a).drColorMappingBy=e,a}}}function CC(t,e){t=t.get(e);return j(t)&&t.length?{name:e,range:t}:null}function DC(t,e,n,i,o,r){var a,s=N({},e);return o&&(t="index"===(e="color"===(a=o.type)&&_C(o).drColorMappingBy)?i:"id"===e?r.mapIdToIndex(n.getId()):n.getValue(t.get("visualDimension")),s[a]=o.mapValueToVisual(t)),s}var AC=Math.max,kC=Math.min,LC=ot,PC=G,OC=["itemStyle","borderWidth"],RC=["itemStyle","gapWidth"],NC=["upperLabel","show"],zC=["upperLabel","height"],EC={seriesType:"treemap",reset:function(t,e,n,i){var o,r=n.getWidth(),a=n.getHeight(),s=t.option,l=Sh(t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),u=s.size||[],h=go(LC(l.width,u[0]),r),c=go(LC(l.height,u[1]),a),n=i&&i.type,u=bT(i,["treemapZoomToNode","treemapRootToNode"],t),i="treemapRender"===n||"treemapMove"===n?i.rootRect:null,p=t.getViewRoot(),d=wT(p);"treemapMove"!==n&&(c="treemapZoomToNode"===n?function(t,e,n,i,o){var r,a=(e||{}).node,s=[i,o];if(!a||a===n)return s;var n=i*o,l=n*t.option.zoomToNodeRatio;for(;r=a.parentNode;){for(var u=0,h=r.children,c=0,p=h.length;c<p;c++)u+=h[c].getValue();var d=a.getValue();if(0===d)return s;l*=u/d;var f=r.getModel(),d=f.get(OC),f=Math.max(d,GC(f));l+=4*d*d+(3*d+f)*Math.pow(l,.5),_o<l&&(l=_o),a=r}l<n&&(l=n);n=Math.pow(l/n,.5);return[i*n,o*n]}(t,u,p,h,c):i?[i.width,i.height]:[h,c],f=s.sort,f={squareRatio:s.squareRatio,sort:f=f&&"asc"!==f&&"desc"!==f?"desc":f,leafDepth:s.leafDepth},p.hostTree.clearLayouts(),o={x:0,y:0,width:c[0],height:c[1],area:c[0]*c[1]},p.setLayout(o),function t(e,n,i,o){var r,a;if(!e.isRemoved()){var s=e.getLayout();r=s.width,a=s.height;var l=e.getModel(),u=l.get(OC),h=l.get(RC)/2,c=GC(l),p=Math.max(u,c),d=u-h,s=p-h;e.setLayout({borderWidth:u,upperHeight:p,upperLabelHeight:c},!0),r=AC(r-2*d,0),a=AC(a-d-s,0);var c=r*a,f=VC(e,l,c,n,i,o);if(f.length){for(var g={x:d,y:s,width:r,height:a},y=kC(r,a),m=1/0,v=[],x=v.area=0,_=f.length;x<_;){var b=f[x];v.push(b),v.area+=b.getLayout().area;b=BC(v,y,n.squareRatio);m=b<=m?(x++,b):(v.area-=v.pop().getLayout().area,FC(v,y,g,h,!1),y=kC(g.width,g.height),1/(v.length=v.area=0))}for(v.length&&FC(v,y,g,h,!0),i||null!=(l=l.get("childrenVisibleMin"))&&c<l&&(i=!0),x=0,_=f.length;x<_;x++)t(f[x],n,i,o+1)}}}(p,f,!1,0),o=p.getLayout(),PC(d,function(t,e){e=(d[e+1]||p).getValue();t.setLayout(N({dataExtent:[e,e],borderWidth:0,upperHeight:0},o))}));var f=t.getData().tree.root;f.setLayout(function(t,e,n){if(e)return{x:e.x,y:e.y};var i={x:0,y:0};if(!n)return i;e=n.node,n=e.getLayout();if(!n)return i;var o=[n.width/2,n.height/2],r=e;for(;r;){var a=r.getLayout();o[0]+=a.x,o[1]+=a.y,r=r.parentNode}return{x:t.width/2-o[0],y:t.height/2-o[1]}}(l,i,u),!0),t.setLayoutInfo(l),function e(t,n,i,o,r){var a=t.getLayout(),s=i[r],l=s&&s===t;{var u;s&&!l||r===i.length&&t!==o||(t.setLayout({isInView:!0,invisible:!l&&!n.intersect(a),isAboveViewRoot:l},!0),u=new ki(n.x-a.x,n.y-a.y,n.width,n.height),PC(t.viewChildren||[],function(t){e(t,u,i,o,r+1)}))}}(f,new ki(-l.x,-l.y,r,a),d,p,0)}};function VC(t,e,n,i,o,r){var a=t.children||[],s=i.sort;"asc"!==s&&"desc"!==s&&(s=null);var l,r=null!=i.leafDepth&&i.leafDepth<=r;if(o&&!r)return t.viewChildren=[];a=U(a,function(t){return!t.isRemoved()}),o=a,(l=s)&&o.sort(function(t,e){var n="asc"===l?t.getValue()-e.getValue():e.getValue()-t.getValue();return 0==n?"asc"===l?t.dataIndex-e.dataIndex:e.dataIndex-t.dataIndex:n});var u=function(t,e,n){for(var i=0,o=0,r=e.length;o<r;o++)i+=e[o].getValue();var a,s=t.get("visualDimension");return e&&e.length?"value"===s&&n?(a=[e[e.length-1].getValue(),e[0].getValue()],"asc"===n&&a.reverse()):(a=[1/0,-1/0],PC(e,function(t){t=t.getValue(s);t<a[0]&&(a[0]=t),t>a[1]&&(a[1]=t)})):a=[NaN,NaN],{sum:i,dataExtent:a}}(e,a,s);if(0===u.sum)return t.viewChildren=[];if(u.sum=function(t,e,n,i,o){if(!i)return n;for(var r=t.get("visibleMin"),a=o.length,s=a,l=a-1;0<=l;l--){var u=o["asc"===i?a-l-1:l].getValue();u/n*e<r&&(s=l,n-=u)}return"asc"===i?o.splice(0,a-s):o.splice(s,a-s),n}(e,n,u.sum,s,a),0===u.sum)return t.viewChildren=[];for(var h=0,c=a.length;h<c;h++){var p=a[h].getValue()/u.sum*n;a[h].setLayout({area:p})}return r&&(a.length&&t.setLayout({isLeafRoot:!0},!0),a.length=0),t.viewChildren=a,t.setLayout({dataExtent:u.dataExtent},!0),a}function BC(t,e,n){for(var i,o=0,r=1/0,a=0,s=t.length;a<s;a++)(i=t[a].getLayout().area)&&(i<r&&(r=i),o<i&&(o=i));var l=t.area*t.area,n=e*e*n;return l?AC(n*o/l,l/(n*r)):1/0}function FC(t,e,n,i,o){var r=e===n.width?0:1,a=1-r,s=["x","y"],l=["width","height"],u=n[s[r]],h=e?t.area/e:0;(o||h>n[l[a]])&&(h=n[l[a]]);for(var c=0,p=t.length;c<p;c++){var d=t[c],f={},g=h?d.getLayout().area/h:0,y=f[l[a]]=AC(h-2*i,0),m=n[s[r]]+n[l[r]]-u,m=c===p-1||m<g?m:g,g=f[l[r]]=AC(m-2*i,0);f[s[a]]=n[s[a]]+kC(i,y/2),f[s[r]]=u+kC(i,g/2),u+=m,d.setLayout(f,!0)}n[s[a]]+=h,n[l[a]]-=h}function GC(t){return t.get(NC)?t.get(zC):0}function HC(t){var r=t.findComponents({mainType:"legend"});r&&r.length&&t.eachSeriesByType("graph",function(t){var e=t.getCategoriesData(),i=t.getGraph().data,o=e.mapArray(e.getName);i.filterSelf(function(t){var e=i.getItemModel(t).getShallow("category");if(null!=e){"number"==typeof e&&(e=o[e]);for(var n=0;n<r.length;n++)if(!r[n].isSelected(e))return!1}return!0})})}function WC(t){var h={};t.eachSeriesByType("graph",function(s){var l=s.getCategoriesData(),r=s.getData(),u={};l.each(function(t){var e=l.getName(t);u["ec-"+e]=t;var n=l.getItemModel(t),i=n.getModel("itemStyle").getItemStyle();i.fill||(i.fill=s.getColorFromPalette(e,h)),l.setItemVisual(t,"style",i);for(var o=["symbol","symbolSize","symbolKeepAspect"],r=0;r<o.length;r++){var a=n.getShallow(o[r],!0);null!=a&&l.setItemVisual(t,o[r],a)}}),l.count()&&r.each(function(t){var e=r.getItemModel(t).getShallow("category");if(null!=e){"string"==typeof e&&(e=u["ec-"+e]);var n=l.getItemVisual(e,"style");N(r.ensureUniqueItemVisual(t,"style"),n);for(var i=["symbol","symbolSize","symbolKeepAspect"],o=0;o<i.length;o++)r.setItemVisual(t,i[o],l.getItemVisual(e,i[o]))}})})}function UC(t){return t=!(t instanceof Array)?[t,t]:t}function YC(t){t.eachSeriesByType("graph",function(t){var s=t.getGraph(),l=t.getEdgeData(),e=UC(t.get("edgeSymbol")),n=UC(t.get("edgeSymbolSize"));l.setVisual("fromSymbol",e&&e[0]),l.setVisual("toSymbol",e&&e[1]),l.setVisual("fromSymbolSize",n&&n[0]),l.setVisual("toSymbolSize",n&&n[1]),l.setVisual("style",t.getModel("lineStyle").getLineStyle()),l.each(function(t){var e=l.getItemModel(t),n=s.getEdgeByIndex(t),i=UC(e.getShallow("symbol",!0)),o=UC(e.getShallow("symbolSize",!0)),e=e.getModel("lineStyle").getLineStyle(),r=l.ensureUniqueItemVisual(t,"style");switch(N(r,e),r.stroke){case"source":var a=n.node1.getVisual("style");r.stroke=a&&a.fill;break;case"target":a=n.node2.getVisual("style"),r.stroke=a&&a.fill}i[0]&&n.setVisual("fromSymbol",i[0]),i[1]&&n.setVisual("toSymbol",i[1]),o[0]&&n.setVisual("fromSymbolSize",o[0]),o[1]&&n.setVisual("toSymbolSize",o[1])})})}function XC(t,e){var n=JC(t),i=20,o=[];if("number"==typeof n)i=n;else if(j(n))return t.__curvenessList=n,0;for(var r=(i=i<e?e:i)%2?i+2:i+3,o=[],a=0;a<r;a++)o.push((a%2?a+1:a)/10*(a%2?-1:1));t.__curvenessList=o}function ZC(t){return[(t=t.split(KC))[0],t[2],t[1]].join(KC)}function jC(t,e){return t=QC(t.node1,t.node2,e),e.__edgeMap[t]}function qC(t,e){return $C(QC(t.node1,t.node2,e),e)+$C(QC(t.node2,t.node1,e),e)}var KC="--\x3e",JC=function(t){return t.get("autoCurveness")||null},QC=function(t,e,n){t=[t.id,t.dataIndex].join("."),e=[e.id,e.dataIndex].join(".");return[n.uid,t,e].join(KC)},$C=function(t,e){e=e.__edgeMap;return e[t]?e[t].length:0};function tD(t,e,n,i){var o=JC(e),r=j(o);if(!o)return null;var a=jC(t,e);if(!a)return null;for(var s=-1,l=0;l<a.length;l++)if(a[l]===n){s=l;break}var u=qC(t,e);XC(e,u),t.lineStyle=t.lineStyle||{};var h=QC(t.node1,t.node2,e),t=e.__curvenessList,u=r||u%2?0:1;if(a.isForward)return t[u+s];h=ZC(h),h=$C(h,e),e=t[s+h+u];return i?!r||o&&0===o[0]?(h+u)%2?e:-e:((h%2?0:1)+u)%2?e:-e:t[s+h+u]}function eD(t){var e=t.coordinateSystem;e&&"view"!==e.type||((e=t.getGraph()).eachNode(function(t){var e=t.getModel();t.setLayout([+e.get("x"),+e.get("y")])}),nD(e,t))}function nD(t,r){t.eachEdge(function(t,e){var n=at(t.getModel().get(["lineStyle","curveness"]),-tD(t,r,e,!0),0),i=It(t.node1.getLayout()),o=It(t.node2.getLayout()),e=[i,o];+n&&e.push([(i[0]+o[0])/2-(i[1]-o[1])*n,(i[1]+o[1])/2-(o[0]-i[0])*n]),t.setLayout(e)})}function iD(t,e){t.eachSeriesByType("graph",function(t){var e=t.get("layout"),n=t.coordinateSystem;if(n&&"view"!==n.type){var i=t.getData(),o=[];G(n.dimensions,function(t){o=o.concat(i.mapDimensionsAll(t))});for(var r=0;r<i.count();r++){for(var a=[],s=!1,l=0;l<o.length;l++){var u=i.get(o[l],r);isNaN(u)||(s=!0),a.push(u)}s?i.setItemLayout(r,n.dataToPoint(a)):i.setItemLayout(r,[NaN,NaN])}nD(i.graph,t)}else e&&"none"!==e||eD(t)})}function oD(t){var e=t.coordinateSystem;if("view"!==e.type)return 1;var n=t.option.nodeScaleRatio,t=e.scaleX;return((e.getZoom()-1)*n+1)/t}function rD(t){t=t.getVisual("symbolSize");return+(t=t instanceof Array?(t[0]+t[1])/2:t)}var aD=Math.PI,sD=[];function lD(s,t){var e,n,l,u,i,o=s.coordinateSystem;o&&"view"!==o.type||(i=o.getBoundingRect(),n=(e=s.getData()).graph,l=i.width/2+i.x,u=i.height/2+i.y,o=Math.min(i.width,i.height)/2,i=e.count(),e.setLayout({cx:l,cy:u}),i&&(uD[t](s,n,e,o,l,u,i),n.eachEdge(function(t,e){var n,i=at(t.getModel().get(["lineStyle","curveness"]),tD(t,s,e),0),o=It(t.node1.getLayout()),r=It(t.node2.getLayout()),a=(o[0]+r[0])/2,e=(o[1]+r[1])/2;+i&&(n=[l*(i*=3)+a*(1-i),u*i+e*(1-i)]),t.setLayout([o,r,n])})))}var uD={value:function(t,e,n,i,o,r,a){var s=0,l=n.getSum("value"),u=2*Math.PI/(l||a);e.eachNode(function(t){var e=t.getValue("value"),e=u*(l?e:1)/2;s+=e,t.setLayout([i*Math.cos(s)+o,i*Math.sin(s)+r]),s+=e})},symbolSize:function(t,e,n,i,o,r,a){var s=0;sD.length=a;var l=oD(t);e.eachNode(function(t){var e=rD(t);(e=isNaN(e)?2:e)<0&&(e=0),e*=l;e=Math.asin(e/2/i);isNaN(e)&&(e=aD/2),sD[t.dataIndex]=e,s+=2*e});var u=(2*aD-s)/a/2,h=0;e.eachNode(function(t){var e=u+sD[t.dataIndex];h+=e,t.setLayout([i*Math.cos(h)+o,i*Math.sin(h)+r]),h+=e})}};function hD(t){t.eachSeriesByType("graph",function(t){"circular"===t.get("layout")&&lD(t,"symbolSize")})}var cD=Ct;function pD(t,e,n){for(var g=t,y=e,e=n.rect,i=e.width,o=e.height,m=[e.x+i/2,e.y+o/2],v=null==n.gravity?.1:n.gravity,r=0;r<g.length;r++){var a=g[r];a.p||(a.p=St(i*(Math.random()-.5)+m[0],o*(Math.random()-.5)+m[1])),a.pp=It(a.p),a.edges=null}var x,_,s=null==n.friction?.6:n.friction,b=s;return{warmUp:function(){b=.8*s},setFixed:function(t){g[t].fixed=!0},setUnfixed:function(t){g[t].fixed=!1},beforeStep:function(t){x=t},afterStep:function(t){_=t},step:function(t){x&&x(g,y);for(var e,n,i=[],o=g.length,r=0;r<y.length;r++){var a,s,l=y[r];l.ignoreForceLayout||(h=l.n1,Dt(i,(a=l.n2).p,h.p),s=At(i)-l.d,l=a.w/(h.w+a.w),isNaN(l)&&(l=0),Lt(i,i),h.fixed||cD(h.p,h.p,i,l*s*b),a.fixed||cD(a.p,a.p,i,-(1-l)*s*b))}for(r=0;r<o;r++){var u=g[r];u.fixed||(Dt(i,m,u.p),cD(u.p,u.p,i,v*b))}for(r=0;r<o;r++)for(var h=g[r],c=r+1;c<o;c++){Dt(i,(a=g[c]).p,h.p),0===(s=At(i))&&(e=i,n=Math.random()-.5,p=Math.random()-.5,e[0]=n,e[1]=p,s=1);var p=(h.rep+a.rep)/s/s;h.fixed||cD(h.pp,h.pp,i,p),a.fixed||cD(a.pp,a.pp,i,-p)}for(var d=[],r=0;r<o;r++)(u=g[r]).fixed||(Dt(d,u.p,u.pp),cD(u.p,u.p,d,b),Mt(u.pp,u.p));var f=(b*=.992)<.01;_&&_(g,y,f),t&&t(f)}}}function dD(t){t.eachSeriesByType("graph",function(o){var h,c,p,i,r,t,e,a,s,l,n,u,d=o.coordinateSystem;d&&"view"!==d.type||("force"===o.get("layout")?(h=o.preservedPoints||{},c=o.getGraph(),p=c.data,n=c.edgeData,e=(u=o.getModel("force")).get("initLayout"),o.preservedPoints?p.each(function(t){var e=p.getId(t);p.setItemLayout(t,h[e]||[NaN,NaN])}):e&&"none"!==e?"circular"===e&&lD(o,"value"):eD(o),i=p.getDataExtent("value"),r=n.getDataExtent("value"),t=u.get("repulsion"),e=u.get("edgeLength"),a=j(t)?t:[t,t],s=[(s=j(e)?e:[e,e])[1],s[0]],l=p.mapArray("value",function(t,e){var n=p.getItemLayout(e),t=fo(t,i,a);return{w:t=isNaN(t)?(a[0]+a[1])/2:t,rep:t,fixed:p.getItemModel(e).get("fixed"),p:!n||isNaN(n[0])||isNaN(n[1])?null:n}}),n=n.mapArray("value",function(t,e){var n=c.getEdgeByIndex(e),i=fo(t,r,s);isNaN(i)&&(i=(s[0]+s[1])/2);t=n.getModel(),e=at(n.getModel().get(["lineStyle","curveness"]),-tD(n,o,e,!0),0);return{n1:l[n.node1.dataIndex],n2:l[n.node2.dataIndex],d:i,curveness:e,ignoreForceLayout:t.get("ignoreForceLayout")}}),d=d.getBoundingRect(),(u=pD(l,n,{rect:d,gravity:u.get("gravity"),friction:u.get("friction")})).beforeStep(function(t,e){for(var n=0,i=t.length;n<i;n++)t[n].fixed&&Mt(t[n].p,c.getNodeByIndex(n).getLayout())}),u.afterStep(function(t,e,n){for(var i=0,o=t.length;i<o;i++)t[i].fixed||c.getNodeByIndex(i).setLayout(t[i].p),h[p.getId(i)]=t[i].p;for(i=0,o=e.length;i<o;i++){var r=e[i],a=c.getEdgeByIndex(i),s=r.n1.p,l=r.n2.p,u=a.getLayout();(u=u?u.slice():[])[0]=u[0]||[],u[1]=u[1]||[],Mt(u[0],s),Mt(u[1],l),+r.curveness&&(u[2]=[(s[0]+l[0])/2-(s[1]-l[1])*r.curveness,(s[1]+l[1])/2-(l[0]-s[0])*r.curveness]),a.setLayout(u)}}),o.forceLayout=u,o.preservedPoints=h,u.step()):o.forceLayout=null)})}function fD(t,u){var h=[];return t.eachSeriesByType("graph",function(t){var e,n,i,o,r,a,s,l=t.get("coordinateSystem");l&&"view"!==l||(n=[],r=[],ya((e=t.getData()).mapArray(function(t){t=e.getItemModel(t);return[+t.get("x"),+t.get("y")]}),n,r),r[0]-n[0]==0&&(r[0]+=1,--n[0]),r[1]-n[1]==0&&(r[1]+=1,--n[1]),o=(r[0]-n[0])/(r[1]-n[1]),a=u,s=o,i=Sh(N(t.getBoxLayoutParams(),{aspect:s}),{width:a.getWidth(),height:a.getHeight()}),isNaN(o)&&(n=[i.x,i.y],r=[i.x+i.width,i.y+i.height]),l=r[0]-n[0],s=r[1]-n[1],a=i.width,o=i.height,(r=t.coordinateSystem=new I2).zoomLimit=t.get("scaleLimit"),r.setBoundingRect(n[0],n[1],l,s),r.setViewRect(i.x,i.y,a,o),r.setCenter(t.get("center")),r.setZoom(t.get("zoom")),h.push(r))}),h}var gD,yD=Kf.prototype,mD=py.prototype,vD=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1};function xD(t){return isNaN(+t.cpx1)||isNaN(+t.cpy1)}d(function(){return null!==gD&&gD.apply(this,arguments)||this},gD=vD);var _D,bD=(d(SD,_D=as),SD.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},SD.prototype.getDefaultShape=function(){return new vD},SD.prototype.buildPath=function(t,e){(xD(e)?yD:mD).buildPath.call(this,t,e)},SD.prototype.pointAt=function(t){return(xD(this.shape)?yD:mD).pointAt.call(this,t)},SD.prototype.tangentAt=function(t){var e=this.shape,t=xD(e)?[e.x2-e.x1,e.y2-e.y1]:mD.tangentAt.call(this,t);return Lt(t,t)},SD),wD=["fromSymbol","toSymbol"];function SD(t){t=_D.call(this,t)||this;return t.type="ec-line",t}function MD(t){return"_"+t+"Type"}function ID(t,e,n){var i=e.getItemVisual(n,t);if(i&&"none"!==i){var o=e.getItemVisual(n,t+"Size"),r=e.getItemVisual(n,t+"Rotate"),a=e.getItemVisual(n,t+"Offset"),n=e.getItemVisual(n,t+"KeepAspect"),o=sm(o),a=lm(a||0,o),n=am(i,-o[0]/2+a[0],-o[1]/2+a[1],o[0],o[1],null,n);return n.__specifiedRotation=null==r||isNaN(r)?void 0:+r*Math.PI/180||0,n.name=t,n}}function TD(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;e=e[2];e?(t.cpx1=e[0],t.cpy1=e[1]):(t.cpx1=NaN,t.cpy1=NaN)}var CD,DD=(d(kD,CD=ro),kD.prototype._createLine=function(n,i,t){var e,o=n.hostModel,r=n.getItemLayout(i),r=(e=r,TD((r=new bD({name:"line",subPixelOptimize:!0})).shape,e),r);r.shape.percent=0,Ul(r,{shape:{percent:1}},o,i),this.add(r),G(wD,function(t){var e=ID(t,n,i);this.add(e),this[MD(t)]=n.getItemVisual(i,t)},this),this._updateCommonStl(n,i,t)},kD.prototype.updateData=function(i,o,t){var e=i.hostModel,n=this.childOfName("line"),r=i.getItemLayout(o),a={shape:{}};TD(a.shape,r),Wl(n,a,e,o),G(wD,function(t){var e=i.getItemVisual(o,t),n=MD(t);this[n]!==e&&(this.remove(this.childOfName(t)),t=ID(t,i,o),this.add(t)),this[n]=e},this),this._updateCommonStl(i,o,t)},kD.prototype.getLinePath=function(){return this.childAt(0)},kD.prototype._updateCommonStl=function(n,t,e){var i=n.hostModel,r=this.childOfName("line"),o=e&&e.emphasisLineStyle,a=e&&e.blurLineStyle,s=e&&e.selectLineStyle,l=e&&e.labelStatesModels;e&&!n.hasItemOption||(o=(e=n.getItemModel(t)).getModel(["emphasis","lineStyle"]).getLineStyle(),a=e.getModel(["blur","lineStyle"]).getLineStyle(),s=e.getModel(["select","lineStyle"]).getLineStyle(),l=tu(e));var u=n.getItemVisual(t,"style"),h=u.stroke;r.useStyle(u),r.style.fill=null,r.style.strokeNoScale=!0,r.ensureState("emphasis").style=o,r.ensureState("blur").style=a,r.ensureState("select").style=s,G(wD,function(t){var e=this.childOfName(t);if(e){e.setColor(h),e.style.opacity=u.opacity;for(var n=0;n<js.length;n++){var i=js[n],o=r.getState(i);o&&(o=o.style||{},i=(i=e.ensureState(i)).style||(i.style={}),null!=o.stroke&&(i[e.__isEmptyBrush?"stroke":"fill"]=o.stroke),null!=o.opacity&&(i.opacity=o.opacity))}e.markRedraw()}},this);s=i.getRawValue(t);$l(this,l,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(t,e){return i.getFormattedLabel(t,e,n.dataType)}},inheritColor:h||"#000",defaultOpacity:u.opacity,defaultText:(null==s?n.getName(t):isFinite(s)?yo(s):s)+""});s=this.getTextContent();s&&(l=l.normal,s.__align=s.style.align,s.__verticalAlign=s.style.verticalAlign,s.__position=l.get("position")||"middle",j(l=l.get("distance"))||(l=[l,l]),s.__labelDistance=l),this.setTextConfig({position:null,local:!0,inside:!1}),Ll(this)},kD.prototype.highlight=function(){xl(this)},kD.prototype.downplay=function(){_l(this)},kD.prototype.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},kD.prototype.setLinePoints=function(t){var e=this.childOfName("line");TD(e.shape,t),e.dirty()},kD.prototype.beforeUpdate=function(){var t=this.childOfName("fromSymbol"),e=this.childOfName("toSymbol"),n=this.getTextContent();if(t||e||n&&!n.ignore){for(var i=1,o=this.parent;o;)o.scaleX&&(i/=o.scaleX),o=o.parent;var r=this.childOfName("line");if(this.__dirty||r.__dirty){var a=r.shape.percent,s=r.pointAt(0),l=r.pointAt(a),u=Dt([],l,s);if(Lt(u,u),t&&(t.setPosition(s),v(t,0),t.scaleX=t.scaleY=i*a,t.markRedraw()),e&&(e.setPosition(l),v(e,1),e.scaleX=e.scaleY=i*a,e.markRedraw()),n&&!n.ignore){n.x=n.y=0;var h=void(n.originX=n.originY=0),c=void 0,e=n.__labelDistance,p=e[0]*i,d=e[1]*i,e=a/2,f=r.tangentAt(e),a=[f[1],-f[0]],g=r.pointAt(e);0<a[1]&&(a[0]=-a[0],a[1]=-a[1]);var y=f[0]<0?-1:1;"start"!==n.__position&&"end"!==n.__position&&(a=-Math.atan2(f[1],f[0]),l[0]<s[0]&&(a=Math.PI+a),n.rotation=a);var m=void 0;switch(n.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":m=-d,c="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":m=d,c="top";break;default:m=0,c="middle"}switch(n.__position){case"end":n.x=u[0]*p+l[0],n.y=u[1]*d+l[1],h=.8<u[0]?"left":u[0]<-.8?"right":"center",c=.8<u[1]?"top":u[1]<-.8?"bottom":"middle";break;case"start":n.x=-u[0]*p+s[0],n.y=-u[1]*d+s[1],h=.8<u[0]?"right":u[0]<-.8?"left":"center",c=.8<u[1]?"bottom":u[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":n.x=p*y+s[0],n.y=s[1]+m,h=f[0]<0?"right":"left",n.originX=-p*y,n.originY=-m;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":n.x=g[0],n.y=g[1]+m,h="center",n.originY=-m;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":n.x=-p*y+l[0],n.y=l[1]+m,h=0<=f[0]?"right":"left",n.originX=p*y,n.originY=-m}n.scaleX=n.scaleY=i,n.setStyle({verticalAlign:n.__verticalAlign||c,align:n.__align||h})}}}function v(t,e){var n,i=t.__specifiedRotation;null==i?(n=r.tangentAt(e),t.attr("rotation",(1===e?-1:1)*Math.PI/2-Math.atan2(n[1],n[0]))):t.attr("rotation",i)}},kD);function AD(t){this.group=new ro,this._LineCtor=t||DD}function kD(t,e,n){var i=CD.call(this)||this;return i._createLine(t,e,n),i}function LD(t){t=t.hostModel;return{lineStyle:t.getModel("lineStyle").getLineStyle(),emphasisLineStyle:t.getModel(["emphasis","lineStyle"]).getLineStyle(),blurLineStyle:t.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:t.getModel(["select","lineStyle"]).getLineStyle(),labelStatesModels:tu(t)}}function PD(t){return isNaN(t[0])||isNaN(t[1])}function OD(t){return!PD(t[0])&&!PD(t[1])}var RD=(AD.prototype.isPersistent=function(){return!0},AD.prototype.updateData=function(n){var i=this,e=this.group,o=this._lineData;this._lineData=n,o||e.removeAll();var r=LD(n);n.diff(o).add(function(t){i._doAdd(n,t,r)}).update(function(t,e){i._doUpdate(o,n,e,t,r)}).remove(function(t){e.remove(o.getItemGraphicEl(t))}).execute()},AD.prototype.updateLayout=function(){var n=this._lineData;n&&n.eachItemGraphicEl(function(t,e){t.updateLayout(n,e)},this)},AD.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=LD(t),this._lineData=null,this.group.removeAll()},AD.prototype.incrementalUpdate=function(t,e){function n(t){var e;t.isGroup||(e=t).animators&&0<e.animators.length||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}for(var i,o=t.start;o<t.end;o++)OD(e.getItemLayout(o))&&((i=new this._LineCtor(e,o,this._seriesScope)).traverse(n),this.group.add(i),e.setItemGraphicEl(o,i))},AD.prototype.remove=function(){this.group.removeAll()},AD.prototype._doAdd=function(t,e,n){OD(t.getItemLayout(e))&&(n=new this._LineCtor(t,e,n),t.setItemGraphicEl(e,n),this.group.add(n))},AD.prototype._doUpdate=function(t,e,n,i,o){n=t.getItemGraphicEl(n);OD(e.getItemLayout(i))?(n?n.updateData(e,i,o):n=new this._LineCtor(e,i,o),e.setItemGraphicEl(i,n),this.group.add(n)):this.group.remove(n)},AD),ND=[],zD=[],ED=[],VD=ia,BD=Rt,FD=Math.abs;function GD(t,e,n){for(var i,o=t[0],r=t[1],a=t[2],s=1/0,l=n*n,u=.1,h=.1;h<=.9;h+=.1){ND[0]=VD(o[0],r[0],a[0],h),ND[1]=VD(o[1],r[1],a[1],h);var c=FD(BD(ND,e)-l);c<s&&(s=c,i=h)}for(var p=0;p<32;p++){var d=i+u;if(zD[0]=VD(o[0],r[0],a[0],i),zD[1]=VD(o[1],r[1],a[1],i),ED[0]=VD(o[0],r[0],a[0],d),ED[1]=VD(o[1],r[1],a[1],d),c=BD(zD,e)-l,FD(c)<.01)break;d=BD(ED,e)-l;u/=2,c<0?0<=d?i+=u:i-=u:0<=d?i-=u:i+=u}return i}function HD(t,l){var u=[],h=aa,c=[[],[],[]],p=[[],[]],d=[];l/=2,t.eachEdge(function(t,e){var n=t.getLayout(),i=t.getVisual("fromSymbol"),o=t.getVisual("toSymbol");n.__original||(n.__original=[It(n[0]),It(n[1])],n[2]&&n.__original.push(It(n[2])));var r,a,s=n.__original;null!=n[2]?(Mt(c[0],s[0]),Mt(c[1],s[2]),Mt(c[2],s[1]),i&&"none"!==i&&(r=rD(t.node1),a=GD(c,s[0],r*l),h(c[0][0],c[1][0],c[2][0],a,u),c[0][0]=u[3],c[1][0]=u[4],h(c[0][1],c[1][1],c[2][1],a,u),c[0][1]=u[3],c[1][1]=u[4]),o&&"none"!==o&&(r=rD(t.node2),a=GD(c,s[1],r*l),h(c[0][0],c[1][0],c[2][0],a,u),c[1][0]=u[1],c[2][0]=u[2],h(c[0][1],c[1][1],c[2][1],a,u),c[1][1]=u[1],c[2][1]=u[2]),Mt(n[0],c[0]),Mt(n[1],c[2]),Mt(n[2],c[1])):(Mt(p[0],s[0]),Mt(p[1],s[1]),Dt(d,p[1],p[0]),Lt(d,d),i&&"none"!==i&&(r=rD(t.node1),Ct(p[0],p[0],d,r*l)),o&&"none"!==o&&(r=rD(t.node2),Ct(p[1],p[1],d,-r*l)),Mt(n[0],p[0]),Mt(n[1],p[1]))})}function WD(t){return"view"===t.type}var UD,YD=(d(XD,UD=$d),XD.prototype.init=function(t,e){var n=new O_,i=new RD,o=this.group;this._controller=new qI(e.getZr()),this._controllerHost={target:o},o.add(n.group),o.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},XD.prototype.render=function(t,e,n){var r=this,i=t.coordinateSystem;this._model=t;var o=this._symbolDraw,a=this._lineDraw,s=this.group;WD(i)&&(i={x:i.x,y:i.y,scaleX:i.scaleX,scaleY:i.scaleY},this._firstRender?s.attr(i):Wl(s,i,t)),HD(t.getGraph(),oD(t));var l=t.getData();o.updateData(l);o=t.getEdgeData();a.updateData(o),this._updateNodeAndLinkScale(),this._updateController(t,e,n),clearTimeout(this._layoutTimeout);var u=t.forceLayout,h=t.get(["force","layoutAnimation"]);u&&this._startForceLayoutIteration(u,h),l.graph.eachNode(function(t){var e=t.dataIndex,n=t.getGraphicEl(),i=t.getModel();n.off("drag").off("dragend");var o=i.get("draggable");o&&n.on("drag",function(){u&&(u.warmUp(),r._layouting||r._startForceLayoutIteration(u,h),u.setFixed(e),l.setItemLayout(e,[n.x,n.y]))}).on("dragend",function(){u&&u.setUnfixed(e)}),n.setDraggable(o&&!!u),"adjacency"===i.get(["emphasis","focus"])&&(Gs(n).focus=t.getAdjacentDataIndices())}),l.graph.eachEdge(function(t){var e=t.getGraphicEl();"adjacency"===t.getModel().get(["emphasis","focus"])&&(Gs(e).focus={edge:[t.dataIndex],node:[t.node1.dataIndex,t.node2.dataIndex]})});var c="circular"===t.get("layout")&&t.get(["circular","rotateLabel"]),p=l.getLayout("cx"),d=l.getLayout("cy");l.eachItemGraphicEl(function(t,e){var n=l.getItemModel(e).get(["label","rotate"])||0,i=t.getSymbolPath();c?(t=l.getItemLayout(e),(e=Math.atan2(t[1]-d,t[0]-p))<0&&(e=2*Math.PI+e),(t=t[0]<p)&&(e-=Math.PI),i.setTextConfig({rotation:-e,position:e=t?"left":"right",origin:"center"}),N((t=i.ensureState("emphasis")).textConfig||(t.textConfig={}),{position:e})):i.setTextConfig({rotation:n*=Math.PI/180})}),this._firstRender=!1},XD.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},XD.prototype._startForceLayoutIteration=function(t,n){var i=this;!function e(){t.step(function(t){i.updateLayout(i._model),(i._layouting=!t)&&(n?i._layoutTimeout=setTimeout(e,16):e())})}()},XD.prototype._updateController=function(o,t,r){var e=this,n=this._controller,i=this._controllerHost,a=this.group;n.setPointerChecker(function(t,e,n){var i=a.getBoundingRect();return i.applyTransform(a.transform),i.contain(e,n)&&!$I(t,r,o)}),WD(o.coordinateSystem)?(n.enable(o.get("roam")),i.zoomLimit=o.get("scaleLimit"),i.zoom=o.coordinateSystem.getZoom(),n.off("pan").off("zoom").on("pan",function(t){KI(i,t.dx,t.dy),r.dispatchAction({seriesId:o.id,type:"graphRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){JI(i,t.scale,t.originX,t.originY),r.dispatchAction({seriesId:o.id,type:"graphRoam",zoom:t.scale,originX:t.originX,originY:t.originY}),e._updateNodeAndLinkScale(),HD(o.getGraph(),oD(o)),e._lineDraw.updateLayout(),r.updateLabelLayout()})):n.disable()},XD.prototype._updateNodeAndLinkScale=function(){var t=this._model,e=t.getData(),n=oD(t);e.eachItemGraphicEl(function(t,e){t.setSymbolScale(n)})},XD.prototype.updateLayout=function(t){HD(t.getGraph(),oD(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},XD.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},XD.type="graph",XD);function XD(){var t=null!==UD&&UD.apply(this,arguments)||this;return t.type=XD.type,t}function ZD(t){return"_EC_"+t}var C=(QD.prototype.isDirected=function(){return this._directed},QD.prototype.addNode=function(t,e){var n=this._nodesMap;if(!n[ZD(t=null==t?""+e:""+t)]){e=new jD(t,e);return(e.hostGraph=this).nodes.push(e),n[ZD(t)]=e}},QD.prototype.getNodeByIndex=function(t){t=this.data.getRawIndex(t);return this.nodes[t]},QD.prototype.getNodeById=function(t){return this._nodesMap[ZD(t)]},QD.prototype.addEdge=function(t,e,n){var i=this._nodesMap,o=this._edgesMap;if("number"==typeof t&&(t=this.nodes[t]),"number"==typeof e&&(e=this.nodes[e]),t instanceof jD||(t=i[ZD(t)]),e instanceof jD||(e=i[ZD(e)]),t&&e){i=t.id+"-"+e.id,n=new qD(t,e,n);return(n.hostGraph=this)._directed&&(t.outEdges.push(n),e.inEdges.push(n)),t.edges.push(n),t!==e&&e.edges.push(n),this.edges.push(n),o[i]=n}},QD.prototype.getEdgeByIndex=function(t){t=this.edgeData.getRawIndex(t);return this.edges[t]},QD.prototype.getEdge=function(t,e){t instanceof jD&&(t=t.id),e instanceof jD&&(e=e.id);var n=this._edgesMap;return this._directed?n[t+"-"+e]:n[t+"-"+e]||n[e+"-"+t]},QD.prototype.eachNode=function(t,e){for(var n=this.nodes,i=n.length,o=0;o<i;o++)0<=n[o].dataIndex&&t.call(e,n[o],o)},QD.prototype.eachEdge=function(t,e){for(var n=this.edges,i=n.length,o=0;o<i;o++)0<=n[o].dataIndex&&0<=n[o].node1.dataIndex&&0<=n[o].node2.dataIndex&&t.call(e,n[o],o)},QD.prototype.breadthFirstTraverse=function(t,e,n,i){if(e=!(e instanceof jD)?this._nodesMap[ZD(e)]:e){for(var o="out"===n?"outEdges":"in"===n?"inEdges":"edges",r=0;r<this.nodes.length;r++)this.nodes[r].__visited=!1;if(!t.call(i,e,null))for(var a=[e];a.length;)for(var s=a.shift(),l=s[o],r=0;r<l.length;r++){var u=l[r],u=u.node1===s?u.node2:u.node1;if(!u.__visited){if(t.call(i,u,s))return;a.push(u),u.__visited=!0}}}},QD.prototype.update=function(){for(var t=this.data,e=this.edgeData,n=this.nodes,i=this.edges,o=0,r=n.length;o<r;o++)n[o].dataIndex=-1;for(o=0,r=t.count();o<r;o++)n[t.getRawIndex(o)].dataIndex=o;for(e.filterSelf(function(t){t=i[e.getRawIndex(t)];return 0<=t.node1.dataIndex&&0<=t.node2.dataIndex}),o=0,r=i.length;o<r;o++)i[o].dataIndex=-1;for(o=0,r=e.count();o<r;o++)i[e.getRawIndex(o)].dataIndex=o},QD.prototype.clone=function(){for(var t=new QD(this._directed),e=this.nodes,n=this.edges,i=0;i<e.length;i++)t.addNode(e[i].id,e[i].dataIndex);for(i=0;i<n.length;i++){var o=n[i];t.addEdge(o.node1.id,o.node2.id,o.dataIndex)}return t},QD),jD=(JD.prototype.degree=function(){return this.edges.length},JD.prototype.inDegree=function(){return this.inEdges.length},JD.prototype.outDegree=function(){return this.outEdges.length},JD.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostGraph.data.getItemModel(this.dataIndex).getModel(t)},JD.prototype.getAdjacentDataIndices=function(){for(var t={edge:[],node:[]},e=0;e<this.edges.length;e++){var n=this.edges[e];n.dataIndex<0||(t.edge.push(n.dataIndex),t.node.push(n.node1.dataIndex,n.node2.dataIndex))}return t},JD),qD=(KD.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostGraph.edgeData.getItemModel(this.dataIndex).getModel(t)},KD.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},KD);function KD(t,e,n){this.dataIndex=-1,this.node1=t,this.node2=e,this.dataIndex=null==n?-1:n}function JD(t,e){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=null==t?"":t,this.dataIndex=null==e?-1:e}function QD(t){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=t||!1}function $D(n,i){return{getValue:function(t){var e=this[n][i];return e.getStore().get(e.getDimensionIndex(t||"value"),this.dataIndex)},setVisual:function(t,e){0<=this.dataIndex&&this[n][i].setItemVisual(this.dataIndex,t,e)},getVisual:function(t){return this[n][i].getItemVisual(this.dataIndex,t)},setLayout:function(t,e){0<=this.dataIndex&&this[n][i].setItemLayout(this.dataIndex,t,e)},getLayout:function(){return this[n][i].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[n][i].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[n][i].getRawIndex(this.dataIndex)}}}B(jD,$D("hostGraph","data")),B(qD,$D("hostGraph","edgeData"));var tA=C;function eA(t,e,n,i,o){for(var r=new tA(i),a=0;a<t.length;a++)r.addNode(ot(t[a].id,t[a].name,a),a);for(var s=[],l=[],u=0,a=0;a<e.length;a++){var h=e[a],c=h.source,p=h.target;r.addEdge(c,p,u)&&(l.push(h),s.push(ot(Ho(h.id,null),c+" > "+p)),u++)}var d,i=n.get("coordinateSystem");"cartesian2d"===i||"polar"===i?d=w_(t,n):(V(i=(i=Sc.get(i))&&i.dimensions||[],"value")<0&&i.concat(["value"]),i=d_(t,{coordDimensions:i,encodeDefine:n.getEncode()}).dimensions,(d=new c_(i,n)).initData(t));n=new c_(["value"],n);return n.initData(l,s),o&&o(d,n),yT({mainData:d,struct:r,structAttr:"graph",datas:{node:d,edge:n},datasAttr:{node:"data",edge:"edgeData"}}),r.update(),r}var nA,iA=(d(rA,nA=Gd),rA.prototype.init=function(t){nA.prototype.init.apply(this,arguments);var e=this;function n(){return e._categoriesData}this.legendVisualProvider=new Rw(n,n),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},rA.prototype.mergeOption=function(t){nA.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},rA.prototype.mergeDefaultAndTheme=function(t){nA.prototype.mergeDefaultAndTheme.apply(this,arguments),zo(t,"edgeLabel",["show"])},rA.prototype.getInitialData=function(t,e){var n=t.edges||t.links||[],i=t.data||t.nodes||[],r=this;if(i&&n){JC(t=this)&&(t.__curvenessList=[],t.__edgeMap={},XC(t));n=eA(i,n,this,!0,function(t,e){t.wrapMethod("getItemModel",function(t){var e=r._categoriesModels[t.getShallow("category")];return e&&(e.parentModel=t.parentModel,t.parentModel=e),t});var n=wu.prototype.getModel;function i(t,e){e=n.call(this,t,e);return e.resolveParentPath=o,e}function o(t){if(!t||"label"!==t[0]&&"label"!==t[1])return t;var e=t.slice();return"label"===t[0]?e[0]="edgeLabel":"label"===t[1]&&(e[1]="edgeLabel"),e}e.wrapMethod("getItemModel",function(t){return t.resolveParentPath=o,t.getModel=i,t})});return G(n.edges,function(t){var e,n,i;e=t.node1,n=t.node2,i=this,t=t.dataIndex,JC(i)&&(e=QC(e,n,i),i=(n=i.__edgeMap)[ZC(e)],n[e]&&!i?n[e].isForward=!0:i&&n[e]&&(i.isForward=!0,n[e].isForward=!1),n[e]=n[e]||[],n[e].push(t))},this),n.data}},rA.prototype.getGraph=function(){return this.getData().graph},rA.prototype.getEdgeData=function(){return this.getGraph().edgeData},rA.prototype.getCategoriesData=function(){return this._categoriesData},rA.prototype.formatTooltip=function(t,e,n){if("edge"!==n)return Dd({series:this,dataIndex:t,multipleSeries:e});var i=this.getData(),e=this.getDataParams(t,n),n=i.graph.getEdgeByIndex(t),t=i.getName(n.node1.dataIndex),i=i.getName(n.node2.dataIndex),n=[];return null!=t&&n.push(t),null!=i&&n.push(i),md("nameValue",{name:n.join(" > "),value:e.value,noValue:null==e.value})},rA.prototype._updateCategoriesData=function(){var t=H(this.option.categories||[],function(t){return null!=t.value?t:N({value:0},t)}),e=new c_(["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray(function(t){return e.getItemModel(t)})},rA.prototype.setZoom=function(t){this.option.zoom=t},rA.prototype.setCenter=function(t){this.option.center=t},rA.prototype.isAnimationEnabled=function(){return nA.prototype.isAnimationEnabled.call(this)&&!("force"===this.get("layout")&&this.get(["force","layoutAnimation"]))},rA.type="series.graph",rA.dependencies=["grid","polar","geo","singleAxis","calendar"],rA.defaultOption={zlevel:0,z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},rA),oA={type:"graphRoam",event:"graphRoam",update:"none"};function rA(){var t=null!==nA&&nA.apply(this,arguments)||this;return t.type=rA.type,t.hasSymbolVisual=!0,t}var aA,sA=function(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0},lA=(d(uA,aA=as),uA.prototype.getDefaultShape=function(){return new sA},uA.prototype.buildPath=function(t,e){var n=Math.cos,i=Math.sin,o=e.r,r=e.width,a=e.angle,s=e.x-n(a)*r*(o/3<=r?1:2),l=e.y-i(a)*r*(o/3<=r?1:2),a=e.angle-Math.PI/2;t.moveTo(s,l),t.lineTo(e.x+n(a)*r,e.y+i(a)*r),t.lineTo(e.x+n(e.angle)*o,e.y+i(e.angle)*o),t.lineTo(e.x-n(a)*r,e.y-i(a)*r),t.lineTo(s,l)},uA);function uA(t){t=aA.call(this,t)||this;return t.type="pointer",t}function hA(t,e){var n=null==t?"":t+"";return e&&("string"==typeof e?n=e.replace("{value}",n):"function"==typeof e&&(n=e(t))),n}var cA,pA,dA=2*Math.PI,fA=(d(mA,pA=$d),mA.prototype.render=function(t,e,n){this.group.removeAll();var i,o,r,a,s=t.get(["axisLine","lineStyle","color"]),l=(o=n,r=(i=t).get("center"),a=o.getWidth(),l=o.getHeight(),l=Math.min(a,l),{cx:go(r[0],o.getWidth()),cy:go(r[1],o.getHeight()),r:go(i.get("radius"),l/2)});this._renderMain(t,e,n,s,l),this._data=t.getData()},mA.prototype.dispose=function(){},mA.prototype._renderMain=function(t,e,n,i,o){for(var r=this.group,a=t.get("clockwise"),s=-t.get("startAngle")/180*Math.PI,l=-t.get("endAngle")/180*Math.PI,u=t.getModel("axisLine"),h=u.get("roundCap")?Gb:Wg,c=u.get("show"),p=u.getModel("lineStyle"),d=p.get("width"),f=(l-s)%dA||l===s?(l-s)%dA:dA,g=s,y=0;c&&y<i.length;y++){var m=new h({shape:{startAngle:g,endAngle:l=s+f*Math.min(Math.max(i[y][0],0),1),cx:o.cx,cy:o.cy,clockwise:a,r0:o.r-d,r:o.r},silent:!0});m.setStyle({fill:i[y][1]}),m.setStyle(p.getLineStyle(["color","width"])),r.add(m),g=l}function v(t){if(t<=0)return i[0][1];for(var e=0;e<i.length;e++)if(i[e][0]>=t&&(0===e?0:i[e-1][0])<t)return i[e][1];return i[e-1][1]}a||(u=s,s=l,l=u),this._renderTicks(t,e,n,v,o,s,l,a,d),this._renderTitleAndDetail(t,e,n,v,o),this._renderAnchor(t,o),this._renderPointer(t,e,n,v,o,s,l,a,d)},mA.prototype._renderTicks=function(t,e,n,i,o,r,a,s,l){for(var u=this.group,h=o.cx,c=o.cy,p=o.r,d=+t.get("min"),f=+t.get("max"),g=t.getModel("splitLine"),y=t.getModel("axisTick"),m=t.getModel("axisLabel"),v=t.get("splitNumber"),x=y.get("splitNumber"),_=go(g.get("length"),p),b=go(y.get("length"),p),w=r,S=(a-r)/v,M=S/x,I=g.getModel("lineStyle").getLineStyle(),T=y.getModel("lineStyle").getLineStyle(),C=g.get("distance"),D=0;D<=v;D++){var A,k,L,P=Math.cos(w),O=Math.sin(w);if(g.get("show")&&(L=new Kf({shape:{x1:P*(p-(A=C?C+l:l))+h,y1:O*(p-A)+c,x2:P*(p-_-A)+h,y2:O*(p-_-A)+c},style:I,silent:!0}),"auto"===I.stroke&&L.setStyle({stroke:i(D/v)}),u.add(L)),m.get("show")&&(A=m.get("distance")+C,k=hA(yo(D/v*(f-d)+d),m.get("formatter")),L=i(D/v),u.add(new Fs({style:eu(m,{text:k,x:P*(p-_-A)+h,y:O*(p-_-A)+c,verticalAlign:O<-.8?"top":.8<O?"bottom":"middle",align:P<-.4?"left":.4<P?"right":"center"},{inheritColor:L}),silent:!0}))),y.get("show")&&D!==v){A=(A=y.get("distance"))?A+l:l;for(var R=0;R<=x;R++){P=Math.cos(w),O=Math.sin(w);var N=new Kf({shape:{x1:P*(p-A)+h,y1:O*(p-A)+c,x2:P*(p-b-A)+h,y2:O*(p-b-A)+c},silent:!0,style:T});"auto"===T.stroke&&N.setStyle({stroke:i((D+R/x)/v)}),u.add(N),w+=M}w-=M}else w+=S}},mA.prototype._renderPointer=function(s,t,e,l,u,a,n,h,c){var o=this.group,r=this._data,p=this._progressEls,d=[],f=s.get(["pointer","show"]),g=s.getModel("progress"),y=g.get("show"),m=s.getData(),v=m.mapDimension("value"),i=+s.get("min"),x=+s.get("max"),_=[i,x],b=[a,n];function w(t,e){var n=m.getItemModel(t).getModel("pointer"),i=go(n.get("width"),u.r),o=go(n.get("length"),u.r),r=s.get(["pointer","icon"]),a=n.get("offsetCenter"),t=go(a[0],u.r),a=go(a[1],u.r),n=n.get("keepAspect"),a=r?am(r,t-i/2,a-o,i,o,null,n):new lA({shape:{angle:-Math.PI/2,width:i,r:o,x:t,y:a}});return a.rotation=-(e+Math.PI/2),a.x=u.cx,a.y=u.cy,a}function S(t,e){var n=g.get("roundCap")?Gb:Wg,i=g.get("overlap"),o=i?g.get("width"):c/m.count(),r=i?u.r-o:u.r-(t+1)*o,o=i?u.r:u.r-t*o,o=new n({shape:{startAngle:a,endAngle:e,cx:u.cx,cy:u.cy,clockwise:h,r0:r,r:o}});return i&&(o.z2=x-m.get(v,t)%x),o}(y||f)&&(m.diff(r).add(function(t){var e,n;f&&(Ul(n=w(t,a),{rotation:-(fo(m.get(v,t),_,b,!0)+Math.PI/2)},s),o.add(n),m.setItemGraphicEl(t,n)),y&&(e=S(t,a),n=g.get("clip"),Ul(e,{shape:{endAngle:fo(m.get(v,t),_,b,n)}},s),o.add(e),Bs(s.seriesIndex,m.dataType,t,e),d[t]=e)}).update(function(t,e){var n,i;f&&((i=w(t,n=(i=r.getItemGraphicEl(e))?i.rotation:a)).rotation=n,Wl(i,{rotation:-(fo(m.get(v,t),_,b,!0)+Math.PI/2)},s),o.add(i),m.setItemGraphicEl(t,i)),y&&(e=S(t,(i=p[e])?i.shape.endAngle:a),i=g.get("clip"),Wl(e,{shape:{endAngle:fo(m.get(v,t),_,b,i)}},s),o.add(e),Bs(s.seriesIndex,m.dataType,t,e),d[t]=e)}).execute(),m.each(function(t){var e,n,i,o,r=m.getItemModel(t),a=r.getModel("emphasis");f&&(o=m.getItemGraphicEl(t),n=(e=m.getItemVisual(t,"style")).fill,o instanceof ys?(i=o.style,o.useStyle(N({image:i.image,x:i.x,y:i.y,width:i.width,height:i.height},e))):(o.useStyle(e),"pointer"!==o.type&&o.setColor(n)),o.setStyle(r.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===o.style.fill&&o.setStyle("fill",l(fo(m.get(v,t),_,[0,1],!0))),o.z2EmphasisLift=0,Nl(o,r),Ll(o,a.get("focus"),a.get("blurScope"))),y&&((o=d[t]).useStyle(m.getItemVisual(t,"style")),o.setStyle(r.getModel(["progress","itemStyle"]).getItemStyle()),o.z2EmphasisLift=0,Nl(o,r),Ll(o,a.get("focus"),a.get("blurScope")))}),this._progressEls=d)},mA.prototype._renderAnchor=function(t,e){var n,i,o,r=t.getModel("anchor");r.get("show")&&(n=r.get("size"),i=r.get("icon"),o=r.get("offsetCenter"),t=r.get("keepAspect"),(t=am(i,e.cx-n/2+go(o[0],e.r),e.cy-n/2+go(o[1],e.r),n,n,null,t)).z2=r.get("showAbove")?1:0,t.setStyle(r.getModel("itemStyle").getItemStyle()),this.group.add(t))},mA.prototype._renderTitleAndDetail=function(c,t,e,p,d){var n=this,f=c.getData(),g=f.mapDimension("value"),y=+c.get("min"),m=+c.get("max"),v=new ro,x=[],_=[],b=c.isAnimationEnabled(),w=c.get(["pointer","showAbove"]);f.diff(this._data).add(function(t){x[t]=new Fs({silent:!0}),_[t]=new Fs({silent:!0})}).update(function(t,e){x[t]=n._titleEls[e],_[t]=n._detailEls[e]}).execute(),f.each(function(t){var e,n=f.getItemModel(t),a=f.get(g,t),i=new ro,o=p(fo(a,[y,m],[0,1],!0)),r=n.getModel("title");r.get("show")&&(h=r.get("offsetCenter"),s=d.cx+go(h[0],d.r),l=d.cy+go(h[1],d.r),(e=x[t]).attr({z2:w?0:2,style:eu(r,{x:s,y:l,text:f.getName(t),align:"center",verticalAlign:"middle"},{inheritColor:o})}),i.add(e));var s,l,u,h=n.getModel("detail");h.get("show")&&(r=h.get("offsetCenter"),s=d.cx+go(r[0],d.r),l=d.cy+go(r[1],d.r),n=go(h.get("width"),d.r),r=go(h.get("height"),d.r),o=c.get(["progress","show"])?f.getItemVisual(t,"style").fill:o,e=_[t],u=h.get("formatter"),e.attr({z2:w?0:2,style:eu(h,{x:s,y:l,text:hA(a,u),width:isNaN(n)?null:n,height:isNaN(r)?null:r,align:"center",verticalAlign:"middle"},{inheritColor:o})}),uu(e,{normal:h},a,function(t){return hA(t,u)}),b&&hu(e,t,f,c,{getFormattedLabel:function(t,e,n,i,o,r){return hA(r?r.interpolatedValue:a,u)}}),i.add(e)),v.add(i)}),this.group.add(v),this._titleEls=x,this._detailEls=_},mA.type="gauge",mA),gA=(d(yA,cA=Gd),yA.prototype.getInitialData=function(t,e){return Pw(this,["value"])},yA.type="series.gauge",yA.defaultOption={zlevel:0,z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},yA);function yA(){var t=null!==cA&&cA.apply(this,arguments)||this;return t.type=yA.type,t.visualStyleAccessPath="itemStyle",t}function mA(){var t=null!==pA&&pA.apply(this,arguments)||this;return t.type=mA.type,t}var vA,xA,_A,bA=["itemStyle","opacity"],wA=(d(CA,_A=$g),CA.prototype.updateData=function(t,e,n){var i=t.hostModel,o=t.getItemModel(e),r=t.getItemLayout(e),a=o.getModel("emphasis"),s=null==(s=o.get(bA))?1:s;n||ql(this),this.useStyle(t.getItemVisual(e,"style")),this.style.lineJoin="round",n?(this.setShape({points:r.points}),this.style.opacity=0,Ul(this,{style:{opacity:s}},i,e)):Wl(this,{style:{opacity:s},shape:{points:r.points}},i,e),Nl(this,o),this._updateLabel(t,e),Ll(this,a.get("focus"),a.get("blurScope"))},CA.prototype._updateLabel=function(t,e){var n=this.getTextGuideLine(),i=this.getTextContent(),o=t.hostModel,r=t.getItemModel(e),a=t.getItemLayout(e).label,s=t.getItemVisual(e,"style"),l=s.fill;$l(i,tu(r),{labelFetcher:t.hostModel,labelDataIndex:e,defaultOpacity:s.opacity,defaultText:t.getName(e)},{normal:{align:a.textAlign,verticalAlign:a.verticalAlign}}),this.setTextConfig({local:!0,inside:!!a.inside,insideStroke:l,outsideFill:l});t=a.linePoints;n.setShape({points:t}),this.textGuideLineConfig={anchor:t?new bi(t[0][0],t[0][1]):null},Wl(i,{style:{x:a.x,y:a.y}},o,e),i.attr({rotation:a.rotation,originX:a.x,originY:a.y,z2:10}),c1(this,p1(r),{stroke:l})},CA),SA=(d(TA,xA=$d),TA.prototype.render=function(e,t,n){var i=e.getData(),o=this._data,r=this.group;i.diff(o).add(function(t){var e=new wA(i,t);i.setItemGraphicEl(t,e),r.add(e)}).update(function(t,e){e=o.getItemGraphicEl(e);e.updateData(i,t),r.add(e),i.setItemGraphicEl(t,e)}).remove(function(t){jl(o.getItemGraphicEl(t),e,t)}).execute(),this._data=i},TA.prototype.remove=function(){this.group.removeAll(),this._data=null},TA.prototype.dispose=function(){},TA.type="funnel",TA),MA=(d(IA,vA=Gd),IA.prototype.init=function(t){vA.prototype.init.apply(this,arguments),this.legendVisualProvider=new Rw(X(this.getData,this),X(this.getRawData,this)),this._defaultLabelLine(t)},IA.prototype.getInitialData=function(t,e){return Pw(this,{coordDimensions:["value"],encodeDefaulter:Z(Qh,this)})},IA.prototype._defaultLabelLine=function(t){zo(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},IA.prototype.getDataParams=function(t){var e=this.getData(),n=vA.prototype.getDataParams.call(this,t),i=e.mapDimension("value"),o=e.getSum(i);return n.percent=o?+(e.get(i,t)/o*100).toFixed(2):0,n.$vars.push("percent"),n},IA.type="series.funnel",IA.defaultOption={zlevel:0,z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},IA);function IA(){var t=null!==vA&&vA.apply(this,arguments)||this;return t.type=IA.type,t}function TA(){var t=null!==xA&&xA.apply(this,arguments)||this;return t.type=TA.type,t.ignoreLabelLineUpdate=!0,t}function CA(t,e){var n=_A.call(this)||this,i=n,o=new ny,r=new Fs;return i.setTextContent(r),n.setTextGuideLine(o),n.updateData(t,e,!0),n}function DA(t,C){t.eachSeriesByType("funnel",function(t){var a=t.getData(),s=a.mapDimension("value"),e=t.get("sort"),n=(n=C,Sh(t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})),l=t.get("orient"),u=n.width,h=n.height,i=function(t,e){for(var n=t.mapDimension("value"),i=t.mapArray(n,function(t){return t}),o=[],r="ascending"===e,a=0,s=t.count();a<s;a++)o[a]=a;return"function"==typeof e?o.sort(e):"none"!==e&&o.sort(function(t,e){return r?i[t]-i[e]:i[e]-i[t]}),o}(a,e),c=n.x,p=n.y,d="horizontal"===l?[go(t.get("minSize"),h),go(t.get("maxSize"),h)]:[go(t.get("minSize"),u),go(t.get("maxSize"),u)],n=a.getDataExtent(s),f=t.get("min"),g=t.get("max");null==f&&(f=Math.min(n[0],0)),null==g&&(g=n[1]);function o(t,e){if("horizontal"===l){var n=fo(a.get(s,t)||0,[f,g],d,!0),i=void 0;switch(y){case"top":i=p;break;case"center":i=p+(h-n)/2;break;case"bottom":i=p+(h-n)}return[[e,i],[e,i+n]]}var o,r=fo(a.get(s,t)||0,[f,g],d,!0);switch(y){case"left":o=c;break;case"center":o=c+(u-r)/2;break;case"right":o=c+u-r}return[[o,e],[o+r,e]]}var y=t.get("funnelAlign"),r=t.get("gap"),m=(("horizontal"===l?u:h)-r*(a.count()-1))/a.count();"ascending"===e&&(m=-m,r=-r,"horizontal"===l?c+=u:p+=h,i=i.reverse());for(var v,x,_=0;_<i.length;_++){var b,w,S,M=i[_],I=i[_+1],T=a.getItemModel(M);"horizontal"===l?(null==(b=T.get(["itemStyle","width"]))?b=m:(b=go(b,u),"ascending"===e&&(b=-b)),w=o(M,c),S=o(I,c+b),c+=b+r):(null==(T=T.get(["itemStyle","height"]))?T=m:(T=go(T,h),"ascending"===e&&(T=-T)),w=o(M,p),S=o(I,p+T),p+=T+r),a.setItemLayout(M,{points:w.concat(S.slice().reverse())})}x=(v=a).hostModel.get("orient"),v.each(function(t){var e,n,i,o,r=v.getItemModel(t),a=r.getModel("label").get("position"),s=r.getModel("labelLine"),l=v.getItemLayout(t),u=l.points,h="inner"===a||"inside"===a||"center"===a||"insideLeft"===a||"insideRight"===a,c=h?(o="insideLeft"===a?(e=(u[0][0]+u[3][0])/2+5,n=(u[0][1]+u[3][1])/2,"left"):"insideRight"===a?(e=(u[1][0]+u[2][0])/2-5,n=(u[1][1]+u[2][1])/2,"right"):(e=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,n=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,"center"),[[e,n],[e,n]]):(c=t=r=i=void 0,s=s.get("length"),o="left"===a?(i=(u[3][0]+u[0][0])/2,r=(u[3][1]+u[0][1])/2,e=(t=i-s)-5,"right"):"right"===a?(i=(u[1][0]+u[2][0])/2,r=(u[1][1]+u[2][1])/2,e=(t=i+s)+5,"left"):"top"===a?(i=(u[3][0]+u[0][0])/2,n=(c=(r=(u[3][1]+u[0][1])/2)-s)-5,"center"):"bottom"===a?(i=(u[1][0]+u[2][0])/2,n=(c=(r=(u[1][1]+u[2][1])/2)+s)+5,"center"):"rightTop"===a?(i=("horizontal"===x?u[3]:u[1])[0],r=("horizontal"===x?u[3]:u[1])[1],"horizontal"===x?(n=(c=r-s)-5,"center"):(e=(t=i+s)+5,"top")):"rightBottom"===a?(i=u[2][0],r=u[2][1],"horizontal"===x?(n=(c=r+s)+5,"center"):(e=(t=i+s)+5,"bottom")):"leftTop"===a?(i=u[0][0],r=("horizontal"===x?u[0]:u[1])[1],"horizontal"===x?(n=(c=r-s)-5,"center"):(e=(t=i-s)-5,"right")):"leftBottom"===a?(i=("horizontal"===x?u[1]:u[3])[0],r=("horizontal"===x?u[1]:u[2])[1],"horizontal"===x?(n=(c=r+s)+5,"center"):(e=(t=i-s)-5,"right")):(i=(u[1][0]+u[2][0])/2,r=(u[1][1]+u[2][1])/2,"horizontal"===x?(n=(c=r+s)+5,"center"):(e=(t=i+s)+5,"left")),"horizontal"===x?e=t=i:n=c=r,[[i,r],[t,c]]);l.label={linePoints:c,x:e,y:n,verticalAlign:"middle",textAlign:o,inside:h}})})}var AA;function kA(){var t=null!==AA&&AA.apply(this,arguments)||this;return t.type=kA.type,t._dataGroup=new ro,t._initialized=!1,t}function LA(t,e,n,i){for(var o,r=[],a=0;a<n.length;a++){var s=n[a],l=t.get(t.mapDimension(s),e);o=l,("category"===i.getAxis(s).type?null==o:null==o||isNaN(o))||r.push(i.dataToPoint(l,s))}return r}function PA(t,e,n,i,o){o=LA(t,n,i,o),o=new ny({shape:{points:o},z2:10});return e.add(o),t.setItemGraphicEl(n,o),o}function OA(t){t=t.get("smooth",!0);return{smooth:t=it(t=Ao(t=!0===t?.3:t))?0:t}}function RA(t,e,n,i){t.useStyle(e.getItemVisual(n,"style")),t.style.fill=null,t.setShape("smooth",i.smooth);e=e.getItemModel(n),n=e.getModel("emphasis");Nl(t,e,"lineStyle"),Ll(t,n.get("focus"),n.get("blurScope"))}var NA,zA=(d(kA,AA=$d),kA.prototype.init=function(){this.group.add(this._dataGroup)},kA.prototype.render=function(i,t,e,n){var o,r,a,s,l,u=this._dataGroup,h=i.getData(),c=this._data,p=i.coordinateSystem,d=p.dimensions,f=OA(i);h.diff(c).add(function(t){RA(PA(h,u,t,d,p),h,t,f)}).update(function(t,e){var n=c.getItemGraphicEl(e),e=LA(h,t,d,p);h.setItemGraphicEl(t,n),Wl(n,{shape:{points:e}},i,t),ql(n),RA(n,h,t,f)}).remove(function(t){t=c.getItemGraphicEl(t),u.remove(t)}).execute(),this._initialized||(this._initialized=!0,r=i,a=function(){setTimeout(function(){u.removeClipPath()})},s=(o=p).model,l=o.getRect(),o=new Ts({shape:{x:l.x,y:l.y,width:l.width,height:l.height}}),s="horizontal"===s.get("layout")?"width":"height",o.setShape(s,0),Ul(o,{shape:{width:l.width,height:l.height}},r,a),u.setClipPath(o)),this._data=h},kA.prototype.incrementalPrepareRender=function(t,e,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},kA.prototype.incrementalRender=function(t,e,n){for(var i=e.getData(),o=e.coordinateSystem,r=o.dimensions,a=OA(e),s=t.start;s<t.end;s++){var l=PA(i,this._dataGroup,s,r,o);l.incremental=!0,RA(l,i,s,a)}},kA.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},kA.type="parallel",kA);function EA(){var t=null!==NA&&NA.apply(this,arguments)||this;return t.type=EA.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}function VA(t){t=t.ecModel.getComponent("parallel",t.get("parallelIndex"));if(t){var n={};return G(t.dimensions,function(t){var e=+t.replace("dim","");n[t]=e}),n}}var BA=(d(EA,NA=Gd),EA.prototype.getInitialData=function(t,e){return w_(null,this,{useEncodeDefaulter:X(VA,null,this)})},EA.prototype.getRawIndicesByActiveState=function(n){var t=this.coordinateSystem,i=this.getData(),o=[];return t.eachActiveState(i,function(t,e){n===t&&o.push(i.getRawIndex(e))}),o},EA.type="series.parallel",EA.dependencies=["parallel"],EA.defaultOption={zlevel:0,z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"},EA),FA=["lineStyle","opacity"],GA={seriesType:"parallel",reset:function(t,e){var n=t.coordinateSystem,o={normal:t.get(["lineStyle","opacity"]),active:t.get("activeOpacity"),inactive:t.get("inactiveOpacity")};return{progress:function(t,i){n.eachActiveState(i,function(t,e){var n=o[t];"normal"!==t||!i.hasItemOption||null!=(t=i.getItemModel(e).get(FA,!0))&&(n=t),i.ensureUniqueItemVisual(e,"style").opacity=n},t.start,t.end)}}}};function HA(t){var n;(function(t){{var e;t.parallel||(e=!1,G(t.series,function(t){t&&"parallel"===t.type&&(e=!0)}),e&&(t.parallel=[{}]))}})(t),G(No((n=t).parallelAxis),function(t){var e;$(t)&&(e=t.parallelIndex||0,(e=No(n.parallel)[e])&&e.parallelAxisDefault&&O(t,e.parallelAxisDefault,!1))})}var WA,mu=(d(YA,WA=Wd),YA.prototype.render=function(t,e,n){this._model=t,this._api=n,this._handlers||(this._handlers={},G(UA,function(t,e){n.getZr().on(e,this._handlers[e]=X(t,this))},this)),rf(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},YA.prototype.dispose=function(t,n){G(this._handlers,function(t,e){n.getZr().off(e,t)}),this._handlers=null},YA.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},YA.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(N({type:"parallelAxisExpand"},t))},YA.type="parallel",YA),UA={mousedown:function(t){XA(this,"click")&&(this._mouseDownPoint=[t.offsetX,t.offsetY])},mouseup:function(t){var e=this._mouseDownPoint;if(XA(this,"click")&&e){var n=[t.offsetX,t.offsetY];if(5<Math.pow(e[0]-n[0],2)+Math.pow(e[1]-n[1],2))return;t=this._model.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]);"none"!==t.behavior&&this._dispatchExpand({axisExpandWindow:t.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(t){var e,n;!this._mouseDownPoint&&XA(this,"mousemove")&&("jump"===(t=(n=(e=this._model).coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY])).behavior)&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===t?null:{axisExpandWindow:n.axisExpandWindow,animation:"jump"===t?null:{duration:0}}))}};function YA(){var t=null!==WA&&WA.apply(this,arguments)||this;return t.type=YA.type,t}function XA(t,e){t=t._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}var ZA,jA,qA=mu,KA=(d($A,jA=Vh),$A.prototype.init=function(){jA.prototype.init.apply(this,arguments),this.mergeOption({})},$A.prototype.mergeOption=function(t){var e=this.option;t&&O(e,t,!0),this._initDimensions()},$A.prototype.contains=function(t,e){t=t.get("parallelIndex");return null!=t&&e.getComponent("parallel",t)===this},$A.prototype.setAxisExpand=function(e){G(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(t){e.hasOwnProperty(t)&&(this.option[t]=e[t])},this)},$A.prototype._initDimensions=function(){var e=this.dimensions=[],n=this.parallelAxisIndex=[];G(U(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(t){return(t.get("parallelIndex")||0)===this.componentIndex},this),function(t){e.push("dim"+t.get("dim")),n.push(t.componentIndex)})},$A.type="parallel",$A.dependencies=["parallelAxis"],$A.layoutMode="box",$A.defaultOption={zlevel:0,z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},$A),JA=(d(QA,ZA=_),QA.prototype.isHorizontal=function(){return"horizontal"!==this.coordinateSystem.getModel().get("layout")},QA);function QA(t,e,n,i,o){n=ZA.call(this,t,e,n)||this;return n.type=i||"value",n.axisIndex=o,n}function $A(){var t=null!==jA&&jA.apply(this,arguments)||this;return t.type=$A.type,t}function tk(t,e,n,i,o,r){t=t||0;var a=n[1]-n[0];null!=o&&(o=nk(o,[0,a])),null!=r&&(r=Math.max(r,null!=o?o:0)),"all"===i&&(s=nk(s=Math.abs(e[1]-e[0]),[0,a]),o=r=nk(s,[o,r]),i=0),e[0]=nk(e[0],n),e[1]=nk(e[1],n);var s=ek(e,i);e[i]+=t;var t=o||0,n=n.slice();return s.sign<0?n[0]+=t:n[1]-=t,e[i]=nk(e[i],n),n=ek(e,i),null!=o&&(n.sign!==s.sign||n.span<o)&&(e[1-i]=e[i]+s.sign*o),n=ek(e,i),null!=r&&n.span>r&&(e[1-i]=e[i]+n.sign*r),e}function ek(t,e){t=t[e]-t[1-e];return{span:Math.abs(t),sign:0<t||!(t<0)&&e?-1:1}}function nk(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}var ik=G,ok=Math.min,rk=Math.max,ak=Math.floor,sk=Math.ceil,lk=yo,uk=Math.PI;function hk(t,e,n){this.type="parallel",this._axesMap=yt(),this._axesLayout={},this.dimensions=t.dimensions,this._model=t,this._init(t,e,n)}function ck(t,e){return ok(rk(t,e[0]),e[1])}var pk=(hk.prototype._init=function(t,i,e){var n=t.dimensions,o=t.parallelAxisIndex;ik(n,function(t,e){var n=o[e],e=i.getComponent("parallelAxis",n),t=this._axesMap.set(t,new JA(t,QS(e),[0,0],e.get("type"),n)),n="category"===t.type;t.onBand=n&&e.get("boundaryGap"),t.inverse=e.get("inverse"),(e.axis=t).model=e,t.coordinateSystem=e.coordinateSystem=this},this)},hk.prototype.update=function(t,e){this._updateAxesFromSeries(this._model,t)},hk.prototype.containPoint=function(t){var e=this._makeLayoutInfo(),n=e.axisBase,i=e.layoutBase,o=e.pixelDimIndex,r=t[1-o],o=t[o];return n<=r&&r<=n+e.axisLength&&i<=o&&o<=i+e.layoutLength},hk.prototype.getModel=function(){return this._model},hk.prototype._updateAxesFromSeries=function(e,i){i.eachSeries(function(t){var n;e.contains(t,i)&&(n=t.getData(),ik(this.dimensions,function(t){var e=this._axesMap.get(t);e.scale.unionExtentFromData(n,n.mapDimension(t)),JS(e.scale,e.model)},this))},this)},hk.prototype.resize=function(t,e){this._rect=Sh(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},hk.prototype.getRect=function(){return this._rect},hk.prototype._makeLayoutInfo=function(){var t=this._model,e=this._rect,n=["x","y"],i=["width","height"],o=t.get("layout"),r="horizontal"===o?0:1,a=e[i[r]],s=[0,a],l=this.dimensions.length,u=ck(t.get("axisExpandWidth"),s),h=ck(t.get("axisExpandCount")||0,[0,l]),c=t.get("axisExpandable")&&3<l&&h<l&&1<h&&0<u&&0<a,p=t.get("axisExpandWindow");p?(d=ck(p[1]-p[0],s),p[1]=p[0]+d):(d=ck(u*(h-1),s),(p=[u*(t.get("axisExpandCenter")||ak(l/2))-d/2])[1]=p[0]+d);t=(a-d)/(l-h);t<3&&(t=0);var d=[ak(lk(p[0]/u,1))+1,sk(lk(p[1]/u,1))-1],h=t/u*p[0];return{layout:o,pixelDimIndex:r,layoutBase:e[n[r]],layoutLength:a,axisBase:e[n[1-r]],axisLength:e[i[1-r]],axisExpandable:c,axisExpandWidth:u,axisCollapseWidth:t,axisExpandWindow:p,axisCount:l,winInnerIndices:d,axisExpandWindow0Pos:h}},hk.prototype._layoutAxes=function(){var r=this._rect,t=this._axesMap,e=this.dimensions,a=this._makeLayoutInfo(),s=a.layout;t.each(function(t){var e=[0,a.axisLength],n=t.inverse?1:0;t.setExtent(e[n],e[1-n])}),ik(e,function(t,e){var n=(a.axisExpandable?function(t,e){var n,i,o=e.layoutLength,r=e.axisExpandWidth,a=e.axisCount,s=e.axisCollapseWidth,l=e.winInnerIndices,u=s,h=!1;return t<l[0]?(n=t*s,i=s):t<=l[1]?(n=e.axisExpandWindow0Pos+t*r-e.axisExpandWindow[0],u=r,h=!0):(n=o-(a-1-t)*s,i=s),{position:n,axisNameAvailableWidth:u,axisLabelShow:h,nameTruncateMaxWidth:i}}:function(t,e){e=e.layoutLength/(e.axisCount-1);return{position:e*t,axisNameAvailableWidth:e,axisLabelShow:!0}})(e,a),i={horizontal:{x:n.position,y:a.axisLength},vertical:{x:0,y:n.position}},o=[i[s].x+r.x,i[s].y+r.y],e={horizontal:uk/2,vertical:0}[s],i=ni();si(i,i,e),ai(i,i,o),this._axesLayout[t]={position:o,rotation:e,transform:i,axisNameAvailableWidth:n.axisNameAvailableWidth,axisLabelShow:n.axisLabelShow,nameTruncateMaxWidth:n.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},hk.prototype.getAxis=function(t){return this._axesMap.get(t)},hk.prototype.dataToPoint=function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},hk.prototype.eachActiveState=function(e,t,n,i){null==n&&(n=0),null==i&&(i=e.count());var o=this._axesMap,r=this.dimensions,a=[],s=[];G(r,function(t){a.push(e.mapDimension(t)),s.push(o.get(t).model)});for(var l=this.hasAxisBrushed(),u=n;u<i;u++){var h=void 0;if(l){for(var h="active",c=e.getValues(a,u),p=0,d=r.length;p<d;p++)if("inactive"===s[p].getActiveState(c[p])){h="inactive";break}}else h="normal";t(h,u)}},hk.prototype.hasAxisBrushed=function(){for(var t=this.dimensions,e=this._axesMap,n=!1,i=0,o=t.length;i<o;i++)"normal"!==e.get(t[i]).model.getActiveState()&&(n=!0);return n},hk.prototype.axisCoordToPoint=function(t,e){return Xy([t,0],this._axesLayout[e].transform)},hk.prototype.getAxisLayout=function(t){return P(this._axesLayout[t])},hk.prototype.getSlidedAxisExpandWindow=function(t){var e=this._makeLayoutInfo(),n=e.pixelDimIndex,i=e.axisExpandWindow.slice(),o=i[1]-i[0],r=[0,e.axisExpandWidth*(e.axisCount-1)];if(!this.containPoint(t))return{behavior:"none",axisExpandWindow:i};var a,s=t[n]-e.layoutBase-e.axisExpandWindow0Pos,l="slide",u=e.axisCollapseWidth,t=this._model.get("axisExpandSlideTriggerArea"),n=null!=t[0];return u?(n&&u&&s<o*t[0]?(l="jump",a=s-o*t[2]):n&&u&&s>o*(1-t[0])?(l="jump",a=s-o*(1-t[2])):0<=(a=s-o*t[1])&&(a=s-o*(1-t[1]))<=0&&(a=0),(a*=e.axisExpandWidth/u)?tk(a,i,r,"all"):l="none"):(a=i[1]-i[0],(i=[rk(0,r[1]*s/a-a/2)])[1]=ok(r[1],i[0]+a),i[0]=i[1]-a),{axisExpandWindow:i,behavior:l}},hk);var dk,fk={create:function(i,o){var r=[];return i.eachComponent("parallel",function(t,e){var n=new pk(t,i,o);n.name="parallel_"+e,n.resize(t,o),(t.coordinateSystem=n).model=t,r.push(n)}),i.eachSeries(function(t){var e;"parallel"===t.get("coordinateSystem")&&(e=t.getReferringComponents("parallel",Jo).models[0],t.coordinateSystem=e.coordinateSystem)}),r}},Jn=(d(gk,dk=Vh),gk.prototype.getAreaSelectStyle=function(){return dr([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},gk.prototype.setActiveIntervals=function(t){var e=this.activeIntervals=P(t);if(e)for(var n=e.length-1;0<=n;n--)mo(e[n])},gk.prototype.getActiveState=function(t){var e=this.activeIntervals;if(!e.length)return"normal";if(null==t||isNaN(+t))return"inactive";if(1===e.length){var n=e[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var i=0,o=e.length;i<o;i++)if(e[i][0]<=t&&t<=e[i][1])return"active";return"inactive"},gk);function gk(){var t=null!==dk&&dk.apply(this,arguments)||this;return t.type=gk.type,t.activeIntervals=[],t}B(Jn,qw);var yk,mk=Jn,vk=!0,xk=Math.min,_k=Math.max,bk=Math.pow,wk=1e4,Sk=6,Mk=6,Ik="globalPan",Tk={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},Ck={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},Dk={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},Ak=0,gr=(d(kk,yk=Gt),kk.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},kk.prototype._doEnableBrush=function(t){var e,n,i=this._zr;this._enableGlobalPan||(e=Ik,n=this._uid,UI(i)[e]=n),G(this._handlers,function(t,e){i.on(e,t)}),this._brushType=t.brushType,this._brushOption=O(P(Dk),t,!0)},kk.prototype._doDisableBrush=function(){var t,e,n,i=this._zr;t=i,e=Ik,n=this._uid,(t=UI(t))[e]===n&&(t[e]=null),G(this._handlers,function(t,e){i.off(e,t)}),this._brushType=this._brushOption=null},kk.prototype.setPanels=function(t){var e;return t&&t.length?(e=this._panels={},G(t,function(t){e[t.panelId]=P(t)})):this._panels=null,this},kk.prototype.mount=function(t){this._enableGlobalPan=(t=t||{}).enableGlobalPan;var e=this.group;return this._zr.add(e),e.attr({x:t.x||0,y:t.y||0,rotation:t.rotation||0,scaleX:t.scaleX||1,scaleY:t.scaleY||1}),this._transform=e.getLocalTransform(),this},kk.prototype.updateCovers=function(i){i=H(i,function(t){return O(P(Dk),t,!0)});var n="\0-brush-index-",o=this._covers,r=this._covers=[],a=this,s=this._creatingCover;return new Vx(o,i,function(t,e){return l(t.__brushOption,e)},l).add(t).update(t).remove(function(t){o[t]!==s&&a.group.remove(o[t])}).execute(),this;function l(t,e){return(null!=t.id?t.id:n+e)+"-"+t.brushType}function t(t,e){var n=i[t];null!=e&&o[e]===s?r[t]=o[e]:(n=r[t]=null!=e?(o[e].__brushOption=n,o[e]):Pk(a,Lk(a,n)),Nk(a,n))}},kk.prototype.unmount=function(){return this.enableBrush(!1),Bk(this),this._zr.remove(this.group),this},kk.prototype.dispose=function(){this.unmount(),this.off()},kk);function kk(t){var e=yk.call(this)||this;return e._track=[],e._covers=[],e._handlers={},e._zr=t,e.group=new ro,e._uid="brushController_"+Ak++,G(oL,function(t,e){this._handlers[e]=X(t,this)},e),e}function Lk(t,e){var n=aL[e.brushType].createCover(t,e);return n.__brushOption=e,Rk(n,e),t.group.add(n),n}function Pk(t,e){var n=zk(e);return n.endCreating&&(n.endCreating(t,e),Rk(e,e.__brushOption)),e}function Ok(t,e){var n=e.__brushOption;zk(e).updateCoverShape(t,e,n.range,n)}function Rk(t,e){var n=e.z;null==n&&(n=wk),t.traverse(function(t){t.z=n,t.z2=n})}function Nk(t,e){zk(e).updateCommon(t,e),Ok(t,e)}function zk(t){return aL[t.__brushOption.brushType]}function Ek(t,e,n){var i,o=t._panels;if(!o)return vk;var r=t._transform;return G(o,function(t){t.isTargetByCursor(e,n,r)&&(i=t)}),i}function Vk(t,e){t=t._panels;if(!t)return vk;e=e.__brushOption.panelId;return null!=e?t[e]:vk}function Bk(e){var t=e._covers,n=t.length;return G(t,function(t){e.group.remove(t)},e),t.length=0,n}function Fk(t,e){var n=H(t._covers,function(t){var e=t.__brushOption,t=P(e.range);return{brushType:e.brushType,panelId:e.panelId,range:t}});t.trigger("brush",{areas:n,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function Gk(t){var e=t.length-1;return[t[0],t[e=e<0?0:e]]}function Hk(e,n,t,i){var o=new ro;return o.add(new Ts({name:"main",style:Xk(t),silent:!0,draggable:!0,cursor:"move",drift:Z(qk,e,n,o,["n","s","w","e"]),ondragend:Z(Fk,n,{isEnd:!0})})),G(i,function(t){o.add(new Ts({name:t.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:Z(qk,e,n,o,t),ondragend:Z(Fk,n,{isEnd:!0})}))}),o}function Wk(t,e,n,i){var o=i.brushStyle.lineWidth||0,r=_k(o,Mk),a=n[0][0],s=n[1][0],l=a-o/2,u=s-o/2,h=n[0][1],c=n[1][1],p=h-r+o/2,d=c-r+o/2,n=h-a,h=c-s,c=n+o,o=h+o;Yk(t,e,"main",a,s,n,h),i.transformable&&(Yk(t,e,"w",l,u,r,o),Yk(t,e,"e",p,u,r,o),Yk(t,e,"n",l,u,c,r),Yk(t,e,"s",l,d,c,r),Yk(t,e,"nw",l,u,r,r),Yk(t,e,"ne",p,u,r,r),Yk(t,e,"sw",l,d,r,r),Yk(t,e,"se",p,d,r,r))}function Uk(n,i){var t=i.__brushOption,o=t.transformable,e=i.childAt(0);e.useStyle(Xk(t)),e.attr({silent:!o,cursor:o?"move":"default"}),G([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(t){var e=i.childOfName(t.join("")),t=1===t.length?jk(n,t[0]):function(t,e){e=[jk(t,e[0]),jk(t,e[1])];return"e"!==e[0]&&"w"!==e[0]||e.reverse(),e.join("")}(n,t);e&&e.attr({silent:!o,invisible:!o,cursor:o?Ck[t]+"-resize":null})})}function Yk(t,e,n,i,o,r,a){n=e.childOfName(n);n&&n.setShape((i=Qk(t,e,[[i,o],[i+r,o+a]]),r=xk(i[0][0],i[1][0]),o=xk(i[0][1],i[1][1]),a=_k(i[0][0],i[1][0]),i=_k(i[0][1],i[1][1]),{x:r,y:o,width:a-r,height:i-o}))}function Xk(t){return z({strokeNoScale:!0},t.brushStyle)}function Zk(t,e,n,i){var o=[xk(t,n),xk(e,i)],i=[_k(t,n),_k(e,i)];return[[o[0],i[0]],[o[1],i[1]]]}function jk(t,e){return{left:"w",right:"e",top:"n",bottom:"s"}[Zy({w:"left",e:"right",n:"top",s:"bottom"}[e],Yy(t.group))]}function qk(t,e,n,i,o,r){var a=n.__brushOption,s=t.toRectRange(a.range),l=Jk(e,o,r);G(i,function(t){t=Tk[t];s[t[0]][t[1]]+=l[t[0]]}),a.range=t.fromRectRange(Zk(s[0][0],s[1][0],s[0][1],s[1][1])),Nk(e,n),Fk(e,{isEnd:!1})}function Kk(t,e,n,i){var o=e.__brushOption.range,r=Jk(t,n,i);G(o,function(t){t[0]+=r[0],t[1]+=r[1]}),Nk(t,e),Fk(t,{isEnd:!1})}function Jk(t,e,n){t=t.group,n=t.transformCoordToLocal(e,n),t=t.transformCoordToLocal(0,0);return[n[0]-t[0],n[1]-t[1]]}function Qk(t,e,n){e=Vk(t,e);return e&&e!==vk?e.clipPath(n,t._transform):P(n)}function $k(t,e,n){if(t._brushType&&!function(t,e,n){t=t._zr;return e<0||e>t.getWidth()||n<0||n>t.getHeight()}(t,e.offsetX,e.offsetY)){var i=t._zr,o=t._covers,r=Ek(t,e,n);if(!t._dragging)for(var a=0;a<o.length;a++){var s=o[a].__brushOption;if(r&&(r===vk||s.panelId===r.panelId)&&aL[s.brushType].contain(o[a],n[0],n[1]))return}r&&i.setCursorStyle("crosshair")}}function tL(t){t=t.event;t.preventDefault&&t.preventDefault()}function eL(t,e,n){return t.childOfName("main").contain(e,n)}function nL(t,e,n,i){var o,r,a=t._creatingCover,s=t._creatingPanel,l=t._brushOption;return t._track.push(n.slice()),function(t){if((n=t._track).length){var e=n[n.length-1],t=n[0],n=e[0]-t[0],t=e[1]-t[1],t=bk(n*n+t*t,.5);return Sk<t}}(t)||a?(s&&!a&&("single"===l.brushMode&&Bk(t),(o=P(l)).brushType=iL(o.brushType,s),o.panelId=s===vk?null:s.panelId,a=t._creatingCover=Lk(t,o),t._covers.push(a)),a&&(r=aL[iL(t._brushType,s)],a.__brushOption.range=r.getCreatingRange(Qk(t,a,t._track)),i&&(Pk(t,a),r.updateCommon(t,a)),Ok(t,a),r={isEnd:i})):i&&"single"===l.brushMode&&l.removeOnClick&&Ek(t,e,n)&&Bk(t)&&(r={isEnd:i,removeOnClick:!0}),r}function iL(t,e){return"auto"===t?e.defaultBrushType:t}var oL={mousedown:function(t){var e;this._dragging?rL(this,t):t.target&&t.target.draggable||(tL(t),e=this.group.transformCoordToLocal(t.offsetX,t.offsetY),this._creatingCover=null,(this._creatingPanel=Ek(this,t,e))&&(this._dragging=!0,this._track=[e.slice()]))},mousemove:function(t){var e=t.offsetX,n=t.offsetY,n=this.group.transformCoordToLocal(e,n);$k(this,t,n),this._dragging&&(tL(t),(n=nL(this,t,n,!1))&&Fk(this,n))},mouseup:function(t){rL(this,t)}};function rL(t,e){var n,i;t._dragging&&(tL(e),n=e.offsetX,i=e.offsetY,i=t.group.transformCoordToLocal(n,i),i=nL(t,e,i,!0),t._dragging=!1,t._track=[],t._creatingCover=null,i&&Fk(t,i))}var aL={lineX:sL(0),lineY:sL(1),rect:{createCover:function(t,e){function n(t){return t}return Hk({toRectRange:n,fromRectRange:n},t,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(t){t=Gk(t);return Zk(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(t,e,n,i){Wk(t,e,n,i)},updateCommon:Uk,contain:eL},polygon:{createCover:function(t,e){var n=new ro;return n.add(new ny({name:"main",style:Xk(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new $g({name:"main",draggable:!0,drift:Z(Kk,t,e),ondragend:Z(Fk,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n,i){e.childAt(0).setShape({points:Qk(t,e,n)})},updateCommon:Uk,contain:eL}};function sL(a){return{createCover:function(t,e){return Hk({toRectRange:function(t){t=[t,[0,100]];return a&&t.reverse(),t},fromRectRange:function(t){return t[a]}},t,e,[[["w"],["e"]],[["n"],["s"]]][a])},getCreatingRange:function(t){t=Gk(t);return[xk(t[0][a],t[1][a]),_k(t[0][a],t[1][a])]},updateCoverShape:function(t,e,n,i){var o=Vk(t,e),r=[n,o!==vk&&o.getLinearBrushOtherExtent?o.getLinearBrushOtherExtent(a):[0,[(r=t._zr).getWidth(),r.getHeight()][1-a]]];a&&r.reverse(),Wk(t,e,r,i)},updateCommon:Uk,contain:eL}}var lL=gr;function uL(e){return e=pL(e),function(t){return Ky(t,e)}}function hL(n,i){return n=pL(n),function(t){var e=null!=i?i:t,t=e?n.width:n.height,e=e?n.x:n.y;return[e,e+(t||0)]}}function cL(t,n,i){var o=pL(t);return function(t,e){return o.contain(e[0],e[1])&&!$I(t,n,i)}}function pL(t){return ki.create(t)}var dL,fL=["axisLine","axisTickLabel","axisName"];function gL(){var t=null!==dL&&dL.apply(this,arguments)||this;return t.type=gL.type,t}var yL=(d(gL,dL=Wd),gL.prototype.init=function(t,e){dL.prototype.init.apply(this,arguments),(this._brushController=new lL(e.getZr())).on("brush",X(this._onBrush,this))},gL.prototype.render=function(t,e,n,i){var o,r,a,s;r=t,a=e,(s=i)&&"axisAreaSelect"===s.type&&a.findComponents({mainType:"parallelAxis",query:s})[0]===r||(this.axisModel=t,this.api=n,this.group.removeAll(),o=this._axisGroup,this._axisGroup=new ro,this.group.add(this._axisGroup),t.get("show")&&(a=(i=e.getComponent("parallel",t.get("parallelIndex"))).coordinateSystem,r=(s=t.getAreaSelectStyle()).width,e=t.axis.dim,a=N({strokeContainThreshold:r},a.getAxisLayout(e)),e=new HM(t,a),G(fL,e.add,e),this._axisGroup.add(e.getGroup()),this._refreshBrushController(a,s,t,i,r,n),qy(o,this._axisGroup,t)))},gL.prototype._refreshBrushController=function(t,e,n,i,o,r){var a,s=n.axis.getExtent(),l=s[1]-s[0],u=Math.min(30,.1*Math.abs(l)),o=ki.create({x:s[0],y:-o/2,width:l,height:o});o.x-=u,o.width+=2*u,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:uL(o),isTargetByCursor:cL(o,r,i),getLinearBrushOtherExtent:hL(o,0)}]).enableBrush({brushType:"lineX",brushStyle:e,removeOnClick:!0}).updateCovers((a=n.axis,H(n.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[a.dataToCoord(t[0],!0),a.dataToCoord(t[1],!0)]}})))},gL.prototype._onBrush=function(t){var e=t.areas,n=this.axisModel,i=n.axis,e=H(e,function(t){return[i.coordToData(t.range[0],!0),i.coordToData(t.range[1],!0)]});!n.option.realtime!==t.isEnd&&!t.removeOnClick||this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:e})},gL.prototype.dispose=function(){this._brushController.dispose()},gL.type="parallelAxis",gL),mL={type:"axisAreaSelect",event:"axisAreaSelected"};var vL={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function xL(t){t.registerComponentView(qA),t.registerComponentModel(KA),t.registerCoordinateSystem("parallel",fk),t.registerPreprocessor(HA),t.registerComponentModel(mk),t.registerComponentView(yL),hS(t,"parallel",mk,vL),(t=t).registerAction(mL,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(t){t.axis.model.setActiveIntervals(e.intervals)})}),t.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(t){t.setAxisExpand(e)})})}var _L,bL,wL=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0},SL=(d(IL,bL=as),IL.prototype.getDefaultShape=function(){return new wL},IL.prototype.buildPath=function(t,e){var n=e.extent;t.moveTo(e.x1,e.y1),t.bezierCurveTo(e.cpx1,e.cpy1,e.cpx2,e.cpy2,e.x2,e.y2),"vertical"===e.orient?(t.lineTo(e.x2+n,e.y2),t.bezierCurveTo(e.cpx2+n,e.cpy2,e.cpx1+n,e.cpy1,e.x1+n,e.y1)):(t.lineTo(e.x2,e.y2+n),t.bezierCurveTo(e.cpx2,e.cpy2+n,e.cpx1,e.cpy1+n,e.x1,e.y1+n)),t.closePath()},IL.prototype.highlight=function(){xl(this)},IL.prototype.downplay=function(){_l(this)},IL);function ML(){var t=null!==_L&&_L.apply(this,arguments)||this;return t.type=ML.type,t._focusAdjacencyDisabled=!1,t}function IL(t){return bL.call(this,t)||this}var TL,CL=(d(ML,_L=$d),ML.prototype.render=function(b,t,i){var e,n,o=this,r=b.getGraph(),w=this.group,a=b.layoutInfo,S=a.width,M=a.height,s=b.getData(),I=b.getData("edge"),T=b.get("orient");this._model=b,w.removeAll(),w.x=a.x,w.y=a.y,r.eachEdge(function(t){var e=new SL,n=Gs(e);n.dataIndex=t.dataIndex,n.seriesIndex=b.seriesIndex,n.dataType="edge";var i,o,r,a,s,l,u,h=t.getModel(),c=h.getModel("lineStyle"),p=c.get("curveness"),d=t.node1.getLayout(),f=t.node1.getModel(),g=f.get("localX"),y=f.get("localY"),m=t.node2.getLayout(),v=t.node2.getModel(),n=v.get("localX"),f=v.get("localY"),v=t.getLayout();switch(e.shape.extent=Math.max(1,v.dy),v="vertical"===(e.shape.orient=T)?(i=(null!=g?g*S:d.x)+v.sy,o=(null!=y?y*M:d.y)+d.dy,r=(null!=n?n*S:m.x)+v.ty,s=i,l=o*(1-p)+(a=null!=f?f*M:m.y)*p,u=r,o*p+a*(1-p)):(i=(null!=g?g*S:d.x)+d.dx,o=(null!=y?y*M:d.y)+v.sy,s=i*(1-p)+(r=null!=n?n*S:m.x)*p,l=o,u=i*p+r*(1-p),a=(null!=f?f*M:m.y)+v.ty),e.setShape({x1:i,y1:o,x2:r,y2:a,cpx1:s,cpy1:l,cpx2:u,cpy2:v}),e.useStyle(c.getItemStyle()),e.style.fill){case"source":e.style.fill=t.node1.getVisual("color"),e.style.decal=t.node1.getVisual("style").decal;break;case"target":e.style.fill=t.node2.getVisual("color"),e.style.decal=t.node2.getVisual("style").decal;break;case"gradient":var x=t.node1.getVisual("color"),_=t.node2.getVisual("color");"string"==typeof x&&"string"==typeof _&&(e.style.fill=new fy(0,0,+("horizontal"===T),+("vertical"===T),[{color:x,offset:0},{color:_,offset:1}]))}c=h.getModel("emphasis");Nl(e,h,"lineStyle",function(t){return t.getItemStyle()}),w.add(e),I.setItemGraphicEl(t.dataIndex,e);h=c.get("focus");Ll(e,"adjacency"===h?t.getAdjacentDataIndices():h,c.get("blurScope")),Gs(e).dataType="edge"}),r.eachNode(function(t){var e=t.getLayout(),n=t.getModel(),i=n.get("localX"),o=n.get("localY"),r=n.getModel("emphasis"),e=new Ts({shape:{x:null!=i?i*S:e.x,y:null!=o?o*M:e.y,width:e.dx,height:e.dy},style:n.getModel("itemStyle").getItemStyle(),z2:10});$l(e,tu(n),{labelFetcher:b,labelDataIndex:t.dataIndex,defaultText:t.id}),e.disableLabelAnimation=!0,e.setStyle("fill",t.getVisual("color")),e.setStyle("decal",t.getVisual("style").decal),Nl(e,n),w.add(e),s.setItemGraphicEl(t.dataIndex,e),Gs(e).dataType="node";n=r.get("focus");Ll(e,"adjacency"===n?t.getAdjacentDataIndices():n,r.get("blurScope"))}),s.eachItemGraphicEl(function(t,n){s.getItemModel(n).get("draggable")&&(t.drift=function(t,e){o._focusAdjacencyDisabled=!0,this.shape.x+=t,this.shape.y+=e,this.dirty(),i.dispatchAction({type:"dragNode",seriesId:b.id,dataIndex:s.getRawIndex(n),localX:this.shape.x/S,localY:this.shape.y/M})},t.ondragend=function(){o._focusAdjacencyDisabled=!1},t.draggable=!0,t.cursor="move")}),!this._data&&b.isAnimationEnabled()&&w.setClipPath((e=w.getBoundingRect(),n=b,a=function(){w.removeClipPath()},Ul(r=new Ts({shape:{x:e.x-10,y:e.y-10,width:0,height:e.height+20}}),{shape:{width:e.width+20}},n,a),r)),this._data=b.getData()},ML.prototype.dispose=function(){},ML.type="sankey",ML),DL=(d(AL,TL=Gd),AL.prototype.getInitialData=function(t,e){var n=t.edges||t.links,i=t.data||t.nodes,o=t.levels;this.levelModels=[];for(var r=this.levelModels,a=0;a<o.length;a++)null!=o[a].depth&&0<=o[a].depth&&(r[o[a].depth]=new wu(o[a],this,e));if(i&&n)return eA(i,n,this,!0,function(t,e){t.wrapMethod("getItemModel",function(t,e){var n=t.parentModel,e=n.getData().getItemLayout(e);return e&&(e=e.depth,(e=n.levelModels[e])&&(t.parentModel=e)),t}),e.wrapMethod("getItemModel",function(t,e){var n=t.parentModel,e=n.getGraph().getEdgeByIndex(e).node1.getLayout();return e&&(e=e.depth,(e=n.levelModels[e])&&(t.parentModel=e)),t})}).data},AL.prototype.setNodePosition=function(t,e){t=(this.option.data||this.option.nodes)[t];t.localX=e[0],t.localY=e[1]},AL.prototype.getGraph=function(){return this.getData().graph},AL.prototype.getEdgeData=function(){return this.getGraph().edgeData},AL.prototype.formatTooltip=function(t,e,n){function i(t){return isNaN(t)||null==t}if("edge"===n){var o=this.getDataParams(t,n),r=o.data,o=o.value;return md("nameValue",{name:r.source+" -- "+r.target,value:o,noValue:i(o)})}o=this.getGraph().getNodeByIndex(t).getLayout().value,n=this.getDataParams(t,n).data.name;return md("nameValue",{name:null!=n?n+"":null,value:o,noValue:i(o)})},AL.prototype.optionUpdated=function(){},AL.prototype.getDataParams=function(t,e){var n=TL.prototype.getDataParams.call(this,t,e);return null==n.value&&"node"===e&&(t=this.getGraph().getNodeByIndex(t).getLayout().value,n.value=t),n},AL.type="series.sankey",AL.defaultOption={zlevel:0,z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},AL);function AL(){var t=null!==TL&&TL.apply(this,arguments)||this;return t.type=AL.type,t}function kL(t,u){t.eachSeriesByType("sankey",function(t){var e=t.get("nodeWidth"),n=t.get("nodeGap"),i=(l=u,Sh(t.getBoxLayoutParams(),{width:l.getWidth(),height:l.getHeight()})),o=(t.layoutInfo=i).width,r=i.height,a=t.getGraph(),s=a.nodes,l=a.edges;G(s,function(t){var e=BL(t.outEdges,VL),n=BL(t.inEdges,VL),i=t.getValue()||0,i=Math.max(e,n,i);t.setLayout({value:i},!0)});var i=0!==U(s,function(t){return 0===t.getLayout().value}).length?0:t.get("layoutIterations"),a=t.get("orient"),t=t.get("nodeAlign");n=n,i=i,function(t,e,n,i,o,r,a){for(var s=[],l=[],u=[],h=[],c=0,p=0;p<e.length;p++)s[p]=1;for(p=0;p<t.length;p++)l[p]=t[p].inEdges.length,0===l[p]&&u.push(t[p]);var d=-1;for(;u.length;){for(var f=0;f<u.length;f++){var g=u[f],y=g.hostGraph.data.getRawDataItem(g.dataIndex),m=null!=y.depth&&0<=y.depth;m&&y.depth>d&&(d=y.depth),g.setLayout({depth:m?y.depth:c},!0),"vertical"===r?g.setLayout({dy:n},!0):g.setLayout({dx:n},!0);for(var v=0;v<g.outEdges.length;v++){var x=g.outEdges[v],_=e.indexOf(x);s[_]=0;_=x.node2,x=t.indexOf(_);0==--l[x]&&h.indexOf(_)<0&&h.push(_)}}++c,u=h,h=[]}for(p=0;p<s.length;p++)if(1===s[p])throw new Error("Sankey is a DAG, the original data has cycle!");var b=c-1<d?d:c-1;a&&"left"!==a&&function(t,e,n){if("right"===e){for(var i=[],o=t,r=0;o.length;){for(var a=0;a<o.length;a++){var s=o[a];s.setLayout({skNodeHeight:r},!0);for(var l=0;l<s.inEdges.length;l++){var u=s.inEdges[l];i.indexOf(u.node1)<0&&i.push(u.node1)}}o=i,i=[],++r}G(t,function(t){LL(t)||t.setLayout({depth:Math.max(0,n-t.getLayout().skNodeHeight)},!0)})}else"justify"===e&&function(t,e){G(t,function(t){LL(t)||t.outEdges.length||t.setLayout({depth:e},!0)})}(t,n)}(t,a,b),function(t,n,i){G(t,function(t){var e=t.getLayout().depth*n;"vertical"===i?t.setLayout({y:e},!0):t.setLayout({x:e},!0)})}(t,"vertical"===r?(o-n)/b:(i-n)/b,r)}(s=s,l=l,e,o=o,r=r,a=a,t),function(t,e,n,i,o,r,a){var s=function(t,e){var n=[],i="vertical"===e?"y":"x",o=er(t,function(t){return t.getLayout()[i]});return o.keys.sort(function(t,e){return t-e}),G(o.keys,function(t){n.push(o.buckets.get(t))}),n}(t,a);(function(t,e,i,o,r,a){var s=1/0;G(t,function(t){var e=t.length,n=0;G(t,function(t){n+=t.getLayout().value});e="vertical"===a?(o-(e-1)*r)/n:(i-(e-1)*r)/n;e<s&&(s=e)}),G(t,function(t){G(t,function(t,e){var n=t.getLayout().value*s;"vertical"===a?(t.setLayout({x:e},!0),t.setLayout({dx:n},!0)):(t.setLayout({y:e},!0),t.setLayout({dy:n},!0))})}),G(e,function(t){var e=+t.getValue()*s;t.setLayout({dy:e},!0)})})(s,e,n,i,o,a),PL(s,o,n,i,a);for(var l=1;0<r;r--)(function(t,i,o){G(t.slice().reverse(),function(t){G(t,function(t){var e,n;t.outEdges.length&&(n=BL(t.outEdges,OL,o)/BL(t.outEdges,VL),isNaN(n)&&(n=(e=t.outEdges.length)?BL(t.outEdges,RL,o)/e:0),"vertical"===o?(e=t.getLayout().x+(n-EL(t,o))*i,t.setLayout({x:e},!0)):(n=t.getLayout().y+(n-EL(t,o))*i,t.setLayout({y:n},!0)))})})})(s,l*=.99,a),PL(s,o,n,i,a),function(t,i,o){G(t,function(t){G(t,function(t){var e,n;t.inEdges.length&&(n=BL(t.inEdges,NL,o)/BL(t.inEdges,VL),isNaN(n)&&(n=(e=t.inEdges.length)?BL(t.inEdges,zL,o)/e:0),"vertical"===o?(e=t.getLayout().x+(n-EL(t,o))*i,t.setLayout({x:e},!0)):(n=t.getLayout().y+(n-EL(t,o))*i,t.setLayout({y:n},!0)))})})}(s,l,a),PL(s,o,n,i,a)}(s,l,r,o,n,i,a),function(t,e){var n="vertical"===e?"x":"y";G(t,function(t){t.outEdges.sort(function(t,e){return t.node2.getLayout()[n]-e.node2.getLayout()[n]}),t.inEdges.sort(function(t,e){return t.node1.getLayout()[n]-e.node1.getLayout()[n]})}),G(t,function(t){var e=0,n=0;G(t.outEdges,function(t){t.setLayout({sy:e},!0),e+=t.getLayout().dy}),G(t.inEdges,function(t){t.setLayout({ty:n},!0),n+=t.getLayout().dy})})}(s,a)})}function LL(t){t=t.hostGraph.data.getRawDataItem(t.dataIndex);return null!=t.depth&&0<=t.depth}function PL(t,l,u,h,c){var p="vertical"===c?"x":"y";G(t,function(t){var e,n;t.sort(function(t,e){return t.getLayout()[p]-e.getLayout()[p]});for(var i,o=0,r=t.length,a="vertical"===c?"dx":"dy",s=0;s<r;s++)0<(i=o-(n=t[s]).getLayout()[p])&&(e=n.getLayout()[p]+i,"vertical"===c?n.setLayout({x:e},!0):n.setLayout({y:e},!0)),o=n.getLayout()[p]+n.getLayout()[a]+l;if(0<(i=o-l-("vertical"===c?h:u)))for(e=n.getLayout()[p]-i,"vertical"===c?n.setLayout({x:e},!0):n.setLayout({y:e},!0),o=e,s=r-2;0<=s;--s)0<(i=(n=t[s]).getLayout()[p]+n.getLayout()[a]+l-o)&&(e=n.getLayout()[p]-i,"vertical"===c?n.setLayout({x:e},!0):n.setLayout({y:e},!0)),o=n.getLayout()[p]})}function OL(t,e){return EL(t.node2,e)*t.getValue()}function RL(t,e){return EL(t.node2,e)}function NL(t,e){return EL(t.node1,e)*t.getValue()}function zL(t,e){return EL(t.node1,e)}function EL(t,e){return"vertical"===e?t.getLayout().x+t.getLayout().dx/2:t.getLayout().y+t.getLayout().dy/2}function VL(t){return t.getValue()}function BL(t,e,n){for(var i=0,o=t.length,r=-1;++r<o;){var a=+e(t[r],n);isNaN(a)||(i+=a)}return i}function FL(t){t.eachSeriesByType("sankey",function(i){var o,r,t=i.getGraph().nodes;t.length&&(o=1/0,r=-1/0,G(t,function(t){t=t.getLayout().value;t<o&&(o=t),r<t&&(r=t)}),G(t,function(t){var e=new vC({type:"color",mappingMethod:"linear",dataExtent:[o,r],visual:i.get("color")}).mapValueToVisual(t.getLayout().value),n=t.getModel().get(["itemStyle","color"]);null!=n?(t.setVisual("color",n),t.setVisual("style",{fill:n})):(t.setVisual("color",e),t.setVisual("style",{fill:e}))}))})}var GL,C=(WL.prototype.getInitialData=function(t,e){var n,i,o=e.getComponent("xAxis",this.get("xAxisIndex")),r=e.getComponent("yAxis",this.get("yAxisIndex")),a=o.get("type"),s=r.get("type");"category"===a?(t.layout="horizontal",n=o.getOrdinalMeta(),i=!0):"category"===s?(t.layout="vertical",n=r.getOrdinalMeta(),i=!0):t.layout=t.layout||"horizontal";var l,e=["x","y"],a="horizontal"===t.layout?0:1,s=this._baseAxisDim=e[a],e=e[1-a],o=[o,r],r=o[a].get("type"),o=o[1-a].get("type"),a=t.data;a&&i&&(l=[],G(a,function(t,e){var n;j(t)?(n=t.slice(),t.unshift(e)):j(t.value)?((n=N({},t)).value=n.value.slice(),t.value.unshift(e)):n=t,l.push(n)}),t.data=l);t=this.defaultValueDimensions,o=[{name:s,type:Ux(r),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:e,type:Ux(o),dimsDef:t.slice()}];return Pw(this,{coordDimensions:o,dimensionsCount:t.length+1,encodeDefaulter:Z(Jh,o,this)})},WL.prototype.getBaseAxis=function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis},WL),mu=(d(HL,GL=Gd),HL.type="series.boxplot",HL.dependencies=["xAxis","yAxis","grid"],HL.defaultOption={zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},HL);function HL(){var t=null!==GL&&GL.apply(this,arguments)||this;return t.type=HL.type,t.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],t.visualDrawType="stroke",t}function WL(){}B(mu,C,!0);var UL,YL,XL=mu,Jn=(d(KL,YL=$d),KL.prototype.render=function(t,e,n){var i=t.getData(),o=this.group,r=this._data;this._data||o.removeAll();var a="horizontal"===t.get("layout")?1:0;i.diff(r).add(function(t){var e;i.hasValue(t)&&(e=JL(i.getItemLayout(t),i,t,a,!0),i.setItemGraphicEl(t,e),o.add(e))}).update(function(t,e){var n=r.getItemGraphicEl(e);i.hasValue(t)?(e=i.getItemLayout(t),n?(ql(n),QL(e,n,i,t)):n=JL(e,i,t,a),o.add(n),i.setItemGraphicEl(t,n)):o.remove(n)}).remove(function(t){t=r.getItemGraphicEl(t);t&&o.remove(t)}).execute(),this._data=i},KL.prototype.remove=function(t){var e=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(t){t&&e.remove(t)})},KL.type="boxplot",KL),ZL=function(){},jL=(d(qL,UL=as),qL.prototype.getDefaultShape=function(){return new ZL},qL.prototype.buildPath=function(t,e){var n=e.points,i=0;for(t.moveTo(n[i][0],n[i][1]),i++;i<4;i++)t.lineTo(n[i][0],n[i][1]);for(t.closePath();i<n.length;i++)t.moveTo(n[i][0],n[i][1]),t.lineTo(n[++i][0],n[i][1])},qL);function qL(t){t=UL.call(this,t)||this;return t.type="boxplotBoxPath",t}function KL(){var t=null!==YL&&YL.apply(this,arguments)||this;return t.type=KL.type,t}function JL(t,e,n,i,o){var r,a,s=t.ends,s=new jL({shape:{points:o?(r=i,a=t,H(s,function(t){return(t=t.slice())[r]=a.initBaseline,t})):s}});return QL(t,s,e,n,o),s}function QL(t,e,n,i,o){var r=n.hostModel;(0,p[o?"initProps":"updateProps"])(e,{shape:{points:t.ends}},r,i),e.useStyle(n.getItemVisual(i,"style")),e.style.strokeNoScale=!0,e.z2=100;i=n.getItemModel(i);Nl(e,i),Ll(e,i.get(["emphasis","focus"]),i.get(["emphasis","blurScope"]))}var $L=Jn;function tP(t,e){}var eP=G;function nP(t){var i,o,t=(i=[],o=[],t.eachSeriesByType("boxplot",function(t){var e=t.getBaseAxis(),n=V(o,e);n<0&&(n=o.length,o[n]=e,i[n]={axis:e,seriesModels:[]}),i[n].seriesModels.push(t)}),i);eP(t,function(n){var t=n.seriesModels;t.length&&(function(t){var e,n=t.axis,i=t.seriesModels,o=i.length,r=t.boxWidthList=[],a=t.boxOffsetList=[],s=[];{var l;"category"===n.type?e=n.getBandWidth():(l=0,eP(i,function(t){l=Math.max(l,t.getData().count())}),u=n.getExtent(),Math.abs(u[1]-u[0]))}eP(i,function(t){t=t.get("boxWidth");j(t)||(t=[t,t]),s.push([go(t[0],e)||0,go(t[1],e)||0])});var u=.8*e-2,h=u/o*.3,c=(u-h*(o-1))/o,p=c/2-u/2;eP(i,function(t,e){a.push(p),p+=h+c,r.push(Math.min(Math.max(c,s[e][0]),s[e][1]))})}(n),eP(t,function(t,e){!function(t,o,e){var r=t.coordinateSystem,a=t.getData(),s=e/2,l="horizontal"===t.get("layout")?0:1,u=1-l,t=["x","y"],n=a.mapDimension(t[l]),i=a.mapDimensionsAll(t[u]);if(!(null==n||i.length<5))for(var h=0;h<a.count();h++){var c=a.get(n,h),p=m(c,i[2],h),d=m(c,i[0],h),f=m(c,i[1],h),g=m(c,i[3],h),y=m(c,i[4],h),c=[];v(c,f,!1),v(c,g,!0),c.push(d,f,y,g),x(c,d),x(c,y),x(c,p),a.setItemLayout(h,{initBaseline:p[u],ends:c})}function m(t,e,n){var i,e=a.get(e,n),n=[];return n[l]=t,n[u]=e,isNaN(t)||isNaN(e)?i=[NaN,NaN]:(i=r.dataToPoint(n))[l]+=o,i}function v(t,e,n){var i=e.slice(),e=e.slice();i[l]+=s,e[l]-=s,n?t.push(i,e):t.push(e,i)}function x(t,e){var n=e.slice(),e=e.slice();n[l]-=s,e[l]+=s,t.push(n,e)}}(t,n.boxOffsetList[e],n.boxWidthList[e])}))})}var iP={type:"echarts:boxplot",transform:function(t){var e=t.upstream;e.sourceFormat!==Hh&&pc("");t=function(t,e){for(var n=[],i=[],o=(e=e||{}).boundIQR,r="none"===o||0===o,a=0;a<t.length;a++){var s=mo(t[a].slice()),l=Co(s,.25),u=Co(s,.5),h=Co(s,.75),c=s[0],p=s[s.length-1],d=(null==o?1.5:o)*(h-l),f=r?c:Math.max(c,l-d),g=r?p:Math.min(p,h+d),d=e.itemNameFormatter,y=q(d)?d({value:a}):K(d)?d.replace("{value}",a+""):a+"";n.push([y,f,l,u,h,g]);for(var m=0;m<s.length;m++){var v=s[m];(v<f||g<v)&&i.push([y,v])}}return{boxData:n,outliers:i}}(e.getRawData(),t.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:t.boxData},{data:t.outliers}]}};var oP,rP,aP=["color","borderColor"],gr=(d(hP,rP=$d),hP.prototype.render=function(t,e,n){this.group.removeClipPath(),this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},hP.prototype.incrementalPrepareRender=function(t,e,n){this._clear(),this._updateDrawMode(t)},hP.prototype.incrementalRender=function(t,e,n,i){this._isLargeDraw?this._incrementalRenderLarge(t,e):this._incrementalRenderNormal(t,e)},hP.prototype._updateDrawMode=function(t){t=t.pipelineContext.large;null!=this._isLargeDraw&&t===this._isLargeDraw||(this._isLargeDraw=t,this._clear())},hP.prototype._renderNormal=function(i){var o=i.getData(),r=this._data,a=this.group,s=o.getLayout("isSimpleBox"),l=i.get("clip",!0),t=i.coordinateSystem,u=t.getArea&&t.getArea();this._data||a.removeAll(),o.diff(r).add(function(t){var e,n;o.hasValue(t)&&(e=o.getItemLayout(t),l&&pP(u,e)||(Ul(n=cP(e,0,!0),{shape:{points:e.ends}},i,t),dP(n,o,t,s),a.add(n),o.setItemGraphicEl(t,n)))}).update(function(t,e){var n=r.getItemGraphicEl(e);o.hasValue(t)?(e=o.getItemLayout(t),l&&pP(u,e)?a.remove(n):(n?(Wl(n,{shape:{points:e.ends}},i,t),ql(n)):n=cP(e),dP(n,o,t,s),a.add(n),o.setItemGraphicEl(t,n))):a.remove(n)}).remove(function(t){t=r.getItemGraphicEl(t);t&&a.remove(t)}).execute(),this._data=o},hP.prototype._renderLarge=function(t){this._clear(),vP(t,this.group);t=t.get("clip",!0)?nb(t.coordinateSystem,!1,t):null;t?this.group.setClipPath(t):this.group.removeClipPath()},hP.prototype._incrementalRenderNormal=function(t,e){for(var n,i=e.getData(),o=i.getLayout("isSimpleBox");null!=(n=t.next());){var r=cP(i.getItemLayout(n));dP(r,i,n,o),r.incremental=!0,this.group.add(r)}},hP.prototype._incrementalRenderLarge=function(t,e){vP(e,this.group,!0)},hP.prototype.remove=function(t){this._clear()},hP.prototype._clear=function(){this.group.removeAll(),this._data=null},hP.type="candlestick",hP),sP=function(){},lP=(d(uP,oP=as),uP.prototype.getDefaultShape=function(){return new sP},uP.prototype.buildPath=function(t,e){e=e.points;this.__simpleBox?(t.moveTo(e[4][0],e[4][1]),t.lineTo(e[6][0],e[6][1])):(t.moveTo(e[0][0],e[0][1]),t.lineTo(e[1][0],e[1][1]),t.lineTo(e[2][0],e[2][1]),t.lineTo(e[3][0],e[3][1]),t.closePath(),t.moveTo(e[4][0],e[4][1]),t.lineTo(e[5][0],e[5][1]),t.moveTo(e[6][0],e[6][1]),t.lineTo(e[7][0],e[7][1]))},uP);function uP(t){t=oP.call(this,t)||this;return t.type="normalCandlestickBox",t}function hP(){var t=null!==rP&&rP.apply(this,arguments)||this;return t.type=hP.type,t}function cP(t,e,n){var i,o=t.ends;return new lP({shape:{points:n?(i=t,H(o,function(t){return(t=t.slice())[1]=i.initBaseline,t})):o},z2:100})}function pP(t,e){for(var n=!0,i=0;i<e.ends.length;i++)if(t.contain(e.ends[i][0],e.ends[i][1])){n=!1;break}return n}function dP(t,e,n,i){var o=e.getItemModel(n);t.useStyle(e.getItemVisual(n,"style")),t.style.strokeNoScale=!0,t.__simpleBox=i,Nl(t,o)}var fP,gP=function(){},yP=(d(mP,fP=as),mP.prototype.getDefaultShape=function(){return new gP},mP.prototype.buildPath=function(t,e){for(var n,i=e.points,o=0;o<i.length;)this.__sign===i[o++]?(n=i[o++],t.moveTo(n,i[o++]),t.lineTo(n,i[o++])):o+=3},mP);function mP(t){t=fP.call(this,t)||this;return t.type="largeCandlestickBox",t}function vP(t,e,n){var i=t.getData(),o=i.getLayout("largePoints"),r=new yP({shape:{points:o},__sign:1});e.add(r);o=new yP({shape:{points:o},__sign:-1});e.add(o),xP(1,r,t),xP(-1,o,t),n&&(r.incremental=!0,o.incremental=!0)}function xP(t,e,n){t=n.get(["itemStyle",0<t?"borderColor":"borderColor0"])||n.get(["itemStyle",0<t?"color":"color0"]),n=n.getModel("itemStyle").getItemStyle(aP);e.useStyle(n),e.style.fill=null,e.style.stroke=t}var _P,bP=gr,mu=(d(wP,_P=Gd),wP.prototype.getShadowDim=function(){return"open"},wP.prototype.brushSelector=function(t,e,n){t=e.getItemLayout(t);return t&&n.rect(t.brushRect)},wP.type="series.candlestick",wP.dependencies=["xAxis","yAxis","grid"],wP.defaultOption={zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},wP);function wP(){var t=null!==_P&&_P.apply(this,arguments)||this;return t.type=wP.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}B(mu,C,!0);var SP=mu;function MP(t){t&&j(t.series)&&G(t.series,function(t){$(t)&&"k"===t.type&&(t.type="candlestick")})}var IP=["itemStyle","borderColor"],TP=["itemStyle","borderColor0"],CP=["itemStyle","color"],DP=["itemStyle","color0"],AP={seriesType:"candlestick",plan:Ud(),performRawSeries:!0,reset:function(t,e){if(!e.isSeriesFiltered(t))return!t.pipelineContext.large&&{progress:function(t,e){for(var n;null!=(n=t.next());){var i=e.getItemModel(n),o=e.getItemLayout(n).sign,r=i.getItemStyle();r.fill=i.get(0<o?CP:DP),r.stroke=i.get(0<o?IP:TP)||r.fill,N(e.ensureUniqueItemVisual(n,"style"),r)}}}}},kP="undefined"!=typeof Float32Array?Float32Array:Array;function LP(t,e,n,i,o){return!(i<n)&&(n<i||!(0<e)||t.get(o,e-1)<=i)?1:-1}var PP={seriesType:"candlestick",plan:Ud(),reset:function(t){var e,n,i,m=t.coordinateSystem,o=t.getData(),v=(r=o,n="category"===(n=(e=t).getBaseAxis()).type?n.getBandWidth():(i=n.getExtent(),Math.abs(i[1]-i[0])/r.count()),i=go(rt(e.get("barMaxWidth"),n),n),r=go(rt(e.get("barMinWidth"),1),n),null!=(e=e.get("barWidth"))?go(e,n):Math.max(Math.min(n/2,i),r)),r=["x","y"],x=o.getDimensionIndex(o.mapDimension(r[0])),r=H(o.mapDimensionsAll(r[1]),o.getDimensionIndex,o),_=r[0],b=r[1],w=r[2],S=r[3];if(o.setLayout({candleWidth:v,isSimpleBox:v<=1.3}),!(x<0||r.length<4))return{progress:t.pipelineContext.large?function(t,e){var n,i=new kP(4*t.count),o=0,r=[],a=[],s=e.getStore();for(;null!=(n=t.next());){var l=s.get(x,n),u=s.get(_,n),h=s.get(b,n),c=s.get(w,n),p=s.get(S,n);isNaN(l)||isNaN(c)||isNaN(p)?(i[o++]=NaN,o+=3):(i[o++]=LP(s,n,u,h,b),r[0]=l,r[1]=c,c=m.dataToPoint(r,null,a),i[o++]=c?c[0]:NaN,i[o++]=c?c[1]:NaN,r[1]=p,c=m.dataToPoint(r,null,a),i[o++]=c?c[1]:NaN)}e.setLayout("largePoints",i)}:function(t,e){var n,i=e.getStore();for(;null!=(n=t.next());){var o=i.get(x,n),r=i.get(_,n),a=i.get(b,n),s=i.get(w,n),l=i.get(S,n),u=Math.min(r,a),h=Math.max(r,a),c=f(u,o),p=f(h,o),d=f(s,o),u=f(l,o),h=[];g(h,p,0),g(h,c,1),h.push(y(u),y(p),y(d),y(c)),e.setItemLayout(n,{sign:LP(i,n,r,a,b),initBaseline:(a<r?p:c)[1],ends:h,brushRect:function(t,e,n){t=f(t,n),n=f(e,n);return t[0]-=v/2,n[0]-=v/2,{x:t[0],y:t[1],width:v,height:n[1]-t[1]}}(s,l,o)})}function f(t,e){var n=[];return n[0]=e,n[1]=t,isNaN(e)||isNaN(t)?[NaN,NaN]:m.dataToPoint(n)}function g(t,e,n){var i=e.slice(),e=e.slice();i[0]=Uy(i[0]+v/2,1,!1),e[0]=Uy(e[0]-v/2,1,!0),n?t.push(i,e):t.push(e,i)}function y(t){return t[0]=Uy(t[0],1),t}}}}};function OP(t,e){var n=e.rippleEffectColor||e.color;t.eachChild(function(t){t.attr({z:e.z,zlevel:e.zlevel,style:{stroke:"stroke"===e.brushType?n:null,fill:"fill"===e.brushType?n:null}})})}var RP,NP,zP,EP=(d(HP,zP=ro),HP.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},HP.prototype.startEffectAnimation=function(t){for(var e=t.symbolType,n=t.color,i=t.rippleNumber,o=this.childAt(1),r=0;r<i;r++){var a=am(e,-1,-1,2,2,n);a.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var s=-r/i*t.period+t.effectOffset;a.animate("",!0).when(t.period,{scaleX:t.rippleScale/2,scaleY:t.rippleScale/2}).delay(s).start(),a.animateStyle(!0).when(t.period,{opacity:0}).delay(s).start(),o.add(a)}OP(o,t)},HP.prototype.updateEffectAnimation=function(t){for(var e=this._effectCfg,n=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var r=i[o];if(e[r]!==t[r])return this.stopEffectAnimation(),void this.startEffectAnimation(t)}OP(n,t)},HP.prototype.highlight=function(){xl(this)},HP.prototype.downplay=function(){_l(this)},HP.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},HP.prototype.updateData=function(t,e){var n=this,i=t.hostModel;this.childAt(0).updateData(t,e);var o=this.childAt(1),r=t.getItemModel(e),a=t.getItemVisual(e,"symbol"),s=sm(t.getItemVisual(e,"symbolSize")),l=t.getItemVisual(e,"style"),u=l&&l.fill;o.setScale(s),o.traverse(function(t){t.setStyle("fill",u)});s=lm(t.getItemVisual(e,"symbolOffset"),s);s&&(o.x=s[0],o.y=s[1]);s=t.getItemVisual(e,"symbolRotate");o.rotation=(s||0)*Math.PI/180||0;var h={};h.showEffectOn=i.get("showEffectOn"),h.rippleScale=r.get(["rippleEffect","scale"]),h.brushType=r.get(["rippleEffect","brushType"]),h.period=1e3*r.get(["rippleEffect","period"]),h.effectOffset=e/t.count(),h.z=i.getShallow("z")||0,h.zlevel=i.getShallow("zlevel")||0,h.symbolType=a,h.color=u,h.rippleEffectColor=r.get(["rippleEffect","color"]),h.rippleNumber=r.get(["rippleEffect","number"]),this.off("mouseover").off("mouseout").off("emphasis").off("normal"),"render"===h.showEffectOn?(this._effectCfg?this.updateEffectAnimation(h):this.startEffectAnimation(h),this._effectCfg=h):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(t){"emphasis"===t?"render"!==h.showEffectOn&&n.startEffectAnimation(h):"normal"===t&&"render"!==h.showEffectOn&&n.stopEffectAnimation()}),this._effectCfg=h,Ll(this)},HP.prototype.fadeOut=function(t){this.off("mouseover").off("mouseout"),t&&t()},HP),VP=(d(GP,NP=$d),GP.prototype.init=function(){this._symbolDraw=new O_(EP)},GP.prototype.render=function(t,e,n){var i=t.getData(),o=this._symbolDraw;o.updateData(i,{clipShape:this._getClipShape(t)}),this.group.add(o.group)},GP.prototype._getClipShape=function(t){var e=t.coordinateSystem,e=e&&e.getArea&&e.getArea();return t.get("clip",!0)?e:null},GP.prototype.updateTransform=function(t,e,n){var i=t.getData();this.group.dirty();n=vb("").reset(t,e,n);n.progress&&n.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},GP.prototype._updateGroupTransform=function(t){var e=t.coordinateSystem;e&&e.getRoamTransform&&(this.group.transform=(t=e.getRoamTransform(),oi(e=ni(),t),e),this.group.decomposeTransform())},GP.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0)},GP.type="effectScatter",GP),BP=(d(FP,RP=Gd),FP.prototype.getInitialData=function(t,e){return w_(null,this,{useEncodeDefaulter:!0})},FP.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},FP.type="series.effectScatter",FP.dependencies=["grid","polar"],FP.defaultOption={coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},FP);function FP(){var t=null!==RP&&RP.apply(this,arguments)||this;return t.type=FP.type,t.hasSymbolVisual=!0,t}function GP(){var t=null!==NP&&NP.apply(this,arguments)||this;return t.type=GP.type,t}function HP(t,e){var n=zP.call(this)||this,i=new A_(t,e),o=new ro;return n.add(i),n.add(o),n.updateData(t,e),n}var WP,UP,YP,XP,ZP,jP=(d(uO,ZP=ro),uO.prototype.createLine=function(t,e,n){return new DD(t,e,n)},uO.prototype._updateEffectSymbol=function(t,e){var n=t.getItemModel(e).getModel("effect"),i=n.get("symbolSize"),o=n.get("symbol");j(i)||(i=[i,i]);var r=t.getItemVisual(e,"style"),a=n.get("color")||r&&r.stroke,r=this.childAt(1);this._symbolType!==o&&(this.remove(r),(r=am(o,-.5,-.5,1,1,a)).z2=100,r.culling=!0,this.add(r)),r&&(r.setStyle("shadowColor",a),r.setStyle(n.getItemStyle(["color"])),r.scaleX=i[0],r.scaleY=i[1],r.setColor(a),this._symbolType=o,this._symbolScale=i,this._updateEffectAnimation(t,n,e))},uO.prototype._updateEffectAnimation=function(e,t,n){var i,o,r,a,s,l=this.childAt(1);l&&(i=this,o=e.getItemLayout(n),r=1e3*t.get("period"),a=t.get("loop"),s=t.get("constantSpeed"),t=ot(t.get("delay"),function(t){return t/e.count()*r/3}),l.ignore=!0,this._updateAnimationPoints(l,o),((r=0<s?this._getLineLength(l)/s*1e3:r)!==this._period||a!==this._loop)&&(l.stopAnimation(),0<r)&&(s=void 0,s="function"==typeof t?t(n):t,0<l.__t&&(s=-r*l.__t),l.__t=0,s=l.animate("",a).when(r,{__t:1}).delay(s).during(function(){i._updateSymbolPosition(l)}),a||s.done(function(){i.remove(l)}),s.start()),this._period=r,this._loop=a)},uO.prototype._getLineLength=function(t){return Ot(t.__p1,t.__cp1)+Ot(t.__cp1,t.__p2)},uO.prototype._updateAnimationPoints=function(t,e){t.__p1=e[0],t.__p2=e[1],t.__cp1=e[2]||[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]},uO.prototype.updateData=function(t,e,n){this.childAt(0).updateData(t,e,n),this._updateEffectSymbol(t,e)},uO.prototype._updateSymbolPosition=function(t){var e=t.__p1,n=t.__p2,i=t.__cp1,o=t.__t,r=[t.x,t.y],a=r.slice(),s=ia,l=oa;r[0]=s(e[0],i[0],n[0],o),r[1]=s(e[1],i[1],n[1],o);s=l(e[0],i[0],n[0],o),n=l(e[1],i[1],n[1],o);t.rotation=-Math.atan2(n,s)-Math.PI/2,"line"!==this._symbolType&&"rect"!==this._symbolType&&"roundRect"!==this._symbolType||(void 0!==t.__lastT&&t.__lastT<t.__t?(t.scaleY=1.05*Ot(a,r),1===o&&(r[0]=a[0]+(r[0]-a[0])/2,r[1]=a[1]+(r[1]-a[1])/2)):1===t.__lastT?t.scaleY=2*Ot(e,r):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=r[0],t.y=r[1]},uO.prototype.updateLayout=function(t,e){this.childAt(0).updateLayout(t,e);var n=t.getItemModel(e).getModel("effect");this._updateEffectAnimation(t,n,e)},uO),qP=(d(lO,XP=ro),lO.prototype._createPolyline=function(t,e,n){var i=t.getItemLayout(e),i=new ny({shape:{points:i}});this.add(i),this._updateCommonStl(t,e,n)},lO.prototype.updateData=function(t,e,n){var i=t.hostModel;Wl(this.childAt(0),{shape:{points:t.getItemLayout(e)}},i,e),this._updateCommonStl(t,e,n)},lO.prototype._updateCommonStl=function(t,e,n){var i=this.childAt(0),o=t.getItemModel(e),r=n&&n.emphasisLineStyle;n&&!t.hasItemOption||(r=o.getModel(["emphasis","lineStyle"]).getLineStyle()),i.useStyle(t.getItemVisual(e,"style")),i.style.fill=null,i.style.strokeNoScale=!0,i.ensureState("emphasis").style=r,Ll(this)},lO.prototype.updateLayout=function(t,e){this.childAt(0).setShape("points",t.getItemLayout(e))},lO),KP=(d(sO,YP=jP),sO.prototype.createLine=function(t,e,n){return new qP(t,e,n)},sO.prototype._updateAnimationPoints=function(t,e){this._points=e;for(var n=[0],i=0,o=1;o<e.length;o++){var r=e[o-1],a=e[o];i+=Ot(r,a),n.push(i)}if(0!==i){for(o=0;o<n.length;o++)n[o]/=i;this._offsets=n,this._length=i}else this._length=0},sO.prototype._getLineLength=function(){return this._length},sO.prototype._updateSymbolPosition=function(t){var e=t.__t,n=this._points,i=this._offsets,o=n.length;if(i){var r=this._lastFrame;if(e<this._lastFramePercent){for(var a=Math.min(r+1,o-1);0<=a&&!(i[a]<=e);a--);a=Math.min(a,o-2)}else{for(a=r;a<o&&!(i[a]>e);a++);a=Math.min(a-1,o-2)}var s=(e-i[a])/(i[a+1]-i[a]),r=n[a],n=n[a+1];t.x=r[0]*(1-s)+s*n[0],t.y=r[1]*(1-s)+s*n[1];s=n[0]-r[0],r=n[1]-r[1];t.rotation=-Math.atan2(r,s)-Math.PI/2,this._lastFrame=a,this._lastFramePercent=e,t.ignore=!1}},sO),JP=function(){this.polyline=!1,this.curveness=0,this.segs=[]},QP=(d(aO,UP=as),aO.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},aO.prototype.getDefaultShape=function(){return new JP},aO.prototype.buildPath=function(t,e){var n=e.segs,i=e.curveness;if(e.polyline)for(var o=0;o<n.length;){var r=n[o++];if(0<r){t.moveTo(n[o++],n[o++]);for(var a=1;a<r;a++)t.lineTo(n[o++],n[o++])}}else for(o=0;o<n.length;){var s=n[o++],l=n[o++],u=n[o++],h=n[o++];t.moveTo(s,l),0<i?t.quadraticCurveTo((s+u)/2-(l-h)*i,(l+h)/2-(u-s)*i,u,h):t.lineTo(u,h)}},aO.prototype.findDataIndex=function(t,e){var n=this.shape,i=n.segs,o=n.curveness,r=this.style.lineWidth;if(n.polyline)for(var a=0,s=0;s<i.length;){var l=i[s++];if(0<l)for(var u=i[s++],h=i[s++],c=1;c<l;c++){var p=i[s++],d=i[s++];if(Ga(u,h,p,d,r,t,e))return a}a++}else for(s=a=0;s<i.length;){u=i[s++],h=i[s++],p=i[s++],d=i[s++];if(0<o){if(Ha(u,h,(u+p)/2-(h-d)*o,(h+d)/2-(p-u)*o,p,d,r,t,e))return a}else if(Ga(u,h,p,d,r,t,e))return a;a++}return-1},aO),$P=(rO.prototype.isPersistent=function(){return!this._incremental},rO.prototype.updateData=function(t){this.group.removeAll();var e=new QP({rectHover:!0,cursor:"default"});e.setShape({segs:t.getLayout("linesPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},rO.prototype.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),5e5<t.count()?(this._incremental||(this._incremental=new wy({silent:!0})),this.group.add(this._incremental)):this._incremental=null},rO.prototype.incrementalUpdate=function(t,e){var n=new QP;n.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(n,e,!!this._incremental),this._incremental?this._incremental.addDisplayable(n,!0):(n.rectHover=!0,n.cursor="default",n.__startIndex=t.start,this.group.add(n))},rO.prototype.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},rO.prototype._setCommon=function(e,t,n){var i=t.hostModel;e.setShape({polyline:i.get("polyline"),curveness:i.get(["lineStyle","curveness"])}),e.useStyle(i.getModel("lineStyle").getLineStyle()),e.style.strokeNoScale=!0;var o,t=t.getVisual("style");t&&t.stroke&&e.setStyle("stroke",t.stroke),e.setStyle("fill",null),n||((o=Gs(e)).seriesIndex=i.seriesIndex,e.on("mousemove",function(t){o.dataIndex=null;t=e.findDataIndex(t.offsetX,t.offsetY);0<t&&(o.dataIndex=t+e.__startIndex)}))},rO.prototype._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},rO),tO={seriesType:"lines",plan:Ud(),reset:function(f){var g=f.coordinateSystem,y=f.get("polyline"),m=f.pipelineContext.large;return{progress:function(t,e){var n=[];if(m){var i=void 0,o=t.end-t.start;if(y){for(var r=0,a=t.start;a<t.end;a++)r+=f.getLineCoordsCount(a);i=new Float32Array(o+2*r)}else i=new Float32Array(4*o);for(var s=0,l=[],a=t.start;a<t.end;a++){var u=f.getLineCoords(a,n);y&&(i[s++]=u);for(var h=0;h<u;h++)l=g.dataToPoint(n[h],!1,l),i[s++]=l[0],i[s++]=l[1]}e.setLayout("linesPoints",i)}else for(a=t.start;a<t.end;a++){var c=e.getItemModel(a),p=(u=f.getLineCoords(a,n),[]);if(y)for(var d=0;d<u;d++)p.push(g.dataToPoint(n[d]));else{p[0]=g.dataToPoint(n[0]),p[1]=g.dataToPoint(n[1]);c=c.get(["lineStyle","curveness"]);+c&&(p[2]=[(p[0][0]+p[1][0])/2-(p[0][1]-p[1][1])*c,(p[0][1]+p[1][1])/2-(p[1][0]-p[0][0])*c])}e.setItemLayout(a,p)}}}}},eO=(d(oO,WP=$d),oO.prototype.render=function(t,e,n){var i=t.getData(),o=this._updateLineDraw(i,t),r=t.get("zlevel"),a=t.get(["effect","trailLength"]),s=n.getZr(),n="svg"===s.painter.getType();n||s.painter.getLayer(r).clear(!0),null==this._lastZlevel||n||s.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&a&&(n||s.configLayer(r,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(a/10+.9,1),0)})),o.updateData(i);t=t.get("clip",!0)&&nb(t.coordinateSystem,!1,t);t?this.group.setClipPath(t):this.group.removeClipPath(),this._lastZlevel=r,this._finished=!0},oO.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateLineDraw(i,t).incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},oO.prototype.incrementalRender=function(t,e,n){this._lineDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},oO.prototype.updateTransform=function(t,e,n){var i=t.getData(),o=t.pipelineContext;if(!this._finished||o.large||o.progressiveRender)return{update:!0};e=tO.reset(t,e,n);e.progress&&e.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},oO.prototype._updateLineDraw=function(t,e){var n=this._lineDraw,i=this._showEffect(e),o=!!e.get("polyline"),e=e.pipelineContext.large;return n&&i===this._hasEffet&&o===this._isPolyline&&e===this._isLargeDraw||(n&&n.remove(),n=this._lineDraw=e?new $P:new RD(o?i?KP:qP:i?jP:DD),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=e),this.group.add(n.group),n},oO.prototype._showEffect=function(t){return!!t.get(["effect","show"])},oO.prototype._clearLayer=function(t){t=t.getZr();"svg"===t.painter.getType()||null==this._lastZlevel||t.painter.getLayer(this._lastZlevel).clear(!0)},oO.prototype.remove=function(t,e){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(e)},oO.prototype.dispose=function(t,e){this.remove(t,e)},oO.type="lines",oO),nO="undefined"==typeof Uint32Array?Array:Uint32Array,iO="undefined"==typeof Float64Array?Array:Float64Array;function oO(){var t=null!==WP&&WP.apply(this,arguments)||this;return t.type=oO.type,t}function rO(){this.group=new ro}function aO(t){return UP.call(this,t)||this}function sO(){var t=null!==YP&&YP.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}function lO(t,e,n){var i=XP.call(this)||this;return i._createPolyline(t,e,n),i}function uO(t,e,n){var i=ZP.call(this)||this;return i.add(i.createLine(t,e,n)),i._updateEffectSymbol(t,e),i}function hO(t){var e=t.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(t.data=H(e,function(t){var e={coords:[t[0].coord,t[1].coord]};return t[0].name&&(e.fromName=t[0].name),t[1].name&&(e.toName=t[1].name),R([e,t[0],t[1]])}))}var cO,pO=(d(dO,cO=Gd),dO.prototype.init=function(t){t.data=t.data||[],hO(t);var e=this._processFlatCoordsArray(t.data);this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset,e.flatCoords&&(t.data=new Float32Array(e.count)),cO.prototype.init.apply(this,arguments)},dO.prototype.mergeOption=function(t){var e;hO(t),t.data&&(e=this._processFlatCoordsArray(t.data),this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset,e.flatCoords&&(t.data=new Float32Array(e.count))),cO.prototype.mergeOption.apply(this,arguments)},dO.prototype.appendData=function(t){var e=this._processFlatCoordsArray(t.data);e.flatCoords&&(this._flatCoords?(this._flatCoords=mt(this._flatCoords,e.flatCoords),this._flatCoordsOffset=mt(this._flatCoordsOffset,e.flatCoordsOffset)):(this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset),t.data=new Float32Array(e.count)),this.getRawData().appendData(t.data)},dO.prototype._getCoordsFromItemModel=function(t){t=this.getData().getItemModel(t);return t.option instanceof Array?t.option:t.getShallow("coords")},dO.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[2*t+1]:this._getCoordsFromItemModel(t).length},dO.prototype.getLineCoords=function(t,e){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[2*t],i=this._flatCoordsOffset[2*t+1],o=0;o<i;o++)e[o]=e[o]||[],e[o][0]=this._flatCoords[n+2*o],e[o][1]=this._flatCoords[n+2*o+1];return i}for(var r=this._getCoordsFromItemModel(t),o=0;o<r.length;o++)e[o]=e[o]||[],e[o][0]=r[o][0],e[o][1]=r[o][1];return r.length},dO.prototype._processFlatCoordsArray=function(t){var e=0;if(this._flatCoords&&(e=this._flatCoords.length),"number"!=typeof t[0])return{flatCoordsOffset:null,flatCoords:null,count:t.length};for(var n=t.length,i=new nO(n),o=new iO(n),r=0,a=0,s=0,l=0;l<n;){s++;var u=t[l++];i[a++]=r+e,i[a++]=u;for(var h=0;h<u;h++){var c=t[l++],p=t[l++];o[r++]=c,o[r++]=p}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,a),flatCoords:o,count:s}},dO.prototype.getInitialData=function(t,e){var o=new c_(["value"],this);return o.hasItemOption=!1,o.initData(t.data,[],function(t,e,n,i){if(t instanceof Array)return NaN;o.hasItemOption=!0;t=t.value;return null!=t?t instanceof Array?t[i]:t:void 0}),o},dO.prototype.formatTooltip=function(t,e,n){var i=this.getData().getItemModel(t),o=i.get("name");if(o)return o;t=i.get("fromName"),o=i.get("toName"),i=[];return null!=t&&i.push(t),null!=o&&i.push(o),md("nameValue",{name:i.join(" > ")})},dO.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},dO.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?1e4:this.get("progressive"):t},dO.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?2e4:this.get("progressiveThreshold"):t},dO.type="series.lines",dO.dependencies=["grid","polar","geo","calendar"],dO.defaultOption={coordinateSystem:"geo",zlevel:0,z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},dO);function dO(){var t=null!==cO&&cO.apply(this,arguments)||this;return t.type=dO.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}function fO(t){return t=!(t instanceof Array)?[t,t]:t}var gO={seriesType:"lines",reset:function(t){var e=fO(t.get("symbol")),n=fO(t.get("symbolSize")),t=t.getData();return t.setVisual("fromSymbol",e&&e[0]),t.setVisual("toSymbol",e&&e[1]),t.setVisual("fromSymbolSize",n&&n[0]),t.setVisual("toSymbolSize",n&&n[1]),{dataEach:t.hasItemOption?function(t,e){var n=fO((i=t.getItemModel(e)).getShallow("symbol",!0)),i=fO(i.getShallow("symbolSize",!0));n[0]&&t.setItemVisual(e,"fromSymbol",n[0]),n[1]&&t.setItemVisual(e,"toSymbol",n[1]),i[0]&&t.setItemVisual(e,"fromSymbolSize",i[0]),i[1]&&t.setItemVisual(e,"toSymbolSize",i[1])}:null}}};var yO=(mO.prototype.update=function(t,e,n,i,o,r){var a=this._getBrush(),s=this._getGradient(o,"inRange"),l=this._getGradient(o,"outOfRange"),u=this.pointSize+this.blurSize,o=this.canvas,h=o.getContext("2d"),c=t.length;o.width=e,o.height=n;for(var p=0;p<c;++p){var d=t[p],f=d[0],g=d[1],y=i(d[2]);h.globalAlpha=y,h.drawImage(a,f-u,g-u)}if(!o.width||!o.height)return o;for(var n=h.getImageData(0,0,o.width,o.height),m=n.data,v=0,x=m.length,_=this.minOpacity,b=this.maxOpacity-_;v<x;){var w,y=m[v+3]/256,S=4*Math.floor(255*y);0<y?(w=r(y)?s:l,0<y&&(y=y*b+_),m[v++]=w[S],m[v++]=w[1+S],m[v++]=w[2+S],m[v++]=w[3+S]*y*256):v+=4}return h.putImageData(n,0,0),o},mO.prototype._getBrush=function(){var t=this._brushCanvas||(this._brushCanvas=E()),e=this.pointSize+this.blurSize,n=2*e;t.width=n,t.height=n;var i=t.getContext("2d");return i.clearRect(0,0,n,n),i.shadowOffsetX=n,i.shadowBlur=this.blurSize,i.shadowColor="#000",i.beginPath(),i.arc(-e,e,this.pointSize,0,2*Math.PI,!0),i.closePath(),i.fill(),t},mO.prototype._getGradient=function(t,e){for(var n=this._gradientPixels,i=n[e]||(n[e]=new Uint8ClampedArray(1024)),o=[0,0,0,0],r=0,a=0;a<256;a++)t[e](a/255,!0,o),i[r++]=o[0],i[r++]=o[1],i[r++]=o[2],i[r++]=o[3];return i},mO);function mO(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var t=E();this.canvas=t}function vO(t){t=t.dimensions;return"lng"===t[0]&&"lat"===t[1]}var xO,_O,bO=(d(MO,_O=$d),MO.prototype.render=function(n,t,e){var i;t.eachComponent("visualMap",function(e){e.eachTargetSeries(function(t){t===n&&(i=e)})}),this.group.removeAll(),this._incrementalDisplayable=null;t=n.coordinateSystem;"cartesian2d"===t.type||"calendar"===t.type?this._renderOnCartesianAndCalendar(n,e,0,n.getData().count()):vO(t)&&this._renderOnGeo(t,n,i,e)},MO.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll()},MO.prototype.incrementalRender=function(t,e,n,i){var o=e.coordinateSystem;o&&(vO(o)?this.render(e,n,i):this._renderOnCartesianAndCalendar(e,i,t.start,t.end,!0))},MO.prototype._renderOnCartesianAndCalendar=function(t,e,n,i,o){var r,a,s,l,u,h,c=t.coordinateSystem;ib(c,"cartesian2d")&&(r=c.getAxis("x"),a=c.getAxis("y"),s=r.getBandWidth(),l=a.getBandWidth(),u=r.scale.getExtent(),h=a.scale.getExtent());for(var p=this.group,d=t.getData(),f=t.getModel(["emphasis","itemStyle"]).getItemStyle(),g=t.getModel(["blur","itemStyle"]).getItemStyle(),y=t.getModel(["select","itemStyle"]).getItemStyle(),m=tu(t),v=t.get(["emphasis","focus"]),x=t.get(["emphasis","blurScope"]),_=ib(c,"cartesian2d")?[d.mapDimension("x"),d.mapDimension("y"),d.mapDimension("value")]:[d.mapDimension("time"),d.mapDimension("value")],b=n;b<i;b++){var w=void 0,S=d.getItemVisual(b,"style");if(ib(c,"cartesian2d")){var M=d.get(_[0],b),I=d.get(_[1],b);if(isNaN(d.get(_[2],b))||M<u[0]||M>u[1]||I<h[0]||I>h[1])continue;I=c.dataToPoint([M,I]),w=new Ts({shape:{x:Math.floor(Math.round(I[0])-s/2),y:Math.floor(Math.round(I[1])-l/2),width:Math.ceil(s),height:Math.ceil(l)},style:S})}else{if(isNaN(d.get(_[1],b)))continue;w=new Ts({z2:1,shape:c.dataToRect([d.get(_[0],b)]).contentShape,style:S})}I=d.getItemModel(b);d.hasItemOption&&(f=(T=I.getModel("emphasis")).getModel("itemStyle").getItemStyle(),g=I.getModel(["blur","itemStyle"]).getItemStyle(),y=I.getModel(["select","itemStyle"]).getItemStyle(),v=T.get("focus"),x=T.get("blurScope"),m=tu(I));var T=t.getRawValue(b),I="-";T&&null!=T[2]&&(I=T[2]+""),$l(w,m,{labelFetcher:t,labelDataIndex:b,defaultOpacity:S.opacity,defaultText:I}),w.ensureState("emphasis").style=f,w.ensureState("blur").style=g,w.ensureState("select").style=y,Ll(w,v,x),(w.incremental=o)&&(w.states.emphasis.hoverLayer=!0),p.add(w),d.setItemGraphicEl(b,w)}},MO.prototype._renderOnGeo=function(i,t,e,n){var o=e.targetVisuals.inRange,r=e.targetVisuals.outOfRange,a=t.getData(),s=this._hmLayer||this._hmLayer||new yO;s.blurSize=t.get("blurSize"),s.pointSize=t.get("pointSize"),s.minOpacity=t.get("minOpacity"),s.maxOpacity=t.get("maxOpacity");var l=i.getViewRect().clone(),u=i.getRoamTransform();l.applyTransform(u);var h,c,p,d,f,g,y,m=Math.max(l.x,0),v=Math.max(l.y,0),t=Math.min(l.width+l.x,n.getWidth()),u=Math.min(l.height+l.y,n.getHeight()),l=t-m,n=u-v,t=[a.mapDimension("lng"),a.mapDimension("lat"),a.mapDimension("value")],u=a.mapArray(t,function(t,e,n){e=i.dataToPoint([t,e]);return e[0]-=m,e[1]-=v,e.push(n),e}),a=e.getExtent(),e="visualMap.continuous"===e.type?(y=e.option.range,t=a[1]-a[0],y=[(y[0]-a[0])/t,(y[1]-a[0])/t],function(t){return t>=y[0]&&t<=y[1]}):(h=a,c=e.getPieceList(),p=e.option.selected,d=h[1]-h[0],f=(c=H(c,function(t){return{interval:[(t.interval[0]-h[0])/d,(t.interval[1]-h[0])/d]}})).length,g=0,function(t){for(var e=g;e<f;e++){var n=c[e].interval;if(n[0]<=t&&t<=n[1]){g=e;break}}if(e===f)for(e=g-1;0<=e;e--)if((n=c[e].interval)[0]<=t&&t<=n[1]){g=e;break}return 0<=e&&e<f&&p[e]});s.update(u,l,n,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:r.color.getColorMapper()},e);s=new ys({style:{width:l,height:n,x:m,y:v,image:s.canvas},silent:!0});this.group.add(s)},MO.type="heatmap",MO),wO=(d(SO,xO=Gd),SO.prototype.getInitialData=function(t,e){return w_(null,this,{generateCoord:"value"})},SO.prototype.preventIncremental=function(){var t=Sc.get(this.get("coordinateSystem"));if(t&&t.dimensions)return"lng"===t.dimensions[0]&&"lat"===t.dimensions[1]},SO.type="series.heatmap",SO.dependencies=["grid","geo","calendar"],SO.defaultOption={coordinateSystem:"cartesian2d",zlevel:0,z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}},SO);function SO(){var t=null!==xO&&xO.apply(this,arguments)||this;return t.type=SO.type,t}function MO(){var t=null!==_O&&_O.apply(this,arguments)||this;return t.type=MO.type,t}var IO,TO=["itemStyle","borderWidth"],CO=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],DO=new $f;function AO(){var t=null!==IO&&IO.apply(this,arguments)||this;return t.type=AO.type,t}function kO(t,e,n,i){var o,r,a,s,l,u=t.getItemLayout(e),h=n.get("symbolRepeat"),c=n.get("symbolClip"),p=n.get("symbolPosition")||"start",d=(n.get("symbolRotate")||0)*Math.PI/180||0,f=n.get("symbolPatternSize")||2,g=n.isAnimationEnabled(),y={dataIndex:e,layout:u,itemModel:n,symbolType:t.getItemVisual(e,"symbol")||"circle",style:t.getItemVisual(e,"style"),symbolClip:c,symbolRepeat:h,symbolRepeatDirection:n.get("symbolRepeatDirection"),symbolPatternSize:f,rotation:d,animationModel:g?n:null,hoverScale:g&&n.get(["emphasis","scale"]),z2:n.getShallow("z",!0)||0};(function(t,e,n,i,o){var r=i.valueDim,a=t.get("symbolBoundingData"),s=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-(n[r.wh]<=0);l=j(a)?((t=[LO(s,a[0])-l,LO(s,a[1])-l])[1]<t[0]&&t.reverse(),t[u]):null!=a?LO(s,a)-l:e?i.coordSysExtent[r.index][u]-l:n[r.wh];o.boundingLength=l,e&&(o.repeatCutLength=n[r.wh]),o.pxSign=0<l?1:l<0?-1:0})(n,h,u,i,y),o=t,r=e,a=u,s=h,l=y.boundingLength,m=y.pxSign,c=f,g=y,e=(t=i).valueDim,f=t.categoryDim,a=Math.abs(a[f.wh]),(r=j(r=o.getItemVisual(r,"symbolSize"))?r.slice():null==r?["100%","100%"]:[r,r])[f.index]=go(r[f.index],a),r[e.index]=go(r[e.index],s?a:Math.abs(l)),g.symbolSize=r,(g.symbolScale=[r[0]/c,r[1]/c])[e.index]*=(t.isHorizontal?-1:1)*m,function(t,e,n,i,o){t=t.get(TO)||0;t&&(DO.attr({scaleX:e[0],scaleY:e[1],rotation:n}),DO.updateTransform(),t/=DO.getLineScale(),t*=e[i.valueDim.index]),o.valueLineWidth=t}(n,y.symbolScale,d,i,y);var m=y.symbolSize,d=lm(n.get("symbolOffset"),m);return function(t,e,n,i,o,r,a,s,l,u,h){var c=u.categoryDim,p=u.valueDim,d=h.pxSign,f=Math.max(e[p.index]+a,0),g=f;{var y,m,v;i&&(y=Math.abs(s),v=ot(t.get("symbolMargin"),"15%")+"",m=!1,v.lastIndexOf("!")===v.length-1&&(m=!0,v=v.slice(0,v.length-1)),x=go(v,e[p.index]),a=Math.max(f+2*x,0),t=m?0:2*x,v=ko(i),e=v?i:XO((y+t)/a),x=(y-e*f)/2/(m?e:Math.max(e-1,1)),a=f+2*x,t=m?0:2*x,v||"fixed"===i||(e=l?XO((Math.abs(l)+t)/a):0),g=e*a-t,h.repeatTimes=e,h.symbolMargin=x)}var x=d*(g/2),g=h.pathPosition=[];g[c.index]=n[c.wh]/2,g[p.index]="start"===r?x:"end"===r?s-x:s/2,o&&(g[0]+=o[0],g[1]+=o[1]);o=h.bundlePosition=[];o[c.index]=n[c.xy],o[p.index]=n[p.xy];o=h.barRectShape=N({},n);o[p.wh]=d*Math.max(Math.abs(n[p.wh]),Math.abs(g[p.index]+x)),o[c.wh]=n[c.wh];h=h.clipShape={};h[c.xy]=-n[c.xy],h[c.wh]=u.ecSize[c.wh],h[p.xy]=0,h[p.wh]=n[p.wh]}(n,m,u,h,d,p,y.valueLineWidth,y.boundingLength,y.repeatCutLength,i,y),y}function LO(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function PO(t){var e=t.symbolPatternSize,e=am(t.symbolType,-e/2,-e/2,e,e);return e.attr({culling:!0}),"image"!==e.type&&e.setStyle({strokeNoScale:!0}),e}function OO(t,e,o,n){var i=t.__pictorialBundle,r=o.symbolSize,a=o.valueLineWidth,s=o.pathPosition,l=e.valueDim,u=o.repeatTimes||0,h=0,c=r[e.valueDim.index]+a+2*o.symbolMargin;for(WO(t,function(t){t.__pictorialAnimationIndex=h,t.__pictorialRepeatTimes=u,h<u?UO(t,null,f(h),o,n):UO(t,null,{scaleX:0,scaleY:0},o,n,function(){i.remove(t)}),h++});h<u;h++){var p=PO(o);p.__pictorialAnimationIndex=h,p.__pictorialRepeatTimes=u,i.add(p);var d=f(h);UO(p,{x:d.x,y:d.y,scaleX:0,scaleY:0},{scaleX:d.scaleX,scaleY:d.scaleY,rotation:d.rotation},o,n)}function f(t){var e=s.slice(),n=o.pxSign,i=t;return("start"===o.symbolRepeatDirection?0<n:n<0)&&(i=u-1-t),e[l.index]=c*(i-u/2+.5)+s[l.index],{x:e[0],y:e[1],scaleX:o.symbolScale[0],scaleY:o.symbolScale[1],rotation:o.rotation}}}function RO(t,e,n,i){var o=t.__pictorialBundle,r=t.__pictorialMainPath;r?UO(r,null,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation},n,i):(r=t.__pictorialMainPath=PO(n),o.add(r),UO(r,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:0,scaleY:0,rotation:n.rotation},{scaleX:n.symbolScale[0],scaleY:n.symbolScale[1]},n,i))}function NO(t,e,n){var i=N({},e.barRectShape),o=t.__pictorialBarRect;o?UO(o,null,{shape:i},e,n):((o=t.__pictorialBarRect=new Ts({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}})).disableMorphing=!0,t.add(o))}function zO(t,e,n,i){var o,r,a,s;n.symbolClip&&(o=t.__pictorialClipPath,r=N({},n.clipShape),a=e.valueDim,s=n.animationModel,e=n.dataIndex,o?Wl(o,{shape:r},s,e):(r[a.wh]=0,o=new Ts({shape:r}),t.__pictorialBundle.setClipPath(o),t.__pictorialClipPath=o,(t={})[a.wh]=n.clipShape[a.wh],p[i?"updateProps":"initProps"](o,{shape:t},s,e)))}function EO(t,e){e=t.getItemModel(e);return e.getAnimationDelayParams=VO,e.isAnimationEnabled=BO,e}function VO(t){return{index:t.__pictorialAnimationIndex,count:t.__pictorialRepeatTimes}}function BO(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function FO(t,e,n,i){var o=new ro,r=new ro;return o.add(r),(o.__pictorialBundle=r).x=n.bundlePosition[0],r.y=n.bundlePosition[1],n.symbolRepeat?OO(o,e,n):RO(o,0,n),NO(o,n,i),zO(o,e,n,i),o.__pictorialShapeStr=HO(t,n),o.__pictorialSymbolMeta=n,o}function GO(t,e,n,i){var o=i.__pictorialBarRect;o&&o.removeTextContent();var r=[];WO(i,function(t){r.push(t)}),i.__pictorialMainPath&&r.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),G(r,function(t){Xl(t,{scaleX:0,scaleY:0},n,e,function(){i.parent&&i.parent.remove(i)})}),t.setItemGraphicEl(e,null)}function HO(t,e){return[t.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function WO(e,n,i){G(e.__pictorialBundle.children(),function(t){t!==e.__pictorialBarRect&&n.call(i,t)})}function UO(t,e,n,i,o,r){e&&t.attr(e),i.symbolClip&&!o?n&&t.attr(n):n&&p[o?"updateProps":"initProps"](t,n,i.animationModel,i.dataIndex,r)}function YO(t,e,n){var i=n.dataIndex,o=n.itemModel,r=o.getModel("emphasis"),a=r.getModel("itemStyle").getItemStyle(),s=o.getModel(["blur","itemStyle"]).getItemStyle(),l=o.getModel(["select","itemStyle"]).getItemStyle(),u=o.getShallow("cursor"),h=r.get("focus"),c=r.get("blurScope"),p=r.get("scale");WO(t,function(t){t instanceof ys?(e=t.style,t.useStyle(N({image:e.image,x:e.x,y:e.y,width:e.width,height:e.height},n.style))):t.useStyle(n.style);var e=t.ensureState("emphasis");e.style=a,p&&(e.scaleX=1.1*t.scaleX,e.scaleY=1.1*t.scaleY),t.ensureState("blur").style=s,t.ensureState("select").style=l,u&&(t.cursor=u),t.z2=n.z2});r=e.valueDim.posDesc[+(0<n.boundingLength)];$l(t.__pictorialBarRect,tu(o),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:I_(e.seriesModel.getData(),i),inheritColor:n.style.fill,defaultOpacity:n.style.opacity,defaultOutsidePosition:r}),Ll(t,h,c)}function XO(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}var ZO,jO,qO=(d(AO,IO=$d),AO.prototype.render=function(t,e,n){var l=this.group,u=t.getData(),h=this._data,i=t.coordinateSystem,o=i.getBaseAxis().isHorizontal(),r=i.master.getRect(),c={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:i,coordSysExtent:[[r.x,r.x+r.width],[r.y,r.y+r.height]],isHorizontal:o,valueDim:CO[+o],categoryDim:CO[1-+o]};return u.diff(h).add(function(t){var e,n;u.hasValue(t)&&(n=EO(u,t),e=kO(u,t,n,c),n=FO(u,c,e),u.setItemGraphicEl(t,n),l.add(n),YO(n,c,e))}).update(function(t,e){var n,i,o,r,a,s=h.getItemGraphicEl(e);u.hasValue(t)?(r=EO(u,t),n=kO(u,t,r,c),a=HO(u,n),s&&a!==s.__pictorialShapeStr&&(l.remove(s),u.setItemGraphicEl(t,null),s=null),s?(i=s,o=c,r=(e=n).animationModel,a=e.dataIndex,Wl(i.__pictorialBundle,{x:e.bundlePosition[0],y:e.bundlePosition[1]},r,a),(e.symbolRepeat?OO:RO)(i,o,e,!0),NO(i,e,!0),zO(i,o,e,!0)):s=FO(u,c,n,!0),u.setItemGraphicEl(t,s),s.__pictorialSymbolMeta=n,l.add(s),YO(s,c,n)):l.remove(s)}).remove(function(t){var e=h.getItemGraphicEl(t);e&&GO(h,t,e.__pictorialSymbolMeta.animationModel,e)}).execute(),this._data=u,this.group},AO.prototype.remove=function(e,t){var n=this.group,i=this._data;e.get("animation")?i&&i.eachItemGraphicEl(function(t){GO(i,Gs(t).dataIndex,e,t)}):n.removeAll()},AO.type="pictorialBar",AO),KO=(d(JO,ZO=io),JO.prototype.getInitialData=function(t){return t.stack=null,ZO.prototype.getInitialData.apply(this,arguments)},JO.type="series.pictorialBar",JO.dependencies=["grid"],JO.defaultOption=Iu(io.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),JO);function JO(){var t=null!==ZO&&ZO.apply(this,arguments)||this;return t.type=JO.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}function QO(){var t=null!==jO&&jO.apply(this,arguments)||this;return t.type=QO.type,t._layers=[],t}var $O,tR=(d(QO,jO=$d),QO.prototype.render=function(_,t,e){var b=_.getData(),w=this,S=this.group,M=_.getLayerSeries(),n=b.getLayout("layoutInfo"),i=n.rect,n=n.boundaryGap;function o(t){return t.name}S.x=0,S.y=i.y+n[0];var n=new Vx(this._layersSeries||[],M,o,o),I=[];function r(t,e,n){var i,o,r,a=w._layers;if("remove"!==t){for(var s,l=[],u=[],h=M[e].indices,c=0;c<h.length;c++){var p=b.getItemLayout(h[c]),d=p.x,f=p.y0,p=p.y;l.push(d,f),u.push(d,f+p),s=b.getItemVisual(h[c],"style")}var g,y=b.getItemLayout(h[0]),m=_.getModel("label").get("margin"),v=_.getModel("emphasis");"add"===t?(x=I[e]=new ro,g=new K_({shape:{points:l,stackedOnPoints:u,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),x.add(g),S.add(x),_.isAnimationEnabled()&&g.setClipPath((i=g.getBoundingRect(),o=_,r=function(){g.removeClipPath()},Ul(t=new Ts({shape:{x:i.x-10,y:i.y-10,width:0,height:i.height+20}}),{shape:{x:i.x-50,width:i.width+100,height:i.height+20}},o,r),t))):(x=a[n],g=x.childAt(0),S.add(x),I[e]=x,Wl(g,{shape:{points:l,stackedOnPoints:u}},_),ql(g)),$l(g,tu(_),{labelDataIndex:h[c-1],defaultText:b.getName(h[c-1]),inheritColor:s.fill},{normal:{verticalAlign:"middle"}}),g.setTextConfig({position:null,local:!0});var x=g.getTextContent();x&&(x.x=y.x-m,x.y=y.y0+y.y/2),g.useStyle(s),b.setItemGraphicEl(e,g),Nl(g,_),Ll(g,v.get("focus"),v.get("blurScope"))}else S.remove(a[e])}n.add(X(r,this,"add")).update(X(r,this,"update")).remove(X(r,this,"remove")).execute(),this._layersSeries=M,this._layers=I},QO.type="themeRiver",QO),eR=(d(nR,$O=Gd),nR.prototype.init=function(t){$O.prototype.init.apply(this,arguments),this.legendVisualProvider=new Rw(X(this.getData,this),X(this.getRawData,this))},nR.prototype.fixData=function(t){var e=t.length,n={},i=er(t,function(t){return n.hasOwnProperty(t[0]+"")||(n[t[0]+""]=-1),t[2]}),o=[];i.buckets.each(function(t,e){o.push({name:e,dataList:t})});for(var r=o.length,a=0;a<r;++a){for(var s=o[a].name,l=0;l<o[a].dataList.length;++l){var u=o[a].dataList[l][0]+"";n[u]=a}for(u in n)n.hasOwnProperty(u)&&n[u]!==a&&(n[u]=a,t[e]=[u,0,s],e++)}return t},nR.prototype.getInitialData=function(t,e){for(var n=this.getReferringComponents("singleAxis",Jo).models[0].get("type"),t=U(t.data,function(t){return void 0!==t[2]}),i=this.fixData(t||[]),o=[],r=this.nameMap=yt(),a=0,s=0;s<i.length;++s)o.push(i[s][2]),r.get(i[s][2])||(r.set(i[s][2],a),a++);n=d_(i,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:Ux(n)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,n=new c_(n,this);return n.initData(i),n},nR.prototype.getLayerSeries=function(){for(var n=this.getData(),t=n.count(),e=[],i=0;i<t;++i)e[i]=i;var o=n.mapDimension("single"),r=er(e,function(t){return n.get("name",t)}),a=[];return r.buckets.each(function(t,e){t.sort(function(t,e){return n.get(o,t)-n.get(o,e)}),a.push({name:e,indices:t})}),a},nR.prototype.getAxisTooltipData=function(t,e,n){j(t)||(t=t?[t]:[]);for(var i,o=this.getData(),r=this.getLayerSeries(),a=[],s=r.length,l=0;l<s;++l){for(var u=Number.MAX_VALUE,h=-1,c=r[l].indices.length,p=0;p<c;++p){var d=o.get(t[0],r[l].indices[p]),f=Math.abs(d-e);f<=u&&(i=d,u=f,h=r[l].indices[p])}a.push(h)}return{dataIndices:a,nestestValue:i}},nR.prototype.formatTooltip=function(t,e,n){var i=this.getData();return md("nameValue",{name:i.getName(t),value:i.get(i.mapDimension("value"),t)})},nR.type="series.themeRiver",nR.dependencies=["singleAxis"],nR.defaultOption={zlevel:0,z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},nR);function nR(){var t=null!==$O&&$O.apply(this,arguments)||this;return t.type=nR.type,t}function iR(t,e){t.eachSeriesByType("themeRiver",function(t){var e=t.getData(),n=t.coordinateSystem,i={},o=n.getRect();i.rect=o;var r=t.get("boundaryGap"),n=n.getAxis();i.boundaryGap=r,"horizontal"===n.orient?(r[0]=go(r[0],o.height),r[1]=go(r[1],o.height),oR(e,t,o.height-r[0]-r[1])):(r[0]=go(r[0],o.width),r[1]=go(r[1],o.width),oR(e,t,o.width-r[0]-r[1])),e.setLayout("layoutInfo",i)})}function oR(n,t,e){if(n.count())for(var i,o=t.coordinateSystem,r=t.getLayerSeries(),a=n.mapDimension("single"),s=n.mapDimension("value"),l=H(r,function(t){return H(t.indices,function(t){var e=o.dataToPoint(n.get(a,t));return e[1]=n.get(s,t),e})}),t=function(t){for(var e=t.length,n=t[0].length,i=[],o=[],r=0,a=0;a<n;++a){for(var s=0,l=0;l<e;++l)s+=t[l][a][1];r<s&&(r=s),i.push(s)}for(var u=0;u<n;++u)o[u]=(r-i[u])/2;for(var h=r=0;h<n;++h){var c=i[h]+o[h];r<c&&(r=c)}return{y0:o,max:r}}(l),u=t.y0,h=e/t.max,c=r.length,p=r[0].indices.length,d=0;d<p;++d){i=u[d]*h,n.setItemLayout(r[0].indices[d],{layerIndex:0,x:l[0][d][0],y0:i,y:l[0][d][1]*h});for(var f=1;f<c;++f)i+=l[f-1][d][1]*h,n.setItemLayout(r[f].indices[d],{layerIndex:f,x:l[f][d][0],y0:i,y:l[f][d][1]*h})}}var rR,aR=(d(hR,rR=Wg),hR.prototype.updateData=function(t,e,n,i,o){(this.node=e).piece=this,n=n||this._seriesModel,i=i||this._ecModel;var r=this;Gs(r).dataIndex=e.dataIndex;var a=e.getModel(),s=a.getModel("emphasis"),l=e.getLayout(),u=N({},l);u.label=null;var h=e.getVisual("style");h.lineJoin="bevel";var c=e.getVisual("decal");c&&(h.decal=zm(c,o));o=Iw(a.getModel("itemStyle"),u,!0);N(u,o),G(js,function(t){var e=r.ensureState(t),t=a.getModel([t,"itemStyle"]);e.style=t.getItemStyle();t=Iw(t,u);t&&(e.shape=t)}),t?(r.setShape(u),r.shape.r=l.r0,Wl(r,{shape:{r:l.r}},n,e.dataIndex)):(Wl(r,{shape:u},n),ql(r)),r.useStyle(h),this._updateLabel(n);h=a.getShallow("cursor");h&&r.attr("cursor",h),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;i=s.get("focus");Ll(this,"ancestor"===i?e.getAncestorsIndices():"descendant"===i?e.getDescendantIndices():i,s.get("blurScope"))},hR.prototype._updateLabel=function(a){var s=this,l=this.node.getModel(),n=l.getModel("label"),u=this.node.getLayout(),t=u.endAngle-u.startAngle,h=(u.startAngle+u.endAngle)/2,c=Math.cos(h),p=Math.sin(h),d=this,f=d.getTextContent(),g=this.node.dataIndex,e=n.get("minAngle")/180*Math.PI,e=n.get("show")&&!(null!=e&&Math.abs(t)<e);function y(t,e){t=t.get(e);return null==t?n.get(e):t}f.ignore=!e,G(qs,function(t){var e="normal"===t?l.getModel("label"):l.getModel([t,"label"]),n="normal"===t,i=n?f:f.ensureState(t),o=a.getFormattedLabel(g,t);n&&(o=o||s.node.name),i.style=eu(e,{},null,"normal"!==t,!0),o&&(i.style.text=o);o=e.get("show");null==o||n||(i.ignore=!o);o=y(e,"position"),n=n?d:d.states[t],t=n.style.fill;n.textConfig={outsideFill:"inherit"===e.get("color")?t:null,inside:"outside"!==o};n=y(e,"distance")||0,t=y(e,"align");"outside"===o?(r=u.r+n,t=h>Math.PI/2?"right":"left"):t&&"center"!==t?"left"===t?(r=u.r0+n,h>Math.PI/2&&(t="right")):"right"===t&&(r=u.r-n,h>Math.PI/2&&(t="left")):(r=(u.r+u.r0)/2,t="center"),i.style.align=t,i.style.verticalAlign=y(e,"verticalAlign")||"middle",i.x=r*c+u.cx,i.y=r*p+u.cy;var r=y(e,"rotate"),e=0;"radial"===r?(e=-h)<-Math.PI/2&&(e+=Math.PI):"tangential"===r?(e=Math.PI/2-h)>Math.PI/2?e-=Math.PI:e<-Math.PI/2&&(e+=Math.PI):"number"==typeof r&&(e=r*Math.PI/180),i.rotation=e}),f.dirtyStyle()},hR),sR="sunburstRootToNode",lR="sunburstHighlight",uR="sunburstUnhighlight";function hR(t,e,n,i){var o=rR.call(this)||this;o.z2=2,o.textConfig={inside:!0},Gs(o).seriesIndex=e.seriesIndex;var r=new Fs({z2:4,silent:t.getModel().get(["label","silent"])});return o.setTextContent(r),o.updateData(!0,t,e,n,i),o}function cR(t){t.registerAction({type:sR,update:"updateView"},function(o,t){t.eachComponent({mainType:"series",subType:"sunburst",query:o},function(t,e){var n,i=bT(o,[sR],t);i&&((n=t.getViewRoot())&&(o.direction=ST(n,i.node)?"rollUp":"drillDown"),t.resetViewRoot(i.node))})}),t.registerAction({type:lR,update:"none"},function(e,t,n){e=N({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},function(t){(t=bT(e,[lR],t))&&(e.dataIndex=t.node.dataIndex)}),n.dispatchAction(N(e,{type:"highlight"}))}),t.registerAction({type:uR,update:"updateView"},function(t,e,n){t=N({},t),n.dispatchAction(N(t,{type:"downplay"}))})}var pR,dR,fR=(d(yR,dR=$d),yR.prototype.render=function(n,i,o,t){var e=this;this.seriesModel=n,this.api=o,this.ecModel=i;var r=n.getData(),a=r.tree.root,s=n.getViewRoot(),l=this.group,u=n.get("renderLabelForZeroData"),h=[];s.eachNode(function(t){h.push(t)});var c,p,d,f=this._oldChildren||[];function g(t){return t.getId()}function y(t,e){var t=null==t?null:p[t],e=null==e?null:d[e];t=t,e=e,(t=u||!t||t.getValue()?t:null)!==a&&e!==a&&(e&&e.piece?t?(e.piece.updateData(!1,t,n,i,o),r.setItemGraphicEl(t.dataIndex,e.piece)):function(t){t&&t.piece&&(l.remove(t.piece),t.piece=null)}(e):t&&(e=new aR(t,n,i,o),l.add(e),r.setItemGraphicEl(t.dataIndex,e)))}d=f,0===(p=h).length&&0===d.length||new Vx(d,p,g,g).add(y).update(y).remove(Z(y,null)).execute(),f=a,0<(c=s).depth?(e.virtualPiece?e.virtualPiece.updateData(!1,f,n,i,o):(e.virtualPiece=new aR(f,n,i,o),l.add(e.virtualPiece)),c.piece.off("click"),e.virtualPiece.on("click",function(t){e._rootToNode(c.parentNode)})):e.virtualPiece&&(l.remove(e.virtualPiece),e.virtualPiece=null),this._initEvents(),this._oldChildren=h},yR.prototype._initEvents=function(){var o=this;this.group.off("click"),this.group.on("click",function(n){var i=!1;o.seriesModel.getViewRoot().eachNode(function(t){var e;!i&&t.piece&&t.piece===n.target&&("rootToNode"===(e=t.getModel().get("nodeClick"))?o._rootToNode(t):"link"!==e||(t=(e=t.getModel()).get("link"))&&mh(t,e.get("target",!0)||"_blank"),i=!0)})})},yR.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:sR,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},yR.prototype.containPoint=function(t,e){var n=e.getData().getItemLayout(0);if(n){e=t[0]-n.cx,t=t[1]-n.cy,t=Math.sqrt(e*e+t*t);return t<=n.r&&t>=n.r0}},yR.type="sunburst",yR);function gR(){var t=null!==pR&&pR.apply(this,arguments)||this;return t.type=gR.type,t.ignoreStyleOnData=!0,t}function yR(){var t=null!==dR&&dR.apply(this,arguments)||this;return t.type=yR.type,t}var mR=(d(gR,pR=Gd),gR.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};!function e(t){var n=0;G(t.children,function(t){e(t);t=t.value;j(t)&&(t=t[0]),n+=t});var i=t.value;j(i)&&(i=i[0]),null!=i&&!isNaN(i)||(i=n),i<0&&(i=0),j(t.value)?t.value[0]=i:t.value=i}(n);var i=this._levelModels=H(t.levels||[],function(t){return new wu(t,this,e)},this),o=_T.createTree(n,this,function(t){t.wrapMethod("getItemModel",function(t,e){e=o.getNodeByDataIndex(e),e=i[e.depth];return e&&(t.parentModel=e),t})});return o.data},gR.prototype.optionUpdated=function(){this.resetViewRoot()},gR.prototype.getDataParams=function(t){var e=pR.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treePathInfo=MT(t,this),e},gR.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},gR.prototype.getViewRoot=function(){return this._viewRoot},gR.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},gR.prototype.enableAriaDecal=function(){NT(this)},gR.type="series.sunburst",gR.defaultOption={zlevel:0,z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},gR),vR=Math.PI/180;function xR(t,e,r){e.eachSeriesByType(t,function(h){var t=h.get("center"),e=h.get("radius");j(e)||(e=[0,e]),j(t)||(t=[t,t]);var n=r.getWidth(),i=r.getHeight(),c=Math.min(n,i),p=go(t[0],n),d=go(t[1],i),f=go(e[0],c/2),n=go(e[1],c/2),t=-h.get("startAngle")*vR,g=h.get("minAngle")*vR,y=h.getData().tree.root,i=h.getViewRoot(),m=i.depth,e=h.get("sort");null!=e&&function e(t,n){var i=t.children||[];t.children=_R(i,n),i.length&&G(t.children,function(t){e(t,n)})}(i,e);var o=0;G(i.children,function(t){isNaN(t.getValue())||o++});var v=i.getValue(),x=Math.PI/(v||o)*2,_=0<i.depth,e=i.height-(_?-1:1),b=(n-f)/(e||1),w=h.get("clockwise"),S=h.get("stillShowZeroSum"),M=w?1:-1,I=function(t,e){if(t){var n,i,o,r,a,s,l,u=e;return t!==y&&(r=t.getValue(),u=e+M*(n=(n=0===v&&S?x:r*x)<g?g:n),a=t.depth-m-(_?-1:1),i=f+b*a,o=f+b*(1+a),(s=h.getLevelModel(t))&&(r=s.get("r0",!0),a=s.get("r",!0),null!=(s=s.get("radius",!0))&&(r=s[0],a=s[1]),null!=r&&(i=go(r,c/2)),null!=a&&(o=go(a,c/2))),t.setLayout({angle:n,startAngle:e,endAngle:u,clockwise:w,cx:p,cy:d,r0:i,r:o})),t.children&&t.children.length&&(l=0,G(t.children,function(t){l+=I(t,e+l)})),u-e}};_&&(e=2*Math.PI,y.setLayout({angle:e,startAngle:t,endAngle:t+e,clockwise:w,cx:p,cy:d,r0:f,r:f+b})),I(i,t)})}function _R(e,n){if("function"==typeof n){var t=H(e,function(t,e){var n=t.getValue();return{params:{depth:t.depth,height:t.height,dataIndex:t.dataIndex,getValue:function(){return n}},index:e}});return t.sort(function(t,e){return n(t.params,e.params)}),H(t,function(t){return e[t.index]})}var i="asc"===n;return e.sort(function(t,e){var n=(t.getValue()-e.getValue())*(i?1:-1);return 0==n?(t.dataIndex-e.dataIndex)*(i?-1:1):n})}function bR(t){var r={};t.eachSeriesByType("sunburst",function(n){var i=n.getData(),o=i.tree;o.eachNode(function(t){var e=t.getModel().getModel("itemStyle").getItemStyle();e.fill||(e.fill=function(t,e,n){for(var i=t;i&&1<i.depth;)i=i.parentNode;return e=e.getColorFromPalette(i.name||i.dataIndex+"",r),e=1<t.depth&&"string"==typeof e?sn(e,(t.depth-1)/(n-1)*.5):e}(t,n,o.root.height)),N(i.ensureUniqueItemVisual(t.dataIndex,"style"),e)})})}var wR,SR={color:"fill",borderColor:"stroke"},MR={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},IR=Zo(),TR=(d(CR,wR=Gd),CR.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},CR.prototype.getInitialData=function(t,e){return w_(null,this)},CR.prototype.getDataParams=function(t,e,n){e=wR.prototype.getDataParams.call(this,t,e);return n&&(e.info=IR(n).info),e},CR.type="series.custom",CR.dependencies=["grid","polar","geo","singleAxis","calendar"],CR.defaultOption={coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,clip:!1},CR);function CR(){var t=null!==wR&&wR.apply(this,arguments)||this;return t.type=CR.type,t}function DR(i,o){return o=o||[0,0],H(["x","y"],function(t,e){var n=this.getAxis(t),t=o[e],e=i[e]/2;return"category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(t-e)-n.dataToCoord(t+e))},this)}function AR(r,a){return a=a||[0,0],H([0,1],function(t){var e=a[t],n=r[t]/2,i=[],o=[];return i[t]=e-n,o[t]=e+n,i[1-t]=o[1-t]=a[1-t],Math.abs(this.dataToPoint(i)[t]-this.dataToPoint(o)[t])},this)}function kR(t,e){var n=this.getAxis(),e=e instanceof Array?e[0]:e,t=(t instanceof Array?t[0]:t)/2;return"category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(e-t)-n.dataToCoord(e+t))}function LR(o,r){return r=r||[0,0],H(["Radius","Angle"],function(t,e){var n=this["get"+t+"Axis"](),i=r[e],e=o[e]/2,e="category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(i-e)-n.dataToCoord(i+e));return e="Angle"===t?e*Math.PI/180:e},this)}function PR(t,e,n,i){return t&&(t.legacy||!1!==t.legacy&&!n&&!i&&"tspan"!==e&&("text"===e||xt(t,"text")))}function OR(t,e,n){var i,o,r,a=t;return"text"===e?i=a:(i={},xt(a,"text")&&(i.text=a.text),xt(a,"rich")&&(i.rich=a.rich),xt(a,"textFill")&&(i.fill=a.textFill),xt(a,"textStroke")&&(i.stroke=a.textStroke),xt(a,"fontFamily")&&(i.fontFamily=a.fontFamily),xt(a,"fontSize")&&(i.fontSize=a.fontSize),xt(a,"fontStyle")&&(i.fontStyle=a.fontStyle),xt(a,"fontWeight")&&(i.fontWeight=a.fontWeight),o={type:"text",style:i,silent:!0},r={},e=xt(a,"textPosition"),n?r.position=e?a.textPosition:"inside":e&&(r.position=a.textPosition),xt(a,"textPosition")&&(r.position=a.textPosition),xt(a,"textOffset")&&(r.offset=a.textOffset),xt(a,"textRotation")&&(r.rotation=a.textRotation),xt(a,"textDistance")&&(r.distance=a.textDistance)),RR(i,t),G(i.rich,function(t){RR(t,t)}),{textConfig:r,textContent:o}}function RR(t,e){e&&(e.font=e.textFont||e.font,xt(e,"textStrokeWidth")&&(t.lineWidth=e.textStrokeWidth),xt(e,"textAlign")&&(t.align=e.textAlign),xt(e,"textVerticalAlign")&&(t.verticalAlign=e.textVerticalAlign),xt(e,"textLineHeight")&&(t.lineHeight=e.textLineHeight),xt(e,"textWidth")&&(t.width=e.textWidth),xt(e,"textHeight")&&(t.height=e.textHeight),xt(e,"textBackgroundColor")&&(t.backgroundColor=e.textBackgroundColor),xt(e,"textPadding")&&(t.padding=e.textPadding),xt(e,"textBorderColor")&&(t.borderColor=e.textBorderColor),xt(e,"textBorderWidth")&&(t.borderWidth=e.textBorderWidth),xt(e,"textBorderRadius")&&(t.borderRadius=e.textBorderRadius),xt(e,"textBoxShadowColor")&&(t.shadowColor=e.textBoxShadowColor),xt(e,"textBoxShadowBlur")&&(t.shadowBlur=e.textBoxShadowBlur),xt(e,"textBoxShadowOffsetX")&&(t.shadowOffsetX=e.textBoxShadowOffsetX),xt(e,"textBoxShadowOffsetY")&&(t.shadowOffsetY=e.textBoxShadowOffsetY))}function NR(t,e,n){var i=t;i.textPosition=i.textPosition||n.position||"inside",null!=n.offset&&(i.textOffset=n.offset),null!=n.rotation&&(i.textRotation=n.rotation),null!=n.distance&&(i.textDistance=n.distance);var o=0<=i.textPosition.indexOf("inside"),r=t.fill||"#000";zR(i,e);var a=null==i.textFill;return o?a&&(i.textFill=n.insideFill||"#fff",!i.textStroke&&n.insideStroke&&(i.textStroke=n.insideStroke),i.textStroke||(i.textStroke=r),null==i.textStrokeWidth&&(i.textStrokeWidth=2)):(a&&(i.textFill=t.fill||n.outsideFill||"#000"),!i.textStroke&&n.outsideStroke&&(i.textStroke=n.outsideStroke)),i.text=e.text,i.rich=e.rich,G(e.rich,function(t){zR(t,t)}),i}function zR(t,e){e&&(xt(e,"fill")&&(t.textFill=e.fill),xt(e,"stroke")&&(t.textStroke=e.fill),xt(e,"lineWidth")&&(t.textStrokeWidth=e.lineWidth),xt(e,"font")&&(t.font=e.font),xt(e,"fontStyle")&&(t.fontStyle=e.fontStyle),xt(e,"fontWeight")&&(t.fontWeight=e.fontWeight),xt(e,"fontSize")&&(t.fontSize=e.fontSize),xt(e,"fontFamily")&&(t.fontFamily=e.fontFamily),xt(e,"align")&&(t.textAlign=e.align),xt(e,"verticalAlign")&&(t.textVerticalAlign=e.verticalAlign),xt(e,"lineHeight")&&(t.textLineHeight=e.lineHeight),xt(e,"width")&&(t.textWidth=e.width),xt(e,"height")&&(t.textHeight=e.height),xt(e,"backgroundColor")&&(t.textBackgroundColor=e.backgroundColor),xt(e,"padding")&&(t.textPadding=e.padding),xt(e,"borderColor")&&(t.textBorderColor=e.borderColor),xt(e,"borderWidth")&&(t.textBorderWidth=e.borderWidth),xt(e,"borderRadius")&&(t.textBorderRadius=e.borderRadius),xt(e,"shadowColor")&&(t.textBoxShadowColor=e.shadowColor),xt(e,"shadowBlur")&&(t.textBoxShadowBlur=e.shadowBlur),xt(e,"shadowOffsetX")&&(t.textBoxShadowOffsetX=e.shadowOffsetX),xt(e,"shadowOffsetY")&&(t.textBoxShadowOffsetY=e.shadowOffsetY),xt(e,"textShadowColor")&&(t.textShadowColor=e.textShadowColor),xt(e,"textShadowBlur")&&(t.textShadowBlur=e.textShadowBlur),xt(e,"textShadowOffsetX")&&(t.textShadowOffsetX=e.textShadowOffsetX),xt(e,"textShadowOffsetY")&&(t.textShadowOffsetY=e.textShadowOffsetY))}var ER={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]};function VR(t,e,n){t=t[n],n=ER[n];t&&(e[n[0]]=t[0],e[n[1]]=t[1])}function BR(t,e,n){null!=t[n]&&(e[n]=t[n])}function FR(t,e,n){n&&(t[e]=n[e])}function GR(t,e,n,i,o){var r,a,s=n[t];if(s){var l=e[t],u=s.enterFrom;if(o&&u)for(var h=h||(i[t]={}),c=Y(u),p=0;p<c.length;p++){var d=c[p];h[d]=u[d]}if(!o&&l)if(s.transition){h=h||(i[t]={});for(var f=No(s.transition),p=0;p<f.length;p++){var g=l[d=f[p]];h[d]=g}}else if(0<=V(n.transition,t)){h=h||(i[t]={});var y=Y(l);for(p=0;p<y.length;p++)g=l[d=y[p]],r=s[d],a=g,(F(r)?r!==a:null!=r&&isFinite(r))&&(h[d]=g)}var m=s.leaveTo;if(m){var e=WR(e),v=e[t]||(e[t]={}),x=Y(m);for(p=0;p<x.length;p++)v[d=x[p]]=m[d]}}}function HR(t,e,n){var i=e[t];if(i)for(var o=n[t]={},r=Y(i),a=0;a<r.length;a++){var s=r[a];o[s]=wn(i[s])}}function WR(t){t=IR(t);return t.leaveToProps||(t.leaveToProps={})}Y({x:1,y:1,scaleX:1,scaleY:1,originX:1,originY:1,rotation:1}).join(", ");var UR="emphasis",YR="normal",Jn="blur",gr="select",XR=[YR,UR,Jn,gr],ZR={normal:["itemStyle"],emphasis:[UR,"itemStyle"],blur:[Jn,"itemStyle"],select:[gr,"itemStyle"]},jR={normal:["label"],emphasis:[UR,"label"],blur:[Jn,"label"],select:[gr,"label"]},qR="e\0\0",KR={normal:{},emphasis:{},blur:{},select:{}},JR={cartesian2d:function(e){var t=e.master.getRect();return{coordSys:{type:"cartesian2d",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(t){return e.dataToPoint(t)},size:X(DR,e)}}},geo:function(e){var t=e.getBoundingRect();return{coordSys:{type:"geo",x:t.x,y:t.y,width:t.width,height:t.height,zoom:e.getZoom()},api:{coord:function(t){return e.dataToPoint(t)},size:X(AR,e)}}},singleAxis:function(e){var t=e.getRect();return{coordSys:{type:"singleAxis",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(t){return e.dataToPoint(t)},size:X(kR,e)}}},polar:function(i){var o=i.getRadiusAxis(),r=i.getAngleAxis(),t=o.getExtent();return t[0]>t[1]&&t.reverse(),{coordSys:{type:"polar",cx:i.cx,cy:i.cy,r:t[1],r0:t[0]},api:{coord:function(t){var e=o.dataToRadius(t[0]),n=r.dataToAngle(t[1]),t=i.coordToPoint([e,n]);return t.push(e,n*Math.PI/180),t},size:X(LR,i)}}},calendar:function(n){var t=n.getRect(),e=n.getRangeInfo();return{coordSys:{type:"calendar",x:t.x,y:t.y,width:t.width,height:t.height,cellWidth:n.getCellWidth(),cellHeight:n.getCellHeight(),rangeInfo:{start:e.start,end:e.end,weeks:e.weeks,dayCount:e.allDay}},api:{coord:function(t,e){return n.dataToPoint(t,e)}}}}};function QR(t){return t instanceof as}function $R(t){return t instanceof Fr}var tN,eN=(d(nN,tN=$d),nN.prototype.render=function(n,t,i,o){var r=this._data,a=n.getData(),s=this.group,l=hN(n,a,t,i);r||s.removeAll(),a.diff(r).add(function(t){cN(i,null,t,l(t,o),n,s,a)}).remove(function(t){_N(r.getItemGraphicEl(t),n,s)}).update(function(t,e){e=r.getItemGraphicEl(e);cN(i,e,t,l(t,o),n,s,a)}).execute();t=n.get("clip",!0)?nb(n.coordinateSystem,!1,n):null;t?s.setClipPath(t):s.removeClipPath(),this._data=a},nN.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll(),this._data=null},nN.prototype.incrementalRender=function(t,e,n,i,o){var r=e.getData(),a=hN(e,r,n,i);function s(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}for(var l=t.start;l<t.end;l++){var u=cN(null,null,l,a(l,o),e,this.group,r);u&&u.traverse(s)}},nN.prototype.filterForExposedEvent=function(t,e,n,i){var o=e.element;if(null==o||n.name===o)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===o)return!0;return!1},nN.type="custom",nN);function nN(){var t=null!==tN&&tN.apply(this,arguments)||this;return t.type=nN.type,t}function iN(t){var e=t.type;if("path"===e){var n=t.shape,i=null!=n.width&&null!=n.height?{x:n.x||0,y:n.y||0,width:n.width,height:n.height}:null,o=bN(n),n=Ey(o,null,i,n.layout||"center");IR(n).customPathData=o}else if("image"===e)n=new ys({}),IR(n).customImagePath=t.style.image;else if("text"===e)n=new Fs({});else if("group"===e)n=new ro;else{if("compoundPath"===e)throw new Error('"compoundPath" is not supported yet.');o=zy(e);o||pc(""),n=new o}return IR(n).customGraphicType=e,n.name=t.name,n.z2EmphasisLift=1,n.z2SelectLift=1,n}function oN(t,e,n,i,o,r,a,s){o=o&&o.normal.cfg;o&&e.setTextConfig(o);o=i&&i.style;o&&("text"===e.type&&(xt(u=o,"textFill")&&(u.fill=u.textFill),xt(u,"textStroke")&&(u.stroke=u.textStroke)),l=void 0,h=QR(e)?o.decal:null,t&&h&&(h.dirty=!0,l=zm(h,t)),o.__decalPattern=l),IR(e).userDuring=i.during;var l,u={},h={};GR("shape",e,i,u,a),HR("shape",i,h),function(t,e,n,i){var o=e.enterFrom;if(i&&o)for(var r=Y(o),a=0;a<r.length;a++){var s=r[a];n[s]=o[s]}if(!i)if(e.transition)for(var l,u=No(e.transition),a=0;a<u.length;a++)"style"!==(s=u[a])&&"shape"!==s&&"extra"!==s&&(l=t[s],n[s]=l);else FR(n,"x",t),FR(n,"y",t);var h=e.leaveTo;if(h){var c=WR(t),p=Y(h);for(a=0;a<p.length;a++)c[s=p[a]]=h[s]}}(e,i,u,a),VR(t=i,l=h,"position"),VR(t,l,"scale"),VR(t,l,"origin"),BR(t,l,"x"),BR(t,l,"y"),BR(t,l,"scaleX"),BR(t,l,"scaleY"),BR(t,l,"originX"),BR(t,l,"originY"),BR(t,l,"rotation"),GR("extra",e,i,u,a),HR("extra",i,h),function(t,e,n,i,o){if(n){var r=t.style,a=n.enterFrom;if(o&&a)for(var s=Y(a),l=l||(i.style={}),u=0;u<s.length;u++){var h=s[u];l[h]=a[h]}if(!o&&r)if(n.transition){var c=No(n.transition);for(l=l||(i.style={}),u=0;u<c.length;u++){var p=r[h=c[u]];l[h]=p}}else if(t.getAnimationStyleProps&&0<=V(e.transition,"style")){var e=t.getAnimationStyleProps(),d=e?e.style:null;if(d){l=l||(i.style={});for(var f=Y(n),u=0;u<f.length;u++)d[h=f[u]]&&(p=r[h],l[h]=p)}}var g=n.leaveTo;if(g){var y=Y(g),t=WR(t),m=t.style||(t.style={});for(u=0;u<y.length;u++)m[h=y[u]]=g[h]}}}(e,i,o,u,a),h.style=o,function(t,e){var n=t.isGroup?null:t,i=e.style;if(n&&i){n.useStyle(i);var o=i.__decalPattern;o&&(n.style.decal=o);for(var r=n.animators,a=0;a<r.length;a++){var s=r[a];"style"===s.targetName&&s.changeTarget(n.style)}}e&&(e.style=null,e&&t.attr(e),e.style=i)}(e,h),function(t,e,n,i,o){{var r;i&&(r=IR(t).userDuring,r=r?X(sN,{el:t,userDuring:r}):null,(o?Ul:Wl)(t,i,n,{dataIndex:e,isFrom:!0,during:r}))}}(e,n,r,u,a),a=e,s=s,xt(i=i,"silent")&&(a.silent=i.silent),xt(i,"ignore")&&(a.ignore=i.ignore),$R(a)&&xt(i,"invisible")&&(a.invisible=i.invisible),QR(a)&&xt(i,"autoBatch")&&(a.autoBatch=i.autoBatch),s||xt(i,"info")&&(IR(a).info=i.info),o?e.dirty():e.markRedraw()}var rN={},aN={setTransform:function(t,e){return rN.el[t]=e,this},getTransform:function(t){return rN.el[t]},setShape:function(t,e){return(rN.el.shape||(rN.el.shape={}))[t]=e,rN.isShapeDirty=!0,this},getShape:function(t){var e=rN.el.shape;if(e)return e[t]},setStyle:function(t,e){var n=rN.el.style;return n&&(n[t]=e,rN.isStyleDirty=!0),this},getStyle:function(t){var e=rN.el.style;if(e)return e[t]},setExtra:function(t,e){return(rN.el.extra||(rN.el.extra={}))[t]=e,this},getExtra:function(t){var e=rN.el.extra;if(e)return e[t]}};function sN(){var t,e=this.el;e&&(IR(e).userDuring===(t=this.userDuring)?(rN.el=e,rN.isShapeDirty=!1,rN.isStyleDirty=!1,t(aN),rN.isShapeDirty&&e.dirtyShape&&e.dirtyShape(),rN.isStyleDirty&&e.dirtyStyle&&e.dirtyStyle()):this.el=this.userDuring=null)}function lN(t,e,n,i,o){var r=e.isGroup?null:e,e=o&&o[t].cfg;r&&(o=r.ensureState(t),!1===i?(t=r.getState(t))&&(t.style=null):o.style=i||null,e&&(o.textConfig=e),yl(r))}function uN(t,e,n){if(!t.isGroup){var i=t,t=n.currentZ,n=n.currentZLevel;i.z=t,i.zlevel=n;n=e.z2;null!=n&&(i.z2=n||0);for(var o=0;o<XR.length;o++)r=i,a=e,s=XR[o],l=void 0,null!=(a=(a=(l=s===YR)?a:gN(a,s))?a.z2:null)&&((l?r:r.ensureState(s)).z2=a||0)}var r,a,s,l}function hN(a,s,e,t){var n=a.get("renderItem"),i=a.coordinateSystem,o={};i&&(o=i.prepareCustoms?i.prepareCustoms(i):JR[i.type](i));for(var l,r,u,h,c=z({getWidth:t.getWidth,getHeight:t.getHeight,getZr:t.getZr,getDevicePixelRatio:t.getDevicePixelRatio,value:function(t,e){return null==e&&(e=l),s.getStore().get(s.getDimensionIndex(t||0),e)},style:function(t,e){null==e&&(e=l);var n=s.getItemVisual(e,"style"),i=n&&n.fill,o=n&&n.opacity,r=_(e,YR).getItemStyle();null!=i&&(r.fill=i),null!=o&&(r.opacity=o);n={inheritColor:K(i)?i:"#000"},o=b(e,YR),i=eu(o,null,n,!1,!0);i.text=o.getShallow("show")?rt(a.getFormattedLabel(e,YR),I_(s,e)):null;n=nu(o,n,!1);return S(t,r),r=NR(r,i,n),t&&w(r,t),r.legacy=!0,r},ordinalRawValue:function(t,e){null==e&&(e=l),t=t||0;var n=s.getDimensionInfo(t);if(!n){t=s.getDimensionIndex(t);return 0<=t?s.getStore().get(t,e):void 0}e=s.get(n.name,e),n=n&&n.ordinalMeta;return n?n.categories[e]:e},styleEmphasis:function(t,e){var n=_(e=null==e?l:e,UR).getItemStyle(),i=b(e,UR),o=eu(i,null,null,!0,!0);o.text=i.getShallow("show")?at(a.getFormattedLabel(e,UR),a.getFormattedLabel(e,YR),I_(s,e)):null;i=nu(i,null,!0);return S(t,n),n=NR(n,o,i),t&&w(n,t),n.legacy=!0,n},visual:function(t,e){if(null==e&&(e=l),xt(SR,t)){var n=s.getItemVisual(e,"style");return n?n[SR[t]]:null}if(xt(MR,t))return s.getItemVisual(e,t)},barLayout:function(t){if("cartesian2d"===i.type)return function(t){var e=[],n=t.axis;if("category"===n.type){for(var i=n.getBandWidth(),o=0;o<t.count;o++)e.push(z({bandWidth:i,axisKey:"axis0",stackId:wb+o},t));for(var r=Db(e),a=[],o=0;o<t.count;o++){var s=r.axis0[wb+o];s.offsetCenter=s.offset+s.width/2,a.push(s)}return a}}(z({axis:i.getBaseAxis()},t))},currentSeriesIndices:function(){return e.getCurrentSeriesIndices()},font:function(t){return su(t,e)}},o.api||{}),p={context:{},seriesId:a.id,seriesName:a.name,seriesIndex:a.seriesIndex,coordSys:o.coordSys,dataInsideLength:s.count(),encode:(u=a.getData(),h={},G(u.dimensions,function(t){var e,n=u.getDimensionInfo(t);n.isExtraCoord||(e=n.coordDim,(h[e]=h[e]||[])[n.coordDimIndex]=u.getDimensionIndex(t))}),h)},d={},f={},g={},y={},m=0;m<XR.length;m++){var v=XR[m];g[v]=a.getModel(ZR[v]),y[v]=a.getModel(jR[v])}function x(t){return t===l?r=r||s.getItemModel(t):s.getItemModel(t)}function _(t,e){return s.hasItemOption?t===l?d[e]||(d[e]=x(t).getModel(ZR[e])):x(t).getModel(ZR[e]):g[e]}function b(t,e){return s.hasItemOption?t===l?f[e]||(f[e]=x(t).getModel(jR[e])):x(t).getModel(jR[e]):y[e]}return function(t,e){return l=t,r=null,d={},f={},n&&n(z({dataIndexInside:t,dataIndex:s.getRawIndex(t),actionType:e?e.type:null},p),c)};function w(t,e){for(var n in e)xt(e,n)&&(t[n]=e[n])}function S(t,e){t&&(t.textFill&&(e.textFill=t.textFill),t.textPosition&&(e.textPosition=t.textPosition))}}function cN(t,e,n,i,o,r,a){if(i){o=pN(t,e,n,i,o,r);return o&&a.setItemGraphicEl(n,o),o&&Ll(o,i.focus,i.blurScope),o}r.remove(e)}function pN(t,e,n,i,o,r){var a=-1,s=e;e&&dN(e,i,o)&&(a=V(r.childrenRef(),e),e=null);var l,u,h,c,p=!e,d=e;d?d.clearStates():(d=iN(i),s&&(h=s,(c=d).copyTransform(h),$R(c)&&$R(h)&&(c.setStyle(h.style),c.z=h.z,c.z2=h.z2,c.zlevel=h.zlevel,c.invisible=h.invisible,c.ignore=h.ignore,QR(c)&&QR(h)&&c.setShape(h.shape)))),!1===i.morph?d.disableMorphing=!0:d.disableMorphing&&(d.disableMorphing=!1),KR.normal.cfg=KR.normal.conOpt=KR.emphasis.cfg=KR.emphasis.conOpt=KR.blur.cfg=KR.blur.conOpt=KR.select.cfg=KR.select.conOpt=null,KR.isLegacy=!1,function(t,e,n,i,o,r){if(!t.isGroup){fN(n,null,r),fN(n,UR,r);var a=r.normal.conOpt,s=r.emphasis.conOpt,l=r.blur.conOpt,n=r.select.conOpt;if(null!=a||null!=s||null!=n||null!=l){var u=t.getTextContent();if(!1===a)u&&t.removeTextContent();else{a=r.normal.conOpt=a||{type:"text"},u?u.clearStates():(u=iN(a),t.setTextContent(u)),oN(null,u,e,a,null,i,o,!0);for(var o=a&&a.style,h=0;h<XR.length;h++){var c,p=XR[h];p!==YR&&(c=r[p].conOpt,lN(p,u,0,yN(a,c,p),null))}o?u.dirty():u.markRedraw()}}}}(d,n,i,o,p,KR),l=d,u=n,e=o,s=p,!1===(h=(c=i).clipPath)?l&&l.getClipPath()&&l.removeClipPath():h&&((c=(c=l.getClipPath())&&dN(c,h,e)?null:c)||(c=iN(h),l.setClipPath(c)),oN(null,c,u,h,null,e,s,!1)),oN(t,d,n,i,KR,o,p,!1);for(var f=0;f<XR.length;f++){var g=XR[f];g!==YR&&lN(g,d,0,yN(i,gN(i,g),g),KR)}return uN(d,i,o),"group"===i.type&&function(t,e,n,i,o){var r=i.children,a=r?r.length:0,s=i.$mergeChildren,i="byName"===s||i.diffChildrenByName,s=!1===s;if(a||i||s)if(i)!function(t){new Vx(t.oldChildren,t.newChildren,mN,mN,t).add(vN).update(vN).remove(xN).execute()}({api:t,oldChildren:e.children()||[],newChildren:r||[],dataIndex:n,seriesModel:o,group:e});else{s&&e.removeAll();for(var l=0;l<a;l++)r[l]&&pN(t,e.childAt(l),n,r[l],o,e);for(var u=e.childCount()-1;l<=u;u--)_N(e.childAt(u),o,e)}}(t,d,n,i,o),0<=a?r.replaceAt(d,a):r.add(d),d}function dN(t,e,n){var i=IR(t),o=e.type,t=e.shape,e=e.style;return n.isUniversalTransitionEnabled()||null!=o&&o!==i.customGraphicType||"path"===o&&((n=t)&&(xt(n,"pathData")||xt(n,"d")))&&bN(t)!==i.customPathData||"image"===o&&xt(e,"image")&&e.image!==i.customImagePath}function fN(t,e,n){var i,o=e?gN(t,e):t,r=e?yN(t,o,UR):t.style,a=t.type,o=o?o.textConfig:null,t=t.textContent,t=t?e?gN(t,e):t:null;r&&(n.isLegacy||PR(r,a,!!o,!!t))&&(n.isLegacy=!0,i=OR(r,a,!e),!o&&i.textConfig&&(o=i.textConfig),!t&&i.textContent&&(t=i.textContent)),!e&&t&&((i=t).type||(i.type="text"));n=e?n[e]:n.normal;n.cfg=o,n.conOpt=t}function gN(t,e){return e?t?t[e]:null:t}function yN(t,e,n){e=e&&e.style;return e=null==e&&n===UR&&t?t.styleEmphasis:e}function mN(t,e){t=t&&t.name;return null!=t?t:qR+e}function vN(t,e){var n=this.context,t=null!=t?n.newChildren[t]:null,e=null!=e?n.oldChildren[e]:null;pN(n.api,e,n.dataIndex,t,n.seriesModel,n.group)}function xN(t){var e=this.context;_N(e.oldChildren[t],e.seriesModel,e.group)}function _N(t,e,n){var i;t&&((i=IR(t).leaveToProps)?Wl(t,i,e,{cb:function(){n.remove(t)}}):n.remove(t))}function bN(t){return t&&(t.pathData||t.d)}var wN=Zo(),SN=P,MN=X;function IN(){this._dragging=!1,this.animationThreshold=15}function TN(t,e,n,i){!function n(i,t){if($(i)&&$(t)){var o=!0;return G(t,function(t,e){o=o&&n(i[e],t)}),!!o}return i===t}(wN(n).lastProp,i)&&(wN(n).lastProp=i,e?Wl(n,i,t):(n.stopAnimation(),n.attr(i)))}function CN(t,e){t[e.get(["label","show"])?"show":"hide"]()}function DN(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function AN(t,e,n){var i=e.get("z"),o=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=o&&(t.zlevel=o),t.silent=n)})}IN.prototype.render=function(t,e,n,i){var o=e.get("value"),r=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==o||this._lastStatus!==r){this._lastValue=o,this._lastStatus=r;var a=this._group,i=this._handle;if(!r||"hide"===r)return a&&a.hide(),void(i&&i.hide());a&&a.show(),i&&i.show();r={};this.makeElOption(r,o,t,e,n);i=r.graphicKey;i!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=i;i=this._moveAnimation=this.determineAnimation(t,e);a?(i=Z(TN,e,i),this.updatePointerEl(a,r,i),this.updateLabelEl(a,r,i,e)):(a=this._group=new ro,this.createPointerEl(a,r,t,e),this.createLabelEl(a,r,t,e),n.getZr().add(a)),AN(a,e,!0),this._renderHandle(o)}},IN.prototype.remove=function(t){this.clear(t)},IN.prototype.dispose=function(t){this.clear(t)},IN.prototype.determineAnimation=function(t,e){var n=e.get("animation"),i=t.axis,o="category"===i.type,e=e.get("snap");if(!e&&!o)return!1;if("auto"!==n&&null!=n)return!0===n;n=this.animationThreshold;if(o&&i.getBandWidth()>n)return!0;if(e){t=YM(t).seriesDataCount,i=i.getExtent();return Math.abs(i[0]-i[1])/t>n}return!1},IN.prototype.makeElOption=function(t,e,n,i,o){},IN.prototype.createPointerEl=function(t,e,n,i){var o=e.pointer;o&&(e=wN(t).pointerEl=new p[o.type](SN(e.pointer)),t.add(e))},IN.prototype.createLabelEl=function(t,e,n,i){e.label&&(e=wN(t).labelEl=new Fs(SN(e.label)),t.add(e),CN(e,i))},IN.prototype.updatePointerEl=function(t,e,n){t=wN(t).pointerEl;t&&e.pointer&&(t.setStyle(e.pointer.style),n(t,{shape:e.pointer.shape}))},IN.prototype.updateLabelEl=function(t,e,n,i){t=wN(t).labelEl;t&&(t.setStyle(e.label.style),n(t,{x:e.label.x,y:e.label.y}),CN(t,i))},IN.prototype._renderHandle=function(t){if(!this._dragging&&this.updateHandleTransform){var e,n=this._axisPointerModel,i=this._api.getZr(),o=this._handle,r=n.getModel("handle"),a=n.get("status");if(!r.get("show")||!a||"hide"===a)return o&&i.remove(o),void(this._handle=null);this._handle||(e=!0,o=this._handle=Qy(r.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){re(t.event)},onmousedown:MN(this._onHandleDragMove,this,0,0),drift:MN(this._onHandleDragMove,this),ondragend:MN(this._onHandleDragEnd,this)}),i.add(o)),AN(o,n,!1),o.setStyle(r.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));n=r.get("size");j(n)||(n=[n,n]),o.scaleX=n[0]/2,o.scaleY=n[1]/2,rf(this,"_doDispatchAxisPointer",r.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,e)}},IN.prototype._moveHandleToValue=function(t,e){TN(this._axisPointerModel,!e&&this._moveAnimation,this._handle,DN(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},IN.prototype._onHandleDragMove=function(t,e){var n=this._handle;n&&(this._dragging=!0,e=this.updateHandleTransform(DN(n),[t,e],this._axisModel,this._axisPointerModel),this._payloadInfo=e,n.stopAnimation(),n.attr(DN(e)),wN(n).lastProp=null,this._doDispatchAxisPointer())},IN.prototype._doDispatchAxisPointer=function(){var t,e;this._handle&&(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}]}))},IN.prototype._onHandleDragEnd=function(){var t;this._dragging=!1,this._handle&&(t=this._axisPointerModel.get("value"),this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"}))},IN.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,t=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),t&&e.remove(t),this._group=null,this._handle=null,this._payloadInfo=null)},IN.prototype.doClear=function(){},IN.prototype.buildLabel=function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}},C=IN;function kN(t){var e,n=t.get("type"),t=t.getModel(n+"Style");return"line"===n?(e=t.getLineStyle()).fill=null:"shadow"===n&&((e=t.getAreaStyle()).stroke=null),e}function LN(t,e,n,i,o){var r=PN(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=lh(a.get("padding")||0),l=a.getFont(),u=Bi(r,l),h=o.position,c=u.width+s[1]+s[3],n=u.height+s[0]+s[2],u=o.align;"right"===u&&(h[0]-=c),"center"===u&&(h[0]-=c/2);u=o.verticalAlign;"bottom"===u&&(h[1]-=n),"middle"===u&&(h[1]-=n/2),o=h,u=c,c=n,i=(n=i).getWidth(),n=n.getHeight(),o[0]=Math.min(o[0]+u,i)-u,o[1]=Math.min(o[1]+c,n)-c,o[0]=Math.max(o[0],0),o[1]=Math.max(o[1],0);o=a.get("backgroundColor");o&&"auto"!==o||(o=e.get(["axisLine","lineStyle","color"])),t.label={x:h[0],y:h[1],style:eu(a,{text:r,font:l,fill:a.getTextColor(),padding:s,backgroundColor:o}),z2:10}}function PN(t,e,n,i,o){t=e.scale.parse(t);var r,a=e.scale.getLabel({value:t},{precision:o.precision}),o=o.formatter;return o&&(r={value:tM(e,{value:t}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]},G(i,function(t){var e=n.getSeriesByIndex(t.seriesIndex),t=t.dataIndexInside,t=e&&e.getDataParams(t);t&&r.seriesData.push(t)}),K(o)?a=o.replace("{value}",a):q(o)&&(a=o(r))),a}function ON(t,e,n){var i=ni();return si(i,i,n.rotation),ai(i,i,n.position),Xy([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function RN(t,e,n,i,o,r){var a=HM.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=o.get(["label","margin"]),LN(e,i,o,r,{position:ON(i.axis,t,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function NN(t,e,n){return{x1:t[n=n||0],y1:t[1-n],x2:e[n],y2:e[1-n]}}function zN(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}function EN(t,e,n,i,o,r){return{cx:t,cy:e,r0:n,r:i,startAngle:o,endAngle:r,clockwise:!0}}var VN,mu=(d(BN,VN=C),BN.prototype.makeElOption=function(t,e,n,i,o){var r,a=n.axis,s=a.grid,l=i.get("type"),u=FN(s,a).getOtherAxis(a).getGlobalExtent(),h=a.toGlobalCoord(a.dataToCoord(e,!0));l&&"none"!==l&&(r=kN(i),(u=GN[l](a,h,u)).style=r,t.graphicKey=u.type,t.pointer=u),RN(e,t,TM(s.model,n),n,i,o)},BN.prototype.getHandleTransform=function(t,e,n){var i=TM(e.axis.grid.model,e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);t=ON(e.axis,t,i);return{x:t[0],y:t[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},BN.prototype.updateHandleTransform=function(t,e,n,i){var o=n.axis,r=o.grid,a=o.getGlobalExtent(!0),n=FN(r,o).getOtherAxis(o).getGlobalExtent(),r="x"===o.dim?0:1,o=[t.x,t.y];o[r]+=e[r],o[r]=Math.min(a[1],o[r]),o[r]=Math.max(a[0],o[r]);n=(n[1]+n[0])/2,n=[n,n];n[r]=o[r];return{x:o[0],y:o[1],rotation:t.rotation,cursorPoint:n,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][r]}},BN);function BN(){return null!==VN&&VN.apply(this,arguments)||this}function FN(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var GN={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:NN([e,n[0]],[e,n[1]],HN(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),o=n[1]-n[0];return{type:"Rect",shape:zN([e-i/2,n[0]],[i,o],HN(t))}}};function HN(t){return"x"===t.dim?0:1}var WN,UN=mu,YN=(d(jN,WN=Vh),jN.type="axisPointer",jN.defaultOption={show:"auto",zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},jN),XN=Zo(),ZN=G;function jN(){var t=null!==WN&&WN.apply(this,arguments)||this;return t.type=jN.type,t}function qN(t,e,n){var i,c,p;function o(t,h){c.on(t,function(e){var n,i,t,o,r,a,s,l=(n=p,{dispatchAction:u,pendings:i={showTip:[],hideTip:[]}});function u(t){var e=i[t.type];e?e.push(t):(t.dispatchAction=u,n.dispatchAction(t))}ZN(XN(c).records,function(t){t&&h(t,e,l.dispatchAction)}),o=p,a=(t=l.pendings).showTip.length,s=t.hideTip.length,a?r=t.showTip[a-1]:s&&(r=t.hideTip[s-1]),r&&(r.dispatchAction=null,o.dispatchAction(r))})}w.node||(i=e.getZr(),XN(i).records||(XN(i).records={}),p=e,XN(c=i).initialized||(XN(c).initialized=!0,o("click",Z(JN,"click")),o("mousemove",Z(JN,"mousemove")),o("globalout",KN)),(XN(i).records[t]||(XN(i).records[t]={})).handler=n)}function KN(t,e,n){t.handler("leave",null,n)}function JN(t,e,n,i){e.handler(t,n,i)}function QN(t,e){w.node||(e=e.getZr(),(XN(e).records||{})[t]&&(XN(e).records[t]=null))}var $N,tz=(d(ez,$N=Wd),ez.prototype.render=function(t,e,n){var e=e.getComponent("tooltip"),i=t.get("triggerOn")||e&&e.get("triggerOn")||"mousemove|click";qN("axisPointer",n,function(t,e,n){"none"!==i&&("leave"===t||0<=i.indexOf(t))&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},ez.prototype.remove=function(t,e){QN("axisPointer",e)},ez.prototype.dispose=function(t,e){QN("axisPointer",e)},ez.type="axisPointer",ez);function ez(){var t=null!==$N&&$N.apply(this,arguments)||this;return t.type=ez.type,t}function nz(t,e){var n=[],i=t.seriesIndex;if(null==i||!(a=e.getSeriesByIndex(i)))return{point:[]};var o=a.getData(),r=Xo(o,t);if(null==r||r<0||j(r))return{point:[]};var a,s=o.getItemGraphicEl(r),e=a.coordinateSystem;return a.getTooltipPosition?n=a.getTooltipPosition(r)||[]:e&&e.dataToPoint?n=t.isStacked?(i=e.getBaseAxis(),a=e.getOtherAxis(i).dim,t=i.dim,i="x"===a||"radius"===a?1:0,a=o.mapDimension(t),(t=[])[i]=o.get(a,r),t[1-i]=o.get(o.getCalculationInfo("stackResultDimension"),r),e.dataToPoint(t)||[]):e.dataToPoint(o.getValues(H(e.dimensions,function(t){return o.mapDimension(t)}),r))||[]:s&&((r=s.getBoundingRect().clone()).applyTransform(s.transform),n=[r.x+r.width/2,r.y+r.height/2]),{point:n,el:s}}var iz=Zo();function oz(t,e,n){var i,o,r=t.currTrigger,a=[t.x,t.y],s=t,l=t.dispatchAction||X(n.dispatchAction,n),u=e.getComponent("axisPointer").coordSysAxesInfo;if(u){uz(a)&&(a=nz({seriesIndex:s.seriesIndex,dataIndex:s.dataIndex},e).point);var h=uz(a),c=s.axesInfo,p=u.axesInfo,d="leave"===r||uz(a),f={},g={},s={list:[],map:{}},y={showPointer:Z(az,g),showTooltip:Z(sz,s)};G(u.coordSysMap,function(t,e){var o=h||t.containPoint(a);G(u.coordSysAxesInfo[e],function(t,e){var n=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}}(c,t);d||!o||c&&!i||null!=(i=null==(i=i&&i.value)&&!h?n.pointToData(a):i)&&rz(t,i,y,!1,f)})});var m={};return G(p,function(n,t){var i=n.linkGroup;i&&!g[t]&&G(i.axesInfo,function(t,e){var e=g[e];t!==n&&e&&(e=e.value,i.mapper&&(e=n.axis.scale.parse(i.mapper(e,lz(t),lz(n)))),m[n.key]=e)})}),G(m,function(t,e){rz(p[e],t,y,!0,f)}),i=g,r=p,o=f.axesInfo=[],G(r,function(t,e){var n=t.axisPointerModel.option,e=i[e];e?(t.useHandle||(n.status="show"),n.value=e.value,n.seriesDataIndices=(e.payloadBatch||[]).slice()):t.useHandle||(n.status="hide"),"show"===n.status&&o.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:n.value})}),function(t,e,n,i){{var o;!uz(e)&&t.list.length?(o=((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:o.dataIndexInside,dataIndex:o.dataIndex,seriesIndex:o.seriesIndex,dataByCoordSys:t.list})):i({type:"hideTip"})}}(s,a,t,l),function(t,e){var n=e.getZr(),i="axisPointerLastHighlights",o=iz(n)[i]||{},r=iz(n)[i]={};G(t,function(t,e){t=t.axisPointerModel.option;"show"===t.status&&G(t.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;r[e]=t})});var a=[],s=[];G(o,function(t,e){r[e]||s.push(t)}),G(r,function(t,e){o[e]||a.push(t)}),s.length&&e.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:s}),a.length&&e.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:a})}(p,n),f}}function rz(t,e,n,i,o){var r,a,s,l,u,h,c,p,d,f,g=t.axis;!g.scale.isBlank()&&g.containData(e)&&(t.involveSeries?(s=(r=(l=e,u=t.axis,h=u.dim,c=l,p=[],d=Number.MAX_VALUE,f=-1,G(t.seriesModels,function(e,t){var n=e.getData().mapDimensionsAll(h);if(e.getAxisTooltipData)var i=e.getAxisTooltipData(n,l,u),o=i.dataIndices,r=i.nestestValue;else{if(!(o=e.getData().indicesOfNearest(n[0],l,"category"===u.type?.5:null)).length)return;r=e.getData().get(n[0],o[0])}null!=r&&isFinite(r)&&(i=l-r,(n=Math.abs(i))<=d&&((n<d||0<=i&&f<0)&&(d=n,f=i,c=r,p.length=0),G(o,function(t){p.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})})))}),{payloadBatch:p,snapToValue:c})).snapToValue,(a=r.payloadBatch)[0]&&null==o.seriesIndex&&N(o,a[0]),!i&&t.snap&&g.containData(s)&&null!=s&&(e=s),n.showPointer(t,e,a),n.showTooltip(t,r,s)):n.showPointer(t,e))}function az(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function sz(t,e,n,i){var o,r=n.payloadBatch,a=e.axis,s=a.model,l=e.axisPointerModel;e.triggerTooltip&&r.length&&(n=ZM(o=e.coordSys.model),(e=t.map[n])||(e=t.map[n]={coordSysId:o.id,coordSysIndex:o.componentIndex,coordSysType:o.type,coordSysMainType:o.mainType,dataByAxis:[]},t.list.push(e)),e.dataByAxis.push({axisDim:a.dim,axisIndex:s.componentIndex,axisType:s.type,axisId:s.id,value:i,valueLabelOpt:{precision:l.get(["label","precision"]),formatter:l.get(["label","formatter"])},seriesDataIndices:r.slice()}))}function lz(t){var e=t.axis.model,n={},t=n.axisDim=t.axis.dim;return n.axisIndex=n[t+"AxisIndex"]=e.componentIndex,n.axisName=n[t+"AxisName"]=e.name,n.axisId=n[t+"AxisId"]=e.id,n}function uz(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function hz(t){KM.registerAxisPointerClass("CartesianAxisPointer",UN),t.registerComponentModel(YN),t.registerComponentView(tz),t.registerPreprocessor(function(t){var e;t&&(t.axisPointer&&0!==t.axisPointer.length||(t.axisPointer={}),(e=t.axisPointer.link)&&!j(e)&&(t.axisPointer.link=[e]))}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=WM(t,e)}),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},oz)}var cz,io=(d(pz,cz=C),pz.prototype.makeElOption=function(t,e,n,i,o){var r=n.axis;"angle"===r.dim&&(this.animationThreshold=Math.PI/18);var a,s=r.polar,l=s.getOtherAxis(r).getExtent(),u=r.dataToCoord(e),h=i.get("type");h&&"none"!==h&&(a=kN(i),(c=gz[h](r,s,u,l)).style=a,t.graphicKey=c.type,t.pointer=c);var c=i.get(["label","margin"]);LN(t,n,i,o,function(t,e,n,i){var o=e.axis,r=o.dataToCoord(t);l=(l=n.getAngleAxis().getExtent()[0])/180*Math.PI;var a,t=n.getRadiusAxis().getExtent();{var s,l,u;u="radius"===o.dim?(si(s=ni(),s,l),ai(s,s,[n.cx,n.cy]),a=Xy([r,-i],s),s=e.getModel("axisLabel").get("rotate")||0,l=HM.innerTextLayout(l,s*Math.PI/180,-1),s=l.textAlign,l.textVerticalAlign):(t=t[1],a=n.coordToPoint([t+i,r]),r=n.cx,u=n.cy,s=Math.abs(a[0]-r)/t<.3?"center":a[0]>r?"left":"right",Math.abs(a[1]-u)/t<.3?"middle":a[1]>u?"top":"bottom")}return{position:a,align:s,verticalAlign:u}}(e,n,s,c))},pz);function pz(){return null!==cz&&cz.apply(this,arguments)||this}var dz,fz,gz={line:function(t,e,n,i){return"angle"===t.dim?{type:"Line",shape:NN(e.coordToPoint([i[0],n]),e.coordToPoint([i[1],n]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:n}}},shadow:function(t,e,n,i){var o=Math.max(1,t.getBandWidth()),r=Math.PI/180;return"angle"===t.dim?{type:"Sector",shape:EN(e.cx,e.cy,i[0],i[1],(-n-o/2)*r,(o/2-n)*r)}:{type:"Sector",shape:EN(e.cx,e.cy,n-o/2,n+o/2,0,2*Math.PI)}}},yz=io,mz=(d(xz,fz=Vh),xz.prototype.findAxisModel=function(t){var e;return this.ecModel.eachComponent(t,function(t){t.getCoordSysModel()===this&&(e=t)},this),e},xz.type="polar",xz.dependencies=["radiusAxis","angleAxis"],xz.defaultOption={zlevel:0,z:0,center:["50%","50%"],radius:"80%"},xz),Jn=(d(vz,dz=Vh),vz.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Jo).models[0]},vz.type="polarAxis",vz);function vz(){return null!==dz&&dz.apply(this,arguments)||this}function xz(){var t=null!==fz&&fz.apply(this,arguments)||this;return t.type=xz.type,t}B(Jn,qw);var _z,bz,wz,Sz=(d(Cz,wz=Jn),Cz.type="angleAxis",Cz),Mz=(d(Tz,bz=Jn),Tz.type="radiusAxis",Tz),gr=(d(Iz,_z=_),Iz.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},Iz);function Iz(t,e){return _z.call(this,"radius",t,e)||this}function Tz(){var t=null!==bz&&bz.apply(this,arguments)||this;return t.type=Tz.type,t}function Cz(){var t=null!==wz&&wz.apply(this,arguments)||this;return t.type=Cz.type,t}gr.prototype.dataToRadius=_.prototype.dataToCoord,gr.prototype.radiusToData=_.prototype.coordToData;var Dz,Az=gr,kz=Zo(),mu=(d(Lz,Dz=_),Lz.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},Lz.prototype.calculateCategoryInterval=function(){var t=this.getLabelModel(),e=this.scale,n=e.getExtent(),i=e.count();if(n[1]-n[0]<1)return 0;var o=n[0],e=this.dataToCoord(o+1)-this.dataToCoord(o),n=Math.abs(e),e=Bi(null==o?"":o+"",t.getFont(),"center","top"),o=Math.max(e.height,7)/n;isNaN(o)&&(o=1/0);t=Math.max(0,Math.floor(o)),e=kz(this.model),n=e.lastAutoInterval,o=e.lastTickCount;return null!=n&&null!=o&&Math.abs(n-t)<=1&&Math.abs(o-i)<=1&&t<n?t=n:(e.lastTickCount=i,e.lastAutoInterval=t),t},Lz);function Lz(t,e){return Dz.call(this,"angle",t,e||[0,360])||this}mu.prototype.dataToAngle=_.prototype.dataToCoord,mu.prototype.angleToData=_.prototype.coordToData;var Pz=mu,Oz=["radius","angle"];function Rz(t){this.dimensions=Oz,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new Az,this._angleAxis=new Pz,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}function Nz(t){var e=t.seriesModel,t=t.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var zz=(Rz.prototype.containPoint=function(t){t=this.pointToCoord(t);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},Rz.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},Rz.prototype.getAxis=function(t){return this["_"+t+"Axis"]},Rz.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},Rz.prototype.getAxesByScale=function(t){var e=[],n=this._angleAxis,i=this._radiusAxis;return n.scale.type===t&&e.push(n),i.scale.type===t&&e.push(i),e},Rz.prototype.getAngleAxis=function(){return this._angleAxis},Rz.prototype.getRadiusAxis=function(){return this._radiusAxis},Rz.prototype.getOtherAxis=function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},Rz.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},Rz.prototype.getTooltipAxes=function(t){t=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},Rz.prototype.dataToPoint=function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},Rz.prototype.pointToData=function(t,e){t=this.pointToCoord(t);return[this._radiusAxis.radiusToData(t[0],e),this._angleAxis.angleToData(t[1],e)]},Rz.prototype.pointToCoord=function(t){var e=t[0]-this.cx,n=t[1]-this.cy,i=this.getAngleAxis(),t=i.getExtent(),o=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]);i.inverse?o=r-360:r=o+360;i=Math.sqrt(e*e+n*n);e/=i,n/=i;for(var a=Math.atan2(-n,e)/Math.PI*180,s=a<o?1:-1;a<o||r<a;)a+=360*s;return[i,a]},Rz.prototype.coordToPoint=function(t){var e=t[0],t=t[1]/180*Math.PI;return[Math.cos(t)*e+this.cx,-Math.sin(t)*e+this.cy]},Rz.prototype.getArea=function(){var t=this.getAngleAxis(),e=this.getRadiusAxis().getExtent().slice();e[0]>e[1]&&e.reverse();var n=t.getExtent(),i=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:e[0],r:e[1],startAngle:-n[0]*i,endAngle:-n[1]*i,clockwise:t.inverse,contain:function(t,e){var n=t-this.cx,t=e-this.cy,e=n*n+t*t,n=this.r,t=this.r0;return e<=n*n&&t*t<=e}}},Rz.prototype.convertToPixel=function(t,e,n){return Nz(e)===this?this.dataToPoint(n):null},Rz.prototype.convertFromPixel=function(t,e,n){return Nz(e)===this?this.pointToData(n):null},Rz);function Ez(t,e){var n,i=this,o=i.getAngleAxis(),r=i.getRadiusAxis();o.scale.setExtent(1/0,-1/0),r.scale.setExtent(1/0,-1/0),t.eachSeries(function(t){var e;t.coordinateSystem===i&&(G(oM(e=t.getData(),"radius"),function(t){r.scale.unionExtentFromData(e,t)}),G(oM(e,"angle"),function(t){o.scale.unionExtentFromData(e,t)}))}),JS(o.scale,o.model),JS(r.scale,r.model),"category"!==o.type||o.onBand||(n=o.getExtent(),t=360/o.scale.count(),o.inverse?n[1]+=t:n[1]-=t,o.setExtent(n[0],n[1]))}function Vz(t,e){var n;t.type=e.get("type"),t.scale=QS(e),t.onBand=e.get("boundaryGap")&&"category"===t.type,t.inverse=e.get("inverse"),"angleAxis"===e.mainType&&(t.inverse=t.inverse!==e.get("clockwise"),n=e.get("startAngle"),t.setExtent(n,n+(t.inverse?-360:360))),(e.axis=t).model=e}var Bz={dimensions:Oz,create:function(t,s){var l=[];return t.eachComponent("polar",function(t,e){var n=new zz(e+"");n.update=Ez;var i=n.getRadiusAxis(),o=n.getAngleAxis(),r=t.findAxisModel("radiusAxis"),a=t.findAxisModel("angleAxis");Vz(i,r),Vz(o,a),e=n,i=s,o=(r=t).get("center"),a=i.getWidth(),i=i.getHeight(),e.cx=go(o[0],a),e.cy=go(o[1],i),e=e.getRadiusAxis(),i=Math.min(a,i)/2,null==(r=r.get("radius"))?r=[0,"100%"]:j(r)||(r=[0,r]),i=[go(r[0],i),go(r[1],i)],e.inverse?e.setExtent(i[1],i[0]):e.setExtent(i[0],i[1]),l.push(n),(t.coordinateSystem=n).model=t}),t.eachSeries(function(t){var e;"polar"===t.get("coordinateSystem")&&(e=t.getReferringComponents("polar",Jo).models[0],t.coordinateSystem=e.coordinateSystem)}),l}},Fz=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Gz(t,e,n){e[1]>e[0]&&(e=e.slice().reverse());var i=t.coordToPoint([e[0],n]),n=t.coordToPoint([e[1],n]);return{x1:i[0],y1:i[1],x2:n[0],y2:n[1]}}function Hz(t){return t.getRadiusAxis().inverse?0:1}function Wz(t){var e=t[0],n=t[t.length-1];e&&n&&Math.abs(Math.abs(e.coord-n.coord)-360)<1e-4&&t.pop()}var Uz,Yz,io=(d(Qz,Yz=KM),Qz.prototype.render=function(e,t){var n,i,o,r,a,s;this.group.removeAll(),e.get("show")&&(n=e.axis,i=n.polar,o=i.getRadiusAxis().getExtent(),r=n.getTicksCoords(),a=n.getMinorTicksCoords(),Wz(s=H(n.getViewLabels(),function(t){t=P(t);var e=n.scale,e="ordinal"===e.type?e.getRawOrdinalNumber(t.tickValue):t.tickValue;return t.coord=n.dataToCoord(e),t})),Wz(r),G(Fz,function(t){!e.get([t,"show"])||n.scale.isBlank()&&"axisLine"!==t||Xz[t](this.group,e,i,r,a,o,s)},this))},Qz.type="angleAxis",Qz),Xz={axisLine:function(t,e,n,i,o,r){var a=e.getModel(["axisLine","lineStyle"]),s=Hz(n),e=s?0:1,a=0===r[e]?new $f({shape:{cx:n.cx,cy:n.cy,r:r[s]},style:a.getLineStyle(),z2:1,silent:!0}):new Xg({shape:{cx:n.cx,cy:n.cy,r:r[s],r0:r[e]},style:a.getLineStyle(),z2:1,silent:!0});a.style.fill=null,t.add(a)},axisTick:function(t,e,n,i,o,r){var a=e.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=r[Hz(n)],i=H(i,function(t){return new Kf({shape:Gz(n,[l,l+s],t.coord)})});t.add(Fy(i,{style:z(a.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(t,e,n,i,o,r){if(o.length){for(var a=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(a.get("inside")?-1:1)*s.get("length"),u=r[Hz(n)],h=[],c=0;c<o.length;c++)for(var p=0;p<o[c].length;p++)h.push(new Kf({shape:Gz(n,[u,u+l],o[c][p].coord)}));t.add(Fy(h,{style:z(s.getModel("lineStyle").getLineStyle(),z(a.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(l,u,h,t,e,c,n){var p=u.getCategories(!0),d=u.getModel("axisLabel"),f=d.get("margin"),g=u.get("triggerEvent");G(n,function(t,e){var n=d,i=t.tickValue,o=c[Hz(h)],r=h.coordToPoint([o+f,t.coord]),a=h.cx,s=h.cy,a=Math.abs(r[0]-a)/o<.3?"center":r[0]>a?"left":"right",s=Math.abs(r[1]-s)/o<.3?"middle":r[1]>s?"top":"bottom";p&&p[i]&&($(i=p[i])&&i.textStyle&&(n=new wu(i.textStyle,d,d.ecModel)));a=new Fs({silent:HM.isLabelSilent(u),style:eu(n,{x:r[0],y:r[1],fill:n.getTextColor()||u.get(["axisLine","lineStyle","color"]),text:t.formattedLabel,align:a,verticalAlign:s})});l.add(a),g&&((s=HM.makeAxisEventDataBase(u)).targetType="axisLabel",s.value=t.rawLabel,Gs(a).eventData=s)},this)},splitLine:function(t,e,n,i,o,r){for(var a=e.getModel("splitLine").getModel("lineStyle"),s=0,l=(l=a.get("color"))instanceof Array?l:[l],u=[],h=0;h<i.length;h++){var c=s++%l.length;u[c]=u[c]||[],u[c].push(new Kf({shape:Gz(n,r,i[h].coord)}))}for(h=0;h<u.length;h++)t.add(Fy(u[h],{style:z({stroke:l[h%l.length]},a.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(t,e,n,i,o,r){if(o.length){for(var a=e.getModel("minorSplitLine").getModel("lineStyle"),s=[],l=0;l<o.length;l++)for(var u=0;u<o[l].length;u++)s.push(new Kf({shape:Gz(n,r,o[l][u].coord)}));t.add(Fy(s,{style:a.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(t,e,n,i,o,r){if(i.length){for(var a=e.getModel("splitArea").getModel("areaStyle"),s=0,l=(l=a.get("color"))instanceof Array?l:[l],u=[],h=Math.PI/180,c=-i[0].coord*h,p=Math.min(r[0],r[1]),d=Math.max(r[0],r[1]),f=e.get("clockwise"),g=1,y=i.length;g<=y;g++){var m=(g===y?i[0]:i[g]).coord,v=s++%l.length;u[v]=u[v]||[],u[v].push(new Wg({shape:{cx:n.cx,cy:n.cy,r0:p,r:d,startAngle:c,endAngle:-m*h,clockwise:f},silent:!0})),c=-m*h}for(g=0;g<u.length;g++)t.add(Fy(u[g],{style:z({fill:l[g%l.length]},a.getAreaStyle()),silent:!0}))}}},Zz=io,jz=["axisLine","axisTickLabel","axisName"],qz=["splitLine","splitArea","minorSplitLine"],Jn=(d(Jz,Uz=KM),Jz.prototype.render=function(e,t){var n,i,o,r,a,s,l,u,h;this.group.removeAll(),e.get("show")&&(n=this._axisGroup,i=this._axisGroup=new ro,this.group.add(i),o=e.axis,h=(r=o.polar).getAngleAxis(),a=o.getTicksCoords(),s=o.getMinorTicksCoords(),l=h.getExtent()[0],u=o.getExtent(),h={position:[r.cx,r.cy],rotation:l/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1},h=new HM(e,h),G(jz,h.add,h),i.add(h.getGroup()),qy(n,i,e),G(qz,function(t){e.get([t,"show"])&&!o.scale.isBlank()&&Kz[t](this.group,e,r,l,u,a,s)},this))},Jz.type="radiusAxis",Jz),Kz={splitLine:function(t,e,n,i,o,r){for(var a=e.getModel("splitLine").getModel("lineStyle"),s=0,l=(l=a.get("color"))instanceof Array?l:[l],u=[],h=0;h<r.length;h++){var c=s++%l.length;u[c]=u[c]||[],u[c].push(new $f({shape:{cx:n.cx,cy:n.cy,r:r[h].coord}}))}for(h=0;h<u.length;h++)t.add(Fy(u[h],{style:z({stroke:l[h%l.length],fill:null},a.getLineStyle()),silent:!0}))},minorSplitLine:function(t,e,n,i,o,r,a){if(a.length){for(var e=e.getModel("minorSplitLine").getModel("lineStyle"),s=[],l=0;l<a.length;l++)for(var u=0;u<a[l].length;u++)s.push(new $f({shape:{cx:n.cx,cy:n.cy,r:a[l][u].coord}}));t.add(Fy(s,{style:z({fill:null},e.getLineStyle()),silent:!0}))}},splitArea:function(t,e,n,i,o,r){if(r.length){for(var a=e.getModel("splitArea").getModel("areaStyle"),s=0,l=(l=a.get("color"))instanceof Array?l:[l],u=[],h=r[0].coord,c=1;c<r.length;c++){var p=s++%l.length;u[p]=u[p]||[],u[p].push(new Wg({shape:{cx:n.cx,cy:n.cy,r0:h,r:r[c].coord,startAngle:0,endAngle:2*Math.PI},silent:!0})),h=r[c].coord}for(c=0;c<u.length;c++)t.add(Fy(u[c],{style:z({fill:l[c%l.length]},a.getAreaStyle()),silent:!0}))}}};function Jz(){var t=null!==Uz&&Uz.apply(this,arguments)||this;return t.type=Jz.type,t.axisPointerClass="PolarAxisPointer",t}function Qz(){var t=null!==Yz&&Yz.apply(this,arguments)||this;return t.type=Qz.type,t.axisPointerClass="PolarAxisPointer",t}var $z=Jn;function t5(t){return t.get("stack")||"__ec_stack_"+t.seriesIndex}function e5(t,e){return e.dim+t.model.componentIndex}function n5(t,e,n){var k={},L=function(t){var l={};G(t,function(t,e){var n=t.getData(),i=t.coordinateSystem,o=i.getBaseAxis(),r=e5(i,o),a=o.getExtent(),s="category"===o.type?o.getBandWidth():Math.abs(a[1]-a[0])/n.count(),i=l[r]||{bandWidth:s,remainedWidth:s,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},o=i.stacks;l[r]=i;a=t5(t);o[a]||i.autoWidthCount++,o[a]=o[a]||{width:0,maxWidth:0};n=go(t.get("barWidth"),s),r=go(t.get("barMaxWidth"),s),s=t.get("barGap"),t=t.get("barCategoryGap");n&&!o[a].width&&(n=Math.min(i.remainedWidth,n),o[a].width=n,i.remainedWidth-=n),r&&(o[a].maxWidth=r),null!=s&&(i.gap=s),null!=t&&(i.categoryGap=t)});var c={};return G(l,function(t,n){c[n]={};var e=t.stacks,i=t.bandWidth,i=go(t.categoryGap,i),o=go(t.gap,1),r=t.remainedWidth,a=t.autoWidthCount,s=(r-i)/(a+(a-1)*o),s=Math.max(s,0);G(e,function(t,e){var n=t.maxWidth;n&&n<s&&(n=Math.min(n,r),t.width&&(n=Math.min(n,t.width)),r-=n,t.width=n,a--)}),s=(r-i)/(a+(a-1)*o),s=Math.max(s,0);var l,u=0;G(e,function(t,e){t.width||(t.width=s),u+=(l=t).width*(1+o)}),l&&(u-=l.width*o);var h=-u/2;G(e,function(t,e){c[n][e]=c[n][e]||{offset:h,width:t.width},h+=t.width*(1+o)})}),c}(U(e.getSeriesByType(t),function(t){return!e.isSeriesFiltered(t)&&t.coordinateSystem&&"polar"===t.coordinateSystem.type}));e.eachSeriesByType(t,function(t){if("polar"===t.coordinateSystem.type){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),o=e5(n,i),r=t5(t),o=L[o][r],a=o.offset,s=o.width,l=n.getOtherAxis(i),u=t.coordinateSystem.cx,h=t.coordinateSystem.cy,c=t.get("barMinHeight")||0,p=t.get("barMinAngle")||0;k[r]=k[r]||[];for(var d=e.mapDimension(l.dim),f=e.mapDimension(i.dim),g=v_(e,d),y="radius"!==i.dim||!t.get("roundCap",!0),m=l.dataToCoord(0),v=0,x=e.count();v<x;v++){var _=e.get(d,v),b=e.get(f,v),w=0<=_?"p":"n",S=m;g&&(k[r][b]||(k[r][b]={p:m,n:m}),S=k[r][b][w]);var M,I,T=void 0,C=void 0,D=void 0,A=void 0;"radius"===l.dim?(M=l.dataToCoord(_)-m,I=i.dataToCoord(b),C=(T=S)+(M=Math.abs(M)<c?(M<0?-1:1)*c:M),A=(D=I-a)-s,g&&(k[r][b][w]=C)):(_=l.dataToCoord(_,y)-m,C=(T=i.dataToCoord(b)+a)+s,A=(D=S)+(_=Math.abs(_)<p?(_<0?-1:1)*p:_),g&&(k[r][b][w]=A)),e.setItemLayout(v,{cx:u,cy:h,r0:T,r:C,startAngle:-D*Math.PI/180,endAngle:-A*Math.PI/180,clockwise:A<=D})}}})}var i5,o5={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},r5={splitNumber:5},a5=(d(s5,i5=Wd),s5.type="polar",s5);function s5(){var t=null!==i5&&i5.apply(this,arguments)||this;return t.type=s5.type,t}function l5(t,e){e=e||{};var n=t.coordinateSystem,i=t.axis,o={},r=i.position,a=i.orient,i=n.getRect(),n=[i.x,i.x+i.width,i.y,i.y+i.height],i={horizontal:{top:n[2],bottom:n[3]},vertical:{left:n[0],right:n[1]}};o.position=["vertical"===a?i.vertical[r]:n[0],"horizontal"===a?i.horizontal[r]:n[3]];o.rotation=Math.PI/2*{horizontal:0,vertical:1}[a];o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,right:1,left:-1}[r],t.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),ot(e.labelInside,t.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection);e=e.rotate;return null==e&&(e=t.get(["axisLabel","rotate"])),o.labelRotation="top"===r?-e:e,o.z2=1,o}var u5,h5,c5=["axisLine","axisTickLabel","axisName"],p5=["splitArea","splitLine"],gr=(d(y5,h5=KM),y5.prototype.render=function(e,t,n,i){var o=this.group;o.removeAll();var r=this._axisGroup;this._axisGroup=new ro;var a=l5(e),a=new HM(e,a);G(c5,a.add,a),o.add(this._axisGroup),o.add(a.getGroup()),G(p5,function(t){e.get([t,"show"])&&d5[t](this,this.group,this._axisGroup,e)},this),qy(r,this._axisGroup,e),h5.prototype.render.call(this,e,t,n,i)},y5.prototype.remove=function(){tI(this)},y5.type="singleAxis",y5),d5={splitLine:function(t,e,n,i){var o=i.axis;if(!o.scale.isBlank()){for(var r=i.getModel("splitLine"),a=r.getModel("lineStyle"),s=(s=a.get("color"))instanceof Array?s:[s],l=i.coordinateSystem.getRect(),u=o.isHorizontal(),h=[],c=0,p=o.getTicksCoords({tickModel:r}),d=[],f=[],g=0;g<p.length;++g){var y=o.toGlobalCoord(p[g].coord);u?(d[0]=y,d[1]=l.y,f[0]=y,f[1]=l.y+l.height):(d[0]=l.x,d[1]=y,f[0]=l.x+l.width,f[1]=y);y=c++%s.length;h[y]=h[y]||[],h[y].push(new Kf({subPixelOptimize:!0,shape:{x1:d[0],y1:d[1],x2:f[0],y2:f[1]},silent:!0}))}for(var m=a.getLineStyle(["color"]),g=0;g<h.length;++g)e.add(Fy(h[g],{style:z({stroke:s[g%s.length]},m),silent:!0}))}},splitArea:function(t,e,n,i){$M(t,n,i,i)}},f5=gr,mu=(d(g5,u5=Vh),g5.prototype.getCoordSysModel=function(){return this},g5.type="singleAxis",g5.layoutMode="box",g5.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}}},g5);function g5(){var t=null!==u5&&u5.apply(this,arguments)||this;return t.type=g5.type,t}function y5(){var t=null!==h5&&h5.apply(this,arguments)||this;return t.type=y5.type,t.axisPointerClass="SingleAxisPointer",t}B(mu,qw.prototype);var m5,v5=mu,x5=(d(w5,m5=_),w5.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},w5.prototype.pointToData=function(t,e){return this.coordinateSystem.pointToData(t)[0]},w5),_5=["single"];function b5(t,e,n){this.type="single",this.dimension="single",this.dimensions=_5,this.axisPointerEnabled=!0,this.model=t,this._init(t,e,n)}function w5(t,e,n,i,o){n=m5.call(this,t,e,n)||this;return n.type=i||"value",n.position=o||"bottom",n}function S5(t){var e=t.seriesModel,t=t.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var M5=(b5.prototype._init=function(t,e,n){var i=this.dimension,o=new x5(i,QS(t),[0,0],t.get("type"),t.get("position")),i="category"===o.type;o.onBand=i&&t.get("boundaryGap"),o.inverse=t.get("inverse"),o.orient=t.get("orient"),(t.axis=o).model=t,(o.coordinateSystem=this)._axis=o},b5.prototype.update=function(t,e){t.eachSeries(function(t){var e;t.coordinateSystem===this&&(G((e=t.getData()).mapDimensionsAll(this.dimension),function(t){this._axis.scale.unionExtentFromData(e,t)},this),JS(this._axis.scale,this._axis.model))},this)},b5.prototype.resize=function(t,e){this._rect=Sh({left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")},{width:e.getWidth(),height:e.getHeight()}),this._adjustAxis()},b5.prototype.getRect=function(){return this._rect},b5.prototype._adjustAxis=function(){var t=this._rect,e=this._axis,n=e.isHorizontal(),i=n?[0,t.width]:[0,t.height],o=e.reverse?1:0;e.setExtent(i[o],i[1-o]),this._updateAxisTransform(e,n?t.x:t.y)},b5.prototype._updateAxisTransform=function(t,e){var n=t.getExtent(),i=n[0]+n[1],n=t.isHorizontal();t.toGlobalCoord=n?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord=n?function(t){return t-e}:function(t){return i-t+e}},b5.prototype.getAxis=function(){return this._axis},b5.prototype.getBaseAxis=function(){return this._axis},b5.prototype.getAxes=function(){return[this._axis]},b5.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},b5.prototype.containPoint=function(t){var e=this.getRect(),n=this.getAxis();return"horizontal"===n.orient?n.contain(n.toLocalCoord(t[0]))&&t[1]>=e.y&&t[1]<=e.y+e.height:n.contain(n.toLocalCoord(t[1]))&&t[0]>=e.y&&t[0]<=e.y+e.height},b5.prototype.pointToData=function(t){var e=this.getAxis();return[e.coordToData(e.toLocalCoord(t["horizontal"===e.orient?0:1]))]},b5.prototype.dataToPoint=function(t){var e=this.getAxis(),n=this.getRect(),i=[],o="horizontal"===e.orient?0:1;return t instanceof Array&&(t=t[0]),i[o]=e.toGlobalCoord(e.dataToCoord(+t)),i[1-o]=0==o?n.y+n.height/2:n.x+n.width/2,i},b5.prototype.convertToPixel=function(t,e,n){return S5(e)===this?this.dataToPoint(n):null},b5.prototype.convertFromPixel=function(t,e,n){return S5(e)===this?this.pointToData(n):null},b5);var I5,T5={create:function(i,o){var r=[];return i.eachComponent("singleAxis",function(t,e){var n=new M5(t,i,o);n.name="single_"+e,n.resize(t,o),t.coordinateSystem=n,r.push(n)}),i.eachSeries(function(t){var e;"singleAxis"===t.get("coordinateSystem")&&(e=t.getReferringComponents("singleAxis",Jo).models[0],t.coordinateSystem=e&&e.coordinateSystem)}),r},dimensions:_5},C5=["x","y"],D5=["width","height"],io=(d(k5,I5=C),k5.prototype.makeElOption=function(t,e,n,i,o){var r=n.axis,a=r.coordinateSystem,s=P5(a,1-L5(r)),l=a.dataToPoint(e)[0],u=i.get("type");u&&"none"!==u&&(a=kN(i),(s=A5[u](r,l,s)).style=a,t.graphicKey=s.type,t.pointer=s),RN(e,t,l5(n),n,i,o)},k5.prototype.getHandleTransform=function(t,e,n){var i=l5(e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);t=ON(e.axis,t,i);return{x:t[0],y:t[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},k5.prototype.updateHandleTransform=function(t,e,n,i){var o=n.axis,r=o.coordinateSystem,a=L5(o),n=P5(r,a),o=[t.x,t.y];o[a]+=e[a],o[a]=Math.min(n[1],o[a]),o[a]=Math.max(n[0],o[a]);r=P5(r,1-a),r=(r[1]+r[0])/2,r=[r,r];return r[a]=o[a],{x:o[0],y:o[1],rotation:t.rotation,cursorPoint:r,tooltipOption:{verticalAlign:"middle"}}},k5),A5={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:NN([e,n[0]],[e,n[1]],L5(t))}},shadow:function(t,e,n){var i=t.getBandWidth(),o=n[1]-n[0];return{type:"Rect",shape:zN([e-i/2,n[0]],[i,o],L5(t))}}};function k5(){return null!==I5&&I5.apply(this,arguments)||this}function L5(t){return t.isHorizontal()?0:1}function P5(t,e){t=t.getRect();return[t[C5[e]],t[C5[e]]+t[D5[e]]]}var O5,R5,N5=io,z5=(d(E5,O5=Wd),E5.type="single",E5);function E5(){var t=null!==O5&&O5.apply(this,arguments)||this;return t.type=E5.type,t}function V5(){var t=null!==R5&&R5.apply(this,arguments)||this;return t.type=V5.type,t}function B5(t,i){var e=t.cellSize,o=j(e)?e:t.cellSize=[e,e];1===o.length&&(o[1]=o[0]);e=H([0,1],function(t){return(null!=(e=i)[_h[n=t][0]]||null!=e[_h[n][1]]&&null!=e[_h[n][2]])&&(o[t]="auto"),null!=o[t]&&"auto"!==o[t];var e,n});Th(t,i,{type:"box",ignoreSize:e})}var F5,G5=(d(V5,R5=Vh),V5.prototype.init=function(t,e,n){var i=Ch(t);R5.prototype.init.apply(this,arguments),B5(t,i)},V5.prototype.mergeOption=function(t){R5.prototype.mergeOption.apply(this,arguments),B5(this.option,t)},V5.prototype.getCellSize=function(){return this.option.cellSize},V5.type="calendar",V5.defaultOption={zlevel:0,z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},V5),H5=(d(U5,F5=Wd),U5.prototype.render=function(t,e,n){var i=this.group;i.removeAll();var o=t.coordinateSystem,r=o.getRangeInfo(),o=o.getOrient(),e=e.getLocaleModel();this._renderDayRect(t,r,i),this._renderLines(t,r,o,i),this._renderYearText(t,r,o,i),this._renderMonthText(t,e,o,i),this._renderWeekText(t,e,r,o,i)},U5.prototype._renderDayRect=function(t,e,n){for(var i=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),r=i.getCellWidth(),a=i.getCellHeight(),s=e.start.time;s<=e.end.time;s=i.getNextNDay(s,1).time){var l=i.dataToRect([s],!1).tl,l=new Ts({shape:{x:l[0],y:l[1],width:r,height:a},cursor:"default",style:o});n.add(l)}},U5.prototype._renderLines=function(e,t,n,i){var o=this,r=e.coordinateSystem,a=e.getModel(["splitLine","lineStyle"]).getLineStyle(),s=e.get(["splitLine","show"]),l=a.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var u=t.start,h=0;u.time<=t.end.time;h++){p(u.formatedDate);var c=(u=0===h?r.getDateInfo(t.start.y+"-"+t.start.m):u).date;c.setMonth(c.getMonth()+1),u=r.getDateInfo(c)}function p(t){o._firstDayOfMonth.push(r.getDateInfo(t)),o._firstDayPoints.push(r.dataToRect([t],!1).tl);t=o._getLinePointsOfOneWeek(e,t,n);o._tlpoints.push(t[0]),o._blpoints.push(t[t.length-1]),s&&o._drawSplitline(t,a,i)}p(r.getNextNDay(t.end.time,1).formatedDate),s&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,l,n),a,i),s&&this._drawSplitline(o._getEdgesPoints(o._blpoints,l,n),a,i)},U5.prototype._getEdgesPoints=function(t,e,n){t=[t[0].slice(),t[t.length-1].slice()],n="horizontal"===n?0:1;return t[0][n]=t[0][n]-e/2,t[1][n]=t[1][n]+e/2,t},U5.prototype._drawSplitline=function(t,e,n){e=new ny({z2:20,shape:{points:t},style:e});n.add(e)},U5.prototype._getLinePointsOfOneWeek=function(t,e,n){for(var i=t.coordinateSystem,o=i.getDateInfo(e),r=[],a=0;a<7;a++){var s=i.getNextNDay(o.time,a),l=i.dataToRect([s.time],!1);r[2*s.day]=l.tl,r[2*s.day+1]=l["horizontal"===n?"bl":"tr"]}return r},U5.prototype._formatterLabel=function(t,e){return"string"==typeof t&&t?(n=t,G(e,function(t,e){n=n.replace("{"+e+"}",i?ch(t):t)}),n):"function"==typeof t?t(e):e.nameMap;var n,i},U5.prototype._yearTextPositionControl=function(t,e,n,i,o){var r=e[0],a=e[1],e=["center","bottom"];"bottom"===i?(a+=o,e=["center","top"]):"left"===i?r-=o:"right"===i?(r+=o,e=["center","top"]):a-=o;o=0;return{rotation:o="left"===i||"right"===i?Math.PI/2:o,x:r,y:a,style:{align:e[0],verticalAlign:e[1]}}},U5.prototype._renderYearText=function(t,e,n,i){var o,r,a,s,l,u=t.getModel("yearLabel");u.get("show")&&(o=u.get("margin"),r=(r=u.get("position"))||("horizontal"!==n?"top":"left"),a=((s=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]])[0][0]+s[1][0])/2,l=(s[0][1]+s[1][1])/2,s={top:[a,s[t="horizontal"===n?0:1][1]],bottom:[a,s[1-t][1]],left:[s[1-t][0],l],right:[s[t][0],l]},t=e.start.y,+e.end.y>+e.start.y&&(t=t+"-"+e.end.y),l=u.get("formatter"),t={start:e.start.y,end:e.end.y,nameMap:t},t=this._formatterLabel(l,t),(t=new Fs({z2:30,style:eu(u,{text:t})})).attr(this._yearTextPositionControl(t,s[r],n,r,o)),i.add(t))},U5.prototype._monthTextPositionControl=function(t,e,n,i,o){var r="left",a="top",s=t[0],t=t[1];return"horizontal"===n?(t+=o,e&&(r="center"),"start"===i&&(a="bottom")):(s+=o,e&&(a="middle"),"start"===i&&(r="right")),{x:s,y:t,align:r,verticalAlign:a}},U5.prototype._renderMonthText=function(t,e,n,i){var o=t.getModel("monthLabel");if(o.get("show")){var r=o.get("nameMap"),a=o.get("margin"),s=o.get("position"),t=o.get("align"),l=[this._tlpoints,this._blpoints];r&&!K(r)||(r=(e=r?Ou(r)||e:e).get(["time","monthAbbr"])||[]);for(var u="start"===s?0:1,h="horizontal"===n?0:1,a="start"===s?-a:a,c="center"===t,p=0;p<l[u].length-1;p++){var d=l[u][p].slice(),f=this._firstDayOfMonth[p];c&&(y=this._firstDayPoints[p],d[h]=(y[h]+l[0][p+1][h])/2);var g=o.get("formatter"),y=r[+f.m-1],y={yyyy:f.y,yy:(f.y+"").slice(2),MM:f.m,M:+f.m,nameMap:y},y=this._formatterLabel(g,y),d=new Fs({z2:30,style:N(eu(o,{text:y}),this._monthTextPositionControl(d,c,n,s,a))});i.add(d)}}},U5.prototype._weekTextPositionControl=function(t,e,n,i,o){var r="center",a="middle",s=t[0],t=t[1],n="start"===n;return"horizontal"===e?(s=s+i+(n?1:-1)*o[0]/2,r=n?"right":"left"):(t=t+i+(n?1:-1)*o[1]/2,a=n?"bottom":"top"),{x:s,y:t,align:r,verticalAlign:a}},U5.prototype._renderWeekText=function(t,e,n,i,o){var r=t.getModel("dayLabel");if(r.get("show")){var a=t.coordinateSystem,s=r.get("position"),l=r.get("nameMap"),u=r.get("margin"),h=a.getFirstDayOfWeek();l&&!K(l)||(l=(e=l?Ou(l)||e:e).get(["time","dayOfWeekShort"])||H(e.get(["time","dayOfWeekAbbr"]),function(t){return t[0]}));var c=a.getNextNDay(n.end.time,7-n.lweek).time,p=[a.getCellWidth(),a.getCellHeight()],u=go(u,Math.min(p[1],p[0]));"start"===s&&(c=a.getNextNDay(n.start.time,-(7+n.fweek)).time,u=-u);for(var d=0;d<7;d++){var f=a.getNextNDay(c,d),g=a.dataToRect([f.time],!1).center,f=Math.abs((d+h)%7),g=new Fs({z2:30,style:N(eu(r,{text:l[f]}),this._weekTextPositionControl(g,i,s,u,p))});o.add(g)}}},U5.type="calendar",U5);function W5(t,e,n){this.type="calendar",this.dimensions=W5.dimensions,this.getDimensionsInfo=W5.getDimensionsInfo,this._model=t}function U5(){var t=null!==F5&&F5.apply(this,arguments)||this;return t.type=U5.type,t}function Y5(t){var e=t.calendarModel,t=t.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem:null}var X5=(W5.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},W5.prototype.getRangeInfo=function(){return this._rangeInfo},W5.prototype.getModel=function(){return this._model},W5.prototype.getRect=function(){return this._rect},W5.prototype.getCellWidth=function(){return this._sw},W5.prototype.getCellHeight=function(){return this._sh},W5.prototype.getOrient=function(){return this._orient},W5.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},W5.prototype.getDateInfo=function(t){var e=(t=Mo(t)).getFullYear(),n=t.getMonth()+1,i=n<10?"0"+n:""+n,o=t.getDate(),n=o<10?"0"+o:""+o,o=t.getDay();return{y:e+"",m:i,d:n,day:o=Math.abs((o+7-this.getFirstDayOfWeek())%7),time:t.getTime(),formatedDate:e+"-"+i+"-"+n,date:t}},W5.prototype.getNextNDay=function(t,e){return 0===(e=e||0)||(t=new Date(this.getDateInfo(t).time)).setDate(t.getDate()+e),this.getDateInfo(t)},W5.prototype.update=function(t,e){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var n=this._rangeInfo.weeks||1,i=["width","height"],o=this._model.getCellSize().slice(),r=this._model.getBoxLayoutParams(),a="horizontal"===this._orient?[n,7]:[7,n];G([0,1],function(t){l(o,t)&&(r[i[t]]=o[t]*a[t])});var e={width:e.getWidth(),height:e.getHeight()},s=this._rect=Sh(r,e);function l(t,e){return null!=t[e]&&"auto"!==t[e]}G([0,1],function(t){l(o,t)||(o[t]=s[i[t]]/a[t])}),this._sw=o[0],this._sh=o[1]},W5.prototype.dataToPoint=function(t,e){j(t)&&(t=t[0]),null==e&&(e=!0);var n=this.getDateInfo(t),i=this._rangeInfo,t=n.formatedDate;if(e&&!(n.time>=i.start.time&&n.time<i.end.time+864e5))return[NaN,NaN];n=n.day,t=this._getRangeInfo([i.start.time,t]).nthWeek;return"vertical"===this._orient?[this._rect.x+n*this._sw+this._sw/2,this._rect.y+t*this._sh+this._sh/2]:[this._rect.x+t*this._sw+this._sw/2,this._rect.y+n*this._sh+this._sh/2]},W5.prototype.pointToData=function(t){t=this.pointToDate(t);return t&&t.time},W5.prototype.dataToRect=function(t,e){e=this.dataToPoint(t,e);return{contentShape:{x:e[0]-(this._sw-this._lineWidth)/2,y:e[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},center:e,tl:[e[0]-this._sw/2,e[1]-this._sh/2],tr:[e[0]+this._sw/2,e[1]-this._sh/2],br:[e[0]+this._sw/2,e[1]+this._sh/2],bl:[e[0]-this._sw/2,e[1]+this._sh/2]}},W5.prototype.pointToDate=function(t){var e=Math.floor((t[0]-this._rect.x)/this._sw)+1,n=Math.floor((t[1]-this._rect.y)/this._sh)+1,t=this._rangeInfo.range;return"vertical"===this._orient?this._getDateByWeeksAndDay(n,e-1,t):this._getDateByWeeksAndDay(e,n-1,t)},W5.prototype.convertToPixel=function(t,e,n){e=Y5(e);return e===this?e.dataToPoint(n):null},W5.prototype.convertFromPixel=function(t,e,n){e=Y5(e);return e===this?e.pointToData(n):null},W5.prototype.containPoint=function(t){return!1},W5.prototype._initRangeOption=function(){var t,e,n,i,o=this._model.get("range");if(j(o)&&1===o.length&&(o=o[0]),j(o)?i=o:(t=o.toString(),/^\d{4}$/.test(t)&&(i=[t+"-01-01",t+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(t)&&((n=(e=this.getDateInfo(t)).date).setMonth(n.getMonth()+1),n=this.getNextNDay(n,-1),i=[e.formatedDate,n.formatedDate]),/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(t)&&(i=[t,t])),!i)return o;o=this._getRangeInfo(i);return o.start.time>o.end.time&&i.reverse(),i},W5.prototype._getRangeInfo=function(t){var e,n=[this.getDateInfo(t[0]),this.getDateInfo(t[1])];n[0].time>n[1].time&&(e=!0,n.reverse());var i,o=Math.floor(n[1].time/864e5)-Math.floor(n[0].time/864e5)+1,r=new Date(n[0].time),a=r.getDate(),s=n[1].date.getDate();if(r.setDate(a+o-1),(i=r.getDate())!==s)for(var l=0<r.getTime()-n[1].time?1:-1;(i=r.getDate())!==s&&0<(r.getTime()-n[1].time)*l;)o-=l,r.setDate(i-l);t=Math.floor((o+n[0].day+6)/7),a=e?1-t:t-1;return e&&n.reverse(),{range:[n[0].formatedDate,n[1].formatedDate],start:n[0],end:n[1],allDay:o,weeks:t,nthWeek:a,fweek:n[0].day,lweek:n[1].day}},W5.prototype._getDateByWeeksAndDay=function(t,e,n){n=this._getRangeInfo(n);if(t>n.weeks||0===t&&e<n.fweek||t===n.weeks&&e>n.lweek)return null;t=7*(t-1)-n.fweek+e,e=new Date(n.start.time);return e.setDate(+n.start.d+t),this.getDateInfo(e)},W5.create=function(t,e){var n=[];return t.eachComponent("calendar",function(t){var e=new W5(t);n.push(e),t.coordinateSystem=e}),t.eachSeries(function(t){"calendar"===t.get("coordinateSystem")&&(t.coordinateSystem=n[t.get("calendarIndex")||0])}),n},W5.dimensions=["time","value"],W5);function Z5(t){var e=t.graphic;j(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])}var j5,q5,K5=Zo(),J5={path:null,compoundPath:null,group:ro,image:ys,text:Fs},Q5=(d(eE,q5=Vh),eE.prototype.mergeOption=function(t,e){var n=this.option.elements;this.option.elements=null,q5.prototype.mergeOption.call(this,t,e),this.option.elements=n},eE.prototype.optionUpdated=function(t,e){var n=this.option,t=(e?n:t).elements,l=n.elements=e?[]:n.elements,n=[];this._flatten(t,n,null);var n=Bo(l,n,"normalMerge"),u=this._elOptionsToUpdate=[];G(n,function(t,e){var n,i,o,r,a,s=t.newOption;s&&(u.push(s),function(t,e){var n=t.existing;e.id=t.keyInfo.id,!e.type&&n&&(e.type=n.type),null==e.parentId&&((t=e.parentOption)?e.parentId=t.id:n&&(e.parentId=n.parentId));e.parentOption=null}(t,s),n=l,i=e,r=N({},o=s),a=n[i],"merge"===(t=o.$action||"merge")?a?(O(a,r,!0),Th(a,r,{ignoreSize:!0}),Dh(o,a)):n[i]=r:"replace"===t?n[i]=r:"remove"===t&&a&&(n[i]=null),e=l[e],s=s,e&&(e.hv=s.hv=[oE(s,["left","right"]),oE(s,["top","bottom"])],"group"===e.type)&&(s=s,null==(e=e).width&&(e.width=s.width=0),null==e.height&&(e.height=s.height=0)))},this);for(var i=l.length-1;0<=i;i--)null==l[i]?l.splice(i,1):delete l[i].$action},eE.prototype._flatten=function(t,n,i){G(t,function(t){var e;t&&(i&&(t.parentOption=i),n.push(t),e=t.children,"group"===t.type&&e&&this._flatten(e,n,t),delete t.children)},this)},eE.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},eE.type="graphic",eE.defaultOption={elements:[]},eE),$5=(d(tE,j5=Wd),tE.prototype.init=function(){this._elMap=yt()},tE.prototype.render=function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},tE.prototype._updateElements=function(c){var p,d,t=c.useElOptionsToUpdate();t&&(p=this._elMap,d=this.group,G(t,function(t){var e=Ho(t.id,null),n=null!=e?p.get(e):null,i=Ho(t.parentId,null),o=null!=i?p.get(i):d,r=t.type,a=t.style;"text"===r&&a&&t.hv&&t.hv[1]&&(a.textVerticalAlign=a.textBaseline=a.verticalAlign=a.align=null);var s=t.textContent,i=t.textConfig;a&&PR(a,r,!!i,!!s)&&(u=OR(a,r,!0),!i&&u.textConfig&&(i=t.textConfig=u.textConfig),!s&&u.textContent&&(s=u.textContent));var l,i=(l=N({},l=t),G(["id","parentId","$action","hv","bounding","textContent"].concat(xh),function(t){delete l[t]}),l),u=t.$action||"merge";"merge"===u?n?n.attr(i):nE(e,o,i,p):"replace"===u?(iE(n,p),nE(e,o,i,p)):"remove"===u&&iE(n,p);var h,n=p.get(e);n&&s&&("merge"===u?(h=n.getTextContent())?h.attr(s):n.setTextContent(new Fs(s)):"replace"===u&&n.setTextContent(new Fs(s))),n&&((e=K5(n)).__ecGraphicWidthOption=t.width,e.__ecGraphicHeightOption=t.height,h=c,u=t,e=Gs(s=n).eventData,(e=s.silent||s.ignore||e?e:Gs(s).eventData={componentType:"graphic",componentIndex:h.componentIndex,name:s.name})&&(e.info=u.info),em({el:n,componentModel:c,itemName:n.name,itemTooltipOption:t.tooltip}))}))},tE.prototype._relocate=function(t,e){for(var n=t.option.elements,i=this.group,o=this._elMap,r=e.getWidth(),a=e.getHeight(),s=0;s<n.length;s++){var l,u,h,c,p=n[s],d=Ho(p.id,null),f=null!=d?o.get(d):null;f&&f.isGroup&&(u=(l=f.parent)===i,h=K5(f),c=K5(l),h.__ecGraphicWidth=go(h.__ecGraphicWidthOption,u?r:c.__ecGraphicWidth)||0,h.__ecGraphicHeight=go(h.__ecGraphicHeightOption,u?a:c.__ecGraphicHeight)||0)}for(s=n.length-1;0<=s;s--)(f=null!=(d=Ho((p=n[s]).id,null))?o.get(d):null)&&(l=f.parent,c=K5(l),Mh(f,p,l===i?{width:r,height:a}:{width:c.__ecGraphicWidth,height:c.__ecGraphicHeight},null,{hv:p.hv,boundingMode:p.bounding}))},tE.prototype._clear=function(){var e=this._elMap;e.each(function(t){iE(t,e)}),this._elMap=yt()},tE.prototype.dispose=function(){this._clear()},tE.type="graphic",tE);function tE(){var t=null!==j5&&j5.apply(this,arguments)||this;return t.type=tE.type,t}function eE(){var t=null!==q5&&q5.apply(this,arguments)||this;return t.type=eE.type,t.preventAutoZ=!0,t}function nE(t,e,n,i){var o=n.type,n=new(xt(J5,o)?J5[o]:zy(o))(n);e.add(n),i.set(t,n),K5(n).__ecGraphicId=t}function iE(t,e){var n=t&&t.parent;n&&("group"===t.type&&t.traverse(function(t){iE(t,e)}),e.removeKey(K5(t).__ecGraphicId),n.remove(t))}function oE(e,t){var n;return G(t,function(t){null!=e[t]&&"auto"!==e[t]&&(n=!0)}),n}var rE=["x","y","radius","angle","single"],aE=["cartesian2d","polar","singleAxis"];function sE(t){return t+"Axis"}function lE(t,e){var i,o=yt(),n=[],r=yt();for(t.eachComponent({mainType:"dataZoom",query:e},function(t){r.get(t.uid)||s(t)});i=!1,t.eachComponent("dataZoom",a),i;);function a(t){var n;!r.get(t.uid)&&(n=!1,t.eachTargetAxis(function(t,e){t=o.get(t);t&&t[e]&&(n=!0)}),n)&&(s(t),i=!0)}function s(t){r.set(t.uid,!0),n.push(t),t.eachTargetAxis(function(t,e){(o.get(t)||o.set(t,[]))[e]=!0})}return n}function uE(t){var o=t.ecModel,r={infoList:[],infoMap:yt()};return t.eachTargetAxis(function(t,e){var n,i=o.getComponent(sE(t),e);!i||(n=i.getCoordSysModel())&&(t=n.uid,(e=r.infoMap.get(t))||(r.infoList.push(e={model:n,axisModels:[]}),r.infoMap.set(t,e)),e.axisModels.push(i))}),r}var hE,cE=(dE.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},dE);function pE(){var t=null!==hE&&hE.apply(this,arguments)||this;return t.type=pE.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}function dE(){this.indexList=[],this.indexMap=[]}function fE(e){var n={};return G(["start","end","startValue","endValue","throttle"],function(t){e.hasOwnProperty(t)&&(n[t]=e[t])}),n}var gE,yE,mE,Jn=(d(pE,hE=Vh),pE.prototype.init=function(t,e,n){var i=fE(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},pE.prototype.mergeOption=function(t){var e=fE(t);O(this.option,t,!0),O(this.settledOption,e,!0),this._doInit(e)},pE.prototype._doInit=function(t){var n=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var i=this.settledOption;G([["start","startValue"],["end","endValue"]],function(t,e){"value"===this._rangePropMode[e]&&(n[t[0]]=i[t[0]]=null)},this),this._resetTarget()},pE.prototype._resetTarget=function(){var t=this.get("orient",!0),e=this._targetAxisInfoMap=yt();this._fillSpecifiedTargetAxis(e)?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(e,this._orient)),this._noTarget=!0,e.each(function(t){t.indexList.length&&(this._noTarget=!1)},this)},pE.prototype._fillSpecifiedTargetAxis=function(i){var o=!1;return G(rE,function(t){var e,n=this.getReferringComponents(sE(t),Qo);n.specified&&(o=!0,e=new cE,G(n.models,function(t){e.add(t.componentIndex)}),i.set(t,e))},this),o},pE.prototype._fillAutoTargetAxisByOrient=function(r,e){var t,i=this.ecModel,a=!0;function n(t,e){var n,i,o=t[0];o&&((n=new cE).add(o.componentIndex),r.set(e,n),a=!1,"x"!==e&&"y"!==e||(i=o.getReferringComponents("grid",Jo).models[0])&&G(t,function(t){o.componentIndex!==t.componentIndex&&i===t.getReferringComponents("grid",Jo).models[0]&&n.add(t.componentIndex)}))}a&&n(i.findComponents({mainType:(t="vertical"===e?"y":"x")+"Axis"}),t),a&&n(i.findComponents({mainType:"singleAxis",filter:function(t){return t.get("orient",!0)===e}}),"single"),a&&G(rE,function(t){var e,n;!a||(e=i.findComponents({mainType:sE(t),filter:function(t){return"category"===t.get("type",!0)}}))[0]&&((n=new cE).add(e[0].componentIndex),r.set(t,n),a=!1)},this)},pE.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(t){e=e||t},this),"y"===e?"vertical":"horizontal"},pE.prototype._setDefaultThrottle=function(t){t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle&&(t=this.ecModel.option,this.option.throttle=t.animation&&0<t.animationDurationUpdate?100:20)},pE.prototype._updateRangeUse=function(i){var o=this._rangePropMode,r=this.get("rangeMode");G([["start","startValue"],["end","endValue"]],function(t,e){var n=null!=i[t[0]],t=null!=i[t[1]];n&&!t?o[e]="percent":!n&&t?o[e]="value":r?o[e]=r[e]:n&&(o[e]="percent")})},pE.prototype.noTarget=function(){return this._noTarget},pE.prototype.getFirstTargetAxisModel=function(){var n;return this.eachTargetAxis(function(t,e){null==n&&(n=this.ecModel.getComponent(sE(t),e))},this),n},pE.prototype.eachTargetAxis=function(n,i){this._targetAxisInfoMap.each(function(t,e){G(t.indexList,function(t){n.call(i,e,t)})})},pE.prototype.getAxisProxy=function(t,e){e=this.getAxisModel(t,e);if(e)return e.__dzAxisProxy},pE.prototype.getAxisModel=function(t,e){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[e])return this.ecModel.getComponent(sE(t),e)},pE.prototype.setRawRange=function(e){var n=this.option,i=this.settledOption;G([["start","startValue"],["end","endValue"]],function(t){null==e[t[0]]&&null==e[t[1]]||(n[t[0]]=i[t[0]]=e[t[0]],n[t[1]]=i[t[1]]=e[t[1]])},this),this._updateRangeUse(e)},pE.prototype.setCalculatedRange=function(e){var n=this.option;G(["start","startValue","end","endValue"],function(t){n[t]=e[t]})},pE.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},pE.prototype.getValueRange=function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();e=this.findRepresentativeAxisProxy();return e?e.getDataValueWindow():void 0},pE.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var e,n=this._targetAxisInfoMap.keys(),i=0;i<n.length;i++)for(var o=n[i],r=this._targetAxisInfoMap.get(o),a=0;a<r.indexList.length;a++){var s=this.getAxisProxy(o,r.indexList[a]);if(s.hostedBy(this))return s;e=e||s}return e},pE.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},pE.prototype.getOrient=function(){return this._orient},pE.type="dataZoom",pE.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],pE.defaultOption={zlevel:0,z:4,filterMode:"filter",start:0,end:100},pE),vE=(d(IE,mE=Jn),IE.type="dataZoom.select",IE),gr=(d(ME,yE=Wd),ME.prototype.render=function(t,e,n,i){this.dataZoomModel=t,this.ecModel=e,this.api=n},ME.type="dataZoom",ME),xE=(d(SE,gE=gr),SE.type="dataZoom.select",SE),_E=G,bE=mo;function wE(t,e,n,i){this._dimName=t,this._axisIndex=e,this.ecModel=i,this._dataZoomModel=n}function SE(){var t=null!==gE&&gE.apply(this,arguments)||this;return t.type=SE.type,t}function ME(){var t=null!==yE&&yE.apply(this,arguments)||this;return t.type=ME.type,t}function IE(){var t=null!==mE&&mE.apply(this,arguments)||this;return t.type=IE.type,t}var TE=(wE.prototype.hostedBy=function(t){return this._dataZoomModel===t},wE.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},wE.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},wE.prototype.getTargetSeriesModels=function(){var n=[];return this.ecModel.eachSeries(function(t){var e;e=(e=t).get("coordinateSystem"),0<=V(aE,e)&&(e=sE(this._dimName),(e=t.getReferringComponents(e,Jo).models[0])&&this._axisIndex===e.componentIndex&&n.push(t))},this),n},wE.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},wE.prototype.getMinMaxSpan=function(){return P(this._minMaxSpan)},wE.prototype.calculateDataWindow=function(i){var o,r=this._dataExtent,s=this.getAxisModel().axis.scale,a=this._dataZoomModel.getRangePropMode(),l=[0,100],u=[],h=[];_E(["start","end"],function(t,e){var n=i[t],t=i[t+"Value"];"percent"===a[e]?t=s.parse(fo(n=null==n?l[e]:n,l,r)):(o=!0,n=fo(t=null==t?r[e]:s.parse(t),r,l)),h[e]=t,u[e]=n}),bE(h),bE(u);var c=this._minMaxSpan;function t(t,e,n,i,o){var r=o?"Span":"ValueSpan";tk(0,t,n,"all",c["min"+r],c["max"+r]);for(var a=0;a<2;a++)e[a]=fo(t[a],n,i,!0),o&&(e[a]=s.parse(e[a]))}return o?t(h,u,r,l,!1):t(u,h,l,r,!0),{valueWindow:h,percentWindow:u}},wE.prototype.reset=function(t){var e;t===this._dataZoomModel&&(e=this.getTargetSeriesModels(),this._dataExtent=function(t,i,e){var o=[1/0,-1/0];_E(e,function(t){var e,n;e=o,n=t.getData(),t=i,n&&G(oM(n,t),function(t){t=n.getApproximateExtent(t);t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])})});t=t.getAxisModel(),t=jS(t.axis.scale,t,o).calculate();return[t.min,t.max]}(this,this._dimName,e),this._updateMinMaxSpan(),t=this.calculateDataWindow(t.settledOption),this._valueWindow=t.valueWindow,this._percentWindow=t.percentWindow,this._setAxisModel())},wE.prototype.filterData=function(t,e){var o,n,r,c;t===this._dataZoomModel&&(o=this._dimName,n=this.getTargetSeriesModels(),r=t.get("filterMode"),c=this._valueWindow,"none"!==r&&_E(n,function(n){var l,u,i=n.getData(),h=i.mapDimensionsAll(o);h.length&&("weakFilter"===r?(l=i.getStore(),u=H(h,function(t){return i.getDimensionIndex(t)},i),i.filterSelf(function(t){for(var e,n,i,o=0;o<h.length;o++){var r=l.get(u[o],t),a=!isNaN(r),s=r<c[0],r=r>c[1];if(a&&!s&&!r)return!0;a&&(i=!0),s&&(e=!0),r&&(n=!0)}return i&&e&&n})):_E(h,function(t){var e;"empty"===r?n.setData(i=i.map(t,function(t){return(e=t)>=c[0]&&e<=c[1]?t:NaN;var e})):((e={})[t]=c,i.selectRange(e))}),_E(h,function(t){i.setApproximateExtent(c,t)}))}))},wE.prototype._updateMinMaxSpan=function(){var i=this._minMaxSpan={},o=this._dataZoomModel,r=this._dataExtent;_E(["min","max"],function(t){var e=o.get(t+"Span"),n=o.get(t+"ValueSpan");null!=(n=null!=n?this.getAxisModel().axis.scale.parse(n):n)?e=fo(r[0]+n,r,[0,100],!0):null!=e&&(n=fo(e,[0,100],r,!0)-r[0]),i[t+"Span"]=e,i[t+"ValueSpan"]=n},this)},wE.prototype._setAxisModel=function(){var t,e=this.getAxisModel(),n=this._percentWindow,i=this._valueWindow;n&&(t=xo(i,[0,500]),t=Math.min(t,20),e=e.axis.scale.rawExtentInfo,0!==n[0]&&e.setDeterminedMinMax("min",+i[0].toFixed(t)),100!==n[1]&&e.setDeterminedMinMax("max",+i[1].toFixed(t)),e.freeze())},wE),CE={getTargetSeries:function(r){function t(o){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(t,e){var n=r.getComponent(sE(t),e);o(t,e,n,i)})})}t(function(t,e,n,i){n.__dzAxisProxy=null});var o=[];t(function(t,e,n,i){n.__dzAxisProxy||(n.__dzAxisProxy=new TE(t,e,i,r),o.push(n.__dzAxisProxy))});var e=yt();return G(o,function(t){G(t.getTargetSeriesModels(),function(t){e.set(t.uid,t)})}),e},overallReset:function(t,i){t.eachComponent("dataZoom",function(n){n.eachTargetAxis(function(t,e){n.getAxisProxy(t,e).reset(n)}),n.eachTargetAxis(function(t,e){n.getAxisProxy(t,e).filterData(n,i)})}),t.eachComponent("dataZoom",function(t){var e,n=t.findRepresentativeAxisProxy();n&&(e=n.getDataPercentWindow(),n=n.getDataValueWindow(),t.setCalculatedRange({start:e[0],end:e[1],startValue:n[0],endValue:n[1]}))})}};var DE=!1;function AE(t){DE||(DE=!0,t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,CE),t.registerAction("dataZoom",function(e,t){G(lE(t,e),function(t){t.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})}),t.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function kE(t){t.registerComponentModel(vE),t.registerComponentView(xE),AE(t)}function LE(){}var PE={};function OE(t,e){PE[t]=e}function RE(t){return PE[t]}var NE,zE,EE=(d(VE,NE=Vh),VE.prototype.optionUpdated=function(){NE.prototype.optionUpdated.apply(this,arguments);var n=this.ecModel;G(this.option.feature,function(t,e){e=RE(e);e&&(e.getDefaultOption&&(e.defaultOption=e.getDefaultOption(n)),O(t,e.defaultOption))})},VE.type="toolbox",VE.layoutMode={type:"box",ignoreSize:!0},VE.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,position:"bottom"}},VE);function VE(){var t=null!==NE&&NE.apply(this,arguments)||this;return t.type=VE.type,t}function BE(t,e){var n=lh(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new Ts({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 FE(){return null!==zE&&zE.apply(this,arguments)||this}var GE,HE=(d(FE,zE=Wd),FE.prototype.render=function(h,c,p,a){var d,s,l,u,t,e,n,i,o,r,f=this.group;function g(t,e){var n,i=u[t],o=u[e],t=s[i],e=new wu(t,h,h.ecModel);if(a&&null!=a.newTitle&&a.featureName===i&&(t.title=a.newTitle),i&&!o){if(0===i.indexOf("my"))n={onclick:e.option.onclick,featureName:i};else{var r=RE(i);if(!r)return;n=new r}l[i]=n}else if(!(n=l[o]))return;n.uid=Mu("toolbox-feature"),n.model=e,n.ecModel=c,n.api=p;r=n instanceof LE;i||!o?!e.get("show")||r&&n.unusable?r&&n.remove&&n.remove(c,p):(function(o,r,t){var e,a,s=o.getModel("iconStyle"),l=o.getModel(["emphasis","iconStyle"]),n=r instanceof LE&&r.getIcons?r.getIcons():o.get("icon"),i=o.get("title")||{};"string"==typeof n?(e={})[t]=n:e=n,"string"==typeof i?(a={})[t]=i:a=i;var u=o.iconPaths={};G(e,function(t,e){var n=Qy(t,{},{x:-d/2,y:-d/2,width:d,height:d});n.setStyle(s.getItemStyle()),n.ensureState("emphasis").style=l.getItemStyle();var i=new Fs({style:{text:a[e],align:l.get("textAlign"),borderRadius:l.get("textBorderRadius"),padding:l.get("textPadding"),fill:null},ignore:!0});n.setTextContent(i),em({el:n,componentModel:h,itemName:e,formatterParamsExtra:{title:a[e]}}),n.__title=a[e],n.on("mouseover",function(){var t=l.getItemStyle(),e="vertical"===h.get("orient")?null==h.get("right")?"right":"left":null==h.get("bottom")?"bottom":"top";i.setStyle({fill:l.get("textFill")||t.fill||t.stroke||"#000",backgroundColor:l.get("textBackgroundColor")}),n.setTextConfig({position:l.get("textPosition")||e}),i.ignore=!h.get("showTitle"),xl(this)}).on("mouseout",function(){"emphasis"!==o.get(["iconStatus",e])&&_l(this),i.hide()}),("emphasis"===o.get(["iconStatus",e])?xl:_l)(n),f.add(n),n.on("click",X(r.onclick,r,c,p,e)),u[e]=n})}(e,n,i),e.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&("emphasis"===e?xl:_l)(i[t])},n instanceof LE&&n.render&&n.render(e,c,p,a)):r&&n.dispose&&n.dispose(c,p)}f.removeAll(),h.get("show")&&(d=+h.get("itemSize"),s=h.get("feature")||{},l=this._features||(this._features={}),u=[],G(s,function(t,e){u.push(e)}),new Vx(this._featureNames||[],u).add(g).update(g).remove(Z(g,null)).execute(),this._featureNames=u,t=f,n=p,i=(e=h).getBoxLayoutParams(),o=e.get("padding"),r={width:n.getWidth(),height:n.getHeight()},n=Sh(i,r,o),wh(e.get("orient"),t,e.get("itemGap"),n.width,n.height),Mh(t,i,r,o),f.add(BE(f.getBoundingRect(),h)),f.eachChild(function(t){var e=t.__title,n=t.ensureState("emphasis"),i=n.textConfig||(n.textConfig={}),o=t.getTextContent(),r=o&&o.states.emphasis;r&&!q(r)&&e&&(n=r.style||(r.style={}),o=Bi(e,Fs.makeFont(n)),r=t.x+f.x,e=!1,t.y+f.y+d+o.height>p.getHeight()&&(i.position="top",e=!0),e=e?-5-o.height:d+8,r+o.width/2>p.getWidth()?(i.position=["100%",e],n.align="right"):r-o.width/2<0&&(i.position=[0,e],n.align="left"))}))},FE.prototype.updateView=function(t,e,n,i){G(this._features,function(t){t instanceof LE&&t.updateView&&t.updateView(t.model,e,n,i)})},FE.prototype.remove=function(e,n){G(this._features,function(t){t instanceof LE&&t.remove&&t.remove(e,n)}),this.group.removeAll()},FE.prototype.dispose=function(e,n){G(this._features,function(t){t instanceof LE&&t.dispose&&t.dispose(e,n)})},FE.type="toolbox",FE),mu=(d(WE,GE=LE),WE.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",o="svg"===e.getZr().painter.getType(),r=o?"svg":n.get("type",!0)||"png",a=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||!w.browser.newEdge&&(w.browser.ie||w.browser.edge))if(window.navigator.msSaveOrOpenBlob||o){var e=a.split(","),t=-1<e[0].indexOf("base64"),s=o?decodeURIComponent(e[1]):e[1];t&&(s=window.atob(s));o=i+"."+r;if(window.navigator.msSaveOrOpenBlob){for(var l=s.length,u=new Uint8Array(l);l--;)u[l]=s.charCodeAt(l);var h=new Blob([u]);window.navigator.msSaveOrOpenBlob(h,o)}else{e=document.createElement("iframe");document.body.appendChild(e);t=e.contentWindow,h=t.document;h.open("image/svg+xml","replace"),h.write(s),h.close(),t.focus(),h.execCommand("SaveAs",!0,o),document.body.removeChild(e)}}else{var c=n.get("lang"),n='<body style="margin:0;"><img src="'+a+'" style="max-width:100%;" title="'+(c&&c[0]||"")+'" /></body>',c=window.open();c.document.write(n),c.document.title=i}else{c=document.createElement("a");c.download=i+"."+r,c.target="_blank",c.href=a;a=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(a)}},WE.getDefaultOption=function(t){return{show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])}},WE);function WE(){return null!==GE&&GE.apply(this,arguments)||this}mu.prototype.unusable=!w.canvasSupported;var UE,YE=mu,XE="__ec_magicType_stack__",ZE=[["line","bar"],["stack"]],C=(d(qE,UE=LE),qE.prototype.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return G(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n},qE.getDefaultOption=function(t){return{show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}}},qE.prototype.onclick=function(t,e,a){var n,s,l=this.model,i=l.get(["seriesIndex",a]);jE[a]&&(s={series:[]},G(ZE,function(t){0<=V(t,a)&&G(t,function(t){l.setIconStatus(t,"normal")})}),l.setIconStatus(a,"emphasis"),t.eachComponent({mainType:"series",query:null==i?null:{seriesIndex:i}},function(t){var e=t.subType,n=t.id,n=jE[a](e,n,t,l);n&&(z(n,t.option),s.series.push(n));n=t.coordinateSystem;if(n&&"cartesian2d"===n.type&&("line"===a||"bar"===a)){n=n.getAxesByScale("ordinal")[0];if(n){var i=n.dim+"Axis",o=t.getReferringComponents(i,Jo).models[0].componentIndex;s[i]=s[i]||[];for(var r=0;r<=o;r++)s[i][o]=s[i][o]||{};s[i][o].boundaryGap="bar"===a}}}),"stack"===(i=a)&&(n=O({stack:l.option.title.tiled,tiled:l.option.title.stack},l.option.title),"emphasis"!==l.get(["iconStatus",a])&&(i="tiled")),e.dispatchAction({type:"changeMagicType",currentType:i,newOption:s,newTitle:n,featureName:"magicType"}))},qE),jE={line:function(t,e,n,i){if("bar"===t)return O({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)},bar:function(t,e,n,i){if("line"===t)return O({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)},stack:function(t,e,n,i){n=n.get("stack")===XE;if("line"===t||"bar"===t)return i.setIconStatus("stack",n?"normal":"emphasis"),O({id:e,stack:n?"":XE},i.get(["option","stack"])||{},!0)}};function qE(){return null!==UE&&UE.apply(this,arguments)||this}Vv({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)});var KE=C,JE=new Array(60).join("-"),QE="\t";function $E(t){var o,r,a,h,t=(o={},r=[],a=[],t.eachRawSeries(function(t){var e,n,i=t.coordinateSystem;i&&("cartesian2d"===i.type||"polar"===i.type)&&"category"===(e=i.getBaseAxis()).type?(n=e.dim+"_"+e.index,o[n]||(o[n]={categoryAxis:e,valueAxis:i.getOtherAxis(e),series:[]},a.push({axisDim:e.dim,axisIndex:e.index})),o[n].series.push(t)):r.push(t)}),{seriesGroupByCategoryAxis:o,other:r,meta:a});return{value:U([(h=[],G(t.seriesGroupByCategoryAxis,function(t,e){var n=t.categoryAxis,i=t.valueAxis.dim,o=[" "].concat(H(t.series,function(t){return t.name})),r=[n.model.getCategories()];G(t.series,function(t){var e=t.getRawData();r.push(t.getRawData().mapArray(e.mapDimension(i),function(t){return t}))});for(var a=[o.join(QE)],s=0;s<r[0].length;s++){for(var l=[],u=0;u<r.length;u++)l.push(r[u][s]);a.push(l.join(QE))}h.push(a.join("\n"))}),h.join("\n\n"+JE+"\n\n")),H(t.other,function(t){var i=t.getRawData(),o=[t.name],r=[];return i.each(i.dimensions,function(){for(var t=arguments.length,e=i.getName(arguments[t-1]),n=0;n<t-1;n++)r[n]=arguments[n];o.push((e?e+QE:"")+r.join(QE))}),o.join("\n")}).join("\n\n"+JE+"\n\n")],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join("\n\n"+JE+"\n\n"),meta:t.meta}}function t3(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var e3=new RegExp("["+QE+"]+","g");function n3(t,o){var t=t.split(new RegExp("\n*"+JE+"\n*","g")),r={series:[]};return G(t,function(t,e){var n,i;0<=t.slice(0,t.indexOf("\n")).indexOf(QE)?(n=function(t){for(var e=t.split(/\n+/g),n=[],i=H(t3(e.shift()).split(e3),function(t){return{name:t,data:[]}}),o=0;o<e.length;o++){var r=t3(e[o]).split(e3);n.push(r.shift());for(var a=0;a<r.length;a++)i[a]&&(i[a].data[o]=r[a])}return{series:i,categories:n}}(t),e=(i=o[e]).axisDim+"Axis",i&&(r[e]=r[e]||[],r[e][i.axisIndex]={data:n.categories},r.series=r.series.concat(n.series))):(n=function(t){for(var e=t.split(/\n+/g),t=t3(e.shift()),n=[],i=0;i<e.length;i++){var o=t3(e[i]);if(o){for(var r=o.split(e3),a=void 0,s=!1,a=isNaN(r[0])?(s=!0,o=r[0],r=r.slice(1),n[i]={name:o,value:[]},n[i].value):n[i]=[],l=0;l<r.length;l++)a.push(+r[l]);1===a.length&&(s?n[i].value=a[0]:n[i]=a[0])}}return{name:t,data:n}}(t),r.series.push(n))}),r}var i3,io=(d(o3,i3=LE),o3.prototype.onclick=function(t,e){var n=e.getDom(),i=this.model;this._dom&&n.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",o.style.backgroundColor=i.get("backgroundColor")||"#fff";var r=document.createElement("h4"),a=i.get("lang")||[];r.innerHTML=a[0]||i.get("title"),r.style.cssText="margin: 10px 20px;",r.style.color=i.get("textColor");var s=document.createElement("div"),l=document.createElement("textarea");s.style.cssText="display:block;width:100%;overflow:auto;";var u=i.get("optionToContent"),h=i.get("contentToOption"),c=$E(t);"function"==typeof u?"string"==typeof(f=u(e.getOption()))?s.innerHTML=f:nt(f)&&s.appendChild(f):(s.appendChild(l),l.readOnly=i.get("readOnly"),l.style.cssText="width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;",l.style.color=i.get("textColor"),l.style.borderColor=i.get("textareaBorderColor"),l.style.backgroundColor=i.get("textareaColor"),l.value=c.value);var p=c.meta,d=document.createElement("div");d.style.cssText="position:absolute;bottom:0;left:0;right:0;";var t="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",f=document.createElement("div"),c=document.createElement("div");t+=";background-color:"+i.get("buttonColor"),t+=";color:"+i.get("buttonTextColor");var g=this;function y(){n.removeChild(o),g._dom=null}oe(f,"click",y),oe(c,"click",function(){if(null==h&&null!=u||null!=h&&null==u)y();else{var t;try{t="function"==typeof h?h(s,e.getOption()):n3(l.value,p)}catch(t){throw y(),new Error("Data view format error "+t)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),y()}}),f.innerHTML=a[1],c.innerHTML=a[2],c.style.cssText=t,f.style.cssText=t,i.get("readOnly")||d.appendChild(c),d.appendChild(f),o.appendChild(r),o.appendChild(s),o.appendChild(d),s.style.height=n.clientHeight-80+"px",n.appendChild(o),this._dom=o},o3.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},o3.prototype.dispose=function(t,e){this.remove(t,e)},o3.getDefaultOption=function(t){return{show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"}},o3);function o3(){return null!==i3&&i3.apply(this,arguments)||this}Vv({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,o){var r=[];G(t.newOption.series,function(t){var e,i,n=o.getSeriesByName(t.name)[0];n?(e=n.get("data"),r.push({name:t.name,data:(n=t.data,i=e,H(n,function(t,e){var n=i&&i[e];if(!$(n)||j(n))return t;$(t)&&!j(t)||(t={value:t});e=null!=n.name&&null==t.name;return t=z(t,n),e&&delete t.name,t}))})):r.push(N({type:"scatter"},t))}),o.mergeOption(z({series:r},t.newOption))});var r3=io,a3=G,s3=Zo();function l3(t){t=s3(t);return t.snapshots||(t.snapshots=[{}]),t.snapshots}var u3,mu=(d(h3,u3=LE),h3.prototype.onclick=function(t,e){s3(t).snapshots=null,e.dispatchAction({type:"restore",from:this.uid})},h3.getDefaultOption=function(t){return{show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:t.getLocaleModel().get(["toolbox","restore","title"])}},h3);function h3(){return null!==u3&&u3.apply(this,arguments)||this}Vv({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var c3=mu,p3=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],C=(d3.prototype.setOutputRanges=function(t,e){return this.matchOutputRanges(t,e,function(t,e,n){(t.coordRanges||(t.coordRanges=[])).push(e),t.coordRange||(t.coordRange=e,e=x3[t.brushType](0,n,e),t.__rangeOffset={offset:b3[t.brushType](e.values,t.range,[1,1]),xyMinMax:e.xyMinMax})}),t},d3.prototype.matchOutputRanges=function(t,i,o){G(t,function(n){var t=this.findTargetInfo(n,i);t&&!0!==t&&G(t.coordSyses,function(t){var e=x3[n.brushType](1,t,n.range,!0);o(n,e.values,t,i)})},this)},d3.prototype.setInputRanges=function(t,i){G(t,function(t){var e,n=this.findTargetInfo(t,i);t.range=t.range||[],n&&!0!==n&&(t.panelId=n.panelId,e=x3[t.brushType](0,n.coordSys,t.coordRange),n=t.__rangeOffset,t.range=n?b3[t.brushType](e.values,n.offset,function(t,e){t=S3(t),e=S3(e),e=[t[0]/e[0],t[1]/e[1]];return isNaN(e[0])&&(e[0]=1),isNaN(e[1])&&(e[1]=1),e}(e.xyMinMax,n.xyMinMax)):e.values)},this)},d3.prototype.makePanelOpts=function(n,i){return H(this._targetInfoList,function(t){var e=t.getPanelRect();return{panelId:t.panelId,defaultBrushType:i?i(t):null,clipPath:uL(e),isTargetByCursor:cL(e,n,t.coordSysModel),getLinearBrushOtherExtent:hL(e)}})},d3.prototype.controlSeries=function(t,e,n){n=this.findTargetInfo(t,n);return!0===n||n&&0<=V(n.coordSyses,e.coordinateSystem)},d3.prototype.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=g3(e,t),o=0;o<n.length;o++){var r=n[o],a=t.panelId;if(a){if(r.panelId===a)return r}else for(var s=0;s<m3.length;s++)if(m3[s](i,r))return r}return!0},d3);function d3(t,e,n){var i=this;this._targetInfoList=[];var o=g3(e,t);G(y3,function(t,e){n&&n.include&&!(0<=V(n.include,e))||t(o,i._targetInfoList)})}function f3(t){return t[0]>t[1]&&t.reverse(),t}function g3(t,e){return qo(t,e,{includeMainTypes:p3})}var y3={grid:function(t,i){var o=t.xAxisModels,r=t.yAxisModels,t=t.gridModels,e=yt(),a={},s={};(o||r||t)&&(G(o,function(t){t=t.axis.grid.model;e.set(t.id,t),a[t.id]=!0}),G(r,function(t){t=t.axis.grid.model;e.set(t.id,t),s[t.id]=!0}),G(t,function(t){e.set(t.id,t),a[t.id]=!0,s[t.id]=!0}),e.each(function(t){var e=t.coordinateSystem,n=[];G(e.getCartesians(),function(t,e){(0<=V(o,t.getAxis("x").model)||0<=V(r,t.getAxis("y").model))&&n.push(t)}),i.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:n[0],coordSyses:n,getPanelRect:v3.grid,xAxisDeclared:a[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,n){G(t.geoModels,function(t){var e=t.coordinateSystem;n.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:e,coordSyses:[e],getPanelRect:v3.geo})})}},m3=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,t=t.gridModel;return(t=!(t=!t&&n?n.axis.grid.model:t)&&i?i.axis.grid.model:t)&&t===e.gridModel},function(t,e){t=t.geoModel;return t&&t===e.geoModel}],v3={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Yy(t)),e}},x3={lineX:Z(_3,0),lineY:Z(_3,1),rect:function(t,e,n,i){var o=t?e.pointToData([n[0][0],n[1][0]],i):e.dataToPoint([n[0][0],n[1][0]],i),i=t?e.pointToData([n[0][1],n[1][1]],i):e.dataToPoint([n[0][1],n[1][1]],i),i=[f3([o[0],i[0]]),f3([o[1],i[1]])];return{values:i,xyMinMax:i}},polygon:function(e,n,t,i){var o=[[1/0,-1/0],[1/0,-1/0]];return{values:H(t,function(t){t=e?n.pointToData(t,i):n.dataToPoint(t,i);return o[0][0]=Math.min(o[0][0],t[0]),o[1][0]=Math.min(o[1][0],t[1]),o[0][1]=Math.max(o[0][1],t[0]),o[1][1]=Math.max(o[1][1],t[1]),t}),xyMinMax:o}}};function _3(t,e,n,i){var o=n.getAxis(["x","y"][t]),r=f3(H([0,1],function(t){return e?o.coordToData(o.toLocalCoord(i[t]),!0):o.toGlobalCoord(o.dataToCoord(i[t]))})),n=[];return n[t]=r,n[1-t]=[NaN,NaN],{values:r,xyMinMax:n}}var b3={lineX:Z(w3,0),lineY:Z(w3,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,n,i){return H(t,function(t,e){return[t[0]-i[0]*n[e][0],t[1]-i[1]*n[e][1]]})}};function w3(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function S3(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}var M3,I3=C,T3=G,io=(d(D3,M3=LE),D3.prototype.render=function(t,e,n,i){this._brushController||(this._brushController=new lL(n.getZr()),this._brushController.on("brush",X(this._onBrush,this)).mount()),function(t,e,n,i,o){var r=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(r="dataZoomSelect"===i.key&&i.dataZoomSelectActive),n._isZoomActive=r,t.setIconStatus("zoom",r?"emphasis":"normal");o=new I3(A3(t),e,{include:["grid"]}).makePanelOpts(o,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"});n._brushController.setPanels(o).enableBrush(!(!r||!o.length)&&{brushType:"auto",brushStyle:t.getModel("brushStyle").getItemStyle()})}(t,e,this,i,n),t.setIconStatus("back",1<function(t){return l3(t).length}(e)?"emphasis":"normal")},D3.prototype.onclick=function(t,e,n){C3[n].call(this)},D3.prototype.remove=function(t,e){this._brushController&&this._brushController.unmount()},D3.prototype.dispose=function(t,e){this._brushController&&this._brushController.dispose()},D3.prototype._onBrush=function(t){var s,l,o,r,e=t.areas;function i(t,e,n){var i,o,r,a=e.getAxis(t),e=a.model,t=(i=t,o=e,l.eachComponent({mainType:"dataZoom",subType:"select"},function(t){t.getAxisModel(i,o.componentIndex)&&(r=t)}),r),e=t.findRepresentativeAxisProxy(e).getMinMaxSpan();null==e.minValueSpan&&null==e.maxValueSpan||(n=tk(0,n.slice(),a.scale.getExtent(),0,e.minValueSpan,e.maxValueSpan)),t&&(s[t.id]={dataZoomId:t.id,startValue:n[0],endValue:n[1]})}t.isEnd&&e.length&&(s={},l=this.ecModel,this._brushController.updateCovers([]),new I3(A3(this.model),l,{include:["grid"]}).matchOutputRanges(e,l,function(t,e,n){"cartesian2d"===n.type&&("rect"===(t=t.brushType)?(i("x",n,e[0]),i("y",n,e[1])):i({lineX:"x",lineY:"y"}[t],n,e))}),e=s,r=l3(o=l),a3(e,function(t,e){for(var n,i=r.length-1;0<=i;i--)if(r[i][e])break;i<0&&((n=o.queryComponents({mainType:"dataZoom",subType:"select",id:e})[0])&&(n=n.getPercentRange(),r[0][e]={dataZoomId:e,start:n[0],end:n[1]}))}),r.push(e),this._dispatchZoomAction(s))},D3.prototype._dispatchZoomAction=function(t){var n=[];T3(t,function(t,e){n.push(P(t))}),n.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:n})},D3.getDefaultOption=function(t){return{show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}}},D3),C3={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(function(t){var i=l3(t),t=i[i.length-1];1<i.length&&i.pop();var o={};return a3(t,function(t,e){for(var n=i.length-1;0<=n;n--)if(t=i[n][e]){o[e]=t;break}}),o}(this.ecModel))}};function D3(){return null!==M3&&M3.apply(this,arguments)||this}function A3(t){t={xAxisIndex:t.get("xAxisIndex",!0),yAxisIndex:t.get("yAxisIndex",!0),xAxisId:t.get("xAxisId",!0),yAxisId:t.get("yAxisId",!0)};return null==t.xAxisIndex&&null==t.xAxisId&&(t.xAxisIndex="all"),null==t.yAxisIndex&&null==t.yAxisId&&(t.yAxisIndex="all"),t}mu="dataZoom",C=function(t){var e=t.getComponent("toolbox",0),n=["feature","dataZoom"];if(e&&null!=e.get(n)){var i=e.getModel(n),o=[],t=qo(t,A3(i));return T3(t.xAxisModels,function(t){return r(t,"xAxis","xAxisIndex")}),T3(t.yAxisModels,function(t){return r(t,"yAxis","yAxisIndex")}),o}function r(t,e,n){t=t.componentIndex,e={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:"\0_ec_\0toolbox-dataZoom_"+e+t};e[n]=t,o.push(e)}},ut(null==nc.get(mu)&&C),nc.set(mu,C);var k3=io;var L3,P3=(d(O3,L3=Vh),O3.type="tooltip",O3.dependencies=["axisPointer"],O3.defaultOption={zlevel:0,z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},O3);function O3(){var t=null!==L3&&L3.apply(this,arguments)||this;return t.type=O3.type,t}function R3(t){var e=t.get("confine");return null!=e?e:"richText"===t.get("renderMode")}function N3(t){if(w.domSupported)for(var e=document.documentElement.style,n=0,i=t.length;n<i;n++)if(t[n]in e)return t[n]}var z3=N3(["transform","webkitTransform","OTransform","MozTransform","msTransform"]);function E3(t,e){if(!t)return e;e=sh(e,!0);var n=t.indexOf(e);return(t=-1===n?e:"-"+t.slice(0,n)+"-"+e).toLowerCase()}var V3=E3(N3(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),"transition"),B3=E3(z3,"transform"),F3="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(w.transform3dSupported?"will-change:transform;":"");function G3(t,e,n){var i=t.toFixed(0)+"px",t=e.toFixed(0)+"px";if(!w.transformSupported)return n?"top:"+t+";left:"+i+";":[["top",t],["left",i]];e=w.transform3dSupported,e="translate"+(e?"3d":"")+"("+i+","+t+(e?",0":"")+")";return n?"top:0;left:0;"+B3+":"+e+";":[["top",0],["left",0],[z3,e]]}function H3(i,t,e){var o=[],n=i.get("transitionDuration"),r=i.get("backgroundColor"),a=i.get("shadowBlur"),s=i.get("shadowColor"),l=i.get("shadowOffsetX"),u=i.get("shadowOffsetY"),h=i.getModel("textStyle"),c=Id(i,"html");return o.push("box-shadow:"+(l+"px "+u+"px "+a+"px "+s)),t&&n&&o.push((n="opacity"+(t=" "+(a=n)/2+"s "+(s="cubic-bezier(0.23,1,0.32,1)"))+",visibility"+t,e||(t=" "+a+"s "+s,n+=w.transformSupported?","+B3+t:",left"+t+",top"+t),V3+":"+n)),r&&(w.canvasSupported?o.push("background-color:"+r):(o.push("background-color:#"+ln(r)),o.push("filter:alpha(opacity=70)"))),G(["width","color","radius"],function(t){var e="border-"+t,n=sh(e),n=i.get(n);null!=n&&o.push(e+":"+n+("color"===t?"":"px"))}),o.push(function(n){var i=[],t=n.get("fontSize");(r=n.getTextColor())&&i.push("color:"+r),i.push("font:"+n.getFont()),t&&i.push("line-height:"+Math.round(3*t/2)+"px");var e=n.get("textShadowColor"),o=n.get("textShadowBlur")||0,r=n.get("textShadowOffsetX")||0,t=n.get("textShadowOffsetY")||0;return e&&o&&i.push("text-shadow:"+r+"px "+t+"px "+o+"px "+e),G(["decoration","align"],function(t){var e=n.get(t);e&&i.push("text-"+t+":"+e)}),i.join(";")}(h)),null!=c&&o.push("padding:"+lh(c).join("px ")+"px"),o.join(";")+";"}function W3(t,e,n,i,o){var r,a,s=e&&e.painter;n?(r=s&&s.getViewportRoot())&&(a=t,n=document.body,qt(jt,r,i,o,!0)&&qt(a,n,jt[0],jt[1])):(t[0]=i,t[1]=o,(s=s&&s.getViewportRootOffset())&&(t[0]+=s.offsetLeft,t[1]+=s.offsetTop)),t[2]=t[0]/e.getWidth(),t[3]=t[1]/e.getHeight()}var U3=(X3.prototype.update=function(t){var e,n=this._container,i=(e="position",(i=(i=n).currentStyle||document.defaultView&&document.defaultView.getComputedStyle(i))?e?i[e]:i:null),n=n.style;"absolute"!==n.position&&"absolute"!==i&&(n.position="relative"),t.get("alwaysShowContent")&&this._moveIfResized(),this.el.className=t.get("className")||""},X3.prototype.show=function(t,e){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,i=n.style,o=this._styleCoord;n.innerHTML?i.cssText=F3+H3(t,!this._firstShow,this._longHide)+G3(o[0],o[1],!0)+"border-color:"+yh(e)+";"+(t.get("extraCssText")||"")+";pointer-events:"+(this._enterable?"auto":"none"):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},X3.prototype.setContent=function(t,e,n,i,o){var r=this.el;if(null!=t){var a="";if(K(o)&&"item"===n.get("trigger")&&!R3(n)&&(a=function(t,e,n){if(!K(n)||"inside"===n)return"";var i=t.get("backgroundColor"),o=t.get("borderWidth");e=yh(e);var r=s="left"===(s=n)?"right":"right"===s?"left":"top"===s?"bottom":"top",a=Math.max(1.5*Math.round(o),6),t="",n=B3+":";-1<V(["left","right"],r)?(t+="top:50%",n+="translateY(-50%) rotate("+(l="left"==r?-225:-45)+"deg)"):(t+="left:50%",n+="translateX(-50%) rotate("+(l="top"==r?225:45)+"deg)");var s=l*Math.PI/180,l=a+o,s=l*Math.abs(Math.cos(s))+l*Math.abs(Math.sin(s)),e=e+" solid "+o+"px;";return'<div style="'+["position:absolute;width:"+a+"px;height:"+a+"px;",(t+=";"+r+":-"+Math.round(100*((s-Math.SQRT2*o)/2+Math.SQRT2*o-(s-l)/2))/100+"px")+";"+n+";","border-bottom:"+e,"border-right:"+e,"background-color:"+i+";"].join("")+'"></div>'}(n,i,o)),K(t))r.innerHTML=t+a;else if(t){r.innerHTML="",j(t)||(t=[t]);for(var s=0;s<t.length;s++)nt(t[s])&&t[s].parentNode!==r&&r.appendChild(t[s]);a&&r.childNodes.length&&((o=document.createElement("div")).innerHTML=a,r.appendChild(o))}}else r.innerHTML=""},X3.prototype.setEnterable=function(t){this._enterable=t},X3.prototype.getSize=function(){var t=this.el;return[t.offsetWidth,t.offsetHeight]},X3.prototype.moveTo=function(t,e){var n,i=this._styleCoord;W3(i,this._zr,this._appendToBody,t,e),null!=i[0]&&null!=i[1]&&(n=this.el.style,G(G3(i[0],i[1]),function(t){n[t[0]]=t[1]}))},X3.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},X3.prototype.hide=function(){var t=this,e=this.el.style;e.visibility="hidden",e.opacity="0",w.transform3dSupported&&(e.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return t._longHide=!0},500)},X3.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(X(this.hide,this),t)):this.hide())},X3.prototype.isShow=function(){return this._show},X3.prototype.dispose=function(){this.el.parentNode.removeChild(this.el)},X3);function Y3(t){this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._zr=t.getZr(),q3(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}function X3(t,e,n){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._firstShow=!0,this._longHide=!0,w.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var o=this._zr=e.getZr(),n=this._appendToBody=n&&n.appendToBody;W3(this._styleCoord,o,n,e.getWidth()/2,e.getHeight()/2),(n?document.body:t).appendChild(i),this._container=t;var r=this;i.onmouseenter=function(){r._enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},i.onmousemove=function(t){var e;t=t||window.event,r._enterable||(e=o.handler,ie(o.painter.getViewportRoot(),t,!0),e.dispatch("mousemove",t))},i.onmouseleave=function(){r._inContent=!1,r._enterable&&r._show&&r.hideLater(r._hideDelay)}}function Z3(t){return Math.max(0,t)}function j3(t){var e=Z3(t.shadowBlur||0),n=Z3(t.shadowOffsetX||0),t=Z3(t.shadowOffsetY||0);return{left:Z3(e-n),right:Z3(e+n),top:Z3(e-t),bottom:Z3(e+t)}}function q3(t,e,n,i){t[0]=n,t[1]=i,t[2]=t[0]/e.getWidth(),t[3]=t[1]/e.getHeight()}var K3,J3=(Y3.prototype.update=function(t){t.get("alwaysShowContent")&&this._moveIfResized()},Y3.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},Y3.prototype.setContent=function(t,e,n,i,o){$(t)&&pc(""),this.el&&this._zr.remove(this.el);var r=n.getModel("textStyle");this.el=new Fs({style:{rich:e.richTextStyles,text:t,lineHeight:22,backgroundColor:n.get("backgroundColor"),borderRadius:n.get("borderRadius"),borderWidth:1,borderColor:i,shadowColor:n.get("shadowColor"),shadowBlur:n.get("shadowBlur"),shadowOffsetX:n.get("shadowOffsetX"),shadowOffsetY:n.get("shadowOffsetY"),textShadowColor:r.get("textShadowColor"),textShadowBlur:r.get("textShadowBlur")||0,textShadowOffsetX:r.get("textShadowOffsetX")||0,textShadowOffsetY:r.get("textShadowOffsetY")||0,fill:n.get(["textStyle","color"]),padding:Id(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),this._zr.add(this.el);var a=this;this.el.on("mouseover",function(){a._enterable&&(clearTimeout(a._hideTimeout),a._show=!0),a._inContent=!0}),this.el.on("mouseout",function(){a._enterable&&a._show&&a.hideLater(a._hideDelay),a._inContent=!1})},Y3.prototype.setEnterable=function(t){this._enterable=t},Y3.prototype.getSize=function(){var t=this.el,e=this.el.getBoundingRect(),t=j3(t.style);return[e.width+t.left+t.right,e.height+t.top+t.bottom]},Y3.prototype.moveTo=function(t,e){var n,i,o=this.el;o&&(q3(n=this._styleCoord,this._zr,t,e),t=n[0],e=n[1],n=Z3((i=o.style).borderWidth||0),i=j3(i),o.x=t+n+i.left,o.y=e+n+i.top,o.markRedraw())},Y3.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},Y3.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},Y3.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(X(this.hide,this),t)):this.hide())},Y3.prototype.isShow=function(){return this._show},Y3.prototype.dispose=function(){this._zr.remove(this.el)},Y3),Q3=X,$3=G,tV=go,eV=new Ts({shape:{x:-1,y:-1,width:2,height:2}});function nV(){var t=null!==K3&&K3.apply(this,arguments)||this;return t.type=nV.type,t}function iV(t,e,n){for(var i=e.ecModel,o=n?(o=new wu(n,i,i),new wu(e.option,o,i)):e,r=t.length-1;0<=r;r--){var a=t[r];a&&((a=K(a=a instanceof wu?a.get("tooltip",!0):a)?{formatter:a}:a)&&(o=new wu(a,o,i)))}return o}function oV(t,e){return t.dispatchAction||X(e.dispatchAction,e)}function rV(t){return"center"===t||"middle"===t}var aV=(d(nV,K3=Wd),nV.prototype.init=function(t,e){var n;w.node||(t=(n=t.getComponent("tooltip")).get("renderMode"),this._renderMode="auto"===(t=t)?w.domSupported?"html":"richText":t||"html",this._tooltipContent="richText"===this._renderMode?new J3(e):new U3(e.getDom(),e,{appendToBody:n.get("appendToBody",!0)}))},nV.prototype.render=function(t,e,n){w.node||(this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._alwaysShowContent=t.get("alwaysShowContent"),(n=this._tooltipContent).update(t),n.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._updatePosition="html"===this._renderMode?of(Q3(this._doUpdatePosition,this),50):this._doUpdatePosition)},nV.prototype._initGlobalListener=function(){var i=this._tooltipModel.get("triggerOn");qN("itemTooltip",this._api,Q3(function(t,e,n){"none"!==i&&(0<=i.indexOf(t)?this._tryShow(e,n):"leave"===t&&this._hide(n))},this))},nV.prototype._keepShow=function(){var t,e=this._tooltipModel,n=this._ecModel,i=this._api;null!=this._lastX&&null!=this._lastY&&"none"!==e.get("triggerOn")&&(t=this,clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){i.isDisposed()||t.manuallyShowTip(e,n,i,{x:t._lastX,y:t._lastY,dataByCoordSys:t._lastDataByCoordSys})}))},nV.prototype.manuallyShowTip=function(t,e,n,i){var o,r,a,s;i.from===this.uid||w.node||(o=oV(i,n),this._ticket="",s=i.dataByCoordSys,(a=function(n,t,e){var i=Ko(n).queryOptionMap,o=i.keys()[0];if(o&&"series"!==o){var r,i=$o(t,o,i.get(o),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(i)return e.getViewOfComponentModel(i).group.traverse(function(t){var e=Gs(t).tooltipConfig;if(e&&e.name===n.name)return r=t,!0}),r?{componentMainType:o,componentIndex:i.componentIndex,el:r}:void 0}}(i,e,n))?((r=a.el.getBoundingRect().clone()).applyTransform(a.el.transform),this._tryShow({offsetX:r.x+r.width/2,offsetY:r.y+r.height/2,target:a.el,position:i.position,positionDefault:"bottom"},o)):i.tooltip&&null!=i.x&&null!=i.y?((a=eV).x=i.x,a.y=i.y,a.update(),Gs(a).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:a},o)):s?this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:s,tooltipOption:i.tooltipOption},o):null!=i.seriesIndex?this._manuallyAxisShowTip(t,e,n,i)||(t=(s=nz(i,e)).point[0],e=s.point[1],null!=t&&null!=e&&this._tryShow({offsetX:t,offsetY:e,target:s.el,position:i.position,positionDefault:"bottom"},o)):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},o)))},nV.prototype.manuallyHideTip=function(t,e,n,i){var o=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(oV(i,n))},nV.prototype._manuallyAxisShowTip=function(t,e,n,i){var o=i.seriesIndex,r=i.dataIndex,a=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=o&&null!=r&&null!=a){e=e.getSeriesByIndex(o);if(e)if("axis"===iV([e.getData().getItemModel(r),e,(e.coordinateSystem||{}).model],this._tooltipModel).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:r,position:i.position}),!0}},nV.prototype._tryShow=function(t,e){var n,i,o,r=t.target;this._tooltipModel&&(this._lastX=t.offsetX,this._lastY=t.offsetY,(n=t.dataByCoordSys)&&n.length?this._showAxisTooltip(n,t):r?(Gf(r,function(t){return null!=Gs(t).dataIndex?(i=t,1):null!=Gs(t).tooltipConfig&&(o=t,1)},!(this._lastDataByCoordSys=null)),i?this._showSeriesItemTooltip(t,i,e):o?this._showComponentItemTooltip(t,o,e):this._hide(e)):(this._lastDataByCoordSys=null,this._hide(e)))},nV.prototype._showOrMove=function(t,e){t=t.get("showDelay");e=X(e,this),clearTimeout(this._showTimout),0<t?this._showTimout=setTimeout(e,t):e()},nV.prototype._showAxisTooltip=function(t,e){var l=this._ecModel,n=this._tooltipModel,i=[e.offsetX,e.offsetY],o=iV([e.tooltipOption],n),u=this._renderMode,h=[],c=md("section",{blocks:[],noHeader:!0}),p=[],d=new Td;$3(t,function(t){$3(t.dataByAxis,function(i){var o,r,a=l.getComponent(i.axisDim+"Axis",i.axisIndex),s=i.value;a&&null!=s&&(o=PN(s,a.axis,l,i.seriesDataIndices,i.valueLabelOpt),r=md("section",{header:o,noHeader:!ht(o),sortBlocks:!0,blocks:[]}),c.blocks.push(r),G(i.seriesDataIndices,function(t){var e=l.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,t=e.getDataParams(n);t.dataIndex<0||(t.axisDim=i.axisDim,t.axisIndex=i.axisIndex,t.axisType=i.axisType,t.axisId=i.axisId,t.axisValue=tM(a.axis,{value:s}),t.axisValueLabel=o,t.marker=d.makeTooltipMarker("item",yh(t.color),u),(n=xp(e.formatTooltip(n,!0,null))).markupFragment&&r.blocks.push(n.markupFragment),n.markupText&&p.push(n.markupText),h.push(t))}))})}),c.blocks.reverse(),p.reverse();var r=e.position,e=o.get("order"),e=_d(c,d,u,e,l.get("useUTC"),o.get("textStyle"));e&&p.unshift(e);var a=p.join("richText"===u?"\n\n":"<br/>");this._showOrMove(o,function(){this._updateContentNotChangedOnAxis(t,h)?this._updatePosition(o,r,i[0],i[1],this._tooltipContent,h):this._showTooltipContent(o,a,h,Math.random()+"",i[0],i[1],r,null,d)})},nV.prototype._showSeriesItemTooltip=function(t,e,n){var i,o,r,a,s=this._ecModel,l=Gs(e),u=l.seriesIndex,h=s.getSeriesByIndex(u),c=l.dataModel||h,p=l.dataIndex,d=l.dataType,f=c.getData(d),e=this._renderMode,l=t.positionDefault,g=iV([f.getItemModel(p),c,h&&(h.coordinateSystem||{}).model],this._tooltipModel,l?{position:l}:null),l=g.get("trigger");null!=l&&"item"!==l||(i=c.getDataParams(p,d),o=new Td,i.marker=o.makeTooltipMarker("item",yh(i.color),e),l=xp(c.formatTooltip(p,!1,d)),d=g.get("order"),r=l.markupFragment?_d(l.markupFragment,o,e,d,s.get("useUTC"),g.get("textStyle")):l.markupText,a="item_"+c.name+"_"+p,this._showOrMove(g,function(){this._showTooltipContent(g,r,i,a,t.offsetX,t.offsetY,t.position,t.target,o)}),n({type:"showTip",dataIndexInside:p,dataIndex:f.getRawIndex(p),seriesIndex:u,from:this.uid}))},nV.prototype._showComponentItemTooltip=function(e,n,t){var i=Gs(n),o=i.tooltipConfig.option||{},r=[o=K(o)?{content:o,formatter:o}:o],i=this._ecModel.getComponent(i.componentMainType,i.componentIndex);i&&r.push(i),r.push({formatter:o.content});var o=e.positionDefault,a=iV(r,this._tooltipModel,o?{position:o}:null),s=a.get("content"),l=Math.random()+"",u=new Td;this._showOrMove(a,function(){var t=P(a.get("formatterParams")||{});this._showTooltipContent(a,s,t,l,e.offsetX,e.offsetY,e.position,n,u)}),t({type:"showTip",from:this.uid})},nV.prototype._showTooltipContent=function(n,t,i,e,o,r,a,s,l){var u,h,c,p,d;this._ticket="",n.get("showContent")&&n.get("show")&&(u=this._tooltipContent,h=n.get("formatter"),a=a||n.get("position"),p=t,c=this._getNearestPoint([o,r],i,n.get("trigger"),n.get("borderColor")).color,h&&(p=K(h)?(d=n.ecModel.get("useUTC"),p=h,gh(p=(t=j(i)?i[0]:i)&&t.axisType&&0<=t.axisType.indexOf("time")?Uu(t.axisValue,p,d):p,i,!0)):q(h)?(d=Q3(function(t,e){t===this._ticket&&(u.setContent(e,l,n,c,a),this._updatePosition(n,a,o,r,u,i,s))},this),this._ticket=e,h(i,e,d)):h),u.setContent(p,l,n,c,a),u.show(n,c),this._updatePosition(n,a,o,r,u,i,s))},nV.prototype._getNearestPoint=function(t,e,n,i){return"axis"===n||j(e)?{color:i||("html"===this._renderMode?"#fff":"none")}:j(e)?void 0:{color:i||e.color||e.borderColor}},nV.prototype._doUpdatePosition=function(t,e,n,i,o,r,a){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var u,h,c,p,d,f=o.getSize(),g=t.get("align"),y=t.get("verticalAlign"),m=a&&a.getBoundingRect().clone();a&&m.applyTransform(a.transform),j(e=q(e)?e([n,i],r,o.el,m,{viewSize:[s,l],contentSize:f.slice()}):e)?(n=tV(e[0],s),i=tV(e[1],l)):$(e)?((p=e).width=f[0],p.height=f[1],n=(d=Sh(p,{width:s,height:l})).x,i=d.y,y=g=null):i=(n=K(e)&&a?(u=function(t,e,n,i){var o=n[0],r=n[1],a=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,u=e.width,h=e.height;switch(t){case"inside":s=e.x+u/2-o/2,l=e.y+h/2-r/2;break;case"top":s=e.x+u/2-o/2,l=e.y-r-a;break;case"bottom":s=e.x+u/2-o/2,l=e.y+h+a;break;case"left":s=e.x-o-a,l=e.y+h/2-r/2;break;case"right":s=e.x+u+a,l=e.y+h/2-r/2}return[s,l]}(e,m,f,t.get("borderWidth")))[0]:(h=n,c=i,r=s,p=l,d=g?null:20,a=y?null:20,e=(m=(e=o).getSize())[0],m=m[1],null!=d&&(r<h+e+d+2?h-=e+d:h+=d),null!=a&&(p<c+m+a?c-=m+a:c+=a),(u=[h,c])[0]),u[1]),g&&(n-=rV(g)?f[0]/2:"right"===g?f[0]:0),y&&(i-=rV(y)?f[1]/2:"bottom"===y?f[1]:0),R3(t)&&(g=n,y=i,f=s,t=l,s=(l=(s=o).getSize())[0],l=l[1],g=Math.min(g+s,f)-s,y=Math.min(y+l,t)-l,g=Math.max(g,0),y=Math.max(y,0),n=(u=[g,y])[0],i=u[1]),o.moveTo(n,i)},nV.prototype._updateContentNotChangedOnAxis=function(n,r){var t=this._lastDataByCoordSys,a=this._cbParamsList,s=!!t&&t.length===n.length;return s&&$3(t,function(t,e){var t=t.dataByAxis||[],o=(n[e]||{}).dataByAxis||[];(s=s&&t.length===o.length)&&$3(t,function(t,e){var n=o[e]||{},e=t.seriesDataIndices||[],i=n.seriesDataIndices||[];(s=s&&t.value===n.value&&t.axisType===n.axisType&&t.axisId===n.axisId&&e.length===i.length)&&$3(e,function(t,e){e=i[e];s=s&&t.seriesIndex===e.seriesIndex&&t.dataIndex===e.dataIndex}),a&&G(t.seriesDataIndices,function(t){var e=t.seriesIndex,t=r[e],e=a[e];t&&e&&e.data!==t.data&&(s=!1)})})}),this._lastDataByCoordSys=n,this._cbParamsList=r,!!s},nV.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},nV.prototype.dispose=function(t,e){w.node||(this._tooltipContent.dispose(),QN("itemTooltip",e))},nV.type="tooltip",nV);var sV=["rect","polygon","keep","clear"];function lV(t,e){var n,i,o,r=No(t?t.brush:[]);r.length&&(n=[],G(r,function(t){t=t.hasOwnProperty("toolbox")?t.toolbox:[];t instanceof Array&&(n=n.concat(t))}),(r=j(r=t&&t.toolbox)?r[0]:r)||(t.toolbox=[r={feature:{}}]),(r=(r=(r=r.feature||(r.feature={})).brush||(r.brush={})).type||(r.type=[])).push.apply(r,n),o={},G(i=r,function(t){o[t]=1}),i.length=0,G(o,function(t,e){i.push(e)}),e&&!r.length&&r.push.apply(r,sV))}var uV=G;function hV(t){if(t)for(var e in t)if(t.hasOwnProperty(e))return 1}function cV(e,t,o){var r={};return uV(t,function(n){var i=r[n]=(t.prototype.__hidden=t.prototype,new t);function t(){}uV(e[n],function(t,e){vC.isValidType(e)&&(t={type:e,visual:t},o&&o(t,n),i[e]=new vC(t),"opacity"===e&&((t=P(t)).type="colorAlpha",i.__hidden.__alphaForOpacity=new vC(t)))})}),r}function pV(e,n,t){var i;G(t,function(t){n.hasOwnProperty(t)&&hV(n[t])&&(i=!0)}),i&&G(t,function(t){n.hasOwnProperty(t)&&hV(n[t])?e[t]=P(n[t]):delete e[t]})}var dV={lineX:fV(0),lineY:fV(1),rect:{point:function(t,e,n){return t&&n.boundingRect.contain(t[0],t[1])},rect:function(t,e,n){return t&&n.boundingRect.intersect(t)}},polygon:{point:function(t,e,n){return t&&n.boundingRect.contain(t[0],t[1])&&l0(n.range,t[0],t[1])},rect:function(t,e,n){var i=n.range;if(!t||i.length<=1)return!1;var o=t.x,r=t.y,a=t.width,s=t.height,n=i[0];return!!(l0(i,o,r)||l0(i,o+a,r)||l0(i,o,r+s)||l0(i,o+a,r+s)||ki.create(t).contain(n[0],n[1])||$y(o,r,o+a,r,i)||$y(o,r,o,r+s,i)||$y(o+a,r,o+a,r+s,i)||$y(o,r+s,o+a,r+s,i))||void 0}}};function fV(i){var o=["x","y"],r=["width","height"];return{point:function(t,e,n){if(t){n=n.range;return gV(t[i],n)}},rect:function(t,e,n){if(t){n=n.range,t=[t[o[i]],t[o[i]]+t[r[i]]];return t[1]<t[0]&&t.reverse(),gV(t[0],n)||gV(t[1],n)||gV(n[0],t)||gV(n[1],t)}}}}function gV(t,e){return e[0]<=t&&t<=e[1]}var yV=["inBrush","outOfBrush"],mV="__ecBrushSelect",vV="__ecInBrushSelectEvent";function xV(e){e.eachComponent({mainType:"brush"},function(t){(t.brushTargetManager=new I3(t.option,e)).setInputRanges(t.areas,e)})}function _V(s,t,e){var l,u,n,i,o,r,h=[];s.eachComponent({mainType:"brush"},function(t){e&&"takeGlobalCursor"===e.type&&t.setBrushOption("brush"===e.key?e.brushOption:{brushType:!1})}),xV(s),s.eachComponent({mainType:"brush"},function(o,t){var y={brushId:o.id,brushIndex:t,brushName:o.name,areas:P(o.areas),selected:[]};h.push(y);var e=o.option,n=e.brushLink,i=[],m=[],v=[],x=!1;t||(l=e.throttleType,u=e.throttleDelay);var r=H(o.areas,function(t){var e,n,i,o=SV[t.brushType],t=z({boundingRect:o?o(t):void 0},t);return t.selectors=(n=(e=t).brushType,i={point:function(t){return dV[n].point(t,i,e)},rect:function(t){return dV[n].rect(t,i,e)}}),t}),_=cV(o.option,yV,function(t){t.mappingMethod="fixed"});function b(t){return"all"===n||i[t]}function w(t){return!!t.length}function a(e,t,n){var i;e.brushSelector&&!function(t,e){t=t.option.seriesIndex;return null!=t&&"all"!==t&&(j(t)?V(t,e)<0:e!==t)}(o,t)&&(G(r,function(t){o.brushTargetManager.controlSeries(t,e,s)&&n.push(t),x=x||w(n)}),b(t)&&w(n))&&(i=e.getData()).each(function(t){wV(e,n,i,t)&&(m[t]=1)})}j(n)&&G(n,function(t){i[t]=1}),s.eachSeries(function(t,e){var n,i,o,r=v[e]=[];"parallel"===t.subType?(i=e,o=(n=t).coordinateSystem,x=x||o.hasAxisBrushed(),b(i)&&o.eachActiveState(n.getData(),function(t,e){"active"===t&&(m[e]=1)})):a(t,e,r)}),s.eachSeries(function(e,t){var n={seriesId:e.id,seriesIndex:t,seriesName:e.name,dataIndex:[]};y.selected.push(n);var s,l,u,h,c,p,d,i=v[t],o=e.getData(),r=b(t)?function(t){return m[t]?(n.dataIndex.push(o.getRawIndex(t)),"inBrush"):"outOfBrush"}:function(t){return wV(e,i,o,t)?(n.dataIndex.push(o.getRawIndex(t)),"inBrush"):"outOfBrush"};function f(t){return zf(l,p,t)}function g(t,e){Vf(l,p,t,e)}function a(t,e){p=null==c?t:e;e=l.getRawDataItem(p);if(!e||!1!==e.visualMap)for(var e=u.call(h,t),n=s[e],i=d[e],o=0,r=i.length;o<r;o++){var a=i[o];n[a]&&n[a].applyVisual(t,f,g)}}(b(t)?x:w(i))&&(s=_,l=o,u=r,d={},G(yV,function(t){var e=vC.prepareVisualTypes(s[t]);d[t]=e}),null==c?l.each(a):l.each([c],a))})}),n=t,i=l,o=u,r=h,(t=e)&&((t=n.getZr())[vV]||(t[mV]||(t[mV]=bV),rf(t,mV,o,i)(n,r)))}function bV(t,e){var n;t.isDisposed()||((n=t.getZr())[vV]=!0,t.dispatchAction({type:"brushSelect",batch:e}),n[vV]=!1)}function wV(t,e,n,i){for(var o=0,r=e.length;o<r;o++){var a=e[o];if(t.brushSelector(i,n,a.selectors,a))return 1}}var SV={rect:function(t){return MV(t.range)},polygon:function(t){for(var e=t.range,n=0,i=e.length;n<i;n++){var o=o||[[1/0,-1/0],[1/0,-1/0]],r=e[n];r[0]<o[0][0]&&(o[0][0]=r[0]),r[0]>o[0][1]&&(o[0][1]=r[0]),r[1]<o[1][0]&&(o[1][0]=r[1]),r[1]>o[1][1]&&(o[1][1]=r[1])}return o&&MV(o)}};function MV(t){return new ki(t[0][0],t[1][0],t[0][1]-t[0][0],t[1][1]-t[1][0])}var IV,TV,CV=(d(AV,TV=Wd),AV.prototype.init=function(t,e){this.ecModel=t,this.api=e,this.model,(this._brushController=new lL(e.getZr())).on("brush",X(this._onBrush,this)).mount()},AV.prototype.render=function(t,e,n,i){this.model=t,this._updateController(t,e,n,i)},AV.prototype.updateTransform=function(t,e,n,i){xV(e),this._updateController(t,e,n,i)},AV.prototype.updateVisual=function(t,e,n,i){this.updateTransform(t,e,n,i)},AV.prototype.updateView=function(t,e,n,i){this._updateController(t,e,n,i)},AV.prototype._updateController=function(t,e,n,i){i&&i.$from===t.id||this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},AV.prototype.dispose=function(){this._brushController.dispose()},AV.prototype._onBrush=function(t){var e=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);t.isEnd&&!t.removeOnClick||this.api.dispatchAction({type:"brush",brushId:e,areas:P(n),$from:e}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:e,areas:P(n),$from:e})},AV.type="brush",AV);function DV(){var t=null!==IV&&IV.apply(this,arguments)||this;return t.type=DV.type,t.areas=[],t.brushOption={},t}function AV(){var t=null!==TV&&TV.apply(this,arguments)||this;return t.type=AV.type,t}function kV(t,e){return O({brushType:t.brushType,brushMode:t.brushMode,transformable:t.transformable,brushStyle:new wu(t.brushStyle).getItemStyle(),removeOnClick:t.removeOnClick,z:t.z},e,!0)}var LV,PV=(d(DV,IV=Vh),DV.prototype.optionUpdated=function(t,e){var n=this.option;e||pV(n,t,["inBrush","outOfBrush"]);t=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:"#ddd"},t.hasOwnProperty("liftZ")||(t.liftZ=5)},DV.prototype.setAreas=function(t){t&&(this.areas=H(t,function(t){return kV(this.option,t)},this))},DV.prototype.setBrushOption=function(t){this.brushOption=kV(this.option,t),this.brushType=this.brushOption.brushType},DV.type="brush",DV.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],DV.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},DV),OV=["rect","polygon","lineX","lineY","keep","clear"],RV=(d(NV,LV=LE),NV.prototype.render=function(e,t,n){var i,o,r;t.eachComponent({mainType:"brush"},function(t){i=t.brushType,o=t.brushOption.brushMode||"single",r=r||!!t.areas.length}),this._brushType=i,this._brushMode=o,G(e.get("type",!0),function(t){e.setIconStatus(t,("keep"===t?"multiple"===o:"clear"===t?r:t===i)?"emphasis":"normal")})},NV.prototype.updateView=function(t,e,n){this.render(t,e,n)},NV.prototype.getIcons=function(){var t=this.model,e=t.get("icon",!0),n={};return G(t.get("type",!0),function(t){e[t]&&(n[t]=e[t])}),n},NV.prototype.onclick=function(t,e,n){var i=this._brushType,o=this._brushMode;"clear"===n?(e.dispatchAction({type:"axisAreaSelect",intervals:[]}),e.dispatchAction({type:"brush",command:"clear",areas:[]})):e.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:"keep"===n?i:i!==n&&n,brushMode:"keep"===n?"multiple"===o?"single":"multiple":o}})},NV.getDefaultOption=function(t){return{show:!0,type:OV.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])}},NV);function NV(){return null!==LV&&LV.apply(this,arguments)||this}var zV,EV,VV=(d(GV,EV=Vh),GV.type="title",GV.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:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},GV),BV=(d(FV,zV=Wd),FV.prototype.render=function(t,e,n){var i,o,r,a,s,l,u,h,c;this.group.removeAll(),t.get("show")&&(i=this.group,u=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),c=rt(t.get("textBaseline"),t.get("textVerticalAlign")),h=(r=new Fs({style:eu(u,{text:t.get("text"),fill:u.getTextColor()},{disableBox:!0}),z2:10})).getBoundingRect(),u=t.get("subtext"),a=new Fs({style:eu(a,{text:u,fill:a.getTextColor(),y:h.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),s=t.get("link"),l=t.get("sublink"),h=t.get("triggerEvent",!0),r.silent=!s&&!h,a.silent=!l&&!h,s&&r.on("click",function(){mh(s,"_"+t.get("target"))}),l&&a.on("click",function(){mh(l,"_"+t.get("subtarget"))}),Gs(r).eventData=Gs(a).eventData=h?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(r),u&&i.add(a),h=i.getBoundingRect(),(u=t.getBoxLayoutParams()).width=h.width,u.height=h.height,n=Sh(u,{width:n.getWidth(),height:n.getHeight()},t.get("padding")),o||("right"===(o="middle"===(o=t.get("left")||t.get("right"))?"center":o)?n.x+=n.width:"center"===o&&(n.x+=n.width/2)),c||("bottom"===(c="center"===(c=t.get("top")||t.get("bottom"))?"middle":c)?n.y+=n.height:"middle"===c&&(n.y+=n.height/2),c=c||"top"),i.x=n.x,i.y=n.y,i.markRedraw(),r.setStyle(c={align:o,verticalAlign:c}),a.setStyle(c),h=i.getBoundingRect(),c=n.margin,(n=t.getItemStyle(["color","opacity"])).fill=t.get("backgroundColor"),n=new Ts({shape:{x:h.x-c[3],y:h.y-c[0],width:h.width+c[1]+c[3],height:h.height+c[0]+c[2],r:t.get("borderRadius")},style:n,subPixelOptimize:!0,silent:!0}),i.add(n))},FV.type="title",FV);function FV(){var t=null!==zV&&zV.apply(this,arguments)||this;return t.type=FV.type,t}function GV(){var t=null!==EV&&EV.apply(this,arguments)||this;return t.type=GV.type,t.layoutMode={type:"box",ignoreSize:!0},t}var HV,WV,io=(d(YV,WV=Vh),YV.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._initData()},YV.prototype.mergeOption=function(t){WV.prototype.mergeOption.apply(this,arguments),this._initData()},YV.prototype.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:t)<0&&(t=0),this.option.currentIndex=t},YV.prototype.getCurrentIndex=function(){return this.option.currentIndex},YV.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},YV.prototype.setPlayState=function(t){this.option.autoPlay=!!t},YV.prototype.getPlayState=function(){return!!this.option.autoPlay},YV.prototype._initData=function(){var o,t=this.option,e=t.data||[],t=t.axisType,r=this._names=[];"category"===t?(o=[],G(e,function(t,e){var n,i=Ho(Vo(t),"");$(t)?(n=P(t)).value=e:n=e,o.push(n),r.push(i)})):o=e,(this._data=new c_([{name:"value",type:{category:"ordinal",time:"time",value:"number"}[t]||"number"}],this)).initData(o,r)},YV.prototype.getData=function(){return this._data},YV.prototype.getCategories=function(){if("category"===this.get("axisType"))return this._names.slice()},YV.type="timeline",YV.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:[]},YV),io=(d(UV,HV=io),UV.type="timeline.slider",UV.defaultOption=Iu(io.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),UV);function UV(){var t=null!==HV&&HV.apply(this,arguments)||this;return t.type=UV.type,t}function YV(){var t=null!==WV&&WV.apply(this,arguments)||this;return t.type=YV.type,t.layoutMode="box",t}B(io,fu.prototype);var XV,ZV,jV,qV=io,io=(d(eB,jV=Wd),eB.type="timeline",eB),KV=(d(tB,ZV=_),tB.prototype.getLabelModel=function(){return this.model.getModel("label")},tB.prototype.isHorizontal=function(){return"horizontal"===this.model.get("orient")},tB),JV=Math.PI,QV=Zo();function $V(){var t=null!==XV&&XV.apply(this,arguments)||this;return t.type=$V.type,t}function tB(t,e,n,i){n=ZV.call(this,t,e,n)||this;return n.type=i||"value",n}function eB(){var t=null!==jV&&jV.apply(this,arguments)||this;return t.type=eB.type,t}function nB(t,e,n,i,o,r){var a=e.get("color");o?(o.setColor(a),n.add(o),r&&r.onUpdate(o)):((o=am(t.get("symbol"),-1,-1,2,2,a)).setStyle("strokeNoScale",!0),n.add(o),r&&r.onCreate(o));e=e.getItemStyle(["color"]);o.setStyle(e),i=O({rectHover:!0,z2:100},i,!0);e=sm(t.get("symbolSize"));i.scaleX=e[0]/2,i.scaleY=e[1]/2;e=lm(t.get("symbolOffset"),e);e&&(i.x=(i.x||0)+e[0],i.y=(i.y||0)+e[1]);t=t.get("symbolRotate");return i.rotation=(t||0)*Math.PI/180||0,o.attr(i),o.updateTransform(),o}function iB(t,e,n,i,o,r){var a;t.dragging||(a=o.getModel("checkpointStyle"),n=i.dataToCoord(o.getData().get("value",n)),r||!a.get("animation",!0)?(t.attr({x:n,y:0}),e&&e.attr({shape:{x2:n}})):(a={duration:a.get("animationDuration",!0),easing:a.get("animationEasing",!0)},t.stopAnimation(null,!0),t.animateTo({x:n,y:0},a),e&&e.animateTo({shape:{x2:n}},a)))}var oB=(d($V,XV=io),$V.prototype.init=function(t,e){this.api=e},$V.prototype.render=function(e,t,n){var i,o,r;this.model=e,this.api=n,this.ecModel=t,this.group.removeAll(),e.get("show",!0)&&(i=this._layout(e,n),o=this._createGroup("_mainGroup"),n=this._createGroup("_labelGroup"),r=this._axis=this._createAxis(i,e),e.formatTooltip=function(t){return md("nameValue",{noName:!0,value:r.scale.getLabel({value:t})})},G(["AxisLine","AxisTick","Control","CurrentPointer"],function(t){this["_render"+t](i,o,r,e)},this),this._renderAxisLabel(i,n,r,e),this._position(i,e)),this._doPlayStop(),this._updateTicksStatus()},$V.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},$V.prototype.dispose=function(){this._clearTimer()},$V.prototype._layout=function(t,e){var n,i,o,r=t.get(["label","position"]),a=t.get("orient"),s=(x=e,Sh((_=t).getBoxLayoutParams(),{width:x.getWidth(),height:x.getHeight()},_.get("padding"))),l=null==r||"auto"===r?"horizontal"===a?s.y+s.height/2<e.getHeight()/2?"-":"+":s.x+s.width/2<e.getWidth()/2?"+":"-":K(r)?{horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[a][r]:r,u={horizontal:"center",vertical:0<=l||"+"===l?"left":"right"},h={horizontal:0<=l||"+"===l?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:JV/2},p="vertical"===a?s.height:s.width,d=t.getModel("controlStyle"),f=d.get("show",!0),g=f?d.get("itemSize"):0,y=f?d.get("itemGap"):0,m=g+y,v=(v=t.get(["label","rotate"])||0)*JV/180,x=d.get("position",!0),_=f&&d.get("showPlayBtn",!0),e=f&&d.get("showPrevBtn",!0),r=f&&d.get("showNextBtn",!0),f=0,d=p;"left"===x||"bottom"===x?(_&&(n=[0,0],f+=m),e&&(i=[f,0],f+=m)):(_&&(n=[d-g,0],d-=m),e&&(i=[0,0],f+=m)),r&&(o=[d-g,0],d-=m);d=[f,d];return t.get("inverse")&&d.reverse(),{viewRect:s,mainLength:p,orient:a,rotation:c[a],labelRotation:v,labelPosOpt:l,labelAlign:t.get(["label","align"])||u[a],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||h[a],playPosition:n,prevBtnPosition:i,nextBtnPosition:o,axisExtent:d,controlSize:g,controlGap:y}},$V.prototype._position=function(t,e){var n=this._mainGroup,i=this._labelGroup,o=t.viewRect;"vertical"===t.orient&&(ai(u=ni(),u,[-(s=o.x),-(l=o.y+o.height)]),si(u,u,-JV/2),ai(u,u,[s,l]),(o=o.clone()).applyTransform(u));var r=p(o),a=p(n.getBoundingRect()),s=p(i.getBoundingRect()),l=[n.x,n.y],u=[i.x,i.y];u[0]=l[0]=r[0][0];var h,o=t.labelPosOpt;function c(t){t.originX=r[0][0]-t.x,t.originY=r[1][0]-t.y}function p(t){return[[t.x,t.x+t.width],[t.y,t.y+t.height]]}function d(t,e,n,i,o){t[i]+=n[i][o]-e[i][o]}null==o||K(o)?(d(l,a,r,1,h="+"===o?0:1),d(u,s,r,1,1-h)):(d(l,a,r,1,h=0<=o?0:1),u[1]=l[1]+o),n.setPosition(l),i.setPosition(u),n.rotation=i.rotation=t.rotation,c(n),c(i)},$V.prototype._createAxis=function(t,e){var n=e.getData(),i=e.get("axisType"),o=function(t,e){if(e=e||t.get("type"))switch(e){case"category":return new MS({ordinalMeta:t.getCategories(),extent:[1/0,-1/0]});case"time":return new OS({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new DS}}(e,i);o.getTicks=function(){return n.mapArray(["value"],function(t){return{value:t}})};var r=n.getDataExtent("value");o.setExtent(r[0],r[1]),o.niceTicks();i=new KV("value",o,t.axisExtent,i);return i.model=e,i},$V.prototype._createGroup=function(t){t=this[t]=new ro;return this.group.add(t),t},$V.prototype._renderAxisLine=function(t,e,n,i){var o=n.getExtent();i.get(["lineStyle","show"])&&(n=new Kf({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:N({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1}),e.add(n),i=this._progressLine=new Kf({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:z({lineCap:"round",lineWidth:n.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1}),e.add(i))},$V.prototype._renderAxisTick=function(t,a,s,l){var u=this,h=l.getData(),e=s.scale.getTicks();this._tickSymbols=[],G(e,function(t){var e=s.dataToCoord(t.value),n=h.getItemModel(t.value),i=n.getModel("itemStyle"),o=n.getModel(["emphasis","itemStyle"]),r=n.getModel(["progress","itemStyle"]),e={x:e,y:0,onclick:X(u._changeTimeline,u,t.value)},e=nB(n,i,a,e);e.ensureState("emphasis").style=o.getItemStyle(),e.ensureState("progress").style=r.getItemStyle(),Ll(e);r=Gs(e);n.get("tooltip")?(r.dataIndex=t.value,r.dataModel=l):r.dataIndex=r.dataModel=null,u._tickSymbols.push(e)})},$V.prototype._renderAxisLabel=function(a,s,l,t){var u,h=this;l.getLabelModel().get("show")&&(u=t.getData(),t=l.getViewLabels(),this._tickLabels=[],G(t,function(t){var e=t.tickValue,n=u.getItemModel(e),i=n.getModel("label"),o=n.getModel(["emphasis","label"]),r=n.getModel(["progress","label"]),n=l.dataToCoord(t.tickValue),t=new Fs({x:n,y:0,rotation:a.labelRotation-a.rotation,onclick:X(h._changeTimeline,h,e),silent:!1,style:eu(i,{text:t.formattedLabel,align:a.labelAlign,verticalAlign:a.labelBaseline})});t.ensureState("emphasis").style=eu(o),t.ensureState("progress").style=eu(r),s.add(t),Ll(t),QV(t).dataIndex=e,h._tickLabels.push(t)}))},$V.prototype._renderControl=function(t,r,e,a){var s=t.controlSize,l=t.rotation,u=a.getModel("controlStyle").getItemStyle(),h=a.getModel(["emphasis","controlStyle"]).getItemStyle(),n=a.getPlayState(),i=a.get("inverse",!0);function o(t,e,n,i){var o;t&&(o=Wi(rt(a.get(["controlStyle",e+"BtnSize"]),s),s),e=e+"Icon",o=[0,-o/2,o,o],i={x:t[0],y:t[1],originX:s/2,originY:0,rotation:i?-l:0,rectHover:!0,style:u,onclick:n},n=i.style,o=Qy(a.get(["controlStyle",e]),i||{},new ki(o[0],o[1],o[2],o[3])),n&&o.setStyle(n),(o=o).ensureState("emphasis").style=h,r.add(o),Ll(o))}o(t.nextBtnPosition,"next",X(this._changeTimeline,this,i?"-":"+")),o(t.prevBtnPosition,"prev",X(this._changeTimeline,this,i?"+":"-")),o(t.playPosition,n?"stop":"play",X(this._handlePlayClick,this,!n),!0)},$V.prototype._renderCurrentPointer=function(t,e,n,i){var o=i.getData(),r=i.getCurrentIndex(),o=o.getItemModel(r).getModel("checkpointStyle"),a=this;this._currentPointer=nB(o,o,this._mainGroup,{},this._currentPointer,{onCreate:function(t){t.draggable=!0,t.drift=X(a._handlePointerDrag,a),t.ondragend=X(a._handlePointerDragend,a),iB(t,a._progressLine,r,n,i,!0)},onUpdate:function(t){iB(t,a._progressLine,r,n,i)}})},$V.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},$V.prototype._handlePointerDrag=function(t,e,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},$V.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},$V.prototype._pointerChangeTimeline=function(t,e){var n=this._toAxisCoord(t)[0],t=mo(this._axis.getExtent().slice());(n=n>t[1]?t[1]:n)<t[0]&&(n=t[0]),this._currentPointer.x=n,this._currentPointer.markRedraw(),this._progressLine.shape.x2=n,this._progressLine.dirty();t=this._findNearestTick(n),n=this.model;(e||t!==n.getCurrentIndex()&&n.get("realtime"))&&this._changeTimeline(t)},$V.prototype._doPlayStop=function(){var e=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var t=e.model;e._changeTimeline(t.getCurrentIndex()+(t.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},$V.prototype._toAxisCoord=function(t){return Xy(t,this._mainGroup.getLocalTransform(),!0)},$V.prototype._findNearestTick=function(n){var i,t=this.model.getData(),o=1/0,r=this._axis;return t.each(["value"],function(t,e){t=r.dataToCoord(t),t=Math.abs(t-n);t<o&&(o=t,i=e)}),i},$V.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},$V.prototype._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})},$V.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),e=this._tickSymbols,n=this._tickLabels;if(e)for(var i=0;i<e.length;i++)e&&e[i]&&e[i].toggleState("progress",i<t);if(n)for(i=0;i<n.length;i++)n&&n[i]&&n[i].toggleState("progress",QV(n[i]).dataIndex<=t)},$V.type="timeline.slider",$V);function rB(t){t=t&&t.timeline;G(t=!j(t)?t?[t]:[]:t,function(t){t&&function(t){var e=t.type,n={number:"value",time:"time"};n[e]&&(t.axisType=n[e],delete t.type),aB(t),sB(t,"controlPosition")&&(sB(e=t.controlStyle||(t.controlStyle={}),"position")||(e.position=t.controlPosition),"none"!==e.position||sB(e,"show")||(e.show=!1,delete e.position),delete t.controlPosition);G(t.data||[],function(t){$(t)&&!j(t)&&(!sB(t,"value")&&sB(t,"name")&&(t.value=t.name),aB(t))})}(t)})}function aB(t){var e=t.itemStyle||(t.itemStyle={}),e=e.emphasis||(e.emphasis={}),t=t.label||t.label||{},n=t.normal||(t.normal={}),i={normal:1,emphasis:1};G(t,function(t,e){i[e]||sB(n,e)||(n[e]=t)}),e.label&&!sB(t,"emphasis")&&(t.emphasis=e.label,delete e.label)}function sB(t,e){return t.hasOwnProperty(e)}function lB(t,e){if(t)for(var n=j(t)?t:[t],i=0;i<n.length;i++)if(n[i]&&n[i][e])return 1}function uB(t){zo(t,"label",["show"])}var hB,cB=Zo(),io=(d(pB,hB=Vh),pB.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._mergeOption(t,n,!1,!0)},pB.prototype.isAnimationEnabled=function(){if(w.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},pB.prototype.mergeOption=function(t,e){this._mergeOption(t,e,!1,!1)},pB.prototype._mergeOption=function(t,i,e,o){var r=this.mainType;e||i.eachSeries(function(t){var e=t.get(this.mainType,!0),n=cB(t)[r];e&&e.data?(n?n._mergeOption(e,i,!0):(o&&uB(e),G(e.data,function(t){t instanceof Array?(uB(t[0]),uB(t[1])):uB(t)}),N(n=this.createMarkerModelFromSeries(e,this,i),{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),n.__hostSeries=t),cB(t)[r]=n):cB(t)[r]=null},this)},pB.prototype.formatTooltip=function(t,e,n){var i=this.getData(),o=this.getRawValue(t),t=i.getName(t);return md("section",{header:this.name,blocks:[md("nameValue",{name:t,value:o,noName:!t,noValue:null==o})]})},pB.prototype.getData=function(){return this._data},pB.prototype.setData=function(t){this._data=t},pB.getMarkerModelFromSeries=function(t,e){return cB(t)[e]},pB.type="marker",pB.dependencies=["series","grid","polar","geo"],pB);function pB(){var t=null!==hB&&hB.apply(this,arguments)||this;return t.type=pB.type,t.createdBySelf=!1,t}B(io,fu.prototype);var dB,fB=io,gB=(d(yB,dB=fB),yB.prototype.createMarkerModelFromSeries=function(t,e,n){return new yB(t,e,n)},yB.type="markPoint",yB.defaultOption={zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},yB);function yB(){var t=null!==dB&&dB.apply(this,arguments)||this;return t.type=yB.type,t}function mB(t,e,n,i,o,r){var a=[],s=v_(e,i)?e.getCalculationInfo("stackResultDimension"):i,t=SB(e,s,t),t=e.indicesOfNearest(s,t)[0];a[o]=e.get(n,t),a[r]=e.get(s,t);s=e.get(i,t),t=vo(e.get(i,t));return 0<=(t=Math.min(t,20))&&(a[r]=+a[r].toFixed(t)),[a,s]}var vB={min:Z(mB,"min"),max:Z(mB,"max"),average:Z(mB,"average"),median:Z(mB,"median")};function xB(t,e){var n=t.getData(),i=t.coordinateSystem;if(e&&(r=e,isNaN(parseFloat(r.x))||isNaN(parseFloat(r.y)))&&!j(e.coord)&&i){var o=i.dimensions,r=_B(e,n,i,t);if((e=P(e)).type&&vB[e.type]&&r.baseAxis&&r.valueAxis){i=V(o,r.baseAxis.dim),t=V(o,r.valueAxis.dim),t=vB[e.type](n,r.baseDataDim,r.valueDataDim,i,t);e.coord=t[0],e.value=t[1]}else{for(var a=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis],s=0;s<2;s++)vB[a[s]]&&(a[s]=SB(n,n.mapDimension(o[s]),a[s]));e.coord=a}}return e}function _B(t,e,n,i){var o={};return null!=t.valueIndex||null!=t.valueDim?(o.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,o.valueAxis=n.getAxis(function(t,e){e=t.getData().getDimensionInfo(e);return e&&e.coordDim}(i,o.valueDataDim)),o.baseAxis=n.getOtherAxis(o.valueAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim)):(o.baseAxis=i.getBaseAxis(),o.valueAxis=n.getOtherAxis(o.baseAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim),o.valueDataDim=e.mapDimension(o.valueAxis.dim)),o}function bB(t,e){return!(t&&t.containData&&e.coord&&(n=e,isNaN(parseFloat(n.x))&&isNaN(parseFloat(n.y))))||t.containData(e.coord);var n}function wB(t,o){return t?function(t,e,n,i){return Pp(i<2?t.coord&&t.coord[i]:t.value,o[i])}:function(t,e,n,i){return Pp(t.value,o[i])}}function SB(t,e,n){if("average"!==n)return"median"===n?t.getMedian(e):t.getDataExtent(e)["max"===n?1:0];var i=0,o=0;return t.each(e,function(t,e){isNaN(t)||(i+=t,o++)}),i/o}var MB,IB,TB=Zo(),io=(d(CB,MB=Wd),CB.prototype.init=function(){this.markerGroupMap=yt()},CB.prototype.render=function(t,n,i){var o=this,e=this.markerGroupMap;e.each(function(t){TB(t).keep=!1}),n.eachSeries(function(t){var e=fB.getMarkerModelFromSeries(t,o.type);e&&o.renderSeries(t,e,n,i)}),e.each(function(t){TB(t).keep||o.group.remove(t.group)})},CB.prototype.markKeep=function(t){TB(t).keep=!0},CB.prototype.blurSeries=function(t){var e=this;G(t,function(t){t=fB.getMarkerModelFromSeries(t,e.type);t&&t.getData().eachItemGraphicEl(function(t){t&&bl(t)})})},CB.type="marker",CB);function CB(){var t=null!==MB&&MB.apply(this,arguments)||this;return t.type=CB.type,t}function DB(a,s,l){var u=s.coordinateSystem;a.each(function(t){var e,n,i=a.getItemModel(t),o=go(i.get("x"),l.getWidth()),r=go(i.get("y"),l.getHeight());isNaN(o)||isNaN(r)?s.getMarkerPosition?n=s.getMarkerPosition(a.getValues(a.dimensions,t)):u&&(e=a.get(u.dimensions[0],t),i=a.get(u.dimensions[1],t),n=u.dataToPoint([e,i])):n=[o,r],isNaN(o)||(n[0]=o),isNaN(r)||(n[1]=r),a.setItemLayout(t,n)})}function AB(){var t=null!==IB&&IB.apply(this,arguments)||this;return t.type=AB.type,t}var kB=(d(AB,IB=io),AB.prototype.updateTransform=function(t,e,n){e.eachSeries(function(t){var e=fB.getMarkerModelFromSeries(t,"markPoint");e&&(DB(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout())},this)},AB.prototype.renderSeries=function(t,u,e,n){var i=t.coordinateSystem,o=t.id,h=t.getData(),r=this.markerGroupMap,o=r.get(o)||r.set(o,new O_),c=function(t,e,n){o=t?H(t&&t.dimensions,function(t){return N(N({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})}):[{name:"value",type:"float"}];var i=new c_(o,n),n=H(n.get("data"),Z(xB,e));t&&(n=U(n,Z(bB,t)));var o=wB(!!t,o);return i.initData(n,null,o),i}(i,t,u);u.setData(c),DB(u.getData(),t,n),c.each(function(t){var e,n=c.getItemModel(t),i=n.getShallow("symbol"),o=n.getShallow("symbolSize"),r=n.getShallow("symbolRotate"),a=n.getShallow("symbolOffset"),s=n.getShallow("symbolKeepAspect");(q(i)||q(o)||q(r)||q(a))&&(e=u.getRawValue(t),l=u.getDataParams(t),q(i)&&(i=i(e,l)),q(o)&&(o=o(e,l)),q(r)&&(r=r(e,l)),q(a)&&(a=a(e,l)));var l=n.getModel("itemStyle").getItemStyle(),n=Ef(h,"color");l.fill||(l.fill=n),c.setItemVisual(t,{symbol:i,symbolSize:o,symbolRotate:r,symbolOffset:a,symbolKeepAspect:s,style:l})}),o.updateData(c),this.group.add(o.group),c.eachItemGraphicEl(function(t){t.traverse(function(t){Gs(t).dataModel=u})}),this.markKeep(o),o.group.silent=u.get("silent")||t.get("silent")},AB.type="markPoint",AB);function LB(t,e,n,i){var o,r,a,s=t.getData(),l=[xB(t,(l=j(i)?i:"min"===(o=i.type)||"max"===o||"average"===o||"median"===o||null!=i.xAxis||null!=i.yAxis?(l=r=void 0,l=null!=i.yAxis||null!=i.xAxis?(r=e.getAxis(null!=i.yAxis?"y":"x"),ot(i.yAxis,i.xAxis)):(r=(a=_B(i,s,e,t)).valueAxis,SB(s,x_(s,a.valueDataDim),o)),s=1-(e="x"===r.dim?0:1),a={coord:[]},(r=P(i)).type=null,r.coord=[],r.coord[s]=-1/0,a.coord[s]=1/0,0<=(n=n.get("precision"))&&"number"==typeof l&&(l=+l.toFixed(Math.min(n,20))),r.coord[e]=a.coord[e]=l,[r,a,{type:o,valueIndex:i.valueIndex,value:l}]):[])[0]),xB(t,l[1]),N({},l[2])];return l[2].type=l[2].type||null,O(l[2],l[0]),O(l[2],l[1]),l}var PB,OB,RB=(d(zB,PB=fB),zB.prototype.createMarkerModelFromSeries=function(t,e,n){return new zB(t,e,n)},zB.type="markLine",zB.defaultOption={zlevel:0,z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},zB),NB=Zo();function zB(){var t=null!==PB&&PB.apply(this,arguments)||this;return t.type=zB.type,t}function EB(t){return!isNaN(t)&&!isFinite(t)}function VB(t,e,n,i){var o=1-t,r=i.dimensions[t];return EB(e[o])&&EB(n[o])&&e[t]===n[t]&&i.getAxis(r).containData(e[t])}function BB(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(VB(1,n,i,t)||VB(0,n,i,t)))return!0}return bB(t,e[0])&&bB(t,e[1])}function FB(t,e,n,i,o){var r,a,s,l,u=i.coordinateSystem,h=t.getItemModel(e),c=go(h.get("x"),o.getWidth()),o=go(h.get("y"),o.getHeight());isNaN(c)||isNaN(o)?(r=i.getMarkerPosition?i.getMarkerPosition(t.getValues(t.dimensions,e)):(l=u.dimensions,a=t.get(l[0],e),s=t.get(l[1],e),u.dataToPoint([a,s])),ib(u,"cartesian2d")&&(a=u.getAxis("x"),s=u.getAxis("y"),l=u.dimensions,EB(t.get(l[0],e))?r[0]=a.toGlobalCoord(a.getExtent()[n?0:1]):EB(t.get(l[1],e))&&(r[1]=s.toGlobalCoord(s.getExtent()[n?0:1]))),isNaN(c)||(r[0]=c),isNaN(o)||(r[1]=o)):r=[c,o],t.setItemLayout(e,r)}function GB(){var t=null!==OB&&OB.apply(this,arguments)||this;return t.type=GB.type,t}var HB=(d(GB,OB=io),GB.prototype.updateTransform=function(t,e,r){e.eachSeries(function(e){var n,i,o,t=fB.getMarkerModelFromSeries(e,"markLine");t&&(n=t.getData(),i=NB(t).from,o=NB(t).to,i.each(function(t){FB(i,t,!0,e,r),FB(o,t,!1,e,r)}),n.each(function(t){n.setItemLayout(t,[i.getItemLayout(t),o.getItemLayout(t)])}),this.markerGroupMap.get(e.id).updateLayout())},this)},GB.prototype.renderSeries=function(r,n,t,a){var e=r.coordinateSystem,i=r.id,s=r.getData(),o=this.markerGroupMap,i=o.get(i)||o.set(i,new RD);this.group.add(i.group);var e=function(t,e,n){a=t?H(t&&t.dimensions,function(t){return N(N({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})}):[{name:"value",type:"float"}];var i=new c_(a,n),o=new c_(a,n),r=new c_([],n),n=H(n.get("data"),Z(LB,e,t,n));t&&(n=U(n,Z(BB,t)));var a=wB(!!t,a);return i.initData(H(n,function(t){return t[0]}),null,a),o.initData(H(n,function(t){return t[1]}),null,a),r.initData(H(n,function(t){return t[2]})),r.hasItemOption=!0,{from:i,to:o,line:r}}(e,r,n),l=e.from,u=e.to,h=e.line;NB(n).from=l,NB(n).to=u,n.setData(h);var c=n.get("symbol"),p=n.get("symbolSize"),d=n.get("symbolRotate"),f=n.get("symbolOffset");function g(t,e,n){var i=t.getItemModel(e);FB(t,e,n,r,a);var o=i.getModel("itemStyle").getItemStyle();null==o.fill&&(o.fill=Ef(s,"color")),t.setItemVisual(e,{symbolKeepAspect:i.get("symbolKeepAspect"),symbolOffset:rt(i.get("symbolOffset",!0),f[n?0:1]),symbolRotate:rt(i.get("symbolRotate",!0),d[n?0:1]),symbolSize:rt(i.get("symbolSize"),p[n?0:1]),symbol:rt(i.get("symbol",!0),c[n?0:1]),style:o})}j(c)||(c=[c,c]),j(p)||(p=[p,p]),j(d)||(d=[d,d]),j(f)||(f=[f,f]),e.from.each(function(t){g(l,t,!0),g(u,t,!1)}),h.each(function(t){var e=h.getItemModel(t).getModel("lineStyle").getLineStyle();h.setItemLayout(t,[l.getItemLayout(t),u.getItemLayout(t)]),null==e.stroke&&(e.stroke=l.getItemVisual(t,"style").fill),h.setItemVisual(t,{fromSymbolKeepAspect:l.getItemVisual(t,"symbolKeepAspect"),fromSymbolOffset:l.getItemVisual(t,"symbolOffset"),fromSymbolRotate:l.getItemVisual(t,"symbolRotate"),fromSymbolSize:l.getItemVisual(t,"symbolSize"),fromSymbol:l.getItemVisual(t,"symbol"),toSymbolKeepAspect:u.getItemVisual(t,"symbolKeepAspect"),toSymbolOffset:u.getItemVisual(t,"symbolOffset"),toSymbolRotate:u.getItemVisual(t,"symbolRotate"),toSymbolSize:u.getItemVisual(t,"symbolSize"),toSymbol:u.getItemVisual(t,"symbol"),style:e})}),i.updateData(h),e.line.eachItemGraphicEl(function(t,e){t.traverse(function(t){Gs(t).dataModel=n})}),this.markKeep(i),i.group.silent=n.get("silent")||r.get("silent")},GB.type="markLine",GB);function WB(t,e,n,i){var o=xB(t,i[0]),r=xB(t,i[1]),t=o.coord,i=r.coord;return t[0]=ot(t[0],-1/0),t[1]=ot(t[1],-1/0),i[0]=ot(i[0],1/0),i[1]=ot(i[1],1/0),(i=R([{},o,r])).coord=[o.coord,r.coord],i.x0=o.x,i.y0=o.y,i.x1=r.x,i.y1=r.y,i}var UB,YB=(d(ZB,UB=fB),ZB.prototype.createMarkerModelFromSeries=function(t,e,n){return new ZB(t,e,n)},ZB.type="markArea",ZB.defaultOption={zlevel:0,z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},ZB),XB=Zo();function ZB(){var t=null!==UB&&UB.apply(this,arguments)||this;return t.type=ZB.type,t}function jB(t){return!isNaN(t)&&!isFinite(t)}function qB(t,e,n){t=1-t;return jB(e[t])&&jB(n[t])}function KB(t,e){var n=e.coord[0],i=e.coord[1];return!!(ib(t,"cartesian2d")&&n&&i&&(qB(1,n,i)||qB(0,n,i)))||bB(t,{coord:n,x:e.x0,y:e.y0})||bB(t,{coord:i,x:e.x1,y:e.y1})}function JB(t,e,n,i,o){var r,a,s,l,u=i.coordinateSystem,h=t.getItemModel(e),c=go(h.get(n[0]),o.getWidth()),o=go(h.get(n[1]),o.getHeight());return isNaN(c)||isNaN(o)?(l=i.getMarkerPosition?i.getMarkerPosition(t.getValues(n,e)):(r=[a=t.get(n[0],e),s=t.get(n[1],e)],u.clampData&&u.clampData(r,r),u.dataToPoint(r,!0)),ib(u,"cartesian2d")&&(r=u.getAxis("x"),u=u.getAxis("y"),a=t.get(n[0],e),s=t.get(n[1],e),jB(a)?l[0]=r.toGlobalCoord(r.getExtent()["x0"===n[0]?0:1]):jB(s)&&(l[1]=u.toGlobalCoord(u.getExtent()["y0"===n[1]?0:1]))),isNaN(c)||(l[0]=c),isNaN(o)||(l[1]=o)):l=[c,o],l}var QB,$B=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]];function t4(){var t=null!==QB&&QB.apply(this,arguments)||this;return t.type=t4.type,t}var e4=(d(t4,QB=io),t4.prototype.updateTransform=function(t,e,o){e.eachSeries(function(n){var i,t=fB.getMarkerModelFromSeries(n,"markArea");t&&(i=t.getData()).each(function(e){var t=H($B,function(t){return JB(i,e,t,n,o)});i.setItemLayout(e,t),i.getItemGraphicEl(e).setShape("points",t)})},this)},t4.prototype.renderSeries=function(a,o,t,s){var l=a.coordinateSystem,e=a.id,u=a.getData(),n=this.markerGroupMap,i=n.get(e)||n.set(e,{group:new ro});this.group.add(i.group),this.markKeep(i);var h=function(t,n,e){var i,o;{var r;i=t?(r=H(t&&t.dimensions,function(t){var e=n.getData();return N(N({},e.getDimensionInfo(e.mapDimension(t))||{}),{name:t,ordinalMeta:null})}),o=H(["x0","y0","x1","y1"],function(t,e){return{name:t,type:r[e%2].type}}),new c_(o,e)):new c_(o=[{name:"value",type:"float"}],e)}e=H(e.get("data"),Z(WB,n,t,e));t&&(e=U(e,Z(KB,t)));t=t?function(t,e,n,i){return Pp(t.coord[Math.floor(i/2)][i%2],o[i])}:function(t,e,n,i){return Pp(t.value,o[i])};return i.initData(e,null,t),i.hasItemOption=!0,i}(l,a,o);o.setData(h),h.each(function(e){var t=H($B,function(t){return JB(h,e,t,a,s)}),n=l.getAxis("x").scale,i=l.getAxis("y").scale,o=n.getExtent(),r=i.getExtent(),n=[n.parse(h.get("x0",e)),n.parse(h.get("x1",e))],i=[i.parse(h.get("y0",e)),i.parse(h.get("y1",e))];mo(n),mo(i);i=!(o[0]>n[1]||o[1]<n[0]||r[0]>i[1]||r[1]<i[0]);h.setItemLayout(e,{points:t,allClipped:!i});t=h.getItemModel(e).getModel("itemStyle").getItemStyle(),i=Ef(u,"color");t.fill||(t.fill=i,"string"==typeof t.fill&&(t.fill=cn(t.fill,.4))),t.stroke||(t.stroke=i),h.setItemVisual(e,"style",t)}),h.diff(XB(i).data).add(function(t){var e=h.getItemLayout(t);e.allClipped||(e=new $g({shape:{points:e.points}}),h.setItemGraphicEl(t,e),i.group.add(e))}).update(function(t,e){var n=XB(i).data.getItemGraphicEl(e),e=h.getItemLayout(t);e.allClipped?n&&i.group.remove(n):(n?Wl(n,{shape:{points:e.points}},o,t):n=new $g({shape:{points:e.points}}),h.setItemGraphicEl(t,n),i.group.add(n))}).remove(function(t){t=XB(i).data.getItemGraphicEl(t);i.group.remove(t)}).execute(),h.eachItemGraphicEl(function(t,e){var n=h.getItemModel(e),i=h.getItemVisual(e,"style");t.useStyle(h.getItemVisual(e,"style")),$l(t,tu(n),{labelFetcher:o,labelDataIndex:e,defaultText:h.getName(e)||"",inheritColor:"string"==typeof i.fill?cn(i.fill,1):"#000"}),Nl(t,n),Ll(t),Gs(t).dataModel=o}),XB(i).data=h,i.group.silent=o.get("silent")||a.get("silent")},t4.type="markArea",t4);var n4,i4,o4=(d(u4,i4=Vh),u4.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},u4.prototype.mergeOption=function(t,e){i4.prototype.mergeOption.call(this,t,e),this._updateSelector(t)},u4.prototype._updateSelector=function(t){var n=t.selector,i=this.ecModel;j(n=!0===n?t.selector=["all","inverse"]:n)&&G(n,function(t,e){K(t)&&(t={type:t}),n[e]=O(t,(e=i,"all"===(t=t.type)?{type:"all",title:e.getLocaleModel().get(["legend","selector","all"])}:"inverse"===t?{type:"inverse",title:e.getLocaleModel().get(["legend","selector","inverse"])}:void 0))})},u4.prototype.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"))}},u4.prototype._updateData=function(i){var o=[],r=[];i.eachRawSeries(function(t){var e,n=t.name;r.push(n),t.legendVisualProvider?(n=t.legendVisualProvider.getAllNames(),i.isSeriesFiltered(t)||(r=r.concat(n)),n.length?o=o.concat(n):e=!0):e=!0,e&&Wo(t)&&o.push(t.name)}),this._availableNames=r;var t=H(this.get("data")||o,function(t){return new wu(t="string"==typeof t||"number"==typeof t?{name:t}:t,this,this.ecModel)},this);this._data=t},u4.prototype.getData=function(){return this._data},u4.prototype.select=function(t){var e=this.option.selected;"single"===this.get("selectedMode")&&G(this._data,function(t){e[t.get("name")]=!1}),e[t]=!0},u4.prototype.unSelect=function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},u4.prototype.toggleSelected=function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},u4.prototype.allSelect=function(){var t=this._data,e=this.option.selected;G(t,function(t){e[t.get("name",!0)]=!0})},u4.prototype.inverseSelect=function(){var t=this._data,e=this.option.selected;G(t,function(t){t=t.get("name",!0);e.hasOwnProperty(t)||(e[t]=!0),e[t]=!e[t]})},u4.prototype.isSelected=function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&0<=V(this._availableNames,t)},u4.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},u4.type="legend.plain",u4.dependencies=["series"],u4.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,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},u4),r4=Z,a4=G,s4=ro;function l4(){var t=null!==n4&&n4.apply(this,arguments)||this;return t.type=l4.type,t.newlineDisabled=!1,t}function u4(){var t=null!==i4&&i4.apply(this,arguments)||this;return t.type=u4.type,t.layoutMode={type:"box",ignoreSize:!0},t}function h4(t,e,n,i){d4(t,e,n,i),n.dispatchAction({type:"legendToggleSelect",name:null!=t?t:e}),p4(t,e,n,i)}function c4(t){for(var e,n=t.getZr().storage.getDisplayList(),i=0,o=n.length;i<o&&!(e=n[i].states.emphasis);)i++;return e&&e.hoverLayer}function p4(t,e,n,i){c4(n)||n.dispatchAction({type:"highlight",seriesName:t,name:e,excludeSeriesId:i})}function d4(t,e,n,i){c4(n)||n.dispatchAction({type:"downplay",seriesName:t,name:e,excludeSeriesId:i})}var f4,g4=(d(l4,n4=Wd),l4.prototype.init=function(){this.group.add(this._contentGroup=new s4),this.group.add(this._selectorGroup=new s4),this._isFirstRender=!0},l4.prototype.getContentGroup=function(){return this._contentGroup},l4.prototype.getSelectorGroup=function(){return this._selectorGroup},l4.prototype.render=function(t,e,n){var i,o,r,a,s,l=this._isFirstRender;this._isFirstRender=!1,this.resetInner(),t.get("show",!0)&&(i=t.get("align"),s=t.get("orient"),i&&"auto"!==i||(i="right"===t.get("left")&&"vertical"===s?"right":"left"),o=t.get("selector",!0),a=t.get("selectorPosition",!0),this.renderInner(i,t,e,n,o,s,a=o&&(!a||"auto"===a)?"horizontal"===s?"end":"start":a),n=Sh(r=t.getBoxLayoutParams(),e={width:n.getWidth(),height:n.getHeight()},s=t.get("padding")),s=Sh(z({width:(a=this.layoutInner(t,i,n,l,o,a)).width,height:a.height},r),e,s),this.group.x=s.x-a.x,this.group.y=s.y-a.y,this.group.markRedraw(),this.group.add(this._backgroundEl=BE(a,t)))},l4.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},l4.prototype.renderInner=function(s,l,u,h,t,e,n){var c=this.getContentGroup(),p=yt(),d=l.get("selectedMode"),f=[];u.eachRawSeries(function(t){t.get("legendHoverLink")||f.push(t.id)}),a4(l.getData(),function(o,r){var a=o.get("name");if(!this.newlineDisabled&&(""===a||"\n"===a)){var t=new s4;return t.newline=!0,void c.add(t)}var e,n,i=u.getSeriesByName(a)[0];p.get(a)||(i?(e=(n=i.getData()).getVisual("legendLineStyle")||{},t=n.getVisual("legendIcon"),n=n.getVisual("style"),this._createItem(i,a,r,o,l,s,e,n,t,d).on("click",r4(h4,a,null,h,f)).on("mouseover",r4(p4,i.name,null,h,f)).on("mouseout",r4(d4,i.name,null,h,f)),p.set(a,!0)):u.eachRawSeries(function(t){var e,n,i;p.get(a)||!t.legendVisualProvider||(n=t.legendVisualProvider).containName(a)&&(i=n.indexOfName(a),e=n.getItemVisual(i,"style"),n=n.getItemVisual(i,"legendIcon"),(i=rn(e.fill))&&0===i[3]&&(i[3]=.2,e.fill=pn(i,"rgba")),this._createItem(t,a,r,o,l,s,{},e,n,d).on("click",r4(h4,null,a,h,f)).on("mouseover",r4(p4,null,a,h,f)).on("mouseout",r4(d4,null,a,h,f)),p.set(a,!0))},this))},this),t&&this._createSelector(t,l,h,e,n)},l4.prototype._createSelector=function(t,i,o,e,n){var r=this.getSelectorGroup();a4(t,function(t){var e=t.type,n=new Fs({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){o.dispatchAction({type:"all"===e?"legendAllSelect":"legendInverseSelect"})}});r.add(n),$l(n,{normal:i.getModel("selectorLabel"),emphasis:i.getModel(["emphasis","selectorLabel"])},{defaultText:t.title}),Ll(n)})},l4.prototype._createItem=function(t,e,n,i,o,r,a,s,l,u){var h=t.visualDrawType,c=o.get("itemWidth"),p=o.get("itemHeight"),d=o.isSelected(e),f=i.get("symbolRotate"),g=i.get("symbolKeepAspect"),y=i.get("icon"),m=function(t,e,n,i,o,r){function a(n,i){"auto"===n.lineWidth&&(n.lineWidth=0<i.lineWidth?2:0),a4(n,function(t,e){"inherit"===n[e]&&(n[e]=i[e])})}var s=e.getModel("itemStyle").getItemStyle(),l=0===t.lastIndexOf("empty",0)?"fill":"stroke";s.decal=i.decal,"inherit"===s.fill&&(s.fill=i[o]),"inherit"===s.stroke&&(s.stroke=i[l]),"inherit"===s.opacity&&(s.opacity=("fill"===o?i:n).opacity),a(s,i);t=e.getModel("lineStyle"),o=t.getLineStyle();a(o,n),"auto"===s.fill&&(s.fill=i.fill),"auto"===s.stroke&&(s.stroke=i.fill),"auto"===o.stroke&&(o.stroke=i.fill),r||(r=e.get("inactiveBorderWidth"),l=s[l],s.lineWidth="auto"===r?0<i.lineWidth&&l?2:0:s.lineWidth,s.fill=e.get("inactiveColor"),s.stroke=e.get("inactiveBorderColor"),o.stroke=t.get("inactiveColor"),o.lineWidth=t.get("inactiveWidth"));return{itemStyle:s,lineStyle:o}}(l=y||l||"roundRect",i,a,s,h,d),v=new s4,a=i.getModel("textStyle");"function"!=typeof t.getLegendIcon||y&&"inherit"!==y?(s="inherit"===y&&t.getData().getVisual("symbol")?"inherit"===f?t.getData().getVisual("symbolRotate"):f:0,v.add((h={itemWidth:c,itemHeight:p,icon:l,iconRotate:s,itemStyle:m.itemStyle,lineStyle:m.lineStyle,symbolKeepAspect:g},y=h.icon||"roundRect",(s=am(y,0,0,h.itemWidth,h.itemHeight,h.itemStyle.fill,h.symbolKeepAspect)).setStyle(h.itemStyle),s.rotation=(h.iconRotate||0)*Math.PI/180,s.setOrigin([h.itemWidth/2,h.itemHeight/2]),-1<y.indexOf("empty")&&(s.style.stroke=s.style.fill,s.style.fill="#fff",s.style.lineWidth=2),s))):v.add(t.getLegendIcon({itemWidth:c,itemHeight:p,icon:l,iconRotate:f,itemStyle:m.itemStyle,lineStyle:m.lineStyle,symbolKeepAspect:g}));m="left"===r?c+5:-5,g=r,c=o.get("formatter"),r=e;"string"==typeof c&&c?r=c.replace("{name}",null!=e?e:""):"function"==typeof c&&(r=c(e));c=i.get("inactiveColor");v.add(new Fs({style:eu(a,{text:r,x:m,y:p/2,fill:d?a.getTextColor():c,align:g,verticalAlign:"middle"})}));g=new Ts({shape:v.getBoundingRect(),invisible:!0}),i=i.getModel("tooltip");return i.get("show")&&em({el:g,componentModel:o,itemName:e,itemTooltipOption:i.option}),v.add(g),v.eachChild(function(t){t.silent=!0}),g.silent=!u,this.getContentGroup().add(v),Ll(v),v.__legendDataIndex=n,v},l4.prototype.layoutInner=function(t,e,n,i,o,r){var a=this.getContentGroup(),s=this.getSelectorGroup();wh(t.get("orient"),a,t.get("itemGap"),n.width,n.height);var l=a.getBoundingRect(),u=[-l.x,-l.y];if(s.markRedraw(),a.markRedraw(),o){wh("horizontal",s,t.get("selectorItemGap",!0));var h=s.getBoundingRect(),c=[-h.x,-h.y],p=t.get("selectorButtonGap",!0),d=t.getOrient().index,n=0===d?"width":"height",o=0===d?"height":"width",t=0===d?"y":"x";"end"===r?c[d]+=l[n]+p:u[d]+=h[n]+p,c[1-d]+=l[o]/2-h[o]/2,s.x=c[0],s.y=c[1],a.x=u[0],a.y=u[1];s={x:0,y:0};return s[n]=l[n]+p+h[n],s[o]=Math.max(l[o],h[o]),s[t]=Math.min(0,h[t]+c[1-d]),s}return a.x=u[0],a.y=u[1],this.group.getBoundingRect()},l4.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},l4.type="legend.plain",l4);function y4(t){var n=t.findComponents({mainType:"legend"});n&&n.length&&t.filterSeries(function(t){for(var e=0;e<n.length;e++)if(!n[e].isSelected(t.name))return!1;return!0})}function m4(t,e,n){var i,o={},r="toggleSelected"===t;return n.eachComponent("legend",function(n){r&&null!=i?n[i?"select":"unSelect"](e.name):"allSelect"===t||"inverseSelect"===t?n[t]():(n[t](e.name),i=n.isSelected(e.name)),G(n.getData(),function(t){var e=t.get("name");"\n"!==e&&""!==e&&(t=n.isSelected(e),o.hasOwnProperty(e)?o[e]=o[e]&&t:o[e]=t)})}),"allSelect"===t||"inverseSelect"===t?{selected:o}:{name:e.name,selected:o}}function v4(t){t.registerComponentModel(o4),t.registerComponentView(g4),t.registerProcessor(t.PRIORITY.PROCESSOR.SERIES_FILTER,y4),t.registerSubTypeDefaulter("legend",function(){return"plain"}),(t=t).registerAction("legendToggleSelect","legendselectchanged",Z(m4,"toggleSelected")),t.registerAction("legendAllSelect","legendselectall",Z(m4,"allSelect")),t.registerAction("legendInverseSelect","legendinverseselect",Z(m4,"inverseSelect")),t.registerAction("legendSelect","legendselected",Z(m4,"select")),t.registerAction("legendUnSelect","legendunselected",Z(m4,"unSelect"))}function x4(){var t=null!==f4&&f4.apply(this,arguments)||this;return t.type=x4.type,t}function _4(t,e,n){var i=[1,1];i[t.getOrient().index]=0,Th(e,n,{type:"box",ignoreSize:!!i})}var b4,w4=(d(x4,f4=o4),x4.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},x4.prototype.init=function(t,e,n){var i=Ch(t);f4.prototype.init.call(this,t,e,n),_4(this,t,i)},x4.prototype.mergeOption=function(t,e){f4.prototype.mergeOption.call(this,t,e),_4(this,this.option,t)},x4.type="legend.scroll",x4.defaultOption=Iu(o4.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}),x4),S4=ro,M4=["width","height"],I4=["x","y"],T4=(d(C4,b4=g4),C4.prototype.init=function(){b4.prototype.init.call(this),this.group.add(this._containerGroup=new S4),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new S4)},C4.prototype.resetInner=function(){b4.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},C4.prototype.renderInner=function(t,i,e,o,n,r,a){var s=this;b4.prototype.renderInner.call(this,t,i,e,o,n,r,a);var l=this._controllerGroup,a=i.get("pageIconSize",!0),u=j(a)?a:[a,a];h("pagePrev",0);a=i.getModel("pageTextStyle");function h(t,e){var n=t+"DataIndex",n=Qy(i.get("pageIcons",!0)[i.getOrient().name][e],{onclick:X(s._pageGo,s,n,i,o)},{x:-u[0]/2,y:-u[1]/2,width:u[0],height:u[1]});n.name=t,l.add(n)}l.add(new Fs({name:"pageText",style:{text:"xx/xx",fill:a.getTextColor(),font:a.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),h("pageNext",1)},C4.prototype.layoutInner=function(t,e,n,i,o,r){var a=this.getSelectorGroup(),s=t.getOrient().index,l=M4[s],u=I4[s],h=M4[1-s],c=I4[1-s];o&&wh("horizontal",a,t.get("selectorItemGap",!0));var p=t.get("selectorButtonGap",!0),d=a.getBoundingRect(),f=[-d.x,-d.y],g=P(n);o&&(g[l]=n[l]-d[l]-p);g=this._layoutContentAndController(t,i,g,s,l,h,c,u);return o&&("end"===r?f[s]+=g[l]+p:(r=d[l]+p,f[s]-=r,g[u]-=r),g[l]+=d[l]+p,f[1-s]+=g[c]+g[h]/2-d[h]/2,g[h]=Math.max(g[h],d[h]),g[c]=Math.min(g[c],d[c]+f[1-s]),a.x=f[0],a.y=f[1],a.markRedraw()),g},C4.prototype._layoutContentAndController=function(t,e,n,i,o,r,a,s){var l=this.getContentGroup(),u=this._containerGroup,h=this._controllerGroup;wh(t.get("orient"),l,t.get("itemGap"),i?n.width:null,i?null:n.height),wh("horizontal",h,t.get("pageButtonItemGap",!0));var c=l.getBoundingRect(),p=h.getBoundingRect(),d=this._showController=c[o]>n[o],f=[-c.x,-c.y];e||(f[i]=l[s]);var g=[0,0],e=[-p.x,-p.y],s=rt(t.get("pageButtonGap",!0),t.get("itemGap",!0));d&&("end"===t.get("pageButtonPosition",!0)?e[i]+=n[o]-p[o]:g[i]+=p[o]+s),e[1-i]+=c[r]/2-p[r]/2,l.setPosition(f),u.setPosition(g),h.setPosition(e);g={x:0,y:0};g[o]=(d?n:c)[o],g[r]=Math.max(c[r],p[r]),g[a]=Math.min(0,p[a]+e[1-i]),u.__rectSize=n[o],d?((i={x:0,y:0})[o]=Math.max(n[o]-p[o]-s,0),i[r]=g[r],u.setClipPath(new Ts({shape:i})),u.__rectSize=i[o]):h.eachChild(function(t){t.attr({invisible:!0,silent:!0})});h=this._getPageInfo(t);return null!=h.pageIndex&&Wl(l,{x:h.contentPosition[0],y:h.contentPosition[1]},d?t:null),this._updatePageInfoView(t,h),g},C4.prototype._pageGo=function(t,e,n){t=this._getPageInfo(e)[t];null!=t&&n.dispatchAction({type:"legendScroll",scrollDataIndex:t,legendId:e.id})},C4.prototype._updatePageInfoView=function(n,i){var o=this._controllerGroup;G(["pagePrev","pageNext"],function(t){var e=null!=i[t+"DataIndex"],t=o.childOfName(t);t&&(t.setStyle("fill",e?n.get("pageIconColor",!0):n.get("pageIconInactiveColor",!0)),t.cursor=e?"pointer":"default")});var t=o.childOfName("pageText"),e=n.get("pageFormatter"),r=i.pageIndex,a=null!=r?r+1:0,r=i.pageCount;t&&e&&t.setStyle("text",K(e)?e.replace("{current}",null==a?"":a+"").replace("{total}",null==r?"":r+""):e({current:a,total:r}))},C4.prototype._getPageInfo=function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,o=t.getOrient().index,r=M4[o],a=I4[o],s=this._findTargetItemIndex(e),l=n.children(),t=l[s],u=l.length,e=u?1:0,h={contentPosition:[n.x,n.y],pageCount:e,pageIndex:e-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!t)return h;t=g(t);h.contentPosition[o]=-t.s;for(var c=s+1,p=t,d=t,f=null;c<=u;++c)(!(f=g(l[c]))&&d.e>p.s+i||f&&!y(f,p.s))&&((p=d.i>p.i?d:f)&&(null==h.pageNextDataIndex&&(h.pageNextDataIndex=p.i),++h.pageCount)),d=f;for(c=s-1,d=p=t,f=null;-1<=c;--c)(f=g(l[c]))&&y(d,f.s)||!(p.i<d.i)||(d=p,null==h.pagePrevDataIndex&&(h.pagePrevDataIndex=p.i),++h.pageCount,++h.pageIndex),p=f;return h;function g(t){if(t){var e=t.getBoundingRect(),n=e[a]+t[a];return{s:n,e:n+e[r],i:t.__legendDataIndex}}}function y(t,e){return t.e>=e&&t.s<=e+i}},C4.prototype._findTargetItemIndex=function(n){return this._showController?(this.getContentGroup().eachChild(function(t,e){t=t.__legendDataIndex;null==o&&null!=t&&(o=e),t===n&&(i=e)}),null!=i?i:o):0;var i,o},C4.type="legend.scroll",C4);function C4(){var t=null!==b4&&b4.apply(this,arguments)||this;return t.type=C4.type,t.newlineDisabled=!0,t._currentIndex=0,t}function D4(t){Xv(v4),t.registerComponentModel(w4),t.registerComponentView(T4),t.registerAction("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 A4,k4=(d(P4,A4=Jn),P4.type="dataZoom.inside",P4.defaultOption=Iu(Jn.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),P4),L4=Zo();function P4(){var t=null!==A4&&A4.apply(this,arguments)||this;return t.type=P4.type,t}function O4(t,e){e&&(t.removeKey(e.model.uid),(e=e.controller)&&e.dispose())}function R4(t,e){t.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function N4(t,e,n,i){return t.coordinateSystem.containPoint([n,i])}function z4(t){t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,function(t,a){var e=L4(a),l=e.coordSysRecordMap||(e.coordSysRecordMap=yt());l.each(function(t){t.dataZoomInfoMap=null}),t.eachComponent({mainType:"dataZoom",subType:"inside"},function(o){G(uE(o).infoList,function(t){var r,e,n=t.model.uid,i=l.get(n)||l.set(n,(i=a,n=t.model,r={model:n,containsPoint:Z(N4,n),dispatchAction:Z(R4,i),dataZoomInfoMap:null,controller:null},e=r.controller=new qI(i.getZr()),G(["pan","zoom","scrollMove"],function(o){e.on(o,function(n){var i=[];r.dataZoomInfoMap.each(function(t){var e;n.isAvailableBehavior(t.model.option)&&(e=(e=(t.getRange||{})[o])&&e(t.dzReferCoordSysInfo,r.model.mainType,r.controller,n),!t.model.get("disabled",!0)&&e&&i.push({dataZoomId:t.model.id,start:e[0],end:e[1]}))}),i.length&&r.dispatchAction(i)})}),r));(i.dataZoomInfoMap||(i.dataZoomInfoMap=yt())).set(o.uid,{dzReferCoordSysInfo:t,model:o,getRange:null})})}),l.each(function(t){var e,n,i,o,r,a=t.controller,s=t.dataZoomInfoMap;!s||null!=(n=s.keys()[0])&&(e=s.get(n)),e?(o={type_true:2,type_move:1,type_false:0,type_undefined:-1},r=!0,s.each(function(t){var e=t.model,t=!e.get("disabled",!0)&&(!e.get("zoomLock",!0)||"move");o["type_"+i]<o["type_"+t]&&(i=t),r=r&&e.get("preventDefaultMouseMove",!0)}),s={controlType:i,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!r}},a.enable(s.controlType,s.opt),a.setPointerChecker(t.containsPoint),rf(t,"dispatchAction",e.model.get("throttle",!0),"fixRate")):O4(l,t)})})}var E4,io=(d(B4,E4=gr),B4.prototype.render=function(t,e,n){var i,o;E4.prototype.render.apply(this,arguments),t.noTarget()?this._clear():(this.range=t.getPercentRange(),n=n,i=t,o={pan:X(V4.pan,this),zoom:X(V4.zoom,this),scrollMove:X(V4.scrollMove,this)},L4(n).coordSysRecordMap.each(function(t){t=t.dataZoomInfoMap.get(i.uid);t&&(t.getRange=o)}))},B4.prototype.dispose=function(){this._clear(),E4.prototype.dispose.apply(this,arguments)},B4.prototype._clear=function(){(function(t,e){for(var n=L4(t).coordSysRecordMap,i=n.keys(),o=0;o<i.length;o++){var r=i[o],a=n.get(r),s=a.dataZoomInfoMap;s&&(r=e.uid,s.get(r)&&(s.removeKey(r),s.keys().length||O4(n,a)))}})(this.api,this.dataZoomModel),this.range=null},B4.type="dataZoom.inside",B4),V4={zoom:function(t,e,n,i){var o=this.range,r=o.slice(),a=t.axisModels[0];if(a){t=G4[e](null,[i.originX,i.originY],a,n,t),t=(0<t.signal?t.pixelStart+t.pixelLength-t.pixel:t.pixel-t.pixelStart)/t.pixelLength*(r[1]-r[0])+r[0],i=Math.max(1/i.scale,0);r[0]=(r[0]-t)*i+t,r[1]=(r[1]-t)*i+t;t=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return tk(0,r,[0,100],0,t.minSpan,t.maxSpan),this.range=r,o[0]!==r[0]||o[1]!==r[1]?r:void 0}},pan:F4(function(t,e,n,i,o,r){n=G4[i]([r.oldX,r.oldY],[r.newX,r.newY],e,o,n);return n.signal*(t[1]-t[0])*n.pixel/n.pixelLength}),scrollMove:F4(function(t,e,n,i,o,r){return G4[i]([0,0],[r.scrollDelta,r.scrollDelta],e,o,n).signal*(t[1]-t[0])*r.scrollDelta})};function B4(){var t=null!==E4&&E4.apply(this,arguments)||this;return t.type="dataZoom.inside",t}function F4(s){return function(t,e,n,i){var o=this.range,r=o.slice(),a=t.axisModels[0];if(a)return tk(s(r,a,t,e,n,i),r,[0,100],"all"),this.range=r,o[0]!==r[0]||o[1]!==r[1]?r:void 0}}var G4={grid:function(t,e,n,i,o){var r=n.axis,n={},o=o.model.coordinateSystem.getRect();return t=t||[0,0],"x"===r.dim?(n.pixel=e[0]-t[0],n.pixelLength=o.width,n.pixelStart=o.x,n.signal=r.inverse?1:-1):(n.pixel=e[1]-t[1],n.pixelLength=o.height,n.pixelStart=o.y,n.signal=r.inverse?-1:1),n},polar:function(t,e,n,i,o){var r=n.axis,a={},s=o.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),o=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=r.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=o[1]-o[0],a.pixelStart=o[0],a.signal=r.inverse?-1:1),a},singleAxis:function(t,e,n,i,o){var r=n.axis,n=o.model.coordinateSystem.getRect(),o={};return t=t||[0,0],"horizontal"===r.orient?(o.pixel=e[0]-t[0],o.pixelLength=n.width,o.pixelStart=n.x,o.signal=r.inverse?1:-1):(o.pixel=e[1]-t[1],o.pixelLength=n.height,o.pixelStart=n.y,o.signal=r.inverse?-1:1),o}},H4=io;function W4(t){AE(t),t.registerComponentModel(k4),t.registerComponentView(H4),z4(t)}var U4,Y4,X4=(d($4,Y4=Jn),$4.type="dataZoom.slider",$4.layoutMode="box",$4.defaultOption=Iu(Jn.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),$4),Z4=Ts,j4="horizontal",q4="vertical",K4=["line","bar","candlestick","scatter"],J4={easing:"cubicOut",duration:100,delay:0};function Q4(){var t=null!==U4&&U4.apply(this,arguments)||this;return t.type=Q4.type,t._displayables={},t}function $4(){var t=null!==Y4&&Y4.apply(this,arguments)||this;return t.type=$4.type,t}function tF(t){return"vertical"===t?"ns-resize":"ew-resize"}var eF=(d(Q4,U4=gr),Q4.prototype.init=function(t,e){this.api=e,this._onBrush=X(this._onBrush,this),this._onBrushEnd=X(this._onBrushEnd,this)},Q4.prototype.render=function(t,e,n,i){if(U4.prototype.render.apply(this,arguments),rf(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),!1!==t.get("show")){if(t.noTarget())return this._clear(),void this.group.removeAll();i&&"dataZoom"===i.type&&i.from===this.uid||this._buildView(),this._updateView()}else this.group.removeAll()},Q4.prototype.dispose=function(){this._clear(),U4.prototype.dispose.apply(this,arguments)},Q4.prototype._clear=function(){var t,e;(n=(t=this)[e="_dispatchZoomAction"])&&n[tf]&&(t[e]=n[tf]);var n=this.api.getZr();n.off("mousemove",this._onBrush),n.off("mouseup",this._onBrushEnd)},Q4.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var e=this._displayables.sliderGroup=new ro;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},Q4.prototype._resetLocation=function(){var t=this.dataZoomModel,e=this.api,n=t.get("brushSelect")?7:0,i=this._findCoordRect(),e={width:e.getWidth(),height:e.getHeight()},o=this._orient===j4?{right:e.width-i.x-i.width,top:e.height-30-7-n,width:i.width,height:30}:{right:7,top:i.y,width:30,height:i.height},r=Ch(t.option);G(["right","top","width","height"],function(t){"ph"===r[t]&&(r[t]=o[t])});e=Sh(r,e);this._location={x:e.x,y:e.y},this._size=[e.width,e.height],this._orient===q4&&this._size.reverse()},Q4.prototype._positionGroup=function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),o=i&&i.get("inverse"),r=this._displayables.sliderGroup,i=(this._dataShadowInfo||{}).otherAxisInverse;r.attr(n!==j4||o?n===j4&&o?{scaleY:i?1:-1,scaleX:-1}:n!==q4||o?{scaleY:i?-1:1,scaleX:-1,rotation:Math.PI/2}:{scaleY:i?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:i?1:-1,scaleX:1});r=t.getBoundingRect([r]);t.x=e.x-r.x,t.y=e.y-r.y,t.markRedraw()},Q4.prototype._getViewExtent=function(){return[0,this._size[0]]},Q4.prototype._renderBackground=function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect");n.add(new Z4({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40}));t=new Z4({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:X(this._onClickPanel,this)}),e=this.api.getZr();i?(t.on("mousedown",this._onBrushStart,this),t.cursor="crosshair",e.on("mousemove",this._onBrush),e.on("mouseup",this._onBrushEnd)):(e.off("mousemove",this._onBrush),e.off("mouseup",this._onBrushEnd)),n.add(t)},Q4.prototype._renderDataShadow=function(){var t,e,n=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],n){var i=this._size,o=n.series,r=o.getRawData(),o=o.getShadowDim?o.getShadowDim():n.otherDim;if(null!=o){var a,n=.3*((s=r.getDataExtent(o))[1]-s[0]),s=[s[0]-n,s[1]+n],l=[0,i[1]],n=[0,i[0]],u=[[i[0],0],[0,0]],h=[],c=n[1]/(r.count()-1),p=0,d=Math.round(r.count()/i[0]);r.each([o],function(t,e){var n;0<d&&e%d?p+=c:(t=(n=null==t||isNaN(t)||""===t)?0:fo(t,s,l,!0),n&&!a&&e?(u.push([u[u.length-1][0],0]),h.push([h[h.length-1][0],0])):!n&&a&&(u.push([p,0]),h.push([p,0])),u.push([p,t]),h.push([p,t]),p+=c,a=n)});for(var f=this.dataZoomModel,g=0;g<3;g++){var y=(t=1===g,e=y=e=void 0,e=f.getModel(t?"selectedDataBackground":"dataBackground"),y=new ro,t=new $g({shape:{points:u},segmentIgnoreThreshold:1,style:e.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),e=new ny({shape:{points:h},segmentIgnoreThreshold:1,style:e.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19}),y.add(t),y.add(e),y);this._displayables.sliderGroup.add(y),this._displayables.dataShadowSegs.push(y)}}}},Q4.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,s=t.get("showDataShadow");if(!1!==s){var l,u=this.ecModel;return t.eachTargetAxis(function(r,a){G(t.getAxisProxy(r,a).getTargetSeriesModels(),function(t){var e,n,i,o;l||!0!==s&&V(K4,t.get("type"))<0||(n=u.getComponent(sE(r),a).axis,o=t.coordinateSystem,null!=(i={x:"y",y:"x",radius:"angle",angle:"radius"}[r])&&o.getOtherAxis&&(e=o.getOtherAxis(n).inverse),i=t.getData().mapDimension(i),l={thisAxis:n,series:t,thisDim:r,otherDim:i,otherAxisInverse:e})},this)},this),l}},Q4.prototype._renderHandle=function(){var o=this.group,t=this._displayables,r=t.handles=[null,null],a=t.handleLabels=[null,null],s=this._displayables.sliderGroup,e=this._size,l=this.dataZoomModel,n=this.api,i=l.get("borderRadius")||0,u=l.get("brushSelect"),h=t.filler=new Z4({silent:u,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});s.add(h),s.add(new Z4({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:e[0],height:e[1],r:i},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),G([0,1],function(t){var e=l.get("handleIcon"),n=am(e=!im[e]&&e.indexOf("path://")<0&&e.indexOf("image://")<0?"path://"+e:e,-1,0,2,2,null,!0);n.attr({cursor:tF(this._orient),draggable:!0,drift:X(this._onDragMove,this,t),ondragend:X(this._onDragEnd,this),onmouseover:X(this._showDataInfo,this,!0),onmouseout:X(this._showDataInfo,this,!1),z2:5});var i=n.getBoundingRect(),e=l.get("handleSize");this._handleHeight=go(e,this._size[1]),this._handleWidth=i.width/i.height*this._handleHeight,n.setStyle(l.getModel("handleStyle").getItemStyle()),n.style.strokeNoScale=!0,n.rectHover=!0,n.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),Ll(n);i=l.get("handleColor");null!=i&&(n.style.fill=i),s.add(r[t]=n);n=l.getModel("textStyle");o.add(a[t]=new Fs({silent:!0,invisible:!0,style:eu(n,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:n.getTextColor(),font:n.getFont()}),z2:10}))},this);var c,p=h;u&&(i=go(l.get("moveHandleSize"),e[1]),c=t.moveHandle=new Ts({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:e[1]-.5,height:i}}),h=.8*i,(u=t.moveHandleIcon=am(l.get("moveHandleIcon"),-h/2,-h/2,h,h,"#fff",!0)).silent=!0,u.y=e[1]+i/2-.5,c.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle(),h=Math.min(e[1]/2,Math.max(i,10)),(p=t.moveZone=new Ts({invisible:!0,shape:{y:e[1]-h,height:i+h}})).on("mouseover",function(){n.enterEmphasis(c)}).on("mouseout",function(){n.leaveEmphasis(c)}),s.add(c),s.add(u),s.add(p)),p.attr({draggable:!0,cursor:tF(this._orient),drift:X(this._onDragMove,this,"all"),ondragstart:X(this._showDataInfo,this,!0),ondragend:X(this._onDragEnd,this),onmouseover:X(this._showDataInfo,this,!0),onmouseout:X(this._showDataInfo,this,!1)})},Q4.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[fo(t[0],[0,100],e,!0),fo(t[1],[0,100],e,!0)]},Q4.prototype._updateInterval=function(t,e){var n=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),r=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100];tk(e,i,o,n.get("zoomLock")?"all":t,null!=r.minSpan?fo(r.minSpan,a,o,!0):null,null!=r.maxSpan?fo(r.maxSpan,a,o,!0):null);r=this._range,a=this._range=mo([fo(i[0],o,a,!0),fo(i[1],o,a,!0)]);return!r||r[0]!==a[0]||r[1]!==a[1]},Q4.prototype._updateView=function(t){var i=this._displayables,o=this._handleEnds,e=mo(o.slice()),r=this._size;G([0,1],function(t){var e=i.handles[t],n=this._handleHeight;e.attr({scaleX:n/2,scaleY:n/2,x:o[t]+(t?-1:1),y:r[1]/2-n/2})},this),i.filler.setShape({x:e[0],y:0,width:e[1]-e[0],height:r[1]});var n={x:e[0],width:e[1]-e[0]};i.moveHandle&&(i.moveHandle.setShape(n),i.moveZone.setShape(n),i.moveZone.getBoundingRect(),i.moveHandleIcon&&i.moveHandleIcon.attr("x",n.x+n.width/2));for(var a=i.dataShadowSegs,s=[0,e[0],e[1],r[0]],l=0;l<a.length;l++){var u=a[l],h=u.getClipPath();h||(h=new Ts,u.setClipPath(h)),h.setShape({x:s[l],y:0,width:s[l+1]-s[l],height:r[1]})}this._updateDataInfo(t)},Q4.prototype._updateDataInfo=function(t){var e,n,i=this.dataZoomModel,o=this._displayables,r=o.handleLabels,a=this._orient,s=["",""];!i.get("showDetail")||(n=i.findRepresentativeAxisProxy())&&(e=n.getAxisModel().axis,i=this._range,n=t?n.calculateDataWindow({start:i[0],end:i[1]}).valueWindow:n.getDataValueWindow(),s=[this._formatLabel(n[0],e),this._formatLabel(n[1],e)]);var l=mo(this._handleEnds.slice());function u(t){var e=Yy(o.handles[t].parent,this.group),n=Zy(0===t?"right":"left",e),i=this._handleWidth/2+5,e=Xy([l[t]+(0===t?-i:i),this._size[1]/2],e);r[t].setStyle({x:e[0],y:e[1],verticalAlign:a===j4?"middle":n,align:a===j4?n:"center",text:s[t]})}u.call(this,0),u.call(this,1)},Q4.prototype._formatLabel=function(t,e){var n=this.dataZoomModel,i=n.get("labelFormatter"),n=n.get("labelPrecision");null!=n&&"auto"!==n||(n=e.getPixelPrecision());n=null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(n,20));return q(i)?i(t,n):K(i)?i.replace("{value}",n):n},Q4.prototype._showDataInfo=function(t){t=this._dragging||t;var e=this._displayables,n=e.handleLabels;n[0].attr("invisible",!t),n[1].attr("invisible",!t),e.moveHandle&&this.api[t?"enterEmphasis":"leaveEmphasis"](e.moveHandle,1)},Q4.prototype._onDragMove=function(t,e,n,i){this._dragging=!0,re(i.event);n=Xy([e,n],this._displayables.sliderGroup.getLocalTransform(),!0),t=this._updateInterval(t,n[0]),n=this.dataZoomModel.get("realtime");this._updateView(!n),t&&n&&this._dispatchZoomAction(!0)},Q4.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1),this.dataZoomModel.get("realtime")||this._dispatchZoomAction(!1)},Q4.prototype._onClickPanel=function(t){var e=this._size,t=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);t[0]<0||t[0]>e[0]||t[1]<0||t[1]>e[1]||(e=((e=this._handleEnds)[0]+e[1])/2,e=this._updateInterval("all",t[0]-e),this._updateView(),e&&this._dispatchZoomAction(!1))},Q4.prototype._onBrushStart=function(t){var e=t.offsetX,t=t.offsetY;this._brushStart=new bi(e,t),this._brushing=!0,this._brushStartTime=+new Date},Q4.prototype._onBrushEnd=function(t){var e,n,i;this._brushing&&(i=this._displayables.brushRect,this._brushing=!1,i&&(i.attr("ignore",!0),e=i.shape,+new Date-this._brushStartTime<200&&Math.abs(e.width)<5||(n=this._getViewExtent(),this._range=mo([fo(e.x,n,i=[0,100],!0),fo(e.x+e.width,n,i,!0)]),this._handleEnds=[e.x,e.x+e.width],this._updateView(),this._dispatchZoomAction(!1))))},Q4.prototype._onBrush=function(t){this._brushing&&(re(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},Q4.prototype._updateBrushRect=function(t,e){var n=this._displayables,i=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new Z4({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);i=this._brushStart,n=this._displayables.sliderGroup,e=n.transformCoordToLocal(t,e),n=n.transformCoordToLocal(i.x,i.y),i=this._size;e[0]=Math.max(Math.min(i[0],e[0]),0),o.setShape({x:n[0],y:0,width:e[0]-n[0],height:i[1]})},Q4.prototype._dispatchZoomAction=function(t){var e=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?J4:null,start:e[0],end:e[1]})},Q4.prototype._findCoordRect=function(){var t,e,n=uE(this.dataZoomModel).infoList;return t=!(t=!t&&n.length?(e=n[0].model.coordinateSystem).getRect&&e.getRect():t)?{x:.2*(n=this.api.getWidth()),y:.2*(e=this.api.getHeight()),width:.6*n,height:.6*e}:t},Q4.type="dataZoom.slider",Q4);function nF(t){t.registerComponentModel(X4),t.registerComponentView(eF),AE(t)}var iF,oF,rF={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},aF={get:function(t,e,n){e=P((rF[t]||{})[e]);return n&&j(e)?e[e.length-1]:e}},sF=vC.mapVisual,lF=vC.eachVisual,uF=j,hF=G,cF=mo,pF=fo,Jn=(d(gF,oF=Vh),gF.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},gF.prototype.optionUpdated=function(t,e){var n=this.option;w.canvasSupported||(n.realtime=!1),e||pV(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},gF.prototype.resetVisual=function(t){var e=this.stateList;t=X(t,this),this.controllerVisuals=cV(this.option.controller,e,t),this.targetVisuals=cV(this.option.target,e,t)},gF.prototype.getItemSymbol=function(){return null},gF.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,n=[];return null==t||"all"===t?this.ecModel.eachSeries(function(t,e){n.push(e)}):n=No(t),n},gF.prototype.eachTargetSeries=function(e,n){G(this.getTargetSeriesIndices(),function(t){t=this.ecModel.getSeriesByIndex(t);t&&e.call(n,t)},this)},gF.prototype.isTargetSeries=function(e){var n=!1;return this.eachTargetSeries(function(t){t===e&&(n=!0)}),n},gF.prototype.formatValueText=function(t,e,n){var i,o=this.option,r=o.precision,a=this.dataBound,o=o.formatter;n=n||["<",">"],j(t)&&(t=t.slice(),i=!0);e=e?t:i?[s(t[0]),s(t[1])]:s(t);return K(o)?o.replace("{value}",i?e[0]:e).replace("{value2}",i?e[1]:e):q(o)?i?o(t[0],t[1]):o(t):i?t[0]===a[0]?n[0]+" "+e[1]:t[1]===a[1]?n[1]+" "+e[0]:e[0]+" - "+e[1]:e;function s(t){return t===a[0]?"min":t===a[1]?"max":(+t).toFixed(Math.min(r,20))}},gF.prototype.resetExtent=function(){var t=this.option,t=cF([t.min,t.max]);this._dataExtent=t},gF.prototype.getDataDimensionIndex=function(t){var e=this.option.dimension;if(null!=e)return t.getDimensionIndex(e);for(var n=t.dimensions,i=n.length-1;0<=i;i--){var o=n[i],o=t.getDimensionInfo(o);if(!o.isCalculationCoord)return o.storeDimIndex}},gF.prototype.getExtent=function(){return this._dataExtent.slice()},gF.prototype.completeVisualOption=function(){var e=this.ecModel,n=this.option,t={inRange:n.inRange,outOfRange:n.outOfRange},i=n.target||(n.target={}),o=n.controller||(n.controller={});O(i,t),O(o,t);var u=this.isCategory();function r(t){uF(n.color)&&!t.inRange&&(t.inRange={color:n.color.slice().reverse()}),t.inRange=t.inRange||{color:e.get("gradientColor")}}r.call(this,i),r.call(this,o),function(t,e,n){var e=t[e],i=t[n];e&&!i&&(i=t[n]={},hF(e,function(t,e){var n;!vC.isValidType(e)||null!=(n=aF.get(e,"inactive",u))&&(i[e]=n,"color"!==e||i.hasOwnProperty("opacity")||i.hasOwnProperty("colorAlpha")||(i.opacity=[0,0]))}))}.call(this,i,"inRange","outOfRange"),function(o){var r=(o.inRange||{}).symbol||(o.outOfRange||{}).symbol,a=(o.inRange||{}).symbolSize||(o.outOfRange||{}).symbolSize,s=this.get("inactiveColor"),l=this.getItemSymbol()||"roundRect";hF(this.stateList,function(t){var e=this.itemSize,n=o[t];null==(n=n||(o[t]={color:u?s:[s]})).symbol&&(n.symbol=r&&P(r)||(u?l:[l])),null==n.symbolSize&&(n.symbolSize=a&&P(a)||(u?e[0]:[e[0],e[0]])),n.symbol=sF(n.symbol,function(t){return"none"===t?l:t});var i,t=n.symbolSize;null!=t&&(i=-1/0,lF(t,function(t){i<t&&(i=t)}),n.symbolSize=sF(t,function(t){return pF(t,[0,i],[0,e[0]],!0)}))},this)}.call(this,o)},gF.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},gF.prototype.isCategory=function(){return!!this.option.categories},gF.prototype.setSelected=function(t){},gF.prototype.getSelected=function(){return null},gF.prototype.getValueState=function(t){return null},gF.prototype.getVisualMeta=function(t){return null},gF.type="visualMap",gF.dependencies=["series"],gF.defaultOption={show:!0,zlevel:0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},gF),dF=[20,140];function fF(){var t=null!==iF&&iF.apply(this,arguments)||this;return t.type=fF.type,t}function gF(){var t=null!==oF&&oF.apply(this,arguments)||this;return t.type=gF.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}function yF(t,e,n){if(n[0]===n[1])return n.slice();for(var i=(n[1]-n[0])/200,o=n[0],r=[],a=0;a<=200&&o<n[1];a++)r.push(o),o+=i;return r.push(n[1]),r}var mF,vF=(d(fF,iF=Jn),fF.prototype.optionUpdated=function(t,e){iF.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(t){t.mappingMethod="linear",t.dataExtent=this.getExtent()}),this._resetRange()},fF.prototype.resetItemSize=function(){iF.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;null!=t[0]&&!isNaN(t[0])||(t[0]=dF[0]),null!=t[1]&&!isNaN(t[1])||(t[1]=dF[1])},fF.prototype._resetRange=function(){var t=this.getExtent(),e=this.option.range;!e||e.auto?(t.auto=1,this.option.range=t):j(e)&&(e[0]>e[1]&&e.reverse(),e[0]=Math.max(e[0],t[0]),e[1]=Math.min(e[1],t[1]))},fF.prototype.completeVisualOption=function(){iF.prototype.completeVisualOption.apply(this,arguments),G(this.stateList,function(t){t=this.option.controller[t].symbolSize;t&&t[0]!==t[1]&&(t[0]=t[1]/3)},this)},fF.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},fF.prototype.getSelected=function(){var t=this.getExtent(),e=mo((this.get("range")||[]).slice());return e[0]>t[1]&&(e[0]=t[1]),e[1]>t[1]&&(e[1]=t[1]),e[0]<t[0]&&(e[0]=t[0]),e[1]<t[0]&&(e[1]=t[0]),e},fF.prototype.getValueState=function(t){var e=this.option.range,n=this.getExtent();return(e[0]<=n[0]||e[0]<=t)&&(e[1]>=n[1]||t<=e[1])?"inRange":"outOfRange"},fF.prototype.findTargetDataIndices=function(i){var o=[];return this.eachTargetSeries(function(t){var n=[],e=t.getData();e.each(this.getDataDimensionIndex(e),function(t,e){i[0]<=t&&t<=i[1]&&n.push(e)},this),o.push({seriesId:t.id,dataIndex:n})},this),o},fF.prototype.getVisualMeta=function(n){var t=yF(0,0,this.getExtent()),e=yF(0,0,this.option.range.slice()),i=[];function o(t,e){i.push({value:t,color:n(t,e)})}for(var r=0,a=0,s=e.length,l=t.length;a<l&&(!e.length||t[a]<=e[0]);a++)t[a]<e[r]&&o(t[a],"outOfRange");for(var u=1;r<s;r++,u=0)u&&i.length&&o(e[r],"outOfRange"),o(e[r],"inRange");for(u=1;a<l;a++)(!e.length||e[e.length-1]<t[a])&&(u&&(i.length&&o(i[i.length-1].value,"outOfRange"),u=0),o(t[a],"outOfRange"));var h=i.length;return{stops:i,outerColors:[h?i[0].color:"transparent",h?i[h-1].color:"transparent"]}},fF.type="visualMap.continuous",fF.defaultOption=Iu(Jn.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:"#fff",borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}}),fF),gr=(d(_F,mF=Wd),_F.prototype.init=function(t,e){this.ecModel=t,this.api=e},_F.prototype.render=function(t,e,n,i){!1!==(this.visualMapModel=t).get("show")?this.doRender(t,e,n,i):this.group.removeAll()},_F.prototype.renderBackground=function(t){var e=this.visualMapModel,n=lh(e.get("padding")||0),i=t.getBoundingRect();t.add(new Ts({z2:-1,silent:!0,shape:{x:i.x-n[3],y:i.y-n[0],width:i.width+n[3]+n[1],height:i.height+n[0]+n[2]},style:{fill:e.get("backgroundColor"),stroke:e.get("borderColor"),lineWidth:e.get("borderWidth")}}))},_F.prototype.getControllerVisual=function(n,i,o){var t,e=(o=o||{}).forceState,r=this.visualMapModel,a={};function s(t){return a[t]}function l(t,e){a[t]=e}"color"===i&&(t=r.get("contentColor"),a.color=t);var u=r.controllerVisuals[e||r.getValueState(n)];return G(vC.prepareVisualTypes(u),function(t){var e=u[t];o.convertOpacityToAlpha&&"opacity"===t&&(t="colorAlpha",e=u.__alphaForOpacity),vC.dependsOn(t,i)&&e&&e.applyVisual(n,s,l)}),a[i]},_F.prototype.positionGroup=function(t){var e=this.visualMapModel,n=this.api;Mh(t,e.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})},_F.prototype.doRender=function(t,e,n,i){},_F.type="visualMap",_F),xF=[["left","right","width"],["top","bottom","height"]];function _F(){var t=null!==mF&&mF.apply(this,arguments)||this;return t.type=_F.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}function bF(t,e,n){var i=t.option,o=i.align;if(null!=o&&"auto"!==o)return o;for(var t={width:e.getWidth(),height:e.getHeight()},r="horizontal"===i.orient?1:0,a=xF[r],s=[0,null,10],l={},u=0;u<3;u++)l[xF[1-r][u]]=s[u],l[a[u]]=2===u?n[0]:i[a[u]];o=[["x","width",3],["y","height",0]][r],e=Sh(l,t,i.padding);return a[(e.margin[o[2]]||0)+e[o[0]]+.5*e[o[1]]<.5*t[o[1]]?0:1]}function wF(t,e){return G(t||[],function(t){null!=t.dataIndex&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),t}var SF,MF=fo,IF=G,TF=Math.min,CF=Math.max;function DF(){var t=null!==SF&&SF.apply(this,arguments)||this;return t.type=DF.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}function AF(t,e,n,i){return new $g({shape:{points:t},draggable:!!n,cursor:e,drift:n,onmousemove:function(t){re(t.event)},ondragend:i})}function kF(t){var e=t.get("hoverLinkOnHandle");return null==e?t.get("realtime"):e}function LF(t){return"vertical"===t?"ns-resize":"ew-resize"}function PF(e,t){t.eachComponent({mainType:"visualMap",query:e},function(t){t.setSelected(e.selected)})}var OF=(d(DF,SF=gr),DF.prototype.doRender=function(t,e,n,i){this._api=n,i&&"selectDataRange"===i.type&&i.from===this.uid||this._buildView()},DF.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,e=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(e);t=t.get("text");this._renderEndsText(e,t,0),this._renderEndsText(e,t,1),this._updateView(!0),this.renderBackground(e),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(e)},DF.prototype._renderEndsText=function(t,e,n){var i,o,r;e&&(i=null!=(i=e[1-n])?i+"":"",o=(r=this.visualMapModel).get("textGap"),e=r.itemSize,r=this._shapes.mainGroup,e=this._applyTransform([e[0]/2,0===n?-o:e[1]+o],r),o=this._applyTransform(0===n?"bottom":"top",r),n=this._orient,r=this.visualMapModel.textStyleModel,this.group.add(new Fs({style:{x:e[0],y:e[1],verticalAlign:"horizontal"===n?"middle":o,align:"horizontal"===n?o:"center",text:i,font:r.getFont(),fill:r.getTextColor()}})))},DF.prototype._renderBar=function(t){var e=this.visualMapModel,n=this._shapes,i=e.itemSize,o=this._orient,r=this._useHandle,a=bF(e,this.api,i),s=n.mainGroup=this._createBarGroup(a),a=new ro;s.add(a),a.add(n.outOfRange=AF()),a.add(n.inRange=AF(null,r?LF(this._orient):null,X(this._dragHandle,this,"all",!1),X(this._dragHandle,this,"all",!0))),a.setClipPath(new Ts({shape:{x:0,y:0,width:i[0],height:i[1],r:3}}));a=e.textStyleModel.getTextRect("国"),a=CF(a.width,a.height);r&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(e,s,0,i,a,o),this._createHandle(e,s,1,i,a,o)),this._createIndicator(e,s,i,a,o),t.add(s)},DF.prototype._createHandle=function(t,e,n,i,o,r){var a=X(this._dragHandle,this,n,!1),s=X(this._dragHandle,this,n,!0),l=Wi(t.get("handleSize"),i[0]),u=am(t.get("handleIcon"),-l/2,-l/2,l,l,null,!0),h=LF(this._orient);u.attr({cursor:h,draggable:!0,drift:a,ondragend:s,onmousemove:function(t){re(t.event)}}),u.x=i[0]/2,u.useStyle(t.getModel("handleStyle").getItemStyle()),u.setStyle({strokeNoScale:!0,strokeFirst:!0}),u.style.lineWidth*=2,u.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),zl(u,!0),e.add(u);e=this.visualMapModel.textStyleModel,s=new Fs({cursor:h,draggable:!0,drift:a,onmousemove:function(t){re(t.event)},ondragend:s,style:{x:0,y:0,text:"",font:e.getFont(),fill:e.getTextColor()}});s.ensureState("blur").style={opacity:.1},s.stateTransition={duration:200},this.group.add(s);e=[l,0],l=this._shapes;l.handleThumbs[n]=u,l.handleLabelPoints[n]=e,l.handleLabels[n]=s},DF.prototype._createIndicator=function(t,e,n,i,o){var r=Wi(t.get("indicatorSize"),n[0]),a=am(t.get("indicatorIcon"),-r/2,-r/2,r,r,null,!0);a.attr({cursor:"move",invisible:!0,silent:!0,x:n[0]/2});r=t.getModel("indicatorStyle").getItemStyle();a instanceof ys?(t=a.style,a.useStyle(N({image:t.image,x:t.x,y:t.y,width:t.width,height:t.height},r))):a.useStyle(r),e.add(a);e=this.visualMapModel.textStyleModel,e=new Fs({silent:!0,invisible:!0,style:{x:0,y:0,text:"",font:e.getFont(),fill:e.getTextColor()}});this.group.add(e);i=[("horizontal"===o?i/2:6)+n[0]/2,0],n=this._shapes;n.indicator=a,n.indicatorLabel=e,n.indicatorLabelPoint=i,this._firstShowIndicator=!0},DF.prototype._dragHandle=function(t,e,n,i){this._useHandle&&(this._dragging=!e,e||(i=this._applyTransform([n,i],this._shapes.mainGroup,!0),this._updateInterval(t,i[1]),this._hideIndicator(),this._updateView()),e===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),e?this._hovering||this._clearHoverLinkToSeries():kF(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1))},DF.prototype._resetInterval=function(){var t=this.visualMapModel,e=this._dataInterval=t.getSelected(),n=t.getExtent(),t=[0,t.itemSize[1]];this._handleEnds=[MF(e[0],n,t,!0),MF(e[1],n,t,!0)]},DF.prototype._updateInterval=function(t,e){var n=this.visualMapModel,i=this._handleEnds,o=[0,n.itemSize[1]];tk(e=e||0,i,o,t,0);n=n.getExtent();this._dataInterval=[MF(i[0],o,n,!0),MF(i[1],o,n,!0)]},DF.prototype._updateView=function(t){var e=this.visualMapModel,n=e.getExtent(),i=this._shapes,o=[0,e.itemSize[1]],e=t?o:this._handleEnds,t=this._createBarVisual(this._dataInterval,n,e,"inRange"),o=this._createBarVisual(n,n,o,"outOfRange");i.inRange.setStyle({fill:t.barColor}).setShape("points",t.barPoints),i.outOfRange.setStyle({fill:o.barColor}).setShape("points",o.barPoints),this._updateHandle(e,t)},DF.prototype._createBarVisual=function(t,e,n,i){var o={forceState:i,convertOpacityToAlpha:!0},i=this._makeColorGradient(t,o),o=[this.getControllerVisual(t[0],"symbolSize",o),this.getControllerVisual(t[1],"symbolSize",o)],o=this._createBarPoints(n,o);return{barColor:new fy(0,0,0,1,i),barPoints:o,handlesColor:[i[0].color,i[i.length-1].color]}},DF.prototype._makeColorGradient=function(t,e){var n=[],i=(t[1]-t[0])/100;n.push({color:this.getControllerVisual(t[0],"color",e),offset:0});for(var o=1;o<100;o++){var r=t[0]+i*o;if(r>t[1])break;n.push({color:this.getControllerVisual(r,"color",e),offset:o/100})}return n.push({color:this.getControllerVisual(t[1],"color",e),offset:1}),n},DF.prototype._createBarPoints=function(t,e){var n=this.visualMapModel.itemSize;return[[n[0]-e[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-e[1],t[1]]]},DF.prototype._createBarGroup=function(t){var e=this._orient,n=this.visualMapModel.get("inverse");return new ro("horizontal"!==e||n?"horizontal"===e&&n?{scaleX:"bottom"===t?-1:1,rotation:-Math.PI/2}:"vertical"!==e||n?{scaleX:"left"===t?1:-1}:{scaleX:"left"===t?1:-1,scaleY:-1}:{scaleX:"bottom"===t?1:-1,rotation:Math.PI/2})},DF.prototype._updateHandle=function(i,o){var r,a,s,l,u,h;this._useHandle&&(r=this._shapes,a=this.visualMapModel,s=r.handleThumbs,l=r.handleLabels,u=a.itemSize,h=a.getExtent(),IF([0,1],function(t){var e=s[t];e.setStyle("fill",o.handlesColor[t]),e.y=i[t];var n=MF(i[t],[0,u[1]],h,!0),n=this.getControllerVisual(n,"symbolSize");e.scaleX=e.scaleY=n/u[0],e.x=u[0]-n/2;e=Xy(r.handleLabelPoints[t],Yy(e,this.group));l[t].setStyle({x:e[0],y:e[1],text:a.formatValueText(this._dataInterval[t]),verticalAlign:"middle",align:"vertical"===this._orient?this._applyTransform("left",r.mainGroup):"center"})},this))},DF.prototype._showIndicator=function(t,e,n,i){var o=this.visualMapModel,r=o.getExtent(),a=o.itemSize,s=[0,a[1]],l=this._shapes,u=l.indicator;if(u){u.attr("invisible",!1);var h=this.getControllerVisual(t,"color",{convertOpacityToAlpha:!0}),c=this.getControllerVisual(t,"symbolSize"),p=MF(t,r,s,!0),t=a[0]-c/2,r={x:u.x,y:u.y};u.y=p,u.x=t;s=Xy(l.indicatorLabelPoint,Yy(u,this.group)),a=l.indicatorLabel;a.attr("invisible",!1);c=this._applyTransform("left",l.mainGroup),l="horizontal"===this._orient;a.setStyle({text:(n||"")+o.formatValueText(e),verticalAlign:l?c:"middle",align:l?"center":c});h={x:t,y:p,style:{fill:h}},s={style:{x:s[0],y:s[1]}};o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator?(o={duration:100,easing:"cubicInOut",additive:!0},u.x=r.x,u.y=r.y,u.animateTo(h,o),a.animateTo(s,o)):(u.attr(h),a.attr(s)),this._firstShowIndicator=!1;var d=this._shapes.handleLabels;if(d)for(var f=0;f<d.length;f++)this._api.enterBlur(d[f])}},DF.prototype._enableHoverLinkToSeries=function(){var n=this;this._shapes.mainGroup.on("mousemove",function(t){var e;n._hovering=!0,n._dragging||(e=n.visualMapModel.itemSize,(t=n._applyTransform([t.offsetX,t.offsetY],n._shapes.mainGroup,!0,!0))[1]=TF(CF(0,t[1]),e[1]),n._doHoverLinkToSeries(t[1],0<=t[0]&&t[0]<=e[0]))}).on("mouseout",function(){n._hovering=!1,n._dragging||n._clearHoverLinkToSeries()})},DF.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},DF.prototype._doHoverLinkToSeries=function(t,e){var n,i,o,r,a,s=this.visualMapModel,l=s.itemSize;function u(t,e,n){for(var i=0,o=t.length;i<o;i++){var r=Ho(t[i].seriesId,null);if(null==r)return;for(var a=No(t[i].dataIndex),s=n&&n[r],l=0,u=a.length;l<u;l++){var h=a[l];s&&s[h]?s[h]=null:(e[r]||(e[r]={}))[h]=1}}}function h(t,e){var n,i,o=[];for(n in t)t.hasOwnProperty(n)&&null!=t[n]&&(e?o.push(+n):(i=h(t[n],!0)).length&&o.push({seriesId:n,dataIndex:i}));return o}s.option.hoverLink&&(n=[0,l[1]],i=s.getExtent(),t=TF(CF(n[0],t),n[1]),o=i,r=n,a=6,l=(l=s).get("hoverLinkDataSize"),a=[t-(r=a=l?MF(l,o,r,!0)/2:a),t+r],t=MF(t,n,i,!0),i=[MF(a[0],n,i,!0),MF(a[1],n,i,!0)],a[0]<n[0]&&(i[0]=-1/0),n[1]<a[1]&&(i[1]=1/0),e&&(i[0]===-1/0?this._showIndicator(t,i[1],"< ",r):i[1]===1/0?this._showIndicator(t,i[0],"> ",r):this._showIndicator(t,t,"≈ ",r)),t=this._hoverLinkDataIndices,r=[],(e||kF(s))&&(r=this._hoverLinkDataIndices=s.findTargetDataIndices(i)),i=r,r={},u(t||[],t={}),u(i||[],r,t),r=[h(t),h(r)],this._dispatchHighDown("downplay",wF(r[0],s)),this._dispatchHighDown("highlight",wF(r[1],s)))},DF.prototype._hoverLinkFromSeriesMouseOver=function(t){var e=t.target,n=this.visualMapModel;e&&null!=Gs(e).dataIndex&&(t=Gs(e),e=this.ecModel.getSeriesByIndex(t.seriesIndex),n.isTargetSeries(e)&&(t=(e=e.getData(t.dataType)).getStore().get(n.getDataDimensionIndex(e),t.dataIndex),isNaN(t)||this._showIndicator(t,t)))},DF.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var e=this._shapes.handleLabels;if(e)for(var n=0;n<e.length;n++)this._api.leaveBlur(e[n])},DF.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",wF(t,this.visualMapModel)),t.length=0},DF.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},DF.prototype._applyTransform=function(t,e,n,i){i=Yy(e,i?null:this.group);return(j(t)?Xy:Zy)(t,i,n)},DF.prototype._dispatchHighDown=function(t,e){e&&e.length&&this.api.dispatchAction({type:t,batch:e})},DF.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},DF.prototype.remove=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},DF.type="visualMap.continuous",DF),RF={type:"selectDataRange",event:"dataRangeSelected",update:"update"},NF=[{createOnAllSeries:!0,reset:function(n,t){var i=[];return t.eachComponent("visualMap",function(t){var f,g,y,m,e=n.pipelineContext;!t.isTargetSeries(n)||e&&e.large||i.push((e=t.stateList,f=t.targetVisuals,g=X(t.getValueState,t),y=t.getDataDimensionIndex(n.getData()),m={},G(e,function(t){var e=vC.prepareVisualTypes(f[t]);m[t]=e}),{progress:function(t,n){var e,i;function o(t){return zf(n,i,t)}function r(t,e){Vf(n,i,t,e)}null!=y&&(e=n.getDimensionIndex(y));for(var a=n.getStore();null!=(i=t.next());){var s=n.getRawDataItem(i);if(!s||!1!==s.visualMap)for(var l=null!=y?a.get(e,i):i,s=g(l),u=f[s],h=m[s],c=0,p=h.length;c<p;c++){var d=h[c];u[d]&&u[d].applyVisual(l,o,r)}}}}))}),i}},{createOnAllSeries:!0,reset:function(n,t){var i=n.getData(),o=[];t.eachComponent("visualMap",function(t){var e;t.isTargetSeries(n)&&(e=t.getVisualMeta(X(zF,null,n,t))||{stops:[],outerColors:[]},0<=(t=t.getDataDimensionIndex(i))&&(e.dimension=t,o.push(e)))}),n.getData().setVisual("visualMeta",o)}}];function zF(t,e,n,i){for(var o=e.targetVisuals[i],r=vC.prepareVisualTypes(o),a={color:Ef(t.getData(),"color")},s=0,l=r.length;s<l;s++){var u=r[s],u=o["opacity"===u?"__alphaForOpacity":u];u&&u.applyVisual(n,h,c)}return a.color;function h(t){return a[t]}function c(t,e){a[t]=e}}var EF=G;function VF(t){t=t&&t.visualMap;j(t)||(t=t?[t]:[]),EF(t,function(t){t&&(BF(t,"splitList")&&!BF(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList),(t=t.pieces)&&j(t)&&EF(t,function(t){$(t)&&(BF(t,"start")&&!BF(t,"min")&&(t.min=t.start),BF(t,"end")&&!BF(t,"max")&&(t.max=t.end))}))})}function BF(t,e){return t&&t.hasOwnProperty&&t.hasOwnProperty(e)}var FF=!1;function GF(e){FF||(FF=!0,e.registerSubTypeDefaulter("visualMap",function(t){return t.categories||(t.pieces?0<t.pieces.length:0<t.splitNumber)&&!t.calculable?"piecewise":"continuous"}),e.registerAction(RF,PF),G(NF,function(t){e.registerVisual(e.PRIORITY.VISUAL.COMPONENT,t)}),e.registerPreprocessor(VF))}function HF(t){t.registerComponentModel(vF),t.registerComponentView(OF),GF(t)}var WF,Jn=(d(YF,WF=Jn),YF.prototype.optionUpdated=function(t,e){WF.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode();this._pieceList=[],UF[this._mode].call(this,this._pieceList),this._resetSelected(t,e);var i=this.option.categories;this.resetVisual(function(t,e){"categories"===n?(t.mappingMethod="category",t.categories=P(i)):(t.dataExtent=this.getExtent(),t.mappingMethod="piecewise",t.pieceList=H(this._pieceList,function(t){return t=P(t),"inRange"!==e&&(t.visual=null),t}))})},YF.prototype.completeVisualOption=function(){var i=this.option,n={},t=vC.listVisualTypes(),o=this.isCategory();function r(t,e,n){return t&&t[e]&&t[e].hasOwnProperty(n)}G(i.pieces,function(e){G(t,function(t){e.hasOwnProperty(t)&&(n[t]=1)})}),G(n,function(t,e){var n=!1;G(this.stateList,function(t){n=n||r(i,t,e)||r(i.target,t,e)},this),n||G(this.stateList,function(t){(i[t]||(i[t]={}))[e]=aF.get(e,"inRange"===t?"active":"inactive",o)})},this),WF.prototype.completeVisualOption.apply(this,arguments)},YF.prototype._resetSelected=function(t,e){var n,i=this.option,o=this._pieceList,r=(e?i:t).selected||{};i.selected=r,G(o,function(t,e){t=this.getSelectedMapKey(t);r.hasOwnProperty(t)||(r[t]=!0)},this),"single"===i.selectedMode&&(n=!1,G(o,function(t,e){t=this.getSelectedMapKey(t);r[t]&&(n?r[t]=!1:n=!0)},this))},YF.prototype.getItemSymbol=function(){return this.get("itemSymbol")},YF.prototype.getSelectedMapKey=function(t){return"categories"===this._mode?t.value+"":t.index+""},YF.prototype.getPieceList=function(){return this._pieceList},YF.prototype._determineMode=function(){var t=this.option;return t.pieces&&0<t.pieces.length?"pieces":this.option.categories?"categories":"splitNumber"},YF.prototype.setSelected=function(t){this.option.selected=P(t)},YF.prototype.getValueState=function(t){t=vC.findPieceIndex(t,this._pieceList);return null!=t&&this.option.selected[this.getSelectedMapKey(this._pieceList[t])]?"inRange":"outOfRange"},YF.prototype.findTargetDataIndices=function(i){var o=[],r=this._pieceList;return this.eachTargetSeries(function(t){var n=[],e=t.getData();e.each(this.getDataDimensionIndex(e),function(t,e){vC.findPieceIndex(t,r)===i&&n.push(e)},this),o.push({seriesId:t.id,dataIndex:n})},this),o},YF.prototype.getRepresentValue=function(t){return this.isCategory()||null!=t.value?t.value:(t=t.interval||[])[0]===-1/0&&t[1]===1/0?0:(t[0]+t[1])/2},YF.prototype.getVisualMeta=function(i){if(!this.isCategory()){var t,o=[],r=["",""],a=this,e=this._pieceList.slice();e.length?((t=e[0].interval[0])!==-1/0&&e.unshift({interval:[-1/0,t]}),(t=e[e.length-1].interval[1])!==1/0&&e.push({interval:[t,1/0]})):e.push({interval:[-1/0,1/0]});var n=-1/0;return G(e,function(t){t=t.interval;t&&(t[0]>n&&s([n,t[0]],"outOfRange"),s(t.slice()),n=t[1])},this),{stops:o,outerColors:r}}function s(t,e){var n=a.getRepresentValue({interval:t});e=e||a.getValueState(n);e=i(n,e);t[0]===-1/0?r[0]=e:t[1]===1/0?r[1]=e:o.push({value:t[0],color:e},{value:t[1],color:e})}},YF.type="visualMap.piecewise",YF.defaultOption=Iu(Jn.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),YF),UF={splitNumber:function(t){var e=this.option,n=Math.min(e.precision,20),i=this.getExtent(),o=e.splitNumber,o=Math.max(parseInt(o,10),1);e.splitNumber=o;for(var r=(i[1]-i[0])/o;+r.toFixed(n)!==r&&n<5;)n++;e.precision=n,r=+r.toFixed(n),e.minOpen&&t.push({interval:[-1/0,i[0]],close:[0,0]});for(var a=0,s=i[0];a<o;s+=r,a++){var l=a===o-1?i[1]:s+r;t.push({interval:[s,l],close:[1,1]})}e.maxOpen&&t.push({interval:[i[1],1/0],close:[0,0]}),Do(t),G(t,function(t,e){t.index=e,t.text=this.formatValueText(t.interval)},this)},categories:function(e){var t=this.option;G(t.categories,function(t){e.push({text:this.formatValueText(t,!0),value:t})},this),XF(t,e)},pieces:function(c){var t=this.option;G(t.pieces,function(t,e){var n={text:"",index:e};if(null!=(t=!$(t)?{value:t}:t).label&&(n.text=t.label),t.hasOwnProperty("value")){e=n.value=t.value;n.interval=[e,e],n.close=[1,1]}else{for(var i=n.interval=[],o=n.close=[0,0],r=[1,0,1],a=[-1/0,1/0],s=[],l=0;l<2;l++){for(var u=[["gte","gt","min"],["lte","lt","max"]][l],h=0;h<3&&null==i[l];h++)i[l]=t[u[h]],o[l]=r[h],s[l]=2===h;null==i[l]&&(i[l]=a[l])}s[0]&&i[1]===1/0&&(o[0]=0),s[1]&&i[0]===-1/0&&(o[1]=0),i[0]===i[1]&&o[0]&&o[1]&&(n.value=i[0])}n.visual=vC.retrieveVisuals(t),c.push(n)},this),XF(t,c),Do(c),G(c,function(t){var e=t.close,e=[["<","≤"][e[1]],[">","≥"][e[0]]];t.text=t.text||this.formatValueText(null!=t.value?t.value:t.interval,!1,e)},this)}};function YF(){var t=null!==WF&&WF.apply(this,arguments)||this;return t.type=YF.type,t._pieceList=[],t}function XF(t,e){var n=t.inverse;("vertical"===t.orient?!n:n)&&e.reverse()}var ZF,jF=Jn,qF=(d(KF,ZF=gr),KF.prototype.doRender=function(){var i=this.group;i.removeAll();var o=this.visualMapModel,r=o.get("textGap"),t=o.textStyleModel,a=t.getFont(),s=t.getTextColor(),l=this._getItemAlign(),u=o.itemSize,e=this._getViewData(),t=e.endsText,h=ot(o.get("showLabel",!0),!t);t&&this._renderEndsText(i,t[0],u,h,l),G(e.viewPieceList,function(t){var e=t.piece,n=new ro;n.onclick=X(this._onItemClick,this,e),this._enableHoverLink(n,t.indexInModelPieceList);var t=o.getRepresentValue(e);this._createItemSymbol(n,t,[0,0,u[0],u[1]]),h&&(t=this.visualMapModel.getValueState(t),n.add(new Fs({style:{x:"right"===l?-r:u[0]+r,y:u[1]/2,text:e.text,verticalAlign:"middle",align:l,font:a,fill:s,opacity:"outOfRange"===t?.5:1}}))),i.add(n)},this),t&&this._renderEndsText(i,t[1],u,h,l),wh(o.get("orient"),i,o.get("itemGap")),this.renderBackground(i),this.positionGroup(i)},KF.prototype._enableHoverLink=function(t,n){var i=this;t.on("mouseover",function(){return e("highlight")}).on("mouseout",function(){return e("downplay")});var e=function(t){var e=i.visualMapModel;e.option.hoverLink&&i.api.dispatchAction({type:t,batch:wF(e.findTargetDataIndices(n),e)})}},KF.prototype._getItemAlign=function(){var t=this.visualMapModel,e=t.option;if("vertical"===e.orient)return bF(t,this.api,t.itemSize);e=e.align;return e=!e||"auto"===e?"left":e},KF.prototype._renderEndsText=function(t,e,n,i,o){var r,a;e&&(r=new ro,a=this.visualMapModel.textStyleModel,r.add(new Fs({style:{x:i?"right"===o?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?o:"center",text:e,font:a.getFont(),fill:a.getTextColor()}})),t.add(r))},KF.prototype._getViewData=function(){var t=this.visualMapModel,e=H(t.getPieceList(),function(t,e){return{piece:t,indexInModelPieceList:e}}),n=t.get("text"),i=t.get("orient"),t=t.get("inverse");return("horizontal"===i?t:!t)?e.reverse():n=n&&n.slice().reverse(),{viewPieceList:e,endsText:n}},KF.prototype._createItemSymbol=function(t,e,n){t.add(am(this.getControllerVisual(e,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(e,"color")))},KF.prototype._onItemClick=function(t){var e=this.visualMapModel,n=e.option,i=P(n.selected),o=e.getSelectedMapKey(t);"single"===n.selectedMode?(i[o]=!0,G(i,function(t,e){i[e]=e===o})):i[o]=!i[o],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:i})},KF.type="visualMap.piecewise",KF);function KF(){var t=null!==ZF&&ZF.apply(this,arguments)||this;return t.type=KF.type,t}function JF(t){t.registerComponentModel(jF),t.registerComponentView(qF),GF(t)}var QF={label:{enabled:!0},decal:{show:!1}},$F=Zo(),tG={};function eG(g,o){var t,r=g.getModel("aria");function y(t,e){if("string"!=typeof t)return t;var n=t;return G(e,function(t,e){n=n.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),n}r.get("enabled")&&(O((t=P(QF)).label,g.getLocaleModel().get("aria"),!1),O(r.option,t,!1),function(){{var n;r.getModel("decal").get("show")&&(n=yt(),g.eachSeries(function(t){var e;t.isColorBySeries()||((e=n.get(t.type))||n.set(t.type,e={}),$F(t).scope=e)}),g.eachRawSeries(function(i){var o,t,e,r,a,s,l;function u(t,e){e=t?N(N({},e),t):e;return e.dirty=!0,e}g.isSeriesFiltered(i)||("function"!=typeof i.enableAriaDecal?(o=i.getData(),i.isColorBySeries()?(t=hc(i.ecModel,i.name,tG,g.getSeriesCount()),e=o.getVisual("decal"),o.setVisual("decal",u(e,t))):(r=i.getRawData(),a={},s=$F(i).scope,o.each(function(t){var e=o.getRawIndex(t);a[e]=t}),l=r.count(),r.each(function(t){var e=a[t],n=r.getName(t)||t+"",t=hc(i.ecModel,n,s,l),n=o.getItemVisual(e,"decal");o.setItemVisual(e,"decal",u(n,t))}))):i.enableAriaDecal())}))}}(),function(){var t=g.getLocaleModel().get("aria"),h=r.getModel("label");{var e,c,p,d,f,n,i;h.option=z(h.option,t),h.get("enabled")&&(e=o.getZr().dom,h.get("description")?e.setAttribute("aria-label",h.get("description")):(c=g.getSeriesCount(),p=h.get(["data","maxCount"])||10,n=h.get(["series","maxCount"])||10,d=Math.min(c,n),c<1||(i=function(){var t=g.get("title");return(t=t&&t.length?t[0]:t)&&t.text}(),t=i?y(h.get(["general","withTitle"]),{title:i}):h.get(["general","withoutTitle"]),f=[],n=1<c?h.get(["series","multiple","prefix"]):h.get(["series","single","prefix"]),t+=y(n,{seriesCount:c}),g.eachSeries(function(t,e){if(e<d){var n=void 0,e=t.get("name")?"withName":"withoutName";n=y(n=1<c?h.get(["series","multiple",e]):h.get(["series","single",e]),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:(e=t.subType,g.getLocaleModel().get(["series","typeNames"])[e]||"自定义图")});var i=t.getData();i.count()>p?n+=y(h.get(["data","partialData"]),{displayCnt:p}):n+=h.get(["data","allData"]);for(var o,r,a,s=h.get(["data","separator","middle"]),t=h.get(["data","separator","end"]),l=[],u=0;u<i.count();u++)u<p&&(o=i.getName(u),r=i.getValues(u),a=h.get(["data",o?"withName":"withoutName"]),l.push(y(a,{name:o,value:r.join(s)})));n+=l.join(s)+t,f.push(n)}}),i=h.getModel(["series","multiple","separator"]),n=i.get("middle"),i=i.get("end"),t+=f.join(n)+i,e.setAttribute("aria-label",t))))}}())}function nG(t){var e;t&&t.aria&&(null!=(e=t.aria).show&&(e.enabled=e.show),e.label=e.label||{},G(["description","general","series","data"],function(t){null!=e[t]&&(e.label[t]=e[t])}))}var iG={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},oG=(gG.prototype.evaluate=function(t){var e=typeof t;return"string"==e?this._condVal.test(t):"number"==e&&this._condVal.test(t+"")},gG),rG=(fG.prototype.evaluate=function(){return this.value},fG),aG=(dG.prototype.evaluate=function(){for(var t=this.children,e=0;e<t.length;e++)if(!t[e].evaluate())return!1;return!0},dG),sG=(pG.prototype.evaluate=function(){for(var t=this.children,e=0;e<t.length;e++)if(t[e].evaluate())return!0;return!1},pG),lG=(cG.prototype.evaluate=function(){return!this.child.evaluate()},cG),uG=(hG.prototype.evaluate=function(){for(var t=!!this.valueParser,e=(0,this.getValue)(this.valueGetterParam),n=t?this.valueParser(e):null,i=0;i<this.subCondList.length;i++)if(!this.subCondList[i].evaluate(t?n:e))return!1;return!0},hG);function hG(){}function cG(){}function pG(){}function dG(){}function fG(){}function gG(t){null==(this._condVal=K(t)?new RegExp(t):"[object RegExp]"===x.call(t)?t:null)&&pc("")}function yG(t,e){if(!0===t||!1===t){var n=new rG;return n.value=t,n}return vG(t)||pc(""),t.and?mG("and",t,e):t.or?mG("or",t,e):(t.not?function(t,e){var n=t.not;vG(n)||pc("");t=new lG;return t.child=yG(n,e),t.child||pc(""),t}:function(t,e){for(var n=e.prepareGetValue(t),i=[],o=Y(t),r=t.parser,a=r?Rp(r):null,s=0;s<o.length;s++){var l,u=o[s];"parser"===u||e.valueGetterAttrMap.get(u)||(l=xt(iG,u)?iG[u]:u,u=t[u],u=a?a(u):u,(u=function(t,e){return"eq"===t||"ne"===t?new Vp("eq"===t,e):xt(Np,t)?new zp(t,e):null}(l,u)||"reg"===l&&new oG(u))||pc(""),i.push(u))}i.length||pc("");r=new uG;return r.valueGetterParam=n,r.valueParser=a,r.getValue=e.getValue,r.subCondList=i,r})(t,e)}function mG(t,e,n){e=e[t];j(e)||pc(""),e.length||pc("");t=new("and"===t?aG:sG);return t.children=H(e,function(t){return yG(t,n)}),t.children.length||pc(""),t}function vG(t){return $(t)&&!F(t)}var xG=(_G.prototype.evaluate=function(){return this._cond.evaluate()},_G);function _G(t,e){this._cond=yG(t,e)}var bG={type:"echarts:filter",transform:function(t){for(var e,n,i=t.upstream,o=(n=t.config,t={valueGetterAttrMap:yt({dimension:!0}),prepareGetValue:function(t){var e=t.dimension;xt(t,"dimension")||pc("");e=i.getDimensionInfo(e);return e||pc(""),{dimIdx:e.index}},getValue:function(t){return i.retrieveValueFromItem(e,t.dimIdx)}},new xG(n,t)),r=[],a=0,s=i.count();a<s;a++)e=i.getRawDataItem(a),o.evaluate()&&r.push(e);return{data:r}}},wG={type:"echarts:sort",transform:function(t){var a=t.upstream,t=t.config,t=No(t);t.length||pc("");var s=[];G(t,function(t){var e=t.dimension,n=t.order,i=t.parser,o=t.incomparable;null==e&&pc(""),"asc"!==n&&"desc"!==n&&pc(""),o&&"min"!==o&&"max"!==o&&pc(""),"asc"!==n&&"desc"!==n&&pc("");t=a.getDimensionInfo(e);t||pc("");e=i?Rp(i):null;i&&!e&&pc(""),s.push({dimIdx:t.index,parser:e,comparator:new Ep(n,o)})});t=a.sourceFormat;t!==Hh&&t!==Wh&&pc("");for(var e=[],n=0,i=a.count();n<i;n++)e.push(a.getRawDataItem(n));return e.sort(function(t,e){for(var n=0;n<s.length;n++){var i=s[n],o=a.retrieveValueFromItem(t,i.dimIdx),r=a.retrieveValueFromItem(e,i.dimIdx);i.parser&&(o=i.parser(o),r=i.parser(r));r=i.comparator.evaluate(o,r);if(0!==r)return r}return 0}),{data:e}}};var SG,MG,IG=(d(DG,MG=Vh),DG.prototype.init=function(t,e,n){MG.prototype.init.call(this,t,e,n),this._sourceManager=new ad(this),hd(this)},DG.prototype.mergeOption=function(t,e){MG.prototype.mergeOption.call(this,t,e),hd(this)},DG.prototype.optionUpdated=function(){this._sourceManager.dirty()},DG.prototype.getSourceManager=function(){return this._sourceManager},DG.type="dataset",DG.defaultOption={seriesLayoutBy:Zh},DG),TG=(d(CG,SG=Wd),CG.type="dataset",CG);function CG(){var t=null!==SG&&SG.apply(this,arguments)||this;return t.type="dataset",t}function DG(){var t=null!==MG&&MG.apply(this,arguments)||this;return t.type="dataset",t}var AG=Ba.CMD;function kG(t,e){return Math.abs(t-e)<1e-5}function LG(t){var o,e,n=t.data,i=t.len(),r=[],a=0,s=0,l=0,u=0;function h(t,e){o&&2<o.length&&r.push(o),o=[t,e]}function c(t,e,n,i){kG(t,n)&&kG(e,i)||o.push(t,e,n,i,n,i)}for(var p,d,f,g,y,m,v,x,_,b,w,S,M=0;M<i;){var I=n[M++],T=1===M;switch(T&&(l=a=n[M],u=s=n[M+1],I!==AG.L&&I!==AG.C&&I!==AG.Q||(o=[l,u])),I){case AG.M:a=l=n[M++],s=u=n[M++],h(l,u);break;case AG.L:c(a,s,R=n[M++],N=n[M++]),a=R,s=N;break;case AG.C:o.push(n[M++],n[M++],n[M++],n[M++],a=n[M++],s=n[M++]);break;case AG.Q:R=n[M++],N=n[M++],e=n[M++],L=n[M++],o.push(a+2/3*(R-a),s+2/3*(N-s),e+2/3*(R-e),L+2/3*(N-L),e,L),a=e,s=L;break;case AG.A:var C=n[M++],D=n[M++],A=n[M++],k=n[M++],L=n[M++],P=n[M++]+L;M+=1;var O=!n[M++],R=Math.cos(L)*A+C,N=Math.sin(L)*k+D;T?h(l=R,u=N):c(a,s,R,N);for(var a=Math.cos(P)*A+C,s=Math.sin(P)*k+D,z=(O?-1:1)*Math.PI/2,E=L;O?P<E:E<P;E+=z){var V=O?Math.max(E+z,P):Math.min(E+z,P);p=E,d=V,f=C,g=D,y=A,m=k,_=v=V=S=w=b=_=x=v=void 0,v=Math.abs(d-p),x=4*Math.tan(v/4)/3,_=d<p?-1:1,b=Math.cos(p),w=Math.sin(p),S=Math.cos(d),V=Math.sin(d),v=S*y+f,p=V*m+g,d=y*x*_,_*=m*x,o.push(b*y+f-d*w,w*m+g+_*b,v+d*V,p-_*S,v,p)}break;case AG.R:l=a=n[M++],u=s=n[M++],R=l+n[M++],N=u+n[M++],h(R,u),c(R,u,R,N),c(R,N,l,N),c(l,N,l,u),c(l,u,R,u);break;case AG.Z:o&&c(a,s,l,u),a=l,s=u}}return o&&2<o.length&&r.push(o),r}function PG(t,e){var n=LG(t),i=[];e=e||1;for(var o=0;o<n.length;o++){var r=n[o],a=[],s=r[0],l=r[1];a.push(s,l);for(var u=2;u<r.length;){var h=r[u++],c=r[u++],p=r[u++],d=r[u++],f=r[u++],g=r[u++];(function t(e,n,i,o,r,a,s,l,u,h){var c,p,d,f,g,y,m,v,x;kG(e,i)&&kG(n,o)&&kG(r,s)&&kG(a,l)?u.push(s,l):(c=(v=2/h)*v,p=s-e,d=l-n,p/=y=Math.sqrt(p*p+d*d),d/=y,m=(g=r-s)*g+(x=a-l)*x,(y=(f=i-e)*f+(v=o-n)*v)<c&&m<c?u.push(s,l):(x=-p*g-d*x,y-(v=p*f+d*v)*v<c&&0<=v&&m-x*x<c&&0<=x?u.push(s,l):(x=[],ea(e,i,r,s,.5,s=[]),ea(n,o,a,l,.5,x),t(s[0],x[0],s[1],x[1],s[2],x[2],s[3],x[3],u,h),t(s[4],x[4],s[5],x[5],s[6],x[6],s[7],x[7],u,h))))})(s,l,h,c,p,d,f,g,a,e),s=f,l=g}i.push(a)}return i}function OG(t,e,n){var i=t[e],e=t[1-e],e=Math.abs(i/e),o=Math.ceil(Math.sqrt(e*n)),r=Math.floor(n/o);0===r&&(r=1,o=n);for(var a=[],s=0;s<o;s++)a.push(r);var l=n-o*r;if(0<l)for(s=0;s<l;s++)a[s%o]+=1;return a}function RG(t,e,n){for(var i=t.r0,o=t.r,r=t.startAngle,a=t.endAngle,s=Math.abs(a-r),a=s*o,l=o-i,u=a>Math.abs(l),h=OG([a,l],u?0:1,e),c=(u?s:l)/h.length,p=0;p<h.length;p++)for(var d=(u?l:s)/h[p],f=0;f<h[p];f++){var g={};u?(g.startAngle=r+c*p,g.endAngle=r+c*(p+1),g.r0=i+d*f,g.r=i+d*(f+1)):(g.startAngle=r+d*f,g.endAngle=r+d*(f+1),g.r0=i+c*p,g.r=i+c*(p+1)),g.clockwise=t.clockwise,g.cx=t.cx,g.cy=t.cy,n.push(g)}}function NG(t,e){var n=t[t.length-1];n&&n[0]===e[0]&&n[1]===e[1]||t.push(e)}function zG(t,e,n){for(var i,o,r,a,s,l,u,h=t.length,c=[],p=0;p<h;p++){var d=t[p],f=t[(p+1)%h],f=(i=d[0],o=d[1],r=f[0],a=f[1],s=e.x,l=e.y,u=n.x,d=n.y,f=void 0,f=r-i,r=a-o,d=(a=u-s)*r-f*(u=d-l),Math.abs(d)<1e-6||(d=((i-s)*u-a*(o-l))/d)<0||1<d?null:new bi(d*f+i,d*r+o));f&&c.push({projPt:(i=f,d=e,r=n,o=void 0,o=new bi,bi.sub(o,r,d),o.normalize(),r=new bi,bi.sub(r,i,d),r.dot(o)),pt:f,idx:p})}if(c.length<2)return[{points:t},{points:t}];c.sort(function(t,e){return t.projPt-e.projPt});var g=c[0],y=c[c.length-1];y.idx<g.idx&&(v=g,g=y,y=v);for(var m=[g.pt.x,g.pt.y],v=[y.pt.x,y.pt.y],x=[m],_=[v],p=g.idx+1;p<=y.idx;p++)NG(x,t[p].slice());for(NG(x,v),NG(x,m),p=y.idx+1;p<=g.idx+h;p++)NG(_,t[p%h].slice());return NG(_,m),NG(_,v),[{points:x},{points:_}]}function EG(t){var e=t.points,n=[],i=[];ya(e,n,i);var o=new ki(n[0],n[1],i[0]-n[0],i[1]-n[1]),r=o.width,a=o.height,t=o.x,i=o.y,n=new bi,o=new bi;return a<r?(n.x=o.x=t+r/2,n.y=i,o.y=i+a):(n.y=o.y=i+a/2,n.x=t,o.x=t+r),zG(e,n,o)}function VG(t,e,n,i){var o;return 1===n?i.push(e):(o=Math.floor(n/2),e=t(e),VG(t,e[0],o,i),VG(t,e[1],n-o,i)),i}function BG(t,e){var n,i=[],o=t.shape;switch(t.type){case"rect":(function(t,e,n){for(var i=t.width,o=t.height,r=o<i,a=OG([i,o],r?0:1,e),s=r?"width":"height",l=r?"height":"width",u=r?"x":"y",h=r?"y":"x",c=t[s]/a.length,p=0;p<a.length;p++)for(var d=t[l]/a[p],f=0;f<a[p];f++){var g={};g[u]=p*c,g[h]=f*d,g[s]=c,g[l]=d,g.x+=t.x,g.y+=t.y,n.push(g)}})(o,e,i),n=Ts;break;case"sector":RG(o,e,i),n=Wg;break;case"circle":RG({r0:0,r:o.r,startAngle:0,endAngle:2*Math.PI,cx:o.cx,cy:o.cy},e,i),n=Wg;break;default:var r=t.getComputedTransform(),r=r?Math.sqrt(Math.max(r[0]*r[0]+r[1]*r[1],r[2]*r[2]+r[3]*r[3])):1,a=H(PG(t.getUpdatedPathProxy(),r),function(t){for(var e=[],n=0;n<t.length;)e.push([t[n++],t[n++]]);return e}),s=a.length;if(0===s)VG(EG,{points:a[0]},e,i);else if(s===e)for(var l=0;l<s;l++)i.push({points:a[l]});else{var u=0,h=H(a,function(t){var e=[],n=[];ya(t,e,n);e=(n[1]-e[1])*(n[0]-e[0]);return u+=e,{poly:t,area:e}});h.sort(function(t,e){return e.area-t.area});for(var c=e,l=0;l<s;l++){var p=h[l];if(c<=0)break;var d=l===s-1?c:Math.ceil(p.area/u*e);d<0||(VG(EG,{points:p.poly},d,i),c-=d)}}n=$g}if(!n)return function(t,e){for(var n=[],i=0;i<e;i++)n.push(bg(t));return n}(t,e);var f,g,y=[];for(l=0;l<i.length;l++){var m=new n;m.setShape(i[l]),f=t,(g=m).setStyle(f.style),g.z=f.z,g.z2=f.z2,g.zlevel=f.zlevel,y.push(m)}return y}function FG(t,e){for(var n=t.length,i=t[n-2],o=t[n-1],r=[],a=0;a<e.length;)r[a++]=i,r[a++]=o;return r}function GG(t,e){for(var n,i,o=[],r=[],a=0;a<Math.max(t.length,e.length);a++){var s=t[a],l=e[a],u=void 0,h=void 0;s?l?(n=u=(i=function(t,e){var n=t.length,i=e.length;if(n===i)return[t,e];for(var o=[],r=[],a=n<i?t:e,s=Math.min(n,i),n=Math.abs(i-n)/6,l=Math.ceil(n/((s-2)/6))+1,u=[a[0],a[1]],h=n,c=2;c<s;){var p=a[c-2],d=a[c-1],f=a[c++],g=a[c++],y=a[c++],m=a[c++],v=a[c++],x=a[c++];if(h<=0)u.push(f,g,y,m,v,x);else{for(var _=Math.min(h,l-1)+1,b=1;b<=_;b++){var w=b/_;ea(p,f,y,v,w,o),ea(d,g,m,x,w,r),u.push(o[1],r[1],o[2],r[2],p=o[3],d=r[3]),f=o[5],g=r[5],y=o[6],m=r[6]}h-=_-1}}return a===t?[u,e]:[t,u]}(s,l))[0],i=h=i[1]):(h=FG(i||s,s),u=s):(u=FG(n||l,l),h=l),o.push(u),r.push(h)}return[o,r]}function HG(t){for(var e=0,n=0,i=0,o=t.length,r=0,a=o-2;r<o;a=r,r+=2){var s=t[a],l=t[a+1],u=t[r],h=t[r+1],c=s*h-u*l;e+=c,n+=(s+u)*c,i+=(l+h)*c}return 0===e?[t[0]||0,t[1]||0]:[n/e/3,i/e/3,e]}function WG(t,e,n,i){for(var o,r=[],a=0;a<t.length;a++){var s=t[a],l=e[a],u=HG(s),h=HG(l);null==o&&(o=u[2]<0!=h[2]<0);for(var c=[],p=[],d=0,f=1/0,g=[],y=s.length,m=6*function(t,e,n,i){for(var o=(t.length-2)/6,r=1/0,a=0,s=t.length,l=s-2,u=0;u<o;u++){for(var h=6*u,c=0,p=0;p<s;p+=2){var d=0===p?h:(h+p-2)%l+2,f=t[d]-n[0],d=t[1+d]-n[1],f=e[p]-i[0]-f,d=e[p+1]-i[1]-d;c+=f*f+d*d}c<r&&(r=c,a=u)}return a}(s=o?function(t){for(var e=[],n=t.length,i=0;i<n;i+=2)e[i]=t[n-i-2],e[i+1]=t[n-i-1];return e}(s):s,l,u,h),v=y-2,x=0;x<v;x+=2){var _=(m+x)%v+2;c[x+2]=s[_]-u[0],c[x+3]=s[1+_]-u[1]}if(c[0]=s[m]-u[0],c[1]=s[1+m]-u[1],0<n)for(var b=i/n,w=-i/2;w<=i/2;w+=b){for(var S=Math.sin(w),M=Math.cos(w),I=0,x=0;x<s.length;x+=2){var T=c[x],C=c[x+1],D=l[x]-h[0],A=l[x+1]-h[1],k=D*M-A*S,A=D*S+A*M,T=(g[x]=k)-T,C=(g[x+1]=A)-C;I+=T*T+C*C}if(I<f)for(var f=I,d=w,L=0;L<g.length;L++)p[L]=g[L]}else for(var P=0;P<y;P+=2)p[P]=l[P]-h[0],p[P+1]=l[P+1]-h[1];r.push({from:c,to:p,fromCp:u,toCp:h,rotation:-d})}return r}function UG(t){return t.__isCombineMorphing}var YG="__mOriginal_";function XG(t,e,n){var i=YG+e,o=t[i]||t[e];t[i]||(t[i]=t[e]);var r=n.replace,a=n.after,s=n.before;t[e]=function(){var t,e=arguments;return s&&s.apply(this,e),t=(r||o).apply(this,e),a&&a.apply(this,e),t}}function ZG(t,e){var n=YG+e;t[n]&&(t[e]=t[n],t[n]=null)}function jG(t,e){for(var n=0;n<t.length;n++)for(var i=t[n],o=0;o<i.length;){var r=i[o],a=i[o+1];i[o++]=e[0]*r+e[2]*a+e[4],i[o++]=e[1]*r+e[3]*a+e[5]}}function qG(t,S){var e=t.getUpdatedPathProxy(),n=S.getUpdatedPathProxy(),i=GG(LG(e),LG(n)),e=i[0],n=i[1],i=t.getComputedTransform(),t=S.getComputedTransform();i&&jG(e,i),t&&jG(n,t),XG(S,"updateTransform",{replace:function(){this.transform=null}}),S.transform=null;var M=WG(e,n,10,Math.PI),I=[];XG(S,"buildPath",{replace:function(t){for(var e=S.__morphT,n=1-e,i=[],o=0;o<M.length;o++){var r=M[o],a=r.from,s=r.to,l=r.rotation*e,u=r.fromCp,r=r.toCp,h=Math.sin(l),c=Math.cos(l);Nt(i,u,r,e);for(var p=0;p<a.length;p+=2){var d=a[p],f=a[p+1],g=s[p],y=s[p+1],d=d*n+g*e,f=f*n+y*e;I[p]=d*c-f*h+i[0],I[p+1]=d*h+f*c+i[1]}var m=I[0],v=I[1];for(t.moveTo(m,v),p=2;p<a.length;){var g=I[p++],y=I[p++],x=I[p++],_=I[p++],b=I[p++],w=I[p++];m===g&&v===y&&x===b&&_===w?t.lineTo(b,w):t.bezierCurveTo(g,y,x,_,b,w),m=b,v=w}}}})}function KG(t,e,n){if(!t||!e)return e;var i=n.done,o=n.during;return qG(t,e),e.__morphT=0,e.animateTo({__morphT:1},z({during:function(t){e.dirtyShape(),o&&o(t)},done:function(){ZG(e,"buildPath"),ZG(e,"updateTransform"),e.__morphT=-1,e.createPathProxy(),e.dirtyShape(),i&&i()}},n)),e}function JG(n){var i=1/0,o=1/0,r=-1/0,a=-1/0,t=H(n,function(t){var e=t.getBoundingRect(),n=t.getComputedTransform(),t=e.x+e.width/2+(n?n[4]:0),n=e.y+e.height/2+(n?n[5]:0);return i=Math.min(t,i),o=Math.min(n,o),r=Math.max(t,r),a=Math.max(n,a),[t,n]});return H(t,function(t,e){return{cp:t,z:function(t,e,n,i,o,r){t=o===n?0:Math.round(32767*(t-n)/(o-n)),e=r===i?0:Math.round(32767*(e-i)/(r-i));for(var a=0,s=32768;0<s;s/=2){var l=0,u=0;a+=s*s*(3*(l=0<(t&s)?1:l)^(u=0<(e&s)?1:u)),0===u&&(1===l&&(t=s-1-t,e=s-1-e),l=t,t=e,e=l)}return a}(t[0],t[1],i,o,r,a),path:n[e]}}).sort(function(t,e){return t.z-e.z}).map(function(t){return t.path})}function QG(t){return BG(t.path,t.count)}function $G(){return{fromIndividuals:[],toIndividuals:[],count:0}}function tH(e,i,t){var o=[];!function t(e){for(var n=0;n<e.length;n++){var i=e[n];UG(i)?t(i.childrenRef()):i instanceof as&&o.push(i)}}(e);var n=o.length;if(!n)return $G();var r=t.dividePath||QG;if((a=r({path:i,count:n})).length!==n)return $G();for(var o=JG(o),a=JG(a),s=t.done,l=t.during,u=t.individualDelay,h=new _i,c=0;c<n;c++){var p=o[c],d=a[c];d.parent=i,d.copyTransform(h),u||qG(p,d)}function f(t){for(var e=0;e<a.length;e++)a[e].addSelfToZr(t)}function g(){i.__isCombineMorphing=!1,i.__morphT=-1,i.childrenRef=null,ZG(i,"addSelfToZr"),ZG(i,"removeSelfFromZr")}i.__isCombineMorphing=!0,i.childrenRef=function(){return a},XG(i,"addSelfToZr",{after:function(t){f(t)}}),XG(i,"removeSelfFromZr",{after:function(t){for(var e=0;e<a.length;e++)a[e].removeSelfFromZr(t)}});var y=a.length;if(u)for(var m=y,v=function(){0===--m&&(g(),s&&s())},c=0;c<y;c++){var x=u?z({delay:(t.delay||0)+u(c,y,o[c],a[c]),done:v},t):t;KG(o[c],a[c],x)}else i.__morphT=0,i.animateTo({__morphT:1},z({during:function(t){for(var e=0;e<y;e++){var n=a[e];n.__morphT=i.__morphT,n.dirtyShape()}l&&l(t)},done:function(){g();for(var t=0;t<e.length;t++)ZG(e[t],"updateTransform");s&&s()}},t));return i.__zr&&f(i.__zr),{fromIndividuals:o,toIndividuals:a,count:y}}function eH(t,e,n){var i=e.length,o=[],r=n.dividePath||QG;if(UG(t)){!function t(e){for(var n=0;n<e.length;n++){var i=e[n];UG(i)?t(i.childrenRef()):i instanceof as&&o.push(i)}}(t.childrenRef());var a=o.length;if(a<i)for(var s=0,l=a;l<i;l++)o.push(bg(o[s++%a]));o.length=i}else{for(var o=r({path:t,count:i}),u=t.getComputedTransform(),l=0;l<o.length;l++)o[l].setLocalTransform(u);if(o.length!==i)return $G()}o=JG(o),e=JG(e);var h=n.individualDelay;for(l=0;l<i;l++){var c=h?z({delay:(n.delay||0)+h(l,i,o[l],e[l])},n):n;KG(o[l],e[l],c)}return{fromIndividuals:o,toIndividuals:e,count:e.length}}function nH(t){return j(t[0])}function iH(t,e){for(var n=[],i=t.length,o=0;o<i;o++)n.push({one:t[o],many:[]});for(o=0;o<e.length;o++)for(var r=e[o].length,a=void 0,a=0;a<r;a++)n[a%i].many.push(e[o][a]);for(var s=0,o=i-1;0<=o;o--)if(!n[o].many.length){var l=n[s].many;if(l.length<=1){if(!s)return n;s=0}var r=l.length,u=Math.ceil(r/2);n[o].many=l.slice(u,r),n[s].many=l.slice(0,u),s++}return n}var oH={clone:function(t){for(var e=[],n=1-Math.pow(1-t.path.style.opacity,1/t.count),i=0;i<t.count;i++){var o=bg(t.path);o.setStyle("opacity",n),e.push(o)}return e},split:null};function rH(t,e,f,n,i,g){if(t.length&&e.length){i=Gl("update",n,i);if(i&&0<i.duration){var o,r,y=n.getModel("universalTransition").get("delay"),m=Object.assign({setToFinal:!0},i);nH(t)&&(o=t,r=e),nH(e)&&(o=e,r=t);for(var a=o?o===t:t.length>e.length,s=o?iH(r,o):iH(a?e:t,[a?t:e]),l=0,u=0;u<s.length;u++)l+=s[u].many.length;for(var h=0,u=0;u<s.length;u++)(function t(e,n,o,r,i){var a=e.many,s=e.one;if(1!==a.length||i)for(var l=z({dividePath:oH[f],individualDelay:y&&function(t,e,n,i){return y(t+o,r)}},m),l=n?tH(a,s,l):eH(s,a,l),u=l.fromIndividuals,h=l.toIndividuals,c=u.length,p=0;p<c;p++)d=y?z({delay:y(p,c)},m):m,g(u[p],h[p],n?a[p]:e.one,n?e.one:a[p],d);else{var d,l=n?a[0]:s,s=n?s:a[0];UG(l)?t({many:[l],one:s},!0,o,r,!0):(d=y?z({delay:y(o,r)},m):m,KG(l,s,d),g(l,s,l,s,d))}})(s[u],a,h,l),h+=s[u].many.length}}}function aH(t){if(!t)return[];if(j(t)){for(var e=[],n=0;n<t.length;n++)e.push(aH(t[n]));return e}var i=[];return t.traverse(function(t){t instanceof as&&!t.disableMorphing&&!t.invisible&&!t.ignore&&i.push(t)}),i}var sH=1e4,lH=Zo();function uH(t){var r=[];return G(t,function(t){var e=t.data;if(!(e.count()>sH))for(var n=e.getIndices(),i=function(t){for(var e=t.dimensions,n=0;n<e.length;n++){var i=t.getDimensionInfo(e[n]);if(i&&0===i.otherDims.itemGroupId)return e[n]}}(e),o=0;o<n.length;o++)r.push({data:e,dim:t.dim||i,divide:t.divide,dataIndex:o})}),r}function hH(t,e,n){t.traverse(function(t){t instanceof as&&Ul(t,{style:{opacity:0}},e,{dataIndex:n,isFrom:!0})})}function cH(t){var e;t.parent&&(e=t.getComputedTransform(),t.setLocalTransform(e),t.parent.remove(t))}function pH(t){t.stopAnimation(),t.isGroup&&t.traverse(function(t){t.stopAnimation()})}function dH(t,e,n){var i=Gl("update",n,e);i&&t.traverse(function(t){var e;t instanceof Fr&&((e=Fl(t).oldStyle)&&t.animateFrom({style:e},i))})}function fH(t,e,i){var a=uH(t),s=uH(e);function l(t,e,n,i,o){(n||t)&&e.animateFrom({style:(n||t).style},o)}function n(t){for(var e=0;e<t.length;e++)if(t[e].dim)return t[e].dim}var u=n(a),h=n(s),c=!1;function o(a,s){return function(t){var e=t.data,n=t.dataIndex;if(s)return e.getId(n);var i=e.hostModel&&e.hostModel.get("dataGroupId"),o=a?u||h:h||u,t=o&&e.getDimensionInfo(o),o=t&&t.ordinalMeta;if(t){var r=e.get(t.name,n);return o&&o.categories[r]||r+""}r=e.getRawDataItem(n);return r&&r.groupId?r.groupId+"":i||e.getId(n)}}var t=function(t,e){var n=t.length;if(n!==e.length)return!1;for(var i=0;i<n;i++){var o=t[i],r=e[i];if(o.data.getId(o.dataIndex)!==r.data.getId(r.dataIndex))return!1}return!0}(a,s),p={};if(!t)for(var r=0;r<s.length;r++){var d=s[r],d=d.data.getItemGraphicEl(d.dataIndex);d&&(p[d.id]=!0)}function f(t,e){var n=a[e],i=s[t],o=i.data.hostModel,e=n.data.getItemGraphicEl(n.dataIndex),n=i.data.getItemGraphicEl(i.dataIndex);e!==n?e&&p[e.id]||n&&(pH(n),e?(pH(e),cH(e),c=!0,rH(aH(e),aH(n),i.divide,o,t,l)):hH(n,o,t)):n&&dH(n,i.dataIndex,o)}new Vx(a,s,o(!0,t),o(!1,t),null,"multiple").update(f).updateManyToOne(function(t,e){var n=s[t],i=n.data,o=i.hostModel,r=i.getItemGraphicEl(n.dataIndex),e=U(H(e,function(t){return a[t].data.getItemGraphicEl(a[t].dataIndex)}),function(t){return t&&t!==r&&!p[t.id]});r&&(pH(r),e.length?(G(e,function(t){pH(t),cH(t)}),c=!0,rH(aH(e),aH(r),n.divide,o,t,l)):hH(r,o,n.dataIndex))}).updateOneToMany(function(e,t){var n,i=a[t],o=i.data.getItemGraphicEl(i.dataIndex);o&&p[o.id]||(t=U(H(e,function(t){return s[t].data.getItemGraphicEl(s[t].dataIndex)}),function(t){return t&&t!==o}),n=s[e[0]].data.hostModel,t.length&&(G(t,pH),o?(pH(o),cH(o),c=!0,rH(aH(o),aH(t),i.divide,n,e[0],l)):G(t,function(t){return hH(t,n,e[0])})))}).updateManyToMany(function(n,i){new Vx(i,n,function(t){return a[t].data.getId(a[t].dataIndex)},function(t){return s[t].data.getId(s[t].dataIndex)}).update(function(t,e){f(n[t],i[e])}).execute()}).execute(),c&&G(e,function(t){var e=t.data.hostModel,t=e&&i.getViewOfSeriesModel(e),n=Gl("update",e,0);t&&e.isAnimationEnabled()&&n&&0<n.duration&&t.group.traverse(function(t){t instanceof as&&!t.animators.length&&t.animateFrom({style:{opacity:0}},n)})})}function gH(t){return t.getModel("universalTransition").get("seriesKey")||t.id}function yH(t){return j(t)?t.sort().join(","):t}function mH(t){if(t.hostModel)return t.hostModel.getModel("universalTransition").get("divideShape")}function vH(t,e){for(var n=0;n<t.length;n++)if(null!=e.seriesIndex&&e.seriesIndex===t[n].seriesIndex||null!=e.seriesId&&e.seriesId===t[n].id)return n}Xv([function(t){t.registerPainter("canvas",N1)}]),Xv([function(t){t.registerPainter("svg",Nx)}]),Xv([function(t){t.registerChartView(yb),t.registerSeriesModel(S_),t.registerLayout(vb("line",!0)),t.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),t=t.getModel("lineStyle").getLineStyle();t&&!t.stroke&&(t.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",t)}}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,bb("line"))},function(t){t.registerChartView(fw),t.registerSeriesModel(Bb),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,Z(kb,"bar")),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,Lb),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,bb("bar")),t.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(e,t){var n=e.componentType||"series";t.eachComponent({mainType:n,query:e},function(t){e.sortInfo&&t.axis.setCategorySortInfo(e.sortInfo)})})},function(t){t.registerChartView(Aw),t.registerSeriesModel(Nw),Bf("pie",t.registerAction),t.registerLayout(Z(xw,"pie")),t.registerProcessor(_w("pie")),t.registerProcessor({seriesType:"pie",reset:function(t,e){var n=t.getData();n.filterSelf(function(t){var e=n.mapDimension("value"),t=n.get(e,t);return!("number"==typeof t&&!isNaN(t)&&t<0)})}})},function(t){Xv(yI),t.registerSeriesModel(Ww),t.registerChartView(Zw),t.registerLayout(vb("scatter"))},function(t){Xv(FI),t.registerChartView(SI),t.registerSeriesModel(MI),t.registerLayout(mI),t.registerProcessor(_w("radar")),t.registerPreprocessor(_I)},function(t){Xv(G2),t.registerChartView(f2),t.registerSeriesModel(g2),t.registerLayout(x2),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,v2),Bf("map",t.registerAction)},function(t){t.registerChartView(sT),t.registerSeriesModel(TT),t.registerLayout(AT),t.registerVisual(kT),(t=t).registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(n,t){t.eachComponent({mainType:"series",subType:"tree",query:n},function(t){var e=n.dataIndex,e=t.getData().tree.getNodeByDataIndex(e);e.isExpand=!e.isExpand})}),t.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(n,t){t.eachComponent({mainType:"series",subType:"tree",query:n},function(t){var e=E2(t.coordinateSystem,n);t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom)})})},function(t){t.registerSeriesModel(ET),t.registerChartView(eC),t.registerVisual(bC),t.registerLayout(EC),RT(t)},function(t){t.registerChartView(YD),t.registerSeriesModel(iA),t.registerProcessor(HC),t.registerVisual(WC),t.registerVisual(YC),t.registerLayout(iD),t.registerLayout(t.PRIORITY.VISUAL.POST_CHART_LAYOUT,hD),t.registerLayout(dD),t.registerCoordinateSystem("graphView",{dimensions:I2.dimensions,create:fD}),t.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},function(){}),t.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},function(){}),t.registerAction(oA,function(n,t){t.eachComponent({mainType:"series",query:n},function(t){var e=E2(t.coordinateSystem,n);t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom)})})},function(t){t.registerChartView(fA),t.registerSeriesModel(gA)},function(t){t.registerChartView(SA),t.registerSeriesModel(MA),t.registerLayout(DA),t.registerProcessor(_w("funnel"))},function(t){Xv(xL),t.registerChartView(zA),t.registerSeriesModel(BA),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,GA)},function(t){t.registerChartView(CL),t.registerSeriesModel(DL),t.registerLayout(kL),t.registerVisual(FL),t.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(e,t){t.eachComponent({mainType:"series",subType:"sankey",query:e},function(t){t.setNodePosition(e.dataIndex,[e.localX,e.localY])})})},function(t){t.registerSeriesModel(XL),t.registerChartView($L),t.registerVisual(tP),t.registerLayout(nP),t.registerTransform(iP)},function(t){t.registerChartView(bP),t.registerSeriesModel(SP),t.registerPreprocessor(MP),t.registerVisual(AP),t.registerLayout(PP)},function(t){t.registerChartView(VP),t.registerSeriesModel(BP),t.registerLayout(vb("effectScatter"))},function(t){t.registerChartView(eO),t.registerSeriesModel(pO),t.registerLayout(tO),t.registerVisual(gO)},function(t){t.registerChartView(bO),t.registerSeriesModel(wO)},function(t){t.registerChartView(qO),t.registerSeriesModel(KO),t.registerLayout(Z(kb,"pictorialBar"))},function(t){t.registerChartView(tR),t.registerSeriesModel(eR),t.registerLayout(iR),t.registerProcessor(_w("themeRiver"))},function(t){t.registerChartView(fR),t.registerSeriesModel(mR),t.registerLayout(Z(xR,"sunburst")),t.registerProcessor(Z(_w,"sunburst")),t.registerVisual(bR),cR(t)},function(t){t.registerChartView(eN),t.registerSeriesModel(TR)}]),Xv(function(t){Xv(yI),Xv(hz)}),Xv(function(t){Xv(hz),KM.registerAxisPointerClass("PolarAxisPointer",yz),t.registerCoordinateSystem("polar",Bz),t.registerComponentModel(mz),t.registerComponentView(a5),hS(t,"angle",Sz,o5),hS(t,"radius",Mz,r5),t.registerComponentView(Zz),t.registerComponentView($z),t.registerLayout(Z(n5,"bar"))}),Xv(G2),Xv(function(t){Xv(hz),KM.registerAxisPointerClass("SingleAxisPointer",N5),t.registerComponentView(z5),t.registerComponentView(f5),t.registerComponentModel(v5),hS(t,"single",v5,v5.defaultOption),t.registerCoordinateSystem("single",T5)}),Xv(xL),Xv(function(t){t.registerComponentModel(G5),t.registerComponentView(H5),t.registerCoordinateSystem("calendar",X5)}),Xv(function(t){t.registerComponentModel(Q5),t.registerComponentView($5),t.registerPreprocessor(Z5)}),Xv(function(t){t.registerComponentModel(EE),t.registerComponentView(HE),OE("saveAsImage",YE),OE("magicType",KE),OE("dataView",r3),OE("dataZoom",k3),OE("restore",c3),Xv(kE)}),Xv(function(t){Xv(hz),t.registerComponentModel(P3),t.registerComponentView(aV),t.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),t.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){})}),Xv(hz),Xv(function(t){t.registerComponentView(CV),t.registerComponentModel(PV),t.registerPreprocessor(lV),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,_V),t.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(t){t.setAreas(e.areas)})}),t.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},function(){}),t.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},function(){}),OE("brush",RV)}),Xv(function(t){t.registerComponentModel(VV),t.registerComponentView(BV)}),Xv(function(t){var e;t.registerComponentModel(qV),t.registerComponentView(oB),t.registerSubTypeDefaulter("timeline",function(){return"slider"}),(e=t).registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(t,e,n){var i=e.getComponent("timeline");return i&&null!=t.currentIndex&&(i.setCurrentIndex(t.currentIndex),!i.get("loop",!0)&&i.isIndexMax()&&i.getPlayState()&&(i.setPlayState(!1),n.dispatchAction({type:"timelinePlayChange",playState:!1,from:t.from}))),e.resetOption("timeline",{replaceMerge:i.get("replaceMerge",!0)}),z({currentIndex:i.option.currentIndex},t)}),e.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(t,e){e=e.getComponent("timeline");e&&null!=t.playState&&e.setPlayState(t.playState)}),t.registerPreprocessor(rB)}),Xv(function(t){t.registerComponentModel(gB),t.registerComponentView(kB),t.registerPreprocessor(function(t){lB(t.series,"markPoint")&&(t.markPoint=t.markPoint||{})})}),Xv(function(t){t.registerComponentModel(RB),t.registerComponentView(HB),t.registerPreprocessor(function(t){lB(t.series,"markLine")&&(t.markLine=t.markLine||{})})}),Xv(function(t){t.registerComponentModel(YB),t.registerComponentView(e4),t.registerPreprocessor(function(t){lB(t.series,"markArea")&&(t.markArea=t.markArea||{})})}),Xv(function(t){Xv(v4),Xv(D4)}),Xv(function(t){Xv(W4),Xv(nF)}),Xv(W4),Xv(nF),Xv(function(t){Xv(HF),Xv(JF)}),Xv(HF),Xv(JF),Xv(function(t){t.registerPreprocessor(nG),t.registerVisual(t.PRIORITY.VISUAL.ARIA,eG)}),Xv(function(t){t.registerTransform(bG),t.registerTransform(wG)}),Xv(function(t){t.registerComponentModel(IG),t.registerComponentView(TG)}),Xv(function(t){t.registerUpdateLifecycle("series:beforeupdate",function(t,e,i){G(No(i.seriesTransition),function(t){G(No(t.to),function(t){for(var e=i.updatedSeries,n=0;n<e.length;n++)(null!=t.seriesIndex&&t.seriesIndex===e[n].seriesIndex||null!=t.seriesId&&t.seriesId===e[n].id)&&(e[n][Pd]=!0)})})}),t.registerUpdateLifecycle("series:transition",function(t,a,s){var e,o,n,r,l,u,h=lH(a);h.oldSeries&&s.updatedSeries&&s.optionChanged&&((n=s.seriesTransition)?G(No(n),function(t){var n,i,e,o,r;n=h,i=s,e=a,o=[],r=[],G(No((t=t).from),function(t){var e=vH(n.oldSeries,t);0<=e&&o.push({data:n.oldData[e],divide:mH(n.oldData[e]),dim:t.dimension})}),G(No(t.to),function(t){var e=vH(i.updatedSeries,t);0<=e&&(e=i.updatedSeries[e].getData(),r.push({data:e,divide:mH(e),dim:t.dimension}))}),0<o.length&&0<r.length&&fH(o,r,e)}):(o=h,n=s,r=yt(),l=yt(),u=yt(),G(o.oldSeries,function(t,e){var n=o.oldData[e],t=gH(t),i=yH(t);l.set(i,n),j(t)&&G(t,function(t){u.set(t,{data:n,key:i})})}),G(n.updatedSeries,function(t){var e,n,i,o;t.isUniversalTransitionEnabled()&&t.isAnimationEnabled()&&(e=t.getData(),i=yH(o=gH(t)),(t=l.get(i))?r.set(i,{oldSeries:[{divide:mH(t),data:t}],newSeries:[{divide:mH(e),data:e}]}):j(o)?(n=[],G(o,function(t){t=l.get(t);t&&n.push({divide:mH(t),data:t})}),n.length&&r.set(i,{oldSeries:n,newSeries:[{data:e,divide:mH(e)}]})):(i=u.get(o))&&((o=r.get(i.key))||(o={oldSeries:[{data:i.data,divide:mH(i.data)}],newSeries:[]},r.set(i.key,o)),o.newSeries.push({data:e,divide:mH(e)})))}),G((e=r).keys(),function(t){t=e.get(t);fH(t.oldSeries,t.newSeries,a)})),G(s.updatedSeries,function(t){t[Pd]&&(t[Pd]=!1)}));for(var i=t.getSeries(),c=h.oldSeries=[],p=h.oldData=[],d=0;d<i.length;d++){var f=i[d].getData();f.count()<sH&&(c.push(i[d]),p.push(f))}})}),Xv(C1);o=Object(r.a)({props:{id:{type:String,default:"myChart"},data:{type:Object,default:null},s:{type:String,default:""}},computed:{result:function(){return JSON.parse(JSON.stringify(this.data))}},watch:{result:function(){this.drawLine()}}})(o=function(t){Object(l.a)(r,t);var o=Object(u.a)(r);function r(){var t;Object(a.a)(this,r);for(var e=arguments.length,n=new Array(e),i=0;i<e;i++)n[i]=arguments[i];return t=o.call.apply(o,[this].concat(n)),Object(h.a)(Object(s.a)(t),"flag",!0),Object(h.a)(Object(s.a)(t),"myChart",null),t}return Object(i.a)(r,[{key:"created",value:function(){var t=this;this.$nextTick(function(){t.myChart||(t.s?t.myChart=Ov(t.$refs[t.id],t.s):t.myChart=Ov(t.$refs[t.id])),t.drawLine()})}},{key:"drawLine",value:function(){this.data&&this.myChart&&this.myChart.setOption(this.data)}}]),r}(o.a))||o,n("5712"),n=n("2877"),o=Object(n.a)(o,function(){var t=this,e=t.$createElement,e=t._self._c||e;return e("div",[t.flag?e("div",{ref:t.id,staticClass:"charts-div"}):t._e()])},[],!1,null,"3505ba68",null);e.a=o.exports},5712:function(t,e,n){"use strict";n("4066")},"7e12":function(t,e,n){"use strict";n("28d5")},"85af":function(t,e,n){"use strict";var i=n("d4ec"),o=n("bee2"),r=n("262e"),a=n("2caf"),s=(n("a9e3"),n("2b0e")),l=n("2fe1"),s=Object(l.a)({props:{bl:{type:Number,default:0},backgroundColor:{type:String,default:"#349FE1"}}})(s=function(t){Object(r.a)(n,t);var e=Object(a.a)(n);function n(){return Object(i.a)(this,n),e.apply(this,arguments)}return Object(o.a)(n,[{key:"created",value:function(){}}]),n}(s.a))||s,n=(n("7e12"),n("2877")),s=Object(n.a)(s,function(){var t=this.$createElement,t=this._self._c||t;return t("div",[t("div",{staticClass:"progress-main"},[t("div",{staticClass:"progress"}),t("div",{staticClass:"progress-bl",style:{width:this.bl+"%",background:this.backgroundColor}})])])},[],!1,null,"18e36f58",null);e.a=s.exports},"89a6":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJQAAAAeCAYAAADKFzdqAAAJNklEQVR4nO2aC5CWZRXH/99eZLkTYQVUiKBGUGYFhjZgWiSDWllKYo0ReOniJDWAlmYpFEMak3SxSQ10k2a0sikSK9CoxEoxRRREuSyiXGK5uOzC7n6c5qHfMx1f3u+y+20z2rz/mXf2e9/ndp7znPM/53meVYYMGTJkyJAhQ4YMGTJk+D9CLkzFzCqd0XskPSSpl/u2StJpneirVlLbq0TF3SW1vArkeM2gqosEnZ8wpoBrO9HPRyU9LOmnFcrzZUm/kTSsgj4ulfR3SdMqlKWzmCRpQoG2UySNLlBWxbzfW8a4/dH5JyUdnyirk/QFSe9338L7x937lejnmPihKxjqJEnrEt+e5Xsh9JA0SFKzK89LmiNpOu8fk/RIwuh7SnpJUhPKWBjEl3SXpF3UCayyknaLqOPRLulJ9/42SadL2iLpj7Q7LGmZpA9LekrSGJgqlFX/Dxl0Mmxfx2IF/FDSDnQ8XNIoSRdJ2kdZjaTfMmexpiuZU9DLE+jb4zC/L5R0Mr+DkS7hdzDkz2FsQa/flnQC3wK+JukxdBTQD3n+g2BQFTzX2NG4vkR/l6a0KRcz6eO4CvqY5WSZ7b6vNrO1ZvaomW113zea2RNm9rSZPWNmfzaz8yvUW9oz38yeRYaI9Wa2wsxuMLMHkSWg1cweR6bpib7WdFAfT5pZf9e+3pW1mVmjmbUk2nzRzLaZ2U4/dk0XeVUSvyzRplHS05K2w0w1zvMPUqcb+ZThdb1gqMhEeTwtsMYfJO2BnaqcB+Z4jPqjCAcXE6YDDjm5Tikg79CUb7ky5tlR3A07heftsOnDsMyfmMNI5Nkt6UHm++vEOAf4u1jSGvSblL2K/tbCcB6zJf1T0nckbaWfE2GxkAb8QNIZko5lzeYQOVZWalCTHGVG/JVJFMMvJN0vaYakN6OsLSnULAytCcV61LhwWMfvv0hqSPSTo49lUPlPCLcRMfd7hE3EAElvSJEjhLxNks4kNL6xAr0VQh9yn7guOfSbwwFD2RDKeri6uQL9LWKzVAq15EHRELdJ+jEGFYz3G679OtZqKu+1hMCAtkoMKrDBzSnf7y6zfRj7GljnihJ1D5MPfMZ9a8QzgiJmotRPFOnjAAoO+cAL7ntI3nvDCFNZgLUF+vgsDHcHRtWVeIukBTBPXJdq5A5znAijHHJlzRj/jZIuT5FlqaTWMjZf3WDBM3Cc4OSfQjd7YKbAVJuR7yUYfpaklyXdSr51QjGD6o23+gQ0hp8w+W+lJN5B+HvLVHIdyuoJo/2L/pMIyfe72InMJkEVSeB1/D4Tb62XtBFlR4SwMRZ2Cob5VVeWY5EW89wOE16dIsepeKxg5s3I1lhkjq8jkQ3z+pGkvUXqtmPotTw7kS1P+2gYhxhzPwa1nrqF+mzEQOsSevFoo27EOByvgRQktH8941yAfFfy7MawBhUzqJmwxpuYiFB+zFn6Fmh3c5HJpSHmOl8iH0hDyGtWUzctJNbiYQH/IOR2d+UtyDshxVOPYcfnQ8ZpbsdUCEv5HnZJ9xSpdy/GHjBe0tlF6gav/4ikn6H3duYc5nYcOUwz73naBGecy44rDVPJ8/q+YheWjm6O/aJxvQhjX40DPSDp6/RbTypSg76PpA5pBnWZS1hVYBHTcD/U2xnU43FVTDzPuN3c+HlngIXwvRLl7Yl3I6Efiof1hEU2JeZ9iEWJ+csWlLlDxfFOV1rOuZDw+BacQyxWDjbPYVTP0PcEvp9fZL4hknyQVGRbgXoPoP+I6GAjJA3mdwj1l9DnXmznqIiSNKj+BfKixcTTNhRd6zqrJlwtTWlXDNV4oljMfinG28QiCw+oLdHnQhinzn07iOIvSJlvmM+57iznA+RZMxJ9BJZ+H+wXDPs8FrWUgYewMQ9dpek1DfdJGugiw4GUOs3oRm5X7BHXpifha3SRg1CR8I91RtUASz/KOIGVNnBONRrDbMTY824nfZSCL0k58V7kMvquxD6S7DEY4+/IzZaRIF8v6QZJZ0n6EJPeVWL8HUzWG14riWUaYm7S6hL1AQUW6lj+7sWYyjnc/C4hI4zzeBn1e5OXnApL5WHpFha7L+vT7HaZaU4WGcacQYYI8pxz0Mi6U9D3UBLzWDYcR499DWO9enFM0YBB7UR/R2zJG1RgjM8nBGtPbBm7Es0w32QY4TF2ElEB61jcmzh5v66MRZxTojwZ8jyCQX8aeYITLXdlda7vFR08KV/dgbp9OCbYzW+xWHHz84IzrK0s+HOJPvq6Y5FqZ3CzOPVPYgrvPny9yF1sbwxoGA62BSNa5c4P96PXI4bnk9TJWKXHUjrpCHJuV1EMp5PoTSTGx7Fjwp8jBA4g+W0pcK/W5pLJuYSwKe45z90NNqW0j/g59WphyZkszCTC6Cjymgs7qI+OYCwOdRdb8V1sjuJxyXrqBLm+ybdkHlfNjkw4bVzjwZT5Z6Br5w1qO8cRY8ijhGGN4Apms2PwqNMj93meoS5LmXh9mcq4StI5CFrF4Gn3aBGXozDhaRezWF9hNyO8NNDqu2GyYHi3sbAzmNjZjBk9Ms/E8m4sn++NJ6S0kQ/sI6EdzLdt/K1lYzL/lWIfKZ/mcr3FiWS2ErwVNh6Cx59I6AuL+H3C/kR3EdufvHMOYXgR77cgX5jH8+6oYIm7jxQ6iWWtCbmHk8utIQ05F51uwliHuFuFraQl//3PEjM7OeV+Z7uZdS/j/mlwgfuhcUXaTKdOuBMbxLd3uLbhPqtHos3tlF1rhe8QO4KR9LO/gj5GdOE93hVu7uH9Tt73mNl9ZrbczBrM7B7u9sZxZxqwijYjnWy38G0X73n6OsCzz8wOuvqnOFlWUN+o+zJ3egEbzGyda3cRd4wByyNDXZXiWfVl/i9QGrP9vsRZzm3E/r+5MZ7iYHEY/3HQnGgzDU+Nye1DMGCpnVYSVYwZQ8UCWLCNcLOHELoBGQfCFn05qOzDmFbiULOjuAPZ4pnSrZw/HU+Ya4INx5NOnETY28tVlgiRCznTmkd/v4KB56HvyK6tsM0CmMqfUwXWu5PxtvK3Fr09z2HtjdRZQp0QLebGf19JnifkUeLGEkoZSI6V3Gmc04ljhAxHI0cSnHSaGrc7LYaqTjhcuehX4uQ/Q4YMGTJkyJAhQ4YMGTK8tiHp32LJJRCXrlXUAAAAAElFTkSuQmCC"},e9c4:function(t,e,n){function s(t,e,n){var i=p(n,e-1),e=p(n,e+1);return c(m,t)&&!c(v,e)||c(v,t)&&!c(m,i)?"\\u"+g(d(t,0),16):t}var i=n("23e7"),o=n("da84"),r=n("d066"),l=n("2ba4"),a=n("e330"),n=n("d039"),u=o.Array,h=r("JSON","stringify"),c=a(/./.exec),p=a("".charAt),d=a("".charCodeAt),f=a("".replace),g=a(1..toString),y=/[\uD800-\uDFFF]/g,m=/^[\uD800-\uDBFF]$/,v=/^[\uDC00-\uDFFF]$/,n=n(function(){return'"\\udf06\\ud834"'!==h("\udf06\ud834")||'"\\udead"'!==h("\udead")});h&&i({target:"JSON",stat:!0,forced:n},{stringify:function(t,e,n){for(var i=0,o=arguments.length,r=u(o);i<o;i++)r[i]=arguments[i];var a=l(h,null,r);return"string"==typeof a?f(a,y,s):a}})}}]);