/* Highcharts JS v6.1.1 (2018-06-27) 3D features for Highcharts JS @license: www.highcharts.com/license */ (function(A){"object"===typeof module&&module.exports?module.exports=A:A(Highcharts)})(function(A){(function(b){var u=b.deg2rad,z=b.pick;b.perspective3D=function(b,n,x){n=0e&&C-e>Math.PI/2+.0001?(B=B.concat(u(a,c,d,b,e,e+Math.PI/2,k,g)),B=B.concat(u(a,c,d,b,e+Math.PI/2,C,k,g))):CMath.PI/2+.0001?(B=B.concat(u(a,c,d,b,e,e-Math.PI/2,k,g)),B=B.concat(u(a,c,d,b,e-Math.PI/2,C,k,g))): ["C",a+d*Math.cos(e)-d*t*E*Math.sin(e)+k,c+b*Math.sin(e)+b*t*E*Math.cos(e)+g,a+d*Math.cos(C)+d*t*E*Math.sin(C)+k,c+b*Math.sin(C)-b*t*E*Math.cos(C)+g,a+d*Math.cos(C)+k,c+b*Math.sin(C)+g]}var z=Math.cos,p=Math.PI,n=Math.sin,x=b.animObject,y=b.charts,m=b.color,h=b.defined,w=b.deg2rad,v=b.each,l=b.extend,a=b.inArray,e=b.map,f=b.merge,k=b.perspective,g=b.pick,d=b.SVGElement,c=b.SVGRenderer,q=b.wrap,t=4*(Math.sqrt(2)-1)/3/(p/2);c.prototype.toLinePath=function(a,c){var d=[];v(a,function(a){d.push("L",a.x, a.y)});a.length&&(d[0]="M",c&&d.push("Z"));return d};c.prototype.toLineSegments=function(a){var c=[],d=!0;v(a,function(a){c.push(d?"M":"L",a.x,a.y);d=!d});return c};c.prototype.face3d=function(a){var c=this,d=this.createElement("path");d.vertexes=[];d.insidePlotArea=!1;d.enabled=!0;q(d,"attr",function(a,d){if("object"===typeof d&&(h(d.enabled)||h(d.vertexes)||h(d.insidePlotArea))){this.enabled=g(d.enabled,this.enabled);this.vertexes=g(d.vertexes,this.vertexes);this.insidePlotArea=g(d.insidePlotArea, this.insidePlotArea);delete d.enabled;delete d.vertexes;delete d.insidePlotArea;var B=k(this.vertexes,y[c.chartIndex],this.insidePlotArea),e=c.toLinePath(B,!0),B=b.shapeArea(B),B=this.enabled&&0b.faces.length;)c.faces.pop().destroy();for(;c.faces.lengthb.faces.length;)c.faces.pop().destroy();for(;c.faces.lengthb.shapeArea(a)?g=[a,0]:0>b.shapeArea(d)&&(g=[d,1]);return g};v=m([3,2,1,0],[7,6,5,4]);a=v[0];l=v[1];v=m([1,6,7,0],[4,5,2,3]);t=v[0]; f=v[1];v=m([1,2,5,6],[0,7,4,3]);m=v[0];v=v[1];1===v?p+=1E4*(1E3-d):v||(p+=1E4*d);p+=10*(!f||0<=n&&180>=n||360>n&&357.5Math.PI&&(a=2*Math.PI-a);return a}var d=a.x,e=a.y,b=a.start,g=a.end-.00001,k=a.r,t=a.innerR,l=a.depth,f=a.alpha,r=a.beta,q=Math.cos(b),v=Math.sin(b);a=Math.cos(g);var m=Math.sin(g),h=k*Math.cos(r),k=k*Math.cos(f),y=t*Math.cos(r),x=t*Math.cos(f),t=l*Math.sin(r),w=l*Math.sin(f),l=["M",d+h*q,e+k*v],l=l.concat(u(d,e,h,k,b,g,0,0)),l=l.concat(["L",d+y*a,e+x*m]),l= l.concat(u(d,e,y,x,g,b,0,0)),l=l.concat(["Z"]),A=0-A?b:g>-A?-A:b,D=gF&&bp-r&&bc&&(m=Math.min(m,1-Math.abs((a+g)/(c+g))%1));et&&(m=0>t?Math.min(m,(f+d)/(-t+f+d)):Math.min(m,1-(f+d)/(t+d)%1));ka?-1:0},q=c([{x:e,y:g,z:d},{x:f,y:g,z:d},{x:f,y:g,z:0},{x:e,y:g,z:0}]),t=c([{x:e,y:k,z:0},{x:f,y:k,z:0},{x:f,y:k,z:d},{x:e,y:k,z:d}]),r=c([{x:e,y:k,z:0},{x:e,y:k,z:d},{x:e,y:g,z:d},{x:e,y:g,z:0}]),p=c([{x:f,y:k,z:d},{x:f,y:k,z:0},{x:f,y:g,z:0},{x:f,y:g,z:d}]),x=c([{x:e,y:g,z:0},{x:f, y:g,z:0},{x:f,y:k,z:0},{x:e,y:k,z:0}]),c=c([{x:e,y:k,z:d},{x:f,y:k,z:d},{x:f,y:g,z:d},{x:e,y:g,z:d}]),w=!1,G=!1,u=!1,z=!1;n([].concat(h.xAxis,h.yAxis,h.zAxis),function(a){a&&(a.horiz?a.opposite?G=!0:w=!0:a.opposite?z=!0:u=!0)});var A=function(a,c,d){for(var b=["size","color","visible"],e={},g=0;gd*e[b][c]?b=g:d*e[g][c]===d*e[b][c]&&e[g].zthis.pos&&(b.isArray(this.start)||b.isArray(this.end))){var l=this.start||[1,0,0,1,0,0],a=this.end||[1,0,0,1,0,0];h=[];for(var e=0;6>e;e++)h.push(this.pos* a[e]+(1-this.pos)*l[e])}else h=this.end;this.elem.attr(this.prop,h,null,!0)}})(A);(function(b){function u(d,c,b){if(!d.chart.is3d()||"colorAxis"===d.coll)return c;var g=d.chart,k=y*g.options.chart.options3d.alpha,f=y*g.options.chart.options3d.beta,l=a(b&&d.options.title.position3d,d.options.labels.position3d);b=a(b&&d.options.title.skew3d,d.options.labels.skew3d);var h=g.frame3d,q=g.plotLeft,m=g.plotWidth+q,n=g.plotTop,p=g.plotHeight+n,g=!1,w=0,x=0,u={x:0,y:1,z:0};c=d.swapZ({x:c.x,y:c.y,z:0});if(d.isZAxis)if(d.opposite){if(null=== h.axes.z.top)return{};x=c.y-n;c.x=h.axes.z.top.x;c.y=h.axes.z.top.y;q=h.axes.z.top.xDir;g=!h.top.frontFacing}else{if(null===h.axes.z.bottom)return{};x=c.y-p;c.x=h.axes.z.bottom.x;c.y=h.axes.z.bottom.y;q=h.axes.z.bottom.xDir;g=!h.bottom.frontFacing}else if(d.horiz)if(d.opposite){if(null===h.axes.x.top)return{};x=c.y-n;c.y=h.axes.x.top.y;c.z=h.axes.x.top.z;q=h.axes.x.top.xDir;g=!h.top.frontFacing}else{if(null===h.axes.x.bottom)return{};x=c.y-p;c.y=h.axes.x.bottom.y;c.z=h.axes.x.bottom.z;q=h.axes.x.bottom.xDir; g=!h.bottom.frontFacing}else if(d.opposite){if(null===h.axes.y.right)return{};w=c.x-m;c.x=h.axes.y.right.x;c.z=h.axes.y.right.z;q=h.axes.y.right.xDir;q={x:q.z,y:q.y,z:-q.x}}else{if(null===h.axes.y.left)return{};w=c.x-q;c.x=h.axes.y.left.x;c.z=h.axes.y.left.z;q=h.axes.y.left.xDir}"chart"!==l&&("flap"===l?d.horiz?(f=Math.sin(k),k=Math.cos(k),d.opposite&&(f=-f),g&&(f=-f),u={x:q.z*f,y:k,z:-q.x*f}):q={x:Math.cos(f),y:0,z:Math.sin(f)}:"ortho"===l?d.horiz?(u=Math.cos(k),l=Math.sin(f)*u,k=-Math.sin(k),f= -u*Math.cos(f),u={x:q.y*f-q.z*k,y:q.z*l-q.x*f,z:q.x*k-q.y*l},k=1/Math.sqrt(u.x*u.x+u.y*u.y+u.z*u.z),g&&(k=-k),u={x:k*u.x,y:k*u.y,z:k*u.z}):q={x:Math.cos(f),y:0,z:Math.sin(f)}:d.horiz?u={x:Math.sin(f)*Math.sin(k),y:Math.cos(k),z:-Math.cos(f)*Math.sin(k)}:q={x:Math.cos(f),y:0,z:Math.sin(f)});c.x+=w*q.x+x*u.x;c.y+=w*q.y+x*u.y;c.z+=w*q.z+x*u.z;g=v([c],d.chart)[0];b&&(0>e(v([c,{x:c.x+q.x,y:c.y+q.y,z:c.z+q.z},{x:c.x+u.x,y:c.y+u.y,z:c.z+u.z}],d.chart))&&(q={x:-q.x,y:-q.y,z:-q.z}),d=v([{x:c.x,y:c.y,z:c.z}, {x:c.x+q.x,y:c.y+q.y,z:c.z+q.z},{x:c.x+u.x,y:c.y+u.y,z:c.z+u.z}],d.chart),g.matrix=[d[1].x-d[0].x,d[1].y-d[0].y,d[2].x-d[0].x,d[2].y-d[0].y,g.x,g.y],g.matrix[4]-=g.x*g.matrix[0]+g.y*g.matrix[2],g.matrix[5]-=g.x*g.matrix[1]+g.y*g.matrix[3]);return g}var z,p=b.addEvent,n=b.Axis,x=b.Chart,y=b.deg2rad,m=b.each,h=b.extend,w=b.merge,v=b.perspective,l=b.perspective3D,a=b.pick,e=b.shapeArea,f=b.splat,k=b.Tick,g=b.wrap;w(!0,n.prototype.defaultOptions,{labels:{position3d:"offset",skew3d:!1},title:{position3d:null, skew3d:null}});p(n,"afterSetOptions",function(){var d;this.chart.is3d&&this.chart.is3d()&&"colorAxis"!==this.coll&&(d=this.options,d.tickWidth=a(d.tickWidth,0),d.gridLineWidth=a(d.gridLineWidth,1))});g(n.prototype,"getPlotLinePath",function(a){var c=a.apply(this,[].slice.call(arguments,1));if(!this.chart.is3d()||"colorAxis"===this.coll||null===c)return c;var d=this.chart,b=d.options.chart.options3d,b=this.isZAxis?d.plotWidth:b.depth,d=d.frame3d,c=[this.swapZ({x:c[1],y:c[2],z:0}),this.swapZ({x:c[1], y:c[2],z:b}),this.swapZ({x:c[4],y:c[5],z:0}),this.swapZ({x:c[4],y:c[5],z:b})],b=[];this.horiz?(this.isZAxis?(d.left.visible&&b.push(c[0],c[2]),d.right.visible&&b.push(c[1],c[3])):(d.front.visible&&b.push(c[0],c[2]),d.back.visible&&b.push(c[1],c[3])),d.top.visible&&b.push(c[0],c[1]),d.bottom.visible&&b.push(c[2],c[3])):(d.front.visible&&b.push(c[0],c[2]),d.back.visible&&b.push(c[1],c[3]),d.left.visible&&b.push(c[0],c[1]),d.right.visible&&b.push(c[2],c[3]));b=v(b,this.chart,!1);return this.chart.renderer.toLineSegments(b)}); g(n.prototype,"getLinePath",function(a){return this.chart.is3d()&&"colorAxis"!==this.coll?[]:a.apply(this,[].slice.call(arguments,1))});g(n.prototype,"getPlotBandPath",function(a){if(!this.chart.is3d()||"colorAxis"===this.coll)return a.apply(this,[].slice.call(arguments,1));var c=arguments,d=c[2],b=[],c=this.getPlotLinePath(c[1]),d=this.getPlotLinePath(d);if(c&&d)for(var e=0;e=u.min&&h<=u.max:!1):m.plotZ=0,m.axisXpos=m.plotX,m.axisYpos=m.plotY,m.axisZpos=m.plotZ,y.push({x:m.plotX,y:m.plotY,z:m.plotZ});b=z(y,b,!0);for(w=0;wh&&(c[a[1]]+=c[a[0]]+g,c[a[0]]=-g,h=0);h+c[a[1]]>b[a[0]+"Axis"].len&&0!==c[a[1]]&&(c[a[1]]=b[a[0]+"Axis"].len-c[a[0]]);if(0!==c[a[1]]&&(c[a[0]]>=b[a[0]+"Axis"].len||c[a[0]]+c[a[1]]<=g)){for(var e in c)c[e]=0;d.outside3dPlot=!0}});d.shapeType="cuboid";c.z=k;c.depth=f;c.insidePlotArea=!0;e=n([{x:e[0],y:e[1],z:k}],a,!0)[0];d.tooltipPos=[e.x,e.y]}});b.z=k};v(m.column.prototype,"animate",function(b){if(this.chart.is3d()){var a= arguments[1],e=this.yAxis,f=this,k=this.yAxis.reversed;w&&(a?p(f.data,function(a){null!==a.y&&(a.height=a.shapeArgs.height,a.shapey=a.shapeArgs.y,a.shapeArgs.height=1,k||(a.shapeArgs.y=a.stackY?a.plotY+e.translate(a.stackY):a.plotY+(a.negative?-a.height:a.height)))}):(p(f.data,function(a){null!==a.y&&(a.shapeArgs.height=a.height,a.shapeArgs.y=a.shapey,a.graphic&&a.graphic.animate(a.shapeArgs,f.options.animation))}),this.drawDataLabels(),f.animate=null))}else b.apply(this,[].slice.call(arguments,1))}); v(m.column.prototype,"plotGroup",function(b,a,e,f,k,g){this.chart.is3d()&&g&&!this[a]&&(this.chart.columnGroup||(this.chart.columnGroup=this.chart.renderer.g("columnGroup").add(g)),this[a]=this.chart.columnGroup,this.chart.columnGroup.attr(this.getPlotBox()),this[a].survive=!0);return b.apply(this,Array.prototype.slice.call(arguments,1))});v(m.column.prototype,"setVisible",function(b,a){var e=this,f;e.chart.is3d()&&p(e.data,function(b){f=(b.visible=b.options.visible=a=void 0===a?!b.visible:a)?"visible": "hidden";e.options.data[h(b,e.data)]=b.options;b.graphic&&b.graphic.attr({visibility:f})});b.apply(this,Array.prototype.slice.call(arguments,1))});m.column.prototype.handle3dGrouping=!0;z(y,"afterInit",function(){if(this.chart.is3d()&&this.handle3dGrouping){var b=this.options,a=b.grouping,e=b.stacking,f=x(this.yAxis.options.reversedStacks,!0),k=0;if(void 0===a||a){a=this.chart.retrieveStacks(e);k=b.stack||0;for(e=0;e