tupali/librerias/gantt/code/highcharts-gantt.js

704 lines
348 KiB
JavaScript
Raw Normal View History

2020-05-23 20:45:54 +00:00
/*
Highcharts Gantt JS v8.1.0 (2020-05-05)
(c) 2017-2018 Lars Cabrera, Torstein Honsi, Jon Arild Nygard & Oystein Moseng
License: www.highcharts.com/license
*/
(function(T,P){"object"===typeof module&&module.exports?(P["default"]=P,module.exports=T.document?P(T):P):"function"===typeof define&&define.amd?define("highcharts/highcharts-gantt",function(){return P(T)}):(T.Highcharts&&T.Highcharts.error(16,!0),T.Highcharts=P(T))})("undefined"!==typeof window?window:this,function(T){function P(l,e,B,t){l.hasOwnProperty(e)||(l[e]=t.apply(null,B))}var x={};P(x,"parts/Globals.js",[],function(){var l="undefined"!==typeof T?T:"undefined"!==typeof window?window:{},e=
l.document,B=l.navigator&&l.navigator.userAgent||"",t=e&&e.createElementNS&&!!e.createElementNS("http://www.w3.org/2000/svg","svg").createSVGRect,N=/(edge|msie|trident)/i.test(B)&&!l.opera,H=-1!==B.indexOf("Firefox"),L=-1!==B.indexOf("Chrome"),K=H&&4>parseInt(B.split("Firefox/")[1],10);return{product:"Highcharts",version:"8.1.0",deg2rad:2*Math.PI/360,doc:e,hasBidiBug:K,hasTouch:!!l.TouchEvent,isMS:N,isWebKit:-1!==B.indexOf("AppleWebKit"),isFirefox:H,isChrome:L,isSafari:!L&&-1!==B.indexOf("Safari"),
isTouchDevice:/(Mobile|Android|Windows Phone)/.test(B),SVG_NS:"http://www.w3.org/2000/svg",chartCount:0,seriesTypes:{},symbolSizes:{},svg:t,win:l,marginNames:["plotTop","marginRight","marginBottom","plotLeft"],noop:function(){},charts:[],dateFormats:{}}});P(x,"parts/Utilities.js",[x["parts/Globals.js"]],function(l){function e(){var d,h=arguments,a={},b=function(d,h){"object"!==typeof d&&(d={});R(h,function(a,c){!B(a,!0)||m(a)||q(a)?d[c]=h[c]:d[c]=b(d[c]||{},a)});return d};!0===h[0]&&(a=h[1],h=Array.prototype.slice.call(h,
2));var c=h.length;for(d=0;d<c;d++)a=b(a,h[d]);return a}function B(d,h){return!!d&&"object"===typeof d&&(!h||!z(d))}function t(d,h,a){var c;A(h)?g(a)?d.setAttribute(h,a):d&&d.getAttribute&&((c=d.getAttribute(h))||"class"!==h||(c=d.getAttribute(h+"Name"))):R(h,function(h,a){d.setAttribute(a,h)});return c}function N(){for(var d=arguments,h=d.length,a=0;a<h;a++){var c=d[a];if("undefined"!==typeof c&&null!==c)return c}}function H(d,h){if(!d)return h;var a=d.split(".").reverse();if(1===a.length)return h[d];
for(d=a.pop();"undefined"!==typeof d&&"undefined"!==typeof h&&null!==h;)h=h[d],d=a.pop();return h}l.timers=[];var L=l.charts,K=l.doc,E=l.win,C=l.error=function(d,h,a,c){var b=u(d),G=b?"Highcharts error #"+d+": www.highcharts.com/errors/"+d+"/":d.toString(),M=function(){if(h)throw Error(G);E.console&&console.log(G)};if("undefined"!==typeof c){var f="";b&&(G+="?");R(c,function(d,h){f+="\n"+h+": "+d;b&&(G+=encodeURI(h)+"="+encodeURI(d))});G+=f}a?da(a,"displayError",{code:d,message:G,params:c},M):M()},
J=function(){function d(d,h,a){this.options=h;this.elem=d;this.prop=a}d.prototype.dSetter=function(){var d=this.paths,h=d&&d[0];d=d&&d[1];var a=[],c=this.now||0;if(1!==c&&h&&d)if(h.length===d.length&&1>c)for(var b=0;b<d.length;b++){for(var G=h[b],M=d[b],f=[],g=0;g<M.length;g++){var p=G[g],r=M[g];f[g]="number"===typeof p&&"number"===typeof r&&("A"!==M[0]||4!==g&&5!==g)?p+c*(r-p):r}a.push(f)}else a=d;else a=this.toD||[];this.elem.attr("d",a,void 0,!0)};d.prototype.update=function(){var d=this.elem,
h=this.prop,a=this.now,c=this.options.step;if(this[h+"Setter"])this[h+"Setter"]();else d.attr?d.element&&d.attr(h,a,null,!0):d.style[h]=a+this.unit;c&&c.call(d,a,this)};d.prototype.run=function(d,h,a){var c=this,b=c.options,G=function(d){return G.stopped?!1:c.step(d)},M=E.requestAnimationFrame||function(d){setTimeout(d,13)},f=function(){for(var d=0;d<l.timers.length;d++)l.timers[d]()||l.timers.splice(d--,1);l.timers.length&&M(f)};d!==h||this.elem["forceAnimate:"+this.prop]?(this.startTime=+new Date,
this.start=d,this.end=h,this.unit=a,this.now=this.start,this.pos=0,G.elem=this.elem,G.prop=this.prop,G()&&1===l.timers.push(G)&&M(f)):(delete b.curAnim[this.prop],b.complete&&0===Object.keys(b.curAnim).length&&b.complete.call(this.elem))};d.prototype.step=function(d){var h=+new Date,a=this.options,c=this.elem,b=a.complete,G=a.duration,M=a.curAnim;if(c.attr&&!c.element)d=!1;else if(d||h>=G+this.startTime){this.now=this.end;this.pos=1;this.update();var f=M[this.prop]=!0;R(M,function(d){!0!==d&&(f=!1)});
f&&b&&b.call(c);d=!1}else this.pos=a.easing((h-this.startTime)/G),this.now=this.start+(this.end-this.start)*this.pos,this.update(),d=!0;return d};d.prototype.initPath=function(d,h,a){function c(d,h){for(;d.length<k;){var a=d[0],c=h[k-d.length];c&&"M"===a[0]&&(d[0]="C"===c[0]?["C",a[1],a[2],a[1],a[2],a[1],a[2]]:["L",a[1],a[2]]);d.unshift(a);f&&d.push(d[d.length-1])}}function b(d,h){for(;d.length<k;)if(h=d[d.length/g-1].slice(),"C"===h[0]&&(h[1]=h[5],h[2]=h[6]),f){var a=d[d.length/g].slice();d.splice(d.length/
2,0,h,a)}else d.push(h)}var G=d.startX,M=d.endX;h=h&&h.slice();a=a.slice();var f=d.isArea,g=f?2:1;if(!h)return[a,a];if(G&&M){for(d=0;d<G.length;d++)if(G[d]===M[0]){var p=d;break}else if(G[0]===M[M.length-G.length+d]){p=d;var r=!0;break}else if(G[G.length-1]===M[M.length-G.length+d]){p=G.length-d;break}"undefined"===typeof p&&(h=[])}if(h.length&&u(p)){var k=a.length+p*g;r?(c(h,a),b(a,h)):(c(a,h),b(h,a))}return[h,a]};d.prototype.fillSetter=function(){d.prototype.strokeSetter.apply(this,arguments)};
d.prototype.strokeSetter=function(){this.elem.attr(this.prop,l.color(this.start).tweenTo(l.color(this.end),this.pos),null,!0)};return d}();l.Fx=J;l.merge=e;var y=l.pInt=function(d,h){return parseInt(d,h||10)},A=l.isString=function(d){return"string"===typeof d},z=l.isArray=function(d){d=Object.prototype.toString.call(d);return"[object Array]"===d||"[object Array Iterator]"===d};l.isObject=B;var q=l.isDOMElement=function(d){return B(d)&&"number"===typeof d.nodeType},m=l.isClass=function(d){var h=d&&
d.constructor;return!(!B(d,!0)||q(d)||!h||!h.name||"Object"===h.name)},u=l.isNumber=function(d){return"number"===typeof d&&!isNaN(d)&&Infinity>d&&-Infinity<d},k=l.erase=function(d,h){for(var a=d.length;a--;)if(d[a]===h){d.splice(a,1);break}},g=l.defined=function(d){return"undefined"!==typeof d&&null!==d};l.attr=t;var b=l.splat=function(d){return z(d)?d:[d]},f=l.syncTimeout=function(d,h,a){if(0<h)return setTimeout(d,h,a);d.call(0,a);return-1},a=l.clearTimeout=function(d){g(d)&&clearTimeout(d)},c=l.extend=
function(d,h){var a;d||(d={});for(a in h)d[a]=h[a];return d};l.pick=N;var r=l.css=function(d,h){l.isMS&&!l.svg&&h&&"undefined"!==typeof h.opacity&&(h.filter="alpha(opacity="+100*h.opacity+")");c(d.style,h)},p=l.createElement=function(d,h,a,b,G){d=K.createElement(d);h&&c(d,h);G&&r(d,{padding:"0",border:"none",margin:"0"});a&&r(d,a);b&&b.appendChild(d);return d},I=l.extendClass=function(d,h){var a=function(){};a.prototype=new d;c(a.prototype,h);return a},w=l.pad=function(d,h,a){return Array((h||2)+
1-String(d).replace("-","").length).join(a||"0")+d},v=l.relativeLength=function(d,h,a){return/%$/.test(d)?h*parseFloat(d)/100+(a||0):parseFloat(d)},n=l.wrap=function(d,h,a){var c=d[h];d[h]=function(){var d=Array.prototype.slice.call(arguments),h=arguments,b=this;b.proceed=function(){c.apply(b,arguments.length?arguments:h)};d.unshift(c);d=a.apply(this,d);b.proceed=null;return d}},F=l.format=function(d,h,a){var c="{",b=!1,G=[],M=/f$/,f=/\.([0-9])/,g=l.defaultOptions.lang,p=a&&a.time||l.time;for(a=a&&
a.numberFormatter||V;d;){var r=d.indexOf(c);if(-1===r)break;var k=d.slice(0,r);if(b){k=k.split(":");c=H(k.shift()||"",h);if(k.length&&"number"===typeof c)if(k=k.join(":"),M.test(k)){var n=parseInt((k.match(f)||["","-1"])[1],10);null!==c&&(c=a(c,n,g.decimalPoint,-1<k.indexOf(",")?g.thousandsSep:""))}else c=p.dateFormat(k,c);G.push(c)}else G.push(k);d=d.slice(r+1);c=(b=!b)?"}":"{"}G.push(d);return G.join("")},O=l.getMagnitude=function(d){return Math.pow(10,Math.floor(Math.log(d)/Math.LN10))},D=l.normalizeTickInterval=
function(d,h,a,c,b){var G=d;a=N(a,1);var M=d/a;h||(h=b?[1,1.2,1.5,2,2.5,3,4,5,6,8,10]:[1,2,2.5,5,10],!1===c&&(1===a?h=h.filter(function(d){return 0===d%1}):.1>=a&&(h=[1/a])));for(c=0;c<h.length&&!(G=h[c],b&&G*a>=d||!b&&M<=(h[c]+(h[c+1]||h[c]))/2);c++);return G=S(G*a,-Math.round(Math.log(.001)/Math.LN10))},h=l.stableSort=function(d,h){var a=d.length,c,b;for(b=0;b<a;b++)d[b].safeI=b;d.sort(function(d,a){c=h(d,a);return 0===c?d.safeI-a.safeI:c});for(b=0;b<a;b++)delete d[b].safeI},d=l.arrayMin=function(d){for(var h=
d.length,a=d[0];h--;)d[h]<a&&(a=d[h]);return a},G=l.arrayMax=function(d){for(var h=d.length,a=d[0];h--;)d[h]>a&&(a=d[h]);return a},M=l.destroyObjectProperties=function(d,h){R(d,function(a,c){a&&a!==h&&a.destroy&&a.destroy();delete d[c]})},Q=l.discardElement=function(d){var h=l.garbageBin;h||(h=p("div"));d&&h.appendChild(d);h.innerHTML=""},S=l.correctFloat=function(d,h){return parseFloat(d.toPrecision(h||14))},Z=l.setAnimation=function(d,h){h.renderer.globalAnimation=N(d,h.options.chart.animation,
!0)},U=l.animObject=function(d){return B(d)?e(d):{duration:d?500:0}},W=l.timeUnits={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5,month:24192E5,year:314496E5},V=l.numberFormat=function(d,h,a,c){d=+d||0;h=+h;var b=l.defaultOptions.lang,G=(d.toString().split(".")[1]||"").split("e")[0].length,M=d.toString().split("e");if(-1===h)h=Math.min(G,20);else if(!u(h))h=2;else if(h&&M[1]&&0>M[1]){var f=h+ +M[1];0<=f?(M[0]=(+M[0]).toExponential(f).split("e")[0],h=f):(M[0]=M[0].split(".")[0]||
0,d=20>h?(M[0]*Math.pow(10,M[1])).toFixed(h):0,M[1]=0)}var g=(Math.abs(M[1]?M[0]:d)+Math.pow(10,-Math.max(h,G)-1)).toFixed(h);G=String(y(g));f=3<G.length?G.length%3:0;a=N(a,b.decimalPoint);c=N(c,b.thousandsSep);d=(0>d?"-":"")+(f?G.substr(0,f)+c:"");d+=G.substr(f).replace(/(\d{3})(?=\d)/g,"$1"+c);h&&(d+=a+g.slice(-h));M[1]&&0!==+d&&(d+="e"+M[1]);return d};Math.easeInOutSine=function(d){return-.5*(Math.cos(Math.PI*d)-1)};var ea=l.getStyle=function(d,h,a){if("width"===h)return h=Math.min(d.offsetWidth,
d.scrollWidth),a=d.getBoundingClientRect&&d.getBoundingClientRect().width,a<h&&a>=h-1&&(h=Math.floor(a)),Math.max(0,h-l.getStyle(d,"padding-left")-l.getStyle(d,"padding-right"));if("height"===h)return Math.max(0,Math.min(d.offsetHeight,d.scrollHeight)-l.getStyle(d,"padding-top")-l.getStyle(d,"padding-bottom"));E.getComputedStyle||C(27,!0);if(d=E.getComputedStyle(d,void 0))d=d.getPropertyValue(h),N(a,"opacity"!==h)&&(d=y(d));return d},ca=l.inArray=function(d,h,a){return h.indexOf(d,a)},X=l.find=Array.prototype.find?
function(d,h){return d.find(h)}:function(d,h){var a,c=d.length;for(a=0;a<c;a++)if(h(d[a],a))return d[a]};l.keys=Object.keys;var fa=l.offset=function(d){var h=K.documentElement;d=d.parentElement||d.parentNode?d.getBoundingClientRect():{top:0,left:0};return{top:d.top+(E.pageYOffset||h.scrollTop)-(h.clientTop||0),left:d.left+(E.pageXOffset||h.scrollLeft)-(h.clientLeft||0)}},aa=l.stop=function(d,h){for(var a=l.timers.length;a--;)l.timers[a].elem!==d||h&&h!==l.timers[a].prop||(l.timers[a].stopped=!0)},
R=l.objectEach=function(d,h,a){for(var c in d)Object.hasOwnProperty.call(d,c)&&h.call(a||d[c],d[c],c,d)};R({map:"map",each:"forEach",grep:"filter",reduce:"reduce",some:"some"},function(d,h){l[h]=function(h){return Array.prototype[d].apply(h,[].slice.call(arguments,1))}});var x=l.addEvent=function(d,h,a,c){void 0===c&&(c={});var b=d.addEventListener||l.addEventListenerPolyfill;var G="function"===typeof d&&d.prototype?d.prototype.protoEvents=d.prototype.protoEvents||{}:d.hcEvents=d.hcEvents||{};l.Point&&
d instanceof l.Point&&d.series&&d.series.chart&&(d.series.chart.runTrackerClick=!0);b&&b.call(d,h,a,!1);G[h]||(G[h]=[]);G[h].push({fn:a,order:"number"===typeof c.order?c.order:Infinity});G[h].sort(function(d,h){return d.order-h.order});return function(){ba(d,h,a)}},ba=l.removeEvent=function(d,h,a){function c(h,a){var c=d.removeEventListener||l.removeEventListenerPolyfill;c&&c.call(d,h,a,!1)}function b(a){var b;if(d.nodeName){if(h){var G={};G[h]=!0}else G=a;R(G,function(d,h){if(a[h])for(b=a[h].length;b--;)c(h,
a[h][b].fn)})}}var G;["protoEvents","hcEvents"].forEach(function(M,f){var g=(f=f?d:d.prototype)&&f[M];g&&(h?(G=g[h]||[],a?(g[h]=G.filter(function(d){return a!==d.fn}),c(h,a)):(b(g),g[h]=[])):(b(g),f[M]={}))})},da=l.fireEvent=function(d,h,a,b){var G;a=a||{};if(K.createEvent&&(d.dispatchEvent||d.fireEvent)){var M=K.createEvent("Events");M.initEvent(h,!0,!0);c(M,a);d.dispatchEvent?d.dispatchEvent(M):d.fireEvent(h,M)}else a.target||c(a,{preventDefault:function(){a.defaultPrevented=!0},target:d,type:h}),
function(h,c){void 0===h&&(h=[]);void 0===c&&(c=[]);var b=0,M=0,f=h.length+c.length;for(G=0;G<f;G++)!1===(h[b]?c[M]?h[b].order<=c[M].order?h[b++]:c[M++]:h[b++]:c[M++]).fn.call(d,a)&&a.preventDefault()}(d.protoEvents&&d.protoEvents[h],d.hcEvents&&d.hcEvents[h]);b&&!a.defaultPrevented&&b.call(d,a)},ia=l.animate=function(d,h,a){var c,b="",G,M;if(!B(a)){var f=arguments;a={duration:f[2],easing:f[3],complete:f[4]}}u(a.duration)||(a.duration=400);a.easing="function"===typeof a.easing?a.easing:Math[a.easing]||
Math.easeInOutSine;a.curAnim=e(h);R(h,function(f,g){aa(d,g);M=new J(d,a,g);G=null;"d"===g&&z(h.d)?(M.paths=M.initPath(d,d.pathArray,h.d),M.toD=h.d,c=0,G=1):d.attr?c=d.attr(g):(c=parseFloat(ea(d,g))||0,"opacity"!==g&&(b="px"));G||(G=f);G&&G.match&&G.match("px")&&(G=G.replace(/px/g,""));M.run(c,G,b)})},ja=l.seriesType=function(d,h,a,c,b){var G=l.getOptions(),M=l.seriesTypes;G.plotOptions[d]=e(G.plotOptions[h],a);M[d]=I(M[h]||function(){},c);M[d].prototype.type=d;b&&(M[d].prototype.pointClass=I(l.Point,
b));return M[d]},ha=l.uniqueKey=function(){var d=Math.random().toString(36).substring(2,9),h=0;return function(){return"highcharts-"+d+"-"+h++}}(),P=l.isFunction=function(d){return"function"===typeof d};E.jQuery&&(E.jQuery.fn.highcharts=function(){var d=[].slice.call(arguments);if(this[0])return d[0]?(new (l[A(d[0])?d.shift():"Chart"])(this[0],d[0],d[1]),this):L[t(this[0],"data-highcharts-chart")]});return{Fx:l.Fx,addEvent:x,animate:ia,animObject:U,arrayMax:G,arrayMin:d,attr:t,clamp:function(d,h,
a){return d>h?d<a?d:a:h},clearTimeout:a,correctFloat:S,createElement:p,css:r,defined:g,destroyObjectProperties:M,discardElement:Q,erase:k,error:C,extend:c,extendClass:I,find:X,fireEvent:da,format:F,getMagnitude:O,getNestedProperty:H,getStyle:ea,inArray:ca,isArray:z,isClass:m,isDOMElement:q,isFunction:P,isNumber:u,isObject:B,isString:A,merge:e,normalizeTickInterval:D,numberFormat:V,objectEach:R,offset:fa,pad:w,pick:N,pInt:y,relativeLength:v,removeEvent:ba,seriesType:ja,setAnimation:Z,splat:b,stableSort:h,
stop:aa,syncTimeout:f,timeUnits:W,uniqueKey:ha,wrap:n}});P(x,"parts/Color.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.isNumber,t=e.merge,N=e.pInt;e=function(){function l(e){this.parsers=[{regex:/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]?(?:\.[0-9]+)?)\s*\)/,parse:function(l){return[N(l[1]),N(l[2]),N(l[3]),parseFloat(l[4],10)]}},{regex:/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/,parse:function(l){return[N(l[1]),N(l[2]),
N(l[3]),1]}}];this.rgba=[];if(!(this instanceof l))return new l(e);this.init(e)}l.parse=function(e){return new l(e)};l.prototype.init=function(e){var t,E;if((this.input=e=l.names[e&&e.toLowerCase?e.toLowerCase():""]||e)&&e.stops)this.stops=e.stops.map(function(y){return new l(y[1])});else{if(e&&e.charAt&&"#"===e.charAt()){var C=e.length;e=parseInt(e.substr(1),16);7===C?t=[(e&16711680)>>16,(e&65280)>>8,e&255,1]:4===C&&(t=[(e&3840)>>4|(e&3840)>>8,(e&240)>>4|e&240,(e&15)<<4|e&15,1])}if(!t)for(E=this.parsers.length;E--&&
!t;){var J=this.parsers[E];(C=J.regex.exec(e))&&(t=J.parse(C))}}this.rgba=t||[]};l.prototype.get=function(e){var l=this.input,E=this.rgba;if("undefined"!==typeof this.stops){var C=t(l);C.stops=[].concat(C.stops);this.stops.forEach(function(l,y){C.stops[y]=[C.stops[y][0],l.get(e)]})}else C=E&&B(E[0])?"rgb"===e||!e&&1===E[3]?"rgb("+E[0]+","+E[1]+","+E[2]+")":"a"===e?E[3]:"rgba("+E.join(",")+")":l;return C};l.prototype.brighten=function(e){var l,E=this.rgba;if(this.stops)this.stops.forEach(function(l){l.brighten(e)});
else if(B(e)&&0!==e)for(l=0;3>l;l++)E[l]+=N(255*e),0>E[l]&&(E[l]=0),255<E[l]&&(E[l]=255);return this};l.prototype.setOpacity=function(l){this.rgba[3]=l;return this};l.prototype.tweenTo=function(l,e){var E=this.rgba,C=l.rgba;C.length&&E&&E.length?(l=1!==C[3]||1!==E[3],e=(l?"rgba(":"rgb(")+Math.round(C[0]+(E[0]-C[0])*(1-e))+","+Math.round(C[1]+(E[1]-C[1])*(1-e))+","+Math.round(C[2]+(E[2]-C[2])*(1-e))+(l?","+(C[3]+(E[3]-C[3])*(1-e)):"")+")"):e=l.input||"none";return e};l.names={white:"#ffffff",black:"#000000"};
return l}();l.Color=e;l.color=e.parse;return l.Color});P(x,"parts/SVGElement.js",[x["parts/Color.js"],x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e,B){var t=e.deg2rad,N=e.doc,H=e.hasTouch,L=e.isFirefox,K=e.noop,E=e.svg,C=e.SVG_NS,J=e.win,y=B.animate,A=B.animObject,z=B.attr,q=B.createElement,m=B.css,u=B.defined,k=B.erase,g=B.extend,b=B.fireEvent,f=B.inArray,a=B.isArray,c=B.isFunction,r=B.isNumber,p=B.isString,I=B.merge,w=B.objectEach,v=B.pick,n=B.pInt,F=B.stop,O=B.uniqueKey;B=function(){function D(){this.height=
this.element=void 0;this.opacity=1;this.renderer=void 0;this.SVG_NS=C;this.symbolCustomAttribs="x y width height r start end innerR anchorX anchorY rounded".split(" ");this.textProps="color cursor direction fontFamily fontSize fontStyle fontWeight lineHeight textAlign textDecoration textOutline textOverflow width".split(" ");this.width=void 0}D.prototype._defaultGetter=function(h){h=v(this[h+"Value"],this[h],this.element?this.element.getAttribute(h):null,0);/^[\-0-9\.]+$/.test(h)&&(h=parseFloat(h));
return h};D.prototype._defaultSetter=function(h,d,a){a.setAttribute(d,h)};D.prototype.add=function(h){var d=this.renderer,a=this.element;h&&(this.parentGroup=h);this.parentInverted=h&&h.inverted;"undefined"!==typeof this.textStr&&d.buildText(this);this.added=!0;if(!h||h.handleZ||this.zIndex)var c=this.zIndexSetter();c||(h?h.element:d.box).appendChild(a);if(this.onAdd)this.onAdd();return this};D.prototype.addClass=function(h,d){var a=d?"":this.attr("class")||"";h=(h||"").split(/ /g).reduce(function(d,
h){-1===a.indexOf(h)&&d.push(h);return d},a?[a]:[]).join(" ");h!==a&&this.attr("class",h);return this};D.prototype.afterSetters=function(){this.doTransform&&(this.updateTransform(),this.doTransform=!1)};D.prototype.align=function(h,d,a){var c,b={};var G=this.renderer;var f=G.alignedObjects;var g,r;if(h){if(this.alignOptions=h,this.alignByTranslate=d,!a||p(a))this.alignTo=c=a||"renderer",k(f,this),f.push(this),a=void 0}else h=this.alignOptions,d=this.alignByTranslate,c=this.alignTo;a=v(a,G[c],G);c=
h.align;G=h.verticalAlign;f=(a.x||0)+(h.x||0);var n=(a.y||0)+(h.y||0);"right"===c?g=1:"center"===c&&(g=2);g&&(f+=(a.width-(h.width||0))/g);b[d?"translateX":"x"]=Math.round(f);"bottom"===G?r=1:"middle"===G&&(r=2);r&&(n+=(a.height-(h.height||0))/r);b[d?"translateY":"y"]=Math.round(n);this[this.placed?"animate":"attr"](b);this.placed=!0;this.alignAttr=b;return this};D.prototype.alignSetter=function(h){var d={left:"start",center:"middle",right:"end"};d[h]&&(this.alignValue=h,this.element.setAttribute("text-anchor",
d[h]))};D.prototype.animate=function(h,d,a){var c=A(v(d,this.renderer.globalAnimation,!0));v(N.hidden,N.msHidden,N.webkitHidden,!1)&&(c.duration=0);0!==c.duration?(a&&(c.complete=a),y(this,h,c)):(this.attr(h,void 0,a),w(h,function(d,h){c.step&&c.step.call(this,d,{prop:h,pos:1})},this));return this};D.prototype.applyTextOutline=function(h){var d=this.element,a;-1!==h.indexOf("contrast")&&(h=h.replace(/contrast/g,this.renderer.getContrast(d.style.fill)));h=h.split(" ");var c=h[h.length-1];if((a=h[0])&&
"none"!==a&&e.svg){this.fakeTS=!0;h=[].slice.call(d.getElementsByTagName("tspan"));this.ySetter=this.xSetter;a=a.replace(/(^[\d\.]+)(.*?)$/g,function(d,h,a){return 2*h+a});this.removeTextOutline(h);var b=d.textContent?/^[\u0591-\u065F\u066A-\u07FF\uFB1D-\uFDFD\uFE70-\uFEFC]/.test(d.textContent):!1;var f=d.firstChild;h.forEach(function(h,G){0===G&&(h.setAttribute("x",d.getAttribute("x")),G=d.getAttribute("y"),h.setAttribute("y",G||0),null===G&&d.setAttribute("y",0));G=h.cloneNode(!0);z(b&&!L?h:G,{"class":"highcharts-text-outline",
fill:c,stroke:c,"stroke-width":a,"stroke-linejoin":"round"});d.insertBefore(G,f)});b&&L&&h[0]&&(h=h[0].cloneNode(!0),h.textContent=" ",d.insertBefore(h,f))}};D.prototype.attr=function(h,d,a,c){var b=this.element,G,M=this,g,p,r=this.symbolCustomAttribs;if("string"===typeof h&&"undefined"!==typeof d){var k=h;h={};h[k]=d}"string"===typeof h?M=(this[h+"Getter"]||this._defaultGetter).call(this,h,b):(w(h,function(d,a){g=!1;c||F(this,a);this.symbolName&&-1!==f(a,r)&&(G||(this.symbolAttr(h),G=!0),g=!0);!this.rotation||
"x"!==a&&"y"!==a||(this.doTransform=!0);g||(p=this[a+"Setter"]||this._defaultSetter,p.call(this,d,a,b),!this.styledMode&&this.shadows&&/^(width|height|visibility|x|y|d|transform|cx|cy|r)$/.test(a)&&this.updateShadows(a,d,p))},this),this.afterSetters());a&&a.call(this);return M};D.prototype.clip=function(h){return this.attr("clip-path",h?"url("+this.renderer.url+"#"+h.id+")":"none")};D.prototype.crisp=function(h,d){d=d||h.strokeWidth||0;var a=Math.round(d)%2/2;h.x=Math.floor(h.x||this.x||0)+a;h.y=
Math.floor(h.y||this.y||0)+a;h.width=Math.floor((h.width||this.width||0)-2*a);h.height=Math.floor((h.height||this.height||0)-2*a);u(h.strokeWidth)&&(h.strokeWidth=d);return h};D.prototype.complexColor=function(h,d,c){var G=this.renderer,f,g,p,r,k,n,v,F,D,m,q=[],z;b(this.renderer,"complexColor",{args:arguments},function(){h.radialGradient?g="radialGradient":h.linearGradient&&(g="linearGradient");if(g){p=h[g];k=G.gradients;n=h.stops;D=c.radialReference;a(p)&&(h[g]=p={x1:p[0],y1:p[1],x2:p[2],y2:p[3],
gradientUnits:"userSpaceOnUse"});"radialGradient"===g&&D&&!u(p.gradientUnits)&&(r=p,p=I(p,G.getRadialAttr(D,r),{gradientUnits:"userSpaceOnUse"}));w(p,function(d,h){"id"!==h&&q.push(h,d)});w(n,function(d){q.push(d)});q=q.join(",");if(k[q])m=k[q].attr("id");else{p.id=m=O();var b=k[q]=G.createElement(g).attr(p).add(G.defs);b.radAttr=r;b.stops=[];n.forEach(function(d){0===d[1].indexOf("rgba")?(f=l.parse(d[1]),v=f.get("rgb"),F=f.get("a")):(v=d[1],F=1);d=G.createElement("stop").attr({offset:d[0],"stop-color":v,
"stop-opacity":F}).add(b);b.stops.push(d)})}z="url("+G.url+"#"+m+")";c.setAttribute(d,z);c.gradient=q;h.toString=function(){return z}}})};D.prototype.css=function(h){var d=this.styles,a={},c=this.element,b="",f=!d,p=["textOutline","textOverflow","width"];h&&h.color&&(h.fill=h.color);d&&w(h,function(h,c){d&&d[c]!==h&&(a[c]=h,f=!0)});if(f){d&&(h=g(d,a));if(h)if(null===h.width||"auto"===h.width)delete this.textWidth;else if("text"===c.nodeName.toLowerCase()&&h.width)var r=this.textWidth=n(h.width);this.styles=
h;r&&!E&&this.renderer.forExport&&delete h.width;if(c.namespaceURI===this.SVG_NS){var k=function(d,h){return"-"+h.toLowerCase()};w(h,function(d,h){-1===p.indexOf(h)&&(b+=h.replace(/([A-Z])/g,k)+":"+d+";")});b&&z(c,"style",b)}else m(c,h);this.added&&("text"===this.element.nodeName&&this.renderer.buildText(this),h&&h.textOutline&&this.applyTextOutline(h.textOutline))}return this};D.prototype.dashstyleSetter=function(h){var d=this["stroke-width"];"inherit"===d&&(d=1);if(h=h&&h.toLowerCase()){var a=h.replace("shortdashdotdot",
"3,1,1,1,1,1,").replace("shortdashdot","3,1,1,1").replace("shortdot","1,1,").replace("shortdash","3,1,").replace("longdash","8,3,").replace(/dot/g,"1,3,").replace("dash","4,3,").replace(/,$/,"").split(",");for(h=a.length;h--;)a[h]=""+n(a[h])*v(d,NaN);h=a.join(",").replace(/NaN/g,"none");this.element.setAttribute("stroke-dasharray",h)}};D.prototype.destroy=function(){var h=this,d=h.element||{},a=h.renderer,c=a.isSVG&&"SPAN"===d.nodeName&&h.parentGroup||void 0,b=d.ownerSVGElement;d.onclick=d.onmouseout=
d.onmouseover=d.onmousemove=d.point=null;F(h);if(h.clipPath&&b){var f=h.clipPath;[].forEach.call(b.querySelectorAll("[clip-path],[CLIP-PATH]"),function(d){-1<d.getAttribute("clip-path").indexOf(f.element.id)&&d.removeAttribute("clip-path")});h.clipPath=f.destroy()}if(h.stops){for(b=0;b<h.stops.length;b++)h.stops[b].destroy();h.stops.length=0;h.stops=void 0}h.safeRemoveChild(d);for(a.styledMode||h.destroyShadows();c&&c.div&&0===c.div.childNodes.length;)d=c.parentGroup,h.safeRemoveChild(c.div),delete c.div,
c=d;h.alignTo&&k(a.alignedObjects,h);w(h,function(d,a){h[a]&&h[a].parentGroup===h&&h[a].destroy&&h[a].destroy();delete h[a]})};D.prototype.destroyShadows=function(){(this.shadows||[]).forEach(function(h){this.safeRemoveChild(h)},this);this.shadows=void 0};D.prototype.destroyTextPath=function(h,d){var a=h.getElementsByTagName("text")[0];if(a){if(a.removeAttribute("dx"),a.removeAttribute("dy"),d.element.setAttribute("id",""),this.textPathWrapper&&a.getElementsByTagName("textPath").length){for(h=this.textPathWrapper.element.childNodes;h.length;)a.appendChild(h[0]);
a.removeChild(this.textPathWrapper.element)}}else if(h.getAttribute("dx")||h.getAttribute("dy"))h.removeAttribute("dx"),h.removeAttribute("dy");this.textPathWrapper&&(this.textPathWrapper=this.textPathWrapper.destroy())};D.prototype.dSetter=function(h,d,c){a(h)&&("string"===typeof h[0]&&(h=this.renderer.pathToSegments(h)),this.pathArray=h,h=h.reduce(function(d,h,a){return h&&h.join?(a?d+" ":"")+h.join(" "):(h||"").toString()},""));/(NaN| {2}|^$)/.test(h)&&(h="M 0 0");this[d]!==h&&(c.setAttribute(d,
h),this[d]=h)};D.prototype.fadeOut=function(h){var d=this;d.animate({opacity:0},{duration:v(h,150),complete:function(){d.attr({y:-9999}).hide()}})};D.prototype.fillSetter=function(h,d,a){"string"===typeof h?a.setAttribute(d,h):h&&this.complexColor(h,d,a)};D.prototype.getBBox=function(h,d){var a,b=this.renderer,f=this.element,p=this.styles,r=this.textStr,k=b.cache,n=b.cacheKeys,w=f.namespaceURI===this.SVG_NS;d=v(d,this.rotation,0);var F=b.styledMode?f&&D.prototype.getStyle.call(f,"font-size"):p&&p.fontSize;
if(u(r)){var I=r.toString();-1===I.indexOf("<")&&(I=I.replace(/[0-9]/g,"0"));I+=["",d,F,this.textWidth,p&&p.textOverflow,p&&p.fontWeight].join()}I&&!h&&(a=k[I]);if(!a){if(w||b.forExport){try{var m=this.fakeTS&&function(d){[].forEach.call(f.querySelectorAll(".highcharts-text-outline"),function(h){h.style.display=d})};c(m)&&m("none");a=f.getBBox?g({},f.getBBox()):{width:f.offsetWidth,height:f.offsetHeight};c(m)&&m("")}catch(fa){""}if(!a||0>a.width)a={width:0,height:0}}else a=this.htmlGetBBox();b.isSVG&&
(h=a.width,b=a.height,w&&(a.height=b={"11px,17":14,"13px,20":16}[p&&p.fontSize+","+Math.round(b)]||b),d&&(p=d*t,a.width=Math.abs(b*Math.sin(p))+Math.abs(h*Math.cos(p)),a.height=Math.abs(b*Math.cos(p))+Math.abs(h*Math.sin(p))));if(I&&0<a.height){for(;250<n.length;)delete k[n.shift()];k[I]||n.push(I);k[I]=a}}return a};D.prototype.getStyle=function(h){return J.getComputedStyle(this.element||this,"").getPropertyValue(h)};D.prototype.hasClass=function(h){return-1!==(""+this.attr("class")).split(" ").indexOf(h)};
D.prototype.hide=function(h){h?this.attr({y:-9999}):this.attr({visibility:"hidden"});return this};D.prototype.htmlGetBBox=function(){return{height:0,width:0,x:0,y:0}};D.prototype.init=function(h,d){this.element="span"===d?q(d):N.createElementNS(this.SVG_NS,d);this.renderer=h;b(this,"afterInit")};D.prototype.invert=function(h){this.inverted=h;this.updateTransform();return this};D.prototype.on=function(h,d){var a,c,b=this.element,f;H&&"click"===h?(b.ontouchstart=function(d){a=d.touches[0].clientX;c=
d.touches[0].clientY},b.ontouchend=function(h){a&&4<=Math.sqrt(Math.pow(a-h.changedTouches[0].clientX,2)+Math.pow(c-h.changedTouches[0].clientY,2))||d.call(b,h);f=!0;h.preventDefault()},b.onclick=function(h){f||d.call(b,h)}):b["on"+h]=d;return this};D.prototype.opacitySetter=function(h,d,a){this[d]=h;a.setAttribute(d,h)};D.prototype.removeClass=function(h){return this.attr("class",(""+this.attr("class")).replace(p(h)?new RegExp(" ?"+h+" ?"):h,""))};D.prototype.removeTextOutline=function(h){for(var d=
h.length,a;d--;)a=h[d],"highcharts-text-outline"===a.getAttribute("class")&&k(h,this.element.removeChild(a))};D.prototype.safeRemoveChild=function(h){var d=h.parentNode;d&&d.removeChild(h)};D.prototype.setRadialReference=function(h){var d=this.element.gradient&&this.renderer.gradients[this.element.gradient];this.element.radialReference=h;d&&d.radAttr&&d.animate(this.renderer.getRadialAttr(h,d.radAttr));return this};D.prototype.setTextPath=function(h,d){var a=this.element,c={textAnchor:"text-anchor"},
b=!1,f=this.textPathWrapper,g=!f;d=I(!0,{enabled:!0,attributes:{dy:-5,startOffset:"50%",textAnchor:"middle"}},d);var p=d.attributes;if(h&&d&&d.enabled){f&&null===f.element.parentNode?(g=!0,f=f.destroy()):f&&this.removeTextOutline.call(f.parentGroup,[].slice.call(a.getElementsByTagName("tspan")));this.options&&this.options.padding&&(p.dx=-this.options.padding);f||(this.textPathWrapper=f=this.renderer.createElement("textPath"),b=!0);var k=f.element;(d=h.element.getAttribute("id"))||h.element.setAttribute("id",
d=O());if(g)for(h=a.getElementsByTagName("tspan");h.length;)h[0].setAttribute("y",0),r(p.dx)&&h[0].setAttribute("x",-p.dx),k.appendChild(h[0]);b&&f&&f.add({element:this.text?this.text.element:a});k.setAttributeNS("http://www.w3.org/1999/xlink","href",this.renderer.url+"#"+d);u(p.dy)&&(k.parentNode.setAttribute("dy",p.dy),delete p.dy);u(p.dx)&&(k.parentNode.setAttribute("dx",p.dx),delete p.dx);w(p,function(d,h){k.setAttribute(c[h]||h,d)});a.removeAttribute("transform");this.removeTextOutline.call(f,
[].slice.call(a.getElementsByTagName("tspan")));this.text&&!this.renderer.styledMode&&this.attr({fill:"none","stroke-width":0});this.applyTextOutline=this.updateTransform=K}else f&&(delete this.updateTransform,delete this.applyTextOutline,this.destroyTextPath(a,h),this.updateTransform(),this.options&&this.options.rotation&&this.applyTextOutline(this.options.style.textOutline));return this};D.prototype.shadow=function(h,d,a){var c=[],b=this.element,G=!1,f=this.oldShadowOptions;var p={color:"#000000",
offsetX:1,offsetY:1,opacity:.15,width:3};var r;!0===h?r=p:"object"===typeof h&&(r=g(p,h));r&&(r&&f&&w(r,function(d,h){d!==f[h]&&(G=!0)}),G&&this.destroyShadows(),this.oldShadowOptions=r);if(!r)this.destroyShadows();else if(!this.shadows){var k=r.opacity/r.width;var n=this.parentInverted?"translate(-1,-1)":"translate("+r.offsetX+", "+r.offsetY+")";for(p=1;p<=r.width;p++){var v=b.cloneNode(!1);var F=2*r.width+1-2*p;z(v,{stroke:h.color||"#000000","stroke-opacity":k*p,"stroke-width":F,transform:n,fill:"none"});
v.setAttribute("class",(v.getAttribute("class")||"")+" highcharts-shadow");a&&(z(v,"height",Math.max(z(v,"height")-F,0)),v.cutHeight=F);d?d.element.appendChild(v):b.parentNode&&b.parentNode.insertBefore(v,b);c.push(v)}this.shadows=c}return this};D.prototype.show=function(h){return this.attr({visibility:h?"inherit":"visible"})};D.prototype.strokeSetter=function(h,d,a){this[d]=h;this.stroke&&this["stroke-width"]?(D.prototype.fillSetter.call(this,this.stroke,"stroke",a),a.setAttribute("stroke-width",
this["stroke-width"]),this.hasStroke=!0):"stroke-width"===d&&0===h&&this.hasStroke?(a.removeAttribute("stroke"),this.hasStroke=!1):this.renderer.styledMode&&this["stroke-width"]&&(a.setAttribute("stroke-width",this["stroke-width"]),this.hasStroke=!0)};D.prototype.strokeWidth=function(){if(!this.renderer.styledMode)return this["stroke-width"]||0;var h=this.getStyle("stroke-width"),d=0;if(h.indexOf("px")===h.length-2)d=n(h);else if(""!==h){var a=N.createElementNS(C,"rect");z(a,{width:h,"stroke-width":0});
this.element.parentNode.appendChild(a);d=a.getBBox().width;a.parentNode.removeChild(a)}return d};D.prototype.symbolAttr=function(h){var d=this;"x y r start end width height innerR anchorX anchorY clockwise".split(" ").forEach(function(a){d[a]=v(h[a],d[a])});d.attr({d:d.renderer.symbols[d.symbolName](d.x,d.y,d.width,d.height,d)})};D.prototype.textSetter=function(h){h!==this.textStr&&(delete this.textPxLength,this.textStr=h,this.added&&this.renderer.buildText(this))};D.prototype.titleSetter=function(h){var d=
this.element.getElementsByTagName("title")[0];d||(d=N.createElementNS(this.SVG_NS,"title"),this.element.appendChild(d));d.firstChild&&d.removeChild(d.firstChild);d.appendChild(N.createTextNode(String(v(h,"")).replace(/<[^>]*>/g,"").replace(/&lt;/g,"<").replace(/&gt;/g,">")))};D.prototype.toFront=function(){var h=this.element;h.parentNode.appendChild(h);return this};D.prototype.translate=function(h,d){return this.attr({translateX:h,translateY:d})};D.prototype.updateShadows=function(h,d,a){var c=this.shadows;
if(c)for(var b=c.length;b--;)a.call(c[b],"height"===h?Math.max(d-(c[b].cutHeight||0),0):"d"===h?this.d:d,h,c[b])};D.prototype.updateTransform=function(){var h=this.translateX||0,d=this.translateY||0,a=this.scaleX,c=this.scaleY,b=this.inverted,f=this.rotation,g=this.matrix,p=this.element;b&&(h+=this.width,d+=this.height);h=["translate("+h+","+d+")"];u(g)&&h.push("matrix("+g.join(",")+")");b?h.push("rotate(90) scale(-1,1)"):f&&h.push("rotate("+f+" "+v(this.rotationOriginX,p.getAttribute("x"),0)+" "+
v(this.rotationOriginY,p.getAttribute("y")||0)+")");(u(a)||u(c))&&h.push("scale("+v(a,1)+" "+v(c,1)+")");h.length&&p.setAttribute("transform",h.join(" "))};D.prototype.visibilitySetter=function(h,d,a){"inherit"===h?a.removeAttribute(d):this[d]!==h&&a.setAttribute(d,h);this[d]=h};D.prototype.xGetter=function(h){"circle"===this.element.nodeName&&("x"===h?h="cx":"y"===h&&(h="cy"));return this._defaultGetter(h)};D.prototype.zIndexSetter=function(h,d){var a=this.renderer,c=this.parentGroup,b=(c||a).element||
a.box,f=this.element,g=!1;a=b===a.box;var p=this.added;var r;u(h)?(f.setAttribute("data-z-index",h),h=+h,this[d]===h&&(p=!1)):u(this[d])&&f.removeAttribute("data-z-index");this[d]=h;if(p){(h=this.zIndex)&&c&&(c.handleZ=!0);d=b.childNodes;for(r=d.length-1;0<=r&&!g;r--){c=d[r];p=c.getAttribute("data-z-index");var k=!u(p);if(c!==f)if(0>h&&k&&!a&&!r)b.insertBefore(f,d[r]),g=!0;else if(n(p)<=h||k&&(!u(h)||0<=h))b.insertBefore(f,d[r+1]||null),g=!0}g||(b.insertBefore(f,d[a?3:0]||null),g=!0)}return g};return D}();
B.prototype["stroke-widthSetter"]=B.prototype.strokeSetter;B.prototype.yGetter=B.prototype.xGetter;B.prototype.matrixSetter=B.prototype.rotationOriginXSetter=B.prototype.rotationOriginYSetter=B.prototype.rotationSetter=B.prototype.scaleXSetter=B.prototype.scaleYSetter=B.prototype.translateXSetter=B.prototype.translateYSetter=B.prototype.verticalAlignSetter=function(a,h){this[h]=a;this.doTransform=!0};e.SVGElement=B;return e.SVGElement});P(x,"parts/SvgRenderer.js",[x["parts/Color.js"],x["parts/Globals.js"],
x["parts/SVGElement.js"],x["parts/Utilities.js"]],function(l,e,B,t){var N=l.parse,H=t.addEvent,L=t.attr,K=t.createElement,E=t.css,C=t.defined,J=t.destroyObjectProperties,y=t.extend,A=t.isArray,z=t.isNumber,q=t.isObject,m=t.isString,u=t.merge,k=t.objectEach,g=t.pick,b=t.pInt,f=t.removeEvent,a=t.splat,c=t.uniqueKey,r=e.charts,p=e.deg2rad,I=e.doc,w=e.isFirefox,v=e.isMS,n=e.isWebKit;t=e.noop;var F=e.svg,O=e.SVG_NS,D=e.symbolSizes,h=e.win;l=e.SVGRenderer=function(){this.init.apply(this,arguments)};y(l.prototype,
{Element:B,SVG_NS:O,init:function(d,a,c,b,f,g,p){var G=this.createElement("svg").attr({version:"1.1","class":"highcharts-root"});p||G.css(this.getStyle(b));b=G.element;d.appendChild(b);L(d,"dir","ltr");-1===d.innerHTML.indexOf("xmlns")&&L(b,"xmlns",this.SVG_NS);this.isSVG=!0;this.box=b;this.boxWrapper=G;this.alignedObjects=[];this.url=(w||n)&&I.getElementsByTagName("base").length?h.location.href.split("#")[0].replace(/<[^>]*>/g,"").replace(/([\('\)])/g,"\\$1").replace(/ /g,"%20"):"";this.createElement("desc").add().element.appendChild(I.createTextNode("Created with Highcharts 8.1.0"));
this.defs=this.createElement("defs").add();this.allowHTML=g;this.forExport=f;this.styledMode=p;this.gradients={};this.cache={};this.cacheKeys=[];this.imgCount=0;this.setSize(a,c,!1);var M;w&&d.getBoundingClientRect&&(a=function(){E(d,{left:0,top:0});M=d.getBoundingClientRect();E(d,{left:Math.ceil(M.left)-M.left+"px",top:Math.ceil(M.top)-M.top+"px"})},a(),this.unSubPixelFix=H(h,"resize",a))},definition:function(d){function h(d,b){var f;a(d).forEach(function(d){var a=c.createElement(d.tagName),G={};
k(d,function(d,h){"tagName"!==h&&"children"!==h&&"textContent"!==h&&(G[h]=d)});a.attr(G);a.add(b||c.defs);d.textContent&&a.element.appendChild(I.createTextNode(d.textContent));h(d.children||[],a);f=a});return f}var c=this;return h(d)},getStyle:function(d){return this.style=y({fontFamily:'"Lucida Grande", "Lucida Sans Unicode", Arial, Helvetica, sans-serif',fontSize:"12px"},d)},setStyle:function(d){this.boxWrapper.css(this.getStyle(d))},isHidden:function(){return!this.boxWrapper.getBBox().width},destroy:function(){var d=
this.defs;this.box=null;this.boxWrapper=this.boxWrapper.destroy();J(this.gradients||{});this.gradients=null;d&&(this.defs=d.destroy());this.unSubPixelFix&&this.unSubPixelFix();return this.alignedObjects=null},createElement:function(d){var h=new this.Element;h.init(this,d);return h},draw:t,getRadialAttr:function(d,h){return{cx:d[0]-d[2]/2+h.cx*d[2],cy:d[1]-d[2]/2+h.cy*d[2],r:h.r*d[2]}},truncate:function(d,h,a,c,b,f,g){var G=this,M=d.rotation,p,r=c?1:0,k=(a||c).length,n=k,w=[],v=function(d){h.firstChild&&
h.removeChild(h.firstChild);d&&h.appendChild(I.createTextNode(d))},F=function(f,M){M=M||f;if("undefined"===typeof w[M])if(h.getSubStringLength)try{w[M]=b+h.getSubStringLength(0,c?M+1:M)}catch(ha){""}else G.getSpanWidth&&(v(g(a||c,f)),w[M]=b+G.getSpanWidth(d,h));return w[M]},Q;d.rotation=0;var S=F(h.textContent.length);if(Q=b+S>f){for(;r<=k;)n=Math.ceil((r+k)/2),c&&(p=g(c,n)),S=F(n,p&&p.length-1),r===k?r=k+1:S>f?k=n-1:r=n;0===k?v(""):a&&k===a.length-1||v(p||g(a||c,n))}c&&c.splice(0,n);d.actualWidth=
S;d.rotation=M;return Q},escapes:{"&":"&amp;","<":"&lt;",">":"&gt;","'":"&#39;",'"':"&quot;"},buildText:function(d){var h=d.element,a=this,c=a.forExport,f=g(d.textStr,"").toString(),p=-1!==f.indexOf("<"),r=h.childNodes,n,w=L(h,"x"),v=d.styles,m=d.textWidth,D=v&&v.lineHeight,q=v&&v.textOutline,u=v&&"ellipsis"===v.textOverflow,z=v&&"nowrap"===v.whiteSpace,l=v&&v.fontSize,e,y=r.length;v=m&&!d.added&&this.box;var A=function(d){var c;a.styledMode||(c=/(px|em)$/.test(d&&d.style.fontSize)?d.style.fontSize:
l||a.style.fontSize||12);return D?b(D):a.fontMetrics(c,d.getAttribute("style")?d:h).h},C=function(d,h){k(a.escapes,function(a,c){h&&-1!==h.indexOf(a)||(d=d.toString().replace(new RegExp(a,"g"),c))});return d},J=function(d,h){var a=d.indexOf("<");d=d.substring(a,d.indexOf(">")-a);a=d.indexOf(h+"=");if(-1!==a&&(a=a+h.length+1,h=d.charAt(a),'"'===h||"'"===h))return d=d.substring(a+1),d.substring(0,d.indexOf(h))},t=/<br.*?>/g;var K=[f,u,z,D,q,l,m].join();if(K!==d.textCache){for(d.textCache=K;y--;)h.removeChild(r[y]);
p||q||u||m||-1!==f.indexOf(" ")&&(!z||t.test(f))?(v&&v.appendChild(h),p?(f=a.styledMode?f.replace(/<(b|strong)>/g,'<span class="highcharts-strong">').replace(/<(i|em)>/g,'<span class="highcharts-emphasized">'):f.replace(/<(b|strong)>/g,'<span style="font-weight:bold">').replace(/<(i|em)>/g,'<span style="font-style:italic">'),f=f.replace(/<a/g,"<span").replace(/<\/(b|strong|i|em|a)>/g,"</span>").split(t)):f=[f],f=f.filter(function(d){return""!==d}),f.forEach(function(b,f){var G=0,M=0;b=b.replace(/^\s+|\s+$/g,
"").replace(/<span/g,"|||<span").replace(/<\/span>/g,"</span>|||");var g=b.split("|||");g.forEach(function(b){if(""!==b||1===g.length){var p={},r=I.createElementNS(a.SVG_NS,"tspan"),k,v;(k=J(b,"class"))&&L(r,"class",k);if(k=J(b,"style"))k=k.replace(/(;| |^)color([ :])/,"$1fill$2"),L(r,"style",k);(v=J(b,"href"))&&!c&&(L(r,"onclick",'location.href="'+v+'"'),L(r,"class","highcharts-anchor"),a.styledMode||E(r,{cursor:"pointer"}));b=C(b.replace(/<[a-zA-Z\/](.|\n)*?>/g,"")||" ");if(" "!==b){r.appendChild(I.createTextNode(b));
G?p.dx=0:f&&null!==w&&(p.x=w);L(r,p);h.appendChild(r);!G&&e&&(!F&&c&&E(r,{display:"block"}),L(r,"dy",A(r)));if(m){var Q=b.replace(/([^\^])-/g,"$1- ").split(" ");p=!z&&(1<g.length||f||1<Q.length);v=0;var S=A(r);if(u)n=a.truncate(d,r,b,void 0,0,Math.max(0,m-parseInt(l||12,10)),function(d,h){return d.substring(0,h)+"\u2026"});else if(p)for(;Q.length;)Q.length&&!z&&0<v&&(r=I.createElementNS(O,"tspan"),L(r,{dy:S,x:w}),k&&L(r,"style",k),r.appendChild(I.createTextNode(Q.join(" ").replace(/- /g,"-"))),h.appendChild(r)),
a.truncate(d,r,null,Q,0===v?M:0,m,function(d,h){return Q.slice(0,h).join(" ").replace(/- /g,"-")}),M=d.actualWidth,v++}G++}}});e=e||h.childNodes.length}),u&&n&&d.attr("title",C(d.textStr,["&lt;","&gt;"])),v&&v.removeChild(h),q&&d.applyTextOutline&&d.applyTextOutline(q)):h.appendChild(I.createTextNode(C(f)))}},getContrast:function(d){d=N(d).rgba;d[0]*=1;d[1]*=1.2;d[2]*=.5;return 459<d[0]+d[1]+d[2]?"#000000":"#FFFFFF"},button:function(d,h,a,c,b,f,g,p,r,k){var G=this.label(d,h,a,r,void 0,void 0,k,void 0,
"button"),M=0,n=this.styledMode;G.attr(u({padding:8,r:2},b));if(!n){b=u({fill:"#f7f7f7",stroke:"#cccccc","stroke-width":1,style:{color:"#333333",cursor:"pointer",fontWeight:"normal"}},b);var w=b.style;delete b.style;f=u(b,{fill:"#e6e6e6"},f);var F=f.style;delete f.style;g=u(b,{fill:"#e6ebf5",style:{color:"#000000",fontWeight:"bold"}},g);var Q=g.style;delete g.style;p=u(b,{style:{color:"#cccccc"}},p);var I=p.style;delete p.style}H(G.element,v?"mouseover":"mouseenter",function(){3!==M&&G.setState(1)});
H(G.element,v?"mouseout":"mouseleave",function(){3!==M&&G.setState(M)});G.setState=function(d){1!==d&&(G.state=M=d);G.removeClass(/highcharts-button-(normal|hover|pressed|disabled)/).addClass("highcharts-button-"+["normal","hover","pressed","disabled"][d||0]);n||G.attr([b,f,g,p][d||0]).css([w,F,Q,I][d||0])};n||G.attr(b).css(y({cursor:"default"},w));return G.on("click",function(d){3!==M&&c.call(G,d)})},crispLine:function(d,h,a){void 0===a&&(a="round");var c=d[0],b=d[1];c[1]===b[1]&&(c[1]=b[1]=Math[a](c[1])-
h%2/2);c[2]===b[2]&&(c[2]=b[2]=Math[a](c[2])+h%2/2);return d},path:function(d){var h=this.styledMode?{}:{fill:"none"};A(d)?h.d=d:q(d)&&y(h,d);return this.createElement("path").attr(h)},circle:function(d,h,a){d=q(d)?d:"undefined"===typeof d?{}:{x:d,y:h,r:a};h=this.createElement("circle");h.xSetter=h.ySetter=function(d,h,a){a.setAttribute("c"+h,d)};return h.attr(d)},arc:function(d,h,a,c,b,f){q(d)?(c=d,h=c.y,a=c.r,d=c.x):c={innerR:c,start:b,end:f};d=this.symbol("arc",d,h,a,a,c);d.r=a;return d},rect:function(d,
h,a,c,b,f){b=q(d)?d.r:b;var G=this.createElement("rect");d=q(d)?d:"undefined"===typeof d?{}:{x:d,y:h,width:Math.max(a,0),height:Math.max(c,0)};this.styledMode||("undefined"!==typeof f&&(d.strokeWidth=f,d=G.crisp(d)),d.fill="none");b&&(d.r=b);G.rSetter=function(d,h,a){G.r=d;L(a,{rx:d,ry:d})};G.rGetter=function(){return G.r};return G.attr(d)},setSize:function(d,h,a){var c=this.alignedObjects,b=c.length;this.width=d;this.height=h;for(this.boxWrapper.animate({width:d,height:h},{step:function(){this.attr({viewBox:"0 0 "+
this.attr("width")+" "+this.attr("height")})},duration:g(a,!0)?void 0:0});b--;)c[b].align()},g:function(d){var h=this.createElement("g");return d?h.attr({"class":"highcharts-"+d}):h},image:function(d,a,c,b,f,g){var G={preserveAspectRatio:"none"},p=function(d,h){d.setAttributeNS?d.setAttributeNS("http://www.w3.org/1999/xlink","href",h):d.setAttribute("hc-svg-href",h)},M=function(h){p(r.element,d);g.call(r,h)};1<arguments.length&&y(G,{x:a,y:c,width:b,height:f});var r=this.createElement("image").attr(G);
g?(p(r.element,"data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="),G=new h.Image,H(G,"load",M),G.src=d,G.complete&&M({})):p(r.element,d);return r},symbol:function(d,h,a,c,b,f){var G=this,p=/^url\((.*?)\)$/,M=p.test(d),k=!M&&(this.symbols[d]?d:"circle"),n=k&&this.symbols[k],v;if(n){"number"===typeof h&&(v=n.call(this.symbols,Math.round(h||0),Math.round(a||0),c,b,f));var w=this.path(v);G.styledMode||w.attr("fill","none");y(w,{symbolName:k,x:h,y:a,width:c,height:b});f&&y(w,
f)}else if(M){var F=d.match(p)[1];w=this.image(F);w.imgwidth=g(D[F]&&D[F].width,f&&f.width);w.imgheight=g(D[F]&&D[F].height,f&&f.height);var Q=function(){w.attr({width:w.width,height:w.height})};["width","height"].forEach(function(d){w[d+"Setter"]=function(d,h){var a={},c=this["img"+h],b="width"===h?"translateX":"translateY";this[h]=d;C(c)&&(f&&"within"===f.backgroundSize&&this.width&&this.height&&(c=Math.round(c*Math.min(this.width/this.imgwidth,this.height/this.imgheight))),this.element&&this.element.setAttribute(h,
c),this.alignByTranslate||(a[b]=((this[h]||0)-c)/2,this.attr(a)))}});C(h)&&w.attr({x:h,y:a});w.isImg=!0;C(w.imgwidth)&&C(w.imgheight)?Q():(w.attr({width:0,height:0}),K("img",{onload:function(){var d=r[G.chartIndex];0===this.width&&(E(this,{position:"absolute",top:"-999em"}),I.body.appendChild(this));D[F]={width:this.width,height:this.height};w.imgwidth=this.width;w.imgheight=this.height;w.element&&Q();this.parentNode&&this.parentNode.removeChild(this);G.imgCount--;if(!G.imgCount&&d&&!d.hasLoaded)d.onload()},
src:F}),this.imgCount++)}return w},symbols:{circle:function(d,h,a,c){return this.arc(d+a/2,h+c/2,a/2,c/2,{start:.5*Math.PI,end:2.5*Math.PI,open:!1})},square:function(d,h,a,c){return[["M",d,h],["L",d+a,h],["L",d+a,h+c],["L",d,h+c],["Z"]]},triangle:function(d,h,a,c){return[["M",d+a/2,h],["L",d+a,h+c],["L",d,h+c],["Z"]]},"triangle-down":function(d,h,a,c){return[["M",d,h],["L",d+a,h],["L",d+a/2,h+c],["Z"]]},diamond:function(d,h,a,c){return[["M",d+a/2,h],["L",d+a,h+c/2],["L",d+a/2,h+c],["L",d,h+c/2],["Z"]]},
arc:function(d,h,a,c,b){var f=b.start,G=b.r||a,p=b.r||c||a,r=b.end-.001;a=b.innerR;c=g(b.open,.001>Math.abs(b.end-b.start-2*Math.PI));var M=Math.cos(f),k=Math.sin(f),n=Math.cos(r);r=Math.sin(r);f=g(b.longArc,.001>b.end-f-Math.PI?0:1);G=[["M",d+G*M,h+p*k],["A",G,p,0,f,g(b.clockwise,1),d+G*n,h+p*r]];C(a)&&G.push(c?["M",d+a*n,h+a*r]:["L",d+a*n,h+a*r],["A",a,a,0,f,C(b.clockwise)?1-b.clockwise:0,d+a*M,h+a*k]);c||G.push(["Z"]);return G},callout:function(d,h,a,c,b){var f=Math.min(b&&b.r||0,a,c),p=f+6,g=
b&&b.anchorX;b=b&&b.anchorY;var r=[["M",d+f,h],["L",d+a-f,h],["C",d+a,h,d+a,h,d+a,h+f],["L",d+a,h+c-f],["C",d+a,h+c,d+a,h+c,d+a-f,h+c],["L",d+f,h+c],["C",d,h+c,d,h+c,d,h+c-f],["L",d,h+f],["C",d,h,d,h,d+f,h]];g&&g>a?b>h+p&&b<h+c-p?r.splice(3,1,["L",d+a,b-6],["L",d+a+6,b],["L",d+a,b+6],["L",d+a,h+c-f]):r.splice(3,1,["L",d+a,c/2],["L",g,b],["L",d+a,c/2],["L",d+a,h+c-f]):g&&0>g?b>h+p&&b<h+c-p?r.splice(7,1,["L",d,b+6],["L",d-6,b],["L",d,b-6],["L",d,h+f]):r.splice(7,1,["L",d,c/2],["L",g,b],["L",d,c/2],
["L",d,h+f]):b&&b>c&&g>d+p&&g<d+a-p?r.splice(5,1,["L",g+6,h+c],["L",g,h+c+6],["L",g-6,h+c],["L",d+f,h+c]):b&&0>b&&g>d+p&&g<d+a-p&&r.splice(1,1,["L",g-6,h],["L",g,h-6],["L",g+6,h],["L",a-f,h]);return r}},clipRect:function(d,h,a,b){var f=c()+"-",g=this.createElement("clipPath").attr({id:f}).add(this.defs);d=this.rect(d,h,a,b,0).add(g);d.id=f;d.clipPath=g;d.count=0;return d},text:function(d,h,a,c){var b={};if(c&&(this.allowHTML||!this.forExport))return this.html(d,h,a);b.x=Math.round(h||0);a&&(b.y=Math.round(a));
C(d)&&(b.text=d);d=this.createElement("text").attr(b);c||(d.xSetter=function(d,h,a){var c=a.getElementsByTagName("tspan"),b=a.getAttribute(h),f;for(f=0;f<c.length;f++){var g=c[f];g.getAttribute(h)===b&&g.setAttribute(h,d)}a.setAttribute(h,d)});return d},fontMetrics:function(d,a){d=!this.styledMode&&/px/.test(d)||!h.getComputedStyle?d||a&&a.style&&a.style.fontSize||this.style&&this.style.fontSize:a&&B.prototype.getStyle.call(a,"font-size");d=/px/.test(d)?b(d):12;a=24>d?d+3:Math.round(1.2*d);return{h:a,
b:Math.round(.8*a),f:d}},rotCorr:function(d,h,a){var c=d;h&&a&&(c=Math.max(c*Math.cos(h*p),4));return{x:-d/3*Math.sin(h*p),y:c}},pathToSegments:function(d){for(var h=[],a=[],c={A:8,C:7,H:2,L:3,M:3,Q:5,S:5,T:3,V:2},b=0;b<d.length;b++)m(a[0])&&z(d[b])&&a.length===c[a[0].toUpperCase()]&&d.splice(b,0,a[0].replace("M","L").replace("m","l")),"string"===typeof d[b]&&(a.length&&h.push(a.slice(0)),a.length=0),a.push(d[b]);h.push(a.slice(0));return h},label:function(d,h,a,c,b,g,p,r,k){var G=this,M=G.styledMode,
n=G.g("button"!==k&&"label"),w=n.text=G.text("",0,0,p).attr({zIndex:1}),v,F={width:0,height:0,x:0,y:0},Q=F,I=0,m=3,D=0,O,q,S,l,e,Z={},A,E,J=/^url\((.*?)\)$/.test(c),U=M||J,t=function(){return M?v.strokeWidth()%2/2:(A?parseInt(A,10):0)%2/2};k&&n.addClass("highcharts-"+k);var V=function(){var d=w.element.style,h={};Q=z(O)&&z(q)&&!e||!C(w.textStr)?F:w.getBBox();n.width=(O||Q.width||0)+2*m+D;n.height=(q||Q.height||0)+2*m;E=m+Math.min(G.fontMetrics(d&&d.fontSize,w).b,Q.height||Infinity);U&&(v||(n.box=
v=G.symbols[c]||J?G.symbol(c):G.rect(),v.addClass(("button"===k?"":"highcharts-label-box")+(k?" highcharts-"+k+"-box":"")),v.add(n),d=t(),h.x=d,h.y=(r?-E:0)+d),h.width=Math.round(n.width),h.height=Math.round(n.height),v.attr(y(h,Z)),Z={})};var W=function(){var d=D+m;var h=r?0:E;C(O)&&Q&&("center"===e||"right"===e)&&(d+={center:.5,right:1}[e]*(O-Q.width));if(d!==w.x||h!==w.y)w.attr("x",d),w.hasBoxWidthChanged&&(Q=w.getBBox(!0),V()),"undefined"!==typeof h&&w.attr("y",h);w.x=d;w.y=h};var K=function(d,
h){v?v.attr(d,h):Z[d]=h};n.onAdd=function(){w.add(n);n.attr({text:d||0===d?d:"",x:h,y:a});v&&C(b)&&n.attr({anchorX:b,anchorY:g})};n.widthSetter=function(d){O=z(d)?d:null};n.heightSetter=function(d){q=d};n["text-alignSetter"]=function(d){e=d};n.paddingSetter=function(d){C(d)&&d!==m&&(m=n.padding=d,W())};n.paddingLeftSetter=function(d){C(d)&&d!==D&&(D=d,W())};n.alignSetter=function(d){d={left:0,center:.5,right:1}[d];d!==I&&(I=d,Q&&n.attr({x:S}))};n.textSetter=function(d){"undefined"!==typeof d&&w.attr({text:d});
V();W()};n["stroke-widthSetter"]=function(d,h){d&&(U=!0);A=this["stroke-width"]=d;K(h,d)};M?n.rSetter=function(d,h){K(h,d)}:n.strokeSetter=n.fillSetter=n.rSetter=function(d,h){"r"!==h&&("fill"===h&&d&&(U=!0),n[h]=d);K(h,d)};n.anchorXSetter=function(d,h){b=n.anchorX=d;K(h,Math.round(d)-t()-S)};n.anchorYSetter=function(d,h){g=n.anchorY=d;K(h,d-l)};n.xSetter=function(d){n.x=d;I&&(d-=I*((O||Q.width)+2*m),n["forceAnimate:x"]=!0);S=Math.round(d);n.attr("translateX",S)};n.ySetter=function(d){l=n.y=Math.round(d);
n.attr("translateY",l)};n.isLabel=!0;var L=n.css;p={css:function(d){if(d){var h={};d=u(d);n.textProps.forEach(function(a){"undefined"!==typeof d[a]&&(h[a]=d[a],delete d[a])});w.css(h);var a="fontSize"in h||"fontWeight"in h;if("width"in h||a)V(),a&&W()}return L.call(n,d)},getBBox:function(){return{width:Q.width+2*m,height:Q.height+2*m,x:Q.x-m,y:Q.y-m}},destroy:function(){f(n.element,"mouseenter");f(n.element,"mouseleave");w&&w.destroy();v&&(v=v.destroy());B.prototype.destroy.call(n);n=G=w=V=W=K=null}};
n.on=function(d,h){var a=w&&"SPAN"===w.element.tagName?w:void 0;if(a){var c=function(c){("mouseenter"===d||"mouseleave"===d)&&c.relatedTarget instanceof Element&&(n.element.contains(c.relatedTarget)||a.element.contains(c.relatedTarget))||h.call(n.element,c)};a.on(d,c)}B.prototype.on.call(n,d,c||h);return n};M||(p.shadow=function(d){d&&(V(),v&&v.shadow(d));return n});return y(n,p)}});e.Renderer=l});P(x,"parts/Html.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.attr,t=e.createElement,
N=e.css,H=e.defined,L=e.extend,K=e.pick,E=e.pInt,C=l.isFirefox,J=l.isMS,y=l.isWebKit,A=l.SVGElement;e=l.SVGRenderer;var z=l.win;L(A.prototype,{htmlCss:function(q){var m="SPAN"===this.element.tagName&&q&&"width"in q,u=K(m&&q.width,void 0);if(m){delete q.width;this.textWidth=u;var k=!0}q&&"ellipsis"===q.textOverflow&&(q.whiteSpace="nowrap",q.overflow="hidden");this.styles=L(this.styles,q);N(this.element,q);k&&this.htmlUpdateTransform();return this},htmlGetBBox:function(){var q=this.element;return{x:q.offsetLeft,
y:q.offsetTop,width:q.offsetWidth,height:q.offsetHeight}},htmlUpdateTransform:function(){if(this.added){var q=this.renderer,m=this.element,u=this.translateX||0,k=this.translateY||0,g=this.x||0,b=this.y||0,f=this.textAlign||"left",a={left:0,center:.5,right:1}[f],c=this.styles,r=c&&c.whiteSpace;N(m,{marginLeft:u,marginTop:k});!q.styledMode&&this.shadows&&this.shadows.forEach(function(a){N(a,{marginLeft:u+1,marginTop:k+1})});this.inverted&&[].forEach.call(m.childNodes,function(a){q.invertChild(a,m)});
if("SPAN"===m.tagName){c=this.rotation;var p=this.textWidth&&E(this.textWidth),I=[c,f,m.innerHTML,this.textWidth,this.textAlign].join(),w;(w=p!==this.oldTextWidth)&&!(w=p>this.oldTextWidth)&&((w=this.textPxLength)||(N(m,{width:"",whiteSpace:r||"nowrap"}),w=m.offsetWidth),w=w>p);w&&(/[ \-]/.test(m.textContent||m.innerText)||"ellipsis"===m.style.textOverflow)?(N(m,{width:p+"px",display:"block",whiteSpace:r||"normal"}),this.oldTextWidth=p,this.hasBoxWidthChanged=!0):this.hasBoxWidthChanged=!1;I!==this.cTT&&
(r=q.fontMetrics(m.style.fontSize,m).b,!H(c)||c===(this.oldRotation||0)&&f===this.oldAlign||this.setSpanRotation(c,a,r),this.getSpanCorrection(!H(c)&&this.textPxLength||m.offsetWidth,r,a,c,f));N(m,{left:g+(this.xCorr||0)+"px",top:b+(this.yCorr||0)+"px"});this.cTT=I;this.oldRotation=c;this.oldAlign=f}}else this.alignOnAdd=!0},setSpanRotation:function(q,m,u){var k={},g=this.renderer.getTransformKey();k[g]=k.transform="rotate("+q+"deg)";k[g+(C?"Origin":"-origin")]=k.transformOrigin=100*m+"% "+u+"px";
N(this.element,k)},getSpanCorrection:function(q,m,u){this.xCorr=-q*u;this.yCorr=-m}});L(e.prototype,{getTransformKey:function(){return J&&!/Edge/.test(z.navigator.userAgent)?"-ms-transform":y?"-webkit-transform":C?"MozTransform":z.opera?"-o-transform":""},html:function(q,m,u){var k=this.createElement("span"),g=k.element,b=k.renderer,f=b.isSVG,a=function(a,b){["opacity","visibility"].forEach(function(c){a[c+"Setter"]=function(f,g,p){var r=a.div?a.div.style:b;A.prototype[c+"Setter"].call(this,f,g,p);
r&&(r[g]=f)}});a.addedSetters=!0};k.textSetter=function(a){a!==g.innerHTML&&(delete this.bBox,delete this.oldTextWidth);this.textStr=a;g.innerHTML=K(a,"");k.doTransform=!0};f&&a(k,k.element.style);k.xSetter=k.ySetter=k.alignSetter=k.rotationSetter=function(a,b){"align"===b&&(b="textAlign");k[b]=a;k.doTransform=!0};k.afterSetters=function(){this.doTransform&&(this.htmlUpdateTransform(),this.doTransform=!1)};k.attr({text:q,x:Math.round(m),y:Math.round(u)}).css({position:"absolute"});b.styledMode||k.css({fontFamily:this.style.fontFamily,
fontSize:this.style.fontSize});g.style.whiteSpace="nowrap";k.css=k.htmlCss;f&&(k.add=function(c){var f=b.box.parentNode,p=[];if(this.parentGroup=c){var I=c.div;if(!I){for(;c;)p.push(c),c=c.parentGroup;p.reverse().forEach(function(c){function b(a,b){c[b]=a;"translateX"===b?r.left=a+"px":r.top=a+"px";c.doTransform=!0}var g=B(c.element,"class");I=c.div=c.div||t("div",g?{className:g}:void 0,{position:"absolute",left:(c.translateX||0)+"px",top:(c.translateY||0)+"px",display:c.display,opacity:c.opacity,
pointerEvents:c.styles&&c.styles.pointerEvents},I||f);var r=I.style;L(c,{classSetter:function(a){return function(c){this.element.setAttribute("class",c);a.className=c}}(I),on:function(){p[0].div&&k.on.apply({element:p[0].div},arguments);return c},translateXSetter:b,translateYSetter:b});c.addedSetters||a(c)})}}else I=f;I.appendChild(g);k.added=!0;k.alignOnAdd&&k.htmlUpdateTransform();return k});return k}})});P(x,"parts/Tick.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.clamp,
t=e.correctFloat,N=e.defined,H=e.destroyObjectProperties,L=e.extend,K=e.fireEvent,E=e.isNumber,C=e.merge,J=e.objectEach,y=e.pick,A=l.deg2rad;e=function(){function z(q,m,u,k,g){this.isNewLabel=this.isNew=!0;this.axis=q;this.pos=m;this.type=u||"";this.parameters=g||{};this.tickmarkOffset=this.parameters.tickmarkOffset;this.options=this.parameters.options;K(this,"init");u||k||this.addLabel()}z.prototype.addLabel=function(){var q=this,m=q.axis,u=m.options,k=m.chart,g=m.categories,b=m.logarithmic,f=m.names,
a=q.pos,c=y(q.options&&q.options.labels,u.labels),r=m.tickPositions,p=a===r[0],I=a===r[r.length-1];f=this.parameters.category||(g?y(g[a],f[a],a):a);var w=q.label;g=(!c.step||1===c.step)&&1===m.tickInterval;r=r.info;var v,n;if(m.dateTime&&r){var F=k.time.resolveDTLFormat(u.dateTimeLabelFormats[!u.grid&&r.higherRanks[a]||r.unitName]);var O=F.main}q.isFirst=p;q.isLast=I;q.formatCtx={axis:m,chart:k,isFirst:p,isLast:I,dateTimeLabelFormat:O,tickPositionInfo:r,value:b?t(b.lin2log(f)):f,pos:a};u=m.labelFormatter.call(q.formatCtx,
this.formatCtx);if(n=F&&F.list)q.shortenLabel=function(){for(v=0;v<n.length;v++)if(w.attr({text:m.labelFormatter.call(L(q.formatCtx,{dateTimeLabelFormat:n[v]}))}),w.getBBox().width<m.getSlotWidth(q)-2*y(c.padding,5))return;w.attr({text:""})};g&&m._addedPlotLB&&m.isXAxis&&q.moveLabel(u,c);N(w)||q.movedLabel?w&&w.textStr!==u&&!g&&(!w.textWidth||c.style&&c.style.width||w.styles.width||w.css({width:null}),w.attr({text:u}),w.textPxLength=w.getBBox().width):(q.label=w=q.createLabel({x:0,y:0},u,c),q.rotation=
0)};z.prototype.createLabel=function(q,m,u){var k=this.axis,g=k.chart;if(q=N(m)&&u.enabled?g.renderer.text(m,q.x,q.y,u.useHTML).add(k.labelGroup):null)g.styledMode||q.css(C(u.style)),q.textPxLength=q.getBBox().width;return q};z.prototype.destroy=function(){H(this,this.axis)};z.prototype.getPosition=function(q,m,u,k){var g=this.axis,b=g.chart,f=k&&b.oldChartHeight||b.chartHeight;q={x:q?t(g.translate(m+u,null,null,k)+g.transB):g.left+g.offset+(g.opposite?(k&&b.oldChartWidth||b.chartWidth)-g.right-g.left:
0),y:q?f-g.bottom+g.offset-(g.opposite?g.height:0):t(f-g.translate(m+u,null,null,k)-g.transB)};q.y=B(q.y,-1E5,1E5);K(this,"afterGetPosition",{pos:q});return q};z.prototype.getLabelPosition=function(q,m,u,k,g,b,f,a){var c=this.axis,r=c.transA,p=c.isLinked&&c.linkedParent?c.linkedParent.reversed:c.reversed,I=c.staggerLines,w=c.tickRotCorr||{x:0,y:0},v=g.y,n=k||c.reserveSpaceDefault?0:-c.labelOffset*("center"===c.labelAlign?.5:1),F={};N(v)||(v=0===c.side?u.rotation?-8:-u.getBBox().height:2===c.side?
w.y+8:Math.cos(u.rotation*A)*(w.y-u.getBBox(!1,0).height/2));q=q+g.x+n+w.x-(b&&k?b*r*(p?-1:1):0);m=m+v-(b&&!k?b*r*(p?1:-1):0);I&&(u=f/(a||1)%I,c.opposite&&(u=I-u-1),m+=c.labelOffset/I*u);F.x=q;F.y=Math.round(m);K(this,"afterGetLabelPosition",{pos:F,tickmarkOffset:b,index:f});return F};z.prototype.getLabelSize=function(){return this.label?this.label.getBBox()[this.axis.horiz?"height":"width"]:0};z.prototype.getMarkPath=function(q,m,u,k,g,b){return b.crispLine([["M",q,m],["L",q+(g?0:-u),m+(g?u:0)]],
k)};z.prototype.handleOverflow=function(q){var m=this.axis,u=m.options.labels,k=q.x,g=m.chart.chartWidth,b=m.chart.spacing,f=y(m.labelLeft,Math.min(m.pos,b[3]));b=y(m.labelRight,Math.max(m.isRadial?0:m.pos+m.len,g-b[1]));var a=this.label,c=this.rotation,r={left:0,center:.5,right:1}[m.labelAlign||a.attr("align")],p=a.getBBox().width,I=m.getSlotWidth(this),w=I,v=1,n,F={};if(c||"justify"!==y(u.overflow,"justify"))0>c&&k-r*p<f?n=Math.round(k/Math.cos(c*A)-f):0<c&&k+r*p>b&&(n=Math.round((g-k)/Math.cos(c*
A)));else if(g=k+(1-r)*p,k-r*p<f?w=q.x+w*(1-r)-f:g>b&&(w=b-q.x+w*r,v=-1),w=Math.min(I,w),w<I&&"center"===m.labelAlign&&(q.x+=v*(I-w-r*(I-Math.min(p,w)))),p>w||m.autoRotation&&(a.styles||{}).width)n=w;n&&(this.shortenLabel?this.shortenLabel():(F.width=Math.floor(n)+"px",(u.style||{}).textOverflow||(F.textOverflow="ellipsis"),a.css(F)))};z.prototype.moveLabel=function(q,m){var u=this,k=u.label,g=!1,b=u.axis,f=b.reversed,a=b.chart.inverted;k&&k.textStr===q?(u.movedLabel=k,g=!0,delete u.label):J(b.ticks,
function(a){g||a.isNew||a===u||!a.label||a.label.textStr!==q||(u.movedLabel=a.label,g=!0,a.labelPos=u.movedLabel.xy,delete a.label)});if(!g&&(u.labelPos||k)){var c=u.labelPos||k.xy;k=a?c.x:f?0:b.width+b.left;b=a?f?b.width+b.left:0:c.y;u.movedLabel=u.createLabel({x:k,y:b},q,m);u.movedLabel&&u.movedLabel.attr({opacity:0})}};z.prototype.render=function(q,m,u){var k=this.axis,g=k.horiz,b=this.pos,f=y(this.tickmarkOffset,k.tickmarkOffset);b=this.getPosition(g,b,f,m);f=b.x;var a=b.y;k=g&&f===k.pos+k.len||
!g&&a===k.pos?-1:1;u=y(u,1);this.isActive=!0;this.renderGridLine(m,u,k);this.renderMark(b,u,k);this.renderLabel(b,m,u,q);this.isNew=!1;K(this,"afterRender")};z.prototype.renderGridLine=function(q,m,u){var k=this.axis,g=k.options,b=this.gridLine,f={},a=this.pos,c=this.type,r=y(this.tickmarkOffset,k.tickmarkOffset),p=k.chart.renderer,I=c?c+"Grid":"grid",w=g[I+"LineWidth"],v=g[I+"LineColor"];g=g[I+"LineDashStyle"];b||(k.chart.styledMode||(f.stroke=v,f["stroke-width"]=w,g&&(f.dashstyle=g)),c||(f.zIndex=
1),q&&(m=0),this.gridLine=b=p.path().attr(f).addClass("highcharts-"+(c?c+"-":"")+"grid-line").add(k.gridGroup));if(b&&(u=k.getPlotLinePath({value:a+r,lineWidth:b.strokeWidth()*u,force:"pass",old:q})))b[q||this.isNew?"attr":"animate"]({d:u,opacity:m})};z.prototype.renderMark=function(q,m,u){var k=this.axis,g=k.options,b=k.chart.renderer,f=this.type,a=f?f+"Tick":"tick",c=k.tickSize(a),r=this.mark,p=!r,I=q.x;q=q.y;var w=y(g[a+"Width"],!f&&k.isXAxis?1:0);g=g[a+"Color"];c&&(k.opposite&&(c[0]=-c[0]),p&&
(this.mark=r=b.path().addClass("highcharts-"+(f?f+"-":"")+"tick").add(k.axisGroup),k.chart.styledMode||r.attr({stroke:g,"stroke-width":w})),r[p?"attr":"animate"]({d:this.getMarkPath(I,q,c[0],r.strokeWidth()*u,k.horiz,b),opacity:m}))};z.prototype.renderLabel=function(q,m,u,k){var g=this.axis,b=g.horiz,f=g.options,a=this.label,c=f.labels,r=c.step;g=y(this.tickmarkOffset,g.tickmarkOffset);var p=!0,I=q.x;q=q.y;a&&E(I)&&(a.xy=q=this.getLabelPosition(I,q,a,b,c,g,k,r),this.isFirst&&!this.isLast&&!y(f.showFirstLabel,
1)||this.isLast&&!this.isFirst&&!y(f.showLastLabel,1)?p=!1:!b||c.step||c.rotation||m||0===u||this.handleOverflow(q),r&&k%r&&(p=!1),p&&E(q.y)?(q.opacity=u,a[this.isNewLabel?"attr":"animate"](q),this.isNewLabel=!1):(a.attr("y",-9999),this.isNewLabel=!0))};z.prototype.replaceMovedLabel=function(){var q=this.label,m=this.axis,u=m.reversed,k=this.axis.chart.inverted;if(q&&!this.isNew){var g=k?q.xy.x:u?m.left:m.width+m.left;u=k?u?m.width+m.top:m.top:q.xy.y;q.animate({x:g,y:u,opacity:0},void 0,q.destroy);
delete this.label}m.isDirty=!0;this.label=this.movedLabel;delete this.movedLabel};return z}();l.Tick=e;return l.Tick});P(x,"parts/Time.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.defined,t=e.error,N=e.extend,H=e.isObject,L=e.merge,K=e.objectEach,E=e.pad,C=e.pick,J=e.splat,y=e.timeUnits,A=l.win;e=function(){function z(q){this.options={};this.variableTimezone=this.useUTC=!1;this.Date=A.Date;this.getTimezoneOffset=this.timezoneOffsetFunction();this.update(q)}z.prototype.get=
function(q,m){if(this.variableTimezone||this.timezoneOffset){var u=m.getTime(),k=u-this.getTimezoneOffset(m);m.setTime(k);q=m["getUTC"+q]();m.setTime(u);return q}return this.useUTC?m["getUTC"+q]():m["get"+q]()};z.prototype.set=function(q,m,u){if(this.variableTimezone||this.timezoneOffset){if("Milliseconds"===q||"Seconds"===q||"Minutes"===q)return m["setUTC"+q](u);var k=this.getTimezoneOffset(m);k=m.getTime()-k;m.setTime(k);m["setUTC"+q](u);q=this.getTimezoneOffset(m);k=m.getTime()+q;return m.setTime(k)}return this.useUTC?
m["setUTC"+q](u):m["set"+q](u)};z.prototype.update=function(q){var m=C(q&&q.useUTC,!0);this.options=q=L(!0,this.options||{},q);this.Date=q.Date||A.Date||Date;this.timezoneOffset=(this.useUTC=m)&&q.timezoneOffset;this.getTimezoneOffset=this.timezoneOffsetFunction();this.variableTimezone=!(m&&!q.getTimezoneOffset&&!q.timezone)};z.prototype.makeTime=function(q,m,u,k,g,b){if(this.useUTC){var f=this.Date.UTC.apply(0,arguments);var a=this.getTimezoneOffset(f);f+=a;var c=this.getTimezoneOffset(f);a!==c?
f+=c-a:a-36E5!==this.getTimezoneOffset(f-36E5)||l.isSafari||(f-=36E5)}else f=(new this.Date(q,m,C(u,1),C(k,0),C(g,0),C(b,0))).getTime();return f};z.prototype.timezoneOffsetFunction=function(){var q=this,m=this.options,u=A.moment;if(!this.useUTC)return function(k){return 6E4*(new Date(k.toString())).getTimezoneOffset()};if(m.timezone){if(u)return function(k){return 6E4*-u.tz(k,m.timezone).utcOffset()};t(25)}return this.useUTC&&m.getTimezoneOffset?function(k){return 6E4*m.getTimezoneOffset(k.valueOf())}:
function(){return 6E4*(q.timezoneOffset||0)}};z.prototype.dateFormat=function(q,m,u){var k;if(!B(m)||isNaN(m))return(null===(k=l.defaultOptions.lang)||void 0===k?void 0:k.invalidDate)||"";q=C(q,"%Y-%m-%d %H:%M:%S");var g=this;k=new this.Date(m);var b=this.get("Hours",k),f=this.get("Day",k),a=this.get("Date",k),c=this.get("Month",k),r=this.get("FullYear",k),p=l.defaultOptions.lang,I=null===p||void 0===p?void 0:p.weekdays,w=null===p||void 0===p?void 0:p.shortWeekdays;k=N({a:w?w[f]:I[f].substr(0,3),
A:I[f],d:E(a),e:E(a,2," "),w:f,b:p.shortMonths[c],B:p.months[c],m:E(c+1),o:c+1,y:r.toString().substr(2,2),Y:r,H:E(b),k:b,I:E(b%12||12),l:b%12||12,M:E(this.get("Minutes",k)),p:12>b?"AM":"PM",P:12>b?"am":"pm",S:E(k.getSeconds()),L:E(Math.floor(m%1E3),3)},l.dateFormats);K(k,function(a,c){for(;-1!==q.indexOf("%"+c);)q=q.replace("%"+c,"function"===typeof a?a.call(g,m):a)});return u?q.substr(0,1).toUpperCase()+q.substr(1):q};z.prototype.resolveDTLFormat=function(q){return H(q,!0)?q:(q=J(q),{main:q[0],from:q[1],
to:q[2]})};z.prototype.getTimeTicks=function(q,m,u,k){var g=this,b=[],f={};var a=new g.Date(m);var c=q.unitRange,r=q.count||1,p;k=C(k,1);if(B(m)){g.set("Milliseconds",a,c>=y.second?0:r*Math.floor(g.get("Milliseconds",a)/r));c>=y.second&&g.set("Seconds",a,c>=y.minute?0:r*Math.floor(g.get("Seconds",a)/r));c>=y.minute&&g.set("Minutes",a,c>=y.hour?0:r*Math.floor(g.get("Minutes",a)/r));c>=y.hour&&g.set("Hours",a,c>=y.day?0:r*Math.floor(g.get("Hours",a)/r));c>=y.day&&g.set("Date",a,c>=y.month?1:Math.max(1,
r*Math.floor(g.get("Date",a)/r)));if(c>=y.month){g.set("Month",a,c>=y.year?0:r*Math.floor(g.get("Month",a)/r));var I=g.get("FullYear",a)}c>=y.year&&g.set("FullYear",a,I-I%r);c===y.week&&(I=g.get("Day",a),g.set("Date",a,g.get("Date",a)-I+k+(I<k?-7:0)));I=g.get("FullYear",a);k=g.get("Month",a);var w=g.get("Date",a),v=g.get("Hours",a);m=a.getTime();g.variableTimezone&&(p=u-m>4*y.month||g.getTimezoneOffset(m)!==g.getTimezoneOffset(u));m=a.getTime();for(a=1;m<u;)b.push(m),m=c===y.year?g.makeTime(I+a*r,
0):c===y.month?g.makeTime(I,k+a*r):!p||c!==y.day&&c!==y.week?p&&c===y.hour&&1<r?g.makeTime(I,k,w,v+a*r):m+c*r:g.makeTime(I,k,w+a*r*(c===y.day?1:7)),a++;b.push(m);c<=y.hour&&1E4>b.length&&b.forEach(function(a){0===a%18E5&&"000000000"===g.dateFormat("%H%M%S%L",a)&&(f[a]="day")})}b.info=N(q,{higherRanks:f,totalRange:c*r});return b};z.defaultOptions={Date:void 0,getTimezoneOffset:void 0,timezone:void 0,timezoneOffset:0,useUTC:!0};return z}();l.Time=e;return l.Time});P(x,"parts/Options.js",[x["parts/Globals.js"],
x["parts/Time.js"],x["parts/Color.js"],x["parts/Utilities.js"]],function(l,e,B,t){B=B.parse;var N=t.merge;l.defaultOptions={colors:"#7cb5ec #434348 #90ed7d #f7a35c #8085e9 #f15c80 #e4d354 #2b908f #f45b5b #91e8e1".split(" "),symbols:["circle","diamond","square","triangle","triangle-down"],lang:{loading:"Loading...",months:"January February March April May June July August September October November December".split(" "),shortMonths:"Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec".split(" "),weekdays:"Sunday Monday Tuesday Wednesday Thursday Friday Saturday".split(" "),
decimalPoint:".",numericSymbols:"kMGTPE".split(""),resetZoom:"Reset zoom",resetZoomTitle:"Reset zoom level 1:1",thousandsSep:" "},global:{},time:e.defaultOptions,chart:{styledMode:!1,borderRadius:0,colorCount:10,defaultSeriesType:"line",ignoreHiddenSeries:!0,spacing:[10,10,15,10],resetZoomButton:{theme:{zIndex:6},position:{align:"right",x:-10,y:10}},width:null,height:null,borderColor:"#335cad",backgroundColor:"#ffffff",plotBorderColor:"#cccccc"},title:{text:"Chart title",align:"center",margin:15,
widthAdjust:-44},subtitle:{text:"",align:"center",widthAdjust:-44},caption:{margin:15,text:"",align:"left",verticalAlign:"bottom"},plotOptions:{},labels:{style:{position:"absolute",color:"#333333"}},legend:{enabled:!0,align:"center",alignColumns:!0,layout:"horizontal",labelFormatter:function(){return this.name},borderColor:"#999999",borderRadius:0,navigation:{activeColor:"#003399",inactiveColor:"#cccccc"},itemStyle:{color:"#333333",cursor:"pointer",fontSize:"12px",fontWeight:"bold",textOverflow:"ellipsis"},
itemHoverStyle:{color:"#000000"},itemHiddenStyle:{color:"#cccccc"},shadow:!1,itemCheckboxStyle:{position:"absolute",width:"13px",height:"13px"},squareSymbol:!0,symbolPadding:5,verticalAlign:"bottom",x:0,y:0,title:{style:{fontWeight:"bold"}}},loading:{labelStyle:{fontWeight:"bold",position:"relative",top:"45%"},style:{position:"absolute",backgroundColor:"#ffffff",opacity:.5,textAlign:"center"}},tooltip:{enabled:!0,animation:l.svg,borderRadius:3,dateTimeLabelFormats:{millisecond:"%A, %b %e, %H:%M:%S.%L",
second:"%A, %b %e, %H:%M:%S",minute:"%A, %b %e, %H:%M",hour:"%A, %b %e, %H:%M",day:"%A, %b %e, %Y",week:"Week from %A, %b %e, %Y",month:"%B %Y",year:"%Y"},footerFormat:"",padding:8,snap:l.isTouchDevice?25:10,headerFormat:'<span style="font-size: 10px">{point.key}</span><br/>',pointFormat:'<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.y}</b><br/>',backgroundColor:B("#f7f7f7").setOpacity(.85).get(),borderWidth:1,shadow:!0,style:{color:"#333333",cursor:"default",fontSize:"12px",
whiteSpace:"nowrap"}},credits:{enabled:!0,href:"https://www.highcharts.com?credits",position:{align:"right",x:-10,verticalAlign:"bottom",y:-5},style:{cursor:"pointer",color:"#999999",fontSize:"9px"},text:"Highcharts.com"}};l.setOptions=function(e){l.defaultOptions=N(!0,l.defaultOptions,e);(e.time||e.global)&&l.time.update(N(l.defaultOptions.global,l.defaultOptions.time,e.global,e.time));return l.defaultOptions};l.getOptions=function(){return l.defaultOptions};l.defaultPlotOptions=l.defaultOptions.plotOptions;
l.time=new e(N(l.defaultOptions.global,l.defaultOptions.time));l.dateFormat=function(e,t,K){return l.time.dateFormat(e,t,K)};""});P(x,"parts/Axis.js",[x["parts/Color.js"],x["parts/Globals.js"],x["parts/Tick.js"],x["parts/Utilities.js"]],function(l,e,B,t){var N=t.addEvent,H=t.animObject,L=t.arrayMax,K=t.arrayMin,E=t.clamp,C=t.correctFloat,J=t.defined,y=t.destroyObjectProperties,A=t.error,z=t.extend,q=t.fireEvent,m=t.format,u=t.getMagnitude,k=t.isArray,g=t.isFunction,b=t.isNumber,f=t.isString,a=t.merge,
c=t.normalizeTickInterval,r=t.objectEach,p=t.pick,I=t.relativeLength,w=t.removeEvent,v=t.splat,n=t.syncTimeout,F=e.defaultOptions,O=e.deg2rad;t=function(){function D(h,d){this.zoomEnabled=this.width=this.visible=this.userOptions=this.translationSlope=this.transB=this.transA=this.top=this.ticks=this.tickRotCorr=this.tickPositions=this.tickmarkOffset=this.tickInterval=this.tickAmount=this.side=this.series=this.right=this.positiveValuesOnly=this.pos=this.pointRangePadding=this.pointRange=this.plotLinesAndBandsGroups=
this.plotLinesAndBands=this.paddedTicks=this.overlap=this.options=this.oldMin=this.oldMax=this.offset=this.names=this.minPixelPadding=this.minorTicks=this.minorTickInterval=this.min=this.maxLabelLength=this.max=this.len=this.left=this.labelFormatter=this.labelEdge=this.isLinked=this.height=this.hasVisibleSeries=this.hasNames=this.coll=this.closestPointRange=this.chart=this.categories=this.bottom=this.alternateBands=void 0;this.init(h,d)}D.prototype.init=function(h,d){var a=d.isX,c=this;c.chart=h;
c.horiz=h.inverted&&!c.isZAxis?!a:a;c.isXAxis=a;c.coll=c.coll||(a?"xAxis":"yAxis");q(this,"init",{userOptions:d});c.opposite=d.opposite;c.side=d.side||(c.horiz?c.opposite?0:2:c.opposite?1:3);c.setOptions(d);var b=this.options,f=b.type;c.labelFormatter=b.labels.formatter||c.defaultLabelFormatter;c.userOptions=d;c.minPixelPadding=0;c.reversed=b.reversed;c.visible=!1!==b.visible;c.zoomEnabled=!1!==b.zoomEnabled;c.hasNames="category"===f||!0===b.categories;c.categories=b.categories||c.hasNames;c.names||
(c.names=[],c.names.keys={});c.plotLinesAndBandsGroups={};c.positiveValuesOnly=!(!c.logarithmic||b.allowNegativeLog);c.isLinked=J(b.linkedTo);c.ticks={};c.labelEdge=[];c.minorTicks={};c.plotLinesAndBands=[];c.alternateBands={};c.len=0;c.minRange=c.userMinRange=b.minRange||b.maxZoom;c.range=b.range;c.offset=b.offset||0;c.max=null;c.min=null;c.crosshair=p(b.crosshair,v(h.options.tooltip.crosshairs)[a?0:1],!1);d=c.options.events;-1===h.axes.indexOf(c)&&(a?h.axes.splice(h.xAxis.length,0,c):h.axes.push(c),
h[c.coll].push(c));c.series=c.series||[];h.inverted&&!c.isZAxis&&a&&"undefined"===typeof c.reversed&&(c.reversed=!0);c.labelRotation=c.options.labels.rotation;r(d,function(d,h){g(d)&&N(c,h,d)});q(this,"afterInit")};D.prototype.setOptions=function(h){this.options=a(D.defaultOptions,"yAxis"===this.coll&&D.defaultYAxisOptions,[D.defaultTopAxisOptions,D.defaultRightAxisOptions,D.defaultBottomAxisOptions,D.defaultLeftAxisOptions][this.side],a(F[this.coll],h));q(this,"afterSetOptions",{userOptions:h})};
D.prototype.defaultLabelFormatter=function(){var h=this.axis,d=this.value,a=h.chart.time,c=h.categories,b=this.dateTimeLabelFormat,f=F.lang,g=f.numericSymbols;f=f.numericSymbolMagnitude||1E3;var p=g&&g.length,r=h.options.labels.format;h=h.logarithmic?Math.abs(d):h.tickInterval;var k=this.chart,n=k.numberFormatter;if(r)var w=m(r,this,k);else if(c)w=d;else if(b)w=a.dateFormat(b,d);else if(p&&1E3<=h)for(;p--&&"undefined"===typeof w;)a=Math.pow(f,p+1),h>=a&&0===10*d%a&&null!==g[p]&&0!==d&&(w=n(d/a,-1)+
g[p]);"undefined"===typeof w&&(w=1E4<=Math.abs(d)?n(d,-1):n(d,-1,void 0,""));return w};D.prototype.getSeriesExtremes=function(){var h=this,d=h.chart,a;q(this,"getSeriesExtremes",null,function(){h.hasVisibleSeries=!1;h.dataMin=h.dataMax=h.threshold=null;h.softThreshold=!h.isXAxis;h.stacking&&h.stacking.buildStacks();h.series.forEach(function(c){if(c.visible||!d.options.chart.ignoreHiddenSeries){var f=c.options,g=f.threshold;h.hasVisibleSeries=!0;h.positiveValuesOnly&&0>=g&&(g=null);if(h.isXAxis){if(f=
c.xData,f.length){a=c.getXExtremes(f);var r=a.min;var G=a.max;b(r)||r instanceof Date||(f=f.filter(b),a=c.getXExtremes(f),r=a.min,G=a.max);f.length&&(h.dataMin=Math.min(p(h.dataMin,r),r),h.dataMax=Math.max(p(h.dataMax,G),G))}}else if(c=c.applyExtremes(),b(c.dataMin)&&(r=c.dataMin,h.dataMin=Math.min(p(h.dataMin,r),r)),b(c.dataMax)&&(G=c.dataMax,h.dataMax=Math.max(p(h.dataMax,G),G)),J(g)&&(h.threshold=g),!f.softThreshold||h.positiveValuesOnly)h.softThreshold=!1}})});q(this,"afterGetSeriesExtremes")};
D.prototype.translate=function(h,d,a,c,f,g){var p=this.linkedParent||this,r=1,G=0,k=c?p.oldTransA:p.transA;c=c?p.oldMin:p.min;var n=p.minPixelPadding;f=(p.isOrdinal||p.brokenAxis&&p.brokenAxis.hasBreaks||p.logarithmic&&f)&&p.lin2val;k||(k=p.transA);a&&(r*=-1,G=p.len);p.reversed&&(r*=-1,G-=r*(p.sector||p.len));d?(h=(h*r+G-n)/k+c,f&&(h=p.lin2val(h))):(f&&(h=p.val2lin(h)),h=b(c)?r*(h-c)*k+G+r*n+(b(g)?k*g:0):void 0);return h};D.prototype.toPixels=function(h,d){return this.translate(h,!1,!this.horiz,null,
!0)+(d?0:this.pos)};D.prototype.toValue=function(h,d){return this.translate(h-(d?0:this.pos),!0,!this.horiz,null,!0)};D.prototype.getPlotLinePath=function(h){function d(d,h,a){if("pass"!==v&&d<h||d>a)v?d=E(d,h,a):z=!0;return d}var a=this,c=a.chart,f=a.left,g=a.top,r=h.old,k=h.value,n=h.translatedValue,w=h.lineWidth,v=h.force,F,I,m,D,O=r&&c.oldChartHeight||c.chartHeight,u=r&&c.oldChartWidth||c.chartWidth,z,e=a.transB;h={value:k,lineWidth:w,old:r,force:v,acrossPanes:h.acrossPanes,translatedValue:n};
q(this,"getPlotLinePath",h,function(h){n=p(n,a.translate(k,null,null,r));n=E(n,-1E5,1E5);F=m=Math.round(n+e);I=D=Math.round(O-n-e);b(n)?a.horiz?(I=g,D=O-a.bottom,F=m=d(F,f,f+a.width)):(F=f,m=u-a.right,I=D=d(I,g,g+a.height)):(z=!0,v=!1);h.path=z&&!v?null:c.renderer.crispLine([["M",F,I],["L",m,D]],w||1)});return h.path};D.prototype.getLinearTickPositions=function(h,d,a){var c=C(Math.floor(d/h)*h);a=C(Math.ceil(a/h)*h);var b=[],f;C(c+h)===c&&(f=20);if(this.single)return[d];for(d=c;d<=a;){b.push(d);d=
C(d+h,f);if(d===g)break;var g=d}return b};D.prototype.getMinorTickInterval=function(){var h=this.options;return!0===h.minorTicks?p(h.minorTickInterval,"auto"):!1===h.minorTicks?null:h.minorTickInterval};D.prototype.getMinorTickPositions=function(){var h=this.options,d=this.tickPositions,a=this.minorTickInterval,c=[],b=this.pointRangePadding||0,f=this.min-b;b=this.max+b;var g=b-f;if(g&&g/a<this.len/3){var p=this.logarithmic;if(p)this.paddedTicks.forEach(function(d,h,b){h&&c.push.apply(c,p.getLogTickPositions(a,
b[h-1],b[h],!0))});else if(this.dateTime&&"auto"===this.getMinorTickInterval())c=c.concat(this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(a),f,b,h.startOfWeek));else for(h=f+(d[0]-f)%a;h<=b&&h!==c[0];h+=a)c.push(h)}0!==c.length&&this.trimTicks(c);return c};D.prototype.adjustForMinRange=function(){var h=this.options,d=this.min,a=this.max,c=this.logarithmic,b,f,g,r,k;this.isXAxis&&"undefined"===typeof this.minRange&&!c&&(J(h.min)||J(h.max)?this.minRange=null:(this.series.forEach(function(d){r=
d.xData;for(f=k=d.xIncrement?1:r.length-1;0<f;f--)if(g=r[f]-r[f-1],"undefined"===typeof b||g<b)b=g}),this.minRange=Math.min(5*b,this.dataMax-this.dataMin)));if(a-d<this.minRange){var n=this.dataMax-this.dataMin>=this.minRange;var w=this.minRange;var v=(w-a+d)/2;v=[d-v,p(h.min,d-v)];n&&(v[2]=this.logarithmic?this.logarithmic.log2lin(this.dataMin):this.dataMin);d=L(v);a=[d+w,p(h.max,d+w)];n&&(a[2]=c?c.log2lin(this.dataMax):this.dataMax);a=K(a);a-d<w&&(v[0]=a-w,v[1]=p(h.min,a-w),d=L(v))}this.min=d;this.max=
a};D.prototype.getClosest=function(){var a;this.categories?a=1:this.series.forEach(function(d){var h=d.closestPointRange,c=d.visible||!d.chart.options.chart.ignoreHiddenSeries;!d.noSharedTooltip&&J(h)&&c&&(a=J(a)?Math.min(a,h):h)});return a};D.prototype.nameToX=function(a){var d=k(this.categories),h=d?this.categories:this.names,c=a.options.x;a.series.requireSorting=!1;J(c)||(c=!1===this.options.uniqueNames?a.series.autoIncrement():d?h.indexOf(a.name):p(h.keys[a.name],-1));if(-1===c){if(!d)var b=h.length}else b=
c;"undefined"!==typeof b&&(this.names[b]=a.name,this.names.keys[a.name]=b);return b};D.prototype.updateNames=function(){var a=this,d=this.names;0<d.length&&(Object.keys(d.keys).forEach(function(a){delete d.keys[a]}),d.length=0,this.minRange=this.userMinRange,(this.series||[]).forEach(function(d){d.xIncrement=null;if(!d.points||d.isDirtyData)a.max=Math.max(a.max,d.xData.length-1),d.processData(),d.generatePoints();d.data.forEach(function(h,c){if(h&&h.options&&"undefined"!==typeof h.name){var b=a.nameToX(h);
"undefined"!==typeof b&&b!==h.x&&(h.x=b,d.xData[c]=b)}})}))};D.prototype.setAxisTranslation=function(a){var d=this,h=d.max-d.min,c=d.axisPointRange||0,b=0,g=0,r=d.linkedParent,k=!!d.categories,n=d.transA,w=d.isXAxis;if(w||k||c){var v=d.getClosest();r?(b=r.minPointOffset,g=r.pointRangePadding):d.series.forEach(function(a){var h=k?1:w?p(a.options.pointRange,v,0):d.axisPointRange||0,r=a.options.pointPlacement;c=Math.max(c,h);if(!d.single||k)a=a.is("xrange")?!w:w,b=Math.max(b,a&&f(r)?0:h/2),g=Math.max(g,
a&&"on"===r?0:h)});r=d.ordinal&&d.ordinal.slope&&v?d.ordinal.slope/v:1;d.minPointOffset=b*=r;d.pointRangePadding=g*=r;d.pointRange=Math.min(c,d.single&&k?1:h);w&&(d.closestPointRange=v)}a&&(d.oldTransA=n);d.translationSlope=d.transA=n=d.staticScale||d.len/(h+g||1);d.transB=d.horiz?d.left:d.bottom;d.minPixelPadding=n*b;q(this,"afterSetAxisTranslation")};D.prototype.minFromRange=function(){return this.max-this.range};D.prototype.setTickInterval=function(a){var d=this,h=d.chart,f=d.logarithmic,g=d.options,
r=d.isXAxis,k=d.isLinked,n=g.maxPadding,w=g.minPadding,v=g.tickInterval,F=g.tickPixelInterval,I=d.categories,m=b(d.threshold)?d.threshold:null,D=d.softThreshold;d.dateTime||I||k||this.getTickAmount();var O=p(d.userMin,g.min);var z=p(d.userMax,g.max);if(k){d.linkedParent=h[d.coll][g.linkedTo];var e=d.linkedParent.getExtremes();d.min=p(e.min,e.dataMin);d.max=p(e.max,e.dataMax);g.type!==d.linkedParent.options.type&&A(11,1,h)}else{if(!D&&J(m))if(d.dataMin>=m)e=m,w=0;else if(d.dataMax<=m){var l=m;n=0}d.min=
p(O,e,d.dataMin);d.max=p(z,l,d.dataMax)}f&&(d.positiveValuesOnly&&!a&&0>=Math.min(d.min,p(d.dataMin,d.min))&&A(10,1,h),d.min=C(f.log2lin(d.min),16),d.max=C(f.log2lin(d.max),16));d.range&&J(d.max)&&(d.userMin=d.min=O=Math.max(d.dataMin,d.minFromRange()),d.userMax=z=d.max,d.range=null);q(d,"foundExtremes");d.beforePadding&&d.beforePadding();d.adjustForMinRange();!(I||d.axisPointRange||d.stacking&&d.stacking.usePercentage||k)&&J(d.min)&&J(d.max)&&(h=d.max-d.min)&&(!J(O)&&w&&(d.min-=h*w),!J(z)&&n&&(d.max+=
h*n));b(d.userMin)||(b(g.softMin)&&g.softMin<d.min&&(d.min=O=g.softMin),b(g.floor)&&(d.min=Math.max(d.min,g.floor)));b(d.userMax)||(b(g.softMax)&&g.softMax>d.max&&(d.max=z=g.softMax),b(g.ceiling)&&(d.max=Math.min(d.max,g.ceiling)));D&&J(d.dataMin)&&(m=m||0,!J(O)&&d.min<m&&d.dataMin>=m?d.min=d.options.minRange?Math.min(m,d.max-d.minRange):m:!J(z)&&d.max>m&&d.dataMax<=m&&(d.max=d.options.minRange?Math.max(m,d.min+d.minRange):m));d.tickInterval=d.min===d.max||"undefined"===typeof d.min||"undefined"===
typeof d.max?1:k&&!v&&F===d.linkedParent.options.tickPixelInterval?v=d.linkedParent.tickInterval:p(v,this.tickAmount?(d.max-d.min)/Math.max(this.tickAmount-1,1):void 0,I?1:(d.max-d.min)*F/Math.max(d.len,F));r&&!a&&d.series.forEach(function(a){a.processData(d.min!==d.oldMin||d.max!==d.oldMax)});d.setAxisTranslation(!0);d.beforeSetTickPositions&&d.beforeSetTickPositions();d.ordinal&&(d.tickInterval=d.ordinal.postProcessTickInterval(d.tickInterval));d.pointRange&&!v&&(d.tickInterval=Math.max(d.pointRange,
d.tickInterval));a=p(g.minTickInterval,d.dateTime&&d.closestPointRange);!v&&d.tickInterval<a&&(d.tickInterval=a);d.dateTime||d.logarithmic||v||(d.tickInterval=c(d.tickInterval,void 0,u(d.tickInterval),p(g.allowDecimals,.5>d.tickInterval||void 0!==this.tickAmount),!!this.tickAmount));this.tickAmount||(d.tickInterval=d.unsquish());this.setTickPositions()};D.prototype.setTickPositions=function(){var a=this.options,d=a.tickPositions;var c=this.getMinorTickInterval();var b=a.tickPositioner,f=this.hasVerticalPanning(),
g="colorAxis"===this.coll,p=(g||!f)&&a.startOnTick;f=(g||!f)&&a.endOnTick;this.tickmarkOffset=this.categories&&"between"===a.tickmarkPlacement&&1===this.tickInterval?.5:0;this.minorTickInterval="auto"===c&&this.tickInterval?this.tickInterval/5:c;this.single=this.min===this.max&&J(this.min)&&!this.tickAmount&&(parseInt(this.min,10)===this.min||!1!==a.allowDecimals);this.tickPositions=c=d&&d.slice();!c&&(this.ordinal&&this.ordinal.positions||!((this.max-this.min)/this.tickInterval>Math.max(2*this.len,
200))?c=this.dateTime?this.getTimeTicks(this.dateTime.normalizeTimeTickInterval(this.tickInterval,a.units),this.min,this.max,a.startOfWeek,this.ordinal&&this.ordinal.positions,this.closestPointRange,!0):this.logarithmic?this.logarithmic.getLogTickPositions(this.tickInterval,this.min,this.max):this.getLinearTickPositions(this.tickInterval,this.min,this.max):(c=[this.min,this.max],A(19,!1,this.chart)),c.length>this.len&&(c=[c[0],c.pop()],c[0]===c[1]&&(c.length=1)),this.tickPositions=c,b&&(b=b.apply(this,
[this.min,this.max])))&&(this.tickPositions=c=b);this.paddedTicks=c.slice(0);this.trimTicks(c,p,f);this.isLinked||(this.single&&2>c.length&&!this.categories&&!this.series.some(function(d){return d.is("heatmap")&&"between"===d.options.pointPlacement})&&(this.min-=.5,this.max+=.5),d||b||this.adjustTickAmount());q(this,"afterSetTickPositions")};D.prototype.trimTicks=function(a,d,c){var h=a[0],b=a[a.length-1],f=!this.isOrdinal&&this.minPointOffset||0;q(this,"trimTicks");if(!this.isLinked){if(d&&-Infinity!==
h)this.min=h;else for(;this.min-f>a[0];)a.shift();if(c)this.max=b;else for(;this.max+f<a[a.length-1];)a.pop();0===a.length&&J(h)&&!this.options.tickPositions&&a.push((b+h)/2)}};D.prototype.alignToOthers=function(){var a={},d,c=this.options;!1===this.chart.options.chart.alignTicks||!1===c.alignTicks||!1===c.startOnTick||!1===c.endOnTick||this.logarithmic||this.chart[this.coll].forEach(function(h){var c=h.options;c=[h.horiz?c.left:c.top,c.width,c.height,c.pane].join();h.series.length&&(a[c]?d=!0:a[c]=
1)});return d};D.prototype.getTickAmount=function(){var a=this.options,d=a.tickAmount,c=a.tickPixelInterval;!J(a.tickInterval)&&!d&&this.len<c&&!this.isRadial&&!this.logarithmic&&a.startOnTick&&a.endOnTick&&(d=2);!d&&this.alignToOthers()&&(d=Math.ceil(this.len/c)+1);4>d&&(this.finalTickAmt=d,d=5);this.tickAmount=d};D.prototype.adjustTickAmount=function(){var a=this.options,d=this.tickInterval,c=this.tickPositions,b=this.tickAmount,f=this.finalTickAmt,g=c&&c.length,r=p(this.threshold,this.softThreshold?
0:null),k;if(this.hasData()){if(g<b){for(k=this.min;c.length<b;)c.length%2||k===r?c.push(C(c[c.length-1]+d)):c.unshift(C(c[0]-d));this.transA*=(g-1)/(b-1);this.min=a.startOnTick?c[0]:Math.min(this.min,c[0]);this.max=a.endOnTick?c[c.length-1]:Math.max(this.max,c[c.length-1])}else g>b&&(this.tickInterval*=2,this.setTickPositions());if(J(f)){for(d=a=c.length;d--;)(3===f&&1===d%2||2>=f&&0<d&&d<a-1)&&c.splice(d,1);this.finalTickAmt=void 0}}};D.prototype.setScale=function(){var a,d=!1,c=!1;this.series.forEach(function(a){var h;
d=d||a.isDirtyData||a.isDirty;c=c||(null===(h=a.xAxis)||void 0===h?void 0:h.isDirty)||!1});this.oldMin=this.min;this.oldMax=this.max;this.oldAxisLength=this.len;this.setAxisSize();(a=this.len!==this.oldAxisLength)||d||c||this.isLinked||this.forceRedraw||this.userMin!==this.oldUserMin||this.userMax!==this.oldUserMax||this.alignToOthers()?(this.stacking&&this.stacking.resetStacks(),this.forceRedraw=!1,this.getSeriesExtremes(),this.setTickInterval(),this.oldUserMin=this.userMin,this.oldUserMax=this.userMax,
this.isDirty||(this.isDirty=a||this.min!==this.oldMin||this.max!==this.oldMax)):this.stacking&&this.stacking.cleanStacks();d&&this.panningState&&(this.panningState.isDirty=!0);q(this,"afterSetScale")};D.prototype.setExtremes=function(a,d,c,b,f){var h=this,g=h.chart;c=p(c,!0);h.series.forEach(function(d){delete d.kdTree});f=z(f,{min:a,max:d});q(h,"setExtremes",f,function(){h.userMin=a;h.userMax=d;h.eventArgs=f;c&&g.redraw(b)})};D.prototype.zoom=function(a,d){var h=this,c=this.dataMin,b=this.dataMax,
f=this.options,g=Math.min(c,p(f.min,c)),r=Math.max(b,p(f.max,b));a={newMin:a,newMax:d};q(this,"zoom",a,function(d){var a=d.newMin,f=d.newMax;if(a!==h.min||f!==h.max)h.allowZoomOutside||(J(c)&&(a<g&&(a=g),a>r&&(a=r)),J(b)&&(f<g&&(f=g),f>r&&(f=r))),h.displayBtn="undefined"!==typeof a||"undefined"!==typeof f,h.setExtremes(a,f,!1,void 0,{trigger:"zoom"});d.zoomed=!0});return a.zoomed};D.prototype.setAxisSize=function(){var a=this.chart,d=this.options,c=d.offsets||[0,0,0,0],b=this.horiz,f=this.width=Math.round(I(p(d.width,
a.plotWidth-c[3]+c[1]),a.plotWidth)),g=this.height=Math.round(I(p(d.height,a.plotHeight-c[0]+c[2]),a.plotHeight)),r=this.top=Math.round(I(p(d.top,a.plotTop+c[0]),a.plotHeight,a.plotTop));d=this.left=Math.round(I(p(d.left,a.plotLeft+c[3]),a.plotWidth,a.plotLeft));this.bottom=a.chartHeight-g-r;this.right=a.chartWidth-f-d;this.len=Math.max(b?f:g,0);this.pos=b?d:r};D.prototype.getExtremes=function(){var a=this.logarithmic;return{min:a?C(a.lin2log(this.min)):this.min,max:a?C(a.lin2log(this.max)):this.max,
dataMin:this.dataMin,dataMax:this.dataMax,userMin:this.userMin,userMax:this.userMax}};D.prototype.getThreshold=function(a){var d=this.logarithmic,h=d?d.lin2log(this.min):this.min;d=d?d.lin2log(this.max):this.max;null===a||-Infinity===a?a=h:Infinity===a?a=d:h>a?a=h:d<a&&(a=d);return this.translate(a,0,1,0,1)};D.prototype.autoLabelAlign=function(a){var d=(p(a,0)-90*this.side+720)%360;a={align:"center"};q(this,"autoLabelAlign",a,function(a){15<d&&165>d?a.align="right":195<d&&345>d&&(a.align="left")});
return a.align};D.prototype.tickSize=function(a){var d=this.options,h=d["tick"===a?"tickLength":"minorTickLength"],c=p(d["tick"===a?"tickWidth":"minorTickWidth"],"tick"===a&&this.isXAxis&&!this.categories?1:0);if(c&&h){"inside"===d[a+"Position"]&&(h=-h);var b=[h,c]}a={tickSize:b};q(this,"afterTickSize",a);return a.tickSize};D.prototype.labelMetrics=function(){var a=this.tickPositions&&this.tickPositions[0]||0;return this.chart.renderer.fontMetrics(this.options.labels.style&&this.options.labels.style.fontSize,
this.ticks[a]&&this.ticks[a].label)};D.prototype.unsquish=function(){var a=this.options.labels,d=this.horiz,c=this.tickInterval,b=c,f=this.len/(((this.categories?1:0)+this.max-this.min)/c),g,r=a.rotation,k=this.labelMetrics(),n,w=Number.MAX_VALUE,v,F=this.max-this.min,I=function(d){var a=d/(f||1);a=1<a?Math.ceil(a):1;a*c>F&&Infinity!==d&&Infinity!==f&&F&&(a=Math.ceil(F/c));return C(a*c)};d?(v=!a.staggerLines&&!a.step&&(J(r)?[r]:f<p(a.autoRotationLimit,80)&&a.autoRotation))&&v.forEach(function(d){if(d===
r||d&&-90<=d&&90>=d){n=I(Math.abs(k.h/Math.sin(O*d)));var a=n+Math.abs(d/360);a<w&&(w=a,g=d,b=n)}}):a.step||(b=I(k.h));this.autoRotation=v;this.labelRotation=p(g,r);return b};D.prototype.getSlotWidth=function(a){var d,h=this.chart,c=this.horiz,f=this.options.labels,g=Math.max(this.tickPositions.length-(this.categories?0:1),1),p=h.margin[3];if(a&&b(a.slotWidth))return a.slotWidth;if(c&&f&&2>(f.step||0))return f.rotation?0:(this.staggerLines||1)*this.len/g;if(!c){a=null===(d=null===f||void 0===f?void 0:
f.style)||void 0===d?void 0:d.width;if(void 0!==a)return parseInt(a,10);if(p)return p-h.spacing[3]}return.33*h.chartWidth};D.prototype.renderUnsquish=function(){var a=this.chart,d=a.renderer,c=this.tickPositions,b=this.ticks,g=this.options.labels,p=g&&g.style||{},r=this.horiz,k=this.getSlotWidth(),n=Math.max(1,Math.round(k-2*(g.padding||5))),w={},v=this.labelMetrics(),F=g.style&&g.style.textOverflow,I=0;f(g.rotation)||(w.rotation=g.rotation||0);c.forEach(function(d){d=b[d];d.movedLabel&&d.replaceMovedLabel();
d&&d.label&&d.label.textPxLength>I&&(I=d.label.textPxLength)});this.maxLabelLength=I;if(this.autoRotation)I>n&&I>v.h?w.rotation=this.labelRotation:this.labelRotation=0;else if(k){var m=n;if(!F){var D="clip";for(n=c.length;!r&&n--;){var O=c[n];if(O=b[O].label)O.styles&&"ellipsis"===O.styles.textOverflow?O.css({textOverflow:"clip"}):O.textPxLength>k&&O.css({width:k+"px"}),O.getBBox().height>this.len/c.length-(v.h-v.f)&&(O.specificTextOverflow="ellipsis")}}}w.rotation&&(m=I>.5*a.chartHeight?.33*a.chartHeight:
I,F||(D="ellipsis"));if(this.labelAlign=g.align||this.autoLabelAlign(this.labelRotation))w.align=this.labelAlign;c.forEach(function(d){var a=(d=b[d])&&d.label,h=p.width,c={};a&&(a.attr(w),d.shortenLabel?d.shortenLabel():m&&!h&&"nowrap"!==p.whiteSpace&&(m<a.textPxLength||"SPAN"===a.element.tagName)?(c.width=m+"px",F||(c.textOverflow=a.specificTextOverflow||D),a.css(c)):a.styles&&a.styles.width&&!c.width&&!h&&a.css({width:null}),delete a.specificTextOverflow,d.rotation=w.rotation)},this);this.tickRotCorr=
d.rotCorr(v.b,this.labelRotation||0,0!==this.side)};D.prototype.hasData=function(){return this.series.some(function(a){return a.hasData()})||this.options.showEmpty&&J(this.min)&&J(this.max)};D.prototype.addTitle=function(h){var d=this.chart.renderer,c=this.horiz,b=this.opposite,f=this.options.title,g,p=this.chart.styledMode;this.axisTitle||((g=f.textAlign)||(g=(c?{low:"left",middle:"center",high:"right"}:{low:b?"right":"left",middle:"center",high:b?"left":"right"})[f.align]),this.axisTitle=d.text(f.text,
0,0,f.useHTML).attr({zIndex:7,rotation:f.rotation||0,align:g}).addClass("highcharts-axis-title"),p||this.axisTitle.css(a(f.style)),this.axisTitle.add(this.axisGroup),this.axisTitle.isNew=!0);p||f.style.width||this.isRadial||this.axisTitle.css({width:this.len+"px"});this.axisTitle[h?"show":"hide"](h)};D.prototype.generateTick=function(a){var d=this.ticks;d[a]?d[a].addLabel():d[a]=new B(this,a)};D.prototype.getOffset=function(){var a=this,d=a.chart,c=d.renderer,b=a.options,f=a.tickPositions,g=a.ticks,
k=a.horiz,n=a.side,w=d.inverted&&!a.isZAxis?[1,0,3,2][n]:n,v,F=0,I=0,m=b.title,O=b.labels,D=0,u=d.axisOffset;d=d.clipOffset;var z=[-1,1,1,-1][n],e=b.className,l=a.axisParent;var y=a.hasData();a.showAxis=v=y||p(b.showEmpty,!0);a.staggerLines=a.horiz&&O.staggerLines;a.axisGroup||(a.gridGroup=c.g("grid").attr({zIndex:b.gridZIndex||1}).addClass("highcharts-"+this.coll.toLowerCase()+"-grid "+(e||"")).add(l),a.axisGroup=c.g("axis").attr({zIndex:b.zIndex||2}).addClass("highcharts-"+this.coll.toLowerCase()+
" "+(e||"")).add(l),a.labelGroup=c.g("axis-labels").attr({zIndex:O.zIndex||7}).addClass("highcharts-"+a.coll.toLowerCase()+"-labels "+(e||"")).add(l));y||a.isLinked?(f.forEach(function(d,c){a.generateTick(d,c)}),a.renderUnsquish(),a.reserveSpaceDefault=0===n||2===n||{1:"left",3:"right"}[n]===a.labelAlign,p(O.reserveSpace,"center"===a.labelAlign?!0:null,a.reserveSpaceDefault)&&f.forEach(function(d){D=Math.max(g[d].getLabelSize(),D)}),a.staggerLines&&(D*=a.staggerLines),a.labelOffset=D*(a.opposite?
-1:1)):r(g,function(d,a){d.destroy();delete g[a]});if(m&&m.text&&!1!==m.enabled&&(a.addTitle(v),v&&!1!==m.reserveSpace)){a.titleOffset=F=a.axisTitle.getBBox()[k?"height":"width"];var A=m.offset;I=J(A)?0:p(m.margin,k?5:10)}a.renderLine();a.offset=z*p(b.offset,u[n]?u[n]+(b.margin||0):0);a.tickRotCorr=a.tickRotCorr||{x:0,y:0};c=0===n?-a.labelMetrics().h:2===n?a.tickRotCorr.y:0;I=Math.abs(D)+I;D&&(I=I-c+z*(k?p(O.y,a.tickRotCorr.y+8*z):O.x));a.axisTitleMargin=p(A,I);a.getMaxLabelDimensions&&(a.maxLabelDimensions=
a.getMaxLabelDimensions(g,f));k=this.tickSize("tick");u[n]=Math.max(u[n],a.axisTitleMargin+F+z*a.offset,I,f&&f.length&&k?k[0]+z*a.offset:0);b=b.offset?0:2*Math.floor(a.axisLine.strokeWidth()/2);d[w]=Math.max(d[w],b);q(this,"afterGetOffset")};D.prototype.getLinePath=function(a){var d=this.chart,c=this.opposite,h=this.offset,b=this.horiz,f=this.left+(c?this.width:0)+h;h=d.chartHeight-this.bottom-(c?this.height:0)+h;c&&(a*=-1);return d.renderer.crispLine([["M",b?this.left:f,b?h:this.top],["L",b?d.chartWidth-
this.right:f,b?h:d.chartHeight-this.bottom]],a)};D.prototype.renderLine=function(){this.axisLine||(this.axisLine=this.chart.renderer.path().addClass("highcharts-axis-line").add(this.axisGroup),this.chart.styledMode||this.axisLine.attr({stroke:this.options.lineColor,"stroke-width":this.options.lineWidth,zIndex:7}))};D.prototype.getTitlePosition=function(){var a=this.horiz,d=this.left,c=this.top,b=this.len,f=this.options.title,g=a?d:c,p=this.opposite,r=this.offset,n=f.x||0,k=f.y||0,w=this.axisTitle,
v=this.chart.renderer.fontMetrics(f.style&&f.style.fontSize,w);w=Math.max(w.getBBox(null,0).height-v.h-1,0);b={low:g+(a?0:b),middle:g+b/2,high:g+(a?b:0)}[f.align];d=(a?c+this.height:d)+(a?1:-1)*(p?-1:1)*this.axisTitleMargin+[-w,w,v.f,-w][this.side];a={x:a?b+n:d+(p?this.width:0)+r+n,y:a?d+k-(p?this.height:0)+r:b+k};q(this,"afterGetTitlePosition",{titlePosition:a});return a};D.prototype.renderMinorTick=function(a){var d=this.chart.hasRendered&&b(this.oldMin),c=this.minorTicks;c[a]||(c[a]=new B(this,
a,"minor"));d&&c[a].isNew&&c[a].render(null,!0);c[a].render(null,!1,1)};D.prototype.renderTick=function(a,d){var c=this.isLinked,h=this.ticks,f=this.chart.hasRendered&&b(this.oldMin);if(!c||a>=this.min&&a<=this.max)h[a]||(h[a]=new B(this,a)),f&&h[a].isNew&&h[a].render(d,!0,-1),h[a].render(d)};D.prototype.render=function(){var a=this,d=a.chart,c=a.logarithmic,f=a.options,g=a.isLinked,p=a.tickPositions,k=a.axisTitle,w=a.ticks,v=a.minorTicks,F=a.alternateBands,I=f.stackLabels,m=f.alternateGridColor,
O=a.tickmarkOffset,D=a.axisLine,u=a.showAxis,z=H(d.renderer.globalAnimation),l,y;a.labelEdge.length=0;a.overlap=!1;[w,v,F].forEach(function(d){r(d,function(d){d.isActive=!1})});if(a.hasData()||g)a.minorTickInterval&&!a.categories&&a.getMinorTickPositions().forEach(function(d){a.renderMinorTick(d)}),p.length&&(p.forEach(function(d,c){a.renderTick(d,c)}),O&&(0===a.min||a.single)&&(w[-1]||(w[-1]=new B(a,-1,null,!0)),w[-1].render(-1))),m&&p.forEach(function(h,b){y="undefined"!==typeof p[b+1]?p[b+1]+O:
a.max-O;0===b%2&&h<a.max&&y<=a.max+(d.polar?-O:O)&&(F[h]||(F[h]=new e.PlotLineOrBand(a)),l=h+O,F[h].options={from:c?c.lin2log(l):l,to:c?c.lin2log(y):y,color:m},F[h].render(),F[h].isActive=!0)}),a._addedPlotLB||((f.plotLines||[]).concat(f.plotBands||[]).forEach(function(d){a.addPlotBandOrLine(d)}),a._addedPlotLB=!0);[w,v,F].forEach(function(a){var c,h=[],b=z.duration;r(a,function(d,a){d.isActive||(d.render(a,!1,0),d.isActive=!1,h.push(a))});n(function(){for(c=h.length;c--;)a[h[c]]&&!a[h[c]].isActive&&
(a[h[c]].destroy(),delete a[h[c]])},a!==F&&d.hasRendered&&b?b:0)});D&&(D[D.isPlaced?"animate":"attr"]({d:this.getLinePath(D.strokeWidth())}),D.isPlaced=!0,D[u?"show":"hide"](u));k&&u&&(f=a.getTitlePosition(),b(f.y)?(k[k.isNew?"attr":"animate"](f),k.isNew=!1):(k.attr("y",-9999),k.isNew=!0));I&&I.enabled&&a.stacking&&a.stacking.renderStackTotals();a.isDirty=!1;q(this,"afterRender")};D.prototype.redraw=function(){this.visible&&(this.render(),this.plotLinesAndBands.forEach(function(a){a.render()}));this.series.forEach(function(a){a.isDirty=
!0})};D.prototype.getKeepProps=function(){return this.keepProps||D.keepProps};D.prototype.destroy=function(a){var d=this,c=d.plotLinesAndBands,h;q(this,"destroy",{keepEvents:a});a||w(d);[d.ticks,d.minorTicks,d.alternateBands].forEach(function(d){y(d)});if(c)for(a=c.length;a--;)c[a].destroy();"axisLine axisTitle axisGroup gridGroup labelGroup cross scrollbar".split(" ").forEach(function(a){d[a]&&(d[a]=d[a].destroy())});for(h in d.plotLinesAndBandsGroups)d.plotLinesAndBandsGroups[h]=d.plotLinesAndBandsGroups[h].destroy();
r(d,function(a,c){-1===d.getKeepProps().indexOf(c)&&delete d[c]})};D.prototype.drawCrosshair=function(a,d){var c=this.crosshair,h=p(c.snap,!0),b,f=this.cross,g=this.chart;q(this,"drawCrosshair",{e:a,point:d});a||(a=this.cross&&this.cross.e);if(this.crosshair&&!1!==(J(d)||!h)){h?J(d)&&(b=p("colorAxis"!==this.coll?d.crosshairPos:null,this.isXAxis?d.plotX:this.len-d.plotY)):b=a&&(this.horiz?a.chartX-this.pos:this.len-a.chartY+this.pos);if(J(b)){var r={value:d&&(this.isXAxis?d.x:p(d.stackY,d.y)),translatedValue:b};
g.polar&&z(r,{isCrosshair:!0,chartX:a&&a.chartX,chartY:a&&a.chartY,point:d});r=this.getPlotLinePath(r)||null}if(!J(r)){this.hideCrosshair();return}h=this.categories&&!this.isRadial;f||(this.cross=f=g.renderer.path().addClass("highcharts-crosshair highcharts-crosshair-"+(h?"category ":"thin ")+c.className).attr({zIndex:p(c.zIndex,2)}).add(),g.styledMode||(f.attr({stroke:c.color||(h?l.parse("#ccd6eb").setOpacity(.25).get():"#cccccc"),"stroke-width":p(c.width,1)}).css({"pointer-events":"none"}),c.dashStyle&&
f.attr({dashstyle:c.dashStyle})));f.show().attr({d:r});h&&!c.width&&f.attr({"stroke-width":this.transA});this.cross.e=a}else this.hideCrosshair();q(this,"afterDrawCrosshair",{e:a,point:d})};D.prototype.hideCrosshair=function(){this.cross&&this.cross.hide();q(this,"afterHideCrosshair")};D.prototype.hasVerticalPanning=function(){var a,d;return/y/.test((null===(d=null===(a=this.chart.options.chart)||void 0===a?void 0:a.panning)||void 0===d?void 0:d.type)||"")};D.defaultOptions={dateTimeLabelFormats:{millisecond:{main:"%H:%M:%S.%L",
range:!1},second:{main:"%H:%M:%S",range:!1},minute:{main:"%H:%M",range:!1},hour:{main:"%H:%M",range:!1},day:{main:"%e. %b"},week:{main:"%e. %b"},month:{main:"%b '%y"},year:{main:"%Y"}},endOnTick:!1,labels:{enabled:!0,indentation:10,x:0,style:{color:"#666666",cursor:"default",fontSize:"11px"}},maxPadding:.01,minorTickLength:2,minorTickPosition:"outside",minPadding:.01,showEmpty:!0,startOfWeek:1,startOnTick:!1,tickLength:10,tickPixelInterval:100,tickmarkPlacement:"between",tickPosition:"outside",title:{align:"middle",
style:{color:"#666666"}},type:"linear",minorGridLineColor:"#f2f2f2",minorGridLineWidth:1,minorTickColor:"#999999",lineColor:"#ccd6eb",lineWidth:1,gridLineColor:"#e6e6e6",tickColor:"#ccd6eb"};D.defaultYAxisOptions={endOnTick:!0,maxPadding:.05,minPadding:.05,tickPixelInterval:72,showLastLabel:!0,labels:{x:-8},startOnTick:!0,title:{rotation:270,text:"Values"},stackLabels:{allowOverlap:!1,enabled:!1,crop:!0,overflow:"justify",formatter:function(){var a=this.axis.chart.numberFormatter;return a(this.total,
-1)},style:{color:"#000000",fontSize:"11px",fontWeight:"bold",textOutline:"1px contrast"}},gridLineWidth:1,lineWidth:0};D.defaultLeftAxisOptions={labels:{x:-15},title:{rotation:270}};D.defaultRightAxisOptions={labels:{x:15},title:{rotation:90}};D.defaultBottomAxisOptions={labels:{autoRotation:[-45],x:0},margin:15,title:{rotation:0}};D.defaultTopAxisOptions={labels:{autoRotation:[-45],x:0},margin:15,title:{rotation:0}};D.keepProps="extKey hcEvents names series userMax userMin".split(" ");return D}();
e.Axis=t;return e.Axis});P(x,"parts/DateTimeAxis.js",[x["parts/Axis.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent,t=e.getMagnitude,N=e.normalizeTickInterval,H=e.timeUnits,L=function(){function e(e){this.axis=e}e.prototype.normalizeTimeTickInterval=function(e,l){var E=l||[["millisecond",[1,2,5,10,20,25,50,100,200,500]],["second",[1,2,5,10,15,30]],["minute",[1,2,5,10,15,30]],["hour",[1,2,3,4,6,8,12]],["day",[1,2]],["week",[1,2]],["month",[1,2,3,4,6]],["year",null]];l=E[E.length-1];var y=
H[l[0]],A=l[1],z;for(z=0;z<E.length&&!(l=E[z],y=H[l[0]],A=l[1],E[z+1]&&e<=(y*A[A.length-1]+H[E[z+1][0]])/2);z++);y===H.year&&e<5*y&&(A=[1,2,5]);e=N(e/y,A,"year"===l[0]?Math.max(t(e/y),1):1);return{unitRange:y,count:e,unitName:l[0]}};return e}();e=function(){function e(){}e.compose=function(e){e.keepProps.push("dateTime");e.prototype.getTimeTicks=function(){return this.chart.time.getTimeTicks.apply(this.chart.time,arguments)};B(e,"init",function(e){"datetime"!==e.userOptions.type?this.dateTime=void 0:
this.dateTime||(this.dateTime=new L(this))})};e.AdditionsClass=L;return e}();e.compose(l);return e});P(x,"parts/LogarithmicAxis.js",[x["parts/Axis.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent,t=e.getMagnitude,N=e.normalizeTickInterval,H=e.pick,L=function(){function e(e){this.axis=e}e.prototype.getLogTickPositions=function(e,l,J,y){var A=this.axis,z=A.len,q=A.options,m=[];y||(this.minorAutoInterval=void 0);if(.5<=e)e=Math.round(e),m=A.getLinearTickPositions(e,l,J);else if(.08<=e){q=
Math.floor(l);var u,k;for(z=.3<e?[1,2,4]:.15<e?[1,2,4,6,8]:[1,2,3,4,5,6,7,8,9];q<J+1&&!k;q++){var g=z.length;for(u=0;u<g&&!k;u++){var b=this.log2lin(this.lin2log(q)*z[u]);b>l&&(!y||f<=J)&&"undefined"!==typeof f&&m.push(f);f>J&&(k=!0);var f=b}}}else l=this.lin2log(l),J=this.lin2log(J),e=y?A.getMinorTickInterval():q.tickInterval,e=H("auto"===e?null:e,this.minorAutoInterval,q.tickPixelInterval/(y?5:1)*(J-l)/((y?z/A.tickPositions.length:z)||1)),e=N(e,void 0,t(e)),m=A.getLinearTickPositions(e,l,J).map(this.log2lin),
y||(this.minorAutoInterval=e/5);y||(A.tickInterval=e);return m};e.prototype.lin2log=function(e){return Math.pow(10,e)};e.prototype.log2lin=function(e){return Math.log(e)/Math.LN10};return e}();e=function(){function e(){}e.compose=function(e){e.keepProps.push("logarithmic");var l=e.prototype,E=L.prototype;l.log2lin=E.log2lin;l.lin2log=E.lin2log;B(e,"init",function(e){var l=this.logarithmic;"logarithmic"!==e.userOptions.type?this.logarithmic=void 0:(l||(l=this.logarithmic=new L(this)),this.log2lin!==
l.log2lin&&(l.log2lin=this.log2lin.bind(this)),this.lin2log!==l.lin2log&&(l.lin2log=this.lin2log.bind(this)))});B(e,"afterInit",function(){var e=this.logarithmic;e&&(this.lin2val=function(l){return e.lin2log(l)},this.val2lin=function(l){return e.log2lin(l)})})};return e}();e.compose(l);return e});P(x,"parts/PlotLineOrBand.js",[x["parts/Globals.js"],x["parts/Axis.js"],x["parts/Utilities.js"]],function(l,e,B){var t=B.arrayMax,N=B.arrayMin,H=B.defined,L=B.destroyObjectProperties,K=B.erase,E=B.extend,
C=B.merge,J=B.objectEach,y=B.pick,A=function(){function e(q,m){this.axis=q;m&&(this.options=m,this.id=m.id)}e.prototype.render=function(){l.fireEvent(this,"render");var q=this,m=q.axis,e=m.horiz,k=m.logarithmic,g=q.options,b=g.label,f=q.label,a=g.to,c=g.from,r=g.value,p=H(c)&&H(a),I=H(r),w=q.svgElem,v=!w,n=[],F=g.color,O=y(g.zIndex,0),D=g.events;n={"class":"highcharts-plot-"+(p?"band ":"line ")+(g.className||"")};var h={},d=m.chart.renderer,G=p?"bands":"lines";k&&(c=k.log2lin(c),a=k.log2lin(a),r=
k.log2lin(r));m.chart.styledMode||(I?(n.stroke=F||"#999999",n["stroke-width"]=y(g.width,1),g.dashStyle&&(n.dashstyle=g.dashStyle)):p&&(n.fill=F||"#e6ebf5",g.borderWidth&&(n.stroke=g.borderColor,n["stroke-width"]=g.borderWidth)));h.zIndex=O;G+="-"+O;(k=m.plotLinesAndBandsGroups[G])||(m.plotLinesAndBandsGroups[G]=k=d.g("plot-"+G).attr(h).add());v&&(q.svgElem=w=d.path().attr(n).add(k));if(I)n=m.getPlotLinePath({value:r,lineWidth:w.strokeWidth(),acrossPanes:g.acrossPanes});else if(p)n=m.getPlotBandPath(c,
a,g);else return;(v||!w.d)&&n&&n.length?(w.attr({d:n}),D&&J(D,function(a,d){w.on(d,function(a){D[d].apply(q,[a])})})):w&&(n?(w.show(!0),w.animate({d:n})):w.d&&(w.hide(),f&&(q.label=f=f.destroy())));b&&(H(b.text)||H(b.formatter))&&n&&n.length&&0<m.width&&0<m.height&&!n.isFlat?(b=C({align:e&&p&&"center",x:e?!p&&4:10,verticalAlign:!e&&p&&"middle",y:e?p?16:10:p?6:-4,rotation:e&&!p&&90},b),this.renderLabel(b,n,p,O)):f&&f.hide();return q};e.prototype.renderLabel=function(e,m,u,k){var g=this.label,b=this.axis.chart.renderer;
g||(g={align:e.textAlign||e.align,rotation:e.rotation,"class":"highcharts-plot-"+(u?"band":"line")+"-label "+(e.className||"")},g.zIndex=k,k=this.getLabelText(e),this.label=g=b.text(k,0,0,e.useHTML).attr(g).add(),this.axis.chart.styledMode||g.css(e.style));b=m.xBounds||[m[0][1],m[1][1],u?m[2][1]:m[0][1]];m=m.yBounds||[m[0][2],m[1][2],u?m[2][2]:m[0][2]];u=N(b);k=N(m);g.align(e,!1,{x:u,y:k,width:t(b)-u,height:t(m)-k});g.show(!0)};e.prototype.getLabelText=function(e){return H(e.formatter)?e.formatter.call(this):
e.text};e.prototype.destroy=function(){K(this.axis.plotLinesAndBands,this);delete this.axis;L(this)};return e}();E(e.prototype,{getPlotBandPath:function(e,q){var m=this.getPlotLinePath({value:q,force:!0,acrossPanes:this.options.acrossPanes}),u=this.getPlotLinePath({value:e,force:!0,acrossPanes:this.options.acrossPanes}),k=[],g=this.horiz,b=1;e=e<this.min&&q<this.min||e>this.max&&q>this.max;if(u&&m){if(e){var f=u.toString()===m.toString();b=0}for(e=0;e<u.length;e+=2){q=u[e];var a=u[e+1],c=m[e],r=m[e+
1];"M"!==q[0]&&"L"!==q[0]||"M"!==a[0]&&"L"!==a[0]||"M"!==c[0]&&"L"!==c[0]||"M"!==r[0]&&"L"!==r[0]||(g&&c[1]===q[1]?(c[1]+=b,r[1]+=b):g||c[2]!==q[2]||(c[2]+=b,r[2]+=b),k.push(["M",q[1],q[2]],["L",a[1],a[2]],["L",r[1],r[2]],["L",c[1],c[2]],["Z"]));k.isFlat=f}}return k},addPlotBand:function(e){return this.addPlotBandOrLine(e,"plotBands")},addPlotLine:function(e){return this.addPlotBandOrLine(e,"plotLines")},addPlotBandOrLine:function(e,q){var m=(new A(this,e)).render(),u=this.userOptions;if(m){if(q){var k=
u[q]||[];k.push(e);u[q]=k}this.plotLinesAndBands.push(m)}return m},removePlotBandOrLine:function(e){for(var q=this.plotLinesAndBands,m=this.options,u=this.userOptions,k=q.length;k--;)q[k].id===e&&q[k].destroy();[m.plotLines||[],u.plotLines||[],m.plotBands||[],u.plotBands||[]].forEach(function(g){for(k=g.length;k--;)(g[k]||{}).id===e&&K(g,g[k])})},removePlotBand:function(e){this.removePlotBandOrLine(e)},removePlotLine:function(e){this.removePlotBandOrLine(e)}});l.PlotLineOrBand=A;return l.PlotLineOrBand});
P(x,"parts/Tooltip.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.clamp,t=e.css,N=e.defined,H=e.discardElement,L=e.extend,K=e.fireEvent,E=e.format,C=e.isNumber,J=e.isString,y=e.merge,A=e.pick,z=e.splat,q=e.syncTimeout,m=e.timeUnits;"";var u=l.doc,k=function(){function g(b,f){this.crosshairs=[];this.distance=0;this.isHidden=!0;this.isSticky=!1;this.now={};this.options={};this.outside=!1;this.chart=b;this.init(b,f)}g.prototype.applyFilter=function(){var b=this.chart;b.renderer.definition({tagName:"filter",
id:"drop-shadow-"+b.index,opacity:.5,children:[{tagName:"feGaussianBlur","in":"SourceAlpha",stdDeviation:1},{tagName:"feOffset",dx:1,dy:1},{tagName:"feComponentTransfer",children:[{tagName:"feFuncA",type:"linear",slope:.3}]},{tagName:"feMerge",children:[{tagName:"feMergeNode"},{tagName:"feMergeNode","in":"SourceGraphic"}]}]});b.renderer.definition({tagName:"style",textContent:".highcharts-tooltip-"+b.index+"{filter:url(#drop-shadow-"+b.index+")}"})};g.prototype.bodyFormatter=function(b){return b.map(function(b){var a=
b.series.tooltipOptions;return(a[(b.point.formatPrefix||"point")+"Formatter"]||b.point.tooltipFormatter).call(b.point,a[(b.point.formatPrefix||"point")+"Format"]||"")})};g.prototype.cleanSplit=function(b){this.chart.series.forEach(function(f){var a=f&&f.tt;a&&(!a.isActive||b?f.tt=a.destroy():a.isActive=!1)})};g.prototype.defaultFormatter=function(b){var f=this.points||z(this);var a=[b.tooltipFooterHeaderFormatter(f[0])];a=a.concat(b.bodyFormatter(f));a.push(b.tooltipFooterHeaderFormatter(f[0],!0));
return a};g.prototype.destroy=function(){this.label&&(this.label=this.label.destroy());this.split&&this.tt&&(this.cleanSplit(this.chart,!0),this.tt=this.tt.destroy());this.renderer&&(this.renderer=this.renderer.destroy(),H(this.container));e.clearTimeout(this.hideTimer);e.clearTimeout(this.tooltipTimeout)};g.prototype.getAnchor=function(b,f){var a=this.chart,c=a.pointer,g=a.inverted,p=a.plotTop,k=a.plotLeft,w=0,v=0,n,F;b=z(b);this.followPointer&&f?("undefined"===typeof f.chartX&&(f=c.normalize(f)),
b=[f.chartX-k,f.chartY-p]):b[0].tooltipPos?b=b[0].tooltipPos:(b.forEach(function(a){n=a.series.yAxis;F=a.series.xAxis;w+=a.plotX+(!g&&F?F.left-k:0);v+=(a.plotLow?(a.plotLow+a.plotHigh)/2:a.plotY)+(!g&&n?n.top-p:0)}),w/=b.length,v/=b.length,b=[g?a.plotWidth-v:w,this.shared&&!g&&1<b.length&&f?f.chartY-p:g?a.plotHeight-w:v]);return b.map(Math.round)};g.prototype.getDateFormat=function(b,f,a,c){var g=this.chart.time,p=g.dateFormat("%m-%d %H:%M:%S.%L",f),k={millisecond:15,second:12,minute:9,hour:6,day:3},
w="millisecond";for(v in m){if(b===m.week&&+g.dateFormat("%w",f)===a&&"00:00:00.000"===p.substr(6)){var v="week";break}if(m[v]>b){v=w;break}if(k[v]&&p.substr(k[v])!=="01-01 00:00:00.000".substr(k[v]))break;"week"!==v&&(w=v)}if(v)var n=g.resolveDTLFormat(c[v]).main;return n};g.prototype.getLabel=function(){var b,f,a=this,c=this.chart.renderer,g=this.chart.styledMode,p=this.options,k="tooltip"+(N(p.className)?" "+p.className:""),w=(null===(b=p.style)||void 0===b?void 0:b.pointerEvents)||(!this.followPointer&&
p.stickOnContact?"auto":"none"),v;b=function(){a.inContact=!0};var n=function(){var c=a.chart.hoverSeries;a.inContact=!1;if(c&&c.onMouseOut)c.onMouseOut()};if(!this.label){this.outside&&(this.container=v=l.doc.createElement("div"),v.className="highcharts-tooltip-container",t(v,{position:"absolute",top:"1px",pointerEvents:w,zIndex:3}),l.doc.body.appendChild(v),this.renderer=c=new l.Renderer(v,0,0,null===(f=this.chart.options.chart)||void 0===f?void 0:f.style,void 0,void 0,c.styledMode));this.split?
this.label=c.g(k):(this.label=c.label("",0,0,p.shape||"callout",null,null,p.useHTML,null,k).attr({padding:p.padding,r:p.borderRadius}),g||this.label.attr({fill:p.backgroundColor,"stroke-width":p.borderWidth}).css(p.style).css({pointerEvents:w}).shadow(p.shadow));g&&(this.applyFilter(),this.label.addClass("highcharts-tooltip-"+this.chart.index));if(a.outside&&!a.split){var F={x:this.label.xSetter,y:this.label.ySetter};this.label.xSetter=function(c,b){F[b].call(this.label,a.distance);v.style.left=c+
"px"};this.label.ySetter=function(c,b){F[b].call(this.label,a.distance);v.style.top=c+"px"}}this.label.on("mouseenter",b).on("mouseleave",n).attr({zIndex:8}).add()}return this.label};g.prototype.getPosition=function(b,f,a){var c=this.chart,g=this.distance,p={},k=c.inverted&&a.h||0,w,v=this.outside,n=v?u.documentElement.clientWidth-2*g:c.chartWidth,F=v?Math.max(u.body.scrollHeight,u.documentElement.scrollHeight,u.body.offsetHeight,u.documentElement.offsetHeight,u.documentElement.clientHeight):c.chartHeight,
m=c.pointer.getChartPosition(),e=c.containerScaling,h=function(a){return e?a*e.scaleX:a},d=function(a){return e?a*e.scaleY:a},G=function(p){var r="x"===p;return[p,r?n:F,r?b:f].concat(v?[r?h(b):d(f),r?m.left-g+h(a.plotX+c.plotLeft):m.top-g+d(a.plotY+c.plotTop),0,r?n:F]:[r?b:f,r?a.plotX+c.plotLeft:a.plotY+c.plotTop,r?c.plotLeft:c.plotTop,r?c.plotLeft+c.plotWidth:c.plotTop+c.plotHeight])},M=G("y"),q=G("x"),l=!this.followPointer&&A(a.ttBelow,!c.inverted===!!a.negative),z=function(a,c,b,f,r,n,w){var v=
"y"===a?d(g):h(g),F=(b-f)/2,G=f<r-g,M=r+g+f<c,m=r-v-b+F;r=r+v-F;if(l&&M)p[a]=r;else if(!l&&G)p[a]=m;else if(G)p[a]=Math.min(w-f,0>m-k?m:m-k);else if(M)p[a]=Math.max(n,r+k+b>c?r:r+k);else return!1},y=function(a,d,c,h,b){var f;b<g||b>d-g?f=!1:p[a]=b<c/2?1:b>d-h/2?d-h-2:b-c/2;return f},E=function(a){var d=M;M=q;q=d;w=a},C=function(){!1!==z.apply(0,M)?!1!==y.apply(0,q)||w||(E(!0),C()):w?p.x=p.y=0:(E(!0),C())};(c.inverted||1<this.len)&&E();C();return p};g.prototype.getXDateFormat=function(b,f,a){f=f.dateTimeLabelFormats;
var c=a&&a.closestPointRange;return(c?this.getDateFormat(c,b.x,a.options.startOfWeek,f):f.day)||f.year};g.prototype.hide=function(b){var f=this;e.clearTimeout(this.hideTimer);b=A(b,this.options.hideDelay,500);this.isHidden||(this.hideTimer=q(function(){f.getLabel().fadeOut(b?void 0:b);f.isHidden=!0},b))};g.prototype.init=function(b,f){this.chart=b;this.options=f;this.crosshairs=[];this.now={x:0,y:0};this.isHidden=!0;this.split=f.split&&!b.inverted&&!b.polar;this.shared=f.shared||this.split;this.outside=
A(f.outside,!(!b.scrollablePixelsX&&!b.scrollablePixelsY))};g.prototype.isStickyOnContact=function(){return!(this.followPointer||!this.options.stickOnContact||!this.inContact)};g.prototype.move=function(b,f,a,c){var g=this,p=g.now,k=!1!==g.options.animation&&!g.isHidden&&(1<Math.abs(b-p.x)||1<Math.abs(f-p.y)),w=g.followPointer||1<g.len;L(p,{x:k?(2*p.x+b)/3:b,y:k?(p.y+f)/2:f,anchorX:w?void 0:k?(2*p.anchorX+a)/3:a,anchorY:w?void 0:k?(p.anchorY+c)/2:c});g.getLabel().attr(p);g.drawTracker();k&&(e.clearTimeout(this.tooltipTimeout),
this.tooltipTimeout=setTimeout(function(){g&&g.move(b,f,a,c)},32))};g.prototype.refresh=function(b,f){var a=this.chart,c=this.options,g=b,p={},k=[],w=c.formatter||this.defaultFormatter;p=this.shared;var v=a.styledMode;if(c.enabled){e.clearTimeout(this.hideTimer);this.followPointer=z(g)[0].series.tooltipOptions.followPointer;var n=this.getAnchor(g,f);f=n[0];var F=n[1];!p||g.series&&g.series.noSharedTooltip?p=g.getLabelConfig():(a.pointer.applyInactiveState(g),g.forEach(function(a){a.setState("hover");
k.push(a.getLabelConfig())}),p={x:g[0].category,y:g[0].y},p.points=k,g=g[0]);this.len=k.length;a=w.call(p,this);w=g.series;this.distance=A(w.tooltipOptions.distance,16);!1===a?this.hide():(this.split?this.renderSplit(a,z(b)):(b=this.getLabel(),c.style.width&&!v||b.css({width:this.chart.spacingBox.width+"px"}),b.attr({text:a&&a.join?a.join(""):a}),b.removeClass(/highcharts-color-[\d]+/g).addClass("highcharts-color-"+A(g.colorIndex,w.colorIndex)),v||b.attr({stroke:c.borderColor||g.color||w.color||"#666666"}),
this.updatePosition({plotX:f,plotY:F,negative:g.negative,ttBelow:g.ttBelow,h:n[2]||0})),this.isHidden&&this.label&&this.label.attr({opacity:1}).show(),this.isHidden=!1);K(this,"refresh")}};g.prototype.renderSplit=function(b,f){function a(a,d,c,h,b){void 0===b&&(b=!0);c?(d=E?0:K,a=B(a-h/2,z.left,z.right-h)):(d-=C,a=b?a-h-M:a+M,a=B(a,b?a:z.left,z.right));return{x:a,y:d}}var c=this,g=c.chart,p=c.chart,k=p.plotHeight,w=p.plotLeft,v=p.plotTop,n=p.pointer,F=p.renderer,m=p.scrollablePixelsY,e=void 0===m?
0:m;m=p.scrollingContainer;m=void 0===m?{scrollLeft:0,scrollTop:0}:m;var h=m.scrollLeft,d=m.scrollTop,G=p.styledMode,M=c.distance,q=c.options,u=c.options.positioner,z={left:h,right:h+p.chartWidth,top:d,bottom:d+p.chartHeight},y=c.getLabel(),E=!(!g.xAxis[0]||!g.xAxis[0].opposite),C=v+d,t=0,K=k-e;J(b)&&(b=[!1,b]);b=b.slice(0,f.length+1).reduce(function(h,b,g){if(!1!==b&&""!==b){g=f[g-1]||{isHeader:!0,plotX:f[0].plotX,plotY:k,series:{}};var p=g.isHeader,r=p?c:g.series,n=r.tt,m=g.isHeader;var I=g.series;
var D="highcharts-color-"+A(g.colorIndex,I.colorIndex,"none");n||(n={padding:q.padding,r:q.borderRadius},G||(n.fill=q.backgroundColor,n["stroke-width"]=q.borderWidth),n=F.label("",0,0,q[m?"headerShape":"shape"]||"callout",void 0,void 0,q.useHTML).addClass((m?"highcharts-tooltip-header ":"")+"highcharts-tooltip-box "+D).attr(n).add(y));n.isActive=!0;n.attr({text:b});G||n.css(q.style).shadow(q.shadow).attr({stroke:q.borderColor||g.color||I.color||"#333333"});b=r.tt=n;m=b.getBBox();r=m.width+b.strokeWidth();
p&&(t=m.height,K+=t,E&&(C-=t));I=g.plotX;I=void 0===I?0:I;D=g.plotY;D=void 0===D?0:D;var O=g.series;if(g.isHeader){I=w+I;var l=v+k/2}else n=O.xAxis,O=O.yAxis,I=n.pos+B(I,-M,n.len+M),O.pos+D>=d+v&&O.pos+D<=d+v+k-e&&(l=O.pos+D);I=B(I,z.left-M,z.right+M);"number"===typeof l?(m=m.height+1,D=u?u.call(c,r,m,g):a(I,l,p,r),h.push({align:u?0:void 0,anchorX:I,anchorY:l,boxWidth:r,point:g,rank:A(D.rank,p?1:0),size:m,target:D.y,tt:b,x:D.x})):b.isActive=!1}return h},[]);!u&&b.some(function(a){return a.x<z.left})&&
(b=b.map(function(d){var c=a(d.anchorX,d.anchorY,d.point.isHeader,d.boxWidth,!1);return L(d,{target:c.y,x:c.x})}));c.cleanSplit();l.distribute(b,K);b.forEach(function(a){var d=a.pos;a.tt.attr({visibility:"undefined"===typeof d?"hidden":"inherit",x:a.x,y:d+C,anchorX:a.anchorX,anchorY:a.anchorY})});b=c.container;g=c.renderer;c.outside&&b&&g&&(p=y.getBBox(),g.setSize(p.width+p.x,p.height+p.y,!1),n=n.getChartPosition(),b.style.left=n.left+"px",b.style.top=n.top+"px")};g.prototype.drawTracker=function(){if(this.followPointer||
!this.options.stickOnContact)this.tracker&&this.tracker.destroy();else{var b=this.chart,f=this.label,a=b.hoverPoint;if(f&&a){var c={x:0,y:0,width:0,height:0};a=this.getAnchor(a);var g=f.getBBox();a[0]+=b.plotLeft-f.translateX;a[1]+=b.plotTop-f.translateY;c.x=Math.min(0,a[0]);c.y=Math.min(0,a[1]);c.width=0>a[0]?Math.max(Math.abs(a[0]),g.width-a[0]):Math.max(Math.abs(a[0]),g.width);c.height=0>a[1]?Math.max(Math.abs(a[1]),g.height-Math.abs(a[1])):Math.max(Math.abs(a[1]),g.height);this.tracker?this.tracker.attr(c):
(this.tracker=f.renderer.rect(c).addClass("highcharts-tracker").add(f),b.styledMode||this.tracker.attr({fill:"rgba(0,0,0,0)"}))}}};g.prototype.styledModeFormat=function(b){return b.replace('style="font-size: 10px"','class="highcharts-header"').replace(/style="color:{(point|series)\.color}"/g,'class="highcharts-color-{$1.colorIndex}"')};g.prototype.tooltipFooterHeaderFormatter=function(b,f){var a=f?"footer":"header",c=b.series,g=c.tooltipOptions,p=g.xDateFormat,k=c.xAxis,w=k&&"datetime"===k.options.type&&
C(b.key),v=g[a+"Format"];f={isFooter:f,labelConfig:b};K(this,"headerFormatter",f,function(a){w&&!p&&(p=this.getXDateFormat(b,g,k));w&&p&&(b.point&&b.point.tooltipDateKeys||["key"]).forEach(function(a){v=v.replace("{point."+a+"}","{point."+a+":"+p+"}")});c.chart.styledMode&&(v=this.styledModeFormat(v));a.text=E(v,{point:b,series:c},this.chart)});return f.text};g.prototype.update=function(b){this.destroy();y(!0,this.chart.options.tooltip.userOptions,b);this.init(this.chart,y(!0,this.options,b))};g.prototype.updatePosition=
function(b){var f=this.chart,a=f.pointer,c=this.getLabel(),g=b.plotX+f.plotLeft,p=b.plotY+f.plotTop;a=a.getChartPosition();b=(this.options.positioner||this.getPosition).call(this,c.width,c.height,b);if(this.outside){var k=(this.options.borderWidth||0)+2*this.distance;this.renderer.setSize(c.width+k,c.height+k,!1);if(f=f.containerScaling)t(this.container,{transform:"scale("+f.scaleX+", "+f.scaleY+")"}),g*=f.scaleX,p*=f.scaleY;g+=a.left-b.x;p+=a.top-b.y}this.move(Math.round(b.x),Math.round(b.y||0),
g,p)};return g}();l.Tooltip=k;return l.Tooltip});P(x,"parts/Pointer.js",[x["parts/Globals.js"],x["parts/Utilities.js"],x["parts/Tooltip.js"],x["parts/Color.js"]],function(l,e,B,t){var N=e.addEvent,H=e.attr,L=e.css,K=e.defined,E=e.extend,C=e.find,J=e.fireEvent,y=e.isNumber,A=e.isObject,z=e.objectEach,q=e.offset,m=e.pick,u=e.splat,k=t.parse,g=l.charts,b=l.noop;e=function(){function f(a,c){this.lastValidTouch={};this.pinchDown=[];this.runChartClick=!1;this.chart=a;this.hasDragged=!1;this.options=c;this.unbindContainerMouseLeave=
function(){};this.init(a,c)}f.prototype.applyInactiveState=function(a){var c=[],b;(a||[]).forEach(function(a){b=a.series;c.push(b);b.linkedParent&&c.push(b.linkedParent);b.linkedSeries&&(c=c.concat(b.linkedSeries));b.navigatorSeries&&c.push(b.navigatorSeries)});this.chart.series.forEach(function(a){-1===c.indexOf(a)?a.setState("inactive",!0):a.options.inactiveOtherPoints&&a.setAllPointsToState("inactive")})};f.prototype.destroy=function(){var a=this;"undefined"!==typeof a.unDocMouseMove&&a.unDocMouseMove();
this.unbindContainerMouseLeave();l.chartCount||(l.unbindDocumentMouseUp&&(l.unbindDocumentMouseUp=l.unbindDocumentMouseUp()),l.unbindDocumentTouchEnd&&(l.unbindDocumentTouchEnd=l.unbindDocumentTouchEnd()));clearInterval(a.tooltipTimeout);z(a,function(c,b){a[b]=null})};f.prototype.drag=function(a){var c=this.chart,b=c.options.chart,f=a.chartX,g=a.chartY,w=this.zoomHor,v=this.zoomVert,n=c.plotLeft,F=c.plotTop,m=c.plotWidth,e=c.plotHeight,h=this.selectionMarker,d=this.mouseDownX||0,G=this.mouseDownY||
0,M=A(b.panning)?b.panning&&b.panning.enabled:b.panning,q=b.panKey&&a[b.panKey+"Key"];if(!h||!h.touch)if(f<n?f=n:f>n+m&&(f=n+m),g<F?g=F:g>F+e&&(g=F+e),this.hasDragged=Math.sqrt(Math.pow(d-f,2)+Math.pow(G-g,2)),10<this.hasDragged){var u=c.isInsidePlot(d-n,G-F);c.hasCartesianSeries&&(this.zoomX||this.zoomY)&&u&&!q&&!h&&(this.selectionMarker=h=c.renderer.rect(n,F,w?1:m,v?1:e,0).attr({"class":"highcharts-selection-marker",zIndex:7}).add(),c.styledMode||h.attr({fill:b.selectionMarkerFill||k("#335cad").setOpacity(.25).get()}));
h&&w&&(f-=d,h.attr({width:Math.abs(f),x:(0<f?0:f)+d}));h&&v&&(f=g-G,h.attr({height:Math.abs(f),y:(0<f?0:f)+G}));u&&!h&&M&&c.pan(a,b.panning)}};f.prototype.dragStart=function(a){var c=this.chart;c.mouseIsDown=a.type;c.cancelClick=!1;c.mouseDownX=this.mouseDownX=a.chartX;c.mouseDownY=this.mouseDownY=a.chartY};f.prototype.drop=function(a){var c=this,b=this.chart,f=this.hasPinched;if(this.selectionMarker){var g={originalEvent:a,xAxis:[],yAxis:[]},k=this.selectionMarker,v=k.attr?k.attr("x"):k.x,n=k.attr?
k.attr("y"):k.y,F=k.attr?k.attr("width"):k.width,m=k.attr?k.attr("height"):k.height,e;if(this.hasDragged||f)b.axes.forEach(function(h){if(h.zoomEnabled&&K(h.min)&&(f||c[{xAxis:"zoomX",yAxis:"zoomY"}[h.coll]])){var d=h.horiz,b="touchend"===a.type?h.minPixelPadding:0,p=h.toValue((d?v:n)+b);d=h.toValue((d?v+F:n+m)-b);g[h.coll].push({axis:h,min:Math.min(p,d),max:Math.max(p,d)});e=!0}}),e&&J(b,"selection",g,function(a){b.zoom(E(a,f?{animation:!1}:null))});y(b.index)&&(this.selectionMarker=this.selectionMarker.destroy());
f&&this.scaleGroups()}b&&y(b.index)&&(L(b.container,{cursor:b._cursor}),b.cancelClick=10<this.hasDragged,b.mouseIsDown=this.hasDragged=this.hasPinched=!1,this.pinchDown=[])};f.prototype.findNearestKDPoint=function(a,c,b){var f=this.chart,g=f.hoverPoint;f=f.tooltip;if(g&&f&&f.isStickyOnContact())return g;var k;a.forEach(function(a){var f=!(a.noSharedTooltip&&c)&&0>a.options.findNearestPointBy.indexOf("y");a=a.searchPoint(b,f);if((f=A(a,!0))&&!(f=!A(k,!0))){f=k.distX-a.distX;var g=k.dist-a.dist,p=(a.series.group&&
a.series.group.zIndex)-(k.series.group&&k.series.group.zIndex);f=0<(0!==f&&c?f:0!==g?g:0!==p?p:k.series.index>a.series.index?-1:1)}f&&(k=a)});return k};f.prototype.getChartCoordinatesFromPoint=function(a,c){var b=a.series,f=b.xAxis;b=b.yAxis;var g=m(a.clientX,a.plotX),k=a.shapeArgs;if(f&&b)return c?{chartX:f.len+f.pos-g,chartY:b.len+b.pos-a.plotY}:{chartX:g+f.pos,chartY:a.plotY+b.pos};if(k&&k.x&&k.y)return{chartX:k.x,chartY:k.y}};f.prototype.getChartPosition=function(){return this.chartPosition||
(this.chartPosition=q(this.chart.container))};f.prototype.getCoordinates=function(a){var c={xAxis:[],yAxis:[]};this.chart.axes.forEach(function(b){c[b.isXAxis?"xAxis":"yAxis"].push({axis:b,value:b.toValue(a[b.horiz?"chartX":"chartY"])})});return c};f.prototype.getHoverData=function(a,c,b,f,g,k){var p,n=[];f=!(!f||!a);var r=c&&!c.stickyTracking,w={chartX:k?k.chartX:void 0,chartY:k?k.chartY:void 0,shared:g};J(this,"beforeGetHoverData",w);r=r?[c]:b.filter(function(a){return w.filter?w.filter(a):a.visible&&
!(!g&&a.directTouch)&&m(a.options.enableMouseTracking,!0)&&a.stickyTracking});c=(p=f||!k?a:this.findNearestKDPoint(r,g,k))&&p.series;p&&(g&&!c.noSharedTooltip?(r=b.filter(function(a){return w.filter?w.filter(a):a.visible&&!(!g&&a.directTouch)&&m(a.options.enableMouseTracking,!0)&&!a.noSharedTooltip}),r.forEach(function(a){var c=C(a.points,function(a){return a.x===p.x&&!a.isNull});A(c)&&(a.chart.isBoosting&&(c=a.getPoint(c)),n.push(c))})):n.push(p));w={hoverPoint:p};J(this,"afterGetHoverData",w);return{hoverPoint:w.hoverPoint,
hoverSeries:c,hoverPoints:n}};f.prototype.getPointFromEvent=function(a){a=a.target;for(var c;a&&!c;)c=a.point,a=a.parentNode;return c};f.prototype.onTrackerMouseOut=function(a){a=a.relatedTarget||a.toElement;var c=this.chart.hoverSeries;this.isDirectTouch=!1;if(!(!c||!a||c.stickyTracking||this.inClass(a,"highcharts-tooltip")||this.inClass(a,"highcharts-series-"+c.index)&&this.inClass(a,"highcharts-tracker")))c.onMouseOut()};f.prototype.inClass=function(a,c){for(var b;a;){if(b=H(a,"class")){if(-1!==
b.indexOf(c))return!0;if(-1!==b.indexOf("highcharts-container"))return!1}a=a.parentNode}};f.prototype.init=function(a,c){this.options=c;this.chart=a;this.runChartClick=c.chart.events&&!!c.chart.events.click;this.pinchDown=[];this.lastValidTouch={};B&&(a.tooltip=new B(a,c.tooltip),this.followTouchMove=m(c.tooltip.followTouchMove,!0));this.setDOMEvents()};f.prototype.normalize=function(a,c){var b=a.touches,f=b?b.length?b.item(0):b.changedTouches[0]:a;c||(c=this.getChartPosition());b=f.pageX-c.left;
c=f.pageY-c.top;if(f=this.chart.containerScaling)b/=f.scaleX,c/=f.scaleY;return E(a,{chartX:Math.round(b),chartY:Math.round(c)})};f.prototype.onContainerClick=function(a){var c=this.chart,b=c.hoverPoint;a=this.normalize(a);var f=c.plotLeft,g=c.plotTop;c.cancelClick||(b&&this.inClass(a.target,"highcharts-tracker")?(J(b.series,"click",E(a,{point:b})),c.hoverPoint&&b.firePointEvent("click",a)):(E(a,this.getCoordinates(a)),c.isInsidePlot(a.chartX-f,a.chartY-g)&&J(c,"click",a)))};f.prototype.onContainerMouseDown=
function(a){a=this.normalize(a);if(l.isFirefox&&0!==a.button)this.onContainerMouseMove(a);if("undefined"===typeof a.button||1===((a.buttons||a.button)&1))this.zoomOption(a),this.dragStart(a)};f.prototype.onContainerMouseLeave=function(a){var c=g[m(l.hoverChartIndex,-1)],b=this.chart.tooltip;a=this.normalize(a);c&&(a.relatedTarget||a.toElement)&&(c.pointer.reset(),c.pointer.chartPosition=void 0);b&&!b.isHidden&&this.reset()};f.prototype.onContainerMouseMove=function(a){var c=this.chart;a=this.normalize(a);
this.setHoverChartIndex();a.preventDefault||(a.returnValue=!1);"mousedown"===c.mouseIsDown&&this.drag(a);c.openMenu||!this.inClass(a.target,"highcharts-tracker")&&!c.isInsidePlot(a.chartX-c.plotLeft,a.chartY-c.plotTop)||this.runPointActions(a)};f.prototype.onDocumentTouchEnd=function(a){g[l.hoverChartIndex]&&g[l.hoverChartIndex].pointer.drop(a)};f.prototype.onContainerTouchMove=function(a){this.touch(a)};f.prototype.onContainerTouchStart=function(a){this.zoomOption(a);this.touch(a,!0)};f.prototype.onDocumentMouseMove=
function(a){var c=this.chart,b=this.chartPosition;a=this.normalize(a,b);var f=c.tooltip;!b||f&&f.isStickyOnContact()||c.isInsidePlot(a.chartX-c.plotLeft,a.chartY-c.plotTop)||this.inClass(a.target,"highcharts-tracker")||this.reset()};f.prototype.onDocumentMouseUp=function(a){var c=g[m(l.hoverChartIndex,-1)];c&&c.pointer.drop(a)};f.prototype.pinch=function(a){var c=this,f=c.chart,g=c.pinchDown,k=a.touches||[],w=k.length,v=c.lastValidTouch,n=c.hasZoom,F=c.selectionMarker,e={},D=1===w&&(c.inClass(a.target,
"highcharts-tracker")&&f.runTrackerClick||c.runChartClick),h={};1<w&&(c.initiated=!0);n&&c.initiated&&!D&&a.preventDefault();[].map.call(k,function(a){return c.normalize(a)});"touchstart"===a.type?([].forEach.call(k,function(a,c){g[c]={chartX:a.chartX,chartY:a.chartY}}),v.x=[g[0].chartX,g[1]&&g[1].chartX],v.y=[g[0].chartY,g[1]&&g[1].chartY],f.axes.forEach(function(a){if(a.zoomEnabled){var d=f.bounds[a.horiz?"h":"v"],c=a.minPixelPadding,b=a.toPixels(Math.min(m(a.options.min,a.dataMin),a.dataMin)),
h=a.toPixels(Math.max(m(a.options.max,a.dataMax),a.dataMax)),g=Math.max(b,h);d.min=Math.min(a.pos,Math.min(b,h)-c);d.max=Math.max(a.pos+a.len,g+c)}}),c.res=!0):c.followTouchMove&&1===w?this.runPointActions(c.normalize(a)):g.length&&(F||(c.selectionMarker=F=E({destroy:b,touch:!0},f.plotBox)),c.pinchTranslate(g,k,e,F,h,v),c.hasPinched=n,c.scaleGroups(e,h),c.res&&(c.res=!1,this.reset(!1,0)))};f.prototype.pinchTranslate=function(a,c,b,f,g,k){this.zoomHor&&this.pinchTranslateDirection(!0,a,c,b,f,g,k);
this.zoomVert&&this.pinchTranslateDirection(!1,a,c,b,f,g,k)};f.prototype.pinchTranslateDirection=function(a,c,b,f,g,k,v,n){var p=this.chart,r=a?"x":"y",w=a?"X":"Y",h="chart"+w,d=a?"width":"height",G=p["plot"+(a?"Left":"Top")],m,e,I=n||1,q=p.inverted,u=p.bounds[a?"h":"v"],l=1===c.length,z=c[0][h],y=b[0][h],A=!l&&c[1][h],E=!l&&b[1][h];b=function(){"number"===typeof E&&20<Math.abs(z-A)&&(I=n||Math.abs(y-E)/Math.abs(z-A));e=(G-y)/I+z;m=p["plot"+(a?"Width":"Height")]/I};b();c=e;if(c<u.min){c=u.min;var C=
!0}else c+m>u.max&&(c=u.max-m,C=!0);C?(y-=.8*(y-v[r][0]),"number"===typeof E&&(E-=.8*(E-v[r][1])),b()):v[r]=[y,E];q||(k[r]=e-G,k[d]=m);k=q?1/I:I;g[d]=m;g[r]=c;f[q?a?"scaleY":"scaleX":"scale"+w]=I;f["translate"+w]=k*G+(y-k*z)};f.prototype.reset=function(a,c){var b=this.chart,f=b.hoverSeries,g=b.hoverPoint,k=b.hoverPoints,v=b.tooltip,n=v&&v.shared?k:g;a&&n&&u(n).forEach(function(c){c.series.isCartesian&&"undefined"===typeof c.plotX&&(a=!1)});if(a)v&&n&&u(n).length&&(v.refresh(n),v.shared&&k?k.forEach(function(a){a.setState(a.state,
!0);a.series.isCartesian&&(a.series.xAxis.crosshair&&a.series.xAxis.drawCrosshair(null,a),a.series.yAxis.crosshair&&a.series.yAxis.drawCrosshair(null,a))}):g&&(g.setState(g.state,!0),b.axes.forEach(function(a){a.crosshair&&g.series[a.coll]===a&&a.drawCrosshair(null,g)})));else{if(g)g.onMouseOut();k&&k.forEach(function(a){a.setState()});if(f)f.onMouseOut();v&&v.hide(c);this.unDocMouseMove&&(this.unDocMouseMove=this.unDocMouseMove());b.axes.forEach(function(a){a.hideCrosshair()});this.hoverX=b.hoverPoints=
b.hoverPoint=null}};f.prototype.runPointActions=function(a,c){var b=this.chart,f=b.tooltip&&b.tooltip.options.enabled?b.tooltip:void 0,k=f?f.shared:!1,w=c||b.hoverPoint,v=w&&w.series||b.hoverSeries;v=this.getHoverData(w,v,b.series,(!a||"touchmove"!==a.type)&&(!!c||v&&v.directTouch&&this.isDirectTouch),k,a);w=v.hoverPoint;var n=v.hoverPoints;c=(v=v.hoverSeries)&&v.tooltipOptions.followPointer;k=k&&v&&!v.noSharedTooltip;if(w&&(w!==b.hoverPoint||f&&f.isHidden)){(b.hoverPoints||[]).forEach(function(a){-1===
n.indexOf(a)&&a.setState()});if(b.hoverSeries!==v)v.onMouseOver();this.applyInactiveState(n);(n||[]).forEach(function(a){a.setState("hover")});b.hoverPoint&&b.hoverPoint.firePointEvent("mouseOut");if(!w.series)return;w.firePointEvent("mouseOver");b.hoverPoints=n;b.hoverPoint=w;f&&f.refresh(k?n:w,a)}else c&&f&&!f.isHidden&&(w=f.getAnchor([{}],a),f.updatePosition({plotX:w[0],plotY:w[1]}));this.unDocMouseMove||(this.unDocMouseMove=N(b.container.ownerDocument,"mousemove",function(a){var c=g[l.hoverChartIndex];
if(c)c.pointer.onDocumentMouseMove(a)}));b.axes.forEach(function(c){var f=m((c.crosshair||{}).snap,!0),g;f&&((g=b.hoverPoint)&&g.series[c.coll]===c||(g=C(n,function(a){return a.series[c.coll]===c})));g||!f?c.drawCrosshair(a,g):c.hideCrosshair()})};f.prototype.scaleGroups=function(a,c){var b=this.chart,f;b.series.forEach(function(g){f=a||g.getPlotBox();g.xAxis&&g.xAxis.zoomEnabled&&g.group&&(g.group.attr(f),g.markerGroup&&(g.markerGroup.attr(f),g.markerGroup.clip(c?b.clipRect:null)),g.dataLabelsGroup&&
g.dataLabelsGroup.attr(f))});b.clipRect.attr(c||b.clipBox)};f.prototype.setDOMEvents=function(){var a=this.chart.container,c=a.ownerDocument;a.onmousedown=this.onContainerMouseDown.bind(this);a.onmousemove=this.onContainerMouseMove.bind(this);a.onclick=this.onContainerClick.bind(this);this.unbindContainerMouseLeave=N(a,"mouseleave",this.onContainerMouseLeave.bind(this));l.unbindDocumentMouseUp||(l.unbindDocumentMouseUp=N(c,"mouseup",this.onDocumentMouseUp.bind(this)));l.hasTouch&&(N(a,"touchstart",
this.onContainerTouchStart.bind(this)),N(a,"touchmove",this.onContainerTouchMove.bind(this)),l.unbindDocumentTouchEnd||(l.unbindDocumentTouchEnd=N(c,"touchend",this.onDocumentTouchEnd.bind(this))))};f.prototype.setHoverChartIndex=function(){var a=this.chart,c=l.charts[m(l.hoverChartIndex,-1)];if(c&&c!==a)c.pointer.onContainerMouseLeave({relatedTarget:!0});c&&c.mouseIsDown||(l.hoverChartIndex=a.index)};f.prototype.touch=function(a,c){var b=this.chart,f;this.setHoverChartIndex();if(1===a.touches.length)if(a=
this.normalize(a),(f=b.isInsidePlot(a.chartX-b.plotLeft,a.chartY-b.plotTop))&&!b.openMenu){c&&this.runPointActions(a);if("touchmove"===a.type){c=this.pinchDown;var g=c[0]?4<=Math.sqrt(Math.pow(c[0].chartX-a.chartX,2)+Math.pow(c[0].chartY-a.chartY,2)):!1}m(g,!0)&&this.pinch(a)}else c&&this.reset();else 2===a.touches.length&&this.pinch(a)};f.prototype.zoomOption=function(a){var c=this.chart,b=c.options.chart,f=b.zoomType||"";c=c.inverted;/touch/.test(a.type)&&(f=m(b.pinchType,f));this.zoomX=a=/x/.test(f);
this.zoomY=f=/y/.test(f);this.zoomHor=a&&!c||f&&c;this.zoomVert=f&&!c||a&&c;this.hasZoom=a||f};return f}();l.Pointer=e;return l.Pointer});P(x,"parts/MSPointer.js",[x["parts/Globals.js"],x["parts/Pointer.js"],x["parts/Utilities.js"]],function(l,e,B){function t(){var m=[];m.item=function(m){return this[m]};E(z,function(e){m.push({pageX:e.pageX,pageY:e.pageY,target:e.target})});return m}function N(m,e,k,g){"touch"!==m.pointerType&&m.pointerType!==m.MSPOINTER_TYPE_TOUCH||!J[l.hoverChartIndex]||(g(m),
g=J[l.hoverChartIndex].pointer,g[e]({type:k,target:m.currentTarget,preventDefault:A,touches:t()}))}var H=this&&this.__extends||function(){var m=function(e,k){m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,b){g.__proto__=b}||function(g,b){for(var f in b)b.hasOwnProperty(f)&&(g[f]=b[f])};return m(e,k)};return function(e,k){function g(){this.constructor=e}m(e,k);e.prototype=null===k?Object.create(k):(g.prototype=k.prototype,new g)}}(),L=B.addEvent,K=B.css,E=B.objectEach,C=B.removeEvent,
J=l.charts,y=l.doc,A=l.noop,z={},q=!!l.win.PointerEvent;return function(m){function e(){return null!==m&&m.apply(this,arguments)||this}H(e,m);e.prototype.batchMSEvents=function(k){k(this.chart.container,q?"pointerdown":"MSPointerDown",this.onContainerPointerDown);k(this.chart.container,q?"pointermove":"MSPointerMove",this.onContainerPointerMove);k(y,q?"pointerup":"MSPointerUp",this.onDocumentPointerUp)};e.prototype.destroy=function(){this.batchMSEvents(C);m.prototype.destroy.call(this)};e.prototype.init=
function(k,g){m.prototype.init.call(this,k,g);this.hasZoom&&K(k.container,{"-ms-touch-action":"none","touch-action":"none"})};e.prototype.onContainerPointerDown=function(k){N(k,"onContainerTouchStart","touchstart",function(g){z[g.pointerId]={pageX:g.pageX,pageY:g.pageY,target:g.currentTarget}})};e.prototype.onContainerPointerMove=function(k){N(k,"onContainerTouchMove","touchmove",function(g){z[g.pointerId]={pageX:g.pageX,pageY:g.pageY};z[g.pointerId].target||(z[g.pointerId].target=g.currentTarget)})};
e.prototype.onDocumentPointerUp=function(k){N(k,"onDocumentTouchEnd","touchend",function(g){delete z[g.pointerId]})};e.prototype.setDOMEvents=function(){m.prototype.setDOMEvents.call(this);(this.hasZoom||this.followTouchMove)&&this.batchMSEvents(L)};return e}(e)});P(x,"parts/Legend.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent,t=e.animObject,N=e.css,H=e.defined,L=e.discardElement,K=e.find,E=e.fireEvent,C=e.format,J=e.isNumber,y=e.merge,A=e.pick,z=e.relativeLength,
q=e.setAnimation,m=e.stableSort,u=e.syncTimeout;e=e.wrap;var k=l.isFirefox,g=l.marginNames,b=l.win,f=function(){function a(a,b){this.allItems=[];this.contentGroup=this.box=void 0;this.display=!1;this.group=void 0;this.offsetWidth=this.maxLegendWidth=this.maxItemWidth=this.legendWidth=this.legendHeight=this.lastLineHeight=this.lastItemY=this.itemY=this.itemX=this.itemMarginTop=this.itemMarginBottom=this.itemHeight=this.initialItemY=0;this.options={};this.padding=0;this.pages=[];this.proximate=!1;this.scrollGroup=
void 0;this.widthOption=this.totalItemWidth=this.titleHeight=this.symbolWidth=this.symbolHeight=0;this.chart=a;this.init(a,b)}a.prototype.init=function(a,b){this.chart=a;this.setOptions(b);b.enabled&&(this.render(),B(this.chart,"endResize",function(){this.legend.positionCheckboxes()}),this.proximate?this.unchartrender=B(this.chart,"render",function(){this.legend.proximatePositions();this.legend.positionItems()}):this.unchartrender&&this.unchartrender())};a.prototype.setOptions=function(a){var c=A(a.padding,
8);this.options=a;this.chart.styledMode||(this.itemStyle=a.itemStyle,this.itemHiddenStyle=y(this.itemStyle,a.itemHiddenStyle));this.itemMarginTop=a.itemMarginTop||0;this.itemMarginBottom=a.itemMarginBottom||0;this.padding=c;this.initialItemY=c-5;this.symbolWidth=A(a.symbolWidth,16);this.pages=[];this.proximate="proximate"===a.layout&&!this.chart.inverted;this.baseline=void 0};a.prototype.update=function(a,b){var c=this.chart;this.setOptions(y(!0,this.options,a));this.destroy();c.isDirtyLegend=c.isDirtyBox=
!0;A(b,!0)&&c.redraw();E(this,"afterUpdate")};a.prototype.colorizeItem=function(a,b){a.legendGroup[b?"removeClass":"addClass"]("highcharts-legend-item-hidden");if(!this.chart.styledMode){var c=this.options,f=a.legendItem,g=a.legendLine,k=a.legendSymbol,n=this.itemHiddenStyle.color;c=b?c.itemStyle.color:n;var r=b?a.color||n:n,m=a.options&&a.options.marker,e={fill:r};f&&f.css({fill:c,color:c});g&&g.attr({stroke:r});k&&(m&&k.isMarker&&(e=a.pointAttribs(),b||(e.stroke=e.fill=n)),k.attr(e))}E(this,"afterColorizeItem",
{item:a,visible:b})};a.prototype.positionItems=function(){this.allItems.forEach(this.positionItem,this);this.chart.isResizing||this.positionCheckboxes()};a.prototype.positionItem=function(a){var c=this.options,b=c.symbolPadding;c=!c.rtl;var f=a._legendItemPos,g=f[0];f=f[1];var k=a.checkbox;if((a=a.legendGroup)&&a.element)a[H(a.translateY)?"animate":"attr"]({translateX:c?g:this.legendWidth-g-2*b-4,translateY:f});k&&(k.x=g,k.y=f)};a.prototype.destroyItem=function(a){var c=a.checkbox;["legendItem","legendLine",
"legendSymbol","legendGroup"].forEach(function(c){a[c]&&(a[c]=a[c].destroy())});c&&L(a.checkbox)};a.prototype.destroy=function(){function a(a){this[a]&&(this[a]=this[a].destroy())}this.getAllItems().forEach(function(c){["legendItem","legendGroup"].forEach(a,c)});"clipRect up down pager nav box title group".split(" ").forEach(a,this);this.display=null};a.prototype.positionCheckboxes=function(){var a=this.group&&this.group.alignAttr,b=this.clipHeight||this.legendHeight,f=this.titleHeight;if(a){var g=
a.translateY;this.allItems.forEach(function(c){var k=c.checkbox;if(k){var p=g+f+k.y+(this.scrollOffset||0)+3;N(k,{left:a.translateX+c.checkboxOffset+k.x-20+"px",top:p+"px",display:this.proximate||p>g-6&&p<g+b-6?"":"none"})}},this)}};a.prototype.renderTitle=function(){var a=this.options,b=this.padding,f=a.title,g=0;f.text&&(this.title||(this.title=this.chart.renderer.label(f.text,b-3,b-4,null,null,null,a.useHTML,null,"legend-title").attr({zIndex:1}),this.chart.styledMode||this.title.css(f.style),this.title.add(this.group)),
f.width||this.title.css({width:this.maxLegendWidth+"px"}),a=this.title.getBBox(),g=a.height,this.offsetWidth=a.width,this.contentGroup.attr({translateY:g}));this.titleHeight=g};a.prototype.setText=function(a){var c=this.options;a.legendItem.attr({text:c.labelFormat?C(c.labelFormat,a,this.chart):c.labelFormatter.call(a)})};a.prototype.renderItem=function(a){var b=this.chart,c=b.renderer,f=this.options,g=this.symbolWidth,k=f.symbolPadding,n=this.itemStyle,F=this.itemHiddenStyle,m="horizontal"===f.layout?
A(f.itemDistance,20):0,e=!f.rtl,h=a.legendItem,d=!a.series,G=!d&&a.series.drawLegendSymbol?a.series:a,M=G.options;M=this.createCheckboxForItem&&M&&M.showCheckbox;m=g+k+m+(M?20:0);var q=f.useHTML,u=a.options.className;h||(a.legendGroup=c.g("legend-item").addClass("highcharts-"+G.type+"-series highcharts-color-"+a.colorIndex+(u?" "+u:"")+(d?" highcharts-series-"+a.index:"")).attr({zIndex:1}).add(this.scrollGroup),a.legendItem=h=c.text("",e?g+k:-k,this.baseline||0,q),b.styledMode||h.css(y(a.visible?
n:F)),h.attr({align:e?"left":"right",zIndex:2}).add(a.legendGroup),this.baseline||(this.fontMetrics=c.fontMetrics(b.styledMode?12:n.fontSize,h),this.baseline=this.fontMetrics.f+3+this.itemMarginTop,h.attr("y",this.baseline)),this.symbolHeight=f.symbolHeight||this.fontMetrics.f,G.drawLegendSymbol(this,a),this.setItemEvents&&this.setItemEvents(a,h,q));M&&!a.checkbox&&this.createCheckboxForItem&&this.createCheckboxForItem(a);this.colorizeItem(a,a.visible);!b.styledMode&&n.width||h.css({width:(f.itemWidth||
this.widthOption||b.spacingBox.width)-m+"px"});this.setText(a);b=h.getBBox();a.itemWidth=a.checkboxOffset=f.itemWidth||a.legendItemWidth||b.width+m;this.maxItemWidth=Math.max(this.maxItemWidth,a.itemWidth);this.totalItemWidth+=a.itemWidth;this.itemHeight=a.itemHeight=Math.round(a.legendItemHeight||b.height||this.symbolHeight)};a.prototype.layoutItem=function(a){var b=this.options,c=this.padding,f="horizontal"===b.layout,g=a.itemHeight,k=this.itemMarginBottom,n=this.itemMarginTop,F=f?A(b.itemDistance,
20):0,m=this.maxLegendWidth;b=b.alignColumns&&this.totalItemWidth>m?this.maxItemWidth:a.itemWidth;f&&this.itemX-c+b>m&&(this.itemX=c,this.lastLineHeight&&(this.itemY+=n+this.lastLineHeight+k),this.lastLineHeight=0);this.lastItemY=n+this.itemY+k;this.lastLineHeight=Math.max(g,this.lastLineHeight);a._legendItemPos=[this.itemX,this.itemY];f?this.itemX+=b:(this.itemY+=n+g+k,this.lastLineHeight=g);this.offsetWidth=this.widthOption||Math.max((f?this.itemX-c-(a.checkbox?0:F):b)+c,this.offsetWidth)};a.prototype.getAllItems=
function(){var a=[];this.chart.series.forEach(function(b){var c=b&&b.options;b&&A(c.showInLegend,H(c.linkedTo)?!1:void 0,!0)&&(a=a.concat(b.legendItems||("point"===c.legendType?b.data:b)))});E(this,"afterGetAllItems",{allItems:a});return a};a.prototype.getAlignment=function(){var a=this.options;return this.proximate?a.align.charAt(0)+"tv":a.floating?"":a.align.charAt(0)+a.verticalAlign.charAt(0)+a.layout.charAt(0)};a.prototype.adjustMargins=function(a,b){var c=this.chart,f=this.options,k=this.getAlignment();
k&&[/(lth|ct|rth)/,/(rtv|rm|rbv)/,/(rbh|cb|lbh)/,/(lbv|lm|ltv)/].forEach(function(p,n){p.test(k)&&!H(a[n])&&(c[g[n]]=Math.max(c[g[n]],c.legend[(n+1)%2?"legendHeight":"legendWidth"]+[1,-1,-1,1][n]*f[n%2?"x":"y"]+A(f.margin,12)+b[n]+(c.titleOffset[n]||0)))})};a.prototype.proximatePositions=function(){var a=this.chart,b=[],f="left"===this.options.align;this.allItems.forEach(function(c){var g=f;if(c.yAxis&&c.points){c.xAxis.options.reversed&&(g=!g);var k=K(g?c.points:c.points.slice(0).reverse(),function(a){return J(a.plotY)});
g=this.itemMarginTop+c.legendItem.getBBox().height+this.itemMarginBottom;var n=c.yAxis.top-a.plotTop;c.visible?(k=k?k.plotY:c.yAxis.height,k+=n-.3*g):k=n+c.yAxis.height;b.push({target:k,size:g,item:c})}},this);l.distribute(b,a.plotHeight);b.forEach(function(b){b.item._legendItemPos[1]=a.plotTop-a.spacing[0]+b.pos})};a.prototype.render=function(){var a=this.chart,b=a.renderer,f=this.group,g=this.box,k=this.options,v=this.padding;this.itemX=v;this.itemY=this.initialItemY;this.lastItemY=this.offsetWidth=
0;this.widthOption=z(k.width,a.spacingBox.width-v);var n=a.spacingBox.width-2*v-k.x;-1<["rm","lm"].indexOf(this.getAlignment().substring(0,2))&&(n/=2);this.maxLegendWidth=this.widthOption||n;f||(this.group=f=b.g("legend").attr({zIndex:7}).add(),this.contentGroup=b.g().attr({zIndex:1}).add(f),this.scrollGroup=b.g().add(this.contentGroup));this.renderTitle();var F=this.getAllItems();m(F,function(a,b){return(a.options&&a.options.legendIndex||0)-(b.options&&b.options.legendIndex||0)});k.reversed&&F.reverse();
this.allItems=F;this.display=n=!!F.length;this.itemHeight=this.totalItemWidth=this.maxItemWidth=this.lastLineHeight=0;F.forEach(this.renderItem,this);F.forEach(this.layoutItem,this);F=(this.widthOption||this.offsetWidth)+v;var e=this.lastItemY+this.lastLineHeight+this.titleHeight;e=this.handleOverflow(e);e+=v;g||(this.box=g=b.rect().addClass("highcharts-legend-box").attr({r:k.borderRadius}).add(f),g.isNew=!0);a.styledMode||g.attr({stroke:k.borderColor,"stroke-width":k.borderWidth||0,fill:k.backgroundColor||
"none"}).shadow(k.shadow);0<F&&0<e&&(g[g.isNew?"attr":"animate"](g.crisp.call({},{x:0,y:0,width:F,height:e},g.strokeWidth())),g.isNew=!1);g[n?"show":"hide"]();a.styledMode&&"none"===f.getStyle("display")&&(F=e=0);this.legendWidth=F;this.legendHeight=e;n&&this.align();this.proximate||this.positionItems();E(this,"afterRender")};a.prototype.align=function(a){void 0===a&&(a=this.chart.spacingBox);var b=this.chart,c=this.options,f=a.y;/(lth|ct|rth)/.test(this.getAlignment())&&0<b.titleOffset[0]?f+=b.titleOffset[0]:
/(lbh|cb|rbh)/.test(this.getAlignment())&&0<b.titleOffset[2]&&(f-=b.titleOffset[2]);f!==a.y&&(a=y(a,{y:f}));this.group.align(y(c,{width:this.legendWidth,height:this.legendHeight,verticalAlign:this.proximate?"top":c.verticalAlign}),!0,a)};a.prototype.handleOverflow=function(a){var b=this,c=this.chart,f=c.renderer,g=this.options,k=g.y,n=this.padding;k=c.spacingBox.height+("top"===g.verticalAlign?-k:k)-n;var F=g.maxHeight,m,e=this.clipRect,h=g.navigation,d=A(h.animation,!0),G=h.arrowSize||12,M=this.nav,
q=this.pages,u,l=this.allItems,z=function(a){"number"===typeof a?e.attr({height:a}):e&&(b.clipRect=e.destroy(),b.contentGroup.clip());b.contentGroup.div&&(b.contentGroup.div.style.clip=a?"rect("+n+"px,9999px,"+(n+a)+"px,0)":"auto")},y=function(a){b[a]=f.circle(0,0,1.3*G).translate(G/2,G/2).add(M);c.styledMode||b[a].attr("fill","rgba(0,0,0,0.0001)");return b[a]};"horizontal"!==g.layout||"middle"===g.verticalAlign||g.floating||(k/=2);F&&(k=Math.min(k,F));q.length=0;a>k&&!1!==h.enabled?(this.clipHeight=
m=Math.max(k-20-this.titleHeight-n,0),this.currentPage=A(this.currentPage,1),this.fullHeight=a,l.forEach(function(a,d){var b=a._legendItemPos[1],c=Math.round(a.legendItem.getBBox().height),h=q.length;if(!h||b-q[h-1]>m&&(u||b)!==q[h-1])q.push(u||b),h++;a.pageIx=h-1;u&&(l[d-1].pageIx=h-1);d===l.length-1&&b+c-q[h-1]>m&&b!==u&&(q.push(b),a.pageIx=h);b!==u&&(u=b)}),e||(e=b.clipRect=f.clipRect(0,n,9999,0),b.contentGroup.clip(e)),z(m),M||(this.nav=M=f.g().attr({zIndex:1}).add(this.group),this.up=f.symbol("triangle",
0,0,G,G).add(M),y("upTracker").on("click",function(){b.scroll(-1,d)}),this.pager=f.text("",15,10).addClass("highcharts-legend-navigation"),c.styledMode||this.pager.css(h.style),this.pager.add(M),this.down=f.symbol("triangle-down",0,0,G,G).add(M),y("downTracker").on("click",function(){b.scroll(1,d)})),b.scroll(0),a=k):M&&(z(),this.nav=M.destroy(),this.scrollGroup.attr({translateY:1}),this.clipHeight=0);return a};a.prototype.scroll=function(a,b){var c=this,f=this.chart,g=this.pages,k=g.length,n=this.currentPage+
a;a=this.clipHeight;var r=this.options.navigation,m=this.pager,e=this.padding;n>k&&(n=k);0<n&&("undefined"!==typeof b&&q(b,f),this.nav.attr({translateX:e,translateY:a+this.padding+7+this.titleHeight,visibility:"visible"}),[this.up,this.upTracker].forEach(function(a){a.attr({"class":1===n?"highcharts-legend-nav-inactive":"highcharts-legend-nav-active"})}),m.attr({text:n+"/"+k}),[this.down,this.downTracker].forEach(function(a){a.attr({x:18+this.pager.getBBox().width,"class":n===k?"highcharts-legend-nav-inactive":
"highcharts-legend-nav-active"})},this),f.styledMode||(this.up.attr({fill:1===n?r.inactiveColor:r.activeColor}),this.upTracker.css({cursor:1===n?"default":"pointer"}),this.down.attr({fill:n===k?r.inactiveColor:r.activeColor}),this.downTracker.css({cursor:n===k?"default":"pointer"})),this.scrollOffset=-g[n-1]+this.initialItemY,this.scrollGroup.animate({translateY:this.scrollOffset}),this.currentPage=n,this.positionCheckboxes(),b=t(A(b,f.renderer.globalAnimation,!0)),u(function(){E(c,"afterScroll",
{currentPage:n})},b.duration||0))};return a}();(/Trident\/7\.0/.test(b.navigator&&b.navigator.userAgent)||k)&&e(f.prototype,"positionItem",function(a,b){var c=this,f=function(){b._legendItemPos&&a.call(c,b)};f();c.bubbleLegend||setTimeout(f)});l.Legend=f;return l.Legend});P(x,"parts/Chart.js",[x["parts/Globals.js"],x["parts/Legend.js"],x["parts/MSPointer.js"],x["parts/Pointer.js"],x["parts/Time.js"],x["parts/Utilities.js"]],function(l,e,B,t,N,H){var L=H.addEvent,K=H.animate,E=H.animObject,C=H.attr,
J=H.createElement,y=H.css,A=H.defined,z=H.discardElement,q=H.erase,m=H.error,u=H.extend,k=H.find,g=H.fireEvent,b=H.getStyle,f=H.isArray,a=H.isFunction,c=H.isNumber,r=H.isObject,p=H.isString,I=H.merge,w=H.numberFormat,v=H.objectEach,n=H.pick,F=H.pInt,O=H.relativeLength,D=H.removeEvent,h=H.setAnimation,d=H.splat,G=H.syncTimeout,M=H.uniqueKey,Q=l.doc,S=l.Axis,Z=l.defaultOptions,U=l.charts,W=l.marginNames,V=l.seriesTypes,x=l.win,ca=l.Chart=function(){this.getArgs.apply(this,arguments)};l.chart=function(a,
d,b){return new ca(a,d,b)};u(ca.prototype,{callbacks:[],getArgs:function(){var a=[].slice.call(arguments);if(p(a[0])||a[0].nodeName)this.renderTo=a.shift();this.init(a[0],a[1])},init:function(d,b){var c,h=d.series,f=d.plotOptions||{};g(this,"init",{args:arguments},function(){d.series=null;c=I(Z,d);var k=c.chart||{};v(c.plotOptions,function(a,d){r(a)&&(a.tooltip=f[d]&&I(f[d].tooltip)||void 0)});c.tooltip.userOptions=d.chart&&d.chart.forExport&&d.tooltip.userOptions||d.tooltip;c.series=d.series=h;this.userOptions=
d;var n=k.events;this.margin=[];this.spacing=[];this.bounds={h:{},v:{}};this.labelCollectors=[];this.callback=b;this.isResizing=0;this.options=c;this.axes=[];this.series=[];this.time=d.time&&Object.keys(d.time).length?new N(d.time):l.time;this.numberFormatter=k.numberFormatter||w;this.styledMode=k.styledMode;this.hasCartesianSeries=k.showAxes;var p=this;p.index=U.length;U.push(p);l.chartCount++;n&&v(n,function(d,b){a(d)&&L(p,b,d)});p.xAxis=[];p.yAxis=[];p.pointCount=p.colorCounter=p.symbolCounter=
0;g(p,"afterInit");p.firstRender()})},initSeries:function(a){var d=this.options.chart;d=a.type||d.type||d.defaultSeriesType;var b=V[d];b||m(17,!0,this,{missingModuleFor:d});d=new b;d.init(this,a);return d},setSeriesData:function(){this.getSeriesOrderByLinks().forEach(function(a){a.points||a.data||!a.enabledDataSorting||a.setData(a.options.data,!1)})},getSeriesOrderByLinks:function(){return this.series.concat().sort(function(a,d){return a.linkedSeries.length||d.linkedSeries.length?d.linkedSeries.length-
a.linkedSeries.length:0})},orderSeries:function(a){var d=this.series;for(a=a||0;a<d.length;a++)d[a]&&(d[a].index=a,d[a].name=d[a].getName())},isInsidePlot:function(a,d,b){var c=b?d:a;a=b?a:d;c={x:c,y:a,isInsidePlot:0<=c&&c<=this.plotWidth&&0<=a&&a<=this.plotHeight};g(this,"afterIsInsidePlot",c);return c.isInsidePlot},redraw:function(a){g(this,"beforeRedraw");var d=this.axes,b=this.series,c=this.pointer,f=this.legend,k=this.userOptions.legend,n=this.isDirtyLegend,p=this.hasCartesianSeries,v=this.isDirtyBox,
w=this.renderer,r=w.isHidden(),F=[];this.setResponsive&&this.setResponsive(!1);h(this.hasRendered?a:!1,this);r&&this.temporaryDisplay();this.layOutTitles();for(a=b.length;a--;){var G=b[a];if(G.options.stacking){var m=!0;if(G.isDirty){var e=!0;break}}}if(e)for(a=b.length;a--;)G=b[a],G.options.stacking&&(G.isDirty=!0);b.forEach(function(a){a.isDirty&&("point"===a.options.legendType?(a.updateTotals&&a.updateTotals(),n=!0):k&&(k.labelFormatter||k.labelFormat)&&(n=!0));a.isDirtyData&&g(a,"updatedData")});
n&&f&&f.options.enabled&&(f.render(),this.isDirtyLegend=!1);m&&this.getStacks();p&&d.forEach(function(a){a.updateNames();a.setScale()});this.getMargins();p&&(d.forEach(function(a){a.isDirty&&(v=!0)}),d.forEach(function(a){var d=a.min+","+a.max;a.extKey!==d&&(a.extKey=d,F.push(function(){g(a,"afterSetExtremes",u(a.eventArgs,a.getExtremes()));delete a.eventArgs}));(v||m)&&a.redraw()}));v&&this.drawChartBox();g(this,"predraw");b.forEach(function(a){(v||a.isDirty)&&a.visible&&a.redraw();a.isDirtyData=
!1});c&&c.reset(!0);w.draw();g(this,"redraw");g(this,"render");r&&this.temporaryDisplay(!0);F.forEach(function(a){a.call()})},get:function(a){function d(d){return d.id===a||d.options&&d.options.id===a}var b=this.series,c;var h=k(this.axes,d)||k(this.series,d);for(c=0;!h&&c<b.length;c++)h=k(b[c].points||[],d);return h},getAxes:function(){var a=this,b=this.options,c=b.xAxis=d(b.xAxis||{});b=b.yAxis=d(b.yAxis||{});g(this,"getAxes");c.forEach(function(a,d){a.index=d;a.isX=!0});b.forEach(function(a,d){a.index=
d});c.concat(b).forEach(function(d){new S(a,d)});g(this,"afterGetAxes")},getSelectedPoints:function(){var a=[];this.series.forEach(function(d){a=a.concat(d.getPointsCollection().filter(function(a){return n(a.selectedStaging,a.selected)}))});return a},getSelectedSeries:function(){return this.series.filter(function(a){return a.selected})},setTitle:function(a,d,b){this.applyDescription("title",a);this.applyDescription("subtitle",d);this.applyDescription("caption",void 0);this.layOutTitles(b)},applyDescription:function(a,
d){var b=this,c="title"===a?{color:"#333333",fontSize:this.options.isStock?"16px":"18px"}:{color:"#666666"};c=this.options[a]=I(!this.styledMode&&{style:c},this.options[a],d);var h=this[a];h&&d&&(this[a]=h=h.destroy());c&&!h&&(h=this.renderer.text(c.text,0,0,c.useHTML).attr({align:c.align,"class":"highcharts-"+a,zIndex:c.zIndex||4}).add(),h.update=function(d){b[{title:"setTitle",subtitle:"setSubtitle",caption:"setCaption"}[a]](d)},this.styledMode||h.css(c.style),this[a]=h)},layOutTitles:function(a){var d=
[0,0,0],b=this.renderer,c=this.spacingBox;["title","subtitle","caption"].forEach(function(a){var h=this[a],f=this.options[a],g=f.verticalAlign||"top";a="title"===a?-3:"top"===g?d[0]+2:0;if(h){if(!this.styledMode)var k=f.style.fontSize;k=b.fontMetrics(k,h).b;h.css({width:(f.width||c.width+(f.widthAdjust||0))+"px"});var n=Math.round(h.getBBox(f.useHTML).height);h.align(u({y:"bottom"===g?k:a+k,height:n},f),!1,"spacingBox");f.floating||("top"===g?d[0]=Math.ceil(d[0]+n):"bottom"===g&&(d[2]=Math.ceil(d[2]+
n)))}},this);d[0]&&"top"===(this.options.title.verticalAlign||"top")&&(d[0]+=this.options.title.margin);d[2]&&"bottom"===this.options.caption.verticalAlign&&(d[2]+=this.options.caption.margin);var h=!this.titleOffset||this.titleOffset.join(",")!==d.join(",");this.titleOffset=d;g(this,"afterLayOutTitles");!this.isDirtyBox&&h&&(this.isDirtyBox=this.isDirtyLegend=h,this.hasRendered&&n(a,!0)&&this.isDirtyBox&&this.redraw())},getChartSize:function(){var a=this.options.chart,d=a.width;a=a.height;var c=
this.renderTo;A(d)||(this.containerWidth=b(c,"width"));A(a)||(this.containerHeight=b(c,"height"));this.chartWidth=Math.max(0,d||this.containerWidth||600);this.chartHeight=Math.max(0,O(a,this.chartWidth)||(1<this.containerHeight?this.containerHeight:400))},temporaryDisplay:function(a){var d=this.renderTo;if(a)for(;d&&d.style;)d.hcOrigStyle&&(y(d,d.hcOrigStyle),delete d.hcOrigStyle),d.hcOrigDetached&&(Q.body.removeChild(d),d.hcOrigDetached=!1),d=d.parentNode;else for(;d&&d.style;){Q.body.contains(d)||
d.parentNode||(d.hcOrigDetached=!0,Q.body.appendChild(d));if("none"===b(d,"display",!1)||d.hcOricDetached)d.hcOrigStyle={display:d.style.display,height:d.style.height,overflow:d.style.overflow},a={display:"block",overflow:"hidden"},d!==this.renderTo&&(a.height=0),y(d,a),d.offsetWidth||d.style.setProperty("display","block","important");d=d.parentNode;if(d===Q.body)break}},setClassName:function(a){this.container.className="highcharts-container "+(a||"")},getContainer:function(){var a=this.options,d=
a.chart;var b=this.renderTo;var f=M(),k,n;b||(this.renderTo=b=d.renderTo);p(b)&&(this.renderTo=b=Q.getElementById(b));b||m(13,!0,this);var v=F(C(b,"data-highcharts-chart"));c(v)&&U[v]&&U[v].hasRendered&&U[v].destroy();C(b,"data-highcharts-chart",this.index);b.innerHTML="";d.skipClone||b.offsetWidth||this.temporaryDisplay();this.getChartSize();v=this.chartWidth;var w=this.chartHeight;y(b,{overflow:"hidden"});this.styledMode||(k=u({position:"relative",overflow:"hidden",width:v+"px",height:w+"px",textAlign:"left",
lineHeight:"normal",zIndex:0,"-webkit-tap-highlight-color":"rgba(0,0,0,0)"},d.style));this.container=b=J("div",{id:f},k,b);this._cursor=b.style.cursor;this.renderer=new (l[d.renderer]||l.Renderer)(b,v,w,null,d.forExport,a.exporting&&a.exporting.allowHTML,this.styledMode);h(void 0,this);this.setClassName(d.className);if(this.styledMode)for(n in a.defs)this.renderer.definition(a.defs[n]);else this.renderer.setStyle(d.style);this.renderer.chartIndex=this.index;g(this,"afterGetContainer")},getMargins:function(a){var d=
this.spacing,b=this.margin,c=this.titleOffset;this.resetMargins();c[0]&&!A(b[0])&&(this.plotTop=Math.max(this.plotTop,c[0]+d[0]));c[2]&&!A(b[2])&&(this.marginBottom=Math.max(this.marginBottom,c[2]+d[2]));this.legend&&this.legend.display&&this.legend.adjustMargins(b,d);g(this,"getMargins");a||this.getAxisMargins()},getAxisMargins:function(){var a=this,d=a.axisOffset=[0,0,0,0],b=a.colorAxis,c=a.margin,h=function(a){a.forEach(function(a){a.visible&&a.getOffset()})};a.hasCartesianSeries?h(a.axes):b&&
b.length&&h(b);W.forEach(function(b,h){A(c[h])||(a[b]+=d[h])});a.setChartSize()},reflow:function(a){var d=this,c=d.options.chart,h=d.renderTo,f=A(c.width)&&A(c.height),g=c.width||b(h,"width");c=c.height||b(h,"height");h=a?a.target:x;if(!f&&!d.isPrinting&&g&&c&&(h===x||h===Q)){if(g!==d.containerWidth||c!==d.containerHeight)H.clearTimeout(d.reflowTimeout),d.reflowTimeout=G(function(){d.container&&d.setSize(void 0,void 0,!1)},a?100:0);d.containerWidth=g;d.containerHeight=c}},setReflow:function(a){var d=
this;!1===a||this.unbindReflow?!1===a&&this.unbindReflow&&(this.unbindReflow=this.unbindReflow()):(this.unbindReflow=L(x,"resize",function(a){d.options&&d.reflow(a)}),L(this,"destroy",this.unbindReflow))},setSize:function(a,d,b){var c=this,f=c.renderer;c.isResizing+=1;h(b,c);b=f.globalAnimation;c.oldChartHeight=c.chartHeight;c.oldChartWidth=c.chartWidth;"undefined"!==typeof a&&(c.options.chart.width=a);"undefined"!==typeof d&&(c.options.chart.height=d);c.getChartSize();c.styledMode||(b?K:y)(c.container,
{width:c.chartWidth+"px",height:c.chartHeight+"px"},b);c.setChartSize(!0);f.setSize(c.chartWidth,c.chartHeight,b);c.axes.forEach(function(a){a.isDirty=!0;a.setScale()});c.isDirtyLegend=!0;c.isDirtyBox=!0;c.layOutTitles();c.getMargins();c.redraw(b);c.oldChartHeight=null;g(c,"resize");G(function(){c&&g(c,"endResize",null,function(){--c.isResizing})},E(b).duration||0)},setChartSize:function(a){var d=this.inverted,b=this.renderer,c=this.chartWidth,h=this.chartHeight,f=this.options.chart,k=this.spacing,
n=this.clipOffset,p,v,w,r;this.plotLeft=p=Math.round(this.plotLeft);this.plotTop=v=Math.round(this.plotTop);this.plotWidth=w=Math.max(0,Math.round(c-p-this.marginRight));this.plotHeight=r=Math.max(0,Math.round(h-v-this.marginBottom));this.plotSizeX=d?r:w;this.plotSizeY=d?w:r;this.plotBorderWidth=f.plotBorderWidth||0;this.spacingBox=b.spacingBox={x:k[3],y:k[0],width:c-k[3]-k[1],height:h-k[0]-k[2]};this.plotBox=b.plotBox={x:p,y:v,width:w,height:r};c=2*Math.floor(this.plotBorderWidth/2);d=Math.ceil(Math.max(c,
n[3])/2);b=Math.ceil(Math.max(c,n[0])/2);this.clipBox={x:d,y:b,width:Math.floor(this.plotSizeX-Math.max(c,n[1])/2-d),height:Math.max(0,Math.floor(this.plotSizeY-Math.max(c,n[2])/2-b))};a||this.axes.forEach(function(a){a.setAxisSize();a.setAxisTranslation()});g(this,"afterSetChartSize",{skipAxes:a})},resetMargins:function(){g(this,"resetMargins");var a=this,d=a.options.chart;["margin","spacing"].forEach(function(b){var c=d[b],h=r(c)?c:[c,c,c,c];["Top","Right","Bottom","Left"].forEach(function(c,f){a[b][f]=
n(d[b+c],h[f])})});W.forEach(function(d,b){a[d]=n(a.margin[b],a.spacing[b])});a.axisOffset=[0,0,0,0];a.clipOffset=[0,0,0,0]},drawChartBox:function(){var a=this.options.chart,d=this.renderer,b=this.chartWidth,c=this.chartHeight,h=this.chartBackground,f=this.plotBackground,k=this.plotBorder,n=this.styledMode,p=this.plotBGImage,v=a.backgroundColor,w=a.plotBackgroundColor,r=a.plotBackgroundImage,G,F=this.plotLeft,m=this.plotTop,e=this.plotWidth,M=this.plotHeight,q=this.plotBox,u=this.clipRect,D=this.clipBox,
l="animate";h||(this.chartBackground=h=d.rect().addClass("highcharts-background").add(),l="attr");if(n)var O=G=h.strokeWidth();else{O=a.borderWidth||0;G=O+(a.shadow?8:0);v={fill:v||"none"};if(O||h["stroke-width"])v.stroke=a.borderColor,v["stroke-width"]=O;h.attr(v).shadow(a.shadow)}h[l]({x:G/2,y:G/2,width:b-G-O%2,height:c-G-O%2,r:a.borderRadius});l="animate";f||(l="attr",this.plotBackground=f=d.rect().addClass("highcharts-plot-background").add());f[l](q);n||(f.attr({fill:w||"none"}).shadow(a.plotShadow),
r&&(p?(r!==p.attr("href")&&p.attr("href",r),p.animate(q)):this.plotBGImage=d.image(r,F,m,e,M).add()));u?u.animate({width:D.width,height:D.height}):this.clipRect=d.clipRect(D);l="animate";k||(l="attr",this.plotBorder=k=d.rect().addClass("highcharts-plot-border").attr({zIndex:1}).add());n||k.attr({stroke:a.plotBorderColor,"stroke-width":a.plotBorderWidth||0,fill:"none"});k[l](k.crisp({x:F,y:m,width:e,height:M},-k.strokeWidth()));this.isDirtyBox=!1;g(this,"afterDrawChartBox")},propFromSeries:function(){var a=
this,d=a.options.chart,b,c=a.options.series,h,f;["inverted","angular","polar"].forEach(function(g){b=V[d.type||d.defaultSeriesType];f=d[g]||b&&b.prototype[g];for(h=c&&c.length;!f&&h--;)(b=V[c[h].type])&&b.prototype[g]&&(f=!0);a[g]=f})},linkSeries:function(){var a=this,d=a.series;d.forEach(function(a){a.linkedSeries.length=0});d.forEach(function(d){var b=d.options.linkedTo;p(b)&&(b=":previous"===b?a.series[d.index-1]:a.get(b))&&b.linkedParent!==d&&(b.linkedSeries.push(d),d.linkedParent=b,b.enabledDataSorting&&
d.setDataSortingOptions(),d.visible=n(d.options.visible,b.options.visible,d.visible))});g(this,"afterLinkSeries")},renderSeries:function(){this.series.forEach(function(a){a.translate();a.render()})},renderLabels:function(){var a=this,d=a.options.labels;d.items&&d.items.forEach(function(b){var c=u(d.style,b.style),h=F(c.left)+a.plotLeft,f=F(c.top)+a.plotTop+12;delete c.left;delete c.top;a.renderer.text(b.html,h,f).attr({zIndex:2}).css(c).add()})},render:function(){var a=this.axes,d=this.colorAxis,
b=this.renderer,c=this.options,h=0,f=function(a){a.forEach(function(a){a.visible&&a.render()})};this.setTitle();this.legend=new e(this,c.legend);this.getStacks&&this.getStacks();this.getMargins(!0);this.setChartSize();c=this.plotWidth;a.some(function(a){if(a.horiz&&a.visible&&a.options.labels.enabled&&a.series.length)return h=21,!0});var g=this.plotHeight=Math.max(this.plotHeight-h,0);a.forEach(function(a){a.setScale()});this.getAxisMargins();var k=1.1<c/this.plotWidth;var n=1.05<g/this.plotHeight;
if(k||n)a.forEach(function(a){(a.horiz&&k||!a.horiz&&n)&&a.setTickInterval(!0)}),this.getMargins();this.drawChartBox();this.hasCartesianSeries?f(a):d&&d.length&&f(d);this.seriesGroup||(this.seriesGroup=b.g("series-group").attr({zIndex:3}).add());this.renderSeries();this.renderLabels();this.addCredits();this.setResponsive&&this.setResponsive();this.updateContainerScaling();this.hasRendered=!0},addCredits:function(a){var d=this;a=I(!0,this.options.credits,a);a.enabled&&!this.credits&&(this.credits=
this.renderer.text(a.text+(this.mapCredits||""),0,0).addClass("highcharts-credits").on("click",function(){a.href&&(x.location.href=a.href)}).attr({align:a.position.align,zIndex:8}),d.styledMode||this.credits.css(a.style),this.credits.add().align(a.position),this.credits.update=function(a){d.credits=d.credits.destroy();d.addCredits(a)})},updateContainerScaling:function(){var a=this.container;if(a.offsetWidth&&a.offsetHeight&&a.getBoundingClientRect){var d=a.getBoundingClientRect(),b=d.width/a.offsetWidth;
a=d.height/a.offsetHeight;1!==b||1!==a?this.containerScaling={scaleX:b,scaleY:a}:delete this.containerScaling}},destroy:function(){var a=this,d=a.axes,b=a.series,c=a.container,h,f=c&&c.parentNode;g(a,"destroy");a.renderer.forExport?q(U,a):U[a.index]=void 0;l.chartCount--;a.renderTo.removeAttribute("data-highcharts-chart");D(a);for(h=d.length;h--;)d[h]=d[h].destroy();this.scroller&&this.scroller.destroy&&this.scroller.destroy();for(h=b.length;h--;)b[h]=b[h].destroy();"title subtitle chartBackground plotBackground plotBGImage plotBorder seriesGroup clipRect credits pointer rangeSelector legend resetZoomButton tooltip renderer".split(" ").forEach(function(d){var b=
a[d];b&&b.destroy&&(a[d]=b.destroy())});c&&(c.innerHTML="",D(c),f&&z(c));v(a,function(d,b){delete a[b]})},firstRender:function(){var a=this,d=a.options;if(!a.isReadyToRender||a.isReadyToRender()){a.getContainer();a.resetMargins();a.setChartSize();a.propFromSeries();a.getAxes();(f(d.series)?d.series:[]).forEach(function(d){a.initSeries(d)});a.linkSeries();a.setSeriesData();g(a,"beforeRender");t&&(a.pointer=l.hasTouch||!x.PointerEvent&&!x.MSPointerEvent?new t(a,d):new B(a,d));a.render();if(!a.renderer.imgCount&&
!a.hasLoaded)a.onload();a.temporaryDisplay(!0)}},onload:function(){this.callbacks.concat([this.callback]).forEach(function(a){a&&"undefined"!==typeof this.index&&a.apply(this,[this])},this);g(this,"load");g(this,"render");A(this.index)&&this.setReflow(this.options.chart.reflow);this.hasLoaded=!0}})});P(x,"parts/ScrollablePlotArea.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent,t=e.createElement,N=e.pick,H=e.stop;e=l.Chart;"";B(e,"afterSetChartSize",function(e){var t=
this.options.chart.scrollablePlotArea,E=t&&t.minWidth;t=t&&t.minHeight;if(!this.renderer.forExport){if(E){if(this.scrollablePixelsX=E=Math.max(0,E-this.chartWidth)){this.plotWidth+=E;this.inverted?(this.clipBox.height+=E,this.plotBox.height+=E):(this.clipBox.width+=E,this.plotBox.width+=E);var C={1:{name:"right",value:E}}}}else t&&(this.scrollablePixelsY=E=Math.max(0,t-this.chartHeight))&&(this.plotHeight+=E,this.inverted?(this.clipBox.width+=E,this.plotBox.width+=E):(this.clipBox.height+=E,this.plotBox.height+=
E),C={2:{name:"bottom",value:E}});C&&!e.skipAxes&&this.axes.forEach(function(e){C[e.side]?e.getPlotLinePath=function(){var y=C[e.side].name,A=this[y];this[y]=A-C[e.side].value;var z=l.Axis.prototype.getPlotLinePath.apply(this,arguments);this[y]=A;return z}:(e.setAxisSize(),e.setAxisTranslation())})}});B(e,"render",function(){this.scrollablePixelsX||this.scrollablePixelsY?(this.setUpScrolling&&this.setUpScrolling(),this.applyFixed()):this.fixedDiv&&this.applyFixed()});e.prototype.setUpScrolling=function(){var e=
this,l={WebkitOverflowScrolling:"touch",overflowX:"hidden",overflowY:"hidden"};this.scrollablePixelsX&&(l.overflowX="auto");this.scrollablePixelsY&&(l.overflowY="auto");this.scrollingContainer=t("div",{className:"highcharts-scrolling"},l,this.renderTo);B(this.scrollingContainer,"scroll",function(){e.pointer&&delete e.pointer.chartPosition});this.innerContainer=t("div",{className:"highcharts-inner-container"},null,this.scrollingContainer);this.innerContainer.appendChild(this.container);this.setUpScrolling=
null};e.prototype.moveFixedElements=function(){var e=this.container,l=this.fixedRenderer,E=".highcharts-contextbutton .highcharts-credits .highcharts-legend .highcharts-legend-checkbox .highcharts-navigator-series .highcharts-navigator-xaxis .highcharts-navigator-yaxis .highcharts-navigator .highcharts-reset-zoom .highcharts-scrollbar .highcharts-subtitle .highcharts-title".split(" "),C;this.scrollablePixelsX&&!this.inverted?C=".highcharts-yaxis":this.scrollablePixelsX&&this.inverted?C=".highcharts-xaxis":
this.scrollablePixelsY&&!this.inverted?C=".highcharts-xaxis":this.scrollablePixelsY&&this.inverted&&(C=".highcharts-yaxis");E.push(C,C+"-labels");E.forEach(function(E){[].forEach.call(e.querySelectorAll(E),function(e){(e.namespaceURI===l.SVG_NS?l.box:l.box.parentNode).appendChild(e);e.style.pointerEvents="auto"})})};e.prototype.applyFixed=function(){var e,K,E=!this.fixedDiv,C=this.options.chart.scrollablePlotArea;E?(this.fixedDiv=t("div",{className:"highcharts-fixed"},{position:"absolute",overflow:"hidden",
pointerEvents:"none",zIndex:2},null,!0),this.renderTo.insertBefore(this.fixedDiv,this.renderTo.firstChild),this.renderTo.style.overflow="visible",this.fixedRenderer=K=new l.Renderer(this.fixedDiv,this.chartWidth,this.chartHeight,null===(e=this.options.chart)||void 0===e?void 0:e.style),this.scrollableMask=K.path().attr({fill:this.options.chart.backgroundColor||"#fff","fill-opacity":N(C.opacity,.85),zIndex:-1}).addClass("highcharts-scrollable-mask").add(),this.moveFixedElements(),B(this,"afterShowResetZoom",
this.moveFixedElements),B(this,"afterLayOutTitles",this.moveFixedElements)):this.fixedRenderer.setSize(this.chartWidth,this.chartHeight);e=this.chartWidth+(this.scrollablePixelsX||0);K=this.chartHeight+(this.scrollablePixelsY||0);H(this.container);this.container.style.width=e+"px";this.container.style.height=K+"px";this.renderer.boxWrapper.attr({width:e,height:K,viewBox:[0,0,e,K].join(" ")});this.chartBackground.attr({width:e,height:K});this.scrollingContainer.style.height=this.chartHeight+"px";E&&
(C.scrollPositionX&&(this.scrollingContainer.scrollLeft=this.scrollablePixelsX*C.scrollPositionX),C.scrollPositionY&&(this.scrollingContainer.scrollTop=this.scrollablePixelsY*C.scrollPositionY));K=this.axisOffset;E=this.plotTop-K[0]-1;C=this.plotLeft-K[3]-1;e=this.plotTop+this.plotHeight+K[2]+1;K=this.plotLeft+this.plotWidth+K[1]+1;var J=this.plotLeft+this.plotWidth-(this.scrollablePixelsX||0),y=this.plotTop+this.plotHeight-(this.scrollablePixelsY||0);E=this.scrollablePixelsX?[["M",0,E],["L",this.plotLeft-
1,E],["L",this.plotLeft-1,e],["L",0,e],["Z"],["M",J,E],["L",this.chartWidth,E],["L",this.chartWidth,e],["L",J,e],["Z"]]:this.scrollablePixelsY?[["M",C,0],["L",C,this.plotTop-1],["L",K,this.plotTop-1],["L",K,0],["Z"],["M",C,y],["L",C,this.chartHeight],["L",K,this.chartHeight],["L",K,y],["Z"]]:[["M",0,0]];"adjustHeight"!==this.redrawTrigger&&this.scrollableMask.attr({d:E})}});P(x,"parts/StackingAxis.js",[x["parts/Utilities.js"]],function(l){var e=l.addEvent,B=l.destroyObjectProperties,t=l.fireEvent,
N=l.objectEach,H=l.pick,L=function(){function e(e){this.oldStacks={};this.stacks={};this.stacksTouched=0;this.axis=e}e.prototype.buildStacks=function(){var e=this.axis,l=e.series,J=H(e.options.reversedStacks,!0),y=l.length,A;if(!e.isXAxis){this.usePercentage=!1;for(A=y;A--;){var z=l[J?A:y-A-1];z.setStackedPoints()}for(A=0;A<y;A++)l[A].modifyStacks();t(e,"afterBuildStacks")}};e.prototype.cleanStacks=function(){if(!this.axis.isXAxis){if(this.oldStacks)var e=this.stacks=this.oldStacks;N(e,function(e){N(e,
function(e){e.cumulative=e.total})})}};e.prototype.resetStacks=function(){var e=this,l=e.stacks;e.axis.isXAxis||N(l,function(l){N(l,function(y,A){y.touched<e.stacksTouched?(y.destroy(),delete l[A]):(y.total=null,y.cumulative=null)})})};e.prototype.renderStackTotals=function(){var e=this.axis.chart,l=e.renderer,t=this.stacks,y=this.stackTotalGroup=this.stackTotalGroup||l.g("stack-labels").attr({visibility:"visible",zIndex:6}).add();y.translate(e.plotLeft,e.plotTop);N(t,function(e){N(e,function(e){e.render(y)})})};
return e}();return function(){function l(){}l.compose=function(E){e(E,"init",l.onInit);e(E,"destroy",l.onDestroy)};l.onDestroy=function(){var e=this.stacking;if(e){var l=e.stacks;N(l,function(e,y){B(e);l[y]=null});e&&e.stackTotalGroup&&e.stackTotalGroup.destroy()}};l.onInit=function(){this.stacking||(this.stacking=new L(this))};return l}()});P(x,"mixins/legend-symbol.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.merge,t=e.pick;l.LegendSymbolMixin={drawRectangle:function(e,
l){var B=e.symbolHeight,K=e.options.squareSymbol;l.legendSymbol=this.chart.renderer.rect(K?(e.symbolWidth-B)/2:0,e.baseline-B+1,K?B:e.symbolWidth,B,t(e.options.symbolRadius,B/2)).addClass("highcharts-point").attr({zIndex:3}).add(l.legendGroup)},drawLineMarker:function(e){var l=this.options,L=l.marker,K=e.symbolWidth,E=e.symbolHeight,C=E/2,J=this.chart.renderer,y=this.legendGroup;e=e.baseline-Math.round(.3*e.fontMetrics.b);var A={};this.chart.styledMode||(A={"stroke-width":l.lineWidth||0},l.dashStyle&&
(A.dashstyle=l.dashStyle));this.legendLine=J.path(["M",0,e,"L",K,e]).addClass("highcharts-graph").attr(A).add(y);L&&!1!==L.enabled&&K&&(l=Math.min(t(L.radius,C),C),0===this.symbol.indexOf("url")&&(L=B(L,{width:E,height:E}),l=0),this.legendSymbol=L=J.symbol(this.symbol,K/2-l,e-l,2*l,2*l,L).addClass("highcharts-point").add(y),L.isMarker=!0)}};return l.LegendSymbolMixin});P(x,"parts/Point.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){"";var B=e.animObject,t=e.defined,x=e.erase,H=
e.extend,L=e.fireEvent,K=e.format,E=e.getNestedProperty,C=e.isArray,J=e.isNumber,y=e.isObject,A=e.syncTimeout,z=e.pick,q=e.removeEvent,m=e.uniqueKey;e=function(){function e(){this.colorIndex=this.category=void 0;this.formatPrefix="point";this.id=void 0;this.isNull=!1;this.percentage=this.options=this.name=void 0;this.selected=!1;this.total=this.series=void 0;this.visible=!0;this.x=void 0}e.prototype.animateBeforeDestroy=function(){var k=this,g={x:k.startXPos,opacity:0},b,f=k.getGraphicalProps();f.singular.forEach(function(a){b=
"dataLabel"===a;k[a]=k[a].animate(b?{x:k[a].startXPos,y:k[a].startYPos,opacity:0}:g)});f.plural.forEach(function(a){k[a].forEach(function(a){a.element&&a.animate(H({x:k.startXPos},a.startYPos?{x:a.startXPos,y:a.startYPos}:{}))})})};e.prototype.applyOptions=function(k,g){var b=this.series,f=b.options.pointValKey||b.pointValKey;k=e.prototype.optionsToObject.call(this,k);H(this,k);this.options=this.options?H(this.options,k):k;k.group&&delete this.group;k.dataLabels&&delete this.dataLabels;f&&(this.y=
e.prototype.getNestedProperty.call(this,f));this.formatPrefix=(this.isNull=z(this.isValid&&!this.isValid(),null===this.x||!J(this.y)))?"null":"point";this.selected&&(this.state="select");"name"in this&&"undefined"===typeof g&&b.xAxis&&b.xAxis.hasNames&&(this.x=b.xAxis.nameToX(this));"undefined"===typeof this.x&&b&&(this.x="undefined"===typeof g?b.autoIncrement(this):g);return this};e.prototype.destroy=function(){function k(){if(g.graphic||g.dataLabel||g.dataLabels)q(g),g.destroyElements();for(e in g)g[e]=
null}var g=this,b=g.series,f=b.chart;b=b.options.dataSorting;var a=f.hoverPoints,c=B(g.series.chart.renderer.globalAnimation),e;g.legendItem&&f.legend.destroyItem(g);a&&(g.setState(),x(a,g),a.length||(f.hoverPoints=null));if(g===f.hoverPoint)g.onMouseOut();b&&b.enabled?(this.animateBeforeDestroy(),A(k,c.duration)):k();f.pointCount--};e.prototype.destroyElements=function(k){var g=this;k=g.getGraphicalProps(k);k.singular.forEach(function(b){g[b]=g[b].destroy()});k.plural.forEach(function(b){g[b].forEach(function(b){b.element&&
b.destroy()});delete g[b]})};e.prototype.firePointEvent=function(k,g,b){var f=this,a=this.series.options;(a.point.events[k]||f.options&&f.options.events&&f.options.events[k])&&f.importEvents();"click"===k&&a.allowPointSelect&&(b=function(a){f.select&&f.select(null,a.ctrlKey||a.metaKey||a.shiftKey)});L(f,k,g,b)};e.prototype.getClassName=function(){return"highcharts-point"+(this.selected?" highcharts-point-select":"")+(this.negative?" highcharts-negative":"")+(this.isNull?" highcharts-null-point":"")+
("undefined"!==typeof this.colorIndex?" highcharts-color-"+this.colorIndex:"")+(this.options.className?" "+this.options.className:"")+(this.zone&&this.zone.className?" "+this.zone.className.replace("highcharts-negative",""):"")};e.prototype.getGraphicalProps=function(k){var g=this,b=[],f,a={singular:[],plural:[]};k=k||{graphic:1,dataLabel:1};k.graphic&&b.push("graphic","shadowGroup");k.dataLabel&&b.push("dataLabel","dataLabelUpper","connector");for(f=b.length;f--;){var c=b[f];g[c]&&a.singular.push(c)}["dataLabel",
"connector"].forEach(function(b){var c=b+"s";k[b]&&g[c]&&a.plural.push(c)});return a};e.prototype.getLabelConfig=function(){return{x:this.category,y:this.y,color:this.color,colorIndex:this.colorIndex,key:this.name||this.category,series:this.series,point:this,percentage:this.percentage,total:this.total||this.stackTotal}};e.prototype.getNestedProperty=function(k){if(k)return 0===k.indexOf("custom.")?E(k,this.options):this[k]};e.prototype.getZone=function(){var k=this.series,g=k.zones;k=k.zoneAxis||
"y";var b=0,f;for(f=g[b];this[k]>=f.value;)f=g[++b];this.nonZonedColor||(this.nonZonedColor=this.color);this.color=f&&f.color&&!this.options.color?f.color:this.nonZonedColor;return f};e.prototype.hasNewShapeType=function(){return(this.graphic&&(this.graphic.symbolName||this.graphic.element.nodeName))!==this.shapeType};e.prototype.init=function(k,g,b){this.series=k;this.applyOptions(g,b);this.id=t(this.id)?this.id:m();this.resolveColor();k.chart.pointCount++;L(this,"afterInit");return this};e.prototype.optionsToObject=
function(k){var g={},b=this.series,f=b.options.keys,a=f||b.pointArrayMap||["y"],c=a.length,r=0,p=0;if(J(k)||null===k)g[a[0]]=k;else if(C(k))for(!f&&k.length>c&&(b=typeof k[0],"string"===b?g.name=k[0]:"number"===b&&(g.x=k[0]),r++);p<c;)f&&"undefined"===typeof k[r]||(0<a[p].indexOf(".")?e.prototype.setNestedProperty(g,k[r],a[p]):g[a[p]]=k[r]),r++,p++;else"object"===typeof k&&(g=k,k.dataLabels&&(b._hasPointLabels=!0),k.marker&&(b._hasPointMarkers=!0));return g};e.prototype.resolveColor=function(){var k=
this.series;var g=k.chart.options.chart.colorCount;var b=k.chart.styledMode;delete this.nonZonedColor;b||this.options.color||(this.color=k.color);k.options.colorByPoint?(b||(g=k.options.colors||k.chart.options.colors,this.color=this.color||g[k.colorCounter],g=g.length),b=k.colorCounter,k.colorCounter++,k.colorCounter===g&&(k.colorCounter=0)):b=k.colorIndex;this.colorIndex=z(this.colorIndex,b)};e.prototype.setNestedProperty=function(k,g,b){b.split(".").reduce(function(b,a,c,k){b[a]=k.length-1===c?
g:y(b[a],!0)?b[a]:{};return b[a]},k);return k};e.prototype.tooltipFormatter=function(k){var g=this.series,b=g.tooltipOptions,f=z(b.valueDecimals,""),a=b.valuePrefix||"",c=b.valueSuffix||"";g.chart.styledMode&&(k=g.chart.tooltip.styledModeFormat(k));(g.pointArrayMap||["y"]).forEach(function(b){b="{point."+b;if(a||c)k=k.replace(RegExp(b+"}","g"),a+b+"}"+c);k=k.replace(RegExp(b+"}","g"),b+":,."+f+"f}")});return K(k,{point:this,series:this.series},g.chart)};return e}();l.Point=e;return l.Point});P(x,
"parts/Series.js",[x["mixins/legend-symbol.js"],x["parts/Globals.js"],x["parts/Point.js"],x["parts/Utilities.js"]],function(l,e,B,t){"";var x=t.addEvent,H=t.animObject,L=t.arrayMax,K=t.arrayMin,E=t.clamp,C=t.correctFloat,J=t.defined,y=t.erase,A=t.error,z=t.extend,q=t.find,m=t.fireEvent,u=t.getNestedProperty,k=t.isArray,g=t.isFunction,b=t.isNumber,f=t.isString,a=t.merge,c=t.objectEach,r=t.pick,p=t.removeEvent,I=t.seriesType,w=t.splat,v=t.syncTimeout,n=e.defaultOptions,F=e.defaultPlotOptions,O=e.seriesTypes,
D=e.SVGElement,h=e.win;e.Series=I("line",null,{lineWidth:2,allowPointSelect:!1,crisp:!0,showCheckbox:!1,animation:{duration:1E3},events:{},marker:{enabledThreshold:2,lineColor:"#ffffff",lineWidth:0,radius:4,states:{normal:{animation:!0},hover:{animation:{duration:50},enabled:!0,radiusPlus:2,lineWidthPlus:1},select:{fillColor:"#cccccc",lineColor:"#000000",lineWidth:2}}},point:{events:{}},dataLabels:{align:"center",formatter:function(){var a=this.series.chart.numberFormatter;return"number"!==typeof this.y?
"":a(this.y,-1)},padding:5,style:{fontSize:"11px",fontWeight:"bold",color:"contrast",textOutline:"1px contrast"},verticalAlign:"bottom",x:0,y:0},cropThreshold:300,opacity:1,pointRange:0,softThreshold:!0,states:{normal:{animation:!0},hover:{animation:{duration:50},lineWidthPlus:1,marker:{},halo:{size:10,opacity:.25}},select:{animation:{duration:0}},inactive:{animation:{duration:50},opacity:.2}},stickyTracking:!0,turboThreshold:1E3,findNearestPointBy:"x"},{axisTypes:["xAxis","yAxis"],coll:"series",
colorCounter:0,cropShoulder:1,directTouch:!1,eventsToUnbind:[],isCartesian:!0,parallelArrays:["x","y"],pointClass:B,requireSorting:!0,sorted:!0,init:function(a,b){m(this,"init",{options:b});var d=this,h=a.series,f;this.eventOptions=this.eventOptions||{};d.chart=a;d.options=b=d.setOptions(b);d.linkedSeries=[];d.bindAxes();z(d,{name:b.name,state:"",visible:!1!==b.visible,selected:!0===b.selected});var k=b.events;c(k,function(a,b){g(a)&&d.eventOptions[b]!==a&&(g(d.eventOptions[b])&&p(d,b,d.eventOptions[b]),
d.eventOptions[b]=a,x(d,b,a))});if(k&&k.click||b.point&&b.point.events&&b.point.events.click||b.allowPointSelect)a.runTrackerClick=!0;d.getColor();d.getSymbol();d.parallelArrays.forEach(function(a){d[a+"Data"]||(d[a+"Data"]=[])});d.isCartesian&&(a.hasCartesianSeries=!0);h.length&&(f=h[h.length-1]);d._i=r(f&&f._i,-1)+1;a.orderSeries(this.insert(h));b.dataSorting&&b.dataSorting.enabled?d.setDataSortingOptions():d.points||d.data||d.setData(b.data,!1);m(this,"afterInit")},is:function(a){return O[a]&&
this instanceof O[a]},insert:function(a){var d=this.options.index,c;if(b(d)){for(c=a.length;c--;)if(d>=r(a[c].options.index,a[c]._i)){a.splice(c+1,0,this);break}-1===c&&a.unshift(this);c+=1}else a.push(this);return r(c,a.length-1)},bindAxes:function(){var a=this,b=a.options,c=a.chart,h;m(this,"bindAxes",null,function(){(a.axisTypes||[]).forEach(function(d){c[d].forEach(function(c){h=c.options;if(b[d]===h.index||"undefined"!==typeof b[d]&&b[d]===h.id||"undefined"===typeof b[d]&&0===h.index)a.insert(c.series),
a[d]=c,c.isDirty=!0});a[d]||a.optionalAxis===d||A(18,!0,c)})});m(this,"afterBindAxes")},updateParallelArrays:function(a,c){var d=a.series,h=arguments,f=b(c)?function(b){var h="y"===b&&d.toYData?d.toYData(a):a[b];d[b+"Data"][c]=h}:function(a){Array.prototype[c].apply(d[a+"Data"],Array.prototype.slice.call(h,2))};d.parallelArrays.forEach(f)},hasData:function(){return this.visible&&"undefined"!==typeof this.dataMax&&"undefined"!==typeof this.dataMin||this.visible&&this.yData&&0<this.yData.length},autoIncrement:function(){var a=
this.options,b=this.xIncrement,c,h=a.pointIntervalUnit,f=this.chart.time;b=r(b,a.pointStart,0);this.pointInterval=c=r(this.pointInterval,a.pointInterval,1);h&&(a=new f.Date(b),"day"===h?f.set("Date",a,f.get("Date",a)+c):"month"===h?f.set("Month",a,f.get("Month",a)+c):"year"===h&&f.set("FullYear",a,f.get("FullYear",a)+c),c=a.getTime()-b);this.xIncrement=b+c;return b},setDataSortingOptions:function(){var a=this.options;z(this,{requireSorting:!1,sorted:!1,enabledDataSorting:!0,allowDG:!1});J(a.pointRange)||
(a.pointRange=1)},setOptions:function(d){var b=this.chart,c=b.options,h=c.plotOptions,f=b.userOptions||{};d=a(d);b=b.styledMode;var g={plotOptions:h,userOptions:d};m(this,"setOptions",g);var k=g.plotOptions[this.type],p=f.plotOptions||{};this.userOptions=g.userOptions;f=a(k,h.series,f.plotOptions&&f.plotOptions[this.type],d);this.tooltipOptions=a(n.tooltip,n.plotOptions.series&&n.plotOptions.series.tooltip,n.plotOptions[this.type].tooltip,c.tooltip.userOptions,h.series&&h.series.tooltip,h[this.type].tooltip,
d.tooltip);this.stickyTracking=r(d.stickyTracking,p[this.type]&&p[this.type].stickyTracking,p.series&&p.series.stickyTracking,this.tooltipOptions.shared&&!this.noSharedTooltip?!0:f.stickyTracking);null===k.marker&&delete f.marker;this.zoneAxis=f.zoneAxis;c=this.zones=(f.zones||[]).slice();!f.negativeColor&&!f.negativeFillColor||f.zones||(h={value:f[this.zoneAxis+"Threshold"]||f.threshold||0,className:"highcharts-negative"},b||(h.color=f.negativeColor,h.fillColor=f.negativeFillColor),c.push(h));c.length&&
J(c[c.length-1].value)&&c.push(b?{}:{color:this.color,fillColor:this.fillColor});m(this,"afterSetOptions",{options:f});return f},getName:function(){return r(this.options.name,"Series "+(this.index+1))},getCyclic:function(a,b,c){var d=this.chart,h=this.userOptions,f=a+"Index",g=a+"Counter",k=c?c.length:r(d.options.chart[a+"Count"],d[a+"Count"]);if(!b){var n=r(h[f],h["_"+f]);J(n)||(d.series.length||(d[g]=0),h["_"+f]=n=d[g]%k,d[g]+=1);c&&(b=c[n])}"undefined"!==typeof n&&(this[f]=n);this[a]=b},getColor:function(){this.chart.styledMode?
this.getCyclic("color"):this.options.colorByPoint?this.options.color=null:this.getCyclic("color",this.options.color||F[this.type].color,this.chart.options.colors)},getPointsCollection:function(){return(this.hasGroupedData?this.points:this.data)||[]},getSymbol:function(){this.getCyclic("symbol",this.options.marker.symbol,this.chart.options.symbols)},findPointIndex:function(a,c){var d=a.id,h=a.x,f=this.points,g,k=this.options.dataSorting;if(d)var n=this.chart.get(d);else if(this.linkedParent||this.enabledDataSorting){var p=
k&&k.matchByName?"name":"index";n=q(f,function(d){return!d.touched&&d[p]===a[p]});if(!n)return}if(n){var e=n&&n.index;"undefined"!==typeof e&&(g=!0)}"undefined"===typeof e&&b(h)&&(e=this.xData.indexOf(h,c));-1!==e&&"undefined"!==typeof e&&this.cropped&&(e=e>=this.cropStart?e-this.cropStart:e);!g&&f[e]&&f[e].touched&&(e=void 0);return e},drawLegendSymbol:l.drawLineMarker,updateData:function(a,c){var d=this.options,h=d.dataSorting,f=this.points,g=[],k,n,p,e=this.requireSorting,v=a.length===f.length,
w=!0;this.xIncrement=null;a.forEach(function(a,c){var n=J(a)&&this.pointClass.prototype.optionsToObject.call({series:this},a)||{};var w=n.x;if(n.id||b(w)){if(w=this.findPointIndex(n,p),-1===w||"undefined"===typeof w?g.push(a):f[w]&&a!==d.data[w]?(f[w].update(a,!1,null,!1),f[w].touched=!0,e&&(p=w+1)):f[w]&&(f[w].touched=!0),!v||c!==w||h&&h.enabled||this.hasDerivedData)k=!0}else g.push(a)},this);if(k)for(a=f.length;a--;)(n=f[a])&&!n.touched&&n.remove&&n.remove(!1,c);else!v||h&&h.enabled?w=!1:(a.forEach(function(a,
d){f[d].update&&a!==f[d].y&&f[d].update(a,!1,null,!1)}),g.length=0);f.forEach(function(a){a&&(a.touched=!1)});if(!w)return!1;g.forEach(function(a){this.addPoint(a,!1,null,null,!1)},this);null===this.xIncrement&&this.xData&&this.xData.length&&(this.xIncrement=L(this.xData),this.autoIncrement());return!0},setData:function(a,c,h,g){var d=this,n=d.points,p=n&&n.length||0,e,w=d.options,v=d.chart,F=w.dataSorting,m=null,G=d.xAxis;m=w.turboThreshold;var q=this.xData,l=this.yData,D=(e=d.pointArrayMap)&&e.length,
M=w.keys,u=0,O=1,z;a=a||[];e=a.length;c=r(c,!0);F&&F.enabled&&(a=this.sortData(a));!1!==g&&e&&p&&!d.cropped&&!d.hasGroupedData&&d.visible&&!d.isSeriesBoosting&&(z=this.updateData(a,h));if(!z){d.xIncrement=null;d.colorCounter=0;this.parallelArrays.forEach(function(a){d[a+"Data"].length=0});if(m&&e>m)if(m=d.getFirstValidPoint(a),b(m))for(h=0;h<e;h++)q[h]=this.autoIncrement(),l[h]=a[h];else if(k(m))if(D)for(h=0;h<e;h++)g=a[h],q[h]=g[0],l[h]=g.slice(1,D+1);else for(M&&(u=M.indexOf("x"),O=M.indexOf("y"),
u=0<=u?u:0,O=0<=O?O:1),h=0;h<e;h++)g=a[h],q[h]=g[u],l[h]=g[O];else A(12,!1,v);else for(h=0;h<e;h++)"undefined"!==typeof a[h]&&(g={series:d},d.pointClass.prototype.applyOptions.apply(g,[a[h]]),d.updateParallelArrays(g,h));l&&f(l[0])&&A(14,!0,v);d.data=[];d.options.data=d.userOptions.data=a;for(h=p;h--;)n[h]&&n[h].destroy&&n[h].destroy();G&&(G.minRange=G.userMinRange);d.isDirty=v.isDirtyBox=!0;d.isDirtyData=!!n;h=!1}"point"===w.legendType&&(this.processData(),this.generatePoints());c&&v.redraw(h)},
sortData:function(a){var d=this,b=d.options.dataSorting.sortKey||"y",c=function(a,d){return J(d)&&a.pointClass.prototype.optionsToObject.call({series:a},d)||{}};a.forEach(function(b,h){a[h]=c(d,b);a[h].index=h},this);a.concat().sort(function(a,d){a=u(b,a);d=u(b,d);return d<a?-1:d>a?1:0}).forEach(function(a,d){a.x=d},this);d.linkedSeries&&d.linkedSeries.forEach(function(d){var b=d.options,h=b.data;b.dataSorting&&b.dataSorting.enabled||!h||(h.forEach(function(b,f){h[f]=c(d,b);a[f]&&(h[f].x=a[f].x,h[f].index=
f)}),d.setData(h,!1))});return a},getProcessedData:function(a){var d=this.xData,b=this.yData,c=d.length;var h=0;var f=this.xAxis,g=this.options;var k=g.cropThreshold;var n=a||this.getExtremesFromAll||g.getExtremesFromAll,p=this.isCartesian;a=f&&f.val2lin;g=!(!f||!f.logarithmic);var e=this.requireSorting;if(f){f=f.getExtremes();var w=f.min;var v=f.max}if(p&&this.sorted&&!n&&(!k||c>k||this.forceCrop))if(d[c-1]<w||d[0]>v)d=[],b=[];else if(this.yData&&(d[0]<w||d[c-1]>v)){h=this.cropData(this.xData,this.yData,
w,v);d=h.xData;b=h.yData;h=h.start;var r=!0}for(k=d.length||1;--k;)if(c=g?a(d[k])-a(d[k-1]):d[k]-d[k-1],0<c&&("undefined"===typeof F||c<F))var F=c;else 0>c&&e&&(A(15,!1,this.chart),e=!1);return{xData:d,yData:b,cropped:r,cropStart:h,closestPointRange:F}},processData:function(a){var d=this.xAxis;if(this.isCartesian&&!this.isDirty&&!d.isDirty&&!this.yAxis.isDirty&&!a)return!1;a=this.getProcessedData();this.cropped=a.cropped;this.cropStart=a.cropStart;this.processedXData=a.xData;this.processedYData=a.yData;
this.closestPointRange=this.basePointRange=a.closestPointRange},cropData:function(a,b,c,h,f){var d=a.length,g=0,k=d,n;f=r(f,this.cropShoulder);for(n=0;n<d;n++)if(a[n]>=c){g=Math.max(0,n-f);break}for(c=n;c<d;c++)if(a[c]>h){k=c+f;break}return{xData:a.slice(g,k),yData:b.slice(g,k),start:g,end:k}},generatePoints:function(){var a=this.options,b=a.data,c=this.data,h,f=this.processedXData,g=this.processedYData,k=this.pointClass,n=f.length,p=this.cropStart||0,e=this.hasGroupedData;a=a.keys;var v=[],r;c||
e||(c=[],c.length=b.length,c=this.data=c);a&&e&&(this.options.keys=!1);for(r=0;r<n;r++){var F=p+r;if(e){var q=(new k).init(this,[f[r]].concat(w(g[r])));q.dataGroup=this.groupMap[r];q.dataGroup.options&&(q.options=q.dataGroup.options,z(q,q.dataGroup.options),delete q.dataLabels)}else(q=c[F])||"undefined"===typeof b[F]||(c[F]=q=(new k).init(this,b[F],f[r]));q&&(q.index=F,v[r]=q)}this.options.keys=a;if(c&&(n!==(h=c.length)||e))for(r=0;r<h;r++)r!==p||e||(r+=n),c[r]&&(c[r].destroyElements(),c[r].plotX=
void 0);this.data=c;this.points=v;m(this,"afterGeneratePoints")},getXExtremes:function(a){return{min:K(a),max:L(a)}},getExtremes:function(a,c){var d=this.xAxis,h=this.yAxis,f=this.processedXData||this.xData,g=[],n=0,p=0;var e=0;var v=this.requireSorting?this.cropShoulder:0,w=h?h.positiveValuesOnly:!1,r;a=a||this.stackedYData||this.processedYData||[];h=a.length;d&&(e=d.getExtremes(),p=e.min,e=e.max);for(r=0;r<h;r++){var F=f[r];var G=a[r];var q=(b(G)||k(G))&&(G.length||0<G||!w);F=c||this.getExtremesFromAll||
this.options.getExtremesFromAll||this.cropped||!d||(f[r+v]||F)>=p&&(f[r-v]||F)<=e;if(q&&F)if(q=G.length)for(;q--;)b(G[q])&&(g[n++]=G[q]);else g[n++]=G}a={dataMin:K(g),dataMax:L(g)};m(this,"afterGetExtremes",{dataExtremes:a});return a},applyExtremes:function(){var a=this.getExtremes();this.dataMin=a.dataMin;this.dataMax=a.dataMax;return a},getFirstValidPoint:function(a){for(var d=null,b=a.length,c=0;null===d&&c<b;)d=a[c],c++;return d},translate:function(){this.processedXData||this.processData();this.generatePoints();
var a=this.options,c=a.stacking,h=this.xAxis,f=h.categories,g=this.enabledDataSorting,n=this.yAxis,p=this.points,e=p.length,v=!!this.modifyValue,w,F=this.pointPlacementToXValue(),q=!!F,l=a.threshold,D=a.startFromThreshold?l:0,u,O=this.zoneAxis||"y",z=Number.MAX_VALUE;for(w=0;w<e;w++){var I=p[w],y=I.x,A=I.y,t=I.low,B=c&&n.stacking&&n.stacking.stacks[(this.negStacks&&A<(D?0:l)?"-":"")+this.stackKey];n.positiveValuesOnly&&null!==A&&0>=A&&(I.isNull=!0);I.plotX=u=C(E(h.translate(y,0,0,0,1,F,"flags"===
this.type),-1E5,1E5));if(c&&this.visible&&B&&B[y]){var K=this.getStackIndicator(K,y,this.index);if(!I.isNull){var L=B[y];var H=L.points[K.key]}}k(H)&&(t=H[0],A=H[1],t===D&&K.key===B[y].base&&(t=r(b(l)&&l,n.min)),n.positiveValuesOnly&&0>=t&&(t=null),I.total=I.stackTotal=L.total,I.percentage=L.total&&I.y/L.total*100,I.stackY=A,this.irregularWidths||L.setOffset(this.pointXOffset||0,this.barW||0));I.yBottom=J(t)?E(n.translate(t,0,1,0,1),-1E5,1E5):null;v&&(A=this.modifyValue(A,I));I.plotY="number"===typeof A&&
Infinity!==A?E(n.translate(A,0,1,0,1),-1E5,1E5):void 0;I.isInside=this.isPointInside(I);I.clientX=q?C(h.translate(y,0,0,0,1,F)):u;I.negative=I[O]<(a[O+"Threshold"]||l||0);I.category=f&&"undefined"!==typeof f[I.x]?f[I.x]:I.x;if(!I.isNull&&!1!==I.visible){"undefined"!==typeof x&&(z=Math.min(z,Math.abs(u-x)));var x=u}I.zone=this.zones.length&&I.getZone();!I.graphic&&this.group&&g&&(I.isNew=!0)}this.closestPointRangePx=z;m(this,"afterTranslate")},getValidPoints:function(a,b,c){var d=this.chart;return(a||
this.points||[]).filter(function(a){return b&&!d.isInsidePlot(a.plotX,a.plotY,d.inverted)?!1:!1!==a.visible&&(c||!a.isNull)})},getClipBox:function(a,b){var d=this.options,c=this.chart,h=c.inverted,f=this.xAxis,g=f&&this.yAxis;a&&!1===d.clip&&g?a=h?{y:-c.chartWidth+g.len+g.pos,height:c.chartWidth,width:c.chartHeight,x:-c.chartHeight+f.len+f.pos}:{y:-g.pos,height:c.chartHeight,width:c.chartWidth,x:-f.pos}:(a=this.clipBox||c.clipBox,b&&(a.width=c.plotSizeX,a.x=0));return b?{width:a.width,x:a.x}:a},setClip:function(a){var d=
this.chart,b=this.options,c=d.renderer,h=d.inverted,f=this.clipBox,g=this.getClipBox(a),k=this.sharedClipKey||["_sharedClip",a&&a.duration,a&&a.easing,g.height,b.xAxis,b.yAxis].join(),n=d[k],p=d[k+"m"];a&&(g.width=0,h&&(g.x=d.plotHeight+(!1!==b.clip?0:d.plotTop)));n?d.hasLoaded||n.attr(g):(a&&(d[k+"m"]=p=c.clipRect(h?d.plotSizeX+99:-99,h?-d.plotLeft:-d.plotTop,99,h?d.chartWidth:d.chartHeight)),d[k]=n=c.clipRect(g),n.count={length:0});a&&!n.count[this.index]&&(n.count[this.index]=!0,n.count.length+=
1);if(!1!==b.clip||a)this.group.clip(a||f?n:d.clipRect),this.markerGroup.clip(p),this.sharedClipKey=k;a||(n.count[this.index]&&(delete n.count[this.index],--n.count.length),0===n.count.length&&k&&d[k]&&(f||(d[k]=d[k].destroy()),d[k+"m"]&&(d[k+"m"]=d[k+"m"].destroy())))},animate:function(a){var d=this.chart,b=H(this.options.animation);if(!d.hasRendered)if(a)this.setClip(b);else{var c=this.sharedClipKey;a=d[c];var h=this.getClipBox(b,!0);a&&a.animate(h,b);d[c+"m"]&&d[c+"m"].animate({width:h.width+99,
x:h.x-(d.inverted?0:99)},b)}},afterAnimate:function(){this.setClip();m(this,"afterAnimate");this.finishedAnimating=!0},drawPoints:function(){var a=this.points,b=this.chart,c,h,f=this.options.marker,g=this[this.specialGroup]||this.markerGroup,k=this.xAxis,n=r(f.enabled,!k||k.isRadial?!0:null,this.closestPointRangePx>=f.enabledThreshold*f.radius);if(!1!==f.enabled||this._hasPointMarkers)for(c=0;c<a.length;c++){var p=a[c];var e=(h=p.graphic)?"animate":"attr";var w=p.marker||{};var v=!!p.marker;if((n&&
"undefined"===typeof w.enabled||w.enabled)&&!p.isNull&&!1!==p.visible){var F=r(w.symbol,this.symbol);var m=this.markerAttribs(p,p.selected&&"select");this.enabledDataSorting&&(p.startXPos=k.reversed?-m.width:k.width);var q=!1!==p.isInside;h?h[q?"show":"hide"](q).animate(m):q&&(0<m.width||p.hasImage)&&(p.graphic=h=b.renderer.symbol(F,m.x,m.y,m.width,m.height,v?w:f).add(g),this.enabledDataSorting&&b.hasRendered&&(h.attr({x:p.startXPos}),e="animate"));h&&"animate"===e&&h[q?"show":"hide"](q).animate(m);
if(h&&!b.styledMode)h[e](this.pointAttribs(p,p.selected&&"select"));h&&h.addClass(p.getClassName(),!0)}else h&&(p.graphic=h.destroy())}},markerAttribs:function(a,b){var d=this.options,c=d.marker,h=a.marker||{},f=h.symbol||c.symbol,g=r(h.radius,c.radius);b&&(c=c.states[b],b=h.states&&h.states[b],g=r(b&&b.radius,c&&c.radius,g+(c&&c.radiusPlus||0)));a.hasImage=f&&0===f.indexOf("url");a.hasImage&&(g=0);a={x:d.crisp?Math.floor(a.plotX)-g:a.plotX-g,y:a.plotY-g};g&&(a.width=a.height=2*g);return a},pointAttribs:function(a,
b){var d=this.options.marker,c=a&&a.options,h=c&&c.marker||{},f=this.color,g=c&&c.color,k=a&&a.color;c=r(h.lineWidth,d.lineWidth);var n=a&&a.zone&&a.zone.color;a=1;f=g||n||k||f;g=h.fillColor||d.fillColor||f;f=h.lineColor||d.lineColor||f;b=b||"normal";d=d.states[b];b=h.states&&h.states[b]||{};c=r(b.lineWidth,d.lineWidth,c+r(b.lineWidthPlus,d.lineWidthPlus,0));g=b.fillColor||d.fillColor||g;f=b.lineColor||d.lineColor||f;a=r(b.opacity,d.opacity,a);return{stroke:f,"stroke-width":c,fill:g,opacity:a}},destroy:function(a){var d=
this,b=d.chart,f=/AppleWebKit\/533/.test(h.navigator.userAgent),g,k,n=d.data||[],p,e;m(d,"destroy");this.removeEvents(a);(d.axisTypes||[]).forEach(function(a){(e=d[a])&&e.series&&(y(e.series,d),e.isDirty=e.forceRedraw=!0)});d.legendItem&&d.chart.legend.destroyItem(d);for(k=n.length;k--;)(p=n[k])&&p.destroy&&p.destroy();d.points=null;t.clearTimeout(d.animationTimeout);c(d,function(a,d){a instanceof D&&!a.survive&&(g=f&&"group"===d?"hide":"destroy",a[g]())});b.hoverSeries===d&&(b.hoverSeries=null);
y(b.series,d);b.orderSeries();c(d,function(b,c){a&&"hcEvents"===c||delete d[c]})},getGraphPath:function(a,b,c){var d=this,h=d.options,f=h.step,g,k=[],n=[],p;a=a||d.points;(g=a.reversed)&&a.reverse();(f={right:1,center:2}[f]||f&&3)&&g&&(f=4-f);a=this.getValidPoints(a,!1,!(h.connectNulls&&!b&&!c));a.forEach(function(g,e){var w=g.plotX,v=g.plotY,r=a[e-1];(g.leftCliff||r&&r.rightCliff)&&!c&&(p=!0);g.isNull&&!J(b)&&0<e?p=!h.connectNulls:g.isNull&&!b?p=!0:(0===e||p?e=[["M",g.plotX,g.plotY]]:d.getPointSpline?
e=[d.getPointSpline(a,g,e)]:f?(e=1===f?[["L",r.plotX,v]]:2===f?[["L",(r.plotX+w)/2,r.plotY],["L",(r.plotX+w)/2,v]]:[["L",w,r.plotY]],e.push(["L",w,v])):e=[["L",w,v]],n.push(g.x),f&&(n.push(g.x),2===f&&n.push(g.x)),k.push.apply(k,e),p=!1)});k.xMap=n;return d.graphPath=k},drawGraph:function(){var a=this,b=this.options,c=(this.gappedPath||this.getGraphPath).call(this),h=this.chart.styledMode,f=[["graph","highcharts-graph"]];h||f[0].push(b.lineColor||this.color||"#cccccc",b.dashStyle);f=a.getZonesGraphs(f);
f.forEach(function(d,f){var g=d[0],k=a[g],n=k?"animate":"attr";k?(k.endX=a.preventGraphAnimation?null:c.xMap,k.animate({d:c})):c.length&&(a[g]=k=a.chart.renderer.path(c).addClass(d[1]).attr({zIndex:1}).add(a.group));k&&!h&&(g={stroke:d[2],"stroke-width":b.lineWidth,fill:a.fillGraph&&a.color||"none"},d[3]?g.dashstyle=d[3]:"square"!==b.linecap&&(g["stroke-linecap"]=g["stroke-linejoin"]="round"),k[n](g).shadow(2>f&&b.shadow));k&&(k.startX=c.xMap,k.isArea=c.isArea)})},getZonesGraphs:function(a){this.zones.forEach(function(d,
b){b=["zone-graph-"+b,"highcharts-graph highcharts-zone-graph-"+b+" "+(d.className||"")];this.chart.styledMode||b.push(d.color||this.color,d.dashStyle||this.options.dashStyle);a.push(b)},this);return a},applyZones:function(){var a=this,b=this.chart,c=b.renderer,h=this.zones,f,g,k=this.clips||[],n,p=this.graph,e=this.area,w=Math.max(b.chartWidth,b.chartHeight),v=this[(this.zoneAxis||"y")+"Axis"],F=b.inverted,m,q,l,D=!1,u,O;if(h.length&&(p||e)&&v&&"undefined"!==typeof v.min){var I=v.reversed;var z=
v.horiz;p&&!this.showLine&&p.hide();e&&e.hide();var y=v.getExtremes();h.forEach(function(d,h){f=I?z?b.plotWidth:0:z?0:v.toPixels(y.min)||0;f=E(r(g,f),0,w);g=E(Math.round(v.toPixels(r(d.value,y.max),!0)||0),0,w);D&&(f=g=v.toPixels(y.max));m=Math.abs(f-g);q=Math.min(f,g);l=Math.max(f,g);v.isXAxis?(n={x:F?l:q,y:0,width:m,height:w},z||(n.x=b.plotHeight-n.x)):(n={x:0,y:F?l:q,width:w,height:m},z&&(n.y=b.plotWidth-n.y));F&&c.isVML&&(n=v.isXAxis?{x:0,y:I?q:l,height:n.width,width:b.chartWidth}:{x:n.y-b.plotLeft-
b.spacingBox.x,y:0,width:n.height,height:b.chartHeight});k[h]?k[h].animate(n):k[h]=c.clipRect(n);u=a["zone-area-"+h];O=a["zone-graph-"+h];p&&O&&O.clip(k[h]);e&&u&&u.clip(k[h]);D=d.value>y.max;a.resetZones&&0===g&&(g=void 0)});this.clips=k}else a.visible&&(p&&p.show(!0),e&&e.show(!0))},invertGroups:function(a){function d(){["group","markerGroup"].forEach(function(d){b[d]&&(c.renderer.isVML&&b[d].attr({width:b.yAxis.len,height:b.xAxis.len}),b[d].width=b.yAxis.len,b[d].height=b.xAxis.len,b[d].invert(b.isRadialSeries?
!1:a))})}var b=this,c=b.chart;b.xAxis&&(b.eventsToUnbind.push(x(c,"resize",d)),d(),b.invertGroups=d)},plotGroup:function(a,b,c,h,f){var d=this[a],g=!d;g&&(this[a]=d=this.chart.renderer.g().attr({zIndex:h||.1}).add(f));d.addClass("highcharts-"+b+" highcharts-series-"+this.index+" highcharts-"+this.type+"-series "+(J(this.colorIndex)?"highcharts-color-"+this.colorIndex+" ":"")+(this.options.className||"")+(d.hasClass("highcharts-tracker")?" highcharts-tracker":""),!0);d.attr({visibility:c})[g?"attr":
"animate"](this.getPlotBox());return d},getPlotBox:function(){var a=this.chart,b=this.xAxis,c=this.yAxis;a.inverted&&(b=c,c=this.xAxis);return{translateX:b?b.left:a.plotLeft,translateY:c?c.top:a.plotTop,scaleX:1,scaleY:1}},removeEvents:function(a){a?this.eventsToUnbind.length&&(this.eventsToUnbind.forEach(function(a){a()}),this.eventsToUnbind.length=0):p(this)},render:function(){var a=this,b=a.chart,c=a.options,h=!a.finishedAnimating&&b.renderer.isSVG&&H(c.animation).duration,f=a.visible?"inherit":
"hidden",g=c.zIndex,k=a.hasRendered,n=b.seriesGroup,p=b.inverted;m(this,"render");var e=a.plotGroup("group","series",f,g,n);a.markerGroup=a.plotGroup("markerGroup","markers",f,g,n);h&&a.animate&&a.animate(!0);e.inverted=a.isCartesian||a.invertable?p:!1;a.drawGraph&&(a.drawGraph(),a.applyZones());a.visible&&a.drawPoints();a.drawDataLabels&&a.drawDataLabels();a.redrawPoints&&a.redrawPoints();a.drawTracker&&!1!==a.options.enableMouseTracking&&a.drawTracker();a.invertGroups(p);!1===c.clip||a.sharedClipKey||
k||e.clip(b.clipRect);h&&a.animate&&a.animate();k||(a.animationTimeout=v(function(){a.afterAnimate()},h||0));a.isDirty=!1;a.hasRendered=!0;m(a,"afterRender")},redraw:function(){var a=this.chart,b=this.isDirty||this.isDirtyData,c=this.group,h=this.xAxis,f=this.yAxis;c&&(a.inverted&&c.attr({width:a.plotWidth,height:a.plotHeight}),c.animate({translateX:r(h&&h.left,a.plotLeft),translateY:r(f&&f.top,a.plotTop)}));this.translate();this.render();b&&delete this.kdTree},kdAxisArray:["clientX","plotY"],searchPoint:function(a,
b){var d=this.xAxis,c=this.yAxis,h=this.chart.inverted;return this.searchKDTree({clientX:h?d.len-a.chartY+d.pos:a.chartX-d.pos,plotY:h?c.len-a.chartX+c.pos:a.chartY-c.pos},b,a)},buildKDTree:function(a){function d(a,c,h){var f;if(f=a&&a.length){var g=b.kdAxisArray[c%h];a.sort(function(a,d){return a[g]-d[g]});f=Math.floor(f/2);return{point:a[f],left:d(a.slice(0,f),c+1,h),right:d(a.slice(f+1),c+1,h)}}}this.buildingKdTree=!0;var b=this,c=-1<b.options.findNearestPointBy.indexOf("y")?2:1;delete b.kdTree;
v(function(){b.kdTree=d(b.getValidPoints(null,!b.directTouch),c,c);b.buildingKdTree=!1},b.options.kdNow||a&&"touchstart"===a.type?0:1)},searchKDTree:function(a,b,c){function d(a,b,c,n){var p=b.point,e=h.kdAxisArray[c%n],v=p;var w=J(a[f])&&J(p[f])?Math.pow(a[f]-p[f],2):null;var r=J(a[g])&&J(p[g])?Math.pow(a[g]-p[g],2):null;r=(w||0)+(r||0);p.dist=J(r)?Math.sqrt(r):Number.MAX_VALUE;p.distX=J(w)?Math.sqrt(w):Number.MAX_VALUE;e=a[e]-p[e];r=0>e?"left":"right";w=0>e?"right":"left";b[r]&&(r=d(a,b[r],c+1,
n),v=r[k]<v[k]?r:p);b[w]&&Math.sqrt(e*e)<v[k]&&(a=d(a,b[w],c+1,n),v=a[k]<v[k]?a:v);return v}var h=this,f=this.kdAxisArray[0],g=this.kdAxisArray[1],k=b?"distX":"dist";b=-1<h.options.findNearestPointBy.indexOf("y")?2:1;this.kdTree||this.buildingKdTree||this.buildKDTree(c);if(this.kdTree)return d(a,this.kdTree,b,b)},pointPlacementToXValue:function(){var a=this.options,c=a.pointRange,h=this.xAxis;a=a.pointPlacement;"between"===a&&(a=h.reversed?-.5:.5);return b(a)?a*r(c,h.pointRange):0},isPointInside:function(a){return"undefined"!==
typeof a.plotY&&"undefined"!==typeof a.plotX&&0<=a.plotY&&a.plotY<=this.yAxis.len&&0<=a.plotX&&a.plotX<=this.xAxis.len}});""});P(x,"parts/Stacking.js",[x["parts/Axis.js"],x["parts/Globals.js"],x["parts/StackingAxis.js"],x["parts/Utilities.js"]],function(l,e,B,t){var x=t.correctFloat,H=t.defined,L=t.destroyObjectProperties,K=t.format,E=t.pick;"";t=e.Chart;var C=e.Series,J=function(){function e(e,l,q,m,u){var k=e.chart.inverted;this.axis=e;this.isNegative=q;this.options=l=l||{};this.x=m;this.total=
null;this.points={};this.stack=u;this.rightCliff=this.leftCliff=0;this.alignOptions={align:l.align||(k?q?"left":"right":"center"),verticalAlign:l.verticalAlign||(k?"middle":q?"bottom":"top"),y:l.y,x:l.x};this.textAlign=l.textAlign||(k?q?"right":"left":"center")}e.prototype.destroy=function(){L(this,this.axis)};e.prototype.render=function(e){var l=this.axis.chart,q=this.options,m=q.format;m=m?K(m,this,l):q.formatter.call(this);this.label?this.label.attr({text:m,visibility:"hidden"}):(this.label=l.renderer.label(m,
null,null,q.shape,null,null,q.useHTML,!1,"stack-labels"),m={r:q.borderRadius||0,text:m,rotation:q.rotation,padding:E(q.padding,5),visibility:"hidden"},l.styledMode||(m.fill=q.backgroundColor,m.stroke=q.borderColor,m["stroke-width"]=q.borderWidth,this.label.css(q.style)),this.label.attr(m),this.label.added||this.label.add(e));this.label.labelrank=l.plotHeight};e.prototype.setOffset=function(e,l,q,m,u){var k=this.axis,g=k.chart;m=k.translate(k.stacking.usePercentage?100:m?m:this.total,0,0,0,1);q=k.translate(q?
q:0);q=H(m)&&Math.abs(m-q);e=E(u,g.xAxis[0].translate(this.x))+e;k=H(m)&&this.getStackBox(g,this,e,m,l,q,k);l=this.label;q=this.isNegative;e="justify"===E(this.options.overflow,"justify");var b=this.textAlign;l&&k&&(u=l.getBBox(),m=l.padding,b="left"===b?g.inverted?-m:m:"right"===b?u.width:g.inverted&&"center"===b?u.width/2:g.inverted?q?u.width+m:-m:u.width/2,q=g.inverted?u.height/2:q?-m:u.height,this.alignOptions.x=E(this.options.x,0),this.alignOptions.y=E(this.options.y,0),k.x-=b,k.y-=q,l.align(this.alignOptions,
null,k),g.isInsidePlot(l.alignAttr.x+b-this.alignOptions.x,l.alignAttr.y+q-this.alignOptions.y)?l.show():(l.alignAttr.y=-9999,e=!1),e&&C.prototype.justifyDataLabel.call(this.axis,l,this.alignOptions,l.alignAttr,u,k),l.attr({x:l.alignAttr.x,y:l.alignAttr.y}),E(!e&&this.options.crop,!0)&&((g=g.isInsidePlot(l.x-m+l.width,l.y)&&g.isInsidePlot(l.x+m,l.y))||l.hide()))};e.prototype.getStackBox=function(e,l,q,m,u,k,g){var b=l.axis.reversed,f=e.inverted,a=g.height+g.pos-(f?e.plotLeft:e.plotTop);l=l.isNegative&&
!b||!l.isNegative&&b;return{x:f?l?m-g.right:m-k+g.pos-e.plotLeft:q+e.xAxis[0].transB-e.plotLeft,y:f?g.height-q-u:l?a-m-k:a-m,width:f?k:u,height:f?u:k}};return e}();t.prototype.getStacks=function(){var e=this,l=e.inverted;e.yAxis.forEach(function(e){e.stacking&&e.stacking.stacks&&e.hasVisibleSeries&&(e.stacking.oldStacks=e.stacking.stacks)});e.series.forEach(function(z){var q=z.xAxis&&z.xAxis.options||{};!z.options.stacking||!0!==z.visible&&!1!==e.options.chart.ignoreHiddenSeries||(z.stackKey=[z.type,
E(z.options.stack,""),l?q.top:q.left,l?q.height:q.width].join())})};B.compose(l);C.prototype.setStackedPoints=function(){if(this.options.stacking&&(!0===this.visible||!1===this.chart.options.chart.ignoreHiddenSeries)){var e=this.processedXData,l=this.processedYData,z=[],q=l.length,m=this.options,u=m.threshold,k=E(m.startFromThreshold&&u,0),g=m.stack;m=m.stacking;var b=this.stackKey,f="-"+b,a=this.negStacks,c=this.yAxis,r=c.stacking.stacks,p=c.stacking.oldStacks,I,w;c.stacking.stacksTouched+=1;for(w=
0;w<q;w++){var v=e[w];var n=l[w];var F=this.getStackIndicator(F,v,this.index);var O=F.key;var D=(I=a&&n<(k?0:u))?f:b;r[D]||(r[D]={});r[D][v]||(p[D]&&p[D][v]?(r[D][v]=p[D][v],r[D][v].total=null):r[D][v]=new J(c,c.options.stackLabels,I,v,g));D=r[D][v];null!==n?(D.points[O]=D.points[this.index]=[E(D.cumulative,k)],H(D.cumulative)||(D.base=O),D.touched=c.stacking.stacksTouched,0<F.index&&!1===this.singleStacks&&(D.points[O][0]=D.points[this.index+","+v+",0"][0])):D.points[O]=D.points[this.index]=null;
"percent"===m?(I=I?b:f,a&&r[I]&&r[I][v]?(I=r[I][v],D.total=I.total=Math.max(I.total,D.total)+Math.abs(n)||0):D.total=x(D.total+(Math.abs(n)||0))):D.total=x(D.total+(n||0));D.cumulative=E(D.cumulative,k)+(n||0);null!==n&&(D.points[O].push(D.cumulative),z[w]=D.cumulative)}"percent"===m&&(c.stacking.usePercentage=!0);this.stackedYData=z;c.stacking.oldStacks={}}};C.prototype.modifyStacks=function(){var e=this,l=e.stackKey,z=e.yAxis.stacking.stacks,q=e.processedXData,m,u=e.options.stacking;e[u+"Stacker"]&&
[l,"-"+l].forEach(function(k){for(var g=q.length,b,f;g--;)if(b=q[g],m=e.getStackIndicator(m,b,e.index,k),f=(b=z[k]&&z[k][b])&&b.points[m.key])e[u+"Stacker"](f,b,g)})};C.prototype.percentStacker=function(e,l,z){l=l.total?100/l.total:0;e[0]=x(e[0]*l);e[1]=x(e[1]*l);this.stackedYData[z]=e[1]};C.prototype.getStackIndicator=function(e,l,z,q){!H(e)||e.x!==l||q&&e.key!==q?e={x:l,index:0,key:q}:e.index++;e.key=[z,l,e.index].join();return e};e.StackItem=J;return e.StackItem});P(x,"parts/Dynamics.js",[x["parts/Globals.js"],
x["parts/Point.js"],x["parts/Time.js"],x["parts/Utilities.js"]],function(l,e,B,t){var x=t.addEvent,H=t.animate,L=t.createElement,K=t.css,E=t.defined,C=t.erase,J=t.error,y=t.extend,A=t.fireEvent,z=t.isArray,q=t.isNumber,m=t.isObject,u=t.isString,k=t.merge,g=t.objectEach,b=t.pick,f=t.relativeLength,a=t.setAnimation,c=t.splat,r=l.Axis;t=l.Chart;var p=l.Series,I=l.seriesTypes;l.cleanRecursively=function(a,b){var c={};g(a,function(f,g){if(m(a[g],!0)&&!a.nodeType&&b[g])f=l.cleanRecursively(a[g],b[g]),Object.keys(f).length&&
(c[g]=f);else if(m(a[g])||a[g]!==b[g])c[g]=a[g]});return c};y(t.prototype,{addSeries:function(a,c,f){var g,k=this;a&&(c=b(c,!0),A(k,"addSeries",{options:a},function(){g=k.initSeries(a);k.isDirtyLegend=!0;k.linkSeries();g.enabledDataSorting&&g.setData(a.data,!1);A(k,"afterAddSeries",{series:g});c&&k.redraw(f)}));return g},addAxis:function(a,b,c,f){return this.createAxis(b?"xAxis":"yAxis",{axis:a,redraw:c,animation:f})},addColorAxis:function(a,b,c){return this.createAxis("colorAxis",{axis:a,redraw:b,
animation:c})},createAxis:function(a,f){var g=this.options,p="colorAxis"===a,e=f.redraw,v=f.animation;f=k(f.axis,{index:this[a].length,isX:"xAxis"===a});var h=p?new l.ColorAxis(this,f):new r(this,f);g[a]=c(g[a]||{});g[a].push(f);p&&(this.isDirtyLegend=!0,this.axes.forEach(function(a){a.series=[]}),this.series.forEach(function(a){a.bindAxes();a.isDirtyData=!0}));b(e,!0)&&this.redraw(v);return h},showLoading:function(a){var c=this,f=c.options,g=c.loadingDiv,k=f.loading,p=function(){g&&K(g,{left:c.plotLeft+
"px",top:c.plotTop+"px",width:c.plotWidth+"px",height:c.plotHeight+"px"})};g||(c.loadingDiv=g=L("div",{className:"highcharts-loading highcharts-loading-hidden"},null,c.container),c.loadingSpan=L("span",{className:"highcharts-loading-inner"},null,g),x(c,"redraw",p));g.className="highcharts-loading";c.loadingSpan.innerHTML=b(a,f.lang.loading,"");c.styledMode||(K(g,y(k.style,{zIndex:10})),K(c.loadingSpan,k.labelStyle),c.loadingShown||(K(g,{opacity:0,display:""}),H(g,{opacity:k.style.opacity||.5},{duration:k.showDuration||
0})));c.loadingShown=!0;p()},hideLoading:function(){var a=this.options,b=this.loadingDiv;b&&(b.className="highcharts-loading highcharts-loading-hidden",this.styledMode||H(b,{opacity:0},{duration:a.loading.hideDuration||100,complete:function(){K(b,{display:"none"})}}));this.loadingShown=!1},propsRequireDirtyBox:"backgroundColor borderColor borderWidth borderRadius plotBackgroundColor plotBackgroundImage plotBorderColor plotBorderWidth plotShadow shadow".split(" "),propsRequireReflow:"margin marginTop marginRight marginBottom marginLeft spacing spacingTop spacingRight spacingBottom spacingLeft".split(" "),
propsRequireUpdateSeries:"chart.inverted chart.polar chart.ignoreHiddenSeries chart.type colors plotOptions time tooltip".split(" "),collectionsWithUpdate:["xAxis","yAxis","zAxis","series"],update:function(a,p,n,e){var r=this,v={credits:"addCredits",title:"setTitle",subtitle:"setSubtitle",caption:"setCaption"},h,d,w,m=a.isResponsiveOptions,F=[];A(r,"update",{options:a});m||r.setResponsive(!1,!0);a=l.cleanRecursively(a,r.options);k(!0,r.userOptions,a);if(h=a.chart){k(!0,r.options.chart,h);"className"in
h&&r.setClassName(h.className);"reflow"in h&&r.setReflow(h.reflow);if("inverted"in h||"polar"in h||"type"in h){r.propFromSeries();var I=!0}"alignTicks"in h&&(I=!0);g(h,function(a,b){-1!==r.propsRequireUpdateSeries.indexOf("chart."+b)&&(d=!0);-1!==r.propsRequireDirtyBox.indexOf(b)&&(r.isDirtyBox=!0);m||-1===r.propsRequireReflow.indexOf(b)||(w=!0)});!r.styledMode&&"style"in h&&r.renderer.setStyle(h.style)}!r.styledMode&&a.colors&&(this.options.colors=a.colors);a.plotOptions&&k(!0,this.options.plotOptions,
a.plotOptions);a.time&&this.time===l.time&&(this.time=new B(a.time));g(a,function(a,b){if(r[b]&&"function"===typeof r[b].update)r[b].update(a,!1);else if("function"===typeof r[v[b]])r[v[b]](a);"chart"!==b&&-1!==r.propsRequireUpdateSeries.indexOf(b)&&(d=!0)});this.collectionsWithUpdate.forEach(function(d){if(a[d]){if("series"===d){var h=[];r[d].forEach(function(a,d){a.options.isInternal||h.push(b(a.options.index,d))})}c(a[d]).forEach(function(a,b){(b=E(a.id)&&r.get(a.id)||r[d][h?h[b]:b])&&b.coll===
d&&(b.update(a,!1),n&&(b.touched=!0));!b&&n&&r.collectionsWithInit[d]&&(r.collectionsWithInit[d][0].apply(r,[a].concat(r.collectionsWithInit[d][1]||[]).concat([!1])).touched=!0)});n&&r[d].forEach(function(a){a.touched||a.options.isInternal?delete a.touched:F.push(a)})}});F.forEach(function(a){a.remove&&a.remove(!1)});I&&r.axes.forEach(function(a){a.update({},!1)});d&&r.getSeriesOrderByLinks().forEach(function(a){a.chart&&a.update({},!1)},this);a.loading&&k(!0,r.options.loading,a.loading);I=h&&h.width;
h=h&&h.height;u(h)&&(h=f(h,I||r.chartWidth));w||q(I)&&I!==r.chartWidth||q(h)&&h!==r.chartHeight?r.setSize(I,h,e):b(p,!0)&&r.redraw(e);A(r,"afterUpdate",{options:a,redraw:p,animation:e})},setSubtitle:function(a,b){this.applyDescription("subtitle",a);this.layOutTitles(b)},setCaption:function(a,b){this.applyDescription("caption",a);this.layOutTitles(b)}});t.prototype.collectionsWithInit={xAxis:[t.prototype.addAxis,[!0]],yAxis:[t.prototype.addAxis,[!1]],series:[t.prototype.addSeries]};y(e.prototype,{update:function(a,
c,f,g){function k(){n.applyOptions(a);var g=d&&n.hasDummyGraphic;g=null===n.y?!g:g;d&&g&&(n.graphic=d.destroy(),delete n.hasDummyGraphic);m(a,!0)&&(d&&d.element&&a&&a.marker&&"undefined"!==typeof a.marker.symbol&&(n.graphic=d.destroy()),a&&a.dataLabels&&n.dataLabel&&(n.dataLabel=n.dataLabel.destroy()),n.connector&&(n.connector=n.connector.destroy()));p=n.index;h.updateParallelArrays(n,p);r.data[p]=m(r.data[p],!0)||m(a,!0)?n.options:b(a,r.data[p]);h.isDirty=h.isDirtyData=!0;!h.fixedBox&&h.hasCartesianSeries&&
(e.isDirtyBox=!0);"point"===r.legendType&&(e.isDirtyLegend=!0);c&&e.redraw(f)}var n=this,h=n.series,d=n.graphic,p,e=h.chart,r=h.options;c=b(c,!0);!1===g?k():n.firePointEvent("update",{options:a},k)},remove:function(a,b){this.series.removePoint(this.series.data.indexOf(this),a,b)}});y(p.prototype,{addPoint:function(a,c,f,g,k){var n=this.options,h=this.data,d=this.chart,p=this.xAxis;p=p&&p.hasNames&&p.names;var e=n.data,r=this.xData,v;c=b(c,!0);var w={series:this};this.pointClass.prototype.applyOptions.apply(w,
[a]);var m=w.x;var F=r.length;if(this.requireSorting&&m<r[F-1])for(v=!0;F&&r[F-1]>m;)F--;this.updateParallelArrays(w,"splice",F,0,0);this.updateParallelArrays(w,F);p&&w.name&&(p[m]=w.name);e.splice(F,0,a);v&&(this.data.splice(F,0,null),this.processData());"point"===n.legendType&&this.generatePoints();f&&(h[0]&&h[0].remove?h[0].remove(!1):(h.shift(),this.updateParallelArrays(w,"shift"),e.shift()));!1!==k&&A(this,"addPoint",{point:w});this.isDirtyData=this.isDirty=!0;c&&d.redraw(g)},removePoint:function(c,
f,g){var k=this,n=k.data,p=n[c],h=k.points,d=k.chart,e=function(){h&&h.length===n.length&&h.splice(c,1);n.splice(c,1);k.options.data.splice(c,1);k.updateParallelArrays(p||{series:k},"splice",c,1);p&&p.destroy();k.isDirty=!0;k.isDirtyData=!0;f&&d.redraw()};a(g,d);f=b(f,!0);p?p.firePointEvent("remove",null,e):e()},remove:function(a,c,f,g){function k(){n.destroy(g);n.remove=null;h.isDirtyLegend=h.isDirtyBox=!0;h.linkSeries();b(a,!0)&&h.redraw(c)}var n=this,h=n.chart;!1!==f?A(n,"remove",null,k):k()},
update:function(a,c){a=l.cleanRecursively(a,this.userOptions);A(this,"update",{options:a});var f=this,g=f.chart,p=f.userOptions,e=f.initialType||f.type,h=a.type||p.type||g.options.chart.type,d=!(this.hasDerivedData||a.dataGrouping||h&&h!==this.type||"undefined"!==typeof a.pointStart||a.pointInterval||a.pointIntervalUnit||a.keys),r=I[e].prototype,v,w=["group","markerGroup","dataLabelsGroup","transformGroup"],m=["eventOptions","navigatorSeries","baseSeries"],q=f.finishedAnimating&&{animation:!1},u=
{};d&&(m.push("data","isDirtyData","points","processedXData","processedYData","xIncrement","_hasPointMarkers","_hasPointLabels","mapMap","mapData","minY","maxY","minX","maxX"),!1!==a.visible&&m.push("area","graph"),f.parallelArrays.forEach(function(a){m.push(a+"Data")}),a.data&&(a.dataSorting&&y(f.options.dataSorting,a.dataSorting),this.setData(a.data,!1)));a=k(p,q,{index:"undefined"===typeof p.index?f.index:p.index,pointStart:b(p.pointStart,f.xData[0])},!d&&{data:f.options.data},a);d&&a.data&&(a.data=
f.options.data);m=w.concat(m);m.forEach(function(a){m[a]=f[a];delete f[a]});f.remove(!1,null,!1,!0);for(v in r)f[v]=void 0;I[h||e]?y(f,I[h||e].prototype):J(17,!0,g,{missingModuleFor:h||e});m.forEach(function(a){f[a]=m[a]});f.init(g,a);if(d&&this.points){var z=f.options;!1===z.visible?(u.graphic=1,u.dataLabel=1):f._hasPointLabels||(h=z.marker,r=z.dataLabels,h&&(!1===h.enabled||"symbol"in h)&&(u.graphic=1),r&&!1===r.enabled&&(u.dataLabel=1));this.points.forEach(function(a){a&&a.series&&(a.resolveColor(),
Object.keys(u).length&&a.destroyElements(u),!1===z.showInLegend&&a.legendItem&&g.legend.destroyItem(a))},this)}a.zIndex!==p.zIndex&&w.forEach(function(d){f[d]&&f[d].attr({zIndex:a.zIndex})});f.initialType=e;g.linkSeries();A(this,"afterUpdate");b(c,!0)&&g.redraw(d?void 0:!1)},setName:function(a){this.name=this.options.name=this.userOptions.name=a;this.chart.isDirtyLegend=!0}});y(r.prototype,{update:function(a,c){var f=this.chart,p=a&&a.events||{};a=k(this.userOptions,a);f.options[this.coll].indexOf&&
(f.options[this.coll][f.options[this.coll].indexOf(this.userOptions)]=a);g(f.options[this.coll].events,function(a,b){"undefined"===typeof p[b]&&(p[b]=void 0)});this.destroy(!0);this.init(f,y(a,{events:p}));f.isDirtyBox=!0;b(c,!0)&&f.redraw()},remove:function(a){for(var c=this.chart,f=this.coll,g=this.series,k=g.length;k--;)g[k]&&g[k].remove(!1);C(c.axes,this);C(c[f],this);z(c.options[f])?c.options[f].splice(this.options.index,1):delete c.options[f];c[f].forEach(function(a,b){a.options.index=a.userOptions.index=
b});this.destroy();c.isDirtyBox=!0;b(a,!0)&&c.redraw()},setTitle:function(a,b){this.update({title:a},b)},setCategories:function(a,b){this.update({categories:a},b)}})});P(x,"parts/AreaSeries.js",[x["parts/Globals.js"],x["parts/Color.js"],x["mixins/legend-symbol.js"],x["parts/Utilities.js"]],function(l,e,B,t){var x=e.parse,H=t.objectEach,L=t.pick;e=t.seriesType;var K=l.Series;e("area","line",{softThreshold:!1,threshold:0},{singleStacks:!1,getStackPoints:function(e){var l=[],t=[],y=this.xAxis,A=this.yAxis,
z=A.stacking.stacks[this.stackKey],q={},m=this.index,u=A.series,k=u.length,g=L(A.options.reversedStacks,!0)?1:-1,b;e=e||this.points;if(this.options.stacking){for(b=0;b<e.length;b++)e[b].leftNull=e[b].rightNull=void 0,q[e[b].x]=e[b];H(z,function(a,b){null!==a.total&&t.push(b)});t.sort(function(a,b){return a-b});var f=u.map(function(a){return a.visible});t.forEach(function(a,c){var e=0,p,u;if(q[a]&&!q[a].isNull)l.push(q[a]),[-1,1].forEach(function(e){var r=1===e?"rightNull":"leftNull",n=0,w=z[t[c+e]];
if(w)for(b=m;0<=b&&b<k;)p=w.points[b],p||(b===m?q[a][r]=!0:f[b]&&(u=z[a].points[b])&&(n-=u[1]-u[0])),b+=g;q[a][1===e?"rightCliff":"leftCliff"]=n});else{for(b=m;0<=b&&b<k;){if(p=z[a].points[b]){e=p[1];break}b+=g}e=A.translate(e,0,1,0,1);l.push({isNull:!0,plotX:y.translate(a,0,0,0,1),x:a,plotY:e,yBottom:e})}})}return l},getGraphPath:function(e){var l=K.prototype.getGraphPath,t=this.options,y=t.stacking,A=this.yAxis,z,q=[],m=[],u=this.index,k=A.stacking.stacks[this.stackKey],g=t.threshold,b=Math.round(A.getThreshold(t.threshold));
t=L(t.connectNulls,"percent"===y);var f=function(a,f,r){var p=e[a];a=y&&k[p.x].points[u];var n=p[r+"Null"]||0;r=p[r+"Cliff"]||0;p=!0;if(r||n){var w=(n?a[0]:a[1])+r;var l=a[0]+r;p=!!n}else!y&&e[f]&&e[f].isNull&&(w=l=g);"undefined"!==typeof w&&(m.push({plotX:c,plotY:null===w?b:A.getThreshold(w),isNull:p,isCliff:!0}),q.push({plotX:c,plotY:null===l?b:A.getThreshold(l),doCurve:!1}))};e=e||this.points;y&&(e=this.getStackPoints(e));for(z=0;z<e.length;z++){y||(e[z].leftCliff=e[z].rightCliff=e[z].leftNull=
e[z].rightNull=void 0);var a=e[z].isNull;var c=L(e[z].rectPlotX,e[z].plotX);var r=L(e[z].yBottom,b);if(!a||t)t||f(z,z-1,"left"),a&&!y&&t||(m.push(e[z]),q.push({x:z,plotX:c,plotY:r})),t||f(z,z+1,"right")}z=l.call(this,m,!0,!0);q.reversed=!0;a=l.call(this,q,!0,!0);(r=a[0])&&"M"===r[0]&&(a[0]=["L",r[1],r[2]]);a=z.concat(a);l=l.call(this,m,!1,t);a.xMap=z.xMap;this.areaPath=a;return l},drawGraph:function(){this.areaPath=[];K.prototype.drawGraph.apply(this);var e=this,l=this.areaPath,t=this.options,y=[["area",
"highcharts-area",this.color,t.fillColor]];this.zones.forEach(function(l,z){y.push(["zone-area-"+z,"highcharts-area highcharts-zone-area-"+z+" "+l.className,l.color||e.color,l.fillColor||t.fillColor])});y.forEach(function(y){var z=y[0],q=e[z],m=q?"animate":"attr",u={};q?(q.endX=e.preventGraphAnimation?null:l.xMap,q.animate({d:l})):(u.zIndex=0,q=e[z]=e.chart.renderer.path(l).addClass(y[1]).add(e.group),q.isArea=!0);e.chart.styledMode||(u.fill=L(y[3],x(y[2]).setOpacity(L(t.fillOpacity,.75)).get()));
q[m](u);q.startX=l.xMap;q.shiftUnit=t.step?2:1})},drawLegendSymbol:B.drawRectangle});""});P(x,"parts/SplineSeries.js",[x["parts/Utilities.js"]],function(l){var e=l.pick;l=l.seriesType;l("spline","line",{},{getPointSpline:function(l,t,x){var B=t.plotX||0,L=t.plotY||0,K=l[x-1];x=l[x+1];if(K&&!K.isNull&&!1!==K.doCurve&&!t.isCliff&&x&&!x.isNull&&!1!==x.doCurve&&!t.isCliff){l=K.plotY||0;var E=x.plotX||0;x=x.plotY||0;var C=0;var J=(1.5*B+(K.plotX||0))/2.5;var y=(1.5*L+l)/2.5;E=(1.5*B+E)/2.5;var A=(1.5*
L+x)/2.5;E!==J&&(C=(A-y)*(E-B)/(E-J)+L-A);y+=C;A+=C;y>l&&y>L?(y=Math.max(l,L),A=2*L-y):y<l&&y<L&&(y=Math.min(l,L),A=2*L-y);A>x&&A>L?(A=Math.max(x,L),y=2*L-A):A<x&&A<L&&(A=Math.min(x,L),y=2*L-A);t.rightContX=E;t.rightContY=A}t=["C",e(K.rightContX,K.plotX,0),e(K.rightContY,K.plotY,0),e(J,B,0),e(y,L,0),B,L];K.rightContX=K.rightContY=void 0;return t}});""});P(x,"parts/AreaSplineSeries.js",[x["parts/Globals.js"],x["mixins/legend-symbol.js"],x["parts/Utilities.js"]],function(l,e,B){B=B.seriesType;var t=
l.seriesTypes.area.prototype;B("areaspline","spline",l.defaultPlotOptions.area,{getStackPoints:t.getStackPoints,getGraphPath:t.getGraphPath,drawGraph:t.drawGraph,drawLegendSymbol:e.drawRectangle});""});P(x,"parts/ColumnSeries.js",[x["parts/Globals.js"],x["parts/Color.js"],x["mixins/legend-symbol.js"],x["parts/Utilities.js"]],function(l,e,B,t){"";var x=e.parse,H=t.animObject,L=t.clamp,K=t.defined,E=t.extend,C=t.isNumber,J=t.merge,y=t.pick;e=t.seriesType;var A=l.Series;e("column","line",{borderRadius:0,
groupPadding:.2,marker:null,pointPadding:.1,minPointLength:0,cropThreshold:50,pointRange:null,states:{hover:{halo:!1,brightness:.1},select:{color:"#cccccc",borderColor:"#000000"}},dataLabels:{align:null,verticalAlign:null,y:null},softThreshold:!1,startFromThreshold:!0,stickyTracking:!1,tooltip:{distance:6},threshold:0,borderColor:"#ffffff"},{cropShoulder:0,directTouch:!0,trackerGroups:["group","dataLabelsGroup"],negStacks:!0,init:function(){A.prototype.init.apply(this,arguments);var e=this,l=e.chart;
l.hasRendered&&l.series.forEach(function(m){m.type===e.type&&(m.isDirty=!0)})},getColumnMetrics:function(){var e=this,l=e.options,m=e.xAxis,u=e.yAxis,k=m.options.reversedStacks;k=m.reversed&&!k||!m.reversed&&k;var g,b={},f=0;!1===l.grouping?f=1:e.chart.series.forEach(function(a){var c=a.yAxis,k=a.options;if(a.type===e.type&&(a.visible||!e.chart.options.chart.ignoreHiddenSeries)&&u.len===c.len&&u.pos===c.pos){if(k.stacking){g=a.stackKey;"undefined"===typeof b[g]&&(b[g]=f++);var p=b[g]}else!1!==k.grouping&&
(p=f++);a.columnIndex=p}});var a=Math.min(Math.abs(m.transA)*(m.ordinal&&m.ordinal.slope||l.pointRange||m.closestPointRange||m.tickInterval||1),m.len),c=a*l.groupPadding,r=(a-2*c)/(f||1);l=Math.min(l.maxPointWidth||m.len,y(l.pointWidth,r*(1-2*l.pointPadding)));e.columnMetrics={width:l,offset:(r-l)/2+(c+((e.columnIndex||0)+(k?1:0))*r-a/2)*(k?-1:1)};return e.columnMetrics},crispCol:function(e,l,m,u){var k=this.chart,g=this.borderWidth,b=-(g%2?.5:0);g=g%2?.5:1;k.inverted&&k.renderer.isVML&&(g+=1);this.options.crisp&&
(m=Math.round(e+m)+b,e=Math.round(e)+b,m-=e);u=Math.round(l+u)+g;b=.5>=Math.abs(l)&&.5<u;l=Math.round(l)+g;u-=l;b&&u&&(--l,u+=1);return{x:e,y:l,width:m,height:u}},translate:function(){var e=this,l=e.chart,m=e.options,u=e.dense=2>e.closestPointRange*e.xAxis.transA;u=e.borderWidth=y(m.borderWidth,u?0:1);var k=e.xAxis,g=e.yAxis,b=m.threshold,f=e.translatedThreshold=g.getThreshold(b),a=y(m.minPointLength,5),c=e.getColumnMetrics(),r=c.width,p=e.barW=Math.max(r,1+2*u),I=e.pointXOffset=c.offset,w=e.dataMin,
v=e.dataMax;l.inverted&&(f-=.5);m.pointPadding&&(p=Math.ceil(p));A.prototype.translate.apply(e);e.points.forEach(function(c){var n=y(c.yBottom,f),m=999+Math.abs(n),q=r,h=c.plotX;m=L(c.plotY,-m,g.len+m);var d=c.plotX+I,u=p,z=Math.min(m,n),t=Math.max(m,n)-z;if(a&&Math.abs(t)<a){t=a;var A=!g.reversed&&!c.negative||g.reversed&&c.negative;C(b)&&C(v)&&c.y===b&&v<=b&&(g.min||0)<b&&w!==v&&(A=!A);z=Math.abs(z-f)>a?n-a:f-(A?a:0)}K(c.options.pointWidth)&&(q=u=Math.ceil(c.options.pointWidth),d-=Math.round((q-
r)/2));c.barX=d;c.pointWidth=q;c.tooltipPos=l.inverted?[g.len+g.pos-l.plotLeft-m,k.len+k.pos-l.plotTop-(h||0)-I-u/2,t]:[d+u/2,m+g.pos-l.plotTop,t];c.shapeType=e.pointClass.prototype.shapeType||"rect";c.shapeArgs=e.crispCol.apply(e,c.isNull?[d,f,u,0]:[d,z,u,t])})},getSymbol:l.noop,drawLegendSymbol:B.drawRectangle,drawGraph:function(){this.group[this.dense?"addClass":"removeClass"]("highcharts-dense-data")},pointAttribs:function(e,l){var m=this.options,q=this.pointAttrToOptions||{};var k=q.stroke||
"borderColor";var g=q["stroke-width"]||"borderWidth",b=e&&e.color||this.color,f=e&&e[k]||m[k]||this.color||b,a=e&&e[g]||m[g]||this[g]||0;q=e&&e.options.dashStyle||m.dashStyle;var c=y(e&&e.opacity,m.opacity,1);if(e&&this.zones.length){var r=e.getZone();b=e.options.color||r&&(r.color||e.nonZonedColor)||this.color;r&&(f=r.borderColor||f,q=r.dashStyle||q,a=r.borderWidth||a)}l&&e&&(e=J(m.states[l],e.options.states&&e.options.states[l]||{}),l=e.brightness,b=e.color||"undefined"!==typeof l&&x(b).brighten(e.brightness).get()||
b,f=e[k]||f,a=e[g]||a,q=e.dashStyle||q,c=y(e.opacity,c));k={fill:b,stroke:f,"stroke-width":a,opacity:c};q&&(k.dashstyle=q);return k},drawPoints:function(){var e=this,l=this.chart,m=e.options,u=l.renderer,k=m.animationLimit||250,g;e.points.forEach(function(b){var f=b.graphic,a=!!f,c=f&&l.pointCount<k?"animate":"attr";if(C(b.plotY)&&null!==b.y){g=b.shapeArgs;f&&b.hasNewShapeType()&&(f=f.destroy());e.enabledDataSorting&&(b.startXPos=e.xAxis.reversed?-(g?g.width:0):e.xAxis.width);f||(b.graphic=f=u[b.shapeType](g).add(b.group||
e.group))&&e.enabledDataSorting&&l.hasRendered&&l.pointCount<k&&(f.attr({x:b.startXPos}),a=!0,c="animate");if(f&&a)f[c](J(g));if(m.borderRadius)f[c]({r:m.borderRadius});l.styledMode||f[c](e.pointAttribs(b,b.selected&&"select")).shadow(!1!==b.allowShadow&&m.shadow,null,m.stacking&&!m.borderRadius);f.addClass(b.getClassName(),!0)}else f&&(b.graphic=f.destroy())})},animate:function(e){var l=this,m=this.yAxis,u=l.options,k=this.chart.inverted,g={},b=k?"translateX":"translateY";if(e)g.scaleY=.001,e=L(m.toPixels(u.threshold),
m.pos,m.pos+m.len),k?g.translateX=e-m.len:g.translateY=e,l.clipBox&&l.setClip(),l.group.attr(g);else{var f=l.group.attr(b);l.group.animate({scaleY:1},E(H(l.options.animation),{step:function(a,c){l.group&&(g[b]=f+c.pos*(m.pos-f),l.group.attr(g))}}))}},remove:function(){var e=this,l=e.chart;l.hasRendered&&l.series.forEach(function(l){l.type===e.type&&(l.isDirty=!0)});A.prototype.remove.apply(e,arguments)}});""});P(x,"parts/BarSeries.js",[x["parts/Utilities.js"]],function(l){l=l.seriesType;l("bar","column",
null,{inverted:!0});""});P(x,"parts/ScatterSeries.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent;e=e.seriesType;var t=l.Series;e("scatter","line",{lineWidth:0,findNearestPointBy:"xy",jitter:{x:0,y:0},marker:{enabled:!0},tooltip:{headerFormat:'<span style="color:{point.color}">\u25cf</span> <span style="font-size: 10px"> {series.name}</span><br/>',pointFormat:"x: <b>{point.x}</b><br/>y: <b>{point.y}</b><br/>"}},{sorted:!1,requireSorting:!1,noSharedTooltip:!0,trackerGroups:["group",
"markerGroup","dataLabelsGroup"],takeOrdinalPosition:!1,drawGraph:function(){this.options.lineWidth&&t.prototype.drawGraph.call(this)},applyJitter:function(){var e=this,l=this.options.jitter,t=this.points.length;l&&this.points.forEach(function(B,E){["x","y"].forEach(function(C,J){var y="plot"+C.toUpperCase();if(l[C]&&!B.isNull){var A=e[C+"Axis"];var z=l[C]*A.transA;if(A&&!A.isLog){var q=Math.max(0,B[y]-z);A=Math.min(A.len,B[y]+z);J=1E4*Math.sin(E+J*t);B[y]=q+(A-q)*(J-Math.floor(J));"x"===C&&(B.clientX=
B.plotX)}}})})}});B(t,"afterTranslate",function(){this.applyJitter&&this.applyJitter()});""});P(x,"mixins/centered-series.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.isNumber,t=e.pick,x=e.relativeLength,H=l.deg2rad;l.CenteredSeriesMixin={getCenter:function(){var e=this.options,l=this.chart,E=2*(e.slicedOffset||0),C=l.plotWidth-2*E,J=l.plotHeight-2*E,y=e.center,A=Math.min(C,J),z=e.size,q=e.innerSize||0;"string"===typeof z&&(z=parseFloat(z));"string"===typeof q&&(q=parseFloat(q));
e=[t(y[0],"50%"),t(y[1],"50%"),t(z&&0>z?void 0:e.size,"100%"),t(q&&0>q?void 0:e.innerSize||0,"0%")];l.angular&&(e[3]=0);for(y=0;4>y;++y)z=e[y],l=2>y||2===y&&/%$/.test(z),e[y]=x(z,[C,J,A,e[2]][y])+(l?E:0);e[3]>e[2]&&(e[3]=e[2]);return e},getStartAndEndRadians:function(e,l){e=B(e)?e:0;l=B(l)&&l>e&&360>l-e?l:e+360;return{start:H*(e+-90),end:H*(l+-90)}}}});P(x,"parts/PieSeries.js",[x["parts/Globals.js"],x["mixins/legend-symbol.js"],x["parts/Point.js"],x["parts/Utilities.js"]],function(l,e,B,t){var x=
t.addEvent,H=t.clamp,L=t.defined,K=t.fireEvent,E=t.isNumber,C=t.merge,J=t.pick,y=t.relativeLength,A=t.seriesType,z=t.setAnimation;t=l.CenteredSeriesMixin;var q=t.getStartAndEndRadians,m=l.noop,u=l.Series;A("pie","line",{center:[null,null],clip:!1,colorByPoint:!0,dataLabels:{allowOverlap:!0,connectorPadding:5,connectorShape:"fixedOffset",crookDistance:"70%",distance:30,enabled:!0,formatter:function(){return this.point.isNull?void 0:this.point.name},softConnector:!0,x:0},fillColor:void 0,ignoreHiddenPoint:!0,
inactiveOtherPoints:!0,legendType:"point",marker:null,size:null,showInLegend:!1,slicedOffset:10,stickyTracking:!1,tooltip:{followPointer:!0},borderColor:"#ffffff",borderWidth:1,lineWidth:void 0,states:{hover:{brightness:.1}}},{isCartesian:!1,requireSorting:!1,directTouch:!0,noSharedTooltip:!0,trackerGroups:["group","dataLabelsGroup"],axisTypes:[],pointAttribs:l.seriesTypes.column.prototype.pointAttribs,animate:function(k){var g=this,b=g.points,f=g.startAngleRad;k||b.forEach(function(a){var b=a.graphic,
k=a.shapeArgs;b&&k&&(b.attr({r:J(a.startR,g.center&&g.center[3]/2),start:f,end:f}),b.animate({r:k.r,start:k.start,end:k.end},g.options.animation))})},hasData:function(){return!!this.processedXData.length},updateTotals:function(){var k,g=0,b=this.points,f=b.length,a=this.options.ignoreHiddenPoint;for(k=0;k<f;k++){var c=b[k];g+=a&&!c.visible?0:c.isNull?0:c.y}this.total=g;for(k=0;k<f;k++)c=b[k],c.percentage=0<g&&(c.visible||!a)?c.y/g*100:0,c.total=g},generatePoints:function(){u.prototype.generatePoints.call(this);
this.updateTotals()},getX:function(k,g,b){var f=this.center,a=this.radii?this.radii[b.index]:f[2]/2;k=Math.asin(H((k-f[1])/(a+b.labelDistance),-1,1));return f[0]+(g?-1:1)*Math.cos(k)*(a+b.labelDistance)+(0<b.labelDistance?(g?-1:1)*this.options.dataLabels.padding:0)},translate:function(k){this.generatePoints();var g=0,b=this.options,f=b.slicedOffset,a=f+(b.borderWidth||0),c=q(b.startAngle,b.endAngle),e=this.startAngleRad=c.start;c=(this.endAngleRad=c.end)-e;var p=this.points,l=b.dataLabels.distance;
b=b.ignoreHiddenPoint;var m,v=p.length;k||(this.center=k=this.getCenter());for(m=0;m<v;m++){var n=p[m];var F=e+g*c;if(!b||n.visible)g+=n.percentage/100;var u=e+g*c;n.shapeType="arc";n.shapeArgs={x:k[0],y:k[1],r:k[2]/2,innerR:k[3]/2,start:Math.round(1E3*F)/1E3,end:Math.round(1E3*u)/1E3};n.labelDistance=J(n.options.dataLabels&&n.options.dataLabels.distance,l);n.labelDistance=y(n.labelDistance,n.shapeArgs.r);this.maxLabelDistance=Math.max(this.maxLabelDistance||0,n.labelDistance);u=(u+F)/2;u>1.5*Math.PI?
u-=2*Math.PI:u<-Math.PI/2&&(u+=2*Math.PI);n.slicedTranslation={translateX:Math.round(Math.cos(u)*f),translateY:Math.round(Math.sin(u)*f)};var D=Math.cos(u)*k[2]/2;var h=Math.sin(u)*k[2]/2;n.tooltipPos=[k[0]+.7*D,k[1]+.7*h];n.half=u<-Math.PI/2||u>Math.PI/2?1:0;n.angle=u;F=Math.min(a,n.labelDistance/5);n.labelPosition={natural:{x:k[0]+D+Math.cos(u)*n.labelDistance,y:k[1]+h+Math.sin(u)*n.labelDistance},"final":{},alignment:0>n.labelDistance?"center":n.half?"right":"left",connectorPosition:{breakAt:{x:k[0]+
D+Math.cos(u)*F,y:k[1]+h+Math.sin(u)*F},touchingSliceAt:{x:k[0]+D,y:k[1]+h}}}}K(this,"afterTranslate")},drawEmpty:function(){var k=this.options;if(0===this.total){var g=this.center[0];var b=this.center[1];this.graph||(this.graph=this.chart.renderer.circle(g,b,0).addClass("highcharts-graph").add(this.group));this.graph.animate({"stroke-width":k.borderWidth,cx:g,cy:b,r:this.center[2]/2,fill:k.fillColor||"none",stroke:k.color||"#cccccc"},this.options.animation)}else this.graph&&(this.graph=this.graph.destroy())},
redrawPoints:function(){var k=this,g=k.chart,b=g.renderer,f,a,c,e,p=k.options.shadow;this.drawEmpty();!p||k.shadowGroup||g.styledMode||(k.shadowGroup=b.g("shadow").attr({zIndex:-1}).add(k.group));k.points.forEach(function(r){var l={};a=r.graphic;if(!r.isNull&&a){e=r.shapeArgs;f=r.getTranslate();if(!g.styledMode){var v=r.shadowGroup;p&&!v&&(v=r.shadowGroup=b.g("shadow").add(k.shadowGroup));v&&v.attr(f);c=k.pointAttribs(r,r.selected&&"select")}r.delayedRendering?(a.setRadialReference(k.center).attr(e).attr(f),
g.styledMode||a.attr(c).attr({"stroke-linejoin":"round"}).shadow(p,v),r.delayedRendering=!1):(a.setRadialReference(k.center),g.styledMode||C(!0,l,c),C(!0,l,e,f),a.animate(l));a.attr({visibility:r.visible?"inherit":"hidden"});a.addClass(r.getClassName())}else a&&(r.graphic=a.destroy())})},drawPoints:function(){var k=this.chart.renderer;this.points.forEach(function(g){g.graphic&&g.hasNewShapeType()&&(g.graphic=g.graphic.destroy());g.graphic||(g.graphic=k[g.shapeType](g.shapeArgs).add(g.series.group),
g.delayedRendering=!0)})},searchPoint:m,sortByAngle:function(k,g){k.sort(function(b,f){return"undefined"!==typeof b.angle&&(f.angle-b.angle)*g})},drawLegendSymbol:e.drawRectangle,getCenter:t.getCenter,getSymbol:m,drawGraph:null},{init:function(){B.prototype.init.apply(this,arguments);var k=this;k.name=J(k.name,"Slice");var g=function(b){k.slice("select"===b.type)};x(k,"select",g);x(k,"unselect",g);return k},isValid:function(){return E(this.y)&&0<=this.y},setVisible:function(k,g){var b=this,f=b.series,
a=f.chart,c=f.options.ignoreHiddenPoint;g=J(g,c);k!==b.visible&&(b.visible=b.options.visible=k="undefined"===typeof k?!b.visible:k,f.options.data[f.data.indexOf(b)]=b.options,["graphic","dataLabel","connector","shadowGroup"].forEach(function(a){if(b[a])b[a][k?"show":"hide"](!0)}),b.legendItem&&a.legend.colorizeItem(b,k),k||"hover"!==b.state||b.setState(""),c&&(f.isDirty=!0),g&&a.redraw())},slice:function(k,g,b){var f=this.series;z(b,f.chart);J(g,!0);this.sliced=this.options.sliced=L(k)?k:!this.sliced;
f.options.data[f.data.indexOf(this)]=this.options;this.graphic&&this.graphic.animate(this.getTranslate());this.shadowGroup&&this.shadowGroup.animate(this.getTranslate())},getTranslate:function(){return this.sliced?this.slicedTranslation:{translateX:0,translateY:0}},haloPath:function(k){var g=this.shapeArgs;return this.sliced||!this.visible?[]:this.series.chart.renderer.symbols.arc(g.x,g.y,g.r+k,g.r+k,{innerR:g.r-1,start:g.start,end:g.end})},connectorShapes:{fixedOffset:function(k,g,b){var f=g.breakAt;
g=g.touchingSliceAt;return[["M",k.x,k.y],b.softConnector?["C",k.x+("left"===k.alignment?-5:5),k.y,2*f.x-g.x,2*f.y-g.y,f.x,f.y]:["L",f.x,f.y],["L",g.x,g.y]]},straight:function(k,g){g=g.touchingSliceAt;return[["M",k.x,k.y],["L",g.x,g.y]]},crookedLine:function(k,g,b){g=g.touchingSliceAt;var f=this.series,a=f.center[0],c=f.chart.plotWidth,e=f.chart.plotLeft;f=k.alignment;var p=this.shapeArgs.r;b=y(b.crookDistance,1);c="left"===f?a+p+(c+e-a-p)*(1-b):e+(a-p)*b;b=["L",c,k.y];a=!0;if("left"===f?c>k.x||c<
g.x:c<k.x||c>g.x)a=!1;k=[["M",k.x,k.y]];a&&k.push(b);k.push(["L",g.x,g.y]);return k}},getConnectorPath:function(){var k=this.labelPosition,g=this.series.options.dataLabels,b=g.connectorShape,f=this.connectorShapes;f[b]&&(b=f[b]);return b.call(this,{x:k.final.x,y:k.final.y,alignment:k.alignment},k.connectorPosition,g)}});""});P(x,"parts/DataLabels.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.animObject,t=e.arrayMax,x=e.clamp,H=e.defined,L=e.extend,K=e.fireEvent,E=e.format,
C=e.isArray,J=e.merge,y=e.objectEach,A=e.pick,z=e.relativeLength,q=e.splat,m=e.stableSort;e=l.noop;var u=l.Series,k=l.seriesTypes;l.distribute=function(g,b,f){function a(a,b){return a.target-b.target}var c,k=!0,e=g,q=[];var w=0;var v=e.reducedLen||b;for(c=g.length;c--;)w+=g[c].size;if(w>v){m(g,function(a,b){return(b.rank||0)-(a.rank||0)});for(w=c=0;w<=v;)w+=g[c].size,c++;q=g.splice(c-1,g.length)}m(g,a);for(g=g.map(function(a){return{size:a.size,targets:[a.target],align:A(a.align,.5)}});k;){for(c=
g.length;c--;)k=g[c],w=(Math.min.apply(0,k.targets)+Math.max.apply(0,k.targets))/2,k.pos=x(w-k.size*k.align,0,b-k.size);c=g.length;for(k=!1;c--;)0<c&&g[c-1].pos+g[c-1].size>g[c].pos&&(g[c-1].size+=g[c].size,g[c-1].targets=g[c-1].targets.concat(g[c].targets),g[c-1].align=.5,g[c-1].pos+g[c-1].size>b&&(g[c-1].pos=b-g[c-1].size),g.splice(c,1),k=!0)}e.push.apply(e,q);c=0;g.some(function(a){var g=0;if(a.targets.some(function(){e[c].pos=a.pos+g;if("undefined"!==typeof f&&Math.abs(e[c].pos-e[c].target)>f)return e.slice(0,
c+1).forEach(function(a){delete a.pos}),e.reducedLen=(e.reducedLen||b)-.1*b,e.reducedLen>.1*b&&l.distribute(e,b,f),!0;g+=e[c].size;c++}))return!0});m(e,a)};u.prototype.drawDataLabels=function(){function g(a,d){var b=d.filter;return b?(d=b.operator,a=a[b.property],b=b.value,">"===d&&a>b||"<"===d&&a<b||">="===d&&a>=b||"<="===d&&a<=b||"=="===d&&a==b||"==="===d&&a===b?!0:!1):!0}function b(a,d){var b=[],c;if(C(a)&&!C(d))b=a.map(function(a){return J(a,d)});else if(C(d)&&!C(a))b=d.map(function(d){return J(a,
d)});else if(C(a)||C(d))for(c=Math.max(a.length,d.length);c--;)b[c]=J(a[c],d[c]);else b=J(a,d);return b}var f=this,a=f.chart,c=f.options,k=c.dataLabels,e=f.points,l,m=f.hasRendered||0,v=B(c.animation).duration,n=Math.min(v,200),F=!a.renderer.forExport&&A(k.defer,0<n),u=a.renderer;k=b(b(a.options.plotOptions&&a.options.plotOptions.series&&a.options.plotOptions.series.dataLabels,a.options.plotOptions&&a.options.plotOptions[f.type]&&a.options.plotOptions[f.type].dataLabels),k);K(this,"drawDataLabels");
if(C(k)||k.enabled||f._hasPointLabels){var D=f.plotGroup("dataLabelsGroup","data-labels",F&&!m?"hidden":"inherit",k.zIndex||6);F&&(D.attr({opacity:+m}),m||setTimeout(function(){var a=f.dataLabelsGroup;a&&(f.visible&&D.show(!0),a[c.animation?"animate":"attr"]({opacity:1},{duration:n}))},v-n));e.forEach(function(h){l=q(b(k,h.dlOptions||h.options&&h.options.dataLabels));l.forEach(function(d,b){var k=d.enabled&&(!h.isNull||h.dataLabelOnNull)&&g(h,d),e=h.dataLabels?h.dataLabels[b]:h.dataLabel,p=h.connectors?
h.connectors[b]:h.connector,n=A(d.distance,h.labelDistance),r=!e;if(k){var l=h.getLabelConfig();var m=A(d[h.formatPrefix+"Format"],d.format);l=H(m)?E(m,l,a):(d[h.formatPrefix+"Formatter"]||d.formatter).call(l,d);m=d.style;var v=d.rotation;a.styledMode||(m.color=A(d.color,m.color,f.color,"#000000"),"contrast"===m.color?(h.contrastColor=u.getContrast(h.color||f.color),m.color=!H(n)&&d.inside||0>n||c.stacking?h.contrastColor:"#000000"):delete h.contrastColor,c.cursor&&(m.cursor=c.cursor));var w={r:d.borderRadius||
0,rotation:v,padding:d.padding,zIndex:1};a.styledMode||(w.fill=d.backgroundColor,w.stroke=d.borderColor,w["stroke-width"]=d.borderWidth);y(w,function(a,d){"undefined"===typeof a&&delete w[d]})}!e||k&&H(l)?k&&H(l)&&(e?w.text=l:(h.dataLabels=h.dataLabels||[],e=h.dataLabels[b]=v?u.text(l,0,-9999,d.useHTML).addClass("highcharts-data-label"):u.label(l,0,-9999,d.shape,null,null,d.useHTML,null,"data-label"),b||(h.dataLabel=e),e.addClass(" highcharts-data-label-color-"+h.colorIndex+" "+(d.className||"")+
(d.useHTML?" highcharts-tracker":""))),e.options=d,e.attr(w),a.styledMode||e.css(m).shadow(d.shadow),e.added||e.add(D),d.textPath&&!d.useHTML&&(e.setTextPath(h.getDataLabelPath&&h.getDataLabelPath(e)||h.graphic,d.textPath),h.dataLabelPath&&!d.textPath.enabled&&(h.dataLabelPath=h.dataLabelPath.destroy())),f.alignDataLabel(h,e,d,null,r)):(h.dataLabel=h.dataLabel&&h.dataLabel.destroy(),h.dataLabels&&(1===h.dataLabels.length?delete h.dataLabels:delete h.dataLabels[b]),b||delete h.dataLabel,p&&(h.connector=
h.connector.destroy(),h.connectors&&(1===h.connectors.length?delete h.connectors:delete h.connectors[b])))})})}K(this,"afterDrawDataLabels")};u.prototype.alignDataLabel=function(g,b,f,a,c){var k=this,e=this.chart,l=this.isCartesian&&e.inverted,m=this.enabledDataSorting,v=A(g.dlBox&&g.dlBox.centerX,g.plotX,-9999),n=A(g.plotY,-9999),F=b.getBBox(),q=f.rotation,u=f.align,h=e.isInsidePlot(v,Math.round(n),l),d="justify"===A(f.overflow,m?"none":"justify"),G=this.visible&&!1!==g.visible&&(g.series.forceDL||
m&&!d||h||f.inside&&a&&e.isInsidePlot(v,l?a.x+1:a.y+a.height-1,l));var y=function(a){m&&k.xAxis&&!d&&k.setDataLabelStartPos(g,b,c,h,a)};if(G){var t=e.renderer.fontMetrics(e.styledMode?void 0:f.style.fontSize,b).b;a=L({x:l?this.yAxis.len-n:v,y:Math.round(l?this.xAxis.len-v:n),width:0,height:0},a);L(f,{width:F.width,height:F.height});q?(d=!1,v=e.renderer.rotCorr(t,q),v={x:a.x+f.x+a.width/2+v.x,y:a.y+f.y+{top:0,middle:.5,bottom:1}[f.verticalAlign]*a.height},y(v),b[c?"attr":"animate"](v).attr({align:u}),
y=(q+720)%360,y=180<y&&360>y,"left"===u?v.y-=y?F.height:0:"center"===u?(v.x-=F.width/2,v.y-=F.height/2):"right"===u&&(v.x-=F.width,v.y-=y?0:F.height),b.placed=!0,b.alignAttr=v):(y(a),b.align(f,null,a),v=b.alignAttr);d&&0<=a.height?this.justifyDataLabel(b,f,v,F,a,c):A(f.crop,!0)&&(G=e.isInsidePlot(v.x,v.y)&&e.isInsidePlot(v.x+F.width,v.y+F.height));if(f.shape&&!q)b[c?"attr":"animate"]({anchorX:l?e.plotWidth-g.plotY:g.plotX,anchorY:l?e.plotHeight-g.plotX:g.plotY})}c&&m&&(b.placed=!1);G||m&&!d||(b.hide(!0),
b.placed=!1)};u.prototype.setDataLabelStartPos=function(g,b,f,a,c){var k=this.chart,e=k.inverted,l=this.xAxis,m=l.reversed,v=e?b.height/2:b.width/2;g=(g=g.pointWidth)?g/2:0;l=e?c.x:m?-v-g:l.width-v+g;c=e?m?this.yAxis.height-v+g:-v-g:c.y;b.startXPos=l;b.startYPos=c;a?"hidden"===b.visibility&&(b.show(),b.attr({opacity:0}).animate({opacity:1})):b.attr({opacity:1}).animate({opacity:0},void 0,b.hide);k.hasRendered&&(f&&b.attr({x:b.startXPos,y:b.startYPos}),b.placed=!0)};u.prototype.justifyDataLabel=function(g,
b,f,a,c,k){var e=this.chart,r=b.align,l=b.verticalAlign,m=g.box?0:g.padding||0;var n=f.x+m;if(0>n){"right"===r?(b.align="left",b.inside=!0):b.x=-n;var F=!0}n=f.x+a.width-m;n>e.plotWidth&&("left"===r?(b.align="right",b.inside=!0):b.x=e.plotWidth-n,F=!0);n=f.y+m;0>n&&("bottom"===l?(b.verticalAlign="top",b.inside=!0):b.y=-n,F=!0);n=f.y+a.height-m;n>e.plotHeight&&("top"===l?(b.verticalAlign="bottom",b.inside=!0):b.y=e.plotHeight-n,F=!0);F&&(g.placed=!k,g.align(b,null,c));return F};k.pie&&(k.pie.prototype.dataLabelPositioners=
{radialDistributionY:function(g){return g.top+g.distributeBox.pos},radialDistributionX:function(g,b,f,a){return g.getX(f<b.top+2||f>b.bottom-2?a:f,b.half,b)},justify:function(g,b,f){return f[0]+(g.half?-1:1)*(b+g.labelDistance)},alignToPlotEdges:function(g,b,f,a){g=g.getBBox().width;return b?g+a:f-g-a},alignToConnectors:function(g,b,f,a){var c=0,k;g.forEach(function(a){k=a.dataLabel.getBBox().width;k>c&&(c=k)});return b?c+a:f-c-a}},k.pie.prototype.drawDataLabels=function(){var g=this,b=g.data,f,a=
g.chart,c=g.options.dataLabels||{},k=c.connectorPadding,e,m=a.plotWidth,w=a.plotHeight,v=a.plotLeft,n=Math.round(a.chartWidth/3),F,q=g.center,D=q[2]/2,h=q[1],d,y,z,C,E=[[],[]],B,x,K,L,N=[0,0,0,0],P=g.dataLabelPositioners,X;g.visible&&(c.enabled||g._hasPointLabels)&&(b.forEach(function(a){a.dataLabel&&a.visible&&a.dataLabel.shortened&&(a.dataLabel.attr({width:"auto"}).css({width:"auto",textOverflow:"clip"}),a.dataLabel.shortened=!1)}),u.prototype.drawDataLabels.apply(g),b.forEach(function(a){a.dataLabel&&
(a.visible?(E[a.half].push(a),a.dataLabel._pos=null,!H(c.style.width)&&!H(a.options.dataLabels&&a.options.dataLabels.style&&a.options.dataLabels.style.width)&&a.dataLabel.getBBox().width>n&&(a.dataLabel.css({width:Math.round(.7*n)+"px"}),a.dataLabel.shortened=!0)):(a.dataLabel=a.dataLabel.destroy(),a.dataLabels&&1===a.dataLabels.length&&delete a.dataLabels))}),E.forEach(function(b,e){var n=b.length,p=[],r;if(n){g.sortByAngle(b,e-.5);if(0<g.maxLabelDistance){var F=Math.max(0,h-D-g.maxLabelDistance);
var u=Math.min(h+D+g.maxLabelDistance,a.plotHeight);b.forEach(function(d){0<d.labelDistance&&d.dataLabel&&(d.top=Math.max(0,h-D-d.labelDistance),d.bottom=Math.min(h+D+d.labelDistance,a.plotHeight),r=d.dataLabel.getBBox().height||21,d.distributeBox={target:d.labelPosition.natural.y-d.top+r/2,size:r,rank:d.y},p.push(d.distributeBox))});F=u+r-F;l.distribute(p,F,F/5)}for(L=0;L<n;L++){f=b[L];z=f.labelPosition;d=f.dataLabel;K=!1===f.visible?"hidden":"inherit";x=F=z.natural.y;p&&H(f.distributeBox)&&("undefined"===
typeof f.distributeBox.pos?K="hidden":(C=f.distributeBox.size,x=P.radialDistributionY(f)));delete f.positionIndex;if(c.justify)B=P.justify(f,D,q);else switch(c.alignTo){case "connectors":B=P.alignToConnectors(b,e,m,v);break;case "plotEdges":B=P.alignToPlotEdges(d,e,m,v);break;default:B=P.radialDistributionX(g,f,x,F)}d._attr={visibility:K,align:z.alignment};X=f.options.dataLabels||{};d._pos={x:B+A(X.x,c.x)+({left:k,right:-k}[z.alignment]||0),y:x+A(X.y,c.y)-10};z.final.x=B;z.final.y=x;A(c.crop,!0)&&
(y=d.getBBox().width,F=null,B-y<k&&1===e?(F=Math.round(y-B+k),N[3]=Math.max(F,N[3])):B+y>m-k&&0===e&&(F=Math.round(B+y-m+k),N[1]=Math.max(F,N[1])),0>x-C/2?N[0]=Math.max(Math.round(-x+C/2),N[0]):x+C/2>w&&(N[2]=Math.max(Math.round(x+C/2-w),N[2])),d.sideOverflow=F)}}}),0===t(N)||this.verifyDataLabelOverflow(N))&&(this.placeDataLabels(),this.points.forEach(function(b){X=J(c,b.options.dataLabels);if(e=A(X.connectorWidth,1)){var h;F=b.connector;if((d=b.dataLabel)&&d._pos&&b.visible&&0<b.labelDistance){K=
d._attr.visibility;if(h=!F)b.connector=F=a.renderer.path().addClass("highcharts-data-label-connector highcharts-color-"+b.colorIndex+(b.className?" "+b.className:"")).add(g.dataLabelsGroup),a.styledMode||F.attr({"stroke-width":e,stroke:X.connectorColor||b.color||"#666666"});F[h?"attr":"animate"]({d:b.getConnectorPath()});F.attr("visibility",K)}else F&&(b.connector=F.destroy())}}))},k.pie.prototype.placeDataLabels=function(){this.points.forEach(function(g){var b=g.dataLabel,f;b&&g.visible&&((f=b._pos)?
(b.sideOverflow&&(b._attr.width=Math.max(b.getBBox().width-b.sideOverflow,0),b.css({width:b._attr.width+"px",textOverflow:(this.options.dataLabels.style||{}).textOverflow||"ellipsis"}),b.shortened=!0),b.attr(b._attr),b[b.moved?"animate":"attr"](f),b.moved=!0):b&&b.attr({y:-9999}));delete g.distributeBox},this)},k.pie.prototype.alignDataLabel=e,k.pie.prototype.verifyDataLabelOverflow=function(g){var b=this.center,f=this.options,a=f.center,c=f.minSize||80,k=null!==f.size;if(!k){if(null!==a[0])var e=
Math.max(b[2]-Math.max(g[1],g[3]),c);else e=Math.max(b[2]-g[1]-g[3],c),b[0]+=(g[3]-g[1])/2;null!==a[1]?e=x(e,c,b[2]-Math.max(g[0],g[2])):(e=x(e,c,b[2]-g[0]-g[2]),b[1]+=(g[0]-g[2])/2);e<b[2]?(b[2]=e,b[3]=Math.min(z(f.innerSize||0,e),e),this.translate(b),this.drawDataLabels&&this.drawDataLabels()):k=!0}return k});k.column&&(k.column.prototype.alignDataLabel=function(g,b,f,a,c){var k=this.chart.inverted,e=g.series,l=g.dlBox||g.shapeArgs,m=A(g.below,g.plotY>A(this.translatedThreshold,e.yAxis.len)),v=
A(f.inside,!!this.options.stacking);l&&(a=J(l),0>a.y&&(a.height+=a.y,a.y=0),l=a.y+a.height-e.yAxis.len,0<l&&l<a.height&&(a.height-=l),k&&(a={x:e.yAxis.len-a.y-a.height,y:e.xAxis.len-a.x-a.width,width:a.height,height:a.width}),v||(k?(a.x+=m?0:a.width,a.width=0):(a.y+=m?a.height:0,a.height=0)));f.align=A(f.align,!k||v?"center":m?"right":"left");f.verticalAlign=A(f.verticalAlign,k||v?"middle":m?"top":"bottom");u.prototype.alignDataLabel.call(this,g,b,f,a,c);f.inside&&g.contrastColor&&b.css({color:g.contrastColor})})});
P(x,"modules/overlapping-datalabels.src.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var B=e.addEvent,t=e.fireEvent,x=e.isArray,H=e.objectEach,L=e.pick;l=l.Chart;B(l,"render",function(){var e=[];(this.labelCollectors||[]).forEach(function(l){e=e.concat(l())});(this.yAxis||[]).forEach(function(l){l.stacking&&l.options.stackLabels&&!l.options.stackLabels.allowOverlap&&H(l.stacking.stacks,function(l){H(l,function(l){e.push(l.label)})})});(this.series||[]).forEach(function(l){var t=
l.options.dataLabels;l.visible&&(!1!==t.enabled||l._hasPointLabels)&&(l.nodes||l.points).forEach(function(l){l.visible&&(x(l.dataLabels)?l.dataLabels:l.dataLabel?[l.dataLabel]:[]).forEach(function(y){var t=y.options;y.labelrank=L(t.labelrank,l.labelrank,l.shapeArgs&&l.shapeArgs.height);t.allowOverlap||e.push(y)})})});this.hideOverlappingLabels(e)});l.prototype.hideOverlappingLabels=function(e){var l=this,C=e.length,J=l.renderer,y,A,z,q=!1;var m=function(g){var b,f=g.box?0:g.padding||0,a=b=0,c;if(g&&
(!g.alignAttr||g.placed)){var k=g.alignAttr||{x:g.attr("x"),y:g.attr("y")};var e=g.parentGroup;g.width||(b=g.getBBox(),g.width=b.width,g.height=b.height,b=J.fontMetrics(null,g.element).h);var l=g.width-2*f;(c={left:"0",center:"0.5",right:"1"}[g.alignValue])?a=+c*l:Math.round(g.x)!==g.translateX&&(a=g.x-g.translateX);return{x:k.x+(e.translateX||0)+f-a,y:k.y+(e.translateY||0)+f-b,width:g.width-2*f,height:g.height-2*f}}};for(A=0;A<C;A++)if(y=e[A])y.oldOpacity=y.opacity,y.newOpacity=1,y.absoluteBox=m(y);
e.sort(function(g,b){return(b.labelrank||0)-(g.labelrank||0)});for(A=0;A<C;A++){var u=(m=e[A])&&m.absoluteBox;for(y=A+1;y<C;++y){var k=(z=e[y])&&z.absoluteBox;!u||!k||m===z||0===m.newOpacity||0===z.newOpacity||k.x>u.x+u.width||k.x+k.width<u.x||k.y>u.y+u.height||k.y+k.height<u.y||((m.labelrank<z.labelrank?m:z).newOpacity=0)}}e.forEach(function(g){if(g){var b=g.newOpacity;g.oldOpacity!==b&&(g.alignAttr&&g.placed?(g[b?"removeClass":"addClass"]("highcharts-data-label-hidden"),q=!0,g.alignAttr.opacity=
b,g[g.isOld?"animate":"attr"](g.alignAttr,null,function(){l.styledMode||g.css({pointerEvents:b?"auto":"none"});g.visibility=b?"inherit":"hidden";g.placed=!!b}),t(l,"afterHideOverlappingLabel")):g.attr({opacity:b}));g.isOld=!0}});q&&t(l,"afterHideAllOverlappingLabels")}});P(x,"parts/Interaction.js",[x["parts/Globals.js"],x["parts/Legend.js"],x["parts/Point.js"],x["parts/Utilities.js"]],function(l,e,B,t){var x=t.addEvent,H=t.createElement,L=t.css,K=t.defined,E=t.extend,C=t.fireEvent,J=t.isArray,y=t.isFunction,
A=t.isNumber,z=t.isObject,q=t.merge,m=t.objectEach,u=t.pick;t=l.Chart;var k=l.defaultOptions,g=l.defaultPlotOptions,b=l.hasTouch,f=l.Series,a=l.seriesTypes,c=l.svg;var r=l.TrackerMixin={drawTrackerPoint:function(){var a=this,c=a.chart,f=c.pointer,g=function(a){var b=f.getPointFromEvent(a);"undefined"!==typeof b&&(f.isDirectTouch=!0,b.onMouseOver(a))},k;a.points.forEach(function(a){k=J(a.dataLabels)?a.dataLabels:a.dataLabel?[a.dataLabel]:[];a.graphic&&(a.graphic.element.point=a);k.forEach(function(b){b.div?
b.div.point=a:b.element.point=a})});a._hasTracking||(a.trackerGroups.forEach(function(k){if(a[k]){a[k].addClass("highcharts-tracker").on("mouseover",g).on("mouseout",function(a){f.onTrackerMouseOut(a)});if(b)a[k].on("touchstart",g);!c.styledMode&&a.options.cursor&&a[k].css(L).css({cursor:a.options.cursor})}}),a._hasTracking=!0);C(this,"afterDrawTracker")},drawTrackerGraph:function(){var a=this,f=a.options,g=f.trackByArea,k=[].concat(g?a.areaPath:a.graphPath),e=a.chart,l=e.pointer,r=e.renderer,m=e.options.tooltip.snap,
h=a.tracker,d=function(d){if(e.hoverSeries!==a)a.onMouseOver()},q="rgba(192,192,192,"+(c?.0001:.002)+")";h?h.attr({d:k}):a.graph&&(a.tracker=r.path(k).attr({visibility:a.visible?"visible":"hidden",zIndex:2}).addClass(g?"highcharts-tracker-area":"highcharts-tracker-line").add(a.group),e.styledMode||a.tracker.attr({"stroke-linecap":"round","stroke-linejoin":"round",stroke:q,fill:g?q:"none","stroke-width":a.graph.strokeWidth()+(g?0:2*m)}),[a.tracker,a.markerGroup].forEach(function(a){a.addClass("highcharts-tracker").on("mouseover",
d).on("mouseout",function(a){l.onTrackerMouseOut(a)});f.cursor&&!e.styledMode&&a.css({cursor:f.cursor});if(b)a.on("touchstart",d)}));C(this,"afterDrawTracker")}};a.column&&(a.column.prototype.drawTracker=r.drawTrackerPoint);a.pie&&(a.pie.prototype.drawTracker=r.drawTrackerPoint);a.scatter&&(a.scatter.prototype.drawTracker=r.drawTrackerPoint);E(e.prototype,{setItemEvents:function(a,b,c){var f=this,g=f.chart.renderer.boxWrapper,k=a instanceof B,e="highcharts-legend-"+(k?"point":"series")+"-active",
p=f.chart.styledMode;(c?[b,a.legendSymbol]:[a.legendGroup]).forEach(function(c){if(c)c.on("mouseover",function(){a.visible&&f.allItems.forEach(function(d){a!==d&&d.setState("inactive",!k)});a.setState("hover");a.visible&&g.addClass(e);p||b.css(f.options.itemHoverStyle)}).on("mouseout",function(){f.chart.styledMode||b.css(q(a.visible?f.itemStyle:f.itemHiddenStyle));f.allItems.forEach(function(d){a!==d&&d.setState("",!k)});g.removeClass(e);a.setState()}).on("click",function(d){var b=function(){a.setVisible&&
a.setVisible();f.allItems.forEach(function(d){a!==d&&d.setState(a.visible?"inactive":"",!k)})};g.removeClass(e);d={browserEvent:d};a.firePointEvent?a.firePointEvent("legendItemClick",d,b):C(a,"legendItemClick",d,b)})})},createCheckboxForItem:function(a){a.checkbox=H("input",{type:"checkbox",className:"highcharts-legend-checkbox",checked:a.selected,defaultChecked:a.selected},this.options.itemCheckboxStyle,this.chart.container);x(a.checkbox,"click",function(b){C(a.series||a,"checkboxClick",{checked:b.target.checked,
item:a},function(){a.select()})})}});E(t.prototype,{showResetZoom:function(){function a(){b.zoomOut()}var b=this,c=k.lang,f=b.options.chart.resetZoomButton,g=f.theme,e=g.states,l="chart"===f.relativeTo||"spaceBox"===f.relativeTo?null:"plotBox";C(this,"beforeShowResetZoom",null,function(){b.resetZoomButton=b.renderer.button(c.resetZoom,null,null,a,g,e&&e.hover).attr({align:f.position.align,title:c.resetZoomTitle}).addClass("highcharts-reset-zoom").add().align(f.position,!1,l)});C(this,"afterShowResetZoom")},
zoomOut:function(){C(this,"selection",{resetSelection:!0},this.zoom)},zoom:function(a){var b=this,c,f=b.pointer,g=!1,k=b.inverted?f.mouseDownX:f.mouseDownY;!a||a.resetSelection?(b.axes.forEach(function(a){c=a.zoom()}),f.initiated=!1):a.xAxis.concat(a.yAxis).forEach(function(a){var h=a.axis,d=b.inverted?h.left:h.top,e=b.inverted?d+h.width:d+h.height,n=h.isXAxis,p=!1;if(!n&&k>=d&&k<=e||n||!K(k))p=!0;f[n?"zoomX":"zoomY"]&&p&&(c=h.zoom(a.min,a.max),h.displayBtn&&(g=!0))});var e=b.resetZoomButton;g&&!e?
b.showResetZoom():!g&&z(e)&&(b.resetZoomButton=e.destroy());c&&b.redraw(u(b.options.chart.animation,a&&a.animation,100>b.pointCount))},pan:function(a,b){var c=this,f=c.hoverPoints,g=c.options.chart,k=c.options.mapNavigation&&c.options.mapNavigation.enabled,e;b="object"===typeof b?b:{enabled:b,type:"x"};g&&g.panning&&(g.panning=b);var p=b.type;C(this,"pan",{originalEvent:a},function(){f&&f.forEach(function(a){a.setState()});var b=[1];"xy"===p?b=[1,0]:"y"===p&&(b=[0]);b.forEach(function(d){var b=c[d?
"xAxis":"yAxis"][0],h=b.options,f=b.horiz,g=a[f?"chartX":"chartY"];f=f?"mouseDownX":"mouseDownY";var n=c[f],r=(b.pointRange||0)/2,m=b.reversed&&!c.inverted||!b.reversed&&c.inverted?-1:1,v=b.getExtremes(),w=b.toValue(n-g,!0)+r*m;m=b.toValue(n+b.len-g,!0)-r*m;var F=m<w;n=F?m:w;w=F?w:m;var q=b.hasVerticalPanning(),u=b.panningState;b.series.forEach(function(a){if(q&&!d&&(!u||u.isDirty)){var b=a.getProcessedData(!0);a=a.getExtremes(b.yData,!0);u||(u={startMin:Number.MAX_VALUE,startMax:-Number.MAX_VALUE});
A(a.dataMin)&&A(a.dataMax)&&(u.startMin=Math.min(a.dataMin,u.startMin),u.startMax=Math.max(a.dataMax,u.startMax))}});m=Math.min(l.pick(null===u||void 0===u?void 0:u.startMin,v.dataMin),r?v.min:b.toValue(b.toPixels(v.min)-b.minPixelPadding));r=Math.max(l.pick(null===u||void 0===u?void 0:u.startMax,v.dataMax),r?v.max:b.toValue(b.toPixels(v.max)+b.minPixelPadding));b.panningState=u;if(!h.ordinal){h=m-n;0<h&&(w+=h,n=m);h=w-r;0<h&&(w=r,n-=h);if(b.series.length&&n!==v.min&&w!==v.max&&d||u&&n>=m&&w<=r)b.setExtremes(n,
w,!1,!1,{trigger:"pan"}),c.resetZoomButton||k||!p.match("y")||(c.showResetZoom(),b.displayBtn=!1),e=!0;c[f]=g}});e&&c.redraw(!1);L(c.container,{cursor:"move"})})}});E(B.prototype,{select:function(a,b){var c=this,f=c.series,g=f.chart;this.selectedStaging=a=u(a,!c.selected);c.firePointEvent(a?"select":"unselect",{accumulate:b},function(){c.selected=c.options.selected=a;f.options.data[f.data.indexOf(c)]=c.options;c.setState(a&&"select");b||g.getSelectedPoints().forEach(function(a){var b=a.series;a.selected&&
a!==c&&(a.selected=a.options.selected=!1,b.options.data[b.data.indexOf(a)]=a.options,a.setState(g.hoverPoints&&b.options.inactiveOtherPoints?"inactive":""),a.firePointEvent("unselect"))})});delete this.selectedStaging},onMouseOver:function(a){var b=this.series.chart,c=b.pointer;a=a?c.normalize(a):c.getChartCoordinatesFromPoint(this,b.inverted);c.runPointActions(a,this)},onMouseOut:function(){var a=this.series.chart;this.firePointEvent("mouseOut");this.series.options.inactiveOtherPoints||(a.hoverPoints||
[]).forEach(function(a){a.setState()});a.hoverPoints=a.hoverPoint=null},importEvents:function(){if(!this.hasImportedEvents){var a=this,b=q(a.series.options.point,a.options).events;a.events=b;m(b,function(b,c){y(b)&&x(a,c,b)});this.hasImportedEvents=!0}},setState:function(a,b){var c=this.series,f=this.state,k=c.options.states[a||"normal"]||{},e=g[c.type].marker&&c.options.marker,p=e&&!1===e.enabled,l=e&&e.states&&e.states[a||"normal"]||{},h=!1===l.enabled,d=c.stateMarkerGraphic,r=this.marker||{},m=
c.chart,q=c.halo,y,t=e&&c.markerAttribs;a=a||"";if(!(a===this.state&&!b||this.selected&&"select"!==a||!1===k.enabled||a&&(h||p&&!1===l.enabled)||a&&r.states&&r.states[a]&&!1===r.states[a].enabled)){this.state=a;t&&(y=c.markerAttribs(this,a));if(this.graphic){f&&this.graphic.removeClass("highcharts-point-"+f);a&&this.graphic.addClass("highcharts-point-"+a);if(!m.styledMode){var I=c.pointAttribs(this,a);var z=u(m.options.chart.animation,k.animation);c.options.inactiveOtherPoints&&I.opacity&&((this.dataLabels||
[]).forEach(function(a){a&&a.animate({opacity:I.opacity},z)}),this.connector&&this.connector.animate({opacity:I.opacity},z));this.graphic.animate(I,z)}y&&this.graphic.animate(y,u(m.options.chart.animation,l.animation,e.animation));d&&d.hide()}else{if(a&&l){f=r.symbol||c.symbol;d&&d.currentSymbol!==f&&(d=d.destroy());if(y)if(d)d[b?"animate":"attr"]({x:y.x,y:y.y});else f&&(c.stateMarkerGraphic=d=m.renderer.symbol(f,y.x,y.y,y.width,y.height).add(c.markerGroup),d.currentSymbol=f);!m.styledMode&&d&&d.attr(c.pointAttribs(this,
a))}d&&(d[a&&this.isInside?"show":"hide"](),d.element.point=this)}a=k.halo;k=(d=this.graphic||d)&&d.visibility||"inherit";a&&a.size&&d&&"hidden"!==k&&!this.isCluster?(q||(c.halo=q=m.renderer.path().add(d.parentGroup)),q.show()[b?"animate":"attr"]({d:this.haloPath(a.size)}),q.attr({"class":"highcharts-halo highcharts-color-"+u(this.colorIndex,c.colorIndex)+(this.className?" "+this.className:""),visibility:k,zIndex:-1}),q.point=this,m.styledMode||q.attr(E({fill:this.color||c.color,"fill-opacity":a.opacity},
a.attributes))):q&&q.point&&q.point.haloPath&&q.animate({d:q.point.haloPath(0)},null,q.hide);C(this,"afterSetState")}},haloPath:function(a){return this.series.chart.renderer.symbols.circle(Math.floor(this.plotX)-a,this.plotY-a,2*a,2*a)}});E(f.prototype,{onMouseOver:function(){var a=this.chart,b=a.hoverSeries;a.pointer.setHoverChartIndex();if(b&&b!==this)b.onMouseOut();this.options.events.mouseOver&&C(this,"mouseOver");this.setState("hover");a.hoverSeries=this},onMouseOut:function(){var a=this.options,
b=this.chart,c=b.tooltip,f=b.hoverPoint;b.hoverSeries=null;if(f)f.onMouseOut();this&&a.events.mouseOut&&C(this,"mouseOut");!c||this.stickyTracking||c.shared&&!this.noSharedTooltip||c.hide();b.series.forEach(function(a){a.setState("",!0)})},setState:function(a,b){var c=this,f=c.options,g=c.graph,k=f.inactiveOtherPoints,e=f.states,l=f.lineWidth,h=f.opacity,d=u(e[a||"normal"]&&e[a||"normal"].animation,c.chart.options.chart.animation);f=0;a=a||"";if(c.state!==a&&([c.group,c.markerGroup,c.dataLabelsGroup].forEach(function(d){d&&
(c.state&&d.removeClass("highcharts-series-"+c.state),a&&d.addClass("highcharts-series-"+a))}),c.state=a,!c.chart.styledMode)){if(e[a]&&!1===e[a].enabled)return;a&&(l=e[a].lineWidth||l+(e[a].lineWidthPlus||0),h=u(e[a].opacity,h));if(g&&!g.dashstyle)for(e={"stroke-width":l},g.animate(e,d);c["zone-graph-"+f];)c["zone-graph-"+f].attr(e),f+=1;k||[c.group,c.markerGroup,c.dataLabelsGroup,c.labelBySeries].forEach(function(a){a&&a.animate({opacity:h},d)})}b&&k&&c.points&&c.setAllPointsToState(a)},setAllPointsToState:function(a){this.points.forEach(function(b){b.setState&&
b.setState(a)})},setVisible:function(a,b){var c=this,f=c.chart,g=c.legendItem,k=f.options.chart.ignoreHiddenSeries,e=c.visible;var l=(c.visible=a=c.options.visible=c.userOptions.visible="undefined"===typeof a?!e:a)?"show":"hide";["group","dataLabelsGroup","markerGroup","tracker","tt"].forEach(function(a){if(c[a])c[a][l]()});if(f.hoverSeries===c||(f.hoverPoint&&f.hoverPoint.series)===c)c.onMouseOut();g&&f.legend.colorizeItem(c,a);c.isDirty=!0;c.options.stacking&&f.series.forEach(function(a){a.options.stacking&&
a.visible&&(a.isDirty=!0)});c.linkedSeries.forEach(function(b){b.setVisible(a,!1)});k&&(f.isDirtyBox=!0);C(c,l);!1!==b&&f.redraw()},show:function(){this.setVisible(!0)},hide:function(){this.setVisible(!1)},select:function(a){this.selected=a=this.options.selected="undefined"===typeof a?!this.selected:a;this.checkbox&&(this.checkbox.checked=a);C(this,a?"select":"unselect")},drawTracker:r.drawTrackerGraph})});P(x,"parts/Responsive.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=
e.find,t=e.isArray,N=e.isObject,H=e.merge,L=e.objectEach,K=e.pick,E=e.splat,C=e.uniqueKey;l=l.Chart;l.prototype.setResponsive=function(e,l){var y=this.options.responsive,t=[],q=this.currentResponsive;!l&&y&&y.rules&&y.rules.forEach(function(e){"undefined"===typeof e._id&&(e._id=C());this.matchResponsiveRule(e,t)},this);l=H.apply(0,t.map(function(e){return x(y.rules,function(l){return l._id===e}).chartOptions}));l.isResponsiveOptions=!0;t=t.toString()||void 0;t!==(q&&q.ruleIds)&&(q&&this.update(q.undoOptions,
e,!0),t?(q=this.currentOptions(l),q.isResponsiveOptions=!0,this.currentResponsive={ruleIds:t,mergedOptions:l,undoOptions:q},this.update(l,e,!0)):this.currentResponsive=void 0)};l.prototype.matchResponsiveRule=function(e,l){var y=e.condition;(y.callback||function(){return this.chartWidth<=K(y.maxWidth,Number.MAX_VALUE)&&this.chartHeight<=K(y.maxHeight,Number.MAX_VALUE)&&this.chartWidth>=K(y.minWidth,0)&&this.chartHeight>=K(y.minHeight,0)}).call(this)&&l.push(e._id)};l.prototype.currentOptions=function(e){function l(e,
m,u,k){var g;L(e,function(b,f){if(!k&&-1<C.collectionsWithUpdate.indexOf(f))for(b=E(b),u[f]=[],g=0;g<b.length;g++)m[f][g]&&(u[f][g]={},l(b[g],m[f][g],u[f][g],k+1));else N(b)?(u[f]=t(b)?[]:{},l(b,m[f]||{},u[f],k+1)):u[f]="undefined"===typeof m[f]?null:m[f]})}var C=this,z={};l(e,this.options,z,0);return z}});P(x,"masters/highcharts.src.js",[x["parts/Globals.js"]],function(l){return l});P(x,"parts-gantt/CurrentDateIndicator.js",[x["parts/Globals.js"],x["parts/Utilities.js"],x["parts/PlotLineOrBand.js"]],
function(l,e,x){var t=e.addEvent,B=e.merge;e=e.wrap;var H={currentDateIndicator:!0,color:"#ccd6eb",width:2,label:{format:"%a, %b %d %Y, %H:%M",formatter:function(e,t){return l.dateFormat(t,e)},rotation:0,style:{fontSize:"10px"}}};t(l.Axis,"afterSetOptions",function(){var e=this.options,l=e.currentDateIndicator;l&&(l="object"===typeof l?B(H,l):B(H),l.value=new Date,e.plotLines||(e.plotLines=[]),e.plotLines.push(l))});t(x,"render",function(){this.label&&this.label.attr({text:this.getLabelText(this.options.label)})});
e(x.prototype,"getLabelText",function(e,l){var t=this.options;return t.currentDateIndicator&&t.label&&"function"===typeof t.label.formatter?(t.value=new Date,t.label.formatter.call(this,t.value,t.label.format)):e.call(this,l)})});P(x,"modules/static-scale.src.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=e.addEvent,t=e.defined,N=e.isNumber,H=e.pick;e=l.Chart;x(l.Axis,"afterSetOptions",function(){var e=this.chart.options&&this.chart.options.chart;!this.horiz&&N(this.options.staticScale)&&
(!e.height||e.scrollablePlotArea&&e.scrollablePlotArea.minHeight)&&(this.staticScale=this.options.staticScale)});e.prototype.adjustHeight=function(){"adjustHeight"!==this.redrawTrigger&&((this.axes||[]).forEach(function(e){var l=e.chart,E=!!l.initiatedScale&&l.options.animation,C=e.options.staticScale;if(e.staticScale&&t(e.min)){var J=H(e.brokenAxis&&e.brokenAxis.unitLength,e.max+e.tickInterval-e.min)*C;J=Math.max(J,C);C=J-l.plotHeight;1<=Math.abs(C)&&(l.plotHeight=J,l.redrawTrigger="adjustHeight",
l.setSize(void 0,l.chartHeight+C,E));e.series.forEach(function(e){(e=e.sharedClipKey&&l[e.sharedClipKey])&&e.attr({height:l.plotHeight})})}}),this.initiatedScale=!0);this.redrawTrigger=null};x(e,"render",e.prototype.adjustHeight)});P(x,"parts-gantt/Tree.js",[x["parts/Utilities.js"]],function(l){var e=l.extend,x=l.isNumber,t=l.pick,N=function(e,l){var E=e.reduce(function(e,l){var y=t(l.parent,"");"undefined"===typeof e[y]&&(e[y]=[]);e[y].push(l);return e},{});Object.keys(E).forEach(function(e,t){var y=
E[e];""!==e&&-1===l.indexOf(e)&&(y.forEach(function(e){t[""].push(e)}),delete t[e])});return E},H=function(l,B,E,C,J,y){var A=0,z=0,q=y&&y.after,m=y&&y.before;B={data:C,depth:E-1,id:l,level:E,parent:B};var u,k;"function"===typeof m&&m(B,y);m=(J[l]||[]).map(function(g){var b=H(g.id,l,E+1,g,J,y),f=g.start;g=!0===g.milestone?f:g.end;u=!x(u)||f<u?f:u;k=!x(k)||g>k?g:k;A=A+1+b.descendants;z=Math.max(b.height+1,z);return b});C&&(C.start=t(C.start,u),C.end=t(C.end,k));e(B,{children:m,descendants:A,height:z});
"function"===typeof q&&q(B,y);return B};return{getListOfParents:N,getNode:H,getTree:function(e,l){var t=e.map(function(e){return e.id});e=N(e,t);return H("",null,1,null,e,l)}}});P(x,"parts-gantt/TreeGridTick.js",[x["parts/Utilities.js"]],function(l){var e=l.addEvent,x=l.defined,t=l.isObject,N=l.isNumber,H=l.pick,L=l.wrap,K;(function(l){function C(){this.treeGrid||(this.treeGrid=new q(this))}function E(e,l){e=e.treeGrid;var k=!e.labelIcon,g=l.renderer,b=l.xy,f=l.options,a=f.width,c=f.height,r=b.x-
a/2-f.padding;b=b.y-c/2;var p=l.collapsed?90:180,m=l.show&&N(b),q=e.labelIcon;q||(e.labelIcon=q=g.path(g.symbols[f.type](f.x,f.y,a,c)).addClass("highcharts-label-icon").add(l.group));m||q.attr({y:-9999});g.styledMode||q.attr({"stroke-width":1,fill:H(l.color,"#666666")}).css({cursor:"pointer",stroke:f.lineColor,strokeWidth:f.lineWidth});q[k?"attr":"animate"]({translateX:r,translateY:b,rotation:p})}function y(e,l,k,g,b,f,a,c,r){var p=H(this.options&&this.options.labels,f);f=this.pos;var m=this.axis,
q="treegrid"===m.options.type;e=e.apply(this,[l,k,g,b,p,a,c,r]);q&&(l=p&&t(p.symbol,!0)?p.symbol:{},p=p&&N(p.indentation)?p.indentation:0,f=(f=(m=m.treeGrid.mapOfPosToGridNode)&&m[f])&&f.depth||1,e.x+=l.width+2*l.padding+(f-1)*p);return e}function A(l){var m=this,k=m.pos,g=m.axis,b=m.label,f=g.treeGrid.mapOfPosToGridNode,a=g.options,c=H(m.options&&m.options.labels,a&&a.labels),r=c&&t(c.symbol,!0)?c.symbol:{},p=(f=f&&f[k])&&f.depth;a="treegrid"===a.type;var q=-1<g.tickPositions.indexOf(k);k=g.chart.styledMode;
a&&f&&b&&b.element&&b.addClass("highcharts-treegrid-node-level-"+p);l.apply(m,Array.prototype.slice.call(arguments,1));a&&b&&b.element&&f&&f.descendants&&0<f.descendants&&(g=g.treeGrid.isCollapsed(f),E(m,{color:!k&&b.styles&&b.styles.color||"",collapsed:g,group:b.parentGroup,options:r,renderer:b.renderer,show:q,xy:b.xy}),r="highcharts-treegrid-node-"+(g?"expanded":"collapsed"),b.addClass("highcharts-treegrid-node-"+(g?"collapsed":"expanded")).removeClass(r),k||b.css({cursor:"pointer"}),[b,m.treeGrid.labelIcon].forEach(function(a){a&&
!a.attachedTreeGridEvents&&(e(a.element,"mouseover",function(){b.addClass("highcharts-treegrid-node-active");b.renderer.styledMode||b.css({textDecoration:"underline"})}),e(a.element,"mouseout",function(){var a=x(c.style)?c.style:{};b.removeClass("highcharts-treegrid-node-active");b.renderer.styledMode||b.css({textDecoration:a.textDecoration})}),e(a.element,"click",function(){m.treeGrid.toggleCollapse()}),a.attachedTreeGridEvents=!0)}))}var z=!1;l.compose=function(l){z||(e(l,"init",C),L(l.prototype,
"getLabelPosition",y),L(l.prototype,"renderLabel",A),l.prototype.collapse=function(e){this.treeGrid.collapse(e)},l.prototype.expand=function(e){this.treeGrid.expand(e)},l.prototype.toggleCollapse=function(e){this.treeGrid.toggleCollapse(e)},z=!0)};var q=function(){function e(e){this.tick=e}e.prototype.collapse=function(e){var k=this.tick,g=k.axis,b=g.brokenAxis;b&&g.treeGrid.mapOfPosToGridNode&&(k=g.treeGrid.collapse(g.treeGrid.mapOfPosToGridNode[k.pos]),b.setBreaks(k,H(e,!0)))};e.prototype.expand=
function(e){var k=this.tick,g=k.axis,b=g.brokenAxis;b&&g.treeGrid.mapOfPosToGridNode&&(k=g.treeGrid.expand(g.treeGrid.mapOfPosToGridNode[k.pos]),b.setBreaks(k,H(e,!0)))};e.prototype.toggleCollapse=function(e){var k=this.tick,g=k.axis,b=g.brokenAxis;b&&g.treeGrid.mapOfPosToGridNode&&(k=g.treeGrid.toggleCollapse(g.treeGrid.mapOfPosToGridNode[k.pos]),b.setBreaks(k,H(e,!0)))};return e}();l.Additions=q})(K||(K={}));return K});P(x,"mixins/tree-series.js",[x["parts/Color.js"],x["parts/Utilities.js"]],function(l,
e){var x=e.extend,t=e.isArray,N=e.isNumber,H=e.isObject,L=e.merge,K=e.pick;return{getColor:function(e,t){var C=t.index,y=t.mapOptionsToLevel,A=t.parentColor,z=t.parentColorIndex,q=t.series,m=t.colors,u=t.siblings,k=q.points,g=q.chart.options.chart,b;if(e){k=k[e.i];e=y[e.level]||{};if(y=k&&e.colorByPoint){var f=k.index%(m?m.length:g.colorCount);var a=m&&m[f]}if(!q.chart.styledMode){m=k&&k.options.color;g=e&&e.color;if(b=A)b=(b=e&&e.colorVariation)&&"brightness"===b.key?l.parse(A).brighten(C/u*b.to).get():
A;b=K(m,g,a,b,q.color)}var c=K(k&&k.options.colorIndex,e&&e.colorIndex,f,z,t.colorIndex)}return{color:b,colorIndex:c}},getLevelOptions:function(e){var l=null;if(H(e)){l={};var J=N(e.from)?e.from:1;var y=e.levels;var A={};var z=H(e.defaults)?e.defaults:{};t(y)&&(A=y.reduce(function(e,l){if(H(l)&&N(l.level)){var m=L({},l);var k="boolean"===typeof m.levelIsConstant?m.levelIsConstant:z.levelIsConstant;delete m.levelIsConstant;delete m.level;l=l.level+(k?0:J-1);H(e[l])?x(e[l],m):e[l]=m}return e},{}));
y=N(e.to)?e.to:1;for(e=0;e<=y;e++)l[e]=L({},z,H(A[e])?A[e]:{})}return l},setTreeValues:function y(e,l){var t=l.before,z=l.idRoot,q=l.mapIdToNode[z],m=l.points[e.i],u=m&&m.options||{},k=0,g=[];x(e,{levelDynamic:e.level-(("boolean"===typeof l.levelIsConstant?l.levelIsConstant:1)?0:q.level),name:K(m&&m.name,""),visible:z===e.id||("boolean"===typeof l.visible?l.visible:!1)});"function"===typeof t&&(e=t(e,l));e.children.forEach(function(b,f){var a=x({},l);x(a,{index:f,siblings:e.children.length,visible:e.visible});
b=y(b,a);g.push(b);b.visible&&(k+=b.val)});e.visible=0<k||e.visible;t=K(u.value,k);x(e,{children:g,childrenTotal:k,isLeaf:e.visible&&!k,val:t});return e},updateRootId:function(e){if(H(e)){var l=H(e.options)?e.options:{};l=K(e.rootNode,l.rootId,"");H(e.userOptions)&&(e.userOptions.rootId=l);e.rootNode=l}return l}}});P(x,"parts-gantt/GridAxis.js",[x["parts/Axis.js"],x["parts/Globals.js"],x["parts/Tick.js"],x["parts/Utilities.js"]],function(l,e,x,t){var B=t.addEvent,H=t.defined,L=t.erase,K=t.find,E=
t.isArray,C=t.isNumber,J=t.merge,y=t.pick,A=t.timeUnits,z=t.wrap,q=e.dateFormat,m=e.Chart,u=function(b){var f=b.options;f.labels||(f.labels={});f.labels.align=y(f.labels.align,"center");b.categories||(f.showLastLabel=!1);b.labelRotation=0;f.labels.rotation=0};"";l.prototype.getMaxLabelDimensions=function(b,f){var a={width:0,height:0};f.forEach(function(c){c=b[c];if(t.isObject(c,!0)){var f=t.isObject(c.label,!0)?c.label:{};c=f.getBBox?f.getBBox().height:0;f.textStr&&!C(f.textPxLength)&&(f.textPxLength=
f.getBBox().width);f=C(f.textPxLength)?Math.round(f.textPxLength):0;a.height=Math.max(c,a.height);a.width=Math.max(f,a.width)}});return a};e.dateFormats.W=function(b){b=new this.Date(b);var f=(this.get("Day",b)+6)%7,a=new this.Date(b.valueOf());this.set("Date",a,this.get("Date",b)-f+3);f=new this.Date(this.get("FullYear",a),0,1);4!==this.get("Day",f)&&(this.set("Month",b,0),this.set("Date",b,1+(11-this.get("Day",f))%7));return(1+Math.floor((a.valueOf()-f.valueOf())/6048E5)).toString()};e.dateFormats.E=
function(b){return q("%a",b,!0).charAt(0)};B(m,"afterSetChartSize",function(){this.axes.forEach(function(b){(b.grid&&b.grid.columns||[]).forEach(function(b){b.setAxisSize();b.setAxisTranslation()})})});B(x,"afterGetLabelPosition",function(b){var f=this.label,a=this.axis,c=a.reversed,e=a.chart,k=a.options.grid||{},l=a.options.labels,m=l.align,v=g.Side[a.side],n=b.tickmarkOffset,F=a.tickPositions,q=this.pos-n;F=C(F[b.index+1])?F[b.index+1]-n:a.max+n;var u=a.tickSize("tick");n=u?u[0]:0;u=u?u[1]/2:0;
if(!0===k.enabled){if("top"===v){k=a.top+a.offset;var h=k-n}else"bottom"===v?(h=e.chartHeight-a.bottom+a.offset,k=h+n):(k=a.top+a.len-a.translate(c?F:q),h=a.top+a.len-a.translate(c?q:F));"right"===v?(v=e.chartWidth-a.right+a.offset,c=v+n):"left"===v?(c=a.left+a.offset,v=c-n):(v=Math.round(a.left+a.translate(c?F:q))-u,c=Math.round(a.left+a.translate(c?q:F))-u);this.slotWidth=c-v;b.pos.x="left"===m?v:"right"===m?c:v+(c-v)/2;b.pos.y=h+(k-h)/2;e=e.renderer.fontMetrics(l.style.fontSize,f.element);f=f.getBBox().height;
l.useHTML?b.pos.y+=e.b+-(f/2):(f=Math.round(f/e.h),b.pos.y+=(e.b-(e.h-e.f))/2+-((f-1)*e.h/2));b.pos.x+=a.horiz&&l.x||0}});var k=function(){function b(b){this.axis=b}b.prototype.isOuterAxis=function(){var b=this.axis,a=b.grid.columnIndex,c=b.linkedParent&&b.linkedParent.grid.columns||b.grid.columns,g=a?b.linkedParent:b,e=-1,k=0;b.chart[b.coll].forEach(function(a,c){a.side!==b.side||a.options.isInternal||(k=c,a===g&&(e=c))});return k===e&&(C(a)?c.length===a:!0)};return b}(),g=function(){function b(){}
b.compose=function(f){l.keepProps.push("grid");z(f.prototype,"unsquish",b.wrapUnsquish);B(f,"init",b.onInit);B(f,"afterGetOffset",b.onAfterGetOffset);B(f,"afterGetTitlePosition",b.onAfterGetTitlePosition);B(f,"afterInit",b.onAfterInit);B(f,"afterRender",b.onAfterRender);B(f,"afterSetAxisTranslation",b.onAfterSetAxisTranslation);B(f,"afterSetOptions",b.onAfterSetOptions);B(f,"afterSetOptions",b.onAfterSetOptions2);B(f,"afterSetScale",b.onAfterSetScale);B(f,"afterTickSize",b.onAfterTickSize);B(f,"trimTicks",
b.onTrimTicks);B(f,"destroy",b.onDestroy)};b.onAfterGetOffset=function(){var b=this.grid;(b&&b.columns||[]).forEach(function(a){a.getOffset()})};b.onAfterGetTitlePosition=function(f){if(!0===(this.options.grid||{}).enabled){var a=this.axisTitle,c=this.height,g=this.horiz,e=this.left,k=this.offset,l=this.opposite,m=this.options.title,n=void 0===m?{}:m;m=this.top;var q=this.width,u=this.tickSize(),t=a&&a.getBBox().width,h=n.x||0,d=n.y||0,z=y(n.margin,g?5:10);a=this.chart.renderer.fontMetrics(n.style&&
n.style.fontSize,a).f;u=(g?m+c:e)+(g?1:-1)*(l?-1:1)*(u?u[0]/2:0)+(this.side===b.Side.bottom?a:0);f.titlePosition.x=g?e-t/2-z+h:u+(l?q:0)+k+h;f.titlePosition.y=g?u-(l?c:0)+(l?a:-a)/2+k+d:m-z+d}};b.onAfterInit=function(){var b=this.chart,a=this.options.grid;a=void 0===a?{}:a;var c=this.userOptions;a.enabled&&(u(this),z(this,"labelFormatter",function(a){var b=this.axis,c=this.value,f=b.tickPositions,g=(b.isLinked?b.linkedParent:b).series[0],e=c===f[0];f=c===f[f.length-1];g=g&&K(g.options.data,function(a){return a[b.isXAxis?
"x":"y"]===c});this.isFirst=e;this.isLast=f;this.point=g;return a.call(this)}));if(a.columns)for(var g=this.grid.columns=[],e=this.grid.columnIndex=0;++e<a.columns.length;){var k=J(c,a.columns[a.columns.length-e-1],{linkedTo:0,type:"category"});delete k.grid.columns;k=new l(this.chart,k);k.grid.isColumn=!0;k.grid.columnIndex=e;L(b.axes,k);L(b[this.coll],k);g.push(k)}};b.onAfterRender=function(){var f=this.grid,a=this.options,c=this.chart.renderer;if(!0===(a.grid||{}).enabled){this.maxLabelDimensions=
this.getMaxLabelDimensions(this.ticks,this.tickPositions);this.rightWall&&this.rightWall.destroy();if(this.grid&&this.grid.isOuterAxis()&&this.axisLine){var g=a.lineWidth;if(g){var e=this.getLinePath(g),k=e[0],l=e[1],m=((this.tickSize("tick")||[1])[0]-1)*(this.side===b.Side.top||this.side===b.Side.left?-1:1);"M"===k[0]&&"L"===l[0]&&(this.horiz?(k[2]+=m,l[2]+=m):(k[1]+=m,l[1]+=m));this.grid.axisLineExtra?this.grid.axisLineExtra.animate({d:e}):(this.grid.axisLineExtra=c.path(e).attr({zIndex:7}).addClass("highcharts-axis-line").add(this.axisGroup),
c.styledMode||this.grid.axisLineExtra.attr({stroke:a.lineColor,"stroke-width":g}));this.axisLine[this.showAxis?"show":"hide"](!0)}}(f&&f.columns||[]).forEach(function(a){a.render()})}};b.onAfterSetAxisTranslation=function(){var b=this.tickPositions&&this.tickPositions.info,a=this.options,c=a.grid||{},g=this.userOptions.labels||{};this.horiz&&(!0===c.enabled&&this.series.forEach(function(a){a.options.pointRange=0}),b&&a.dateTimeLabelFormats&&a.labels&&!H(g.align)&&(!1===a.dateTimeLabelFormats[b.unitName].range||
1<b.count)&&(a.labels.align="left",H(g.x)||(a.labels.x=3)))};b.onAfterSetOptions=function(b){var a=this.options;b=b.userOptions;var c=a&&t.isObject(a.grid,!0)?a.grid:{};if(!0===c.enabled){var f=J(!0,{className:"highcharts-grid-axis "+(b.className||""),dateTimeLabelFormats:{hour:{list:["%H:%M","%H"]},day:{list:["%A, %e. %B","%a, %e. %b","%E"]},week:{list:["Week %W","W%W"]},month:{list:["%B","%b","%o"]}},grid:{borderWidth:1},labels:{padding:2,style:{fontSize:"13px"}},margin:0,title:{text:null,reserveSpace:!1,
rotation:0},units:[["millisecond",[1,10,100]],["second",[1,10]],["minute",[1,5,15]],["hour",[1,6]],["day",[1]],["week",[1]],["month",[1]],["year",null]]},b);"xAxis"===this.coll&&(H(b.linkedTo)&&!H(b.tickPixelInterval)&&(f.tickPixelInterval=350),H(b.tickPixelInterval)||!H(b.linkedTo)||H(b.tickPositioner)||H(b.tickInterval)||(f.tickPositioner=function(a,b){var c=this.linkedParent&&this.linkedParent.tickPositions&&this.linkedParent.tickPositions.info;if(c){var g,e=f.units;for(g=0;g<e.length;g++)if(e[g][0]===
c.unitName){var k=g;break}if(e[k+1]){var l=e[k+1][0];var m=(e[k+1][1]||[1])[0]}else"year"===c.unitName&&(l="year",m=10*c.count);c=A[l];this.tickInterval=c*m;return this.getTimeTicks({unitRange:c,count:m,unitName:l},a,b,this.options.startOfWeek)}}));J(!0,this.options,f);this.horiz&&(a.minPadding=y(b.minPadding,0),a.maxPadding=y(b.maxPadding,0));C(a.grid.borderWidth)&&(a.tickWidth=a.lineWidth=c.borderWidth)}};b.onAfterSetOptions2=function(b){b=(b=b.userOptions)&&b.grid||{};var a=b.columns;b.enabled&&
a&&J(!0,this.options,a[a.length-1])};b.onAfterSetScale=function(){(this.grid.columns||[]).forEach(function(b){b.setScale()})};b.onAfterTickSize=function(b){var a=l.defaultLeftAxisOptions,c=this.horiz,f=this.maxLabelDimensions,g=this.options.grid;g=void 0===g?{}:g;g.enabled&&f&&(a=2*Math.abs(a.labels.x),c=c?g.cellHeight||a+f.height:a+f.width,E(b.tickSize)?b.tickSize[0]=c:b.tickSize=[c,0])};b.onDestroy=function(b){var a=this.grid;(a.columns||[]).forEach(function(a){a.destroy(b.keepEvents)});a.columns=
void 0};b.onInit=function(b){b=b.userOptions||{};var a=b.grid||{};a.enabled&&H(a.borderColor)&&(b.tickColor=b.lineColor=a.borderColor);this.grid||(this.grid=new k(this))};b.onTrimTicks=function(){var b=this.options,a=this.categories,c=this.tickPositions,g=c[0],e=c[c.length-1],k=this.linkedParent&&this.linkedParent.min||this.min,l=this.linkedParent&&this.linkedParent.max||this.max,m=this.tickInterval;!0!==(b.grid||{}).enabled||a||!this.horiz&&!this.isLinked||(g<k&&g+m>k&&!b.startOnTick&&(c[0]=k),e>
l&&e-m<l&&!b.endOnTick&&(c[c.length-1]=l))};b.wrapUnsquish=function(b){var a=this.options.grid;return!0===(void 0===a?{}:a).enabled&&this.categories?this.tickInterval:b.apply(this,Array.prototype.slice.call(arguments,1))};return b}();(function(b){b=b.Side||(b.Side={});b[b.top=0]="top";b[b.right=1]="right";b[b.bottom=2]="bottom";b[b.left=3]="left"})(g||(g={}));g.compose(l);return g});P(x,"modules/broken-axis.src.js",[x["parts/Axis.js"],x["parts/Globals.js"],x["parts/Utilities.js"],x["parts/Stacking.js"]],
function(l,e,x,t){var B=x.addEvent,H=x.find,L=x.fireEvent,K=x.isArray,E=x.isNumber,C=x.pick,J=e.Series,y=function(){function e(e){this.hasBreaks=!1;this.axis=e}e.isInBreak=function(e,l){var m=e.repeat||Infinity,q=e.from,k=e.to-e.from;l=l>=q?(l-q)%m:m-(q-l)%m;return e.inclusive?l<=k:l<k&&0!==l};e.lin2Val=function(l){var q=this.brokenAxis;q=q&&q.breakArray;if(!q)return l;var m;for(m=0;m<q.length;m++){var u=q[m];if(u.from>=l)break;else u.to<l?l+=u.len:e.isInBreak(u,l)&&(l+=u.len)}return l};e.val2Lin=
function(l){var q=this.brokenAxis;q=q&&q.breakArray;if(!q)return l;var m=l,u;for(u=0;u<q.length;u++){var k=q[u];if(k.to<=l)m-=k.len;else if(k.from>=l)break;else if(e.isInBreak(k,l)){m-=l-k.from;break}}return m};e.prototype.findBreakAt=function(e,l){return H(l,function(l){return l.from<e&&e<l.to})};e.prototype.isInAnyBreak=function(l,q){var m=this.axis,u=m.options.breaks,k=u&&u.length,g;if(k){for(;k--;)if(e.isInBreak(u[k],l)){var b=!0;g||(g=C(u[k].showPoints,!m.isXAxis))}var f=b&&q?b&&!g:b}return f};
e.prototype.setBreaks=function(t,q){var m=this,u=m.axis,k=K(t)&&!!t.length;u.isDirty=m.hasBreaks!==k;m.hasBreaks=k;u.options.breaks=u.userOptions.breaks=t;u.forceRedraw=!0;u.series.forEach(function(g){g.isDirty=!0});k||u.val2lin!==e.val2Lin||(delete u.val2lin,delete u.lin2val);k&&(u.userOptions.ordinal=!1,u.lin2val=e.lin2Val,u.val2lin=e.val2Lin,u.setExtremes=function(g,b,f,a,c){if(m.hasBreaks){for(var e,k=this.options.breaks;e=m.findBreakAt(g,k);)g=e.to;for(;e=m.findBreakAt(b,k);)b=e.from;b<g&&(b=
g)}l.prototype.setExtremes.call(this,g,b,f,a,c)},u.setAxisTranslation=function(g){l.prototype.setAxisTranslation.call(this,g);m.unitLength=null;if(m.hasBreaks){g=u.options.breaks||[];var b=[],f=[],a=0,c,k=u.userMin||u.min,p=u.userMax||u.max,q=C(u.pointRangePadding,0),w;g.forEach(function(a){c=a.repeat||Infinity;e.isInBreak(a,k)&&(k+=a.to%c-k%c);e.isInBreak(a,p)&&(p-=p%c-a.from%c)});g.forEach(function(a){n=a.from;for(c=a.repeat||Infinity;n-c>k;)n-=c;for(;n<k;)n+=c;for(w=n;w<p;w+=c)b.push({value:w,
move:"in"}),b.push({value:w+(a.to-a.from),move:"out",size:a.breakSize})});b.sort(function(a,b){return a.value===b.value?("in"===a.move?0:1)-("in"===b.move?0:1):a.value-b.value});var v=0;var n=k;b.forEach(function(b){v+="in"===b.move?1:-1;1===v&&"in"===b.move&&(n=b.value);0===v&&(f.push({from:n,to:b.value,len:b.value-n-(b.size||0)}),a+=b.value-n-(b.size||0))});u.breakArray=m.breakArray=f;m.unitLength=p-k-a+q;L(u,"afterBreaks");u.staticScale?u.transA=u.staticScale:m.unitLength&&(u.transA*=(p-u.min+
q)/m.unitLength);q&&(u.minPixelPadding=u.transA*u.minPointOffset);u.min=k;u.max=p}});C(q,!0)&&u.chart.redraw()};return e}();e=function(){function e(){}e.compose=function(e,l){e.keepProps.push("brokenAxis");var m=J.prototype;m.drawBreaks=function(e,k){var g=this,b=g.points,f,a,c,l;if(e&&e.brokenAxis&&e.brokenAxis.hasBreaks){var m=e.brokenAxis;k.forEach(function(k){f=m&&m.breakArray||[];a=e.isXAxis?e.min:C(g.options.threshold,e.min);b.forEach(function(b){l=C(b["stack"+k.toUpperCase()],b[k]);f.forEach(function(f){if(E(a)&&
E(l)){c=!1;if(a<f.from&&l>f.to||a>f.from&&l<f.from)c="pointBreak";else if(a<f.from&&l>f.from&&l<f.to||a>f.from&&l>f.to&&l<f.from)c="pointInBreak";c&&L(e,c,{point:b,brk:f})}})})})}};m.gappedPath=function(){var e=this.currentDataGrouping,k=e&&e.gapSize;e=this.options.gapSize;var g=this.points.slice(),b=g.length-1,f=this.yAxis,a;if(e&&0<b)for("value"!==this.options.gapUnit&&(e*=this.basePointRange),k&&k>e&&k>=this.basePointRange&&(e=k),a=void 0;b--;)a&&!1!==a.visible||(a=g[b+1]),k=g[b],!1!==a.visible&&
!1!==k.visible&&(a.x-k.x>e&&(a=(k.x+a.x)/2,g.splice(b+1,0,{isNull:!0,x:a}),f.stacking&&this.options.stacking&&(a=f.stacking.stacks[this.stackKey][a]=new t(f,f.options.stackLabels,!1,a,this.stack),a.total=0)),a=k);return this.getGraphPath(g)};B(e,"init",function(){this.brokenAxis||(this.brokenAxis=new y(this))});B(e,"afterInit",function(){"undefined"!==typeof this.brokenAxis&&this.brokenAxis.setBreaks(this.options.breaks,!1)});B(e,"afterSetTickPositions",function(){var e=this.brokenAxis;if(e&&e.hasBreaks){var k=
this.tickPositions,g=this.tickPositions.info,b=[],f;for(f=0;f<k.length;f++)e.isInAnyBreak(k[f])||b.push(k[f]);this.tickPositions=b;this.tickPositions.info=g}});B(e,"afterSetOptions",function(){this.brokenAxis&&this.brokenAxis.hasBreaks&&(this.options.ordinal=!1)});B(l,"afterGeneratePoints",function(){var e=this.options.connectNulls,k=this.points,g=this.xAxis,b=this.yAxis;if(this.isDirty)for(var f=k.length;f--;){var a=k[f],c=!(null===a.y&&!1===e)&&(g&&g.brokenAxis&&g.brokenAxis.isInAnyBreak(a.x,!0)||
b&&b.brokenAxis&&b.brokenAxis.isInAnyBreak(a.y,!0));a.visible=c?!1:!1!==a.options.visible}});B(l,"afterRender",function(){this.drawBreaks(this.xAxis,["x"]);this.drawBreaks(this.yAxis,C(this.pointArrayMap,["y"]))})};return e}();e.compose(l,J);return e});P(x,"parts-gantt/TreeGridAxis.js",[x["parts/Axis.js"],x["parts/Tick.js"],x["parts-gantt/Tree.js"],x["parts-gantt/TreeGridTick.js"],x["mixins/tree-series.js"],x["parts/Utilities.js"]],function(l,e,x,t,N,H){var B=H.addEvent,K=H.find,E=H.fireEvent,C=H.isNumber,
J=H.isObject,y=H.isString,A=H.merge,z=H.pick,q=H.wrap,m;(function(l){function k(a,b){var c=a.collapseStart||0;a=a.collapseEnd||0;a>=b&&(c-=.5);return{from:c,to:a,showPoints:!1}}function g(a,b,c){var f=[],g=[],e={},h={},d=-1,k="boolean"===typeof b?b:!1;a=x.getTree(a,{after:function(a){a=h[a.pos];var b=0,d=0;a.children.forEach(function(a){d+=(a.descendants||0)+1;b=Math.max((a.height||0)+1,b)});a.descendants=d;a.height=b;a.collapsed&&g.push(a)},before:function(a){var b=J(a.data,!0)?a.data:{},c=y(b.name)?
b.name:"",g=e[a.parent];g=J(g,!0)?h[g.pos]:null;var l=function(a){return a.name===c},n;k&&J(g,!0)&&(n=K(g.children,l))?(l=n.pos,n.nodes.push(a)):l=d++;h[l]||(h[l]=n={depth:g?g.depth+1:0,name:c,nodes:[a],children:[],pos:l},-1!==l&&f.push(c),J(g,!0)&&g.children.push(n));y(a.id)&&(e[a.id]=a);n&&!0===b.collapsed&&(n.collapsed=!0);a.pos=l}});h=function(a,b){var d=function(a,c,h){var f=c+(-1===c?0:b-1),g=(f-c)/2,e=c+g;a.nodes.forEach(function(a){var b=a.data;J(b,!0)&&(b.y=c+(b.seriesIndex||0),delete b.seriesIndex);
a.pos=e});h[e]=a;a.pos=e;a.tickmarkOffset=g+.5;a.collapseStart=f+.5;a.children.forEach(function(a){d(a,f+1,h);f=(a.collapseEnd||0)-.5});a.collapseEnd=f+.5;return h};return d(a["-1"],-1,{})}(h,c);return{categories:f,mapOfIdToNode:e,mapOfPosToGridNode:h,collapsedNodes:g,tree:a}}function b(a){a.target.axes.filter(function(a){return"treegrid"===a.options.type}).forEach(function(b){var c=b.options||{},f=c.labels,e=c.uniqueNames,k=0;if(!b.treeGrid.mapOfPosToGridNode||b.series.some(function(a){return!a.hasRendered||
a.isDirtyData||a.isDirty}))c=b.series.reduce(function(a,b){b.visible&&((b.options.data||[]).forEach(function(b){J(b,!0)&&(b.seriesIndex=k,a.push(b))}),!0===e&&k++);return a},[]),c=g(c,e||!1,!0===e?k:1),b.categories=c.categories,b.treeGrid.mapOfPosToGridNode=c.mapOfPosToGridNode,b.hasNames=!0,b.treeGrid.tree=c.tree,b.series.forEach(function(a){var b=(a.options.data||[]).map(function(a){return J(a,!0)?A(a):a});a.visible&&a.setData(b,!1)}),b.treeGrid.mapOptionsToLevel=N.getLevelOptions({defaults:f,from:1,
levels:f&&f.levels,to:b.treeGrid.tree&&b.treeGrid.tree.height}),"beforeRender"===a.type&&(b.treeGrid.collapsedNodes=c.collapsedNodes)})}function f(a,b){var c=this.treeGrid.mapOptionsToLevel||{},f=this.ticks,g=f[b],k;if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var h=this.treeGrid.mapOfPosToGridNode[b];(c=c[h.depth])&&(k={labels:c});g?(g.parameters.category=h.name,g.options=k,g.addLabel()):f[b]=new e(this,b,void 0,void 0,{category:h.name,tickmarkOffset:h.tickmarkOffset,options:k})}else a.apply(this,
Array.prototype.slice.call(arguments,1))}function a(a){var b=this.options;b=(b=b&&b.labels)&&C(b.indentation)?b.indentation:0;var c=a.apply(this,Array.prototype.slice.call(arguments,1));if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var f=this.treeGrid.mapOfPosToGridNode[-1].height||0;c.width+=b*(f-1)}return c}function c(a,c,f){var e=this,k="treegrid"===f.type;e.treeGrid||(e.treeGrid=new u(e));k&&(B(c,"beforeRender",b),B(c,"beforeRedraw",b),B(c,"addSeries",function(a){a.options.data&&
(a=g(a.options.data,f.uniqueNames||!1,1),e.treeGrid.collapsedNodes=(e.treeGrid.collapsedNodes||[]).concat(a.collapsedNodes))}),B(e,"foundExtremes",function(){e.treeGrid.collapsedNodes&&e.treeGrid.collapsedNodes.forEach(function(a){var b=e.treeGrid.collapse(a);e.brokenAxis&&(e.brokenAxis.setBreaks(b,!1),e.treeGrid.collapsedNodes&&(e.treeGrid.collapsedNodes=e.treeGrid.collapsedNodes.filter(function(b){return a.collapseStart!==b.collapseStart||a.collapseEnd!==b.collapseEnd})))})}),f=A({grid:{enabled:!0},
labels:{align:"left",levels:[{level:void 0},{level:1,style:{fontWeight:"bold"}}],symbol:{type:"triangle",x:-5,y:-5,height:10,width:10,padding:5}},uniqueNames:!1},f,{reversed:!0,grid:{columns:void 0}}));a.apply(e,[c,f]);k&&(e.hasNames=!0,e.options.showLastLabel=!0)}function m(a){var b=this.options;"treegrid"===b.type?(this.min=z(this.userMin,b.min,this.dataMin),this.max=z(this.userMax,b.max,this.dataMax),E(this,"foundExtremes"),this.setAxisTranslation(!0),this.tickmarkOffset=.5,this.tickInterval=1,
this.tickPositions=this.treeGrid.mapOfPosToGridNode?this.treeGrid.getTickPositions():[]):a.apply(this,Array.prototype.slice.call(arguments,1))}var p=!1;l.compose=function(b){p||(q(b.prototype,"generateTick",f),q(b.prototype,"getMaxLabelDimensions",a),q(b.prototype,"init",c),q(b.prototype,"setTickInterval",m),t.compose(e),p=!0)};var u=function(){function a(a){this.axis=a}a.prototype.collapse=function(a){var b=this.axis,c=b.options.breaks||[];a=k(a,b.max);c.push(a);return c};a.prototype.expand=function(a){var b=
this.axis,c=b.options.breaks||[],f=k(a,b.max);return c.reduce(function(a,b){b.to===f.to&&b.from===f.from||a.push(b);return a},[])};a.prototype.getTickPositions=function(){var a=this.axis;return Object.keys(a.treeGrid.mapOfPosToGridNode||{}).reduce(function(b,c){c=+c;!(a.min<=c&&a.max>=c)||a.brokenAxis&&a.brokenAxis.isInAnyBreak(c)||b.push(c);return b},[])};a.prototype.isCollapsed=function(a){var b=this.axis,c=b.options.breaks||[],f=k(a,b.max);return c.some(function(a){return a.from===f.from&&a.to===
f.to})};a.prototype.toggleCollapse=function(a){return this.isCollapsed(a)?this.expand(a):this.collapse(a)};return a}();l.Additions=u})(m||(m={}));l.prototype.utils={getNode:x.getNode};m.compose(l);return m});P(x,"parts-gantt/PathfinderAlgorithms.js",[x["parts/Utilities.js"]],function(l){function e(e,l,t){t=t||0;var y=e.length-1;l-=1e-7;for(var q,m;t<=y;)if(q=y+t>>1,m=l-e[q].xMin,0<m)t=q+1;else if(0>m)y=q-1;else return q;return 0<t?t-1:0}function x(l,t){for(var y=e(l,t.x+1)+1;y--;){var z;if(z=l[y].xMax>=
t.x)z=l[y],z=t.x<=z.xMax&&t.x>=z.xMin&&t.y<=z.yMax&&t.y>=z.yMin;if(z)return y}return-1}function t(e){var l=[];if(e.length){l.push(["M",e[0].start.x,e[0].start.y]);for(var t=0;t<e.length;++t)l.push(["L",e[t].end.x,e[t].end.y])}return l}function N(e,l){e.yMin=E(e.yMin,l.yMin);e.yMax=K(e.yMax,l.yMax);e.xMin=E(e.xMin,l.xMin);e.xMax=K(e.xMax,l.xMax)}var H=l.extend,L=l.pick,K=Math.min,E=Math.max,C=Math.abs;return{straight:function(e,l){return{path:[["M",e.x,e.y],["L",l.x,l.y]],obstacles:[{start:e,end:l}]}},
simpleConnect:H(function(e,l,A){function y(a,b,f,g,e){a={x:a.x,y:a.y};a[b]=f[g||b]+(e||0);return a}function q(a,b,f){var c=C(b[f]-a[f+"Min"])>C(b[f]-a[f+"Max"]);return y(b,f,a,f+(c?"Max":"Min"),c?1:-1)}var m=[],u=L(A.startDirectionX,C(l.x-e.x)>C(l.y-e.y))?"x":"y",k=A.chartObstacles,g=x(k,e);A=x(k,l);if(-1<A){var b=k[A];A=q(b,l,u);b={start:A,end:l};var f=A}else f=l;-1<g&&(k=k[g],A=q(k,e,u),m.push({start:e,end:A}),A[u]>=e[u]===A[u]>=f[u]&&(u="y"===u?"x":"y",l=e[u]<l[u],m.push({start:A,end:y(A,u,k,u+
(l?"Max":"Min"),l?1:-1)}),u="y"===u?"x":"y"));e=m.length?m[m.length-1].end:e;A=y(e,u,f);m.push({start:e,end:A});u=y(A,"y"===u?"x":"y",f);m.push({start:A,end:u});m.push(b);return{path:t(m),obstacles:m}},{requiresObstacles:!0}),fastAvoid:H(function(l,y,A){function z(a,b,c){var f,d=a.x<b.x?1:-1;if(a.x<b.x){var g=a;var k=b}else g=b,k=a;if(a.y<b.y){var l=a;var n=b}else l=b,n=a;for(f=0>d?K(e(w,k.x),w.length-1):0;w[f]&&(0<d&&w[f].xMin<=k.x||0>d&&w[f].xMax>=g.x);){if(w[f].xMin<=k.x&&w[f].xMax>=g.x&&w[f].yMin<=
n.y&&w[f].yMax>=l.y)return c?{y:a.y,x:a.x<b.x?w[f].xMin-1:w[f].xMax+1,obstacle:w[f]}:{x:a.x,y:a.y<b.y?w[f].yMin-1:w[f].yMax+1,obstacle:w[f]};f+=d}return b}function q(a,b,c,f,d){var h=d.soft,g=d.hard,e=f?"x":"y",k={x:b.x,y:b.y},l={x:b.x,y:b.y};d=a[e+"Max"]>=h[e+"Max"];h=a[e+"Min"]<=h[e+"Min"];var n=a[e+"Max"]>=g[e+"Max"];g=a[e+"Min"]<=g[e+"Min"];var m=C(a[e+"Min"]-b[e]),p=C(a[e+"Max"]-b[e]);c=10>C(m-p)?b[e]<c[e]:p<m;l[e]=a[e+"Min"];k[e]=a[e+"Max"];a=z(b,l,f)[e]!==l[e];b=z(b,k,f)[e]!==k[e];c=a?b?c:
!0:b?!1:c;c=h?d?c:!0:d?!1:c;return g?n?c:!0:n?!1:c}function m(a,b,e){if(a.x===b.x&&a.y===b.y)return[];var h=e?"x":"y",d=A.obstacleOptions.margin;var g={soft:{xMin:c,xMax:r,yMin:p,yMax:I},hard:A.hardBounds};var k=x(w,a);if(-1<k){k=w[k];g=q(k,a,b,e,g);N(k,A.hardBounds);var l=e?{y:a.y,x:k[g?"xMax":"xMin"]+(g?1:-1)}:{x:a.x,y:k[g?"yMax":"yMin"]+(g?1:-1)};var n=x(w,l);-1<n&&(n=w[n],N(n,A.hardBounds),l[h]=g?E(k[h+"Max"]-d+1,(n[h+"Min"]+k[h+"Max"])/2):K(k[h+"Min"]+d-1,(n[h+"Max"]+k[h+"Min"])/2),a.x===l.x&&
a.y===l.y?(f&&(l[h]=g?E(k[h+"Max"],n[h+"Max"])+1:K(k[h+"Min"],n[h+"Min"])-1),f=!f):f=!1);a=[{start:a,end:l}]}else h=z(a,{x:e?b.x:a.x,y:e?a.y:b.y},e),a=[{start:a,end:{x:h.x,y:h.y}}],h[e?"x":"y"]!==b[e?"x":"y"]&&(g=q(h.obstacle,h,b,!e,g),N(h.obstacle,A.hardBounds),g={x:e?h.x:h.obstacle[g?"xMax":"xMin"]+(g?1:-1),y:e?h.obstacle[g?"yMax":"yMin"]+(g?1:-1):h.y},e=!e,a=a.concat(m({x:h.x,y:h.y},g,e)));return a=a.concat(m(a[a.length-1].end,b,!e))}function u(a,b,c){var f=K(a.xMax-b.x,b.x-a.xMin)<K(a.yMax-b.y,
b.y-a.yMin);c=q(a,b,c,f,{soft:A.hardBounds,hard:A.hardBounds});return f?{y:b.y,x:a[c?"xMax":"xMin"]+(c?1:-1)}:{x:b.x,y:a[c?"yMax":"yMin"]+(c?1:-1)}}var k=L(A.startDirectionX,C(y.x-l.x)>C(y.y-l.y)),g=k?"x":"y",b=[],f=!1,a=A.obstacleMetrics,c=K(l.x,y.x)-a.maxWidth-10,r=E(l.x,y.x)+a.maxWidth+10,p=K(l.y,y.y)-a.maxHeight-10,I=E(l.y,y.y)+a.maxHeight+10,w=A.chartObstacles;var v=e(w,c);a=e(w,r);w=w.slice(v,a+1);if(-1<(a=x(w,y))){var n=u(w[a],y,l);b.push({end:y,start:n});y=n}for(;-1<(a=x(w,y));)v=0>y[g]-l[g],
n={x:y.x,y:y.y},n[g]=w[a][v?g+"Max":g+"Min"]+(v?1:-1),b.push({end:y,start:n}),y=n;l=m(l,y,k);l=l.concat(b.reverse());return{path:t(l),obstacles:l}},{requiresObstacles:!0})}});P(x,"parts-gantt/ArrowSymbols.js",[x["parts/Globals.js"]],function(l){l.SVGRenderer.prototype.symbols.arrow=function(e,l,t,x){return[["M",e,l+x/2],["L",e+t,l],["L",e,l+x/2],["L",e+t,l+x]]};l.SVGRenderer.prototype.symbols["arrow-half"]=function(e,x,t,N){return l.SVGRenderer.prototype.symbols.arrow(e,x,t/2,N)};l.SVGRenderer.prototype.symbols["triangle-left"]=
function(e,l,t,x){return[["M",e+t,l],["L",e,l+x/2],["L",e+t,l+x],["Z"]]};l.SVGRenderer.prototype.symbols["arrow-filled"]=l.SVGRenderer.prototype.symbols["triangle-left"];l.SVGRenderer.prototype.symbols["triangle-left-half"]=function(e,x,t,N){return l.SVGRenderer.prototype.symbols["triangle-left"](e,x,t/2,N)};l.SVGRenderer.prototype.symbols["arrow-filled-half"]=l.SVGRenderer.prototype.symbols["triangle-left-half"]});P(x,"parts-gantt/Pathfinder.js",[x["parts/Globals.js"],x["parts/Point.js"],x["parts/Utilities.js"],
x["parts-gantt/PathfinderAlgorithms.js"]],function(l,e,x,t){function B(b){var a=b.shapeArgs;return a?{xMin:a.x,xMax:a.x+a.width,yMin:a.y,yMax:a.y+a.height}:(a=b.graphic&&b.graphic.getBBox())?{xMin:b.plotX-a.width/2,xMax:b.plotX+a.width/2,yMin:b.plotY-a.height/2,yMax:b.plotY+a.height/2}:null}function H(f){for(var a=f.length,c=0,e,k,l=[],q=function(a,c,f){f=m(f,10);var e=a.yMax+f>c.yMin-f&&a.yMin-f<c.yMax+f,g=a.xMax+f>c.xMin-f&&a.xMin-f<c.xMax+f,h=e?a.xMin>c.xMax?a.xMin-c.xMax:c.xMin-a.xMax:Infinity,
d=g?a.yMin>c.yMax?a.yMin-c.yMax:c.yMin-a.yMax:Infinity;return g&&e?f?q(a,c,Math.floor(f/2)):Infinity:b(h,d)};c<a;++c)for(e=c+1;e<a;++e)k=q(f[c],f[e]),80>k&&l.push(k);l.push(80);return g(Math.floor(l.sort(function(a,b){return a-b})[Math.floor(l.length/10)]/2-1),1)}function L(b,a,c){this.init(b,a,c)}function K(b){this.init(b)}function E(b){if(b.options.pathfinder||b.series.reduce(function(a,b){b.options&&z(!0,b.options.connectors=b.options.connectors||{},b.options.pathfinder);return a||b.options&&b.options.pathfinder},
!1))z(!0,b.options.connectors=b.options.connectors||{},b.options.pathfinder),y('WARNING: Pathfinder options have been renamed. Use "chart.connectors" or "series.connectors" instead.')}"";var C=x.addEvent,J=x.defined,y=x.error,A=x.extend,z=x.merge,q=x.objectEach,m=x.pick,u=x.splat,k=l.deg2rad,g=Math.max,b=Math.min;A(l.defaultOptions,{connectors:{type:"straight",lineWidth:1,marker:{enabled:!1,align:"center",verticalAlign:"middle",inside:!1,lineWidth:1},startMarker:{symbol:"diamond"},endMarker:{symbol:"arrow-filled"}}});
L.prototype={init:function(b,a,c){this.fromPoint=b;this.toPoint=a;this.options=c;this.chart=b.series.chart;this.pathfinder=this.chart.pathfinder},renderPath:function(b,a,c){var f=this.chart,e=f.styledMode,g=f.pathfinder,k=!f.options.chart.forExport&&!1!==c,l=this.graphics&&this.graphics.path;g.group||(g.group=f.renderer.g().addClass("highcharts-pathfinder-group").attr({zIndex:-1}).add(f.seriesGroup));g.group.translate(f.plotLeft,f.plotTop);l&&l.renderer||(l=f.renderer.path().add(g.group),e||l.attr({opacity:0}));
l.attr(a);b={d:b};e||(b.opacity=1);l[k?"animate":"attr"](b,c);this.graphics=this.graphics||{};this.graphics.path=l},addMarker:function(b,a,c){var f=this.fromPoint.series.chart,e=f.pathfinder;f=f.renderer;var g="start"===b?this.fromPoint:this.toPoint,l=g.getPathfinderAnchorPoint(a);if(a.enabled&&((c="start"===b?c[1]:c[c.length-2])&&"M"===c[0]||"L"===c[0])){c={x:c[1],y:c[2]};c=g.getRadiansToVector(c,l);l=g.getMarkerVector(c,a.radius,l);c=-c/k;if(a.width&&a.height){var m=a.width;var n=a.height}else m=
n=2*a.radius;this.graphics=this.graphics||{};l={x:l.x-m/2,y:l.y-n/2,width:m,height:n,rotation:c,rotationOriginX:l.x,rotationOriginY:l.y};this.graphics[b]?this.graphics[b].animate(l):(this.graphics[b]=f.symbol(a.symbol).addClass("highcharts-point-connecting-path-"+b+"-marker").attr(l).add(e.group),f.styledMode||this.graphics[b].attr({fill:a.color||this.fromPoint.color,stroke:a.lineColor,"stroke-width":a.lineWidth,opacity:0}).animate({opacity:1},g.series.options.animation))}},getPath:function(b){var a=
this.pathfinder,c=this.chart,f=a.algorithms[b.type],e=a.chartObstacles;if("function"!==typeof f)y('"'+b.type+'" is not a Pathfinder algorithm.');else return f.requiresObstacles&&!e&&(e=a.chartObstacles=a.getChartObstacles(b),c.options.connectors.algorithmMargin=b.algorithmMargin,a.chartObstacleMetrics=a.getObstacleMetrics(e)),f(this.fromPoint.getPathfinderAnchorPoint(b.startMarker),this.toPoint.getPathfinderAnchorPoint(b.endMarker),z({chartObstacles:e,lineObstacles:a.lineObstacles||[],obstacleMetrics:a.chartObstacleMetrics,
hardBounds:{xMin:0,xMax:c.plotWidth,yMin:0,yMax:c.plotHeight},obstacleOptions:{margin:b.algorithmMargin},startDirectionX:a.getAlgorithmStartDirection(b.startMarker)},b))},render:function(){var f=this.fromPoint,a=f.series,c=a.chart,e=c.pathfinder,k=z(c.options.connectors,a.options.connectors,f.options.connectors,this.options),l={};c.styledMode||(l.stroke=k.lineColor||f.color,l["stroke-width"]=k.lineWidth,k.dashStyle&&(l.dashstyle=k.dashStyle));l["class"]="highcharts-point-connecting-path highcharts-color-"+
f.colorIndex;k=z(l,k);J(k.marker.radius)||(k.marker.radius=b(g(Math.ceil((k.algorithmMargin||8)/2)-1,1),5));f=this.getPath(k);c=f.path;f.obstacles&&(e.lineObstacles=e.lineObstacles||[],e.lineObstacles=e.lineObstacles.concat(f.obstacles));this.renderPath(c,l,a.options.animation);this.addMarker("start",z(k.marker,k.startMarker),c);this.addMarker("end",z(k.marker,k.endMarker),c)},destroy:function(){this.graphics&&(q(this.graphics,function(b){b.destroy()}),delete this.graphics)}};K.prototype={algorithms:t,
init:function(b){this.chart=b;this.connections=[];C(b,"redraw",function(){this.pathfinder.update()})},update:function(b){var a=this.chart,c=this,f=c.connections;c.connections=[];a.series.forEach(function(b){b.visible&&!b.options.isInternal&&b.points.forEach(function(b){var f,h=b.options&&b.options.connect&&u(b.options.connect);b.visible&&!1!==b.isInside&&h&&h.forEach(function(d){f=a.get("string"===typeof d?d:d.to);f instanceof e&&f.series.visible&&f.visible&&!1!==f.isInside&&c.connections.push(new L(b,
f,"string"===typeof d?{}:d))})})});for(var g=0,k,l,m=f.length,n=c.connections.length;g<m;++g){l=!1;for(k=0;k<n;++k)if(f[g].fromPoint===c.connections[k].fromPoint&&f[g].toPoint===c.connections[k].toPoint){c.connections[k].graphics=f[g].graphics;l=!0;break}l||f[g].destroy()}delete this.chartObstacles;delete this.lineObstacles;c.renderConnections(b)},renderConnections:function(b){b?this.chart.series.forEach(function(a){var b=function(){var b=a.chart.pathfinder;(b&&b.connections||[]).forEach(function(b){b.fromPoint&&
b.fromPoint.series===a&&b.render()});a.pathfinderRemoveRenderEvent&&(a.pathfinderRemoveRenderEvent(),delete a.pathfinderRemoveRenderEvent)};!1===a.options.animation?b():a.pathfinderRemoveRenderEvent=C(a,"afterAnimate",b)}):this.connections.forEach(function(a){a.render()})},getChartObstacles:function(b){for(var a=[],c=this.chart.series,f=m(b.algorithmMargin,0),e,g=0,k=c.length;g<k;++g)if(c[g].visible&&!c[g].options.isInternal)for(var l=0,n=c[g].points.length,q;l<n;++l)q=c[g].points[l],q.visible&&(q=
B(q))&&a.push({xMin:q.xMin-f,xMax:q.xMax+f,yMin:q.yMin-f,yMax:q.yMax+f});a=a.sort(function(a,b){return a.xMin-b.xMin});J(b.algorithmMargin)||(e=b.algorithmMargin=H(a),a.forEach(function(a){a.xMin-=e;a.xMax+=e;a.yMin-=e;a.yMax+=e}));return a},getObstacleMetrics:function(b){for(var a=0,c=0,f,e,g=b.length;g--;)f=b[g].xMax-b[g].xMin,e=b[g].yMax-b[g].yMin,a<f&&(a=f),c<e&&(c=e);return{maxHeight:c,maxWidth:a}},getAlgorithmStartDirection:function(b){var a="top"!==b.verticalAlign&&"bottom"!==b.verticalAlign;
return"left"!==b.align&&"right"!==b.align?a?void 0:!1:a?!0:void 0}};l.Connection=L;l.Pathfinder=K;A(e.prototype,{getPathfinderAnchorPoint:function(b){var a=B(this);switch(b.align){case "right":var c="xMax";break;case "left":c="xMin"}switch(b.verticalAlign){case "top":var f="yMin";break;case "bottom":f="yMax"}return{x:c?a[c]:(a.xMin+a.xMax)/2,y:f?a[f]:(a.yMin+a.yMax)/2}},getRadiansToVector:function(b,a){var c;J(a)||(c=B(this))&&(a={x:(c.xMin+c.xMax)/2,y:(c.yMin+c.yMax)/2});return Math.atan2(a.y-b.y,
b.x-a.x)},getMarkerVector:function(b,a,c){var f=2*Math.PI,e=B(this),g=e.xMax-e.xMin,k=e.yMax-e.yMin,l=Math.atan2(k,g),n=!1;g/=2;var m=k/2,q=e.xMin+g;e=e.yMin+m;for(var u=q,h=e,d={},t=1,y=1;b<-Math.PI;)b+=f;for(;b>Math.PI;)b-=f;f=Math.tan(b);b>-l&&b<=l?(y=-1,n=!0):b>l&&b<=Math.PI-l?y=-1:b>Math.PI-l||b<=-(Math.PI-l)?(t=-1,n=!0):t=-1;n?(u+=t*g,h+=y*g*f):(u+=k/(2*f)*t,h+=y*m);c.x!==q&&(u=c.x);c.y!==e&&(h=c.y);d.x=u+a*Math.cos(b);d.y=h-a*Math.sin(b);return d}});l.Chart.prototype.callbacks.push(function(b){!1!==
b.options.connectors.enabled&&(E(b),this.pathfinder=new K(this),this.pathfinder.update(!0))})});P(x,"modules/xrange.src.js",[x["parts/Globals.js"],x["parts/Color.js"],x["parts/Point.js"],x["parts/Utilities.js"]],function(l,e,x,t){var B=e.parse;e=t.addEvent;var H=t.clamp,L=t.correctFloat,K=t.defined,E=t.find,C=t.isNumber,J=t.isObject,y=t.merge,A=t.pick;t=t.seriesType;var z=l.seriesTypes.column,q=l.seriesTypes,m=l.Axis,u=l.Series;t("xrange","column",{colorByPoint:!0,dataLabels:{formatter:function(){var e=
this.point.partialFill;J(e)&&(e=e.amount);if(C(e)&&0<e)return L(100*e)+"%"},inside:!0,verticalAlign:"middle"},tooltip:{headerFormat:'<span style="font-size: 10px">{point.x} - {point.x2}</span><br/>',pointFormat:'<span style="color:{point.color}">\u25cf</span> {series.name}: <b>{point.yCategory}</b><br/>'},borderRadius:3,pointRange:0},{type:"xrange",parallelArrays:["x","x2","y"],requireSorting:!1,animate:q.line.prototype.animate,cropShoulder:1,getExtremesFromAll:!0,autoIncrement:l.noop,buildKDTree:l.noop,
init:function(){q.column.prototype.init.apply(this,arguments);this.options.stacking=void 0},getColumnMetrics:function(){function e(){g.series.forEach(function(b){var a=b.xAxis;b.xAxis=b.yAxis;b.yAxis=a})}var g=this.chart;e();var b=z.prototype.getColumnMetrics.call(this);e();return b},cropData:function(e,g,b,f){g=u.prototype.cropData.call(this,this.x2Data,g,b,f);g.xData=e.slice(g.start,g.end);return g},findPointIndex:function(e){var g=this.cropped,b=this.cropStart,f=this.points,a=e.id;if(a)var c=(c=
E(f,function(b){return b.id===a}))?c.index:void 0;"undefined"===typeof c&&(c=(c=E(f,function(a){return a.x===e.x&&a.x2===e.x2&&!a.touched}))?c.index:void 0);g&&C(c)&&C(b)&&c>=b&&(c-=b);return c},translatePoint:function(e){var g=this.xAxis,b=this.yAxis,f=this.columnMetrics,a=this.options,c=a.minPointLength||0,k=e.plotX,l=A(e.x2,e.x+(e.len||0)),m=g.translate(l,0,0,0,1);l=Math.abs(m-k);var q=this.chart.inverted,u=A(a.borderWidth,1)%2/2,n=f.offset,t=Math.round(f.width);c&&(c-=l,0>c&&(c=0),k-=c/2,m+=c/
2);k=Math.max(k,-10);m=H(m,-10,g.len+10);K(e.options.pointWidth)&&(n-=(Math.ceil(e.options.pointWidth)-t)/2,t=Math.ceil(e.options.pointWidth));a.pointPlacement&&C(e.plotY)&&b.categories&&(e.plotY=b.translate(e.y,0,1,0,1,a.pointPlacement));e.shapeArgs={x:Math.floor(Math.min(k,m))+u,y:Math.floor(e.plotY+n)+u,width:Math.round(Math.abs(m-k)),height:t,r:this.options.borderRadius};a=e.shapeArgs.x;c=a+e.shapeArgs.width;0>a||c>g.len?(a=H(a,0,g.len),c=H(c,0,g.len),m=c-a,e.dlBox=y(e.shapeArgs,{x:a,width:c-
a,centerX:m?m/2:null})):e.dlBox=null;a=e.tooltipPos;c=q?1:0;m=q?0:1;f=this.columnMetrics?this.columnMetrics.offset:-f.width/2;a[c]=H(a[c]+l/2*(g.reversed?-1:1)*(q?-1:1),0,g.len-1);a[m]=H(a[m]+(q?-1:1)*f,0,b.len-1);if(f=e.partialFill)J(f)&&(f=f.amount),C(f)||(f=0),b=e.shapeArgs,e.partShapeArgs={x:b.x,y:b.y,width:b.width,height:b.height,r:this.options.borderRadius},k=Math.max(Math.round(l*f+e.plotX-k),0),e.clipRectArgs={x:g.reversed?b.x+l-k:b.x,y:b.y,width:k,height:b.height}},translate:function(){z.prototype.translate.apply(this,
arguments);this.points.forEach(function(e){this.translatePoint(e)},this)},drawPoint:function(e,g){var b=this.options,f=this.chart.renderer,a=e.graphic,c=e.shapeType,k=e.shapeArgs,l=e.partShapeArgs,m=e.clipRectArgs,q=e.partialFill,u=b.stacking&&!b.borderRadius,n=e.state,t=b.states[n||"normal"]||{},x="undefined"===typeof n?"attr":g;n=this.pointAttribs(e,n);t=A(this.chart.options.chart.animation,t.animation);if(e.isNull||!1===e.visible)a&&(e.graphic=a.destroy());else{if(a)a.rect[g](k);else e.graphic=
a=f.g("point").addClass(e.getClassName()).add(e.group||this.group),a.rect=f[c](y(k)).addClass(e.getClassName()).addClass("highcharts-partfill-original").add(a);l&&(a.partRect?(a.partRect[g](y(l)),a.partialClipRect[g](y(m))):(a.partialClipRect=f.clipRect(m.x,m.y,m.width,m.height),a.partRect=f[c](l).addClass("highcharts-partfill-overlay").add(a).clip(a.partialClipRect)));this.chart.styledMode||(a.rect[g](n,t).shadow(b.shadow,null,u),l&&(J(q)||(q={}),J(b.partialFill)&&(q=y(q,b.partialFill)),e=q.fill||
B(n.fill).brighten(-.3).get()||B(e.color||this.color).brighten(-.3).get(),n.fill=e,a.partRect[x](n,t).shadow(b.shadow,null,u)))}},drawPoints:function(){var e=this,g=e.getAnimationVerb();e.points.forEach(function(b){e.drawPoint(b,g)})},getAnimationVerb:function(){return this.chart.pointCount<(this.options.animationLimit||250)?"animate":"attr"}},{resolveColor:function(){var e=this.series;if(e.options.colorByPoint&&!this.options.color){var g=e.options.colors||e.chart.options.colors;var b=this.y%(g?g.length:
e.chart.options.chart.colorCount);g=g&&g[b];e.chart.styledMode||(this.color=g);this.options.colorIndex||(this.colorIndex=b)}else this.color||(this.color=e.color)},init:function(){x.prototype.init.apply(this,arguments);this.y||(this.y=0);return this},setState:function(){x.prototype.setState.apply(this,arguments);this.series.drawPoint(this,this.series.getAnimationVerb())},getLabelConfig:function(){var e=x.prototype.getLabelConfig.call(this),g=this.series.yAxis.categories;e.x2=this.x2;e.yCategory=this.yCategory=
g&&g[this.y];return e},tooltipDateKeys:["x","x2"],isValid:function(){return"number"===typeof this.x&&"number"===typeof this.x2}});e(m,"afterGetSeriesExtremes",function(){var e=this.series,g;if(this.isXAxis){var b=A(this.dataMax,-Number.MAX_VALUE);e.forEach(function(e){e.x2Data&&e.x2Data.forEach(function(a){a>b&&(b=a,g=!0)})});g&&(this.dataMax=b)}});""});P(x,"parts-gantt/GanttSeries.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=e.isNumber,t=e.merge,N=e.pick,H=e.seriesType,
L=e.splat,K=l.dateFormat,E=l.seriesTypes.xrange;H("gantt","xrange",{grouping:!1,dataLabels:{enabled:!0},tooltip:{headerFormat:'<span style="font-size: 10px">{series.name}</span><br/>',pointFormat:null,pointFormatter:function(){var e=this.series,l=e.chart.tooltip,t=e.xAxis,x=e.tooltipOptions.dateTimeLabelFormats,z=t.options.startOfWeek,q=e.tooltipOptions,m=q.xDateFormat;e=this.options.milestone;var u="<b>"+(this.name||this.yCategory)+"</b>";if(q.pointFormat)return this.tooltipFormatter(q.pointFormat);
m||(m=L(l.getDateFormat(t.closestPointRange,this.start,z,x))[0]);l=K(m,this.start);t=K(m,this.end);u+="<br/>";return e?u+(l+"<br/>"):u+("Start: "+l+"<br/>End: ")+(t+"<br/>")}},connectors:{type:"simpleConnect",animation:{reversed:!0},startMarker:{enabled:!0,symbol:"arrow-filled",radius:4,fill:"#fa0",align:"left"},endMarker:{enabled:!1,align:"right"}}},{pointArrayMap:["start","end","y"],keyboardMoveVertical:!1,translatePoint:function(e){E.prototype.translatePoint.call(this,e);if(e.options.milestone){var l=
e.shapeArgs;var t=l.height;e.shapeArgs={x:l.x-t/2,y:l.y,width:t,height:t}}},drawPoint:function(e,l){var t=this.options,A=this.chart.renderer,z=e.shapeArgs,q=e.plotY,m=e.graphic,u=e.selected&&"select",k=t.stacking&&!t.borderRadius;if(e.options.milestone)if(x(q)&&null!==e.y&&!1!==e.visible){z=A.symbols.diamond(z.x,z.y,z.width,z.height);if(m)m[l]({d:z});else e.graphic=A.path(z).addClass(e.getClassName(),!0).add(e.group||this.group);this.chart.styledMode||e.graphic.attr(this.pointAttribs(e,u)).shadow(t.shadow,
null,k)}else m&&(e.graphic=m.destroy());else E.prototype.drawPoint.call(this,e,l)},setData:l.Series.prototype.setData,setGanttPointAliases:function(e){function l(l,t){"undefined"!==typeof t&&(e[l]=t)}l("x",N(e.start,e.x));l("x2",N(e.end,e.x2));l("partialFill",N(e.completed,e.partialFill));l("connect",N(e.dependency,e.connect))}},t(E.prototype.pointClass.prototype,{applyOptions:function(e,x){e=t(e);l.seriesTypes.gantt.prototype.setGanttPointAliases(e);return e=E.prototype.pointClass.prototype.applyOptions.call(this,
e,x)},isValid:function(){return("number"===typeof this.start||"number"===typeof this.x)&&("number"===typeof this.end||"number"===typeof this.x2||this.milestone)}}));""});P(x,"parts-gantt/GanttChart.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=e.isArray,t=e.merge,N=e.splat,H=l.Chart;l.ganttChart=function(e,B,E){var C="string"===typeof e||e.nodeName,J=B.series,y=l.getOptions(),A,z=B;B=arguments[C?1:0];x(B.xAxis)||(B.xAxis=[B.xAxis||{},{}]);B.xAxis=B.xAxis.map(function(e,l){1===
l&&(A=0);return t(y.xAxis,{grid:{enabled:!0},opposite:!0,linkedTo:A},e,{type:"datetime"})});B.yAxis=N(B.yAxis||{}).map(function(e){return t(y.yAxis,{grid:{enabled:!0},staticScale:50,reversed:!0,type:e.categories?e.type:"treegrid"},e)});B.series=null;B=t(!0,{chart:{type:"gantt"},title:{text:null},legend:{enabled:!1}},B,{isGantt:!0});B.series=z.series=J;B.series.forEach(function(e){e.data.forEach(function(e){l.seriesTypes.gantt.prototype.setGanttPointAliases(e)})});return C?new H(e,B,E):new H(B,B)}});
P(x,"parts/ScrollbarAxis.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=e.addEvent,t=e.defined,N=e.pick;return function(){function e(){}e.compose=function(e,B){x(e,"afterInit",function(){var e=this;e.options&&e.options.scrollbar&&e.options.scrollbar.enabled&&(e.options.scrollbar.vertical=!e.horiz,e.options.startOnTick=e.options.endOnTick=!1,e.scrollbar=new B(e.chart.renderer,e.options.scrollbar,e.chart),x(e.scrollbar,"changed",function(x){var B=N(e.options&&e.options.min,
e.min),y=N(e.options&&e.options.max,e.max),A=t(e.dataMin)?Math.min(B,e.min,e.dataMin):B,z=(t(e.dataMax)?Math.max(y,e.max,e.dataMax):y)-A;t(B)&&t(y)&&(e.horiz&&!e.reversed||!e.horiz&&e.reversed?(B=A+z*this.to,A+=z*this.from):(B=A+z*(1-this.from),A+=z*(1-this.to)),N(this.options.liveRedraw,l.svg&&!l.isTouchDevice&&!this.chart.isBoosting)||"mouseup"===x.DOMType||!t(x.DOMType)?e.setExtremes(A,B,!0,"mousemove"!==x.DOMType,x):this.setRange(this.from,this.to))}))});x(e,"afterRender",function(){var e=Math.min(N(this.options.min,
this.min),this.min,N(this.dataMin,this.min)),l=Math.max(N(this.options.max,this.max),this.max,N(this.dataMax,this.max)),x=this.scrollbar,y=this.axisTitleMargin+(this.titleOffset||0),A=this.chart.scrollbarsOffsets,z=this.options.margin||0;x&&(this.horiz?(this.opposite||(A[1]+=y),x.position(this.left,this.top+this.height+2+A[1]-(this.opposite?z:0),this.width,this.height),this.opposite||(A[1]+=z),y=1):(this.opposite&&(A[0]+=y),x.position(this.left+this.width+2+A[0]-(this.opposite?0:z),this.top,this.width,
this.height),this.opposite&&(A[0]+=z),y=0),A[y]+=x.size+x.options.margin,isNaN(e)||isNaN(l)||!t(this.min)||!t(this.max)||this.min===this.max?x.setRange(0,1):(A=(this.min-e)/(l-e),e=(this.max-e)/(l-e),this.horiz&&!this.reversed||!this.horiz&&this.reversed?x.setRange(A,e):x.setRange(1-e,1-A)))});x(e,"afterGetOffset",function(){var e=this.horiz?2:1,l=this.scrollbar;l&&(this.chart.scrollbarsOffsets=[0,0],this.chart.axisOffset[e]+=l.size+l.options.margin)})};return e}()});P(x,"parts/Scrollbar.js",[x["parts/Axis.js"],
x["parts/Globals.js"],x["parts/ScrollbarAxis.js"],x["parts/Utilities.js"]],function(l,e,x,t){var B=t.addEvent,H=t.correctFloat,L=t.defined,K=t.destroyObjectProperties,E=t.fireEvent,C=t.merge,J=t.pick,y=t.removeEvent;t=e.defaultOptions;var A=e.hasTouch,z=e.isTouchDevice,q=e.swapXY=function(e,k){k&&e.forEach(function(e){for(var b=e.length,f,a=0;a<b;a+=2)f=e[a+1],"number"===typeof f&&(e[a+1]=e[a+2],e[a+2]=f)});return e},m=function(){function e(e,g,b){this._events=[];this.from=this.chartY=this.chartX=
0;this.scrollbar=this.group=void 0;this.scrollbarButtons=[];this.scrollbarGroup=void 0;this.scrollbarLeft=0;this.scrollbarRifles=void 0;this.scrollbarStrokeWidth=1;this.to=this.size=this.scrollbarTop=0;this.track=void 0;this.trackBorderWidth=1;this.userOptions={};this.y=this.x=0;this.chart=b;this.options=g;this.renderer=b.renderer;this.init(e,g,b)}e.prototype.addEvents=function(){var e=this.options.inverted?[1,0]:[0,1],g=this.scrollbarButtons,b=this.scrollbarGroup.element,f=this.track.element,a=this.mouseDownHandler.bind(this),
c=this.mouseMoveHandler.bind(this),l=this.mouseUpHandler.bind(this);e=[[g[e[0]].element,"click",this.buttonToMinClick.bind(this)],[g[e[1]].element,"click",this.buttonToMaxClick.bind(this)],[f,"click",this.trackClick.bind(this)],[b,"mousedown",a],[b.ownerDocument,"mousemove",c],[b.ownerDocument,"mouseup",l]];A&&e.push([b,"touchstart",a],[b.ownerDocument,"touchmove",c],[b.ownerDocument,"touchend",l]);e.forEach(function(a){B.apply(null,a)});this._events=e};e.prototype.buttonToMaxClick=function(e){var g=
(this.to-this.from)*J(this.options.step,.2);this.updatePosition(this.from+g,this.to+g);E(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:e})};e.prototype.buttonToMinClick=function(e){var g=H(this.to-this.from)*J(this.options.step,.2);this.updatePosition(H(this.from-g),H(this.to-g));E(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:e})};e.prototype.cursorToScrollbarPosition=function(e){var g=this.options;g=g.minWidth>this.calculatedWidth?g.minWidth:0;return{chartX:(e.chartX-
this.x-this.xOffset)/(this.barWidth-g),chartY:(e.chartY-this.y-this.yOffset)/(this.barWidth-g)}};e.prototype.destroy=function(){var e=this.chart.scroller;this.removeEvents();["track","scrollbarRifles","scrollbar","scrollbarGroup","group"].forEach(function(e){this[e]&&this[e].destroy&&(this[e]=this[e].destroy())},this);e&&this===e.scrollbar&&(e.scrollbar=null,K(e.scrollbarButtons))};e.prototype.drawScrollbarButton=function(e){var g=this.renderer,b=this.scrollbarButtons,f=this.options,a=this.size;var c=
g.g().add(this.group);b.push(c);c=g.rect().addClass("highcharts-scrollbar-button").add(c);this.chart.styledMode||c.attr({stroke:f.buttonBorderColor,"stroke-width":f.buttonBorderWidth,fill:f.buttonBackgroundColor});c.attr(c.crisp({x:-.5,y:-.5,width:a+1,height:a+1,r:f.buttonBorderRadius},c.strokeWidth()));c=g.path(q([["M",a/2+(e?-1:1),a/2-3],["L",a/2+(e?-1:1),a/2+3],["L",a/2+(e?2:-2),a/2]],f.vertical)).addClass("highcharts-scrollbar-arrow").add(b[e]);this.chart.styledMode||c.attr({fill:f.buttonArrowColor})};
e.prototype.init=function(k,g,b){this.scrollbarButtons=[];this.renderer=k;this.userOptions=g;this.options=C(e.defaultOptions,g);this.chart=b;this.size=J(this.options.size,this.options.height);g.enabled&&(this.render(),this.addEvents())};e.prototype.mouseDownHandler=function(e){e=this.chart.pointer.normalize(e);e=this.cursorToScrollbarPosition(e);this.chartX=e.chartX;this.chartY=e.chartY;this.initPositions=[this.from,this.to];this.grabbedCenter=!0};e.prototype.mouseMoveHandler=function(e){var g=this.chart.pointer.normalize(e),
b=this.options.vertical?"chartY":"chartX",f=this.initPositions||[];!this.grabbedCenter||e.touches&&0===e.touches[0][b]||(g=this.cursorToScrollbarPosition(g)[b],b=this[b],b=g-b,this.hasDragged=!0,this.updatePosition(f[0]+b,f[1]+b),this.hasDragged&&E(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:e.type,DOMEvent:e}))};e.prototype.mouseUpHandler=function(e){this.hasDragged&&E(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:e.type,DOMEvent:e});this.grabbedCenter=
this.hasDragged=this.chartX=this.chartY=null};e.prototype.position=function(e,g,b,f){var a=this.options.vertical,c=0,k=this.rendered?"animate":"attr";this.x=e;this.y=g+this.trackBorderWidth;this.width=b;this.xOffset=this.height=f;this.yOffset=c;a?(this.width=this.yOffset=b=c=this.size,this.xOffset=g=0,this.barWidth=f-2*b,this.x=e+=this.options.margin):(this.height=this.xOffset=f=g=this.size,this.barWidth=b-2*f,this.y+=this.options.margin);this.group[k]({translateX:e,translateY:this.y});this.track[k]({width:b,
height:f});this.scrollbarButtons[1][k]({translateX:a?0:b-g,translateY:a?f-c:0})};e.prototype.removeEvents=function(){this._events.forEach(function(e){y.apply(null,e)});this._events.length=0};e.prototype.render=function(){var e=this.renderer,g=this.options,b=this.size,f=this.chart.styledMode,a;this.group=a=e.g("scrollbar").attr({zIndex:g.zIndex,translateY:-99999}).add();this.track=e.rect().addClass("highcharts-scrollbar-track").attr({x:0,r:g.trackBorderRadius||0,height:b,width:b}).add(a);f||this.track.attr({fill:g.trackBackgroundColor,
stroke:g.trackBorderColor,"stroke-width":g.trackBorderWidth});this.trackBorderWidth=this.track.strokeWidth();this.track.attr({y:-this.trackBorderWidth%2/2});this.scrollbarGroup=e.g().add(a);this.scrollbar=e.rect().addClass("highcharts-scrollbar-thumb").attr({height:b,width:b,r:g.barBorderRadius||0}).add(this.scrollbarGroup);this.scrollbarRifles=e.path(q([["M",-3,b/4],["L",-3,2*b/3],["M",0,b/4],["L",0,2*b/3],["M",3,b/4],["L",3,2*b/3]],g.vertical)).addClass("highcharts-scrollbar-rifles").add(this.scrollbarGroup);
f||(this.scrollbar.attr({fill:g.barBackgroundColor,stroke:g.barBorderColor,"stroke-width":g.barBorderWidth}),this.scrollbarRifles.attr({stroke:g.rifleColor,"stroke-width":1}));this.scrollbarStrokeWidth=this.scrollbar.strokeWidth();this.scrollbarGroup.translate(-this.scrollbarStrokeWidth%2/2,-this.scrollbarStrokeWidth%2/2);this.drawScrollbarButton(0);this.drawScrollbarButton(1)};e.prototype.setRange=function(e,g){var b=this.options,f=b.vertical,a=b.minWidth,c=this.barWidth,k,l=!this.rendered||this.hasDragged||
this.chart.navigator&&this.chart.navigator.hasDragged?"attr":"animate";if(L(c)){e=Math.max(e,0);var m=Math.ceil(c*e);this.calculatedWidth=k=H(c*Math.min(g,1)-m);k<a&&(m=(c-a+k)*e,k=a);a=Math.floor(m+this.xOffset+this.yOffset);c=k/2-.5;this.from=e;this.to=g;f?(this.scrollbarGroup[l]({translateY:a}),this.scrollbar[l]({height:k}),this.scrollbarRifles[l]({translateY:c}),this.scrollbarTop=a,this.scrollbarLeft=0):(this.scrollbarGroup[l]({translateX:a}),this.scrollbar[l]({width:k}),this.scrollbarRifles[l]({translateX:c}),
this.scrollbarLeft=a,this.scrollbarTop=0);12>=k?this.scrollbarRifles.hide():this.scrollbarRifles.show(!0);!1===b.showFull&&(0>=e&&1<=g?this.group.hide():this.group.show());this.rendered=!0}};e.prototype.trackClick=function(e){var g=this.chart.pointer.normalize(e),b=this.to-this.from,f=this.y+this.scrollbarTop,a=this.x+this.scrollbarLeft;this.options.vertical&&g.chartY>f||!this.options.vertical&&g.chartX>a?this.updatePosition(this.from+b,this.to+b):this.updatePosition(this.from-b,this.to-b);E(this,
"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:e})};e.prototype.update=function(e){this.destroy();this.init(this.chart.renderer,C(!0,this.options,e),this.chart)};e.prototype.updatePosition=function(e,g){1<g&&(e=H(1-H(g-e)),g=1);0>e&&(g=H(g-e),e=0);this.from=e;this.to=g};e.defaultOptions={height:z?20:14,barBorderRadius:0,buttonBorderRadius:0,liveRedraw:void 0,margin:10,minWidth:6,step:.2,zIndex:3,barBackgroundColor:"#cccccc",barBorderWidth:1,barBorderColor:"#cccccc",buttonArrowColor:"#333333",
buttonBackgroundColor:"#e6e6e6",buttonBorderColor:"#cccccc",buttonBorderWidth:1,rifleColor:"#333333",trackBackgroundColor:"#f2f2f2",trackBorderColor:"#f2f2f2",trackBorderWidth:1};return e}();e.Scrollbar||(t.scrollbar=C(!0,m.defaultOptions,t.scrollbar),e.Scrollbar=m,x.compose(l,m));return e.Scrollbar});P(x,"parts/RangeSelector.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){function x(b){this.init(b)}var t=e.addEvent,N=e.createElement,H=e.css,L=e.defined,K=e.destroyObjectProperties,
E=e.discardElement,C=e.extend,J=e.fireEvent,y=e.isNumber,A=e.merge,z=e.objectEach,q=e.pick,m=e.pInt,u=e.splat,k=l.Axis;e=l.Chart;var g=l.defaultOptions;C(g,{rangeSelector:{verticalAlign:"top",buttonTheme:{width:28,height:18,padding:2,zIndex:7},floating:!1,x:0,y:0,height:void 0,inputPosition:{align:"right",x:0,y:0},buttonPosition:{align:"left",x:0,y:0},labelStyle:{color:"#666666"}}});g.lang=A(g.lang,{rangeSelectorZoom:"Zoom",rangeSelectorFrom:"From",rangeSelectorTo:"To"});x.prototype={clickButton:function(b,
e){var a=this.chart,c=this.buttonOptions[b],f=a.xAxis[0],g=a.scroller&&a.scroller.getUnionExtremes()||f||{},l=g.dataMin,m=g.dataMax,v=f&&Math.round(Math.min(f.max,q(m,f.max))),n=c.type;g=c._range;var F,x=c.dataGrouping;if(null!==l&&null!==m){a.fixedRange=g;x&&(this.forcedDataGrouping=!0,k.prototype.setDataGrouping.call(f||{chart:this.chart},x,!1),this.frozenStates=c.preserveDataGrouping);if("month"===n||"year"===n)if(f){n={range:c,max:v,chart:a,dataMin:l,dataMax:m};var D=f.minFromRange.call(n);y(n.newMax)&&
(v=n.newMax)}else g=c;else if(g)D=Math.max(v-g,l),v=Math.min(D+g,m);else if("ytd"===n)if(f)"undefined"===typeof m&&(l=Number.MAX_VALUE,m=Number.MIN_VALUE,a.series.forEach(function(a){a=a.xData;l=Math.min(a[0],l);m=Math.max(a[a.length-1],m)}),e=!1),v=this.getYTDExtremes(m,l,a.time.useUTC),D=F=v.min,v=v.max;else{this.deferredYTDClick=b;return}else"all"===n&&f&&(D=l,v=m);D+=c._offsetMin;v+=c._offsetMax;this.setSelected(b);if(f)f.setExtremes(D,v,q(e,1),null,{trigger:"rangeSelectorButton",rangeSelectorButton:c});
else{var h=u(a.options.xAxis)[0];var d=h.range;h.range=g;var z=h.min;h.min=F;t(a,"load",function(){h.range=d;h.min=z})}}},setSelected:function(b){this.selected=this.options.selected=b},defaultButtons:[{type:"month",count:1,text:"1m"},{type:"month",count:3,text:"3m"},{type:"month",count:6,text:"6m"},{type:"ytd",text:"YTD"},{type:"year",count:1,text:"1y"},{type:"all",text:"All"}],init:function(b){var e=this,a=b.options.rangeSelector,c=a.buttons||[].concat(e.defaultButtons),g=a.selected,k=function(){var a=
e.minInput,b=e.maxInput;a&&a.blur&&J(a,"blur");b&&b.blur&&J(b,"blur")};e.chart=b;e.options=a;e.buttons=[];e.buttonOptions=c;this.unMouseDown=t(b.container,"mousedown",k);this.unResize=t(b,"resize",k);c.forEach(e.computeButtonRange);"undefined"!==typeof g&&c[g]&&this.clickButton(g,!1);t(b,"load",function(){b.xAxis&&b.xAxis[0]&&t(b.xAxis[0],"setExtremes",function(a){this.max-this.min!==b.fixedRange&&"rangeSelectorButton"!==a.trigger&&"updatedData"!==a.trigger&&e.forcedDataGrouping&&!e.frozenStates&&
this.setDataGrouping(!1,!1)})})},updateButtonStates:function(){var b=this,e=this.chart,a=e.xAxis[0],c=Math.round(a.max-a.min),g=!a.hasVisibleSeries,k=e.scroller&&e.scroller.getUnionExtremes()||a,l=k.dataMin,m=k.dataMax;e=b.getYTDExtremes(m,l,e.time.useUTC);var q=e.min,n=e.max,u=b.selected,t=y(u),x=b.options.allButtonsEnabled,h=b.buttons;b.buttonOptions.forEach(function(d,e){var f=d._range,k=d.type,p=d.count||1,r=h[e],v=0,w=d._offsetMax-d._offsetMin;d=e===u;var F=f>m-l,y=f<a.minRange,D=!1,z=!1;f=f===
c;("month"===k||"year"===k)&&c+36E5>=864E5*{month:28,year:365}[k]*p-w&&c-36E5<=864E5*{month:31,year:366}[k]*p+w?f=!0:"ytd"===k?(f=n-q+w===c,D=!d):"all"===k&&(f=a.max-a.min>=m-l,z=!d&&t&&f);k=!x&&(F||y||z||g);p=d&&f||f&&!t&&!D||d&&b.frozenStates;k?v=3:p&&(t=!0,v=2);r.state!==v&&(r.setState(v),0===v&&u===e&&b.setSelected(null))})},computeButtonRange:function(b){var e=b.type,a=b.count||1,c={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5};if(c[e])b._range=c[e]*a;else if("month"===
e||"year"===e)b._range=864E5*{month:30,year:365}[e]*a;b._offsetMin=q(b.offsetMin,0);b._offsetMax=q(b.offsetMax,0);b._range+=b._offsetMax-b._offsetMin},setInputValue:function(b,e){var a=this.chart.options.rangeSelector,c=this.chart.time,f=this[b+"Input"];L(e)&&(f.previousValue=f.HCTime,f.HCTime=e);f.value=c.dateFormat(a.inputEditDateFormat||"%Y-%m-%d",f.HCTime);this[b+"DateBox"].attr({text:c.dateFormat(a.inputDateFormat||"%b %e, %Y",f.HCTime)})},showInput:function(b){var e=this.inputGroup,a=this[b+
"DateBox"];H(this[b+"Input"],{left:e.translateX+a.x+"px",top:e.translateY+"px",width:a.width-2+"px",height:a.height-2+"px",border:"2px solid silver"})},hideInput:function(b){H(this[b+"Input"],{border:0,width:"1px",height:"1px"});this.setInputValue(b)},drawInput:function(b){function e(){var b=n.value,e=(q.inputDateParser||Date.parse)(b),d=c.xAxis[0],f=c.scroller&&c.scroller.xAxis?c.scroller.xAxis:d,g=f.dataMin;f=f.dataMax;e!==n.previousValue&&(n.previousValue=e,y(e)||(e=b.split("-"),e=Date.UTC(m(e[0]),
m(e[1])-1,m(e[2]))),y(e)&&(c.time.useUTC||(e+=6E4*(new Date).getTimezoneOffset()),v?e>a.maxInput.HCTime?e=void 0:e<g&&(e=g):e<a.minInput.HCTime?e=void 0:e>f&&(e=f),"undefined"!==typeof e&&d.setExtremes(v?e:d.min,v?d.max:e,void 0,void 0,{trigger:"rangeSelectorInput"})))}var a=this,c=a.chart,k=c.renderer.style||{},p=c.renderer,q=c.options.rangeSelector,u=a.div,v="min"===b,n,t,x=this.inputGroup;this[b+"Label"]=t=p.label(g.lang[v?"rangeSelectorFrom":"rangeSelectorTo"],this.inputGroup.offset).addClass("highcharts-range-label").attr({padding:2}).add(x);
x.offset+=t.width+5;this[b+"DateBox"]=p=p.label("",x.offset).addClass("highcharts-range-input").attr({padding:2,width:q.inputBoxWidth||90,height:q.inputBoxHeight||17,"text-align":"center"}).on("click",function(){a.showInput(b);a[b+"Input"].focus()});c.styledMode||p.attr({stroke:q.inputBoxBorderColor||"#cccccc","stroke-width":1});p.add(x);x.offset+=p.width+(v?10:0);this[b+"Input"]=n=N("input",{name:b,className:"highcharts-range-selector",type:"text"},{top:c.plotTop+"px"},u);c.styledMode||(t.css(A(k,
q.labelStyle)),p.css(A({color:"#333333"},k,q.inputStyle)),H(n,C({position:"absolute",border:0,width:"1px",height:"1px",padding:0,textAlign:"center",fontSize:k.fontSize,fontFamily:k.fontFamily,top:"-9999em"},q.inputStyle)));n.onfocus=function(){a.showInput(b)};n.onblur=function(){n===l.doc.activeElement&&e();a.hideInput(b);n.blur()};n.onchange=e;n.onkeypress=function(a){13===a.keyCode&&e()}},getPosition:function(){var b=this.chart,e=b.options.rangeSelector;b="top"===e.verticalAlign?b.plotTop-b.axisOffset[0]:
0;return{buttonTop:b+e.buttonPosition.y,inputTop:b+e.inputPosition.y-10}},getYTDExtremes:function(b,e,a){var c=this.chart.time,f=new c.Date(b),g=c.get("FullYear",f);a=a?c.Date.UTC(g,0,1):+new c.Date(g,0,1);e=Math.max(e||0,a);f=f.getTime();return{max:Math.min(b||f,f),min:e}},render:function(b,e){var a=this,c=a.chart,f=c.renderer,k=c.container,l=c.options,m=l.exporting&&!1!==l.exporting.enabled&&l.navigation&&l.navigation.buttonOptions,v=g.lang,n=a.div,u=l.rangeSelector,t=q(l.chart.style&&l.chart.style.zIndex,
0)+1;l=u.floating;var y=a.buttons;n=a.inputGroup;var h=u.buttonTheme,d=u.buttonPosition,x=u.inputPosition,z=u.inputEnabled,A=h&&h.states,B=c.plotLeft,C=a.buttonGroup,E,H=a.options.verticalAlign,J=c.legend,L=J&&J.options,K=d.y,P=x.y,T=c.hasLoaded,aa=T?"animate":"attr",R=0,Y=0;if(!1!==u.enabled){a.rendered||(a.group=E=f.g("range-selector-group").attr({zIndex:7}).add(),a.buttonGroup=C=f.g("range-selector-buttons").add(E),a.zoomText=f.text(v.rangeSelectorZoom,0,15).add(C),c.styledMode||(a.zoomText.css(u.labelStyle),
h["stroke-width"]=q(h["stroke-width"],0)),a.buttonOptions.forEach(function(b,d){y[d]=f.button(b.text,0,0,function(c){var e=b.events&&b.events.click,f;e&&(f=e.call(b,c));!1!==f&&a.clickButton(d);a.isActive=!0},h,A&&A.hover,A&&A.select,A&&A.disabled).attr({"text-align":"center"}).add(C)}),!1!==z&&(a.div=n=N("div",null,{position:"relative",height:0,zIndex:t}),k.parentNode.insertBefore(n,k),a.inputGroup=n=f.g("input-group").add(E),n.offset=0,a.drawInput("min"),a.drawInput("max")));a.zoomText[aa]({x:q(B+
d.x,B)});var ba=q(B+d.x,B)+a.zoomText.getBBox().width+5;a.buttonOptions.forEach(function(a,b){y[b][aa]({x:ba});ba+=y[b].width+q(u.buttonSpacing,5)});B=c.plotLeft-c.spacing[3];a.updateButtonStates();m&&this.titleCollision(c)&&"top"===H&&"right"===d.align&&d.y+C.getBBox().height-12<(m.y||0)+m.height&&(R=-40);k=d.x-c.spacing[3];"right"===d.align?k+=R-B:"center"===d.align&&(k-=B/2);C.align({y:d.y,width:C.getBBox().width,align:d.align,x:k},!0,c.spacingBox);a.group.placed=T;a.buttonGroup.placed=T;!1!==
z&&(R=m&&this.titleCollision(c)&&"top"===H&&"right"===x.align&&x.y-n.getBBox().height-12<(m.y||0)+m.height+c.spacing[0]?-40:0,"left"===x.align?k=B:"right"===x.align&&(k=-Math.max(c.axisOffset[1],-R)),n.align({y:x.y,width:n.getBBox().width,align:x.align,x:x.x+k-2},!0,c.spacingBox),m=n.alignAttr.translateX+n.alignOptions.x-R+n.getBBox().x+2,k=n.alignOptions.width,v=C.alignAttr.translateX+C.getBBox().x,B=C.getBBox().width+20,(x.align===d.align||v+B>m&&m+k>v&&K<P+n.getBBox().height)&&n.attr({translateX:n.alignAttr.translateX+
(c.axisOffset[1]>=-R?0:-R),translateY:n.alignAttr.translateY+C.getBBox().height+10}),a.setInputValue("min",b),a.setInputValue("max",e),a.inputGroup.placed=T);a.group.align({verticalAlign:H},!0,c.spacingBox);b=a.group.getBBox().height+20;e=a.group.alignAttr.translateY;"bottom"===H&&(J=L&&"bottom"===L.verticalAlign&&L.enabled&&!L.floating?J.legendHeight+q(L.margin,10):0,b=b+J-20,Y=e-b-(l?0:u.y)-(c.titleOffset?c.titleOffset[2]:0)-10);if("top"===H)l&&(Y=0),c.titleOffset&&c.titleOffset[0]&&(Y=c.titleOffset[0]),
Y+=c.margin[0]-c.spacing[0]||0;else if("middle"===H)if(P===K)Y=0>P?e+void 0:e;else if(P||K)Y=0>P||0>K?Y-Math.min(P,K):e-b+NaN;a.group.translate(u.x,u.y+Math.floor(Y));!1!==z&&(a.minInput.style.marginTop=a.group.translateY+"px",a.maxInput.style.marginTop=a.group.translateY+"px");a.rendered=!0}},getHeight:function(){var b=this.options,e=this.group,a=b.y,c=b.buttonPosition.y,g=b.inputPosition.y;if(b.height)return b.height;b=e?e.getBBox(!0).height+13+a:0;e=Math.min(g,c);if(0>g&&0>c||0<g&&0<c)b+=Math.abs(e);
return b},titleCollision:function(b){return!(b.options.title.text||b.options.subtitle.text)},update:function(b){var e=this.chart;A(!0,e.options.rangeSelector,b);this.destroy();this.init(e);e.rangeSelector.render()},destroy:function(){var b=this,e=b.minInput,a=b.maxInput;b.unMouseDown();b.unResize();K(b.buttons);e&&(e.onfocus=e.onblur=e.onchange=null);a&&(a.onfocus=a.onblur=a.onchange=null);z(b,function(a,e){a&&"chart"!==e&&(a.destroy?a.destroy():a.nodeType&&E(this[e]));a!==x.prototype[e]&&(b[e]=null)},
this)}};k.prototype.minFromRange=function(){var b=this.range,e=b.type,a=this.max,c=this.chart.time,g=function(a,b){var f="year"===e?"FullYear":"Month",g=new c.Date(a),k=c.get(f,g);c.set(f,g,k+b);k===c.get(f,g)&&c.set("Date",g,0);return g.getTime()-a};if(y(b)){var k=a-b;var l=b}else k=a+g(a,-b.count),this.chart&&(this.chart.fixedRange=a-k);var m=q(this.dataMin,Number.MIN_VALUE);y(k)||(k=m);k<=m&&(k=m,"undefined"===typeof l&&(l=g(k,b.count)),this.newMax=Math.min(k+l,this.dataMax));y(a)||(k=void 0);
return k};l.RangeSelector||(t(e,"afterGetContainer",function(){this.options.rangeSelector.enabled&&(this.rangeSelector=new x(this))}),t(e,"beforeRender",function(){var b=this.axes,e=this.rangeSelector;e&&(y(e.deferredYTDClick)&&(e.clickButton(e.deferredYTDClick),delete e.deferredYTDClick),b.forEach(function(a){a.updateNames();a.setScale()}),this.getAxisMargins(),e.render(),b=e.options.verticalAlign,e.options.floating||("bottom"===b?this.extraBottomMargin=!0:"middle"!==b&&(this.extraTopMargin=!0)))}),
t(e,"update",function(b){var e=b.options.rangeSelector;b=this.rangeSelector;var a=this.extraBottomMargin,c=this.extraTopMargin;e&&e.enabled&&!L(b)&&(this.options.rangeSelector.enabled=!0,this.rangeSelector=new x(this));this.extraTopMargin=this.extraBottomMargin=!1;b&&(b.render(),e=e&&e.verticalAlign||b.options&&b.options.verticalAlign,b.options.floating||("bottom"===e?this.extraBottomMargin=!0:"middle"!==e&&(this.extraTopMargin=!0)),this.extraBottomMargin!==a||this.extraTopMargin!==c)&&(this.isDirtyBox=
!0)}),t(e,"render",function(){var b=this.rangeSelector;b&&!b.options.floating&&(b.render(),b=b.options.verticalAlign,"bottom"===b?this.extraBottomMargin=!0:"middle"!==b&&(this.extraTopMargin=!0))}),t(e,"getMargins",function(){var b=this.rangeSelector;b&&(b=b.getHeight(),this.extraTopMargin&&(this.plotTop+=b),this.extraBottomMargin&&(this.marginBottom+=b))}),e.prototype.callbacks.push(function(b){function e(){a=b.xAxis[0].getExtremes();g=b.legend;l=null===c||void 0===c?void 0:c.options.verticalAlign;
y(a.min)&&c.render(a.min,a.max);c&&g.display&&"top"===l&&l===g.options.verticalAlign&&(k=A(b.spacingBox),k.y="vertical"===g.options.layout?b.plotTop:k.y+c.getHeight(),g.group.placed=!1,g.align(k))}var a,c=b.rangeSelector,g,k,l;if(c){var m=t(b.xAxis[0],"afterSetExtremes",function(a){c.render(a.min,a.max)});var q=t(b,"redraw",e);e()}t(b,"destroy",function(){c&&(q(),m())})}),l.RangeSelector=x)});P(x,"parts/NavigatorAxis.js",[x["parts/Globals.js"],x["parts/Utilities.js"]],function(l,e){var x=l.isTouchDevice,
t=e.addEvent,N=e.correctFloat,H=e.defined,L=e.isNumber,K=e.pick,E=function(){function e(e){this.axis=e}e.prototype.destroy=function(){this.axis=void 0};e.prototype.toFixedRange=function(e,l,t,x){var q=this.axis,m=q.chart;m=m&&m.fixedRange;var u=(q.pointRange||0)/2;e=K(t,q.translate(e,!0,!q.horiz));l=K(x,q.translate(l,!0,!q.horiz));q=m&&(l-e)/m;H(t)||(e=N(e+u));H(x)||(l=N(l-u));.7<q&&1.3>q&&(x?e=l-m:l=e+m);L(e)&&L(l)||(e=l=void 0);return{min:e,max:l}};return e}();return function(){function e(){}e.compose=
function(e){e.keepProps.push("navigatorAxis");t(e,"init",function(){this.navigatorAxis||(this.navigatorAxis=new E(this))});t(e,"zoom",function(e){var l=this.chart.options,t=l.navigator,q=this.navigatorAxis,m=l.chart.pinchType,u=l.rangeSelector;l=l.chart.zoomType;this.isXAxis&&(t&&t.enabled||u&&u.enabled)&&("y"===l?e.zoomed=!1:(!x&&"xy"===l||x&&"xy"===m)&&this.options.range&&(t=q.previousZoom,H(e.newMin)?q.previousZoom=[this.min,this.max]:t&&(e.newMin=t[0],e.newMax=t[1],q.previousZoom=void 0)));"undefined"!==
typeof e.zoomed&&e.preventDefault()})};e.AdditionsClass=E;return e}()});P(x,"parts/Navigator.js",[x["parts/Axis.js"],x["parts/Color.js"],x["parts/Globals.js"],x["parts/NavigatorAxis.js"],x["parts/Scrollbar.js"],x["parts/Utilities.js"]],function(l,e,x,t,N,H){e=e.parse;var B=H.addEvent,K=H.clamp,E=H.correctFloat,C=H.defined,J=H.destroyObjectProperties,y=H.erase,A=H.extend,z=H.find,q=H.isArray,m=H.isNumber,u=H.merge,k=H.pick,g=H.removeEvent,b=H.splat;H=x.Chart;var f=x.defaultOptions,a=x.hasTouch,c=x.isTouchDevice,
r=x.Series,p=function(a){for(var b=[],c=1;c<arguments.length;c++)b[c-1]=arguments[c];b=[].filter.call(b,m);if(b.length)return Math[a].apply(0,b)};var I="undefined"===typeof x.seriesTypes.areaspline?"line":"areaspline";A(f,{navigator:{height:40,margin:25,maskInside:!0,handles:{width:7,height:15,symbols:["navigator-handle","navigator-handle"],enabled:!0,lineWidth:1,backgroundColor:"#f2f2f2",borderColor:"#999999"},maskFill:e("#6685c2").setOpacity(.3).get(),outlineColor:"#cccccc",outlineWidth:1,series:{type:I,
fillOpacity:.05,lineWidth:1,compare:null,dataGrouping:{approximation:"average",enabled:!0,groupPixelWidth:2,smoothed:!0,units:[["millisecond",[1,2,5,10,20,25,50,100,200,500]],["second",[1,2,5,10,15,30]],["minute",[1,2,5,10,15,30]],["hour",[1,2,3,4,6,8,12]],["day",[1,2,3,4]],["week",[1,2,3]],["month",[1,3,6]],["year",null]]},dataLabels:{enabled:!1,zIndex:2},id:"highcharts-navigator-series",className:"highcharts-navigator-series",lineColor:null,marker:{enabled:!1},threshold:null},xAxis:{overscroll:0,
className:"highcharts-navigator-xaxis",tickLength:0,lineWidth:0,gridLineColor:"#e6e6e6",gridLineWidth:1,tickPixelInterval:200,labels:{align:"left",style:{color:"#999999"},x:3,y:-4},crosshair:!1},yAxis:{className:"highcharts-navigator-yaxis",gridLineWidth:0,startOnTick:!1,endOnTick:!1,minPadding:.1,maxPadding:.1,labels:{enabled:!1},crosshair:!1,title:{text:null},tickLength:0,tickWidth:0}}});x.Renderer.prototype.symbols["navigator-handle"]=function(a,b,c,e,f){a=f.width/2;b=Math.round(a/3)+.5;f=f.height||
0;return[["M",-a-1,.5],["L",a,.5],["L",a,f+.5],["L",-a-1,f+.5],["L",-a-1,.5],["M",-b,4],["L",-b,f-3],["M",b-1,4],["L",b-1,f-3]]};var w=function(){function e(a){this.zoomedMin=this.zoomedMax=this.yAxis=this.xAxis=this.top=this.size=this.shades=this.rendered=this.range=this.outlineHeight=this.outline=this.opposite=this.navigatorSize=this.navigatorSeries=this.navigatorOptions=this.navigatorGroup=this.navigatorEnabled=this.left=this.height=this.handles=this.chart=this.baseSeries=void 0;this.init(a)}e.prototype.drawHandle=
function(a,b,c,e){var f=this.navigatorOptions.handles.height;this.handles[b][e](c?{translateX:Math.round(this.left+this.height/2),translateY:Math.round(this.top+parseInt(a,10)+.5-f)}:{translateX:Math.round(this.left+parseInt(a,10)),translateY:Math.round(this.top+this.height/2-f/2-1)})};e.prototype.drawOutline=function(a,b,c,e){var f=this.navigatorOptions.maskInside,d=this.outline.strokeWidth(),g=d/2,k=d%2/2;d=this.outlineHeight;var l=this.scrollbarHeight||0,n=this.size,m=this.left-l,p=this.top;c?
(m-=g,c=p+b+k,b=p+a+k,k=[["M",m+d,p-l-k],["L",m+d,c],["L",m,c],["L",m,b],["L",m+d,b],["L",m+d,p+n+l]],f&&k.push(["M",m+d,c-g],["L",m+d,b+g])):(a+=m+l-k,b+=m+l-k,p+=g,k=[["M",m,p],["L",a,p],["L",a,p+d],["L",b,p+d],["L",b,p],["L",m+n+2*l,p]],f&&k.push(["M",a-g,p],["L",b+g,p]));this.outline[e]({d:k})};e.prototype.drawMasks=function(a,b,c,e){var f=this.left,d=this.top,g=this.height;if(c){var k=[f,f,f];var l=[d,d+a,d+b];var n=[g,g,g];var m=[a,b-a,this.size-b]}else k=[f,f+a,f+b],l=[d,d,d],n=[a,b-a,this.size-
b],m=[g,g,g];this.shades.forEach(function(a,b){a[e]({x:k[b],y:l[b],width:n[b],height:m[b]})})};e.prototype.renderElements=function(){var a=this,b=a.navigatorOptions,c=b.maskInside,e=a.chart,f=e.renderer,d,g={cursor:e.inverted?"ns-resize":"ew-resize"};a.navigatorGroup=d=f.g("navigator").attr({zIndex:8,visibility:"hidden"}).add();[!c,c,!c].forEach(function(c,h){a.shades[h]=f.rect().addClass("highcharts-navigator-mask"+(1===h?"-inside":"-outside")).add(d);e.styledMode||a.shades[h].attr({fill:c?b.maskFill:
"rgba(0,0,0,0)"}).css(1===h&&g)});a.outline=f.path().addClass("highcharts-navigator-outline").add(d);e.styledMode||a.outline.attr({"stroke-width":b.outlineWidth,stroke:b.outlineColor});b.handles.enabled&&[0,1].forEach(function(c){b.handles.inverted=e.inverted;a.handles[c]=f.symbol(b.handles.symbols[c],-b.handles.width/2-1,0,b.handles.width,b.handles.height,b.handles);a.handles[c].attr({zIndex:7-c}).addClass("highcharts-navigator-handle highcharts-navigator-handle-"+["left","right"][c]).add(d);if(!e.styledMode){var h=
b.handles;a.handles[c].attr({fill:h.backgroundColor,stroke:h.borderColor,"stroke-width":h.lineWidth}).css(g)}})};e.prototype.update=function(a){(this.series||[]).forEach(function(a){a.baseSeries&&delete a.baseSeries.navigatorSeries});this.destroy();u(!0,this.chart.options.navigator,this.options,a);this.init(this.chart)};e.prototype.render=function(a,b,c,e){var f=this.chart,d=this.scrollbarHeight,g,l=this.xAxis,n=l.pointRange||0;var p=l.navigatorAxis.fake?f.xAxis[0]:l;var q=this.navigatorEnabled,r,
u=this.rendered;var t=f.inverted;var v=f.xAxis[0].minRange,w=f.xAxis[0].options.maxRange;if(!this.hasDragged||C(c)){a=E(a-n/2);b=E(b+n/2);if(!m(a)||!m(b))if(u)c=0,e=k(l.width,p.width);else return;this.left=k(l.left,f.plotLeft+d+(t?f.plotWidth:0));this.size=r=g=k(l.len,(t?f.plotHeight:f.plotWidth)-2*d);f=t?d:g+2*d;c=k(c,l.toPixels(a,!0));e=k(e,l.toPixels(b,!0));m(c)&&Infinity!==Math.abs(c)||(c=0,e=f);a=l.toValue(c,!0);b=l.toValue(e,!0);var x=Math.abs(E(b-a));x<v?this.grabbedLeft?c=l.toPixels(b-v-n,
!0):this.grabbedRight&&(e=l.toPixels(a+v+n,!0)):C(w)&&E(x-n)>w&&(this.grabbedLeft?c=l.toPixels(b-w-n,!0):this.grabbedRight&&(e=l.toPixels(a+w+n,!0)));this.zoomedMax=K(Math.max(c,e),0,r);this.zoomedMin=K(this.fixedWidth?this.zoomedMax-this.fixedWidth:Math.min(c,e),0,r);this.range=this.zoomedMax-this.zoomedMin;r=Math.round(this.zoomedMax);c=Math.round(this.zoomedMin);q&&(this.navigatorGroup.attr({visibility:"visible"}),u=u&&!this.hasDragged?"animate":"attr",this.drawMasks(c,r,t,u),this.drawOutline(c,
r,t,u),this.navigatorOptions.handles.enabled&&(this.drawHandle(c,0,t,u),this.drawHandle(r,1,t,u)));this.scrollbar&&(t?(t=this.top-d,p=this.left-d+(q||!p.opposite?0:(p.titleOffset||0)+p.axisTitleMargin),d=g+2*d):(t=this.top+(q?this.height:-d),p=this.left-d),this.scrollbar.position(p,t,f,d),this.scrollbar.setRange(this.zoomedMin/(g||1),this.zoomedMax/(g||1)));this.rendered=!0}};e.prototype.addMouseEvents=function(){var b=this,c=b.chart,e=c.container,f=[],g,d;b.mouseMoveHandler=g=function(a){b.onMouseMove(a)};
b.mouseUpHandler=d=function(a){b.onMouseUp(a)};f=b.getPartsEvents("mousedown");f.push(B(c.renderTo,"mousemove",g),B(e.ownerDocument,"mouseup",d));a&&(f.push(B(c.renderTo,"touchmove",g),B(e.ownerDocument,"touchend",d)),f.concat(b.getPartsEvents("touchstart")));b.eventsToUnbind=f;b.series&&b.series[0]&&f.push(B(b.series[0].xAxis,"foundExtremes",function(){c.navigator.modifyNavigatorAxisExtremes()}))};e.prototype.getPartsEvents=function(a){var b=this,c=[];["shades","handles"].forEach(function(e){b[e].forEach(function(f,
d){c.push(B(f.element,a,function(a){b[e+"Mousedown"](a,d)}))})});return c};e.prototype.shadesMousedown=function(a,b){a=this.chart.pointer.normalize(a);var c=this.chart,e=this.xAxis,f=this.zoomedMin,d=this.left,g=this.size,k=this.range,l=a.chartX;c.inverted&&(l=a.chartY,d=this.top);if(1===b)this.grabbedCenter=l,this.fixedWidth=k,this.dragOffset=l-f;else{a=l-d-k/2;if(0===b)a=Math.max(0,a);else if(2===b&&a+k>=g)if(a=g-k,this.reversedExtremes){a-=k;var m=this.getUnionExtremes().dataMin}else var n=this.getUnionExtremes().dataMax;
a!==f&&(this.fixedWidth=k,b=e.navigatorAxis.toFixedRange(a,a+k,m,n),C(b.min)&&c.xAxis[0].setExtremes(Math.min(b.min,b.max),Math.max(b.min,b.max),!0,null,{trigger:"navigator"}))}};e.prototype.handlesMousedown=function(a,b){this.chart.pointer.normalize(a);a=this.chart;var c=a.xAxis[0],e=this.reversedExtremes;0===b?(this.grabbedLeft=!0,this.otherHandlePos=this.zoomedMax,this.fixedExtreme=e?c.min:c.max):(this.grabbedRight=!0,this.otherHandlePos=this.zoomedMin,this.fixedExtreme=e?c.max:c.min);a.fixedRange=
null};e.prototype.onMouseMove=function(a){var b=this,e=b.chart,f=b.left,g=b.navigatorSize,d=b.range,l=b.dragOffset,m=e.inverted;a.touches&&0===a.touches[0].pageX||(a=e.pointer.normalize(a),e=a.chartX,m&&(f=b.top,e=a.chartY),b.grabbedLeft?(b.hasDragged=!0,b.render(0,0,e-f,b.otherHandlePos)):b.grabbedRight?(b.hasDragged=!0,b.render(0,0,b.otherHandlePos,e-f)):b.grabbedCenter&&(b.hasDragged=!0,e<l?e=l:e>g+l-d&&(e=g+l-d),b.render(0,0,e-l,e-l+d)),b.hasDragged&&b.scrollbar&&k(b.scrollbar.options.liveRedraw,
x.svg&&!c&&!this.chart.isBoosting)&&(a.DOMType=a.type,setTimeout(function(){b.onMouseUp(a)},0)))};e.prototype.onMouseUp=function(a){var b=this.chart,c=this.xAxis,e=this.scrollbar,f=a.DOMEvent||a,d=b.inverted,g=this.rendered&&!this.hasDragged?"animate":"attr",k=Math.round(this.zoomedMax),l=Math.round(this.zoomedMin);if(this.hasDragged&&(!e||!e.hasDragged)||"scrollbar"===a.trigger){e=this.getUnionExtremes();if(this.zoomedMin===this.otherHandlePos)var m=this.fixedExtreme;else if(this.zoomedMax===this.otherHandlePos)var n=
this.fixedExtreme;this.zoomedMax===this.size&&(n=this.reversedExtremes?e.dataMin:e.dataMax);0===this.zoomedMin&&(m=this.reversedExtremes?e.dataMax:e.dataMin);c=c.navigatorAxis.toFixedRange(this.zoomedMin,this.zoomedMax,m,n);C(c.min)&&b.xAxis[0].setExtremes(Math.min(c.min,c.max),Math.max(c.min,c.max),!0,this.hasDragged?!1:null,{trigger:"navigator",triggerOp:"navigator-drag",DOMEvent:f})}"mousemove"!==a.DOMType&&"touchmove"!==a.DOMType&&(this.grabbedLeft=this.grabbedRight=this.grabbedCenter=this.fixedWidth=
this.fixedExtreme=this.otherHandlePos=this.hasDragged=this.dragOffset=null);this.navigatorEnabled&&(this.shades&&this.drawMasks(l,k,d,g),this.outline&&this.drawOutline(l,k,d,g),this.navigatorOptions.handles.enabled&&Object.keys(this.handles).length===this.handles.length&&(this.drawHandle(l,0,d,g),this.drawHandle(k,1,d,g)))};e.prototype.removeEvents=function(){this.eventsToUnbind&&(this.eventsToUnbind.forEach(function(a){a()}),this.eventsToUnbind=void 0);this.removeBaseSeriesEvents()};e.prototype.removeBaseSeriesEvents=
function(){var a=this.baseSeries||[];this.navigatorEnabled&&a[0]&&(!1!==this.navigatorOptions.adaptToUpdatedData&&a.forEach(function(a){g(a,"updatedData",this.updatedDataHandler)},this),a[0].xAxis&&g(a[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes))};e.prototype.init=function(a){var b=a.options,c=b.navigator,e=c.enabled,f=b.scrollbar,d=f.enabled;b=e?c.height:0;var g=d?f.height:0;this.handles=[];this.shades=[];this.chart=a;this.setBaseSeries();this.height=b;this.scrollbarHeight=g;this.scrollbarEnabled=
d;this.navigatorEnabled=e;this.navigatorOptions=c;this.scrollbarOptions=f;this.outlineHeight=b+g;this.opposite=k(c.opposite,!(e||!a.inverted));var m=this;e=m.baseSeries;f=a.xAxis.length;d=a.yAxis.length;var n=e&&e[0]&&e[0].xAxis||a.xAxis[0]||{options:{}};a.isDirtyBox=!0;m.navigatorEnabled?(m.xAxis=new l(a,u({breaks:n.options.breaks,ordinal:n.options.ordinal},c.xAxis,{id:"navigator-x-axis",yAxis:"navigator-y-axis",isX:!0,type:"datetime",index:f,isInternal:!0,offset:0,keepOrdinalPadding:!0,startOnTick:!1,
endOnTick:!1,minPadding:0,maxPadding:0,zoomEnabled:!1},a.inverted?{offsets:[g,0,-g,0],width:b}:{offsets:[0,-g,0,g],height:b})),m.yAxis=new l(a,u(c.yAxis,{id:"navigator-y-axis",alignTicks:!1,offset:0,index:d,isInternal:!0,zoomEnabled:!1},a.inverted?{width:b}:{height:b})),e||c.series.data?m.updateNavigatorSeries(!1):0===a.series.length&&(m.unbindRedraw=B(a,"beforeRedraw",function(){0<a.series.length&&!m.series&&(m.setBaseSeries(),m.unbindRedraw())})),m.reversedExtremes=a.inverted&&!m.xAxis.reversed||
!a.inverted&&m.xAxis.reversed,m.renderElements(),m.addMouseEvents()):(m.xAxis={chart:a,navigatorAxis:{fake:!0},translate:function(b,c){var d=a.xAxis[0],e=d.getExtremes(),f=d.len-2*g,h=p("min",d.options.min,e.dataMin);d=p("max",d.options.max,e.dataMax)-h;return c?b*d/f+h:f*(b-h)/d},toPixels:function(a){return this.translate(a)},toValue:function(a){return this.translate(a,!0)}},m.xAxis.navigatorAxis.axis=m.xAxis,m.xAxis.navigatorAxis.toFixedRange=t.AdditionsClass.prototype.toFixedRange.bind(m.xAxis.navigatorAxis));
a.options.scrollbar.enabled&&(a.scrollbar=m.scrollbar=new N(a.renderer,u(a.options.scrollbar,{margin:m.navigatorEnabled?0:10,vertical:a.inverted}),a),B(m.scrollbar,"changed",function(b){var c=m.size,d=c*this.to;c*=this.from;m.hasDragged=m.scrollbar.hasDragged;m.render(0,0,c,d);(a.options.scrollbar.liveRedraw||"mousemove"!==b.DOMType&&"touchmove"!==b.DOMType)&&setTimeout(function(){m.onMouseUp(b)})}));m.addBaseSeriesEvents();m.addChartEvents()};e.prototype.getUnionExtremes=function(a){var b=this.chart.xAxis[0],
c=this.xAxis,e=c.options,f=b.options,d;a&&null===b.dataMin||(d={dataMin:k(e&&e.min,p("min",f.min,b.dataMin,c.dataMin,c.min)),dataMax:k(e&&e.max,p("max",f.max,b.dataMax,c.dataMax,c.max))});return d};e.prototype.setBaseSeries=function(a,b){var c=this.chart,e=this.baseSeries=[];a=a||c.options&&c.options.navigator.baseSeries||(c.series.length?z(c.series,function(a){return!a.options.isInternal}).index:0);(c.series||[]).forEach(function(b,c){b.options.isInternal||!b.options.showInNavigator&&(c!==a&&b.options.id!==
a||!1===b.options.showInNavigator)||e.push(b)});this.xAxis&&!this.xAxis.navigatorAxis.fake&&this.updateNavigatorSeries(!0,b)};e.prototype.updateNavigatorSeries=function(a,c){var e=this,l=e.chart,h=e.baseSeries,d,m,n=e.navigatorOptions.series,p,r={enableMouseTracking:!1,index:null,linkedTo:null,group:"nav",padXAxis:!1,xAxis:"navigator-x-axis",yAxis:"navigator-y-axis",showInLegend:!1,stacking:void 0,isInternal:!0,states:{inactive:{opacity:1}}},t=e.series=(e.series||[]).filter(function(a){var b=a.baseSeries;
return 0>h.indexOf(b)?(b&&(g(b,"updatedData",e.updatedDataHandler),delete b.navigatorSeries),a.chart&&a.destroy(),!1):!0});h&&h.length&&h.forEach(function(a){var b=a.navigatorSeries,g=A({color:a.color,visible:a.visible},q(n)?f.navigator.series:n);b&&!1===e.navigatorOptions.adaptToUpdatedData||(r.name="Navigator "+h.length,d=a.options||{},p=d.navigatorOptions||{},m=u(d,r,g,p),m.pointRange=k(g.pointRange,p.pointRange,f.plotOptions[m.type||"line"].pointRange),g=p.data||g.data,e.hasNavigatorData=e.hasNavigatorData||
!!g,m.data=g||d.data&&d.data.slice(0),b&&b.options?b.update(m,c):(a.navigatorSeries=l.initSeries(m),a.navigatorSeries.baseSeries=a,t.push(a.navigatorSeries)))});if(n.data&&(!h||!h.length)||q(n))e.hasNavigatorData=!1,n=b(n),n.forEach(function(a,b){r.name="Navigator "+(t.length+1);m=u(f.navigator.series,{color:l.series[b]&&!l.series[b].options.isInternal&&l.series[b].color||l.options.colors[b]||l.options.colors[0]},r,a);m.data=a.data;m.data&&(e.hasNavigatorData=!0,t.push(l.initSeries(m)))});a&&this.addBaseSeriesEvents()};
e.prototype.addBaseSeriesEvents=function(){var a=this,b=a.baseSeries||[];b[0]&&b[0].xAxis&&B(b[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes);b.forEach(function(b){B(b,"show",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!0,!1)});B(b,"hide",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!1,!1)});!1!==this.navigatorOptions.adaptToUpdatedData&&b.xAxis&&B(b,"updatedData",this.updatedDataHandler);B(b,"remove",function(){this.navigatorSeries&&(y(a.series,this.navigatorSeries),
C(this.navigatorSeries.options)&&this.navigatorSeries.remove(!1),delete this.navigatorSeries)})},this)};e.prototype.getBaseSeriesMin=function(a){return this.baseSeries.reduce(function(a,b){return Math.min(a,b.xData?b.xData[0]:a)},a)};e.prototype.modifyNavigatorAxisExtremes=function(){var a=this.xAxis,b;"undefined"!==typeof a.getExtremes&&(!(b=this.getUnionExtremes(!0))||b.dataMin===a.min&&b.dataMax===a.max||(a.min=b.dataMin,a.max=b.dataMax))};e.prototype.modifyBaseAxisExtremes=function(){var a=this.chart.navigator,
b=this.getExtremes(),c=b.dataMin,e=b.dataMax;b=b.max-b.min;var f=a.stickToMin,d=a.stickToMax,g=k(this.options.overscroll,0),l=a.series&&a.series[0],p=!!this.setExtremes;if(!this.eventArgs||"rangeSelectorButton"!==this.eventArgs.trigger){if(f){var q=c;var r=q+b}d&&(r=e+g,f||(q=Math.max(c,r-b,a.getBaseSeriesMin(l&&l.xData?l.xData[0]:-Number.MAX_VALUE))));p&&(f||d)&&m(q)&&(this.min=this.userMin=q,this.max=this.userMax=r)}a.stickToMin=a.stickToMax=null};e.prototype.updatedDataHandler=function(){var a=
this.chart.navigator,b=this.navigatorSeries,c=a.getBaseSeriesMin(this.xData[0]);a.stickToMax=a.reversedExtremes?0===Math.round(a.zoomedMin):Math.round(a.zoomedMax)>=Math.round(a.size);a.stickToMin=m(this.xAxis.min)&&this.xAxis.min<=c&&(!this.chart.fixedRange||!a.stickToMax);b&&!a.hasNavigatorData&&(b.options.pointStart=this.xData[0],b.setData(this.options.data,!1,null,!1))};e.prototype.addChartEvents=function(){this.eventsToUnbind||(this.eventsToUnbind=[]);this.eventsToUnbind.push(B(this.chart,"redraw",
function(){var a=this.navigator,b=a&&(a.baseSeries&&a.baseSeries[0]&&a.baseSeries[0].xAxis||this.xAxis[0]);b&&a.render(b.min,b.max)}),B(this.chart,"getMargins",function(){var a=this.navigator,b=a.opposite?"plotTop":"marginBottom";this.inverted&&(b=a.opposite?"marginRight":"plotLeft");this[b]=(this[b]||0)+(a.navigatorEnabled||!this.inverted?a.outlineHeight:0)+a.navigatorOptions.margin}))};e.prototype.destroy=function(){this.removeEvents();this.xAxis&&(y(this.chart.xAxis,this.xAxis),y(this.chart.axes,
this.xAxis));this.yAxis&&(y(this.chart.yAxis,this.yAxis),y(this.chart.axes,this.yAxis));(this.series||[]).forEach(function(a){a.destroy&&a.destroy()});"series xAxis yAxis shades outline scrollbarTrack scrollbarRifles scrollbarGroup scrollbar navigatorGroup rendered".split(" ").forEach(function(a){this[a]&&this[a].destroy&&this[a].destroy();this[a]=null},this);[this.handles].forEach(function(a){J(a)},this)};return e}();x.Navigator||(x.Navigator=w,t.compose(l),B(H,"beforeShowResetZoom",function(){var a=
this.options,b=a.navigator,e=a.rangeSelector;if((b&&b.enabled||e&&e.enabled)&&(!c&&"x"===a.chart.zoomType||c&&"x"===a.chart.pinchType))return!1}),B(H,"beforeRender",function(){var a=this.options;if(a.navigator.enabled||a.scrollbar.enabled)this.scroller=this.navigator=new w(this)}),B(H,"afterSetChartSize",function(){var a=this.legend,b=this.navigator;if(b){var c=a&&a.options;var e=b.xAxis;var f=b.yAxis;var g=b.scrollbarHeight;this.inverted?(b.left=b.opposite?this.chartWidth-g-b.height:this.spacing[3]+
g,b.top=this.plotTop+g):(b.left=this.plotLeft+g,b.top=b.navigatorOptions.top||this.chartHeight-b.height-g-this.spacing[2]-(this.rangeSelector&&this.extraBottomMargin?this.rangeSelector.getHeight():0)-(c&&"bottom"===c.verticalAlign&&c.enabled&&!c.floating?a.legendHeight+k(c.margin,10):0)-(this.titleOffset?this.titleOffset[2]:0));e&&f&&(this.inverted?e.options.left=f.options.left=b.left:e.options.top=f.options.top=b.top,e.setAxisSize(),f.setAxisSize())}}),B(H,"update",function(a){var b=a.options.navigator||
{},c=a.options.scrollbar||{};this.navigator||this.scroller||!b.enabled&&!c.enabled||(u(!0,this.options.navigator,b),u(!0,this.options.scrollbar,c),delete a.options.navigator,delete a.options.scrollbar)}),B(H,"afterUpdate",function(a){this.navigator||this.scroller||!this.options.navigator.enabled&&!this.options.scrollbar.enabled||(this.scroller=this.navigator=new w(this),k(a.redraw,!0)&&this.redraw(a.animation))}),B(H,"afterAddSeries",function(){this.navigator&&this.navigator.setBaseSeries(null,!1)}),
B(r,"afterUpdate",function(){this.chart.navigator&&!this.options.isInternal&&this.chart.navigator.setBaseSeries(null,!1)}),H.prototype.callbacks.push(function(a){var b=a.navigator;b&&a.xAxis[0]&&(a=a.xAxis[0].getExtremes(),b.render(a.min,a.max))}));x.Navigator=w;return x.Navigator});P(x,"masters/modules/gantt.src.js",[],function(){});P(x,"masters/highcharts-gantt.src.js",[x["masters/highcharts.src.js"]],function(l){l.product="Highcharts Gantt";return l});x["masters/highcharts-gantt.src.js"]._modules=
x;return x["masters/highcharts-gantt.src.js"]});
//# sourceMappingURL=highcharts-gantt.js.map