!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.F2=e():t.F2=e()}(this,function(){return function(t){function e(i){if(n[i])return n[i].exports;var r=n[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,e),r.l=!0,r.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:i})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=252)}([function(t,e,n){"use strict";var i=n(49);e.__esModule=!0;var r={isObjectValueEqual:!0,parsePadding:!0,directionEnabled:!0,upperFirst:!0,lowerFirst:!0,isString:!0,isNumber:!0,isBoolean:!0,isFunction:!0,isDate:!0,isArray:!0,isNil:!0,isObject:!0,isPlainObject:!0,isEqual:!0,deepMix:!0,mix:!0,each:!0,uniq:!0,find:!0,Array:!0};e.isObjectValueEqual=function(t,e){t=Object.assign({},t),e=Object.assign({},e);var n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(e);if(n.length!==i.length)return!1;for(var r=0,a=n.length;r0){var a=n.strokeOpacity;c.isNil(a)||1===a||(t.globalAlpha=a),t.stroke()}},n.getBBox=function(){var t=this._attrs.bbox;return t||((t=this.calculateBox())&&(t.x=t.minX,t.y=t.minY,t.width=t.maxX-t.minX,t.height=t.maxY-t.minY),this._attrs.bbox=t),t},n.calculateBox=function(){return null},n.createPath=function(){},e}(n(46));t.exports=l},function(t,e,n){"use strict";var i={}.toString;e.a=function(t,e){return i.call(t)==="[object "+e+"]"}},function(t,e,n){"use strict";var i=n(11);e.a=function(t){return Object(i.a)(t,"Number")}},function(t,e,n){"use strict";t.exports={create:function(){return[0,0]},length:function(t){var e=t[0],n=t[1];return Math.sqrt(e*e+n*n)},normalize:function(t,e){var n=this.length(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t},add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t},sub:function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t},scale:function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},direction:function(t,e){return t[0]*e[1]-e[0]*t[1]},angle:function(t,e){var n=this.dot(t,e)/(this.length(t)*this.length(e));return Math.acos(n)},angleTo:function(t,e,n){var i=this.angle(t,e),r=this.direction(t,e)>=0;return n?r?2*Math.PI-i:i:r?i:2*Math.PI-i},zero:function(t){return 0===t[0]&&0===t[1]},distance:function(t,e){var n=e[0]-t[0],i=e[1]-t[1];return Math.sqrt(n*n+i*i)},clone:function(t){return[t[0],t[1]]},min:function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t},max:function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t},transformMat2d:function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}}},function(t,e,n){"use strict";e.a=function(t){return null===t||void 0===t}},function(t,e,n){var i=n(44),r=n(34);t.exports=function(t,e){if(t)if(r(t))for(var n=0,a=t.length;na&&(a=l)}(re.max)&&e.change({min:r,max:a})},n._sort=function(t){var e=this,n=e.getXScale(),i=n.field,r=n.type;"identity"!==r&&n.values.length>1&&h.each(t,function(t){t.sort(function(t,e){return"timeCat"===r?n._toTimeStamp(t._origin[i])-n._toTimeStamp(e._origin[i]):n.translate(t._origin[i])-n.translate(e._origin[i])})}),e.set("hasSorted",!0),e.set("dataArray",t)},n.paint=function(){var t=this,e=t.get("dataArray"),n=[],i=t.getShapeFactory();i.setCoord(t.get("coord")),t._beforeMapping(e);for(var r=0,a=e.length;r=0?e:0:e},n._normalizeValues=function(t,e){var n=[];if(h.isArray(t))for(var i=0,r=t.length;ie);r++){if(i[i.length-1][1]<=e){r=i.length-1;break}if(i[r][0]<=e&&i[r][1]>e)break}}else{(i=t.values).sort(function(t,e){return t-e});for(var o=i.length;re)&&!((i[r-1]+i[r])/2<=e&&(i[r+1]+i[r])/2>e);r++)if((i[i.length-2]+i[i.length-1])/2<=e){r=i.length-1;break}}return i[r]},n.getSnapRecords=function(t){var e=this,n=e.get("coord"),i=e.getXScale(),r=e.getYScale(),a=i.field,s=e.get("dataArray");this.get("hasSorted")||this._sort(s);var o=[],u=n.invertPoint(t),c=u.x;e.isInCircle()&&!n.transposed&&c>(1+i.rangeMax())/2&&(c=i.rangeMin());var l=i.invert(c);i.isCategory||(l=e._getSnap(i,l));var f=[];if(s.forEach(function(t){t.forEach(function(t){var n=h.isNil(t._origin)?t[a]:t._origin[a];e._isEqual(n,l,i)&&f.push(t)})}),this.hasAdjust("stack")&&n.isPolar&&n.transposed){if(c>=0&&c<=1){var p=r.invert(u.y);p=e._getSnap(r,p,f),f.forEach(function(t){(h.isArray(p)?t._originY.toString()===p.toString():t._originY===p)&&o.push(t)})}}else o=f;return o},n._isEqual=function(t,e,n){return"timeCat"===n.type?n._toTimeStamp(t)===e:e===t},n.position=function(t){return this._setAttrOptions("position",{field:t}),this},n.color=function(t,e){return this._createAttrOption("color",t,e,g.colors),this},n.size=function(t,e){return this._createAttrOption("size",t,e,g.sizes),this},n.shape=function(t,e){var n=this.get("type"),i=g.shapes[n]||[];return this._createAttrOption("shape",t,e,i),this},n.style=function(t,e){var n=this.get("styleOptions");n||(n={},this.set("styleOptions",n)),h.isObject(t)&&(e=t,t=null);var i;return t&&(i=a(t)),n.fields=i,n.style=e,this},n.adjust=function(t){return h.isString(t)&&(t={type:t}),this.set("adjust",t),this},n.animate=function(t){return this.set("animateCfg",t),this},n.changeData=function(t){this.set("data",t),this.set("scales",{}),this.init()},n.clearInner=function(){var t=this.get("container");t&&t.clear()},n.reset=function(){this.set("attrs",{}),this.set("attrOptions",{}),this.set("adjust",null),this.clearInner()},n.clear=function(){this.clearInner()},n.destroy=function(){this.clear(),t.prototype.destroy.call(this)},n._display=function(t){this.set("visible",t);var e=this.get("container"),n=e.get("canvas");e.set("visible",t),n.draw()},n.show=function(){this._display(!0)},n.hide=function(){this._display(!1)},e}(p);t.exports=m},function(t,e,n){"use strict";var i=n(11);e.a=function(t){return Object(i.a)(t,"String")}},function(t,e,n){"use strict";var i=n(0),r=n(6),a={},s={_coord:null,draw:function(t,e){this.drawShape&&this.drawShape(t,e)},setCoord:function(t){this._coord=t},parsePoint:function(t){var e=this._coord;return e.isPolar&&(1===t.x&&(t.x=.9999999),1===t.y&&(t.y=.9999999)),e.convertPoint(t)},parsePoints:function(t){if(!t)return!1;var e=this,n=[];return t.forEach(function(t){n.push(e.parsePoint(t))}),n}},o={defaultShapeType:null,setCoord:function(t){this._coord=t},getShape:function(t){var e=this;i.isArray(t)&&(t=t[0]);var n=e[t]||e[e.defaultShapeType];return n._coord=e._coord,n},getShapePoints:function(t,e){var n=this.getShape(t);return(n.getPoints||n.getShapePoints||this.getDefaultPoints)(e)},getDefaultPoints:function(){return[]},drawShape:function(t,e,n){var i=this.getShape(t);return e.color||(e.color=r.colors[0]),i.draw(e,n)}};a.registerFactory=function(t,e){var n=i.upperFirst(t),r=i.mix({},o,e);return a[n]=r,r.name=t,r},a.registerShape=function(t,e,n){var r=i.upperFirst(t),o=a[r],u=i.mix({},s,n);return o[e]=u,u},a.registShape=a.registerShape,a.getShapeFactory=function(t){var e=this;return t=t||"point",e[i.upperFirst(t)]},t.exports=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(28);n.d(e,"contains",function(){return i.a}),n.d(e,"includes",function(){return i.a});var r=n(79);n.d(e,"difference",function(){return r.a});var a=n(80);n.d(e,"find",function(){return a.a});var s=n(81);n.d(e,"findIndex",function(){return s.a});var o=n(82);n.d(e,"firstValue",function(){return o.a});var u=n(83);n.d(e,"flatten",function(){return u.a});var c=n(84);n.d(e,"flattenDeep",function(){return c.a});var l=n(85);n.d(e,"getRange",function(){return l.a});var f=n(86);n.d(e,"pull",function(){return f.a});var h=n(53);n.d(e,"pullAt",function(){return h.a});var p=n(87);n.d(e,"reduce",function(){return p.a});var d=n(88);n.d(e,"remove",function(){return d.a});var g=n(89);n.d(e,"sortBy",function(){return g.a});var v=n(90);n.d(e,"union",function(){return v.a});var y=n(54);n.d(e,"uniq",function(){return y.a});var m=n(91);n.d(e,"valuesOfKey",function(){return m.a});var x=n(92);n.d(e,"head",function(){return x.a});var _=n(93);n.d(e,"last",function(){return _.a});var S=n(94);n.d(e,"startsWith",function(){return S.a});var b=n(95);n.d(e,"endsWith",function(){return b.a});var P=n(39);n.d(e,"filter",function(){return P.a});var C=n(96);n.d(e,"every",function(){return C.a});var M=n(97);n.d(e,"some",function(){return M.a});var T=n(98);n.d(e,"group",function(){return T.a});var w=n(56);n.d(e,"groupBy",function(){return w.a});var D=n(55);n.d(e,"groupToMap",function(){return D.a});var A=n(99);n.d(e,"getWrapBehavior",function(){return A.a});var R=n(100);n.d(e,"wrapBehavior",function(){return R.a});var E=n(101);n.d(e,"number2color",function(){return E.a});var O=n(102);n.d(e,"parseRadius",function(){return O.a});var k=n(103);n.d(e,"clamp",function(){return k.a});var I=n(104);n.d(e,"fixedBase",function(){return I.a});var N=n(105);n.d(e,"isDecimal",function(){return N.a});var j=n(106);n.d(e,"isEven",function(){return j.a});var F=n(107);n.d(e,"isInteger",function(){return F.a});var Y=n(108);n.d(e,"isNegative",function(){return Y.a});var B=n(109);n.d(e,"isNumberEqual",function(){return B.a});var L=n(110);n.d(e,"isOdd",function(){return L.a});var X=n(111);n.d(e,"isPositive",function(){return X.a});var z=n(112);n.d(e,"maxBy",function(){return z.a});var G=n(113);n.d(e,"minBy",function(){return G.a});var W=n(114);n.d(e,"mod",function(){return W.a});var H=n(115);n.d(e,"toDegree",function(){return H.a});var V=n(116);n.d(e,"toInteger",function(){return V.a});var q=n(117);n.d(e,"toRadian",function(){return q.a});var U=n(118);n.d(e,"forIn",function(){return U.a});var Z=n(57);n.d(e,"has",function(){return Z.a});var J=n(119);n.d(e,"hasKey",function(){return J.a});var $=n(120);n.d(e,"hasValue",function(){return $.a});var K=n(52);n.d(e,"keys",function(){return K.a});var Q=n(51);n.d(e,"isMatch",function(){return Q.a});var tt=n(58);n.d(e,"values",function(){return tt.a});var et=n(121);n.d(e,"lowerCase",function(){return et.a});var nt=n(122);n.d(e,"lowerFirst",function(){return nt.a});var it=n(123);n.d(e,"substitute",function(){return it.a});var rt=n(124);n.d(e,"upperCase",function(){return rt.a});var at=n(125);n.d(e,"upperFirst",function(){return at.a});var st=n(59);n.d(e,"getType",function(){return st.a});var ot=n(126);n.d(e,"isArguments",function(){return ot.a});var ut=n(5);n.d(e,"isArray",function(){return ut.a});var ct=n(7);n.d(e,"isArrayLike",function(){return ct.a});var lt=n(127);n.d(e,"isBoolean",function(){return lt.a});var ft=n(128);n.d(e,"isDate",function(){return ft.a});var ht=n(129);n.d(e,"isError",function(){return ht.a});var pt=n(9);n.d(e,"isFunction",function(){return pt.a});var dt=n(130);n.d(e,"isFinite",function(){return dt.a});var gt=n(14);n.d(e,"isNil",function(){return gt.a});var vt=n(131);n.d(e,"isNull",function(){return vt.a});var yt=n(12);n.d(e,"isNumber",function(){return yt.a});var mt=n(29);n.d(e,"isObject",function(){return mt.a});var xt=n(40);n.d(e,"isObjectLike",function(){return xt.a});var _t=n(24);n.d(e,"isPlainObject",function(){return _t.a});var St=n(60);n.d(e,"isPrototype",function(){return St.a});var bt=n(132);n.d(e,"isRegExp",function(){return bt.a});var Pt=n(18);n.d(e,"isString",function(){return Pt.a});var Ct=n(11);n.d(e,"isType",function(){return Ct.a});var Mt=n(133);n.d(e,"isUndefined",function(){return Mt.a});var Tt=n(134);n.d(e,"isElement",function(){return Tt.a});var wt=n(135);n.d(e,"requestAnimationFrame",function(){return wt.a});var Dt=n(136);n.d(e,"clearAnimationFrame",function(){return Dt.a});var At=n(137);n.d(e,"augment",function(){return At.a});var Rt=n(138);n.d(e,"clone",function(){return Rt.a});var Et=n(139);n.d(e,"debounce",function(){return Et.a});var Ot=n(140);n.d(e,"memoize",function(){return Ot.a});var kt=n(141);n.d(e,"deepMix",function(){return kt.a});var It=n(8);n.d(e,"each",function(){return It.a});var Nt=n(142);n.d(e,"extend",function(){return Nt.a});var jt=n(143);n.d(e,"indexOf",function(){return jt.a});var Ft=n(144);n.d(e,"isEmpty",function(){return Ft.a});var Yt=n(61);n.d(e,"isEqual",function(){return Yt.a});var Bt=n(145);n.d(e,"isEqualWith",function(){return Bt.a});var Lt=n(146);n.d(e,"map",function(){return Lt.a});var Xt=n(147);n.d(e,"mapValues",function(){return Xt.a});var zt=n(41);n.d(e,"mix",function(){return zt.a}),n.d(e,"assign",function(){return zt.a});var Gt=n(148);n.d(e,"get",function(){return Gt.a});var Wt=n(149);n.d(e,"set",function(){return Wt.a});var Ht=n(150);n.d(e,"pick",function(){return Ht.a});var Vt=n(151);n.d(e,"throttle",function(){return Vt.a});var qt=n(152);n.d(e,"toArray",function(){return qt.a});var Ut=n(25);n.d(e,"toString",function(){return Ut.a});var Zt=n(153);n.d(e,"uniqueId",function(){return Zt.a});var Jt=n(154);n.d(e,"noop",function(){return Jt.a});var $t=n(155);n.d(e,"identity",function(){return $t.a});var Kt=n(156);n.d(e,"size",function(){return Kt.a});var Qt=n(157);n.d(e,"Cache",function(){return Qt.a})},function(t,e,n){"use strict";function i(t,e,n,i,a){return{x:r(a,t.x,e.x,n.x,i.x),y:r(a,t.y,e.y,n.y,i.y)}}function r(t,e,n,i,r){var a=t*t;return e+(3*-e+t*(3*e-e*t))*t+(3*n+t*(-6*n+3*n*t))*t+(3*i-3*i*t)*a+r*(a*t)}function a(t){for(var e=1/0,n=-1/0,r=1/0,a=-1/0,s={x:t[0],y:t[1]},o={x:t[2],y:t[3]},u={x:t[4],y:t[5]},c={x:t[6],y:t[7]},l=0;l<100;l++){var f=i(s,o,u,c,l/100);f.xn&&(n=f.x),f.ya&&(a=f.y)}return{minX:e,minY:r,maxX:n,maxY:a}}var s=n(13),o=s.create(),u=s.create(),c=s.create();t.exports={getBBoxFromPoints:function(t,e){if(0!==t.length){for(var n=t[0],i=n.x,r=n.x,a=n.y,s=n.y,o=t.length,u=1;u1e-4)return{minX:t-n,minY:e-n,maxX:t+n,maxY:e+n};o[0]=Math.cos(i)*n+t,o[1]=Math.sin(i)*n+e,u[0]=Math.cos(r)*n+t,u[1]=Math.sin(r)*n+e;var f=[0,0],h=[0,0];if(s.min(f,o,u),s.max(h,o,u),(i%=2*Math.PI)<0&&(i+=2*Math.PI),(r%=2*Math.PI)<0&&(r+=2*Math.PI),i>r&&!a?r+=2*Math.PI:ii&&(c[0]=Math.cos(d)*n+t,c[1]=Math.sin(d)*n+e,s.min(f,c,f),s.max(h,c,h));return{minX:f[0],minY:f[1],maxX:h[0],maxY:h[1]}},getBBoxFromBezierGroup:function(t,e){for(var n=1/0,i=-1/0,r=1/0,s=-1/0,o=0,u=t.length;oi&&(i=c.maxX),c.minYs&&(s=c.maxY)}return e=e/2||0,{minX:n-e,minY:r-e,maxX:i+e,maxY:s+e}}}},function(t,e){t.exports=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}},function(t,e,n){"use strict";var i=n(0),r={min:0,median:.5,max:1},a=function(){function t(t){this._initDefaultCfg(),i.deepMix(this,t)}var e=t.prototype;return e._initDefaultCfg=function(){},e._getNormalizedValue=function(t,e){return i.isNil(r[t])?e.scale(t):r[t]},e.parsePercentPoint=function(t,e){var n=parseFloat(e[0])/100,i=parseFloat(e[1])/100,r=t.start,a=t.end,s=Math.abs(r.x-a.x),o=Math.abs(r.y-a.y);return{x:s*n+Math.min(r.x,a.x),y:o*i+Math.min(r.y,a.y)}},e.parsePoint=function(t,e){var n=this,r=n.xScale,a=n.yScales;if(i.isFunction(e)&&(e=e(r,a)),i.isString(e[0])&&-1!==e[0].indexOf("%")&&!isNaN(e[0].slice(0,-1)))return this.parsePercentPoint(t,e);var s=n._getNormalizedValue(e[0],r),o=n._getNormalizedValue(e[1],a[0]),u=t.convertPoint({x:s,y:o});return n.limitInPlot?s>=0&&s<=1&&o>=0&&o<=1?u:null:u},e.render=function(){},e.repaint=function(){this.remove();var t=this.coord,e=this.container,n=this.canvas;e&&!e.isDestroyed()&&(this.render(t,e),n.draw())},e.remove=function(){var t=this.element;t&&t.remove(!0)},e.changeVisible=function(t){var e=this;e.visible=t;var n=e.element;n&&(n.set?n.set("visible",t):n.style.display=t?"":"none")},t}();t.exports=a},function(t,e,n){"use strict";var i=n(40),r=n(11);e.a=function(t){if(!Object(i.a)(t)||!Object(r.a)(t,"Object"))return!1;if(null===Object.getPrototypeOf(t))return!0;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}},function(t,e,n){"use strict";var i=n(14);e.a=function(t){return Object(i.a)(t)?"":t.toString()}},function(t,e,n){var i=n(64),r=n(15),a=n(44),s=n(35),o=function(){function t(t){this._initDefaultCfg(),i(this,t),this.init()}var e=t.prototype;return e._initDefaultCfg=function(){this.type="base",this.formatter=null,this.range=[0,1],this.ticks=null,this.values=[]},e.init=function(){},e.getTicks=function(){var t=this,e=t.ticks,n=[];return r(e,function(e){var i;i=a(e)?e:{text:t.getText(e),tickValue:e,value:t.scale(e)},n.push(i)}),n},e.getText=function(t,e){var n=this.formatter;return t=n?n(t,e):t,!s(t)&&t.toString||(t=""),t.toString()},e.rangeMin=function(){return this.range[0]},e.rangeMax=function(){var t=this.range;return t[t.length-1]},e.invert=function(t){return t},e.translate=function(t){return t},e.scale=function(t){return t},e.clone=function(){var t=this,e=t.constructor,n={};return r(t,function(e,i){n[i]=t[i]}),new e(n)},e.change=function(t){return this.ticks=null,i(this,t),this.init(),this},t}();t.exports=o},function(t,e){var n={}.toString;t.exports=function(t,e){return n.call(t)==="[object "+e+"]"}},function(t,e,n){"use strict";var i=n(7);e.a=function(t,e){return!!Object(i.a)(t)&&t.indexOf(e)>-1}},function(t,e,n){"use strict";e.a=function(t){var e=typeof t;return null!==t&&"object"===e||"function"===e}},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,l.default)(t);if(r()){var i=(0,l.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,c.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}function a(t,e){return t-e}function s(t,e){var n=!1;return g.each(t,function(t){var i=[].concat(t.values),r=[].concat(e.values);t.type!==e.type||t.field!==e.field||i.sort(a).toString()!==r.sort(a).toString()||(n=!0)}),n}var o=n(1),u=o(n(22)),c=o(n(2)),l=o(n(3)),f=o(n(4)),h=n(47),p=n(63),d=n(158),g=n(0),v=n(159),y=n(17),m=n(167),x=n(173),_=n(6),S=n(16).Canvas,b=n(37),P=function(t){function e(e){var n;n=t.call(this,e)||this;var i=(0,u.default)(n);return g.each(y,function(t,e){var n=g.lowerFirst(e);i[n]=function(e){var n=new t(e);return i.addGeom(n),n}}),i._init(),n}(0,f.default)(e,t);i(e);e.initPlugins=function(){return{_plugins:[],_cacheId:0,register:function(t){var e=this._plugins;[].concat(t).forEach(function(t){-1===e.indexOf(t)&&e.push(t)}),this._cacheId++},unregister:function(t){var e=this._plugins;[].concat(t).forEach(function(t){var n=e.indexOf(t);-1!==n&&e.splice(n,1)}),this._cacheId++},clear:function(){this._plugins=[],this._cacheId++},count:function(){return this._plugins.length},getAll:function(){return this._plugins},notify:function(t,e,n){var i,r,a,s,o,u=this.descriptors(t),c=u.length;for(i=0;i0;)t.shift().destroy()},n._clearGeoms=function(){for(var t=this.get("geoms"),e=0,n=t.length;e=r.x&&n<=a.x&&i>=r.y&&i<=s.y};var i=n(16).Shape},function(t,e,n){"use strict";var i=n(0),r={splitPoints:function(t){var e=[],n=t.x,r=t.y;return(r=i.isArray(r)?r:[r]).forEach(function(t,r){var a={x:i.isArray(n)?n[r]:n,y:t};e.push(a)}),e},splitArray:function(t,e,n){if(!t.length)return[];var r,a=[],s=[];return i.each(t,function(t){r=t._origin?t._origin[e]:t[e],n?i.isNil(r)||s.push(t):i.isArray(r)&&i.isNil(r[0])||i.isNil(r)?s.length&&(a.push(s),s=[]):s.push(t)}),s.length&&a.push(s),a}};t.exports=r},function(t,e,n){"use strict";var i=n(8),r=n(7);e.a=function(t,e){if(!Object(r.a)(t))return t;var n=[];return Object(i.a)(t,function(t,i){e(t,i)&&n.push(t)}),n}},function(t,e,n){"use strict";e.a=function(t){return"object"==typeof t&&null!==t}},function(t,e,n){"use strict";function i(t,e){for(var n in e)e.hasOwnProperty(n)&&"constructor"!==n&&void 0!==e[n]&&(t[n]=e[n])}e.a=function(t,e,n,r){return e&&i(t,e),n&&i(t,n),r&&i(t,r),t}},function(t,e,n){"use strict";e.__esModule=!0,e.default=void 0;var i=n(0),r=function(){function t(){this.__events={}}var e=t.prototype;return e.on=function(t,e){if(t&&e){var n=this.__events[t]||[];n.push(e),this.__events[t]=n}},e.emit=function(t,e){var n=this;if((0,i.isObject)(t)&&(t=(e=t)&&e.type),t){var r=this.__events[t];r&&r.length&&r.forEach(function(t){t.call(n,e)})}},e.off=function(t,e){var n=this.__events,i=n[t];if(i&&i.length)if(e)for(var r=0,a=i.length;r0?"left":r[0]<0?"right":"center",i=r[1]>0?"top":r[1]<0?"bottom":"middle",{textAlign:n,textBaseline:i}},e.getContainer=function(t){var e=this.frontContainer,n=this.backContainer;return t?e:n},t}();t.exports=s},function(t,e,n){"use strict";function i(t){return 1===t[0]&&0===t[1]&&0===t[2]&&1===t[3]&&0===t[4]&&0===t[5]}var r=n(0),a=n(31),s=n(13),o=n(179),u={stroke:"strokeStyle",fill:"fillStyle",opacity:"globalAlpha"},c=["fillStyle","font","globalAlpha","lineCap","lineWidth","lineJoin","miterLimit","shadowBlur","shadowColor","shadowOffsetX","shadowOffsetY","strokeStyle","textAlign","textBaseline","lineDash","shadow"],l=["circle","sector","polygon","rect","polyline"],f=function(){function t(t){this._initProperties(),r.mix(this._attrs,t);var e=this._attrs.attrs;e&&this.initAttrs(e),this.initTransform()}var e=t.prototype;return e._initProperties=function(){this._attrs={zIndex:0,visible:!0,destroyed:!1}},e.get=function(t){return this._attrs[t]},e.set=function(t,e){this._attrs[t]=e},e.isGroup=function(){return this.get("isGroup")},e.isShape=function(){return this.get("isShape")},e.initAttrs=function(t){this.attr(r.mix(this.getDefaultAttrs(),t))},e.getDefaultAttrs=function(){return{}},e._setAttr=function(t,e){var n=this._attrs.attrs;if("clip"===t)e=this._setAttrClip(e);else{var i=u[t];i&&(n[i]=e)}n[t]=e},e._getAttr=function(t){return this._attrs.attrs[t]},e._setAttrClip=function(t){return t&&l.indexOf(t._attrs.type)>-1?(null===t.get("canvas")&&(t=Object.assign({},t)),t.set("parent",this.get("parent")),t.set("context",this.get("context")),t):null},e.attr=function(t,e){var n=this;if(n.get("destroyed"))return null;var i=arguments.length;if(0===i)return n._attrs.attrs;if(r.isObject(t)){this._attrs.bbox=null;for(var a in t)n._setAttr(a,t[a]);return n._afterAttrsSet&&n._afterAttrsSet(),n}return 2===i?(this._attrs.bbox=null,n._setAttr(t,e),n._afterAttrsSet&&n._afterAttrsSet(),n):n._getAttr(t)},e.getParent=function(){return this.get("parent")},e.draw=function(t){this.get("destroyed")||this.get("visible")&&(this.setContext(t),this.drawInner(t),this.restoreContext(t))},e.setContext=function(t){var e=this._attrs.attrs.clip;t.save(),e&&(e.resetTransform(t),e.createPath(t),t.clip()),this.resetContext(t),this.resetTransform(t)},e.restoreContext=function(t){t.restore()},e.resetContext=function(t){var e=this._attrs.attrs;if(!this._attrs.isGroup)for(var n in e)if(c.indexOf(n)>-1){var i=e[n];"fillStyle"!==n&&"strokeStyle"!==n||(i=o.parseStyle(i,this,t)),"lineDash"===n&&t.setLineDash&&r.isArray(i)?t.setLineDash(i):t[n]=i}},e.hasFill=function(){return this.get("canFill")&&this._attrs.attrs.fillStyle},e.hasStroke=function(){return this.get("canStroke")&&this._attrs.attrs.strokeStyle},e.drawInner=function(){},e.show=function(){return this.set("visible",!0),this},e.hide=function(){return this.set("visible",!1),this},e.isVisible=function(){return this.get("visible")},e._removeFromParent=function(){var t=this.get("parent");if(t){var e=t.get("children");r.Array.remove(e,this)}return this},e.remove=function(t){t?this.destroy():this._removeFromParent()},e.destroy=function(){if(this.get("destroyed"))return null;this._removeFromParent(),this._attrs={},this.set("destroyed",!0)},e.getBBox=function(){return{minX:0,maxX:0,minY:0,maxY:0,width:0,height:0}},e.initTransform=function(){var t=this._attrs.attrs||{};t.matrix||(t.matrix=[1,0,0,1,0,0]),this._attrs.attrs=t},e.getMatrix=function(){return this._attrs.attrs.matrix},e.setMatrix=function(t){this._attrs.attrs.matrix=[t[0],t[1],t[2],t[3],t[4],t[5]]},e.transform=function(t){var e=this._attrs.attrs.matrix;return this._attrs.attrs.matrix=a.transform(e,t),this},e.setTransform=function(t){return this._attrs.attrs.matrix=[1,0,0,1,0,0],this.transform(t)},e.translate=function(t,e){var n=this._attrs.attrs.matrix;a.translate(n,n,[t,e])},e.rotate=function(t){var e=this._attrs.attrs.matrix;a.rotate(e,e,t)},e.scale=function(t,e){var n=this._attrs.attrs.matrix;a.scale(n,n,[t,e])},e.moveTo=function(t,e){var n=this._attrs.x||0,i=this._attrs.y||0;this.translate(t-n,e-i),this.set("x",t),this.set("y",e)},e.apply=function(t){var e=this._attrs.attrs.matrix;return s.transformMat2d(t,t,e),this},e.resetTransform=function(t){var e=this._attrs.attrs.matrix;i(e)||t.transform(e[0],e[1],e[2],e[3],e[4],e[5])},e.isDestroyed=function(){return this.get("destroyed")},t}();t.exports=f},function(t,e,n){"use strict";e.__esModule=!0,e.EVENT_AFTER_GEOM_INIT=e.EVENT_AFTER_SIZE_CHANGE=e.EVENT_AFTER_DATA_CHANGE=e.EVENT_BEFORE_DATA_CHANGE=e.EVENT_AFTER_RENDER=e.EVENT_BEFORE_RENDER=e.EVENT_AFTER_INIT=void 0;e.EVENT_AFTER_INIT="afterinit";e.EVENT_BEFORE_RENDER="beforerender";e.EVENT_AFTER_RENDER="afterrender";e.EVENT_BEFORE_DATA_CHANGE="beforedatachange";e.EVENT_AFTER_DATA_CHANGE="afterdatachange";e.EVENT_AFTER_SIZE_CHANGE="_aftersizechange";e.EVENT_AFTER_GEOM_INIT="_aftergeominit"},function(t,e,n){var i=n(27);t.exports=function(t){return i(t,"String")}},function(t,e,n){function i(){if("function"!=typeof WeakMap)return null;var t=new WeakMap;return i=function(){return t},t}var r=n(50);t.exports=function(t){if(t&&t.__esModule)return t;if(null===t||"object"!==r(t)&&"function"!=typeof t)return{default:t};var e=i();if(e&&e.has(t))return e.get(t);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in t)if(Object.prototype.hasOwnProperty.call(t,s)){var o=a?Object.getOwnPropertyDescriptor(t,s):null;o&&(o.get||o.set)?Object.defineProperty(n,s,o):n[s]=t[s]}return n.default=t,e&&e.set(t,n),n}},function(t,e){function n(e){"@babel/helpers - typeof";return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?t.exports=n=function(t){return typeof t}:t.exports=n=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(e)}t.exports=n},function(t,e,n){"use strict";var i=n(14),r=n(52);e.a=function(t,e){var n=Object(r.a)(e),a=n.length;if(Object(i.a)(t))return!a;for(var s=0;s0&&t%n!=0;n--);if(1===n)for(n=e;n>0&&(t-1)%n!=0;n--);return n}var a=n(15);t.exports=function(t){var e,n={},a=[],s=t.isRounding,o=i(t.data),u=o.length,c=t.maxCount||8;if(s?2===(e=r(u-1,c-1)+1)?e=c:e-1},sort:function(){for(var t=this.get("children"),e=0,n=t.length;e=0&&(e.lineWidth=t.size),a.mix(e,t.style),a.mix({},u.shape.line,e)}function r(t,e,n,i){var r=t.points;if(r.length&&a.isArray(r[0].y)){for(var s=[],u=[],c=0,l=r.length;c1?t/(this.values.length-1):t,n+e*(i-n)},n.invert=function(t){if(u(t))return t;var e=this.rangeMin(),n=this.rangeMax();tn&&(t=n);var i=(t-e)/(n-e),r=Math.round(i*(this.values.length-1))%this.values.length;return r=r||0,this.values[r]},e}(r);r.Cat=c,t.exports=c},function(t,e,n){"use strict";t.exports={requestAnimationFrame:"object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame:function(t){return setTimeout(t,16)}}},function(t,e,n){"use strict";function i(t){return[t.x,t.y]}function r(t,e,n,r){var s,o,u,c,l,f,h,p,d=[],g=!!r;if(g){for(u=[1/0,1/0],c=[-1/0,-1/0],p=0,h=t.length;p1?r.widthRatio.multiplePie:r.widthRatio.rose:(n.isLinear&&(u*=o[1]-o[0]),c=r.widthRatio.column),u*=c,this.hasAdjust("dodge")&&(u/=i.length),t=u,this.set("defaultSize",t)}return t},getDimWidth:function(t){var e=this.get("coord"),n=e.convertPoint({x:0,y:0}),i=e.convertPoint({x:"x"===t?1:0,y:"x"===t?0:1}),r=0;return n&&i&&(r=Math.sqrt(Math.pow(i.x-n.x,2)+Math.pow(i.y-n.y,2))),r},_getWidth:function(){var t=this.get("_width");if(!t){var e=this.get("coord");t=e&&e.isPolar&&!e.transposed?(e.endAngle-e.startAngle)*e.circleRadius:this.getDimWidth("x"),this.set("_width",t)}return t},_toNormalizedSize:function(t){return t/this._getWidth()},_toCoordSize:function(t){return this._getWidth()*t},getNormalizedSize:function(t){var e=this.getAttrValue("size",t);return e=a.isNil(e)?this.getDefalutSize():this._toNormalizedSize(e)},getSize:function(t){var e=this.getAttrValue("size",t);if(a.isNil(e)){var n=this.getDefalutSize();e=this._toCoordSize(n)}return e}};t.exports=s},function(t,e,n){"use strict";n(241);var i,r=n(0);r.isWx||r.isMy||(i=n(259));var a=["touchstart","touchmove","touchend"],s=function(){function t(t,e){var n=this;this._start=function(t){n.preStart&&n.preStart(t),n.start(t),n.onStart&&n.onStart(t)},this._process=function(t){n.preProcess&&n.preProcess(t),n.process(t),n.onProcess&&n.onProcess(t)},this._end=function(t){n.preEnd&&n.preEnd(t),n.end(t),n.onEnd&&n.onEnd(t)},this._reset=function(t){n.preReset&&n.preReset(t),n.reset(t),n.onReset&&n.onReset(t)};var i=this.getDefaultCfg();r.deepMix(this,i,t),this.chart=e,this.canvas=e.get("canvas"),this.el=e.get("canvas").get("el"),this._bindEvents()}var e=t.prototype;return e.getDefaultCfg=function(){return{startEvent:a[0],processEvent:a[1],endEvent:a[2],resetEvent:null}},e.start=function(){},e.process=function(){},e.end=function(){},e.reset=function(){},e._bindEvents=function(){this._clearEvents();var t=this.startEvent,e=this.processEvent,n=this.endEvent,r=this.resetEvent,a=this.el;i&&(this.hammer=new i(a)),this._bindEvent(t,this._start),this._bindEvent(e,this._process),this._bindEvent(n,this._end),this._bindEvent(r,this._reset)},e._clearEvents=function(){var t=this.startEvent,e=this.processEvent,n=this.endEvent,i=this.resetEvent;this.hammer&&(this.hammer.destroy(),this.hammer=null),this._clearTouchEvent(t,this._start),this._clearTouchEvent(e,this._process),this._clearTouchEvent(n,this._end),this._clearTouchEvent(i,this._reset)},e._bindEvent=function(t,e){var n=this.el;t&&(-1!==a.indexOf(t)?r.addEventListener(n,t,e):this.hammer&&this.hammer.on(t,e))},e._clearTouchEvent=function(t,e){var n=this.el;t&&-1!==a.indexOf(t)&&r.removeEventListener(n,t,e)},e.destroy=function(){this._clearEvents()},t}();t.exports=s},function(t,e,n){"use strict";function i(t,e){if(!e)return{0:t};for(var n={},i=0,r=t.length;i-1;)r.call(t,o,1);return t}},function(t,e,n){"use strict";var i=n(8),r=n(5),a=n(24);e.a=function(t,e,n){if(!Object(r.a)(t)&&!Object(a.a)(t))return t;var s=n;return Object(i.a)(t,function(t,n){s=e(s,t,n)}),s}},function(t,e,n){"use strict";var i=n(7),r=n(53);e.a=function(t,e){var n=[];if(!Object(i.a)(t))return n;for(var a=-1,s=[],o=t.length;++ae[i])return 1;if(t[i]n?n:t}},function(t,e,n){"use strict";e.a=function(t,e){var n=e.toString(),i=n.indexOf(".");if(-1===i)return Math.round(t);var r=n.substr(i+1).length;return r>20&&(r=20),parseFloat(t.toFixed(r))}},function(t,e,n){"use strict";var i=n(12);e.a=function(t){return Object(i.a)(t)&&t%1!=0}},function(t,e,n){"use strict";var i=n(12);e.a=function(t){return Object(i.a)(t)&&t%2==0}},function(t,e,n){"use strict";var i=n(12),r=Number.isInteger?Number.isInteger:function(t){return Object(i.a)(t)&&t%1==0};e.a=r},function(t,e,n){"use strict";var i=n(12);e.a=function(t){return Object(i.a)(t)&&t<0}},function(t,e,n){"use strict";e.a=function(t,e,n){return void 0===n&&(n=i),Math.abs(t-e)0}},function(t,e,n){"use strict";var i=n(8),r=n(5),a=n(9);e.a=function(t,e){if(Object(r.a)(t)){var n,s=t[0];n=Object(a.a)(e)?e(t[0]):t[0][e];var o;return Object(i.a)(t,function(t){(o=Object(a.a)(e)?e(t):t[e])>n&&(s=t,n=o)}),s}}},function(t,e,n){"use strict";var i=n(8),r=n(5),a=n(9);e.a=function(t,e){if(Object(r.a)(t)){var n,s=t[0];n=Object(a.a)(e)?e(t[0]):t[0][e];var o;return Object(i.a)(t,function(t){(o=Object(a.a)(e)?e(t):t[e])e?(i&&(clearTimeout(i),i=null),o=c,s=t.apply(r,a),i||(r=a=null)):i||!1===n.trailing||(i=setTimeout(u,l)),s};return c.cancel=function(){clearTimeout(i),o=0,i=r=a=null},c}},function(t,e,n){"use strict";var i=n(7);e.a=function(t){return Object(i.a)(t)?Array.prototype.slice.call(t):[]}},function(t,e,n){"use strict";var i={};e.a=function(t){return t=t||"g",i[t]?i[t]+=1:i[t]=1,t+i[t]}},function(t,e,n){"use strict";e.a=function(){}},function(t,e,n){"use strict";e.a=function(t){return t}},function(t,e,n){"use strict";e.a=function(t){return Object(i.a)(t)?0:Object(r.a)(t)?t.length:Object.keys(t).length};var i=n(14),r=n(7)},function(t,e,n){"use strict";var i=function(){function t(){this.map={}}return t.prototype.has=function(t){return void 0!==this.map[t]},t.prototype.get=function(t,e){var n=this.map[t];return void 0===n?e:n},t.prototype.set=function(t,e){this.map[t]=e},t.prototype.clear=function(){this.map={}},t.prototype.delete=function(t){delete this.map[t]},t.prototype.size=function(){return Object.keys(this.map).length},t}();e.a=i},function(t,e,n){"use strict";var i=n(0),r=function(){function t(t){i.mix(this,t),this._init()}var e=t.prototype;return e._init=function(){var t=this,e=t.start,n=t.end,i=Math.min(e.x,n.x),r=Math.max(e.x,n.x),a=Math.min(e.y,n.y),s=Math.max(e.y,n.y);this.tl={x:i,y:a},this.tr={x:r,y:a},this.bl={x:i,y:s},this.br={x:r,y:s},this.width=r-i,this.height=s-a},e.reset=function(t,e){this.start=t,this.end=e,this._init()},e.isInRange=function(t,e){i.isObject(t)&&(e=t.y,t=t.x);var n=this.tl,r=this.br;return n.x<=t&&t<=r.x&&n.y<=e&&e<=r.y},t}();t.exports=r},function(t,e,n){"use strict";var i=n(43);n(160),t.exports=i},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(43),l=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="cartesian",this.transposed=!1,this.isRect=!0},n.init=function(e,n){t.prototype.init.call(this,e,n),this.x={start:e.x,end:n.x},this.y={start:e.y,end:n.y}},n._convertPoint=function(t){var e=this,n=e.transposed,i=n?"y":"x",r=n?"x":"y",a=e.x,s=e.y;return{x:a.start+(a.end-a.start)*t[i],y:s.start+(s.end-s.start)*t[r]}},n._invertPoint=function(t){var e=this,n=e.transposed,i=n?"y":"x",r=n?"x":"y",a=e.x,s=e.y,o={};return o[i]=(t.x-a.start)/(a.end-a.start),o[r]=(t.y-s.start)/(s.end-s.start),o},e}(c);c.Cartesian=l,c.Rect=l,t.exports=l},function(t,e,n){"use strict";var i=n(1);e.__esModule=!0,e.Color=e.Size=e.Shape=e.Position=void 0;var r=i(n(162));e.Position=r.default;var a=i(n(163));e.Shape=a.default;var s=i(n(164));e.Size=s.default;var o=i(n(165));e.Color=o.default},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1);e.__esModule=!0,e.default=void 0;var s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(20),l=function(t){function e(e){var n;return n=t.call(this,e)||this,n.names=["x","y"],n.type="position",n}(0,u.default)(e,t);i(e);return e.prototype.mapping=function(t,e){var n,i,r,a=this.scales,s=this.coord,o=a[0],u=a[1];if((0,c.isNil)(t)||(0,c.isNil)(e))return[];if((0,c.isArray)(e)&&(0,c.isArray)(t)){n=[],i=[];for(var l=0,f=0,h=t.length,p=e.length;l0?t.change({min:0}):r<0&&t.change({max:0}))},e.clear=function(){r(this.defs),r(this.scales),this.data=null},t}();t.exports=c},function(t,e,n){"use strict";var i=n(26);n(169),n(172),n(69),t.exports=i},function(t,e,n){function i(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=n(35),a=n(15),s=n(26),o=n(170),u=function(t){function e(){return t.apply(this,arguments)||this}i(e,t);var n=e.prototype;return n._initDefaultCfg=function(){t.prototype._initDefaultCfg.call(this);var e=this;e.type="linear",e.isLinear=!0,e.nice=!1,e.min=null,e.minLimit=null,e.max=null,e.maxLimit=null,e.tickCount=null,e.tickInterval=null,e.minTickInterval=null,e.snapArray=null},n.init=function(){var t=this;if(t.ticks){var e=t.ticks,n=t.translate(e[0]),i=t.translate(e[e.length-1]);(r(t.min)||t.min>n)&&(t.min=n),(r(t.max)||t.max=t.min&&e<=t.max&&n.push(e)}),n.length||(n.push(t.min),n.push(t.max)),t.ticks=n}},n.scale=function(t){if(r(t))return NaN;var e=this.max,n=this.min;if(e===n)return 0;var i=(t-n)/(e-n),a=this.rangeMin();return a+i*(this.rangeMax()-a)},n.invert=function(t){var e=(t-this.rangeMin())/(this.rangeMax()-this.rangeMin());return this.min+e*(this.max-this.min)},e}(s);s.Linear=u,t.exports=u},function(t,e,n){var i=n(35),r=n(36),a=n(171),s=[0,1,1.2,1.5,1.6,2,2.2,2.4,2.5,3,4,5,6,7.5,8,10],o=[0,1,2,4,5,10];t.exports=function(t){var e=t.min,n=t.max,u=t.interval,c=t.minTickInterval,l=[],f=t.minCount||5,h=t.maxCount||7,p=f===h,d=i(t.minLimit)?-1/0:t.minLimit,g=i(t.maxLimit)?1/0:t.maxLimit,v=(f+h)/2,y=v,m=t.snapArray?t.snapArray:p?s:o;if(e===d&&n===g&&p&&(u=(n-e)/(y-1)),i(e)&&(e=0),i(n)&&(n=0),Math.abs(n-e)<1e-12&&(0===e?n=1:e>0?e=0:n=0,n-e<5&&!u&&n-e>=1&&(u=1)),i(u)){var x=(n-e)/(v-1);u=a.snapFactorTo(x,m,"ceil"),h!==f&&((y=parseInt((n-e)/u,10))>h&&(y=h),yM);)M=C,C=a.fixedBase(C+u,u);for(var T=null;_>e&&(null===T||_a&&(e=parseFloat(e.toFixed(n)))}else for(;t>10;)e*=10,t/=10;return e}function i(t,e){var n=t.length;if(0===n)return NaN;var i=t[0];if(e=t[n-1])return t[n-1];for(var r=1;rt[n-1])return NaN;if(ea&&(u=t/parseInt(1/r)*(r>0?1:-1)),u},snapMultiple:function(t,e,n){return("ceil"===n?Math.ceil(t/e):"floor"===n?Math.floor(t/e):Math.round(t/e))*e},snapTo:function(t,e){var n=i(t,e),a=r(t,e);if(isNaN(n)||isNaN(a)){if(t[0]>=e)return t[0];var s=t[t.length-1];if(s<=e)return s}return Math.abs(e-n)=0?parseInt(n.substr(r+2),10):n.substr(i+1).length;return a>20&&(a=20),parseFloat(t.toFixed(a))}};t.exports=s},function(t,e,n){function i(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=n(26),a=n(36),s=function(t){function e(){return t.apply(this,arguments)||this}i(e,t);var n=e.prototype;return n._initDefaultCfg=function(){t.prototype._initDefaultCfg.call(this),this.isIdentity=!0,this.type="identity",this.value=null},n.getText=function(){return this.value.toString()},n.scale=function(t){return this.value!==t&&a(t)?t:this.range[0]},n.invert=function(){return this.value},e}(r);r.Identity=s,t.exports=s},function(t,e,n){"use strict";function i(t){var e=t.slice(0);if(e.length>0){var n=e[0],i=e[e.length-1];0!==n.value&&e.unshift({value:0}),1!==i.value&&e.push({value:1})}return e}var r=n(0),a=n(174),s=n(6),o=n(16).Shape,u=function(){function t(t){this.axisCfg={},this.frontPlot=null,this.backPlot=null,this.axes={},r.mix(this,t)}var e=t.prototype;return e._isHide=function(t){var e=this.axisCfg;return!e||!1===e[t]},e._getLinePosition=function(t,e,n,i){var r="",a=t.field,s=this.axisCfg;return s[a]&&s[a].position?r=s[a].position:"x"===e?r=i?"left":"bottom":"y"===e&&(r=n?"right":"left",i&&(r="bottom")),r},e._getLineCfg=function(t,e,n){var i,r,a=1;return"x"===e?(i={x:0,y:0},r={x:1,y:0}):"right"===n?(i={x:1,y:0},r={x:1,y:1}):(i={x:0,y:0},r={x:0,y:1},a=-1),t.transposed&&(a*=-1),{offsetFactor:a,start:t.convertPoint(i),end:t.convertPoint(r)}},e._getCircleCfg=function(t){return{startAngle:t.startAngle,endAngle:t.endAngle,center:t.center,radius:t.circleRadius}},e._getRadiusCfg=function(t){var e,n;return t.transposed?(e={x:0,y:0},n={x:1,y:0}):(e={x:0,y:0},n={x:0,y:1}),{offsetFactor:-1,start:t.convertPoint(e),end:t.convertPoint(n)}},e._getAxisCfg=function(t,e,n,i,a){var u=this,c=this.axisCfg,l=e.getTicks(),f=r.deepMix({ticks:l,frontContainer:this.frontPlot,backContainer:this.backPlot},a,c[e.field]),h=[],p=f.label,d=l.length,g=0,v=0,y=p;return r.each(l,function(t,e){if(r.isFunction(p)){var n=p(t.text,e,d);y=n?r.mix({},s._defaultAxis.label,n):null}if(y){var i={};y.textAlign&&(i.textAlign=y.textAlign),y.textBaseline&&(i.textBaseline=y.textBaseline);var a=new o.Text({className:"axis-label",attrs:r.mix({x:0,y:0,text:t.text,fontFamily:u.chart.get("canvas").get("fontFamily")},y),value:t.value,textStyle:i,top:y.top,context:u.chart.get("canvas").get("context")});h.push(a);var c=a.getBBox(),l=c.width,f=c.height;g=Math.max(g,l),v=Math.max(v,f)}}),f.labels=h,f.maxWidth=g,f.maxHeight=v,f},e._createAxis=function(t,e,n,i,r){void 0===r&&(r="");var a,o,u,c=this,l=t.type,f=t.transposed;if("cartesian"===l||"rect"===l){var h=c._getLinePosition(e,i,r,f);(u=s.axis[h]).position=h,a="Line",o=h}else"x"===i&&!f||"y"===i&&f?(u=s.axis.circle,a="Circle",o="circle"):(u=s.axis.radius,a="Line",o="radius");var p=c._getAxisCfg(t,e,n,i,u);p.type=a,p.dimType=i,p.verticalScale=n,p.index=r,this.axes[o]=p},e.createAxis=function(t,e,n){var s=this;e&&!s._isHide(e.field)&&s._createAxis(t,e,n[0],"x"),r.each(n,function(n,i){s._isHide(n.field)||s._createAxis(t,n,e,"y",i)});var o=this.axes,u=s.chart;if(u._isAutoPadding()){var c=r.parsePadding(u.get("padding")),l=r.parsePadding(u.get("appendPadding")),f=u.get("legendRange")||{top:0,right:0,bottom:0,left:0},h=["auto"===c[0]?f.top+2*l[0]:c[0],"auto"===c[1]?f.right+l[1]:c[1],"auto"===c[2]?f.bottom+l[2]:c[2],"auto"===c[3]?f.left+l[3]:c[3]];if(t.isPolar){var p=o.circle;if(p){var d=p.maxHeight,g=p.maxWidth,v=p.labelOffset;h[0]+=d+v,h[1]+=g+v,h[2]+=d+v,h[3]+=g+v}}else{if(o.right&&"auto"===c[1]){var y=o.right,m=y.maxWidth,x=y.labelOffset;h[1]+=m+x}if(o.left&&"auto"===c[3]){var _=o.left,S=_.maxWidth,b=_.labelOffset;h[3]+=S+b}if(o.bottom&&"auto"===c[2]){var P=o.bottom,C=P.maxHeight,M=P.labelOffset;h[2]+=C+M}}u.set("_padding",h),u._updateLayout(h)}r.each(o,function(e){var n,o=e.type,u=e.grid,c=e.verticalScale,l=e.ticks,f=e.dimType,h=e.position,p=e.index;if(t.isPolar?"Line"===o?n=s._getRadiusCfg(t):"Circle"===o&&(n=s._getCircleCfg(t)):n=s._getLineCfg(t,f,h),u&&c){var d=[],g=i(c.getTicks());r.each(l,function(e){var n=[];r.each(g,function(i){var r="x"===f?e.value:i.value,a="x"===f?i.value:e.value;if(r>=0&&r<=1&&a>=0&&a<=1){var s=t.convertPoint({x:r,y:a});n.push(s)}}),d.push({points:n,_id:"axis-"+f+p+"-grid-"+e.tickValue})}),e.gridPoints=d,t.isPolar&&(e.center=t.center,e.startAngle=t.startAngle,e.endAngle=t.endAngle)}n._id="axis-"+f,r.isNil(p)||(n._id="axis-"+f+p),new a[o](r.mix(e,n))})},e.clear=function(){this.axes={},this.frontPlot.clear(),this.backPlot.clear()},t}();t.exports=u},function(t,e,n){"use strict";var i=n(45);n(175),t.exports=i},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(45),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){t.prototype._initDefaultCfg.call(this),this.start=null,this.end=null},n.getOffsetPoint=function(t){var e=this.start,n=this.end;return{x:e.x+(n.x-e.x)*t,y:e.y+(n.y-e.y)*t}},n.getAxisVector=function(){var t=this.start,e=this.end;return[e.x-t.x,e.y-t.y]},n.drawLine=function(t){var e=this.getContainer(t.top),n=this.start,i=this.end;e.addShape("line",{className:"axis-line",attrs:c.mix({x1:n.x,y1:n.y,x2:i.x,y2:i.y},t)})},e}(l);l.Line=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=a(n(42)),l=a(n(177)),f=a(n(178)),h=n(0),p=n(66),d=n(67),g=n(70).requestAnimationFrame,v=function(t){function e(e){var n;return n=t.call(this)||this,n._attrs=h.mix({type:"canvas",children:[]},e),n._initPixelRatio(),n._initCanvas(),n}(0,u.default)(e,t);i(e);var n=e.prototype;return n.get=function(t){return this._attrs[t]},n.set=function(t,e){this._attrs[t]=e},n._initPixelRatio=function(){this.get("pixelRatio")||this.set("pixelRatio",h.getPixelRatio())},n.beforeDraw=function(){var t=this._attrs.context,e=this._attrs.el;t&&t.clearRect&&t.clearRect(0,0,e.width,e.height)},n._initCanvas=function(){var t=this,e=t.get("el"),n=t.get("context");if(!e&&!n)throw new Error("Please specify the id, el or context of the chart!");var i;i=e?h.isString(e)?h.getDomById(e):e:f.default.create(n),n&&i&&!i.getContext&&(i.getContext=function(){return n});var r=t.get("width");r||(r=h.getWidth(i));var a=t.get("height");a||(a=h.getHeight(i)),t.set("canvas",this),t.set("el",i),t.set("context",n||i.getContext("2d")),t.changeSize(r,a);var s=new l.default({canvas:this,el:i});t.set("eventController",s)},n.changeSize=function(t,e){var n=this.get("pixelRatio"),i=this.get("el");i.style&&(i.style.width=t+"px",i.style.height=e+"px"),h.isCanvasElement(i)&&(i.width=t*n,i.height=e*n,1!==n&&this.get("context").scale(n,n)),this.set("width",t),this.set("height",e)},n.getWidth=function(){var t=this.get("pixelRatio");return this.get("width")*t},n.getHeight=function(){var t=this.get("pixelRatio");return this.get("height")*t},n.getPointByClient=function(t,e){var n=this.get("el"),i=n.getBoundingClientRect(),r=i.right-i.left,a=i.bottom-i.top;return{x:(t-i.left)*(n.width/r),y:(e-i.top)*(n.height/a)}},n._beginDraw=function(){this._attrs.toDraw=!0},n._endDraw=function(){this._attrs.toDraw=!1},n.draw=function(){function t(){e.set("animateHandler",g(function(){e.set("animateHandler",void 0),e.get("toDraw")&&t()})),e.beforeDraw();try{for(var n=e._attrs.context,i=e._attrs.children,r=0,a=i.length;rMath.abs(i)?n>0?"right":"left":i>0?"down":"up"},s=function(t,e){var n=Math.abs(e.x-t.x),i=Math.abs(e.y-t.y);return Math.sqrt(n*n+i*i)},o=function(t,e){return{x:t.x+(e.x-t.x)/2,y:t.y+(e.y-t.y)/2}},u=function(t,e){if(t){for(var n=[],a=t.length,s=0;s1?(e.startDistance=s(n[0],n[1]),e.center=o(n[0],n[1])):e.pressTimeout=setTimeout(function(){t.direction="none",e.emitStart("press",t),e.emitEvent("press",t),e.eventType="press"},c))},this._move=function(t){var n=u(t.touches,e.canvas);if(n){e.clearPressTimeout(),t.points=n,e.emitEvent("touchmove",t);var i=e.startPoints;if(i)if(n.length>1){var r=e.startDistance,o=s(n[0],n[1]);t.zoom=o/r,t.center=e.center,e.emitStart("pinch",t),e.emitEvent("pinch",t)}else{var c=n[0].x-i[0].x,l=n[0].y-i[0].y,f=e.direction||a(i[0],n[0]);e.direction=f;var h=e.getEventType(n);t.direction=f,t.deltaX=c,t.deltaY=l,e.emitStart(h,t),e.emitEvent(h,t);var p=e.lastMoveTime,d=Date.now();d-p>0&&(e.prevMoveTime=p,e.prevMovePoints=e.lastMovePoints,e.lastMoveTime=d,e.lastMovePoints=n)}}},this._end=function(t){e.emitEnd(t),e.emitEvent("touchend",t);var n=e.lastMoveTime;if(Date.now()-n<100){var i=n-(e.prevMoveTime||e.startTime);if(i>0){var r=e.prevMovePoints||e.startPoints,o=e.lastMovePoints,u=s(r[0],o[0])/i;u>.3&&(t.velocity=u,t.direction=a(r[0],o[0]),e.emitEvent("swipe",t))}}e.reset();var c=t.touches;c&&c.length>0&&e._start(t)},this._cancel=function(t){e.emitEvent("touchcancel",t),e.reset()},this.canvas=n,this.delegateEvent(i),this.processEvent={}}var e=t.prototype;return e.delegateEvent=function(t){t.addEventListener("click",this._click),t.addEventListener("touchstart",this._start),t.addEventListener("touchmove",this._move),t.addEventListener("touchend",this._end),t.addEventListener("touchcancel",this._cancel)},e.emitEvent=function(t,e){this.canvas.emit(t,e)},e.getEventType=function(t){var e=this.eventType,n=this.canvas,i=this.startTime,r=this.startPoints;if(e)return e;var a,o=n.__events.pan;return a=o&&o.length?Date.now()-i>c&&s(r[0],t[0])<10?"press":"pan":"press",this.eventType=a,a},e.enable=function(t){this.processEvent[t]=!0},e.isProcess=function(t){return this.processEvent[t]},e.emitStart=function(t,e){this.isProcess(t)||(this.enable(t),this.emitEvent(t+"start",e))},e.emitEnd=function(t){var e=this,n=this.processEvent;Object.keys(n).forEach(function(i){e.emitEvent(i+"end",t),delete n[i]})},e.clearPressTimeout=function(){this.pressTimeout&&(clearTimeout(this.pressTimeout),this.pressTimeout=0)},e.reset=function(){this.clearPressTimeout(),this.startTime=0,this.startPoints=null,this.startDistance=0,this.direction=null,this.eventType=null,this.pinch=!1,this.prevMoveTime=0,this.prevMovePoints=null,this.lastMoveTime=0,this.lastMovePoints=null},t}();e.default=l},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,u.default)(t);if(r()){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,o.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}function a(t){if(!t)return!1;if(1!==t.nodeType||!t.nodeName||"canvas"!==t.nodeName.toLowerCase())return!1;var e=!1;try{t.addEventListener("eventTest",function(){e=!0}),t.dispatchEvent(new Event("eventTest"))}catch(t){e=!1}return e}var s=n(1);e.__esModule=!0,e.default=void 0;var o=s(n(2)),u=s(n(3)),c=s(n(4)),l=function(t){function e(e){var n;return n=t.call(this)||this,n.context=e,n.width=0,n.height=0,n.style={},n.currentStyle={},n.isCanvasElement=!0,n}(0,c.default)(e,t);i(e);var n=e.prototype;return n.getContext=function(){return this.context},n.getBoundingClientRect=function(){return{top:0,right:this.width,bottom:this.height,left:0}},n.addEventListener=function(t,e){this.on(t,e)},n.removeEventListener=function(t,e){this.off(t,e)},n.dispatchEvent=function(t,e){this.emit(t,e)},e}(s(n(42)).default),f={create:function(t){return t?a(t.canvas)?t.canvas:new l(t):null}};e.default=f},function(t,e,n){"use strict";function i(t,e){return(t%e+e)%e}function r(t,e){o.each(t,function(t){t=t.split(":"),e.addColorStop(Number(t[0]),t[1])})}function a(t,e,n){var a=t.split(" "),s=a[0].slice(2,a[0].length-1);s=i(parseFloat(s)*Math.PI/180,2*Math.PI);var o,u,c=a.slice(1),l=e.getBBox(),f=l.minX,h=l.minY,p=l.maxX,d=l.maxY;s>=0&&s<.5*Math.PI?(o={x:f,y:h},u={x:p,y:d}):.5*Math.PI<=s&&s1e-4||0===r&&a<0)&&(t.arc(n,i,s,r,a,u),t.lineTo(Math.cos(a)*o+n,Math.sin(a)*o+i),0!==o&&t.arc(n,i,o,a,r,!u)),t.closePath()},n.calculateBox=function(){var t=this.get("attrs"),e=t.x,n=t.y,i=t.r,r=t.r0,a=t.startAngle,s=t.endAngle,o=t.anticlockwise,u=l.getBBoxFromArc(e,n,i,a,s,o),c=l.getBBoxFromArc(e,n,r,a,s,o);return{minX:Math.min(u.minX,c.minX),minY:Math.min(u.minY,c.minY),maxX:Math.max(u.maxX,c.maxX),maxY:Math.max(u.maxY,c.maxY)}},e}(c);c.Sector=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(10),f=n(188),h=0,p={},d=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initProperties=function(){t.prototype._initProperties.call(this),this._attrs.canFill=!0,this._attrs.canStroke=!0,this._attrs.type="text"},n.getDefaultAttrs=function(){return{lineWidth:0,lineCount:1,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom",lineHeight:null,textArr:null}},n._getFontStyle=function(){var t=this._attrs.attrs,e=t.fontSize,n=t.fontFamily,i=t.fontWeight;return t.fontStyle+" "+t.fontVariant+" "+i+" "+e+"px "+n},n._afterAttrsSet=function(){var t=this._attrs.attrs;if(t.font=this._getFontStyle(),t.text){var e=t.text,n=null,i=1;c.isString(e)&&-1!==e.indexOf("\n")&&(i=(n=e.split("\n")).length),t.lineCount=i,t.textArr=n}this.set("attrs",t)},n._getTextHeight=function(){var t=this._attrs.attrs;if(t.height)return t.height;var e=t.lineCount,n=1*t.fontSize;return e>1?n*e+this._getSpaceingY()*(e-1):n},n._getSpaceingY=function(){var t=this._attrs.attrs,e=t.lineHeight,n=1*t.fontSize;return e?e-n:.14*n},n.drawInner=function(t){var e=this,n=e._attrs.attrs,i=n.text,r=n.x,a=n.y;if(!(c.isNil(i)||isNaN(r)||isNaN(a))){var s=n.textArr,o=1*n.fontSize,u=e._getSpaceingY();n.rotate&&(t.translate(r,a),t.rotate(n.rotate),r=0,a=0);var l,f=n.textBaseline;s&&(l=e._getTextHeight());var h;if(e.hasFill()){var p=n.fillOpacity;if(c.isNil(p)||1===p||(t.globalAlpha=p),s)for(var d=0,g=s.length;d5e3&&(h=0,p={}),h++,p[a]=s,s}},e}(l);l.Text=d,t.exports=d},function(t,e,n){"use strict";var i={calcRotatedBox:function(t){var e=t.width,n=t.height,i=t.rotate,r=Math.abs(i);return{width:Math.abs(e*Math.cos(r)+n*Math.sin(r)),height:Math.abs(n*Math.cos(r)+e*Math.sin(r))}}};t.exports=i},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(10),l=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initProperties=function(){t.prototype._initProperties.call(this),this._attrs.canFill=!0,this._attrs.canStroke=!0,this._attrs.createPath=null,this._attrs.type="custom"},n.createPath=function(t){var e=this.get("createPath");e&&e.call(this,t)},n.calculateBox=function(){var t=this.get("calculateBox");return t&&t.call(this)},e}(c);c.Custom=l,t.exports=l},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(72),l=n(17);n(68);var f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);return e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="line",e.sortable=!0,e},e}(c);l.Line=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,u.default)(t);if(r()){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,o.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(22)),o=a(n(2)),u=a(n(3)),c=a(n(4)),l=n(17),f=n(0),h=n(73);n(192);var p=function(t){function e(e){var n;return n=t.call(this,e)||this,f.mix((0,s.default)(n),h),n}(0,c.default)(e,t);i(e);var n=e.prototype;return n.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="interval",e.shapeType="interval",e.generatePoints=!0,e},n.init=function(){t.prototype.init.call(this),this.initEvent()},n.createShapePointsCfg=function(e){var n=t.prototype.createShapePointsCfg.call(this,e);return n.size=this.getNormalizedSize(e),n},n.clearInner=function(){t.prototype.clearInner.call(this),this.set("defaultSize",null)},e}(l);l.Interval=p,t.exports=p},function(t,e,n){"use strict";function i(t){var e=t.x,n=t.y,i=t.y0,r=t.size,a=i,o=n;s.isArray(n)&&(o=n[1],a=n[0]);var u,c;return s.isArray(e)?(u=e[0],c=e[1]):(u=e-r/2,c=e+r/2),[{x:u,y:a},{x:u,y:o},{x:c,y:o},{x:c,y:a}]}function r(t){for(var e=[],n=[],i=0,r=t.length;i=1.5*Math.PI&&(v-=2*Math.PI),y>=1.5*Math.PI&&(y-=2*Math.PI),e.addShape("Sector",{className:"interval",attrs:s.mix({x:l,y:f,r:x,r0:m,startAngle:v,endAngle:y},i)})}var _=r(n);return e.addShape("rect",{className:"interval",attrs:s.mix(_,i)})}}),["pyramid","funnel"].forEach(function(t){o.registerShape("interval",t,{getPoints:function(t){return t.size=2*t.size,i(t)},draw:function(e,n){var i=this.parsePoints(e.points),r=this.parsePoints(e.nextPoints),o=null;r?o=[i[0],i[1],r[1],r[0]]:(o=[i[0],i[1]],"pyramid"===t?o.push(a(i[2],i[3])):o.push(i[2],i[3]));var u=s.mix({fill:e.color,points:o},c.shape.interval,e.style);return n.addShape("polygon",{className:"interval",attrs:u})}})}),t.exports=l},function(t,e,n){"use strict";t.exports={Stack:n(194),Dodge:n(196),Symmetric:n(198)}},function(t,e,n){"use strict";var i=n(195);t.exports=i},function(t,e,n){function i(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=n(34),a=n(35),s=n(33),o=function(t){function e(){return t.apply(this,arguments)||this}i(e,t);var n=e.prototype;return n._initDefaultCfg=function(){this.xField=null,this.yField=null},n.processAdjust=function(t){this.processStack(t)},n.processStack=function(t){var e=this,n=e.xField,i=e.yField,s=t.length,o={positive:{},negative:{}};e.reverseOrder&&(t=t.slice(0).reverse());for(var u=0;u=0?"positive":"negative";o[v][g]||(o[v][g]=0),h[i]=[o[v][g],d+o[v][g]],o[v][g]+=d}}},e}(s);s.Stack=o,t.exports=o},function(t,e,n){"use strict";var i=n(197);t.exports=i},function(t,e,n){function i(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=n(33),a=n(15),s=function(t){function e(){return t.apply(this,arguments)||this}i(e,t);var n=e.prototype;return n._initDefaultCfg=function(){this.marginRatio=.5,this.dodgeRatio=.5,this.adjustNames=["x","y"]},n.getDodgeOffset=function(t,e,n){var i=this,r=t.pre,a=t.next,s=a-r,o=s*i.dodgeRatio/n,u=i.marginRatio*o;return(r+a)/2+(.5*(s-n*o-(n-1)*u)+((e+1)*o+e*u)-.5*o-.5*s)},n.processAdjust=function(t){var e=this,n=t.length,i=e.xField;a(t,function(t,r){for(var a=0,s=t.length;as&&(n=t,s=o)}),n}}},function(t,e,n){var i=n(27);t.exports=function(t){return i(t,"Function")}},function(t,e){t.exports=function(t){for(var e=[],n=0;n0&&c<=1&&(i*=c),this.x={start:a.startAngle,end:a.endAngle},this.y={start:i*s,end:i},this.center=r,this.circleRadius=i},n._convertPoint=function(t){var e=this,n=e.center,i=e.transposed,r=i?"y":"x",a=i?"x":"y",s=e.x,o=e.y,u=s.start+(s.end-s.start)*t[r],c=o.start+(o.end-o.start)*t[a];return{x:n.x+Math.cos(u)*c,y:n.y+Math.sin(u)*c}},n._invertPoint=function(t){var e=this,n=e.center,i=e.transposed,r=e.x,a=e.y,s=i?"y":"x",o=i?"x":"y",u=[1,0,0,1,0,0];f.rotate(u,u,r.start);var c=[1,0];l.transformMat2d(c,c,u),c=[c[0],c[1]];var h=[t.x-n.x,t.y-n.y];if(l.zero(h))return{x:0,y:0};var p=l.angleTo(c,h,r.end0?g:-g;var v=(d-a.start)/(a.end-a.start),y={};return y[s]=g,y[o]=v,y},e}(c);c.Polar=h,t.exports=h},function(t,e,n){var i=n(48),r=n(222);t.exports={toTimeStamp:function(t){return i(t)&&(t=t.indexOf("T")>0?new Date(t).getTime():new Date(t.replace(/-/gi,"/")).getTime()),r(t)&&(t=t.getTime()),t}}},function(t,e,n){"use strict";var i=n(0),r=n(16).Group,a=n(76),s=function(){function t(t){i.deepMix(this,this.getDefaultCfg(),t),this._init(),this._renderTitle(),this._renderItems()}var e=t.prototype;return e.getDefaultCfg=function(){return{showTitle:!1,title:null,items:null,titleGap:12,itemGap:10,itemMarginBottom:12,itemFormatter:null,itemWidth:null,wordSpace:6,x:0,y:0,layout:"horizontal",joinString:": "}},e._init=function(){var t=new r({zIndex:this.zIndex||0});this.container=t;var e=t.addGroup();this.wrapper=e;var n=e.addGroup({className:"itemsGroup"});this.itemsGroup=n,this.parent&&this.parent.add(t)},e._renderTitle=function(t){t=t||this.title;var e=this.titleShape,n=0;if(this.showTitle&&t){if(e&&!e.get("destroyed"))e.attr("text",t);else{var r=this.wrapper,a=this.titleStyle;e=r.addShape("text",{className:"title",attrs:i.mix({x:0,y:0,text:t},a)}),this.titleShape=e}n=e.getBBox().height+this.titleGap}this._titleHeight=n},e._renderItems=function(t){var e=this;(t=t||e.items)&&(e.reversed&&t.reverse(),i.each(t,function(t,n){e._addItem(t,n)}),t.length>1&&this._adjustItems(),this._renderBackground())},e._renderBackground=function(){var t=this.background;if(t){var e=this.container,n=this.wrapper.getBBox(),r=n.minX,a=n.minY,s=n.width,o=n.height,u=t.padding||[0,0,0,0];u=i.parsePadding(u);var c=i.mix({x:r-u[3],y:a-u[0],width:s+u[1]+u[3],height:o+u[0]+u[2]},t),l=this.backShape;l?l.attr(c):l=e.addShape("Rect",{zIndex:-1,attrs:c}),this.backShape=l,e.sort()}},e._addItem=function(t){var e=this.itemsGroup.addGroup({name:t.name,value:t.value,dataValue:t.dataValue,checked:t.checked}),n=this.unCheckStyle,r=this.unCheckColor,s=this.nameStyle,o=this.valueStyle,u=this.wordSpace,c=t.marker,l=t.value,f=0;if(r&&(n.fill=r),c){var h=c.radius||3,p=i.mix({x:h,y:this._titleHeight},c);!1===t.checked&&i.mix(p,n);var d=new a({className:"item-marker",attrs:p});e.add(d),f+=d.getBBox().width+u}var g,v=t.name;if(v){var y=this.joinString||"";v=l?v+y:v,g=e.addShape("text",{className:"name",attrs:i.mix({x:f,y:this._titleHeight,text:this._formatItemValue(v)},s,!1===t.checked?n:null)})}if(l){var m=f;g&&(m+=g.getBBox().width),e.addShape("text",{className:"value",attrs:i.mix({x:m,y:this._titleHeight,text:l},o,!1===t.checked?n:null)})}return e},e._formatItemValue=function(t){var e=this.itemFormatter;return e&&(t=e.call(this,t)),t},e._getMaxItemWidth=function(){var t=this.itemWidth;if(i.isNumber(t)||i.isNil(t))return t;if("auto"===t){for(var e=this.itemsGroup.get("children"),n=e.length,r=0,a=0;a1e-4&&(o++,u=0),p.moveTo(u,o*e),l.push({x:u,y:o*e+s-g/2,width:1.375*v,height:1.375*g}),u+=t+r}this.legendHitBoxes=l},e._adjustVertical=function(){for(var t,e,n=this.maxLength,r=this.itemsGroup,a=this.itemGap,s=this.itemMarginBottom,o=this.itemWidth,u=this._titleHeight,c=r.get("children"),l=0,f=0,h=0,p=[],d=0,g=c.length;df&&(f=t+a),n-ln.max&&(n.max=e.max)):"timeCat"===s?(r.each(o,function(t,e){o[e]=i.toTimeStamp(t)}),o.sort(function(t,e){return t-e}),n=o):n=o,n}}},function(t,e,n){"use strict";var i=n(17);n(210),n(72),n(190),n(212),n(191),n(214),n(216),t.exports=i},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(17);n(211);var f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="point",e.shapeType="point",e.generatePoints=!1,e},n.draw=function(t,e){var n=this,i=n.get("container");c.each(t,function(t){var r=t.shape,a=n.getDrawCfg(t);if(c.isArray(t.y)){var s=n.hasAdjust("stack");c.each(t.y,function(o,u){a.y=o,s&&0===u||n.drawShape(r,t,a,i,e)})}else c.isNil(t.y)||n.drawShape(r,t,a,i,e)})},e}(l);l.Point=f,t.exports=f},function(t,e,n){"use strict";function i(t){var e={lineWidth:0,stroke:t.color,fill:t.color};return t.size&&(e.size=t.size),a.mix(e,t.style),a.mix({},s.shape.point,e)}function r(t,e,n){if(0!==t.size){var r=i(t),s=r.r||r.size,o=t.x,u=a.isArray(t.y)?t.y:[t.y];"hollowCircle"===n&&(r.lineWidth=1,r.fill=null);for(var c=0,l=u.length;c0?n="left":i[0]<0?n="right":(n="center",i[1]>0?r="top":i[1]<0&&(r="bottom")),{textAlign:n,textBaseline:r}},n.getAxisVector=function(t){var e=this.center,n=this.offsetFactor;return[(t.y-e.y)*n,-1*(t.x-e.x)*n]},n.drawLine=function(t){var e=this.center,n=this.radius,i=this.startAngle,r=this.endAngle;this.getContainer(t.top).addShape("arc",{className:"axis-line",attrs:c.mix({x:e.x,y:e.y,r:n,startAngle:i,endAngle:r},t)})},e}(l);l.Circle=f,t.exports=f},function(t,e,n){"use strict";var i=n(220);t.exports=i},function(t,e,n){function i(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=n(26),a=n(69),s=n(221),o=n(65),u=n(204),c=n(15),l=n(36),f=n(44),h=n(48),p=function(t){function e(){return t.apply(this,arguments)||this}i(e,t);var n=e.prototype;return n._initDefaultCfg=function(){t.prototype._initDefaultCfg.call(this),this.type="timeCat",this.sortable=!0,this.tickCount=5,this.mask="YYYY-MM-DD"},n.init=function(){var t=this,e=this.values;c(e,function(n,i){e[i]=t._toTimeStamp(n)}),this.sortable&&e.sort(function(t,e){return t-e}),t.ticks||(t.ticks=this.calculateTicks())},n.calculateTicks=function(){var t=this,e=t.tickCount;return e?o({maxCount:e,data:t.values,isRounding:t.isRounding}).ticks:t.values},n.translate=function(t){t=this._toTimeStamp(t);var e=this.values.indexOf(t);return-1===e&&(e=l(t)&&t-1?r/(this.values.length-1):0,n+e*(i-n)},n.getText=function(t){var e="",n=this.translate(t);e=n>-1?this.values[n]:t;var i=this.formatter;return e=parseInt(e,10),e=i?i(e):s.format(e,this.mask)},n.getTicks=function(){var t=this,e=this.ticks,n=[];return c(e,function(e){var i;i=f(e)?e:{text:h(e)?e:t.getText(e),value:t.scale(e),tickValue:e},n.push(i)}),n},n._toTimeStamp=function(t){return u.toTimeStamp(t)},e}(a);r.TimeCat=p,t.exports=p},function(t,e,n){var i;!function(r){"use strict";function a(t,e){for(var n=[],i=0,r=t.length;i3?0:(t-t%10!=10)*t%10]}};var _={D:function(t){return t.getDate()},DD:function(t){return o(t.getDate())},Do:function(t,e){return e.DoFn(t.getDate())},d:function(t){return t.getDay()},dd:function(t){return o(t.getDay())},ddd:function(t,e){return e.dayNamesShort[t.getDay()]},dddd:function(t,e){return e.dayNames[t.getDay()]},M:function(t){return t.getMonth()+1},MM:function(t){return o(t.getMonth()+1)},MMM:function(t,e){return e.monthNamesShort[t.getMonth()]},MMMM:function(t,e){return e.monthNames[t.getMonth()]},YY:function(t){return String(t.getFullYear()).substr(2)},YYYY:function(t){return o(t.getFullYear(),4)},h:function(t){return t.getHours()%12||12},hh:function(t){return o(t.getHours()%12||12)},H:function(t){return t.getHours()},HH:function(t){return o(t.getHours())},m:function(t){return t.getMinutes()},mm:function(t){return o(t.getMinutes())},s:function(t){return t.getSeconds()},ss:function(t){return o(t.getSeconds())},S:function(t){return Math.round(t.getMilliseconds()/100)},SS:function(t){return o(Math.round(t.getMilliseconds()/10),2)},SSS:function(t){return o(t.getMilliseconds(),3)},a:function(t,e){return t.getHours()<12?e.amPm[0]:e.amPm[1]},A:function(t,e){return t.getHours()<12?e.amPm[0].toUpperCase():e.amPm[1].toUpperCase()},ZZ:function(t){var e=t.getTimezoneOffset();return(e>0?"-":"+")+o(100*Math.floor(Math.abs(e)/60)+Math.abs(e)%60,4)}},S={D:[l,function(t,e){t.day=e}],Do:[new RegExp(l.source+p.source),function(t,e){t.day=parseInt(e,10)}],M:[l,function(t,e){t.month=e-1}],YY:[l,function(t,e){var n=+(""+(new Date).getFullYear()).substr(0,2);t.year=""+(e>68?n-1:n)+e}],h:[l,function(t,e){t.hour=e}],m:[l,function(t,e){t.minute=e}],s:[l,function(t,e){t.second=e}],YYYY:[h,function(t,e){t.year=e}],S:[/\d/,function(t,e){t.millisecond=100*e}],SS:[/\d{2}/,function(t,e){t.millisecond=10*e}],SSS:[f,function(t,e){t.millisecond=e}],d:[l,g],ddd:[p,g],MMM:[p,s("monthNamesShort")],MMMM:[p,s("monthNames")],a:[p,function(t,e,n){var i=e.toLowerCase();i===n.amPm[0]?t.isPm=!1:i===n.amPm[1]&&(t.isPm=!0)}],ZZ:[/([\+\-]\d\d:?\d\d|Z)/,function(t,e){"Z"===e&&(e="+00:00");var n,i=(e+"").match(/([\+\-]|\d\d)/gi);i&&(n=60*i[1]+parseInt(i[2],10),t.timezoneOffset="+"===i[0]?n:-n)}]};S.dd=S.d,S.dddd=S.ddd,S.DD=S.D,S.mm=S.m,S.hh=S.H=S.HH=S.h,S.MM=S.M,S.ss=S.s,S.A=S.a,u.masks={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},u.format=function(t,e,n){var i=n||u.i18n;if("number"==typeof t&&(t=new Date(t)),"[object Date]"!==Object.prototype.toString.call(t)||isNaN(t.getTime()))throw new Error("Invalid Date in fecha.format");var r=[];return e=(e=u.masks[e]||e||u.masks.default).replace(d,function(t,e){return r.push(e),"??"}),(e=e.replace(c,function(e){return e in _?_[e](t,i):e.slice(1,e.length-1)})).replace(/\?\?/g,function(){return r.shift()})},u.parse=function(t,e,n){var i=n||u.i18n;if("string"!=typeof e)throw new Error("Invalid format in fecha.parse");if(e=u.masks[e]||e,t.length>1e3)return!1;var r=!0,a={};if(e.replace(c,function(e){if(S[e]){var n=S[e],s=t.search(n[0]);~s?t.replace(n[0],function(e){return n[1](a,e,i),t=t.substr(s+e.length),e}):r=!1}return S[e]?"":e.slice(1,e.length-1)}),!r)return!1;var s=new Date;!0===a.isPm&&null!=a.hour&&12!=+a.hour?a.hour=+a.hour+12:!1===a.isPm&&12==+a.hour&&(a.hour=0);var o;return null!=a.timezoneOffset?(a.minute=+(a.minute||0)-+a.timezoneOffset,o=new Date(Date.UTC(a.year||s.getFullYear(),a.month||0,a.day||1,a.hour||0,a.minute||0,a.second||0,a.millisecond||0))):o=new Date(a.year||s.getFullYear(),a.month||0,a.day||1,a.hour||0,a.minute||0,a.second||0,a.millisecond||0),o},void 0!==t&&t.exports?t.exports=u:void 0!==(i=function(){return u}.call(e,n,e,t))&&(t.exports=i)}()},function(t,e,n){var i=n(27);t.exports=function(t){return i(t,"Date")}},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="arc",this.start=[],this.end=[],this.style={stroke:"#999",lineWidth:1}},n.render=function(t,e){var n=this,i=n.parsePoint(t,n.start),r=n.parsePoint(t,n.end);if(i&&r){var a=t.center,s=Math.sqrt((i.x-a.x)*(i.x-a.x)+(i.y-a.y)*(i.y-a.y)),o=Math.atan2(i.y-a.y,i.x-a.x),u=Math.atan2(r.y-a.y,r.x-a.x),l=e.addShape("arc",{className:"guide-arc",attrs:c.mix({x:a.x,y:a.y,r:s,startAngle:o,endAngle:u},n.style)});return n.element=l,l}},e}(l);l.Arc=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,l.default)(t);if(r()){var i=(0,l.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,c.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}function a(t,e,n,i){var r=[];return"left"===t&&"top"===e?(r[0]=0,r[1]=0):"right"===t&&"top"===e?(r[0]=-n,r[1]=0):"left"===t&&"bottom"===e?(r[0]=0,r[1]=Math.floor(-i)):"right"===t&&"bottom"===e?(r[0]=Math.floor(-n),r[1]=Math.floor(-i)):"right"===t&&"middle"===e?(r[0]=Math.floor(-n),r[1]=Math.floor(-i/2)):"left"===t&&"middle"===e?(r[0]=0,r[1]=Math.floor(-i/2)):"center"===t&&"bottom"===e?(r[0]=Math.floor(-n/2),r[1]=Math.floor(-i)):"center"===t&&"top"===e?(r[0]=Math.floor(-n/2),r[1]=0):(r[0]=Math.floor(-n/2),r[1]=Math.floor(-i/2)),r}function s(t,e){for(var n in e)e.hasOwnProperty(n)&&(t.style[n]=e[n]);return t}function o(t){var e=document.createElement("div");return t=t.replace(/(^\s*)|(\s*$)/g,""),e.innerHTML=""+t,e.childNodes[0]}var u=n(1),c=u(n(2)),l=u(n(3)),f=u(n(4)),h=n(0),p=n(23),d=function(t){function e(){return t.apply(this,arguments)||this}(0,f.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="html",this.position=null,this.alignX="center",this.alignY="middle",this.offsetX=null,this.offsetY=null,this.html=null},n.render=function(t,e){var n=this,i=n.parsePoint(t,n.position);if(i){var r=o(n.html);r=s(r,{position:"absolute",top:Math.floor(i.y)+"px",left:Math.floor(i.x)+"px",visibility:"hidden"});var u=e.get("canvas").get("el"),c=u.parentNode;c=s(c,{position:"relative"});var l=o('
');c.appendChild(l),l.appendChild(r);var f=u.offsetTop,p=u.offsetLeft,d=n.alignX,g=n.alignY,v=n.offsetX,y=n.offsetY,m=a(d,g,h.getWidth(r),h.getHeight(r));i.x=i.x+m[0]+p,i.y=i.y+m[1]+f,v&&(i.x+=v),y&&(i.y+=y),s(r,{top:Math.floor(i.y)+"px",left:Math.floor(i.x)+"px",visibility:"visible"}),n.element=l}},n.remove=function(){var t=this.element;t&&t.parentNode&&t.parentNode.removeChild(t)},e}(p);p.Html=d,t.exports=d},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="line",this.start=[],this.end=[],this.style={stroke:"#000",lineWidth:1}},n.render=function(t,e){var n=[];if(n[0]=this.parsePoint(t,this.start),n[1]=this.parsePoint(t,this.end),n[0]&&n[1]){var i=e.addShape("Line",{className:"guide-line",attrs:c.mix({x1:n[0].x,y1:n[0].y,x2:n[1].x,y2:n[1].y},this.style)});return this.element=i,i}},e}(l);l.Line=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="rect",this.start=[],this.end=[],this.style={fill:"#CCD7EB",opacity:.4}},n.render=function(t,e){var n=this.parsePoint(t,this.start),i=this.parsePoint(t,this.end);if(n&&i){var r=e.addShape("rect",{className:"guide-rect",attrs:c.mix({x:Math.min(n.x,i.x),y:Math.min(n.y,i.y),width:Math.abs(i.x-n.x),height:Math.abs(n.y-i.y)},this.style)});return this.element=r,r}},e}(l);l.Rect=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="text",this.position=null,this.content=null,this.style={fill:"#000"},this.offsetX=0,this.offsetY=0},n.render=function(t,e){var n=this.position,i=this.parsePoint(t,n);if(i){var r=this.content,a=this.style,s=this.offsetX,o=this.offsetY;s&&(i.x+=s),o&&(i.y+=o);var u=e.addShape("text",{className:"guide-text",attrs:c.mix({x:i.x,y:i.y,text:r},a)});return this.element=u,u}},e}(l);l.Text=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="tag",this.position=null,this.content=null,this.direct="tl",this.autoAdjust=!0,this.offsetX=0,this.offsetY=0,this.side=4,this.background={padding:5,radius:2,fill:"#1890FF"},this.textStyle={fontSize:12,fill:"#fff",textAlign:"center",textBaseline:"middle"},this.withPoint=!0,this.pointStyle={fill:"#1890FF",r:3,lineWidth:1,stroke:"#fff"}},n._getDirect=function(t,e,n,i){var r=this.direct,a=this.side,s=t.get("canvas"),o=s.get("width"),u=s.get("height"),c=e.x,l=e.y,f=r[0],h=r[1];"t"===f&&l-a-i<0?f="b":"b"===f&&l+a+i>u&&(f="t");var p="c"===f?a:0;return"l"===h&&c-p-n<0?h="r":"r"===h&&c+p+n>o?h="l":"c"===h&&(n/2+c+p>o?h="l":c-n/2-p<0&&(h="r")),r=f+h},n.render=function(t,e){var n=this.parsePoint(t,this.position);if(n&&!isNaN(n.x)&&!isNaN(n.y)){var i=this.content,r=this.background,a=this.textStyle,s=[],o=e.addGroup({className:"guide-tag"});if(this.withPoint){var u=o.addShape("Circle",{className:"guide-tag-point",attrs:c.mix({x:n.x,y:n.y},this.pointStyle)});s.push(u)}var l=o.addGroup(),f=l.addShape("text",{className:"guide-tag-text",zIndex:1,attrs:c.mix({x:0,y:0,text:i},a)});s.push(f);var h=f.getBBox(),p=c.parsePadding(r.padding),d=h.width+p[1]+p[3],g=h.height+p[0]+p[2],v=h.minY-p[0],y=h.minX-p[3],m=l.addShape("rect",{className:"guide-tag-bg",zIndex:-1,attrs:c.mix({x:y,y:v,width:d,height:g},r)});s.push(m);var x,_=this.autoAdjust?this._getDirect(e,n,d,g):this.direct,S=this.side,b=n.x+this.offsetX,P=n.y+this.offsetY,C=c.parsePadding(r.radius);"tl"===_?(x=[{x:d+y-S-1,y:g+v-1},{x:d+y,y:g+v-1},{x:d+y,y:g+S+v}],C[2]=0,b-=d,P=P-S-g):"cl"===_?(x=[{x:d+y-1,y:(g-S)/2+v-1},{x:d+y-1,y:(g+S)/2+v+1},{x:d+S+y,y:g/2+v}],b=b-d-S,P-=g/2):"bl"===_?(x=[{x:d+y,y:-S+v},{x:d+y-S-1,y:v+1},{x:d+y,y:v+1}],C[1]=0,b-=d,P+=S):"bc"===_?(x=[{x:d/2+y,y:-S+v},{x:(d-S)/2+y-1,y:v+1},{x:(d+S)/2+y+1,y:v+1}],b-=d/2,P+=S):"br"===_?(x=[{x:y,y:v-S},{x:y,y:v+1},{x:y+S+1,y:v+1}],C[0]=0,P+=S):"cr"===_?(x=[{x:y-S,y:g/2+v},{x:y+1,y:(g-S)/2+v-1},{x:y+1,y:(g+S)/2+v+1}],b+=S,P-=g/2):"tr"===_?(x=[{x:y,y:g+S+v},{x:y,y:g+v-1},{x:S+y+1,y:g+v-1}],C[3]=0,P=P-g-S):"tc"===_&&(x=[{x:(d-S)/2+y-1,y:g+v-1},{x:(d+S)/2+y+1,y:g+v-1},{x:d/2+y,y:g+S+v}],b-=d/2,P=P-g-S);var M=l.addShape("Polygon",{className:"guide-tag-side",zIndex:0,attrs:{points:x,fill:r.fill}});return s.push(M),m.attr("radius",C),l.moveTo(b-y,P-v),l.sort(),this.element=o,s}},e}(l);l.Tag=f,t.exports=f},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="point",this.position=null,this.offsetX=0,this.offsetY=0,this.style={fill:"#1890FF",r:3,lineWidth:1,stroke:"#fff"}},n.render=function(t,e){var n=this.parsePoint(t,this.position);if(!n)return null;var i=e.addShape("Circle",{className:"guide-point",attrs:c.mix({x:n.x+this.offsetX,y:n.y+this.offsetY},this.style)});return this.element=i,i},e}(l);l.Point=f,t.exports=f},function(t,e,n){"use strict";function i(t){var e=t.getAttr("color");if(e){var n=e.getScale(e.type);if(n.isLinear)return n}var i=t.getXScale(),r=t.getYScale();return r||i}function r(t,e){var n,r,a=t._getGroupScales();if(a.length&&l.each(a,function(t){return r=t,!1}),r){var s=r.field;n=r.getText(e[s])}else{var o=i(t);n=o.alias||o.field}return n}function a(t,e){var n=i(t);return n.getText(e[n.field])}function s(t,e){var n=t.getAttr("position").getFields()[0],i=t.get("scales")[n];return i.getText(e[i.field])}function o(t,e){var n=-1;return l.each(t,function(t,i){if(t.title===e.title&&t.name===e.name&&t.value===e.value&&t.color===e.color)return n=i,!1}),n}function u(t){var e=[];return l.each(t,function(t){var n=o(e,t);-1===n?e.push(t):e[n]=t}),e}function c(t,e){return JSON.stringify(t)===JSON.stringify(e)}var l=n(0),f=n(6),h=n(231),p=n(37);f.tooltip=l.deepMix({triggerOn:"press",triggerOff:"pressend",alwaysShow:!1,showTitle:!1,showCrosshairs:!1,crosshairsStyle:{stroke:"rgba(0, 0, 0, 0.25)",lineWidth:1},showTooltipMarker:!0,background:{radius:1,fill:"rgba(0, 0, 0, 0.65)",padding:[3,5]},titleStyle:{fontSize:12,fill:"#fff",textAlign:"start",textBaseline:"top"},nameStyle:{fontSize:12,fill:"rgba(255, 255, 255, 0.65)",textAlign:"start",textBaseline:"middle"},valueStyle:{fontSize:12,fill:"#fff",textAlign:"start",textBaseline:"middle"},showItemMarker:!0,itemMarkerStyle:{radius:3,symbol:"circle",lineWidth:1,stroke:"#fff"},layout:"horizontal",snap:!1},f.tooltip||{});var d=function(){function t(t){var e=this;this.handleShowEvent=function(t){var n=e.chart;if(e.enable){var i=n.get("plotRange"),r=l.createEvent(t,n);if(p.isPointInPlot(r,i)||e._tooltipCfg.alwaysShow){var a=e.timeStamp,s=+new Date;s-a>16&&(e.showTooltip(r),e.timeStamp=s)}else e.hideTooltip()}},this.handleHideEvent=function(){e.enable&&e.hideTooltip()},this.enable=!0,this.cfg={},this.tooltip=null,this.chart=null,this.timeStamp=0,l.mix(this,t);var n=this.chart.get("canvas");this.canvas=n,this.canvasDom=n.get("el")}var e=t.prototype;return e._setCrosshairsCfg=function(){var t=this.chart,e=l.mix({},f.tooltip),n=t.get("geoms"),i=[];l.each(n,function(t){var e=t.get("type");-1===i.indexOf(e)&&i.push(e)});var r=t.get("coord").type;return!n.length||"cartesian"!==r&&"rect"!==r||1===i.length&&-1!==["line","area","path","point"].indexOf(i[0])&&l.mix(e,{showCrosshairs:!0}),e},e._getMaxLength=function(t){void 0===t&&(t={});var e=t,n=e.layout,i=e.plotRange;return"horizontal"===n?i.br.x-i.bl.x:i.bl.y-i.tr.y},e.render=function(){var t=this;if(!t.tooltip){var e=t.chart,n=e.get("canvas"),i=e.get("frontPlot").addGroup({className:"tooltipContainer",zIndex:10}),r=e.get("backPlot").addGroup({className:"tooltipContainer"}),a=e.get("plotRange"),s=e.get("coord"),o=t._setCrosshairsCfg(),u=t.cfg,c=l.deepMix({plotRange:a,frontPlot:i,backPlot:r,canvas:n,fixed:s.transposed||s.isPolar},o,u);c.maxLength=t._getMaxLength(c),this._tooltipCfg=c;var f=new h(c);t.tooltip=f,t.bindEvents()}},e.clear=function(){var t=this.tooltip;t&&(t.destroy(),this.unBindEvents()),this.tooltip=null,this.prePoint=null,this._lastActive=null},e._getTooltipMarkerStyle=function(t){void 0===t&&(t={});var e=t,n=e.type,i=e.items,r=this._tooltipCfg;if("rect"===n){var a,s,o,u,c=this.chart,f=c.get("plotRange"),h=f.tl,p=f.br,d=c.get("coord"),g=i[0],v=i[i.length-1],y=g.width;d.transposed?(a=h.x,s=v.y-.75*y,o=p.x-h.x,u=g.y-v.y+1.5*y):(a=g.x-.75*y,s=h.y,o=v.x-g.x+1.5*y,u=p.y-h.y),t.style=l.mix({x:a,y:s,width:o,height:u,fill:"#CCD6EC",opacity:.3},r.tooltipMarkerStyle)}else t.style=l.mix({radius:4,fill:"#fff",lineWidth:2},r.tooltipMarkerStyle);return t},e._setTooltip=function(t,e,n){void 0===n&&(n={});var i=this._lastActive,r=this.tooltip,a=this._tooltipCfg;e=u(e);var s=this.chart,o=s.get("coord"),f=s.getYScales()[0],h=a.snap;if(!1===h&&f.isLinear){var d,g,v=o.invertPoint(t),y=s.get("plotRange");p.isPointInPlot(t,y)&&(o.transposed?(d=f.invert(v.x),g=t.x,r.setXTipContent(d),r.setXTipPosition(g),r.setYCrosshairPosition(g)):(d=f.invert(v.y),g=t.y,r.setYTipContent(d),r.setYTipPosition(g),r.setXCrosshairPosition(g)))}if(a.onShow&&a.onShow({x:t.x,y:t.y,tooltip:r,items:e,tooltipMarkerCfg:n}),c(i,e))!1===h&&(l.directionEnabled(a.crosshairsType,"y")||a.showYTip)&&this.chart.get("canvas").draw();else{this._lastActive=e;var m=a.onChange;m&&m({x:t.x,y:t.y,tooltip:r,items:e,tooltipMarkerCfg:n});var x=e[0],_=x.title||x.name,S=x.x;if(e.length>1&&(S=(e[0].x+e[e.length-1].x)/2),r.setContent(_,e,o.transposed),r.setPosition(e,t),o.transposed){var b=x.y;e.length>1&&(b=(e[0].y+e[e.length-1].y)/2),r.setYTipContent(_),r.setYTipPosition(b),r.setXCrosshairPosition(b),h&&(r.setXTipContent(x.value),r.setXTipPosition(S),r.setYCrosshairPosition(S))}else r.setXTipContent(_),r.setXTipPosition(S),r.setYCrosshairPosition(S),h&&(r.setYTipContent(x.value),r.setYTipPosition(x.y),r.setXCrosshairPosition(x.y));var P=n.items;a.showTooltipMarker&&P.length?(n=this._getTooltipMarkerStyle(n),r.setMarkers(n)):r.clearMarkers(),r.show()}},e.showTooltip=function(t){var e,n,i=this,o=i.chart,u=[],c=[],h=i._tooltipCfg;h.showItemMarker&&(n=h.itemMarkerStyle);var p=o.get("geoms"),d=o.get("coord");if(l.each(p,function(i){if(i.get("visible")){var o=i.get("type"),h=i.getSnapRecords(t),p=i.get("adjust");if("interval"===o&&p&&"symmetric"===p.type)return;l.each(h,function(t){if(t.x&&t.y){var h=t.x,p=t.y,g=t._origin,v=t.color,y={x:h,y:l.isArray(p)?p[1]:p,color:v||f.defaultColor,origin:g,name:r(i,g),value:a(i,g),title:s(i,g)};n&&(y.marker=l.mix({fill:v||f.defaultColor},n)),c.push(y),-1!==["line","area","path"].indexOf(o)?(e="circle",u.push(y)):"interval"!==o||"cartesian"!==d.type&&"rect"!==d.type||(e="rect",y.width=i.getSize(t._origin),u.push(y))}})}}),c.length){var g={items:u,type:e};i._setTooltip(t,c,g)}else i.hideTooltip()},e.hideTooltip=function(){var t=this._tooltipCfg;this._lastActive=null;var e=this.tooltip;e&&(e.hide(),t.onHide&&t.onHide({tooltip:e}),this.chart.get("canvas").draw())},e._handleEvent=function(t,e,n){var i=this.canvas;l.each([].concat(t),function(t){"bind"===n?i.on(t,e):i.off(t,e)})},e.bindEvents=function(){var t=this._tooltipCfg,e=t.triggerOn,n=t.triggerOff,i=t.alwaysShow;e&&this._handleEvent(e,this.handleShowEvent,"bind"),i||this._handleEvent(n,this.handleHideEvent,"bind")},e.unBindEvents=function(){var t=this._tooltipCfg,e=t.triggerOn,n=t.triggerOff,i=t.alwaysShow;e&&this._handleEvent(e,this.handleShowEvent,"unBind"),i||this._handleEvent(n,this.handleHideEvent,"unBind")},t}();t.exports={init:function(t){var e=new d({chart:t});t.set("tooltipController",e),t.tooltip=function(t,n){return l.isObject(t)&&(n=t,t=!0),e.enable=t,n&&(e.cfg=n),this}},afterGeomDraw:function(t){var e=t.get("tooltipController");e.render(),t.showTooltip=function(t){return e.showTooltip(t),this},t.hideTooltip=function(){return e.hideTooltip(),this}},clearInner:function(t){t.get("tooltipController").clear()}}},function(t,e,n){"use strict";var i=n(0),r=n(76),a=n(205),s=n(232),o=function(){function t(t){i.deepMix(this,this.getDefaultCfg(),t);var e=this.frontPlot;if(!this.custom){var n=new a(i.mix({parent:e,zIndex:3},t));this.container=n;var r=this.fixed,o=this.background;r||(this.tooltipArrow=e.addShape("Polygon",{className:"tooltip-arrow",visible:!1,zIndex:2,attrs:i.mix({points:[]},o)}))}if(this.showXTip){var u=this.xTipBackground,c=new s({className:"xTip",background:u,visible:!1});e.add(c.container),this.xTipBox=c}if(this.showYTip){var l=this.yTipBackground,f=new s({className:"yTip",background:l,visible:!1});e.add(f.container),this.yTipBox=f}this.showCrosshairs&&this._renderCrosshairs(),e.sort()}var e=t.prototype;return e.getDefaultCfg=function(){return{showCrosshairs:!1,crosshairsStyle:{stroke:"rgba(0, 0, 0, 0.25)",lineWidth:1},crosshairsType:"y",showXTip:!1,showYTip:!1,xTip:null,xTipBackground:{radius:1,fill:"rgba(0, 0, 0, 0.65)",padding:[3,5]},yTip:null,yTipBackground:{radius:1,fill:"rgba(0, 0, 0, 0.65)",padding:[3,5]},background:null,layout:"horizontal",offsetX:0,offsetY:0}},e.setContent=function(t,e){if(this.title=t,this.items=e,!this.custom){var n=this.container;n.setTitle(t),n.setItems(e)}},e.setYTipContent=function(t){var e=this.yTip;t=i.isFunction(e)?e(t):i.mix({text:t},e),this.yTipBox&&this.yTipBox.updateContent(t)},e.setYTipPosition=function(t){var e=this.plotRange,n=this.crosshairsShapeX;if(this.showYTip){var i=this.yTipBox,r=i.getHeight(),a=i.getWidth(),s=e.tl.x-a,o=t-r/2;o<=e.tl.y&&(o=e.tl.y),o+r>=e.br.y&&(o=e.br.y-r),s<0&&(s=e.tl.x,n&&n.attr("x1",e.tl.x+a)),i.updatePosition(s,o)}},e.setXTipContent=function(t){var e=this.xTip;t=i.isFunction(e)?e(t):i.mix({text:t},e),this.xTipBox&&this.xTipBox.updateContent(t)},e.setXTipPosition=function(t){var e=this.showXTip,n=this.canvas,i=this.plotRange,r=this.xTipBox,a=this.crosshairsShapeY;if(e){var s=n.get("height"),o=r.getWidth(),u=r.getHeight(),c=t-o/2,l=i.br.y;c<=i.tl.x&&(c=i.tl.x),c+o>=i.tr.x&&(c=i.tr.x-o),s-l1?(t[0].x+t[t.length-1].x)/2:t[0].x,(g=y-f/2+r)d.x&&(g=d.x-f),o){o.attr("points",[{x:y-3,y:p.y-4+a},{x:y+3,y:p.y-4+a},{x:y,y:p.y+a}]);var m=e.backShape,x=i.parsePadding(m.attr("radius"));y===p.x?(x[3]=0,o.attr("points",[{x:p.x,y:p.y+a},{x:p.x,y:p.y-4+a},{x:p.x+4,y:p.y-4+a}])):y===d.x&&(x[2]=0,o.attr("points",[{x:d.x,y:p.y+a},{x:d.x-4,y:p.y-4+a},{x:d.x,y:p.y-4+a}])),m.attr("radius",x)}}e.moveTo(g-c,v-l)}},e.setMarkers=function(t){void 0===t&&(t={});var e=this,n=t,a=n.items,s=n.style,o=n.type,u=e._getMarkerGroup(o);if("circle"===o)for(var c=0,l=a.length;c=r.x+u&&t<=r.x+r.width+u&&e>=r.y+c&&e<=r.height+r.y+c)return i={clickedItem:o[a],clickedLegend:n},!1})}})}),i}(a.x,a.y);if(s&&!1!==s.clickedLegend.clickable){var o=s.clickedItem,u=s.clickedLegend;if(u.onClick)t.clickedItem=o,u.onClick(t);else if(!u.custom){var c=o.get("checked"),l=o.get("dataValue"),f=u.filteredVals,h=u.field;"single"===u.selectedMode?i.filter(h,function(t){return t===l}):(c?f.push(l):r.Array.remove(f,l),i.filter(h,function(t){return-1===f.indexOf(t)})),i.repaint()}}},this.legendCfg={},this.enable=!0,this.position="top",r.mix(this,t);var n=this.chart;this.canvasDom=n.get("canvas").get("el"),this.clear()}var e=t.prototype;return e.addLegend=function(t,e,n){var i=this,r=i.legendCfg,a=t.field,s=r[a];if(!1===s)return null;if(s&&s.custom)i.addCustomLegend(a);else{var o=r.position||i.position;s&&s.position&&(o=s.position),t.isCategory&&i._addCategoryLegend(t,e,o,n)}},e.addCustomLegend=function(t){var e=this,n=e.legendCfg;t&&n[t]&&(n=n[t]);var i=n.position||e.position,o=e.legends;o[i]=o[i]||[];var u=n.items;if(!u)return null;var c=e.container;r.each(u,function(t){r.isPlainObject(t.marker)?t.marker.radius=t.marker.radius||3:t.marker={symbol:t.marker||"circle",fill:t.fill,radius:3},t.checked=!!r.isNil(t.checked)||t.checked,t.name=t.name||t.value});var l=new a(r.deepMix({},s.legend[i],n,{maxLength:e._getMaxLength(i),items:u,parent:c}));o[i].push(l)},e.clear=function(){var t=this.legends;r.each(t,function(t){r.each(t,function(t){t.clear()})}),this.legends={},this.unBindEvents()},e._isFiltered=function(t,e,n){var i=!1;return r.each(e,function(e){if(i=i||t.getText(e)===t.getText(n))return!1}),i},e._getMaxLength=function(t){var e=this.chart,n=r.parsePadding(e.get("appendPadding"));return"right"===t||"left"===t?e.get("height")-(n[0]+n[2]):e.get("width")-(n[1]+n[3])},e._addCategoryLegend=function(t,e,n,i){var o=this,u=o.legendCfg,c=o.legends,l=o.container,f=o.chart,h=t.field;c[n]=c[n]||[];var p="circle";u[h]&&u[h].marker?p=u[h].marker:u.marker&&(p=u.marker),r.each(e,function(e){r.isPlainObject(p)?r.mix(e.marker,p):e.marker.symbol=p,i&&(e.checked=!o._isFiltered(t,i,e.dataValue))}),f.get("legendItems")[h]=e;var d=r.deepMix({},s.legend[n],u[h]||u,{maxLength:o._getMaxLength(n),items:e,field:h,filteredVals:i,parent:l});d.showTitle&&r.deepMix(d,{title:t.alias||t.field});var g=new a(d);return c[n].push(g),g},e._alignLegend=function(t,e,n){var i=this,a=i.plotRange,s=a.tl,o=a.bl,u=i.chart,c=t.offsetX||0,l=t.offsetY||0,f=u.get("width"),h=u.get("height"),p=r.parsePadding(u.get("appendPadding")),d=t.getHeight(),g=t.getWidth(),v=0,y=0;if("left"===n||"right"===n){var m=t.verticalAlign||"middle",x=Math.abs(s.y-o.y);v="left"===n?p[3]:f-g-p[1],y=(x-d)/2+s.y,"top"===m?y=s.y:"bottom"===m&&(y=o.y-d),e&&(y=e.get("y")-d-12)}else{var _=t.align||"left";if(v=p[3],"center"===_?v=f/2-g/2:"right"===_&&(v=f-(g+p[1])),y="top"===n?p[0]+Math.abs(t.container.getBBox().minY):h-d,e){var S=e.getWidth();v=e.x+S+12}}"bottom"===n&&l>0&&(l=0),"right"===n&&c>0&&(c=0),t.moveTo(v+c,y+l)},e.alignLegends=function(){var t=this,e=t.legends;return r.each(e,function(e,n){r.each(e,function(i,r){var a=e[r-1];t._alignLegend(i,a,n)})}),t},e.bindEvents=function(){var t=this.legendCfg.triggerOn||"touchstart";r.addEventListener(this.canvasDom,t,this.handleEvent)},e.unBindEvents=function(){var t=this.legendCfg.triggerOn||"touchstart";r.removeEventListener(this.canvasDom,t,this.handleEvent)},t}();t.exports={init:function(t){var e=new u({container:t.get("backPlot"),plotRange:t.get("plotRange"),chart:t});t.set("legendController",e),t.legend=function(t,n){var i=e.legendCfg;return e.enable=!0,r.isBoolean(t)?(e.enable=t,i=n||{}):r.isObject(t)?i=t:i[t]=n,e.legendCfg=i,this}},beforeGeomDraw:function(t){var e=t.get("legendController");if(!e.enable)return null;var n=e.legendCfg;if(n&&n.custom)e.addCustomLegend();else{var a=t.getLegendItems(),s=t.get("scales"),o=t.get("filters");r.each(a,function(t,n){var i,r=s[n],a=r.values;i=o&&o[n]?a.filter(function(t){return!o[n](t)}):[],e.addLegend(r,t,i)})}n&&!1!==n.clickable&&e.bindEvents();var u=e.legends,c={top:0,right:0,bottom:0,left:0};r.each(u,function(e,n){var a=0;r.each(e,function(t){var e=t.getWidth(),i=t.getHeight();"top"===n||"bottom"===n?(a=Math.max(a,i),t.offsetY>0&&(a+=t.offsetY)):(a=Math.max(a,e),t.offsetX>0&&(a+=t.offsetX))}),c[n]=a+i(n,t.get("appendPadding"))}),t.set("legendRange",c)},afterGeomDraw:function(t){t.get("legendController").alignLegends()},clearInner:function(t){t.get("legendController").clear(),t.set("legendRange",null)}}},function(t,e,n){"use strict";function i(t,e){var n={};for(var i in e)h.isNumber(t[i])&&t[i]!==e[i]?n[i]=e[i]:h.isArray(t[i])&&JSON.stringify(t[i])!==JSON.stringify(e[i])&&(n[i]=e[i]);return n}function r(t,e,n){var i,r=t.get("type"),a="geom"+n+"-"+r,s=t.getXScale(),o=t.getYScale(),u=s.field||"x",c=o.field||"y",l=e[c];i=s.isIdentity?s.value:e[u],a+="interval"===r||"schema"===r?"-"+i:"line"===r||"area"===r||"path"===r?"-"+r:s.isCategory?"-"+i:"-"+i+"-"+l;var f=t._getGroupScales();return h.each(f,function(t){var n=t.field;"identity"!==t.type&&(a+="-"+e[n])}),a}function a(t,e,n){var i=[];return h.each(t,function(t,a){var s=t.get("container").get("children"),o=t.get("type"),u=h.isNil(t.get("animateCfg"))?l(o,e):t.get("animateCfg");!1!==u&&h.each(s,function(e,s){e.get("className")===o&&(e._id=r(t,e.get("origin")._origin,a),e.set("coord",n),e.set("animateCfg",u),e.set("index",s),i.push(e))}),t.set("shapes",s)}),i}function s(t){for(var e={},n=0,i=t.length;n-1&&(t="guide-tag"),h.isObject(n)?n[t]:!1!==n&&null}var f,h=n(0),p=n(46),d=n(236),g=n(237),v=n(206),y=n(239),m=n(240),x=n(30);p.prototype.animate=function(){var t=h.mix({},this.get("attrs"));return new g(this,t,f)},x.prototype.animate=function(t){return this.set("animate",t),this},v.Action=y,v.defaultCfg={interval:{enter:function(t){return t.isPolar&&t.transposed?function(t){t.set("zIndex",-1),t.get("parent").sort()}:y.fadeIn}},area:{enter:function(t){return t.isPolar?null:y.fadeIn}},line:{enter:function(t){return t.isPolar?null:y.fadeIn}},path:{enter:function(t){return t.isPolar?null:y.fadeIn}}};var _={line:function(t){return t.isPolar?m.groupScaleInXY:m.groupWaveIn},area:function(t){return t.isPolar?m.groupScaleInXY:m.groupWaveIn},path:function(t){return t.isPolar?m.groupScaleInXY:m.groupWaveIn},point:function(){return m.shapesScaleInXY},interval:function(t){var e;return t.isPolar?(e=m.groupScaleInXY,t.transposed&&(e=m.groupWaveIn)):e=t.transposed?m.groupScaleInX:m.groupScaleInY,e},schema:function(){return m.groupWaveIn}};t.exports={afterCanvasInit:function(){(f=new d).play()},beforeCanvasDraw:function(t){if(!1!==t.get("animate")){var e=t.get("isUpdate"),n=t.get("canvas"),i=t.get("coord"),r=t.get("geoms"),f=n.get("caches")||[];0===f.length&&(e=!1);var p=a(r,t,i),d=t.get("axisController"),g=d.frontPlot,y=d.backPlot,x=g.get("children").concat(y.get("children")),S=[];t.get("guideController")&&(S=t.get("guideController").guideShapes);var b=[];if(x.concat(S).forEach(function(e){var n=l(e.get("className"),t);e.set("coord",i),e.set("animateCfg",n),b.push(e),p.push(e)}),n.set("caches",s(p)),e)c(f,p,n);else{var P,C;h.each(r,function(e){var n=e.get("type"),r=h.isNil(e.get("animateCfg"))?l(n,t):e.get("animateCfg");if(!1!==r)if(P=u(n,"appear",r),C=o(n,i,"appear",P.animation),h.isFunction(C)){var a=e.get("shapes");h.each(a,function(t){C(t,P,i)})}else if(_[n]){C=m[P.animation]||_[n](i);var s=e.getYScale(),c=i.convertPoint({x:0,y:s.scale(e.getYMinValue())}),f=e.get("container");C&&C(f,P,i,c)}}),h.each(b,function(t){var e=t.get("animateCfg"),n=t.get("className");if(e&&e.appear){var r=v.getAnimateCfg(n,"appear"),a=h.deepMix({},r,e.appear),s=o(n,i,"appear",a.animation);h.isFunction(s)&&s(t,a,i)}})}}},afterCanvasDestroyed:function(){f.stop()}}},function(t,e,n){"use strict";var i=n(70).requestAnimationFrame,r="object"==typeof performance&&performance.now?performance:Date,a=function(){function t(){this.anims=[],this.time=null,this.playing=!1,this.canvas=[]}var e=t.prototype;return e.play=function(){function t(){e.playing&&(i(t),e.update())}var e=this;e.time=r.now(),e.playing=!0,i(t)},e.stop=function(){this.playing=!1,this.time=null,this.canvas=[]},e.update=function(){var t=r.now();this.canvas=[];for(var e=0;e=n.startTime&&!n.hasStarted&&(n.hasStarted=!0,n.onStart&&n.onStart());var c=(t-n.startTime)/u;if(c=Math.max(0,Math.min(c,1)),c=n.easing(c),n.onFrame)n.onFrame(c);else for(var l in o){var f=(0,o[l])(c),h=void 0;if("points"===l){h=[];for(var p=Math.max(a.points.length,s.points.length),d=0;d=n.endTime&&!n.hasEnded&&(n.hasEnded=!0,n.onEnd&&n.onEnd()),1===c&&(this.anims.splice(e,1),e--)}}}this.canvas.map(function(t){return t.draw(),t}),this.time=r.now()},t}();t.exports=a},function(t,e,n){"use strict";function i(t){for(var e=[],n=0,i=t.length;nl.x?i.x:l.x,u=l.y+p/2):"xy"===r&&(n.isPolar?(s=n.center.x,u=n.center.y):(s=(l.x+f.x)/2,u=(l.y+f.y)/2));var g=a.getScaledMatrix(d,[s,u],r);d.isClip=!0,d.endState={matrix:g},d.set("canvas",t.get("canvas")),t.attr("clip",d);a.doAnimation(d,d.endState,e,function(){t.attr("clip",null),d.remove(!0)})}function r(t,e,n){for(var i,r,s,o=t.get("children"),u=0,c=o.length;uo.max)&&(e=!1)}}),e&&u.push(t)}),t.set("filteredData",u)}}},function(t,e,n){"use strict";var i=n(208),r=n(0);t.exports={updateLinearScale:function(t,e,n){var r=this.chart;i.getScale(r,t).change({min:e,max:n,nice:!1})},updateCatScale:function(t,e,n,a,s,o){var u=this.chart;i.getScale(u,t).change({values:e,ticks:n,scale:function(t){"timeCat"===this.type&&(t=this._toTimeStamp(t));var e,n,i,r=this.rangeMin(),u=this.rangeMax(),c=u-r,l=a.indexOf(t);if(l>=0&&l0?-.1:r-.1)-c,i=l/s;else if(l>=0&&l>o)n=(e=u<1?1.1:u+.1)+c,i=(l-o-1)/(a.length-1-o);else{var f=this.translate(t);i=1===this.values.length?f:f/(this.values.length-1),e=r,n=u}return e+i*(n-e)},getTicks:function(){var t=this,e=this.ticks,n=[];return r.each(e,function(e){var i;if(r.isObject(e))i=e;else{var a=t.scale(e);a=a>=0&&a<=1?a:NaN,i={text:r.isString(e)?e:t.getText(e),value:a,tickValue:e}}n.push(i)}),n}})}}},,function(t,e,n){"use strict";var i=n(0),r=n(208),a=["touchstart","touchmove","touchend","touchStart","touchMove","touchEnd"];t.exports={_handleMove:function(t){if("swipe"===t.type&&t.deltaTime>350)return null;var e,n,i=this.currentDeltaX,r=this.currentDeltaY,s=this.lastPoint;if(-1!==a.indexOf(t.type)){var o=t.touches[0];e=o.x-s.x,n=o.y-s.y,this.lastPoint=o}else null!==i&&null!==r&&(e=t.deltaX-i,n=t.deltaY-r,this.currentDeltaX=t.deltaX,this.currentDeltaY=t.deltaY);if(Math.abs(e)>0||Math.abs(n)>0){var u=this._timestamp,c=+new Date;c-u>16&&(this._doMove(e,n),this._timestamp=c)}},_doMove:function(t,e){var n=this,a=n.mode,s=n.chart,o=n.limitRange,u=s.get("coord"),c=u.start,l=u.end,f=s.get("data");if(i.directionEnabled(a,"x")&&0!==t){var h=s.getXScale(),p=h.field;o[p]||(o[p]=r.getLimitRange(f,h));var d=l.x-c.x;h.isCategory?n._handleCatScale(h,t,d):h.isLinear&&n._handleLinearScale(h,t,d,"x"),n.xRange=r.getFieldRange(h,o[p],h.type)}if(i.directionEnabled(a,"y")&&0!==e){var g=c.y-l.y,v=s.getYScales();i.each(v,function(t){var i=t.field;o[i]||(o[i]=r.getLimitRange(f,t)),t.isLinear&&n._handleLinearScale(t,e,g,"y")});var y=v[0];n.yRange=r.getFieldRange(y,o[y.field],y.type)}s.repaint()},_handleLinearScale:function(t,e,n,r){var a=t.field,s=t.min,o=t.max,u=this.limitRange;if(s!==u[a].min||o!==u[a].max){var c=e/n*(o-s),l="x"===r?o-c:o+c,f="x"===r?s-c:s+c;u[a]&&!i.isNil(u[a].min)&&f<=u[a].min&&(l=o-s+(f=u[a].min)),u[a]&&!i.isNil(u[a].max)&&l>=u[a].max&&(f=(l=u[a].max)-(o-s)),this.updateLinearScale(a,f,l)}},_handleCatScale:function(t,e,n){var r=t.type,a=t.field,s=t.values,o=t.ticks,u=i.uniq(s),c=this.limitRange[a],l=c.length-1,f=u.length,h=n/(f*(this.speed||1)),p=c.indexOf(u[0]),d=c.indexOf(u[f-1]),g=p,v=d,y=Math.abs(e/n),m=this.step||Math.max(1,parseInt(y*f));if(this._panCumulativeDelta+=e,g=this._panCumulativeDelta>h?Math.max(0,g-m):this._panCumulativeDelta<-h?Math.min(l-f+1,g+m):g,v=Math.min(l,g+f-1),g===p&&v===d)return null;var x=c.slice(g,v+1),_=null;if("timeCat"===r){var S=o.length>2?o[1]-o[0]:864e5;if(this._panCumulativeDelta>h)for(var b=o[0]-S;b>=x[0];b-=S)o.unshift(b);else if(this._panCumulativeDelta<-h)for(var P=o[o.length-1]+S;P<=x[x.length-1];P+=S)o.push(P);_=o}else _=o;this.updateCatScale(a,x,_,c,g,v),this._panCumulativeDelta=g!==p?0:this._panCumulativeDelta}}},,,,,,,function(t,e,n){"use strict";var i=n(77);n(209),n(193),n(203),n(218),n(219),n(253);var r=n(230),a=n(233),s=n(234),o=n(235),u=n(255),c=n(256),l=n(257);i.Animate=n(206),i.Chart.plugins.register([r,s,a,o,u,c,l]),n(258),i.Interaction=n(74),t.exports=i},function(t,e,n){"use strict";t.exports={Text:n(227),Line:n(225),Arc:n(223),Rect:n(226),Html:n(224),Tag:n(228),Point:n(229),RegionFilter:n(254)}},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,o.default)(t);if(r()){var i=(0,o.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,s.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(2)),o=a(n(3)),u=a(n(4)),c=n(0),l=n(23),f=n(10).Rect,h=function(t){function e(){return t.apply(this,arguments)||this}(0,u.default)(e,t);i(e);var n=e.prototype;return n._initDefaultCfg=function(){this.type="regionFilter",this.start=[],this.end=[],this.color=null,this.style=null},n.render=function(t){var e=this.parsePoint(t,this.start),n=this.parsePoint(t,this.end);if(e&&n){var i=new f({attrs:{x:Math.min(e.x,n.x),y:Math.min(e.y,n.y),width:Math.abs(n.x-e.x),height:Math.abs(n.y-e.y)}});this.clip=i;var r=this.chart,a=this.color,s=this.style||{},o=[];r.get("geoms").map(function(t){var e=t.get("container"),n=e.get("children"),r=e.addGroup({zIndex:10,className:"guide-region-filter"});return n.map(function(t){if(t.get("isShape")){var e=t.get("type"),n=c.mix({},t.get("attrs"),s);a&&(n.fill||n.fillStyle)&&(n.fill=n.fillStyle=a),a&&(n.stroke||n.strokeStyle)&&(n.stroke=n.strokeStyle=a);var i={attrs:n};"custom"!==e&&"Custom"!==e||(i.createPath=t.get("createPath"),i.calculateBox=t.get("calculateBox")),r.addShape(e,i)}return t}),r.attr("clip",i),e.sort(),o.push(r),t}),this.element=o}},n.remove=function(){var t=this.element;c.each(t,function(t){t&&t.remove(!0)}),this.clip&&this.clip.remove(!0)},e}(l);l.RegionFilter=h,t.exports=h},function(t,e,n){"use strict";var i=n(208),r=n(0),a={mode:"x",xStyle:{backgroundColor:"rgba(202, 215, 239, .2)",fillerColor:"rgba(202, 215, 239, .5)",size:4,lineCap:"round",offsetX:0,offsetY:8},yStyle:{backgroundColor:"rgba(202, 215, 239, .2)",fillerColor:"rgba(202, 215, 239, .5)",size:4,lineCap:"round",offsetX:8,offsetY:0}};t.exports={init:function(t){t.set("_limitRange",{}),t.scrollBar=function(t){!0===t?t=a:r.isObject(t)&&(t=r.deepMix({},a,t)),this.set("_scrollBarCfg",t)}},clear:function(t){t.set("_limitRange",{})},changeData:function(t){t.set("_limitRange",{})},clearInner:function(t){var e=t.get("_horizontalBar"),n=t.get("_verticalBar");e&&e.remove(!0),n&&n.remove(!0),t.set("_horizontalBar",null),t.set("_verticalBar",null)},afterGeomDraw:function(t){var e=t.get("_scrollBarCfg");if(e){var n=t.get("data"),a=t.get("plotRange"),s=t.get("backPlot"),o=t.get("canvas").get("height"),u=t.get("_limitRange"),c=e.mode;if(r.directionEnabled(c,"x")){var l=e.xStyle,f=l.offsetX,h=l.offsetY,p=l.lineCap,d=l.backgroundColor,g=l.fillerColor,v=l.size,y=t.getXScale(),m=u[y.field];m||(m=i.getLimitRange(n,y),u[y.field]=m);var x=i.getFieldRange(y,m,y.type),_=t.get("_horizontalBar"),S=o-v/2+h;_?_.get("children")[1].attr({x1:Math.max(a.bl.x+a.width*x[0]+f,a.bl.x),x2:Math.min(a.bl.x+a.width*x[1]+f,a.br.x)}):((_=s.addGroup({className:"horizontalBar"})).addShape("line",{attrs:{x1:a.bl.x+f,y1:S,x2:a.br.x+f,y2:S,lineWidth:v,stroke:d,lineCap:p}}),_.addShape("line",{attrs:{x1:Math.max(a.bl.x+a.width*x[0]+f,a.bl.x),y1:S,x2:Math.min(a.bl.x+a.width*x[1]+f,a.br.x),y2:S,lineWidth:v,stroke:g,lineCap:p}}),t.set("_horizontalBar",_))}if(r.directionEnabled(c,"y")){var b=e.yStyle,P=b.offsetX,C=b.offsetY,M=b.lineCap,T=b.backgroundColor,w=b.fillerColor,D=b.size,A=t.getYScales()[0],R=u[A.field];R||(R=i.getLimitRange(n,A),u[A.field]=R);var E=i.getFieldRange(A,R,A.type),O=t.get("_verticalBar"),k=D/2+P;O?O.get("children")[1].attr({y1:Math.max(a.tl.y+a.height*E[0]+C,a.tl.y),y2:Math.min(a.tl.y+a.height*E[1]+C,a.bl.y)}):((O=s.addGroup({className:"verticalBar"})).addShape("line",{attrs:{x1:k,y1:a.tl.y+C,x2:k,y2:a.bl.y+C,lineWidth:D,stroke:T,lineCap:M}}),O.addShape("line",{attrs:{x1:k,y1:Math.max(a.tl.y+a.height*E[0]+C,a.tl.y),x2:k,y2:Math.min(a.tl.y+a.height*E[1]+C,a.bl.y),lineWidth:D,stroke:w,lineCap:M}}),t.set("_verticalBar",O))}}}}},function(t,e,n){"use strict";function i(t,e,n){return{x:t.x+n*Math.cos(e),y:t.y+n*Math.sin(e)}}function r(t,e){return e=v.minX&&f<=v.maxX&&h>=v.minY&&h<=v.maxY){n=g;break}}var y=r.getSnapRecords({x:f,y:h});n?l.data=n.get("data"):y.length&&(l.data=y[0]._origin),u&&u(l),l.data&&c&&e._activeShape(l.data)},s.mix(this,t);var n=this.chart;this.canvasDom=n.get("canvas").get("el")}var e=t.prototype;return e.renderLabels=function(){var t=this,e=t.chart,n=t.pieLabelCfg,u=t.labelGroup,c=[[],[]],l=e.get("geoms")[0].get("container").get("children"),f=n.anchorOffset,h=n.inflectionOffset,p=n.label1,d=n.label2,g=n.lineHeight,v=n.skipOverlapLabels,y=n.label1OffsetY,m=n.label2OffsetY,x=e.get("coord"),_=x.center,S=x.circleRadius;l.forEach(function(t){var n=t._attrs.attrs,a=r(n.startAngle,n.endAngle),u=i(_,a,S+f),l=i(_,a,S+h),g=t.get("origin"),v=g._origin,x=g.color,b={_anchor:u,_inflection:l,_data:v,x:l.x,y:l.y,r:S+h,fill:x},P=new o({context:e.get("canvas").get("context"),data:v}),C={x:0,y:0,fontSize:12,lineHeight:12,fill:"#808080"};s.isFunction(p)&&P.addShape("Text",{attrs:s.mix({textBaseline:"bottom"},C,p(v,x)),data:v,offsetY:y}),s.isFunction(d)&&P.addShape("Text",{attrs:s.mix({textBaseline:"top"},C,d(v,x)),data:v,offsetY:m}),b.textGroup=P,u.x<_.x?(b._side="left",c[0].push(b)):(b._side="right",c[1].push(b))});var b=[];if(v)for(var P,C=c[1].concat(c[0]),M=0,T=C.length;MR&&e.splice(R,e.length-R),e.sort(function(t,e){return t.y-e.y});var n=t._antiCollision(e);b=b.concat(n)})}this.drawnLabels=b},e.bindEvents=function(){var t=this.pieLabelCfg.triggerOn||"touchstart";s.addEventListener(this.canvasDom,t,this._handleEvent)},e.unBindEvents=function(){var t=this.pieLabelCfg.triggerOn||"touchstart";s.removeEventListener(this.canvasDom,t,this._handleEvent)},e.clear=function(){this.labelGroup&&this.labelGroup.clear(),this.halo&&this.halo.remove(!0),this.lastSelectedData=null,this.drawnLabels=[],this.unBindEvents()},e._drawLabel=function(t){var e=this.pieLabelCfg,n=this.chart.get("width"),i=e.sidePadding,r=t.y,a=t.textGroup,s=a.get("children"),o={textAlign:"left"===t._side?"left":"right",x:"left"===t._side?i:n-i};return s.forEach(function(t){t.attr(o),t.attr("y",r+t.get("offsetY"))}),a},e._drawLabelLine=function(t,e){var n=this.chart,i=this.pieLabelCfg,r=this.labelGroup,a=n.get("width"),o=i.sidePadding,u=i.adjustOffset,c=i.lineStyle,l=i.anchorStyle,f=i.skipOverlapLabels,h=t._anchor,p=t._inflection,d=t.fill,g=t.y,v={x:"left"===t._side?o:a-o,y:g},y=[h,p,v];if(!f&&p.y!==g)if(p.ym.x)&&(y=[h,_,v])}else y=[h,{x:p.x,y:g},v];r.addShape("Polyline",{attrs:s.mix({points:y,lineWidth:1,stroke:d},c)}),r.addShape("Circle",{attrs:s.mix({x:h.x,y:h.y,r:2,fill:d},l)})},e._antiCollision=function(t){var e,n=this,i=n.chart,r=n.pieLabelCfg,a=i.get("coord"),s=i.get("height"),o=a.center,u=a.circleRadius,c=r.inflectionOffset,l=r.lineHeight,f=o.y-u-c-l,h=!0,p=s,d=0,g=Number.MIN_VALUE,v=0,y=t.map(function(t){var e=t.y;e>d&&(d=e),e=v&&(v=n),{size:l,targets:[e-f]}});d-f>p&&(p=d-f);for(;h;)for(!function(t){t.forEach(function(t){var e=(Math.min.apply(g,t.targets)+Math.max.apply(g,t.targets))/2;t.pos=Math.min(Math.max(g,e-t.size/2),p-t.size)})}(y),h=!1,e=y.length;e--;)if(e>0){var m=y[e-1],x=y[e];m.pos+m.size>x.pos&&(m.size+=x.size,m.targets=m.targets.concat(x.targets),m.pos+m.size>p&&(m.pos=p-m.size),y.splice(e,1),h=!0)}e=0,y.forEach(function(n){var i=f;n.targets.forEach(function(){t[e].y=n.pos+i+l/2,i+=l,e++})});var _=[];return t.forEach(function(t){var e=n._drawLabel(t);n.labelGroup.add(e),n._drawLabelLine(t,v),_.push(e)}),_},e._getSelectedShapeByData=function(t){var e=null,n=this.chart.get("geoms")[0],i=n.get("container").get("children");return s.each(i,function(i){if(i.get("isShape")&&i.get("className")===n.get("type")){var r=i.get("origin")._origin;if(s.isObjectValueEqual(r,t))return e=i,!1}}),e},e._activeShape=function(t){var e=this.chart,n=this.lastSelectedData,i=this.pieLabelCfg;if(t!==n){this.lastSelectedData=t;var r=i.activeStyle,a=this._getSelectedShapeByData(t)._attrs.attrs,o=a.x,u=a.y,c=a.startAngle,l=a.endAngle,f=a.r,h=a.fill,p=e.get("frontPlot");this.halo&&this.halo.remove(!0);var d=p.addShape("sector",{attrs:s.mix({x:o,y:u,r:f+r.offset+r.appendRadius,r0:f+r.offset,fill:h,startAngle:c,endAngle:l},r)});this.halo=d,e.get("canvas").draw()}},t}();t.exports={init:function(t){var e=t.get("frontPlot").addGroup({className:"pie-label",zIndex:0}),n=new c({chart:t,labelGroup:e});t.set("pieLabelController",n),t.pieLabel=function(t){return t=s.deepMix({},u,t),n.pieLabelCfg=t,this}},afterGeomDraw:function(t){var e=t.get("pieLabelController");e.pieLabelCfg&&(e.renderLabels(),e.bindEvents())},clearInner:function(t){var e=t.get("pieLabelController");e.pieLabelCfg&&e.clear()}}},function(t,e,n){"use strict";function i(t,e){return{x:(t.x-e.x)/2+e.x,y:(t.y-e.y)/2+e.y}}var r=n(0),a={label:null,offsetX:0,offsetY:0},s={textBaseline:"middle",fill:"#808080"},o=function(){function t(t){var e=t.chart,n=t.container;this.cfg=null,this.chart=e,this.container=n}var e=t.prototype;return e.draw=function(){var t=this.chart,e=this.container,n=this.cfg;if(n){var o=r.mix({},a,n),u=t.get("coord");t.get("geoms")[0].get("container").get("children").forEach(function(t){var n=t.get("origin"),a=n._origin,c=n.color,l=n.points;if(o.label){var f=o.label(a,c),h=e.addGroup(),p=u.convertPoint(i(l[1],l[2]));h.addShape("Text",{attrs:r.mix({x:p.x+o.offsetX,y:p.y+o.offsetY},f,s)})}})}},e.clear=function(){this.container.clear()},t}();t.exports={init:function(t){var e=t.get("frontPlot").addGroup({className:"label",zIndex:0}),n=new o({chart:t,container:e});t.set("intervalLabelController",n),t.intervalLabel=function(t){n.cfg=t}},afterGeomDraw:function(t){t.get("intervalLabelController").draw()},clearInner:function(t){t.get("intervalLabelController").clear()}}},function(t,e,n){"use strict";t.exports={Interaction:n(74),PieSelect:n(260),IntervalSelect:n(261),Swipe:n(262),Pan:n(263),Pinch:n(264)}},function(t,e,n){var i;!function(r,a,s,o){"use strict";function u(t,e,n){return setTimeout(p(t,n),e)}function c(t,e,n){return!!Array.isArray(t)&&(l(t,n[e],n),!0)}function l(t,e,n){var i;if(t)if(t.forEach)t.forEach(e,n);else if(t.length!==o)for(i=0;i\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",a=r.console&&(r.console.warn||r.console.log);return a&&a.call(r.console,i,n),t.apply(this,arguments)}}function h(t,e,n){var i,r=e.prototype;(i=t.prototype=Object.create(r)).constructor=t,i._super=r,n&&dt(i,n)}function p(t,e){return function(){return t.apply(e,arguments)}}function d(t,e){return typeof t==yt?t.apply(e?e[0]||o:o,e):t}function g(t,e){return t===o?e:t}function v(t,e,n){l(_(e),function(e){t.addEventListener(e,n,!1)})}function y(t,e,n){l(_(e),function(e){t.removeEventListener(e,n,!1)})}function m(t,e){for(;t;){if(t==e)return!0;t=t.parentNode}return!1}function x(t,e){return t.indexOf(e)>-1}function _(t){return t.trim().split(/\s+/g)}function S(t,e,n){if(t.indexOf&&!n)return t.indexOf(e);for(var i=0;in[e]}):i.sort()),i}function C(t,e){for(var n,i,r=e[0].toUpperCase()+e.slice(1),a=0;a1&&!n.firstMultiple?n.firstMultiple=k(e):1===r&&(n.firstMultiple=!1);var a=n.firstInput,s=n.firstMultiple,o=s?s.center:a.center,u=e.center=I(i);e.timeStamp=_t(),e.deltaTime=e.timeStamp-a.timeStamp,e.angle=Y(o,u),e.distance=F(o,u),E(n,e),e.offsetDirection=j(e.deltaX,e.deltaY);var c=N(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=c.x,e.overallVelocityY=c.y,e.overallVelocity=xt(c.x)>xt(c.y)?c.x:c.y,e.scale=s?L(s.pointers,i):1,e.rotation=s?B(s.pointers,i):0,e.maxPointers=n.prevInput?e.pointers.length>n.prevInput.maxPointers?e.pointers.length:n.prevInput.maxPointers:e.pointers.length,O(n,e);var l=t.element;m(e.srcEvent.target,l)&&(l=e.srcEvent.target),e.target=l}function E(t,e){var n=e.center,i=t.offsetDelta||{},r=t.prevDelta||{},a=t.prevInput||{};e.eventType!==At&&a.eventType!==Et||(r=t.prevDelta={x:a.deltaX||0,y:a.deltaY||0},i=t.offsetDelta={x:n.x,y:n.y}),e.deltaX=r.x+(n.x-i.x),e.deltaY=r.y+(n.y-i.y)}function O(t,e){var n,i,r,a,s=t.lastInterval||e,u=e.timeStamp-s.timeStamp;if(e.eventType!=Ot&&(u>Dt||s.velocity===o)){var c=e.deltaX-s.deltaX,l=e.deltaY-s.deltaY,f=N(u,c,l);i=f.x,r=f.y,n=xt(f.x)>xt(f.y)?f.x:f.y,a=j(c,l),t.lastInterval=e}else n=s.velocity,i=s.velocityX,r=s.velocityY,a=s.direction;e.velocity=n,e.velocityX=i,e.velocityY=r,e.direction=a}function k(t){for(var e=[],n=0;n=xt(e)?t<0?It:Nt:e<0?jt:Ft}function F(t,e,n){n||(n=Xt);var i=e[n[0]]-t[n[0]],r=e[n[1]]-t[n[1]];return Math.sqrt(i*i+r*r)}function Y(t,e,n){n||(n=Xt);var i=e[n[0]]-t[n[0]],r=e[n[1]]-t[n[1]];return 180*Math.atan2(r,i)/Math.PI}function B(t,e){return Y(e[1],e[0],zt)+Y(t[1],t[0],zt)}function L(t,e){return F(e[0],e[1],zt)/F(t[0],t[1],zt)}function X(){this.evEl=Wt,this.evWin=Ht,this.pressed=!1,w.apply(this,arguments)}function z(){this.evEl=Ut,this.evWin=Zt,w.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function G(){this.evTarget=$t,this.evWin=Kt,this.started=!1,w.apply(this,arguments)}function W(t,e){var n=b(t.touches),i=b(t.changedTouches);return e&(Et|Ot)&&(n=P(n.concat(i),"identifier",!0)),[n,i]}function H(){this.evTarget=te,this.targetIds={},w.apply(this,arguments)}function V(t,e){var n=b(t.touches),i=this.targetIds;if(e&(At|Rt)&&1===n.length)return i[n[0].identifier]=!0,[n,n];var r,a,s=b(t.changedTouches),o=[],u=this.target;if(a=n.filter(function(t){return m(t.target,u)}),e===At)for(r=0;r-1&&i.splice(t,1)},ee)}}function J(t){for(var e=t.srcEvent.clientX,n=t.srcEvent.clientY,i=0;i-1&&this.requireFail.splice(e,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(t){return!!this.simultaneous[t.id]},emit:function(t){function e(e){n.manager.emit(e,t)}var n=this,i=this.state;i=de&&e(n.options.event+tt(i))},tryEmit:function(t){if(this.canEmit())return this.emit(t);this.state=32},canEmit:function(){for(var t=0;te.threshold&&r&e.direction},attrTest:function(t){return it.prototype.attrTest.call(this,t)&&(this.state&he||!(this.state&he)&&this.directionTest(t))},emit:function(t){this.pX=t.deltaX,this.pY=t.deltaY;var e=et(t.direction);e&&(t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),h(at,it,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[oe]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||this.state&he)},emit:function(t){if(1!==t.scale){var e=t.scale<1?"in":"out";t.additionalEvent=this.options.event+e}this._super.emit.call(this,t)}}),h(st,Q,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[ae]},process:function(t){var e=this.options,n=t.pointers.length===e.pointers,i=t.distancee.time;if(this._input=t,!i||!n||t.eventType&(Et|Ot)&&!r)this.reset();else if(t.eventType&At)this.reset(),this._timer=u(function(){this.state=ge,this.tryEmit()},e.time,this);else if(t.eventType&Et)return ge;return 32},reset:function(){clearTimeout(this._timer)},emit:function(t){this.state===ge&&(t&&t.eventType&Et?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=_t(),this.manager.emit(this.options.event,this._input)))}}),h(ot,it,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[oe]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||this.state&he)}}),h(ut,it,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Yt|Bt,pointers:1},getTouchAction:function(){return rt.prototype.getTouchAction.call(this)},attrTest:function(t){var e,n=this.options.direction;return n&(Yt|Bt)?e=t.overallVelocity:n&Yt?e=t.overallVelocityX:n&Bt&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&n&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&&xt(e)>this.options.velocity&&t.eventType&Et},emit:function(t){var e=et(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)}}),h(ct,Q,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[se]},process:function(t){var e=this.options,n=t.pointers.length===e.pointers,i=t.distance=e.x&&r<=e.x+e.width&&a>=e.y&&a<=e.height+e.y?n=t:u.push(t)})}else if("range"===s){var h=e.getSnapRecords({x:r,y:a});if(!h.length)return void this.reset();var p=h[0]._origin,d=this._selectShapesByData(p);n=d.selectedShape,u=d.unSelectedShapes}if(n)if(this.selectedShape=n,n.get("_selected")){if(!this.cancelable)return void this._setEventData(t);this.reset()}else this._selectShapes(n,u);else this.reset();this._setEventData(t)},n.end=function(t){this._setEventData(t)},e}(f);h.registerInteraction("interval-select",p),t.exports=p},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,u.default)(t);if(r()){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,o.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(22)),o=a(n(2)),u=a(n(3)),c=a(n(4)),l=n(0),f=n(74),h=n(30),p=n(242),d=n(245),g=n(243),v=function(t){function e(e,n){var i;i=t.call(this,e,n)||this;var r=(0,s.default)(i),a=r.hammer,o=r.threshold,u=r.velocity;return a&&a.get("swipe").set({direction:6,threshold:o,velocity:u}),n.registerPlugins([p,{changeData:function(){r.limitRange={}},clear:function(){r.limitRange={}}}]),r.mode="x",l.mix(r,g,d),i}(0,c.default)(e,t);i(e);var n=e.prototype;return n.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e=l.mix({},e,{startEvent:"touchstart",processEvent:"swipe",endEvent:"touchend",currentDeltaX:null,threshold:10,velocity:.3,limitRange:{},_timestamp:0,_panCumulativeDelta:0,speed:5})},n.process=function(t){this.currentDeltaX=0,this._handleMove(t)},n.end=function(){this.currentDeltaX=null,this._panCumulativeDelta=0},e}(f);h.registerInteraction("swipe",v),t.exports=v},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,u.default)(t);if(r()){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,o.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(22)),o=a(n(2)),u=a(n(3)),c=a(n(4)),l=n(0),f=n(74),h=n(30),p=n(242),d=n(245),g=n(243),v=function(t){function e(e,n){var i;i=t.call(this,e,n)||this;var r=(0,s.default)(i),a=r.hammer,o=r.panThreshold;return a&&(a.get("pan").set({threshold:o}),n.get("canvas").on("pan",function(){})),n.registerPlugins([p,{changeData:function(){r.limitRange={}},clear:function(){r.limitRange={}}}]),l.mix((0,s.default)(i),g,d),i}(0,c.default)(e,t);i(e);var n=e.prototype;return n.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e=l.mix({},e,{startEvent:"panstart",processEvent:"panmove",endEvent:"panend",resetEvent:"touchend",mode:"x",panThreshold:10,pressThreshold:9,pressTime:251,currentDeltaX:null,currentDeltaY:null,limitRange:{},_timestamp:0,lastPoint:null,_panCumulativeDelta:0,speed:5}),(l.isWx||l.isMy)&&(e.startEvent="touchstart",e.processEvent="touchmove",e.endEvent="touchend"),e},n.start=function(t){this.pressed||(this.currentDeltaX=0,this.currentDeltaY=0,"touchstart"!==t.type&&"touchStart"!==t.type||(this.lastPoint=t.touches[0]),this._handleMove(t))},n.process=function(t){this.pressed||this._handleMove(t)},n.end=function(){this.pressed||(this.currentDeltaX=null,this.currentDeltaY=null,this.lastPoint=null,this._panCumulativeDelta=0)},e}(f);h.registerInteraction("pan",v),t.exports=v},function(t,e,n){"use strict";function i(t){return function(){var e,n=(0,u.default)(t);if(r()){var i=(0,u.default)(this).constructor;e=Reflect.construct(n,arguments,i)}else e=n.apply(this,arguments);return(0,o.default)(this,e)}}function r(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(t){return!1}}var a=n(1),s=a(n(22)),o=a(n(2)),u=a(n(3)),c=a(n(4)),l=n(0),f=n(208),h=n(74),p=n(30),d=n(242),g=n(243),v=function(t){function e(e,n){var i;i=t.call(this,e,n)||this;var r=(0,s.default)(i);return r.hammer.get("pinch").set({enable:!0}),n.registerPlugins([d,{changeData:function(){r.limitRange={},r.originTicks=null},clear:function(){r.limitRange={},r.originTicks=null}}]),l.mix(r,g),i}(0,c.default)(e,t);i(e);var n=e.prototype;return n.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return l.mix({},e,{startEvent:"pinchstart",processEvent:"pinch",endEvent:"pinchend",resetEvent:"touchend",pressThreshold:9,pressTime:251,mode:"x",currentPinchScaling:null,originValues:null,minScale:null,maxScale:null,limitRange:{},sensitivity:1,_pinchCumulativeDelta:0,_timestamp:0})},n.start=function(){this.pressed||(this.currentPinchScaling=1)},n.process=function(t){this.pressed||this._handlePinch(t)},n.end=function(t){this.pressed||(this._handlePinch(t),this.currentPinchScaling=null,this.pinchCumulativeDelta=0)},n._handlePinch=function(t){var e,n=1/this.currentPinchScaling*t.scale,i=t.target.getBoundingClientRect(),r={x:t.center.x-i.left,y:t.center.y-i.top},a=Math.abs(t.pointers[0].clientX-t.pointers[1].clientX),s=Math.abs(t.pointers[0].clientY-t.pointers[1].clientY),o=a/s;e=o>.3&&o<1.7?"xy":a>s?"x":"y";var u=this._timestamp,c=+new Date;c-u>16&&(this._doZoom(n,r,e),this._timestamp=c),this.currentPinchScaling=t.scale},n._doZoom=function(t,e,n){var i,r=this,a=r.mode,s=r.chart,o=r.limitRange;i="xy"===a&&void 0!==n?n:"xy";var u=s.get("data");if(l.directionEnabled(a,"x")&&l.directionEnabled(i,"x")){var c=s.getXScale(),h=c.field;o[h]||(o[h]=f.getLimitRange(u,c)),c.isCategory?r._zoomCatScale(c,t,e):c.isLinear&&r._zoomLinearScale(c,t,e,"x"),this.xRange=f.getFieldRange(c,o[h],c.type)}if(l.directionEnabled(a,"y")&&l.directionEnabled(i,"y")){var p=s.getYScales();l.each(p,function(n){var i=n.field;o[i]||(o[i]=f.getLimitRange(u,n)),n.isLinear&&r._zoomLinearScale(n,t,e,"y")});var d=p[0];this.yRange=f.getFieldRange(d,o[d.field],d.type)}s.repaint()},n._zoomLinearScale=function(t,e,n,i){var r=this.chart,a=t.min,s=t.max,o=t.field,u=s-a,c=this.limitRange,l=c[o].max-c[o].min,f=r.get("coord"),h=u*(e-1);if(this.minScale&&e<1){var p=l/this.minScale;h=Math.max(u-p,h)}if(this.maxScale&&e>=1){var d=l/this.maxScale;h=Math.min(u-d,h)}var g=f.invertPoint(n),v="x"===i?g.x:g.y,y=s-h*(1-v),m=a+h*v;this.updateLinearScale(o,m,y)},n._zoomCatScale=function(t,e,n){var i=this._pinchCumulativeDelta,r=this.sensitivity;i=e>1?i+1:i-1,this._pinchCumulativeDelta=i;var a=t.field,s=t.values,o=this.chart.get("coord");this.originTicks||(this.originTicks=t.ticks);var u=this.limitRange[a],c=u.length,l=this.minScale||1,f=this.maxScale||5,h=parseInt(c/f),p=parseInt(c/l),d=s.length;if(i>0&&d<=h)return null;if(i<0&&d>=p)return null;var g=c-1,v=s[0],y=s[d-1],m=u.indexOf(v),x=u.indexOf(y),_=(o.start.x+o.end.x)/2,S=n.x;if(Math.abs(i)>r){var b=Math.max(1,parseInt(d*Math.abs(e-1)));i<0?(S>=_?m<=0?x=Math.min(g,x+b):m=Math.max(0,m-b):S<_&&(x>=g?m=Math.max(0,m-b):x=Math.min(g,x+b)),this._pinchCumulativeDelta=0):i>0&&(S>=_?m=mm?x=Math.max(m,x-b):x),this._pinchCumulativeDelta=0);var P=u.slice(m,x+1);this.updateCatScale(a,P,this.originTicks,u,m,x)}},e}(h);p.registerInteraction("pinch",v),t.exports=v}])});