highcharts 9.2.0 → 9.3.1

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 (755) hide show
  1. package/README.md +13 -6
  2. package/bower.json +1 -1
  3. package/css/annotations/popup.css +48 -8
  4. package/css/annotations/popup.scss +70 -22
  5. package/css/highcharts.css +45 -0
  6. package/css/highcharts.scss +40 -0
  7. package/css/themes/dark-unica.css +45 -0
  8. package/css/themes/grid-light.css +45 -0
  9. package/css/themes/sand-signika.css +45 -0
  10. package/es-modules/Accessibility/A11yI18n.js +273 -224
  11. package/es-modules/Accessibility/Accessibility.js +237 -128
  12. package/es-modules/Accessibility/AccessibilityComponent.js +79 -314
  13. package/es-modules/Accessibility/Components/AnnotationsA11y.js +10 -0
  14. package/es-modules/Accessibility/Components/ContainerComponent.js +52 -27
  15. package/es-modules/Accessibility/Components/InfoRegionsComponent.js +173 -104
  16. package/es-modules/Accessibility/Components/LegendComponent.js +97 -65
  17. package/es-modules/Accessibility/Components/MenuComponent.js +243 -149
  18. package/es-modules/Accessibility/Components/RangeSelectorComponent.js +170 -88
  19. package/es-modules/Accessibility/Components/SeriesComponent/ForcedMarkers.js +152 -115
  20. package/es-modules/Accessibility/Components/SeriesComponent/NewDataAnnouncer.js +133 -68
  21. package/es-modules/Accessibility/Components/SeriesComponent/SeriesComponent.js +64 -27
  22. package/es-modules/Accessibility/Components/SeriesComponent/SeriesDescriber.js +38 -21
  23. package/es-modules/Accessibility/Components/SeriesComponent/SeriesKeyboardNavigation.js +380 -325
  24. package/es-modules/Accessibility/Components/ZoomComponent.js +28 -20
  25. package/es-modules/Accessibility/FocusBorder.js +192 -147
  26. package/es-modules/Accessibility/HighContrastMode.js +78 -66
  27. package/es-modules/Accessibility/HighContrastTheme.js +10 -0
  28. package/es-modules/Accessibility/KeyboardNavigation.js +146 -71
  29. package/es-modules/Accessibility/KeyboardNavigationHandler.js +71 -44
  30. package/es-modules/Accessibility/Options/DeprecatedOptions.js +11 -1
  31. package/es-modules/Accessibility/Options/LangOptions.js +1 -2
  32. package/es-modules/Accessibility/Options/Options.js +32 -17
  33. package/es-modules/Accessibility/ProxyElement.js +212 -0
  34. package/es-modules/Accessibility/ProxyProvider.js +305 -0
  35. package/es-modules/Accessibility/Utils/Announcer.js +15 -8
  36. package/es-modules/Accessibility/Utils/ChartUtilities.js +41 -16
  37. package/es-modules/Accessibility/Utils/DOMElementProvider.js +27 -15
  38. package/es-modules/Accessibility/Utils/EventProvider.js +27 -17
  39. package/es-modules/Accessibility/Utils/HTMLUtilities.js +125 -30
  40. package/es-modules/Core/Axis/Axis.js +37 -30
  41. package/es-modules/Core/Axis/AxisDefaults.js +35 -24
  42. package/es-modules/Core/Axis/Color/ColorAxisComposition.js +54 -4
  43. package/es-modules/Core/Axis/Color/ColorAxisDefaults.js +5 -5
  44. package/es-modules/Core/Axis/OrdinalAxis.js +5 -13
  45. package/es-modules/Core/Axis/PlotLineOrBand/PlotLineOrBand.js +4 -5
  46. package/es-modules/Core/Axis/ScrollbarAxis.js +10 -3
  47. package/es-modules/Core/Axis/TreeGridAxis.js +2 -2
  48. package/es-modules/Core/Axis/TreeGridTick.js +1 -2
  49. package/es-modules/Core/Chart/Chart.js +2 -3
  50. package/es-modules/Core/Chart/ChartDefaults.js +3 -4
  51. package/es-modules/Core/Chart/ChartNavigationComposition.js +92 -0
  52. package/es-modules/Core/Chart/MapChart.js +10 -22
  53. package/es-modules/Core/Chart/StockChart.js +3 -293
  54. package/es-modules/Core/Color/Palettes.js +22 -0
  55. package/es-modules/Core/DefaultOptions.js +19 -17
  56. package/es-modules/Core/Foundation.js +39 -31
  57. package/es-modules/Core/Globals.js +1 -1
  58. package/es-modules/Core/HttpUtilities.js +3 -3
  59. package/es-modules/Core/Legend/Legend.js +7 -3
  60. package/es-modules/Core/Navigator.js +7 -8
  61. package/es-modules/Core/Pointer.js +39 -36
  62. package/es-modules/Core/Renderer/HTML/AST.js +3 -6
  63. package/es-modules/Core/Renderer/HTML/HTMLElement.js +23 -18
  64. package/es-modules/Core/Renderer/SVG/SVGElement.js +3 -4
  65. package/es-modules/Core/Renderer/SVG/SVGRenderer.js +21 -18
  66. package/es-modules/Core/Renderer/SVG/TextBuilder.js +17 -13
  67. package/es-modules/Core/ScrollbarDefaults.js +10 -9
  68. package/es-modules/Core/Series/DataLabel.js +2 -3
  69. package/es-modules/Core/Series/Point.js +5 -3
  70. package/es-modules/Core/Series/Series.js +156 -162
  71. package/es-modules/Core/Series/SeriesDefaults.js +3 -4
  72. package/es-modules/Core/Series/SeriesRegistry.js +1 -2
  73. package/es-modules/Core/Tooltip.js +44 -17
  74. package/es-modules/Core/Utilities.js +15 -7
  75. package/es-modules/Data/DataConverter.js +489 -0
  76. package/es-modules/Data/DataPromise.js +252 -0
  77. package/es-modules/Data/DataSeriesConverter.js +203 -0
  78. package/es-modules/Data/DataTable.js +1204 -0
  79. package/es-modules/Data/Modifiers/ChainModifier.js +299 -0
  80. package/es-modules/Data/Modifiers/DataModifier.js +303 -0
  81. package/es-modules/Data/Modifiers/GroupModifier.js +144 -0
  82. package/es-modules/Data/Modifiers/InvertModifier.js +254 -0
  83. package/es-modules/Data/Modifiers/RangeModifier.js +143 -0
  84. package/es-modules/Data/Modifiers/SeriesPointsModifier.js +110 -0
  85. package/es-modules/Data/Modifiers/SortModifier.js +249 -0
  86. package/es-modules/Data/Parsers/CSVParser.js +399 -0
  87. package/es-modules/Data/Parsers/DataParser.js +101 -0
  88. package/es-modules/Data/Parsers/GoogleSheetsParser.js +220 -0
  89. package/es-modules/Data/Parsers/HTMLTableParser.js +213 -0
  90. package/es-modules/Data/Stores/CSVStore.js +317 -0
  91. package/es-modules/Data/Stores/DataStore.js +276 -0
  92. package/es-modules/Data/Stores/GoogleSheetsStore.js +167 -0
  93. package/es-modules/Data/Stores/HTMLTableStore.js +351 -0
  94. package/es-modules/Extensions/Annotations/Annotations.js +61 -11
  95. package/es-modules/Extensions/Annotations/ControlPoint.js +1 -1
  96. package/es-modules/Extensions/Annotations/Controllables/ControllableEllipse.js +199 -0
  97. package/es-modules/Extensions/Annotations/Mixins/ControllableMixin.js +7 -1
  98. package/es-modules/Extensions/Annotations/NavigationBindings.js +90 -28
  99. package/es-modules/Extensions/Annotations/Popup.js +479 -141
  100. package/es-modules/Extensions/Annotations/Types/BasicAnnotation.js +51 -2
  101. package/es-modules/Extensions/Annotations/Types/CrookedLine.js +1 -1
  102. package/es-modules/Extensions/Annotations/Types/Fibonacci.js +2 -3
  103. package/es-modules/Extensions/Annotations/Types/FibonacciTimeZones.js +219 -0
  104. package/es-modules/Extensions/Annotations/Types/InfinityLine.js +1 -1
  105. package/es-modules/Extensions/Annotations/Types/Measure.js +14 -8
  106. package/es-modules/Extensions/Annotations/Types/Pitchfork.js +5 -5
  107. package/es-modules/Extensions/Annotations/Types/TimeCycles.js +207 -0
  108. package/es-modules/Extensions/Annotations/Types/Tunnel.js +3 -5
  109. package/es-modules/Extensions/Annotations/Types/VerticalLine.js +1 -1
  110. package/es-modules/Extensions/Boost/BoostOptions.js +2 -2
  111. package/es-modules/Extensions/Boost/BoostOverrides.js +3 -1
  112. package/es-modules/Extensions/Boost/WGLShader.js +4 -3
  113. package/es-modules/Extensions/BoostCanvas.js +1 -2
  114. package/es-modules/Extensions/CurrentDateIndication.js +2 -3
  115. package/es-modules/Extensions/Data.js +73 -67
  116. package/es-modules/Extensions/DataGrouping.js +33 -18
  117. package/es-modules/Extensions/Debugger/ErrorMessages.js +2 -2
  118. package/es-modules/Extensions/DownloadURL.js +2 -2
  119. package/es-modules/Extensions/DragPanes.js +1 -2
  120. package/es-modules/Extensions/Drilldown.js +2 -3
  121. package/es-modules/Extensions/Exporting/Exporting.js +12 -11
  122. package/es-modules/Extensions/Exporting/ExportingDefaults.js +8 -15
  123. package/es-modules/Extensions/GeoJSON.js +39 -63
  124. package/es-modules/Extensions/MarkerClusters.js +115 -97
  125. package/es-modules/Extensions/NoDataToDisplay.js +1 -2
  126. package/es-modules/Extensions/OfflineExporting/OfflineExporting.js +10 -9
  127. package/es-modules/Extensions/OfflineExporting/OfflineExportingDefaults.js +1 -1
  128. package/es-modules/Extensions/Oldie/Oldie.js +2 -3
  129. package/es-modules/Extensions/Pane.js +5 -6
  130. package/es-modules/Extensions/Polar.js +1 -1
  131. package/es-modules/Extensions/RangeSelector.js +3 -4
  132. package/es-modules/Extensions/Sonification/ChartSonify.js +247 -637
  133. package/es-modules/Extensions/Sonification/Earcon.js +136 -102
  134. package/es-modules/Extensions/Sonification/Instrument.js +496 -426
  135. package/es-modules/Extensions/Sonification/MusicalFrequencies.js +10 -0
  136. package/es-modules/Extensions/Sonification/Options.js +10 -0
  137. package/es-modules/Extensions/Sonification/PointSonify.js +203 -152
  138. package/es-modules/Extensions/Sonification/SeriesSonify.js +459 -0
  139. package/es-modules/Extensions/Sonification/SignalHandler.js +124 -0
  140. package/es-modules/Extensions/Sonification/Sonification.js +26 -52
  141. package/es-modules/Extensions/Sonification/{Utilities.js → SonificationUtilities.js} +62 -84
  142. package/es-modules/Extensions/Sonification/Timeline.js +255 -567
  143. package/es-modules/Extensions/Sonification/TimelineEvent.js +158 -0
  144. package/es-modules/Extensions/Sonification/TimelinePath.js +311 -0
  145. package/es-modules/Maps/MapNavigation.js +27 -64
  146. package/es-modules/Maps/MapNavigationOptionsDefault.js +3 -0
  147. package/es-modules/Maps/MapPointer.js +7 -5
  148. package/es-modules/Maps/MapView.js +450 -0
  149. package/es-modules/Maps/MapViewOptionsDefault.js +97 -0
  150. package/es-modules/Maps/Projection.js +436 -0
  151. package/es-modules/Maps/ProjectionDefinition.js +9 -0
  152. package/es-modules/Maps/Projections/EqualEarth.js +42 -0
  153. package/es-modules/Maps/Projections/LambertConformalConic.js +52 -0
  154. package/es-modules/Maps/Projections/Miller.js +16 -0
  155. package/es-modules/Maps/Projections/Orthographic.js +26 -0
  156. package/es-modules/Maps/Projections/ProjectionRegistry.js +19 -0
  157. package/es-modules/Maps/Projections/WebMercator.js +24 -0
  158. package/es-modules/Series/AreaRange/AreaRangeSeries.js +4 -5
  159. package/es-modules/Series/Bellcurve/BellcurveSeries.js +2 -8
  160. package/es-modules/Series/BoxPlot/BoxPlotSeries.js +1 -2
  161. package/es-modules/Series/Bubble/BubbleLegendDefaults.js +1 -2
  162. package/es-modules/Series/Bubble/BubbleLegendItem.js +3 -3
  163. package/es-modules/Series/Bubble/BubblePoint.js +5 -0
  164. package/es-modules/Series/Bubble/BubbleSeries.js +90 -50
  165. package/es-modules/Series/Candlestick/CandlestickSeries.js +10 -18
  166. package/es-modules/{Mixins/CenteredSeries.js → Series/CenteredUtilities.js} +45 -23
  167. package/es-modules/Series/ColorMapComposition.js +109 -0
  168. package/es-modules/Series/Column/ColumnDataLabel.js +5 -5
  169. package/es-modules/Series/Column/ColumnSeries.js +3 -4
  170. package/es-modules/Series/ColumnPyramid/ColumnPyramidSeries.js +6 -6
  171. package/es-modules/Series/DataModifyComposition.js +539 -0
  172. package/es-modules/Series/DependencyWheel/DependencyWheelPoint.js +2 -6
  173. package/es-modules/Series/DerivedComposition.js +137 -0
  174. package/es-modules/Series/DrawPointComposition.js +111 -0
  175. package/es-modules/Series/Dumbbell/DumbbellSeries.js +2 -3
  176. package/es-modules/Series/ErrorBar/ErrorBarSeries.js +1 -2
  177. package/es-modules/Series/Flags/FlagsSeries.js +18 -25
  178. package/es-modules/Series/Funnel/FunnelSeries.js +6 -5
  179. package/es-modules/Series/Gantt/GanttSeries.js +0 -2
  180. package/es-modules/Series/Gauge/GaugePoint.js +1 -1
  181. package/es-modules/Series/Gauge/GaugeSeries.js +7 -7
  182. package/es-modules/Series/HLC/HLCPoint.js +55 -0
  183. package/es-modules/Series/HLC/HLCSeries.js +383 -0
  184. package/es-modules/Series/Heatmap/HeatmapPoint.js +3 -4
  185. package/es-modules/Series/Heatmap/HeatmapSeries.js +19 -6
  186. package/es-modules/Series/HeikinAshi/HeikinAshiSeries.js +2 -3
  187. package/es-modules/Series/Histogram/HistogramSeries.js +3 -7
  188. package/es-modules/Series/HollowCandlestick/HollowCandlestickPoint.js +2 -2
  189. package/es-modules/Series/HollowCandlestick/HollowCandlestickSeries.js +33 -34
  190. package/es-modules/Series/Line/LineSeries.js +1 -2
  191. package/es-modules/Series/Map/MapPoint.js +23 -16
  192. package/es-modules/Series/Map/MapSeries.js +271 -309
  193. package/es-modules/Series/MapBubble/MapBubblePoint.js +0 -3
  194. package/es-modules/Series/MapBubble/MapBubbleSeries.js +10 -1
  195. package/es-modules/Series/MapLine/MapLineSeries.js +2 -0
  196. package/es-modules/Series/MapPoint/MapPointPoint.js +5 -1
  197. package/es-modules/Series/MapPoint/MapPointSeries.js +99 -14
  198. package/es-modules/Series/Networkgraph/Networkgraph.js +5 -5
  199. package/es-modules/{Mixins/Nodes.js → Series/NodesComposition.js} +76 -29
  200. package/es-modules/Series/OHLC/OHLCPoint.js +2 -6
  201. package/es-modules/Series/OHLC/OHLCSeries.js +55 -183
  202. package/es-modules/{Mixins/OnSeries.js → Series/OnSeriesComposition.js} +53 -21
  203. package/es-modules/Series/Organization/OrganizationSeries.js +2 -3
  204. package/es-modules/Series/PackedBubble/PackedBubbleSeries.js +46 -6
  205. package/es-modules/Series/ParetoSeries/ParetoSeries.js +3 -7
  206. package/es-modules/Series/Pie/PieDataLabel.js +1 -2
  207. package/es-modules/Series/Pie/PieSeries.js +6 -7
  208. package/es-modules/Series/Sankey/SankeyPoint.js +0 -4
  209. package/es-modules/Series/Sankey/SankeySeries.js +89 -20
  210. package/es-modules/Series/Sunburst/SunburstPoint.js +2 -3
  211. package/es-modules/Series/Sunburst/SunburstSeries.js +4 -4
  212. package/es-modules/Series/Tilemap/TilemapPoint.js +2 -3
  213. package/es-modules/Series/Timeline/TimelineSeries.js +3 -4
  214. package/es-modules/{Mixins/TreeSeries.js → Series/TreeUtilities.js} +86 -76
  215. package/es-modules/Series/Treemap/TreemapPoint.js +2 -2
  216. package/es-modules/Series/Treemap/TreemapSeries.js +8 -8
  217. package/es-modules/Series/Venn/VennPoint.js +16 -7
  218. package/es-modules/Series/Venn/VennSeries.js +5 -8
  219. package/es-modules/Series/Venn/VennUtils.js +550 -439
  220. package/es-modules/Series/Waterfall/WaterfallSeries.js +2 -3
  221. package/es-modules/Series/Windbarb/WindbarbSeries.js +23 -24
  222. package/es-modules/Series/Wordcloud/WordcloudPoint.js +8 -6
  223. package/es-modules/Series/Wordcloud/WordcloudSeries.js +24 -20
  224. package/es-modules/Series/Wordcloud/WordcloudUtils.js +673 -484
  225. package/es-modules/Series/XRange/XRangePoint.js +1 -0
  226. package/es-modules/Stock/Indicators/ABands/ABandsIndicator.js +3 -6
  227. package/es-modules/Stock/Indicators/AO/AOIndicator.js +2 -3
  228. package/es-modules/Stock/Indicators/APO/APOIndicator.js +14 -20
  229. package/es-modules/Stock/Indicators/Aroon/AroonIndicator.js +3 -6
  230. package/es-modules/Stock/Indicators/AroonOscillator/AroonOscillatorIndicator.js +11 -13
  231. package/es-modules/Stock/Indicators/ArrayUtilities.js +47 -0
  232. package/es-modules/Stock/Indicators/BB/BBIndicator.js +27 -11
  233. package/es-modules/Stock/Indicators/Chaikin/ChaikinIndicator.js +6 -12
  234. package/es-modules/Stock/Indicators/DEMA/DEMAIndicator.js +1 -11
  235. package/es-modules/Stock/Indicators/DMI/DMIIndicator.js +19 -11
  236. package/es-modules/Stock/Indicators/DisparityIndex/DisparityIndexIndicator.js +17 -11
  237. package/es-modules/Stock/Indicators/EMA/EMAIndicator.js +1 -3
  238. package/es-modules/Stock/Indicators/KeltnerChannels/KeltnerChannelsIndicator.js +11 -9
  239. package/es-modules/Stock/Indicators/Klinger/KlingerIndicator.js +8 -16
  240. package/es-modules/Stock/Indicators/LinearRegression/LinearRegression.js +2 -2
  241. package/es-modules/Stock/Indicators/LinearRegressionAngle/LinearRegressionAngle.js +2 -2
  242. package/es-modules/Stock/Indicators/LinearRegressionIntercept/LinearRegressionIntercept.js +2 -2
  243. package/es-modules/Stock/Indicators/LinearRegressionSlopes/LinearRegressionSlopes.js +2 -2
  244. package/es-modules/Stock/Indicators/MACD/MACDIndicator.js +1 -2
  245. package/es-modules/{Mixins/MultipleLines.js → Stock/Indicators/MultipleLinesComposition.js} +136 -87
  246. package/es-modules/Stock/Indicators/NATR/NATRIndicator.js +1 -3
  247. package/es-modules/Stock/Indicators/PC/PCIndicator.js +14 -13
  248. package/es-modules/Stock/Indicators/PPO/PPOIndicator.js +1 -11
  249. package/es-modules/Stock/Indicators/SMA/SMAComposition.js +0 -26
  250. package/es-modules/Stock/Indicators/SMA/SMAIndicator.js +32 -49
  251. package/es-modules/Stock/Indicators/SlowStochastic/SlowStochasticIndicator.js +0 -8
  252. package/es-modules/Stock/Indicators/Stochastic/StochasticIndicator.js +15 -8
  253. package/es-modules/Stock/Indicators/Supertrend/SupertrendIndicator.js +4 -6
  254. package/es-modules/Stock/Indicators/TEMA/TEMAIndicator.js +26 -11
  255. package/es-modules/Stock/Indicators/TRIX/TRIXIndicator.js +6 -12
  256. package/es-modules/Stock/Indicators/VBP/VBPIndicator.js +23 -7
  257. package/es-modules/Stock/Indicators/WilliamsR/WilliamsRIndicator.js +2 -3
  258. package/es-modules/Stock/StockToolsBindings.js +144 -42
  259. package/es-modules/Stock/StockToolsGui.js +409 -15
  260. package/es-modules/masters/highcharts-3d.src.js +1 -1
  261. package/es-modules/masters/highcharts-gantt.src.js +1 -1
  262. package/es-modules/masters/highcharts-more.src.js +1 -1
  263. package/es-modules/masters/highcharts.src.js +1 -1
  264. package/es-modules/masters/highmaps.src.js +1 -1
  265. package/es-modules/masters/highstock.src.js +1 -1
  266. package/es-modules/masters/indicators/acceleration-bands.src.js +1 -1
  267. package/es-modules/masters/indicators/accumulation-distribution.src.js +1 -1
  268. package/es-modules/masters/indicators/ao.src.js +1 -1
  269. package/es-modules/masters/indicators/apo.src.js +1 -1
  270. package/es-modules/masters/indicators/aroon-oscillator.src.js +1 -1
  271. package/es-modules/masters/indicators/aroon.src.js +1 -1
  272. package/es-modules/masters/indicators/atr.src.js +1 -1
  273. package/es-modules/masters/indicators/bollinger-bands.src.js +1 -1
  274. package/es-modules/masters/indicators/cci.src.js +1 -1
  275. package/es-modules/masters/indicators/chaikin.src.js +1 -1
  276. package/es-modules/masters/indicators/cmf.src.js +1 -1
  277. package/es-modules/masters/indicators/cmo.src.js +1 -1
  278. package/es-modules/masters/indicators/dema.src.js +1 -1
  279. package/es-modules/masters/indicators/disparity-index.src.js +1 -1
  280. package/es-modules/masters/indicators/dmi.src.js +1 -1
  281. package/es-modules/masters/indicators/dpo.src.js +1 -1
  282. package/es-modules/masters/indicators/ema.src.js +4 -10
  283. package/es-modules/masters/indicators/ichimoku-kinko-hyo.src.js +1 -1
  284. package/es-modules/masters/indicators/indicators-all.src.js +2 -2
  285. package/es-modules/masters/indicators/indicators.src.js +2 -1
  286. package/es-modules/masters/indicators/keltner-channels.src.js +1 -1
  287. package/es-modules/masters/indicators/klinger.src.js +1 -1
  288. package/es-modules/masters/indicators/macd.src.js +1 -1
  289. package/es-modules/masters/indicators/mfi.src.js +1 -1
  290. package/es-modules/masters/indicators/momentum.src.js +1 -1
  291. package/es-modules/masters/indicators/natr.src.js +1 -1
  292. package/es-modules/masters/indicators/obv.src.js +1 -1
  293. package/es-modules/masters/indicators/pivot-points.src.js +1 -1
  294. package/es-modules/masters/indicators/ppo.src.js +1 -1
  295. package/es-modules/masters/indicators/price-channel.src.js +1 -1
  296. package/es-modules/masters/indicators/price-envelopes.src.js +1 -1
  297. package/es-modules/masters/indicators/psar.src.js +1 -1
  298. package/es-modules/masters/indicators/regressions.src.js +1 -1
  299. package/es-modules/masters/indicators/roc.src.js +1 -1
  300. package/es-modules/masters/indicators/rsi.src.js +1 -1
  301. package/es-modules/masters/indicators/slow-stochastic.src.js +1 -1
  302. package/es-modules/masters/indicators/stochastic.src.js +1 -1
  303. package/es-modules/masters/indicators/supertrend.src.js +1 -1
  304. package/es-modules/masters/indicators/tema.src.js +1 -1
  305. package/es-modules/masters/indicators/trendline.src.js +1 -1
  306. package/es-modules/masters/indicators/trix.src.js +1 -1
  307. package/es-modules/masters/indicators/volume-by-price.src.js +1 -1
  308. package/es-modules/masters/indicators/vwap.src.js +1 -1
  309. package/es-modules/masters/indicators/williams-r.src.js +1 -1
  310. package/es-modules/masters/indicators/wma.src.js +1 -1
  311. package/es-modules/masters/indicators/zigzag.src.js +1 -1
  312. package/es-modules/masters/modules/accessibility.src.js +16 -2
  313. package/es-modules/masters/modules/annotations-advanced.src.js +3 -1
  314. package/es-modules/masters/modules/annotations.src.js +1 -1
  315. package/es-modules/masters/modules/arrow-symbols.src.js +1 -1
  316. package/es-modules/masters/modules/boost-canvas.src.js +1 -1
  317. package/es-modules/masters/modules/boost.src.js +1 -1
  318. package/es-modules/masters/modules/broken-axis.src.js +1 -1
  319. package/es-modules/masters/modules/bullet.src.js +1 -1
  320. package/es-modules/masters/modules/coloraxis.src.js +1 -1
  321. package/es-modules/masters/modules/current-date-indicator.src.js +1 -1
  322. package/es-modules/masters/modules/cylinder.src.js +1 -1
  323. package/es-modules/masters/modules/data.src.js +6 -3
  324. package/es-modules/masters/modules/datagrouping.src.js +1 -1
  325. package/es-modules/masters/modules/debugger.src.js +1 -1
  326. package/es-modules/masters/modules/dependency-wheel.src.js +1 -1
  327. package/es-modules/masters/modules/dotplot.src.js +1 -1
  328. package/es-modules/masters/modules/drag-panes.src.js +1 -1
  329. package/es-modules/masters/modules/draggable-points.src.js +1 -1
  330. package/es-modules/masters/modules/drilldown.src.js +1 -1
  331. package/es-modules/masters/modules/dumbbell.src.js +1 -1
  332. package/es-modules/masters/modules/export-data.src.js +1 -1
  333. package/es-modules/masters/modules/exporting.src.js +1 -1
  334. package/es-modules/masters/modules/full-screen.src.js +1 -1
  335. package/es-modules/masters/modules/funnel.src.js +1 -1
  336. package/es-modules/masters/modules/funnel3d.src.js +1 -1
  337. package/es-modules/masters/modules/gantt.src.js +1 -1
  338. package/es-modules/masters/modules/grid-axis.src.js +1 -1
  339. package/es-modules/masters/modules/heatmap.src.js +1 -2
  340. package/es-modules/masters/modules/heikinashi.src.js +1 -1
  341. package/es-modules/masters/modules/histogram-bellcurve.src.js +1 -1
  342. package/es-modules/masters/modules/hollowcandlestick.src.js +1 -1
  343. package/es-modules/masters/modules/item-series.src.js +1 -1
  344. package/es-modules/masters/modules/lollipop.src.js +1 -1
  345. package/es-modules/masters/modules/map.src.js +1 -3
  346. package/es-modules/masters/modules/marker-clusters.src.js +1 -1
  347. package/es-modules/masters/modules/networkgraph.src.js +1 -1
  348. package/es-modules/masters/modules/no-data-to-display.src.js +1 -1
  349. package/es-modules/masters/modules/offline-exporting.src.js +1 -1
  350. package/es-modules/masters/modules/oldie-polyfills.src.js +1 -1
  351. package/es-modules/masters/modules/oldie.src.js +1 -1
  352. package/es-modules/masters/modules/organization.src.js +1 -1
  353. package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
  354. package/es-modules/masters/modules/parallel-coordinates.src.js +1 -1
  355. package/es-modules/masters/modules/pareto.src.js +1 -1
  356. package/es-modules/masters/modules/pathfinder.src.js +1 -1
  357. package/es-modules/masters/modules/pattern-fill.src.js +1 -1
  358. package/es-modules/masters/modules/price-indicator.src.js +1 -1
  359. package/es-modules/masters/modules/pyramid3d.src.js +1 -1
  360. package/es-modules/masters/modules/sankey.src.js +1 -1
  361. package/es-modules/masters/modules/series-label.src.js +1 -1
  362. package/es-modules/masters/modules/solid-gauge.src.js +1 -1
  363. package/es-modules/masters/modules/sonification.src.js +33 -2
  364. package/es-modules/masters/modules/static-scale.src.js +1 -1
  365. package/es-modules/masters/modules/stock-tools.src.js +1 -1
  366. package/es-modules/masters/modules/stock.src.js +4 -1
  367. package/es-modules/masters/modules/streamgraph.src.js +1 -1
  368. package/es-modules/masters/modules/sunburst.src.js +1 -1
  369. package/es-modules/masters/modules/tilemap.src.js +1 -1
  370. package/es-modules/masters/modules/timeline.src.js +1 -1
  371. package/es-modules/masters/modules/treegrid.src.js +1 -1
  372. package/es-modules/masters/modules/treemap.src.js +1 -1
  373. package/es-modules/masters/modules/variable-pie.src.js +1 -1
  374. package/es-modules/masters/modules/variwide.src.js +1 -1
  375. package/es-modules/masters/modules/vector.src.js +1 -1
  376. package/es-modules/masters/modules/venn.src.js +1 -1
  377. package/es-modules/masters/modules/windbarb.src.js +1 -1
  378. package/es-modules/masters/modules/wordcloud.src.js +1 -1
  379. package/es-modules/masters/modules/xrange.src.js +1 -1
  380. package/es-modules/masters/themes/avocado.src.js +1 -1
  381. package/es-modules/masters/themes/dark-blue.src.js +1 -1
  382. package/es-modules/masters/themes/dark-green.src.js +1 -1
  383. package/es-modules/masters/themes/dark-unica.src.js +1 -1
  384. package/es-modules/masters/themes/gray.src.js +1 -1
  385. package/es-modules/masters/themes/grid-light.src.js +1 -1
  386. package/es-modules/masters/themes/grid.src.js +1 -1
  387. package/es-modules/masters/themes/high-contrast-dark.src.js +1 -1
  388. package/es-modules/masters/themes/high-contrast-light.src.js +1 -1
  389. package/es-modules/masters/themes/sand-signika.src.js +1 -1
  390. package/es-modules/masters/themes/skies.src.js +1 -1
  391. package/es-modules/masters/themes/sunset.src.js +1 -1
  392. package/highcharts-3d.js +1 -1
  393. package/highcharts-3d.src.js +1 -1
  394. package/highcharts-gantt.js +799 -801
  395. package/highcharts-gantt.js.map +1 -1
  396. package/highcharts-gantt.src.js +793 -755
  397. package/highcharts-more.js +194 -193
  398. package/highcharts-more.js.map +1 -1
  399. package/highcharts-more.src.js +208 -120
  400. package/highcharts.d.ts +9814 -4231
  401. package/highcharts.js +585 -587
  402. package/highcharts.js.map +1 -1
  403. package/highcharts.src.d.ts +9814 -4231
  404. package/highcharts.src.js +626 -603
  405. package/highmaps.js +728 -707
  406. package/highmaps.js.map +1 -1
  407. package/highmaps.src.js +2824 -1613
  408. package/highstock.js +788 -782
  409. package/highstock.js.map +1 -1
  410. package/highstock.src.js +1913 -1284
  411. package/indicators/acceleration-bands.js +10 -9
  412. package/indicators/acceleration-bands.js.map +1 -1
  413. package/indicators/acceleration-bands.src.js +156 -112
  414. package/indicators/accumulation-distribution.js +1 -1
  415. package/indicators/accumulation-distribution.src.js +1 -1
  416. package/indicators/ao.js +6 -6
  417. package/indicators/ao.js.map +1 -1
  418. package/indicators/ao.src.js +4 -4
  419. package/indicators/apo.js +5 -6
  420. package/indicators/apo.js.map +1 -1
  421. package/indicators/apo.src.js +16 -84
  422. package/indicators/aroon-oscillator.js +9 -9
  423. package/indicators/aroon-oscillator.js.map +1 -1
  424. package/indicators/aroon-oscillator.src.js +160 -177
  425. package/indicators/aroon.js +9 -9
  426. package/indicators/aroon.js.map +1 -1
  427. package/indicators/aroon.src.js +156 -112
  428. package/indicators/atr.js +1 -1
  429. package/indicators/atr.src.js +1 -1
  430. package/indicators/bollinger-bands.js +10 -9
  431. package/indicators/bollinger-bands.js.map +1 -1
  432. package/indicators/bollinger-bands.src.js +180 -117
  433. package/indicators/cci.js +1 -1
  434. package/indicators/cci.src.js +1 -1
  435. package/indicators/chaikin.js +8 -9
  436. package/indicators/chaikin.js.map +1 -1
  437. package/indicators/chaikin.src.js +8 -76
  438. package/indicators/cmf.js +1 -1
  439. package/indicators/cmf.src.js +1 -1
  440. package/indicators/cmo.js +1 -1
  441. package/indicators/cmo.src.js +1 -1
  442. package/indicators/dema.js +5 -6
  443. package/indicators/dema.js.map +1 -1
  444. package/indicators/dema.src.js +3 -75
  445. package/indicators/disparity-index.js +6 -7
  446. package/indicators/disparity-index.js.map +1 -1
  447. package/indicators/disparity-index.src.js +19 -74
  448. package/indicators/dmi.js +11 -11
  449. package/indicators/dmi.js.map +1 -1
  450. package/indicators/dmi.src.js +173 -116
  451. package/indicators/dpo.js +1 -1
  452. package/indicators/dpo.src.js +1 -1
  453. package/indicators/ema.js +1 -13
  454. package/indicators/ema.js.map +1 -1
  455. package/indicators/ema.src.js +7 -188
  456. package/indicators/ichimoku-kinko-hyo.js +1 -1
  457. package/indicators/ichimoku-kinko-hyo.src.js +1 -1
  458. package/indicators/indicators-all.js +197 -203
  459. package/indicators/indicators-all.js.map +1 -1
  460. package/indicators/indicators-all.src.js +677 -743
  461. package/indicators/indicators.js +12 -12
  462. package/indicators/indicators.js.map +1 -1
  463. package/indicators/indicators.src.js +213 -143
  464. package/indicators/keltner-channels.js +10 -10
  465. package/indicators/keltner-channels.js.map +1 -1
  466. package/indicators/keltner-channels.src.js +164 -118
  467. package/indicators/klinger.js +12 -13
  468. package/indicators/klinger.js.map +1 -1
  469. package/indicators/klinger.src.js +161 -184
  470. package/indicators/macd.js +2 -2
  471. package/indicators/macd.js.map +1 -1
  472. package/indicators/macd.src.js +2 -3
  473. package/indicators/mfi.js +1 -1
  474. package/indicators/mfi.src.js +1 -1
  475. package/indicators/momentum.js +1 -1
  476. package/indicators/momentum.src.js +1 -1
  477. package/indicators/natr.js +3 -3
  478. package/indicators/natr.js.map +1 -1
  479. package/indicators/natr.src.js +2 -4
  480. package/indicators/obv.js +1 -1
  481. package/indicators/obv.src.js +1 -1
  482. package/indicators/pivot-points.js +1 -1
  483. package/indicators/pivot-points.src.js +1 -1
  484. package/indicators/ppo.js +5 -6
  485. package/indicators/ppo.js.map +1 -1
  486. package/indicators/ppo.src.js +3 -75
  487. package/indicators/price-channel.js +9 -9
  488. package/indicators/price-channel.js.map +1 -1
  489. package/indicators/price-channel.src.js +207 -168
  490. package/indicators/price-envelopes.js +1 -1
  491. package/indicators/price-envelopes.src.js +1 -1
  492. package/indicators/psar.js +1 -1
  493. package/indicators/psar.src.js +1 -1
  494. package/indicators/regressions.js +1 -1
  495. package/indicators/regressions.src.js +9 -9
  496. package/indicators/roc.js +1 -1
  497. package/indicators/roc.src.js +1 -1
  498. package/indicators/rsi.js +1 -1
  499. package/indicators/rsi.src.js +1 -1
  500. package/indicators/slow-stochastic.js +5 -6
  501. package/indicators/slow-stochastic.js.map +1 -1
  502. package/indicators/slow-stochastic.src.js +2 -72
  503. package/indicators/stochastic.js +10 -10
  504. package/indicators/stochastic.js.map +1 -1
  505. package/indicators/stochastic.src.js +209 -164
  506. package/indicators/supertrend.js +10 -10
  507. package/indicators/supertrend.js.map +1 -1
  508. package/indicators/supertrend.src.js +6 -7
  509. package/indicators/tema.js +6 -7
  510. package/indicators/tema.js.map +1 -1
  511. package/indicators/tema.src.js +28 -75
  512. package/indicators/trendline.js +1 -1
  513. package/indicators/trendline.src.js +1 -1
  514. package/indicators/trix.js +4 -5
  515. package/indicators/trix.js.map +1 -1
  516. package/indicators/trix.src.js +8 -76
  517. package/indicators/volume-by-price.js +16 -16
  518. package/indicators/volume-by-price.js.map +1 -1
  519. package/indicators/volume-by-price.src.js +24 -7
  520. package/indicators/vwap.js +1 -1
  521. package/indicators/vwap.src.js +1 -1
  522. package/indicators/williams-r.js +5 -6
  523. package/indicators/williams-r.js.map +1 -1
  524. package/indicators/williams-r.src.js +41 -51
  525. package/indicators/wma.js +1 -1
  526. package/indicators/wma.src.js +1 -1
  527. package/indicators/zigzag.js +1 -1
  528. package/indicators/zigzag.src.js +1 -1
  529. package/modules/accessibility.d.ts +5 -0
  530. package/modules/accessibility.js +237 -216
  531. package/modules/accessibility.js.map +1 -1
  532. package/modules/accessibility.src.d.ts +5 -0
  533. package/modules/accessibility.src.js +7400 -6078
  534. package/modules/annotations-advanced.d.ts +30 -0
  535. package/modules/annotations-advanced.js +192 -165
  536. package/modules/annotations-advanced.js.map +1 -1
  537. package/modules/annotations-advanced.src.d.ts +30 -0
  538. package/modules/annotations-advanced.src.js +1604 -332
  539. package/modules/annotations.js +121 -106
  540. package/modules/annotations.js.map +1 -1
  541. package/modules/annotations.src.js +981 -238
  542. package/modules/arrow-symbols.js +1 -1
  543. package/modules/arrow-symbols.src.js +1 -1
  544. package/modules/boost-canvas.js +15 -15
  545. package/modules/boost-canvas.js.map +1 -1
  546. package/modules/boost-canvas.src.js +3 -3
  547. package/modules/boost.js +79 -79
  548. package/modules/boost.js.map +1 -1
  549. package/modules/boost.src.js +10 -9
  550. package/modules/broken-axis.js +1 -1
  551. package/modules/broken-axis.src.js +1 -1
  552. package/modules/bullet.js +1 -1
  553. package/modules/bullet.src.js +1 -1
  554. package/modules/coloraxis.js +24 -24
  555. package/modules/coloraxis.js.map +1 -1
  556. package/modules/coloraxis.src.js +69 -98
  557. package/modules/current-date-indicator.js +4 -4
  558. package/modules/current-date-indicator.js.map +1 -1
  559. package/modules/current-date-indicator.src.js +4 -4
  560. package/modules/cylinder.js +1 -1
  561. package/modules/cylinder.src.js +1 -1
  562. package/modules/data.js +32 -32
  563. package/modules/data.js.map +1 -1
  564. package/modules/data.src.js +85 -88
  565. package/modules/datagrouping.js +20 -20
  566. package/modules/datagrouping.js.map +1 -1
  567. package/modules/datagrouping.src.js +35 -19
  568. package/modules/debugger.js +3 -3
  569. package/modules/debugger.js.map +1 -1
  570. package/modules/debugger.src.js +3 -3
  571. package/modules/dependency-wheel.js +11 -11
  572. package/modules/dependency-wheel.js.map +1 -1
  573. package/modules/dependency-wheel.src.js +4 -7
  574. package/modules/dotplot.js +1 -1
  575. package/modules/dotplot.src.js +1 -1
  576. package/modules/drag-panes.js +8 -8
  577. package/modules/drag-panes.js.map +1 -1
  578. package/modules/drag-panes.src.js +3 -3
  579. package/modules/draggable-points.js +1 -1
  580. package/modules/draggable-points.src.js +1 -1
  581. package/modules/drilldown.js +24 -24
  582. package/modules/drilldown.js.map +1 -1
  583. package/modules/drilldown.src.js +4 -4
  584. package/modules/dumbbell.js +17 -17
  585. package/modules/dumbbell.js.map +1 -1
  586. package/modules/dumbbell.src.js +4 -4
  587. package/modules/export-data.js +1 -1
  588. package/modules/export-data.js.map +1 -1
  589. package/modules/export-data.src.js +3 -3
  590. package/modules/exporting.js +39 -38
  591. package/modules/exporting.js.map +1 -1
  592. package/modules/exporting.src.js +102 -72
  593. package/modules/full-screen.js +1 -1
  594. package/modules/full-screen.src.js +1 -1
  595. package/modules/funnel.js +12 -12
  596. package/modules/funnel.js.map +1 -1
  597. package/modules/funnel.src.js +9 -6
  598. package/modules/funnel3d.js +1 -1
  599. package/modules/funnel3d.src.js +1 -1
  600. package/modules/gantt.js +217 -218
  601. package/modules/gantt.js.map +1 -1
  602. package/modules/gantt.src.js +167 -152
  603. package/modules/grid-axis.js +1 -1
  604. package/modules/grid-axis.src.js +1 -1
  605. package/modules/heatmap.js +39 -39
  606. package/modules/heatmap.js.map +1 -1
  607. package/modules/heatmap.src.js +177 -162
  608. package/modules/heikinashi.js +1 -1
  609. package/modules/heikinashi.src.js +4 -4
  610. package/modules/histogram-bellcurve.js +13 -13
  611. package/modules/histogram-bellcurve.js.map +1 -1
  612. package/modules/histogram-bellcurve.src.js +91 -86
  613. package/modules/hollowcandlestick.js +9 -9
  614. package/modules/hollowcandlestick.js.map +1 -1
  615. package/modules/hollowcandlestick.src.js +37 -37
  616. package/modules/item-series.js +1 -1
  617. package/modules/item-series.src.js +1 -1
  618. package/modules/lollipop.js +1 -1
  619. package/modules/lollipop.src.js +1 -1
  620. package/modules/map.d.ts +136 -14
  621. package/modules/map.js +144 -122
  622. package/modules/map.js.map +1 -1
  623. package/modules/map.src.d.ts +136 -14
  624. package/modules/map.src.js +2227 -1039
  625. package/modules/marker-clusters.js +36 -36
  626. package/modules/marker-clusters.js.map +1 -1
  627. package/modules/marker-clusters.src.js +173 -142
  628. package/modules/networkgraph.d.ts +12 -1
  629. package/modules/networkgraph.js +49 -49
  630. package/modules/networkgraph.js.map +1 -1
  631. package/modules/networkgraph.src.d.ts +12 -1
  632. package/modules/networkgraph.src.js +91 -43
  633. package/modules/no-data-to-display.js +5 -5
  634. package/modules/no-data-to-display.js.map +1 -1
  635. package/modules/no-data-to-display.src.js +3 -3
  636. package/modules/offline-exporting.js +18 -17
  637. package/modules/offline-exporting.js.map +1 -1
  638. package/modules/offline-exporting.src.js +14 -14
  639. package/modules/oldie-polyfills.js +1 -1
  640. package/modules/oldie-polyfills.src.js +1 -1
  641. package/modules/oldie.js +26 -26
  642. package/modules/oldie.js.map +1 -1
  643. package/modules/oldie.src.js +4 -4
  644. package/modules/organization.js +13 -13
  645. package/modules/organization.js.map +1 -1
  646. package/modules/organization.src.js +4 -4
  647. package/modules/overlapping-datalabels.js +1 -1
  648. package/modules/overlapping-datalabels.src.js +1 -1
  649. package/modules/parallel-coordinates.js +1 -1
  650. package/modules/parallel-coordinates.src.js +1 -1
  651. package/modules/pareto.js +7 -7
  652. package/modules/pareto.js.map +1 -1
  653. package/modules/pareto.src.js +89 -78
  654. package/modules/pathfinder.js +1 -1
  655. package/modules/pathfinder.src.js +1 -1
  656. package/modules/pattern-fill.js +1 -1
  657. package/modules/pattern-fill.src.js +1 -1
  658. package/modules/price-indicator.js +1 -1
  659. package/modules/price-indicator.src.js +1 -1
  660. package/modules/pyramid3d.js +1 -1
  661. package/modules/pyramid3d.src.js +1 -1
  662. package/modules/sankey.d.ts +12 -1
  663. package/modules/sankey.js +29 -29
  664. package/modules/sankey.js.map +1 -1
  665. package/modules/sankey.src.d.ts +12 -1
  666. package/modules/sankey.src.js +300 -176
  667. package/modules/series-label.js +1 -1
  668. package/modules/series-label.src.js +1 -1
  669. package/modules/solid-gauge.js +1 -1
  670. package/modules/solid-gauge.src.js +1 -1
  671. package/modules/sonification.js +59 -55
  672. package/modules/sonification.js.map +1 -1
  673. package/modules/sonification.src.js +3034 -2553
  674. package/modules/static-scale.js +1 -1
  675. package/modules/static-scale.src.js +1 -1
  676. package/modules/stock-tools.js +178 -163
  677. package/modules/stock-tools.js.map +1 -1
  678. package/modules/stock-tools.src.js +1028 -144
  679. package/modules/stock.d.ts +39 -6
  680. package/modules/stock.js +204 -196
  681. package/modules/stock.js.map +1 -1
  682. package/modules/stock.src.d.ts +39 -6
  683. package/modules/stock.src.js +1667 -1061
  684. package/modules/streamgraph.js +1 -1
  685. package/modules/streamgraph.src.js +1 -1
  686. package/modules/sunburst.js +61 -60
  687. package/modules/sunburst.js.map +1 -1
  688. package/modules/sunburst.src.js +329 -266
  689. package/modules/tilemap.js +17 -17
  690. package/modules/tilemap.js.map +1 -1
  691. package/modules/tilemap.src.js +3 -4
  692. package/modules/timeline.js +18 -18
  693. package/modules/timeline.js.map +1 -1
  694. package/modules/timeline.src.js +5 -5
  695. package/modules/treegrid.js +56 -57
  696. package/modules/treegrid.js.map +1 -1
  697. package/modules/treegrid.src.js +126 -120
  698. package/modules/treemap.js +41 -41
  699. package/modules/treemap.js.map +1 -1
  700. package/modules/treemap.src.js +319 -254
  701. package/modules/variable-pie.js +1 -1
  702. package/modules/variable-pie.src.js +1 -1
  703. package/modules/variwide.js +1 -1
  704. package/modules/variwide.src.js +1 -1
  705. package/modules/vector.js +1 -1
  706. package/modules/vector.src.js +1 -1
  707. package/modules/venn.js +31 -31
  708. package/modules/venn.js.map +1 -1
  709. package/modules/venn.src.js +731 -721
  710. package/modules/windbarb.js +15 -15
  711. package/modules/windbarb.js.map +1 -1
  712. package/modules/windbarb.src.js +90 -62
  713. package/modules/wordcloud.js +23 -24
  714. package/modules/wordcloud.js.map +1 -1
  715. package/modules/wordcloud.src.js +897 -949
  716. package/modules/xrange.js +2 -2
  717. package/modules/xrange.js.map +1 -1
  718. package/modules/xrange.src.js +2 -1
  719. package/package.json +1 -1
  720. package/themes/avocado.js +1 -1
  721. package/themes/avocado.src.js +1 -1
  722. package/themes/dark-blue.js +1 -1
  723. package/themes/dark-blue.src.js +1 -1
  724. package/themes/dark-green.js +1 -1
  725. package/themes/dark-green.src.js +1 -1
  726. package/themes/dark-unica.js +1 -1
  727. package/themes/dark-unica.src.js +1 -1
  728. package/themes/gray.js +1 -1
  729. package/themes/gray.src.js +1 -1
  730. package/themes/grid-light.js +1 -1
  731. package/themes/grid-light.src.js +1 -1
  732. package/themes/grid.js +1 -1
  733. package/themes/grid.src.js +1 -1
  734. package/themes/high-contrast-dark.js +1 -1
  735. package/themes/high-contrast-dark.src.js +1 -1
  736. package/themes/high-contrast-light.js +1 -1
  737. package/themes/high-contrast-light.src.js +1 -1
  738. package/themes/sand-signika.js +1 -1
  739. package/themes/sand-signika.src.js +1 -1
  740. package/themes/skies.js +1 -1
  741. package/themes/skies.src.js +1 -1
  742. package/themes/sunset.js +1 -1
  743. package/themes/sunset.src.js +1 -1
  744. package/es-modules/Core/Axis/MapAxis.js +0 -157
  745. package/es-modules/Core/Color/Palette.js +0 -82
  746. package/es-modules/Extensions/Sonification/InstrumentDefinitions.js +0 -32
  747. package/es-modules/Mixins/ColorMapSeries.js +0 -82
  748. package/es-modules/Mixins/ColorSeries.js +0 -77
  749. package/es-modules/Mixins/DerivedSeries.js +0 -118
  750. package/es-modules/Mixins/DrawPoint.js +0 -81
  751. package/es-modules/Mixins/IndicatorRequired.js +0 -56
  752. package/es-modules/Mixins/Navigation.js +0 -54
  753. package/es-modules/Mixins/NelderMead.js +0 -132
  754. package/es-modules/Mixins/Polygon.js +0 -259
  755. package/es-modules/Mixins/ReduceArray.js +0 -54
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highstock JS v9.2.0 (2021-08-18)
2
+ * @license Highstock JS v9.3.1 (2021-11-05)
3
3
  *
4
4
  * All technical indicators for Highcharts Stock
5
5
  *
@@ -28,68 +28,6 @@
28
28
  obj[path] = fn.apply(null, args);
29
29
  }
30
30
  }
31
- _registerModule(_modules, 'Mixins/IndicatorRequired.js', [_modules['Core/Utilities.js']], function (U) {
32
- /**
33
- *
34
- * (c) 2010-2021 Daniel Studencki
35
- *
36
- * License: www.highcharts.com/license
37
- *
38
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
39
- *
40
- * */
41
- var error = U.error;
42
- /* eslint-disable no-invalid-this, valid-jsdoc */
43
- var requiredIndicatorMixin = {
44
- /**
45
- * Check whether given indicator is loaded,
46
- else throw error.
47
- * @private
48
- * @param {Highcharts.Indicator} indicator
49
- * Indicator constructor function.
50
- * @param {string} requiredIndicator
51
- * Required indicator type.
52
- * @param {string} type
53
- * Type of indicator where function was called (parent).
54
- * @param {Highcharts.IndicatorCallbackFunction} callback
55
- * Callback which is triggered if the given indicator is loaded.
56
- * Takes indicator as an argument.
57
- * @param {string} errMessage
58
- * Error message that will be logged in console.
59
- * @return {boolean}
60
- * Returns false when there is no required indicator loaded.
61
- */
62
- isParentLoaded: function (indicator,
63
- requiredIndicator,
64
- type,
65
- callback,
66
- errMessage) {
67
- if (indicator) {
68
- return callback ? callback(indicator) : true;
69
- }
70
- error(errMessage || this.generateMessage(type, requiredIndicator));
71
- return false;
72
- },
73
- /**
74
- * @private
75
- * @param {string} indicatorType
76
- * Indicator type
77
- * @param {string} required
78
- * Required indicator
79
- * @return {string}
80
- * Error message
81
- */
82
- generateMessage: function (indicatorType, required) {
83
- return 'Error: "' + indicatorType +
84
- '" indicator type requires "' + required +
85
- '" indicator loaded before. Please read docs: ' +
86
- 'https://api.highcharts.com/highstock/plotOptions.' +
87
- indicatorType;
88
- }
89
- };
90
-
91
- return requiredIndicatorMixin;
92
- });
93
31
  _registerModule(_modules, 'Stock/Indicators/SMA/SMAComposition.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
94
32
  /* *
95
33
  *
@@ -102,37 +40,9 @@
102
40
  ohlcProto = SeriesRegistry.seriesTypes.ohlc.prototype;
103
41
  var addEvent = U.addEvent,
104
42
  extend = U.extend;
105
- /* *
106
- *
107
- * Composition
108
- *
109
- * */
110
- addEvent(Series, 'init', function (eventOptions) {
111
- // eslint-disable-next-line no-invalid-this
112
- var series = this,
113
- options = eventOptions.options;
114
- if (options.useOhlcData &&
115
- options.id !== 'highcharts-navigator-series') {
116
- extend(series, {
117
- pointValKey: ohlcProto.pointValKey,
118
- // keys: ohlcProto.keys, // @todo potentially nonsense
119
- pointArrayMap: ohlcProto.pointArrayMap,
120
- toYData: ohlcProto.toYData
121
- });
122
- }
123
- });
124
- addEvent(Series, 'afterSetOptions', function (e) {
125
- var options = e.options,
126
- dataGrouping = options.dataGrouping;
127
- if (dataGrouping &&
128
- options.useOhlcData &&
129
- options.id !== 'highcharts-navigator-series') {
130
- dataGrouping.approximation = 'ohlc';
131
- }
132
- });
133
43
 
134
44
  });
135
- _registerModule(_modules, 'Stock/Indicators/SMA/SMAIndicator.js', [_modules['Core/Chart/Chart.js'], _modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (Chart, RequiredIndicatorMixin, SeriesRegistry, U) {
45
+ _registerModule(_modules, 'Stock/Indicators/SMA/SMAIndicator.js', [_modules['Core/Chart/Chart.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (Chart, SeriesRegistry, U) {
136
46
  /* *
137
47
  *
138
48
  * License: www.highcharts.com/license
@@ -164,7 +74,6 @@
164
74
  merge = U.merge,
165
75
  pick = U.pick,
166
76
  splat = U.splat;
167
- var generateMessage = RequiredIndicatorMixin.generateMessage;
168
77
  /* *
169
78
  *
170
79
  * Class
@@ -278,12 +187,7 @@
278
187
  * @private
279
188
  */
280
189
  SMAIndicator.prototype.init = function (chart, options) {
281
- var indicator = this,
282
- requiredIndicators = indicator.requireIndicators();
283
- // Check whether all required indicators are loaded.
284
- if (!requiredIndicators.allLoaded) {
285
- return error(generateMessage(indicator.type, requiredIndicators.needed));
286
- }
190
+ var indicator = this;
287
191
  _super.prototype.init.call(indicator, chart, options);
288
192
  // Only after series are linked indicator can be processed.
289
193
  var linkedSeriesUnbiner = addEvent(Chart, 'afterLinkSeries',
@@ -291,27 +195,35 @@
291
195
  var hasEvents = !!indicator.dataEventsToUnbind.length;
292
196
  if (indicator.linkedParent) {
293
197
  if (!hasEvents) {
294
- indicator.dataEventsToUnbind.push(addEvent(indicator.bindTo.series ?
295
- indicator.linkedParent :
296
- indicator.linkedParent.xAxis, indicator.bindTo.eventName, function () {
198
+ // No matter which indicator,
199
+ // always recalculate after updating the data.
200
+ indicator.dataEventsToUnbind.push(addEvent(indicator.linkedParent, 'updatedData', function () {
297
201
  indicator.recalculateValues();
298
202
  }));
203
+ // Some indicators (like VBP) requires an additional
204
+ // event (afterSetExtremes) to properly show the data.
205
+ if (indicator.calculateOn.xAxis) {
206
+ indicator.dataEventsToUnbind.push(addEvent(indicator.linkedParent.xAxis, indicator.calculateOn.xAxis, function () {
207
+ indicator.recalculateValues();
208
+ }));
209
+ }
299
210
  }
300
- if (indicator.calculateOn === 'init') {
211
+ // Most indicators are being calculated on chart's init.
212
+ if (indicator.calculateOn.chart === 'init') {
301
213
  if (!indicator.processedYData) {
302
214
  indicator.recalculateValues();
303
215
  }
304
216
  }
305
- else {
306
- if (!hasEvents) {
307
- var unbinder_1 = addEvent(indicator.chart,
308
- indicator.calculateOn,
309
- function () {
310
- indicator.recalculateValues();
311
- // Call this just once, on init
312
- unbinder_1();
313
- });
314
- }
217
+ else if (!hasEvents) {
218
+ // Some indicators (like VBP) has to recalculate their
219
+ // values after other chart's events (render).
220
+ var unbinder_1 = addEvent(indicator.chart,
221
+ indicator.calculateOn.chart,
222
+ function () {
223
+ indicator.recalculateValues();
224
+ // Call this just once.
225
+ unbinder_1();
226
+ });
315
227
  }
316
228
  }
317
229
  else {
@@ -394,7 +306,7 @@
394
306
  }
395
307
  // Removal of processedXData property is required because on
396
308
  // first translate processedXData array is empty
397
- if (indicator.bindTo.series === false) {
309
+ if (indicator.calculateOn.xAxis && indicator.processedXData) {
398
310
  delete indicator.processedXData;
399
311
  indicator.isDirty = true;
400
312
  indicator.redraw();
@@ -409,31 +321,16 @@
409
321
  compareToMain = series.options.compareToMain,
410
322
  linkedParent = series.linkedParent;
411
323
  _super.prototype.processData.apply(series, arguments);
412
- if (linkedParent && linkedParent.compareValue && compareToMain) {
413
- series.compareValue = linkedParent.compareValue;
324
+ if (series.dataModify &&
325
+ linkedParent &&
326
+ linkedParent.dataModify &&
327
+ linkedParent.dataModify.compareValue &&
328
+ compareToMain) {
329
+ series.dataModify.compareValue =
330
+ linkedParent.dataModify.compareValue;
414
331
  }
415
332
  return;
416
333
  };
417
- /**
418
- * @private
419
- */
420
- SMAIndicator.prototype.requireIndicators = function () {
421
- var obj = {
422
- allLoaded: true
423
- };
424
- // Check whether all required indicators are loaded, else return
425
- // the object with missing indicator's name.
426
- this.requiredIndicators.forEach(function (indicator) {
427
- if (SeriesRegistry.seriesTypes[indicator]) {
428
- SeriesRegistry.seriesTypes[indicator].prototype.requireIndicators();
429
- }
430
- else {
431
- obj.allLoaded = false;
432
- obj.needed = indicator;
433
- }
434
- });
435
- return obj;
436
- };
437
334
  /**
438
335
  * The parameter allows setting line series type and use OHLC indicators.
439
336
  * Data in OHLC format is required.
@@ -504,7 +401,7 @@
504
401
  * example using OHLC data, index=2 means the indicator will be
505
402
  * calculated using Low values.
506
403
  */
507
- index: 0,
404
+ index: 3,
508
405
  /**
509
406
  * The base period for indicator calculations. This is the number of
510
407
  * data points which are taken into account for the indicator
@@ -516,16 +413,12 @@
516
413
  return SMAIndicator;
517
414
  }(LineSeries));
518
415
  extend(SMAIndicator.prototype, {
519
- bindTo: {
520
- series: true,
521
- eventName: 'updatedData'
416
+ calculateOn: {
417
+ chart: 'init'
522
418
  },
523
- calculateOn: 'init',
524
419
  hasDerivedData: true,
525
420
  nameComponents: ['period'],
526
421
  nameSuffixes: [],
527
- // Defines on which other indicators is this indicator based on.
528
- requiredIndicators: [],
529
422
  useCommonDataGrouping: true
530
423
  });
531
424
  SeriesRegistry.registerSeriesType('sma', SMAIndicator);
@@ -554,6 +447,183 @@
554
447
 
555
448
  return SMAIndicator;
556
449
  });
450
+ _registerModule(_modules, 'Stock/Indicators/EMA/EMAIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
451
+ /* *
452
+ *
453
+ * License: www.highcharts.com/license
454
+ *
455
+ * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
456
+ *
457
+ * */
458
+ var __extends = (this && this.__extends) || (function () {
459
+ var extendStatics = function (d,
460
+ b) {
461
+ extendStatics = Object.setPrototypeOf ||
462
+ ({ __proto__: [] } instanceof Array && function (d,
463
+ b) { d.__proto__ = b; }) ||
464
+ function (d,
465
+ b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
466
+ return extendStatics(d, b);
467
+ };
468
+ return function (d, b) {
469
+ extendStatics(d, b);
470
+ function __() { this.constructor = d; }
471
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
472
+ };
473
+ })();
474
+ var SMAIndicator = SeriesRegistry.seriesTypes.sma;
475
+ var correctFloat = U.correctFloat,
476
+ isArray = U.isArray,
477
+ merge = U.merge;
478
+ /* *
479
+ *
480
+ * Class
481
+ *
482
+ * */
483
+ /**
484
+ * The EMA series type.
485
+ *
486
+ * @private
487
+ * @class
488
+ * @name Highcharts.seriesTypes.ema
489
+ *
490
+ * @augments Highcharts.Series
491
+ */
492
+ var EMAIndicator = /** @class */ (function (_super) {
493
+ __extends(EMAIndicator, _super);
494
+ function EMAIndicator() {
495
+ var _this = _super !== null && _super.apply(this,
496
+ arguments) || this;
497
+ /* *
498
+ *
499
+ * Properties
500
+ *
501
+ * */
502
+ _this.data = void 0;
503
+ _this.options = void 0;
504
+ _this.points = void 0;
505
+ return _this;
506
+ }
507
+ /* *
508
+ *
509
+ * Functions
510
+ *
511
+ * */
512
+ EMAIndicator.prototype.accumulatePeriodPoints = function (period, index, yVal) {
513
+ var sum = 0,
514
+ i = 0,
515
+ y = 0;
516
+ while (i < period) {
517
+ y = index < 0 ? yVal[i] : yVal[i][index];
518
+ sum = sum + y;
519
+ i++;
520
+ }
521
+ return sum;
522
+ };
523
+ EMAIndicator.prototype.calculateEma = function (xVal, yVal, i, EMApercent, calEMA, index, SMA) {
524
+ var x = xVal[i - 1],
525
+ yValue = index < 0 ?
526
+ yVal[i - 1] :
527
+ yVal[i - 1][index],
528
+ y;
529
+ y = typeof calEMA === 'undefined' ?
530
+ SMA : correctFloat((yValue * EMApercent) +
531
+ (calEMA * (1 - EMApercent)));
532
+ return [x, y];
533
+ };
534
+ EMAIndicator.prototype.getValues = function (series, params) {
535
+ var period = params.period,
536
+ xVal = series.xData,
537
+ yVal = series.yData,
538
+ yValLen = yVal ? yVal.length : 0,
539
+ EMApercent = 2 / (period + 1),
540
+ sum = 0,
541
+ EMA = [],
542
+ xData = [],
543
+ yData = [],
544
+ index = -1,
545
+ SMA = 0,
546
+ calEMA,
547
+ EMAPoint,
548
+ i;
549
+ // Check period, if bigger than points length, skip
550
+ if (yValLen < period) {
551
+ return;
552
+ }
553
+ // Switch index for OHLC / Candlestick / Arearange
554
+ if (isArray(yVal[0])) {
555
+ index = params.index ? params.index : 0;
556
+ }
557
+ // Accumulate first N-points
558
+ sum = this.accumulatePeriodPoints(period, index, yVal);
559
+ // first point
560
+ SMA = sum / period;
561
+ // Calculate value one-by-one for each period in visible data
562
+ for (i = period; i < yValLen + 1; i++) {
563
+ EMAPoint = this.calculateEma(xVal, yVal, i, EMApercent, calEMA, index, SMA);
564
+ EMA.push(EMAPoint);
565
+ xData.push(EMAPoint[0]);
566
+ yData.push(EMAPoint[1]);
567
+ calEMA = EMAPoint[1];
568
+ }
569
+ return {
570
+ values: EMA,
571
+ xData: xData,
572
+ yData: yData
573
+ };
574
+ };
575
+ /**
576
+ * Exponential moving average indicator (EMA). This series requires the
577
+ * `linkedTo` option to be set.
578
+ *
579
+ * @sample stock/indicators/ema
580
+ * Exponential moving average indicator
581
+ *
582
+ * @extends plotOptions.sma
583
+ * @since 6.0.0
584
+ * @product highstock
585
+ * @requires stock/indicators/indicators
586
+ * @optionparent plotOptions.ema
587
+ */
588
+ EMAIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
589
+ params: {
590
+ /**
591
+ * The point index which indicator calculations will base. For
592
+ * example using OHLC data, index=2 means the indicator will be
593
+ * calculated using Low values.
594
+ *
595
+ * By default index value used to be set to 0. Since
596
+ * Highcharts Stock 7 by default index is set to 3
597
+ * which means that the ema indicator will be
598
+ * calculated using Close values.
599
+ */
600
+ index: 3,
601
+ period: 9 // @merge 14 in v6.2
602
+ }
603
+ });
604
+ return EMAIndicator;
605
+ }(SMAIndicator));
606
+ SeriesRegistry.registerSeriesType('ema', EMAIndicator);
607
+ /* *
608
+ *
609
+ * Default Export
610
+ *
611
+ * */
612
+ /**
613
+ * A `EMA` series. If the [type](#series.ema.type) option is not
614
+ * specified, it is inherited from [chart.type](#chart.type).
615
+ *
616
+ * @extends series,plotOptions.ema
617
+ * @since 6.0.0
618
+ * @product highstock
619
+ * @excluding dataParser, dataURL
620
+ * @requires stock/indicators/indicators
621
+ * @apioption series.ema
622
+ */
623
+ ''; // adds doclet above to the transpiled file
624
+
625
+ return EMAIndicator;
626
+ });
557
627
  _registerModule(_modules, 'Stock/Indicators/AD/ADIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
558
628
  /* *
559
629
  *
@@ -737,7 +807,7 @@
737
807
 
738
808
  return ADIndicator;
739
809
  });
740
- _registerModule(_modules, 'Stock/Indicators/AO/AOIndicator.js', [_modules['Core/Globals.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js'], _modules['Core/Color/Palette.js']], function (H, SeriesRegistry, U, palette) {
810
+ _registerModule(_modules, 'Stock/Indicators/AO/AOIndicator.js', [_modules['Core/Globals.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (H, SeriesRegistry, U) {
741
811
  /* *
742
812
  *
743
813
  * License: www.highcharts.com/license
@@ -919,7 +989,7 @@
919
989
  * @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
920
990
  * @since 7.0.0
921
991
  */
922
- greaterBarColor: palette.positiveColor,
992
+ greaterBarColor: "#06b535" /* positiveColor */,
923
993
  /**
924
994
  * Color of the Awesome oscillator series bar that is lower than the
925
995
  * previous one. Note that if a `color` is defined, the `color`
@@ -931,7 +1001,7 @@
931
1001
  * @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
932
1002
  * @since 7.0.0
933
1003
  */
934
- lowerBarColor: palette.negativeColor,
1004
+ lowerBarColor: "#f21313" /* negativeColor */,
935
1005
  threshold: 0,
936
1006
  groupPadding: 0.2,
937
1007
  pointPadding: 0.2,
@@ -980,7 +1050,7 @@
980
1050
 
981
1051
  return AOIndicator;
982
1052
  });
983
- _registerModule(_modules, 'Mixins/MultipleLines.js', [_modules['Core/Globals.js'], _modules['Core/Utilities.js']], function (H, U) {
1053
+ _registerModule(_modules, 'Stock/Indicators/MultipleLinesComposition.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
984
1054
  /**
985
1055
  *
986
1056
  * (c) 2010-2021 Wojciech Chmiel
@@ -990,118 +1060,96 @@
990
1060
  * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
991
1061
  *
992
1062
  * */
1063
+ var SMAIndicator = SeriesRegistry.seriesTypes.sma;
993
1064
  var defined = U.defined,
994
1065
  error = U.error,
995
1066
  merge = U.merge;
996
- var SMA = H.seriesTypes.sma;
1067
+ /* *
1068
+ *
1069
+ * Composition
1070
+ *
1071
+ * */
997
1072
  /**
998
- * Mixin useful for all indicators that have more than one line.
999
- * Merge it with your implementation where you will provide
1000
- * getValues method appropriate to your indicator and pointArrayMap,
1001
- * pointValKey, linesApiNames properites. Notice that pointArrayMap
1002
- * should be consistent with amount of lines calculated in getValues method.
1073
+ * Composition useful for all indicators that have more than one line. Compose
1074
+ * it with your implementation where you will provide the `getValues` method
1075
+ * appropriate to your indicator and `pointArrayMap`, `pointValKey`,
1076
+ * `linesApiNames` properties. Notice that `pointArrayMap` should be consistent
1077
+ * with the amount of lines calculated in the `getValues` method.
1003
1078
  *
1004
1079
  * @private
1005
1080
  * @mixin multipleLinesMixin
1006
1081
  */
1007
- var multipleLinesMixin = {
1008
- /* eslint-disable valid-jsdoc */
1009
- /**
1010
- * Lines ids. Required to plot appropriate amount of lines.
1011
- * Notice that pointArrayMap should have more elements than
1012
- * linesApiNames, because it contains main line and additional lines ids.
1013
- * Also it should be consistent with amount of lines calculated in
1014
- * getValues method from your implementation.
1015
- *
1016
- * @private
1017
- * @name multipleLinesMixin.pointArrayMap
1018
- * @type {Array<string>}
1019
- */
1020
- pointArrayMap: ['top', 'bottom'],
1021
- /**
1022
- * Main line id.
1023
- *
1024
- * @private
1025
- * @name multipleLinesMixin.pointValKey
1026
- * @type {string}
1027
- */
1028
- pointValKey: 'top',
1029
- /**
1030
- * Additional lines DOCS names. Elements of linesApiNames array should
1031
- * be consistent with DOCS line names defined in your implementation.
1032
- * Notice that linesApiNames should have decreased amount of elements
1033
- * relative to pointArrayMap (without pointValKey).
1034
- *
1035
- * @private
1036
- * @name multipleLinesMixin.linesApiNames
1037
- * @type {Array<string>}
1038
- */
1039
- linesApiNames: ['bottomLine'],
1040
- /**
1041
- * Create translatedLines Collection based on pointArrayMap.
1042
- *
1043
- * @private
1044
- * @function multipleLinesMixin.getTranslatedLinesNames
1045
- * @param {string} [excludedValue]
1046
- * Main line id
1047
- * @return {Array<string>}
1048
- * Returns translated lines names without excluded value.
1049
- */
1050
- getTranslatedLinesNames: function (excludedValue) {
1051
- var translatedLines = [];
1052
- (this.pointArrayMap || []).forEach(function (propertyName) {
1053
- if (propertyName !== excludedValue) {
1054
- translatedLines.push('plot' +
1055
- propertyName.charAt(0).toUpperCase() +
1056
- propertyName.slice(1));
1057
- }
1058
- });
1059
- return translatedLines;
1060
- },
1082
+ var MultipleLinesComposition;
1083
+ (function (MultipleLinesComposition) {
1084
+ /* *
1085
+ *
1086
+ * Declarations
1087
+ *
1088
+ * */
1089
+ /* *
1090
+ *
1091
+ * Constants
1092
+ *
1093
+ * */
1094
+ var composedClasses = [];
1061
1095
  /**
1096
+ * Additional lines DOCS names. Elements of linesApiNames array should
1097
+ * be consistent with DOCS line names defined in your implementation.
1098
+ * Notice that linesApiNames should have decreased amount of elements
1099
+ * relative to pointArrayMap (without pointValKey).
1100
+ *
1062
1101
  * @private
1063
- * @function multipleLinesMixin.toYData
1064
- * @param {Highcharts.Point} point
1065
- * Indicator point
1066
- * @return {Array<number>}
1067
- * Returns point Y value for all lines
1102
+ * @name multipleLinesMixin.linesApiNames
1103
+ * @type {Array<string>}
1068
1104
  */
1069
- toYData: function (point) {
1070
- var pointColl = [];
1071
- (this.pointArrayMap || []).forEach(function (propertyName) {
1072
- pointColl.push(point[propertyName]);
1073
- });
1074
- return pointColl;
1075
- },
1105
+ var linesApiNames = ['bottomLine'];
1076
1106
  /**
1077
- * Add lines plot pixel values.
1107
+ * Lines ids. Required to plot appropriate amount of lines.
1108
+ * Notice that pointArrayMap should have more elements than
1109
+ * linesApiNames, because it contains main line and additional lines ids.
1110
+ * Also it should be consistent with amount of lines calculated in
1111
+ * getValues method from your implementation.
1078
1112
  *
1079
1113
  * @private
1080
- * @function multipleLinesMixin.translate
1081
- * @return {void}
1114
+ * @name multipleLinesMixin.pointArrayMap
1115
+ * @type {Array<string>}
1082
1116
  */
1083
- translate: function () {
1084
- var indicator = this,
1085
- pointArrayMap = indicator.pointArrayMap,
1086
- LinesNames = [],
1087
- value;
1088
- var modfidyValue = indicator.modifyValue;
1089
- LinesNames = indicator.getTranslatedLinesNames();
1090
- SMA.prototype.translate.apply(indicator, arguments);
1091
- indicator.points.forEach(function (point) {
1092
- pointArrayMap.forEach(function (propertyName, i) {
1093
- value = point[propertyName];
1094
- // If the modifier, like for example compare exists,
1095
- // modified the original value by that method, #15867.
1096
- if (modfidyValue) {
1097
- value = modfidyValue.call(indicator, value);
1098
- }
1099
- if (value !== null) {
1100
- point[LinesNames[i]] = indicator.yAxis.toPixels(value, true);
1101
- }
1102
- });
1103
- });
1104
- },
1117
+ var pointArrayMap = ['top', 'bottom'];
1118
+ /**
1119
+ * Main line id.
1120
+ *
1121
+ * @private
1122
+ * @name multipleLinesMixin.pointValKey
1123
+ * @type {string}
1124
+ */
1125
+ var pointValKey = 'top';
1126
+ /* *
1127
+ *
1128
+ * Functions
1129
+ *
1130
+ * */
1131
+ /* eslint-disable valid-jsdoc */
1132
+ /**
1133
+ * @private
1134
+ */
1135
+ function compose(IndicatorClass) {
1136
+ if (composedClasses.indexOf(IndicatorClass) === -1) {
1137
+ composedClasses.push(IndicatorClass);
1138
+ var proto = IndicatorClass.prototype;
1139
+ proto.linesApiNames = (proto.linesApiNames ||
1140
+ linesApiNames.slice());
1141
+ proto.pointArrayMap = (proto.pointArrayMap ||
1142
+ pointArrayMap.slice());
1143
+ proto.pointValKey = (proto.pointValKey ||
1144
+ pointValKey);
1145
+ proto.drawGraph = drawGraph;
1146
+ proto.toYData = toYData;
1147
+ proto.translate = translate;
1148
+ proto.getTranslatedLinesNames = getTranslatedLinesNames;
1149
+ }
1150
+ return IndicatorClass;
1151
+ }
1152
+ MultipleLinesComposition.compose = compose;
1105
1153
  /**
1106
1154
  * Draw main and additional lines.
1107
1155
  *
@@ -1109,12 +1157,11 @@
1109
1157
  * @function multipleLinesMixin.drawGraph
1110
1158
  * @return {void}
1111
1159
  */
1112
- drawGraph: function () {
1160
+ function drawGraph() {
1113
1161
  var indicator = this,
1114
1162
  pointValKey = indicator.pointValKey,
1115
1163
  linesApiNames = indicator.linesApiNames,
1116
1164
  mainLinePoints = indicator.points,
1117
- pointsLength = mainLinePoints.length,
1118
1165
  mainLineOptions = indicator.options,
1119
1166
  mainLinePath = indicator.graph,
1120
1167
  gappedExtend = {
@@ -1124,7 +1171,8 @@
1124
1171
  },
1125
1172
  // additional lines point place holders:
1126
1173
  secondaryLines = [],
1127
- secondaryLinesNames = indicator.getTranslatedLinesNames(pointValKey),
1174
+ secondaryLinesNames = indicator.getTranslatedLinesNames(pointValKey);
1175
+ var pointsLength = mainLinePoints.length,
1128
1176
  point;
1129
1177
  // Generate points for additional lines:
1130
1178
  secondaryLinesNames.forEach(function (plotLine, index) {
@@ -1155,7 +1203,7 @@
1155
1203
  ' at mixin/multiple-line.js:34');
1156
1204
  }
1157
1205
  indicator.graph = indicator['graph' + lineName];
1158
- SMA.prototype.drawGraph.call(indicator);
1206
+ SMAIndicator.prototype.drawGraph.call(indicator);
1159
1207
  // Now save lines:
1160
1208
  indicator['graph' + lineName] = indicator.graph;
1161
1209
  }
@@ -1169,13 +1217,82 @@
1169
1217
  indicator.points = mainLinePoints;
1170
1218
  indicator.options = mainLineOptions;
1171
1219
  indicator.graph = mainLinePath;
1172
- SMA.prototype.drawGraph.call(indicator);
1220
+ SMAIndicator.prototype.drawGraph.call(indicator);
1173
1221
  }
1174
- };
1222
+ /**
1223
+ * Create translatedLines Collection based on pointArrayMap.
1224
+ *
1225
+ * @private
1226
+ * @function multipleLinesMixin.getTranslatedLinesNames
1227
+ * @param {string} [excludedValue]
1228
+ * Main line id
1229
+ * @return {Array<string>}
1230
+ * Returns translated lines names without excluded value.
1231
+ */
1232
+ function getTranslatedLinesNames(excludedValue) {
1233
+ var translatedLines = [];
1234
+ (this.pointArrayMap || []).forEach(function (propertyName) {
1235
+ if (propertyName !== excludedValue) {
1236
+ translatedLines.push('plot' +
1237
+ propertyName.charAt(0).toUpperCase() +
1238
+ propertyName.slice(1));
1239
+ }
1240
+ });
1241
+ return translatedLines;
1242
+ }
1243
+ /**
1244
+ * @private
1245
+ * @function multipleLinesMixin.toYData
1246
+ * @param {Highcharts.Point} point
1247
+ * Indicator point
1248
+ * @return {Array<number>}
1249
+ * Returns point Y value for all lines
1250
+ */
1251
+ function toYData(point) {
1252
+ var pointColl = [];
1253
+ (this.pointArrayMap || []).forEach(function (propertyName) {
1254
+ pointColl.push(point[propertyName]);
1255
+ });
1256
+ return pointColl;
1257
+ }
1258
+ /**
1259
+ * Add lines plot pixel values.
1260
+ *
1261
+ * @private
1262
+ * @function multipleLinesMixin.translate
1263
+ * @return {void}
1264
+ */
1265
+ function translate() {
1266
+ var indicator = this,
1267
+ pointArrayMap = indicator.pointArrayMap;
1268
+ var LinesNames = [],
1269
+ value;
1270
+ LinesNames = indicator.getTranslatedLinesNames();
1271
+ SMAIndicator.prototype.translate.apply(indicator, arguments);
1272
+ indicator.points.forEach(function (point) {
1273
+ pointArrayMap.forEach(function (propertyName, i) {
1274
+ value = point[propertyName];
1275
+ // If the modifier, like for example compare exists,
1276
+ // modified the original value by that method, #15867.
1277
+ if (indicator.dataModify) {
1278
+ value = indicator.dataModify.modifyValue(value);
1279
+ }
1280
+ if (value !== null) {
1281
+ point[LinesNames[i]] = indicator.yAxis.toPixels(value, true);
1282
+ }
1283
+ });
1284
+ });
1285
+ }
1286
+ })(MultipleLinesComposition || (MultipleLinesComposition = {}));
1287
+ /* *
1288
+ *
1289
+ * Default Export
1290
+ *
1291
+ * */
1175
1292
 
1176
- return multipleLinesMixin;
1293
+ return MultipleLinesComposition;
1177
1294
  });
1178
- _registerModule(_modules, 'Stock/Indicators/Aroon/AroonIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, SeriesRegistry, U) {
1295
+ _registerModule(_modules, 'Stock/Indicators/Aroon/AroonIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
1179
1296
  /* *
1180
1297
  *
1181
1298
  * License: www.highcharts.com/license
@@ -1364,12 +1481,9 @@
1364
1481
  linesApiNames: ['aroonDown'],
1365
1482
  nameBase: 'Aroon',
1366
1483
  pointArrayMap: ['y', 'aroonDown'],
1367
- pointValKey: 'y',
1368
- drawGraph: MultipleLinesMixin.drawGraph,
1369
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
1370
- toYData: MultipleLinesMixin.toYData,
1371
- translate: MultipleLinesMixin.translate
1484
+ pointValKey: 'y'
1372
1485
  });
1486
+ MultipleLinesComposition.compose(AroonIndicator);
1373
1487
  SeriesRegistry.registerSeriesType('aroon', AroonIndicator);
1374
1488
  /* *
1375
1489
  *
@@ -1394,7 +1508,7 @@
1394
1508
 
1395
1509
  return AroonIndicator;
1396
1510
  });
1397
- _registerModule(_modules, 'Stock/Indicators/AroonOscillator/AroonOscillatorIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (multipleLinesMixin, requiredIndicator, SeriesRegistry, U) {
1511
+ _registerModule(_modules, 'Stock/Indicators/AroonOscillator/AroonOscillatorIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
1398
1512
  /* *
1399
1513
  *
1400
1514
  * License: www.highcharts.com/license
@@ -1439,6 +1553,11 @@
1439
1553
  var AroonOscillatorIndicator = /** @class */ (function (_super) {
1440
1554
  __extends(AroonOscillatorIndicator, _super);
1441
1555
  function AroonOscillatorIndicator() {
1556
+ /* *
1557
+ *
1558
+ * Static Properties
1559
+ *
1560
+ * */
1442
1561
  var _this = _super !== null && _super.apply(this,
1443
1562
  arguments) || this;
1444
1563
  /* *
@@ -1481,14 +1600,6 @@
1481
1600
  yData: yData
1482
1601
  };
1483
1602
  };
1484
- AroonOscillatorIndicator.prototype.init = function () {
1485
- var args = arguments,
1486
- ctx = this;
1487
- requiredIndicator.isParentLoaded(AROON, 'aroon', ctx.type, function (indicator) {
1488
- indicator.prototype.init.apply(ctx, args);
1489
- return;
1490
- });
1491
- };
1492
1603
  /**
1493
1604
  * Aroon Oscillator. This series requires the `linkedTo` option to be set
1494
1605
  * and should be loaded after the `stock/indicators/indicators.js` and
@@ -1516,12 +1627,13 @@
1516
1627
  });
1517
1628
  return AroonOscillatorIndicator;
1518
1629
  }(AroonIndicator));
1519
- extend(AroonOscillatorIndicator.prototype, merge(multipleLinesMixin, {
1630
+ extend(AroonOscillatorIndicator.prototype, {
1520
1631
  nameBase: 'Aroon Oscillator',
1632
+ linesApiNames: [],
1521
1633
  pointArrayMap: ['y'],
1522
- pointValKey: 'y',
1523
- linesApiNames: []
1524
- }));
1634
+ pointValKey: 'y'
1635
+ });
1636
+ MultipleLinesComposition.compose(AroonIndicator);
1525
1637
  SeriesRegistry.registerSeriesType('aroonoscillator', AroonOscillatorIndicator);
1526
1638
  /* *
1527
1639
  *
@@ -1733,7 +1845,7 @@
1733
1845
 
1734
1846
  return ATRIndicator;
1735
1847
  });
1736
- _registerModule(_modules, 'Stock/Indicators/BB/BBIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, SeriesRegistry, U) {
1848
+ _registerModule(_modules, 'Stock/Indicators/BB/BBIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
1737
1849
  /**
1738
1850
  *
1739
1851
  * License: www.highcharts.com/license
@@ -1761,6 +1873,11 @@
1761
1873
  var extend = U.extend,
1762
1874
  isArray = U.isArray,
1763
1875
  merge = U.merge;
1876
+ /* *
1877
+ *
1878
+ * Functions
1879
+ *
1880
+ * */
1764
1881
  /* eslint-disable valid-jsdoc */
1765
1882
  // Utils:
1766
1883
  /**
@@ -1780,7 +1897,11 @@
1780
1897
  std = Math.sqrt(variance);
1781
1898
  return std;
1782
1899
  }
1783
- /* eslint-enable valid-jsdoc */
1900
+ /* *
1901
+ *
1902
+ * Class
1903
+ *
1904
+ * */
1784
1905
  /**
1785
1906
  * Bollinger Bands series type.
1786
1907
  *
@@ -1793,18 +1914,28 @@
1793
1914
  var BBIndicator = /** @class */ (function (_super) {
1794
1915
  __extends(BBIndicator, _super);
1795
1916
  function BBIndicator() {
1917
+ /* *
1918
+ *
1919
+ * Static Properties
1920
+ *
1921
+ * */
1796
1922
  var _this = _super !== null && _super.apply(this,
1797
1923
  arguments) || this;
1798
1924
  /* *
1799
- *
1800
- * Prototype Properties
1801
- *
1802
- * */
1925
+ *
1926
+ * Properties
1927
+ *
1928
+ * */
1803
1929
  _this.data = void 0;
1804
1930
  _this.options = void 0;
1805
1931
  _this.points = void 0;
1806
1932
  return _this;
1807
1933
  }
1934
+ /* *
1935
+ *
1936
+ * Functions
1937
+ *
1938
+ * */
1808
1939
  BBIndicator.prototype.init = function () {
1809
1940
  SeriesRegistry.seriesTypes.sma.prototype.init.apply(this, arguments);
1810
1941
  // Set default color for lines:
@@ -1942,12 +2073,9 @@
1942
2073
  pointArrayMap: ['top', 'middle', 'bottom'],
1943
2074
  pointValKey: 'middle',
1944
2075
  nameComponents: ['period', 'standardDeviation'],
1945
- linesApiNames: ['topLine', 'bottomLine'],
1946
- drawGraph: MultipleLinesMixin.drawGraph,
1947
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
1948
- translate: MultipleLinesMixin.translate,
1949
- toYData: MultipleLinesMixin.toYData
2076
+ linesApiNames: ['topLine', 'bottomLine']
1950
2077
  });
2078
+ MultipleLinesComposition.compose(BBIndicator);
1951
2079
  SeriesRegistry.registerSeriesType('bb', BBIndicator);
1952
2080
  /* *
1953
2081
  *
@@ -2390,7 +2518,7 @@
2390
2518
 
2391
2519
  return CMFIndicator;
2392
2520
  });
2393
- _registerModule(_modules, 'Stock/Indicators/DMI/DMIIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Core/Color/Palette.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, palette, SeriesRegistry, U) {
2521
+ _registerModule(_modules, 'Stock/Indicators/DMI/DMIIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
2394
2522
  /* *
2395
2523
  * (c) 2010-2021 Rafal Sebestjanski
2396
2524
  *
@@ -2439,7 +2567,20 @@
2439
2567
  var DMIIndicator = /** @class */ (function (_super) {
2440
2568
  __extends(DMIIndicator, _super);
2441
2569
  function DMIIndicator() {
2442
- return _super !== null && _super.apply(this, arguments) || this;
2570
+ /* *
2571
+ *
2572
+ * Static Properties
2573
+ *
2574
+ * */
2575
+ var _this = _super !== null && _super.apply(this,
2576
+ arguments) || this;
2577
+ /* *
2578
+ *
2579
+ * Properties
2580
+ *
2581
+ * */
2582
+ _this.options = void 0;
2583
+ return _this;
2443
2584
  }
2444
2585
  /* *
2445
2586
  *
@@ -2609,7 +2750,7 @@
2609
2750
  *
2610
2751
  * @type {Highcharts.ColorString}
2611
2752
  */
2612
- lineColor: palette.positiveColor // green-ish
2753
+ lineColor: "#06b535" /* positiveColor */ // green-ish
2613
2754
  }
2614
2755
  },
2615
2756
  /**
@@ -2629,7 +2770,7 @@
2629
2770
  *
2630
2771
  * @type {Highcharts.ColorString}
2631
2772
  */
2632
- lineColor: palette.negativeColor // red-ish
2773
+ lineColor: "#f21313" /* negativeColor */ // red-ish
2633
2774
  }
2634
2775
  },
2635
2776
  dataGrouping: {
@@ -2640,15 +2781,12 @@
2640
2781
  }(SMAIndicator));
2641
2782
  extend(DMIIndicator.prototype, {
2642
2783
  nameBase: 'DMI',
2784
+ linesApiNames: ['plusDILine', 'minusDILine'],
2643
2785
  pointArrayMap: ['y', 'plusDI', 'minusDI'],
2644
2786
  parallelArrays: ['x', 'y', 'plusDI', 'minusDI'],
2645
- pointValKey: 'y',
2646
- linesApiNames: ['plusDILine', 'minusDILine'],
2647
- drawGraph: MultipleLinesMixin.drawGraph,
2648
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
2649
- translate: MultipleLinesMixin.translate,
2650
- toYData: MultipleLinesMixin.toYData
2787
+ pointValKey: 'y'
2651
2788
  });
2789
+ MultipleLinesComposition.compose(DMIIndicator);
2652
2790
  SeriesRegistry.registerSeriesType('dmi', DMIIndicator);
2653
2791
  /* *
2654
2792
  *
@@ -2785,261 +2923,82 @@
2785
2923
  periodIndex = j + period - 1;
2786
2924
  rangeIndex = j + range - 1;
2787
2925
  // adding the last period point
2788
- sum = accumulatePoints(sum, yVal, periodIndex, index);
2789
- price = pick(yVal[rangeIndex][index], yVal[rangeIndex]);
2790
- oscillator = price - sum / period;
2791
- // substracting the first period point
2792
- sum = accumulatePoints(sum, yVal, j, index, true);
2793
- DPO.push([xVal[rangeIndex], oscillator]);
2794
- xData.push(xVal[rangeIndex]);
2795
- yData.push(oscillator);
2796
- }
2797
- return {
2798
- values: DPO,
2799
- xData: xData,
2800
- yData: yData
2801
- };
2802
- };
2803
- /**
2804
- * Detrended Price Oscillator. This series requires the `linkedTo` option to
2805
- * be set and should be loaded after the `stock/indicators/indicators.js`.
2806
- *
2807
- * @sample {highstock} stock/indicators/dpo
2808
- * Detrended Price Oscillator
2809
- *
2810
- * @extends plotOptions.sma
2811
- * @since 7.0.0
2812
- * @product highstock
2813
- * @excluding allAreas, colorAxis, compare, compareBase, joinBy, keys,
2814
- * navigatorOptions, pointInterval, pointIntervalUnit,
2815
- * pointPlacement, pointRange, pointStart, showInNavigator,
2816
- * stacking
2817
- * @requires stock/indicators/indicators
2818
- * @requires stock/indicators/dpo
2819
- * @optionparent plotOptions.dpo
2820
- */
2821
- DPOIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
2822
- /**
2823
- * Parameters used in calculation of Detrended Price Oscillator series
2824
- * points.
2825
- */
2826
- params: {
2827
- index: 0,
2828
- /**
2829
- * Period for Detrended Price Oscillator
2830
- */
2831
- period: 21
2832
- }
2833
- });
2834
- return DPOIndicator;
2835
- }(SMAIndicator));
2836
- extend(DPOIndicator.prototype, {
2837
- nameBase: 'DPO'
2838
- });
2839
- SeriesRegistry.registerSeriesType('dpo', DPOIndicator);
2840
- /* *
2841
- *
2842
- * Default Export
2843
- *
2844
- * */
2845
- /**
2846
- * A Detrended Price Oscillator. If the [type](#series.dpo.type) option is not
2847
- * specified, it is inherited from [chart.type](#chart.type).
2848
- *
2849
- * @extends series,plotOptions.dpo
2850
- * @since 7.0.0
2851
- * @product highstock
2852
- * @excluding allAreas, colorAxis, compare, compareBase, dataParser, dataURL,
2853
- * joinBy, keys, navigatorOptions, pointInterval, pointIntervalUnit,
2854
- * pointPlacement, pointRange, pointStart, showInNavigator, stacking
2855
- * @requires stock/indicators/indicators
2856
- * @requires stock/indicators/dpo
2857
- * @apioption series.dpo
2858
- */
2859
- ''; // to include the above in the js output'
2860
-
2861
- return DPOIndicator;
2862
- });
2863
- _registerModule(_modules, 'Stock/Indicators/EMA/EMAIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
2864
- /* *
2865
- *
2866
- * License: www.highcharts.com/license
2867
- *
2868
- * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
2869
- *
2870
- * */
2871
- var __extends = (this && this.__extends) || (function () {
2872
- var extendStatics = function (d,
2873
- b) {
2874
- extendStatics = Object.setPrototypeOf ||
2875
- ({ __proto__: [] } instanceof Array && function (d,
2876
- b) { d.__proto__ = b; }) ||
2877
- function (d,
2878
- b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
2879
- return extendStatics(d, b);
2880
- };
2881
- return function (d, b) {
2882
- extendStatics(d, b);
2883
- function __() { this.constructor = d; }
2884
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
2885
- };
2886
- })();
2887
- var SMAIndicator = SeriesRegistry.seriesTypes.sma;
2888
- var correctFloat = U.correctFloat,
2889
- isArray = U.isArray,
2890
- merge = U.merge;
2891
- /* *
2892
- *
2893
- * Class
2894
- *
2895
- * */
2896
- /**
2897
- * The EMA series type.
2898
- *
2899
- * @private
2900
- * @class
2901
- * @name Highcharts.seriesTypes.ema
2902
- *
2903
- * @augments Highcharts.Series
2904
- */
2905
- var EMAIndicator = /** @class */ (function (_super) {
2906
- __extends(EMAIndicator, _super);
2907
- function EMAIndicator() {
2908
- var _this = _super !== null && _super.apply(this,
2909
- arguments) || this;
2910
- /* *
2911
- *
2912
- * Properties
2913
- *
2914
- * */
2915
- _this.data = void 0;
2916
- _this.options = void 0;
2917
- _this.points = void 0;
2918
- return _this;
2919
- }
2920
- /* *
2921
- *
2922
- * Functions
2923
- *
2924
- * */
2925
- EMAIndicator.prototype.accumulatePeriodPoints = function (period, index, yVal) {
2926
- var sum = 0,
2927
- i = 0,
2928
- y = 0;
2929
- while (i < period) {
2930
- y = index < 0 ? yVal[i] : yVal[i][index];
2931
- sum = sum + y;
2932
- i++;
2933
- }
2934
- return sum;
2935
- };
2936
- EMAIndicator.prototype.calculateEma = function (xVal, yVal, i, EMApercent, calEMA, index, SMA) {
2937
- var x = xVal[i - 1],
2938
- yValue = index < 0 ?
2939
- yVal[i - 1] :
2940
- yVal[i - 1][index],
2941
- y;
2942
- y = typeof calEMA === 'undefined' ?
2943
- SMA : correctFloat((yValue * EMApercent) +
2944
- (calEMA * (1 - EMApercent)));
2945
- return [x, y];
2946
- };
2947
- EMAIndicator.prototype.getValues = function (series, params) {
2948
- var period = params.period,
2949
- xVal = series.xData,
2950
- yVal = series.yData,
2951
- yValLen = yVal ? yVal.length : 0,
2952
- EMApercent = 2 / (period + 1),
2953
- sum = 0,
2954
- EMA = [],
2955
- xData = [],
2956
- yData = [],
2957
- index = -1,
2958
- SMA = 0,
2959
- calEMA,
2960
- EMAPoint,
2961
- i;
2962
- // Check period, if bigger than points length, skip
2963
- if (yValLen < period) {
2964
- return;
2965
- }
2966
- // Switch index for OHLC / Candlestick / Arearange
2967
- if (isArray(yVal[0])) {
2968
- index = params.index ? params.index : 0;
2969
- }
2970
- // Accumulate first N-points
2971
- sum = this.accumulatePeriodPoints(period, index, yVal);
2972
- // first point
2973
- SMA = sum / period;
2974
- // Calculate value one-by-one for each period in visible data
2975
- for (i = period; i < yValLen + 1; i++) {
2976
- EMAPoint = this.calculateEma(xVal, yVal, i, EMApercent, calEMA, index, SMA);
2977
- EMA.push(EMAPoint);
2978
- xData.push(EMAPoint[0]);
2979
- yData.push(EMAPoint[1]);
2980
- calEMA = EMAPoint[1];
2926
+ sum = accumulatePoints(sum, yVal, periodIndex, index);
2927
+ price = pick(yVal[rangeIndex][index], yVal[rangeIndex]);
2928
+ oscillator = price - sum / period;
2929
+ // substracting the first period point
2930
+ sum = accumulatePoints(sum, yVal, j, index, true);
2931
+ DPO.push([xVal[rangeIndex], oscillator]);
2932
+ xData.push(xVal[rangeIndex]);
2933
+ yData.push(oscillator);
2981
2934
  }
2982
2935
  return {
2983
- values: EMA,
2936
+ values: DPO,
2984
2937
  xData: xData,
2985
2938
  yData: yData
2986
2939
  };
2987
2940
  };
2988
2941
  /**
2989
- * Exponential moving average indicator (EMA). This series requires the
2990
- * `linkedTo` option to be set.
2942
+ * Detrended Price Oscillator. This series requires the `linkedTo` option to
2943
+ * be set and should be loaded after the `stock/indicators/indicators.js`.
2991
2944
  *
2992
- * @sample stock/indicators/ema
2993
- * Exponential moving average indicator
2945
+ * @sample {highstock} stock/indicators/dpo
2946
+ * Detrended Price Oscillator
2994
2947
  *
2995
2948
  * @extends plotOptions.sma
2996
- * @since 6.0.0
2949
+ * @since 7.0.0
2997
2950
  * @product highstock
2951
+ * @excluding allAreas, colorAxis, compare, compareBase, joinBy, keys,
2952
+ * navigatorOptions, pointInterval, pointIntervalUnit,
2953
+ * pointPlacement, pointRange, pointStart, showInNavigator,
2954
+ * stacking
2998
2955
  * @requires stock/indicators/indicators
2999
- * @requires stock/indicators/ema
3000
- * @optionparent plotOptions.ema
2956
+ * @requires stock/indicators/dpo
2957
+ * @optionparent plotOptions.dpo
3001
2958
  */
3002
- EMAIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
2959
+ DPOIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
2960
+ /**
2961
+ * Parameters used in calculation of Detrended Price Oscillator series
2962
+ * points.
2963
+ */
3003
2964
  params: {
2965
+ index: 0,
3004
2966
  /**
3005
- * The point index which indicator calculations will base. For
3006
- * example using OHLC data, index=2 means the indicator will be
3007
- * calculated using Low values.
3008
- *
3009
- * By default index value used to be set to 0. Since
3010
- * Highcharts Stock 7 by default index is set to 3
3011
- * which means that the ema indicator will be
3012
- * calculated using Close values.
2967
+ * Period for Detrended Price Oscillator
3013
2968
  */
3014
- index: 3,
3015
- period: 9 // @merge 14 in v6.2
2969
+ period: 21
3016
2970
  }
3017
2971
  });
3018
- return EMAIndicator;
2972
+ return DPOIndicator;
3019
2973
  }(SMAIndicator));
3020
- SeriesRegistry.registerSeriesType('ema', EMAIndicator);
2974
+ extend(DPOIndicator.prototype, {
2975
+ nameBase: 'DPO'
2976
+ });
2977
+ SeriesRegistry.registerSeriesType('dpo', DPOIndicator);
3021
2978
  /* *
3022
2979
  *
3023
2980
  * Default Export
3024
2981
  *
3025
2982
  * */
3026
2983
  /**
3027
- * A `EMA` series. If the [type](#series.ema.type) option is not
2984
+ * A Detrended Price Oscillator. If the [type](#series.dpo.type) option is not
3028
2985
  * specified, it is inherited from [chart.type](#chart.type).
3029
2986
  *
3030
- * @extends series,plotOptions.ema
3031
- * @since 6.0.0
2987
+ * @extends series,plotOptions.dpo
2988
+ * @since 7.0.0
3032
2989
  * @product highstock
3033
- * @excluding dataParser, dataURL
2990
+ * @excluding allAreas, colorAxis, compare, compareBase, dataParser, dataURL,
2991
+ * joinBy, keys, navigatorOptions, pointInterval, pointIntervalUnit,
2992
+ * pointPlacement, pointRange, pointStart, showInNavigator, stacking
3034
2993
  * @requires stock/indicators/indicators
3035
- * @requires stock/indicators/ema
3036
- * @apioption series.ema
2994
+ * @requires stock/indicators/dpo
2995
+ * @apioption series.dpo
3037
2996
  */
3038
- ''; // adds doclet above to the transpiled file
2997
+ ''; // to include the above in the js output'
3039
2998
 
3040
- return EMAIndicator;
2999
+ return DPOIndicator;
3041
3000
  });
3042
- _registerModule(_modules, 'Stock/Indicators/Chaikin/ChaikinIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
3001
+ _registerModule(_modules, 'Stock/Indicators/Chaikin/ChaikinIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
3043
3002
  /* *
3044
3003
  *
3045
3004
  * License: www.highcharts.com/license
@@ -3087,6 +3046,11 @@
3087
3046
  var ChaikinIndicator = /** @class */ (function (_super) {
3088
3047
  __extends(ChaikinIndicator, _super);
3089
3048
  function ChaikinIndicator() {
3049
+ /* *
3050
+ *
3051
+ * Static Properties
3052
+ *
3053
+ * */
3090
3054
  var _this = _super !== null && _super.apply(this,
3091
3055
  arguments) || this;
3092
3056
  /* *
@@ -3104,14 +3068,6 @@
3104
3068
  * Functions
3105
3069
  *
3106
3070
  * */
3107
- ChaikinIndicator.prototype.init = function () {
3108
- var args = arguments,
3109
- ctx = this;
3110
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
3111
- indicator.prototype.init.apply(ctx, args);
3112
- return;
3113
- });
3114
- };
3115
3071
  ChaikinIndicator.prototype.getValues = function (series, params) {
3116
3072
  var periods = params.periods,
3117
3073
  period = params.period,
@@ -3168,8 +3124,7 @@
3168
3124
  };
3169
3125
  /**
3170
3126
  * Chaikin Oscillator. This series requires the `linkedTo` option to
3171
- * be set and should be loaded after the `stock/indicators/indicators.js`
3172
- * and `stock/indicators/ema.js`.
3127
+ * be set and should be loaded after the `stock/indicators/indicators.js`.
3173
3128
  *
3174
3129
  * @sample {highstock} stock/indicators/chaikin
3175
3130
  * Chaikin Oscillator
@@ -3181,7 +3136,6 @@
3181
3136
  * pointInterval, pointIntervalUnit, pointPlacement,
3182
3137
  * pointRange, pointStart, showInNavigator, stacking
3183
3138
  * @requires stock/indicators/indicators
3184
- * @requires stock/indicators/ema
3185
3139
  * @requires stock/indicators/chaikin
3186
3140
  * @optionparent plotOptions.chaikin
3187
3141
  */
@@ -3238,7 +3192,6 @@
3238
3192
  * navigatorOptions, pointInterval, pointIntervalUnit,
3239
3193
  * pointPlacement, pointRange, pointStart, stacking, showInNavigator
3240
3194
  * @requires stock/indicators/indicators
3241
- * @requires stock/indicators/ema
3242
3195
  * @requires stock/indicators/chaikin
3243
3196
  * @apioption series.chaikin
3244
3197
  */
@@ -3428,7 +3381,7 @@
3428
3381
 
3429
3382
  return CMOIndicator;
3430
3383
  });
3431
- _registerModule(_modules, 'Stock/Indicators/DEMA/DEMAIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
3384
+ _registerModule(_modules, 'Stock/Indicators/DEMA/DEMAIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
3432
3385
  /* *
3433
3386
  *
3434
3387
  * License: www.highcharts.com/license
@@ -3476,14 +3429,6 @@
3476
3429
  _this.points = void 0;
3477
3430
  return _this;
3478
3431
  }
3479
- DEMAIndicator.prototype.init = function () {
3480
- var args = arguments,
3481
- ctx = this;
3482
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
3483
- indicator.prototype.init.apply(ctx, args);
3484
- return;
3485
- });
3486
- };
3487
3432
  DEMAIndicator.prototype.getEMA = function (yVal, prevEMA, SMA, index, i, xVal) {
3488
3433
  return EMAIndicator.prototype.calculateEma(xVal || [], yVal, typeof i === 'undefined' ? 1 : i, this.EMApercent, prevEMA, typeof index === 'undefined' ? -1 : index, SMA);
3489
3434
  };
@@ -3562,7 +3507,7 @@
3562
3507
  /**
3563
3508
  * Double exponential moving average (DEMA) indicator. This series requires
3564
3509
  * `linkedTo` option to be set and should be loaded after the
3565
- * `stock/indicators/indicators.js` and `stock/indicators/ema.js`.
3510
+ * `stock/indicators/indicators.js`.
3566
3511
  *
3567
3512
  * @sample {highstock} stock/indicators/dema
3568
3513
  * DEMA indicator
@@ -3575,7 +3520,6 @@
3575
3520
  * pointPlacement, pointRange, pointStart, showInNavigator,
3576
3521
  * stacking
3577
3522
  * @requires stock/indicators/indicators
3578
- * @requires stock/indicators/ema
3579
3523
  * @requires stock/indicators/dema
3580
3524
  * @optionparent plotOptions.dema
3581
3525
  */
@@ -3599,7 +3543,6 @@
3599
3543
  * joinBy, keys, navigatorOptions, pointInterval, pointIntervalUnit,
3600
3544
  * pointPlacement, pointRange, pointStart, showInNavigator, stacking
3601
3545
  * @requires stock/indicators/indicators
3602
- * @requires stock/indicators/ema
3603
3546
  * @requires stock/indicators/dema
3604
3547
  * @apioption series.dema
3605
3548
  */
@@ -3607,7 +3550,7 @@
3607
3550
 
3608
3551
  return DEMAIndicator;
3609
3552
  });
3610
- _registerModule(_modules, 'Stock/Indicators/TEMA/TEMAIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
3553
+ _registerModule(_modules, 'Stock/Indicators/TEMA/TEMAIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
3611
3554
  /* *
3612
3555
  *
3613
3556
  * License: www.highcharts.com/license
@@ -3635,6 +3578,11 @@
3635
3578
  var correctFloat = U.correctFloat,
3636
3579
  isArray = U.isArray,
3637
3580
  merge = U.merge;
3581
+ /* *
3582
+ *
3583
+ * Class
3584
+ *
3585
+ * */
3638
3586
  /**
3639
3587
  * The TEMA series type.
3640
3588
  *
@@ -3647,22 +3595,29 @@
3647
3595
  var TEMAIndicator = /** @class */ (function (_super) {
3648
3596
  __extends(TEMAIndicator, _super);
3649
3597
  function TEMAIndicator() {
3598
+ /* *
3599
+ *
3600
+ * Static Properties
3601
+ *
3602
+ * */
3650
3603
  var _this = _super !== null && _super.apply(this,
3651
3604
  arguments) || this;
3605
+ /* *
3606
+ *
3607
+ * Properties
3608
+ *
3609
+ * */
3652
3610
  _this.EMApercent = void 0;
3653
3611
  _this.data = void 0;
3654
3612
  _this.options = void 0;
3655
3613
  _this.points = void 0;
3656
3614
  return _this;
3657
3615
  }
3658
- TEMAIndicator.prototype.init = function () {
3659
- var args = arguments,
3660
- ctx = this;
3661
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
3662
- indicator.prototype.init.apply(ctx, args);
3663
- return;
3664
- });
3665
- };
3616
+ /* *
3617
+ *
3618
+ * Functions
3619
+ *
3620
+ * */
3666
3621
  TEMAIndicator.prototype.getEMA = function (yVal, prevEMA, SMA, index, i, xVal) {
3667
3622
  return EMAIndicator.prototype.calculateEma(xVal || [], yVal, typeof i === 'undefined' ? 1 : i, this.EMApercent, prevEMA, typeof index === 'undefined' ? -1 : index, SMA);
3668
3623
  };
@@ -3776,7 +3731,7 @@
3776
3731
  /**
3777
3732
  * Triple exponential moving average (TEMA) indicator. This series requires
3778
3733
  * `linkedTo` option to be set and should be loaded after the
3779
- * `stock/indicators/indicators.js` and `stock/indicators/ema.js`.
3734
+ * `stock/indicators/indicators.js`.
3780
3735
  *
3781
3736
  * @sample {highstock} stock/indicators/tema
3782
3737
  * TEMA indicator
@@ -3789,7 +3744,6 @@
3789
3744
  * pointPlacement, pointRange, pointStart, showInNavigator,
3790
3745
  * stacking
3791
3746
  * @requires stock/indicators/indicators
3792
- * @requires stock/indicators/ema
3793
3747
  * @requires stock/indicators/tema
3794
3748
  * @optionparent plotOptions.tema
3795
3749
  */
@@ -3802,6 +3756,11 @@
3802
3756
  * Default Export
3803
3757
  *
3804
3758
  * */
3759
+ /* *
3760
+ *
3761
+ * API Options
3762
+ *
3763
+ * */
3805
3764
  /**
3806
3765
  * A `TEMA` series. If the [type](#series.tema.type) option is not
3807
3766
  * specified, it is inherited from [chart.type](#chart.type).
@@ -3813,7 +3772,6 @@
3813
3772
  * joinBy, keys, navigatorOptions, pointInterval, pointIntervalUnit,
3814
3773
  * pointPlacement, pointRange, pointStart, showInNavigator, stacking
3815
3774
  * @requires stock/indicators/indicators
3816
- * @requires stock/indicators/ema
3817
3775
  * @requires stock/indicators/tema
3818
3776
  * @apioption series.tema
3819
3777
  */
@@ -3821,7 +3779,7 @@
3821
3779
 
3822
3780
  return TEMAIndicator;
3823
3781
  });
3824
- _registerModule(_modules, 'Stock/Indicators/TRIX/TRIXIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
3782
+ _registerModule(_modules, 'Stock/Indicators/TRIX/TRIXIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
3825
3783
  /* *
3826
3784
  *
3827
3785
  * License: www.highcharts.com/license
@@ -3867,14 +3825,6 @@
3867
3825
  _this.points = void 0;
3868
3826
  return _this;
3869
3827
  }
3870
- TRIXIndicator.prototype.init = function () {
3871
- var args = arguments,
3872
- ctx = this;
3873
- RequiredIndicatorMixin.isParentLoaded(SeriesRegistry.seriesTypes.tema, 'tema', ctx.type, function (indicator) {
3874
- indicator.prototype.init.apply(ctx, args);
3875
- return;
3876
- });
3877
- };
3878
3828
  // TRIX is calculated using TEMA so we just extend getTemaPoint method.
3879
3829
  TRIXIndicator.prototype.getTemaPoint = function (xVal, tripledPeriod, EMAlevels, i) {
3880
3830
  if (i > tripledPeriod) {
@@ -3890,11 +3840,8 @@
3890
3840
  * Triple exponential average (TRIX) oscillator. This series requires
3891
3841
  * `linkedTo` option to be set.
3892
3842
  *
3893
- * Requires https://code.highcharts.com/stock/indicators/ema.js
3894
- * and https://code.highcharts.com/stock/indicators/tema.js.
3895
- *
3896
3843
  * @sample {highstock} stock/indicators/trix
3897
- * TRIX indicator
3844
+ * TRIX indicator
3898
3845
  *
3899
3846
  * @extends plotOptions.tema
3900
3847
  * @since 7.0.0
@@ -3903,6 +3850,9 @@
3903
3850
  * navigatorOptions, pointInterval, pointIntervalUnit,
3904
3851
  * pointPlacement, pointRange, pointStart, showInNavigator,
3905
3852
  * stacking
3853
+ * @requires stock/indicators/indicators
3854
+ * @requires stock/indicators/tema
3855
+ * @requires stock/indicators/trix
3906
3856
  * @optionparent plotOptions.trix
3907
3857
  */
3908
3858
  TRIXIndicator.defaultOptions = merge(TEMAIndicator.defaultOptions);
@@ -3924,13 +3874,15 @@
3924
3874
  * @excluding allAreas, colorAxis, compare, compareBase, dataParser, dataURL,
3925
3875
  * joinBy, keys, navigatorOptions, pointInterval, pointIntervalUnit,
3926
3876
  * pointPlacement, pointRange, pointStart, showInNavigator, stacking
3877
+ * @requires stock/indicators/indicators
3878
+ * @requires stock/indicators/tema
3927
3879
  * @apioption series.trix
3928
3880
  */
3929
3881
  ''; // to include the above in the js output
3930
3882
 
3931
3883
  return TRIXIndicator;
3932
3884
  });
3933
- _registerModule(_modules, 'Stock/Indicators/APO/APOIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
3885
+ _registerModule(_modules, 'Stock/Indicators/APO/APOIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
3934
3886
  /* *
3935
3887
  *
3936
3888
  * License: www.highcharts.com/license
@@ -3975,23 +3927,28 @@
3975
3927
  var APOIndicator = /** @class */ (function (_super) {
3976
3928
  __extends(APOIndicator, _super);
3977
3929
  function APOIndicator() {
3930
+ /* *
3931
+ *
3932
+ * Static Properties
3933
+ *
3934
+ * */
3978
3935
  var _this = _super !== null && _super.apply(this,
3979
3936
  arguments) || this;
3980
3937
  /* *
3981
- *
3982
- * Properties
3983
- *
3984
- * */
3938
+ *
3939
+ * Properties
3940
+ *
3941
+ * */
3985
3942
  _this.data = void 0;
3986
3943
  _this.options = void 0;
3987
3944
  _this.points = void 0;
3988
3945
  return _this;
3989
3946
  }
3990
3947
  /* *
3991
- *
3992
- * Functions
3993
- *
3994
- * */
3948
+ *
3949
+ * Functions
3950
+ *
3951
+ * */
3995
3952
  APOIndicator.prototype.getValues = function (series, params) {
3996
3953
  var periods = params.periods,
3997
3954
  index = params.index,
@@ -4038,18 +3995,9 @@
4038
3995
  yData: yData
4039
3996
  };
4040
3997
  };
4041
- APOIndicator.prototype.init = function () {
4042
- var args = arguments,
4043
- ctx = this;
4044
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
4045
- indicator.prototype.init.apply(ctx, args);
4046
- return;
4047
- });
4048
- };
4049
3998
  /**
4050
3999
  * Absolute Price Oscillator. This series requires the `linkedTo` option to
4051
- * be set and should be loaded after the `stock/indicators/indicators.js`
4052
- * and `stock/indicators/ema.js`.
4000
+ * be set and should be loaded after the `stock/indicators/indicators.js`.
4053
4001
  *
4054
4002
  * @sample {highstock} stock/indicators/apo
4055
4003
  * Absolute Price Oscillator
@@ -4061,7 +4009,6 @@
4061
4009
  * pointInterval, pointIntervalUnit, pointPlacement,
4062
4010
  * pointRange, pointStart, showInNavigator, stacking
4063
4011
  * @requires stock/indicators/indicators
4064
- * @requires stock/indicators/ema
4065
4012
  * @requires stock/indicators/apo
4066
4013
  * @optionparent plotOptions.apo
4067
4014
  */
@@ -4107,7 +4054,6 @@
4107
4054
  * navigatorOptions, pointInterval, pointIntervalUnit,
4108
4055
  * pointPlacement, pointRange, pointStart, showInNavigator, stacking
4109
4056
  * @requires stock/indicators/indicators
4110
- * @requires stock/indicators/ema
4111
4057
  * @requires stock/indicators/apo
4112
4058
  * @apioption series.apo
4113
4059
  */
@@ -4868,7 +4814,7 @@
4868
4814
 
4869
4815
  return IKHIndicator;
4870
4816
  });
4871
- _registerModule(_modules, 'Stock/Indicators/KeltnerChannels/KeltnerChannelsIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, SeriesRegistry, U) {
4817
+ _registerModule(_modules, 'Stock/Indicators/KeltnerChannels/KeltnerChannelsIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
4872
4818
  /* *
4873
4819
  *
4874
4820
  * License: www.highcharts.com/license
@@ -4892,10 +4838,7 @@
4892
4838
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
4893
4839
  };
4894
4840
  })();
4895
- var _a = SeriesRegistry.seriesTypes,
4896
- SMAIndicator = _a.sma,
4897
- EMAIndicator = _a.ema,
4898
- ATRIndicator = _a.atr;
4841
+ var SMAIndicator = SeriesRegistry.seriesTypes.sma;
4899
4842
  var correctFloat = U.correctFloat,
4900
4843
  extend = U.extend,
4901
4844
  merge = U.merge;
@@ -5002,6 +4945,12 @@
5002
4945
  */
5003
4946
  KeltnerChannelsIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
5004
4947
  params: {
4948
+ /**
4949
+ * The point index which indicator calculations will base. For
4950
+ * example using OHLC data, index=2 means the indicator will be
4951
+ * calculated using Low values.
4952
+ */
4953
+ index: 0,
5005
4954
  period: 20,
5006
4955
  /**
5007
4956
  * The ATR period.
@@ -5058,17 +5007,13 @@
5058
5007
  return KeltnerChannelsIndicator;
5059
5008
  }(SMAIndicator));
5060
5009
  extend(KeltnerChannelsIndicator.prototype, {
5061
- pointArrayMap: ['top', 'middle', 'bottom'],
5062
- pointValKey: 'middle',
5063
5010
  nameBase: 'Keltner Channels',
5064
5011
  nameComponents: ['period', 'periodATR', 'multiplierATR'],
5065
5012
  linesApiNames: ['topLine', 'bottomLine'],
5066
- requiredIndicators: ['ema', 'atr'],
5067
- drawGraph: MultipleLinesMixin.drawGraph,
5068
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
5069
- translate: MultipleLinesMixin.translate,
5070
- toYData: MultipleLinesMixin.toYData
5013
+ pointArrayMap: ['top', 'middle', 'bottom'],
5014
+ pointValKey: 'middle'
5071
5015
  });
5016
+ MultipleLinesComposition.compose(KeltnerChannelsIndicator);
5072
5017
  SeriesRegistry.registerSeriesType('keltnerchannels', KeltnerChannelsIndicator);
5073
5018
  /* *
5074
5019
  *
@@ -5094,7 +5039,7 @@
5094
5039
 
5095
5040
  return KeltnerChannelsIndicator;
5096
5041
  });
5097
- _registerModule(_modules, 'Stock/Indicators/Klinger/KlingerIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Mixins/MultipleLines.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, MultipleLinesMixin, SeriesRegistry, U) {
5042
+ _registerModule(_modules, 'Stock/Indicators/Klinger/KlingerIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
5098
5043
  /* *
5099
5044
  *
5100
5045
  * License: www.highcharts.com/license
@@ -5138,6 +5083,11 @@
5138
5083
  var KlingerIndicator = /** @class */ (function (_super) {
5139
5084
  __extends(KlingerIndicator, _super);
5140
5085
  function KlingerIndicator() {
5086
+ /* *
5087
+ *
5088
+ * Static Properties
5089
+ *
5090
+ * */
5141
5091
  var _this = _super !== null && _super.apply(this,
5142
5092
  arguments) || this;
5143
5093
  /* *
@@ -5156,15 +5106,6 @@
5156
5106
  * Functions
5157
5107
  *
5158
5108
  * */
5159
- KlingerIndicator.prototype.init = function () {
5160
- var args = arguments,
5161
- ctx = this;
5162
- // Check if the EMA module is added.
5163
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
5164
- indicator.prototype.init.apply(ctx, args);
5165
- return;
5166
- });
5167
- };
5168
5109
  KlingerIndicator.prototype.calculateTrend = function (yVal, i) {
5169
5110
  var isUpward = yVal[i][1] + yVal[i][2] + yVal[i][3] >
5170
5111
  yVal[i - 1][1] + yVal[i - 1][2] + yVal[i - 1][3];
@@ -5370,12 +5311,9 @@
5370
5311
  nameComponents: ['fastAvgPeriod', 'slowAvgPeriod'],
5371
5312
  pointArrayMap: ['y', 'signal'],
5372
5313
  parallelArrays: ['x', 'y', 'signal'],
5373
- pointValKey: 'y',
5374
- drawGraph: MultipleLinesMixin.drawGraph,
5375
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
5376
- translate: MultipleLinesMixin.translate,
5377
- toYData: MultipleLinesMixin.toYData
5314
+ pointValKey: 'y'
5378
5315
  });
5316
+ MultipleLinesComposition.compose(KlingerIndicator);
5379
5317
  SeriesRegistry.registerSeriesType('klinger', KlingerIndicator);
5380
5318
  /* *
5381
5319
  *
@@ -5390,7 +5328,6 @@
5390
5328
  * @since 9.1.0
5391
5329
  * @product highstock
5392
5330
  * @requires stock/indicators/indicators
5393
- * @requires stock/indicators/ema
5394
5331
  * @requires stock/indicators/klinger
5395
5332
  * @apioption series.klinger
5396
5333
  */
@@ -5688,7 +5625,7 @@
5688
5625
  /**
5689
5626
  * Moving Average Convergence Divergence (MACD). This series requires
5690
5627
  * `linkedTo` option to be set and should be loaded after the
5691
- * `stock/indicators/indicators.js` and `stock/indicators/ema.js`.
5628
+ * `stock/indicators/indicators.js`.
5692
5629
  *
5693
5630
  * @sample stock/indicators/macd
5694
5631
  * MACD indicator
@@ -5793,7 +5730,6 @@
5793
5730
  }(SMAIndicator));
5794
5731
  extend(MACDIndicator.prototype, {
5795
5732
  nameComponents: ['longPeriod', 'shortPeriod', 'signalPeriod'],
5796
- requiredIndicators: ['ema'],
5797
5733
  // "y" value is treated as Histogram data
5798
5734
  pointArrayMap: ['y', 'signal', 'MACD'],
5799
5735
  parallelArrays: ['x', 'y', 'signal', 'MACD'],
@@ -6287,9 +6223,6 @@
6287
6223
  });
6288
6224
  return NATRIndicator;
6289
6225
  }(ATRIndicator));
6290
- extend(NATRIndicator.prototype, {
6291
- requiredIndicators: ['atr']
6292
- });
6293
6226
  SeriesRegistry.registerSeriesType('natr', NATRIndicator);
6294
6227
  /* *
6295
6228
  *
@@ -6305,6 +6238,7 @@
6305
6238
  * @product highstock
6306
6239
  * @excluding dataParser, dataURL
6307
6240
  * @requires stock/indicators/indicators
6241
+ * @requires stock/indicators/atr
6308
6242
  * @requires stock/indicators/natr
6309
6243
  * @apioption series.natr
6310
6244
  */
@@ -6943,7 +6877,7 @@
6943
6877
 
6944
6878
  return PivotPointsIndicator;
6945
6879
  });
6946
- _registerModule(_modules, 'Stock/Indicators/PPO/PPOIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
6880
+ _registerModule(_modules, 'Stock/Indicators/PPO/PPOIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
6947
6881
  /* *
6948
6882
  *
6949
6883
  * License: www.highcharts.com/license
@@ -7006,14 +6940,6 @@
7006
6940
  * Functions
7007
6941
  *
7008
6942
  * */
7009
- PPOIndicator.prototype.init = function () {
7010
- var args = arguments,
7011
- ctx = this;
7012
- RequiredIndicatorMixin.isParentLoaded(EMAIndicator, 'ema', ctx.type, function (indicator) {
7013
- indicator.prototype.init.apply(ctx, args);
7014
- return;
7015
- });
7016
- };
7017
6943
  PPOIndicator.prototype.getValues = function (series, params) {
7018
6944
  var periods = params.periods,
7019
6945
  index = params.index,
@@ -7065,7 +6991,7 @@
7065
6991
  /**
7066
6992
  * Percentage Price Oscillator. This series requires the
7067
6993
  * `linkedTo` option to be set and should be loaded after the
7068
- * `stock/indicators/indicators.js` and `stock/indicators/ema.js`.
6994
+ * `stock/indicators/indicators.js`.
7069
6995
  *
7070
6996
  * @sample {highstock} stock/indicators/ppo
7071
6997
  * Percentage Price Oscillator
@@ -7077,7 +7003,6 @@
7077
7003
  * pointInterval, pointIntervalUnit, pointPlacement,
7078
7004
  * pointRange, pointStart, showInNavigator, stacking
7079
7005
  * @requires stock/indicators/indicators
7080
- * @requires stock/indicators/ema
7081
7006
  * @requires stock/indicators/ppo
7082
7007
  * @optionparent plotOptions.ppo
7083
7008
  */
@@ -7122,7 +7047,6 @@
7122
7047
  * navigatorOptions, pointInterval, pointIntervalUnit,
7123
7048
  * pointPlacement, pointRange, pointStart, showInNavigator, stacking
7124
7049
  * @requires stock/indicators/indicators
7125
- * @requires stock/indicators/ema
7126
7050
  * @requires stock/indicators/ppo
7127
7051
  * @apioption series.ppo
7128
7052
  */
@@ -7130,7 +7054,7 @@
7130
7054
 
7131
7055
  return PPOIndicator;
7132
7056
  });
7133
- _registerModule(_modules, 'Mixins/ReduceArray.js', [], function () {
7057
+ _registerModule(_modules, 'Stock/Indicators/ArrayUtilities.js', [], function () {
7134
7058
  /**
7135
7059
  *
7136
7060
  * (c) 2010-2021 Pawel Fus & Daniel Studencki
@@ -7140,55 +7064,46 @@
7140
7064
  * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
7141
7065
  *
7142
7066
  * */
7143
- var reduceArrayMixin = {
7144
- /**
7145
- * Get min value of array filled by OHLC data.
7146
- * @private
7147
- * @param {Array<*>} arr Array of OHLC points (arrays).
7148
- * @param {string} index Index of "low" value in point array.
7149
- * @return {number} Returns min value.
7150
- */
7151
- minInArray: function (arr,
7152
- index) {
7153
- return arr.reduce(function (min,
7154
- target) {
7155
- return Math.min(min,
7156
- target[index]);
7157
- }, Number.MAX_VALUE);
7158
- },
7159
- /**
7160
- * Get max value of array filled by OHLC data.
7161
- * @private
7162
- * @param {Array<*>} arr Array of OHLC points (arrays).
7163
- * @param {string} index Index of "high" value in point array.
7164
- * @return {number} Returns max value.
7165
- */
7166
- maxInArray: function (arr, index) {
7167
- return arr.reduce(function (max, target) {
7168
- return Math.max(max, target[index]);
7169
- }, -Number.MAX_VALUE);
7170
- },
7171
- /**
7172
- * Get extremes of array filled by OHLC data.
7173
- * @private
7174
- * @param {Array<*>} arr Array of OHLC points (arrays).
7175
- * @param {string} minIndex Index of "low" value in point array.
7176
- * @param {string} maxIndex Index of "high" value in point array.
7177
- * @return {Array<number,number>} Returns array with min and max value.
7178
- */
7179
- getArrayExtremes: function (arr, minIndex, maxIndex) {
7180
- return arr.reduce(function (prev, target) {
7181
- return [
7182
- Math.min(prev[0], target[minIndex]),
7183
- Math.max(prev[1], target[maxIndex])
7184
- ];
7185
- }, [Number.MAX_VALUE, -Number.MAX_VALUE]);
7186
- }
7187
- };
7067
+ /* *
7068
+ *
7069
+ * Functions
7070
+ *
7071
+ * */
7072
+ /**
7073
+ * Get extremes of array filled by OHLC data.
7074
+ *
7075
+ * @private
7076
+ *
7077
+ * @param {Array<Array<number>>} arr
7078
+ * Array of OHLC points (arrays).
7079
+ *
7080
+ * @param {number} minIndex
7081
+ * Index of "low" value in point array.
7082
+ *
7083
+ * @param {number} maxIndex
7084
+ * Index of "high" value in point array.
7085
+ *
7086
+ * @return {Array<number,number>}
7087
+ * Returns array with min and max value.
7088
+ */
7089
+ function getArrayExtremes(arr, minIndex, maxIndex) {
7090
+ return arr.reduce(function (prev, target) { return [
7091
+ Math.min(prev[0], target[minIndex]),
7092
+ Math.max(prev[1], target[maxIndex])
7093
+ ]; }, [Number.MAX_VALUE, -Number.MAX_VALUE]);
7094
+ }
7095
+ /* *
7096
+ *
7097
+ * Default Export
7098
+ *
7099
+ * */
7100
+ var ArrayUtilities = {
7101
+ getArrayExtremes: getArrayExtremes
7102
+ };
7188
7103
 
7189
- return reduceArrayMixin;
7104
+ return ArrayUtilities;
7190
7105
  });
7191
- _registerModule(_modules, 'Stock/Indicators/PC/PCIndicator.js', [_modules['Core/Color/Palette.js'], _modules['Mixins/MultipleLines.js'], _modules['Mixins/ReduceArray.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (palette, MultipleLinesMixin, ReduceArrayMixin, SeriesRegistry, U) {
7106
+ _registerModule(_modules, 'Stock/Indicators/PC/PCIndicator.js', [_modules['Stock/Indicators/ArrayUtilities.js'], _modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Color/Palettes.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (AU, MultipleLinesComposition, Palettes, SeriesRegistry, U) {
7192
7107
  /* *
7193
7108
  *
7194
7109
  * License: www.highcharts.com/license
@@ -7215,7 +7130,6 @@
7215
7130
  var SMAIndicator = SeriesRegistry.seriesTypes.sma;
7216
7131
  var merge = U.merge,
7217
7132
  extend = U.extend;
7218
- var getArrayExtremes = ReduceArrayMixin.getArrayExtremes;
7219
7133
  /* *
7220
7134
  *
7221
7135
  * Class
@@ -7233,6 +7147,11 @@
7233
7147
  var PCIndicator = /** @class */ (function (_super) {
7234
7148
  __extends(PCIndicator, _super);
7235
7149
  function PCIndicator() {
7150
+ /* *
7151
+ *
7152
+ * Static Properties
7153
+ *
7154
+ * */
7236
7155
  var _this = _super !== null && _super.apply(this,
7237
7156
  arguments) || this;
7238
7157
  /* *
@@ -7275,7 +7194,7 @@
7275
7194
  for (i = period; i <= yValLen; i++) {
7276
7195
  date = xVal[i - 1];
7277
7196
  slicedY = yVal.slice(i - period, i);
7278
- extremes = getArrayExtremes(slicedY, low, high);
7197
+ extremes = AU.getArrayExtremes(slicedY, low, high);
7279
7198
  TL = extremes[1];
7280
7199
  BL = extremes[0];
7281
7200
  ML = (TL + BL) / 2;
@@ -7324,7 +7243,7 @@
7324
7243
  *
7325
7244
  * @type {Highcharts.ColorString}
7326
7245
  */
7327
- lineColor: palette.colors[2],
7246
+ lineColor: Palettes.colors[2],
7328
7247
  /**
7329
7248
  * Pixel width of the line.
7330
7249
  */
@@ -7339,7 +7258,7 @@
7339
7258
  *
7340
7259
  * @type {Highcharts.ColorString}
7341
7260
  */
7342
- lineColor: palette.colors[8],
7261
+ lineColor: Palettes.colors[8],
7343
7262
  /**
7344
7263
  * Pixel width of the line.
7345
7264
  */
@@ -7353,16 +7272,13 @@
7353
7272
  return PCIndicator;
7354
7273
  }(SMAIndicator));
7355
7274
  extend(PCIndicator.prototype, {
7356
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
7357
- drawGraph: MultipleLinesMixin.drawGraph,
7358
- toYData: MultipleLinesMixin.toYData,
7359
- pointArrayMap: ['top', 'middle', 'bottom'],
7360
- pointValKey: 'middle',
7361
7275
  nameBase: 'Price Channel',
7362
7276
  nameComponents: ['period'],
7363
7277
  linesApiNames: ['topLine', 'bottomLine'],
7364
- translate: MultipleLinesMixin.translate
7278
+ pointArrayMap: ['top', 'middle', 'bottom'],
7279
+ pointValKey: 'middle'
7365
7280
  });
7281
+ MultipleLinesComposition.compose(PCIndicator);
7366
7282
  SeriesRegistry.registerSeriesType('pc', PCIndicator);
7367
7283
  /* *
7368
7284
  *
@@ -8346,7 +8262,7 @@
8346
8262
 
8347
8263
  return RSIIndicator;
8348
8264
  });
8349
- _registerModule(_modules, 'Stock/Indicators/Stochastic/StochasticIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Mixins/ReduceArray.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, ReduceArrayMixin, SeriesRegistry, U) {
8265
+ _registerModule(_modules, 'Stock/Indicators/Stochastic/StochasticIndicator.js', [_modules['Stock/Indicators/ArrayUtilities.js'], _modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (AU, MultipleLinesComposition, SeriesRegistry, U) {
8350
8266
  /* *
8351
8267
  *
8352
8268
  * License: www.highcharts.com/license
@@ -8374,6 +8290,11 @@
8374
8290
  var extend = U.extend,
8375
8291
  isArray = U.isArray,
8376
8292
  merge = U.merge;
8293
+ /* *
8294
+ *
8295
+ * Class
8296
+ *
8297
+ * */
8377
8298
  /**
8378
8299
  * The Stochastic series type.
8379
8300
  *
@@ -8386,6 +8307,11 @@
8386
8307
  var StochasticIndicator = /** @class */ (function (_super) {
8387
8308
  __extends(StochasticIndicator, _super);
8388
8309
  function StochasticIndicator() {
8310
+ /* *
8311
+ *
8312
+ * Static Properties
8313
+ *
8314
+ * */
8389
8315
  var _this = _super !== null && _super.apply(this,
8390
8316
  arguments) || this;
8391
8317
  _this.data = void 0;
@@ -8438,7 +8364,7 @@
8438
8364
  for (i = periodK - 1; i < yValLen; i++) {
8439
8365
  slicedY = yVal.slice(i - periodK + 1, i + 1);
8440
8366
  // Calculate %K
8441
- extremes = ReduceArrayMixin.getArrayExtremes(slicedY, low, high);
8367
+ extremes = AU.getArrayExtremes(slicedY, low, high);
8442
8368
  LL = extremes[0]; // Lowest low in %K periods
8443
8369
  CL = yVal[i][close] - LL;
8444
8370
  HL = extremes[1] - LL;
@@ -8537,12 +8463,9 @@
8537
8463
  pointArrayMap: ['y', 'smoothed'],
8538
8464
  parallelArrays: ['x', 'y', 'smoothed'],
8539
8465
  pointValKey: 'y',
8540
- linesApiNames: ['smoothedLine'],
8541
- drawGraph: MultipleLinesMixin.drawGraph,
8542
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
8543
- translate: MultipleLinesMixin.translate,
8544
- toYData: MultipleLinesMixin.toYData
8466
+ linesApiNames: ['smoothedLine']
8545
8467
  });
8468
+ MultipleLinesComposition.compose(StochasticIndicator);
8546
8469
  SeriesRegistry.registerSeriesType('stochastic', StochasticIndicator);
8547
8470
  /* *
8548
8471
  *
@@ -8567,7 +8490,7 @@
8567
8490
 
8568
8491
  return StochasticIndicator;
8569
8492
  });
8570
- _registerModule(_modules, 'Stock/Indicators/SlowStochastic/SlowStochasticIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
8493
+ _registerModule(_modules, 'Stock/Indicators/SlowStochastic/SlowStochasticIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
8571
8494
  /* *
8572
8495
  *
8573
8496
  * License: www.highcharts.com/license
@@ -8614,14 +8537,6 @@
8614
8537
  _this.points = void 0;
8615
8538
  return _this;
8616
8539
  }
8617
- SlowStochasticIndicator.prototype.init = function () {
8618
- var args = arguments,
8619
- ctx = this;
8620
- RequiredIndicatorMixin.isParentLoaded(seriesTypes.stochastic, 'stochastic', ctx.type, function (indicator) {
8621
- indicator.prototype.init.apply(ctx, args);
8622
- return;
8623
- });
8624
- };
8625
8540
  SlowStochasticIndicator.prototype.getValues = function (series, params) {
8626
8541
  var periods = params.periods,
8627
8542
  fastValues = seriesTypes.stochastic.prototype.getValues.call(this,
@@ -8718,7 +8633,7 @@
8718
8633
 
8719
8634
  return SlowStochasticIndicator;
8720
8635
  });
8721
- _registerModule(_modules, 'Stock/Indicators/Supertrend/SupertrendIndicator.js', [_modules['Core/Color/Palette.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js'], _modules['Core/Chart/StockChart.js']], function (palette, SeriesRegistry, U, StockChart) {
8636
+ _registerModule(_modules, 'Stock/Indicators/Supertrend/SupertrendIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js'], _modules['Core/Chart/StockChart.js']], function (SeriesRegistry, U, StockChart) {
8722
8637
  /* *
8723
8638
  *
8724
8639
  * License: www.highcharts.com/license
@@ -9169,7 +9084,7 @@
9169
9084
  *
9170
9085
  * @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
9171
9086
  */
9172
- risingTrendColor: palette.positiveColor,
9087
+ risingTrendColor: "#06b535" /* positiveColor */,
9173
9088
  /**
9174
9089
  * Color of the Supertrend series line that is above the main series.
9175
9090
  *
@@ -9178,7 +9093,7 @@
9178
9093
  *
9179
9094
  * @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
9180
9095
  */
9181
- fallingTrendColor: palette.negativeColor,
9096
+ fallingTrendColor: "#f21313" /* negativeColor */,
9182
9097
  /**
9183
9098
  * The styles for the Supertrend line that intersect main series.
9184
9099
  *
@@ -9196,7 +9111,7 @@
9196
9111
  *
9197
9112
  * @type {Highcharts.ColorString}
9198
9113
  */
9199
- lineColor: palette.neutralColor80,
9114
+ lineColor: "#333333" /* neutralColor80 */,
9200
9115
  /**
9201
9116
  * The dash or dot style of the grid lines. For possible
9202
9117
  * values, see
@@ -9218,8 +9133,7 @@
9218
9133
  }(SMAIndicator));
9219
9134
  extend(SupertrendIndicator.prototype, {
9220
9135
  nameBase: 'Supertrend',
9221
- nameComponents: ['multiplier', 'period'],
9222
- requiredIndicators: ['atr']
9136
+ nameComponents: ['multiplier', 'period']
9223
9137
  });
9224
9138
  SeriesRegistry.registerSeriesType('supertrend', SupertrendIndicator);
9225
9139
  /* *
@@ -9334,6 +9248,7 @@
9334
9248
  arrayMax = U.arrayMax,
9335
9249
  arrayMin = U.arrayMin,
9336
9250
  correctFloat = U.correctFloat,
9251
+ defined = U.defined,
9337
9252
  error = U.error,
9338
9253
  extend = U.extend,
9339
9254
  isArray = U.isArray,
@@ -9641,7 +9556,15 @@
9641
9556
  j = 1,
9642
9557
  rangeStep,
9643
9558
  zoneStartsLength;
9644
- if (!lowRange || !highRange) {
9559
+ // If the compare mode is set on the main series, change the VBP
9560
+ // zones to fit new extremes, #16277.
9561
+ var mainSeries = indicator.linkedParent;
9562
+ if (!indicator.options.compareToMain &&
9563
+ mainSeries.dataModify) {
9564
+ lowRange = mainSeries.dataModify.modifyValue(lowRange);
9565
+ highRange = mainSeries.dataModify.modifyValue(highRange);
9566
+ }
9567
+ if (!defined(lowRange) || !defined(highRange)) {
9645
9568
  if (this.points.length) {
9646
9569
  this.setData([]);
9647
9570
  this.zoneStarts = [];
@@ -9711,6 +9634,15 @@
9711
9634
  yValues[i - 1][3] :
9712
9635
  yValues[i - 1]) :
9713
9636
  value;
9637
+ // If the compare mode is set on the main series,
9638
+ // change the VBP zones to fit new extremes, #16277.
9639
+ var mainSeries = indicator.linkedParent;
9640
+ if (!indicator.options.compareToMain &&
9641
+ mainSeries.dataModify) {
9642
+ value = mainSeries.dataModify.modifyValue(value);
9643
+ previousValue = mainSeries.dataModify
9644
+ .modifyValue(previousValue);
9645
+ }
9714
9646
  // Checks if this is the point with the
9715
9647
  // lowest close value and if so, adds it calculations
9716
9648
  if (value <= zone.start && zone.index === 0) {
@@ -9881,11 +9813,10 @@
9881
9813
  extend(VBPIndicator.prototype, {
9882
9814
  nameBase: 'Volume by Price',
9883
9815
  nameComponents: ['ranges'],
9884
- bindTo: {
9885
- series: false,
9886
- eventName: 'afterSetExtremes'
9816
+ calculateOn: {
9817
+ chart: 'render',
9818
+ xAxis: 'afterSetExtremes'
9887
9819
  },
9888
- calculateOn: 'render',
9889
9820
  pointClass: VBPPoint,
9890
9821
  markerAttribs: noop,
9891
9822
  drawGraph: noop,
@@ -9905,7 +9836,7 @@
9905
9836
  * @extends series,plotOptions.vbp
9906
9837
  * @since 6.0.0
9907
9838
  * @product highstock
9908
- * @excluding dataParser, dataURL
9839
+ * @excluding dataParser, dataURL, compare, compareBase, compareStart
9909
9840
  * @requires stock/indicators/indicators
9910
9841
  * @requires stock/indicators/volume-by-price
9911
9842
  * @apioption series.vbp
@@ -10120,7 +10051,7 @@
10120
10051
 
10121
10052
  return VWAPIndicator;
10122
10053
  });
10123
- _registerModule(_modules, 'Stock/Indicators/WilliamsR/WilliamsRIndicator.js', [_modules['Mixins/ReduceArray.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (ReduceArrayMixin, SeriesRegistry, U) {
10054
+ _registerModule(_modules, 'Stock/Indicators/WilliamsR/WilliamsRIndicator.js', [_modules['Stock/Indicators/ArrayUtilities.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (AU, SeriesRegistry, U) {
10124
10055
  /* *
10125
10056
  *
10126
10057
  * License: www.highcharts.com/license
@@ -10144,7 +10075,6 @@
10144
10075
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
10145
10076
  };
10146
10077
  })();
10147
- var getArrayExtremes = ReduceArrayMixin.getArrayExtremes;
10148
10078
  var SMAIndicator = SeriesRegistry.seriesTypes.sma;
10149
10079
  var extend = U.extend,
10150
10080
  isArray = U.isArray,
@@ -10197,7 +10127,7 @@
10197
10127
  // with (+1)
10198
10128
  for (i = period - 1; i < yValLen; i++) {
10199
10129
  slicedY = yVal.slice(i - period + 1, i + 1);
10200
- extremes = getArrayExtremes(slicedY, low, high);
10130
+ extremes = AU.getArrayExtremes(slicedY, low, high);
10201
10131
  LL = extremes[0];
10202
10132
  HH = extremes[1];
10203
10133
  CC = yVal[i][close];
@@ -10899,7 +10829,7 @@
10899
10829
  * @since 7.0.0
10900
10830
  * @product highstock
10901
10831
  * @requires stock/indicators/indicators
10902
- * @requires stock/indicators/linearregression
10832
+ * @requires stock/indicators/regressions
10903
10833
  * @optionparent plotOptions.linearregression
10904
10834
  */
10905
10835
  LinearRegressionIndicator.defaultOptions = merge(SMAIndicator.defaultOptions, {
@@ -10978,7 +10908,7 @@
10978
10908
  * @product highstock
10979
10909
  * @excluding dataParser,dataURL
10980
10910
  * @requires stock/indicators/indicators
10981
- * @requires stock/indicators/linearregression
10911
+ * @requires stock/indicators/regressions
10982
10912
  * @apioption series.linearregression
10983
10913
  */
10984
10914
  ''; // to include the above in the js output
@@ -11062,7 +10992,7 @@
11062
10992
  * @since 7.0.0
11063
10993
  * @product highstock
11064
10994
  * @requires stock/indicators/indicators
11065
- * @requires stock/indicators/linearregression
10995
+ * @requires stock/indicators/regressions
11066
10996
  * @optionparent plotOptions.linearregressionslope
11067
10997
  */
11068
10998
  LinearRegressionSlopesIndicator.defaultOptions = merge(LinearRegressionIndicator.defaultOptions);
@@ -11087,7 +11017,7 @@
11087
11017
  * @product highstock
11088
11018
  * @excluding dataParser,dataURL
11089
11019
  * @requires stock/indicators/indicators
11090
- * @requires stock/indicators/linearregressionslope
11020
+ * @requires stock/indicators/regressions
11091
11021
  * @apioption series.linearregressionslope
11092
11022
  */
11093
11023
  ''; // to include the above in the js output
@@ -11171,7 +11101,7 @@
11171
11101
  * @since 7.0.0
11172
11102
  * @product highstock
11173
11103
  * @requires stock/indicators/indicators
11174
- * @requires stock/indicators/linearregressionintercept
11104
+ * @requires stock/indicators/regressions
11175
11105
  * @optionparent plotOptions.linearregressionintercept
11176
11106
  */
11177
11107
  LinearRegressionInterceptIndicator.defaultOptions = merge(LinearRegressionIndicator.defaultOptions);
@@ -11196,7 +11126,7 @@
11196
11126
  * @product highstock
11197
11127
  * @excluding dataParser,dataURL
11198
11128
  * @requires stock/indicators/indicators
11199
- * @requires stock/indicators/linearregressionintercept
11129
+ * @requires stock/indicators/regressions
11200
11130
  * @apioption series.linearregressionintercept
11201
11131
  */
11202
11132
  ''; // to include the above in the js output
@@ -11290,7 +11220,7 @@
11290
11220
  * @since 7.0.0
11291
11221
  * @product highstock
11292
11222
  * @requires stock/indicators/indicators
11293
- * @requires stock/indicators/linearregressionangle
11223
+ * @requires stock/indicators/regressions
11294
11224
  * @optionparent plotOptions.linearregressionangle
11295
11225
  */
11296
11226
  LinearRegressionAngleIndicator.defaultOptions = merge(LinearRegressionIndicator.defaultOptions, {
@@ -11320,14 +11250,14 @@
11320
11250
  * @product highstock
11321
11251
  * @excluding dataParser,dataURL
11322
11252
  * @requires stock/indicators/indicators
11323
- * @requires stock/indicators/linearregressionangle
11253
+ * @requires stock/indicators/regressions
11324
11254
  * @apioption series.linearregressionangle
11325
11255
  */
11326
11256
  ''; // to include the above in the js output
11327
11257
 
11328
11258
  return LinearRegressionAngleIndicator;
11329
11259
  });
11330
- _registerModule(_modules, 'Stock/Indicators/ABands/ABandsIndicator.js', [_modules['Mixins/MultipleLines.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesMixin, SeriesRegistry, U) {
11260
+ _registerModule(_modules, 'Stock/Indicators/ABands/ABandsIndicator.js', [_modules['Stock/Indicators/MultipleLinesComposition.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (MultipleLinesComposition, SeriesRegistry, U) {
11331
11261
  /* *
11332
11262
  *
11333
11263
  * License: www.highcharts.com/license
@@ -11545,16 +11475,13 @@
11545
11475
  return ABandsIndicator;
11546
11476
  }(SMAIndicator));
11547
11477
  extend(ABandsIndicator.prototype, {
11548
- drawGraph: MultipleLinesMixin.drawGraph,
11549
- getTranslatedLinesNames: MultipleLinesMixin.getTranslatedLinesNames,
11550
11478
  linesApiNames: ['topLine', 'bottomLine'],
11551
11479
  nameBase: 'Acceleration Bands',
11552
11480
  nameComponents: ['period', 'factor'],
11553
11481
  pointArrayMap: ['top', 'middle', 'bottom'],
11554
- pointValKey: 'middle',
11555
- toYData: MultipleLinesMixin.toYData,
11556
- translate: MultipleLinesMixin.translate
11482
+ pointValKey: 'middle'
11557
11483
  });
11484
+ MultipleLinesComposition.compose(ABandsIndicator);
11558
11485
  SeriesRegistry.registerSeriesType('abands', ABandsIndicator);
11559
11486
  /* *
11560
11487
  *
@@ -11754,7 +11681,7 @@
11754
11681
 
11755
11682
  return TrendLineIndicator;
11756
11683
  });
11757
- _registerModule(_modules, 'Stock/Indicators/DisparityIndex/DisparityIndexIndicator.js', [_modules['Mixins/IndicatorRequired.js'], _modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (RequiredIndicatorMixin, SeriesRegistry, U) {
11684
+ _registerModule(_modules, 'Stock/Indicators/DisparityIndex/DisparityIndexIndicator.js', [_modules['Core/Series/SeriesRegistry.js'], _modules['Core/Utilities.js']], function (SeriesRegistry, U) {
11758
11685
  /* *
11759
11686
  * (c) 2010-2021 Rafal Sebestjanski
11760
11687
  *
@@ -11804,6 +11731,11 @@
11804
11731
  var DisparityIndexIndicator = /** @class */ (function (_super) {
11805
11732
  __extends(DisparityIndexIndicator, _super);
11806
11733
  function DisparityIndexIndicator() {
11734
+ /* *
11735
+ *
11736
+ * Static Properties
11737
+ *
11738
+ * */
11807
11739
  var _this = _super !== null && _super.apply(this,
11808
11740
  arguments) || this;
11809
11741
  /* *
@@ -11827,13 +11759,8 @@
11827
11759
  ctx = this, // Disparity Index indicator
11828
11760
  params = args[1].params, // options.params
11829
11761
  averageType = params && params.average ? params.average : void 0;
11830
- ctx.averageIndicator =
11831
- SeriesRegistry.seriesTypes[averageType] || SMAIndicator;
11832
- // Check if the required average indicator modules is loaded
11833
- RequiredIndicatorMixin.isParentLoaded(ctx.averageIndicator, averageType, ctx.type, function (indicator) {
11834
- indicator.prototype.init.apply(ctx, args);
11835
- return;
11836
- });
11762
+ ctx.averageIndicator = SeriesRegistry.seriesTypes[averageType] || SMAIndicator;
11763
+ ctx.averageIndicator.prototype.init.apply(ctx, args);
11837
11764
  };
11838
11765
  DisparityIndexIndicator.prototype.calculateDisparityIndex = function (curPrice, periodAverage) {
11839
11766
  return correctFloat(curPrice - periodAverage) / periodAverage * 100;
@@ -11899,10 +11826,12 @@
11899
11826
  params: {
11900
11827
  /**
11901
11828
  * The average used to calculate the Disparity Index indicator.
11902
- * By default it uses SMA. To use other averages, e.g. EMA,
11903
- * the `stock/indicators/ema.js` file needs to be loaded.
11829
+ * By default it uses SMA, with EMA as an option. To use other
11830
+ * averages, e.g. TEMA, the `stock/indicators/tema.js` file needs to
11831
+ * be loaded.
11904
11832
  *
11905
- * If value is different than ema|dema|tema|wma, then sma is used.
11833
+ * If value is different than `ema`, `dema`, `tema` or `wma`,
11834
+ * then sma is used.
11906
11835
  */
11907
11836
  average: 'sma',
11908
11837
  index: 3
@@ -11926,6 +11855,11 @@
11926
11855
  * Default Export
11927
11856
  *
11928
11857
  * */
11858
+ /* *
11859
+ *
11860
+ * API Options
11861
+ *
11862
+ * */
11929
11863
  /**
11930
11864
  * The Disparity Index indicator series.
11931
11865
  * If the [type](#series.disparityindex.type) option is not