/*
 Highcharts Gantt JS v8.1.0 (2020-05-05)

 Gantt series

 (c) 2016-2019 Lars A. V. Cabrera

 License: www.highcharts.com/license
*/
(function(k){"object"===typeof module&&module.exports?(k["default"]=k,module.exports=k):"function"===typeof define&&define.amd?define("highcharts/modules/gantt",["highcharts"],function(G){k(G);k.Highcharts=G;return k}):k("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(k){function G(w,a,v,n){w.hasOwnProperty(a)||(w[a]=n.apply(null,v))}k=k?k._modules:{};G(k,"parts-gantt/CurrentDateIndicator.js",[k["parts/Globals.js"],k["parts/Utilities.js"],k["parts/PlotLineOrBand.js"]],function(w,a,v){var n=
a.addEvent,x=a.merge;a=a.wrap;var q={currentDateIndicator:!0,color:"#ccd6eb",width:2,label:{format:"%a, %b %d %Y, %H:%M",formatter:function(a,n){return w.dateFormat(n,a)},rotation:0,style:{fontSize:"10px"}}};n(w.Axis,"afterSetOptions",function(){var a=this.options,n=a.currentDateIndicator;n&&(n="object"===typeof n?x(q,n):x(q),n.value=new Date,a.plotLines||(a.plotLines=[]),a.plotLines.push(n))});n(v,"render",function(){this.label&&this.label.attr({text:this.getLabelText(this.options.label)})});a(v.prototype,
"getLabelText",function(a,n){var y=this.options;return y.currentDateIndicator&&y.label&&"function"===typeof y.label.formatter?(y.value=new Date,y.label.formatter.call(this,y.value,y.label.format)):a.call(this,n)})});G(k,"modules/static-scale.src.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(w,a){var v=a.addEvent,n=a.defined,x=a.isNumber,q=a.pick;a=w.Chart;v(w.Axis,"afterSetOptions",function(){var a=this.chart.options&&this.chart.options.chart;!this.horiz&&x(this.options.staticScale)&&
(!a.height||a.scrollablePlotArea&&a.scrollablePlotArea.minHeight)&&(this.staticScale=this.options.staticScale)});a.prototype.adjustHeight=function(){"adjustHeight"!==this.redrawTrigger&&((this.axes||[]).forEach(function(a){var v=a.chart,y=!!v.initiatedScale&&v.options.animation,g=a.options.staticScale;if(a.staticScale&&n(a.min)){var f=q(a.brokenAxis&&a.brokenAxis.unitLength,a.max+a.tickInterval-a.min)*g;f=Math.max(f,g);g=f-v.plotHeight;1<=Math.abs(g)&&(v.plotHeight=f,v.redrawTrigger="adjustHeight",
v.setSize(void 0,v.chartHeight+g,y));a.series.forEach(function(f){(f=f.sharedClipKey&&v[f.sharedClipKey])&&f.attr({height:v.plotHeight})})}}),this.initiatedScale=!0);this.redrawTrigger=null};v(a,"render",a.prototype.adjustHeight)});G(k,"parts-gantt/Tree.js",[k["parts/Utilities.js"]],function(w){var a=w.extend,v=w.isNumber,n=w.pick,x=function(a,v){var y=a.reduce(function(g,f){var r=n(f.parent,"");"undefined"===typeof g[r]&&(g[r]=[]);g[r].push(f);return g},{});Object.keys(y).forEach(function(g,f){var r=
y[g];""!==g&&-1===v.indexOf(g)&&(r.forEach(function(g){f[""].push(g)}),delete f[g])});return y},q=function(w,x,y,g,f,r){var u=0,D=0,F=r&&r.after,A=r&&r.before;x={data:g,depth:y-1,id:w,level:y,parent:x};var h,e;"function"===typeof A&&A(x,r);A=(f[w]||[]).map(function(l){var d=q(l.id,w,y+1,l,f,r),c=l.start;l=!0===l.milestone?c:l.end;h=!v(h)||c<h?c:h;e=!v(e)||l>e?l:e;u=u+1+d.descendants;D=Math.max(d.height+1,D);return d});g&&(g.start=n(g.start,h),g.end=n(g.end,e));a(x,{children:A,descendants:u,height:D});
"function"===typeof F&&F(x,r);return x};return{getListOfParents:x,getNode:q,getTree:function(a,n){var y=a.map(function(g){return g.id});a=x(a,y);return q("",null,1,null,a,n)}}});G(k,"parts-gantt/TreeGridTick.js",[k["parts/Utilities.js"]],function(w){var a=w.addEvent,v=w.defined,n=w.isObject,x=w.isNumber,q=w.pick,k=w.wrap,B;(function(y){function g(){this.treeGrid||(this.treeGrid=new F(this))}function f(f,h){f=f.treeGrid;var e=!f.labelIcon,l=h.renderer,d=h.xy,c=h.options,b=c.width,p=c.height,I=d.x-
b/2-c.padding;d=d.y-p/2;var H=h.collapsed?90:180,g=h.show&&x(d),E=f.labelIcon;E||(f.labelIcon=E=l.path(l.symbols[c.type](c.x,c.y,b,p)).addClass("highcharts-label-icon").add(h.group));g||E.attr({y:-9999});l.styledMode||E.attr({"stroke-width":1,fill:q(h.color,"#666666")}).css({cursor:"pointer",stroke:c.lineColor,strokeWidth:c.lineWidth});E[e?"attr":"animate"]({translateX:I,translateY:d,rotation:H})}function r(f,h,e,l,d,c,b,p,I){var H=q(this.options&&this.options.labels,c);c=this.pos;var g=this.axis,
E="treegrid"===g.options.type;f=f.apply(this,[h,e,l,d,H,b,p,I]);E&&(h=H&&n(H.symbol,!0)?H.symbol:{},H=H&&x(H.indentation)?H.indentation:0,c=(c=(g=g.treeGrid.mapOfPosToGridNode)&&g[c])&&c.depth||1,f.x+=h.width+2*h.padding+(c-1)*H);return f}function u(g){var h=this,e=h.pos,l=h.axis,d=h.label,c=l.treeGrid.mapOfPosToGridNode,b=l.options,p=q(h.options&&h.options.labels,b&&b.labels),I=p&&n(p.symbol,!0)?p.symbol:{},H=(c=c&&c[e])&&c.depth;b="treegrid"===b.type;var L=-1<l.tickPositions.indexOf(e);e=l.chart.styledMode;
b&&c&&d&&d.element&&d.addClass("highcharts-treegrid-node-level-"+H);g.apply(h,Array.prototype.slice.call(arguments,1));b&&d&&d.element&&c&&c.descendants&&0<c.descendants&&(l=l.treeGrid.isCollapsed(c),f(h,{color:!e&&d.styles&&d.styles.color||"",collapsed:l,group:d.parentGroup,options:I,renderer:d.renderer,show:L,xy:d.xy}),I="highcharts-treegrid-node-"+(l?"expanded":"collapsed"),d.addClass("highcharts-treegrid-node-"+(l?"collapsed":"expanded")).removeClass(I),e||d.css({cursor:"pointer"}),[d,h.treeGrid.labelIcon].forEach(function(b){b&&
!b.attachedTreeGridEvents&&(a(b.element,"mouseover",function(){d.addClass("highcharts-treegrid-node-active");d.renderer.styledMode||d.css({textDecoration:"underline"})}),a(b.element,"mouseout",function(){var b=v(p.style)?p.style:{};d.removeClass("highcharts-treegrid-node-active");d.renderer.styledMode||d.css({textDecoration:b.textDecoration})}),a(b.element,"click",function(){h.treeGrid.toggleCollapse()}),b.attachedTreeGridEvents=!0)}))}var D=!1;y.compose=function(f){D||(a(f,"init",g),k(f.prototype,
"getLabelPosition",r),k(f.prototype,"renderLabel",u),f.prototype.collapse=function(h){this.treeGrid.collapse(h)},f.prototype.expand=function(h){this.treeGrid.expand(h)},f.prototype.toggleCollapse=function(h){this.treeGrid.toggleCollapse(h)},D=!0)};var F=function(){function f(h){this.tick=h}f.prototype.collapse=function(h){var e=this.tick,l=e.axis,d=l.brokenAxis;d&&l.treeGrid.mapOfPosToGridNode&&(e=l.treeGrid.collapse(l.treeGrid.mapOfPosToGridNode[e.pos]),d.setBreaks(e,q(h,!0)))};f.prototype.expand=
function(h){var e=this.tick,l=e.axis,d=l.brokenAxis;d&&l.treeGrid.mapOfPosToGridNode&&(e=l.treeGrid.expand(l.treeGrid.mapOfPosToGridNode[e.pos]),d.setBreaks(e,q(h,!0)))};f.prototype.toggleCollapse=function(h){var e=this.tick,l=e.axis,d=l.brokenAxis;d&&l.treeGrid.mapOfPosToGridNode&&(e=l.treeGrid.toggleCollapse(l.treeGrid.mapOfPosToGridNode[e.pos]),d.setBreaks(e,q(h,!0)))};return f}();y.Additions=F})(B||(B={}));return B});G(k,"mixins/tree-series.js",[k["parts/Color.js"],k["parts/Utilities.js"]],function(w,
a){var v=a.extend,n=a.isArray,x=a.isNumber,q=a.isObject,k=a.merge,B=a.pick;return{getColor:function(a,g){var f=g.index,r=g.mapOptionsToLevel,u=g.parentColor,D=g.parentColorIndex,n=g.series,A=g.colors,h=g.siblings,e=n.points,l=n.chart.options.chart,d;if(a){e=e[a.i];a=r[a.level]||{};if(r=e&&a.colorByPoint){var c=e.index%(A?A.length:l.colorCount);var b=A&&A[c]}if(!n.chart.styledMode){A=e&&e.options.color;l=a&&a.color;if(d=u)d=(d=a&&a.colorVariation)&&"brightness"===d.key?w.parse(u).brighten(f/h*d.to).get():
u;d=B(A,l,b,d,n.color)}var p=B(e&&e.options.colorIndex,a&&a.colorIndex,c,D,g.colorIndex)}return{color:d,colorIndex:p}},getLevelOptions:function(a){var g=null;if(q(a)){g={};var f=x(a.from)?a.from:1;var r=a.levels;var u={};var D=q(a.defaults)?a.defaults:{};n(r)&&(u=r.reduce(function(g,a){if(q(a)&&x(a.level)){var h=k({},a);var e="boolean"===typeof h.levelIsConstant?h.levelIsConstant:D.levelIsConstant;delete h.levelIsConstant;delete h.level;a=a.level+(e?0:f-1);q(g[a])?v(g[a],h):g[a]=h}return g},{}));
r=x(a.to)?a.to:1;for(a=0;a<=r;a++)g[a]=k({},D,q(u[a])?u[a]:{})}return g},setTreeValues:function r(g,f){var a=f.before,D=f.idRoot,n=f.mapIdToNode[D],A=f.points[g.i],h=A&&A.options||{},e=0,l=[];v(g,{levelDynamic:g.level-(("boolean"===typeof f.levelIsConstant?f.levelIsConstant:1)?0:n.level),name:B(A&&A.name,""),visible:D===g.id||("boolean"===typeof f.visible?f.visible:!1)});"function"===typeof a&&(g=a(g,f));g.children.forEach(function(d,c){var b=v({},f);v(b,{index:c,siblings:g.children.length,visible:g.visible});
d=r(d,b);l.push(d);d.visible&&(e+=d.val)});g.visible=0<e||g.visible;a=B(h.value,e);v(g,{children:l,childrenTotal:e,isLeaf:g.visible&&!e,val:a});return g},updateRootId:function(a){if(q(a)){var f=q(a.options)?a.options:{};f=B(a.rootNode,f.rootId,"");q(a.userOptions)&&(a.userOptions.rootId=f);a.rootNode=f}return f}}});G(k,"parts-gantt/GridAxis.js",[k["parts/Axis.js"],k["parts/Globals.js"],k["parts/Tick.js"],k["parts/Utilities.js"]],function(w,a,v,n){var x=n.addEvent,q=n.defined,k=n.erase,B=n.find,y=
n.isArray,g=n.isNumber,f=n.merge,r=n.pick,u=n.timeUnits,D=n.wrap,F=a.dateFormat,A=a.Chart,h=function(d){var c=d.options;c.labels||(c.labels={});c.labels.align=r(c.labels.align,"center");d.categories||(c.showLastLabel=!1);d.labelRotation=0;c.labels.rotation=0};"";w.prototype.getMaxLabelDimensions=function(d,c){var b={width:0,height:0};c.forEach(function(c){c=d[c];if(n.isObject(c,!0)){var p=n.isObject(c.label,!0)?c.label:{};c=p.getBBox?p.getBBox().height:0;p.textStr&&!g(p.textPxLength)&&(p.textPxLength=
p.getBBox().width);p=g(p.textPxLength)?Math.round(p.textPxLength):0;b.height=Math.max(c,b.height);b.width=Math.max(p,b.width)}});return b};a.dateFormats.W=function(d){d=new this.Date(d);var c=(this.get("Day",d)+6)%7,b=new this.Date(d.valueOf());this.set("Date",b,this.get("Date",d)-c+3);c=new this.Date(this.get("FullYear",b),0,1);4!==this.get("Day",c)&&(this.set("Month",d,0),this.set("Date",d,1+(11-this.get("Day",c))%7));return(1+Math.floor((b.valueOf()-c.valueOf())/6048E5)).toString()};a.dateFormats.E=
function(d){return F("%a",d,!0).charAt(0)};x(A,"afterSetChartSize",function(){this.axes.forEach(function(d){(d.grid&&d.grid.columns||[]).forEach(function(c){c.setAxisSize();c.setAxisTranslation()})})});x(v,"afterGetLabelPosition",function(d){var c=this.label,b=this.axis,p=b.reversed,e=b.chart,H=b.options.grid||{},h=b.options.labels,f=h.align,z=l.Side[b.side],m=d.tickmarkOffset,t=b.tickPositions,C=this.pos-m;t=g(t[d.index+1])?t[d.index+1]-m:b.max+m;var K=b.tickSize("tick");m=K?K[0]:0;K=K?K[1]/2:0;
if(!0===H.enabled){if("top"===z){H=b.top+b.offset;var J=H-m}else"bottom"===z?(J=e.chartHeight-b.bottom+b.offset,H=J+m):(H=b.top+b.len-b.translate(p?t:C),J=b.top+b.len-b.translate(p?C:t));"right"===z?(z=e.chartWidth-b.right+b.offset,p=z+m):"left"===z?(p=b.left+b.offset,z=p-m):(z=Math.round(b.left+b.translate(p?t:C))-K,p=Math.round(b.left+b.translate(p?C:t))-K);this.slotWidth=p-z;d.pos.x="left"===f?z:"right"===f?p:z+(p-z)/2;d.pos.y=J+(H-J)/2;e=e.renderer.fontMetrics(h.style.fontSize,c.element);c=c.getBBox().height;
h.useHTML?d.pos.y+=e.b+-(c/2):(c=Math.round(c/e.h),d.pos.y+=(e.b-(e.h-e.f))/2+-((c-1)*e.h/2));d.pos.x+=b.horiz&&h.x||0}});var e=function(){function d(c){this.axis=c}d.prototype.isOuterAxis=function(){var c=this.axis,b=c.grid.columnIndex,d=c.linkedParent&&c.linkedParent.grid.columns||c.grid.columns,e=b?c.linkedParent:c,l=-1,h=0;c.chart[c.coll].forEach(function(b,d){b.side!==c.side||b.options.isInternal||(h=d,b===e&&(l=d))});return h===l&&(g(b)?d.length===b:!0)};return d}(),l=function(){function d(){}
d.compose=function(c){w.keepProps.push("grid");D(c.prototype,"unsquish",d.wrapUnsquish);x(c,"init",d.onInit);x(c,"afterGetOffset",d.onAfterGetOffset);x(c,"afterGetTitlePosition",d.onAfterGetTitlePosition);x(c,"afterInit",d.onAfterInit);x(c,"afterRender",d.onAfterRender);x(c,"afterSetAxisTranslation",d.onAfterSetAxisTranslation);x(c,"afterSetOptions",d.onAfterSetOptions);x(c,"afterSetOptions",d.onAfterSetOptions2);x(c,"afterSetScale",d.onAfterSetScale);x(c,"afterTickSize",d.onAfterTickSize);x(c,"trimTicks",
d.onTrimTicks);x(c,"destroy",d.onDestroy)};d.onAfterGetOffset=function(){var c=this.grid;(c&&c.columns||[]).forEach(function(b){b.getOffset()})};d.onAfterGetTitlePosition=function(c){if(!0===(this.options.grid||{}).enabled){var b=this.axisTitle,p=this.height,e=this.horiz,l=this.left,h=this.offset,f=this.opposite,z=this.options.title,m=void 0===z?{}:z;z=this.top;var t=this.width,C=this.tickSize(),K=b&&b.getBBox().width,J=m.x||0,a=m.y||0,g=r(m.margin,e?5:10);b=this.chart.renderer.fontMetrics(m.style&&
m.style.fontSize,b).f;C=(e?z+p:l)+(e?1:-1)*(f?-1:1)*(C?C[0]/2:0)+(this.side===d.Side.bottom?b:0);c.titlePosition.x=e?l-K/2-g+J:C+(f?t:0)+h+J;c.titlePosition.y=e?C-(f?p:0)+(f?b:-b)/2+h+a:z-g+a}};d.onAfterInit=function(){var c=this.chart,b=this.options.grid;b=void 0===b?{}:b;var d=this.userOptions;b.enabled&&(h(this),D(this,"labelFormatter",function(b){var c=this.axis,d=this.value,t=c.tickPositions,p=(c.isLinked?c.linkedParent:c).series[0],e=d===t[0];t=d===t[t.length-1];p=p&&B(p.options.data,function(b){return b[c.isXAxis?
"x":"y"]===d});this.isFirst=e;this.isLast=t;this.point=p;return b.call(this)}));if(b.columns)for(var e=this.grid.columns=[],l=this.grid.columnIndex=0;++l<b.columns.length;){var a=f(d,b.columns[b.columns.length-l-1],{linkedTo:0,type:"category"});delete a.grid.columns;a=new w(this.chart,a);a.grid.isColumn=!0;a.grid.columnIndex=l;k(c.axes,a);k(c[this.coll],a);e.push(a)}};d.onAfterRender=function(){var c=this.grid,b=this.options,p=this.chart.renderer;if(!0===(b.grid||{}).enabled){this.maxLabelDimensions=
this.getMaxLabelDimensions(this.ticks,this.tickPositions);this.rightWall&&this.rightWall.destroy();if(this.grid&&this.grid.isOuterAxis()&&this.axisLine){var e=b.lineWidth;if(e){var l=this.getLinePath(e),h=l[0],a=l[1],z=((this.tickSize("tick")||[1])[0]-1)*(this.side===d.Side.top||this.side===d.Side.left?-1:1);"M"===h[0]&&"L"===a[0]&&(this.horiz?(h[2]+=z,a[2]+=z):(h[1]+=z,a[1]+=z));this.grid.axisLineExtra?this.grid.axisLineExtra.animate({d:l}):(this.grid.axisLineExtra=p.path(l).attr({zIndex:7}).addClass("highcharts-axis-line").add(this.axisGroup),
p.styledMode||this.grid.axisLineExtra.attr({stroke:b.lineColor,"stroke-width":e}));this.axisLine[this.showAxis?"show":"hide"](!0)}}(c&&c.columns||[]).forEach(function(b){b.render()})}};d.onAfterSetAxisTranslation=function(){var c=this.tickPositions&&this.tickPositions.info,b=this.options,d=b.grid||{},e=this.userOptions.labels||{};this.horiz&&(!0===d.enabled&&this.series.forEach(function(b){b.options.pointRange=0}),c&&b.dateTimeLabelFormats&&b.labels&&!q(e.align)&&(!1===b.dateTimeLabelFormats[c.unitName].range||
1<c.count)&&(b.labels.align="left",q(e.x)||(b.labels.x=3)))};d.onAfterSetOptions=function(c){var b=this.options;c=c.userOptions;var d=b&&n.isObject(b.grid,!0)?b.grid:{};if(!0===d.enabled){var e=f(!0,{className:"highcharts-grid-axis "+(c.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]]},c);"xAxis"===this.coll&&(q(c.linkedTo)&&!q(c.tickPixelInterval)&&(e.tickPixelInterval=350),q(c.tickPixelInterval)||!q(c.linkedTo)||q(c.tickPositioner)||q(c.tickInterval)||(e.tickPositioner=function(b,c){var d=this.linkedParent&&this.linkedParent.tickPositions&&this.linkedParent.tickPositions.info;if(d){var p,m=e.units;for(p=0;p<m.length;p++)if(m[p][0]===
d.unitName){var t=p;break}if(m[t+1]){var C=m[t+1][0];var l=(m[t+1][1]||[1])[0]}else"year"===d.unitName&&(C="year",l=10*d.count);d=u[C];this.tickInterval=d*l;return this.getTimeTicks({unitRange:d,count:l,unitName:C},b,c,this.options.startOfWeek)}}));f(!0,this.options,e);this.horiz&&(b.minPadding=r(c.minPadding,0),b.maxPadding=r(c.maxPadding,0));g(b.grid.borderWidth)&&(b.tickWidth=b.lineWidth=d.borderWidth)}};d.onAfterSetOptions2=function(c){c=(c=c.userOptions)&&c.grid||{};var b=c.columns;c.enabled&&
b&&f(!0,this.options,b[b.length-1])};d.onAfterSetScale=function(){(this.grid.columns||[]).forEach(function(c){c.setScale()})};d.onAfterTickSize=function(c){var b=w.defaultLeftAxisOptions,d=this.horiz,e=this.maxLabelDimensions,l=this.options.grid;l=void 0===l?{}:l;l.enabled&&e&&(b=2*Math.abs(b.labels.x),d=d?l.cellHeight||b+e.height:b+e.width,y(c.tickSize)?c.tickSize[0]=d:c.tickSize=[d,0])};d.onDestroy=function(c){var b=this.grid;(b.columns||[]).forEach(function(b){b.destroy(c.keepEvents)});b.columns=
void 0};d.onInit=function(c){c=c.userOptions||{};var b=c.grid||{};b.enabled&&q(b.borderColor)&&(c.tickColor=c.lineColor=b.borderColor);this.grid||(this.grid=new e(this))};d.onTrimTicks=function(){var c=this.options,b=this.categories,d=this.tickPositions,e=d[0],l=d[d.length-1],h=this.linkedParent&&this.linkedParent.min||this.min,a=this.linkedParent&&this.linkedParent.max||this.max,z=this.tickInterval;!0!==(c.grid||{}).enabled||b||!this.horiz&&!this.isLinked||(e<h&&e+z>h&&!c.startOnTick&&(d[0]=h),l>
a&&l-z<a&&!c.endOnTick&&(d[d.length-1]=a))};d.wrapUnsquish=function(c){var b=this.options.grid;return!0===(void 0===b?{}:b).enabled&&this.categories?this.tickInterval:c.apply(this,Array.prototype.slice.call(arguments,1))};return d}();(function(d){d=d.Side||(d.Side={});d[d.top=0]="top";d[d.right=1]="right";d[d.bottom=2]="bottom";d[d.left=3]="left"})(l||(l={}));l.compose(w);return l});G(k,"modules/broken-axis.src.js",[k["parts/Axis.js"],k["parts/Globals.js"],k["parts/Utilities.js"],k["parts/Stacking.js"]],
function(k,a,v,n){var x=v.addEvent,q=v.find,w=v.fireEvent,B=v.isArray,y=v.isNumber,g=v.pick,f=a.Series,r=function(){function a(a){this.hasBreaks=!1;this.axis=a}a.isInBreak=function(a,f){var g=a.repeat||Infinity,h=a.from,e=a.to-a.from;f=f>=h?(f-h)%g:g-(h-f)%g;return a.inclusive?f<=e:f<e&&0!==f};a.lin2Val=function(f){var g=this.brokenAxis;g=g&&g.breakArray;if(!g)return f;var r;for(r=0;r<g.length;r++){var h=g[r];if(h.from>=f)break;else h.to<f?f+=h.len:a.isInBreak(h,f)&&(f+=h.len)}return f};a.val2Lin=
function(f){var g=this.brokenAxis;g=g&&g.breakArray;if(!g)return f;var r=f,h;for(h=0;h<g.length;h++){var e=g[h];if(e.to<=f)r-=e.len;else if(e.from>=f)break;else if(a.isInBreak(e,f)){r-=f-e.from;break}}return r};a.prototype.findBreakAt=function(a,f){return q(f,function(f){return f.from<a&&a<f.to})};a.prototype.isInAnyBreak=function(f,r){var u=this.axis,h=u.options.breaks,e=h&&h.length,l;if(e){for(;e--;)if(a.isInBreak(h[e],f)){var d=!0;l||(l=g(h[e].showPoints,!u.isXAxis))}var c=d&&r?d&&!l:d}return c};
a.prototype.setBreaks=function(f,r){var u=this,h=u.axis,e=B(f)&&!!f.length;h.isDirty=u.hasBreaks!==e;u.hasBreaks=e;h.options.breaks=h.userOptions.breaks=f;h.forceRedraw=!0;h.series.forEach(function(e){e.isDirty=!0});e||h.val2lin!==a.val2Lin||(delete h.val2lin,delete h.lin2val);e&&(h.userOptions.ordinal=!1,h.lin2val=a.lin2Val,h.val2lin=a.val2Lin,h.setExtremes=function(e,d,c,b,p){if(u.hasBreaks){for(var a,f=this.options.breaks;a=u.findBreakAt(e,f);)e=a.to;for(;a=u.findBreakAt(d,f);)d=a.from;d<e&&(d=
e)}k.prototype.setExtremes.call(this,e,d,c,b,p)},h.setAxisTranslation=function(e){k.prototype.setAxisTranslation.call(this,e);u.unitLength=null;if(u.hasBreaks){e=h.options.breaks||[];var d=[],c=[],b=0,p,f=h.userMin||h.min,l=h.userMax||h.max,r=g(h.pointRangePadding,0),E;e.forEach(function(b){p=b.repeat||Infinity;a.isInBreak(b,f)&&(f+=b.to%p-f%p);a.isInBreak(b,l)&&(l-=l%p-b.from%p)});e.forEach(function(b){m=b.from;for(p=b.repeat||Infinity;m-p>f;)m-=p;for(;m<f;)m+=p;for(E=m;E<l;E+=p)d.push({value:E,
move:"in"}),d.push({value:E+(b.to-b.from),move:"out",size:b.breakSize})});d.sort(function(b,c){return b.value===c.value?("in"===b.move?0:1)-("in"===c.move?0:1):b.value-c.value});var z=0;var m=f;d.forEach(function(d){z+="in"===d.move?1:-1;1===z&&"in"===d.move&&(m=d.value);0===z&&(c.push({from:m,to:d.value,len:d.value-m-(d.size||0)}),b+=d.value-m-(d.size||0))});h.breakArray=u.breakArray=c;u.unitLength=l-f-b+r;w(h,"afterBreaks");h.staticScale?h.transA=h.staticScale:u.unitLength&&(h.transA*=(l-h.min+
r)/u.unitLength);r&&(h.minPixelPadding=h.transA*h.minPointOffset);h.min=f;h.max=l}});g(r,!0)&&h.chart.redraw()};return a}();a=function(){function a(){}a.compose=function(a,u){a.keepProps.push("brokenAxis");var v=f.prototype;v.drawBreaks=function(a,e){var f=this,d=f.points,c,b,p,h;if(a&&a.brokenAxis&&a.brokenAxis.hasBreaks){var r=a.brokenAxis;e.forEach(function(e){c=r&&r.breakArray||[];b=a.isXAxis?a.min:g(f.options.threshold,a.min);d.forEach(function(d){h=g(d["stack"+e.toUpperCase()],d[e]);c.forEach(function(c){if(y(b)&&
y(h)){p=!1;if(b<c.from&&h>c.to||b>c.from&&h<c.from)p="pointBreak";else if(b<c.from&&h>c.from&&h<c.to||b>c.from&&h>c.to&&h<c.from)p="pointInBreak";p&&w(a,p,{point:d,brk:c})}})})})}};v.gappedPath=function(){var a=this.currentDataGrouping,e=a&&a.gapSize;a=this.options.gapSize;var f=this.points.slice(),d=f.length-1,c=this.yAxis,b;if(a&&0<d)for("value"!==this.options.gapUnit&&(a*=this.basePointRange),e&&e>a&&e>=this.basePointRange&&(a=e),b=void 0;d--;)b&&!1!==b.visible||(b=f[d+1]),e=f[d],!1!==b.visible&&
!1!==e.visible&&(b.x-e.x>a&&(b=(e.x+b.x)/2,f.splice(d+1,0,{isNull:!0,x:b}),c.stacking&&this.options.stacking&&(b=c.stacking.stacks[this.stackKey][b]=new n(c,c.options.stackLabels,!1,b,this.stack),b.total=0)),b=e);return this.getGraphPath(f)};x(a,"init",function(){this.brokenAxis||(this.brokenAxis=new r(this))});x(a,"afterInit",function(){"undefined"!==typeof this.brokenAxis&&this.brokenAxis.setBreaks(this.options.breaks,!1)});x(a,"afterSetTickPositions",function(){var a=this.brokenAxis;if(a&&a.hasBreaks){var e=
this.tickPositions,f=this.tickPositions.info,d=[],c;for(c=0;c<e.length;c++)a.isInAnyBreak(e[c])||d.push(e[c]);this.tickPositions=d;this.tickPositions.info=f}});x(a,"afterSetOptions",function(){this.brokenAxis&&this.brokenAxis.hasBreaks&&(this.options.ordinal=!1)});x(u,"afterGeneratePoints",function(){var a=this.options.connectNulls,e=this.points,f=this.xAxis,d=this.yAxis;if(this.isDirty)for(var c=e.length;c--;){var b=e[c],p=!(null===b.y&&!1===a)&&(f&&f.brokenAxis&&f.brokenAxis.isInAnyBreak(b.x,!0)||
d&&d.brokenAxis&&d.brokenAxis.isInAnyBreak(b.y,!0));b.visible=p?!1:!1!==b.options.visible}});x(u,"afterRender",function(){this.drawBreaks(this.xAxis,["x"]);this.drawBreaks(this.yAxis,g(this.pointArrayMap,["y"]))})};return a}();a.compose(k,f);return a});G(k,"parts-gantt/TreeGridAxis.js",[k["parts/Axis.js"],k["parts/Tick.js"],k["parts-gantt/Tree.js"],k["parts-gantt/TreeGridTick.js"],k["mixins/tree-series.js"],k["parts/Utilities.js"]],function(k,a,v,n,x,q){var w=q.addEvent,B=q.find,y=q.fireEvent,g=q.isNumber,
f=q.isObject,r=q.isString,u=q.merge,D=q.pick,F=q.wrap,A;(function(h){function e(b,c){var d=b.collapseStart||0;b=b.collapseEnd||0;b>=c&&(d-=.5);return{from:d,to:b,showPoints:!1}}function l(b,c,d){var m=[],e=[],p={},a={},z=-1,l="boolean"===typeof c?c:!1;b=v.getTree(b,{after:function(b){b=a[b.pos];var c=0,d=0;b.children.forEach(function(b){d+=(b.descendants||0)+1;c=Math.max((b.height||0)+1,c)});b.descendants=d;b.height=c;b.collapsed&&e.push(b)},before:function(b){var c=f(b.data,!0)?b.data:{},d=r(c.name)?
c.name:"",t=p[b.parent];t=f(t,!0)?a[t.pos]:null;var e=function(b){return b.name===d},C;l&&f(t,!0)&&(C=B(t.children,e))?(e=C.pos,C.nodes.push(b)):e=z++;a[e]||(a[e]=C={depth:t?t.depth+1:0,name:d,nodes:[b],children:[],pos:e},-1!==e&&m.push(d),f(t,!0)&&t.children.push(C));r(b.id)&&(p[b.id]=b);C&&!0===c.collapsed&&(C.collapsed=!0);b.pos=e}});a=function(b,c){var d=function(b,m,t){var e=m+(-1===m?0:c-1),p=(e-m)/2,a=m+p;b.nodes.forEach(function(b){var c=b.data;f(c,!0)&&(c.y=m+(c.seriesIndex||0),delete c.seriesIndex);
b.pos=a});t[a]=b;b.pos=a;b.tickmarkOffset=p+.5;b.collapseStart=e+.5;b.children.forEach(function(b){d(b,e+1,t);e=(b.collapseEnd||0)-.5});b.collapseEnd=e+.5;return t};return d(b["-1"],-1,{})}(a,d);return{categories:m,mapOfIdToNode:p,mapOfPosToGridNode:a,collapsedNodes:e,tree:b}}function d(b){b.target.axes.filter(function(b){return"treegrid"===b.options.type}).forEach(function(c){var d=c.options||{},e=d.labels,p=d.uniqueNames,a=0;if(!c.treeGrid.mapOfPosToGridNode||c.series.some(function(b){return!b.hasRendered||
b.isDirtyData||b.isDirty}))d=c.series.reduce(function(b,c){c.visible&&((c.options.data||[]).forEach(function(c){f(c,!0)&&(c.seriesIndex=a,b.push(c))}),!0===p&&a++);return b},[]),d=l(d,p||!1,!0===p?a:1),c.categories=d.categories,c.treeGrid.mapOfPosToGridNode=d.mapOfPosToGridNode,c.hasNames=!0,c.treeGrid.tree=d.tree,c.series.forEach(function(b){var c=(b.options.data||[]).map(function(b){return f(b,!0)?u(b):b});b.visible&&b.setData(c,!1)}),c.treeGrid.mapOptionsToLevel=x.getLevelOptions({defaults:e,from:1,
levels:e&&e.levels,to:c.treeGrid.tree&&c.treeGrid.tree.height}),"beforeRender"===b.type&&(c.treeGrid.collapsedNodes=d.collapsedNodes)})}function c(b,c){var d=this.treeGrid.mapOptionsToLevel||{},e=this.ticks,p=e[c],f;if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var l=this.treeGrid.mapOfPosToGridNode[c];(d=d[l.depth])&&(f={labels:d});p?(p.parameters.category=l.name,p.options=f,p.addLabel()):e[c]=new a(this,c,void 0,void 0,{category:l.name,tickmarkOffset:l.tickmarkOffset,options:f})}else b.apply(this,
Array.prototype.slice.call(arguments,1))}function b(b){var c=this.options;c=(c=c&&c.labels)&&g(c.indentation)?c.indentation:0;var d=b.apply(this,Array.prototype.slice.call(arguments,1));if("treegrid"===this.options.type&&this.treeGrid.mapOfPosToGridNode){var e=this.treeGrid.mapOfPosToGridNode[-1].height||0;d.width+=c*(e-1)}return d}function p(b,c,m){var e=this,p="treegrid"===m.type;e.treeGrid||(e.treeGrid=new L(e));p&&(w(c,"beforeRender",d),w(c,"beforeRedraw",d),w(c,"addSeries",function(b){b.options.data&&
(b=l(b.options.data,m.uniqueNames||!1,1),e.treeGrid.collapsedNodes=(e.treeGrid.collapsedNodes||[]).concat(b.collapsedNodes))}),w(e,"foundExtremes",function(){e.treeGrid.collapsedNodes&&e.treeGrid.collapsedNodes.forEach(function(b){var c=e.treeGrid.collapse(b);e.brokenAxis&&(e.brokenAxis.setBreaks(c,!1),e.treeGrid.collapsedNodes&&(e.treeGrid.collapsedNodes=e.treeGrid.collapsedNodes.filter(function(c){return b.collapseStart!==c.collapseStart||b.collapseEnd!==c.collapseEnd})))})}),m=u({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},m,{reversed:!0,grid:{columns:void 0}}));b.apply(e,[c,m]);p&&(e.hasNames=!0,e.options.showLastLabel=!0)}function I(b){var c=this.options;"treegrid"===c.type?(this.min=D(this.userMin,c.min,this.dataMin),this.max=D(this.userMax,c.max,this.dataMax),y(this,"foundExtremes"),this.setAxisTranslation(!0),this.tickmarkOffset=.5,this.tickInterval=1,
this.tickPositions=this.treeGrid.mapOfPosToGridNode?this.treeGrid.getTickPositions():[]):b.apply(this,Array.prototype.slice.call(arguments,1))}var H=!1;h.compose=function(d){H||(F(d.prototype,"generateTick",c),F(d.prototype,"getMaxLabelDimensions",b),F(d.prototype,"init",p),F(d.prototype,"setTickInterval",I),n.compose(a),H=!0)};var L=function(){function b(b){this.axis=b}b.prototype.collapse=function(b){var c=this.axis,d=c.options.breaks||[];b=e(b,c.max);d.push(b);return d};b.prototype.expand=function(b){var c=
this.axis,d=c.options.breaks||[],p=e(b,c.max);return d.reduce(function(b,c){c.to===p.to&&c.from===p.from||b.push(c);return b},[])};b.prototype.getTickPositions=function(){var b=this.axis;return Object.keys(b.treeGrid.mapOfPosToGridNode||{}).reduce(function(c,d){d=+d;!(b.min<=d&&b.max>=d)||b.brokenAxis&&b.brokenAxis.isInAnyBreak(d)||c.push(d);return c},[])};b.prototype.isCollapsed=function(b){var c=this.axis,d=c.options.breaks||[],p=e(b,c.max);return d.some(function(b){return b.from===p.from&&b.to===
p.to})};b.prototype.toggleCollapse=function(b){return this.isCollapsed(b)?this.expand(b):this.collapse(b)};return b}();h.Additions=L})(A||(A={}));k.prototype.utils={getNode:v.getNode};A.compose(k);return A});G(k,"parts-gantt/PathfinderAlgorithms.js",[k["parts/Utilities.js"]],function(k){function a(a,g,u){u=u||0;var f=a.length-1;g-=1e-7;for(var r,n;u<=f;)if(r=f+u>>1,n=g-a[r].xMin,0<n)u=r+1;else if(0>n)f=r-1;else return r;return 0<u?u-1:0}function v(f,g){for(var r=a(f,g.x+1)+1;r--;){var n;if(n=f[r].xMax>=
g.x)n=f[r],n=g.x<=n.xMax&&g.x>=n.xMin&&g.y<=n.yMax&&g.y>=n.yMin;if(n)return r}return-1}function n(a){var f=[];if(a.length){f.push(["M",a[0].start.x,a[0].start.y]);for(var g=0;g<a.length;++g)f.push(["L",a[g].end.x,a[g].end.y])}return f}function x(a,g){a.yMin=y(a.yMin,g.yMin);a.yMax=B(a.yMax,g.yMax);a.xMin=y(a.xMin,g.xMin);a.xMax=B(a.xMax,g.xMax)}var q=k.extend,w=k.pick,B=Math.min,y=Math.max,g=Math.abs;return{straight:function(a,g){return{path:[["M",a.x,a.y],["L",g.x,g.y]],obstacles:[{start:a,end:g}]}},
simpleConnect:q(function(a,r,u){function f(b,c,d,e,a){b={x:b.x,y:b.y};b[c]=d[e||c]+(a||0);return b}function y(b,c,d){var e=g(c[d]-b[d+"Min"])>g(c[d]-b[d+"Max"]);return f(c,d,b,d+(e?"Max":"Min"),e?1:-1)}var q=[],h=w(u.startDirectionX,g(r.x-a.x)>g(r.y-a.y))?"x":"y",e=u.chartObstacles,l=v(e,a);u=v(e,r);if(-1<u){var d=e[u];u=y(d,r,h);d={start:u,end:r};var c=u}else c=r;-1<l&&(e=e[l],u=y(e,a,h),q.push({start:a,end:u}),u[h]>=a[h]===u[h]>=c[h]&&(h="y"===h?"x":"y",r=a[h]<r[h],q.push({start:u,end:f(u,h,e,h+
(r?"Max":"Min"),r?1:-1)}),h="y"===h?"x":"y"));a=q.length?q[q.length-1].end:a;u=f(a,h,c);q.push({start:a,end:u});h=f(u,"y"===h?"x":"y",c);q.push({start:u,end:h});q.push(d);return{path:n(q),obstacles:q}},{requiresObstacles:!0}),fastAvoid:q(function(f,r,u){function q(b,c,d){var e,m=b.x<c.x?1:-1;if(b.x<c.x){var p=b;var t=c}else p=c,t=b;if(b.y<c.y){var f=b;var l=c}else f=c,l=b;for(e=0>m?B(a(E,t.x),E.length-1):0;E[e]&&(0<m&&E[e].xMin<=t.x||0>m&&E[e].xMax>=p.x);){if(E[e].xMin<=t.x&&E[e].xMax>=p.x&&E[e].yMin<=
l.y&&E[e].yMax>=f.y)return d?{y:b.y,x:b.x<c.x?E[e].xMin-1:E[e].xMax+1,obstacle:E[e]}:{x:b.x,y:b.y<c.y?E[e].yMin-1:E[e].yMax+1,obstacle:E[e]};e+=m}return c}function k(b,c,d,e,m){var p=m.soft,a=m.hard,t=e?"x":"y",f={x:c.x,y:c.y},l={x:c.x,y:c.y};m=b[t+"Max"]>=p[t+"Max"];p=b[t+"Min"]<=p[t+"Min"];var h=b[t+"Max"]>=a[t+"Max"];a=b[t+"Min"]<=a[t+"Min"];var C=g(b[t+"Min"]-c[t]),z=g(b[t+"Max"]-c[t]);d=10>g(C-z)?c[t]<d[t]:z<C;l[t]=b[t+"Min"];f[t]=b[t+"Max"];b=q(c,l,e)[t]!==l[t];c=q(c,f,e)[t]!==f[t];d=b?c?d:
!0:c?!1:d;d=p?m?d:!0:m?!1:d;return a?h?d:!0:h?!1:d}function A(b,d,e){if(b.x===d.x&&b.y===d.y)return[];var m=e?"x":"y",a=u.obstacleOptions.margin;var t={soft:{xMin:p,xMax:I,yMin:H,yMax:L},hard:u.hardBounds};var f=v(E,b);if(-1<f){f=E[f];t=k(f,b,d,e,t);x(f,u.hardBounds);var l=e?{y:b.y,x:f[t?"xMax":"xMin"]+(t?1:-1)}:{x:b.x,y:f[t?"yMax":"yMin"]+(t?1:-1)};var g=v(E,l);-1<g&&(g=E[g],x(g,u.hardBounds),l[m]=t?y(f[m+"Max"]-a+1,(g[m+"Min"]+f[m+"Max"])/2):B(f[m+"Min"]+a-1,(g[m+"Max"]+f[m+"Min"])/2),b.x===l.x&&
b.y===l.y?(c&&(l[m]=t?y(f[m+"Max"],g[m+"Max"])+1:B(f[m+"Min"],g[m+"Min"])-1),c=!c):c=!1);b=[{start:b,end:l}]}else m=q(b,{x:e?d.x:b.x,y:e?b.y:d.y},e),b=[{start:b,end:{x:m.x,y:m.y}}],m[e?"x":"y"]!==d[e?"x":"y"]&&(t=k(m.obstacle,m,d,!e,t),x(m.obstacle,u.hardBounds),t={x:e?m.x:m.obstacle[t?"xMax":"xMin"]+(t?1:-1),y:e?m.obstacle[t?"yMax":"yMin"]+(t?1:-1):m.y},e=!e,b=b.concat(A({x:m.x,y:m.y},t,e)));return b=b.concat(A(b[b.length-1].end,d,!e))}function h(b,c,d){var e=B(b.xMax-c.x,c.x-b.xMin)<B(b.yMax-c.y,
c.y-b.yMin);d=k(b,c,d,e,{soft:u.hardBounds,hard:u.hardBounds});return e?{y:c.y,x:b[d?"xMax":"xMin"]+(d?1:-1)}:{x:c.x,y:b[d?"yMax":"yMin"]+(d?1:-1)}}var e=w(u.startDirectionX,g(r.x-f.x)>g(r.y-f.y)),l=e?"x":"y",d=[],c=!1,b=u.obstacleMetrics,p=B(f.x,r.x)-b.maxWidth-10,I=y(f.x,r.x)+b.maxWidth+10,H=B(f.y,r.y)-b.maxHeight-10,L=y(f.y,r.y)+b.maxHeight+10,E=u.chartObstacles;var z=a(E,p);b=a(E,I);E=E.slice(z,b+1);if(-1<(b=v(E,r))){var m=h(E[b],r,f);d.push({end:r,start:m});r=m}for(;-1<(b=v(E,r));)z=0>r[l]-f[l],
m={x:r.x,y:r.y},m[l]=E[b][z?l+"Max":l+"Min"]+(z?1:-1),d.push({end:r,start:m}),r=m;f=A(f,r,e);f=f.concat(d.reverse());return{path:n(f),obstacles:f}},{requiresObstacles:!0})}});G(k,"parts-gantt/ArrowSymbols.js",[k["parts/Globals.js"]],function(k){k.SVGRenderer.prototype.symbols.arrow=function(a,k,n,x){return[["M",a,k+x/2],["L",a+n,k],["L",a,k+x/2],["L",a+n,k+x]]};k.SVGRenderer.prototype.symbols["arrow-half"]=function(a,v,n,x){return k.SVGRenderer.prototype.symbols.arrow(a,v,n/2,x)};k.SVGRenderer.prototype.symbols["triangle-left"]=
function(a,k,n,x){return[["M",a+n,k],["L",a,k+x/2],["L",a+n,k+x],["Z"]]};k.SVGRenderer.prototype.symbols["arrow-filled"]=k.SVGRenderer.prototype.symbols["triangle-left"];k.SVGRenderer.prototype.symbols["triangle-left-half"]=function(a,v,n,x){return k.SVGRenderer.prototype.symbols["triangle-left"](a,v,n/2,x)};k.SVGRenderer.prototype.symbols["arrow-filled-half"]=k.SVGRenderer.prototype.symbols["triangle-left-half"]});G(k,"parts-gantt/Pathfinder.js",[k["parts/Globals.js"],k["parts/Point.js"],k["parts/Utilities.js"],
k["parts-gantt/PathfinderAlgorithms.js"]],function(k,a,v,n){function x(c){var b=c.shapeArgs;return b?{xMin:b.x,xMax:b.x+b.width,yMin:b.y,yMax:b.y+b.height}:(b=c.graphic&&c.graphic.getBBox())?{xMin:c.plotX-b.width/2,xMax:c.plotX+b.width/2,yMin:c.plotY-b.height/2,yMax:c.plotY+b.height/2}:null}function q(c){for(var b=c.length,e=0,a,f,g=[],h=function(b,c,e){e=A(e,10);var m=b.yMax+e>c.yMin-e&&b.yMin-e<c.yMax+e,a=b.xMax+e>c.xMin-e&&b.xMin-e<c.xMax+e,p=m?b.xMin>c.xMax?b.xMin-c.xMax:c.xMin-b.xMax:Infinity,
t=a?b.yMin>c.yMax?b.yMin-c.yMax:c.yMin-b.yMax:Infinity;return a&&m?e?h(b,c,Math.floor(e/2)):Infinity:d(p,t)};e<b;++e)for(a=e+1;a<b;++a)f=h(c[e],c[a]),80>f&&g.push(f);g.push(80);return l(Math.floor(g.sort(function(b,c){return b-c})[Math.floor(g.length/10)]/2-1),1)}function w(c,b,d){this.init(c,b,d)}function B(c){this.init(c)}function y(c){if(c.options.pathfinder||c.series.reduce(function(b,c){c.options&&D(!0,c.options.connectors=c.options.connectors||{},c.options.pathfinder);return b||c.options&&c.options.pathfinder},
!1))D(!0,c.options.connectors=c.options.connectors||{},c.options.pathfinder),r('WARNING: Pathfinder options have been renamed. Use "chart.connectors" or "series.connectors" instead.')}"";var g=v.addEvent,f=v.defined,r=v.error,u=v.extend,D=v.merge,F=v.objectEach,A=v.pick,h=v.splat,e=k.deg2rad,l=Math.max,d=Math.min;u(k.defaultOptions,{connectors:{type:"straight",lineWidth:1,marker:{enabled:!1,align:"center",verticalAlign:"middle",inside:!1,lineWidth:1},startMarker:{symbol:"diamond"},endMarker:{symbol:"arrow-filled"}}});
w.prototype={init:function(c,b,d){this.fromPoint=c;this.toPoint=b;this.options=d;this.chart=c.series.chart;this.pathfinder=this.chart.pathfinder},renderPath:function(c,b,d){var e=this.chart,a=e.styledMode,p=e.pathfinder,f=!e.options.chart.forExport&&!1!==d,l=this.graphics&&this.graphics.path;p.group||(p.group=e.renderer.g().addClass("highcharts-pathfinder-group").attr({zIndex:-1}).add(e.seriesGroup));p.group.translate(e.plotLeft,e.plotTop);l&&l.renderer||(l=e.renderer.path().add(p.group),a||l.attr({opacity:0}));
l.attr(b);c={d:c};a||(c.opacity=1);l[f?"animate":"attr"](c,d);this.graphics=this.graphics||{};this.graphics.path=l},addMarker:function(c,b,d){var a=this.fromPoint.series.chart,p=a.pathfinder;a=a.renderer;var f="start"===c?this.fromPoint:this.toPoint,l=f.getPathfinderAnchorPoint(b);if(b.enabled&&((d="start"===c?d[1]:d[d.length-2])&&"M"===d[0]||"L"===d[0])){d={x:d[1],y:d[2]};d=f.getRadiansToVector(d,l);l=f.getMarkerVector(d,b.radius,l);d=-d/e;if(b.width&&b.height){var g=b.width;var m=b.height}else g=
m=2*b.radius;this.graphics=this.graphics||{};l={x:l.x-g/2,y:l.y-m/2,width:g,height:m,rotation:d,rotationOriginX:l.x,rotationOriginY:l.y};this.graphics[c]?this.graphics[c].animate(l):(this.graphics[c]=a.symbol(b.symbol).addClass("highcharts-point-connecting-path-"+c+"-marker").attr(l).add(p.group),a.styledMode||this.graphics[c].attr({fill:b.color||this.fromPoint.color,stroke:b.lineColor,"stroke-width":b.lineWidth,opacity:0}).animate({opacity:1},f.series.options.animation))}},getPath:function(c){var b=
this.pathfinder,d=this.chart,e=b.algorithms[c.type],a=b.chartObstacles;if("function"!==typeof e)r('"'+c.type+'" is not a Pathfinder algorithm.');else return e.requiresObstacles&&!a&&(a=b.chartObstacles=b.getChartObstacles(c),d.options.connectors.algorithmMargin=c.algorithmMargin,b.chartObstacleMetrics=b.getObstacleMetrics(a)),e(this.fromPoint.getPathfinderAnchorPoint(c.startMarker),this.toPoint.getPathfinderAnchorPoint(c.endMarker),D({chartObstacles:a,lineObstacles:b.lineObstacles||[],obstacleMetrics:b.chartObstacleMetrics,
hardBounds:{xMin:0,xMax:d.plotWidth,yMin:0,yMax:d.plotHeight},obstacleOptions:{margin:c.algorithmMargin},startDirectionX:b.getAlgorithmStartDirection(c.startMarker)},c))},render:function(){var c=this.fromPoint,b=c.series,e=b.chart,a=e.pathfinder,g=D(e.options.connectors,b.options.connectors,c.options.connectors,this.options),h={};e.styledMode||(h.stroke=g.lineColor||c.color,h["stroke-width"]=g.lineWidth,g.dashStyle&&(h.dashstyle=g.dashStyle));h["class"]="highcharts-point-connecting-path highcharts-color-"+
c.colorIndex;g=D(h,g);f(g.marker.radius)||(g.marker.radius=d(l(Math.ceil((g.algorithmMargin||8)/2)-1,1),5));c=this.getPath(g);e=c.path;c.obstacles&&(a.lineObstacles=a.lineObstacles||[],a.lineObstacles=a.lineObstacles.concat(c.obstacles));this.renderPath(e,h,b.options.animation);this.addMarker("start",D(g.marker,g.startMarker),e);this.addMarker("end",D(g.marker,g.endMarker),e)},destroy:function(){this.graphics&&(F(this.graphics,function(c){c.destroy()}),delete this.graphics)}};B.prototype={algorithms:n,
init:function(c){this.chart=c;this.connections=[];g(c,"redraw",function(){this.pathfinder.update()})},update:function(c){var b=this.chart,d=this,e=d.connections;d.connections=[];b.series.forEach(function(c){c.visible&&!c.options.isInternal&&c.points.forEach(function(c){var e,m=c.options&&c.options.connect&&h(c.options.connect);c.visible&&!1!==c.isInside&&m&&m.forEach(function(m){e=b.get("string"===typeof m?m:m.to);e instanceof a&&e.series.visible&&e.visible&&!1!==e.isInside&&d.connections.push(new w(c,
e,"string"===typeof m?{}:m))})})});for(var f=0,l,g,r=e.length,m=d.connections.length;f<r;++f){g=!1;for(l=0;l<m;++l)if(e[f].fromPoint===d.connections[l].fromPoint&&e[f].toPoint===d.connections[l].toPoint){d.connections[l].graphics=e[f].graphics;g=!0;break}g||e[f].destroy()}delete this.chartObstacles;delete this.lineObstacles;d.renderConnections(c)},renderConnections:function(c){c?this.chart.series.forEach(function(b){var c=function(){var c=b.chart.pathfinder;(c&&c.connections||[]).forEach(function(c){c.fromPoint&&
c.fromPoint.series===b&&c.render()});b.pathfinderRemoveRenderEvent&&(b.pathfinderRemoveRenderEvent(),delete b.pathfinderRemoveRenderEvent)};!1===b.options.animation?c():b.pathfinderRemoveRenderEvent=g(b,"afterAnimate",c)}):this.connections.forEach(function(b){b.render()})},getChartObstacles:function(c){for(var b=[],d=this.chart.series,e=A(c.algorithmMargin,0),a,l=0,g=d.length;l<g;++l)if(d[l].visible&&!d[l].options.isInternal)for(var h=0,m=d[l].points.length,t;h<m;++h)t=d[l].points[h],t.visible&&(t=
x(t))&&b.push({xMin:t.xMin-e,xMax:t.xMax+e,yMin:t.yMin-e,yMax:t.yMax+e});b=b.sort(function(b,c){return b.xMin-c.xMin});f(c.algorithmMargin)||(a=c.algorithmMargin=q(b),b.forEach(function(b){b.xMin-=a;b.xMax+=a;b.yMin-=a;b.yMax+=a}));return b},getObstacleMetrics:function(c){for(var b=0,d=0,e,a,f=c.length;f--;)e=c[f].xMax-c[f].xMin,a=c[f].yMax-c[f].yMin,b<e&&(b=e),d<a&&(d=a);return{maxHeight:d,maxWidth:b}},getAlgorithmStartDirection:function(c){var b="top"!==c.verticalAlign&&"bottom"!==c.verticalAlign;
return"left"!==c.align&&"right"!==c.align?b?void 0:!1:b?!0:void 0}};k.Connection=w;k.Pathfinder=B;u(a.prototype,{getPathfinderAnchorPoint:function(c){var b=x(this);switch(c.align){case "right":var d="xMax";break;case "left":d="xMin"}switch(c.verticalAlign){case "top":var e="yMin";break;case "bottom":e="yMax"}return{x:d?b[d]:(b.xMin+b.xMax)/2,y:e?b[e]:(b.yMin+b.yMax)/2}},getRadiansToVector:function(c,b){var d;f(b)||(d=x(this))&&(b={x:(d.xMin+d.xMax)/2,y:(d.yMin+d.yMax)/2});return Math.atan2(b.y-c.y,
c.x-b.x)},getMarkerVector:function(c,b,d){var e=2*Math.PI,a=x(this),f=a.xMax-a.xMin,l=a.yMax-a.yMin,p=Math.atan2(l,f),m=!1;f/=2;var t=l/2,g=a.xMin+f;a=a.yMin+t;for(var h=g,r=a,n={},u=1,k=1;c<-Math.PI;)c+=e;for(;c>Math.PI;)c-=e;e=Math.tan(c);c>-p&&c<=p?(k=-1,m=!0):c>p&&c<=Math.PI-p?k=-1:c>Math.PI-p||c<=-(Math.PI-p)?(u=-1,m=!0):u=-1;m?(h+=u*f,r+=k*f*e):(h+=l/(2*e)*u,r+=k*t);d.x!==g&&(h=d.x);d.y!==a&&(r=d.y);n.x=h+b*Math.cos(c);n.y=r-b*Math.sin(c);return n}});k.Chart.prototype.callbacks.push(function(c){!1!==
c.options.connectors.enabled&&(y(c),this.pathfinder=new B(this),this.pathfinder.update(!0))})});G(k,"modules/xrange.src.js",[k["parts/Globals.js"],k["parts/Color.js"],k["parts/Point.js"],k["parts/Utilities.js"]],function(k,a,v,n){var x=a.parse;a=n.addEvent;var q=n.clamp,w=n.correctFloat,B=n.defined,y=n.find,g=n.isNumber,f=n.isObject,r=n.merge,u=n.pick;n=n.seriesType;var D=k.seriesTypes.column,F=k.seriesTypes,A=k.Axis,h=k.Series;n("xrange","column",{colorByPoint:!0,dataLabels:{formatter:function(){var e=
this.point.partialFill;f(e)&&(e=e.amount);if(g(e)&&0<e)return w(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:F.line.prototype.animate,cropShoulder:1,getExtremesFromAll:!0,autoIncrement:k.noop,buildKDTree:k.noop,
init:function(){F.column.prototype.init.apply(this,arguments);this.options.stacking=void 0},getColumnMetrics:function(){function e(){a.series.forEach(function(c){var b=c.xAxis;c.xAxis=c.yAxis;c.yAxis=b})}var a=this.chart;e();var d=D.prototype.getColumnMetrics.call(this);e();return d},cropData:function(e,a,d,c){a=h.prototype.cropData.call(this,this.x2Data,a,d,c);a.xData=e.slice(a.start,a.end);return a},findPointIndex:function(e){var a=this.cropped,d=this.cropStart,c=this.points,b=e.id;if(b)var f=(f=
y(c,function(c){return c.id===b}))?f.index:void 0;"undefined"===typeof f&&(f=(f=y(c,function(b){return b.x===e.x&&b.x2===e.x2&&!b.touched}))?f.index:void 0);a&&g(f)&&g(d)&&f>=d&&(f-=d);return f},translatePoint:function(e){var a=this.xAxis,d=this.yAxis,c=this.columnMetrics,b=this.options,p=b.minPointLength||0,h=e.plotX,k=u(e.x2,e.x+(e.len||0)),n=a.translate(k,0,0,0,1);k=Math.abs(n-h);var y=this.chart.inverted,z=u(b.borderWidth,1)%2/2,m=c.offset,t=Math.round(c.width);p&&(p-=k,0>p&&(p=0),h-=p/2,n+=p/
2);h=Math.max(h,-10);n=q(n,-10,a.len+10);B(e.options.pointWidth)&&(m-=(Math.ceil(e.options.pointWidth)-t)/2,t=Math.ceil(e.options.pointWidth));b.pointPlacement&&g(e.plotY)&&d.categories&&(e.plotY=d.translate(e.y,0,1,0,1,b.pointPlacement));e.shapeArgs={x:Math.floor(Math.min(h,n))+z,y:Math.floor(e.plotY+m)+z,width:Math.round(Math.abs(n-h)),height:t,r:this.options.borderRadius};b=e.shapeArgs.x;p=b+e.shapeArgs.width;0>b||p>a.len?(b=q(b,0,a.len),p=q(p,0,a.len),n=p-b,e.dlBox=r(e.shapeArgs,{x:b,width:p-
b,centerX:n?n/2:null})):e.dlBox=null;b=e.tooltipPos;p=y?1:0;n=y?0:1;c=this.columnMetrics?this.columnMetrics.offset:-c.width/2;b[p]=q(b[p]+k/2*(a.reversed?-1:1)*(y?-1:1),0,a.len-1);b[n]=q(b[n]+(y?-1:1)*c,0,d.len-1);if(c=e.partialFill)f(c)&&(c=c.amount),g(c)||(c=0),d=e.shapeArgs,e.partShapeArgs={x:d.x,y:d.y,width:d.width,height:d.height,r:this.options.borderRadius},h=Math.max(Math.round(k*c+e.plotX-h),0),e.clipRectArgs={x:a.reversed?d.x+k-h:d.x,y:d.y,width:h,height:d.height}},translate:function(){D.prototype.translate.apply(this,
arguments);this.points.forEach(function(e){this.translatePoint(e)},this)},drawPoint:function(e,a){var d=this.options,c=this.chart.renderer,b=e.graphic,p=e.shapeType,g=e.shapeArgs,l=e.partShapeArgs,h=e.clipRectArgs,n=e.partialFill,k=d.stacking&&!d.borderRadius,m=e.state,t=d.states[m||"normal"]||{},C="undefined"===typeof m?"attr":a;m=this.pointAttribs(e,m);t=u(this.chart.options.chart.animation,t.animation);if(e.isNull||!1===e.visible)b&&(e.graphic=b.destroy());else{if(b)b.rect[a](g);else e.graphic=
b=c.g("point").addClass(e.getClassName()).add(e.group||this.group),b.rect=c[p](r(g)).addClass(e.getClassName()).addClass("highcharts-partfill-original").add(b);l&&(b.partRect?(b.partRect[a](r(l)),b.partialClipRect[a](r(h))):(b.partialClipRect=c.clipRect(h.x,h.y,h.width,h.height),b.partRect=c[p](l).addClass("highcharts-partfill-overlay").add(b).clip(b.partialClipRect)));this.chart.styledMode||(b.rect[a](m,t).shadow(d.shadow,null,k),l&&(f(n)||(n={}),f(d.partialFill)&&(n=r(n,d.partialFill)),e=n.fill||
x(m.fill).brighten(-.3).get()||x(e.color||this.color).brighten(-.3).get(),m.fill=e,b.partRect[C](m,t).shadow(d.shadow,null,k)))}},drawPoints:function(){var e=this,a=e.getAnimationVerb();e.points.forEach(function(d){e.drawPoint(d,a)})},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 a=e.options.colors||e.chart.options.colors;var d=this.y%(a?a.length:
e.chart.options.chart.colorCount);a=a&&a[d];e.chart.styledMode||(this.color=a);this.options.colorIndex||(this.colorIndex=d)}else this.color||(this.color=e.color)},init:function(){v.prototype.init.apply(this,arguments);this.y||(this.y=0);return this},setState:function(){v.prototype.setState.apply(this,arguments);this.series.drawPoint(this,this.series.getAnimationVerb())},getLabelConfig:function(){var e=v.prototype.getLabelConfig.call(this),a=this.series.yAxis.categories;e.x2=this.x2;e.yCategory=this.yCategory=
a&&a[this.y];return e},tooltipDateKeys:["x","x2"],isValid:function(){return"number"===typeof this.x&&"number"===typeof this.x2}});a(A,"afterGetSeriesExtremes",function(){var e=this.series,a;if(this.isXAxis){var d=u(this.dataMax,-Number.MAX_VALUE);e.forEach(function(c){c.x2Data&&c.x2Data.forEach(function(b){b>d&&(d=b,a=!0)})});a&&(this.dataMax=d)}});""});G(k,"parts-gantt/GanttSeries.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(k,a){var v=a.isNumber,n=a.merge,x=a.pick,q=a.seriesType,
w=a.splat,B=k.dateFormat,y=k.seriesTypes.xrange;q("gantt","xrange",{grouping:!1,dataLabels:{enabled:!0},tooltip:{headerFormat:'<span style="font-size: 10px">{series.name}</span><br/>',pointFormat:null,pointFormatter:function(){var a=this.series,f=a.chart.tooltip,r=a.xAxis,n=a.tooltipOptions.dateTimeLabelFormats,k=r.options.startOfWeek,q=a.tooltipOptions,y=q.xDateFormat;a=this.options.milestone;var h="<b>"+(this.name||this.yCategory)+"</b>";if(q.pointFormat)return this.tooltipFormatter(q.pointFormat);
y||(y=w(f.getDateFormat(r.closestPointRange,this.start,k,n))[0]);f=B(y,this.start);r=B(y,this.end);h+="<br/>";return a?h+(f+"<br/>"):h+("Start: "+f+"<br/>End: ")+(r+"<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(a){y.prototype.translatePoint.call(this,a);if(a.options.milestone){var f=
a.shapeArgs;var g=f.height;a.shapeArgs={x:f.x-g/2,y:f.y,width:g,height:g}}},drawPoint:function(a,f){var g=this.options,n=this.chart.renderer,k=a.shapeArgs,q=a.plotY,x=a.graphic,h=a.selected&&"select",e=g.stacking&&!g.borderRadius;if(a.options.milestone)if(v(q)&&null!==a.y&&!1!==a.visible){k=n.symbols.diamond(k.x,k.y,k.width,k.height);if(x)x[f]({d:k});else a.graphic=n.path(k).addClass(a.getClassName(),!0).add(a.group||this.group);this.chart.styledMode||a.graphic.attr(this.pointAttribs(a,h)).shadow(g.shadow,
null,e)}else x&&(a.graphic=x.destroy());else y.prototype.drawPoint.call(this,a,f)},setData:k.Series.prototype.setData,setGanttPointAliases:function(a){function f(f,g){"undefined"!==typeof g&&(a[f]=g)}f("x",x(a.start,a.x));f("x2",x(a.end,a.x2));f("partialFill",x(a.completed,a.partialFill));f("connect",x(a.dependency,a.connect))}},n(y.prototype.pointClass.prototype,{applyOptions:function(a,f){a=n(a);k.seriesTypes.gantt.prototype.setGanttPointAliases(a);return a=y.prototype.pointClass.prototype.applyOptions.call(this,
a,f)},isValid:function(){return("number"===typeof this.start||"number"===typeof this.x)&&("number"===typeof this.end||"number"===typeof this.x2||this.milestone)}}));""});G(k,"parts-gantt/GanttChart.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(k,a){var v=a.isArray,n=a.merge,x=a.splat,q=k.Chart;k.ganttChart=function(a,w,y){var g="string"===typeof a||a.nodeName,f=w.series,r=k.getOptions(),u,D=w;w=arguments[g?1:0];v(w.xAxis)||(w.xAxis=[w.xAxis||{},{}]);w.xAxis=w.xAxis.map(function(a,f){1===
f&&(u=0);return n(r.xAxis,{grid:{enabled:!0},opposite:!0,linkedTo:u},a,{type:"datetime"})});w.yAxis=x(w.yAxis||{}).map(function(a){return n(r.yAxis,{grid:{enabled:!0},staticScale:50,reversed:!0,type:a.categories?a.type:"treegrid"},a)});w.series=null;w=n(!0,{chart:{type:"gantt"},title:{text:null},legend:{enabled:!1}},w,{isGantt:!0});w.series=D.series=f;w.series.forEach(function(a){a.data.forEach(function(a){k.seriesTypes.gantt.prototype.setGanttPointAliases(a)})});return g?new q(a,w,y):new q(w,w)}});
G(k,"parts/ScrollbarAxis.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(k,a){var v=a.addEvent,n=a.defined,x=a.pick;return function(){function a(){}a.compose=function(a,q){v(a,"afterInit",function(){var a=this;a.options&&a.options.scrollbar&&a.options.scrollbar.enabled&&(a.options.scrollbar.vertical=!a.horiz,a.options.startOnTick=a.options.endOnTick=!1,a.scrollbar=new q(a.chart.renderer,a.options.scrollbar,a.chart),v(a.scrollbar,"changed",function(g){var f=x(a.options&&a.options.min,
a.min),r=x(a.options&&a.options.max,a.max),u=n(a.dataMin)?Math.min(f,a.min,a.dataMin):f,q=(n(a.dataMax)?Math.max(r,a.max,a.dataMax):r)-u;n(f)&&n(r)&&(a.horiz&&!a.reversed||!a.horiz&&a.reversed?(f=u+q*this.to,u+=q*this.from):(f=u+q*(1-this.from),u+=q*(1-this.to)),x(this.options.liveRedraw,k.svg&&!k.isTouchDevice&&!this.chart.isBoosting)||"mouseup"===g.DOMType||!n(g.DOMType)?a.setExtremes(u,f,!0,"mousemove"!==g.DOMType,g):this.setRange(this.from,this.to))}))});v(a,"afterRender",function(){var a=Math.min(x(this.options.min,
this.min),this.min,x(this.dataMin,this.min)),g=Math.max(x(this.options.max,this.max),this.max,x(this.dataMax,this.max)),f=this.scrollbar,k=this.axisTitleMargin+(this.titleOffset||0),u=this.chart.scrollbarsOffsets,q=this.options.margin||0;f&&(this.horiz?(this.opposite||(u[1]+=k),f.position(this.left,this.top+this.height+2+u[1]-(this.opposite?q:0),this.width,this.height),this.opposite||(u[1]+=q),k=1):(this.opposite&&(u[0]+=k),f.position(this.left+this.width+2+u[0]-(this.opposite?0:q),this.top,this.width,
this.height),this.opposite&&(u[0]+=q),k=0),u[k]+=f.size+f.options.margin,isNaN(a)||isNaN(g)||!n(this.min)||!n(this.max)||this.min===this.max?f.setRange(0,1):(u=(this.min-a)/(g-a),a=(this.max-a)/(g-a),this.horiz&&!this.reversed||!this.horiz&&this.reversed?f.setRange(u,a):f.setRange(1-a,1-u)))});v(a,"afterGetOffset",function(){var a=this.horiz?2:1,g=this.scrollbar;g&&(this.chart.scrollbarsOffsets=[0,0],this.chart.axisOffset[a]+=g.size+g.options.margin)})};return a}()});G(k,"parts/Scrollbar.js",[k["parts/Axis.js"],
k["parts/Globals.js"],k["parts/ScrollbarAxis.js"],k["parts/Utilities.js"]],function(k,a,v,n){var x=n.addEvent,q=n.correctFloat,w=n.defined,B=n.destroyObjectProperties,y=n.fireEvent,g=n.merge,f=n.pick,r=n.removeEvent;n=a.defaultOptions;var u=a.hasTouch,D=a.isTouchDevice,F=a.swapXY=function(a,e){e&&a.forEach(function(a){for(var d=a.length,c,b=0;b<d;b+=2)c=a[b+1],"number"===typeof c&&(a[b+1]=a[b+2],a[b+2]=c)});return a},A=function(){function a(a,f,d){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=d;this.options=f;this.renderer=d.renderer;this.init(a,f,d)}a.prototype.addEvents=function(){var a=this.options.inverted?[1,0]:[0,1],f=this.scrollbarButtons,d=this.scrollbarGroup.element,c=this.track.element,b=this.mouseDownHandler.bind(this),
p=this.mouseMoveHandler.bind(this),g=this.mouseUpHandler.bind(this);a=[[f[a[0]].element,"click",this.buttonToMinClick.bind(this)],[f[a[1]].element,"click",this.buttonToMaxClick.bind(this)],[c,"click",this.trackClick.bind(this)],[d,"mousedown",b],[d.ownerDocument,"mousemove",p],[d.ownerDocument,"mouseup",g]];u&&a.push([d,"touchstart",b],[d.ownerDocument,"touchmove",p],[d.ownerDocument,"touchend",g]);a.forEach(function(b){x.apply(null,b)});this._events=a};a.prototype.buttonToMaxClick=function(a){var e=
(this.to-this.from)*f(this.options.step,.2);this.updatePosition(this.from+e,this.to+e);y(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:a})};a.prototype.buttonToMinClick=function(a){var e=q(this.to-this.from)*f(this.options.step,.2);this.updatePosition(q(this.from-e),q(this.to-e));y(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:a})};a.prototype.cursorToScrollbarPosition=function(a){var e=this.options;e=e.minWidth>this.calculatedWidth?e.minWidth:0;return{chartX:(a.chartX-
this.x-this.xOffset)/(this.barWidth-e),chartY:(a.chartY-this.y-this.yOffset)/(this.barWidth-e)}};a.prototype.destroy=function(){var a=this.chart.scroller;this.removeEvents();["track","scrollbarRifles","scrollbar","scrollbarGroup","group"].forEach(function(a){this[a]&&this[a].destroy&&(this[a]=this[a].destroy())},this);a&&this===a.scrollbar&&(a.scrollbar=null,B(a.scrollbarButtons))};a.prototype.drawScrollbarButton=function(a){var e=this.renderer,d=this.scrollbarButtons,c=this.options,b=this.size;var f=
e.g().add(this.group);d.push(f);f=e.rect().addClass("highcharts-scrollbar-button").add(f);this.chart.styledMode||f.attr({stroke:c.buttonBorderColor,"stroke-width":c.buttonBorderWidth,fill:c.buttonBackgroundColor});f.attr(f.crisp({x:-.5,y:-.5,width:b+1,height:b+1,r:c.buttonBorderRadius},f.strokeWidth()));f=e.path(F([["M",b/2+(a?-1:1),b/2-3],["L",b/2+(a?-1:1),b/2+3],["L",b/2+(a?2:-2),b/2]],c.vertical)).addClass("highcharts-scrollbar-arrow").add(d[a]);this.chart.styledMode||f.attr({fill:c.buttonArrowColor})};
a.prototype.init=function(e,h,d){this.scrollbarButtons=[];this.renderer=e;this.userOptions=h;this.options=g(a.defaultOptions,h);this.chart=d;this.size=f(this.options.size,this.options.height);h.enabled&&(this.render(),this.addEvents())};a.prototype.mouseDownHandler=function(a){a=this.chart.pointer.normalize(a);a=this.cursorToScrollbarPosition(a);this.chartX=a.chartX;this.chartY=a.chartY;this.initPositions=[this.from,this.to];this.grabbedCenter=!0};a.prototype.mouseMoveHandler=function(a){var e=this.chart.pointer.normalize(a),
d=this.options.vertical?"chartY":"chartX",c=this.initPositions||[];!this.grabbedCenter||a.touches&&0===a.touches[0][d]||(e=this.cursorToScrollbarPosition(e)[d],d=this[d],d=e-d,this.hasDragged=!0,this.updatePosition(c[0]+d,c[1]+d),this.hasDragged&&y(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:a.type,DOMEvent:a}))};a.prototype.mouseUpHandler=function(a){this.hasDragged&&y(this,"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMType:a.type,DOMEvent:a});this.grabbedCenter=
this.hasDragged=this.chartX=this.chartY=null};a.prototype.position=function(a,f,d,c){var b=this.options.vertical,e=0,g=this.rendered?"animate":"attr";this.x=a;this.y=f+this.trackBorderWidth;this.width=d;this.xOffset=this.height=c;this.yOffset=e;b?(this.width=this.yOffset=d=e=this.size,this.xOffset=f=0,this.barWidth=c-2*d,this.x=a+=this.options.margin):(this.height=this.xOffset=c=f=this.size,this.barWidth=d-2*c,this.y+=this.options.margin);this.group[g]({translateX:a,translateY:this.y});this.track[g]({width:d,
height:c});this.scrollbarButtons[1][g]({translateX:b?0:d-f,translateY:b?c-e:0})};a.prototype.removeEvents=function(){this._events.forEach(function(a){r.apply(null,a)});this._events.length=0};a.prototype.render=function(){var a=this.renderer,f=this.options,d=this.size,c=this.chart.styledMode,b;this.group=b=a.g("scrollbar").attr({zIndex:f.zIndex,translateY:-99999}).add();this.track=a.rect().addClass("highcharts-scrollbar-track").attr({x:0,r:f.trackBorderRadius||0,height:d,width:d}).add(b);c||this.track.attr({fill:f.trackBackgroundColor,
stroke:f.trackBorderColor,"stroke-width":f.trackBorderWidth});this.trackBorderWidth=this.track.strokeWidth();this.track.attr({y:-this.trackBorderWidth%2/2});this.scrollbarGroup=a.g().add(b);this.scrollbar=a.rect().addClass("highcharts-scrollbar-thumb").attr({height:d,width:d,r:f.barBorderRadius||0}).add(this.scrollbarGroup);this.scrollbarRifles=a.path(F([["M",-3,d/4],["L",-3,2*d/3],["M",0,d/4],["L",0,2*d/3],["M",3,d/4],["L",3,2*d/3]],f.vertical)).addClass("highcharts-scrollbar-rifles").add(this.scrollbarGroup);
c||(this.scrollbar.attr({fill:f.barBackgroundColor,stroke:f.barBorderColor,"stroke-width":f.barBorderWidth}),this.scrollbarRifles.attr({stroke:f.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)};a.prototype.setRange=function(a,f){var d=this.options,c=d.vertical,b=d.minWidth,e=this.barWidth,g,h=!this.rendered||this.hasDragged||
this.chart.navigator&&this.chart.navigator.hasDragged?"attr":"animate";if(w(e)){a=Math.max(a,0);var l=Math.ceil(e*a);this.calculatedWidth=g=q(e*Math.min(f,1)-l);g<b&&(l=(e-b+g)*a,g=b);b=Math.floor(l+this.xOffset+this.yOffset);e=g/2-.5;this.from=a;this.to=f;c?(this.scrollbarGroup[h]({translateY:b}),this.scrollbar[h]({height:g}),this.scrollbarRifles[h]({translateY:e}),this.scrollbarTop=b,this.scrollbarLeft=0):(this.scrollbarGroup[h]({translateX:b}),this.scrollbar[h]({width:g}),this.scrollbarRifles[h]({translateX:e}),
this.scrollbarLeft=b,this.scrollbarTop=0);12>=g?this.scrollbarRifles.hide():this.scrollbarRifles.show(!0);!1===d.showFull&&(0>=a&&1<=f?this.group.hide():this.group.show());this.rendered=!0}};a.prototype.trackClick=function(a){var e=this.chart.pointer.normalize(a),d=this.to-this.from,c=this.y+this.scrollbarTop,b=this.x+this.scrollbarLeft;this.options.vertical&&e.chartY>c||!this.options.vertical&&e.chartX>b?this.updatePosition(this.from+d,this.to+d):this.updatePosition(this.from-d,this.to-d);y(this,
"changed",{from:this.from,to:this.to,trigger:"scrollbar",DOMEvent:a})};a.prototype.update=function(a){this.destroy();this.init(this.chart.renderer,g(!0,this.options,a),this.chart)};a.prototype.updatePosition=function(a,f){1<f&&(a=q(1-q(f-a)),f=1);0>a&&(f=q(f-a),a=0);this.from=a;this.to=f};a.defaultOptions={height:D?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 a}();a.Scrollbar||(n.scrollbar=g(!0,A.defaultOptions,n.scrollbar),a.Scrollbar=A,v.compose(k,A));return a.Scrollbar});G(k,"parts/RangeSelector.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(k,a){function v(a){this.init(a)}var n=a.addEvent,x=a.createElement,q=a.css,w=a.defined,B=a.destroyObjectProperties,
y=a.discardElement,g=a.extend,f=a.fireEvent,r=a.isNumber,u=a.merge,D=a.objectEach,F=a.pick,A=a.pInt,h=a.splat,e=k.Axis;a=k.Chart;var l=k.defaultOptions;g(l,{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"}}});l.lang=u(l.lang,{rangeSelectorZoom:"Zoom",rangeSelectorFrom:"From",rangeSelectorTo:"To"});v.prototype={clickButton:function(a,
c){var b=this.chart,d=this.buttonOptions[a],f=b.xAxis[0],g=b.scroller&&b.scroller.getUnionExtremes()||f||{},k=g.dataMin,l=g.dataMax,z=f&&Math.round(Math.min(f.max,F(l,f.max))),m=d.type;g=d._range;var t,C=d.dataGrouping;if(null!==k&&null!==l){b.fixedRange=g;C&&(this.forcedDataGrouping=!0,e.prototype.setDataGrouping.call(f||{chart:this.chart},C,!1),this.frozenStates=d.preserveDataGrouping);if("month"===m||"year"===m)if(f){m={range:d,max:z,chart:b,dataMin:k,dataMax:l};var u=f.minFromRange.call(m);r(m.newMax)&&
(z=m.newMax)}else g=d;else if(g)u=Math.max(z-g,k),z=Math.min(u+g,l);else if("ytd"===m)if(f)"undefined"===typeof l&&(k=Number.MAX_VALUE,l=Number.MIN_VALUE,b.series.forEach(function(b){b=b.xData;k=Math.min(b[0],k);l=Math.max(b[b.length-1],l)}),c=!1),z=this.getYTDExtremes(l,k,b.time.useUTC),u=t=z.min,z=z.max;else{this.deferredYTDClick=a;return}else"all"===m&&f&&(u=k,z=l);u+=d._offsetMin;z+=d._offsetMax;this.setSelected(a);if(f)f.setExtremes(u,z,F(c,1),null,{trigger:"rangeSelectorButton",rangeSelectorButton:d});
else{var q=h(b.options.xAxis)[0];var v=q.range;q.range=g;var x=q.min;q.min=t;n(b,"load",function(){q.range=v;q.min=x})}}},setSelected:function(a){this.selected=this.options.selected=a},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(a){var c=this,b=a.options.rangeSelector,d=b.buttons||[].concat(c.defaultButtons),e=b.selected,g=function(){var b=
c.minInput,a=c.maxInput;b&&b.blur&&f(b,"blur");a&&a.blur&&f(a,"blur")};c.chart=a;c.options=b;c.buttons=[];c.buttonOptions=d;this.unMouseDown=n(a.container,"mousedown",g);this.unResize=n(a,"resize",g);d.forEach(c.computeButtonRange);"undefined"!==typeof e&&d[e]&&this.clickButton(e,!1);n(a,"load",function(){a.xAxis&&a.xAxis[0]&&n(a.xAxis[0],"setExtremes",function(b){this.max-this.min!==a.fixedRange&&"rangeSelectorButton"!==b.trigger&&"updatedData"!==b.trigger&&c.forcedDataGrouping&&!c.frozenStates&&
this.setDataGrouping(!1,!1)})})},updateButtonStates:function(){var a=this,c=this.chart,b=c.xAxis[0],e=Math.round(b.max-b.min),f=!b.hasVisibleSeries,g=c.scroller&&c.scroller.getUnionExtremes()||b,h=g.dataMin,k=g.dataMax;c=a.getYTDExtremes(k,h,c.time.useUTC);var l=c.min,m=c.max,t=a.selected,n=r(t),u=a.options.allButtonsEnabled,q=a.buttons;a.buttonOptions.forEach(function(c,d){var g=c._range,p=c.type,C=c.count||1,r=q[d],z=0,J=c._offsetMax-c._offsetMin;c=d===t;var K=g>k-h,v=g<b.minRange,x=!1,T=!1;g=g===
e;("month"===p||"year"===p)&&e+36E5>=864E5*{month:28,year:365}[p]*C-J&&e-36E5<=864E5*{month:31,year:366}[p]*C+J?g=!0:"ytd"===p?(g=m-l+J===e,x=!c):"all"===p&&(g=b.max-b.min>=k-h,T=!c&&n&&g);p=!u&&(K||v||T||f);C=c&&g||g&&!n&&!x||c&&a.frozenStates;p?z=3:C&&(n=!0,z=2);r.state!==z&&(r.setState(z),0===z&&t===d&&a.setSelected(null))})},computeButtonRange:function(a){var c=a.type,b=a.count||1,d={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5};if(d[c])a._range=d[c]*b;else if("month"===
c||"year"===c)a._range=864E5*{month:30,year:365}[c]*b;a._offsetMin=F(a.offsetMin,0);a._offsetMax=F(a.offsetMax,0);a._range+=a._offsetMax-a._offsetMin},setInputValue:function(a,c){var b=this.chart.options.rangeSelector,d=this.chart.time,e=this[a+"Input"];w(c)&&(e.previousValue=e.HCTime,e.HCTime=c);e.value=d.dateFormat(b.inputEditDateFormat||"%Y-%m-%d",e.HCTime);this[a+"DateBox"].attr({text:d.dateFormat(b.inputDateFormat||"%b %e, %Y",e.HCTime)})},showInput:function(a){var c=this.inputGroup,b=this[a+
"DateBox"];q(this[a+"Input"],{left:c.translateX+b.x+"px",top:c.translateY+"px",width:b.width-2+"px",height:b.height-2+"px",border:"2px solid silver"})},hideInput:function(a){q(this[a+"Input"],{border:0,width:"1px",height:"1px"});this.setInputValue(a)},drawInput:function(a){function c(){var a=m.value,c=(h.inputDateParser||Date.parse)(a),e=d.xAxis[0],f=d.scroller&&d.scroller.xAxis?d.scroller.xAxis:e,t=f.dataMin;f=f.dataMax;c!==m.previousValue&&(m.previousValue=c,r(c)||(c=a.split("-"),c=Date.UTC(A(c[0]),
A(c[1])-1,A(c[2]))),r(c)&&(d.time.useUTC||(c+=6E4*(new Date).getTimezoneOffset()),z?c>b.maxInput.HCTime?c=void 0:c<t&&(c=t):c<b.minInput.HCTime?c=void 0:c>f&&(c=f),"undefined"!==typeof c&&e.setExtremes(z?c:e.min,z?e.max:c,void 0,void 0,{trigger:"rangeSelectorInput"})))}var b=this,d=b.chart,e=d.renderer.style||{},f=d.renderer,h=d.options.rangeSelector,n=b.div,z="min"===a,m,t,C=this.inputGroup;this[a+"Label"]=t=f.label(l.lang[z?"rangeSelectorFrom":"rangeSelectorTo"],this.inputGroup.offset).addClass("highcharts-range-label").attr({padding:2}).add(C);
C.offset+=t.width+5;this[a+"DateBox"]=f=f.label("",C.offset).addClass("highcharts-range-input").attr({padding:2,width:h.inputBoxWidth||90,height:h.inputBoxHeight||17,"text-align":"center"}).on("click",function(){b.showInput(a);b[a+"Input"].focus()});d.styledMode||f.attr({stroke:h.inputBoxBorderColor||"#cccccc","stroke-width":1});f.add(C);C.offset+=f.width+(z?10:0);this[a+"Input"]=m=x("input",{name:a,className:"highcharts-range-selector",type:"text"},{top:d.plotTop+"px"},n);d.styledMode||(t.css(u(e,
h.labelStyle)),f.css(u({color:"#333333"},e,h.inputStyle)),q(m,g({position:"absolute",border:0,width:"1px",height:"1px",padding:0,textAlign:"center",fontSize:e.fontSize,fontFamily:e.fontFamily,top:"-9999em"},h.inputStyle)));m.onfocus=function(){b.showInput(a)};m.onblur=function(){m===k.doc.activeElement&&c();b.hideInput(a);m.blur()};m.onchange=c;m.onkeypress=function(a){13===a.keyCode&&c()}},getPosition:function(){var a=this.chart,c=a.options.rangeSelector;a="top"===c.verticalAlign?a.plotTop-a.axisOffset[0]:
0;return{buttonTop:a+c.buttonPosition.y,inputTop:a+c.inputPosition.y-10}},getYTDExtremes:function(a,c,b){var d=this.chart.time,e=new d.Date(a),f=d.get("FullYear",e);b=b?d.Date.UTC(f,0,1):+new d.Date(f,0,1);c=Math.max(c||0,b);e=e.getTime();return{max:Math.min(a||e,e),min:c}},render:function(a,c){var b=this,d=b.chart,e=d.renderer,f=d.container,g=d.options,h=g.exporting&&!1!==g.exporting.enabled&&g.navigation&&g.navigation.buttonOptions,k=l.lang,m=b.div,t=g.rangeSelector,n=F(g.chart.style&&g.chart.style.zIndex,
0)+1;g=t.floating;var r=b.buttons;m=b.inputGroup;var u=t.buttonTheme,q=t.buttonPosition,v=t.inputPosition,R=t.inputEnabled,w=u&&u.states,y=d.plotLeft,A=b.buttonGroup,S,D=b.options.verticalAlign,B=d.legend,P=B&&B.options,G=q.y,O=v.y,Q=d.hasLoaded,U=Q?"animate":"attr",N=0,M=0;if(!1!==t.enabled){b.rendered||(b.group=S=e.g("range-selector-group").attr({zIndex:7}).add(),b.buttonGroup=A=e.g("range-selector-buttons").add(S),b.zoomText=e.text(k.rangeSelectorZoom,0,15).add(A),d.styledMode||(b.zoomText.css(t.labelStyle),
u["stroke-width"]=F(u["stroke-width"],0)),b.buttonOptions.forEach(function(a,c){r[c]=e.button(a.text,0,0,function(d){var e=a.events&&a.events.click,f;e&&(f=e.call(a,d));!1!==f&&b.clickButton(c);b.isActive=!0},u,w&&w.hover,w&&w.select,w&&w.disabled).attr({"text-align":"center"}).add(A)}),!1!==R&&(b.div=m=x("div",null,{position:"relative",height:0,zIndex:n}),f.parentNode.insertBefore(m,f),b.inputGroup=m=e.g("input-group").add(S),m.offset=0,b.drawInput("min"),b.drawInput("max")));b.zoomText[U]({x:F(y+
q.x,y)});var V=F(y+q.x,y)+b.zoomText.getBBox().width+5;b.buttonOptions.forEach(function(a,b){r[b][U]({x:V});V+=r[b].width+F(t.buttonSpacing,5)});y=d.plotLeft-d.spacing[3];b.updateButtonStates();h&&this.titleCollision(d)&&"top"===D&&"right"===q.align&&q.y+A.getBBox().height-12<(h.y||0)+h.height&&(N=-40);f=q.x-d.spacing[3];"right"===q.align?f+=N-y:"center"===q.align&&(f-=y/2);A.align({y:q.y,width:A.getBBox().width,align:q.align,x:f},!0,d.spacingBox);b.group.placed=Q;b.buttonGroup.placed=Q;!1!==R&&(N=
h&&this.titleCollision(d)&&"top"===D&&"right"===v.align&&v.y-m.getBBox().height-12<(h.y||0)+h.height+d.spacing[0]?-40:0,"left"===v.align?f=y:"right"===v.align&&(f=-Math.max(d.axisOffset[1],-N)),m.align({y:v.y,width:m.getBBox().width,align:v.align,x:v.x+f-2},!0,d.spacingBox),h=m.alignAttr.translateX+m.alignOptions.x-N+m.getBBox().x+2,f=m.alignOptions.width,k=A.alignAttr.translateX+A.getBBox().x,y=A.getBBox().width+20,(v.align===q.align||k+y>h&&h+f>k&&G<O+m.getBBox().height)&&m.attr({translateX:m.alignAttr.translateX+
(d.axisOffset[1]>=-N?0:-N),translateY:m.alignAttr.translateY+A.getBBox().height+10}),b.setInputValue("min",a),b.setInputValue("max",c),b.inputGroup.placed=Q);b.group.align({verticalAlign:D},!0,d.spacingBox);a=b.group.getBBox().height+20;c=b.group.alignAttr.translateY;"bottom"===D&&(B=P&&"bottom"===P.verticalAlign&&P.enabled&&!P.floating?B.legendHeight+F(P.margin,10):0,a=a+B-20,M=c-a-(g?0:t.y)-(d.titleOffset?d.titleOffset[2]:0)-10);if("top"===D)g&&(M=0),d.titleOffset&&d.titleOffset[0]&&(M=d.titleOffset[0]),
M+=d.margin[0]-d.spacing[0]||0;else if("middle"===D)if(O===G)M=0>O?c+void 0:c;else if(O||G)M=0>O||0>G?M-Math.min(O,G):c-a+NaN;b.group.translate(t.x,t.y+Math.floor(M));!1!==R&&(b.minInput.style.marginTop=b.group.translateY+"px",b.maxInput.style.marginTop=b.group.translateY+"px");b.rendered=!0}},getHeight:function(){var a=this.options,c=this.group,b=a.y,e=a.buttonPosition.y,f=a.inputPosition.y;if(a.height)return a.height;a=c?c.getBBox(!0).height+13+b:0;c=Math.min(f,e);if(0>f&&0>e||0<f&&0<e)a+=Math.abs(c);
return a},titleCollision:function(a){return!(a.options.title.text||a.options.subtitle.text)},update:function(a){var c=this.chart;u(!0,c.options.rangeSelector,a);this.destroy();this.init(c);c.rangeSelector.render()},destroy:function(){var a=this,c=a.minInput,b=a.maxInput;a.unMouseDown();a.unResize();B(a.buttons);c&&(c.onfocus=c.onblur=c.onchange=null);b&&(b.onfocus=b.onblur=b.onchange=null);D(a,function(b,c){b&&"chart"!==c&&(b.destroy?b.destroy():b.nodeType&&y(this[c]));b!==v.prototype[c]&&(a[c]=null)},
this)}};e.prototype.minFromRange=function(){var a=this.range,c=a.type,b=this.max,e=this.chart.time,f=function(a,b){var d="year"===c?"FullYear":"Month",f=new e.Date(a),m=e.get(d,f);e.set(d,f,m+b);m===e.get(d,f)&&e.set("Date",f,0);return f.getTime()-a};if(r(a)){var g=b-a;var h=a}else g=b+f(b,-a.count),this.chart&&(this.chart.fixedRange=b-g);var k=F(this.dataMin,Number.MIN_VALUE);r(g)||(g=k);g<=k&&(g=k,"undefined"===typeof h&&(h=f(g,a.count)),this.newMax=Math.min(g+h,this.dataMax));r(b)||(g=void 0);
return g};k.RangeSelector||(n(a,"afterGetContainer",function(){this.options.rangeSelector.enabled&&(this.rangeSelector=new v(this))}),n(a,"beforeRender",function(){var a=this.axes,c=this.rangeSelector;c&&(r(c.deferredYTDClick)&&(c.clickButton(c.deferredYTDClick),delete c.deferredYTDClick),a.forEach(function(a){a.updateNames();a.setScale()}),this.getAxisMargins(),c.render(),a=c.options.verticalAlign,c.options.floating||("bottom"===a?this.extraBottomMargin=!0:"middle"!==a&&(this.extraTopMargin=!0)))}),
n(a,"update",function(a){var c=a.options.rangeSelector;a=this.rangeSelector;var b=this.extraBottomMargin,d=this.extraTopMargin;c&&c.enabled&&!w(a)&&(this.options.rangeSelector.enabled=!0,this.rangeSelector=new v(this));this.extraTopMargin=this.extraBottomMargin=!1;a&&(a.render(),c=c&&c.verticalAlign||a.options&&a.options.verticalAlign,a.options.floating||("bottom"===c?this.extraBottomMargin=!0:"middle"!==c&&(this.extraTopMargin=!0)),this.extraBottomMargin!==b||this.extraTopMargin!==d)&&(this.isDirtyBox=
!0)}),n(a,"render",function(){var a=this.rangeSelector;a&&!a.options.floating&&(a.render(),a=a.options.verticalAlign,"bottom"===a?this.extraBottomMargin=!0:"middle"!==a&&(this.extraTopMargin=!0))}),n(a,"getMargins",function(){var a=this.rangeSelector;a&&(a=a.getHeight(),this.extraTopMargin&&(this.plotTop+=a),this.extraBottomMargin&&(this.marginBottom+=a))}),a.prototype.callbacks.push(function(a){function c(){b=a.xAxis[0].getExtremes();e=a.legend;g=null===d||void 0===d?void 0:d.options.verticalAlign;
r(b.min)&&d.render(b.min,b.max);d&&e.display&&"top"===g&&g===e.options.verticalAlign&&(f=u(a.spacingBox),f.y="vertical"===e.options.layout?a.plotTop:f.y+d.getHeight(),e.group.placed=!1,e.align(f))}var b,d=a.rangeSelector,e,f,g;if(d){var h=n(a.xAxis[0],"afterSetExtremes",function(a){d.render(a.min,a.max)});var k=n(a,"redraw",c);c()}n(a,"destroy",function(){d&&(k(),h())})}),k.RangeSelector=v)});G(k,"parts/NavigatorAxis.js",[k["parts/Globals.js"],k["parts/Utilities.js"]],function(k,a){var v=k.isTouchDevice,
n=a.addEvent,x=a.correctFloat,q=a.defined,w=a.isNumber,B=a.pick,y=function(){function a(a){this.axis=a}a.prototype.destroy=function(){this.axis=void 0};a.prototype.toFixedRange=function(a,g,k,n){var f=this.axis,r=f.chart;r=r&&r.fixedRange;var h=(f.pointRange||0)/2;a=B(k,f.translate(a,!0,!f.horiz));g=B(n,f.translate(g,!0,!f.horiz));f=r&&(g-a)/r;q(k)||(a=x(a+h));q(n)||(g=x(g-h));.7<f&&1.3>f&&(n?a=g-r:g=a+r);w(a)&&w(g)||(a=g=void 0);return{min:a,max:g}};return a}();return function(){function a(){}a.compose=
function(a){a.keepProps.push("navigatorAxis");n(a,"init",function(){this.navigatorAxis||(this.navigatorAxis=new y(this))});n(a,"zoom",function(a){var f=this.chart.options,g=f.navigator,k=this.navigatorAxis,n=f.chart.pinchType,h=f.rangeSelector;f=f.chart.zoomType;this.isXAxis&&(g&&g.enabled||h&&h.enabled)&&("y"===f?a.zoomed=!1:(!v&&"xy"===f||v&&"xy"===n)&&this.options.range&&(g=k.previousZoom,q(a.newMin)?k.previousZoom=[this.min,this.max]:g&&(a.newMin=g[0],a.newMax=g[1],k.previousZoom=void 0)));"undefined"!==
typeof a.zoomed&&a.preventDefault()})};a.AdditionsClass=y;return a}()});G(k,"parts/Navigator.js",[k["parts/Axis.js"],k["parts/Color.js"],k["parts/Globals.js"],k["parts/NavigatorAxis.js"],k["parts/Scrollbar.js"],k["parts/Utilities.js"]],function(k,a,v,n,x,q){a=a.parse;var w=q.addEvent,B=q.clamp,y=q.correctFloat,g=q.defined,f=q.destroyObjectProperties,r=q.erase,u=q.extend,D=q.find,F=q.isArray,A=q.isNumber,h=q.merge,e=q.pick,l=q.removeEvent,d=q.splat;q=v.Chart;var c=v.defaultOptions,b=v.hasTouch,p=v.isTouchDevice,
G=v.Series,H=function(a){for(var b=[],c=1;c<arguments.length;c++)b[c-1]=arguments[c];b=[].filter.call(b,A);if(b.length)return Math[a].apply(0,b)};var L="undefined"===typeof v.seriesTypes.areaspline?"line":"areaspline";u(c,{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:a("#6685c2").setOpacity(.3).get(),outlineColor:"#cccccc",outlineWidth:1,series:{type:L,
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}}});v.Renderer.prototype.symbols["navigator-handle"]=function(a,b,c,d,e){a=e.width/2;b=Math.round(a/3)+.5;e=e.height||
0;return[["M",-a-1,.5],["L",a,.5],["L",a,e+.5],["L",-a-1,e+.5],["L",-a-1,.5],["M",-b,4],["L",-b,e-3],["M",b-1,4],["L",b-1,e-3]]};var E=function(){function a(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)}a.prototype.drawHandle=
function(a,b,c,d){var e=this.navigatorOptions.handles.height;this.handles[b][d](c?{translateX:Math.round(this.left+this.height/2),translateY:Math.round(this.top+parseInt(a,10)+.5-e)}:{translateX:Math.round(this.left+parseInt(a,10)),translateY:Math.round(this.top+this.height/2-e/2-1)})};a.prototype.drawOutline=function(a,b,c,d){var e=this.navigatorOptions.maskInside,f=this.outline.strokeWidth(),m=f/2,g=f%2/2;f=this.outlineHeight;var t=this.scrollbarHeight||0,h=this.size,k=this.left-t,l=this.top;c?
(k-=m,c=l+b+g,b=l+a+g,g=[["M",k+f,l-t-g],["L",k+f,c],["L",k,c],["L",k,b],["L",k+f,b],["L",k+f,l+h+t]],e&&g.push(["M",k+f,c-m],["L",k+f,b+m])):(a+=k+t-g,b+=k+t-g,l+=m,g=[["M",k,l],["L",a,l],["L",a,l+f],["L",b,l+f],["L",b,l],["L",k+h+2*t,l]],e&&g.push(["M",a-m,l],["L",b+m,l]));this.outline[d]({d:g})};a.prototype.drawMasks=function(a,b,c,d){var e=this.left,f=this.top,m=this.height;if(c){var g=[e,e,e];var h=[f,f+a,f+b];var t=[m,m,m];var k=[a,b-a,this.size-b]}else g=[e,e+a,e+b],h=[f,f,f],t=[a,b-a,this.size-
b],k=[m,m,m];this.shades.forEach(function(a,b){a[d]({x:g[b],y:h[b],width:t[b],height:k[b]})})};a.prototype.renderElements=function(){var a=this,b=a.navigatorOptions,c=b.maskInside,d=a.chart,e=d.renderer,f,g={cursor:d.inverted?"ns-resize":"ew-resize"};a.navigatorGroup=f=e.g("navigator").attr({zIndex:8,visibility:"hidden"}).add();[!c,c,!c].forEach(function(c,m){a.shades[m]=e.rect().addClass("highcharts-navigator-mask"+(1===m?"-inside":"-outside")).add(f);d.styledMode||a.shades[m].attr({fill:c?b.maskFill:
"rgba(0,0,0,0)"}).css(1===m&&g)});a.outline=e.path().addClass("highcharts-navigator-outline").add(f);d.styledMode||a.outline.attr({"stroke-width":b.outlineWidth,stroke:b.outlineColor});b.handles.enabled&&[0,1].forEach(function(c){b.handles.inverted=d.inverted;a.handles[c]=e.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(f);if(!d.styledMode){var m=
b.handles;a.handles[c].attr({fill:m.backgroundColor,stroke:m.borderColor,"stroke-width":m.lineWidth}).css(g)}})};a.prototype.update=function(a){(this.series||[]).forEach(function(a){a.baseSeries&&delete a.baseSeries.navigatorSeries});this.destroy();h(!0,this.chart.options.navigator,this.options,a);this.init(this.chart)};a.prototype.render=function(a,b,c,d){var f=this.chart,m=this.scrollbarHeight,h,t=this.xAxis,k=t.pointRange||0;var l=t.navigatorAxis.fake?f.xAxis[0]:t;var n=this.navigatorEnabled,p,
r=this.rendered;var q=f.inverted;var u=f.xAxis[0].minRange,C=f.xAxis[0].options.maxRange;if(!this.hasDragged||g(c)){a=y(a-k/2);b=y(b+k/2);if(!A(a)||!A(b))if(r)c=0,d=e(t.width,l.width);else return;this.left=e(t.left,f.plotLeft+m+(q?f.plotWidth:0));this.size=p=h=e(t.len,(q?f.plotHeight:f.plotWidth)-2*m);f=q?m:h+2*m;c=e(c,t.toPixels(a,!0));d=e(d,t.toPixels(b,!0));A(c)&&Infinity!==Math.abs(c)||(c=0,d=f);a=t.toValue(c,!0);b=t.toValue(d,!0);var v=Math.abs(y(b-a));v<u?this.grabbedLeft?c=t.toPixels(b-u-k,
!0):this.grabbedRight&&(d=t.toPixels(a+u+k,!0)):g(C)&&y(v-k)>C&&(this.grabbedLeft?c=t.toPixels(b-C-k,!0):this.grabbedRight&&(d=t.toPixels(a+C+k,!0)));this.zoomedMax=B(Math.max(c,d),0,p);this.zoomedMin=B(this.fixedWidth?this.zoomedMax-this.fixedWidth:Math.min(c,d),0,p);this.range=this.zoomedMax-this.zoomedMin;p=Math.round(this.zoomedMax);c=Math.round(this.zoomedMin);n&&(this.navigatorGroup.attr({visibility:"visible"}),r=r&&!this.hasDragged?"animate":"attr",this.drawMasks(c,p,q,r),this.drawOutline(c,
p,q,r),this.navigatorOptions.handles.enabled&&(this.drawHandle(c,0,q,r),this.drawHandle(p,1,q,r)));this.scrollbar&&(q?(q=this.top-m,l=this.left-m+(n||!l.opposite?0:(l.titleOffset||0)+l.axisTitleMargin),m=h+2*m):(q=this.top+(n?this.height:-m),l=this.left-m),this.scrollbar.position(l,q,f,m),this.scrollbar.setRange(this.zoomedMin/(h||1),this.zoomedMax/(h||1)));this.rendered=!0}};a.prototype.addMouseEvents=function(){var a=this,c=a.chart,d=c.container,e=[],f,g;a.mouseMoveHandler=f=function(b){a.onMouseMove(b)};
a.mouseUpHandler=g=function(b){a.onMouseUp(b)};e=a.getPartsEvents("mousedown");e.push(w(c.renderTo,"mousemove",f),w(d.ownerDocument,"mouseup",g));b&&(e.push(w(c.renderTo,"touchmove",f),w(d.ownerDocument,"touchend",g)),e.concat(a.getPartsEvents("touchstart")));a.eventsToUnbind=e;a.series&&a.series[0]&&e.push(w(a.series[0].xAxis,"foundExtremes",function(){c.navigator.modifyNavigatorAxisExtremes()}))};a.prototype.getPartsEvents=function(a){var b=this,c=[];["shades","handles"].forEach(function(d){b[d].forEach(function(e,
f){c.push(w(e.element,a,function(a){b[d+"Mousedown"](a,f)}))})});return c};a.prototype.shadesMousedown=function(a,b){a=this.chart.pointer.normalize(a);var c=this.chart,d=this.xAxis,e=this.zoomedMin,f=this.left,m=this.size,h=this.range,k=a.chartX;c.inverted&&(k=a.chartY,f=this.top);if(1===b)this.grabbedCenter=k,this.fixedWidth=h,this.dragOffset=k-e;else{a=k-f-h/2;if(0===b)a=Math.max(0,a);else if(2===b&&a+h>=m)if(a=m-h,this.reversedExtremes){a-=h;var t=this.getUnionExtremes().dataMin}else var l=this.getUnionExtremes().dataMax;
a!==e&&(this.fixedWidth=h,b=d.navigatorAxis.toFixedRange(a,a+h,t,l),g(b.min)&&c.xAxis[0].setExtremes(Math.min(b.min,b.max),Math.max(b.min,b.max),!0,null,{trigger:"navigator"}))}};a.prototype.handlesMousedown=function(a,b){this.chart.pointer.normalize(a);a=this.chart;var c=a.xAxis[0],d=this.reversedExtremes;0===b?(this.grabbedLeft=!0,this.otherHandlePos=this.zoomedMax,this.fixedExtreme=d?c.min:c.max):(this.grabbedRight=!0,this.otherHandlePos=this.zoomedMin,this.fixedExtreme=d?c.max:c.min);a.fixedRange=
null};a.prototype.onMouseMove=function(a){var b=this,c=b.chart,d=b.left,f=b.navigatorSize,g=b.range,m=b.dragOffset,h=c.inverted;a.touches&&0===a.touches[0].pageX||(a=c.pointer.normalize(a),c=a.chartX,h&&(d=b.top,c=a.chartY),b.grabbedLeft?(b.hasDragged=!0,b.render(0,0,c-d,b.otherHandlePos)):b.grabbedRight?(b.hasDragged=!0,b.render(0,0,b.otherHandlePos,c-d)):b.grabbedCenter&&(b.hasDragged=!0,c<m?c=m:c>f+m-g&&(c=f+m-g),b.render(0,0,c-m,c-m+g)),b.hasDragged&&b.scrollbar&&e(b.scrollbar.options.liveRedraw,
v.svg&&!p&&!this.chart.isBoosting)&&(a.DOMType=a.type,setTimeout(function(){b.onMouseUp(a)},0)))};a.prototype.onMouseUp=function(a){var b=this.chart,c=this.xAxis,d=this.scrollbar,e=a.DOMEvent||a,f=b.inverted,m=this.rendered&&!this.hasDragged?"animate":"attr",h=Math.round(this.zoomedMax),k=Math.round(this.zoomedMin);if(this.hasDragged&&(!d||!d.hasDragged)||"scrollbar"===a.trigger){d=this.getUnionExtremes();if(this.zoomedMin===this.otherHandlePos)var l=this.fixedExtreme;else if(this.zoomedMax===this.otherHandlePos)var n=
this.fixedExtreme;this.zoomedMax===this.size&&(n=this.reversedExtremes?d.dataMin:d.dataMax);0===this.zoomedMin&&(l=this.reversedExtremes?d.dataMax:d.dataMin);c=c.navigatorAxis.toFixedRange(this.zoomedMin,this.zoomedMax,l,n);g(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:e})}"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(k,h,f,m),this.outline&&this.drawOutline(k,h,f,m),this.navigatorOptions.handles.enabled&&Object.keys(this.handles).length===this.handles.length&&(this.drawHandle(k,0,f,m),this.drawHandle(h,1,f,m)))};a.prototype.removeEvents=function(){this.eventsToUnbind&&(this.eventsToUnbind.forEach(function(a){a()}),this.eventsToUnbind=void 0);this.removeBaseSeriesEvents()};a.prototype.removeBaseSeriesEvents=
function(){var a=this.baseSeries||[];this.navigatorEnabled&&a[0]&&(!1!==this.navigatorOptions.adaptToUpdatedData&&a.forEach(function(a){l(a,"updatedData",this.updatedDataHandler)},this),a[0].xAxis&&l(a[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes))};a.prototype.init=function(a){var b=a.options,c=b.navigator,d=c.enabled,f=b.scrollbar,g=f.enabled;b=d?c.height:0;var m=g?f.height:0;this.handles=[];this.shades=[];this.chart=a;this.setBaseSeries();this.height=b;this.scrollbarHeight=m;this.scrollbarEnabled=
g;this.navigatorEnabled=d;this.navigatorOptions=c;this.scrollbarOptions=f;this.outlineHeight=b+m;this.opposite=e(c.opposite,!(d||!a.inverted));var l=this;d=l.baseSeries;f=a.xAxis.length;g=a.yAxis.length;var p=d&&d[0]&&d[0].xAxis||a.xAxis[0]||{options:{}};a.isDirtyBox=!0;l.navigatorEnabled?(l.xAxis=new k(a,h({breaks:p.options.breaks,ordinal:p.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:[m,0,-m,0],width:b}:{offsets:[0,-m,0,m],height:b})),l.yAxis=new k(a,h(c.yAxis,{id:"navigator-y-axis",alignTicks:!1,offset:0,index:g,isInternal:!0,zoomEnabled:!1},a.inverted?{width:b}:{height:b})),d||c.series.data?l.updateNavigatorSeries(!1):0===a.series.length&&(l.unbindRedraw=w(a,"beforeRedraw",function(){0<a.series.length&&!l.series&&(l.setBaseSeries(),l.unbindRedraw())})),l.reversedExtremes=a.inverted&&!l.xAxis.reversed||
!a.inverted&&l.xAxis.reversed,l.renderElements(),l.addMouseEvents()):(l.xAxis={chart:a,navigatorAxis:{fake:!0},translate:function(b,c){var d=a.xAxis[0],e=d.getExtremes(),f=d.len-2*m,g=H("min",d.options.min,e.dataMin);d=H("max",d.options.max,e.dataMax)-g;return c?b*d/f+g:f*(b-g)/d},toPixels:function(a){return this.translate(a)},toValue:function(a){return this.translate(a,!0)}},l.xAxis.navigatorAxis.axis=l.xAxis,l.xAxis.navigatorAxis.toFixedRange=n.AdditionsClass.prototype.toFixedRange.bind(l.xAxis.navigatorAxis));
a.options.scrollbar.enabled&&(a.scrollbar=l.scrollbar=new x(a.renderer,h(a.options.scrollbar,{margin:l.navigatorEnabled?0:10,vertical:a.inverted}),a),w(l.scrollbar,"changed",function(b){var c=l.size,d=c*this.to;c*=this.from;l.hasDragged=l.scrollbar.hasDragged;l.render(0,0,c,d);(a.options.scrollbar.liveRedraw||"mousemove"!==b.DOMType&&"touchmove"!==b.DOMType)&&setTimeout(function(){l.onMouseUp(b)})}));l.addBaseSeriesEvents();l.addChartEvents()};a.prototype.getUnionExtremes=function(a){var b=this.chart.xAxis[0],
c=this.xAxis,d=c.options,f=b.options,g;a&&null===b.dataMin||(g={dataMin:e(d&&d.min,H("min",f.min,b.dataMin,c.dataMin,c.min)),dataMax:e(d&&d.max,H("max",f.max,b.dataMax,c.dataMax,c.max))});return g};a.prototype.setBaseSeries=function(a,b){var c=this.chart,d=this.baseSeries=[];a=a||c.options&&c.options.navigator.baseSeries||(c.series.length?D(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)||d.push(b)});this.xAxis&&!this.xAxis.navigatorAxis.fake&&this.updateNavigatorSeries(!0,b)};a.prototype.updateNavigatorSeries=function(a,b){var f=this,g=f.chart,m=f.baseSeries,k,t,n=f.navigatorOptions.series,p,q={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}}},r=f.series=(f.series||[]).filter(function(a){var b=a.baseSeries;
return 0>m.indexOf(b)?(b&&(l(b,"updatedData",f.updatedDataHandler),delete b.navigatorSeries),a.chart&&a.destroy(),!1):!0});m&&m.length&&m.forEach(function(a){var d=a.navigatorSeries,l=u({color:a.color,visible:a.visible},F(n)?c.navigator.series:n);d&&!1===f.navigatorOptions.adaptToUpdatedData||(q.name="Navigator "+m.length,k=a.options||{},p=k.navigatorOptions||{},t=h(k,q,l,p),t.pointRange=e(l.pointRange,p.pointRange,c.plotOptions[t.type||"line"].pointRange),l=p.data||l.data,f.hasNavigatorData=f.hasNavigatorData||
!!l,t.data=l||k.data&&k.data.slice(0),d&&d.options?d.update(t,b):(a.navigatorSeries=g.initSeries(t),a.navigatorSeries.baseSeries=a,r.push(a.navigatorSeries)))});if(n.data&&(!m||!m.length)||F(n))f.hasNavigatorData=!1,n=d(n),n.forEach(function(a,b){q.name="Navigator "+(r.length+1);t=h(c.navigator.series,{color:g.series[b]&&!g.series[b].options.isInternal&&g.series[b].color||g.options.colors[b]||g.options.colors[0]},q,a);t.data=a.data;t.data&&(f.hasNavigatorData=!0,r.push(g.initSeries(t)))});a&&this.addBaseSeriesEvents()};
a.prototype.addBaseSeriesEvents=function(){var a=this,b=a.baseSeries||[];b[0]&&b[0].xAxis&&w(b[0].xAxis,"foundExtremes",this.modifyBaseAxisExtremes);b.forEach(function(b){w(b,"show",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!0,!1)});w(b,"hide",function(){this.navigatorSeries&&this.navigatorSeries.setVisible(!1,!1)});!1!==this.navigatorOptions.adaptToUpdatedData&&b.xAxis&&w(b,"updatedData",this.updatedDataHandler);w(b,"remove",function(){this.navigatorSeries&&(r(a.series,this.navigatorSeries),
g(this.navigatorSeries.options)&&this.navigatorSeries.remove(!1),delete this.navigatorSeries)})},this)};a.prototype.getBaseSeriesMin=function(a){return this.baseSeries.reduce(function(a,b){return Math.min(a,b.xData?b.xData[0]:a)},a)};a.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))};a.prototype.modifyBaseAxisExtremes=function(){var a=this.chart.navigator,
b=this.getExtremes(),c=b.dataMin,d=b.dataMax;b=b.max-b.min;var f=a.stickToMin,g=a.stickToMax,h=e(this.options.overscroll,0),k=a.series&&a.series[0],l=!!this.setExtremes;if(!this.eventArgs||"rangeSelectorButton"!==this.eventArgs.trigger){if(f){var n=c;var p=n+b}g&&(p=d+h,f||(n=Math.max(c,p-b,a.getBaseSeriesMin(k&&k.xData?k.xData[0]:-Number.MAX_VALUE))));l&&(f||g)&&A(n)&&(this.min=this.userMin=n,this.max=this.userMax=p)}a.stickToMin=a.stickToMax=null};a.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=A(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))};a.prototype.addChartEvents=function(){this.eventsToUnbind||(this.eventsToUnbind=[]);this.eventsToUnbind.push(w(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)}),w(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}))};a.prototype.destroy=function(){this.removeEvents();this.xAxis&&(r(this.chart.xAxis,this.xAxis),r(this.chart.axes,
this.xAxis));this.yAxis&&(r(this.chart.yAxis,this.yAxis),r(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){f(a)},this)};return a}();v.Navigator||(v.Navigator=E,n.compose(k),w(q,"beforeShowResetZoom",function(){var a=
this.options,b=a.navigator,c=a.rangeSelector;if((b&&b.enabled||c&&c.enabled)&&(!p&&"x"===a.chart.zoomType||p&&"x"===a.chart.pinchType))return!1}),w(q,"beforeRender",function(){var a=this.options;if(a.navigator.enabled||a.scrollbar.enabled)this.scroller=this.navigator=new E(this)}),w(q,"afterSetChartSize",function(){var a=this.legend,b=this.navigator;if(b){var c=a&&a.options;var d=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+e(c.margin,10):0)-(this.titleOffset?this.titleOffset[2]:0));d&&f&&(this.inverted?d.options.left=f.options.left=b.left:d.options.top=f.options.top=b.top,d.setAxisSize(),f.setAxisSize())}}),w(q,"update",function(a){var b=a.options.navigator||
{},c=a.options.scrollbar||{};this.navigator||this.scroller||!b.enabled&&!c.enabled||(h(!0,this.options.navigator,b),h(!0,this.options.scrollbar,c),delete a.options.navigator,delete a.options.scrollbar)}),w(q,"afterUpdate",function(a){this.navigator||this.scroller||!this.options.navigator.enabled&&!this.options.scrollbar.enabled||(this.scroller=this.navigator=new E(this),e(a.redraw,!0)&&this.redraw(a.animation))}),w(q,"afterAddSeries",function(){this.navigator&&this.navigator.setBaseSeries(null,!1)}),
w(G,"afterUpdate",function(){this.chart.navigator&&!this.options.isInternal&&this.chart.navigator.setBaseSeries(null,!1)}),q.prototype.callbacks.push(function(a){var b=a.navigator;b&&a.xAxis[0]&&(a=a.xAxis[0].getExtremes(),b.render(a.min,a.max))}));v.Navigator=E;return v.Navigator});G(k,"masters/modules/gantt.src.js",[],function(){})});
//# sourceMappingURL=gantt.js.map