-
Notifications
You must be signed in to change notification settings - Fork 0
/
bundle.js
2 lines (2 loc) · 48.7 KB
/
bundle.js
1
2
!function(t){function e(i){if(n[i])return n[i].exports;var r=n[i]={exports:{},id:i,loaded:!1};return t[i].call(r.exports,r,r.exports,e),r.loaded=!0,r.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){function i(){o.titles(function(t,e){if(t)throw t;u.init(e,r)})}function r(t){h.render(t),s(t),a(t)}function s(t){o.byMonth(t,function(t,e){if(t)throw t;l.render(e.records)})}function a(t){o.byIssue(t,function(t,e){if(t)throw t;c.render(e.records)})}var o=n(13),u=n(11),l=n(8),c=n(5),h=n(4);i()},function(t,e,n){var i,r;!function(n,s){i=[],r=function(){return n.Chartist=s()}.apply(e,i),!(void 0!==r&&(t.exports=r))}(this,function(){var t={version:"0.9.8"};return function(t,e,n){"use strict";n.namespaces={svg:"http://www.w3.org/2000/svg",xmlns:"http://www.w3.org/2000/xmlns/",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",ct:"http://gionkunz.github.com/chartist-js/ct"},n.noop=function(t){return t},n.alphaNumerate=function(t){return String.fromCharCode(97+t%26)},n.extend=function(t){t=t||{};var e=Array.prototype.slice.call(arguments,1);return e.forEach(function(e){for(var i in e)"object"!=typeof e[i]||null===e[i]||e[i]instanceof Array?t[i]=e[i]:t[i]=n.extend({},t[i],e[i])}),t},n.replaceAll=function(t,e,n){return t.replace(new RegExp(e,"g"),n)},n.ensureUnit=function(t,e){return"number"==typeof t&&(t+=e),t},n.quantity=function(t){if("string"==typeof t){var e=/^(\d+)\s*(.*)$/g.exec(t);return{value:+e[1],unit:e[2]||void 0}}return{value:t}},n.querySelector=function(t){return t instanceof Node?t:e.querySelector(t)},n.times=function(t){return Array.apply(null,new Array(t))},n.sum=function(t,e){return t+(e?e:0)},n.mapMultiply=function(t){return function(e){return e*t}},n.mapAdd=function(t){return function(e){return e+t}},n.serialMap=function(t,e){var i=[],r=Math.max.apply(null,t.map(function(t){return t.length}));return n.times(r).forEach(function(n,r){var s=t.map(function(t){return t[r]});i[r]=e.apply(null,s)}),i},n.roundWithPrecision=function(t,e){var i=Math.pow(10,e||n.precision);return Math.round(t*i)/i},n.precision=8,n.escapingMap={"&":"&","<":"<",">":">",'"':""","'":"'"},n.serialize=function(t){return null===t||void 0===t?t:("number"==typeof t?t=""+t:"object"==typeof t&&(t=JSON.stringify({data:t})),Object.keys(n.escapingMap).reduce(function(t,e){return n.replaceAll(t,e,n.escapingMap[e])},t))},n.deserialize=function(t){if("string"!=typeof t)return t;t=Object.keys(n.escapingMap).reduce(function(t,e){return n.replaceAll(t,n.escapingMap[e],e)},t);try{t=JSON.parse(t),t=void 0!==t.data?t.data:t}catch(t){}return t},n.createSvg=function(t,e,i,r){var s;return e=e||"100%",i=i||"100%",Array.prototype.slice.call(t.querySelectorAll("svg")).filter(function(t){return t.getAttributeNS(n.namespaces.xmlns,"ct")}).forEach(function(e){t.removeChild(e)}),s=new n.Svg("svg").attr({width:e,height:i}).addClass(r).attr({style:"width: "+e+"; height: "+i+";"}),t.appendChild(s._node),s},n.normalizeData=function(t){if(t=t||{series:[],labels:[]},t.series=t.series||[],t.labels=t.labels||[],t.series.length>0&&0===t.labels.length){var e,i=n.getDataArray(t);e=i.every(function(t){return t instanceof Array})?Math.max.apply(null,i.map(function(t){return t.length})):i.length,t.labels=n.times(e).map(function(){return""})}return t},n.reverseData=function(t){t.labels.reverse(),t.series.reverse();for(var e=0;e<t.series.length;e++)"object"==typeof t.series[e]&&void 0!==t.series[e].data?t.series[e].data.reverse():t.series[e]instanceof Array&&t.series[e].reverse()},n.getDataArray=function(t,e,i){function r(t){if(!n.isFalseyButZero(t)){if((t.data||t)instanceof Array)return(t.data||t).map(r);if(t.hasOwnProperty("value"))return r(t.value);if(i){var e={};return"string"==typeof i?e[i]=n.getNumberOrUndefined(t):e.y=n.getNumberOrUndefined(t),e.x=t.hasOwnProperty("x")?n.getNumberOrUndefined(t.x):e.x,e.y=t.hasOwnProperty("y")?n.getNumberOrUndefined(t.y):e.y,e}return n.getNumberOrUndefined(t)}}return(e&&!t.reversed||!e&&t.reversed)&&(n.reverseData(t),t.reversed=!t.reversed),t.series.map(r)},n.normalizePadding=function(t,e){return e=e||0,"number"==typeof t?{top:t,right:t,bottom:t,left:t}:{top:"number"==typeof t.top?t.top:e,right:"number"==typeof t.right?t.right:e,bottom:"number"==typeof t.bottom?t.bottom:e,left:"number"==typeof t.left?t.left:e}},n.getMetaData=function(t,e){var i=t.data?t.data[e]:t[e];return i?n.serialize(i.meta):void 0},n.orderOfMagnitude=function(t){return Math.floor(Math.log(Math.abs(t))/Math.LN10)},n.projectLength=function(t,e,n){return e/n.range*t},n.getAvailableHeight=function(t,e){return Math.max((n.quantity(e.height).value||t.height())-(e.chartPadding.top+e.chartPadding.bottom)-e.axisX.offset,0)},n.getHighLow=function(t,e,i){function r(t){if(void 0!==t)if(t instanceof Array)for(var e=0;e<t.length;e++)r(t[e]);else{var n=i?+t[i]:+t;a&&n>s.high&&(s.high=n),o&&n<s.low&&(s.low=n)}}e=n.extend({},e,i?e["axis"+i.toUpperCase()]:{});var s={high:void 0===e.high?-Number.MAX_VALUE:+e.high,low:void 0===e.low?Number.MAX_VALUE:+e.low},a=void 0===e.high,o=void 0===e.low;return(a||o)&&r(t),(e.referenceValue||0===e.referenceValue)&&(s.high=Math.max(e.referenceValue,s.high),s.low=Math.min(e.referenceValue,s.low)),s.high<=s.low&&(0===s.low?s.high=1:s.low<0?s.high=0:s.high>0?s.low=0:(s.high=1,s.low=0)),s},n.isNum=function(t){return!isNaN(t)&&isFinite(t)},n.isFalseyButZero=function(t){return!t&&0!==t},n.getNumberOrUndefined=function(t){return isNaN(+t)?void 0:+t},n.getMultiValue=function(t,e){return n.isNum(t)?+t:t?t[e||"y"]||0:0},n.rho=function(t){function e(t,n){return t%n===0?n:e(n,t%n)}function n(t){return t*t+1}if(1===t)return t;var i,r=2,s=2;if(t%2===0)return 2;do r=n(r)%t,s=n(n(s))%t,i=e(Math.abs(r-s),t);while(1===i);return i},n.getBounds=function(t,e,i,r){var s,a,o,u=0,l={high:e.high,low:e.low};l.valueRange=l.high-l.low,l.oom=n.orderOfMagnitude(l.valueRange),l.step=Math.pow(10,l.oom),l.min=Math.floor(l.low/l.step)*l.step,l.max=Math.ceil(l.high/l.step)*l.step,l.range=l.max-l.min,l.numberOfSteps=Math.round(l.range/l.step);var c=n.projectLength(t,l.step,l),h=c<i,d=r?n.rho(l.range):0;if(r&&n.projectLength(t,1,l)>=i)l.step=1;else if(r&&d<l.step&&n.projectLength(t,d,l)>=i)l.step=d;else for(;;){if(h&&n.projectLength(t,l.step,l)<=i)l.step*=2;else{if(h||!(n.projectLength(t,l.step/2,l)>=i))break;if(l.step/=2,r&&l.step%1!==0){l.step*=2;break}}if(u++>1e3)throw new Error("Exceeded maximum number of iterations while optimizing scale step!")}var p=2.221e-16;for(l.step=Math.max(l.step,p),a=l.min,o=l.max;a+l.step<=l.low;)a+=l.step;for(;o-l.step>=l.high;)o-=l.step;l.min=a,l.max=o,l.range=l.max-l.min;var f=[];for(s=l.min;s<=l.max;s+=l.step){var m=n.roundWithPrecision(s);m!==f[f.length-1]&&f.push(s)}return l.values=f,l},n.polarToCartesian=function(t,e,n,i){var r=(i-90)*Math.PI/180;return{x:t+n*Math.cos(r),y:e+n*Math.sin(r)}},n.createChartRect=function(t,e,i){var r=!(!e.axisX&&!e.axisY),s=r?e.axisY.offset:0,a=r?e.axisX.offset:0,o=t.width()||n.quantity(e.width).value||0,u=t.height()||n.quantity(e.height).value||0,l=n.normalizePadding(e.chartPadding,i);o=Math.max(o,s+l.left+l.right),u=Math.max(u,a+l.top+l.bottom);var c={padding:l,width:function(){return this.x2-this.x1},height:function(){return this.y1-this.y2}};return r?("start"===e.axisX.position?(c.y2=l.top+a,c.y1=Math.max(u-l.bottom,c.y2+1)):(c.y2=l.top,c.y1=Math.max(u-l.bottom-a,c.y2+1)),"start"===e.axisY.position?(c.x1=l.left+s,c.x2=Math.max(o-l.right,c.x1+1)):(c.x1=l.left,c.x2=Math.max(o-l.right-s,c.x1+1))):(c.x1=l.left,c.x2=Math.max(o-l.right,c.x1+1),c.y2=l.top,c.y1=Math.max(u-l.bottom,c.y2+1)),c},n.createGrid=function(t,e,i,r,s,a,o,u){var l={};l[i.units.pos+"1"]=t,l[i.units.pos+"2"]=t,l[i.counterUnits.pos+"1"]=r,l[i.counterUnits.pos+"2"]=r+s;var c=a.elem("line",l,o.join(" "));u.emit("draw",n.extend({type:"grid",axis:i,index:e,group:a,element:c},l))},n.createLabel=function(t,e,i,r,s,a,o,u,l,c,h){var d,p={};if(p[s.units.pos]=t+o[s.units.pos],p[s.counterUnits.pos]=o[s.counterUnits.pos],p[s.units.len]=e,p[s.counterUnits.len]=Math.max(0,a-10),c){var f='<span class="'+l.join(" ")+'" style="'+s.units.len+": "+Math.round(p[s.units.len])+"px; "+s.counterUnits.len+": "+Math.round(p[s.counterUnits.len])+'px">'+r[i]+"</span>";d=u.foreignObject(f,n.extend({style:"overflow: visible;"},p))}else d=u.elem("text",p,l.join(" ")).text(r[i]);h.emit("draw",n.extend({type:"label",axis:s,index:i,group:u,element:d,text:r[i]},p))},n.getSeriesOption=function(t,e,n){if(t.name&&e.series&&e.series[t.name]){var i=e.series[t.name];return i.hasOwnProperty(n)?i[n]:e[n]}return e[n]},n.optionsProvider=function(e,i,r){function s(e){var s=o;if(o=n.extend({},l),i)for(u=0;u<i.length;u++){var a=t.matchMedia(i[u][0]);a.matches&&(o=n.extend(o,i[u][1]))}r&&e&&r.emit("optionsChanged",{previousOptions:s,currentOptions:o})}function a(){c.forEach(function(t){t.removeListener(s)})}var o,u,l=n.extend({},e),c=[];if(!t.matchMedia)throw"window.matchMedia not found! Make sure you're using a polyfill.";if(i)for(u=0;u<i.length;u++){var h=t.matchMedia(i[u][0]);h.addListener(s),c.push(h)}return s(),{removeMediaQueryListeners:a,getCurrentOptions:function(){return n.extend({},o)}}},n.splitIntoSegments=function(t,e,i){var r={increasingX:!1,fillHoles:!1};i=n.extend({},r,i);for(var s=[],a=!0,o=0;o<t.length;o+=2)void 0===e[o/2].value?i.fillHoles||(a=!0):(i.increasingX&&o>=2&&t[o]<=t[o-2]&&(a=!0),a&&(s.push({pathCoordinates:[],valueData:[]}),a=!1),s[s.length-1].pathCoordinates.push(t[o],t[o+1]),s[s.length-1].valueData.push(e[o/2]));return s}}(window,document,t),function(t,e,n){"use strict";n.Interpolation={},n.Interpolation.none=function(t){var e={fillHoles:!1};return t=n.extend({},e,t),function(e,i){for(var r=new n.Svg.Path,s=!0,a=0;a<e.length;a+=2){var o=e[a],u=e[a+1],l=i[a/2];void 0!==l.value?(s?r.move(o,u,!1,l):r.line(o,u,!1,l),s=!1):t.fillHoles||(s=!0)}return r}},n.Interpolation.simple=function(t){var e={divisor:2,fillHoles:!1};t=n.extend({},e,t);var i=1/Math.max(1,t.divisor);return function(e,r){for(var s,a,o,u=new n.Svg.Path,l=0;l<e.length;l+=2){var c=e[l],h=e[l+1],d=(c-s)*i,p=r[l/2];void 0!==p.value?(void 0===o?u.move(c,h,!1,p):u.curve(s+d,a,c-d,h,c,h,!1,p),s=c,a=h,o=p):t.fillHoles||(s=c=o=void 0)}return u}},n.Interpolation.cardinal=function(t){var e={tension:1,fillHoles:!1};t=n.extend({},e,t);var i=Math.min(1,Math.max(0,t.tension)),r=1-i;return function e(s,a){var o=n.splitIntoSegments(s,a,{fillHoles:t.fillHoles});if(o.length){if(o.length>1){var u=[];return o.forEach(function(t){u.push(e(t.pathCoordinates,t.valueData))}),n.Svg.Path.join(u)}if(s=o[0].pathCoordinates,a=o[0].valueData,s.length<=4)return n.Interpolation.none()(s,a);for(var l,c=(new n.Svg.Path).move(s[0],s[1],!1,a[0]),h=0,d=s.length;d-2*!l>h;h+=2){var p=[{x:+s[h-2],y:+s[h-1]},{x:+s[h],y:+s[h+1]},{x:+s[h+2],y:+s[h+3]},{x:+s[h+4],y:+s[h+5]}];l?h?d-4===h?p[3]={x:+s[0],y:+s[1]}:d-2===h&&(p[2]={x:+s[0],y:+s[1]},p[3]={x:+s[2],y:+s[3]}):p[0]={x:+s[d-2],y:+s[d-1]}:d-4===h?p[3]=p[2]:h||(p[0]={x:+s[h],y:+s[h+1]}),c.curve(i*(-p[0].x+6*p[1].x+p[2].x)/6+r*p[2].x,i*(-p[0].y+6*p[1].y+p[2].y)/6+r*p[2].y,i*(p[1].x+6*p[2].x-p[3].x)/6+r*p[2].x,i*(p[1].y+6*p[2].y-p[3].y)/6+r*p[2].y,p[2].x,p[2].y,!1,a[(h+2)/2])}return c}return n.Interpolation.none()([])}},n.Interpolation.monotoneCubic=function(t){var e={fillHoles:!1};return t=n.extend({},e,t),function e(i,r){var s=n.splitIntoSegments(i,r,{fillHoles:t.fillHoles,increasingX:!0});if(s.length){if(s.length>1){var a=[];return s.forEach(function(t){a.push(e(t.pathCoordinates,t.valueData))}),n.Svg.Path.join(a)}if(i=s[0].pathCoordinates,r=s[0].valueData,i.length<=4)return n.Interpolation.none()(i,r);var o,u,l=[],c=[],h=i.length/2,d=[],p=[],f=[],m=[];for(o=0;o<h;o++)l[o]=i[2*o],c[o]=i[2*o+1];for(o=0;o<h-1;o++)f[o]=c[o+1]-c[o],m[o]=l[o+1]-l[o],p[o]=f[o]/m[o];for(d[0]=p[0],d[h-1]=p[h-2],o=1;o<h-1;o++)0===p[o]||0===p[o-1]||p[o-1]>0!=p[o]>0?d[o]=0:(d[o]=3*(m[o-1]+m[o])/((2*m[o]+m[o-1])/p[o-1]+(m[o]+2*m[o-1])/p[o]),isFinite(d[o])||(d[o]=0));for(u=(new n.Svg.Path).move(l[0],c[0],!1,r[0]),o=0;o<h-1;o++)u.curve(l[o]+m[o]/3,c[o]+d[o]*m[o]/3,l[o+1]-m[o]/3,c[o+1]-d[o+1]*m[o]/3,l[o+1],c[o+1],!1,r[o+1]);return u}return n.Interpolation.none()([])}},n.Interpolation.step=function(t){var e={postpone:!0,fillHoles:!1};return t=n.extend({},e,t),function(e,i){for(var r,s,a,o=new n.Svg.Path,u=0;u<e.length;u+=2){var l=e[u],c=e[u+1],h=i[u/2];void 0!==h.value?(void 0===a?o.move(l,c,!1,h):(t.postpone?o.line(l,s,!1,a):o.line(r,c,!1,h),o.line(l,c,!1,h)),r=l,s=c,a=h):t.fillHoles||(r=s=a=void 0)}return o}}}(window,document,t),function(t,e,n){"use strict";n.EventEmitter=function(){function t(t,e){i[t]=i[t]||[],i[t].push(e)}function e(t,e){i[t]&&(e?(i[t].splice(i[t].indexOf(e),1),0===i[t].length&&delete i[t]):delete i[t])}function n(t,e){i[t]&&i[t].forEach(function(t){t(e)}),i["*"]&&i["*"].forEach(function(n){n(t,e)})}var i=[];return{addEventHandler:t,removeEventHandler:e,emit:n}}}(window,document,t),function(t,e,n){"use strict";function i(t){var e=[];if(t.length)for(var n=0;n<t.length;n++)e.push(t[n]);return e}function r(t,e){var i=e||this.prototype||n.Class,r=Object.create(i);n.Class.cloneDefinitions(r,t);var s=function(){var t,e=r.constructor||function(){};return t=this===n?Object.create(r):this,e.apply(t,Array.prototype.slice.call(arguments,0)),t};return s.prototype=r,s.super=i,s.extend=this.extend,s}function s(){var t=i(arguments),e=t[0];return t.splice(1,t.length-1).forEach(function(t){Object.getOwnPropertyNames(t).forEach(function(n){delete e[n],Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))})}),e}n.Class={extend:r,cloneDefinitions:s}}(window,document,t),function(t,e,n){"use strict";function i(t,e,i){return t&&(this.data=t,this.eventEmitter.emit("data",{type:"update",data:this.data})),e&&(this.options=n.extend({},i?this.options:this.defaultOptions,e),this.initializeTimeoutId||(this.optionsProvider.removeMediaQueryListeners(),this.optionsProvider=n.optionsProvider(this.options,this.responsiveOptions,this.eventEmitter))),this.initializeTimeoutId||this.createChart(this.optionsProvider.getCurrentOptions()),this}function r(){return this.initializeTimeoutId?t.clearTimeout(this.initializeTimeoutId):(t.removeEventListener("resize",this.resizeListener),this.optionsProvider.removeMediaQueryListeners()),this}function s(t,e){return this.eventEmitter.addEventHandler(t,e),this}function a(t,e){return this.eventEmitter.removeEventHandler(t,e),this}function o(){t.addEventListener("resize",this.resizeListener),this.optionsProvider=n.optionsProvider(this.options,this.responsiveOptions,this.eventEmitter),this.eventEmitter.addEventHandler("optionsChanged",function(){this.update()}.bind(this)),this.options.plugins&&this.options.plugins.forEach(function(t){t instanceof Array?t[0](this,t[1]):t(this)}.bind(this)),this.eventEmitter.emit("data",{type:"initial",data:this.data}),this.createChart(this.optionsProvider.getCurrentOptions()),this.initializeTimeoutId=void 0}function u(t,e,i,r,s){this.container=n.querySelector(t),this.data=e,this.defaultOptions=i,this.options=r,this.responsiveOptions=s,this.eventEmitter=n.EventEmitter(),this.supportsForeignObject=n.Svg.isSupported("Extensibility"),this.supportsAnimations=n.Svg.isSupported("AnimationEventsAttribute"),this.resizeListener=function(){this.update()}.bind(this),this.container&&(this.container.__chartist__&&this.container.__chartist__.detach(),this.container.__chartist__=this),this.initializeTimeoutId=setTimeout(o.bind(this),0)}n.Base=n.Class.extend({constructor:u,optionsProvider:void 0,container:void 0,svg:void 0,eventEmitter:void 0,createChart:function(){throw new Error("Base chart type can't be instantiated!")},update:i,detach:r,on:s,off:a,version:n.version,supportsForeignObject:!1})}(window,document,t),function(t,e,n){"use strict";function i(t,i,r,s,a){t instanceof Element?this._node=t:(this._node=e.createElementNS(n.namespaces.svg,t),"svg"===t&&this.attr({"xmlns:ct":n.namespaces.ct})),i&&this.attr(i),r&&this.addClass(r),s&&(a&&s._node.firstChild?s._node.insertBefore(this._node,s._node.firstChild):s._node.appendChild(this._node))}function r(t,e){return"string"==typeof t?e?this._node.getAttributeNS(e,t):this._node.getAttribute(t):(Object.keys(t).forEach(function(e){if(void 0!==t[e])if(e.indexOf(":")!==-1){var i=e.split(":");this._node.setAttributeNS(n.namespaces[i[0]],e,t[e])}else this._node.setAttribute(e,t[e])}.bind(this)),this)}function s(t,e,i,r){return new n.Svg(t,e,i,this,r)}function a(){return this._node.parentNode instanceof SVGElement?new n.Svg(this._node.parentNode):null}function o(){for(var t=this._node;"svg"!==t.nodeName;)t=t.parentNode;return new n.Svg(t)}function u(t){var e=this._node.querySelector(t);return e?new n.Svg(e):null}function l(t){var e=this._node.querySelectorAll(t);return e.length?new n.Svg.List(e):null}function c(t,i,r,s){if("string"==typeof t){var a=e.createElement("div");a.innerHTML=t,t=a.firstChild}t.setAttribute("xmlns",n.namespaces.xmlns);var o=this.elem("foreignObject",i,r,s);return o._node.appendChild(t),o}function h(t){return this._node.appendChild(e.createTextNode(t)),this}function d(){for(;this._node.firstChild;)this._node.removeChild(this._node.firstChild);return this}function p(){return this._node.parentNode.removeChild(this._node),this.parent()}function f(t){return this._node.parentNode.replaceChild(t._node,this._node),t}function m(t,e){return e&&this._node.firstChild?this._node.insertBefore(t._node,this._node.firstChild):this._node.appendChild(t._node),this}function v(){return this._node.getAttribute("class")?this._node.getAttribute("class").trim().split(/\s+/):[]}function g(t){return this._node.setAttribute("class",this.classes(this._node).concat(t.trim().split(/\s+/)).filter(function(t,e,n){return n.indexOf(t)===e}).join(" ")),this}function x(t){var e=t.trim().split(/\s+/);return this._node.setAttribute("class",this.classes(this._node).filter(function(t){return e.indexOf(t)===-1}).join(" ")),this}function y(){return this._node.setAttribute("class",""),this}function b(){return this._node.getBoundingClientRect().height}function w(){return this._node.getBoundingClientRect().width}function E(t,e,i){return void 0===e&&(e=!0),Object.keys(t).forEach(function(r){function s(t,e){var s,a,o,u={};t.easing&&(o=t.easing instanceof Array?t.easing:n.Svg.Easing[t.easing],delete t.easing),t.begin=n.ensureUnit(t.begin,"ms"),t.dur=n.ensureUnit(t.dur,"ms"),o&&(t.calcMode="spline",t.keySplines=o.join(" "),t.keyTimes="0;1"),e&&(t.fill="freeze",u[r]=t.from,this.attr(u),a=n.quantity(t.begin||0).value,t.begin="indefinite"),s=this.elem("animate",n.extend({attributeName:r},t)),e&&setTimeout(function(){try{s._node.beginElement()}catch(e){u[r]=t.to,this.attr(u),s.remove()}}.bind(this),a),i&&s._node.addEventListener("beginEvent",function(){i.emit("animationBegin",{element:this,animate:s._node,params:t})}.bind(this)),s._node.addEventListener("endEvent",function(){i&&i.emit("animationEnd",{element:this,animate:s._node,params:t}),e&&(u[r]=t.to,this.attr(u),s.remove())}.bind(this))}t[r]instanceof Array?t[r].forEach(function(t){s.bind(this)(t,!1)}.bind(this)):s.bind(this)(t[r],e)}.bind(this)),this}function A(t){var e=this;this.svgElements=[];for(var i=0;i<t.length;i++)this.svgElements.push(new n.Svg(t[i]));Object.keys(n.Svg.prototype).filter(function(t){return["constructor","parent","querySelector","querySelectorAll","replace","append","classes","height","width"].indexOf(t)===-1}).forEach(function(t){e[t]=function(){var i=Array.prototype.slice.call(arguments,0);return e.svgElements.forEach(function(e){n.Svg.prototype[t].apply(e,i)}),e}})}n.Svg=n.Class.extend({constructor:i,attr:r,elem:s,parent:a,root:o,querySelector:u,querySelectorAll:l,foreignObject:c,text:h,empty:d,remove:p,replace:f,append:m,classes:v,addClass:g,removeClass:x,removeAllClasses:y,height:b,width:w,animate:E}),n.Svg.isSupported=function(t){return e.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#"+t,"1.1")};var S={easeInSine:[.47,0,.745,.715],easeOutSine:[.39,.575,.565,1],easeInOutSine:[.445,.05,.55,.95],easeInQuad:[.55,.085,.68,.53],easeOutQuad:[.25,.46,.45,.94],easeInOutQuad:[.455,.03,.515,.955],easeInCubic:[.55,.055,.675,.19],easeOutCubic:[.215,.61,.355,1],easeInOutCubic:[.645,.045,.355,1],easeInQuart:[.895,.03,.685,.22],easeOutQuart:[.165,.84,.44,1],easeInOutQuart:[.77,0,.175,1],easeInQuint:[.755,.05,.855,.06],easeOutQuint:[.23,1,.32,1],easeInOutQuint:[.86,0,.07,1],easeInExpo:[.95,.05,.795,.035],easeOutExpo:[.19,1,.22,1],easeInOutExpo:[1,0,0,1],easeInCirc:[.6,.04,.98,.335],easeOutCirc:[.075,.82,.165,1],easeInOutCirc:[.785,.135,.15,.86],easeInBack:[.6,-.28,.735,.045],easeOutBack:[.175,.885,.32,1.275],easeInOutBack:[.68,-.55,.265,1.55]};n.Svg.Easing=S,n.Svg.List=n.Class.extend({constructor:A})}(window,document,t),function(t,e,n){"use strict";function i(t,e,i,r,s,a){var o=n.extend({command:s?t.toLowerCase():t.toUpperCase()},e,a?{data:a}:{});i.splice(r,0,o)}function r(t,e){t.forEach(function(n,i){b[n.command.toLowerCase()].forEach(function(r,s){e(n,r,i,s,t)})})}function s(t,e){this.pathElements=[],this.pos=0,this.close=t,this.options=n.extend({},w,e)}function a(t){return void 0!==t?(this.pos=Math.max(0,Math.min(this.pathElements.length,t)),this):this.pos}function o(t){return this.pathElements.splice(this.pos,t),this}function u(t,e,n,r){return i("M",{x:+t,y:+e},this.pathElements,this.pos++,n,r),this}function l(t,e,n,r){return i("L",{x:+t,y:+e},this.pathElements,this.pos++,n,r),this}function c(t,e,n,r,s,a,o,u){return i("C",{x1:+t,y1:+e,x2:+n,y2:+r,x:+s,y:+a},this.pathElements,this.pos++,o,u),this}function h(t,e,n,r,s,a,o,u,l){return i("A",{rx:+t,ry:+e,xAr:+n,lAf:+r,sf:+s,x:+a,y:+o},this.pathElements,this.pos++,u,l),this}function d(t){var e=t.replace(/([A-Za-z])([0-9])/g,"$1 $2").replace(/([0-9])([A-Za-z])/g,"$1 $2").split(/[\s,]+/).reduce(function(t,e){return e.match(/[A-Za-z]/)&&t.push([]),t[t.length-1].push(e),t},[]);"Z"===e[e.length-1][0].toUpperCase()&&e.pop();var i=e.map(function(t){var e=t.shift(),i=b[e.toLowerCase()];return n.extend({command:e},i.reduce(function(e,n,i){return e[n]=+t[i],e},{}))}),r=[this.pos,0];return Array.prototype.push.apply(r,i),Array.prototype.splice.apply(this.pathElements,r),this.pos+=i.length,this}function p(){var t=Math.pow(10,this.options.accuracy);return this.pathElements.reduce(function(e,n){var i=b[n.command.toLowerCase()].map(function(e){return this.options.accuracy?Math.round(n[e]*t)/t:n[e]}.bind(this));return e+n.command+i.join(",")}.bind(this),"")+(this.close?"Z":"")}function f(t,e){return r(this.pathElements,function(n,i){n[i]*="x"===i[0]?t:e}),this}function m(t,e){return r(this.pathElements,function(n,i){n[i]+="x"===i[0]?t:e}),this}function v(t){return r(this.pathElements,function(e,n,i,r,s){var a=t(e,n,i,r,s);(a||0===a)&&(e[n]=a)}),this}function g(t){var e=new n.Svg.Path(t||this.close);return e.pos=this.pos,e.pathElements=this.pathElements.slice().map(function(t){return n.extend({},t)}),e.options=n.extend({},this.options),e}function x(t){var e=[new n.Svg.Path];return this.pathElements.forEach(function(i){i.command===t.toUpperCase()&&0!==e[e.length-1].pathElements.length&&e.push(new n.Svg.Path),e[e.length-1].pathElements.push(i)}),e}function y(t,e,i){for(var r=new n.Svg.Path(e,i),s=0;s<t.length;s++)for(var a=t[s],o=0;o<a.pathElements.length;o++)r.pathElements.push(a.pathElements[o]);return r}var b={m:["x","y"],l:["x","y"],c:["x1","y1","x2","y2","x","y"],a:["rx","ry","xAr","lAf","sf","x","y"]},w={accuracy:3};n.Svg.Path=n.Class.extend({constructor:s,position:a,remove:o,move:u,line:l,curve:c,arc:h,scale:f,translate:m,transform:v,parse:d,stringify:p,clone:g,splitByCommand:x}),n.Svg.Path.elementDescriptions=b,n.Svg.Path.join=y}(window,document,t),function(t,e,n){"use strict";function i(t,e,n,i){this.units=t,this.counterUnits=t===s.x?s.y:s.x,this.chartRect=e,this.axisLength=e[t.rectEnd]-e[t.rectStart],this.gridOffset=e[t.rectOffset],this.ticks=n,this.options=i}function r(t,e,i,r,s){var a=r["axis"+this.units.pos.toUpperCase()],o=this.ticks.map(this.projectValue.bind(this)),u=this.ticks.map(a.labelInterpolationFnc);o.forEach(function(l,c){var h,d={x:0,y:0};h=o[c+1]?o[c+1]-l:Math.max(this.axisLength-l,30),n.isFalseyButZero(u[c])&&""!==u[c]||("x"===this.units.pos?(l=this.chartRect.x1+l,d.x=r.axisX.labelOffset.x,"start"===r.axisX.position?d.y=this.chartRect.padding.top+r.axisX.labelOffset.y+(i?5:20):d.y=this.chartRect.y1+r.axisX.labelOffset.y+(i?5:20)):(l=this.chartRect.y1-l,d.y=r.axisY.labelOffset.y-(i?h:0),"start"===r.axisY.position?d.x=i?this.chartRect.padding.left+r.axisY.labelOffset.x:this.chartRect.x1-10:d.x=this.chartRect.x2+r.axisY.labelOffset.x+10),a.showGrid&&n.createGrid(l,c,this,this.gridOffset,this.chartRect[this.counterUnits.len](),t,[r.classNames.grid,r.classNames[this.units.dir]],s),a.showLabel&&n.createLabel(l,h,c,u,this,a.offset,d,e,[r.classNames.label,r.classNames[this.units.dir],r.classNames[a.position]],i,s))}.bind(this))}var s={x:{pos:"x",len:"width",dir:"horizontal",rectStart:"x1",rectEnd:"x2",rectOffset:"y2"},y:{pos:"y",len:"height",dir:"vertical",rectStart:"y2",rectEnd:"y1",rectOffset:"x1"}};n.Axis=n.Class.extend({constructor:i,createGridAndLabels:r,projectValue:function(t,e,n){throw new Error("Base axis can't be instantiated!")}}),n.Axis.units=s}(window,document,t),function(t,e,n){"use strict";function i(t,e,i,r){var s=r.highLow||n.getHighLow(e.normalized,r,t.pos);this.bounds=n.getBounds(i[t.rectEnd]-i[t.rectStart],s,r.scaleMinSpace||20,r.onlyInteger),this.range={min:this.bounds.min,max:this.bounds.max},n.AutoScaleAxis.super.constructor.call(this,t,i,this.bounds.values,r)}function r(t){return this.axisLength*(+n.getMultiValue(t,this.units.pos)-this.bounds.min)/this.bounds.range}n.AutoScaleAxis=n.Axis.extend({constructor:i,projectValue:r})}(window,document,t),function(t,e,n){"use strict";function i(t,e,i,r){var s=r.highLow||n.getHighLow(e.normalized,r,t.pos);this.divisor=r.divisor||1,this.ticks=r.ticks||n.times(this.divisor).map(function(t,e){return s.low+(s.high-s.low)/this.divisor*e}.bind(this)),this.ticks.sort(function(t,e){return t-e}),this.range={min:s.low,max:s.high},n.FixedScaleAxis.super.constructor.call(this,t,i,this.ticks,r),this.stepLength=this.axisLength/this.divisor}function r(t){return this.axisLength*(+n.getMultiValue(t,this.units.pos)-this.range.min)/(this.range.max-this.range.min)}n.FixedScaleAxis=n.Axis.extend({constructor:i,projectValue:r})}(window,document,t),function(t,e,n){"use strict";function i(t,e,i,r){n.StepAxis.super.constructor.call(this,t,i,r.ticks,r),this.stepLength=this.axisLength/(r.ticks.length-(r.stretch?1:0))}function r(t,e){return this.stepLength*e}n.StepAxis=n.Axis.extend({constructor:i,projectValue:r})}(window,document,t),function(t,e,n){"use strict";function i(t){this.data=n.normalizeData(this.data);var e={raw:this.data,normalized:n.getDataArray(this.data,t.reverseData,!0)};this.svg=n.createSvg(this.container,t.width,t.height,t.classNames.chart);var i,r,a=this.svg.elem("g").addClass(t.classNames.gridGroup),o=this.svg.elem("g"),u=this.svg.elem("g").addClass(t.classNames.labelGroup),l=n.createChartRect(this.svg,t,s.padding);i=void 0===t.axisX.type?new n.StepAxis(n.Axis.units.x,e,l,n.extend({},t.axisX,{ticks:e.raw.labels,stretch:t.fullWidth})):t.axisX.type.call(n,n.Axis.units.x,e,l,t.axisX),r=void 0===t.axisY.type?new n.AutoScaleAxis(n.Axis.units.y,e,l,n.extend({},t.axisY,{high:n.isNum(t.high)?t.high:t.axisY.high,low:n.isNum(t.low)?t.low:t.axisY.low})):t.axisY.type.call(n,n.Axis.units.y,e,l,t.axisY),i.createGridAndLabels(a,u,this.supportsForeignObject,t,this.eventEmitter),r.createGridAndLabels(a,u,this.supportsForeignObject,t,this.eventEmitter),e.raw.series.forEach(function(s,a){var u=o.elem("g");u.attr({"ct:series-name":s.name,"ct:meta":n.serialize(s.meta)}),u.addClass([t.classNames.series,s.className||t.classNames.series+"-"+n.alphaNumerate(a)].join(" "));var c=[],h=[];e.normalized[a].forEach(function(t,o){var u={x:l.x1+i.projectValue(t,o,e.normalized[a]),y:l.y1-r.projectValue(t,o,e.normalized[a])};c.push(u.x,u.y),h.push({value:t,valueIndex:o,meta:n.getMetaData(s,o)})}.bind(this));var d={lineSmooth:n.getSeriesOption(s,t,"lineSmooth"),showPoint:n.getSeriesOption(s,t,"showPoint"),showLine:n.getSeriesOption(s,t,"showLine"),showArea:n.getSeriesOption(s,t,"showArea"),areaBase:n.getSeriesOption(s,t,"areaBase")},p="function"==typeof d.lineSmooth?d.lineSmooth:d.lineSmooth?n.Interpolation.monotoneCubic():n.Interpolation.none(),f=p(c,h);if(d.showPoint&&f.pathElements.forEach(function(e){var o=u.elem("line",{x1:e.x,y1:e.y,x2:e.x+.01,y2:e.y},t.classNames.point).attr({"ct:value":[e.data.value.x,e.data.value.y].filter(n.isNum).join(","),"ct:meta":e.data.meta});this.eventEmitter.emit("draw",{type:"point",value:e.data.value,index:e.data.valueIndex,meta:e.data.meta,series:s,seriesIndex:a,axisX:i,axisY:r,group:u,element:o,x:e.x,y:e.y})}.bind(this)),d.showLine){var m=u.elem("path",{d:f.stringify()},t.classNames.line,!0);this.eventEmitter.emit("draw",{type:"line",values:e.normalized[a],path:f.clone(),chartRect:l,index:a,series:s,seriesIndex:a,axisX:i,axisY:r,group:u,element:m})}if(d.showArea&&r.range){var v=Math.max(Math.min(d.areaBase,r.range.max),r.range.min),g=l.y1-r.projectValue(v);f.splitByCommand("M").filter(function(t){return t.pathElements.length>1}).map(function(t){var e=t.pathElements[0],n=t.pathElements[t.pathElements.length-1];return t.clone(!0).position(0).remove(1).move(e.x,g).line(e.x,e.y).position(t.pathElements.length+1).line(n.x,g)}).forEach(function(n){var o=u.elem("path",{d:n.stringify()},t.classNames.area,!0);this.eventEmitter.emit("draw",{type:"area",values:e.normalized[a],path:n.clone(),series:s,seriesIndex:a,axisX:i,axisY:r,chartRect:l,index:a,group:u,element:o})}.bind(this))}}.bind(this)),this.eventEmitter.emit("created",{bounds:r.bounds,chartRect:l,axisX:i,axisY:r,svg:this.svg,options:t})}function r(t,e,i,r){n.Line.super.constructor.call(this,t,e,s,n.extend({},s,i),r)}var s={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:n.noop,type:void 0},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:n.noop,type:void 0,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,showLine:!0,showPoint:!0,showArea:!1,areaBase:0,lineSmooth:!0,low:void 0,high:void 0,chartPadding:{top:15,right:15,bottom:5,left:10},fullWidth:!1,reverseData:!1,classNames:{chart:"ct-chart-line",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",line:"ct-line",point:"ct-point",area:"ct-area",grid:"ct-grid",gridGroup:"ct-grids",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};n.Line=n.Base.extend({constructor:r,createChart:i})}(window,document,t),function(t,e,n){"use strict";function i(t){this.data=n.normalizeData(this.data);var e,i={raw:this.data,normalized:t.distributeSeries?n.getDataArray(this.data,t.reverseData,t.horizontalBars?"x":"y").map(function(t){return[t]}):n.getDataArray(this.data,t.reverseData,t.horizontalBars?"x":"y")};this.svg=n.createSvg(this.container,t.width,t.height,t.classNames.chart+(t.horizontalBars?" "+t.classNames.horizontalBars:""));var r=this.svg.elem("g").addClass(t.classNames.gridGroup),a=this.svg.elem("g"),o=this.svg.elem("g").addClass(t.classNames.labelGroup);if(t.stackBars&&0!==i.normalized.length){var u=n.serialMap(i.normalized,function(){return Array.prototype.slice.call(arguments).map(function(t){return t}).reduce(function(t,e){return{x:t.x+(e&&e.x)||0,y:t.y+(e&&e.y)||0}},{x:0,y:0})});e=n.getHighLow([u],n.extend({},t,{referenceValue:0}),t.horizontalBars?"x":"y")}else e=n.getHighLow(i.normalized,n.extend({},t,{referenceValue:0}),t.horizontalBars?"x":"y");e.high=+t.high||(0===t.high?0:e.high),e.low=+t.low||(0===t.low?0:e.low);var l,c,h,d,p,f=n.createChartRect(this.svg,t,s.padding);c=t.distributeSeries&&t.stackBars?i.raw.labels.slice(0,1):i.raw.labels,t.horizontalBars?(l=d=void 0===t.axisX.type?new n.AutoScaleAxis(n.Axis.units.x,i,f,n.extend({},t.axisX,{highLow:e,referenceValue:0})):t.axisX.type.call(n,n.Axis.units.x,i,f,n.extend({},t.axisX,{highLow:e,referenceValue:0})),h=p=void 0===t.axisY.type?new n.StepAxis(n.Axis.units.y,i,f,{
ticks:c}):t.axisY.type.call(n,n.Axis.units.y,i,f,t.axisY)):(h=d=void 0===t.axisX.type?new n.StepAxis(n.Axis.units.x,i,f,{ticks:c}):t.axisX.type.call(n,n.Axis.units.x,i,f,t.axisX),l=p=void 0===t.axisY.type?new n.AutoScaleAxis(n.Axis.units.y,i,f,n.extend({},t.axisY,{highLow:e,referenceValue:0})):t.axisY.type.call(n,n.Axis.units.y,i,f,n.extend({},t.axisY,{highLow:e,referenceValue:0})));var m=t.horizontalBars?f.x1+l.projectValue(0):f.y1-l.projectValue(0),v=[];h.createGridAndLabels(r,o,this.supportsForeignObject,t,this.eventEmitter),l.createGridAndLabels(r,o,this.supportsForeignObject,t,this.eventEmitter),i.raw.series.forEach(function(e,r){var s,o,u=r-(i.raw.series.length-1)/2;s=t.distributeSeries&&!t.stackBars?h.axisLength/i.normalized.length/2:t.distributeSeries&&t.stackBars?h.axisLength/2:h.axisLength/i.normalized[r].length/2,o=a.elem("g"),o.attr({"ct:series-name":e.name,"ct:meta":n.serialize(e.meta)}),o.addClass([t.classNames.series,e.className||t.classNames.series+"-"+n.alphaNumerate(r)].join(" ")),i.normalized[r].forEach(function(a,c){var g,x,y,b;if(b=t.distributeSeries&&!t.stackBars?r:t.distributeSeries&&t.stackBars?0:c,g=t.horizontalBars?{x:f.x1+l.projectValue(a&&a.x?a.x:0,c,i.normalized[r]),y:f.y1-h.projectValue(a&&a.y?a.y:0,b,i.normalized[r])}:{x:f.x1+h.projectValue(a&&a.x?a.x:0,b,i.normalized[r]),y:f.y1-l.projectValue(a&&a.y?a.y:0,c,i.normalized[r])},h instanceof n.StepAxis&&(h.options.stretch||(g[h.units.pos]+=s*(t.horizontalBars?-1:1)),g[h.units.pos]+=t.stackBars||t.distributeSeries?0:u*t.seriesBarDistance*(t.horizontalBars?-1:1)),y=v[c]||m,v[c]=y-(m-g[h.counterUnits.pos]),void 0!==a){var w={};w[h.units.pos+"1"]=g[h.units.pos],w[h.units.pos+"2"]=g[h.units.pos],!t.stackBars||"accumulate"!==t.stackMode&&t.stackMode?(w[h.counterUnits.pos+"1"]=m,w[h.counterUnits.pos+"2"]=g[h.counterUnits.pos]):(w[h.counterUnits.pos+"1"]=y,w[h.counterUnits.pos+"2"]=v[c]),w.x1=Math.min(Math.max(w.x1,f.x1),f.x2),w.x2=Math.min(Math.max(w.x2,f.x1),f.x2),w.y1=Math.min(Math.max(w.y1,f.y2),f.y1),w.y2=Math.min(Math.max(w.y2,f.y2),f.y1),x=o.elem("line",w,t.classNames.bar).attr({"ct:value":[a.x,a.y].filter(n.isNum).join(","),"ct:meta":n.getMetaData(e,c)}),this.eventEmitter.emit("draw",n.extend({type:"bar",value:a,index:c,meta:n.getMetaData(e,c),series:e,seriesIndex:r,axisX:d,axisY:p,chartRect:f,group:o,element:x},w))}}.bind(this))}.bind(this)),this.eventEmitter.emit("created",{bounds:l.bounds,chartRect:f,axisX:d,axisY:p,svg:this.svg,options:t})}function r(t,e,i,r){n.Bar.super.constructor.call(this,t,e,s,n.extend({},s,i),r)}var s={axisX:{offset:30,position:"end",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:n.noop,scaleMinSpace:30,onlyInteger:!1},axisY:{offset:40,position:"start",labelOffset:{x:0,y:0},showLabel:!0,showGrid:!0,labelInterpolationFnc:n.noop,scaleMinSpace:20,onlyInteger:!1},width:void 0,height:void 0,high:void 0,low:void 0,chartPadding:{top:15,right:15,bottom:5,left:10},seriesBarDistance:15,stackBars:!1,stackMode:"accumulate",horizontalBars:!1,distributeSeries:!1,reverseData:!1,classNames:{chart:"ct-chart-bar",horizontalBars:"ct-horizontal-bars",label:"ct-label",labelGroup:"ct-labels",series:"ct-series",bar:"ct-bar",grid:"ct-grid",gridGroup:"ct-grids",vertical:"ct-vertical",horizontal:"ct-horizontal",start:"ct-start",end:"ct-end"}};n.Bar=n.Base.extend({constructor:r,createChart:i})}(window,document,t),function(t,e,n){"use strict";function i(t,e,n){var i=e.x>t.x;return i&&"explode"===n||!i&&"implode"===n?"start":i&&"implode"===n||!i&&"explode"===n?"end":"middle"}function r(t){this.data=n.normalizeData(this.data);var e,r,s,o,u,l=[],c=t.startAngle,h=n.getDataArray(this.data,t.reverseData);this.svg=n.createSvg(this.container,t.width,t.height,t.donut?t.classNames.chartDonut:t.classNames.chartPie),r=n.createChartRect(this.svg,t,a.padding),s=Math.min(r.width()/2,r.height()/2),u=t.total||h.reduce(function(t,e){return t+e},0);var d=n.quantity(t.donutWidth);"%"===d.unit&&(d.value*=s/100),s-=t.donut?d.value/2:0,o="outside"===t.labelPosition||t.donut?s:"center"===t.labelPosition?0:s/2,o+=t.labelOffset;var p={x:r.x1+r.width()/2,y:r.y2+r.height()/2},f=1===this.data.series.filter(function(t){return t.hasOwnProperty("value")?0!==t.value:0!==t}).length;t.showLabel&&(e=this.svg.elem("g",null,null,!0));for(var m=0;m<this.data.series.length;m++)if(0!==h[m]||!t.ignoreEmptyValues){var v=this.data.series[m];l[m]=this.svg.elem("g",null,null,!0),l[m].attr({"ct:series-name":v.name}),l[m].addClass([t.classNames.series,v.className||t.classNames.series+"-"+n.alphaNumerate(m)].join(" "));var g=c+h[m]/u*360,x=Math.max(0,c-(0===m||f?0:.2));g-x>=359.99&&(g=x+359.99);var y=n.polarToCartesian(p.x,p.y,s,x),b=n.polarToCartesian(p.x,p.y,s,g),w=new n.Svg.Path(!t.donut).move(b.x,b.y).arc(s,s,0,g-c>180,0,y.x,y.y);t.donut||w.line(p.x,p.y);var E=l[m].elem("path",{d:w.stringify()},t.donut?t.classNames.sliceDonut:t.classNames.slicePie);if(E.attr({"ct:value":h[m],"ct:meta":n.serialize(v.meta)}),t.donut&&E.attr({style:"stroke-width: "+d.value+"px"}),this.eventEmitter.emit("draw",{type:"slice",value:h[m],totalDataSum:u,index:m,meta:v.meta,series:v,group:l[m],element:E,path:w.clone(),center:p,radius:s,startAngle:c,endAngle:g}),t.showLabel){var A=n.polarToCartesian(p.x,p.y,o,c+(g-c)/2),S=t.labelInterpolationFnc(this.data.labels&&!n.isFalseyButZero(this.data.labels[m])?this.data.labels[m]:h[m],m);if(S||0===S){var C=e.elem("text",{dx:A.x,dy:A.y,"text-anchor":i(p,A,t.labelDirection)},t.classNames.label).text(""+S);this.eventEmitter.emit("draw",{type:"label",index:m,group:e,element:C,text:""+S,x:A.x,y:A.y})}}c=g}this.eventEmitter.emit("created",{chartRect:r,svg:this.svg,options:t})}function s(t,e,i,r){n.Pie.super.constructor.call(this,t,e,a,n.extend({},a,i),r)}var a={width:void 0,height:void 0,chartPadding:5,classNames:{chartPie:"ct-chart-pie",chartDonut:"ct-chart-donut",series:"ct-series",slicePie:"ct-slice-pie",sliceDonut:"ct-slice-donut",label:"ct-label"},startAngle:0,total:void 0,donut:!1,donutWidth:60,showLabel:!0,labelOffset:0,labelPosition:"inside",labelInterpolationFnc:n.noop,labelDirection:"neutral",reverseData:!1,ignoreEmptyValues:!1};n.Pie=n.Base.extend({constructor:s,createChart:r,determineAnchorPosition:i})}(window,document,t),t})},function(t,e){function n(t){return r[t]||i(t)}function i(t){throw new Error("No month for number "+t)}t.exports=n;var r={1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"}},function(t,e,n){var i,r;!function(s,a){i=[n(1)],r=function(t){return s.returnExportsGlobal=a(t)}.apply(e,i),!(void 0!==r&&(t.exports=r))}(this,function(t){return function(t,e,n){"use strict";function i(t){s(t,"tooltip-show")||(t.className=t.className+" tooltip-show")}function r(t){var e=new RegExp("tooltip-show\\s*","gi");t.className=t.className.replace(e,"").trim()}function s(t,e){return(" "+t.getAttribute("class")+" ").indexOf(" "+e+" ")>-1}function a(t,e){do t=t.nextSibling;while(t&&!s(t,e));return t}function o(t){return t.innerText||t.textContent}var u={currency:void 0,currencyFormatCallback:void 0,tooltipOffset:{x:0,y:-20},anchorToPoint:!1,appendToBody:!1,class:void 0,pointClass:"ct-point"};n.plugins=n.plugins||{},n.plugins.tooltip=function(l){return l=n.extend({},u,l),function(u){function c(t,e,n){p.addEventListener(t,function(t){e&&!s(t.target,e)||n(t)})}function h(e){m=m||f.offsetHeight,v=v||f.offsetWidth;var n,i,r=-v/2+l.tooltipOffset.x,s=-m+l.tooltipOffset.y;if(l.appendToBody)f.style.top=e.pageY+s+"px",f.style.left=e.pageX+r+"px";else{var a=p.getBoundingClientRect(),o=e.pageX-a.left-t.pageXOffset,u=e.pageY-a.top-t.pageYOffset;!0===l.anchorToPoint&&e.target.x2&&e.target.y2&&(n=parseInt(e.target.x2.baseVal.value),i=parseInt(e.target.y2.baseVal.value)),f.style.top=(i||u)+s+"px",f.style.left=(n||o)+r+"px"}}var d=l.pointClass;u instanceof n.Bar?d="ct-bar":u instanceof n.Pie&&(d=u.options.donut?"ct-slice-donut":"ct-slice-pie");var p=u.container,f=p.querySelector(".chartist-tooltip");f||(f=e.createElement("div"),f.className=l.class?"chartist-tooltip "+l.class:"chartist-tooltip",l.appendToBody?e.body.appendChild(f):p.appendChild(f));var m=f.offsetHeight,v=f.offsetWidth;r(f),c("mouseover",d,function(t){var r=t.target,s="",c=u instanceof n.Pie?r:r.parentNode,d=c?r.parentNode.getAttribute("ct:meta")||r.parentNode.getAttribute("ct:series-name"):"",p=r.getAttribute("ct:meta")||d||"",g=!!p,x=r.getAttribute("ct:value");if(l.transformTooltipTextFnc&&"function"==typeof l.transformTooltipTextFnc&&(x=l.transformTooltipTextFnc(x)),l.tooltipFnc&&"function"==typeof l.tooltipFnc)s=l.tooltipFnc(p,x);else{if(l.metaIsHTML){var y=e.createElement("textarea");y.innerHTML=p,p=y.value}if(p='<span class="chartist-tooltip-meta">'+p+"</span>",g)s+=p+"<br>";else if(u instanceof n.Pie){var b=a(r,"ct-label");b&&(s+=o(b)+"<br>")}x&&(l.currency&&(x=void 0!=l.currencyFormatCallback?l.currencyFormatCallback(x,l):l.currency+x.replace(/(\d)(?=(\d{3})+(?:\.\d+)?$)/g,"$1,")),x='<span class="chartist-tooltip-value">'+x+"</span>",s+=x)}s&&(f.innerHTML=s,h(t),i(f),m=f.offsetHeight,v=f.offsetWidth)}),c("mouseout",d,function(){r(f)}),c("mousemove",null,function(t){!1===l.anchorToPoint&&h(t)})}}}(window,document,t),t.plugins.tooltips})},function(t,e){function n(t){var e=document.getElementById("id-display");e.textContent="(id: "+t+")"}t.exports={render:n}},function(t,e,n){function i(t){var e={labels:t.map(r),series:[t.map(s)]},n={axisX:{labelInterpolationFnc:l(t.length)},plugins:[o.plugins.tooltip({tooltipFnc:c,appendToBody:!0})]};u&&u.detach(),u=new o.Bar(a(),e,n)}function r(t){return t.issue}function s(t){return{meta:r(t),value:t.count}}function a(){return document.querySelector("#by-issue")}var o=n(1);n(3);var u,l=n(6),c=n(7);t.exports={render:i}},function(t,e){function n(t){return t>50?r:i}function i(t,e){return t}function r(t,e){var n=Number(t);if(1==n||n%10==0)return n}t.exports=n},function(t,e){t.exports=function(t,e){return e+" of #"+t}},function(t,e,n){function i(t){var e={labels:t.map(r),series:[t.map(s)]},n={axisX:{labelInterpolationFnc:l(t.length)},plugins:[o.plugins.tooltip({tooltipFnc:c,appendToBody:!0})]};u&&u.detach(),u=new o.Bar(a(),e,n)}function r(t){return t.year+"-"+t.month}function s(t){return{meta:r(t),value:t.count}}function a(){return document.querySelector("#by-month")}var o=n(1);n(3);var u,l=n(9),c=n(10);t.exports={render:i}},function(t,e,n){function i(t,e,n){if(a(t,n))return o(t)}function r(t,e,n){return a(t,n)?s(t):l(u(t))}function s(t){return l(u(t))+" "+o(t)}function a(t,e){var n=e.indexOf(t),i=e[n-1];return!i||o(i)!=o(t)}function o(t){return Number(t.split("-")[0])}function u(t){return Number(t.split("-")[1])}var l=n(2);t.exports=function(t){return t>100?i:t>20?r:s}},function(t,e,n){function i(t){var e=t.split("-");return{year:Number(e[0]),month:Number(e[1])}}var r=n(2);t.exports=function(t,e){var n=i(t);return e+" in "+r(n.month)+" "+n.year}},function(t,e,n){function i(t,e){var n=s();new a(n,{list:t.map(r),filter:function(t,e){return t.toLowerCase().indexOf(e.toLowerCase())!==-1},replace:function(t){this.input.value=t.label}});a.$.bind(n,{"awesomplete-selectcomplete":function(t){var n=t.text;e(n.value)}})}function r(t){return{label:t.title+" ("+t.publisher+")",value:t.id}}function s(){return document.querySelector("#title-picker")}var a=n(12);t.exports={init:i}},function(t,e){!function(){function e(t){var e=Array.isArray(t)?{label:t[0],value:t[1]}:"object"==typeof t&&"label"in t&&"value"in t?t:{label:t,value:t};this.label=e.label||e.value,this.value=e.value}function n(t,e,n){for(var i in e){var r=e[i],s=t.input.getAttribute("data-"+i.toLowerCase());"number"==typeof r?t[i]=parseInt(s):r===!1?t[i]=null!==s:r instanceof Function?t[i]=null:t[i]=s,t[i]||0===t[i]||(t[i]=i in n?n[i]:r)}}function i(t,e){return"string"==typeof t?(e||document).querySelector(t):t||null}function r(t,e){return o.call((e||document).querySelectorAll(t))}function s(){r("input.awesomplete").forEach(function(t){new a(t)})}var a=function(t,e){var r=this;this.input=i(t),this.input.setAttribute("autocomplete","off"),this.input.setAttribute("aria-autocomplete","list"),e=e||{},n(this,{minChars:2,maxItems:10,autoFirst:!1,data:a.DATA,filter:a.FILTER_CONTAINS,sort:a.SORT_BYLENGTH,item:a.ITEM,replace:a.REPLACE},e),this.index=-1,this.container=i.create("div",{className:"awesomplete",around:t}),this.ul=i.create("ul",{hidden:"hidden",inside:this.container}),this.status=i.create("span",{className:"visually-hidden",role:"status","aria-live":"assertive","aria-relevant":"additions",inside:this.container}),i.bind(this.input,{input:this.evaluate.bind(this),blur:this.close.bind(this,{reason:"blur"}),keydown:function(t){var e=t.keyCode;r.opened&&(13===e&&r.selected?(t.preventDefault(),r.select()):27===e?r.close({reason:"esc"}):38!==e&&40!==e||(t.preventDefault(),r[38===e?"previous":"next"]()))}}),i.bind(this.input.form,{submit:this.close.bind(this,{reason:"submit"})}),i.bind(this.ul,{mousedown:function(t){var e=t.target;if(e!==this){for(;e&&!/li/i.test(e.nodeName);)e=e.parentNode;e&&0===t.button&&(t.preventDefault(),r.select(e,t.target))}}}),this.input.hasAttribute("list")?(this.list="#"+this.input.getAttribute("list"),this.input.removeAttribute("list")):this.list=this.input.getAttribute("data-list")||e.list||[],a.all.push(this)};a.prototype={set list(t){if(Array.isArray(t))this._list=t;else if("string"==typeof t&&t.indexOf(",")>-1)this._list=t.split(/\s*,\s*/);else if(t=i(t),t&&t.children){var e=[];o.apply(t.children).forEach(function(t){if(!t.disabled){var n=t.textContent.trim(),i=t.value||n,r=t.label||n;""!==i&&e.push({label:r,value:i})}}),this._list=e}document.activeElement===this.input&&this.evaluate()},get selected(){return this.index>-1},get opened(){return!this.ul.hasAttribute("hidden")},close:function(t){this.opened&&(this.ul.setAttribute("hidden",""),this.index=-1,i.fire(this.input,"awesomplete-close",t||{}))},open:function(){this.ul.removeAttribute("hidden"),this.autoFirst&&this.index===-1&&this.goto(0),i.fire(this.input,"awesomplete-open")},next:function(){var t=this.ul.children.length;this.goto(this.index<t-1?this.index+1:-1)},previous:function(){var t=this.ul.children.length;this.goto(this.selected?this.index-1:t-1)},goto:function(t){var e=this.ul.children;this.selected&&e[this.index].setAttribute("aria-selected","false"),this.index=t,t>-1&&e.length>0&&(e[t].setAttribute("aria-selected","true"),this.status.textContent=e[t].textContent,i.fire(this.input,"awesomplete-highlight",{text:this.suggestions[this.index]}))},select:function(t,e){if(t?this.index=i.siblingIndex(t):t=this.ul.children[this.index],t){var n=this.suggestions[this.index],r=i.fire(this.input,"awesomplete-select",{text:n,origin:e||t});r&&(this.replace(n),this.close({reason:"select"}),i.fire(this.input,"awesomplete-selectcomplete",{text:n}))}},evaluate:function(){var t=this,n=this.input.value;n.length>=this.minChars&&this._list.length>0?(this.index=-1,this.ul.innerHTML="",this.suggestions=this._list.map(function(i){return new e(t.data(i,n))}).filter(function(e){return t.filter(e,n)}).sort(this.sort).slice(0,this.maxItems),this.suggestions.forEach(function(e){t.ul.appendChild(t.item(e,n))}),0===this.ul.children.length?this.close({reason:"nomatches"}):this.open()):this.close({reason:"nomatches"})}},a.all=[],a.FILTER_CONTAINS=function(t,e){return RegExp(i.regExpEscape(e.trim()),"i").test(t)},a.FILTER_STARTSWITH=function(t,e){return RegExp("^"+i.regExpEscape(e.trim()),"i").test(t)},a.SORT_BYLENGTH=function(t,e){return t.length!==e.length?t.length-e.length:t<e?-1:1},a.ITEM=function(t,e){var n=""===e?t:t.replace(RegExp(i.regExpEscape(e.trim()),"gi"),"<mark>$&</mark>");return i.create("li",{innerHTML:n,"aria-selected":"false"})},a.REPLACE=function(t){this.input.value=t.value},a.DATA=function(t){return t},Object.defineProperty(e.prototype=Object.create(String.prototype),"length",{get:function(){return this.label.length}}),e.prototype.toString=e.prototype.valueOf=function(){return""+this.label};var o=Array.prototype.slice;return i.create=function(t,e){var n=document.createElement(t);for(var r in e){var s=e[r];if("inside"===r)i(s).appendChild(n);else if("around"===r){var a=i(s);a.parentNode.insertBefore(n,a),n.appendChild(a)}else r in n?n[r]=s:n.setAttribute(r,s)}return n},i.bind=function(t,e){if(t)for(var n in e){var i=e[n];n.split(/\s+/).forEach(function(e){t.addEventListener(e,i)})}},i.fire=function(t,e,n){var i=document.createEvent("HTMLEvents");i.initEvent(e,!0,!0);for(var r in n)i[r]=n[r];return t.dispatchEvent(i)},i.regExpEscape=function(t){return t.replace(/[-\\^$*+?.()|[\]{}]/g,"\\$&")},i.siblingIndex=function(t){for(var e=0;t=t.previousElementSibling;e++);return e},"undefined"!=typeof Document&&("loading"!==document.readyState?s():document.addEventListener("DOMContentLoaded",s)),a.$=i,a.$$=r,"undefined"!=typeof self&&(self.Awesomplete=a),"object"==typeof t&&t.exports&&(t.exports=a),a}()},function(t,e,n){function i(t){o(l.titles(),t)}function r(t,e){o(l.byMonth(t),e)}function s(t,e){o(l.byIssue(t),e)}function a(t,e,n){o(l.sourceData(t,e),n)}function o(t,e){function n(t){if(r.status>=400)return i(t);var n=JSON.parse(this.responseText);return e(null,n)}function i(n){e(u(r,t,n))}var r=new XMLHttpRequest;r.addEventListener("load",n),r.addEventListener("error",i),r.addEventListener("abort",i),r.open("GET",t),r.send()}function u(t,e,n){var i=new Error("Unable to GET "+e);return i.statusCode=t.status,i.url=e,i.event=n,i}var l=n(14);t.exports={titles:i,byMonth:r,byIssue:s,sourceData:a}},function(t,e){function n(){return o+"/api/titles.json"}function i(t){return o+"/api/titles/"+t+"/by-month.json"}function r(t){return o+"/api/titles/"+t+"/by-issue.json"}function s(t,e){return o+"/api/source-data/"+t+"-"+a(e)+".json"}function a(t){return 1==String(t).length?"0"+t:t}var o="https://comichron-data.github.io";t.exports={titles:n,byMonth:i,byIssue:r,sourceData:s}}]);