/* Highcharts JS v9.1.1 (2021-06-03) Accessibility module (c) 2010-2021 Highsoft AS Author: Oystein Moseng License: www.highcharts.com/license */ 'use strict';(function(b){"object"===typeof module&&module.exports?(b["default"]=b,module.exports=b):"function"===typeof define&&define.amd?define("highcharts/modules/accessibility",["highcharts"],function(v){b(v);b.Highcharts=v;return b}):b("undefined"!==typeof Highcharts?Highcharts:void 0)})(function(b){function v(b,e,r,p){b.hasOwnProperty(e)||(b[e]=p.apply(null,r))}b=b?b._modules:{};v(b,"Accessibility/Utils/HTMLUtilities.js",[b["Core/Globals.js"],b["Core/Utilities.js"]],function(b,e){var w=b.doc, p=b.win,u=e.merge;return{addClass:function(b,l){b.classList?b.classList.add(l):0>b.className.indexOf(l)&&(b.className+=l)},escapeStringForHTML:function(b){return b.replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/")},getElement:function(b){return w.getElementById(b)},getFakeMouseEvent:function(b){if("function"===typeof p.MouseEvent)return new p.MouseEvent(b);if(w.createEvent){var t=w.createEvent("MouseEvent");if(t.initMouseEvent)return t.initMouseEvent(b, !0,!0,p,"click"===b?1:0,0,0,0,0,!1,!1,!1,!1,0,null),t}return{type:b}},getHeadingTagNameForElement:function(b){var t=function(b){b=parseInt(b.slice(1),10);return"h"+Math.min(6,b+1)},m=function(b){var h;a:{for(h=b;h=h.previousSibling;){var g=h.tagName||"";if(/H[1-6]/.test(g)){h=g;break a}}h=""}if(h)return t(h);b=b.parentElement;if(!b)return"p";h=b.tagName;return/H[1-6]/.test(h)?t(h):m(b)};return m(b)},removeElement:function(b){b&&b.parentNode&&b.parentNode.removeChild(b)},reverseChildNodes:function(b){for(var t= b.childNodes.length;t--;)b.appendChild(b.childNodes[t])},setElAttrs:function(b,e){Object.keys(e).forEach(function(m){var h=e[m];null===h?b.removeAttribute(m):b.setAttribute(m,h)})},stripHTMLTagsFromString:function(b){return"string"===typeof b?b.replace(/<\/?[^>]+(>|$)/g,""):b},visuallyHideElement:function(b){u(!0,b.style,{position:"absolute",width:"1px",height:"1px",overflow:"hidden",whiteSpace:"nowrap",clip:"rect(1px, 1px, 1px, 1px)",marginTop:"-3px","-ms-filter":"progid:DXImageTransform.Microsoft.Alpha(Opacity=1)", filter:"alpha(opacity=1)",opacity:"0.01"})}}});v(b,"Accessibility/Utils/ChartUtilities.js",[b["Accessibility/Utils/HTMLUtilities.js"],b["Core/Utilities.js"]],function(b,e){function w(a){var c=a.chart,d={},f="Seconds";d.Seconds=((a.max||0)-(a.min||0))/1E3;d.Minutes=d.Seconds/60;d.Hours=d.Minutes/60;d.Days=d.Hours/24;["Minutes","Hours","Days"].forEach(function(a){2b||d!==c-1;g.a11yProxyElement&&(g.a11yProxyElement.style.visibility=d?"hidden":"visible")})},onChartRender:function(){m(this.chart)?this.updateProxiesPositions():this.removeProxies()},onChartUpdate:function(){this.updateLegendTitle()},updateProxiesPositions:function(){for(var a=0,c=this.proxyElementsList;a/g," "));a=a.langFormat("accessibility.legend.legendLabel"+(c?"":"NoTitle"),{chart:a,legendTitle:c});this.legendProxyGroup&&this.legendProxyGroup.setAttribute("aria-label",a)},addLegendProxyGroup:function(){this.legendProxyGroup=this.addProxyGroup({"aria-label":"_placeholder_",role:"all"===this.chart.options.accessibility.landmarkVerbosity?"region":null})},addLegendListContainer:function(){if(this.legendProxyGroup){var a= this.legendListContainer=this.createElement("ul");a.style.listStyle="none";this.legendProxyGroup.appendChild(a)}},proxyLegendItems:function(){var a=this;(this.chart.legend&&this.chart.legend.allItems||[]).forEach(function(c){c.legendItem&&c.legendItem.element&&a.proxyLegendItem(c)})},proxyLegendItem:function(a){if(a.legendItem&&a.legendGroup&&this.legendListContainer){var c=this.chart.langFormat("accessibility.legend.legendItem",{chart:this.chart,itemName:f(a.name),item:a});c={tabindex:-1,"aria-pressed":a.visible, "aria-label":c};var b=a.legendGroup.div?a.legendItem:a.legendGroup,g=this.createElement("li");this.legendListContainer.appendChild(g);a.a11yProxyElement=this.createProxyButton(a.legendItem,g,c,b);this.proxyElementsList.push({item:a,element:a.a11yProxyElement,posElement:b})}},getKeyboardNavigation:function(){var a=this.keyCodes,c=this,b=this.chart;return new t(b,{keyCodeMap:[[[a.left,a.right,a.up,a.down],function(a){return c.onKbdArrowKey(this,a)}],[[a.enter,a.space],function(b){return e.isFirefox&& b===a.space?this.response.success:c.onKbdClick(this)}]],validate:function(){return c.shouldHaveLegendNavigation()},init:function(a){return c.onKbdNavigationInit(a)},terminate:function(){b.legend.allItems.forEach(function(a){return a.setState("",!0)})}})},onKbdArrowKey:function(a,c){var b=this.keyCodes,g=a.response,d=this.chart,f=d.options.accessibility,n=d.legend.allItems.length;c=c===b.left||c===b.up?-1:1;return d.highlightLegendItem(this.highlightedLegendItemIx+c)?(this.highlightedLegendItemIx+= c,g.success):1=n&&c||0<=n&&!c||5>k||a(g))&&k"+b+"":""})}var t=b.escapeStringForHTML,l=b.stripHTMLTagsFromString;return{getAnnotationsInfoHTML:function(b){var h=b.annotations;return h&&h.length?'
    '+u(b).join(" ")+"
":""},getAnnotationLabelDescription:p,getAnnotationListItems:u,getPointAnnotationTexts:function(b){var h=e(b.series.chart).filter(function(h){return-1b&&a.graphic&&a.graphic.element)})||null:null}function m(a){var b=a.chart.options.accessibility.series.pointDescriptionEnabledThreshold; return!!(!1!==b&&a.points&&a.points.length>=b)}function h(a){var b=a.options.accessibility||{};return!m(a)&&!b.exposeAsGroupOnly}function q(a){var b=a.chart.options.accessibility.keyboardNavigation.seriesNavigation;return!(!a.points||!(a.points.length"," "),k=a.id&&0>a.id.indexOf("highcharts-"),f="x, "+a.x;return a.name||b||c||(k?a.id:f)}function n(a,b,c){var k=b||"",d=c||"";return a.series.pointArrayMap.reduce(function(b,c){b+=b.length?", ":"";var f=g(a,G(a[c],a.options[c]));return b+(c+": "+k+f+d)},"")}function E(a){var b= a.series,c=b.chart.options.accessibility.point||{},k=b.tooltipOptions||{},d=c.valuePrefix||k.valuePrefix||"";c=c.valueSuffix||k.valueSuffix||"";k=g(a,a["undefined"!==typeof a.value?"value":"y"]);return a.isNull?b.chart.langFormat("accessibility.series.nullPointValue",{point:a}):b.pointArrayMap?n(a,d,c):d+k+c}function C(a){var b=a.series,c=b.chart,k=c.options.accessibility.point.valueDescriptionFormat,d=(b=G(b.xAxis&&b.xAxis.options.accessibility&&b.xAxis.options.accessibility.enabled,!c.angular))? f(a):"";a={point:a,index:I(a.index)?a.index+1:"",xDescription:d,value:E(a),separator:b?", ":""};return z(k,a,c)}function w(a){var b=a.series,c=b.chart,k=C(a),d=a.options&&a.options.accessibility&&a.options.accessibility.description;d=d?" "+d:"";b=1b&&da.dataMax&&(c=a.dataMax,d=c-f);this.setExtremes(d,c)};e.prototype=new b; p(e.prototype,{init:function(){var b=this,a=this.chart;["afterShowResetZoom","afterDrilldown","drillupall"].forEach(function(c){b.addEvent(a,c,function(){b.updateProxyOverlays()})})},onChartUpdate:function(){var b=this.chart,a=this;b.mapNavButtons&&b.mapNavButtons.forEach(function(c,d){l(b,c.element);a.setMapNavButtonAttrs(c.element,"accessibility.zoom.mapZoom"+(d?"Out":"In"))})},setMapNavButtonAttrs:function(b,a){var c=this.chart;a=c.langFormat(a,{chart:c});h(b,{tabindex:-1,role:"button","aria-label":a})}, onChartRender:function(){this.updateProxyOverlays()},updateProxyOverlays:function(){var b=this.chart;m(this.drillUpProxyGroup);m(this.resetZoomProxyGroup);b.resetZoomButton&&this.recreateProxyButtonAndGroup(b.resetZoomButton,"resetZoomProxyButton","resetZoomProxyGroup",b.langFormat("accessibility.zoom.resetZoomButton",{chart:b}));b.drillUpButton&&this.recreateProxyButtonAndGroup(b.drillUpButton,"drillUpProxyButton","drillUpProxyGroup",b.langFormat("accessibility.drillUpButton",{chart:b,buttonText:b.getDrilldownBackText()}))}, recreateProxyButtonAndGroup:function(b,a,c,d){m(this[c]);this[c]=this.addProxyGroup();this[a]=this.createProxyButton(b,this[c],{"aria-label":d,tabindex:-1})},getMapZoomNavigation:function(){var b=this.keyCodes,a=this.chart,c=this;return new u(a,{keyCodeMap:[[[b.up,b.down,b.left,b.right],function(a){return c.onMapKbdArrow(this,a)}],[[b.tab],function(a,b){return c.onMapKbdTab(this,b)}],[[b.space,b.enter],function(){return c.onMapKbdClick(this)}]],validate:function(){return!!(a.mapZoom&&a.mapNavButtons&& a.mapNavButtons.length)},init:function(a){return c.onMapNavInit(a)}})},onMapKbdArrow:function(b,a){var c=this.keyCodes;this.chart[a===c.up||a===c.down?"yAxis":"xAxis"][0].panStep(a===c.left||a===c.up?-1:1);return b.response.success},onMapKbdTab:function(b,a){var c=this.chart;b=b.response;var d=(a=a.shiftKey)&&!this.focusedMapNavButtonIx||!a&&this.focusedMapNavButtonIx;c.mapNavButtons[this.focusedMapNavButtonIx].setState(0);if(d)return c.mapZoom(),b[a?"prev":"next"];this.focusedMapNavButtonIx+=a?-1: 1;a=c.mapNavButtons[this.focusedMapNavButtonIx];c.setFocusToElement(a.box,a.element);a.setState(2);return b.success},onMapKbdClick:function(b){this.fakeClickEvent(this.chart.mapNavButtons[this.focusedMapNavButtonIx].element);return b.response.success},onMapNavInit:function(b){var a=this.chart,c=a.mapNavButtons[0],d=a.mapNavButtons[1];c=0n-h,r=e=864E5*{month:28,year:365}[A]*G-l&&f-36E5<=864E5*{month:31,year:366}[A]*G+l?e=!0:"ytd"===A?(e=y-m+l===f,u=!b):"all"===A&&(e=d.max-d.min>=n-h,t=!b&&x&&e);A=!p&&(O||r||t||g);G=b&&e||e&&!x&&!u||b&&a.frozenStates;A?I=3:G&&(x=!0, I=2);L.state!==I&&(L.setState(I),c&&(c.options[k+1].disabled=A,2===I&&(c.selectedIndex=k+1)),0===I&&q===k&&a.setSelected())})};e.prototype.computeButtonRange=function(a){var b=a.type,c=a.count||1,d={millisecond:1,second:1E3,minute:6E4,hour:36E5,day:864E5,week:6048E5};if(d[b])a._range=d[b]*c;else if("month"===b||"year"===b)a._range=864E5*{month:30,year:365}[b]*c;a._offsetMin=B(a.offsetMin,0);a._offsetMax=B(a.offsetMax,0);a._range+=a._offsetMax-a._offsetMin};e.prototype.getInputValue=function(a){a= "min"===a?this.minInput:this.maxInput;var b=this.chart.options.rangeSelector,c=this.chart.time;return a?("text"===a.type&&b.inputDateParser||this.defaultInputDateParser)(a.value,c.useUTC,c):0};e.prototype.setInputValue=function(a,b){var d=this.options,k=this.chart.time,f="min"===a?this.minInput:this.maxInput;a="min"===a?this.minDateBox:this.maxDateBox;if(f){var g=f.getAttribute("data-hc-time");g=c(g)?Number(g):void 0;c(b)&&(c(g)&&f.setAttribute("data-hc-time-previous",g),f.setAttribute("data-hc-time", b),g=b);f.value=k.dateFormat(this.inputTypeFormats[f.type]||d.inputEditDateFormat,g);a&&a.attr({text:k.dateFormat(d.inputDateFormat,g)})}};e.prototype.setInputExtremes=function(a,b,c){if(a="min"===a?this.minInput:this.maxInput){var d=this.inputTypeFormats[a.type],k=this.chart.time;d&&(b=k.dateFormat(d,b),a.min!==b&&(a.min=b),c=k.dateFormat(d,c),a.max!==c&&(a.max=c))}};e.prototype.showInput=function(b){var c="min"===b?this.minDateBox:this.maxDateBox;if((b="min"===b?this.minInput:this.maxInput)&&c&& this.inputGroup){var d="text"===b.type,k=this.inputGroup,f=k.translateX;k=k.translateY;var g=this.options.inputBoxWidth;a(b,{width:d?c.width+(g?-2:20)+"px":"auto",height:d?c.height-2+"px":"auto",border:"2px solid silver"});d&&g?a(b,{left:f+c.x+"px",top:k+"px"}):a(b,{left:Math.min(Math.round(c.x+f-(b.offsetWidth-c.width)/2),this.chart.chartWidth-b.offsetWidth)+"px",top:k-(b.offsetHeight-c.height)/2+"px"})}};e.prototype.hideInput=function(b){(b="min"===b?this.minInput:this.maxInput)&&a(b,{top:"-9999em", border:0,width:"1px",height:"1px"})};e.prototype.defaultInputDateParser=function(a,b,c){var d=a.split("/").join("-").split(" ").join("T");-1===d.indexOf("T")&&(d+="T00:00");if(b)d+="Z";else{var k;if(k=r.isSafari)k=d,k=!(6=k?"+"+F(-k)+":00":"-"+F(k)+":00")}d=Date.parse(d);w(d)||(a=a.split("-"),d=Date.UTC(D(a[0]),D(a[1])-1,D(a[2])));c&&b&&w(d)&&(d+=c.getTimezoneOffset(d));return d}; e.prototype.drawInput=function(b){function c(){var a=e.getInputValue(b),c=d.xAxis[0],k=d.scroller&&d.scroller.xAxis?d.scroller.xAxis:c,f=k.dataMin;k=k.dataMax;var g=e.maxInput,h=e.minInput;a!==Number(l.getAttribute("data-hc-time-previous"))&&w(a)&&(l.setAttribute("data-hc-time-previous",a),p&&g&&w(f)?a>Number(g.getAttribute("data-hc-time"))?a=void 0:ak&&(a=k)),"undefined"!==typeof a&&c.setExtremes(p?a:c.min,p?c.max:a,void 0,void 0, {trigger:"rangeSelectorInput"}))}var d=this.chart,k=this.div,f=this.inputGroup,e=this,y=d.renderer.style||{},q=d.renderer,x=d.options.rangeSelector,p="min"===b,z=h.lang[p?"rangeSelectorFrom":"rangeSelectorTo"];z=q.label(z,0).addClass("highcharts-range-label").attr({padding:z?2:0,height:z?x.inputBoxHeight:0}).add(f);q=q.label("",0).addClass("highcharts-range-input").attr({padding:2,width:x.inputBoxWidth,height:x.inputBoxHeight,"text-align":"center"}).on("click",function(){e.showInput(b);e[b+"Input"].focus()}); d.styledMode||q.attr({stroke:x.inputBoxBorderColor,"stroke-width":1});q.add(f);var l=g("input",{name:b,className:"highcharts-range-selector"},void 0,k);l.setAttribute("type",m(x.inputDateFormat||"%b %e, %Y"));d.styledMode||(z.css(v(y,x.labelStyle)),q.css(v({color:u.neutralColor80},y,x.inputStyle)),a(l,n({position:"absolute",border:0,boxShadow:"0 0 15px rgba(0,0,0,0.3)",width:"1px",height:"1px",padding:0,textAlign:"center",fontSize:y.fontSize,fontFamily:y.fontFamily,top:"-9999em"},x.inputStyle))); l.onfocus=function(){e.showInput(b)};l.onblur=function(){l===r.doc.activeElement&&c();e.hideInput(b);e.setInputValue(b);l.blur()};var t=!1;l.onchange=function(){t||(c(),e.hideInput(b),l.blur())};l.onkeypress=function(a){13===a.keyCode&&c()};l.onkeydown=function(a){t=!0;38!==a.keyCode&&40!==a.keyCode||c()};l.onkeyup=function(){t=!1};return{dateBox:q,input:l,label:z}};e.prototype.getPosition=function(){var a=this.chart,b=a.options.rangeSelector;a="top"===b.verticalAlign?a.plotTop-a.axisOffset[0]:0; return{buttonTop:a+b.buttonPosition.y,inputTop:a+b.inputPosition.y-10}};e.prototype.getYTDExtremes=function(a,b,c){var d=this.chart.time,f=new d.Date(a),k=d.get("FullYear",f);c=c?d.Date.UTC(k,0,1):+new d.Date(k,0,1);b=Math.max(b,c);f=f.getTime();return{max:Math.min(a||f,f),min:b}};e.prototype.render=function(a,b){var d=this.chart,f=d.renderer,k=d.container,e=d.options,h=e.rangeSelector,n=B(e.chart.style&&e.chart.style.zIndex,0)+1;e=h.inputEnabled;if(!1!==h.enabled){this.rendered||(this.group=f.g("range-selector-group").attr({zIndex:7}).add(), this.div=g("div",void 0,{position:"relative",height:0,zIndex:n}),this.buttonOptions.length&&this.renderButtons(),k.parentNode&&k.parentNode.insertBefore(this.div,k),e&&(this.inputGroup=f.g("input-group").add(this.group),f=this.drawInput("min"),this.minDateBox=f.dateBox,this.minLabel=f.label,this.minInput=f.input,f=this.drawInput("max"),this.maxDateBox=f.dateBox,this.maxLabel=f.label,this.maxInput=f.input));if(e&&(this.setInputValue("min",a),this.setInputValue("max",b),a=d.scroller&&d.scroller.getUnionExtremes()|| d.xAxis[0]||{},c(a.dataMin)&&c(a.dataMax)&&(d=d.xAxis[0].minRange||0,this.setInputExtremes("min",a.dataMin,Math.min(a.dataMax,this.getInputValue("max"))-d),this.setInputExtremes("max",Math.max(a.dataMin,this.getInputValue("min"))+d,a.dataMax)),this.inputGroup)){var y=0;[this.minLabel,this.minDateBox,this.maxLabel,this.maxDateBox].forEach(function(a){if(a){var b=a.getBBox().width;b&&(a.attr({x:y}),y+=b+h.inputSpacing)}})}this.alignElements();this.rendered=!0}};e.prototype.renderButtons=function(){var a= this,b=this.buttons,c=this.options,d=h.lang,f=this.chart.renderer,e=v(c.buttonTheme),n=e&&e.states,y=e.width||28;delete e.width;delete e.states;this.buttonGroup=f.g("range-selector-buttons").add(this.group);var m=this.dropdown=g("select",void 0,{position:"absolute",width:"1px",height:"1px",padding:0,border:0,top:"-9999em",cursor:"pointer",opacity:.0001},this.div);q(m,"touchstart",function(){m.style.fontSize="16px"});[[r.isMS?"mouseover":"mouseenter"],[r.isMS?"mouseout":"mouseleave"],["change","click"]].forEach(function(c){var d= c[0],f=c[1];q(m,d,function(){var c=b[a.currentButtonIndex()];c&&C(c.element,f||d)})});this.zoomText=f.label(d&&d.rangeSelectorZoom||"",0).attr({padding:c.buttonTheme.padding,height:c.buttonTheme.height,paddingLeft:0,paddingRight:0}).add(this.buttonGroup);this.chart.styledMode||(this.zoomText.css(c.labelStyle),e["stroke-width"]=B(e["stroke-width"],0));g("option",{textContent:this.zoomText.textStr,disabled:!0},void 0,m);this.buttonOptions.forEach(function(c,d){g("option",{textContent:c.title||c.text}, void 0,m);b[d]=f.button(c.text,0,0,function(b){var f=c.events&&c.events.click,k;f&&(k=f.call(c,b));!1!==k&&a.clickButton(d);a.isActive=!0},e,n&&n.hover,n&&n.select,n&&n.disabled).attr({"text-align":"center",width:y}).add(a.buttonGroup);c.title&&b[d].attr("title",c.title)})};e.prototype.alignElements=function(){var a=this,b=this.buttonGroup,c=this.buttons,d=this.chart,f=this.group,e=this.inputGroup,g=this.options,h=this.zoomText,n=d.options,y=n.exporting&&!1!==n.exporting.enabled&&n.navigation&&n.navigation.buttonOptions; n=g.buttonPosition;var m=g.inputPosition,q=g.verticalAlign,l=function(b,c){return y&&a.titleCollision(d)&&"top"===q&&"right"===c.align&&c.y-b.getBBox().height-12<(y.y||0)+(y.height||0)+d.spacing[0]?-40:0},x=d.plotLeft;if(f&&n&&m){var z=n.x-d.spacing[3];if(b){this.positionButtons();if(!this.initialButtonGroupWidth){var p=0;h&&(p+=h.getBBox().width+5);c.forEach(function(a,b){p+=a.width;b!==c.length-1&&(p+=g.buttonSpacing)});this.initialButtonGroupWidth=p}x-=d.spacing[3];this.updateButtonStates();h= l(b,n);this.alignButtonGroup(h);f.placed=b.placed=d.hasLoaded}b=0;e&&(b=l(e,m),"left"===m.align?z=x:"right"===m.align&&(z=-Math.max(d.axisOffset[1],-b)),e.align({y:m.y,width:e.getBBox().width,align:m.align,x:m.x+z-2},!0,d.spacingBox),e.placed=d.hasLoaded);this.handleCollision(b);f.align({verticalAlign:q},!0,d.spacingBox);e=f.alignAttr.translateY;b=f.getBBox().height+20;l=0;"bottom"===q&&(l=(l=d.legend&&d.legend.options)&&"bottom"===l.verticalAlign&&l.enabled&&!l.floating?d.legend.legendHeight+B(l.margin, 10):0,b=b+l-20,l=e-b-(g.floating?0:g.y)-(d.titleOffset?d.titleOffset[2]:0)-10);if("top"===q)g.floating&&(l=0),d.titleOffset&&d.titleOffset[0]&&(l=d.titleOffset[0]),l+=d.margin[0]-d.spacing[0]||0;else if("middle"===q)if(m.y===n.y)l=e;else if(m.y||n.y)l=0>m.y||0>n.y?l-Math.min(m.y,n.y):e-b;f.translate(g.x,g.y+Math.floor(l));n=this.minInput;m=this.maxInput;e=this.dropdown;g.inputEnabled&&n&&m&&(n.style.marginTop=f.translateY+"px",m.style.marginTop=f.translateY+"px");e&&(e.style.marginTop=f.translateY+ "px")}};e.prototype.alignButtonGroup=function(a,b){var c=this.chart,d=this.buttonGroup,f=this.options.buttonPosition,k=c.plotLeft-c.spacing[3],e=f.x-c.spacing[3];"right"===f.align?e+=a-k:"center"===f.align&&(e-=k/2);d&&d.align({y:f.y,width:B(b,this.initialButtonGroupWidth),align:f.align,x:e},!0,c.spacingBox)};e.prototype.positionButtons=function(){var a=this.buttons,b=this.chart,c=this.options,d=this.zoomText,f=b.hasLoaded?"animate":"attr",e=c.buttonPosition,g=b.plotLeft,h=g;d&&"hidden"!==d.visibility&& (d[f]({x:B(g+e.x,g)}),h+=e.x+d.getBBox().width+5);this.buttonOptions.forEach(function(b,d){if("hidden"!==a[d].visibility)a[d][f]({x:h}),h+=a[d].width+c.buttonSpacing;else a[d][f]({x:g})})};e.prototype.handleCollision=function(a){var b=this,c=this.chart,d=this.buttonGroup,f=this.inputGroup,k=this.options,e=k.buttonPosition,g=k.dropdown,h=k.inputPosition;k=function(){var a=0;b.buttons.forEach(function(b){b=b.getBBox();b.width>a&&(a=b.width)});return a};var n=function(b){if(f&&d){var c=f.alignAttr.translateX+ f.alignOptions.x-a+f.getBBox().x+2,k=f.alignOptions.width,g=d.alignAttr.translateX+d.getBBox().x;return g+b>c&&c+k>g&&e.y=-a?0:-a),translateY:f.alignAttr.translateY+d.getBBox().height+10})};if(d){if("always"===g){this.collapseButtons(a);n(k())&&m();return}"never"===g&&this.expandButtons()}f&&d?h.align===e.align||n(this.initialButtonGroupWidth+20)?"responsive"===g?(this.collapseButtons(a), n(k())&&m()):m():"responsive"===g&&this.expandButtons():d&&"responsive"===g&&(this.initialButtonGroupWidth>c.plotWidth?this.collapseButtons(a):this.expandButtons())};e.prototype.collapseButtons=function(a){var b=this.buttons,c=this.buttonOptions,d=this.chart,f=this.dropdown,k=this.options,e=this.zoomText,g=d.userOptions.rangeSelector&&d.userOptions.rangeSelector.buttonTheme||{},h=function(a){return{text:a?a+" \u25be":"\u25be",width:"auto",paddingLeft:B(k.buttonTheme.paddingLeft,g.padding,8),paddingRight:B(k.buttonTheme.paddingRight, g.padding,8)}};e&&e.hide();var n=!1;c.forEach(function(a,c){c=b[c];2!==c.state?c.hide():(c.show(),c.attr(h(a.text)),n=!0)});n||(f&&(f.selectedIndex=0),b[0].show(),b[0].attr(h(this.zoomText&&this.zoomText.textStr)));c=k.buttonPosition.align;this.positionButtons();"right"!==c&&"center"!==c||this.alignButtonGroup(a,b[this.currentButtonIndex()].getBBox().width);this.showDropdown()};e.prototype.expandButtons=function(){var a=this.buttons,b=this.buttonOptions,c=this.options,d=this.zoomText;this.hideDropdown(); d&&d.show();b.forEach(function(b,d){d=a[d];d.show();d.attr({text:b.text,width:c.buttonTheme.width||28,paddingLeft:B(c.buttonTheme.paddingLeft,"unset"),paddingRight:B(c.buttonTheme.paddingRight,"unset")});2>d.state&&d.setState(0)});this.positionButtons()};e.prototype.currentButtonIndex=function(){var a=this.dropdown;return a&&0 f&&0>d||0e?b.accessibility&&(b.accessibility.keyboardNavigation.tabindexContainer.focus(),b.accessibility.keyboardNavigation[0>a?"prev":"next"]()):c&&(a=c[e?"maxDateBox":"minDateBox"],c=c[e?"maxInput":"minInput"],a&&c&&b.setFocusToElement(a, c))},onInputNavInit:function(b){var c=this,f=this,e=this.chart,g=0this.series.length?"Single":"Multiple";return(this.langFormat("accessibility.chartTypes."+a+d,c)||this.langFormat("accessibility.chartTypes.default"+d,c))+(b?" "+ b:"")};e=function(){};e.prototype=new t;r(e.prototype,{init:function(){var a=this.chart,b=this;this.initRegionsDefinitions();this.addEvent(a,"aftergetTableAST",function(a){b.onDataTableCreated(a)});this.addEvent(a,"afterViewData",function(a){b.dataTableDiv=a;setTimeout(function(){b.focusDataTable()},300)});this.announcer=new l(a,"assertive")},initRegionsDefinitions:function(){var a=this;this.screenReaderSections={before:{element:null,buildContent:function(b){var c=b.options.accessibility.screenReaderSection.beforeChartFormatter; return c?c(b):a.defaultBeforeChartFormatter(b)},insertIntoDOM:function(a,b){b.renderTo.insertBefore(a,b.renderTo.firstChild)},afterInserted:function(){"undefined"!==typeof a.sonifyButtonId&&a.initSonifyButton(a.sonifyButtonId);"undefined"!==typeof a.dataTableButtonId&&a.initDataTableButton(a.dataTableButtonId)}},after:{element:null,buildContent:function(b){var c=b.options.accessibility.screenReaderSection.afterChartFormatter;return c?c(b):a.defaultAfterChartFormatter()},insertIntoDOM:function(a,b){b.renderTo.insertBefore(a, b.container.nextSibling)}}}},onChartRender:function(){var a=this;this.linkedDescriptionElement=this.getLinkedDescriptionElement();this.setLinkedDescriptionAttrs();Object.keys(this.screenReaderSections).forEach(function(b){a.updateScreenReaderSection(b)})},getLinkedDescriptionElement:function(){var b=this.chart.options.accessibility.linkedDescription;if(b){if("string"!==typeof b)return b;b=g(b,this.chart);b=a.querySelectorAll(b);if(1===b.length)return b[0]}},setLinkedDescriptionAttrs:function(){var a= this.linkedDescriptionElement;a&&(a.setAttribute("aria-hidden","true"),N(a,"highcharts-linked-description"))},updateScreenReaderSection:function(a){var c=this.chart,d=this.screenReaderSections[a],f=d.buildContent(c),e=d.element=d.element||this.createElement("div"),g=e.firstChild||this.createElement("div");this.setScreenReaderSectionAttribs(e,a);b.setElementHTML(g,f);e.appendChild(g);d.insertIntoDOM(e,c);D(g);v(c,g);d.afterInserted&&d.afterInserted()},setScreenReaderSectionAttribs:function(a,b){var c= this.chart,d=c.langFormat("accessibility.screenReaderSection."+b+"RegionLabel",{chart:c});F(a,{id:"highcharts-screen-reader-region-"+b+"-"+c.index,"aria-label":d});a.style.position="relative";"all"===c.options.accessibility.landmarkVerbosity&&d&&a.setAttribute("role","region")},defaultBeforeChartFormatter:function(){var a=this.chart,b=a.options.accessibility.screenReaderSection.beforeChartFormat,c=this.getAxesDescription(),f=a.sonify&&a.options.sonification&&a.options.sonification.enabled,e="highcharts-a11y-sonify-data-btn-"+ a.index,g="hc-linkto-highcharts-data-table-"+a.index,h=d(a),m=a.langFormat("accessibility.screenReaderSection.annotations.heading",{chart:a});c={headingTagName:H(a.renderTo),chartTitle:w(a),typeDescription:this.getTypeDescriptionText(),chartSubtitle:this.getSubtitleText(),chartLongdesc:this.getLongdescText(),xAxisDescription:c.xAxis,yAxisDescription:c.yAxis,playAsSoundButton:f?this.getSonifyButtonText(e):"",viewTableButton:a.getCSV?this.getDataTableButtonText(g):"",annotationsTitle:h?m:"",annotationsList:h}; a=p.i18nFormat(b,c,a);this.dataTableButtonId=g;this.sonifyButtonId=e;return a.replace(/<(\w+)[^>]*?>\s*<\/\1>/g,"")},defaultAfterChartFormatter:function(){var a=this.chart,b=a.options.accessibility.screenReaderSection.afterChartFormat,c={endOfChartMarker:this.getEndOfChartMarkerText()};return p.i18nFormat(b,c,a).replace(/<(\w+)[^>]*?>\s*<\/\1>/g,"")},getLinkedDescription:function(){var a=this.linkedDescriptionElement;return B(a&&a.innerHTML||"")},getLongdescText:function(){var a=this.chart.options, b=a.caption;b=b&&b.text;var c=this.getLinkedDescription();return a.accessibility.description||c||b||""},getTypeDescriptionText:function(){var a=this.chart;return a.types?a.options.accessibility.typeDescription||a.getTypeDescription(a.types):""},getDataTableButtonText:function(a){var b=this.chart;b=b.langFormat("accessibility.table.viewAsDataTableButtonText",{chart:b,chartTitle:w(b)});return'"},getSonifyButtonText:function(a){var b=this.chart;if(b.options.sonification&& !1===b.options.sonification.enabled)return"";b=b.langFormat("accessibility.sonification.playAsSoundButtonText",{chart:b,chartTitle:w(b)});return'"},getSubtitleText:function(){var a=this.chart.options.subtitle;return B(a&&a.text||"")},getEndOfChartMarkerText:function(){var a=this.chart,b=a.langFormat("accessibility.screenReaderSection.endOfChartMarker",{chart:a});return'
'+b+"
"},onDataTableCreated:function(a){var b= this.chart;if(b.options.accessibility.enabled){this.viewDataTableButton&&this.viewDataTableButton.setAttribute("aria-expanded","true");var c=a.tree.attributes||{};c.tabindex=-1;c.summary=b.langFormat("accessibility.table.tableSummary",{chart:b});a.tree.attributes=c}},focusDataTable:function(){var a=this.dataTableDiv;(a=a&&a.getElementsByTagName("table")[0])&&a.focus&&a.focus()},initSonifyButton:function(a){var b=this,c=this.sonifyButton=J(a),d=this.chart,f=function(a){c&&(c.setAttribute("aria-hidden", "true"),c.setAttribute("aria-label",""));a.preventDefault();a.stopPropagation();a=d.langFormat("accessibility.sonification.playAsSoundClickAnnouncement",{chart:d});b.announcer.announce(a);setTimeout(function(){c&&(c.removeAttribute("aria-hidden"),c.removeAttribute("aria-label"));d.sonify&&d.sonify()},1E3)};c&&d&&(F(c,{tabindex:-1}),c.onclick=function(a){(d.options.accessibility&&d.options.accessibility.screenReaderSection.onPlayAsSoundClick||f).call(this,a,d)})},initDataTableButton:function(a){var b= this.viewDataTableButton=J(a),c=this.chart;a=a.replace("hc-linkto-","");b&&(F(b,{tabindex:-1,"aria-expanded":!!J(a)}),b.onclick=c.options.accessibility.screenReaderSection.onViewDataTableClick||function(){c.viewData()})},getAxesDescription:function(){var a=this.chart,b=function(b,d){b=a[b];return 1a.types.indexOf("map"),f=!!a.hasCartesianSeries,e=b("xAxis",!a.angular&&f&&d);b=b("yAxis",f&&d);d={}; e&&(d.xAxis=this.getAxisDescriptionText("xAxis"));b&&(d.yAxis=this.getAxisDescriptionText("yAxis"));return d},getAxisDescriptionText:function(a){var b=this.chart,c=b[a];return b.langFormat("accessibility.axis."+a+"Description"+(1{chartTitle}
{typeDescription}
{chartSubtitle}
{chartLongdesc}
{playAsSoundButton}
{viewTableButton}
{xAxisDescription}
{yAxisDescription}
{annotationsTitle}{annotationsList}
", afterChartFormat:"{endOfChartMarker}",axisRangeDateFormat:"%Y-%m-%d %H:%M:%S"},series:{describeSingleSeries:!1,pointDescriptionEnabledThreshold:200},point:{valueDescriptionFormat:"{index}. {xDescription}{separator}{value}."},landmarkVerbosity:"all",linkedDescription:'*[data-highcharts-chart="{index}"] + .highcharts-description',keyboardNavigation:{enabled:!0,focusBorder:{enabled:!0,hideBrowserFocusOutline:!0,style:{color:b.highlightColor80,lineWidth:2,borderRadius:3},margin:2},order:["series","zoom", "rangeSelector","legend","chartMenu"],wrapAround:!0,seriesNavigation:{skipNullPoints:!0,pointNavigationEnabledThreshold:!1}},announceNewData:{enabled:!1,minAnnounceInterval:5E3,interruptUser:!1}},legend:{accessibility:{enabled:!0,keyboardNavigation:{enabled:!0}}},exporting:{accessibility:{enabled:!0}}}});v(b,"Accessibility/Options/LangOptions.js",[],function(){return{accessibility:{defaultChartTitle:"Chart",chartContainerLabel:"{title}. Highcharts interactive chart.",svgContainerLabel:"Interactive chart", drillUpButton:"{buttonText}",credits:"Chart credits: {creditsStr}",thousandsSep:",",svgContainerTitle:"",graphicContainerLabel:"",screenReaderSection:{beforeRegionLabel:"Chart screen reader information.",afterRegionLabel:"",annotations:{heading:"Chart annotations summary",descriptionSinglePoint:"{annotationText}. Related to {annotationPoint}",descriptionMultiplePoints:"{annotationText}. Related to {annotationPoint}{ Also related to, #each(additionalAnnotationPoints)}",descriptionNoPoints:"{annotationText}"}, endOfChartMarker:"End of interactive chart."},sonification:{playAsSoundButtonText:"Play as sound, {chartTitle}",playAsSoundClickAnnouncement:"Play"},legend:{legendLabelNoTitle:"Toggle series visibility",legendLabel:"Chart legend: {legendTitle}",legendItem:"Show {itemName}"},zoom:{mapZoomIn:"Zoom chart",mapZoomOut:"Zoom out chart",resetZoomButton:"Reset zoom"},rangeSelector:{dropdownLabel:"{rangeTitle}",minInputLabel:"Select start date.",maxInputLabel:"Select end date.",clickButtonAnnouncement:"Viewing {axisRangeDescription}"}, table:{viewAsDataTableButtonText:"View as data table, {chartTitle}",tableSummary:"Table representation of chart."},announceNewData:{newDataAnnounce:"Updated data for chart {chartTitle}",newSeriesAnnounceSingle:"New data series: {seriesDesc}",newPointAnnounceSingle:"New data point: {pointDesc}",newSeriesAnnounceMultiple:"New data series in chart {chartTitle}: {seriesDesc}",newPointAnnounceMultiple:"New data point in chart {chartTitle}: {pointDesc}"},seriesTypeDescriptions:{boxplot:"Box plot charts are typically used to display groups of statistical data. Each data point in the chart can have up to 5 values: minimum, lower quartile, median, upper quartile, and maximum.", arearange:"Arearange charts are line charts displaying a range between a lower and higher value for each point.",areasplinerange:"These charts are line charts displaying a range between a lower and higher value for each point.",bubble:"Bubble charts are scatter charts where each data point also has a size value.",columnrange:"Columnrange charts are column charts displaying a range between a lower and higher value for each point.",errorbar:"Errorbar series are used to display the variability of the data.", funnel:"Funnel charts are used to display reduction of data in stages.",pyramid:"Pyramid charts consist of a single pyramid with item heights corresponding to each point value.",waterfall:"A waterfall chart is a column chart where each column contributes towards a total end value."},chartTypes:{emptyChart:"Empty chart",mapTypeDescription:"Map of {mapTitle} with {numSeries} data series.",unknownMap:"Map of unspecified region with {numSeries} data series.",combinationChart:"Combination chart with {numSeries} data series.", defaultSingle:"Chart with {numPoints} data {#plural(numPoints, points, point)}.",defaultMultiple:"Chart with {numSeries} data series.",splineSingle:"Line chart with {numPoints} data {#plural(numPoints, points, point)}.",splineMultiple:"Line chart with {numSeries} lines.",lineSingle:"Line chart with {numPoints} data {#plural(numPoints, points, point)}.",lineMultiple:"Line chart with {numSeries} lines.",columnSingle:"Bar chart with {numPoints} {#plural(numPoints, bars, bar)}.",columnMultiple:"Bar chart with {numSeries} data series.", barSingle:"Bar chart with {numPoints} {#plural(numPoints, bars, bar)}.",barMultiple:"Bar chart with {numSeries} data series.",pieSingle:"Pie chart with {numPoints} {#plural(numPoints, slices, slice)}.",pieMultiple:"Pie chart with {numSeries} pies.",scatterSingle:"Scatter chart with {numPoints} {#plural(numPoints, points, point)}.",scatterMultiple:"Scatter chart with {numSeries} data series.",boxplotSingle:"Boxplot with {numPoints} {#plural(numPoints, boxes, box)}.",boxplotMultiple:"Boxplot with {numSeries} data series.", bubbleSingle:"Bubble chart with {numPoints} {#plural(numPoints, bubbles, bubble)}.",bubbleMultiple:"Bubble chart with {numSeries} data series."},axis:{xAxisDescriptionSingular:"The chart has 1 X axis displaying {names[0]}. {ranges[0]}",xAxisDescriptionPlural:"The chart has {numAxes} X axes displaying {#each(names, -1) }and {names[-1]}.",yAxisDescriptionSingular:"The chart has 1 Y axis displaying {names[0]}. {ranges[0]}",yAxisDescriptionPlural:"The chart has {numAxes} Y axes displaying {#each(names, -1) }and {names[-1]}.", timeRangeDays:"Range: {range} days.",timeRangeHours:"Range: {range} hours.",timeRangeMinutes:"Range: {range} minutes.",timeRangeSeconds:"Range: {range} seconds.",rangeFromTo:"Range: {rangeFrom} to {rangeTo}.",rangeCategories:"Range: {numCategories} categories."},exporting:{chartMenuLabel:"Chart menu",menuButtonLabel:"View chart menu",exportRegionLabel:"Chart menu"},series:{summary:{"default":"{name}, series {ix} of {numSeries} with {numPoints} data {#plural(numPoints, points, point)}.",defaultCombination:"{name}, series {ix} of {numSeries} with {numPoints} data {#plural(numPoints, points, point)}.", line:"{name}, line {ix} of {numSeries} with {numPoints} data {#plural(numPoints, points, point)}.",lineCombination:"{name}, series {ix} of {numSeries}. Line with {numPoints} data {#plural(numPoints, points, point)}.",spline:"{name}, line {ix} of {numSeries} with {numPoints} data {#plural(numPoints, points, point)}.",splineCombination:"{name}, series {ix} of {numSeries}. Line with {numPoints} data {#plural(numPoints, points, point)}.",column:"{name}, bar series {ix} of {numSeries} with {numPoints} {#plural(numPoints, bars, bar)}.", columnCombination:"{name}, series {ix} of {numSeries}. Bar series with {numPoints} {#plural(numPoints, bars, bar)}.",bar:"{name}, bar series {ix} of {numSeries} with {numPoints} {#plural(numPoints, bars, bar)}.",barCombination:"{name}, series {ix} of {numSeries}. Bar series with {numPoints} {#plural(numPoints, bars, bar)}.",pie:"{name}, pie {ix} of {numSeries} with {numPoints} {#plural(numPoints, slices, slice)}.",pieCombination:"{name}, series {ix} of {numSeries}. Pie with {numPoints} {#plural(numPoints, slices, slice)}.", scatter:"{name}, scatter plot {ix} of {numSeries} with {numPoints} {#plural(numPoints, points, point)}.",scatterCombination:"{name}, series {ix} of {numSeries}, scatter plot with {numPoints} {#plural(numPoints, points, point)}.",boxplot:"{name}, boxplot {ix} of {numSeries} with {numPoints} {#plural(numPoints, boxes, box)}.",boxplotCombination:"{name}, series {ix} of {numSeries}. Boxplot with {numPoints} {#plural(numPoints, boxes, box)}.",bubble:"{name}, bubble series {ix} of {numSeries} with {numPoints} {#plural(numPoints, bubbles, bubble)}.", bubbleCombination:"{name}, series {ix} of {numSeries}. Bubble series with {numPoints} {#plural(numPoints, bubbles, bubble)}.",map:"{name}, map {ix} of {numSeries} with {numPoints} {#plural(numPoints, areas, area)}.",mapCombination:"{name}, series {ix} of {numSeries}. Map with {numPoints} {#plural(numPoints, areas, area)}.",mapline:"{name}, line {ix} of {numSeries} with {numPoints} data {#plural(numPoints, points, point)}.",maplineCombination:"{name}, series {ix} of {numSeries}. Line with {numPoints} data {#plural(numPoints, points, point)}.", mapbubble:"{name}, bubble series {ix} of {numSeries} with {numPoints} {#plural(numPoints, bubbles, bubble)}.",mapbubbleCombination:"{name}, series {ix} of {numSeries}. Bubble series with {numPoints} {#plural(numPoints, bubbles, bubble)}."},description:"{description}",xAxisDescription:"X axis, {name}",yAxisDescription:"Y axis, {name}",nullPointValue:"No value",pointAnnotationsDescription:"{Annotation: #each(annotations). }"}}}});v(b,"Accessibility/Options/DeprecatedOptions.js",[b["Core/Utilities.js"]], function(b){function e(b,e,g){for(var a,c=0;ch?e.length+h:Math.min(h,e.length),c=0;ca?(b=e[e.length+a],"undefined"===typeof b&&(b=e[0])):(b=e[a],"undefined"===typeof b&&(b=e[e.length-1]))),"undefined"!==typeof b?b:""):"{"+b+"}"}var t=r.format,l=p.pick;e.i18nFormat=function(b,e,l){var g=function(a,b){a=a.slice(b||0);var c=a.indexOf("{"),d=a.indexOf("}");if(-1c)return{statement:a.substring(c+ 1,d),begin:b+c+1,end:b+d}},a=[],c=0;do{var d=g(b,c);var f=b.substring(c,d&&d.begin-1);f.length&&a.push({value:f,type:"constant"});d&&a.push({value:d.statement,type:"statement"});c=d?d.end+1:c+1}while(d);a.forEach(function(a){"statement"===a.type&&(a.value=u(a.value,e))});return t(a.reduce(function(a,b){return a+b.value},""),e,l)};b.prototype.langFormat=function(b,h){b=b.split(".");for(var l=this.options.lang,g=0;g