| | | !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).echarts={})}(this,function(t){"use strict";var a=function(t,e){return(a=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 u(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}a(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var s=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},w=new function(){this.browser=new s,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow="undefined"!=typeof window};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(w.wxa=!0,w.touchEventsSupported=!0):"undefined"==typeof document&&"undefined"!=typeof self?w.worker=!0:"undefined"==typeof navigator||0===navigator.userAgent.indexOf("Node.js")?(w.node=!0,w.svgSupported=!0):(tt=navigator.userAgent,se=(Gt=w).browser,st=tt.match(/Firefox\/([\d.]+)/),_=tt.match(/MSIE\s([\d.]+)/)||tt.match(/Trident\/.+?rv:(([\d.]+))/),k=tt.match(/Edge?\/([\d.]+)/),tt=/micromessenger/i.test(tt),st&&(se.firefox=!0,se.version=st[1]),_&&(se.ie=!0,se.version=_[1]),k&&(se.edge=!0,se.version=k[1],se.newEdge=18<+k[1].split(".")[0]),tt&&(se.weChat=!0),Gt.svgSupported="undefined"!=typeof SVGRect,Gt.touchEventsSupported="ontouchstart"in window&&!se.ie&&!se.edge,Gt.pointerEventsSupported="onpointerdown"in window&&(se.edge||se.ie&&11<=+se.version),Gt.domSupported="undefined"!=typeof document,st=document.documentElement.style,Gt.transform3dSupported=(se.ie&&"transition"in st||se.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in st)&&!("OTransition"in st),Gt.transformSupported=Gt.transform3dSupported||se.ie&&9<=+se.version);var l=12,f="sans-serif",J=l+"px "+f;var h,c,p=function(t){var e={};if("undefined"!=typeof JSON)for(var n=0;n<t.length;n++){var i=String.fromCharCode(n+32),o=(t.charCodeAt(n)-20)/100;e[i]=o}return e}("007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N"),Q={createCanvas:function(){return"undefined"!=typeof document&&document.createElement("canvas")},measureText:function(t,e){if(h||(n=Q.createCanvas(),h=n&&n.getContext("2d")),h)return c!==e&&(c=h.font=e||J),h.measureText(t);t=t||"",e=e||J;var n=/(\d+)px/.exec(e),i=n&&+n[1]||l,o=0;if(0<=e.indexOf("mono"))o=i*t.length;else for(var r=0;r<t.length;r++){var a=p[t[r]];o+=null==a?i:a*i}return{width:o}},loadImage:function(t,e,n){var i=new Image;return i.onload=e,i.onerror=n,i.src=t,i}};function y(t){for(var e in Q)t[e]&&(Q[e]=t[e])}var m=ct(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(t,e){return t["[object "+e+"]"]=!0,t},{}),v=ct(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(t,e){return t["[object "+e+"Array]"]=!0,t},{}),x=Object.prototype.toString,_=Array.prototype,b=_.forEach,M=_.filter,I=_.slice,A=_.map,k=function(){}.constructor,tt=k?k.prototype:null,et="__proto__",it=2311;function ot(){return it++}function rt(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];"undefined"!=typeof console&&console.error.apply(console,t)}function S(t){if(null==t||"object"!=typeof t)return t;var e=t,n=x.call(t);if("[object Array]"===n){if(!kt(t))for(var e=[],i=0,o=t.length;i<o;i++)e[i]=S(t[i])}else if(v[n]){if(!kt(t)){var r=t.constructor;if(r.from)e=r.from(t);else{e=new r(t.length);for(i=0,o=t.length;i<o;i++)e[i]=t[i]}}}else if(!m[n]&&!kt(t)&&!mt(t))for(var a in e={},t)t.hasOwnProperty(a)&&a!==et&&(e[a]=S(t[a]));return e}function d(t,e,n){if(!O(e)||!O(t))return n?S(e):t;for(var i in e){var o,r;e.hasOwnProperty(i)&&i!==et&&(o=t[i],!O(r=e[i])||!O(o)||B(r)||B(o)||mt(r)||mt(o)||ft(r)||ft(o)||kt(r)||kt(o)?!n&&i in t||(t[i]=S(e[i])):d(o,r,n))}return t}function at(t,e){for(var n=t[0],i=1,o=t.length;i<o;i++)n=d(n,t[i],e);return n}function F(t,e){if(Object.assign)Object.assign(t,e);else for(var n in e)e.hasOwnProperty(n)&&n!==et&&(t[n]=e[n]);return t}function z(t,e,n){for(var i=W(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 st=Q.createCanvas;function G(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 lt(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}function ut(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 ht(t){return!!t&&"string"!=typeof t&&"number"==typeof t.length}function nt(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 V(t,e,n){if(!t)return[];if(!e)return Mt(t);if(t.map&&t.map===A)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 ct(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 pt(t,e,n){if(!t)return[];if(!e)return Mt(t);if(t.filter&&t.filter===M)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 dt(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]}function W(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}var T=tt&&D(tt.bind)?tt.call.bind(tt.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(I.call(arguments)))}};function P(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return function(){return t.apply(this,e.concat(I.call(arguments)))}}function B(t){return Array.isArray?Array.isArray(t):"[object Array]"===x.call(t)}function D(t){return"function"==typeof t}function H(t){return"string"==typeof t}function gt(t){return"[object String]"===x.call(t)}function Y(t){return"number"==typeof t}function O(t){var e=typeof t;return"function"==e||!!t&&"object"==e}function ft(t){return!!m[x.call(t)]}function yt(t){return!!v[x.call(t)]}function mt(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function vt(t){return null!=t.colorStops}function xt(t){return null!=t.image}function _t(t){return"[object RegExp]"===x.call(t)}function bt(t){return t!=t}function wt(){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 N(t,e){return null!=t?t:e}function St(t,e,n){return null!=t?t:null!=e?e:n}function Mt(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return I.apply(t,e)}function It(t){var e;return"number"==typeof t?[t,t,t,t]:2===(e=t.length)?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function Tt(t,e){if(!t)throw new Error(e)}function Ct(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var Dt="__ec_primitive__";function At(t){t[Dt]=!0}function kt(t){return t[Dt]}Pt.prototype.delete=function(t){var e=this.has(t);return e&&delete this.data[t],e},Pt.prototype.has=function(t){return this.data.hasOwnProperty(t)},Pt.prototype.get=function(t){return this.data[t]},Pt.prototype.set=function(t,e){return this.data[t]=e,this},Pt.prototype.keys=function(){return W(this.data)},Pt.prototype.forEach=function(t){var e,n=this.data;for(e in n)n.hasOwnProperty(e)&&t(n[e],e)};var Lt=Pt;function Pt(){this.data={}}var Ot="function"==typeof Map;Rt.prototype.hasKey=function(t){return this.data.has(t)},Rt.prototype.get=function(t){return this.data.get(t)},Rt.prototype.set=function(t,e){return this.data.set(t,e),e},Rt.prototype.each=function(n,i){this.data.forEach(function(t,e){n.call(i,t,e)})},Rt.prototype.keys=function(){var t=this.data.keys();return Ot?Array.from(t):t},Rt.prototype.removeKey=function(t){this.data.delete(t)};var Nt=Rt;function Rt(t){var n=B(t),i=(this.data=new(Ot?Map:Lt),this);function e(t,e){n?i.set(t,e):i.set(e,t)}t instanceof Rt?t.each(e):t&&nt(t,e)}function R(t){return new Nt(t)}function Et(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 zt(t,e){var n,t=Object.create?Object.create(t):((n=function(){}).prototype=t,new n);return e&&F(t,e),t}function Vt(t){t=t.style;t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none"}function X(t,e){return t.hasOwnProperty(e)}function Bt(){}var Ft=180/Math.PI,Gt=Object.freeze({__proto__:null,HashMap:Nt,RADIAN_TO_DEGREE:Ft,assert:Tt,bind:T,clone:S,concatArray:Et,createCanvas:st,createHashMap:R,createObject:zt,curry:P,defaults:z,disableUserSelect:Vt,each:nt,eqNaN:bt,extend:F,filter:pt,find:dt,guid:ot,hasOwn:X,indexOf:G,inherits:lt,isArray:B,isArrayLike:ht,isBuiltInObject:ft,isDom:mt,isFunction:D,isGradientObject:vt,isImagePatternObject:xt,isNumber:Y,isObject:O,isPrimitive:kt,isRegExp:_t,isString:H,isStringSafe:gt,isTypedArray:yt,keys:W,logError:rt,map:V,merge:d,mergeAll:at,mixin:ut,noop:Bt,normalizeCssArray:It,reduce:ct,retrieve:wt,retrieve2:N,retrieve3:St,setAsPrimitive:At,slice:Mt,trim:Ct});function Wt(t,e){return[t=null==t?0:t,e=null==e?0:e]}function Ht(t,e){return t[0]=e[0],t[1]=e[1],t}function Yt(t){return[t[0],t[1]]}function Xt(t,e,n){return t[0]=e,t[1]=n,t}function Ut(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function Zt(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function jt(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function qt(t){return Math.sqrt(Kt(t))}function Kt(t){return t[0]*t[0]+t[1]*t[1]}function $t(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function Jt(t,e){var n=qt(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function Qt(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var te=Qt;function ee(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var ne=ee;function ie(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 oe(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 re(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function ae(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}var se=Object.freeze({__proto__:null,add:Ut,applyTransform:oe,clone:Yt,copy:Ht,create:Wt,dist:te,distSquare:ne,distance:Qt,distanceSquare:ee,div:function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},len:qt,lenSquare:Kt,length:qt,lengthSquare:Kt,lerp:ie,max:ae,min:re,mul:function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},normalize:Jt,scale:$t,scaleAndAdd:Zt,set:Xt,sub:jt}),le=function(t,e){this.target=t,this.topTarget=e&&e.topTarget},ue=(he.prototype._dragStart=function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent||e.__hostTarget;e&&((this._draggingTarget=e).dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new le(e,t),"dragstart",t.event))},he.prototype._drag=function(t){var e,n,i,o,r=this._draggingTarget;r&&(e=t.offsetX,n=t.offsetY,i=e-this._x,o=n-this._y,this._x=e,this._y=n,r.drift(i,o,t),this.handler.dispatchToElement(new le(r,t),"drag",t.event),i=this.handler.findHover(e,n,r).target,o=this._dropTarget,r!==(this._dropTarget=i))&&(o&&i!==o&&this.handler.dispatchToElement(new le(o,t),"dragleave",t.event),i)&&i!==o&&this.handler.dispatchToElement(new le(i,t),"dragenter",t.event)},he.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new le(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new le(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},he);function he(t){(this.handler=t).on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}pe.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){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];i&&i.callAtLast?o[t].splice(e,0,r):o[t].push(r)}return this},pe.prototype.isSilent=function(t){var e=this._$handlers;return!e||!e[t]||!e[t].length},pe.prototype.off=function(t,e){var n=this._$handlers;if(n)if(t)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];else this._$handlers={};return this},pe.prototype.trigger=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(this._$handlers){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)}}o&&o.afterTrigger&&o.afterTrigger(t)}return this},pe.prototype.triggerWithContext=function(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];if(this._$handlers){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))}}o&&o.afterTrigger&&o.afterTrigger(t)}return this};var ce=pe;function pe(t){t&&(this._$eventProcessor=t)}var de=Math.log(2);function ge(t,e,n,i,o,r){var a,s=i+"-"+o,l=t.length;if(r.hasOwnProperty(s))return r[s];if(1===e)return a=Math.round(Math.log((1<<l)-1&~o)/de),t[n][a];for(var u=i|1<<n,h=n+1;i&1<<h;)h++;for(var c=0,p=0,d=0;p<l;p++){var g=1<<p;g&o||(c+=(d%2?-1:1)*t[n][p]*ge(t,e-1,h,u,o|g,r),d++)}return r[s]=c}function fe(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=ge(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)*ge(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 ye="___zrEVENTSAVED",me=[];function ve(t,e,n,i,o){if(e.getBoundingClientRect&&w.domSupported&&!xe(e)){var r=e[ye]||(e[ye]={}),e=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?fe(s,a):fe(a,s))}(function(t,e){var n=e.markers;if(!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(e)return e(t,n,i),!0}return!1}function xe(t){return"CANVAS"===t.nodeName.toUpperCase()}var _e=/([&<>"'])/g,be={"&":"&","<":"<",">":">",'"':""","'":"'"};function we(t){return null==t?"":(t+"").replace(_e,function(t,e){return be[e]})}var Se=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Me=[],Ie=w.browser.firefox&&+w.browser.version.split(".")[0]<39;function Te(t,e,n,i){return n=n||{},i?Ce(t,e,n):Ie&&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):Ce(t,e,n),n}function Ce(t,e,n){if(w.domSupported&&t.getBoundingClientRect){var i,o=e.clientX,e=e.clientY;if(xe(t))return i=t.getBoundingClientRect(),n.zrX=o-i.left,void(n.zrY=e-i.top);if(ve(Me,t,o,e))return n.zrX=Me[0],void(n.zrY=Me[1])}n.zrX=n.zrY=0}function De(t){return t||window.event}function Ae(t,e,n){var i;return null==(e=De(e)).zrX&&((i=e.type)&&0<=i.indexOf("touch")?(i=("touchend"!==i?e.targetTouches:e.changedTouches)[0])&&Te(t,i,e,n):(Te(t,e,e,n),i=function(t){var e=t.wheelDelta;if(e)return e;var n=t.deltaX,t=t.deltaY;return null!=n&&null!=t?3*(0!==t?Math.abs(t):Math.abs(n))*(0<t||!(t<0)&&0<n?-1:1):e}(e),e.zrDelta=i?i/120:-(e.detail||0)/3),t=e.button,null==e.which&&void 0!==t&&Se.test(e.type))&&(e.which=1&t?1:2&t?3:4&t?2:0),e}function ke(t,e,n,i){t.addEventListener(e,n,i)}var Le=function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0};function Pe(t){return 2===t.which||3===t.which}Ne.prototype.recognize=function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},Ne.prototype.clear=function(){return this._track.length=0,this},Ne.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)}},Ne.prototype._recognize=function(t){for(var e in Ee)if(Ee.hasOwnProperty(e)){e=Ee[e](this._track,t);if(e)return e}};var Oe=Ne;function Ne(){this._track=[]}function Re(t){var e=t[1][0]-t[0][0],t=t[1][1]-t[0][1];return Math.sqrt(e*e+t*t)}var Ee={pinch:function(t,e){var n,i=t.length;if(i)return n=(t[i-1]||{}).points,(i=(t[i-2]||{}).points||n)&&1<i.length&&n&&1<n.length?(i=Re(n)/Re(i),isFinite(i)||(i=1),e.pinchScale=i,i=[(n[0][0]+n[1][0])/2,(n[0][1]+n[1][1])/2],e.pinchX=i[0],e.pinchY=i[1],{type:"pinch",target:t[0].target,event:e}):void 0}};function ze(){return[1,0,0,1,0,0]}function Ve(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function Be(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 Fe(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],n=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]=n,t}function Ge(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 We(t,e,n,i){void 0===i&&(i=[0,0]);var o=e[0],r=e[2],a=e[4],s=e[1],l=e[3],e=e[5],u=Math.sin(n),n=Math.cos(n);return t[0]=o*n+s*u,t[1]=-o*u+s*n,t[2]=r*n+l*u,t[3]=-r*u+n*l,t[4]=n*(a-i[0])+u*(e-i[1])+i[0],t[5]=n*(e-i[1])-u*(a-i[0])+i[1],t}function He(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 Ye(t,e){var n=e[0],i=e[2],o=e[4],r=e[1],a=e[3],e=e[5],s=n*a-r*i;return s?(t[0]=a*(s=1/s),t[1]=-r*s,t[2]=-i*s,t[3]=n*s,t[4]=(i*e-a*o)*s,t[5]=(r*o-n*e)*s,t):null}function Xe(t){var e=ze();return Be(e,t),e}var Ue=Object.freeze({__proto__:null,clone:Xe,copy:Be,create:ze,identity:Ve,invert:Ye,mul:Fe,rotate:We,scale:He,translate:Ge}),E=(Ze.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},Ze.prototype.clone=function(){return new Ze(this.x,this.y)},Ze.prototype.set=function(t,e){return this.x=t,this.y=e,this},Ze.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},Ze.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},Ze.prototype.scale=function(t){this.x*=t,this.y*=t},Ze.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},Ze.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},Ze.prototype.dot=function(t){return this.x*t.x+this.y*t.y},Ze.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},Ze.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},Ze.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},Ze.prototype.distance=function(t){var e=this.x-t.x,t=this.y-t.y;return Math.sqrt(e*e+t*t)},Ze.prototype.distanceSquare=function(t){var e=this.x-t.x,t=this.y-t.y;return e*e+t*t},Ze.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},Ze.prototype.transform=function(t){var e,n;if(t)return e=this.x,n=this.y,this.x=t[0]*e+t[2]*n+t[4],this.y=t[1]*e+t[3]*n+t[5],this},Ze.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},Ze.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},Ze.set=function(t,e,n){t.x=e,t.y=n},Ze.copy=function(t,e){t.x=e.x,t.y=e.y},Ze.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},Ze.lenSquare=function(t){return t.x*t.x+t.y*t.y},Ze.dot=function(t,e){return t.x*e.x+t.y*e.y},Ze.add=function(t,e,n){t.x=e.x+n.x,t.y=e.y+n.y},Ze.sub=function(t,e,n){t.x=e.x-n.x,t.y=e.y-n.y},Ze.scale=function(t,e,n){t.x=e.x*n,t.y=e.y*n},Ze.scaleAndAdd=function(t,e,n,i){t.x=e.x+n.x*i,t.y=e.y+n.y*i},Ze.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},Ze);function Ze(t,e){this.x=t||0,this.y=e||0}var je=Math.min,qe=Math.max,Ke=new E,$e=new E,Je=new E,Qe=new E,tn=new E,en=new E,U=(nn.prototype.union=function(t){var e=je(t.x,this.x),n=je(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=qe(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=qe(t.y+t.height,this.y+this.height)-n:this.height=t.height,this.x=e,this.y=n},nn.prototype.applyTransform=function(t){nn.applyTransform(this,this,t)},nn.prototype.calculateTransform=function(t){var e=t.width/this.width,n=t.height/this.height,i=ze();return Ge(i,i,[-this.x,-this.y]),He(i,i,[e,n]),Ge(i,i,[t.x,t.y]),i},nn.prototype.intersect=function(t,e){if(!t)return!1;t instanceof nn||(t=nn.create(t));var n,i,o,r,a,s,l,u,h=this,c=h.x,p=h.x+h.width,d=h.y,h=h.y+h.height,g=t.x,f=t.x+t.width,y=t.y,t=t.y+t.height,m=!(p<g||f<c||h<y||t<d);return e&&(n=1/0,i=0,o=Math.abs(p-g),r=Math.abs(f-c),a=Math.abs(h-y),s=Math.abs(t-d),l=Math.min(o,r),u=Math.min(a,s),p<g||f<c?i<l&&(i=l,o<r?E.set(en,-o,0):E.set(en,r,0)):l<n&&(n=l,o<r?E.set(tn,o,0):E.set(tn,-r,0)),h<y||t<d?i<u&&(i=u,a<s?E.set(en,0,-a):E.set(en,0,s)):l<n&&(n=l,a<s?E.set(tn,0,a):E.set(tn,0,-s))),e&&E.copy(e,m?tn:en),m},nn.prototype.contain=function(t,e){var n=this;return t>=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},nn.prototype.clone=function(){return new nn(this.x,this.y,this.width,this.height)},nn.prototype.copy=function(t){nn.copy(this,t)},nn.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},nn.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},nn.prototype.isZero=function(){return 0===this.width||0===this.height},nn.create=function(t){return new nn(t.x,t.y,t.width,t.height)},nn.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},nn.applyTransform=function(t,e,n){var i,o,r,a;n?n[1]<1e-5&&-1e-5<n[1]&&n[2]<1e-5&&-1e-5<n[2]?(i=n[0],o=n[3],r=n[4],a=n[5],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),t.height<0&&(t.y+=t.height,t.height=-t.height)):(Ke.x=Je.x=e.x,Ke.y=Qe.y=e.y,$e.x=Qe.x=e.x+e.width,$e.y=Je.y=e.y+e.height,Ke.transform(n),Qe.transform(n),$e.transform(n),Je.transform(n),t.x=je(Ke.x,$e.x,Je.x,Qe.x),t.y=je(Ke.y,$e.y,Je.y,Qe.y),r=qe(Ke.x,$e.x,Je.x,Qe.x),a=qe(Ke.y,$e.y,Je.y,Qe.y),t.width=r-t.x,t.height=a-t.y):t!==e&&nn.copy(t,e)},nn);function nn(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}var on="silent";function rn(){Le(this.event)}u(ln,an=ce),ln.prototype.dispose=function(){},ln.prototype.setCursor=function(){};var an,sn=ln;function ln(){var t=null!==an&&an.apply(this,arguments)||this;return t.handler=null,t}var un,hn=function(t,e){this.x=t,this.y=e},cn=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],pn=new U(0,0,0,0),dn=(u(gn,un=ce),gn.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(nt(cn,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},gn.prototype.mousemove=function(t){var e=t.zrX,n=t.zrY,i=yn(this,e,n),o=this._hovered,r=o.target,i=(r&&!r.__zr&&(r=(o=this.findHover(o.x,o.y)).target),this._hovered=i?new hn(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)},gn.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})},gn.prototype.resize=function(){this._hovered=new hn(0,0)},gn.prototype.dispatch=function(t,e){t=this[t];t&&t.call(this,e)},gn.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},gn.prototype.setCursorStyle=function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},gn.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:rn};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)}))}},gn.prototype.findHover=function(t,e,n){var i=this.storage.getDisplayList(),o=new hn(t,e);if(fn(i,o,t,e,n),this._pointerSize&&!o.target){for(var r=[],a=this._pointerSize,s=a/2,l=new U(t-s,e-s,a,a),u=i.length-1;0<=u;u--){var h=i[u];h===n||h.ignore||h.ignoreCoarsePointer||h.parent&&h.parent.ignoreCoarsePointer||(pn.copy(h.getBoundingRect()),h.transform&&pn.applyTransform(h.transform),pn.intersect(l)&&r.push(h))}if(r.length)for(var c=Math.PI/12,p=2*Math.PI,d=0;d<s;d+=4)for(var g=0;g<p;g+=c)if(fn(r,o,t+d*Math.cos(g),e+d*Math.sin(g),n),o.target)return o}return o},gn.prototype.processGesture=function(t,e){this._gestureMgr||(this._gestureMgr=new Oe);var n=this._gestureMgr,i=("start"===e&&n.clear(),n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom));"end"===e&&n.clear(),i&&(e=i.type,t.gestureEvent=e,(n=new hn).target=i.target,this.dispatchToElement(n,e,i.event))},gn);function gn(t,e,n,i,o){var r=un.call(this)||this;return r._hovered=new hn(0,0),r.storage=t,r.painter=e,r.painterRoot=i,r._pointerSize=o,n=n||new sn,r.proxy=null,r.setHandlerProxy(n),r._draggingMgr=new ue(r),r}function fn(t,e,n,i,o){for(var r=t.length-1;0<=r;r--){var a=t[r],s=void 0;if(a!==o&&!a.ignore&&(s=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||on}return!1}(a,n,i))&&(e.topTarget||(e.topTarget=a),s!==on)){e.target=a;break}}}function yn(t,e,n){t=t.painter;return e<0||e>t.getWidth()||n<0||n>t.getHeight()}nt(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(a){dn.prototype[a]=function(t){var e,n,i=t.zrX,o=t.zrY,r=yn(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<te(this._downPoint,[t.zrX,t.zrY]))return;this._downPoint=null}this.dispatchToElement(e,a,t)}});var mn=32,vn=7;function xn(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++;var r=t,a=e,s=o;for(s--;a<s;){var l=r[a];r[a++]=r[s],r[s--]=l}}else for(;o<n&&0<=i(t[o],t[o-1]);)o++;return o-e}function _n(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 bn(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 wn(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 Sn(k,L){var P,O,N=vn,R=0,E=[];function e(t){var e=P[t],n=O[t],i=P[t+1],o=O[t+1],t=(O[t]=n+o,t===R-3&&(P[t+1]=P[t+2],O[t+1]=O[t+2]),R--,wn(k[i],k,e,n,0,L));if(e+=t,0!=(n-=t)&&0!==(o=bn(k[e+n-1],k,i,o,o-1,L)))if(n<=o){var r=e,a=n,t=i,s=o,l=0;for(l=0;l<a;l++)E[l]=k[r+l];var u=0,h=t,c=r;if(k[c++]=k[h++],0==--s)for(l=0;l<a;l++)k[c+l]=E[u+l];else if(1===a){for(l=0;l<s;l++)k[c+l]=k[h+l];k[c+s]=E[u]}else{for(var p,d,g,f=N;;){d=p=0,g=!1;do{if(L(k[h],E[u])<0){if(k[c++]=k[h++],d++,(p=0)==--s){g=!0;break}}else if(k[c++]=E[u++],p++,d=0,1==--a){g=!0;break}}while((p|d)<f);if(g)break;do{if(0!==(p=wn(k[h],E,u,a,0,L))){for(l=0;l<p;l++)k[c+l]=E[u+l];if(c+=p,u+=p,(a-=p)<=1){g=!0;break}}if(k[c++]=k[h++],0==--s){g=!0;break}if(0!==(d=bn(E[u],k,h,s,0,L))){for(l=0;l<d;l++)k[c+l]=k[h+l];if(c+=d,h+=d,0===(s-=d)){g=!0;break}}if(k[c++]=E[u++],1==--a){g=!0;break}}while(f--,vn<=p||vn<=d);if(g)break;f<0&&(f=0),f+=2}if((N=f)<1&&(N=1),1===a){for(l=0;l<s;l++)k[c+l]=k[h+l];k[c+s]=E[u]}else{if(0===a)throw new Error;for(l=0;l<a;l++)k[c+l]=E[u+l]}}}else{var y=e,m=n,v=i,x=o,_=0;for(_=0;_<x;_++)E[_]=k[v+_];var b=y+m-1,w=x-1,S=v+x-1,M=0,I=0;if(k[S--]=k[b--],0==--m)for(M=S-(x-1),_=0;_<x;_++)k[M+_]=E[_];else if(1===x){for(I=(S-=m)+1,M=(b-=m)+1,_=m-1;0<=_;_--)k[I+_]=k[M+_];k[S]=E[w]}else{for(var T=N;;){var C=0,D=0,A=!1;do{if(L(E[w],k[b])<0){if(k[S--]=k[b--],C++,(D=0)==--m){A=!0;break}}else if(k[S--]=E[w--],D++,C=0,1==--x){A=!0;break}}while((C|D)<T);if(A)break;do{if(0!==(C=m-wn(E[w],k,y,m,m-1,L))){for(m-=C,I=(S-=C)+1,M=(b-=C)+1,_=C-1;0<=_;_--)k[I+_]=k[M+_];if(0===m){A=!0;break}}if(k[S--]=E[w--],1==--x){A=!0;break}if(0!==(D=x-bn(k[b],E,0,x,x-1,L))){for(x-=D,I=(S-=D)+1,M=(w-=D)+1,_=0;_<D;_++)k[I+_]=E[M+_];if(x<=1){A=!0;break}}if(k[S--]=k[b--],0==--m){A=!0;break}}while(T--,vn<=C||vn<=D);if(A)break;T<0&&(T=0),T+=2}if((N=T)<1&&(N=1),1===x){for(I=(S-=m)+1,M=(b-=m)+1,_=m-1;0<=_;_--)k[I+_]=k[M+_];k[S]=E[w]}else{if(0===x)throw new Error;for(M=S-(x-1),_=0;_<x;_++)k[M+_]=E[_]}}}}return P=[],O=[],{mergeRuns:function(){for(;1<R;){var t=R-2;if(1<=t&&O[t-1]<=O[t]+O[t+1]||2<=t&&O[t-2]<=O[t]+O[t-1])O[t-1]<O[t+1]&&t--;else if(O[t]>O[t+1])break;e(t)}},forceMergeRuns:function(){for(;1<R;){var t=R-2;0<t&&O[t-1]<O[t+1]&&t--,e(t)}},pushRun:function(t,e){P[R]=t,O[R]=e,R+=1}}}function Mn(t,e,n,i){var o=(i=i||t.length)-(n=n||0);if(!(o<2)){var r=0;if(o<mn)_n(t,n,i,n+(r=xn(t,n,i,e)),e);else{var a,s=Sn(t,e),l=function(t){for(var e=0;mn<=t;)e|=1&t,t>>=1;return t+e}(o);do{}while((r=xn(t,n,i,e))<l&&(_n(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 In=1,Tn=4,Cn=!1;function Dn(){Cn||(Cn=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function An(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}Ln.prototype.traverse=function(t,e){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,e)},Ln.prototype.getDisplayList=function(t,e){e=e||!1;var n=this._displayList;return!t&&n.length||this.updateDisplayList(e),n},Ln.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,Mn(n,An)},Ln.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|=In),this._updateAndAddDisplayable(l,e,n)}t.__dirty=0}else{i=t;e&&e.length?i.__clipPaths=e:i.__clipPaths&&0<i.__clipPaths.length&&(i.__clipPaths=[]),isNaN(i.z)&&(Dn(),i.z=0),isNaN(i.z2)&&(Dn(),i.z2=0),isNaN(i.zlevel)&&(Dn(),i.zlevel=0),this._displayList[this._displayListLen++]=i}i=t.getDecalElement&&t.getDecalElement(),i=(i&&this._updateAndAddDisplayable(i,e,n),t.getTextGuideLine()),i=(i&&this._updateAndAddDisplayable(i,e,n),t.getTextContent());i&&this._updateAndAddDisplayable(i,e,n)}},Ln.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},Ln.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=G(this._roots,t);0<=i&&this._roots.splice(i,1)}},Ln.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},Ln.prototype.getRoots=function(){return this._roots},Ln.prototype.dispose=function(){this._displayList=null,this._roots=null};var kn=Ln;function Ln(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=An}var Pn=w.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)},On={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-On.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*On.bounceIn(2*t):.5*On.bounceOut(2*t-1)+.5}},Nn=Math.pow,Rn=Math.sqrt,En=1e-8,zn=1e-4,Vn=Rn(3),Bn=1/3,Fn=Wt(),Gn=Wt(),Wn=Wt();function Hn(t){return-En<t&&t<En}function Yn(t){return En<t||t<-En}function Xn(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 Un(t,e,n,i,o){var r=1-o;return 3*(((e-t)*r+2*(n-e)*o)*r+(i-n)*o*o)}function Zn(t,e,n,i,o,r){var a,s,i=i+3*(e-n)-t,n=3*(n-2*e+t),e=3*(e-t),t=t-o,o=n*n-3*i*e,l=n*e-9*i*t,t=e*e-3*n*t,u=0;return Hn(o)&&Hn(l)?Hn(n)?r[0]=0:0<=(a=-e/n)&&a<=1&&(r[u++]=a):Hn(e=l*l-4*o*t)?(s=-(t=l/o)/2,0<=(a=-n/i+t)&&a<=1&&(r[u++]=a),0<=s&&s<=1&&(r[u++]=s)):0<e?(e=o*n+1.5*i*(-l-(t=Rn(e))),0<=(a=(-n-((t=(t=o*n+1.5*i*(-l+t))<0?-Nn(-t,Bn):Nn(t,Bn))+(e=e<0?-Nn(-e,Bn):Nn(e,Bn))))/(3*i))&&a<=1&&(r[u++]=a)):(t=(2*o*n-3*i*l)/(2*Rn(o*o*o)),e=Math.acos(t)/3,a=(-n-2*(l=Rn(o))*(t=Math.cos(e)))/(3*i),s=(-n+l*(t+Vn*Math.sin(e)))/(3*i),o=(-n+l*(t-Vn*Math.sin(e)))/(3*i),0<=a&&a<=1&&(r[u++]=a),0<=s&&s<=1&&(r[u++]=s),0<=o&&o<=1&&(r[u++]=o)),u}function jn(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 Hn(i)?Yn(a)&&0<=(r=-n/a)&&r<=1&&(o[e++]=r):Hn(t=a*a-4*i*n)?o[0]=-a/(2*i):0<t&&(t=(-a-(n=Rn(t)))/(2*i),0<=(r=(-a+n)/(2*i))&&r<=1&&(o[e++]=r),0<=t)&&t<=1&&(o[e++]=t),e}function qn(t,e,n,i,o,r){var a=(e-t)*o+t,e=(n-e)*o+e,n=(i-n)*o+n,s=(e-a)*o+a,e=(n-e)*o+e,o=(e-s)*o+s;r[0]=t,r[1]=a,r[2]=s,r[3]=o,r[4]=o,r[5]=e,r[6]=n,r[7]=i}function Kn(t,e,n,i,o,r,a,s,l,u,h){var c,p,d,g,f=.005,y=1/0;Fn[0]=l,Fn[1]=u;for(var m=0;m<1;m+=.05)Gn[0]=Xn(t,n,o,a,m),Gn[1]=Xn(e,i,r,s,m),(d=ne(Fn,Gn))<y&&(c=m,y=d);for(var y=1/0,v=0;v<32&&!(f<zn);v++)p=c+f,Gn[0]=Xn(t,n,o,a,g=c-f),Gn[1]=Xn(e,i,r,s,g),d=ne(Gn,Fn),0<=g&&d<y?(c=g,y=d):(Wn[0]=Xn(t,n,o,a,p),Wn[1]=Xn(e,i,r,s,p),g=ne(Wn,Fn),p<=1&&g<y?(c=p,y=g):f*=.5);return h&&(h[0]=Xn(t,n,o,a,c),h[1]=Xn(e,i,r,s,c)),Rn(y)}function $n(t,e,n,i){var o=1-i;return o*(o*t+2*i*e)+i*i*n}function Jn(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function Qn(t,e,n){n=t+n-2*e;return 0==n?.5:(t-e)/n}function ti(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 ei(t,e,n,i,o,r,a,s,l){var u,h=.005,c=1/0;Fn[0]=a,Fn[1]=s;for(var p=0;p<1;p+=.05)Gn[0]=$n(t,n,o,p),Gn[1]=$n(e,i,r,p),(y=ne(Fn,Gn))<c&&(u=p,c=y);for(var c=1/0,d=0;d<32&&!(h<zn);d++){var g=u-h,f=u+h,y=(Gn[0]=$n(t,n,o,g),Gn[1]=$n(e,i,r,g),ne(Gn,Fn));0<=g&&y<c?(u=g,c=y):(Wn[0]=$n(t,n,o,f),Wn[1]=$n(e,i,r,f),g=ne(Wn,Fn),f<=1&&g<c?(u=f,c=g):h*=.5)}return l&&(l[0]=$n(t,n,o,u),l[1]=$n(e,i,r,u)),Rn(c)}var ni=/cubic-bezier\(([0-9,\.e ]+)\)/;function ii(t){t=t&&ni.exec(t);if(t){var e,t=t[1].split(","),n=+Ct(t[0]),i=+Ct(t[1]),o=+Ct(t[2]),r=+Ct(t[3]);if(!isNaN(n+i+o+r))return e=[],function(t){return t<=0?0:1<=t?1:Zn(0,n,o,1,t,e)&&Xn(0,i,r,1,e[0])}}}ri.prototype.step=function(t,e){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),!this._paused){var n=this._life,i=t-this._startTime-this._pausedTime,o=i/n,r=(o<0&&(o=0),o=Math.min(o,1),this.easingFunc),r=r?r(o):o;if(this.onframe(r),1===o){if(!this.loop)return!0;this._startTime=t-i%n,this._pausedTime=0,this.onrestart()}return!1}this._pausedTime+=e},ri.prototype.pause=function(){this._paused=!0},ri.prototype.resume=function(){this._paused=!1},ri.prototype.setEasing=function(t){this.easing=t,this.easingFunc=D(t)?t:On[t]||ii(t)};var oi=ri;function ri(t){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=t.loop||!1,this.onframe=t.onframe||Bt,this.ondestroy=t.ondestroy||Bt,this.onrestart=t.onrestart||Bt,t.easing&&this.setEasing(t.easing)}var ai=function(t){this.value=t},si=(li.prototype.insert=function(t){t=new ai(t);return this.insertEntry(t),t},li.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++},li.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--},li.prototype.len=function(){return this._len},li.prototype.clear=function(){this.head=this.tail=null,this._len=0},li);function li(){this._len=0}hi.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 ai(e),n.key=t,o.insertEntry(n),r[t]=n),a},hi.prototype.get=function(t){var t=this._map[t],e=this._list;if(null!=t)return t!==e.tail&&(e.remove(t),e.insertEntry(t)),t.value},hi.prototype.clear=function(){this._list.clear(),this._map={}},hi.prototype.len=function(){return this._list.len()};var ui=hi;function hi(t){this._list=new si,this._maxSize=10,this._map={},this._maxSize=t}var ci={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 pi(t){return(t=Math.round(t))<0?0:255<t?255:t}function di(t){return t<0?0:1<t?1:t}function gi(t){return t.length&&"%"===t.charAt(t.length-1)?pi(parseFloat(t)/100*255):pi(parseInt(t,10))}function fi(t){return t.length&&"%"===t.charAt(t.length-1)?di(parseFloat(t)/100):di(parseFloat(t))}function yi(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 mi(t,e,n){return t+(e-t)*n}function vi(t,e,n,i,o){return t[0]=e,t[1]=n,t[2]=i,t[3]=o,t}function xi(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var _i=new ui(20),bi=null;function wi(t,e){bi&&xi(bi,e),bi=_i.put(t,bi||e.slice())}function Si(t,e){if(t){e=e||[];var n=_i.get(t);if(n)return xi(e,n);n=(t+="").replace(/ /g,"").toLowerCase();if(n in ci)return xi(e,ci[n]),wi(t,e),e;var i=n.length;if("#"===n.charAt(0))return 4===i||5===i?0<=(o=parseInt(n.slice(1,4),16))&&o<=4095?(vi(e,(3840&o)>>4|(3840&o)>>8,240&o|(240&o)>>4,15&o|(15&o)<<4,5===i?parseInt(n.slice(4),16)/15:1),wi(t,e),e):void vi(e,0,0,0,1):7===i||9===i?0<=(o=parseInt(n.slice(1,7),16))&&o<=16777215?(vi(e,(16711680&o)>>16,(65280&o)>>8,255&o,9===i?parseInt(n.slice(7),16)/255:1),wi(t,e),e):void vi(e,0,0,0,1):void 0;var o=n.indexOf("("),r=n.indexOf(")");if(-1!==o&&r+1===i){var i=n.substr(0,o),a=n.substr(o+1,r-(o+1)).split(","),s=1;switch(i){case"rgba":if(4!==a.length)return 3===a.length?vi(e,+a[0],+a[1],+a[2],1):vi(e,0,0,0,1);s=fi(a.pop());case"rgb":return 3<=a.length?(vi(e,gi(a[0]),gi(a[1]),gi(a[2]),3===a.length?s:fi(a[3])),wi(t,e),e):void vi(e,0,0,0,1);case"hsla":return 4!==a.length?void vi(e,0,0,0,1):(a[3]=fi(a[3]),Mi(a,e),wi(t,e),e);case"hsl":return 3!==a.length?void vi(e,0,0,0,1):(Mi(a,e),wi(t,e),e);default:return}}vi(e,0,0,0,1)}}function Mi(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=fi(t[1]),o=fi(t[2]),i=o<=.5?o*(i+1):o+i-o*i,o=2*o-i;return vi(e=e||[],pi(255*yi(o,i,n+1/3)),pi(255*yi(o,i,n)),pi(255*yi(o,i,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Ii(t,e){var n=Si(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 Li(n,4===n.length?"rgba":"rgb")}}function Ti(t,e,n){var i,o,r;if(e&&e.length&&0<=t&&t<=1)return n=n||[],t=t*(e.length-1),i=Math.floor(t),r=Math.ceil(t),o=e[i],e=e[r],n[0]=pi(mi(o[0],e[0],r=t-i)),n[1]=pi(mi(o[1],e[1],r)),n[2]=pi(mi(o[2],e[2],r)),n[3]=di(mi(o[3],e[3],r)),n}var Ci=Ti;function Di(t,e,n){var i,o,r,a;if(e&&e.length&&0<=t&&t<=1)return t=t*(e.length-1),i=Math.floor(t),o=Math.ceil(t),a=Si(e[i]),e=Si(e[o]),a=Li([pi(mi(a[0],e[0],r=t-i)),pi(mi(a[1],e[1],r)),pi(mi(a[2],e[2],r)),di(mi(a[3],e[3],r))],"rgba"),n?{color:a,leftIndex:i,rightIndex:o,value:t}:a}var e=Di;function Ai(t,e,n,i){var o=Si(t);if(t)return o=function(t){var e,n,i,o,r,a,s,l,u,h;if(t)return h=t[0]/255,e=t[1]/255,n=t[2]/255,s=Math.min(h,e,n),o=((i=Math.max(h,e,n))+s)/2,0==(u=i-s)?a=r=0:(a=o<.5?u/(i+s):u/(2-i-s),s=((i-h)/6+u/2)/u,l=((i-e)/6+u/2)/u,u=((i-n)/6+u/2)/u,h===i?r=u-l:e===i?r=1/3+s-u:n===i&&(r=2/3+l-s),r<0&&(r+=1),1<r&&--r),h=[360*r,a,o],null!=t[3]&&h.push(t[3]),h}(o),null!=e&&(o[0]=(t=e,(t=Math.round(t))<0?0:360<t?360:t)),null!=n&&(o[1]=fi(n)),null!=i&&(o[2]=fi(i)),Li(Mi(o),"rgba")}function ki(t,e){t=Si(t);if(t&&null!=e)return t[3]=di(e),Li(t,"rgba")}function Li(t,e){var n;if(t&&t.length)return n=t[0]+","+t[1]+","+t[2],"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}function Pi(t,e){t=Si(t);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}var Oi=new ui(100);function Ni(t){var e;return H(t)?((e=Oi.get(t))||(e=Ii(t,-.1),Oi.put(t,e)),e):vt(t)?((e=F({},t)).colorStops=V(t.colorStops,function(t){return{offset:t.offset,color:Ii(t.color,-.1)}}),e):t}var Ci=Object.freeze({__proto__:null,fastLerp:Ti,fastMapToColor:Ci,lerp:Di,lift:Ii,liftColor:Ni,lum:Pi,mapToColor:e,modifyAlpha:ki,modifyHSL:Ai,parse:Si,random:function(){return Li([Math.round(255*Math.random()),Math.round(255*Math.random()),Math.round(255*Math.random())],"rgb")},stringify:Li,toHex:function(t){if(t=Si(t))return((1<<24)+(t[0]<<16)+(t[1]<<8)+ +t[2]).toString(16).slice(1)}}),Ri=Math.round;function Ei(t){var e,n;return t&&"transparent"!==t?"string"==typeof t&&-1<t.indexOf("rgba")&&(n=Si(t))&&(t="rgb("+n[0]+","+n[1]+","+n[2]+")",e=n[3]):t="none",{color:t,opacity:null==e?1:e}}function zi(t){return t<1e-4&&-1e-4<t}function Vi(t){return Ri(1e3*t)/1e3}function Bi(t){return Ri(1e4*t)/1e4}var Fi={left:"start",right:"end",center:"middle",middle:"middle"};function Gi(t){return t&&!!t.image}function Wi(t){return Gi(t)||(t=t)&&!!t.svgElement}function Hi(t){return"linear"===t.type}function Yi(t){return"radial"===t.type}function Xi(t){return t&&("linear"===t.type||"radial"===t.type)}function Ui(t){return"url(#"+t+")"}function Zi(t){t=t.getGlobalScale(),t=Math.max(t[0],t[1]);return Math.max(Math.ceil(Math.log(t)/Math.log(10)),1)}function ji(t){var e=t.x||0,n=t.y||0,i=(t.rotation||0)*Ft,o=N(t.scaleX,1),r=N(t.scaleY,1),a=t.skewX||0,t=t.skewY||0,s=[];return(e||n)&&s.push("translate("+e+"px,"+n+"px)"),i&&s.push("rotate("+i+")"),1===o&&1===r||s.push("scale("+o+","+r+")"),(a||t)&&s.push("skew("+Ri(a*Ft)+"deg, "+Ri(t*Ft)+"deg)"),s.join(" ")}var qi=w.hasGlobalWindow&&D(window.btoa)?function(t){return window.btoa(unescape(encodeURIComponent(t)))}:"undefined"!=typeof Buffer?function(t){return Buffer.from(t).toString("base64")}:function(t){return null},Ki=Array.prototype.slice;function $i(t,e,n){return(e-t)*n+t}function Ji(t,e,n,i){for(var o=e.length,r=0;r<o;r++)t[r]=$i(e[r],n[r],i);return t}function Qi(t,e,n,i){for(var o=e.length,r=0;r<o;r++)t[r]=e[r]+n[r]*i;return t}function to(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 eo(t){if(ht(t)){var e=t.length;if(ht(t[0])){for(var n=[],i=0;i<e;i++)n.push(Ki.call(t[i]));return n}return Ki.call(t)}return t}function no(t){return t[0]=Math.floor(t[0])||0,t[1]=Math.floor(t[1])||0,t[2]=Math.floor(t[2])||0,t[3]=null==t[3]?1:t[3],"rgba("+t.join(",")+")"}function io(t){return 4===t||5===t}function oo(t){return 1===t||2===t}var ro=[0,0,0,0],ao=(so.prototype.isFinished=function(){return this._finished},so.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},so.prototype.needsAnimate=function(){return 1<=this.keyframes.length},so.prototype.getAdditiveTrack=function(){return this._additiveTrack},so.prototype.addKeyframe=function(t,e,n){this._needsSort=!0;var i,o=this.keyframes,r=o.length,a=!1,s=6,l=e,u=(ht(e)?(1==(s=i=ht((i=e)&&i[0])?2:1)&&!Y(e[0])||2==i&&!Y(e[0][0]))&&(a=!0):Y(e)&&!bt(e)?s=0:H(e)?isNaN(+e)?(i=Si(e))&&(l=i,s=3):s=0:vt(e)&&((u=F({},l)).colorStops=V(e.colorStops,function(t){return{offset:t.offset,color:Si(t.color)}}),Hi(e)?s=4:Yi(e)&&(s=5),l=u),0===r?this.valType=s:s===this.valType&&6!==s||(a=!0),this.discrete=this.discrete||a,{time:t,value:l,rawValue:e,percent:0});return n&&(u.easing=n,u.easingFunc=D(n)?n:On[n]||ii(n)),o.push(u),u},so.prototype.prepare=function(t,e){for(var n=this.keyframes,i=(this._needsSort&&n.sort(function(t,e){return t.time-e.time}),this.valType),o=n.length,r=n[o-1],a=this.discrete,s=oo(i),l=io(i),u=0;u<o;u++){var h=n[u],c=h.value,p=r.value;if(h.percent=h.time/t,!a)if(s&&u!==o-1){_=x=v=m=y=f=g=d=h=void 0;var d=p,g=i,f=h=c,y=d;if(f.push&&y.push){var h=f.length,m=y.length;if(h!==m)if(m<h)f.length=m;else for(var v=h;v<m;v++)f.push(1===g?y[v]:Ki.call(y[v]));for(var x=f[0]&&f[0].length,v=0;v<f.length;v++)if(1===g)isNaN(f[v])&&(f[v]=y[v]);else for(var _=0;_<x;_++)isNaN(f[v][_])&&(f[v][_]=y[v][_])}}else if(l){I=M=S=w=b=h=d=void 0;for(var d=c.colorStops,h=p.colorStops,b=d.length,w=h.length,S=w<b?h:d,h=Math.min(b,w),M=S[h-1]||{color:[0,0,0,0],offset:0},I=h;I<Math.max(b,w);I++)S.push({offset:M.offset,color:M.color.slice()})}}if(!a&&5!==i&&e&&this.needsAnimate()&&e.needsAnimate()&&i===e.valType&&!e._finished){this._additiveTrack=e;for(var T=n[0].value,u=0;u<o;u++)0===i?n[u].additiveValue=n[u].value-T:3===i?n[u].additiveValue=Qi([],n[u].value,T,-1):oo(i)&&(n[u].additiveValue=(1===i?Qi:to)([],n[u].value,T,-1))}},so.prototype.step=function(t,e){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n,i,o,r,a=null!=this._additiveTrack,s=a?"additiveValue":"value",l=this.valType,u=this.keyframes,h=u.length,c=this.propName,p=3===l,d=this._lastFr,g=Math.min;if(1===h)n=i=u[0];else{if(e<0)f=0;else if(e<this._lastFrP){for(var f=g(d+1,h-1);0<=f&&!(u[f].percent<=e);f--);f=g(f,h-2)}else{for(f=d;f<h&&!(u[f].percent>e);f++);f=g(f-1,h-2)}i=u[f+1],n=u[f]}n&&i&&(this._lastFr=f,this._lastFrP=e,d=i.percent-n.percent,o=0==d?1:g((e-n.percent)/d,1),i.easingFunc&&(o=i.easingFunc(o)),g=a?this._additiveValue:p?ro:t[c],(oo(l)||p)&&(g=g||(this._additiveValue=[])),this.discrete?t[c]=(o<1?n:i).rawValue:oo(l)?(1===l?Ji: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]=$i(e[a][s],n[a][s],i)}})(g,n[s],i[s],o):io(l)?(d=n[s],r=i[s],t[c]={type:(l=4===l)?"linear":"radial",x:$i(d.x,r.x,o),y:$i(d.y,r.y,o),colorStops:V(d.colorStops,function(t,e){e=r.colorStops[e];return{offset:$i(t.offset,e.offset,o),color:no(Ji([],t.color,e.color,o))}}),global:r.global},l?(t[c].x2=$i(d.x2,r.x2,o),t[c].y2=$i(d.y2,r.y2,o)):t[c].r=$i(d.r,r.r,o)):p?(Ji(g,n[s],i[s],o),a||(t[c]=no(g))):(l=$i(n[s],i[s],o),a?this._additiveValue=l:t[c]=l),a)&&this._addToTarget(t)}},so.prototype._addToTarget=function(t){var e=this.valType,n=this.propName,i=this._additiveValue;0===e?t[n]=t[n]+i:3===e?(Si(t[n],ro),Qi(ro,ro,i,1),t[n]=no(ro)):1===e?Qi(t[n],t[n],i,1):2===e&&to(t[n],t[n],i,1)},so);function so(t){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=t}uo.prototype.getMaxTime=function(){return this._maxTime},uo.prototype.getDelay=function(){return this._delay},uo.prototype.getLoop=function(){return this._loop},uo.prototype.getTarget=function(){return this._target},uo.prototype.changeTarget=function(t){this._target=t},uo.prototype.when=function(t,e,n){return this.whenWithKeys(t,e,W(e),n)},uo.prototype.whenWithKeys=function(t,e,n,i){for(var o=this._tracks,r=0;r<n.length;r++){var a=n[r];if(!(l=o[a])){var s,l=o[a]=new ao(a),u=void 0,h=this._getAdditiveTrack(a);if(h?(u=(s=(s=h.keyframes)[s.length-1])&&s.value,3===h.valType&&(u=u&&no(u))):u=this._target[a],null==u)continue;0<t&&l.addKeyframe(0,eo(u),i),this._trackKeys.push(a)}l.addKeyframe(t,eo(e[a]),i)}return this._maxTime=Math.max(this._maxTime,t),this},uo.prototype.pause=function(){this._clip.pause(),this._paused=!0},uo.prototype.resume=function(){this._clip.resume(),this._paused=!1},uo.prototype.isPaused=function(){return!!this._paused},uo.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},uo.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)},uo.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)},uo.prototype._setTracksFinished=function(){for(var t=this._tracks,e=this._trackKeys,n=0;n<e.length;n++)t[e[n]].setFinished()},uo.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},uo.prototype.start=function(t){if(!(0<this._started)){this._started=1;for(var e,r=this,a=[],n=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var o=this._trackKeys[i],s=this._tracks[o],o=this._getAdditiveTrack(o),l=s.keyframes,u=l.length;s.prepare(n,o),s.needsAnimate()&&(!this._allowDiscrete&&s.discrete?((o=l[u-1])&&(r._target[s.propName]=o.rawValue),s.setFinished()):a.push(s))}return a.length||this._force?(e=new oi({life:n,loop:this._loop,delay:this._delay||0,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&&e.setEasing(t)):this._doneCallback(),this}},uo.prototype.stop=function(t){var e;this._clip&&(e=this._clip,t&&e.onframe(1),this._abortedCallback())},uo.prototype.delay=function(t){return this._delay=t,this},uo.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},uo.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},uo.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},uo.prototype.getClip=function(){return this._clip},uo.prototype.getTrack=function(t){return this._tracks[t]},uo.prototype.getTracks=function(){var e=this;return V(this._trackKeys,function(t){return e._tracks[t]})},uo.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&&!r.isFinished()&&(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},uo.prototype.saveTo=function(t,e,n){if(t){e=e||this._trackKeys;for(var i=0;i<e.length;i++){var o=e[i],r=this._tracks[o];r&&!r.isFinished()&&(r=(r=r.keyframes)[n?0:r.length-1])&&(t[o]=eo(r.rawValue))}}},uo.prototype.__changeFinalValue=function(t,e){e=e||W(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(this._maxTime,r.getAdditiveTrack()))}};var lo=uo;function uo(t,e,n,i){this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,(this._loop=e)&&i?rt("Can' use additive animation on looped animation."):(this._additiveAnimators=i,this._allowDiscrete=n)}function ho(){return(new Date).getTime()}u(go,co=ce),go.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?((this._tail.next=t).prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},go.prototype.addAnimator=function(t){t.animation=this;t=t.getClip();t&&this.addClip(t)},go.prototype.removeClip=function(t){var e,n;t.animation&&(e=t.prev,n=t.next,e?e.next=n:this._head=n,n?n.prev=e:this._tail=e,t.next=t.prev=t.animation=null)},go.prototype.removeAnimator=function(t){var e=t.getClip();e&&this.removeClip(e),t.animation=null},go.prototype.update=function(t){for(var e=ho()-this._pausedTime,n=e-this._time,i=this._head;i;)var o=i.next,i=(i.step(e,n)&&(i.ondestroy(),this.removeClip(i)),o);this._time=e,t||(this.trigger("frame",n),this.stage.update&&this.stage.update())},go.prototype._startLoop=function(){var e=this;this._running=!0,Pn(function t(){e._running&&(Pn(t),e._paused||e.update())})},go.prototype.start=function(){this._running||(this._time=ho(),this._pausedTime=0,this._startLoop())},go.prototype.stop=function(){this._running=!1},go.prototype.pause=function(){this._paused||(this._pauseStart=ho(),this._paused=!0)},go.prototype.resume=function(){this._paused&&(this._pausedTime+=ho()-this._pauseStart,this._paused=!1)},go.prototype.clear=function(){for(var t=this._head;t;){var e=t.next;t.prev=t.next=t.animation=null,t=e}this._head=this._tail=null},go.prototype.isFinished=function(){return null==this._head},go.prototype.animate=function(t,e){e=e||{},this.start();t=new lo(t,e.loop);return this.addAnimator(t),t};var co,po=go;function go(t){var e=co.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}var fo,yo=w.domSupported,mo=(fo={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:e=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:V(e,function(t){var e=t.replace("mouse","pointer");return fo.hasOwnProperty(e)?e:t})}),vo=["mousemove","mouseup"],xo=["pointermove","pointerup"],_o=!1;function bo(t){t=t.pointerType;return"pen"===t||"touch"===t}function wo(t){t&&(t.zrByTouch=!0)}function So(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 Mo=function(t,e){this.stopPropagation=Bt,this.stopImmediatePropagation=Bt,this.preventDefault=Bt,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY},Io={mousedown:function(t){t=Ae(this.dom,t),this.__mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=Ae(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=Ae(this.dom,t),this.__togglePointerCapture(!1),this.trigger("mouseup",t)},mouseout:function(t){So(this,(t=Ae(this.dom,t)).toElement||t.relatedTarget)||(this.__pointerCapturing&&(t.zrEventControl="no_globalout"),this.trigger("mouseout",t))},wheel:function(t){_o=!0,t=Ae(this.dom,t),this.trigger("mousewheel",t)},mousewheel:function(t){_o||(t=Ae(this.dom,t),this.trigger("mousewheel",t))},touchstart:function(t){wo(t=Ae(this.dom,t)),this.__lastTouchMoment=new Date,this.handler.processGesture(t,"start"),Io.mousemove.call(this,t),Io.mousedown.call(this,t)},touchmove:function(t){wo(t=Ae(this.dom,t)),this.handler.processGesture(t,"change"),Io.mousemove.call(this,t)},touchend:function(t){wo(t=Ae(this.dom,t)),this.handler.processGesture(t,"end"),Io.mouseup.call(this,t),+new Date-+this.__lastTouchMoment<300&&Io.click.call(this,t)},pointerdown:function(t){Io.mousedown.call(this,t)},pointermove:function(t){bo(t)||Io.mousemove.call(this,t)},pointerup:function(t){Io.mouseup.call(this,t)},pointerout:function(t){bo(t)||Io.mouseout.call(this,t)}},To=(nt(["click","dblclick","contextmenu"],function(e){Io[e]=function(t){t=Ae(this.dom,t),this.trigger(e,t)}}),{pointermove:function(t){bo(t)||To.mousemove.call(this,t)},pointerup:function(t){To.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 Co(i,o){var r=o.domHandlers;w.pointerEventsSupported?nt(mo.pointer,function(e){Ao(o,e,function(t){r[e].call(i,t)})}):(w.touchEventsSupported&&nt(mo.touch,function(n){Ao(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)})}),nt(mo.mouse,function(e){Ao(o,e,function(t){t=De(t),o.touching||r[e].call(i,t)})}))}function Do(i,o){function t(n){Ao(o,n,function(t){var e;t=De(t),So(i,t.target)||(e=t,t=Ae(i.dom,new Mo(i,e),!0),o.domHandlers[n].call(i,t))},{capture:!0})}w.pointerEventsSupported?nt(xo,t):w.touchEventsSupported||nt(vo,t)}function Ao(t,e,n,i){t.mounted[e]=n,t.listenerOpts[e]=i,ke(t.domTarget,e,n,i)}function ko(t){var e,n,i,o,r,a=t.mounted;for(e in a)a.hasOwnProperty(e)&&(n=t.domTarget,o=a[i=e],r=t.listenerOpts[e],n.removeEventListener(i,o,r));t.mounted={}}var Lo,Po=function(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e},Oo=(u(No,Lo=ce),No.prototype.dispose=function(){ko(this._localHandlerScope),yo&&ko(this._globalHandlerScope)},No.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},No.prototype.__togglePointerCapture=function(t){var e;this.__mayPointerCapture=null,yo&&+this.__pointerCapturing^+t&&(this.__pointerCapturing=t,e=this._globalHandlerScope,t?Do(this,e):ko(e))},No);function No(t,e){var n=Lo.call(this)||this;return n.__pointerCapturing=!1,n.dom=t,n.painterRoot=e,n._localHandlerScope=new Po(t,Io),yo&&(n._globalHandlerScope=new Po(document,To)),Co(n,n._localHandlerScope),n}var e=1,Ro=e=w.hasGlobalWindow?Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1):e,Eo="#333",zo="#ccc",Vo=Ve;function Bo(t){return 5e-5<t||t<-5e-5}var Fo=[],Go=[],Wo=ze(),Ho=Math.abs,Yo=(Xo.prototype.getLocalTransform=function(t){return Xo.getLocalTransform(this,t)},Xo.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},Xo.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},Xo.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},Xo.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},Xo.prototype.needLocalTransform=function(){return Bo(this.rotation)||Bo(this.x)||Bo(this.y)||Bo(this.scaleX-1)||Bo(this.scaleY-1)||Bo(this.skewX)||Bo(this.skewY)},Xo.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),n=this.transform;e||t?(n=n||ze(),e?this.getLocalTransform(n):Vo(n),t&&(e?Fe(n,t,n):Be(n,t)),this.transform=n,this._resolveGlobalScaleRatio(n)):n&&(Vo(n),this.invTransform=null)},Xo.prototype._resolveGlobalScaleRatio=function(t){var e,n,i=this.globalScaleRatio;null!=i&&1!==i&&(this.getGlobalScale(Fo),n=((Fo[1]-(n=Fo[1]<0?-1:1))*i+n)/Fo[1]||0,t[0]*=i=((Fo[0]-(e=Fo[0]<0?-1:1))*i+e)/Fo[0]||0,t[1]*=i,t[2]*=n,t[3]*=n),this.invTransform=this.invTransform||ze(),Ye(this.invTransform,t)},Xo.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},Xo.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)},Xo.prototype.decomposeTransform=function(){var t,e,n;this.transform&&(e=this.parent,t=this.transform,e&&e.transform&&(e.invTransform=e.invTransform||ze(),Fe(Go,e.invTransform,t),t=Go),e=this.originX,n=this.originY,(e||n)&&(Wo[4]=e,Wo[5]=n,Fe(Go,t,Wo),Go[4]-=e,Go[5]-=n,t=Go),this.setLocalTransform(t))},Xo.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},Xo.prototype.transformCoordToLocal=function(t,e){t=[t,e],e=this.invTransform;return e&&oe(t,t,e),t},Xo.prototype.transformCoordToGlobal=function(t,e){t=[t,e],e=this.transform;return e&&oe(t,t,e),t},Xo.prototype.getLineScale=function(){var t=this.transform;return t&&1e-10<Ho(t[0]-1)&&1e-10<Ho(t[3]-1)?Math.sqrt(Ho(t[0]*t[3]-t[2]*t[1])):1},Xo.prototype.copyTransform=function(t){Zo(this,t)},Xo.getLocalTransform=function(t,e){e=e||[];var n=t.originX||0,i=t.originY||0,o=t.scaleX,r=t.scaleY,a=t.anchorX,s=t.anchorY,l=t.rotation||0,u=t.x,h=t.y,c=t.skewX?Math.tan(t.skewX):0,t=t.skewY?Math.tan(-t.skewY):0;return n||i||a||s?(e[4]=-(a=n+a)*o-c*(s=i+s)*r,e[5]=-s*r-t*a*o):e[4]=e[5]=0,e[0]=o,e[3]=r,e[1]=t*o,e[2]=c*r,l&&We(e,e,l),e[4]+=n+u,e[5]+=i+h,e},Xo.initDefaultProps=((e=Xo.prototype).scaleX=e.scaleY=e.globalScaleRatio=1,void(e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0)),Xo);function Xo(){}var Uo=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function Zo(t,e){for(var n=0;n<Uo.length;n++){var i=Uo[n];t[i]=e[i]}}var jo={};function qo(t,e){var n=jo[e=e||J],i=(n=n||(jo[e]=new ui(500))).get(t);return null==i&&(i=Q.measureText(t,e).width,n.put(t,i)),i}function Ko(t,e,n,i){t=qo(t,e),e=tr(e),n=Jo(0,t,n),i=Qo(0,e,i);return new U(n,i,t,e)}function $o(t,e,n,i){var o=((t||"")+"").split("\n");if(1===o.length)return Ko(o[0],e,n,i);for(var r=new U(0,0,0,0),a=0;a<o.length;a++){var s=Ko(o[a],e,n,i);0===a?r.copy(s):r.union(s)}return r}function Jo(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function Qo(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function tr(t){return qo("å½",t)}function er(t,e){return"string"==typeof t?0<=t.lastIndexOf("%")?parseFloat(t)/100*e:parseFloat(t):t}function nr(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+=er(i[0],n.width),u+=er(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 ir,or="__zr_normal__",rr=Uo.concat(["ignore"]),ar=ct(Uo,function(t,e){return t[e]=!0,t},{ignore:!1}),sr={},lr=new U(0,0,0,0),e=(n.prototype._init=function(t){this.attr(t)},n.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()},n.prototype.beforeUpdate=function(){},n.prototype.afterUpdate=function(){},n.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},n.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={}),l=(t=this.textConfig).local,i=n=void 0,o=!1,(e=c.innerTransformable).parent=l?this:null,h=!1,e.copyTransform(c),null!=t.position&&(u=lr,t.layoutRect?u.copy(t.layoutRect):u.copy(this.getBoundingRect()),l||u.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(sr,t,u):nr(sr,t,u),e.x=sr.x,e.y=sr.y,n=sr.align,i=sr.verticalAlign,r=t.origin)&&null!=t.rotation&&(s=a=void 0,s="center"===r?(a=.5*u.width,.5*u.height):(a=er(r[0],u.width),er(r[1],u.height)),h=!0,e.originX=-e.x+a+(l?0:u.x),e.originY=-e.y+s+(l?0:u.y)),null!=t.rotation&&(e.rotation=t.rotation),(r=t.offset)&&(e.x+=r[0],e.y+=r[1],h||(e.originX=-r[0],e.originY=-r[1])),a=null==t.inside?"string"==typeof t.position&&0<=t.position.indexOf("inside"):t.inside,s=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),h=u=l=void 0,a&&this.canBeInsideText()?(l=t.insideFill,u=t.insideStroke,null!=l&&"auto"!==l||(l=this.getInsideTextFill()),null!=u&&"auto"!==u||(u=this.getInsideTextStroke(l),h=!0)):(l=t.outsideFill,u=t.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&&n===s.align&&i===s.verticalAlign||(o=!0,s.fill=l,s.stroke=u,s.autoStroke=h,s.align=n,s.verticalAlign=i,c.setDefaultTextStyle(s)),c.__dirty|=In,o&&c.dirtyStyle(!0))},n.prototype.canBeInsideText=function(){return!0},n.prototype.getInsideTextFill=function(){return"#fff"},n.prototype.getInsideTextStroke=function(t){return"#000"},n.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?zo:Eo},n.prototype.getOutsideStroke=function(t){for(var e=this.__zr&&this.__zr.getBackgroundColor(),n="string"==typeof e&&Si(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,Li(n,"rgba")},n.prototype.traverse=function(t,e){},n.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||{},F(this.extra,e)):this[t]=e},n.prototype.hide=function(){this.ignore=!0,this.markRedraw()},n.prototype.show=function(){this.ignore=!1,this.markRedraw()},n.prototype.attr=function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(O(t))for(var n=W(t),i=0;i<n.length;i++){var o=n[i];this.attrKV(o,t[o])}return this.markRedraw(),this},n.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;i.getLoop()||o&&o!==or||(o=(o=i.targetName)?e[o]:e,i.saveTo(o))}},n.prototype._innerSaveToNormal=function(t){var e=(e=this._normalState)||(this._normalState={});t.textConfig&&!e.textConfig&&(e.textConfig=this.textConfig),this._savePrimaryToNormal(t,e,rr)},n.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])}},n.prototype.hasState=function(){return 0<this.currentStates.length},n.prototype.getState=function(t){return this.states[t]},n.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},n.prototype.clearStates=function(t){this.useState(or,!1,t)},n.prototype.useState=function(t,e,n,i){var o=t===or,r=this.hasState();if(r||!o){var a,r=this.currentStates,s=this.stateTransition;if(!(0<=G(r,t))||!e&&1!==r.length){if((a=(a=this.stateProxy&&!o?this.stateProxy(t):a)||this.states&&this.states[t])||o)return o||this.saveCurrentToNormalState(a),(r=!!(a&&a.hoverLayer||i))&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,a,this._normalState,e,!n&&!this.__inHover&&s&&0<s.duration,s),i=this._textContent,s=this._textGuide,i&&i.useState(t,e,n,r),s&&s.useState(t,e,n,r),o?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!r&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~In),a;rt("State "+t+" not exists.")}}},n.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],h=!!(h&&h.hoverLayer||n),n=(h&&this._toggleHoverLayerFlag(!0),this._mergeStates(i)),c=this.stateTransition,n=(this.saveCurrentToNormalState(n),this._applyStateObj(t.join(","),n,this._normalState,!1,!e&&!this.__inHover&&c&&0<c.duration,c),this._textContent),c=this._textGuide;n&&n.useStates(t,e,h),c&&c.useStates(t,e,h),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!h&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~In)}}else this.clearStates()},n.prototype.isSilent=function(){for(var t=this.silent,e=this.parent;!t&&e;){if(e.silent){t=!0;break}e=e.parent}return t},n.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var e=this.animators[t];e.targetName&&e.changeTarget(this[e.targetName])}},n.prototype.removeState=function(t){var e,t=G(this.currentStates,t);0<=t&&((e=this.currentStates.slice()).splice(t,1),this.useStates(e))},n.prototype.replaceState=function(t,e,n){var i=this.currentStates.slice(),t=G(i,t),o=0<=G(i,e);0<=t?o?i.splice(t,1):i[t]=e:n&&!o&&i.push(e),this.useStates(i)},n.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},n.prototype._mergeStates=function(t){for(var e,n={},i=0;i<t.length;i++){var o=t[i];F(n,o),o.textConfig&&F(e=e||{},o.textConfig)}return e&&(n.textConfig=e),n},n.prototype._applyStateObj=function(t,e,n,i,o,r){for(var a=!(e&&i),s=(e&&e.textConfig?(this.textConfig=F({},(i?this:n).textConfig),F(this.textConfig,e.textConfig)):a&&n.textConfig&&(this.textConfig=n.textConfig),{}),l=!1,u=0;u<rr.length;u++){var h=rr[u],c=o&&ar[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.getLoop()||p.__changeFinalValue(d?(e||n)[d]:e||n)}l&&this._transitionState(t,s,r)},n.prototype._attachComponent=function(t){var e;t.__zr&&!t.__hostTarget||t!==this&&((e=this.__zr)&&t.addSelfToZr(e),t.__zr=e,t.__hostTarget=this)},n.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},n.prototype.getClipPath=function(){return this._clipPath},n.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},n.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},n.prototype.getTextContent=function(){return this._textContent},n.prototype.setTextContent=function(t){var e=this._textContent;e!==t&&(e&&e!==t&&this.removeTextContent(),t.innerTransformable=new Yo,this._attachComponent(t),this._textContent=t,this.markRedraw())},n.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),F(this.textConfig,t),this.markRedraw()},n.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},n.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},n.prototype.getTextGuideLine=function(){return this._textGuide},n.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},n.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},n.prototype.markRedraw=function(){this.__dirty|=In;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},n.prototype.dirty=function(){this.markRedraw()},n.prototype._toggleHoverLayerFlag=function(t){this.__inHover=t;var e=this._textContent,n=this._textGuide;e&&(e.__inHover=t),n&&(n.__inHover=t)},n.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)}},n.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)}},n.prototype.animate=function(t,e,n){var i=t?this[t]:this,i=new lo(i,e,n);return t&&(i.targetName=t),this.addAnimator(i,t),i},n.prototype.addAnimator=function(n,t){var e=this.__zr,i=this;n.during(function(){i.updateDuringAnimation(t)}).done(function(){var t=i.animators,e=G(t,n);0<=e&&t.splice(e,1)}),this.animators.push(n),e&&e.animation.addAnimator(n),e&&e.wakeUp()},n.prototype.updateDuringAnimation=function(t){this.markRedraw()},n.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},n.prototype.animateTo=function(t,e,n){hr(this,t,e,n)},n.prototype.animateFrom=function(t,e,n){hr(this,t,e,n,!0)},n.prototype._transitionState=function(t,e,n,i){for(var o=hr(this,e,n,i),r=0;r<o.length;r++)o[r].__fromStateTransition=t},n.prototype.getBoundingRect=function(){return null},n.prototype.getPaintRect=function(){return null},n.initDefaultProps=((ir=n.prototype).type="element",ir.name="",ir.ignore=ir.silent=ir.isGroup=ir.draggable=ir.dragging=ir.ignoreClip=ir.__inHover=!1,ir.__dirty=In,void(Object.defineProperty&&(ur("position","_legacyPos","x","y"),ur("scale","_legacyScale","scaleX","scaleY"),ur("origin","_legacyOrigin","originX","originY")))),n);function n(t){this.id=it++,this.animators=[],this.currentStates=[],this.states={},this._init(t)}function ur(t,e,n,i){function o(e,t){Object.defineProperty(t,0,{get:function(){return e[n]},set:function(t){e[n]=t}}),Object.defineProperty(t,1,{get:function(){return e[i]},set:function(t){e[i]=t}})}Object.defineProperty(ir,t,{get:function(){var t;return this[e]||(t=this[e]=[],o(this,t)),this[e]},set:function(t){this[n]=t[0],this[i]=t[1],this[e]=t,o(this,t)}})}function hr(t,e,n,i,o){function r(){u=!0,--l<=0&&(u?h&&h():c&&c())}function a(){--l<=0&&(u?h&&h():c&&c())}var s=[],l=(!function t(e,n,i,o,r,a,s,l){var u=W(o);var h=r.duration;var c=r.delay;var p=r.additive;var d=r.setToFinal;var g=!O(a);var f=e.animators;var y=[];for(var m=0;m<u.length;m++){var v=u[m],x=o[v];null!=x&&null!=i[v]&&(g||a[v])?!O(x)||ht(x)||vt(x)?y.push(v):n?l||(i[v]=x,e.updateDuringAnimation(n)):t(e,v,i[v],x,r,a&&a[v],s,l):l||(i[v]=x,e.updateDuringAnimation(n),y.push(v))}var _=y.length;if(!p&&_)for(var b,w=0;w<f.length;w++)(S=f[w]).targetName===n&&S.stopTracks(y)&&(b=G(f,S),f.splice(b,1));r.force||(y=pt(y,function(t){return!dr(o[t],i[t])}),_=y.length);if(0<_||r.force&&!s.length){var S,M=void 0,I=void 0,T=void 0;if(l){I={},d&&(M={});for(w=0;w<_;w++){v=y[w];I[v]=i[v],d?M[v]=o[v]:i[v]=o[v]}}else if(d){T={};for(w=0;w<_;w++){v=y[w];T[v]=eo(i[v]),pr(i,o,v)}}(S=new lo(i,!1,!1,p?pt(f,function(t){return t.targetName===n}):null)).targetName=n,r.scope&&(S.scope=r.scope),d&&M&&S.whenWithKeys(0,M,y),T&&S.whenWithKeys(0,T,y),S.whenWithKeys(null==h?500:h,l?I:o,y).delay(c||0),e.addAnimator(S,n),s.push(S)}}(t,"",t,e,n=n||{},i,s,o),s.length),u=!1,h=n.done,c=n.aborted;l||h&&h(),0<s.length&&n.during&&s[0].during(function(t,e){n.during(e)});for(var p=0;p<s.length;p++){var d=s[p];d.done(r),d.aborted(a),n.force&&d.duration(n.duration),d.start(n.easing)}return s}function cr(t,e,n){for(var i=0;i<n;i++)t[i]=e[i]}function pr(t,e,n){if(ht(e[n]))if(ht(t[n])||(t[n]=[]),yt(e[n])){var i=e[n].length;t[n].length!==i&&(t[n]=new e[n].constructor(i),cr(t[n],e[n],i))}else{var o=e[n],r=t[n],a=o.length;if(ht(o[0]))for(var s=o[0].length,l=0;l<a;l++)r[l]?cr(r[l],o[l],s):r[l]=Array.prototype.slice.call(o[l]);else cr(r,o,a);r.length=o.length}else t[n]=e[n]}function dr(t,e){return t===e||ht(t)&&ht(e)&&function(t,e){var n=t.length;if(n!==e.length)return!1;for(var i=0;i<n;i++)if(t[i]!==e[i])return!1;return!0}(t,e)}ut(e,ce),ut(e,Yo);u(fr,gr=e),fr.prototype.childrenRef=function(){return this._children},fr.prototype.children=function(){return this._children.slice()},fr.prototype.childAt=function(t){return this._children[t]},fr.prototype.childOfName=function(t){for(var e=this._children,n=0;n<e.length;n++)if(e[n].name===t)return e[n]},fr.prototype.childCount=function(){return this._children.length},fr.prototype.add=function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},fr.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},fr.prototype.replace=function(t,e){t=G(this._children,t);return 0<=t&&this.replaceAt(e,t),this},fr.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,(n=this.__zr)&&i.removeSelfFromZr(n),this._doAdd(t)),this},fr.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()},fr.prototype.remove=function(t){var e=this.__zr,n=this._children,i=G(n,t);return i<0||(n.splice(i,1),t.parent=null,e&&t.removeSelfFromZr(e),e&&e.refresh()),this},fr.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},fr.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},fr.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},fr.prototype.addSelfToZr=function(t){gr.prototype.addSelfToZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].addSelfToZr(t)},fr.prototype.removeSelfFromZr=function(t){gr.prototype.removeSelfFromZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].removeSelfFromZr(t)},fr.prototype.getBoundingRect=function(t){for(var e=new U(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))?(U.applyTransform(e,a,s),(o=o||e.clone()).union(e)):(o=o||a.clone()).union(a))}return o||e};var gr,Z=fr;function fr(t){var e=gr.call(this)||this;return e.isGroup=!0,e._children=[],e.attr(t),e}Z.prototype.type="group";var yr={},mr={};_r.prototype.add=function(t){!this._disposed&&t&&(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},_r.prototype.remove=function(t){!this._disposed&&t&&(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},_r.prototype.configLayer=function(t,e){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,e),this.refresh())},_r.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=function(t){if(t){if("string"==typeof t)return Pi(t,1)<.4;if(t.colorStops){for(var e=t.colorStops,n=0,i=e.length,o=0;o<i;o++)n+=Pi(e[o].color,1);return(n/=i)<.4}}return!1}(t))},_r.prototype.getBackgroundColor=function(){return this._backgroundColor},_r.prototype.setDarkMode=function(t){this._darkMode=t},_r.prototype.isDarkMode=function(){return this._darkMode},_r.prototype.refreshImmediately=function(t){this._disposed||(t||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},_r.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},_r.prototype.flush=function(){this._disposed||this._flush(!1)},_r.prototype._flush=function(t){var e,n=ho(),t=(this._needsRefresh&&(e=!0,this.refreshImmediately(t)),this._needsRefreshHover&&(e=!0,this.refreshHoverImmediately()),ho());e?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:t-n})):0<this._sleepAfterStill&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill)&&this.animation.stop()},_r.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},_r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},_r.prototype.refreshHover=function(){this._needsRefreshHover=!0},_r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&"canvas"===this.painter.getType()&&this.painter.refreshHover())},_r.prototype.resize=function(t){this._disposed||(this.painter.resize((t=t||{}).width,t.height),this.handler.resize())},_r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},_r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},_r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},_r.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},_r.prototype.findHover=function(t,e){if(!this._disposed)return this.handler.findHover(t,e)},_r.prototype.on=function(t,e,n){return this._disposed||this.handler.on(t,e,n),this},_r.prototype.off=function(t,e){this._disposed||this.handler.off(t,e)},_r.prototype.trigger=function(t,e){this._disposed||this.handler.trigger(t,e)},_r.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),e=0;e<t.length;e++)t[e]instanceof Z&&t[e].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},_r.prototype.dispose=function(){var t;this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,t=this.id,delete mr[t])};var vr,xr=_r;function _r(t,e,n){var i,o=this,r=(this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=e,this.id=t,new kn),a=n.renderer||"canvas",a=(yr[a]||(a=W(yr)[0]),n.useDirtyRect=null!=n.useDirtyRect&&n.useDirtyRect,new yr[a](e,r,n,t)),e=n.ssr||a.ssrOnly,t=(this.storage=r,this.painter=a,w.node||w.worker||e?null:new Oo(a.getViewportRoot(),a.root)),s=n.useCoarsePointer;(null==s||"auto"===s?w.touchEventsSupported:!!s)&&(i=N(n.pointerSize,44)),this.handler=new dn(r,a,t,a.root,i),this.animation=new po({stage:{update:e?null:function(){return o._flush(!0)}}}),e||this.animation.start()}function br(t,e){t=new xr(it++,t,e);return mr[t.id]=t}function wr(t,e){yr[t]=e}function Sr(t){if("function"==typeof vr)return vr(t)}function Mr(t){vr=t}var Ir=Object.freeze({__proto__:null,dispose:function(t){t.dispose()},disposeAll:function(){for(var t in mr)mr.hasOwnProperty(t)&&mr[t].dispose();mr={}},getElementSSRData:Sr,getInstance:function(t){return mr[t]},init:br,registerPainter:wr,registerSSRDataGetter:Mr,version:"5.5.0"}),Tr=20;function Cr(t,e,n,i){var o=e[0],e=e[1],r=n[0],n=n[1],a=e-o,s=n-r;if(0==a)return 0==s?r:(r+n)/2;if(i)if(0<a){if(t<=o)return r;if(e<=t)return n}else{if(o<=t)return r;if(t<=e)return n}else{if(t===o)return r;if(t===e)return n}return(t-o)/a*s+r}function j(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 H(t)?t.replace(/^\s+|\s+$/g,"").match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function Dr(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),Tr),t=(+t).toFixed(e),n?t:+t}function Ar(t){return t.sort(function(t,e){return t-e}),t}function kr(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 Lr(t)}function Lr(t){var t=t.toString().toLowerCase(),e=t.indexOf("e"),n=0<e?+t.slice(e+1):0,e=0<e?e:t.length,t=t.indexOf(".");return Math.max(0,(t<0?0:e-1-t)-n)}function Pr(t,e){var n=Math.log,i=Math.LN10,t=Math.floor(n(t[1]-t[0])/i),n=Math.round(n(Math.abs(e[1]-e[0]))/i),e=Math.min(Math.max(-t+n,0),20);return isFinite(e)?e:20}function Or(t,e){var n=ct(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===n)return[];for(var i=Math.pow(10,e),e=V(t,function(t){return(isNaN(t)?0:t)/n*i*100}),o=100*i,r=V(e,function(t){return Math.floor(t)}),a=ct(r,function(t,e){return t+e},0),s=V(e,function(t,e){return t-r[e]});a<o;){for(var l=Number.NEGATIVE_INFINITY,u=null,h=0,c=s.length;h<c;++h)s[h]>l&&(l=s[h],u=h);++r[u],s[u]=0,++a}return V(r,function(t){return t/i})}var Nr=9007199254740991;function Rr(t){var e=2*Math.PI;return(t%e+e)%e}function Er(t){return-1e-4<t&&t<1e-4}var zr=/^(?:(\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 Vr(t){var e,n;return t instanceof Date?t:H(t)?(e=zr.exec(t))?e[8]?(n=+e[4]||0,"Z"!==e[8].toUpperCase()&&(n-=+e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,n,+(e[5]||0),+e[6]||0,e[7]?+e[7].substring(0,3):0))):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):new Date(NaN):null==t?new Date(NaN):new Date(Math.round(t))}function Br(t){return Math.pow(10,Fr(t))}function Fr(t){var e;return 0===t?0:(e=Math.floor(Math.log(t)/Math.LN10),10<=t/Math.pow(10,e)&&e++,e)}function Gr(t,e){var n=Fr(t),i=Math.pow(10,n),o=t/i,e=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;return t=e*i,-20<=n?+t.toFixed(n<0?-n:0):t}function Wr(t,e){var e=(t.length-1)*e+1,n=Math.floor(e),i=+t[n-1],e=e-n;return e?i+e*(t[n]-i):i}function Hr(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 Yr(t){var e=parseFloat(t);return e==t&&(0!==e||!H(t)||t.indexOf("x")<=0)?e:NaN}function Xr(t){return!isNaN(Yr(t))}function Ur(){return Math.round(9*Math.random())}function Zr(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)}function jr(t){throw new Error(t)}function qr(t,e,n){return(e-t)*n+t}var Kr="series\0",$r="\0_ec_\0";function Jr(t){return t instanceof Array?t:null==t?[]:[t]}function Qr(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 ta=["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 ea(t){return!O(t)||B(t)||t instanceof Date?t:t.value}function na(t,n,e){var r,a,s,l,o,u,i,h,c,p,d="normalMerge"===e,g="replaceMerge"===e,f="replaceAll"===e,y=(t=t||[],n=(n||[]).slice(),R()),e=(nt(n,function(t,e){O(t)||(n[e]=null)}),function(t,e,n){var i=[];if("replaceAll"!==n)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||sa(r)?null:r,newOption:null,keyInfo:null,brandNew:null})}return i}(t,y,e));return(d||g)&&(r=e,a=t,s=y,nt(l=n,function(t,e){var n,i,o;t&&null!=t.id&&(n=oa(t.id),null!=(i=s.get(n)))&&(Tt(!(o=r[i]).newOption,'Duplicated option on id "'+n+'".'),o.newOption=t,o.existing=a[i],l[e]=null)})),d&&(o=e,nt(u=n,function(t,e){if(t&&null!=t.name)for(var n=0;n<o.length;n++){var i=o[n].existing;if(!o[n].newOption&&i&&(null==i.id||null==t.id)&&!sa(t)&&!sa(i)&&ia("name",i,t))return o[n].newOption=t,void(u[e]=null)}})),d||g?(h=e,c=g,nt(n,function(t){if(t){for(var e,n=0;(e=h[n])&&(e.newOption||sa(e.existing)||e.existing&&null!=t.id&&!ia("id",t,e.existing));)n++;e?(e.newOption=t,e.brandNew=c):h.push({newOption:t,brandNew:c,existing:null,keyInfo:null}),n++}})):f&&(i=e,nt(n,function(t){i.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})),t=e,p=R(),nt(t,function(t){var e=t.existing;e&&p.set(e.id,t)}),nt(t,function(t){var e=t.newOption;Tt(!e||null==e.id||!p.get(e.id)||p.get(e.id)===t,"id duplicates: "+(e&&e.id)),e&&null!=e.id&&p.set(e.id,t),t.keyInfo||(t.keyInfo={})}),nt(t,function(t,e){var n=t.existing,i=t.newOption,o=t.keyInfo;if(O(i)){if(o.name=null!=i.name?oa(i.name):n?n.name:Kr+e,n)o.id=oa(n.id);else if(null!=i.id)o.id=oa(i.id);else for(var r=0;o.id="\0"+o.name+"\0"+r++,p.get(o.id););p.set(o.id,t)}}),e}function ia(t,e,n){e=ra(e[t],null),n=ra(n[t],null);return null!=e&&null!=n&&e===n}function oa(t){return ra(t,"")}function ra(t,e){return null==t?e:H(t)?t:Y(t)||gt(t)?t+"":e}function aa(t){t=t.name;return!(!t||!t.indexOf(Kr))}function sa(t){return t&&null!=t.id&&0===oa(t.id).indexOf($r)}function la(t,o,r){nt(t,function(t){var e,n,i=t.newOption;O(i)&&(t.keyInfo.mainType=o,t.keyInfo.subType=(e=o,i=i,t=t.existing,n=r,i.type||(t?t.subType:n.determineSubType(e,i))))})}function ua(e,t){return null!=t.dataIndexInside?t.dataIndexInside:null!=t.dataIndex?B(t.dataIndex)?V(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex):null!=t.name?B(t.name)?V(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name):void 0}function i(){var e="__ec_inner_"+ha++;return function(t){return t[e]||(t[e]={})}}var ha=Ur();function ca(n,t,i){var t=pa(t,i),e=t.mainTypeSpecified,o=t.queryOptionMap,r=t.others,a=i?i.defaultMainType:null;return!e&&a&&o.set(a,{}),o.each(function(t,e){t=fa(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 pa(t,i){var e=H(t)?((e={})[t+"Index"]=0,e):t,o=R(),r={},a=!1;return nt(e,function(t,e){var n;"dataIndex"===e||"dataIndexInside"===e?r[e]=t:(n=(e=e.match(/^(\w+)(Index|Id|Name)$/)||[])[1],e=(e[2]||"").toLowerCase(),!n||!e||i&&i.includeMainTypes&&G(i.includeMainTypes,n)<0||(a=a||!!n,(o.get(n)||o.set(n,{}))[e]=t))}),{mainTypeSpecified:a,queryOptionMap:o,others:r}}var da={useDefault:!0,enableAll:!1,enableNone:!1},ga={useDefault:!1,enableAll:!0,enableNone:!0};function fa(t,e,n,i){i=i||da;var o=n.index,r=n.id,n=n.name,a={models:null,specified:null!=o||null!=r||null!=n};return a.specified?"none"===o||!1===o?(Tt(i.enableNone,'`"none"` or `false` is not a valid value on index option.'),a.models=[]):("all"===o&&(Tt(i.enableAll,'`"all"` is not a valid value on index option.'),o=r=n=null),a.models=t.queryComponents({mainType:e,index:o,id:r,name:n})):(o=void 0,a.models=i.useDefault&&(o=t.getComponent(e))?[o]:[]),a}function ya(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function ma(t,n){var i=R(),o=[];return nt(t,function(t){var e=n(t);(i.get(e)||(o.push(e),i.set(e,[]))).push(t)}),{keys:o,buckets:i}}function va(t,e,n,i,o){var r=null==e||"auto"===e;if(null==i)return i;if(Y(i))return Dr(p=qr(n||0,i,o),r?Math.max(kr(n||0),kr(i)):e);if(H(i))return o<1?n:i;for(var a=[],s=n,l=i,u=Math.max(s?s.length:0,l.length),h=0;h<u;++h){var c,p,d=t.getDimensionInfo(h);d&&"ordinal"===d.type?a[h]=(o<1&&s?s:l)[h]:(p=qr(d=s&&s[h]?s[h]:0,c=l[h],o),a[h]=Dr(p,r?Math.max(kr(d),kr(c)):e))}return a}var xa=".",_a="___EC__COMPONENT__CONTAINER___",ba="___EC__EXTENDED_CLASS___";function wa(t){var e={main:"",sub:""};return t&&(t=t.split(xa),e.main=t[0]||"",e.sub=t[1]||""),e}function Sa(t){(t.$constructor=t).extend=function(t){var e,n,i,o=this;function r(){return n.apply(this,arguments)||this}return D(i=o)&&/^class\s/.test(Function.prototype.toString.call(i))?(u(r,n=o),e=r):lt(e=function(){(t.$constructor||o).apply(this,arguments)},this),F(e.prototype,t),e[ba]=!0,e.extend=this.extend,e.superCall=Ta,e.superApply=Ca,e.superClass=o,e}}function Ma(t,e){t.extend=e.extend}var Ia=Math.round(10*Math.random());function Ta(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 Ca(t,e,n){return this.superClass.prototype[e].apply(t,n)}function Da(t){var o={};t.registerClass=function(t){var e,n=t.type||t.prototype.type;return n&&(Tt(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e=n),'componentType "'+e+'" illegal'),(e=wa(t.prototype.type=n)).sub?e.sub!==_a&&(function(t){var e=o[t.main];e&&e[_a]||(e=o[t.main]={___EC__COMPONENT__CONTAINER___:!0});return e}(e)[e.sub]=t):o[e.main]=t),t},t.getClass=function(t,e,n){var i=o[t];if(i&&i[_a]&&(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=wa(t),n=[],t=o[t.main];return t&&t[_a]?nt(t,function(t,e){e!==_a&&n.push(t)}):n.push(t),n},t.hasClass=function(t){t=wa(t);return!!o[t.main]},t.getAllClassMainTypes=function(){var n=[];return nt(o,function(t,e){n.push(e)}),n},t.hasSubTypes=function(t){t=wa(t),t=o[t.main];return t&&t[_a]}}function Aa(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<=G(e,r)||n&&G(n,r)<0||null!=(r=t.getShallow(r,s))&&(i[a[o][0]]=r)}return i}}var ka=Aa([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),La=(Pa.prototype.getAreaStyle=function(t,e){return ka(this,t,e)},Pa);function Pa(){}var Oa=new ui(50);function Na(t,e,n,i,o){return t?"string"==typeof t?(e&&e.__zrImageSrc===t||!n||(n={hostEl:n,cb:i,cbPayload:o},(i=Oa.get(t))?Ea(e=i.image)||i.pending.push(n):((e=Q.loadImage(t,Ra,Ra)).__zrImageSrc=t,Oa.put(t,e.__cachedImgObj={image:e,pending:[n]}))),e):t:e}function Ra(){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 Ea(t){return t&&t.width&&t.height}var za=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function Va(t,e,n,i,o){if(!e)return"";var r=(t+"").split("\n");o=Ba(e,n,i,o);for(var a=0,s=r.length;a<s;a++)r[a]=Fa(r[a],o);return r.join("\n")}function Ba(t,e,n,i){for(var o=F({},i=i||{}),r=(o.font=e,n=N(n,"..."),o.maxIterations=N(i.maxIterations,2),o.minChar=N(i.minChar,0)),a=(o.cnCharWidth=qo("å½",e),o.ascCharWidth=qo("a",e)),s=(o.placeholder=N(i.placeholder,""),t=Math.max(0,t-1)),l=0;l<r&&a<=s;l++)s-=a;i=qo(n,e);return s<i&&(n="",i=0),s=t-i,o.ellipsis=n,o.ellipsisWidth=i,o.contentWidth=s,o.containerWidth=t,o}function Fa(t,e){var n=e.containerWidth,i=e.font,o=e.contentWidth;if(!n)return"";var r=qo(t,i);if(!(r<=n)){for(var a=0;;a++){if(r<=o||a>=e.maxIterations){t+=e.ellipsis;break}var s=0===a?function(t,e,n,i){for(var 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<r?Math.floor(t.length*o/r):0,r=qo(t=t.substr(0,s),i)}""===t&&(t=e.placeholder)}return t}var Ga=function(){},Wa=function(t){this.tokens=[],t&&(this.tokens=t)},Ha=function(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[]};function Ya(t,e){var n=new Ha;if(null!=t&&(t+=""),t){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=za.lastIndex=0;null!=(i=za.exec(t));){var u=i.index;l<u&&Xa(n,t.substring(l,u),e,s),Xa(n,i[2],e,s,i[1]),l=za.lastIndex}l<t.length&&Xa(n,t.substring(l,t.length),e,s);var h,c=[],p=0,d=0,g=e.padding,f="truncate"===a,y="truncate"===e.lineOverflow;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=(A=v.tokens[b]).styleName&&e.rich[A.styleName]||{},S=A.textPadding=w.padding,M=S?S[1]+S[3]:0,I=A.font=w.font||e.font,T=(A.contentHeight=tr(I),N(w.height,A.contentHeight));if(A.innerHeight=T,S&&(T+=S[0]+S[2]),A.height=T,A.lineHeight=St(w.lineHeight,e.lineHeight,T),A.align=w&&w.align||e.align,A.verticalAlign=w&&w.verticalAlign||"middle",y&&null!=r&&p+A.lineHeight>r){0<b?(v.tokens=v.tokens.slice(0,b),L(v,_,x),n.lines=n.lines.slice(0,m+1)):n.lines=n.lines.slice(0,m);break t}var C,S=w.width,D=null==S||"auto"===S;"string"==typeof S&&"%"===S.charAt(S.length-1)?(A.percentWidth=S,c.push(A),A.contentWidth=qo(A.text,I)):(D&&(S=(S=w.backgroundColor)&&S.image)&&(C=void 0,Ea(S="string"==typeof(h=S)?(C=Oa.get(h))&&C.image:h))&&(A.width=Math.max(A.width,S.width*T/S.height)),null!=(C=f&&null!=o?o-_:null)&&C<A.width?!D||C<M?(A.text="",A.width=A.contentWidth=0):(A.text=Va(A.text,C-M,I,e.ellipsis,{minChar:e.truncateMinChar}),A.width=A.contentWidth=qo(A.text,I)):A.contentWidth=qo(A.text,I)),A.width+=M,_+=A.width,w&&(x=Math.max(x,A.lineHeight))}L(v,_,x)}n.outerWidth=n.width=N(o,d),n.outerHeight=n.height=N(r,p),n.contentHeight=p,n.contentWidth=d,g&&(n.outerWidth+=g[1]+g[3],n.outerHeight+=g[0]+g[2]);for(m=0;m<c.length;m++){var A,k=(A=c[m]).percentWidth;A.width=parseInt(k,10)/100*n.width}}return n;function L(t,e,n){t.width=e,t.lineHeight=n,p+=n,d=Math.max(d,e)}}function Xa(t,e,n,i,o){var r,a,s=""===e,l=o&&n.rich[o]||{},u=t.lines,h=l.font||n.font,c=!1;i?(n=(t=l.padding)?t[1]+t[3]:0,null!=l.width&&"auto"!==l.width?(t=er(l.width,i.width)+n,0<u.length&&t+i.accumWidth>i.width&&(r=e.split("\n"),c=!0),i.accumWidth=t):(t=Za(e,h,i.width,i.breakAll,i.accumWidth),i.accumWidth=t.accumWidth+n,a=t.linesWidths,r=t.lines)):r=e.split("\n");for(var p=0;p<r.length;p++){var d,g,f=r[p],y=new Ga;y.styleName=o,y.text=f,y.isLineHolder=!f&&!s,"number"==typeof l.width?y.width=l.width:y.width=a?a[p]:qo(f,h),p||c?u.push(new Wa([y])):1===(g=(d=(u[u.length-1]||(u[0]=new Wa)).tokens).length)&&d[0].isLineHolder?d[0]=y:!f&&g&&!s||d.push(y)}}var Ua=ct(",&?/;] ".split(""),function(t,e){return t[e]=!0,t},{});function Za(t,e,n,i,o){for(var r,a=[],s=[],l="",u="",h=0,c=0,p=0;p<t.length;p++){var d,g,f=t.charAt(p);"\n"===f?(u&&(l+=u,c+=h),a.push(l),s.push(c),u=l="",c=h=0):(d=qo(f,e),g=!(i||(g=void 0,!(32<=(g=(g=r=f).charCodeAt(0))&&g<=591||880<=g&&g<=4351||4608<=g&&g<=5119||7680<=g&&g<=8303))||!!Ua[r]),(a.length?n<c+d:n<o+c+d)?c?(l||u)&&(c=g?(l||(l=u,u="",c=h=0),a.push(l),s.push(c-h),u+=f,l="",h+=d):(u&&(l+=u,u="",h=0),a.push(l),s.push(c),l=f,d)):g?(a.push(u),s.push(h),u=f,h=d):(a.push(f),s.push(d)):(c+=d,g?(u+=f,h+=d):(u&&(l+=u,u="",h=0),l+=f)))}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 ja,qa="__zr_style_"+Math.round(10*Math.random()),Ka={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},$a={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}},Ja=(Ka[qa]=!0,["z","z2","invisible"]),Qa=["invisible"],ts=(u(es,ja=e),es.prototype._init=function(t){for(var e=W(t),n=0;n<e.length;n++){var i=e[n];"style"===i?this.useStyle(t[i]):ja.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},es.prototype.beforeBrush=function(){},es.prototype.afterBrush=function(){},es.prototype.innerBeforeBrush=function(){},es.prototype.innerAfterBrush=function(){},es.prototype.shouldBePainted=function(t,e,n,i){var o=this.transform;if(this.ignore||this.invisible||0===this.style.opacity||this.culling&&function(t,e,n){ns.copy(t.getBoundingRect()),t.transform&&ns.applyTransform(t.transform);return is.width=e,is.height=n,!ns.intersect(is)}(this,t,e)||o&&!o[0]&&!o[3])return!1;if(n&&this.__clipPaths)for(var r=0;r<this.__clipPaths.length;++r)if(this.__clipPaths[r].isZeroArea())return!1;if(i&&this.parent)for(var a=this.parent;a;){if(a.ignore)return!1;a=a.parent}return!0},es.prototype.contain=function(t,e){return this.rectContain(t,e)},es.prototype.traverse=function(t,e){t.call(e,this)},es.prototype.rectContain=function(t,e){t=this.transformCoordToLocal(t,e);return this.getBoundingRect().contain(t[0],t[1])},es.prototype.getPaintRect=function(){var t,e,n,i,o,r=this._paintRect;return this._paintRect&&!this.__dirty||(o=this.transform,t=this.getBoundingRect(),e=(i=this.style).shadowBlur||0,n=i.shadowOffsetX||0,i=i.shadowOffsetY||0,r=this._paintRect||(this._paintRect=new U(0,0,0,0)),o?U.applyTransform(r,t,o):r.copy(t),(e||n||i)&&(r.width+=2*e+Math.abs(n),r.height+=2*e+Math.abs(i),r.x=Math.min(r.x,r.x+n-e),r.y=Math.min(r.y,r.y+i-e)),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},es.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new U(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},es.prototype.getPrevPaintRect=function(){return this._prevPaintRect},es.prototype.animateStyle=function(t){return this.animate("style",t)},es.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():this.markRedraw()},es.prototype.attrKV=function(t,e){"style"!==t?ja.prototype.attrKV.call(this,t,e):this.style?this.setStyle(e):this.useStyle(e)},es.prototype.setStyle=function(t,e){return"string"==typeof t?this.style[t]=e:F(this.style,t),this.dirtyStyle(),this},es.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=2,this._rect&&(this._rect=null)},es.prototype.dirty=function(){this.dirtyStyle()},es.prototype.styleChanged=function(){return!!(2&this.__dirty)},es.prototype.styleUpdated=function(){this.__dirty&=-3},es.prototype.createStyle=function(t){return zt(Ka,t)},es.prototype.useStyle=function(t){t[qa]||(t=this.createStyle(t)),this.__inHover?this.__hoverStyle=t:this.style=t,this.dirtyStyle()},es.prototype.isStyleObject=function(t){return t[qa]},es.prototype._innerSaveToNormal=function(t){ja.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,Ja)},es.prototype._applyStateObj=function(t,e,n,i,o,r){ja.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=W(l),h=0;h<u.length;h++)(p=u[h])in a&&(a[p]=a[p],this.style[p]=l[p]);for(var c=W(a),h=0;h<c.length;h++){var p=c[h];this.style[p]=this.style[p]}this._transitionState(t,{style:a},r,this.getAnimationStyleProps())}else this.useStyle(a);for(var d=this.__inHover?Qa:Ja,h=0;h<d.length;h++){p=d[h];e&&null!=e[p]?this[p]=e[p]:s&&null!=n[p]&&(this[p]=n[p])}},es.prototype._mergeStates=function(t){for(var e,n=ja.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},es.prototype._mergeStyle=function(t,e){return F(t,e),t},es.prototype.getAnimationStyleProps=function(){return $a},es.initDefaultProps=((e=es.prototype).type="displayable",e.invisible=!1,e.z=0,e.z2=0,e.zlevel=0,e.culling=!1,e.cursor="pointer",e.rectHover=!1,e.incremental=!1,e._rect=null,e.dirtyRectTolerance=0,void(e.__dirty=2|In)),es);function es(t){return ja.call(this,t)||this}var ns=new U(0,0,0,0),is=new U(0,0,0,0);var os=Math.min,rs=Math.max,as=Math.sin,ss=Math.cos,ls=2*Math.PI,us=Wt(),hs=Wt(),cs=Wt();function ps(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=os(o,i[0]),r=rs(r,i[0]),a=os(a,i[1]),s=rs(s,i[1]);e[0]=o,e[1]=a,n[0]=r,n[1]=s}}function ds(t,e,n,i,o,r){o[0]=os(t,n),o[1]=os(e,i),r[0]=rs(t,n),r[1]=rs(e,i)}var gs=[],fs=[];var ys={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},ms=[],vs=[],xs=[],_s=[],bs=[],ws=[],Ss=Math.min,Ms=Math.max,Is=Math.cos,Ts=Math.sin,Cs=Math.abs,Ds=Math.PI,As=2*Ds,ks="undefined"!=typeof Float32Array,Ls=[];function Ps(t){return Math.round(t/Ds*1e8)/1e8%2*Ds}function Os(t,e){var n=Ps(t[0]),i=(n<0&&(n+=As),n-t[0]),o=t[1];o+=i,!e&&As<=o-n?o=n+As:e&&As<=n-o?o=n-As:!e&&o<n?o=n+(As-Ps(n-o)):e&&n<o&&(o=n-(As-Ps(o-n))),t[0]=n,t[1]=o}Rs.prototype.increaseVersion=function(){this._version++},Rs.prototype.getVersion=function(){return this._version},Rs.prototype.setScale=function(t,e,n){0<(n=n||0)&&(this._ux=Cs(n/Ro/t)||0,this._uy=Cs(n/Ro/e)||0)},Rs.prototype.setDPR=function(t){this.dpr=t},Rs.prototype.setContext=function(t){this._ctx=t},Rs.prototype.getContext=function(){return this._ctx},Rs.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},Rs.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},Rs.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(ys.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},Rs.prototype.lineTo=function(t,e){var n=Cs(t-this._xi),i=Cs(e-this._yi),o=n>this._ux||i>this._uy;return this.addData(ys.L,t,e),this._ctx&&o&&this._ctx.lineTo(t,e),o?(this._xi=t,this._yi=e,this._pendingPtDist=0):(o=n*n+i*i)>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=o),this},Rs.prototype.bezierCurveTo=function(t,e,n,i,o,r){return this._drawPendingPt(),this.addData(ys.C,t,e,n,i,o,r),this._ctx&&this._ctx.bezierCurveTo(t,e,n,i,o,r),this._xi=o,this._yi=r,this},Rs.prototype.quadraticCurveTo=function(t,e,n,i){return this._drawPendingPt(),this.addData(ys.Q,t,e,n,i),this._ctx&&this._ctx.quadraticCurveTo(t,e,n,i),this._xi=n,this._yi=i,this},Rs.prototype.arc=function(t,e,n,i,o,r){return this._drawPendingPt(),Ls[0]=i,Ls[1]=o,Os(Ls,r),this.addData(ys.A,t,e,n,n,i=Ls[0],(o=Ls[1])-i,0,r?0:1),this._ctx&&this._ctx.arc(t,e,n,i,o,r),this._xi=Is(o)*n+t,this._yi=Ts(o)*n+e,this},Rs.prototype.arcTo=function(t,e,n,i,o){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,n,i,o),this},Rs.prototype.rect=function(t,e,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,n,i),this.addData(ys.R,t,e,n,i),this},Rs.prototype.closePath=function(){this._drawPendingPt(),this.addData(ys.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&t.closePath(),this._xi=e,this._yi=n,this},Rs.prototype.fill=function(t){t&&t.fill(),this.toStatic()},Rs.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},Rs.prototype.len=function(){return this._len},Rs.prototype.setData=function(t){var e=t.length;this.data&&this.data.length===e||!ks||(this.data=new Float32Array(e));for(var n=0;n<e;n++)this.data[n]=t[n];this._len=e},Rs.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();ks&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(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},Rs.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]}},Rs.prototype._drawPendingPt=function(){0<this._pendingPtDist&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},Rs.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}},Rs.prototype.toStatic=function(){var t;this._saveData&&(this._drawPendingPt(),(t=this.data)instanceof Array)&&(t.length=this._len,ks)&&11<this._len&&(this.data=new Float32Array(t))},Rs.prototype.getBoundingRect=function(){xs[0]=xs[1]=bs[0]=bs[1]=Number.MAX_VALUE,_s[0]=_s[1]=ws[0]=ws[1]=-Number.MAX_VALUE;for(var t,e=this.data,n=0,i=0,o=0,r=0,a=0;a<this._len;){var E=e[a++],z=1===a;switch(z&&(o=n=e[a],r=i=e[a+1]),E){case ys.M:n=o=e[a++],i=r=e[a++],bs[0]=o,bs[1]=r,ws[0]=o,ws[1]=r;break;case ys.L:ds(n,i,e[a],e[a+1],bs,ws),n=e[a++],i=e[a++];break;case ys.C:W=G=m=y=F=f=g=d=p=c=B=V=h=u=l=s=void 0;var s=n,l=i,u=e[a++],h=e[a++],V=e[a++],B=e[a++],c=e[a],p=e[a+1],d=bs,g=ws,f=jn,F=Xn,y=f(s,u,V,c,gs);d[0]=1/0,d[1]=1/0,g[0]=-1/0,g[1]=-1/0;for(var m=0;m<y;m++){var G=F(s,u,V,c,gs[m]);d[0]=os(G,d[0]),g[0]=rs(G,g[0])}for(y=f(l,h,B,p,fs),m=0;m<y;m++){var W=F(l,h,B,p,fs[m]);d[1]=os(W,d[1]),g[1]=rs(W,g[1])}d[0]=os(s,d[0]),g[0]=rs(s,g[0]),d[0]=os(c,d[0]),g[0]=rs(c,g[0]),d[1]=os(l,d[1]),g[1]=rs(l,g[1]),d[1]=os(p,d[1]),g[1]=rs(p,g[1]),n=e[a++],i=e[a++];break;case ys.Q:f=n,P=i,M=e[a++],_=e[a++],S=e[a],v=e[a+1],w=bs,I=ws,t=b=t=x=void 0,x=$n,t=rs(os((b=Qn)(f,M,S),1),0),b=rs(os(b(P,_,v),1),0),M=x(f,M,S,t),t=x(P,_,v,b),w[0]=os(f,S,M),w[1]=os(P,v,t),I[0]=rs(f,S,M),I[1]=rs(P,v,t),n=e[a++],i=e[a++];break;case ys.A:var v,x=e[a++],_=e[a++],b=e[a++],w=e[a++],S=e[a++],M=e[a++]+S,I=(a+=1,!e[a++]),T=(z&&(o=Is(S)*b+x,r=Ts(S)*w+_),R=v=Y=H=N=O=P=L=k=A=D=C=T=void 0,x),C=_,D=b,A=w,k=S,L=M,P=I,O=bs,N=ws,H=re,Y=ae;if((v=Math.abs(k-L))%ls<1e-4&&1e-4<v)O[0]=T-D,O[1]=C-A,N[0]=T+D,N[1]=C+A;else{us[0]=ss(k)*D+T,us[1]=as(k)*A+C,hs[0]=ss(L)*D+T,hs[1]=as(L)*A+C,H(O,us,hs),Y(N,us,hs),(k%=ls)<0&&(k+=ls),(L%=ls)<0&&(L+=ls),L<k&&!P?L+=ls:k<L&&P&&(k+=ls),P&&(v=L,L=k,k=v);for(var R=0;R<L;R+=Math.PI/2)k<R&&(cs[0]=ss(R)*D+T,cs[1]=as(R)*A+C,H(O,cs,O),Y(N,cs,N))}n=Is(M)*b+x,i=Ts(M)*w+_;break;case ys.R:ds(o=n=e[a++],r=i=e[a++],o+e[a++],r+e[a++],bs,ws);break;case ys.Z:n=o,i=r}re(xs,xs,bs),ae(_s,_s,ws)}return 0===a&&(xs[0]=xs[1]=_s[0]=_s[1]=0),new U(xs[0],xs[1],_s[0]-xs[0],_s[1]-xs[1])},Rs.prototype._calculateLength=function(){for(var t=this.data,e=this._len,n=this._ux,i=this._uy,o=0,r=0,a=0,s=0,l=(this._pathSegLen||(this._pathSegLen=[]),this._pathSegLen),u=0,h=0,c=0;c<e;){var p=t[c++],d=1===c,g=(d&&(a=o=t[c],s=r=t[c+1]),-1);switch(p){case ys.M:o=a=t[c++],r=s=t[c++];break;case ys.L:var f=t[c++],y=(x=t[c++])-r;(Cs(C=f-o)>n||Cs(y)>i||c===e-1)&&(g=Math.sqrt(C*C+y*y),o=f,r=x);break;case ys.C:var m=t[c++],v=t[c++],f=t[c++],x=t[c++],_=t[c++],b=t[c++],g=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 g=d*p,f=Xn(t,n,o,a,g),g=Xn(e,i,r,s,g),y=f-u,m=g-h;c+=Math.sqrt(y*y+m*m),u=f,h=g}return c}(o,r,m,v,f,x,_,b,10),o=_,r=b;break;case ys.Q:g=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=$n(t,n,o,p),p=$n(e,i,r,p),g=d-s,f=p-l;u+=Math.sqrt(g*g+f*f),s=d,l=p}return u}(o,r,m=t[c++],v=t[c++],f=t[c++],x=t[c++],10),o=f,r=x;break;case ys.A:var _=t[c++],b=t[c++],w=t[c++],S=t[c++],M=t[c++],I=t[c++],T=I+M;c+=1,d&&(a=Is(M)*w+_,s=Ts(M)*S+b),g=Ms(w,S)*Ss(As,Math.abs(I)),o=Is(T)*w+_,r=Ts(T)*S+b;break;case ys.R:a=o=t[c++],s=r=t[c++];g=2*t[c++]+2*t[c++];break;case ys.Z:var C=a-o,y=s-r;g=Math.sqrt(C*C+y*y),o=a,r=s}0<=g&&(u+=l[h++]=g)}return this._pathLen=u},Rs.prototype.rebuildPath=function(t,e){var n,i,o,r,a,s,l,u,h=this.data,E=this._ux,z=this._uy,V=this._len,c=e<1,p=0,d=0,g=0;if(!c||(this._pathSegLen||this._calculateLength(),a=this._pathSegLen,s=e*this._pathLen))t:for(var f=0;f<V;){var y=h[f++],B=1===f;switch(B&&(n=o=h[f],i=r=h[f+1]),y!==ys.L&&0<g&&(t.lineTo(l,u),g=0),y){case ys.M:n=o=h[f++],i=r=h[f++],t.moveTo(o,r);break;case ys.L:var m=h[f++],v=h[f++],x=Cs(m-o),_=Cs(v-r);if(E<x||z<_){if(c){if(s<p+(R=a[d++])){var b=(s-p)/R;t.lineTo(o*(1-b)+m*b,r*(1-b)+v*b);break t}p+=R}t.lineTo(m,v),o=m,r=v,g=0}else{x=x*x+_*_;g<x&&(l=m,u=v,g=x)}break;case ys.C:var w=h[f++],S=h[f++],M=h[f++],I=h[f++],_=h[f++],x=h[f++];if(c){if(s<p+(R=a[d++])){qn(o,w,M,_,b=(s-p)/R,ms),qn(r,S,I,x,b,vs),t.bezierCurveTo(ms[1],vs[1],ms[2],vs[2],ms[3],vs[3]);break t}p+=R}t.bezierCurveTo(w,S,M,I,_,x),o=_,r=x;break;case ys.Q:w=h[f++],S=h[f++],M=h[f++],I=h[f++];if(c){if(s<p+(R=a[d++])){ti(o,w,M,b=(s-p)/R,ms),ti(r,S,I,b,vs),t.quadraticCurveTo(ms[1],vs[1],ms[2],vs[2]);break t}p+=R}t.quadraticCurveTo(w,S,M,I),o=M,r=I;break;case ys.A:var T=h[f++],C=h[f++],D=h[f++],A=h[f++],k=h[f++],L=h[f++],P=h[f++],F=!h[f++],G=A<D?D:A,O=.001<Cs(D-A),N=k+L,W=!1;if(c&&(s<p+(R=a[d++])&&(N=k+L*(s-p)/R,W=!0),p+=R),O&&t.ellipse?t.ellipse(T,C,D,A,P,k,N,F):t.arc(T,C,G,k,N,F),W)break t;B&&(n=Is(k)*D+T,i=Ts(k)*A+C),o=Is(N)*D+T,r=Ts(N)*A+C;break;case ys.R:n=o=h[f],i=r=h[f+1],m=h[f++],v=h[f++];var R,L=h[f++],O=h[f++];if(c){if(s<p+(R=a[d++])){P=s-p;t.moveTo(m,v),t.lineTo(m+Ss(P,L),v),0<(P-=L)&&t.lineTo(m+L,v+Ss(P,O)),0<(P-=O)&&t.lineTo(m+Ms(L-P,0),v+O),0<(P-=L)&&t.lineTo(m,v+Ms(O-P,0));break t}p+=R}t.rect(m,v,L,O);break;case ys.Z:if(c){if(s<p+(R=a[d++])){b=(s-p)/R;t.lineTo(o*(1-b)+n*b,r*(1-b)+i*b);break t}p+=R}t.closePath(),o=n,r=i}}},Rs.prototype.clone=function(){var t=new Rs,e=this.data;return t.data=e.slice?e.slice():Array.prototype.slice.call(e),t._len=this._len,t},Rs.CMD=ys,Rs.initDefaultProps=((e=Rs.prototype)._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,void(e._version=0));var Ns=Rs;function Rs(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 Es(t,e,n,i,o,r,a){var s;if(0!==o)return s=0,!(e+(o=o)<a&&i+o<a||a<e-o&&a<i-o||t+o<r&&n+o<r||r<t-o&&r<n-o)&&(t===n?Math.abs(r-t)<=o/2:(r=(s=(e-i)/(t-n))*r-a+(t*i-n*e)/(t-n))*r/(s*s+1)<=o/2*o/2)}function zs(t,e,n,i,o,r,a,s,l){if(0!==a)return!(e+(a=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)&&ei(t,e,n,i,o,r,s,l,null)<=a/2}var Vs=2*Math.PI;function Bs(t){return(t%=Vs)<0&&(t+=Vs),t}var Fs=2*Math.PI;function Gs(t,e,n,i,o,r){return e<r&&i<r||r<e&&r<i||i===e?0:(n=(r=(r-e)/(i-e))*(n-t)+t)===o?1/0:o<n?1!=r&&0!=r?i<e?1:-1:i<e?.5:-.5:0}var Ws=Ns.CMD,Hs=2*Math.PI,Ys=1e-4;var Xs=[-1,-1,-1],Us=[-1,-1];function Zs(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=Zn(e,i,r,s,u,Xs);if(0===h)return 0;for(var c,p=0,d=-1,g=void 0,f=void 0,y=0;y<h;y++){var m=Xs[y],v=0===m||1===m?.5:1;Xn(t,n,o,a,m)<l||(d<0&&(d=jn(e,i,r,s,Us),Us[1]<Us[0]&&1<d&&(c=void 0,c=Us[0],Us[0]=Us[1],Us[1]=c),g=Xn(e,i,r,s,Us[0]),1<d)&&(f=Xn(e,i,r,s,Us[1])),2===d?m<Us[0]?p+=g<e?v:-v:m<Us[1]?p+=f<g?v:-v:p+=s<f?v:-v:m<Us[0]?p+=g<e?v:-v:p+=s<g?v:-v)}return p}function js(t,e,n,i,o,r,a,s){if(e<s&&i<s&&r<s||s<e&&s<i&&s<r)return 0;c=Xs,h=(l=e)-2*(u=i)+(h=r),u=2*(u-l),l-=s=s,s=0,Hn(h)?Yn(u)&&0<=(p=-l/u)&&p<=1&&(c[s++]=p):Hn(l=u*u-4*h*l)?0<=(p=-u/(2*h))&&p<=1&&(c[s++]=p):0<l&&(d=(-u-(l=Rn(l)))/(2*h),0<=(p=(-u+l)/(2*h))&&p<=1&&(c[s++]=p),0<=d)&&d<=1&&(c[s++]=d);var l,u,h,c,p,d,g=s;if(0===g)return 0;var f=Qn(e,i,r);if(0<=f&&f<=1){for(var y=0,m=$n(e,i,r,f),v=0;v<g;v++){var x=0===Xs[v]||1===Xs[v]?.5:1;$n(t,n,o,Xs[v])<a||(Xs[v]<f?y+=m<e?x:-x:y+=r<m?x:-x)}return y}return x=0===Xs[0]||1===Xs[0]?.5:1,$n(t,n,o,Xs[0])<a?0:r<e?x:-x}function qs(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 g=a[d++],f=1===d;switch(g===Ws.M&&1<d&&(n||(l+=Gs(u,h,c,p,i,o))),f&&(c=u=a[d],p=h=a[d+1]),g){case Ws.M:u=c=a[d++],h=p=a[d++];break;case Ws.L:if(n){if(Es(u,h,a[d],a[d+1],e,i,o))return!0}else l+=Gs(u,h,a[d],a[d+1],i,o)||0;u=a[d++],h=a[d++];break;case Ws.C:if(n){if(function(t,e,n,i,o,r,a,s,l,u,h){if(0!==l)return!(e+(l=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)&&Kn(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+=Zs(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 Ws.Q:if(n){if(zs(u,h,a[d++],a[d++],a[d],a[d+1],e,i,o))return!0}else l+=js(u,h,a[d++],a[d++],a[d],a[d+1],i,o)||0;u=a[d++],h=a[d++];break;case Ws.A:var y=a[d++],m=a[d++],v=a[d++],x=a[d++],_=a[d++],b=a[d++],w=(d+=1,!!(1-a[d++])),S=Math.cos(_)*v+y,M=Math.sin(_)*x+m,I=(f?(c=S,p=M):l+=Gs(u,h,S,M,i,o),(i-y)*x/v+y);if(n){if(function(t,e,n,i,o,r,a,s,l){if(0!==a)return a=a,s-=t,l-=e,!(n<(t=Math.sqrt(s*s+l*l))-a||t+a<n)&&(Math.abs(i-o)%Fs<1e-4||((o=r?(e=i,i=Bs(o),Bs(e)):(i=Bs(i),Bs(o)))<i&&(o+=Fs),(t=Math.atan2(l,s))<0&&(t+=Fs),i<=t&&t<=o)||i<=t+Fs&&t+Fs<=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;var e=Math.sqrt(n*n-s*s);if(Xs[0]=-e,Xs[1]=e,(n=Math.abs(i-o))<1e-4)return 0;if(Hs-1e-4<=n)return o=Hs,h=r?1:-1,a>=Xs[i=0]+t&&a<=Xs[1]+t?h:0;o<i&&(e=i,i=o,o=e),i<0&&(i+=Hs,o+=Hs);for(var l=0,u=0;u<2;u++){var h,c=Xs[u];a<c+t&&(h=r?1:-1,i<=(c=(c=Math.atan2(s,c))<0?Hs+c:c)&&c<=o||i<=c+Hs&&c+Hs<=o)&&(l+=h=c>Math.PI/2&&c<1.5*Math.PI?-h:h)}return l}(y,m,x,_,_+b,w,I,o);u=Math.cos(_+b)*v+y,h=Math.sin(_+b)*x+m;break;case Ws.R:c=u=a[d++],p=h=a[d++];if(S=c+a[d++],M=p+a[d++],n){if(Es(c,p,S,p,e,i,o)||Es(S,p,S,M,e,i,o)||Es(S,M,c,M,e,i,o)||Es(c,M,c,p,e,i,o))return!0}else l=(l+=Gs(S,p,S,M,i,o))+Gs(c,M,c,p,i,o);break;case Ws.Z:if(n){if(Es(u,h,c,p,e,i,o))return!0}else l+=Gs(u,h,c,p,i,o);u=c,h=p}}return n||(t=h,r=p,Math.abs(t-r)<Ys)||(l+=Gs(u,h,c,p,i,o)||0),0!==l}var Ks,$s=z({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},Ka),Js={style:z({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},$a.style)},Qs=Uo.concat(["invisible","culling","z","z2","zlevel","parent"]),q=(u(tl,Ks=ts),tl.prototype.update=function(){var e=this,t=(Ks.prototype.update.call(this),this.style);if(t.decal){var n,i=this._decalEl=this._decalEl||new tl,o=(i.buildPath===tl.prototype.buildPath&&(i.buildPath=function(t){e.buildPath(t,e.shape)}),i.silent=!0,i.style);for(n in t)o[n]!==t[n]&&(o[n]=t[n]);o.fill=t.fill?t.decal:null,o.decal=null,o.shadowColor=null,t.strokeFirst&&(o.stroke=null);for(var r=0;r<Qs.length;++r)i[Qs[r]]=this[Qs[r]];i.__dirty|=In}else this._decalEl&&(this._decalEl=null)},tl.prototype.getDecalElement=function(){return this._decalEl},tl.prototype._init=function(t){var e=W(t),n=(this.shape=this.getDefaultShape(),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?F(this.style,r):this.useStyle(r):"shape"===o?F(this.shape,r):Ks.prototype.attrKV.call(this,o,r)}this.style||this.useStyle({})},tl.prototype.getDefaultStyle=function(){return null},tl.prototype.getDefaultShape=function(){return{}},tl.prototype.canBeInsideText=function(){return this.hasFill()},tl.prototype.getInsideTextFill=function(){var t,e=this.style.fill;if("none"!==e){if(H(e))return.5<(t=Pi(e,0))?Eo:.2<t?"#eee":zo;if(e)return zo}return Eo},tl.prototype.getInsideTextStroke=function(t){var e=this.style.fill;if(H(e)){var n=this.__zr;if(!(!n||!n.isDarkMode())==Pi(t,0)<.4)return e}},tl.prototype.buildPath=function(t,e,n){},tl.prototype.pathUpdated=function(){this.__dirty&=~Tn},tl.prototype.getUpdatedPathProxy=function(t){return this.path||this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},tl.prototype.createPathProxy=function(){this.path=new Ns(!1)},tl.prototype.hasStroke=function(){var t=this.style,e=t.stroke;return!(null==e||"none"===e||!(0<t.lineWidth))},tl.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},tl.prototype.getBoundingRect=function(){var t,e,n=this._rect,i=this.style,o=!n;return o&&(t=!1,this.path||(t=!0,this.createPathProxy()),e=this.path,(t||this.__dirty&Tn)&&(e.beginPath(),this.buildPath(e,this.shape,!1),this.pathUpdated()),n=e.getBoundingRect()),this._rect=n,this.hasStroke()&&this.path&&0<this.path.len()?(t=this._rectStroke||(this._rectStroke=n.clone()),(this.__dirty||o)&&(t.copy(n),e=i.strokeNoScale?this.getLineScale():1,o=i.lineWidth,this.hasFill()||(i=this.strokeContainThreshold,o=Math.max(o,null==i?4:i)),1e-10<e)&&(t.width+=o/e,t.height+=o/e,t.x-=o/e/2,t.y-=o/e/2),t):n},tl.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)),qs(n,i/o,!0,t,e)))return!0}if(this.hasFill())return qs(n,0,!1,t,e)}return!1},tl.prototype.dirtyShape=function(){this.__dirty|=Tn,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},tl.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},tl.prototype.animateShape=function(t){return this.animate("shape",t)},tl.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():"shape"===t?this.dirtyShape():this.markRedraw()},tl.prototype.attrKV=function(t,e){"shape"===t?this.setShape(e):Ks.prototype.attrKV.call(this,t,e)},tl.prototype.setShape=function(t,e){var n=(n=this.shape)||(this.shape={});return"string"==typeof t?n[t]=e:F(n,t),this.dirtyShape(),this},tl.prototype.shapeChanged=function(){return!!(this.__dirty&Tn)},tl.prototype.createStyle=function(t){return zt($s,t)},tl.prototype._innerSaveToNormal=function(t){Ks.prototype._innerSaveToNormal.call(this,t);var e=this._normalState;t.shape&&!e.shape&&(e.shape=F({},this.shape))},tl.prototype._applyStateObj=function(t,e,n,i,o,r){Ks.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=F({},n.shape),F(a,e.shape)):(a=F({},(i?this:n).shape),F(a,e.shape)):s&&(a=n.shape),a)if(o){this.shape=F({},this.shape);for(var l={},u=W(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()},tl.prototype._mergeStates=function(t){for(var e,n=Ks.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},tl.prototype.getAnimationStyleProps=function(){return Js},tl.prototype.isZeroArea=function(){return!1},tl.extend=function(n){u(o,i=tl),o.prototype.getDefaultStyle=function(){return S(n.style)},o.prototype.getDefaultShape=function(){return S(n.shape)};var i,t,e=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},tl.initDefaultProps=((e=tl.prototype).type="path",e.strokeContainThreshold=5,e.segmentIgnoreThreshold=0,e.subPixelOptimize=!1,e.autoBatch=!1,void(e.__dirty=2|In|Tn)),tl);function tl(t){return Ks.call(this,t)||this}var el,nl=z({strokeFirst:!0,font:J,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},$s),il=(u(ol,el=ts),ol.prototype.hasStroke=function(){var t=this.style,e=t.stroke;return null!=e&&"none"!==e&&0<t.lineWidth},ol.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},ol.prototype.createStyle=function(t){return zt(nl,t)},ol.prototype.setBoundingRect=function(t){this._rect=t},ol.prototype.getBoundingRect=function(){var t,e=this.style;return this._rect||(null!=(t=e.text)?t+="":t="",(t=$o(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},ol.initDefaultProps=void(ol.prototype.dirtyRectTolerance=10),ol);function ol(){return null!==el&&el.apply(this,arguments)||this}il.prototype.type="tspan";var rl=z({x:0,y:0},Ka),al={style:z({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},$a.style)};u(ul,sl=ts),ul.prototype.createStyle=function(t){return zt(rl,t)},ul.prototype._getSize=function(t){var e,n=this.style,i=n[t];return null!=i?i:(i=(i=n.image)&&"string"!=typeof i&&i.width&&i.height?n.image:this.__image)?null==(e=n[n="width"===t?"height":"width"])?i[t]:i[t]/i[n]*e:0},ul.prototype.getWidth=function(){return this._getSize("width")},ul.prototype.getHeight=function(){return this._getSize("height")},ul.prototype.getAnimationStyleProps=function(){return al},ul.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new U(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect};var sl,ll=ul;function ul(){return null!==sl&&sl.apply(this,arguments)||this}ll.prototype.type="image";var hl=Math.round;function cl(t,e,n){var i,o,r;if(e)return 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)&&(hl(2*i)===hl(2*o)&&(t.x1=t.x2=dl(i,n,!0)),hl(2*r)===hl(2*e))&&(t.y1=t.y2=dl(r,n,!0)),t}function pl(t,e,n){var i,o,r;if(e)return 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)&&(t.x=dl(i,n,!0),t.y=dl(o,n,!0),t.width=Math.max(dl(i+r,n,!1)-t.x,0===r?0:1),t.height=Math.max(dl(o+e,n,!1)-t.y,0===e?0:1)),t}function dl(t,e,n){var i;return e?((i=hl(2*t))+hl(e))%2==0?i/2:(i+(n?1:-1))/2:t}var gl,fl=function(){this.x=0,this.y=0,this.width=0,this.height=0},yl={},L=(u(ml,gl=q),ml.prototype.getDefaultShape=function(){return new fl},ml.prototype.buildPath=function(t,e){var n,i,o,r,a,s,l,u,h,c,p,d,g,f;this.subPixelOptimize?(n=(a=pl(yl,e,this.style)).x,i=a.y,o=a.width,r=a.height,a.r=e.r,e=a):(n=e.x,i=e.y,o=e.width,r=e.height),e.r?(a=t,p=(e=e).x,d=e.y,g=e.width,f=e.height,e=e.r,g<0&&(p+=g,g=-g),f<0&&(d+=f,f=-f),"number"==typeof e?s=l=u=h=e:e instanceof Array?1===e.length?s=l=u=h=e[0]:2===e.length?(s=u=e[0],l=h=e[1]):3===e.length?(s=e[0],l=h=e[1],u=e[2]):(s=e[0],l=e[1],u=e[2],h=e[3]):s=l=u=h=0,g<s+l&&(s*=g/(c=s+l),l*=g/c),g<u+h&&(u*=g/(c=u+h),h*=g/c),f<l+u&&(l*=f/(c=l+u),u*=f/c),f<s+h&&(s*=f/(c=s+h),h*=f/c),a.moveTo(p+s,d),a.lineTo(p+g-l,d),0!==l&&a.arc(p+g-l,d+l,l,-Math.PI/2,0),a.lineTo(p+g,d+f-u),0!==u&&a.arc(p+g-u,d+f-u,u,0,Math.PI/2),a.lineTo(p+h,d+f),0!==h&&a.arc(p+h,d+f-h,h,Math.PI/2,Math.PI),a.lineTo(p,d+s),0!==s&&a.arc(p+s,d+s,s,Math.PI,1.5*Math.PI)):t.rect(n,i,o,r)},ml.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},ml);function ml(t){return gl.call(this,t)||this}L.prototype.type="rect";var vl,xl={fill:"#000"},_l={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},$a.style)},K=(u(bl,vl=ts),bl.prototype.childrenRef=function(){return this._children},bl.prototype.update=function(){vl.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}},bl.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):vl.prototype.updateTransform.call(this)},bl.prototype.getLocalTransform=function(t){var e=this.innerTransformable;return e?e.getLocalTransform(t):vl.prototype.getLocalTransform.call(this,t)},bl.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),vl.prototype.getComputedTransform.call(this)},bl.prototype._updateSubTexts=function(){var t;this._childCursor=0,Dl(t=this.style),nt(t.rich,Dl),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},bl.prototype.addSelfToZr=function(t){vl.prototype.addSelfToZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].__zr=t},bl.prototype.removeSelfFromZr=function(t){vl.prototype.removeSelfFromZr.call(this,t);for(var e=0;e<this._children.length;e++)this._children[e].__zr=null},bl.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new U(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},bl.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||xl},bl.prototype.setTextContent=function(t){},bl.prototype._mergeStyle=function(t,e){var n,i;return e&&(n=e.rich,i=t.rich||n&&{},F(t,e),n&&i?(this._mergeRich(i,n),t.rich=i):i&&(t.rich=i)),t},bl.prototype._mergeRich=function(t,e){for(var n=W(e),i=0;i<n.length;i++){var o=n[i];t[o]=t[o]||{},F(t[o],e[o])}},bl.prototype.getAnimationStyleProps=function(){return _l},bl.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},bl.prototype._updatePlainTexts=function(){for(var t,e=this.style,n=e.font||J,i=e.padding,o=function(t,e){null!=t&&(t+="");var n,i=e.overflow,o=e.padding,r=e.font,a="truncate"===i,s=tr(r),l=N(e.lineHeight,s),u=!!e.backgroundColor,h="truncate"===e.lineOverflow,c=e.width,i=(n=null==c||"break"!==i&&"breakAll"!==i?t?t.split("\n"):[]:t?Za(t,e.font,c,"breakAll"===i,0).lines:[]).length*l,p=N(e.height,i);if(p<i&&h&&(h=Math.floor(p/l),n=n.slice(0,h)),t&&a&&null!=c)for(var d=Ba(c,r,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),g=0;g<n.length;g++)n[g]=Fa(n[g],d);for(var h=p,f=0,g=0;g<n.length;g++)f=Math.max(qo(n[g],r),f);return null==c&&(c=f),t=f,o&&(h+=o[0]+o[2],t+=o[1]+o[3],c+=o[1]+o[3]),{lines:n,height:p,outerWidth:t=u?c:t,outerHeight:h,lineHeight:l,calculatedLineHeight:s,contentWidth:f,contentHeight:i,width:c}}(Pl(e),e),r=Ol(e),a=!!e.backgroundColor,s=o.outerHeight,l=o.outerWidth,u=o.contentWidth,h=o.lines,c=o.lineHeight,p=this._defaultStyle,d=e.x||0,g=e.y||0,f=e.align||p.align||"left",y=e.verticalAlign||p.verticalAlign||"top",m=d,v=Qo(g,o.contentHeight,y),x=((r||i)&&(t=Jo(d,l,f),g=Qo(g,s,y),r)&&this._renderBackground(e,e,t,g,l,s),v+=c/2,i&&(m=Ll(d,f,i),"top"===y?v+=i[0]:"bottom"===y&&(v-=i[2])),0),r=!1,_=(kl(("fill"in e?e:(r=!0,p)).fill)),b=(Al("stroke"in e?e.stroke:a||p.autoStroke&&!r?null:(x=2,p.stroke))),w=0<e.textShadowBlur,S=null!=e.width&&("truncate"===e.overflow||"break"===e.overflow||"breakAll"===e.overflow),M=o.calculatedLineHeight,I=0;I<h.length;I++){var T=this._getOrCreateChild(il),C=T.createStyle();T.useStyle(C),C.text=h[I],C.x=m,C.y=v,f&&(C.textAlign=f),C.textBaseline="middle",C.opacity=e.opacity,C.strokeFirst=!0,w&&(C.shadowBlur=e.textShadowBlur||0,C.shadowColor=e.textShadowColor||"transparent",C.shadowOffsetX=e.textShadowOffsetX||0,C.shadowOffsetY=e.textShadowOffsetY||0),C.stroke=b,C.fill=_,b&&(C.lineWidth=e.lineWidth||x,C.lineDash=e.lineDash,C.lineDashOffset=e.lineDashOffset||0),C.font=n,Tl(C,e),v+=c,S&&T.setBoundingRect(new U(Jo(C.x,e.width,C.textAlign),Qo(C.y,M,C.textBaseline),u,M))}},bl.prototype._updateRichTexts=function(){for(var t=this.style,e=Ya(Pl(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,a=Jo(a,i,u),u=Qo(s,o,l),h=a,c=u,p=(r&&(h+=r[3],c+=r[0]),h+n),d=(Ol(t)&&this._renderBackground(t,t,a,u,i,o),!!t.backgroundColor),g=0;g<e.lines.length;g++){for(var f=e.lines[g],y=f.tokens,m=y.length,v=f.lineHeight,x=f.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}},bl.prototype._placeToken=function(t,e,n,i,o,r,a){var s=e.rich[t.styleName]||{},l=(s.text=t.text,t.verticalAlign),u=i+n/2;"top"===l?u=i+t.height/2:"bottom"===l&&(u=i+n-t.height/2);!t.isLineHolder&&Ol(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 l=!!s.backgroundColor,i=t.textPadding,n=(i&&(o=Ll(o,r,i),u-=t.height/2-i[0]-t.innerHeight/2),this._getOrCreateChild(il)),i=n.createStyle(),h=(n.useStyle(i),this._defaultStyle),c=!1,p=0,d=kl(("fill"in s?s:"fill"in e?e:(c=!0,h)).fill),l=Al("stroke"in s?s.stroke:"stroke"in e?e.stroke:l||a||h.autoStroke&&!c?null:(p=2,h.stroke)),a=0<s.textShadowBlur||0<e.textShadowBlur,c=(i.text=t.text,i.x=o,i.y=u,a&&(i.shadowBlur=s.textShadowBlur||e.textShadowBlur||0,i.shadowColor=s.textShadowColor||e.textShadowColor||"transparent",i.shadowOffsetX=s.textShadowOffsetX||e.textShadowOffsetX||0,i.shadowOffsetY=s.textShadowOffsetY||e.textShadowOffsetY||0),i.textAlign=r,i.textBaseline="middle",i.font=t.font||J,i.opacity=St(s.opacity,e.opacity,1),Tl(i,s),l&&(i.lineWidth=St(s.lineWidth,e.lineWidth,p),i.lineDash=N(s.lineDash,e.lineDash),i.lineDashOffset=e.lineDashOffset||0,i.stroke=l),d&&(i.fill=d),t.contentWidth),h=t.contentHeight;n.setBoundingRect(new U(Jo(i.x,c,i.textAlign),Qo(i.y,h,i.textBaseline),c,h))},bl.prototype._renderBackground=function(t,e,n,i,o,r){var a,s,l,u,h=t.backgroundColor,c=t.borderWidth,p=t.borderColor,d=h&&h.image,g=h&&!d,f=t.borderRadius,y=this,f=((g||t.lineHeight||c&&p)&&((a=this._getOrCreateChild(L)).useStyle(a.createStyle()),a.style.fill=null,(l=a.shape).x=n,l.y=i,l.width=o,l.height=r,l.r=f,a.dirtyShape()),g?((u=a.style).fill=h||null,u.fillOpacity=N(t.fillOpacity,1)):d&&((s=this._getOrCreateChild(ll)).onload=function(){y.dirtyStyle()},(l=s.style).image=h.image,l.x=n,l.y=i,l.width=o,l.height=r),c&&p&&((u=a.style).lineWidth=c,u.stroke=p,u.strokeOpacity=N(t.strokeOpacity,1),u.lineDash=t.borderDash,u.lineDashOffset=t.borderDashOffset||0,a.strokeContainThreshold=0,a.hasFill())&&a.hasStroke()&&(u.strokeFirst=!0,u.lineWidth*=2),(a||s).style);f.shadowBlur=t.shadowBlur||0,f.shadowColor=t.shadowColor||"transparent",f.shadowOffsetX=t.shadowOffsetX||0,f.shadowOffsetY=t.shadowOffsetY||0,f.opacity=St(t.opacity,e.opacity,1)},bl.makeFont=function(t){var e="";return(e=Cl(t)?[t.fontStyle,t.fontWeight,Il(t.fontSize),t.fontFamily||"sans-serif"].join(" "):e)&&Ct(e)||t.textFont||t.font},bl);function bl(t){var e=vl.call(this)||this;return e.type="text",e._children=[],e._defaultStyle=xl,e.attr(t),e}var wl={left:!0,right:1,center:1},Sl={top:1,bottom:1,middle:1},Ml=["fontStyle","fontWeight","fontSize","fontFamily"];function Il(t){return"string"!=typeof t||-1===t.indexOf("px")&&-1===t.indexOf("rem")&&-1===t.indexOf("em")?isNaN(+t)?l+"px":t+"px":t}function Tl(t,e){for(var n=0;n<Ml.length;n++){var i=Ml[n],o=e[i];null!=o&&(t[i]=o)}}function Cl(t){return null!=t.fontSize||t.fontFamily||t.fontWeight}function Dl(t){var e;t&&(t.font=K.makeFont(t),e=t.align,t.align=null==(e="middle"===e?"center":e)||wl[e]?e:"left",e=t.verticalAlign,t.verticalAlign=null==(e="center"===e?"middle":e)||Sl[e]?e:"top",t.padding)&&(t.padding=It(t.padding))}function Al(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function kl(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function Ll(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function Pl(t){t=t.text;return null!=t&&(t+=""),t}function Ol(t){return!!(t.backgroundColor||t.lineHeight||t.borderWidth&&t.borderColor)}function Nl(e,n,i,t){var o;t&&((o=$(t)).dataIndex=i,o.dataType=n,o.seriesIndex=e,o.ssrType="chart","group"===t.type)&&t.traverse(function(t){t=$(t);t.seriesIndex=e,t.dataIndex=i,t.dataType=n,t.ssrType="chart"})}var $=i(),Rl=1,El={},zl=i(),Vl=i(),Bl=0,Fl=1,Gl=2,Wl=["emphasis","blur","select"],Hl=["normal","emphasis","blur","select"],Yl="highlight",Xl="downplay",Ul="select",Zl="unselect",jl="toggleSelect";function ql(t){return null!=t&&"none"!==t}function Kl(t,e,n){t.onHoverStateChange&&(t.hoverState||0)!==n&&t.onHoverStateChange(e),t.hoverState=n}function $l(t){Kl(t,"emphasis",Gl)}function Jl(t){t.hoverState===Gl&&Kl(t,"normal",Bl)}function Ql(t){Kl(t,"blur",Fl)}function tu(t){t.hoverState===Fl&&Kl(t,"normal",Bl)}function eu(t){t.selected=!0}function nu(t){t.selected=!1}function iu(t,e,n){e(t,n)}function ou(t,e,n){iu(t,e,n),t.isGroup&&t.traverse(function(t){iu(t,e,n)})}function ru(t,e){switch(e){case"emphasis":t.hoverState=Gl;break;case"normal":t.hoverState=Bl;break;case"blur":t.hoverState=Fl;break;case"select":t.selected=!0}}function au(t,e,n){var i=0<=G(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.saveTo(r,e)}return r}(t,["opacity"],e,{opacity:1}),e=(n=n||{}).style||{};return null==e.opacity&&(n=F({},n),e=F({opacity:i?o:.1*t.opacity},e),n.style=e),n}function su(t,e){var n,i,o,r,a,s=this.states[t];if(this.style){if("emphasis"===t)return n=this,i=s,e=(e=e)&&0<=G(e,"select"),a=!1,n instanceof q&&(o=zl(n),r=e&&o.selectFill||o.normalFill,e=e&&o.selectStroke||o.normalStroke,ql(r)||ql(e))&&("inherit"===(o=(i=i||{}).style||{}).fill?(a=!0,i=F({},i),(o=F({},o)).fill=r):!ql(o.fill)&&ql(r)?(a=!0,i=F({},i),(o=F({},o)).fill=Ni(r)):!ql(o.stroke)&&ql(e)&&(a||(i=F({},i),o=F({},o)),o.stroke=Ni(e)),i.style=o),i&&null==i.z2&&(a||(i=F({},i)),r=n.z2EmphasisLift,i.z2=n.z2+(null!=r?r:10)),i;if("blur"===t)return au(this,t,s);if("select"===t)return e=this,(o=s)&&null==o.z2&&(o=F({},o),a=e.z2SelectLift,o.z2=e.z2+(null!=a?a:9)),o}return s}function lu(t){t.stateProxy=su;var e=t.getTextContent(),t=t.getTextGuideLine();e&&(e.stateProxy=su),t&&(t.stateProxy=su)}function uu(t,e){mu(t,e)||t.__highByOuter||ou(t,$l)}function hu(t,e){mu(t,e)||t.__highByOuter||ou(t,Jl)}function cu(t,e){t.__highByOuter|=1<<(e||0),ou(t,$l)}function pu(t,e){(t.__highByOuter&=~(1<<(e||0)))||ou(t,Jl)}function du(t){ou(t,Ql)}function gu(t){ou(t,tu)}function fu(t){ou(t,eu)}function yu(t){ou(t,nu)}function mu(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function vu(o){var e=o.getModel(),r=[],a=[];e.eachComponent(function(t,e){var n=Vl(e),t="series"===t,i=t?o.getViewOfSeriesModel(e):o.getViewOfComponentModel(e);t||a.push(i),n.isBlured&&(i.group.traverse(function(t){tu(t)}),t)&&r.push(e),n.isBlured=!1}),nt(a,function(t){t&&t.toggleBlurSeries&&t.toggleBlurSeries(r,!1,e)})}function xu(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&&gu(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,n=(n=n&&n.master?n.master:n)&&u?n===u:e;if(!("series"===a&&!e||"coordinateSystem"===a&&!n||"series"===r&&e)){if(s.getViewOfSeriesModel(t).group.traverse(function(t){t.__highByOuter&&e&&"self"===r||Ql(t)}),ht(r))c(t.getData(),r);else if(O(r))for(var i=W(r),o=0;o<i.length;o++)c(t.getData(i[o]),r[i[o]]);h.push(t),Vl(t).isBlured=!0}}),n.eachComponent(function(t,e){"series"!==t&&(t=s.getViewOfComponentModel(e))&&t.toggleBlurSeries&&t.toggleBlurSeries(h,!0,n)}))}function _u(t,e,n){var i;null!=t&&null!=e&&(t=n.getModel().getComponent(t,e))&&(Vl(t).isBlured=!0,i=n.getViewOfComponentModel(t))&&i.focusBlurEnabled&&i.group.traverse(function(t){Ql(t)})}function bu(t,e,n,i){var o={focusSelf:!1,dispatchers:null};if(null==t||"series"===t||null==e||null==n)return o;t=i.getModel().getComponent(t,e);if(!t)return o;e=i.getViewOfComponentModel(t);if(!e||!e.findHighDownDispatchers)return o;for(var r,a=e.findHighDownDispatchers(n),s=0;s<a.length;s++)if("self"===$(a[s]).focus){r=!0;break}return{focusSelf:r,dispatchers:a}}function wu(i){nt(i.getAllData(),function(t){var e=t.data,n=t.type;e.eachItemGraphicEl(function(t,e){(i.isSelected(e,n)?fu:yu)(t)})})}function Su(t,e,n){Au(t,!0),ou(t,lu),Iu(t,e,n)}function Mu(t,e,n,i){i?Au(t,!1):Su(t,e,n)}function Iu(t,e,n){t=$(t);null!=e?(t.focus=e,t.blurScope=n):t.focus&&(t.focus=null)}var Tu=["emphasis","blur","select"],Cu={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function Du(t,e,n,i){n=n||"itemStyle";for(var o=0;o<Tu.length;o++){var r=Tu[o],a=e.getModel([r,n]);t.ensureState(r).style=i?i(a):a[Cu[n]]()}}function Au(t,e){var e=!1===e,n=t;t.highDownSilentOnTouch&&(n.__highDownSilentOnTouch=t.highDownSilentOnTouch),e&&!n.__highDownDispatcher||(n.__highByOuter=n.__highByOuter||0,n.__highDownDispatcher=!e)}function ku(t){return!(!t||!t.__highDownDispatcher)}function Lu(t){t=t.type;return t===Ul||t===Zl||t===jl}function Pu(t){t=t.type;return t===Yl||t===Xl}var Ou=Ns.CMD,Nu=[[],[],[]],Ru=Math.sqrt,Eu=Math.atan2;var zu=Math.sqrt,Vu=Math.sin,Bu=Math.cos,Fu=Math.PI;function Gu(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function Wu(t,e){return(t[0]*e[0]+t[1]*e[1])/(Gu(t)*Gu(e))}function Hu(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(Wu(t,e))}function Yu(t,e,n,i,o,r,a,s,l,u,h){var l=l*(Fu/180),c=Bu(l)*(t-n)/2+Vu(l)*(e-i)/2,p=-1*Vu(l)*(t-n)/2+Bu(l)*(e-i)/2,d=c*c/(a*a)+p*p/(s*s),d=(1<d&&(a*=zu(d),s*=zu(d)),(o===r?-1:1)*zu((a*a*(s*s)-a*a*(p*p)-s*s*(c*c))/(a*a*(p*p)+s*s*(c*c)))||0),o=d*a*p/s,d=d*-s*c/a,t=(t+n)/2+Bu(l)*o-Vu(l)*d,n=(e+i)/2+Vu(l)*o+Bu(l)*d,e=Hu([1,0],[(c-o)/a,(p-d)/s]),i=[(c-o)/a,(p-d)/s],c=[(-1*c-o)/a,(-1*p-d)/s],o=Hu(i,c);Wu(i,c)<=-1&&(o=Fu),(o=1<=Wu(i,c)?0:o)<0&&(p=Math.round(o/Fu*1e6)/1e6,o=2*Fu+p%2*Fu),h.addData(u,t,n,a,s,e,o,l,r)}var Xu=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,Uu=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;u(qu,Zu=q),qu.prototype.applyTransform=function(t){};var Zu,ju=qu;function qu(){return null!==Zu&&Zu.apply(this,arguments)||this}function Ku(t){return null!=t.setData}function $u(t,e){var S=function(t){var e=new Ns;if(t){var n,i=0,o=0,r=i,a=o,s=Ns.CMD,l=t.match(Xu);if(l){for(var u=0;u<l.length;u++){for(var h=l[u],c=h.charAt(0),p=void 0,d=h.match(Uu)||[],g=d.length,f=0;f<g;f++)d[f]=parseFloat(d[f]);for(var y=0;y<g;){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++],Yu(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++],Yu(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}e.toStatic()}}return e}(t),t=F({},e);return t.buildPath=function(t){var e;Ku(t)?(t.setData(S.data),(e=t.getContext())&&t.rebuildPath(e,1)):S.rebuildPath(e=t,1)},t.applyTransform=function(t){var e=S,n=t;if(n){for(var i,o,r,a,s=e.data,l=e.len(),u=Ou.M,h=Ou.C,c=Ou.L,p=Ou.R,d=Ou.A,g=Ou.Q,f=0,y=0;f<l;){switch(i=s[f++],y=f,o=0,i){case u:case c:o=1;break;case h:o=3;break;case g:o=2;break;case d:var m=n[4],v=n[5],x=Ru(n[0]*n[0]+n[1]*n[1]),_=Ru(n[2]*n[2]+n[3]*n[3]),b=Eu(-n[1]/_,n[0]/x);s[f]*=x,s[f++]+=m,s[f]*=_,s[f++]+=v,s[f++]*=x,s[f++]*=_,s[f++]+=b,s[f++]+=b,y=f+=2;break;case p:a[0]=s[f++],a[1]=s[f++],oe(a,a,n),s[y++]=a[0],s[y++]=a[1],a[0]+=s[f++],a[1]+=s[f++],oe(a,a,n),s[y++]=a[0],s[y++]=a[1]}for(r=0;r<o;r++){var w=Nu[r];w[0]=s[f++],w[1]=s[f++],oe(w,w,n),s[y++]=w[0],s[y++]=w[1]}}e.increaseVersion()}this.dirtyShape()},t}function Ju(t,e){return new ju($u(t,e))}var Qu,th=function(){this.cx=0,this.cy=0,this.r=0},eh=(u(nh,Qu=q),nh.prototype.getDefaultShape=function(){return new th},nh.prototype.buildPath=function(t,e){t.moveTo(e.cx+e.r,e.cy),t.arc(e.cx,e.cy,e.r,0,2*Math.PI)},nh);function nh(t){return Qu.call(this,t)||this}eh.prototype.type="circle";var ih,oh=function(){this.cx=0,this.cy=0,this.rx=0,this.ry=0},rh=(u(ah,ih=q),ah.prototype.getDefaultShape=function(){return new oh},ah.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=e.rx,e=e.ry,r=.5522848*o,a=.5522848*e;t.moveTo(n-o,i),t.bezierCurveTo(n-o,i-a,n-r,i-e,n,i-e),t.bezierCurveTo(n+r,i-e,n+o,i-a,n+o,i),t.bezierCurveTo(n+o,i+a,n+r,i+e,n,i+e),t.bezierCurveTo(n-r,i+e,n-o,i+a,n-o,i),t.closePath()},ah);function ah(t){return ih.call(this,t)||this}rh.prototype.type="ellipse";var sh=Math.PI,lh=2*sh,uh=Math.sin,hh=Math.cos,ch=Math.acos,ph=Math.atan2,dh=Math.abs,gh=Math.sqrt,fh=Math.max,yh=Math.min,mh=1e-4;function vh(t,e,n,i,o,r,a){var s=t-n,l=e-i,a=(a?r:-r)/gh(s*s+l*l),l=a*l,a=-a*s,s=t+l,t=e+a,e=n+l,n=i+a,i=(s+e)/2,u=(t+n)/2,h=e-s,c=n-t,p=h*h+c*c,r=o-r,s=s*n-e*t,n=(c<0?-1:1)*gh(fh(0,r*r*p-s*s)),e=(s*c-h*n)/p,t=(-s*h-c*n)/p,d=(s*c+h*n)/p,s=(-s*h+c*n)/p,h=e-i,c=t-u,n=d-i,p=s-u;return n*n+p*p<h*h+c*c&&(e=d,t=s),{cx:e,cy:t,x0:-l,y0:-a,x1:e*(o/r-1),y1:t*(o/r-1)}}function xh(t,e){var n,i,o,r,a,s,l,u,h,c,p,d,g,f,y,m,v,x,_,b,w,S,M,I,T,C,D,A,k,L,P=fh(e.r,0),O=fh(e.r0||0,0),N=0<P;(N||0<O)&&(N||(P=O,O=0),P<O&&(N=P,P=O,O=N),N=e.startAngle,n=e.endAngle,isNaN(N)||isNaN(n)||(i=e.cx,o=e.cy,r=!!e.clockwise,m=dh(n-N),mh<(a=lh<m&&m%lh)&&(m=a),mh<P?lh-mh<m?(t.moveTo(i+P*hh(N),o+P*uh(N)),t.arc(i,o,P,N,n,!r),mh<O&&(t.moveTo(i+O*hh(n),o+O*uh(n)),t.arc(i,o,O,n,N,r))):(S=w=b=_=x=v=c=h=C=T=I=M=u=l=s=a=void 0,p=P*hh(N),d=P*uh(N),g=O*hh(n),f=O*uh(n),(y=mh<m)&&((e=e.cornerRadius)&&(a=(e=function(t){if(B(t)){var e=t.length;if(!e)return t;e=1===e?[t[0],t[0],0,0]:2===e?[t[0],t[0],t[1],t[1]]:3===e?t.concat(t[2]):t}else e=[t,t,t,t];return e}(e))[0],s=e[1],l=e[2],u=e[3]),e=dh(P-O)/2,M=yh(e,l),I=yh(e,u),T=yh(e,a),C=yh(e,s),v=h=fh(M,I),x=c=fh(T,C),mh<h||mh<c)&&(_=P*hh(n),b=P*uh(n),w=O*hh(N),S=O*uh(N),m<sh)&&(e=function(t,e,n,i,o,r,a,s){var l=(s=s-r)*(n=n-t)-(a=a-o)*(i=i-e);if(!(l*l<mh))return[t+(l=(a*(e-r)-s*(t-o))/l)*n,e+l*i]}(p,d,w,S,_,b,g,f))&&(M=p-e[0],I=d-e[1],T=_-e[0],C=b-e[1],m=1/uh(ch((M*T+I*C)/(gh(M*M+I*I)*gh(T*T+C*C)))/2),M=gh(e[0]*e[0]+e[1]*e[1]),v=yh(h,(P-M)/(1+m)),x=yh(c,(O-M)/(m-1))),y?mh<v?(D=yh(l,v),A=yh(u,v),k=vh(w,S,p,d,P,D,r),L=vh(_,b,g,f,P,A,r),t.moveTo(i+k.cx+k.x0,o+k.cy+k.y0),v<h&&D===A?t.arc(i+k.cx,o+k.cy,v,ph(k.y0,k.x0),ph(L.y0,L.x0),!r):(0<D&&t.arc(i+k.cx,o+k.cy,D,ph(k.y0,k.x0),ph(k.y1,k.x1),!r),t.arc(i,o,P,ph(k.cy+k.y1,k.cx+k.x1),ph(L.cy+L.y1,L.cx+L.x1),!r),0<A&&t.arc(i+L.cx,o+L.cy,A,ph(L.y1,L.x1),ph(L.y0,L.x0),!r))):(t.moveTo(i+p,o+d),t.arc(i,o,P,N,n,!r)):t.moveTo(i+p,o+d),mh<O&&y?mh<x?(D=yh(a,x),k=vh(g,f,_,b,O,-(A=yh(s,x)),r),L=vh(p,d,w,S,O,-D,r),t.lineTo(i+k.cx+k.x0,o+k.cy+k.y0),x<c&&D===A?t.arc(i+k.cx,o+k.cy,x,ph(k.y0,k.x0),ph(L.y0,L.x0),!r):(0<A&&t.arc(i+k.cx,o+k.cy,A,ph(k.y0,k.x0),ph(k.y1,k.x1),!r),t.arc(i,o,O,ph(k.cy+k.y1,k.cx+k.x1),ph(L.cy+L.y1,L.cx+L.x1),r),0<D&&t.arc(i+L.cx,o+L.cy,D,ph(L.y1,L.x1),ph(L.y0,L.x0),!r))):(t.lineTo(i+g,o+f),t.arc(i,o,O,n,N,r)):t.lineTo(i+g,o+f)):t.moveTo(i,o),t.closePath()))}var _h,bh=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},wh=(u(Sh,_h=q),Sh.prototype.getDefaultShape=function(){return new bh},Sh.prototype.buildPath=function(t,e){xh(t,e)},Sh.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},Sh);function Sh(t){return _h.call(this,t)||this}wh.prototype.type="sector";var Mh,Ih=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},Th=(u(Ch,Mh=q),Ch.prototype.getDefaultShape=function(){return new Ih},Ch.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)},Ch);function Ch(t){return Mh.call(this,t)||this}function Dh(t,e,n){var i=e.smooth,o=e.points;if(o&&2<=o.length){if(i)for(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++)re(h,h,t[p]),ae(c,c,t[p]);re(h,h,i[0]),ae(c,c,i[1])}for(p=0,d=t.length;p<d;p++){var g=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(Yt(t[p]));continue}o=t[p-1],r=t[p+1]}jt(s,r,o),$t(s,s,e);var f=Qt(g,o),y=Qt(g,r),m=f+y,m=(0!==m&&(f/=m,y/=m),$t(l,s,-f),$t(u,s,y),Ut([],g,l)),f=Ut([],g,u);i&&(ae(m,m,h),re(m,m,c),ae(f,f,h),re(f,f,c)),a.push(m),a.push(f)}return n&&a.push(a.shift()),a}(o,i,n,e.smoothConstraint),a=(t.moveTo(o[0][0],o[0][1]),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{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()}}Th.prototype.type="ring";var Ah,kh=function(){this.points=null,this.smooth=0,this.smoothConstraint=null},Lh=(u(Ph,Ah=q),Ph.prototype.getDefaultShape=function(){return new kh},Ph.prototype.buildPath=function(t,e){Dh(t,e,!0)},Ph);function Ph(t){return Ah.call(this,t)||this}Lh.prototype.type="polygon";var Oh,Nh=function(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null},Rh=(u(Eh,Oh=q),Eh.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Eh.prototype.getDefaultShape=function(){return new Nh},Eh.prototype.buildPath=function(t,e){Dh(t,e,!1)},Eh);function Eh(t){return Oh.call(this,t)||this}Rh.prototype.type="polyline";var zh,Vh={},Bh=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1},Fh=(u(Gh,zh=q),Gh.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Gh.prototype.getDefaultShape=function(){return new Bh},Gh.prototype.buildPath=function(t,e){r=(this.subPixelOptimize?(n=(r=cl(Vh,e,this.style)).x1,i=r.y1,o=r.x2,r):(n=e.x1,i=e.y1,o=e.x2,e)).y2;var n,i,o,r,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))},Gh.prototype.pointAt=function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]},Gh);function Gh(t){return zh.call(this,t)||this}Fh.prototype.type="line";var Wh=[],Hh=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1};function Yh(t,e,n){var i=t.cpx2,o=t.cpy2;return null!=i||null!=o?[(n?Un:Xn)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?Un:Xn)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?Jn:$n)(t.x1,t.cpx1,t.x2,e),(n?Jn:$n)(t.y1,t.cpy1,t.y2,e)]}u(Zh,Xh=q),Zh.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Zh.prototype.getDefaultShape=function(){return new Hh},Zh.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&&(ti(n,a,o,e,Wh),a=Wh[1],o=Wh[2],ti(i,s,r,e,Wh),s=Wh[1],r=Wh[2]),t.quadraticCurveTo(a,s,o,r)):(e<1&&(qn(n,a,l,o,e,Wh),a=Wh[1],l=Wh[2],o=Wh[3],qn(i,s,u,r,e,Wh),s=Wh[1],u=Wh[2],r=Wh[3]),t.bezierCurveTo(a,s,l,u,o,r)))},Zh.prototype.pointAt=function(t){return Yh(this.shape,t,!1)},Zh.prototype.tangentAt=function(t){t=Yh(this.shape,t,!0);return Jt(t,t)};var Xh,Uh=Zh;function Zh(t){return Xh.call(this,t)||this}Uh.prototype.type="bezier-curve";var jh,qh=function(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},Kh=(u($h,jh=q),$h.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},$h.prototype.getDefaultShape=function(){return new qh},$h.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,o=Math.max(e.r,0),r=e.startAngle,a=e.endAngle,e=e.clockwise,s=Math.cos(r),l=Math.sin(r);t.moveTo(s*o+n,l*o+i),t.arc(n,i,o,r,a,!e)},$h);function $h(t){return jh.call(this,t)||this}Kh.prototype.type="arc";u(tc,Jh=q),tc.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()},tc.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)},tc.prototype.buildPath=function(t,e){for(var n=e.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},tc.prototype.afterBrush=function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].pathUpdated()},tc.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),q.prototype.getBoundingRect.call(this)};var Jh,Qh=tc;function tc(){var t=null!==Jh&&Jh.apply(this,arguments)||this;return t.type="compound",t}ec.prototype.addColorStop=function(t,e){this.colorStops.push({offset:t,color:e})};e=ec;function ec(t){this.colorStops=t||[]}u(oc,nc=e);var nc,ic=oc;function oc(t,e,n,i,o,r){o=nc.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}u(sc,rc=e);var rc,ac=sc;function sc(t,e,n,i,o){i=rc.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}var lc=[0,0],uc=[0,0],hc=new E,cc=new E,pc=(dc.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);E.sub(i[0],n[1],n[0]),E.sub(i[1],n[3],n[0]),i[0].normalize(),i[1].normalize();for(s=0;s<2;s++)this._origin[s]=i[s].dot(n[0])},dc.prototype.intersect=function(t,e){var n=!0,i=!e;return hc.set(1/0,1/0),cc.set(0,0),!this._intersectCheckOneSide(this,t,hc,cc,i,1)&&(n=!1,i)||!this._intersectCheckOneSide(t,this,hc,cc,i,-1)&&(n=!1,i)||i||E.copy(e,n?hc:cc),n},dc.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,lc),this._getProjMinMaxOnAxis(s,e._corners,uc),lc[1]<uc[0]||uc[1]<lc[0]){if(a=!1,o)return a;var u=Math.abs(uc[0]-lc[1]),h=Math.abs(lc[0]-uc[1]);Math.min(u,h)>i.len()&&(u<h?E.scale(i,l,-u*r):E.scale(i,l,h*r))}else n&&(u=Math.abs(uc[0]-lc[1]),h=Math.abs(lc[0]-uc[1]),Math.min(u,h)<n.len())&&(u<h?E.scale(n,l,u*r):E.scale(n,l,-h*r))}return a},dc.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},dc);function dc(t,e){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new E;for(n=0;n<2;n++)this._axes[n]=new E;t&&this.fromBoundingRect(t,e)}var gc,fc=[],e=(u(yc,gc=ts),yc.prototype.traverse=function(t,e){t.call(e,this)},yc.prototype.useStyle=function(){this.style={}},yc.prototype.getCursor=function(){return this._cursor},yc.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},yc.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},yc.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},yc.prototype.addDisplayable=function(t,e){(e?this._temporaryDisplayables:this._displayables).push(t),this.markRedraw()},yc.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},yc.prototype.getDisplayables=function(){return this._displayables},yc.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},yc.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])},yc.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++)(e=this._displayables[t]).parent=this,e.update(),e.parent=null;for(var e,t=0;t<this._temporaryDisplayables.length;t++)(e=this._temporaryDisplayables[t]).parent=this,e.update(),e.parent=null},yc.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new U(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(fc)),t.union(i)}this._rect=t}return this._rect},yc.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},yc);function yc(){var t=null!==gc&&gc.apply(this,arguments)||this;return t.notClear=!0,t.incremental=!0,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}var mc=i();function vc(t,e,n,i,o){var r;e&&e.ecModel&&(r=(r=e.ecModel.getUpdatePayload())&&r.animation);var a,s,l,t="update"===t;return e&&e.isAnimationEnabled()?(l=s=a=void 0,l=i?(a=N(i.duration,200),s=N(i.easing,"cubicOut"),0):(a=e.getShallow(t?"animationDurationUpdate":"animationDuration"),s=e.getShallow(t?"animationEasingUpdate":"animationEasing"),e.getShallow(t?"animationDelayUpdate":"animationDelay")),D(l=r&&(null!=r.duration&&(a=r.duration),null!=r.easing&&(s=r.easing),null!=r.delay)?r.delay:l)&&(l=l(n,o)),{duration:(a=D(a)?a(n):a)||0,delay:l,easing:s}):null}function xc(t,e,n,i,o,r,a){var s=!1,l=(D(o)?(a=r,r=o,o=null):O(o)&&(r=o.cb,a=o.during,s=o.isFrom,u=o.removeOpt,o=o.dataIndex),"leave"===t),u=(l||e.stopAnimation("leave"),vc(t,i,o,l?u||{}:null,i&&i.getAnimationDelayParams?i.getAnimationDelayParams(e,o):null));u&&0<u.duration?(i={duration:u.duration,delay:u.delay||0,easing:u.easing,done:r,force:!!r||!!a,setToFinal:!l,scope:t,during:a},s?e.animateFrom(n,i):e.animateTo(n,i)):(e.stopAnimation(),s||e.attr(n),a&&a(1),r&&r())}function C(t,e,n,i,o,r){xc("update",t,e,n,i,o,r)}function _c(t,e,n,i,o,r){xc("enter",t,e,n,i,o,r)}function bc(t){if(!t.__zr)return!0;for(var e=0;e<t.animators.length;e++)if("leave"===t.animators[e].scope)return!0;return!1}function wc(t,e,n,i,o,r){bc(t)||xc("leave",t,e,n,i,o,r)}function Sc(t,e,n,i){t.removeTextContent(),t.removeTextGuideLine(),wc(t,{style:{opacity:0}},e,n,i)}function Mc(t,e,n){function i(){t.parent&&t.parent.remove(t)}t.isGroup?t.traverse(function(t){t.isGroup||Sc(t,e,n,i)}):Sc(t,e,n,i)}function Ic(t){mc(t).oldStyle=t.style}var Tc=Math.max,Cc=Math.min,Dc={};function Ac(t){return q.extend(t)}var kc=function(t,e){var n,i=$u(t,e);function o(t){t=n.call(this,t)||this;return t.applyTransform=i.applyTransform,t.buildPath=i.buildPath,t}return u(o,n=ju),o};function Lc(t,e){return kc(t,e)}function Pc(t,e){Dc[t]=e}function Oc(t){if(Dc.hasOwnProperty(t))return Dc[t]}function Nc(t,e,n,i){t=Ju(t,e);return n&&("center"===i&&(n=Ec(n,t.getBoundingRect())),Vc(t,n)),t}function Rc(t,e,n){var i=new ll({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(Ec(e,t)))}});return i}function Ec(t,e){var e=e.width/e.height,n=t.height*e,e=n<=t.width?t.height:(n=t.width)/e;return{x:t.x+t.width/2-n/2,y:t.y+t.height/2-e/2,width:n,height:e}}var zc=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 q(e)).createPathProxy(),e.buildPath=function(t){var e;Ku(t)&&(t.appendPath(n),e=t.getContext())&&t.rebuildPath(e,1)},e};function Vc(t,e){t.applyTransform&&(e=t.getBoundingRect().calculateTransform(e),t.applyTransform(e))}function Bc(t,e){return cl(t,t,{lineWidth:e}),t}var Fc=dl;function Gc(t,e){for(var n=Ve([]);t&&t!==e;)Fe(n,t.getLocalTransform(),n),t=t.parent;return n}function Wc(t,e,n){return e&&!ht(e)&&(e=Yo.getLocalTransform(e)),oe([],t,e=n?Ye([],e):e)}function Hc(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]),i=Wc(["left"===t?-i:"right"===t?i:0,"top"===t?-o:"bottom"===t?o:0],e,n);return Math.abs(i[0])>Math.abs(i[1])?0<i[0]?"right":"left":0<i[1]?"bottom":"top"}function Yc(t){return!t.isGroup}function Xc(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=F({},t.shape)),e}t&&e&&(n={},t.traverse(function(t){Yc(t)&&t.anid&&(n[t.anid]=t)}),o=n,e.traverse(function(t){var e,n;Yc(t)&&t.anid&&(e=o[t.anid])&&(n=r(t),t.attr(r(e)),C(t,n,i,$(t).dataIndex))}))}function Uc(t,n){return V(t,function(t){var e=t[0],e=Tc(e,n.x),t=(e=Cc(e,n.x+n.width),t[1]),t=Tc(t,n.y);return[e,Cc(t,n.y+n.height)]})}function Zc(t,e){var n=Tc(t.x,e.x),i=Cc(t.x+t.width,e.x+e.width),o=Tc(t.y,e.y),t=Cc(t.y+t.height,e.y+e.height);if(n<=i&&o<=t)return{x:n,y:o,width:i-n,height:t-o}}function jc(t,e,n){var e=F({rectHover:!0},e),i=e.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(i.image=t.slice(8),z(i,n),new ll(e)):Nc(t.replace("path://",""),e,n,"center")}function qc(t,e,n,i,o){for(var r=0,a=o[o.length-1];r<o.length;r++){var s=o[r];if(Kc(t,e,n,i,s[0],s[1],a[0],a[1]))return!0;a=s}}function Kc(t,e,n,i,o,r,a,s){var l,n=n-t,i=i-e,a=a-o,s=s-r,u=a*i-n*s;return!((l=u)<=1e-6&&-1e-6<=l||(o=((l=t-o)*i-n*(t=e-r))/u)<0||1<o||(i=(l*s-a*t)/u)<0||1<i)}function $c(t){var e=t.itemTooltipOption,n=t.componentModel,i=t.itemName,e=H(e)?{formatter:e}:e,o=n.mainType,n=n.componentIndex,r={componentType:o,name:i,$vars:["name"]},a=(r[o+"Index"]=n,t.formatterParamsExtra),t=(a&&nt(W(a),function(t){X(r,t)||(r[t]=a[t],r.$vars.push(t))}),$(t.el));t.componentMainType=o,t.componentIndex=n,t.tooltipConfig={name:i,option:z({content:i,formatterParams:r},e)}}function Jc(t,e){var n;(n=t.isGroup?e(t):n)||t.traverse(e)}function Qc(t,e){if(t)if(B(t))for(var n=0;n<t.length;n++)Jc(t[n],e);else Jc(t,e)}Pc("circle",eh),Pc("ellipse",rh),Pc("sector",wh),Pc("ring",Th),Pc("polygon",Lh),Pc("polyline",Rh),Pc("rect",L),Pc("line",Fh),Pc("bezierCurve",Uh),Pc("arc",Kh);var tp=Object.freeze({__proto__:null,Arc:Kh,BezierCurve:Uh,BoundingRect:U,Circle:eh,CompoundPath:Qh,Ellipse:rh,Group:Z,Image:ll,IncrementalDisplayable:e,Line:Fh,LinearGradient:ic,OrientedBoundingRect:pc,Path:q,Point:E,Polygon:Lh,Polyline:Rh,RadialGradient:ac,Rect:L,Ring:Th,Sector:wh,Text:K,applyTransform:Wc,clipPointsByRect:Uc,clipRectByRect:Zc,createIcon:jc,extendPath:Lc,extendShape:Ac,getShapeClass:Oc,getTransform:Gc,groupTransition:Xc,initProps:_c,isElementRemoved:bc,lineLineIntersect:Kc,linePolygonIntersect:qc,makeImage:Rc,makePath:Nc,mergePath:zc,registerShape:Pc,removeElement:wc,removeElementWithFadeOut:Mc,resizePath:Vc,setTooltipConfig:$c,subPixelOptimize:Fc,subPixelOptimizeLine:Bc,subPixelOptimizeRect:function(t){return pl(t.shape,t.shape,t.style),t},transformDirection:Hc,traverseElements:Qc,updateProps:C}),ep={};function np(t,e){for(var n=0;n<Wl.length;n++){var i=Wl[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 ip(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)?D(t.defaultText)?t.defaultText(r,t,n):t.defaultText:i},u=0;u<Wl.length;u++){var h=Wl[u],c=e[h];l[h]=N(o?o.getFormattedLabel(r,h,null,a,c&&c.get("formatter")):null,i)}return l}function op(t,e,n,i){n=n||ep;for(var o=t instanceof K,r=!1,a=0;a<Hl.length;a++)if((p=e[Hl[a]])&&p.getShallow("show")){r=!0;break}var s=o?t:t.getTextContent();if(r){o||(s||(s=new K,t.setTextContent(s)),t.stateProxy&&(s.stateProxy=t.stateProxy));var l=ip(n,e),u=e.normal,h=!!u.getShallow("show"),c=ap(u,i&&i.normal,n,!1,!o);c.text=l.normal,o||t.setTextConfig(sp(u,n,!1));for(a=0;a<Wl.length;a++){var p,d,g,f=Wl[a];(p=e[f])&&(d=s.ensureState(f),(g=!!N(p.getShallow("show"),h))!=h&&(d.ignore=!g),d.style=ap(p,i&&i[f],n,!0,!o),d.style.text=l[f],o||(t.ensureState(f).textConfig=sp(p,n,!0)))}s.silent=!!u.getShallow("silent"),null!=s.style.x&&(c.x=s.style.x),null!=s.style.y&&(c.y=s.style.y),s.ignore=!h,s.useStyle(c),s.dirty(),n.enableTextSetter&&(dp(s).setLabelText=function(t){t=ip(n,e,t);np(s,t)})}else s&&(s.ignore=!0);t.dirty()}function rp(t,e){for(var n={normal:t.getModel(e=e||"label")},i=0;i<Wl.length;i++){var o=Wl[i];n[o]=t.getModel([o,e])}return n}function ap(t,e,n,i,o){var r,a={},s=a,l=t,u=n,h=i,c=o;u=u||ep;var p,t=l.ecModel,d=t&&t.option.textStyle,g=function(t){var e;for(;t&&t!==t.ecModel;){var n=(t.option||ep).rich;if(n){e=e||{};for(var i=W(n),o=0;o<i.length;o++){var r=i[o];e[r]=1}}t=t.parentModel}return e}(l);if(g)for(var f in p={},g)g.hasOwnProperty(f)&&(r=l.getModel(["rich",f]),cp(p[f]={},r,d,u,h,c,!1,!0));return p&&(s.rich=p),(t=l.get("overflow"))&&(s.overflow=t),null!=(t=l.get("minMargin"))&&(s.margin=t),cp(s,l,d,u,h,c,!0,!1),e&&F(a,e),a}function sp(t,e,n){e=e||{};var i={},o=t.getShallow("rotate"),r=N(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 lp=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],up=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],hp=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function cp(t,e,n,i,o,r,a,s){n=!o&&n||ep;var l=i&&i.inheritColor,u=e.getShallow("color"),h=e.getShallow("textBorderColor"),c=N(e.getShallow("opacity"),n.opacity),u=("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),N(e.getShallow("textBorderWidth"),n.textBorderWidth)),h=(null!=u&&(t.lineWidth=u),N(e.getShallow("textBorderType"),n.textBorderType)),u=(null!=h&&(t.lineDash=h),N(e.getShallow("textBorderDashOffset"),n.textBorderDashOffset));null!=u&&(t.lineDashOffset=u),null!=(c=o||null!=c||s?c:i&&i.defaultOpacity)&&(t.opacity=c),o||r||null==t.fill&&i.inheritColor&&(t.fill=i.inheritColor);for(var p=0;p<lp.length;p++){var d=lp[p];null!=(g=N(e.getShallow(d),n[d]))&&(t[d]=g)}for(var p=0;p<up.length;p++){d=up[p];null!=(g=e.getShallow(d))&&(t[d]=g)}if(null==t.verticalAlign&&null!=(h=e.getShallow("baseline"))&&(t.verticalAlign=h),!a||!i.disableBox){for(p=0;p<hp.length;p++){var g,d=hp[p];null!=(g=e.getShallow(d))&&(t[d]=g)}u=e.getShallow("borderType");null!=u&&(t.borderDash=u),"auto"!==t.backgroundColor&&"inherit"!==t.backgroundColor||!l||(t.backgroundColor=l),"auto"!==t.borderColor&&"inherit"!==t.borderColor||!l||(t.borderColor=l)}}function pp(t,e){e=e&&e.getModel("textStyle");return Ct([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 dp=i();function gp(t,e,n,i){t&&((t=dp(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 fp(n,i,o,t,r){var a,s,l,u=dp(n);u.valueAnimation&&u.prevValue!==u.value&&(a=u.defaultInterpolatedText,s=N(u.interpolatedValue,u.prevValue),l=u.value,n.percent=0,(null==u.prevValue?_c:C)(n,{percent:1},t,i,null,function(t){var e=va(o,u.precision,s,l,t),t=(u.interpolatedValue=1===t?null:e,ip({labelDataIndex:i,labelFetcher:r,defaultText:a?a(e):e+""},u.statesModels,e));np(n,t)}))}var yp=["textStyle","color"],mp=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],vp=new K,xp=(_p.prototype.getTextColor=function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(yp):null)},_p.prototype.getFont=function(){return pp({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},_p.prototype.getTextRect=function(t){for(var e={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n<mp.length;n++)e[mp[n]]=this.getShallow(mp[n]);return vp.useStyle(e),vp.update(),vp.getBoundingRect()},_p);function _p(){}var bp=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],wp=Aa(bp),Sp=(Mp.prototype.getLineStyle=function(t){return wp(this,t)},Mp);function Mp(){}var Ip=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],Tp=Aa(Ip),Cp=(Dp.prototype.getItemStyle=function(t,e){return Tp(this,t,e)},Dp);function Dp(){}Lp.prototype.init=function(t,e,n){},Lp.prototype.mergeOption=function(t,e){d(this.option,t,!0)},Lp.prototype.get=function(t,e){return null==t?this.option:this._doGet(this.parsePath(t),!e&&this.parentModel)},Lp.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},Lp.prototype.getModel=function(t,e){var n=null!=t,t=n?this.parsePath(t):null;return new Lp(n?this._doGet(t):this.option,e=e||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(t)),this.ecModel)},Lp.prototype.isEmpty=function(){return null==this.option},Lp.prototype.restoreData=function(){},Lp.prototype.clone=function(){return new this.constructor(S(this.option))},Lp.prototype.parsePath=function(t){return"string"==typeof t?t.split("."):t},Lp.prototype.resolveParentPath=function(t){return t},Lp.prototype.isAnimationEnabled=function(){if(!w.node&&this.option)return null!=this.option.animation?!!this.option.animation:this.parentModel?this.parentModel.isAnimationEnabled():void 0},Lp.prototype._doGet=function(t,e){var n=this.option;if(t){for(var i=0;i<t.length&&(!t[i]||null!=(n=n&&"object"==typeof n?n[t[i]]:null));i++);null==n&&e&&(n=e._doGet(this.resolveParentPath(t),e.parentModel))}return n};var Ap,kp=Lp;function Lp(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}Sa(kp),jp=kp,Ap=["__\0is_clz",Ia++].join("_"),jp.prototype[Ap]=!0,jp.isInstance=function(t){return!(!t||!t[Ap])},ut(kp,Sp),ut(kp,Cp),ut(kp,La),ut(kp,xp);var Pp=Math.round(10*Math.random());function Op(t){return[t||"",Pp++].join("_")}function Np(t,e){return d(d({},t,!0),e,!0)}var Rp="ZH",Ep="EN",zp=Ep,Vp={},Bp={},Fp=w.domSupported&&-1<(document.documentElement.lang||navigator.language||navigator.browserLanguage||zp).toUpperCase().indexOf(Rp)?Rp:zp;function Gp(t,e){t=t.toUpperCase(),Bp[t]=new kp(e),Vp[t]=e}function Wp(t){return Bp[t]}Gp(Ep,{time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}}),Gp(Rp,{time:{month:["䏿","äºæ","䏿","åæ","äºæ","å
æ","䏿","å
«æ","乿","åæ","å䏿","åäºæ"],monthAbbr:["1æ","2æ","3æ","4æ","5æ","6æ","7æ","8æ","9æ","10æ","11æ","12æ"],dayOfWeek:["æææ¥","ææä¸","ææäº","ææä¸","ææå","ææäº","ææå
"],dayOfWeekAbbr:["æ¥","ä¸","äº","ä¸","å","äº","å
"]},legend:{selector:{all:"å
¨é",inverse:"åé"}},toolbox:{brush:{title:{rect:"ç©å½¢éæ©",polygon:"åé",lineX:"横åéæ©",lineY:"纵åéæ©",keep:"ä¿æéæ©",clear:"æ¸
é¤éæ©"}},dataView:{title:"æ°æ®è§å¾",lang:["æ°æ®è§å¾","å
³é","å·æ°"]},dataZoom:{title:{zoom:"åºå缩æ¾",back:"åºå缩æ¾è¿å"}},magicType:{title:{line:"åæ¢ä¸ºæçº¿å¾",bar:"åæ¢ä¸ºæ±ç¶å¾",stack:"åæ¢ä¸ºå å ",tiled:"åæ¢ä¸ºå¹³éº"}},restore:{title:"è¿å"},saveAsImage:{title:"ä¿å为å¾ç",lang:["å³é®å¦å为å¾ç"]}},series:{typeNames:{pie:"饼å¾",bar:"æ±ç¶å¾",line:"æçº¿å¾",scatter:"æ£ç¹å¾",effectScatter:"æ¶æ¼ªæ£ç¹å¾",radar:"é·è¾¾å¾",tree:"æ å¾",treemap:"ç©å½¢æ å¾",boxplot:"ç®±åå¾",candlestick:"K线å¾",k:"K线å¾",heatmap:"çåå¾",map:"å°å¾",parallel:"å¹³è¡åæ å¾",lines:"线å¾",graph:"å
³ç³»å¾",sankey:"æ¡åºå¾",funnel:"æ¼æå¾",gauge:"仪表çå¾",pictorialBar:"象形æ±å¾",themeRiver:"䏻颿²³æµå¾",sunburst:"ææ¥å¾",custom:"èªå®ä¹å¾è¡¨",chart:"å¾è¡¨"}},aria:{general:{withTitle:"è¿æ¯ä¸ä¸ªå
³äºâ{title}âçå¾è¡¨ã",withoutTitle:"è¿æ¯ä¸ä¸ªå¾è¡¨ï¼"},series:{single:{prefix:"",withName:"å¾è¡¨ç±»åæ¯{seriesType}ï¼è¡¨ç¤º{seriesName}ã",withoutName:"å¾è¡¨ç±»åæ¯{seriesType}ã"},multiple:{prefix:"å®ç±{seriesCount}个å¾è¡¨ç³»åç»æã",withName:"第{seriesId}ä¸ªç³»åæ¯ä¸ä¸ªè¡¨ç¤º{seriesName}ç{seriesType}ï¼",withoutName:"第{seriesId}ä¸ªç³»åæ¯ä¸ä¸ª{seriesType}ï¼",separator:{middle:"ï¼",end:"ã"}}},data:{allData:"å
¶æ°æ®æ¯ââ",partialData:"å
¶ä¸ï¼å{displayCnt}项æ¯ââ",withName:"{name}çæ°æ®æ¯{value}",withoutName:"{value}",separator:{middle:"ï¼",end:""}}}});var Hp=1e3,Yp=60*Hp,Xp=60*Yp,Up=24*Xp,Ia=365*Up,Zp={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}"},jp="{yyyy}-{MM}-{dd}",qp={year:"{yyyy}",month:"{yyyy}-{MM}",day:jp,hour:jp+" "+Zp.hour,minute:jp+" "+Zp.minute,second:jp+" "+Zp.second,millisecond:Zp.none},Kp=["year","month","day","hour","minute","second","millisecond"],$p=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Jp(t,e){return"0000".substr(0,e-(t+="").length)+t}function Qp(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 td(t,e,n,i){var t=Vr(t),o=t[id(n)](),r=t[od(n)]()+1,a=Math.floor((r-1)/3)+1,s=t[rd(n)](),l=t["get"+(n?"UTC":"")+"Day"](),u=t[ad(n)](),h=(u-1)%12+1,c=t[sd(n)](),p=t[ld(n)](),t=t[ud(n)](),n=(i instanceof kp?i:Wp(i||Fp)||Bp[zp]).getModel("time"),i=n.get("month"),d=n.get("monthAbbr"),g=n.get("dayOfWeek"),n=n.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,Jp(o%100+"",2)).replace(/{Q}/g,a+"").replace(/{MMMM}/g,i[r-1]).replace(/{MMM}/g,d[r-1]).replace(/{MM}/g,Jp(r,2)).replace(/{M}/g,r+"").replace(/{dd}/g,Jp(s,2)).replace(/{d}/g,s+"").replace(/{eeee}/g,g[l]).replace(/{ee}/g,n[l]).replace(/{e}/g,l+"").replace(/{HH}/g,Jp(u,2)).replace(/{H}/g,u+"").replace(/{hh}/g,Jp(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,Jp(c,2)).replace(/{m}/g,c+"").replace(/{ss}/g,Jp(p,2)).replace(/{s}/g,p+"").replace(/{SSS}/g,Jp(t,3)).replace(/{S}/g,t+"")}function ed(t,e){var t=Vr(t),n=t[od(e)]()+1,i=t[rd(e)](),o=t[ad(e)](),r=t[sd(e)](),a=t[ld(e)](),t=0===t[ud(e)](),e=t&&0===a,a=e&&0===r,r=a&&0===o,o=r&&1===i;return o&&1===n?"year":o?"month":r?"day":a?"hour":e?"minute":t?"second":"millisecond"}function nd(t,e,n){var i=Y(t)?Vr(t):t;switch(e=e||ed(t,n)){case"year":return i[id(n)]();case"half-year":return 6<=i[od(n)]()?1:0;case"quarter":return Math.floor((i[od(n)]()+1)/4);case"month":return i[od(n)]();case"day":return i[rd(n)]();case"half-day":return i[ad(n)]()/24;case"hour":return i[ad(n)]();case"minute":return i[sd(n)]();case"second":return i[ld(n)]();case"millisecond":return i[ud(n)]()}}function id(t){return t?"getUTCFullYear":"getFullYear"}function od(t){return t?"getUTCMonth":"getMonth"}function rd(t){return t?"getUTCDate":"getDate"}function ad(t){return t?"getUTCHours":"getHours"}function sd(t){return t?"getUTCMinutes":"getMinutes"}function ld(t){return t?"getUTCSeconds":"getSeconds"}function ud(t){return t?"getUTCMilliseconds":"getMilliseconds"}function hd(t){return t?"setUTCMonth":"setMonth"}function cd(t){return t?"setUTCDate":"setDate"}function pd(t){return t?"setUTCHours":"setHours"}function dd(t){return t?"setUTCMinutes":"setMinutes"}function gd(t){return t?"setUTCSeconds":"setSeconds"}function fd(t){return t?"setUTCMilliseconds":"setMilliseconds"}function yd(t){var e;return Xr(t)?(e=(t+"").split("."))[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(1<e.length?"."+e[1]:""):H(t)?t:"-"}function md(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 vd=It;function xd(t,e,n){function i(t){return t&&Ct(t)?t:"-"}function o(t){return null!=t&&!isNaN(t)&&isFinite(t)}var r="time"===e,a=t instanceof Date;if(r||a){var r=r?Vr(t):t;if(!isNaN(+r))return td(r,"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}",n);if(a)return"-"}return"ordinal"===e?gt(t)?i(t):Y(t)&&o(t)?t+"":"-":o(r=Yr(t))?yd(r):gt(t)?i(t):"boolean"==typeof t?t+"":"-"}function _d(t,e){return"{"+t+(null==e?"":e)+"}"}var bd=["a","b","c","d","e","f","g"];function wd(t,e,n){var i=(e=B(e)?e:[e]).length;if(!i)return"";for(var o=e[0].$vars||[],r=0;r<o.length;r++){var a=bd[r];t=t.replace(_d(a),_d(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(_d(bd[l],s),n?we(u):u)}return t}function Sd(t,e){var t=H(t)?{color:t,extraCssText:e}:t||{},n=t.color,i=t.type,o=(e=t.extraCssText,t.renderMode||"html");return n?"html"===o?"subItem"===i?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+we(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+we(n)+";"+(e||"")+'"></span>':{renderMode:o,content:"{"+(t.markerId||"markerX")+"|} ",style:"subItem"===i?{width:4,height:4,borderRadius:2,backgroundColor:n}:{width:10,height:10,borderRadius:5,backgroundColor:n}}:""}function Md(t,e){return e=e||"transparent",H(t)?t:O(t)&&t.colorStops&&(t.colorStops[0]||{}).color||e}function Id(t,e){var n;"_blank"===e||"blank"===e?((n=window.open()).opener=null,n.location.href=t):window.open(t,e)}var Td=nt,Cd=["left","right","top","bottom","width","height"],Dd=[["width","left","right"],["height","top","bottom"]];function Ad(a,s,l,u,h){var c=0,p=0,d=(null==u&&(u=1/0),null==h&&(h=1/0),0);s.eachChild(function(t,e){var n,i,o,r=t.getBoundingRect(),e=s.childAt(e+1),e=e&&e.getBoundingRect();d="horizontal"===a?(i=r.width+(e?-e.x+r.x:0),u<(n=c+i)||t.newline?(c=0,n=i,p+=d+l,r.height):Math.max(d,r.height)):(i=r.height+(e?-e.y+r.y:0),h<(o=p+i)||t.newline?(c+=d+l,p=0,o=i,r.width):Math.max(d,r.width)),t.newline||(t.x=c,t.y=p,t.markRedraw(),"horizontal"===a?c=n+l:p=o+l)})}var kd=Ad;function Ld(t,e,n){n=vd(n||0);var i=e.width,o=e.height,r=j(t.left,i),a=j(t.top,o),e=j(t.right,i),s=j(t.bottom,o),l=j(t.width,i),u=j(t.height,o),h=n[2]+n[0],c=n[1]+n[3],p=t.aspect;switch(isNaN(l)&&(l=i-e-c-r),isNaN(u)&&(u=o-s-h-a),null!=p&&(isNaN(l)&&isNaN(u)&&(i/o<p?l=.8*i:u=.8*o),isNaN(l)&&(l=p*u),isNaN(u))&&(u=l/p),isNaN(r)&&(r=i-e-l-c),isNaN(a)&&(a=o-s-u-h),t.left||t.right){case"center":r=i/2-l/2-n[3];break;case"right":r=i-l-c}switch(t.top||t.bottom){case"middle":case"center":a=o/2-u/2-n[0];break;case"bottom":a=o-u-h}r=r||0,a=a||0,isNaN(l)&&(l=i-c-r-(e||0)),isNaN(u)&&(u=o-h-a-(s||0));p=new U(r+n[3],a+n[0],l,u);return p.margin=n,p}function Pd(t,e,n,i,o,r){var a,s=!o||!o.hv||o.hv[0],l=!o||!o.hv||o.hv[1],o=o&&o.boundingMode||"all";if((r=r||t).x=t.x,r.y=t.y,!s&&!l)return!1;"raw"===o?a="group"===t.type?new U(0,0,+e.width||0,+e.height||0):t.getBoundingRect():(a=t.getBoundingRect(),t.needLocalTransform()&&(u=t.getLocalTransform(),(a=a.clone()).applyTransform(u)));var u=Ld(z({width:a.width,height:a.height},e),n,i),e=s?u.x-a.x:0,n=l?u.y-a.y:0;return"raw"===o?(r.x=e,r.y=n):(r.x+=e,r.y+=n),r===t&&t.markRedraw(),!0}function Od(t){t=t.layoutMode||t.constructor.layoutMode;return O(t)?t:t?{type:t}:null}function Nd(l,u,t){var h=t&&t.ignoreSize,t=(B(h)||(h=[h,h]),n(Dd[0],0)),e=n(Dd[1],1);function n(t,e){var n={},i=0,o={},r=0;if(Td(t,function(t){o[t]=l[t]}),Td(t,function(t){c(u,t)&&(n[t]=o[t]=u[t]),p(n,t)&&i++,p(o,t)&&r++}),h[e])p(u,t[1])?o[t[2]]=null:p(u,t[2])&&(o[t[1]]=null);else if(2!==r&&i){if(!(2<=i))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){Td(t,function(t){e[t]=n[t]})}i(Dd[0],l,t),i(Dd[1],l,e)}function Rd(t){return Ed({},t)}function Ed(e,n){return n&&e&&Td(Cd,function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e}P(Ad,"vertical"),P(Ad,"horizontal");var zd,Vd,Bd,Fd,Gd=i(),g=(u(Wd,zd=kp),Wd.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},Wd.prototype.mergeDefaultAndTheme=function(t,e){var n=Od(this),i=n?Rd(t):{};d(t,e.getTheme().get(this.mainType)),d(t,this.getDefaultOption()),n&&Nd(t,i,n)},Wd.prototype.mergeOption=function(t,e){d(this.option,t,!0);var n=Od(this);n&&Nd(this.option,t,n)},Wd.prototype.optionUpdated=function(t,e){},Wd.prototype.getDefaultOption=function(){var t=this.constructor;if(!(e=t)||!e[ba])return t.defaultOption;var e=Gd(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=d(r,n[a],!0);e.defaultOption=r}return e.defaultOption},Wd.prototype.getReferringComponents=function(t,e){var n=t+"Id";return fa(this.ecModel,t,{index:this.get(t+"Index",!0),id:this.get(n,!0)},e)},Wd.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")}},Wd.prototype.getZLevelKey=function(){return""},Wd.prototype.setZLevel=function(t){this.option.zlevel=t},Wd.protoInitialize=((Sp=Wd.prototype).type="component",Sp.id="",Sp.name="",Sp.mainType="",Sp.subType="",void(Sp.componentIndex=0)),Wd);function Wd(t,e,n){t=zd.call(this,t,e,n)||this;return t.uid=Op("ec_cpt_model"),t}function Hd(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}Ma(g,kp),Da(g),Bd={},(Vd=g).registerSubTypeDefaulter=function(t,e){t=wa(t);Bd[t.main]=e},Vd.determineSubType=function(t,e){var n,i=e.type;return i||(n=wa(t).main,Vd.hasSubTypes(t)&&Bd[n]&&(i=Bd[n](e))),i},Fd=function(t){var e=[];nt(g.getClassesByMainType(t),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=V(e,function(t){return wa(t).main}),"dataset"!==t&&G(e,"dataset")<=0&&e.unshift("dataset");return e},g.topologicalTravel=function(t,e,n,i){if(t.length){a={},s=[],nt(r=e,function(n){var e,i,o=Hd(a,n),t=o.originalDeps=Fd(n),t=(e=r,i=[],nt(t,function(t){0<=G(e,t)&&i.push(t)}),i);o.entryCount=t.length,0===o.entryCount&&s.push(n),nt(t,function(t){G(o.predecessor,t)<0&&o.predecessor.push(t);var e=Hd(a,t);G(e.successor,t)<0&&e.successor.push(n)})});var r,a,s,e={graph:a,noEntryList:s},o=e.graph,l=e.noEntryList,u={};for(nt(t,function(t){u[t]=!0});l.length;){var h=l.pop(),c=o[h],p=!!u[h];p&&(n.call(i,h,c.originalDeps.slice()),delete u[h]),nt(c.successor,p?g:d)}nt(u,function(){throw new Error("")})}function d(t){o[t].entryCount--,0===o[t].entryCount&&l.push(t)}function g(t){u[t]=!0,d(t)}};var Cp="",La=("undefined"!=typeof navigator&&(Cp=navigator.platform||""),"rgba(0, 0, 0, 0.2)"),Yd={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:La,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:La,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:La,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:La,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:La,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:La,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Cp.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},Xd=R(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),Ud="original",Zd="arrayRows",jd="objectRows",qd="keyedColumns",Kd="typedArray",$d="unknown",Jd="column",Qd="row",tg={Must:1,Might:2,Not:3},eg=i();function ng(n,t,e){var o,r,a,i,s,l={},u=og(t);return u&&n&&(o=[],r=[],t=t.ecModel,t=eg(t).datasetMap,u=u.uid+"_"+e.seriesLayoutBy,nt(n=n.slice(),function(t,e){t=O(t)?t:n[e]={name:t};"ordinal"===t.type&&null==a&&(a=e,i=c(t)),l[t.name]=[]}),s=t.get(u)||t.set(u,{categoryWayDim:i,valueWayDim:0}),nt(n,function(t,e){var n,i=t.name,t=c(t);null==a?(n=s.valueWayDim,h(l[i],n,t),h(r,n,t),s.valueWayDim+=t):a===e?(h(l[i],0,t),h(o,0,t)):(n=s.categoryWayDim,h(l[i],n,t),h(r,n,t),s.categoryWayDim+=t)}),o.length&&(l.itemName=o),r.length)&&(l.seriesName=r),l;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}}function ig(t,l,u){var h,c,p,e={};return og(t)&&(h=l.sourceFormat,c=l.dimensionsDefine,h!==jd&&h!==qd||nt(c,function(t,e){"name"===(O(t)?t.name:t)&&(p=e)}),t=function(){for(var t={},e={},n=[],i=0,o=Math.min(5,u);i<o;i++){var r=ag(l.data,h,l.seriesLayoutBy,c,l.startIndex,i),a=(n.push(r),r===tg.Not);if(a&&null==t.v&&i!==p&&(t.v=i),null!=t.n&&t.n!==t.v&&(a||n[t.n]!==tg.Not)||(t.n=i),s(t)&&n[t.n]!==tg.Not)return t;a||(r===tg.Might&&null==e.v&&i!==p&&(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}())&&(e.value=[t.v],t=null!=p?p:t.n,e.itemName=[t],e.seriesName=[t]),e}function og(t){if(!t.get("data",!0))return fa(t.ecModel,"dataset",{index:t.get("datasetIndex",!0),id:t.get("datasetId",!0)},da).models[0]}function rg(t,e){return ag(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,e)}function ag(t,e,n,i,o,r){var a,s,l;if(!yt(t)){if(i&&(O(i=i[r])?(s=i.name,l=i.type):H(i)&&(s=i)),null!=l)return"ordinal"===l?tg.Must:tg.Not;if(e===Zd){var u=t;if(n===Qd){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===jd){var d=t;if(!s)return tg.Not;for(c=0;c<d.length&&c<5;c++)if((f=d[c])&&null!=(a=m(f[s])))return a}else if(e===qd){if(!s)return tg.Not;if(!(h=t[s])||yt(h))return tg.Not;for(c=0;c<h.length&&c<5;c++)if(null!=(a=m(h[c])))return a}else if(e===Ud)for(var g=t,c=0;c<g.length&&c<5;c++){var f,y=ea(f=g[c]);if(!B(y))return tg.Not;if(null!=(a=m(y[r])))return a}}return tg.Not;function m(t){var e=H(t);return null!=t&&isFinite(t)&&""!==t?e?tg.Might:tg.Not:e&&"-"!==t?tg.Must:void 0}}var sg=R();var lg,ug,hg,cg=i(),pg=i(),dg=(gg.prototype.getColorFromPalette=function(t,e,n){var i=Jr(this.get("color",!0)),o=this.get("colorLayer",!0);return fg(this,cg,i,o,t,e,n)},gg.prototype.clearColorPalette=function(){var t,e;(e=cg)(t=this).paletteIdx=0,e(t).paletteNameMap={}},gg);function gg(){}function fg(t,e,n,i,o,r,a){e=e(r=r||t),t=e.paletteIdx||0,r=e.paletteNameMap=e.paletteNameMap||{};return r.hasOwnProperty(o)?r[o]:(i=(i=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)&&i.length?(a=i[t],o&&(r[o]=a),e.paletteIdx=(t+1)%i.length,a):void 0}var yg,mg="\0_ec_inner",vg=(u(xg,yg=kp),xg.prototype.init=function(t,e,n,i,o,r){i=i||{},this.option=null,this._theme=new kp(i),this._locale=new kp(o),this._optionManager=r},xg.prototype.setOption=function(t,e,n){e=wg(e);this._optionManager.setOption(t,n,e),this._resetOption(null,e)},xg.prototype.resetOption=function(t,e){return this._resetOption(t,wg(e))},xg.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)):hg(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||(n=o.getMediaOption(this)).length&&nt(n,function(t){i=!0,this._mergeOption(t,e)},this),i},xg.prototype.mergeOption=function(t){this._mergeOption(t,null)},xg.prototype._mergeOption=function(i,t){var o=this.option,h=this._componentsMap,c=this._componentsCount,n=[],r=R(),p=t&&t.replaceMergeMainTypeMap;eg(this).datasetMap=R(),nt(i,function(t,e){null!=t&&(g.hasClass(e)?e&&(n.push(e),r.set(e,!0)):o[e]=null==o[e]?S(t):d(o[e],t,!0))}),p&&p.each(function(t,e){g.hasClass(e)&&!r.get(e)&&(n.push(e),r.set(e,!0))}),g.topologicalTravel(n,g.getAllClassMainTypes(),function(r){var a,t=function(t,e,n){return(e=(e=sg.get(e))&&e(t))?n.concat(e):n}(this,r,Jr(i[r])),e=h.get(r),n=e?p&&p.get(r)?"replaceMerge":"normalMerge":"replaceAll",e=na(e,t,n),s=(la(e,r,g),o[r]=null,h.set(r,null),c.set(r,0),[]),l=[],u=0;nt(e,function(t,e){var n=t.existing,i=t.newOption;if(i){var o=g.getClass(r,t.keyInfo.subType,!("series"===r));if(!o)return;if("tooltip"===r){if(a)return;a=!0}n&&n.constructor===o?(n.name=t.keyInfo.name,n.mergeOption(i,this),n.optionUpdated(i,!1)):(e=F({componentIndex:e},t.keyInfo),F(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?(s.push(n.option),l.push(n),u++):(s.push(void 0),l.push(void 0))},this),o[r]=s,h.set(r,l),c.set(r,u),"series"===r&&lg(this)},this),this._seriesIndices||lg(this)},xg.prototype.getOption=function(){var a=S(this.option);return nt(a,function(t,e){if(g.hasClass(e)){for(var n=Jr(t),i=n.length,o=!1,r=i-1;0<=r;r--)n[r]&&!sa(n[r])?o=!0:(n[r]=null,o||i--);n.length=i,a[e]=n}}),delete a[mg],a},xg.prototype.getTheme=function(){return this._theme},xg.prototype.getLocaleModel=function(){return this._locale},xg.prototype.setUpdatePayload=function(t){this._payload=t},xg.prototype.getUpdatePayload=function(){return this._payload},xg.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]}},xg.prototype.queryComponents=function(t){var e,n,i,o,r,a=t.mainType;return a&&(e=t.index,n=t.id,i=t.name,o=this._componentsMap.get(a))&&o.length?(null!=e?(r=[],nt(Jr(e),function(t){o[t]&&r.push(o[t])})):r=null!=n?_g("id",n,o):null!=i?_g("name",i,o):pt(o,function(t){return!!t}),bg(r,t)):[]},xg.prototype.findComponents=function(t){var e,n=t.query,i=t.mainType,o=(o=i+"Index",r=i+"Id",e=i+"Name",!(n=n)||null==n[o]&&null==n[r]&&null==n[e]?null:{mainType:i,index:n[o],id:n[r],name:n[e]}),r=o?this.queryComponents(o):pt(this._componentsMap.get(i),function(t){return!!t});return n=bg(r,t),t.filter?pt(n,t.filter):n},xg.prototype.eachComponent=function(t,e,n){var i=this._componentsMap;if(D(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=H(t)?i.get(t):O(t)?this.findComponents(t):null,s=0;a&&s<a.length;s++){var l=a[s];l&&e.call(n,l,l.componentIndex)}},xg.prototype.getSeriesByName=function(t){var e=ra(t,null);return pt(this._componentsMap.get("series"),function(t){return!!t&&null!=e&&t.name===e})},xg.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},xg.prototype.getSeriesByType=function(e){return pt(this._componentsMap.get("series"),function(t){return!!t&&t.subType===e})},xg.prototype.getSeries=function(){return pt(this._componentsMap.get("series"),function(t){return!!t})},xg.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},xg.prototype.eachSeries=function(n,i){ug(this),nt(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];n.call(i,e,t)},this)},xg.prototype.eachRawSeries=function(e,n){nt(this._componentsMap.get("series"),function(t){t&&e.call(n,t,t.componentIndex)})},xg.prototype.eachSeriesByType=function(n,i,o){ug(this),nt(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];e.subType===n&&i.call(o,e,t)},this)},xg.prototype.eachRawSeriesByType=function(t,e,n){return nt(this.getSeriesByType(t),e,n)},xg.prototype.isSeriesFiltered=function(t){return ug(this),null==this._seriesIndicesMap.get(t.componentIndex)},xg.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},xg.prototype.filterSeries=function(n,i){ug(this);var o=[];nt(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=R(o)},xg.prototype.restoreData=function(n){lg(this);var t=this._componentsMap,i=[];t.each(function(t,e){g.hasClass(e)&&i.push(e)}),g.topologicalTravel(i,g.getAllClassMainTypes(),function(e){nt(t.get(e),function(t){!t||"series"===e&&function(t,e){{var n,i;if(e)return n=e.seriesIndex,i=e.seriesId,e=e.seriesName,null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=e&&t.name!==e}}(t,n)||t.restoreData()})})},xg.internalField=(lg=function(t){var e=t._seriesIndices=[];nt(t._componentsMap.get("series"),function(t){t&&e.push(t.componentIndex)}),t._seriesIndicesMap=R(e)},ug=function(t){},void(hg=function(t,e){t.option={},t.option[mg]=1,t._componentsMap=R({series:[]}),t._componentsCount=R();var n,i,o=e.aria;O(o)&&null==o.enabled&&(o.enabled=!0),n=e,o=t._theme.option,i=n.color&&!n.colorLayer,nt(o,function(t,e){"colorLayer"===e&&i||g.hasClass(e)||("object"==typeof t?n[e]=n[e]?d(n[e],t,!1):S(t):null==n[e]&&(n[e]=t))}),d(e,Yd,!1),t._mergeOption(e,null)})),xg);function xg(){return null!==yg&&yg.apply(this,arguments)||this}function _g(e,t,n){var i,o;return B(t)?(i=R(),nt(t,function(t){null!=t&&null!=ra(t,null)&&i.set(t,!0)}),pt(n,function(t){return t&&i.get(t[e])})):(o=ra(t,null),pt(n,function(t){return t&&null!=o&&t[e]===o}))}function bg(t,e){return e.hasOwnProperty("subType")?pt(t,function(t){return t&&t.subType===e.subType}):t}function wg(t){var e=R();return t&&nt(Jr(t.replaceMerge),function(t){e.set(t,!0)}),{replaceMergeMainTypeMap:e}}ut(vg,dg);function Sg(e){nt(Mg,function(t){this[t]=T(e[t],e)},this)}var Mg=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],Ig={},Tg=(Cg.prototype.create=function(n,i){var o=[];nt(Ig,function(t,e){t=t.create(n,i);o=o.concat(t||[])}),this._coordinateSystems=o},Cg.prototype.update=function(e,n){nt(this._coordinateSystems,function(t){t.update&&t.update(e,n)})},Cg.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},Cg.register=function(t,e){Ig[t]=e},Cg.get=function(t){return Ig[t]},Cg);function Cg(){this._coordinateSystems=[]}var Dg=/^(min|max)?(.+)$/,Ag=(kg.prototype.setOption=function(t,e,n){t&&(nt(Jr(t.series),function(t){t&&t.data&&yt(t.data)&&At(t.data)}),nt(Jr(t.dataset),function(t){t&&t.source&&yt(t.source)&&At(t.source)})),t=S(t);var i=this._optionBackup,t=function(t,n,i){var e,o,r=[],a=t.baseOption,s=t.timeline,l=t.options,u=t.media,h=!!t.media,c=!!(l||s||a&&a.timeline);a?(o=a).timeline||(o.timeline=s):((c||h)&&(t.options=t.media=null),o=t);h&&B(u)&&nt(u,function(t){t&&t.option&&(t.query?r.push(t):e=e||t)});function p(e){nt(n,function(t){t(e,i)})}return p(o),nt(l,p),nt(r,function(t){return p(t.option)}),{baseOption:o,timelineOptions:l||[],mediaDefault:e,mediaList:r}}(t,e,!i);this._newBaseOption=t.baseOption,i?(t.timelineOptions.length&&(i.timelineOptions=t.timelineOptions),t.mediaList.length&&(i.mediaList=t.mediaList),t.mediaDefault&&(i.mediaDefault=t.mediaDefault)):this._optionBackup=t},kg.prototype.mountOption=function(t){var e=this._optionBackup;return this._timelineOptions=e.timelineOptions,this._mediaList=e.mediaList,this._mediaDefault=e.mediaDefault,this._currentMediaIndices=[],S(t?e.baseOption:this._newBaseOption)},kg.prototype.getTimelineOption=function(t){var e,n=this._timelineOptions;return e=n.length&&(t=t.getComponent("timeline"))?S(n[t.getCurrentIndex()]):e},kg.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){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 nt(t,function(t,e){var n,e=e.match(Dg);e&&e[1]&&e[2]&&(n=e[1],e=e[2].toLowerCase(),e=i[e],t=t,("min"===(n=n)?t<=e:"max"===n?e<=t:e===t)||(o=!1))}),o}(i[u].query,e,n)||r.push(u);(r=!r.length&&o?[-1]:r).length&&(s=r,l=this._currentMediaIndices,s.join(",")!==l.join(","))&&(a=V(r,function(t){return S((-1===t?o:i[t]).option)})),this._currentMediaIndices=r}return a},kg);function kg(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}var Lg=nt,Pg=O,Og=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Ng(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=Og.length;n<i;n++){var o=Og[n],r=e.normal,a=e.emphasis;r&&r[o]&&(t[o]=t[o]||{},t[o].normal?d(t[o].normal,r[o]):t[o].normal=r[o],r[o]=null),a&&a[o]&&(t[o]=t[o]||{},t[o].emphasis?d(t[o].emphasis,a[o]):t[o].emphasis=a[o],a[o]=null)}}function Rg(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 Eg(t){Rg(t,"itemStyle"),Rg(t,"lineStyle"),Rg(t,"areaStyle"),Rg(t,"label"),Rg(t,"labelLine"),Rg(t,"upperLabel"),Rg(t,"edgeLabel")}function zg(t,e){var n=Pg(t)&&t[e],i=Pg(n)&&n.textStyle;if(i)for(var o=0,r=ta.length;o<r;o++){var a=ta[o];i.hasOwnProperty(a)&&(n[a]=i[a])}}function Vg(t){t&&(Eg(t),zg(t,"label"),t.emphasis)&&zg(t.emphasis,"label")}function Bg(t){return B(t)?t:t?[t]:[]}function Fg(t){return(B(t)?t[0]:t)||{}}function Gg(e,t){Lg(Bg(e.series),function(t){if(Pg(t))if(Pg(t)){Ng(t),Eg(t),zg(t,"label"),zg(t,"upperLabel"),zg(t,"edgeLabel"),t.emphasis&&(zg(t.emphasis,"label"),zg(t.emphasis,"upperLabel"),zg(t.emphasis,"edgeLabel"));var e=t.markPoint,n=(e&&(Ng(e),Vg(e)),t.markLine),i=(n&&(Ng(n),Vg(n)),t.markArea),o=(i&&Vg(i),t.data);if("graph"===t.type){var o=o||t.nodes,r=t.links||t.edges;if(r&&!yt(r))for(var a=0;a<r.length;a++)Vg(r[a]);nt(t.categories,function(t){Eg(t)})}if(o&&!yt(o))for(a=0;a<o.length;a++)Vg(o[a]);if((e=t.markPoint)&&e.data)for(var s=e.data,a=0;a<s.length;a++)Vg(s[a]);if((n=t.markLine)&&n.data)for(var l=n.data,a=0;a<l.length;a++)B(l[a])?(Vg(l[a][0]),Vg(l[a][1])):Vg(l[a]);"gauge"===t.type?(zg(t,"axisLabel"),zg(t,"title"),zg(t,"detail")):"treemap"===t.type?(Rg(t.breadcrumb,"itemStyle"),nt(t.levels,function(t){Eg(t)})):"tree"===t.type&&Eg(t.leaves)}});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),Lg(n,function(t){Lg(Bg(e[t]),function(t){t&&(zg(t,"axisLabel"),zg(t.axisPointer,"label"))})}),Lg(Bg(e.parallel),function(t){t=t&&t.parallelAxisDefault;zg(t,"axisLabel"),zg(t&&t.axisPointer,"label")}),Lg(Bg(e.calendar),function(t){Rg(t,"itemStyle"),zg(t,"dayLabel"),zg(t,"monthLabel"),zg(t,"yearLabel")}),Lg(Bg(e.radar),function(t){zg(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)}),Lg(Bg(e.geo),function(t){Pg(t)&&(Vg(t),Lg(Bg(t.regions),function(t){Vg(t)}))}),Lg(Bg(e.timeline),function(t){Vg(t),Rg(t,"label"),Rg(t,"itemStyle"),Rg(t,"controlStyle",!0);t=t.data;B(t)&&nt(t,function(t){O(t)&&(Rg(t,"label"),Rg(t,"itemStyle"))})}),Lg(Bg(e.toolbox),function(t){Rg(t,"iconStyle"),Lg(t.feature,function(t){Rg(t,"iconStyle")})}),zg(Fg(e.axisPointer),"label"),zg(Fg(e.tooltip).axisPointer,"label")}function Wg(e){e&&nt(Hg,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var Hg=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Yg=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Xg=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function Ug(t){var e=t&&t.itemStyle;if(e)for(var n=0;n<Xg.length;n++){var i=Xg[n][1],o=Xg[n][0];null!=e[i]&&(e[o]=e[i])}}function Zg(t){t&&"edge"===t.alignTo&&null!=t.margin&&null==t.edgeDistance&&(t.edgeDistance=t.margin)}function jg(t){t&&t.downplay&&!t.blur&&(t.blur=t.downplay)}function qg(e,t){Gg(e,t),e.series=Jr(e.series),nt(e.series,function(t){if(O(t)){var e,n=t.type;if("line"===n)null!=t.clipOverflow&&(t.clip=t.clipOverflow);else if("pie"===n||"gauge"===n){if(null!=t.clockWise&&(t.clockwise=t.clockWise),Zg(t.label),(e=t.data)&&!yt(e))for(var i=0;i<e.length;i++)Zg(e[i]);null!=t.hoverOffset&&(t.emphasis=t.emphasis||{},t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset)}else if("gauge"===n){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");if(null!=o){var r=t;var a="itemStyle.color";var s=void 0;for(var l,u=a.split(","),h=r,c=0;c<u.length-1;c++)null==h[l=u[c]]&&(h[l]={}),h=h[l];!s&&null!=h[u[c]]||(h[u[c]]=o)}}else if("bar"===n){if(Ug(t),Ug(t.backgroundStyle),Ug(t.emphasis),(e=t.data)&&!yt(e))for(i=0;i<e.length;i++)"object"==typeof e[i]&&(Ug(e[i]),Ug(e[i]&&e[i].emphasis))}else"sunburst"===n?((a=t.highlightPolicy)&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=a)),jg(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,jg)):"graph"===n||"sankey"===n?(r=t)&&null!=r.focusNodeAdjacency&&(r.emphasis=r.emphasis||{},null==r.emphasis.focus)&&(r.emphasis.focus="adjacency"):"map"===n&&(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),Wg(t)}}),e.dataRange&&(e.visualMap=e.dataRange),nt(Yg,function(t){t=e[t];t&&nt(t=B(t)?t:[t],function(t){Wg(t)})})}function Kg(x){nt(x,function(p,d){var g=[],f=[NaN,NaN],t=[p.stackResultDimension,p.stackedOverDimension],y=p.data,m=p.isStackedByIndex,v=p.seriesModel.get("stackStrategy")||"samesign";y.modify(t,function(t,e,n){var i,o,r=y.get(p.stackedDimension,n);if(isNaN(r))return f;m?o=y.getRawIndex(n):i=y.get(p.stackedByDimension,n);for(var a,s,l,u=NaN,h=d-1;0<=h;h--){var c=x[h];if(0<=(o=m?o:c.data.rawIndexOf(c.stackedByDimension,i))){c=c.data.getByRawIndex(c.stackResultDimension,o);if("all"===v||"positive"===v&&0<c||"negative"===v&&c<0||"samesign"===v&&0<=r&&0<c||"samesign"===v&&r<=0&&c<0){a=r,s=c,l=void 0,l=Math.max(kr(a),kr(s)),a+=s,r=Tr<l?a:Dr(a,l),u=c;break}}}return g[0]=r,g[1]=u,g})})}var $g,Jg,Qg=function(t){this.data=t.data||(t.sourceFormat===qd?{}:[]),this.sourceFormat=t.sourceFormat||$d,this.seriesLayoutBy=t.seriesLayoutBy||Jd,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&&rg(this,n)===tg.Must&&(i.type="ordinal")}};function tf(t){return t instanceof Qg}function ef(t,e,n){n=n||of(t);var i=e.seriesLayoutBy,o=function(t,e,n,i,o){var r,a;if(!t)return{dimensionsDefine:rf(o),startIndex:a,dimensionsDetectedCount:r};{var s;e===Zd?(s=t,"auto"===i||null==i?af(function(t){null!=t&&"-"!==t&&(H(t)?null==a&&(a=1):a=0)},n,s,10):a=Y(i)?i:i?1:0,o||1!==a||(o=[],af(function(t,e){o[e]=null!=t?t+"":""},n,s,1/0)),r=o?o.length:n===Qd?s.length:s[0]?s[0].length:null):e===jd?o=o||function(t){var e,n=0;for(;n<t.length&&!(e=t[n++]););if(e)return W(e)}(t):e===qd?o||(o=[],nt(t,function(t,e){o.push(e)})):e===Ud&&(i=ea(t[0]),r=B(i)&&i.length||1)}return{startIndex:a,dimensionsDefine:rf(o),dimensionsDetectedCount:r}}(t,n,i,e.sourceHeader,e.dimensions);return new Qg({data:t,sourceFormat:n,seriesLayoutBy:i,dimensionsDefine:o.dimensionsDefine,startIndex:o.startIndex,dimensionsDetectedCount:o.dimensionsDetectedCount,metaRawOption:S(e)})}function nf(t){return new Qg({data:t,sourceFormat:yt(t)?Kd:Ud})}function of(t){var e=$d;if(yt(t))e=Kd;else if(B(t)){0===t.length&&(e=Zd);for(var n=0,i=t.length;n<i;n++){var o=t[n];if(null!=o){if(B(o)||yt(o)){e=Zd;break}if(O(o)){e=jd;break}}}}else if(O(t))for(var r in t)if(X(t,r)&&ht(t[r])){e=qd;break}return e}function rf(t){var i;if(t)return i=R(),V(t,function(t,e){var n,t={name:(t=O(t)?t:{name:t}).name,displayName:t.displayName,type:t.type};return null!=t.name&&(t.name+="",null==t.displayName&&(t.displayName=t.name),(n=i.get(t.name))?t.name+="-"+n.count++:i.set(t.name,{count:1})),t})}function af(t,e,n,i){if(e===Qd)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 sf(t){t=t.sourceFormat;return t===jd||t===qd}pf.prototype.getSource=function(){return this._source},pf.prototype.count=function(){return 0},pf.prototype.getItem=function(t,e){},pf.prototype.appendData=function(t){},pf.prototype.clean=function(){},pf.protoInitialize=((xp=pf.prototype).pure=!1,void(xp.persistent=!0)),pf.internalField=(Jg=function(t,e,n){var i,o=n.sourceFormat,r=n.seriesLayoutBy,a=n.startIndex,n=n.dimensionsDefine;F(t,$g[Sf(o,r)]),o===Kd?(t.getItem=lf,t.count=hf,t.fillStorage=uf):(i=yf(o,r),t.getItem=T(i,null,e,a,n),i=xf(o,r),t.count=T(i,null,e,a,n))},lf=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},uf=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}},hf=function(){return this._data?this._data.length/this._dimSize:0},(xp={})[Zd+"_"+Jd]={pure:!0,appendData:df},xp[Zd+"_"+Qd]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},xp[jd]={pure:!0,appendData:df},xp[qd]={pure:!0,appendData:function(t){var o=this._data;nt(t,function(t,e){for(var n=o[e]||(o[e]=[]),i=0;i<(t||[]).length;i++)n.push(t[i])})}},xp[Ud]={appendData:df},xp[Kd]={persistent:!1,pure:!0,appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}},void($g=xp));var lf,uf,hf,cf=pf;function pf(t,e){var t=tf(t)?t:nf(t),n=(this._source=t,this._data=t.data);t.sourceFormat===Kd&&(this._offset=0,this._dimSize=e,this._data=n),Jg(this,n,t)}function df(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}function gf(t,e,n,i){return t[i]}(jp={})[Zd+"_"+Jd]=function(t,e,n,i){return t[i+e]},jp[Zd+"_"+Qd]=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},jp[jd]=gf,jp[qd]=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},jp[Ud]=gf;var ff=jp;function yf(t,e){return ff[Sf(t,e)]}function mf(t,e,n){return t.length}(Sp={})[Zd+"_"+Jd]=function(t,e,n){return Math.max(0,t.length-e)},Sp[Zd+"_"+Qd]=function(t,e,n){t=t[0];return t?Math.max(0,t.length-e):0},Sp[jd]=mf,Sp[qd]=function(t,e,n){t=t[n[0].name];return t?t.length:0},Sp[Ud]=mf;var vf=Sp;function xf(t,e){return vf[Sf(t,e)]}function _f(t,e,n){return t[e]}(La={})[Zd]=_f,La[jd]=function(t,e,n){return t[n]},La[qd]=_f,La[Ud]=function(t,e,n){t=ea(t);return t instanceof Array?t[e]:t},La[Kd]=_f;var bf=La;function wf(t){return bf[t]}function Sf(t,e){return t===Zd?t+"_"+e:t}function Mf(t,e,n){if(t){var i,o,e=t.getRawDataItem(e);if(null!=e)return i=(o=t.getStore()).getSource().sourceFormat,null!=n?(t=t.getDimensionIndex(n),n=o.getDimensionProperty(t),wf(i)(e,t,n)):(o=e,i===Ud?ea(e):o)}}var If=/\{@(.+?)\}/g,Cp=(Tf.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"),t=s&&s[n.getItemVisual(t,"drawType")||"fill"],s=s&&s.stroke,l=this.mainType,u="series"===l,n=n.userOutput&&n.userOutput.get();return{componentType:l,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:u?this.subType:null,seriesIndex:this.seriesIndex,seriesId:u?this.id:null,seriesName:u?this.name:null,name:r,dataIndex:o,data:a,dataType:e,value:i,color:t,borderColor:s,dimensionNames:n?n.fullDimensions:null,encode:n?n.encode:null,$vars:["seriesName","name","value"]}},Tf.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&&B(e.value)&&(e.value=e.value[n]),D(o=o||a.getItemModel(i).get("normal"===t?["label","formatter"]:[t,"label","formatter"]))?(e.status=t,e.dimensionIndex=n,o(e)):H(o)?wd(o,e).replace(If,function(t,e){var n=e.length,n=("["===e.charAt(0)&&"]"===e.charAt(n-1)&&(e=+e.slice(1,n-1)),Mf(a,i,e));return null!=(n=r&&B(r.interpolatedValue)&&0<=(e=a.getDimensionIndex(e))?r.interpolatedValue[e]:n)?n+"":""}):void 0},Tf.prototype.getRawValue=function(t,e){return Mf(this.getData(e),t)},Tf.prototype.formatTooltip=function(t,e,n){},Tf);function Tf(){}function Cf(t){var e,n;return O(t)?t.type&&(n=t):e=t,{text:e,frag:n}}function Df(t){return new Af(t)}kf.prototype.perform=function(t){var e,n,i=this._upstream,o=t&&t.skip,r=(this._dirty&&i&&((r=this.context).data=r.outputData=i.context.outputData),this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!o&&(e=this._plan(this.context)),u(this._modBy)),a=this._modDataCount||0,s=u(t&&t.modBy),l=t&&t.modDataCount||0;function u(t){return t=1<=t?t:1}r===s&&a===l||(e="reset"),!this._dirty&&"reset"!==e||(this._dirty=!1,n=this._doReset(o)),this._modBy=s,this._modDataCount=l;r=t&&t.step;if(this._dueEnd=i?i._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var h=this._dueIndex,c=Math.min(null!=r?this._dueIndex+r:1/0,this._dueEnd);if(!o&&(n||h<c)){var p=this._progress;if(B(p))for(var d=0;d<p.length;d++)this._doProgress(p[d],h,c,s,l);else this._doProgress(p,h,c,s,l)}this._dueIndex=c;a=null!=this._settedOutputEnd?this._settedOutputEnd:c;this._outputDueEnd=a}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},kf.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},kf.prototype._doProgress=function(t,e,n,i,o){zf.reset(e,n,i,o),this._callingProgress=t,this._callingProgress({start:e,end:n,count:n-e,next:zf.next},this.context)},kf.prototype._doReset=function(t){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null,!t&&this._reset&&((e=this._reset(this.context))&&e.progress&&(n=e.forceFirstProgress,e=e.progress),B(e))&&!e.length&&(e=null),this._progress=e,this._modBy=this._modDataCount=null;var e,n,t=this._downstream;return t&&t.dirty(),n},kf.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},kf.prototype.pipe=function(t){this._downstream===t&&!this._dirty||((this._downstream=t)._upstream=this,t.dirty())},kf.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},kf.prototype.getUpstream=function(){return this._upstream},kf.prototype.getDownstream=function(){return this._downstream},kf.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t};var Af=kf;function kf(t){this._reset=(t=t||{}).reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}var Lf,Pf,Of,Nf,Rf,Ef,zf=Ef={reset:function(t,e,n,i){Pf=t,Lf=e,Of=n,Nf=i,Rf=Math.ceil(Nf/Of),Ef.next=1<Of&&0<Nf?Bf:Vf}};function Vf(){return Pf<Lf?Pf++:null}function Bf(){var t=Pf%Rf*Of+Math.ceil(Pf/Rf),t=Lf<=Pf?null:t<Nf?t:Pf;return Pf++,t}function Ff(t,e){e=e&&e.type;return"ordinal"===e?t:null==(t="time"!==e||Y(t)||null==t||"-"===t?t:+Vr(t))||""===t?NaN:+t}var Gf=R({number:function(t){return parseFloat(t)},time:function(t){return+Vr(t)},trim:function(t){return H(t)?Ct(t):t}});function Wf(t){return Gf.get(t)}var Hf={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}},Yf=(Xf.prototype.evaluate=function(t){return Y(t)?this._opFn(t,this._rvalFloat):this._opFn(Yr(t),this._rvalFloat)},Xf);function Xf(t,e){Y(e)||jr(""),this._opFn=Hf[t],this._rvalFloat=Yr(e)}Zf.prototype.evaluate=function(t,e){var n=Y(t)?t:Yr(t),i=Y(e)?e:Yr(e),o=isNaN(n),r=isNaN(i);return o&&(n=this._incomparable),r&&(i=this._incomparable),o&&r&&(o=H(t),r=H(e),o&&(n=r?t:0),r)&&(i=o?e:0),n<i?this._resultLT:i<n?-this._resultLT:0};var Uf=Zf;function Zf(t,e){t="desc"===t;this._resultLT=t?1:-1,this._incomparable="min"===(e=null==e?t?"min":"max":e)?-1/0:1/0}qf.prototype.evaluate=function(t){var e,n=t===this._rval;return n||(e=typeof t)===this._rvalTypeof||"number"!=e&&"number"!==this._rvalTypeof||(n=Yr(t)===this._rvalFloat),this._isEQ?n:!n};var jf=qf;function qf(t,e){this._rval=e,this._isEQ=t,this._rvalTypeof=typeof e,this._rvalFloat=Yr(e)}$f.prototype.getRawData=function(){throw new Error("not supported")},$f.prototype.getRawDataItem=function(t){throw new Error("not supported")},$f.prototype.cloneRawData=function(){},$f.prototype.getDimensionInfo=function(t){},$f.prototype.cloneAllDimensionInfo=function(){},$f.prototype.count=function(){},$f.prototype.retrieveValue=function(t,e){},$f.prototype.retrieveValueFromItem=function(t,e){},$f.prototype.convertValue=Ff;var Kf=$f;function $f(){}function Jf(t){return oy(t.sourceFormat)||jr(""),t.data}function Qf(t){var e=t.sourceFormat,n=t.data;if(oy(e)||jr(""),e===Zd){for(var i=[],o=0,r=n.length;o<r;o++)i.push(n[o].slice());return i}if(e===jd){for(i=[],o=0,r=n.length;o<r;o++)i.push(F({},n[o]));return i}}function ty(t,e,n){if(null!=n)return Y(n)||!isNaN(n)&&!X(e,n)?t[n]:X(e,n)?e[n]:void 0}function ey(t){return S(t)}var ny=R();function iy(t,e){var n=Jr(t),t=n.length;t||jr("");for(var i=0,o=t;i<o;i++)e=function(t,i){i.length||jr("");O(t)||jr("");var e=t.type,d=ny.get(e);d||jr("");e=V(i,function(t){var e=t,t=d,n=new Kf,i=e.data,o=n.sourceFormat=e.sourceFormat,r=e.startIndex,a=(e.seriesLayoutBy!==Jd&&jr(""),[]),s={};if(h=e.dimensionsDefine)nt(h,function(t,e){var n=t.name,e={index:e,name:n,displayName:t.displayName};a.push(e),null!=n&&(X(s,n)&&jr(""),s[n]=e)});else for(var l=0;l<e.dimensionsDetectedCount;l++)a.push({index:l});var u=yf(o,Jd),h=(t.__isBuiltIn&&(n.getRawDataItem=function(t){return u(i,r,a,t)},n.getRawData=T(Jf,null,e)),n.cloneRawData=T(Qf,null,e),xf(o,Jd)),c=(n.count=T(h,null,i,r,a),wf(o)),p=(n.retrieveValue=function(t,e){t=u(i,r,a,t);return p(t,e)},n.retrieveValueFromItem=function(t,e){var n;return null!=t&&(n=a[e])?c(t,e,n.name):void 0});return n.getDimensionInfo=T(ty,null,a,s),n.cloneAllDimensionInfo=T(ey,null,a),n});return V(Jr(d.transform({upstream:e[0],upstreamList:e,config:S(t.config)})),function(t,e){O(t)||jr(""),t.data||jr("");oy(of(t.data))||jr("");var n=i[0],e=n&&0===e&&!t.dimensions?((e=n.startIndex)&&(t.data=n.data.slice(0,e).concat(t.data)),{seriesLayoutBy:Jd,sourceHeader:e,dimensions:n.metaRawOption.dimensions}):{seriesLayoutBy:Jd,sourceHeader:0,dimensions:t.dimensions};return ef(t.data,e,null)})}(n[i],e),i!==o-1&&(e.length=Math.max(e.length,1));return e}function oy(t){return t===Zd||t===jd}var ry,xp="undefined",ay=typeof Uint32Array==xp?Array:Uint32Array,sy=typeof Uint16Array==xp?Array:Uint16Array,ly=typeof Int32Array==xp?Array:Int32Array,jp=typeof Float64Array==xp?Array:Float64Array,uy={float:jp,int:ly,ordinal:Array,number:Array,time:jp};function hy(t){return 65535<t?ay:sy}function cy(){return[1/0,-1/0]}function py(t,e,n,i,o){n=uy[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)}gy.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=ry[i.sourceFormat];this._dimValueGetter=n||o,this._rawExtent=[],sf(i),this._dimensions=V(e,function(t){return{type:t.type,property:t.property}}),this._initDataFromProvider(0,t.count())},gy.prototype.getProvider=function(){return this._provider},gy.prototype.getSource=function(){return this._provider.getSource()},gy.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 uy[e||"float"](this._rawCount),this._rawExtent[o]=cy(),o},gy.prototype.collectOrdinalMeta=function(t,e){for(var n=this._chunks[t],i=this._dimensions[t],o=this._rawExtent,r=i.ordinalOffset||0,a=n.length,s=(0===r&&(o[t]=cy()),o[t]),l=r;l<a;l++){var u=n[l]=e.parseAndCollect(n[l]);isNaN(u)||(s[0]=Math.min(u,s[0]),s[1]=Math.max(u,s[1]))}i.ordinalMeta=e,i.ordinalOffset=a,i.type="ordinal"},gy.prototype.getOrdinalMeta=function(t){return this._dimensions[t].ordinalMeta},gy.prototype.getDimensionProperty=function(t){t=this._dimensions[t];return t&&t.property},gy.prototype.appendData=function(t){var e=this._provider,n=this.count(),t=(e.appendData(t),e.count());return e.persistent||(t+=n),n<t&&this._initDataFromProvider(n,t,!0),[n,t]},gy.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++)py(n,l,(d=i[l]).type,s,!0);for(var u=[],h=a;h<s;h++)for(var c=h-a,p=0;p<o;p++){var d=i[p],g=ry.arrayRows.call(this,t[c]||u,d.property,c,p),f=(n[p][h]=g,r[p]);g<f[0]&&(f[0]=g),g>f[1]&&(f[1]=g)}return{start:a,end:this._rawCount=this._count=s}},gy.prototype._initDataFromProvider=function(t,e,n){for(var i=this._provider,o=this._chunks,r=this._dimensions,a=r.length,s=this._rawExtent,l=V(r,function(t){return t.property}),u=0;u<a;u++){var h=r[u];s[u]||(s[u]=cy()),py(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 g=o[d],f=this._dimValueGetter(c,l[d],p,d),g=(g[p]=f,s[d]);f<g[0]&&(g[0]=f),f>g[1]&&(g[1]=f)}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=e,this._extent=[]},gy.prototype.count=function(){return this._count},gy.prototype.get=function(t,e){return 0<=e&&e<this._count&&(t=this._chunks[t])?t[this.getRawIndex(e)]:NaN},gy.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},gy.prototype.getByRawIndex=function(t,e){return 0<=e&&e<this._rawCount&&(t=this._chunks[t])?t[e]:NaN},gy.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},gy.prototype.getMedian=function(t){var e=[],t=(this.each([t],function(t){isNaN(t)||e.push(t)}),e.sort(function(t,e){return t-e})),n=this.count();return 0===n?0:n%2==1?t[(n-1)/2]:(t[n/2]+t[n/2-1])/2},gy.prototype.indexOfRawIndex=function(t){if(!(t>=this._rawCount||t<0)){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},gy.prototype.indicesOfNearest=function(t,e,n){var i=this._chunks[t],o=[];if(i){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)}o.length=s}return o},gy.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{i=new(e=hy(this._rawCount))(this.count());for(o=0;o<i.length;o++)i[o]=o}return i},gy.prototype.filter=function(t,e){if(!this._count)return this;for(var n=this.clone(),i=n.count(),o=new(hy(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},gy.prototype.selectRange=function(t){var e=this.clone(),n=e._count;if(!n)return this;var i=W(t),o=i.length;if(!o)return this;var r=e.count(),a=new(hy(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]],g=0;g<n;g++)(u<=(v=d[g])&&v<=h||isNaN(v))&&(a[s++]=p),p++;l=!0}else if(2===o){for(var d=c[i[0]],f=c[i[1]],y=t[i[1]][0],m=t[i[1]][1],g=0;g<n;g++){var v=d[g],x=f[g];(u<=v&&v<=h||isNaN(v))&&(y<=x&&x<=m||isNaN(x))&&(a[s++]=p),p++}l=!0}}if(!l)if(1===o)for(g=0;g<r;g++){var _=e.getRawIndex(g);(u<=(v=c[i[0]][_])&&v<=h||isNaN(v))&&(a[s++]=_)}else for(g=0;g<r;g++){for(var b=!0,_=e.getRawIndex(g),w=0;w<o;w++){var S=i[w];((v=c[S][_])<t[S][0]||v>t[S][1])&&(b=!1)}b&&(a[s++]=e.getRawIndex(g))}return s<r&&(e._indices=a),e._count=s,e._extent=[],e._updateGetRawIdx(),e},gy.prototype.map=function(t,e){var n=this.clone(t);return this._updateDims(n,t,e),n},gy.prototype.modify=function(t,e){this._updateDims(this,t,e)},gy.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]]=cy();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){"object"!=typeof d&&(o[0]=d,d=o);for(u=0;u<d.length;u++){var g=e[u],f=d[u],y=l[g],g=i[g];g&&(g[c]=f),f<y[0]&&(y[0]=f),f>y[1]&&(y[1]=f)}}}},gy.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(hy(this._rawCount))(Math.min(2*(Math.ceil(r/s)+2),r));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,g=0,f=c;f<p;f++){var y=o[M=this.getRawIndex(f)];isNaN(y)||(g+=y)}g/=p-c;for(var c=h,m=Math.min(h+s,r),v=h-1,x=o[l],_=-1,b=c,w=-1,S=0,f=c;f<m;f++){var M,y=o[M=this.getRawIndex(f)];isNaN(y)?(S++,w<0&&(w=M)):_<(n=Math.abs((v-d)*(y-x)-(v-f)*(g-x)))&&(_=n,b=M)}0<S&&S<m-c&&(u[a++]=Math.min(w,b),b=Math.max(w,b)),l=u[a++]=b}return u[a++]=this.getRawIndex(r-1),i._count=a,i._indices=u,i.getRawIndex=this._getRawIdx,i},gy.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]=cy(),c=new(hy(this._rawCount))(Math.ceil(u/s)),p=0,d=0;d<u;d+=s){u-d<s&&(a.length=s=u-d);for(var g=0;g<s;g++){var f=this.getRawIndex(d+g);a[g]=l[f]}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},gy.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)}}},gy.prototype.getDataExtent=function(t){var e=this._chunks[t],n=cy();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]},gy.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},gy.prototype.clone=function(t,e){var n,i,o=new gy,r=this._chunks,a=t&&ct(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},gy.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=S(this._extent),t._rawExtent=S(this._rawExtent)},gy.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},gy.prototype._getRawIdxIdentity=function(t){return t},gy.prototype._getRawIdx=function(t){return t<this._count&&0<=t?this._indices[t]:-1},gy.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},gy.internalField=void(ry={arrayRows:fy,objectRows:function(t,e,n,i){return Ff(t[e],this._dimensions[i])},keyedColumns:fy,original:function(t,e,n,i){t=t&&(null==t.value?t:t.value);return Ff(t instanceof Array?t[i]:t,this._dimensions[i])},typedArray:function(t,e,n,i){return t[i]}});var dy=gy;function gy(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=R()}function fy(t,e,n,i){return Ff(t[i],this._dimensions[i])}my.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},my.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,9e10<this._versionSignBase&&(this._versionSignBase=0)},my.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},my.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},my.prototype._createSource=function(){this._setLocalSource([],[]);var t,e,n,i,o,r,a,s=this._sourceHost,l=this._getUpstreamSourceManagers(),u=!!l.length;xy(s)?(i=s,o=t=r=void 0,e=u?((e=l[0]).prepareSource(),r=(o=e.getSource()).data,t=o.sourceFormat,[e._getVersionSign()]):(t=yt(r=i.get("data",!0))?Kd:Ud,[]),i=this._getSourceMetaRawOption()||{},o=o&&o.metaRawOption||{},a=N(i.seriesLayoutBy,o.seriesLayoutBy)||null,n=N(i.sourceHeader,o.sourceHeader),i=N(i.dimensions,o.dimensions),o=a!==o.seriesLayoutBy||!!n!=!!o.sourceHeader||i?[ef(r,{seriesLayoutBy:a,sourceHeader:n,dimensions:i},t)]:[]):(r=s,e=u?(o=(a=this._applyTransform(l)).sourceList,a.upstreamSignList):(o=[ef(r.get("source",!0),this._getSourceMetaRawOption(),null)],[])),this._setLocalSource(o,e)},my.prototype._applyTransform=function(t){var e,n=this._sourceHost,i=n.get("transform",!0),o=n.get("fromTransformResult",!0),r=(null!=o&&1!==t.length&&_y(""),[]),a=[];return nt(t,function(t){t.prepareSource();var e=t.getSource(o||0);null==o||e||_y(""),r.push(e),a.push(t._getVersionSign())}),i?e=iy(i,r,n.componentIndex):null!=o&&(e=[new Qg({data:(t=r[0]).data,sourceFormat:t.sourceFormat,seriesLayoutBy:t.seriesLayoutBy,dimensionsDefine:S(t.dimensionsDefine),startIndex:t.startIndex,dimensionsDetectedCount:t.dimensionsDetectedCount})]),{sourceList:e,upstreamSignList:a}},my.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}},my.prototype.getSource=function(t){var e=this._sourceList[t=t||0];return e||(e=this._getUpstreamSourceManagers())[0]&&e[0].getSource(t)},my.prototype.getSharedDataStore=function(t){var e=t.makeStoreSchema();return this._innerGetDataStore(e.dimensions,t.source,e.hash)},my.prototype._innerGetDataStore=function(t,e,n){var i,o=this._storeList,r=o[0],o=(r=r||(o[0]={}))[n];return o||(i=this._getUpstreamSourceManagers()[0],xy(this._sourceHost)&&i?o=i._innerGetDataStore(t,e,n):(o=new dy).initData(new cf(e,t.length),t),r[n]=o),o},my.prototype._getUpstreamSourceManagers=function(){var t,e=this._sourceHost;return xy(e)?(t=og(e))?[t.getSourceManager()]:[]:V((t=e).get("transform",!0)||t.get("fromTransformResult",!0)?fa(t.ecModel,"dataset",{index:t.get("fromDatasetIndex",!0),id:t.get("fromDatasetId",!0)},da).models:[],function(t){return t.getSourceManager()})},my.prototype._getSourceMetaRawOption=function(){var t,e,n,i=this._sourceHost;return xy(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}};var yy=my;function my(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}function vy(t){t.option.transform&&At(t.option.transform)}function xy(t){return"series"===t.mainType}function _y(t){throw new Error(t)}var by="line-height:1";function wy(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:"+we(i+"")+"px;color:"+we(n)+";font-weight:"+we(o+""),valueStyle:"font-size:"+we(a+"")+"px;color:"+we(r)+";font-weight:"+we(t+"")}:{nameStyle:{fontSize:i,fill:n,fontWeight:o},valueStyle:{fontSize:a,fill:r,fontWeight:t}}}var Sy=[0,10,20,30],My=["","\n","\n\n","\n\n\n"];function Iy(t,e){return e.type=t,e}function Ty(t){return"section"===t.type}function Cy(t){return Ty(t)?Dy:Ay}function Dy(i,o,t,r){var n,e=o.noHeader,a=(l=function n(t){var i,e,o;return Ty(t)?(i=0,e=t.blocks.length,o=1<e||0<e&&!t.noHeader,nt(t.blocks,function(t){var e=n(t);i<=e&&(i=e+ +(o&&(!e||Ty(t)&&!t.noHeader)))}),i):0}(o),{html:Sy[l],richText:My[l]}),s=[],l=o.blocks||[],u=(Tt(!l||B(l)),l=l||[],i.orderMode),h=(o.sortBlocks&&u&&(l=l.slice(),X(h={valueAsc:"asc",valueDesc:"desc"},u)?(n=new Uf(h[u],null),l.sort(function(t,e){return n.evaluate(t.sortParam,e.sortParam)})):"seriesDesc"===u&&l.reverse()),nt(l,function(t,e){var n=o.valueFormatter,n=Cy(t)(n?F(F({},i),{valueFormatter:n}):i,t,0<e?a.html:0,r);null!=n&&s.push(n)}),"richText"===i.renderMode?s.join(a.richText):Ly(s.join(""),e?t:a.html));return e?h:(u=xd(o.header,"ordinal",i.useUTC),l=wy(r,i.renderMode).nameStyle,"richText"===i.renderMode?Py(i,u,l)+a.richText+h:Ly('<div style="'+l+";"+by+';">'+we(u)+"</div>"+h,t))}function Ay(t,e,n,i){var o,r,a,s,l=t.renderMode,u=e.noName,h=e.noValue,c=!e.markerType,p=e.name,d=t.useUTC,g=e.valueFormatter||t.valueFormatter||function(t){return V(t=B(t)?t:[t],function(t,e){return xd(t,B(r)?r[e]:r,d)})};if(!u||!h)return o=c?"":t.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",l),p=u?"":xd(p,"ordinal",d),r=e.valueType,g=h?[]:g(e.value,e.dataIndex),e=!c||!u,a=!c&&u,i=wy(i,l),s=i.nameStyle,i=i.valueStyle,"richText"===l?(c?"":o)+(u?"":Py(t,p,s))+(h?"":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(B(e)?e.join(" "):e,o)}(t,g,e,a,i)):Ly((c?"":o)+(u?"":'<span style="'+s+";"+(!c?"margin-left:2px":"")+'">'+we(p)+"</span>")+(h?"":function(t,e,n,i){n=n?"10px":"20px",e=e?"float:right;margin-left:"+n:"";return t=B(t)?t:[t],'<span style="'+e+";"+i+'">'+V(t,we).join(" ")+"</span>"}(g,e,a,i)),n)}function ky(t,e,n,i,o,r){if(t)return Cy(t)({useUTC:o,renderMode:n,orderMode:i,markupStyleCreator:e,valueFormatter:t.valueFormatter},t,0,r)}function Ly(t,e){return'<div style="'+("margin: "+e+"px 0 0")+";"+by+';">'+t+'<div style="clear:both"></div></div>'}function Py(t,e,n){return t.markupStyleCreator.wrapRichTextStyle(e,n)}function Oy(t,e){return Md(t.getData().getItemVisual(e,"style")[t.visualDrawType])}function Ny(t,e){t=t.get("padding");return null!=t?t:"richText"===e?[8,10]:10}Ey.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},Ey.prototype.makeTooltipMarker=function(t,e,n){var i="richText"===n?this._generateStyleName():null,e=Sd({color:e,type:t,renderMode:n,markerId:i});return H(e)?e:(this.richTextStyles[i]=e.style,e.content)},Ey.prototype.wrapRichTextStyle=function(t,e){var n={},e=(B(e)?nt(e,function(t){return F(n,t)}):F(n,e),this._generateStyleName());return this.richTextStyles[e]=n,"{"+e+"|"+t+"}"};var Ry=Ey;function Ey(){this.richTextStyles={},this._nextStyleNameId=Ur()}function zy(t){var e,n,i,o,r,a,s,l,u,h,c,p=t.series,d=t.dataIndex,t=t.multipleSeries,g=p.getData(),f=g.mapDimensionsAll("defaultedTooltip"),y=f.length,m=p.getRawValue(d),v=B(m),x=Oy(p,d);function _(t,e){e=s.getDimensionInfo(e);e&&!1!==e.otherDims.tooltip&&(l?c.push(Iy("nameValue",{markerType:"subItem",markerColor:a,name:e.displayName,value:t,valueType:e.type})):(u.push(t),h.push(e.type)))}1<y||v&&!y?(i=m,o=d,r=f,a=x,s=p.getData(),l=ct(i,function(t,e,n){n=s.getDimensionInfo(n);return t||n&&!1!==n.tooltip&&null!=n.displayName},!1),u=[],h=[],c=[],r.length?nt(r,function(t){_(Mf(s,o,t),t)}):nt(i,_),i=(r={inlineValues:u,inlineValueTypes:h,blocks:c}).inlineValueTypes,e=r.blocks,n=(r=r.inlineValues)[0]):y?(y=g.getDimensionInfo(f[0]),n=r=Mf(g,d,f[0]),i=y.type):n=r=v?m[0]:m;f=aa(p),y=f&&p.name||"",v=g.getName(d),m=t?y:v;return Iy("section",{header:y,noHeader:t||!f,sortParam:n,blocks:[Iy("nameValue",{markerType:"item",markerColor:x,name:m,noName:!Ct(m),value:r,valueType:i,dataIndex:d})].concat(e||[])})}var Vy=i();function By(t,e){return t.getName(e)||t.getId(e)}u(Wy,Fy=g),Wy.prototype.init=function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=Df({count:Yy,reset:Xy}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n);(Vy(this).sourceManager=new yy(this)).prepareSource();t=this.getInitialData(t,n);Zy(t,this),this.dataTask.context.data=t,Vy(this).dataBeforeProcessed=t,Hy(this),this._initSelectedMapFromData(t)},Wy.prototype.mergeDefaultAndTheme=function(t,e){var n=Od(this),i=n?Rd(t):{},o=this.subType;g.hasClass(o),d(t,e.getTheme().get(this.subType)),d(t,this.getDefaultOption()),Qr(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Nd(t,i,n)},Wy.prototype.mergeOption=function(t,e){t=d(this.option,t,!0),this.fillDataTextStyle(t.data);var n=Od(this),n=(n&&Nd(this.option,t,n),Vy(this).sourceManager),n=(n.dirty(),n.prepareSource(),this.getInitialData(t,e));Zy(n,this),this.dataTask.dirty(),this.dataTask.context.data=n,Vy(this).dataBeforeProcessed=n,Hy(this),this._initSelectedMapFromData(n)},Wy.prototype.fillDataTextStyle=function(t){if(t&&!yt(t))for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&Qr(t[n],"label",e)},Wy.prototype.getInitialData=function(t,e){},Wy.prototype.appendData=function(t){this.getRawData().appendData(t.data)},Wy.prototype.getData=function(t){var e=qy(this);return e?(e=e.context.data,null==t?e:e.getLinkedData(t)):Vy(this).data},Wy.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},Wy.prototype.setData=function(t){var e,n=qy(this);n&&((e=n.context).outputData=t,n!==this.dataTask)&&(e.data=t),Vy(this).data=t},Wy.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return R(t)},Wy.prototype.getSourceManager=function(){return Vy(this).sourceManager},Wy.prototype.getSource=function(){return this.getSourceManager().getSource()},Wy.prototype.getRawData=function(){return Vy(this).dataBeforeProcessed},Wy.prototype.getColorBy=function(){return this.get("colorBy")||"series"},Wy.prototype.isColorBySeries=function(){return"series"===this.getColorBy()},Wy.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},Wy.prototype.formatTooltip=function(t,e,n){return zy({series:this,dataIndex:t,multipleSeries:e})},Wy.prototype.isAnimationEnabled=function(){var t=this.ecModel;return!!(!w.node||t&&t.ssr)&&!!(t=(t=this.getShallow("animation"))&&this.getData().count()>this.getShallow("animationThreshold")?!1:t)},Wy.prototype.restoreData=function(){this.dataTask.dirty()},Wy.prototype.getColorFromPalette=function(t,e,n){var i=this.ecModel;return dg.prototype.getColorFromPalette.call(this,t,e,n)||i.getColorFromPalette(t,e,n)},Wy.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},Wy.prototype.getProgressive=function(){return this.get("progressive")},Wy.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},Wy.prototype.select=function(t,e){this._innerSelect(this.getData(e),t)},Wy.prototype.unselect=function(t,e){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,o=this.getData(e);if("series"===i||"all"===n)this.option.selectedMap={},this._selectedDataIndicesMap={};else for(var r=0;r<t.length;r++){var a=By(o,t[r]);n[a]=!1,this._selectedDataIndicesMap[a]=-1}}},Wy.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)},Wy.prototype.getSelectedDataIndices=function(){if("all"===this.option.selectedMap)return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,e=W(t),n=[],i=0;i<e.length;i++){var o=t[e[i]];0<=o&&n.push(o)}return n},Wy.prototype.isSelected=function(t,e){var n=this.option.selectedMap;return!!n&&(e=this.getData(e),"all"===n||n[By(e,t)])&&!e.getItemModel(t).get(["select","disabled"])},Wy.prototype.isUniversalTransitionEnabled=function(){var t;return!!this.__universalTransitionEnabled||!!(t=this.option.universalTransition)&&(!0===t||t&&t.enabled)},Wy.prototype._innerSelect=function(t,e){var n=this.option,i=n.selectedMode,o=e.length;if(i&&o)if("series"===i)n.selectedMap="all";else if("multiple"===i){O(n.selectedMap)||(n.selectedMap={});for(var r=n.selectedMap,a=0;a<o;a++){var s,l=e[a];r[s=By(t,l)]=!0,this._selectedDataIndicesMap[s]=t.getRawIndex(l)}}else"single"!==i&&!0!==i||(s=By(t,i=e[o-1]),n.selectedMap=((n={})[s]=!0,n),this._selectedDataIndicesMap=((n={})[s]=t.getRawIndex(i),n))},Wy.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))},Wy.registerClass=function(t){return g.registerClass(t)},Wy.protoInitialize=((Sp=Wy.prototype).type="series.__base__",Sp.seriesIndex=0,Sp.ignoreStyleOnData=!1,Sp.hasSymbolVisual=!1,Sp.defaultSymbol="circle",Sp.visualStyleAccessPath="itemStyle",void(Sp.visualDrawType="fill"));var Fy,Gy=Wy;function Wy(){var t=null!==Fy&&Fy.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}function Hy(t){var e,n,i=t.name;aa(t)||(t.name=(t=(e=(t=t).getRawData()).mapDimensionsAll("seriesName"),n=[],nt(t,function(t){t=e.getDimensionInfo(t);t.displayName&&n.push(t.displayName)}),n.join(" ")||i))}function Yy(t){return t.model.getRawData().count()}function Xy(t){t=t.model;return t.setData(t.getRawData().cloneShallow()),Uy}function Uy(t,e){e.outputData&&t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Zy(e,n){nt(Et(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(t){e.wrapMethod(t,P(jy,n))})}function jy(t,e){t=qy(t);return t&&t.setOutputEnd((e||this).count()),e}function qy(t){var e,n=(t.ecModel||{}).scheduler,n=n&&n.getPipeline(t.uid);if(n)return(n=n.currentTask)&&(e=n.agentStubMap)?e.get(t.uid):n}ut(Gy,Cp),ut(Gy,dg),Ma(Gy,g);$y.prototype.init=function(t,e){},$y.prototype.render=function(t,e,n,i){},$y.prototype.dispose=function(t,e){},$y.prototype.updateView=function(t,e,n,i){},$y.prototype.updateLayout=function(t,e,n,i){},$y.prototype.updateVisual=function(t,e,n,i){},$y.prototype.toggleBlurSeries=function(t,e,n){},$y.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)};var Ky=$y;function $y(){this.group=new Z,this.uid=Op("viewComponent")}function Jy(){var r=i();return function(t){var e=r(t),t=t.pipelineContext,n=!!e.large,i=!!e.progressiveRender,o=e.large=!(!t||!t.large),e=e.progressiveRender=!(!t||!t.progressiveRender);return!(n==o&&i==e)&&"reset"}}Sa(Ky),Da(Ky);var Qy=i(),tm=Jy(),em=(nm.prototype.init=function(t,e){},nm.prototype.render=function(t,e,n,i){},nm.prototype.highlight=function(t,e,n,i){t=t.getData(i&&i.dataType);t&&om(t,i,"emphasis")},nm.prototype.downplay=function(t,e,n,i){t=t.getData(i&&i.dataType);t&&om(t,i,"normal")},nm.prototype.remove=function(t,e){this.group.removeAll()},nm.prototype.dispose=function(t,e){},nm.prototype.updateView=function(t,e,n,i){this.render(t,e,n,i)},nm.prototype.updateLayout=function(t,e,n,i){this.render(t,e,n,i)},nm.prototype.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},nm.prototype.eachRendered=function(t){Qc(this.group,t)},nm.markUpdateMethod=function(t,e){Qy(t).updateMethod=e},nm.protoInitialize=void(nm.prototype.type="chart"),nm);function nm(){this.group=new Z,this.uid=Op("viewChart"),this.renderTask=Df({plan:rm,reset:am}),this.renderTask.context={view:this}}function im(t,e,n){t&&ku(t)&&("emphasis"===e?cu:pu)(t,n)}function om(e,t,n){var i,o=ua(e,t),r=t&&null!=t.highlightKey?(t=t.highlightKey,i=null==(i=El[t])&&Rl<=32?El[t]=Rl++:i):null;null!=o?nt(Jr(o),function(t){im(e.getItemGraphicEl(t),n,r)}):e.eachItemGraphicEl(function(t){im(t,n,r)})}function rm(t){return tm(t.model)}function am(t){var e=t.model,n=t.ecModel,i=t.api,o=t.payload,r=e.pipelineContext.progressiveRender,t=t.view,a=o&&Qy(o).updateMethod,r=r?"incrementalPrepareRender":a&&t[a]?a:"render";return"render"!==r&&t[r](e,n,i,o),sm[r]}Sa(em),Da(em);var sm={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)}}},lm="\0__throttleOriginMethod",um="\0__throttleRate",hm="\0__throttleType";function cm(t,o,r){var a,s,l,u,h,c=0,p=0,d=null;function g(){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(g,n):0<=s?g():d=setTimeout(g,-s),c=a}return e.clear=function(){d&&(clearTimeout(d),d=null)},e.debounceNextCall=function(t){h=t},e}function pm(t,e,n,i){var o=t[e];if(o){var r=o[lm]||o,a=o[hm];if(o[um]!==n||a!==i){if(null==n||!i)return t[e]=r;(o=t[e]=cm(r,n,"debounce"===i))[lm]=r,o[hm]=i,o[um]=n}return o}}function dm(t,e){var n=t[e];n&&n[lm]&&(n.clear&&n.clear(),t[e]=n[lm])}var gm=i(),fm={itemStyle:Aa(Ip,!0),lineStyle:Aa(bp,!0)},ym={lineStyle:"stroke",itemStyle:"fill"};function mm(t,e){t=t.visualStyleMapper||fm[e];return t||(console.warn("Unknown style type '"+e+"'."),fm.itemStyle)}function vm(t,e){t=t.visualDrawType||ym[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var La={createOnAllSeries:!0,performRawSeries:!0,reset:function(o,t){var e=o.getData(),n=o.visualStyleAccessPath||"itemStyle",i=o.getModel(n),r=mm(o,n)(i),i=i.getShallow("decal"),a=(i&&(e.setVisual("decal",i),i.dirty=!0),vm(o,n)),i=r[a],s=D(i)?i:null,n="auto"===r.fill||"auto"===r.stroke;if(r[a]&&!s&&!n||(i=o.getColorFromPalette(o.name,null,t.getSeriesCount()),r[a]||(r[a]=i,e.setVisual("colorFromPalette",!0)),r.fill="auto"===r.fill||D(r.fill)?i:r.fill,r.stroke="auto"===r.stroke||D(r.stroke)?i: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=F({},r);i[a]=s(n),t.setItemVisual(e,"style",i)}}}},xm=new kp,xp={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var i,o,r;if(!t.ignoreStyleOnData&&!e.isSeriesFiltered(t))return e=t.getData(),i=t.visualStyleAccessPath||"itemStyle",o=mm(t,i),r=e.getVisual("drawType"),{dataEach:e.hasItemOption?function(t,e){var n=t.getRawDataItem(e);n&&n[i]&&(xm.option=n[i],n=o(xm),F(t.ensureUniqueItemVisual(e,"style"),n),xm.option.decal&&(t.setItemVisual(e,"decal",xm.option.decal),xm.option.decal.dirty=!0),r in n)&&t.setItemVisual(e,"colorFromPalette",!1)}:null}}},jp={performRawSeries:!0,overallReset:function(e){var i=R();e.eachSeries(function(t){var e,n=t.getColorBy();t.isColorBySeries()||(n=t.type+"-"+n,(e=i.get(n))||i.set(n,e={}),gm(t).scope=e)}),e.eachSeries(function(i){var o,r,a,s,t,l;i.isColorBySeries()||e.isSeriesFiltered(i)||(o=i.getRawData(),r={},a=i.getData(),s=gm(i).scope,t=i.visualStyleAccessPath||"itemStyle",l=vm(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")&&(n=a.ensureUniqueItemVisual(n,"style"),t=o.getName(t)||t+"",e=o.count(),n[l]=i.getColorFromPalette(t,s,e))}))})}},_m=Math.PI;wm.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(t){t=t.overallTask;t&&t.dirty()})},wm.prototype.getPerformArgs=function(t,e){var n,i;if(t.__pipeline)return i=(n=this._pipelineMap.get(t.__pipeline.id)).context,{step:e=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,modBy:null!=(t=i&&i.modDataCount)?Math.ceil(t/e):null,modDataCount:t}},wm.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},wm.prototype.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),e=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,o=t.get("large")&&i>=t.get("largeThreshold"),i="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:e,modDataCount:i,large:o}},wm.prototype.restorePipelines=function(t){var i=this,o=i._pipelineMap=R();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)})},wm.prototype.prepareStageTasks=function(){var n=this._stageTaskMap,i=this.api.getModel(),o=this.api;nt(this._allHandlers,function(t){var e=n.get(t.uid)||n.set(t.uid,{});Tt(!(t.reset&&t.overallReset),""),t.reset&&this._createSeriesStageTask(t,e,i,o),t.overallReset&&this._createOverallStageTask(t,e,i,o)},this)},wm.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)},wm.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},wm.prototype.performVisualTasks=function(t,e,n){this._performStageTasks(this._visualHandlers,t,e,n)},wm.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))}nt(t,function(i,t){var e,n,o,r,a;u.visualType&&u.visualType!==i.visualType||(e=(n=c._stageTaskMap.get(i.uid)).seriesTaskMap,(n=n.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},wm.prototype.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e=t.dataTask.perform()||e}),this.unfinished=e||this.unfinished},wm.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())})},wm.prototype.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},wm.prototype._createSeriesStageTask=function(n,t,i,o){var r=this,a=t.seriesTaskMap,s=t.seriesTaskMap=R(),t=n.seriesType,e=n.getTargetSeries;function l(t){var e=t.uid,e=s.set(e,a&&a.get(e)||Df({plan:Cm,reset:Dm,count:Lm}));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):t?i.eachRawSeriesByType(t,l):e&&e(i,o).each(l)},wm.prototype._createOverallStageTask=function(t,e,n,i){var o=this,r=e.overallTask=e.overallTask||Df({reset:Sm}),a=(r.context={ecModel:n,api:i,overallReset:t.overallReset,scheduler:o},r.agentStubMap),s=r.agentStubMap=R(),e=t.seriesType,l=t.getTargetSeries,u=!0,h=!1;function c(t){var e=t.uid,e=s.set(e,a&&a.get(e)||(h=!0,Df({reset:Mm,onDirty:Tm})));e.context={model:t,overallProgress:u},e.agent=r,e.__block=u,o._pipe(t,e)}Tt(!t.createOnAllSeries,""),e?n.eachRawSeriesByType(e,c):l?l(n,i).each(c):(u=!1,nt(n.getSeries(),c)),h&&r.dirty()},wm.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},wm.wrapStageHandler=function(t,e){return(t=D(t)?{overallReset:t,seriesType:function(t){Pm=null;try{t(Om,Nm)}catch(t){}return Pm}(t)}:t).uid=Op("stageHandler"),e&&(t.visualType=e),t};var bm=wm;function wm(t,e,n,i){this._stageTaskMap=R(),this.ecInstance=t,this.api=e,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}function Sm(t){t.overallReset(t.ecModel,t.api,t.payload)}function Mm(t){return t.overallProgress&&Im}function Im(){this.agent.dirty(),this.getDownstream().dirty()}function Tm(){this.agent&&this.agent.dirty()}function Cm(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function Dm(t){t.useClearVisual&&t.data.clearAllVisual();t=t.resetDefines=Jr(t.reset(t.model,t.ecModel,t.api,t.payload));return 1<t.length?V(t,function(t,e){return km(e)}):Am}var Am=km(0);function km(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 Lm(t){return t.data.count()}var Pm,Om={},Nm={};function Rm(t,e){for(var n in e.prototype)t[n]=Bt}Rm(Om,vg),Rm(Nm,Sg),Om.eachSeriesByType=Om.eachRawSeriesByType=function(t){Pm=t},Om.eachComponent=function(t){"series"===t.mainType&&t.subType&&(Pm=t.subType)};function Em(){return{axisLine:{lineStyle:{color:zm}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}}var Sp=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],Ip={color:Sp,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],Sp]},zm="#B9B8CE",bp="#100C2A",Sp=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],bp={darkMode:!0,color:Sp,backgroundColor:bp,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:zm}},textStyle:{color:zm},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:zm}},dataZoom:{borderColor:"#71708A",textStyle:{color:zm},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:zm}},timeline:{lineStyle:{color:zm},label:{color:zm},controlStyle:{color:zm,borderColor:zm}},calendar:{itemStyle:{color:bp},dayLabel:{color:zm},monthLabel:{color:zm},yearLabel:{color:zm}},timeAxis:Em(),logAxis:Em(),valueAxis:Em(),categoryAxis:Em(),line:{symbol:"circle"},graph:{color:Sp},gauge:{title:{color:zm},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:zm},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}},Vm=(bp.categoryAxis.splitLine.show=!1,Bm.prototype.normalizeQuery=function(t){var e,a,s,l={},u={},h={};return H(t)?(e=wa(t),l.mainType=e.main||null,l.subType=e.sub||null):(a=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1},nt(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}},Bm.prototype.filter=function(t,e){var n,i,o,r,a,s=this.eventInfo;return!s||(n=s.targetEl,i=s.packedEvent,o=s.model,s=s.view,!o)||!s||(r=e.cptQuery,a=e.dataQuery,l(r,o,"mainType")&&l(r,o,"subType")&&l(r,o,"index","componentIndex")&&l(r,o,"name")&&l(r,o,"id")&&l(a,i,"name")&&l(a,i,"dataIndex")&&l(a,i,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,n,i)));function l(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},Bm.prototype.afterTrigger=function(){this.eventInfo=null},Bm);function Bm(){}var Fm=["symbol","symbolSize","symbolRotate","symbolOffset"],Gm=Fm.concat(["symbolKeepAspect"]),Sp={createOnAllSeries:!0,performRawSeries:!0,reset:function(a,t){var e=a.getData();if(a.legendIcon&&e.setVisual("legendIcon",a.legendIcon),a.hasSymbolVisual){for(var s,n={},l={},i=!1,o=0;o<Fm.length;o++){var r=Fm[o],u=a.get(r);D(u)?(i=!0,l[r]=u):n[r]=u}if(n.symbol=n.symbol||a.defaultSymbol,e.setVisual(F({legendIcon:a.legendIcon||n.symbol,symbolKeepAspect:a.get("symbolKeepAspect")},n)),!t.isSeriesFiltered(a))return s=W(l),{dataEach:i?function(t,e){for(var n=a.getRawValue(e),i=a.getDataParams(e),o=0;o<s.length;o++){var r=s[o];t.setItemVisual(e,r,l[r](n,i))}}:null}}}},Wm={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(t.hasSymbolVisual&&!e.isSeriesFiltered(t))return{dataEach:t.getData().hasItemOption?function(t,e){for(var n=t.getItemModel(e),i=0;i<Gm.length;i++){var o=Gm[i],r=n.getShallow(o,!0);null!=r&&t.setItemVisual(e,o,r)}}:null}}};function Hm(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 Ym(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 Xm(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 Um(r,t){nt([[r+"ToggleSelect","toggleSelect"],[r+"Select","select"],[r+"UnSelect","unselect"]],function(o){t(o[0],function(t,e,n){var i;t=F({},t),n.dispatchAction(F(t,{type:o[1],seriesIndex:(n=t,i=[],e.eachComponent({mainType:"series",subType:r,query:n},function(t){i.push(t.seriesIndex)}),i)}))})})}function Zm(t,e,s,n,l){var u=t+e;s.isSilent(u)||n.eachComponent({mainType:"series",subType:"pie"},function(t){for(var e,n,i=t.seriesIndex,o=t.option.selectedMap,r=l.selected,a=0;a<r.length;a++)r[a].seriesIndex===i&&(n=ua(e=t.getData(),l.fromActionPayload),s.trigger(u,{type:u,seriesId:t.id,name:B(n)?e.getName(n[0]):e.getName(n),selected:H(o)?o:F({},o)}))})}function jm(t,e,n){for(var i;t&&(!e(t)||(i=t,!n));)t=t.__hostTarget||t.parent;return i}var qm=Math.round(9*Math.random()),Km="function"==typeof Object.defineProperty,$m=(Jm.prototype.get=function(t){return this._guard(t)[this._id]},Jm.prototype.set=function(t,e){t=this._guard(t);return Km?Object.defineProperty(t,this._id,{value:e,enumerable:!1,configurable:!0}):t[this._id]=e,this},Jm.prototype.delete=function(t){return!!this.has(t)&&(delete this._guard(t)[this._id],!0)},Jm.prototype.has=function(t){return!!this._guard(t)[this._id]},Jm.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},Jm);function Jm(){this._id="__ec_inner_"+qm++}var Qm=q.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()}}),t0=q.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()}}),e0=q.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,e=Math.max(o,e.height),o=o/2,r=o*o/(e-o),e=i-e+o+r,a=Math.asin(r/o),s=Math.cos(a)*o,l=Math.sin(a),u=Math.cos(a),h=.6*o,c=.7*o;t.moveTo(n-s,e+r),t.arc(n,e,o,Math.PI-a,2*Math.PI+a),t.bezierCurveTo(n+s-l*h,e+r+u*h,n,i-c,n,i),t.bezierCurveTo(n,i-c,n-s+l*h,e+r+u*h,n-s,e+r),t.closePath()}}),n0=q.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()}}),i0={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){n=Math.min(n,i);o.x=t,o.y=e,o.width=n,o.height=n},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}},o0={},r0=(nt({line:Fh,rect:L,roundRect:L,square:L,circle:eh,diamond:t0,pin:e0,arrow:n0,triangle:Qm},function(t,e){o0[e]=new t}),q.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,e,n){var t=nr(t,e,n),i=this.shape;return i&&"pin"===i.symbolType&&"inside"===e.position&&(t.y=n.y+.4*n.height),t},buildPath:function(t,e,n){var i,o=e.symbolType;"none"!==o&&(i=(i=o0[o])||o0[o="rect"],i0[o](e.x,e.y,e.width,e.height,i.shape),i.buildPath(t,i.shape,n))}}));function a0(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 s0(t,e,n,i,o,r,a){var s=0===t.indexOf("empty");return(a=0===(t=s?t.substr(5,1).toLowerCase()+t.substr(6):t).indexOf("image://")?Rc(t.slice(8),new U(e,n,i,o),a?"center":"cover"):0===t.indexOf("path://")?Nc(t.slice(7),{},new U(e,n,i,o),a?"center":"cover"):new r0({shape:{symbolType:t,x:e,y:n,width:i,height:o}})).__isEmptyBrush=s,a.setColor=a0,r&&a.setColor(r),a}function l0(t){return[(t=B(t)?t:[+t,+t])[0]||0,t[1]||0]}function u0(t,e){if(null!=t)return[j((t=B(t)?t:[t,t])[0],e[0])||0,j(N(t[1],t[0]),e[1])||0]}function h0(t){return isFinite(t)}function c0(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),u=h0(u)?u:.5,h=h0(h)?h:.5,c=0<=c&&h0(c)?c:.5,i.createRadialGradient(u,h,0,u,h,c)):(o=t,a=n,r=null==(s=e).x?0:s.x,l=null==s.x2?1:s.x2,i=null==s.y?0:s.y,u=null==s.y2?0:s.y2,s.global||(r=r*a.width+a.x,l=l*a.width+a.x,i=i*a.height+a.y,u=u*a.height+a.y),r=h0(r)?r:0,l=h0(l)?l:1,i=h0(i)?i:0,u=h0(u)?u:0,o.createLinearGradient(r,i,l,u)),d=e.colorStops,g=0;g<d.length;g++)p.addColorStop(d[g].offset,d[g].color);return p}function p0(t){return parseInt(t,10)}function d0(t,e,n){var i=["width","height"][e],o=["clientWidth","clientHeight"][e],r=["paddingLeft","paddingTop"][e],e=["paddingRight","paddingBottom"][e];return null!=n[i]&&"auto"!==n[i]?parseFloat(n[i]):(n=document.defaultView.getComputedStyle(t),(t[o]||p0(n[i])||p0(t.style[i]))-(p0(n[r])||0)-(p0(n[e])||0)|0)}function g0(t){var e,n=t.style,i=n.lineDash&&0<n.lineWidth&&(o=n.lineDash,i=n.lineWidth,o&&"solid"!==o&&0<i?"dashed"===o?[4*i,2*i]:"dotted"===o?[i]:Y(o)?[o]:B(o)?o:null:null),o=n.lineDashOffset;return i&&(e=n.strokeNoScale&&t.getLineScale?t.getLineScale():1)&&1!==e&&(i=V(i,function(t){return t/e}),o/=e),[i,o]}var f0=new Ns(!0);function y0(t){var e=t.stroke;return!(null==e||"none"===e||!(0<t.lineWidth))}function m0(t){return"string"==typeof t&&"none"!==t}function v0(t){t=t.fill;return null!=t&&"none"!==t}function x0(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 _0(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 b0(t,e,n){var n=Na(e.image,e.__image,n);if(Ea(n))return t=t.createPattern(n,e.repeat||"repeat"),"function"==typeof DOMMatrix&&t&&t.setTransform&&((n=new DOMMatrix).translateSelf(e.x||0,e.y||0),n.rotateSelf(0,0,(e.rotation||0)*Ft),n.scaleSelf(e.scaleX||1,e.scaleY||1),t.setTransform(n)),t}var w0=["shadowBlur","shadowOffsetX","shadowOffsetY"],S0=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function M0(t,e,n,i,o){var r,a=!1;if(!i&&e===(n=n||{}))return!1;!i&&e.opacity===n.opacity||(L0(t,o),a=!0,r=Math.max(Math.min(e.opacity,1),0),t.globalAlpha=isNaN(r)?Ka.opacity:r),!i&&e.blend===n.blend||(a||(L0(t,o),a=!0),t.globalCompositeOperation=e.blend||Ka.blend);for(var s=0;s<w0.length;s++){var l=w0[s];!i&&e[l]===n[l]||(a||(L0(t,o),a=!0),t[l]=t.dpr*(e[l]||0))}return!i&&e.shadowColor===n.shadowColor||(a||(L0(t,o),a=!0),t.shadowColor=e.shadowColor||Ka.shadowColor),a}function I0(t,e,n,i,o){var r=P0(e,o.inHover),a=i?null:n&&P0(n,o.inHover)||{};if(r!==a){var s=M0(t,r,a,i,o);(i||r.fill!==a.fill)&&(s||(L0(t,o),s=!0),m0(r.fill))&&(t.fillStyle=r.fill),(i||r.stroke!==a.stroke)&&(s||(L0(t,o),s=!0),m0(r.stroke))&&(t.strokeStyle=r.stroke),!i&&r.opacity===a.opacity||(s||(L0(t,o),s=!0),t.globalAlpha=null==r.opacity?1:r.opacity),e.hasStroke()&&(n=r.lineWidth/(r.strokeNoScale&&e.getLineScale?e.getLineScale():1),t.lineWidth!==n)&&(s||(L0(t,o),s=!0),t.lineWidth=n);for(var l=0;l<S0.length;l++){var u=S0[l],h=u[0];!i&&r[h]===a[h]||(s||(L0(t,o),s=!0),t[h]=r[h]||u[1])}}}function T0(t,e){var e=e.transform,n=t.dpr||1;e?t.setTransform(n*e[0],n*e[1],n*e[2],n*e[3],n*e[4],n*e[5]):t.setTransform(n,0,0,n,0,0)}var C0=1,D0=2,A0=3,k0=4;function L0(t,e){e.batchFill&&t.fill(),e.batchStroke&&t.stroke(),e.batchFill="",e.batchStroke=""}function P0(t,e){return e&&t.__hoverStyle||t.style}function O0(t,e){N0(t,e,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function N0(t,e,n,E){var i=e.transform;if(e.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1)){var o=e.__clipPaths,r=n.prevElClipPaths,a=!1,s=!1;if(!r||function(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}}(o,r)){if(r&&r.length&&(L0(t,n),t.restore(),s=a=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),o&&o.length){L0(t,n),t.save();for(var z=o,l=t,r=n,V=!1,B=0;B<z.length;B++){var F=z[B],V=V||F.isZeroArea();T0(l,F),l.beginPath(),F.buildPath(l,F.shape),l.clip()}r.allClipped=V,a=!0}n.prevElClipPaths=o}if(n.allClipped)e.__isRendered=!1;else{e.beforeBrush&&e.beforeBrush(),e.innerBeforeBrush();var u,h,c,p,d,g,f,y,m,v,x,_,b,G,w,S,M,I,T,C,D,A,k,r=n.prevEl,L=(r||(s=a=!0),e instanceof q&&e.autoBatch&&(o=e.style,L=v0(o),u=y0(o),!(o.lineDash||!(+L^+u)||L&&"string"!=typeof o.fill||u&&"string"!=typeof o.stroke||o.strokePercent<1||o.strokeOpacity<1||o.fillOpacity<1))),a=(a||(u=i,o=r.transform,u&&o?u[0]!==o[0]||u[1]!==o[1]||u[2]!==o[2]||u[3]!==o[3]||u[4]!==o[4]||u[5]!==o[5]:u||o)?(L0(t,n),T0(t,e)):L||L0(t,n),P0(e,n.inHover));if(e instanceof q)n.lastDrawType!==C0&&(s=!0,n.lastDrawType=C0),I0(t,e,r,s,n),L&&(n.batchFill||n.batchStroke)||t.beginPath(),i=t,o=e,N=L,w=y0(p=a),S=v0(p),M=p.strokePercent,I=M<1,T=!o.path,o.silent&&!I||!T||o.createPathProxy(),C=o.path||f0,D=o.__dirty,N||(d=p.fill,k=p.stroke,g=S&&!!d.colorStops,f=w&&!!k.colorStops,y=S&&!!d.image,m=w&&!!k.image,A=b=_=x=v=void 0,(g||f)&&(A=o.getBoundingRect()),g&&(v=D?c0(i,d,A):o.__canvasFillGradient,o.__canvasFillGradient=v),f&&(x=D?c0(i,k,A):o.__canvasStrokeGradient,o.__canvasStrokeGradient=x),y&&(_=D||!o.__canvasFillPattern?b0(i,d,o):o.__canvasFillPattern,o.__canvasFillPattern=_),m&&(b=D||!o.__canvasStrokePattern?b0(i,k,o):o.__canvasStrokePattern,o.__canvasStrokePattern=_),g?i.fillStyle=v:y&&(_?i.fillStyle=_:S=!1),f?i.strokeStyle=x:m&&(b?i.strokeStyle=b:w=!1)),A=o.getGlobalScale(),C.setScale(A[0],A[1],o.segmentIgnoreThreshold),i.setLineDash&&p.lineDash&&(G=(d=g0(o))[0],O=d[1]),k=!0,(T||D&Tn)&&(C.setDPR(i.dpr),I?C.setContext(null):(C.setContext(i),k=!1),C.reset(),o.buildPath(C,o.shape,N),C.toStatic(),o.pathUpdated()),k&&C.rebuildPath(i,I?M:1),G&&(i.setLineDash(G),i.lineDashOffset=O),N||(p.strokeFirst?(w&&_0(i,p),S&&x0(i,p)):(S&&x0(i,p),w&&_0(i,p))),G&&i.setLineDash([]),L&&(n.batchFill=a.fill||"",n.batchStroke=a.stroke||"");else if(e instanceof il)n.lastDrawType!==A0&&(s=!0,n.lastDrawType=A0),I0(t,e,r,s,n),g=t,v=e,null!=(_=(y=a).text)&&(_+=""),_&&(g.font=y.font||J,g.textAlign=y.textAlign,g.textBaseline=y.textBaseline,x=f=void 0,g.setLineDash&&y.lineDash&&(f=(v=g0(v))[0],x=v[1]),f&&(g.setLineDash(f),g.lineDashOffset=x),y.strokeFirst?(y0(y)&&g.strokeText(_,y.x,y.y),v0(y)&&g.fillText(_,y.x,y.y)):(v0(y)&&g.fillText(_,y.x,y.y),y0(y)&&g.strokeText(_,y.x,y.y)),f)&&g.setLineDash([]);else if(e instanceof ll)n.lastDrawType!==D0&&(s=!0,n.lastDrawType=D0),m=r,b=s,M0(t,P0(e,(A=n).inHover),m&&P0(m,A.inHover),b,A),d=t,T=a,(o=(D=e).__image=Na(T.image,D.__image,D,D.onload))&&Ea(o)&&(k=T.x||0,C=T.y||0,I=D.getWidth(),D=D.getHeight(),M=o.width/o.height,null==I&&null!=D?I=D*M:null==D&&null!=I?D=I/M:null==I&&null==D&&(I=o.width,D=o.height),T.sWidth&&T.sHeight?(h=T.sx||0,c=T.sy||0,d.drawImage(o,h,c,T.sWidth,T.sHeight,k,C,I,D)):T.sx&&T.sy?(h=T.sx,c=T.sy,d.drawImage(o,h,c,I-h,D-c,k,C,I,D)):d.drawImage(o,k,C,I,D));else if(e.getTemporalDisplayables){n.lastDrawType!==k0&&(s=!0,n.lastDrawType=k0);var P,W,H=t,O=e,N=n,Y=O.getDisplayables(),X=O.getTemporalDisplayables(),U=(H.save(),{prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:N.viewWidth,viewHeight:N.viewHeight,inHover:N.inHover});for(P=O.getCursor(),W=Y.length;P<W;P++)(R=Y[P]).beforeBrush&&R.beforeBrush(),R.innerBeforeBrush(),N0(H,R,U,P===W-1),R.innerAfterBrush(),R.afterBrush&&R.afterBrush(),U.prevEl=R;for(var R,Z=0,j=X.length;Z<j;Z++)(R=X[Z]).beforeBrush&&R.beforeBrush(),R.innerBeforeBrush(),N0(H,R,U,Z===j-1),R.innerAfterBrush(),R.afterBrush&&R.afterBrush(),U.prevEl=R;O.clearTemporalDisplayables(),O.notClear=!0,H.restore()}L&&E&&L0(t,n),e.innerAfterBrush(),e.afterBrush&&e.afterBrush(),(n.prevEl=e).__dirty=0,e.__isRendered=!0}}else e.__dirty&=~In,e.__isRendered=!1}var R0=new $m,E0=new ui(100),z0=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function V0(t,e){if("none"===t)return null;var a=e.getDevicePixelRatio(),s=e.getZr(),l="svg"===s.painter.type,e=(t.dirty&&R0.delete(t),R0.get(t));if(e)return e;for(var n,u=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}),e=("none"===u.backgroundColor&&(u.backgroundColor=null),{repeat:"repeat"}),i=e,o=[a],r=!0,h=0;h<z0.length;++h){var c=u[z0[h]];if(null!=c&&!B(c)&&!H(c)&&!Y(c)&&"boolean"!=typeof c){r=!1;break}o.push(c)}r&&(n=o.join(",")+(l?"-svg":""),v=E0.get(n))&&(l?i.svgElement=v:i.image=v);var p,d=function t(e){if(!e||0===e.length)return[[0,0]];if(Y(e))return[[r=Math.ceil(e),r]];var n=!0;for(var i=0;i<e.length;++i)if(!Y(e[i])){n=!1;break}if(n)return t([e]);var o=[];for(i=0;i<e.length;++i){var r;Y(e[i])?(r=Math.ceil(e[i]),o.push([r,r])):(r=V(e[i],function(t){return Math.ceil(t)})).length%2==1?o.push(r.concat(r)):o.push(r)}return o}(u.dashArrayX),g=function(t){if(!t||"object"==typeof t&&0===t.length)return[0,0];if(Y(t))return[e=Math.ceil(t),e];var e=V(t,function(t){return Math.ceil(t)});return t.length%2?e.concat(e):e}(u.dashArrayY),f=function t(e){if(!e||0===e.length)return[["rect"]];if(H(e))return[[e]];var n=!0;for(var i=0;i<e.length;++i)if(!H(e[i])){n=!1;break}if(n)return t([e]);var o=[];for(i=0;i<e.length;++i)H(e[i])?o.push([e[i]]):o.push(e[i]);return o}(u.symbol),y=function(t){return V(t,B0)}(d),m=B0(g),v=!l&&Q.createCanvas(),x=l&&{tag:"g",attrs:{},key:"dcl",children:[]},_=function(){for(var t=1,e=0,n=y.length;e<n;++e)t=Zr(t,y[e]);for(var i=1,e=0,n=f.length;e<n;++e)i=Zr(i,f[e].length);t*=i;var o=m*y.length*f.length;return{width:Math.max(1,Math.min(t,u.maxTileWidth)),height:Math.max(1,Math.min(o,u.maxTileHeight))}}();v&&(v.width=_.width*a,v.height=_.height*a,p=v.getContext("2d")),p&&(p.clearRect(0,0,v.width,v.height),u.backgroundColor)&&(p.fillStyle=u.backgroundColor,p.fillRect(0,0,v.width,v.height));for(var b=0,w=0;w<g.length;++w)b+=g[w];if(!(b<=0))for(var S=-m,M=0,I=0,T=0;S<_.height;){if(M%2==0){for(var C=I/2%f.length,D=0,A=0,k=0;D<2*_.width;){for(var L,P,O,N,R,E=0,w=0;w<d[T].length;++w)E+=d[T][w];if(E<=0)break;A%2==0&&(P=.5*(1-u.symbolSize),L=D+d[T][A]*P,P=S+g[M]*P,O=d[T][A]*u.symbolSize,N=g[M]*u.symbolSize,R=k/2%f[C].length,function(t,e,n,i,o){var r=l?1:a,o=s0(o,t*r,e*r,n*r,i*r,u.color,u.symbolKeepAspect);l?(t=s.painter.renderOneToVNode(o))&&x.children.push(t):O0(p,o)}(L,P,O,N,f[C][R])),D+=d[T][A],++k,++A===d[T].length&&(A=0)}++T===d.length&&(T=0)}S+=g[M],++I,++M===g.length&&(M=0)}return r&&E0.put(n,v||x),i.image=v,i.svgElement=x,i.svgWidth=_.width,i.svgHeight=_.height,e.rotation=u.rotation,e.scaleX=e.scaleY=l?1:1/a,R0.set(t,e),t.dirty=!1,e}function B0(t){for(var e=0,n=0;n<t.length;++n)e+=t[n];return t.length%2==1?2*e:e}var F0=new ce,G0={};var t0={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}},W0="__flagInMainProcess",H0="__pendingUpdate",Y0="__needsUpdateStatus",X0=/^[a-zA-Z0-9_]+$/,U0="__connectUpdateStatus";function Z0(n){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(!this.isDisposed())return q0(this,n,t);this.id}}function j0(n){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return q0(this,n,t)}}function q0(t,e,n){return n[0]=n[0]&&n[0].toLowerCase(),ce.prototype[e].apply(t,n)}u(J0,K0=ce);var K0,$0=J0;function J0(){return null!==K0&&K0.apply(this,arguments)||this}var Q0,tv,ev,nv,iv,ov,rv,av,sv,lv,uv,hv,cv,pv,dv,gv,fv,yv,mv,e0=$0.prototype,vv=(e0.on=j0("on"),e0.off=j0("off"),u(xv,mv=ce),xv.prototype._onframe=function(){if(!this._disposed){yv(this);var t=this._scheduler;if(this[H0]){var e=this[H0].silent;this[W0]=!0;try{Q0(this),nv.update.call(this,null,this[H0].updateParams)}catch(t){throw this[W0]=!1,this[H0]=null,t}this._zr.flush(),this[W0]=!1,this[H0]=null,av.call(this,e),sv.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),ov(this,i),t.performVisualTasks(i),pv(this,this._model,o,"remain",{}),0<(n-=+new Date-r)&&t.unfinished);t.unfinished||this._zr.flush()}}},xv.prototype.getDom=function(){return this._dom},xv.prototype.getId=function(){return this.id},xv.prototype.getZr=function(){return this._zr},xv.prototype.isSSR=function(){return this._ssr},xv.prototype.setOption=function(t,e,n){if(!this[W0])if(this._disposed)this.id;else{O(e)&&(n=e.lazyUpdate,i=e.silent,o=e.replaceMerge,r=e.transition,e=e.notMerge),this[W0]=!0,this._model&&!e||(e=new Ag(this._api),a=this._theme,(s=this._model=new vg).scheduler=this._scheduler,s.ssr=this._ssr,s.init(null,null,null,a,this._locale,e)),this._model.setOption(t,{replaceMerge:o},Av);var i,o,r,a,s={seriesTransition:r,optionChanged:!0};if(n)this[H0]={silent:i,updateParams:s},this[W0]=!1,this.getZr().wakeUp();else{try{Q0(this),nv.update.call(this,null,s)}catch(t){throw this[H0]=null,this[W0]=!1,t}this._ssr||this._zr.flush(),this[H0]=null,this[W0]=!1,av.call(this,i),sv.call(this,i)}}},xv.prototype.setTheme=function(){},xv.prototype.getModel=function(){return this._model},xv.prototype.getOption=function(){return this._model&&this._model.getOption()},xv.prototype.getWidth=function(){return this._zr.getWidth()},xv.prototype.getHeight=function(){return this._zr.getHeight()},xv.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||w.hasGlobalWindow&&window.devicePixelRatio||1},xv.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},xv.prototype.renderToCanvas=function(t){return this._zr.painter.getRenderedCanvas({backgroundColor:(t=t||{}).backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},xv.prototype.renderToSVGString=function(t){return this._zr.painter.renderToString({useViewBox:(t=t||{}).useViewBox})},xv.prototype.getSvgDataURL=function(){var t;if(w.svgSupported)return nt((t=this._zr).storage.getDisplayList(),function(t){t.stopAnimation(null,!0)}),t.painter.toDataURL()},xv.prototype.getDataURL=function(t){var e,n,i,o;if(!this._disposed)return o=(t=t||{}).excludeComponents,e=this._model,n=[],i=this,nt(o,function(t){e.eachComponent({mainType:t},function(t){t=i._componentsMap[t.__viewId];t.group.ignore||(n.push(t),t.group.ignore=!0)})}),o="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png")),nt(n,function(t){t.group.ignore=!1}),o;this.id},xv.prototype.getConnectedDataURL=function(i){var o,r,a,s,l,u,h,c,p,e,t,n,d,g,f;if(!this._disposed)return o="svg"===i.type,r=this.group,a=Math.min,s=Math.max,Nv[r]?(u=l=1/0,c=h=-1/0,p=[],e=i&&i.pixelRatio||this.getDevicePixelRatio(),nt(Ov,function(t,e){var n;t.group===r&&(n=o?t.getZr().painter.getSvgDom().innerHTML:t.renderToCanvas(S(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}))}),t=(h*=e)-(l*=e),n=(c*=e)-(u*=e),d=Q.createCanvas(),(g=br(d,{renderer:o?"svg":"canvas"})).resize({width:t,height:n}),o?(f="",nt(p,function(t){var e=t.left-l,n=t.top-u;f+='<g transform="translate('+e+","+n+')">'+t.dom+"</g>"}),g.painter.getSvgRoot().innerHTML=f,i.connectedBackgroundColor&&g.painter.setBackgroundColor(i.connectedBackgroundColor),g.refreshImmediately(),g.painter.toDataURL()):(i.connectedBackgroundColor&&g.add(new L({shape:{x:0,y:0,width:t,height:n},style:{fill:i.connectedBackgroundColor}})),nt(p,function(t){t=new ll({style:{x:t.left*e-l,y:t.top*e-u,image:t.dom}});g.add(t)}),g.refreshImmediately(),d.toDataURL("image/"+(i&&i.type||"png")))):this.getDataURL(i);this.id},xv.prototype.convertToPixel=function(t,e){return iv(this,"convertToPixel",t,e)},xv.prototype.convertFromPixel=function(t,e){return iv(this,"convertFromPixel",t,e)},xv.prototype.containPixel=function(t,i){var o;if(!this._disposed)return nt(ca(this._model,t),function(t,n){0<=n.indexOf("Models")&&nt(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;this.id},xv.prototype.getVisual=function(t,e){var t=ca(this._model,t,{defaultMainType:"series"}),n=t.seriesModel.getData(),t=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?n.indexOfRawIndex(t.dataIndex):null;return null!=t?Hm(n,t,e):Ym(n,e)},xv.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},xv.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},xv.prototype._initEvents=function(){var t,n,i,s=this;nt(Iv,function(a){function t(t){var n,e,i,o=s.getModel(),r=t.target;"globalout"===a?n={}:r&&jm(r,function(t){var e,t=$(t);return t&&null!=t.dataIndex?(e=t.dataModel||o.getSeriesByIndex(t.seriesIndex),n=e&&e.getDataParams(t.dataIndex,t.dataType,r)||{},1):t.eventData&&(n=F({},t.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)}),nt(Cv,function(t,e){s._messageCenter.on(e,function(t){this.trigger(e,t)},s)}),nt(["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?(Zm("map","selectchanged",n,e,t),Zm("pie","selectchanged",n,e,t)):"select"===t.fromAction?(Zm("map","selected",n,e,t),Zm("pie","selected",n,e,t)):"unselect"===t.fromAction&&(Zm("map","unselected",n,e,t),Zm("pie","unselected",n,e,t))})},xv.prototype.isDisposed=function(){return this._disposed},xv.prototype.clear=function(){this._disposed?this.id:this.setOption({series:[]},!0)},xv.prototype.dispose=function(){var t,e,n;this._disposed?this.id:(this._disposed=!0,this.getDom()&&ya(this.getDom(),zv,""),e=(t=this)._api,n=t._model,nt(t._componentsViews,function(t){t.dispose(n,e)}),nt(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 Ov[t.id])},xv.prototype.resize=function(t){if(!this[W0])if(this._disposed)this.id;else{this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var e=e.resetOption("media"),n=t&&t.silent;this[H0]&&(null==n&&(n=this[H0].silent),e=!0,this[H0]=null),this[W0]=!0;try{e&&Q0(this),nv.update.call(this,{type:"resize",animation:F({duration:0},t&&t.animation)})}catch(t){throw this[W0]=!1,t}this[W0]=!1,av.call(this,n),sv.call(this,n)}}},xv.prototype.showLoading=function(t,e){this._disposed?this.id:(O(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),Pv[t]&&(t=Pv[t](this._api,e),e=this._zr,this._loadingFX=t,e.add(t)))},xv.prototype.hideLoading=function(){this._disposed?this.id:(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},xv.prototype.makeActionFromEvent=function(t){var e=F({},t);return e.type=Cv[t.type],e},xv.prototype.dispatchAction=function(t,e){var n;this._disposed?this.id:(O(e)||(e={silent:!!e}),Tv[t.type]&&this._model&&(this[W0]?this._pendingActions.push(t):(n=e.silent,rv.call(this,t,n),(t=e.flush)?this._zr.flush():!1!==t&&w.browser.weChat&&this._throttledZrFlush(),av.call(this,n),sv.call(this,n))))},xv.prototype.updateLabelLayout=function(){F0.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},xv.prototype.appendData=function(t){var e;this._disposed?this.id:(e=t.seriesIndex,this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp())},xv.internalField=(Q0=function(t){var e=t._scheduler;e.restorePipelines(t._model),e.prepareStageTasks(),tv(t,!0),tv(t,!1),e.plan()},tv=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,n=t.__requireNewView,i=(t.__requireNewView=!1,"_ec_"+t.id+"_"+t.type),n=!n&&l[i];n||(e=wa(t.type),(n=new(o?Ky.getClass(e.main,e.sub):em.getClass(e.sub))).init(r,h),l[i]=n,s.push(n),u.add(n.group)),t.__viewId=n.__id=i,n.__alive=!0,n.__model=t,n.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},o||a.prepareView(n,t,r,h)}o?r.eachComponent(function(t,e){"series"!==t&&n(e)}):r.eachSeries(n);for(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)}},ev=function(c,e,p,n,t){var i,d,o=c._model;function r(t){t&&t.__alive&&t[e]&&t[e](t.__model,o,c._api,p)}o.setUpdatePayload(p),n?((i={})[n+"Id"]=p[n+"Id"],i[n+"Index"]=p[n+"Index"],i[n+"Name"]=p[n+"Name"],i={mainType:n,query:i},t&&(i.subType=t),null!=(t=p.excludeSeriesId)&&(d=R(),nt(Jr(t),function(t){t=ra(t,null);null!=t&&d.set(t,!0)})),o&&o.eachComponent(i,function(t){var e,n,i=d&&null!=d.get(t.id);if(!i)if(Pu(p))if(t instanceof Gy){if(p.type===Yl&&!p.notBlur&&!t.get(["emphasis","disabled"])){var i=t,o=p,r=c._api,a=i.seriesIndex,s=i.getData(o.dataType);if(s){var o=(B(o=ua(s,o))?o[0]:o)||0,l=s.getItemGraphicEl(o);if(!l)for(var u=s.count(),h=0;!l&&h<u;)l=s.getItemGraphicEl(h++);l?xu(a,(o=$(l)).focus,o.blurScope,r):(o=i.get(["emphasis","focus"]),i=i.get(["emphasis","blurScope"]),null!=o&&xu(a,o,i,r))}}}else{a=bu(t.mainType,t.componentIndex,p.name,c._api),o=a.focusSelf,i=a.dispatchers;p.type===Yl&&o&&!p.notBlur&&_u(t.mainType,t.componentIndex,c._api),i&&nt(i,function(t){(p.type===Yl?cu:pu)(t)})}else Lu(p)&&t instanceof Gy&&(r=t,i=p,c._api,Lu(i)&&(e=i.dataType,B(n=ua(r.getData(e),i))||(n=[n]),r[i.type===jl?"toggleSelect":i.type===Ul?"select":"unselect"](n,e)),wu(t),fv(c))},c),o&&o.eachComponent(i,function(t){d&&null!=d.get(t.id)||r(c["series"===n?"_chartsMap":"_componentsMap"][t.__viewId])},c)):nt([].concat(c._componentsViews).concat(c._chartsViews),r)},nv={prepareAndUpdate:function(t){Q0(this),nv.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),ov(this,n),r.update(n,i),_v(n),a.performVisualTasks(n,t),hv(this,n,i,t,e),r=n.get("backgroundColor")||"transparent",a=n.get("darkMode"),o.setBackgroundColor(r),null!=a&&"auto"!==a&&o.setDarkMode(a),F0.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=R(),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)}),_v(a),this._scheduler.performVisualTasks(a,n,{setDirty:!0,dirtyMap:o}),pv(this,a,s,n,{},o),F0.trigger("afterupdate",a,s))},updateView:function(t){var e=this._model;e&&(e.setUpdatePayload(t),em.markUpdateMethod(t,"updateView"),_v(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),hv(this,e,this._api,t,{}),F0.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()}),em.markUpdateMethod(n,"updateVisual"),_v(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)}),F0.trigger("afterupdate",o,this._api))},updateLayout:function(t){nv.update.call(this,t)}},iv=function(t,e,n,i){if(t._disposed)t.id;else for(var o=t._model,r=t._coordSysMgr.getCoordinateSystems(),a=ca(o,n),s=0;s<r.length;s++){var l=r[s];if(l[e]&&null!=(l=l[e](o,a,i)))return l}},ov=function(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})},rv=function(i,t){var o,r,a=this,e=this.getModel(),n=i.type,s=i.escapeConnect,l=Tv[n],u=l.actionInfo,h=(u.update||"update").split(":"),c=h.pop(),p=null!=h[0]&&wa(h[0]),h=(this[W0]=!0,[i]),d=!1,g=(i.batch&&(d=!0,h=V(i.batch,function(t){return(t=z(F({},t),i)).batch=null,t})),[]),f=Lu(i),y=Pu(i);if(y&&vu(this._api),nt(h,function(t){var e,n;(o=(o=l.action(t,a._model,a._api))||F({},t)).type=u.event||o.type,g.push(o),y?(e=(n=pa(i)).queryOptionMap,n=n.mainTypeSpecified?e.keys()[0]:"series",ev(a,c,t,n),fv(a)):f?(ev(a,c,t,"series"),fv(a)):p&&ev(a,c,t,p.main,p.sub)}),"none"!==c&&!y&&!f&&!p)try{this[H0]?(Q0(this),nv.update.call(this,i),this[H0]=null):nv[c].call(this,i)}catch(t){throw this[W0]=!1,t}o=d?{type:u.event||n,escapeConnect:s,batch:g}:g[0],this[W0]=!1,t||((h=this._messageCenter).trigger(o.type,o),f&&(d={type:"selectchanged",escapeConnect:s,selected:(r=[],e.eachSeries(function(n){nt(n.getAllData(),function(t){t.data;var t=t.type,e=n.getSelectedDataIndices();0<e.length&&(e={dataIndex:e,seriesIndex:n.seriesIndex},null!=t&&(e.dataType=t),r.push(e))})}),r),isFromClick:i.isFromClick||!1,fromAction:i.type,fromActionPayload:i},h.trigger(d.type,d)))},av=function(t){for(var e=this._pendingActions;e.length;){var n=e.shift();rv.call(this,n,t)}},sv=function(t){t||this.trigger("updated")},lv=function(e,n){e.on("rendered",function(t){n.trigger("rendered",t),!e.animation.isFinished()||n[H0]||n._scheduler.unfinished||n._pendingActions.length||n.trigger("finished")})},uv=function(t,a){t.on("mouseover",function(t){var e,n,i,o,r=jm(t.target,ku);r&&(r=r,e=t,t=a._api,n=$(r),i=(o=bu(n.componentMainType,n.componentIndex,n.componentHighDownName,t)).dispatchers,o=o.focusSelf,i?(o&&_u(n.componentMainType,n.componentIndex,t),nt(i,function(t){return uu(t,e)})):(xu(n.seriesIndex,n.focus,n.blurScope,t),"self"===n.focus&&_u(n.componentMainType,n.componentIndex,t),uu(r,e)),fv(a))}).on("mouseout",function(t){var e,n,i=jm(t.target,ku);i&&(i=i,e=t,vu(t=a._api),(n=bu((n=$(i)).componentMainType,n.componentIndex,n.componentHighDownName,t).dispatchers)?nt(n,function(t){return hu(t,e)}):hu(i,e),fv(a))}).on("click",function(t){var e,t=jm(t.target,function(t){return null!=$(t).dataIndex},!0);t&&(e=t.selected?"unselect":"select",t=$(t),a._api.dispatchAction({type:e,dataType:t.dataType,dataIndexInside:t.dataIndex,seriesIndex:t.seriesIndex,isFromClick:!0}))})},hv=function(t,e,n,i,o){var r,a,s,l,u,h,c;u=[],c=!(h=[]),(r=e).eachComponent(function(t,e){var n=e.get("zlevel")||0,i=e.get("z")||0,o=e.getZLevelKey();c=c||!!o,("series"===t?h:u).push({zlevel:n,z:i,idx:e.componentIndex,type:t,key:o})}),c&&(Mn(a=u.concat(h),function(t,e){return t.zlevel===e.zlevel?t.z-e.z:t.zlevel-e.zlevel}),nt(a,function(t){var e=r.getComponent(t.type,t.idx),n=t.zlevel,t=t.key;null!=s&&(n=Math.max(s,n)),t?(n===s&&t!==l&&n++,l=t):l&&(n===s&&n++,l=""),s=n,e.setZLevel(n)})),cv(t,e,n,i,o),nt(t._chartsViews,function(t){t.__alive=!1}),pv(t,e,n,i,o),nt(t._chartsViews,function(t){t.__alive||t.remove(e,n)})},cv=function(t,n,i,o,e,r){nt(r||t._componentsViews,function(t){var e=t.__model;Sv(0,t),t.render(e,n,i,o),wv(e,t),Mv(e,t)})},pv=function(o,t,e,r,n,a){var i,s,l,u,h=o._scheduler,c=(n=F(n||{},{updatedSeries:t.getSeries()}),F0.trigger("series:beforeupdate",t,e,n),!1);t.eachSeries(function(t){var e,n=o._chartsMap[t.__viewId],i=(n.__alive=!0,n.renderTask);h.updatePayload(i,r),Sv(0,n),a&&a.get(t.uid)&&i.dirty(),i.perform(h.getPerformArgs(i))&&(c=!0),n.group.silent=!!t.get("silent"),i=n,e=t.get("blendMode")||null,i.eachRendered(function(t){t.isGroup||(t.style.blend=e)}),wu(t)}),h.unfinished=c||h.unfinished,F0.trigger("series:layoutlabels",t,e,n),F0.trigger("series:transition",t,e,n),t.eachSeries(function(t){var e=o._chartsMap[t.__viewId];wv(t,e),Mv(t,e)}),s=t,l=(i=o)._zr.storage,u=0,l.traverse(function(t){t.isGroup||u++}),u>s.get("hoverLayerThreshold")&&!w.node&&!w.worker&&s.eachSeries(function(t){t.preventUsingHoverLayer||(t=i._chartsMap[t.__viewId]).__alive&&t.eachRendered(function(t){t.states.emphasis&&(t.states.emphasis.hoverLayer=!0)})}),F0.trigger("series:afterupdate",t,e,n)},fv=function(t){t[Y0]=!0,t.getZr().wakeUp()},yv=function(t){t[Y0]&&(t.getZr().storage.traverse(function(t){bc(t)||bv(t)}),t[Y0]=!1)},dv=function(n){return u(t,e=Sg),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){cu(t,e),fv(n)},t.prototype.leaveEmphasis=function(t,e){pu(t,e),fv(n)},t.prototype.enterBlur=function(t){du(t),fv(n)},t.prototype.leaveBlur=function(t){gu(t),fv(n)},t.prototype.enterSelect=function(t){fu(t),fv(n)},t.prototype.leaveSelect=function(t){yu(t),fv(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(gv=function(i){function o(t,e){for(var n=0;n<t.length;n++)t[n][U0]=e}nt(Cv,function(t,e){i._messageCenter.on(e,function(t){var e,n;!Nv[i.group]||0===i[U0]||t&&t.escapeConnect||(e=i.makeActionFromEvent(t),n=[],nt(Ov,function(t){t!==i&&t.group===i.group&&n.push(t)}),o(n,0),nt(n,function(t){1!==t[U0]&&t.dispatchAction(e)}),o(n,2))})})})),xv);function xv(t,e,n){var i=mv.call(this,new Vm)||this,t=(i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],n=n||{},H(e)&&(e=Lv[e]),i._dom=t,n.ssr&&Mr(function(t){var e,t=$(t),n=t.dataIndex;if(null!=n)return(e=R()).set("series_index",t.seriesIndex),e.set("data_index",n),t.ssrType&&e.set("ssr_type",t.ssrType),e}),i._zr=br(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:N(n.useDirtyRect,!1),useCoarsePointer:N(n.useCoarsePointer,"auto"),pointerSize:n.pointerSize})),n=(i._ssr=n.ssr,i._throttledZrFlush=cm(T(t.flush,t),17),(e=S(e))&&qg(e,!0),i._theme=e,i._locale=H(e=n.locale||Fp)?(n=Vp[e.toUpperCase()]||{},e===Rp||e===Ep?S(n):d(S(n),S(Vp[zp]),!1)):d(S(e),S(Vp[zp]),!1),i._coordSysMgr=new Tg,i._api=dv(i));function o(t,e){return t.__prio-e.__prio}return Mn(kv,o),Mn(Dv,o),i._scheduler=new bm(i,n,Dv,kv),i._messageCenter=new $0,i._initEvents(),i.resize=T(i.resize,i),t.animation.on("frame",i._onframe,i),lv(t,i),uv(t,i),At(i),i}function _v(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})}function bv(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===Gl&&t.states.emphasis?e.push("emphasis"):t.hoverState===Fl&&t.states.blur&&e.push("blur"),t.useStates(e)}function wv(t,e){var n,i;t.preventAutoZ||(n=t.get("z")||0,i=t.get("zlevel")||0,e.eachRendered(function(t){return function t(e,n,i,o){var r=e.getTextContent();var a=e.getTextGuideLine();var 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&&(s=e.textGuideLineConfig,a.z=n,a.zlevel=i,isFinite(o))&&(a.z2=o+(s&&s.showAbove?1:-1));return o}(t,n,i,-1/0),!0}))}function Sv(t,e){e.eachRendered(function(t){var e,n;bc(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 Mv(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.eachRendered(function(t){var e,n,i;t.states&&t.states.emphasis&&(bc(t)||(t instanceof q&&((i=zl(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&&(i=t.prevStates)&&t.useStates(i),o&&(t.stateTransition=r,n=t.getTextContent(),e=t.getTextGuideLine(),n&&(n.stateTransition=r),e)&&(e.stateTransition=r),t.__dirty&&bv(t)))})}var n0=vv.prototype,Iv=(n0.on=Z0("on"),n0.off=Z0("off"),n0.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)},["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"]);var Tv={},Cv={},Dv=[],Av=[],kv=[],Lv={},Pv={},Ov={},Nv={},Rv=+new Date,Ev=+new Date,zv="_echarts_instance_";function Vv(t){Nv[t]=!1}Qm=Vv;function Bv(t){return Ov[e=zv,(t=t).getAttribute?t.getAttribute(e):t[e]];var e}function Fv(t,e){Lv[t]=e}function Gv(t){G(Av,t)<0&&Av.push(t)}function Wv(t,e){$v(Dv,t,e,2e3)}function Hv(t){Xv("afterinit",t)}function Yv(t){Xv("afterupdate",t)}function Xv(t,e){F0.on(t,e)}function Uv(t,e,n){D(e)&&(n=e,e="");var i=O(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,Cv[e]||(Tt(X0.test(i)&&X0.test(e)),Tv[i]||(Tv[i]={action:n,actionInfo:t}),Cv[e]=i)}function Zv(t,e){Tg.register(t,e)}function jv(t,e){$v(kv,t,e,1e3,"layout")}function qv(t,e){$v(kv,t,e,3e3,"visual")}var Kv=[];function $v(t,e,n,i,o){(D(e)||O(e))&&(n=e,e=i),0<=G(Kv,n)||(Kv.push(n),(i=bm.wrapStageHandler(n,o)).__prio=e,i.__raw=n,t.push(i))}function Jv(t,e){Pv[t]=e}function Qv(t,e,n){var i=G0.registerMap;i&&i(t,e,n)}function t1(t){var e=(t=S(t)).type,n=(e||jr(""),e.split(":")),i=(2!==n.length&&jr(""),!1);"echarts"===n[0]&&(e=n[1],i=!0),t.__isBuiltIn=i,ny.set(e,t)}qv(2e3,La),qv(4500,xp),qv(4500,jp),qv(2e3,Sp),qv(4500,Wm),qv(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=V0(e,i))}),t=n.getVisual("decal"))&&(n.getVisual("style").decal=V0(t,i))})}),Gv(qg),Wv(900,function(t){var i=R();t.eachSeries(function(t){var e,n=t.get("stack");n&&(n=i.get(n)||i.set(n,[]),(t={stackResultDimension:(e=t.getData()).getCalculationInfo("stackResultDimension"),stackedOverDimension:e.getCalculationInfo("stackedOverDimension"),stackedDimension:e.getCalculationInfo("stackedDimension"),stackedByDimension:e.getCalculationInfo("stackedByDimension"),isStackedByIndex:e.getCalculationInfo("isStackedByIndex"),data:e,seriesModel:t}).stackedDimension)&&(t.isStackedByIndex||t.stackedByDimension)&&(n.length&&e.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(t))}),i.each(Kg)}),Jv("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 r,t=new Z,a=new L({style:{fill:o.maskColor},zlevel:o.zlevel,z:1e4}),s=(t.add(a),new K({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 L({style:{fill:"none"},textContent:s,textConfig:{position:"right",distance:10},zlevel:o.zlevel,z:10001});return t.add(l),o.showSpinner&&((r=new Kh({shape:{startAngle:-_m/2,endAngle:-_m/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*_m/2}).start("circularInOut"),r.animateShape(!0).when(1e3,{startAngle:3*_m/2}).delay(300).start("circularInOut"),t.add(r)),t.resize=function(){var t=s.getBoundingRect().width,e=o.showSpinner?o.spinnerRadius:0,t=(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),n=i.getHeight()/2;o.showSpinner&&r.setShape({cx:t,cy:n}),l.setShape({x:t-e,y:n-e,width:2*e,height:2*e}),a.setShape({x:0,y:0,width:i.getWidth(),height:i.getHeight()})},t.resize(),t}),Uv({type:Yl,event:Yl,update:Yl},Bt),Uv({type:Xl,event:Xl,update:Xl},Bt),Uv({type:Ul,event:Ul,update:Ul},Bt),Uv({type:Zl,event:Zl,update:Zl},Bt),Uv({type:jl,event:jl,update:jl},Bt),Fv("light",Ip),Fv("dark",bp);function e1(t){return null==t?0:t.length||1}function n1(t){return t}o1.prototype.add=function(t){return this._add=t,this},o1.prototype.update=function(t){return this._update=t,this},o1.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},o1.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},o1.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},o1.prototype.remove=function(t){return this._remove=t,this},o1.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},o1.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=e1(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)},o1.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=e1(l),c=e1(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)},o1.prototype._performRestAdd=function(t,e){for(var n=0;n<t.length;n++){var i=t[n],o=e[i],r=e1(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}},o1.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=e1(a=e[l]))?(e[l]=r,o&&n.push(l)):1===s?e[l]=[a,r]:a.push(r))}};var i1=o1;function o1(t,e,n,i,o,r){this._old=t,this._new=e,this._oldKeyGetter=n||n1,this._newKeyGetter=i||n1,this.context=o,this._diffModeMultiple="multiple"===r}a1.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},a1.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames};var r1=a1;function a1(t,e){this._encode=t,this._schema=e}function s1(r,t){var e={},a=e.encode={},s=R(),l=[],u=[],h={},i=(nt(r.dimensions,function(t){var e,n,i=r.getDimensionInfo(t),o=i.coordDim;o&&(e=i.coordDimIndex,l1(a,o)[e]=t,i.isExtraCoord||(s.set(o,1),"ordinal"!==(n=i.type)&&"time"!==n&&(l[0]=t),l1(h,o)[e]=r.getDimensionIndex(i.name)),i.defaultTooltip)&&u.push(t),Xd.each(function(t,e){var n=l1(a,e),e=i.otherDims[e];null!=e&&!1!==e&&(n[e]=i.name)})}),[]),o={},n=(s.each(function(t,e){var n=a[e];o[e]=n[0],i=i.concat(n)}),e.dataDimsOnCoord=i,e.dataDimIndicesOnCoord=V(i,function(t){return r.getDimensionInfo(t).storeDimIndex}),e.encodeFirstDimNotExtra=o,a.label),n=(n&&n.length&&(l=n.slice()),a.tooltip);return n&&n.length?u=n.slice():u.length||(u=l.slice()),a.defaultedLabel=l,a.defaultedTooltip=u,e.userOutput=new r1(h,t),e}function l1(t,e){return t.hasOwnProperty(e)||(t[e]=[]),t[e]}function u1(t){return"category"===t?"ordinal":"time"===t?"time":"float"}var h1=function(t){this.otherDims={},null!=t&&F(this,t)},c1=i(),p1={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},d1=(g1.prototype.isDimensionOmitted=function(){return this._dimOmitted},g1.prototype._updateDimOmitted=function(t){(this._dimOmitted=t)&&!this._dimNameMap&&(this._dimNameMap=m1(this.source))},g1.prototype.getSourceDimensionIndex=function(t){return N(this._dimNameMap.get(t),-1)},g1.prototype.getSourceDimension=function(t){var e=this.source.dimensionsDefine;if(e)return e[t]},g1.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,e=sf(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+"$"+(p1[u]||"f"),h&&(i+=h.uid),i+="$"}var p=this.source;return{dimensions:o,hash:[p.seriesLayoutBy,p.startIndex,i].join("$$")}},g1.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},g1.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},g1);function g1(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}function f1(t){return t instanceof d1}function y1(t){for(var e=R(),n=0;n<(t||[]).length;n++){var i=t[n],i=O(i)?i.name:i;null!=i&&null==e.get(i)&&e.set(i,n)}return e}function m1(t){var e=c1(t);return e.dimNameMap||(e.dimNameMap=y1(t.dimensionsDefine))}var v1,x1,_1,b1,w1,S1,M1,I1=O,T1=V,C1="undefined"==typeof Int32Array?Array:Int32Array,D1=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],A1=["_approximateExtent"],k1=(o.prototype.getDimension=function(t){var e;return null==(e=this._recognizeDimIndex(t))?t:(e=t,this._dimOmitted?null!=(t=this._dimIdxToName.get(e))?t:(t=this._schema.getSourceDimension(e))?t.name:void 0:this.dimensions[e])},o.prototype.getDimensionIndex=function(t){var e=this._recognizeDimIndex(t);return null!=e?e:null==t?-1:(e=this._getDimInfo(t))?e.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},o.prototype._recognizeDimIndex=function(t){if(Y(t)||null!=t&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},o.prototype._getStoreDimIndex=function(t){return this.getDimensionIndex(t)},o.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},o.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]}},o.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},o.prototype.mapDimension=function(t,e){var n=this._dimSummary;return null==e?n.encodeFirstDimNotExtra[t]:(n=n.encode[t])?n[e]:null},o.prototype.mapDimensionsAll=function(t){return(this._dimSummary.encode[t]||[]).slice()},o.prototype.getStore=function(){return this._store},o.prototype.initData=function(t,e,n){var i,o,r=this;(i=t instanceof dy?t:i)||(o=this.dimensions,t=tf(t)||ht(t)?new cf(t,o.length):t,i=new dy,o=T1(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=s1(this,this._schema),this.userOutput=this._dimSummary.userOutput},o.prototype.appendData=function(t){t=this._store.appendData(t);this._doInit(t[0],t[1])},o.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&&M1(this,r)},o.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)}},o.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return null==this._idDimIdx&&t.getSource().sourceFormat!==Kd&&!t.fillStorage},o.prototype._doInit=function(t,e){if(!(e<=t)){var n=this._store.getProvider(),i=(this._updateOrdinalMeta(),this._nameList),o=this._idList;if(n.getSource().sourceFormat===Ud&&!n.pure)for(var r=[],a=t;a<e;a++){var s,l=n.getItem(a,r);this.hasItemOption||!O(s=l)||s instanceof Array||(this.hasItemOption=!0),l&&(s=l.name,null==i[a]&&null!=s&&(i[a]=ra(s,null)),l=l.id,null==o[a])&&null!=l&&(o[a]=ra(l,null))}if(this._shouldMakeIdFromName())for(a=t;a<e;a++)M1(this,a);v1(this)}},o.prototype.getApproximateExtent=function(t){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t))},o.prototype.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},o.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},o.prototype.setCalculationInfo=function(t,e){I1(t)?F(this._calculationInfo,t):this._calculationInfo[t]=e},o.prototype.getName=function(t){var t=this.getRawIndex(t),e=this._nameList[t];return e=null==(e=null==e&&null!=this._nameDimIdx?_1(this,this._nameDimIdx,t):e)?"":e},o.prototype._getCategory=function(t,e){e=this._store.get(t,e),t=this._store.getOrdinalMeta(t);return t?t.categories[e]:e},o.prototype.getId=function(t){return x1(this,this.getRawIndex(t))},o.prototype.count=function(){return this._store.count()},o.prototype.get=function(t,e){var n=this._store,t=this._dimInfos[t];if(t)return n.get(t.storeDimIndex,e)},o.prototype.getByRawIndex=function(t,e){var n=this._store,t=this._dimInfos[t];if(t)return n.getByRawIndex(t.storeDimIndex,e)},o.prototype.getIndices=function(){return this._store.getIndices()},o.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t))},o.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},o.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},o.prototype.getValues=function(t,e){var n=this,i=this._store;return B(t)?i.getValues(T1(t,function(t){return n._getStoreDimIndex(t)}),e):i.getValues(t)},o.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},o.prototype.indexOfName=function(t){for(var e=0,n=this._store.count();e<n;e++)if(this.getName(e)===t)return e;return-1},o.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},o.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},o.prototype.rawIndexOf=function(t,e){t=(t&&this._invertedIndicesMap[t])[e];return null==t||isNaN(t)?-1:t},o.prototype.indicesOfNearest=function(t,e,n){return this._store.indicesOfNearest(this._getStoreDimIndex(t),e,n)},o.prototype.each=function(t,e,n){D(t)&&(n=e,e=t,t=[]);n=n||this,t=T1(b1(t),this._getStoreDimIndex,this);this._store.each(t,n?T(e,n):e)},o.prototype.filterSelf=function(t,e,n){D(t)&&(n=e,e=t,t=[]);n=n||this,t=T1(b1(t),this._getStoreDimIndex,this);return this._store=this._store.filter(t,n?T(e,n):e),this},o.prototype.selectRange=function(n){var i=this,o={};return nt(W(n),function(t){var e=i._getStoreDimIndex(t);o[e]=n[t]}),this._store=this._store.selectRange(o),this},o.prototype.mapArray=function(t,e,n){D(t)&&(n=e,e=t,t=[]);var i=[];return this.each(t,function(){i.push(e&&e.apply(this,arguments))},n=n||this),i},o.prototype.map=function(t,e,n,i){n=n||i||this,i=T1(b1(t),this._getStoreDimIndex,this),t=S1(this);return t._store=this._store.map(i,n?T(e,n):e),t},o.prototype.modify=function(t,e,n,i){n=n||i||this,i=T1(b1(t),this._getStoreDimIndex,this);this._store.modify(i,n?T(e,n):e)},o.prototype.downSample=function(t,e,n,i){var o=S1(this);return o._store=this._store.downSample(this._getStoreDimIndex(t),e,n,i),o},o.prototype.lttbDownSample=function(t,e){var n=S1(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(t),e),n},o.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},o.prototype.getItemModel=function(t){var e=this.hostModel,t=this.getRawDataItem(t);return new kp(t,e,e&&e.ecModel)},o.prototype.diff=function(e){var n=this;return new i1(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(t){return x1(e,t)},function(t){return x1(n,t)})},o.prototype.getVisual=function(t){var e=this._visual;return e&&e[t]},o.prototype.setVisual=function(t,e){this._visual=this._visual||{},I1(t)?F(this._visual,t):this._visual[t]=e},o.prototype.getItemVisual=function(t,e){t=this._itemVisuals[t],t=t&&t[e];return null==t?this.getVisual(e):t},o.prototype.hasItemVisual=function(){return 0<this._itemVisuals.length},o.prototype.ensureUniqueItemVisual=function(t,e){var n=this._itemVisuals,i=n[t],n=(i=i||(n[t]={}))[e];return null==n&&(B(n=this.getVisual(e))?n=n.slice():I1(n)&&(n=F({},n)),i[e]=n),n},o.prototype.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{};this._itemVisuals[t]=i,I1(e)?F(i,e):i[e]=n},o.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},o.prototype.setLayout=function(t,e){I1(t)?F(this._layout,t):this._layout[t]=e},o.prototype.getLayout=function(t){return this._layout[t]},o.prototype.getItemLayout=function(t){return this._itemLayouts[t]},o.prototype.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?F(this._itemLayouts[t]||{},e):e},o.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},o.prototype.setItemGraphicEl=function(t,e){var n=this.hostModel&&this.hostModel.seriesIndex;Nl(n,this.dataType,t,e),this._graphicEls[t]=e},o.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},o.prototype.eachItemGraphicEl=function(n,i){nt(this._graphicEls,function(t,e){t&&n&&n.call(i,t,e)})},o.prototype.cloneShallow=function(t){return t=t||new o(this._schema||T1(this.dimensions,this._getDimInfo,this),this.hostModel),w1(t,this),t._store=this._store,t},o.prototype.wrapMethod=function(t,e){var n=this[t];D(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(Mt(arguments)))})},o.internalField=(v1=function(a){var s=a._invertedIndicesMap;nt(s,function(t,e){var n=a._dimInfos[e],i=n.ordinalMeta,o=a._store;if(i){t=s[e]=new C1(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}})},_1=function(t,e,n){return ra(t._getCategory(e,n),null)},x1=function(t,e){var n=t._idList[e];return n=null==(n=null==n&&null!=t._idDimIdx?_1(t,t._idDimIdx,e):n)?"e\0\0"+e:n},b1=function(t){return t=B(t)?t:null!=t?[t]:[]},S1=function(t){var e=new o(t._schema||T1(t.dimensions,t._getDimInfo,t),t.hostModel);return w1(e,t),e},w1=function(e,n){nt(D1.concat(n.__wrappedMethods||[]),function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e.__wrappedMethods=n.__wrappedMethods,nt(A1,function(t){e[t]=S(n[t])}),e._calculationInfo=F({},n._calculationInfo)},void(M1=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=_1(t,o,e)),null==s&&null!=r&&(i[e]=s=_1(t,r,e)),null==s&&null!=a&&(s=a,1<(o=(n=t._nameRepeatCount)[a]=(n[a]||0)+1)&&(s+="__ec__"+o),i[e]=s)})),o);function o(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"];for(var n,i,o=!(this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"]),r=(f1(t)?(n=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(o=!0,n=t),n=n||["x","y"],{}),a=[],s={},l=!1,u={},h=0;h<n.length;h++){var c=n[h],c=H(c)?new h1({name:c}):c instanceof h1?c:new h1(c),p=c.name,d=(c.type=c.type||"float",c.coordDim||(c.coordDim=p,c.coordDimIndex=0),c.otherDims=c.otherDims||{});a.push(p),null!=u[p]&&(l=!0),(r[p]=c).createInvertedIndices&&(s[p]=[]),0===d.itemName&&(this._nameDimIdx=h),0===d.itemId&&(this._idDimIdx=h),o&&(c.storeDimIndex=h)}this.dimensions=a,this._dimInfos=r,this._initGetDimensionInfo(l),this.hostModel=e,this._invertedIndicesMap=s,this._dimOmitted&&(i=this._dimIdxToName=R(),nt(a,function(t){i.set(r[t].storeDimIndex,t)}))}function L1(t,e){tf(t)||(t=nf(t));for(var n,i,o=(e=e||{}).coordDimensions||[],r=e.dimensionsDefine||t.dimensionsDefine||[],a=R(),s=[],l=(u=t,n=o,p=e.dimensionsCount,i=Math.max(u.dimensionsDetectedCount||1,n.length,r.length,p||0),nt(n,function(t){O(t)&&(t=t.dimsDef)&&(i=Math.max(i,t.length))}),i),u=e.canOmitUnusedDimensions&&30<l,h=r===t.dimensionsDefine,c=h?m1(t):y1(r),p=e.encodeDefine,d=R(p=!p&&e.encodeDefaulter?e.encodeDefaulter(t,l):p),g=new ly(l),f=0;f<g.length;f++)g[f]=-1;function y(t){var e,n,i,o=g[t];return o<0?(e=O(e=r[t])?e:{name:e},n=new h1,null!=(i=e.name)&&null!=c.get(i)&&(n.name=n.displayName=i),null!=e.type&&(n.type=e.type),null!=e.displayName&&(n.displayName=e.displayName),g[t]=s.length,n.storeDimIndex=t,s.push(n),n):s[o]}if(!u)for(f=0;f<l;f++)y(f);d.each(function(t,n){var i,t=Jr(t).slice();1===t.length&&!H(t[0])&&t[0]<0?d.set(n,!1):(i=d.set(n,[]),nt(t,function(t,e){t=H(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!=Xd.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,a.set(e,!0))}nt(o,function(t){H(t)?(r=t,o={}):(r=(o=t).name,t=o.ordinalMeta,o.ordinalMeta=null,(o=F({},o)).ordinalMeta=t,n=o.dimsDef,i=o.otherDims,o.name=o.coordDim=o.coordDimIndex=o.dimsDef=o.otherDims=null);var n,i,o,r,e=d.get(r);if(!1!==e){if(!(e=Jr(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++)}nt(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&&(O(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)nt(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){if(n||e.hasKey(t)){for(var i=0;e.hasKey(t+i);)i++;t+=i}return e.set(t,!0),t}(w,a,_),I.coordDimIndex=0,(!x||b<=0)&&(I.isExtraCoord=!0),b--),S(I),null!=I.type||rg(t,M)!==tg.Must&&(!I.isExtraCoord||null==I.otherDims.itemName&&null==I.otherDims.seriesName)||(I.type="ordinal")}for(var T=s,C=R(),D=0;D<T.length;D++){var A=T[D],k=A.name,L=C.get(k)||0;0<L&&(A.name=k+(L-1)),L++,C.set(k,L)}return new d1({source:t,dimensions:s,fullDimensionCount:l,dimensionOmitted:u})}var P1=function(t){this.coordSysDims=[],this.axisMap=R(),this.categoryAxisMap=R(),this.coordSysName=t};var O1={cartesian2d:function(t,e,n,i){var o=t.getReferringComponents("xAxis",da).models[0],t=t.getReferringComponents("yAxis",da).models[0];e.coordSysDims=["x","y"],n.set("x",o),n.set("y",t),N1(o)&&(i.set("x",o),e.firstCategoryDimIndex=0),N1(t)&&(i.set("y",t),null==e.firstCategoryDimIndex)&&(e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){t=t.getReferringComponents("singleAxis",da).models[0];e.coordSysDims=["single"],n.set("single",t),N1(t)&&(i.set("single",t),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var t=t.getReferringComponents("polar",da).models[0],o=t.findAxisModel("radiusAxis"),t=t.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",o),n.set("angle",t),N1(o)&&(i.set("radius",o),e.firstCategoryDimIndex=0),N1(t)&&(i.set("angle",t),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();nt(t.parallelAxisIndex,function(t,e){var t=a.getComponent("parallelAxis",t),n=s[e];o.set(n,t),N1(t)&&(r.set(n,t),null==i.firstCategoryDimIndex)&&(i.firstCategoryDimIndex=e)})}};function N1(t){return"category"===t.get("type")}function R1(t,e,n){var i,o,r,a,s,l,u,h,c,p=(n=n||{}).byIndex,d=n.stackedCoordDimension,g=(f1(e.schema)?(o=e.schema,i=o.dimensions,r=e.store):i=e,!(!t||!t.get("stack")));return nt(i,function(t,e){H(t)&&(i[e]=t={name:t}),g&&!t.isExtraCoord&&(p||a||!t.ordinalMeta||(a=t),s||"ordinal"===t.type||"time"===t.type||d&&d!==t.coordDim||(s=t))}),!s||p||a||(p=!0),s&&(l="__\0ecstackresult_"+t.id,u="__\0ecstackedover_"+t.id,a&&(a.createInvertedIndices=!0),h=s.coordDim,n=s.type,c=0,nt(i,function(t){t.coordDim===h&&c++}),e={name:l,coordDim:h,coordDimIndex:c,type:n,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},t={name:u,coordDim:u,coordDimIndex:c+1,type:n,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1},o?(r&&(e.storeDimIndex=r.ensureCalculationDimension(u,n),t.storeDimIndex=r.ensureCalculationDimension(l,n)),o.appendCalculationDimension(e),o.appendCalculationDimension(t)):(i.push(e),i.push(t))),{stackedDimension:s&&s.name,stackedByDimension:a&&a.name,isStackedByIndex:p,stackedOverDimension:u,stackResultDimension:l}}function E1(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function z1(t,e){return E1(t,e)?t.getCalculationInfo("stackResultDimension"):e}function V1(t,e,n){n=n||{};var i,o,r,a,s,l,u=e.getSourceManager(),h=!1,t=(t?(h=!0,i=nf(t)):h=(i=u.getSource()).sourceFormat===Ud,function(t){var e=t.get("coordinateSystem"),n=new P1(e);if(e=O1[e])return e(t,n,n.axisMap,n.categoryAxisMap),n}(e)),c=(o=t,c=(c=e).get("coordinateSystem"),c=Tg.get(c),p=(p=o&&o.coordSysDims?V(o.coordSysDims,function(t){var e={name:t},t=o.axisMap.get(t);return t&&(t=t.get("type"),e.type=u1(t)),e}):p)||c&&(c.getDimensionsInfo?c.getDimensionsInfo():c.dimensions.slice())||["x","y"]),p=n.useEncodeDefaulter,p=D(p)?p:p?P(ng,c,e):null,c={coordDimensions:c,generateCoord:n.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:p,canOmitUnusedDimensions:!h},p=L1(i,c),d=(c=p.dimensions,r=n.createInvertedIndices,(a=t)&&nt(c,function(t,e){var n=t.coordDim,n=a.categoryAxisMap.get(n);n&&(null==s&&(s=e),t.ordinalMeta=n.getOrdinalMeta(),r)&&(t.createInvertedIndices=!0),null!=t.otherDims.itemName&&(l=!0)}),l||null==s||(c[s].otherDims.itemName=0),s),n=h?null:u.getSharedDataStore(p),t=R1(e,{schema:p,store:n}),c=new k1(p,e),p=(c.setCalculationInfo(t),null==d||(u=i).sourceFormat!==Ud||B(ea(function(t){var e=0;for(;e<t.length&&null==t[e];)e++;return t[e]}(u.data||[])))?null:function(t,e,n,i){return i===d?n:this.defaultDimValueGetter(t,e,n,i)});return c.hasItemOption=!1,c.initData(h?i:n,null,p),c}F1.prototype.getSetting=function(t){return this._setting[t]},F1.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},F1.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},F1.prototype.getExtent=function(){return this._extent.slice()},F1.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},F1.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},F1.prototype.isBlank=function(){return this._isBlank},F1.prototype.setBlank=function(t){this._isBlank=t};var B1=F1;function F1(t){this._setting=t||{},this._extent=[1/0,-1/0]}Da(B1);var G1=0,W1=(H1.createByAxisModel=function(t){var t=t.option,e=t.data,e=e&&V(e,Y1);return new H1({categories:e,needCollect:!e,deduplication:!1!==t.dedplication})},H1.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},H1.prototype.parseAndCollect=function(t){var e,n,i=this._needCollect;return H(t)||i?(i&&!this._deduplication?(n=this.categories.length,this.categories[n]=t):null==(n=(e=this._getOrCreateMap()).get(t))&&(i?(n=this.categories.length,this.categories[n]=t,e.set(t,n)):n=NaN),n):t},H1.prototype._getOrCreateMap=function(){return this._map||(this._map=R(this.categories))},H1);function H1(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++G1}function Y1(t){return O(t)&&null!=t.value?t.value:t+""}function X1(t){return"interval"===t.type||"log"===t.type}function U1(t,e,n,i){var o={},r=t[1]-t[0],r=o.interval=Gr(r/e,!0),e=(null!=n&&r<n&&(r=o.interval=n),null!=i&&i<r&&(r=o.interval=i),o.intervalPrecision=j1(r)),n=o.niceTickExtent=[Dr(Math.ceil(t[0]/r)*r,e),Dr(Math.floor(t[1]/r)*r,e)];return i=n,r=t,isFinite(i[0])||(i[0]=r[0]),isFinite(i[1])||(i[1]=r[1]),q1(i,0,r),q1(i,1,r),i[0]>i[1]&&(i[0]=i[1]),o}function Z1(t){var e=Math.pow(10,Fr(t)),t=t/e;return t?2===t?t=3:3===t?t=5:t*=2:t=1,Dr(t*e)}function j1(t){return kr(t)+2}function q1(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function K1(t,e){return t>=e[0]&&t<=e[1]}function $1(t,e){return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])}function J1(t,e){return t*(e[1]-e[0])+e[0]}u(ex,Q1=B1),ex.prototype.parse=function(t){return null==t?NaN:H(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},ex.prototype.contain=function(t){return K1(t=this.parse(t),this._extent)&&null!=this._ordinalMeta.categories[t]},ex.prototype.normalize=function(t){return $1(t=this._getTickNumber(this.parse(t)),this._extent)},ex.prototype.scale=function(t){return t=Math.round(J1(t,this._extent)),this.getRawOrdinalNumber(t)},ex.prototype.getTicks=function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push({value:n}),n++;return t},ex.prototype.getMinorTicks=function(t){},ex.prototype.setSortInfo=function(t){if(null==t)this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;else{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}}},ex.prototype._getTickNumber=function(t){var e=this._ticksByOrdinalNumber;return e&&0<=t&&t<e.length?e[t]:t},ex.prototype.getRawOrdinalNumber=function(t){var e=this._ordinalNumbersByTick;return e&&0<=t&&t<e.length?e[t]:t},ex.prototype.getLabel=function(t){if(!this.isBlank())return t=this.getRawOrdinalNumber(t.value),null==(t=this._ordinalMeta.categories[t])?"":t+""},ex.prototype.count=function(){return this._extent[1]-this._extent[0]+1},ex.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},ex.prototype.isInExtentRange=function(t){return t=this._getTickNumber(t),this._extent[0]<=t&&this._extent[1]>=t},ex.prototype.getOrdinalMeta=function(){return this._ordinalMeta},ex.prototype.calcNiceTicks=function(){},ex.prototype.calcNiceExtent=function(){},ex.type="ordinal";var Q1,tx=ex;function ex(t){var t=Q1.call(this,t)||this,e=(t.type="ordinal",t.getSetting("ordinalMeta"));return B(e=e||new W1({}))&&(e=new W1({categories:V(e,function(t){return O(t)?t.value:t})})),t._ordinalMeta=e,t._extent=t.getSetting("extent")||[0,e.categories.length-1],t}B1.registerClass(tx);var nx,ix=Dr,ox=(u(rx,nx=B1),rx.prototype.parse=function(t){return t},rx.prototype.contain=function(t){return K1(t,this._extent)},rx.prototype.normalize=function(t){return $1(t,this._extent)},rx.prototype.scale=function(t){return J1(t,this._extent)},rx.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},rx.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])},rx.prototype.getInterval=function(){return this._interval},rx.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=j1(t)},rx.prototype.getTicks=function(t){var e=this._interval,n=this._extent,i=this._niceExtent,o=this._intervalPrecision,r=[];if(e){n[0]<i[0]&&r.push(t?{value:ix(i[0]-e,o)}:{value:n[0]});for(var a=i[0];a<=i[1]&&(r.push({value:a}),(a=ix(a+e,o))!==r[r.length-1].value);)if(1e4<r.length)return[];var s=r.length?r[r.length-1].value:i[1];n[1]>s&&r.push(t?{value:ix(s+e,o)}:{value:n[1]})}return r},rx.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=ix(a.value+(s+1)*u);h>i[0]&&h<i[1]&&l.push(h),s++}n.push(l)}return n},rx.prototype.getLabel=function(t,e){return null==t?"":(null==(e=e&&e.precision)?e=kr(t.value)||0:"auto"===e&&(e=this._intervalPrecision),yd(ix(t.value,e,!0)))},rx.prototype.calcNiceTicks=function(t,e,n){t=t||5;var i=this._extent,o=i[1]-i[0];isFinite(o)&&(o<0&&i.reverse(),o=U1(i,t,e,n),this._intervalPrecision=o.intervalPrecision,this._interval=o.interval,this._niceExtent=o.niceTickExtent)},rx.prototype.calcNiceExtent=function(t){var e=this._extent,n=(e[0]===e[1]&&(0!==e[0]?(n=Math.abs(e[0]),t.fixMax||(e[1]+=n/2),e[0]-=n/2):e[1]=1),e[1]-e[0]),n=(isFinite(n)||(e[0]=0,e[1]=1),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval),this._interval);t.fixMin||(e[0]=ix(Math.floor(e[0]/n)*n)),t.fixMax||(e[1]=ix(Math.ceil(e[1]/n)*n))},rx.prototype.setNiceExtent=function(t,e){this._niceExtent=[t,e]},rx.type="interval",rx);function rx(){var t=null!==nx&&nx.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}B1.registerClass(ox);var ax="undefined"!=typeof Float32Array,sx=ax?Float32Array:Array;function lx(t){return B(t)?ax?new Float32Array(t):t:new sx(t)}var ux="__ec_stack_";function hx(t){return t.get("stack")||ux+t.seriesIndex}function cx(t){return t.dim+t.index}function px(t,e){var n=[];return e.eachSeriesByType(t,function(t){mx(t)&&n.push(t)}),n}function dx(t){var l=function(t){var e,l={},n=(nt(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]}}),{});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 nt(t,function(t){var e,n=t.coordinateSystem.getBaseAxis(),i=n.getExtent(),o=(e="category"===n.type?n.getBandWidth():"value"===n.type||"time"===n.type?(e=n.dim+"_"+n.index,e=l[e],o=Math.abs(i[1]-i[0]),r=n.scale.getExtent(),r=Math.abs(r[1]-r[0]),e?o/r*e:o):(r=t.getData(),Math.abs(i[1]-i[0])/r.count()),j(t.get("barWidth"),e)),i=j(t.get("barMaxWidth"),e),r=j(t.get("barMinWidth")||(vx(t)?.5:1),e),a=t.get("barGap"),s=t.get("barCategoryGap");u.push({bandWidth:e,barWidth:o,barMaxWidth:i,barMinWidth:r,barGap:a,barCategoryGap:s,axisKey:cx(n),stackId:hx(t)})}),gx(u)}function gx(t){var a={},d=(nt(t,function(t,e){var n=t.axisKey,i=t.bandWidth,i=a[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},o=i.stacks,n=(a[n]=i,t.stackId),r=(o[n]||i.autoWidthCount++,o[n]=o[n]||{width:0,maxWidth:0},t.barWidth),r=(r&&!o[n].width&&(o[n].width=r,r=Math.min(i.remainedWidth,r),i.remainedWidth-=r),t.barMaxWidth),r=(r&&(o[n].maxWidth=r),t.barMinWidth),o=(r&&(o[n].minWidth=r),t.barGap),n=(null!=o&&(i.gap=o),t.barCategoryGap);null!=n&&(i.categoryGap=n)}),{});return nt(a,function(t,n){d[n]={};var i,e=t.stacks,o=t.bandWidth,r=t.categoryGap,a=(null==r&&(a=W(e).length,r=Math.max(35-4*a,15)+"%"),j(r,o)),s=j(t.gap,1),l=t.remainedWidth,u=t.autoWidthCount,h=(l-a)/(u+(u-1)*s),h=Math.max(h,0),c=(nt(e,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,l-=e+s*e,u--):(e=h,n&&n<e&&(e=Math.min(n,l)),(e=i&&e<i?i:e)!==h&&(t.width=e,l-=e+s*e,u--))}),h=(l-a)/(u+(u-1)*s),h=Math.max(h,0),0),p=(nt(e,function(t,e){t.width||(t.width=h),c+=(i=t).width*(1+s)}),i&&(c-=i.width*s),-c/2);nt(e,function(t,e){d[n][e]=d[n][e]||{bandWidth:o,offset:p,width:t.width},p+=t.width*(1+s)})}),d}function fx(t,e){var t=px(t,e),o=dx(t);nt(t,function(t){var e=t.getData(),n=t.coordinateSystem.getBaseAxis(),t=hx(t),n=o[cx(n)][t],t=n.offset,i=n.width;e.setLayout({bandWidth:n.bandWidth,offset:t,size:i})})}function yx(t){return{seriesType:t,plan:Jy(),reset:function(t){var e,_,n,b,w,S,i,o,M,I,T,C,D,A,k,L;if(mx(t))return e=t.getData(),i=(_=t.coordinateSystem).getBaseAxis(),n=_.getOtherAxis(i),b=e.getDimensionIndex(e.mapDimension(n.dim)),w=e.getDimensionIndex(e.mapDimension(i.dim)),S=t.get("showBackground",!0),i=e.mapDimension(n.dim),o=e.getCalculationInfo("stackResultDimension"),M=E1(e,i)&&!!e.getCalculationInfo("stackedOnSeries"),I=n.isHorizontal(),T=n.toGlobalCoord(n.dataToCoord("log"===n.type?1:0)),C=vx(t),D=t.get("barMinHeight")||0,A=o&&e.getDimensionIndex(o),k=e.getLayout("size"),L=e.getLayout("offset"),{progress:function(t,e){for(var n,i=t.count,o=C&&lx(3*i),r=C&&S&&lx(3*i),a=C&&lx(i),s=_.master.getRect(),l=I?s.width:s.height,u=e.getStore(),h=0;null!=(n=t.next());){var c,p=u.get(M?A:b,n),d=u.get(w,n),g=T,f=void 0,y=(M&&(f=+p-u.get(b,n)),void 0),m=void 0,v=void 0,x=void 0;I?(c=_.dataToPoint([p,d]),y=g=M?_.dataToPoint([f,d])[0]:g,m=c[1]+L,v=c[0]-g,x=k,Math.abs(v)<D&&(v=(v<0?-1:1)*D)):(c=_.dataToPoint([d,p]),M&&(g=_.dataToPoint([d,f])[1]),y=c[0]+L,m=g,v=k,x=c[1]-g,Math.abs(x)<D&&(x=(x<=0?-1:1)*D)),C?(o[h]=y,o[h+1]=m,o[h+2]=I?v:x,r&&(r[h]=I?s.x:y,r[h+1]=I?m:s.y,r[h+2]=l),a[n]=n):e.setItemLayout(n,{x:y,y:m,width:v,height:x}),h+=3}C&&e.setLayout({largePoints:o,largeDataIndices:a,largeBackgroundPoints:r,valueAxisHorizontal:I})}}}}}function mx(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}function vx(t){return t.pipelineContext&&t.pipelineContext.large}u(bx,xx=ox),bx.prototype.getLabel=function(t){var e=this.getSetting("useUTC");return td(t.value,qp[function(t){switch(t){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}(Qp(this._minLevelUnit))]||qp.second,e,this.getSetting("locale"))},bx.prototype.getFormattedLabel=function(t,e,n){var i=this.getSetting("useUTC"),o=this.getSetting("locale"),r=null;if(H(n))r=n;else if(D(n))r=n(t.value,e,{level:t.level});else{var a=F({},Zp);if(0<t.level)for(var s=0;s<Kp.length;++s)a[Kp[s]]="{primary|"+a[Kp[s]]+"}";var l=n?!1===n.inherit?n:z(n,a):a,u=ed(t.value,i);if(l[u])r=l[u];else if(l.inherit){for(s=$p.indexOf(u)-1;0<=s;--s)if(l[u]){r=l[u];break}r=r||a.none}B(r)&&(e=null==t.level?0:0<=t.level?t.level:r.length+t.level,r=r[e=Math.min(e,r.length-1)])}return td(new Date(t.value),r,i,o)},bx.prototype.getTicks=function(){var t=this._interval,e=this._extent,n=[];return t&&(n.push({value:e[0],level:0}),t=this.getSetting("useUTC"),t=function(t,w,S,M){var e=$p,n=0;function i(t,e,n){var i=[],o=!e.length;if(!function(t,e,n,i){function o(t){return nd(c,t,i)===nd(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=Vr(e),p=Vr(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")}}(Qp(t),M[0],M[1],S)){o&&(e=[{value:function(t,e,n){var i=new Date(t);switch(Qp(e)){case"year":case"month":i[hd(n)](0);case"day":i[cd(n)](1);case"hour":i[pd(n)](0);case"minute":i[dd(n)](0);case"second":i[gd(n)](0),i[fd(n)](0)}return i.getTime()}(new Date(M[0]),t,S)},{value:M[1]}]);for(var r,a,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(w/Up/365)),c=id(S),p=S?"setUTCFullYear":"setFullYear";break;case"half-year":case"quarter":case"month":a=w,h=6<(a/=30*Up)?6:3<a?3:2<a?2:1,c=od(S),p=hd(S);break;case"week":case"half-week":case"day":a=w,h=16<(a/=Up)?16:7.5<a?7:3.5<a?4:1.5<a?2:1,c=rd(S),p=cd(S),0;break;case"half-day":case"quarter-day":case"hour":r=w,h=12<(r/=Xp)?12:6<r?6:3.5<r?4:2<r?2:1,c=ad(S),p=pd(S);break;case"minute":h=Mx(w,!0),c=sd(S),p=dd(S);break;case"second":h=Mx(w,!1),c=ld(S),p=gd(S);break;case"millisecond":h=Gr(w,!0),c=ud(S),p=fd(S)}b=_=x=v=m=y=f=g=d=void 0;for(var d=h,g=l,f=u,y=c,m=p,v=i,x=new Date(g),_=g,b=x[y]();_<f&&_<=M[1];)v.push({value:_}),x[m](b+=d),_=x.getTime();v.push({value:_,notAdd:!0}),"year"===t&&1<n.length&&0===s&&n.unshift({value:n[0].value-h})}}for(s=0;s<i.length;s++)n.push(i[s])}}for(var o=[],r=[],a=0,s=0,l=0;l<e.length&&n++<1e4;++l){var u=Qp(e[l]);if(function(t){return t===Qp(t)}(e[l])){i(e[l],o[o.length-1]||[],r);var h=e[l+1]?Qp(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 d=r[p].value;0!==p&&r[p-1].value===d||(c.push(r[p]),d>=M[0]&&d<=M[1]&&a++)}u=(M[1]-M[0])/w;if(1.5*u<a&&u/1.5<s)break;if(o.push(c),u<a||t===e[l])break}r=[]}}}for(var g=pt(V(o,function(t){return pt(t,function(t){return t.value>=M[0]&&t.value<=M[1]&&!t.notAdd})}),function(t){return 0<t.length}),f=[],y=g.length-1,l=0;l<g.length;++l)for(var m=g[l],v=0;v<m.length;++v)f.push({value:m[v].value,level:y-l});f.sort(function(t,e){return t.value-e.value});for(var x=[],l=0;l<f.length;++l)0!==l&&f[l].value===f[l-1].value||x.push(f[l]);return x}(this._minLevelUnit,this._approxInterval,t,e),(n=n.concat(t)).push({value:e[1],level:0})),n},bx.prototype.calcNiceExtent=function(t){var e,n=this._extent;n[0]===n[1]&&(n[0]-=Up,n[1]+=Up),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]-Up),this.calcNiceTicks(t.splitNumber,t.minInterval,t.maxInterval)},bx.prototype.calcNiceTicks=function(t,e,n){var i=this._extent,i=i[1]-i[0],i=(this._approxInterval=i/(t=t||10),null!=e&&this._approxInterval<e&&(this._approxInterval=e),null!=n&&this._approxInterval>n&&(this._approxInterval=n),Sx.length),t=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}(Sx,this._approxInterval,0,i),i-1);this._interval=Sx[t][1],this._minLevelUnit=Sx[Math.max(t-1,0)][0]},bx.prototype.parse=function(t){return Y(t)?t:+Vr(t)},bx.prototype.contain=function(t){return K1(this.parse(t),this._extent)},bx.prototype.normalize=function(t){return $1(this.parse(t),this._extent)},bx.prototype.scale=function(t){return J1(t,this._extent)},bx.type="time";var xx,_x=bx;function bx(t){t=xx.call(this,t)||this;return t.type="time",t}var Sx=[["second",Hp],["minute",Yp],["hour",Xp],["quarter-day",6*Xp],["half-day",12*Xp],["day",1.2*Up],["half-week",3.5*Up],["week",7*Up],["month",31*Up],["quarter",95*Up],["half-year",Ia/2],["year",Ia]];function Mx(t,e){return 30<(t/=e?Yp:Hp)?30:20<t?20:15<t?15:10<t?10:5<t?5:2<t?2:1}B1.registerClass(_x);var Ix,Tx=B1.prototype,Cx=ox.prototype,Dx=Dr,Ax=Math.floor,kx=Math.ceil,Lx=Math.pow,Px=Math.log,Ox=(u(Nx,Ix=B1),Nx.prototype.getTicks=function(t){var e=this._originalScale,n=this._extent,i=e.getExtent();return V(Cx.getTicks.call(this,t),function(t){var t=t.value,e=Dr(Lx(this.base,t)),e=t===n[0]&&this._fixMin?Rx(e,i[0]):e;return{value:t===n[1]&&this._fixMax?Rx(e,i[1]):e}},this)},Nx.prototype.setExtent=function(t,e){var n=Px(this.base);t=Px(Math.max(0,t))/n,e=Px(Math.max(0,e))/n,Cx.setExtent.call(this,t,e)},Nx.prototype.getExtent=function(){var t=this.base,e=Tx.getExtent.call(this);e[0]=Lx(t,e[0]),e[1]=Lx(t,e[1]);t=this._originalScale.getExtent();return this._fixMin&&(e[0]=Rx(e[0],t[0])),this._fixMax&&(e[1]=Rx(e[1],t[1])),e},Nx.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=Px(t[0])/Px(e),t[1]=Px(t[1])/Px(e),Tx.unionExtent.call(this,t)},Nx.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},Nx.prototype.calcNiceTicks=function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n==1/0||n<=0)){var i=Br(n);for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&0<Math.abs(i);)i*=10;t=[Dr(kx(e[0]/i)*i),Dr(Ax(e[1]/i)*i)];this._interval=i,this._niceExtent=t}},Nx.prototype.calcNiceExtent=function(t){Cx.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},Nx.prototype.parse=function(t){return t},Nx.prototype.contain=function(t){return K1(t=Px(t)/Px(this.base),this._extent)},Nx.prototype.normalize=function(t){return $1(t=Px(t)/Px(this.base),this._extent)},Nx.prototype.scale=function(t){return t=J1(t,this._extent),Lx(this.base,t)},Nx.type="log",Nx);function Nx(){var t=null!==Ix&&Ix.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new ox,t._interval=0,t}$m=Ox.prototype;function Rx(t,e){return Dx(t,kr(e))}$m.getMinorTicks=Cx.getMinorTicks,$m.getLabel=Cx.getLabel,B1.registerClass(Ox);zx.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,o=(this._needCrossZero="interval"===t.type&&e.getNeedCrossZero&&e.getNeedCrossZero(),this._modelMinRaw=e.get("min",!0)),o=(D(o)?this._modelMinNum=Gx(t,o({min:n[0],max:n[1]})):"dataMin"!==o&&(this._modelMinNum=Gx(t,o)),this._modelMaxRaw=e.get("max",!0));D(o)?this._modelMaxNum=Gx(t,o({min:n[0],max:n[1]})):"dataMax"!==o&&(this._modelMaxNum=Gx(t,o)),i?this._axisDataLen=e.getCategories().length:"boolean"==typeof(t=B(n=e.get("boundaryGap"))?n:[n||0,n||0])[0]||"boolean"==typeof t[1]?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[er(t[0],1),er(t[1],1)]},zx.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,e=(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),bt(a)||bt(s)||t&&!i),n=(this._needCrossZero&&(a=0<a&&0<s&&!l?0:a)<0&&s<0&&!u&&(s=0),this._determinedMin),o=this._determinedMax;return null!=n&&(a=n,l=!0),null!=o&&(s=o,u=!0),{min:a,max:s,minFixed:l,maxFixed:u,isBlank:e}},zx.prototype.modifyDataMinMax=function(t,e){this[Bx[t]]=e},zx.prototype.setDeterminedMinMax=function(t,e){this[Vx[t]]=e},zx.prototype.freeze=function(){this.frozen=!0};var Ex=zx;function zx(t,e,n){this._prepareParams(t,e,n)}var Vx={min:"_determinedMin",max:"_determinedMax"},Bx={min:"_dataMin",max:"_dataMax"};function Fx(t,e,n){var i=t.rawExtentInfo;return i||(i=new Ex(t,e,n),t.rawExtentInfo=i),i}function Gx(t,e){return null==e?null:bt(e)?NaN:t.parse(e)}function Wx(t,e){var n,i,o,r,a,s,l=t.type,u=Fx(t,e,t.getExtent()).calculate(),t=(t.setBlank(u.isBlank),u.min),h=u.max,c=e.ecModel;return c&&"time"===l&&(l=px("bar",c),n=!1,nt(l,function(t){n=n||t.getBaseAxis()===e.axis}),n)&&(c=dx(l),l=t,i=h,c=c,s=(s=(o=e).axis.getExtent())[1]-s[0],void 0!==(c=function(t,e,n){if(t&&e)return null!=(t=t[cx(e)])&&null!=n?t[hx(n)]:t}(c,o.axis))&&(r=1/0,nt(c,function(t){r=Math.min(t.offset,r)}),a=-1/0,nt(c,function(t){a=Math.max(t.offset+t.width,a)}),r=Math.abs(r),a=Math.abs(a),i+=a/(o=r+a)*(s=(c=i-l)/(1-(r+a)/s)-c),l-=r/o*s),t=(c={min:l,max:i}).min,h=c.max),{extent:[t,h],fixMin:u.minFixed,fixMax:u.maxFixed}}function Hx(t,e){var n=Wx(t,e),i=n.extent,o=e.get("splitNumber"),r=(t instanceof Ox&&(t.base=e.get("logBase")),t.type),a=e.get("interval"),r="interval"===r||"time"===r;t.setExtent(i[0],i[1]),t.calcNiceExtent({splitNumber:o,fixMin:n.fixMin,fixMax:n.fixMax,minInterval:r?e.get("minInterval"):null,maxInterval:r?e.get("maxInterval"):null}),null!=a&&t.setInterval&&t.setInterval(a)}function Yx(t,e){if(e=e||t.get("type"))switch(e){case"category":return new tx({ordinalMeta:t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),extent:[1/0,-1/0]});case"time":return new _x({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new(B1.getClass(e)||ox)}}function Xx(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)}):H(t)?(e=t,function(t){t=n.scale.getLabel(t);return e.replace("{value}",null!=t?t:"")}):D(t)?(i=t,function(t,e){return null!=r&&(e=t.value-r),i(Ux(n,t),e,null!=t.level?{level:t.level}:null)}):function(t){return n.scale.getLabel(t)}}function Ux(t,e){return"category"===t.type?t.scale.getLabel(e):e.value}function Zx(t){var e=t.model,n=t.scale;if(e.get(["axisLabel","show"])&&!n.isBlank()){var i,o,r=n.getExtent(),a=n instanceof tx?n.count():(i=n.getTicks()).length,s=t.getLabelModel(),l=Xx(t),u=1;40<a&&(u=Math.ceil(a/40));for(var h,c,p,d=0;d<a;d+=u){var g=l(i?i[d]:{value:r[0]+d},d),g=s.getTextRect(g),f=(g=g,h=s.get("rotate")||0,c=p=f=c=void 0,h=h*Math.PI/180,c=g.width,f=g.height,p=c*Math.abs(Math.cos(h))+Math.abs(f*Math.sin(h)),c=c*Math.abs(Math.sin(h))+Math.abs(f*Math.cos(h)),new U(g.x,g.y,p,c));o?o.union(f):o=f}return o}}function jx(t){t=t.get("interval");return null==t?"auto":t}function qx(t){return"category"===t.type&&0===jx(t.getLabelModel())}function Kx(e,t){var n={};return nt(e.mapDimensionsAll(t),function(t){n[z1(e,t)]=!0}),W(n)}Jx.prototype.getNeedCrossZero=function(){return!this.option.scale},Jx.prototype.getCoordSysModel=function(){};var $x=Jx;function Jx(){}var e0=Object.freeze({__proto__:null,createDimensions:function(t,e){return L1(t,e).dimensions},createList:function(t){return V1(null,t)},createScale:function(t,e){var n=e;return(e=Yx(n=e instanceof kp?n:new kp(e))).setExtent(t[0],t[1]),Hx(e,n),e},createSymbol:s0,createTextStyle:function(t,e){return ap(t,null,null,"normal"!==(e=e||{}).state)},dataStack:{isDimensionStacked:E1,enableDataStack:R1,getStackedDimension:z1},enableHoverEmphasis:Su,getECData:$,getLayoutRect:Ld,mixinAxisModelCommonMethods:function(t){ut(t,$x)}}),Qx=[],t_={registerPreprocessor:Gv,registerProcessor:Wv,registerPostInit:Hv,registerPostUpdate:Yv,registerUpdateLifecycle:Xv,registerAction:Uv,registerCoordinateSystem:Zv,registerLayout:jv,registerVisual:qv,registerTransform:t1,registerLoading:Jv,registerMap:Qv,registerImpl:function(t,e){G0[t]=e},PRIORITY:t0,ComponentModel:g,ComponentView:Ky,SeriesModel:Gy,ChartView:em,registerComponentModel:function(t){g.registerClass(t)},registerComponentView:function(t){Ky.registerClass(t)},registerSeriesModel:function(t){Gy.registerClass(t)},registerChartView:function(t){em.registerClass(t)},registerSubTypeDefaulter:function(t,e){g.registerSubTypeDefaulter(t,e)},registerPainter:function(t,e){wr(t,e)}};function r(t){B(t)?nt(t,function(t){r(t)}):0<=G(Qx,t)||(Qx.push(t),(t=D(t)?{install:t}:t).install(t_))}var e_=1e-8;function n_(t,e){return Math.abs(t-e)<e_}function i_(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+=Gs(o[0],o[1],a[0],a[1],e,n),o=a}var s=t[0];return n_(o[0],s[0])&&n_(o[1],s[1])||(i+=Gs(o[0],o[1],s[0],s[1],e,n)),0!==i}var o_=[];function r_(t,e){for(var n=0;n<t.length;n++)oe(t[n],t[n],e)}function a_(t,e,n,i){for(var o=0;o<t.length;o++){var r=t[o];(r=i?i.project(r):r)&&isFinite(r[0])&&isFinite(r[1])&&(re(e,e,r),ae(n,n,r))}}s_.prototype.setCenter=function(t){this._center=t},s_.prototype.getCenter=function(){return this._center||(this._center=this.calcCenter())};n0=s_;function s_(t){this.name=t}var l_,u_=function(t,e){this.type="polygon",this.exterior=t,this.interiors=e},h_=function(t){this.type="linestring",this.points=t},c_=(u(p_,l_=n0),p_.prototype.calcCenter=function(){for(var t,e=this.geometries,n=0,i=0;i<e.length;i++){var o=e[i],r=o.exterior,r=r&&r.length;n<r&&(t=o,n=r)}if(t){for(var a=t.exterior,s=0,l=0,u=0,h=a.length,c=a[h-1][0],p=a[h-1][1],d=0;d<h;d++){var g=a[d][0],f=a[d][1],y=c*f-g*p;s+=y,l+=(c+g)*y,u+=(p+f)*y,c=g,p=f}return s?[l/s/3,u/s/3,s]:[a[0][0]||0,a[0][1]||0]}var m=this.getBoundingRect();return[m.x+m.width/2,m.y+m.height/2]},p_.prototype.getBoundingRect=function(e){var n,i,t=this._rect;return t&&!e||(n=[1/0,1/0],i=[-1/0,-1/0],nt(this.geometries,function(t){"polygon"===t.type?a_(t.exterior,n,i,e):nt(t.points,function(t){a_(t,n,i,e)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(i[0])&&isFinite(i[1])||(n[0]=n[1]=i[0]=i[1]=0),t=new U(n[0],n[1],i[0]-n[0],i[1]-n[1]),e)||(this._rect=t),t},p_.prototype.contain=function(t){var e=this.getBoundingRect(),n=this.geometries;if(e.contain(t[0],t[1]))t:for(var i=0,o=n.length;i<o;i++){var r=n[i];if("polygon"===r.type){var a=r.exterior,s=r.interiors;if(i_(a,t[0],t[1])){for(var l=0;l<(s?s.length:0);l++)if(i_(s[l],t[0],t[1]))continue t;return!0}}}return!1},p_.prototype.transformTo=function(t,e,n,i){for(var o=this.getBoundingRect(),r=o.width/o.height,r=(n?i=i||n/r:n=r*i,new U(t,e,n,i)),a=o.calculateTransform(r),s=this.geometries,l=0;l<s.length;l++){var u=s[l];"polygon"===u.type?(r_(u.exterior,a),nt(u.interiors,function(t){r_(t,a)})):nt(u.points,function(t){r_(t,a)})}(o=this._rect).copy(r),this._center=[o.x+o.width/2,o.y+o.height/2]},p_.prototype.cloneShallow=function(t){t=new p_(t=null==t?this.name:t,this.geometries,this._center);return t._rect=this._rect,t.transformTo=null,t},p_);function p_(t,e,n){t=l_.call(this,t)||this;return t.type="geoJSON",t.geometries=e,t._center=n&&[n[0],n[1]],t}u(f_,d_=n0),f_.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,e=t.getBoundingRect(),e=[e.x+e.width/2,e.y+e.height/2],n=Ve(o_),i=t;i&&!i.isGeoSVGGraphicRoot;)Fe(n,i.getLocalTransform(),n),i=i.parent;return Ye(n,n),oe(e,e,n),e};var d_,g_=f_;function f_(t,e){t=d_.call(this,t)||this;return t.type="geoSVG",t._elOnlyForCalculate=e,t}function y_(t,e,n){for(var i=0;i<t.length;i++)t[i]=m_(t[i],e[i],n)}function m_(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);i.push([(o=s+=o)/n,(r=l+=r)/n])}return i}function v_(t,r){var e,n,o;return V(pt((t=(e=t).UTF8Encoding?(null==(o=(n=e).UTF8Scale)&&(o=1024),nt(n.features,function(t){var e=t.geometry,n=e.encodeOffsets,i=e.coordinates;if(n)switch(e.type){case"LineString":e.coordinates=m_(i,n,o);break;case"Polygon":case"MultiLineString":y_(i,n,o);break;case"MultiPolygon":nt(i,function(t,e){return y_(t,n[e],o)})}}),n.UTF8Encoding=!1,n):e).features,function(t){return t.geometry&&t.properties&&0<t.geometry.coordinates.length}),function(t){var e=t.properties,n=t.geometry,i=[];switch(n.type){case"Polygon":var o=n.coordinates;i.push(new u_(o[0],o.slice(1)));break;case"MultiPolygon":nt(n.coordinates,function(t){t[0]&&i.push(new u_(t[0],t.slice(1)))});break;case"LineString":i.push(new h_([n.coordinates]));break;case"MultiLineString":i.push(new h_(n.coordinates))}t=new c_(e[r||"name"],i,e.cp);return t.properties=e,t})}var La=Object.freeze({__proto__:null,MAX_SAFE_INTEGER:Nr,asc:Ar,getPercentWithPrecision:function(t,e,n){return t[e]&&Or(t,n)[e]||0},getPixelPrecision:Pr,getPrecision:kr,getPrecisionSafe:Lr,isNumeric:Xr,isRadianAroundZero:Er,linearMap:Cr,nice:Gr,numericToNumber:Yr,parseDate:Vr,quantile:Wr,quantity:Br,quantityExponent:Fr,reformIntervals:Hr,remRadian:Rr,round:Dr}),xp=Object.freeze({__proto__:null,format:td,parse:Vr}),jp=Object.freeze({__proto__:null,Arc:Kh,BezierCurve:Uh,BoundingRect:U,Circle:eh,CompoundPath:Qh,Ellipse:rh,Group:Z,Image:ll,IncrementalDisplayable:e,Line:Fh,LinearGradient:ic,Polygon:Lh,Polyline:Rh,RadialGradient:ac,Rect:L,Ring:Th,Sector:wh,Text:K,clipPointsByRect:Uc,clipRectByRect:Zc,createIcon:jc,extendPath:Lc,extendShape:Ac,getShapeClass:Oc,getTransform:Gc,initProps:_c,makeImage:Rc,makePath:Nc,mergePath:zc,registerShape:Pc,resizePath:Vc,updateProps:C}),Sp=Object.freeze({__proto__:null,addCommas:yd,capitalFirst:function(t){return t&&t.charAt(0).toUpperCase()+t.substr(1)},encodeHTML:we,formatTime:function(t,e,n){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var i=(e=Vr(e))[(n=n?"getUTC":"get")+"FullYear"](),o=e[n+"Month"]()+1,r=e[n+"Date"](),a=e[n+"Hours"](),s=e[n+"Minutes"](),l=e[n+"Seconds"](),e=e[n+"Milliseconds"]();return t=t.replace("MM",Jp(o,2)).replace("M",o).replace("yyyy",i).replace("yy",Jp(i%100+"",2)).replace("dd",Jp(r,2)).replace("d",r).replace("hh",Jp(a,2)).replace("h",a).replace("mm",Jp(s,2)).replace("m",s).replace("ss",Jp(l,2)).replace("s",l).replace("SSS",Jp(e,3))},formatTpl:wd,getTextRect:function(t,e,n,i,o,r,a,s){return new K({style:{text:t,font:e,align:n,verticalAlign:i,padding:o,rich:r,overflow:a?"truncate":null,lineHeight:s}}).getBoundingRect()},getTooltipMarker:Sd,normalizeCssArray:vd,toCamelCase:md,truncateText:Va}),Wm=Object.freeze({__proto__:null,bind:T,clone:S,curry:P,defaults:z,each:nt,extend:F,filter:pt,indexOf:G,inherits:lt,isArray:B,isFunction:D,isObject:O,isString:H,map:V,merge:d,reduce:ct}),x_=i();function __(t){return"category"===t.type?(o=(e=t).getLabelModel(),r=w_(e,o),!o.get("show")||e.scale.isBlank()?{labels:[],labelCategoryInterval:r.labelCategoryInterval}:r):(o=(n=t).scale.getTicks(),i=Xx(n),{labels:V(o,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 b_(t,e){var n,i,o,r,a,s;return"category"===t.type?(e=e,r=S_(n=t,"ticks"),a=jx(e),(s=M_(r,a))||(e.get("show")&&!n.scale.isBlank()||(i=[]),i=D(a)?C_(n,a,!0):"auto"===a?(s=w_(n,n.getLabelModel()),o=s.labelCategoryInterval,V(s.labels,function(t){return t.tickValue})):T_(n,o=a,!0),I_(r,a,{ticks:i,tickCategoryInterval:o}))):{ticks:V(t.scale.getTicks(),function(t){return t.value})}}function w_(t,e){var n,i=S_(t,"labels"),e=jx(e),o=M_(i,e);return o||I_(i,e,{labels:D(e)?C_(t,e):T_(t,n="auto"===e?null!=(i=x_(o=t).autoInterval)?i:x_(o).autoInterval=o.calculateCategoryInterval():e),labelCategoryInterval:n})}function S_(t,e){return x_(t)[e]||(x_(t)[e]=[])}function M_(t,e){for(var n=0;n<t.length;n++)if(t[n].key===e)return t[n].value}function I_(t,e,n){return t.push({key:e,value:n}),n}function T_(t,e,n){for(var i=Xx(t),o=t.scale,r=o.getExtent(),a=t.getLabelModel(),s=[],l=Math.max((e||0)+1,1),e=r[0],u=o.count(),u=(0!==e&&1<l&&2<u/l&&(e=Math.round(Math.ceil(e/l)*l)),qx(t)),t=a.get("showMinLabel")||u,a=a.get("showMaxLabel")||u,h=(t&&e!==r[0]&&c(r[0]),e);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 a&&h-l!==r[1]&&c(r[1]),s}function C_(t,i,o){var r=t.scale,a=Xx(t),s=[];return nt(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 D_=[0,1],Ip=(A_.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},A_.prototype.containData=function(t){return this.scale.contain(t)},A_.prototype.getExtent=function(){return this._extent.slice()},A_.prototype.getPixelPrecision=function(t){return Pr(t||this.scale.getExtent(),this._extent)},A_.prototype.setExtent=function(t,e){var n=this._extent;n[0]=t,n[1]=e},A_.prototype.dataToCoord=function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&k_(n=n.slice(),i.count()),Cr(t,D_,n,e)},A_.prototype.coordToData=function(t,e){var n=this._extent,i=this.scale,i=(this.onBand&&"ordinal"===i.type&&k_(n=n.slice(),i.count()),Cr(t,n,D_,e));return this.scale.scale(i)},A_.prototype.pointToData=function(t,e){},A_.prototype.getTicksCoords=function(t){var e,n,i,o,r,a,s,l=(t=t||{}).tickModel||this.getTickModel(),u=V(b_(this,l).ticks,function(t){return{coord:this.dataToCoord("ordinal"===this.scale.type?this.scale.getRawOrdinalNumber(t):t),tickValue:t}},this),l=l.get("alignWithLabel");function h(t,e){return t=Dr(t),e=Dr(e),a?e<t:t<e}return e=this,n=u,l=l,t=t.clamp,s=n.length,e.onBand&&!l&&s&&(l=e.getExtent(),1===s?(n[0].coord=l[0],i=n[1]={coord:l[1]}):(r=n[s-1].tickValue-n[0].tickValue,o=(n[s-1].coord-n[0].coord)/r,nt(n,function(t){t.coord-=o/2}),e=1+(r=e.scale.getExtent())[1]-n[s-1].tickValue,i={coord:n[s-1].coord+o*e},n.push(i)),a=l[0]>l[1],h(n[0].coord,l[0])&&(t?n[0].coord=l[0]:n.shift()),t&&h(l[0],n[0].coord)&&n.unshift({coord:l[0]}),h(l[1],i.coord)&&(t?i.coord=l[1]:n.pop()),t)&&h(i.coord,l[1])&&n.push({coord:l[1]}),u},A_.prototype.getMinorTicksCoords=function(){var t;return"ordinal"===this.scale.type?[]:(t=this.model.getModel("minorTick").get("splitNumber"),V(this.scale.getMinorTicks(t=0<t&&t<100?t:5),function(t){return V(t,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this)},this))},A_.prototype.getViewLabels=function(){return __(this).labels},A_.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},A_.prototype.getTickModel=function(){return this.model.getModel("axisTick")},A_.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),e=e[1]-e[0]+(this.onBand?1:0),t=(0===e&&(e=1),Math.abs(t[1]-t[0]));return Math.abs(t)/e},A_.prototype.calculateCategoryInterval=function(){o=(n=d=this).getLabelModel();var t={axisRotate:n.getRotate?n.getRotate():n.isHorizontal&&!n.isHorizontal()?90:0,labelRotate:o.get("rotate")||0,font:o.getFont()},e=Xx(d),n=(t.axisRotate-t.labelRotate)/180*Math.PI,i=(o=d.scale).getExtent(),o=o.count();if(i[1]-i[0]<1)return 0;for(var r=1,a=(40<o&&(r=Math.max(1,Math.floor(o/40))),i[0]),s=d.dataToCoord(a+1)-d.dataToCoord(a),l=Math.abs(s*Math.cos(n)),s=Math.abs(s*Math.sin(n)),u=0,h=0;a<=i[1];a+=r)var c=1.3*(p=$o(e({value:a}),t.font,"center","top")).width,p=1.3*p.height,u=Math.max(u,c,7),h=Math.max(h,p,7);var n=u/l,l=h/s,s=(isNaN(n)&&(n=1/0),isNaN(l)&&(l=1/0),Math.max(0,Math.floor(Math.min(n,l)))),n=x_(d.model),l=d.getExtent(),d=n.lastAutoInterval,g=n.lastTickCount;return null!=d&&null!=g&&Math.abs(d-s)<=1&&Math.abs(g-o)<=1&&s<d&&n.axisExtent0===l[0]&&n.axisExtent1===l[1]?s=d:(n.lastTickCount=o,n.lastAutoInterval=s,n.axisExtent0=l[0],n.axisExtent1=l[1]),s},A_);function A_(t,e,n){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=n||[0,0]}function k_(t,e){e=(t[1]-t[0])/e/2;t[0]+=e,t[1]-=e}var L_=2*Math.PI,P_=Ns.CMD,O_=["top","right","bottom","left"];function N_(t,e,n,i,o,r,a,s){var l=o-t,u=r-e,n=n-t,i=i-e,h=Math.sqrt(n*n+i*i),l=(l*(n/=h)+u*(i/=h))/h,u=(s&&(l=Math.min(Math.max(l,0),1)),a[0]=t+(l*=h)*n),s=a[1]=e+l*i;return Math.sqrt((u-o)*(u-o)+(s-r)*(s-r))}function R_(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,t=a[0]=Math.min(Math.max(o,t),n),n=a[1]=Math.min(Math.max(r,e),i);return Math.sqrt((t-o)*(t-o)+(n-r)*(n-r))}var E_=[];function z_(t,e,n){for(var i,o,r,a,s,l,u,h,c,p=0,d=0,g=0,f=0,y=1/0,m=e.data,v=t.x,x=t.y,_=0;_<m.length;){var b=m[_++],w=(1===_&&(g=p=m[_],f=d=m[_+1]),y);switch(b){case P_.M:p=g=m[_++],d=f=m[_++];break;case P_.L:w=N_(p,d,m[_],m[_+1],v,x,E_,!0),p=m[_++],d=m[_++];break;case P_.C:w=Kn(p,d,m[_++],m[_++],m[_++],m[_++],m[_],m[_+1],v,x,E_),p=m[_++],d=m[_++];break;case P_.Q:w=ei(p,d,m[_++],m[_++],m[_],m[_+1],v,x,E_),p=m[_++],d=m[_++];break;case P_.A:var S=m[_++],M=m[_++],I=m[_++],T=m[_++],C=m[_++],D=m[_++],A=(_+=1,!!(1-m[_++])),k=Math.cos(C)*I+S,L=Math.sin(C)*T+M;_<=1&&(g=k,f=L),L=(k=C)+D,A=A,a=(v-S)*(r=T)/I+S,s=x,l=E_,c=h=u=void 0,a-=i=S,s-=o=M,u=Math.sqrt(a*a+s*s),h=(a/=u)*r+i,c=(s/=u)*r+o,w=Math.abs(k-L)%L_<1e-4||((L=A?(A=k,k=Bs(L),Bs(A)):(k=Bs(k),Bs(L)))<k&&(L+=L_),(A=Math.atan2(s,a))<0&&(A+=L_),k<=A&&A<=L)||k<=A+L_&&A+L_<=L?(l[0]=h,l[1]=c,u-r):(c=((A=r*Math.cos(k)+i)-a)*(A-a)+((h=r*Math.sin(k)+o)-s)*(h-s))<(i=((u=r*Math.cos(L)+i)-a)*(u-a)+((k=r*Math.sin(L)+o)-s)*(k-s))?(l[0]=A,l[1]=h,Math.sqrt(c)):(l[0]=u,l[1]=k,Math.sqrt(i)),p=Math.cos(C+D)*I+S,d=Math.sin(C+D)*T+M;break;case P_.R:w=R_(g=p=m[_++],f=d=m[_++],m[_++],m[_++],v,x,E_);break;case P_.Z:w=N_(p,d,g,f,v,x,E_,!0),p=g,d=f}w<y&&(y=w,n.set(E_[0],E_[1]))}return y}var V_=new E,B_=new E,F_=new E,G_=new E,W_=new E;function H_(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||O_,s=i.getBoundingRect().clone(),l=(s.applyTransform(i.getComputedTransform()),1/0),u=o.anchor,h=t.getComputedTransform(),c=h&&Ye([],h),p=e.get("length2")||0;u&&F_.copy(u);for(var d,g=0;g<a.length;g++){var f=a[g],y=(w=b=_=x=v=m=y=void 0,f),m=0,v=s,x=V_,_=G_,b=v.width,w=v.height;switch(y){case"top":x.set(v.x+b/2,v.y-m),_.set(0,-1);break;case"bottom":x.set(v.x+b/2,v.y+w+m),_.set(0,1);break;case"left":x.set(v.x-m,v.y+w/2),_.set(-1,0);break;case"right":x.set(v.x+b+m,v.y+w/2),_.set(1,0)}E.scaleAndAdd(B_,V_,G_,p),B_.transform(c);f=t.getBoundingRect(),f=u?u.distance(B_):t instanceof q?z_(B_,t.path,F_):(y=F_,d=R_((d=f).x,f.y,f.width,f.height,B_.x,B_.y,E_),y.set(E_[0],E_[1]),d);f<l&&(l=f,B_.transform(h),F_.transform(h),F_.toArray(r[0]),B_.toArray(r[1]),V_.toArray(r[2]))}U_(r,e.get("minTurnAngle")),n.setShape({points:r})}}}var Y_=[],X_=new E;function U_(t,e){var n,i;e<=180&&0<e&&(e=e/180*Math.PI,V_.fromArray(t[0]),B_.fromArray(t[1]),F_.fromArray(t[2]),E.sub(G_,V_,B_),E.sub(W_,F_,B_),i=G_.len(),n=W_.len(),i<.001||n<.001||(G_.scale(1/i),W_.scale(1/n),i=G_.dot(W_),Math.cos(e)<i&&(n=N_(B_.x,B_.y,F_.x,F_.y,V_.x,V_.y,Y_,!1),X_.fromArray(Y_),X_.scaleAndAdd(W_,n/Math.tan(Math.PI-e)),i=F_.x!==B_.x?(X_.x-B_.x)/(F_.x-B_.x):(X_.y-B_.y)/(F_.y-B_.y),isNaN(i)||(i<0?E.copy(X_,B_):1<i&&E.copy(X_,F_),X_.toArray(t[1])))))}function Z_(t,e,n,i){var o="normal"===n,n=o?t:t.ensureState(n),e=(n.ignore=e,i.get("smooth")),e=(e&&!0===e&&(e=.3),n.shape=n.shape||{},0<e&&(n.shape.smooth=e),i.getModel("lineStyle").getLineStyle());o?t.useStyle(e):n.style=e}function j_(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 e=te(i[0],i[1]),o=te(i[1],i[2]);e&&o?(n=Math.min(e,o)*n,e=ie([],i[1],i[0],n/e),n=ie([],i[1],i[2],n/o),o=ie([],e,n,.5),t.bezierCurveTo(e[0],e[1],e[0],e[1],o[0],o[1]),t.bezierCurveTo(n[0],n[1],n[0],n[1],i[2][0],i[2][1])):(t.lineTo(i[1][0],i[1][1]),t.lineTo(i[2][0],i[2][1]))}else for(var r=1;r<i.length;r++)t.lineTo(i[r][0],i[r][1])}function q_(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<Hl.length;l++){var u,h=Hl[l],c=e[h],p="normal"===h;c&&(u=c.get("show"),(p?s:N(o.states[h]&&o.states[h].ignore,s))||!N(u,a)?((u=p?i:i&&i.states[h])&&(u.ignore=!0),i&&Z_(i,!0,h,c)):(i||(i=new Rh,t.setTextGuideLine(i),p||!s&&a||Z_(i,!0,"normal",e.normal),t.stateProxy&&(i.stateProxy=t.stateProxy)),Z_(i,!1,h,c)))}i&&(z(i.style,n),i.style.fill=null,n=r.get("showAbove"),(t.textGuideLineConfig=t.textGuideLineConfig||{}).showAbove=n||!1,i.buildPath=j_)}else i&&t.removeTextGuideLine()}function K_(t,e){for(var n={normal:t.getModel(e=e||"labelLine")},i=0;i<Wl.length;i++){var o=Wl[i];n[o]=t.getModel([o,e])}return n}function $_(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 pc(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 J_(s,l,u,t,e,n){var h=s.length;if(!(h<2)){s.sort(function(t,e){return t.rect[l]-e.rect[l]});for(var i=0,r=!1,o=0,a=0;a<h;a++){var c,p=s[a],d=p.rect;(c=d[l]-i)<0&&(d[l]-=c,p.label[l]-=c,r=!0),o+=Math.max(-c,0),i=d[l]+d[u]}0<o&&n&&_(-o/h,0,h);var g,f,y=s[0],m=s[h-1];return v(),g<0&&b(-g,.8),f<0&&b(f,.8),v(),x(g,f,1),x(f,g,-1),v(),g<0&&w(-g),f<0&&w(f),r}function v(){g=y.rect[l]-t,f=e-m.rect[l]-m.rect[u]}function x(t,e,n){t<0&&(0<(e=Math.min(e,-t))?(_(e*n,0,h),(e=e+t)<0&&b(-e*n,1)):b(-t*n,1))}function _(t,e,n){0!==t&&(r=!0);for(var i=e;i<n;i++){var o=s[i];o.rect[l]+=t,o.label[l]+=t}}function b(t,e){for(var n=[],i=0,o=1;o<h;o++){var r=s[o-1].rect,r=Math.max(s[o].rect[l]-r[l]-r[u],0);n.push(r),i+=r}if(i){var a=Math.min(Math.abs(t)/i,e);if(0<t)for(o=0;o<h-1;o++)_(n[o]*a,0,o+1);else for(o=h-1;0<o;o--)_(-(n[o-1]*a),o,h)}}function w(t){for(var e=t<0?-1:1,n=(t=Math.abs(t),Math.ceil(t/(h-1))),i=0;i<h-1;i++)if(0<e?_(n,0,i+1):_(-n,h-i-1,h),(t-=n)<=0)return}}function Q_(t,e,n,i){return J_(t,"y","height",e,n,i)}function tb(t){var e=[],n=(t.sort(function(t,e){return e.priority-t.priority}),new U(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++){for(var r=t[o],a=r.axisAligned,s=r.localRect,l=r.transform,u=r.label,h=r.labelLine,c=(n.copy(r.rect),n.width-=.1,n.height-=.1,n.x+=.05,n.y+=.05,r.obb),p=!1,d=0;d<e.length;d++){var g=e[d];if(n.intersect(g.rect)){if(a&&g.axisAligned){p=!0;break}if(g.obb||(g.obb=new pc(g.localRect,g.transform)),(c=c||new pc(s,l)).intersect(g.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 eb(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 nb=["align","verticalAlign","width","height","fontSize"],ib=new Yo,ob=i(),rb=i();function ab(t,e,n){for(var i=0;i<n.length;i++){var o=n[i];null!=e[o]&&(t[o]=e[o])}}var sb=["x","y","rotation"],lb=(ub.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},ub.prototype._addLabel=function(t,e,n,i,o){var r,a=i.style,s=i.__hostTarget.textConfig||{},l=i.getComputedTransform(),u=i.getBoundingRect().plain(),l=(U.applyTransform(u,u,l),l?ib.setLocalTransform(l):(ib.x=ib.y=ib.rotation=ib.originX=ib.originY=0,ib.scaleX=ib.scaleY=1),ib.rotation=Bs(ib.rotation),i.__hostTarget),h=(l&&(r=l.getBoundingRect().plain(),h=l.getComputedTransform(),U.applyTransform(r,r,h)),r&&l.getTextGuideLine());this._labelList.push({label:i,labelLine:h,seriesModel:n,dataIndex:t,dataType:e,layoutOption:o,computedLayoutOption:null,rect:u,hostRect:r,priority:r?r.width*r.height:0,defaultAttr:{ignore:i.ignore,labelGuideIgnore:h&&h.ignore,x:ib.x,y:ib.y,scaleX:ib.scaleX,scaleY:ib.scaleY,rotation:ib.rotation,style:{x:a.x,y:a.y,align:a.align,verticalAlign:a.verticalAlign,width:a.width,height:a.height,fontSize:a.fontSize},cursor:i.cursor,attachedPos:s.position,attachedRot:s.rotation}})},ub.prototype.addLabelsOfSeries=function(t){var n=this,i=(this._chartViewList.push(t),t.__model),o=i.get("labelLayout");(D(o)||W(o).length)&&t.group.traverse(function(t){if(t.ignore)return!0;var e=t.getTextContent(),t=$(t);e&&!e.disableLabelLayout&&n._addLabel(t.dataIndex,t.dataType,i,e,o)})},ub.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=void 0,l=D(o.layoutOption)?o.layoutOption(eb(o,a)):o.layoutOption,u=(o.computedLayoutOption=l=l||{},Math.PI/180),h=(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]}),!1);null!=l.x?(r.x=j(l.x,e),r.setStyle("x",0),h=!0):(r.x=s.x,r.setStyle("x",s.style.x)),null!=l.y?(r.y=j(l.y,n),r.setStyle("y",0),h=!0):(r.y=s.y,r.setStyle("y",s.style.y)),l.labelLinePoints&&(c=a.getTextGuideLine())&&(c.setShape({points:l.labelLinePoints}),h=!1),ob(r).needsUpdateLabelLine=h,r.rotation=null!=l.rotate?l.rotate*u:s.rotation,r.scaleX=s.scaleX,r.scaleY=s.scaleY;for(var c,p=0;p<nb.length;p++){var d=nb[p];r.setStyle(d,(null!=l[d]?l:s.style)[d])}l.draggable?(r.draggable=!0,r.cursor="move",a&&(c=o.seriesModel,null!=o.dataIndex&&(c=o.seriesModel.getData(o.dataType).getItemModel(o.dataIndex)),r.on("drag",function(t,e){return function(){H_(t,e)}}(a,c.getModel("labelLine"))))):(r.off("drag"),r.cursor=s.cursor)}},ub.prototype.layout=function(t){var e,n=t.getWidth(),t=t.getHeight(),i=$_(this._labelList),o=pt(i,function(t){return"shiftX"===t.layoutOption.moveOverlap}),r=pt(i,function(t){return"shiftY"===t.layoutOption.moveOverlap});J_(o,"x","width",0,n,e),Q_(r,0,t),tb(pt(i,function(t){return t.layoutOption.hideOverlap}))},ub.prototype.processLabelsOverall=function(){var a=this;nt(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?ob(n).needsUpdateLabelLine:e)&&a._updateLabelLine(t,i),r&&a._animateLabels(t,i)})})},ub.prototype._updateLabelLine=function(t,e){var n=t.getTextContent(),i=$(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]),o=e.getModel("labelLine"),q_(t,K_(e),i),H_(t,o))},ub.prototype._animateLabels=function(t,e){var n,i,o,r,a,s=t.getTextContent(),l=t.getTextGuideLine();!s||!t.forceLabelAnimation&&(s.ignore||s.invisible||t.disableLabelAnimation||bc(t))||(r=(o=ob(s)).oldLayout,n=(i=$(t)).dataIndex,a={x:s.x,y:s.y,rotation:s.rotation},i=e.getData(i.dataType),r?(s.attr(r),(t=t.prevStates)&&(0<=G(t,"select")&&s.attr(o.oldLayoutSelect),0<=G(t,"emphasis"))&&s.attr(o.oldLayoutEmphasis),C(s,a,e,n)):(s.attr(a),dp(s).valueAnimation||(t=N(s.style.opacity,1),s.style.opacity=0,_c(s,{style:{opacity:t}},e,n))),o.oldLayout=a,s.states.select&&(ab(t=o.oldLayoutSelect={},a,sb),ab(t,s.states.select,sb)),s.states.emphasis&&(ab(t=o.oldLayoutEmphasis={},a,sb),ab(t,s.states.emphasis,sb)),fp(s,n,i,e,e)),!l||l.ignore||l.invisible||(r=(o=rb(l)).oldLayout,a={points:l.shape.points},r?(l.attr({shape:r}),C(l,{shape:a},e)):(l.setShape(a),l.style.strokePercent=0,_c(l,{style:{strokePercent:1}},e)),o.oldLayout=a)},ub);function ub(){this._labelList=[],this._chartViewList=[]}var hb=i();function cb(t){t.registerUpdateLifecycle("series:beforeupdate",function(t,e,n){(hb(e).labelManager||(hb(e).labelManager=new lb)).clearLabels()}),t.registerUpdateLifecycle("series:layoutlabels",function(t,e,n){var i=hb(e).labelManager;n.updatedSeries.forEach(function(t){i.addLabelsOfSeries(e.getViewOfSeriesModel(t))}),i.updateLayoutConfig(e),i.layout(e),i.processLabelsOverall()})}function pb(t,e,n){var i=Q.createCanvas(),o=e.getWidth(),e=e.getHeight(),r=i.style;return r&&(r.position="absolute",r.left="0",r.top="0",r.width=o+"px",r.height=e+"px",i.setAttribute("data-zr-dom-id",t)),i.width=o*n,i.height=e*n,i}r(cb);u(fb,db=ce),fb.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},fb.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},fb.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},fb.prototype.setUnpainted=function(){this.__firstTimePaint=!0},fb.prototype.createBackBuffer=function(){var t=this.dpr;this.domBack=pb("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!==t&&this.ctxBack.scale(t,t)},fb.prototype.createRepaintRects=function(t,e,n,i){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var l=[],u=this.maxRepaintRectCount,h=!1,c=new U(0,0,0,0);function o(t){if(t.isFinite()&&!t.isZero())if(0===l.length)(e=new U(0,0,0,0)).copy(t),l.push(e);else{for(var e,n=!1,i=1/0,o=0,r=0;r<l.length;++r){var a=l[r];if(a.intersect(t)){var s=new U(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 U(0,0,0,0)).copy(t),l.push(e)),h=h||l.length>=u}}for(var r,a=this.__startIndex;a<this.__endIndex;++a)(s=t[a])&&(d=s.shouldBePainted(n,i,!0,!0),(p=s.__isRendered&&(s.__dirty&In||!d)?s.getPrevPaintRect():null)&&o(p),r=d&&(s.__dirty&In||!s.__isRendered)?s.getPaintRect():null)&&o(r);for(a=this.__prevStartIndex;a<this.__prevEndIndex;++a){var s,p,d=(s=e[a])&&s.shouldBePainted(n,i,!0,!0);!s||d&&s.__zr||!s.__isRendered||(p=s.getPrevPaintRect())&&o(p)}do{for(var g=!1,a=0;a<l.length;)if(l[a].isZero())l.splice(a,1);else{for(var f=a+1;f<l.length;)l[a].intersect(l[f])?(g=!0,l[a].union(l[f]),l.splice(f,1)):f++;a++}}while(g);return this._paintRects=l},fb.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},fb.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)},fb.prototype.clear=function(t,r,e){var n=this.dom,a=this.ctx,i=n.width,o=n.height,s=(r=r||this.clearColor,this.motionBlur&&!t),l=this.lastFrameAlpha,u=this.dpr,h=this,c=(s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(n,0,0,i/u,o/u)),this.domBack);function p(t,e,n,i){var o;a.clearRect(t,e,n,i),r&&"transparent"!==r&&(o=void 0,vt(r)?(o=(r.global||r.__width===n&&r.__height===i)&&r.__canvasGradient||c0(a,r,{x:0,y:0,width:n,height:i}),r.__canvasGradient=o,r.__width=n,r.__height=i):xt(r)&&(r.scaleX=r.scaleX||u,r.scaleY=r.scaleY||u,o=b0(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&&nt(e,function(t){p(t.x*u,t.y*u,t.width*u,t.height*u)})};var db,gb=fb;function fb(t,e,n){var i,o=db.call(this)||this,t=(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||Ro,"string"==typeof t?i=pb(t,e,n):O(t)&&(t=(i=t).id),o.id=t,(o.dom=i).style);return t&&(Vt(i),i.onselectstart=function(){return!1},t.padding="0",t.margin="0",t.borderWidth="0"),o.painter=e,o.dpr=n,o}var yb=314159;vb.prototype.getType=function(){return"canvas"},vb.prototype.isSingleCanvas=function(){return this._singleCanvas},vb.prototype.getViewportRoot=function(){return this._domRoot},vb.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},vb.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,a=i[o],a=this._layers[a];!a.__builtin__&&a.refresh&&(r=0===o?this._backgroundColor:null,a.refresh(r))}return this._opts.useDirtyRect&&(this._prevDisplayList=e.slice()),this},vb.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},vb.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(),N0(i,a,o,r===e-1))}i&&i.restore()}},vb.prototype.getHoverLayer=function(){return this.getLayer(1e5)},vb.prototype.paintOne=function(t,e){O0(t,e)},vb.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,Pn(function(){a._paintList(t,e,n,i)})))},vb.prototype._compositeManually=function(){var e=this.getLayer(yb).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)})},vb.prototype._doPaintList=function(d,g,f){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||f)&&m.push(e)}for(var x=!0,_=!1,n=function(t){function e(t){var e={inHover:!1,allClipped:!1,prevEl:null,viewWidth:y._width,viewHeight:y._height};for(i=s;i<o.__endIndex;i++){var n=d[i];if(n.__inHover&&(_=!0),y._doPaintEl(n,o,v,t,e,i===o.__endIndex-1),l)if(15<Date.now()-u)break}e.prevElClipPaths&&r.restore()}var n,i,o=m[t],r=o.ctx,a=v&&o.createRepaintRects(d,g,b._width,b._height),s=f?o.__startIndex:o.__drawIndex,l=!f&&o.incremental&&Date.now,u=l&&Date.now(),t=o.zlevel===b._zlevelList[0]?b._backgroundColor:null;o.__startIndex!==o.__endIndex&&(s!==o.__startIndex||(n=d[s]).incremental&&n.notClear&&!f)||o.clear(!1,t,a),-1===s&&(console.error("For some unknown reason. drawIndex is -1"),s=o.__startIndex);if(a)if(0===a.length)i=o.__endIndex;else for(var h=b.dpr,c=0;c<a.length;++c){var p=a[c];r.save(),r.beginPath(),r.rect(p.x*h,p.y*h,p.width*h,p.height*h),r.clip(),e(p),r.restore()}else r.save(),e(),r.restore();o.__drawIndex=i,o.__drawIndex<o.__endIndex&&(x=!1)},b=this,i=0;i<m.length;i++)n(i);return w.wxa&&nt(this._layers,function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()}),{finished:x,needsRefreshHover:_}},vb.prototype._doPaintEl=function(t,e,n,i,o,r){e=e.ctx;n?(n=t.getPaintRect(),(!i||n&&n.intersect(i))&&(N0(e,t,o,r),t.setPrevPaintRect(n))):N0(e,t,o,r)},vb.prototype.getLayer=function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=yb);var n=this._layers[t];return n||((n=new gb("zr_"+t,this,this.dpr)).zlevel=t,n.__builtin__=!0,this._layerConfig[t]?d(n,this._layerConfig[t],!0):this._layerConfig[t-.01]&&d(n,this._layerConfig[t-.01],!0),e&&(n.virtual=e),this.insertLayer(t,n),n.initContext()),n},vb.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]&&(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?(n=s.dom).nextSibling?a.insertBefore(e.dom,n.nextSibling):a.appendChild(e.dom):a.firstChild?a.insertBefore(e.dom,a.firstChild):a.appendChild(e.dom)),e.painter||(e.painter=this)}},vb.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)}},vb.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)}},vb.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)}},vb.prototype.getLayers=function(){return this._layers},vb.prototype._updateLayerStatus=function(t){function e(t){o&&(o.__endIndex!==t&&(o.__dirty=!0),o.__endIndex=t)}if(this.eachBuiltinLayer(function(t,e){t.__dirty=t.__used=!1}),this._singleCanvas)for(var n=1;n<t.length;n++)if((s=t[n]).zlevel!==t[n-1].zlevel||s.incremental){this._needsManuallyCompositing=!0;break}for(var i,o=null,r=0,a=0;a<t.length;a++){var s,l=(s=t[a]).zlevel,u=void 0;i!==l&&(i=l,r=0),s.incremental?((u=this.getLayer(l+.001,this._needsManuallyCompositing)).incremental=!0,r=1):u=this.getLayer(l+(0<r?.01:0),this._needsManuallyCompositing),u.__builtin__||rt("ZLevel "+l+" has been used by unkown layer "+u.id),u!==o&&(u.__used=!0,u.__startIndex!==a&&(u.__dirty=!0),u.__startIndex=a,u.incremental?u.__drawIndex=-1:u.__drawIndex=a,e(a),o=u),s.__dirty&In&&!s.__inHover&&(u.__dirty=!0,u.incremental)&&u.__drawIndex<0&&(u.__drawIndex=a)}e(a),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)})},vb.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},vb.prototype._clearLayer=function(t){t.clear()},vb.prototype.setBackgroundColor=function(t){this._backgroundColor=t,nt(this._layers,function(t){t.setUnpainted()})},vb.prototype.configLayer=function(t,e){if(e){var n=this._layerConfig;n[t]?d(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||d(this._layers[o],n[t],!0)}}},vb.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(G(n,t),1))},vb.prototype.resize=function(t,e){if(this._domRoot.style){var n=this._domRoot,i=(n.style.display="none",this._opts),o=this.root;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=d0(o,0,i),e=d0(o,1,i),n.style.display="",this._width!==t||e!==this._height){for(var r in n.style.width=t+"px",n.style.height=e+"px",this._layers)this._layers.hasOwnProperty(r)&&this._layers[r].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(yb).resize(t,e)}return this},vb.prototype.clearLayer=function(t){t=this._layers[t];t&&t.clear()},vb.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},vb.prototype.getRenderedCanvas=function(t){if(this._singleCanvas&&!this._compositeManually)return this._layers[yb].dom;var e=new gb("image",this,(t=t||{}).pixelRatio||this.dpr),n=(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),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];N0(n,u,r,s===l-1)}return e.dom},vb.prototype.getWidth=function(){return this._width},vb.prototype.getHeight=function(){return this._height};var mb=vb;function vb(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=F({},n||{}),this.dpr=n.devicePixelRatio||Ro,this._singleCanvas=o;(this.root=t).style&&(Vt(t),t.innerHTML=""),this.storage=e;var r,a,e=this._zlevelList,s=(this._prevDisplayList=[],this._layers);o?(r=(o=t).width,a=o.height,null!=n.width&&(r=n.width),null!=n.height&&(a=n.height),this.dpr=n.devicePixelRatio||1,o.width=r*this.dpr,o.height=a*this.dpr,this._width=r,this._height=a,(r=new gb(o,this,this.dpr)).__builtin__=!0,r.initContext(),(s[yb]=r).zlevel=yb,e.push(yb),this._domRoot=t):(this._width=d0(t,0,n),this._height=d0(t,1,n),r=this._domRoot=(a=this._width,o=this._height,(s=document.createElement("div")).style.cssText=["position:relative","width:"+a+"px","height:"+o+"px","padding:0","margin:0","border-width:0"].join(";")+";",s),t.appendChild(r))}u(bb,xb=g),bb.prototype.init=function(t,e,n){xb.prototype.init.call(this,t,e,n),this._sourceManager=new yy(this),vy(this)},bb.prototype.mergeOption=function(t,e){xb.prototype.mergeOption.call(this,t,e),vy(this)},bb.prototype.optionUpdated=function(){this._sourceManager.dirty()},bb.prototype.getSourceManager=function(){return this._sourceManager},bb.type="dataset",bb.defaultOption={seriesLayoutBy:Jd};var xb,_b=bb;function bb(){var t=null!==xb&&xb.apply(this,arguments)||this;return t.type="dataset",t}u(Mb,wb=Ky),Mb.type="dataset";var wb,Sb=Mb;function Mb(){var t=null!==wb&&wb.apply(this,arguments)||this;return t.type="dataset",t}function Ib(t){t.registerComponentModel(_b),t.registerComponentView(Sb)}r([function(t){t.registerPainter("canvas",mb)},Ib]),r(cb);var Tb={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},minmax:function(t){for(var e=-1/0,n=-1/0,i=0;i<t.length;i++){var o=t[i],r=Math.abs(o);e<r&&(e=r,n=o)}return isFinite(n)?n:NaN},nearest:function(t){return t[0]}},Cb=function(t){return Math.round(t.length/2)};function Db(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(),i=Math.abs(i[1]-i[0])*(n||1),n=Math.round(s/i),isFinite(n))&&1<n&&("lttb"===r&&t.setData(o.lttbDownSample(o.mapDimension(a.dim),1/n)),s=void 0,H(r)?s=Tb[r]:D(r)&&(s=r),s)&&t.setData(o.downSample(o.mapDimension(a.dim),1/n,s,Cb))}}}u(kb,Ab=Gy),kb.prototype.getInitialData=function(t,e){return V1(null,this,{useEncodeDefaulter:!0})},kb.prototype.getMarkerPosition=function(t,p,e){var d,g,n=this.coordinateSystem;return n&&n.clampData?(d=n.clampData(t),g=n.dataToPoint(d),e?nt(n.getAxes(),function(t,e){if("category"===t.type&&null!=p){var n=t.getTicksCoords(),i=t.getTickModel().get("alignWithLabel"),o=d[e],r="x1"===p[e]||"y1"===p[e];if(r&&!i&&(o+=1),!(n.length<2))if(2===n.length)g[e]=t.toGlobalCoord(t.getExtent()[r?1:0]);else{for(var a=void 0,s=void 0,l=1,u=0;u<n.length;u++){var h=n[u].coord,c=u===n.length-1?n[u-1].tickValue+l:n[u].tickValue;if(c===o){s=h;break}if(c<o)a=h;else if(null!=a&&o<c){s=(h+a)/2;break}1===u&&(l=c-n[0].tickValue)}null==s&&(s=(a?n[n.length-1]:n[0]).coord),g[e]=t.toGlobalCoord(s)}}}):(e=(t=this.getData()).getLayout("offset"),t=t.getLayout("size"),n=n.getBaseAxis().isHorizontal()?0:1,g[n]+=e+t/2),g):[NaN,NaN]},kb.type="series.__base_bar__",kb.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"};var Ab,bp=kb;function kb(){var t=null!==Ab&&Ab.apply(this,arguments)||this;return t.type=kb.type,t}Gy.registerClass(bp);u(Ob,Lb=bp),Ob.prototype.getInitialData=function(){return V1(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},Ob.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},Ob.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return t=t<e?e:t},Ob.prototype.brushSelector=function(t,e,n){return n.rect(e.getItemLayout(t))},Ob.type="series.bar",Ob.dependencies=["grid","polar"],Ob.defaultOption=Np(bp.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});var Lb,Pb=Ob;function Ob(){var t=null!==Lb&&Lb.apply(this,arguments)||this;return t.type=Ob.type,t}function Nb(t,e,n,i,o){var r=t.getArea(),a=r.x,s=r.y,l=r.width,r=r.height,u=n.get(["lineStyle","width"])||2,h=(a-=u/2,s-=u/2,l+=u,r+=u,l=Math.ceil(l),a!==Math.floor(a)&&(a=Math.floor(a),l++),new L({shape:{x:a,y:s,width:l,height:r}}));return e&&(e=(u=t.getBaseAxis()).isHorizontal(),t=u.inverse,e?(t&&(h.shape.x+=l),h.shape.width=0):(t||(h.shape.y+=r),h.shape.height=0),u=D(o)?function(t){o(t,h)}:null,_c(h,{shape:{width:l,height:r,x:a,y:s}},n,null,i,u)),h}function Rb(t,e,n){var i=t.getArea(),o=Dr(i.r0,1),r=Dr(i.r,1),a=new wh({shape:{cx:Dr(t.cx,1),cy:Dr(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,_c(a,{shape:{endAngle:i.endAngle,r:r}},n)),a}function Eb(t,e,n,i,o){return t?"polar"===t.type?Rb(t,e,n):"cartesian2d"===t.type?Nb(t,e,n,i,o):null:null}var zb,Vb=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},Bb=(u(Fb,zb=q),Fb.prototype.getDefaultShape=function(){return new Vb},Fb.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,e=e.clockwise,h=2*Math.PI,c=e?u-l<h:l-u<h,h=(c||(l=u-(e?h:-h)),Math.cos(l)),p=Math.sin(l),d=Math.cos(u),g=Math.sin(u);c?(t.moveTo(h*o+n,p*o+i),t.arc(h*s+n,p*s+i,a,-Math.PI+l,l,!e)):t.moveTo(h*r+n,p*r+i),t.arc(n,i,r,l,u,!e),t.arc(d*s+n,g*s+i,a,u-2*Math.PI,u-Math.PI,!e),0!==o&&t.arc(n,i,o,u,l,e)},Fb);function Fb(t){t=zb.call(this,t)||this;return t.type="sausage",t}function Gb(t,e){return t.type===e}function Wb(t,e){var n,i=t.mapDimensionsAll("defaultedLabel"),o=i.length;if(1===o)return null!=(n=Mf(t,e,i[0]))?n+"":null;if(o){for(var r=[],a=0;a<i.length;a++)r.push(Mf(t,e,i[a]));return r.join(" ")}}function Hb(t,e){var n=t.mapDimensionsAll("defaultedLabel");if(!B(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 Yb(t,e,n){return e*Math.sin(t)*(n?-1:1)}function Xb(t,e,n){return e*Math.cos(t)*(n?1:-1)}function Ub(t,e,n){t=t.get("borderRadius");if(null==t)return n?{cornerRadius:0}:null;B(t)||(t=[t,t,t,t]);var i=Math.abs(e.r||0-e.r0||0);return{cornerRadius:V(t,function(t){return er(t,i)})}}var Zb=Math.max,jb=Math.min;u($b,qb=em),$b.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._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n,i))},$b.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},$b.prototype.incrementalRender=function(t,e){this._progressiveEls=[],this._incrementalRenderLarge(t,e)},$b.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},$b.prototype._updateDrawMode=function(t){t=t.pipelineContext.large;null!=this._isLargeDraw&&t===this._isLargeDraw||(this._isLargeDraw=t,this._clear())},$b.prototype._renderNormal=function(a,t,e,n){var s,i,o,l=this.group,u=a.getData(),h=this._data,c=a.coordinateSystem,p=c.getBaseAxis(),d=("cartesian2d"===c.type?s=p.isHorizontal():"polar"===c.type&&(s="angle"===p.dim),a.isAnimationEnabled()?a:null),g=function(t,e){var t=t.get("realtimeSort",!0),n=e.getBaseAxis();if(t&&"category"===n.type&&"cartesian2d"===e.type)return{baseAxis:n,otherAxis:e.getOtherAxis(n)}}(a,c),f=(g&&this._enableRealtimeSort(g,u,e),a.get("clip",!0)||g),y=(e=u,o=(i=c).getArea&&i.getArea(),!Gb(i,"cartesian2d")||"category"===(i=i.getBaseAxis()).type&&i.onBand||(e=e.getLayout("bandWidth"),i.isHorizontal()?(o.x-=e,o.width+=2*e):(o.y-=e,o.height+=2*e)),o),m=(l.removeClipPath(),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=rw[c.type](u,t),n=(n=s,new("polar"===c.type?wh:L)({shape:gw(n,e,c),silent:!0,z2:0}));return n.useStyle(x.getItemStyle()),"cartesian2d"===c.type?n.setShape("r",_):n.setShape("cornerRadius",_),b[t]=n}u.diff(h).add(function(t){var e,n,i=u.getItemModel(t),o=rw[c.type](u,t,i);v&&I(t),u.hasValue(t)&&ow[c.type](o)&&(e=!1,f&&(e=Jb[c.type](y,o)),n=Qb[c.type](a,u,t,o,s,d,p.model,!1,m),g&&(n.forceLabelAnimation=!0),sw(n,u,t,i,o,a,s,"polar"===c.type),S?n.attr({shape:o}):g?tw(g,d,n,o,t,s,!1,!1):_c(n,{shape:o},a,t),u.setItemGraphicEl(t,n),l.add(n),n.ignore=e)}).update(function(t,e){var n,i=u.getItemModel(t),o=rw[c.type](u,t,i),r=(v&&(r=void 0,0===w.length?r=I(e):((r=w[e]).useStyle(x.getItemStyle()),"cartesian2d"===c.type?r.setShape("r",_):r.setShape("cornerRadius",_),b[t]=r),n=rw[c.type](u,t),C(r,{shape:gw(s,n,c)},d,t)),h.getItemGraphicEl(e));u.hasValue(t)&&ow[c.type](o)?(n=!1,f&&(n=Jb[c.type](y,o))&&l.remove(r),r?Ic(r):r=Qb[c.type](a,u,t,o,s,d,p.model,!!r,m),g&&(r.forceLabelAnimation=!0),M?(e=r.getTextContent())&&null!=(e=dp(e)).prevValue&&(e.prevValue=e.value):sw(r,u,t,i,o,a,s,"polar"===c.type),S?r.attr({shape:o}):g?tw(g,d,r,o,t,s,!0,M):C(r,{shape:o},a,t,null),u.setItemGraphicEl(t,r),r.ignore=n,l.add(r)):l.remove(r)}).remove(function(t){var e=h.getItemGraphicEl(t);e&&Mc(e,a,t)}).execute();var r=this._backgroundGroup||(this._backgroundGroup=new Z);r.removeAll();for(var T=0;T<b.length;++T)r.add(b[T]);l.add(r),this._backgroundEls=b,this._data=u},$b.prototype._renderLarge=function(t,e,n){this._clear(),pw(t,this.group),this._updateLargeClip(t)},$b.prototype._incrementalRenderLarge=function(t,e){this._removeBackground(),pw(e,this.group,this._progressiveEls,!0)},$b.prototype._updateLargeClip=function(t){var t=t.get("clip",!0)&&Eb(t.coordinateSystem,!1,t),e=this.group;t?e.setClipPath(t):e.removeClipPath()},$b.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),t=t&&t.shape;return t&&Math.abs(i.isHorizontal()?t.height:t.width)||0},this._onRendered=function(){r._updateSortWithinSameData(e,o,i,n)},n.getZr().on("rendered",this._onRendered)))},$b.prototype._dataSort=function(t,e,i){var o=[];return t.each(t.mapDimension(e.dim),function(t,e){var n=i(e);o.push({dataIndex:e,mappedValue:null==n?NaN:n,ordinalNumber:t})}),o.sort(function(t,e){return e.mappedValue-t.mappedValue}),{ordinalNumbers:V(o,function(t){return t.ordinalNumber})}},$b.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},$b.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},$b.prototype._updateSortWithinSameData=function(t,e,n,i){this._isOrderChangedWithinSameData(t,e,n)&&(t=this._dataSort(t,n,e),this._isOrderDifferentInView(t,n))&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:t}))},$b.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})},$b.prototype.remove=function(t,e){this._clear(this._model),this._removeOnRenderedListener(e)},$b.prototype.dispose=function(t,e){this._removeOnRenderedListener(e)},$b.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},$b.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){Mc(t,e,$(t).dataIndex)})):t.removeAll(),this._data=null,this._isFirstFrame=!0},$b.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},$b.type="bar";var qb,Kb=$b;function $b(){var t=qb.call(this)||this;return t.type=$b.type,t._isFirstFrame=!0,t}var Jb={cartesian2d:function(t,e){var n=e.width<0?-1:1,i=e.height<0?-1:1,o=(n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),t.x+t.width),r=t.y+t.height,a=Zb(e.x,t.x),s=jb(e.x+e.width,o),t=Zb(e.y,t.y),l=jb(e.y+e.height,r),u=s<a,h=l<t;return e.x=u&&o<a?s:a,e.y=h&&r<t?l:t,e.width=u?0:s-a,e.height=h?0:l-t,n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),u||h},polar:function(t,e){var n,i=e.r0<=e.r?1:-1,o=(i<0&&(n=e.r,e.r=e.r0,e.r0=n),jb(e.r,t.r)),t=Zb(e.r0,t.r0),o=(e.r=o)-(e.r0=t)<0;return i<0&&(n=e.r,e.r=e.r0,e.r0=n),o}},Qb={cartesian2d:function(t,e,n,i,o,r,a,s,l){i=new L({shape:F({},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 b,w,l=!o&&l?Bb:wh,u=new l({shape:i,z2:1}),h=(u.name="item",aw(o));return u.calculateTextPosition=(b=h,w=({isRoundCap:l===Bb}||{}).isRoundCap,function(t,e,n){var i=e.position;if(!i||i instanceof Array)return nr(t,e,n);var i=b(i),o=null!=e.distance?e.distance:5,r=this.shape,a=r.cx,s=r.cy,l=r.r,u=r.r0,h=(l+u)/2,c=r.startAngle,p=r.endAngle,d=(c+p)/2,g=w?Math.abs(l-u)/2:0,f=Math.cos,y=Math.sin,m=a+l*f(c),v=s+l*y(c),x="left",_="top";switch(i){case"startArc":m=a+(u-o)*f(d),v=s+(u-o)*y(d),x="center",_="top";break;case"insideStartArc":m=a+(u+o)*f(d),v=s+(u+o)*y(d),x="center",_="bottom";break;case"startAngle":m=a+h*f(c)+Yb(c,o+g,!1),v=s+h*y(c)+Xb(c,o+g,!1),x="right",_="middle";break;case"insideStartAngle":m=a+h*f(c)+Yb(c,g-o,!1),v=s+h*y(c)+Xb(c,g-o,!1),x="left",_="middle";break;case"middle":m=a+h*f(d),v=s+h*y(d),x="center",_="middle";break;case"endArc":m=a+(l+o)*f(d),v=s+(l+o)*y(d),x="center",_="bottom";break;case"insideEndArc":m=a+(l-o)*f(d),v=s+(l-o)*y(d),x="center",_="top";break;case"endAngle":m=a+h*f(p)+Yb(p,o+g,!0),v=s+h*y(p)+Xb(p,o+g,!0),x="left",_="middle";break;case"insideEndAngle":m=a+h*f(p)+Yb(p,g-o,!0),v=s+h*y(p)+Xb(p,g-o,!0),x="right",_="middle";break;default:return nr(t,e,n)}return(t=t||{}).x=m,t.y=v,t.align=x,t.verticalAlign=_,t}),r&&(h={},u.shape[l=o?"r":"endAngle"]=o?i.r0:i.startAngle,h[l]=i[l],(s?C:_c)(u,{shape:h},r)),u}};function tw(t,e,n,i,o,r,a,s){var l,r=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?C:_c)(n,{shape:r},e,o,null),(a?C:_c)(n,{shape:l},e?t.baseAxis.model:null,o)}function ew(t,e){for(var n=0;n<e.length;n++)if(!isFinite(t[e[n]]))return 1}var nw=["x","y","width","height"],iw=["cx","cy","r","startAngle","endAngle"],ow={cartesian2d:function(t){return!ew(t,nw)},polar:function(t){return!ew(t,iw)}},rw={cartesian2d:function(t,e,n){var t=t.getItemLayout(e),i=n&&(e=t,i=(n=n).get(["itemStyle","borderColor"]))&&"none"!==i?(i=n.get(["itemStyle","borderWidth"])||0,n=isNaN(e.width)?Number.MAX_VALUE:Math.abs(e.width),e=isNaN(e.height)?Number.MAX_VALUE:Math.abs(e.height),Math.min(i,n,e)):0,n=0<t.width?1:-1,e=0<t.height?1:-1;return{x:t.x+n*i/2,y:t.y+e*i/2,width:t.width-n*i,height:t.height-e*i}},polar:function(t,e,n){t=t.getItemLayout(e);return{cx:t.cx,cy:t.cy,r0:t.r0,r:t.r,startAngle:t.startAngle,endAngle:t.endAngle,clockwise:t.clockwise}}};function aw(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 sw(t,e,n,i,o,r,a,s){var l=e.getItemVisual(n,"style"),u=(s?r.get("roundCap")||(F(u=t.shape,Ub(i.getModel("itemStyle"),u,!0)),t.setShape(u)):(u=i.get(["itemStyle","borderRadius"])||0,t.setShape("r",u)),t.useStyle(l),i.getShallow("cursor")),u=(u&&t.attr("cursor",u),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"),h=rp(i),l=(op(t,h,{labelFetcher:r,labelDataIndex:n,defaultText:Wb(r.getData(),n),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:u}),t.getTextContent()),u=(s&&l&&(s=i.get(["label","position"]),t.textConfig.inside="middle"===s||null,function(t,e,n,i){if(Y(i))t.setTextConfig({rotation:i});else if(B(e))t.setTextConfig({rotation:0});else{var o,i=t.shape,r=i.clockwise?i.startAngle:i.endAngle,a=i.clockwise?i.endAngle:i.startAngle,s=(r+a)/2,i=n(e);switch(i){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":o=s;break;case"startAngle":case"insideStartAngle":o=r;break;case"endAngle":case"insideEndAngle":o=a;break;default:return t.setTextConfig({rotation:0})}n=1.5*Math.PI-o;"middle"===i&&n>Math.PI/2&&n<1.5*Math.PI&&(n-=Math.PI),t.setTextConfig({rotation:n})}}(t,"outside"===s?u:s,aw(a),i.get(["label","rotate"]))),gp(l,h,r.getRawValue(n),function(t){return Hb(e,t)}),i.getModel(["emphasis"]));Mu(t,u.get("focus"),u.get("blurScope"),u.get("disabled")),Du(t,i),null!=(s=o).startAngle&&null!=s.endAngle&&s.startAngle===s.endAngle&&(t.style.fill="none",t.style.stroke="none",nt(t.states,function(t){t.style&&(t.style.fill=t.style.stroke="none")}))}var lw,uw=function(){},hw=(u(cw,lw=q),cw.prototype.getDefaultShape=function(){return new uw},cw.prototype.buildPath=function(t,e){for(var n=e.points,i=this.baseDimIdx,o=1-this.baseDimIdx,r=[],a=[],s=this.barWidth,l=0;l<n.length;l+=3)a[i]=s,a[o]=n[l+2],r[i]=n[l+i],r[o]=n[l+o],t.rect(r[0],r[1],a[0],a[1])},cw);function cw(t){t=lw.call(this,t)||this;return t.type="largeBar",t}function pw(t,e,n,i){var o=t.getData(),r=o.getLayout("valueAxisHorizontal")?1:0,a=o.getLayout("largeDataIndices"),s=o.getLayout("size"),l=t.getModel("backgroundStyle"),u=o.getLayout("largeBackgroundPoints"),l=(u&&((u=new hw({shape:{points:u},incremental:!!i,silent:!0,z2:0})).baseDimIdx=r,u.largeDataIndices=a,u.barWidth=s,u.useStyle(l.getItemStyle()),e.add(u),n)&&n.push(u),new hw({shape:{points:o.getLayout("largePoints")},incremental:!!i,ignoreCoarsePointer:!0,z2:1}));l.baseDimIdx=r,l.largeDataIndices=a,l.barWidth=s,e.add(l),l.useStyle(o.getVisual("style")),$(l).seriesIndex=t.seriesIndex,t.get("silent")||(l.on("mousedown",dw),l.on("mousemove",dw)),n&&n.push(l)}var dw=cm(function(t){t=function(t,e,n){for(var i=t.baseDimIdx,o=1-i,r=t.shape.points,a=t.largeDataIndices,s=[],l=[],u=t.barWidth,h=0,c=r.length/3;h<c;h++){var p=3*h;if(l[i]=u,l[o]=r[2+p],s[i]=r[p+i],s[o]=r[p+o],l[o]<0&&(s[o]+=l[o],l[o]=-l[o]),s[0]<=e&&e<=s[0]+l[0]&&s[1]<=n&&n<=s[1]+l[1])return a[h]}return-1}(this,t.offsetX,t.offsetY);$(this).dataIndex=0<=t?t:null},30,!1);function gw(t,e,n){var i,o;return Gb(n,"cartesian2d")?(i=e,o=n.getArea(),{x:(t?i:o).x,y:(t?o:i).y,width:(t?i:o).width,height:(t?o:i).height}):{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}}r(function(t){t.registerChartView(Kb),t.registerSeriesModel(Pb),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,P(fx,"bar")),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yx("bar")),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,Db("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)})})});u(mw,fw=Gy),mw.prototype.getInitialData=function(t){return V1(null,this,{useEncodeDefaulter:!0})},mw.prototype.getLegendIcon=function(t){var e=new Z,n=s0("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1),n=(e.add(n),n.setStyle(t.lineStyle),this.getData().getVisual("symbol")),i=this.getData().getVisual("symbolRotate"),n="none"===n?"circle":n,o=.8*t.itemHeight,o=s0(n,(t.itemWidth-o)/2,(t.itemHeight-o)/2,o,o,t.itemStyle.fill),i=(e.add(o),o.setStyle(t.itemStyle),"inherit"===t.iconRotate?i:t.iconRotate||0);return o.rotation=i*Math.PI/180,o.setOrigin([t.itemWidth/2,t.itemHeight/2]),-1<n.indexOf("empty")&&(o.style.stroke=o.style.fill,o.style.fill="#fff",o.style.lineWidth=2),e},mw.type="series.line",mw.dependencies=["grid","polar"],mw.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1};var fw,yw=mw;function mw(){var t=null!==fw&&fw.apply(this,arguments)||this;return t.type=mw.type,t.hasSymbolVisual=!0,t}u(_w,vw=Z),_w.prototype._createSymbol=function(t,e,n,i,o){this.removeAll();o=s0(t,-1,-1,2,2,null,o);o.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),o.drift=bw,this._symbolType=t,this.add(o)},_w.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},_w.prototype.getSymbolType=function(){return this._symbolType},_w.prototype.getSymbolPath=function(){return this.childAt(0)},_w.prototype.highlight=function(){cu(this.childAt(0))},_w.prototype.downplay=function(){pu(this.childAt(0))},_w.prototype.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},_w.prototype.setDraggable=function(t,e){var n=this.childAt(0);n.draggable=t,n.cursor=!e&&t?"move":n.cursor},_w.prototype.updateData=function(t,e,n,i){this.silent=!1;var o,r,a,s=t.getItemVisual(e,"symbol")||"circle",l=t.hostModel,u=_w.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):C(r,a,l,e),Ic(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,_c(r,a,l,e))),c&&this.childAt(0).stopAnimation("leave")},_w.prototype._updateCommon=function(e,t,n,i,o){var r,a,s,l,u,h,c,p,d=this.childAt(0),g=e.hostModel,f=(i&&(r=i.emphasisItemStyle,s=i.blurItemStyle,a=i.selectItemStyle,l=i.focus,u=i.blurScope,c=i.labelStatesModels,p=i.hoverScale,y=i.cursorStyle,h=i.emphasisDisabled),i&&!e.hasItemOption||(r=(f=(i=i&&i.itemModel?i.itemModel:e.getItemModel(t)).getModel("emphasis")).getModel("itemStyle").getItemStyle(),a=i.getModel(["select","itemStyle"]).getItemStyle(),s=i.getModel(["blur","itemStyle"]).getItemStyle(),l=f.get("focus"),u=f.get("blurScope"),h=f.get("disabled"),c=rp(i),p=f.getShallow("scale"),y=i.getShallow("cursor")),e.getItemVisual(t,"symbolRotate")),i=(d.attr("rotation",(f||0)*Math.PI/180||0),u0(e.getItemVisual(t,"symbolOffset"),n)),f=(i&&(d.x=i[0],d.y=i[1]),y&&d.attr("cursor",y),e.getItemVisual(t,"style")),i=f.fill,y=(d instanceof ll?(y=d.style,d.useStyle(F({image:y.image,x:y.x,y:y.y,width:y.width,height:y.height},f))):(d.__isEmptyBrush?d.useStyle(F({},f)):d.useStyle(f),d.style.decal=null,d.setColor(i,o&&o.symbolInnerColor),d.style.strokeNoScale=!0),e.getItemVisual(t,"liftZ")),m=this._z2,v=(null!=y?null==m&&(this._z2=d.z2,d.z2+=y):null!=m&&(d.z2=m,this._z2=null),o&&o.useNameLabel);op(d,c,{labelFetcher:g,labelDataIndex:t,defaultText:function(t){return v?e.getName(t):Wb(e,t)},inheritColor:i,defaultOpacity:f.opacity}),this._sizeX=n[0]/2,this._sizeY=n[1]/2;y=d.ensureState("emphasis"),y.style=r,d.ensureState("select").style=a,d.ensureState("blur").style=s,m=null==p||!0===p?Math.max(1.1,3/this._sizeY):isFinite(p)&&0<p?+p:1;y.scaleX=this._sizeX*m,y.scaleY=this._sizeY*m,this.setSymbolScale(1),Mu(this,l,u,h)},_w.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},_w.prototype.fadeOut=function(t,e,n){var i=this.childAt(0),o=$(this).dataIndex,r=n&&n.animation;this.silent=i.silent=!0,n&&n.fadeLabel?(n=i.getTextContent())&&wc(n,{style:{opacity:0}},e,{dataIndex:o,removeOpt:r,cb:function(){i.removeTextContent()}}):i.removeTextContent(),wc(i,{style:{opacity:0},scaleX:0,scaleY:0},e,{dataIndex:o,cb:t,removeOpt:r})},_w.getSymbolSize=function(t,e){return l0(t.getItemVisual(e,"symbolSize"))};var vw,xw=_w;function _w(t,e,n,i){var o=vw.call(this)||this;return o.updateData(t,e,n,i),o}function bw(t,e){this.parent.drift(t,e)}function ww(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 Sw(t){return(t=null==t||O(t)?t:{isIgnore:t})||{}}function Mw(t){var t=t.hostModel,e=t.getModel("emphasis");return{emphasisItemStyle:e.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:e.get("focus"),blurScope:e.get("blurScope"),emphasisDisabled:e.get("disabled"),hoverScale:e.get("scale"),labelStatesModels:rp(t),cursorStyle:t.get("cursor")}}Tw.prototype.updateData=function(r,a){this._progressiveEls=null,a=Sw(a);var s=this.group,l=r.hostModel,u=this._data,h=this._SymbolCtor,c=a.disableAnimation,p=Mw(r),d={disableAnimation:c},g=a.getSymbolPoint||function(t){return r.getItemLayout(t)};u||s.removeAll(),r.diff(u).add(function(t){var e,n=g(t);ww(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,e=u.getItemGraphicEl(e),o=g(t);ww(r,o,t,a)?(n=r.getItemVisual(t,"symbol")||"circle",i=e&&e.getSymbolType&&e.getSymbolType(),!e||i&&i!==n?(s.remove(e),(e=new h(r,t,p,d)).setPosition(o)):(e.updateData(r,t,p,d),i={x:o[0],y:o[1]},c?e.attr(i):C(e,i,l)),s.add(e),r.setItemGraphicEl(t,e)):s.remove(e)}).remove(function(t){var e=u.getItemGraphicEl(t);e&&e.fadeOut(function(){s.remove(e)},l)}).execute(),this._getSymbolPoint=g,this._data=r},Tw.prototype.updateLayout=function(){var n=this,t=this._data;t&&t.eachItemGraphicEl(function(t,e){e=n._getSymbolPoint(e);t.setPosition(e),t.markRedraw()})},Tw.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Mw(t),this._data=null,this.group.removeAll()},Tw.prototype.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[],n=Sw(n);for(var o=t.start;o<t.end;o++){var r,a=e.getItemLayout(o);ww(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),this._progressiveEls.push(r))}},Tw.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},Tw.prototype.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)},n.hostModel)}):e.removeAll()};var Iw=Tw;function Tw(t){this.group=new Z,this._SymbolCtor=t||xw}function Cw(t,e,n){var i=t.getBaseAxis(),o=t.getOtherAxis(i),n=function(t,e){var n=0,t=t.scale.getExtent();"start"===e?n=t[0]:"end"===e?n=t[1]:Y(e)&&!isNaN(e)?n=e:0<t[0]?n=t[0]:t[1]<0&&(n=t[1]);return n}(o,n),i=i.dim,o=o.dim,r=e.mapDimension(o),a=e.mapDimension(i),s="x"===o||"radius"===o?1:0,t=V(t.dimensions,function(t){return e.mapDimension(t)}),l=!1,u=e.getCalculationInfo("stackResultDimension");return E1(e,t[0])&&(l=!0,t[0]=u),E1(e,t[1])&&(l=!0,t[1]=u),{dataDimsForPoint:t,valueStart:n,valueAxisDim:o,baseAxisDim:i,stacked:!!l,valueDim:r,baseDim:a,baseDataOffset:s,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function Dw(t,e,n,i){var o=NaN,r=(t.stacked&&(o=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(o)&&(o=t.valueStart),t.baseDataOffset),a=[];return a[r]=n.get(t.baseDim,i),a[1-r]=o,e.dataToPoint(a)}var Aw=Math.min,kw=Math.max;function Lw(t,e){return isNaN(t)||isNaN(e)}function Pw(t,e,n,i,o,r,a,s,l){for(var u,h,c,p,d=n,g=0;g<i;g++){var f=e[2*d],y=e[2*d+1];if(o<=d||d<0)break;if(Lw(f,y)){if(l){d+=r;continue}break}if(d===n)t[0<r?"moveTo":"lineTo"](f,y),c=f,p=y;else{var m=f-u,v=y-h;if(m*m+v*v<.5){d+=r;continue}if(0<a){for(var x=d+r,_=e[2*x],b=e[2*x+1];_===f&&b===y&&g<i;)g++,d+=r,_=e[2*(x+=r)],b=e[2*x+1],f=e[2*d],y=e[2*d+1];var w=g+1;if(l)for(;Lw(_,b)&&w<i;)w++,_=e[2*(x+=r)],b=e[2*x+1];var S,M,I,T,C,D,A,k,L,m=0,v=0,P=void 0,O=void 0;i<=w||Lw(_,b)?(A=f,k=y):(m=_-u,v=b-h,S=f-u,M=_-f,I=y-h,T=b-y,D=C=void 0,O="x"===s?(A=f-(L=0<m?1:-1)*(C=Math.abs(S))*a,k=y,P=f+L*(D=Math.abs(M))*a,y):"y"===s?(k=y-(L=0<v?1:-1)*(C=Math.abs(I))*a,P=A=f,y+L*(D=Math.abs(T))*a):(C=Math.sqrt(S*S+I*I),A=f-m*a*(1-(S=(D=Math.sqrt(M*M+T*T))/(D+C))),k=y-v*a*(1-S),O=y+v*a*S,P=Aw(P=f+m*a*S,kw(_,f)),O=Aw(O,kw(b,y)),P=kw(P,Aw(_,f)),k=y-(v=(O=kw(O,Aw(b,y)))-y)*C/D,A=Aw(A=f-(m=P-f)*C/D,kw(u,f)),k=Aw(k,kw(h,y)),P=f+(m=f-(A=kw(A,Aw(u,f))))*D/C,y+(v=y-(k=kw(k,Aw(h,y))))*D/C)),t.bezierCurveTo(c,p,A,k,f,y),c=P,p=O}else t.lineTo(f,y)}u=f,h=y,d+=r}return g}var Ow,Nw=function(){this.smooth=0,this.smoothConstraint=!0},Rw=(u(Ew,Ow=q),Ew.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Ew.prototype.getDefaultShape=function(){return new Nw},Ew.prototype.buildPath=function(t,e){var n=e.points,i=0,o=n.length/2;if(e.connectNulls){for(;0<o&&Lw(n[2*o-2],n[2*o-1]);o--);for(;i<o&&Lw(n[2*i],n[2*i+1]);i++);}for(;i<o;)i+=Pw(t,n,i,o,o,1,e.smooth,e.smoothMonotone,e.connectNulls)+1},Ew.prototype.getPointOn=function(t,e){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n,i,o=this.path.data,r=Ns.CMD,a="x"===e,s=[],l=0;l<o.length;){var u=void 0,h=void 0;switch(o[l++]){case r.M:n=o[l++],i=o[l++];break;case r.L:var c,u=o[l++],h=o[l++];if((c=a?(t-n)/(u-n):(t-i)/(h-i))<=1&&0<=c)return v=a?(h-i)*c+i:(u-n)*c+n,a?[t,v]:[v,t];n=u,i=h;break;case r.C:u=o[l++],h=o[l++];var p=o[l++],d=o[l++],g=o[l++],f=o[l++],y=a?Zn(n,u,p,g,t,s):Zn(i,h,d,f,t,s);if(0<y)for(var m=0;m<y;m++){var v,x=s[m];if(x<=1&&0<=x)return v=a?Xn(i,h,d,f,x):Xn(n,u,p,g,x),a?[t,v]:[v,t]}n=g,i=f}}},Ew);function Ew(t){t=Ow.call(this,t)||this;return t.type="ec-polyline",t}u(Bw,zw=Nw);var zw,Vw=Bw;function Bw(){return null!==zw&&zw.apply(this,arguments)||this}u(Ww,Fw=q),Ww.prototype.getDefaultShape=function(){return new Vw},Ww.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&&Lw(n[2*r-2],n[2*r-1]);r--);for(;o<r&&Lw(n[2*o],n[2*o+1]);o++);}for(;o<r;){var s=Pw(t,n,o,r,r,1,e.smooth,a,e.connectNulls);Pw(t,i,o+s-1,s,r,-1,e.stackedOnSmooth,a,e.connectNulls),o+=s+1,t.closePath()}};var Fw,Gw=Ww;function Ww(t){t=Fw.call(this,t)||this;return t.type="ec-polygon",t}function Hw(t,e){if(t.length===e.length){for(var n=0;n<t.length;n++)if(t[n]!==e[n])return;return 1}}function Yw(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 Xw(t,e){var t=Yw(t),n=t[0],t=t[1],e=Yw(e),i=e[0],e=e[1];return Math.max(Math.abs(n[0]-i[0]),Math.abs(n[1]-i[1]),Math.abs(t[0]-e[0]),Math.abs(t[1]-e[1]))}function Uw(t){return Y(t)?t:t?.5:0}function Zw(t,e,n,i){var e=e.getBaseAxis(),o="x"===e.dim||"radius"===e.dim?0:1,r=[],a=0,s=[],l=[],u=[],h=[];if(i){for(a=0;a<t.length;a+=2)isNaN(t[a])||isNaN(t[a+1])||h.push(t[a],t[a+1]);t=h}for(a=0;a<t.length-2;a+=2)switch(u[0]=t[a+2],u[1]=t[a+3],l[0]=t[a],l[1]=t[a+1],r.push(l[0],l[1]),n){case"end":s[o]=u[o],s[1-o]=l[1-o],r.push(s[0],s[1]);break;case"middle":var c=[];s[o]=c[o]=(l[o]+u[o])/2,s[1-o]=l[1-o],c[1-o]=u[1-o],r.push(s[0],s[1]),r.push(c[0],c[1]);break;default:s[o]=l[o],s[1-o]=u[1-o],r.push(s[0],s[1])}return r.push(t[a++],t[a++]),r}function jw(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),e=V(o.stops,function(t){return{coord:l.toGlobalCoord(l.dataToCoord(t.value)),color:t.color}}),u=e.length,h=o.outerColors.slice(),n=(u&&e[0].coord>e[u-1].coord&&(e.reverse(),h.reverse()),function(t,e){var n,i,o=[],r=t.length;function a(t,e,n){var i=t.coord;return{coord:n,color:Di((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}(e,"x"===a?n.getWidth():n.getHeight())),c=n.length;if(!c&&u)return e[0].coord<0?h[1]||e[u-1].color:h[0]||e[0].color;var p=n[0].coord-10,u=n[c-1].coord+10,d=u-p;if(d<.001)return"transparent";nt(n,function(t){t.offset=(t.coord-p)/d}),n.push({offset:c?n[c-1].offset:.5,color:h[1]||"transparent"}),n.unshift({offset:c?n[0].offset:.5,color:h[0]||"transparent"});e=new ic(0,0,0,0,n,!0);return e[a]=p,e[a+"2"]=u,e}}}function qw(t,e,n){var t=t.get("showAllSymbol"),i="auto"===t;if(!t||i){var o,r,a=n.getAxesByScale("ordinal")[0];if(a)if(!i||!function(t,e){for(var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count(),o=(isNaN(i)&&(i=0),e.count()),r=Math.max(1,Math.round(o/5)),a=0;a<o;a+=r)if(1.5*xw.getSymbolSize(e,a)[t.isHorizontal()?1:0]>i)return;return 1}(a,e))return o=e.mapDimension(a.dim),r={},nt(a.getViewLabels(),function(t){t=a.scale.getRawOrdinalNumber(t.tickValue);r[t]=1}),function(t){return!r.hasOwnProperty(e.get(o,t))}}}function Kw(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 $w(t,e){return[t[2*e],t[2*e+1]]}function Jw(t){if(t.get(["endLabel","show"]))return 1;for(var e=0;e<Wl.length;e++)if(t.get([Wl[e],"endLabel","show"]))return 1}function Qw(n,i,e,t){var o,r,a,s,l,u,h,c,p;return Gb(i,"cartesian2d")?(o=t.getModel("endLabel"),r=o.get("valueAnimation"),a=t.getData(),s={lastFrameIndex:0},l=Jw(t)?function(t,e){n._endLabelOnDuring(t,e,a,s,r,o,i)}:null,u=i.getBaseAxis().isHorizontal(),h=Nb(i,e,t,function(){var t=n._endLabel;t&&e&&null!=s.originalX&&t.attr({x:s.originalX,y:s.originalY})},l),t.get("clip",!0)||(c=h.shape,p=Math.max(c.width,c.height),u?(c.y-=p,c.height+=2*p):(c.x-=p,c.width+=2*p)),l&&l(1,h),h):Rb(i,e,t)}u(nS,tS=em),nS.prototype.init=function(){var t=new Z,e=new Iw;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},nS.prototype.render=function(t,e,n){function i(t){r._changePolyState(t)}var o,r=this,a=t.coordinateSystem,s=this.group,l=t.getData(),u=t.getModel("lineStyle"),h=t.getModel("areaStyle"),c=l.getLayout("points")||[],p="polar"===a.type,d=this._coordSys,g=this._symbolDraw,f=this._polyline,y=this._polygon,m=this._lineGroup,e=!e.ssr&&t.get("animation"),v=!h.isEmpty(),x=h.get("origin"),_=Cw(a,l,x),_=v&&function(t,e,n){if(!n.valueDim)return[];for(var i=e.count(),o=lx(2*i),r=0;r<i;r++){var a=Dw(n,t,e,r);o[2*r]=a[0],o[2*r+1]=a[1]}return o}(a,l,_),b=t.get("showSymbol"),w=t.get("connectNulls"),S=b&&!p&&qw(t,l,a),M=this._data,I=(M&&M.eachItemGraphicEl(function(t,e){t.__temp&&(s.remove(t),M.setItemGraphicEl(e,null))}),b||g.remove(),s.add(m),!p&&t.get("step")),T=(a&&a.getArea&&t.get("clip",!0)&&(null!=(o=a.getArea()).width?(o.x-=.1,o.y-=.1,o.width+=.2,o.height+=.2):o.r0&&(o.r0-=.5,o.r+=.5)),this._clipShapeForSymbol=o,jw(l,a,n)||l.getVisual("style")[l.getVisual("drawType")]),d=(f&&d.type===a.type&&I===this._step?(v&&!y?y=this._newPolygon(c,_):y&&!v&&(m.remove(y),y=this._polygon=null),p||this._initOrUpdateEndLabel(t,a,Md(T)),(d=m.getClipPath())?_c(d,{shape:Qw(this,a,!1,t).shape},t):m.setClipPath(Qw(this,a,!0,t)),b&&g.updateData(l,{isIgnore:S,clipShape:o,disableAnimation:!0,getSymbolPoint:function(t){return[c[2*t],c[2*t+1]]}}),Hw(this._stackedOnPoints,_)&&Hw(this._points,c)||(e?this._doUpdateAnimation(l,_,a,n,I,x,w):(I&&(c=Zw(c,a,I,w),_=_&&Zw(_,a,I,w)),f.setShape({points:c}),y&&y.setShape({points:c,stackedOnPoints:_})))):(b&&g.updateData(l,{isIgnore:S,clipShape:o,disableAnimation:!0,getSymbolPoint:function(t){return[c[2*t],c[2*t+1]]}}),e&&this._initSymbolLabelAnimation(l,a,o),I&&(c=Zw(c,a,I,w),_=_&&Zw(_,a,I,w)),f=this._newPolyline(c),v?y=this._newPolygon(c,_):y&&(m.remove(y),y=this._polygon=null),p||this._initOrUpdateEndLabel(t,a,Md(T)),m.setClipPath(Qw(this,a,!0,t))),t.getModel("emphasis")),n=d.get("focus"),b=d.get("blurScope"),g=d.get("disabled"),S=(f.useStyle(z(u.getLineStyle(),{fill:"none",stroke:T,lineJoin:"bevel"})),Du(f,t,"lineStyle"),0<f.style.lineWidth&&"bolder"===t.get(["emphasis","lineStyle","width"])&&(f.getState("emphasis").style.lineWidth=+f.style.lineWidth+1),$(f).seriesIndex=t.seriesIndex,Mu(f,n,b,g),Uw(t.get("smooth"))),e=t.get("smoothMonotone");f.setShape({smooth:S,smoothMonotone:e,connectNulls:w}),y&&(o=l.getCalculationInfo("stackedOnSeries"),v=0,y.useStyle(z(h.getAreaStyle(),{fill:T,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),o&&(v=Uw(o.get("smooth"))),y.setShape({smooth:S,stackedOnSmooth:v,smoothMonotone:e,connectNulls:w}),Du(y,t,"areaStyle"),$(y).seriesIndex=t.seriesIndex,Mu(y,n,b,g));l.eachItemGraphicEl(function(t){t&&(t.onHoverStateChange=i)}),this._polyline.onHoverStateChange=i,this._data=l,this._coordSys=a,this._stackedOnPoints=_,this._points=c,this._step=I,this._valueOrigin=x,t.get("triggerLineEvent")&&(this.packEventData(t,f),y)&&this.packEventData(t,y)},nS.prototype.packEventData=function(t,e){$(e).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},nS.prototype.highlight=function(t,e,n,i){var o=t.getData(),r=ua(o,i);if(this._changePolyState("emphasis"),!(r instanceof Array)&&null!=r&&0<=r){var a=o.getLayout("points");if(!(l=o.getItemGraphicEl(r))){var s=a[2*r],a=a[2*r+1];if(isNaN(s)||isNaN(a))return;if(this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(s,a))return;var l,u=t.get("zlevel")||0,h=t.get("z")||0,s=((l=new xw(o,r)).x=s,l.y=a,l.setZ(u,h),l.getSymbolPath().getTextContent());s&&(s.zlevel=u,s.z=h,s.z2=this._polyline.z2+1),l.__temp=!0,o.setItemGraphicEl(r,l),l.stopSymbolAnimation(!0),this.group.add(l)}l.highlight()}else em.prototype.highlight.call(this,t,e,n,i)},nS.prototype.downplay=function(t,e,n,i){var o,r=t.getData(),a=ua(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()):em.prototype.downplay.call(this,t,e,n,i)},nS.prototype._changePolyState=function(t){var e=this._polygon;ru(this._polyline,t),e&&ru(e,t)},nS.prototype._newPolyline=function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new Rw({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(e),this._polyline=e},nS.prototype._newPolygon=function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Gw({shape:{points:t,stackedOnPoints:e},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n},nS.prototype._initSymbolLabelAnimation=function(t,l,u){var h,c,e=l.getBaseAxis(),p=e.inverse,e=("cartesian2d"===l.type?(h=e.isHorizontal(),c=!1):"polar"===l.type&&(h="angle"===e.dim,c=!0),t.hostModel),d=e.get("animationDuration"),g=(D(d)&&(d=d(null)),e.get("animationDelay")||0),f=D(g)?g(null):g;t.eachItemGraphicEl(function(t,e){var n,i,o,r,a,s=t;s&&(r=[t.x,t.y],a=i=n=void 0,u&&(a=c?(o=u,r=l.pointToCoord(r),h?(n=o.startAngle,i=o.endAngle,-r[1]/180*Math.PI):(n=o.r0,i=o.r,r[0])):h?(n=u.x,i=u.x+u.width,t.x):(n=u.y+u.height,i=u.y,t.y)),o=i===n?0:(a-n)/(i-n),p&&(o=1-o),r=D(g)?g(e):d*o+f,a=(t=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}),t.disableLabelAnimation=!0)})},nS.prototype._initOrUpdateEndLabel=function(t,e,n){var i,o,r,a=t.getModel("endLabel");Jw(t)?(i=t.getData(),o=this._polyline,(r=i.getLayout("points"))?(this._endLabel||((this._endLabel=new K({z2:200})).ignoreClip=!0,o.setTextContent(this._endLabel),o.disableLabelAnimation=!0),0<=(r=Kw(r))&&(op(o,rp(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:r,defaultText:function(t,e,n){return null!=n?Hb(i,n):Wb(i,t)},enableTextSetter:!0},(n=a,r=(t=(t=e).getBaseAxis()).isHorizontal(),t=t.inverse,a=r?t?"right":"left":"center",r=r?"middle":t?"top":"bottom",{normal:{align:n.get("align")||a,verticalAlign:n.get("verticalAlign")||r}})),o.textConfig.position=null)):(o.removeTextContent(),this._endLabel=null)):this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},nS.prototype._endLabelOnDuring=function(t,e,n,i,o,r,a){var s,l,u,h,c,p,d,g,f,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"),f=(l=n.hostModel).get("connectNulls"),u=r.get("precision"),r=r.get("distance")||0,c=(a=a.getBaseAxis()).isHorizontal(),a=a.inverse,e=e.shape,h=(c?r:0)*(a?-1:1),r=(c?0:-r)*(a?-1:1),d=void 0,1<=(g=(p=(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}return{range:[s,l],t:(e-i)/(o-i)}}(s,a=a?c?e.x:e.y+e.height:c?e.x+e.width:e.y,e=c?"x":"y")).range)[1]-p[0])?(1<g&&!f?(y=$w(s,p[0]),m.attr({x:y[0]+h,y:y[1]+r}),o&&(d=l.getRawValue(p[0]))):((y=v.getPointOn(a,e))&&m.attr({x:y[0]+h,y:y[1]+r}),g=l.getRawValue(p[0]),f=l.getRawValue(p[1]),o&&(d=va(n,u,g,f,c.t))),i.lastFrameIndex=p[0]):(y=$w(s,v=1===t||0<i.lastFrameIndex?p[0]:0),o&&(d=l.getRawValue(v)),m.attr({x:y[0]+h,y:y[1]+r})),o)&&"function"==typeof(a=dp(m)).setLabelText&&a.setLabelText(d)},nS.prototype._doUpdateAnimation=function(t,e,n,i,o,r,a){var s=this._polyline,l=this._polygon,u=t.hostModel,e=function(t,e,n,i,o,r){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();for(var a,s=a,l=[],u=[],h=[],c=[],p=[],d=[],g=[],f=Cw(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]),g.push(e.getRawIndex(x.idx1));break;case"+":S=x.idx,M=f.dataDimsForPoint,I=o.dataToPoint([e.get(M[0],S),e.get(M[1],S)]),T=(b=2*S,l.push(I[0],I[1]),u.push(m[b],m[b+1]),Dw(f,o,e,S));h.push(T[0],T[1]),c.push(i[b],i[b+1]),g.push(e.getRawIndex(S));break;case"-":_=!1}_&&(p.push(x),d.push(d.length))}d.sort(function(t,e){return g[t]-g[e]});for(var C=lx(r=l.length),D=lx(r),A=lx(r),k=lx(r),L=[],v=0;v<d.length;v++){var P=d[v],O=2*v,N=2*P;C[O]=l[N],C[1+O]=l[1+N],D[O]=u[N],D[1+O]=u[1+N],A[O]=h[N],A[1+O]=h[1+N],k[O]=c[N],k[1+O]=c[1+N],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=e.current,c=e.stackedOnCurrent,p=e.next,d=e.stackedOnNext;if(o&&(h=Zw(e.current,n,o,a),c=Zw(e.stackedOnCurrent,n,o,a),p=Zw(e.next,n,o,a),d=Zw(e.stackedOnNext,n,o,a)),3e3<Xw(h,p)||l&&3e3<Xw(c,d))s.stopAnimation(),s.setShape({points:p}),l&&(l.stopAnimation(),l.setShape({points:p,stackedOnPoints:d}));else{s.shape.__points=e.current,s.shape.points=h;for(var g,n={shape:{points:p}},f=(e.current!==h&&(n.shape.__points=e.next),s.stopAnimation(),C(s,n,u),l&&(l.setShape({points:h,stackedOnPoints:c}),l.stopAnimation(),C(l,{shape:{stackedOnPoints:d}},u),s.shape.points!==l.shape.points)&&(l.shape.points=s.shape.points),[]),y=e.status,m=0;m<y.length;m++)"="===y[m].cmd&&(g=t.getItemGraphicEl(y[m].idx1))&&f.push({el:g,ptIdx:m});s.animators&&s.animators.length&&s.animators[0].during(function(){l&&l.dirtyShape();for(var t=s.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()}})}},nS.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},nS.type="line";var tS,eS=nS;function nS(){return null!==tS&&tS.apply(this,arguments)||this}function iS(t,i){return{seriesType:t,plan:Jy(),reset:function(t){var h,e,c,p,d,n=t.getData(),g=t.coordinateSystem,t=t.pipelineContext,f=i||t.large;if(g)return t=V(g.dimensions,function(t){return n.mapDimension(t)}).slice(0,2),h=t.length,e=n.getCalculationInfo("stackResultDimension"),E1(n,t[0])&&(t[0]=e),E1(n,t[1])&&(t[1]=e),c=n.getStore(),p=n.getDimensionIndex(t[0]),d=n.getDimensionIndex(t[1]),h&&{progress:function(t,e){for(var n=t.end-t.start,i=f&&lx(n*h),o=[],r=[],a=t.start,s=0;a<t.end;a++){var l,u=void 0;u=1===h?(l=c.get(p,a),g.dataToPoint(l,null,r)):(o[0]=c.get(p,a),o[1]=c.get(d,a),g.dataToPoint(o,null,r)),f?(i[s++]=u[0],i[s++]=u[1]):e.setItemLayout(a,u.slice())}f&&e.setLayout("points",i)}}}}}r(function(t){t.registerChartView(eS),t.registerSeriesModel(yw),t.registerLayout(iS("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,Db("line"))});var oS=2*Math.PI,rS=Math.PI/180;function aS(t,e){return Ld(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function sS(t,e){var n,i=aS(t,e),o=t.get("center"),r=t.get("radius"),a=(B(r)||(r=[0,r]),j(i.width,e.getWidth())),e=j(i.height,e.getHeight()),s=Math.min(a,e),l=j(r[0],s/2),r=j(r[1],s/2),s=t.coordinateSystem;return s=s?(n=(t=s.dataToPoint(o))[0]||0,t[1]||0):(n=j((o=B(o)?o:[o,o])[0],a)+i.x,j(o[1],e)+i.y),{cx:n,cy:s,r0:l,r:r}}function lS(t,e,T){e.eachSeriesByType(t,function(t){var o,a=t.getData(),e=a.mapDimension("value"),n=aS(t,T),i=sS(t,T),s=i.cx,l=i.cy,u=i.r,h=i.r0,r=-t.get("startAngle")*rS,i=t.get("endAngle"),c=t.get("padAngle")*rS,i="auto"===i?r-oS:-i*rS,p=t.get("minAngle")*rS+c,d=0,g=(a.each(e,function(t){isNaN(t)||d++}),a.getSum(e)),f=Math.PI/(g||d)*2,y=t.get("clockwise"),m=t.get("roseType"),v=t.get("stillShowZeroSum"),x=a.getDataExtent(e),_=(x[0]=0,y?1:-1),t=[r,i],b=_*c/2,w=(Os(t,!y),r=t[0],Math.abs(t[1]-r)),S=w,M=0,I=r;a.setLayout({viewRect:n,r:u}),a.each(e,function(t,e){var n,i,o,r;isNaN(t)?a.setItemLayout(e,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:y,cx:s,cy:l,r0:h,r:m?NaN:u}):((n="area"!==m?0===g&&v?f:t*f:w/d)<p?S-=n=p:M+=t,i=I+_*n,r=o=0,r=n<c?o=I+_*n/2:(o=I+b,i-b),a.setItemLayout(e,{angle:n,startAngle:o,endAngle:r,clockwise:y,cx:s,cy:l,r0:h,r:m?Cr(t,x,[h,u]):u}),I=i)}),S<oS&&d&&(S<=.001?(o=w/d,a.each(e,function(t,e){var n,i;isNaN(t)||(i=t=0,i=((n=a.getItemLayout(e)).angle=o)<c?t=r+_*(e+.5)*o:(t=r+_*e*o+b,r+_*(e+1)*o-b),n.startAngle=t,n.endAngle=i)})):(f=S/M,I=r,a.each(e,function(t,e){var n,i;isNaN(t)||(i=n=0,i=(t=(e=a.getItemLayout(e)).angle===p?p:t*f)<c?n=I+_*t/2:(n=I+b,I+_*t-b),e.startAngle=n,e.endAngle=i,I+=_*t)})))})}function uS(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 hS=Math.PI/180;function cS(t,s,l,u,h,e,n,i,o,r){if(!(t.length<2)){for(var a,c=t.length,p=0;p<c;p++)"outer"===t[p].position&&"labelLine"===t[p].labelAlignTo&&(a=t[p].label.x-r,t[p].linePoints[1][0]+=a,t[p].label.x=r);if(Q_(t,o,o+n)){for(var d,g,f,y,m,v=t,x={list:[],maxY:0},_={list:[],maxY:0},b=0;b<v.length;b++)"none"===v[b].labelAlignTo&&(g=(d=v[b]).label.y>l?_:x,(f=Math.abs(d.label.y-l))>=g.maxY&&(m=d.label.x-s-d.len2*h,y=u+d.len,m=Math.abs(m)<y?Math.sqrt(f*f/(1-m*m/y/y)):y,g.rB=m,g.maxY=f),g.list.push(d));w(x),w(_)}}function w(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-l),a=u+o.len,a=a*a,r=Math.sqrt((1-Math.abs(r*r/n))*a),a=s+(r+o.len2)*h,r=a-o.label.x;pS(o,o.targetTextWidth-r*h,!0),o.label.x=a}}}function pS(t,e,n){var i,o,r,a,s,l,u;void 0===n&&(n=!1),null==t.labelStyleWidth&&(s=(i=t.label).style,o=t.rect,l=s.backgroundColor,u=(u=s.padding)?u[1]+u[3]:0,s=s.overflow,e<(r=o.width+(l?0:u))||n)&&(a=o.height,s&&s.match("break")?(i.setStyle("backgroundColor",null),i.setStyle("width",e-u),s=i.getBoundingRect(),i.setStyle("width",Math.ceil(s.width)),i.setStyle("backgroundColor",l)):(s=e-u,l=!(e<r)&&(!n||s>t.unconstrainedWidth)?null:s,i.setStyle("width",l)),u=i.getBoundingRect(),o.width=u.width,e=(i.style.margin||0)+2.1,o.height=u.height+e,o.y-=(o.height-a)/2)}function dS(t){return"center"===t.position}function gS(t){var S,M,I=t.getData(),T=[],C=!1,D=(t.get("minShowLabelAngle")||0)*hS,e=I.getLayout("viewRect"),A=I.getLayout("r"),k=e.width,L=e.x,n=e.y,e=e.height;function P(t){t.ignore=!0}if(I.each(function(t){var e,n,i,o,r,a,s,l,u,h,c=I.getItemGraphicEl(t),p=c.shape,d=c.getTextContent(),g=c.getTextGuideLine(),t=I.getItemModel(t),f=t.getModel("label"),y=f.get("position")||t.get(["emphasis","label","position"]),m=f.get("distanceToLabelLine"),v=f.get("alignTo"),x=j(f.get("edgeDistance"),k),_=f.get("bleedMargin"),t=t.getModel("labelLine"),b=j(t.get("length"),k),w=j(t.get("length2"),k);Math.abs(p.endAngle-p.startAngle)<D?(nt(d.states,P),d.ignore=!0,g&&(nt(g.states,P),g.ignore=!0)):function(t){if(!t.ignore)return 1;for(var e in t.states)if(!1===t.states[e].ignore)return 1}(d)&&(h=(p.startAngle+p.endAngle)/2,e=Math.cos(h),n=Math.sin(h),S=p.cx,M=p.cy,i="inside"===y||"inner"===y,s="center"===y?(o=p.cx,r=p.cy,"center"):(o=(s=(i?(p.r+p.r0)/2*e:p.r*e)+S)+3*e,r=(l=(i?(p.r+p.r0)/2*n:p.r*n)+M)+3*n,i||(a=s+e*(b+A-p.r),p=l+n*(b+A-p.r),u=a+(e<0?-1:1)*w,o="edge"===v?e<0?L+x:L+k-x:u+(e<0?-m:m),a=[[s,l],[a,r=p],[u,p]]),i?"center":"edge"===v?0<e?"right":"left":0<e?"left":"right"),l=Math.PI,u=0,Y(p=f.get("rotate"))?u=p*(l/180):"center"===y?u=0:"radial"===p||!0===p?u=e<0?-h+l:-h:"tangential"===p&&"outside"!==y&&"outer"!==y&&((f=Math.atan2(e,n))<0&&(f=2*l+f),u=(f=0<n?l+f:f)-l),C=!!u,d.x=o,d.y=r,d.rotation=u,d.setStyle({verticalAlign:"middle"}),i?(d.setStyle({align:s}),(h=d.states.select)&&(h.x+=d.x,h.y+=d.y)):((p=d.getBoundingRect().clone()).applyTransform(d.getComputedTransform()),f=(d.style.margin||0)+2.1,p.y-=f/2,p.height+=f,T.push({label:d,labelLine:g,position:y,len:b,len2:w,minTurnAngle:t.get("minTurnAngle"),maxSurfaceAngle:t.get("maxSurfaceAngle"),surfaceNormal:new E(e,n),linePoints:a,textAlign:s,labelDistance:m,labelAlignTo:v,edgeDistance:x,bleedMargin:_,rect:p,unconstrainedWidth:p.width,labelStyleWidth:d.style.width})),c.setTextConfig({inside:i}))}),!C&&t.get("avoidLabelOverlap")){for(var i=T,o=S,t=M,r=A,a=k,s=L,l=[],u=[],h=Number.MAX_VALUE,c=-Number.MAX_VALUE,p=0;p<i.length;p++){var d=i[p].label;dS(i[p])||(d.x<o?(h=Math.min(h,d.x),l):(c=Math.max(c,d.x),u)).push(i[p])}for(var g,p=0;p<i.length;p++)!dS(f=i[p])&&f.linePoints&&null==f.labelStyleWidth&&(d=f.label,y=f.linePoints,g=void 0,g="edge"===f.labelAlignTo?d.x<o?y[2][0]-f.labelDistance-s-f.edgeDistance:s+a-f.edgeDistance-y[2][0]-f.labelDistance:"labelLine"===f.labelAlignTo?d.x<o?h-s-f.bleedMargin:s+a-c-f.bleedMargin:d.x<o?d.x-s-f.bleedMargin:s+a-d.x-f.bleedMargin,f.targetTextWidth=g,pS(f,g));cS(u,o,t,r,1,0,e,0,n,c),cS(l,o,t,r,-1,0,e,0,n,h);for(var f,y,m,v,x,p=0;p<i.length;p++)!dS(f=i[p])&&f.linePoints&&(d=f.label,y=f.linePoints,m="edge"===f.labelAlignTo,v=(v=d.style.padding)?v[1]+v[3]:0,v=d.style.backgroundColor?0:v,v=f.rect.width+v,x=y[1][0]-y[2][0],m?d.x<o?y[2][0]=s+f.edgeDistance+v+f.labelDistance:y[2][0]=s+a-f.edgeDistance-v-f.labelDistance:(d.x<o?y[2][0]=d.x+f.labelDistance:y[2][0]=d.x-f.labelDistance,y[1][0]=y[2][0]+x),y[1][1]=y[2][1]=d.y)}for(var _=0;_<T.length;_++){var b,w=T[_],O=w.label,N=w.labelLine,R=isNaN(O.x)||isNaN(O.y);O&&(O.setStyle({align:w.textAlign}),R&&(nt(O.states,P),O.ignore=!0),b=O.states.select)&&(b.x+=O.x,b.y+=O.y),N&&(b=w.linePoints,R||!b?(nt(N.states,P),N.ignore=!0):(U_(b,w.minTurnAngle),function(t,e,n){if(n<=180&&0<n){n=n/180*Math.PI,V_.fromArray(t[0]),B_.fromArray(t[1]),F_.fromArray(t[2]),E.sub(G_,B_,V_),E.sub(W_,F_,B_);var i=G_.len(),o=W_.len();if(!(i<.001||o<.001))if(G_.scale(1/i),W_.scale(1/o),G_.dot(e)<Math.cos(n)){i=N_(B_.x,B_.y,F_.x,F_.y,V_.x,V_.y,Y_,!1),o=(X_.fromArray(Y_),Math.PI/2),e=o+Math.acos(W_.dot(e))-n;if(o<=e)E.copy(X_,F_);else{X_.scaleAndAdd(W_,i/Math.tan(Math.PI/2-e));n=F_.x!==B_.x?(X_.x-B_.x)/(F_.x-B_.x):(X_.y-B_.y)/(F_.y-B_.y);if(isNaN(n))return;n<0?E.copy(X_,B_):1<n&&E.copy(X_,F_)}X_.toArray(t[1])}}}(b,w.surfaceNormal,w.maxSurfaceAngle),N.setShape({points:b}),O.__hostTarget.textGuideLineConfig={anchor:new E(b[0][0],b[0][1])}))}}u(mS,fS=wh),mS.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=F(Ub(a.getModel("itemStyle"),l,!0),l);isNaN(u.startAngle)?o.setShape(u):(i?(o.setShape(u),i=r.getShallow("animationType"),r.ecModel.ssr?(_c(o,{scaleX:0,scaleY:0},r,{dataIndex:e,isFrom:!0}),o.originX=u.cx,o.originY=u.cy):"scale"===i?(o.shape.r=l.r0,_c(o,{shape:{r:l.r}},r,e)):null!=n?(o.setShape({startAngle:n,endAngle:n}),_c(o,{shape:{startAngle:l.startAngle,endAngle:l.endAngle}},r,e)):(o.shape.endAngle=l.startAngle,C(o,{shape:{endAngle:l.endAngle}},r,e))):(Ic(o),C(o,{shape:u},r,e)),o.useStyle(t.getItemVisual(e,"style")),Du(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)},Ub(s.getModel("itemStyle"),l)),F(o.ensureState("select"),{x:u,y:i,shape:Ub(a.getModel(["select","itemStyle"]),l)}),F(o.ensureState("blur"),{shape:Ub(a.getModel(["blur","itemStyle"]),l)}),n=o.getTextGuideLine(),r=o.getTextContent(),n&&F(n.ensureState("select"),{x:u,y:i}),F(r.ensureState("select"),{x:u,y:i}),Mu(this,s.get("focus"),s.get("blurScope"),s.get("disabled")))},mS.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,e=(op(this,rp(i),{labelFetcher:e.hostModel,labelDataIndex:n,inheritColor:a,defaultOpacity:r,defaultText:t.getFormattedLabel(n,"normal")||e.getName(n)}),this.getTextContent()),n=(this.setTextConfig({position:null,rotation:null}),e.attr({z2:10}),t.get(["label","position"]));"outside"!==n&&"outer"!==n?this.removeTextGuideLine():(this.getTextGuideLine()||(e=new Rh,this.setTextGuideLine(e)),q_(this,K_(i),{stroke:a,opacity:St(o.get(["lineStyle","opacity"]),r,1)}))};var fS,yS=mS;function mS(t,e,n){var i=fS.call(this)||this,o=(i.z2=2,new K);return i.setTextContent(o),i.updateData(t,e,n,!0),i}u(_S,vS=em),_S.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 wh({shape:sS(e,n)})).useStyle(e.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=n,s.add(n)),r.diff(a).add(function(t){var e=new yS(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){Mc(a.getItemGraphicEl(t),e,t)}).execute(),gS(e),"expansion"!==e.get("animationTypeUpdate")&&(this._data=r)},_S.prototype.dispose=function(){},_S.prototype.containPoint=function(t,e){var n,e=e.getData().getItemLayout(0);if(e)return n=t[0]-e.cx,t=t[1]-e.cy,(n=Math.sqrt(n*n+t*t))<=e.r&&n>=e.r0},_S.type="pie";var vS,xS=_S;function _S(){var t=null!==vS&&vS.apply(this,arguments)||this;return t.ignoreLabelLineUpdate=!0,t}function bS(t,e,n){e=B(e)?{coordDimensions:e}:F({encodeDefine:t.getEncode()},e);var i=t.getSource(),e=L1(i,e).dimensions,e=new k1(e,t);return e.initData(i,n),e}SS.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},SS.prototype.containName=function(t){return 0<=this._getRawData().indexOfName(t)},SS.prototype.indexOfName=function(t){return this._getDataWithEncodedVisual().indexOfName(t)},SS.prototype.getItemVisual=function(t,e){return this._getDataWithEncodedVisual().getItemVisual(t,e)};var wS=SS;function SS(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}var MS,IS=i(),TS=(u(CS,MS=Gy),CS.prototype.init=function(t){MS.prototype.init.apply(this,arguments),this.legendVisualProvider=new wS(T(this.getData,this),T(this.getRawData,this)),this._defaultLabelLine(t)},CS.prototype.mergeOption=function(){MS.prototype.mergeOption.apply(this,arguments)},CS.prototype.getInitialData=function(){return bS(this,{coordDimensions:["value"],encodeDefaulter:P(ig,this)})},CS.prototype.getDataParams=function(t){var e,n=this.getData(),i=IS(n),o=i.seats,i=(o||(e=[],n.each(n.mapDimension("value"),function(t){e.push(t)}),o=i.seats=Or(e,n.hostModel.get("percentPrecision"))),MS.prototype.getDataParams.call(this,t));return i.percent=o[t]||0,i.$vars.push("percent"),i},CS.prototype._defaultLabelLine=function(t){Qr(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},CS.type="series.pie",CS.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},CS);function CS(){return null!==MS&&MS.apply(this,arguments)||this}r(function(t){t.registerChartView(xS),t.registerSeriesModel(TS),Um("pie",t.registerAction),t.registerLayout(P(lS,"pie")),t.registerProcessor(uS("pie")),t.registerProcessor({seriesType:"pie",reset:function(t,e){var n=t.getData();n.filterSelf(function(t){var e=n.mapDimension("value"),e=n.get(e,t);return!(Y(e)&&!isNaN(e)&&e<0)})}})});u(kS,DS=Gy),kS.prototype.getInitialData=function(t,e){return V1(null,this,{useEncodeDefaulter:!0})},kS.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},kS.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},kS.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},kS.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},kS.type="series.scatter",kS.dependencies=["grid","polar","geo","singleAxis","calendar"],kS.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}};var DS,AS=kS;function kS(){var t=null!==DS&&DS.apply(this,arguments)||this;return t.type=kS.type,t.hasSymbolVisual=!0,t}var LS,PS=function(){},OS=(u(NS,LS=q),NS.prototype.getDefaultShape=function(){return new PS},NS.prototype.reset=function(){this.notClear=!1,this._off=0},NS.prototype.buildPath=function(t,e){var n,i=e.points,o=e.size,r=this.symbolProxy,a=r.shape,e=t.getContext?t.getContext():t,s=e&&o[0]<4,l=this.softClipShape;if(s)this._ctx=e;else{for(this._ctx=null,n=this._off;n<i.length;){var u=i[n++],h=i[n++];isNaN(u)||isNaN(h)||l&&!l.contain(u,h)||(a.x=u-o[0]/2,a.y=h-o[1]/2,a.width=o[0],a.height=o[1],r.buildPath(t,a,!0))}this.incremental&&(this._off=n,this.notClear=!0)}},NS.prototype.afterBrush=function(){var t,e=this.shape,n=e.points,i=e.size,o=this._ctx,r=this.softClipShape;if(o){for(t=this._off;t<n.length;){var a=n[t++],s=n[t++];isNaN(a)||isNaN(s)||r&&!r.contain(a,s)||o.fillRect(a-i[0]/2,s-i[1]/2,i[0],i[1])}this.incremental&&(this._off=t,this.notClear=!0)}},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.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();return t=n[0],e=n[1],i.contain(t,e)?0<=(this.hoverDataIdx=this.findDataIndex(t,e)):!(this.hoverDataIdx=-1)},NS.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape,n=e.points,e=e.size,i=e[0],e=e[1],o=1/0,r=1/0,a=-1/0,s=-1/0,l=0;l<n.length;)var u=n[l++],h=n[l++],o=Math.min(u,o),a=Math.max(u,a),r=Math.min(h,r),s=Math.max(h,s);t=this._rect=new U(o-i/2,r-e/2,a-o+i,s-r+e)}return t},NS);function NS(t){t=LS.call(this,t)||this;return t._off=0,t.hoverDataIdx=-1,t}ES.prototype.updateData=function(t,e){this._clear();var n=this._create();n.setShape({points:t.getLayout("points")}),this._setCommon(n,t,e)},ES.prototype.updateLayout=function(t){var 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),t.reset()})},ES.prototype.incrementalPrepareUpdate=function(t){this._clear()},ES.prototype.incrementalUpdate=function(t,e,n){var i,o,r=this._newAdded[0],a=e.getLayout("points"),s=r&&r.shape.points;s&&s.length<2e4?(i=s.length,(o=new Float32Array(i+a.length)).set(s),o.set(a,i),r.endIndex=t.end,r.setShape({points:o})):(this._newAdded=[],(s=this._create()).startIndex=t.start,s.endIndex=t.end,s.incremental=!0,s.setShape({points:a}),this._setCommon(s,e,n))},ES.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},ES.prototype._create=function(){var t=new OS({cursor:"default"});return t.ignoreCoarsePointer=!0,this.group.add(t),this._newAdded.push(t),t},ES.prototype._setCommon=function(n,t,e){var i=t.hostModel,o=(e=e||{},t.getVisual("symbolSize")),o=(n.setShape("size",o instanceof Array?o:[o,o]),n.softClipShape=e.clipShape||null,n.symbolProxy=s0(t.getVisual("symbol"),0,0,0,0),n.setColor=n.symbolProxy.setColor,n.shape.size[0]<4),e=(n.useStyle(i.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"])),t.getVisual("style")),o=e&&e.fill,r=(o&&n.setColor(o),$(n));r.seriesIndex=i.seriesIndex,n.on("mousemove",function(t){r.dataIndex=null;var e=n.hoverDataIdx;0<=e&&(r.dataIndex=e+(n.startIndex||0))})},ES.prototype.remove=function(){this._clear()},ES.prototype._clear=function(){this._newAdded=[],this.group.removeAll()};var RS=ES;function ES(){this.group=new Z}u(BS,zS=em),BS.prototype.render=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},BS.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},BS.prototype.incrementalRender=function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData(),{clipShape:this._getClipShape(e)}),this._finished=t.end===e.getData().count()},BS.prototype.updateTransform=function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||1e4<i.count())return{update:!0};t=iS("").reset(t,e,n);t.progress&&t.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},BS.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},BS.prototype._getClipShape=function(t){if(t.get("clip",!0))return(t=t.coordinateSystem)&&t.getArea&&t.getArea(.1)},BS.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?RS:Iw),this._isLargeDraw=e,this.group.removeAll()),this.group.add(n.group),n},BS.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},BS.prototype.dispose=function(){},BS.type="scatter";var zS,VS=BS;function BS(){var t=null!==zS&&zS.apply(this,arguments)||this;return t.type=BS.type,t}u(WS,FS=g),WS.type="grid",WS.dependencies=["xAxis","yAxis"],WS.layoutMode="box",WS.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"};var FS,GS=WS;function WS(){return null!==FS&&FS.apply(this,arguments)||this}u(XS,HS=g),XS.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",da).models[0]},XS.type="cartesian2dAxis";var HS,YS=XS;function XS(){return null!==HS&&HS.apply(this,arguments)||this}ut(YS,$x);var Ia={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},$m=d({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Ia),n0=d({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}}},Ia),US={category:$m,value:n0,time:d({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},n0),log:z({logBase:10},n0)},ZS={value:1,category:1,time:1,log:1};function jS(r,a,s,l){nt(ZS,function(t,o){var e,n=d(d({},US[o],!0),l,!0),n=(u(i,e=s),i.prototype.mergeDefaultAndTheme=function(t,e){var n=Od(this),i=n?Rd(t):{};d(t,e.getTheme().get(o+"Axis")),d(t,this.getDefaultOption()),t.type=qS(t),n&&Nd(t,i,n)},i.prototype.optionUpdated=function(){"category"===this.option.type&&(this.__ordinalMeta=W1.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",qS)}function qS(t){return t.type||(t.data?"category":"value")}function KS(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}KS.prototype.getAxis=function(t){return this._axes[t]},KS.prototype.getAxes=function(){return V(this._dimList,function(t){return this._axes[t]},this)},KS.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),pt(this.getAxes(),function(t){return t.scale.type===e})},KS.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)};var $S=["x","y"];function JS(t){return"interval"===t.type||"time"===t.type}u(eM,QS=KS),eM.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t,e,n,i,o=this.getAxis("x").scale,r=this.getAxis("y").scale;JS(o)&&JS(r)&&(o=o.getExtent(),r=r.getExtent(),i=this.dataToPoint([o[0],r[0]]),e=this.dataToPoint([o[1],r[1]]),t=o[1]-o[0],n=r[1]-r[0],t)&&n&&(t=(e[0]-i[0])/t,e=(e[1]-i[1])/n,n=i[0]-o[0]*t,o=i[1]-r[0]*e,i=this._transform=[t,0,0,e,n,o],this._invTransform=Ye([],i))},eM.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},eM.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]))},eM.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},eM.prototype.containZone=function(t,e){var t=this.dataToPoint(t),e=this.dataToPoint(e),n=this.getArea(),e=new U(t[0],t[1],e[0]-t[0],e[1]-t[1]);return n.intersect(e)},eM.prototype.dataToPoint=function(t,e,n){n=n||[];var i,o=t[0],r=t[1];return this._transform&&null!=o&&isFinite(o)&&null!=r&&isFinite(r)?oe(n,t,this._transform):(t=this.getAxis("x"),i=this.getAxis("y"),n[0]=t.toGlobalCoord(t.dataToCoord(o,e)),n[1]=i.toGlobalCoord(i.dataToCoord(r,e)),n)},eM.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]),i=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]),i),Math.max(r[0],r[1])),e},eM.prototype.pointToData=function(t,e){var n,i,o=[];return this._invTransform?oe(o,t,this._invTransform):(n=this.getAxis("x"),i=this.getAxis("y"),o[0]=n.coordToData(n.toLocalCoord(t[0]),e),o[1]=i.coordToData(i.toLocalCoord(t[1]),e),o)},eM.prototype.getOtherAxis=function(t){return this.getAxis("x"===t.dim?"y":"x")},eM.prototype.getArea=function(t){t=t||0;var e=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),i=Math.min(e[0],e[1])-t,o=Math.min(n[0],n[1])-t,e=Math.max(e[0],e[1])-i+t,n=Math.max(n[0],n[1])-o+t;return new U(i,o,e,n)};var QS,tM=eM;function eM(){var t=null!==QS&&QS.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=$S,t}u(oM,nM=Ip),oM.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},oM.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},oM.prototype.pointToData=function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},oM.prototype.setCategorySortInfo=function(t){if("category"!==this.type)return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)};var nM,iM=oM;function oM(t,e,n,i,o){t=nM.call(this,t,e,n)||this;return t.index=0,t.type=i||"value",t.position=o||"bottom",t}function rM(t,e,n){n=n||{};var t=t.coordinateSystem,i=e.axis,o={},r=i.getAxesOnZeroOf()[0],a=i.position,s=r?"onZero":a,i=i.dim,t=t.getRect(),t=[t.x,t.x+t.width,t.y,t.y+t.height],l={left:0,right:1,top:0,bottom:1,onZero:2},u=e.get("offset")||0,u="x"===i?[t[2]-u,t[3]+u]:[t[0]-u,t[1]+u],h=(r&&(h=r.toGlobalCoord(r.dataToCoord(0)),u[l.onZero]=Math.max(Math.min(h,u[1]),u[0])),o.position=["y"===i?u[l[s]]:t[0],"x"===i?u[l[s]]:t[3]],o.rotation=Math.PI/2*("x"===i?0:1),o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,left:-1,right:1}[a],o.labelOffset=r?u[l[a]]-u[l.onZero]:0,e.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),wt(n.labelInside,e.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection),e.get(["axisLabel","rotate"]));return o.labelRotate="top"===s?-h:h,o.z2=1,o}function aM(t){return"cartesian2d"===t.get("coordinateSystem")}function sM(i){var o={xAxisModel:null,yAxisModel:null};return nt(o,function(t,e){var n=e.replace(/Model$/,""),n=i.getReferringComponents(n,da).models[0];o[e]=n}),o}var lM=Math.log;function uM(t,e,n){var i=ox.prototype,o=i.getTicks.call(n),r=i.getTicks.call(n,!0),a=o.length-1,n=i.getInterval.call(n),e=Wx(t,e),s=e.extent,l=e.fixMin,e=e.fixMax,u=("log"===t.type&&(u=lM(t.base),s=[lM(s[0])/u,lM(s[1])/u]),t.setExtent(s[0],s[1]),t.calcNiceExtent({splitNumber:a,fixMin:l,fixMax:e}),i.getExtent.call(t)),h=(l&&(s[0]=u[0]),e&&(s[1]=u[1]),i.getInterval.call(t)),c=s[0],p=s[1];if(l&&e)h=(p-c)/a;else if(l)for(p=s[0]+h*a;p<s[1]&&isFinite(p)&&isFinite(s[1]);)h=Z1(h),p=s[0]+h*a;else if(e)for(c=s[1]-h*a;c>s[0]&&isFinite(c)&&isFinite(s[0]);)h=Z1(h),c=s[1]-h*a;else{u=(h=a<t.getTicks().length-1?Z1(h):h)*a;(c=Dr((p=Math.ceil(s[1]/h)*h)-u))<0&&0<=s[0]?(c=0,p=Dr(u)):0<p&&s[1]<=0&&(p=0,c=-Dr(u))}l=(o[0].value-r[0].value)/n,e=(o[a].value-r[a].value)/n;i.setExtent.call(t,c+h*l,p+h*e),i.setInterval.call(t,h),(l||e)&&i.setNiceExtent.call(t,c+h,p-h)}cM.prototype.getRect=function(){return this._rect},cM.prototype.update=function(t,e){var n=this._axesMap;function i(t){var e,n=W(t),i=n.length;if(i){for(var o=[],r=i-1;0<=r;r--){var a=t[+n[r]],s=a.model,l=a.scale;X1(l)&&s.get("alignTicks")&&null==s.get("interval")?o.push(a):(Hx(l,s),X1(l)&&(e=a))}o.length&&(e||Hx((e=o.pop()).scale,e.model),nt(o,function(t){uM(t.scale,t.model,e.scale)}))}}this._updateScale(t,this.model),i(n.x),i(n.y);var o={};nt(n.x,function(t){dM(n,"y",t,o)}),nt(n.y,function(t){dM(n,"x",t,o)}),this.resize(this.model,e)},cM.prototype.resize=function(t,e,n){var i=t.getBoxLayoutParams(),n=!n&&t.get("containLabel"),a=Ld(i,{width:e.getWidth(),height:e.getHeight()}),o=(this._rect=a,this._axesList);function r(){nt(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]),o=t,e=i?a.x:a.y,r=o.getExtent(),n=r[0]+r[1],o.toGlobalCoord="x"===o.dim?function(t){return t+e}:function(t){return n-t+e},o.toLocalCoord="x"===o.dim?function(t){return t-e}:function(t){return n-t+e}})}r(),n&&(nt(o,function(t){var e,n,i;t.model.get(["axisLabel","inside"])||(e=Zx(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()),nt(this._coordsList,function(t){t.calcAffineTransform()})},cM.prototype.getAxis=function(t,e){t=this._axesMap[t];if(null!=t)return t[e||0]},cM.prototype.getAxes=function(){return this._axesList.slice()},cM.prototype.getCartesian=function(t,e){if(null!=t&&null!=e)return this._coordsMap["x"+t+"y"+e];O(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]},cM.prototype.getCartesians=function(){return this._coordsList.slice()},cM.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},cM.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},cM.prototype._findConvertTarget=function(t){var e,n,i=t.seriesModel,o=t.xAxisModel||i&&i.getReferringComponents("xAxis",da).models[0],r=t.yAxisModel||i&&i.getReferringComponents("yAxis",da).models[0],t=t.gridModel,a=this._coordsList;return i?G(a,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):t&&t.coordinateSystem===this&&(e=this._coordsList[0]),{cartesian:e,axis:n}},cM.prototype.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},cM.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};function n(o){return function(t,e){var n,i;pM(t,r)&&(n=t.get("position"),"x"===o?"top"!==n&&"bottom"!==n&&(n=l.bottom?"top":"bottom"):"left"!==n&&"right"!==n&&(n=l.left?"right":"left"),l[n]=!0,i="category"===(n=new iM(o,Yx(t),[0,0],t.get("type"),n)).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]++)}}t.eachComponent("xAxis",n("x"),this),t.eachComponent("yAxis",n("y"),this),h.x&&h.y?nt((this._axesMap=u).x,function(i,o){nt(u.y,function(t,e){var e="x"+o+"y"+e,n=new tM(e);n.master=a,n.model=r,a._coordsMap[e]=n,a._coordsList.push(n),n.addAxis(i),n.addAxis(t)})}):(this._axesMap={},this._axesList=[])},cM.prototype._updateScale=function(t,i){function o(e,n){nt(Kx(e,n.dim),function(t){n.scale.unionExtentFromData(e,t)})}nt(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;aM(t)&&(n=(e=sM(t)).xAxisModel,e=e.yAxisModel,pM(n,i))&&pM(e,i)&&(n=this.getCartesian(n.componentIndex,e.componentIndex),e=t.getData(),t=n.getAxis("x"),n=n.getAxis("y"),o(e,t),o(e,n))},this)},cM.prototype.getTooltipAxes=function(n){var i=[],o=[];return nt(this.getCartesians(),function(t){var e=null!=n&&"auto"!==n?t.getAxis(n):t.getBaseAxis(),t=t.getOtherAxis(e);G(i,e)<0&&i.push(e),G(o,t)<0&&o.push(t)}),{baseAxes:i,otherAxes:o}},cM.create=function(i,o){var r=[];return i.eachComponent("grid",function(t,e){var n=new cM(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;aM(t)&&(e=(n=sM(t)).xAxisModel,n=n.yAxisModel,i=e.getCoordSysModel().coordinateSystem,t.coordinateSystem=i.getCartesian(e.componentIndex,n.componentIndex))}),r},cM.dimensions=$S;var hM=cM;function cM(t,e,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=$S,this._initCartesian(t,e,n),this.model=t}function pM(t,e){return t.getCoordSysModel()===e}function dM(t,e,n,i){n.getAxesOnZeroOf=function(){return o?[o]:[]};var o,r=t[e],t=n.model,e=t.get(["axisLine","onZero"]),n=t.get(["axisLine","onZeroAxisIndex"]);if(e){if(null!=n)gM(r[n])&&(o=r[n]);else for(var a in r)if(r.hasOwnProperty(a)&&gM(r[a])&&!i[s(r[a])]){o=r[a];break}o&&(i[s(o)]=!0)}function s(t){return t.dim+"_"+t.index}}function gM(t){return t&&"category"!==t.type&&"time"!==t.type&&(e=(t=(t=t).scale.getExtent())[0],t=t[1],!(0<e&&0<t||e<0&&t<0));var e}var fM=Math.PI,yM=(mM.prototype.hasBuilder=function(t){return!!vM[t]},mM.prototype.add=function(t){vM[t](this.opt,this.axisModel,this.group,this._transformGroup)},mM.prototype.getGroup=function(){return this.group},mM.innerTextLayout=function(t,e,n){var i,e=Rr(e-t),t=Er(e)?(i=0<n?"top":"bottom","center"):Er(e-fM)?(i=0<n?"bottom":"top","center"):(i="middle",0<e&&e<fM?0<n?"right":"left":0<n?"left":"right");return{rotation:e,textAlign:t,textVerticalAlign:i}},mM.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},mM.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},mM);function mM(t,e){this.group=new Z,this.opt=e,this.axisModel=t,z(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});t=new Z({x:e.position[0],y:e.position[1],rotation:e.rotation});t.updateTransform(),this._transformGroup=t}var vM={axisLine:function(i,t,o,e){var r,a,s,l,u,h,c,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],a=[n[1],0],s=a[0]<r[0],e&&(oe(r,r,e),oe(a,a,e)),l=F({lineCap:"round"},t.getModel(["axisLine","lineStyle"]).getLineStyle()),Bc((n=new Fh({shape:{x1:r[0],y1:r[1],x2:a[0],y2:a[1]},style:l,strokeContainThreshold:i.strokeContainThreshold||5,silent:!0,z2:1})).shape,n.style.lineWidth),n.anid="line",o.add(n),null!=(u=t.get(["axisLine","symbol"])))&&(e=t.get(["axisLine","symbolSize"]),H(u)&&(u=[u,u]),(H(e)||Y(e))&&(e=[e,e]),n=u0(t.get(["axisLine","symbolOffset"])||0,e),h=e[0],c=e[1],nt([{rotate:i.rotation+Math.PI/2,offset:n[0],r:0},{rotate:i.rotation-Math.PI/2,offset:n[1],r:Math.sqrt((r[0]-a[0])*(r[0]-a[0])+(r[1]-a[1])*(r[1]-a[1]))}],function(t,e){var n;"none"!==u[e]&&null!=u[e]&&(e=s0(u[e],-h/2,-c/2,h,c,l.stroke,!0),n=t.r+t.offset,e.attr({rotation:t.rotate,x:(t=s?a:r)[0]+n*Math.cos(i.rotation),y:t[1]-n*Math.sin(i.rotation),silent:!0,z2:11}),o.add(e))}))},axisTickLabel:function(t,e,n,i){var o,r,a,s,l,u=function(t,e,n,i){var o=n.axis,r=n.getModel("axisTick"),a=r.get("show");"auto"===a&&i.handleAutoShown&&(a=i.handleAutoShown("axisTick"));if(a&&!o.scale.isBlank()){for(var a=r.getModel("lineStyle"),i=i.tickDirection*r.get("length"),s=wM(o.getTicksCoords(),e.transform,i,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),h=function(g,f,y,m){var v,x,_,b,w,S,M,I,T=y.axis,t=wt(m.axisLabelShow,y.get(["axisLabel","show"]));if(t&&!T.scale.isBlank())return v=y.getModel("axisLabel"),x=v.get("margin"),_=T.getViewLabels(),t=(wt(m.labelRotate,v.get("rotate"))||0)*fM/180,b=yM.innerTextLayout(m.rotation,t,m.labelDirection),w=y.getCategories&&y.getCategories(!0),S=[],M=yM.isLabelSilent(y),I=y.get("triggerEvent"),nt(_,function(t,e){var n="ordinal"===T.scale.type?T.scale.getRawOrdinalNumber(t.tickValue):t.tickValue,i=t.formattedLabel,o=t.rawLabel,r=v,a=(r=w&&w[n]&&O(a=w[n])&&a.textStyle?new kp(a.textStyle,v,y.ecModel):r).getTextColor()||y.get(["axisLine","lineStyle","color"]),s=T.dataToCoord(n),l=r.getShallow("align",!0)||b.textAlign,u=N(r.getShallow("alignMinLabel",!0),l),h=N(r.getShallow("alignMaxLabel",!0),l),c=r.getShallow("verticalAlign",!0)||r.getShallow("baseline",!0)||b.textVerticalAlign,p=N(r.getShallow("verticalAlignMinLabel",!0),c),d=N(r.getShallow("verticalAlignMaxLabel",!0),c),s=new K({x:s,y:m.labelOffset+m.labelDirection*x,rotation:b.rotation,silent:M,z2:10+(t.level||0),style:ap(r,{text:i,align:0===e?u:e===_.length-1?h:l,verticalAlign:0===e?p:e===_.length-1?d:c,fill:D(a)?a("category"===T.type?o:"value"===T.type?n+"":n,e):a})});s.anid="label_"+n,I&&((t=yM.makeAxisEventDataBase(y)).targetType="axisLabel",t.value=o,t.tickIndex=e,"category"===T.type&&(t.dataIndex=n),$(s).eventData=t),f.add(s),s.updateTransform(),S.push(s),g.add(s),s.decomposeTransform()}),S}(n,i,e,t),c=(r=h,u=u,qx((o=e).axis)||(d=o.get(["axisLabel","showMinLabel"]),o=o.get(["axisLabel","showMaxLabel"]),u=u||[],y=(r=r||[])[0],g=r[1],a=r[r.length-1],r=r[r.length-2],s=u[0],f=u[1],l=u[u.length-1],u=u[u.length-2],!1===d?(xM(y),xM(s)):_M(y,g)&&(d?(xM(g),xM(f)):(xM(y),xM(s))),!1===o?(xM(a),xM(l)):_M(r,a)&&(o?(xM(r),xM(u)):(xM(a),xM(l)))),n),p=i,d=e,g=t.tickDirection,f=d.axis,y=d.getModel("minorTick");if(y.get("show")&&!f.scale.isBlank()){var m=f.getMinorTicksCoords();if(m.length)for(var f=y.getModel("lineStyle"),v=g*y.get("length"),x=z(f.getLineStyle(),z(d.getModel("axisTick").getLineStyle(),{stroke:d.get(["axisLine","lineStyle","color"])})),_=0;_<m.length;_++)for(var b=wM(m[_],p.transform,v,x,"minorticks_"+_),w=0;w<b.length;w++)c.add(b[w])}e.get(["axisLabel","hideOverlap"])&&tb($_(V(h,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=wt(t.axisName,e.get("name"));p&&(c=e.get("nameLocation"),l=t.nameDirection,o=e.getModel("nameTextStyle"),u=e.get("nameGap")||0,r=(h=e.axis.getExtent())[0]>h[1]?-1:1,r=["start"===c?h[0]-r*u:"end"===c?h[1]+r*u:(h[0]+h[1])/2,bM(c)?t.labelOffset+l*u:0],null!=(u=e.get("nameRotate"))&&(u=u*fM/180),bM(c)?a=yM.innerTextLayout(t.rotation,null!=u?u:t.rotation,l):(a=function(t,e,n,i){var o,n=Rr(n-t),t=i[0]>i[1],i="start"===e&&!t||"start"!==e&&t;e=Er(n-fM/2)?(o=i?"bottom":"top","center"):Er(n-1.5*fM)?(o=i?"top":"bottom","center"):(o="middle",n<1.5*fM&&fM/2<n?i?"left":"right":i?"right":"left");return{rotation:n,textAlign:e,textVerticalAlign:o}}(t.rotation,c,u||0,h),null!=(s=t.axisNameAvailableWidth)&&(s=Math.abs(s/Math.sin(a.rotation)),isFinite(s)||(s=null))),l=o.getFont(),u=(c=e.get("nameTruncate",!0)||{}).ellipsis,h=wt(t.nameTruncateMaxWidth,c.maxWidth,s),$c({el:t=new K({x:r[0],y:r[1],rotation:a.rotation,silent:yM.isLabelSilent(e),style:ap(o,{text:p,font:l,overflow:"truncate",width:h,ellipsis:u,fill:o.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:o.get("align")||a.textAlign,verticalAlign:o.get("verticalAlign")||a.textVerticalAlign}),z2:1}),componentModel:e,itemName:p}),t.__fullText=p,t.anid="name",e.get("triggerEvent")&&((c=yM.makeAxisEventDataBase(e)).targetType="axisName",c.name=p,$(t).eventData=c),i.add(t),t.updateTransform(),n.add(t),t.decomposeTransform())}};function xM(t){t&&(t.ignore=!0)}function _M(t,e){var n,i=t&&t.getBoundingRect().clone(),o=e&&e.getBoundingRect().clone();if(i&&o)return We(n=Ve([]),n,-t.rotation),i.applyTransform(Fe([],n,t.getLocalTransform())),o.applyTransform(Fe([],n,e.getLocalTransform())),i.intersect(o)}function bM(t){return"middle"===t||"center"===t}function wM(t,e,n,i,o){for(var r=[],a=[],s=[],l=0;l<t.length;l++){var u=t[l].coord,u=(a[0]=u,s[a[1]=0]=u,s[1]=n,e&&(oe(a,a,e),oe(s,s,e)),new Fh({shape:{x1:a[0],y1:a[1],x2:s[0],y2:s[1]},style:i,z2:2,autoBatch:!0,silent:!0}));Bc(u.shape,u.style.lineWidth),u.anid=o+"_"+t[l].tickValue,r.push(u)}return r}function SM(t,e){var h,c,o,p,d,g,r,n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return h=n,e=e,o=(c=t).getComponent("tooltip"),p=c.getComponent("axisPointer"),d=p.get("link",!0)||[],g=[],nt(e.getCoordinateSystems(),function(s){var l,u,t,e,n;function i(t,e,n){var i,o,r=n.model.getModel("axisPointer",p),a=r.get("show");a&&("auto"!==a||t||TM(r))&&(null==e&&(e=r.get("triggerTooltip")),a=(r=t?function(t,e,n,i,o,r){var a=e.getModel("axisPointer"),s={};nt(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){s[t]=S(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||(o=s.lineStyle=a.get("crossStyle"))&&z(e,o.textStyle));return t.model.getModel("axisPointer",new kp(s,n,i))}(n,u,p,c,t,e):r).get("snap"),t=r.get("triggerEmphasis"),i=CM(n.model),o=e||a||"category"===n.type,e=h.axesInfo[i]={key:i,axis:n,coordSys:s,axisPointerModel:r,triggerTooltip:e,triggerEmphasis:t,involveSeries:o,snap:a,useHandle:TM(r),seriesModels:[],linkGroup:null},l[i]=e,h.seriesInvolved=h.seriesInvolved||o,null!=(t=function(t,e){for(var n=e.model,i=e.dim,o=0;o<t.length;o++){var r=t[o]||{};if(MM(r[i+"AxisId"],n.id)||MM(r[i+"AxisIndex"],n.componentIndex)||MM(r[i+"AxisName"],n.name))return o}}(d,n)))&&((a=g[t]||(g[t]={axesInfo:{}})).axesInfo[i]=e,a.mapper=d[t].mapper,e.linkGroup=a)}s.axisPointerEnabled&&(t=CM(s.model),l=h.coordSysAxesInfo[t]={},u=(h.coordSysMap[t]=s).model.getModel("tooltip",o),nt(s.getAxes(),P(i,!1,null)),s.getTooltipAxes)&&o&&u.get("show")&&(t="axis"===u.get("trigger"),e="cross"===u.get(["axisPointer","type"]),n=s.getTooltipAxes(u.get(["axisPointer","axis"])),(t||e)&&nt(n.baseAxes,P(i,!e||"cross",t)),e)&&nt(n.otherAxes,P(i,"cross",!1))}),n.seriesInvolved&&(r=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)&&nt(r.coordSysAxesInfo[CM(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 MM(t,e){return"all"===t||B(t)&&0<=G(t,e)||t===e}function IM(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[CM(t)]}function TM(t){return!!t.get(["handle","show"])}function CM(t){return t.type+"||"+t.id}var DM,AM={},kM=(u(LM,DM=Ky),LM.prototype.render=function(t,e,n,i){var o,r,a,s,l,u;this.axisPointerClass&&(o=IM(o=t))&&(l=o.axisPointerModel,r=o.axis.scale,a=l.option,u=l.get("status"),null!=(s=l.get("value"))&&(s=r.parse(s)),l=TM(l),null==u&&(a.status=l?"show":"hide"),(u=r.getExtent().slice())[0]>u[1]&&u.reverse(),(s=null==s||s>u[1]?u[1]:s)<u[0]&&(s=u[0]),a.value=s,l)&&(a.status=o.axis.scale.isBlank()?"hide":"show"),DM.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,n,!0)},LM.prototype.updateAxisPointer=function(t,e,n,i){this._doUpdateAxisPointerClass(t,n,!1)},LM.prototype.remove=function(t,e){var n=this._axisPointer;n&&n.remove(e)},LM.prototype.dispose=function(t,e){this._disposeAxisPointer(e),DM.prototype.dispose.apply(this,arguments)},LM.prototype._doUpdateAxisPointerClass=function(t,e,n){var i,o=LM.getAxisPointerClass(this.axisPointerClass);o&&((i=(i=IM(i=t))&&i.axisPointerModel)?(this._axisPointer||(this._axisPointer=new o)).render(t,i,e,n):this._disposeAxisPointer(e))},LM.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},LM.registerAxisPointerClass=function(t,e){AM[t]=e},LM.getAxisPointerClass=function(t){return t&&AM[t]},LM.type="axis",LM);function LM(){var t=null!==DM&&DM.apply(this,arguments)||this;return t.type=LM.type,t}var PM=i();function OM(t,e,n,i){var o=n.axis;if(!o.scale.isBlank()){var n=n.getModel("splitArea"),r=n.getModel("areaStyle"),a=r.get("color"),s=i.coordinateSystem.getRect(),l=o.getTicksCoords({tickModel:n,clamp:!0});if(l.length){var u=a.length,h=PM(t).splitAreaColors,c=R(),p=0;if(h)for(var d=0;d<l.length;d++){var g=h.get(l[d].tickValue);if(null!=g){p=(g+(u-1)*d)%u;break}}for(var f=o.toGlobalCoord(l[0].coord),y=r.getAreaStyle(),a=B(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,f=o.isHorizontal()?(v=f,x=s.y,b=s.height,v+(_=m-v)):(v=s.x,x=f,_=s.width,x+(b=m-x)),m=l[d-1].tickValue;null!=m&&c.set(m,p),e.add(new L({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}PM(t).splitAreaColors=c}}}function NM(t){PM(t).splitAreaColors=null}var RM,EM=["axisLine","axisTickLabel","axisName"],zM=["splitArea","splitLine","minorSplitLine"],e=(u(VM,RM=kM),VM.prototype.render=function(i,t,e,n){this.group.removeAll();var o,r,a=this._axisGroup;this._axisGroup=new Z,this.group.add(this._axisGroup),i.get("show")&&(r=rM(o=i.getCoordSysModel(),i),r=new yM(i,F({handleAutoShown:function(t){for(var e=o.coordinateSystem.getCartesians(),n=0;n<e.length;n++)if(X1(e[n].getOtherAxis(i.axis).scale))return!0;return!1}},r)),nt(EM,r.add,r),this._axisGroup.add(r.getGroup()),nt(zM,function(t){i.get([t,"show"])&&FM[t](this,this._axisGroup,i,o)},this),n&&"changeAxisOrder"===n.type&&n.isInitSort||Xc(a,this._axisGroup,i),RM.prototype.render.call(this,i,t,e,n))},VM.prototype.remove=function(){NM(this)},VM.type="cartesianAxis",VM);function VM(){var t=null!==RM&&RM.apply(this,arguments)||this;return t.type=VM.type,t.axisPointerClass="CartesianAxisPointer",t}var BM,FM={splitLine:function(t,e,n,i){var o=n.axis;if(!o.scale.isBlank())for(var n=n.getModel("splitLine"),r=n.getModel("lineStyle"),a=B(a=r.get("color"))?a:[a],s=i.coordinateSystem.getRect(),l=o.isHorizontal(),u=0,h=o.getTicksCoords({tickModel:n}),c=[],p=[],d=r.getLineStyle(),g=0;g<h.length;g++){var f=o.toGlobalCoord(h[g].coord),f=(l?(c[0]=f,c[1]=s.y,p[0]=f,p[1]=s.y+s.height):(c[0]=s.x,c[1]=f,p[0]=s.x+s.width,p[1]=f),u++%a.length),y=h[g].tickValue,y=new Fh({anid:null!=y?"line_"+h[g].tickValue:null,autoBatch:!0,shape:{x1:c[0],y1:c[1],x2:p[0],y2:p[1]},style:z({stroke:a[f]},d),silent:!0});Bc(y.shape,d.lineWidth),e.add(y)}},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),d=(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),new Fh({anid:"minor_line_"+s[c][p].tickValue,autoBatch:!0,shape:{x1:l[0],y1:l[1],x2:u[0],y2:u[1]},style:h,silent:!0}));Bc(d.shape,h.lineWidth),e.add(d)}},splitArea:function(t,e,n,i){OM(t,e,n,i)}},GM=(u(WM,BM=e),WM.type="xAxis",WM);function WM(){var t=null!==BM&&BM.apply(this,arguments)||this;return t.type=WM.type,t}u(XM,HM=e),XM.type="yAxis";var HM,YM=XM;function XM(){var t=null!==HM&&HM.apply(this,arguments)||this;return t.type=GM.type,t}u(jM,UM=Ky),jM.prototype.render=function(t,e){this.group.removeAll(),t.get("show")&&this.group.add(new L({shape:t.coordinateSystem.getRect(),style:z({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},jM.type="grid";var UM,ZM=jM;function jM(){var t=null!==UM&&UM.apply(this,arguments)||this;return t.type="grid",t}var qM={offset:0};function KM(t){t.registerComponentView(ZM),t.registerComponentModel(GS),t.registerCoordinateSystem("cartesian2d",hM),jS(t,"x",YS,qM),jS(t,"y",YS,qM),t.registerComponentView(GM),t.registerComponentView(YM),t.registerPreprocessor(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})})}function $M(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}})})}r(function(t){r(KM),t.registerSeriesModel(AS),t.registerChartView(VS),t.registerLayout(iS("scatter"))});u(tI,JM=Z),tI.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},tI.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=s0(e,-1,-1,2,2,n),s=(a.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5}),-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)}$M(o,t)},tI.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)}$M(n,t)},tI.prototype.highlight=function(){cu(this)},tI.prototype.downplay=function(){pu(this)},tI.prototype.getSymbolType=function(){var t=this.childAt(0);return t&&t.getSymbolType()},tI.prototype.updateData=function(t,e){var n=this,i=t.hostModel,o=(this.childAt(0).updateData(t,e),this.childAt(1)),r=t.getItemModel(e),a=t.getItemVisual(e,"symbol"),s=l0(t.getItemVisual(e,"symbolSize")),l=t.getItemVisual(e,"style"),u=l&&l.fill,l=r.getModel("emphasis"),s=(o.setScale(s),o.traverse(function(t){t.setStyle("fill",u)}),u0(t.getItemVisual(e,"symbolOffset"),s)),s=(s&&(o.x=s[0],o.y=s[1]),t.getItemVisual(e,"symbolRotate")),h=(o.rotation=(s||0)*Math.PI/180||0,{});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"]),"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,Mu(this,l.get("focus"),l.get("blurScope"),l.get("disabled"))},tI.prototype.fadeOut=function(t){t&&t()};var JM,QM=tI;function tI(t,e){var n=JM.call(this)||this,i=new xw(t,e),o=new Z;return n.add(i),n.add(o),n.updateData(t,e),n}u(iI,eI=em),iI.prototype.init=function(){this._symbolDraw=new Iw(QM)},iI.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)},iI.prototype._getClipShape=function(t){var e=t.coordinateSystem,e=e&&e.getArea&&e.getArea();return t.get("clip",!0)?e:null},iI.prototype.updateTransform=function(t,e,n){var i=t.getData(),t=(this.group.dirty(),iS("").reset(t,e,n));t.progress&&t.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout()},iI.prototype._updateGroupTransform=function(t){t=t.coordinateSystem;t&&t.getRoamTransform&&(this.group.transform=Xe(t.getRoamTransform()),this.group.decomposeTransform())},iI.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0)},iI.type="effectScatter";var eI,nI=iI;function iI(){var t=null!==eI&&eI.apply(this,arguments)||this;return t.type=iI.type,t}u(aI,oI=Gy),aI.prototype.getInitialData=function(t,e){return V1(null,this,{useEncodeDefaulter:!0})},aI.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},aI.type="series.effectScatter",aI.dependencies=["grid","polar"],aI.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10};var oI,rI=aI;function aI(){var t=null!==oI&&oI.apply(this,arguments)||this;return t.type=aI.type,t.hasSymbolVisual=!0,t}r(function(t){t.registerChartView(nI),t.registerSeriesModel(rI),t.registerLayout(iS("effectScatter"))});var sI,lI=["color","borderColor"],uI=(u(hI,sI=em),hI.prototype.render=function(t,e,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},hI.prototype.incrementalPrepareRender=function(t,e,n){this._clear(),this._updateDrawMode(t)},hI.prototype.incrementalRender=function(t,e,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,e):this._incrementalRenderNormal(t,e)},hI.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},hI.prototype._updateDrawMode=function(t){t=t.pipelineContext.large;null!=this._isLargeDraw&&t===this._isLargeDraw||(this._isLargeDraw=t,this._clear())},hI.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&&yI(u,e)||(_c(n=fI(e,0,!0),{shape:{points:e.ends}},i,t),mI(n,o,t,s),a.add(n),o.setItemGraphicEl(t,n)))}).update(function(t,e){var n,e=r.getItemGraphicEl(e);!o.hasValue(t)||(n=o.getItemLayout(t),l&&yI(u,n))?a.remove(e):(e?(C(e,{shape:{points:n.ends}},i,t),Ic(e)):e=fI(n),mI(e,o,t,s),a.add(e),o.setItemGraphicEl(t,e))}).remove(function(t){t=r.getItemGraphicEl(t);t&&a.remove(t)}).execute(),this._data=o},hI.prototype._renderLarge=function(t){this._clear(),wI(t,this.group);t=t.get("clip",!0)?Eb(t.coordinateSystem,!1,t):null;t?this.group.setClipPath(t):this.group.removeClipPath()},hI.prototype._incrementalRenderNormal=function(t,e){for(var n,i=e.getData(),o=i.getLayout("isSimpleBox");null!=(n=t.next());){var r=fI(i.getItemLayout(n));mI(r,i,n,o),r.incremental=!0,this.group.add(r),this._progressiveEls.push(r)}},hI.prototype._incrementalRenderLarge=function(t,e){wI(e,this.group,this._progressiveEls,!0)},hI.prototype.remove=function(t){this._clear()},hI.prototype._clear=function(){this.group.removeAll(),this._data=null},hI.type="candlestick",hI);function hI(){var t=null!==sI&&sI.apply(this,arguments)||this;return t.type=hI.type,t}var cI,pI=function(){},dI=(u(gI,cI=q),gI.prototype.getDefaultShape=function(){return new pI},gI.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]))},gI);function gI(t){t=cI.call(this,t)||this;return t.type="normalCandlestickBox",t}function fI(t,e,n){var i,o=t.ends;return new dI({shape:{points:n?(i=t,V(o,function(t){return(t=t.slice())[1]=i.initBaseline,t})):o},z2:100})}function yI(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 mI(t,e,n,i){var o=e.getItemModel(n);t.useStyle(e.getItemVisual(n,"style")),t.style.strokeNoScale=!0,t.__simpleBox=i,Du(t,o)}var vI,xI=function(){},_I=(u(bI,vI=q),bI.prototype.getDefaultShape=function(){return new xI},bI.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},bI);function bI(t){t=vI.call(this,t)||this;return t.type="largeCandlestickBox",t}function wI(t,e,n,i){var o=t.getData().getLayout("largePoints"),r=new _I({shape:{points:o},__sign:1,ignoreCoarsePointer:!0}),a=(e.add(r),new _I({shape:{points:o},__sign:-1,ignoreCoarsePointer:!0})),o=(e.add(a),new _I({shape:{points:o},__sign:0,ignoreCoarsePointer:!0}));e.add(o),SI(1,r,t),SI(-1,a,t),SI(0,o,t),i&&(r.incremental=!0,a.incremental=!0),n&&n.push(r,a)}function SI(t,e,n){var i=n.get(["itemStyle",0<t?"borderColor":"borderColor0"])||n.get(["itemStyle",0<t?"color":"color0"]),t=(0===t&&(i=n.get(["itemStyle","borderColorDoji"])),n.getModel("itemStyle").getItemStyle(lI));e.useStyle(t),e.style.fill=null,e.style.stroke=i}MI.prototype.getInitialData=function(t,e){var n,i,o=e.getComponent("xAxis",this.get("xAxisIndex")),e=e.getComponent("yAxis",this.get("yAxisIndex")),r=o.get("type"),a=e.get("type"),r=("category"===r?(t.layout="horizontal",n=o.getOrdinalMeta(),l=!0):"category"===a?(t.layout="vertical",n=e.getOrdinalMeta(),l=!0):t.layout=t.layout||"horizontal",["x","y"]),a="horizontal"===t.layout?0:1,s=this._baseAxisDim=r[a],r=r[1-a],o=[o,e],e=o[a].get("type"),o=o[1-a].get("type"),a=t.data,l=(a&&l&&(i=[],nt(a,function(t,e){var n;B(t)?(n=t.slice(),t.unshift(e)):B(t.value)?((n=F({},t)).value=n.value.slice(),t.value.unshift(e)):n=t,i.push(n)}),t.data=i),this.defaultValueDimensions),a=[{name:s,type:u1(e),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:r,type:u1(o),dimsDef:l.slice()}];return bS(this,{coordDimensions:a,dimensionsCount:l.length+1,encodeDefaulter:P(ng,a,this)})},MI.prototype.getBaseAxis=function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis};Ia=MI;function MI(){}u(CI,II=Gy),CI.prototype.getShadowDim=function(){return"open"},CI.prototype.brushSelector=function(t,e,n){e=e.getItemLayout(t);return e&&n.rect(e.brushRect)},CI.type="series.candlestick",CI.dependencies=["xAxis","yAxis","grid"],CI.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300};var II,TI=CI;function CI(){var t=null!==II&&II.apply(this,arguments)||this;return t.type=CI.type,t.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],t}function DI(t){t&&B(t.series)&&nt(t.series,function(t){O(t)&&"k"===t.type&&(t.type="candlestick")})}ut(TI,Ia,!0);var AI=["itemStyle","borderColor"],kI=["itemStyle","borderColor0"],LI=["itemStyle","borderColorDoji"],PI=["itemStyle","color"],OI=["itemStyle","color0"],NI={seriesType:"candlestick",plan:Jy(),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?PI:OI),r.stroke=(o=o,i.get(0===o?LI:0<o?AI:kI)||r.fill),F(e.ensureUniqueItemVisual(n,"style"),r)}}}}},RI={seriesType:"candlestick",plan:Jy(),reset:function(g){var t,e,m=g.coordinateSystem,n=g.getData(),v=(t=n,o="category"===(o=(i=g).getBaseAxis()).type?o.getBandWidth():(o=o.getExtent(),Math.abs(o[1]-o[0])/t.count()),t=j(N(i.get("barMaxWidth"),o),o),e=j(N(i.get("barMinWidth"),1),o),null!=(i=i.get("barWidth"))?j(i,o):Math.max(Math.min(o/2,t),e)),i=["x","y"],x=n.getDimensionIndex(n.mapDimension(i[0])),o=V(n.mapDimensionsAll(i[1]),n.getDimensionIndex,n),_=o[0],b=o[1],w=o[2],S=o[3];if(n.setLayout({candleWidth:v,isSimpleBox:v<=1.3}),!(x<0||o.length<4))return{progress:g.pipelineContext.large?function(t,e){var n,i=lx(4*t.count),o=0,r=[],a=[],s=e.getStore(),l=!!g.get(["itemStyle","borderColorDoji"]);for(;null!=(n=t.next());){var u=s.get(x,n),h=s.get(_,n),c=s.get(b,n),p=s.get(w,n),d=s.get(S,n);isNaN(u)||isNaN(p)||isNaN(d)?(i[o++]=NaN,o+=3):(i[o++]=EI(s,n,h,c,b,l),r[0]=u,r[1]=p,n=m.dataToPoint(r,null,a),i[o++]=n?n[0]:NaN,i[o++]=n?n[1]:NaN,r[1]=d,n=m.dataToPoint(r,null,a),i[o++]=n?n[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),u=g(u,o),h=g(h,o),c=g(s,o),p=g(l,o),d=[];f(d,h,0),f(d,u,1),d.push(y(p),y(h),y(c),y(u));p=!!e.getItemModel(n).get(["itemStyle","borderColorDoji"]);e.setItemLayout(n,{sign:EI(i,n,r,a,b,p),initBaseline:(a<r?h:u)[1],ends:d,brushRect:function(t,e,n){t=g(t,n),e=g(e,n);return t[0]-=v/2,e[0]-=v/2,{x:t[0],y:t[1],width:v,height:e[1]-t[1]}}(s,l,o)})}function g(t,e){var n=[];return n[0]=e,n[1]=t,isNaN(e)||isNaN(t)?[NaN,NaN]:m.dataToPoint(n)}function f(t,e,n){var i=e.slice(),e=e.slice();i[0]=Fc(i[0]+v/2,1,!1),e[0]=Fc(e[0]-v/2,1,!0),n?t.push(i,e):t.push(e,i)}function y(t){return t[0]=Fc(t[0],1),t}}}}};function EI(t,e,n,i,o,r){n=i<n?-1:n<i?1:r?0:!(0<e)||t.get(o,e-1)<=i?1:-1;return n}function zI(t){t.eachSeriesByType("radar",function(t){var e,i=t.getData(),o=[],r=t.coordinateSystem;r&&(nt(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:BI(r)})}),i.each(function(t){var e=dt(o[t],VI)||BI(r);o[t].push(e.slice()),i.setItemLayout(t,o[t])}))})}function VI(t){return!isNaN(t[0])&&!isNaN(t[1])}function BI(t){return[t.cx,t.cy]}function FI(n){var i,t=n.polar;t&&(B(t)||(t=[t]),i=[],nt(t,function(t,e){(t.indicator?(t.type&&!t.shape&&(t.shape=t.type),n.radar=n.radar||[],B(n.radar)||(n.radar=[n.radar]),n.radar):i).push(t)}),n.polar=i),nt(n.series,function(t){t&&"radar"===t.type&&t.polarIndex&&(t.radarIndex=t.polarIndex)})}r(function(t){t.registerChartView(uI),t.registerSeriesModel(TI),t.registerPreprocessor(DI),t.registerVisual(NI),t.registerLayout(RI)});u(HI,GI=em),HI.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){var n,i=t.getItemVisual(e,"symbol")||"circle";if("none"!==i)return n=l0(t.getItemVisual(e,"symbolSize")),i=s0(i,-1,-1,2,2),t=t.getItemVisual(e,"symbolRotate")||0,i.attr({style:{strokeNoScale:!0},z2:100,scaleX:n[0]/2,scaleY:n[1]/2,rotation:t*Math.PI/180||0}),i}(i,o);s&&(t[s.__dimIdx=a]?(s.setPosition(t[a]),tp[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 V(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 Lh,n=new Rh,i={shape:{points:r}},e.shape.points=u(r),n.shape.points=u(r),_c(e,i,l,t),_c(n,i,l,t),i=new Z,o=new Z,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 e=a.getItemGraphicEl(e),n=e.childAt(0),i=e.childAt(1),o=e.childAt(2),r={shape:{points:c.getItemLayout(t)}};r.shape.points&&(s(n.shape.points,r.shape.points,o,c,t,!1),Ic(i),Ic(n),C(n,r,l),C(i,r,l),c.setItemGraphicEl(t,e))}).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,e=(h.add(t),e.useStyle(z(i.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:s})),Du(e,i,"lineStyle"),Du(o,i,"areaStyle"),i.getModel("areaStyle")),l=e.isEmpty()&&e.parentModel.isEmpty(),e=(o.ignore=l,nt(["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})),i.getModel("emphasis")),u=e.getModel("itemStyle").getItemStyle();r.eachChild(function(t){t instanceof ll?(e=t.style,t.useStyle(F({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=S(u);var e=c.getStore().get(c.getDimensionIndex(t.__dimIdx),n);null!=e&&!isNaN(e)||(e=""),op(t,rp(i),{labelFetcher:c.hostModel,labelDataIndex:n,labelDimIndex:t.__dimIdx,defaultText:e,inheritColor:s,defaultOpacity:a.opacity})}),Mu(t,e.get("focus"),e.get("blurScope"),e.get("disabled"))}),this._data=c},HI.prototype.remove=function(){this.group.removeAll(),this._data=null},HI.type="radar";var GI,WI=HI;function HI(){var t=null!==GI&&GI.apply(this,arguments)||this;return t.type=HI.type,t}u(UI,YI=Gy),UI.prototype.init=function(t){YI.prototype.init.apply(this,arguments),this.legendVisualProvider=new wS(T(this.getData,this),T(this.getRawData,this))},UI.prototype.getInitialData=function(t,e){return bS(this,{generateCoord:"indicator_",generateCoordCount:1/0})},UI.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=Oy(this,n);return Iy("section",{header:r,sortBlocks:!0,blocks:V(o,function(t){var e=i.get(i.mapDimension(t.dim),n);return Iy("nameValue",{markerType:"subItem",markerColor:a,name:t.name,value:e,sortParam:e})})})},UI.prototype.getTooltipPosition=function(t){if(null!=t)for(var e,n=this.getData(),i=this.coordinateSystem,o=n.getValues(V(i.dimensions,function(t){return n.mapDimension(t)}),t),r=0,a=o.length;r<a;r++)if(!isNaN(o[r]))return e=i.getIndicatorAxes(),i.coordToPoint(e[r].dataToCoord(o[r]),r)},UI.type="series.radar",UI.dependencies=["radar"],UI.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8};var YI,XI=UI;function UI(){var t=null!==YI&&YI.apply(this,arguments)||this;return t.type=UI.type,t.hasSymbolVisual=!0,t}$m=US.value;function ZI(t,e){return z({show:e},t)}u(KI,jI=g),KI.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=V(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,t=(null!=t.color&&(e=z({color:t.color},l)),d(S(t),{boundaryGap:n,splitNumber:i,scale:o,axisLine:r,axisTick:a,axisLabel:s,name:t.text,showName:u,nameLocation:"end",nameGap:c,nameTextStyle:e,triggerEvent:p},!1)),e=(H(h)?(e=t.name,t.name=h.replace("{value}",null!=e?e:"")):D(h)&&(t.name=h(t.name,t)),new kp(t,null,this.ecModel));return ut(e,$x.prototype),e.mainType="radar",e.componentIndex=this.componentIndex,e},this);this._indicatorModels=t},KI.prototype.getIndicatorModels=function(){return this._indicatorModels},KI.type="radar",KI.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:d({lineStyle:{color:"#bbb"}},$m.axisLine),axisLabel:ZI($m.axisLabel,!1),axisTick:ZI($m.axisTick,!1),splitLine:ZI($m.splitLine,!0),splitArea:ZI($m.splitArea,!0),indicator:[]};var jI,qI=KI;function KI(){var t=null!==jI&&jI.apply(this,arguments)||this;return t.type=KI.type,t}var $I,JI=["axisLine","axisTickLabel","axisName"],QI=(u(t2,$I=Ky),t2.prototype.render=function(t,e,n){this.group.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},t2.prototype._buildAxes=function(t){var n=t.coordinateSystem;nt(V(n.getIndicatorAxes(),function(t){var e=t.model.get("showName")?t.name:"";return new yM(t.model,{axisName:e,position:[n.cx,n.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})}),function(t){nt(JI,t.add,t),this.group.add(t.getGroup())},this)},t2.prototype._buildSplitLineAndArea=function(t){var n=t.coordinateSystem,e=n.getIndicatorAxes();if(e.length){var i=t.get("shape"),o=t.getModel("splitLine"),t=t.getModel("splitArea"),r=o.getModel("lineStyle"),a=t.getModel("areaStyle"),s=o.get("show"),l=t.get("show"),o=r.get("color"),t=a.get("color"),u=B(o)?o:[o],h=B(t)?t:[t],c=[],p=[];if("circle"===i)for(var d=e[0].getTicksCoords(),g=n.cx,f=n.cy,y=0;y<d.length;y++)s&&c[M(c,u,y)].push(new eh({shape:{cx:g,cy:f,r:d[y].coord}})),l&&y<d.length-1&&p[M(p,h,y)].push(new Th({shape:{cx:g,cy:f,r0:d[y].coord,r:d[y+1].coord}}));else for(var m,v=V(e,function(t,e){t=t.getTicksCoords();return m=null==m?t.length-1:Math.min(t.length-1,m),V(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 Rh({shape:{points:_}})),l&&x&&p[M(p,h,y-1)].push(new Lh({shape:{points:_.concat(x)}})),x=_.slice().reverse()}var w=r.getLineStyle(),S=a.getAreaStyle();nt(p,function(t,e){this.group.add(zc(t,{style:z({stroke:"none",fill:h[e%h.length]},S),silent:!0}))},this),nt(c,function(t,e){this.group.add(zc(t,{style:z({fill:"none",stroke:u[e%u.length]},w),silent:!0}))},this)}function M(t,e,n){n%=e.length;return t[n]=t[n]||[],n}},t2.type="radar",t2);function t2(){var t=null!==$I&&$I.apply(this,arguments)||this;return t.type=t2.type,t}u(i2,e2=Ip);var e2,n2=i2;function i2(t,e,n){t=e2.call(this,t,e,n)||this;return t.type="value",t.angle=0,t.name="",t}r2.prototype.getIndicatorAxes=function(){return this._indicatorAxes},r2.prototype.dataToPoint=function(t,e){var n=this._indicatorAxes[e];return this.coordToPoint(n.dataToCoord(t),e)},r2.prototype.coordToPoint=function(t,e){e=this._indicatorAxes[e].angle;return[this.cx+t*Math.cos(e),this.cy-t*Math.sin(e)]},r2.prototype.pointToData=function(t){for(var e,n=t[0]-this.cx,t=t[1]-this.cy,i=Math.sqrt(n*n+t*t),o=(n/=i,t/=i,Math.atan2(-t,n)),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&&(e=l,a=s,r=u)}return[a,+(e&&e.coordToData(i))]},r2.prototype.resize=function(t,e){var n=t.get("center"),i=e.getWidth(),e=e.getHeight(),o=Math.min(i,e)/2,i=(this.cx=j(n[0],i),this.cy=j(n[1],e),this.startAngle=t.get("startAngle")*Math.PI/180,t.get("radius"));(H(i)||Y(i))&&(i=[0,i]),this.r0=j(i[0],o),this.r=j(i[1],o),nt(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)},r2.prototype.update=function(i,t){var o=this._indicatorAxes,r=this._model,e=(nt(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(),nt(o,function(t){t.scale.unionExtentFromData(n,n.mapDimension(t.dim))}))},this),r.get("splitNumber")),n=new ox;n.setExtent(0,e),n.setInterval(1),nt(o,function(t,e){uM(t.scale,t.model,n)})},r2.prototype.convertToPixel=function(t,e,n){return console.warn("Not implemented."),null},r2.prototype.convertFromPixel=function(t,e,n){return console.warn("Not implemented."),null},r2.prototype.containPoint=function(t){return console.warn("Not implemented."),!1},r2.create=function(t,n){var i=[];return t.eachComponent("radar",function(t){var e=new r2(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},r2.dimensions=[];var o2=r2;function r2(t,e,n){this.dimensions=[],this._model=t,this._indicatorAxes=V(t.getIndicatorModels(),function(t,e){var e="indicator_"+e,n=new n2(e,new ox);return n.name=t.get("name"),(n.model=t).axis=n,this.dimensions.push(e),n},this),this.resize(t,n)}function a2(t){t.registerCoordinateSystem("radar",o2),t.registerComponentModel(qI),t.registerComponentView(QI),t.registerVisual({seriesType:"radar",reset:function(t){var e=t.getData();e.each(function(t){e.setItemVisual(t,"legendIcon","roundRect")}),e.setVisual("legendIcon","roundRect")}})}r(function(t){r(a2),t.registerChartView(WI),t.registerSeriesModel(XI),t.registerLayout(zI),t.registerProcessor(uS("radar")),t.registerPreprocessor(FI)});l2.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],g=d[0],f=d[1],y=i(d[2]);h.globalAlpha=y,h.drawImage(a,g-u,f-u)}if(o.width&&o.height){for(var e=h.getImageData(0,0,o.width,o.height),m=e.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}h.putImageData(e,0,0)}return o},l2.prototype._getBrush=function(){var t=this._brushCanvas||(this._brushCanvas=Q.createCanvas()),e=this.pointSize+this.blurSize,n=2*e,i=(t.width=n,t.height=n,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},l2.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};var s2=l2;function l2(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var t=Q.createCanvas();this.canvas=t}function u2(t){t=t.dimensions;return"lng"===t[0]&&"lat"===t[1]}u(p2,h2=em),p2.prototype.render=function(n,t,e){t.eachComponent("visualMap",function(e){e.eachTargetSeries(function(t){t===n&&(i=e)})}),this._progressiveEls=null,this.group.removeAll();var i,t=n.coordinateSystem;"cartesian2d"===t.type||"calendar"===t.type?this._renderOnCartesianAndCalendar(n,e,0,n.getData().count()):u2(t)&&this._renderOnGeo(t,n,i,e)},p2.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll()},p2.prototype.incrementalRender=function(t,e,n,i){var o=e.coordinateSystem;o&&(u2(o)?this.render(e,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(e,i,t.start,t.end,!0)))},p2.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},p2.prototype._renderOnCartesianAndCalendar=function(t,e,n,i,o){for(var r,a,s,l,u,h=t.coordinateSystem,c=Gb(h,"cartesian2d"),p=(c&&(x=h.getAxis("x"),r=h.getAxis("y"),a=x.getBandWidth()+.5,s=r.getBandWidth()+.5,l=x.scale.getExtent(),u=r.scale.getExtent()),this.group),d=t.getData(),g=t.getModel(["emphasis","itemStyle"]).getItemStyle(),f=t.getModel(["blur","itemStyle"]).getItemStyle(),y=t.getModel(["select","itemStyle"]).getItemStyle(),m=t.get(["itemStyle","borderRadius"]),v=rp(t),x=t.getModel("emphasis"),_=x.get("focus"),b=x.get("blurScope"),w=x.get("disabled"),S=c?[d.mapDimension("x"),d.mapDimension("y"),d.mapDimension("value")]:[d.mapDimension("time"),d.mapDimension("value")],M=n;M<i;M++){var I=void 0,T=d.getItemVisual(M,"style");if(c){var C=d.get(S[0],M),D=d.get(S[1],M);if(isNaN(d.get(S[2],M))||isNaN(C)||isNaN(D)||C<l[0]||C>l[1]||D<u[0]||D>u[1])continue;var C=h.dataToPoint([C,D]),I=new L({shape:{x:C[0]-a/2,y:C[1]-s/2,width:a,height:s},style:T})}else{if(isNaN(d.get(S[1],M)))continue;I=new L({z2:1,shape:h.dataToRect([d.get(S[0],M)]).contentShape,style:T})}d.hasItemOption&&(g=(C=(D=d.getItemModel(M)).getModel("emphasis")).getModel("itemStyle").getItemStyle(),f=D.getModel(["blur","itemStyle"]).getItemStyle(),y=D.getModel(["select","itemStyle"]).getItemStyle(),m=D.get(["itemStyle","borderRadius"]),_=C.get("focus"),b=C.get("blurScope"),w=C.get("disabled"),v=rp(D)),I.shape.r=m;var A=t.getRawValue(M),k="-";A&&null!=A[2]&&(k=A[2]+""),op(I,v,{labelFetcher:t,labelDataIndex:M,defaultOpacity:T.opacity,defaultText:k}),I.ensureState("emphasis").style=g,I.ensureState("blur").style=f,I.ensureState("select").style=y,Mu(I,_,b,w),(I.incremental=o)&&(I.states.emphasis.hoverLayer=!0),p.add(I),d.setItemGraphicEl(M,I),this._progressiveEls&&this._progressiveEls.push(I)}},p2.prototype._renderOnGeo=function(i,t,e,n){var o,r,a,s,l,u,h,c=e.targetVisuals.inRange,p=e.targetVisuals.outOfRange,d=t.getData(),g=this._hmLayer||this._hmLayer||new s2,t=(g.blurSize=t.get("blurSize"),g.pointSize=t.get("pointSize"),g.minOpacity=t.get("minOpacity"),g.maxOpacity=t.get("maxOpacity"),i.getViewRect().clone()),f=i.getRoamTransform(),y=(t.applyTransform(f),Math.max(t.x,0)),m=Math.max(t.y,0),f=Math.min(t.width+t.x,n.getWidth()),t=Math.min(t.height+t.y,n.getHeight()),n=f-y,f=t-m,t=[d.mapDimension("lng"),d.mapDimension("lat"),d.mapDimension("value")],d=d.mapArray(t,function(t,e,n){t=i.dataToPoint([t,e]);return t[0]-=y,t[1]-=m,t.push(n),t}),t=e.getExtent(),v="visualMap.continuous"===e.type?(h=e.option.range,v=t[1]-t[0],h=[(h[0]-t[0])/v,(h[1]-t[0])/v],function(t){return t>=h[0]&&t<=h[1]}):(o=t,r=e.getPieceList(),a=e.option.selected,s=o[1]-o[0],l=(r=V(r,function(t){return{interval:[(t.interval[0]-o[0])/s,(t.interval[1]-o[0])/s]}})).length,u=0,function(t){for(var e,n=u;n<l;n++)if((e=r[n].interval)[0]<=t&&t<=e[1]){u=n;break}if(n===l)for(n=u-1;0<=n;n--)if((e=r[n].interval)[0]<=t&&t<=e[1]){u=n;break}return 0<=n&&n<l&&a[n]}),t=(g.update(d,n,f,c.color.getNormalizer(),{inRange:c.color.getColorMapper(),outOfRange:p.color.getColorMapper()},v),new ll({style:{width:n,height:f,x:y,y:m,image:g.canvas},silent:!0}));this.group.add(t)},p2.type="heatmap";var h2,c2=p2;function p2(){var t=null!==h2&&h2.apply(this,arguments)||this;return t.type=p2.type,t}u(f2,d2=Gy),f2.prototype.getInitialData=function(t,e){return V1(null,this,{generateCoord:"value"})},f2.prototype.preventIncremental=function(){var t=Tg.get(this.get("coordinateSystem"));if(t&&t.dimensions)return"lng"===t.dimensions[0]&&"lat"===t.dimensions[1]},f2.type="series.heatmap",f2.dependencies=["grid","geo","calendar"],f2.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:"#212121"}}};var d2,g2=f2;function f2(){var t=null!==d2&&d2.apply(this,arguments)||this;return t.type=f2.type,t}function y2(t,e){var n=t.isExpand?t.children:[],i=t.parentNode.children,o=t.hierNode.i?i[t.hierNode.i-1]:null;if(n.length){for(var r=t.children,a=r.length,s=0,l=0;0<=--a;){var u=r[a];u.hierNode.prelim+=s,u.hierNode.modifier+=s,l+=u.hierNode.change,s+=u.hierNode.shift+l}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}else 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=_2(s),r=b2(r),s&&r;){o=_2(o),a=b2(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&&!_2(o)&&(o.hierNode.thread=s,o.hierNode.modifier+=c-l),r&&!b2(a)&&(a.hierNode.thread=r,a.hierNode.modifier+=u-h,n=t)}return n}(t,o,t.parentNode.hierNode.defaultAncestor||i[0],e)}function m2(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function v2(t){return arguments.length?t:w2}function x2(t,e){return t-=Math.PI/2,{x:e*Math.cos(t),y:e*Math.sin(t)}}function _2(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function b2(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function w2(t,e){return t.parentNode===e.parentNode?1:2}r(function(t){t.registerChartView(c2),t.registerSeriesModel(g2)});var S2,M2=oe,I2=(u(T2,S2=Yo),T2.prototype.setBoundingRect=function(t,e,n,i){return this._rect=new U(t,e,n,i),this._rect},T2.prototype.getBoundingRect=function(){return this._rect},T2.prototype.setViewRect=function(t,e,n,i){this._transformTo(t,e,n,i),this._viewRect=new U(t,e,n,i)},T2.prototype._transformTo=function(t,e,n,i){var o=this.getBoundingRect(),r=this._rawTransformable,o=(r.transform=o.calculateTransform(new U(t,e,n,i)),r.parent);r.parent=null,r.decomposeTransform(),r.parent=o,this._updateTransform()},T2.prototype.setCenter=function(t,e){t&&(this._center=[j(t[0],e.getWidth()),j(t[1],e.getHeight())],this._updateCenterAndZoom())},T2.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()},T2.prototype.getDefaultCenter=function(){var t=this.getBoundingRect();return[t.x+t.width/2,t.y+t.height/2]},T2.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},T2.prototype.getZoom=function(){return this._zoom||1},T2.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},T2.prototype._updateCenterAndZoom=function(){var t=this._rawTransformable.getLocalTransform(),e=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),o=this.getZoom(),i=oe([],i,t),n=oe([],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()},T2.prototype._updateTransform=function(){var t=this._roamTransformable,e=this._rawTransformable;(e.parent=t).updateTransform(),e.updateTransform(),Be(this.transform||(this.transform=[]),e.transform||ze()),this._rawTransform=e.getLocalTransform(),this.invTransform=this.invTransform||[],Ye(this.invTransform,this.transform),this.decomposeTransform()},T2.prototype.getTransformInfo=function(){var t=this._rawTransformable,e=this._roamTransformable,n=new Yo;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}}},T2.prototype.getViewRect=function(){return this._viewRect},T2.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},T2.prototype.dataToPoint=function(t,e,n){e=e?this._rawTransform:this.transform;return n=n||[],e?M2(n,t,e):Ht(n,t)},T2.prototype.pointToData=function(t){var e=this.invTransform;return e?M2([],t,e):[t[0],t[1]]},T2.prototype.convertToPixel=function(t,e,n){e=C2(e);return e===this?e.dataToPoint(n):null},T2.prototype.convertFromPixel=function(t,e,n){e=C2(e);return e===this?e.pointToData(n):null},T2.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},T2.dimensions=["x","y"],T2);function T2(t){var e=S2.call(this)||this;return e.type="view",e.dimensions=["x","y"],e._roamTransformable=new Yo,e._rawTransformable=new Yo,e.name=t,e}function C2(t){t=t.seriesModel;return t?t.coordinateSystem:null}function D2(t,e,n){t=t.target;t.x+=e,t.y+=n,t.dirty()}function A2(t,e,n,i){var o=t.target,r=t.zoomLimit,a=t.zoom=t.zoom||1,r=(a*=e,r&&(e=r.min||0,r=r.max||1/0,a=Math.max(Math.min(r,a),e)),a/t.zoom);t.zoom=a,o.x-=(n-o.x)*(r-1),o.y-=(i-o.y)*(r-1),o.scaleX*=r,o.scaleY*=r,o.dirty()}var k2="\0_ec_interaction_mutex";function L2(t,e){return P2(t)[e]}function P2(t){return t[k2]||(t[k2]={})}Uv({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},Bt);u(R2,O2=ce),R2.prototype.isDragging=function(){return this._dragging},R2.prototype.isPinching=function(){return this._pinching},R2.prototype.setPointerChecker=function(t){this.pointerChecker=t},R2.prototype.dispose=function(){this.disable()},R2.prototype._mousedownHandler=function(t){if(!Pe(t)){for(var e=t.target;e;){if(e.draggable)return;e=e.__hostTarget||e.parent}var n=t.offsetX,i=t.offsetY;this.pointerChecker&&this.pointerChecker(t,n,i)&&(this._x=n,this._y=i,this._dragging=!0)}},R2.prototype._mousemoveHandler=function(t){var e,n,i,o,r,a;this._dragging&&V2("moveOnMouseMove",t,this._opt)&&"pinch"!==t.gestureEvent&&!L2(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&&Le(t.event),z2(this,"pan","moveOnMouseMove",t,{dx:r,dy:a,oldX:i,oldY:o,newX:e,newY:n,isAvailableBehavior:null}))},R2.prototype._mouseupHandler=function(t){Pe(t)||(this._dragging=!1)},R2.prototype._mousewheelHandler=function(t){var e=V2("zoomOnMouseWheel",t,this._opt),n=V2("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,o=Math.abs(i),r=t.offsetX,a=t.offsetY;0!==i&&(e||n)&&(e&&(e=3<o?1.4:1<o?1.2:1.1,E2(this,"zoom","zoomOnMouseWheel",t,{scale:0<i?e:1/e,originX:r,originY:a,isAvailableBehavior:null})),n)&&E2(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(0<i?1:-1)*(3<(o=Math.abs(i))?.4:1<o?.15:.05),originX:r,originY:a,isAvailableBehavior:null})},R2.prototype._pinchHandler=function(t){L2(this._zr,"globalPan")||E2(this,"zoom",null,t,{scale:1<t.pinchScale?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})};var O2,N2=R2;function R2(n){var t=O2.call(this)||this,i=(t._zr=n,T(t._mousedownHandler,t)),o=T(t._mousemoveHandler,t),r=T(t._mouseupHandler,t),a=T(t._mousewheelHandler,t),s=T(t._pinchHandler,t);return t.enable=function(t,e){this.disable(),this._opt=z(S(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 E2(t,e,n,i,o){t.pointerChecker&&t.pointerChecker(i,o.originX,o.originY)&&(Le(i.event),z2(t,e,n,i,o))}function z2(t,e,n,i,o){o.isAvailableBehavior=T(V2,null,n,i),t.trigger(e,o)}function V2(t,e,n){n=n[t];return!t||n&&(!H(n)||e.event[n+"Key"])}var B2={axisPointer:1,tooltip:1,brush:1};function F2(t,e,n){e=e.getComponentByElement(t.topTarget),t=e&&e.coordinateSystem;return e&&e!==n&&!B2.hasOwnProperty(e.mainType)&&t&&t.model!==n}var G2,W2=function(){this.parentPoint=[],this.childPoints=[]},H2=(u(Y2,G2=q),Y2.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},Y2.prototype.getDefaultShape=function(){return new W2},Y2.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)t.moveTo(o[0],o[1]),t.lineTo(r[0],r[1]);else{var s=e.orient,l="TB"===s||"BT"===s?0:1,s=1-l,e=j(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])}}},Y2);function Y2(t){return G2.call(this,t)||this}u(Z2,X2=em),Z2.prototype.init=function(t,e){this._controller=new N2(e.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},Z2.prototype.render=function(i,t,n){var o=i.getData(),e=i.layoutInfo,r=this._mainGroup,a=("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,n),this._updateController(i,t,n),this._data);o.diff(a).add(function(t){j2(o,t)&&q2(o,t,null,r,i)}).update(function(t,e){var n=a.getItemGraphicEl(e);j2(o,t)?q2(o,t,n,r,i):n&&J2(a,e,n,r,i)}).remove(function(t){var e=a.getItemGraphicEl(t);e&&J2(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},Z2.prototype._updateViewCoordSys=function(t,e){var n=t.getData(),i=[],o=(n.each(function(t){t=n.getItemLayout(t);!t||isNaN(t.x)||isNaN(t.y)||i.push([+t.x,+t.y])}),[]),r=[],a=(ps(i,o,r),this._min),s=this._max,a=(r[0]-o[0]==0&&(o[0]=a?a[0]:o[0]-1,r[0]=s?s[0]:r[0]+1),r[1]-o[1]==0&&(o[1]=a?a[1]:o[1]-1,r[1]=s?s[1]:r[1]+1),t.coordinateSystem=new I2);a.zoomLimit=t.get("scaleLimit"),a.setBoundingRect(o[0],o[1],r[0]-o[0],r[1]-o[1]),a.setCenter(t.get("center"),e),a.setZoom(t.get("zoom")),this.group.attr({x:a.x,y:a.y,scaleX:a.scaleX,scaleY:a.scaleY}),this._min=o,this._max=r},Z2.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)&&!F2(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){D2(i,t.dx,t.dy),r.dispatchAction({seriesId:o.id,type:"treeRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){A2(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()})},Z2.prototype._updateNodeAndLinkScale=function(t){var e=t.getData(),n=this._getNodeGlobalScale(t);e.eachItemGraphicEl(function(t,e){t.setSymbolScale(n)})},Z2.prototype._getNodeGlobalScale=function(t){var e,n,t=t.coordinateSystem;return"view"!==t.type?1:(e=this._nodeScaleRatio,n=t.scaleX||1,((t.getZoom()-1)*e+1)/n)},Z2.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},Z2.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},Z2.type="tree";var X2,U2=Z2;function Z2(){var t=null!==X2&&X2.apply(this,arguments)||this;return t.type=Z2.type,t._mainGroup=new Z,t}function j2(t,e){t=t.getItemLayout(e);return t&&!isNaN(t.x)&&!isNaN(t.y)}function q2(n,t,i,e,o){var r=!i,a=n.tree.getNodeByDataIndex(t),s=a.getModel(),l=a.getVisual("style").fill,l=!1===a.isExpand&&0!==a.children.length?l:"#fff",u=n.tree.root,h=a.parentNode!==u&&a.parentNode||a,c=n.getItemGraphicEl(h.dataIndex),h=h.getLayout(),c=c?{x:c.__oldX,y:c.__oldY,rawX:c.__radialOldRawX,rawY:c.__radialOldRawY}:h,p=a.getLayout(),r=(r?((i=new xw(n,t,null,{symbolInnerColor:l,useNameLabel:!0})).x=c.x,i.y=c.y):i.updateData(n,t,null,{symbolInnerColor:l,useNameLabel:!0}),i.__radialOldRawX=i.__radialRawX,i.__radialOldRawY=i.__radialRawY,i.__radialRawX=p.rawX,i.__radialRawY=p.rawY,e.add(i),n.setItemGraphicEl(t,i),i.__oldX=i.x,i.__oldY=i.y,C(i,{x:p.x,y:p.y},o),i.getSymbolPath()),r=("radial"===o.get("layout")&&(t=(l=u.children[0]).getLayout(),d=l.children.length,y=f=void 0,p.x===t.x&&!0===a.isExpand&&l.children.length?(g=(l.children[0].getLayout().x+l.children[d-1].getLayout().x)/2,l=(l.children[0].getLayout().y+l.children[d-1].getLayout().y)/2,(f=Math.atan2(l-t.y,g-t.x))<0&&(f=2*Math.PI+f),(y=g<t.x)&&(f-=Math.PI)):((f=Math.atan2(p.y-t.y,p.x-t.x))<0&&(f=2*Math.PI+f),0===a.children.length||0!==a.children.length&&!1===a.isExpand?(y=p.x<t.x)&&(f-=Math.PI):(y=p.x>t.x)||(f-=Math.PI)),d=y?"left":"right",t=(g=(l=s.getModel("label")).get("rotate"))*(Math.PI/180),y=r.getTextContent())&&(r.setTextConfig({position:l.get("position")||d,rotation:null==g?-f:t,origin:"center"}),y.setStyle("verticalAlign","middle")),s.get(["emphasis","focus"])),l="relative"===r?Et(a.getAncestorsIndices(),a.getDescendantIndices()):"ancestor"===r?a.getAncestorsIndices():"descendant"===r?a.getDescendantIndices():null,d=(l&&($(i).focus=l),o),g=a,f=u,t=i,y=c,s=h,r=p,l=e,o=g.getModel(),u=d.get("edgeShape"),c=d.get("layout"),h=d.getOrient(),p=d.get(["lineStyle","curveness"]),e=d.get("edgeForkPosition"),m=o.getModel("lineStyle").getLineStyle(),v=t.__edge;if("curve"===u)g.parentNode&&g.parentNode!==f&&C(v=v||(t.__edge=new Uh({shape:Q2(c,h,p,y,y)})),{shape:Q2(c,h,p,s,r)},d);else if("polyline"===u&&"orthogonal"===c&&g!==f&&g.children&&0!==g.children.length&&!0===g.isExpand){for(var x=g.children,_=[],b=0;b<x.length;b++){var w=x[b].getLayout();_.push([w.x,w.y])}C(v=v||(t.__edge=new H2({shape:{parentPoint:[r.x,r.y],childPoints:[[r.x,r.y]],orient:h,forkPosition:e}})),{shape:{parentPoint:[r.x,r.y],childPoints:_}},d)}v&&("polyline"!==u||g.isExpand)&&(v.useStyle(z({strokeNoScale:!0,fill:null},m)),Du(v,o,"lineStyle"),lu(v),l.add(v)),i.__edge&&(i.onHoverStateChange=function(t){var e;"blur"===t||(e=a.parentNode&&n.getItemGraphicEl(a.parentNode.dataIndex))&&e.hoverState===Fl||ru(i.__edge,t)})}function K2(t,e,n,i,o){var r,a,s=$2(e.tree.root,t),l=s.source,s=s.sourceLayout,t=e.getItemGraphicEl(t.dataIndex);t&&(e=e.getItemGraphicEl(l.dataIndex).__edge,r=t.__edge||(!1===l.isExpand||1===l.children.length?e:void 0),t=i.get("edgeShape"),l=i.get("layout"),e=i.get("orient"),a=i.get(["lineStyle","curveness"]),r)&&("curve"===t?wc(r,{shape:Q2(l,e,a,s,s),style:{opacity:0}},i,{cb:function(){n.remove(r)},removeOpt:o}):"polyline"===t&&"orthogonal"===i.get("layout")&&wc(r,{shape:{parentPoint:[s.x,s.y],childPoints:[[s.x,s.y]]},style:{opacity:0}},i,{cb:function(){n.remove(r)},removeOpt:o}))}function $2(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 J2(e,t,n,i,o){var r=e.tree.getNodeByDataIndex(t),a=$2(e.tree.root,r).sourceLayout,s={duration:o.get("animationDurationUpdate"),easing:o.get("animationEasingUpdate")};wc(n,{x:a.x+1,y:a.y+1},o,{cb:function(){i.remove(n),e.setItemGraphicEl(t,null)},removeOpt:s}),n.fadeOut(null,e.hostModel,{fadeLabel:!0,animation:s}),r.children.forEach(function(t){K2(t,e,i,o,s)}),K2(r,e,i,o,s)}function Q2(t,e,n,i,o){var r,a,s,l,u,h,c,p,d,g,f;return"radial"===t?(u=i.rawX,h=i.rawY,c=o.rawX,p=o.rawY,t=x2(u,h),d=x2(u,h+(p-h)*n),g=x2(c,p+(h-p)*n),f=x2(c,p),{x1:t.x||0,y1:t.y||0,x2:f.x||0,y2:f.y||0,cpx1:d.x||0,cpy1:d.y||0,cpx2:g.x||0,cpy2:g.y||0}):(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 tT=i();function eT(n){var i=n.mainData,t=n.datas;t||(t={main:i},n.datasAttr={main:"data"}),n.datas=n.mainData=null,sT(i,t,n),nt(t,function(e){nt(i.TRANSFERABLE_METHODS,function(t){e.wrapMethod(t,P(nT,n))})}),i.wrapMethod("cloneShallow",P(oT,n)),nt(i.CHANGABLE_METHODS,function(t){i.wrapMethod(t,P(iT,n))}),Tt(t[i.dataType]===i)}function nT(t,e){var n;return tT(n=this).mainData===n?sT((n=F({},tT(this).datas))[this.dataType]=e,n,t):lT(e,this.dataType,tT(this).mainData,t),e}function iT(t,e){return t.struct&&t.struct.update(),e}function oT(n,i){return nt(tT(i).datas,function(t,e){t!==i&&lT(t.cloneShallow(),e,i,n)}),i}function rT(t){var e=tT(this).mainData;return null==t||null==e?e:tT(e).datas[t]}function aT(){var e=tT(this).mainData;return null==e?[{data:e}]:V(W(tT(e).datas),function(t){return{type:t,data:tT(e).datas[t]}})}function sT(n,t,i){tT(n).datas={},nt(t,function(t,e){lT(t,e,n,i)})}function lT(t,e,n,i){tT(n).datas[e]=t,tT(t).mainData=n,t.dataType=e,i.struct&&(t[i.structAttr]=i.struct,i.struct[i.datasAttr[e]]=t),t.getLinkedData=rT,t.getLinkedDataAll=aT}hT.prototype.isRemoved=function(){return this.dataIndex<0},hT.prototype.eachNode=function(t,e,n){D(t)&&(n=e,e=t,t=null);var i,o=(t=H(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)},hT.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},hT.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}},hT.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}},hT.prototype.getAncestors=function(t){for(var e=[],n=t?this:this.parentNode;n;)e.push(n),n=n.parentNode;return e.reverse(),e},hT.prototype.getAncestorsIndices=function(){for(var t=[],e=this;e;)t.push(e.dataIndex),e=e.parentNode;return t.reverse(),t},hT.prototype.getDescendantIndices=function(){var e=[];return this.eachNode(function(t){e.push(t.dataIndex)}),e},hT.prototype.getValue=function(t){var e=this.hostTree.data;return e.getStore().get(e.getDimensionIndex(t||"value"),this.dataIndex)},hT.prototype.setLayout=function(t,e){0<=this.dataIndex&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},hT.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},hT.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostTree.data.getItemModel(this.dataIndex).getModel(t)},hT.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},hT.prototype.setVisual=function(t,e){0<=this.dataIndex&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},hT.prototype.getVisual=function(t){return this.hostTree.data.getItemVisual(this.dataIndex,t)},hT.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},hT.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},hT.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},hT.prototype.isAncestorOf=function(t){for(var e=t.parentNode;e;){if(e===this)return!0;e=e.parentNode}return!1},hT.prototype.isDescendantOf=function(t){return t!==this&&t.isAncestorOf(this)};var uT=hT;function hT(t,e){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=t||"",this.hostTree=e}pT.prototype.eachNode=function(t,e,n){this.root.eachNode(t,e,n)},pT.prototype.getNodeByDataIndex=function(t){t=this.data.getRawIndex(t);return this._nodes[t]},pT.prototype.getNodeById=function(t){return this.root.getNodeById(t)},pT.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},pT.prototype.clearLayouts=function(){this.data.clearItemLayouts()},pT.createTree=function(t,e,n){var s=new pT(e),l=[],u=1;!function t(e,n){var i=e.value;u=Math.max(u,B(i)?i.length:1);l.push(e);var o=new uT(ra(e.name,""),s);n?dT(o,n):s.root=o;s._nodes.push(o);var r=e.children;if(r)for(var a=0;a<r.length;a++)t(r[a],o)}(t),s.root.updateDepthAndHeight(0);t=L1(l,{coordDimensions:["value"],dimensionsCount:u}).dimensions,t=new k1(t,e);return t.initData(l),n&&n(t),eT({mainData:t,struct:s,structAttr:"tree"}),s.update(),s};var cT=pT;function pT(t){this.type="tree",this._nodes=[],this.hostModel=t}function dT(t,e){var n=e.children;t.parentNode!==e&&(n.push(t),t.parentNode=e)}function gT(t,e,n){if(t&&0<=G(e,t.type))return e=n.getData().tree.root,(n=H(n=t.targetNode)?e.getNodeById(n):n)&&e.contains(n)||null!=(t=t.targetNodeId)&&(n=e.getNodeById(t))?{node:n}:void 0}function fT(t){for(var e=[];t;)(t=t.parentNode)&&e.push(t);return e.reverse()}function yT(t,e){return 0<=G(fT(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}u(_T,vT=Gy),_T.prototype.getInitialData=function(t){var e={name:t.name,children:t.data},n=t.leaves||{},i=new kp(n,this,this.ecModel),o=cT.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},_T.prototype.getOrient=function(){var t=this.get("orient");return"horizontal"===t?t="LR":"vertical"===t&&(t="TB"),t},_T.prototype.setZoom=function(t){this.option.zoom=t},_T.prototype.setCenter=function(t){this.option.center=t},_T.prototype.formatTooltip=function(t,e,n){for(var i=this.getData().tree,o=i.root.children[0],r=i.getNodeByDataIndex(t),i=r.getValue(),a=r.name;r&&r!==o;)a=r.parentNode.name+"."+a,r=r.parentNode;return Iy("nameValue",{name:a,value:i,noValue:isNaN(i)||null==i})},_T.prototype.getDataParams=function(t){var e=vT.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treeAncestors=mT(t,this),e.collapsed=!t.isExpand,e},_T.type="series.tree",_T.layoutMode="box",_T.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500};var vT,xT=_T;function _T(){var t=null!==vT&&vT.apply(this,arguments)||this;return t.hasSymbolVisual=!0,t.ignoreStyleOnData=!0,t}function bT(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 wT(t,A){t.eachSeriesByType("tree",function(t){var e=function(t,e){return Ld(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}(t,e=A),n=(t.layoutInfo=e,t.get("layout")),i=0,o=0,r=null;r="radial"===n?(i=2*Math.PI,o=Math.min(e.height,e.width)/2,v2(function(t,e){return(t.parentNode===e.parentNode?1:2)/t.depth})):(i=e.width,o=e.height,v2());var a,s,l,u,h,c,p,d,g,f=(e=t.getData().tree.root).children[0];if(f){var y=e;y.hierNode={defaultAncestor:null,ancestor:y,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var m,v,x=[y];m=x.pop();)if(v=m.children,m.isExpand&&v.length)for(var _=v.length-1;0<=_;_--){var b=v[_];b.hierNode={defaultAncestor:null,ancestor:b,prelim:0,modifier:0,change:0,shift:0,i:_,thread:null},x.push(b)}for(var w,S=y2,M=r,I=[f],T=[];w=I.pop();)if(T.push(w),w.isExpand){var C=w.children;if(C.length)for(var D=0;D<C.length;D++)I.push(C[D])}for(;w=T.pop();)S(w,M);e.hierNode.modifier=-f.hierNode.prelim,bT(f,m2),bT(l=s=a=f,function(t){var e=t.getLayout().x;e<a.getLayout().x&&(a=t),e>s.getLayout().x&&(s=t),t.depth>l.depth&&(l=t)}),e=a===s?1:r(a,s)/2,u=e-a.getLayout().x,d=p=c=h=0,"radial"===n?(h=i/(s.getLayout().x+e+u),c=o/(l.depth-1||1),bT(f,function(t){p=(t.getLayout().x+u)*h,d=(t.depth-1)*c;var e=x2(p,d);t.setLayout({x:e.x,y:e.y,rawX:p,rawY:d},!0)})):"RL"===(g=t.getOrient())||"LR"===g?(c=o/(s.getLayout().x+e+u),h=i/(l.depth-1||1),bT(f,function(t){d=(t.getLayout().x+u)*c,p="LR"===g?(t.depth-1)*h:i-(t.depth-1)*h,t.setLayout({x:p,y:d},!0)})):"TB"!==g&&"BT"!==g||(h=i/(s.getLayout().x+e+u),c=o/(l.depth-1||1),bT(f,function(t){p=(t.getLayout().x+u)*h,d="TB"===g?(t.depth-1)*c:o-(t.depth-1)*c,t.setLayout({x:p,y:d},!0)}))}})}function ST(t){t.eachSeriesByType("tree",function(t){var n=t.getData();n.tree.eachNode(function(t){var e=t.getModel().getModel("itemStyle").getItemStyle();F(n.ensureUniqueItemVisual(t.dataIndex,"style"),e)})})}function MT(t,e){return t.pointToProjected?t.pointToProjected(e):t.pointToData(e)}function IT(t,e,n,i){var o,r=t.getZoom(),a=t.getCenter(),s=e.zoom,a=t.projectedToPoint?t.projectedToPoint(a):t.dataToPoint(a);return null!=e.dx&&null!=e.dy&&(a[0]-=e.dx,a[1]-=e.dy,t.setCenter(MT(t,a),i)),null!=s&&(n&&(o=n.min||0,n=n.max||1/0,s=Math.max(Math.min(r*s,n),o)/r),t.scaleX*=s,t.scaleY*=s,n=(e.originX-t.x)*(s-1),o=(e.originY-t.y)*(s-1),t.x-=n,t.y-=o,t.updateTransform(),t.setCenter(MT(t,a),i),t.setZoom(s*r)),{center:t.getCenter(),zoom:t.getZoom()}}r(function(t){t.registerChartView(U2),t.registerSeriesModel(xT),t.registerLayout(wT),t.registerVisual(ST),(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,t=t.getData().tree.getNodeByDataIndex(e);t.isExpand=!t.isExpand})}),t.registerAction({type:"treeRoam",event:"treeRoam",update:"none"},function(n,t,i){t.eachComponent({mainType:"series",subType:"tree",query:n},function(t){var e=IT(t.coordinateSystem,n,void 0,i);t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom)})})});var TT=["treemapZoomToNode","treemapRender","treemapMove"];function CT(t){for(var e=0;e<TT.length;e++)t.registerAction({type:TT[e],update:"updateView"},Bt);t.registerAction({type:"treemapRootToNode",update:"updateView"},function(o,t){t.eachComponent({mainType:"series",subType:"treemap",query:o},function(t,e){var n=gT(o,["treemapZoomToNode","treemapRootToNode"],t);{var i;n&&((i=t.getViewRoot())&&(o.direction=yT(i,n.node)?"rollUp":"drillDown"),t.resetViewRoot(n.node))}})})}function DT(s){var t=s.getData().tree,l={};t.eachNode(function(t){for(var e=t;e&&1<e.depth;)e=e.parentNode;a=s.ecModel,n=e.name||e.dataIndex+"",i=l,r=Jr(a.get(["aria","decal","decals"]));var n,i,o,r,a=fg(a,pg,r,null,n,i,o);t.setVisual("decal",a)})}u(LT,AT=Gy),LT.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data},i=(!function e(t){var n=0;nt(t.children,function(t){e(t);t=t.value;B(t)&&(t=t[0]),n+=t});var i=t.value;B(i)&&(i=i[0]);null!=i&&!isNaN(i)||(i=n);i<0&&(i=0);B(t.value)?t.value[0]=i:t.value=i}(n),t.levels||[]),o=this.designatedVisualItemStyle={},r=new kp({itemStyle:o},this,e),a=V((t.levels=function(t,e){var i,o,n,r=Jr(e.get("color")),e=Jr(e.get(["aria","decal","decals"]));if(r)return nt(t=t||[],function(t){var t=new kp(t),e=t.get("color"),n=t.get("decal");(t.get(["itemStyle","color"])||e&&"none"!==e)&&(i=!0),(t.get(["itemStyle","decal"])||n&&"none"!==n)&&(o=!0)}),n=t[0]||(t[0]={}),i||(n.color=r.slice()),!o&&e&&(n.decal=e.slice()),t}(i,e))||[],function(t){return new kp(t,r,e)},this),s=cT.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},LT.prototype.optionUpdated=function(){this.resetViewRoot()},LT.prototype.formatTooltip=function(t,e,n){var i=this.getData(),o=this.getRawValue(t);return Iy("nameValue",{name:i.getName(t),value:o})},LT.prototype.getDataParams=function(t){var e=AT.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treeAncestors=mT(t,this),e.treePathInfo=e.treeAncestors,e},LT.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},F(this.layoutInfo,t)},LT.prototype.mapIdToIndex=function(t){var e=this._idIndexMap,n=(e||(e=this._idIndexMap=R(),this._idIndexMapCount=0),e.get(t));return null==n&&e.set(t,n=this._idIndexMapCount++),n},LT.prototype.getViewRoot=function(){return this._viewRoot},LT.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)},LT.prototype.enableAriaDecal=function(){DT(this)},LT.type="series.treemap",LT.layoutMode="box",LT.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"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]};var AT,kT=LT;function LT(){var t=null!==AT&&AT.apply(this,arguments)||this;return t.type=LT.type,t.preventUsingHoverLayer=!0,t}OT.prototype.render=function(t,e,n,i){var o,r,a,s,l=t.getModel("breadcrumb"),u=this.group;u.removeAll(),l.get("show")&&n&&(o=l.getModel("itemStyle"),r=l.getModel("emphasis"),a=o.getModel("textStyle"),s=r.getModel(["itemStyle","textStyle"]),e={pos:{left:l.get("left"),right:l.get("right"),top:l.get("top"),bottom:l.get("bottom")},box:{width:e.getWidth(),height:e.getHeight()},emptyItemWidth:l.get("emptyItemWidth"),totalWidth:0,renderList:[]},this._prepare(n,e,a),this._renderContent(t,e,o,r,a,s,i),Pd(u,e.pos,e.box))},OT.prototype._prepare=function(t,e,n){for(var i=t;i;i=i.parentNode){var o=ra(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})}},OT.prototype._renderContent=function(t,e,n,i,o,r,a){for(var s,l,u,h,c,p,d,g,f,y,m,v,x,_=0,b=e.emptyItemWidth,w=t.get(["breadcrumb","height"]),S=(s=e.pos,l=e.box,h=l.width,l=l.height,c=j(s.left,h),p=j(s.top,l),d=j(s.right,h),g=j(s.bottom,l),(isNaN(c)||isNaN(parseFloat(s.left)))&&(c=0),(isNaN(d)||isNaN(parseFloat(s.right)))&&(d=h),(isNaN(p)||isNaN(parseFloat(s.top)))&&(p=0),(isNaN(g)||isNaN(parseFloat(s.bottom)))&&(g=l),u=vd(u||0),{width:Math.max(d-c-u[1]-u[3],0),height:Math.max(g-p-u[0]-u[2],0)}),M=e.totalWidth,I=e.renderList,T=i.getModel("itemStyle").getItemStyle(),C=I.length-1;0<=C;C--){var D=I[C],A=D.node,k=D.width,D=D.text,L=(S.width<M&&(M-=k-b,k=b,D=null),new Lh({shape:{points:(f=_,y=0,L=k,m=w,v=C===I.length-1,x=void 0,x=[[v?f:f-5,y],[f+L,y],[f+L,y+m],[v?f:f-5,y+m]],0===C||x.splice(2,0,[f+L+5,y+m/2]),v||x.push([f,y+m/2]),x)},style:z(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new K({style:ap(o,{text:D})}),textConfig:{position:"inside"},z2:1e5,onclick:P(a,A)}));L.disableLabelAnimation=!0,L.getTextContent().ensureState("emphasis").style=ap(r,{text:D}),L.ensureState("emphasis").style=T,Mu(L,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(L),v=t,f=A,$(L).eventData={componentType:"series",componentSubType:"treemap",componentIndex:v.componentIndex,seriesIndex:v.seriesIndex,seriesName:v.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:f&&f.dataIndex,name:f&&f.name},treePathInfo:f&&mT(f,v)},_+=k+8}},OT.prototype.remove=function(){this.group.removeAll()};var PT=OT;function OT(t){this.group=new Z,t.add(this.group)}RT.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)},RT.prototype.finished=function(t){return this._finishedCallback=t,this},RT.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};var NT=RT;function RT(){this._storage=[],this._elExistsMap={}}var ET,zT=Z,VT=L,BT="label",FT="upperLabel",GT=100,WT=20,HT=30,YT=Aa([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),XT=function(t){t=YT(t);return t.stroke=t.fill=t.lineWidth=null,t},UT=i(),ZT=(u(jT,ET=em),jT.prototype.render=function(t,e,n,i){var o,r,a,s,l;G(e.findComponents({mainType:"series",subType:"treemap",query:i}),t)<0||(this.seriesModel=t,this.api=n,this.ecModel=e,e=gT(i,["treemapZoomToNode","treemapRootToNode"],t),o=i&&i.type,s=t.layoutInfo,r=!this._oldTree,a=this._storage,a="treemapRootToNode"===o&&e&&a?{rootNodeGroup:a.nodeGroup[e.node.getRawIndex()],direction:i.direction}:null,i=this._giveContainerGroup(s),s=t.get("animation"),l=this._doRender(i,t,a),!s||r||o&&"treemapZoomToNode"!==o&&"treemapRootToNode"!==o?l.renderFinally():this._doAnimation(i,l,t,a),this._resetController(n),this._renderBreadcrumb(t,n,e))},jT.prototype._giveContainerGroup=function(t){var e=this._containerGroup;return e||(e=this._containerGroup=new zT,this._initEvents(e),this.group.add(e)),e.x=t.x,e.y=t.y,e},jT.prototype._doRender=function(t,O,N){var e=O.getData().tree,n=this._oldTree,R=qT(),E=qT(),z=this._storage,V=[];function u(t,e,n,i){var u=O,l=E,h=z,c=N,p=R,o=V,d=t,t=e,e=n,n=i;if(d){var g=d.getLayout(),i=u.getData(),f=d.getModel();if(i.setItemGraphicEl(d.dataIndex,null),g&&g.isInView){var r,a,s,y=g.width,m=g.height,v=g.borderWidth,x=g.invisible,_=d.getRawIndex(),b=t&&t.getRawIndex(),t=d.viewChildren,w=g.upperHeight,t=t&&t.length,S=f.getModel("itemStyle"),M=f.getModel(["emphasis","itemStyle"]),I=f.getModel(["blur","itemStyle"]),T=f.getModel(["select","itemStyle"]),C=S.get("borderRadius")||0,D=P("nodeGroup",zT);if(D)return e.add(D),D.x=g.x||0,D.y=g.y||0,D.markRedraw(),UT(D).nodeWidth=y,UT(D).nodeHeight=m,g.isAboveViewRoot||((e=P("background",VT,n,WT))&&function(t,e,n){var i=$(e);{var o,r,a,s,l;i.dataIndex=d.dataIndex,i.seriesIndex=u.seriesIndex,e.setShape({x:0,y:0,width:y,height:m,r:C}),(x?A:(e.invisible=!1,i=d.getVisual("style"),o=i.stroke,(r=XT(S)).fill=o,(a=YT(M)).fill=M.get("borderColor"),(s=YT(I)).fill=I.get("borderColor"),(l=YT(T)).fill=T.get("borderColor"),n?(n=y-2*v,k(e,o,i.opacity,{x:v,y:0,width:n,height:w})):e.removeTextContent(),e.setStyle(r),e.ensureState("emphasis").style=a,e.ensureState("blur").style=s,e.ensureState("select").style=l,lu))(e)}t.add(e)}(D,e,t&&g.upperLabelHeight),a=f.getModel("emphasis"),s=a.get("focus"),r=a.get("blurScope"),a=a.get("disabled"),s="ancestor"===s?d.getAncestorsIndices():"descendant"===s?d.getDescendantIndices():s,t?(ku(D)&&Au(D,!1),e&&(Au(e,!a),i.setItemGraphicEl(d.dataIndex,e),Iu(e,s,r))):((t=P("content",VT,n,HT))&&function(t,e){var n=$(e),n=(n.dataIndex=d.dataIndex,n.seriesIndex=u.seriesIndex,Math.max(y-2*v,0)),i=Math.max(m-2*v,0);{var o,r,a,s;e.culling=!0,e.setShape({x:v,y:v,width:n,height:i,r:C}),(x?A:(e.invisible=!1,n=d.getVisual("style"),i=n.fill,o=XT(S),o.fill=i,o.decal=n.decal,r=YT(M),a=YT(I),s=YT(T),k(e,i,n.opacity,null),e.setStyle(o),e.ensureState("emphasis").style=r,e.ensureState("blur").style=a,e.ensureState("select").style=s,lu))(e)}t.add(e)}(D,t),e.disableMorphing=!0,e&&ku(e)&&Au(e,!1),Au(D,!a),i.setItemGraphicEl(d.dataIndex,D),Iu(D,s,r))),D}}function A(t){t.invisible||o.push(t)}function k(n,t,e,i){var o,r,a=f.getModel(i?FT:BT),s=ra(f.get("name"),null),a=a.getShallow("show"),l=(op(n,rp(f,i?FT:BT),{defaultText:a?s:null,inheritColor:t,defaultOpacity:e,labelFetcher:u,labelDataIndex:d.dataIndex}),n.getTextContent());l&&(o=l.style,r=It(o.padding||0),i&&(n.setTextConfig({layoutRect:i}),l.disableLabelLayout=!0),l.beforeUpdate=function(){var t=Math.max((i||n.shape).width-r[1]-r[3],0),e=Math.max((i||n.shape).height-r[0]-r[2],0);o.width===t&&o.height===e||l.setStyle({width:t,height:e})},o.truncateMinChar=2,o.lineOverflow="truncate",L(o,i,g),L((a=l.getState("emphasis"))?a.style:null,i,g))}function L(t,e,n){var i=t?t.text:null;!e&&n.isLeafRoot&&null!=i&&(e=u.get("drillDownIcon",!0),t.text=e?e+" "+i:i)}function P(t,e,n,i){var o,r,a=null!=b&&h[t][b],s=p[t];return a?(h[t][b]=null,o=a,r=(r=s)[_]={},o instanceof zT?(r.oldX=o.x,r.oldY=o.y):r.oldShape=F({},o.shape)):x||((a=new e)instanceof ts&&(a.z2=n*GT+i),r=a,o=(o=s)[_]={},e=d.parentNode,r=r instanceof Z,!e||c&&"drillDown"!==c.direction||(i=n=0,e=p.background[e.getRawIndex()],!c&&e&&e.oldShape&&(n=e.oldShape.width,i=e.oldShape.height),r?(o.oldX=0,o.oldY=i):o.oldShape={x:n,y:i,width:0,height:0}),o.fadein=!r),l[t][_]=a}}!function i(o,r,a,s,l){s?nt(r=o,function(t,e){t.isRemoved()||n(e,e)}):new i1(r,o,t,t).add(n).update(n).remove(P(n,null)).execute();function t(t){return t.getId()}function n(t,e){var t=null!=t?o[t]:null,e=null!=e?r[e]:null,n=u(t,e,a,l);n&&i(t&&t.viewChildren||[],e&&e.viewChildren||[],n,s,l+1)}}(e.root?[e.root]:[],n&&n.root?[n.root]:[],t,e===n||!n,0);i=qT(),(t=z)&&nt(t,function(t,e){var n=i[e];nt(t,function(t){t&&(n.push(t),UT(t).willDelete=!0)})});var i,o=i;return this._oldTree=e,this._storage=E,{lastsForAnimation:R,willDeleteEls:o,renderFinally:function(){nt(o,function(t){nt(t,function(t){t.parent&&t.parent.remove(t)})}),nt(V,function(t){t.invisible=!0,t.dirty()})}}},jT.prototype._doAnimation=function(t,o,e,a){var n=e.get("animationDurationUpdate"),e=e.get("animationEasing"),s=(D(n)?0:n)||0,l=(D(e)?null:e)||"cubicOut",u=new NT;nt(o.willDeleteEls,function(t,r){nt(t,function(t,e){var n,i,o;!t.invisible&&(n=t.parent,o=UT(n),o=a&&"drillDown"===a.direction?n===a.rootNodeGroup?{shape:{x:0,y:0,width:o.nodeWidth,height:o.nodeHeight},style:{opacity:0}}:{style:{opacity:0}}:(i=n=0,o.willDelete||(n=o.nodeWidth/2,i=o.nodeHeight/2),"nodeGroup"===r?{x:n,y:i,style:{opacity:0}}:{shape:{x:n,y:i,width:0,height:0},style:{opacity:0}}))&&u.add(t,o,s,0,l)})}),nt(this._storage,function(t,i){nt(t,function(t,e){var e=o.lastsForAnimation[i][e],n={};e&&(t instanceof Z?null!=e.oldX&&(n.x=t.x,n.y=t.y,t.x=e.oldX,t.y=e.oldY):(e.oldShape&&(n.shape=F({},t.shape),t.setShape(e.oldShape)),e.fadein?(t.setStyle("opacity",0),n.style={opacity:1}):1!==t.style.opacity&&(n.style={opacity:1})),u.add(t,n,s,0,l))})},this),this._state="animating",u.finished(T(function(){this._state="ready",o.renderFinally()},this)).start()},jT.prototype._resetController=function(t){var e=this._controller,i=(e||((e=this._controller=new N2(t.getZr())).enable(this.seriesModel.get("roam")),e.on("pan",T(this._onPan,this)),e.on("zoom",T(this._onZoom,this))),new U(0,0,t.getWidth(),t.getHeight()));e.setPointerChecker(function(t,e,n){return i.contain(e,n)})},jT.prototype._clearController=function(){var t=this._controller;t&&t.dispose()},jT.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}})},jT.prototype._onZoom=function(t){var e,n,i,o=t.originX,r=t.originY;"animating"!==this._state&&(e=this.seriesModel.getData().tree.root)&&(e=e.getLayout())&&(e=new U(e.x,e.y,e.width,e.height),Ge(i=ze(),i,[-(o-=(n=this.seriesModel.layoutInfo).x),-(r-=n.y)]),He(i,i,[t.scale,t.scale]),Ge(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}}))},jT.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&&(n=(e=t.hostTree.data.getItemModel(t.dataIndex)).get("link",!0),t=e.get("target",!0)||"blank",n)&&Id(n,t))},this)},jT.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 PT(this.group))).render(e,t,n.node,function(t){"animating"!==i._state&&(yT(e.getViewRoot(),t)?i._rootToNode({node:t}):i._zoomToNode({node:t}))})},jT.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=qT(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},jT.prototype.dispose=function(){this._clearController()},jT.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},jT.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},jT.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},jT.type="treemap",jT);function jT(){var t=null!==ET&&ET.apply(this,arguments)||this;return t.type=jT.type,t._state="ready",t._storage=qT(),t}function qT(){return{nodeGroup:[],background:[],content:[]}}var KT=nt,$T=O,JT=-1,QT=(tC.prototype.mapValueToVisual=function(t){var e=this._normalizeData(t);return this._normalizedToVisual(e,t)},tC.prototype.getNormalizer=function(){return T(this._normalizeData,this)},tC.listVisualTypes=function(){return W(tC.visualHandlers)},tC.isValidType=function(t){return tC.visualHandlers.hasOwnProperty(t)},tC.eachVisual=function(t,e,n){O(t)?nt(t,e,n):e.call(n,t)},tC.mapVisual=function(t,n,i){var o,r=B(t)?[]:O(t)?{}:(o=!0,null);return tC.eachVisual(t,function(t,e){t=n.call(i,t,e);o?r=t:r[e]=t}),r},tC.retrieveVisuals=function(n){var i,o={};return n&&KT(tC.visualHandlers,function(t,e){n.hasOwnProperty(e)&&(o[e]=n[e],i=!0)}),i?o:null},tC.prepareVisualTypes=function(t){if(B(t))t=t.slice();else{if(!$T(t))return[];var n=[];KT(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},tC.dependsOn=function(t,e){return"color"===e?!(!t||0!==t.indexOf(e)):t===e},tC.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||H(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(cC(l[1],n,u[1]))return r}else if(u[1]===1/0){if(cC(l[0],u[0],n))return r}else if(cC(l[0],u[0],n)&&cC(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)}},tC.visualHandlers={color:{applyVisual:oC("color"),getColorMapper:function(){var o=this.option;return T("category"===o.mappingMethod?function(t,e){return e||(t=this._normalizeData(t)),rC.call(this,t)}:function(t,e,n){var i=!!n;return n=Ti(t=e?t:this._normalizeData(t),o.parsedVisual,n),i?n:Li(n,"rgba")},this)},_normalizedToVisual:{linear:function(t){return Li(Ti(t,this.option.parsedVisual),"rgba")},category:rC,piecewise:function(t,e){e=lC.call(this,e);return e=null==e?Li(Ti(t,this.option.parsedVisual),"rgba"):e},fixed:aC}},colorHue:nC(function(t,e){return Ai(t,e)}),colorSaturation:nC(function(t,e){return Ai(t,null,e)}),colorLightness:nC(function(t,e){return Ai(t,null,null,e)}),colorAlpha:nC(ki),decal:{applyVisual:oC("decal"),_normalizedToVisual:{linear:null,category:rC,piecewise:null,fixed:null}},opacity:{applyVisual:oC("opacity"),_normalizedToVisual:sC([0,1])},liftZ:{applyVisual:oC("liftZ"),_normalizedToVisual:{linear:aC,category:aC,piecewise:aC,fixed:aC}},symbol:{applyVisual:function(t,e,n){n("symbol",this.mapValueToVisual(t))},_normalizedToVisual:{linear:iC,category:rC,piecewise:function(t,e){e=lC.call(this,e);return e=null==e?iC.call(this,t):e},fixed:aC}},symbolSize:{applyVisual:oC("symbolSize"),_normalizedToVisual:sC([0,1])}},tC);function tC(t){var n,e=t.mappingMethod,i=t.type,t=this.option=S(t),i=(this.type=i,this.mappingMethod=e,this._normalizeData=hC[e],tC.visualHandlers[i]);if(this.applyVisual=i.applyVisual,this.getColorMapper=i.getColorMapper,this._normalizedToVisual=i._normalizedToVisual[e],"piecewise"===e)eC(t),i=(n=t).pieceList,n.hasSpecialVisual=!1,nt(i,function(t,e){t.originIndex=e,null!=t.visual&&(n.hasSpecialVisual=!0)});else if("category"===e)if(t.categories){var o,i=t,r=i.categories,a=i.categoryMap={},s=i.visual;KT(r,function(t,e){a[t]=e}),B(s)||(o=[],O(s)?KT(s,function(t,e){e=a[e];o[null!=e?e:JT]=t}):o[JT]=s,s=uC(i,o));for(var l=r.length-1;0<=l;l--)null==s[l]&&(delete a[r[l]],r.pop())}else eC(t,!0);else Tt("linear"!==e||t.dataExtent),eC(t)}function eC(t,e){var n=t.visual,i=[];O(n)?KT(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]),uC(t,i)}function nC(i){return{applyVisual:function(t,e,n){t=this.mapValueToVisual(t);n("color",i(e("color"),t))},_normalizedToVisual:sC([0,1])}}function iC(t){var e=this.option.visual;return e[Math.round(Cr(t,[0,1],[0,e.length-1],!0))]||{}}function oC(i){return function(t,e,n){n(i,this.mapValueToVisual(t))}}function rC(t){var e=this.option.visual;return e[this.option.loop&&t!==JT?t%e.length:t]}function aC(){return this.option.visual[0]}function sC(n){return{linear:function(t){return Cr(t,n,this.option.visual,!0)},category:rC,piecewise:function(t,e){e=lC.call(this,e);return e=null==e?Cr(t,n,this.option.visual,!0):e},fixed:aC}}function lC(t){var e=this.option,n=e.pieceList;if(e.hasSpecialVisual){e=n[QT.findPieceIndex(t,n)];if(e&&e.visual)return e.visual[this.type]}}function uC(t,e){return t.visual=e,"color"===t.type&&(t.parsedVisual=V(e,function(t){t=Si(t);return t||[0,0,0,1]})),e}var hC={linear:function(t){return Cr(t,this.option.dataExtent,[0,1],!0)},piecewise:function(t){var e=this.option.pieceList,t=QT.findPieceIndex(t,e,!0);if(null!=t)return Cr(t,[0,e.length-1],[0,1],!0)},category:function(t){t=this.option.categories?this.option.categoryMap[t]:t;return null==t?JT:t},fixed:Bt};function cC(t,e,n){return t?e<=n:e<n}var pC="itemStyle",dC=i(),gC={seriesType:"treemap",reset:function(t){var e=t.getData().tree.root;e.isRemoved()||!function n(t,e,i,o){var r=t.getModel();var a=t.getLayout();var s=t.hostTree.data;if(!a||a.invisible||!a.isInView)return;var l=r.getModel(pC);var u=fC(l,e,o);e=s.ensureUniqueItemVisual(t.dataIndex,"style");s=l.get("borderColor");var h=l.get("borderColorSaturation");var c;null!=h&&(c=yC(u),s=mC(h,c));e.stroke=s;h=t.viewChildren;{var p;h&&h.length?(p=xC(0,r,a,0,u,h),nt(h,function(t,e){(t.depth>=i.length||t===i[t.depth])&&(e=bC(r,u,t,e,p,o),n(t,e,i,o))})):(c=yC(u),e.fill=c)}}(e,{},t.getViewRoot().getAncestors(),t)}};function fC(n,i,t){var o=F({},i),r=t.designatedVisualItemStyle;return nt(["color","colorAlpha","colorSaturation"],function(t){r[t]=i[t];var e=n.get(t);(r[t]=null)!=e&&(o[t]=e)}),o}function yC(t){var e,n=vC(t,"color");if(n)return e=vC(t,"colorAlpha"),(t=vC(t,"colorSaturation"))&&(n=Ai(n,null,null,t)),e?ki(n,e):n}function mC(t,e){return null!=e?Ai(e,null,null,t):null}function vC(t,e){t=t[e];if(null!=t&&"none"!==t)return t}function xC(t,e,n,i,o,r){if(r&&r.length){var a,r=_C(e,"color")||null!=o.color&&"none"!==o.color&&(_C(e,"colorAlpha")||_C(e,"colorSaturation"));if(r)return o=e.get("visualMin"),a=e.get("visualMax"),n=n.dataExtent.slice(),null!=o&&o<n[0]&&(n[0]=o),null!=a&&a>n[1]&&(n[1]=a),o=e.get("colorMappingBy"),"color"!==(a={type:r.name,dataExtent:n,visual:r.range}).type||"index"!==o&&"id"!==o?a.mappingMethod="linear":(a.mappingMethod="category",a.loop=!0),e=new QT(a),dC(e).drColorMappingBy=o,e}}function _C(t,e){t=t.get(e);return B(t)&&t.length?{name:e,range:t}:null}function bC(t,e,n,i,o,r){var a,s,e=F({},e);return o&&(i="index"===(s="color"===(a=o.type)&&dC(o).drColorMappingBy)?i:"id"===s?r.mapIdToIndex(n.getId()):n.getValue(t.get("visualDimension")),e[a]=o.mapValueToVisual(i)),e}var wC=Math.max,SC=Math.min,MC=wt,IC=nt,TC=["itemStyle","borderWidth"],CC=["itemStyle","gapWidth"],DC=["upperLabel","show"],AC=["upperLabel","height"],kC={seriesType:"treemap",reset:function(t,e,n,i){var o,r=n.getWidth(),a=n.getHeight(),s=t.option,n=Ld(t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),l=s.size||[],u=j(MC(n.width,l[0]),r),l=j(MC(n.height,l[1]),a),h=i&&i.type,c=gT(i,["treemapZoomToNode","treemapRootToNode"],t),i="treemapRender"===h||"treemapMove"===h?i.rootRect:null,p=t.getViewRoot(),d=fT(p),u=("treemapMove"!==h&&(h="treemapZoomToNode"===h?function(t,e,n,i,o){var r,a=(e||{}).node,s=[i,o];if(!a||a===n)return s;var e=i*o,l=e*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 d=r.getModel(),g=d.get(TC),d=Math.max(g,NC(d));l+=4*g*g+(3*g+d)*Math.pow(l,.5),Nr<l&&(l=Nr),a=r}l<e&&(l=e);n=Math.pow(l/e,.5);return[i*n,o*n]}(t,c,p,u,l):i?[i.width,i.height]:[u,l],u=s.sort,l={squareRatio:s.squareRatio,sort:u=u&&"asc"!==u&&"desc"!==u?"desc":u,leafDepth:s.leafDepth},p.hostTree.clearLayouts(),o={x:0,y:0,width:h[0],height:h[1],area:h[0]*h[1]},p.setLayout(o),function t(e,n,i,o){var r;if(e.isRemoved())return;var a=e.getLayout();r=a.width;a=a.height;var s=e.getModel();var l=s.get(TC);var u=s.get(CC)/2;var h=NC(s);var c=Math.max(l,h);var p=l-u;var d=c-u;e.setLayout({borderWidth:l,upperHeight:c,upperLabelHeight:h},!0);r=wC(r-2*p,0);a=wC(a-p-d,0);l=r*a;var g=LC(e,s,l,n,i,o);if(!g.length)return;var f={x:p,y:d,width:r,height:a};var y=SC(r,a);var m=1/0;var v=[];v.area=0;for(var x=0,_=g.length;x<_;){var b=g[x],b=(v.push(b),v.area+=b.getLayout().area,PC(v,y,n.squareRatio));m=b<=m?(x++,b):(v.area-=v.pop().getLayout().area,OC(v,y,f,u,!1),y=SC(f.width,f.height),1/(v.length=v.area=0))}v.length&&OC(v,y,f,u,!0);i||null!=(c=s.get("childrenVisibleMin"))&&l<c&&(i=!0);for(x=0,_=g.length;x<_;x++)t(g[x],n,i,o+1)}(p,l,!1,0),o=p.getLayout(),IC(d,function(t,e){e=(d[e+1]||p).getValue();t.setLayout(F({dataExtent:[e,e],borderWidth:0,upperHeight:0},o))})),t.getData().tree.root);u.setLayout(function(t,e,n){if(e)return{x:e.x,y:e.y};e={x:0,y:0};if(!n)return e;var n=n.node,i=n.getLayout();if(!i)return e;var o=[i.width/2,i.height/2],r=n;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]}}(n,i,c),!0),t.setLayoutInfo(n),function e(t,n,i,o,r){var a=t.getLayout();var s=i[r];var l=s&&s===t;if(s&&!l||r===i.length&&t!==o)return;t.setLayout({isInView:!0,invisible:!l&&!n.intersect(a),isAboveViewRoot:l},!0);var u=new U(n.x-a.x,n.y-a.y,n.width,n.height);IC(t.viewChildren||[],function(t){e(t,u,i,o,r+1)})}(u,new U(-n.x,-n.y,r,a),d,p,0)}};function LC(t,e,n,i,o,r){var a,s=t.children||[],l=i.sort,i=("asc"!==l&&"desc"!==l&&(l=null),null!=i.leafDepth&&i.leafDepth<=r);if(o&&!i)return t.viewChildren=[];s=pt(s,function(t){return!t.isRemoved()}),r=s,(a=l)&&r.sort(function(t,e){var n="asc"===a?t.getValue()-e.getValue():e.getValue()-t.getValue();return 0==n?"asc"===a?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");e&&e.length?"value"===s&&n?(a=[e[e.length-1].getValue(),e[0].getValue()],"asc"===n&&a.reverse()):(a=[1/0,-1/0],IC(e,function(t){t=t.getValue(s);t<a[0]&&(a[0]=t),t>a[1]&&(a[1]=t)})):a=[NaN,NaN];return{sum:i,dataExtent:a}}(e,s,l);if(0===u.sum)return t.viewChildren=[];if(u.sum=function(t,e,n,i,o){if(i){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)}"asc"===i?o.splice(0,a-s):o.splice(s,a-s)}return n}(e,n,u.sum,l,s),0===u.sum)return t.viewChildren=[];for(var h=0,c=s.length;h<c;h++){var p=s[h].getValue()/u.sum*n;s[h].setLayout({area:p})}return i&&(s.length&&t.setLayout({isLeafRoot:!0},!0),s.length=0),t.viewChildren=s,t.setLayout({dataExtent:u.dataExtent},!0),s}function PC(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,e=e*e*n;return l?wC(e*o/l,l/(e*r)):1/0}function OC(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],g={},f=h?d.getLayout().area/h:0,y=g[l[a]]=wC(h-2*i,0),m=n[s[r]]+n[l[r]]-u,m=c===p-1||m<f?m:f,f=g[l[r]]=wC(m-2*i,0);g[s[a]]=n[s[a]]+SC(i,y/2),g[s[r]]=u+SC(i,f/2),u+=m,d.setLayout(g,!0)}n[s[a]]+=h,n[l[a]]-=h}function NC(t){return t.get(DC)?t.get(AC):0}r(function(t){t.registerSeriesModel(kT),t.registerChartView(ZT),t.registerVisual(gC),t.registerLayout(kC),CT(t)});u(zC,RC=wh),zC.prototype.updateData=function(t,e,n,i,o){(this.node=e).piece=this,n=n||this._seriesModel,i=i||this._ecModel;var r=this,a=($(r).dataIndex=e.dataIndex,e.getModel()),s=a.getModel("emphasis"),l=e.getLayout(),u=F({},l),h=(u.label=null,e.getVisual("style")),c=(h.lineJoin="bevel",e.getVisual("decal")),c=(c&&(h.decal=V0(c,o)),Ub(a.getModel("itemStyle"),u,!0)),o=(F(u,c),nt(Wl,function(t){var e=r.ensureState(t),t=a.getModel([t,"itemStyle"]),t=(e.style=t.getItemStyle(),Ub(t,u));t&&(e.shape=t)}),t?(r.setShape(u),r.shape.r=l.r0,_c(r,{shape:{r:l.r}},n,e.dataIndex)):(C(r,{shape:u},n),Ic(r)),r.useStyle(h),this._updateLabel(n),a.getShallow("cursor")),c=(o&&r.attr("cursor",o),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel,s.get("focus"));Mu(this,"ancestor"===c?e.getAncestorsIndices():"descendant"===c?e.getDescendantIndices():c,s.get("blurScope"),s.get("disabled"))},zC.prototype._updateLabel=function(h){var c=this,p=this.node.getModel(),n=p.getModel("label"),d=this.node.getLayout(),g=d.endAngle-d.startAngle,f=(d.startAngle+d.endAngle)/2,y=Math.cos(f),m=Math.sin(f),v=this,x=v.getTextContent(),_=this.node.dataIndex,t=n.get("minAngle")/180*Math.PI,t=n.get("show")&&!(null!=t&&Math.abs(g)<t);function b(t,e){t=t.get(e);return null==t?n.get(e):t}x.ignore=!t,nt(Hl,function(t){var e,n="normal"===t?p.getModel("label"):p.getModel([t,"label"]),i="normal"===t,o=i?x:x.ensureState(t),r=h.getFormattedLabel(_,t),r=(i&&(r=r||c.node.name),o.style=ap(n,{},null,"normal"!==t,!0),r&&(o.style.text=r),n.get("show")),r=(null==r||i||(o.ignore=!r),b(n,"position")),i=i?v:v.states[t],t=i.style.fill,i=(i.textConfig={outsideFill:"inherit"===n.get("color")?t:null,inside:"outside"!==r},b(n,"distance")||0),t=b(n,"align"),a=b(n,"rotate"),s=.5*Math.PI,l=1.5*Math.PI,u=Bs("tangential"===a?Math.PI/2-f:f),s=s<u&&!Er(u-s)&&u<l,u=("outside"===r?(e=d.r+i,t=s?"right":"left"):t&&"center"!==t?"left"===t?(e=d.r0+i,t=s?"right":"left"):"right"===t&&(e=d.r-i,t=s?"left":"right"):(e=g==2*Math.PI&&0===d.r0?0:(d.r+d.r0)/2,t="center"),o.style.align=t,o.style.verticalAlign=b(n,"verticalAlign")||"middle",o.x=e*y+d.cx,o.y=e*m+d.cy,0);"radial"===a?u=Bs(-f)+(s?Math.PI:0):"tangential"===a?u=Bs(Math.PI/2-f)+(s?Math.PI:0):Y(a)&&(u=a*Math.PI/180),o.rotation=Bs(u)}),x.dirtyStyle()};var RC,EC=zC;function zC(t,e,n,i){var o=RC.call(this)||this,r=(o.z2=2,o.textConfig={inside:!0},$(o).seriesIndex=e.seriesIndex,new K({z2:4,silent:t.getModel().get(["label","silent"])}));return o.setTextContent(r),o.updateData(!0,t,e,n,i),o}var VC="sunburstRootToNode",BC="sunburstHighlight",FC="sunburstUnhighlight";function GC(t){t.registerAction({type:VC,update:"updateView"},function(o,t){t.eachComponent({mainType:"series",subType:"sunburst",query:o},function(t,e){var n=gT(o,[VC],t);{var i;n&&((i=t.getViewRoot())&&(o.direction=yT(i,n.node)?"rollUp":"drillDown"),t.resetViewRoot(n.node))}})}),t.registerAction({type:BC,update:"none"},function(e,t,n){e=F({},e),t.eachComponent({mainType:"series",subType:"sunburst",query:e},function(t){t=gT(e,[BC],t);t&&(e.dataIndex=t.node.dataIndex)}),n.dispatchAction(F(e,{type:"highlight"}))}),t.registerAction({type:FC,update:"updateView"},function(t,e,n){t=F({},t),n.dispatchAction(F(t,{type:"downplay"}))})}u(YC,WC=em),YC.prototype.render=function(i,o,r,t){var a,s,e,n=this,l=(this.seriesModel=i,this.api=r,this.ecModel=o,i.getData()),u=l.tree.root,h=i.getViewRoot(),c=this.group,p=i.get("renderLabelForZeroData"),d=[],g=(h.eachNode(function(t){d.push(t)}),this._oldChildren||[]);function f(t){return t.getId()}function y(t,e){var n,t=null==t?null:a[t],e=null==e?null:s[e];(t=p||!t||t.getValue()?t:null)!==u&&e!==u&&(e&&e.piece?t?(e.piece.updateData(!1,t,i,o,r),l.setItemGraphicEl(t.dataIndex,e.piece)):(n=e)&&n.piece&&(c.remove(n.piece),n.piece=null):t&&(e=new EC(t,i,o,r),c.add(e),l.setItemGraphicEl(t.dataIndex,e)))}s=g,0===(a=d).length&&0===s.length||new i1(s,a,f,f).add(y).update(y).remove(P(y,null)).execute(),g=u,0<(e=h).depth?(n.virtualPiece?n.virtualPiece.updateData(!1,g,i,o,r):(n.virtualPiece=new EC(g,i,o,r),c.add(n.virtualPiece)),e.piece.off("click"),n.virtualPiece.on("click",function(t){n._rootToNode(e.parentNode)})):n.virtualPiece&&(c.remove(n.virtualPiece),n.virtualPiece=null),this._initEvents(),this._oldChildren=d},YC.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"))&&Id(t,e.get("target",!0)||"_blank"),i=!0)})})},YC.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:VC,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},YC.prototype.containPoint=function(t,e){var n,e=e.getData().getItemLayout(0);if(e)return n=t[0]-e.cx,t=t[1]-e.cy,(n=Math.sqrt(n*n+t*t))<=e.r&&n>=e.r0},YC.type="sunburst";var WC,HC=YC;function YC(){var t=null!==WC&&WC.apply(this,arguments)||this;return t.type=YC.type,t}u(ZC,XC=Gy),ZC.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data},i=(!function e(t){var n=0;nt(t.children,function(t){e(t);t=t.value;B(t)&&(t=t[0]),n+=t});var i=t.value;B(i)&&(i=i[0]);null!=i&&!isNaN(i)||(i=n);i<0&&(i=0);B(t.value)?t.value[0]=i:t.value=i}(n),this._levelModels=V(t.levels||[],function(t){return new kp(t,this,e)},this)),o=cT.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},ZC.prototype.optionUpdated=function(){this.resetViewRoot()},ZC.prototype.getDataParams=function(t){var e=XC.prototype.getDataParams.apply(this,arguments),t=this.getData().tree.getNodeByDataIndex(t);return e.treePathInfo=mT(t,this),e},ZC.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},ZC.prototype.getViewRoot=function(){return this._viewRoot},ZC.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)},ZC.prototype.enableAriaDecal=function(){DT(this)},ZC.type="series.sunburst",ZC.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"};var XC,UC=ZC;function ZC(){var t=null!==XC&&XC.apply(this,arguments)||this;return t.type=ZC.type,t.ignoreStyleOnData=!0,t}var jC,qC=Math.PI/180;function KC(t,e,r){e.eachSeriesByType(t,function(h){var t=h.get("center"),e=h.get("radius"),n=(B(e)||(e=[0,e]),B(t)||(t=[t,t]),r.getWidth()),i=r.getHeight(),c=Math.min(n,i),p=j(t[0],n),d=j(t[1],i),g=j(e[0],c/2),n=j(e[1],c/2),t=-h.get("startAngle")*qC,f=h.get("minAngle")*qC,y=h.getData().tree.root,i=h.getViewRoot(),m=i.depth,e=h.get("sort"),o=(null!=e&&!function e(t,n){var i=t.children||[];t.children=$C(i,n);i.length&&nt(t.children,function(t){e(t,n)})}(i,e),0),v=(nt(i.children,function(t){isNaN(t.getValue())||o++}),i.getValue()),x=Math.PI/(v||o)*2,_=0<i.depth,e=i.height-(_?-1:1),b=(n-g)/(e||1),w=h.get("clockwise"),S=h.get("stillShowZeroSum"),M=w?1:-1,I=function(t,e){var n,i,o,r,a,s,l,u;if(t)return n=e,t!==y&&(i=t.getValue(),n=e+M*(i=(i=0===v&&S?x:i*x)<f?f:i),r=t.depth-m-(_?-1:1),o=g+b*r,r=g+b*(1+r),(l=h.getLevelModel(t))&&(a=l.get("r0",!0),s=l.get("r",!0),null!=(l=l.get("radius",!0))&&(a=l[0],s=l[1]),null!=a&&(o=j(a,c/2)),null!=s)&&(r=j(s,c/2)),t.setLayout({angle:i,startAngle:e,endAngle:n,clockwise:w,cx:p,cy:d,r0:o,r:r})),t.children&&t.children.length&&(u=0,nt(t.children,function(t){u+=I(t,e+u)})),n-e};_&&(n=2*Math.PI,y.setLayout({angle:n,startAngle:t,endAngle:t+n,clockwise:w,cx:p,cy:d,r0:g,r:g+b})),I(i,t)})}function $C(e,n){var t,i;return D(n)?((t=V(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}})).sort(function(t,e){return n(t.params,e.params)}),V(t,function(t){return e[t.index]})):(i="asc"===n,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 JC(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&&H(e)?Ii(e,(t.depth-1)/(n-1)*.5):e}(t,n,o.root.height)),F(i.ensureUniqueItemVisual(t.dataIndex,"style"),e)})})}function QC(t){var e=t=H(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}r(function(t){t.registerChartView(HC),t.registerSeriesModel(UC),t.registerLayout(P(KC,"sunburst")),t.registerProcessor(P(uS,"sunburst")),t.registerVisual(JC),GC(t)});var tD={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"},eD=W(tD),nD={"alignment-baseline":"textBaseline","stop-color":"stopColor"},iD=W(nD),oD=(rD.prototype.parse=function(t,e){e=e||{};for(var n,i,t=QC(t),o=(this._defsUsePending=[],new Z),r=(this._root=o,[]),a=t.getAttribute("viewBox")||"",s=parseFloat(t.getAttribute("width")||e.width),l=parseFloat(t.getAttribute("height")||e.height),u=(isNaN(s)&&(s=null),isNaN(l)&&(l=null),cD(t,o,null,!0,!1),t.firstChild);u;)this._parseNode(u,o,r,null,!1,!1),u=u.nextSibling;for(var h=this._defs,c=this._defsUsePending,p=0;p<c.length;p++){var d=c[p];d[0].style[d[1]]=h[d[2]]}return this._defsUsePending=[],(n=a&&4<=(t=fD(a)).length?{x:parseFloat(t[0]||0),y:parseFloat(t[1]||0),width:parseFloat(t[2]),height:parseFloat(t[3])}:n)&&null!=s&&null!=l&&(i=_D(n,{x:0,y:0,width:s,height:l}),e.ignoreViewBox||(a=o,(o=new Z).add(a),a.scaleX=a.scaleY=i.scale,a.x=i.x,a.y=i.y)),e.ignoreRootClip||null==s||null==l||o.setClipPath(new L({shape:{x:0,y:0,width:s,height:l}})),{root:o,width:s,height:l,viewBoxRect:n,viewBoxTransform:i,named:r}},rD.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=jC[l])&&X(jC,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)),(s=aD[l])&&X(aD,l)&&(i=s.call(this,t),e=t.getAttribute("id"))&&(this._defs[e]=i)),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},rD.prototype._parseText=function(t,e){var n=new il({style:{text:t.textContent},silent:!0,x:this._textX||0,y:this._textY||0}),t=(uD(e,n),cD(t,n,this._defsUsePending,!1,!1),n),i=e,o=i.__selfStyle,o=(o&&(o=o.textBaseline,!(r=o)||"auto"===o||"baseline"===o?r="alphabetic":"before-edge"===o||"text-before-edge"===o?r="top":"after-edge"===o||"text-after-edge"===o?r="bottom":"central"!==o&&"mathematical"!==o||(r="middle"),t.style.textBaseline=r),(o=i.__inheritedStyle)&&(r=o.textAlign,i=r)&&("middle"===r&&(i="center"),t.style.textAlign=i),n.style),r=o.fontSize,t=(r&&r<9&&(o.fontSize=9,n.scaleX*=r/9,n.scaleY*=r/9),(o.fontSize||o.fontFamily)&&[o.fontStyle,o.fontWeight,(o.fontSize||12)+"px",o.fontFamily||"sans-serif"].join(" ")),i=(o.font=t,n.getBoundingRect());return this._textX+=i.width,e.add(n),n},rD.internalField=void(jC={g:function(t,e){var n=new Z;return uD(e,n),cD(t,n,this._defsUsePending,!1,!1),n},rect:function(t,e){var n=new L;return uD(e,n),cD(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 eh;return uD(e,n),cD(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 Fh;return uD(e,n),cD(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 rh;return uD(e,n),cD(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,i=t.getAttribute("points"),i=(i&&(n=hD(i)),new Lh({shape:{points:n||[]},silent:!0}));return uD(e,i),cD(t,i,this._defsUsePending,!1,!1),i},polyline:function(t,e){var n,i=t.getAttribute("points"),i=(i&&(n=hD(i)),new Rh({shape:{points:n||[]},silent:!0}));return uD(e,i),cD(t,i,this._defsUsePending,!1,!1),i},image:function(t,e){var n=new ll;return uD(e,n),cD(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",n=(this._textX=parseFloat(n)+parseFloat(o),this._textY=parseFloat(i)+parseFloat(r),new Z);return uD(e,n),cD(t,n,this._defsUsePending,!1,!0),n},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y"),n=(null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i)),t.getAttribute("dx")||"0"),i=t.getAttribute("dy")||"0",o=new Z;return uD(e,o),cD(t,o,this._defsUsePending,!1,!0),this._textX+=parseFloat(n),this._textY+=parseFloat(i),o},path:function(t,e){var n=Ju(t.getAttribute("d")||"");return uD(e,n),cD(t,n,this._defsUsePending,!1,!1),n.silent=!0,n}}),rD);function rD(){this._defs={},this._root=null}var aD={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),e=new ic(e,n,i,o);return sD(t,e),lD(t,e),e},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),e=new ac(e,n,i);return sD(t,e),lD(t,e),e}};function sD(t,e){"userSpaceOnUse"===t.getAttribute("gradientUnits")&&(e.global=!0)}function lD(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,xD(o,i={},i),i=i.stopColor||o.getAttribute("stop-color")||"#000000",e.colorStops.push({offset:n,color:i})),o=o.nextSibling}function uD(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),z(e.__inheritedStyle,t.__inheritedStyle))}function hD(t){for(var e=fD(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 cD(t,e,n,i,o){var r=e,a=r.__inheritedStyle=r.__inheritedStyle||{},s={};if(1===t.nodeType){var l=t;if(l=l.getAttribute("transform")){l=l.replace(/,/g," ");var u=[],h=null;l.replace(yD,function(t,e,n){return u.push(e,n),""});for(var c=u.length-1;0<c;c-=2){var p=u[c-1],d=fD(u[c]);switch(h=h||ze(),p){case"translate":Ge(h,h,[parseFloat(d[0]),parseFloat(d[1]||"0")]);break;case"scale":He(h,h,[parseFloat(d[0]),parseFloat(d[1]||d[0])]);break;case"rotate":We(h,h,-parseFloat(d[0])*mD,[parseFloat(d[1]||"0"),parseFloat(d[2]||"0")]);break;case"skewX":var g=Math.tan(parseFloat(d[0])*mD);Fe(h,[1,0,g,1,0,0],h);break;case"skewY":g=Math.tan(parseFloat(d[0])*mD);Fe(h,[1,g,0,1,0,0],h);break;case"matrix":h[0]=parseFloat(d[0]),h[1]=parseFloat(d[1]),h[2]=parseFloat(d[2]),h[3]=parseFloat(d[3]),h[4]=parseFloat(d[4]),h[5]=parseFloat(d[5])}}e.setLocalTransform(h)}if(xD(t,a,s),!i){for(var f=t,y=a,m=s,v=0;v<eD.length;v++){var x=eD[v];null!=(_=f.getAttribute(x))&&(y[tD[x]]=_)}for(v=0;v<iD.length;v++){var _,x=iD[v];null!=(_=f.getAttribute(x))&&(m[nD[x]]=_)}}}r.style=r.style||{},null!=a.fill&&(r.style.fill=dD(r,"fill",a.fill,n)),null!=a.stroke&&(r.style.stroke=dD(r,"stroke",a.stroke,n)),nt(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(t){null!=a[t]&&(r.style[t]=parseFloat(a[t]))}),nt(["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=V(fD(a.lineDash),function(t){return parseFloat(t)})),"hidden"!==a.visibility&&"collapse"!==a.visibility||(r.invisible=!0),"none"===a.display&&(r.ignore=!0)}var pD=/^url\(\s*#(.*?)\)/;function dD(t,e,n,i){var o=n&&n.match(pD);if(!o)return n="none"===n?null:n;n=Ct(o[1]),i.push([t,e,n])}var gD=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function fD(t){return t.match(gD)||[]}var yD=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,mD=Math.PI/180;var vD=/([^\s:;]+)\s*:\s*([^:;]+)/g;function xD(t,e,n){var i,o=t.getAttribute("style");if(o)for(vD.lastIndex=0;null!=(i=vD.exec(o));){var r=i[1],a=X(tD,r)?tD[r]:null,a=(a&&(e[a]=i[2]),X(nD,r)?nD[r]:null);a&&(n[a]=i[2])}}function _D(t,e){var n=e.width/t.width,i=e.height/t.height,n=Math.min(n,i);return{scale:n,x:-(t.x+t.width/2)*n+(e.x+e.width/2),y:-(t.y+t.height/2)*n+(e.y+e.height/2)}}var bD=R(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),wD=(SD.prototype.load=function(){var t,e,n,i;return this._firstGraphic||(e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone(),e=e.named,n=[],i=R(),nt(e,function(t){var e;null==t.namedFrom&&(e=new g_(t.name,t.el),n.push(e),i.set(t.name,e))}),t=(e={regions:n,regionsMap:i}).regionsMap,this._regions=e.regions,this._regionsMap=t),{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},SD.prototype._buildGraphic=function(t){var e,n,i,o;try{Tt(null!=(n=(e=t&&(i=t,o={ignoreViewBox:!0,ignoreRootClip:!0},(new oD).parse(i,o))||{}).root))}catch(t){throw new Error("Invalid svg format\n"+t.message)}var r,a,s,l,t=new Z,u=(t.add(n),t.isGeoSVGGraphicRoot=!0,e.width),h=e.height,c=e.viewBoxRect,p=this._boundingRect,d=(p||(l=s=a=r=void 0,null!=u?(r=0,s=u):c&&(r=c.x,s=c.width),null!=h?(a=0,l=h):c&&(a=c.y,l=c.height),null!=r&&null!=a||(u=n.getBoundingRect(),null==r&&(r=u.x,s=u.width),null==a&&(a=u.y,l=u.height)),p=this._boundingRect=new U(r,a,s,l)),c&&(h=_D(c,p),n.scaleX=n.scaleY=h.scale,n.x=h.x,n.y=h.y),t.setClipPath(new L({shape:p.plain()})),[]);return nt(e.named,function(t){null!=bD.get(t.svgNodeTagLower)&&(d.push(t),(t=t.el).silent=!1,t.isGroup)&&t.traverse(function(t){t.silent=!1})}),{root:t,boundingRect:p,named:d}},SD.prototype.useGraphic=function(t){var e=this._usedGraphicMap,n=e.get(t);return n||(n=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),e.set(t,n)),n},SD.prototype.freeGraphic=function(t){var e=this._usedGraphicMap,n=e.get(t);n&&(e.removeKey(t),this._freedGraphics.push(n))},SD);function SD(t,e){this.type="geoSVG",this._usedGraphicMap=R(),this._freedGraphics=[],this._mapName=t,this._parsedXML=QC(e)}for(var MD=[126,25],ID=[[[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]]],TD=0;TD<ID.length;TD++)for(var CD=0;CD<ID[TD].length;CD++)ID[TD][CD][0]/=10.5,ID[TD][CD][1]/=-14,ID[TD][CD][0]+=MD[0],ID[TD][CD][1]+=MD[1];var DD={"åæµ·è¯¸å²":[32,80],"广ä¸":[0,-10],"馿¸¯":[10,5],"æ¾³é¨":[-10,10],"天津":[5,5]};var AD=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];LD.prototype.load=function(n,t){var e,i=this._parsedMap.get(t=t||"name"),o=(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)})),R()),r=[];return nt(i.regions,function(t){var e=t.name;n&&X(n,e)&&(t=t.cloneShallow(e=n[e])),r.push(t),o.set(e,t)}),{regions:r,boundingRect:i.boundingRect||new U(0,0,0,0),regionsMap:o}},LD.prototype._parseToRegions=function(t){var e,r=this._mapName,n=this._geoJSON;try{e=n?v_(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 c_("åæµ·è¯¸å²",V(ID,function(t){return{type:"polygon",exterior:t}}),MD))}}(r,e),nt(e,function(t){var e,n,i=t.name,o=(o=t,"china"===(n=r)&&(n=DD[o.name])&&((e=o.getCenter())[0]+=n[0]/10.5,e[1]+=-n[1]/14,o.setCenter(e)),n=t,"china"===r&&"å°æ¹¾"===n.name&&n.geometries.push({type:"polygon",exterior:AD[0]}),this._specialAreas&&this._specialAreas[i]);o&&t.transformTo(o.left,o.top,o.width,o.height)},this),e},LD.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}};var kD=LD;function LD(t,e,n){this.type="geoJSON",this._parsedMap=R(),this._mapName=t,this._specialAreas=n,this._geoJSON=H(t=e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(t):new Function("return ("+t+");")():t}var PD=R(),OD={registerMap:function(t,e,n){var i;e=e.svg?new wD(t,e.svg):((i=e.geoJson||e.geoJSON)&&!e.features?n=e.specialAreas:i=e,new kD(t,i,n)),PD.set(t,e)},getGeoResource:function(t){return PD.get(t)},getMapForUser:function(t){t=PD.get(t);return t&&"geoJSON"===t.type&&t.getMapForUser()},load:function(t,e,n){t=PD.get(t);if(t)return t.load(e,n)}},n0=["rect","circle","line","ellipse","polygon","polyline","path"],ND=R(n0),RD=R(n0.concat(["g"])),ED=R(n0.concat(["g"])),zD=i();function VD(t){var e=t.getItemStyle(),t=t.get("areaColor");return null!=t&&(e.fill=t),e}function BD(t){t=t.style;t&&(t.stroke=t.stroke||t.fill,t.fill=null)}GD.prototype.draw=function(e,t,n,i,o){var r="geo"===e.mainType,a=e.getData&&e.getData(),s=(r&&t.eachComponent({mainType:"series",subType:"map"},function(t){a||t.getHostGeoModel()!==e||(a=t.getData())}),e.coordinateSystem),l=this._regionsGroup,u=this.group,h=s.getTransformInfo(),c=h.raw,h=h.roam,o=(!l.childAt(0)||o?(u.x=h.x,u.y=h.y,u.scaleX=h.scaleX,u.scaleY=h.scaleY,u.dirty()):C(u,h,e),a&&a.getVisual("visualMeta")&&0<a.getVisual("visualMeta").length),u={api:n,geo:s,mapOrGeoModel:e,data:a,isVisualEncodedByVisualMap:o,isGeo:r,transformInfoRaw:c};"geoJSON"===s.resourceType?this._buildGeoJSON(u):"geoSVG"===s.resourceType&&this._buildSVG(u),this._updateController(e,t,n),this._updateMapSelectHandler(e,l,n,i)},GD.prototype._buildGeoJSON=function(h){var c=this._regionsGroupByName=R(),p=R(),d=this._regionsGroup,n=h.transformInfoRaw,g=h.mapOrGeoModel,f=h.data,y=h.geo.projection,m=y&&y.stream;function v(t,e){return(t=e?e(t):t)&&[t[0]*n.scaleX+n.x,t[1]*n.scaleY+n.y]}function x(t){return{shape:{points:function(t){for(var e=[],n=!m&&y&&y.project,i=0;i<t.length;++i){var o=v(t[i],n);o&&e.push(o)}return e}(t)}}}d.removeAll(),nt(h.geo.regions,function(t){var n=t.name,i=c.get(n),e=p.get(n)||{},o=e.dataIdx,r=e.regionModel,a=(i||(i=c.set(n,new Z),d.add(i),o=f?f.indexOfName(n):null,r=h.isGeo?g.getRegionModel(n):f?f.getItemModel(o):null,p.set(n,{dataIdx:o,regionModel:r})),[]),s=[],l=(nt(t.geometries,function(t){var e;"polygon"===t.type?(e=[t.exterior].concat(t.interiors||[]),nt(e=m?ZD(e,m):e,function(t){a.push(new Lh(x(t)))})):(e=t.points,nt(e=m?ZD(e,m,!0):e,function(t){s.push(new Rh(x(t)))}))}),v(t.getCenter(),y&&y.project));function u(t,e){t.length&&(t=new Qh({culling:!0,segmentIgnoreThreshold:1,shape:{paths:t}}),i.add(t),WD(h,t,o,r),HD(h,t,n,r,g,o,l),e)&&(BD(t),nt(t.states,BD))}u(a),u(s,!0)}),c.each(function(t,e){var n=p.get(e),i=n.dataIdx,n=n.regionModel;YD(h,t,e,n,g,i),XD(h,t,e,n,g),UD(h,t,e,n,g)},this)},GD.prototype._buildSVG=function(s){var t=s.geo.map,e=s.transformInfoRaw,l=(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)),this._svgDispatcherMap=R()),u=!1;nt(this._svgGraphicRecord.named,function(t){var e=t.name,n=s.mapOrGeoModel,i=s.data,o=t.svgNodeTagLower,r=t.el,i=i?i.indexOfName(e):null,a=n.getRegionModel(e);null!=ND.get(o)&&r instanceof ts&&WD(s,r,i,a),r instanceof ts&&(r.culling=!0),r.z2EmphasisLift=0,t.namedFrom||(null!=ED.get(o)&&HD(s,r,e,a,n,i,null),YD(s,r,e,a,n,i),XD(s,r,e,a,n),null!=RD.get(o)&&("self"===UD(s,r,e,a,n)&&(u=!0),(l.get(e)||l.set(e,[])).push(r)))},this),this._enableBlurEntireSVG(u,s)},GD.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||(lu(t),null==(e=t.ensureState("blur").style||{}).opacity&&null!=n&&(e.opacity=n),t.ensureState("emphasis"))}))},GD.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},GD.prototype.findHighDownDispatchers=function(t,e){if(null==t)return[];e=e.coordinateSystem;if("geoJSON"===e.resourceType){var n=this._regionsGroupByName;if(n)return(n=n.get(t))?[n]:[]}else if("geoSVG"===e.resourceType)return this._svgDispatcherMap&&this._svgDispatcherMap.get(t)||[]},GD.prototype._svgResourceChanged=function(t){return this._svgMapName!==t},GD.prototype._useSVG=function(t){var e=OD.getGeoResource(t);e&&"geoSVG"===e.type&&(e=e.useGraphic(this.uid),this._svgGroup.add(e.root),this._svgGraphicRecord=e,this._svgMapName=t)},GD.prototype._freeSVG=function(){var t=this._svgMapName;null!=t&&((t=OD.getGeoResource(t))&&"geoSVG"===t.type&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null)},GD.prototype._updateController=function(i,t,o){var r=i.coordinateSystem,e=this._controller,n=this._controllerHost,a=(n.zoomLimit=i.get("scaleLimit"),n.zoom=r.getZoom(),e.enable(i.get("roam")||!1),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,D2(n,t.dx,t.dy),o.dispatchAction(F(s(),{dx:t.dx,dy:t.dy,animation:{duration:0}}))},this),e.off("zoom").on("zoom",function(t){this._mouseDownFlag=!1,A2(n,t.scale,t.originX,t.originY),o.dispatchAction(F(s(),{zoom:t.scale,originX:t.originX,originY:t.originY,animation:{duration:0}}))},this),e.setPointerChecker(function(t,e,n){return r.containPoint([e,n])&&!F2(t,o,i)})},GD.prototype.resetForLabelLayout=function(){this.group.traverse(function(t){t=t.getTextContent();t&&(t.ignore=zD(t).ignore)})},GD.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)}))};var FD=GD;function GD(t){var e=new Z;this.uid=Op("ec_map_draw"),this._controller=new N2(t.getZr()),this._controllerHost={target:e},(this.group=e).add(this._regionsGroup=new Z),e.add(this._svgGroup=new Z)}function WD(t,e,n,i){var o,r=i.getModel("itemStyle"),a=i.getModel(["emphasis","itemStyle"]),s=i.getModel(["blur","itemStyle"]),i=i.getModel(["select","itemStyle"]),r=VD(r),a=VD(a),i=VD(i),s=VD(s),l=t.data;l&&(o=l.getItemVisual(n,"style"),l=l.getItemVisual(n,"decal"),t.isVisualEncodedByVisualMap&&o.fill&&(r.fill=o.fill),l)&&(r.decal=V0(l,t.api)),e.setStyle(r),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=a,e.ensureState("select").style=i,e.ensureState("blur").style=s,lu(e)}function HD(t,e,n,i,o,r,a){var s=t.data,t=t.isGeo,l=s&&isNaN(s.get(s.mapDimension("value"),r)),u=s&&s.getItemLayout(r);t||l||u&&u.showLabel?(l=t?n:r,u=!s||0<=r?o:void 0,t=a?{normal:{align:"center",verticalAlign:"middle"}}:null,op(e,rp(i),{labelFetcher:u,labelDataIndex:l,defaultText:n},t),(s=e.getTextContent())&&(zD(s).ignore=s.ignore,e.textConfig)&&a&&(r=e.getBoundingRect().clone(),e.textConfig.layoutRect=r,e.textConfig.position=[(a[0]-r.x)/r.width*100+"%",(a[1]-r.y)/r.height*100+"%"]),e.disableLabelAnimation=!0):(e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null)}function YD(t,e,n,i,o,r){t.data?t.data.setItemGraphicEl(r,e):$(e).eventData={componentType:"geo",componentIndex:o.componentIndex,geoIndex:o.componentIndex,name:n,region:i&&i.option||{}}}function XD(t,e,n,i,o){t.data||$c({el:e,componentModel:o,itemName:n,itemTooltipOption:i.get("tooltip")})}function UD(t,e,n,i,o){e.highDownSilentOnTouch=!!o.get("selectedMode");var i=i.getModel("emphasis"),r=i.get("focus");return Mu(e,r,i.get("blurScope"),i.get("disabled")),t.isGeo&&(i=o,t=n,(o=$(o=e)).componentMainType=i.mainType,o.componentIndex=i.componentIndex,o.componentHighDownName=t),r}function ZD(t,e,n){var i,o=[];function r(){i=[]}function a(){i.length&&(o.push(i),i=[])}var s=e({polygonStart:r,polygonEnd:a,lineStart:r,lineEnd:a,point:function(t,e){isFinite(t)&&isFinite(e)&&i.push([t,e])},sphere:function(){}});return n||s.polygonStart(),nt(t,function(t){s.lineStart();for(var e=0;e<t.length;e++)s.point(t[e][0],t[e][1]);s.lineEnd()}),n||s.polygonEnd(),o}u(KD,jD=em),KD.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 FD(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))},KD.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},KD.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},KD.prototype._renderSymbols=function(a,t,e){var s=a.originalData,l=this.group;s.each(s.mapDimension("value"),function(t,e){var n,i,o,r;isNaN(t)||(t=s.getItemLayout(e))&&t.point&&(r=t.point,t=t.offset,n=new eh({style:{fill:a.getData().getVisual("style").fill},shape:{cx:r[0]+9*t,cy:r[1],r:3},silent:!0,z2:8+(t?0:11)}),t||(r=a.mainSeries.getData(),t=s.getName(e),i=r.indexOfName(t),o=(e=s.getItemModel(e)).getModel("label"),r=r.getItemGraphicEl(i),op(n,rp(e),{labelFetcher:{getFormattedLabel:function(t,e){return a.getFormattedLabel(i,e)}},defaultText:t}),n.disableLabelAnimation=!0,o.get("position")||n.setTextConfig({position:"bottom"}),r.onHoverStateChange=function(t){ru(n,t)}),l.add(n))})},KD.type="map";var jD,qD=KD;function KD(){var t=null!==jD&&jD.apply(this,arguments)||this;return t.type=KD.type,t}u(QD,$D=Gy),QD.prototype.getInitialData=function(t){for(var e=bS(this,{coordDimensions:["value"],encodeDefaulter:P(ig,this)}),n=R(),i=[],o=0,r=e.count();o<r;o++){var a=e.getName(o);n.set(a,!0)}return nt(OD.load(this.getMapType(),this.option.nameMap,this.option.nameProperty).regions,function(t){t=t.name;n.get(t)||i.push(t)}),e.appendValues([],i),e},QD.prototype.getHostGeoModel=function(){var t=this.option.geoIndex;return null!=t?this.ecModel.getComponent("geo",t):null},QD.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},QD.prototype.getRawValue=function(t){var e=this.getData();return e.get(e.mapDimension("value"),t)},QD.prototype.getRegionModel=function(t){var e=this.getData();return e.getItemModel(e.indexOfName(t))},QD.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 Iy("section",{header:s.join(", "),noHeader:!s.length,blocks:[Iy("nameValue",{name:r,value:o})]})},QD.prototype.setZoom=function(t){this.option.zoom=t},QD.prototype.setCenter=function(t){this.option.center=t},QD.prototype.getLegendIcon=function(t){var e=t.icon||"roundRect",n=s0(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},QD.type="series.map",QD.dependencies=["geo"],QD.layoutMode="box",QD.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"};var $D,JD=QD;function QD(){var t=null!==$D&&$D.apply(this,arguments)||this;return t.type=QD.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(t){var e;if(null!=t)return t=this.getData().getName(t),(t=(e=this.coordinateSystem).getRegion(t))&&e.dataToPoint(t.getCenter())},t}function tA(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)}),nt(n,function(t,e){l=V(t,function(t){return t.getData()}),u=t[0].get("mapValueCalculation"),h={},nt(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)})});for(var l,u,h,n=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 e="min"===u?o:"max"===u?r:"average"===u?i/a:i,0===a?NaN:e}),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 eA(n){var o={};n.eachSeriesByType("map",function(t){var a,i,e=t.getMapType();t.getHostGeoModel()||o[e]||(a={},nt(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 nA,iA={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},oA=["lng","lat"],rA=(u(aA,nA=I2),aA.prototype._transformTo=function(t,e,n,i){var o=this.getBoundingRect(),r=this._invertLongitute,o=o.clone(),a=(r&&(o.y=-o.y-o.height),this._rawTransformable),o=(a.transform=o.calculateTransform(new U(t,e,n,i)),a.parent);a.parent=null,a.decomposeTransform(),a.parent=o,r&&(a.scaleY=-a.scaleY),this._updateTransform()},aA.prototype.getRegion=function(t){return this._regionsMap.get(t)},aA.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]}},aA.prototype.addGeoCoord=function(t,e){this._nameCoordMap.set(t,e)},aA.prototype.getGeoCoord=function(t){var e=this._regionsMap.get(t);return this._nameCoordMap.get(t)||e&&e.getCenter()},aA.prototype.dataToPoint=function(t,e,n){var i;if(t=H(t)?this.getGeoCoord(t):t)return(t=(i=this.projection)?i.project(t):t)&&this.projectedToPoint(t,e,n)},aA.prototype.pointToData=function(t){var e=this.projection;return(t=e?e.unproject(t):t)&&this.pointToProjected(t)},aA.prototype.pointToProjected=function(t){return nA.prototype.pointToData.call(this,t)},aA.prototype.projectedToPoint=function(t,e,n){return nA.prototype.dataToPoint.call(this,t,e,n)},aA.prototype.convertToPixel=function(t,e,n){e=sA(e);return e===this?e.dataToPoint(n):null},aA.prototype.convertFromPixel=function(t,e,n){e=sA(e);return e===this?e.pointToData(n):null},aA);function aA(t,e,n){var t=nA.call(this,t)||this,i=(t.dimensions=oA,t.type="geo",t._nameCoordMap=R(),t.map=e,n.projection),o=OD.load(e,n.nameMap,n.nameProperty),e=OD.getGeoResource(e),r=(t.resourceType=e?e.type:null,t.regions=o.regions),e=iA[e.type];if(t._regionsMap=o.regionsMap,t.regions=o.regions,t.projection=i)for(var a=0;a<r.length;a++){var s,l=r[a].getBoundingRect(i);(s=s||l.clone()).union(l)}else s=o.boundingRect;return t.setBoundingRect(s.x,s.y,s.width,s.height),t.aspectScale=i?1:N(n.aspectScale,e.aspectScale),t._invertLongitute=!i&&e.invertLongitute,t}function sA(t){var e=t.geoModel,t=t.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",da).models[0]||{}).coordinateSystem:null}function lA(t,e){var l,u,h,n,i,o,r=t.get("boundingCoords"),a=(null!=r&&(u=r[0],h=r[1],isFinite(u[0]))&&isFinite(u[1])&&isFinite(h[0])&&isFinite(h[1])&&((l=this.projection)&&(r=u[0],p=u[1],c=h[0],s=h[1],u=[1/0,1/0],h=[-1/0,-1/0],(a=function(t,e,n,i){for(var o=n-t,r=i-e,a=0;a<=100;a++){var s=a/100,s=l.project([t+o*s,e+r*s]);re(u,u,s),ae(h,h,s)}})(r,p,c,p),a(c,p,c,s),a(c,s,r,s),a(r,s,c,p)),this.setBoundingRect(u[0],u[1],h[0]-u[0],h[1]-u[1])),this.getBoundingRect()),r=t.get("layoutCenter"),s=t.get("layoutSize"),c=e.getWidth(),p=e.getHeight(),a=a.width/a.height*this.aspectScale,d=!1;r&&s&&(n=[j(r[0],c),j(r[1],p)],i=j(s,Math.min(c,p)),isNaN(n[0])||isNaN(n[1])||isNaN(i)||(d=!0)),d?(o={},1<a?(o.width=i,o.height=i/a):(o.height=i,o.width=i*a),o.y=n[1]-o.height/2,o.x=n[0]-o.width/2):((r=t.getBoxLayoutParams()).aspect=a,o=Ld(r,{width:c,height:p})),this.setViewRect(o.x,o.y,o.width,o.height),this.setCenter(t.get("center"),e),this.setZoom(t.get("zoom"))}function uA(){this.dimensions=oA}ut(rA,I2),uA.prototype.create=function(t,o){var r=[];function a(t){return{nameProperty:t.get("nameProperty"),aspectScale:t.get("aspectScale"),projection:t.get("projection")}}t.eachComponent("geo",function(t,e){var n=t.get("map"),e=new rA(n+e,n,F({nameMap:t.get("nameMap")},a(t)));e.zoomLimit=t.get("scaleLimit"),r.push(e),(t.coordinateSystem=e).model=t,e.resize=lA,e.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))}),nt(n,function(t,e){var n=V(t,function(t){return t.get("nameMap")}),i=new rA(e,e,F({nameMap:at(n)},a(t[0])));i.zoomLimit=wt.apply(null,V(t,function(t){return t.get("scaleLimit")})),r.push(i),i.resize=lA,i.resize(t[0],o),nt(t,function(t){var n;t.coordinateSystem=i,n=i,nt(t.get("geoCoord"),function(t,e){n.addGeoCoord(e,t)})})}),r},uA.prototype.getFilledRegions=function(t,e,n,i){for(var o=(t||[]).slice(),r=R(),a=0;a<o.length;a++)r.set(o[a].name,o[a]);return nt(OD.load(e,n,i).regions,function(t){t=t.name;r.get(t)||o.push({name:t})}),o};var hA,cA=new uA,pA=(u(dA,hA=g),dA.prototype.init=function(t,e,n){var i=OD.getGeoResource(t.map);!i||"geoJSON"!==i.type||"color"in(i=t.itemStyle=t.itemStyle||{})||(i.color="#eee"),this.mergeDefaultAndTheme(t,n),Qr(t,"label",["show"])},dA.prototype.optionUpdated=function(){var i=this,t=this.option,o=(t.regions=cA.getFilledRegions(t.regions,t.map,t.nameMap,t.nameProperty),{});this._optionModelMap=ct(t.regions||[],function(t,e){var n=e.name;return n&&(t.set(n,new kp(e,i,i.ecModel)),e.selected)&&(o[n]=!0),t},R()),t.selectedMap||(t.selectedMap=o)},dA.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new kp(null,this,this.ecModel)},dA.prototype.getFormattedLabel=function(t,e){var n=this.getRegionModel(t),n="normal"===e?n.get(["label","formatter"]):n.get(["emphasis","label","formatter"]),i={name:t};return D(n)?(i.status=e,n(i)):H(n)?n.replace("{a}",null!=t?t:""):void 0},dA.prototype.setZoom=function(t){this.option.zoom=t},dA.prototype.setCenter=function(t){this.option.center=t},dA.prototype.select=function(t){var e=this.option,n=e.selectedMode;n&&("multiple"!==n&&(e.selectedMap=null),(e.selectedMap||(e.selectedMap={}))[t]=!0)},dA.prototype.unSelect=function(t){var e=this.option.selectedMap;e&&(e[t]=!1)},dA.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},dA.prototype.isSelected=function(t){var e=this.option.selectedMap;return!(!e||!e[t])},dA.type="geo",dA.layoutMode="box",dA.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},dA);function dA(){var t=null!==hA&&hA.apply(this,arguments)||this;return t.type=dA.type,t}u(yA,gA=Ky),yA.prototype.init=function(t,e){this._api=e},yA.prototype.render=function(t,e,n,i){var o;(this._model=t).get("show")?(this._mapDraw||(this._mapDraw=new FD(n)),(o=this._mapDraw).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)):(this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null)},yA.prototype._handleRegionClick=function(t){var e;jm(t.target,function(t){return null!=(e=$(t).eventData)},!0),e&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:e.name})},yA.prototype.updateSelectStatus=function(t,e,n){var i=this;this._mapDraw.group.traverse(function(t){var e=$(t).eventData;if(e)return i._model.isSelected(e.name)?n.enterSelect(t):n.leaveSelect(t),!0})},yA.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},yA.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},yA.type="geo";var gA,fA=yA;function yA(){var t=null!==gA&&gA.apply(this,arguments)||this;return t.type=yA.type,t.focusBlurEnabled=!0,t}function mA(t,e,n){OD.registerMap(t,e,n)}function vA(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);nt(e.coordinateSystem.regions,function(t){i[t.name]=e.isSelected(t.name)||!1});var n=[];nt(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",cA),e.registerComponentModel(pA),e.registerComponentView(fA),e.registerImpl("registerMap",mA),e.registerImpl("getMap",function(t){return OD.getMapForUser(t)}),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,o){var r=i.componentType||"series";t.eachComponent({mainType:r,query:i},function(t){var e,n=t.coordinateSystem;"geo"===n.type&&(e=IT(n,i,t.get("scaleLimit"),o),t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom),"series"===r)&&nt(t.seriesGroup,function(t){t.setCenter(e.center),t.setZoom(e.zoom)})})})}r(function(t){r(vA),t.registerChartView(qD),t.registerSeriesModel(JD),t.registerLayout(eA),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,tA),Um("map",t.registerAction)});var xA,_A=Fh.prototype,bA=Uh.prototype,wA=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1};function SA(){return null!==xA&&xA.apply(this,arguments)||this}function MA(t){return isNaN(+t.cpx1)||isNaN(+t.cpy1)}u(SA,xA=wA);u(CA,IA=q),CA.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},CA.prototype.getDefaultShape=function(){return new wA},CA.prototype.buildPath=function(t,e){(MA(e)?_A:bA).buildPath.call(this,t,e)},CA.prototype.pointAt=function(t){return(MA(this.shape)?_A:bA).pointAt.call(this,t)},CA.prototype.tangentAt=function(t){var e=this.shape,e=MA(e)?[e.x2-e.x1,e.y2-e.y1]:bA.tangentAt.call(this,t);return Jt(e,e)};var IA,TA=CA;function CA(t){t=IA.call(this,t)||this;return t.type="ec-line",t}var DA=["fromSymbol","toSymbol"];function AA(t){return"_"+t+"Type"}function kA(t,e,n){var i,o,r,a=e.getItemVisual(n,t);return a&&"none"!==a?(i=e.getItemVisual(n,t+"Size"),o=e.getItemVisual(n,t+"Rotate"),r=e.getItemVisual(n,t+"Offset"),e=e.getItemVisual(n,t+"KeepAspect"),a+(n=l0(i))+u0(r||0,n)+(o||"")+(e||"")):a}function LA(t,e,n){var i,o,r,a=e.getItemVisual(n,t);if(a&&"none"!==a)return r=e.getItemVisual(n,t+"Size"),i=e.getItemVisual(n,t+"Rotate"),o=e.getItemVisual(n,t+"Offset"),e=e.getItemVisual(n,t+"KeepAspect"),o=u0(o||0,n=l0(r)),(r=s0(a,-n[0]/2+o[0],-n[1]/2+o[1],n[0],n[1],null,e)).__specifiedRotation=null==i||isNaN(i)?void 0:+i*Math.PI/180||0,r.name=t,r}function PA(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)}u(RA,OA=Z),RA.prototype._createLine=function(n,i,t){var e,o=n.hostModel,r=n.getItemLayout(i),r=(r=r,PA((e=new TA({name:"line",subPixelOptimize:!0})).shape,r),e);r.shape.percent=0,_c(r,{shape:{percent:1}},o,i),this.add(r),nt(DA,function(t){var e=LA(t,n,i);this.add(e),this[AA(t)]=kA(t,n,i)},this),this._updateCommonStl(n,i,t)},RA.prototype.updateData=function(i,o,t){var e=i.hostModel,n=this.childOfName("line"),r=i.getItemLayout(o),a={shape:{}};PA(a.shape,r),C(n,a,e,o),nt(DA,function(t){var e=kA(t,i,o),n=AA(t);this[n]!==e&&(this.remove(this.childOfName(t)),t=LA(t,i,o),this.add(t)),this[n]=e},this),this._updateCommonStl(i,o,t)},RA.prototype.getLinePath=function(){return this.childAt(0)},RA.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,u=e&&e.emphasisDisabled,h=e&&e.focus,c=e&&e.blurScope,p=(e&&!n.hasItemOption||(o=(g=(e=n.getItemModel(t)).getModel("emphasis")).getModel("lineStyle").getLineStyle(),a=e.getModel(["blur","lineStyle"]).getLineStyle(),s=e.getModel(["select","lineStyle"]).getLineStyle(),u=g.get("disabled"),h=g.get("focus"),c=g.get("blurScope"),l=rp(e)),n.getItemVisual(t,"style")),d=p.stroke,g=(r.useStyle(p),r.style.fill=null,r.style.strokeNoScale=!0,r.ensureState("emphasis").style=o,r.ensureState("blur").style=a,r.ensureState("select").style=s,nt(DA,function(t){var e=this.childOfName(t);if(e){e.setColor(d),e.style.opacity=p.opacity;for(var n=0;n<Wl.length;n++){var i=Wl[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),i.getRawValue(t)),e=(op(this,l,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(t,e){return i.getFormattedLabel(t,e,n.dataType)}},inheritColor:d||"#000",defaultOpacity:p.opacity,defaultText:(null==g?n.getName(t):isFinite(g)?Dr(g):g)+""}),this.getTextContent());e&&(o=l.normal,e.__align=e.style.align,e.__verticalAlign=e.style.verticalAlign,e.__position=o.get("position")||"middle",B(a=o.get("distance"))||(a=[a,a]),e.__labelDistance=a),this.setTextConfig({position:null,local:!0,inside:!1}),Mu(this,h,c,u)},RA.prototype.highlight=function(){cu(this)},RA.prototype.downplay=function(){pu(this)},RA.prototype.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},RA.prototype.setLinePoints=function(t){var e=this.childOfName("line");PA(e.shape,t),e.dirty()},RA.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=jt([],l,s);if(Jt(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,t=n.__labelDistance,p=t[0]*i,d=t[1]*i,e=a/2,g=r.tangentAt(e),t=[g[1],-g[0]],f=r.pointAt(e),y=(0<t[1]&&(t[0]=-t[0],t[1]=-t[1]),g[0]<0?-1:1),m=("start"!==n.__position&&"end"!==n.__position&&(a=-Math.atan2(g[1],g[0]),l[0]<s[0]&&(a=Math.PI+a),n.rotation=a),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=g[0]<0?"right":"left",n.originX=-p*y,n.originY=-m;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":n.x=f[0],n.y=f[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<=g[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)}};var OA,NA=RA;function RA(t,e,n){var i=OA.call(this)||this;return i._createLine(t,e,n),i}zA.prototype.updateData=function(n){var i=this,e=(this._progressiveEls=null,this.group),o=this._lineData,r=(this._lineData=n,o||e.removeAll(),VA(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()},zA.prototype.updateLayout=function(){var n=this._lineData;n&&n.eachItemGraphicEl(function(t,e){t.updateLayout(n,e)},this)},zA.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=VA(t),this._lineData=null,this.group.removeAll()},zA.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)}this._progressiveEls=[];for(var i,o=t.start;o<t.end;o++)FA(e.getItemLayout(o))&&((i=new this._LineCtor(e,o,this._seriesScope)).traverse(n),this.group.add(i),e.setItemGraphicEl(o,i),this._progressiveEls.push(i))},zA.prototype.remove=function(){this.group.removeAll()},zA.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},zA.prototype._doAdd=function(t,e,n){FA(t.getItemLayout(e))&&(n=new this._LineCtor(t,e,n),t.setItemGraphicEl(e,n),this.group.add(n))},zA.prototype._doUpdate=function(t,e,n,i,o){t=t.getItemGraphicEl(n);FA(e.getItemLayout(i))?(t?t.updateData(e,i,o):t=new this._LineCtor(e,i,o),e.setItemGraphicEl(i,t),this.group.add(t)):this.group.remove(t)};var EA=zA;function zA(t){this.group=new Z,this._LineCtor=t||NA}function VA(t){var t=t.hostModel,e=t.getModel("emphasis");return{lineStyle:t.getModel("lineStyle").getLineStyle(),emphasisLineStyle:e.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:t.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:t.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:e.get("disabled"),blurScope:e.get("blurScope"),focus:e.get("focus"),labelStatesModels:rp(t)}}function BA(t){return isNaN(t[0])||isNaN(t[1])}function FA(t){return t&&!BA(t[0])&&!BA(t[1])}u(HA,GA=Z),HA.prototype.createLine=function(t,e,n){return new NA(t,e,n)},HA.prototype._updateEffectSymbol=function(t,e){var n=t.getItemModel(e).getModel("effect"),i=n.get("symbolSize"),o=n.get("symbol"),r=(B(i)||(i=[i,i]),t.getItemVisual(e,"style")),r=n.get("color")||r&&r.stroke,a=this.childAt(1);this._symbolType!==o&&(this.remove(a),(a=s0(o,-.5,-.5,1,1,r)).z2=100,a.culling=!0,this.add(a)),a&&(a.setStyle("shadowColor",r),a.setStyle(n.getItemStyle(["color"])),a.scaleX=i[0],a.scaleY=i[1],a.setColor(r),this._symbolType=o,this._symbolScale=i,this._updateEffectAnimation(t,n,e))},HA.prototype._updateEffectAnimation=function(e,t,n){var i,o,r,a,s,l=this.childAt(1);l&&(s=e.getItemLayout(n),i=1e3*t.get("period"),o=t.get("loop"),r=t.get("roundTrip"),a=t.get("constantSpeed"),t=wt(t.get("delay"),function(t){return t/e.count()*i/3}),l.ignore=!0,this._updateAnimationPoints(l,s),(i=0<a?this._getLineLength(l)/a*1e3:i)===this._period&&o===this._loop&&r===this._roundTrip||(l.stopAnimation(),s=void 0,s=D(t)?t(n):t,0<l.__t&&(s=-i*l.__t),this._animateSymbol(l,i,s,o,r)),this._period=i,this._loop=o,this._roundTrip=r)},HA.prototype._animateSymbol=function(t,e,n,i,o){var r;0<e&&(t.__t=0,r=this,e=t.animate("",i).when(o?2*e:e,{__t:o?2:1}).delay(n).during(function(){r._updateSymbolPosition(t)}),i||e.done(function(){r.remove(t)}),e.start())},HA.prototype._getLineLength=function(t){return te(t.__p1,t.__cp1)+te(t.__cp1,t.__p2)},HA.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]},HA.prototype.updateData=function(t,e,n){this.childAt(0).updateData(t,e,n),this._updateEffectSymbol(t,e)},HA.prototype._updateSymbolPosition=function(t){var e=t.__p1,n=t.__p2,i=t.__cp1,o=t.__t<1?t.__t:2-t.__t,r=[t.x,t.y],a=r.slice(),s=$n,l=Jn,s=(r[0]=s(e[0],i[0],n[0],o),r[1]=s(e[1],i[1],n[1],o),t.__t<1?l(e[0],i[0],n[0],o):l(n[0],i[0],e[0],1-o)),l=t.__t<1?l(e[1],i[1],n[1],o):l(n[1],i[1],e[1],1-o);t.rotation=-Math.atan2(l,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*te(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*te(e,r):t.scaleY=this._symbolScale[1]),t.__lastT=t.__t,t.ignore=!1,t.x=r[0],t.y=r[1]},HA.prototype.updateLayout=function(t,e){this.childAt(0).updateLayout(t,e);var n=t.getItemModel(e).getModel("effect");this._updateEffectAnimation(t,n,e)};var GA,WA=HA;function HA(t,e,n){var i=GA.call(this)||this;return i.add(i.createLine(t,e,n)),i._updateEffectSymbol(t,e),i}u(UA,YA=Z),UA.prototype._createPolyline=function(t,e,n){var i=t.getItemLayout(e),i=new Rh({shape:{points:i}});this.add(i),this._updateCommonStl(t,e,n)},UA.prototype.updateData=function(t,e,n){var i=t.hostModel;C(this.childAt(0),{shape:{points:t.getItemLayout(e)}},i,e),this._updateCommonStl(t,e,n)},UA.prototype._updateCommonStl=function(t,e,n){var i=this.childAt(0),o=t.getItemModel(e),r=n&&n.emphasisLineStyle,a=n&&n.focus,s=n&&n.blurScope,l=n&&n.emphasisDisabled;n&&!t.hasItemOption||(r=(n=o.getModel("emphasis")).getModel("lineStyle").getLineStyle(),l=n.get("disabled"),a=n.get("focus"),s=n.get("blurScope")),i.useStyle(t.getItemVisual(e,"style")),i.style.fill=null,i.style.strokeNoScale=!0,i.ensureState("emphasis").style=r,Mu(this,a,s,l)},UA.prototype.updateLayout=function(t,e){this.childAt(0).setShape("points",t.getItemLayout(e))};var YA,XA=UA;function UA(t,e,n){var i=YA.call(this)||this;return i._createPolyline(t,e,n),i}u(qA,ZA=WA),qA.prototype.createLine=function(t,e,n){return new XA(t,e,n)},qA.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+=te(r,a),n.push(i)}if(0===i)this._length=0;else{for(o=0;o<n.length;o++)n[o]/=i;this._offsets=n,this._length=i}},qA.prototype._getLineLength=function(){return this._length},qA.prototype._updateSymbolPosition=function(t){var e=t.__t<1?t.__t:2-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 r=(e-i[a])/(i[a+1]-i[a]),s=n[a],n=n[a+1],r=(t.x=s[0]*(1-r)+r*n[0],t.y=s[1]*(1-r)+r*n[1],t.__t<1?n[0]-s[0]:s[0]-n[0]),s=t.__t<1?n[1]-s[1]:s[1]-n[1];t.rotation=-Math.atan2(s,r)-Math.PI/2,this._lastFrame=a,this._lastFramePercent=e,t.ignore=!1}};var ZA,jA=qA;function qA(){var t=null!==ZA&&ZA.apply(this,arguments)||this;return t._lastFrame=0,t._lastFramePercent=0,t}var KA,$A=function(){this.polyline=!1,this.curveness=0,this.segs=[]},JA=(u(QA,KA=q),QA.prototype.reset=function(){this.notClear=!1,this._off=0},QA.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},QA.prototype.getDefaultShape=function(){return new $A},QA.prototype.buildPath=function(t,e){var n,i=e.segs,o=e.curveness;if(e.polyline)for(n=this._off;n<i.length;){var r=i[n++];if(0<r){t.moveTo(i[n++],i[n++]);for(var a=1;a<r;a++)t.lineTo(i[n++],i[n++])}}else for(n=this._off;n<i.length;){var s=i[n++],l=i[n++],u=i[n++],h=i[n++];t.moveTo(s,l),0<o?t.quadraticCurveTo((s+u)/2-(l-h)*o,(l+h)/2-(u-s)*o,u,h):t.lineTo(u,h)}this.incremental&&(this._off=n,this.notClear=!0)},QA.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++)if(Es(u,h,p=i[s++],d=i[s++],r,t,e))return a;a++}else for(a=0,s=0;s<i.length;){var u=i[s++],h=i[s++],p=i[s++],d=i[s++];if(0<o){if(zs(u,h,(u+p)/2-(h-d)*o,(h+d)/2-(p-u)*o,p,d,r,t,e))return a}else if(Es(u,h,p,d,r,t,e))return a;a++}return-1},QA.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();return t=n[0],e=n[1],i.contain(t,e)?0<=(this.hoverDataIdx=this.findDataIndex(t,e)):!(this.hoverDataIdx=-1)},QA.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape.segs,n=1/0,i=1/0,o=-1/0,r=-1/0,a=0;a<e.length;)var s=e[a++],l=e[a++],n=Math.min(s,n),o=Math.max(s,o),i=Math.min(l,i),r=Math.max(l,r);t=this._rect=new U(n,i,o,r)}return t},QA);function QA(t){t=KA.call(this,t)||this;return t._off=0,t.hoverDataIdx=-1,t}ek.prototype.updateData=function(t){this._clear();var e=this._create();e.setShape({segs:t.getLayout("linesPoints")}),this._setCommon(e,t)},ek.prototype.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clear()},ek.prototype.incrementalUpdate=function(t,e){var n,i,o=this._newAdded[0],r=e.getLayout("linesPoints"),a=o&&o.shape.segs;a&&a.length<2e4?(n=a.length,(i=new Float32Array(n+r.length)).set(a),i.set(r,n),o.setShape({segs:i})):(this._newAdded=[],(a=this._create()).incremental=!0,a.setShape({segs:r}),this._setCommon(a,e),a.__startIndex=t.start)},ek.prototype.remove=function(){this._clear()},ek.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},ek.prototype._create=function(){var t=new JA({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(t),this.group.add(t),t},ek.prototype._setCommon=function(n,t,e){var i=t.hostModel,t=(n.setShape({polyline:i.get("polyline"),curveness:i.get(["lineStyle","curveness"])}),n.useStyle(i.getModel("lineStyle").getLineStyle()),n.style.strokeNoScale=!0,t.getVisual("style")),o=(t&&t.stroke&&n.setStyle("stroke",t.stroke),n.setStyle("fill",null),$(n));o.seriesIndex=i.seriesIndex,n.on("mousemove",function(t){o.dataIndex=null;var e=n.hoverDataIdx;0<e&&(o.dataIndex=e+n.__startIndex)})},ek.prototype._clear=function(){this._newAdded=[],this.group.removeAll()};var tk=ek;function ek(){this.group=new Z}var nk,ik={seriesType:"lines",plan:Jy(),reset:function(g){var f,y,m=g.coordinateSystem;if(m)return f=g.get("polyline"),y=g.pipelineContext.large,{progress:function(t,e){var n=[];if(y){var i=void 0,o=t.end-t.start;if(f){for(var r=0,a=t.start;a<t.end;a++)r+=g.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=g.getLineCoords(a,n);f&&(i[s++]=u);for(var h=0;h<u;h++)l=m.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),u=g.getLineCoords(a,n),p=[];if(f)for(var d=0;d<u;d++)p.push(m.dataToPoint(n[d]));else{p[0]=m.dataToPoint(n[0]),p[1]=m.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)}}}}},ok=(u(rk,nk=em),rk.prototype.render=function(t,e,n){var i=t.getData(),o=this._updateLineDraw(i,t),r=t.get("zlevel"),a=t.get(["effect","trailLength"]),n=n.getZr(),s="svg"===n.painter.getType(),s=(s||n.painter.getLayer(r).clear(!0),null==this._lastZlevel||s||n.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(t)&&0<a&&(s||n.configLayer(r,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(a/10+.9,1),0)})),o.updateData(i),t.get("clip",!0)&&Eb(t.coordinateSystem,!1,t));s?this.group.setClipPath(s):this.group.removeClipPath(),this._lastZlevel=r,this._finished=!0},rk.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateLineDraw(i,t).incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},rk.prototype.incrementalRender=function(t,e,n){this._lineDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},rk.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},rk.prototype.updateTransform=function(t,e,n){var i=t.getData(),o=t.pipelineContext;if(!this._finished||o.large||o.progressiveRender)return{update:!0};o=ik.reset(t,e,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},rk.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 tk:new EA(o?i?jA:XA:i?WA:NA),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=e),this.group.add(n.group),n},rk.prototype._showEffect=function(t){return!!t.get(["effect","show"])},rk.prototype._clearLayer=function(t){t=t.getZr();"svg"!==t.painter.getType()&&null!=this._lastZlevel&&t.painter.getLayer(this._lastZlevel).clear(!0)},rk.prototype.remove=function(t,e){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(e)},rk.prototype.dispose=function(t,e){this.remove(t,e)},rk.type="lines",rk);function rk(){var t=null!==nk&&nk.apply(this,arguments)||this;return t.type=rk.type,t}var ak="undefined"==typeof Uint32Array?Array:Uint32Array,sk="undefined"==typeof Float64Array?Array:Float64Array;function lk(t){var e=t.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(t.data=V(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),at([e,t[0],t[1]])}))}u(ck,uk=Gy),ck.prototype.init=function(t){t.data=t.data||[],lk(t);var e=this._processFlatCoordsArray(t.data);this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset,e.flatCoords&&(t.data=new Float32Array(e.count)),uk.prototype.init.apply(this,arguments)},ck.prototype.mergeOption=function(t){var e;lk(t),t.data&&(e=this._processFlatCoordsArray(t.data),this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset,e.flatCoords)&&(t.data=new Float32Array(e.count)),uk.prototype.mergeOption.apply(this,arguments)},ck.prototype.appendData=function(t){var e=this._processFlatCoordsArray(t.data);e.flatCoords&&(this._flatCoords?(this._flatCoords=Et(this._flatCoords,e.flatCoords),this._flatCoordsOffset=Et(this._flatCoordsOffset,e.flatCoordsOffset)):(this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset),t.data=new Float32Array(e.count)),this.getRawData().appendData(t.data)},ck.prototype._getCoordsFromItemModel=function(t){t=this.getData().getItemModel(t);return t.option instanceof Array?t.option:t.getShallow("coords")},ck.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[2*t+1]:this._getCoordsFromItemModel(t).length},ck.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},ck.prototype._processFlatCoordsArray=function(t){var e=0;if(this._flatCoords&&(e=this._flatCoords.length),Y(t[0])){for(var n=t.length,i=new ak(n),o=new sk(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}}return{flatCoordsOffset:null,flatCoords:null,count:t.length}},ck.prototype.getInitialData=function(t,e){var o=new k1(["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},ck.prototype.formatTooltip=function(t,e,n){var i,t=this.getData().getItemModel(t),o=t.get("name");return o||(o=t.get("fromName"),t=t.get("toName"),i=[],null!=o&&i.push(o),null!=t&&i.push(t),Iy("nameValue",{name:i.join(" > ")}))},ck.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},ck.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?1e4:this.get("progressive"):t},ck.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?2e4:this.get("progressiveThreshold"):t},ck.prototype.getZLevelKey=function(){var t=this.getModel("effect"),e=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&0<e?e+"":""},ck.type="series.lines",ck.dependencies=["grid","polar","geo","calendar"],ck.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}};var uk,hk=ck;function ck(){var t=null!==uk&&uk.apply(this,arguments)||this;return t.type=ck.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}function pk(t){return t=t instanceof Array?t:[t,t]}var dk={seriesType:"lines",reset:function(t){var e=pk(t.get("symbol")),n=pk(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=pk((i=t.getItemModel(e)).getShallow("symbol",!0)),i=pk(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}}};function gk(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){Y(e)&&(e=o[e]);for(var n=0;n<r.length;n++)if(!r[n].isSelected(e))return!1}return!0})})}function fk(t){var h={};t.eachSeriesByType("graph",function(s){var l=s.getCategoriesData(),r=s.getData(),u={};l.each(function(t){for(var e=l.getName(t),n=(u["ec-"+e]=t,l.getItemModel(t)),i=n.getModel("itemStyle").getItemStyle(),o=(i.fill||(i.fill=s.getColorFromPalette(e,h)),l.setItemVisual(t,"style",i),["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){H(e)&&(e=u["ec-"+e]);for(var n=l.getItemVisual(e,"style"),i=(F(r.ensureUniqueItemVisual(t,"style"),n),["symbol","symbolSize","symbolKeepAspect"]),o=0;o<i.length;o++)r.setItemVisual(t,i[o],l.getItemVisual(e,i[o]))}})})}function yk(t){return t=t instanceof Array?t:[t,t]}function mk(t){t.eachSeriesByType("graph",function(t){var s=t.getGraph(),l=t.getEdgeData(),e=yk(t.get("edgeSymbol")),n=yk(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=yk(e.getShallow("symbol",!0)),o=yk(e.getShallow("symbolSize",!0)),e=e.getModel("lineStyle").getLineStyle(),r=l.ensureUniqueItemVisual(t,"style");switch(F(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])})})}r(function(t){t.registerChartView(ok),t.registerSeriesModel(hk),t.registerLayout(ik),t.registerVisual(dk)});var vk="--\x3e",xk=function(t){return t.get("autoCurveness")||null},_k=function(t,e){var n=xk(t),i=20,o=[];if(Y(n))i=n;else if(B(n))return void(t.__curvenessList=n);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},bk=function(t,e,n){t=[t.id,t.dataIndex].join("."),e=[e.id,e.dataIndex].join(".");return[n.uid,t,e].join(vk)},wk=function(t){t=t.split(vk);return[t[0],t[2],t[1]].join(vk)},Sk=function(t,e){t=bk(t.node1,t.node2,e);return e.__edgeMap[t]},Mk=function(t,e){return Ik(bk(t.node1,t.node2,e),e)+Ik(bk(t.node2,t.node1,e),e)},Ik=function(t,e){e=e.__edgeMap;return e[t]?e[t].length:0};function Tk(t,e,n,i){var o=xk(e),r=B(o);if(!o)return null;var a=Sk(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=Mk(t,e),t=(_k(e,u),t.lineStyle=t.lineStyle||{},bk(t.node1,t.node2,e)),h=e.__curvenessList,u=r||u%2?0:1;return a.isForward?h[u+s]:(t=wk(t),e=h[s+(t=Ik(t,e))+u],i?!r||o&&0===o[0]?(t+u)%2?e:-e:((t%2?0:1)+u)%2?e:-e:h[s+t+u])}function Ck(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")])}),Dk(e,t))}function Dk(t,r){t.eachEdge(function(t,e){var e=St(t.getModel().get(["lineStyle","curveness"]),-Tk(t,r,e,!0),0),n=Yt(t.node1.getLayout()),i=Yt(t.node2.getLayout()),o=[n,i];+e&&o.push([(n[0]+i[0])/2-(n[1]-i[1])*e,(n[1]+i[1])/2-(i[0]-n[0])*e]),t.setLayout(o)})}function Ak(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=[];nt(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])}Dk(i.graph,t)}else e&&"none"!==e||Ck(t)})}function kk(t){var e,n=t.coordinateSystem;return"view"!==n.type?1:(t=t.option.nodeScaleRatio,e=n.scaleX,((n.getZoom()-1)*t+1)/e)}function Lk(t){t=t.getVisual("symbolSize");return+(t=t instanceof Array?(t[0]+t[1])/2:t)}var Pk=Math.PI,Ok=[];function Nk(s,t,e,n){var i,o,l,u,r,a,h=s.coordinateSystem;h&&"view"!==h.type||(r=h.getBoundingRect(),o=(i=s.getData()).graph,l=r.width/2+r.x,u=r.height/2+r.y,r=Math.min(r.width,r.height)/2,a=i.count(),i.setLayout({cx:l,cy:u}),a&&(e&&(n=(h=h.pointToData(n))[0],h=h[1],Jt(n=[n-l,h-u],n),$t(n,n,r),e.setLayout([l+n[0],u+n[1]],!0),Ek(e,s.get(["circular","rotateLabel"]),l,u)),Rk[t](s,o,i,r,l,u,a),o.eachEdge(function(t,e){var n,e=St(t.getModel().get(["lineStyle","curveness"]),Tk(t,s,e),0),i=Yt(t.node1.getLayout()),o=Yt(t.node2.getLayout()),r=(i[0]+o[0])/2,a=(i[1]+o[1])/2;+e&&(n=[l*(e*=3)+r*(1-e),u*e+a*(1-e)]),t.setLayout([i,o,n])})))}var Rk={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,l=(Ok.length=a,kk(t)),u=(e.eachNode(function(t){var e=Lk(t),e=((e=isNaN(e)?2:e)<0&&(e=0),e*=l,Math.asin(e/2/i));isNaN(e)&&(e=Pk/2),Ok[t.dataIndex]=e,s+=2*e}),(2*Pk-s)/a/2),h=0;e.eachNode(function(t){var e=u+Ok[t.dataIndex];h+=e,t.getLayout()&&t.getLayout().fixed||t.setLayout([i*Math.cos(h)+o,i*Math.sin(h)+r]),h+=e})}};function Ek(t,e,n,i){var o,r=t.getGraphicEl();r&&(o=t.getModel().get(["label","rotate"])||0,r=r.getSymbolPath(),e?(e=t.getLayout(),(t=Math.atan2(e[1]-i,e[0]-n))<0&&(t=2*Math.PI+t),(i=e[0]<n)&&(t-=Math.PI),r.setTextConfig({rotation:-t,position:e=i?"left":"right",origin:"center"}),F((n=r.ensureState("emphasis")).textConfig||(n.textConfig={}),{position:e})):r.setTextConfig({rotation:o*=Math.PI/180}))}function zk(t){t.eachSeriesByType("graph",function(t){"circular"===t.get("layout")&&Nk(t,"symbolSize")})}var Vk=Zt;function Bk(t){t.eachSeriesByType("graph",function(o){var h,c,p,t,i,r,a,s,l,e,n,u,d=o.coordinateSystem;d&&"view"!==d.type||("force"===o.get("layout")?(h=o.preservedPoints||{},c=o.getGraph(),p=c.data,u=c.edgeData,e=(t=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&&Nk(o,"value"):Ck(o),i=p.getDataExtent("value"),r=u.getDataExtent("value"),e=t.get("repulsion"),n=t.get("edgeLength"),a=B(e)?e:[e,e],s=[(s=B(n)?n:[n,n])[1],s[0]],l=p.mapArray("value",function(t,e){var n=p.getItemLayout(e),t=Cr(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}}),e=u.mapArray("value",function(t,e){var n=c.getEdgeByIndex(e),t=Cr(t,r,s),i=(isNaN(t)&&(t=(s[0]+s[1])/2),n.getModel()),e=St(n.getModel().get(["lineStyle","curveness"]),-Tk(n,o,e,!0),0);return{n1:l[n.node1.dataIndex],n2:l[n.node2.dataIndex],d:t,curveness:e,ignoreForceLayout:i.get("ignoreForceLayout")}}),n=d.getBoundingRect(),(u=function(t,e,n){for(var d=t,g=e,i=(t=n.rect).width,o=t.height,f=[t.x+i/2,t.y+o/2],y=null==n.gravity?.1:n.gravity,r=0;r<d.length;r++){var a=d[r];a.p||(a.p=Wt(i*(Math.random()-.5)+f[0],o*(Math.random()-.5)+f[1])),a.pp=Yt(a.p),a.edges=null}var m,v,s=null==n.friction?.6:n.friction,x=s;return{warmUp:function(){x=.8*s},setFixed:function(t){d[t].fixed=!0},setUnfixed:function(t){d[t].fixed=!1},beforeStep:function(t){m=t},afterStep:function(t){v=t},step:function(t){m&&m(d,g);for(var e=[],n=d.length,i=0;i<g.length;i++){var o=g[i];o.ignoreForceLayout||(a=o.n1,jt(e,(r=o.n2).p,a.p),l=qt(e)-o.d,o=r.w/(a.w+r.w),isNaN(o)&&(o=0),Jt(e,e),a.fixed||Vk(a.p,a.p,e,o*l*x),r.fixed)||Vk(r.p,r.p,e,-(1-o)*l*x)}for(i=0;i<n;i++)(h=d[i]).fixed||(jt(e,f,h.p),Vk(h.p,h.p,e,y*x));for(i=0;i<n;i++)for(var r,a=d[i],s=i+1;s<n;s++){jt(e,(r=d[s]).p,a.p);0===(l=qt(e))&&(Xt(e,Math.random()-.5,Math.random()-.5),l=1);var l,u=(a.rep+r.rep)/l/l;a.fixed||Vk(a.pp,a.pp,e,u),r.fixed||Vk(r.pp,r.pp,e,-u)}for(var h,c=[],i=0;i<n;i++)(h=d[i]).fixed||(jt(c,h.p,h.pp),Vk(h.p,h.p,c,x),Ht(h.pp,h.p));var p=(x*=.992)<.01;v&&v(d,g,p),t&&t(p)}}}(l,e,{rect:n,gravity:t.get("gravity"),friction:t.get("friction")})).beforeStep(function(t,e){for(var n=0,i=t.length;n<i;n++)t[n].fixed&&Ht(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]||[],Ht(u[0],s),Ht(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 Fk(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||(l=[],i=[],ps((e=t.getData()).mapArray(function(t){t=e.getItemModel(t);return[+t.get("x"),+t.get("y")]}),l,i),i[0]-l[0]==0&&(i[0]+=1,--l[0]),i[1]-l[1]==0&&(i[1]+=1,--l[1]),n=(i[0]-l[0])/(i[1]-l[1]),a=u,s=n,s=Ld(F(t.getBoxLayoutParams(),{aspect:s}),{width:a.getWidth(),height:a.getHeight()}),isNaN(n)&&(l=[s.x,s.y],i=[s.x+s.width,s.y+s.height]),a=i[0]-l[0],n=i[1]-l[1],i=s.width,o=s.height,(r=t.coordinateSystem=new I2).zoomLimit=t.get("scaleLimit"),r.setBoundingRect(l[0],l[1],a,n),r.setViewRect(s.x,s.y,i,o),r.setCenter(t.get("center"),u),r.setZoom(t.get("zoom")),h.push(r))}),h}var Gk=[],Wk=[],Hk=[],Yk=$n,Xk=ne,Uk=Math.abs;function Zk(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)Gk[0]=Yk(o[0],r[0],a[0],h),Gk[1]=Yk(o[1],r[1],a[1],h),(d=Uk(Xk(Gk,e)-l))<s&&(s=d,i=h);for(var c=0;c<32;c++){var p=i+u,d=(Wk[0]=Yk(o[0],r[0],a[0],i),Wk[1]=Yk(o[1],r[1],a[1],i),Hk[0]=Yk(o[0],r[0],a[0],p),Hk[1]=Yk(o[1],r[1],a[1],p),Xk(Wk,e)-l);if(Uk(d)<.01)break;p=Xk(Hk,e)-l;u/=2,d<0?0<=p?i+=u:i-=u:0<=p?i-=u:i+=u}return i}function jk(t,l){var u=[],h=ti,c=[[],[],[]],p=[[],[]],d=[];l/=2,t.eachEdge(function(t,e){var n,i,o=t.getLayout(),r=t.getVisual("fromSymbol"),a=t.getVisual("toSymbol"),s=(o.__original||(o.__original=[Yt(o[0]),Yt(o[1])],o[2]&&o.__original.push(Yt(o[2]))),o.__original);null!=o[2]?(Ht(c[0],s[0]),Ht(c[1],s[2]),Ht(c[2],s[1]),r&&"none"!==r&&(i=Lk(t.node1),n=Zk(c,s[0],i*l),h(c[0][0],c[1][0],c[2][0],n,u),c[0][0]=u[3],c[1][0]=u[4],h(c[0][1],c[1][1],c[2][1],n,u),c[0][1]=u[3],c[1][1]=u[4]),a&&"none"!==a&&(i=Lk(t.node2),n=Zk(c,s[1],i*l),h(c[0][0],c[1][0],c[2][0],n,u),c[1][0]=u[1],c[2][0]=u[2],h(c[0][1],c[1][1],c[2][1],n,u),c[1][1]=u[1],c[2][1]=u[2]),Ht(o[0],c[0]),Ht(o[1],c[2]),Ht(o[2],c[1])):(Ht(p[0],s[0]),Ht(p[1],s[1]),jt(d,p[1],p[0]),Jt(d,d),r&&"none"!==r&&(i=Lk(t.node1),Zt(p[0],p[0],d,i*l)),a&&"none"!==a&&(i=Lk(t.node2),Zt(p[1],p[1],d,-i*l)),Ht(o[0],p[0]),Ht(o[1],p[1]))})}function qk(t){return"view"===t.type}u(Jk,Kk=em),Jk.prototype.init=function(t,e){var n=new Iw,i=new EA,o=this.group;this._controller=new N2(e.getZr()),this._controllerHost={target:o},o.add(n.group),o.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},Jk.prototype.render=function(r,t,e){var a=this,n=r.coordinateSystem,i=(this._model=r,this._symbolDraw),o=this._lineDraw,s=this.group,l=(qk(n)&&(n={x:n.x,y:n.y,scaleX:n.scaleX,scaleY:n.scaleY},this._firstRender?s.attr(n):C(s,n,r)),jk(r.getGraph(),kk(r)),r.getData()),s=(i.updateData(l),r.getEdgeData()),u=(o.updateData(s),this._updateNodeAndLinkScale(),this._updateController(r,t,e),clearTimeout(this._layoutTimeout),r.forceLayout),h=r.get(["force","layoutAnimation"]),c=(u&&this._startForceLayoutIteration(u,h),r.get("layout")),p=(l.graph.eachNode(function(e){var t,n=e.dataIndex,i=e.getGraphicEl(),o=e.getModel();i&&(i.off("drag").off("dragend"),(t=o.get("draggable"))&&i.on("drag",function(t){switch(c){case"force":u.warmUp(),a._layouting||a._startForceLayoutIteration(u,h),u.setFixed(n),l.setItemLayout(n,[i.x,i.y]);break;case"circular":l.setItemLayout(n,[i.x,i.y]),e.setLayout({fixed:!0},!0),Nk(r,"symbolSize",e,[t.offsetX,t.offsetY]),a.updateLayout(r);break;default:l.setItemLayout(n,[i.x,i.y]),Dk(r.getGraph(),r),a.updateLayout(r)}}).on("dragend",function(){u&&u.setUnfixed(n)}),i.setDraggable(t,!!o.get("cursor")),"adjacency"===o.get(["emphasis","focus"]))&&($(i).focus=e.getAdjacentDataIndices())}),l.graph.eachEdge(function(t){var e=t.getGraphicEl(),n=t.getModel().get(["emphasis","focus"]);e&&"adjacency"===n&&($(e).focus={edge:[t.dataIndex],node:[t.node1.dataIndex,t.node2.dataIndex]})}),"circular"===r.get("layout")&&r.get(["circular","rotateLabel"])),d=l.getLayout("cx"),g=l.getLayout("cy");l.graph.eachNode(function(t){Ek(t,p,d,g)}),this._firstRender=!1},Jk.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose(),this._controllerHost=null},Jk.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())})}()},Jk.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)&&!F2(t,r,o)}),qk(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){D2(i,t.dx,t.dy),r.dispatchAction({seriesId:o.id,type:"graphRoam",dx:t.dx,dy:t.dy})}).on("zoom",function(t){A2(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(),jk(o.getGraph(),kk(o)),e._lineDraw.updateLayout(),r.updateLabelLayout()})):n.disable()},Jk.prototype._updateNodeAndLinkScale=function(){var t=this._model,e=t.getData(),n=kk(t);e.eachItemGraphicEl(function(t,e){t&&t.setSymbolScale(n)})},Jk.prototype.updateLayout=function(t){jk(t.getGraph(),kk(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},Jk.prototype.remove=function(){clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},Jk.type="graph";var Kk,$k=Jk;function Jk(){var t=null!==Kk&&Kk.apply(this,arguments)||this;return t.type=Jk.type,t}function Qk(t){return"_EC_"+t}eL.prototype.isDirected=function(){return this._directed},eL.prototype.addNode=function(t,e){t=null==t?""+e:""+t;var n=this._nodesMap;if(!n[Qk(t)])return((e=new nL(t,e)).hostGraph=this).nodes.push(e),n[Qk(t)]=e},eL.prototype.getNodeByIndex=function(t){t=this.data.getRawIndex(t);return this.nodes[t]},eL.prototype.getNodeById=function(t){return this._nodesMap[Qk(t)]},eL.prototype.addEdge=function(t,e,n){var i=this._nodesMap,o=this._edgesMap;if(Y(t)&&(t=this.nodes[t]),Y(e)&&(e=this.nodes[e]),t instanceof nL||(t=i[Qk(t)]),e instanceof nL||(e=i[Qk(e)]),t&&e)return i=t.id+"-"+e.id,((n=new oL(t,e,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},eL.prototype.getEdgeByIndex=function(t){t=this.edgeData.getRawIndex(t);return this.edges[t]},eL.prototype.getEdge=function(t,e){t instanceof nL&&(t=t.id),e instanceof nL&&(e=e.id);var n=this._edgesMap;return this._directed?n[t+"-"+e]:n[t+"-"+e]||n[e+"-"+t]},eL.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)},eL.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)},eL.prototype.breadthFirstTraverse=function(t,e,n,i){if(e=e instanceof nL?e:this._nodesMap[Qk(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}}}},eL.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;e.filterSelf(function(t){t=i[e.getRawIndex(t)];return 0<=t.node1.dataIndex&&0<=t.node2.dataIndex});for(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},eL.prototype.clone=function(){for(var t=new eL(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};var tL=eL;function eL(t){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=t||!1}iL.prototype.degree=function(){return this.edges.length},iL.prototype.inDegree=function(){return this.inEdges.length},iL.prototype.outDegree=function(){return this.outEdges.length},iL.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostGraph.data.getItemModel(this.dataIndex).getModel(t)},iL.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},iL.prototype.getTrajectoryDataIndices=function(){for(var t=R(),e=R(),n=0;n<this.edges.length;n++){var i=this.edges[n];if(!(i.dataIndex<0)){t.set(i.dataIndex,!0);for(var o=[i.node1],r=[i.node2],a=0;a<o.length;){var s=o[a];a++,e.set(s.dataIndex,!0);for(var l=0;l<s.inEdges.length;l++)t.set(s.inEdges[l].dataIndex,!0),o.push(s.inEdges[l].node1)}for(a=0;a<r.length;){var u=r[a];a++,e.set(u.dataIndex,!0);for(l=0;l<u.outEdges.length;l++)t.set(u.outEdges[l].dataIndex,!0),r.push(u.outEdges[l].node2)}}}return{edge:t.keys(),node:e.keys()}};var nL=iL;function iL(t,e){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=null==t?"":t,this.dataIndex=null==e?-1:e}rL.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostGraph.edgeData.getItemModel(this.dataIndex).getModel(t)},rL.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},rL.prototype.getTrajectoryDataIndices=function(){for(var t=R(),e=R(),n=(t.set(this.dataIndex,!0),[this.node1]),i=[this.node2],o=0;o<n.length;){var r=n[o];o++,e.set(r.dataIndex,!0);for(var a=0;a<r.inEdges.length;a++)t.set(r.inEdges[a].dataIndex,!0),n.push(r.inEdges[a].node1)}for(o=0;o<i.length;){var s=i[o];o++,e.set(s.dataIndex,!0);for(a=0;a<s.outEdges.length;a++)t.set(s.outEdges[a].dataIndex,!0),i.push(s.outEdges[a].node2)}return{edge:t.keys(),node:e.keys()}};var oL=rL;function rL(t,e,n){this.dataIndex=-1,this.node1=t,this.node2=e,this.dataIndex=null==n?-1:n}function aL(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)}}}function sL(t,e,n,i,o){for(var r=new tL(i),a=0;a<t.length;a++)r.addNode(wt(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(wt(ra(h.id,null),c+" > "+p)),u++)}var d,i=n.get("coordinateSystem"),i=("cartesian2d"===i||"polar"===i?d=V1(t,n):(G(i=(i=Tg.get(i))&&i.dimensions||[],"value")<0&&i.concat(["value"]),i=L1(t,{coordDimensions:i,encodeDefine:n.getEncode()}).dimensions,(d=new k1(i,n)).initData(t)),new k1(["value"],n));return i.initData(l,s),o&&o(d,i),eT({mainData:d,struct:r,structAttr:"graph",datas:{node:d,edge:i},datasAttr:{node:"data",edge:"edgeData"}}),r.update(),r}ut(nL,aL("hostGraph","data")),ut(oL,aL("hostGraph","edgeData"));u(hL,lL=Gy),hL.prototype.init=function(t){lL.prototype.init.apply(this,arguments);var e=this;function n(){return e._categoriesData}this.legendVisualProvider=new wS(n,n),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},hL.prototype.mergeOption=function(t){lL.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},hL.prototype.mergeDefaultAndTheme=function(t){lL.prototype.mergeDefaultAndTheme.apply(this,arguments),Qr(t,"edgeLabel",["show"])},hL.prototype.getInitialData=function(t,e){var n,i=t.edges||t.links||[],t=t.data||t.nodes||[],r=this;if(t&&i)return xk(n=this)&&(n.__curvenessList=[],n.__edgeMap={},_k(n)),nt((n=sL(t,i,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=kp.prototype.getModel;function i(t,e){t=n.call(this,t,e);return t.resolveParentPath=o,t}function o(t){var e;return!t||"label"!==t[0]&&"label"!==t[1]?t:(e=t.slice(),"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})})).edges,function(t){var e,n,i;e=t.node1,n=t.node2,i=this,t=t.dataIndex,xk(i)&&(e=bk(e,n,i),i=(n=i.__edgeMap)[wk(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},hL.prototype.getGraph=function(){return this.getData().graph},hL.prototype.getEdgeData=function(){return this.getGraph().edgeData},hL.prototype.getCategoriesData=function(){return this._categoriesData},hL.prototype.formatTooltip=function(t,e,n){var i,o,r;return"edge"===n?(o=this.getData(),n=this.getDataParams(t,n),r=o.graph.getEdgeByIndex(t),i=o.getName(r.node1.dataIndex),o=o.getName(r.node2.dataIndex),r=[],null!=i&&r.push(i),null!=o&&r.push(o),Iy("nameValue",{name:r.join(" > "),value:n.value,noValue:null==n.value})):zy({series:this,dataIndex:t,multipleSeries:e})},hL.prototype._updateCategoriesData=function(){var t=V(this.option.categories||[],function(t){return null!=t.value?t:F({value:0},t)}),e=new k1(["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray(function(t){return e.getItemModel(t)})},hL.prototype.setZoom=function(t){this.option.zoom=t},hL.prototype.setCenter=function(t){this.option.center=t},hL.prototype.isAnimationEnabled=function(){return lL.prototype.isAnimationEnabled.call(this)&&!("force"===this.get("layout")&&this.get(["force","layoutAnimation"]))},hL.type="series.graph",hL.dependencies=["grid","polar","geo","singleAxis","calendar"],hL.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}};var lL,uL=hL;function hL(){var t=null!==lL&&lL.apply(this,arguments)||this;return t.type=hL.type,t.hasSymbolVisual=!0,t}var cL={type:"graphRoam",event:"graphRoam",update:"none"};r(function(t){t.registerChartView($k),t.registerSeriesModel(uL),t.registerProcessor(gk),t.registerVisual(fk),t.registerVisual(mk),t.registerLayout(Ak),t.registerLayout(t.PRIORITY.VISUAL.POST_CHART_LAYOUT,zk),t.registerLayout(Bk),t.registerCoordinateSystem("graphView",{dimensions:I2.dimensions,create:Fk}),t.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},Bt),t.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},Bt),t.registerAction(cL,function(n,t,i){t.eachComponent({mainType:"series",query:n},function(t){var e=IT(t.coordinateSystem,n,void 0,i);t.setCenter&&t.setCenter(e.center),t.setZoom&&t.setZoom(e.zoom)})})});u(gL,pL=Gy),gL.type="series.boxplot",gL.dependencies=["xAxis","yAxis","grid"],gL.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800};var pL,dL=gL;function gL(){var t=null!==pL&&pL.apply(this,arguments)||this;return t.type=gL.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}ut(dL,Ia,!0);u(mL,fL=em),mL.prototype.render=function(t,e,n){var i=t.getData(),o=this.group,r=this._data,a=(this._data||o.removeAll(),"horizontal"===t.get("layout")?1:0);i.diff(r).add(function(t){var e;i.hasValue(t)&&(e=wL(i.getItemLayout(t),i,t,a,!0),i.setItemGraphicEl(t,e),o.add(e))}).update(function(t,e){var n,e=r.getItemGraphicEl(e);i.hasValue(t)?(n=i.getItemLayout(t),e?(Ic(e),SL(n,e,i,t)):e=wL(n,i,t,a),o.add(e),i.setItemGraphicEl(t,e)):o.remove(e)}).remove(function(t){t=r.getItemGraphicEl(t);t&&o.remove(t)}).execute(),this._data=i},mL.prototype.remove=function(t){var e=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(t){t&&e.remove(t)})},mL.type="boxplot";var fL,yL=mL;function mL(){var t=null!==fL&&fL.apply(this,arguments)||this;return t.type=mL.type,t}var vL,xL=function(){},_L=(u(bL,vL=q),bL.prototype.getDefaultShape=function(){return new xL},bL.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])},bL);function bL(t){t=vL.call(this,t)||this;return t.type="boxplotBoxPath",t}function wL(t,e,n,i,o){var r,a,s=t.ends,i=new _L({shape:{points:o?(r=i,a=t,V(s,function(t){return(t=t.slice())[r]=a.initBaseline,t})):s}});return SL(t,i,e,n,o),i}function SL(t,e,n,i,o){var r=n.hostModel,o=((0,tp[o?"initProps":"updateProps"])(e,{shape:{points:t.ends}},r,i),e.useStyle(n.getItemVisual(i,"style")),e.style.strokeNoScale=!0,e.z2=100,n.getItemModel(i)),t=o.getModel("emphasis");Du(e,o),Mu(e,t.get("focus"),t.get("blurScope"),t.get("disabled"))}var ML=nt;function IL(t){var i,o;i=[],o=[],t.eachSeriesByType("boxplot",function(t){var e=t.getBaseAxis(),n=G(o,e);n<0&&(n=o.length,o[n]=e,i[n]={axis:e,seriesModels:[]}),i[n].seriesModels.push(t)}),ML(i,function(_){var t,e,n,i,o,r,a,s,l,u,h,c,p=_.seriesModels;p.length&&(l=(t=_).axis,n=t.seriesModels,i=n.length,o=t.boxWidthList=[],r=t.boxOffsetList=[],a=[],e="category"===l.type?l.getBandWidth():(s=0,ML(n,function(t){s=Math.max(s,t.getData().count())}),t=l.getExtent(),Math.abs(t[1]-t[0])/s),ML(n,function(t){t=t.get("boxWidth");B(t)||(t=[t,t]),a.push([j(t[0],e)||0,j(t[1],e)||0])}),u=(l=.8*e-2)/i*.3,c=(h=(l-u*(i-1))/i)/2-l/2,ML(n,function(t,e){r.push(c),c+=u+h,o.push(Math.min(Math.max(h,a[e][0]),a[e][1]))}),ML(p,function(t,e){var o=_.boxOffsetList[e],e=_.boxWidthList[e],r=t.coordinateSystem,a=t.getData(),s=e/2,l="horizontal"===t.get("layout")?0:1,u=1-l,e=["x","y"],n=a.mapDimension(e[l]),i=a.mapDimensionsAll(e[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),g=m(c,i[1],h),f=m(c,i[3],h),c=m(c,i[4],h),y=[];v(y,g,!1),v(y,f,!0),y.push(d,g,c,f),x(y,d),x(y,c),x(y,p),a.setItemLayout(h,{initBaseline:p[u],ends:y})}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)}}))})}var TL={type:"echarts:boxplot",transform:function(t){var e=t.upstream,e=(e.sourceFormat!==Zd&&jr(""),function(t,e){for(var n=[],i=[],o=(e=e||{}).boundIQR,r="none"===o||0===o,a=0;a<t.length;a++){var s=Ar(t[a].slice()),l=Wr(s,.25),u=Wr(s,.5),h=Wr(s,.75),c=s[0],p=s[s.length-1],d=(null==o?1.5:o)*(h-l),g=r?c:Math.max(c,l-d),f=r?p:Math.min(p,h+d),c=e.itemNameFormatter,y=D(c)?c({value:a}):H(c)?c.replace("{value}",a+""):a+"";n.push([y,g,l,u,h,f]);for(var m=0;m<s.length;m++){var v=s[m];(v<g||f<v)&&i.push([y,v])}}return{boxData:n,outliers:i}}(e.getRawData(),t.config));return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:e.boxData},{data:e.outliers}]}};r(function(t){t.registerSeriesModel(dL),t.registerChartView(yL),t.registerLayout(IL),t.registerTransform(TL)});u(AL,CL=em),AL.prototype.init=function(){this.group.add(this._dataGroup)},AL.prototype.render=function(i,t,e,n){this._progressiveEls=null;var o,r,a,s,l,u=this._dataGroup,h=i.getData(),c=this._data,p=i.coordinateSystem,d=p.dimensions,g=PL(i);h.diff(c).add(function(t){OL(LL(h,u,t,d,p),h,t,g)}).update(function(t,e){var e=c.getItemGraphicEl(e),n=kL(h,t,d,p);h.setItemGraphicEl(t,e),C(e,{shape:{points:n}},i,t),Ic(e),OL(e,h,t,g)}).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,o=o.getRect(),l=new L({shape:{x:o.x,y:o.y,width:o.width,height:o.height}}),s="horizontal"===s.get("layout")?"width":"height",l.setShape(s,0),_c(l,{shape:{width:o.width,height:o.height}},r,a),s=l,u.setClipPath(s)),this._data=h},AL.prototype.incrementalPrepareRender=function(t,e,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},AL.prototype.incrementalRender=function(t,e,n){for(var i=e.getData(),o=e.coordinateSystem,r=o.dimensions,a=PL(e),s=this._progressiveEls=[],l=t.start;l<t.end;l++){var u=LL(i,this._dataGroup,l,r,o);u.incremental=!0,OL(u,i,l,a),s.push(u)}},AL.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},AL.type="parallel";var CL,DL=AL;function AL(){var t=null!==CL&&CL.apply(this,arguments)||this;return t.type=AL.type,t._dataGroup=new Z,t._initialized=!1,t}function kL(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 LL(t,e,n,i,o){i=kL(t,n,i,o),o=new Rh({shape:{points:i},z2:10});return e.add(o),t.setItemGraphicEl(n,o),o}function PL(t){t=t.get("smooth",!0);return{smooth:t=bt(t=Yr(t=!0===t?.3:t))?0:t}}function OL(t,e,n,i){t.useStyle(e.getItemVisual(n,"style")),t.style.fill=null,t.setShape("smooth",i.smooth);i=e.getItemModel(n),e=i.getModel("emphasis");Du(t,i,"lineStyle"),Mu(t,e.get("focus"),e.get("blurScope"),e.get("disabled"))}u(EL,NL=Gy),EL.prototype.getInitialData=function(t,e){return V1(null,this,{useEncodeDefaulter:T(zL,null,this)})},EL.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},EL.type="series.parallel",EL.dependencies=["parallel"],EL.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"};var NL,RL=EL;function EL(){var t=null!==NL&&NL.apply(this,arguments)||this;return t.type=EL.type,t.visualStyleAccessPath="lineStyle",t.visualDrawType="stroke",t}function zL(t){var n,t=t.ecModel.getComponent("parallel",t.get("parallelIndex"));if(t)return n={},nt(t.dimensions,function(t){var e=+t.replace("dim","");n[t]=e}),n}var VL=["lineStyle","opacity"],BL={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(VL,!0))&&(n=t),i.ensureUniqueItemVisual(e,"style").opacity=n},t.start,t.end)}}}};function FL(t){var e,n,i;(e=t).parallel||(n=!1,nt(e.series,function(t){t&&"parallel"===t.type&&(n=!0)}),n&&(e.parallel=[{}])),nt(Jr((i=t).parallelAxis),function(t){var e;O(t)&&(e=t.parallelIndex||0,e=Jr(i.parallel)[e])&&e.parallelAxisDefault&&d(t,e.parallelAxisDefault,!1)})}u(HL,GL=Ky),HL.prototype.render=function(t,e,n){this._model=t,this._api=n,this._handlers||(this._handlers={},nt(YL,function(t,e){n.getZr().on(e,this._handlers[e]=T(t,this))},this)),pm(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},HL.prototype.dispose=function(t,n){dm(this,"_throttledDispatchExpand"),nt(this._handlers,function(t,e){n.getZr().off(e,t)}),this._handlers=null},HL.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},HL.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(F({type:"parallelAxisExpand"},t))},HL.type="parallel";var GL,WL=HL;function HL(){var t=null!==GL&&GL.apply(this,arguments)||this;return t.type=HL.type,t}var YL={mousedown:function(t){XL(this,"click")&&(this._mouseDownPoint=[t.offsetX,t.offsetY])},mouseup:function(t){var e=this._mouseDownPoint;if(XL(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;e=this._model.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]);"none"!==e.behavior&&this._dispatchExpand({axisExpandWindow:e.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(t){var e,n;!this._mouseDownPoint&&XL(this,"mousemove")&&("jump"===(n=(t=(e=this._model).coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY])).behavior)&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===n?null:{axisExpandWindow:t.axisExpandWindow,animation:"jump"===n?null:{duration:0}}))}};function XL(t,e){t=t._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}u(jL,UL=g),jL.prototype.init=function(){UL.prototype.init.apply(this,arguments),this.mergeOption({})},jL.prototype.mergeOption=function(t){var e=this.option;t&&d(e,t,!0),this._initDimensions()},jL.prototype.contains=function(t,e){t=t.get("parallelIndex");return null!=t&&e.getComponent("parallel",t)===this},jL.prototype.setAxisExpand=function(e){nt(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(t){e.hasOwnProperty(t)&&(this.option[t]=e[t])},this)},jL.prototype._initDimensions=function(){var e=this.dimensions=[],n=this.parallelAxisIndex=[];nt(pt(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)})},jL.type="parallel",jL.dependencies=["parallelAxis"],jL.layoutMode="box",jL.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null};var UL,ZL=jL;function jL(){var t=null!==UL&&UL.apply(this,arguments)||this;return t.type=jL.type,t}u($L,qL=Ip),$L.prototype.isHorizontal=function(){return"horizontal"!==this.coordinateSystem.getModel().get("layout")};var qL,KL=$L;function $L(t,e,n,i,o){t=qL.call(this,t,e,n)||this;return t.type=i||"value",t.axisIndex=o,t}function JL(t,e,n,i,o,r){t=t||0;var a=n[1]-n[0],a=(null!=o&&(o=tP(o,[0,a])),null!=r&&(r=Math.max(r,null!=o?o:0)),"all"===i&&(s=tP(s=Math.abs(e[1]-e[0]),[0,a]),o=r=tP(s,[o,r]),i=0),e[0]=tP(e[0],n),e[1]=tP(e[1],n),QL(e,i)),s=(e[i]+=t,o||0),t=n.slice();return a.sign<0?t[0]+=s:t[1]-=s,e[i]=tP(e[i],t),n=QL(e,i),null!=o&&(n.sign!==a.sign||n.span<o)&&(e[1-i]=e[i]+a.sign*o),n=QL(e,i),null!=r&&n.span>r&&(e[1-i]=e[i]+n.sign*r),e}function QL(t,e){t=t[e]-t[1-e];return{span:Math.abs(t),sign:0<t||!(t<0)&&e?-1:1}}function tP(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}var eP=nt,nP=Math.min,iP=Math.max,oP=Math.floor,rP=Math.ceil,aP=Dr,sP=Math.PI,lP=(uP.prototype._init=function(t,i,e){var n=t.dimensions,o=t.parallelAxisIndex;eP(n,function(t,e){var e=o[e],n=i.getComponent("parallelAxis",e),t=this._axesMap.set(t,new KL(t,Yx(n),[0,0],n.get("type"),e)),e="category"===t.type;t.onBand=e&&n.get("boundaryGap"),t.inverse=n.get("inverse"),(n.axis=t).model=n,t.coordinateSystem=n.coordinateSystem=this},this)},uP.prototype.update=function(t,e){this._updateAxesFromSeries(this._model,t)},uP.prototype.containPoint=function(t){var e=this._makeLayoutInfo(),n=e.axisBase,i=e.layoutBase,o=e.pixelDimIndex,r=t[1-o],t=t[o];return n<=r&&r<=n+e.axisLength&&i<=t&&t<=i+e.layoutLength},uP.prototype.getModel=function(){return this._model},uP.prototype._updateAxesFromSeries=function(e,i){i.eachSeries(function(t){var n;e.contains(t,i)&&(n=t.getData(),eP(this.dimensions,function(t){var e=this._axesMap.get(t);e.scale.unionExtentFromData(n,n.mapDimension(t)),Hx(e.scale,e.model)},this))},this)},uP.prototype.resize=function(t,e){this._rect=Ld(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},uP.prototype.getRect=function(){return this._rect},uP.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=hP(t.get("axisExpandWidth"),s),h=hP(t.get("axisExpandCount")||0,[0,l]),c=t.get("axisExpandable")&&3<l&&h<l&&1<h&&0<u&&0<a,p=t.get("axisExpandWindow"),s=(p?(d=hP(p[1]-p[0],s),p[1]=p[0]+d):(d=hP(u*(h-1),s),(p=[u*(t.get("axisExpandCenter")||oP(l/2))-d/2])[1]=p[0]+d),(a-d)/(l-h)),t=(s<3&&(s=0),[oP(aP(p[0]/u,1))+1,rP(aP(p[1]/u,1))-1]),d=s/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:s,axisExpandWindow:p,axisCount:l,winInnerIndices:t,axisExpandWindow0Pos:d}},uP.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])}),eP(e,function(t,e){var e=(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;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);return{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),n={horizontal:{x:e.position,y:a.axisLength},vertical:{x:0,y:e.position}},n=[n[s].x+r.x,n[s].y+r.y],i={horizontal:sP/2,vertical:0}[s],o=ze();We(o,o,i),Ge(o,o,n),this._axesLayout[t]={position:n,rotation:i,transform:o,axisNameAvailableWidth:e.axisNameAvailableWidth,axisLabelShow:e.axisLabelShow,nameTruncateMaxWidth:e.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},uP.prototype.getAxis=function(t){return this._axesMap.get(t)},uP.prototype.dataToPoint=function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},uP.prototype.eachActiveState=function(e,t,n,i){null==n&&(n=0),null==i&&(i=e.count());for(var o=this._axesMap,r=this.dimensions,a=[],s=[],l=(nt(r,function(t){a.push(e.mapDimension(t)),s.push(o.get(t).model)}),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)}},uP.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},uP.prototype.axisCoordToPoint=function(t,e){return Wc([t,0],this._axesLayout[e].transform)},uP.prototype.getAxisLayout=function(t){return S(this._axesLayout[t])},uP.prototype.getSlidedAxisExpandWindow=function(t){var e,n,i,o,r=this._makeLayoutInfo(),a=r.pixelDimIndex,s=r.axisExpandWindow.slice(),l=s[1]-s[0],u=[0,r.axisExpandWidth*(r.axisCount-1)];return this.containPoint(t)?(t=t[a]-r.layoutBase-r.axisExpandWindow0Pos,a="slide",n=r.axisCollapseWidth,o=null!=(i=this._model.get("axisExpandSlideTriggerArea"))[0],n?(o&&n&&t<l*i[0]?(a="jump",e=t-l*i[2]):o&&n&&t>l*(1-i[0])?(a="jump",e=t-l*(1-i[2])):0<=(e=t-l*i[1])&&(e=t-l*(1-i[1]))<=0&&(e=0),(e*=r.axisExpandWidth/n)?JL(e,s,u,"all"):a="none"):(o=s[1]-s[0],(s=[iP(0,u[1]*t/o-o/2)])[1]=nP(u[1],s[0]+o),s[0]=s[1]-o),{axisExpandWindow:s,behavior:a}):{behavior:"none",axisExpandWindow:s}},uP);function uP(t,e,n){this.type="parallel",this._axesMap=R(),this._axesLayout={},this.dimensions=t.dimensions,this._model=t,this._init(t,e,n)}function hP(t,e){return nP(iP(t,e[0]),e[1])}var cP,pP={create:function(i,o){var r=[];return i.eachComponent("parallel",function(t,e){var n=new lP(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",da).models[0],t.coordinateSystem=e.coordinateSystem)}),r}},dP=(u(gP,cP=g),gP.prototype.getAreaSelectStyle=function(){return Aa([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},gP.prototype.setActiveIntervals=function(t){var e=this.activeIntervals=S(t);if(e)for(var n=e.length-1;0<=n;n--)Ar(e[n])},gP.prototype.getActiveState=function(t){var e=this.activeIntervals;if(!e.length)return"normal";if(null!=t&&!isNaN(+t))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"},gP);function gP(){var t=null!==cP&&cP.apply(this,arguments)||this;return t.type=gP.type,t.activeIntervals=[],t}ut(dP,$x);var fP,yP=!0,mP=Math.min,vP=Math.max,xP=Math.pow,_P=1e4,bP=6,wP=6,SP="globalPan",MP={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},IP={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},TP={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},CP=0,DP=(u(AP,fP=ce),AP.prototype.enableBrush=function(t){return this._brushType&&this._doDisableBrush(),t.brushType&&this._doEnableBrush(t),this},AP.prototype._doEnableBrush=function(t){var e,n,i=this._zr;this._enableGlobalPan||(e=SP,n=this._uid,P2(i)[e]=n),nt(this._handlers,function(t,e){i.on(e,t)}),this._brushType=t.brushType,this._brushOption=d(S(TP),t,!0)},AP.prototype._doDisableBrush=function(){var t,e,n,i=this._zr;t=i,e=SP,n=this._uid,(t=P2(t))[e]===n&&(t[e]=null),nt(this._handlers,function(t,e){i.off(e,t)}),this._brushType=this._brushOption=null},AP.prototype.setPanels=function(t){var e;return t&&t.length?(e=this._panels={},nt(t,function(t){e[t.panelId]=S(t)})):this._panels=null,this},AP.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},AP.prototype.updateCovers=function(i){i=V(i,function(t){return d(S(TP),t,!0)});var n="\0-brush-index-",o=this._covers,r=this._covers=[],a=this,s=this._creatingCover;return new i1(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]:(t=r[t]=null!=e?(o[e].__brushOption=n,o[e]):LP(a,kP(a,n)),NP(a,t))}},AP.prototype.unmount=function(){return this.enableBrush(!1),VP(this),this._zr.remove(this.group),this},AP.prototype.dispose=function(){this.unmount(),this.off()},AP);function AP(t){var e=fP.call(this)||this;return e._track=[],e._covers=[],e._handlers={},e._zr=t,e.group=new Z,e._uid="brushController_"+CP++,nt(iO,function(t,e){this._handlers[e]=T(t,this)},e),e}function kP(t,e){var n=rO[e.brushType].createCover(t,e);return n.__brushOption=e,OP(n,e),t.group.add(n),n}function LP(t,e){var n=RP(e);return n.endCreating&&(n.endCreating(t,e),OP(e,e.__brushOption)),e}function PP(t,e){var n=e.__brushOption;RP(e).updateCoverShape(t,e,n.range,n)}function OP(t,e){var n=e.z;null==n&&(n=_P),t.traverse(function(t){t.z=n,t.z2=n})}function NP(t,e){RP(e).updateCommon(t,e),PP(t,e)}function RP(t){return rO[t.__brushOption.brushType]}function EP(t,e,n){var i,o,r=t._panels;return r?(o=t._transform,nt(r,function(t){t.isTargetByCursor(e,n,o)&&(i=t)}),i):yP}function zP(t,e){t=t._panels;return t&&null!=(e=e.__brushOption.panelId)?t[e]:yP}function VP(e){var t=e._covers,n=t.length;return nt(t,function(t){e.group.remove(t)},e),t.length=0,n}function BP(t,e){var n=V(t._covers,function(t){var t=t.__brushOption,e=S(t.range);return{brushType:t.brushType,panelId:t.panelId,range:e}});t.trigger("brush",{areas:n,isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function FP(t){var e=t.length-1;return[t[0],t[e=e<0?0:e]]}function GP(e,n,t,i){var o=new Z;return o.add(new L({name:"main",style:XP(t),silent:!0,draggable:!0,cursor:"move",drift:P(jP,e,n,o,["n","s","w","e"]),ondragend:P(BP,n,{isEnd:!0})})),nt(i,function(t){o.add(new L({name:t.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:P(jP,e,n,o,t),ondragend:P(BP,n,{isEnd:!0})}))}),o}function WP(t,e,n,i){var o=i.brushStyle.lineWidth||0,r=vP(o,wP),a=n[0][0],s=n[1][0],l=a-o/2,u=s-o/2,h=n[0][1],n=n[1][1],c=h-r+o/2,p=n-r+o/2,h=h-a,n=n-s,d=h+o,o=n+o;YP(t,e,"main",a,s,h,n),i.transformable&&(YP(t,e,"w",l,u,r,o),YP(t,e,"e",c,u,r,o),YP(t,e,"n",l,u,d,r),YP(t,e,"s",l,p,d,r),YP(t,e,"nw",l,u,r,r),YP(t,e,"ne",c,u,r,r),YP(t,e,"sw",l,p,r,r),YP(t,e,"se",c,p,r,r))}function HP(n,i){var t=i.__brushOption,o=t.transformable,e=i.childAt(0);e.useStyle(XP(t)),e.attr({silent:!o,cursor:o?"move":"default"}),nt([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(t){var e=i.childOfName(t.join("")),t=1===t.length?ZP(n,t[0]):function(t,e){t=[ZP(t,e[0]),ZP(t,e[1])];return"e"!==t[0]&&"w"!==t[0]||t.reverse(),t.join("")}(n,t);e&&e.attr({silent:!o,invisible:!o,cursor:o?IP[t]+"-resize":null})})}function YP(t,e,n,i,o,r,a){var n=e.childOfName(n);n&&n.setShape((n=$P(t,e,[[i,o],[i+r,o+a]]),t=mP(n[0][0],n[1][0]),e=mP(n[0][1],n[1][1]),i=vP(n[0][0],n[1][0]),n=vP(n[0][1],n[1][1]),{x:t,y:e,width:i-t,height:n-e}))}function XP(t){return z({strokeNoScale:!0},t.brushStyle)}function UP(t,e,n,i){var o=[mP(t,n),mP(e,i)],t=[vP(t,n),vP(e,i)];return[[o[0],t[0]],[o[1],t[1]]]}function ZP(t,e){return{left:"w",right:"e",top:"n",bottom:"s"}[Hc({w:"left",e:"right",n:"top",s:"bottom"}[e],Gc(t.group))]}function jP(t,e,n,i,o,r){var a=n.__brushOption,s=t.toRectRange(a.range),l=KP(e,o,r);nt(i,function(t){t=MP[t];s[t[0]][t[1]]+=l[t[0]]}),a.range=t.fromRectRange(UP(s[0][0],s[1][0],s[0][1],s[1][1])),NP(e,n),BP(e,{isEnd:!1})}function qP(t,e,n,i){var o=e.__brushOption.range,r=KP(t,n,i);nt(o,function(t){t[0]+=r[0],t[1]+=r[1]}),NP(t,e),BP(t,{isEnd:!1})}function KP(t,e,n){t=t.group,e=t.transformCoordToLocal(e,n),n=t.transformCoordToLocal(0,0);return[e[0]-n[0],e[1]-n[1]]}function $P(t,e,n){e=zP(t,e);return e&&e!==yP?e.clipPath(n,t._transform):S(n)}function JP(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=EP(t,e,n);if(!t._dragging)for(var a=0;a<o.length;a++){var s=o[a].__brushOption;if(r&&(r===yP||s.panelId===r.panelId)&&rO[s.brushType].contain(o[a],n[0],n[1]))return}r&&i.setCursorStyle("crosshair")}}function QP(t){t=t.event;t.preventDefault&&t.preventDefault()}function tO(t,e,n){return t.childOfName("main").contain(e,n)}function eO(t,e,n,i){var o,r,a=t._creatingCover,s=t._creatingPanel,l=t._brushOption;return t._track.push(n.slice()),function(t){var e,n;if((t=t._track).length)return n=t[t.length-1],t=t[0],e=n[0]-t[0],n=n[1]-t[1],t=xP(e*e+n*n,.5),bP<t}(t)||a?(s&&!a&&("single"===l.brushMode&&VP(t),(r=S(l)).brushType=nO(r.brushType,s),r.panelId=s===yP?null:s.panelId,a=t._creatingCover=kP(t,r),t._covers.push(a)),a&&(r=rO[nO(t._brushType,s)],a.__brushOption.range=r.getCreatingRange($P(t,a,t._track)),i&&(LP(t,a),r.updateCommon(t,a)),PP(t,a),o={isEnd:i})):i&&"single"===l.brushMode&&l.removeOnClick&&EP(t,e,n)&&VP(t)&&(o={isEnd:i,removeOnClick:!0}),o}function nO(t,e){return"auto"===t?e.defaultBrushType:t}var iO={mousedown:function(t){var e;this._dragging?oO(this,t):t.target&&t.target.draggable||(QP(t),e=this.group.transformCoordToLocal(t.offsetX,t.offsetY),this._creatingCover=null,(this._creatingPanel=EP(this,t,e))&&(this._dragging=!0,this._track=[e.slice()]))},mousemove:function(t){var e=t.offsetX,n=t.offsetY,e=this.group.transformCoordToLocal(e,n);JP(this,t,e),this._dragging&&(QP(t),n=eO(this,t,e,!1))&&BP(this,n)},mouseup:function(t){oO(this,t)}};function oO(t,e){var n,i;t._dragging&&(QP(e),n=e.offsetX,i=e.offsetY,n=t.group.transformCoordToLocal(n,i),i=eO(t,e,n,!0),t._dragging=!1,t._track=[],t._creatingCover=null,i)&&BP(t,i)}var rO={lineX:aO(0),lineY:aO(1),rect:{createCover:function(t,e){function n(t){return t}return GP({toRectRange:n,fromRectRange:n},t,e,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(t){t=FP(t);return UP(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(t,e,n,i){WP(t,e,n,i)},updateCommon:HP,contain:tO},polygon:{createCover:function(t,e){var n=new Z;return n.add(new Rh({name:"main",style:XP(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new Lh({name:"main",draggable:!0,drift:P(qP,t,e),ondragend:P(BP,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n,i){e.childAt(0).setShape({points:$P(t,e,n)})},updateCommon:HP,contain:tO}};function aO(r){return{createCover:function(t,e){return GP({toRectRange:function(t){t=[t,[0,100]];return r&&t.reverse(),t},fromRectRange:function(t){return t[r]}},t,e,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(t){t=FP(t);return[mP(t[0][r],t[1][r]),vP(t[0][r],t[1][r])]},updateCoverShape:function(t,e,n,i){var o=zP(t,e),o=[n,o!==yP&&o.getLinearBrushOtherExtent?o.getLinearBrushOtherExtent(r):[0,[(n=t._zr).getWidth(),n.getHeight()][1-r]]];r&&o.reverse(),WP(t,e,o,i)},updateCommon:HP,contain:tO}}function sO(e){return e=hO(e),function(t){return Uc(t,e)}}function lO(n,i){return n=hO(n),function(t){var t=null!=i?i:t,e=t?n.width:n.height,t=t?n.x:n.y;return[t,t+(e||0)]}}function uO(t,n,i){var o=hO(t);return function(t,e){return o.contain(e[0],e[1])&&!F2(t,n,i)}}function hO(t){return U.create(t)}var cO,pO=["axisLine","axisTickLabel","axisName"],dO=(u(gO,cO=Ky),gO.prototype.init=function(t,e){cO.prototype.init.apply(this,arguments),(this._brushController=new DP(e.getZr())).on("brush",T(this._onBrush,this))},gO.prototype.render=function(t,e,n,i){var o,r,a,s;a=t,o=e,(i=i)&&"axisAreaSelect"===i.type&&o.findComponents({mainType:"parallelAxis",query:i})[0]===a||(this.axisModel=t,this.api=n,this.group.removeAll(),o=this._axisGroup,this._axisGroup=new Z,this.group.add(this._axisGroup),t.get("show")&&(a=(i=e.getComponent("parallel",t.get("parallelIndex"))).coordinateSystem,r=(e=t.getAreaSelectStyle()).width,s=t.axis.dim,a=F({strokeContainThreshold:r},a.getAxisLayout(s)),s=new yM(t,a),nt(pO,s.add,s),this._axisGroup.add(s.getGroup()),this._refreshBrushController(a,e,t,i,r,n),Xc(o,this._axisGroup,t)))},gO.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)),s=U.create({x:s[0],y:-o/2,width:l,height:o});s.x-=u,s.width+=2*u,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:sO(s),isTargetByCursor:uO(s,r,i),getLinearBrushOtherExtent:lO(s,0)}]).enableBrush({brushType:"lineX",brushStyle:e,removeOnClick:!0}).updateCovers((a=n.axis,V(n.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[a.dataToCoord(t[0],!0),a.dataToCoord(t[1],!0)]}})))},gO.prototype._onBrush=function(t){var e=t.areas,n=this.axisModel,i=n.axis,e=V(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})},gO.prototype.dispose=function(){this._brushController.dispose()},gO.type="parallelAxis",gO);function gO(){var t=null!==cO&&cO.apply(this,arguments)||this;return t.type=gO.type,t}var fO={type:"axisAreaSelect",event:"axisAreaSelected"};var yO={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function mO(t){t.registerComponentView(WL),t.registerComponentModel(ZL),t.registerCoordinateSystem("parallel",pP),t.registerPreprocessor(FL),t.registerComponentModel(dP),t.registerComponentView(dO),jS(t,"parallel",dP,yO),(t=t).registerAction(fO,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)})})}r(function(t){r(mO),t.registerChartView(DL),t.registerSeriesModel(RL),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,BL)});var vO,xO=function(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0},_O=(u(bO,vO=q),bO.prototype.getDefaultShape=function(){return new xO},bO.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)},bO);function bO(t){t=vO.call(this,t)||this;return t.type="pointer",t}function wO(t,e){var n=null==t?"":t+"";return e&&(H(e)?n=e.replace("{value}",n):D(e)&&(n=e(t))),n}u(IO,SO=em),IO.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(),a=Math.min(a,l),{cx:j(r[0],o.getWidth()),cy:j(r[1],o.getHeight()),r:j(i.get("radius"),a/2)});this._renderMain(t,e,n,s,l),this._data=t.getData()},IO.prototype.dispose=function(){},IO.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")?Bb:wh,c=u.get("show"),p=u.getModel("lineStyle"),d=p.get("width"),u=[s,l],g=(Os(u,!a),(l=u[1])-(s=u[0])),f=s,y=[],m=0;c&&m<i.length;m++){var v=new h({shape:{startAngle:f,endAngle:l=s+g*Math.min(Math.max(i[m][0],0),1),cx:o.cx,cy:o.cy,clockwise:a,r0:o.r-d,r:o.r},silent:!0});v.setStyle({fill:i[m][1]}),v.setStyle(p.getLineStyle(["color","width"])),y.push(v),f=l}y.reverse(),nt(y,function(t){return r.add(t)});function x(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]}this._renderTicks(t,e,n,x,o,s,l,a,d),this._renderTitleAndDetail(t,e,n,x,o),this._renderAnchor(t,o),this._renderPointer(t,e,n,x,o,s,l,a,d)},IO.prototype._renderTicks=function(t,E,z,e,n,i,o,V,r){for(var a,s,l,u,h,c,p,d=this.group,g=n.cx,f=n.cy,y=n.r,m=+t.get("min"),B=+t.get("max"),v=t.getModel("splitLine"),x=t.getModel("axisTick"),_=t.getModel("axisLabel"),b=t.get("splitNumber"),w=x.get("splitNumber"),S=j(v.get("length"),y),M=j(x.get("length"),y),I=i,T=(o-i)/b,C=T/w,D=v.getModel("lineStyle").getLineStyle(),A=x.getModel("lineStyle").getLineStyle(),k=v.get("distance"),L=0;L<=b;L++)if(O=Math.cos(I),N=Math.sin(I),v.get("show")&&(a=new Fh({shape:{x1:O*(y-(p=k?k+r:r))+g,y1:N*(y-p)+f,x2:O*(y-S-p)+g,y2:N*(y-S-p)+f},style:D,silent:!0}),"auto"===D.stroke&&a.setStyle({stroke:e(L/b)}),d.add(a)),_.get("show")&&(p=_.get("distance")+k,a=wO(Dr(L/b*(B-m)+m),_.get("formatter")),s=e(L/b),l=O*(y-S-p)+g,u=N*(y-S-p)+f,c=0,"radial"===(h=_.get("rotate"))?(c=-I+2*Math.PI)>Math.PI/2&&(c+=Math.PI):"tangential"===h?c=-I-Math.PI/2:Y(h)&&(c=h*Math.PI/180),0===c?d.add(new K({style:ap(_,{text:a,x:l,y:u,verticalAlign:N<-.8?"top":.8<N?"bottom":"middle",align:O<-.4?"left":.4<O?"right":"center"},{inheritColor:s}),silent:!0})):d.add(new K({style:ap(_,{text:a,x:l,y:u,verticalAlign:"middle",align:"center"},{inheritColor:s}),silent:!0,originX:l,originY:u,rotation:c}))),x.get("show")&&L!==b){p=(p=x.get("distance"))?p+r:r;for(var P=0;P<=w;P++){var O=Math.cos(I),N=Math.sin(I),R=new Fh({shape:{x1:O*(y-p)+g,y1:N*(y-p)+f,x2:O*(y-M-p)+g,y2:N*(y-M-p)+f},silent:!0,style:A});"auto"===A.stroke&&R.setStyle({stroke:e((L+P/w)/b)}),d.add(R),I+=C}I-=C}else I+=T},IO.prototype._renderPointer=function(s,t,e,u,l,a,n,h,c){var r=this.group,p=this._data,d=this._progressEls,g=[],f=s.get(["pointer","show"]),y=s.getModel("progress"),m=y.get("show"),v=s.getData(),x=v.mapDimension("value"),i=+s.get("min"),_=+s.get("max"),b=[i,_],w=[a,n];function S(t,e){var t=v.getItemModel(t).getModel("pointer"),n=j(t.get("width"),l.r),i=j(t.get("length"),l.r),o=s.get(["pointer","icon"]),r=t.get("offsetCenter"),a=j(r[0],l.r),r=j(r[1],l.r),t=t.get("keepAspect"),o=o?s0(o,a-n/2,r-i,n,i,null,t):new _O({shape:{angle:-Math.PI/2,width:n,r:i,x:a,y:r}});return o.rotation=-(e+Math.PI/2),o.x=l.cx,o.y=l.cy,o}function M(t,e){var n=y.get("roundCap")?Bb:wh,i=y.get("overlap"),o=i?y.get("width"):c/v.count(),r=i?l.r-o:l.r-(t+1)*o,o=i?l.r:l.r-t*o,n=new n({shape:{startAngle:a,endAngle:e,cx:l.cx,cy:l.cy,clockwise:h,r0:r,r:o}});return i&&(n.z2=_-v.get(x,t)%_),n}(m||f)&&(v.diff(p).add(function(t){var e,n,i=v.get(x,t);f&&(_c(e=S(t,a),{rotation:-((isNaN(+i)?w[0]:Cr(i,b,w,!0))+Math.PI/2)},s),r.add(e),v.setItemGraphicEl(t,e)),m&&(e=M(t,a),n=y.get("clip"),_c(e,{shape:{endAngle:Cr(i,b,w,n)}},s),r.add(e),Nl(s.seriesIndex,v.dataType,t,e),g[t]=e)}).update(function(t,e){var n,i,o=v.get(x,t);f&&((i=S(t,n=(n=p.getItemGraphicEl(e))?n.rotation:a)).rotation=n,C(i,{rotation:-((isNaN(+o)?w[0]:Cr(o,b,w,!0))+Math.PI/2)},s),r.add(i),v.setItemGraphicEl(t,i)),m&&(i=M(t,(n=d[e])?n.shape.endAngle:a),e=y.get("clip"),C(i,{shape:{endAngle:Cr(o,b,w,e)}},s),r.add(i),Nl(s.seriesIndex,v.dataType,t,i),g[t]=i)}).execute(),v.each(function(t){var e,n,i,o,r=v.getItemModel(t),a=r.getModel("emphasis"),s=a.get("focus"),l=a.get("blurScope"),a=a.get("disabled");f&&(e=v.getItemGraphicEl(t),i=(n=v.getItemVisual(t,"style")).fill,e instanceof ll?(o=e.style,e.useStyle(F({image:o.image,x:o.x,y:o.y,width:o.width,height:o.height},n))):(e.useStyle(n),"pointer"!==e.type&&e.setColor(i)),e.setStyle(r.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===e.style.fill&&e.setStyle("fill",u(Cr(v.get(x,t),b,[0,1],!0))),e.z2EmphasisLift=0,Du(e,r),Mu(e,s,l,a)),m&&((o=g[t]).useStyle(v.getItemVisual(t,"style")),o.setStyle(r.getModel(["progress","itemStyle"]).getItemStyle()),o.z2EmphasisLift=0,Du(o,r),Mu(o,s,l,a))}),this._progressEls=g)},IO.prototype._renderAnchor=function(t,e){var n,i,o,r,t=t.getModel("anchor");t.get("show")&&(n=t.get("size"),r=t.get("icon"),i=t.get("offsetCenter"),o=t.get("keepAspect"),(r=s0(r,e.cx-n/2+j(i[0],e.r),e.cy-n/2+j(i[1],e.r),n,n,null,o)).z2=t.get("showAbove")?1:0,r.setStyle(t.getModel("itemStyle").getItemStyle()),this.group.add(r))},IO.prototype._renderTitleAndDetail=function(c,t,e,p,d){var n=this,g=c.getData(),f=g.mapDimension("value"),y=+c.get("min"),m=+c.get("max"),v=new Z,x=[],_=[],b=c.isAnimationEnabled(),w=c.get(["pointer","showAbove"]);g.diff(this._data).add(function(t){x[t]=new K({silent:!0}),_[t]=new K({silent:!0})}).update(function(t,e){x[t]=n._titleEls[e],_[t]=n._detailEls[e]}).execute(),g.each(function(t){var e,n,i,o,a,r=g.getItemModel(t),s=g.get(f,t),l=new Z,u=p(Cr(s,[y,m],[0,1],!0)),h=r.getModel("title"),h=(h.get("show")&&(e=h.get("offsetCenter"),n=d.cx+j(e[0],d.r),e=d.cy+j(e[1],d.r),(o=x[t]).attr({z2:w?0:2,style:ap(h,{x:n,y:e,text:g.getName(t),align:"center",verticalAlign:"middle"},{inheritColor:u})}),l.add(o)),r.getModel("detail"));h.get("show")&&(n=h.get("offsetCenter"),e=d.cx+j(n[0],d.r),r=d.cy+j(n[1],d.r),n=j(h.get("width"),d.r),i=j(h.get("height"),d.r),u=c.get(["progress","show"])?g.getItemVisual(t,"style").fill:u,o=_[t],a=h.get("formatter"),o.attr({z2:w?0:2,style:ap(h,{x:e,y:r,text:wO(s,a),width:isNaN(n)?null:n,height:isNaN(i)?null:i,align:"center",verticalAlign:"middle"},{inheritColor:u})}),gp(o,{normal:h},s,function(t){return wO(t,a)}),b&&fp(o,t,g,c,{getFormattedLabel:function(t,e,n,i,o,r){return wO(r?r.interpolatedValue:s,a)}}),l.add(o)),v.add(l)}),this.group.add(v),this._titleEls=x,this._detailEls=_},IO.type="gauge";var SO,MO=IO;function IO(){var t=null!==SO&&SO.apply(this,arguments)||this;return t.type=IO.type,t}u(DO,TO=Gy),DO.prototype.getInitialData=function(t,e){return bS(this,["value"])},DO.type="series.gauge",DO.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}};var TO,CO=DO;function DO(){var t=null!==TO&&TO.apply(this,arguments)||this;return t.type=DO.type,t.visualStyleAccessPath="itemStyle",t}r(function(t){t.registerChartView(MO),t.registerSeriesModel(CO)});var AO,kO=["itemStyle","opacity"],LO=(u(PO,AO=Lh),PO.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(kO))?1:s;n||Ic(this),this.useStyle(t.getItemVisual(e,"style")),this.style.lineJoin="round",n?(this.setShape({points:r.points}),this.style.opacity=0,_c(this,{style:{opacity:s}},i,e)):C(this,{style:{opacity:s},shape:{points:r.points}},i,e),Du(this,o),this._updateLabel(t,e),Mu(this,a.get("focus"),a.get("blurScope"),a.get("disabled"))},PO.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,s=(op(i,rp(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}),a.linePoints);n.setShape({points:s}),this.textGuideLineConfig={anchor:s?new E(s[0][0],s[0][1]):null},C(i,{style:{x:a.x,y:a.y}},o,e),i.attr({rotation:a.rotation,originX:a.x,originY:a.y,z2:10}),q_(this,K_(r),{stroke:l})},PO);function PO(t,e){var n=AO.call(this)||this,i=n,o=new Rh,r=new K;return i.setTextContent(r),n.setTextGuideLine(o),n.updateData(t,e,!0),n}u(RO,OO=em),RO.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 LO(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){Mc(o.getItemGraphicEl(t),e,t)}).execute(),this._data=i},RO.prototype.remove=function(){this.group.removeAll(),this._data=null},RO.prototype.dispose=function(){},RO.type="funnel";var OO,NO=RO;function RO(){var t=null!==OO&&OO.apply(this,arguments)||this;return t.type=RO.type,t.ignoreLabelLineUpdate=!0,t}u(VO,EO=Gy),VO.prototype.init=function(t){EO.prototype.init.apply(this,arguments),this.legendVisualProvider=new wS(T(this.getData,this),T(this.getRawData,this)),this._defaultLabelLine(t)},VO.prototype.getInitialData=function(t,e){return bS(this,{coordDimensions:["value"],encodeDefaulter:P(ig,this)})},VO.prototype._defaultLabelLine=function(t){Qr(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},VO.prototype.getDataParams=function(t){var e=this.getData(),n=EO.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},VO.type="series.funnel",VO.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}};var EO,zO=VO;function VO(){var t=null!==EO&&EO.apply(this,arguments)||this;return t.type=VO.type,t}function BO(t,C){t.eachSeriesByType("funnel",function(t){function e(t,e){if("horizontal"===l){var n=Cr(a.get(s,t)||0,[g,f],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=Cr(a.get(s,t)||0,[g,f],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 a=t.getData(),s=a.mapDimension("value"),n=t.get("sort"),i=(i=C,Ld(t.getBoxLayoutParams(),{width:i.getWidth(),height:i.getHeight()})),l=t.get("orient"),u=i.width,h=i.height,o=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 D(e)?o.sort(e):"none"!==e&&o.sort(function(t,e){return r?i[t]-i[e]:i[e]-i[t]}),o}(a,n),c=i.x,p=i.y,d="horizontal"===l?[j(t.get("minSize"),h),j(t.get("maxSize"),h)]:[j(t.get("minSize"),u),j(t.get("maxSize"),u)],i=a.getDataExtent(s),g=t.get("min"),f=t.get("max"),y=(null==g&&(g=Math.min(i[0],0)),null==f&&(f=i[1]),t.get("funnelAlign")),r=t.get("gap"),m=(("horizontal"===l?u:h)-r*(a.count()-1))/a.count();"ascending"===n&&(m=-m,r=-r,"horizontal"===l?c+=u:p+=h,o=o.reverse());for(var v,x,_=0;_<o.length;_++){var b,w,S,M=o[_],I=o[_+1],T=a.getItemModel(M);"horizontal"===l?(null==(b=T.get(["itemStyle","width"]))?b=m:(b=j(b,u),"ascending"===n&&(b=-b)),w=e(M,c),S=e(I,c+b),c+=b+r):(null==(b=T.get(["itemStyle","height"]))?b=m:(b=j(b,h),"ascending"===n&&(b=-b)),w=e(M,p),S=e(I,p+b),p+=b+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,a,s,l=v.getItemModel(t),u=l.getModel("label").get("position"),l=l.getModel("labelLine"),t=v.getItemLayout(t),h=t.points,c="inner"===u||"inside"===u||"center"===u||"insideLeft"===u||"insideRight"===u,u=c?(s="insideLeft"===u?(e=(h[0][0]+h[3][0])/2+5,n=(h[0][1]+h[3][1])/2,"left"):"insideRight"===u?(e=(h[1][0]+h[2][0])/2-5,n=(h[1][1]+h[2][1])/2,"right"):(e=(h[0][0]+h[1][0]+h[2][0]+h[3][0])/4,n=(h[0][1]+h[1][1]+h[2][1]+h[3][1])/4,"center"),[[e,n],[e,n]]):(a=r=o=i=void 0,l=l.get("length"),s="left"===u?(i=(h[3][0]+h[0][0])/2,o=(h[3][1]+h[0][1])/2,e=(r=i-l)-5,"right"):"right"===u?(i=(h[1][0]+h[2][0])/2,o=(h[1][1]+h[2][1])/2,e=(r=i+l)+5,"left"):"top"===u?(i=(h[3][0]+h[0][0])/2,n=(a=(o=(h[3][1]+h[0][1])/2)-l)-5,"center"):"bottom"===u?(i=(h[1][0]+h[2][0])/2,n=(a=(o=(h[1][1]+h[2][1])/2)+l)+5,"center"):"rightTop"===u?(i=("horizontal"===x?h[3]:h[1])[0],o=("horizontal"===x?h[3]:h[1])[1],"horizontal"===x?(n=(a=o-l)-5,"center"):(e=(r=i+l)+5,"top")):"rightBottom"===u?(i=h[2][0],o=h[2][1],"horizontal"===x?(n=(a=o+l)+5,"center"):(e=(r=i+l)+5,"bottom")):"leftTop"===u?(i=h[0][0],o=("horizontal"===x?h[0]:h[1])[1],"horizontal"===x?(n=(a=o-l)-5,"center"):(e=(r=i-l)-5,"right")):"leftBottom"===u?(i=("horizontal"===x?h[1]:h[3])[0],o=("horizontal"===x?h[1]:h[2])[1],"horizontal"===x?(n=(a=o+l)+5,"center"):(e=(r=i-l)-5,"right")):(i=(h[1][0]+h[2][0])/2,o=(h[1][1]+h[2][1])/2,"horizontal"===x?(n=(a=o+l)+5,"center"):(e=(r=i+l)+5,"left")),"horizontal"===x?e=r=i:n=a=o,[[i,o],[r,a]]);t.label={linePoints:u,x:e,y:n,verticalAlign:"middle",textAlign:s,inside:c}})})}r(function(t){t.registerChartView(NO),t.registerSeriesModel(zO),t.registerLayout(BO),t.registerProcessor(uS("funnel"))});var FO,GO=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},WO=(u(HO,FO=q),HO.prototype.getDefaultShape=function(){return new GO},HO.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()},HO.prototype.highlight=function(){cu(this)},HO.prototype.downplay=function(){pu(this)},HO);function HO(t){return FO.call(this,t)||this}u(UO,YO=em),UO.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(e){var t,n,i,o,r,a,s,l=new WO,u=$(l),u=(u.dataIndex=e.dataIndex,u.seriesIndex=b.seriesIndex,u.dataType="edge",e.getModel()),h=u.getModel("lineStyle"),c=h.get("curveness"),p=e.node1.getLayout(),d=e.node1.getModel(),g=d.get("localX"),d=d.get("localY"),f=e.node2.getLayout(),y=e.node2.getModel(),m=y.get("localX"),y=y.get("localY"),v=e.getLayout(),x=(l.shape.extent=Math.max(1,v.dy),g="vertical"===(l.shape.orient=T)?(t=(null!=g?g*S:p.x)+v.sy,n=(null!=d?d*M:p.y)+p.dy,i=(null!=m?m*S:f.x)+v.ty,r=t,a=n*(1-c)+(o=null!=y?y*M:f.y)*c,s=i,n*c+o*(1-c)):(t=(null!=g?g*S:p.x)+p.dx,n=(null!=d?d*M:p.y)+v.sy,r=t*(1-c)+(i=null!=m?m*S:f.x)*c,a=n,s=t*c+i*(1-c),o=(null!=y?y*M:f.y)+v.ty),l.setShape({x1:t,y1:n,x2:i,y2:o,cpx1:r,cpy1:a,cpx2:s,cpy2:g}),l.useStyle(h.getItemStyle()),ZO(l.style,T,e),""+u.get("value")),_=rp(u,"edgeLabel"),d=(op(l,_,{labelFetcher:{getFormattedLabel:function(t,e,n,i,o,r){return b.getFormattedLabel(t,e,"edge",i,St(o,_.normal&&_.normal.get("formatter"),x),r)}},labelDataIndex:e.dataIndex,defaultText:x}),l.setTextConfig({position:"inside"}),u.getModel("emphasis")),p=(Du(l,u,"lineStyle",function(t){t=t.getItemStyle();return ZO(t,T,e),t}),w.add(l),I.setItemGraphicEl(e.dataIndex,l),d.get("focus"));Mu(l,"adjacency"===p?e.getAdjacentDataIndices():"trajectory"===p?e.getTrajectoryDataIndices():p,d.get("blurScope"),d.get("disabled"))}),r.eachNode(function(t){var e=t.getLayout(),n=t.getModel(),i=n.get("localX"),o=n.get("localY"),r=n.getModel("emphasis"),i=new L({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}),o=(op(i,rp(n),{labelFetcher:{getFormattedLabel:function(t,e){return b.getFormattedLabel(t,e,"node")}},labelDataIndex:t.dataIndex,defaultText:t.id}),i.disableLabelAnimation=!0,i.setStyle("fill",t.getVisual("color")),i.setStyle("decal",t.getVisual("style").decal),Du(i,n),w.add(i),s.setItemGraphicEl(t.dataIndex,i),$(i).dataType="node",r.get("focus"));Mu(i,"adjacency"===o?t.getAdjacentDataIndices():"trajectory"===o?t.getTrajectoryDataIndices():o,r.get("blurScope"),r.get("disabled"))}),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((a=w.getBoundingRect(),r=b,e=function(){w.removeClipPath()},_c(n=new L({shape:{x:a.x-10,y:a.y-10,width:0,height:a.height+20}}),{shape:{width:a.width+20}},r,e),n)),this._data=b.getData()},UO.prototype.dispose=function(){},UO.type="sankey";var YO,XO=UO;function UO(){var t=null!==YO&&YO.apply(this,arguments)||this;return t.type=UO.type,t._focusAdjacencyDisabled=!1,t}function ZO(t,e,n){switch(t.fill){case"source":t.fill=n.node1.getVisual("color"),t.decal=n.node1.getVisual("style").decal;break;case"target":t.fill=n.node2.getVisual("color"),t.decal=n.node2.getVisual("style").decal;break;case"gradient":var i=n.node1.getVisual("color"),o=n.node2.getVisual("color");H(i)&&H(o)&&(t.fill=new ic(0,0,+("horizontal"===e),+("vertical"===e),[{color:i,offset:0},{color:o,offset:1}]))}}u(KO,jO=Gy),KO.prototype.getInitialData=function(t,e){for(var n=t.edges||t.links,i=t.data||t.nodes,o=t.levels,r=(this.levelModels=[],this.levelModels),a=0;a<o.length;a++)null!=o[a].depth&&0<=o[a].depth&&(r[o[a].depth]=new kp(o[a],this,e));if(i&&n)return sL(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,n=n.levelModels[e])&&(t.parentModel=n),t}),e.wrapMethod("getItemModel",function(t,e){var n=t.parentModel,e=n.getGraph().getEdgeByIndex(e).node1.getLayout();return e&&(e=e.depth,n=n.levelModels[e])&&(t.parentModel=n),t})}).data},KO.prototype.setNodePosition=function(t,e){t=(this.option.data||this.option.nodes)[t];t.localX=e[0],t.localY=e[1]},KO.prototype.getGraph=function(){return this.getData().graph},KO.prototype.getEdgeData=function(){return this.getGraph().edgeData},KO.prototype.formatTooltip=function(t,e,n){function i(t){return isNaN(t)||null==t}var o,r;return"edge"===n?(o=(r=this.getDataParams(t,n)).data,r=r.value,Iy("nameValue",{name:o.source+" -- "+o.target,value:r,noValue:i(r)})):(o=this.getGraph().getNodeByIndex(t).getLayout().value,Iy("nameValue",{name:null!=(r=this.getDataParams(t,n).data.name)?r+"":null,value:o,noValue:i(o)}))},KO.prototype.optionUpdated=function(){},KO.prototype.getDataParams=function(t,e){var n=jO.prototype.getDataParams.call(this,t,e);return null==n.value&&"node"===e&&(e=this.getGraph().getNodeByIndex(t).getLayout().value,n.value=e),n},KO.type="series.sankey",KO.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3};var jO,qO=KO;function KO(){var t=null!==jO&&jO.apply(this,arguments)||this;return t.type=KO.type,t}function $O(t,et){t.eachSeriesByType("sankey",function(t){var e=t.get("nodeWidth"),n=t.get("nodeGap"),i=(i=et,Ld(t.getBoxLayoutParams(),{width:i.getWidth(),height:i.getHeight()})),o=(t.layoutInfo=i).width,i=i.height,r=t.getGraph(),a=r.nodes,r=r.edges;nt(a,function(t){var e=aN(t.outEdges,rN),n=aN(t.inEdges,rN),i=t.getValue()||0,e=Math.max(e,n,i);t.setLayout({value:e},!0)});for(var s=0!==pt(a,function(t){return 0===t.getLayout().value}).length?0:t.get("layoutIterations"),l=t.get("orient"),t=t.get("nodeAlign"),u=(n=n,s=s,a),E=r,h=e,o=e=o,z=i,c=l,p=[],d=[],g=[],f=[],y=0,m=0;m<E.length;m++)p[m]=1;for(m=0;m<u.length;m++)d[m]=u[m].inEdges.length,0===d[m]&&g.push(u[m]);for(var v=-1;g.length;){for(var x=0;x<g.length;x++){var _=g[x],b=_.hostGraph.data.getRawDataItem(_.dataIndex),V=null!=b.depth&&0<=b.depth;V&&b.depth>v&&(v=b.depth),_.setLayout({depth:V?b.depth:y},!0),"vertical"===c?_.setLayout({dy:h},!0):_.setLayout({dx:h},!0);for(var w=0;w<_.outEdges.length;w++){var S=_.outEdges[w],M=E.indexOf(S),M=(p[M]=0,S.node2),S=u.indexOf(M);0==--d[S]&&f.indexOf(M)<0&&f.push(M)}}++y,g=f,f=[]}for(m=0;m<p.length;m++)if(1===p[m])throw new Error("Sankey is a DAG, the original data has cycle!");var I=y-1<v?v:y-1;if(t&&"left"!==t){var T=u,B=I;if("right"===t){for(var C=[],D=T,F=0;D.length;){for(var G=0;G<D.length;G++){var W=D[G];W.setLayout({skNodeHeight:F},!0);for(var H=0;H<W.inEdges.length;H++){var Y=W.inEdges[H];C.indexOf(Y.node1)<0&&C.push(Y.node1)}}D=C,C=[],++F}nt(T,function(t){JO(t)||t.setLayout({depth:Math.max(0,B-t.getLayout().skNodeHeight)},!0)})}else if("justify"===t){var X=T;var U=B;nt(X,function(t){JO(t)||t.outEdges.length||t.setLayout({depth:U},!0)})}}var Z="vertical"===c?(z-h)/I:(o-h)/I,j=c;nt(u,function(t){var e=t.getLayout().depth*Z;"vertical"===j?t.setLayout({y:e},!0):t.setLayout({x:e},!0)});var t=r,A=i,k=e,L=n,q=s,P=l,O=function(t,e){var n=[],i="vertical"===e?"y":"x",o=ma(t,function(t){return t.getLayout()[i]});return o.keys.sort(function(t,e){return t-e}),nt(o.keys,function(t){n.push(o.buckets.get(t))}),n}(a,P),T=O,z=t,K=A,$=k,J=L,Q=P,N=1/0;nt(T,function(t){var e=t.length,n=0,t=(nt(t,function(t){n+=t.getLayout().value}),"vertical"===Q?($-(e-1)*J)/n:(K-(e-1)*J)/n);t<N&&(N=t)}),nt(T,function(t){nt(t,function(t,e){var n=t.getLayout().value*N;"vertical"===Q?(t.setLayout({x:e},!0),t.setLayout({dx:n},!0)):(t.setLayout({y:e},!0),t.setLayout({dy:n},!0))})}),nt(z,function(t){var e=+t.getValue()*N;t.setLayout({dy:e},!0)}),QO(O,L,A,k,P);for(var tt=1;0<q;q--)!function(t,i,o){nt(t.slice().reverse(),function(t){nt(t,function(t){var e,n;t.outEdges.length&&(e=aN(t.outEdges,tN,o)/aN(t.outEdges,rN),isNaN(e)&&(e=(n=t.outEdges.length)?aN(t.outEdges,eN,o)/n:0),"vertical"===o?(n=t.getLayout().x+(e-oN(t,o))*i,t.setLayout({x:n},!0)):(n=t.getLayout().y+(e-oN(t,o))*i,t.setLayout({y:n},!0)))})})}(O,tt*=.99,P),QO(O,L,A,k,P),function(t,i,o){nt(t,function(t){nt(t,function(t){var e,n;t.inEdges.length&&(e=aN(t.inEdges,nN,o)/aN(t.inEdges,rN),isNaN(e)&&(e=(n=t.inEdges.length)?aN(t.inEdges,iN,o)/n:0),"vertical"===o?(n=t.getLayout().x+(e-oN(t,o))*i,t.setLayout({x:n},!0)):(n=t.getLayout().y+(e-oN(t,o))*i,t.setLayout({y:n},!0)))})})}(O,tt,P),QO(O,L,A,k,P);var o=a,R="vertical"===l?"x":"y";nt(o,function(t){t.outEdges.sort(function(t,e){return t.node2.getLayout()[R]-e.node2.getLayout()[R]}),t.inEdges.sort(function(t,e){return t.node1.getLayout()[R]-e.node1.getLayout()[R]})}),nt(o,function(t){var e=0,n=0;nt(t.outEdges,function(t){t.setLayout({sy:e},!0),e+=t.getLayout().dy}),nt(t.inEdges,function(t){t.setLayout({ty:n},!0),n+=t.getLayout().dy})})})}function JO(t){t=t.hostGraph.data.getRawDataItem(t.dataIndex);return null!=t.depth&&0<=t.depth}function QO(t,l,u,h,c){var p="vertical"===c?"x":"y";nt(t,function(t){t.sort(function(t,e){return t.getLayout()[p]-e.getLayout()[p]});for(var e,n,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))){e=n.getLayout()[p]-i,"vertical"===c?n.setLayout({x:e},!0):n.setLayout({y:e},!0);for(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 tN(t,e){return oN(t.node2,e)*t.getValue()}function eN(t,e){return oN(t.node2,e)}function nN(t,e){return oN(t.node1,e)*t.getValue()}function iN(t,e){return oN(t.node1,e)}function oN(t,e){return"vertical"===e?t.getLayout().x+t.getLayout().dx/2:t.getLayout().y+t.getLayout().dy/2}function rN(t){return t.getValue()}function aN(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 sN(t){t.eachSeriesByType("sankey",function(i){var o,r,t=i.getGraph(),e=t.nodes,t=t.edges;e.length&&(o=1/0,r=-1/0,nt(e,function(t){t=t.getLayout().value;t<o&&(o=t),r<t&&(r=t)}),nt(e,function(t){var e=new QT({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}))})),t.length&&nt(t,function(t){var e=t.getModel().get("lineStyle");t.setVisual("style",e)})})}r(function(t){t.registerChartView(XO),t.registerSeriesModel(qO),t.registerLayout($O),t.registerVisual(sN),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])})})});u(hN,lN=em),hN.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 i=new i1(this._layersSeries||[],M,o,o),I=[];function r(t,e,n){var i=w._layers;if("remove"===t)S.remove(i[e]);else{for(var o,r=[],a=[],s=M[e].indices,l=0;l<s.length;l++){var u=b.getItemLayout(s[l]),h=u.x,c=u.y0,u=u.y;r.push(h,c),a.push(h,c+u),o=b.getItemVisual(s[l],"style")}var p,d,g,f,y,m=b.getItemLayout(s[0]),v=_.getModel("label").get("margin"),x=_.getModel("emphasis"),t=("add"===t?(d=I[e]=new Z,p=new Gw({shape:{points:r,stackedOnPoints:a,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),d.add(p),S.add(d),_.isAnimationEnabled()&&p.setClipPath((t=p.getBoundingRect(),g=_,f=function(){p.removeClipPath()},_c(y=new L({shape:{x:t.x-10,y:t.y-10,width:0,height:t.height+20}}),{shape:{x:t.x-50,width:t.width+100,height:t.height+20}},g,f),y))):(d=i[n],p=d.childAt(0),S.add(d),I[e]=d,C(p,{shape:{points:r,stackedOnPoints:a}},_),Ic(p)),op(p,rp(_),{labelDataIndex:s[l-1],defaultText:b.getName(s[l-1]),inheritColor:o.fill},{normal:{verticalAlign:"middle"}}),p.setTextConfig({position:null,local:!0}),p.getTextContent());t&&(t.x=m.x-v,t.y=m.y0+m.y/2),p.useStyle(o),b.setItemGraphicEl(e,p),Du(p,_),Mu(p,x.get("focus"),x.get("blurScope"),x.get("disabled"))}}i.add(T(r,this,"add")).update(T(r,this,"update")).remove(T(r,this,"remove")).execute(),this._layersSeries=M,this._layers=I},hN.type="themeRiver";var lN,uN=hN;function hN(){var t=null!==lN&&lN.apply(this,arguments)||this;return t.type=hN.type,t._layers=[],t}u(dN,cN=Gy),dN.prototype.init=function(t){cN.prototype.init.apply(this,arguments),this.legendVisualProvider=new wS(T(this.getData,this),T(this.getRawData,this))},dN.prototype.fixData=function(t){for(var e=t.length,n={},i=ma(t,function(t){return n.hasOwnProperty(t[0]+"")||(n[t[0]+""]=-1),t[2]}),o=[],r=(i.buckets.each(function(t,e){o.push({name:e,dataList:t})}),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},dN.prototype.getInitialData=function(t,e){for(var n=this.getReferringComponents("singleAxis",da).models[0].get("type"),t=pt(t.data,function(t){return void 0!==t[2]}),i=this.fixData(t||[]),o=[],r=this.nameMap=R(),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++);t=L1(i,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:u1(n)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,n=new k1(t,this);return n.initData(i),n},dN.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=ma(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},dN.prototype.getAxisTooltipData=function(t,e,n){B(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]),g=Math.abs(d-e);g<=u&&(i=d,u=g,h=r[l].indices[p])}a.push(h)}return{dataIndices:a,nestestValue:i}},dN.prototype.formatTooltip=function(t,e,n){var i=this.getData();return Iy("nameValue",{name:i.getName(t),value:i.get(i.mapDimension("value"),t)})},dN.type="series.themeRiver",dN.dependencies=["singleAxis"],dN.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}};var cN,pN=dN;function dN(){var t=null!==cN&&cN.apply(this,arguments)||this;return t.type=dN.type,t}function gN(t,e){t.eachSeriesByType("themeRiver",function(t){var e=t.getData(),n=t.coordinateSystem,i={},o=n.getRect(),r=(i.rect=o,t.get("boundaryGap")),n=n.getAxis();i.boundaryGap=r,"horizontal"===n.orient?(r[0]=j(r[0],o.height),r[1]=j(r[1],o.height),fN(e,t,o.height-r[0]-r[1])):(r[0]=j(r[0],o.width),r[1]=j(r[1],o.width),fN(e,t,o.width-r[0]-r[1])),e.setLayout("layoutInfo",i)})}function fN(n,t,e){if(n.count())for(var i,o=t.coordinateSystem,r=t.getLayerSeries(),a=n.mapDimension("single"),s=n.mapDimension("value"),l=V(r,function(t){return V(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 g=1;g<c;++g)i+=l[g-1][d][1]*h,n.setItemLayout(r[g].indices[d],{layerIndex:g,x:l[g][d][0],y0:i,y:l[g][d][1]*h})}}r(function(t){t.registerChartView(uN),t.registerSeriesModel(pN),t.registerLayout(gN),t.registerProcessor(uS("themeRiver"))});var yN,mN=["itemStyle","borderWidth"],vN=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],xN=new eh,_N=(u(bN,yN=em),bN.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:vN[+o],categoryDim:vN[1-+o]},n=(u.diff(h).add(function(t){var e,n;u.hasValue(t)&&(e=AN(u,t),e=wN(u,t,e,c),n=PN(u,c,e),u.setItemGraphicEl(t,n),l.add(n),zN(n,c,e))}).update(function(t,e){var n,i,o,r,a,s,e=h.getItemGraphicEl(e);u.hasValue(t)?(n=AN(u,t),n=wN(u,t,n,c),i=NN(u,n),e&&i!==e.__pictorialShapeStr&&(l.remove(e),u.setItemGraphicEl(t,null),e=null),e?(i=e,o=c,a=(r=n).animationModel,s=r.dataIndex,C(i.__pictorialBundle,{x:r.bundlePosition[0],y:r.bundlePosition[1]},a,s),(r.symbolRepeat?IN:TN)(i,o,r,!0),CN(i,r,!0),DN(i,o,r,!0)):e=PN(u,c,n,!0),u.setItemGraphicEl(t,e),e.__pictorialSymbolMeta=n,l.add(e),zN(e,c,n)):l.remove(e)}).remove(function(t){var e=h.getItemGraphicEl(t);e&&ON(h,t,e.__pictorialSymbolMeta.animationModel,e)}).execute(),t.get("clip",!0)?Eb(t.coordinateSystem,!1,t):null);return n?l.setClipPath(n):l.removeClipPath(),this._data=u,this.group},bN.prototype.remove=function(e,t){var n=this.group,i=this._data;e.get("animation")?i&&i.eachItemGraphicEl(function(t){ON(i,$(t).dataIndex,e,t)}):n.removeAll()},bN.type="pictorialBar",bN);function bN(){var t=null!==yN&&yN.apply(this,arguments)||this;return t.type=bN.type,t}function wN(t,e,n,i){var o=t.getItemLayout(e),r=n.get("symbolRepeat"),a=n.get("symbolClip"),s=n.get("symbolPosition")||"start",l=(n.get("symbolRotate")||0)*Math.PI/180||0,u=n.get("symbolPatternSize")||2,h=n.isAnimationEnabled(),a={dataIndex:e,layout:o,itemModel:n,symbolType:t.getItemVisual(e,"symbol")||"circle",style:t.getItemVisual(e,"style"),symbolClip:a,symbolRepeat:r,symbolRepeatDirection:n.get("symbolRepeatDirection"),symbolPatternSize:u,rotation:l,animationModel:h?n:null,hoverScale:h&&n.get(["emphasis","scale"]),z2:n.getShallow("z",!0)||0},h=n,c=r,p=o,d=i,g=a,f=d.valueDim,h=h.get("symbolBoundingData"),y=d.coordSys.getOtherAxis(d.coordSys.getBaseAxis()),m=y.toGlobalCoord(y.dataToCoord(0)),v=1-(p[f.wh]<=0),y=(x=B(h)?((x=[SN(y,h[0])-m,SN(y,h[1])-m])[1]<x[0]&&x.reverse(),x[v]):null!=h?SN(y,h)-m:c?d.coordSysExtent[f.index][v]-m:p[f.wh],g.boundingLength=x,c&&(g.repeatCutLength=p[f.wh]),g.pxSign=0<x?1:-1,t),h=e,d=o,v=r,m=a.boundingLength,c=a.pxSign,p=u,f=i,g=a,x=f.valueDim,t=f.categoryDim,d=Math.abs(d[t.wh]),y=y.getItemVisual(h,"symbolSize"),e=((h=B(y)?y.slice():null==y?["100%","100%"]:[y,y])[t.index]=j(h[t.index],d),h[x.index]=j(h[x.index],v?d:Math.abs(m)),g.symbolSize=h,(g.symbolScale=[h[0]/p,h[1]/p])[x.index]*=(f.isHorizontal?-1:1)*c,n),u=a.symbolScale,y=l,t=i,v=a,d=((e=e.get(mN)||0)&&(xN.attr({scaleX:u[0],scaleY:u[1],rotation:y}),xN.updateTransform(),e=(e/=xN.getLineScale())*u[t.valueDim.index]),v.valueLineWidth=e||0,a.symbolSize),m=u0(n.get("symbolOffset"),d),g=n,h=d,p=o,f=r,c=m,l=s,y=a.valueLineWidth,u=a.boundingLength,t=a.repeatCutLength,v=i,e=a,n=v.categoryDim,d=v.valueDim,o=e.pxSign,r=y=Math.max(h[d.index]+y,0),_=(f&&(_=Math.abs(u),g=wt(g.get("symbolMargin"),"15%")+"",b=!1,g.lastIndexOf("!")===g.length-1&&(b=!0,g=g.slice(0,g.length-1)),g=j(g,h[d.index]),h=Math.max(y+2*g,0),m=b?0:2*g,w=Xr(f),s=w?f:VN((_+m)/h),g=(_-s*y)/2/(b?s:Math.max(s-1,1)),h=y+2*g,m=b?0:2*g,w||"fixed"===f||(s=t?VN((Math.abs(t)+m)/h):0),r=s*h-m,e.repeatTimes=s,e.symbolMargin=g),o*(r/2)),b=((y=e.pathPosition=[])[n.index]=p[n.wh]/2,y[d.index]="start"===l?_:"end"===l?u-_:u/2,c&&(y[0]+=c[0],y[1]+=c[1]),e.bundlePosition=[]),w=(b[n.index]=p[n.xy],b[d.index]=p[d.xy],e.barRectShape=F({},p));return w[d.wh]=o*Math.max(Math.abs(p[d.wh]),Math.abs(y[d.index]+_)),w[n.wh]=p[n.wh],(f=e.clipShape={})[n.xy]=-p[n.xy],f[n.wh]=v.ecSize[n.wh],f[d.xy]=0,f[d.wh]=p[d.wh],a}function SN(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function MN(t){var e=t.symbolPatternSize,t=s0(t.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),"image"!==t.type&&t.setStyle({strokeNoScale:!0}),t}function IN(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(RN(t,function(t){t.__pictorialAnimationIndex=h,t.__pictorialRepeatTimes=u,h<u?EN(t,null,g(h),o,n):EN(t,null,{scaleX:0,scaleY:0},o,n,function(){i.remove(t)}),h++});h<u;h++){var p=MN(o),d=(p.__pictorialAnimationIndex=h,p.__pictorialRepeatTimes=u,i.add(p),g(h));EN(p,{x:d.x,y:d.y,scaleX:0,scaleY:0},{scaleX:d.scaleX,scaleY:d.scaleY,rotation:d.rotation},o,n)}function g(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 TN(t,e,n,i){var o=t.__pictorialBundle,r=t.__pictorialMainPath;r?EN(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=MN(n),o.add(r),EN(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 CN(t,e,n){var i=F({},e.barRectShape),o=t.__pictorialBarRect;o?EN(o,null,{shape:i},e,n):((o=t.__pictorialBarRect=new L({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}})).disableMorphing=!0,t.add(o))}function DN(t,e,n,i){var o,r,a,s;n.symbolClip&&(o=t.__pictorialClipPath,s=F({},n.clipShape),e=e.valueDim,r=n.animationModel,a=n.dataIndex,o?C(o,{shape:s},r,a):(s[e.wh]=0,o=new L({shape:s}),t.__pictorialBundle.setClipPath(o),t.__pictorialClipPath=o,(s={})[e.wh]=n.clipShape[e.wh],tp[i?"updateProps":"initProps"](o,{shape:s},r,a)))}function AN(t,e){t=t.getItemModel(e);return t.getAnimationDelayParams=kN,t.isAnimationEnabled=LN,t}function kN(t){return{index:t.__pictorialAnimationIndex,count:t.__pictorialRepeatTimes}}function LN(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function PN(t,e,n,i){var o=new Z,r=new Z;return o.add(r),(o.__pictorialBundle=r).x=n.bundlePosition[0],r.y=n.bundlePosition[1],n.symbolRepeat?IN(o,e,n):TN(o,0,n),CN(o,n,i),DN(o,e,n,i),o.__pictorialShapeStr=NN(t,n),o.__pictorialSymbolMeta=n,o}function ON(t,e,n,i){var o=i.__pictorialBarRect,r=(o&&o.removeTextContent(),[]);RN(i,function(t){r.push(t)}),i.__pictorialMainPath&&r.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),nt(r,function(t){wc(t,{scaleX:0,scaleY:0},n,e,function(){i.parent&&i.parent.remove(i)})}),t.setItemGraphicEl(e,null)}function NN(t,e){return[t.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function RN(e,n,i){nt(e.__pictorialBundle.children(),function(t){t!==e.__pictorialBarRect&&n.call(i,t)})}function EN(t,e,n,i,o,r){e&&t.attr(e),i.symbolClip&&!o?n&&t.attr(n):n&&tp[o?"updateProps":"initProps"](t,n,i.animationModel,i.dataIndex,r)}function zN(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"),d=(RN(t,function(t){t instanceof ll?(e=t.style,t.useStyle(F({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}),e.valueDim.posDesc[+(0<n.boundingLength)]),g=t.__pictorialBarRect;g.ignoreClip=!0,op(g,rp(o),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:Wb(e.seriesModel.getData(),i),inheritColor:n.style.fill,defaultOpacity:n.style.opacity,defaultOutsidePosition:d}),Mu(t,h,c,r.get("disabled"))}function VN(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}u(GN,BN=bp),GN.prototype.getInitialData=function(t){return t.stack=null,BN.prototype.getInitialData.apply(this,arguments)},GN.type="series.pictorialBar",GN.dependencies=["grid"],GN.defaultOption=Np(bp.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}});var BN,FN=GN;function GN(){var t=null!==BN&&BN.apply(this,arguments)||this;return t.type=GN.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}r(function(t){t.registerChartView(_N),t.registerSeriesModel(FN),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,P(fx,"pictorialBar")),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yx("pictorialBar"))});var WN,HN={color:"fill",borderColor:"stroke"},YN={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},XN=i(),UN=(u(ZN,WN=Gy),ZN.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},ZN.prototype.getInitialData=function(t,e){return V1(null,this)},ZN.prototype.getDataParams=function(t,e,n){t=WN.prototype.getDataParams.call(this,t,e);return n&&(t.info=XN(n).info),t},ZN.type="series.custom",ZN.dependencies=["grid","polar","geo","singleAxis","calendar"],ZN.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},ZN);function ZN(){var t=null!==WN&&WN.apply(this,arguments)||this;return t.type=ZN.type,t}function jN(i,o){return o=o||[0,0],V(["x","y"],function(t,e){var t=this.getAxis(t),n=o[e],e=i[e]/2;return"category"===t.type?t.getBandWidth():Math.abs(t.dataToCoord(n-e)-t.dataToCoord(n+e))},this)}function qN(r,a){return a=a||[0,0],V([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 KN(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 $N(o,r){return r=r||[0,0],V(["Radius","Angle"],function(t,e){var n=this["get"+t+"Axis"](),i=r[e],e=o[e]/2,n="category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(i-e)-n.dataToCoord(i+e));return n="Angle"===t?n*Math.PI/180:n},this)}function JN(t,e,n,i){return t&&(t.legacy||!1!==t.legacy&&!n&&!i&&"tspan"!==e&&("text"===e||X(t,"text")))}function QN(t,e,n){var i,o,r,a=t;return"text"===e?i=a:(i={},X(a,"text")&&(i.text=a.text),X(a,"rich")&&(i.rich=a.rich),X(a,"textFill")&&(i.fill=a.textFill),X(a,"textStroke")&&(i.stroke=a.textStroke),X(a,"fontFamily")&&(i.fontFamily=a.fontFamily),X(a,"fontSize")&&(i.fontSize=a.fontSize),X(a,"fontStyle")&&(i.fontStyle=a.fontStyle),X(a,"fontWeight")&&(i.fontWeight=a.fontWeight),o={type:"text",style:i,silent:!0},r={},e=X(a,"textPosition"),n?r.position=e?a.textPosition:"inside":e&&(r.position=a.textPosition),X(a,"textPosition")&&(r.position=a.textPosition),X(a,"textOffset")&&(r.offset=a.textOffset),X(a,"textRotation")&&(r.rotation=a.textRotation),X(a,"textDistance")&&(r.distance=a.textDistance)),tR(i,t),nt(i.rich,function(t){tR(t,t)}),{textConfig:r,textContent:o}}function tR(t,e){e&&(e.font=e.textFont||e.font,X(e,"textStrokeWidth")&&(t.lineWidth=e.textStrokeWidth),X(e,"textAlign")&&(t.align=e.textAlign),X(e,"textVerticalAlign")&&(t.verticalAlign=e.textVerticalAlign),X(e,"textLineHeight")&&(t.lineHeight=e.textLineHeight),X(e,"textWidth")&&(t.width=e.textWidth),X(e,"textHeight")&&(t.height=e.textHeight),X(e,"textBackgroundColor")&&(t.backgroundColor=e.textBackgroundColor),X(e,"textPadding")&&(t.padding=e.textPadding),X(e,"textBorderColor")&&(t.borderColor=e.textBorderColor),X(e,"textBorderWidth")&&(t.borderWidth=e.textBorderWidth),X(e,"textBorderRadius")&&(t.borderRadius=e.textBorderRadius),X(e,"textBoxShadowColor")&&(t.shadowColor=e.textBoxShadowColor),X(e,"textBoxShadowBlur")&&(t.shadowBlur=e.textBoxShadowBlur),X(e,"textBoxShadowOffsetX")&&(t.shadowOffsetX=e.textBoxShadowOffsetX),X(e,"textBoxShadowOffsetY"))&&(t.shadowOffsetY=e.textBoxShadowOffsetY)}function eR(t,e,n){var i=t,o=(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),0<=i.textPosition.indexOf("inside")),r=t.fill||"#000",a=(nR(i,e),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,nt(e.rich,function(t){nR(t,t)}),i}function nR(t,e){e&&(X(e,"fill")&&(t.textFill=e.fill),X(e,"stroke")&&(t.textStroke=e.fill),X(e,"lineWidth")&&(t.textStrokeWidth=e.lineWidth),X(e,"font")&&(t.font=e.font),X(e,"fontStyle")&&(t.fontStyle=e.fontStyle),X(e,"fontWeight")&&(t.fontWeight=e.fontWeight),X(e,"fontSize")&&(t.fontSize=e.fontSize),X(e,"fontFamily")&&(t.fontFamily=e.fontFamily),X(e,"align")&&(t.textAlign=e.align),X(e,"verticalAlign")&&(t.textVerticalAlign=e.verticalAlign),X(e,"lineHeight")&&(t.textLineHeight=e.lineHeight),X(e,"width")&&(t.textWidth=e.width),X(e,"height")&&(t.textHeight=e.height),X(e,"backgroundColor")&&(t.textBackgroundColor=e.backgroundColor),X(e,"padding")&&(t.textPadding=e.padding),X(e,"borderColor")&&(t.textBorderColor=e.borderColor),X(e,"borderWidth")&&(t.textBorderWidth=e.borderWidth),X(e,"borderRadius")&&(t.textBorderRadius=e.borderRadius),X(e,"shadowColor")&&(t.textBoxShadowColor=e.shadowColor),X(e,"shadowBlur")&&(t.textBoxShadowBlur=e.shadowBlur),X(e,"shadowOffsetX")&&(t.textBoxShadowOffsetX=e.shadowOffsetX),X(e,"shadowOffsetY")&&(t.textBoxShadowOffsetY=e.shadowOffsetY),X(e,"textShadowColor")&&(t.textShadowColor=e.textShadowColor),X(e,"textShadowBlur")&&(t.textShadowBlur=e.textShadowBlur),X(e,"textShadowOffsetX")&&(t.textShadowOffsetX=e.textShadowOffsetX),X(e,"textShadowOffsetY"))&&(t.textShadowOffsetY=e.textShadowOffsetY)}var iR={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},oR=W(iR),rR=(ct(Uo,function(t,e){return t[e]=1,t},{}),Uo.join(", "),["","style","shape","extra"]),aR=i();function sR(t,e,n,i,o){var r=t+"Animation",i=vc(t,i,o)||{},o=aR(e).userDuring;return 0<i.duration&&(i.during=o?T(gR,{el:e,userDuring:o}):null,i.setToFinal=!0,i.scope=t),F(i,n[r]),i}function lR(t,n,e,i){for(var o,r=(i=i||{}).dataIndex,a=i.isInit,i=i.clearStyle,s=e.isAnimationEnabled(),l=aR(t),u=n.style,l=(l.userDuring=n.during,{}),h={},c=n,p=h,d=0;d<oR.length;d++){var g=oR[d],f=iR[g],g=c[g];g&&(p[f[0]]=g[0],p[f[1]]=g[1])}for(d=0;d<Uo.length;d++){var y=Uo[d];null!=c[y]&&(p[y]=c[y])}if(yR("shape",n,h),yR("extra",n,h),!a&&s){for(var E=t,m=n,z=l,v=cR(m=n.transition)?Uo:Jr(m||[]),x=0;x<v.length;x++){var _,b=v[x];"style"!==b&&"shape"!==b&&"extra"!==b&&(_=E[b],z[b]=_)}fR("shape",t,n,l),fR("extra",t,n,l);var m=t,w=n,S=u,M=l;if(S){var I,T=m.style;if(T){var C=S.transition,w=w.transition;if(C&&!cR(C)){var D=Jr(C);I=I||(M.style={});for(var A=0;A<D.length;A++){var k=D[A],L=T[k];I[k]=L}}else if(m.getAnimationStyleProps&&(cR(w)||cR(C)||0<=G(w,"style"))){var C=m.getAnimationStyleProps(),P=C?C.style:null;if(P){I=I||(M.style={});for(var O=W(S),A=0;A<O.length;A++){k=O[A];P[k]&&(L=T[k],I[k]=L)}}}}}}h.style=u;var N=t,w=h,m=i,C=w.style;if(!N.isGroup&&C){if(m){N.useStyle({});for(var V=N.animators,R=0;R<V.length;R++){var B=V[R];"style"===B.targetName&&B.changeTarget(N.style)}}N.setStyle(C)}w&&(w.style=null,w&&N.attr(w),w.style=C);M=t,S=n;X(S,"silent")&&(M.silent=S.silent),X(S,"ignore")&&(M.ignore=S.ignore),M instanceof ts&&X(S,"invisible")&&(M.invisible=S.invisible),M instanceof q&&X(S,"autoBatch")&&(M.autoBatch=S.autoBatch),s&&(a?(o={},nt(rR,function(t){var e=t?n[t]:n;e&&e.enterFrom&&(t&&(o[t]=o[t]||{}),F(t?o[t]:o,e.enterFrom))}),0<(h=sR("enter",t,n,e,r)).duration&&t.animateFrom(o,h)):(i=t,s=n,a=r||0,h=e,(r=l)&&0<(s=sR("update",i,s,h,a)).duration&&i.animateFrom(r,s))),uR(t,n),u?t.dirty():t.markRedraw()}function uR(t,e){for(var n=aR(t).leaveToProps,i=0;i<rR.length;i++){var o=rR[i],r=o?e[o]:e;r&&r.leaveTo&&(n=n||(aR(t).leaveToProps={}),o&&(n[o]=n[o]||{}),F(o?n[o]:n,r.leaveTo))}}function hR(t,e,n,i){var o,r;t&&(o=t.parent,(r=aR(t).leaveToProps)?((e=sR("update",t,e,n,0)).done=function(){o.remove(t),i&&i()},t.animateTo(r,e)):(o.remove(t),i&&i()))}function cR(t){return"all"===t}var pR={},dR={setTransform:function(t,e){return pR.el[t]=e,this},getTransform:function(t){return pR.el[t]},setShape:function(t,e){var n=pR.el;return(n.shape||(n.shape={}))[t]=e,n.dirtyShape&&n.dirtyShape(),this},getShape:function(t){var e=pR.el.shape;if(e)return e[t]},setStyle:function(t,e){var n=pR.el,i=n.style;return i&&(i[t]=e,n.dirtyStyle)&&n.dirtyStyle(),this},getStyle:function(t){var e=pR.el.style;if(e)return e[t]},setExtra:function(t,e){return(pR.el.extra||(pR.el.extra={}))[t]=e,this},getExtra:function(t){var e=pR.el.extra;if(e)return e[t]}};function gR(){var t,e=this.el;e&&(aR(e).userDuring!==(t=this.userDuring)?this.el=this.userDuring=null:(pR.el=e,t(dR)))}function fR(t,e,n,i){var o=n[t];if(o){var r,a,s=e[t];if(s){e=n.transition,n=o.transition;if(n)if(c=c||(i[t]={}),cR(n))F(c,s);else for(var l=Jr(n),u=0;u<l.length;u++){var h=s[d=l[u]];c[d]=h}else if(cR(e)||0<=G(e,t))for(var c=c||(i[t]={}),p=W(s),u=0;u<p.length;u++){var d,h=s[d=p[u]];r=o[d],a=h,(ht(r)?r!==a:null!=r&&isFinite(r))&&(c[d]=h)}}}}function yR(t,e,n){var i=e[t];if(i)for(var o=n[t]={},r=W(i),a=0;a<r.length;a++){var s=r[a];o[s]=eo(i[s])}}var mR=i(),vR=["percent","easing","shape","style","extra"];function xR(t){t.stopAnimation("keyframe"),t.attr(mR(t))}function _R(l,u,e){var t,n,h,c;e.isAnimationEnabled()&&u&&(B(u)?nt(u,function(t){_R(l,t,e)}):(t=u.keyframes,h=u.duration,e&&null==h&&(n=vc("enter",e,0),h=n&&n.duration),t&&h&&(c=mR(l),nt(rR,function(a){var s;a&&!l[a]||(t.sort(function(t,e){return t.percent-e.percent}),nt(t,function(t){var e=l.animators,n=a?t[a]:t;if(n){var i=W(n);if((i=a?i:pt(i,function(t){return G(vR,t)<0})).length){s||((s=l.animate(a,u.loop,!0)).scope="keyframe");for(var o=0;o<e.length;o++)e[o]!==s&&e[o].targetName===s.targetName&&e[o].stopTracks(i);a&&(c[a]=c[a]||{});var r=a?c[a]:c;nt(i,function(t){r[t]=((a?l[a]:l)||{})[t]}),s.whenWithKeys(h*t.percent,n,i,t.easing)}}}),s&&s.delay(u.delay||0).duration(h).start(u.easing))}))))}var bR="emphasis",wR="normal",e="blur",$m="select",SR=[wR,bR,e,$m],MR={normal:["itemStyle"],emphasis:[bR,"itemStyle"],blur:[e,"itemStyle"],select:[$m,"itemStyle"]},IR={normal:["label"],emphasis:[bR,"label"],blur:[e,"label"],select:[$m,"label"]},TR=["x","y"],CR="e\0\0",DR={normal:{},emphasis:{},blur:{},select:{}},AR={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:T(jN,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:T(qN,e)}}},single: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:T(KN,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]),t=r.dataToAngle(t[1]),n=i.coordToPoint([e,t]);return n.push(e,t*Math.PI/180),n},size:T($N,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 kR(t){return t instanceof q}function LR(t){return t instanceof ts}u(NR,PR=em),NR.prototype.render=function(n,t,i,o){this._progressiveEls=null;var r=this._data,a=n.getData(),s=this.group,l=BR(n,a,t,i),t=(r||s.removeAll(),a.diff(r).add(function(t){FR(i,null,t,l(t,o),n,s,a)}).remove(function(t){t=r.getItemGraphicEl(t);t&&hR(t,XN(t).option,n)}).update(function(t,e){e=r.getItemGraphicEl(e);FR(i,e,t,l(t,o),n,s,a)}).execute(),n.get("clip",!0)?Eb(n.coordinateSystem,!1,n):null);t?s.setClipPath(t):s.removeClipPath(),this._data=a},NR.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll(),this._data=null},NR.prototype.incrementalRender=function(t,e,n,i,o){var r=e.getData(),a=BR(e,r,n,i),s=this._progressiveEls=[];function l(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}for(var u=t.start;u<t.end;u++){var h=FR(null,null,u,a(u,o),e,this.group,r);h&&(h.traverse(l),s.push(h))}},NR.prototype.eachRendered=function(t){Qc(this._progressiveEls||this.group,t)},NR.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},NR.type="custom";var PR,OR=NR;function NR(){var t=null!==PR&&PR.apply(this,arguments)||this;return t.type=NR.type,t}function RR(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=qR(n),i=Nc(o,null,i,n.layout||"center");XN(i).customPathData=o}else if("image"===e)i=new ll({}),XN(i).customImagePath=t.style.image;else if("text"===e)i=new K({});else if("group"===e)i=new Z;else{if("compoundPath"===e)throw new Error('"compoundPath" is not supported yet.');n=Oc(e);n||jr(""),i=new n}return XN(i).customGraphicType=e,i.name=t.name,i.z2EmphasisLift=1,i.z2SelectLift=1,i}function ER(t,e,n,i,o,r,a){xR(e);var s,l,o=o&&o.normal.cfg,o=(o&&e.setTextConfig(o),i&&null==i.transition&&(i.transition=TR),i&&i.style);o&&(l=void("text"===e.type&&(X(l=o,"textFill")&&(l.fill=l.textFill),X(l,"textStroke"))&&(l.stroke=l.textStroke)),s=kR(e)?o.decal:null,t&&s&&(s.dirty=!0,l=V0(s,t)),o.__decalPattern=l),LR(e)&&o&&(l=o.__decalPattern)&&(o.decal=l),lR(e,i,r,{dataIndex:n,isInit:a,clearStyle:!0}),_R(e,i.keyframeAnimation,r)}function zR(t,e,n,i,o){var r,e=e.isGroup?null:e,o=o&&o[t].cfg;e&&(r=e.ensureState(t),!1===i?(t=e.getState(t))&&(t.style=null):r.style=i||null,o&&(r.textConfig=o),lu(e))}function VR(t,e,n){if(!t.isGroup){var i=t,t=n.currentZ,n=n.currentZLevel,t=(i.z=t,i.zlevel=n,e.z2);null!=t&&(i.z2=t||0);for(var o,r,a,s,l=0;l<SR.length;l++)o=i,r=e,a=SR[l],s=void 0,null!=(r=(r=(s=a===wR)?r:YR(r,a))?r.z2:null)&&((s?o:o.ensureState(a)).z2=r||0)}}function BR(a,s,e,t){for(var i,o,l,n,r=a.get("renderItem"),u=a.coordinateSystem,h={},c=(u&&(h=u.prepareCustoms?u.prepareCustoms(u):AR[u.type](u)),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,n=n&&n.opacity,o=_(e,wR).getItemStyle(),n=(null!=i&&(o.fill=i),null!=n&&(o.opacity=n),{inheritColor:H(i)?i:"#000"}),i=b(e,wR),r=ap(i,null,n,!1,!0),e=(r.text=i.getShallow("show")?N(a.getFormattedLabel(e,wR),Wb(s,e)):null,sp(i,n,!1));return S(t,o),o=eR(o,r,e),t&&w(o,t),o.legacy=!0,o},ordinalRawValue:function(t,e){null==e&&(e=l),t=t||0;var n,i=s.getDimensionInfo(t);return i?(n=s.get(i.name,e),(i=i&&i.ordinalMeta)?i.categories[n]:n):0<=(i=s.getDimensionIndex(t))?s.getStore().get(i,e):void 0},styleEmphasis:function(t,e){var n=_(e=null==e?l:e,bR).getItemStyle(),i=b(e,bR),o=ap(i,null,null,!0,!0),e=(o.text=i.getShallow("show")?St(a.getFormattedLabel(e,bR),a.getFormattedLabel(e,wR),Wb(s,e)):null,sp(i,null,!0));return S(t,n),n=eR(n,o,e),t&&w(n,t),n.legacy=!0,n},visual:function(t,e){{var n;if(null==e&&(e=l),X(HN,t))return(n=s.getItemVisual(e,"style"))?n[HN[t]]:null}if(X(YN,t))return s.getItemVisual(e,t)},barLayout:function(t){if("cartesian2d"===u.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:ux+o},t));for(var r=gx(e),a=[],o=0;o<t.count;o++){var s=r.axis0[ux+o];s.offsetCenter=s.offset+s.width/2,a.push(s)}return a}}(z({axis:u.getBaseAxis()},t))},currentSeriesIndices:function(){return e.getCurrentSeriesIndices()},font:function(t){return pp(t,e)}},h.api||{})),p={context:{},seriesId:a.id,seriesName:a.name,seriesIndex:a.seriesIndex,coordSys:h.coordSys,dataInsideLength:s.count(),encode:(i=a.getData(),o={},nt(i.dimensions,function(t){var e,n=i.getDimensionInfo(t);n.isExtraCoord||(e=n.coordDim,(o[e]=o[e]||[])[n.coordDimIndex]=i.getDimensionIndex(t))}),o)},d={},g={},f={},y={},m=0;m<SR.length;m++){var v=SR[m];f[v]=a.getModel(MR[v]),y[v]=a.getModel(IR[v])}function x(t){return t===l?n=n||s.getItemModel(t):s.getItemModel(t)}function _(t,e){return s.hasItemOption?t===l?d[e]||(d[e]=x(t).getModel(MR[e])):x(t).getModel(MR[e]):f[e]}function b(t,e){return s.hasItemOption?t===l?g[e]||(g[e]=x(t).getModel(IR[e])):x(t).getModel(IR[e]):y[e]}return function(t,e){return l=t,n=null,d={},g={},r&&r(z({dataIndexInside:t,dataIndex:s.getRawIndex(t),actionType:e?e.type:null},p),c)};function w(t,e){for(var n in e)X(e,n)&&(t[n]=e[n])}function S(t,e){t&&(t.textFill&&(e.textFill=t.textFill),t.textPosition)&&(e.textPosition=t.textPosition)}}function FR(t,e,n,i,o,r,a){if(i)return(t=GR(t,e,n,i,o,r))&&a.setItemGraphicEl(n,t),t&&Mu(t,i.focus,i.blurScope,i.emphasisDisabled),t;r.remove(e)}function GR(t,e,n,i,o,r){var a=-1,s=e,l=(e&&WR(e,i,o)&&(a=G(r.childrenRef(),e),e=null),!e),u=e,s=(u?u.clearStates():(u=RR(i),s&&(e=s,(s=u).copyTransform(e),LR(s))&&LR(e)&&(s.setStyle(e.style),s.z=e.z,s.z2=e.z2,s.zlevel=e.zlevel,s.invisible=e.invisible,s.ignore=e.ignore,kR(s))&&kR(e)&&s.setShape(e.shape)),!1===i.morph?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),DR.normal.cfg=DR.normal.conOpt=DR.emphasis.cfg=DR.emphasis.conOpt=DR.blur.cfg=DR.blur.conOpt=DR.select.cfg=DR.select.conOpt=null,DR.isLegacy=!1,u),e=n,h=i,c=o,p=l,d=DR;if(!s.isGroup){HR(h,null,d),HR(h,bR,d);var g=d.normal.conOpt,h=d.emphasis.conOpt,f=d.blur.conOpt,y=d.select.conOpt;if(null!=g||null!=h||null!=y||null!=f){var m=s.getTextContent();if(!1===g)m&&s.removeTextContent();else{g=d.normal.conOpt=g||{type:"text"},m?m.clearStates():(m=RR(g),s.setTextContent(m)),ER(null,m,e,g,null,c,p);for(var h=g&&g.style,v=0;v<SR.length;v++){var x,_=SR[v];_!==wR&&(x=d[_].conOpt,zR(_,m,0,XR(g,x,_),null))}h?m.dirty():m.markRedraw()}}}y=u,f=n,s=i,e=o,c=l;!1===(s=s.clipPath)?y&&y.getClipPath()&&y.removeClipPath():s&&((p=(p=y.getClipPath())&&WR(p,s,e)?null:p)||(p=RR(s),y.setClipPath(p)),ER(null,p,f,s,null,e,c)),ER(t,u,n,i,DR,o,l),X(i,"info")&&(XN(u).info=i.info);for(var b=0;b<SR.length;b++){var w,S=SR[b];S!==wR&&(w=XR(i,YR(i,S),S),zR(S,u,0,w,DR))}if(VR(u,i,o),"group"===i.type){var M=t,I=u,T=n,C=o,D=(h=i).children,A=D?D.length:0,h="byName"===(p=h.$mergeChildren)||h.diffChildrenByName,p=!1===p;if(A||h||p)if(h){h={api:M,oldChildren:I.children()||[],newChildren:D||[],dataIndex:T,seriesModel:C,group:I};new i1(h.oldChildren,h.newChildren,UR,UR,h).add(ZR).update(ZR).remove(jR).execute()}else{p&&I.removeAll();for(var k=0;k<A;k++){var L=D[k],P=I.childAt(k);L?(null==L.ignore&&(L.ignore=!1),GR(M,P,T,L,C,I)):P.ignore=!0}for(var O=I.childCount()-1;k<=O;O--){var N=I.childAt(O);!function(t,e,n){e&&hR(e,XN(t).option,n)}(I,N,C)}}}return 0<=a?r.replaceAt(u,a):r.add(u),u}function WR(t,e,n){var t=XN(t),i=e.type,o=e.shape,e=e.style;return n.isUniversalTransitionEnabled()||null!=i&&i!==t.customGraphicType||"path"===i&&(n=o)&&(X(n,"pathData")||X(n,"d"))&&qR(o)!==t.customPathData||"image"===i&&X(e,"image")&&e.image!==t.customImagePath}function HR(t,e,n){var i=e?YR(t,e):t,o=e?XR(t,i,bR):t.style,r=t.type,i=i?i.textConfig:null,t=t.textContent,t=t?e?YR(t,e):t:null,o=(o&&(n.isLegacy||JN(o,r,!!i,!!t))&&(n.isLegacy=!0,o=QN(o,r,!e),!i&&o.textConfig&&(i=o.textConfig),!t)&&o.textContent&&(t=o.textContent),e||!t||(r=t).type||(r.type="text"),e?n[e]:n.normal);o.cfg=i,o.conOpt=t}function YR(t,e){return e?t?t[e]:null:t}function XR(t,e,n){e=e&&e.style;return e=null==e&&n===bR&&t?t.styleEmphasis:e}function UR(t,e){t=t&&t.name;return null!=t?t:CR+e}function ZR(t,e){var n=this.context,t=null!=t?n.newChildren[t]:null,e=null!=e?n.oldChildren[e]:null;GR(n.api,e,n.dataIndex,t,n.seriesModel,n.group)}function jR(t){var e=this.context,t=e.oldChildren[t];t&&hR(t,XN(t).option,e.seriesModel)}function qR(t){return t&&(t.pathData||t.d)}r(function(t){t.registerChartView(OR),t.registerSeriesModel(UN)}),r(KM);var KR=i(),$R=S,JR=T,n0=(QR.prototype.render=function(t,e,n,i){var o,r,a=e.get("value"),s=e.get("status");this._axisModel=t,this._axisPointerModel=e,this._api=n,!i&&this._lastValue===a&&this._lastStatus===s||(this._lastValue=a,this._lastStatus=s,i=this._group,o=this._handle,s&&"hide"!==s?(i&&i.show(),o&&o.show(),this.makeElOption(s={},a,t,e,n),(r=s.graphicKey)!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=r,r=this._moveAnimation=this.determineAnimation(t,e),i?(r=P(t5,e,r),this.updatePointerEl(i,s,r),this.updateLabelEl(i,s,r,e)):(i=this._group=new Z,this.createPointerEl(i,s,t,e),this.createLabelEl(i,s,t,e),n.getZr().add(i)),i5(i,e,!0),this._renderHandle(a)):(i&&i.hide(),o&&o.hide()))},QR.prototype.remove=function(t){this.clear(t)},QR.prototype.dispose=function(t){this.clear(t)},QR.prototype.determineAnimation=function(t,e){var n,i=e.get("animation"),o=t.axis,r="category"===o.type,e=e.get("snap");return!(!e&&!r)&&("auto"===i||null==i?(n=this.animationThreshold,r&&o.getBandWidth()>n||!!e&&(r=IM(t).seriesDataCount,e=o.getExtent(),Math.abs(e[0]-e[1])/r>n)):!0===i)},QR.prototype.makeElOption=function(t,e,n,i,o){},QR.prototype.createPointerEl=function(t,e,n,i){var o=e.pointer;o&&(o=KR(t).pointerEl=new tp[o.type]($R(e.pointer)),t.add(o))},QR.prototype.createLabelEl=function(t,e,n,i){e.label&&(e=KR(t).labelEl=new K($R(e.label)),t.add(e),e5(e,i))},QR.prototype.updatePointerEl=function(t,e,n){t=KR(t).pointerEl;t&&e.pointer&&(t.setStyle(e.pointer.style),n(t,{shape:e.pointer.shape}))},QR.prototype.updateLabelEl=function(t,e,n,i){t=KR(t).labelEl;t&&(t.setStyle(e.label.style),n(t,{x:e.label.x,y:e.label.y}),e5(t,i))},QR.prototype._renderHandle=function(t){var e,n,i,o,r,a;!this._dragging&&this.updateHandleTransform&&(e=this._axisPointerModel,n=this._api.getZr(),i=this._handle,o=e.getModel("handle"),a=e.get("status"),o.get("show")&&a&&"hide"!==a?(this._handle||(r=!0,i=this._handle=jc(o.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Le(t.event)},onmousedown:JR(this._onHandleDragMove,this,0,0),drift:JR(this._onHandleDragMove,this),ondragend:JR(this._onHandleDragEnd,this)}),n.add(i)),i5(i,e,!1),i.setStyle(o.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"])),B(a=o.get("size"))||(a=[a,a]),i.scaleX=a[0]/2,i.scaleY=a[1]/2,pm(this,"_doDispatchAxisPointer",o.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,r)):(i&&n.remove(i),this._handle=null))},QR.prototype._moveHandleToValue=function(t,e){t5(this._axisPointerModel,!e&&this._moveAnimation,this._handle,n5(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},QR.prototype._onHandleDragMove=function(t,e){var n=this._handle;n&&(this._dragging=!0,t=this.updateHandleTransform(n5(n),[t,e],this._axisModel,this._axisPointerModel),this._payloadInfo=t,n.stopAnimation(),n.attr(n5(t)),KR(n).lastProp=null,this._doDispatchAxisPointer())},QR.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}]}))},QR.prototype._onHandleDragEnd=function(){var t;this._dragging=!1,this._handle&&(t=this._axisPointerModel.get("value"),this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"}))},QR.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var t=t.getZr(),e=this._group,n=this._handle;t&&e&&(this._lastGraphicKey=null,e&&t.remove(e),n&&t.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),dm(this,"_doDispatchAxisPointer")},QR.prototype.doClear=function(){},QR.prototype.buildLabel=function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}},QR);function QR(){this._dragging=!1,this.animationThreshold=15}function t5(t,e,n,i){!function n(i,t){{var o;return O(i)&&O(t)?(o=!0,nt(t,function(t,e){o=o&&n(i[e],t)}),!!o):i===t}}(KR(n).lastProp,i)&&(KR(n).lastProp=i,e?C(n,i,t):(n.stopAnimation(),n.attr(i)))}function e5(t,e){t[e.get(["label","show"])?"show":"hide"]()}function n5(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function i5(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)})}function o5(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 r5(t,e,n,i,o){var r=a5(n.get("value"),e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get(["label","precision"]),formatter:n.get(["label","formatter"])}),n=n.getModel("label"),a=vd(n.get("padding")||0),s=n.getFont(),l=$o(r,s),u=o.position,h=l.width+a[1]+a[3],l=l.height+a[0]+a[2],c=o.align,c=("right"===c&&(u[0]-=h),"center"===c&&(u[0]-=h/2),o.verticalAlign),i=("bottom"===c&&(u[1]-=l),"middle"===c&&(u[1]-=l/2),o=u,c=h,h=l,i=(l=i).getWidth(),l=l.getHeight(),o[0]=Math.min(o[0]+c,i)-c,o[1]=Math.min(o[1]+h,l)-h,o[0]=Math.max(o[0],0),o[1]=Math.max(o[1],0),n.get("backgroundColor"));i&&"auto"!==i||(i=e.get(["axisLine","lineStyle","color"])),t.label={x:u[0],y:u[1],style:ap(n,{text:r,font:s,fill:n.getTextColor(),padding:a,backgroundColor:i}),z2:10}}function a5(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:Ux(e,{value:t}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]},nt(i,function(t){var e=n.getSeriesByIndex(t.seriesIndex),t=t.dataIndexInside,e=e&&e.getDataParams(t);e&&r.seriesData.push(e)}),H(o)?a=o.replace("{value}",a):D(o)&&(a=o(r))),a}function s5(t,e,n){var i=ze();return We(i,i,n.rotation),Ge(i,i,n.position),Wc([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function l5(t,e,n,i,o,r){var a=yM.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=o.get(["label","margin"]),r5(e,i,o,r,{position:s5(i.axis,t,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function u5(t,e,n){return{x1:t[n=n||0],y1:t[1-n],x2:e[n],y2:e[1-n]}}function h5(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}function c5(t,e,n,i,o,r){return{cx:t,cy:e,r0:n,r:i,startAngle:o,endAngle:r,clockwise:!0}}u(g5,p5=n0),g5.prototype.makeElOption=function(t,e,n,i,o){var r,a=n.axis,s=("angle"===a.dim&&(this.animationThreshold=Math.PI/18),a.polar),l=s.getOtherAxis(a).getExtent(),u=a.dataToCoord(e),h=i.get("type"),a=(h&&"none"!==h&&(r=o5(i),(h=y5[h](a,s,u,l)).style=r,t.graphicKey=h.type,t.pointer=h),i.get(["label","margin"]));r5(t,n,i,o,function(t,e,n,i){var o,r,a=e.axis,t=a.dataToCoord(t),s=(l=(l=n.getAngleAxis().getExtent()[0])/180*Math.PI,n.getRadiusAxis().getExtent());{var l;s="radius"===a.dim?(a=ze(),We(a,a,l),Ge(a,a,[n.cx,n.cy]),o=Wc([t,-i],a),a=e.getModel("axisLabel").get("rotate")||0,e=yM.innerTextLayout(l,a*Math.PI/180,-1),r=e.textAlign,e.textVerticalAlign):(l=s[1],o=n.coordToPoint([l+i,t]),a=n.cx,e=n.cy,r=Math.abs(o[0]-a)/l<.3?"center":o[0]>a?"left":"right",Math.abs(o[1]-e)/l<.3?"middle":o[1]>e?"top":"bottom")}return{position:o,align:r,verticalAlign:s}}(e,n,s,a))};var p5,d5=g5;function g5(){return null!==p5&&p5.apply(this,arguments)||this}var f5,y5={line:function(t,e,n,i){return"angle"===t.dim?{type:"Line",shape:u5(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:c5(e.cx,e.cy,i[0],i[1],(-n-o/2)*r,(o/2-n)*r)}:{type:"Sector",shape:c5(e.cx,e.cy,n-o/2,n+o/2,0,2*Math.PI)}}},m5=(u(v5,f5=n0),v5.prototype.makeElOption=function(t,e,n,i,o){var r,a=n.axis,s=a.grid,l=i.get("type"),u=x5(s,a).getOtherAxis(a).getGlobalExtent(),h=a.toGlobalCoord(a.dataToCoord(e,!0)),a=(l&&"none"!==l&&(r=o5(i),(l=_5[l](a,h,u)).style=r,t.graphicKey=l.type,t.pointer=l),rM(s.model,n));l5(e,t,a,n,i,o)},v5.prototype.getHandleTransform=function(t,e,n){var i=rM(e.axis.grid.model,e,{labelInside:!1}),n=(i.labelMargin=n.get(["handle","margin"]),s5(e.axis,t,i));return{x:n[0],y:n[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},v5.prototype.updateHandleTransform=function(t,e,n,i){var n=n.axis,o=n.grid,r=n.getGlobalExtent(!0),o=x5(o,n).getOtherAxis(n).getGlobalExtent(),n="x"===n.dim?0:1,a=[t.x,t.y],e=(a[n]+=e[n],a[n]=Math.min(r[1],a[n]),a[n]=Math.max(r[0],a[n]),(o[1]+o[0])/2),r=[e,e];r[n]=a[n];return{x:a[0],y:a[1],rotation:t.rotation,cursorPoint:r,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][n]}},v5);function v5(){return null!==f5&&f5.apply(this,arguments)||this}function x5(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var _5={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:u5([e,n[0]],[e,n[1]],b5(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),o=n[1]-n[0];return{type:"Rect",shape:h5([e-i/2,n[0]],[i,o],b5(t))}}};function b5(t){return"x"===t.dim?0:1}u(M5,w5=g),M5.type="axisPointer",M5.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}};var w5,S5=M5;function M5(){var t=null!==w5&&w5.apply(this,arguments)||this;return t.type=M5.type,t}var I5=i(),T5=nt;function C5(t,e,n){var i,c,p;function o(t,h){c.on(t,function(e){n=p;var n,i,o={dispatchAction:r,pendings:i={showTip:[],hideTip:[]}};function r(t){var e=i[t.type];e?e.push(t):(t.dispatchAction=r,n.dispatchAction(t))}T5(I5(c).records,function(t){t&&h(t,e,o.dispatchAction)});var t,a=o.pendings,s=p,l=a.showTip.length,u=a.hideTip.length;l?t=a.showTip[l-1]:u&&(t=a.hideTip[u-1]),t&&(t.dispatchAction=null,s.dispatchAction(t))})}w.node||(i=e.getZr(),I5(i).records||(I5(i).records={}),p=e,I5(c=i).initialized||(I5(c).initialized=!0,o("click",P(A5,"click")),o("mousemove",P(A5,"mousemove")),o("globalout",D5)),(I5(i).records[t]||(I5(i).records[t]={})).handler=n)}function D5(t,e,n){t.handler("leave",null,n)}function A5(t,e,n,i){e.handler(t,n,i)}function k5(t,e){w.node||(e=e.getZr(),(I5(e).records||{})[t]&&(I5(e).records[t]=null))}u(O5,L5=Ky),O5.prototype.render=function(t,e,n){var e=e.getComponent("tooltip"),i=t.get("triggerOn")||e&&e.get("triggerOn")||"mousemove|click";C5("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})})},O5.prototype.remove=function(t,e){k5("axisPointer",e)},O5.prototype.dispose=function(t,e){k5("axisPointer",e)},O5.type="axisPointer";var L5,P5=O5;function O5(){var t=null!==L5&&L5.apply(this,arguments)||this;return t.type=O5.type,t}function N5(t,e){var n,i,o,r,a=[],s=t.seriesIndex;return null==s||!(e=e.getSeriesByIndex(s))||null==(s=ua(n=e.getData(),t))||s<0||B(s)?{point:[]}:(i=n.getItemGraphicEl(s),o=e.coordinateSystem,e.getTooltipPosition?a=e.getTooltipPosition(s)||[]:o&&o.dataToPoint?a=t.isStacked?(e=o.getBaseAxis(),t=o.getOtherAxis(e).dim,e=e.dim,t="x"===t||"radius"===t?1:0,e=n.mapDimension(e),(r=[])[t]=n.get(e,s),r[1-t]=n.get(n.getCalculationInfo("stackResultDimension"),s),o.dataToPoint(r)||[]):o.dataToPoint(n.getValues(V(o.dimensions,function(t){return n.mapDimension(t)}),s))||[]:i&&((e=i.getBoundingRect().clone()).applyTransform(i.transform),a=[e.x+e.width/2,e.y+e.height/2]),{point:a,el:i})}var R5=i();function E5(t,e,n){var r,a,i,s,l,o,u,h,c,p,d,g,f,y,m=t.currTrigger,v=[t.x,t.y],x=t,_=t.dispatchAction||T(n.dispatchAction,n),b=e.getComponent("axisPointer").coordSysAxesInfo;if(b)return G5(v)&&(v=N5({seriesIndex:x.seriesIndex,dataIndex:x.dataIndex},e).point),r=G5(v),a=x.axesInfo,i=b.axesInfo,s="leave"===m||G5(v),l={},e={list:[],map:{}},u={showPointer:P(V5,o={}),showTooltip:P(B5,e)},nt(b.coordSysMap,function(t,e){var o=r||t.containPoint(v);nt(b.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}}(a,t);s||!o||a&&!i||null!=(i=null!=(i=i&&i.value)||r?i:n.pointToData(v))&&z5(t,i,u,!1,l)})}),h={},nt(i,function(n,t){var i=n.linkGroup;i&&!o[t]&&nt(i.axesInfo,function(t,e){var e=o[e];t!==n&&e&&(e=e.value,i.mapper&&(e=n.axis.scale.parse(i.mapper(e,F5(t),F5(n)))),h[n.key]=e)})}),nt(h,function(t,e){z5(i[e],t,u,!0,l)}),c=o,x=i,p=l.axesInfo=[],nt(x,function(t,e){var n=t.axisPointerModel.option,e=c[e];e?(t.useHandle||(n.status="show"),n.value=e.value,n.seriesDataIndices=(e.payloadBatch||[]).slice()):t.useHandle||(n.status="hide"),"show"===n.status&&p.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:n.value})}),m=e,x=t,e=_,G5(t=v)||!m.list.length?e({type:"hideTip"}):(_=((m.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{},e({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:x.tooltipOption,position:x.position,dataIndexInside:_.dataIndexInside,dataIndex:_.dataIndex,seriesIndex:_.seriesIndex,dataByCoordSys:m.list})),e=i,x=(t=n).getZr(),_="axisPointerLastHighlights",d=R5(x)[_]||{},g=R5(x)[_]={},nt(e,function(t,e){var n=t.axisPointerModel.option;"show"===n.status&&t.triggerEmphasis&&nt(n.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;g[e]=t})}),f=[],y=[],nt(d,function(t,e){g[e]||y.push(t)}),nt(g,function(t,e){d[e]||f.push(t)}),y.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:y}),f.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:f}),l}function z5(t,e,n,i,o){var r,a,s,l,u,h,c,p,d,g,f=t.axis;!f.scale.isBlank()&&f.containData(e)&&(t.involveSeries?(a=e,s=t.axis,l=s.dim,u=a,h=[],c=Number.MAX_VALUE,p=-1,nt(t.seriesModels,function(e,t){var n,i=e.getData().mapDimensionsAll(l);if(e.getAxisTooltipData)var o=e.getAxisTooltipData(i,a,s),r=o.dataIndices,o=o.nestestValue;else{if(!(r=e.getData().indicesOfNearest(i[0],a,"category"===s.type?.5:null)).length)return;o=e.getData().get(i[0],r[0])}null!=o&&isFinite(o)&&(i=a-o,(n=Math.abs(i))<=c)&&((n<c||0<=i&&p<0)&&(c=n,p=i,u=o,h.length=0),nt(r,function(t){h.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}),g=(r={payloadBatch:h,snapToValue:u}).snapToValue,(d=r.payloadBatch)[0]&&null==o.seriesIndex&&F(o,d[0]),!i&&t.snap&&f.containData(g)&&null!=g&&(e=g),n.showPointer(t,e,d),n.showTooltip(t,r,g)):n.showPointer(t,e))}function V5(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function B5(t,e,n,i){var o,r,n=n.payloadBatch,a=e.axis,s=a.model,l=e.axisPointerModel;e.triggerTooltip&&n.length&&(o=CM(e=e.coordSys.model),(r=t.map[o])||(r=t.map[o]={coordSysId:e.id,coordSysIndex:e.componentIndex,coordSysType:e.type,coordSysMainType:e.mainType,dataByAxis:[]},t.list.push(r)),r.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:n.slice()}))}function F5(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 G5(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function W5(t){kM.registerAxisPointerClass("CartesianAxisPointer",m5),t.registerComponentModel(S5),t.registerComponentView(P5),t.registerPreprocessor(function(t){var e;t&&(t.axisPointer&&0!==t.axisPointer.length||(t.axisPointer={}),e=t.axisPointer.link)&&!B(e)&&(t.axisPointer.link=[e])}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=SM(t,e)}),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},E5)}u(X5,H5=g),X5.prototype.findAxisModel=function(t){var e;return this.ecModel.eachComponent(t,function(t){t.getCoordSysModel()===this&&(e=t)},this),e},X5.type="polar",X5.dependencies=["radiusAxis","angleAxis"],X5.defaultOption={z:0,center:["50%","50%"],radius:"80%"};var H5,Y5=X5;function X5(){var t=null!==H5&&H5.apply(this,arguments)||this;return t.type=X5.type,t}u(Z5,U5=g),Z5.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",da).models[0]},Z5.type="polarAxis";var U5,Ia=Z5;function Z5(){return null!==U5&&U5.apply(this,arguments)||this}ut(Ia,$x);u(K5,j5=Ia),K5.type="angleAxis";var j5,q5=K5;function K5(){var t=null!==j5&&j5.apply(this,arguments)||this;return t.type=K5.type,t}u(Q5,$5=Ia),Q5.type="radiusAxis";var $5,J5=Q5;function Q5(){var t=null!==$5&&$5.apply(this,arguments)||this;return t.type=Q5.type,t}u(nE,tE=Ip),nE.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]};var tE,eE=nE;function nE(t,e){return tE.call(this,"radius",t,e)||this}eE.prototype.dataToRadius=Ip.prototype.dataToCoord,eE.prototype.radiusToData=Ip.prototype.coordToData;var iE,oE=i(),rE=(u(aE,iE=Ip),aE.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},aE.prototype.calculateCategoryInterval=function(){var t,e,n=this.getLabelModel(),i=this.scale,o=i.getExtent(),i=i.count();return o[1]-o[0]<1?0:(o=o[0],t=this.dataToCoord(o+1)-this.dataToCoord(o),t=Math.abs(t),o=$o(null==o?"":o+"",n.getFont(),"center","top"),n=Math.max(o.height,7)/t,isNaN(n)&&(n=1/0),o=Math.max(0,Math.floor(n)),n=(t=oE(this.model)).lastAutoInterval,e=t.lastTickCount,null!=n&&null!=e&&Math.abs(n-o)<=1&&Math.abs(e-i)<=1&&o<n?o=n:(t.lastTickCount=i,t.lastAutoInterval=o),o)},aE);function aE(t,e){return iE.call(this,"angle",t,e||[0,360])||this}rE.prototype.dataToAngle=Ip.prototype.dataToCoord,rE.prototype.angleToData=Ip.prototype.coordToData;var sE=["radius","angle"],lE=(uE.prototype.containPoint=function(t){t=this.pointToCoord(t);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},uE.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},uE.prototype.getAxis=function(t){return this["_"+t+"Axis"]},uE.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},uE.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},uE.prototype.getAngleAxis=function(){return this._angleAxis},uE.prototype.getRadiusAxis=function(){return this._radiusAxis},uE.prototype.getOtherAxis=function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},uE.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},uE.prototype.getTooltipAxes=function(t){t=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},uE.prototype.dataToPoint=function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},uE.prototype.pointToData=function(t,e){t=this.pointToCoord(t);return[this._radiusAxis.radiusToData(t[0],e),this._angleAxis.angleToData(t[1],e)]},uE.prototype.pointToCoord=function(t){for(var e=t[0]-this.cx,t=t[1]-this.cy,n=this.getAngleAxis(),i=n.getExtent(),o=Math.min(i[0],i[1]),r=Math.max(i[0],i[1]),i=(n.inverse?o=r-360:r=o+360,Math.sqrt(e*e+t*t)),a=(e/=i,t/=i,Math.atan2(-t,e)/Math.PI*180),s=a<o?1:-1;a<o||r<a;)a+=360*s;return[i,a]},uE.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]},uE.prototype.getArea=function(){var t=this.getAngleAxis(),e=this.getRadiusAxis().getExtent().slice(),n=(e[0]>e[1]&&e.reverse(),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 t=t-this.cx,e=e-this.cy,t=t*t+e*e-1e-4,e=this.r,n=this.r0;return t<=e*e&&n*n<=t}}},uE.prototype.convertToPixel=function(t,e,n){return hE(e)===this?this.dataToPoint(n):null},uE.prototype.convertFromPixel=function(t,e,n){return hE(e)===this?this.pointToData(n):null},uE);function uE(t){this.dimensions=sE,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new eE,this._angleAxis=new rE,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}function hE(t){var e=t.seriesModel,t=t.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function cE(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&&(nt(Kx(e=t.getData(),"radius"),function(t){r.scale.unionExtentFromData(e,t)}),nt(Kx(e,"angle"),function(t){o.scale.unionExtentFromData(e,t)}))}),Hx(o.scale,o.model),Hx(r.scale,r.model),"category"!==o.type||o.onBand||(t=o.getExtent(),n=360/o.scale.count(),o.inverse?t[1]+=n:t[1]-=n,o.setExtent(t[0],t[1]))}function pE(t,e){var n,i;t.type=e.get("type"),t.scale=Yx(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"),i=null!=(i=e.get("endAngle"))?i:n+(t.inverse?-360:360),t.setExtent(n,i)),(e.axis=t).model=e}var dE={dimensions:sE,create:function(t,s){var l=[];return t.eachComponent("polar",function(t,e){var n,e=new lE(e+""),i=(e.update=cE,e.getRadiusAxis()),o=e.getAngleAxis(),r=t.findAxisModel("radiusAxis"),a=t.findAxisModel("angleAxis");pE(i,r),pE(o,a),i=e,r=s,a=(o=t).get("center"),n=r.getWidth(),r=r.getHeight(),i.cx=j(a[0],n),i.cy=j(a[1],r),a=i.getRadiusAxis(),i=Math.min(n,r)/2,null==(n=o.get("radius"))?n=[0,"100%"]:B(n)||(n=[0,n]),r=[j(n[0],i),j(n[1],i)],a.inverse?a.setExtent(r[1],r[0]):a.setExtent(r[0],r[1]),l.push(e),(t.coordinateSystem=e).model=t}),t.eachSeries(function(t){var e;"polar"===t.get("coordinateSystem")&&(e=t.getReferringComponents("polar",da).models[0],t.coordinateSystem=e.coordinateSystem)}),l}},gE=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function fE(t,e,n){e[1]>e[0]&&(e=e.slice().reverse());var i=t.coordToPoint([e[0],n]),t=t.coordToPoint([e[1],n]);return{x1:i[0],y1:i[1],x2:t[0],y2:t[1]}}function yE(t){return t.getRadiusAxis().inverse?0:1}function mE(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()}u(_E,vE=kM),_E.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(),mE(s=V(n.getViewLabels(),function(t){t=S(t);var e=n.scale,e="ordinal"===e.type?e.getRawOrdinalNumber(t.tickValue):t.tickValue;return t.coord=n.dataToCoord(e),t})),mE(r),nt(gE,function(t){!e.get([t,"show"])||n.scale.isBlank()&&"axisLine"!==t||wE[t](this.group,e,i,r,a,o,s)},this))},_E.type="angleAxis";var vE,xE=_E;function _E(){var t=null!==vE&&vE.apply(this,arguments)||this;return t.type=_E.type,t.axisPointerClass="PolarAxisPointer",t}var bE,wE={axisLine:function(t,e,n,i,o,r){var e=e.getModel(["axisLine","lineStyle"]),a=n.getAngleAxis(),s=Math.PI/180,l=a.getExtent(),u=yE(n),h=u?0:1,c=360===Math.abs(l[1]-l[0])?"Circle":"Arc",c=0===r[h]?new tp[c]({shape:{cx:n.cx,cy:n.cy,r:r[u],startAngle:-l[0]*s,endAngle:-l[1]*s,clockwise:a.inverse},style:e.getLineStyle(),z2:1,silent:!0}):new Th({shape:{cx:n.cx,cy:n.cy,r:r[u],r0:r[h]},style:e.getLineStyle(),z2:1,silent:!0});c.style.fill=null,t.add(c)},axisTick:function(t,e,n,i,o,r){var a=e.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=r[yE(n)],r=V(i,function(t){return new Fh({shape:fE(n,[l,l+s],t.coord)})});t.add(zc(r,{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[yE(n)],h=[],c=0;c<o.length;c++)for(var p=0;p<o[c].length;p++)h.push(new Fh({shape:fE(n,[u,u+l],o[c][p].coord)}));t.add(zc(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"),g=d.get("margin"),f=u.get("triggerEvent");nt(n,function(t,e){var n=d,i=t.tickValue,o=c[yE(h)],r=h.coordToPoint([o+g,t.coord]),a=h.cx,s=h.cy,a=Math.abs(r[0]-a)/o<.3?"center":r[0]>a?"left":"right",o=Math.abs(r[1]-s)/o<.3?"middle":r[1]>s?"top":"bottom",i=(p&&p[i]&&O(s=p[i])&&s.textStyle&&(n=new kp(s.textStyle,d,d.ecModel)),new K({silent:yM.isLabelSilent(u),style:ap(n,{x:r[0],y:r[1],fill:n.getTextColor()||u.get(["axisLine","lineStyle","color"]),text:t.formattedLabel,align:a,verticalAlign:o})}));l.add(i),f&&((s=yM.makeAxisEventDataBase(u)).targetType="axisLabel",s.value=t.rawLabel,$(i).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 Fh({shape:fE(n,r,i[h].coord)}))}for(h=0;h<u.length;h++)t.add(zc(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 Fh({shape:fE(n,r,o[l][u].coord)}));t.add(zc(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]),g=e.get("clockwise"),f=1,y=i.length;f<=y;f++){var m=(f===y?i[0]:i[f]).coord,v=s++%l.length;u[v]=u[v]||[],u[v].push(new wh({shape:{cx:n.cx,cy:n.cy,r0:p,r:d,startAngle:c,endAngle:-m*h,clockwise:g},silent:!0})),c=-m*h}for(f=0;f<u.length;f++)t.add(zc(u[f],{style:z({fill:l[f%l.length]},a.getAreaStyle()),silent:!0}))}}},SE=["axisLine","axisTickLabel","axisName"],ME=["splitLine","splitArea","minorSplitLine"],IE=(u(TE,bE=kM),TE.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 Z,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 yM(e,h),nt(SE,h.add,h),i.add(h.getGroup()),Xc(n,i,e),nt(ME,function(t){e.get([t,"show"])&&!o.scale.isBlank()&&CE[t](this.group,e,r,l,u,a,s)},this))},TE.type="radiusAxis",TE);function TE(){var t=null!==bE&&bE.apply(this,arguments)||this;return t.type=TE.type,t.axisPointerClass="PolarAxisPointer",t}var CE={splitLine:function(t,e,n,i,o,r){for(var a=e.getModel("splitLine").getModel("lineStyle"),s=a.get("color"),l=0,u=n.getAngleAxis(),h=Math.PI/180,c=u.getExtent(),p=360===Math.abs(c[1]-c[0])?"Circle":"Arc",s=s instanceof Array?s:[s],d=[],g=0;g<r.length;g++){var f=l++%s.length;d[f]=d[f]||[],d[f].push(new tp[p]({shape:{cx:n.cx,cy:n.cy,r:Math.max(r[g].coord,0),startAngle:-c[0]*h,endAngle:-c[1]*h,clockwise:u.inverse}}))}for(g=0;g<d.length;g++)t.add(zc(d[g],{style:z({stroke:s[g%s.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 eh({shape:{cx:n.cx,cy:n.cy,r:a[l][u].coord}}));t.add(zc(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 wh({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(zc(u[c],{style:z({fill:l[c%l.length]},a.getAreaStyle()),silent:!0}))}}};function DE(t){return t.get("stack")||"__ec_stack_"+t.seriesIndex}function AE(t,e){return e.dim+t.model.componentIndex}function kE(t,e,n){var i,l,c,k={},L=(i=pt(e.getSeriesByType(t),function(t){return!e.isSeriesFiltered(t)&&t.coordinateSystem&&"polar"===t.coordinateSystem.type}),l={},nt(i,function(t,e){var n=t.getData(),i=t.coordinateSystem,o=i.getBaseAxis(),i=AE(i,o),r=o.getExtent(),o="category"===o.type?o.getBandWidth():Math.abs(r[1]-r[0])/n.count(),r=l[i]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},n=r.stacks,i=(l[i]=r,DE(t)),a=(n[i]||r.autoWidthCount++,n[i]=n[i]||{width:0,maxWidth:0},j(t.get("barWidth"),o)),o=j(t.get("barMaxWidth"),o),s=t.get("barGap"),t=t.get("barCategoryGap");a&&!n[i].width&&(a=Math.min(r.remainedWidth,a),n[i].width=a,r.remainedWidth-=a),o&&(n[i].maxWidth=o),null!=s&&(r.gap=s),null!=t&&(r.categoryGap=t)}),c={},nt(l,function(t,n){c[n]={};var i,e=t.stacks,o=t.bandWidth,o=j(t.categoryGap,o),r=j(t.gap,1),a=t.remainedWidth,s=t.autoWidthCount,l=(a-o)/(s+(s-1)*r),l=Math.max(l,0),u=(nt(e,function(t,e){var n=t.maxWidth;n&&n<l&&(n=Math.min(n,a),t.width&&(n=Math.min(n,t.width)),a-=n,t.width=n,s--)}),l=(a-o)/(s+(s-1)*r),l=Math.max(l,0),0),h=(nt(e,function(t,e){t.width||(t.width=l),u+=(i=t).width*(1+r)}),i&&(u-=i.width*r),-u/2);nt(e,function(t,e){c[n][e]=c[n][e]||{offset:h,width:t.width},h+=t.width*(1+r)})}),c);e.eachSeriesByType(t,function(t){if("polar"===t.coordinateSystem.type)for(var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),o=AE(n,i),r=DE(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,d=(k[r]=k[r]||[],e.mapDimension(l.dim)),g=e.mapDimension(i.dim),f=E1(e,d),y="radius"!==i.dim||!t.get("roundCap",!0),m=l.dataToCoord(0),v=0,x=e.count();v<x;v++){var _,b,w=e.get(d,v),S=e.get(g,v),M=0<=w?"p":"n",I=m,T=(f&&(k[r][S]||(k[r][S]={p:m,n:m}),I=k[r][S][M]),void 0),C=void 0,D=void 0,A=void 0;"radius"===l.dim?(b=l.dataToCoord(w)-m,_=i.dataToCoord(S),C=(T=I)+(b=Math.abs(b)<c?(b<0?-1:1)*c:b),A=(D=_-a)-s,f&&(k[r][S][M]=C)):(b=l.dataToCoord(w,y)-m,C=(T=i.dataToCoord(S)+a)+s,A=(D=I)+(b=Math.abs(b)<p?(b<0?-1:1)*p:b),f&&(k[r][S][M]=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 LE,PE={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},OE={splitNumber:5},NE=(u(RE,LE=Ky),RE.type="polar",RE);function RE(){var t=null!==LE&&LE.apply(this,arguments)||this;return t.type=RE.type,t}function EE(t,e){e=e||{};var n=t.coordinateSystem,i=t.axis,o={},r=i.position,i=i.orient,n=n.getRect(),n=[n.x,n.x+n.width,n.y,n.y+n.height],a={horizontal:{top:n[2],bottom:n[3]},vertical:{left:n[0],right:n[1]}},a=(o.position=["vertical"===i?a.vertical[r]:n[0],"horizontal"===i?a.horizontal[r]:n[3]],o.rotation=Math.PI/2*{horizontal:0,vertical:1}[i],o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,right:1,left:-1}[r],t.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),wt(e.labelInside,t.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection),e.rotate);return null==a&&(a=t.get(["axisLabel","rotate"])),o.labelRotation="top"===r?-a:a,o.z2=1,o}r(function(t){r(W5),kM.registerAxisPointerClass("PolarAxisPointer",d5),t.registerCoordinateSystem("polar",dE),t.registerComponentModel(Y5),t.registerComponentView(NE),jS(t,"angle",q5,PE),jS(t,"radius",J5,OE),t.registerComponentView(xE),t.registerComponentView(IE),t.registerLayout(P(kE,"bar"))}),r(vA);var zE,VE=["axisLine","axisTickLabel","axisName"],BE=["splitArea","splitLine"],FE=(u(GE,zE=kM),GE.prototype.render=function(e,t,n,i){var o=this.group,r=(o.removeAll(),this._axisGroup),a=(this._axisGroup=new Z,EE(e)),a=new yM(e,a);nt(VE,a.add,a),o.add(this._axisGroup),o.add(a.getGroup()),nt(BE,function(t){e.get([t,"show"])&&HE[t](this,this.group,this._axisGroup,e)},this),Xc(r,this._axisGroup,e),zE.prototype.render.call(this,e,t,n,i)},GE.prototype.remove=function(){NM(this)},GE.type="singleAxis",GE);function GE(){var t=null!==zE&&zE.apply(this,arguments)||this;return t.type=GE.type,t.axisPointerClass="SingleAxisPointer",t}var WE,HE={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=a.get("width"),u=i.coordinateSystem.getRect(),h=o.isHorizontal(),c=[],p=0,d=o.getTicksCoords({tickModel:r}),g=[],f=[],y=0;y<d.length;++y){var m=o.toGlobalCoord(d[y].coord),m=(h?(g[0]=m,g[1]=u.y,f[0]=m,f[1]=u.y+u.height):(g[0]=u.x,g[1]=m,f[0]=u.x+u.width,f[1]=m),new Fh({shape:{x1:g[0],y1:g[1],x2:f[0],y2:f[1]},silent:!0})),v=(Bc(m.shape,l),p++%s.length);c[v]=c[v]||[],c[v].push(m)}for(var x=a.getLineStyle(["color"]),y=0;y<c.length;++y)e.add(zc(c[y],{style:z({stroke:s[y%s.length]},x),silent:!0}))}},splitArea:function(t,e,n,i){OM(t,n,i,i)}},YE=(u(XE,WE=g),XE.prototype.getCoordSysModel=function(){return this},XE.type="singleAxis",XE.layoutMode="box",XE.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}}},XE);function XE(){var t=null!==WE&&WE.apply(this,arguments)||this;return t.type=XE.type,t}ut(YE,$x.prototype);u(jE,UE=Ip),jE.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},jE.prototype.pointToData=function(t,e){return this.coordinateSystem.pointToData(t)[0]};var UE,ZE=jE;function jE(t,e,n,i,o){t=UE.call(this,t,e,n)||this;return t.type=i||"value",t.position=o||"bottom",t}var qE=["single"],KE=($E.prototype._init=function(t,e,n){var i=this.dimension,i=new ZE(i,Yx(t),[0,0],t.get("type"),t.get("position")),o="category"===i.type;i.onBand=o&&t.get("boundaryGap"),i.inverse=t.get("inverse"),i.orient=t.get("orient"),(t.axis=i).model=t,(i.coordinateSystem=this)._axis=i},$E.prototype.update=function(t,e){t.eachSeries(function(t){var e;t.coordinateSystem===this&&(nt((e=t.getData()).mapDimensionsAll(this.dimension),function(t){this._axis.scale.unionExtentFromData(e,t)},this),Hx(this._axis.scale,this._axis.model))},this)},$E.prototype.resize=function(t,e){this._rect=Ld({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()},$E.prototype.getRect=function(){return this._rect},$E.prototype._adjustAxis=function(){var t=this._rect,e=this._axis,n=e.isHorizontal(),i=n?[0,t.width]:[0,t.height],o=e.inverse?1:0;e.setExtent(i[o],i[1-o]),this._updateAxisTransform(e,n?t.x:t.y)},$E.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}},$E.prototype.getAxis=function(){return this._axis},$E.prototype.getBaseAxis=function(){return this._axis},$E.prototype.getAxes=function(){return[this._axis]},$E.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},$E.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},$E.prototype.pointToData=function(t){var e=this.getAxis();return[e.coordToData(e.toLocalCoord(t["horizontal"===e.orient?0:1]))]},$E.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},$E.prototype.convertToPixel=function(t,e,n){return JE(e)===this?this.dataToPoint(n):null},$E.prototype.convertFromPixel=function(t,e,n){return JE(e)===this?this.pointToData(n):null},$E);function $E(t,e,n){this.type="single",this.dimension="single",this.dimensions=qE,this.axisPointerEnabled=!0,this.model=t,this._init(t,e,n)}function JE(t){var e=t.seriesModel,t=t.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var QE,tz={create:function(i,o){var r=[];return i.eachComponent("singleAxis",function(t,e){var n=new KE(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",da).models[0],t.coordinateSystem=e&&e.coordinateSystem)}),r},dimensions:qE},ez=["x","y"],nz=["width","height"],iz=(u(oz,QE=n0),oz.prototype.makeElOption=function(t,e,n,i,o){var r,a=n.axis,s=a.coordinateSystem,l=sz(s,1-az(a)),s=s.dataToPoint(e)[0],u=i.get("type"),a=(u&&"none"!==u&&(r=o5(i),(u=rz[u](a,s,l)).style=r,t.graphicKey=u.type,t.pointer=u),EE(n));l5(e,t,a,n,i,o)},oz.prototype.getHandleTransform=function(t,e,n){var i=EE(e,{labelInside:!1}),n=(i.labelMargin=n.get(["handle","margin"]),s5(e.axis,t,i));return{x:n[0],y:n[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},oz.prototype.updateHandleTransform=function(t,e,n,i){var n=n.axis,o=n.coordinateSystem,n=az(n),r=sz(o,n),a=[t.x,t.y],e=(a[n]+=e[n],a[n]=Math.min(r[1],a[n]),a[n]=Math.max(r[0],a[n]),sz(o,1-n)),r=(e[1]+e[0])/2,o=[r,r];return o[n]=a[n],{x:a[0],y:a[1],rotation:t.rotation,cursorPoint:o,tooltipOption:{verticalAlign:"middle"}}},oz);function oz(){return null!==QE&&QE.apply(this,arguments)||this}var rz={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:u5([e,n[0]],[e,n[1]],az(t))}},shadow:function(t,e,n){var i=t.getBandWidth(),o=n[1]-n[0];return{type:"Rect",shape:h5([e-i/2,n[0]],[i,o],az(t))}}};function az(t){return t.isHorizontal()?0:1}function sz(t,e){t=t.getRect();return[t[ez[e]],t[ez[e]]+t[nz[e]]]}u(hz,lz=Ky),hz.type="single";var lz,uz=hz;function hz(){var t=null!==lz&&lz.apply(this,arguments)||this;return t.type=hz.type,t}r(function(t){r(W5),kM.registerAxisPointerClass("SingleAxisPointer",iz),t.registerComponentView(uz),t.registerComponentView(FE),t.registerComponentModel(YE),jS(t,"single",YE,YE.defaultOption),t.registerCoordinateSystem("single",tz)});u(dz,cz=g),dz.prototype.init=function(t,e,n){var i=Rd(t);cz.prototype.init.apply(this,arguments),gz(t,i)},dz.prototype.mergeOption=function(t){cz.prototype.mergeOption.apply(this,arguments),gz(this.option,t)},dz.prototype.getCellSize=function(){return this.option.cellSize},dz.type="calendar",dz.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}};var cz,pz=dz;function dz(){var t=null!==cz&&cz.apply(this,arguments)||this;return t.type=dz.type,t}function gz(t,i){var e=t.cellSize,o=B(e)?e:t.cellSize=[e,e],e=(1===o.length&&(o[1]=o[0]),V([0,1],function(t){var e,n;return(null!=(e=i)[Dd[n=t][0]]||null!=e[Dd[n][1]]&&null!=e[Dd[n][2]])&&(o[t]="auto"),null!=o[t]&&"auto"!==o[t]}));Nd(t,i,{type:"box",ignoreSize:e})}u(mz,fz=Ky),mz.prototype.render=function(t,e,n){var i=this.group,o=(i.removeAll(),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)},mz.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 L({shape:{x:l[0],y:l[1],width:r,height:a},cursor:"default",style:o});n.add(l)}},mz.prototype._renderLines=function(e,t,n,i){for(var o=this,r=e.coordinateSystem,a=e.getModel(["splitLine","lineStyle"]).getLineStyle(),s=e.get(["splitLine","show"]),l=a.lineWidth,u=(this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[],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)},mz.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},mz.prototype._drawSplitline=function(t,e,n){t=new Rh({z2:20,shape:{points:t},style:e});n.add(t)},mz.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},mz.prototype._formatterLabel=function(t,e){var n,i;return H(t)&&t?(n=t,nt(e,function(t,e){n=n.replace("{"+e+"}",i?we(t):t)}),n):D(t)?t(e):e.nameMap},mz.prototype._yearTextPositionControl=function(t,e,n,i,o){var r=e[0],e=e[1],a=["center","bottom"],o=("bottom"===i?(e+=o,a=["center","top"]):"left"===i?r-=o:"right"===i?(r+=o,a=["center","top"]):e-=o,0);return{rotation:o="left"!==i&&"right"!==i?o:Math.PI/2,x:r,y:e,style:{align:a[0],verticalAlign:a[1]}}},mz.prototype._renderYearText=function(t,e,n,i){var o,r,a,s,l,u,t=t.getModel("yearLabel");t.get("show")&&(o=t.get("margin"),r=(r=t.get("position"))||("horizontal"!==n?"top":"left"),a=((u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]])[0][0]+u[1][0])/2,l=(u[0][1]+u[1][1])/2,a={top:[a,u[s="horizontal"===n?0:1][1]],bottom:[a,u[1-s][1]],left:[u[1-s][0],l],right:[u[s][0],l]},u=e.start.y,+e.end.y>+e.start.y&&(u=u+"-"+e.end.y),s=t.get("formatter"),l={start:e.start.y,end:e.end.y,nameMap:u},e=this._formatterLabel(s,l),(u=new K({z2:30,style:ap(t,{text:e})})).attr(this._yearTextPositionControl(u,a[r],n,r,o)),i.add(u))},mz.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}},mz.prototype._renderMonthText=function(t,e,n,i){var o=t.getModel("monthLabel");if(o.get("show"))for(var r=o.get("nameMap"),a=o.get("margin"),s=o.get("position"),t=o.get("align"),l=[this._tlpoints,this._blpoints],u=(r&&!H(r)||(r=(e=r?Wp(r)||e:e).get(["time","monthAbbr"])||[]),"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(),g=this._firstDayOfMonth[p],f=(c&&(f=this._firstDayPoints[p],d[h]=(f[h]+l[0][p+1][h])/2),o.get("formatter")),y=r[+g.m-1],g={yyyy:g.y,yy:(g.y+"").slice(2),MM:g.m,M:+g.m,nameMap:y},y=this._formatterLabel(f,g),g=new K({z2:30,style:F(ap(o,{text:y}),this._monthTextPositionControl(d,c,n,s,a))});i.add(g)}},mz.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}},mz.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(),c=(l&&!H(l)||(l=(e=l?Wp(l)||e:e).get(["time","dayOfWeekShort"])||V(e.get(["time","dayOfWeekAbbr"]),function(t){return t[0]})),a.getNextNDay(n.end.time,7-n.lweek).time),p=[a.getCellWidth(),a.getCellHeight()],u=j(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 g=a.getNextNDay(c,d),g=a.dataToRect([g.time],!1).center,f=Math.abs((d+h)%7),f=new K({z2:30,style:F(ap(r,{text:l[f]}),this._weekTextPositionControl(g,i,s,u,p))});o.add(f)}}},mz.type="calendar";var fz,yz=mz;function mz(){var t=null!==fz&&fz.apply(this,arguments)||this;return t.type=mz.type,t}xz.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},xz.prototype.getRangeInfo=function(){return this._rangeInfo},xz.prototype.getModel=function(){return this._model},xz.prototype.getRect=function(){return this._rect},xz.prototype.getCellWidth=function(){return this._sw},xz.prototype.getCellHeight=function(){return this._sh},xz.prototype.getOrient=function(){return this._orient},xz.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},xz.prototype.getDateInfo=function(t){var e=(t=Vr(t)).getFullYear(),n=t.getMonth()+1,n=n<10?"0"+n:""+n,i=t.getDate(),i=i<10?"0"+i:""+i,o=t.getDay();return{y:e+"",m:n,d:i,day:Math.abs((o+7-this.getFirstDayOfWeek())%7),time:t.getTime(),formatedDate:e+"-"+n+"-"+i,date:t}},xz.prototype.getNextNDay=function(t,e){return 0!==(e=e||0)&&(t=new Date(this.getDateInfo(t).time)).setDate(t.getDate()+e),this.getDateInfo(t)},xz.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],n=(nt([0,1],function(t){l(o,t)&&(r[i[t]]=o[t]*a[t])}),{width:e.getWidth(),height:e.getHeight()}),s=this._rect=Ld(r,n);function l(t,e){return null!=t[e]&&"auto"!==t[e]}nt([0,1],function(t){l(o,t)||(o[t]=s[i[t]]/a[t])}),this._sw=o[0],this._sh=o[1]},xz.prototype.dataToPoint=function(t,e){B(t)&&(t=t[0]),null==e&&(e=!0);var t=this.getDateInfo(t),n=this._rangeInfo,i=t.formatedDate;return!e||t.time>=n.start.time&&t.time<n.end.time+864e5?(e=t.day,t=this._getRangeInfo([n.start.time,i]).nthWeek,"vertical"===this._orient?[this._rect.x+e*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+e*this._sh+this._sh/2]):[NaN,NaN]},xz.prototype.pointToData=function(t){t=this.pointToDate(t);return t&&t.time},xz.prototype.dataToRect=function(t,e){t=this.dataToPoint(t,e);return{contentShape:{x:t[0]-(this._sw-this._lineWidth)/2,y:t[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},center:t,tl:[t[0]-this._sw/2,t[1]-this._sh/2],tr:[t[0]+this._sw/2,t[1]-this._sh/2],br:[t[0]+this._sw/2,t[1]+this._sh/2],bl:[t[0]-this._sw/2,t[1]+this._sh/2]}},xz.prototype.pointToDate=function(t){var e=Math.floor((t[0]-this._rect.x)/this._sw)+1,t=Math.floor((t[1]-this._rect.y)/this._sh)+1,n=this._rangeInfo.range;return"vertical"===this._orient?this._getDateByWeeksAndDay(t,e-1,n):this._getDateByWeeksAndDay(e,t-1,n)},xz.prototype.convertToPixel=function(t,e,n){e=_z(e);return e===this?e.dataToPoint(n):null},xz.prototype.convertFromPixel=function(t,e,n){e=_z(e);return e===this?e.pointToData(n):null},xz.prototype.containPoint=function(t){return console.warn("Not implemented."),!1},xz.prototype._initRangeOption=function(){var t,e,n,i,o=this._model.get("range");return B(o)&&1===o.length&&(o=o[0]),B(o)?n=o:(t=o.toString(),/^\d{4}$/.test(t)&&(n=[t+"-01-01",t+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(t)&&((e=(i=this.getDateInfo(t)).date).setMonth(e.getMonth()+1),e=this.getNextNDay(e,-1),n=[i.formatedDate,e.formatedDate]),/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(t)&&(n=[t,t])),n?((i=this._getRangeInfo(n)).start.time>i.end.time&&n.reverse(),n):o},xz.prototype._getRangeInfo=function(t){var e,n,i=[this.getDateInfo(t[0]),this.getDateInfo(t[1])],o=(i[0].time>i[1].time&&(e=!0,i.reverse()),Math.floor(i[1].time/864e5)-Math.floor(i[0].time/864e5)+1),r=new Date(i[0].time),t=r.getDate(),a=i[1].date.getDate();if(r.setDate(t+o-1),r.getDate()!==a)for(var s=0<r.getTime()-i[1].time?1:-1;(n=r.getDate())!==a&&0<(r.getTime()-i[1].time)*s;)o-=s,r.setDate(n-s);var t=Math.floor((o+i[0].day+6)/7),l=e?1-t:t-1;return e&&i.reverse(),{range:[i[0].formatedDate,i[1].formatedDate],start:i[0],end:i[1],allDay:o,weeks:t,nthWeek:l,fweek:i[0].day,lweek:i[1].day}},xz.prototype._getDateByWeeksAndDay=function(t,e,n){n=this._getRangeInfo(n);return t>n.weeks||0===t&&e<n.fweek||t===n.weeks&&e>n.lweek?null:(t=7*(t-1)-n.fweek+e,(e=new Date(n.start.time)).setDate(+n.start.d+t),this.getDateInfo(e))},xz.create=function(t,e){var n=[];return t.eachComponent("calendar",function(t){var e=new xz(t);n.push(e),t.coordinateSystem=e}),t.eachSeries(function(t){"calendar"===t.get("coordinateSystem")&&(t.coordinateSystem=n[t.get("calendarIndex")||0])}),n},xz.dimensions=["time","value"];var vz=xz;function xz(t,e,n){this.type="calendar",this.dimensions=xz.dimensions,this.getDimensionsInfo=xz.getDimensionsInfo,this._model=t}function _z(t){var e=t.calendarModel,t=t.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem:null}r(function(t){t.registerComponentModel(pz),t.registerComponentView(yz),t.registerCoordinateSystem("calendar",vz)});u(Sz,bz=g),Sz.type="title",Sz.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}};var bz,wz=Sz;function Sz(){var t=null!==bz&&bz.apply(this,arguments)||this;return t.type=Sz.type,t.layoutMode={type:"box",ignoreSize:!0},t}u(Tz,Mz=Ky),Tz.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"),o=t.getModel("subtextStyle"),h=t.get("textAlign"),c=N(t.get("textBaseline"),t.get("textVerticalAlign")),s=(u=new K({style:ap(u,{text:t.get("text"),fill:u.getTextColor()},{disableBox:!0}),z2:10})).getBoundingRect(),l=t.get("subtext"),o=new K({style:ap(o,{text:l,fill:o.getTextColor(),y:s.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),r=t.get("link"),a=t.get("sublink"),s=t.get("triggerEvent",!0),u.silent=!r&&!s,o.silent=!a&&!s,r&&u.on("click",function(){Id(r,"_"+t.get("target"))}),a&&o.on("click",function(){Id(a,"_"+t.get("subtarget"))}),$(u).eventData=$(o).eventData=s?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(u),l&&i.add(o),s=i.getBoundingRect(),(l=t.getBoxLayoutParams()).width=s.width,l.height=s.height,l=Ld(l,{width:n.getWidth(),height:n.getHeight()},t.get("padding")),h||("right"===(h="middle"===(h=t.get("left")||t.get("right"))?"center":h)?l.x+=l.width:"center"===h&&(l.x+=l.width/2)),c||("bottom"===(c="center"===(c=t.get("top")||t.get("bottom"))?"middle":c)?l.y+=l.height:"middle"===c&&(l.y+=l.height/2),c=c||"top"),i.x=l.x,i.y=l.y,i.markRedraw(),u.setStyle(n={align:h,verticalAlign:c}),o.setStyle(n),s=i.getBoundingRect(),u=l.margin,(h=t.getItemStyle(["color","opacity"])).fill=t.get("backgroundColor"),c=new L({shape:{x:s.x-u[3],y:s.y-u[0],width:s.width+u[1]+u[3],height:s.height+u[0]+u[2],r:t.get("borderRadius")},style:h,subPixelOptimize:!0,silent:!0}),i.add(c))},Tz.type="title";var Mz,Iz=Tz;function Tz(){var t=null!==Mz&&Mz.apply(this,arguments)||this;return t.type=Tz.type,t}r(function(t){t.registerComponentModel(wz),t.registerComponentView(Iz)});u(Az,Cz=g),Az.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{},this._updateSelector(t)},Az.prototype.mergeOption=function(t,e){Cz.prototype.mergeOption.call(this,t,e),this._updateSelector(t)},Az.prototype._updateSelector=function(t){var n=t.selector,i=this.ecModel;B(n=!0===n?t.selector=["all","inverse"]:n)&&nt(n,function(t,e){H(t)&&(t={type:t}),n[e]=d(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))})},Az.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"))}},Az.prototype._updateData=function(i){var o=[],r=[],t=(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&&aa(t)&&o.push(t.name)}),this._availableNames=r,this.get("data")||o),e=R(),t=V(t,function(t){return(H(t)||Y(t))&&(t={name:t}),e.get(t.name)?null:(e.set(t.name,!0),new kp(t,this,this.ecModel))},this);this._data=pt(t,function(t){return!!t})},Az.prototype.getData=function(){return this._data},Az.prototype.select=function(t){var e=this.option.selected;"single"===this.get("selectedMode")&&nt(this._data,function(t){e[t.get("name")]=!1}),e[t]=!0},Az.prototype.unSelect=function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},Az.prototype.toggleSelected=function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},Az.prototype.allSelect=function(){var t=this._data,e=this.option.selected;nt(t,function(t){e[t.get("name",!0)]=!0})},Az.prototype.inverseSelect=function(){var t=this._data,e=this.option.selected;nt(t,function(t){t=t.get("name",!0);e.hasOwnProperty(t)||(e[t]=!0),e[t]=!e[t]})},Az.prototype.isSelected=function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&0<=G(this._availableNames,t)},Az.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},Az.type="legend.plain",Az.dependencies=["series"],Az.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}};var Cz,Dz=Az;function Az(){var t=null!==Cz&&Cz.apply(this,arguments)||this;return t.type=Az.type,t.layoutMode={type:"box",ignoreSize:!0},t}function kz(t,e){var n=vd(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new L({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})}var Lz,Pz=P,Oz=nt,Nz=Z,Rz=(u(Ez,Lz=Ky),Ez.prototype.init=function(){this.group.add(this._contentGroup=new Nz),this.group.add(this._selectorGroup=new Nz),this._isFirstRender=!0},Ez.prototype.getContentGroup=function(){return this._contentGroup},Ez.prototype.getSelectorGroup=function(){return this._selectorGroup},Ez.prototype.render=function(t,e,n){var i,o,r,a,s,l=this._isFirstRender;this._isFirstRender=!1,this.resetInner(),t.get("show",!0)&&(a=t.get("align"),r=t.get("orient"),a&&"auto"!==a||(a="right"===t.get("left")&&"vertical"===r?"right":"left"),i=t.get("selector",!0),o=t.get("selectorPosition",!0),this.renderInner(a,t,e,n,i,r,o=!i||o&&"auto"!==o?o:"horizontal"===r?"end":"start"),s=Ld(e=t.getBoxLayoutParams(),r={width:n.getWidth(),height:n.getHeight()},n=t.get("padding")),s=Ld(z({width:(a=this.layoutInner(t,a,s,l,i,o)).width,height:a.height},e),r,n),this.group.x=s.x-a.x,this.group.y=s.y-a.y,this.group.markRedraw(),this.group.add(this._backgroundEl=kz(a,t)))},Ez.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},Ez.prototype.renderInner=function(s,l,u,h,t,e,n){var c=this.getContentGroup(),p=R(),d=l.get("selectedMode"),g=[];u.eachRawSeries(function(t){t.get("legendHoverLink")||g.push(t.id)}),Oz(l.getData(),function(o,r){var e,t,n,i,a=o.get("name");this.newlineDisabled||""!==a&&"\n"!==a?(e=u.getSeriesByName(a)[0],p.get(a)||(e?(i=(n=e.getData()).getVisual("legendLineStyle")||{},t=n.getVisual("legendIcon"),n=n.getVisual("style"),(i=this._createItem(e,a,r,o,l,s,i,n,t,d,h)).on("click",Pz(zz,a,null,h,g)).on("mouseover",Pz(Bz,e.name,null,h,g)).on("mouseout",Pz(Fz,e.name,null,h,g)),u.ssr&&i.eachChild(function(t){t=$(t);t.seriesIndex=e.seriesIndex,t.dataIndex=r,t.ssrType="legend"}),p.set(a,!0)):u.eachRawSeries(function(e){var t,n,i;p.get(a)||e.legendVisualProvider&&(n=e.legendVisualProvider).containName(a)&&(i=n.indexOfName(a),t=n.getItemVisual(i,"style"),n=n.getItemVisual(i,"legendIcon"),(i=Si(t.fill))&&0===i[3]&&(i[3]=.2,t=F(F({},t),{fill:Li(i,"rgba")})),(i=this._createItem(e,a,r,o,l,s,{},t,n,d,h)).on("click",Pz(zz,null,a,h,g)).on("mouseover",Pz(Bz,null,a,h,g)).on("mouseout",Pz(Fz,null,a,h,g)),u.ssr&&i.eachChild(function(t){t=$(t);t.seriesIndex=e.seriesIndex,t.dataIndex=r,t.ssrType="legend"}),p.set(a,!0))},this))):((n=new Nz).newline=!0,c.add(n))},this),t&&this._createSelector(t,l,h,e,n)},Ez.prototype._createSelector=function(t,i,o,e,n){var r=this.getSelectorGroup();Oz(t,function(t){var e=t.type,n=new K({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){o.dispatchAction({type:"all"===e?"legendAllSelect":"legendInverseSelect"})}});r.add(n),op(n,{normal:i.getModel("selectorLabel"),emphasis:i.getModel(["emphasis","selectorLabel"])},{defaultText:t.title}),Su(n)})},Ez.prototype._createItem=function(t,e,n,i,o,r,a,s,l,u,h){var c=t.visualDrawType,p=o.get("itemWidth"),d=o.get("itemHeight"),g=o.isSelected(e),f=i.get("symbolRotate"),y=i.get("symbolKeepAspect"),m=i.get("icon"),a=function(t,e,n,i,o,r,a){function s(n,i){"auto"===n.lineWidth&&(n.lineWidth=0<i.lineWidth?2:0),Oz(n,function(t,e){"inherit"===n[e]&&(n[e]=i[e])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),t=0===t.lastIndexOf("empty",0)?"fill":"stroke",l=l.getShallow("decal");u.decal=l&&"inherit"!==l?V0(l,a):i.decal,"inherit"===u.fill&&(u.fill=i[o]);"inherit"===u.stroke&&(u.stroke=i[t]);"inherit"===u.opacity&&(u.opacity=("fill"===o?i:n).opacity);s(u,i);l=e.getModel("lineStyle"),a=l.getLineStyle();s(a,n),"auto"===u.fill&&(u.fill=i.fill),"auto"===u.stroke&&(u.stroke=i.fill),"auto"===a.stroke&&(a.stroke=i.fill),r||(o=e.get("inactiveBorderWidth"),n=u[t],u.lineWidth="auto"===o?0<i.lineWidth&&n?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),a.stroke=l.get("inactiveColor"),a.lineWidth=l.get("inactiveWidth"));return{itemStyle:u,lineStyle:a}}(l=m||l||"roundRect",i,a,s,c,g,h),s=new Nz,c=i.getModel("textStyle"),m=(!D(t.getLegendIcon)||m&&"inherit"!==m?(h="inherit"===m&&t.getData().getVisual("symbol")?"inherit"===f?t.getData().getVisual("symbolRotate"):f:0,s.add(function(t){var e=t.icon||"roundRect",n=s0(e,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill,t.symbolKeepAspect);n.setStyle(t.itemStyle),n.rotation=(t.iconRotate||0)*Math.PI/180,n.setOrigin([t.itemWidth/2,t.itemHeight/2]),-1<e.indexOf("empty")&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2);return n}({itemWidth:p,itemHeight:d,icon:l,iconRotate:h,itemStyle:a.itemStyle,lineStyle:a.lineStyle,symbolKeepAspect:y}))):s.add(t.getLegendIcon({itemWidth:p,itemHeight:d,icon:l,iconRotate:f,itemStyle:a.itemStyle,lineStyle:a.lineStyle,symbolKeepAspect:y})),"left"===r?p+5:-5),h=r,t=o.get("formatter"),l=e,f=(H(t)&&t?l=t.replace("{name}",null!=e?e:""):D(t)&&(l=t(e)),g?c.getTextColor():i.get("inactiveColor")),a=(s.add(new K({style:ap(c,{text:l,x:m,y:d/2,fill:f,align:h,verticalAlign:"middle"},{inheritColor:f})})),new L({shape:s.getBoundingRect(),style:{fill:"transparent"}})),y=i.getModel("tooltip");return y.get("show")&&$c({el:a,componentModel:o,itemName:e,itemTooltipOption:y.option}),s.add(a),s.eachChild(function(t){t.silent=!0}),a.silent=!u,this.getContentGroup().add(s),Su(s),s.__legendDataIndex=n,s},Ez.prototype.layoutInner=function(t,e,n,i,o,r){var a,s,l,u,h,c=this.getContentGroup(),p=this.getSelectorGroup(),n=(kd(t.get("orient"),c,t.get("itemGap"),n.width,n.height),c.getBoundingRect()),d=[-n.x,-n.y];return p.markRedraw(),c.markRedraw(),o?(kd("horizontal",p,t.get("selectorItemGap",!0)),a=[-(o=p.getBoundingRect()).x,-o.y],s=t.get("selectorButtonGap",!0),l=0===(t=t.getOrient().index)?"width":"height",u=0===t?"height":"width",h=0===t?"y":"x","end"===r?a[t]+=n[l]+s:d[t]+=o[l]+s,a[1-t]+=n[u]/2-o[u]/2,p.x=a[0],p.y=a[1],c.x=d[0],c.y=d[1],(r={x:0,y:0})[l]=n[l]+s+o[l],r[u]=Math.max(n[u],o[u]),r[h]=Math.min(0,o[h]+a[1-t]),r):(c.x=d[0],c.y=d[1],this.group.getBoundingRect())},Ez.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},Ez.type="legend.plain",Ez);function Ez(){var t=null!==Lz&&Lz.apply(this,arguments)||this;return t.type=Ez.type,t.newlineDisabled=!1,t}function zz(t,e,n,i){Fz(t,e,n,i),n.dispatchAction({type:"legendToggleSelect",name:null!=t?t:e}),Bz(t,e,n,i)}function Vz(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 Bz(t,e,n,i){Vz(n)||n.dispatchAction({type:"highlight",seriesName:t,name:e,excludeSeriesId:i})}function Fz(t,e,n,i){Vz(n)||n.dispatchAction({type:"downplay",seriesName:t,name:e,excludeSeriesId:i})}function Gz(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 Wz(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)),nt(n.getData(),function(t){var e,t=t.get("name");"\n"!==t&&""!==t&&(e=n.isSelected(t),o.hasOwnProperty(t)?o[t]=o[t]&&e:o[t]=e)})}),"allSelect"===t||"inverseSelect"===t?{selected:o}:{name:e.name,selected:o}}function Hz(t){t.registerComponentModel(Dz),t.registerComponentView(Rz),t.registerProcessor(t.PRIORITY.PROCESSOR.SERIES_FILTER,Gz),t.registerSubTypeDefaulter("legend",function(){return"plain"}),(t=t).registerAction("legendToggleSelect","legendselectchanged",P(Wz,"toggleSelected")),t.registerAction("legendAllSelect","legendselectall",P(Wz,"allSelect")),t.registerAction("legendInverseSelect","legendinverseselect",P(Wz,"inverseSelect")),t.registerAction("legendSelect","legendselected",P(Wz,"select")),t.registerAction("legendUnSelect","legendunselected",P(Wz,"unSelect"))}u(Uz,Yz=Dz),Uz.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},Uz.prototype.init=function(t,e,n){var i=Rd(t);Yz.prototype.init.call(this,t,e,n),Zz(this,t,i)},Uz.prototype.mergeOption=function(t,e){Yz.prototype.mergeOption.call(this,t,e),Zz(this,this.option,t)},Uz.type="legend.scroll",Uz.defaultOption=Np(Dz.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});var Yz,Xz=Uz;function Uz(){var t=null!==Yz&&Yz.apply(this,arguments)||this;return t.type=Uz.type,t}function Zz(t,e,n){var i=[1,1];i[t.getOrient().index]=0,Nd(e,n,{type:"box",ignoreSize:!!i})}var jz,qz=Z,Kz=["width","height"],$z=["x","y"],Jz=(u(Qz,jz=Rz),Qz.prototype.init=function(){jz.prototype.init.call(this),this.group.add(this._containerGroup=new qz),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new qz)},Qz.prototype.resetInner=function(){jz.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},Qz.prototype.renderInner=function(t,i,e,o,n,r,a){var s=this,l=(jz.prototype.renderInner.call(this,t,i,e,o,n,r,a),this._controllerGroup),t=i.get("pageIconSize",!0),u=B(t)?t:[t,t],e=(h("pagePrev",0),i.getModel("pageTextStyle"));function h(t,e){var n=t+"DataIndex",e=jc(i.get("pageIcons",!0)[i.getOrient().name][e],{onclick:T(s._pageGo,s,n,i,o)},{x:-u[0]/2,y:-u[1]/2,width:u[0],height:u[1]});e.name=t,l.add(e)}l.add(new K({name:"pageText",style:{text:"xx/xx",fill:e.getTextColor(),font:e.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),h("pageNext",1)},Qz.prototype.layoutInner=function(t,e,n,i,o,r){var a=this.getSelectorGroup(),s=t.getOrient().index,l=Kz[s],u=$z[s],h=Kz[1-s],c=$z[1-s],p=(o&&kd("horizontal",a,t.get("selectorItemGap",!0)),t.get("selectorButtonGap",!0)),d=a.getBoundingRect(),g=[-d.x,-d.y],f=S(n),n=(o&&(f[l]=n[l]-d[l]-p),this._layoutContentAndController(t,i,f,s,l,h,c,u));return o&&("end"===r?g[s]+=n[l]+p:(t=d[l]+p,g[s]-=t,n[u]-=t),n[l]+=d[l]+p,g[1-s]+=n[c]+n[h]/2-d[h]/2,n[h]=Math.max(n[h],d[h]),n[c]=Math.min(n[c],d[c]+g[1-s]),a.x=g[0],a.y=g[1],a.markRedraw()),n},Qz.prototype._layoutContentAndController=function(t,e,n,i,o,r,a,s){var l=this.getContentGroup(),u=this._containerGroup,h=this._controllerGroup,c=(kd(t.get("orient"),l,t.get("itemGap"),i?n.width:null,i?null:n.height),kd("horizontal",h,t.get("pageButtonItemGap",!0)),l.getBoundingRect()),p=h.getBoundingRect(),d=this._showController=c[o]>n[o],g=[-c.x,-c.y],e=(e||(g[i]=l[s]),[0,0]),s=[-p.x,-p.y],f=N(t.get("pageButtonGap",!0),t.get("itemGap",!0)),g=(d&&("end"===t.get("pageButtonPosition",!0)?s[i]+=n[o]-p[o]:e[i]+=p[o]+f),s[1-i]+=c[r]/2-p[r]/2,l.setPosition(g),u.setPosition(e),h.setPosition(s),{x:0,y:0}),c=(g[o]=(d?n:c)[o],g[r]=Math.max(c[r],p[r]),g[a]=Math.min(0,p[a]+s[1-i]),u.__rectSize=n[o],d?((e={x:0,y:0})[o]=Math.max(n[o]-p[o]-f,0),e[r]=g[r],u.setClipPath(new L({shape:e})),u.__rectSize=e[o]):h.eachChild(function(t){t.attr({invisible:!0,silent:!0})}),this._getPageInfo(t));return null!=c.pageIndex&&C(l,{x:c.contentPosition[0],y:c.contentPosition[1]},d?t:null),this._updatePageInfoView(t,c),g},Qz.prototype._pageGo=function(t,e,n){t=this._getPageInfo(e)[t];null!=t&&n.dispatchAction({type:"legendScroll",scrollDataIndex:t,legendId:e.id})},Qz.prototype._updatePageInfoView=function(n,i){var o=this._controllerGroup,t=(nt(["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")}),o.childOfName("pageText")),e=n.get("pageFormatter"),r=i.pageIndex,r=null!=r?r+1:0,a=i.pageCount;t&&e&&t.setStyle("text",H(e)?e.replace("{current}",null==r?"":r+"").replace("{total}",null==a?"":a+""):e({current:r,total:a}))},Qz.prototype._getPageInfo=function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,t=t.getOrient().index,o=Kz[t],r=$z[t],e=this._findTargetItemIndex(e),a=n.children(),s=a[e],l=a.length,u=l?1:0,h={contentPosition:[n.x,n.y],pageCount:u,pageIndex:u-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(s){n=f(s);h.contentPosition[t]=-n.s;for(var c=e+1,p=n,d=n,g=null;c<=l;++c)(!(g=f(a[c]))&&d.e>p.s+i||g&&!y(g,p.s))&&(p=d.i>p.i?d:g)&&(null==h.pageNextDataIndex&&(h.pageNextDataIndex=p.i),++h.pageCount),d=g;for(c=e-1,p=n,d=n,g=null;-1<=c;--c)(g=f(a[c]))&&y(d,g.s)||!(p.i<d.i)||(d=p,null==h.pagePrevDataIndex&&(h.pagePrevDataIndex=p.i),++h.pageCount,++h.pageIndex),p=g}return h;function f(t){var e,n;if(t)return{s:n=(e=t.getBoundingRect())[r]+t[r],e:n+e[o],i:t.__legendDataIndex}}function y(t,e){return t.e>=e&&t.s<=e+i}},Qz.prototype._findTargetItemIndex=function(n){var i,o;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},Qz.type="legend.scroll",Qz);function Qz(){var t=null!==jz&&jz.apply(this,arguments)||this;return t.type=Qz.type,t.newlineDisabled=!0,t._currentIndex=0,t}r(function(t){r(Hz),t.registerComponentModel(Xz),t.registerComponentView(Jz),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)})})});u(nV,tV=g),nV.type="tooltip",nV.dependencies=["axisPointer"],nV.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}};var tV,eV=nV;function nV(){var t=null!==tV&&tV.apply(this,arguments)||this;return t.type=nV.type,t}function iV(t){var e=t.get("confine");return null!=e?e:"richText"===t.get("renderMode")}function oV(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 rV=oV(["transform","webkitTransform","OTransform","MozTransform","msTransform"]);function aV(t,e){if(!t)return e;e=md(e,!0);var n=t.indexOf(e);return(t=-1===n?e:"-"+t.slice(0,n)+"-"+e).toLowerCase()}var sV=aV(oV(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),"transition"),lV=aV(rV,"transform"),uV="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(w.transform3dSupported?"will-change:transform;":"");function hV(t,e,n){var i,t=t.toFixed(0)+"px",e=e.toFixed(0)+"px";return w.transformSupported?(i="translate"+((i=w.transform3dSupported)?"3d":"")+"("+t+","+e+(i?",0":"")+")",n?"top:0;left:0;"+lV+":"+i+";":[["top",0],["left",0],[rV,i]]):n?"top:"+e+";left:"+t+";":[["top",e],["left",t]]}function cV(i,t,e){var n,o,r=[],a=i.get("transitionDuration"),s=i.get("backgroundColor"),l=i.get("shadowBlur"),u=i.get("shadowColor"),h=i.get("shadowOffsetX"),c=i.get("shadowOffsetY"),p=i.getModel("textStyle"),d=Ny(i,"html");return r.push("box-shadow:"+(h+"px "+c+"px "+l+"px "+u)),t&&a&&r.push((u="opacity"+(l=" "+(h=a)/2+"s "+(c="cubic-bezier(0.23,1,0.32,1)"))+",visibility"+l,e||(l=" "+h+"s "+c,u+=w.transformSupported?","+lV+l:",left"+l+",top"+l),sV+":"+u)),s&&r.push("background-color:"+s),nt(["width","color","radius"],function(t){var e="border-"+t,n=md(e),n=i.get(n);null!=n&&r.push(e+":"+n+("color"===t?"":"px"))}),r.push((o=[],t=(n=p).get("fontSize"),(a=n.getTextColor())&&o.push("color:"+a),o.push("font:"+n.getFont()),t&&o.push("line-height:"+Math.round(3*t/2)+"px"),a=n.get("textShadowColor"),t=n.get("textShadowBlur")||0,e=n.get("textShadowOffsetX")||0,h=n.get("textShadowOffsetY")||0,a&&t&&o.push("text-shadow:"+e+"px "+h+"px "+t+"px "+a),nt(["decoration","align"],function(t){var e=n.get(t);e&&o.push("text-"+t+":"+e)}),o.join(";"))),null!=d&&r.push("padding:"+vd(d).join("px ")+"px"),r.join(";")+";"}function pV(t,e,n,i,o){var r,a,s=e&&e.painter;n?(r=s&&s.getViewportRoot())&&(a=t,n=n,ve(me,r,i,o,!0))&&ve(a,n,me[0],me[1]):(t[0]=i,t[1]=o,(r=s&&s.getViewportRootOffset())&&(t[0]+=r.offsetLeft,t[1]+=r.offsetTop)),t[2]=t[0]/e.getWidth(),t[3]=t[1]/e.getHeight()}gV.prototype.update=function(t){this._container||(i=this._api.getDom(),n="position",n=(e=(e=i).currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e))?n?e[n]:e:null,"absolute"!==(e=i.style).position&&"absolute"!==n&&(e.position="relative"));var e,n,i=t.get("alwaysShowContent");i&&this._moveIfResized(),this._alwaysShowContent=i,this.el.className=t.get("className")||""},gV.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=uV+cV(t,!this._firstShow,this._longHide)+hV(o[0],o[1],!0)+"border-color:"+Md(e)+";"+(t.get("extraCssText")||"")+";pointer-events:"+(this._enterable?"auto":"none"):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},gV.prototype.setContent=function(t,e,n,i,o){var r=this.el;if(null==t)r.innerHTML="";else{var a,s,l,u,h,c="";if(H(o)&&"item"===n.get("trigger")&&!iV(n)&&(n=n,i=i,c=H(o=o)&&"inside"!==o?(a=n.get("backgroundColor"),n=n.get("borderWidth"),i=Md(i),o=o="left"===(o=o)?"right":"right"===o?"left":"top"===o?"bottom":"top",p=Math.max(1.5*Math.round(n),6),s="",l=lV+":",-1<G(["left","right"],o)?(s+="top:50%",l+="translateY(-50%) rotate("+(h="left"==o?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(h="top"==o?225:45)+"deg)"),h=h*Math.PI/180,h=(u=p+n)*Math.abs(Math.cos(h))+u*Math.abs(Math.sin(h)),i=i+" solid "+n+"px;",'<div style="'+["position:absolute;width:"+p+"px;height:"+p+"px;z-index:-1;",(s+=";"+o+":-"+Math.round(100*((h-Math.SQRT2*n)/2+Math.SQRT2*n-(h-u)/2))/100+"px")+";"+l+";","border-bottom:"+i,"border-right:"+i,"background-color:"+a+";"].join("")+'"></div>'):""),H(t))r.innerHTML=t+c;else if(t){r.innerHTML="",B(t)||(t=[t]);for(var p,d=0;d<t.length;d++)mt(t[d])&&t[d].parentNode!==r&&r.appendChild(t[d]);c&&r.childNodes.length&&((p=document.createElement("div")).innerHTML=c,r.appendChild(p))}}},gV.prototype.setEnterable=function(t){this._enterable=t},gV.prototype.getSize=function(){var t=this.el;return[t.offsetWidth,t.offsetHeight]},gV.prototype.moveTo=function(t,e){var n,i=this._styleCoord;pV(i,this._zr,this._container,t,e),null!=i[0]&&null!=i[1]&&(n=this.el.style,nt(hV(i[0],i[1]),function(t){n[t[0]]=t[1]}))},gV.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},gV.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)},gV.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(T(this.hide,this),t)):this.hide())},gV.prototype.isShow=function(){return this._show},gV.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var t=this.el.parentNode;t&&t.removeChild(this.el),this.el=this._container=null};var dV=gV;function gV(t,e){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,w.wxa)return null;var n=document.createElement("div"),i=(n.domBelongToZr=!0,this.el=n,this._zr=t.getZr()),e=e.appendTo,e=e&&(H(e)?document.querySelector(e):mt(e)?e:D(e)&&e(t.getDom())),o=(pV(this._styleCoord,i,e,t.getWidth()/2,t.getHeight()/2),(e||t.getDom()).appendChild(n),this._api=t,this._container=e,this);n.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},n.onmousemove=function(t){var e;t=t||window.event,o._enterable||(e=i.handler,Ae(i.painter.getViewportRoot(),t,!0),e.dispatch("mousemove",t))},n.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}yV.prototype.update=function(t){t=t.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},yV.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},yV.prototype.setContent=function(t,e,n,i,o){var r=this,a=(O(t)&&jr(""),this.el&&this._zr.remove(this.el),n.getModel("textStyle")),s=(this.el=new K({style:{rich:e.richTextStyles,text:t,lineHeight:22,borderWidth:1,borderColor:i,textShadowColor:a.get("textShadowColor"),fill:n.get(["textStyle","color"]),padding:Ny(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),nt(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(t){r.el.style[t]=n.get(t)}),nt(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(t){r.el.style[t]=a.get(t)||0}),this._zr.add(this.el),this);this.el.on("mouseover",function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0}),this.el.on("mouseout",function(){s._enterable&&s._show&&s.hideLater(s._hideDelay),s._inContent=!1})},yV.prototype.setEnterable=function(t){this._enterable=t},yV.prototype.getSize=function(){var t=this.el,e=this.el.getBoundingRect(),t=vV(t.style);return[e.width+t.left+t.right,e.height+t.top+t.bottom]},yV.prototype.moveTo=function(t,e){var n,i,o=this.el;o&&(xV(i=this._styleCoord,this._zr,t,e),t=i[0],e=i[1],n=mV((i=o.style).borderWidth||0),i=vV(i),o.x=t+n+i.left,o.y=e+n+i.top,o.markRedraw())},yV.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},yV.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},yV.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(T(this.hide,this),t)):this.hide())},yV.prototype.isShow=function(){return this._show},yV.prototype.dispose=function(){this._zr.remove(this.el)};var fV=yV;function yV(t){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=t.getZr(),xV(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}function mV(t){return Math.max(0,t)}function vV(t){var e=mV(t.shadowBlur||0),n=mV(t.shadowOffsetX||0),t=mV(t.shadowOffsetY||0);return{left:mV(e-n),right:mV(e+n),top:mV(e-t),bottom:mV(e+t)}}function xV(t,e,n,i){t[0]=n,t[1]=i,t[2]=t[0]/e.getWidth(),t[3]=t[1]/e.getHeight()}var _V,bV=new L({shape:{x:-1,y:-1,width:2,height:2}}),wV=(u(SV,_V=Ky),SV.prototype.init=function(t,e){var n;!w.node&&e.getDom()&&(t=t.getComponent("tooltip"),n=this._renderMode="auto"===(n=t.get("renderMode"))?w.domSupported?"html":"richText":n||"html",this._tooltipContent="richText"===n?new fV(e):new dV(e,{appendTo:t.get("appendToBody",!0)?"body":t.get("appendTo",!0)}))},SV.prototype.render=function(t,e,n){!w.node&&n.getDom()&&(this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,(e=this._tooltipContent).update(t),e.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),"richText"!==this._renderMode&&t.get("transitionDuration")?pm(this,"_updatePosition",50,"fixRate"):dm(this,"_updatePosition"))},SV.prototype._initGlobalListener=function(){var i=this._tooltipModel.get("triggerOn");C5("itemTooltip",this._api,T(function(t,e,n){"none"!==i&&(0<=i.indexOf(t)?this._tryShow(e,n):"leave"===t&&this._hide(n))},this))},SV.prototype._keepShow=function(){var t,e=this._tooltipModel,n=this._ecModel,i=this._api,o=e.get("triggerOn");null!=this._lastX&&null!=this._lastY&&"none"!==o&&"click"!==o&&(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})}))},SV.prototype.manuallyShowTip=function(t,e,n,i){var o,r,a,s;i.from!==this.uid&&!w.node&&n.getDom()&&(o=IV(i,n),this._ticket="",s=i.dataByCoordSys,(r=function(n,t,e){var i=pa(n).queryOptionMap,o=i.keys()[0];if(o&&"series"!==o){var r,t=fa(t,o,i.get(o),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(t)if(e.getViewOfComponentModel(t).group.traverse(function(t){var e=$(t).tooltipConfig;if(e&&e.name===n.name)return r=t,!0}),r)return{componentMainType:o,componentIndex:t.componentIndex,el:r}}}(i,e,n))?((a=r.el.getBoundingRect().clone()).applyTransform(r.el.transform),this._tryShow({offsetX:a.x+a.width/2,offsetY:a.y+a.height/2,target:r.el,position:i.position,positionDefault:"bottom"},o)):i.tooltip&&null!=i.x&&null!=i.y?((a=bV).x=i.x,a.y=i.y,a.update(),$(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)||(a=(r=N5(i,e)).point[0],s=r.point[1],null!=a&&null!=s&&this._tryShow({offsetX:a,offsetY:s,target:r.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)))},SV.prototype.manuallyHideTip=function(t,e,n,i){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(IV(i,n))},SV.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){a=e.getSeriesByIndex(o);if(a){e=MV([a.getData().getItemModel(r),a,(a.coordinateSystem||{}).model],this._tooltipModel);if("axis"===e.get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:r,position:i.position}),!0}}},SV.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?"legend"!==$(r).ssrType&&(jm(r,function(t){return null!=$(t).dataIndex?(i=t,1):null!=$(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)))},SV.prototype._showOrMove=function(t,e){t=t.get("showDelay");e=T(e,this),clearTimeout(this._showTimout),0<t?this._showTimout=setTimeout(e,t):e()},SV.prototype._showAxisTooltip=function(t,e){var u=this._ecModel,h=this._tooltipModel,n=[e.offsetX,e.offsetY],i=MV([e.tooltipOption],h),c=this._renderMode,p=[],d=Iy("section",{blocks:[],noHeader:!0}),g=[],f=new Ry,o=(nt(t,function(t){nt(t.dataByAxis,function(o){var r,a,s=u.getComponent(o.axisDim+"Axis",o.axisIndex),l=o.value;s&&null!=l&&(r=a5(l,s.axis,u,o.seriesDataIndices,o.valueLabelOpt),a=Iy("section",{header:r,noHeader:!Ct(r),sortBlocks:!0,blocks:[]}),d.blocks.push(a),nt(o.seriesDataIndices,function(t){var e,n=u.getSeriesByIndex(t.seriesIndex),t=t.dataIndexInside,i=n.getDataParams(t);i.dataIndex<0||(i.axisDim=o.axisDim,i.axisIndex=o.axisIndex,i.axisType=o.axisType,i.axisId=o.axisId,i.axisValue=Ux(s.axis,{value:l}),i.axisValueLabel=r,i.marker=f.makeTooltipMarker("item",Md(i.color),c),(e=(t=Cf(n.formatTooltip(t,!0,null))).frag)&&(n=MV([n],h).get("valueFormatter"),a.blocks.push(n?F({valueFormatter:n},e):e)),t.text&&g.push(t.text),p.push(i))}))})}),d.blocks.reverse(),g.reverse(),e.position),e=i.get("order"),e=ky(d,f,c,e,u.get("useUTC"),i.get("textStyle")),e=(e&&g.unshift(e),"richText"===c?"\n\n":"<br/>"),r=g.join(e);this._showOrMove(i,function(){this._updateContentNotChangedOnAxis(t,p)?this._updatePosition(i,o,n[0],n[1],this._tooltipContent,p):this._showTooltipContent(i,r,p,Math.random()+"",n[0],n[1],o,null,f)})},SV.prototype._showSeriesItemTooltip=function(t,e,n){var i,o,r,a,s,l=this._ecModel,e=$(e),u=e.seriesIndex,h=l.getSeriesByIndex(u),c=e.dataModel||h,p=e.dataIndex,e=e.dataType,d=c.getData(e),g=this._renderMode,f=t.positionDefault,y=MV([d.getItemModel(p),c,h&&(h.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),h=y.get("trigger");null!=h&&"item"!==h||(i=c.getDataParams(p,e),o=new Ry,i.marker=o.makeTooltipMarker("item",Md(i.color),g),f=Cf(c.formatTooltip(p,!1,e)),h=y.get("order"),e=y.get("valueFormatter"),r=f.frag,a=r?ky(e?F({valueFormatter:e},r):r,o,g,h,l.get("useUTC"),y.get("textStyle")):f.text,s="item_"+c.name+"_"+p,this._showOrMove(y,function(){this._showTooltipContent(y,a,i,s,t.offsetX,t.offsetY,t.position,t.target,o)}),n({type:"showTip",dataIndexInside:p,dataIndex:d.getRawIndex(p),seriesIndex:u,from:this.uid}))},SV.prototype._showComponentItemTooltip=function(e,n,t){var i=$(n),o=i.tooltipConfig.option||{},r=[o=H(o)?{content:o,formatter:o}:o],i=this._ecModel.getComponent(i.componentMainType,i.componentIndex),i=(i&&r.push(i),r.push({formatter:o.content}),e.positionDefault),a=MV(r,this._tooltipModel,i?{position:i}:null),s=a.get("content"),l=Math.random()+"",u=new Ry;this._showOrMove(a,function(){var t=S(a.get("formatterParams")||{});this._showTooltipContent(a,s,t,l,e.offsetX,e.offsetY,e.position,n,u)}),t({type:"showTip",from:this.uid})},SV.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).setEnterable(n.get("enterable")),h=n.get("formatter"),a=a||n.get("position"),t=t,c=this._getNearestPoint([o,r],i,n.get("trigger"),n.get("borderColor")).color,h&&(t=H(h)?(p=n.ecModel.get("useUTC"),t=h,wd(t=(d=B(i)?i[0]:i)&&d.axisType&&0<=d.axisType.indexOf("time")?td(d.axisValue,t,p):t,i,!0)):D(h)?(d=T(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(t,l,n,c,a),u.show(n,c),this._updatePosition(n,a,o,r,u,i,s))},SV.prototype._getNearestPoint=function(t,e,n,i){return"axis"===n||B(e)?{color:i||("html"===this._renderMode?"#fff":"none")}:B(e)?void 0:{color:i||e.color||e.borderColor}},SV.prototype._updatePosition=function(t,e,n,i,o,r,a){var s,l=this._api.getWidth(),u=this._api.getHeight(),h=(e=e||t.get("position"),o.getSize()),c=t.get("align"),p=t.get("verticalAlign"),d=a&&a.getBoundingRect().clone();a&&d.applyTransform(a.transform),B(e=D(e)?e([n,i],r,o.el,d,{viewSize:[l,u],contentSize:h.slice()}):e)?(n=j(e[0],l),i=j(e[1],u)):O(e)?((r=e).width=h[0],r.height=h[1],n=(r=Ld(r,{width:l,height:u})).x,i=r.y,p=c=null):i=(n=(s=H(e)&&a?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,d,h,t.get("borderWidth")):function(t,e,n,i,o,r,a){var n=n.getSize(),s=n[0],n=n[1];null!=r&&(i<t+s+r+2?t-=s+r:t+=r);null!=a&&(o<e+n+a?e-=n+a:e+=a);return[t,e]}(n,i,o,l,u,c?null:20,p?null:20))[0],s[1]),c&&(n-=TV(c)?h[0]/2:"right"===c?h[0]:0),p&&(i-=TV(p)?h[1]/2:"bottom"===p?h[1]:0),iV(t)&&(r=n,a=i,e=l,d=u,c=(c=o).getSize(),p=c[0],c=c[1],r=Math.min(r+p,e)-p,a=Math.min(a+c,d)-c,r=Math.max(r,0),a=Math.max(a,0),n=(s=[r,a])[0],i=s[1]),o.moveTo(n,i)},SV.prototype._updateContentNotChangedOnAxis=function(n,r){var t=this._lastDataByCoordSys,a=this._cbParamsList,s=!!t&&t.length===n.length;return s&&nt(t,function(t,e){var t=t.dataByAxis||[],o=(n[e]||{}).dataByAxis||[];(s=s&&t.length===o.length)&&nt(t,function(t,e){var e=o[e]||{},n=t.seriesDataIndices||[],i=e.seriesDataIndices||[];(s=s&&t.value===e.value&&t.axisType===e.axisType&&t.axisId===e.axisId&&n.length===i.length)&&nt(n,function(t,e){e=i[e];s=s&&t.seriesIndex===e.seriesIndex&&t.dataIndex===e.dataIndex}),a&&nt(t.seriesDataIndices,function(t){var t=t.seriesIndex,e=r[t],t=a[t];e&&t&&t.data!==e.data&&(s=!1)})})}),this._lastDataByCoordSys=n,this._cbParamsList=r,!!s},SV.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},SV.prototype.dispose=function(t,e){!w.node&&e.getDom()&&(dm(this,"_updatePosition"),this._tooltipContent.dispose(),k5("itemTooltip",e))},SV.type="tooltip",SV);function SV(){var t=null!==_V&&_V.apply(this,arguments)||this;return t.type=SV.type,t}function MV(t,e,n){for(var i=e.ecModel,o=n?(o=new kp(n,i,i),new kp(e.option,o,i)):e,r=t.length-1;0<=r;r--){var a=t[r];(a=a&&(H(a=a instanceof kp?a.get("tooltip",!0):a)?{formatter:a}:a))&&(o=new kp(a,o,i))}return o}function IV(t,e){return t.dispatchAction||T(e.dispatchAction,e)}function TV(t){return"center"===t||"middle"===t}function CV(t,e){if(t)for(var n=B(t)?t:[t],i=0;i<n.length;i++)if(n[i]&&n[i][e])return 1}function DV(t){Qr(t,"label",["show"])}r(function(t){r(W5),t.registerComponentModel(eV),t.registerComponentView(wV),t.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Bt),t.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Bt)});var AV,kV=i(),LV=(u(PV,AV=g),PV.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._mergeOption(t,n,!1,!0)},PV.prototype.isAnimationEnabled=function(){var t;return!w.node&&(t=this.__hostSeries,this.getShallow("animation"))&&t&&t.isAnimationEnabled()},PV.prototype.mergeOption=function(t,e){this._mergeOption(t,e,!1,!1)},PV.prototype._mergeOption=function(t,i,e,o){var r=this.mainType;e||i.eachSeries(function(t){var e=t.get(this.mainType,!0),n=kV(t)[r];e&&e.data?(n?n._mergeOption(e,i,!0):(o&&DV(e),nt(e.data,function(t){t instanceof Array?(DV(t[0]),DV(t[1])):DV(t)}),F(n=this.createMarkerModelFromSeries(e,this,i),{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),n.__hostSeries=t),kV(t)[r]=n):kV(t)[r]=null},this)},PV.prototype.formatTooltip=function(t,e,n){var i=this.getData(),o=this.getRawValue(t),i=i.getName(t);return Iy("section",{header:this.name,blocks:[Iy("nameValue",{name:i,value:o,noName:!i,noValue:null==o})]})},PV.prototype.getData=function(){return this._data},PV.prototype.setData=function(t){this._data=t},PV.getMarkerModelFromSeries=function(t,e){return kV(t)[e]},PV.type="marker",PV.dependencies=["series","grid","polar","geo"],PV);function PV(){var t=null!==AV&&AV.apply(this,arguments)||this;return t.type=PV.type,t.createdBySelf=!1,t}ut(LV,Cp.prototype);u(RV,OV=LV),RV.prototype.createMarkerModelFromSeries=function(t,e,n){return new RV(t,e,n)},RV.type="markPoint",RV.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}};var OV,NV=RV;function RV(){var t=null!==OV&&OV.apply(this,arguments)||this;return t.type=RV.type,t}function EV(t){return!isNaN(parseFloat(t.x))||!isNaN(parseFloat(t.y))}function zV(t,e,n,i,o,r){var a=[],s=E1(e,i)?e.getCalculationInfo("stackResultDimension"):i,t=HV(e,s,t),t=e.indicesOfNearest(s,t)[0],o=(a[o]=e.get(n,t),a[r]=e.get(s,t),e.get(i,t)),n=kr(e.get(i,t));return 0<=(n=Math.min(n,20))&&(a[r]=+a[r].toFixed(n)),[a,o]}var VV={min:P(zV,"min"),max:P(zV,"max"),average:P(zV,"average"),median:P(zV,"median")};function BV(t,e){if(e){var n,i=t.getData(),o=t.coordinateSystem,r=o&&o.dimensions;if(n=e,(isNaN(parseFloat(n.x))||isNaN(parseFloat(n.y)))&&!B(e.coord)&&B(r)&&(n=FV(e,i,o,t),(e=S(e)).type&&VV[e.type]&&n.baseAxis&&n.valueAxis?(o=G(r,n.baseAxis.dim),t=G(r,n.valueAxis.dim),n=VV[e.type](i,n.baseDataDim,n.valueDataDim,o,t),e.coord=n[0],e.value=n[1]):e.coord=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis]),null!=e.coord&&B(r))for(var a=e.coord,s=0;s<2;s++)VV[a[s]]&&(a[s]=HV(i,i.mapDimension(r[s]),a[s]));else e.coord=[];return e}}function FV(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){t=t.getData().getDimensionInfo(e);return t&&t.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 GV(t,e){return!(t&&t.containData&&e.coord&&!EV(e))||t.containData(e.coord)}function WV(t,o){return t?function(t,e,n,i){return Ff(i<2?t.coord&&t.coord[i]:t.value,o[i])}:function(t,e,n,i){return Ff(t.value,o[i])}}function HV(t,e,n){var i,o;return"average"===n?(o=i=0,t.each(e,function(t,e){isNaN(t)||(i+=t,o++)}),i/o):"median"===n?t.getMedian(e):t.getDataExtent(e)["max"===n?1:0]}var YV,XV=i(),bp=(u(UV,YV=Ky),UV.prototype.init=function(){this.markerGroupMap=R()},UV.prototype.render=function(t,n,i){var o=this,e=this.markerGroupMap;e.each(function(t){XV(t).keep=!1}),n.eachSeries(function(t){var e=LV.getMarkerModelFromSeries(t,o.type);e&&o.renderSeries(t,e,n,i)}),e.each(function(t){XV(t).keep||o.group.remove(t.group)})},UV.prototype.markKeep=function(t){XV(t).keep=!0},UV.prototype.toggleBlurSeries=function(t,e){var n=this;nt(t,function(t){t=LV.getMarkerModelFromSeries(t,n.type);t&&t.getData().eachItemGraphicEl(function(t){t&&(e?du:gu)(t)})})},UV.type="marker",UV);function UV(){var t=null!==YV&&YV.apply(this,arguments)||this;return t.type=UV.type,t}function ZV(a,s,l){var u=s.coordinateSystem;a.each(function(t){var e,n,i,o=a.getItemModel(t),r=j(o.get("x"),l.getWidth()),o=j(o.get("y"),l.getHeight());isNaN(r)||isNaN(o)?s.getMarkerPosition?i=s.getMarkerPosition(a.getValues(a.dimensions,t)):u&&(e=a.get(u.dimensions[0],t),n=a.get(u.dimensions[1],t),i=u.dataToPoint([e,n])):i=[r,o],isNaN(r)||(i[0]=r),isNaN(o)||(i[1]=o),a.setItemLayout(t,i)})}u(KV,jV=bp),KV.prototype.updateTransform=function(t,e,n){e.eachSeries(function(t){var e=LV.getMarkerModelFromSeries(t,"markPoint");e&&(ZV(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout())},this)},KV.prototype.renderSeries=function(t,u,e,n){var i=t.coordinateSystem,o=t.id,h=t.getData(),r=this.markerGroupMap,r=r.get(o)||r.set(o,new Iw),c=function(t,e,n){var i;i=t?V(t&&t.dimensions,function(t){return F(F({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})}):[{name:"value",type:"float"}];var o=new k1(i,n),n=V(n.get("data"),P(BV,e));t&&(n=pt(n,P(GV,t)));t=WV(!!t,i);return o.initData(n,null,t),o}(i,t,u);u.setData(c),ZV(u.getData(),t,n),c.each(function(t){var e=c.getItemModel(t),n=e.getShallow("symbol"),i=e.getShallow("symbolSize"),o=e.getShallow("symbolRotate"),r=e.getShallow("symbolOffset"),a=e.getShallow("symbolKeepAspect"),s=((D(n)||D(i)||D(o)||D(r))&&(s=u.getRawValue(t),l=u.getDataParams(t),D(n)&&(n=n(s,l)),D(i)&&(i=i(s,l)),D(o)&&(o=o(s,l)),D(r))&&(r=r(s,l)),e.getModel("itemStyle").getItemStyle()),l=Ym(h,"color");s.fill||(s.fill=l),c.setItemVisual(t,{symbol:n,symbolSize:i,symbolRotate:o,symbolOffset:r,symbolKeepAspect:a,style:s})}),r.updateData(c),this.group.add(r.group),c.eachItemGraphicEl(function(t){t.traverse(function(t){$(t).dataModel=u})}),this.markKeep(r),r.group.silent=u.get("silent")||t.get("silent")},KV.type="markPoint";var jV,qV=KV;function KV(){var t=null!==jV&&jV.apply(this,arguments)||this;return t.type=KV.type,t}r(function(t){t.registerComponentModel(NV),t.registerComponentView(qV),t.registerPreprocessor(function(t){CV(t.series,"markPoint")&&(t.markPoint=t.markPoint||{})})});u(QV,$V=LV),QV.prototype.createMarkerModelFromSeries=function(t,e,n){return new QV(t,e,n)},QV.type="markLine",QV.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"};var $V,JV=QV;function QV(){var t=null!==$V&&$V.apply(this,arguments)||this;return t.type=QV.type,t}function tB(t,e,n,i){var o,r,a,s,l=t.getData();return(e=[BV(t,(n=B(i)?i:"min"===(o=i.type)||"max"===o||"average"===o||"median"===o||null!=i.xAxis||null!=i.yAxis?(r=s=void 0,r=null!=i.yAxis||null!=i.xAxis?(s=e.getAxis(null!=i.yAxis?"y":"x"),wt(i.yAxis,i.xAxis)):(s=(e=FV(i,l,e,t)).valueAxis,HV(l,z1(l,e.valueDataDim),o)),e=1-(l="x"===s.dim?0:1),s={coord:[]},(a=S(i)).type=null,a.coord=[],a.coord[e]=-1/0,s.coord[e]=1/0,0<=(e=n.get("precision"))&&Y(r)&&(r=+r.toFixed(Math.min(e,20))),a.coord[l]=s.coord[l]=r,[a,s,{type:o,valueIndex:i.valueIndex,value:r}]):[])[0]),BV(t,n[1]),F({},n[2])])[2].type=e[2].type||null,d(e[2],e[0]),d(e[2],e[1]),e}var eB=i();function nB(t){return!isNaN(t)&&!isFinite(t)}function iB(t,e,n,i){var o=1-t,r=i.dimensions[t];return nB(e[o])&&nB(n[o])&&e[t]===n[t]&&i.getAxis(r).containData(e[t])}function oB(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(iB(1,n,i,t)||iB(0,n,i,t)))return!0}return GV(t,e[0])&&GV(t,e[1])}function rB(t,e,n,i,o){var r,a,s=i.coordinateSystem,l=t.getItemModel(e),u=j(l.get("x"),o.getWidth()),l=j(l.get("y"),o.getHeight());isNaN(u)||isNaN(l)?(r=i.getMarkerPosition?i.getMarkerPosition(t.getValues(t.dimensions,e)):(a=s.dimensions,o=t.get(a[0],e),i=t.get(a[1],e),s.dataToPoint([o,i])),Gb(s,"cartesian2d")&&(o=s.getAxis("x"),i=s.getAxis("y"),a=s.dimensions,nB(t.get(a[0],e))?r[0]=o.toGlobalCoord(o.getExtent()[n?0:1]):nB(t.get(a[1],e))&&(r[1]=i.toGlobalCoord(i.getExtent()[n?0:1]))),isNaN(u)||(r[0]=u),isNaN(l)||(r[1]=l)):r=[u,l],t.setItemLayout(e,r)}u(lB,aB=bp),lB.prototype.updateTransform=function(t,e,r){e.eachSeries(function(e){var n,i,o,t=LV.getMarkerModelFromSeries(e,"markLine");t&&(n=t.getData(),i=eB(t).from,o=eB(t).to,i.each(function(t){rB(i,t,!0,e,r),rB(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)},lB.prototype.renderSeries=function(r,e,t,a){var n=r.coordinateSystem,i=r.id,s=r.getData(),o=this.markerGroupMap,o=o.get(i)||o.set(i,new EA),i=(this.group.add(o.group),function(t,e,n){var i;i=t?V(t&&t.dimensions,function(t){return F(F({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})}):[{name:"value",type:"float"}];var o=new k1(i,n),r=new k1(i,n),a=new k1([],n),n=V(n.get("data"),P(tB,e,t,n));t&&(n=pt(n,P(oB,t)));t=WV(!!t,i);return o.initData(V(n,function(t){return t[0]}),null,t),r.initData(V(n,function(t){return t[1]}),null,t),a.initData(V(n,function(t){return t[2]})),a.hasItemOption=!0,{from:o,to:r,line:a}}(n,r,e)),l=i.from,u=i.to,h=i.line,c=(eB(e).from=l,eB(e).to=u,e.setData(h),e.get("symbol")),p=e.get("symbolSize"),d=e.get("symbolRotate"),g=e.get("symbolOffset");function f(t,e,n){var i=t.getItemModel(e),o=(rB(t,e,n,r,a),i.getModel("itemStyle").getItemStyle());null==o.fill&&(o.fill=Ym(s,"color")),t.setItemVisual(e,{symbolKeepAspect:i.get("symbolKeepAspect"),symbolOffset:N(i.get("symbolOffset",!0),g[n?0:1]),symbolRotate:N(i.get("symbolRotate",!0),d[n?0:1]),symbolSize:N(i.get("symbolSize"),p[n?0:1]),symbol:N(i.get("symbol",!0),c[n?0:1]),style:o})}B(c)||(c=[c,c]),B(p)||(p=[p,p]),B(d)||(d=[d,d]),B(g)||(g=[g,g]),i.from.each(function(t){f(l,t,!0),f(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})}),o.updateData(h),i.line.eachItemGraphicEl(function(t){$(t).dataModel=e,t.traverse(function(t){$(t).dataModel=e})}),this.markKeep(o),o.group.silent=e.get("silent")||r.get("silent")},lB.type="markLine";var aB,sB=lB;function lB(){var t=null!==aB&&aB.apply(this,arguments)||this;return t.type=lB.type,t}r(function(t){t.registerComponentModel(JV),t.registerComponentView(sB),t.registerPreprocessor(function(t){CV(t.series,"markLine")&&(t.markLine=t.markLine||{})})});u(cB,uB=LV),cB.prototype.createMarkerModelFromSeries=function(t,e,n){return new cB(t,e,n)},cB.type="markArea",cB.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}};var uB,hB=cB;function cB(){var t=null!==uB&&uB.apply(this,arguments)||this;return t.type=cB.type,t}function pB(t,e,n,i){var o,r=i[0],i=i[1];if(r&&i)return r=BV(t,r),t=BV(t,i),i=r.coord,o=t.coord,i[0]=wt(i[0],-1/0),i[1]=wt(i[1],-1/0),o[0]=wt(o[0],1/0),o[1]=wt(o[1],1/0),(i=at([{},r,t])).coord=[r.coord,t.coord],i.x0=r.x,i.y0=r.y,i.x1=t.x,i.y1=t.y,i}var dB=i();function gB(t){return!isNaN(t)&&!isFinite(t)}function fB(t,e,n){t=1-t;return gB(e[t])&&gB(n[t])}function yB(t,e){var n,i,o,r=e.coord[0],a=e.coord[1],s={coord:r,x:e.x0,y:e.y0},e={coord:a,x:e.x1,y:e.y1};return Gb(t,"cartesian2d")?!((!r||!a||!fB(1,r,a)&&!fB(0,r,a))&&(i=s,o=e,n=t)&&n.containZone&&i.coord&&o.coord&&!EV(i)&&!EV(o))||n.containZone(i.coord,o.coord):GV(t,s)||GV(t,e)}function mB(t,e,n,i,o){var r,a,s,l,u,h,c=i.coordinateSystem,p=t.getItemModel(e),d=j(p.get(n[0]),o.getWidth()),p=j(p.get(n[1]),o.getHeight());return isNaN(d)||isNaN(p)?(h=i.getMarkerPosition?(o=t.getValues(["x0","y0"],e),s=t.getValues(["x1","y1"],e),a=c.clampData(o),h=c.clampData(s),r=[],"x0"===n[0]?r[0]=(a[0]>h[0]?s:o)[0]:r[0]=(a[0]>h[0]?o:s)[0],"y0"===n[1]?r[1]=(a[1]>h[1]?s:o)[1]:r[1]=(a[1]>h[1]?o:s)[1],i.getMarkerPosition(r,n,!0)):(a=[l=t.get(n[0],e),u=t.get(n[1],e)],c.clampData&&c.clampData(a,a),c.dataToPoint(a,!0)),Gb(c,"cartesian2d")&&(o=c.getAxis("x"),s=c.getAxis("y"),l=t.get(n[0],e),u=t.get(n[1],e),gB(l)?h[0]=o.toGlobalCoord(o.getExtent()["x0"===n[0]?0:1]):gB(u)&&(h[1]=s.toGlobalCoord(s.getExtent()["y0"===n[1]?0:1]))),isNaN(d)||(h[0]=d),isNaN(p)||(h[1]=p)):h=[d,p],h}var vB,xB=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],_B=(u(bB,vB=bp),bB.prototype.updateTransform=function(t,e,o){e.eachSeries(function(n){var i,t=LV.getMarkerModelFromSeries(n,"markArea");t&&(i=t.getData()).each(function(e){var t=V(xB,function(t){return mB(i,e,t,n,o)});i.setItemLayout(e,t),i.getItemGraphicEl(e).setShape("points",t)})},this)},bB.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 Z}),h=(this.group.add(i.group),this.markKeep(i),function(t,n,e){var i,o;{var r;i=t?(r=V(t&&t.dimensions,function(t){var e=n.getData();return F(F({},e.getDimensionInfo(e.mapDimension(t))||{}),{name:t,ordinalMeta:null})}),o=V(["x0","y0","x1","y1"],function(t,e){return{name:t,type:r[e%2].type}}),new k1(o,e)):new k1(o=[{name:"value",type:"float"}],e)}e=V(e.get("data"),P(pB,n,t,e));t&&(e=pt(e,P(yB,t)));t=t?function(t,e,n,i){return Ff(t.coord[Math.floor(i/2)][i%2],o[i])}:function(t,e,n,i){return Ff(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=V(xB,function(t){return mB(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))],o=(Ar(n),Ar(i),!(o[0]>n[1]||o[1]<n[0]||r[0]>i[1]||r[1]<i[0])),n=(h.setItemLayout(e,{points:t,allClipped:!o}),h.getItemModel(e).getModel("itemStyle").getItemStyle()),r=Ym(u,"color");n.fill||(n.fill=r,H(n.fill)&&(n.fill=ki(n.fill,.4))),n.stroke||(n.stroke=r),h.setItemVisual(e,"style",n)}),h.diff(dB(i).data).add(function(t){var e=h.getItemLayout(t);e.allClipped||(e=new Lh({shape:{points:e.points}}),h.setItemGraphicEl(t,e),i.group.add(e))}).update(function(t,e){var e=dB(i).data.getItemGraphicEl(e),n=h.getItemLayout(t);n.allClipped?e&&i.group.remove(e):(e?C(e,{shape:{points:n.points}},o,t):e=new Lh({shape:{points:n.points}}),h.setItemGraphicEl(t,e),i.group.add(e))}).remove(function(t){t=dB(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")),op(t,rp(n),{labelFetcher:o,labelDataIndex:e,defaultText:h.getName(e)||"",inheritColor:H(i.fill)?ki(i.fill,1):"#000"}),Du(t,n),Mu(t,null,null,n.get(["emphasis","disabled"])),$(t).dataModel=o}),dB(i).data=h,i.group.silent=o.get("silent")||a.get("silent")},bB.type="markArea",bB);function bB(){var t=null!==vB&&vB.apply(this,arguments)||this;return t.type=bB.type,t}r(function(t){t.registerComponentModel(hB),t.registerComponentView(_B),t.registerPreprocessor(function(t){CV(t.series,"markArea")&&(t.markArea=t.markArea||{})})});u(SB,wB=g),SB.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._initData()},SB.prototype.mergeOption=function(t){wB.prototype.mergeOption.apply(this,arguments),this._initData()},SB.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},SB.prototype.getCurrentIndex=function(){return this.option.currentIndex},SB.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},SB.prototype.setPlayState=function(t){this.option.autoPlay=!!t},SB.prototype.getPlayState=function(){return!!this.option.autoPlay},SB.prototype._initData=function(){var o,t=this.option,e=t.data||[],t=t.axisType,r=this._names=[],e=("category"===t?(o=[],nt(e,function(t,e){var n,i=ra(ea(t),"");O(t)?(n=S(t)).value=e:n=e,o.push(n),r.push(i)})):o=e,{category:"ordinal",time:"time",value:"number"}[t]||"number");(this._data=new k1([{name:"value",type:e}],this)).initData(o,r)},SB.prototype.getData=function(){return this._data},SB.prototype.getCategories=function(){if("category"===this.get("axisType"))return this._names.slice()},SB.type="timeline",SB.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]};var wB,e=SB;function SB(){var t=null!==wB&&wB.apply(this,arguments)||this;return t.type=SB.type,t.layoutMode="box",t}u(TB,MB=e),TB.type="timeline.slider",TB.defaultOption=Np(e.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:[]});var MB,IB=TB;function TB(){var t=null!==MB&&MB.apply(this,arguments)||this;return t.type=TB.type,t}ut(IB,Cp.prototype);u(DB,CB=Ky),DB.type="timeline";var CB,$m=DB;function DB(){var t=null!==CB&&CB.apply(this,arguments)||this;return t.type=DB.type,t}u(LB,AB=Ip),LB.prototype.getLabelModel=function(){return this.model.getModel("label")},LB.prototype.isHorizontal=function(){return"horizontal"===this.model.get("orient")};var AB,kB=LB;function LB(t,e,n,i){t=AB.call(this,t,e,n)||this;return t.type=i||"value",t}var PB,OB=Math.PI,NB=i(),RB=(u(EB,PB=$m),EB.prototype.init=function(t,e){this.api=e},EB.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"),t=this._createGroup("_labelGroup"),r=this._axis=this._createAxis(i,e),e.formatTooltip=function(t){return Iy("nameValue",{noName:!0,value:r.scale.getLabel({value:t})})},nt(["AxisLine","AxisTick","Control","CurrentPointer"],function(t){this["_render"+t](i,o,r,e)},this),this._renderAxisLabel(i,t,r,e),this._position(i,e)),this._doPlayStop(),this._updateTicksStatus()},EB.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},EB.prototype.dispose=function(){this._clearTimer()},EB.prototype._layout=function(t,e){var n,i,o,r=t.get(["label","position"]),a=t.get("orient"),s=(s=e,Ld((l=t).getBoxLayoutParams(),{width:s.getWidth(),height:s.getHeight()},l.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?"+":"-":H(r)?{horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[a][r]:r,e={horizontal:"center",vertical:0<=l||"+"===l?"left":"right"},r={horizontal:0<=l||"+"===l?"top":"bottom",vertical:"middle"},u={horizontal:0,vertical:OB/2},h="vertical"===a?s.height:s.width,c=t.getModel("controlStyle"),p=c.get("show",!0),d=p?c.get("itemSize"):0,g=p?c.get("itemGap"):0,f=d+g,y=(t.get(["label","rotate"])||0)*OB/180,m=c.get("position",!0),v=p&&c.get("showPlayBtn",!0),x=p&&c.get("showPrevBtn",!0),p=p&&c.get("showNextBtn",!0),c=0,_=h,m=("left"===m||"bottom"===m?(v&&(n=[0,0],c+=f),x&&(i=[c,0],c+=f)):(v&&(n=[_-d,0],_-=f),x&&(i=[0,0],c+=f)),p&&(o=[_-d,0],_-=f),[c,_]);return t.get("inverse")&&m.reverse(),{viewRect:s,mainLength:h,orient:a,rotation:u[a],labelRotation:y,labelPosOpt:l,labelAlign:t.get(["label","align"])||e[a],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||r[a],playPosition:n,prevBtnPosition:i,nextBtnPosition:o,axisExtent:m,controlSize:d,controlGap:g}},EB.prototype._position=function(t,e){var n,i=this._mainGroup,o=this._labelGroup,r=t.viewRect,a=("vertical"===t.orient&&(Ge(u=ze(),u,[-(s=r.x),-(l=r.y+r.height)]),We(u,u,-OB/2),Ge(u,u,[s,l]),(r=r.clone()).applyTransform(u)),p(r)),s=p(i.getBoundingRect()),l=p(o.getBoundingRect()),u=[i.x,i.y],r=[o.x,o.y],h=(r[0]=u[0]=a[0][0],t.labelPosOpt);function c(t){t.originX=a[0][0]-t.x,t.originY=a[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==h||H(h)?(d(u,s,a,1,n="+"===h?0:1),d(r,l,a,1,1-n)):(d(u,s,a,1,n=0<=h?0:1),r[1]=u[1]+h),i.setPosition(u),o.setPosition(r),i.rotation=o.rotation=t.rotation,c(i),c(o)},EB.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 tx({ordinalMeta:t.getCategories(),extent:[1/0,-1/0]});case"time":return new _x({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new ox}}(e,i),r=(o.getTicks=function(){return n.mapArray(["value"],function(t){return{value:t}})},n.getDataExtent("value")),r=(o.setExtent(r[0],r[1]),o.calcNiceTicks(),new kB("value",o,t.axisExtent,i));return r.model=e,r},EB.prototype._createGroup=function(t){t=this[t]=new Z;return this.group.add(t),t},EB.prototype._renderAxisLine=function(t,e,n,i){var o,n=n.getExtent();i.get(["lineStyle","show"])&&(o=new Fh({shape:{x1:n[0],y1:0,x2:n[1],y2:0},style:F({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1}),e.add(o),n=this._progressLine=new Fh({shape:{x1:n[0],x2:this._currentPointer?this._currentPointer.x:n[0],y1:0,y2:0},style:z({lineCap:"round",lineWidth:o.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1}),e.add(n))},EB.prototype._renderAxisTick=function(t,a,s,l){var u=this,h=l.getData(),e=s.scale.getTicks();this._tickSymbols=[],nt(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:T(u._changeTimeline,u,t.value)},i=zB(n,i,a,e),e=(i.ensureState("emphasis").style=o.getItemStyle(),i.ensureState("progress").style=r.getItemStyle(),Su(i),$(i));n.get("tooltip")?(e.dataIndex=t.value,e.dataModel=l):e.dataIndex=e.dataModel=null,u._tickSymbols.push(i)})},EB.prototype._renderAxisLabel=function(a,s,l,t){var u,h=this;l.getLabelModel().get("show")&&(u=t.getData(),t=l.getViewLabels(),this._tickLabels=[],nt(t,function(t){var e=t.tickValue,n=u.getItemModel(e),i=n.getModel("label"),o=n.getModel(["emphasis","label"]),n=n.getModel(["progress","label"]),r=l.dataToCoord(t.tickValue),r=new K({x:r,y:0,rotation:a.labelRotation-a.rotation,onclick:T(h._changeTimeline,h,e),silent:!1,style:ap(i,{text:t.formattedLabel,align:a.labelAlign,verticalAlign:a.labelBaseline})});r.ensureState("emphasis").style=ap(o),r.ensureState("progress").style=ap(n),s.add(r),Su(r),NB(r).dataIndex=e,h._tickLabels.push(r)}))},EB.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=er(N(a.get(["controlStyle",e+"BtnSize"]),s),s),(e=function(t,e,n,i){var o=i.style,t=jc(t.get(["controlStyle",e]),i||{},new U(n[0],n[1],n[2],n[3]));o&&t.setStyle(o);return t}(a,e+"Icon",[0,-o/2,o,o],{x:t[0],y:t[1],originX:s/2,originY:0,rotation:i?-l:0,rectHover:!0,style:u,onclick:n})).ensureState("emphasis").style=h,r.add(e),Su(e))}o(t.nextBtnPosition,"next",T(this._changeTimeline,this,i?"-":"+")),o(t.prevBtnPosition,"prev",T(this._changeTimeline,this,i?"+":"-")),o(t.playPosition,n?"stop":"play",T(this._handlePlayClick,this,!n),!0)},EB.prototype._renderCurrentPointer=function(t,e,n,i){var o=i.getData(),r=i.getCurrentIndex(),o=o.getItemModel(r).getModel("checkpointStyle"),a=this;this._currentPointer=zB(o,o,this._mainGroup,{},this._currentPointer,{onCreate:function(t){t.draggable=!0,t.drift=T(a._handlePointerDrag,a),t.ondragend=T(a._handlePointerDragend,a),VB(t,a._progressLine,r,n,i,!0)},onUpdate:function(t){VB(t,a._progressLine,r,n,i)}})},EB.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},EB.prototype._handlePointerDrag=function(t,e,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},EB.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},EB.prototype._pointerChangeTimeline=function(t,e){var t=this._toAxisCoord(t)[0],n=Ar(this._axis.getExtent().slice()),n=((t=t>n[1]?n[1]:t)<n[0]&&(t=n[0]),this._currentPointer.x=t,this._currentPointer.markRedraw(),this._progressLine),n=(n&&(n.shape.x2=t,n.dirty()),this._findNearestTick(t)),t=this.model;(e||n!==t.getCurrentIndex()&&t.get("realtime"))&&this._changeTimeline(n)},EB.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")))},EB.prototype._toAxisCoord=function(t){return Wc(t,this._mainGroup.getLocalTransform(),!0)},EB.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},EB.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},EB.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})},EB.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",NB(n[i]).dataIndex<=t)},EB.type="timeline.slider",EB);function EB(){var t=null!==PB&&PB.apply(this,arguments)||this;return t.type=EB.type,t}function zB(t,e,n,i,o,r){var a=e.get("color"),a=(o?(o.setColor(a),n.add(o),r&&r.onUpdate(o)):((o=s0(t.get("symbol"),-1,-1,2,2,a)).setStyle("strokeNoScale",!0),n.add(o),r&&r.onCreate(o)),e.getItemStyle(["color"])),n=(o.setStyle(a),i=d({rectHover:!0,z2:100},i,!0),l0(t.get("symbolSize"))),r=(i.scaleX=n[0]/2,i.scaleY=n[1]/2,u0(t.get("symbolOffset"),n)),e=(r&&(i.x=(i.x||0)+r[0],i.y=(i.y||0)+r[1]),t.get("symbolRotate"));return i.rotation=(e||0)*Math.PI/180||0,o.attr(i),o.updateTransform(),o}function VB(t,e,n,i,o,r){var a;t.dragging||(a=o.getModel("checkpointStyle"),i=i.dataToCoord(o.getData().get("value",n)),r||!a.get("animation",!0)?(t.attr({x:i,y:0}),e&&e.attr({shape:{x2:i}})):(o={duration:a.get("animationDuration",!0),easing:a.get("animationEasing",!0)},t.stopAnimation(null,!0),t.animateTo({x:i,y:0},o),e&&e.animateTo({shape:{x2:i}},o)))}function BB(t){t=t&&t.timeline;nt(t=B(t)?t:t?[t]:[],function(t){var e,n;t&&(e=(t=t).type,(n={number:"value",time:"time"})[e]&&(t.axisType=n[e],delete t.type),FB(t),GB(t,"controlPosition")&&(GB(n=t.controlStyle||(t.controlStyle={}),"position")||(n.position=t.controlPosition),"none"!==n.position||GB(n,"show")||(n.show=!1,delete n.position),delete t.controlPosition),nt(t.data||[],function(t){O(t)&&!B(t)&&(!GB(t,"value")&&GB(t,"name")&&(t.value=t.name),FB(t))}))})}function FB(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};nt(t,function(t,e){i[e]||GB(n,e)||(n[e]=t)}),e.label&&!GB(t,"emphasis")&&(t.emphasis=e.label,delete e.label)}function GB(t,e){return t.hasOwnProperty(e)}r(function(t){var e;t.registerComponentModel(IB),t.registerComponentView(RB),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(BB)});var WB=["x","y","radius","angle","single"],HB=["cartesian2d","polar","singleAxis"];function YB(t){return t+"Axis"}function XB(t,e){var i,o=R(),n=[],r=R();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 UB(t){var o=t.ecModel,r={infoList:[],infoMap:R()};return t.eachTargetAxis(function(t,e){var n,i,t=o.getComponent(YB(t),e);t&&(e=t.getCoordSysModel())&&(n=e.uid,(i=r.infoMap.get(n))||(r.infoList.push(i={model:e,axisModels:[]}),r.infoMap.set(n,i)),i.axisModels.push(t))}),r}jB.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)};var ZB=jB;function jB(){this.indexList=[],this.indexMap=[]}u(KB,qB=g),KB.prototype.init=function(t,e,n){var i=$B(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},KB.prototype.mergeOption=function(t){var e=$B(t);d(this.option,t,!0),d(this.settledOption,e,!0),this._doInit(e)},KB.prototype._doInit=function(t){var n=this.option,i=(this._setDefaultThrottle(t),this._updateRangeUse(t),this.settledOption);nt([["start","startValue"],["end","endValue"]],function(t,e){"value"===this._rangePropMode[e]&&(n[t[0]]=i[t[0]]=null)},this),this._resetTarget()},KB.prototype._resetTarget=function(){var t=this.get("orient",!0),e=this._targetAxisInfoMap=R();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)},KB.prototype._fillSpecifiedTargetAxis=function(i){var o=!1;return nt(WB,function(t){var e,n=this.getReferringComponents(YB(t),ga);n.specified&&(o=!0,e=new ZB,nt(n.models,function(t){e.add(t.componentIndex)}),i.set(t,e))},this),o},KB.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 ZB).add(o.componentIndex),r.set(e,n),a=!1,"x"!==e&&"y"!==e||(i=o.getReferringComponents("grid",da).models[0])&&nt(t,function(t){o.componentIndex!==t.componentIndex&&i===t.getReferringComponents("grid",da).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&&nt(WB,function(t){var e,n;a&&(e=i.findComponents({mainType:YB(t),filter:function(t){return"category"===t.get("type",!0)}}))[0]&&((n=new ZB).add(e[0].componentIndex),r.set(t,n),a=!1)},this)},KB.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(t){e=e||t},this),"y"===e?"vertical":"horizontal"},KB.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)},KB.prototype._updateRangeUse=function(i){var o=this._rangePropMode,r=this.get("rangeMode");nt([["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")})},KB.prototype.noTarget=function(){return this._noTarget},KB.prototype.getFirstTargetAxisModel=function(){var n;return this.eachTargetAxis(function(t,e){null==n&&(n=this.ecModel.getComponent(YB(t),e))},this),n},KB.prototype.eachTargetAxis=function(n,i){this._targetAxisInfoMap.each(function(t,e){nt(t.indexList,function(t){n.call(i,e,t)})})},KB.prototype.getAxisProxy=function(t,e){t=this.getAxisModel(t,e);if(t)return t.__dzAxisProxy},KB.prototype.getAxisModel=function(t,e){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[e])return this.ecModel.getComponent(YB(t),e)},KB.prototype.setRawRange=function(e){var n=this.option,i=this.settledOption;nt([["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)},KB.prototype.setCalculatedRange=function(e){var n=this.option;nt(["start","startValue","end","endValue"],function(t){n[t]=e[t]})},KB.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},KB.prototype.getValueRange=function(t,e){return null!=t||null!=e?this.getAxisProxy(t,e).getDataValueWindow():(t=this.findRepresentativeAxisProxy())?t.getDataValueWindow():void 0},KB.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},KB.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},KB.prototype.getOrient=function(){return this._orient},KB.type="dataZoom",KB.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],KB.defaultOption={z:4,filterMode:"filter",start:0,end:100};var qB,Ia=KB;function KB(){var t=null!==qB&&qB.apply(this,arguments)||this;return t.type=KB.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}function $B(e){var n={};return nt(["start","end","startValue","endValue","throttle"],function(t){e.hasOwnProperty(t)&&(n[t]=e[t])}),n}u(t3,JB=Ia),t3.type="dataZoom.inside",t3.defaultOption=Np(Ia.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0});var JB,QB=t3;function t3(){var t=null!==JB&&JB.apply(this,arguments)||this;return t.type=t3.type,t}u(n3,e3=Ky),n3.prototype.render=function(t,e,n,i){this.dataZoomModel=t,this.ecModel=e,this.api=n},n3.type="dataZoom";var e3,n0=n3;function n3(){var t=null!==e3&&e3.apply(this,arguments)||this;return t.type=n3.type,t}var i3=i();function o3(t,e){e&&(t.removeKey(e.model.uid),t=e.controller)&&t.dispose()}function r3(t,e){t.isDisposed()||t.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function a3(t,e,n,i){return t.coordinateSystem.containPoint([n,i])}function s3(t){t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,function(t,a){var e=i3(a),l=e.coordSysRecordMap||(e.coordSysRecordMap=R());l.each(function(t){t.dataZoomInfoMap=null}),t.eachComponent({mainType:"dataZoom",subType:"inside"},function(o){nt(UB(o).infoList,function(t){var r,e,n=t.model.uid,i=l.get(n)||l.set(n,(n=a,i=t.model,r={model:i,containsPoint:P(a3,i),dispatchAction:P(r3,n),dataZoomInfoMap:null,controller:null},e=r.controller=new N2(n.getZr()),nt(["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=R())).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;(e=s&&null!=(n=s.keys()[0])?s.get(n):e)?(o={type_true:2,type_move:1,type_false:0,type_undefined:-1},r=!0,s.each(function(t){var t=t.model,e=!t.get("disabled",!0)&&(!t.get("zoomLock",!0)||"move");o["type_"+i]<o["type_"+e]&&(i=e),r=r&&t.get("preventDefaultMouseMove",!0)}),n={controlType:i,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!r}},a.enable(n.controlType,n.opt),a.setPointerChecker(t.containsPoint),pm(t,"dispatchAction",e.model.get("throttle",!0),"fixRate")):o3(l,t)})})}u(h3,l3=n0),h3.prototype.render=function(t,e,n){var i,o;l3.prototype.render.apply(this,arguments),t.noTarget()?this._clear():(this.range=t.getPercentRange(),n=n,i=t,o={pan:T(c3.pan,this),zoom:T(c3.zoom,this),scrollMove:T(c3.scrollMove,this)},i3(n).coordSysRecordMap.each(function(t){t=t.dataZoomInfoMap.get(i.uid);t&&(t.getRange=o)}))},h3.prototype.dispose=function(){this._clear(),l3.prototype.dispose.apply(this,arguments)},h3.prototype._clear=function(){for(var t=this.api,e=this.dataZoomModel,n=i3(t).coordSysRecordMap,i=n.keys(),o=0;o<i.length;o++){var r,a=i[o],a=n.get(a),s=a.dataZoomInfoMap;s&&(r=e.uid,s.get(r))&&(s.removeKey(r),s.keys().length||o3(n,a))}this.range=null},h3.type="dataZoom.inside";var l3,u3=h3;function h3(){var t=null!==l3&&l3.apply(this,arguments)||this;return t.type="dataZoom.inside",t}var c3={zoom:function(t,e,n,i){var o=this.range,r=o.slice(),a=t.axisModels[0];if(a)return a=(0<(e=d3[e](null,[i.originX,i.originY],a,n,t)).signal?e.pixelStart+e.pixelLength-e.pixel:e.pixel-e.pixelStart)/e.pixelLength*(r[1]-r[0])+r[0],n=Math.max(1/i.scale,0),r[0]=(r[0]-a)*n+a,r[1]=(r[1]-a)*n+a,JL(0,r,[0,100],0,(t=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan()).minSpan,t.maxSpan),this.range=r,o[0]!==r[0]||o[1]!==r[1]?r:void 0},pan:p3(function(t,e,n,i,o,r){i=d3[i]([r.oldX,r.oldY],[r.newX,r.newY],e,o,n);return i.signal*(t[1]-t[0])*i.pixel/i.pixelLength}),scrollMove:p3(function(t,e,n,i,o,r){return d3[i]([0,0],[r.scrollDelta,r.scrollDelta],e,o,n).signal*(t[1]-t[0])*r.scrollDelta})};function p3(s){return function(t,e,n,i){var o=this.range,r=o.slice(),a=t.axisModels[0];if(a)return JL(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 d3={grid:function(t,e,n,i,o){var n=n.axis,r={},o=o.model.coordinateSystem.getRect();return t=t||[0,0],"x"===n.dim?(r.pixel=e[0]-t[0],r.pixelLength=o.width,r.pixelStart=o.x,r.signal=n.inverse?1:-1):(r.pixel=e[1]-t[1],r.pixelLength=o.height,r.pixelStart=o.y,r.signal=n.inverse?-1:1),r},polar:function(t,e,n,i,o){var r=n.axis,a={},o=o.model.coordinateSystem,s=o.getRadiusAxis().getExtent(),l=o.getAngleAxis().getExtent();return t=t?o.pointToCoord(t):[0,0],e=o.pointToCoord(e),"radiusAxis"===n.mainType?(a.pixel=e[0]-t[0],a.pixelLength=s[1]-s[0],a.pixelStart=s[0],a.signal=r.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=r.inverse?-1:1),a},singleAxis:function(t,e,n,i,o){var n=n.axis,o=o.model.coordinateSystem.getRect(),r={};return t=t||[0,0],"horizontal"===n.orient?(r.pixel=e[0]-t[0],r.pixelLength=o.width,r.pixelStart=o.x,r.signal=n.inverse?1:-1):(r.pixel=e[1]-t[1],r.pixelLength=o.height,r.pixelStart=o.y,r.signal=n.inverse?-1:1),r}},g3=nt,f3=Ar,y3=(m3.prototype.hostedBy=function(t){return this._dataZoomModel===t},m3.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},m3.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},m3.prototype.getTargetSeriesModels=function(){var n=[];return this.ecModel.eachSeries(function(t){var e;e=(e=t).get("coordinateSystem"),0<=G(HB,e)&&(e=YB(this._dimName),e=t.getReferringComponents(e,da).models[0])&&this._axisIndex===e.componentIndex&&n.push(t)},this),n},m3.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},m3.prototype.getMinMaxSpan=function(){return S(this._minMaxSpan)},m3.prototype.calculateDataWindow=function(i){var o,r=this._dataExtent,s=this.getAxisModel().axis.scale,a=this._dataZoomModel.getRangePropMode(),l=[0,100],u=[],h=[],c=(g3(["start","end"],function(t,e){var n=i[t],t=i[t+"Value"];"percent"===a[e]?t=s.parse(Cr(n=null==n?l[e]:n,l,r)):(o=!0,n=Cr(t=null==t?r[e]:s.parse(t),r,l)),h[e]=null==t||isNaN(t)?r[e]:t,u[e]=null==n||isNaN(n)?l[e]:n}),f3(h),f3(u),this._minMaxSpan);function t(t,e,n,i,o){var r=o?"Span":"ValueSpan";JL(0,t,n,"all",c["min"+r],c["max"+r]);for(var a=0;a<2;a++)e[a]=Cr(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}},m3.prototype.reset=function(t){var e,i,o,n;t===this._dataZoomModel&&(n=this.getTargetSeriesModels(),this._dataExtent=(i=(e=this)._dimName,o=[1/0,-1/0],g3(n=n,function(t){var e,n;e=o,n=t.getData(),t=i,n&&nt(Kx(n,t),function(t){t=n.getApproximateExtent(t);t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])})}),[(e=Fx((n=e.getAxisModel()).axis.scale,n,o).calculate()).min,e.max]),this._updateMinMaxSpan(),n=this.calculateDataWindow(t.settledOption),this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,this._setAxisModel())},m3.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)&&g3(n,function(n){var l,u,i=n.getData(),h=i.mapDimensionsAll(o);h.length&&("weakFilter"===r?(l=i.getStore(),u=V(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})):g3(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))}),g3(h,function(t){i.setApproximateExtent(c,t)}))})},m3.prototype._updateMinMaxSpan=function(){var i=this._minMaxSpan={},o=this._dataZoomModel,r=this._dataExtent;g3(["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=Cr(r[0]+n,r,[0,100],!0):null!=e&&(n=Cr(e,[0,100],r,!0)-r[0]),i[t+"Span"]=e,i[t+"ValueSpan"]=n},this)},m3.prototype._setAxisModel=function(){var t,e=this.getAxisModel(),n=this._percentWindow,i=this._valueWindow;n&&(t=Pr(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())},m3);function m3(t,e,n,i){this._dimName=t,this._axisIndex=e,this.ecModel=i,this._dataZoomModel=n}var v3={getTargetSeries:function(r){function t(o){r.eachComponent("dataZoom",function(i){i.eachTargetAxis(function(t,e){var n=r.getComponent(YB(t),e);o(t,e,n,i)})})}t(function(t,e,n,i){n.__dzAxisProxy=null});var o=[],e=(t(function(t,e,n,i){n.__dzAxisProxy||(n.__dzAxisProxy=new y3(t,e,i,r),o.push(n.__dzAxisProxy))}),R());return nt(o,function(t){nt(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 x3=!1;function _3(t){x3||(x3=!0,t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,v3),t.registerAction("dataZoom",function(e,t){nt(XB(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 b3(t){_3(t),t.registerComponentModel(QB),t.registerComponentView(u3),s3(t)}u(M3,w3=Ia),M3.type="dataZoom.slider",M3.layoutMode="box",M3.defaultOption=Np(Ia.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"}}});var w3,S3=M3;function M3(){var t=null!==w3&&w3.apply(this,arguments)||this;return t.type=M3.type,t}var I3,T3=L,C3="horizontal",D3="vertical",A3=["line","bar","candlestick","scatter"],k3={easing:"cubicOut",duration:100,delay:0},L3=(u(P3,I3=n0),P3.prototype.init=function(t,e){this.api=e,this._onBrush=T(this._onBrush,this),this._onBrushEnd=T(this._onBrushEnd,this)},P3.prototype.render=function(t,e,n,i){I3.prototype.render.apply(this,arguments),pm(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),!1===t.get("show")?this.group.removeAll():t.noTarget()?(this._clear(),this.group.removeAll()):(i&&"dataZoom"===i.type&&i.from===this.uid||this._buildView(),this._updateView())},P3.prototype.dispose=function(){this._clear(),I3.prototype.dispose.apply(this,arguments)},P3.prototype._clear=function(){dm(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},P3.prototype._buildView=function(){var t=this.group,e=(t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval(),this._displayables.sliderGroup=new Z);this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},P3.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===C3?{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=Rd(t.option),n=(nt(["right","top","width","height"],function(t){"ph"===r[t]&&(r[t]=o[t])}),Ld(r,e));this._location={x:n.x,y:n.y},this._size=[n.width,n.height],this._orient===D3&&this._size.reverse()},P3.prototype._positionGroup=function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),i=i&&i.get("inverse"),o=this._displayables.sliderGroup,r=(this._dataShadowInfo||{}).otherAxisInverse,n=(o.attr(n!==C3||i?n===C3&&i?{scaleY:r?1:-1,scaleX:-1}:n!==D3||i?{scaleY:r?-1:1,scaleX:-1,rotation:Math.PI/2}:{scaleY:r?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:r?1:-1,scaleX:1}),t.getBoundingRect([o]));t.x=e.x-n.x,t.y=e.y-n.y,t.markRedraw()},P3.prototype._getViewExtent=function(){return[0,this._size[0]]},P3.prototype._renderBackground=function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect"),t=(n.add(new T3({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40})),new T3({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:T(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)},P3.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],t){var e=this._size,n=this._shadowSize||[],i=t.series,o=i.getRawData(),r=i.getShadowDim&&i.getShadowDim(),r=r&&o.getDimensionInfo(r)?i.getShadowDim():t.otherDim;if(null!=r)for(var a,s,l,u,h,c,p,d,g,f,y=this._shadowPolygonPts,m=this._shadowPolylinePts,v=(o===this._shadowData&&r===this._shadowDim&&e[0]===n[0]&&e[1]===n[1]||(i=.3*((a=o.getDataExtent(r))[1]-a[0]),a=[a[0]-i,a[1]+i],s=[0,e[1]],t=[0,e[0]],l=[[e[0],0],[0,0]],u=[],h=t[1]/(o.count()-1),c=0,p=Math.round(o.count()/e[0]),o.each([r],function(t,e){var n;0<p&&e%p?c+=h:(t=(n=null==t||isNaN(t)||""===t)?0:Cr(t,a,s,!0),n&&!d&&e?(l.push([l[l.length-1][0],0]),u.push([u[u.length-1][0],0])):!n&&d&&(l.push([c,0]),u.push([c,0])),l.push([c,t]),u.push([c,t]),c+=h,d=n)}),y=this._shadowPolygonPts=l,m=this._shadowPolylinePts=u),this._shadowData=o,this._shadowDim=r,this._shadowSize=[e[0],e[1]],this.dataZoomModel),x=0;x<3;x++){g=1===x,_=f=void 0,g=v.getModel(g?"selectedDataBackground":"dataBackground"),f=new Z,_=new Lh({shape:{points:y},segmentIgnoreThreshold:1,style:g.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),g=new Rh({shape:{points:m},segmentIgnoreThreshold:1,style:g.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19}),f.add(_),f.add(g);var _=f;this._displayables.sliderGroup.add(_),this._displayables.dataShadowSegs.push(_)}}},P3.prototype._prepareDataShadowInfo=function(){var s,l,t=this.dataZoomModel,u=t.get("showDataShadow");if(!1!==u)return l=this.ecModel,t.eachTargetAxis(function(r,a){nt(t.getAxisProxy(r,a).getTargetSeriesModels(),function(t){var e,n,i,o;s||!0!==u&&G(A3,t.get("type"))<0||(e=l.getComponent(YB(r),a).axis,o=t.coordinateSystem,null!=(n={x:"y",y:"x",radius:"angle",angle:"radius"}[r])&&o.getOtherAxis&&(i=o.getOtherAxis(e).inverse),n=t.getData().mapDimension(n),s={thisAxis:e,series:t,thisDim:r,otherDim:n,otherAxisInverse:i})},this)},this),s},P3.prototype._renderHandle=function(){var t,e,o=this.group,n=this._displayables,r=n.handles=[null,null],a=n.handleLabels=[null,null],s=this._displayables.sliderGroup,i=this._size,l=this.dataZoomModel,u=this.api,h=l.get("borderRadius")||0,c=l.get("brushSelect"),p=n.filler=new T3({silent:c,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}}),h=(s.add(p),s.add(new T3({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:i[0],height:i[1],r:h},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),nt([0,1],function(t){var e=l.get("handleIcon"),e=s0(e=!o0[e]&&e.indexOf("path://")<0&&e.indexOf("image://")<0?"path://"+e:e,-1,0,2,2,null,!0),n=(e.attr({cursor:O3(this._orient),draggable:!0,drift:T(this._onDragMove,this,t),ondragend:T(this._onDragEnd,this),onmouseover:T(this._showDataInfo,this,!0),onmouseout:T(this._showDataInfo,this,!1),z2:5}),e.getBoundingRect()),i=l.get("handleSize"),i=(this._handleHeight=j(i,this._size[1]),this._handleWidth=n.width/n.height*this._handleHeight,e.setStyle(l.getModel("handleStyle").getItemStyle()),e.style.strokeNoScale=!0,e.rectHover=!0,e.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),Su(e),l.get("handleColor")),n=(null!=i&&(e.style.fill=i),s.add(r[t]=e),l.getModel("textStyle"));o.add(a[t]=new K({silent:!0,invisible:!0,style:ap(n,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:n.getTextColor(),font:n.getFont()}),z2:10}))},this),p);c&&(p=j(l.get("moveHandleSize"),i[1]),t=n.moveHandle=new L({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:i[1]-.5,height:p}}),c=.8*p,(c=n.moveHandleIcon=s0(l.get("moveHandleIcon"),-c/2,-c/2,c,c,"#fff",!0)).silent=!0,c.y=i[1]+p/2-.5,t.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle(),e=Math.min(i[1]/2,Math.max(p,10)),(h=n.moveZone=new L({invisible:!0,shape:{y:i[1]-e,height:p+e}})).on("mouseover",function(){u.enterEmphasis(t)}).on("mouseout",function(){u.leaveEmphasis(t)}),s.add(t),s.add(c),s.add(h)),h.attr({draggable:!0,cursor:O3(this._orient),drift:T(this._onDragMove,this,"all"),ondragstart:T(this._showDataInfo,this,!0),ondragend:T(this._onDragEnd,this),onmouseover:T(this._showDataInfo,this,!0),onmouseout:T(this._showDataInfo,this,!1)})},P3.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[Cr(t[0],[0,100],e,!0),Cr(t[1],[0,100],e,!0)]},P3.prototype._updateInterval=function(t,e){var n=this.dataZoomModel,i=this._handleEnds,o=this._getViewExtent(),r=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100],e=(JL(e,i,o,n.get("zoomLock")?"all":t,null!=r.minSpan?Cr(r.minSpan,a,o,!0):null,null!=r.maxSpan?Cr(r.maxSpan,a,o,!0):null),this._range),n=this._range=Ar([Cr(i[0],o,a,!0),Cr(i[1],o,a,!0)]);return!e||e[0]!==n[0]||e[1]!==n[1]},P3.prototype._updateView=function(t){for(var i=this._displayables,o=this._handleEnds,e=Ar(o.slice()),r=this._size,n=(nt([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]}),{x:e[0],width:e[1]-e[0]}),a=(i.moveHandle&&(i.moveHandle.setShape(n),i.moveZone.setShape(n),i.moveZone.getBoundingRect(),i.moveHandleIcon)&&i.moveHandleIcon.attr("x",n.x+n.width/2),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 L,u.setClipPath(h)),h.setShape({x:s[l],y:0,width:s[l+1]-s[l],height:r[1]})}this._updateDataInfo(t)},P3.prototype._updateDataInfo=function(t){var e,n,i=this.dataZoomModel,o=this._displayables,r=o.handleLabels,a=this._orient,s=["",""],l=(i.get("showDetail")&&(i=i.findRepresentativeAxisProxy())&&(e=i.getAxisModel().axis,n=this._range,t=t?i.calculateDataWindow({start:n[0],end:n[1]}).valueWindow:i.getDataValueWindow(),s=[this._formatLabel(t[0],e),this._formatLabel(t[1],e)]),Ar(this._handleEnds.slice()));function u(t){var e=Gc(o.handles[t].parent,this.group),n=Hc(0===t?"right":"left",e),i=this._handleWidth/2+5,i=Wc([l[t]+(0===t?-i:i),this._size[1]/2],e);r[t].setStyle({x:i[0],y:i[1],verticalAlign:a===C3?"middle":n,align:a===C3?n:"center",text:s[t]})}u.call(this,0),u.call(this,1)},P3.prototype._formatLabel=function(t,e){var n=this.dataZoomModel,i=n.get("labelFormatter"),n=n.get("labelPrecision"),e=(null!=n&&"auto"!==n||(n=e.getPixelPrecision()),null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(n,20)));return D(i)?i(t,e):H(i)?i.replace("{value}",e):e},P3.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)},P3.prototype._onDragMove=function(t,e,n,i){this._dragging=!0,Le(i.event);i=Wc([e,n],this._displayables.sliderGroup.getLocalTransform(),!0),e=this._updateInterval(t,i[0]),n=this.dataZoomModel.get("realtime");this._updateView(!n),e&&n&&this._dispatchZoomAction(!0)},P3.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1),this.dataZoomModel.get("realtime")||this._dispatchZoomAction(!1)},P3.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,t=this._updateInterval("all",t[0]-e),this._updateView(),t&&this._dispatchZoomAction(!1))},P3.prototype._onBrushStart=function(t){var e=t.offsetX,t=t.offsetY;this._brushStart=new E(e,t),this._brushing=!0,this._brushStartTime=+new Date},P3.prototype._onBrushEnd=function(t){var e,n,i;this._brushing&&(e=this._displayables.brushRect,this._brushing=!1,e)&&(e.attr("ignore",!0),e=e.shape,+new Date-this._brushStartTime<200&&Math.abs(e.width)<5||(n=this._getViewExtent(),this._range=Ar([Cr(e.x,n,i=[0,100],!0),Cr(e.x+e.width,n,i,!0)]),this._handleEnds=[e.x,e.x+e.width],this._updateView(),this._dispatchZoomAction(!1)))},P3.prototype._onBrush=function(t){this._brushing&&(Le(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},P3.prototype._updateBrushRect=function(t,e){var n=this._displayables,i=this.dataZoomModel,o=n.brushRect,i=(o||(o=n.brushRect=new T3({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1),this._brushStart),n=this._displayables.sliderGroup,t=n.transformCoordToLocal(t,e),e=n.transformCoordToLocal(i.x,i.y),n=this._size;t[0]=Math.max(Math.min(n[0],t[0]),0),o.setShape({x:e[0],y:0,width:t[0]-e[0],height:n[1]})},P3.prototype._dispatchZoomAction=function(t){var e=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?k3:null,start:e[0],end:e[1]})},P3.prototype._findCoordRect=function(){var t,e,n=UB(this.dataZoomModel).infoList;return t=(t=!t&&n.length?(n=n[0].model.coordinateSystem).getRect&&n.getRect():t)?t:{x:.2*(n=this.api.getWidth()),y:.2*(e=this.api.getHeight()),width:.6*n,height:.6*e}},P3.type="dataZoom.slider",P3);function P3(){var t=null!==I3&&I3.apply(this,arguments)||this;return t.type=P3.type,t._displayables={},t}function O3(t){return"vertical"===t?"ns-resize":"ew-resize"}function N3(t){t.registerComponentModel(S3),t.registerComponentView(L3),_3(t)}r(function(t){r(b3),r(N3)});var R3=["rect","polygon","keep","clear"];function E3(t,e){var n,i,o,r=Jr(t?t.brush:[]);r.length&&(n=[],nt(r,function(t){t=t.hasOwnProperty("toolbox")?t.toolbox:[];t instanceof Array&&(n=n.concat(t))}),(r=B(r=t&&t.toolbox)?r[0]:r)||(t.toolbox=[r={feature:{}}]),r=(t=r.feature||(r.feature={})).brush||(t.brush={}),(t=r.type||(r.type=[])).push.apply(t,n),o={},nt(i=t,function(t){o[t]=1}),i.length=0,nt(o,function(t,e){i.push(e)}),e)&&!t.length&&t.push.apply(t,R3)}var z3=nt;function V3(t){if(t)for(var e in t)if(t.hasOwnProperty(e))return 1}function B3(e,t,o){var r={};return z3(t,function(n){var i=r[n]=(t.prototype.__hidden=t.prototype,new t);function t(){}z3(e[n],function(t,e){QT.isValidType(e)&&(t={type:e,visual:t},o&&o(t,n),i[e]=new QT(t),"opacity"===e)&&((t=S(t)).type="colorAlpha",i.__hidden.__alphaForOpacity=new QT(t))})}),r}function F3(e,n,t){var i;nt(t,function(t){n.hasOwnProperty(t)&&V3(n[t])&&(i=!0)}),i&&nt(t,function(t){n.hasOwnProperty(t)&&V3(n[t])?e[t]=S(n[t]):delete e[t]})}var G3={lineX:W3(0),lineY:W3(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])&&i_(n.range,t[0],t[1])},rect:function(t,e,n){var i,o,r,a,s,n=n.range;return!(!t||n.length<=1)&&(i=t.x,o=t.y,r=t.width,a=t.height,s=n[0],!!(i_(n,i,o)||i_(n,i+r,o)||i_(n,i,o+a)||i_(n,i+r,o+a)||U.create(t).contain(s[0],s[1])||qc(i,o,i+r,o,n)||qc(i,o,i,o+a,n)||qc(i+r,o,i+r,o+a,n)||qc(i,o+a,i+r,o+a,n))||void 0)}}};function W3(i){var o=["x","y"],r=["width","height"];return{point:function(t,e,n){if(t)return n=n.range,H3(t[i],n)},rect:function(t,e,n){if(t)return n=n.range,(t=[t[o[i]],t[o[i]]+t[r[i]]])[1]<t[0]&&t.reverse(),H3(t[0],n)||H3(t[1],n)||H3(n[0],t)||H3(n[1],t)}}}function H3(t,e){return e[0]<=t&&t<=e[1]}var Y3=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],X3=(U3.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,n=J3[t.brushType](0,n,e),t.__rangeOffset={offset:tF[t.brushType](n.values,t.range,[1,1]),xyMinMax:n.xyMinMax})}),t},U3.prototype.matchOutputRanges=function(t,i,o){nt(t,function(n){var t=this.findTargetInfo(n,i);t&&!0!==t&&nt(t.coordSyses,function(t){var e=J3[n.brushType](1,t,n.range,!0);o(n,e.values,t,i)})},this)},U3.prototype.setInputRanges=function(t,i){nt(t,function(t){var e,n=this.findTargetInfo(t,i);t.range=t.range||[],n&&!0!==n&&(t.panelId=n.panelId,n=J3[t.brushType](0,n.coordSys,t.coordRange),e=t.__rangeOffset,t.range=e?tF[t.brushType](n.values,e.offset,function(t,e){t=nF(t),e=nF(e),t=[t[0]/e[0],t[1]/e[1]];return isNaN(t[0])&&(t[0]=1),isNaN(t[1])&&(t[1]=1),t}(n.xyMinMax,e.xyMinMax)):n.values)},this)},U3.prototype.makePanelOpts=function(n,i){return V(this._targetInfoList,function(t){var e=t.getPanelRect();return{panelId:t.panelId,defaultBrushType:i?i(t):null,clipPath:sO(e),isTargetByCursor:uO(e,n,t.coordSysModel),getLinearBrushOtherExtent:lO(e)}})},U3.prototype.controlSeries=function(t,e,n){t=this.findTargetInfo(t,n);return!0===t||t&&0<=G(t.coordSyses,e.coordinateSystem)},U3.prototype.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=j3(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<K3.length;s++)if(K3[s](i,r))return r}return!0},U3);function U3(t,e,n){var i=this,o=(this._targetInfoList=[],j3(e,t));nt(q3,function(t,e){n&&n.include&&!(0<=G(n.include,e))||t(o,i._targetInfoList)})}function Z3(t){return t[0]>t[1]&&t.reverse(),t}function j3(t,e){return ca(t,e,{includeMainTypes:Y3})}var q3={grid:function(t,i){var o=t.xAxisModels,r=t.yAxisModels,t=t.gridModels,e=R(),a={},s={};(o||r||t)&&(nt(o,function(t){t=t.axis.grid.model;e.set(t.id,t),a[t.id]=!0}),nt(r,function(t){t=t.axis.grid.model;e.set(t.id,t),s[t.id]=!0}),nt(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=[];nt(e.getCartesians(),function(t,e){(0<=G(o,t.getAxis("x").model)||0<=G(r,t.getAxis("y").model))&&n.push(t)}),i.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:n[0],coordSyses:n,getPanelRect:$3.grid,xAxisDeclared:a[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,n){nt(t.geoModels,function(t){var e=t.coordinateSystem;n.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:e,coordSyses:[e],getPanelRect:$3.geo})})}},K3=[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}],$3={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Gc(t)),e}},J3={lineX:P(Q3,0),lineY:P(Q3,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),t=t?e.pointToData([n[0][1],n[1][1]],i):e.dataToPoint([n[0][1],n[1][1]],i),e=[Z3([o[0],t[0]]),Z3([o[1],t[1]])];return{values:e,xyMinMax:e}},polygon:function(e,n,t,i){var o=[[1/0,-1/0],[1/0,-1/0]];return{values:V(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 Q3(t,e,n,i){var o=n.getAxis(["x","y"][t]),n=Z3(V([0,1],function(t){return e?o.coordToData(o.toLocalCoord(i[t]),!0):o.toGlobalCoord(o.dataToCoord(i[t]))})),r=[];return r[t]=n,r[1-t]=[NaN,NaN],{values:n,xyMinMax:r}}var tF={lineX:P(eF,0),lineY:P(eF,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 V(t,function(t,e){return[t[0]-i[0]*n[e][0],t[1]-i[1]*n[e][1]]})}};function eF(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function nF(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}var iF=["inBrush","outOfBrush"],oF="__ecBrushSelect",rF="__ecInBrushSelectEvent";function aF(e){e.eachComponent({mainType:"brush"},function(t){(t.brushTargetManager=new X3(t.option,e)).setInputRanges(t.areas,e)})}function sF(c,t,e){var o,r,n,i,a,s,l=[];c.eachComponent({mainType:"brush"},function(t){e&&"takeGlobalCursor"===e.type&&t.setBrushOption("brush"===e.key?e.brushOption:{brushType:!1})}),aF(c),c.eachComponent({mainType:"brush"},function(u,t){var y={brushId:u.id,brushIndex:t,brushName:u.name,areas:S(u.areas),selected:[]},e=(l.push(y),u.option),n=e.brushLink,i=[],m=[],v=[],x=!1,h=(t||(o=e.throttleType,r=e.throttleDelay),V(u.areas,function(t){var e,n,i,o=hF[t.brushType],o=z({boundingRect:o?o(t):void 0},t);return o.selectors=(n=(e=o).brushType,i={point:function(t){return G3[n].point(t,i,e)},rect:function(t){return G3[n].rect(t,i,e)}}),o})),_=B3(u.option,iF,function(t){t.mappingMethod="fixed"});function b(t){return"all"===n||i[t]}function w(t){return!!t.length}B(n)&&nt(n,function(t){i[t]=1}),c.eachSeries(function(t,e){var n,i,o,r,a,s,l=v[e]=[];"parallel"===t.subType?(a=e,s=(r=t).coordinateSystem,x=x||s.hasAxisBrushed(),b(a)&&s.eachActiveState(r.getData(),function(t,e){"active"===t&&(m[e]=1)})):(a=e,i=l,(n=t).brushSelector&&!function(t,e){t=t.option.seriesIndex;return null!=t&&"all"!==t&&(B(t)?G(t,e)<0:e!==t)}(u,a)&&(nt(h,function(t){u.brushTargetManager.controlSeries(t,n,c)&&i.push(t),x=x||w(i)}),b(a))&&w(i)&&(o=n.getData()).each(function(t){uF(n,i,o,t)&&(m[t]=1)}))}),c.eachSeries(function(e,t){var s,l,u,h,c,p,d,n={seriesId:e.id,seriesIndex:t,seriesName:e.name,dataIndex:[]},i=(y.selected.push(n),v[t]),o=e.getData(),r=b(t)?function(t){return m[t]?(n.dataIndex.push(o.getRawIndex(t)),"inBrush"):"outOfBrush"}:function(t){return uF(e,i,o,t)?(n.dataIndex.push(o.getRawIndex(t)),"inBrush"):"outOfBrush"};function g(t){return Hm(l,p,t)}function f(t,e){Xm(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,g,f)}}(b(t)?x:w(i))&&(s=_,l=o,u=r,d={},nt(iF,function(t){var e=QT.prepareVisualTypes(s[t]);d[t]=e}),null==c?l.each(a):l.each([c],a))})}),t=t,n=o,i=r,a=l,(s=e)&&!(s=t.getZr())[rF]&&(s[oF]||(s[oF]=lF),pm(s,oF,i,n)(t,a))}function lF(t,e){var n;t.isDisposed()||((n=t.getZr())[rF]=!0,t.dispatchAction({type:"brushSelect",batch:e}),n[rF]=!1)}function uF(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 hF={rect:function(t){return cF(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&&cF(o)}};function cF(t){return new U(t[0][0],t[1][0],t[0][1]-t[0][0],t[1][1]-t[1][0])}u(gF,pF=Ky),gF.prototype.init=function(t,e){this.ecModel=t,this.api=e,this.model,(this._brushController=new DP(e.getZr())).on("brush",T(this._onBrush,this)).mount()},gF.prototype.render=function(t,e,n,i){this.model=t,this._updateController(t,e,n,i)},gF.prototype.updateTransform=function(t,e,n,i){aF(e),this._updateController(t,e,n,i)},gF.prototype.updateVisual=function(t,e,n,i){this.updateTransform(t,e,n,i)},gF.prototype.updateView=function(t,e,n,i){this._updateController(t,e,n,i)},gF.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())},gF.prototype.dispose=function(){this._brushController.dispose()},gF.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:S(n),$from:e}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:e,areas:S(n),$from:e})},gF.type="brush";var pF,dF=gF;function gF(){var t=null!==pF&&pF.apply(this,arguments)||this;return t.type=gF.type,t}u(mF,fF=g),mF.prototype.optionUpdated=function(t,e){var n=this.option,e=(e||F3(n,t,["inBrush","outOfBrush"]),n.inBrush=n.inBrush||{});n.outOfBrush=n.outOfBrush||{color:"#ddd"},e.hasOwnProperty("liftZ")||(e.liftZ=5)},mF.prototype.setAreas=function(t){t&&(this.areas=V(t,function(t){return vF(this.option,t)},this))},mF.prototype.setBrushOption=function(t){this.brushOption=vF(this.option,t),this.brushType=this.brushOption.brushType},mF.type="brush",mF.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],mF.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};var fF,yF=mF;function mF(){var t=null!==fF&&fF.apply(this,arguments)||this;return t.type=mF.type,t.areas=[],t.brushOption={},t}function vF(t,e){return d({brushType:t.brushType,brushMode:t.brushMode,transformable:t.transformable,brushStyle:new kp(t.brushStyle).getItemStyle(),removeOnClick:t.removeOnClick,z:t.z},e,!0)}function xF(){}var _F={};function bF(t,e){_F[t]=e}function wF(t){return _F[t]}var SF,MF=["rect","polygon","lineX","lineY","keep","clear"],IF=(u(TF,SF=xF),TF.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,nt(e.get("type",!0),function(t){e.setIconStatus(t,("keep"===t?"multiple"===o:"clear"===t?r:t===i)?"emphasis":"normal")})},TF.prototype.updateView=function(t,e,n){this.render(t,e,n)},TF.prototype.getIcons=function(){var t=this.model,e=t.get("icon",!0),n={};return nt(t.get("type",!0),function(t){e[t]&&(n[t]=e[t])}),n},TF.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}})},TF.getDefaultOption=function(t){return{show:!0,type:MF.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"])}},TF);function TF(){return null!==SF&&SF.apply(this,arguments)||this}r(function(t){t.registerComponentView(dF),t.registerComponentModel(yF),t.registerPreprocessor(E3),t.registerVisual(t.PRIORITY.VISUAL.BRUSH,sF),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"},Bt),t.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},Bt),bF("brush",IF)});var CF,DF=function(t,e,n){t=S((AF[t]||{})[e]);return n&&B(t)?t[t.length-1]:t},AF={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]}},kF=QT.mapVisual,LF=QT.eachVisual,PF=B,OF=nt,NF=Ar,RF=Cr,bp=(u(EF,CF=g),EF.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},EF.prototype.optionUpdated=function(t,e){var n=this.option;e||F3(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},EF.prototype.resetVisual=function(t){var e=this.stateList;t=T(t,this),this.controllerVisuals=B3(this.option.controller,e,t),this.targetVisuals=B3(this.option.target,e,t)},EF.prototype.getItemSymbol=function(){return null},EF.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,n=[];return null==t||"all"===t?this.ecModel.eachSeries(function(t,e){n.push(e)}):n=Jr(t),n},EF.prototype.eachTargetSeries=function(e,n){nt(this.getTargetSeriesIndices(),function(t){t=this.ecModel.getSeriesByIndex(t);t&&e.call(n,t)},this)},EF.prototype.isTargetSeries=function(e){var n=!1;return this.eachTargetSeries(function(t){t===e&&(n=!0)}),n},EF.prototype.formatValueText=function(t,e,n){var i,o=this.option,r=o.precision,a=this.dataBound,o=o.formatter,e=(n=n||["<",">"],B(t)&&(t=t.slice(),i=!0),e?t:i?[s(t[0]),s(t[1])]:s(t));return H(o)?o.replace("{value}",i?e[0]:e).replace("{value2}",i?e[1]:e):D(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))}},EF.prototype.resetExtent=function(){var t=this.option,t=NF([t.min,t.max]);this._dataExtent=t},EF.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}},EF.prototype.getExtent=function(){return this._dataExtent.slice()},EF.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={}),u=(d(i,t),d(o,t),this.isCategory());function r(t){PF(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]={},OF(e,function(t,e){var n;QT.isValidType(e)&&null!=(n=DF(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";OF(this.stateList,function(t){var e,n=this.itemSize,i=o[t],t=(null==(i=i||(o[t]={color:u?s:[s]})).symbol&&(i.symbol=r&&S(r)||(u?l:[l])),null==i.symbolSize&&(i.symbolSize=a&&S(a)||(u?n[0]:[n[0],n[0]])),i.symbol=kF(i.symbol,function(t){return"none"===t?l:t}),i.symbolSize);null!=t&&(e=-1/0,LF(t,function(t){e<t&&(e=t)}),i.symbolSize=kF(t,function(t){return RF(t,[0,e],[0,n[0]],!0)}))},this)}.call(this,o)},EF.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},EF.prototype.isCategory=function(){return!!this.option.categories},EF.prototype.setSelected=function(t){},EF.prototype.getSelected=function(){return null},EF.prototype.getValueState=function(t){return null},EF.prototype.getVisualMeta=function(t){return null},EF.type="visualMap",EF.dependencies=["series"],EF.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},EF);function EF(){var t=null!==CF&&CF.apply(this,arguments)||this;return t.type=EF.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}var zF,VF=[20,140],BF=(u(FF,zF=bp),FF.prototype.optionUpdated=function(t,e){zF.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(t){t.mappingMethod="linear",t.dataExtent=this.getExtent()}),this._resetRange()},FF.prototype.resetItemSize=function(){zF.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;null!=t[0]&&!isNaN(t[0])||(t[0]=VF[0]),null!=t[1]&&!isNaN(t[1])||(t[1]=VF[1])},FF.prototype._resetRange=function(){var t=this.getExtent(),e=this.option.range;!e||e.auto?(t.auto=1,this.option.range=t):B(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(){zF.prototype.completeVisualOption.apply(this,arguments),nt(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=Ar((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=GF(0,0,this.getExtent()),e=GF(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=Np(bp.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);function FF(){var t=null!==zF&&zF.apply(this,arguments)||this;return t.type=FF.type,t}function GF(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}u(HF,WF=Ky),HF.prototype.init=function(t,e){this.ecModel=t,this.api=e},HF.prototype.render=function(t,e,n,i){!1===(this.visualMapModel=t).get("show")?this.group.removeAll():this.doRender(t,e,n,i)},HF.prototype.renderBackground=function(t){var e=this.visualMapModel,n=vd(e.get("padding")||0),i=t.getBoundingRect();t.add(new L({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")}}))},HF.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 nt(QT.prepareVisualTypes(u),function(t){var e=u[t];o.convertOpacityToAlpha&&"opacity"===t&&(t="colorAlpha",e=u.__alphaForOpacity),QT.dependsOn(t,i)&&e&&e.applyVisual(n,s,l)}),a[i]},HF.prototype.positionGroup=function(t){var e=this.visualMapModel,n=this.api;Pd(t,e.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()})},HF.prototype.doRender=function(t,e,n,i){},HF.type="visualMap";var WF,e=HF;function HF(){var t=null!==WF&&WF.apply(this,arguments)||this;return t.type=HF.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}var YF=[["left","right","width"],["top","bottom","height"]];function XF(t,e,n){var i=t.option,t=i.align;if(null!=t&&"auto"!==t)return t;for(var t={width:e.getWidth(),height:e.getHeight()},o="horizontal"===i.orient?1:0,r=YF[o],a=[0,null,10],s={},l=0;l<3;l++)s[YF[1-o][l]]=a[l],s[r[l]]=2===l?n[0]:i[r[l]];var e=[["x","width",3],["y","height",0]][o],u=Ld(s,t,i.padding);return r[(u.margin[e[2]]||0)+u[e[0]]+.5*u[e[1]]<.5*t[e[1]]?0:1]}function UF(t,e){return nt(t||[],function(t){null!=t.dataIndex&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),t}var ZF,jF=Cr,qF=nt,KF=Math.min,$F=Math.max,JF=(u(QF,ZF=e),QF.prototype.init=function(t,e){ZF.prototype.init.call(this,t,e),this._hoverLinkFromSeriesMouseOver=T(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=T(this._hideIndicator,this)},QF.prototype.doRender=function(t,e,n,i){i&&"selectDataRange"===i.type&&i.from===this.uid||this._buildView()},QF.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,e=this.group,t=(this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(e),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)},QF.prototype._renderEndsText=function(t,e,n){var i,o,r;e&&(e=null!=(e=e[1-n])?e+"":"",o=(i=this.visualMapModel).get("textGap"),i=i.itemSize,r=this._shapes.mainGroup,i=this._applyTransform([i[0]/2,0===n?-o:i[1]+o],r),o=this._applyTransform(0===n?"bottom":"top",r),n=this._orient,r=this.visualMapModel.textStyleModel,this.group.add(new K({style:ap(r,{x:i[0],y:i[1],verticalAlign:"horizontal"===n?"middle":o,align:"horizontal"===n?o:"center",text:e})})))},QF.prototype._renderBar=function(t){var e=this.visualMapModel,n=this._shapes,i=e.itemSize,o=this._orient,r=this._useHandle,a=XF(e,this.api,i),a=n.mainGroup=this._createBarGroup(a),s=new Z,s=(a.add(s),s.add(n.outOfRange=t4()),s.add(n.inRange=t4(null,r?n4(this._orient):null,T(this._dragHandle,this,"all",!1),T(this._dragHandle,this,"all",!0))),s.setClipPath(new L({shape:{x:0,y:0,width:i[0],height:i[1],r:3}})),e.textStyleModel.getTextRect("å½")),s=$F(s.width,s.height);r&&(n.handleThumbs=[],n.handleLabels=[],n.handleLabelPoints=[],this._createHandle(e,a,0,i,s,o),this._createHandle(e,a,1,i,s,o)),this._createIndicator(e,a,i,s,o),t.add(a)},QF.prototype._createHandle=function(t,e,n,i,o,r){var a=T(this._dragHandle,this,n,!1),s=T(this._dragHandle,this,n,!0),l=er(t.get("handleSize"),i[0]),u=s0(t.get("handleIcon"),-l/2,-l/2,l,l,null,!0),h=n4(this._orient),i=(u.attr({cursor:h,draggable:!0,drift:a,ondragend:s,onmousemove:function(t){Le(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(),Au(u,!0),e.add(u),this.visualMapModel.textStyleModel),t=new K({cursor:h,draggable:!0,drift:a,onmousemove:function(t){Le(t.event)},ondragend:s,style:ap(i,{x:0,y:0,text:""})}),e=(t.ensureState("blur").style={opacity:.1},t.stateTransition={duration:200},this.group.add(t),[l,0]),h=this._shapes;h.handleThumbs[n]=u,h.handleLabelPoints[n]=e,h.handleLabels[n]=t},QF.prototype._createIndicator=function(t,e,n,i,o){var r=er(t.get("indicatorSize"),n[0]),r=s0(t.get("indicatorIcon"),-r/2,-r/2,r,r,null,!0),t=(r.attr({cursor:"move",invisible:!0,silent:!0,x:n[0]/2}),t.getModel("indicatorStyle").getItemStyle()),a=(r instanceof ll?(a=r.style,r.useStyle(F({image:a.image,x:a.x,y:a.y,width:a.width,height:a.height},t))):r.useStyle(t),e.add(r),this.visualMapModel.textStyleModel),t=new K({silent:!0,invisible:!0,style:ap(a,{x:0,y:0,text:""})}),e=(this.group.add(t),[("horizontal"===o?i/2:6)+n[0]/2,0]),a=this._shapes;a.indicator=r,a.indicatorLabel=t,a.indicatorLabelPoint=e,this._firstShowIndicator=!0},QF.prototype._dragHandle=function(t,e,n,i){this._useHandle&&(this._dragging=!e,e||(n=this._applyTransform([n,i],this._shapes.mainGroup,!0),this._updateInterval(t,n[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():e4(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1))},QF.prototype._resetInterval=function(){var t=this.visualMapModel,e=this._dataInterval=t.getSelected(),n=t.getExtent(),t=[0,t.itemSize[1]];this._handleEnds=[jF(e[0],n,t,!0),jF(e[1],n,t,!0)]},QF.prototype._updateInterval=function(t,e){var n=this.visualMapModel,i=this._handleEnds,o=[0,n.itemSize[1]],e=(JL(e=e||0,i,o,t,0),n.getExtent());this._dataInterval=[jF(i[0],o,e,!0),jF(i[1],o,e,!0)]},QF.prototype._updateView=function(t){var e=this.visualMapModel,n=e.getExtent(),i=this._shapes,e=[0,e.itemSize[1]],t=t?e:this._handleEnds,o=this._createBarVisual(this._dataInterval,n,t,"inRange"),n=this._createBarVisual(n,n,e,"outOfRange");i.inRange.setStyle({fill:o.barColor}).setShape("points",o.barPoints),i.outOfRange.setStyle({fill:n.barColor}).setShape("points",n.barPoints),this._updateHandle(t,o)},QF.prototype._createBarVisual=function(t,e,n,i){var i={forceState:i,convertOpacityToAlpha:!0},o=this._makeColorGradient(t,i),t=[this.getControllerVisual(t[0],"symbolSize",i),this.getControllerVisual(t[1],"symbolSize",i)],i=this._createBarPoints(n,t);return{barColor:new ic(0,0,0,1,o),barPoints:i,handlesColor:[o[0].color,o[o.length-1].color]}},QF.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},QF.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]]]},QF.prototype._createBarGroup=function(t){var e=this._orient,n=this.visualMapModel.get("inverse");return new Z("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})},QF.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(),qF([0,1],function(t){var e=s[t],n=(e.setStyle("fill",o.handlesColor[t]),e.y=i[t],jF(i[t],[0,u[1]],h,!0)),n=this.getControllerVisual(n,"symbolSize"),n=(e.scaleX=e.scaleY=n/u[0],e.x=u[0]-n/2,Wc(r.handleLabelPoints[t],Gc(e,this.group)));l[t].setStyle({x:n[0],y:n[1],text:a.formatValueText(this._dataInterval[t]),verticalAlign:"middle",align:"vertical"===this._orient?this._applyTransform("left",r.mainGroup):"center"})},this))},QF.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"),t=jF(t,r,s,!0),r=a[0]-c/2,s={x:u.x,y:u.y},a=(u.y=t,u.x=r,Wc(l.indicatorLabelPoint,Gc(u,this.group))),c=l.indicatorLabel,l=(c.attr("invisible",!1),this._applyTransform("left",l.mainGroup)),p="horizontal"===this._orient,n=(c.setStyle({text:(n||"")+o.formatValueText(e),verticalAlign:p?l:"middle",align:p?"center":l}),{x:r,y:t,style:{fill:h}}),e={style:{x:a[0],y:a[1]}},d=(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator?(p={duration:100,easing:"cubicInOut",additive:!0},u.x=s.x,u.y=s.y,u.animateTo(n,p),c.animateTo(e,p)):(u.attr(n),c.attr(e)),this._firstShowIndicator=!1,this._shapes.handleLabels);if(d)for(var g=0;g<d.length;g++)this.api.enterBlur(d[g])}},QF.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]=KF($F(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()})},QF.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()},QF.prototype._doHoverLinkToSeries=function(t,e){var n,i,o,r=this.visualMapModel,a=r.itemSize;function s(t,e,n){for(var i=0,o=t.length;i<o;i++){var r=ra(t[i].seriesId,null);if(null==r)return;for(var a=Jr(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 l(t,e){var n,i,o=[];for(n in t)t.hasOwnProperty(n)&&null!=t[n]&&(e?o.push(+n):(i=l(t[n],!0)).length&&o.push({seriesId:n,dataIndex:i}));return o}r.option.hoverLink&&(a=[0,a[1]],i=r.getExtent(),n=[(t=KF($F(a[0],t),a[1]))-(o=function(t,e,n){var i=6,t=t.get("hoverLinkDataSize");t&&(i=jF(t,e,n,!0)/2);return i}(r,i,a)),t+o],t=jF(t,a,i,!0),i=[jF(n[0],a,i,!0),jF(n[1],a,i,!0)],n[0]<a[0]&&(i[0]=-1/0),a[1]<n[1]&&(i[1]=1/0),e&&(i[0]===-1/0?this._showIndicator(t,i[1],"< ",o):i[1]===1/0?this._showIndicator(t,i[0],"> ",o):this._showIndicator(t,t,"â ",o)),a=this._hoverLinkDataIndices,n=[],(e||e4(r))&&(n=this._hoverLinkDataIndices=r.findTargetDataIndices(i)),t=n,o={},s(a||[],e={}),s(t||[],o,e),i=[l(e),l(o)],this._dispatchHighDown("downplay",UF(i[0],r)),this._dispatchHighDown("highlight",UF(i[1],r)))},QF.prototype._hoverLinkFromSeriesMouseOver=function(t){var e,n;jm(t.target,function(t){t=$(t);return null!=t.dataIndex&&(e=t,1)},!0),e&&(t=this.ecModel.getSeriesByIndex(e.seriesIndex),(n=this.visualMapModel).isTargetSeries(t))&&(n=(t=t.getData(e.dataType)).getStore().get(n.getDataDimensionIndex(t),e.dataIndex),isNaN(n)||this._showIndicator(n,n))},QF.prototype._hideIndicator=function(){var t=this._shapes,e=(t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0),this._shapes.handleLabels);if(e)for(var n=0;n<e.length;n++)this.api.leaveBlur(e[n])},QF.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",UF(t,this.visualMapModel)),t.length=0},QF.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},QF.prototype._applyTransform=function(t,e,n,i){e=Gc(e,i?null:this.group);return(B(t)?Wc:Hc)(t,e,n)},QF.prototype._dispatchHighDown=function(t,e){e&&e.length&&this.api.dispatchAction({type:t,batch:e})},QF.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},QF.type="visualMap.continuous",QF);function QF(){var t=null!==ZF&&ZF.apply(this,arguments)||this;return t.type=QF.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}function t4(t,e,n,i){return new Lh({shape:{points:t},draggable:!!n,cursor:e,drift:n,onmousemove:function(t){Le(t.event)},ondragend:i})}function e4(t){var e=t.get("hoverLinkOnHandle");return null==e?t.get("realtime"):e}function n4(t){return"vertical"===t?"ns-resize":"ew-resize"}function i4(e,t){t.eachComponent({mainType:"visualMap",query:e},function(t){t.setSelected(e.selected)})}var o4={type:"selectDataRange",event:"dataRangeSelected",update:"update"},r4=[{createOnAllSeries:!0,reset:function(n,t){var i=[];return t.eachComponent("visualMap",function(t){var g,f,y,m,e=n.pipelineContext;!t.isTargetSeries(n)||e&&e.large||i.push((e=t.stateList,g=t.targetVisuals,f=T(t.getValueState,t),y=t.getDataDimensionIndex(n.getData()),m={},nt(e,function(t){var e=QT.prepareVisualTypes(g[t]);m[t]=e}),{progress:function(t,n){var e,i;function o(t){return Hm(n,i,t)}function r(t,e){Xm(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=f(l),u=g[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(T(a4,null,n,t))||{stops:[],outerColors:[]},0<=(t=t.getDataDimensionIndex(i)))&&(e.dimension=t,o.push(e))}),n.getData().setVisual("visualMeta",o)}}];function a4(t,e,n,i){for(var o=e.targetVisuals[i],r=QT.prepareVisualTypes(o),a={color:Ym(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 s4=nt;function l4(t){t=t&&t.visualMap;B(t)||(t=t?[t]:[]),s4(t,function(t){t&&(u4(t,"splitList")&&!u4(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList),t=t.pieces)&&B(t)&&s4(t,function(t){O(t)&&(u4(t,"start")&&!u4(t,"min")&&(t.min=t.start),u4(t,"end"))&&!u4(t,"max")&&(t.max=t.end)})})}function u4(t,e){return t&&t.hasOwnProperty&&t.hasOwnProperty(e)}var h4=!1;function c4(e){h4||(h4=!0,e.registerSubTypeDefaulter("visualMap",function(t){return t.categories||(t.pieces?0<t.pieces.length:0<t.splitNumber)&&!t.calculable?"piecewise":"continuous"}),e.registerAction(o4,i4),nt(r4,function(t){e.registerVisual(e.PRIORITY.VISUAL.COMPONENT,t)}),e.registerPreprocessor(l4))}function p4(t){t.registerComponentModel(BF),t.registerComponentView(JF),c4(t)}u(f4,d4=bp),f4.prototype.optionUpdated=function(t,e){d4.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode(),i=(this._pieceList=[],y4[this._mode].call(this,this._pieceList),this._resetSelected(t,e),this.option.categories);this.resetVisual(function(t,e){"categories"===n?(t.mappingMethod="category",t.categories=S(i)):(t.dataExtent=this.getExtent(),t.mappingMethod="piecewise",t.pieceList=V(this._pieceList,function(t){return t=S(t),"inRange"!==e&&(t.visual=null),t}))})},f4.prototype.completeVisualOption=function(){var i=this.option,n={},t=QT.listVisualTypes(),o=this.isCategory();function r(t,e,n){return t&&t[e]&&t[e].hasOwnProperty(n)}nt(i.pieces,function(e){nt(t,function(t){e.hasOwnProperty(t)&&(n[t]=1)})}),nt(n,function(t,e){var n=!1;nt(this.stateList,function(t){n=n||r(i,t,e)||r(i.target,t,e)},this),n||nt(this.stateList,function(t){(i[t]||(i[t]={}))[e]=DF(e,"inRange"===t?"active":"inactive",o)})},this),d4.prototype.completeVisualOption.apply(this,arguments)},f4.prototype._resetSelected=function(t,e){var n,i=this.option,o=this._pieceList,r=(e?i:t).selected||{};i.selected=r,nt(o,function(t,e){t=this.getSelectedMapKey(t);r.hasOwnProperty(t)||(r[t]=!0)},this),"single"===i.selectedMode&&(n=!1,nt(o,function(t,e){t=this.getSelectedMapKey(t);r[t]&&(n?r[t]=!1:n=!0)},this))},f4.prototype.getItemSymbol=function(){return this.get("itemSymbol")},f4.prototype.getSelectedMapKey=function(t){return"categories"===this._mode?t.value+"":t.index+""},f4.prototype.getPieceList=function(){return this._pieceList},f4.prototype._determineMode=function(){var t=this.option;return t.pieces&&0<t.pieces.length?"pieces":this.option.categories?"categories":"splitNumber"},f4.prototype.setSelected=function(t){this.option.selected=S(t)},f4.prototype.getValueState=function(t){t=QT.findPieceIndex(t,this._pieceList);return null!=t&&this.option.selected[this.getSelectedMapKey(this._pieceList[t])]?"inRange":"outOfRange"},f4.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){QT.findPieceIndex(t,r)===i&&n.push(e)},this),o.push({seriesId:t.id,dataIndex:n})},this),o},f4.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},f4.prototype.getVisualMeta=function(i){var o,r,a,t,e,n;if(!this.isCategory())return o=[],r=["",""],(t=(a=this)._pieceList.slice()).length?((e=t[0].interval[0])!==-1/0&&t.unshift({interval:[-1/0,e]}),(e=t[t.length-1].interval[1])!==1/0&&t.push({interval:[e,1/0]})):t.push({interval:[-1/0,1/0]}),n=-1/0,nt(t,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}),n=(e=e||a.getValueState(n),i(n,e));t[0]===-1/0?r[0]=n:t[1]===1/0?r[1]=n:o.push({value:t[0],color:n},{value:t[1],color:n})}},f4.type="visualMap.piecewise",f4.defaultOption=Np(bp.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});var d4,g4=f4;function f4(){var t=null!==d4&&d4.apply(this,arguments)||this;return t.type=f4.type,t._pieceList=[],t}var y4={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]}),Hr(t),nt(t,function(t,e){t.index=e,t.text=this.formatValueText(t.interval)},this)},categories:function(e){var t=this.option;nt(t.categories,function(t){e.push({text:this.formatValueText(t,!0),value:t})},this),m4(t,e)},pieces:function(c){var t=this.option;nt(t.pieces,function(t,e){e={text:"",index:e};if(null!=(t=O(t)?t:{value:t}).label&&(e.text=t.label),t.hasOwnProperty("value")){var n=e.value=t.value;e.interval=[n,n],e.close=[1,1]}else{for(var i=e.interval=[],o=e.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]&&(e.value=i[0])}e.visual=QT.retrieveVisuals(t),c.push(e)},this),m4(t,c),Hr(c),nt(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 m4(t,e){var n=t.inverse;("vertical"===t.orient?!n:n)&&e.reverse()}u(_4,v4=e),_4.prototype.doRender=function(){var i=this.group,o=(i.removeAll(),this.visualMapModel),r=o.get("textGap"),t=o.textStyleModel,a=t.getFont(),s=t.getTextColor(),l=this._getItemAlign(),u=o.itemSize,t=this._getViewData(),e=t.endsText,h=wt(o.get("showLabel",!0),!e);e&&this._renderEndsText(i,e[0],u,h,l),nt(t.viewPieceList,function(t){var e=t.piece,n=new Z,t=(n.onclick=T(this._onItemClick,this,e),this._enableHoverLink(n,t.indexInModelPieceList),o.getRepresentValue(e));this._createItemSymbol(n,t,[0,0,u[0],u[1]]),h&&(t=this.visualMapModel.getValueState(t),n.add(new K({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),e&&this._renderEndsText(i,e[1],u,h,l),kd(o.get("orient"),i,o.get("itemGap")),this.renderBackground(i),this.positionGroup(i)},_4.prototype._enableHoverLink=function(t,n){var i=this,e=(t.on("mouseover",function(){return e("highlight")}).on("mouseout",function(){return e("downplay")}),function(t){var e=i.visualMapModel;e.option.hoverLink&&i.api.dispatchAction({type:t,batch:UF(e.findTargetDataIndices(n),e)})})},_4.prototype._getItemAlign=function(){var t=this.visualMapModel,e=t.option;return"vertical"===e.orient?XF(t,this.api,t.itemSize):(t=e.align)&&"auto"!==t?t:"left"},_4.prototype._renderEndsText=function(t,e,n,i,o){var r,a;e&&(r=new Z,a=this.visualMapModel.textStyleModel,r.add(new K({style:ap(a,{x:i?"right"===o?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?o:"center",text:e})})),t.add(r))},_4.prototype._getViewData=function(){var t=this.visualMapModel,e=V(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}},_4.prototype._createItemSymbol=function(t,e,n){t.add(s0(this.getControllerVisual(e,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(e,"color")))},_4.prototype._onItemClick=function(t){var n,i,e=this.visualMapModel,o=e.option,r=o.selectedMode;r&&(n=S(o.selected),i=e.getSelectedMapKey(t),"single"===r||!0===r?(n[i]=!0,nt(n,function(t,e){n[e]=e===i})):n[i]=!n[i],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:n}))},_4.type="visualMap.piecewise";var v4,x4=_4;function _4(){var t=null!==v4&&v4.apply(this,arguments)||this;return t.type=_4.type,t}function b4(t){t.registerComponentModel(g4),t.registerComponentView(x4),c4(t)}r(function(t){r(p4),r(b4)});u(M4,w4=Ia),M4.type="dataZoom.select";var w4,S4=M4;function M4(){var t=null!==w4&&w4.apply(this,arguments)||this;return t.type=M4.type,t}u(C4,I4=n0),C4.type="dataZoom.select";var I4,T4=C4;function C4(){var t=null!==I4&&I4.apply(this,arguments)||this;return t.type=C4.type,t}function D4(t){t.registerComponentModel(S4),t.registerComponentView(T4),_3(t)}u(L4,A4=g),L4.prototype.optionUpdated=function(){A4.prototype.optionUpdated.apply(this,arguments);var n=this.ecModel;nt(this.option.feature,function(t,e){e=wF(e);e&&(e.getDefaultOption&&(e.defaultOption=e.getDefaultOption(n)),d(t,e.defaultOption))})},L4.type="toolbox",L4.layoutMode={type:"box",ignoreSize:!0},L4.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}};var A4,k4=L4;function L4(){var t=null!==A4&&A4.apply(this,arguments)||this;return t.type=L4.type,t}u(N4,P4=Ky),N4.prototype.render=function(p,d,g,f){var y,m,v,x,_,t,e,n,i,o,r,b=this.group;function a(t,e){var n,t=_[t],e=_[e],i=v[t],o=new kp(i,p,p.ecModel);if(f&&null!=f.newTitle&&f.featureName===t&&(i.title=f.newTitle),t&&!e){if(0===t.indexOf("my"))n={onclick:o.option.onclick,featureName:t};else{i=wF(t);if(!i)return;n=new i}x[t]=n}else if(!(n=x[e]))return;n.uid=Op("toolbox-feature"),n.model=o,n.ecModel=d,n.api=g;var r,a,s,l,u,h,c,i=n instanceof xF;!t&&e?i&&n.dispose&&n.dispose(d,g):!o.get("show")||i&&n.unusable?i&&n.remove&&n.remove(d,g):(a=n,e=t,u=(r=o).getModel("iconStyle"),h=r.getModel(["emphasis","iconStyle"]),i=a instanceof xF&&a.getIcons?a.getIcons():r.get("icon"),t=r.get("title")||{},H(i)?(s={})[e]=i:s=i,H(t)?(l={})[e]=t:l=t,c=r.iconPaths={},nt(s,function(t,e){var n=jc(t,{},{x:-y/2,y:-y/2,width:y,height:y});n.setStyle(u.getItemStyle());n.ensureState("emphasis").style=h.getItemStyle();var i=new K({style:{text:l[e],align:h.get("textAlign"),borderRadius:h.get("textBorderRadius"),padding:h.get("textPadding"),fill:null,font:pp({fontStyle:h.get("textFontStyle"),fontFamily:h.get("textFontFamily"),fontSize:h.get("textFontSize"),fontWeight:h.get("textFontWeight")},d)},ignore:!0});n.setTextContent(i),$c({el:n,componentModel:p,itemName:e,formatterParamsExtra:{title:l[e]}}),n.__title=l[e],n.on("mouseover",function(){var t=h.getItemStyle(),e=m?null==p.get("right")&&"right"!==p.get("left")?"right":"left":null==p.get("bottom")&&"bottom"!==p.get("top")?"bottom":"top";i.setStyle({fill:h.get("textFill")||t.fill||t.stroke||"#000",backgroundColor:h.get("textBackgroundColor")}),n.setTextConfig({position:h.get("textPosition")||e}),i.ignore=!p.get("showTitle"),g.enterEmphasis(this)}).on("mouseout",function(){"emphasis"!==r.get(["iconStatus",e])&&g.leaveEmphasis(this),i.hide()}),("emphasis"===r.get(["iconStatus",e])?cu:pu)(n),b.add(n),n.on("click",T(a.onclick,a,d,g,e)),c[e]=n}),o.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&("emphasis"===e?cu:pu)(i[t])},n instanceof xF&&n.render&&n.render(o,d,g,f))}b.removeAll(),p.get("show")&&(y=+p.get("itemSize"),m="vertical"===p.get("orient"),v=p.get("feature")||{},x=this._features||(this._features={}),_=[],nt(v,function(t,e){_.push(e)}),new i1(this._featureNames||[],_).add(a).update(a).remove(P(a,null)).execute(),this._featureNames=_,t=b,n=g,i=(e=p).getBoxLayoutParams(),o=e.get("padding"),n={width:n.getWidth(),height:n.getHeight()},r=Ld(i,n,o),kd(e.get("orient"),t,e.get("itemGap"),r.width,r.height),Pd(t,i,n,o),b.add(kz(b.getBoundingRect(),p)),m||b.eachChild(function(t){var e,n,i=t.__title,o=t.ensureState("emphasis"),o=o.textConfig||(o.textConfig={}),r=t.getTextContent(),r=r&&r.ensureState("emphasis");r&&!D(r)&&i&&(r=r.style||(r.style={}),i=$o(i,K.makeFont(r)),e=t.x+b.x,n=!1,t.y+b.y+y+i.height>g.getHeight()&&(o.position="top",n=!0),t=n?-5-i.height:y+10,e+i.width/2>g.getWidth()?(o.position=["100%",t],r.align="right"):e-i.width/2<0&&(o.position=[0,t],r.align="left"))}))},N4.prototype.updateView=function(t,e,n,i){nt(this._features,function(t){t instanceof xF&&t.updateView&&t.updateView(t.model,e,n,i)})},N4.prototype.remove=function(e,n){nt(this._features,function(t){t instanceof xF&&t.remove&&t.remove(e,n)}),this.group.removeAll()},N4.prototype.dispose=function(e,n){nt(this._features,function(t){t instanceof xF&&t.dispose&&t.dispose(e,n)})},N4.type="toolbox";var P4,O4=N4;function N4(){return null!==P4&&P4.apply(this,arguments)||this}u(z4,R4=xF),z4.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",e=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")}),t=w.browser;if(D(MouseEvent)&&(t.newEdge||!t.ie&&!t.edge)){var t=document.createElement("a"),a=(t.download=i+"."+r,t.target="_blank",t.href=e,new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1}));t.dispatchEvent(a)}else if(window.navigator.msSaveOrOpenBlob||o){var t=e.split(","),a=-1<t[0].indexOf("base64"),s=o?decodeURIComponent(t[1]):t[1],o=(a&&(s=window.atob(s)),i+"."+r);if(window.navigator.msSaveOrOpenBlob){for(var l=s.length,u=new Uint8Array(l);l--;)u[l]=s.charCodeAt(l);t=new Blob([u]);window.navigator.msSaveOrOpenBlob(t,o)}else{a=document.createElement("iframe"),r=(document.body.appendChild(a),a.contentWindow),t=r.document;t.open("image/svg+xml","replace"),t.write(s),t.close(),r.focus(),t.execCommand("SaveAs",!0,o),document.body.removeChild(a)}}else{r=n.get("lang"),t='<body style="margin:0;"><img src="'+e+'" style="max-width:100%;" title="'+(r&&r[0]||"")+'" /></body>',o=window.open();o.document.write(t),o.document.title=i}},z4.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"])}};var R4,E4=z4;function z4(){return null!==R4&&R4.apply(this,arguments)||this}var V4,B4="__ec_magicType_stack__",F4=[["line","bar"],["stack"]],G4=(u(W4,V4=xF),W4.prototype.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return nt(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n},W4.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:{}}},W4.prototype.onclick=function(t,e,a){var s,n,l=this.model,i=l.get(["seriesIndex",a]);H4[a]&&(s={series:[]},nt(F4,function(t){0<=G(t,a)&&nt(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,e=H4[a](e,n,t,l),n=(e&&(z(e,t.option),s.series.push(e)),t.coordinateSystem);if(n&&"cartesian2d"===n.type&&("line"===a||"bar"===a)){e=n.getAxesByScale("ordinal")[0];if(e){var i=e.dim+"Axis",o=t.getReferringComponents(i,da).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"===(t=a)&&(n=d({stack:l.option.title.tiled,tiled:l.option.title.stack},l.option.title),"emphasis"!==l.get(["iconStatus",a]))&&(t="tiled"),e.dispatchAction({type:"changeMagicType",currentType:t,newOption:s,newTitle:n,featureName:"magicType"}))},W4);function W4(){return null!==V4&&V4.apply(this,arguments)||this}var H4={line:function(t,e,n,i){if("bar"===t)return d({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 d({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")===B4;if("line"===t||"bar"===t)return i.setIconStatus("stack",n?"normal":"emphasis"),d({id:e,stack:n?"":B4},i.get(["option","stack"])||{},!0)}},Y4=(Uv({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),new Array(60).join("-")),X4="\t";function U4(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):r).push(t)});var o,r,a,h,t={seriesGroupByCategoryAxis:o,other:r,meta:a};return{value:pt([(h=[],nt(t.seriesGroupByCategoryAxis,function(t,e){for(var n=t.categoryAxis,i=t.valueAxis.dim,o=[" "].concat(V(t.series,function(t){return t.name})),r=[n.model.getCategories()],a=(nt(t.series,function(t){var e=t.getRawData();r.push(t.getRawData().mapArray(e.mapDimension(i),function(t){return t}))}),[o.join(X4)]),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(X4))}h.push(a.join("\n"))}),h.join("\n\n"+Y4+"\n\n")),V(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+X4:"")+r.join(X4))}),o.join("\n")}).join("\n\n"+Y4+"\n\n")],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join("\n\n"+Y4+"\n\n"),meta:t.meta}}function Z4(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var j4=new RegExp("["+X4+"]+","g");function q4(t,o){var t=t.split(new RegExp("\n*"+Y4+"\n*","g")),r={series:[]};return nt(t,function(t,e){var n,i;0<=t.slice(0,t.indexOf("\n")).indexOf(X4)?(i=function(t){for(var e=t.split(/\n+/g),n=[],i=V(Z4(e.shift()).split(j4),function(t){return{name:t,data:[]}}),o=0;o<e.length;o++){var r=Z4(e[o]).split(j4);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),n=(e=o[e]).axisDim+"Axis",e&&(r[n]=r[n]||[],r[n][e.axisIndex]={data:i.categories},r.series=r.series.concat(i.series))):(i=function(t){for(var e=t.split(/\n+/g),t=Z4(e.shift()),n=[],i=0;i<e.length;i++){var o=Z4(e[i]);if(o){for(var r,a=o.split(j4),s=void 0,o=!1,s=isNaN(a[0])?(o=!0,r=a[0],a=a.slice(1),n[i]={name:r,value:[]},n[i].value):n[i]=[],l=0;l<a.length;l++)s.push(+a[l]);1===s.length&&(o?n[i].value=s[0]:n[i]=s[0])}}return{name:t,data:n}}(t),r.series.push(i))}),r}u(J4,K4=xF),J4.prototype.onclick=function(t,e){setTimeout(function(){e.dispatchAction({type:"hideTip"})});var n=e.getDom(),i=this.model,o=(this._dom&&n.removeChild(this._dom),document.createElement("div")),r=(o.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",o.style.backgroundColor=i.get("backgroundColor")||"#fff",document.createElement("h4")),a=i.get("lang")||[],s=(r.innerHTML=a[0]||i.get("title"),r.style.cssText="margin:10px 20px",r.style.color=i.get("textColor"),document.createElement("div")),l=document.createElement("textarea"),u=(s.style.cssText="overflow:auto",i.get("optionToContent")),h=i.get("contentToOption"),t=U4(t),c=(D(u)?H(p=u(e.getOption()))?s.innerHTML=p:mt(p)&&s.appendChild(p):(l.readOnly=i.get("readOnly"),(p=l.style).cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",p.color=i.get("textColor"),p.borderColor=i.get("textareaBorderColor"),p.backgroundColor=i.get("textareaColor"),l.value=t.value,s.appendChild(l)),t.meta),p=document.createElement("div"),t=(p.style.cssText="position:absolute;bottom:5px;left:0;right:0","float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px"),d=document.createElement("div"),g=document.createElement("div"),f=(t=(t+=";background-color:"+i.get("buttonColor"))+(";color:"+i.get("buttonTextColor")),this);function y(){n.removeChild(o),f._dom=null}ke(d,"click",y),ke(g,"click",function(){if(!(null==h&&null!=u||null!=h&&null==u)){var t;try{t=D(h)?h(s,e.getOption()):q4(l.value,c)}catch(t){throw y(),new Error("Data view format error "+t)}t&&e.dispatchAction({type:"changeDataView",newOption:t})}y()}),d.innerHTML=a[1],g.innerHTML=a[2],g.style.cssText=d.style.cssText=t,i.get("readOnly")||p.appendChild(g),p.appendChild(d),o.appendChild(r),o.appendChild(s),o.appendChild(p),s.style.height=n.clientHeight-80+"px",n.appendChild(o),this._dom=o},J4.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},J4.prototype.dispose=function(t,e){this.remove(t,e)},J4.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"}};var K4,$4=J4;function J4(){return null!==K4&&K4.apply(this,arguments)||this}Uv({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,o){var r=[];nt(t.newOption.series,function(t){var e,i,n=o.getSeriesByName(t.name)[0];n?(n=n.get("data"),r.push({name:t.name,data:(e=t.data,i=n,V(e,function(t,e){var n,e=i&&i[e];return O(e)&&!B(e)&&(O(t)&&!B(t)||(t={value:t}),n=null!=e.name&&null==t.name,t=z(t,e),n)&&delete t.name,t}))})):r.push(F({type:"scatter"},t))}),o.mergeOption(z({series:r},t.newOption))});var Q4=nt,tG=i();function eG(t){t=tG(t);return t.snapshots||(t.snapshots=[{}]),t.snapshots}u(oG,nG=xF),oG.prototype.onclick=function(t,e){tG(t).snapshots=null,e.dispatchAction({type:"restore",from:this.uid})},oG.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"])}};var nG,iG=oG;function oG(){return null!==nG&&nG.apply(this,arguments)||this}Uv({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var rG,aG=nt,sG=(u(lG,rG=xF),lG.prototype.render=function(t,e,n,i){this._brushController||(this._brushController=new DP(n.getZr()),this._brushController.on("brush",T(this._onBrush,this)).mount());var o=t,r=e,a=this,s=a._isZoomActive;i&&"takeGlobalCursor"===i.type&&(s="dataZoomSelect"===i.key&&i.dataZoomSelectActive),a._isZoomActive=s,o.setIconStatus("zoom",s?"emphasis":"normal"),i=new X3(hG(o),r,{include:["grid"]}).makePanelOpts(n,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"}),a._brushController.setPanels(i).enableBrush(!(!s||!i.length)&&{brushType:"auto",brushStyle:o.getModel("brushStyle").getItemStyle()}),t.setIconStatus("back",1<function(t){return eG(t).length}(e)?"emphasis":"normal")},lG.prototype.onclick=function(t,e,n){uG[n].call(this)},lG.prototype.remove=function(t,e){this._brushController&&this._brushController.unmount()},lG.prototype.dispose=function(t,e){this._brushController&&this._brushController.dispose()},lG.prototype._onBrush=function(t){var s,l,o,r,e=t.areas;function i(t,e,n){var i,o,r,e=e.getAxis(t),a=e.model,t=(i=t,o=a,l.eachComponent({mainType:"dataZoom",subType:"select"},function(t){t.getAxisModel(i,o.componentIndex)&&(r=t)}),r),a=t.findRepresentativeAxisProxy(a).getMinMaxSpan();null==a.minValueSpan&&null==a.maxValueSpan||(n=JL(0,n.slice(),e.scale.getExtent(),0,a.minValueSpan,a.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 X3(hG(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))}),t=s,r=eG(o=l),Q4(t,function(t,e){for(var n,i=r.length-1;0<=i&&!r[i][e];i--);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(t),this._dispatchZoomAction(s))},lG.prototype._dispatchZoomAction=function(t){var n=[];aG(t,function(t,e){n.push(S(t))}),n.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:n})},lG.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)"}}},lG);function lG(){return null!==rG&&rG.apply(this,arguments)||this}var uG={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){var t,i,o;this._dispatchZoomAction((t=this.ecModel,i=eG(t),t=i[i.length-1],1<i.length&&i.pop(),o={},Q4(t,function(t,e){for(var n=i.length-1;0<=n;n--)if(t=i[n][e]){o[e]=t;break}}),o))}};function hG(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}function cG(e,t){var n;return nt(t,function(t){null!=e[t]&&"auto"!==e[t]&&(n=!0)}),n}Cp="dataZoom",$m=function(t){var i,o,e=t.getComponent("toolbox",0),n=["feature","dataZoom"];if(e&&null!=e.get(n))return i=e.getModel(n),o=[],e=ca(t,hG(i)),aG(e.xAxisModels,function(t){return r(t,"xAxis","xAxisIndex")}),aG(e.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)}},Tt(null==sg.get(Cp)&&$m),sg.set(Cp,$m),r(function(t){t.registerComponentModel(k4),t.registerComponentView(O4),bF("saveAsImage",E4),bF("magicType",G4),bF("dataView",$4),bF("dataZoom",sG),bF("restore",iG),r(D4)});var pG=["transition","enterFrom","leaveTo"],dG=pG.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function gG(t,e,n){if(n&&(!t[n]&&e[n]&&(t[n]={}),t=t[n],e=e[n]),t&&e)for(var i=n?pG:dG,o=0;o<i.length;o++){var r=i[o];null==t[r]&&null!=e[r]&&(t[r]=e[r])}}u(mG,fG=g),mG.prototype.mergeOption=function(t,e){var n=this.option.elements;this.option.elements=null,fG.prototype.mergeOption.call(this,t,e),this.option.elements=n},mG.prototype.optionUpdated=function(t,e){var n=this.option,t=(e?n:t).elements,l=n.elements=e?[]:n.elements,e=[],t=(this._flatten(t,e,null),na(l,e,"normalMerge")),u=this._elOptionsToUpdate=[];nt(t,function(t,e){var n,i,o,r,a,s=t.newOption;s&&(u.push(s),r=s,n=(t=t).existing,r.id=t.keyInfo.id,!r.type&&n&&(r.type=n.type),null==r.parentId&&((t=r.parentOption)?r.parentId=t.id:n&&(r.parentId=n.parentId)),r.parentOption=null,t=l,n=e,a=F({},r=s),i=t[n],"merge"===(o=r.$action||"merge")?i?(d(i,a,!0),Nd(i,a,{ignoreSize:!0}),Ed(r,i),gG(r,i),gG(r,i,"shape"),gG(r,i,"style"),gG(r,i,"extra"),r.clipPath=i.clipPath):t[n]=a:"replace"===o?t[n]=a:"remove"===o&&i&&(t[n]=null),r=l[e],a=s,r)&&(r.hv=a.hv=[cG(a,["left","right"]),cG(a,["top","bottom"])],"group"===r.type)&&(a=a,null==(r=r).width&&(r.width=a.width=0),null==r.height)&&(r.height=a.height=0)},this),n.elements=pt(l,function(t){return t&&delete t.$action,null!=t})},mG.prototype._flatten=function(t,n,i){nt(t,function(t){var e;t&&(i&&(t.parentOption=i),n.push(t),(e=t.children)&&e.length&&this._flatten(e,n,t),delete t.children)},this)},mG.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},mG.type="graphic",mG.defaultOption={elements:[]};var fG,yG=mG;function mG(){var t=null!==fG&&fG.apply(this,arguments)||this;return t.type=mG.type,t.preventAutoZ=!0,t}var vG,xG={path:null,compoundPath:null,group:Z,image:ll,text:K},_G=i(),bG=(u(wG,vG=Ky),wG.prototype.init=function(){this._elMap=R()},wG.prototype.render=function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},wG.prototype._updateElements=function(d){var g,f,y,m,t=d.useElOptionsToUpdate();t&&(g=this._elMap,f=this.group,y=d.get("z"),m=d.get("zlevel"),nt(t,function(t){var e,n,i,o=ra(t.id,null),r=null!=o?g.get(o):null,a=ra(t.parentId,null),a=null!=a?g.get(a):f,s=t.type,l=t.style,u=("text"===s&&l&&t.hv&&t.hv[1]&&(l.textVerticalAlign=l.textBaseline=l.verticalAlign=l.align=null),t.textContent),h=t.textConfig,s=(l&&JN(l,s,!!h,!!u)&&(l=QN(l,s,!0),!h&&l.textConfig&&(h=t.textConfig=l.textConfig),!u)&&l.textContent&&(u=l.textContent),e=F({},e=t),nt(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(Cd),function(t){delete e[t]}),e),l=t.$action||"merge",c="merge"===l,p="replace"===l,a=(c?((i=!(n=r))?n=MG(o,a,t.type,g):(n&&(_G(n).isNew=!1),xR(n)),n&&(lR(n,s,d,{isInit:i}),TG(n,t,y,m))):p?(IG(r,t,g,d),(n=MG(o,a,t.type,g))&&(lR(n,s,d,{isInit:!0}),TG(n,t,y,m))):"remove"===l&&(uR(r,t),IG(r,t,g,d)),g.get(o));a&&u&&(c?(s=a.getTextContent())?s.attr(u):a.setTextContent(new K(u)):p&&a.setTextContent(new K(u))),a&&((n=t.clipPath)&&(l=n.type,r=void 0,i=!1,c?r=(i=!(o=a.getClipPath())||_G(o).type!==l)?SG(l):o:p&&(i=!0,r=SG(l)),a.setClipPath(r),lR(r,n,d,{isInit:i}),_R(r,n.keyframeAnimation,d)),s=_G(a),a.setTextConfig(h),s.option=t,u=d,c=t,p=$(o=a).eventData,(p=o.silent||o.ignore?p:p||($(o).eventData={componentType:"graphic",componentIndex:u.componentIndex,name:o.name}))&&(p.info=c.info),$c({el:a,componentModel:d,itemName:a.name,itemTooltipOption:t.tooltip}),_R(a,t.keyframeAnimation,d))}))},wG.prototype._relocate=function(t,e){for(var n,i,o=t.option.elements,r=this.group,a=this._elMap,s=e.getWidth(),l=e.getHeight(),u=["x","y"],h=0;h<o.length;h++)(d=null!=(p=ra((c=o[h]).id,null))?a.get(p):null)&&d.isGroup&&(n=(g=d.parent)===r,i=_G(d),f=_G(g),i.width=j(i.option.width,n?s:f.width)||0,i.height=j(i.option.height,n?l:f.height)||0);for(var c,p,d,h=o.length-1;0<=h;h--)if(d=null!=(p=ra((c=o[h]).id,null))?a.get(p):null){var g=d.parent,f=_G(g),y={},m=Pd(d,c,g===r?{width:s,height:l}:{width:f.width,height:f.height},null,{hv:c.hv,boundingMode:c.bounding},y);if(!_G(d).isNew&&m){for(var v=c.transition,x={},_=0;_<u.length;_++){var b=u[_],w=y[b];v&&(cR(v)||0<=G(v,b))?x[b]=w:d[b]=w}C(d,x,t,0)}else d.attr(y)}},wG.prototype._clear=function(){var e=this,n=this._elMap;n.each(function(t){IG(t,_G(t).option,n,e._lastGraphicModel)}),this._elMap=R()},wG.prototype.dispose=function(){this._clear()},wG.type="graphic",wG);function wG(){var t=null!==vG&&vG.apply(this,arguments)||this;return t.type=wG.type,t}function SG(t){var e=new(X(xG,t)?xG[t]:Oc(t))({});return _G(e).type=t,e}function MG(t,e,n,i){n=SG(n);return e.add(n),i.set(t,n),_G(n).id=t,_G(n).isNew=!0,n}function IG(t,e,n,i){t&&t.parent&&("group"===t.type&&t.traverse(function(t){IG(t,e,n,i)}),hR(t,e,i),n.removeKey(_G(t).id))}function TG(n,i,t,e){n.isGroup||nt([["cursor",ts.prototype.cursor],["zlevel",e||0],["z",t||0],["z2",0]],function(t){var e=t[0];X(i,e)?n[e]=N(i[e],t[1]):null==n[e]&&(n[e]=t[1])}),nt(W(i),function(t){var e;0===t.indexOf("on")&&(e=i[t],n[t]=D(e)?e:null)}),X(i,"draggable")&&(n.draggable=i.draggable),null!=i.name&&(n.name=i.name),null!=i.id&&(n.id=i.id)}r(function(t){t.registerComponentModel(yG),t.registerComponentView(bG),t.registerPreprocessor(function(t){var e=t.graphic;B(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])})}),r(Ib);var CG={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},DG=(AG.prototype.evaluate=function(t){var e=typeof t;return H(e)?this._condVal.test(t):!!Y(e)&&this._condVal.test(t+"")},AG);function AG(t){null==(this._condVal=H(t)?new RegExp(t):_t(t)?t:null)&&jr("")}LG.prototype.evaluate=function(){return this.value};var kG=LG;function LG(){}OG.prototype.evaluate=function(){for(var t=this.children,e=0;e<t.length;e++)if(!t[e].evaluate())return!1;return!0};var PG=OG;function OG(){}RG.prototype.evaluate=function(){for(var t=this.children,e=0;e<t.length;e++)if(t[e].evaluate())return!0;return!1};var NG=RG;function RG(){}zG.prototype.evaluate=function(){return!this.child.evaluate()};var EG=zG;function zG(){}BG.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};var VG=BG;function BG(){}function FG(t,e){if(!0===t||!1===t)return(n=new kG).value=t,n;var n;if(WG(t)||jr(""),t.and)return GG("and",t,e);if(t.or)return GG("or",t,e);if(t.not)return n=e,WG(r=(r=t).not)||jr(""),(l=new EG).child=FG(r,n),l.child||jr(""),l;for(var i=t,o=e,r=o.prepareGetValue(i),a=[],s=W(i),l=i.parser,u=l?Wf(l):null,h=0;h<s.length;h++){var c,p=s[h];"parser"===p||o.valueGetterAttrMap.get(p)||(c=X(CG,p)?CG[p]:p,p=i[p],p=u?u(p):p,(c=function(t,e){return"eq"===t||"ne"===t?new jf("eq"===t,e):X(Hf,t)?new Yf(t,e):null}(c,p)||"reg"===c&&new DG(p))||jr(""),a.push(c))}return a.length||jr(""),(l=new VG).valueGetterParam=r,l.valueParser=u,l.getValue=o.getValue,l.subCondList=a,l}function GG(t,e,n){e=e[t],B(e)||jr(""),e.length||jr(""),t=new("and"===t?PG:NG);return t.children=V(e,function(t){return FG(t,n)}),t.children.length||jr(""),t}function WG(t){return O(t)&&!ht(t)}YG.prototype.evaluate=function(){return this._cond.evaluate()};var HG=YG;function YG(t,e){this._cond=FG(t,e)}var XG={type:"echarts:filter",transform:function(t){for(var e,n,i=t.upstream,o=(t=t.config,n={valueGetterAttrMap:R({dimension:!0}),prepareGetValue:function(t){var e=t.dimension,t=(X(t,"dimension")||jr(""),i.getDimensionInfo(e));return t||jr(""),{dimIdx:t.index}},getValue:function(t){return i.retrieveValueFromItem(e,t.dimIdx)}},new HG(t,n)),r=[],a=0,s=i.count();a<s;a++)e=i.getRawDataItem(a),o.evaluate()&&r.push(e);return{data:r}}},UG={type:"echarts:sort",transform:function(t){for(var a=t.upstream,t=t.config,t=Jr(t),s=(t.length||jr(""),[]),t=(nt(t,function(t){var e=t.dimension,n=t.order,i=t.parser,t=t.incomparable,e=(null==e&&jr(""),"asc"!==n&&"desc"!==n&&jr(""),t&&"min"!==t&&"max"!==t&&jr(""),"asc"!==n&&"desc"!==n&&jr(""),a.getDimensionInfo(e)),o=(e||jr(""),i?Wf(i):null);i&&!o&&jr(""),s.push({dimIdx:e.index,parser:o,comparator:new Uf(n,t)})}),a.sourceFormat),e=(t!==Zd&&t!==jd&&jr(""),[]),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=(i.parser&&(o=i.parser(o),r=i.parser(r)),i.comparator.evaluate(o,r));if(0!==i)return i}return 0}),{data:e}}};r(function(t){t.registerTransform(XG),t.registerTransform(UG)});var ZG=Math.sin,jG=Math.cos,qG=Math.PI,KG=2*Math.PI,$G=180/qG,JG=(QG.prototype.reset=function(t){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,t||4)},QG.prototype.moveTo=function(t,e){this._add("M",t,e)},QG.prototype.lineTo=function(t,e){this._add("L",t,e)},QG.prototype.bezierCurveTo=function(t,e,n,i,o,r){this._add("C",t,e,n,i,o,r)},QG.prototype.quadraticCurveTo=function(t,e,n,i){this._add("Q",t,e,n,i)},QG.prototype.arc=function(t,e,n,i,o,r){this.ellipse(t,e,n,n,0,i,o,r)},QG.prototype.ellipse=function(t,e,n,i,o,r,a,s){var l,u=a-r,s=!s,h=Math.abs(u),c=zi(h-KG)||(s?KG<=u:KG<=-u),p=!1,p=!!c||!zi(h)&&qG<=(0<u?u%KG:u%KG+KG)==!!s,h=t+n*jG(r),u=e+i*ZG(r),o=(this._start&&this._add("M",h,u),Math.round(o*$G));c?(c=1/this._p,this._add("A",n,i,o,1,+s,t+n*jG(r+(l=(s?1:-1)*(KG-c))),e+i*ZG(r+l)),.01<c&&this._add("A",n,i,o,0,+s,h,u)):(r=t+n*jG(a),l=e+i*ZG(a),this._add("A",n,i,o,+p,+s,r,l))},QG.prototype.rect=function(t,e,n,i){this._add("M",t,e),this._add("l",n,0),this._add("l",0,i),this._add("l",-n,0),this._add("Z")},QG.prototype.closePath=function(){0<this._d.length&&this._add("Z")},QG.prototype._add=function(t,e,n,i,o,r,a,s,l){for(var u=[],h=this._p,c=1;c<arguments.length;c++){var p=arguments[c];if(isNaN(p))return void(this._invalid=!0);u.push(Math.round(p*h)/h)}this._d.push(t+u.join(" ")),this._start="Z"===t},QG.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},QG.prototype.getStr=function(){return this._str},QG);function QG(){}var tW="none",eW=Math.round;var nW=["lineCap","miterLimit","lineJoin"],iW=V(nW,function(t){return"stroke-"+t.toLowerCase()});function oW(t,e,n,i){var o=null==e.opacity?1:e.opacity;if(n instanceof ll)t("opacity",o);else if(null!=(r=(r=e).fill)&&r!==tW?(t("fill",(r=Ei(e.fill)).color),r=null!=e.fillOpacity?e.fillOpacity*r.opacity*o:r.opacity*o,(i||r<1)&&t("fill-opacity",r)):t("fill",tW),null!=(r=(r=e).stroke)&&r!==tW){var r=Ei(e.stroke),a=(t("stroke",r.color),e.strokeNoScale?n.getLineScale():1),a=a?(e.lineWidth||0)/a:0,r=null!=e.strokeOpacity?e.strokeOpacity*r.opacity*o:r.opacity*o,o=e.strokeFirst;!i&&1==a||t("stroke-width",a),(i||o)&&t("paint-order",o?"stroke":"fill"),(i||r<1)&&t("stroke-opacity",r),e.lineDash?(o=(a=g0(n))[0],r=a[1],o&&(r=eW(r||0),t("stroke-dasharray",o.join(",")),r||i)&&t("stroke-dashoffset",r)):i&&t("stroke-dasharray",tW);for(var s=0;s<nW.length;s++){var l=nW[s];(i||e[l]!==$s[l])&&(l=e[l]||$s[l])&&t(iW[s],l)}}else i&&t("stroke",tW)}var rW="http://www.w3.org/2000/svg",aW="http://www.w3.org/1999/xlink",sW="http://www.w3.org/2000/xmlns/",lW="http://www.w3.org/XML/1998/namespace",uW="ecmeta_";function hW(t){return document.createElementNS(rW,t)}function cW(t,e,n,i,o){return{tag:t,attrs:n||{},children:i,text:o,key:e}}function pW(t,e){var r=(e=e||{}).newline?"\n":"";return function t(e){var n=e.children,i=e.tag,o=e.attrs,e=e.text;return function(t,e){var n=[];if(e)for(var i in e){var o=e[i];!1!==o&&(!0!==o&&null!=o&&(i+='="'+o+'"'),n.push(i))}return"<"+t+" "+n.join(" ")+">"}(i,o)+("style"!==i?we(e):e||"")+(n?r+V(n,t).join(r)+r:"")+"</"+i+">"}(t)}function dW(t){return{zrId:t,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function gW(t,e,n,i){return cW("svg","root",{width:t,height:e,xmlns:rW,"xmlns:xlink":aW,version:"1.1",baseProfile:"full",viewBox:!!i&&"0 0 "+t+" "+e},n)}var fW=0;var yW={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},mW="transform-origin";var vW={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function xW(t,e){var n=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[n]=t,n}function _W(t){return H(t)?yW[t]?"cubic-bezier("+yW[t]+")":ii(t)?t:"":""}function bW(A,k,L,P){var t=A.animators,e=t.length,n=[];if(A instanceof Qh){if(o=function(t,e,u){var h,c,t=t.shape.paths,p={};if(nt(t,function(t){var e=dW(u.zrId),t=(e.animation=!0,bW(t,{},e,!0),e.cssAnims),n=e.cssNodes,e=W(t),i=e.length;if(i){var o,r,a=t[c=e[i-1]];for(o in a){var s=a[o];p[o]=p[o]||{d:""},p[o].d+=s.d||""}for(r in n){var l=n[r].animation;0<=l.indexOf(c)&&(h=l)}}}),h)return e.d=!1,t=xW(p,u),h.replace(c,t)}(A,k,L))n.push(o);else if(!e)return}else if(!e)return;for(var i,o,r,a={},s=0;s<e;s++){var l=t[s],u=[l.getMaxTime()/1e3+"s"],h=_W(l.getClip().easing),c=l.getDelay(),h=(u.push(h||"linear"),c&&u.push(c/1e3+"s"),l.getLoop()&&u.push("infinite"),u.join(" "));a[h]=a[h]||[h,[]],a[h][1].push(l)}function p(t){var e=t[1],n=e.length,i={},o={},r={},g="animation-timing-function";function a(t,e,n){for(var i=t.getTracks(),o=t.getMaxTime(),r=0;r<i.length;r++){var a=i[r];if(a.needsAnimate()){var s=a.keyframes,l=a.propName;if(l=n?n(l):l)for(var u=0;u<s.length;u++){var h=s[u],c=Math.round(h.time/o*100)+"%",p=_W(h.easing),d=h.rawValue;(H(d)||Y(d))&&(e[c]=e[c]||{},e[c][l]=h.rawValue,p)&&(e[c][g]=p)}}}}for(var s,l,u=0;u<n;u++)(S=(w=e[u]).targetName)?"shape"===S&&a(w,o):P||a(w,i);for(b in i){var h={},c=(Zo(h,A),F(h,i[b]),ji(h)),p=i[b][g];r[b]=c?{transform:c}:{},c=r[b],s=void 0,s=(h=h).originX,h=h.originY,(s||h)&&(c[mW]=s+"px "+h+"px"),p&&(r[b][g]=p)}var d,f,y,m=!0;for(b in o){r[b]=r[b]||{};var v=!l,p=o[b][g],x=(l=v?new Ns:l).len(),_=(l.reset(),r[b].d=(f=o[b],y=l,_=void 0,_=F({},(d=A).shape),F(_,f),d.buildPath(y,_),(f=new JG).reset(Zi(d)),y.rebuildPath(f,1),f.generateStr(),f.getStr()),l.len());if(!v&&x!==_){m=!1;break}p&&(r[b][g]=p)}if(!m)for(var b in r)delete r[b].d;if(!P)for(var w,S,u=0;u<n;u++)"style"===(S=(w=e[u]).targetName)&&a(w,r,function(t){return vW[t]});for(var M,I=W(r),T=!0,u=1;u<I.length;u++){var C=I[u-1],D=I[u];if(r[C][mW]!==r[D][mW]){T=!1;break}M=r[C][mW]}if(T&&M){for(var b in r)r[b][mW]&&delete r[b][mW];k[mW]=M}if(pt(I,function(t){return 0<W(r[t]).length}).length)return xW(r,L)+" "+t[0]+" both"}for(i in a)(o=p(a[i]))&&n.push(o);n.length&&(r=L.zrId+"-cls-"+fW++,L.cssNodes["."+r]={animation:n.join(",")},k.class=r)}function wW(t,e,n,i){var o=JSON.stringify(t),r=n.cssStyleCache[o];r||(r=n.zrId+"-cls-"+fW++,n.cssStyleCache[o]=r,n.cssNodes["."+r+(i?":hover":"")]=t),e.class=e.class?e.class+" "+r:r}var SW=Math.round;function MW(t){return t&&H(t.src)}function IW(t){return t&&D(t.toDataURL)}function TW(i,o,r,a){oW(function(t,e){var n="fill"===t||"stroke"===t;n&&Xi(e)?EW(o,i,t,a):n&&Wi(e)?zW(r,i,t,a):i[t]=n&&"none"===e?"transparent":e},o,r,!1);var t=i,e=a;if(function(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY)}(g=(u=r).style)){var n=function(t){var e=t.style,t=t.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),t[0],t[1]].join(",")}(u),s=e.shadowCache,l=s[n];if(!l){var u=u.getGlobalScale(),h=u[0],u=u[1];if(!h||!u)return;var c=g.shadowOffsetX||0,p=g.shadowOffsetY||0,d=g.shadowBlur,g=Ei(g.shadowColor),f=g.opacity,g=g.color,d=d/2/h+" "+d/2/u;l=e.zrId+"-s"+e.shadowIdx++,e.defs[l]=cW("filter",l,{id:l,x:"-100%",y:"-100%",width:"300%",height:"300%"},[cW("feDropShadow","",{dx:c/h,dy:p/u,stdDeviation:d,"flood-color":g,"flood-opacity":f})]),s[n]=l}t.filter=Ui(l)}}function CW(n,t){var e=Sr(t);e&&(e.each(function(t,e){null!=t&&(n[(uW+e).toLowerCase()]=t+"")}),t.isSilent())&&(n[uW+"silent"]="true")}function DW(t){return zi(t[0]-1)&&zi(t[1])&&zi(t[2])&&zi(t[3]-1)}function AW(t,e,n){var i;!e||zi((i=e)[4])&&zi(i[5])&&DW(e)||(i=n?10:1e4,t.transform=DW(e)?"translate("+SW(e[4]*i)/i+" "+SW(e[5]*i)/i+")":"matrix("+Vi((n=e)[0])+","+Vi(n[1])+","+Vi(n[2])+","+Vi(n[3])+","+Bi(n[4])+","+Bi(n[5])+")")}function kW(t,e,n){for(var i=t.points,o=[],r=0;r<i.length;r++)o.push(SW(i[r][0]*n)/n),o.push(SW(i[r][1]*n)/n);e.points=o.join(" ")}function LW(t){return!t.smooth}var PW,OW={circle:[(PW=V(["cx","cy","r"],function(t){return"string"==typeof t?[t,t]:t}),function(t,e,n){for(var i=0;i<PW.length;i++){var o=PW[i],r=t[o[0]];null!=r&&(e[o[1]]=SW(r*n)/n)}})],polyline:[kW,LW],polygon:[kW,LW]};function NW(t,e){var n,i,o,r,a,s=t.style,l=t.shape,u=OW[t.type],h={},c=e.animation,p="path",d=t.style.strokePercent,g=e.compress&&Zi(t)||4;return!u||e.willUpdate||u[1]&&!u[1](l)||c&&function(t){for(var e=t.animators,n=0;n<e.length;n++)if("shape"===e[n].targetName)return 1}(t)||d<1?(c=!t.path||t.shapeChanged(),t.path||t.createPathProxy(),n=t.path,c&&(n.beginPath(),t.buildPath(n,t.shape),t.pathUpdated()),c=n.getVersion(),o=(i=t).__svgPathBuilder,i.__svgPathVersion===c&&o&&d===i.__svgPathStrokePercent||((o=o||(i.__svgPathBuilder=new JG)).reset(g),n.rebuildPath(o,d),o.generateStr(),i.__svgPathVersion=c,i.__svgPathStrokePercent=d),h.d=o.getStr()):(p=t.type,n=Math.pow(10,g),u[0](l,h,n)),AW(h,t.transform),TW(h,s,t,e),CW(h,t),e.animation&&bW(t,h,e),e.emphasis&&(c=h,i=e,(d=t).ignore||(d.isSilent()?wW(a={"pointer-events":"none"},c,i,!0):(!(g=(o=d.states.emphasis&&d.states.emphasis.style?d.states.emphasis.style:{}).fill)&&(r=d.style&&d.style.fill,u=d.states.select&&d.states.select.style&&d.states.select.style.fill,u=0<=d.currentStates.indexOf("select")&&u||r)&&(g=Ni(u)),(r=o.lineWidth)&&(r/=!o.strokeNoScale&&d.transform?d.transform[0]:1),a={cursor:"pointer"},g&&(a.fill=g),o.stroke&&(a.stroke=o.stroke),r&&(a["stroke-width"]=r),wW(a,c,i,!0)))),cW(p,t.id+"",h)}function RW(t,e){if(t instanceof q)return NW(t,e);if(t instanceof ll){var n=t,i=e,o=n.style,r=o.image;if(r&&!H(r)&&(MW(r)?r=r.src:IW(r)&&(r=r.toDataURL())),r)return a=o.x||0,s=o.y||0,r={href:r,width:o.width,height:o.height},a&&(r.x=a),s&&(r.y=s),AW(r,n.transform),TW(r,o,n,i),CW(r,n),i.animation&&bW(n,r,i),cW("image",n.id+"",r)}else if(t instanceof il){var a=t,s=e,o=a.style,i=o.text;if(null!=i&&(i+=""),i&&!isNaN(o.x)&&!isNaN(o.y)){var n=o.font||J,r=o.x||0,l=(t=o.y||0,e=tr(n),"top"===(l=o.textBaseline)?t+=e/2:"bottom"===l&&(t-=e/2),t),e={"dominant-baseline":"central","text-anchor":Fi[o.textAlign]||o.textAlign};if(Cl(o)){var t="",u=o.fontStyle,h=Il(o.fontSize);if(!parseFloat(h))return;var c=o.fontFamily||f,p=o.fontWeight;t+="font-size:"+h+";font-family:"+c+";",u&&"normal"!==u&&(t+="font-style:"+u+";"),p&&"normal"!==p&&(t+="font-weight:"+p+";"),e.style=t}else e.style="font: "+n;return i.match(/\s/)&&(e["xml:space"]="preserve"),r&&(e.x=r),l&&(e.y=l),AW(e,a.transform),TW(e,o,a,s),CW(e,a),s.animation&&bW(a,e,s),cW("text",a.id+"",e,void 0,i)}}}function EW(t,e,n,i){var o,t=t[n],r={gradientUnits:t.global?"userSpaceOnUse":"objectBoundingBox"};if(Hi(t))o="linearGradient",r.x1=t.x,r.y1=t.y,r.x2=t.x2,r.y2=t.y2;else{if(!Yi(t))return;o="radialGradient",r.cx=N(t.x,.5),r.cy=N(t.y,.5),r.r=N(t.r,.5)}for(var a=t.colorStops,s=[],l=0,u=a.length;l<u;++l){var h=100*Bi(a[l].offset)+"%",c=Ei(a[l].color),p=c.color,c=c.opacity,h={offset:h};h["stop-color"]=p,c<1&&(h["stop-opacity"]=c),s.push(cW("stop",l+"",h))}var t=pW(cW(o,"",r,s)),d=i.gradientCache,g=d[t];g||(g=i.zrId+"-g"+i.gradientIdx++,d[t]=g,r.id=g,i.defs[g]=cW(o,g,r,s)),e[n]=Ui(g)}function zW(t,e,n,i){var o,r,a,s,l,u,h,c,p=t.style[n],d=t.getBoundingRect(),g={},f=p.repeat,y="no-repeat"===f,m="repeat-x"===f,v="repeat-y"===f;Gi(p)?(r=p.imageWidth,a=p.imageHeight,f=void 0,H(h=p.image)?f=h:MW(h)?f=h.src:IW(h)&&(f=h.toDataURL()),"undefined"==typeof Image?(Tt(r,h="Image width/height must been given explictly in svg-ssr renderer."),Tt(a,h)):null!=r&&null!=a||(s=function(t,e){var n,i;t&&(n=t.elm,i=r||e.width,e=a||e.height,"pattern"===t.tag&&(m?(e=1,i/=d.width):v&&(i=1,e/=d.height)),t.attrs.width=i,t.attrs.height=e,n)&&(n.setAttribute("width",i),n.setAttribute("height",e))},(h=Na(f,null,t,function(t){y||s(u,t),s(o,t)}))&&h.width&&h.height&&(r=r||h.width,a=a||h.height)),o=cW("image","img",{href:f,width:r,height:a}),g.width=r,g.height=a):p.svgElement&&(o=S(p.svgElement),g.width=p.svgWidth,g.height=p.svgHeight),o&&(y?c=l=1:m?(l=1,c=g.width/d.width):v?(c=1,l=g.height/d.height):g.patternUnits="userSpaceOnUse",null==c||isNaN(c)||(g.width=c),null==l||isNaN(l)||(g.height=l),(t=ji(p))&&(g.patternTransform=t),h=pW(u=cW("pattern","",g,[o])),(c=(f=i.patternCache)[h])||(c=i.zrId+"-p"+i.patternIdx++,f[h]=c,g.id=c,u=i.defs[c]=cW("pattern",c,g,[o])),e[n]=Ui(c))}function VW(t){return document.createTextNode(t)}function BW(t,e,n){t.insertBefore(e,n)}function FW(t,e){t.removeChild(e)}function GW(t,e){t.appendChild(e)}function WW(t){return t.parentNode}function HW(t){return t.nextSibling}function YW(t,e){t.textContent=e}var XW=58,UW=120,ZW=cW("","");function jW(t){return void 0===t}function qW(t){return void 0!==t}function KW(t,e){var n=t.key===e.key;return t.tag===e.tag&&n}function $W(t){var e,n=t.children,i=t.tag;if(qW(i)){var o=t.elm=hW(i);if(tH(ZW,t),B(n))for(e=0;e<n.length;++e){var r=n[e];null!=r&&GW(o,$W(r))}else qW(t.text)&&!O(t.text)&&GW(o,VW(t.text))}else t.elm=VW(t.text);return t.elm}function JW(t,e,n,i,o){for(;i<=o;++i){var r=n[i];null!=r&&BW(t,$W(r),e)}}function QW(t,e,n,i){for(;n<=i;++n){var o=e[n];null!=o&&(qW(o.tag)?FW(WW(o.elm),o.elm):FW(t,o.elm))}}function tH(t,e){var n,i=e.elm,o=t&&t.attrs||{},r=e.attrs||{};if(o!==r){for(n in r){var a=r[n];o[n]!==a&&(!0===a?i.setAttribute(n,""):!1===a?i.removeAttribute(n):"style"===n?i.style.cssText=a:n.charCodeAt(0)!==UW?i.setAttribute(n,a):"xmlns:xlink"===n||"xmlns"===n?i.setAttributeNS(sW,n,a):n.charCodeAt(3)===XW?i.setAttributeNS(lW,n,a):n.charCodeAt(5)===XW?i.setAttributeNS(aW,n,a):i.setAttribute(n,a))}for(n in o)n in r||i.removeAttribute(n)}}function eH(t,e,n){for(var i,o,r,a=0,s=0,l=e.length-1,u=e[0],h=e[l],c=n.length-1,p=n[0],d=n[c];a<=l&&s<=c;)null==u?u=e[++a]:null==h?h=e[--l]:null==p?p=n[++s]:null==d?d=n[--c]:KW(u,p)?(nH(u,p),u=e[++a],p=n[++s]):KW(h,d)?(nH(h,d),h=e[--l],d=n[--c]):KW(u,d)?(nH(u,d),BW(t,u.elm,HW(h.elm)),u=e[++a],d=n[--c]):p=(KW(h,p)?(nH(h,p),BW(t,h.elm,u.elm),h=e[--l]):(jW(i)&&(i=function(t,e,n){for(var i={},o=e;o<=n;++o){var r=t[o].key;void 0!==r&&(i[r]=o)}return i}(e,a,l)),jW(o=i[p.key])||(r=e[o]).tag!==p.tag?BW(t,$W(p),u.elm):(nH(r,p),e[o]=void 0,BW(t,r.elm,u.elm))),n[++s]);(a<=l||s<=c)&&(l<a?JW(t,null==n[c+1]?null:n[c+1].elm,n,s,c):QW(t,e,a,l))}function nH(t,e){var n=e.elm=t.elm,i=t.children,o=e.children;t!==e&&(tH(t,e),jW(e.text)?qW(i)&&qW(o)?i!==o&&eH(n,i,o):qW(o)?(qW(t.text)&&YW(n,""),JW(n,null,o,0,o.length-1)):qW(i)?QW(n,i,0,i.length-1):qW(t.text)&&YW(n,""):t.text!==e.text&&(qW(i)&&QW(n,i,0,i.length-1),YW(n,e.text)))}var iH=0;function oH(t,e,n){var i;this.type="svg",this.refreshHover=rH(),this.configLayer=rH(),this.storage=e,this._opts=n=F({},n),this.root=t,this._id="zr"+iH++,this._oldVNode=gW(n.width,n.height),t&&!n.ssr&&((e=this._viewport=document.createElement("div")).style.cssText="position:relative;overflow:hidden",i=this._svgDom=this._oldVNode.elm=hW("svg"),tH(null,this._oldVNode),e.appendChild(i),t.appendChild(e)),this.resize(n.width,n.height)}function rH(){return function(){}}oH.prototype.getType=function(){return this.type},oH.prototype.getViewportRoot=function(){return this._viewport},oH.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},oH.prototype.getSvgDom=function(){return this._svgDom},oH.prototype.refresh=function(){var t,e,n,i,o;this.root&&((t=this.renderToVNode({willUpdate:!0})).attrs.style="position:absolute;left:0;top:0;user-select:none",KW(e=this._oldVNode,n=t)?nH(e,n):(o=WW(i=e.elm),$W(n),null!==o&&(BW(o,n.elm,HW(i)),QW(o,[e],0,0))),this._oldVNode=t)},oH.prototype.renderOneToVNode=function(t){return RW(t,dW(this._id))},oH.prototype.renderToVNode=function(t){t=t||{};var n,o,r,a,s,e=this.storage.getDisplayList(!0),i=this._width,l=this._height,u=dW(this._id),h=(u.animation=t.animation,u.willUpdate=t.willUpdate,u.compress=t.compress,u.emphasis=t.emphasis,[]),c=this._bgVNode=function(t,e,n,i){var o;n&&"none"!==n&&(o=cW("rect","bg",{width:t,height:e,x:"0",y:"0"}),Xi(n)?EW({fill:n},o.attrs,"fill",i):Wi(n)?zW({style:{fill:n},dirty:Bt,getBoundingRect:function(){return{width:t,height:e}}},o.attrs,"fill",i):(i=Ei(n),n=i.color,i=i.opacity,o.attrs.fill=n,i<1&&(o.attrs["fill-opacity"]=i)));return o}(i,l,this._backgroundColor,u),c=(c&&h.push(c),t.compress?null:this._mainVNode=cW("g","main",{},[])),e=(this._paintList(e,u,c?c.children:h),c&&h.push(c),V(W(u.defs),function(t){return u.defs[t]}));return e.length&&h.push(cW("defs","defs",{},e)),t.animation&&(n=u.cssNodes,o=u.cssAnims,r=(c=(c={newline:!0})||{}).newline?"\n":"",a=" {"+r,s=r+"}",c=V(W(n),function(e){return e+a+V(W(n[e]),function(t){return t+":"+n[e][t]+";"}).join(r)+s}).join(r),e=V(W(o),function(i){return"@keyframes "+i+a+V(W(o[i]),function(n){return n+a+V(W(o[i][n]),function(t){var e=o[i][n][t];return t+":"+(e="d"===t?'path("'+e+'")':e)+";"}).join(r)+s}).join(r)+s}).join(r),c=c||e?["<![CDATA[",c,e,"]]>"].join(r):"")&&(e=cW("style","stl",{},[],c),h.push(e)),gW(i,l,h,t.useViewBox)},oH.prototype.renderToString=function(t){return pW(this.renderToVNode({animation:N((t=t||{}).cssAnimation,!0),emphasis:N(t.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:N(t.useViewBox,!0)}),{newline:!0})},oH.prototype.setBackgroundColor=function(t){this._backgroundColor=t},oH.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},oH.prototype._paintList=function(t,e,n){for(var i,o,r,a,s,l,u,h=t.length,c=[],p=0,d=0,g=0;g<h;g++){var f=t[g];if(!f.invisible){for(var y=f.__clipPaths,m=y&&y.length||0,v=M&&M.length||0,x=void 0,x=Math.max(m-1,v-1);0<=x&&(!y||!M||y[x]!==M[x]);x--);for(var _=v-1;x<_;_--)i=c[--p-1];for(var b=x+1;b<m;b++){var w={},S=(o=y[b],r=w,u=S=l=s=void 0,l=(a=e).clipPathCache,S=a.defs,(u=l[o.id])||(s={id:u=a.zrId+"-c"+a.clipPathIdx++},S[l[o.id]=u]=cW("clipPath",u,s,[NW(o,a)])),r["clip-path"]=Ui(u),cW("g","clip-g-"+d++,w,[]));(i?i.children:n).push(S),i=c[p++]=S}var M=y,v=RW(f,e);v&&(i?i.children:n).push(v)}}},oH.prototype.resize=function(t,e){var n=this._opts,i=this.root,o=this._viewport;null!=t&&(n.width=t),null!=e&&(n.height=e),i&&o&&(o.style.display="none",t=d0(i,0,n),e=d0(i,1,n),o.style.display=""),this._width===t&&this._height===e||(this._width=t,this._height=e,o&&((i=o.style).width=t+"px",i.height=e+"px"),Wi(this._backgroundColor)?this.refresh():((n=this._svgDom)&&(n.setAttribute("width",t),n.setAttribute("height",e)),(o=this._bgVNode&&this._bgVNode.elm)&&(o.setAttribute("width",t),o.setAttribute("height",e))))},oH.prototype.getWidth=function(){return this._width},oH.prototype.getHeight=function(){return this._height},oH.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},oH.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},oH.prototype.toDataURL=function(t){var e=this.renderToString(),n="data:image/svg+xml;";return t?(e=qi(e))&&n+"base64,"+e:n+"charset=UTF-8,"+encodeURIComponent(e)},wr("svg",oH),t.Axis=Ip,t.ChartView=em,t.ComponentModel=g,t.ComponentView=Ky,t.List=k1,t.Model=kp,t.PRIORITY=t0,t.SeriesModel=Gy,t.color=Ci,t.connect=function(e){var t;return B(e)&&(t=e,e=null,nt(t,function(t){null!=t.group&&(e=t.group)}),e=e||"g_"+Ev++,nt(t,function(t){t.group=e})),Nv[e]=!0,e},t.dataTool={},t.dependencies={zrender:"5.5.0"},t.disConnect=Qm,t.disconnect=Vv,t.dispose=function(t){H(t)?t=Ov[t]:t instanceof vv||(t=Bv(t)),t instanceof vv&&!t.isDisposed()&&t.dispose()},t.env=w,t.extendChartView=function(t){return t=em.extend(t),em.registerClass(t),t},t.extendComponentModel=function(t){return t=g.extend(t),g.registerClass(t),t},t.extendComponentView=function(t){return t=Ky.extend(t),Ky.registerClass(t),t},t.extendSeriesModel=function(t){return t=Gy.extend(t),Gy.registerClass(t),t},t.format=Sp,t.getCoordinateSystemDimensions=function(t){if(t=Tg.get(t))return t.getDimensionsInfo?t.getDimensionsInfo():t.dimensions.slice()},t.getInstanceByDom=Bv,t.getInstanceById=function(t){return Ov[t]},t.getMap=function(t){var e=G0.getMap;return e&&e(t)},t.graphic=jp,t.helper=e0,t.init=function(t,e,n){var i=!(n&&n.ssr);if(i){var o=Bv(t);if(o)return o}return(o=new vv(t,e,n)).id="ec_"+Rv++,Ov[o.id]=o,i&&ya(t,zv,o.id),gv(o),F0.trigger("afterinit",o),o},t.innerDrawElementOnCanvas=O0,t.matrix=Ue,t.number=La,t.parseGeoJSON=v_,t.parseGeoJson=v_,t.registerAction=Uv,t.registerCoordinateSystem=Zv,t.registerLayout=jv,t.registerLoading=Jv,t.registerLocale=Gp,t.registerMap=Qv,t.registerPostInit=Hv,t.registerPostUpdate=Yv,t.registerPreprocessor=Gv,t.registerProcessor=Wv,t.registerTheme=Fv,t.registerTransform=t1,t.registerUpdateLifecycle=Xv,t.registerVisual=qv,t.setCanvasCreator=function(t){y({createCanvas:t})},t.setPlatformAPI=y,t.throttle=cm,t.time=xp,t.use=r,t.util=Wm,t.vector=se,t.version="5.5.0",t.zrUtil=Gt,t.zrender=Ir}); |