aw-highstock_rails 7.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (697) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +9 -0
  3. data/.travis.yml +7 -0
  4. data/CODE_OF_CONDUCT.md +74 -0
  5. data/Gemfile +6 -0
  6. data/Gemfile.lock +22 -0
  7. data/LICENSE.txt +21 -0
  8. data/README.md +53 -0
  9. data/Rakefile +10 -0
  10. data/aw-highstock_rails.gemspec +28 -0
  11. data/bin/console +14 -0
  12. data/bin/setup +8 -0
  13. data/lib/aw/highstock_rails.rb +9 -0
  14. data/lib/aw/highstock_rails/version.rb +5 -0
  15. data/vendor/assets/javascripts/highstock/css/annotations/popup.css +229 -0
  16. data/vendor/assets/javascripts/highstock/css/annotations/popup.scss +235 -0
  17. data/vendor/assets/javascripts/highstock/css/highcharts.css +890 -0
  18. data/vendor/assets/javascripts/highstock/css/highcharts.scss +788 -0
  19. data/vendor/assets/javascripts/highstock/css/stocktools/gui.css +268 -0
  20. data/vendor/assets/javascripts/highstock/css/stocktools/gui.scss +270 -0
  21. data/vendor/assets/javascripts/highstock/css/themes/dark-unica.css +951 -0
  22. data/vendor/assets/javascripts/highstock/css/themes/dark-unica.scss +122 -0
  23. data/vendor/assets/javascripts/highstock/css/themes/grid-light.css +904 -0
  24. data/vendor/assets/javascripts/highstock/css/themes/grid-light.scss +33 -0
  25. data/vendor/assets/javascripts/highstock/css/themes/sand-signika.css +920 -0
  26. data/vendor/assets/javascripts/highstock/css/themes/sand-signika.scss +74 -0
  27. data/vendor/assets/javascripts/highstock/es-modules/annotations/ControlPoint.js +130 -0
  28. data/vendor/assets/javascripts/highstock/es-modules/annotations/MockPoint.js +415 -0
  29. data/vendor/assets/javascripts/highstock/es-modules/annotations/annotations.src.js +1231 -0
  30. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/ControllableCircle.js +92 -0
  31. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/ControllableImage.js +101 -0
  32. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/ControllableLabel.js +452 -0
  33. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/ControllablePath.js +175 -0
  34. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/ControllableRect.js +93 -0
  35. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/controllableMixin.js +411 -0
  36. data/vendor/assets/javascripts/highstock/es-modules/annotations/controllable/markerMixin.js +214 -0
  37. data/vendor/assets/javascripts/highstock/es-modules/annotations/eventEmitterMixin.js +271 -0
  38. data/vendor/assets/javascripts/highstock/es-modules/annotations/navigationBindings.js +1283 -0
  39. data/vendor/assets/javascripts/highstock/es-modules/annotations/popup.js +1069 -0
  40. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/CrookedLine.js +191 -0
  41. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/ElliottWave.js +76 -0
  42. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/Fibonacci.js +247 -0
  43. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/InfinityLine.js +185 -0
  44. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/Measure.js +928 -0
  45. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/Pitchfork.js +203 -0
  46. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/Tunnel.js +242 -0
  47. data/vendor/assets/javascripts/highstock/es-modules/annotations/types/VerticalLine.js +157 -0
  48. data/vendor/assets/javascripts/highstock/es-modules/error-messages.js +128 -0
  49. data/vendor/assets/javascripts/highstock/es-modules/error.js +1 -0
  50. data/vendor/assets/javascripts/highstock/es-modules/indicators/acceleration-bands.src.js +199 -0
  51. data/vendor/assets/javascripts/highstock/es-modules/indicators/accumulation-distribution.src.js +129 -0
  52. data/vendor/assets/javascripts/highstock/es-modules/indicators/ao.src.js +206 -0
  53. data/vendor/assets/javascripts/highstock/es-modules/indicators/apo.src.js +148 -0
  54. data/vendor/assets/javascripts/highstock/es-modules/indicators/aroon-oscillator.src.js +128 -0
  55. data/vendor/assets/javascripts/highstock/es-modules/indicators/aroon.src.js +173 -0
  56. data/vendor/assets/javascripts/highstock/es-modules/indicators/atr.src.js +151 -0
  57. data/vendor/assets/javascripts/highstock/es-modules/indicators/bollinger-bands.src.js +209 -0
  58. data/vendor/assets/javascripts/highstock/es-modules/indicators/cci.src.js +131 -0
  59. data/vendor/assets/javascripts/highstock/es-modules/indicators/chaikin.src.js +167 -0
  60. data/vendor/assets/javascripts/highstock/es-modules/indicators/cmf.src.js +246 -0
  61. data/vendor/assets/javascripts/highstock/es-modules/indicators/dema.src.js +191 -0
  62. data/vendor/assets/javascripts/highstock/es-modules/indicators/dpo.src.js +138 -0
  63. data/vendor/assets/javascripts/highstock/es-modules/indicators/ema.src.js +166 -0
  64. data/vendor/assets/javascripts/highstock/es-modules/indicators/ichimoku-kinko-hyo.src.js +850 -0
  65. data/vendor/assets/javascripts/highstock/es-modules/indicators/indicators.src.js +425 -0
  66. data/vendor/assets/javascripts/highstock/es-modules/indicators/keltner-channels.src.js +193 -0
  67. data/vendor/assets/javascripts/highstock/es-modules/indicators/macd.src.js +417 -0
  68. data/vendor/assets/javascripts/highstock/es-modules/indicators/mfi.src.js +198 -0
  69. data/vendor/assets/javascripts/highstock/es-modules/indicators/momentum.src.js +119 -0
  70. data/vendor/assets/javascripts/highstock/es-modules/indicators/natr.src.js +74 -0
  71. data/vendor/assets/javascripts/highstock/es-modules/indicators/pivot-points.src.js +360 -0
  72. data/vendor/assets/javascripts/highstock/es-modules/indicators/ppo.src.js +152 -0
  73. data/vendor/assets/javascripts/highstock/es-modules/indicators/price-channel.src.js +149 -0
  74. data/vendor/assets/javascripts/highstock/es-modules/indicators/price-envelopes.src.js +251 -0
  75. data/vendor/assets/javascripts/highstock/es-modules/indicators/psar.src.js +307 -0
  76. data/vendor/assets/javascripts/highstock/es-modules/indicators/regressions.src.js +427 -0
  77. data/vendor/assets/javascripts/highstock/es-modules/indicators/roc.src.js +149 -0
  78. data/vendor/assets/javascripts/highstock/es-modules/indicators/rsi.src.js +163 -0
  79. data/vendor/assets/javascripts/highstock/es-modules/indicators/stochastic.src.js +193 -0
  80. data/vendor/assets/javascripts/highstock/es-modules/indicators/supertrend.src.js +544 -0
  81. data/vendor/assets/javascripts/highstock/es-modules/indicators/tema.src.js +247 -0
  82. data/vendor/assets/javascripts/highstock/es-modules/indicators/trix.src.js +96 -0
  83. data/vendor/assets/javascripts/highstock/es-modules/indicators/volume-by-price.src.js +671 -0
  84. data/vendor/assets/javascripts/highstock/es-modules/indicators/vwap.src.js +189 -0
  85. data/vendor/assets/javascripts/highstock/es-modules/indicators/williams-r.src.js +128 -0
  86. data/vendor/assets/javascripts/highstock/es-modules/indicators/wma.src.js +146 -0
  87. data/vendor/assets/javascripts/highstock/es-modules/indicators/zigzag.src.js +221 -0
  88. data/vendor/assets/javascripts/highstock/es-modules/masters/highcharts-3d.src.js +17 -0
  89. data/vendor/assets/javascripts/highstock/es-modules/masters/highcharts-more.src.js +22 -0
  90. data/vendor/assets/javascripts/highstock/es-modules/masters/highstock.src.js +11 -0
  91. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/acceleration-bands.src.js +11 -0
  92. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/accumulation-distribution.src.js +11 -0
  93. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/ao.src.js +11 -0
  94. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/apo.src.js +11 -0
  95. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/aroon-oscillator.src.js +11 -0
  96. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/aroon.src.js +11 -0
  97. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/atr.src.js +11 -0
  98. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/bollinger-bands.src.js +11 -0
  99. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/cci.src.js +11 -0
  100. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/chaikin.src.js +11 -0
  101. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/cmf.src.js +10 -0
  102. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/dema.src.js +11 -0
  103. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/dpo.src.js +11 -0
  104. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/ema.src.js +11 -0
  105. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/ichimoku-kinko-hyo.src.js +11 -0
  106. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/indicators-all.src.js +49 -0
  107. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/indicators.src.js +11 -0
  108. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/keltner-channels.src.js +11 -0
  109. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/macd.src.js +11 -0
  110. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/mfi.src.js +11 -0
  111. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/momentum.src.js +11 -0
  112. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/natr.src.js +11 -0
  113. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/pivot-points.src.js +11 -0
  114. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/ppo.src.js +11 -0
  115. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/price-channel.src.js +11 -0
  116. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/price-envelopes.src.js +11 -0
  117. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/psar.src.js +11 -0
  118. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/regressions.src.js +11 -0
  119. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/roc.src.js +11 -0
  120. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/rsi.src.js +11 -0
  121. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/stochastic.src.js +11 -0
  122. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/supertrend.src.js +11 -0
  123. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/tema.src.js +11 -0
  124. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/trix.src.js +11 -0
  125. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/volume-by-price.src.js +11 -0
  126. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/vwap.src.js +11 -0
  127. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/williams-r.src.js +11 -0
  128. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/wma.src.js +11 -0
  129. data/vendor/assets/javascripts/highstock/es-modules/masters/indicators/zigzag.src.js +11 -0
  130. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/accessibility.src.js +13 -0
  131. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/annotations-advanced.src.js +20 -0
  132. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/annotations.src.js +12 -0
  133. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/arrow-symbols.src.js +10 -0
  134. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/boost-canvas.src.js +11 -0
  135. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/boost.src.js +11 -0
  136. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/bullet.src.js +11 -0
  137. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/current-date-indicator.src.js +10 -0
  138. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/cylinder.src.js +10 -0
  139. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/data.src.js +10 -0
  140. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/datagrouping.src.js +12 -0
  141. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/debugger.src.js +13 -0
  142. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/dependency-wheel.src.js +10 -0
  143. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/drag-panes.src.js +11 -0
  144. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/draggable-points.src.js +9 -0
  145. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/drilldown.src.js +10 -0
  146. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/export-data.src.js +10 -0
  147. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/exporting.src.js +10 -0
  148. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/full-screen.src.js +11 -0
  149. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/funnel.src.js +10 -0
  150. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/grid-axis.src.js +10 -0
  151. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/heatmap.src.js +11 -0
  152. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/histogram-bellcurve.src.js +11 -0
  153. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/item-series.src.js +11 -0
  154. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/networkgraph.src.js +10 -0
  155. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/no-data-to-display.src.js +11 -0
  156. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/offline-exporting.src.js +10 -0
  157. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/oldie-polyfills.src.js +11 -0
  158. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/oldie.src.js +11 -0
  159. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/overlapping-datalabels.src.js +9 -0
  160. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/parallel-coordinates.src.js +11 -0
  161. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/pareto.src.js +11 -0
  162. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/pathfinder.src.js +10 -0
  163. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/pattern-fill.src.js +11 -0
  164. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/price-indicator.src.js +11 -0
  165. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/sankey.src.js +10 -0
  166. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/series-label.src.js +9 -0
  167. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/solid-gauge.src.js +10 -0
  168. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/sonification.src.js +12 -0
  169. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/static-scale.src.js +10 -0
  170. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/stock-tools.src.js +12 -0
  171. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/stock.src.js +19 -0
  172. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/streamgraph.src.js +10 -0
  173. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/sunburst.src.js +10 -0
  174. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/tilemap.src.js +10 -0
  175. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/timeline.src.js +11 -0
  176. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/treegrid.src.js +10 -0
  177. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/treemap.src.js +10 -0
  178. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/variable-pie.src.js +11 -0
  179. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/variwide.src.js +10 -0
  180. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/vector.src.js +10 -0
  181. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/venn.src.js +10 -0
  182. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/windbarb.src.js +10 -0
  183. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/wordcloud.src.js +10 -0
  184. data/vendor/assets/javascripts/highstock/es-modules/masters/modules/xrange.src.js +10 -0
  185. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/avocado.js +9 -0
  186. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/avocado.src.js +9 -0
  187. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/dark-blue.src.js +9 -0
  188. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/dark-green.src.js +9 -0
  189. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/dark-unica.src.js +9 -0
  190. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/gray.src.js +9 -0
  191. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/grid-light.src.js +9 -0
  192. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/grid.src.js +9 -0
  193. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/sand-signika.src.js +9 -0
  194. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/skies.src.js +9 -0
  195. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/sunset.js +9 -0
  196. data/vendor/assets/javascripts/highstock/es-modules/masters/themes/sunset.src.js +9 -0
  197. data/vendor/assets/javascripts/highstock/es-modules/mixins/ajax.js +123 -0
  198. data/vendor/assets/javascripts/highstock/es-modules/mixins/centered-series.js +116 -0
  199. data/vendor/assets/javascripts/highstock/es-modules/mixins/derived-series.js +150 -0
  200. data/vendor/assets/javascripts/highstock/es-modules/mixins/download-url.js +103 -0
  201. data/vendor/assets/javascripts/highstock/es-modules/mixins/draw-point.js +51 -0
  202. data/vendor/assets/javascripts/highstock/es-modules/mixins/geometry-circles.js +300 -0
  203. data/vendor/assets/javascripts/highstock/es-modules/mixins/geometry.js +50 -0
  204. data/vendor/assets/javascripts/highstock/es-modules/mixins/indicator-required.js +49 -0
  205. data/vendor/assets/javascripts/highstock/es-modules/mixins/multipe-lines.js +223 -0
  206. data/vendor/assets/javascripts/highstock/es-modules/mixins/navigation.js +59 -0
  207. data/vendor/assets/javascripts/highstock/es-modules/mixins/nodes.js +76 -0
  208. data/vendor/assets/javascripts/highstock/es-modules/mixins/on-series.js +167 -0
  209. data/vendor/assets/javascripts/highstock/es-modules/mixins/polygon.js +293 -0
  210. data/vendor/assets/javascripts/highstock/es-modules/mixins/reduce-array.js +53 -0
  211. data/vendor/assets/javascripts/highstock/es-modules/mixins/tree-series.js +256 -0
  212. data/vendor/assets/javascripts/highstock/es-modules/modules/a11y-i18n.src.js +524 -0
  213. data/vendor/assets/javascripts/highstock/es-modules/modules/annotations-legacy.src.js +1951 -0
  214. data/vendor/assets/javascripts/highstock/es-modules/modules/bellcurve.src.js +173 -0
  215. data/vendor/assets/javascripts/highstock/es-modules/modules/boost-canvas.src.js +732 -0
  216. data/vendor/assets/javascripts/highstock/es-modules/modules/boost.src.js +3730 -0
  217. data/vendor/assets/javascripts/highstock/es-modules/modules/bullet.src.js +361 -0
  218. data/vendor/assets/javascripts/highstock/es-modules/modules/cylinder.src.js +389 -0
  219. data/vendor/assets/javascripts/highstock/es-modules/modules/data.src.js +2417 -0
  220. data/vendor/assets/javascripts/highstock/es-modules/modules/debugger.src.js +109 -0
  221. data/vendor/assets/javascripts/highstock/es-modules/modules/dependency-wheel.src.js +199 -0
  222. data/vendor/assets/javascripts/highstock/es-modules/modules/drag-panes.src.js +624 -0
  223. data/vendor/assets/javascripts/highstock/es-modules/modules/draggable-points.src.js +2625 -0
  224. data/vendor/assets/javascripts/highstock/es-modules/modules/drilldown.src.js +1300 -0
  225. data/vendor/assets/javascripts/highstock/es-modules/modules/export-data.src.js +983 -0
  226. data/vendor/assets/javascripts/highstock/es-modules/modules/exporting.src.js +2149 -0
  227. data/vendor/assets/javascripts/highstock/es-modules/modules/full-screen.src.js +40 -0
  228. data/vendor/assets/javascripts/highstock/es-modules/modules/funnel.src.js +552 -0
  229. data/vendor/assets/javascripts/highstock/es-modules/modules/histogram.src.js +229 -0
  230. data/vendor/assets/javascripts/highstock/es-modules/modules/item-series.src.js +150 -0
  231. data/vendor/assets/javascripts/highstock/es-modules/modules/keyboard-navigation.src.js +1606 -0
  232. data/vendor/assets/javascripts/highstock/es-modules/modules/networkgraph/QuadTree.js +175 -0
  233. data/vendor/assets/javascripts/highstock/es-modules/modules/networkgraph/layouts.js +506 -0
  234. data/vendor/assets/javascripts/highstock/es-modules/modules/networkgraph/networkgraph.src.js +740 -0
  235. data/vendor/assets/javascripts/highstock/es-modules/modules/no-data-to-display.src.js +260 -0
  236. data/vendor/assets/javascripts/highstock/es-modules/modules/offline-exporting.src.js +710 -0
  237. data/vendor/assets/javascripts/highstock/es-modules/modules/oldie-polyfills.src.js +121 -0
  238. data/vendor/assets/javascripts/highstock/es-modules/modules/oldie.src.js +1556 -0
  239. data/vendor/assets/javascripts/highstock/es-modules/modules/overlapping-datalabels.src.js +250 -0
  240. data/vendor/assets/javascripts/highstock/es-modules/modules/parallel-coordinates.src.js +492 -0
  241. data/vendor/assets/javascripts/highstock/es-modules/modules/pareto.src.js +152 -0
  242. data/vendor/assets/javascripts/highstock/es-modules/modules/pattern-fill.src.js +607 -0
  243. data/vendor/assets/javascripts/highstock/es-modules/modules/price-indicator.src.js +149 -0
  244. data/vendor/assets/javascripts/highstock/es-modules/modules/sankey.src.js +809 -0
  245. data/vendor/assets/javascripts/highstock/es-modules/modules/screen-reader.src.js +954 -0
  246. data/vendor/assets/javascripts/highstock/es-modules/modules/series-label.src.js +1042 -0
  247. data/vendor/assets/javascripts/highstock/es-modules/modules/solid-gauge.src.js +486 -0
  248. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/Earcon.js +184 -0
  249. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/Instrument.js +582 -0
  250. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/Timeline.js +702 -0
  251. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/chartSonify.js +1026 -0
  252. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/instrumentDefinitions.js +37 -0
  253. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/musicalFrequencies.js +113 -0
  254. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/pointSonify.js +385 -0
  255. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/sonification.js +107 -0
  256. data/vendor/assets/javascripts/highstock/es-modules/modules/sonification/utilities.js +178 -0
  257. data/vendor/assets/javascripts/highstock/es-modules/modules/static-scale.src.js +88 -0
  258. data/vendor/assets/javascripts/highstock/es-modules/modules/stock-tools-bindings.js +1950 -0
  259. data/vendor/assets/javascripts/highstock/es-modules/modules/stock-tools-gui.js +1458 -0
  260. data/vendor/assets/javascripts/highstock/es-modules/modules/streamgraph.src.js +132 -0
  261. data/vendor/assets/javascripts/highstock/es-modules/modules/sunburst.src.js +1041 -0
  262. data/vendor/assets/javascripts/highstock/es-modules/modules/tilemap.src.js +769 -0
  263. data/vendor/assets/javascripts/highstock/es-modules/modules/timeline.src.js +750 -0
  264. data/vendor/assets/javascripts/highstock/es-modules/modules/treemap.src.js +1803 -0
  265. data/vendor/assets/javascripts/highstock/es-modules/modules/variable-pie.src.js +459 -0
  266. data/vendor/assets/javascripts/highstock/es-modules/modules/variwide.src.js +350 -0
  267. data/vendor/assets/javascripts/highstock/es-modules/modules/vector.src.js +354 -0
  268. data/vendor/assets/javascripts/highstock/es-modules/modules/venn.src.js +1192 -0
  269. data/vendor/assets/javascripts/highstock/es-modules/modules/windbarb.src.js +380 -0
  270. data/vendor/assets/javascripts/highstock/es-modules/modules/wordcloud.src.js +1103 -0
  271. data/vendor/assets/javascripts/highstock/es-modules/modules/xrange.src.js +761 -0
  272. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Axis.js +669 -0
  273. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Chart.js +1753 -0
  274. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Column.js +437 -0
  275. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Math.js +206 -0
  276. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Pie.js +207 -0
  277. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/SVGRenderer.js +1002 -0
  278. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Scatter.js +154 -0
  279. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/Series.js +73 -0
  280. data/vendor/assets/javascripts/highstock/es-modules/parts-3d/VMLRenderer.js +62 -0
  281. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/ArrowSymbols.js +198 -0
  282. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/CurrentDateIndicator.js +100 -0
  283. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/GanttChart.js +140 -0
  284. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/GanttSeries.js +415 -0
  285. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/GridAxis.js +961 -0
  286. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/Pathfinder.js +1298 -0
  287. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/PathfinderAlgorithms.js +816 -0
  288. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/Tree.js +158 -0
  289. data/vendor/assets/javascripts/highstock/es-modules/parts-gantt/TreeGrid.js +1003 -0
  290. data/vendor/assets/javascripts/highstock/es-modules/parts-map/ColorAxis.js +1103 -0
  291. data/vendor/assets/javascripts/highstock/es-modules/parts-map/ColorSeriesMixin.js +138 -0
  292. data/vendor/assets/javascripts/highstock/es-modules/parts-map/GeoJSON.js +435 -0
  293. data/vendor/assets/javascripts/highstock/es-modules/parts-map/HeatmapSeries.js +474 -0
  294. data/vendor/assets/javascripts/highstock/es-modules/parts-map/Map.js +477 -0
  295. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapAxis.js +124 -0
  296. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapBubbleSeries.js +274 -0
  297. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapLineSeries.js +143 -0
  298. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapNavigation.js +357 -0
  299. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapPointSeries.js +187 -0
  300. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapPointer.js +132 -0
  301. data/vendor/assets/javascripts/highstock/es-modules/parts-map/MapSeries.js +1294 -0
  302. data/vendor/assets/javascripts/highstock/es-modules/parts-more/AreaRangeSeries.js +725 -0
  303. data/vendor/assets/javascripts/highstock/es-modules/parts-more/AreaSplineRangeSeries.js +98 -0
  304. data/vendor/assets/javascripts/highstock/es-modules/parts-more/BoxPlotSeries.js +617 -0
  305. data/vendor/assets/javascripts/highstock/es-modules/parts-more/BubbleLegend.js +1167 -0
  306. data/vendor/assets/javascripts/highstock/es-modules/parts-more/BubbleSeries.js +661 -0
  307. data/vendor/assets/javascripts/highstock/es-modules/parts-more/ColumnPyramidSeries.js +288 -0
  308. data/vendor/assets/javascripts/highstock/es-modules/parts-more/ColumnRangeSeries.js +278 -0
  309. data/vendor/assets/javascripts/highstock/es-modules/parts-more/ErrorBarSeries.js +172 -0
  310. data/vendor/assets/javascripts/highstock/es-modules/parts-more/GaugeSeries.js +618 -0
  311. data/vendor/assets/javascripts/highstock/es-modules/parts-more/PackedBubbleSeries.js +567 -0
  312. data/vendor/assets/javascripts/highstock/es-modules/parts-more/Pane.js +399 -0
  313. data/vendor/assets/javascripts/highstock/es-modules/parts-more/Polar.js +634 -0
  314. data/vendor/assets/javascripts/highstock/es-modules/parts-more/PolygonSeries.js +151 -0
  315. data/vendor/assets/javascripts/highstock/es-modules/parts-more/RadialAxis.js +685 -0
  316. data/vendor/assets/javascripts/highstock/es-modules/parts-more/WaterfallSeries.js +765 -0
  317. data/vendor/assets/javascripts/highstock/es-modules/parts.js +684 -0
  318. data/vendor/assets/javascripts/highstock/es-modules/parts/AreaSeries.js +578 -0
  319. data/vendor/assets/javascripts/highstock/es-modules/parts/AreaSplineSeries.js +122 -0
  320. data/vendor/assets/javascripts/highstock/es-modules/parts/Axis.js +6453 -0
  321. data/vendor/assets/javascripts/highstock/es-modules/parts/BarSeries.js +153 -0
  322. data/vendor/assets/javascripts/highstock/es-modules/parts/CandlestickSeries.js +358 -0
  323. data/vendor/assets/javascripts/highstock/es-modules/parts/Chart.js +2307 -0
  324. data/vendor/assets/javascripts/highstock/es-modules/parts/Color.js +301 -0
  325. data/vendor/assets/javascripts/highstock/es-modules/parts/ColumnSeries.js +1125 -0
  326. data/vendor/assets/javascripts/highstock/es-modules/parts/DataGrouping.js +1115 -0
  327. data/vendor/assets/javascripts/highstock/es-modules/parts/DataLabels.js +1431 -0
  328. data/vendor/assets/javascripts/highstock/es-modules/parts/DateTimeAxis.js +134 -0
  329. data/vendor/assets/javascripts/highstock/es-modules/parts/Dynamics.js +1301 -0
  330. data/vendor/assets/javascripts/highstock/es-modules/parts/FlagsSeries.js +739 -0
  331. data/vendor/assets/javascripts/highstock/es-modules/parts/Globals.js +75 -0
  332. data/vendor/assets/javascripts/highstock/es-modules/parts/Html.js +539 -0
  333. data/vendor/assets/javascripts/highstock/es-modules/parts/Interaction.js +1299 -0
  334. data/vendor/assets/javascripts/highstock/es-modules/parts/Legend.js +1411 -0
  335. data/vendor/assets/javascripts/highstock/es-modules/parts/LogarithmicAxis.js +168 -0
  336. data/vendor/assets/javascripts/highstock/es-modules/parts/MSPointer.js +176 -0
  337. data/vendor/assets/javascripts/highstock/es-modules/parts/Navigator.js +2486 -0
  338. data/vendor/assets/javascripts/highstock/es-modules/parts/OHLCSeries.js +412 -0
  339. data/vendor/assets/javascripts/highstock/es-modules/parts/Options.js +3732 -0
  340. data/vendor/assets/javascripts/highstock/es-modules/parts/OrdinalAxis.js +962 -0
  341. data/vendor/assets/javascripts/highstock/es-modules/parts/PieSeries.js +1328 -0
  342. data/vendor/assets/javascripts/highstock/es-modules/parts/PlotBandSeries.experimental.js +74 -0
  343. data/vendor/assets/javascripts/highstock/es-modules/parts/PlotLineOrBand.js +1061 -0
  344. data/vendor/assets/javascripts/highstock/es-modules/parts/Point.js +681 -0
  345. data/vendor/assets/javascripts/highstock/es-modules/parts/Pointer.js +1332 -0
  346. data/vendor/assets/javascripts/highstock/es-modules/parts/RangeSelector.js +2063 -0
  347. data/vendor/assets/javascripts/highstock/es-modules/parts/Responsive.js +295 -0
  348. data/vendor/assets/javascripts/highstock/es-modules/parts/ScatterSeries.js +278 -0
  349. data/vendor/assets/javascripts/highstock/es-modules/parts/ScrollablePlotArea.js +266 -0
  350. data/vendor/assets/javascripts/highstock/es-modules/parts/Scrollbar.js +1134 -0
  351. data/vendor/assets/javascripts/highstock/es-modules/parts/Series.js +5864 -0
  352. data/vendor/assets/javascripts/highstock/es-modules/parts/SplineSeries.js +267 -0
  353. data/vendor/assets/javascripts/highstock/es-modules/parts/Stacking.js +604 -0
  354. data/vendor/assets/javascripts/highstock/es-modules/parts/StockChart.js +951 -0
  355. data/vendor/assets/javascripts/highstock/es-modules/parts/SvgRenderer.js +5109 -0
  356. data/vendor/assets/javascripts/highstock/es-modules/parts/Tick.js +746 -0
  357. data/vendor/assets/javascripts/highstock/es-modules/parts/Time.js +881 -0
  358. data/vendor/assets/javascripts/highstock/es-modules/parts/Tooltip.js +1318 -0
  359. data/vendor/assets/javascripts/highstock/es-modules/parts/TouchPointer.js +404 -0
  360. data/vendor/assets/javascripts/highstock/es-modules/parts/Utilities.js +2751 -0
  361. data/vendor/assets/javascripts/highstock/es-modules/themes/avocado.js +37 -0
  362. data/vendor/assets/javascripts/highstock/es-modules/themes/dark-blue.js +259 -0
  363. data/vendor/assets/javascripts/highstock/es-modules/themes/dark-green.js +261 -0
  364. data/vendor/assets/javascripts/highstock/es-modules/themes/dark-unica.js +220 -0
  365. data/vendor/assets/javascripts/highstock/es-modules/themes/gray.js +267 -0
  366. data/vendor/assets/javascripts/highstock/es-modules/themes/grid-light.js +81 -0
  367. data/vendor/assets/javascripts/highstock/es-modules/themes/grid.js +110 -0
  368. data/vendor/assets/javascripts/highstock/es-modules/themes/sand-signika.js +111 -0
  369. data/vendor/assets/javascripts/highstock/es-modules/themes/skies.js +100 -0
  370. data/vendor/assets/javascripts/highstock/es-modules/themes/sunset.js +36 -0
  371. data/vendor/assets/javascripts/highstock/highcharts-3d.js +85 -0
  372. data/vendor/assets/javascripts/highstock/highcharts-3d.js.map +1 -0
  373. data/vendor/assets/javascripts/highstock/highcharts-more.js +101 -0
  374. data/vendor/assets/javascripts/highstock/highcharts-more.js.map +1 -0
  375. data/vendor/assets/javascripts/highstock/highstock.js +583 -0
  376. data/vendor/assets/javascripts/highstock/highstock.js.map +1 -0
  377. data/vendor/assets/javascripts/highstock/indicators/acceleration-bands.js +16 -0
  378. data/vendor/assets/javascripts/highstock/indicators/acceleration-bands.js.map +1 -0
  379. data/vendor/assets/javascripts/highstock/indicators/acceleration-bands.src.js +448 -0
  380. data/vendor/assets/javascripts/highstock/indicators/accumulation-distribution.js +12 -0
  381. data/vendor/assets/javascripts/highstock/indicators/accumulation-distribution.js.map +1 -0
  382. data/vendor/assets/javascripts/highstock/indicators/accumulation-distribution.src.js +156 -0
  383. data/vendor/assets/javascripts/highstock/indicators/ao.js +13 -0
  384. data/vendor/assets/javascripts/highstock/indicators/ao.js.map +1 -0
  385. data/vendor/assets/javascripts/highstock/indicators/ao.src.js +233 -0
  386. data/vendor/assets/javascripts/highstock/indicators/apo.js +13 -0
  387. data/vendor/assets/javascripts/highstock/indicators/apo.js.map +1 -0
  388. data/vendor/assets/javascripts/highstock/indicators/apo.src.js +223 -0
  389. data/vendor/assets/javascripts/highstock/indicators/aroon-oscillator.js +15 -0
  390. data/vendor/assets/javascripts/highstock/indicators/aroon-oscillator.js.map +1 -0
  391. data/vendor/assets/javascripts/highstock/indicators/aroon-oscillator.src.js +426 -0
  392. data/vendor/assets/javascripts/highstock/indicators/aroon.js +16 -0
  393. data/vendor/assets/javascripts/highstock/indicators/aroon.js.map +1 -0
  394. data/vendor/assets/javascripts/highstock/indicators/aroon.src.js +423 -0
  395. data/vendor/assets/javascripts/highstock/indicators/atr.js +12 -0
  396. data/vendor/assets/javascripts/highstock/indicators/atr.js.map +1 -0
  397. data/vendor/assets/javascripts/highstock/indicators/atr.src.js +178 -0
  398. data/vendor/assets/javascripts/highstock/indicators/bollinger-bands.js +16 -0
  399. data/vendor/assets/javascripts/highstock/indicators/bollinger-bands.js.map +1 -0
  400. data/vendor/assets/javascripts/highstock/indicators/bollinger-bands.src.js +458 -0
  401. data/vendor/assets/javascripts/highstock/indicators/cci.js +12 -0
  402. data/vendor/assets/javascripts/highstock/indicators/cci.js.map +1 -0
  403. data/vendor/assets/javascripts/highstock/indicators/cci.src.js +158 -0
  404. data/vendor/assets/javascripts/highstock/indicators/chaikin.js +15 -0
  405. data/vendor/assets/javascripts/highstock/indicators/chaikin.js.map +1 -0
  406. data/vendor/assets/javascripts/highstock/indicators/chaikin.src.js +370 -0
  407. data/vendor/assets/javascripts/highstock/indicators/cmf.js +12 -0
  408. data/vendor/assets/javascripts/highstock/indicators/cmf.js.map +1 -0
  409. data/vendor/assets/javascripts/highstock/indicators/cmf.src.js +273 -0
  410. data/vendor/assets/javascripts/highstock/indicators/dema.js +13 -0
  411. data/vendor/assets/javascripts/highstock/indicators/dema.js.map +1 -0
  412. data/vendor/assets/javascripts/highstock/indicators/dema.src.js +266 -0
  413. data/vendor/assets/javascripts/highstock/indicators/dpo.js +12 -0
  414. data/vendor/assets/javascripts/highstock/indicators/dpo.js.map +1 -0
  415. data/vendor/assets/javascripts/highstock/indicators/dpo.src.js +166 -0
  416. data/vendor/assets/javascripts/highstock/indicators/ema.js +12 -0
  417. data/vendor/assets/javascripts/highstock/indicators/ema.js.map +1 -0
  418. data/vendor/assets/javascripts/highstock/indicators/ema.src.js +193 -0
  419. data/vendor/assets/javascripts/highstock/indicators/ichimoku-kinko-hyo.js +22 -0
  420. data/vendor/assets/javascripts/highstock/indicators/ichimoku-kinko-hyo.js.map +1 -0
  421. data/vendor/assets/javascripts/highstock/indicators/ichimoku-kinko-hyo.src.js +877 -0
  422. data/vendor/assets/javascripts/highstock/indicators/indicators-all.js +117 -0
  423. data/vendor/assets/javascripts/highstock/indicators/indicators-all.js.map +1 -0
  424. data/vendor/assets/javascripts/highstock/indicators/indicators-all.src.js +9389 -0
  425. data/vendor/assets/javascripts/highstock/indicators/indicators.js +17 -0
  426. data/vendor/assets/javascripts/highstock/indicators/indicators.js.map +1 -0
  427. data/vendor/assets/javascripts/highstock/indicators/indicators.src.js +500 -0
  428. data/vendor/assets/javascripts/highstock/indicators/keltner-channels.js +16 -0
  429. data/vendor/assets/javascripts/highstock/indicators/keltner-channels.js.map +1 -0
  430. data/vendor/assets/javascripts/highstock/indicators/keltner-channels.src.js +442 -0
  431. data/vendor/assets/javascripts/highstock/indicators/macd.js +18 -0
  432. data/vendor/assets/javascripts/highstock/indicators/macd.js.map +1 -0
  433. data/vendor/assets/javascripts/highstock/indicators/macd.src.js +444 -0
  434. data/vendor/assets/javascripts/highstock/indicators/mfi.js +13 -0
  435. data/vendor/assets/javascripts/highstock/indicators/mfi.js.map +1 -0
  436. data/vendor/assets/javascripts/highstock/indicators/mfi.src.js +225 -0
  437. data/vendor/assets/javascripts/highstock/indicators/momentum.js +12 -0
  438. data/vendor/assets/javascripts/highstock/indicators/momentum.js.map +1 -0
  439. data/vendor/assets/javascripts/highstock/indicators/momentum.src.js +146 -0
  440. data/vendor/assets/javascripts/highstock/indicators/natr.js +12 -0
  441. data/vendor/assets/javascripts/highstock/indicators/natr.js.map +1 -0
  442. data/vendor/assets/javascripts/highstock/indicators/natr.src.js +101 -0
  443. data/vendor/assets/javascripts/highstock/indicators/pivot-points.js +16 -0
  444. data/vendor/assets/javascripts/highstock/indicators/pivot-points.js.map +1 -0
  445. data/vendor/assets/javascripts/highstock/indicators/pivot-points.src.js +387 -0
  446. data/vendor/assets/javascripts/highstock/indicators/ppo.js +13 -0
  447. data/vendor/assets/javascripts/highstock/indicators/ppo.js.map +1 -0
  448. data/vendor/assets/javascripts/highstock/indicators/ppo.src.js +227 -0
  449. data/vendor/assets/javascripts/highstock/indicators/price-channel.js +16 -0
  450. data/vendor/assets/javascripts/highstock/indicators/price-channel.js.map +1 -0
  451. data/vendor/assets/javascripts/highstock/indicators/price-channel.src.js +450 -0
  452. data/vendor/assets/javascripts/highstock/indicators/price-envelopes.js +15 -0
  453. data/vendor/assets/javascripts/highstock/indicators/price-envelopes.js.map +1 -0
  454. data/vendor/assets/javascripts/highstock/indicators/price-envelopes.src.js +278 -0
  455. data/vendor/assets/javascripts/highstock/indicators/psar.js +13 -0
  456. data/vendor/assets/javascripts/highstock/indicators/psar.js.map +1 -0
  457. data/vendor/assets/javascripts/highstock/indicators/psar.src.js +334 -0
  458. data/vendor/assets/javascripts/highstock/indicators/regressions.js +14 -0
  459. data/vendor/assets/javascripts/highstock/indicators/regressions.js.map +1 -0
  460. data/vendor/assets/javascripts/highstock/indicators/regressions.src.js +454 -0
  461. data/vendor/assets/javascripts/highstock/indicators/roc.js +12 -0
  462. data/vendor/assets/javascripts/highstock/indicators/roc.js.map +1 -0
  463. data/vendor/assets/javascripts/highstock/indicators/roc.src.js +176 -0
  464. data/vendor/assets/javascripts/highstock/indicators/rsi.js +12 -0
  465. data/vendor/assets/javascripts/highstock/indicators/rsi.js.map +1 -0
  466. data/vendor/assets/javascripts/highstock/indicators/rsi.src.js +190 -0
  467. data/vendor/assets/javascripts/highstock/indicators/stochastic.js +17 -0
  468. data/vendor/assets/javascripts/highstock/indicators/stochastic.js.map +1 -0
  469. data/vendor/assets/javascripts/highstock/indicators/stochastic.src.js +494 -0
  470. data/vendor/assets/javascripts/highstock/indicators/supertrend.js +17 -0
  471. data/vendor/assets/javascripts/highstock/indicators/supertrend.js.map +1 -0
  472. data/vendor/assets/javascripts/highstock/indicators/supertrend.src.js +571 -0
  473. data/vendor/assets/javascripts/highstock/indicators/tema.js +14 -0
  474. data/vendor/assets/javascripts/highstock/indicators/tema.js.map +1 -0
  475. data/vendor/assets/javascripts/highstock/indicators/tema.src.js +322 -0
  476. data/vendor/assets/javascripts/highstock/indicators/trix.js +12 -0
  477. data/vendor/assets/javascripts/highstock/indicators/trix.js.map +1 -0
  478. data/vendor/assets/javascripts/highstock/indicators/trix.src.js +171 -0
  479. data/vendor/assets/javascripts/highstock/indicators/volume-by-price.js +21 -0
  480. data/vendor/assets/javascripts/highstock/indicators/volume-by-price.js.map +1 -0
  481. data/vendor/assets/javascripts/highstock/indicators/volume-by-price.src.js +698 -0
  482. data/vendor/assets/javascripts/highstock/indicators/vwap.js +12 -0
  483. data/vendor/assets/javascripts/highstock/indicators/vwap.js.map +1 -0
  484. data/vendor/assets/javascripts/highstock/indicators/vwap.src.js +216 -0
  485. data/vendor/assets/javascripts/highstock/indicators/williams-r.js +13 -0
  486. data/vendor/assets/javascripts/highstock/indicators/williams-r.js.map +1 -0
  487. data/vendor/assets/javascripts/highstock/indicators/williams-r.src.js +207 -0
  488. data/vendor/assets/javascripts/highstock/indicators/wma.js +12 -0
  489. data/vendor/assets/javascripts/highstock/indicators/wma.js.map +1 -0
  490. data/vendor/assets/javascripts/highstock/indicators/wma.src.js +173 -0
  491. data/vendor/assets/javascripts/highstock/indicators/zigzag.js +13 -0
  492. data/vendor/assets/javascripts/highstock/indicators/zigzag.js.map +1 -0
  493. data/vendor/assets/javascripts/highstock/indicators/zigzag.src.js +248 -0
  494. data/vendor/assets/javascripts/highstock/lib/canvg.js +130 -0
  495. data/vendor/assets/javascripts/highstock/lib/canvg.src.js +3073 -0
  496. data/vendor/assets/javascripts/highstock/lib/jspdf.js +283 -0
  497. data/vendor/assets/javascripts/highstock/lib/jspdf.src.js +21627 -0
  498. data/vendor/assets/javascripts/highstock/lib/rgbcolor.js +17 -0
  499. data/vendor/assets/javascripts/highstock/lib/rgbcolor.src.js +299 -0
  500. data/vendor/assets/javascripts/highstock/lib/svg2pdf.js +38 -0
  501. data/vendor/assets/javascripts/highstock/lib/svg2pdf.src.js +4390 -0
  502. data/vendor/assets/javascripts/highstock/modules/accessibility.js +73 -0
  503. data/vendor/assets/javascripts/highstock/modules/accessibility.js.map +1 -0
  504. data/vendor/assets/javascripts/highstock/modules/accessibility.src.js +3103 -0
  505. data/vendor/assets/javascripts/highstock/modules/annotations-advanced.js +132 -0
  506. data/vendor/assets/javascripts/highstock/modules/annotations-advanced.js.map +1 -0
  507. data/vendor/assets/javascripts/highstock/modules/annotations-advanced.src.js +8230 -0
  508. data/vendor/assets/javascripts/highstock/modules/annotations.js +94 -0
  509. data/vendor/assets/javascripts/highstock/modules/annotations.js.map +1 -0
  510. data/vendor/assets/javascripts/highstock/modules/annotations.src.js +6001 -0
  511. data/vendor/assets/javascripts/highstock/modules/arrow-symbols.js +11 -0
  512. data/vendor/assets/javascripts/highstock/modules/arrow-symbols.js.map +1 -0
  513. data/vendor/assets/javascripts/highstock/modules/arrow-symbols.src.js +225 -0
  514. data/vendor/assets/javascripts/highstock/modules/boost-canvas.js +23 -0
  515. data/vendor/assets/javascripts/highstock/modules/boost-canvas.js.map +1 -0
  516. data/vendor/assets/javascripts/highstock/modules/boost-canvas.src.js +756 -0
  517. data/vendor/assets/javascripts/highstock/modules/boost.js +65 -0
  518. data/vendor/assets/javascripts/highstock/modules/boost.js.map +1 -0
  519. data/vendor/assets/javascripts/highstock/modules/boost.src.js +3752 -0
  520. data/vendor/assets/javascripts/highstock/modules/bullet.js +14 -0
  521. data/vendor/assets/javascripts/highstock/modules/bullet.js.map +1 -0
  522. data/vendor/assets/javascripts/highstock/modules/bullet.src.js +388 -0
  523. data/vendor/assets/javascripts/highstock/modules/current-date-indicator.js +11 -0
  524. data/vendor/assets/javascripts/highstock/modules/current-date-indicator.js.map +1 -0
  525. data/vendor/assets/javascripts/highstock/modules/current-date-indicator.src.js +127 -0
  526. data/vendor/assets/javascripts/highstock/modules/cylinder.js +14 -0
  527. data/vendor/assets/javascripts/highstock/modules/cylinder.js.map +1 -0
  528. data/vendor/assets/javascripts/highstock/modules/cylinder.src.js +413 -0
  529. data/vendor/assets/javascripts/highstock/modules/data.js +37 -0
  530. data/vendor/assets/javascripts/highstock/modules/data.js.map +1 -0
  531. data/vendor/assets/javascripts/highstock/modules/data.src.js +2565 -0
  532. data/vendor/assets/javascripts/highstock/modules/datagrouping.js +25 -0
  533. data/vendor/assets/javascripts/highstock/modules/datagrouping.js.map +1 -0
  534. data/vendor/assets/javascripts/highstock/modules/datagrouping.src.js +1140 -0
  535. data/vendor/assets/javascripts/highstock/modules/debugger.js +28 -0
  536. data/vendor/assets/javascripts/highstock/modules/debugger.js.map +1 -0
  537. data/vendor/assets/javascripts/highstock/modules/debugger.src.js +267 -0
  538. data/vendor/assets/javascripts/highstock/modules/dependency-wheel.js +15 -0
  539. data/vendor/assets/javascripts/highstock/modules/dependency-wheel.js.map +1 -0
  540. data/vendor/assets/javascripts/highstock/modules/dependency-wheel.src.js +301 -0
  541. data/vendor/assets/javascripts/highstock/modules/drag-panes.js +18 -0
  542. data/vendor/assets/javascripts/highstock/modules/drag-panes.js.map +1 -0
  543. data/vendor/assets/javascripts/highstock/modules/drag-panes.src.js +649 -0
  544. data/vendor/assets/javascripts/highstock/modules/draggable-points.js +40 -0
  545. data/vendor/assets/javascripts/highstock/modules/draggable-points.js.map +1 -0
  546. data/vendor/assets/javascripts/highstock/modules/draggable-points.src.js +2650 -0
  547. data/vendor/assets/javascripts/highstock/modules/drilldown.js +29 -0
  548. data/vendor/assets/javascripts/highstock/modules/drilldown.js.map +1 -0
  549. data/vendor/assets/javascripts/highstock/modules/drilldown.src.js +1321 -0
  550. data/vendor/assets/javascripts/highstock/modules/export-data.js +27 -0
  551. data/vendor/assets/javascripts/highstock/modules/export-data.js.map +1 -0
  552. data/vendor/assets/javascripts/highstock/modules/export-data.src.js +1234 -0
  553. data/vendor/assets/javascripts/highstock/modules/exporting.js +35 -0
  554. data/vendor/assets/javascripts/highstock/modules/exporting.js.map +1 -0
  555. data/vendor/assets/javascripts/highstock/modules/exporting.src.js +2233 -0
  556. data/vendor/assets/javascripts/highstock/modules/full-screen.js +11 -0
  557. data/vendor/assets/javascripts/highstock/modules/full-screen.js.map +1 -0
  558. data/vendor/assets/javascripts/highstock/modules/full-screen.src.js +68 -0
  559. data/vendor/assets/javascripts/highstock/modules/funnel.js +14 -0
  560. data/vendor/assets/javascripts/highstock/modules/funnel.js.map +1 -0
  561. data/vendor/assets/javascripts/highstock/modules/funnel.src.js +576 -0
  562. data/vendor/assets/javascripts/highstock/modules/grid-axis.js +23 -0
  563. data/vendor/assets/javascripts/highstock/modules/grid-axis.js.map +1 -0
  564. data/vendor/assets/javascripts/highstock/modules/grid-axis.src.js +988 -0
  565. data/vendor/assets/javascripts/highstock/modules/heatmap.js +28 -0
  566. data/vendor/assets/javascripts/highstock/modules/heatmap.js.map +1 -0
  567. data/vendor/assets/javascripts/highstock/modules/heatmap.src.js +1731 -0
  568. data/vendor/assets/javascripts/highstock/modules/histogram-bellcurve.js +16 -0
  569. data/vendor/assets/javascripts/highstock/modules/histogram-bellcurve.js.map +1 -0
  570. data/vendor/assets/javascripts/highstock/modules/histogram-bellcurve.src.js +570 -0
  571. data/vendor/assets/javascripts/highstock/modules/item-series.js +13 -0
  572. data/vendor/assets/javascripts/highstock/modules/item-series.js.map +1 -0
  573. data/vendor/assets/javascripts/highstock/modules/item-series.src.js +176 -0
  574. data/vendor/assets/javascripts/highstock/modules/networkgraph.js +31 -0
  575. data/vendor/assets/javascripts/highstock/modules/networkgraph.js.map +1 -0
  576. data/vendor/assets/javascripts/highstock/modules/networkgraph.src.js +1348 -0
  577. data/vendor/assets/javascripts/highstock/modules/no-data-to-display.js +13 -0
  578. data/vendor/assets/javascripts/highstock/modules/no-data-to-display.js.map +1 -0
  579. data/vendor/assets/javascripts/highstock/modules/no-data-to-display.src.js +285 -0
  580. data/vendor/assets/javascripts/highstock/modules/offline-exporting.js +22 -0
  581. data/vendor/assets/javascripts/highstock/modules/offline-exporting.js.map +1 -0
  582. data/vendor/assets/javascripts/highstock/modules/offline-exporting.src.js +838 -0
  583. data/vendor/assets/javascripts/highstock/modules/oldie-polyfills.js +13 -0
  584. data/vendor/assets/javascripts/highstock/modules/oldie-polyfills.js.map +1 -0
  585. data/vendor/assets/javascripts/highstock/modules/oldie-polyfills.src.js +150 -0
  586. data/vendor/assets/javascripts/highstock/modules/oldie.js +35 -0
  587. data/vendor/assets/javascripts/highstock/modules/oldie.js.map +1 -0
  588. data/vendor/assets/javascripts/highstock/modules/oldie.src.js +1582 -0
  589. data/vendor/assets/javascripts/highstock/modules/overlapping-datalabels.js +9 -0
  590. data/vendor/assets/javascripts/highstock/modules/overlapping-datalabels.js.map +1 -0
  591. data/vendor/assets/javascripts/highstock/modules/overlapping-datalabels.src.js +22 -0
  592. data/vendor/assets/javascripts/highstock/modules/parallel-coordinates.js +18 -0
  593. data/vendor/assets/javascripts/highstock/modules/parallel-coordinates.js.map +1 -0
  594. data/vendor/assets/javascripts/highstock/modules/parallel-coordinates.src.js +517 -0
  595. data/vendor/assets/javascripts/highstock/modules/pareto.js +14 -0
  596. data/vendor/assets/javascripts/highstock/modules/pareto.js.map +1 -0
  597. data/vendor/assets/javascripts/highstock/modules/pareto.src.js +327 -0
  598. data/vendor/assets/javascripts/highstock/modules/pathfinder.js +34 -0
  599. data/vendor/assets/javascripts/highstock/modules/pathfinder.js.map +1 -0
  600. data/vendor/assets/javascripts/highstock/modules/pathfinder.src.js +2336 -0
  601. data/vendor/assets/javascripts/highstock/modules/pattern-fill.js +21 -0
  602. data/vendor/assets/javascripts/highstock/modules/pattern-fill.js.map +1 -0
  603. data/vendor/assets/javascripts/highstock/modules/pattern-fill.src.js +634 -0
  604. data/vendor/assets/javascripts/highstock/modules/price-indicator.js +13 -0
  605. data/vendor/assets/javascripts/highstock/modules/price-indicator.js.map +1 -0
  606. data/vendor/assets/javascripts/highstock/modules/price-indicator.src.js +176 -0
  607. data/vendor/assets/javascripts/highstock/modules/sankey.js +22 -0
  608. data/vendor/assets/javascripts/highstock/modules/sankey.js.map +1 -0
  609. data/vendor/assets/javascripts/highstock/modules/sankey.src.js +911 -0
  610. data/vendor/assets/javascripts/highstock/modules/series-label.js +23 -0
  611. data/vendor/assets/javascripts/highstock/modules/series-label.js.map +1 -0
  612. data/vendor/assets/javascripts/highstock/modules/series-label.src.js +1065 -0
  613. data/vendor/assets/javascripts/highstock/modules/solid-gauge.js +15 -0
  614. data/vendor/assets/javascripts/highstock/modules/solid-gauge.js.map +1 -0
  615. data/vendor/assets/javascripts/highstock/modules/solid-gauge.src.js +510 -0
  616. data/vendor/assets/javascripts/highstock/modules/sonification.js +53 -0
  617. data/vendor/assets/javascripts/highstock/modules/sonification.js.map +1 -0
  618. data/vendor/assets/javascripts/highstock/modules/sonification.src.js +3341 -0
  619. data/vendor/assets/javascripts/highstock/modules/static-scale.js +12 -0
  620. data/vendor/assets/javascripts/highstock/modules/static-scale.js.map +1 -0
  621. data/vendor/assets/javascripts/highstock/modules/static-scale.src.js +114 -0
  622. data/vendor/assets/javascripts/highstock/modules/stock-tools.js +65 -0
  623. data/vendor/assets/javascripts/highstock/modules/stock-tools.js.map +1 -0
  624. data/vendor/assets/javascripts/highstock/modules/stock-tools.src.js +3437 -0
  625. data/vendor/assets/javascripts/highstock/modules/stock.js +151 -0
  626. data/vendor/assets/javascripts/highstock/modules/stock.js.map +1 -0
  627. data/vendor/assets/javascripts/highstock/modules/stock.src.js +10907 -0
  628. data/vendor/assets/javascripts/highstock/modules/streamgraph.js +10 -0
  629. data/vendor/assets/javascripts/highstock/modules/streamgraph.js.map +1 -0
  630. data/vendor/assets/javascripts/highstock/modules/streamgraph.src.js +158 -0
  631. data/vendor/assets/javascripts/highstock/modules/sunburst.js +52 -0
  632. data/vendor/assets/javascripts/highstock/modules/sunburst.js.map +1 -0
  633. data/vendor/assets/javascripts/highstock/modules/sunburst.src.js +3174 -0
  634. data/vendor/assets/javascripts/highstock/modules/tilemap.js +26 -0
  635. data/vendor/assets/javascripts/highstock/modules/tilemap.js.map +1 -0
  636. data/vendor/assets/javascripts/highstock/modules/tilemap.src.js +1402 -0
  637. data/vendor/assets/javascripts/highstock/modules/timeline.js +23 -0
  638. data/vendor/assets/javascripts/highstock/modules/timeline.js.map +1 -0
  639. data/vendor/assets/javascripts/highstock/modules/timeline.src.js +778 -0
  640. data/vendor/assets/javascripts/highstock/modules/treegrid.js +50 -0
  641. data/vendor/assets/javascripts/highstock/modules/treegrid.js.map +1 -0
  642. data/vendor/assets/javascripts/highstock/modules/treegrid.src.js +2917 -0
  643. data/vendor/assets/javascripts/highstock/modules/treemap.js +39 -0
  644. data/vendor/assets/javascripts/highstock/modules/treemap.js.map +1 -0
  645. data/vendor/assets/javascripts/highstock/modules/treemap.src.js +2083 -0
  646. data/vendor/assets/javascripts/highstock/modules/variable-pie.js +16 -0
  647. data/vendor/assets/javascripts/highstock/modules/variable-pie.js.map +1 -0
  648. data/vendor/assets/javascripts/highstock/modules/variable-pie.src.js +485 -0
  649. data/vendor/assets/javascripts/highstock/modules/variwide.js +15 -0
  650. data/vendor/assets/javascripts/highstock/modules/variwide.js.map +1 -0
  651. data/vendor/assets/javascripts/highstock/modules/variwide.src.js +376 -0
  652. data/vendor/assets/javascripts/highstock/modules/vector.js +13 -0
  653. data/vendor/assets/javascripts/highstock/modules/vector.js.map +1 -0
  654. data/vendor/assets/javascripts/highstock/modules/vector.src.js +381 -0
  655. data/vendor/assets/javascripts/highstock/modules/venn.js +30 -0
  656. data/vendor/assets/javascripts/highstock/modules/venn.js.map +1 -0
  657. data/vendor/assets/javascripts/highstock/modules/venn.src.js +1624 -0
  658. data/vendor/assets/javascripts/highstock/modules/windbarb.js +17 -0
  659. data/vendor/assets/javascripts/highstock/modules/windbarb.js.map +1 -0
  660. data/vendor/assets/javascripts/highstock/modules/windbarb.src.js +574 -0
  661. data/vendor/assets/javascripts/highstock/modules/wordcloud.js +25 -0
  662. data/vendor/assets/javascripts/highstock/modules/wordcloud.js.map +1 -0
  663. data/vendor/assets/javascripts/highstock/modules/wordcloud.src.js +1475 -0
  664. data/vendor/assets/javascripts/highstock/modules/xrange.js +20 -0
  665. data/vendor/assets/javascripts/highstock/modules/xrange.js.map +1 -0
  666. data/vendor/assets/javascripts/highstock/modules/xrange.src.js +788 -0
  667. data/vendor/assets/javascripts/highstock/themes/avocado.js +9 -0
  668. data/vendor/assets/javascripts/highstock/themes/avocado.js.map +1 -0
  669. data/vendor/assets/javascripts/highstock/themes/avocado.src.js +63 -0
  670. data/vendor/assets/javascripts/highstock/themes/dark-blue.js +15 -0
  671. data/vendor/assets/javascripts/highstock/themes/dark-blue.js.map +1 -0
  672. data/vendor/assets/javascripts/highstock/themes/dark-blue.src.js +285 -0
  673. data/vendor/assets/javascripts/highstock/themes/dark-green.js +15 -0
  674. data/vendor/assets/javascripts/highstock/themes/dark-green.js.map +1 -0
  675. data/vendor/assets/javascripts/highstock/themes/dark-green.src.js +287 -0
  676. data/vendor/assets/javascripts/highstock/themes/dark-unica.js +14 -0
  677. data/vendor/assets/javascripts/highstock/themes/dark-unica.js.map +1 -0
  678. data/vendor/assets/javascripts/highstock/themes/dark-unica.src.js +246 -0
  679. data/vendor/assets/javascripts/highstock/themes/gray.js +15 -0
  680. data/vendor/assets/javascripts/highstock/themes/gray.js.map +1 -0
  681. data/vendor/assets/javascripts/highstock/themes/gray.src.js +293 -0
  682. data/vendor/assets/javascripts/highstock/themes/grid-light.js +11 -0
  683. data/vendor/assets/javascripts/highstock/themes/grid-light.js.map +1 -0
  684. data/vendor/assets/javascripts/highstock/themes/grid-light.src.js +107 -0
  685. data/vendor/assets/javascripts/highstock/themes/grid.js +11 -0
  686. data/vendor/assets/javascripts/highstock/themes/grid.js.map +1 -0
  687. data/vendor/assets/javascripts/highstock/themes/grid.src.js +136 -0
  688. data/vendor/assets/javascripts/highstock/themes/sand-signika.js +11 -0
  689. data/vendor/assets/javascripts/highstock/themes/sand-signika.js.map +1 -0
  690. data/vendor/assets/javascripts/highstock/themes/sand-signika.src.js +137 -0
  691. data/vendor/assets/javascripts/highstock/themes/skies.js +11 -0
  692. data/vendor/assets/javascripts/highstock/themes/skies.js.map +1 -0
  693. data/vendor/assets/javascripts/highstock/themes/skies.src.js +126 -0
  694. data/vendor/assets/javascripts/highstock/themes/sunset.js +9 -0
  695. data/vendor/assets/javascripts/highstock/themes/sunset.js.map +1 -0
  696. data/vendor/assets/javascripts/highstock/themes/sunset.src.js +62 -0
  697. metadata +781 -0
@@ -0,0 +1,107 @@
1
+ /* *
2
+ *
3
+ * (c) 2009-2019 Øystein Moseng
4
+ *
5
+ * Sonification module for Highcharts
6
+ *
7
+ * License: www.highcharts.com/license
8
+ *
9
+ * */
10
+
11
+ 'use strict';
12
+
13
+ import H from '../../parts/Globals.js';
14
+ import Instrument from './Instrument';
15
+ import instruments from './instrumentDefinitions';
16
+ import Earcon from './Earcon';
17
+ import pointSonifyFunctions from './pointSonify';
18
+ import chartSonifyFunctions from './chartSonify';
19
+ import utilities from './utilities';
20
+ import TimelineClasses from './Timeline';
21
+
22
+ // Expose on the Highcharts object
23
+
24
+ /**
25
+ * Global classes and objects related to sonification.
26
+ *
27
+ * @requires module:modules/sonification
28
+ *
29
+ * @name Highcharts.sonification
30
+ * @type {Highcharts.SonificationObject}
31
+ */
32
+
33
+ /**
34
+ * Global classes and objects related to sonification.
35
+ *
36
+ * @requires module:modules/sonification
37
+ *
38
+ * @interface Highcharts.SonificationObject
39
+ *//**
40
+ * Note fade-out-time in milliseconds. Most notes are faded out quickly by
41
+ * default if there is time. This is to avoid abrupt stops which will cause
42
+ * perceived clicks.
43
+ * @name Highcharts.SonificationObject#fadeOutDuration
44
+ * @type {number}
45
+ *//**
46
+ * Utility functions.
47
+ * @name Highcharts.SonificationObject#utilities
48
+ * @private
49
+ * @type {object}
50
+ *//**
51
+ * The Instrument class.
52
+ * @name Highcharts.SonificationObject#Instrument
53
+ * @type {Function}
54
+ *//**
55
+ * Predefined instruments, given as an object with a map between the instrument
56
+ * name and the Highcharts.Instrument object.
57
+ * @name Highcharts.SonificationObject#instruments
58
+ * @type {Object}
59
+ *//**
60
+ * The Earcon class.
61
+ * @name Highcharts.SonificationObject#Earcon
62
+ * @type {Function}
63
+ *//**
64
+ * The TimelineEvent class.
65
+ * @private
66
+ * @name Highcharts.SonificationObject#TimelineEvent
67
+ * @type {Function}
68
+ *//**
69
+ * The TimelinePath class.
70
+ * @private
71
+ * @name Highcharts.SonificationObject#TimelinePath
72
+ * @type {Function}
73
+ *//**
74
+ * The Timeline class.
75
+ * @private
76
+ * @name Highcharts.SonificationObject#Timeline
77
+ * @type {Function}
78
+ */
79
+ H.sonification = {
80
+ fadeOutDuration: 20,
81
+
82
+ // Classes and functions
83
+ utilities: utilities,
84
+ Instrument: Instrument,
85
+ instruments: instruments,
86
+ Earcon: Earcon,
87
+ TimelineEvent: TimelineClasses.TimelineEvent,
88
+ TimelinePath: TimelineClasses.TimelinePath,
89
+ Timeline: TimelineClasses.Timeline
90
+ };
91
+
92
+ // Chart specific
93
+ H.Point.prototype.sonify = pointSonifyFunctions.pointSonify;
94
+ H.Point.prototype.cancelSonify = pointSonifyFunctions.pointCancelSonify;
95
+ H.Series.prototype.sonify = chartSonifyFunctions.seriesSonify;
96
+ H.extend(H.Chart.prototype, {
97
+ sonify: chartSonifyFunctions.chartSonify,
98
+ pauseSonify: chartSonifyFunctions.pause,
99
+ resumeSonify: chartSonifyFunctions.resume,
100
+ rewindSonify: chartSonifyFunctions.rewind,
101
+ cancelSonify: chartSonifyFunctions.cancel,
102
+ getCurrentSonifyPoints: chartSonifyFunctions.getCurrentPoints,
103
+ setSonifyCursor: chartSonifyFunctions.setCursor,
104
+ resetSonifyCursor: chartSonifyFunctions.resetCursor,
105
+ resetSonifyCursorEnd: chartSonifyFunctions.resetCursorEnd,
106
+ sonification: {}
107
+ });
@@ -0,0 +1,178 @@
1
+ /* *
2
+ *
3
+ * (c) 2009-2019 Øystein Moseng
4
+ *
5
+ * Utility functions for sonification.
6
+ *
7
+ * License: www.highcharts.com/license
8
+ *
9
+ * */
10
+
11
+ 'use strict';
12
+
13
+ import musicalFrequencies from './musicalFrequencies';
14
+
15
+
16
+ /**
17
+ * The SignalHandler class. Stores signal callbacks (event handlers), and
18
+ * provides an interface to register them, and emit signals. The word "event" is
19
+ * not used to avoid confusion with TimelineEvents.
20
+ *
21
+ * @requires module:modules/sonification
22
+ *
23
+ * @private
24
+ * @class
25
+ * @name Highcharts.SignalHandler
26
+ *
27
+ * @param {Array<string>} supportedSignals
28
+ * List of supported signal names.
29
+ */
30
+ function SignalHandler(supportedSignals) {
31
+ this.init(supportedSignals || []);
32
+ }
33
+ SignalHandler.prototype.init = function (supportedSignals) {
34
+ this.supportedSignals = supportedSignals;
35
+ this.signals = {};
36
+ };
37
+
38
+
39
+ /**
40
+ * Register a set of signal callbacks with this SignalHandler.
41
+ * Multiple signal callbacks can be registered for the same signal.
42
+ * @private
43
+ * @param {object} signals - An object that contains a mapping from the signal
44
+ * name to the callbacks. Only supported events are considered.
45
+ */
46
+ SignalHandler.prototype.registerSignalCallbacks = function (signals) {
47
+ var signalHandler = this;
48
+
49
+ signalHandler.supportedSignals.forEach(function (supportedSignal) {
50
+ if (signals[supportedSignal]) {
51
+ (
52
+ signalHandler.signals[supportedSignal] =
53
+ signalHandler.signals[supportedSignal] || []
54
+ ).push(
55
+ signals[supportedSignal]
56
+ );
57
+ }
58
+ });
59
+ };
60
+
61
+
62
+ /**
63
+ * Clear signal callbacks, optionally by name.
64
+ * @private
65
+ * @param {Array<string>} [signalNames] - A list of signal names to clear. If
66
+ * not supplied, all signal callbacks are removed.
67
+ */
68
+ SignalHandler.prototype.clearSignalCallbacks = function (signalNames) {
69
+ var signalHandler = this;
70
+
71
+ if (signalNames) {
72
+ signalNames.forEach(function (signalName) {
73
+ if (signalHandler.signals[signalName]) {
74
+ delete signalHandler.signals[signalName];
75
+ }
76
+ });
77
+ } else {
78
+ signalHandler.signals = {};
79
+ }
80
+ };
81
+
82
+
83
+ /**
84
+ * Emit a signal. Does nothing if the signal does not exist, or has no
85
+ * registered callbacks.
86
+ * @private
87
+ * @param {string} signalNames - Name of signal to emit.
88
+ * @param {*} data - Data to pass to the callback.
89
+ */
90
+ SignalHandler.prototype.emitSignal = function (signalName, data) {
91
+ var retval;
92
+
93
+ if (this.signals[signalName]) {
94
+ this.signals[signalName].forEach(function (handler) {
95
+ var result = handler(data);
96
+
97
+ retval = result !== undefined ? result : retval;
98
+ });
99
+ }
100
+ return retval;
101
+ };
102
+
103
+
104
+ var utilities = {
105
+
106
+ // List of musical frequencies from C0 to C8
107
+ musicalFrequencies: musicalFrequencies,
108
+
109
+ // SignalHandler class
110
+ SignalHandler: SignalHandler,
111
+
112
+ /**
113
+ * Get a musical scale by specifying the semitones from 1-12 to include.
114
+ * 1: C, 2: C#, 3: D, 4: D#, 5: E, 6: F,
115
+ * 7: F#, 8: G, 9: G#, 10: A, 11: Bb, 12: B
116
+ * @private
117
+ * @param {Array<number>} semitones - Array of semitones from 1-12 to
118
+ * include in the scale. Duplicate entries are ignored.
119
+ * @return {Array<number>} Array of frequencies from C0 to C8 that are
120
+ * included in this scale.
121
+ */
122
+ getMusicalScale: function (semitones) {
123
+ return musicalFrequencies.filter(function (freq, i) {
124
+ var interval = i % 12 + 1;
125
+
126
+ return semitones.some(function (allowedInterval) {
127
+ return allowedInterval === interval;
128
+ });
129
+ });
130
+ },
131
+
132
+ /**
133
+ * Calculate the extreme values in a chart for a data prop.
134
+ * @private
135
+ * @param {Highcharts.Chart} chart - The chart
136
+ * @param {string} prop - The data prop to find extremes for
137
+ * @return {object} Object with min and max properties
138
+ */
139
+ calculateDataExtremes: function (chart, prop) {
140
+ return chart.series.reduce(function (extremes, series) {
141
+ // We use cropped points rather than series.data here, to allow
142
+ // users to zoom in for better fidelity.
143
+ series.points.forEach(function (point) {
144
+ var val = point[prop] !== undefined ?
145
+ point[prop] : point.options[prop];
146
+
147
+ extremes.min = Math.min(extremes.min, val);
148
+ extremes.max = Math.max(extremes.max, val);
149
+ });
150
+ return extremes;
151
+ }, {
152
+ min: Infinity,
153
+ max: -Infinity
154
+ });
155
+ },
156
+
157
+ /**
158
+ * Translate a value on a virtual axis. Creates a new, virtual, axis with a
159
+ * min and max, and maps the relative value onto this axis.
160
+ * @private
161
+ * @param {number} value - The relative data value to translate.
162
+ * @param {object} dataExtremes - The possible extremes for this value.
163
+ * @param {object} limits - Limits for the virtual axis.
164
+ * @return {number} The value mapped to the virtual axis.
165
+ */
166
+ virtualAxisTranslate: function (value, dataExtremes, limits) {
167
+ var lenValueAxis = dataExtremes.max - dataExtremes.min,
168
+ lenVirtualAxis = limits.max - limits.min,
169
+ virtualAxisValue = limits.min +
170
+ lenVirtualAxis * (value - dataExtremes.min) / lenValueAxis;
171
+
172
+ return lenValueAxis > 0 ?
173
+ Math.max(Math.min(virtualAxisValue, limits.max), limits.min) :
174
+ limits.min;
175
+ }
176
+ };
177
+
178
+ export default utilities;
@@ -0,0 +1,88 @@
1
+ /* *
2
+ * (c) 2016-2019 Torstein Honsi, Lars Cabrera
3
+ *
4
+ * License: www.highcharts.com/license
5
+ */
6
+
7
+ 'use strict';
8
+
9
+ import H from '../parts/Globals.js';
10
+ import '../parts/Utilities.js';
11
+
12
+ var Chart = H.Chart,
13
+ pick = H.pick;
14
+
15
+ /**
16
+ * For vertical axes only. Setting the static scale ensures that each tick unit
17
+ * is translated into a fixed pixel height. For example, setting the static
18
+ * scale to 24 results in each Y axis category taking up 24 pixels, and the
19
+ * height of the chart adjusts. Adding or removing items will make the chart
20
+ * resize.
21
+ *
22
+ * @sample gantt/xrange-series/demo/
23
+ * X-range series with static scale
24
+ *
25
+ * @type {number}
26
+ * @default 50
27
+ * @since 6.2.0
28
+ * @product gantt
29
+ * @apioption yAxis.staticScale
30
+ */
31
+
32
+ H.addEvent(H.Axis, 'afterSetOptions', function () {
33
+ if (
34
+ !this.horiz &&
35
+ H.isNumber(this.options.staticScale) &&
36
+ !this.chart.options.chart.height
37
+ ) {
38
+ this.staticScale = this.options.staticScale;
39
+ }
40
+ });
41
+
42
+ Chart.prototype.adjustHeight = function () {
43
+ if (this.redrawTrigger !== 'adjustHeight') {
44
+ (this.axes || []).forEach(function (axis) {
45
+ var chart = axis.chart,
46
+ animate = !!chart.initiatedScale && chart.options.animation,
47
+ staticScale = axis.options.staticScale,
48
+ height,
49
+ diff;
50
+
51
+ if (axis.staticScale && H.defined(axis.min)) {
52
+ height = pick(
53
+ axis.unitLength,
54
+ axis.max + axis.tickInterval - axis.min
55
+ ) * staticScale;
56
+
57
+
58
+ // Minimum height is 1 x staticScale.
59
+ height = Math.max(height, staticScale);
60
+
61
+ diff = height - chart.plotHeight;
62
+
63
+ if (Math.abs(diff) >= 1) {
64
+ chart.plotHeight = height;
65
+ chart.redrawTrigger = 'adjustHeight';
66
+ chart.setSize(undefined, chart.chartHeight + diff, animate);
67
+ }
68
+
69
+ // Make sure clip rects have the right height before initial
70
+ // animation.
71
+ axis.series.forEach(function (series) {
72
+ var clipRect =
73
+ series.sharedClipKey && chart[series.sharedClipKey];
74
+
75
+ if (clipRect) {
76
+ clipRect.attr({
77
+ height: chart.plotHeight
78
+ });
79
+ }
80
+ });
81
+ }
82
+
83
+ });
84
+ this.initiatedScale = true;
85
+ }
86
+ this.redrawTrigger = null;
87
+ };
88
+ H.addEvent(Chart, 'render', Chart.prototype.adjustHeight);
@@ -0,0 +1,1950 @@
1
+ /**
2
+ *
3
+ * Events generator for Stock tools
4
+ *
5
+ * (c) 2009-2019 Paweł Fus
6
+ *
7
+ * License: www.highcharts.com/license
8
+ *
9
+ * */
10
+
11
+ /**
12
+ * A config object for bindings in Stock Tools module.
13
+ *
14
+ * @interface Highcharts.StockToolsBindingsObject
15
+ *//**
16
+ * ClassName of the element for a binding.
17
+ * @name Highcharts.StockToolsBindingsObject#className
18
+ * @type {string|undefined}
19
+ *//**
20
+ * Last event to be fired after last step event.
21
+ * @name Highcharts.StockToolsBindingsObject#end
22
+ * @type {Function|undefined}
23
+ *//**
24
+ * Initial event, fired on a button click.
25
+ * @name Highcharts.StockToolsBindingsObject#init
26
+ * @type {Function|undefined}
27
+ *//**
28
+ * Event fired on first click on a chart.
29
+ * @name Highcharts.StockToolsBindingsObject#start
30
+ * @type {Function|undefined}
31
+ *//**
32
+ * Last event to be fired after last step event. Array of step events to be
33
+ * called sequentially after each user click.
34
+ * @name Highcharts.StockToolsBindingsObject#steps
35
+ * @type {Array<Function>|undefined}
36
+ */
37
+
38
+ 'use strict';
39
+
40
+ import H from '../parts/Globals.js';
41
+
42
+ var fireEvent = H.fireEvent,
43
+ defined = H.defined,
44
+ pick = H.pick,
45
+ extend = H.extend,
46
+ isNumber = H.isNumber,
47
+ correctFloat = H.correctFloat,
48
+ bindingsUtils = H.NavigationBindings.prototype.utils,
49
+ PREFIX = 'highcharts-';
50
+
51
+ /**
52
+ * Generates function which will add a flag series using modal in GUI.
53
+ * Method fires an event "showPopup" with config:
54
+ * `{type, options, callback}`.
55
+ *
56
+ * Example: NavigationBindings.utils.addFlagFromForm('url(...)') - will
57
+ * generate function that shows modal in GUI.
58
+ *
59
+ * @private
60
+ * @function bindingsUtils.addFlagFromForm
61
+ *
62
+ * @param {string} type
63
+ * Type of flag series, e.g. "squarepin"
64
+ *
65
+ * @return {Function}
66
+ * Callback to be used in `start` callback
67
+ */
68
+ bindingsUtils.addFlagFromForm = function (type) {
69
+ return function (e) {
70
+ var navigation = this,
71
+ chart = navigation.chart,
72
+ toolbar = chart.toolbar,
73
+ getFieldType = bindingsUtils.getFieldType,
74
+ point = bindingsUtils.attractToPoint(e, chart),
75
+ pointConfig = {
76
+ x: point.x,
77
+ y: point.y
78
+ },
79
+ seriesOptions = {
80
+ type: 'flags',
81
+ onSeries: point.series.id,
82
+ shape: type,
83
+ data: [pointConfig],
84
+ point: {
85
+ events: {
86
+ click: function () {
87
+ var point = this,
88
+ options = point.options;
89
+
90
+ fireEvent(
91
+ navigation,
92
+ 'showPopup',
93
+ {
94
+ point: point,
95
+ formType: 'annotation-toolbar',
96
+ options: {
97
+ langKey: 'flags',
98
+ type: 'flags',
99
+ title: [
100
+ options.title,
101
+ getFieldType(
102
+ options.title
103
+ )
104
+ ],
105
+ name: [
106
+ options.name,
107
+ getFieldType(
108
+ options.name
109
+ )
110
+ ]
111
+ },
112
+ onSubmit: function (updated) {
113
+ point.update(
114
+ navigation.fieldsToOptions(
115
+ updated.fields,
116
+ {}
117
+ )
118
+ );
119
+ }
120
+ }
121
+ );
122
+ }
123
+ }
124
+ }
125
+ };
126
+
127
+ if (!toolbar || !toolbar.guiEnabled) {
128
+ chart.addSeries(seriesOptions);
129
+ }
130
+
131
+ fireEvent(
132
+ navigation,
133
+ 'showPopup',
134
+ {
135
+ formType: 'flag',
136
+ // Enabled options:
137
+ options: {
138
+ langKey: 'flags',
139
+ type: 'flags',
140
+ title: ['A', getFieldType('A')],
141
+ name: ['Flag A', getFieldType('Flag A')]
142
+ },
143
+ // Callback on submit:
144
+ onSubmit: function (data) {
145
+ navigation.fieldsToOptions(
146
+ data.fields,
147
+ seriesOptions.data[0]
148
+ );
149
+ chart.addSeries(seriesOptions);
150
+ }
151
+ }
152
+ );
153
+ };
154
+ };
155
+
156
+ bindingsUtils.manageIndicators = function (data) {
157
+ var navigation = this,
158
+ chart = navigation.chart,
159
+ seriesConfig = {
160
+ linkedTo: data.linkedTo,
161
+ type: data.type
162
+ },
163
+ indicatorsWithVolume = [
164
+ 'ad',
165
+ 'cmf',
166
+ 'mfi',
167
+ 'vbp',
168
+ 'vwap'
169
+ ],
170
+ indicatorsWithAxes = [
171
+ 'ad',
172
+ 'atr',
173
+ 'cci',
174
+ 'cmf',
175
+ 'macd',
176
+ 'mfi',
177
+ 'roc',
178
+ 'rsi',
179
+ 'vwap',
180
+ 'ao',
181
+ 'aroon',
182
+ 'aroonoscillator',
183
+ 'trix',
184
+ 'apo',
185
+ 'dpo',
186
+ 'ppo',
187
+ 'natr',
188
+ 'williamsr',
189
+ 'linearRegression',
190
+ 'linearRegressionSlope',
191
+ 'linearRegressionIntercept',
192
+ 'linearRegressionAngle'
193
+ ],
194
+ yAxis,
195
+ series;
196
+
197
+ if (data.actionType === 'edit') {
198
+ navigation.fieldsToOptions(data.fields, seriesConfig);
199
+ series = chart.get(data.seriesId);
200
+
201
+ if (series) {
202
+ series.update(seriesConfig, false);
203
+ }
204
+ } else if (data.actionType === 'remove') {
205
+ series = chart.get(data.seriesId);
206
+ if (series) {
207
+ yAxis = series.yAxis;
208
+
209
+ if (series.linkedSeries) {
210
+ series.linkedSeries.forEach(function (linkedSeries) {
211
+ linkedSeries.remove(false);
212
+ });
213
+ }
214
+
215
+ series.remove(false);
216
+
217
+ if (indicatorsWithAxes.indexOf(series.type) >= 0) {
218
+ yAxis.remove(false);
219
+ navigation.resizeYAxes();
220
+ }
221
+ }
222
+ } else {
223
+ seriesConfig.id = H.uniqueKey();
224
+ navigation.fieldsToOptions(data.fields, seriesConfig);
225
+
226
+ if (indicatorsWithAxes.indexOf(data.type) >= 0) {
227
+ yAxis = chart.addAxis({
228
+ id: H.uniqueKey(),
229
+ offset: 0,
230
+ opposite: true,
231
+ title: {
232
+ text: ''
233
+ },
234
+ tickPixelInterval: 40,
235
+ showLastLabel: false,
236
+ labels: {
237
+ align: 'left',
238
+ y: -2
239
+ }
240
+ }, false, false);
241
+ seriesConfig.yAxis = yAxis.options.id;
242
+ navigation.resizeYAxes();
243
+ }
244
+
245
+ if (indicatorsWithVolume.indexOf(data.type) >= 0) {
246
+ seriesConfig.params.volumeSeriesID = chart.series.filter(
247
+ function (series) {
248
+ return series.options.type === 'column';
249
+ }
250
+ )[0].options.id;
251
+ }
252
+
253
+ chart.addSeries(seriesConfig, false);
254
+ }
255
+
256
+ fireEvent(
257
+ navigation,
258
+ 'deselectButton',
259
+ {
260
+ button: navigation.selectedButtonElement
261
+ }
262
+ );
263
+
264
+ chart.redraw();
265
+ };
266
+
267
+ /**
268
+ * Update height for an annotation. Height is calculated as a difference
269
+ * between last point in `typeOptions` and current position. It's a value,
270
+ * not pixels height.
271
+ *
272
+ * @private
273
+ * @function bindingsUtils.updateHeight
274
+ *
275
+ * @param {global.Event} e
276
+ * normalized browser event
277
+ *
278
+ * @param {Highcharts.Annotation} annotation
279
+ * Annotation to be updated
280
+ */
281
+ bindingsUtils.updateHeight = function (e, annotation) {
282
+ annotation.update({
283
+ typeOptions: {
284
+ height: this.chart.yAxis[0].toValue(e.chartY) -
285
+ annotation.options.typeOptions.points[1].y
286
+ }
287
+ });
288
+ };
289
+
290
+ // @todo
291
+ // Consider using getHoverData(), but always kdTree (columns?)
292
+ bindingsUtils.attractToPoint = function (e, chart) {
293
+ var x = chart.xAxis[0].toValue(e.chartX),
294
+ y = chart.yAxis[0].toValue(e.chartY),
295
+ distX = Number.MAX_VALUE,
296
+ closestPoint;
297
+
298
+ chart.series.forEach(function (series) {
299
+ series.points.forEach(function (point) {
300
+ if (point && distX > Math.abs(point.x - x)) {
301
+ distX = Math.abs(point.x - x);
302
+ closestPoint = point;
303
+ }
304
+ });
305
+ });
306
+
307
+ return {
308
+ x: closestPoint.x,
309
+ y: closestPoint.y,
310
+ below: y < closestPoint.y,
311
+ series: closestPoint.series,
312
+ xAxis: closestPoint.series.xAxis.index || 0,
313
+ yAxis: closestPoint.series.yAxis.index || 0
314
+ };
315
+ };
316
+
317
+ /**
318
+ * Shorthand to check if given yAxis comes from navigator.
319
+ *
320
+ * @private
321
+ * @function bindingsUtils.isNotNavigatorYAxis
322
+ *
323
+ * @param {Highcharts.Axis} axis
324
+ * Axis
325
+ *
326
+ * @return {boolean}
327
+ */
328
+ bindingsUtils.isNotNavigatorYAxis = function (axis) {
329
+ return axis.userOptions.className !== PREFIX + 'navigator-yaxis';
330
+ };
331
+ /**
332
+ * Update each point after specified index, most of the annotations use
333
+ * this. For example crooked line: logic behind updating each point is the
334
+ * same, only index changes when adding an annotation.
335
+ *
336
+ * Example: NavigationBindings.utils.updateNthPoint(1) - will generate
337
+ * function that updates all consecutive points except point with index=0.
338
+ *
339
+ * @private
340
+ * @function bindingsUtils.updateNthPoint
341
+ *
342
+ * @param {number} startIndex
343
+ * Index from each point should udpated
344
+ *
345
+ * @return {Function}
346
+ * Callback to be used in steps array
347
+ */
348
+ bindingsUtils.updateNthPoint = function (startIndex) {
349
+ return function (e, annotation) {
350
+ var options = annotation.options.typeOptions,
351
+ x = this.chart.xAxis[0].toValue(e.chartX),
352
+ y = this.chart.yAxis[0].toValue(e.chartY);
353
+
354
+ options.points.forEach(function (point, index) {
355
+ if (index >= startIndex) {
356
+ point.x = x;
357
+ point.y = y;
358
+ }
359
+ });
360
+
361
+ annotation.update({
362
+ typeOptions: {
363
+ points: options.points
364
+ }
365
+ });
366
+ };
367
+ };
368
+
369
+ // Extends NavigationBindigs to support indicators and resizers:
370
+ extend(H.NavigationBindings.prototype, {
371
+ /**
372
+ * Get current positions for all yAxes. If new axis does not have position,
373
+ * returned is default height and last available top place.
374
+ *
375
+ * @private
376
+ * @function Highcharts.NavigationBindings#getYAxisPositions
377
+ *
378
+ * @param {Array<Highcharts.Axis>} yAxes
379
+ * Array of yAxes available in the chart.
380
+ *
381
+ * @param {number} plotHeight
382
+ * Available height in the chart.
383
+ *
384
+ * @param {number} defaultHeight
385
+ * Default height in percents.
386
+ *
387
+ * @return {Array}
388
+ * An array of calculated positions in percentages.
389
+ * Format: `{top: Number, height: Number}`
390
+ */
391
+ getYAxisPositions: function (yAxes, plotHeight, defaultHeight) {
392
+ var positions,
393
+ allAxesHeight = 0;
394
+
395
+ function isPercentage(prop) {
396
+ return defined(prop) && !isNumber(prop) && prop.match('%');
397
+ }
398
+
399
+ positions = yAxes.map(function (yAxis) {
400
+ var height = isPercentage(yAxis.options.height) ?
401
+ parseFloat(yAxis.options.height) / 100 :
402
+ yAxis.height / plotHeight,
403
+ top = isPercentage(yAxis.options.top) ?
404
+ parseFloat(yAxis.options.top) / 100 :
405
+ correctFloat(
406
+ yAxis.top - yAxis.chart.plotTop
407
+ ) / plotHeight;
408
+
409
+ // New yAxis does not contain "height" info yet
410
+ if (!isNumber(height)) {
411
+ height = defaultHeight / 100;
412
+ }
413
+
414
+ allAxesHeight = correctFloat(allAxesHeight + height);
415
+
416
+ return {
417
+ height: height * 100,
418
+ top: top * 100
419
+ };
420
+ });
421
+
422
+ positions.allAxesHeight = allAxesHeight;
423
+
424
+ return positions;
425
+ },
426
+
427
+ /**
428
+ * Get current resize options for each yAxis. Note that each resize is
429
+ * linked to the next axis, except the last one which shouldn't affect
430
+ * axes in the navigator. Because indicator can be removed with it's yAxis
431
+ * in the middle of yAxis array, we need to bind closest yAxes back.
432
+ *
433
+ * @private
434
+ * @function Highcharts.NavigationBindings#getYAxisResizers
435
+ *
436
+ * @param {Array<Highcharts.Axis>} yAxes
437
+ * Array of yAxes available in the chart
438
+ *
439
+ * @return {Array<object>}
440
+ * An array of resizer options.
441
+ * Format: `{enabled: Boolean, controlledAxis: { next: [String]}}`
442
+ */
443
+ getYAxisResizers: function (yAxes) {
444
+ var resizers = [];
445
+
446
+ yAxes.forEach(function (yAxis, index) {
447
+ var nextYAxis = yAxes[index + 1];
448
+
449
+ // We have next axis, bind them:
450
+ if (nextYAxis) {
451
+ resizers[index] = {
452
+ enabled: true,
453
+ controlledAxis: {
454
+ next: [
455
+ pick(
456
+ nextYAxis.options.id,
457
+ nextYAxis.options.index
458
+ )
459
+ ]
460
+ }
461
+ };
462
+ } else {
463
+ // Remove binding:
464
+ resizers[index] = {
465
+ enabled: false
466
+ };
467
+ }
468
+ });
469
+
470
+ return resizers;
471
+ },
472
+ /**
473
+ * Resize all yAxes (except navigator) to fit the plotting height. Method
474
+ * checks if new axis is added, then shrinks other main axis up to 5 panes.
475
+ * If added is more thatn 5 panes, it rescales all other axes to fit new
476
+ * yAxis.
477
+ *
478
+ * If axis is removed, and we have more than 5 panes, rescales all other
479
+ * axes. If chart has less than 5 panes, first pane receives all extra
480
+ * space.
481
+ *
482
+ * @private
483
+ * @function Highcharts.NavigationBindings#resizeYAxes
484
+ *
485
+ * @param {number} defaultHeight
486
+ * Default height for yAxis
487
+ */
488
+ resizeYAxes: function (defaultHeight) {
489
+ defaultHeight = defaultHeight || 20; // in %, but as a number
490
+ var chart = this.chart,
491
+ // Only non-navigator axes
492
+ yAxes = chart.yAxis.filter(this.utils.isNotNavigatorYAxis),
493
+ plotHeight = chart.plotHeight,
494
+ allAxesLength = yAxes.length,
495
+ // Gather current heights (in %)
496
+ positions = this.getYAxisPositions(
497
+ yAxes,
498
+ plotHeight,
499
+ defaultHeight
500
+ ),
501
+ resizers = this.getYAxisResizers(yAxes),
502
+ allAxesHeight = positions.allAxesHeight,
503
+ changedSpace = defaultHeight;
504
+
505
+ // More than 100%
506
+ if (allAxesHeight > 1) {
507
+ // Simple case, add new panes up to 5
508
+ if (allAxesLength < 6) {
509
+ // Added axis, decrease first pane's height:
510
+ positions[0].height = correctFloat(
511
+ positions[0].height - changedSpace
512
+ );
513
+ // And update all other "top" positions:
514
+ positions = this.recalculateYAxisPositions(
515
+ positions,
516
+ changedSpace
517
+ );
518
+ } else {
519
+ // We have more panes, rescale all others to gain some space,
520
+ // This is new height for upcoming yAxis:
521
+ defaultHeight = 100 / allAxesLength;
522
+ // This is how much we need to take from each other yAxis:
523
+ changedSpace = defaultHeight / (allAxesLength - 1);
524
+
525
+ // Now update all positions:
526
+ positions = this.recalculateYAxisPositions(
527
+ positions,
528
+ changedSpace,
529
+ true,
530
+ -1
531
+ );
532
+ }
533
+ // Set last position manually:
534
+ positions[allAxesLength - 1] = {
535
+ top: correctFloat(100 - defaultHeight),
536
+ height: defaultHeight
537
+ };
538
+
539
+ } else {
540
+ // Less than 100%
541
+ changedSpace = correctFloat(1 - allAxesHeight) * 100;
542
+ // Simple case, return first pane it's space:
543
+ if (allAxesLength < 5) {
544
+ positions[0].height = correctFloat(
545
+ positions[0].height + changedSpace
546
+ );
547
+
548
+ positions = this.recalculateYAxisPositions(
549
+ positions,
550
+ changedSpace
551
+ );
552
+ } else {
553
+ // There were more panes, return to each pane a bit of space:
554
+ changedSpace /= allAxesLength;
555
+ // Removed axis, add extra space to the first pane:
556
+ // And update all other positions:
557
+ positions = this.recalculateYAxisPositions(
558
+ positions,
559
+ changedSpace,
560
+ true,
561
+ 1
562
+ );
563
+ }
564
+ }
565
+
566
+ positions.forEach(function (position, index) {
567
+ // if (index === 0) debugger;
568
+ yAxes[index].update({
569
+ height: position.height + '%',
570
+ top: position.top + '%',
571
+ resize: resizers[index]
572
+ }, false);
573
+ });
574
+ },
575
+ /**
576
+ * Utility to modify calculated positions according to the remaining/needed
577
+ * space. Later, these positions are used in `yAxis.update({ top, height })`
578
+ *
579
+ * @private
580
+ * @function Highcharts.NavigationBindings#recalculateYAxisPositions
581
+ *
582
+ * @param {Array<object>} positions
583
+ * Default positions of all yAxes.
584
+ *
585
+ * @param {number} changedSpace
586
+ * How much space should be added or removed.
587
+ * @param {number} adder
588
+ * `-1` or `1`, to determine whether we should add or remove space.
589
+ *
590
+ * @param {boolean} modifyHeight
591
+ * Update only `top` or both `top` and `height`.
592
+ *
593
+ * @return {Array<object>}
594
+ * Modified positions,
595
+ */
596
+ recalculateYAxisPositions: function (
597
+ positions,
598
+ changedSpace,
599
+ modifyHeight,
600
+ adder
601
+ ) {
602
+ positions.forEach(function (position, index) {
603
+ var prevPosition = positions[index - 1];
604
+
605
+ position.top = !prevPosition ? 0 :
606
+ correctFloat(prevPosition.height + prevPosition.top);
607
+
608
+ if (modifyHeight) {
609
+ position.height = correctFloat(
610
+ position.height + adder * changedSpace
611
+ );
612
+ }
613
+ });
614
+
615
+ return positions;
616
+ }
617
+ });
618
+
619
+ /**
620
+ * @type {Highcharts.Dictionary<Highcharts.StockToolsBindingsObject>|*}
621
+ * @since 7.0.0
622
+ * @optionparent navigation.bindings
623
+ */
624
+ var stockToolsBindings = {
625
+ // Line type annotations:
626
+ /**
627
+ * A segment annotation bindings. Includes `start` and one event in `steps`
628
+ * array.
629
+ *
630
+ * @type {Highcharts.StockToolsBindingsObject}
631
+ * @product highstock
632
+ * @default {"className": "highcharts-segment", "start": function() {}, "steps": [function() {}]}
633
+ */
634
+ segment: {
635
+ /** @ignore */
636
+ className: 'highcharts-segment',
637
+ /** @ignore */
638
+ start: function (e) {
639
+ var x = this.chart.xAxis[0].toValue(e.chartX),
640
+ y = this.chart.yAxis[0].toValue(e.chartY);
641
+
642
+ return this.chart.addAnnotation({
643
+ langKey: 'segment',
644
+ type: 'crookedLine',
645
+ typeOptions: {
646
+ points: [{
647
+ x: x,
648
+ y: y
649
+ }, {
650
+ x: x,
651
+ y: y
652
+ }]
653
+ }
654
+ });
655
+ },
656
+ /** @ignore */
657
+ steps: [
658
+ bindingsUtils.updateNthPoint(1)
659
+ ]
660
+ },
661
+ /**
662
+ * A segment with an arrow annotation bindings. Includes `start` and one
663
+ * event in `steps` array.
664
+ *
665
+ * @type {Highcharts.StockToolsBindingsObject}
666
+ * @product highstock
667
+ * @default {"className": "highcharts-arrow-segment", "start": function() {}, "steps": [function() {}]}
668
+ */
669
+ arrowSegment: {
670
+ /** @ignore */
671
+ className: 'highcharts-arrow-segment',
672
+ /** @ignore */
673
+ start: function (e) {
674
+ var x = this.chart.xAxis[0].toValue(e.chartX),
675
+ y = this.chart.yAxis[0].toValue(e.chartY);
676
+
677
+ return this.chart.addAnnotation({
678
+ langKey: 'arrowSegment',
679
+ type: 'crookedLine',
680
+ typeOptions: {
681
+ line: {
682
+ markerEnd: 'arrow'
683
+ },
684
+ points: [{
685
+ x: x,
686
+ y: y
687
+ }, {
688
+ x: x,
689
+ y: y
690
+ }]
691
+ }
692
+ });
693
+ },
694
+ /** @ignore */
695
+ steps: [
696
+ bindingsUtils.updateNthPoint(1)
697
+ ]
698
+ },
699
+ /**
700
+ * A ray annotation bindings. Includes `start` and one event in `steps`
701
+ * array.
702
+ *
703
+ * @type {Highcharts.StockToolsBindingsObject}
704
+ * @product highstock
705
+ * @default {"className": "highcharts-ray", "start": function() {}, "steps": [function() {}]}
706
+ */
707
+ ray: {
708
+ /** @ignore */
709
+ className: 'highcharts-ray',
710
+ /** @ignore */
711
+ start: function (e) {
712
+ var x = this.chart.xAxis[0].toValue(e.chartX),
713
+ y = this.chart.yAxis[0].toValue(e.chartY);
714
+
715
+ return this.chart.addAnnotation({
716
+ langKey: 'ray',
717
+ type: 'infinityLine',
718
+ typeOptions: {
719
+ type: 'ray',
720
+ points: [{
721
+ x: x,
722
+ y: y
723
+ }, {
724
+ x: x,
725
+ y: y
726
+ }]
727
+ }
728
+ });
729
+ },
730
+ /** @ignore */
731
+ steps: [
732
+ bindingsUtils.updateNthPoint(1)
733
+ ]
734
+ },
735
+ /**
736
+ * A ray with an arrow annotation bindings. Includes `start` and one event
737
+ * in `steps` array.
738
+ *
739
+ * @type {Highcharts.StockToolsBindingsObject}
740
+ * @product highstock
741
+ * @default {"className": "highcharts-arrow-ray", "start": function() {}, "steps": [function() {}]}
742
+ */
743
+ arrowRay: {
744
+ /** @ignore */
745
+ className: 'highcharts-arrow-ray',
746
+ /** @ignore */
747
+ start: function (e) {
748
+ var x = this.chart.xAxis[0].toValue(e.chartX),
749
+ y = this.chart.yAxis[0].toValue(e.chartY);
750
+
751
+ return this.chart.addAnnotation({
752
+ langKey: 'arrowRay',
753
+ type: 'infinityLine',
754
+ typeOptions: {
755
+ type: 'ray',
756
+ line: {
757
+ markerEnd: 'arrow'
758
+ },
759
+ points: [{
760
+ x: x,
761
+ y: y
762
+ }, {
763
+ x: x,
764
+ y: y
765
+ }]
766
+ }
767
+ });
768
+ },
769
+ /** @ignore */
770
+ steps: [
771
+ bindingsUtils.updateNthPoint(1)
772
+ ]
773
+ },
774
+ /**
775
+ * A line annotation. Includes `start` and one event in `steps` array.
776
+ *
777
+ * @type {Highcharts.StockToolsBindingsObject}
778
+ * @product highstock
779
+ * @default {"className": "highcharts-infinity-line", "start": function() {}, "steps": [function() {}]}
780
+ */
781
+ infinityLine: {
782
+ /** @ignore */
783
+ className: 'highcharts-infinity-line',
784
+ /** @ignore */
785
+ start: function (e) {
786
+ var x = this.chart.xAxis[0].toValue(e.chartX),
787
+ y = this.chart.yAxis[0].toValue(e.chartY);
788
+
789
+ return this.chart.addAnnotation({
790
+ langKey: 'infinityLine',
791
+ type: 'infinityLine',
792
+ typeOptions: {
793
+ type: 'line',
794
+ points: [{
795
+ x: x,
796
+ y: y
797
+ }, {
798
+ x: x,
799
+ y: y
800
+ }]
801
+ }
802
+ });
803
+ },
804
+ /** @ignore */
805
+ steps: [
806
+ bindingsUtils.updateNthPoint(1)
807
+ ]
808
+ },
809
+ /**
810
+ * A line with arrow annotation. Includes `start` and one event in `steps`
811
+ * array.
812
+ *
813
+ * @type {Highcharts.StockToolsBindingsObject}
814
+ * @product highstock
815
+ * @default {"className": "highcharts-arrow-infinity-line", "start": function() {}, "steps": [function() {}]}
816
+ */
817
+ arrowInfinityLine: {
818
+ /** @ignore */
819
+ className: 'highcharts-arrow-infinity-line',
820
+ /** @ignore */
821
+ start: function (e) {
822
+ var x = this.chart.xAxis[0].toValue(e.chartX),
823
+ y = this.chart.yAxis[0].toValue(e.chartY);
824
+
825
+ return this.chart.addAnnotation({
826
+ langKey: 'arrowInfinityLine',
827
+ type: 'infinityLine',
828
+ typeOptions: {
829
+ type: 'line',
830
+ line: {
831
+ markerEnd: 'arrow'
832
+ },
833
+ points: [{
834
+ x: x,
835
+ y: y
836
+ }, {
837
+ x: x,
838
+ y: y
839
+ }]
840
+ }
841
+ });
842
+ },
843
+ /** @ignore */
844
+ steps: [
845
+ bindingsUtils.updateNthPoint(1)
846
+ ]
847
+ },
848
+ /**
849
+ * A horizontal line annotation. Includes `start` event.
850
+ *
851
+ * @type {Highcharts.StockToolsBindingsObject}
852
+ * @product highstock
853
+ * @default {"className": "highcharts-horizontal-line", "start": function() {}}
854
+ */
855
+ horizontalLine: {
856
+ /** @ignore */
857
+ className: 'highcharts-horizontal-line',
858
+ /** @ignore */
859
+ start: function (e) {
860
+ var x = this.chart.xAxis[0].toValue(e.chartX),
861
+ y = this.chart.yAxis[0].toValue(e.chartY);
862
+
863
+ this.chart.addAnnotation({
864
+ langKey: 'horizontalLine',
865
+ type: 'infinityLine',
866
+ typeOptions: {
867
+ type: 'horizontalLine',
868
+ points: [{
869
+ x: x,
870
+ y: y
871
+ }]
872
+ }
873
+ });
874
+ }
875
+ },
876
+ /**
877
+ * A vertical line annotation. Includes `start` event.
878
+ *
879
+ * @type {Highcharts.StockToolsBindingsObject}
880
+ * @product highstock
881
+ * @default {"className": "highcharts-vertical-line", "start": function() {}}
882
+ */
883
+ verticalLine: {
884
+ /** @ignore */
885
+ className: 'highcharts-vertical-line',
886
+ /** @ignore */
887
+ start: function (e) {
888
+ var x = this.chart.xAxis[0].toValue(e.chartX),
889
+ y = this.chart.yAxis[0].toValue(e.chartY);
890
+
891
+ this.chart.addAnnotation({
892
+ langKey: 'verticalLine',
893
+ type: 'infinityLine',
894
+ typeOptions: {
895
+ type: 'verticalLine',
896
+ points: [{
897
+ x: x,
898
+ y: y
899
+ }]
900
+ }
901
+ });
902
+ }
903
+ },
904
+ /**
905
+ * Crooked line (three points) annotation bindings. Includes `start` and two
906
+ * events in `steps` (for second and third points in crooked line) array.
907
+ *
908
+ * @type {Highcharts.StockToolsBindingsObject}
909
+ * @product highstock
910
+ * @default {"className": "highcharts-crooked3", "start": function() {}, "steps": [function() {}, function() {}]}
911
+ */
912
+ // Crooked Line type annotations:
913
+ crooked3: {
914
+ /** @ignore */
915
+ className: 'highcharts-crooked3',
916
+ /** @ignore */
917
+ start: function (e) {
918
+ var x = this.chart.xAxis[0].toValue(e.chartX),
919
+ y = this.chart.yAxis[0].toValue(e.chartY);
920
+
921
+ return this.chart.addAnnotation({
922
+ langKey: 'crooked3',
923
+ type: 'crookedLine',
924
+ typeOptions: {
925
+ points: [{
926
+ x: x,
927
+ y: y
928
+ }, {
929
+ x: x,
930
+ y: y
931
+ }, {
932
+ x: x,
933
+ y: y
934
+ }]
935
+ }
936
+ });
937
+ },
938
+ /** @ignore */
939
+ steps: [
940
+ bindingsUtils.updateNthPoint(1),
941
+ bindingsUtils.updateNthPoint(2)
942
+ ]
943
+ },
944
+ /**
945
+ * Crooked line (five points) annotation bindings. Includes `start` and four
946
+ * events in `steps` (for all consequent points in crooked line) array.
947
+ *
948
+ * @type {Highcharts.StockToolsBindingsObject}
949
+ * @product highstock
950
+ * @default {"className": "highcharts-crooked3", "start": function() {}, "steps": [function() {}, function() {}, function() {}, function() {}]}
951
+ */
952
+ crooked5: {
953
+ /** @ignore */
954
+ className: 'highcharts-crooked5',
955
+ /** @ignore */
956
+ start: function (e) {
957
+ var x = this.chart.xAxis[0].toValue(e.chartX),
958
+ y = this.chart.yAxis[0].toValue(e.chartY);
959
+
960
+ return this.chart.addAnnotation({
961
+ langKey: 'crookedLine',
962
+ type: 'crookedLine',
963
+ typeOptions: {
964
+ points: [{
965
+ x: x,
966
+ y: y
967
+ }, {
968
+ x: x,
969
+ y: y
970
+ }, {
971
+ x: x,
972
+ y: y
973
+ }, {
974
+ x: x,
975
+ y: y
976
+ }, {
977
+ x: x,
978
+ y: y
979
+ }]
980
+ }
981
+ });
982
+ },
983
+ /** @ignore */
984
+ steps: [
985
+ bindingsUtils.updateNthPoint(1),
986
+ bindingsUtils.updateNthPoint(2),
987
+ bindingsUtils.updateNthPoint(3),
988
+ bindingsUtils.updateNthPoint(4)
989
+ ]
990
+ },
991
+ /**
992
+ * Elliott wave (three points) annotation bindings. Includes `start` and two
993
+ * events in `steps` (for second and third points) array.
994
+ *
995
+ * @type {Highcharts.StockToolsBindingsObject}
996
+ * @product highstock
997
+ * @default {"className": "highcharts-elliott3", "start": function() {}, "steps": [function() {}, function() {}]}
998
+ */
999
+ elliott3: {
1000
+ /** @ignore */
1001
+ className: 'highcharts-elliott3',
1002
+ /** @ignore */
1003
+ start: function (e) {
1004
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1005
+ y = this.chart.yAxis[0].toValue(e.chartY);
1006
+
1007
+ return this.chart.addAnnotation({
1008
+ langKey: 'elliott3',
1009
+ type: 'elliottWave',
1010
+ typeOptions: {
1011
+ points: [{
1012
+ x: x,
1013
+ y: y
1014
+ }, {
1015
+ x: x,
1016
+ y: y
1017
+ }, {
1018
+ x: x,
1019
+ y: y
1020
+ }]
1021
+ },
1022
+ labelOptions: {
1023
+ style: {
1024
+ color: '#666666'
1025
+ }
1026
+ }
1027
+ });
1028
+ },
1029
+ /** @ignore */
1030
+ steps: [
1031
+ bindingsUtils.updateNthPoint(1),
1032
+ bindingsUtils.updateNthPoint(2)
1033
+ ]
1034
+ },
1035
+ /**
1036
+ * Elliott wave (five points) annotation bindings. Includes `start` and four
1037
+ * event in `steps` (for all consequent points in Elliott wave) array.
1038
+ *
1039
+ * @type {Highcharts.StockToolsBindingsObject}
1040
+ * @product highstock
1041
+ * @default {"className": "highcharts-elliott3", "start": function() {}, "steps": [function() {}, function() {}, function() {}, function() {}]}
1042
+ */
1043
+ elliott5: {
1044
+ /** @ignore */
1045
+ className: 'highcharts-elliott5',
1046
+ /** @ignore */
1047
+ start: function (e) {
1048
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1049
+ y = this.chart.yAxis[0].toValue(e.chartY);
1050
+
1051
+ return this.chart.addAnnotation({
1052
+ langKey: 'elliott5',
1053
+ type: 'elliottWave',
1054
+ typeOptions: {
1055
+ points: [{
1056
+ x: x,
1057
+ y: y
1058
+ }, {
1059
+ x: x,
1060
+ y: y
1061
+ }, {
1062
+ x: x,
1063
+ y: y
1064
+ }, {
1065
+ x: x,
1066
+ y: y
1067
+ }, {
1068
+ x: x,
1069
+ y: y
1070
+ }]
1071
+ },
1072
+ labelOptions: {
1073
+ style: {
1074
+ color: '#666666'
1075
+ }
1076
+ }
1077
+ });
1078
+ },
1079
+ /** @ignore */
1080
+ steps: [
1081
+ bindingsUtils.updateNthPoint(1),
1082
+ bindingsUtils.updateNthPoint(2),
1083
+ bindingsUtils.updateNthPoint(3),
1084
+ bindingsUtils.updateNthPoint(4)
1085
+ ]
1086
+ },
1087
+ /**
1088
+ * A measure (x-dimension) annotation bindings. Includes `start` and one
1089
+ * event in `steps` array.
1090
+ *
1091
+ * @type {Highcharts.StockToolsBindingsObject}
1092
+ * @product highstock
1093
+ * @default {"className": "highcharts-measure-x", "start": function() {}, "steps": [function() {}]}
1094
+ */
1095
+ measureX: {
1096
+ /** @ignore */
1097
+ className: 'highcharts-measure-x',
1098
+ /** @ignore */
1099
+ start: function (e) {
1100
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1101
+ y = this.chart.yAxis[0].toValue(e.chartY),
1102
+ options = {
1103
+ langKey: 'measure',
1104
+ type: 'measure',
1105
+ typeOptions: {
1106
+ selectType: 'x',
1107
+ point: {
1108
+ x: x,
1109
+ y: y,
1110
+ xAxis: 0,
1111
+ yAxis: 0
1112
+ },
1113
+ crosshairX: {
1114
+ strokeWidth: 1,
1115
+ stroke: '#000000'
1116
+ },
1117
+ crosshairY: {
1118
+ enabled: false,
1119
+ strokeWidth: 0,
1120
+ stroke: '#000000'
1121
+ },
1122
+ background: {
1123
+ width: 0,
1124
+ height: 0,
1125
+ strokeWidth: 0,
1126
+ stroke: '#ffffff'
1127
+ }
1128
+ },
1129
+ labelOptions: {
1130
+ style: {
1131
+ color: '#666666'
1132
+ }
1133
+ }
1134
+ };
1135
+
1136
+ return this.chart.addAnnotation(options);
1137
+ },
1138
+ /** @ignore */
1139
+ steps: [
1140
+ bindingsUtils.updateRectSize
1141
+ ]
1142
+ },
1143
+ /**
1144
+ * A measure (y-dimension) annotation bindings. Includes `start` and one
1145
+ * event in `steps` array.
1146
+ *
1147
+ * @type {Highcharts.StockToolsBindingsObject}
1148
+ * @product highstock
1149
+ * @default {"className": "highcharts-measure-y", "start": function() {}, "steps": [function() {}]}
1150
+ */
1151
+ measureY: {
1152
+ /** @ignore */
1153
+ className: 'highcharts-measure-y',
1154
+ /** @ignore */
1155
+ start: function (e) {
1156
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1157
+ y = this.chart.yAxis[0].toValue(e.chartY),
1158
+ options = {
1159
+ langKey: 'measure',
1160
+ type: 'measure',
1161
+ typeOptions: {
1162
+ selectType: 'y',
1163
+ point: {
1164
+ x: x,
1165
+ y: y,
1166
+ xAxis: 0,
1167
+ yAxis: 0
1168
+ },
1169
+ crosshairX: {
1170
+ enabled: false,
1171
+ strokeWidth: 0,
1172
+ stroke: '#000000'
1173
+ },
1174
+ crosshairY: {
1175
+ strokeWidth: 1,
1176
+ stroke: '#000000'
1177
+ },
1178
+ background: {
1179
+ width: 0,
1180
+ height: 0,
1181
+ strokeWidth: 0,
1182
+ stroke: '#ffffff'
1183
+ }
1184
+ },
1185
+ labelOptions: {
1186
+ style: {
1187
+ color: '#666666'
1188
+ }
1189
+ }
1190
+ };
1191
+
1192
+ return this.chart.addAnnotation(options);
1193
+ },
1194
+ /** @ignore */
1195
+ steps: [
1196
+ bindingsUtils.updateRectSize
1197
+ ]
1198
+ },
1199
+ /**
1200
+ * A measure (xy-dimension) annotation bindings. Includes `start` and one
1201
+ * event in `steps` array.
1202
+ *
1203
+ * @type {Highcharts.StockToolsBindingsObject}
1204
+ * @product highstock
1205
+ * @default {"className": "highcharts-measure-xy", "start": function() {}, "steps": [function() {}]}
1206
+ */
1207
+ measureXY: {
1208
+ /** @ignore */
1209
+ className: 'highcharts-measure-xy',
1210
+ /** @ignore */
1211
+ start: function (e) {
1212
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1213
+ y = this.chart.yAxis[0].toValue(e.chartY),
1214
+ options = {
1215
+ langKey: 'measure',
1216
+ type: 'measure',
1217
+ typeOptions: {
1218
+ selectType: 'xy',
1219
+ point: {
1220
+ x: x,
1221
+ y: y,
1222
+ xAxis: 0,
1223
+ yAxis: 0
1224
+ },
1225
+ background: {
1226
+ width: 0,
1227
+ height: 0,
1228
+ strokeWidth: 0,
1229
+ stroke: '#000000'
1230
+ },
1231
+ crosshairX: {
1232
+ strokeWidth: 1,
1233
+ stroke: '#000000'
1234
+ },
1235
+ crosshairY: {
1236
+ strokeWidth: 1,
1237
+ stroke: '#000000'
1238
+ }
1239
+ },
1240
+ labelOptions: {
1241
+ style: {
1242
+ color: '#666666'
1243
+ }
1244
+ }
1245
+ };
1246
+
1247
+ return this.chart.addAnnotation(options);
1248
+ },
1249
+ /** @ignore */
1250
+ steps: [
1251
+ bindingsUtils.updateRectSize
1252
+ ]
1253
+ },
1254
+ // Advanced type annotations:
1255
+ /**
1256
+ * A fibonacci annotation bindings. Includes `start` and two events in
1257
+ * `steps` array (updates second point, then height).
1258
+ *
1259
+ * @type {Highcharts.StockToolsBindingsObject}
1260
+ * @product highstock
1261
+ * @default {"className": "highcharts-fibonacci", "start": function() {}, "steps": [function() {}, function() {}]}
1262
+ */
1263
+ fibonacci: {
1264
+ /** @ignore */
1265
+ className: 'highcharts-fibonacci',
1266
+ /** @ignore */
1267
+ start: function (e) {
1268
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1269
+ y = this.chart.yAxis[0].toValue(e.chartY);
1270
+
1271
+ return this.chart.addAnnotation({
1272
+ langKey: 'fibonacci',
1273
+ type: 'fibonacci',
1274
+ typeOptions: {
1275
+ points: [{
1276
+ x: x,
1277
+ y: y
1278
+ }, {
1279
+ x: x,
1280
+ y: y
1281
+ }]
1282
+ },
1283
+ labelOptions: {
1284
+ style: {
1285
+ color: '#666666'
1286
+ }
1287
+ }
1288
+ });
1289
+ },
1290
+ /** @ignore */
1291
+ steps: [
1292
+ bindingsUtils.updateNthPoint(1),
1293
+ bindingsUtils.updateHeight
1294
+ ]
1295
+ },
1296
+ /**
1297
+ * A parallel channel (tunnel) annotation bindings. Includes `start` and
1298
+ * two events in `steps` array (updates second point, then height).
1299
+ *
1300
+ * @type {Highcharts.StockToolsBindingsObject}
1301
+ * @product highstock
1302
+ * @default {"className": "highcharts-parallel-channel", "start": function() {}, "steps": [function() {}, function() {}]}
1303
+ */
1304
+ parallelChannel: {
1305
+ /** @ignore */
1306
+ className: 'highcharts-parallel-channel',
1307
+ /** @ignore */
1308
+ start: function (e) {
1309
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1310
+ y = this.chart.yAxis[0].toValue(e.chartY);
1311
+
1312
+ return this.chart.addAnnotation({
1313
+ langKey: 'parallelChannel',
1314
+ type: 'tunnel',
1315
+ typeOptions: {
1316
+ points: [{
1317
+ x: x,
1318
+ y: y
1319
+ }, {
1320
+ x: x,
1321
+ y: y
1322
+ }]
1323
+ }
1324
+ });
1325
+ },
1326
+ /** @ignore */
1327
+ steps: [
1328
+ bindingsUtils.updateNthPoint(1),
1329
+ bindingsUtils.updateHeight
1330
+ ]
1331
+ },
1332
+ /**
1333
+ * An Andrew's pitchfork annotation bindings. Includes `start` and two
1334
+ * events in `steps` array (sets second and third control points).
1335
+ *
1336
+ * @type {Highcharts.StockToolsBindingsObject}
1337
+ * @product highstock
1338
+ * @default {"className": "highcharts-pitchfork", "start": function() {}, "steps": [function() {}, function() {}]}
1339
+ */
1340
+ pitchfork: {
1341
+ /** @ignore */
1342
+ className: 'highcharts-pitchfork',
1343
+ /** @ignore */
1344
+ start: function (e) {
1345
+ var x = this.chart.xAxis[0].toValue(e.chartX),
1346
+ y = this.chart.yAxis[0].toValue(e.chartY);
1347
+
1348
+ return this.chart.addAnnotation({
1349
+ langKey: 'pitchfork',
1350
+ type: 'pitchfork',
1351
+ typeOptions: {
1352
+ points: [{
1353
+ x: x,
1354
+ y: y,
1355
+ controlPoint: {
1356
+ style: {
1357
+ fill: 'red'
1358
+ }
1359
+ }
1360
+ }, {
1361
+ x: x,
1362
+ y: y
1363
+ }, {
1364
+ x: x,
1365
+ y: y
1366
+ }],
1367
+ innerBackground: {
1368
+ fill: 'rgba(100, 170, 255, 0.8)'
1369
+ }
1370
+ },
1371
+ shapeOptions: {
1372
+ strokeWidth: 2
1373
+ }
1374
+ });
1375
+ },
1376
+ /** @ignore */
1377
+ steps: [
1378
+ bindingsUtils.updateNthPoint(1),
1379
+ bindingsUtils.updateNthPoint(2)
1380
+ ]
1381
+ },
1382
+ // Labels with arrow and auto increments
1383
+ /**
1384
+ * A vertical counter annotation bindings. Includes `start` event. On click,
1385
+ * finds the closest point and marks it with a numeric annotation -
1386
+ * incrementing counter on each add.
1387
+ *
1388
+ * @type {Highcharts.StockToolsBindingsObject}
1389
+ * @product highstock
1390
+ * @default {"className": "highcharts-vertical-counter", "start": function() {}}
1391
+ */
1392
+ verticalCounter: {
1393
+ /** @ignore */
1394
+ className: 'highcharts-vertical-counter',
1395
+ /** @ignore */
1396
+ start: function (e) {
1397
+ var closestPoint = bindingsUtils.attractToPoint(e, this.chart),
1398
+ annotation;
1399
+
1400
+ if (!defined(this.verticalCounter)) {
1401
+ this.verticalCounter = 0;
1402
+ }
1403
+
1404
+ annotation = this.chart.addAnnotation({
1405
+ langKey: 'verticalCounter',
1406
+ type: 'verticalLine',
1407
+ typeOptions: {
1408
+ point: {
1409
+ x: closestPoint.x,
1410
+ y: closestPoint.y,
1411
+ xAxis: closestPoint.xAxis,
1412
+ yAxis: closestPoint.yAxis
1413
+ },
1414
+ label: {
1415
+ offset: closestPoint.below ? 40 : -40,
1416
+ text: this.verticalCounter.toString()
1417
+ }
1418
+ },
1419
+ labelOptions: {
1420
+ style: {
1421
+ color: '#666666',
1422
+ fontSize: '11px'
1423
+ }
1424
+ },
1425
+ shapeOptions: {
1426
+ stroke: 'rgba(0, 0, 0, 0.75)',
1427
+ strokeWidth: 1
1428
+ }
1429
+ });
1430
+
1431
+ this.verticalCounter++;
1432
+
1433
+ annotation.options.events.click.call(annotation, {});
1434
+ }
1435
+ },
1436
+ /**
1437
+ * A vertical arrow annotation bindings. Includes `start` event. On click,
1438
+ * finds the closest point and marks it with an arrow and a label with
1439
+ * value.
1440
+ *
1441
+ * @type {Highcharts.StockToolsBindingsObject}
1442
+ * @product highstock
1443
+ * @default {"className": "highcharts-vertical-label", "start": function() {}}
1444
+ */
1445
+ verticalLabel: {
1446
+ /** @ignore */
1447
+ className: 'highcharts-vertical-label',
1448
+ /** @ignore */
1449
+ start: function (e) {
1450
+ var closestPoint = bindingsUtils.attractToPoint(e, this.chart),
1451
+ annotation;
1452
+
1453
+ annotation = this.chart.addAnnotation({
1454
+ langKey: 'verticalLabel',
1455
+ type: 'verticalLine',
1456
+ typeOptions: {
1457
+ point: {
1458
+ x: closestPoint.x,
1459
+ y: closestPoint.y,
1460
+ xAxis: closestPoint.xAxis,
1461
+ yAxis: closestPoint.yAxis
1462
+ },
1463
+ label: {
1464
+ offset: closestPoint.below ? 40 : -40
1465
+ }
1466
+ },
1467
+ labelOptions: {
1468
+ style: {
1469
+ color: '#666666',
1470
+ fontSize: '11px'
1471
+ }
1472
+ },
1473
+ shapeOptions: {
1474
+ stroke: 'rgba(0, 0, 0, 0.75)',
1475
+ strokeWidth: 1
1476
+ }
1477
+ });
1478
+
1479
+ annotation.options.events.click.call(annotation, {});
1480
+ }
1481
+ },
1482
+ /**
1483
+ * A vertical arrow annotation bindings. Includes `start` event. On click,
1484
+ * finds the closest point and marks it with an arrow. Green arrow when
1485
+ * pointing from above, red when pointing from below the point.
1486
+ *
1487
+ * @type {Highcharts.StockToolsBindingsObject}
1488
+ * @product highstock
1489
+ * @default {"className": "highcharts-vertical-arrow", "start": function() {}}
1490
+ */
1491
+ verticalArrow: {
1492
+ /** @ignore */
1493
+ className: 'highcharts-vertical-arrow',
1494
+ /** @ignore */
1495
+ start: function (e) {
1496
+ var closestPoint = bindingsUtils.attractToPoint(e, this.chart),
1497
+ annotation;
1498
+
1499
+ annotation = this.chart.addAnnotation({
1500
+ langKey: 'verticalArrow',
1501
+ type: 'verticalLine',
1502
+ typeOptions: {
1503
+ point: {
1504
+ x: closestPoint.x,
1505
+ y: closestPoint.y,
1506
+ xAxis: closestPoint.xAxis,
1507
+ yAxis: closestPoint.yAxis
1508
+ },
1509
+ label: {
1510
+ offset: closestPoint.below ? 40 : -40,
1511
+ format: ' '
1512
+ },
1513
+ connector: {
1514
+ fill: 'none',
1515
+ stroke: closestPoint.below ? 'red' : 'green'
1516
+ }
1517
+ },
1518
+ shapeOptions: {
1519
+ stroke: 'rgba(0, 0, 0, 0.75)',
1520
+ strokeWidth: 1
1521
+ }
1522
+ });
1523
+
1524
+ annotation.options.events.click.call(annotation, {});
1525
+ }
1526
+ },
1527
+ // Flag types:
1528
+ /**
1529
+ * A flag series bindings. Includes `start` event. On click, finds the
1530
+ * closest point and marks it with a flag with `'circlepin'` shape.
1531
+ *
1532
+ * @type {Highcharts.StockToolsBindingsObject}
1533
+ * @product highstock
1534
+ * @default {"className": "highcharts-flag-circlepin", "start": function() {}}
1535
+ */
1536
+ flagCirclepin: {
1537
+ /** @ignore */
1538
+ className: 'highcharts-flag-circlepin',
1539
+ /** @ignore */
1540
+ start: bindingsUtils
1541
+ .addFlagFromForm('circlepin')
1542
+ },
1543
+ /**
1544
+ * A flag series bindings. Includes `start` event. On click, finds the
1545
+ * closest point and marks it with a flag with `'diamondpin'` shape.
1546
+ *
1547
+ * @type {Highcharts.StockToolsBindingsObject}
1548
+ * @product highstock
1549
+ * @default {"className": "highcharts-flag-diamondpin", "start": function() {}}
1550
+ */
1551
+ flagDiamondpin: {
1552
+ /** @ignore */
1553
+ className: 'highcharts-flag-diamondpin',
1554
+ /** @ignore */
1555
+ start: bindingsUtils
1556
+ .addFlagFromForm('flag')
1557
+ },
1558
+ /**
1559
+ * A flag series bindings. Includes `start` event.
1560
+ * On click, finds the closest point and marks it with a flag with
1561
+ * `'squarepin'` shape.
1562
+ *
1563
+ * @type {Highcharts.StockToolsBindingsObject}
1564
+ * @product highstock
1565
+ * @default {"className": "highcharts-flag-squarepin", "start": function() {}}
1566
+ */
1567
+ flagSquarepin: {
1568
+ /** @ignore */
1569
+ className: 'highcharts-flag-squarepin',
1570
+ /** @ignore */
1571
+ start: bindingsUtils
1572
+ .addFlagFromForm('squarepin')
1573
+ },
1574
+ /**
1575
+ * A flag series bindings. Includes `start` event.
1576
+ * On click, finds the closest point and marks it with a flag without pin
1577
+ * shape.
1578
+ *
1579
+ * @type {Highcharts.StockToolsBindingsObject}
1580
+ * @product highstock
1581
+ * @default {"className": "highcharts-flag-simplepin", "start": function() {}}
1582
+ */
1583
+ flagSimplepin: {
1584
+ /** @ignore */
1585
+ className: 'highcharts-flag-simplepin',
1586
+ /** @ignore */
1587
+ start: bindingsUtils
1588
+ .addFlagFromForm('nopin')
1589
+ },
1590
+ // Other tools:
1591
+ /**
1592
+ * Enables zooming in xAxis on a chart. Includes `start` event which
1593
+ * changes [chart.zoomType](#chart.zoomType).
1594
+ *
1595
+ * @type {Highcharts.StockToolsBindingsObject}
1596
+ * @product highstock
1597
+ * @default {"className": "highcharts-zoom-x", "init": function() {}}
1598
+ */
1599
+ zoomX: {
1600
+ /** @ignore */
1601
+ className: 'highcharts-zoom-x',
1602
+ /** @ignore */
1603
+ init: function (button) {
1604
+ this.chart.update({
1605
+ chart: {
1606
+ zoomType: 'x'
1607
+ }
1608
+ });
1609
+
1610
+ fireEvent(
1611
+ this,
1612
+ 'deselectButton',
1613
+ { button: button }
1614
+ );
1615
+ }
1616
+ },
1617
+ /**
1618
+ * Enables zooming in yAxis on a chart. Includes `start` event which
1619
+ * changes [chart.zoomType](#chart.zoomType).
1620
+ *
1621
+ * @type {Highcharts.StockToolsBindingsObject}
1622
+ * @product highstock
1623
+ * @default {"className": "highcharts-zoom-y", "init": function() {}}
1624
+ */
1625
+ zoomY: {
1626
+ /** @ignore */
1627
+ className: 'highcharts-zoom-y',
1628
+ /** @ignore */
1629
+ init: function (button) {
1630
+ this.chart.update({
1631
+ chart: {
1632
+ zoomType: 'y'
1633
+ }
1634
+ });
1635
+ fireEvent(
1636
+ this,
1637
+ 'deselectButton',
1638
+ { button: button }
1639
+ );
1640
+ }
1641
+ },
1642
+ /**
1643
+ * Enables zooming in xAxis and yAxis on a chart. Includes `start` event
1644
+ * which changes [chart.zoomType](#chart.zoomType).
1645
+ *
1646
+ * @type {Highcharts.StockToolsBindingsObject}
1647
+ * @product highstock
1648
+ * @default {"className": "highcharts-zoom-xy", "init": function() {}}
1649
+ */
1650
+ zoomXY: {
1651
+ /** @ignore */
1652
+ className: 'highcharts-zoom-xy',
1653
+ /** @ignore */
1654
+ init: function (button) {
1655
+ this.chart.update({
1656
+ chart: {
1657
+ zoomType: 'xy'
1658
+ }
1659
+ });
1660
+
1661
+ fireEvent(
1662
+ this,
1663
+ 'deselectButton',
1664
+ { button: button }
1665
+ );
1666
+ }
1667
+ },
1668
+ /**
1669
+ * Changes main series to `'line'` type.
1670
+ *
1671
+ * @type {Highcharts.StockToolsBindingsObject}
1672
+ * @product highstock
1673
+ * @default {"className": "highcharts-series-type-line", "init": function() {}}
1674
+ */
1675
+ seriesTypeLine: {
1676
+ /** @ignore */
1677
+ className: 'highcharts-series-type-line',
1678
+ /** @ignore */
1679
+ init: function (button) {
1680
+ this.chart.series[0].update({
1681
+ type: 'line',
1682
+ useOhlcData: true
1683
+ });
1684
+
1685
+ fireEvent(
1686
+ this,
1687
+ 'deselectButton',
1688
+ { button: button }
1689
+ );
1690
+ }
1691
+ },
1692
+ /**
1693
+ * Changes main series to `'ohlc'` type.
1694
+ *
1695
+ * @type {Highcharts.StockToolsBindingsObject}
1696
+ * @product highstock
1697
+ * @default {"className": "highcharts-series-type-ohlc", "init": function() {}}
1698
+ */
1699
+ seriesTypeOhlc: {
1700
+ /** @ignore */
1701
+ className: 'highcharts-series-type-ohlc',
1702
+ /** @ignore */
1703
+ init: function (button) {
1704
+ this.chart.series[0].update({
1705
+ type: 'ohlc'
1706
+ });
1707
+
1708
+ fireEvent(
1709
+ this,
1710
+ 'deselectButton',
1711
+ { button: button }
1712
+ );
1713
+ }
1714
+ },
1715
+ /**
1716
+ * Changes main series to `'candlestick'` type.
1717
+ *
1718
+ * @type {Highcharts.StockToolsBindingsObject}
1719
+ * @product highstock
1720
+ * @default {"className": "highcharts-series-type-candlestick", "init": function() {}}
1721
+ */
1722
+ seriesTypeCandlestick: {
1723
+ /** @ignore */
1724
+ className: 'highcharts-series-type-candlestick',
1725
+ /** @ignore */
1726
+ init: function (button) {
1727
+ this.chart.series[0].update({
1728
+ type: 'candlestick'
1729
+ });
1730
+
1731
+ fireEvent(
1732
+ this,
1733
+ 'deselectButton',
1734
+ { button: button }
1735
+ );
1736
+ }
1737
+ },
1738
+ /**
1739
+ * Displays chart in fullscreen.
1740
+ *
1741
+ * @type {Highcharts.StockToolsBindingsObject}
1742
+ * @product highstock
1743
+ * @default {"className": "highcharts-full-screen", "init": function() {}}
1744
+ */
1745
+ fullScreen: {
1746
+ /** @ignore */
1747
+ className: 'highcharts-full-screen',
1748
+ /** @ignore */
1749
+ init: function (button) {
1750
+ var chart = this.chart;
1751
+
1752
+ chart.fullScreen = new H.FullScreen(chart.container);
1753
+
1754
+ fireEvent(
1755
+ this,
1756
+ 'deselectButton',
1757
+ { button: button }
1758
+ );
1759
+ }
1760
+ },
1761
+ /**
1762
+ * Hides/shows two price indicators:
1763
+ * - last price in the dataset
1764
+ * - last price in the selected range
1765
+ *
1766
+ * @type {Highcharts.StockToolsBindingsObject}
1767
+ * @product highstock
1768
+ * @default {"className": "highcharts-current-price-indicator", "init": function() {}}
1769
+ */
1770
+ currentPriceIndicator: {
1771
+ /** @ignore */
1772
+ className: 'highcharts-current-price-indicator',
1773
+ /** @ignore */
1774
+ init: function (button) {
1775
+ var series = this.chart.series[0],
1776
+ options = series.options,
1777
+ lastVisiblePrice = options.lastVisiblePrice &&
1778
+ options.lastVisiblePrice.enabled,
1779
+ lastPrice = options.lastPrice && options.lastPrice.enabled,
1780
+ gui = this.chart.stockToolbar;
1781
+
1782
+ if (gui && gui.guiEnabled) {
1783
+ if (lastPrice) {
1784
+ button.firstChild.style['background-image'] =
1785
+ 'url("' + gui.options.iconsURL +
1786
+ 'current-price-show.svg")';
1787
+ } else {
1788
+ button.firstChild.style['background-image'] =
1789
+ 'url("' + gui.options.iconsURL +
1790
+ 'current-price-hide.svg")';
1791
+ }
1792
+ }
1793
+
1794
+ series.update({
1795
+ // line
1796
+ lastPrice: {
1797
+ enabled: !lastPrice,
1798
+ color: 'red'
1799
+ },
1800
+ // label
1801
+ lastVisiblePrice: {
1802
+ enabled: !lastVisiblePrice,
1803
+ label: {
1804
+ enabled: true
1805
+ }
1806
+ }
1807
+ });
1808
+
1809
+ fireEvent(
1810
+ this,
1811
+ 'deselectButton',
1812
+ { button: button }
1813
+ );
1814
+ }
1815
+ },
1816
+ /**
1817
+ * Indicators bindings. Includes `init` event to show a popup.
1818
+ *
1819
+ * @type {Highcharts.StockToolsBindingsObject}
1820
+ * @product highstock
1821
+ * @default {"className": "highcharts-indicators", "init": function() {}}
1822
+ */
1823
+ indicators: {
1824
+ /** @ignore */
1825
+ className: 'highcharts-indicators',
1826
+ /** @ignore */
1827
+ init: function () {
1828
+ var navigation = this;
1829
+
1830
+ fireEvent(
1831
+ navigation,
1832
+ 'showPopup',
1833
+ {
1834
+ formType: 'indicators',
1835
+ options: {},
1836
+ // Callback on submit:
1837
+ onSubmit: function (data) {
1838
+ navigation.utils.manageIndicators.call(
1839
+ navigation,
1840
+ data
1841
+ );
1842
+ }
1843
+ }
1844
+ );
1845
+ }
1846
+ },
1847
+ /**
1848
+ * Hides/shows all annotations on a chart.
1849
+ *
1850
+ * @type {Highcharts.StockToolsBindingsObject}
1851
+ * @product highstock
1852
+ * @default {"className": "highcharts-toggle-annotations", "init": function() {}}
1853
+ */
1854
+ toggleAnnotations: {
1855
+ /** @ignore */
1856
+ className: 'highcharts-toggle-annotations',
1857
+ /** @ignore */
1858
+ init: function (button) {
1859
+ var gui = this.chart.stockToolbar;
1860
+
1861
+ this.toggledAnnotations = !this.toggledAnnotations;
1862
+
1863
+ (this.chart.annotations || []).forEach(function (annotation) {
1864
+ annotation.setVisibility(!this.toggledAnnotations);
1865
+ }, this);
1866
+
1867
+ if (gui && gui.guiEnabled) {
1868
+ if (this.toggledAnnotations) {
1869
+ button.firstChild.style['background-image'] =
1870
+ 'url("' + gui.options.iconsURL +
1871
+ 'annotations-hidden.svg")';
1872
+ } else {
1873
+ button.firstChild.style['background-image'] =
1874
+ 'url("' + gui.options.iconsURL +
1875
+ 'annotations-visible.svg")';
1876
+ }
1877
+ }
1878
+
1879
+ fireEvent(
1880
+ this,
1881
+ 'deselectButton',
1882
+ { button: button }
1883
+ );
1884
+ }
1885
+ },
1886
+ /**
1887
+ * Save a chart in localStorage under `highcharts-chart` key.
1888
+ * Stored items:
1889
+ * - annotations
1890
+ * - indicators (with yAxes)
1891
+ * - flags
1892
+ *
1893
+ * @type {Highcharts.StockToolsBindingsObject}
1894
+ * @product highstock
1895
+ * @default {"className": "highcharts-save-chart", "init": function() {}}
1896
+ */
1897
+ saveChart: {
1898
+ /** @ignore */
1899
+ className: 'highcharts-save-chart',
1900
+ /** @ignore */
1901
+ init: function (button) {
1902
+ var navigation = this,
1903
+ chart = navigation.chart,
1904
+ annotations = [],
1905
+ indicators = [],
1906
+ flags = [],
1907
+ yAxes = [];
1908
+
1909
+ chart.annotations.forEach(function (annotation, index) {
1910
+ annotations[index] = annotation.userOptions;
1911
+ });
1912
+
1913
+ chart.series.forEach(function (series) {
1914
+ if (series instanceof H.seriesTypes.sma) {
1915
+ indicators.push(series.userOptions);
1916
+ } else if (series.type === 'flags') {
1917
+ flags.push(series.userOptions);
1918
+ }
1919
+ });
1920
+
1921
+ chart.yAxis.forEach(function (yAxis) {
1922
+ if (navigation.utils.isNotNavigatorYAxis(yAxis)) {
1923
+ yAxes.push(yAxis.options);
1924
+ }
1925
+ });
1926
+
1927
+ H.win.localStorage.setItem(
1928
+ PREFIX + 'chart',
1929
+ JSON.stringify({
1930
+ annotations: annotations,
1931
+ indicators: indicators,
1932
+ flags: flags,
1933
+ yAxes: yAxes
1934
+ })
1935
+ );
1936
+
1937
+ fireEvent(
1938
+ this,
1939
+ 'deselectButton',
1940
+ { button: button }
1941
+ );
1942
+ }
1943
+ }
1944
+ };
1945
+
1946
+ H.setOptions({
1947
+ navigation: {
1948
+ bindings: stockToolsBindings
1949
+ }
1950
+ });