12 lines
374 KiB
JavaScript
12 lines
374 KiB
JavaScript
|
|
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(this,function(t){"use strict";function e(t){var e={},n={},i=t.match(/Firefox\/([\d.]+)/),r=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),a=t.match(/Edge\/([\d.]+)/),o=/micromessenger/i.test(t);return i&&(n.firefox=!0,n.version=i[1]),r&&(n.ie=!0,n.version=r[1]),a&&(n.edge=!0,n.version=a[1]),o&&(n.weChat=!0),{browser:n,os:e,node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!n.ie&&!n.edge,pointerEventsSupported:"onpointerdown"in window&&(n.edge||n.ie&&n.version>=11),domSupported:"undefined"!=typeof document}}function n(t,e){"createCanvas"===t&&(_p=null),yp[t]=e}function i(t){if(null==t||"object"!=typeof t)return t;var e=t,n=cp.call(t);if("[object Array]"===n){if(!N(t)){e=[];for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}else if(up[n]){if(!N(t)){var o=t.constructor;if(t.constructor.from)e=o.from(t);else{e=new o(t.length);for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}}else if(!hp[n]&&!N(t)&&!T(t)){e={};for(var s in t)t.hasOwnProperty(s)&&(e[s]=i(t[s]))}return e}function r(t,e,n){if(!S(e)||!S(t))return n?i(e):t;for(var a in e)if(e.hasOwnProperty(a)){var o=t[a],s=e[a];!S(s)||!S(o)||_(s)||_(o)||T(s)||T(o)||M(s)||M(o)||N(s)||N(o)?!n&&a in t||(t[a]=i(e[a],!0)):r(o,s,n)}return t}function a(t,e){for(var n=t[0],i=1,a=t.length;a>i;i++)n=r(n,t[i],e);return n}function o(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function s(t,e,n){for(var i in e)e.hasOwnProperty(i)&&(n?null!=e[i]:null==t[i])&&(t[i]=e[i]);return t}function l(){return _p||(_p=xp().getContext("2d")),_p}function h(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;i>n;n++)if(t[n]===e)return n}return-1}function u(t,e){function n(){}var i=t.prototype;n.prototype=e.prototype,t.prototype=new n;for(var r in i)t.prototype[r]=i[r];t.prototype.constructor=t,t.superClass=e}function c(t,e,n){t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,s(t,e,n)}function d(t){return t?"string"==typeof t?!1:"number"==typeof t.length:void 0}function f(t,e,n){if(t&&e)if(t.forEach&&t.forEach===fp)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;r>i;i++)e.call(n,t[i],i,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(n,t[a],a,t)}function p(t,e,n){if(t&&e){if(t.map&&t.map===vp)return t.map(e,n);for(var i=[],r=0,a=t.length;a>r;r++)i.push(e.call(n,t[r],r,t));return i}}function g(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===mp)return t.reduce(e,n,i);for(var r=0,a=t.length;a>r;r++)n=e.call(i,n,t[r],r,t);return n}}function v(t,e,n){if(t&&e){if(t.filter&&t.filter===pp)return t.filter(e,n);for(var i=[],r=0,a=t.length;a>r;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function m(t,e,n){if(t&&e)for(var i=0,r=t.length;r>i;i++)if(e.call(n,t[i],i,t))return t[i]}function y(t,e){var n=gp.call(arguments,2);return function(){return t.apply(e,n.concat(gp.call(arguments)))}}function x(t){var e=gp.call(arguments,1);return function(){return t.apply(this,e.concat(gp.call(arguments)))}}function _(t){return"[object Array]"===cp.call(t)}function w(t){return"function"==typeof t}function b(t){return"[object String]"===cp.call(t)}function S(t){var e=typeof t;return"function"===e||!!t&&"object"===e}function M(t){return!!hp[cp.call(t)]}function I(t){return!!up[cp.call(t)]}function T(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function C(t){return t!==t}function D(){for(var t=0,e=arguments.length;e>t;t++)if(null!=arguments[t])return arguments[t]}function A(t,e){return null!=t?t:e}function k(t,e,n){return null!=t?t:null!=e?e:n}function P(){return Function.call.apply(gp,arguments)}function L(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function O(t,e){if(!t)throw new Error(e)}function E(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\
|
||
|
|
}function pi(t,e){return null==t||0>=e||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function gi(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function vi(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function mi(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function yi(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function xi(t){t=t||{},pg.call(this,t);for(var e in t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new Cg(t.style,this),this._rect=null,this.__clipPaths=[]}function _i(t){xi.call(this,t)}function wi(t){return parseInt(t,10)}function bi(t){return t?t.__builtin__?!0:"function"!=typeof t.resize||"function"!=typeof t.refresh?!1:!0:!1}function Si(t,e,n){return $g.copy(t.getBoundingRect()),t.transform&&$g.applyTransform(t.transform),Qg.width=e,Qg.height=n,!$g.intersect(Qg)}function Mi(t,e){if(t===e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!0}function Ii(t,e){for(var n=0;n<t.length;n++){var i=t[n];i.setTransform(e),e.beginPath(),i.buildPath(e,i.shape),e.clip(),i.restoreTransform(e)}}function Ti(t,e){var n=document.createElement("div");return n.style.cssText=["position:relative","overflow:hidden","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",n}function Ci(t){return"mousewheel"===t&&lp.browser.firefox?"DOMMouseScroll":t}function Di(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}function Ai(t){var e=t.pointerType;return"pen"===e||"touch"===e}function ki(t){function e(t,e){return function(){return e._touching?void 0:t.apply(e,arguments)}}f(iv,function(e){t._handlers[e]=y(ov[e],t)}),f(av,function(e){t._handlers[e]=y(ov[e],t)}),f(nv,function(n){t._handlers[n]=e(ov[n],t)})}function Pi(t){function e(e,n){f(e,function(e){ve(t,Ci(e),n._handlers[e])},n)}kp.call(this),this.dom=t,this._touching=!1,this._touchTimer,this._handlers={},ki(this),lp.pointerEventsSupported?e(av,this):(lp.touchEventsSupported&&e(iv,this),e(nv,this))}function Li(t,e){var n=new dv(op(),t,e);return uv[n.id]=n,n}function Oi(t){if(t)t.dispose();else{for(var e in uv)uv.hasOwnProperty(e)&&uv[e].dispose();uv={}}return this}function Ei(t){return uv[t]}function Bi(t,e){hv[t]=e}function Ni(t){delete uv[t]}function zi(t){return t instanceof Array?t:null==t?[]:[t]}function Ri(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,r=n.length;r>i;i++){var a=n[i];!t.emphasis[e].hasOwnProperty(a)&&t[e].hasOwnProperty(a)&&(t.emphasis[e][a]=t[e][a])}}}function Fi(t){return!gv(t)||vv(t)||t instanceof Date?t:t.value}function Vi(t){return gv(t)&&!(t instanceof Array)}function Gi(t,e){e=(e||[]).slice();var n=p(t||[],function(t){return{exist:t}});return pv(e,function(t,i){if(gv(t)){for(var r=0;r<n.length;r++)if(!n[r].option&&null!=t.id&&n[r].exist.id===t.id+"")return n[r].option=t,void(e[i]=null);for(var r=0;r<n.length;r++){var a=n[r].exist;if(!(n[r].option||null!=a.id&&null!=t.id||null==t.name||Xi(t)||Xi(a)||a.name!==t.name+""))return n[r].option=t,void(e[i]=null)}}}),pv(e,function(t){if(gv(t)){for(var e=0;e<n.length;e++){var i=n[e].exist;if(!n[e].option&&!Xi(i)&&null==t.id){n[e].option=t;break}}e>=n.length&&n.push({option:t})}}),n}function Hi(t){var e=R();pv(t,function(t){var n=t.exist;n&&e.set(n.id,t)}),pv(t,function(t){var n=t.option;O(!n||null==n.id||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),pv(t,function(t,n){var i=t.exist,r=t.option,a=t.keyInfo;if(gv(r)){if(a.name=null!=r.name?r.name+"":i?i.name:mv+n,i)a.id=i.id;else if(null!=r.id)a.id=r.id+"";else{var o=0;do a.id="\x00"+a.name+"\x00"+o++;while(e.get(a.id))}e.set(a.id,t)}})}function Wi(t){var e=t.name;return!(!e||!e.indexOf(mv))}function Xi(t){return gv(t)&&t.id&&0===(t.id+"").indexOf("\x00_ec_\x00")}function Yi(t,e){return null!=e.dataIndexInside?e.dataIndexInside:null!=e.dataIndex
|
||
|
|
}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}function go(t){return null==t?"":(t+"").replace(_y,function(t,e){return wy[e]})}function vo(t,e,n){_(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],a=0;a<r.length;a++){var o=by[a];t=t.replace(Sy(o),Sy(o,0))}for(var s=0;i>s;s++)for(var l=0;l<r.length;l++){var h=e[s][r[l]];t=t.replace(Sy(by[l],s),n?go(h):h)}return t}function mo(t,e,n){return f(e,function(e,i){t=t.replace("{"+i+"}",n?go(e):e)}),t}function yo(t,e){t=b(t)?{color:t,extraCssText:e}:t||{};var n=t.color,i=t.type,e=t.extraCssText,r=t.renderMode||"html",a=t.markerId||"X";return n?"html"===r?"subItem"===i?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+go(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:'+go(n)+";"+(e||"")+'"></span>':{renderMode:r,content:"{marker"+a+"|} ",style:{color:n}}:""}function xo(t,e){return t+="","0000".substr(0,e-t.length)+t}function _o(t,e,n){("week"===t||"month"===t||"quarter"===t||"half-year"===t||"year"===t)&&(t="MM-dd\nyyyy");var i=ao(e),r=n?"UTC":"",a=i["get"+r+"FullYear"](),o=i["get"+r+"Month"]()+1,s=i["get"+r+"Date"](),l=i["get"+r+"Hours"](),h=i["get"+r+"Minutes"](),u=i["get"+r+"Seconds"](),c=i["get"+r+"Milliseconds"]();return t=t.replace("MM",xo(o,2)).replace("M",o).replace("yyyy",a).replace("yy",a%100).replace("dd",xo(s,2)).replace("d",s).replace("hh",xo(l,2)).replace("h",l).replace("mm",xo(h,2)).replace("m",h).replace("ss",xo(u,2)).replace("s",u).replace("SSS",xo(c,3))}function wo(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function bo(t){return Rn(t.text,t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich,t.truncate)}function So(t,e,n,i,r,a,o,s){return Rn(t,e,n,i,r,s,a,o)}function Mo(t,e,n,i,r){var a=0,o=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;e.eachChild(function(l,h){var u,c,d=l.position,f=l.getBoundingRect(),p=e.childAt(h+1),g=p&&p.getBoundingRect();if("horizontal"===t){var v=f.width+(g?-g.x+f.x:0);u=a+v,u>i||l.newline?(a=0,u=v,o+=s+n,s=f.height):s=Math.max(s,f.height)}else{var m=f.height+(g?-g.y+f.y:0);c=o+m,c>r||l.newline?(a+=s+n,o=0,c=m,s=f.width):s=Math.max(s,f.width)}l.newline||(d[0]=a,d[1]=o,"horizontal"===t?a=u+n:o=c+n)})}function Io(t,e,n){n=xy(n||0);var i=e.width,r=e.height,a=Ka(t.left,i),o=Ka(t.top,r),s=Ka(t.right,i),l=Ka(t.bottom,r),h=Ka(t.width,i),u=Ka(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(h)&&(h=i-s-d-a),isNaN(u)&&(u=r-l-c-o),null!=f&&(isNaN(h)&&isNaN(u)&&(f>i/r?h=.8*i:u=.8*r),isNaN(h)&&(h=f*u),isNaN(u)&&(u=h/f)),isNaN(a)&&(a=i-s-h-d),isNaN(o)&&(o=r-l-u-c),t.left||t.right){case"center":a=i/2-h/2-n[3];break;case"right":a=i-h-d}switch(t.top||t.bottom){case"middle":case"center":o=r/2-u/2-n[0];break;case"bottom":o=r-u-c}a=a||0,o=o||0,isNaN(h)&&(h=i-d-a-(s||0)),isNaN(u)&&(u=r-c-o-(l||0));var p=new xn(a+n[3],o+n[0],h,u);return p.margin=n,p}function To(t,e,n){function i(n,i){var o={},l=0,h={},u=0,c=2;if(Ty(n,function(e){h[e]=t[e]}),Ty(n,function(t){r(e,t)&&(o[t]=h[t]=e[t]),a(o,t)&&l++,a(h,t)&&u++}),s[i])return a(e,n[1])?h[n[2]]=null:a(e,n[2])&&(h[n[1]]=null),h;if(u!==c&&l){if(l>=c)return o;for(var d=0;d<n.length;d++){var f=n[d];if(!r(o,f)&&r(t,f)){o[f]=t[f];break}}return o}return h}function r(t,e){return t.hasOwnProperty(e)}function a(t,e){return null!=t[e]&&"auto"!==t[e]}function o(t,e,n){Ty(t,function(t){e[t]=n[t]})}!S(n)&&(n={});var s=n.ignoreSize;!_(s)&&(s=[s,s]);var l=i(Dy[0],0),h=i(Dy[1],1);o(Dy[0],t,l),o(Dy[1],t,h)}function Co(t){return Do({},t)}function Do(t,e){return e&&t&&Ty(Cy,function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function Ao(t){var e=[];return f(Ly.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=p(e,function(t){return Qi(t).main}),"dataset"!==t&&h(e,"dataset")<=0&&e.unshift("dataset"),e}function ko(t,e){for(var n=t.length,i=0;n>i;i++)if(t[i].length>e)return t[i];return t[n-1]}function Po(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSy
|
||
|
|
null!=v&&null==h.get(v)&&(m.name=m.displayName=v,h.set(v,p)),null!=g.type&&(m.type=g.type),null!=g.displayName&&(m.displayName=g.displayName)}l.each(function(t,e){if(t=zi(t).slice(),1===t.length&&t[0]<0)return void l.set(e,!1);var n=l.set(e,[]);f(t,function(t,i){b(t)&&(t=h.get(t)),null!=t&&d>t&&(n[i]=t,r(c[t],e,i))})});var y=0;f(t,function(t){var e,t,n,a;if(b(t))e=t,t={};else{e=t.name;var o=t.ordinalMeta;t.ordinalMeta=null,t=i(t),t.ordinalMeta=o,n=t.dimsDef,a=t.otherDims,t.name=t.coordDim=t.coordDimIndex=t.dimsDef=t.otherDims=null}var h=l.get(e);if(h!==!1){var h=zi(h);if(!h.length)for(var u=0;u<(n&&n.length||1);u++){for(;y<c.length&&null!=c[y].coordDim;)y++;y<c.length&&h.push(y++)}f(h,function(i,o){var l=c[i];if(r(s(l,t),e,o),null==l.name&&n){var h=n[o];!S(h)&&(h={name:h}),l.name=l.displayName=h.name,l.defaultTooltip=h.defaultTooltip}a&&s(l.otherDims,a)})}});var x=n.generateCoord,_=n.generateCoordCount,w=null!=_;_=x?_||1:0;for(var M=x||"value",I=0;d>I;I++){var m=c[I]=c[I]||{},T=m.coordDim;null==T&&(m.coordDim=Lh(M,u,w),m.coordDimIndex=0,(!x||0>=_)&&(m.isExtraCoord=!0),_--),null==m.name&&(m.name=Lh(m.coordDim,h)),null==m.type&&Xo(e,I,m.name)&&(m.type="ordinal")}return c}function Ph(t,e,n,i){var r=Math.max(t.dimensionsDetectCount||1,e.length,n.length,i||0);return f(e,function(t){var e=t.dimsDef;e&&(r=Math.max(r,e.length))}),r}function Lh(t,e,n){if(n||null!=e.get(t)){for(var i=0;null!=e.get(t+i);)i++;t+=i}return e.set(t,!0),t}function Oh(t,e,n){n=n||{};var i,r,a,o,s=n.byIndex,l=n.stackedCoordDimension,h=!(!t||!t.get("stack"));if(f(e,function(t,n){b(t)&&(e[n]=t={name:t}),h&&!t.isExtraCoord&&(s||i||!t.ordinalMeta||(i=t),r||"ordinal"===t.type||"time"===t.type||l&&l!==t.coordDim||(r=t))}),!r||s||i||(s=!0),r){a="__\x00ecstackresult",o="__\x00ecstackedover",i&&(i.createInvertedIndices=!0);var u=r.coordDim,c=r.type,d=0;f(e,function(t){t.coordDim===u&&d++}),e.push({name:a,coordDim:u,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0}),d++,e.push({name:o,coordDim:o,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0})}return{stackedDimension:r&&r.name,stackedByDimension:i&&i.name,isStackedByIndex:s,stackedOverDimension:o,stackResultDimension:a}}function Eh(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function Bh(t,e){return Eh(t,e)?t.getCalculationInfo("stackResultDimension"):e}function Nh(t,e,n){n=n||{},Oo.isInstance(t)||(t=Oo.seriesDataToSource(t));var i,r=e.get("coordinateSystem"),a=ts.get(r),o=Po(e);o&&(i=p(o.coordSysDims,function(t){var e={name:t},n=o.axisMap.get(t);if(n){var i=n.get("type");e.type=gh(i)}return e})),i||(i=a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]);var s,l,h=nw(t,{coordDimensions:i,generateCoord:n.generateCoord});o&&f(h,function(t,e){var n=t.coordDim,i=o.categoryAxisMap.get(n);i&&(null==s&&(s=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(l=!0)}),l||null==s||(h[s].otherDims.itemName=0);var u=Oh(e,h),c=new J_(h,e);c.setCalculationInfo(u);var d=null!=s&&zh(t)?function(t,e,n,i){return i===s?n:this.defaultDimValueGetter(t,e,n,i)}:null;return c.hasItemOption=!1,c.initData(t,null,d),c}function zh(t){if(t.sourceFormat===Ry){var e=Rh(t.data||[]);return null!=e&&!_(Fi(e))}}function Rh(t){for(var e=0;e<t.length&&null==t[e];)e++;return t[e]}function Fh(t){this._setting=t||{},this._extent=[1/0,-1/0],this._interval=0,this.init&&this.init.apply(this,arguments)}function Vh(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this._map}function Gh(t){return t._map||(t._map=R(t.categories))}function Hh(t){return S(t)&&null!=t.value?t.value:t+""}function Wh(t,e,n,i){var r={},a=t[1]-t[0],o=r.interval=lo(a/e,!0);null!=n&&n>o&&(o=r.interval=n),null!=i&&o>i&&(o=r.interval=i);var s=r.intervalPrecision=Xh(o),l=r.niceTickExtent=[ow(Math.ceil(t[0]/o)*o,s),ow(Math.floor(t[1]/o)*o,s)];return qh(l,t),r}function Xh(t){return to(t)+2}function Yh(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function qh(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),Yh(t,0,e),Yh(t,1,e),t[0]>t[1]&&(t[0]=
|
||
|
|
e&&d>=o&&(d=o-10),!e&&o>=d&&(d=o+10),t[s].x=n+d*a,o=d}}t.sort(function(t,e){return t.y-e.y});for(var u,c=0,d=t.length,f=[],p=[],g=0;d>g;g++)u=t[g].y-c,0>u&&s(g,d,-u,r),c=t[g].y+t[g].height;0>o-c&&l(d-1,c-o);for(var g=0;d>g;g++)t[g].y>=n?p.push(t[g]):f.push(t[g]);h(f,!1,e,n,i,r),h(p,!0,e,n,i,r)}function cd(t,e,n,i,r,a){for(var o=[],s=[],l=0;l<t.length;l++)dd(t[l])||(t[l].x<e?o.push(t[l]):s.push(t[l]));ud(s,e,n,i,1,r,a),ud(o,e,n,i,-1,r,a);for(var l=0;l<t.length;l++)if(!dd(t[l])){var h=t[l].linePoints;if(h){var u=h[1][0]-h[2][0];h[2][0]=t[l].x<e?t[l].x+3:t[l].x-3,h[1][1]=h[2][1]=t[l].y,h[1][0]=h[2][0]+u}}}function dd(t){return"center"===t.position}function fd(t){var e=t.mainData,n=t.datas;n||(n={main:e},t.datasAttr={main:"data"}),t.datas=t.mainData=null,xd(e,n,t),rS(n,function(n){rS(e.TRANSFERABLE_METHODS,function(e){n.wrapMethod(e,x(pd,t))})}),e.wrapMethod("cloneShallow",x(vd,t)),rS(e.CHANGABLE_METHODS,function(n){e.wrapMethod(n,x(gd,t))}),O(n[e.dataType]===e)}function pd(t,e){if(yd(this)){var n=o({},this[aS]);n[this.dataType]=e,xd(e,n,t)}else _d(e,this.dataType,this[oS],t);return e}function gd(t,e){return t.struct&&t.struct.update(this),e}function vd(t,e){return rS(e[aS],function(n,i){n!==e&&_d(n.cloneShallow(),i,e,t)}),e}function md(t){var e=this[oS];return null==t||null==e?e:e[aS][t]}function yd(t){return t[oS]===t}function xd(t,e,n){t[aS]={},rS(e,function(e,i){_d(e,i,t,n)})}function _d(t,e,n,i){n[aS][e]=t,t[oS]=n,t.dataType=e,i.struct&&(t[i.structAttr]=i.struct,i.struct[i.datasAttr[e]]=t),t.getLinkedData=md}function wd(t,e,n){this.root,this.data,this._nodes=[],this.hostModel=t,this.levelModels=p(e||[],function(e){return new Ha(e,t,t.ecModel)}),this.leavesModel=new Ha(n||{},t,t.ecModel)}function bd(t,e){var n=e.children;t.parentNode!==e&&(n.push(t),t.parentNode=e)}function Sd(t){t.hierNode={defaultAncestor:null,ancestor:t,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var e,n,i=[t];e=i.pop();)if(n=e.children,e.isExpand&&n.length)for(var r=n.length,a=r-1;a>=0;a--){var o=n[a];o.hierNode={defaultAncestor:null,ancestor:o,prelim:0,modifier:0,change:0,shift:0,i:a,thread:null},i.push(o)}}function Md(t,e){var n=t.isExpand?t.children:[],i=t.parentNode.children,r=t.hierNode.i?i[t.hierNode.i-1]:null;if(n.length){Ad(t);var a=(n[0].hierNode.prelim+n[n.length-1].hierNode.prelim)/2;r?(t.hierNode.prelim=r.hierNode.prelim+e(t,r),t.hierNode.modifier=t.hierNode.prelim-a):t.hierNode.prelim=a}else r&&(t.hierNode.prelim=r.hierNode.prelim+e(t,r));t.parentNode.hierNode.defaultAncestor=kd(t,r,t.parentNode.hierNode.defaultAncestor||i[0],e)}function Id(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function Td(t){return arguments.length?t:Bd}function Cd(t,e){var n={};return t-=Math.PI/2,n.x=e*Math.cos(t),n.y=e*Math.sin(t),n}function Dd(t,e){return Io(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function Ad(t){for(var e=t.children,n=e.length,i=0,r=0;--n>=0;){var a=e[n];a.hierNode.prelim+=i,a.hierNode.modifier+=i,r+=a.hierNode.change,i+=a.hierNode.shift+r}}function kd(t,e,n,i){if(e){for(var r=t,a=t,o=a.parentNode.children[0],s=e,l=r.hierNode.modifier,h=a.hierNode.modifier,u=o.hierNode.modifier,c=s.hierNode.modifier;s=Pd(s),a=Ld(a),s&&a;){r=Pd(r),o=Ld(o),r.hierNode.ancestor=t;var d=s.hierNode.prelim+c-a.hierNode.prelim-h+i(s,a);d>0&&(Ed(Od(s,t,n),t,d),h+=d,l+=d),c+=s.hierNode.modifier,h+=a.hierNode.modifier,l+=r.hierNode.modifier,u+=o.hierNode.modifier}s&&!Pd(r)&&(r.hierNode.thread=s,r.hierNode.modifier+=c-l),a&&!Ld(o)&&(o.hierNode.thread=a,o.hierNode.modifier+=h-u,n=t)}return n}function Pd(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function Ld(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function Od(t,e,n){return t.hierNode.ancestor.parentNode===e.parentNode?t.hierNode.ancestor:n}function Ed(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 Bd(t,e){return t.parentN
|
||
|
|
return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},Xp.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&ae(n,n,i),n},Xp.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&ae(n,n,i),n},Wp.getLocalTransform=function(t,e){e=e||[],Gp(e);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,a=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),Pe(e,e,i),r&&ke(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=a[0],e[5]+=a[1],e};var Zp={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(-Math.pow(2,-10*(t-1))+2)},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),-(n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i)))},elasticOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin(2*(t-e)*Math.PI/i)+1)},elasticInOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?-.5*n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i):n*Math.pow(2,-10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?.5*t*t*((e+1)*t-e):.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-Zp.bounceOut(1-t)},bounceOut:function(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return.5>t?.5*Zp.bounceIn(2*t):.5*Zp.bounceOut(2*t-1)+.5}};Be.prototype={constructor:Be,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)return void(this._pausedTime+=e);var n=(t-this._startTime-this._pausedTime)/this._life;if(!(0>n)){n=Math.min(n,1);var i=this.easing,r="string"==typeof i?Zp[i]:i,a="function"==typeof r?r(n):n;return this.fire("frame",a),1===n?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){t="on"+t,this[t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var Up=function(){this.head=null,this.tail=null,this._len=0},Kp=Up.prototype;Kp.insert=function(t){var e=new $p(t);return this.insertEntry(e),e},Kp.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},Kp.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--},Kp.len=function(){return this._len},Kp.clear=function(){this.head=this.tail=null,
|
||
|
|
},configLayer:function(t,e){if(e){var n=this._layerConfig;n[t]?r(n[t],e,!0):n[t]=e;for(var i=0;i<this._zlevelList.length;i++){var a=this._zlevelList[i];if(a===t||a===t+Ug){var o=this._layers[a];r(o,n[t],!0)}}}},delLayer:function(t){var e=this._layers,n=this._zlevelList,i=e[t];i&&(i.dom.parentNode.removeChild(i.dom),delete e[t],n.splice(h(n,t),1))},resize:function(t,e){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var i=this._opts;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width!==t||e!==this._height){n.style.width=t+"px",n.style.height=e+"px";for(var r in this._layers)this._layers.hasOwnProperty(r)&&this._layers[r].resize(t,e);f(this._progressiveLayers,function(n){n.resize(t,e)}),this.refresh(!0)}this._width=t,this._height=e}else{if(null==t||null==e)return;this._width=t,this._height=e,this.getLayer(Zg).resize(t,e)}return this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[Zg].dom;var e=new Lg("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,i=e.dom.height,r=e.ctx;this.eachLayer(function(t){t.__builtin__?r.drawImage(t.dom,0,0,n,i):t.renderToCanvas&&(e.ctx.save(),t.renderToCanvas(e.ctx),e.ctx.restore())})}else for(var a={},o=this.storage.getDisplayList(!0),s=0;s<o.length;s++){var l=o[s];this._doPaintEl(l,e,!0,a)}return e.dom},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||wi(s[n])||wi(o.style[n]))-(wi(s[r])||0)-(wi(s[a])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),r=t.getBoundingRect(),a=t.style,o=a.shadowBlur*e,s=a.shadowOffsetX*e,l=a.shadowOffsetY*e,h=a.hasStroke()?a.lineWidth:0,u=Math.max(h/2,-s+o),c=Math.max(h/2,s+o),d=Math.max(h/2,-l+o),f=Math.max(h/2,l+o),p=r.width+u+c,g=r.height+d+f;n.width=p*e,n.height=g*e,i.scale(e,e),i.clearRect(0,0,p,g),i.dpr=e;var v={position:t.position,rotation:t.rotation,scale:t.scale};t.position=[u-r.x,d-r.y],t.rotation=0,t.scale=[1,1],t.updateTransform(),t&&t.brush(i);var m=_i,y=new m({style:{x:0,y:0,image:n}});return null!=v.position&&(y.position=t.position=v.position),null!=v.rotation&&(y.rotation=t.rotation=v.rotation),null!=v.scale&&(y.scale=t.scale=v.scale),y}};var tv=function(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time,this._pausedTime,this._pauseStart,this._paused=!1,kp.call(this)};tv.prototype={constructor:tv,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t.animation=this;for(var e=t.getClips(),n=0;n<e.length;n++)this.addClip(e[n])},removeClip:function(t){var e=h(this._clips,t);e>=0&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),n=0;n<e.length;n++)this.removeClip(e[n]);t.animation=null},_update:function(){for(var t=(new Date).getTime()-this._pausedTime,e=t-this._time,n=this._clips,i=n.length,r=[],a=[],o=0;i>o;o++){var s=n[o],l=s.step(t,e);l&&(r.push(l),a.push(s))}for(var o=0;i>o;)n[o]._needsRemove?(n[o]=n[i-1],n.pop(),i--):o++;i=r.length;for(var o=0;i>o;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){function t(){e._running&&(Og(t),!e._paused&&e._update())}var e=this;this._running=!0,Og(t)},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this.
|
||
|
|
},My=Xn,Iy=(Object.freeze||Object)({addCommas:fo,toCamelCase:po,normalizeCssArray:xy,encodeHTML:go,formatTpl:vo,formatTplSimple:mo,getTooltipMarker:yo,formatTime:_o,capitalFirst:wo,truncateText:My,getTextBoundingRect:bo,getTextRect:So}),Ty=f,Cy=["left","right","top","bottom","width","height"],Dy=[["width","left","right"],["height","top","bottom"]],Ay=Mo,ky=(x(Mo,"vertical"),x(Mo,"horizontal"),{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}}),Py=qi(),Ly=Ha.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){Ha.call(this,t,e,n,i),this.uid=Ya("ec_cpt_model")},init:function(t,e,n){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Co(t):{},a=e.getTheme();r(t,a.get(this.mainType)),r(t,this.getDefaultOption()),n&&To(t,i,n)},mergeOption:function(t){r(this.option,t,!0);var e=this.layoutMode;e&&To(this.option,t,e)},optionUpdated:function(){},getDefaultOption:function(){var t=Py(this);if(!t.defaultOption){for(var e=[],n=this.constructor;n;){var i=n.prototype.defaultOption;i&&e.push(i),n=n.superClass}for(var a={},o=e.length-1;o>=0;o--)a=r(a,e[o],!0);t.defaultOption=a}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});rr(Ly,{registerWhenExtend:!0}),qa(Ly),ja(Ly,Ao),c(Ly,ky);var Oy="";"undefined"!=typeof navigator&&(Oy=navigator.platform||"");var Ey={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:Oy.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},By=qi(),Ny={clearColorPalette:function(){By(this).colorIdx=0,By(this).colorNameMap={}},getColorFromPalette:function(t,e,n){e=e||this;var i=By(e),r=i.colorIdx||0,a=i.colorNameMap=i.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var o=zi(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?ko(s,n):o;if(l=l||o,l&&l.length){var h=l[r];return t&&(a[t]=h),i.colorIdx=(r+1)%l.length,h}}},zy={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",a),Lo(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),Lo(a)&&(i.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),Lo(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],a=r.findAxisModel("radiusAxis"),o=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",a),n.set("angle",o),Lo(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),Lo(o)&&(i.set("angle",o),e.firstCategoryDimIndex=1)},geo:function(t,e){e.coordSysDims=["lng","lat"]},parallel:function(t,e,n,i){var r=t.ecModel,a=r.getComponent("parallel",t.get("parallelIndex")),o=e.coordSysDims=a.dimensions.slice();f(a.parallelAxisIndex,function(t,a){var s=r.getComponent("parallelAxis",t),l=o[a];n.set(l,s),Lo(s)&&null==e.firstCategoryDimIndex&&(i.set(l,s),e.firstCategoryDimIndex=a)})}},Ry="original",Fy="arrayRows",Vy="objectRows",Gy="keyedColumns",Hy="unknown",Wy="typedArray",Xy="column",Yy="row";Oo.seriesDataToSource=function(t){return new Oo({data:t,sourceFormat:I(t)?Wy:Ry,fromDataset:!1})},er(Oo);var qy=qi(),jy="\x00_ec_inner",Zy=Ha.extend({init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new Ha(n),this._optionManager=i},setOption:function(t,e){O(!(
|
||
|
|
},hl.prototype._parseText=function(t,e){if(1===t.nodeType){var n=t.getAttribute("dx")||0,i=t.getAttribute("dy")||0;this._textX+=parseFloat(n),this._textY+=parseFloat(i)}var r=new km({style:{text:t.textContent,transformText:!0},position:[this._textX||0,this._textY||0]});cl(e,r),fl(t,r,this._defs);var a=r.style.fontSize;a&&9>a&&(r.style.fontSize=9,r.scale=r.scale||[1,1],r.scale[0]*=a/9,r.scale[1]*=a/9);var o=r.getBoundingRect();return this._textX+=o.width,e.add(r),r};var Kx={g:function(t,e){var n=new yg;return cl(e,n),fl(t,n,this._defs),n},rect:function(t,e){var n=new Hm;return cl(e,n),fl(t,n,this._defs),n.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),n},circle:function(t,e){var n=new Pm;return cl(e,n),fl(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),n},line:function(t,e){var n=new Xm;return cl(e,n),fl(t,n,this._defs),n.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),n},ellipse:function(t,e){var n=new Zx;return cl(e,n),fl(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),n},polygon:function(t,e){var n=t.getAttribute("points");n&&(n=dl(n));var i=new Rm({shape:{points:n||[]}});return cl(e,i),fl(t,i,this._defs),i},polyline:function(t,e){var n=new Rr;cl(e,n),fl(t,n,this._defs);var i=t.getAttribute("points");i&&(i=dl(i));var r=new Fm({shape:{points:i||[]}});return r},image:function(t,e){var n=new _i;return cl(e,n),fl(t,n,this._defs),n.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),n},text:function(t,e){var n=t.getAttribute("x")||0,i=t.getAttribute("y")||0,r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0;this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(a);var o=new yg;return cl(e,o),fl(t,o,this._defs),o},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0,o=new yg;return cl(e,o),fl(t,o,this._defs),this._textX+=r,this._textY+=a,o},path:function(t,e){var n=t.getAttribute("d")||"",i=Hr(n);return cl(e,i),fl(t,i,this._defs),i}},$x={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),n=parseInt(t.getAttribute("y1")||0,10),i=parseInt(t.getAttribute("x2")||10,10),r=parseInt(t.getAttribute("y2")||0,10),a=new Km(e,n,i,r);return ul(t,a),a},radialgradient:function(){}},Qx={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"},Jx=/url\(\s*#(.*?)\)/,t_=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g,e_=/([^\s:;]+)\s*:\s*([^:;]+)/g,n_=R(),i_={registerMap:function(t,e,n){var i;return _(e)?i=e:e.svg?i=[{type:"svg",source:e.svg,specialAreas:e.specialAreas}]:(e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),i=[{type:"geoJSON",source:e,specialAreas:n}]),f(i,function(t){var e=t.type;"geoJson"===e&&(e=t.type="geoJSON");var n=r_[e];n(t)}),n_.set(t,i)},retrieveMap:function(t){return n_.get(t)}},r_={geoJSON:function(t){var e=t.source;t.geoJSON=b(e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e},svg:function(t){t.svgXML=ll(t.source)}},a_=O,o_=f,s_=w,l_=S,h_=Ly.parseClassType,u_="4.2.1",c_={zrender:"4.0.6"},d_=1,f_=1e3,p_=5
|
||
|
|
h*=c}var d=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,f=[Math.round(pw((i[0]-d)/h)*h+d),Math.round(gw((i[1]-d)/h)*h+d)];qh(f,i),this._stepLvl=l,this._interval=h,this._niceExtent=f},parse:function(t){return+ao(t)}});f(["contain","normalize"],function(t){ww.prototype[t]=function(e){return fw[t].call(this,this.parse(e))}});var bw=[["hh:mm:ss",vw],["hh:mm:ss",5*vw],["hh:mm:ss",10*vw],["hh:mm:ss",15*vw],["hh:mm:ss",30*vw],["hh:mm\nMM-dd",mw],["hh:mm\nMM-dd",5*mw],["hh:mm\nMM-dd",10*mw],["hh:mm\nMM-dd",15*mw],["hh:mm\nMM-dd",30*mw],["hh:mm\nMM-dd",yw],["hh:mm\nMM-dd",2*yw],["hh:mm\nMM-dd",6*yw],["hh:mm\nMM-dd",12*yw],["MM-dd\nyyyy",xw],["MM-dd\nyyyy",2*xw],["MM-dd\nyyyy",3*xw],["MM-dd\nyyyy",4*xw],["MM-dd\nyyyy",5*xw],["MM-dd\nyyyy",6*xw],["week",7*xw],["MM-dd\nyyyy",10*xw],["week",14*xw],["week",21*xw],["month",31*xw],["week",42*xw],["month",62*xw],["week",70*xw],["quarter",95*xw],["month",31*xw*4],["month",31*xw*5],["half-year",380*xw/2],["month",31*xw*8],["month",31*xw*10],["year",380*xw]];ww.create=function(t){return new ww({useUTC:t.ecModel.get("useUTC")})};var Sw=Fh.prototype,Mw=lw.prototype,Iw=to,Tw=$a,Cw=Math.floor,Dw=Math.ceil,Aw=Math.pow,kw=Math.log,Pw=Fh.extend({type:"log",base:10,$constructor:function(){Fh.apply(this,arguments),this._originalScale=new lw},getTicks:function(){var t=this._originalScale,e=this._extent,n=t.getExtent();return p(Mw.getTicks.call(this),function(i){var r=$a(Aw(this.base,i));return r=i===e[0]&&t.__fixMin?ru(r,n[0]):r,r=i===e[1]&&t.__fixMax?ru(r,n[1]):r},this)},getLabel:Mw.getLabel,scale:function(t){return t=Sw.scale.call(this,t),Aw(this.base,t)},setExtent:function(t,e){var n=this.base;t=kw(t)/kw(n),e=kw(e)/kw(n),Mw.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=Sw.getExtent.call(this);e[0]=Aw(t,e[0]),e[1]=Aw(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=ru(e[0],i[0])),n.__fixMax&&(e[1]=ru(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=kw(t[0])/kw(e),t[1]=kw(t[1])/kw(e),Sw.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(1/0===n||0>=n)){var i=oo(n),r=t/n*i;for(.5>=r&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var a=[$a(Dw(e[0]/i)*i),$a(Cw(e[1]/i)*i)];this._interval=i,this._niceExtent=a}},niceExtent:function(t){Mw.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});f(["contain","normalize"],function(t){Pw.prototype[t]=function(e){return e=kw(e)/kw(this.base),Sw[t].call(this,e)}}),Pw.create=function(){return new Pw};var Lw={getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null!=t.rangeStart||null!=t.rangeEnd?!1:!t.scale},getCoordSysModel:V,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},Ow=Qr({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i+a),t.lineTo(n-r,i+a),t.closePath()}}),Ew=Qr({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i),t.lineTo(n,i+a),t.lineTo(n-r,i),t.closePath()}}),Bw=Qr({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,a=Math.max(r,e.height),o=r/2,s=o*o/(a-o),l=i-a+o+s,h=Math.asin(s/o),u=Math.cos(h)*o,c=Math.sin(h),d=Math.cos(h),f=.6*o,p=.7*o;t.moveTo(n-u,l+s),t.arc(n,l,o,Math.PI-h,2*Math.PI+h),t.bezierCurveTo(n+u-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-u+c*f,l+s+d*f,n-u
|
||
|
|
},Ib.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,!(e&&e.keepLabel)&&(n.style.text=null),Oa(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},u(kc,yg);var Pb=zc.prototype;Pb.updateData=function(t,e){e=Fc(e);var n=this.group,i=t.hostModel,r=this._data,a=this._symbolCtor,o=Vc(t);r||n.removeAll(),t.diff(r).add(function(i){var r=t.getItemLayout(i);if(Rc(t,r,i,e)){var s=new a(t,i,o);s.attr("position",r),t.setItemGraphicEl(i,s),n.add(s)}}).update(function(s,l){var h=r.getItemGraphicEl(l),u=t.getItemLayout(s);return Rc(t,u,s,e)?(h?(h.updateData(t,s,o),Oa(h,{position:u},i)):(h=new a(t,s),h.attr("position",u)),n.add(h),void t.setItemGraphicEl(s,h)):void n.remove(h)}).remove(function(t){var e=r.getItemGraphicEl(t);e&&e.fadeOut(function(){n.remove(e)})}).execute(),this._data=t},Pb.isPersistent=function(){return!0},Pb.updateLayout=function(){var t=this._data;t&&t.eachItemGraphicEl(function(e,n){var i=t.getItemLayout(n);e.attr("position",i)})},Pb.incrementalPrepareUpdate=function(t){this._seriesScope=Vc(t),this._data=null,this.group.removeAll()},Pb.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}n=Fc(n);for(var r=t.start;r<t.end;r++){var a=e.getItemLayout(r);if(Rc(e,a,r,n)){var o=new this._symbolCtor(e,r,this._seriesScope);o.traverse(i),o.attr("position",a),this.group.add(o),e.setItemGraphicEl(r,o)}}},Pb.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll()};var Lb=function(t,e,n,i,r,a,o,s){for(var l=Xc(t,e),h=[],u=[],c=[],d=[],f=[],p=[],g=[],v=Gc(r,e,o),m=Gc(a,t,s),y=0;y<l.length;y++){var x=l[y],_=!0;switch(x.cmd){case"=":var w=t.getItemLayout(x.idx),b=e.getItemLayout(x.idx1);(isNaN(w[0])||isNaN(w[1]))&&(w=b.slice()),h.push(w),u.push(b),c.push(n[x.idx]),d.push(i[x.idx1]),g.push(e.getRawIndex(x.idx1));break;case"+":var S=x.idx;h.push(r.dataToPoint([e.get(v.dataDimsForPoint[0],S),e.get(v.dataDimsForPoint[1],S)])),u.push(e.getItemLayout(S).slice()),c.push(Wc(v,r,e,S)),d.push(i[S]),g.push(e.getRawIndex(S));break;case"-":var S=x.idx,M=t.getRawIndex(S);M!==S?(h.push(t.getItemLayout(S)),u.push(a.dataToPoint([t.get(m.dataDimsForPoint[0],S),t.get(m.dataDimsForPoint[1],S)])),c.push(n[S]),d.push(Wc(m,a,t,S)),g.push(M)):_=!1}_&&(f.push(x),p.push(p.length))}p.sort(function(t,e){return g[t]-g[e]});for(var I=[],T=[],C=[],D=[],A=[],y=0;y<p.length;y++){var S=p[y];I[y]=h[S],T[y]=u[S],C[y]=c[S],D[y]=d[S],A[y]=f[S]}return{current:I,next:T,stackedOnCurrent:C,stackedOnNext:D,status:A}},Ob=oe,Eb=se,Bb=q,Nb=H,zb=[],Rb=[],Fb=[],Vb=Rr.extend({type:"ec-polyline",shape:{points:[],smooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},style:{fill:null,stroke:"#000"},brush:Om(Rr.prototype.brush),buildPath:function(t,e){var n=e.points,i=0,r=n.length,a=Uc(n,e.smoothConstraint);if(e.connectNulls){for(;r>0&&Yc(n[r-1]);r--);for(;r>i&&Yc(n[i]);i++);}for(;r>i;)i+=qc(t,n,i,r,r,1,a.min,a.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),Gb=Rr.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:Om(Rr.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,a=n.length,o=e.smoothMonotone,s=Uc(n,e.smoothConstraint),l=Uc(i,e.smoothConstraint);if(e.connectNulls){for(;a>0&&Yc(n[a-1]);a--);for(;a>r&&Yc(n[r]);r++);}for(;a>r;){var h=qc(t,n,r,a,a,1,s.min,s.max,e.smooth,o,e.connectNulls);qc(t,i,r+h-1,h,a,-1,l.min,l.max,e.stackedOnSmooth,o,e.connectNulls),r+=h+1,t.closePath()}}});Vs.extend({type:"line",init:function(){var t=new yg,e=new zc;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,a=t.getData(),o=t.getModel("lineStyle"),l=t.getModel("areaStyle"),h=a.mapArray(a.getItemLayout),u="polar"===i.type,c=this._coordSys,d=this._symbolDraw,f=this._polyline,p=this._polygon,g=this._lineGroup,v=t.get("animation"),m=!l.isEmpty(),y=l.get("origin"),x=Gc(i,a,y),_=Jc(i,a,x),w=t.get("showSymbol"),b=w&&!u&&ad(t,a,i),S=thi
|
||
|
|
}else a=!0;a&&Wi(i)&&e.push(i.name)}),this._availableNames=n;var i=this.get("data")||e,r=p(i,function(t){return("string"==typeof t||"number"==typeof t)&&(t={name:t}),new Ha(t,this,this.ecModel)},this);this._data=r},getData:function(){return this._data},select:function(t){var e=this.option.selected,n=this.get("selectedMode");if("single"===n){var i=this._data;f(i,function(t){e[t.get("name")]=!1})}e[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},toggleSelected:function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&h(this._availableNames,t)>=0},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});$l("legendToggleSelect","legendselectchanged",x(hf,"toggleSelected")),$l("legendSelect","legendselected",x(hf,"select")),$l("legendUnSelect","legendunselected",x(hf,"unSelect"));var fS=x,pS=f,gS=yg,vS=ah({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new gS),this._backgroundEl,this._isFirstRender=!0},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(r,t,e,n);var a=t.getBoxLayoutParams(),o={width:n.getWidth(),height:n.getHeight()},l=t.get("padding"),h=Io(a,o,l),u=this.layoutInner(t,r,h,i),c=Io(s({width:u.width,height:u.height},a),o,l);this.group.attr("position",[c.x-u.x,c.y-u.y]),this.group.add(this._backgroundEl=uf(u,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(t,e,n,i){var r=this.getContentGroup(),a=R(),o=e.get("selectedMode"),s=[];n.eachRawSeries(function(t){!t.get("legendHoverLink")&&s.push(t.id)}),pS(e.getData(),function(l,h){var u=l.get("name");if(!this.newlineDisabled&&(""===u||"\n"===u))return void r.add(new gS({newline:!0}));var c=n.getSeriesByName(u)[0];if(!a.get(u))if(c){var d=c.getData(),f=d.getVisual("color");"function"==typeof f&&(f=f(c.getDataParams(0)));var p=d.getVisual("legendSymbol")||"roundRect",g=d.getVisual("symbol"),v=this._createItem(u,h,l,e,p,g,t,f,o);v.on("click",fS(cf,u,i)).on("mouseover",fS(df,c.name,null,i,s)).on("mouseout",fS(ff,c.name,null,i,s)),a.set(u,!0)}else n.eachRawSeries(function(n){if(!a.get(u)&&n.legendDataProvider){var r=n.legendDataProvider(),c=r.indexOfName(u);if(0>c)return;var d=r.getItemVisual(c,"color"),f="roundRect",p=this._createItem(u,h,l,e,f,null,t,d,o);p.on("click",fS(cf,u,i)).on("mouseover",fS(df,null,u,i,s)).on("mouseout",fS(ff,null,u,i,s)),a.set(u,!0)}},this)},this)},_createItem:function(t,e,n,i,r,a,s,l,h){var u=i.get("itemWidth"),c=i.get("itemHeight"),d=i.get("inactiveColor"),f=i.get("symbolKeepAspect"),p=i.isSelected(t),g=new gS,v=n.getModel("textStyle"),m=n.get("icon"),y=n.getModel("tooltip"),x=y.parentModel;if(r=m||r,g.add(mu(r,0,0,u,c,p?l:d,null==f?!0:f)),!m&&a&&(a!==r||"none"===a)){var _=.8*c;"none"===a&&(a="circle"),g.add(mu(a,(u-_)/2,(c-_)/2,_,_,p?l:d,null==f?!0:f))}var w="left"===s?u+5:-5,b=s,S=i.get("formatter"),M=t;"string"==typeof S&&S?M=S.replace("{name}",null!=t?t:""):"function"==typeof S&&(M=S(t)),g.add(new km({style:Sa({},v,{text:M,x:w,y:c/2,textFill:p?v.getTextColor():d,textAlign:b,textVerticalAlign:"middle"})}));var I=new Hm({shape:g.getBoundingRect(),invisible:!0,tooltip:y.get("show")?o({content:t,formatter:x.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},y.option):null});return g.add(I),g.eachChild(function(t){t.silent=!0}),I.silent=!h,this.getContentGroup().add(g),_a(g),g.__
|