21 lines
184 KiB
JavaScript
21 lines
184 KiB
JavaScript
|
!function t(e,i,s){function o(n,r){if(!i[n]){if(!e[n]){var h="function"==typeof require&&require;if(!r&&h)return h(n,!0);if(a)return a(n,!0);var l=new Error("Cannot find module '"+n+"'");throw l.code="MODULE_NOT_FOUND",l}var c=i[n]={exports:{}};e[n][0].call(c.exports,function(t){var i=e[n][1][t];return o(i?i:t)},c,c.exports,t,e,i,s)}return i[n].exports}for(var a="function"==typeof require&&require,n=0;n<s.length;n++)o(s[n]);return o}({1:[function(t,e,i){function s(t){var e,i,s,o=t[0]/255,a=t[1]/255,n=t[2]/255,r=Math.min(o,a,n),h=Math.max(o,a,n),l=h-r;return h==r?e=0:o==h?e=(a-n)/l:a==h?e=2+(n-o)/l:n==h&&(e=4+(o-a)/l),e=Math.min(60*e,360),0>e&&(e+=360),s=(r+h)/2,i=h==r?0:.5>=s?l/(h+r):l/(2-h-r),[e,100*i,100*s]}function o(t){var e,i,s,o=t[0],a=t[1],n=t[2],r=Math.min(o,a,n),h=Math.max(o,a,n),l=h-r;return i=0==h?0:l/h*1e3/10,h==r?e=0:o==h?e=(a-n)/l:a==h?e=2+(n-o)/l:n==h&&(e=4+(o-a)/l),e=Math.min(60*e,360),0>e&&(e+=360),s=h/255*1e3/10,[e,i,s]}function a(t){var e=t[0],i=t[1],o=t[2],a=s(t)[0],n=1/255*Math.min(e,Math.min(i,o)),o=1-1/255*Math.max(e,Math.max(i,o));return[a,100*n,100*o]}function n(t){var e,i,s,o,a=t[0]/255,n=t[1]/255,r=t[2]/255;return o=Math.min(1-a,1-n,1-r),e=(1-a-o)/(1-o)||0,i=(1-n-o)/(1-o)||0,s=(1-r-o)/(1-o)||0,[100*e,100*i,100*s,100*o]}function h(t){return X[JSON.stringify(t)]}function l(t){var e=t[0]/255,i=t[1]/255,s=t[2]/255;e=e>.04045?Math.pow((e+.055)/1.055,2.4):e/12.92,i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,s=s>.04045?Math.pow((s+.055)/1.055,2.4):s/12.92;var o=.4124*e+.3576*i+.1805*s,a=.2126*e+.7152*i+.0722*s,n=.0193*e+.1192*i+.9505*s;return[100*o,100*a,100*n]}function c(t){var e,i,s,o=l(t),a=o[0],n=o[1],r=o[2];return a/=95.047,n/=100,r/=108.883,a=a>.008856?Math.pow(a,1/3):7.787*a+16/116,n=n>.008856?Math.pow(n,1/3):7.787*n+16/116,r=r>.008856?Math.pow(r,1/3):7.787*r+16/116,e=116*n-16,i=500*(a-n),s=200*(n-r),[e,i,s]}function u(t){return V(c(t))}function d(t){var e,i,s,o,a,n=t[0]/360,r=t[1]/100,h=t[2]/100;if(0==r)return a=255*h,[a,a,a];i=.5>h?h*(1+r):h+r-h*r,e=2*h-i,o=[0,0,0];for(var l=0;3>l;l++)s=n+1/3*-(l-1),0>s&&s++,s>1&&s--,a=1>6*s?e+6*(i-e)*s:1>2*s?i:2>3*s?e+(i-e)*(2/3-s)*6:e,o[l]=255*a;return o}function f(t){var e,i,s=t[0],o=t[1]/100,a=t[2]/100;return 0===a?[0,0,0]:(a*=2,o*=1>=a?a:2-a,i=(a+o)/2,e=2*o/(a+o),[s,100*e,100*i])}function m(t){return a(d(t))}function p(t){return n(d(t))}function v(t){return h(d(t))}function x(t){var e=t[0]/60,i=t[1]/100,s=t[2]/100,o=Math.floor(e)%6,a=e-Math.floor(e),n=255*s*(1-i),r=255*s*(1-i*a),h=255*s*(1-i*(1-a)),s=255*s;switch(o){case 0:return[s,h,n];case 1:return[r,s,n];case 2:return[n,s,h];case 3:return[n,r,s];case 4:return[h,n,s];case 5:return[s,n,r]}}function y(t){var e,i,s=t[0],o=t[1]/100,a=t[2]/100;return i=(2-o)*a,e=o*a,e/=1>=i?i:2-i,e=e||0,i/=2,[s,100*e,100*i]}function k(t){return a(x(t))}function _(t){return n(x(t))}function D(t){return h(x(t))}function S(t){var e,i,s,o,a=t[0]/360,n=t[1]/100,h=t[2]/100,l=n+h;switch(l>1&&(n/=l,h/=l),e=Math.floor(6*a),i=1-h,s=6*a-e,0!=(1&e)&&(s=1-s),o=n+s*(i-n),e){default:case 6:case 0:r=i,g=o,b=n;break;case 1:r=o,g=i,b=n;break;case 2:r=n,g=i,b=o;break;case 3:r=n,g=o,b=i;break;case 4:r=o,g=n,b=i;break;case 5:r=i,g=n,b=o}return[255*r,255*g,255*b]}function w(t){return s(S(t))}function C(t){return o(S(t))}function M(t){return n(S(t))}function A(t){return h(S(t))}function T(t){var e,i,s,o=t[0]/100,a=t[1]/100,n=t[2]/100,r=t[3]/100;return e=1-Math.min(1,o*(1-r)+r),i=1-Math.min(1,a*(1-r)+r),s=1-Math.min(1,n*(1-r)+r),[255*e,255*i,255*s]}function I(t){return s(T(t))}function F(t){return o(T(t))}function P(t){return a(T(t))}function W(t){return h(T(t))}function L(t){var e,i,s,o=t[0]/100,a=t[1]/100,n=t[2]/100;return e=3.2406*o+-1.5372*a+n*-.4986,i=o*-.9689+1.8758*a+.0415*n,s=.0557*o+a*-.204+1.057*n,e=e>.0031308?1.055*Math.pow(e,1/2.4)-.055:e=12.92*e,i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i=12.92*i,s=s>.0031308?1.055*Math.pow(s,1/2.4)-.055:s=12.92*s,e=Math.min(Math.max(0,e),1),i=Math.min(Math.max(0,i),1),s=Math.min(Math.max(0,s),1),[255*e,255*i,255*s]}function R(t){var e,i,s,o=t[0],a=t[1],n=t[2];return o/=95.047,a/=100,n/=108.883,o=
|
||
|
//! moment.js
|
||
|
//! version : 2.10.6
|
||
|
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
||
|
//! license : MIT
|
||
|
//! momentjs.com
|
||
|
!function(t,s){"object"==typeof i&&"undefined"!=typeof e?e.exports=s():"function"==typeof define&&define.amd?define(s):t.moment=s()}(this,function(){"use strict";function i(){return Ri.apply(null,arguments)}function s(t){Ri=t}function o(t){return"[object Array]"===Object.prototype.toString.call(t)}function a(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function n(t,e){var i,s=[];for(i=0;i<t.length;++i)s.push(e(t[i],i));return s}function r(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function h(t,e){for(var i in e)r(e,i)&&(t[i]=e[i]);return r(e,"toString")&&(t.toString=e.toString),r(e,"valueOf")&&(t.valueOf=e.valueOf),t}function l(t,e,i,s){return It(t,e,i,s,!0).utc()}function c(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1}}function u(t){return null==t._pf&&(t._pf=c()),t._pf}function d(t){if(null==t._isValid){var e=u(t);t._isValid=!(isNaN(t._d.getTime())||!(e.overflow<0)||e.empty||e.invalidMonth||e.invalidWeekday||e.nullInput||e.invalidFormat||e.userInvalidated),t._strict&&(t._isValid=t._isValid&&0===e.charsLeftOver&&0===e.unusedTokens.length&&void 0===e.bigHour)}return t._isValid}function f(t){var e=l(NaN);return null!=t?h(u(e),t):u(e).userInvalidated=!0,e}function m(t,e){var i,s,o;if("undefined"!=typeof e._isAMomentObject&&(t._isAMomentObject=e._isAMomentObject),"undefined"!=typeof e._i&&(t._i=e._i),"undefined"!=typeof e._f&&(t._f=e._f),"undefined"!=typeof e._l&&(t._l=e._l),"undefined"!=typeof e._strict&&(t._strict=e._strict),"undefined"!=typeof e._tzm&&(t._tzm=e._tzm),"undefined"!=typeof e._isUTC&&(t._isUTC=e._isUTC),"undefined"!=typeof e._offset&&(t._offset=e._offset),"undefined"!=typeof e._pf&&(t._pf=u(e)),"undefined"!=typeof e._locale&&(t._locale=e._locale),zi.length>0)for(i in zi)s=zi[i],o=e[s],"undefined"!=typeof o&&(t[s]=o);return t}function g(t){m(this,t),this._d=new Date(null!=t._d?t._d.getTime():NaN),Vi===!1&&(Vi=!0,i.updateOffset(this),Vi=!1)}function p(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function b(t){return 0>t?Math.ceil(t):Math.floor(t)}function v(t){var e=+t,i=0;return 0!==e&&isFinite(e)&&(i=b(e)),i}function x(t,e,i){var s,o=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),n=0;for(s=0;o>s;s++)(i&&t[s]!==e[s]||!i&&v(t[s])!==v(e[s]))&&n++;return n+a}function y(){}function k(t){return t?t.toLowerCase().replace("_","-"):t}function _(t){for(var e,i,s,o,a=0;a<t.length;){for(o=k(t[a]).split("-"),e=o.length,i=k(t[a+1]),i=i?i.split("-"):null;e>0;){if(s=D(o.slice(0,e).join("-")))return s;if(i&&i.length>=e&&x(o,i,!0)>=e-1)break;e--}a++}return null}function D(i){var s=null;if(!Bi[i]&&"undefined"!=typeof e&&e&&e.exports)try{s=Oi._abbr,t("./locale/"+i),S(s)}catch(o){}return Bi[i]}function S(t,e){var i;return t&&(i="undefined"==typeof e?C(t):w(t,e),i&&(Oi=i)),Oi._abbr}function w(t,e){return null!==e?(e.abbr=t,Bi[t]=Bi[t]||new y,Bi[t].set(e),S(t),Bi[t]):(delete Bi[t],null)}function C(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Oi;if(!o(t)){if(e=D(t))return e;t=[t]}return _(t)}function M(t,e){var i=t.toLowerCase();Yi[i]=Yi[i+"s"]=Yi[e]=t}function A(t){return"string"==typeof t?Yi[t]||Yi[t.toLowerCase()]:void 0}function T(t){var e,i,s={};for(i in t)r(t,i)&&(e=A(i),e&&(s[e]=t[i]));return s}function I(t,e){return function(s){return null!=s?(P(this,t,s),i.updateOffset(this,e),this):F(this,t)}}function F(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function P(t,e,i){return t._d["set"+(t._isUTC?"UTC":"")+e](i)}function W(t,e){var i;if("object"==typeof t)for(i in t)this.set(i,t[i]);else if(t=A(t),"function"==typeof this[t])return this[t](e);return this}function L(t,e,i){var s=""+Math.abs(t),o=e-s.length,a=t>=0;return(a?i?"+":"":"-")+Math.pow(10,Math.max(0,o)).toString().substr(1)+s}function R(t,e,i,s){var o=s;"string"==typeof s&&(o=function(){return this[s]()}),t&&(Ui[t]=o),e&&(Ui[e[0]]=function(){return L(o.apply(this,arguments),e[1],e[2])}),i&&(Ui[i]=function(){return this.localeData().ordinal(o.apply(this,arguments
|
||
|
Ns.utcOffset=Nt,Ns.utc=Et,Ns.local=Ut,Ns.parseZone=jt,Ns.hasAlignedHourOffset=Gt,Ns.isDST=qt,Ns.isDSTShifted=Zt,Ns.isLocal=Qt,Ns.isUtcOffset=Jt,Ns.isUtc=Xt,Ns.isUTC=Xt,Ns.zoneAbbr=Xe,Ns.zoneName=$e,Ns.dates=it("dates accessor is deprecated. Use date instead.",Fs),Ns.months=it("months accessor is deprecated. Use month instead",$),Ns.years=it("years accessor is deprecated. Use year instead",ks),Ns.zone=it("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",Ht);var Hs=Ns,Es={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},Us={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},js="Invalid date",Gs="%d",qs=/\d{1,2}/,Zs={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},Qs=y.prototype;Qs._calendar=Es,Qs.calendar=ei,Qs._longDateFormat=Us,Qs.longDateFormat=ii,Qs._invalidDate=js,Qs.invalidDate=si,Qs._ordinal=Gs,Qs.ordinal=oi,Qs._ordinalParse=qs,Qs.preparse=ai,Qs.postformat=ai,Qs._relativeTime=Zs,Qs.relativeTime=ni,Qs.pastFuture=ri,Qs.set=hi,Qs.months=Z,Qs._months=ms,Qs.monthsShort=Q,Qs._monthsShort=gs,Qs.monthsParse=J,Qs.week=dt,Qs._week=_s,Qs.firstDayOfYear=mt,Qs.firstDayOfWeek=ft,Qs.weekdays=Be,Qs._weekdays=Ps,Qs.weekdaysMin=Ne,Qs._weekdaysMin=Ls,Qs.weekdaysShort=Ye,Qs._weekdaysShort=Ws,Qs.weekdaysParse=He,Qs.isPM=Ze,Qs._meridiemParse=Rs,Qs.meridiem=Qe,S("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10,i=1===v(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th";return t+i}}),i.lang=it("moment.lang is deprecated. Use moment.locale instead.",S),i.langData=it("moment.langData is deprecated. Use moment.localeData instead.",C);var Js=Math.abs,Xs=Ci("ms"),$s=Ci("s"),Ks=Ci("m"),to=Ci("h"),eo=Ci("d"),io=Ci("w"),so=Ci("M"),oo=Ci("y"),ao=Ai("milliseconds"),no=Ai("seconds"),ro=Ai("minutes"),ho=Ai("hours"),lo=Ai("days"),co=Ai("months"),uo=Ai("years"),fo=Math.round,mo={s:45,m:45,h:22,d:26,M:11},go=Math.abs,po=Rt.prototype;po.abs=pi,po.add=vi,po.subtract=xi,po.as=Si,po.asMilliseconds=Xs,po.asSeconds=$s,po.asMinutes=Ks,po.asHours=to,po.asDays=eo,po.asWeeks=io,po.asMonths=so,po.asYears=oo,po.valueOf=wi,po._bubble=ki,po.get=Mi,po.milliseconds=ao,po.seconds=no,po.minutes=ro,po.hours=ho,po.days=lo,po.weeks=Ti,po.months=co,po.years=uo,po.humanize=Wi,po.toISOString=Li,po.toString=Li,po.toJSON=Li,po.locale=xe,po.localeData=ye,po.toIsoString=it("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Li),po.lang=Is,R("X",0,0,"unix"),R("x",0,0,"valueOf"),N("x",es),N("X",ss),U("X",function(t,e,i){i._d=new Date(1e3*parseFloat(t,10))}),U("x",function(t,e,i){i._d=new Date(v(t))}),i.version="2.10.6",s(Ft),i.fn=Hs,i.min=Wt,i.max=Lt,i.utc=l,i.unix=Ke,i.months=ui,i.isDate=a,i.locale=S,i.invalid=f,i.duration=$t,i.isMoment=p,i.weekdays=fi,i.parseZone=ti,i.localeData=C,i.isDuration=Ot,i.monthsShort=di,i.weekdaysMin=gi,i.defineLocale=w,i.weekdaysShort=mi,i.normalizeUnits=A,i.relativeTimeThreshold=Pi;var bo=i;return bo})},{}],7:[function(t,e,i){/*!
|
||
|
* Chart.js
|
||
|
* http://chartjs.org/
|
||
|
* Version: 2.0.0-beta2
|
||
|
*
|
||
|
* Copyright 2015 Nick Downie
|
||
|
* Released under the MIT license
|
||
|
* https://github.com/nnnick/Chart.js/blob/master/LICENSE.md
|
||
|
*/
|
||
|
var s=t("./core/core.js")();t("./core/core.helpers")(s),t("./core/core.element")(s),t("./core/core.animation")(s),t("./core/core.controller")(s),t("./core/core.datasetController")(s),t("./core/core.layoutService")(s),t("./core/core.legend")(s),t("./core/core.scale")(s),t("./core/core.scaleService")(s),t("./core/core.title")(s),t("./core/core.tooltip")(s),t("./controllers/controller.bar")(s),t("./controllers/controller.bubble")(s),t("./controllers/controller.doughnut")(s),t("./controllers/controller.line")(s),t("./controllers/controller.polarArea")(s),t("./controllers/controller.radar")(s),t("./scales/scale.category")(s),t("./scales/scale.linear")(s),t("./scales/scale.logarithmic")(s),t("./scales/scale.radialLinear")(s),t("./scales/scale.time")(s),t("./elements/element.arc")(s),t("./elements/element.line")(s),t("./elements/element.point")(s),t("./elements/element.rectangle")(s),t("./charts/Chart.Bar")(s),t("./charts/Chart.Bubble")(s),t("./charts/Chart.Doughnut")(s),t("./charts/Chart.Line")(s),t("./charts/Chart.PolarArea")(s),t("./charts/Chart.Radar")(s),t("./charts/Chart.Scatter")(s),window.Chart=e.exports=s},{"./charts/Chart.Bar":8,"./charts/Chart.Bubble":9,"./charts/Chart.Doughnut":10,"./charts/Chart.Line":11,"./charts/Chart.PolarArea":12,"./charts/Chart.Radar":13,"./charts/Chart.Scatter":14,"./controllers/controller.bar":15,"./controllers/controller.bubble":16,"./controllers/controller.doughnut":17,"./controllers/controller.line":18,"./controllers/controller.polarArea":19,"./controllers/controller.radar":20,"./core/core.animation":21,"./core/core.controller":22,"./core/core.datasetController":23,"./core/core.element":24,"./core/core.helpers":25,"./core/core.js":26,"./core/core.layoutService":27,"./core/core.legend":28,"./core/core.scale":29,"./core/core.scaleService":30,"./core/core.title":31,"./core/core.tooltip":32,"./elements/element.arc":33,"./elements/element.line":34,"./elements/element.point":35,"./elements/element.rectangle":36,"./scales/scale.category":37,"./scales/scale.linear":38,"./scales/scale.logarithmic":39,"./scales/scale.radialLinear":40,"./scales/scale.time":41}],8:[function(t,e,i){"use strict";e.exports=function(t){t.Bar=function(e,i){return i.type="bar",new t(e,i)}}},{}],9:[function(t,e,i){"use strict";e.exports=function(t){t.Bubble=function(e,i){return i.type="bubble",new t(e,i)}}},{}],10:[function(t,e,i){"use strict";e.exports=function(t){t.Doughnut=function(e,i){return i.type="doughnut",new t(e,i)}}},{}],11:[function(t,e,i){"use strict";e.exports=function(t){t.Line=function(e,i){return i.type="line",new t(e,i)}}},{}],12:[function(t,e,i){"use strict";e.exports=function(t){t.PolarArea=function(e,i){return i.type="polarArea",new t(e,i)}}},{}],13:[function(t,e,i){"use strict";e.exports=function(t){var e=t.helpers,i={aspectRatio:1};t.Radar=function(s,o){return o.options=e.configMerge(i,o.options),o.type="radar",new t(s,o)}}},{}],14:[function(t,e,i){"use strict";e.exports=function(t){var e={hover:{mode:"single"},scales:{xAxes:[{type:"linear",position:"bottom",id:"x-axis-1"}],yAxes:[{type:"linear",position:"left",id:"y-axis-1"}]},tooltips:{callbacks:{title:function(t,e){return""},label:function(t,e){return"("+t.xLabel+", "+t.yLabel+")"}}}};t.defaults.scatter=e,t.controllers.scatter=t.controllers.line,t.Scatter=function(e,i){return i.type="scatter",new t(e,i)}}},{}],15:[function(t,e,i){"use strict";e.exports=function(t){var e=t.helpers;t.defaults.bar={hover:{mode:"label"},scales:{xAxes:[{type:"category",categoryPercentage:.8,barPercentage:.9,gridLines:{offsetGridLines:!0}}],yAxes:[{type:"linear"}]}},t.controllers.bar=t.DatasetController.extend({initialize:function(e,i){t.DatasetController.prototype.initialize.call(this,e,i),this.getDataset().bar=!0},getBarCount:function(){var t=0;return e.each(this.chart.data.datasets,function(i){e.isDatasetVisible(i)&&i.bar&&++t}),t},addElements:function(){this.getDataset().metaData=this.getDataset().metaData||[],e.each(this.getDataset().data,function(e,i){this.getDataset().metaData[i]=this.getDataset().metaData[i]||new t.elements.Rectangle({_chart:this.chart.chart,_da
|
||
|
_model:s?u:{x:a,y:n,innerRadius:0,outerRadius:this.chart.scale.getDistanceFromCenterForValue(this.getDataset().data[i]),startAngle:l,endAngle:c,backgroundColor:t.custom&&t.custom.backgroundColor?t.custom.backgroundColor:e.getValueAtIndexOrDefault(this.getDataset().backgroundColor,i,this.chart.options.elements.arc.backgroundColor),borderWidth:t.custom&&t.custom.borderWidth?t.custom.borderWidth:e.getValueAtIndexOrDefault(this.getDataset().borderWidth,i,this.chart.options.elements.arc.borderWidth),borderColor:t.custom&&t.custom.borderColor?t.custom.borderColor:e.getValueAtIndexOrDefault(this.getDataset().borderColor,i,this.chart.options.elements.arc.borderColor),label:e.getValueAtIndexOrDefault(this.chart.data.labels,i,this.chart.data.labels[i])}}),t.pivot()},draw:function(t){var i=t||1;e.each(this.getDataset().metaData,function(t,e){t.transition(i).draw()})},setHoverStyle:function(t){var i=this.chart.data.datasets[t._datasetIndex],s=t._index;t._model.backgroundColor=t.custom&&t.custom.hoverBackgroundColor?t.custom.hoverBackgroundColor:e.getValueAtIndexOrDefault(i.hoverBackgroundColor,s,e.color(t._model.backgroundColor).saturate(.5).darken(.1).rgbString()),t._model.borderColor=t.custom&&t.custom.hoverBorderColor?t.custom.hoverBorderColor:e.getValueAtIndexOrDefault(i.hoverBorderColor,s,e.color(t._model.borderColor).saturate(.5).darken(.1).rgbString()),t._model.borderWidth=t.custom&&t.custom.hoverBorderWidth?t.custom.hoverBorderWidth:e.getValueAtIndexOrDefault(i.hoverBorderWidth,s,t._model.borderWidth)},removeHoverStyle:function(t){var i=(this.chart.data.datasets[t._datasetIndex],t._index);t._model.backgroundColor=t.custom&&t.custom.backgroundColor?t.custom.backgroundColor:e.getValueAtIndexOrDefault(this.getDataset().backgroundColor,i,this.chart.options.elements.arc.backgroundColor),t._model.borderColor=t.custom&&t.custom.borderColor?t.custom.borderColor:e.getValueAtIndexOrDefault(this.getDataset().borderColor,i,this.chart.options.elements.arc.borderColor),t._model.borderWidth=t.custom&&t.custom.borderWidth?t.custom.borderWidth:e.getValueAtIndexOrDefault(this.getDataset().borderWidth,i,this.chart.options.elements.arc.borderWidth)},calculateCircumference:function(t){if(isNaN(t))return 0;var i=e.where(this.getDataset().data,function(t){return isNaN(t)}).length;return 2*Math.PI/(this.getDataset().data.length-i)}})}},{}],20:[function(t,e,i){"use strict";e.exports=function(t){var e=t.helpers;t.defaults.radar={scale:{type:"radialLinear"},elements:{line:{tension:0}}},t.controllers.radar=t.DatasetController.extend({linkScales:function(){},addElements:function(){this.getDataset().metaData=this.getDataset().metaData||[],this.getDataset().metaDataset=this.getDataset().metaDataset||new t.elements.Line({_chart:this.chart.chart,_datasetIndex:this.index,_points:this.getDataset().metaData,_loop:!0}),e.each(this.getDataset().data,function(e,i){this.getDataset().metaData[i]=this.getDataset().metaData[i]||new t.elements.Point({_chart:this.chart.chart,_datasetIndex:this.index,_index:i,_model:{x:0,y:0}})},this)},addElementAndReset:function(e){this.getDataset().metaData=this.getDataset().metaData||[];var i=new t.elements.Point({_chart:this.chart.chart,_datasetIndex:this.index,_index:e});this.updateElement(i,e,!0),this.getDataset().metaData.splice(e,0,i),this.updateBezierControlPoints()},update:function(t){var i,s=this.getDataset().metaDataset,o=this.getDataset().metaData,a=this.chart.scale;i=a.min<0&&a.max<0?a.getPointPositionForValue(0,a.max):a.min>0&&a.max>0?a.getPointPositionForValue(0,a.min):a.getPointPositionForValue(0,0),e.extend(this.getDataset().metaDataset,{_datasetIndex:this.index,_children:this.getDataset().metaData,_model:{tension:s.custom&&s.custom.tension?s.custom.tension:e.getValueOrDefault(this.getDataset().tension,this.chart.options.elements.line.tension),backgroundColor:s.custom&&s.custom.backgroundColor?s.custom.backgroundColor:this.getDataset().backgroundColor||this.chart.options.elements.line.backgroundColor,borderWidth:s.custom&&s.custom.borderWidth?s.custom.borderWidth:this.getDataset().borderWidth||this.chart.options.eleme
|
||
|
return void 0!==a&&(o=Math.min(o,a)),o},e.getMaximumHeight=function(t){var i=t.parentNode,s=parseInt(e.getStyle(i,"padding-top"))+parseInt(e.getStyle(i,"padding-bottom")),o=i.clientHeight-s,a=e.getConstraintHeight(t);return void 0!==a&&(o=Math.min(o,a)),o},e.getStyle=function(t,e){return t.currentStyle?t.currentStyle[e]:document.defaultView.getComputedStyle(t,null).getPropertyValue(e)},e.retinaScale=function(t){var e=t.ctx,i=t.canvas.width,s=t.canvas.height,o=t.currentDevicePixelRatio=window.devicePixelRatio||1;1!==o&&(e.canvas.height=s*o,e.canvas.width=i*o,e.scale(o,o),e.canvas.style.width=i+"px",e.canvas.style.height=s+"px",t.originalDevicePixelRatio=t.originalDevicePixelRatio||o)},e.clear=function(t){t.ctx.clearRect(0,0,t.width,t.height)},e.fontString=function(t,e,i){return e+" "+t+"px "+i},e.longestText=function(t,i,s,o){o=o||{},o.data=o.data||{},o.garbageCollect=o.garbageCollect||[],o.font!==i&&(o.data={},o.garbageCollect=[],o.font=i),t.font=i;var a=0;e.each(s,function(e){var i=o.data[e];i||(i=o.data[e]=t.measureText(e).width,o.garbageCollect.push(e)),i>a&&(a=i)});var n=o.garbageCollect.length/2;if(n>s.length)for(var r=0;n>r;r++){var h=o.garbageCollect.shift();delete o.data[h]}return a},e.drawRoundedRectangle=function(t,e,i,s,o,a){t.beginPath(),t.moveTo(e+a,i),t.lineTo(e+s-a,i),t.quadraticCurveTo(e+s,i,e+s,i+a),t.lineTo(e+s,i+o-a),t.quadraticCurveTo(e+s,i+o,e+s-a,i+o),t.lineTo(e+a,i+o),t.quadraticCurveTo(e,i+o,e,i+o-a),t.lineTo(e,i+a),t.quadraticCurveTo(e,i,e+a,i),t.closePath()},e.color=function(t){return s?s(t):(console.log("Color.js not found!"),t)},e.addResizeListener=function(t,e){var i=document.createElement("iframe"),s="chartjs-hidden-iframe";i.classlist?i.classlist.add(s):i.setAttribute("class",s),i.style.width="100%",i.style.display="block",i.style.border=0,i.style.height=0,i.style.margin=0,i.style.position="absolute",i.style.left=0,i.style.right=0,i.style.top=0,i.style.bottom=0,t.insertBefore(i,t.firstChild),(i.contentWindow||i).onresize=function(){e&&e()}},e.removeResizeListener=function(t){var e=t.querySelector(".chartjs-hidden-iframe");e&&e.parentNode.removeChild(e)},e.isArray=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===Object.prototype.toString.call(t)},e.pushAllIfDefined=function(t,i){"undefined"!=typeof t&&(e.isArray(t)?i.push.apply(i,t):i.push(t))},e.isDatasetVisible=function(t){return!t.hidden},e.callCallback=function(t,e,i){t&&"function"==typeof t.call&&t.apply(i,e)}}},{"chartjs-color":5}],26:[function(t,e,i){"use strict";e.exports=function(){var t=function(e,i){this.config=i,e.length&&e[0].getContext&&(e=e[0]),e.getContext&&(e=e.getContext("2d")),this.ctx=e,this.canvas=e.canvas,this.width=e.canvas.width||parseInt(t.helpers.getStyle(e.canvas,"width"))||t.helpers.getMaximumWidth(e.canvas),this.height=e.canvas.height||parseInt(t.helpers.getStyle(e.canvas,"height"))||t.helpers.getMaximumHeight(e.canvas),this.aspectRatio=this.width/this.height,(isNaN(this.aspectRatio)||isFinite(this.aspectRatio)===!1)&&(this.aspectRatio=void 0!==i.aspectRatio?i.aspectRatio:2),this.originalCanvasStyleWidth=e.canvas.style.width,this.originalCanvasStyleHeight=e.canvas.style.height,t.helpers.retinaScale(this),i&&(this.controller=new t.Controller(this));var s=this;return t.helpers.addResizeListener(e.canvas.parentNode,function(){s.controller&&s.controller.config.options.responsive&&s.controller.resize()}),this.controller?this.controller:this};return t.defaults={global:{responsive:!0,responsiveAnimationDuration:0,maintainAspectRatio:!0,events:["mousemove","mouseout","click","touchstart","touchmove"],hover:{onHover:null,mode:"single",animationDuration:400},onClick:null,defaultColor:"rgba(0,0,0,0.1)",defaultFontColor:"#666",defaultFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",defaultFontSize:12,defaultFontStyle:"normal",showLines:!0,elements:{},legendCallback:function(t){var e=[];e.push('<ul class="'+t.id+'-legend">');for(var i=0;i<t.data.datasets.length;i++)e.push('<li><span style="background-color:'+t.data.datasets[i].backgroundColor+'">'),t.data.datasets[i].label&&e.push(t.data.da
|
||
|
yLabel:n?n.getLabelForIndex(o._index,o._datasetIndex):"",index:s._index,datasetIndex:e})}}}),i.each(this._active,function(t){t&&o.push({borderColor:t._view.borderColor,backgroundColor:t._view.backgroundColor})}),e=this.getAveragePosition(this._active),e.y=this._active[0]._yScale.getPixelForDecimal(.5);i.extend(this._model,{title:this.getTitle(a,this._data),beforeBody:this.getBeforeBody(a,this._data),body:this.getBody(a,this._data),afterBody:this.getAfterBody(a,this._data),footer:this.getFooter(a,this._data)}),i.extend(this._model,{x:Math.round(e.x),y:Math.round(e.y),caretPadding:i.getValueOrDefault(e.padding,2),labelColors:o});var r=this.getTooltipSize(this._model);this.determineAlignment(r),i.extend(this._model,this.getBackgroundPoint(this._model,r))}else this._model.opacity=0;return t&&this._options.tooltips.custom&&this._options.tooltips.custom.call(this,this._model),this},getTooltipSize:function(t){var e=this._chart.ctx,s={height:2*t.yPadding,width:0},o=t.body.length+t.beforeBody.length+t.afterBody.length;return s.height+=t.title.length*t.titleFontSize,s.height+=(t.title.length-1)*t.titleSpacing,s.height+=t.title.length?t.titleMarginBottom:0,s.height+=o*t.bodyFontSize,s.height+=o?(o-1)*t.bodySpacing:0,s.height+=t.footer.length?t.footerMarginTop:0,s.height+=t.footer.length*t.footerFontSize,s.height+=t.footer.length?(t.footer.length-1)*t.footerSpacing:0,e.font=i.fontString(t.titleFontSize,t._titleFontStyle,t._titleFontFamily),i.each(t.title,function(t){s.width=Math.max(s.width,e.measureText(t).width)}),e.font=i.fontString(t.bodyFontSize,t._bodyFontStyle,t._bodyFontFamily),i.each(t.beforeBody.concat(t.afterBody),function(t){s.width=Math.max(s.width,e.measureText(t).width)}),i.each(t.body,function(i){s.width=Math.max(s.width,e.measureText(i).width+("single"!==this._options.tooltips.mode?t.bodyFontSize+2:0))},this),e.font=i.fontString(t.footerFontSize,t._footerFontStyle,t._footerFontFamily),i.each(t.footer,function(t){s.width=Math.max(s.width,e.measureText(t).width)}),s.width+=2*t.xPadding,s},determineAlignment:function(t){this._model.xAlign=this._model.yAlign="center",this._model.y<t.height?this._model.yAlign="top":this._model.y>this._chart.height-t.height&&(this._model.yAlign="bottom");var e,i,s,o,a,n=this,r=(this._chartInstance.chartArea.left+this._chartInstance.chartArea.right)/2,h=(this._chartInstance.chartArea.top+this._chartInstance.chartArea.bottom)/2;"center"===this._model.yAlign?(e=function(t){return r>=t},i=function(t){return t>r}):(e=function(e){return e<=t.width/2},i=function(e){return e>=n._chart.width-t.width/2}),s=function(e){return e+t.width>n._chart.width},o=function(e){return e-t.width<0},a=function(t){return h>=t?"top":"bottom"},e(this._model.x)?(this._model.xAlign="left",s(this._model.x)&&(this._model.xAlign="center",this._model.yAlign=a(this._model.y))):i(this._model.x)&&(this._model.xAlign="right",o(this._model.x)&&(this._model.xAlign="center",this._model.yAlign=a(this._model.y)))},getBackgroundPoint:function(t,e){var i={x:t.x,y:t.y};return"right"===t.xAlign?i.x-=e.width:"center"===t.xAlign&&(i.x-=e.width/2),"top"===t.yAlign?i.y+=t.caretPadding+t.caretSize:"bottom"===t.yAlign?i.y-=e.height+t.caretPadding+t.caretSize:i.y-=e.height/2,"center"==t.yAlign?"left"===t.xAlign?i.x+=t.caretPadding+t.caretSize:"right"===t.xAlign&&(i.x-=t.caretPadding+t.caretSize):"left"===t.xAlign?i.x-=t.cornerRadius+t.caretPadding:"right"===t.xAlign&&(i.x+=t.cornerRadius+t.caretPadding),i},drawCaret:function(t,e,s,o){var a,n,r,h,l,c,u=this._view,d=this._chart.ctx;"center"===u.yAlign?("left"===u.xAlign?(a=t.x,n=a-u.caretSize,r=a):(a=t.x+e.width,n=a+u.caretSize,r=a),l=t.y+e.height/2,h=l-u.caretSize,c=l+u.caretSize):("left"===u.xAlign?(a=t.x+u.cornerRadius,n=a+u.caretSize,r=n+u.caretSize):"right"===u.xAlign?(a=t.x+e.width-u.cornerRadius,n=a-u.caretSize,r=n-u.caretSize):(n=t.x+e.width/2,a=n-u.caretSize,r=n+u.caretSize),"top"===u.yAlign?(h=t.y,l=h-u.caretSize,c=h):(h=t.y+e.height,l=h+u.caretSize,c=h)),d.fillStyle=i.color(u.backgroundColor).alpha(s).rgbString(),d.beginPath(),d.moveTo(a,h),d.lineTo(n,l),d.lineTo(r,c),d.closePath(),
|
||
|
this.options.time.tooltipFormat&&(i=this.parseTime(i).format(this.options.time.tooltipFormat)),i},convertTicksToLabels:function(){this.ticks=this.ticks.map(function(t,e,i){var s=t.format(this.displayFormat);return this.options.ticks.userCallback?this.options.ticks.userCallback(s,e,i):s},this)},getPixelForValue:function(t,e,i,s){var o=this.getLabelMoment(i,e),a=o.diff(this.firstTick,this.tickUnit,!0),n=a/this.tickRange;if(this.isHorizontal()){var r=this.width-(this.paddingLeft+this.paddingRight),h=(r/Math.max(this.ticks.length-1,1),r*n+this.paddingLeft);return this.left+Math.round(h)}var l=this.height-(this.paddingTop+this.paddingBottom),c=(l/Math.max(this.ticks.length-1,1),l*n+this.paddingTop);return this.top+Math.round(c)},parseTime:function(t){return"function"==typeof t.getMonth||"number"==typeof t?s(t):t.isValid&&t.isValid()?t:"string"!=typeof this.options.time.format&&this.options.time.format.call?this.options.time.format(t):s(t,this.options.time.format)}});t.scaleService.registerScaleType("time",a,o)}},{moment:6}]},{},[7]);
|