highstock-rails 2.1.10 → 5.0.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (91) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/css/highcharts.css +760 -0
  3. data/app/assets/javascripts/highstock.js +511 -419
  4. data/app/assets/javascripts/highstock/highstock.js +472 -0
  5. data/app/assets/javascripts/highstock/highstock.js.map +8 -0
  6. data/app/assets/javascripts/highstock/highstock.src.js +28809 -0
  7. data/app/assets/javascripts/highstock/modules/accessibility.js +48 -0
  8. data/app/assets/javascripts/highstock/modules/accessibility.js.map +8 -0
  9. data/app/assets/javascripts/highstock/modules/accessibility.src.js +1131 -0
  10. data/app/assets/javascripts/highstock/modules/annotations.js +14 -0
  11. data/app/assets/javascripts/highstock/modules/annotations.js.map +8 -0
  12. data/app/assets/javascripts/highstock/modules/annotations.src.js +407 -0
  13. data/app/assets/javascripts/highstock/modules/boost-canvas.js +23 -0
  14. data/app/assets/javascripts/highstock/modules/boost-canvas.js.map +8 -0
  15. data/app/assets/javascripts/highstock/modules/boost-canvas.src.js +771 -0
  16. data/app/assets/javascripts/highstock/modules/boost.js +51 -12
  17. data/app/assets/javascripts/highstock/modules/boost.js.map +8 -0
  18. data/app/assets/javascripts/highstock/modules/boost.src.js +2580 -492
  19. data/app/assets/javascripts/highstock/modules/broken-axis.js.map +8 -0
  20. data/app/assets/javascripts/highstock/modules/canvasrenderer.experimental.js.map +8 -0
  21. data/app/assets/javascripts/highstock/modules/data.js +19 -19
  22. data/app/assets/javascripts/highstock/modules/data.js.map +8 -0
  23. data/app/assets/javascripts/highstock/modules/data.src.js +974 -950
  24. data/app/assets/javascripts/highstock/modules/drilldown.js +25 -17
  25. data/app/assets/javascripts/highstock/modules/drilldown.js.map +8 -0
  26. data/app/assets/javascripts/highstock/modules/drilldown.src.js +790 -709
  27. data/app/assets/javascripts/highstock/modules/export-data.js +17 -0
  28. data/app/assets/javascripts/highstock/modules/export-data.js.map +8 -0
  29. data/app/assets/javascripts/highstock/modules/export-data.src.js +417 -0
  30. data/app/assets/javascripts/highstock/modules/exporting.js +21 -18
  31. data/app/assets/javascripts/highstock/modules/exporting.js.map +8 -0
  32. data/app/assets/javascripts/highstock/modules/exporting.src.js +1013 -768
  33. data/app/assets/javascripts/highstock/modules/funnel.js +6 -7
  34. data/app/assets/javascripts/highstock/modules/funnel.js.map +8 -0
  35. data/app/assets/javascripts/highstock/modules/funnel.src.js +284 -308
  36. data/app/assets/javascripts/highstock/modules/gantt.js +24 -0
  37. data/app/assets/javascripts/highstock/modules/gantt.js.map +8 -0
  38. data/app/assets/javascripts/highstock/modules/gantt.src.js +793 -0
  39. data/app/assets/javascripts/highstock/modules/grid-axis.js +19 -0
  40. data/app/assets/javascripts/highstock/modules/grid-axis.js.map +8 -0
  41. data/app/assets/javascripts/highstock/modules/grid-axis.src.js +545 -0
  42. data/app/assets/javascripts/highstock/modules/heatmap.js +20 -18
  43. data/app/assets/javascripts/highstock/modules/heatmap.js.map +8 -0
  44. data/app/assets/javascripts/highstock/modules/heatmap.src.js +738 -633
  45. data/app/assets/javascripts/highstock/modules/map-parser.js.map +8 -0
  46. data/app/assets/javascripts/highstock/modules/map.js.map +8 -0
  47. data/app/assets/javascripts/highstock/modules/no-data-to-display.js +5 -5
  48. data/app/assets/javascripts/highstock/modules/no-data-to-display.js.map +8 -0
  49. data/app/assets/javascripts/highstock/modules/no-data-to-display.src.js +140 -133
  50. data/app/assets/javascripts/highstock/modules/offline-exporting.js +12 -7
  51. data/app/assets/javascripts/highstock/modules/offline-exporting.js.map +8 -0
  52. data/app/assets/javascripts/highstock/modules/offline-exporting.src.js +543 -270
  53. data/app/assets/javascripts/highstock/modules/overlapping-datalabels.js +10 -0
  54. data/app/assets/javascripts/highstock/modules/overlapping-datalabels.js.map +8 -0
  55. data/app/assets/javascripts/highstock/modules/overlapping-datalabels.src.js +187 -0
  56. data/app/assets/javascripts/highstock/modules/series-label.js +19 -0
  57. data/app/assets/javascripts/highstock/modules/series-label.js.map +8 -0
  58. data/app/assets/javascripts/highstock/modules/series-label.src.js +606 -0
  59. data/app/assets/javascripts/highstock/modules/solid-gauge.js +9 -8
  60. data/app/assets/javascripts/highstock/modules/solid-gauge.js.map +8 -0
  61. data/app/assets/javascripts/highstock/modules/solid-gauge.src.js +334 -266
  62. data/app/assets/javascripts/highstock/modules/static-scale.js +12 -0
  63. data/app/assets/javascripts/highstock/modules/static-scale.js.map +8 -0
  64. data/app/assets/javascripts/highstock/modules/static-scale.src.js +64 -0
  65. data/app/assets/javascripts/highstock/modules/stock.js +123 -0
  66. data/app/assets/javascripts/highstock/modules/stock.js.map +8 -0
  67. data/app/assets/javascripts/highstock/modules/stock.src.js +6247 -0
  68. data/app/assets/javascripts/highstock/modules/treemap.js +22 -23
  69. data/app/assets/javascripts/highstock/modules/treemap.js.map +8 -0
  70. data/app/assets/javascripts/highstock/modules/treemap.src.js +884 -859
  71. data/app/assets/javascripts/highstock/modules/xrange-series.js +15 -0
  72. data/app/assets/javascripts/highstock/modules/xrange-series.js.map +8 -0
  73. data/app/assets/javascripts/highstock/modules/xrange-series.src.js +258 -0
  74. data/app/assets/javascripts/highstock/themes/dark-blue.js +307 -244
  75. data/app/assets/javascripts/highstock/themes/dark-green.js +303 -244
  76. data/app/assets/javascripts/highstock/themes/dark-unica.js +231 -201
  77. data/app/assets/javascripts/highstock/themes/gray.js +314 -245
  78. data/app/assets/javascripts/highstock/themes/grid-light.js +91 -66
  79. data/app/assets/javascripts/highstock/themes/grid.js +124 -96
  80. data/app/assets/javascripts/highstock/themes/sand-signika.js +119 -94
  81. data/app/assets/javascripts/highstock/themes/skies.js +108 -85
  82. data/lib/highstock/rails/version.rb +1 -1
  83. metadata +54 -11
  84. data/app/assets/javascripts/highstock/adapters/standalone-framework.js +0 -18
  85. data/app/assets/javascripts/highstock/adapters/standalone-framework.src.js +0 -635
  86. data/app/assets/javascripts/highstock/highcharts-3d.js +0 -48
  87. data/app/assets/javascripts/highstock/highcharts-3d.src.js +0 -1711
  88. data/app/assets/javascripts/highstock/highcharts-more.js +0 -55
  89. data/app/assets/javascripts/highstock/highstock-all.js +0 -637
  90. data/app/assets/javascripts/highstock/modules/canvas-tools.js +0 -133
  91. data/app/assets/javascripts/highstock/modules/canvas-tools.src.js +0 -3114
@@ -0,0 +1,48 @@
1
+ /*
2
+ Highcharts JS v5.0.11 (2017-05-04)
3
+ Accessibility module
4
+
5
+ (c) 2010-2017 Highsoft AS
6
+ Author: Oystein Moseng
7
+
8
+ License: www.highcharts.com/license
9
+ */
10
+ (function(q){"object"===typeof module&&module.exports?module.exports=q:q(Highcharts)})(function(q){(function(e){function q(a){return a.replace(/&/g,"\x26amp;").replace(/</g,"\x26lt;").replace(/>/g,"\x26gt;").replace(/"/g,"\x26quot;").replace(/'/g,"\x26#x27;").replace(/\//g,"\x26#x2F;")}function z(a){for(var c=a.childNodes.length;c--;)a.appendChild(a.childNodes[c])}function k(a){var c;a&&a.onclick&&l.createEvent&&(c=l.createEvent("Events"),c.initEvent("click",!0,!1),a.onclick(c))}var y=e.win,l=y.document,
11
+ g=e.each,A=e.erase,v=e.addEvent,B=e.removeEvent,x=e.fireEvent,C=e.dateFormat,w=e.merge,r={"default":["series","data point","data points"],line:["line","data point","data points"],spline:["line","data point","data points"],area:["line","data point","data points"],areaspline:["line","data point","data points"],pie:["pie","slice","slices"],column:["column series","column","columns"],bar:["bar series","bar","bars"],scatter:["scatter series","data point","data points"],boxplot:["boxplot series","box",
12
+ "boxes"],arearange:["arearange series","data point","data points"],areasplinerange:["areasplinerange series","data point","data points"],bubble:["bubble series","bubble","bubbles"],columnrange:["columnrange series","column","columns"],errorbar:["errorbar series","errorbar","errorbars"],funnel:["funnel","data point","data points"],pyramid:["pyramid","data point","data points"],waterfall:["waterfall series","column","columns"],map:["map","area","areas"],mapline:["line","data point","data points"],mappoint:["point series",
13
+ "data point","data points"],mapbubble:["bubble series","bubble","bubbles"]},D={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. ",
14
+ 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. "};
15
+ e.Series.prototype.commonKeys="name id category x value y".split(" ");e.Series.prototype.specialKeys="z open high q3 median q1 low close".split(" ");e.seriesTypes.pie&&(e.seriesTypes.pie.prototype.specialKeys=[]);e.setOptions({accessibility:{enabled:!0,pointDescriptionThreshold:30,keyboardNavigation:{enabled:!0}}});e.wrap(e.Series.prototype,"render",function(a){a.apply(this,Array.prototype.slice.call(arguments,1));this.chart.options.accessibility.enabled&&this.setA11yDescription()});e.Series.prototype.setA11yDescription=
16
+ function(){var a=this.chart.options.accessibility,c=this.points&&this.points.length&&this.points[0].graphic&&this.points[0].graphic.element,d=c&&c.parentNode||this.graph&&this.graph.element||this.group&&this.group.element;d&&(d.lastChild===c&&z(d),this.points&&(this.points.length<a.pointDescriptionThreshold||!1===a.pointDescriptionThreshold)&&g(this.points,function(b){b.graphic&&(b.graphic.element.setAttribute("role","img"),b.graphic.element.setAttribute("tabindex","-1"),b.graphic.element.setAttribute("aria-label",
17
+ a.pointDescriptionFormatter&&a.pointDescriptionFormatter(b)||b.buildPointInfoString()))}),1<this.chart.series.length||a.describeSingleSeries)&&(d.setAttribute("role","region"),d.setAttribute("tabindex","-1"),d.setAttribute("aria-label",a.seriesDescriptionFormatter&&a.seriesDescriptionFormatter(this)||this.buildSeriesInfoString()))};e.Series.prototype.buildSeriesInfoString=function(){var a=r[this.type]||r["default"],c=this.description||this.options.description;return(this.name?this.name+", ":"")+(1===
18
+ this.chart.types.length?a[0]:"series")+" "+(this.index+1)+" of "+this.chart.series.length+(1===this.chart.types.length?" with ":". "+a[0]+" with ")+(this.points.length+" "+(1===this.points.length?a[1]:a[2]))+(c?". "+c:"")+(1<this.chart.yAxis.length&&this.yAxis?". Y axis, "+this.yAxis.getDescription():"")+(1<this.chart.xAxis.length&&this.xAxis?". X axis, "+this.xAxis.getDescription():"")};e.Point.prototype.buildPointInfoString=function(){var a=this,c=a.series,d=c.chart.options.accessibility,b="",f=
19
+ c.xAxis&&c.xAxis.isDatetimeAxis,d=f&&C(d.pointDateFormatter&&d.pointDateFormatter(a)||d.pointDateFormat||e.Tooltip.prototype.getXDateFormat(a,c.chart.options.tooltip,c.xAxis),a.x);e.find(c.specialKeys,function(b){return void 0!==a[b]})?(f&&(b=d),g(c.commonKeys.concat(c.specialKeys),function(c){void 0===a[c]||f&&"x"===c||(b+=(b?". ":"")+c+", "+a[c])})):b=(this.name||d||this.category||this.id||"x, "+this.x)+", "+(void 0!==this.value?this.value:this.y);return this.index+1+". "+b+"."+(this.description?
20
+ " "+this.description:"")};e.Axis.prototype.getDescription=function(){return this.userOptions&&this.userOptions.description||this.axisTitle&&this.axisTitle.textStr||this.options.id||this.categories&&"categories"||"values"};e.Axis.prototype.panStep=function(a,c){var d=c||3;c=this.getExtremes();var b=(c.max-c.min)/d*a,d=c.max+b,b=c.min+b,f=d-b;0>a&&b<c.dataMin?(b=c.dataMin,d=b+f):0<a&&d>c.dataMax&&(d=c.dataMax,b=d-f);this.setExtremes(b,d)};e.wrap(e.Series.prototype,"init",function(a){a.apply(this,Array.prototype.slice.call(arguments,
21
+ 1));var c=this.chart;c.options.accessibility.enabled&&(c.types=c.types||[],0>c.types.indexOf(this.type)&&c.types.push(this.type),v(this,"remove",function(){var a=this,b=!1;g(c.series,function(f){f!==a&&0>c.types.indexOf(a.type)&&(b=!0)});b||A(c.types,a.type)}))});e.Chart.prototype.getTypeDescription=function(){var a=this.types&&this.types[0],c=this.series[0]&&this.series[0].mapTitle;if(a){if("map"===a)return c?"Map of "+c:"Map of unspecified region.";if(1<this.types.length)return"Combination chart.";
22
+ if(-1<["spline","area","areaspline"].indexOf(a))return"Line chart."}else return"Empty chart.";return a+" chart."+(D[a]||"")};e.Chart.prototype.getAxesDescription=function(){var a=this.xAxis.length,c=this.yAxis.length,d={},b;if(a)if(d.xAxis="The chart has "+a+(1<a?" X axes":" X axis")+" displaying ",2>a)d.xAxis+=this.xAxis[0].getDescription()+".";else{for(b=0;b<a-1;++b)d.xAxis+=(b?", ":"")+this.xAxis[b].getDescription();d.xAxis+=" and "+this.xAxis[b].getDescription()+"."}if(c)if(d.yAxis="The chart has "+
23
+ c+(1<c?" Y axes":" Y axis")+" displaying ",2>c)d.yAxis+=this.yAxis[0].getDescription()+".";else{for(b=0;b<c-1;++b)d.yAxis+=(b?", ":"")+this.yAxis[b].getDescription();d.yAxis+=" and "+this.yAxis[b].getDescription()+"."}return d};e.Chart.prototype.addAccessibleContextMenuAttribs=function(){var a=this.exportDivElements;a&&(g(a,function(a){"DIV"!==a.tagName||a.children&&a.children.length||(a.setAttribute("role","menuitem"),a.setAttribute("tabindex",-1))}),a[0].parentNode.setAttribute("role","menu"),a[0].parentNode.setAttribute("aria-label",
24
+ "Chart export"))};e.Point.prototype.highlight=function(){var a=this.series.chart;this.graphic&&this.graphic.element.focus&&this.graphic.element.focus();this.isNull?a.tooltip&&a.tooltip.hide(0):(this.onMouseOver(),a.tooltip&&a.tooltip.refresh(a.tooltip.shared?[this]:this));a.highlightedPoint=this;return this};e.Chart.prototype.highlightAdjacentPoint=function(a){var c=this.series,d=this.highlightedPoint,b=d&&d.index||0,f=d&&d.series.points,E=d&&d.series.connectEnds&&b>f.length-3?2:1;if(!c[0]||!c[0].points)return!1;
25
+ if(!d)return c[0].points[0].highlight();if(f[b]!==d)for(var e=0;e<f.length;++e)if(f[e]===d){b=e;break}c=c[d.series.index+(a?1:-1)];b=f[b+(a?E:-1)]||c&&c.points[a?0:c.points.length-(c.connectEnds?2:1)];return void 0===b?!1:b.isNull&&this.options.accessibility.keyboardNavigation.skipNullPoints||b.series.options.skipKeyboardNavigation?(this.highlightedPoint=b,this.highlightAdjacentPoint(a)):b.highlight()};e.Chart.prototype.showExportMenu=function(){this.exportSVGElements&&this.exportSVGElements[0]&&
26
+ (this.exportSVGElements[0].element.onclick(),this.highlightExportItem(0))};e.Chart.prototype.highlightExportItem=function(a){var c=this.exportDivElements&&this.exportDivElements[a],d=this.exportDivElements&&this.exportDivElements[this.highlightedExportItem];if(c&&"DIV"===c.tagName&&(!c.children||!c.children.length)){c.focus&&c.focus();if(d&&d.onmouseout)d.onmouseout();if(c.onmouseover)c.onmouseover();this.highlightedExportItem=a;return!0}};e.Chart.prototype.highlightRangeSelectorButton=function(a){var c=
27
+ this.rangeSelector.buttons;c[this.highlightedRangeSelectorItemIx]&&c[this.highlightedRangeSelectorItemIx].setState(this.oldRangeSelectorItemState||0);this.highlightedRangeSelectorItemIx=a;return c[a]?(c[a].element.focus&&c[a].element.focus(),this.oldRangeSelectorItemState=c[a].state,c[a].setState(2),!0):!1};e.Chart.prototype.highlightLegendItem=function(a){var c=this.legend.allItems;c[this.highlightedLegendItemIx]&&x(c[this.highlightedLegendItemIx].legendGroup.element,"mouseout");this.highlightedLegendItemIx=
28
+ a;return c[a]?(c[a].legendGroup.element.focus&&c[a].legendGroup.element.focus(),x(c[a].legendGroup.element,"mouseover"),!0):!1};e.Chart.prototype.hideExportMenu=function(){var a=this.exportDivElements;if(a){g(a,function(a){x(a,"mouseleave")});if(a[this.highlightedExportItem]&&a[this.highlightedExportItem].onmouseout)a[this.highlightedExportItem].onmouseout();this.highlightedExportItem=0;this.renderTo.focus()}};e.Chart.prototype.addKeyboardNavEvents=function(){function a(b){this.keyCodeMap=b.keyCodeMap;
29
+ this.move=b.move;this.validate=b.validate;this.init=b.init;this.transformTabs=!1!==b.transformTabs}function c(c,d){return new a(w({keyCodeMap:c,move:function(a){b.keyboardNavigationModuleIndex+=a;var c=b.keyboardNavigationModules[b.keyboardNavigationModuleIndex];if(c){if(c.validate&&!c.validate())return this.move(a);if(c.init)return c.init(a),!0}b.keyboardNavigationModuleIndex=0;b.slipNextTab=!0;return!1}},d))}function d(a){a=a||y.event;var c=b.keyboardNavigationModules[b.keyboardNavigationModuleIndex];
30
+ 9===(a.which||a.keyCode)&&b.slipNextTab?b.slipNextTab=!1:(b.slipNextTab=!1,c&&c.run(a)&&a.preventDefault())}var b=this;a.prototype={run:function(b){var a=this,c=b.which||b.keyCode,f=!1,c=this.transformTabs&&9===c?b.shiftKey?37:39:c;g(this.keyCodeMap,function(d){-1<d[0].indexOf(c)&&(f=!1===d[1].call(a,c,b)?!1:!0)});return f}};b.keyboardNavigationModules=[c([[[37,39],function(a){if(!b.highlightAdjacentPoint(39===a))return this.move(39===a?1:-1)}],[[38,40],function(a){var c;if(b.highlightedPoint)if((c=
31
+ b.series[b.highlightedPoint.series.index+(38===a?-1:1)])&&c.points[0])c.points[0].highlight();else return this.move(40===a?1:-1)}],[[13,32],function(){b.highlightedPoint&&b.highlightedPoint.firePointEvent("click")}]],{init:function(a){var c=b.series&&b.series[b.series.length-1],c=c&&c.points&&c.points[c.points.length-1];0>a&&c&&c.highlight()}}),c([[[37,38],function(){for(var a=b.highlightedExportItem||0,c=!0,d=b.series;a--;)if(b.highlightExportItem(a)){c=!1;break}if(c)return b.hideExportMenu(),d&&
32
+ d.length&&(a=d[d.length-1],a.points.length&&a.points[a.points.length-1].highlight()),this.move(-1)}],[[39,40],function(){for(var a=!0,c=(b.highlightedExportItem||0)+1;c<b.exportDivElements.length;++c)if(b.highlightExportItem(c)){a=!1;break}if(a)return b.hideExportMenu(),this.move(1)}],[[13,32],function(){k(b.exportDivElements[b.highlightedExportItem])}]],{validate:function(){return b.exportChart&&!(b.options.exporting&&!1===b.options.exporting.enabled)},init:function(a){b.highlightedPoint=null;b.showExportMenu();
33
+ if(0>a&&b.exportDivElements)for(a=b.exportDivElements.length;-1<a&&!b.highlightExportItem(a);--a);}}),c([[[38,40,37,39],function(a){b[38===a||40===a?"yAxis":"xAxis"][0].panStep(39>a?-1:1)}],[[9],function(a,c){b.mapNavButtons[b.focusedMapNavButtonIx].setState(0);if(c.shiftKey&&!b.focusedMapNavButtonIx||!c.shiftKey&&b.focusedMapNavButtonIx)return b.mapZoom(),this.move(c.shiftKey?-1:1);b.focusedMapNavButtonIx+=c.shiftKey?-1:1;a=b.mapNavButtons[b.focusedMapNavButtonIx];a.element.focus&&a.element.focus();
34
+ a.setState(2)}],[[13,32],function(){k(b.mapNavButtons[b.focusedMapNavButtonIx].element)}]],{validate:function(){return b.mapZoom&&b.mapNavButtons&&2===b.mapNavButtons.length},transformTabs:!1,init:function(a){var c=b.mapNavButtons[0],d=b.mapNavButtons[1],c=0<a?c:d;g(b.mapNavButtons,function(a,b){a.element.setAttribute("tabindex",-1);a.element.setAttribute("role","button");a.element.setAttribute("aria-label","Zoom "+(b?"out":"")+"chart")});c.element.focus&&c.element.focus();c.setState(2);b.focusedMapNavButtonIx=
35
+ 0<a?0:1}}),c([[[37,39,38,40],function(a){a=37===a||38===a?-1:1;if(!b.highlightRangeSelectorButton(b.highlightedRangeSelectorItemIx+a))return this.move(a)}],[[13,32],function(){3!==b.oldRangeSelectorItemState&&k(b.rangeSelector.buttons[b.highlightedRangeSelectorItemIx].element)}]],{validate:function(){return b.rangeSelector&&b.rangeSelector.buttons&&b.rangeSelector.buttons.length},init:function(a){g(b.rangeSelector.buttons,function(a){a.element.setAttribute("tabindex","-1");a.element.setAttribute("role",
36
+ "button");a.element.setAttribute("aria-label","Select range "+(a.text&&a.text.textStr))});b.highlightRangeSelectorButton(0<a?0:b.rangeSelector.buttons.length-1)}}),c([[[9,38,40],function(a,c){a=9===a&&c.shiftKey||38===a?-1:1;c=b.highlightedInputRangeIx+=a;if(1<c||0>c)return this.move(a);b.rangeSelector[c?"maxInput":"minInput"].focus()}]],{validate:function(){return b.rangeSelector&&b.rangeSelector.inputGroup&&"hidden"!==b.rangeSelector.inputGroup.element.getAttribute("visibility")&&!1!==b.options.rangeSelector.inputEnabled&&
37
+ b.rangeSelector.minInput&&b.rangeSelector.maxInput},transformTabs:!1,init:function(a){b.highlightedInputRangeIx=0<a?0:1;b.rangeSelector[b.highlightedInputRangeIx?"maxInput":"minInput"].focus()}}),c([[[37,39,38,40],function(a){a=37===a||38===a?-1:1;if(!b.highlightLegendItem(b.highlightedLegendItemIx+a))return this.move(a)}],[[13,32],function(){k(b.legend.allItems[b.highlightedLegendItemIx].legendItem.element.parentNode)}]],{validate:function(){return b.legend&&b.legend.allItems&&!(b.colorAxis&&b.colorAxis.length)},
38
+ init:function(a){g(b.legend.allItems,function(a){a.legendGroup.element.setAttribute("tabindex","-1");a.legendGroup.element.setAttribute("role","button");a.legendGroup.element.setAttribute("aria-label","Toggle visibility of series "+a.name)});b.highlightLegendItem(0<a?0:b.legend.allItems.length-1)}})];b.keyboardNavigationModuleIndex=0;b.container.hasAttribute&&!b.container.hasAttribute("tabIndex")&&b.container.setAttribute("tabindex","0");v(b.renderTo,"keydown",d);v(b,"destroy",function(){B(b.renderTo,
39
+ "keydown",d)})};e.Chart.prototype.addScreenReaderRegion=function(a,c){var d=this,b=d.series,e=d.options,g=e.accessibility,m=d.screenReaderRegion=l.createElement("div"),k=l.createElement("h4"),n=l.createElement("a"),t=l.createElement("h4"),u={position:"absolute",left:"-9999px",top:"auto",width:"1px",height:"1px",overflow:"hidden"},h=d.types||[],h=(1===h.length&&"pie"===h[0]||"map"===h[0])&&{}||d.getAxesDescription(),p=b[0]&&r[b[0].type]||r["default"];m.setAttribute("id",a);m.setAttribute("role","region");
40
+ m.setAttribute("aria-label","Chart screen reader information.");m.innerHTML=g.screenReaderSectionFormatter&&g.screenReaderSectionFormatter(d)||"\x3cdiv\x3eUse regions/landmarks to skip ahead to chart"+(1<b.length?" and navigate between data series":"")+".\x3c/div\x3e\x3ch3\x3e"+(e.title.text?q(e.title.text):"Chart")+(e.subtitle&&e.subtitle.text?". "+q(e.subtitle.text):"")+"\x3c/h3\x3e\x3ch4\x3eLong description.\x3c/h4\x3e\x3cdiv\x3e"+(e.chart.description||"No description available.")+"\x3c/div\x3e\x3ch4\x3eStructure.\x3c/h4\x3e\x3cdiv\x3eChart type: "+
41
+ (e.chart.typeDescription||d.getTypeDescription())+"\x3c/div\x3e"+(1===b.length?"\x3cdiv\x3e"+p[0]+" with "+b[0].points.length+" "+(1===b[0].points.length?p[1]:p[2])+".\x3c/div\x3e":"")+(h.xAxis?"\x3cdiv\x3e"+h.xAxis+"\x3c/div\x3e":"")+(h.yAxis?"\x3cdiv\x3e"+h.yAxis+"\x3c/div\x3e":"");d.getCSV&&(n.innerHTML="View as data table.",n.href="#"+c,n.setAttribute("tabindex","-1"),n.onclick=g.onTableAnchorClick||function(){d.viewData();l.getElementById(c).focus()},k.appendChild(n),m.appendChild(k));t.innerHTML=
42
+ "Chart graphic.";d.renderTo.insertBefore(t,d.renderTo.firstChild);d.renderTo.insertBefore(m,d.renderTo.firstChild);w(!0,t.style,u);w(!0,m.style,u)};e.Chart.prototype.callbacks.push(function(a){var c=a.options,d=c.accessibility;if(d.enabled){var b=l.createElementNS("http://www.w3.org/2000/svg","title"),f=l.createElementNS("http://www.w3.org/2000/svg","g"),k=a.container.getElementsByTagName("desc")[0],m=a.container.getElementsByTagName("text"),r="highcharts-title-"+a.index,n="highcharts-data-table-"+
43
+ a.index,t="highcharts-information-region-"+a.index,u=c.title.text||"Chart",h=c.exporting&&c.exporting.csv&&c.exporting.csv.columnHeaderFormatter,p=[];b.textContent=q(u);b.id=r;k.parentNode.insertBefore(b,k);a.renderTo.setAttribute("role","region");a.container.setAttribute("aria-details",t);a.renderTo.setAttribute("aria-label","Interactive chart. "+u+". Use up and down arrows to navigate with most screen readers.");if(a.exportSVGElements&&a.exportSVGElements[0]&&a.exportSVGElements[0].element){var v=
44
+ a.exportSVGElements[0].element.onclick,b=a.exportSVGElements[0].element.parentNode;a.exportSVGElements[0].element.onclick=function(){v.apply(this,Array.prototype.slice.call(arguments));a.addAccessibleContextMenuAttribs();a.highlightExportItem(0)};a.exportSVGElements[0].element.setAttribute("role","button");a.exportSVGElements[0].element.setAttribute("aria-label","View export menu");f.appendChild(a.exportSVGElements[0].element);f.setAttribute("role","region");f.setAttribute("aria-label","Chart export menu");
45
+ b.appendChild(f)}a.rangeSelector&&g(["minInput","maxInput"],function(b,c){a.rangeSelector[b]&&(a.rangeSelector[b].setAttribute("tabindex","-1"),a.rangeSelector[b].setAttribute("role","textbox"),a.rangeSelector[b].setAttribute("aria-label","Select "+(c?"end":"start")+" date."))});g(m,function(a){a.setAttribute("aria-hidden","true")});a.addScreenReaderRegion(t,n);d.keyboardNavigation.enabled&&a.addKeyboardNavEvents();w(!0,c.exporting,{csv:{columnHeaderFormatter:function(a,b,c){if(!a)return"Category";
46
+ if(a instanceof e.Axis)return a.options.title&&a.options.title.text||(a.isDatetimeAxis?"DateTime":"Category");var d=p[p.length-1];1<c&&(d&&d.text)!==a.name&&p.push({text:a.name,span:c});return h?h.call(this,a,b,c):1<c?b:a.name}}});e.wrap(a,"getTable",function(a){return a.apply(this,Array.prototype.slice.call(arguments,1)).replace("\x3ctable\x3e",'\x3ctable id\x3d"'+n+'" summary\x3d"Table representation of chart"\x3e\x3ccaption\x3e'+u+"\x3c/caption\x3e")});e.wrap(a,"viewData",function(a){if(!this.insertedTable){a.apply(this,
47
+ Array.prototype.slice.call(arguments,1));var b=l.getElementById(n),c=b.getElementsByTagName("thead")[0],d=b.getElementsByTagName("tbody")[0],e=c.firstChild.children,f="\x3ctr\x3e\x3ctd\x3e\x3c/td\x3e",h,k;b.setAttribute("tabindex","-1");g(d.children,function(a){h=a.firstChild;k=l.createElement("th");k.setAttribute("scope","row");k.innerHTML=h.innerHTML;h.parentNode.replaceChild(k,h)});g(e,function(a){"TH"===a.tagName&&a.setAttribute("scope","col")});p.length&&(g(p,function(a){f+='\x3cth scope\x3d"col" colspan\x3d"'+
48
+ a.span+'"\x3e'+a.text+"\x3c/th\x3e"}),c.insertAdjacentHTML("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H","htmlencode","html","replace","reverseChildNodes","node","i","childNodes","length","appendChild","fakeClickEvent","element","fakeEvent","onclick","doc","createEvent","initEvent","win","document","each","erase","addEvent","removeEvent","fireEvent","dateFormat","merge","typeToSeriesMap","typeDescriptionMap","boxplot","arearange","areasplinerange","bubble","columnrange","errorbar","funnel","pyramid","waterfall","Series","prototype","commonKeys","specialKeys","seriesTypes","pie","setOptions","accessibility","enabled","pointDescriptionThreshold","keyboardNavigation","wrap","proceed","apply","Array","slice","call","arguments","chart","options","setA11yDescription","H.Series.prototype.setA11yDescription","a11yOptions","firstPointEl","points","graphic","seriesEl","parentNode","graph","group","lastChild","point","setAttribute","pointDescriptionFormatter","buildPointInfoString","series","describeSingleSeries","seriesDescriptionFormatter","buildSeriesInfoString","H.Series.prototype.buildSeriesInfoString","typeInfo","type","description","name","types","index","yAxis","getDescription","xAxis","Point","H.Point.prototype.buildPointInfoString","infoString","dateTimePoint","isDatetimeAxis","timeDesc","pointDateFormatter","pointDateFormat","Tooltip","getXDateFormat","tooltip","x","find","hasSpecialKey","key","undefined","concat","category","id","value","y","Axis","H.Axis.prototype.getDescription","userOptions","axisTitle","textStr","categories","panStep","H.Axis.prototype.panStep","direction","granularity","gran","extremes","getExtremes","step","max","min","newMax","newMin","size","dataMin","dataMax","setExtremes","indexOf","push","removedSeries","hasType","s","Chart","getTypeDescription","H.Chart.prototype.getTypeDescription","firstType","mapTitle","getAxesDescription","H.Chart.prototype.getAxesDescription","numXAxes","numYAxes","desc","addAccessibleContextMenuAttribs","H.Chart.prototype.addAccessibleContextMenuAttribs","exportList","exportDivElements","item","tagName","children","highlight","H.Point.prototype.highlight","focus","isNull","hide","onMouseOver","refresh","shared","highlightedPoint","highlightAdjacentPoint","H.Chart.prototype.highlightAdjacentPoint","next","curPoint","curPointIndex","curPoints","forwardSkipAmount","connectEnds","newSeries","newPoint","skipNullPoints","skipKeyboardNavigation","showExportMenu","H.Chart.prototype.showExportMenu","exportSVGElements","highlightExportItem","H.Chart.prototype.highlightExportItem","ix","listItem","curHighlighted","highlightedExportItem","onmouseout","onmouseover","highlightRangeSelectorButton","H.Chart.prototype.highlightRangeSelectorButton","buttons","rangeSelector","highlightedRangeSelectorItemIx","setState","oldRangeSelectorItemState","state","highlightLegendItem","H.Chart.prototype.highlightLegendItem","items","legend","allItems","highlightedLegendItemIx","legendGroup","hideExportMenu","H.Chart.prototype.hideExportMenu","el","renderTo","addKeyboardNavEvents","H.Chart.prototype.addKeyboardNavEvents","KeyboardNavigationModule","keyCodeMap","move","validate","init","transformTabs","navModuleFactory","keyMap","keyboardNavigationModuleIndex","newModule","keyboardNavigationModules","slipNextTab","keydownHandler","ev","e","event","curNavModule","which","keyCode","run","preventDefault","navModule","handled","shiftKey","codeSet","firePointEvent","lastSeries","lastPoint","reachedEnd","exportChart","exporting","mapNavButtons","focusedMapNavButtonIx","mapZoom","button","zoomIn","zoomOut","initialButton","text","newIx","highlightedInputRangeIx","inputGroup","getAttribute","inputEnabled","minInput","maxInput","legendItem","colorAxis","container","hasAttribute","addScreenReaderRegion","H.Chart.prototype.addScreenReaderRegion","tableId","hiddenSection","screenReaderRegion","createElement","tableShortcut","tableShortcutAnchor","chartHeading","hiddenStyle","position","left","top","width","height","overflow","chartTypes","axesDesc","chartTypeInfo","innerHTML","screenReaderSectionFormatter","title","subtitle","typeDescription","getCSV","href","onTableAnchorClick","viewData","getElementById","insertBefore","firstChild","style","callbacks","titleElement","createElementNS","exportGroupElement","descElement","getElementsByTagName","textElements","titleId","hiddenSectionId","chartTitle","oldColumnHeaderFormatter","csv","columnHeaderFormatter","topLevelColumns","textContent","oldExportCallback","parent","keyLength","prevCol","span","insertedTable","table","head","body","firstRow","columnHeaderRow","cell","newCell","replaceChild","col","insertAdjacentHTML"]
8
+ }
@@ -0,0 +1,1131 @@
1
+ /**
2
+ * @license Highcharts JS v5.0.11 (2017-05-04)
3
+ * Accessibility module
4
+ *
5
+ * (c) 2010-2017 Highsoft AS
6
+ * Author: Oystein Moseng
7
+ *
8
+ * License: www.highcharts.com/license
9
+ */
10
+ 'use strict';
11
+ (function(factory) {
12
+ if (typeof module === 'object' && module.exports) {
13
+ module.exports = factory;
14
+ } else {
15
+ factory(Highcharts);
16
+ }
17
+ }(function(Highcharts) {
18
+ (function(H) {
19
+ /**
20
+ * Accessibility module
21
+ *
22
+ * (c) 2010-2017 Highsoft AS
23
+ * Author: Oystein Moseng
24
+ *
25
+ * License: www.highcharts.com/license
26
+ */
27
+
28
+ var win = H.win,
29
+ doc = win.document,
30
+ each = H.each,
31
+ erase = H.erase,
32
+ addEvent = H.addEvent,
33
+ removeEvent = H.removeEvent,
34
+ fireEvent = H.fireEvent,
35
+ dateFormat = H.dateFormat,
36
+ merge = H.merge,
37
+ // Human readable description of series and each point in singular and plural
38
+ typeToSeriesMap = {
39
+ 'default': ['series', 'data point', 'data points'],
40
+ 'line': ['line', 'data point', 'data points'],
41
+ 'spline': ['line', 'data point', 'data points'],
42
+ 'area': ['line', 'data point', 'data points'],
43
+ 'areaspline': ['line', 'data point', 'data points'],
44
+ 'pie': ['pie', 'slice', 'slices'],
45
+ 'column': ['column series', 'column', 'columns'],
46
+ 'bar': ['bar series', 'bar', 'bars'],
47
+ 'scatter': ['scatter series', 'data point', 'data points'],
48
+ 'boxplot': ['boxplot series', 'box', 'boxes'],
49
+ 'arearange': ['arearange series', 'data point', 'data points'],
50
+ 'areasplinerange': ['areasplinerange series', 'data point', 'data points'],
51
+ 'bubble': ['bubble series', 'bubble', 'bubbles'],
52
+ 'columnrange': ['columnrange series', 'column', 'columns'],
53
+ 'errorbar': ['errorbar series', 'errorbar', 'errorbars'],
54
+ 'funnel': ['funnel', 'data point', 'data points'],
55
+ 'pyramid': ['pyramid', 'data point', 'data points'],
56
+ 'waterfall': ['waterfall series', 'column', 'columns'],
57
+ 'map': ['map', 'area', 'areas'],
58
+ 'mapline': ['line', 'data point', 'data points'],
59
+ 'mappoint': ['point series', 'data point', 'data points'],
60
+ 'mapbubble': ['bubble series', 'bubble', 'bubbles']
61
+ },
62
+ // Descriptions for exotic chart types
63
+ typeDescriptionMap = {
64
+ boxplot: ' Box plot charts are typically used to display groups of statistical data. ' +
65
+ 'Each data point in the chart can have up to 5 values: minimum, lower quartile, median, upper quartile and maximum. ',
66
+ arearange: ' Arearange charts are line charts displaying a range between a lower and higher value for each point. ',
67
+ areasplinerange: ' These charts are line charts displaying a range between a lower and higher value for each point. ',
68
+ bubble: ' Bubble charts are scatter charts where each data point also has a size value. ',
69
+ columnrange: ' Columnrange charts are column charts displaying a range between a lower and higher value for each point. ',
70
+ errorbar: ' Errorbar series are used to display the variability of the data. ',
71
+ funnel: ' Funnel charts are used to display reduction of data in stages. ',
72
+ pyramid: ' Pyramid charts consist of a single pyramid with item heights corresponding to each point value. ',
73
+ waterfall: ' A waterfall chart is a column chart where each column contributes towards a total end value. '
74
+ };
75
+
76
+ // If a point has one of the special keys defined, we expose all keys to the
77
+ // screen reader.
78
+ H.Series.prototype.commonKeys = ['name', 'id', 'category', 'x', 'value', 'y'];
79
+ H.Series.prototype.specialKeys = [
80
+ 'z', 'open', 'high', 'q3', 'median', 'q1', 'low', 'close'
81
+ ];
82
+
83
+ // A pie is always simple. Don't quote me on that.
84
+ if (H.seriesTypes.pie) {
85
+ H.seriesTypes.pie.prototype.specialKeys = [];
86
+ }
87
+
88
+
89
+ // Default a11y options
90
+ H.setOptions({
91
+ accessibility: {
92
+ enabled: true,
93
+ pointDescriptionThreshold: 30, // set to false to disable
94
+ keyboardNavigation: {
95
+ enabled: true
96
+ // skipNullPoints: false
97
+ }
98
+ // describeSingleSeries: false
99
+ }
100
+ });
101
+
102
+ /**
103
+ * HTML encode some characters vulnerable for XSS.
104
+ * @param {string} html The input string
105
+ * @return {string} The excaped string
106
+ */
107
+ function htmlencode(html) {
108
+ return html
109
+ .replace(/&/g, '&amp;')
110
+ .replace(/</g, '&lt;')
111
+ .replace(/>/g, '&gt;')
112
+ .replace(/"/g, '&quot;')
113
+ .replace(/'/g, '&#x27;')
114
+ .replace(/\//g, '&#x2F;');
115
+ }
116
+
117
+ // Utility function. Reverses child nodes of a DOM element
118
+ function reverseChildNodes(node) {
119
+ var i = node.childNodes.length;
120
+ while (i--) {
121
+ node.appendChild(node.childNodes[i]);
122
+ }
123
+ }
124
+
125
+ // Utility function to attempt to fake a click event on an element
126
+ function fakeClickEvent(element) {
127
+ var fakeEvent;
128
+ if (element && element.onclick && doc.createEvent) {
129
+ fakeEvent = doc.createEvent('Events');
130
+ fakeEvent.initEvent('click', true, false);
131
+ element.onclick(fakeEvent);
132
+ }
133
+ }
134
+
135
+ // Whenever drawing series, put info on DOM elements
136
+ H.wrap(H.Series.prototype, 'render', function(proceed) {
137
+ proceed.apply(this, Array.prototype.slice.call(arguments, 1));
138
+ if (this.chart.options.accessibility.enabled) {
139
+ this.setA11yDescription();
140
+ }
141
+ });
142
+
143
+ // Put accessible info on series and points of a series
144
+ H.Series.prototype.setA11yDescription = function() {
145
+ var a11yOptions = this.chart.options.accessibility,
146
+ firstPointEl = this.points && this.points.length && this.points[0].graphic && this.points[0].graphic.element,
147
+ seriesEl = firstPointEl && firstPointEl.parentNode || this.graph && this.graph.element || this.group && this.group.element; // Could be tracker series depending on series type
148
+
149
+ if (seriesEl) {
150
+ // For some series types the order of elements do not match the order of points in series
151
+ // In that case we have to reverse them in order for AT to read them out in an understandable order
152
+ if (seriesEl.lastChild === firstPointEl) {
153
+ reverseChildNodes(seriesEl);
154
+ }
155
+ // Make individual point elements accessible if possible. Note: If markers are disabled there might not be any elements there to make accessible.
156
+ if (this.points && (this.points.length < a11yOptions.pointDescriptionThreshold || a11yOptions.pointDescriptionThreshold === false)) {
157
+ each(this.points, function(point) {
158
+ if (point.graphic) {
159
+ point.graphic.element.setAttribute('role', 'img');
160
+ point.graphic.element.setAttribute('tabindex', '-1');
161
+ point.graphic.element.setAttribute('aria-label', a11yOptions.pointDescriptionFormatter && a11yOptions.pointDescriptionFormatter(point) ||
162
+ point.buildPointInfoString());
163
+ }
164
+ });
165
+ }
166
+ // Make series element accessible
167
+ if (this.chart.series.length > 1 || a11yOptions.describeSingleSeries) {
168
+ seriesEl.setAttribute('role', 'region');
169
+ seriesEl.setAttribute('tabindex', '-1');
170
+ seriesEl.setAttribute('aria-label', a11yOptions.seriesDescriptionFormatter && a11yOptions.seriesDescriptionFormatter(this) ||
171
+ this.buildSeriesInfoString());
172
+ }
173
+ }
174
+ };
175
+
176
+ // Return string with information about series
177
+ H.Series.prototype.buildSeriesInfoString = function() {
178
+ var typeInfo = typeToSeriesMap[this.type] || typeToSeriesMap['default'], // eslint-disable-line dot-notation
179
+ description = this.description || this.options.description;
180
+ return (this.name ? this.name + ', ' : '') +
181
+ (this.chart.types.length === 1 ? typeInfo[0] : 'series') + ' ' + (this.index + 1) + ' of ' + (this.chart.series.length) +
182
+ (this.chart.types.length === 1 ? ' with ' : '. ' + typeInfo[0] + ' with ') +
183
+ (this.points.length + ' ' + (this.points.length === 1 ? typeInfo[1] : typeInfo[2])) +
184
+ (description ? '. ' + description : '') +
185
+ (this.chart.yAxis.length > 1 && this.yAxis ? '. Y axis, ' + this.yAxis.getDescription() : '') +
186
+ (this.chart.xAxis.length > 1 && this.xAxis ? '. X axis, ' + this.xAxis.getDescription() : '');
187
+ };
188
+
189
+ // Return string with information about point
190
+ H.Point.prototype.buildPointInfoString = function() {
191
+ var point = this,
192
+ series = point.series,
193
+ a11yOptions = series.chart.options.accessibility,
194
+ infoString = '',
195
+ dateTimePoint = series.xAxis && series.xAxis.isDatetimeAxis,
196
+ timeDesc = dateTimePoint && dateFormat(a11yOptions.pointDateFormatter && a11yOptions.pointDateFormatter(point) || a11yOptions.pointDateFormat ||
197
+ H.Tooltip.prototype.getXDateFormat(point, series.chart.options.tooltip, series.xAxis), point.x),
198
+ hasSpecialKey = H.find(series.specialKeys, function(key) {
199
+ return point[key] !== undefined;
200
+ });
201
+
202
+ // If the point has one of the less common properties defined, display all that are defined
203
+ if (hasSpecialKey) {
204
+ if (dateTimePoint) {
205
+ infoString = timeDesc;
206
+ }
207
+ each(series.commonKeys.concat(series.specialKeys), function(key) {
208
+ if (point[key] !== undefined && !(dateTimePoint && key === 'x')) {
209
+ infoString += (infoString ? '. ' : '') + key + ', ' + point[key];
210
+ }
211
+ });
212
+ } else {
213
+ // Pick and choose properties for a succint label
214
+ infoString = (this.name || timeDesc || this.category || this.id || 'x, ' + this.x) + ', ' +
215
+ (this.value !== undefined ? this.value : this.y);
216
+ }
217
+
218
+ return (this.index + 1) + '. ' + infoString + '.' + (this.description ? ' ' + this.description : '');
219
+ };
220
+
221
+ // Get descriptive label for axis
222
+ H.Axis.prototype.getDescription = function() {
223
+ return this.userOptions && this.userOptions.description || this.axisTitle && this.axisTitle.textStr ||
224
+ this.options.id || this.categories && 'categories' || 'values';
225
+ };
226
+
227
+ // Pan along axis in a direction (1 or -1), optionally with a defined granularity (number of steps it takes to walk across current view)
228
+ H.Axis.prototype.panStep = function(direction, granularity) {
229
+ var gran = granularity || 3,
230
+ extremes = this.getExtremes(),
231
+ step = (extremes.max - extremes.min) / gran * direction,
232
+ newMax = extremes.max + step,
233
+ newMin = extremes.min + step,
234
+ size = newMax - newMin;
235
+ if (direction < 0 && newMin < extremes.dataMin) {
236
+ newMin = extremes.dataMin;
237
+ newMax = newMin + size;
238
+ } else if (direction > 0 && newMax > extremes.dataMax) {
239
+ newMax = extremes.dataMax;
240
+ newMin = newMax - size;
241
+ }
242
+ this.setExtremes(newMin, newMax);
243
+ };
244
+
245
+ // Whenever adding or removing series, keep track of types present in chart
246
+ H.wrap(H.Series.prototype, 'init', function(proceed) {
247
+ proceed.apply(this, Array.prototype.slice.call(arguments, 1));
248
+ var chart = this.chart;
249
+ if (chart.options.accessibility.enabled) {
250
+ chart.types = chart.types || [];
251
+
252
+ // Add type to list if does not exist
253
+ if (chart.types.indexOf(this.type) < 0) {
254
+ chart.types.push(this.type);
255
+ }
256
+
257
+ addEvent(this, 'remove', function() {
258
+ var removedSeries = this,
259
+ hasType = false;
260
+
261
+ // Check if any of the other series have the same type as this one. Otherwise remove it from the list.
262
+ each(chart.series, function(s) {
263
+ if (s !== removedSeries && chart.types.indexOf(removedSeries.type) < 0) {
264
+ hasType = true;
265
+ }
266
+ });
267
+ if (!hasType) {
268
+ erase(chart.types, removedSeries.type);
269
+ }
270
+ });
271
+ }
272
+ });
273
+
274
+ // Return simplified description of chart type. Some types will not be familiar to most screen reader users, but we try.
275
+ H.Chart.prototype.getTypeDescription = function() {
276
+ var firstType = this.types && this.types[0],
277
+ mapTitle = this.series[0] && this.series[0].mapTitle;
278
+ if (!firstType) {
279
+ return 'Empty chart.';
280
+ } else if (firstType === 'map') {
281
+ return mapTitle ? 'Map of ' + mapTitle : 'Map of unspecified region.';
282
+ } else if (this.types.length > 1) {
283
+ return 'Combination chart.';
284
+ } else if (['spline', 'area', 'areaspline'].indexOf(firstType) > -1) {
285
+ return 'Line chart.';
286
+ }
287
+ return firstType + ' chart.' + (typeDescriptionMap[firstType] || '');
288
+ };
289
+
290
+ // Return object with text description of each of the chart's axes
291
+ H.Chart.prototype.getAxesDescription = function() {
292
+ var numXAxes = this.xAxis.length,
293
+ numYAxes = this.yAxis.length,
294
+ desc = {},
295
+ i;
296
+
297
+ if (numXAxes) {
298
+ desc.xAxis = 'The chart has ' + numXAxes + (numXAxes > 1 ? ' X axes' : ' X axis') + ' displaying ';
299
+ if (numXAxes < 2) {
300
+ desc.xAxis += this.xAxis[0].getDescription() + '.';
301
+ } else {
302
+ for (i = 0; i < numXAxes - 1; ++i) {
303
+ desc.xAxis += (i ? ', ' : '') + this.xAxis[i].getDescription();
304
+ }
305
+ desc.xAxis += ' and ' + this.xAxis[i].getDescription() + '.';
306
+ }
307
+ }
308
+
309
+ if (numYAxes) {
310
+ desc.yAxis = 'The chart has ' + numYAxes + (numYAxes > 1 ? ' Y axes' : ' Y axis') + ' displaying ';
311
+ if (numYAxes < 2) {
312
+ desc.yAxis += this.yAxis[0].getDescription() + '.';
313
+ } else {
314
+ for (i = 0; i < numYAxes - 1; ++i) {
315
+ desc.yAxis += (i ? ', ' : '') + this.yAxis[i].getDescription();
316
+ }
317
+ desc.yAxis += ' and ' + this.yAxis[i].getDescription() + '.';
318
+ }
319
+ }
320
+
321
+ return desc;
322
+ };
323
+
324
+ // Set a11y attribs on exporting menu
325
+ H.Chart.prototype.addAccessibleContextMenuAttribs = function() {
326
+ var exportList = this.exportDivElements;
327
+ if (exportList) {
328
+ // Set tabindex on the menu items to allow focusing by script
329
+ // Set role to give screen readers a chance to pick up the contents
330
+ each(exportList, function(item) {
331
+ if (item.tagName === 'DIV' &&
332
+ !(item.children && item.children.length)) {
333
+ item.setAttribute('role', 'menuitem');
334
+ item.setAttribute('tabindex', -1);
335
+ }
336
+ });
337
+ // Set accessibility properties on parent div
338
+ exportList[0].parentNode.setAttribute('role', 'menu');
339
+ exportList[0].parentNode.setAttribute('aria-label', 'Chart export');
340
+ }
341
+ };
342
+
343
+ // Highlight a point (show tooltip and display hover state). Returns the highlighted point.
344
+ H.Point.prototype.highlight = function() {
345
+ var chart = this.series.chart;
346
+ if (this.graphic && this.graphic.element.focus) {
347
+ this.graphic.element.focus();
348
+ }
349
+ if (!this.isNull) {
350
+ this.onMouseOver(); // Show the hover marker
351
+ // Show the tooltip
352
+ if (chart.tooltip) {
353
+ chart.tooltip.refresh(chart.tooltip.shared ? [this] : this);
354
+ }
355
+ } else {
356
+ if (chart.tooltip) {
357
+ chart.tooltip.hide(0);
358
+ }
359
+ // Don't call blur on the element, as it messes up the chart div's focus
360
+ }
361
+ chart.highlightedPoint = this;
362
+ return this;
363
+ };
364
+
365
+ // Function to highlight next/previous point in chart
366
+ // Returns highlighted point on success, false on failure (no adjacent point to highlight in chosen direction)
367
+ H.Chart.prototype.highlightAdjacentPoint = function(next) {
368
+ var series = this.series,
369
+ curPoint = this.highlightedPoint,
370
+ curPointIndex = curPoint && curPoint.index || 0,
371
+ curPoints = curPoint && curPoint.series.points,
372
+ newSeries,
373
+ newPoint,
374
+ // Handle connecting ends - where the points array has an extra last
375
+ // point that is a reference to the first one. We skip this.
376
+ forwardSkipAmount = curPoint && curPoint.series.connectEnds &&
377
+ curPointIndex > curPoints.length - 3 ? 2 : 1;
378
+
379
+ // If no points, return false
380
+ if (!series[0] || !series[0].points) {
381
+ return false;
382
+ }
383
+
384
+ // Use first point if none already highlighted
385
+ if (!curPoint) {
386
+ return series[0].points[0].highlight();
387
+ }
388
+
389
+ // Find index of current point in series.points array. Necessary for dataGrouping (and maybe zoom?)
390
+ if (curPoints[curPointIndex] !== curPoint) {
391
+ for (var i = 0; i < curPoints.length; ++i) {
392
+ if (curPoints[i] === curPoint) {
393
+ curPointIndex = i;
394
+ break;
395
+ }
396
+ }
397
+ }
398
+
399
+ // Grab next/prev point & series
400
+ newSeries = series[curPoint.series.index + (next ? 1 : -1)];
401
+ newPoint = curPoints[curPointIndex + (next ? forwardSkipAmount : -1)] ||
402
+ // Done with this series, try next one
403
+ newSeries &&
404
+ newSeries.points[next ? 0 : newSeries.points.length - (
405
+ newSeries.connectEnds ? 2 : 1
406
+ )];
407
+
408
+ // If there is no adjacent point, we return false
409
+ if (newPoint === undefined) {
410
+ return false;
411
+ }
412
+
413
+ // Recursively skip null points or points in series that should be skipped
414
+ if (
415
+ newPoint.isNull &&
416
+ this.options.accessibility.keyboardNavigation.skipNullPoints ||
417
+ newPoint.series.options.skipKeyboardNavigation // docs
418
+ ) {
419
+ this.highlightedPoint = newPoint;
420
+ return this.highlightAdjacentPoint(next);
421
+ }
422
+
423
+ // There is an adjacent point, highlight it
424
+ return newPoint.highlight();
425
+ };
426
+
427
+ // Show the export menu and focus the first item (if exists)
428
+ H.Chart.prototype.showExportMenu = function() {
429
+ if (this.exportSVGElements && this.exportSVGElements[0]) {
430
+ this.exportSVGElements[0].element.onclick();
431
+ this.highlightExportItem(0);
432
+ }
433
+ };
434
+
435
+ // Highlight export menu item by index
436
+ H.Chart.prototype.highlightExportItem = function(ix) {
437
+ var listItem = this.exportDivElements && this.exportDivElements[ix],
438
+ curHighlighted = this.exportDivElements && this.exportDivElements[this.highlightedExportItem];
439
+
440
+ if (listItem && listItem.tagName === 'DIV' && !(listItem.children && listItem.children.length)) {
441
+ if (listItem.focus) {
442
+ listItem.focus();
443
+ }
444
+ if (curHighlighted && curHighlighted.onmouseout) {
445
+ curHighlighted.onmouseout();
446
+ }
447
+ if (listItem.onmouseover) {
448
+ listItem.onmouseover();
449
+ }
450
+ this.highlightedExportItem = ix;
451
+ return true;
452
+ }
453
+ };
454
+
455
+ // Highlight range selector button by index
456
+ H.Chart.prototype.highlightRangeSelectorButton = function(ix) {
457
+ var buttons = this.rangeSelector.buttons;
458
+ // Deselect old
459
+ if (buttons[this.highlightedRangeSelectorItemIx]) {
460
+ buttons[this.highlightedRangeSelectorItemIx].setState(this.oldRangeSelectorItemState || 0);
461
+ }
462
+ // Select new
463
+ this.highlightedRangeSelectorItemIx = ix;
464
+ if (buttons[ix]) {
465
+ if (buttons[ix].element.focus) {
466
+ buttons[ix].element.focus();
467
+ }
468
+ this.oldRangeSelectorItemState = buttons[ix].state;
469
+ buttons[ix].setState(2);
470
+ return true;
471
+ }
472
+ return false;
473
+ };
474
+
475
+ // Highlight legend item by index
476
+ H.Chart.prototype.highlightLegendItem = function(ix) {
477
+ var items = this.legend.allItems;
478
+ if (items[this.highlightedLegendItemIx]) {
479
+ fireEvent(items[this.highlightedLegendItemIx].legendGroup.element, 'mouseout');
480
+ }
481
+ this.highlightedLegendItemIx = ix;
482
+ if (items[ix]) {
483
+ if (items[ix].legendGroup.element.focus) {
484
+ items[ix].legendGroup.element.focus();
485
+ }
486
+ fireEvent(items[ix].legendGroup.element, 'mouseover');
487
+ return true;
488
+ }
489
+ return false;
490
+ };
491
+
492
+ // Hide export menu
493
+ H.Chart.prototype.hideExportMenu = function() {
494
+ var exportList = this.exportDivElements;
495
+ if (exportList) {
496
+ each(exportList, function(el) {
497
+ fireEvent(el, 'mouseleave');
498
+ });
499
+ if (exportList[this.highlightedExportItem] && exportList[this.highlightedExportItem].onmouseout) {
500
+ exportList[this.highlightedExportItem].onmouseout();
501
+ }
502
+ this.highlightedExportItem = 0;
503
+ this.renderTo.focus();
504
+ }
505
+ };
506
+
507
+ // Add keyboard navigation handling to chart
508
+ H.Chart.prototype.addKeyboardNavEvents = function() {
509
+ var chart = this;
510
+
511
+ // Abstraction layer for keyboard navigation. Keep a map of keyCodes to handler functions, and a next/prev move handler for tab order.
512
+ // The module's keyCode handlers determine when to move to another module.
513
+ // Validate holds a function to determine if there are prerequisites for this module to run that are not met.
514
+ // Init holds a function to run once before any keyCodes are interpreted.
515
+ // transformTabs determines whether to transform tabs to left/right events or not. Defaults to true.
516
+ function KeyboardNavigationModule(options) {
517
+ this.keyCodeMap = options.keyCodeMap;
518
+ this.move = options.move;
519
+ this.validate = options.validate;
520
+ this.init = options.init;
521
+ this.transformTabs = options.transformTabs !== false;
522
+ }
523
+ KeyboardNavigationModule.prototype = {
524
+ // Find handler function(s) for key code in the keyCodeMap and run it.
525
+ run: function(e) {
526
+ var navModule = this,
527
+ keyCode = e.which || e.keyCode,
528
+ handled = false;
529
+ keyCode = this.transformTabs && keyCode === 9 ? (e.shiftKey ? 37 : 39) : keyCode; // Transform tabs
530
+ each(this.keyCodeMap, function(codeSet) {
531
+ if (codeSet[0].indexOf(keyCode) > -1) {
532
+ handled = codeSet[1].call(navModule, keyCode, e) === false ? false : true; // If explicitly returning false, we haven't handled it
533
+ }
534
+ });
535
+ return handled;
536
+ }
537
+ };
538
+ // Maintain abstraction between KeyboardNavigationModule and Highcharts
539
+ // The chart object keeps track of a list of KeyboardNavigationModules that we move through
540
+ function navModuleFactory(keyMap, options) {
541
+ return new KeyboardNavigationModule(merge({
542
+ keyCodeMap: keyMap,
543
+ // Move to next/prev valid module, or undefined if none, and init it.
544
+ // Returns true on success and false if there is no valid module to move to.
545
+ move: function(direction) {
546
+ chart.keyboardNavigationModuleIndex += direction;
547
+ var newModule = chart.keyboardNavigationModules[chart.keyboardNavigationModuleIndex];
548
+ if (newModule) {
549
+ if (newModule.validate && !newModule.validate()) {
550
+ return this.move(direction); // Invalid module
551
+ }
552
+ if (newModule.init) {
553
+ newModule.init(direction); // Valid module, init it
554
+ return true;
555
+ }
556
+ }
557
+ // No module
558
+ chart.keyboardNavigationModuleIndex = 0; // Reset counter
559
+ chart.slipNextTab = true; // Allow next tab to slip, as we will have focus on chart now
560
+ return false;
561
+ }
562
+ }, options));
563
+ }
564
+
565
+ // Route keydown events
566
+ function keydownHandler(ev) {
567
+ var e = ev || win.event,
568
+ keyCode = e.which || e.keyCode,
569
+ curNavModule = chart.keyboardNavigationModules[chart.keyboardNavigationModuleIndex];
570
+
571
+ // Handle tabbing
572
+ if (keyCode === 9) {
573
+ // If we reached end of chart, we need to let this tab slip through to allow users to tab further
574
+ if (chart.slipNextTab) {
575
+ chart.slipNextTab = false;
576
+ return;
577
+ }
578
+ }
579
+ // If key was not tab, don't slip the next tab
580
+ chart.slipNextTab = false;
581
+
582
+ // If there is a navigation module for the current index, run it. Otherwise, we are outside of the chart in some direction.
583
+ if (curNavModule) {
584
+ if (curNavModule.run(e)) {
585
+ e.preventDefault(); // If successfully handled, stop the event here.
586
+ }
587
+ }
588
+ }
589
+
590
+ // List of the different keyboard handling modes we use depending on where we are in the chart.
591
+ // Each mode has a set of handling functions mapped to key codes.
592
+ // Each mode determines when to move to the next/prev mode.
593
+ chart.keyboardNavigationModules = [
594
+ // Points
595
+ navModuleFactory([
596
+ // Left/Right
597
+ [
598
+ [37, 39],
599
+ function(keyCode) {
600
+ if (!chart.highlightAdjacentPoint(keyCode === 39)) { // Try to highlight adjacent point
601
+ return this.move(keyCode === 39 ? 1 : -1); // Failed. Move to next/prev module
602
+ }
603
+ }
604
+ ],
605
+ // Up/Down
606
+ [
607
+ [38, 40],
608
+ function(keyCode) {
609
+ var newSeries;
610
+ if (chart.highlightedPoint) {
611
+ newSeries = chart.series[chart.highlightedPoint.series.index + (keyCode === 38 ? -1 : 1)]; // Find prev/next series
612
+ if (newSeries && newSeries.points[0]) { // If series exists and has data, go for it
613
+ newSeries.points[0].highlight();
614
+ } else {
615
+ return this.move(keyCode === 40 ? 1 : -1); // Otherwise, attempt to move to next/prev module
616
+ }
617
+ }
618
+ }
619
+ ],
620
+ // Enter/Spacebar
621
+ [
622
+ [13, 32],
623
+ function() {
624
+ if (chart.highlightedPoint) {
625
+ chart.highlightedPoint.firePointEvent('click');
626
+ }
627
+ }
628
+ ]
629
+ ], {
630
+ // If coming back to points from other module, highlight last point
631
+ init: function(direction) {
632
+ var lastSeries = chart.series && chart.series[chart.series.length - 1],
633
+ lastPoint = lastSeries && lastSeries.points && lastSeries.points[lastSeries.points.length - 1];
634
+ if (direction < 0 && lastPoint) {
635
+ lastPoint.highlight();
636
+ }
637
+ }
638
+ }),
639
+
640
+ // Exporting
641
+ navModuleFactory([
642
+ // Left/Up
643
+ [
644
+ [37, 38],
645
+ function() {
646
+ var i = chart.highlightedExportItem || 0,
647
+ reachedEnd = true,
648
+ series = chart.series,
649
+ newSeries;
650
+ // Try to highlight prev item in list. Highlighting e.g. separators will fail.
651
+ while (i--) {
652
+ if (chart.highlightExportItem(i)) {
653
+ reachedEnd = false;
654
+ break;
655
+ }
656
+ }
657
+ if (reachedEnd) {
658
+ chart.hideExportMenu();
659
+ // Wrap to last point
660
+ if (series && series.length) {
661
+ newSeries = series[series.length - 1];
662
+ if (newSeries.points.length) {
663
+ newSeries.points[newSeries.points.length - 1].highlight();
664
+ }
665
+ }
666
+ // Try to move to prev module (should be points, since we wrapped to last point)
667
+ return this.move(-1);
668
+ }
669
+ }
670
+ ],
671
+ // Right/Down
672
+ [
673
+ [39, 40],
674
+ function() {
675
+ var highlightedExportItem = chart.highlightedExportItem || 0,
676
+ reachedEnd = true;
677
+ // Try to highlight next item in list. Highlighting e.g. separators will fail.
678
+ for (var i = highlightedExportItem + 1; i < chart.exportDivElements.length; ++i) {
679
+ if (chart.highlightExportItem(i)) {
680
+ reachedEnd = false;
681
+ break;
682
+ }
683
+ }
684
+ if (reachedEnd) {
685
+ chart.hideExportMenu();
686
+ return this.move(1); // Next module
687
+ }
688
+ }
689
+ ],
690
+ // Enter/Spacebar
691
+ [
692
+ [13, 32],
693
+ function() {
694
+ fakeClickEvent(chart.exportDivElements[chart.highlightedExportItem]);
695
+ }
696
+ ]
697
+ ], {
698
+ // Only run exporting navigation if exporting support exists and is enabled on chart
699
+ validate: function() {
700
+ return chart.exportChart && !(chart.options.exporting && chart.options.exporting.enabled === false);
701
+ },
702
+ // Show export menu
703
+ init: function(direction) {
704
+ chart.highlightedPoint = null;
705
+ chart.showExportMenu();
706
+ // If coming back to export menu from other module, try to highlight last item in menu
707
+ if (direction < 0 && chart.exportDivElements) {
708
+ for (var i = chart.exportDivElements.length; i > -1; --i) {
709
+ if (chart.highlightExportItem(i)) {
710
+ break;
711
+ }
712
+ }
713
+ }
714
+ }
715
+ }),
716
+
717
+ // Map zoom
718
+ navModuleFactory([
719
+ // Up/down/left/right
720
+ [
721
+ [38, 40, 37, 39],
722
+ function(keyCode) {
723
+ chart[keyCode === 38 || keyCode === 40 ? 'yAxis' : 'xAxis'][0].panStep(keyCode < 39 ? -1 : 1);
724
+ }
725
+ ],
726
+
727
+ // Tabs
728
+ [
729
+ [9],
730
+ function(keyCode, e) {
731
+ var button;
732
+ chart.mapNavButtons[chart.focusedMapNavButtonIx].setState(0); // Deselect old
733
+ if (e.shiftKey && !chart.focusedMapNavButtonIx || !e.shiftKey && chart.focusedMapNavButtonIx) { // trying to go somewhere we can't?
734
+ chart.mapZoom(); // Reset zoom
735
+ return this.move(e.shiftKey ? -1 : 1); // Nowhere to go, go to prev/next module
736
+ }
737
+ chart.focusedMapNavButtonIx += e.shiftKey ? -1 : 1;
738
+ button = chart.mapNavButtons[chart.focusedMapNavButtonIx];
739
+ if (button.element.focus) {
740
+ button.element.focus();
741
+ }
742
+ button.setState(2);
743
+ }
744
+ ],
745
+
746
+ // Enter/Spacebar
747
+ [
748
+ [13, 32],
749
+ function() {
750
+ fakeClickEvent(chart.mapNavButtons[chart.focusedMapNavButtonIx].element);
751
+ }
752
+ ]
753
+ ], {
754
+ // Only run this module if we have map zoom on the chart
755
+ validate: function() {
756
+ return chart.mapZoom && chart.mapNavButtons && chart.mapNavButtons.length === 2;
757
+ },
758
+
759
+ // Handle tabs separately
760
+ transformTabs: false,
761
+
762
+ // Make zoom buttons do their magic
763
+ init: function(direction) {
764
+ var zoomIn = chart.mapNavButtons[0],
765
+ zoomOut = chart.mapNavButtons[1],
766
+ initialButton = direction > 0 ? zoomIn : zoomOut;
767
+
768
+ each(chart.mapNavButtons, function(button, i) {
769
+ button.element.setAttribute('tabindex', -1);
770
+ button.element.setAttribute('role', 'button');
771
+ button.element.setAttribute('aria-label', 'Zoom ' + (i ? 'out' : '') + 'chart');
772
+ });
773
+
774
+ if (initialButton.element.focus) {
775
+ initialButton.element.focus();
776
+ }
777
+ initialButton.setState(2);
778
+ chart.focusedMapNavButtonIx = direction > 0 ? 0 : 1;
779
+ }
780
+ }),
781
+
782
+ // Highstock range selector (minus input boxes)
783
+ navModuleFactory([
784
+ // Left/Right/Up/Down
785
+ [
786
+ [37, 39, 38, 40],
787
+ function(keyCode) {
788
+ var direction = (keyCode === 37 || keyCode === 38) ? -1 : 1;
789
+ // Try to highlight next/prev button
790
+ if (!chart.highlightRangeSelectorButton(chart.highlightedRangeSelectorItemIx + direction)) {
791
+ return this.move(direction);
792
+ }
793
+ }
794
+ ],
795
+ // Enter/Spacebar
796
+ [
797
+ [13, 32],
798
+ function() {
799
+ if (chart.oldRangeSelectorItemState !== 3) { // Don't allow click if button used to be disabled
800
+ fakeClickEvent(chart.rangeSelector.buttons[chart.highlightedRangeSelectorItemIx].element);
801
+ }
802
+ }
803
+ ]
804
+ ], {
805
+ // Only run this module if we have range selector
806
+ validate: function() {
807
+ return chart.rangeSelector && chart.rangeSelector.buttons && chart.rangeSelector.buttons.length;
808
+ },
809
+
810
+ // Make elements focusable and accessible
811
+ init: function(direction) {
812
+ each(chart.rangeSelector.buttons, function(button) {
813
+ button.element.setAttribute('tabindex', '-1');
814
+ button.element.setAttribute('role', 'button');
815
+ button.element.setAttribute('aria-label', 'Select range ' + (button.text && button.text.textStr));
816
+ });
817
+ // Focus first/last button
818
+ chart.highlightRangeSelectorButton(direction > 0 ? 0 : chart.rangeSelector.buttons.length - 1);
819
+ }
820
+ }),
821
+
822
+ // Highstock range selector, input boxes
823
+ navModuleFactory([
824
+ // Tab/Up/Down
825
+ [
826
+ [9, 38, 40],
827
+ function(keyCode, e) {
828
+ var direction = (keyCode === 9 && e.shiftKey || keyCode === 38) ? -1 : 1,
829
+ newIx = chart.highlightedInputRangeIx = chart.highlightedInputRangeIx + direction;
830
+ // Try to highlight next/prev item in list.
831
+ if (newIx > 1 || newIx < 0) { // Out of range
832
+ return this.move(direction);
833
+ }
834
+ chart.rangeSelector[newIx ? 'maxInput' : 'minInput'].focus(); // Input boxes are HTML, and should have focus support in all browsers
835
+ }
836
+ ]
837
+ ], {
838
+ // Only run if we have range selector with input boxes
839
+ validate: function() {
840
+ var inputVisible = chart.rangeSelector && chart.rangeSelector.inputGroup && chart.rangeSelector.inputGroup.element.getAttribute('visibility') !== 'hidden';
841
+ return inputVisible && chart.options.rangeSelector.inputEnabled !== false && chart.rangeSelector.minInput && chart.rangeSelector.maxInput;
842
+ },
843
+
844
+ // Handle tabs different from left/right (because we don't want to catch left/right in a text area)
845
+ transformTabs: false,
846
+
847
+ // Highlight first/last input box
848
+ init: function(direction) {
849
+ chart.highlightedInputRangeIx = direction > 0 ? 0 : 1;
850
+ chart.rangeSelector[chart.highlightedInputRangeIx ? 'maxInput' : 'minInput'].focus();
851
+ }
852
+ }),
853
+
854
+ // Legend navigation
855
+ navModuleFactory([
856
+ // Left/Right/Up/Down
857
+ [
858
+ [37, 39, 38, 40],
859
+ function(keyCode) {
860
+ var direction = (keyCode === 37 || keyCode === 38) ? -1 : 1;
861
+ // Try to highlight next/prev legend item
862
+ if (!chart.highlightLegendItem(chart.highlightedLegendItemIx + direction)) {
863
+ return this.move(direction);
864
+ }
865
+ }
866
+ ],
867
+ // Enter/Spacebar
868
+ [
869
+ [13, 32],
870
+ function() {
871
+ fakeClickEvent(chart.legend.allItems[chart.highlightedLegendItemIx].legendItem.element.parentNode);
872
+ }
873
+ ]
874
+ ], {
875
+ // Only run this module if we have at least one legend - wait for it - item.
876
+ // Don't run if the legend is populated by a colorAxis.
877
+ validate: function() {
878
+ return chart.legend && chart.legend.allItems &&
879
+ !(chart.colorAxis && chart.colorAxis.length);
880
+ },
881
+
882
+ // Make elements focusable and accessible
883
+ init: function(direction) {
884
+ each(chart.legend.allItems, function(item) {
885
+ item.legendGroup.element.setAttribute('tabindex', '-1');
886
+ item.legendGroup.element.setAttribute('role', 'button');
887
+ item.legendGroup.element.setAttribute('aria-label', 'Toggle visibility of series ' + item.name);
888
+ });
889
+ // Focus first/last item
890
+ chart.highlightLegendItem(direction > 0 ? 0 : chart.legend.allItems.length - 1);
891
+ }
892
+ })
893
+ ];
894
+
895
+ // Init nav module index. We start at the first module, and as the user navigates through the chart the index will increase to use different handler modules.
896
+ chart.keyboardNavigationModuleIndex = 0;
897
+
898
+ // Make chart reachable by tab
899
+ if (
900
+ chart.container.hasAttribute &&
901
+ !chart.container.hasAttribute('tabIndex')
902
+ ) {
903
+ chart.container.setAttribute('tabindex', '0');
904
+ }
905
+
906
+ // Handle keyboard events
907
+ addEvent(chart.renderTo, 'keydown', keydownHandler);
908
+ addEvent(chart, 'destroy', function() {
909
+ removeEvent(chart.renderTo, 'keydown', keydownHandler);
910
+ });
911
+ };
912
+
913
+ // Add screen reader region to chart.
914
+ // tableId is the HTML id of the table to focus when clicking the table anchor in the screen reader region.
915
+ H.Chart.prototype.addScreenReaderRegion = function(id, tableId) {
916
+ var chart = this,
917
+ series = chart.series,
918
+ options = chart.options,
919
+ a11yOptions = options.accessibility,
920
+ hiddenSection = chart.screenReaderRegion = doc.createElement('div'),
921
+ tableShortcut = doc.createElement('h4'),
922
+ tableShortcutAnchor = doc.createElement('a'),
923
+ chartHeading = doc.createElement('h4'),
924
+ hiddenStyle = { // CSS style to hide element from visual users while still exposing it to screen readers
925
+ position: 'absolute',
926
+ left: '-9999px',
927
+ top: 'auto',
928
+ width: '1px',
929
+ height: '1px',
930
+ overflow: 'hidden'
931
+ },
932
+ chartTypes = chart.types || [],
933
+ // Build axis info - but not for pies and maps. Consider not adding for certain other types as well (funnel, pyramid?)
934
+ axesDesc = (chartTypes.length === 1 && chartTypes[0] === 'pie' || chartTypes[0] === 'map') && {} || chart.getAxesDescription(),
935
+ chartTypeInfo = series[0] && typeToSeriesMap[series[0].type] || typeToSeriesMap['default']; // eslint-disable-line dot-notation
936
+
937
+ hiddenSection.setAttribute('id', id);
938
+ hiddenSection.setAttribute('role', 'region');
939
+ hiddenSection.setAttribute('aria-label', 'Chart screen reader information.');
940
+
941
+ hiddenSection.innerHTML = a11yOptions.screenReaderSectionFormatter && a11yOptions.screenReaderSectionFormatter(chart) ||
942
+ '<div>Use regions/landmarks to skip ahead to chart' +
943
+ (series.length > 1 ? ' and navigate between data series' : '') +
944
+ '.</div><h3>' + (options.title.text ? htmlencode(options.title.text) : 'Chart') +
945
+ (options.subtitle && options.subtitle.text ? '. ' + htmlencode(options.subtitle.text) : '') +
946
+ '</h3><h4>Long description.</h4><div>' + (options.chart.description || 'No description available.') +
947
+ '</div><h4>Structure.</h4><div>Chart type: ' + (options.chart.typeDescription || chart.getTypeDescription()) + '</div>' +
948
+ (series.length === 1 ? '<div>' + chartTypeInfo[0] + ' with ' + series[0].points.length + ' ' +
949
+ (series[0].points.length === 1 ? chartTypeInfo[1] : chartTypeInfo[2]) + '.</div>' : '') +
950
+ (axesDesc.xAxis ? ('<div>' + axesDesc.xAxis + '</div>') : '') +
951
+ (axesDesc.yAxis ? ('<div>' + axesDesc.yAxis + '</div>') : '');
952
+
953
+ // Add shortcut to data table if export-data is loaded
954
+ if (chart.getCSV) {
955
+ tableShortcutAnchor.innerHTML = 'View as data table.';
956
+ tableShortcutAnchor.href = '#' + tableId;
957
+ tableShortcutAnchor.setAttribute('tabindex', '-1'); // Make this unreachable by user tabbing
958
+ tableShortcutAnchor.onclick = a11yOptions.onTableAnchorClick || function() {
959
+ chart.viewData();
960
+ doc.getElementById(tableId).focus();
961
+ };
962
+ tableShortcut.appendChild(tableShortcutAnchor);
963
+ hiddenSection.appendChild(tableShortcut);
964
+ }
965
+
966
+ // Note: JAWS seems to refuse to read aria-label on the container, so add an
967
+ // h4 element as title for the chart.
968
+ chartHeading.innerHTML = 'Chart graphic.';
969
+ chart.renderTo.insertBefore(chartHeading, chart.renderTo.firstChild);
970
+ chart.renderTo.insertBefore(hiddenSection, chart.renderTo.firstChild);
971
+
972
+ // Hide the section and the chart heading
973
+ merge(true, chartHeading.style, hiddenStyle);
974
+ merge(true, hiddenSection.style, hiddenStyle);
975
+ };
976
+
977
+
978
+ // Make chart container accessible, and wrap table functionality
979
+ H.Chart.prototype.callbacks.push(function(chart) {
980
+ var options = chart.options,
981
+ a11yOptions = options.accessibility;
982
+
983
+ if (!a11yOptions.enabled) {
984
+ return;
985
+ }
986
+
987
+ var titleElement = doc.createElementNS('http://www.w3.org/2000/svg', 'title'),
988
+ exportGroupElement = doc.createElementNS('http://www.w3.org/2000/svg', 'g'),
989
+ descElement = chart.container.getElementsByTagName('desc')[0],
990
+ textElements = chart.container.getElementsByTagName('text'),
991
+ titleId = 'highcharts-title-' + chart.index,
992
+ tableId = 'highcharts-data-table-' + chart.index,
993
+ hiddenSectionId = 'highcharts-information-region-' + chart.index,
994
+ chartTitle = options.title.text || 'Chart',
995
+ oldColumnHeaderFormatter = options.exporting && options.exporting.csv && options.exporting.csv.columnHeaderFormatter,
996
+ topLevelColumns = [];
997
+
998
+ // Add SVG title/desc tags
999
+ titleElement.textContent = htmlencode(chartTitle);
1000
+ titleElement.id = titleId;
1001
+ descElement.parentNode.insertBefore(titleElement, descElement);
1002
+ chart.renderTo.setAttribute('role', 'region');
1003
+ chart.container.setAttribute('aria-details', hiddenSectionId);
1004
+ chart.renderTo.setAttribute('aria-label', 'Interactive chart. ' + chartTitle +
1005
+ '. Use up and down arrows to navigate with most screen readers.');
1006
+
1007
+ // Set screen reader properties on export menu
1008
+ if (chart.exportSVGElements && chart.exportSVGElements[0] && chart.exportSVGElements[0].element) {
1009
+ var oldExportCallback = chart.exportSVGElements[0].element.onclick,
1010
+ parent = chart.exportSVGElements[0].element.parentNode;
1011
+ chart.exportSVGElements[0].element.onclick = function() {
1012
+ oldExportCallback.apply(this, Array.prototype.slice.call(arguments));
1013
+ chart.addAccessibleContextMenuAttribs();
1014
+ chart.highlightExportItem(0);
1015
+ };
1016
+ chart.exportSVGElements[0].element.setAttribute('role', 'button');
1017
+ chart.exportSVGElements[0].element.setAttribute('aria-label', 'View export menu');
1018
+ exportGroupElement.appendChild(chart.exportSVGElements[0].element);
1019
+ exportGroupElement.setAttribute('role', 'region');
1020
+ exportGroupElement.setAttribute('aria-label', 'Chart export menu');
1021
+ parent.appendChild(exportGroupElement);
1022
+ }
1023
+
1024
+ // Set screen reader properties on input boxes for range selector. We need to do this regardless of whether or not these are visible, as they are
1025
+ // by default part of the page's tabindex unless we set them to -1.
1026
+ if (chart.rangeSelector) {
1027
+ each(['minInput', 'maxInput'], function(key, i) {
1028
+ if (chart.rangeSelector[key]) {
1029
+ chart.rangeSelector[key].setAttribute('tabindex', '-1');
1030
+ chart.rangeSelector[key].setAttribute('role', 'textbox');
1031
+ chart.rangeSelector[key].setAttribute('aria-label', 'Select ' + (i ? 'end' : 'start') + ' date.');
1032
+ }
1033
+ });
1034
+ }
1035
+
1036
+ // Hide text elements from screen readers
1037
+ each(textElements, function(el) {
1038
+ el.setAttribute('aria-hidden', 'true');
1039
+ });
1040
+
1041
+ // Add top-secret screen reader region
1042
+ chart.addScreenReaderRegion(hiddenSectionId, tableId);
1043
+
1044
+ // Enable keyboard navigation
1045
+ if (a11yOptions.keyboardNavigation.enabled) {
1046
+ chart.addKeyboardNavEvents();
1047
+ }
1048
+
1049
+ /* Wrap table functionality from export-data */
1050
+
1051
+ // Keep track of columns
1052
+ merge(true, options.exporting, {
1053
+ csv: {
1054
+ columnHeaderFormatter: function(item, key, keyLength) {
1055
+ if (!item) {
1056
+ return 'Category';
1057
+ }
1058
+ if (item instanceof H.Axis) {
1059
+ return (item.options.title && item.options.title.text) ||
1060
+ (item.isDatetimeAxis ? 'DateTime' : 'Category');
1061
+ }
1062
+ var prevCol = topLevelColumns[topLevelColumns.length - 1];
1063
+ if (keyLength > 1) {
1064
+ // We need multiple levels of column headers
1065
+ // Populate a list of column headers to add in addition to the ones added by export-data
1066
+ if ((prevCol && prevCol.text) !== item.name) {
1067
+ topLevelColumns.push({
1068
+ text: item.name,
1069
+ span: keyLength
1070
+ });
1071
+ }
1072
+ }
1073
+ if (oldColumnHeaderFormatter) {
1074
+ return oldColumnHeaderFormatter.call(this, item, key, keyLength);
1075
+ }
1076
+ return keyLength > 1 ? key : item.name;
1077
+ }
1078
+ }
1079
+ });
1080
+
1081
+ // Add ID and title/caption to table HTML
1082
+ H.wrap(chart, 'getTable', function(proceed) {
1083
+ return proceed.apply(this, Array.prototype.slice.call(arguments, 1))
1084
+ .replace('<table>', '<table id="' + tableId + '" summary="Table representation of chart"><caption>' + chartTitle + '</caption>');
1085
+ });
1086
+
1087
+ // Add accessibility attributes and top level columns
1088
+ H.wrap(chart, 'viewData', function(proceed) {
1089
+ if (!this.insertedTable) {
1090
+ proceed.apply(this, Array.prototype.slice.call(arguments, 1));
1091
+
1092
+ var table = doc.getElementById(tableId),
1093
+ head = table.getElementsByTagName('thead')[0],
1094
+ body = table.getElementsByTagName('tbody')[0],
1095
+ firstRow = head.firstChild.children,
1096
+ columnHeaderRow = '<tr><td></td>',
1097
+ cell,
1098
+ newCell;
1099
+
1100
+ // Make table focusable by script
1101
+ table.setAttribute('tabindex', '-1');
1102
+
1103
+ // Create row headers
1104
+ each(body.children, function(el) {
1105
+ cell = el.firstChild;
1106
+ newCell = doc.createElement('th');
1107
+ newCell.setAttribute('scope', 'row');
1108
+ newCell.innerHTML = cell.innerHTML;
1109
+ cell.parentNode.replaceChild(newCell, cell);
1110
+ });
1111
+
1112
+ // Set scope for column headers
1113
+ each(firstRow, function(el) {
1114
+ if (el.tagName === 'TH') {
1115
+ el.setAttribute('scope', 'col');
1116
+ }
1117
+ });
1118
+
1119
+ // Add top level columns
1120
+ if (topLevelColumns.length) {
1121
+ each(topLevelColumns, function(col) {
1122
+ columnHeaderRow += '<th scope="col" colspan="' + col.span + '">' + col.text + '</th>';
1123
+ });
1124
+ head.insertAdjacentHTML('afterbegin', columnHeaderRow);
1125
+ }
1126
+ }
1127
+ });
1128
+ });
1129
+
1130
+ }(Highcharts));
1131
+ }));