/*
 Highcharts JS v5.0.0 (2016-09-29)

 (c) 2009-2016 Torstein Honsi

 License: www.highcharts.com/license
*/
(function(h){"object"===typeof module&&module.exports?module.exports=h:h(Highcharts)})(function(h){(function(d){function h(){return Array.prototype.slice.call(arguments,1)}function v(e){e.apply(this);this.drawBreaks(this.xAxis,["x"]);this.drawBreaks(this.yAxis,t(this.pointArrayMap,["y"]))}var t=d.pick,q=d.wrap,u=d.each,y=d.extend,w=d.fireEvent,r=d.Axis,z=d.Series;y(r.prototype,{isInBreak:function(e,g){var b=e.repeat||Infinity,c=e.from,a=e.to-e.from,b=g>=c?(g-c)%b:b-(c-g)%b;return e.inclusive?b<=a:
b<a&&0!==b},isInAnyBreak:function(e,g){var b=this.options.breaks,c=b&&b.length,a,f,n;if(c){for(;c--;)this.isInBreak(b[c],e)&&(a=!0,f||(f=t(b[c].showPoints,this.isXAxis?!1:!0)));n=a&&g?a&&!f:a}return n}});q(r.prototype,"setTickPositions",function(e){e.apply(this,Array.prototype.slice.call(arguments,1));if(this.options.breaks){var g=this.tickPositions,b=this.tickPositions.info,c=[],a;for(a=0;a<g.length;a++)this.isInAnyBreak(g[a])||c.push(g[a]);this.tickPositions=c;this.tickPositions.info=b}});q(r.prototype,
"init",function(e,g,b){b.breaks&&b.breaks.length&&(b.ordinal=!1);e.call(this,g,b);if(this.options.breaks){var c=this;c.isBroken=!0;this.val2lin=function(a){var f=a,n,b;for(b=0;b<c.breakArray.length;b++)if(n=c.breakArray[b],n.to<=a)f-=n.len;else if(n.from>=a)break;else if(c.isInBreak(n,a)){f-=a-n.from;break}return f};this.lin2val=function(a){var f,b;for(b=0;b<c.breakArray.length&&!(f=c.breakArray[b],f.from>=a);b++)f.to<a?a+=f.len:c.isInBreak(f,a)&&(a+=f.len);return a};this.setExtremes=function(a,c,
b,e,g){for(;this.isInAnyBreak(a);)a-=this.closestPointRange;for(;this.isInAnyBreak(c);)c-=this.closestPointRange;r.prototype.setExtremes.call(this,a,c,b,e,g)};this.setAxisTranslation=function(a){r.prototype.setAxisTranslation.call(this,a);var b=c.options.breaks;a=[];var e=[],g=0,m,k,p=c.userMin||c.min,d=c.userMax||c.max,l,h;for(h in b)k=b[h],m=k.repeat||Infinity,c.isInBreak(k,p)&&(p+=k.to%m-p%m),c.isInBreak(k,d)&&(d-=d%m-k.from%m);for(h in b){k=b[h];l=k.from;for(m=k.repeat||Infinity;l-m>p;)l-=m;for(;l<
p;)l+=m;for(;l<d;l+=m)a.push({value:l,move:"in"}),a.push({value:l+(k.to-k.from),move:"out",size:k.breakSize})}a.sort(function(b,a){return b.value===a.value?("in"===b.move?0:1)-("in"===a.move?0:1):b.value-a.value});b=0;l=p;for(h in a)k=a[h],b+="in"===k.move?1:-1,1===b&&"in"===k.move&&(l=k.value),0===b&&(e.push({from:l,to:k.value,len:k.value-l-(k.size||0)}),g+=k.value-l-(k.size||0));c.breakArray=e;w(c,"afterBreaks");c.transA*=(d-c.min)/(d-p-g);c.min=p;c.max=d}}});q(z.prototype,"generatePoints",function(e){e.apply(this,
h(arguments));var g=this.xAxis,b=this.yAxis,c=this.points,a,f=c.length,d=this.options.connectNulls,x;if(g&&b&&(g.options.breaks||b.options.breaks))for(;f--;)a=c[f],x=null===a.y&&!1===d,x||!g.isInAnyBreak(a.x,!0)&&!b.isInAnyBreak(a.y,!0)||(c.splice(f,1),this.data[f]&&this.data[f].destroyElements())});d.Series.prototype.drawBreaks=function(e,g){var b=this,c=b.points,a,f,d,h;u(g,function(g){a=e.breakArray||[];f=e.isXAxis?e.min:t(b.options.threshold,e.min);u(c,function(b){h=t(b["stack"+g.toUpperCase()],
b[g]);u(a,function(a){d=!1;if(f<a.from&&h>a.to||f>a.from&&h<a.from)d="pointBreak";else if(f<a.from&&h>a.from&&h<a.to||f>a.from&&h>a.to&&h<a.from)d="pointInBreak";d&&w(e,d,{point:b,brk:a})})})})};q(d.seriesTypes.column.prototype,"drawPoints",v);q(d.Series.prototype,"drawPoints",v)})(h)});
