highcharts 9.3.1 → 10.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (862) hide show
  1. package/bower.json +1 -1
  2. package/css/annotations/popup.css +1 -1
  3. package/css/highcharts.css +21 -4
  4. package/css/highcharts.scss +18 -3
  5. package/css/stocktools/gui.css +1 -1
  6. package/css/themes/dark-unica.css +21 -4
  7. package/css/themes/grid-light.css +21 -4
  8. package/css/themes/sand-signika.css +21 -4
  9. package/es-modules/Accessibility/A11yI18n.js +1 -5
  10. package/es-modules/Accessibility/Accessibility.js +12 -6
  11. package/es-modules/Accessibility/AccessibilityComponent.js +1 -1
  12. package/es-modules/Accessibility/Components/AnnotationsA11y.js +9 -5
  13. package/es-modules/Accessibility/Components/ContainerComponent.js +1 -1
  14. package/es-modules/Accessibility/Components/InfoRegionsComponent.js +8 -19
  15. package/es-modules/Accessibility/Components/LegendComponent.js +196 -98
  16. package/es-modules/Accessibility/Components/MenuComponent.js +16 -15
  17. package/es-modules/Accessibility/Components/RangeSelectorComponent.js +11 -14
  18. package/es-modules/Accessibility/Components/SeriesComponent/ForcedMarkers.js +22 -12
  19. package/es-modules/Accessibility/Components/SeriesComponent/NewDataAnnouncer.js +9 -5
  20. package/es-modules/Accessibility/Components/SeriesComponent/SeriesComponent.js +3 -2
  21. package/es-modules/Accessibility/Components/SeriesComponent/SeriesDescriber.js +19 -44
  22. package/es-modules/Accessibility/Components/SeriesComponent/SeriesKeyboardNavigation.js +77 -56
  23. package/es-modules/Accessibility/Components/ZoomComponent.js +148 -67
  24. package/es-modules/Accessibility/FocusBorder.js +0 -5
  25. package/es-modules/Accessibility/HighContrastMode.js +4 -3
  26. package/es-modules/Accessibility/KeyboardNavigation.js +117 -101
  27. package/es-modules/Accessibility/Options/DeprecatedOptions.js +12 -5
  28. package/es-modules/Accessibility/Options/LangOptions.js +3 -3
  29. package/es-modules/Accessibility/ProxyElement.js +26 -12
  30. package/es-modules/Accessibility/ProxyProvider.js +10 -5
  31. package/es-modules/Accessibility/Utils/Announcer.js +2 -2
  32. package/es-modules/Accessibility/Utils/ChartUtilities.js +17 -32
  33. package/es-modules/Accessibility/Utils/HTMLUtilities.js +0 -12
  34. package/es-modules/Core/Animation/Fx.js +5 -14
  35. package/es-modules/Core/Axis/Axis.js +189 -111
  36. package/es-modules/Core/Axis/Axis3D.js +10 -4
  37. package/es-modules/Core/Axis/BrokenAxis.js +17 -11
  38. package/es-modules/Core/Axis/Color/ColorAxis.js +28 -8
  39. package/es-modules/Core/Axis/Color/ColorAxisComposition.js +3 -3
  40. package/es-modules/Core/Axis/DateTimeAxis.js +3 -14
  41. package/es-modules/Core/Axis/GridAxis.js +34 -23
  42. package/es-modules/Core/Axis/NavigatorAxis.js +0 -5
  43. package/es-modules/Core/Axis/OrdinalAxis.js +83 -79
  44. package/es-modules/Core/Axis/PlotLineOrBand/PlotLineOrBandAxis.js +0 -5
  45. package/es-modules/Core/Axis/RadialAxis.js +7 -28
  46. package/es-modules/Core/Axis/ScrollbarAxis.js +18 -10
  47. package/es-modules/Core/Axis/StackingAxis.js +2 -1
  48. package/es-modules/Core/Axis/Tick.js +2 -4
  49. package/es-modules/Core/Axis/TreeGridAxis.js +26 -17
  50. package/es-modules/Core/Axis/TreeGridTick.js +15 -1
  51. package/es-modules/Core/Axis/WaterfallAxis.js +1 -1
  52. package/es-modules/Core/Axis/ZAxis.js +1 -1
  53. package/es-modules/Core/Chart/Chart.js +42 -44
  54. package/es-modules/Core/Chart/Chart3D.js +24 -21
  55. package/es-modules/Core/Chart/ChartDefaults.js +32 -11
  56. package/es-modules/Core/Chart/GanttChart.js +4 -4
  57. package/es-modules/Core/Chart/MapChart.js +4 -9
  58. package/es-modules/Core/Chart/StockChart.js +10 -23
  59. package/es-modules/Core/DefaultOptions.js +5 -2
  60. package/es-modules/Core/Geometry/CircleUtilities.js +2 -1
  61. package/es-modules/Core/Geometry/PolygonClip.js +84 -0
  62. package/es-modules/Core/Globals.js +4 -18
  63. package/es-modules/Core/HttpUtilities.js +18 -12
  64. package/es-modules/Core/Legend/Legend.js +22 -21
  65. package/es-modules/Core/Navigator.js +43 -28
  66. package/es-modules/Core/Pointer.js +28 -20
  67. package/es-modules/Core/Renderer/HTML/AST.js +88 -18
  68. package/es-modules/Core/Renderer/HTML/HTMLElement.js +4 -2
  69. package/es-modules/Core/Renderer/HTML/HTMLRenderer.js +8 -6
  70. package/es-modules/Core/Renderer/RendererUtilities.js +2 -2
  71. package/es-modules/Core/Renderer/SVG/SVGElement.js +33 -57
  72. package/es-modules/Core/Renderer/SVG/SVGElement3D.js +17 -5
  73. package/es-modules/Core/Renderer/SVG/SVGLabel.js +17 -8
  74. package/es-modules/Core/Renderer/SVG/SVGRenderer.js +21 -28
  75. package/es-modules/Core/Renderer/SVG/SVGRenderer3D.js +12 -5
  76. package/es-modules/Core/Renderer/SVG/TextBuilder.js +25 -17
  77. package/es-modules/Core/Responsive.js +2 -3
  78. package/es-modules/Core/Scrollbar.js +14 -12
  79. package/es-modules/Core/Series/DataLabel.js +26 -13
  80. package/es-modules/Core/Series/Point.js +19 -18
  81. package/es-modules/Core/Series/Series.js +77 -88
  82. package/es-modules/Core/Series/SeriesDefaults.js +9 -5
  83. package/es-modules/Core/Time.js +14 -11
  84. package/es-modules/Core/Tooltip.js +30 -64
  85. package/es-modules/Core/Utilities.js +33 -45
  86. package/es-modules/Data/DataConverter.js +0 -6
  87. package/es-modules/Data/DataSeriesConverter.js +9 -5
  88. package/es-modules/Data/DataTable.js +2 -1
  89. package/es-modules/Data/Modifiers/DataModifier.js +1 -1
  90. package/es-modules/Data/Parsers/CSVParser.js +3 -2
  91. package/es-modules/Data/Parsers/GoogleSheetsParser.js +5 -2
  92. package/es-modules/Data/Stores/CSVStore.js +2 -2
  93. package/es-modules/Data/Stores/DataStore.js +1 -1
  94. package/es-modules/Data/Stores/GoogleSheetsStore.js +3 -1
  95. package/es-modules/Data/Stores/HTMLTableStore.js +3 -1
  96. package/es-modules/Extensions/Annotations/Annotations.js +18 -10
  97. package/es-modules/Extensions/Annotations/ControlPoint.js +0 -2
  98. package/es-modules/Extensions/Annotations/Controllables/ControllableCircle.js +1 -1
  99. package/es-modules/Extensions/Annotations/Controllables/ControllableEllipse.js +1 -1
  100. package/es-modules/Extensions/Annotations/Controllables/ControllableImage.js +1 -1
  101. package/es-modules/Extensions/Annotations/Controllables/ControllableLabel.js +3 -6
  102. package/es-modules/Extensions/Annotations/Controllables/ControllablePath.js +3 -2
  103. package/es-modules/Extensions/Annotations/Controllables/ControllableRect.js +1 -1
  104. package/es-modules/Extensions/Annotations/Mixins/ControllableMixin.js +6 -3
  105. package/es-modules/Extensions/Annotations/Mixins/EventEmitterMixin.js +0 -1
  106. package/es-modules/Extensions/Annotations/Mixins/MarkerMixin.js +5 -4
  107. package/es-modules/Extensions/Annotations/MockPoint.js +1 -1
  108. package/es-modules/Extensions/Annotations/NavigationBindings.js +34 -29
  109. package/es-modules/Extensions/Annotations/Popup.js +40 -32
  110. package/es-modules/Extensions/Annotations/Types/BasicAnnotation.js +5 -3
  111. package/es-modules/Extensions/Annotations/Types/CrookedLine.js +4 -2
  112. package/es-modules/Extensions/Annotations/Types/ElliottWave.js +1 -1
  113. package/es-modules/Extensions/Annotations/Types/Measure.js +15 -11
  114. package/es-modules/Extensions/Annotations/Types/Pitchfork.js +2 -1
  115. package/es-modules/Extensions/Annotations/Types/TimeCycles.js +8 -4
  116. package/es-modules/Extensions/Annotations/Types/Tunnel.js +10 -5
  117. package/es-modules/Extensions/Boost/BoostInit.js +6 -1
  118. package/es-modules/Extensions/Boost/BoostOptions.js +26 -0
  119. package/es-modules/Extensions/Boost/BoostOverrides.js +3 -9
  120. package/es-modules/Extensions/Boost/BoostUtils.js +0 -6
  121. package/es-modules/Extensions/Boost/Boostables.js +1 -0
  122. package/es-modules/Extensions/Boost/WGLRenderer.js +64 -49
  123. package/es-modules/Extensions/Boost/WGLShader.js +13 -11
  124. package/es-modules/Extensions/Boost/WGLVBuffer.js +4 -7
  125. package/es-modules/Extensions/Breadcrumbs.js +874 -0
  126. package/es-modules/Extensions/Data.js +30 -62
  127. package/es-modules/Extensions/DataGrouping.js +27 -17
  128. package/es-modules/Extensions/DraggablePoints.js +16 -15
  129. package/es-modules/Extensions/Drilldown.js +148 -90
  130. package/es-modules/Extensions/ExportData.js +6 -5
  131. package/es-modules/Extensions/Exporting/Exporting.js +32 -44
  132. package/es-modules/Extensions/Exporting/ExportingDefaults.js +49 -1
  133. package/es-modules/Extensions/FullScreen.js +4 -3
  134. package/es-modules/Extensions/GeoJSON.js +152 -127
  135. package/es-modules/Extensions/MarkerClusters.js +37 -21
  136. package/es-modules/Extensions/Math3D.js +4 -4
  137. package/es-modules/Extensions/OfflineExporting/OfflineExporting.js +133 -46
  138. package/es-modules/Extensions/OfflineExporting/OfflineExportingDefaults.js +1 -1
  139. package/es-modules/Extensions/Oldie/Oldie.js +13 -77
  140. package/es-modules/Extensions/Oldie/VMLAxis3D.js +5 -1
  141. package/es-modules/Extensions/OverlappingDataLabels.js +10 -6
  142. package/es-modules/Extensions/Pane.js +6 -6
  143. package/es-modules/Extensions/ParallelCoordinates.js +5 -3
  144. package/es-modules/Extensions/PatternFill.js +17 -11
  145. package/es-modules/Extensions/Polar.js +6 -3
  146. package/es-modules/Extensions/PriceIndication.js +2 -1
  147. package/es-modules/Extensions/RangeSelector.js +19 -55
  148. package/es-modules/Extensions/ScrollablePlotArea.js +7 -3
  149. package/es-modules/Extensions/SeriesLabel.js +1 -1
  150. package/es-modules/Extensions/Sonification/ChartSonify.js +32 -26
  151. package/es-modules/Extensions/Sonification/Instrument.js +12 -15
  152. package/es-modules/Extensions/Sonification/PointSonify.js +12 -8
  153. package/es-modules/Extensions/Sonification/SeriesSonify.js +33 -18
  154. package/es-modules/Extensions/Sonification/SignalHandler.js +4 -6
  155. package/es-modules/Extensions/Sonification/Sonification.js +1 -1
  156. package/es-modules/Extensions/Sonification/SonificationUtilities.js +11 -7
  157. package/es-modules/Extensions/Sonification/Timeline.js +2 -7
  158. package/es-modules/Extensions/Sonification/TimelineEvent.js +0 -1
  159. package/es-modules/Extensions/Sonification/TimelinePath.js +8 -8
  160. package/es-modules/Extensions/Stacking.js +8 -25
  161. package/es-modules/Extensions/Themes/BrandDark.js +293 -0
  162. package/es-modules/Extensions/Themes/BrandLight.js +259 -0
  163. package/es-modules/Extensions/Themes/DarkUnica.js +4 -2
  164. package/es-modules/Extensions/Themes/Grid.js +4 -2
  165. package/es-modules/Extensions/Themes/GridLight.js +4 -2
  166. package/es-modules/Extensions/Themes/HighContrastDark.js +10 -10
  167. package/es-modules/Extensions/Themes/HighContrastLight.js +10 -10
  168. package/es-modules/Gantt/Connection.js +2 -2
  169. package/es-modules/Gantt/Pathfinder.js +6 -5
  170. package/es-modules/Gantt/PathfinderAlgorithms.js +12 -12
  171. package/es-modules/Maps/MapNavigation.js +54 -14
  172. package/es-modules/Maps/MapPointer.js +18 -1
  173. package/es-modules/Maps/MapSymbols.js +23 -3
  174. package/es-modules/Maps/MapUtilities.js +56 -0
  175. package/es-modules/Maps/MapView.js +606 -135
  176. package/es-modules/Maps/MapViewInsetsOptionsDefault.js +148 -0
  177. package/es-modules/Maps/MapViewOptionsDefault.js +58 -20
  178. package/es-modules/Maps/Projection.js +169 -77
  179. package/es-modules/Maps/Projections/EqualEarth.js +15 -6
  180. package/es-modules/Maps/Projections/LambertConformalConic.js +27 -19
  181. package/es-modules/Maps/Projections/Miller.js +23 -10
  182. package/es-modules/Maps/Projections/Orthographic.js +21 -10
  183. package/es-modules/Maps/Projections/WebMercator.js +25 -13
  184. package/es-modules/Series/ArcDiagram/ArcDiagramPoint.js +77 -0
  185. package/es-modules/Series/ArcDiagram/ArcDiagramSeries.js +581 -0
  186. package/es-modules/Series/Area/AreaSeries.js +13 -13
  187. package/es-modules/Series/Area3DSeries.js +4 -2
  188. package/es-modules/Series/AreaRange/AreaRangeSeries.js +24 -12
  189. package/es-modules/Series/Bellcurve/BellcurveSeries.js +2 -1
  190. package/es-modules/Series/Bubble/BubbleLegendItem.js +2 -12
  191. package/es-modules/Series/Candlestick/CandlestickSeries.js +0 -1
  192. package/es-modules/Series/ColorMapMixin.js +84 -0
  193. package/es-modules/Series/Column/ColumnSeries.js +20 -17
  194. package/es-modules/Series/Column3D/Column3DComposition.js +1 -2
  195. package/es-modules/Series/ColumnPyramid/ColumnPyramidSeries.js +5 -2
  196. package/es-modules/Series/ColumnRange/ColumnRangeSeries.js +2 -1
  197. package/es-modules/Series/Cylinder/CylinderComposition.js +36 -4
  198. package/es-modules/Series/DataModifyComposition.js +1 -0
  199. package/es-modules/Series/DependencyWheel/DependencyWheelSeries.js +3 -3
  200. package/es-modules/Series/DrawPointComposition.js +7 -4
  201. package/es-modules/Series/Dumbbell/DumbbellPoint.js +0 -1
  202. package/es-modules/Series/Dumbbell/DumbbellSeries.js +0 -3
  203. package/es-modules/Series/Flags/FlagsSymbols.js +2 -2
  204. package/es-modules/Series/Funnel3D/Funnel3DComposition.js +14 -8
  205. package/es-modules/Series/Funnel3D/Funnel3DSeries.js +2 -1
  206. package/es-modules/Series/Gantt/GanttPoint.js +1 -1
  207. package/es-modules/Series/Gantt/GanttSeries.js +3 -1
  208. package/es-modules/Series/HLC/HLCSeries.js +1 -6
  209. package/es-modules/Series/Heatmap/HeatmapPoint.js +10 -10
  210. package/es-modules/Series/Heatmap/HeatmapSeries.js +9 -10
  211. package/es-modules/Series/HeikinAshi/HeikinAshiSeries.js +8 -6
  212. package/es-modules/Series/Histogram/HistogramSeries.js +4 -4
  213. package/es-modules/Series/HollowCandlestick/HollowCandlestickPoint.js +1 -4
  214. package/es-modules/Series/HollowCandlestick/HollowCandlestickSeries.js +19 -20
  215. package/es-modules/Series/Item/ItemSeries.js +4 -5
  216. package/es-modules/Series/Lollipop/LollipopSeries.js +1 -1
  217. package/es-modules/Series/Map/MapPoint.js +30 -1
  218. package/es-modules/Series/Map/MapSeries.js +216 -190
  219. package/es-modules/Series/MapBubble/MapBubblePoint.js +16 -24
  220. package/es-modules/Series/MapBubble/MapBubbleSeries.js +11 -0
  221. package/es-modules/Series/MapLine/MapLineSeries.js +0 -4
  222. package/es-modules/Series/MapPoint/MapPointPoint.js +2 -8
  223. package/es-modules/Series/MapPoint/MapPointSeries.js +36 -14
  224. package/es-modules/Series/Networkgraph/DraggableNodes.js +0 -4
  225. package/es-modules/Series/Networkgraph/Integrations.js +8 -22
  226. package/es-modules/Series/Networkgraph/Networkgraph.js +1 -5
  227. package/es-modules/Series/Networkgraph/QuadTree.js +1 -3
  228. package/es-modules/Series/NodesComposition.js +60 -12
  229. package/es-modules/Series/OHLC/OHLCPoint.js +0 -1
  230. package/es-modules/Series/OHLC/OHLCSeries.js +8 -1
  231. package/es-modules/Series/Organization/OrganizationPoint.js +68 -2
  232. package/es-modules/Series/Organization/OrganizationSeries.js +81 -25
  233. package/es-modules/Series/PackedBubble/PackedBubbleComposition.js +1 -0
  234. package/es-modules/Series/PackedBubble/PackedBubblePoint.js +1 -1
  235. package/es-modules/Series/PackedBubble/PackedBubbleSeries.js +2 -4
  236. package/es-modules/Series/Pie/PiePoint.js +14 -7
  237. package/es-modules/Series/Pie/PieSeries.js +1 -1
  238. package/es-modules/Series/Pie3D/Pie3DComposition.js +2 -1
  239. package/es-modules/Series/Pie3D/Pie3DPoint.js +2 -1
  240. package/es-modules/Series/Pie3D/Pie3DSeries.js +20 -1
  241. package/es-modules/Series/Pyramid3D/Pyramid3DSeries.js +2 -1
  242. package/es-modules/Series/Sankey/SankeyColumnComposition.js +193 -0
  243. package/es-modules/Series/Sankey/SankeyPoint.js +37 -1
  244. package/es-modules/Series/Sankey/SankeySeries.js +10 -126
  245. package/es-modules/Series/Scatter/ScatterSeries.js +1 -1
  246. package/es-modules/Series/SolidGauge/SolidGaugeComposition.js +3 -1
  247. package/es-modules/Series/Spline/SplineSeries.js +0 -8
  248. package/es-modules/Series/Sunburst/SunburstSeries.js +15 -4
  249. package/es-modules/Series/Sunburst/SunburstUtilities.js +3 -2
  250. package/es-modules/Series/Tilemap/TilemapPoint.js +0 -2
  251. package/es-modules/Series/Tilemap/TilemapShapes.js +0 -7
  252. package/es-modules/Series/TreeUtilities.js +2 -2
  253. package/es-modules/Series/Treemap/TreemapSeries.js +104 -99
  254. package/es-modules/Series/Variwide/VariwideSeries.js +5 -1
  255. package/es-modules/Series/Venn/VennSeries.js +6 -9
  256. package/es-modules/Series/Venn/VennUtils.js +8 -7
  257. package/es-modules/Series/Waterfall/WaterfallSeries.js +8 -3
  258. package/es-modules/Series/Wordcloud/WordcloudSeries.js +2 -2
  259. package/es-modules/Series/Wordcloud/WordcloudUtils.js +6 -10
  260. package/es-modules/Series/XRange/XRangePoint.js +6 -12
  261. package/es-modules/Series/XRange/XRangeSeries.js +4 -20
  262. package/es-modules/Stock/Indicators/ABands/ABandsIndicator.js +12 -0
  263. package/es-modules/Stock/Indicators/Aroon/AroonIndicator.js +1 -0
  264. package/es-modules/Stock/Indicators/BB/BBIndicator.js +12 -0
  265. package/es-modules/Stock/Indicators/CMF/CMFIndicator.js +35 -15
  266. package/es-modules/Stock/Indicators/DMI/DMIIndicator.js +9 -5
  267. package/es-modules/Stock/Indicators/DisparityIndex/DisparityIndexIndicator.js +2 -1
  268. package/es-modules/Stock/Indicators/IKH/IKHIndicator.js +6 -6
  269. package/es-modules/Stock/Indicators/KeltnerChannels/KeltnerChannelsIndicator.js +12 -0
  270. package/es-modules/Stock/Indicators/Klinger/KlingerIndicator.js +8 -3
  271. package/es-modules/Stock/Indicators/LinearRegression/LinearRegression.js +30 -12
  272. package/es-modules/Stock/Indicators/MACD/MACDIndicator.js +1 -1
  273. package/es-modules/Stock/Indicators/MultipleLinesComposition.js +70 -6
  274. package/es-modules/Stock/Indicators/PC/PCIndicator.js +11 -0
  275. package/es-modules/Stock/Indicators/PivotPoints/PivotPointsIndicator.js +2 -1
  276. package/es-modules/Stock/Indicators/RSI/RSIIndicator.js +2 -1
  277. package/es-modules/Stock/Indicators/SMA/SMAIndicator.js +11 -5
  278. package/es-modules/Stock/Indicators/Stochastic/StochasticIndicator.js +3 -1
  279. package/es-modules/Stock/Indicators/VBP/VBPIndicator.js +3 -3
  280. package/es-modules/Stock/Indicators/VWAP/VWAPIndicator.js +19 -7
  281. package/es-modules/Stock/StockToolsBindings.js +13 -6
  282. package/es-modules/Stock/StockToolsGui.js +34 -23
  283. package/es-modules/masters/highcharts-3d.src.js +1 -1
  284. package/es-modules/masters/highcharts-gantt.src.js +1 -1
  285. package/es-modules/masters/highcharts-more.src.js +1 -1
  286. package/es-modules/masters/highcharts.src.js +1 -1
  287. package/es-modules/masters/highmaps.src.js +1 -1
  288. package/es-modules/masters/highstock.src.js +1 -1
  289. package/es-modules/masters/indicators/acceleration-bands.src.js +1 -1
  290. package/es-modules/masters/indicators/accumulation-distribution.src.js +1 -1
  291. package/es-modules/masters/indicators/ao.src.js +1 -1
  292. package/es-modules/masters/indicators/apo.src.js +1 -1
  293. package/es-modules/masters/indicators/aroon-oscillator.src.js +1 -1
  294. package/es-modules/masters/indicators/aroon.src.js +1 -1
  295. package/es-modules/masters/indicators/atr.src.js +1 -1
  296. package/es-modules/masters/indicators/bollinger-bands.src.js +1 -1
  297. package/es-modules/masters/indicators/cci.src.js +1 -1
  298. package/es-modules/masters/indicators/chaikin.src.js +1 -1
  299. package/es-modules/masters/indicators/cmf.src.js +1 -1
  300. package/es-modules/masters/indicators/cmo.src.js +1 -1
  301. package/es-modules/masters/indicators/dema.src.js +1 -1
  302. package/es-modules/masters/indicators/disparity-index.src.js +1 -1
  303. package/es-modules/masters/indicators/dmi.src.js +1 -1
  304. package/es-modules/masters/indicators/dpo.src.js +1 -1
  305. package/es-modules/masters/indicators/ichimoku-kinko-hyo.src.js +1 -1
  306. package/es-modules/masters/indicators/indicators-all.src.js +1 -1
  307. package/es-modules/masters/indicators/indicators.src.js +1 -1
  308. package/es-modules/masters/indicators/keltner-channels.src.js +1 -1
  309. package/es-modules/masters/indicators/klinger.src.js +1 -1
  310. package/es-modules/masters/indicators/macd.src.js +1 -1
  311. package/es-modules/masters/indicators/mfi.src.js +1 -1
  312. package/es-modules/masters/indicators/momentum.src.js +1 -1
  313. package/es-modules/masters/indicators/natr.src.js +1 -1
  314. package/es-modules/masters/indicators/obv.src.js +1 -1
  315. package/es-modules/masters/indicators/pivot-points.src.js +1 -1
  316. package/es-modules/masters/indicators/ppo.src.js +1 -1
  317. package/es-modules/masters/indicators/price-channel.src.js +1 -1
  318. package/es-modules/masters/indicators/price-envelopes.src.js +1 -1
  319. package/es-modules/masters/indicators/psar.src.js +1 -1
  320. package/es-modules/masters/indicators/regressions.src.js +1 -1
  321. package/es-modules/masters/indicators/roc.src.js +1 -1
  322. package/es-modules/masters/indicators/rsi.src.js +1 -1
  323. package/es-modules/masters/indicators/slow-stochastic.src.js +1 -1
  324. package/es-modules/masters/indicators/stochastic.src.js +1 -1
  325. package/es-modules/masters/indicators/supertrend.src.js +1 -1
  326. package/es-modules/masters/indicators/tema.src.js +1 -1
  327. package/es-modules/masters/indicators/trendline.src.js +1 -1
  328. package/es-modules/masters/indicators/trix.src.js +1 -1
  329. package/es-modules/masters/indicators/volume-by-price.src.js +1 -1
  330. package/es-modules/masters/indicators/vwap.src.js +1 -1
  331. package/es-modules/masters/indicators/williams-r.src.js +1 -1
  332. package/es-modules/masters/indicators/wma.src.js +1 -1
  333. package/es-modules/masters/indicators/zigzag.src.js +1 -1
  334. package/es-modules/masters/modules/accessibility.src.js +2 -2
  335. package/es-modules/masters/modules/annotations-advanced.src.js +1 -1
  336. package/es-modules/masters/modules/annotations.src.js +1 -1
  337. package/es-modules/masters/modules/arc-diagram.src.js +14 -0
  338. package/es-modules/masters/modules/arrow-symbols.src.js +1 -1
  339. package/es-modules/masters/modules/boost-canvas.src.js +1 -1
  340. package/es-modules/masters/modules/boost.src.js +1 -1
  341. package/es-modules/masters/modules/broken-axis.src.js +1 -1
  342. package/es-modules/masters/modules/bullet.src.js +1 -1
  343. package/es-modules/masters/modules/coloraxis.src.js +1 -1
  344. package/es-modules/masters/modules/current-date-indicator.src.js +1 -1
  345. package/es-modules/masters/modules/cylinder.src.js +1 -1
  346. package/es-modules/masters/modules/data.src.js +1 -1
  347. package/es-modules/masters/modules/datagrouping.src.js +1 -1
  348. package/es-modules/masters/modules/debugger.src.js +1 -1
  349. package/es-modules/masters/modules/dependency-wheel.src.js +1 -1
  350. package/es-modules/masters/modules/dotplot.src.js +1 -1
  351. package/es-modules/masters/modules/drag-panes.src.js +1 -1
  352. package/es-modules/masters/modules/draggable-points.src.js +1 -1
  353. package/es-modules/masters/modules/drilldown.src.js +2 -1
  354. package/es-modules/masters/modules/dumbbell.src.js +1 -1
  355. package/es-modules/masters/modules/export-data.src.js +1 -1
  356. package/es-modules/masters/modules/exporting.src.js +1 -1
  357. package/es-modules/masters/modules/full-screen.src.js +1 -1
  358. package/es-modules/masters/modules/funnel.src.js +1 -1
  359. package/es-modules/masters/modules/funnel3d.src.js +1 -1
  360. package/es-modules/masters/modules/gantt.src.js +1 -1
  361. package/es-modules/masters/modules/grid-axis.src.js +1 -1
  362. package/es-modules/masters/modules/heatmap.src.js +1 -1
  363. package/es-modules/masters/modules/heikinashi.src.js +1 -1
  364. package/es-modules/masters/modules/histogram-bellcurve.src.js +1 -1
  365. package/es-modules/masters/modules/hollowcandlestick.src.js +1 -1
  366. package/es-modules/masters/modules/item-series.src.js +1 -1
  367. package/es-modules/masters/modules/lollipop.src.js +1 -1
  368. package/es-modules/masters/modules/map.src.js +5 -1
  369. package/es-modules/masters/modules/marker-clusters.src.js +1 -1
  370. package/es-modules/masters/modules/networkgraph.src.js +1 -1
  371. package/es-modules/masters/modules/no-data-to-display.src.js +1 -1
  372. package/es-modules/masters/modules/offline-exporting.src.js +1 -1
  373. package/es-modules/masters/modules/oldie-polyfills.src.js +1 -1
  374. package/es-modules/masters/modules/oldie.src.js +1 -1
  375. package/es-modules/masters/modules/organization.src.js +1 -1
  376. package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
  377. package/es-modules/masters/modules/parallel-coordinates.src.js +1 -1
  378. package/es-modules/masters/modules/pareto.src.js +1 -1
  379. package/es-modules/masters/modules/pathfinder.src.js +1 -1
  380. package/es-modules/masters/modules/pattern-fill.src.js +1 -1
  381. package/es-modules/masters/modules/price-indicator.src.js +1 -1
  382. package/es-modules/masters/modules/pyramid3d.src.js +1 -1
  383. package/es-modules/masters/modules/sankey.src.js +1 -1
  384. package/es-modules/masters/modules/series-label.src.js +1 -1
  385. package/es-modules/masters/modules/solid-gauge.src.js +1 -1
  386. package/es-modules/masters/modules/sonification.src.js +1 -1
  387. package/es-modules/masters/modules/static-scale.src.js +1 -1
  388. package/es-modules/masters/modules/stock-tools.src.js +1 -1
  389. package/es-modules/masters/modules/stock.src.js +1 -1
  390. package/es-modules/masters/modules/streamgraph.src.js +1 -1
  391. package/es-modules/masters/modules/sunburst.src.js +1 -1
  392. package/es-modules/masters/modules/tilemap.src.js +1 -1
  393. package/es-modules/masters/modules/timeline.src.js +1 -1
  394. package/es-modules/masters/modules/treegrid.src.js +1 -1
  395. package/es-modules/masters/modules/treemap.src.js +5 -1
  396. package/es-modules/masters/modules/variable-pie.src.js +1 -1
  397. package/es-modules/masters/modules/variwide.src.js +1 -1
  398. package/es-modules/masters/modules/vector.src.js +1 -1
  399. package/es-modules/masters/modules/venn.src.js +1 -1
  400. package/es-modules/masters/modules/windbarb.src.js +1 -1
  401. package/es-modules/masters/modules/wordcloud.src.js +1 -1
  402. package/es-modules/masters/modules/xrange.src.js +1 -1
  403. package/es-modules/masters/themes/avocado.src.js +1 -1
  404. package/es-modules/masters/themes/brand-dark.src.js +14 -0
  405. package/es-modules/masters/themes/brand-light.src.js +14 -0
  406. package/es-modules/masters/themes/dark-blue.src.js +1 -1
  407. package/es-modules/masters/themes/dark-green.src.js +1 -1
  408. package/es-modules/masters/themes/dark-unica.src.js +1 -1
  409. package/es-modules/masters/themes/gray.src.js +1 -1
  410. package/es-modules/masters/themes/grid-light.src.js +1 -1
  411. package/es-modules/masters/themes/grid.src.js +1 -1
  412. package/es-modules/masters/themes/high-contrast-dark.src.js +1 -1
  413. package/es-modules/masters/themes/high-contrast-light.src.js +1 -1
  414. package/es-modules/masters/themes/sand-signika.src.js +1 -1
  415. package/es-modules/masters/themes/skies.src.js +1 -1
  416. package/es-modules/masters/themes/sunset.src.js +1 -1
  417. package/highcharts-3d.js +99 -98
  418. package/highcharts-3d.js.map +1 -1
  419. package/highcharts-3d.src.js +114 -54
  420. package/highcharts-gantt.js +805 -800
  421. package/highcharts-gantt.js.map +1 -1
  422. package/highcharts-gantt.src.js +1102 -973
  423. package/highcharts-more.js +195 -194
  424. package/highcharts-more.js.map +1 -1
  425. package/highcharts-more.src.js +85 -104
  426. package/highcharts.d.ts +8196 -2661
  427. package/highcharts.js +590 -585
  428. package/highcharts.js.map +1 -1
  429. package/highcharts.src.d.ts +8196 -2661
  430. package/highcharts.src.js +872 -745
  431. package/highmaps.js +757 -727
  432. package/highmaps.js.map +1 -1
  433. package/highmaps.src.js +3983 -2601
  434. package/highstock.js +792 -788
  435. package/highstock.js.map +1 -1
  436. package/highstock.src.js +1118 -1001
  437. package/indicators/acceleration-bands.d.ts +17 -1
  438. package/indicators/acceleration-bands.js +12 -10
  439. package/indicators/acceleration-bands.js.map +1 -1
  440. package/indicators/acceleration-bands.src.d.ts +17 -1
  441. package/indicators/acceleration-bands.src.js +98 -7
  442. package/indicators/accumulation-distribution.js +5 -5
  443. package/indicators/accumulation-distribution.js.map +1 -1
  444. package/indicators/accumulation-distribution.src.js +11 -2
  445. package/indicators/ao.js +6 -6
  446. package/indicators/ao.js.map +1 -1
  447. package/indicators/ao.src.js +11 -2
  448. package/indicators/apo.js +5 -5
  449. package/indicators/apo.js.map +1 -1
  450. package/indicators/apo.src.js +11 -2
  451. package/indicators/aroon-oscillator.d.ts +17 -1
  452. package/indicators/aroon-oscillator.js +10 -9
  453. package/indicators/aroon-oscillator.js.map +1 -1
  454. package/indicators/aroon-oscillator.src.d.ts +17 -1
  455. package/indicators/aroon-oscillator.src.js +86 -7
  456. package/indicators/aroon.d.ts +17 -1
  457. package/indicators/aroon.js +11 -9
  458. package/indicators/aroon.js.map +1 -1
  459. package/indicators/aroon.src.d.ts +17 -1
  460. package/indicators/aroon.src.js +87 -7
  461. package/indicators/atr.js +5 -5
  462. package/indicators/atr.js.map +1 -1
  463. package/indicators/atr.src.js +11 -2
  464. package/indicators/bollinger-bands.d.ts +17 -1
  465. package/indicators/bollinger-bands.js +12 -10
  466. package/indicators/bollinger-bands.js.map +1 -1
  467. package/indicators/bollinger-bands.src.d.ts +17 -1
  468. package/indicators/bollinger-bands.src.js +98 -7
  469. package/indicators/cci.js +5 -5
  470. package/indicators/cci.js.map +1 -1
  471. package/indicators/cci.src.js +11 -2
  472. package/indicators/chaikin.js +8 -8
  473. package/indicators/chaikin.js.map +1 -1
  474. package/indicators/chaikin.src.js +11 -2
  475. package/indicators/cmf.js +6 -6
  476. package/indicators/cmf.js.map +1 -1
  477. package/indicators/cmf.src.js +46 -17
  478. package/indicators/cmo.js +5 -5
  479. package/indicators/cmo.js.map +1 -1
  480. package/indicators/cmo.src.js +11 -2
  481. package/indicators/dema.js +5 -5
  482. package/indicators/dema.js.map +1 -1
  483. package/indicators/dema.src.js +11 -2
  484. package/indicators/disparity-index.js +6 -6
  485. package/indicators/disparity-index.js.map +1 -1
  486. package/indicators/disparity-index.src.js +13 -3
  487. package/indicators/dmi.js +12 -11
  488. package/indicators/dmi.js.map +1 -1
  489. package/indicators/dmi.src.js +95 -12
  490. package/indicators/dpo.js +5 -5
  491. package/indicators/dpo.js.map +1 -1
  492. package/indicators/dpo.src.js +11 -2
  493. package/indicators/ema.js +2 -1
  494. package/indicators/ema.js.map +1 -1
  495. package/indicators/ema.src.js +10 -1
  496. package/indicators/ichimoku-kinko-hyo.js +16 -16
  497. package/indicators/ichimoku-kinko-hyo.js.map +1 -1
  498. package/indicators/ichimoku-kinko-hyo.src.js +17 -8
  499. package/indicators/indicators-all.d.ts +17 -1
  500. package/indicators/indicators-all.js +199 -197
  501. package/indicators/indicators-all.js.map +1 -1
  502. package/indicators/indicators-all.src.d.ts +17 -1
  503. package/indicators/indicators-all.src.js +266 -69
  504. package/indicators/indicators.js +13 -12
  505. package/indicators/indicators.js.map +1 -1
  506. package/indicators/indicators.src.js +23 -8
  507. package/indicators/keltner-channels.d.ts +17 -1
  508. package/indicators/keltner-channels.js +12 -10
  509. package/indicators/keltner-channels.js.map +1 -1
  510. package/indicators/keltner-channels.src.d.ts +17 -1
  511. package/indicators/keltner-channels.src.js +98 -7
  512. package/indicators/klinger.js +14 -12
  513. package/indicators/klinger.js.map +1 -1
  514. package/indicators/klinger.src.js +94 -10
  515. package/indicators/macd.js +12 -11
  516. package/indicators/macd.js.map +1 -1
  517. package/indicators/macd.src.js +12 -3
  518. package/indicators/mfi.js +6 -6
  519. package/indicators/mfi.js.map +1 -1
  520. package/indicators/mfi.src.js +11 -2
  521. package/indicators/momentum.js +5 -5
  522. package/indicators/momentum.js.map +1 -1
  523. package/indicators/momentum.src.js +11 -2
  524. package/indicators/natr.js +5 -4
  525. package/indicators/natr.js.map +1 -1
  526. package/indicators/natr.src.js +11 -2
  527. package/indicators/obv.js +5 -5
  528. package/indicators/obv.js.map +1 -1
  529. package/indicators/obv.src.js +11 -2
  530. package/indicators/pivot-points.js +11 -11
  531. package/indicators/pivot-points.js.map +1 -1
  532. package/indicators/pivot-points.src.js +13 -3
  533. package/indicators/ppo.js +5 -5
  534. package/indicators/ppo.js.map +1 -1
  535. package/indicators/ppo.src.js +11 -2
  536. package/indicators/price-channel.d.ts +17 -1
  537. package/indicators/price-channel.js +11 -9
  538. package/indicators/price-channel.js.map +1 -1
  539. package/indicators/price-channel.src.d.ts +17 -1
  540. package/indicators/price-channel.src.js +97 -7
  541. package/indicators/price-envelopes.js +8 -8
  542. package/indicators/price-envelopes.js.map +1 -1
  543. package/indicators/price-envelopes.src.js +11 -2
  544. package/indicators/psar.js +7 -6
  545. package/indicators/psar.js.map +1 -1
  546. package/indicators/psar.src.js +11 -2
  547. package/indicators/regressions.js +12 -12
  548. package/indicators/regressions.js.map +1 -1
  549. package/indicators/regressions.src.js +41 -14
  550. package/indicators/roc.js +5 -5
  551. package/indicators/roc.js.map +1 -1
  552. package/indicators/roc.src.js +11 -2
  553. package/indicators/rsi.js +6 -5
  554. package/indicators/rsi.js.map +1 -1
  555. package/indicators/rsi.src.js +13 -3
  556. package/indicators/slow-stochastic.js +5 -5
  557. package/indicators/slow-stochastic.js.map +1 -1
  558. package/indicators/slow-stochastic.src.js +11 -2
  559. package/indicators/stochastic.d.ts +17 -1
  560. package/indicators/stochastic.js +12 -10
  561. package/indicators/stochastic.js.map +1 -1
  562. package/indicators/stochastic.src.d.ts +17 -1
  563. package/indicators/stochastic.src.js +89 -8
  564. package/indicators/supertrend.js +10 -10
  565. package/indicators/supertrend.js.map +1 -1
  566. package/indicators/supertrend.src.js +11 -2
  567. package/indicators/tema.js +6 -6
  568. package/indicators/tema.js.map +1 -1
  569. package/indicators/tema.src.js +11 -2
  570. package/indicators/trendline.js +5 -5
  571. package/indicators/trendline.js.map +1 -1
  572. package/indicators/trendline.src.js +11 -2
  573. package/indicators/trix.js +4 -4
  574. package/indicators/trix.js.map +1 -1
  575. package/indicators/trix.src.js +11 -2
  576. package/indicators/volume-by-price.js +17 -17
  577. package/indicators/volume-by-price.js.map +1 -1
  578. package/indicators/volume-by-price.src.js +14 -5
  579. package/indicators/vwap.js +5 -5
  580. package/indicators/vwap.js.map +1 -1
  581. package/indicators/vwap.src.js +30 -9
  582. package/indicators/williams-r.js +6 -5
  583. package/indicators/williams-r.js.map +1 -1
  584. package/indicators/williams-r.src.js +11 -2
  585. package/indicators/wma.js +5 -5
  586. package/indicators/wma.js.map +1 -1
  587. package/indicators/wma.src.js +11 -2
  588. package/indicators/zigzag.js +6 -6
  589. package/indicators/zigzag.js.map +1 -1
  590. package/indicators/zigzag.src.js +11 -2
  591. package/lib/jspdf.js +299 -184
  592. package/lib/jspdf.src.js +25266 -18067
  593. package/lib/svg2pdf.js +35 -31
  594. package/lib/svg2pdf.src.js +5721 -4179
  595. package/modules/accessibility.d.ts +0 -35
  596. package/modules/accessibility.js +232 -226
  597. package/modules/accessibility.js.map +1 -1
  598. package/modules/accessibility.src.d.ts +0 -35
  599. package/modules/accessibility.src.js +792 -613
  600. package/modules/annotations-advanced.js +175 -175
  601. package/modules/annotations-advanced.js.map +1 -1
  602. package/modules/annotations-advanced.src.js +175 -129
  603. package/modules/annotations.js +124 -124
  604. package/modules/annotations.js.map +1 -1
  605. package/modules/annotations.src.js +130 -102
  606. package/modules/arc-diagram.js +25 -0
  607. package/modules/arc-diagram.js.map +1 -0
  608. package/modules/arc-diagram.src.js +770 -0
  609. package/modules/arrow-symbols.js +4 -3
  610. package/modules/arrow-symbols.js.map +1 -1
  611. package/modules/arrow-symbols.src.js +11 -2
  612. package/modules/boost-canvas.js +15 -15
  613. package/modules/boost-canvas.js.map +1 -1
  614. package/modules/boost-canvas.src.js +11 -2
  615. package/modules/boost.js +80 -79
  616. package/modules/boost.js.map +1 -1
  617. package/modules/boost.src.js +103 -85
  618. package/modules/broken-axis.js +13 -13
  619. package/modules/broken-axis.js.map +1 -1
  620. package/modules/broken-axis.src.js +28 -13
  621. package/modules/bullet.js +9 -9
  622. package/modules/bullet.js.map +1 -1
  623. package/modules/bullet.src.js +11 -2
  624. package/modules/coloraxis.js +24 -24
  625. package/modules/coloraxis.js.map +1 -1
  626. package/modules/coloraxis.src.js +42 -13
  627. package/modules/current-date-indicator.js +5 -4
  628. package/modules/current-date-indicator.js.map +1 -1
  629. package/modules/current-date-indicator.src.js +11 -2
  630. package/modules/cylinder.js +11 -11
  631. package/modules/cylinder.js.map +1 -1
  632. package/modules/cylinder.src.js +47 -6
  633. package/modules/data.d.ts +6 -6
  634. package/modules/data.js +34 -33
  635. package/modules/data.js.map +1 -1
  636. package/modules/data.src.d.ts +6 -6
  637. package/modules/data.src.js +68 -84
  638. package/modules/datagrouping.js +21 -20
  639. package/modules/datagrouping.js.map +1 -1
  640. package/modules/datagrouping.src.js +38 -19
  641. package/modules/debugger.js +6 -6
  642. package/modules/debugger.js.map +1 -1
  643. package/modules/debugger.src.js +11 -2
  644. package/modules/dependency-wheel.js +12 -11
  645. package/modules/dependency-wheel.js.map +1 -1
  646. package/modules/dependency-wheel.src.js +15 -6
  647. package/modules/dotplot.js +6 -6
  648. package/modules/dotplot.js.map +1 -1
  649. package/modules/dotplot.src.js +11 -2
  650. package/modules/drag-panes.js +10 -10
  651. package/modules/drag-panes.js.map +1 -1
  652. package/modules/drag-panes.src.js +11 -2
  653. package/modules/draggable-points.js +35 -34
  654. package/modules/draggable-points.js.map +1 -1
  655. package/modules/draggable-points.src.js +27 -17
  656. package/modules/drilldown.d.ts +19 -0
  657. package/modules/drilldown.js +37 -25
  658. package/modules/drilldown.js.map +1 -1
  659. package/modules/drilldown.src.d.ts +19 -0
  660. package/modules/drilldown.src.js +1091 -101
  661. package/modules/dumbbell.js +17 -17
  662. package/modules/dumbbell.js.map +1 -1
  663. package/modules/dumbbell.src.js +11 -6
  664. package/modules/export-data.js +22 -21
  665. package/modules/export-data.js.map +1 -1
  666. package/modules/export-data.src.js +17 -7
  667. package/modules/exporting.js +39 -39
  668. package/modules/exporting.js.map +1 -1
  669. package/modules/exporting.src.js +114 -62
  670. package/modules/full-screen.js +8 -7
  671. package/modules/full-screen.js.map +1 -1
  672. package/modules/full-screen.src.js +15 -5
  673. package/modules/funnel.js +12 -12
  674. package/modules/funnel.js.map +1 -1
  675. package/modules/funnel.src.js +11 -2
  676. package/modules/funnel3d.js +21 -21
  677. package/modules/funnel3d.js.map +1 -1
  678. package/modules/funnel3d.src.js +27 -11
  679. package/modules/gantt.js +217 -217
  680. package/modules/gantt.js.map +1 -1
  681. package/modules/gantt.src.js +241 -230
  682. package/modules/grid-axis.js +23 -23
  683. package/modules/grid-axis.js.map +1 -1
  684. package/modules/grid-axis.src.js +46 -27
  685. package/modules/heatmap.js +40 -39
  686. package/modules/heatmap.js.map +1 -1
  687. package/modules/heatmap.src.js +119 -117
  688. package/modules/heikinashi.js +8 -8
  689. package/modules/heikinashi.js.map +1 -1
  690. package/modules/heikinashi.src.js +19 -8
  691. package/modules/histogram-bellcurve.js +13 -13
  692. package/modules/histogram-bellcurve.js.map +1 -1
  693. package/modules/histogram-bellcurve.src.js +17 -7
  694. package/modules/hollowcandlestick.js +9 -9
  695. package/modules/hollowcandlestick.js.map +1 -1
  696. package/modules/hollowcandlestick.src.js +31 -26
  697. package/modules/item-series.js +12 -12
  698. package/modules/item-series.js.map +1 -1
  699. package/modules/item-series.src.js +16 -7
  700. package/modules/lollipop.js +7 -7
  701. package/modules/lollipop.js.map +1 -1
  702. package/modules/lollipop.src.js +12 -3
  703. package/modules/map.d.ts +82 -43
  704. package/modules/map.js +169 -144
  705. package/modules/map.js.map +1 -1
  706. package/modules/map.src.d.ts +82 -43
  707. package/modules/map.src.js +8003 -6739
  708. package/modules/marker-clusters.js +36 -36
  709. package/modules/marker-clusters.js.map +1 -1
  710. package/modules/marker-clusters.src.js +50 -24
  711. package/modules/networkgraph.d.ts +5 -0
  712. package/modules/networkgraph.js +49 -48
  713. package/modules/networkgraph.js.map +1 -1
  714. package/modules/networkgraph.src.d.ts +5 -0
  715. package/modules/networkgraph.src.js +87 -48
  716. package/modules/no-data-to-display.js +5 -5
  717. package/modules/no-data-to-display.js.map +1 -1
  718. package/modules/no-data-to-display.src.js +11 -2
  719. package/modules/offline-exporting.js +20 -18
  720. package/modules/offline-exporting.js.map +1 -1
  721. package/modules/offline-exporting.src.js +149 -53
  722. package/modules/oldie-polyfills.js +7 -7
  723. package/modules/oldie-polyfills.js.map +1 -1
  724. package/modules/oldie-polyfills.src.js +11 -2
  725. package/modules/oldie.js +30 -30
  726. package/modules/oldie.js.map +1 -1
  727. package/modules/oldie.src.js +29 -80
  728. package/modules/organization.js +16 -14
  729. package/modules/organization.js.map +1 -1
  730. package/modules/organization.src.js +168 -32
  731. package/modules/overlapping-datalabels.js +3 -2
  732. package/modules/overlapping-datalabels.js.map +1 -1
  733. package/modules/overlapping-datalabels.src.js +11 -2
  734. package/modules/parallel-coordinates.js +11 -11
  735. package/modules/parallel-coordinates.js.map +1 -1
  736. package/modules/parallel-coordinates.src.js +16 -5
  737. package/modules/pareto.js +7 -7
  738. package/modules/pareto.js.map +1 -1
  739. package/modules/pareto.src.js +11 -2
  740. package/modules/pathfinder.js +31 -31
  741. package/modules/pathfinder.js.map +1 -1
  742. package/modules/pathfinder.src.js +31 -21
  743. package/modules/pattern-fill.js +14 -14
  744. package/modules/pattern-fill.js.map +1 -1
  745. package/modules/pattern-fill.src.js +28 -13
  746. package/modules/price-indicator.js +5 -5
  747. package/modules/price-indicator.js.map +1 -1
  748. package/modules/price-indicator.src.js +13 -3
  749. package/modules/pyramid3d.js +4 -4
  750. package/modules/pyramid3d.js.map +1 -1
  751. package/modules/pyramid3d.src.js +13 -3
  752. package/modules/sankey.d.ts +5 -0
  753. package/modules/sankey.js +32 -29
  754. package/modules/sankey.js.map +1 -1
  755. package/modules/sankey.src.d.ts +5 -0
  756. package/modules/sankey.src.js +340 -156
  757. package/modules/series-label.js +18 -17
  758. package/modules/series-label.js.map +1 -1
  759. package/modules/series-label.src.js +12 -3
  760. package/modules/solid-gauge.js +10 -10
  761. package/modules/solid-gauge.js.map +1 -1
  762. package/modules/solid-gauge.src.js +27 -3
  763. package/modules/sonification.js +59 -59
  764. package/modules/sonification.js.map +1 -1
  765. package/modules/sonification.src.js +131 -104
  766. package/modules/static-scale.js +5 -4
  767. package/modules/static-scale.js.map +1 -1
  768. package/modules/static-scale.src.js +11 -2
  769. package/modules/stock-tools.js +107 -107
  770. package/modules/stock-tools.js.map +1 -1
  771. package/modules/stock-tools.src.js +137 -98
  772. package/modules/stock.js +162 -162
  773. package/modules/stock.js.map +1 -1
  774. package/modules/stock.src.js +257 -258
  775. package/modules/streamgraph.js +5 -4
  776. package/modules/streamgraph.js.map +1 -1
  777. package/modules/streamgraph.src.js +11 -2
  778. package/modules/sunburst.d.ts +3 -0
  779. package/modules/sunburst.js +73 -61
  780. package/modules/sunburst.js.map +1 -1
  781. package/modules/sunburst.src.d.ts +3 -0
  782. package/modules/sunburst.src.js +1128 -205
  783. package/modules/tilemap.js +17 -17
  784. package/modules/tilemap.js.map +1 -1
  785. package/modules/tilemap.src.js +11 -11
  786. package/modules/timeline.js +18 -18
  787. package/modules/timeline.js.map +1 -1
  788. package/modules/timeline.src.js +11 -2
  789. package/modules/treegrid.js +57 -56
  790. package/modules/treegrid.js.map +1 -1
  791. package/modules/treegrid.src.js +106 -58
  792. package/modules/treemap.d.ts +3 -0
  793. package/modules/treemap.js +53 -41
  794. package/modules/treemap.js.map +1 -1
  795. package/modules/treemap.src.d.ts +3 -0
  796. package/modules/treemap.src.js +1113 -200
  797. package/modules/variable-pie.js +9 -9
  798. package/modules/variable-pie.js.map +1 -1
  799. package/modules/variable-pie.src.js +11 -2
  800. package/modules/variwide.js +12 -12
  801. package/modules/variwide.js.map +1 -1
  802. package/modules/variwide.src.js +17 -4
  803. package/modules/vector.js +8 -7
  804. package/modules/vector.js.map +1 -1
  805. package/modules/vector.src.js +11 -2
  806. package/modules/venn.js +31 -31
  807. package/modules/venn.js.map +1 -1
  808. package/modules/venn.src.js +34 -23
  809. package/modules/windbarb.js +15 -15
  810. package/modules/windbarb.js.map +1 -1
  811. package/modules/windbarb.src.js +11 -2
  812. package/modules/wordcloud.js +23 -23
  813. package/modules/wordcloud.js.map +1 -1
  814. package/modules/wordcloud.src.js +26 -18
  815. package/modules/xrange.js +16 -16
  816. package/modules/xrange.js.map +1 -1
  817. package/modules/xrange.src.js +21 -34
  818. package/package.json +1 -1
  819. package/themes/avocado.js +4 -3
  820. package/themes/avocado.js.map +1 -1
  821. package/themes/avocado.src.js +11 -2
  822. package/themes/brand-dark.js +16 -0
  823. package/themes/brand-dark.js.map +1 -0
  824. package/themes/brand-dark.src.js +337 -0
  825. package/themes/brand-light.js +15 -0
  826. package/themes/brand-light.js.map +1 -0
  827. package/themes/brand-light.src.js +303 -0
  828. package/themes/dark-blue.js +9 -8
  829. package/themes/dark-blue.js.map +1 -1
  830. package/themes/dark-blue.src.js +11 -2
  831. package/themes/dark-green.js +9 -8
  832. package/themes/dark-green.js.map +1 -1
  833. package/themes/dark-green.src.js +11 -2
  834. package/themes/dark-unica.js +8 -7
  835. package/themes/dark-unica.js.map +1 -1
  836. package/themes/dark-unica.src.js +15 -4
  837. package/themes/gray.js +9 -8
  838. package/themes/gray.js.map +1 -1
  839. package/themes/gray.src.js +11 -2
  840. package/themes/grid-light.js +5 -4
  841. package/themes/grid-light.js.map +1 -1
  842. package/themes/grid-light.src.js +15 -4
  843. package/themes/grid.js +5 -5
  844. package/themes/grid.js.map +1 -1
  845. package/themes/grid.src.js +15 -4
  846. package/themes/high-contrast-dark.js +7 -7
  847. package/themes/high-contrast-dark.js.map +1 -1
  848. package/themes/high-contrast-dark.src.js +21 -12
  849. package/themes/high-contrast-light.js +3 -3
  850. package/themes/high-contrast-light.js.map +1 -1
  851. package/themes/high-contrast-light.src.js +21 -12
  852. package/themes/sand-signika.js +5 -5
  853. package/themes/sand-signika.js.map +1 -1
  854. package/themes/sand-signika.src.js +11 -2
  855. package/themes/skies.js +5 -5
  856. package/themes/skies.js.map +1 -1
  857. package/themes/skies.src.js +11 -2
  858. package/themes/sunset.js +3 -3
  859. package/themes/sunset.js.map +1 -1
  860. package/themes/sunset.src.js +11 -2
  861. package/es-modules/Maps/ProjectionDefinition.js +0 -9
  862. package/es-modules/Series/ColorMapComposition.js +0 -109
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v9.3.1 (2021-11-05)
2
+ * @license Highcharts JS v10.0.0 (2022-03-07)
3
3
  *
4
4
  * Accessibility module
5
5
  *
@@ -8,7 +8,6 @@
8
8
  *
9
9
  * License: www.highcharts.com/license
10
10
  */
11
- 'use strict';
12
11
  (function (factory) {
13
12
  if (typeof module === 'object' && module.exports) {
14
13
  factory['default'] = factory;
@@ -23,10 +22,20 @@
23
22
  factory(typeof Highcharts !== 'undefined' ? Highcharts : undefined);
24
23
  }
25
24
  }(function (Highcharts) {
25
+ 'use strict';
26
26
  var _modules = Highcharts ? Highcharts._modules : {};
27
27
  function _registerModule(obj, path, args, fn) {
28
28
  if (!obj.hasOwnProperty(path)) {
29
29
  obj[path] = fn.apply(null, args);
30
+
31
+ if (typeof CustomEvent === 'function') {
32
+ window.dispatchEvent(
33
+ new CustomEvent(
34
+ 'HighchartsModuleLoaded',
35
+ { detail: { path: path, module: obj[path] }
36
+ })
37
+ );
38
+ }
30
39
  }
31
40
  }
32
41
  _registerModule(_modules, 'Accessibility/A11yI18n.js', [_modules['Core/FormatUtilities.js'], _modules['Core/Utilities.js']], function (F, U) {
@@ -88,13 +97,9 @@
88
97
  *
89
98
  * @private
90
99
  * @function formatExtendedStatement
91
- *
92
100
  * @param {string} statement
93
- *
94
101
  * @param {Highcharts.Dictionary<*>} ctx
95
102
  * Context to apply to the format string.
96
- *
97
- * @return {string}
98
103
  */
99
104
  function formatExtendedStatement(statement, ctx) {
100
105
  var eachStart = statement.indexOf('#each('), pluralStart = statement.indexOf('#plural('), indexStart = statement.indexOf('['), indexEnd = statement.indexOf(']');
@@ -121,7 +126,7 @@
121
126
  }
122
127
  // Dealing with a plural-function?
123
128
  if (pluralStart > -1) {
124
- var pluralEnd = statement.slice(pluralStart).indexOf(')') + pluralStart, pluralStatement = statement.substring(pluralStart + 8, pluralEnd), pluralArguments = pluralStatement.split(','), num = Number(ctx[pluralArguments[0]]);
129
+ var pluralEnd = (statement.slice(pluralStart).indexOf(')') + pluralStart), pluralStatement = statement.substring(pluralStart + 8, pluralEnd), pluralArguments = pluralStatement.split(','), num = Number(ctx[pluralArguments[0]]);
125
130
  switch (num) {
126
131
  case 0:
127
132
  result = pick(pluralArguments[4], pluralArguments[1]);
@@ -456,8 +461,6 @@
456
461
  }
457
462
  /**
458
463
  * @private
459
- * @param {string} str
460
- * @return {string}
461
464
  */
462
465
  function escapeStringForHTML(str) {
463
466
  return str
@@ -470,18 +473,14 @@
470
473
  }
471
474
  /**
472
475
  * Get an element by ID
473
- * @param {string} id
474
476
  * @private
475
- * @return {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement|null}
476
477
  */
477
478
  function getElement(id) {
478
479
  return doc.getElementById(id);
479
480
  }
480
481
  /**
481
482
  * Get a fake mouse event of a given type
482
- * @param {string} type
483
483
  * @private
484
- * @return {global.MouseEvent}
485
484
  */
486
485
  function getFakeMouseEvent(type, position) {
487
486
  var pos = position || {
@@ -596,8 +595,6 @@
596
595
  /**
597
596
  * Utility function. Reverses child nodes of a DOM element.
598
597
  * @private
599
- * @param {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement} node
600
- * @return {void}
601
598
  */
602
599
  function reverseChildNodes(node) {
603
600
  var i = node.childNodes.length;
@@ -609,8 +606,6 @@
609
606
  * Used for aria-label attributes, painting on a canvas will fail if the
610
607
  * text contains tags.
611
608
  * @private
612
- * @param {string} str
613
- * @return {string}
614
609
  */
615
610
  function stripHTMLTagsFromString(str) {
616
611
  return typeof str === 'string' ?
@@ -620,8 +615,6 @@
620
615
  * Utility function for hiding an element visually, but still keeping it
621
616
  * available to screen reader users.
622
617
  * @private
623
- * @param {Highcharts.HTMLDOMElement} element
624
- * @return {void}
625
618
  */
626
619
  function visuallyHideElement(element) {
627
620
  css(element, {
@@ -685,12 +678,14 @@
685
678
  /* eslint-disable valid-jsdoc */
686
679
  /**
687
680
  * Fire an event on an element that is either wrapped by Highcharts,
688
- * or a DOM element
681
+ * or a DOM element.
682
+ * @private
689
683
  */
690
684
  function fireEventOnWrappedOrUnwrappedElement(el, eventObject) {
691
685
  var type = eventObject.type;
692
686
  var hcEvents = el.hcEvents;
693
- if (doc.createEvent && (el.dispatchEvent || el.fireEvent)) {
687
+ if (doc.createEvent &&
688
+ (el.dispatchEvent || el.fireEvent)) {
694
689
  if (el.dispatchEvent) {
695
690
  el.dispatchEvent(eventObject);
696
691
  }
@@ -706,7 +701,7 @@
706
701
  }
707
702
  }
708
703
  /**
709
- * @return {string}
704
+ * @private
710
705
  */
711
706
  function getChartTitle(chart) {
712
707
  return stripHTMLTags(chart.options.title.text ||
@@ -714,8 +709,7 @@
714
709
  }
715
710
  /**
716
711
  * Return string with the axis name/title.
717
- * @param {Highcharts.Axis} axis
718
- * @return {string}
712
+ * @private
719
713
  */
720
714
  function getAxisDescription(axis) {
721
715
  return axis && (axis.userOptions && axis.userOptions.accessibility &&
@@ -728,8 +722,11 @@
728
722
  }
729
723
  /**
730
724
  * Return string with text description of the axis range.
731
- * @param {Highcharts.Axis} axis The axis to get range desc of.
732
- * @return {string} A string with the range description for the axis.
725
+ * @private
726
+ * @param {Highcharts.Axis} axis
727
+ * The axis to get range desc of.
728
+ * @return {string}
729
+ * A string with the range description for the axis.
733
730
  */
734
731
  function getAxisRangeDescription(axis) {
735
732
  var axisOptions = axis.options || {};
@@ -752,8 +749,7 @@
752
749
  }
753
750
  /**
754
751
  * Describe the range of a category axis.
755
- * @param {Highcharts.Axis} axis
756
- * @return {string}
752
+ * @private
757
753
  */
758
754
  function getCategoryAxisRangeDesc(axis) {
759
755
  var chart = axis.chart;
@@ -768,8 +764,7 @@
768
764
  }
769
765
  /**
770
766
  * Describe the length of the time window shown on an axis.
771
- * @param {Highcharts.Axis} axis
772
- * @return {string}
767
+ * @private
773
768
  */
774
769
  function getAxisTimeLengthDesc(axis) {
775
770
  var chart = axis.chart,
@@ -796,14 +791,14 @@
796
791
  }
797
792
  /**
798
793
  * Describe an axis from-to range.
799
- * @param {Highcharts.Axis} axis
800
- * @return {string}
794
+ * @private
801
795
  */
802
796
  function getAxisFromToDescription(axis) {
803
797
  var chart = axis.chart,
804
- dateRangeFormat = (chart.options &&
805
- chart.options.accessibility &&
806
- chart.options.accessibility.screenReaderSection.axisRangeDateFormat ||
798
+ options = chart.options,
799
+ dateRangeFormat = (options &&
800
+ options.accessibility &&
801
+ options.accessibility.screenReaderSection.axisRangeDateFormat ||
807
802
  ''),
808
803
  format = function (axisKey) {
809
804
  return axis.dateTime ? chart.time.dateFormat(dateRangeFormat,
@@ -852,8 +847,6 @@
852
847
  * Remove aria-hidden from element. Also unhides parents of the element, and
853
848
  * hides siblings that are not explicitly unhidden.
854
849
  * @private
855
- * @param {Highcharts.Chart} chart
856
- * @param {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement} element
857
850
  */
858
851
  function unhideChartElementFromAT(chart, element) {
859
852
  element.setAttribute('aria-hidden', false);
@@ -875,9 +868,6 @@
875
868
  /**
876
869
  * Hide series from screen readers.
877
870
  * @private
878
- * @param {Highcharts.Series} series
879
- * The series to hide
880
- * @return {void}
881
871
  */
882
872
  function hideSeriesFromAT(series) {
883
873
  var seriesEl = getSeriesA11yElement(series);
@@ -888,9 +878,6 @@
888
878
  /**
889
879
  * Get series objects by series name.
890
880
  * @private
891
- * @param {Highcharts.Chart} chart
892
- * @param {string} name
893
- * @return {Array<Highcharts.Series>}
894
881
  */
895
882
  function getSeriesFromName(chart, name) {
896
883
  if (!name) {
@@ -903,10 +890,6 @@
903
890
  /**
904
891
  * Get point in a series from x/y values.
905
892
  * @private
906
- * @param {Array<Highcharts.Series>} series
907
- * @param {number} x
908
- * @param {number} y
909
- * @return {Highcharts.Point|undefined}
910
893
  */
911
894
  function getPointFromXY(series, x, y) {
912
895
  var i = series.length,
@@ -923,9 +906,6 @@
923
906
  /**
924
907
  * Get relative position of point on an x/y axis from 0 to 1.
925
908
  * @private
926
- * @param {Highcharts.Axis} axis
927
- * @param {Highcharts.Point} point
928
- * @return {number}
929
909
  */
930
910
  function getRelativePointAxisPosition(axis, point) {
931
911
  if (!defined(axis.dataMin) || !defined(axis.dataMax)) {
@@ -941,7 +921,6 @@
941
921
  /**
942
922
  * Get relative position of point on an x/y axis from 0 to 1.
943
923
  * @private
944
- * @param {Highcharts.Point} point
945
924
  */
946
925
  function scrollToPoint(point) {
947
926
  var xAxis = point.series.xAxis,
@@ -1229,7 +1208,7 @@
1229
1208
  init: function () { },
1230
1209
  /**
1231
1210
  * Get keyboard navigation handler for this component.
1232
- * @return {Highcharts.KeyboardNavigationHandler}
1211
+ * @private
1233
1212
  */
1234
1213
  getKeyboardNavigation: function () { },
1235
1214
  /**
@@ -1514,7 +1493,7 @@
1514
1493
  };
1515
1494
  /**
1516
1495
  * Empty handler to just set focus on chart
1517
- * @return {Highcharts.KeyboardNavigationHandler}
1496
+ * @private
1518
1497
  */
1519
1498
  ContainerComponent.prototype.getKeyboardNavigation = function () {
1520
1499
  var chart = this.chart;
@@ -1712,11 +1691,6 @@
1712
1691
  // For text elements, apply x and y offset, #11397.
1713
1692
  /**
1714
1693
  * @private
1715
- * @function
1716
- *
1717
- * @param {Highcharts.SVGElement} text
1718
- *
1719
- * @return {TextAnchorCorrectionObject}
1720
1694
  */
1721
1695
  function getTextAnchorCorrection(text) {
1722
1696
  var posXCorrection = 0,
@@ -1912,12 +1886,12 @@
1912
1886
  clearTimeout(this.clearAnnouncementRegionTimer);
1913
1887
  }
1914
1888
  this.clearAnnouncementRegionTimer = setTimeout(function () {
1915
- _this.announceRegion.innerHTML = '';
1889
+ _this.announceRegion.innerHTML = AST.emptyHTML;
1916
1890
  delete _this.clearAnnouncementRegionTimer;
1917
1891
  }, 1000);
1918
1892
  };
1919
1893
  Announcer.prototype.addAnnounceRegion = function (type) {
1920
- var chartContainer = this.chart.announcerContainer || this.createAnnouncerContainer(),
1894
+ var chartContainer = (this.chart.announcerContainer || this.createAnnouncerContainer()),
1921
1895
  div = this.domElementProvider.createElement('div');
1922
1896
  attr(div, {
1923
1897
  'aria-hidden': false,
@@ -1994,7 +1968,7 @@
1994
1968
  * Get the text of an annotation label.
1995
1969
  *
1996
1970
  * @private
1997
- * @param {object} label The annotation label object
1971
+ * @param {Object} label The annotation label object
1998
1972
  * @return {string} The text in the label.
1999
1973
  */
2000
1974
  function getLabelText(label) {
@@ -2010,7 +1984,7 @@
2010
1984
  * Describe an annotation label.
2011
1985
  *
2012
1986
  * @private
2013
- * @param {object} label The annotation label object to describe
1987
+ * @param {Object} label The annotation label object to describe
2014
1988
  * @return {string} The description for the label.
2015
1989
  */
2016
1990
  function getAnnotationLabelDescription(label) {
@@ -2039,10 +2013,14 @@
2039
2013
  var pointValueDescriptions = points
2040
2014
  .filter(function (p) { return !!p.graphic; }) // Filter out mock points
2041
2015
  .map(getValueDesc)
2042
- .filter(function (desc) { return !!desc; }); // Filter out points we can't describe
2043
- var numPoints = pointValueDescriptions.length;
2044
- var pointsSelector = numPoints > 1 ? 'MultiplePoints' : numPoints ? 'SinglePoint' : 'NoPoints';
2045
- var langFormatStr = 'accessibility.screenReaderSection.annotations.description' + pointsSelector;
2016
+ // Filter out points we can't describe
2017
+ .filter(function (desc) { return !!desc; });
2018
+ var numPoints = pointValueDescriptions.length;
2019
+ var pointsSelector = numPoints > 1 ?
2020
+ 'MultiplePoints' : numPoints ?
2021
+ 'SinglePoint' : 'NoPoints';
2022
+ var langFormatStr = ('accessibility.screenReaderSection.annotations.description' +
2023
+ pointsSelector);
2046
2024
  var context = {
2047
2025
  annotationText: labelText,
2048
2026
  annotation: label,
@@ -2311,7 +2289,8 @@
2311
2289
  after: {
2312
2290
  element: null,
2313
2291
  buildContent: function (chart) {
2314
- var formatter = chart.options.accessibility.screenReaderSection
2292
+ var formatter = chart.options.accessibility
2293
+ .screenReaderSection
2315
2294
  .afterChartFormatter;
2316
2295
  return formatter ? formatter(chart) :
2317
2296
  component.defaultAfterChartFormatter();
@@ -2425,11 +2404,11 @@
2425
2404
  };
2426
2405
  /**
2427
2406
  * @private
2428
- * @return {string}
2429
2407
  */
2430
2408
  InfoRegionsComponent.prototype.defaultBeforeChartFormatter = function () {
2431
- var chart = this.chart;
2432
- var format = chart.options.accessibility.screenReaderSection.beforeChartFormat;
2409
+ var chart = this.chart,
2410
+ format = chart.options.accessibility.screenReaderSection
2411
+ .beforeChartFormat;
2433
2412
  if (!format) {
2434
2413
  return '';
2435
2414
  }
@@ -2467,11 +2446,11 @@
2467
2446
  };
2468
2447
  /**
2469
2448
  * @private
2470
- * @return {string}
2471
2449
  */
2472
2450
  InfoRegionsComponent.prototype.defaultAfterChartFormatter = function () {
2473
2451
  var chart = this.chart;
2474
- var format = chart.options.accessibility.screenReaderSection.afterChartFormat;
2452
+ var format = chart.options.accessibility.screenReaderSection
2453
+ .afterChartFormat;
2475
2454
  if (!format) {
2476
2455
  return '';
2477
2456
  }
@@ -2483,7 +2462,6 @@
2483
2462
  };
2484
2463
  /**
2485
2464
  * @private
2486
- * @return {string}
2487
2465
  */
2488
2466
  InfoRegionsComponent.prototype.getLinkedDescription = function () {
2489
2467
  var el = this.linkedDescriptionElement,
@@ -2492,7 +2470,6 @@
2492
2470
  };
2493
2471
  /**
2494
2472
  * @private
2495
- * @return {string}
2496
2473
  */
2497
2474
  InfoRegionsComponent.prototype.getLongdescText = function () {
2498
2475
  var chartOptions = this.chart.options,
@@ -2506,7 +2483,6 @@
2506
2483
  };
2507
2484
  /**
2508
2485
  * @private
2509
- * @return {string}
2510
2486
  */
2511
2487
  InfoRegionsComponent.prototype.getTypeDescriptionText = function () {
2512
2488
  var chart = this.chart;
@@ -2516,8 +2492,6 @@
2516
2492
  };
2517
2493
  /**
2518
2494
  * @private
2519
- * @param {string} buttonId
2520
- * @return {string}
2521
2495
  */
2522
2496
  InfoRegionsComponent.prototype.getDataTableButtonText = function (buttonId) {
2523
2497
  var chart = this.chart,
@@ -2527,8 +2501,6 @@
2527
2501
  };
2528
2502
  /**
2529
2503
  * @private
2530
- * @param {string} buttonId
2531
- * @return {string}
2532
2504
  */
2533
2505
  InfoRegionsComponent.prototype.getSonifyButtonText = function (buttonId) {
2534
2506
  var chart = this.chart;
@@ -2542,7 +2514,6 @@
2542
2514
  };
2543
2515
  /**
2544
2516
  * @private
2545
- * @return {string}
2546
2517
  */
2547
2518
  InfoRegionsComponent.prototype.getSubtitleText = function () {
2548
2519
  var subtitle = (this.chart.options.subtitle);
@@ -2550,7 +2521,6 @@
2550
2521
  };
2551
2522
  /**
2552
2523
  * @private
2553
- * @return {string}
2554
2524
  */
2555
2525
  InfoRegionsComponent.prototype.getEndOfChartMarkerText = function () {
2556
2526
  var chart = this.chart, markerText = chart.langFormat('accessibility.screenReaderSection.endOfChartMarker', { chart: chart }), id = 'highcharts-end-of-chart-marker-' + chart.index;
@@ -2613,7 +2583,8 @@
2613
2583
  el.setAttribute('tabindex', -1);
2614
2584
  el.onclick = function (e) {
2615
2585
  var onPlayAsSoundClick = (chart.options.accessibility &&
2616
- chart.options.accessibility.screenReaderSection.onPlayAsSoundClick);
2586
+ chart.options.accessibility.screenReaderSection
2587
+ .onPlayAsSoundClick);
2617
2588
  (onPlayAsSoundClick || defaultHandler).call(this, e, chart);
2618
2589
  };
2619
2590
  }
@@ -2640,7 +2611,6 @@
2640
2611
  /**
2641
2612
  * Return object with text description of each of the chart's axes.
2642
2613
  * @private
2643
- * @return {Highcharts.Dictionary<string>}
2644
2614
  */
2645
2615
  InfoRegionsComponent.prototype.getAxesDescription = function () {
2646
2616
  var chart = this.chart,
@@ -2661,8 +2631,6 @@
2661
2631
  };
2662
2632
  /**
2663
2633
  * @private
2664
- * @param {string} collectionKey
2665
- * @return {string}
2666
2634
  */
2667
2635
  InfoRegionsComponent.prototype.getAxisDescriptionText = function (collectionKey) {
2668
2636
  var chart = this.chart;
@@ -2736,17 +2704,13 @@
2736
2704
  /* eslint-disable valid-jsdoc */
2737
2705
  /**
2738
2706
  * Get the wrapped export button element of a chart.
2739
- *
2740
2707
  * @private
2741
- * @param {Highcharts.Chart} chart
2742
- * @returns {Highcharts.SVGElement}
2743
2708
  */
2744
2709
  function getExportMenuButtonElement(chart) {
2745
2710
  return chart.exportSVGElements && chart.exportSVGElements[0];
2746
2711
  }
2747
2712
  /**
2748
2713
  * @private
2749
- * @param {Highcharts.Chart} chart
2750
2714
  */
2751
2715
  function exportingShouldHaveA11y(chart) {
2752
2716
  var exportingOpts = chart.options.exporting,
@@ -2803,7 +2767,6 @@
2803
2767
  if (menu) {
2804
2768
  menu.setAttribute('aria-hidden', 'true');
2805
2769
  }
2806
- this.isExportMenuShown = false;
2807
2770
  this.setExportButtonExpandedState('false');
2808
2771
  };
2809
2772
  /**
@@ -2816,7 +2779,6 @@
2816
2779
  this.addAccessibleContextMenuAttribs();
2817
2780
  unhideChartElementFromAT(chart, menu);
2818
2781
  }
2819
- this.isExportMenuShown = true;
2820
2782
  this.setExportButtonExpandedState('true');
2821
2783
  };
2822
2784
  /**
@@ -2833,8 +2795,21 @@
2833
2795
  * proxy overlay.
2834
2796
  */
2835
2797
  MenuComponent.prototype.onChartRender = function () {
2798
+ var chart = this.chart,
2799
+ focusEl = chart.focusElement,
2800
+ a11y = chart.accessibility;
2836
2801
  this.proxyProvider.clearGroup('chartMenu');
2837
2802
  this.proxyMenuButton();
2803
+ if (this.exportButtonProxy &&
2804
+ focusEl &&
2805
+ focusEl === chart.exportingGroup) {
2806
+ if (focusEl.focusBorder) {
2807
+ chart.setFocusToElement(focusEl, this.exportButtonProxy.buttonElement);
2808
+ }
2809
+ else if (a11y) {
2810
+ a11y.keyboardNavigation.tabindexContainer.focus();
2811
+ }
2812
+ }
2838
2813
  };
2839
2814
  /**
2840
2815
  * @private
@@ -2849,7 +2824,8 @@
2849
2824
  chart: chart,
2850
2825
  chartTitle: getChartTitle(chart)
2851
2826
  }),
2852
- 'aria-expanded': false
2827
+ 'aria-expanded': false,
2828
+ title: chart.options.lang.contextButtonTitle || null
2853
2829
  });
2854
2830
  }
2855
2831
  };
@@ -2895,7 +2871,7 @@
2895
2871
  };
2896
2872
  /**
2897
2873
  * Get keyboard navigation handler for this component.
2898
- * @return {Highcharts.KeyboardNavigationHandler}
2874
+ * @private
2899
2875
  */
2900
2876
  MenuComponent.prototype.getKeyboardNavigation = function () {
2901
2877
  var keys = this.keyCodes,
@@ -3003,7 +2979,7 @@
3003
2979
  var chart = this.chart;
3004
2980
  var curHighlightedItem = chart.exportDivElements[chart.highlightedExportItemIx];
3005
2981
  var exportButtonElement = getExportMenuButtonElement(chart).element;
3006
- if (this.isExportMenuShown) {
2982
+ if (chart.openMenu) {
3007
2983
  this.fakeClickEvent(curHighlightedItem);
3008
2984
  }
3009
2985
  else {
@@ -3073,7 +3049,7 @@
3073
3049
  function chartHideExportMenu() {
3074
3050
  var chart = this,
3075
3051
  exportList = chart.exportDivElements;
3076
- if (exportList && chart.exportContextMenu) {
3052
+ if (exportList && chart.exportContextMenu && chart.openMenu) {
3077
3053
  // Reset hover states etc.
3078
3054
  exportList.forEach(function (el) {
3079
3055
  if (el &&
@@ -3094,10 +3070,6 @@
3094
3070
  *
3095
3071
  * @private
3096
3072
  * @function Highcharts.Chart#highlightExportItem
3097
- *
3098
- * @param {number} ix
3099
- *
3100
- * @return {boolean}
3101
3073
  */
3102
3074
  function chartHighlightExportItem(ix) {
3103
3075
  var listItem = this.exportDivElements && this.exportDivElements[ix];
@@ -3129,7 +3101,6 @@
3129
3101
  *
3130
3102
  * @private
3131
3103
  * @function Highcharts.Chart#highlightLastExportItem
3132
- * @return {boolean}
3133
3104
  */
3134
3105
  function chartHighlightLastExportItem() {
3135
3106
  var chart = this;
@@ -3184,7 +3155,7 @@
3184
3155
  * @class
3185
3156
  * @param {Highcharts.Chart} chart
3186
3157
  * Chart object
3187
- * @param {object} components
3158
+ * @param {Object} components
3188
3159
  * Map of component names to AccessibilityComponent objects.
3189
3160
  * @name Highcharts.KeyboardNavigation
3190
3161
  */
@@ -3220,7 +3191,7 @@
3220
3191
  * @private
3221
3192
  * @param {Highcharts.Chart} chart
3222
3193
  * Chart object
3223
- * @param {object} components
3194
+ * @param {Object} components
3224
3195
  * Map of component names to AccessibilityComponent objects.
3225
3196
  */
3226
3197
  KeyboardNavigation.prototype.init = function (chart, components) {
@@ -3264,7 +3235,8 @@
3264
3235
  order.length) {
3265
3236
  // We (still) have keyboard navigation. Update module list
3266
3237
  this.modules = order.reduce(function (modules, componentName) {
3267
- var navModules = components[componentName].getKeyboardNavigation();
3238
+ var navModules = components[componentName]
3239
+ .getKeyboardNavigation();
3268
3240
  return modules.concat(navModules);
3269
3241
  }, []);
3270
3242
  this.updateExitAnchor();
@@ -3275,6 +3247,65 @@
3275
3247
  this.removeExitAnchor();
3276
3248
  }
3277
3249
  };
3250
+ /**
3251
+ * We use an exit anchor to move focus out of chart whenever we want, by
3252
+ * setting focus to this div and not preventing the default tab action. We
3253
+ * also use this when users come back into the chart by tabbing back, in
3254
+ * order to navigate from the end of the chart.
3255
+ * @private
3256
+ */
3257
+ KeyboardNavigation.prototype.updateExitAnchor = function () {
3258
+ var endMarkerId = "highcharts-end-of-chart-marker-" + this.chart.index,
3259
+ endMarker = getElement(endMarkerId);
3260
+ this.removeExitAnchor();
3261
+ if (endMarker) {
3262
+ this.makeElementAnExitAnchor(endMarker);
3263
+ this.exitAnchor = endMarker;
3264
+ }
3265
+ else {
3266
+ this.createExitAnchor();
3267
+ }
3268
+ };
3269
+ /**
3270
+ * Move to prev/next module.
3271
+ * @private
3272
+ * @param {number} direction
3273
+ * Direction to move. +1 for next, -1 for prev.
3274
+ * @return {boolean}
3275
+ * True if there was a valid module in direction.
3276
+ */
3277
+ KeyboardNavigation.prototype.move = function (direction) {
3278
+ var curModule = this.modules && this.modules[this.currentModuleIx];
3279
+ if (curModule && curModule.terminate) {
3280
+ curModule.terminate(direction);
3281
+ }
3282
+ // Remove existing focus border if any
3283
+ if (this.chart.focusElement) {
3284
+ this.chart.focusElement.removeFocusBorder();
3285
+ }
3286
+ this.currentModuleIx += direction;
3287
+ var newModule = this.modules && this.modules[this.currentModuleIx];
3288
+ if (newModule) {
3289
+ if (newModule.validate && !newModule.validate()) {
3290
+ return this.move(direction); // Invalid module, recurse
3291
+ }
3292
+ if (newModule.init) {
3293
+ newModule.init(direction); // Valid module, init it
3294
+ return true;
3295
+ }
3296
+ }
3297
+ // No module
3298
+ this.currentModuleIx = 0; // Reset counter
3299
+ // Set focus to chart or exit anchor depending on direction
3300
+ this.exiting = true;
3301
+ if (direction > 0) {
3302
+ this.exitAnchor.focus();
3303
+ }
3304
+ else {
3305
+ this.tabindexContainer.focus();
3306
+ }
3307
+ return false;
3308
+ };
3278
3309
  /**
3279
3310
  * Function to run on container focus
3280
3311
  * @private
@@ -3288,30 +3319,37 @@
3288
3319
  if (!this.exiting &&
3289
3320
  !this.tabbingInBackwards &&
3290
3321
  !this.isClickingChart &&
3291
- !focusComesFromChart &&
3292
- this.modules[0]) {
3293
- this.modules[0].init(1);
3322
+ !focusComesFromChart) {
3323
+ var ix = this.getFirstValidModuleIx();
3324
+ if (ix !== null) {
3325
+ this.currentModuleIx = ix;
3326
+ this.modules[ix].init(1);
3327
+ }
3294
3328
  }
3295
3329
  this.exiting = false;
3296
3330
  };
3297
3331
  /**
3298
- * Reset chart navigation state if we click outside the chart and it's
3299
- * not already reset.
3332
+ * Reset chart navigation state if we mouse click and it's not already
3333
+ * reset. Reset fully if outside the chart, otherwise just hide focus
3334
+ * indicator.
3300
3335
  * @private
3301
3336
  */
3302
3337
  KeyboardNavigation.prototype.onMouseUp = function () {
3303
3338
  delete this.isClickingChart;
3304
- if (!this.keyboardReset && !this.pointerIsOverChart) {
3305
- var chart = this.chart,
3306
- curMod = this.modules &&
3307
- this.modules[this.currentModuleIx || 0];
3308
- if (curMod && curMod.terminate) {
3309
- curMod.terminate();
3339
+ if (!this.keyboardReset) {
3340
+ var chart = this.chart;
3341
+ if (!this.pointerIsOverChart) {
3342
+ var curMod = this.modules &&
3343
+ this.modules[this.currentModuleIx || 0];
3344
+ if (curMod && curMod.terminate) {
3345
+ curMod.terminate();
3346
+ }
3347
+ this.currentModuleIx = 0;
3310
3348
  }
3311
3349
  if (chart.focusElement) {
3312
3350
  chart.focusElement.removeFocusBorder();
3351
+ delete chart.focusElement;
3313
3352
  }
3314
- this.currentModuleIx = 0;
3315
3353
  this.keyboardReset = true;
3316
3354
  }
3317
3355
  };
@@ -3338,10 +3376,10 @@
3338
3376
  preventDefault = true;
3339
3377
  }
3340
3378
  else if (response === curNavModule.response.prev) {
3341
- preventDefault = this.prev();
3379
+ preventDefault = this.move(-1);
3342
3380
  }
3343
3381
  else if (response === curNavModule.response.next) {
3344
- preventDefault = this.next();
3382
+ preventDefault = this.move(1);
3345
3383
  }
3346
3384
  if (preventDefault) {
3347
3385
  e.preventDefault();
@@ -3349,79 +3387,6 @@
3349
3387
  }
3350
3388
  }
3351
3389
  };
3352
- /**
3353
- * Go to previous module.
3354
- * @private
3355
- */
3356
- KeyboardNavigation.prototype.prev = function () {
3357
- return this.move(-1);
3358
- };
3359
- /**
3360
- * Go to next module.
3361
- * @private
3362
- */
3363
- KeyboardNavigation.prototype.next = function () {
3364
- return this.move(1);
3365
- };
3366
- /**
3367
- * Move to prev/next module.
3368
- * @private
3369
- * @param {number} direction
3370
- * Direction to move. +1 for next, -1 for prev.
3371
- * @return {boolean}
3372
- * True if there was a valid module in direction.
3373
- */
3374
- KeyboardNavigation.prototype.move = function (direction) {
3375
- var curModule = this.modules && this.modules[this.currentModuleIx];
3376
- if (curModule && curModule.terminate) {
3377
- curModule.terminate(direction);
3378
- }
3379
- // Remove existing focus border if any
3380
- if (this.chart.focusElement) {
3381
- this.chart.focusElement.removeFocusBorder();
3382
- }
3383
- this.currentModuleIx += direction;
3384
- var newModule = this.modules && this.modules[this.currentModuleIx];
3385
- if (newModule) {
3386
- if (newModule.validate && !newModule.validate()) {
3387
- return this.move(direction); // Invalid module, recurse
3388
- }
3389
- if (newModule.init) {
3390
- newModule.init(direction); // Valid module, init it
3391
- return true;
3392
- }
3393
- }
3394
- // No module
3395
- this.currentModuleIx = 0; // Reset counter
3396
- // Set focus to chart or exit anchor depending on direction
3397
- this.exiting = true;
3398
- if (direction > 0) {
3399
- this.exitAnchor.focus();
3400
- }
3401
- else {
3402
- this.tabindexContainer.focus();
3403
- }
3404
- return false;
3405
- };
3406
- /**
3407
- * We use an exit anchor to move focus out of chart whenever we want, by
3408
- * setting focus to this div and not preventing the default tab action. We
3409
- * also use this when users come back into the chart by tabbing back, in
3410
- * order to navigate from the end of the chart.
3411
- * @private
3412
- */
3413
- KeyboardNavigation.prototype.updateExitAnchor = function () {
3414
- var endMarkerId = 'highcharts-end-of-chart-marker-' + this.chart.index,
3415
- endMarker = getElement(endMarkerId);
3416
- this.removeExitAnchor();
3417
- if (endMarker) {
3418
- this.makeElementAnExitAnchor(endMarker);
3419
- this.exitAnchor = endMarker;
3420
- }
3421
- else {
3422
- this.createExitAnchor();
3423
- }
3424
- };
3425
3390
  /**
3426
3391
  * Chart container should have tabindex if navigation is enabled.
3427
3392
  * @private
@@ -3450,6 +3415,18 @@
3450
3415
  }
3451
3416
  };
3452
3417
  /**
3418
+ * Add new exit anchor to the chart.
3419
+ * @private
3420
+ */
3421
+ KeyboardNavigation.prototype.createExitAnchor = function () {
3422
+ var chart = this.chart,
3423
+ exitAnchor = this.exitAnchor = doc.createElement('div');
3424
+ chart.renderTo.appendChild(exitAnchor);
3425
+ this.makeElementAnExitAnchor(exitAnchor);
3426
+ };
3427
+ /**
3428
+ * Add attributes and events to an element to make it function as an
3429
+ * exit anchor.
3453
3430
  * @private
3454
3431
  */
3455
3432
  KeyboardNavigation.prototype.makeElementAnExitAnchor = function (el) {
@@ -3461,27 +3438,17 @@
3461
3438
  this.addExitAnchorEventsToEl(el);
3462
3439
  };
3463
3440
  /**
3464
- * Add new exit anchor to the chart.
3465
- *
3466
- * @private
3467
- */
3468
- KeyboardNavigation.prototype.createExitAnchor = function () {
3469
- var chart = this.chart,
3470
- exitAnchor = this.exitAnchor = doc.createElement('div');
3471
- chart.renderTo.appendChild(exitAnchor);
3472
- this.makeElementAnExitAnchor(exitAnchor);
3473
- };
3474
- /**
3441
+ * Destroy the exit anchor and remove from DOM.
3475
3442
  * @private
3476
3443
  */
3477
3444
  KeyboardNavigation.prototype.removeExitAnchor = function () {
3478
3445
  if (this.exitAnchor && this.exitAnchor.parentNode) {
3479
- this.exitAnchor.parentNode
3480
- .removeChild(this.exitAnchor);
3446
+ this.exitAnchor.parentNode.removeChild(this.exitAnchor);
3481
3447
  delete this.exitAnchor;
3482
3448
  }
3483
3449
  };
3484
3450
  /**
3451
+ * Add focus handler to exit anchor element.
3485
3452
  * @private
3486
3453
  */
3487
3454
  KeyboardNavigation.prototype.addExitAnchorEventsToEl = function (element) {
@@ -3492,6 +3459,9 @@
3492
3459
  focusComesFromChart = (e.relatedTarget &&
3493
3460
  chart.container.contains(e.relatedTarget)),
3494
3461
  comingInBackwards = !(focusComesFromChart || keyboardNavigation.exiting);
3462
+ if (chart.focusElement) {
3463
+ delete chart.focusElement;
3464
+ }
3495
3465
  if (comingInBackwards) {
3496
3466
  // Focus the container instead
3497
3467
  keyboardNavigation.tabbingInBackwards = true;
@@ -3509,7 +3479,7 @@
3509
3479
  if (curModule &&
3510
3480
  curModule.validate && !curModule.validate()) {
3511
3481
  // Invalid. Try moving backwards to find next valid.
3512
- keyboardNavigation.prev();
3482
+ keyboardNavigation.move(-1);
3513
3483
  }
3514
3484
  else if (curModule) {
3515
3485
  // We have a valid module, init it
@@ -3523,6 +3493,21 @@
3523
3493
  }
3524
3494
  });
3525
3495
  };
3496
+ /**
3497
+ * Get the ix of the first module that either does not require validation or
3498
+ * validates positively.
3499
+ * @private
3500
+ */
3501
+ KeyboardNavigation.prototype.getFirstValidModuleIx = function () {
3502
+ var len = this.modules.length;
3503
+ for (var i = 0; i < len; ++i) {
3504
+ var mod = this.modules[i];
3505
+ if (!mod.validate || mod.validate()) {
3506
+ return i;
3507
+ }
3508
+ }
3509
+ return null;
3510
+ };
3526
3511
  /**
3527
3512
  * Remove all traces of keyboard navigation.
3528
3513
  * @private
@@ -3558,6 +3543,7 @@
3558
3543
  * */
3559
3544
  /* eslint-disable valid-jsdoc */
3560
3545
  /**
3546
+ * Composition function.
3561
3547
  * @private
3562
3548
  */
3563
3549
  function compose(ChartClass) {
@@ -3612,7 +3598,7 @@
3612
3598
 
3613
3599
  return KeyboardNavigation;
3614
3600
  });
3615
- _registerModule(_modules, 'Accessibility/Components/LegendComponent.js', [_modules['Core/Animation/AnimationUtilities.js'], _modules['Core/Chart/Chart.js'], _modules['Core/Globals.js'], _modules['Core/Legend/Legend.js'], _modules['Core/Utilities.js'], _modules['Accessibility/AccessibilityComponent.js'], _modules['Accessibility/KeyboardNavigationHandler.js'], _modules['Accessibility/Utils/HTMLUtilities.js'], _modules['Accessibility/Utils/ChartUtilities.js']], function (A, Chart, H, Legend, U, AccessibilityComponent, KeyboardNavigationHandler, HTMLUtilities, ChartUtils) {
3601
+ _registerModule(_modules, 'Accessibility/Components/LegendComponent.js', [_modules['Core/Animation/AnimationUtilities.js'], _modules['Core/Globals.js'], _modules['Core/Legend/Legend.js'], _modules['Core/Utilities.js'], _modules['Accessibility/AccessibilityComponent.js'], _modules['Accessibility/KeyboardNavigationHandler.js'], _modules['Accessibility/Utils/ChartUtilities.js'], _modules['Accessibility/Utils/HTMLUtilities.js']], function (A, H, Legend, U, AccessibilityComponent, KeyboardNavigationHandler, CU, HU) {
3616
3602
  /* *
3617
3603
  *
3618
3604
  * (c) 2009-2021 Øystein Moseng
@@ -3624,18 +3610,39 @@
3624
3610
  * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
3625
3611
  *
3626
3612
  * */
3613
+ var __extends = (this && this.__extends) || (function () {
3614
+ var extendStatics = function (d,
3615
+ b) {
3616
+ extendStatics = Object.setPrototypeOf ||
3617
+ ({ __proto__: [] } instanceof Array && function (d,
3618
+ b) { d.__proto__ = b; }) ||
3619
+ function (d,
3620
+ b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
3621
+ return extendStatics(d, b);
3622
+ };
3623
+ return function (d, b) {
3624
+ extendStatics(d, b);
3625
+ function __() { this.constructor = d; }
3626
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
3627
+ };
3628
+ })();
3627
3629
  var animObject = A.animObject;
3630
+ var doc = H.doc;
3628
3631
  var addEvent = U.addEvent,
3629
- extend = U.extend,
3630
3632
  fireEvent = U.fireEvent,
3631
3633
  isNumber = U.isNumber,
3632
3634
  pick = U.pick,
3633
3635
  syncTimeout = U.syncTimeout;
3634
- var stripHTMLTags = HTMLUtilities.stripHTMLTagsFromString,
3635
- addClass = HTMLUtilities.addClass,
3636
- removeClass = HTMLUtilities.removeClass;
3637
- var getChartTitle = ChartUtils.getChartTitle;
3638
- /* eslint-disable no-invalid-this, valid-jsdoc */
3636
+ var getChartTitle = CU.getChartTitle;
3637
+ var stripHTMLTags = HU.stripHTMLTagsFromString,
3638
+ addClass = HU.addClass,
3639
+ removeClass = HU.removeClass;
3640
+ /* *
3641
+ *
3642
+ * Functions
3643
+ *
3644
+ * */
3645
+ /* eslint-disable valid-jsdoc */
3639
3646
  /**
3640
3647
  * @private
3641
3648
  */
@@ -3657,46 +3664,23 @@
3657
3664
  legendA11yOptions.enabled !== false);
3658
3665
  }
3659
3666
  /**
3660
- * Highlight legend item by index.
3661
- *
3662
3667
  * @private
3663
- * @function Highcharts.Chart#highlightLegendItem
3664
- *
3665
- * @param {number} ix
3666
- *
3667
- * @return {boolean}
3668
3668
  */
3669
- Chart.prototype.highlightLegendItem = function (ix) {
3670
- var items = this.legend.allItems;
3671
- var oldIx = this.accessibility &&
3672
- this.accessibility.components.legend.highlightedLegendItemIx;
3673
- var itemToHighlight = items[ix];
3674
- if (itemToHighlight) {
3675
- if (isNumber(oldIx) && items[oldIx]) {
3676
- fireEvent(items[oldIx].legendGroup.element, 'mouseout');
3677
- }
3678
- scrollLegendToItem(this.legend, ix);
3679
- var legendItemProp = itemToHighlight.legendItem;
3680
- var proxyBtn = itemToHighlight.a11yProxyElement && itemToHighlight.a11yProxyElement.buttonElement;
3681
- if (legendItemProp && legendItemProp.element && proxyBtn) {
3682
- this.setFocusToElement(legendItemProp, proxyBtn);
3683
- }
3684
- if (itemToHighlight.legendGroup) {
3685
- fireEvent(itemToHighlight.legendGroup.element, 'mouseover');
3669
+ function setLegendItemHoverState(hoverActive, legendItem) {
3670
+ legendItem.setState(hoverActive ? 'hover' : '', true);
3671
+ ['legendGroup', 'legendItem', 'legendSymbol'].forEach(function (i) {
3672
+ var obj = legendItem[i];
3673
+ var el = obj && obj.element || obj;
3674
+ if (el) {
3675
+ fireEvent(el, hoverActive ? 'mouseover' : 'mouseout');
3686
3676
  }
3687
- return true;
3688
- }
3689
- return false;
3690
- };
3691
- // Keep track of pressed state for legend items
3692
- addEvent(Legend, 'afterColorizeItem', function (e) {
3693
- var chart = this.chart,
3694
- a11yOptions = chart.options.accessibility,
3695
- legendItem = e.item;
3696
- if (a11yOptions.enabled && legendItem && legendItem.a11yProxyElement) {
3697
- legendItem.a11yProxyElement.buttonElement.setAttribute('aria-pressed', e.visible ? 'true' : 'false');
3698
- }
3699
- });
3677
+ });
3678
+ }
3679
+ /* *
3680
+ *
3681
+ * Class
3682
+ *
3683
+ * */
3700
3684
  /**
3701
3685
  * The LegendComponent class
3702
3686
  *
@@ -3704,18 +3688,37 @@
3704
3688
  * @class
3705
3689
  * @name Highcharts.LegendComponent
3706
3690
  */
3707
- var LegendComponent = function () { };
3708
- LegendComponent.prototype = new AccessibilityComponent();
3709
- extend(LegendComponent.prototype, /** @lends Highcharts.LegendComponent */ {
3691
+ var LegendComponent = /** @class */ (function (_super) {
3692
+ __extends(LegendComponent, _super);
3693
+ function LegendComponent() {
3694
+ /* *
3695
+ *
3696
+ * Properties
3697
+ *
3698
+ * */
3699
+ var _this = _super !== null && _super.apply(this,
3700
+ arguments) || this;
3701
+ _this.highlightedLegendItemIx = NaN;
3702
+ _this.proxyGroup = null;
3703
+ return _this;
3704
+ }
3705
+ /* *
3706
+ *
3707
+ * Functions
3708
+ *
3709
+ * */
3710
+ /* eslint-disable valid-jsdoc */
3710
3711
  /**
3711
3712
  * Init the component
3712
3713
  * @private
3713
3714
  */
3714
- init: function () {
3715
+ LegendComponent.prototype.init = function () {
3715
3716
  var component = this;
3716
3717
  this.recreateProxies();
3717
3718
  // Note: Chart could create legend dynamically, so events can not be
3718
3719
  // tied to the component's chart's current legend.
3720
+ // @todo 1. attach component to created legends
3721
+ // @todo 2. move listeners to composition and access `this.component`
3719
3722
  this.addEvent(Legend, 'afterScroll', function () {
3720
3723
  if (this.chart === component.chart) {
3721
3724
  component.proxyProvider.updateGroupProxyElementPositions('legend');
@@ -3734,15 +3737,16 @@
3734
3737
  if (this.chart === component.chart &&
3735
3738
  this.chart.renderer &&
3736
3739
  component.recreateProxies()) {
3737
- syncTimeout(function () { return component.proxyProvider.updateGroupProxyElementPositions('legend'); }, animObject(pick(this.chart.renderer.globalAnimation, true)).duration);
3740
+ syncTimeout(function () { return component.proxyProvider
3741
+ .updateGroupProxyElementPositions('legend'); }, animObject(pick(this.chart.renderer.globalAnimation, true)).duration);
3738
3742
  }
3739
3743
  });
3740
- },
3744
+ };
3741
3745
  /**
3742
3746
  * Update visibility of legend items when using paged legend
3743
3747
  * @private
3744
3748
  */
3745
- updateLegendItemProxyVisibility: function () {
3749
+ LegendComponent.prototype.updateLegendItemProxyVisibility = function () {
3746
3750
  var chart = this.chart;
3747
3751
  var legend = chart.legend;
3748
3752
  var items = legend.allItems || [];
@@ -3756,8 +3760,11 @@
3756
3760
  if (hasPages) {
3757
3761
  var itemPage = item.pageIx || 0;
3758
3762
  var y = item._legendItemPos ? item._legendItemPos[1] : 0;
3759
- var h = item.legendItem ? Math.round(item.legendItem.getBBox().height) : 0;
3760
- hide = y + h - legend.pages[itemPage] > clipHeight || itemPage !== curPage - 1;
3763
+ var h = item.legendItem ?
3764
+ Math.round(item.legendItem.getBBox().height) :
3765
+ 0;
3766
+ hide = y + h - legend.pages[itemPage] > clipHeight ||
3767
+ itemPage !== curPage - 1;
3761
3768
  }
3762
3769
  if (hide) {
3763
3770
  if (chart.styledMode) {
@@ -3773,19 +3780,19 @@
3773
3780
  }
3774
3781
  }
3775
3782
  });
3776
- },
3783
+ };
3777
3784
  /**
3778
3785
  * @private
3779
3786
  */
3780
- onChartRender: function () {
3787
+ LegendComponent.prototype.onChartRender = function () {
3781
3788
  if (!shouldDoLegendA11y(this.chart)) {
3782
3789
  this.removeProxies();
3783
3790
  }
3784
- },
3791
+ };
3785
3792
  /**
3786
3793
  * @private
3787
3794
  */
3788
- highlightAdjacentLegendPage: function (direction) {
3795
+ LegendComponent.prototype.highlightAdjacentLegendPage = function (direction) {
3789
3796
  var chart = this.chart;
3790
3797
  var legend = chart.legend;
3791
3798
  var curPageIx = legend.currentPage || 1;
@@ -3803,41 +3810,48 @@
3803
3810
  }
3804
3811
  }
3805
3812
  }
3806
- },
3813
+ };
3807
3814
  /**
3808
3815
  * @private
3809
3816
  */
3810
- updateProxyPositionForItem: function (item) {
3817
+ LegendComponent.prototype.updateProxyPositionForItem = function (item) {
3811
3818
  if (item.a11yProxyElement) {
3812
3819
  item.a11yProxyElement.refreshPosition();
3813
3820
  }
3814
- },
3821
+ };
3815
3822
  /**
3816
3823
  * Returns false if legend a11y is disabled and proxies were not created,
3817
3824
  * true otherwise.
3818
3825
  * @private
3819
3826
  */
3820
- recreateProxies: function () {
3827
+ LegendComponent.prototype.recreateProxies = function () {
3828
+ var focusedElement = doc.activeElement;
3829
+ var proxyGroup = this.proxyGroup;
3830
+ var shouldRestoreFocus = focusedElement && proxyGroup &&
3831
+ proxyGroup.contains(focusedElement);
3821
3832
  this.removeProxies();
3822
3833
  if (shouldDoLegendA11y(this.chart)) {
3823
3834
  this.addLegendProxyGroup();
3824
3835
  this.proxyLegendItems();
3825
3836
  this.updateLegendItemProxyVisibility();
3826
3837
  this.updateLegendTitle();
3838
+ if (shouldRestoreFocus) {
3839
+ this.chart.highlightLegendItem(this.highlightedLegendItemIx);
3840
+ }
3827
3841
  return true;
3828
3842
  }
3829
3843
  return false;
3830
- },
3844
+ };
3831
3845
  /**
3832
3846
  * @private
3833
3847
  */
3834
- removeProxies: function () {
3848
+ LegendComponent.prototype.removeProxies = function () {
3835
3849
  this.proxyProvider.removeGroup('legend');
3836
- },
3850
+ };
3837
3851
  /**
3838
3852
  * @private
3839
3853
  */
3840
- updateLegendTitle: function () {
3854
+ LegendComponent.prototype.updateLegendTitle = function () {
3841
3855
  var chart = this.chart;
3842
3856
  var legendTitle = stripHTMLTags((chart.legend &&
3843
3857
  chart.legend.options.title &&
@@ -3851,22 +3865,25 @@
3851
3865
  this.proxyProvider.updateGroupAttrs('legend', {
3852
3866
  'aria-label': legendLabel
3853
3867
  });
3854
- },
3868
+ };
3855
3869
  /**
3856
3870
  * @private
3857
3871
  */
3858
- addLegendProxyGroup: function () {
3872
+ LegendComponent.prototype.addLegendProxyGroup = function () {
3859
3873
  var a11yOptions = this.chart.options.accessibility;
3860
- var groupRole = a11yOptions.landmarkVerbosity === 'all' ? 'region' : null;
3861
- this.proxyProvider.addGroup('legend', 'ul', {
3874
+ var groupRole = a11yOptions.landmarkVerbosity === 'all' ?
3875
+ 'region' : null;
3876
+ this.proxyGroup = this.proxyProvider.addGroup('legend', 'ul', {
3877
+ // Filled by updateLegendTitle, to keep up to date without
3878
+ // recreating group
3862
3879
  'aria-label': '_placeholder_',
3863
3880
  role: groupRole
3864
3881
  });
3865
- },
3882
+ };
3866
3883
  /**
3867
3884
  * @private
3868
3885
  */
3869
- proxyLegendItems: function () {
3886
+ LegendComponent.prototype.proxyLegendItems = function () {
3870
3887
  var component = this,
3871
3888
  items = (this.chart.legend &&
3872
3889
  this.chart.legend.allItems || []);
@@ -3875,12 +3892,12 @@
3875
3892
  component.proxyLegendItem(item);
3876
3893
  }
3877
3894
  });
3878
- },
3895
+ };
3879
3896
  /**
3880
3897
  * @private
3881
3898
  * @param {Highcharts.BubbleLegendItem|Point|Highcharts.Series} item
3882
3899
  */
3883
- proxyLegendItem: function (item) {
3900
+ LegendComponent.prototype.proxyLegendItem = function (item) {
3884
3901
  if (!item.legendItem || !item.legendGroup) {
3885
3902
  return;
3886
3903
  }
@@ -3895,17 +3912,19 @@
3895
3912
  'aria-label': itemLabel
3896
3913
  };
3897
3914
  // Considers useHTML
3898
- var proxyPositioningElement = item.legendGroup.div ? item.legendItem : item.legendGroup;
3915
+ var proxyPositioningElement = item.legendGroup.div ?
3916
+ item.legendItem :
3917
+ item.legendGroup;
3899
3918
  item.a11yProxyElement = this.proxyProvider.addProxyElement('legend', {
3900
3919
  click: item.legendItem,
3901
3920
  visual: proxyPositioningElement.element
3902
3921
  }, attribs);
3903
- },
3922
+ };
3904
3923
  /**
3905
3924
  * Get keyboard navigation handler for this component.
3906
- * @return {Highcharts.KeyboardNavigationHandler}
3925
+ * @private
3907
3926
  */
3908
- getKeyboardNavigation: function () {
3927
+ LegendComponent.prototype.getKeyboardNavigation = function () {
3909
3928
  var keys = this.keyCodes,
3910
3929
  component = this,
3911
3930
  chart = this.chart;
@@ -3938,23 +3957,21 @@
3938
3957
  validate: function () {
3939
3958
  return component.shouldHaveLegendNavigation();
3940
3959
  },
3941
- init: function (direction) {
3942
- return component.onKbdNavigationInit(direction);
3960
+ init: function () {
3961
+ chart.highlightLegendItem(0);
3962
+ component.highlightedLegendItemIx = 0;
3943
3963
  },
3944
3964
  terminate: function () {
3945
3965
  component.highlightedLegendItemIx = -1;
3946
- chart.legend.allItems.forEach(function (item) { return item.setState('', true); });
3966
+ chart.legend.allItems.forEach(function (item) { return setLegendItemHoverState(false, item); });
3947
3967
  }
3948
3968
  });
3949
- },
3969
+ };
3950
3970
  /**
3971
+ * Arrow key navigation
3951
3972
  * @private
3952
- * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
3953
- * @param {number} keyCode
3954
- * @return {number}
3955
- * Response code
3956
3973
  */
3957
- onKbdArrowKey: function (keyboardNavigationHandler, keyCode) {
3974
+ LegendComponent.prototype.onKbdArrowKey = function (keyboardNavigationHandler, keyCode) {
3958
3975
  var keys = this.keyCodes,
3959
3976
  response = keyboardNavigationHandler.response,
3960
3977
  chart = this.chart,
@@ -3971,50 +3988,119 @@
3971
3988
  keyboardNavigationHandler.init(direction);
3972
3989
  return response.success;
3973
3990
  }
3974
- // No wrap, move
3975
- return response[direction > 0 ? 'next' : 'prev'];
3976
- },
3991
+ return response.success;
3992
+ };
3993
+ /**
3994
+ * @private
3995
+ * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
3996
+ * @return {number} Response code
3997
+ */
3998
+ LegendComponent.prototype.onKbdClick = function (keyboardNavigationHandler) {
3999
+ var legendItem = this.chart.legend.allItems[this.highlightedLegendItemIx];
4000
+ if (legendItem && legendItem.a11yProxyElement) {
4001
+ legendItem.a11yProxyElement.click();
4002
+ }
4003
+ return keyboardNavigationHandler.response.success;
4004
+ };
4005
+ /**
4006
+ * @private
4007
+ */
4008
+ LegendComponent.prototype.shouldHaveLegendNavigation = function () {
4009
+ var chart = this.chart,
4010
+ legendOptions = chart.options.legend || {},
4011
+ hasLegend = chart.legend && chart.legend.allItems,
4012
+ hasColorAxis = chart.colorAxis && chart.colorAxis.length,
4013
+ legendA11yOptions = (legendOptions.accessibility || {});
4014
+ return !!(hasLegend &&
4015
+ chart.legend.display &&
4016
+ !hasColorAxis &&
4017
+ legendA11yOptions.enabled &&
4018
+ legendA11yOptions.keyboardNavigation &&
4019
+ legendA11yOptions.keyboardNavigation.enabled);
4020
+ };
4021
+ return LegendComponent;
4022
+ }(AccessibilityComponent));
4023
+ /* *
4024
+ *
4025
+ * Class Namespace
4026
+ *
4027
+ * */
4028
+ (function (LegendComponent) {
4029
+ /* *
4030
+ *
4031
+ * Declarations
4032
+ *
4033
+ * */
4034
+ /* *
4035
+ *
4036
+ * Constants
4037
+ *
4038
+ * */
4039
+ var composedClasses = [];
4040
+ /* *
4041
+ *
4042
+ * Functions
4043
+ *
4044
+ * */
4045
+ /* eslint-disable valid-jsdoc */
3977
4046
  /**
4047
+ * Highlight legend item by index.
3978
4048
  * @private
3979
- * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
3980
- * @return {number} Response code
3981
4049
  */
3982
- onKbdClick: function (keyboardNavigationHandler) {
3983
- var legendItem = this.chart.legend.allItems[this.highlightedLegendItemIx];
3984
- if (legendItem && legendItem.a11yProxyElement) {
3985
- legendItem.a11yProxyElement.click();
4050
+ function chartHighlightLegendItem(ix) {
4051
+ var items = this.legend.allItems;
4052
+ var oldIx = this.accessibility &&
4053
+ this.accessibility.components.legend.highlightedLegendItemIx;
4054
+ var itemToHighlight = items[ix];
4055
+ if (itemToHighlight) {
4056
+ if (isNumber(oldIx) && items[oldIx]) {
4057
+ setLegendItemHoverState(false, items[oldIx]);
4058
+ }
4059
+ scrollLegendToItem(this.legend, ix);
4060
+ var legendItemProp = itemToHighlight.legendItem;
4061
+ var proxyBtn = itemToHighlight.a11yProxyElement &&
4062
+ itemToHighlight.a11yProxyElement.buttonElement;
4063
+ if (legendItemProp && legendItemProp.element && proxyBtn) {
4064
+ this.setFocusToElement(legendItemProp, proxyBtn);
4065
+ }
4066
+ setLegendItemHoverState(true, itemToHighlight);
4067
+ return true;
3986
4068
  }
3987
- return keyboardNavigationHandler.response.success;
3988
- },
4069
+ return false;
4070
+ }
3989
4071
  /**
3990
4072
  * @private
3991
- * @return {boolean|undefined}
3992
4073
  */
3993
- shouldHaveLegendNavigation: function () {
3994
- var chart = this.chart,
3995
- legendOptions = chart.options.legend || {},
3996
- hasLegend = chart.legend && chart.legend.allItems,
3997
- hasColorAxis = chart.colorAxis && chart.colorAxis.length,
3998
- legendA11yOptions = (legendOptions.accessibility || {});
3999
- return !!(hasLegend &&
4000
- chart.legend.display &&
4001
- !hasColorAxis &&
4002
- legendA11yOptions.enabled &&
4003
- legendA11yOptions.keyboardNavigation &&
4004
- legendA11yOptions.keyboardNavigation.enabled);
4005
- },
4074
+ function compose(ChartClass, LegendClass) {
4075
+ if (composedClasses.indexOf(ChartClass) === -1) {
4076
+ composedClasses.push(ChartClass);
4077
+ var chartProto = ChartClass.prototype;
4078
+ chartProto.highlightLegendItem = chartHighlightLegendItem;
4079
+ }
4080
+ if (composedClasses.indexOf(LegendClass) === -1) {
4081
+ composedClasses.push(LegendClass);
4082
+ addEvent(LegendClass, 'afterColorizeItem', legendOnAfterColorizeItem);
4083
+ }
4084
+ }
4085
+ LegendComponent.compose = compose;
4006
4086
  /**
4087
+ * Keep track of pressed state for legend items.
4007
4088
  * @private
4008
- * @param {number} direction
4009
4089
  */
4010
- onKbdNavigationInit: function (direction) {
4090
+ function legendOnAfterColorizeItem(e) {
4011
4091
  var chart = this.chart,
4012
- lastIx = chart.legend.allItems.length - 1,
4013
- ixToHighlight = direction > 0 ? 0 : lastIx;
4014
- chart.highlightLegendItem(ixToHighlight);
4015
- this.highlightedLegendItemIx = ixToHighlight;
4092
+ a11yOptions = chart.options.accessibility,
4093
+ legendItem = e.item;
4094
+ if (a11yOptions.enabled && legendItem && legendItem.a11yProxyElement) {
4095
+ legendItem.a11yProxyElement.buttonElement.setAttribute('aria-pressed', e.visible ? 'true' : 'false');
4096
+ }
4016
4097
  }
4017
- });
4098
+ })(LegendComponent || (LegendComponent = {}));
4099
+ /* *
4100
+ *
4101
+ * Default Export
4102
+ *
4103
+ * */
4018
4104
 
4019
4105
  return LegendComponent;
4020
4106
  });
@@ -4093,8 +4179,6 @@
4093
4179
  }
4094
4180
  /**
4095
4181
  * @private
4096
- * @param {Highcharts.Point} point
4097
- * @return {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement|undefined}
4098
4182
  */
4099
4183
  function addDummyPointElement(point) {
4100
4184
  var series = point.series,
@@ -4125,8 +4209,6 @@
4125
4209
  }
4126
4210
  /**
4127
4211
  * @private
4128
- * @param {Highcharts.Series} series
4129
- * @return {boolean}
4130
4212
  */
4131
4213
  function hasMorePointsThanDescriptionThreshold(series) {
4132
4214
  var chartA11yOptions = series.chart.options.accessibility,
@@ -4137,8 +4219,6 @@
4137
4219
  }
4138
4220
  /**
4139
4221
  * @private
4140
- * @param {Highcharts.Series} series
4141
- * @return {boolean}
4142
4222
  */
4143
4223
  function shouldSetScreenReaderPropsOnPoints(series) {
4144
4224
  var seriesA11yOptions = series.options.accessibility || {};
@@ -4147,8 +4227,6 @@
4147
4227
  }
4148
4228
  /**
4149
4229
  * @private
4150
- * @param {Highcharts.Series} series
4151
- * @return {boolean}
4152
4230
  */
4153
4231
  function shouldSetKeyboardNavPropsOnPoints(series) {
4154
4232
  var chartA11yOptions = series.chart.options.accessibility,
@@ -4159,8 +4237,6 @@
4159
4237
  }
4160
4238
  /**
4161
4239
  * @private
4162
- * @param {Highcharts.Series} series
4163
- * @return {boolean}
4164
4240
  */
4165
4241
  function shouldDescribeSeriesElement(series) {
4166
4242
  var chart = series.chart,
@@ -4175,15 +4251,13 @@
4175
4251
  }
4176
4252
  /**
4177
4253
  * @private
4178
- * @param {Highcharts.Point} point
4179
- * @param {number} value
4180
- * @return {string}
4181
4254
  */
4182
4255
  function pointNumberToString(point, value) {
4183
4256
  var series = point.series,
4184
4257
  chart = series.chart,
4185
4258
  a11yPointOptions = chart.options.accessibility.point || {},
4186
- seriesA11yPointOptions = series.options.accessibility && series.options.accessibility.point || {},
4259
+ seriesA11yPointOptions = series.options.accessibility &&
4260
+ series.options.accessibility.point || {},
4187
4261
  tooltipOptions = series.tooltipOptions || {},
4188
4262
  lang = chart.options.lang;
4189
4263
  if (isNumber(value)) {
@@ -4196,8 +4270,6 @@
4196
4270
  }
4197
4271
  /**
4198
4272
  * @private
4199
- * @param {Highcharts.Series} series
4200
- * @return {string}
4201
4273
  */
4202
4274
  function getSeriesDescriptionText(series) {
4203
4275
  var seriesA11yOptions = series.options.accessibility || {},
@@ -4209,9 +4281,6 @@
4209
4281
  }
4210
4282
  /**
4211
4283
  * @private
4212
- * @param {Highcharts.series} series
4213
- * @param {string} axisCollection
4214
- * @return {string}
4215
4284
  */
4216
4285
  function getSeriesAxisDescriptionText(series, axisCollection) {
4217
4286
  var axis = series[axisCollection];
@@ -4224,21 +4293,19 @@
4224
4293
  * Get accessible time description for a point on a datetime axis.
4225
4294
  *
4226
4295
  * @private
4227
- * @function Highcharts.Point#getTimeDescription
4228
- * @param {Highcharts.Point} point
4229
- * @return {string|undefined}
4230
- * The description as string.
4231
4296
  */
4232
4297
  function getPointA11yTimeDescription(point) {
4233
4298
  var series = point.series,
4234
4299
  chart = series.chart,
4235
- seriesA11yOptions = series.options.accessibility && series.options.accessibility.point || {},
4300
+ seriesA11yOptions = series.options.accessibility &&
4301
+ series.options.accessibility.point || {},
4236
4302
  a11yOptions = chart.options.accessibility.point || {},
4237
4303
  dateXAxis = series.xAxis && series.xAxis.dateTime;
4238
4304
  if (dateXAxis) {
4239
4305
  var tooltipDateFormat = dateXAxis.getXDateFormat(point.x || 0,
4240
4306
  chart.options.tooltip.dateTimeLabelFormats),
4241
- dateFormat = seriesA11yOptions.dateFormatter && seriesA11yOptions.dateFormatter(point) ||
4307
+ dateFormat = seriesA11yOptions.dateFormatter &&
4308
+ seriesA11yOptions.dateFormatter(point) ||
4242
4309
  a11yOptions.dateFormatter && a11yOptions.dateFormatter(point) ||
4243
4310
  seriesA11yOptions.dateFormat ||
4244
4311
  a11yOptions.dateFormat ||
@@ -4248,8 +4315,6 @@
4248
4315
  }
4249
4316
  /**
4250
4317
  * @private
4251
- * @param {Highcharts.Point} point
4252
- * @return {string}
4253
4318
  */
4254
4319
  function getPointXDescription(point) {
4255
4320
  var timeDesc = getPointA11yTimeDescription(point), xAxis = point.series.xAxis || {}, pointCategory = xAxis.categories && defined(point.category) &&
@@ -4259,10 +4324,6 @@
4259
4324
  }
4260
4325
  /**
4261
4326
  * @private
4262
- * @param {Highcharts.Point} point
4263
- * @param {string} prefix
4264
- * @param {string} suffix
4265
- * @return {string}
4266
4327
  */
4267
4328
  function getPointArrayMapValueDescription(point, prefix, suffix) {
4268
4329
  var pre = prefix || '', suf = suffix || '', keyToValStr = function (key) {
@@ -4275,13 +4336,12 @@
4275
4336
  }
4276
4337
  /**
4277
4338
  * @private
4278
- * @param {Highcharts.Point} point
4279
- * @return {string}
4280
4339
  */
4281
4340
  function getPointValue(point) {
4282
4341
  var series = point.series,
4283
4342
  a11yPointOpts = series.chart.options.accessibility.point || {},
4284
- seriesA11yPointOpts = series.chart.options.accessibility && series.chart.options.accessibility.point || {},
4343
+ seriesA11yPointOpts = series.chart.options.accessibility &&
4344
+ series.chart.options.accessibility.point || {},
4285
4345
  tooltipOptions = series.tooltipOptions || {},
4286
4346
  valuePrefix = seriesA11yPointOpts.valuePrefix ||
4287
4347
  a11yPointOpts.valuePrefix ||
@@ -4311,8 +4371,10 @@
4311
4371
  * empty string if none.
4312
4372
  *
4313
4373
  * @private
4314
- * @param {Highcharts.Point} point The data point to get the annotation info from.
4315
- * @return {string} Annotation description
4374
+ * @param {Highcharts.Point} point
4375
+ * The data point to get the annotation info from.
4376
+ * @return {string}
4377
+ * Annotation description
4316
4378
  */
4317
4379
  function getPointAnnotationDescription(point) {
4318
4380
  var chart = point.series.chart;
@@ -4325,7 +4387,6 @@
4325
4387
  /**
4326
4388
  * Return string with information about point.
4327
4389
  * @private
4328
- * @return {string}
4329
4390
  */
4330
4391
  function getPointValueDescription(point) {
4331
4392
  var series = point.series, chart = series.chart, seriesA11yOptions = series.options.accessibility, seriesValueDescFormat = seriesA11yOptions && seriesA11yOptions.point &&
@@ -4344,12 +4405,11 @@
4344
4405
  /**
4345
4406
  * Return string with information about point.
4346
4407
  * @private
4347
- * @return {string}
4348
4408
  */
4349
4409
  function defaultPointDescriptionFormatter(point) {
4350
- var series = point.series, chart = series.chart, valText = getPointValueDescription(point), description = point.options && point.options.accessibility &&
4351
- point.options.accessibility.description, userDescText = description ? ' ' + description : '', seriesNameText = chart.series.length > 1 && series.name ?
4352
- ' ' + series.name + '.' : '', annotationsDesc = getPointAnnotationDescription(point), pointAnnotationsText = annotationsDesc ? ' ' + annotationsDesc : '';
4410
+ var series = point.series, shouldExposeSeriesName = series.chart.series.length > 1 ||
4411
+ series.options.name, valText = getPointValueDescription(point), description = point.options && point.options.accessibility &&
4412
+ point.options.accessibility.description, userDescText = description ? ' ' + description : '', seriesNameText = shouldExposeSeriesName ? ' ' + series.name + '.' : '', annotationsDesc = getPointAnnotationDescription(point), pointAnnotationsText = annotationsDesc ? ' ' + annotationsDesc : '';
4353
4413
  point.accessibility = point.accessibility || {};
4354
4414
  point.accessibility.valueDescription = valText;
4355
4415
  return valText + userDescText + seriesNameText + pointAnnotationsText;
@@ -4363,7 +4423,8 @@
4363
4423
  function setPointScreenReaderAttribs(point, pointElement) {
4364
4424
  var series = point.series,
4365
4425
  a11yPointOptions = series.chart.options.accessibility.point || {},
4366
- seriesPointA11yOptions = series.options.accessibility && series.options.accessibility.point || {},
4426
+ seriesPointA11yOptions = series.options.accessibility &&
4427
+ series.options.accessibility.point || {},
4367
4428
  label = stripHTMLTags(seriesPointA11yOptions.descriptionFormatter &&
4368
4429
  seriesPointA11yOptions.descriptionFormatter(point) ||
4369
4430
  a11yPointOptions.descriptionFormatter &&
@@ -4408,7 +4469,6 @@
4408
4469
  /**
4409
4470
  * Return string with information about series.
4410
4471
  * @private
4411
- * @return {string}
4412
4472
  */
4413
4473
  function defaultSeriesDescriptionFormatter(series) {
4414
4474
  var chart = series.chart,
@@ -4444,7 +4504,8 @@
4444
4504
  } /* else do not add role */
4445
4505
  seriesElement.setAttribute('tabindex', '-1');
4446
4506
  if (!series.chart.styledMode) {
4447
- seriesElement.style.outline = 'none'; // Don't show browser outline on click, despite tabindex
4507
+ // Don't show browser outline on click, despite tabindex
4508
+ seriesElement.style.outline = 'none';
4448
4509
  }
4449
4510
  seriesElement.setAttribute('aria-label', stripHTMLTags(a11yOptions.series.descriptionFormatter &&
4450
4511
  a11yOptions.series.descriptionFormatter(series) ||
@@ -4581,8 +4642,9 @@
4581
4642
  */
4582
4643
  NewDataAnnouncer.prototype.init = function () {
4583
4644
  var chart = this.chart;
4584
- var announceOptions = chart.options.accessibility.announceNewData;
4585
- var announceType = announceOptions.interruptUser ? 'assertive' : 'polite';
4645
+ var announceOptions = (chart.options.accessibility.announceNewData);
4646
+ var announceType = announceOptions.interruptUser ?
4647
+ 'assertive' : 'polite';
4586
4648
  this.lastAnnouncementTime = 0;
4587
4649
  this.dirty = {
4588
4650
  allSeries: {}
@@ -4607,7 +4669,7 @@
4607
4669
  var announcer = this,
4608
4670
  chart = this.chart,
4609
4671
  e = this.eventProvider;
4610
- e.addEvent(chart, 'afterDrilldown', function () {
4672
+ e.addEvent(chart, 'afterApplyDrilldown', function () {
4611
4673
  announcer.lastAnnouncementTime = 0;
4612
4674
  });
4613
4675
  e.addEvent(chart, 'afterAddSeries', function (e) {
@@ -4649,7 +4711,9 @@
4649
4711
  }
4650
4712
  this.queueAnnouncement(Object
4651
4713
  .keys(this.dirty.allSeries)
4652
- .map(function (ix) { return announcer.dirty.allSeries[ix]; }), this.dirty.newSeries, newPoint);
4714
+ .map(function (ix) {
4715
+ return announcer.dirty.allSeries[ix];
4716
+ }), this.dirty.newSeries, newPoint);
4653
4717
  // Reset
4654
4718
  this.dirty = {
4655
4719
  allSeries: {}
@@ -4731,7 +4795,8 @@
4731
4795
  }
4732
4796
  }
4733
4797
  // Default formatter - use lang options
4734
- var multiple = H.charts && H.charts.length > 1 ? 'Multiple' : 'Single', langKey = newSeries ? 'newSeriesAnnounce' + multiple :
4798
+ var multiple = H.charts && H.charts.length > 1 ?
4799
+ 'Multiple' : 'Single', langKey = newSeries ? 'newSeriesAnnounce' + multiple :
4735
4800
  newPoint ? 'newPointAnnounce' + multiple : 'newDataAnnounce', chartTitle = getChartTitle(chart);
4736
4801
  return chart.langFormat('accessibility.announceNewData.' + langKey, {
4737
4802
  chartTitle: chartTitle,
@@ -4868,13 +4933,17 @@
4868
4933
  this.chart = chart;
4869
4934
  this.target = target;
4870
4935
  this.groupType = groupType;
4936
+ var isListItem = groupType === 'ul';
4871
4937
  this.eventProvider = new EventProvider();
4872
- var wrapperEl = groupType === 'ul' ? doc.createElement('li') : null;
4938
+ var wrapperEl = isListItem ? doc.createElement('li') : null;
4873
4939
  var btnEl = this.buttonElement = doc.createElement('button');
4874
4940
  if (!chart.styledMode) {
4875
4941
  this.hideButtonVisually(btnEl);
4876
4942
  }
4877
4943
  if (wrapperEl) {
4944
+ if (isListItem && !chart.styledMode) {
4945
+ wrapperEl.style.listStyle = 'none';
4946
+ }
4878
4947
  wrapperEl.appendChild(btnEl);
4879
4948
  this.element = wrapperEl;
4880
4949
  }
@@ -4901,17 +4970,24 @@
4901
4970
  fireEventOnWrappedOrUnwrappedElement(this.target.click, fakeEventObject);
4902
4971
  };
4903
4972
  /**
4904
- * Update the target to be proxied.
4905
- * The position and events are updated to match the new target.
4973
+ * Update the target to be proxied. The position and events are updated to
4974
+ * match the new target.
4906
4975
  * @param target The new target definition
4907
- * @param attributes New HTML attributes to apply to the button. Set an attribute to null to remove.
4976
+ * @param attributes New HTML attributes to apply to the button. Set an
4977
+ * attribute to null to remove.
4908
4978
  */
4909
4979
  ProxyElement.prototype.updateTarget = function (target, attributes) {
4910
4980
  this.target = target;
4911
4981
  this.updateCSSClassName();
4982
+ var attrs = attributes || {};
4983
+ Object.keys(attrs).forEach(function (a) {
4984
+ if (attrs[a] === null) {
4985
+ delete attrs[a];
4986
+ }
4987
+ });
4912
4988
  attr(this.buttonElement, merge({
4913
4989
  'aria-label': this.getTargetAttr(target.click, 'aria-label')
4914
- }, attributes));
4990
+ }, attrs));
4915
4991
  this.eventProvider.removeAddedEvents();
4916
4992
  this.addProxyEventsToButton(this.buttonElement, target.click);
4917
4993
  this.refreshPosition();
@@ -4940,7 +5016,7 @@
4940
5016
  * Update the CSS class name to match target
4941
5017
  */
4942
5018
  ProxyElement.prototype.updateCSSClassName = function () {
4943
- var stringHasNoTooltip = function (s) { return s.indexOf('highcharts-no-tooltip') > -1; };
5019
+ var stringHasNoTooltip = function (s) { return (s.indexOf('highcharts-no-tooltip') > -1); };
4944
5020
  var legend = this.chart.legend;
4945
5021
  var groupDiv = legend.group && legend.group.div;
4946
5022
  var noTooltipOnGroup = stringHasNoTooltip(groupDiv && groupDiv.className || '');
@@ -4968,7 +5044,8 @@
4968
5044
  fireEventOnWrappedOrUnwrappedElement(target, clonedEvent);
4969
5045
  }
4970
5046
  e.stopPropagation();
4971
- // #9682, #15318: Touch scrolling didnt work when touching proxy
5047
+ // #9682, #15318: Touch scrolling didnt work when touching
5048
+ // proxy
4972
5049
  if (!isTouchEvent) {
4973
5050
  e.preventDefault();
4974
5051
  }
@@ -5008,12 +5085,14 @@
5008
5085
  var chartDiv = this.chart.renderTo;
5009
5086
  if (chartDiv && posElement && posElement.getBoundingClientRect) {
5010
5087
  var rectEl = posElement.getBoundingClientRect(),
5011
- rectDiv = chartDiv.getBoundingClientRect();
5088
+ chartPos = this.chart.pointer.getChartPosition();
5012
5089
  return {
5013
- x: rectEl.left - rectDiv.left,
5014
- y: rectEl.top - rectDiv.top,
5015
- width: rectEl.right - rectEl.left,
5016
- height: rectEl.bottom - rectEl.top
5090
+ x: (rectEl.left - chartPos.left) / chartPos.scaleX,
5091
+ y: (rectEl.top - chartPos.top) / chartPos.scaleY,
5092
+ width: rectEl.right / chartPos.scaleX -
5093
+ rectEl.left / chartPos.scaleX,
5094
+ height: rectEl.bottom / chartPos.scaleY -
5095
+ rectEl.top / chartPos.scaleY
5017
5096
  };
5018
5097
  }
5019
5098
  return { x: 0, y: 0, width: 1, height: 1 };
@@ -5110,10 +5189,13 @@
5110
5189
  /**
5111
5190
  * Create a group that will contain proxy elements. The group order is
5112
5191
  * automatically updated according to the last group order keys.
5192
+ *
5193
+ * Returns the added group.
5113
5194
  */
5114
5195
  ProxyProvider.prototype.addGroup = function (groupKey, groupType, attributes) {
5115
- if (this.groups[groupKey]) {
5116
- return;
5196
+ var existingGroup = this.groups[groupKey];
5197
+ if (existingGroup) {
5198
+ return existingGroup.groupElement;
5117
5199
  }
5118
5200
  var proxyContainer = this.domElementProvider.createElement(groupType);
5119
5201
  // If we want to add a role to the group, and still use e.g.
@@ -5136,15 +5218,13 @@
5136
5218
  };
5137
5219
  attr(groupElement, attributes || {});
5138
5220
  if (groupType === 'ul') {
5139
- if (!this.chart.styledMode) {
5140
- proxyContainer.style.listStyle = 'none';
5141
- }
5142
5221
  proxyContainer.setAttribute('role', 'list'); // Needed for webkit
5143
5222
  }
5144
5223
  // Add the group to the end by default, and perhaps then we
5145
5224
  // won't have to reorder the whole set of groups.
5146
5225
  this.afterChartProxyPosContainer.appendChild(groupElement);
5147
5226
  this.updateGroupOrder(this.groupOrder);
5227
+ return groupElement;
5148
5228
  };
5149
5229
  /**
5150
5230
  * Update HTML attributes of a group.
@@ -5328,6 +5408,10 @@
5328
5408
  */
5329
5409
  ProxyProvider.prototype.updatePosContainerPositions = function () {
5330
5410
  var chart = this.chart;
5411
+ // If exporting, don't add these containers to the DOM.
5412
+ if (chart.renderer.forExport) {
5413
+ return;
5414
+ }
5331
5415
  var rendererSVGEl = chart.renderer.box;
5332
5416
  chart.container.insertBefore(this.afterChartProxyPosContainer, rendererSVGEl.nextSibling);
5333
5417
  chart.container.insertBefore(this.beforeChartProxyPosContainer, rendererSVGEl);
@@ -5934,7 +6018,6 @@
5934
6018
  * @param {number} i
5935
6019
  * The index of the button
5936
6020
  * @param {boolean} [redraw]
5937
- * @return {void}
5938
6021
  */
5939
6022
  RangeSelector.prototype.clickButton = function (i, redraw) {
5940
6023
  var rangeSelector = this,
@@ -6032,7 +6115,8 @@
6032
6115
  // If the navigator exist and the axis range is declared reset that
6033
6116
  // range and from now on only use the range set by a user, #14742.
6034
6117
  if (chart.navigator && chart.navigator.baseSeries[0]) {
6035
- chart.navigator.baseSeries[0].xAxis.options.range = void 0;
6118
+ chart.navigator.baseSeries[0].xAxis.options
6119
+ .range = void 0;
6036
6120
  }
6037
6121
  newMin = dataMin;
6038
6122
  newMax = dataMax;
@@ -6077,7 +6161,6 @@
6077
6161
  * @private
6078
6162
  * @function Highcharts.RangeSelector#setSelected
6079
6163
  * @param {number} [selected]
6080
- * @return {void}
6081
6164
  */
6082
6165
  RangeSelector.prototype.setSelected = function (selected) {
6083
6166
  this.selected = this.options.selected = selected;
@@ -6088,12 +6171,11 @@
6088
6171
  * @private
6089
6172
  * @function Highcharts.RangeSelector#init
6090
6173
  * @param {Highcharts.Chart} chart
6091
- * @return {void}
6092
6174
  */
6093
6175
  RangeSelector.prototype.init = function (chart) {
6094
6176
  var rangeSelector = this,
6095
6177
  options = chart.options.rangeSelector,
6096
- buttonOptions = options.buttons || rangeSelector.defaultButtons.slice(),
6178
+ buttonOptions = (options.buttons || rangeSelector.defaultButtons.slice()),
6097
6179
  selectedOption = options.selected,
6098
6180
  blurInputs = function () {
6099
6181
  var minInput = rangeSelector.minInput,
@@ -6143,7 +6225,6 @@
6143
6225
  *
6144
6226
  * @private
6145
6227
  * @function Highcharts.RangeSelector#updateButtonStates
6146
- * @return {void}
6147
6228
  */
6148
6229
  RangeSelector.prototype.updateButtonStates = function () {
6149
6230
  var rangeSelector = this,
@@ -6249,7 +6330,6 @@
6249
6330
  * @private
6250
6331
  * @function Highcharts.RangeSelector#computeButtonRange
6251
6332
  * @param {Highcharts.RangeSelectorButtonsOptions} rangeOptions
6252
- * @return {void}
6253
6333
  */
6254
6334
  RangeSelector.prototype.computeButtonRange = function (rangeOptions) {
6255
6335
  var type = rangeOptions.type,
@@ -6284,12 +6364,11 @@
6284
6364
  *
6285
6365
  * @private
6286
6366
  * @function Highcharts.RangeSelector#getInputValue
6287
- * @param {string} name
6288
- * @return {number}
6289
6367
  */
6290
6368
  RangeSelector.prototype.getInputValue = function (name) {
6291
6369
  var input = name === 'min' ? this.minInput : this.maxInput;
6292
- var options = this.chart.options.rangeSelector;
6370
+ var options = this.chart.options
6371
+ .rangeSelector;
6293
6372
  var time = this.chart.time;
6294
6373
  if (input) {
6295
6374
  return ((input.type === 'text' && options.inputDateParser) ||
@@ -6302,9 +6381,6 @@
6302
6381
  *
6303
6382
  * @private
6304
6383
  * @function Highcharts.RangeSelector#setInputValue
6305
- * @param {string} name
6306
- * @param {number} [inputTime]
6307
- * @return {void}
6308
6384
  */
6309
6385
  RangeSelector.prototype.setInputValue = function (name, inputTime) {
6310
6386
  var options = this.options, time = this.chart.time, input = name === 'min' ? this.minInput : this.maxInput, dateBox = name === 'min' ? this.minDateBox : this.maxDateBox;
@@ -6319,7 +6395,8 @@
6319
6395
  input.setAttribute('data-hc-time', inputTime);
6320
6396
  updatedTime = inputTime;
6321
6397
  }
6322
- input.value = time.dateFormat(this.inputTypeFormats[input.type] || options.inputEditDateFormat, updatedTime);
6398
+ input.value = time.dateFormat((this.inputTypeFormats[input.type] ||
6399
+ options.inputEditDateFormat), updatedTime);
6323
6400
  if (dateBox) {
6324
6401
  dateBox.attr({
6325
6402
  text: time.dateFormat(options.inputDateFormat, updatedTime)
@@ -6332,10 +6409,6 @@
6332
6409
  *
6333
6410
  * @private
6334
6411
  * @function Highcharts.RangeSelector#setInputExtremes
6335
- * @param {string} name
6336
- * @param {number} min
6337
- * @param {number} max
6338
- * @return {void}
6339
6412
  */
6340
6413
  RangeSelector.prototype.setInputExtremes = function (name, min, max) {
6341
6414
  var input = name === 'min' ? this.minInput : this.maxInput;
@@ -6360,7 +6433,6 @@
6360
6433
  * @private
6361
6434
  * @function Highcharts.RangeSelector#showInput
6362
6435
  * @param {string} name
6363
- * @return {void}
6364
6436
  */
6365
6437
  RangeSelector.prototype.showInput = function (name) {
6366
6438
  var dateBox = name === 'min' ? this.minDateBox : this.maxDateBox;
@@ -6372,7 +6444,9 @@
6372
6444
  translateY = _a.translateY;
6373
6445
  var inputBoxWidth = this.options.inputBoxWidth;
6374
6446
  css(input, {
6375
- width: isTextInput ? ((dateBox.width + (inputBoxWidth ? -2 : 20)) + 'px') : 'auto',
6447
+ width: isTextInput ?
6448
+ ((dateBox.width + (inputBoxWidth ? -2 : 20)) + 'px') :
6449
+ 'auto',
6376
6450
  height: isTextInput ? ((dateBox.height - 2) + 'px') : 'auto',
6377
6451
  border: '2px solid silver'
6378
6452
  });
@@ -6398,7 +6472,6 @@
6398
6472
  * @private
6399
6473
  * @function Highcharts.RangeSelector#hideInput
6400
6474
  * @param {string} name
6401
- * @return {void}
6402
6475
  */
6403
6476
  RangeSelector.prototype.hideInput = function (name) {
6404
6477
  var input = name === 'min' ? this.minInput : this.maxInput;
@@ -6450,8 +6523,6 @@
6450
6523
  *
6451
6524
  * @private
6452
6525
  * @function Highcharts.RangeSelector#drawInput
6453
- * @param {string} name
6454
- * @return {RangeSelectorInputElements}
6455
6526
  */
6456
6527
  RangeSelector.prototype.drawInput = function (name) {
6457
6528
  var _a = this,
@@ -6620,8 +6691,6 @@
6620
6691
  *
6621
6692
  * @private
6622
6693
  * @function Highcharts.RangeSelector#getPosition
6623
- *
6624
- * @return {Highcharts.Dictionary<number>}
6625
6694
  */
6626
6695
  RangeSelector.prototype.getPosition = function () {
6627
6696
  var chart = this.chart,
@@ -6641,13 +6710,8 @@
6641
6710
  *
6642
6711
  * @private
6643
6712
  * @function Highcharts.RangeSelector#getYTDExtremes
6644
- *
6645
- * @param {number} dataMax
6646
- *
6647
- * @param {number} dataMin
6648
- *
6649
6713
  * @return {*}
6650
- * Returns min and max for the YTD
6714
+ * Returns min and max for the YTD
6651
6715
  */
6652
6716
  RangeSelector.prototype.getYTDExtremes = function (dataMax, dataMin, useUTC) {
6653
6717
  var time = this.chart.time,
@@ -6676,7 +6740,6 @@
6676
6740
  * X axis minimum
6677
6741
  * @param {number} [max]
6678
6742
  * X axis maximum
6679
- * @return {void}
6680
6743
  */
6681
6744
  RangeSelector.prototype.render = function (min, max) {
6682
6745
  var chart = this.chart,
@@ -6730,7 +6793,8 @@
6730
6793
  this.setInputValue('min', min);
6731
6794
  this.setInputValue('max', max);
6732
6795
  var unionExtremes = (chart.scroller && chart.scroller.getUnionExtremes()) || chart.xAxis[0] || {};
6733
- if (defined(unionExtremes.dataMin) && defined(unionExtremes.dataMax)) {
6796
+ if (defined(unionExtremes.dataMin) &&
6797
+ defined(unionExtremes.dataMax)) {
6734
6798
  var minRange = chart.xAxis[0].minRange || 0;
6735
6799
  this.setInputExtremes('min', unionExtremes.dataMin, Math.min(unionExtremes.dataMax, this.getInputValue('max')) - minRange);
6736
6800
  this.setInputExtremes('max', Math.max(unionExtremes.dataMin, this.getInputValue('min')) + minRange, unionExtremes.dataMax);
@@ -6763,7 +6827,6 @@
6763
6827
  *
6764
6828
  * @private
6765
6829
  * @function Highcharts.RangeSelector#renderButtons
6766
- * @return {void}
6767
6830
  */
6768
6831
  RangeSelector.prototype.renderButtons = function () {
6769
6832
  var _this = this;
@@ -6864,7 +6927,6 @@
6864
6927
  *
6865
6928
  * @private
6866
6929
  * @function Highcharts.RangeSelector#alignElements
6867
- * @return {void}
6868
6930
  */
6869
6931
  RangeSelector.prototype.alignElements = function () {
6870
6932
  var _this = this;
@@ -7020,7 +7082,6 @@
7020
7082
  * @function Highcharts.RangeSelector#alignButtonGroup
7021
7083
  * @param {number} xOffsetForExportButton
7022
7084
  * @param {number} [width]
7023
- * @return {void}
7024
7085
  */
7025
7086
  RangeSelector.prototype.alignButtonGroup = function (xOffsetForExportButton, width) {
7026
7087
  var _a = this,
@@ -7050,7 +7111,6 @@
7050
7111
  /**
7051
7112
  * @private
7052
7113
  * @function Highcharts.RangeSelector#positionButtons
7053
- * @return {void}
7054
7114
  */
7055
7115
  RangeSelector.prototype.positionButtons = function () {
7056
7116
  var _a = this,
@@ -7091,7 +7151,6 @@
7091
7151
  * @param {number} xOffsetForExportButton
7092
7152
  * The X offset of the group required to make room for the
7093
7153
  * exporting button
7094
- * @return {void}
7095
7154
  */
7096
7155
  RangeSelector.prototype.handleCollision = function (xOffsetForExportButton) {
7097
7156
  var _this = this;
@@ -7192,7 +7251,6 @@
7192
7251
  * @private
7193
7252
  * @function Highcharts.RangeSelector#collapseButtons
7194
7253
  * @param {number} xOffsetForExportButton
7195
- * @return {void}
7196
7254
  */
7197
7255
  RangeSelector.prototype.collapseButtons = function (xOffsetForExportButton) {
7198
7256
  var _a = this,
@@ -7246,7 +7304,6 @@
7246
7304
  *
7247
7305
  * @private
7248
7306
  * @function Highcharts.RangeSelector#expandButtons
7249
- * @return {void}
7250
7307
  */
7251
7308
  RangeSelector.prototype.expandButtons = function () {
7252
7309
  var _a = this,
@@ -7278,7 +7335,6 @@
7278
7335
  *
7279
7336
  * @private
7280
7337
  * @function Highcharts.RangeSelector#currentButtonIndex
7281
- * @return {number}
7282
7338
  */
7283
7339
  RangeSelector.prototype.currentButtonIndex = function () {
7284
7340
  var dropdown = this.dropdown;
@@ -7292,7 +7348,6 @@
7292
7348
  *
7293
7349
  * @private
7294
7350
  * @function Highcharts.RangeSelector#showDropdown
7295
- * @return {void}
7296
7351
  */
7297
7352
  RangeSelector.prototype.showDropdown = function () {
7298
7353
  var _a = this,
@@ -7316,7 +7371,6 @@
7316
7371
  /**
7317
7372
  * @private
7318
7373
  * @function Highcharts.RangeSelector#hideDropdown
7319
- * @return {void}
7320
7374
  */
7321
7375
  RangeSelector.prototype.hideDropdown = function () {
7322
7376
  var dropdown = this.dropdown;
@@ -7335,7 +7389,7 @@
7335
7389
  * @private
7336
7390
  * @function Highcharts.RangeSelector#getHeight
7337
7391
  * @return {number}
7338
- * Returns rangeSelector height
7392
+ * Returns rangeSelector height
7339
7393
  */
7340
7394
  RangeSelector.prototype.getHeight = function () {
7341
7395
  var rangeSelector = this,
@@ -7371,11 +7425,8 @@
7371
7425
  *
7372
7426
  * @private
7373
7427
  * @function Highcharts.RangeSelector#titleCollision
7374
- *
7375
- * @param {Highcharts.Chart} chart
7376
- *
7377
7428
  * @return {boolean}
7378
- * Returns collision status
7429
+ * Returns collision status
7379
7430
  */
7380
7431
  RangeSelector.prototype.titleCollision = function (chart) {
7381
7432
  return !(chart.options.title.text ||
@@ -7387,7 +7438,6 @@
7387
7438
  * @private
7388
7439
  * @function Highcharts.RangeSelector#update
7389
7440
  * @param {Highcharts.RangeSelectorOptions} options
7390
- * @return {void}
7391
7441
  */
7392
7442
  RangeSelector.prototype.update = function (options) {
7393
7443
  var chart = this.chart;
@@ -7483,17 +7533,14 @@
7483
7533
  *
7484
7534
  * @private
7485
7535
  * @function preferredInputType
7486
- * @param {string} format
7487
- * @return {string}
7488
7536
  */
7489
7537
  function preferredInputType(format) {
7490
7538
  var ms = format.indexOf('%L') !== -1;
7491
7539
  if (ms) {
7492
7540
  return 'text';
7493
7541
  }
7494
- var date = ['a', 'A', 'd', 'e', 'w', 'b', 'B', 'm', 'o', 'y', 'Y'].some(function (char) {
7495
- return format.indexOf('%' + char) !== -1;
7496
- });
7542
+ var date = ['a', 'A', 'd', 'e', 'w', 'b', 'B', 'm', 'o', 'y', 'Y']
7543
+ .some(function (char) { return format.indexOf('%' + char) !== -1; });
7497
7544
  var time = ['H', 'k', 'I', 'l', 'M', 'S'].some(function (char) {
7498
7545
  return format.indexOf('%' + char) !== -1;
7499
7546
  });
@@ -7530,7 +7577,8 @@
7530
7577
  // Get the true range from a start date
7531
7578
  getTrueRange = function (base,
7532
7579
  count) {
7533
- var timeName = type === 'year' ? 'FullYear' : 'Month';
7580
+ var timeName = type === 'year' ?
7581
+ 'FullYear' : 'Month';
7534
7582
  var date = new time.Date(base);
7535
7583
  var basePeriod = time.get(timeName,
7536
7584
  date);
@@ -7975,8 +8023,9 @@
7975
8023
  var newIxOutOfRange = newIx > 1 || newIx < 0;
7976
8024
  if (newIxOutOfRange) {
7977
8025
  if (chart.accessibility) {
7978
- chart.accessibility.keyboardNavigation.tabindexContainer.focus();
7979
- chart.accessibility.keyboardNavigation[direction < 0 ? 'prev' : 'next']();
8026
+ chart.accessibility.keyboardNavigation.tabindexContainer
8027
+ .focus();
8028
+ chart.accessibility.keyboardNavigation.move(direction);
7980
8029
  }
7981
8030
  }
7982
8031
  else if (rangeSel) {
@@ -8060,13 +8109,14 @@
8060
8109
  // Tab-press with dropdown focused does not propagate to chart
8061
8110
  // automatically, so we manually catch and handle it when relevant.
8062
8111
  this.removeDropdownKeydownHandler = addEvent(dropdown, 'keydown', function (e) {
8063
- var isTab = (e.which || e.keyCode) === _this.keyCodes.tab;
8112
+ var isTab = (e.which || e.keyCode) === _this.keyCodes.tab,
8113
+ a11y = chart.accessibility;
8064
8114
  if (isTab) {
8065
8115
  e.preventDefault();
8066
8116
  e.stopPropagation();
8067
- if (chart.accessibility) {
8068
- chart.accessibility.keyboardNavigation.tabindexContainer.focus();
8069
- chart.accessibility.keyboardNavigation[e.shiftKey ? 'prev' : 'next']();
8117
+ if (a11y) {
8118
+ a11y.keyboardNavigation.tabindexContainer.focus();
8119
+ a11y.keyboardNavigation.move(e.shiftKey ? -1 : 1);
8070
8120
  }
8071
8121
  }
8072
8122
  });
@@ -8196,10 +8246,6 @@
8196
8246
  *
8197
8247
  * @private
8198
8248
  * @function Highcharts.Chart#highlightRangeSelectorButton
8199
- *
8200
- * @param {number} ix
8201
- *
8202
- * @return {boolean}
8203
8249
  */
8204
8250
  function chartHighlightRangeSelectorButton(ix) {
8205
8251
  var buttons = (this.rangeSelector &&
@@ -8233,7 +8279,7 @@
8233
8279
  if (composedClasses.indexOf(ChartClass) === -1) {
8234
8280
  composedClasses.push(ChartClass);
8235
8281
  var chartProto = ChartClass.prototype;
8236
- chartProto.highlightRangeSelectorButton = chartHighlightRangeSelectorButton;
8282
+ chartProto.highlightRangeSelectorButton = (chartHighlightRangeSelectorButton);
8237
8283
  }
8238
8284
  if (composedClasses.indexOf(RangeSelectorClass) === -1) {
8239
8285
  composedClasses.push(RangeSelectorClass);
@@ -8247,9 +8293,9 @@
8247
8293
  * @private
8248
8294
  */
8249
8295
  function rangeSelectorAfterBtnClick() {
8250
- if (this.chart.accessibility &&
8251
- this.chart.accessibility.components.rangeSelector) {
8252
- return this.chart.accessibility.components.rangeSelector.onAfterBtnClick();
8296
+ var a11y = this.chart.accessibility;
8297
+ if (a11y && a11y.components.rangeSelector) {
8298
+ return a11y.components.rangeSelector.onAfterBtnClick();
8253
8299
  }
8254
8300
  }
8255
8301
  })(RangeSelectorComponent || (RangeSelectorComponent = {}));
@@ -8345,7 +8391,8 @@
8345
8391
  var hadForcedMarker = point.hasForcedA11yMarker;
8346
8392
  delete point.hasForcedA11yMarker;
8347
8393
  if (pointOptions.marker) {
8348
- var isStillForcedMarker = hadForcedMarker && getPointMarkerOpacity(pointOptions) === 0;
8394
+ var isStillForcedMarker = hadForcedMarker &&
8395
+ getPointMarkerOpacity(pointOptions) === 0;
8349
8396
  if (pointOptions.marker.enabled && !isStillForcedMarker) {
8350
8397
  unforcePointMarkerOptions(pointOptions);
8351
8398
  point.hasForcedA11yMarker = false;
@@ -8361,7 +8408,9 @@
8361
8408
  * @private
8362
8409
  */
8363
8410
  function hasIndividualPointMarkerOptions(series) {
8364
- return !!(series._hasPointMarkers && series.points && series.points.length);
8411
+ return !!(series._hasPointMarkers &&
8412
+ series.points &&
8413
+ series.points.length);
8365
8414
  }
8366
8415
  /**
8367
8416
  * @private
@@ -8370,7 +8419,8 @@
8370
8419
  var a11yOptions = series.chart.options.accessibility;
8371
8420
  return series.points.length <
8372
8421
  a11yOptions.series.pointDescriptionEnabledThreshold ||
8373
- a11yOptions.series.pointDescriptionEnabledThreshold === false;
8422
+ a11yOptions.series
8423
+ .pointDescriptionEnabledThreshold === false;
8374
8424
  }
8375
8425
  /**
8376
8426
  * Process marker graphics after render
@@ -8388,8 +8438,11 @@
8388
8438
  if (hasIndividualPointMarkerOptions(series)) {
8389
8439
  series.points.forEach(function (point) {
8390
8440
  if (point.graphic) {
8391
- point.graphic[point.hasForcedA11yMarker ? 'addClass' : 'removeClass']('highcharts-a11y-marker-hidden');
8392
- point.graphic[point.hasForcedA11yMarker === false ? 'addClass' : 'removeClass']('highcharts-a11y-marker-visible');
8441
+ point.graphic[point.hasForcedA11yMarker ?
8442
+ 'addClass' : 'removeClass']('highcharts-a11y-marker-hidden');
8443
+ point.graphic[point.hasForcedA11yMarker === false ?
8444
+ 'addClass' :
8445
+ 'removeClass']('highcharts-a11y-marker-visible');
8393
8446
  }
8394
8447
  });
8395
8448
  }
@@ -8421,6 +8474,7 @@
8421
8474
  else if (series.a11yMarkersForced) {
8422
8475
  delete series.a11yMarkersForced;
8423
8476
  unforceSeriesMarkerOptions(series);
8477
+ delete series.resetA11yMarkerOptions;
8424
8478
  }
8425
8479
  }
8426
8480
  /**
@@ -8431,7 +8485,9 @@
8431
8485
  chartA11yEnabled = chart.options.accessibility.enabled,
8432
8486
  seriesA11yEnabled = (series.options.accessibility &&
8433
8487
  series.options.accessibility.enabled) !== false;
8434
- return chartA11yEnabled && seriesA11yEnabled && isWithinDescriptionThreshold(series);
8488
+ return (chartA11yEnabled &&
8489
+ seriesA11yEnabled &&
8490
+ isWithinDescriptionThreshold(series));
8435
8491
  }
8436
8492
  /**
8437
8493
  * @private
@@ -8446,20 +8502,20 @@
8446
8502
  });
8447
8503
  }
8448
8504
  /**
8505
+ * Reset markers to normal
8449
8506
  * @private
8450
8507
  */
8451
8508
  function unforceSeriesMarkerOptions(series) {
8452
8509
  var resetMarkerOptions = series.resetA11yMarkerOptions;
8453
8510
  if (resetMarkerOptions) {
8454
- merge(true, series.options, {
8511
+ var originalOpactiy = resetMarkerOptions.states &&
8512
+ resetMarkerOptions.states.normal &&
8513
+ resetMarkerOptions.states.normal.opacity;
8514
+ series.update({
8455
8515
  marker: {
8456
8516
  enabled: resetMarkerOptions.enabled,
8457
8517
  states: {
8458
- normal: {
8459
- opacity: resetMarkerOptions.states &&
8460
- resetMarkerOptions.states.normal &&
8461
- resetMarkerOptions.states.normal.opacity
8462
- }
8518
+ normal: { opacity: originalOpactiy }
8463
8519
  }
8464
8520
  }
8465
8521
  });
@@ -8505,12 +8561,10 @@
8505
8561
  *
8506
8562
  * @private
8507
8563
  * @function getPointIndex
8508
- *
8509
8564
  * @param {Highcharts.AccessibilityPoint} point
8510
- * The point to find index of.
8511
- *
8565
+ * The point to find index of.
8512
8566
  * @return {number|undefined}
8513
- * The index in the series.points array of the point.
8567
+ * The index in the series.points array of the point.
8514
8568
  */
8515
8569
  function getPointIndex(point) {
8516
8570
  var index = point.index,
@@ -8529,13 +8583,7 @@
8529
8583
  }
8530
8584
  /**
8531
8585
  * Determine if series navigation should be skipped
8532
- *
8533
8586
  * @private
8534
- * @function isSkipSeries
8535
- *
8536
- * @param {Highcharts.Series} series
8537
- *
8538
- * @return {boolean|number|undefined}
8539
8587
  */
8540
8588
  function isSkipSeries(series) {
8541
8589
  var a11yOptions = series.chart.options.accessibility,
@@ -8554,13 +8602,7 @@
8554
8602
  }
8555
8603
  /**
8556
8604
  * Determine if navigation for a point should be skipped
8557
- *
8558
8605
  * @private
8559
- * @function isSkipPoint
8560
- *
8561
- * @param {Highcharts.Point} point
8562
- *
8563
- * @return {boolean|number|undefined}
8564
8606
  */
8565
8607
  function isSkipPoint(point) {
8566
8608
  var a11yOptions = point.series.chart.options.accessibility;
@@ -8573,6 +8615,37 @@
8573
8615
  pointA11yDisabled ||
8574
8616
  isSkipSeries(point.series);
8575
8617
  }
8618
+ /**
8619
+ * Get the first point that is not a skip point in this series.
8620
+ * @private
8621
+ */
8622
+ function getFirstValidPointInSeries(series) {
8623
+ var points = series.points || [],
8624
+ len = points.length;
8625
+ for (var i = 0; i < len; ++i) {
8626
+ if (!isSkipPoint(points[i])) {
8627
+ return points[i];
8628
+ }
8629
+ }
8630
+ return null;
8631
+ }
8632
+ /**
8633
+ * Get the first point that is not a skip point in this chart.
8634
+ * @private
8635
+ */
8636
+ function getFirstValidPointInChart(chart) {
8637
+ var series = chart.series || [],
8638
+ len = series.length;
8639
+ for (var i = 0; i < len; ++i) {
8640
+ if (!isSkipSeries(series[i])) {
8641
+ var point = getFirstValidPointInSeries(series[i]);
8642
+ if (point) {
8643
+ return point;
8644
+ }
8645
+ }
8646
+ }
8647
+ return null;
8648
+ }
8576
8649
  /**
8577
8650
  * @private
8578
8651
  */
@@ -8585,7 +8658,7 @@
8585
8658
  // Highlight first valid point in the series will also
8586
8659
  // look backwards. It always starts from currently
8587
8660
  // highlighted point.
8588
- res = chart.series[i].highlightFirstValidPoint();
8661
+ res = chart.series[i].highlightNextValidPoint();
8589
8662
  if (res) {
8590
8663
  break;
8591
8664
  }
@@ -8593,22 +8666,24 @@
8593
8666
  return res;
8594
8667
  }
8595
8668
  /**
8669
+ * After drilling down/up, we need to set focus to the first point for
8670
+ * screen readers and keyboard nav.
8596
8671
  * @private
8597
8672
  */
8598
8673
  function updateChartFocusAfterDrilling(chart) {
8599
- highlightFirstValidPointInChart(chart);
8600
- if (chart.focusElement) {
8601
- chart.focusElement.removeFocusBorder();
8674
+ var point = getFirstValidPointInChart(chart);
8675
+ if (point) {
8676
+ point.highlight(false); // Do not visually highlight
8602
8677
  }
8603
8678
  }
8604
8679
  /**
8680
+ * Highlight the first point in chart that is not a skip point
8605
8681
  * @private
8606
8682
  */
8607
8683
  function highlightFirstValidPointInChart(chart) {
8608
- var res = false;
8609
8684
  delete chart.highlightedPoint;
8610
- res = chart.series.reduce(function (acc, cur) { return acc || cur.highlightFirstValidPoint(); }, false);
8611
- return res;
8685
+ var point = getFirstValidPointInChart(chart);
8686
+ return point ? point.highlight() : false;
8612
8687
  }
8613
8688
  /* *
8614
8689
  *
@@ -8646,7 +8721,7 @@
8646
8721
  e.addEvent(Series, 'destroy', function () {
8647
8722
  return keyboardNavigation.onSeriesDestroy(this);
8648
8723
  });
8649
- e.addEvent(chart, 'afterDrilldown', function () {
8724
+ e.addEvent(chart, 'afterApplyDrilldown', function () {
8650
8725
  updateChartFocusAfterDrilling(this);
8651
8726
  });
8652
8727
  e.addEvent(chart, 'drilldown', function (e) {
@@ -8673,7 +8748,7 @@
8673
8748
  // If then navigating with virtual cursor, it is possible to leave
8674
8749
  // keyboard nav module state on the data points and still activate
8675
8750
  // proxy buttons.
8676
- var focusedElClassName = focusedElement && focusedElement.getAttribute('class');
8751
+ var focusedElClassName = (focusedElement && focusedElement.getAttribute('class'));
8677
8752
  var isProxyFocused = focusedElClassName &&
8678
8753
  focusedElClassName.indexOf('highcharts-a11y-proxy-button') > -1;
8679
8754
  if (chart.highlightedPoint === point &&
@@ -8686,11 +8761,11 @@
8686
8761
  });
8687
8762
  };
8688
8763
  /**
8764
+ * After drillup we want to find the point that was drilled down to and
8765
+ * highlight it.
8689
8766
  * @private
8690
8767
  */
8691
8768
  SeriesKeyboardNavigation.prototype.onDrillupAll = function () {
8692
- // After drillup we want to find the point that was drilled down to and
8693
- // highlight it.
8694
8769
  var last = this.lastDrilledDownPoint,
8695
8770
  chart = this.chart,
8696
8771
  series = last && getSeriesFromName(chart,
@@ -8699,19 +8774,17 @@
8699
8774
  if (last && series && defined(last.x) && defined(last.y)) {
8700
8775
  point = getPointFromXY(series, last.x, last.y);
8701
8776
  }
8777
+ point = point || getFirstValidPointInChart(chart);
8702
8778
  // Container focus can be lost on drillup due to deleted elements.
8703
8779
  if (chart.container) {
8704
8780
  chart.container.focus();
8705
8781
  }
8706
8782
  if (point && point.highlight) {
8707
- point.highlight();
8708
- }
8709
- if (chart.focusElement) {
8710
- chart.focusElement.removeFocusBorder();
8783
+ point.highlight(false); // Do not visually highlight
8711
8784
  }
8712
8785
  };
8713
8786
  /**
8714
- * @return {Highcharts.KeyboardNavigationHandler}
8787
+ * @private
8715
8788
  */
8716
8789
  SeriesKeyboardNavigation.prototype.getKeyboardNavigationHandler = function () {
8717
8790
  var keyboardNavigation = this,
@@ -8752,6 +8825,9 @@
8752
8825
  highlightFirstValidPointInChart(chart);
8753
8826
  return this.response.success;
8754
8827
  },
8828
+ validate: function () {
8829
+ return !!getFirstValidPointInChart(chart);
8830
+ },
8755
8831
  terminate: function () {
8756
8832
  return keyboardNavigation.onHandlerTerminate();
8757
8833
  }
@@ -8802,7 +8878,7 @@
8802
8878
  if (chart.tooltip) {
8803
8879
  chart.tooltip.hide(0);
8804
8880
  }
8805
- var hoverSeries = chart.highlightedPoint && chart.highlightedPoint.series;
8881
+ var hoverSeries = (chart.highlightedPoint && chart.highlightedPoint.series);
8806
8882
  if (hoverSeries && hoverSeries.onMouseOut) {
8807
8883
  hoverSeries.onMouseOut();
8808
8884
  }
@@ -8814,10 +8890,6 @@
8814
8890
  /**
8815
8891
  * Function that attempts to highlight next/prev point. Handles wrap around.
8816
8892
  * @private
8817
- * @param {Highcharts.KeyboardNavigationHandler} handler
8818
- * @param {boolean} directionIsNext
8819
- * @return {number}
8820
- * response
8821
8893
  */
8822
8894
  SeriesKeyboardNavigation.prototype.attemptHighlightAdjacentPoint = function (handler, directionIsNext) {
8823
8895
  var chart = this.chart,
@@ -8825,8 +8897,10 @@
8825
8897
  .wrapAround,
8826
8898
  highlightSuccessful = chart.highlightAdjacentPoint(directionIsNext);
8827
8899
  if (!highlightSuccessful) {
8828
- if (wrapAround) {
8829
- return handler.init(directionIsNext ? 1 : -1);
8900
+ if (wrapAround && (directionIsNext ?
8901
+ highlightFirstValidPointInChart(chart) :
8902
+ highlightLastValidPointInChart(chart))) {
8903
+ return handler.response.success;
8830
8904
  }
8831
8905
  return handler.response[directionIsNext ? 'next' : 'prev'];
8832
8906
  }
@@ -8896,7 +8970,9 @@
8896
8970
  curPointIndex = curPoint && getPointIndex(curPoint) || 0,
8897
8971
  curPoints = curPoint && curPoint.series.points || [],
8898
8972
  lastSeries = chart.series && chart.series[chart.series.length - 1],
8899
- lastPoint = lastSeries && lastSeries.points && lastSeries.points[lastSeries.points.length - 1];
8973
+ lastPoint = lastSeries &&
8974
+ lastSeries.points &&
8975
+ lastSeries.points[lastSeries.points.length - 1];
8900
8976
  var newSeries,
8901
8977
  newPoint;
8902
8978
  // If no points, return false
@@ -8909,8 +8985,7 @@
8909
8985
  newPoint = next ? series[0].points[0] : lastPoint;
8910
8986
  }
8911
8987
  else {
8912
- // We have a highlighted point.
8913
- // Grab next/prev point & series
8988
+ // We have a highlighted point. Grab next/prev point & series.
8914
8989
  newSeries = series[curPoint.series.index + (next ? 1 : -1)];
8915
8990
  newPoint = curPoints[curPointIndex + (next ? 1 : -1)];
8916
8991
  if (!newPoint && newSeries) {
@@ -8970,7 +9045,7 @@
8970
9045
  if (series.yAxis && series.yAxis.reversed) {
8971
9046
  yDistance *= -1;
8972
9047
  }
8973
- if (yDistance <= 0 && down || yDistance >= 0 && !down || // Chk dir
9048
+ if (yDistance <= 0 && down || yDistance >= 0 && !down ||
8974
9049
  distance < 5 || // Points in same spot => infinite loop
8975
9050
  isSkipPoint(point)) {
8976
9051
  return;
@@ -9001,10 +9076,11 @@
9001
9076
  if (!chart.highlightedPoint) {
9002
9077
  newSeries = down ? (chart.series && chart.series[0]) : lastSeries;
9003
9078
  newPoint = down ?
9004
- (newSeries && newSeries.points && newSeries.points[0]) : lastPoint;
9079
+ (newSeries && newSeries.points && newSeries.points[0]) :
9080
+ lastPoint;
9005
9081
  return newPoint ? newPoint.highlight() : false;
9006
9082
  }
9007
- newSeries = chart.series[curPoint.series.index + (down ? -1 : 1)];
9083
+ newSeries = (chart.series[curPoint.series.index + (down ? -1 : 1)]);
9008
9084
  if (!newSeries) {
9009
9085
  return false;
9010
9086
  }
@@ -9018,7 +9094,8 @@
9018
9094
  if (isSkipSeries(newSeries)) {
9019
9095
  // Skip the series
9020
9096
  newPoint.highlight();
9021
- adjacentNewPoint = chart.highlightAdjacentSeries(down); // Try recurse
9097
+ // Try recurse
9098
+ adjacentNewPoint = chart.highlightAdjacentSeries(down);
9022
9099
  if (!adjacentNewPoint) {
9023
9100
  // Recurse failed
9024
9101
  curPoint.highlight();
@@ -9030,7 +9107,7 @@
9030
9107
  // Highlight the new point or any first valid point back or forwards
9031
9108
  // from it
9032
9109
  newPoint.highlight();
9033
- return newPoint.series.highlightFirstValidPoint();
9110
+ return newPoint.series.highlightNextValidPoint();
9034
9111
  }
9035
9112
  /**
9036
9113
  * @private
@@ -9040,7 +9117,7 @@
9040
9117
  composedClasses.push(ChartClass);
9041
9118
  var chartProto = ChartClass.prototype;
9042
9119
  chartProto.highlightAdjacentPoint = chartHighlightAdjacentPoint;
9043
- chartProto.highlightAdjacentPointVertical = chartHighlightAdjacentPointVertical;
9120
+ chartProto.highlightAdjacentPointVertical = (chartHighlightAdjacentPointVertical);
9044
9121
  chartProto.highlightAdjacentSeries = chartHighlightAdjacentSeries;
9045
9122
  }
9046
9123
  if (composedClasses.indexOf(PointClass) === -1) {
@@ -9067,7 +9144,7 @@
9067
9144
  seriesTypes[type].prototype.keyboardMoveVertical = false;
9068
9145
  }
9069
9146
  });
9070
- seriesProto.highlightFirstValidPoint = seriesHighlightFirstValidPoint;
9147
+ seriesProto.highlightNextValidPoint = (seriesHighlightNextValidPoint);
9071
9148
  }
9072
9149
  }
9073
9150
  SeriesKeyboardNavigation.compose = compose;
@@ -9105,7 +9182,7 @@
9105
9182
  return defined(minIx) ? series.points[minIx] : void 0;
9106
9183
  }
9107
9184
  /**
9108
- * Highlights a point (show tooltip and display hover state).
9185
+ * Highlights a point (show tooltip, display hover state, focus element).
9109
9186
  *
9110
9187
  * @private
9111
9188
  * @function Highcharts.Point#highlight
@@ -9113,9 +9190,10 @@
9113
9190
  * @return {Highcharts.Point}
9114
9191
  * This highlighted point.
9115
9192
  */
9116
- function pointHighlight() {
9193
+ function pointHighlight(highlightVisually) {
9194
+ if (highlightVisually === void 0) { highlightVisually = true; }
9117
9195
  var chart = this.series.chart;
9118
- if (!this.isNull) {
9196
+ if (!this.isNull && highlightVisually) {
9119
9197
  this.onMouseOver(); // Show the hover marker and tooltip
9120
9198
  }
9121
9199
  else {
@@ -9130,6 +9208,9 @@
9130
9208
  // change z-index and mess up the element.
9131
9209
  if (this.graphic) {
9132
9210
  chart.setFocusToElement(this.graphic);
9211
+ if (!highlightVisually && chart.focusElement) {
9212
+ chart.focusElement.removeFocusBorder();
9213
+ }
9133
9214
  }
9134
9215
  chart.highlightedPoint = this;
9135
9216
  return this;
@@ -9140,11 +9221,9 @@
9140
9221
  * point in the series, use that as starting point.
9141
9222
  *
9142
9223
  * @private
9143
- * @function Highcharts.Series#highlightFirstValidPoint
9144
- *
9145
- * @return {boolean|Highcharts.Point}
9224
+ * @function Highcharts.Series#highlightNextValidPoint
9146
9225
  */
9147
- function seriesHighlightFirstValidPoint() {
9226
+ function seriesHighlightNextValidPoint() {
9148
9227
  var curPoint = this.chart.highlightedPoint,
9149
9228
  start = (curPoint && curPoint.series) === this ?
9150
9229
  getPointIndex(curPoint) :
@@ -9231,7 +9310,7 @@
9231
9310
  * @private
9232
9311
  */
9233
9312
  SeriesComponent.compose = function (ChartClass, PointClass, SeriesClass) {
9234
- // Handle forcing markers
9313
+ NewDataAnnouncer.compose(SeriesClass);
9235
9314
  ForcedMarkers.compose(SeriesClass);
9236
9315
  SeriesKeyboardNavigation.compose(ChartClass, PointClass, SeriesClass);
9237
9316
  };
@@ -9296,13 +9375,14 @@
9296
9375
  };
9297
9376
  /**
9298
9377
  * Get keyboard navigation handler for this component.
9299
- * @return {Highcharts.KeyboardNavigationHandler}
9378
+ * @private
9300
9379
  */
9301
9380
  SeriesComponent.prototype.getKeyboardNavigation = function () {
9302
9381
  return this.keyboardNavigation.getKeyboardNavigationHandler();
9303
9382
  };
9304
9383
  /**
9305
9384
  * Remove traces
9385
+ * @private
9306
9386
  */
9307
9387
  SeriesComponent.prototype.destroy = function () {
9308
9388
  this.newDataAnnouncer.destroy();
@@ -9330,47 +9410,46 @@
9330
9410
  * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
9331
9411
  *
9332
9412
  * */
9413
+ var __extends = (this && this.__extends) || (function () {
9414
+ var extendStatics = function (d,
9415
+ b) {
9416
+ extendStatics = Object.setPrototypeOf ||
9417
+ ({ __proto__: [] } instanceof Array && function (d,
9418
+ b) { d.__proto__ = b; }) ||
9419
+ function (d,
9420
+ b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
9421
+ return extendStatics(d, b);
9422
+ };
9423
+ return function (d, b) {
9424
+ extendStatics(d, b);
9425
+ function __() { this.constructor = d; }
9426
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
9427
+ };
9428
+ })();
9333
9429
  var unhideChartElementFromAT = ChartUtilities.unhideChartElementFromAT;
9334
9430
  var noop = H.noop;
9335
9431
  var attr = U.attr,
9336
9432
  extend = U.extend,
9337
9433
  pick = U.pick;
9338
- /* eslint-disable no-invalid-this, valid-jsdoc */
9434
+ /* *
9435
+ *
9436
+ * Functions
9437
+ *
9438
+ * */
9439
+ /* eslint-disable valid-jsdoc */
9339
9440
  /**
9340
9441
  * @private
9341
9442
  */
9342
9443
  function chartHasMapZoom(chart) {
9343
9444
  return !!(chart.mapZoom &&
9344
- chart.mapNavButtons &&
9345
- chart.mapNavButtons.length);
9445
+ chart.mapNavigation &&
9446
+ chart.mapNavigation.navButtons.length);
9346
9447
  }
9347
- /**
9348
- * Pan along axis in a direction (1 or -1), optionally with a defined
9349
- * granularity (number of steps it takes to walk across current view)
9448
+ /* *
9350
9449
  *
9351
- * @private
9352
- * @function Highcharts.Axis#panStep
9450
+ * Class
9353
9451
  *
9354
- * @param {number} direction
9355
- * @param {number} [granularity]
9356
- */
9357
- H.Axis.prototype.panStep = function (direction, granularity) {
9358
- var gran = granularity || 3;
9359
- var extremes = this.getExtremes();
9360
- var step = (extremes.max - extremes.min) / gran * direction;
9361
- var newMax = extremes.max + step;
9362
- var newMin = extremes.min + step;
9363
- var size = newMax - newMin;
9364
- if (direction < 0 && newMin < extremes.dataMin) {
9365
- newMin = extremes.dataMin;
9366
- newMax = newMin + size;
9367
- }
9368
- else if (direction > 0 && newMax > extremes.dataMax) {
9369
- newMax = extremes.dataMax;
9370
- newMin = newMax - size;
9371
- }
9372
- this.setExtremes(newMin, newMax);
9373
- };
9452
+ * */
9374
9453
  /**
9375
9454
  * The ZoomComponent class
9376
9455
  *
@@ -9378,44 +9457,59 @@
9378
9457
  * @class
9379
9458
  * @name Highcharts.ZoomComponent
9380
9459
  */
9381
- var ZoomComponent = noop;
9382
- ZoomComponent.prototype = new AccessibilityComponent();
9383
- extend(ZoomComponent.prototype, /** @lends Highcharts.ZoomComponent */ {
9460
+ var ZoomComponent = /** @class */ (function (_super) {
9461
+ __extends(ZoomComponent, _super);
9462
+ function ZoomComponent() {
9463
+ /* *
9464
+ *
9465
+ * Properties
9466
+ *
9467
+ * */
9468
+ var _this = _super !== null && _super.apply(this,
9469
+ arguments) || this;
9470
+ _this.focusedMapNavButtonIx = -1;
9471
+ return _this;
9472
+ }
9473
+ /* *
9474
+ *
9475
+ * Functions
9476
+ *
9477
+ * */
9384
9478
  /**
9385
9479
  * Initialize the component
9386
9480
  */
9387
- init: function () {
9481
+ ZoomComponent.prototype.init = function () {
9388
9482
  var component = this,
9389
9483
  chart = this.chart;
9390
9484
  this.proxyProvider.addGroup('zoom', 'div');
9391
9485
  [
9392
- 'afterShowResetZoom', 'afterDrilldown', 'drillupall'
9486
+ 'afterShowResetZoom', 'afterApplyDrilldown', 'drillupall'
9393
9487
  ].forEach(function (eventType) {
9394
9488
  component.addEvent(chart, eventType, function () {
9395
9489
  component.updateProxyOverlays();
9396
9490
  });
9397
9491
  });
9398
- },
9492
+ };
9399
9493
  /**
9400
9494
  * Called when chart is updated
9401
9495
  */
9402
- onChartUpdate: function () {
9496
+ ZoomComponent.prototype.onChartUpdate = function () {
9403
9497
  var chart = this.chart,
9404
9498
  component = this;
9405
9499
  // Make map zoom buttons accessible
9406
- if (chart.mapNavButtons) {
9407
- chart.mapNavButtons.forEach(function (button, i) {
9500
+ if (chart.mapNavigation) {
9501
+ chart.mapNavigation.navButtons.forEach(function (button, i) {
9408
9502
  unhideChartElementFromAT(chart, button.element);
9409
9503
  component.setMapNavButtonAttrs(button.element, 'accessibility.zoom.mapZoom' + (i ? 'Out' : 'In'));
9410
9504
  });
9411
9505
  }
9412
- },
9506
+ };
9413
9507
  /**
9414
9508
  * @private
9415
9509
  * @param {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement} button
9416
9510
  * @param {string} labelFormatKey
9417
9511
  */
9418
- setMapNavButtonAttrs: function (button, labelFormatKey) {
9512
+ ZoomComponent.prototype.setMapNavButtonAttrs = function (button, labelFormatKey) {
9419
9513
  var chart = this.chart,
9420
9514
  label = chart.langFormat(labelFormatKey, { chart: chart });
9421
9515
  attr(button, {
@@ -9423,51 +9517,54 @@
9423
9517
  role: 'button',
9424
9518
  'aria-label': label
9425
9519
  });
9426
- },
9520
+ };
9427
9521
  /**
9428
9522
  * Update the proxy overlays on every new render to ensure positions are
9429
9523
  * correct.
9430
9524
  */
9431
- onChartRender: function () {
9525
+ ZoomComponent.prototype.onChartRender = function () {
9432
9526
  this.updateProxyOverlays();
9433
- },
9527
+ };
9434
9528
  /**
9435
9529
  * Update proxy overlays, recreating the buttons.
9436
9530
  */
9437
- updateProxyOverlays: function () {
9531
+ ZoomComponent.prototype.updateProxyOverlays = function () {
9438
9532
  var chart = this.chart;
9439
9533
  // Always start with a clean slate
9440
9534
  this.proxyProvider.clearGroup('zoom');
9441
9535
  if (chart.resetZoomButton) {
9442
9536
  this.createZoomProxyButton(chart.resetZoomButton, 'resetZoomProxyButton', chart.langFormat('accessibility.zoom.resetZoomButton', { chart: chart }));
9443
9537
  }
9444
- if (chart.drillUpButton) {
9538
+ if (chart.drillUpButton &&
9539
+ chart.breadcrumbs &&
9540
+ chart.breadcrumbs.list) {
9541
+ var lastBreadcrumb = chart.breadcrumbs.list[chart.breadcrumbs.list.length - 1];
9445
9542
  this.createZoomProxyButton(chart.drillUpButton, 'drillUpProxyButton', chart.langFormat('accessibility.drillUpButton', {
9446
9543
  chart: chart,
9447
- buttonText: chart.getDrilldownBackText()
9544
+ buttonText: chart.breadcrumbs.getButtonText(lastBreadcrumb)
9448
9545
  }));
9449
9546
  }
9450
- },
9547
+ };
9451
9548
  /**
9452
9549
  * @private
9453
9550
  * @param {Highcharts.SVGElement} buttonEl
9454
9551
  * @param {string} buttonProp
9455
9552
  * @param {string} label
9456
9553
  */
9457
- createZoomProxyButton: function (buttonEl, buttonProp, label) {
9554
+ ZoomComponent.prototype.createZoomProxyButton = function (buttonEl, buttonProp, label) {
9458
9555
  this[buttonProp] = this.proxyProvider.addProxyElement('zoom', {
9459
9556
  click: buttonEl
9460
9557
  }, {
9461
9558
  'aria-label': label,
9462
9559
  tabindex: -1
9463
9560
  });
9464
- },
9561
+ };
9465
9562
  /**
9466
9563
  * Get keyboard navigation handler for map zoom.
9467
9564
  * @private
9468
9565
  * @return {Highcharts.KeyboardNavigationHandler} The module object
9469
9566
  */
9470
- getMapZoomNavigation: function () {
9567
+ ZoomComponent.prototype.getMapZoomNavigation = function () {
9471
9568
  var keys = this.keyCodes,
9472
9569
  chart = this.chart,
9473
9570
  component = this;
@@ -9499,14 +9596,14 @@
9499
9596
  return component.onMapNavInit(direction);
9500
9597
  }
9501
9598
  });
9502
- },
9599
+ };
9503
9600
  /**
9504
9601
  * @private
9505
9602
  * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
9506
9603
  * @param {number} keyCode
9507
9604
  * @return {number} Response code
9508
9605
  */
9509
- onMapKbdArrow: function (keyboardNavigationHandler, keyCode) {
9606
+ ZoomComponent.prototype.onMapKbdArrow = function (keyboardNavigationHandler, keyCode) {
9510
9607
  var keys = this.keyCodes,
9511
9608
  panAxis = (keyCode === keys.up || keyCode === keys.down) ?
9512
9609
  'yAxis' : 'xAxis',
@@ -9514,55 +9611,55 @@
9514
9611
  -1 : 1;
9515
9612
  this.chart[panAxis][0].panStep(stepDirection);
9516
9613
  return keyboardNavigationHandler.response.success;
9517
- },
9614
+ };
9518
9615
  /**
9519
9616
  * @private
9520
9617
  * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
9521
9618
  * @param {global.KeyboardEvent} event
9522
9619
  * @return {number} Response code
9523
9620
  */
9524
- onMapKbdTab: function (keyboardNavigationHandler, event) {
9621
+ ZoomComponent.prototype.onMapKbdTab = function (keyboardNavigationHandler, event) {
9525
9622
  var chart = this.chart;
9526
9623
  var response = keyboardNavigationHandler.response;
9527
9624
  var isBackwards = event.shiftKey;
9528
9625
  var isMoveOutOfRange = isBackwards && !this.focusedMapNavButtonIx ||
9529
9626
  !isBackwards && this.focusedMapNavButtonIx;
9530
9627
  // Deselect old
9531
- chart.mapNavButtons[this.focusedMapNavButtonIx].setState(0);
9628
+ chart.mapNavigation.navButtons[this.focusedMapNavButtonIx].setState(0);
9532
9629
  if (isMoveOutOfRange) {
9533
9630
  chart.mapZoom(); // Reset zoom
9534
9631
  return response[isBackwards ? 'prev' : 'next'];
9535
9632
  }
9536
9633
  // Select other button
9537
9634
  this.focusedMapNavButtonIx += isBackwards ? -1 : 1;
9538
- var button = chart.mapNavButtons[this.focusedMapNavButtonIx];
9635
+ var button = chart.mapNavigation.navButtons[this.focusedMapNavButtonIx];
9539
9636
  chart.setFocusToElement(button.box, button.element);
9540
9637
  button.setState(2);
9541
9638
  return response.success;
9542
- },
9639
+ };
9543
9640
  /**
9544
9641
  * @private
9545
9642
  * @param {Highcharts.KeyboardNavigationHandler} keyboardNavigationHandler
9546
9643
  * @return {number} Response code
9547
9644
  */
9548
- onMapKbdClick: function (keyboardNavigationHandler) {
9645
+ ZoomComponent.prototype.onMapKbdClick = function (keyboardNavigationHandler) {
9549
9646
  var el = this.chart.mapNavButtons[this.focusedMapNavButtonIx].element;
9550
9647
  this.fakeClickEvent(el);
9551
9648
  return keyboardNavigationHandler.response.success;
9552
- },
9649
+ };
9553
9650
  /**
9554
9651
  * @private
9555
9652
  * @param {number} direction
9556
9653
  */
9557
- onMapNavInit: function (direction) {
9654
+ ZoomComponent.prototype.onMapNavInit = function (direction) {
9558
9655
  var chart = this.chart,
9559
- zoomIn = chart.mapNavButtons[0],
9560
- zoomOut = chart.mapNavButtons[1],
9656
+ zoomIn = chart.mapNavigation.navButtons[0],
9657
+ zoomOut = chart.mapNavigation.navButtons[1],
9561
9658
  initialButton = direction > 0 ? zoomIn : zoomOut;
9562
9659
  chart.setFocusToElement(initialButton.box, initialButton.element);
9563
9660
  initialButton.setState(2);
9564
9661
  this.focusedMapNavButtonIx = direction > 0 ? 0 : 1;
9565
- },
9662
+ };
9566
9663
  /**
9567
9664
  * Get keyboard navigation handler for a simple chart button. Provide the
9568
9665
  * button reference for the chart, and a function to call on click.
@@ -9571,7 +9668,7 @@
9571
9668
  * @param {string} buttonProp The property on chart referencing the button.
9572
9669
  * @return {Highcharts.KeyboardNavigationHandler} The module object
9573
9670
  */
9574
- simpleButtonNavigation: function (buttonProp, proxyProp, onClick) {
9671
+ ZoomComponent.prototype.simpleButtonNavigation = function (buttonProp, proxyProp, onClick) {
9575
9672
  var keys = this.keyCodes,
9576
9673
  component = this,
9577
9674
  chart = this.chart;
@@ -9580,8 +9677,9 @@
9580
9677
  [
9581
9678
  [keys.tab, keys.up, keys.down, keys.left, keys.right],
9582
9679
  function (keyCode, e) {
9583
- var isBackwards = keyCode === keys.tab && e.shiftKey ||
9584
- keyCode === keys.left || keyCode === keys.up;
9680
+ var isBackwards = (keyCode === keys.tab && e.shiftKey ||
9681
+ keyCode === keys.left ||
9682
+ keyCode === keys.up);
9585
9683
  // Arrow/tab => just move
9586
9684
  return this.response[isBackwards ? 'prev' : 'next'];
9587
9685
  }
@@ -9605,13 +9703,13 @@
9605
9703
  chart.setFocusToElement(chart[buttonProp].box, component[proxyProp].buttonElement);
9606
9704
  }
9607
9705
  });
9608
- },
9706
+ };
9609
9707
  /**
9610
9708
  * Get keyboard navigation handlers for this component.
9611
9709
  * @return {Array<Highcharts.KeyboardNavigationHandler>}
9612
9710
  * List of module objects
9613
9711
  */
9614
- getKeyboardNavigation: function () {
9712
+ ZoomComponent.prototype.getKeyboardNavigation = function () {
9615
9713
  return [
9616
9714
  this.simpleButtonNavigation('resetZoomButton', 'resetZoomProxyButton', function (_handler, chart) {
9617
9715
  chart.zoomOut();
@@ -9622,8 +9720,75 @@
9622
9720
  }),
9623
9721
  this.getMapZoomNavigation()
9624
9722
  ];
9723
+ };
9724
+ return ZoomComponent;
9725
+ }(AccessibilityComponent));
9726
+ /* *
9727
+ *
9728
+ * Class Namespace
9729
+ *
9730
+ * */
9731
+ (function (ZoomComponent) {
9732
+ /* *
9733
+ *
9734
+ * Declarations
9735
+ *
9736
+ * */
9737
+ /* *
9738
+ *
9739
+ * Constants
9740
+ *
9741
+ * */
9742
+ ZoomComponent.composedClasses = [];
9743
+ /* *
9744
+ *
9745
+ * Functions
9746
+ *
9747
+ * */
9748
+ /**
9749
+ * @private
9750
+ */
9751
+ function compose(AxisClass) {
9752
+ if (ZoomComponent.composedClasses.indexOf(AxisClass) === -1) {
9753
+ ZoomComponent.composedClasses.push(AxisClass);
9754
+ var axisProto = AxisClass.prototype;
9755
+ axisProto.panStep = axisPanStep;
9756
+ }
9625
9757
  }
9626
- });
9758
+ ZoomComponent.compose = compose;
9759
+ /**
9760
+ * Pan along axis in a direction (1 or -1), optionally with a defined
9761
+ * granularity (number of steps it takes to walk across current view)
9762
+ *
9763
+ * @private
9764
+ * @function Highcharts.Axis#panStep
9765
+ *
9766
+ * @param {number} direction
9767
+ * @param {number} [granularity]
9768
+ */
9769
+ function axisPanStep(direction, granularity) {
9770
+ var gran = granularity || 3;
9771
+ var extremes = this.getExtremes();
9772
+ var step = (extremes.max - extremes.min) / gran * direction;
9773
+ var newMax = extremes.max + step;
9774
+ var newMin = extremes.min + step;
9775
+ var size = newMax - newMin;
9776
+ if (direction < 0 && newMin < extremes.dataMin) {
9777
+ newMin = extremes.dataMin;
9778
+ newMax = newMin + size;
9779
+ }
9780
+ else if (direction > 0 && newMax > extremes.dataMax) {
9781
+ newMax = extremes.dataMax;
9782
+ newMin = newMax - size;
9783
+ }
9784
+ this.setExtremes(newMin, newMax);
9785
+ }
9786
+ })(ZoomComponent || (ZoomComponent = {}));
9787
+ /* *
9788
+ *
9789
+ * Default Export
9790
+ *
9791
+ * */
9627
9792
 
9628
9793
  return ZoomComponent;
9629
9794
  });
@@ -9663,7 +9828,8 @@
9663
9828
  // Test BG image for IE
9664
9829
  if (isMS && win.getComputedStyle) {
9665
9830
  var testDiv = doc.createElement('div');
9666
- var imageSrc = 'data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==';
9831
+ var imageSrc = 'data:image/gif;base64,' +
9832
+ 'R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==';
9667
9833
  testDiv.style.backgroundImage = "url(" + imageSrc + ")"; // #13071
9668
9834
  doc.body.appendChild(testDiv);
9669
9835
  var bi = (testDiv.currentStyle ||
@@ -9671,8 +9837,8 @@
9671
9837
  doc.body.removeChild(testDiv);
9672
9838
  return bi === 'none';
9673
9839
  }
9674
- // Not used for other browsers
9675
- return false;
9840
+ // Other browsers use the forced-colors standard
9841
+ return win.matchMedia && win.matchMedia('(forced-colors: active)').matches;
9676
9842
  }
9677
9843
  /**
9678
9844
  * Force high contrast theme for the chart. The default theme is defined in
@@ -10860,9 +11026,9 @@
10860
11026
  */
10861
11027
  annotations: {
10862
11028
  heading: 'Chart annotations summary',
10863
- descriptionSinglePoint: '{annotationText}. Related to {annotationPoint}',
10864
- descriptionMultiplePoints: '{annotationText}. Related to {annotationPoint}' +
10865
- '{ Also related to, #each(additionalAnnotationPoints)}',
11029
+ descriptionSinglePoint: ('{annotationText}. Related to {annotationPoint}'),
11030
+ descriptionMultiplePoints: ('{annotationText}. Related to {annotationPoint}' +
11031
+ '{ Also related to, #each(additionalAnnotationPoints)}'),
10866
11032
  descriptionNoPoints: '{annotationText}'
10867
11033
  },
10868
11034
  /**
@@ -11229,7 +11395,8 @@
11229
11395
  if (typeof val !== 'undefined') {
11230
11396
  traverseSetOption(rootNew, mapToNewOptions[oldOptionKey], val);
11231
11397
  error(32, false, chart, (_a = {},
11232
- _a[rootOldAsArray.join('.') + "." + oldOptionKey] = rootNewAsArray.join('.') + "." + mapToNewOptions[oldOptionKey].join('.'),
11398
+ _a[rootOldAsArray.join('.') + '.' + oldOptionKey] = (rootNewAsArray.join('.') + '.' +
11399
+ mapToNewOptions[oldOptionKey].join('.')),
11233
11400
  _a));
11234
11401
  }
11235
11402
  });
@@ -11257,7 +11424,9 @@
11257
11424
  if (opts && opts.description) {
11258
11425
  opts.accessibility = opts.accessibility || {};
11259
11426
  opts.accessibility.description = opts.description;
11260
- error(32, false, chart, { 'axis.description': 'use axis.accessibility.description' });
11427
+ error(32, false, chart, {
11428
+ 'axis.description': 'use axis.accessibility.description'
11429
+ });
11261
11430
  }
11262
11431
  });
11263
11432
  }
@@ -11287,8 +11456,9 @@
11287
11456
  var optionVal = series.options[oldOption];
11288
11457
  // Special case
11289
11458
  if (oldOption === 'accessibility.pointDescriptionFormatter') {
11290
- optionVal = series.options.accessibility &&
11291
- series.options.accessibility.pointDescriptionFormatter;
11459
+ optionVal = (series.options.accessibility &&
11460
+ series.options.accessibility
11461
+ .pointDescriptionFormatter);
11292
11462
  }
11293
11463
  if (typeof optionVal !== 'undefined') {
11294
11464
  // Set the new option
@@ -11297,7 +11467,10 @@
11297
11467
  // value, since we set enabled rather than disabled
11298
11468
  oldOption === 'skipKeyboardNavigation' ?
11299
11469
  !optionVal : optionVal);
11300
- error(32, false, chart, (_a = {}, _a["series." + oldOption] = "series." + oldToNewSeriesOptions[oldOption].join('.'), _a));
11470
+ error(32, false, chart, (_a = {},
11471
+ _a["series." + oldOption] = ('series.' +
11472
+ oldToNewSeriesOptions[oldOption].join('.')),
11473
+ _a));
11301
11474
  }
11302
11475
  });
11303
11476
  });
@@ -11453,7 +11626,6 @@
11453
11626
  this.proxyProvider = new ProxyProvider(this.chart);
11454
11627
  this.initComponents();
11455
11628
  this.keyboardNavigation = new KeyboardNavigation(chart, this.components);
11456
- this.update();
11457
11629
  };
11458
11630
  /**
11459
11631
  * @private
@@ -11658,6 +11830,9 @@
11658
11830
  }
11659
11831
  else {
11660
11832
  this.accessibility = a11y = new Accessibility(this);
11833
+ if (a11y && !a11y.zombie) {
11834
+ a11y.update();
11835
+ }
11661
11836
  }
11662
11837
  }
11663
11838
  else if (a11y) {
@@ -11675,13 +11850,17 @@
11675
11850
  /**
11676
11851
  * @private
11677
11852
  */
11678
- function compose(ChartClass, PointClass, SeriesClass, SVGElementClass, RangeSelectorClass) {
11679
- A11yI18n.compose(ChartClass);
11680
- FocusBorder.compose(ChartClass, SVGElementClass);
11853
+ function compose(AxisClass, ChartClass, LegendClass, PointClass, SeriesClass, SVGElementClass, RangeSelectorClass) {
11854
+ // ordered:
11681
11855
  KeyboardNavigation.compose(ChartClass);
11682
- MenuComponent.compose(ChartClass);
11683
11856
  NewDataAnnouncer.compose(SeriesClass);
11857
+ LegendComponent.compose(ChartClass, LegendClass);
11858
+ MenuComponent.compose(ChartClass);
11684
11859
  SeriesComponent.compose(ChartClass, PointClass, SeriesClass);
11860
+ ZoomComponent.compose(AxisClass);
11861
+ // RangeSelector
11862
+ A11yI18n.compose(ChartClass);
11863
+ FocusBorder.compose(ChartClass, SVGElementClass);
11685
11864
  if (RangeSelectorClass) {
11686
11865
  RangeSelectorComponent.compose(ChartClass, RangeSelectorClass);
11687
11866
  }
@@ -11699,7 +11878,7 @@
11699
11878
  });
11700
11879
  });
11701
11880
  // Direct updates (events happen after render)
11702
- ['afterDrilldown', 'drillupall'].forEach(function (event) {
11881
+ ['afterApplyDrilldown', 'drillupall'].forEach(function (event) {
11703
11882
  addEvent(ChartClass, event, function chartOnAfterDrilldown() {
11704
11883
  var a11y = this.accessibility;
11705
11884
  if (a11y && !a11y.zombie) {
@@ -11764,7 +11943,7 @@
11764
11943
  G.AccessibilityComponent = AccessibilityComponent;
11765
11944
  G.KeyboardNavigationHandler = KeyboardNavigationHandler;
11766
11945
  G.SeriesAccessibilityDescriber = SeriesDescriber;
11767
- Accessibility.compose(G.Chart, G.Point, G.Series, G.SVGElement, G.RangeSelector);
11946
+ Accessibility.compose(G.Axis, G.Chart, G.Legend, G.Point, G.Series, G.SVGElement, G.RangeSelector);
11768
11947
 
11769
11948
  });
11770
11949
  }));