/*! * Chart.js * http://chartjs.org/ * Version: 2.7.1 * * Copyright 2017 Nick Downie * Released under the MIT license * https://github.com/chartjs/Chart.js/blob/master/LICENSE.md */ !function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,e.Chart=t()}}(function(){return function t(e,i,n){function a(r,s){if(!i[r]){if(!e[r]){var l="function"==typeof require&&require;if(!s&&l)return l(r,!0);if(o)return o(r,!0);var c=new Error("Cannot find module '"+r+"'");throw c.code="MODULE_NOT_FOUND",c}var d=i[r]={exports:{}};e[r][0].call(d.exports,function(t){var i=e[r][1][t];return a(i?i:t)},d,d.exports,t,e,i,n)}return i[r].exports}for(var o="function"==typeof require&&require,r=0;r0?Math.min(r,n-i):r,i=n;return r}function a(t,e,i){var n,a,o=i.barThickness,r=e.stackCount,s=e.pixels[t];return l.isNullOrUndef(o)?(n=e.min*i.categoryPercentage,a=i.barPercentage):(n=o*r,a=1),{chunk:n/r,ratio:a,start:s-n/2}}function o(t,e,i){var n,a,o=e.pixels,r=o[t],s=t>0?o[t-1]:null,l=t=0;--i)e.isDatasetVisible(i)&&e.drawDataset(i,t)},drawDataset:function(t,e){var i=this,n=i.getDatasetMeta(t);n.controller.draw(e)},getDatasetMeta:function(t){var e=this,i=e.data.datasets[t];i._meta||(i._meta={});var n=i._meta[e.id];return n||(n=i._meta[e.id]={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null}),n},getVisibleDatasetCount:function(){for(var t=0,e=0,i=this.data.datasets.length;e=i[e].length&&i[e].push({}),!i[e][r].type||l.type&&l.type!==i[e][r].type?n.merge(i[e][r],[t.scaleService.getScaleDefaults(s),l]):n.merge(i[e][r],l)}else n._merger(e,i,a,o)}})},n.where=function(t,e){if(n.isArray(t)&&Array.prototype.filter)return t.filter(e);var i=[];return n.each(t,function(t){e(t)&&i.push(t)}),i},n.findIndex=Array.prototype.findIndex?function(t,e,i){return t.findIndex(e,i)}:function(t,e,i){i=void 0===i?t:i;for(var n=0,a=t.length;n=0;a--){var o=t[a];if(e(o))return o}},n.isNumber=function(t){return!isNaN(parseFloat(t))&&isFinite(t)},n.almostEquals=function(t,e,i){return Math.abs(t-e)t},n.max=function(t){return t.reduce(function(t,e){return isNaN(e)?t:Math.max(t,e)},Number.NEGATIVE_INFINITY)},n.min=function(t){return t.reduce(function(t,e){return isNaN(e)?t:Math.min(t,e)},Number.POSITIVE_INFINITY)},n.sign=Math.sign?function(t){return Math.sign(t)}:function(t){return t=+t,0===t||isNaN(t)?t:t>0?1:-1},n.log10=Math.log10?function(t){return Math.log10(t)}:function(t){return Math.log(t)/Math.LN10},n.toRadians=function(t){return t*(Math.PI/180)},n.aliasPixel=function(t){return t%2===0?0:.5},n.EPSILON=Number.EPSILON||1e-14,n.splineCurveMonotone=function(t){var e,i,a,o,r=(t||[]).map(function(t){return{model:t._model,deltaK:0,mK:0}}),s=r.length;for(e=0;e0?r[e-1]:null,o=e0?r[e-1]:null,o=e=t.length-1?t[0]:t[e+1]:e>=t.length-1?t[t.length-1]:t[e+1]},n.previousItem=function(t,e,i){return i?e<=0?t[t.length-1]:t[e-1]:e<=0?t[0]:t[e-1]},n.niceNum=function(t,e){var i,a=Math.floor(n.log10(t)),o=t/Math.pow(10,a);return i=e?o<1.5?1:o<3?2:o<7?5:10:o<=1?1:o<=2?2:o<=5?5:10,i*Math.pow(10,a)},n.requestAnimFrame=function(){return"undefined"==typeof window?function(t){t()}:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return window.setTimeout(t,1e3/60)}}(),n.getConstraintWidth=function(t){return a(t,"max-width","clientWidth")},n.getConstraintHeight=function(t){return a(t,"max-height","clientHeight")},n.getMaximumWidth=function(t){var e=t.parentNode;if(!e)return t.clientWidth;var i=parseInt(n.getStyle(e,"padding-left"),10),a=parseInt(n.getStyle(e,"padding-right"),10),o=e.clientWidth-i-a,r=n.getConstraintWidth(t);return isNaN(r)?o:Math.min(o,r)},n.getMaximumHeight=function(t){var e=t.parentNode;if(!e)return t.clientHeight;var i=parseInt(n.getStyle(e,"padding-top"),10),a=parseInt(n.getStyle(e,"padding-bottom"),10),o=e.clientHeight-i-a,r=n.getConstraintHeight(t);return isNaN(r)?o:Math.min(o,r)},n.getStyle=function(t,e){return t.currentStyle?t.currentStyle[e]:document.defaultView.getComputedStyle(t,null).getPropertyValue(e)},n.retinaScale=function(t,e){var i=t.currentDevicePixelRatio=e||window.devicePixelRatio||1;if(1!==i){var n=t.canvas,a=t.height,o=t.width;n.height=a*i,n.width=o*i,t.ctx.scale(i,i),n.style.height||n.style.width||(n.style.height=a+"px",n.style.width=o+"px")}},n.fontString=function(t,e,i){return e+" "+t+"px "+i},n.longestText=function(t,e,i,a){a=a||{};var o=a.data=a.data||{},r=a.garbageCollect=a.garbageCollect||[];a.font!==e&&(o=a.data={},r=a.garbageCollect=[],a.font=e),t.font=e;var s=0;n.each(i,function(e){void 0!==e&&null!==e&&n.isArray(e)!==!0?s=n.measureText(t,o,r,s,e):n.isArray(e)&&n.each(e,function(e){void 0===e||null===e||n.isArray(e)||(s=n.measureText(t,o,r,s,e))})});var l=r.length/2;if(l>i.length){for(var c=0;cn&&(n=o),n},n.numberOfLabelLines=function(t){var e=1;return n.each(t,function(t){n.isArray(t)&&t.length>e&&(e=t.length)}),e}}},{22:22,6:6}],9:[function(t,e,i){"use strict";var n=t(6);n._set("global",{responsive:!0,maintainAspectRatio:!0,defaultColor:"rgba(0,0,0,0.1)",defaultFontColor:"#666",defaultFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",defaultFontSize:12,defaultFontStyle:"normal",showLines:!0,elements:{},layout:{padding:{top:0,right:0,bottom:0,left:0}}}),e.exports=function(){var t=function(t,e){return this.construct(t,e),this};return t.Chart=t,t}},{6:6}],10:[function(t,e,i){"use strict";var n=t(22);e.exports=function(t){function e(t,e){return n.where(t,function(t){return t.position===e})}function i(t,e){t.forEach(function(t,e){return t._tmpIndex_=e,t}),t.sort(function(t,i){var n=e?i:t,a=e?t:i;return n.weight===a.weight?n._tmpIndex_-a._tmpIndex_:n.weight-a.weight}),t.forEach(function(t){delete t._tmpIndex_})}t.layoutService={defaults:{},addBox:function(t,e){t.boxes||(t.boxes=[]),e.fullWidth=e.fullWidth||!1,e.position=e.position||"top",e.weight=e.weight||0,t.boxes.push(e)},removeBox:function(t,e){var i=t.boxes?t.boxes.indexOf(e):-1;i!==-1&&t.boxes.splice(i,1)},configure:function(t,e,i){for(var n,a=["fullWidth","position","weight"],o=a.length,r=0;rf&&lt.maxHeight){l--;break}l++,h=c*u}t.labelRotation=l},fit:function(){var t=this,a=t.minSize={width:0,height:0},o=n(t._ticks),r=t.options,l=r.ticks,c=r.gridLines,d=r.display,u=t.isHorizontal(),h=i(l),f=r.gridLines.tickMarkLength;if(u?a.width=t.isFullWidth()?t.maxWidth-t.margins.left-t.margins.right:t.maxWidth:a.width=d&&c.drawTicks?f:0,u?a.height=d&&c.drawTicks?f:0:a.height=t.maxHeight,l.display&&d){var p=s.longestText(t.ctx,h.font,o,t.longestTextCache),g=s.numberOfLabelLines(o),m=.5*h.size,x=t.options.ticks.padding;if(u){t.longestLabelWidth=p;var v=s.toRadians(t.labelRotation),b=Math.cos(v),y=Math.sin(v),w=y*p+h.size*g+m*(g-1)+m;a.height=Math.min(t.maxHeight,a.height+w+x),t.ctx.font=h.font;var k=e(t.ctx,o[0],h.font),D=e(t.ctx,o[o.length-1],h.font);0!==t.labelRotation?(t.paddingLeft="bottom"===r.position?b*k+3:b*m+3,t.paddingRight="bottom"===r.position?b*m+3:b*D+3):(t.paddingLeft=k/2+3,t.paddingRight=D/2+3)}else l.mirror?p=0:p+=x+m,a.width=Math.min(t.maxWidth,a.width+p),t.paddingTop=h.size/2,t.paddingBottom=h.size/2}t.handleMargins(),t.width=a.width,t.height=a.height},handleMargins:function(){var t=this;t.margins&&(t.paddingLeft=Math.max(t.paddingLeft-t.margins.left,0),t.paddingTop=Math.max(t.paddingTop-t.margins.top,0),t.paddingRight=Math.max(t.paddingRight-t.margins.right,0),t.paddingBottom=Math.max(t.paddingBottom-t.margins.bottom,0))},isHorizontal:function(){return"top"===this.options.position||"bottom"===this.options.position},isFullWidth:function(){return this.options.fullWidth},getRightValue:function(t){if(s.isNullOrUndef(t))return NaN;if("number"==typeof t&&!isFinite(t))return NaN;if(t)if(this.isHorizontal()){if(void 0!==t.x)return this.getRightValue(t.x)}else if(void 0!==t.y)return this.getRightValue(t.y);return t},getLabelForIndex:s.noop,getPixelForValue:s.noop,getValueForPixel:s.noop,getPixelForTick:function(t){var e=this,i=e.options.offset;if(e.isHorizontal()){var n=e.width-(e.paddingLeft+e.paddingRight),a=n/Math.max(e._ticks.length-(i?0:1),1),o=a*t+e.paddingLeft;i&&(o+=a/2);var r=e.left+Math.round(o);return r+=e.isFullWidth()?e.margins.left:0}var s=e.height-(e.paddingTop+e.paddingBottom);return e.top+t*(s/(e._ticks.length-1))},getPixelForDecimal:function(t){var e=this;if(e.isHorizontal()){var i=e.width-(e.paddingLeft+e.paddingRight),n=i*t+e.paddingLeft,a=e.left+Math.round(n);return a+=e.isFullWidth()?e.margins.left:0}return e.top+t*e.height},getBasePixel:function(){return this.getPixelForValue(this.getBaseValue())},getBaseValue:function(){var t=this,e=t.min,i=t.max;return t.beginAtZero?0:e<0&&i<0?i:e>0&&i>0?e:0},draw:function(t){var e=this,n=e.options;if(n.display){var r=e.ctx,l=o.global,c=n.ticks.minor,d=n.ticks.major||c,u=n.gridLines,h=0!==e.labelRotation,f=e.isHorizontal(),p=e.getTicks(),g=s.valueOrDefault(c.fontColor,l.defaultFontColor),m=i(c),x=s.valueOrDefault(d.fontColor,l.defaultFontColor),v=i(d),b=u.drawTicks?u.tickMarkLength:0,y=s.toRadians(e.labelRotation),w=[],k="right"===n.position?e.left:e.right-b,D="right"===n.position?e.left+b:e.right,M="bottom"===n.position?e.top:e.bottom-b,S="bottom"===n.position?e.top+b:e.bottom;s.each(p,function(i,o){ if(!s.isNullOrUndef(i.label)){var r,d,g,m,x=i.label;o===e.zeroLineIndex&&n.offset===u.offsetGridLines?(r=u.zeroLineWidth,d=u.zeroLineColor,g=u.zeroLineBorderDash,m=u.zeroLineBorderDashOffset):(r=s.valueAtIndexOrDefault(u.lineWidth,o),d=s.valueAtIndexOrDefault(u.color,o),g=s.valueOrDefault(u.borderDash,l.borderDash),m=s.valueOrDefault(u.borderDashOffset,l.borderDashOffset));var v,I,P,T,A,O,_,C,L,z,N="middle",F="middle",R=c.padding;if(f){var W=b+R;"bottom"===n.position?(F=h?"middle":"top",N=h?"right":"center",z=e.top+W):(F=h?"middle":"bottom",N=h?"left":"center",z=e.bottom-W);var V=a(e,o,u.offsetGridLines&&p.length>1);V1);E0)i=t.stepSize;else{var o=n.niceNum(e.max-e.min,!1);i=n.niceNum(o/(t.maxTicks-1),!0)}var r=Math.floor(e.min/i)*i,s=Math.ceil(e.max/i)*i;t.min&&t.max&&t.stepSize&&n.almostWhole((t.max-t.min)/t.stepSize,i/1e3)&&(r=t.min,s=t.max);var l=(s-r)/i;l=n.almostEquals(l,Math.round(l),i/1e3)?Math.round(l):Math.ceil(l);var c=1;i<1&&(c=Math.pow(10,i.toString().length-2),r=Math.round(r*c)/c,s=Math.round(s*c)/c),a.push(void 0!==t.min?t.min:r);for(var d=1;d3?i[2]-i[1]:i[1]-i[0];Math.abs(a)>1&&t!==Math.floor(t)&&(a=t-Math.floor(t));var o=n.log10(Math.abs(a)),r="";if(0!==t){var s=-1*Math.floor(o);s=Math.max(Math.min(s,20),0),r=t.toFixed(s)}else r="0";return r}}}},{22:22}],14:[function(t,e,i){"use strict";var n=t(6),a=t(7),o=t(22),r=n.global;n._set("global",{elements:{line:{tension:.4,backgroundColor:r.defaultColor,borderWidth:3,borderColor:r.defaultColor,borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",capBezierPoints:!0}}}),e.exports=a.extend({draw:function(){var t,e,i,n,a=this,s=a._view,l=a._chart.ctx,c=s.spanGaps,d=a._children.slice(),u=r.elements.line,h=-1;for(a._loop&&d.length&&d.push(d[0]),l.save(),l.lineCap=s.borderCapStyle||u.borderCapStyle,l.setLineDash&&l.setLineDash(s.borderDash||u.borderDash),l.lineDashOffset=s.borderDashOffset||u.borderDashOffset,l.lineJoin=s.borderJoinStyle||u.borderJoinStyle,l.lineWidth=s.borderWidth||u.borderWidth,l.strokeStyle=s.borderColor||r.defaultColor,l.beginPath(),h=-1,t=0;te?1:-1,r=1,s=c.borderSkipped||"left"):(e=c.x-c.width/2,i=c.x+c.width/2,n=c.y,a=c.base,o=1,r=a>n?1:-1,s=c.borderSkipped||"bottom"),d){var u=Math.min(Math.abs(e-i),Math.abs(n-a));d=d>u?u:d;var h=d/2,f=e+("left"!==s?h*o:0),p=i+("right"!==s?-h*o:0),g=n+("top"!==s?h*r:0),m=a+("bottom"!==s?-h*r:0);f!==p&&(n=g,a=m),g!==m&&(e=f,i=p)}l.beginPath(),l.fillStyle=c.backgroundColor,l.strokeStyle=c.borderColor,l.lineWidth=d;var x=[[e,a],[e,n],[i,n],[i,a]],v=["bottom","left","top","right"],b=v.indexOf(s,0);b===-1&&(b=0);var y=t(0);l.moveTo(y[0],y[1]);for(var w=1;w<4;w++)y=t(w),l.lineTo(y[0],y[1]);l.fill(),d&&l.stroke()},height:function(){var t=this._view;return t.base-t.y}})},{6:6,7:7}],17:[function(t,e,i){"use strict";e.exports={},e.exports.Line=t(14),e.exports.Point=t(15),e.exports.Rectangle=t(16)},{14:14,15:15,16:16}],18:[function(t,e,i){"use strict";var n=t(19),i=e.exports={clear:function(t){t.ctx.clearRect(0,0,t.width,t.height)},drawPoint:function(t,e,i,n,a){isNaN(i)||i<=0||(t.beginPath(),t.arc(n,a,i,0,2*Math.PI),t.closePath(),t.fill(),t.stroke())},clipArea:function(t,e){t.save(),t.beginPath(),t.rect(e.left,e.top,e.right-e.left,e.bottom-e.top),t.clip()},unclipArea:function(t){t.restore()},lineTo:function(t,e,i,n){return i.steppedLine?("after"===i.steppedLine&&!n||"after"!==i.steppedLine&&n?t.lineTo(e.x,i.y):t.lineTo(i.x,e.y),void t.lineTo(i.x,i.y)):i.tension?void t.bezierCurveTo(n?e.controlPointPreviousX:e.controlPointNextX,n?e.controlPointPreviousY:e.controlPointNextY,n?i.controlPointNextX:i.controlPointPreviousX,n?i.controlPointNextY:i.controlPointPreviousY,i.x,i.y):void t.lineTo(i.x,i.y)}};n.clear=i.clear},{19:19}],19:[function(t,e,i){"use strict";var n={noop:function(){},uid:function(){var t=0;return function(){return t++}}(),isNullOrUndef:function(t){return null===t||"undefined"==typeof t},isArray:Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)},isObject:function(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)},valueOrDefault:function(t,e){return"undefined"==typeof t?e:t},valueAtIndexOrDefault:function(t,e,i){return n.valueOrDefault(n.isArray(t)?t[e]:t,i)},callback:function(t,e,i){if(t&&"function"==typeof t.call)return t.apply(i,e)},each:function(t,e,i,a){var o,r,s;if(n.isArray(t))if(r=t.length,a)for(o=r-1;o>=0;o--)e.call(i,t[o],o);else for(o=0;o
';var r=e.childNodes[0],s=e.childNodes[1];e._reset=function(){r.scrollLeft=n,r.scrollTop=n,s.scrollLeft=n,s.scrollTop=n};var l=function(){e._reset(),t()};return o(r,"scroll",l.bind(r,"expand")),o(s,"scroll",l.bind(s,"shrink")),e}function c(t,e){var i=t[f]||(t[f]={}),n=i.renderProxy=function(t){t.animationName===m&&e()};h.each(x,function(e){o(t,e,n)}),i.reflow=!!t.offsetParent,t.classList.add(g)}function d(t,e,i){var n=t[f]||(t[f]={}),a=n.resizer=l(s(function(){if(n.resizer)return e(r("resize",i))}));c(t,function(){if(n.resizer){var e=t.parentNode;e&&e!==a.parentNode&&e.insertBefore(a,e.firstChild),a._reset()}})}function u(t,e){var i=t._style||document.createElement("style");t._style||(t._style=i,e="/* Chart.js */\n"+e,i.setAttribute("type","text/css"),document.getElementsByTagName("head")[0].appendChild(i)),i.appendChild(document.createTextNode(e))}var h=t(22),f="$chartjs",p="chartjs-",g=p+"render-monitor",m=p+"render-animation",x=["animationstart","webkitAnimationStart"],v=function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("e",null,e)}catch(i){}return t}(),b=!!v&&{passive:!0};e.exports={initialize:function(){var t="from{opacity:0.99}to{opacity:1}";u(this,"@-webkit-keyframes "+m+"{"+t+"}@keyframes "+m+"{"+t+"}."+g+"{-webkit-animation:"+m+" 0.001s;animation:"+m+" 0.001s;}")},acquireContext:function(t,e){"string"==typeof t?t=document.getElementById(t):t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas);var i=t&&t.getContext&&t.getContext("2d");return i&&i.canvas===t?(a(t,e),i):null},addEventListener:function(t,e,i){var n=t.canvas;if("resize"===e)return void d(n,i,t)}}},{22:22}],24:[function(t,e,i){"use strict";var n=(t(22),t(23));e.exports=n},{22:22,23:23}],25:[function(t,e,i){"use strict";e.exports=function(t){var e={position:"bottom"},i=t.Scale.extend({getLabels:function(){var t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels},determineDataLimits:function(){var t=this,e=t.getLabels();t.minIndex=0,t.maxIndex=e.length-1;var i;void 0!==t.options.ticks.min&&(i=e.indexOf(t.options.ticks.min),t.minIndex=i!==-1?i:t.minIndex),void 0!==t.options.ticks.max&&(i=e.indexOf(t.options.ticks.max),t.maxIndex=i!==-1?i:t.maxIndex),t.min=e[t.minIndex],t.max=e[t.maxIndex]},buildTicks:function(){var t=this,e=t.getLabels();t.ticks=0===t.minIndex&&t.maxIndex===e.length-1?e:e.slice(t.minIndex,t.maxIndex+1)},getPixelForValue:function(t,e){var i,n=this,a=n.options.offset,o=Math.max(n.maxIndex+1-n.minIndex-(a?0:1),1);if(void 0!==t&&null!==t&&(i=n.isHorizontal()?t.x:t.y),void 0!==i||void 0!==t&&isNaN(e)){var r=n.getLabels();t=i||t;var s=r.indexOf(t);e=s!==-1?s:e}if(n.isHorizontal()){var l=n.width/o,c=l*(e-n.minIndex);return a&&(c+=l/2),n.left+Math.round(c)}var d=n.height/o,u=d*(e-n.minIndex);return a&&(u+=d/2),n.top+Math.round(u)},getPixelForTick:function(t){return this.getPixelForValue(this.ticks[t],t+this.minIndex,null)},getValueForPixel:function(t){var e,i=this,n=i.options.offset,a=Math.max(i._ticks.length-(n?0:1),1),o=i.isHorizontal(),r=(o?i.width:i.height)/a;return t-=o?i.left:i.top,n&&(t-=r/2),e=t<=0?0:Math.round(t/r),e+i.minIndex},getBasePixel:function(){return this.bottom}});t.scaleService.registerScaleType("category",i,e)}},{}],26:[function(t,e,i){"use strict";var n=t(6),a=t(22),o=t(13);e.exports=function(t){var e={position:"left",ticks:{callback:o.formatters.linear}},i=t.LinearScaleBase.extend({determineDataLimits:function(){function t(t){return r?t.xAxisID===e.id:t.yAxisID===e.id}var e=this,i=(e.options,e.chart),n=i.data,o=n.datasets,r=e.isHorizontal(),s=0,l=1;e.min=null,e.max=null,a.each(o,function(n,o){var r=i.getDatasetMeta(o);i.isDatasetVisible(o)&&t(r)&&a.each(n.data,function(t,i){var n=+e.getRightValue(t);isNaN(n)||r.data[i].hidden||(null===e.min?e.min=n:ne.max&&(e.max=n))})}),e.min=isFinite(e.min)&&!isNaN(e.min)?e.min:s,e.max=isFinite(e.max)&&!isNaN(e.max)?e.max:l,this.handleTickRangeOptions()},getTickLimit:function(){var t,e=this,i=e.options.ticks;if(e.isHorizontal())t=Math.min(i.maxTicksLimit?i.maxTicksLimit:11,Math.ceil(e.width/50));else{var o=a.valueOrDefault(i.fontSize,n.global.defaultFontSize);t=Math.min(i.maxTicksLimit?i.maxTicksLimit:11,Math.ceil(e.height/(2*o)))}return t},handleDirectionalChanges:function(){this.isHorizontal()||this.ticks.reverse()},getPixelForValue:function(t){var e,i=this,n=i.start,a=+i.getRightValue(t),o=i.end-n;return e=i.isHorizontal()?i.left+i.width/o*(a-n):i.bottom-i.height/o*(a-n)},getValueForPixel:function(t){var e=this,i=e.isHorizontal(),n=i?e.width:e.height,a=(i?t-e.left:e.bottom-t)/n;return e.start+(e.end-e.start)*a},getPixelForTick:function(t){return this.getPixelForValue(this.ticksAsNumbers[t])}});t.scaleService.registerScaleType("linear",i,e)}},{13:13,22:22,6:6}],27:[function(t,e,i){"use strict";var n=t(22),a=t(13);e.exports=function(t){var e=n.noop;t.LinearScaleBase=t.Scale.extend({getRightValue:function(e){return"string"==typeof e?+e:t.Scale.prototype.getRightValue.call(this,e)},handleTickRangeOptions:function(){var t=this,e=t.options,i=e.ticks;if(i.beginAtZero){var a=n.sign(t.min),o=n.sign(t.max);a<0&&o<0?t.max=0:a>0&&o>0&&(t.min=0)}var r=void 0!==i.min||void 0!==i.suggestedMin,s=void 0!==i.max||void 0!==i.suggestedMax;void 0!==i.min?t.min=i.min:void 0!==i.suggestedMin&&(null===t.min?t.min=i.suggestedMin:t.min=Math.min(t.min,i.suggestedMin)),void 0!==i.max?t.max=i.max:void 0!==i.suggestedMax&&(null===t.max?t.max=i.suggestedMax:t.max=Math.max(t.max,i.suggestedMax)),r!==s&&t.min>=t.max&&(r?t.max=t.min+1:t.min=t.max-1),t.min===t.max&&(t.max++,i.beginAtZero||t.min--)},getTickLimit:e,handleDirectionalChanges:e,buildTicks:function(){var t=this,e=t.options,i=e.ticks,o=t.getTickLimit();o=Math.max(2,o);var r={maxTicks:o,min:i.min,max:i.max,stepSize:n.valueOrDefault(i.fixedStepSize,i.stepSize)},s=t.ticks=a.generators.linear(r,t);t.handleDirectionalChanges(),t.max=n.max(s),t.min=n.min(s),i.reverse?(s.reverse(),t.start=t.max,t.end=t.min):(t.start=t.min,t.end=t.max)},convertTicksToLabels:function(){var e=this;e.ticksAsNumbers=e.ticks.slice(),e.zeroLineIndex=e.ticks.indexOf(0),t.Scale.prototype.convertTicksToLabels.call(e)}})}},{13:13,22:22}]},{},[1])(1)});