=i.startTime&&!i.hasStarted&&(i.hasStarted=!0,i.onStart&&i.onStart());var l=(t-i.startTime)/c;if(l=Math.max(0,Math.min(l,1)),l=i.easing(l),i.onFrame)i.onFrame(l);else for(var u in s){var h=(0,s[u])(l),f=void 0;if("points"===u){f=[];for(var p=Math.max(a.points.length,o.points.length),g=0;g=i.endTime&&!i.hasEnded&&(i.hasEnded=!0,i.onEnd&&i.onEnd()),1===l&&(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,i){function n(t){for(var e=[],i=0,n=t.length;iu.x?n.x:u.x,c=u.y+p/2):"xy"===r&&(i.isPolar?(o=i.center.x,c=i.center.y):(o=(u.x+h.x)/2,c=(u.y+h.y)/2));var d=a.getScaledMatrix(g,[o,c],r);g.isClip=!0,g.endState={matrix:d},g.set("canvas",t.get("canvas")),t.attr("clip",g);a.doAnimation(g,g.endState,e,function(){t.attr("clip",null),g.remove(!0)})}function r(t,e,i){for(var n,r,o,s=t.get("children"),c=0,l=s.length;cs.max)&&(e=!1)}}),e&&c.push(t)}),t.set("filteredData",c)}}},function(t,e,i){var n=i(101),r=i(0);t.exports={updateLinearScale:function(t,e,i){var a=this.chart,o=n.getColDef(a,t);a.scale(t,r.mix({},o,{min:e,max:i,nice:!1}))},updateCatScale:function(t,e,i,a,o,s){var c=this.chart,l=n.getColDef(c,t);c.scale(t,r.mix({},l,{values:e,ticks:i,scale:function(t){"timeCat"===this.type&&(t=this._toTimeStamp(t));var e,i,n,r=this.rangeMin(),c=this.rangeMax(),l=c-r,u=a.indexOf(t);if(u>=0&&u0?-.1:r-.1)-l,n=u/o;else if(u>=0&&u>s)i=(e=c<1?1.1:c+.1)+l,n=(u-s-1)/(a.length-1-s);else{var h=this.translate(t);n=1===this.values.length?h:h/(this.values.length-1),e=r,i=c}return e+n*(i-e)},getTicks:function(){var t=this,e=this.ticks,i=[];return r.each(e,function(e){var n;if(r.isObject(e))n=e;else{var a=t.scale(e);a=a>=0&&a<=1?a:NaN,n={text:r.isString(e)?e:t.getText(e),value:a,tickValue:e}}i.push(n)}),i}}))}}},function(t,e,i){var n=i(0),r=i(101),a=["touchstart","touchmove","touchend","touchStart","touchMove","touchEnd"];t.exports={_handleMove:function(t){if("swipe"===t.type&&t.deltaTime>350)return null;var e,i,n=this.currentDeltaX,r=this.currentDeltaY,o=this.lastPoint;if(-1!==a.indexOf(t.type)){var s=t.touches[0];e=s.x-o.x,i=s.y-o.y,this.lastPoint=s}else null!==n&&null!==r&&(e=t.deltaX-n,i=t.deltaY-r,this.currentDeltaX=t.deltaX,this.currentDeltaY=t.deltaY);if(Math.abs(e)>0||Math.abs(i)>0){var c=this._timestamp,l=+new Date;l-c>16&&(this._doMove(e,i),this._timestamp=l)}},_doMove:function(t,e){var i=this,a=i.mode,o=i.chart,s=i.limitRange,c=o.get("coord"),l=c.start,u=c.end,h=o.get("data");if(n.directionEnabled(a,"x")&&0!==t){var f=o.getXScale(),p=f.field;s[p]||(s[p]=r.getLimitRange(h,f));var g=u.x-l.x;f.isCategory?i._handleCatScale(f,t,g):f.isLinear&&i._handleLinearScale(f,t,g,"x");var d=r.getColDef(o,p);i.xRange=r.getFieldRange(d,s[p],f.type)}if(n.directionEnabled(a,"y")&&0!==e){var v=l.y-u.y,y=o.getYScales();n.each(y,function(t){var n=t.field;s[n]||(s[n]=r.getLimitRange(h,t)),t.isLinear&&i._handleLinearScale(t,e,v,"y")});var m=r.getColDef(o,y[0].field);i.yRange=r.getFieldRange(m,s[y[0].field],y[0].type)}o.repaint()},_handleLinearScale:function(t,e,i,r){var a=t.field,o=t.min,s=t.max,c=this.limitRange;if(o!==c[a].min||s!==c[a].max){var l=e/i*(s-o),u="x"===r?s-l:s+l,h="x"===r?o-l:o+l;c[a]&&!n.isNil(c[a].min)&&h<=c[a].min&&(u=s-o+(h=c[a].min)),c[a]&&!n.isNil(c[a].max)&&u>=c[a].max&&(h=(u=c[a].max)-(s-o)),this.updateLinearScale(a,h,u)}},_handleCatScale:function(t,e,i){var n=t.type,r=t.field,a=t.values,o=t.ticks,s=this.limitRange[r],c=s.length-1,l=a.length,u=i/(l*(this.speed||1)),h=s.indexOf(a[0]),f=s.indexOf(a[l-1]),p=h,g=f,d=Math.abs(e/i),v=this.step||Math.max(1,parseInt(d*l));if(this._panCumulativeDelta+=e,p=this._panCumulativeDelta>u?Math.max(0,p-v):this._panCumulativeDelta<-u?Math.min(c-l+1,p+v):p,g=Math.min(c,p+l-1),p===h&&g===f)return null;var y=s.slice(p,g+1),m=null;if("timeCat"===n){var x=o.length>2?o[1]-o[0]:864e5;if(this._panCumulativeDelta>u)for(var _=o[0]-x;_>=y[0];_-=x)o.unshift(_);else if(this._panCumulativeDelta<-u)for(var S=o[o.length-1]+x;S<=y[y.length-1];S+=x)o.push(S);m=o}this.updateCatScale(r,y,m,s,p,g),this._panCumulativeDelta=p!==h?0:this._panCumulativeDelta}}},function(t,e,i){var n=i(0);t.exports={_bindPress:function(){var t=this.chart,e=this.hammer,i=this.el,r=this.pressThreshold,a=this.pressTime,o=t.get("tooltipController");o&&o.enable&&(t.set("_closeTooltip",!0),e?(e.get("press").set({threshold:r,time:a}),e.on("press",n.wrapBehavior(this,"_handlePress"))):n.addEventListener(i,"press",n.wrapBehavior(this,"_handlePress")))},reset:function(){var t=this.chart,e=t.get("tooltipController");e&&(this.pressed=!1,!e.cfg.alwaysShow&&t.hideTooltip(),t.set("_closeTooltip",!0))},_handlePress:function(t){this.pressed=!0;var e=t.center||t.touches[0];this.chart.set("_closeTooltip",!1),this.chart.showTooltip(e)}}},,,function(t,e,i){var n=i(44);i(102),i(90),i(95),i(111),i(112),i(140);var r=i(122),a=i(125),o=i(126),s=i(127),c=i(143),l=i(144);n.Animate=i(99),n.Chart.plugins.register([r,o,a,s,c,l]),i(145),n.Interaction=i(43),t.exports=n},function(t,e,i){t.exports={Text:i(120),Line:i(118),Arc:i(116),Rect:i(119),Html:i(117),Tag:i(121),Point:i(141),RegionFilter:i(142)}},function(t,e,i){function n(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=i(0),a=i(11),o=function(t){function e(){return t.apply(this,arguments)||this}n(e,t);var i=e.prototype;return i._initDefaultCfg=function(){this.type="point",this.position=null,this.offsetX=0,this.offsetY=0,this.style={fill:"#1890FF",r:3,lineWidth:1,stroke:"#fff"}},i.render=function(t,e){var i=this.parsePoint(t,this.position);if(!i)return null;var n=e.addShape("Circle",{className:"guide-point",attrs:r.mix({x:i.x+this.offsetX,y:i.y+this.offsetY},this.style)});return this.element=n,n},e}(a);a.Point=o,t.exports=o},function(t,e,i){function n(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var r=i(0),a=i(11),o=i(2).Rect,s=function(t){function e(){return t.apply(this,arguments)||this}n(e,t);var i=e.prototype;return i._initDefaultCfg=function(){this.type="regionFilter",this.start=[],this.end=[],this.color=null,this.style=null},i.render=function(t){var e=this.parsePoint(t,this.start),i=this.parsePoint(t,this.end);if(e&&i){var n=new o({attrs:{x:Math.min(e.x,i.x),y:Math.min(e.y,i.y),width:Math.abs(i.x-e.x),height:Math.abs(i.y-e.y)}});this.clip=n;var a=this.chart,s=this.color,c=this.style||{},l=[];a.get("geoms").map(function(t){var e=t.get("container"),i=e.get("children"),a=e.addGroup({zIndex:10,className:"guide-region-filter"});return i.map(function(t){if(t.get("isShape")){var e=t.get("type"),i=r.mix({},t.get("attrs"),c);s&&(i.fill||i.fillStyle)&&(i.fill=i.fillStyle=s),s&&(i.stroke||i.strokeStyle)&&(i.stroke=i.strokeStyle=s);var n={attrs:i};"custom"!==e&&"Custom"!==e||(n.createPath=t.get("createPath"),n.calculateBox=t.get("calculateBox")),a.addShape(e,n)}return t}),a.attr("clip",n),e.sort(),l.push(a),t}),this.element=l}},i.remove=function(){var t=this.element;r.each(t,function(t){t&&t.remove(!0)}),this.clip&&this.clip.remove(!0)},e}(a);a.RegionFilter=s,t.exports=s},function(t,e,i){var n=i(101),r=i(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"),i=t.get("_verticalBar");e&&e.remove(!0),i&&i.remove(!0),t.set("_horizontalBar",null),t.set("_verticalBar",null)},afterGeomDraw:function(t){var e=t.get("_scrollBarCfg");if(e){var i=t.get("data"),a=t.get("plotRange"),o=t.get("backPlot"),s=t.get("canvas").get("height"),c=t.get("_limitRange"),l=e.mode;if(r.directionEnabled(l,"x")){var u=e.xStyle,h=u.offsetX,f=u.offsetY,p=u.lineCap,g=u.backgroundColor,d=u.fillerColor,v=u.size,y=t.getXScale(),m=c[y.field];m||(m=n.getLimitRange(i,y),c[y.field]=m);var x=n.getFieldRange(y,m,y.type),_=t.get("_horizontalBar"),S=s-v/2+f;_?_.get("children")[1].attr({x1:Math.max(a.bl.x+a.width*x[0]+h,a.bl.x),x2:Math.min(a.bl.x+a.width*x[1]+h,a.br.x)}):((_=o.addGroup({className:"horizontalBar"})).addShape("line",{attrs:{x1:a.bl.x+h,y1:S,x2:a.br.x+h,y2:S,lineWidth:v,stroke:g,lineCap:p}}),_.addShape("line",{attrs:{x1:Math.max(a.bl.x+a.width*x[0]+h,a.bl.x),y1:S,x2:Math.min(a.bl.x+a.width*x[1]+h,a.br.x),y2:S,lineWidth:v,stroke:d,lineCap:p}}),t.set("_horizontalBar",_))}if(r.directionEnabled(l,"y")){var b=e.yStyle,C=b.offsetX,P=b.offsetY,w=b.lineCap,M=b.backgroundColor,T=b.fillerColor,A=b.size,D=t.getYScales()[0],k=c[D.field];k||(k=n.getLimitRange(i,D),c[D.field]=k);var I=n.getFieldRange(D,k,D.type),O=t.get("_verticalBar"),E=A/2+C;O?O.get("children")[1].attr({y1:Math.max(a.tl.y+a.height*I[0]+P,a.tl.y),y2:Math.min(a.tl.y+a.height*I[1]+P,a.bl.y)}):((O=o.addGroup({className:"verticalBar"})).addShape("line",{attrs:{x1:E,y1:a.tl.y+P,x2:E,y2:a.bl.y+P,lineWidth:A,stroke:M,lineCap:w}}),O.addShape("line",{attrs:{x1:E,y1:Math.max(a.tl.y+a.height*I[0]+P,a.tl.y),x2:E,y2:Math.min(a.tl.y+a.height*I[1]+P,a.bl.y),lineWidth:A,stroke:T,lineCap:w}}),t.set("_verticalBar",O))}}}}},function(t,e,i){function n(t,e,i){return{x:t.x+i*Math.cos(e),y:t.y+i*Math.sin(e)}}function r(t,e){return ek&&e.splice(k,e.length-k),e.sort(function(t,e){return t.y-e.y});var i=t._antiCollision(e);b=b.concat(i)})}this.drawnLabels=b},e.bindEvents=function(){var t=this.pieLabelCfg.triggerOn||"touchstart",e=o.wrapBehavior(this,"_handleEvent");o.addEventListener(this.canvasDom,t,e)},e.unBindEvents=function(){var t=this.pieLabelCfg.triggerOn||"touchstart",e=o.getWrapBehavior(this,"_handleEvent");o.removeEventListener(this.canvasDom,t,e)},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,i=this.chart.get("width"),n=e.sidePadding,r=t.y,a=t.textGroup,o=a.get("children"),s={textAlign:"left"===t._side?"left":"right",x:"left"===t._side?n:i-n};return o.forEach(function(t){t.attr(s),t.attr("y",r+t.get("offsetY"))}),a},e._drawLabelLine=function(t,e){var i=this.chart,n=this.pieLabelCfg,r=this.labelGroup,a=i.get("width"),s=n.sidePadding,c=n.adjustOffset,l=n.lineStyle,u=n.anchorStyle,h=n.skipOverlapLabels,f=t._anchor,p=t._inflection,g=t.fill,d=t.y,v={x:"left"===t._side?s:a-s,y:d},y=[f,p,v];if(!h&&p.y!==d)if(p.ym.x)&&(y=[f,_,v])}else y=[f,{x:p.x,y:d},v];r.addShape("Polyline",{attrs:o.mix({points:y,lineWidth:1,stroke:g},l)}),r.addShape("Circle",{attrs:o.mix({x:f.x,y:f.y,r:2,fill:g},u)})},e._antiCollision=function(t){var e,i=this,n=i.chart,r=i.pieLabelCfg,a=n.get("coord"),o=n.get("height"),s=a.center,c=a.circleRadius,l=r.inflectionOffset,u=r.lineHeight,h=s.y-c-l-u,f=!0,p=o,g=0,d=Number.MIN_VALUE,v=0,y=t.map(function(t){var e=t.y;e>g&&(g=e),e=v&&(v=i),{size:u,targets:[e-h]}});g-h>p&&(p=g-h);for(;f;)for(!function(t){t.forEach(function(t){var e=(Math.min.apply(d,t.targets)+Math.max.apply(d,t.targets))/2;t.pos=Math.min(Math.max(d,e-t.size/2),p-t.size)})}(y),f=!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),f=!0)}e=0,y.forEach(function(i){var n=h;i.targets.forEach(function(){t[e].y=i.pos+n+u/2,n+=u,e++})});var _=[];return t.forEach(function(t){var e=i._drawLabel(t);i.labelGroup.add(e),i._drawLabelLine(t,v),_.push(e)}),_},e._handleEvent=function(t){for(var e,i=this,n=i.chart,r=i.drawnLabels,a=i.pieLabelCfg,s=a.onClick,c=a.activeShape,l=o.createEvent(t,n),u=l.x,h=l.y,f=0,p=r.length;f=d.minX&&u<=d.maxX&&h>=d.minY&&h<=d.maxY){e=g;break}}var v=n.getSnapRecords({x:u,y:h});e?l.data=e.get("data"):v.length&&(l.data=v[0]._origin),s&&s(l),l.data&&c&&this._activeShape(l.data)},e._getSelectedShapeByData=function(t){var e=null,i=this.chart.get("geoms")[0],n=i.get("container").get("children");return o.each(n,function(n){if(n.get("isShape")&&n.get("className")===i.get("type")){var r=n.get("origin")._origin;if(o.isObjectValueEqual(r,t))return e=n,!1}}),e},e._activeShape=function(t){var e=this.chart,i=this.lastSelectedData,n=this.pieLabelCfg;if(t!==i){this.lastSelectedData=t;var r=n.activeStyle,a=this._getSelectedShapeByData(t)._attrs.attrs,s=a.x,c=a.y,l=a.startAngle,u=a.endAngle,h=a.r,f=a.fill,p=e.get("frontPlot");this.halo&&this.halo.remove(!0);var g=p.addShape("sector",{attrs:o.mix({x:s,y:c,r:h+r.offset+r.appendRadius,r0:h+r.offset,fill:f,startAngle:l,endAngle:u},r)});this.halo=g,e.get("canvas").draw()}},t}();t.exports={init:function(t){var e=t.get("frontPlot").addGroup({className:"pie-label",zIndex:0}),i=new l({chart:t,labelGroup:e});t.set("pieLabelController",i),t.pieLabel=function(t){return t=o.deepMix({},c,t),i.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,i){t.exports={Interaction:i(43),PieSelect:i(147),IntervalSelect:i(148),Swipe:i(149),Pan:i(150),Pinch:i(151)}},function(t,e,i){var n;!function(r,a,o,s){"use strict";function c(t,e,i){return setTimeout(p(t,i),e)}function l(t,e,i){return!!Array.isArray(t)&&(u(t,i[e],i),!0)}function u(t,e,i){var n;if(t)if(t.forEach)t.forEach(e,i);else if(t.length!==s)for(n=0;n\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",a=r.console&&(r.console.warn||r.console.log);return a&&a.call(r.console,n,i),t.apply(this,arguments)}}function f(t,e,i){var n,r=e.prototype;(n=t.prototype=Object.create(r)).constructor=t,n._super=r,i&>(n,i)}function p(t,e){return function(){return t.apply(e,arguments)}}function g(t,e){return typeof t==yt?t.apply(e?e[0]||s:s,e):t}function d(t,e){return t===s?e:t}function v(t,e,i){u(_(e),function(e){t.addEventListener(e,i,!1)})}function y(t,e,i){u(_(e),function(e){t.removeEventListener(e,i,!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,i){if(t.indexOf&&!i)return t.indexOf(e);for(var n=0;ni[e]}):n.sort()),n}function P(t,e){for(var i,n,r=e[0].toUpperCase()+e.slice(1),a=0;a1&&!i.firstMultiple?i.firstMultiple=E(e):1===r&&(i.firstMultiple=!1);var a=i.firstInput,o=i.firstMultiple,s=o?o.center:a.center,c=e.center=Y(n);e.timeStamp=_t(),e.deltaTime=e.timeStamp-a.timeStamp,e.angle=R(s,c),e.distance=N(s,c),I(i,e),e.offsetDirection=F(e.deltaX,e.deltaY);var l=B(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=l.x,e.overallVelocityY=l.y,e.overallVelocity=xt(l.x)>xt(l.y)?l.x:l.y,e.scale=o?L(o.pointers,n):1,e.rotation=o?X(o.pointers,n):0,e.maxPointers=i.prevInput?e.pointers.length>i.prevInput.maxPointers?e.pointers.length:i.prevInput.maxPointers:e.pointers.length,O(i,e);var u=t.element;m(e.srcEvent.target,u)&&(u=e.srcEvent.target),e.target=u}function I(t,e){var i=e.center,n=t.offsetDelta||{},r=t.prevDelta||{},a=t.prevInput||{};e.eventType!==Dt&&a.eventType!==It||(r=t.prevDelta={x:a.deltaX||0,y:a.deltaY||0},n=t.offsetDelta={x:i.x,y:i.y}),e.deltaX=r.x+(i.x-n.x),e.deltaY=r.y+(i.y-n.y)}function O(t,e){var i,n,r,a,o=t.lastInterval||e,c=e.timeStamp-o.timeStamp;if(e.eventType!=Ot&&(c>At||o.velocity===s)){var l=e.deltaX-o.deltaX,u=e.deltaY-o.deltaY,h=B(c,l,u);n=h.x,r=h.y,i=xt(h.x)>xt(h.y)?h.x:h.y,a=F(l,u),t.lastInterval=e}else i=o.velocity,n=o.velocityX,r=o.velocityY,a=o.direction;e.velocity=i,e.velocityX=n,e.velocityY=r,e.direction=a}function E(t){for(var e=[],i=0;i=xt(e)?t<0?Yt:Bt:e<0?Ft:Nt}function N(t,e,i){i||(i=zt);var n=e[i[0]]-t[i[0]],r=e[i[1]]-t[i[1]];return Math.sqrt(n*n+r*r)}function R(t,e,i){i||(i=zt);var n=e[i[0]]-t[i[0]],r=e[i[1]]-t[i[1]];return 180*Math.atan2(r,n)/Math.PI}function X(t,e){return R(e[1],e[0],jt)+R(t[1],t[0],jt)}function L(t,e){return N(e[0],e[1],jt)/N(t[0],t[1],jt)}function z(){this.evEl=Wt,this.evWin=Ht,this.pressed=!1,T.apply(this,arguments)}function j(){this.evEl=Ut,this.evWin=Zt,T.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function G(){this.evTarget=$t,this.evWin=Kt,this.started=!1,T.apply(this,arguments)}function W(t,e){var i=b(t.touches),n=b(t.changedTouches);return e&(It|Ot)&&(i=C(i.concat(n),"identifier",!0)),[i,n]}function H(){this.evTarget=te,this.targetIds={},T.apply(this,arguments)}function V(t,e){var i=b(t.touches),n=this.targetIds;if(e&(Dt|kt)&&1===i.length)return n[i[0].identifier]=!0,[i,i];var r,a,o=b(t.changedTouches),s=[],c=this.target;if(a=i.filter(function(t){return m(t.target,c)}),e===Dt)for(r=0;r-1&&n.splice(t,1)},ee)}}function J(t){for(var e=t.srcEvent.clientX,i=t.srcEvent.clientY,n=0;n-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){i.manager.emit(e,t)}var i=this,n=this.state;n=ge&&e(i.options.event+tt(n))},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 nt.prototype.attrTest.call(this,t)&&(this.state&fe||!(this.state&fe)&&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)}}),f(at,nt,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[se]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||this.state&fe)},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)}}),f(ot,Q,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[ae]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,n=t.distancee.time;if(this._input=t,!n||!i||t.eventType&(It|Ot)&&!r)this.reset();else if(t.eventType&Dt)this.reset(),this._timer=c(function(){this.state=de,this.tryEmit()},e.time,this);else if(t.eventType&It)return de;return 32},reset:function(){clearTimeout(this._timer)},emit:function(t){this.state===de&&(t&&t.eventType&It?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=_t(),this.manager.emit(this.options.event,this._input)))}}),f(st,nt,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[se]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||this.state&fe)}}),f(ct,nt,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Rt|Xt,pointers:1},getTouchAction:function(){return rt.prototype.getTouchAction.call(this)},attrTest:function(t){var e,i=this.options.direction;return i&(Rt|Xt)?e=t.overallVelocity:i&Rt?e=t.overallVelocityX:i&Xt&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&i&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&&xt(e)>this.options.velocity&&t.eventType&It},emit:function(t){var e=et(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)}}),f(lt,Q,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[oe]},process:function(t){var e=this.options,i=t.pointers.length===e.pointers,n=t.distance=e.x&&o<=e.x+e.width&&s>=e.y&&s<=e.height+e.y?i=t:u.push(t)})}else if("range"===c){var f=e.getSnapRecords({x:o,y:s});if(!f.length)return void this.reset();var p=f[0]._origin,g=this._selectShapesByData(p);i=g.selectedShape,u=g.unSelectedShapes}if(i)if(this.selectedShape=i,i.get("_selected")){if(!this.cancelable)return void this._setEventData(t);this.reset()}else this._selectShapes(i,u);else this.reset();this._setEventData(t)},i.end=function(t){this._setEventData(t)},e}(o);s.registerInteraction("interval-select",c),t.exports=c},function(t,e,i){function n(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function r(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var a=i(0),o=i(43),s=i(15),c=i(133),l=i(135),u=i(134),h=function(t){function e(e,i){var r,o=n(r=t.call(this,e,i)||this),s=o.hammer,h=o.threshold,f=o.velocity;return s&&s.get("swipe").set({direction:6,threshold:h,velocity:f}),i.registerPlugins([c,{changeData:function(){o.limitRange={}},clear:function(){o.limitRange={}}}]),o.mode="x",a.mix(o,u,l),r}r(e,t);var i=e.prototype;return i.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e=a.mix({},e,{startEvent:"touchstart",processEvent:"swipe",endEvent:"touchend",currentDeltaX:null,threshold:10,velocity:.3,limitRange:{},_timestamp:0,_panCumulativeDelta:0,speed:5})},i.process=function(t){this.currentDeltaX=0,this._handleMove(t)},i.end=function(){this.currentDeltaX=null,this._panCumulativeDelta=0},e}(o);s.registerInteraction("swipe",h),t.exports=h},function(t,e,i){function n(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function r(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var a=i(0),o=i(43),s=i(15),c=i(133),l=i(135),u=i(136),h=i(134),f=function(t){function e(e,i){var r,o=n(r=t.call(this,e,i)||this),s=o.hammer,f=o.panThreshold;return s&&s.get("pan").set({threshold:f}),i.registerPlugins([c,{changeData:function(){o.limitRange={}},clear:function(){o.limitRange={}}}]),a.mix(n(r),h,l,u),r._bindPress(),r}r(e,t);var i=e.prototype;return i.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e=a.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}),(a.isWx||a.isMy)&&(e.startEvent="touchstart",e.processEvent="touchmove",e.endEvent="touchend"),e},i.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))},i.process=function(t){this.pressed||this._handleMove(t)},i.end=function(){this.pressed||(this.currentDeltaX=null,this.currentDeltaY=null,this.lastPoint=null,this._panCumulativeDelta=0)},e}(o);s.registerInteraction("pan",f),t.exports=f},function(t,e,i){function n(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function r(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}var a=i(0),o=i(101),s=i(43),c=i(15),l=i(133),u=i(136),h=i(134),f=function(t){function e(e,i){var r,o=n(r=t.call(this,e,i)||this);return o.hammer.get("pinch").set({enable:!0}),i.registerPlugins([l,{changeData:function(){o.limitRange={},o.originTicks=null},clear:function(){o.limitRange={},o.originTicks=null}}]),a.mix(o,u,h),o._bindPress(),r}r(e,t);var i=e.prototype;return i.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return a.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})},i.start=function(){this.pressed||(this.currentPinchScaling=1)},i.process=function(t){this.pressed||this._handlePinch(t)},i.end=function(t){this.pressed||(this._handlePinch(t),this.currentPinchScaling=null,this.pinchCumulativeDelta=0)},i._handlePinch=function(t){var e,i=1/this.currentPinchScaling*t.scale,n=t.target.getBoundingClientRect(),r={x:t.center.x-n.left,y:t.center.y-n.top},a=Math.abs(t.pointers[0].clientX-t.pointers[1].clientX),o=Math.abs(t.pointers[0].clientY-t.pointers[1].clientY),s=a/o;e=s>.3&&s<1.7?"xy":a>o?"x":"y";var c=this._timestamp,l=+new Date;l-c>16&&(this._doZoom(i,r,e),this._timestamp=l),this.currentPinchScaling=t.scale},i._doZoom=function(t,e,i){var n,r=this,s=r.mode,c=r.chart,l=r.limitRange;n="xy"===s&&void 0!==i?i:"xy";var u=c.get("data");if(a.directionEnabled(s,"x")&&a.directionEnabled(n,"x")){var h=c.getXScale(),f=h.field;l[f]||(l[f]=o.getLimitRange(u,h)),h.isCategory?r._zoomCatScale(h,t,e):h.isLinear&&r._zoomLinearScale(h,t,e,"x");var p=o.getColDef(c,f);this.xRange=o.getFieldRange(p,l[f],h.type)}if(a.directionEnabled(s,"y")&&a.directionEnabled(n,"y")){var g=c.getYScales();a.each(g,function(i){var n=i.field;l[n]||(l[n]=o.getLimitRange(u,i)),i.isLinear&&r._zoomLinearScale(i,t,e,"y")});var d=o.getColDef(c,g[0].field);this.yRange=o.getFieldRange(d,l[g[0].field],g[0].type)}c.repaint()},i._zoomLinearScale=function(t,e,i,n){var r=this.chart,a=t.min,o=t.max,s=t.field,c=o-a,l=this.limitRange,u=l[s].max-l[s].min,h=r.get("coord"),f=c*(e-1);if(this.minScale&&e<1){var p=u/this.minScale;f=Math.max(c-p,f)}if(this.maxScale&&e>=1){var g=u/this.maxScale;f=Math.min(c-g,f)}var d=h.invertPoint(i),v="x"===n?d.x:d.y,y=o-f*(1-v),m=a+f*v;this.updateLinearScale(s,m,y)},i._zoomCatScale=function(t,e,i){var n=this._pinchCumulativeDelta,r=this.sensitivity;n=e>1?n+1:n-1,this._pinchCumulativeDelta=n;var a=t.field,o=t.values,s=this.chart.get("coord");this.originTicks||(this.originTicks=t.ticks);var c=this.limitRange[a],l=c.length,u=this.minScale||1,h=this.maxScale||5,f=parseInt(l/h),p=parseInt(l/u),g=o.length;if(n>0&&g<=f)return null;if(n<0&&g>=p)return null;var d=l-1,v=o[0],y=o[g-1],m=c.indexOf(v),x=c.indexOf(y),_=(s.start.x+s.end.x)/2,S=i.x;if(Math.abs(n)>r){var b=Math.max(1,parseInt(g*Math.abs(e-1)));n<0?(S>=_?m<=0?x=Math.min(d,x+b):m=Math.max(0,m-b):S<_&&(x>=d?m=Math.max(0,m-b):x=Math.min(d,x+b)),this._pinchCumulativeDelta=0):n>0&&(S>=_?m=mm?x=Math.max(m,x-b):x),this._pinchCumulativeDelta=0);var C=c.slice(m,x+1);this.updateCatScale(a,C,this.originTicks,c,m,x)}},e}(s);c.registerInteraction("pinch",f),t.exports=f}])});