highcharts 6.1.4 → 6.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (695) hide show
  1. package/bower.json +1 -1
  2. package/css/highcharts.css +17 -0
  3. package/css/highcharts.scss +14 -0
  4. package/css/themes/dark-unica.css +17 -0
  5. package/css/themes/grid-light.css +17 -0
  6. package/css/themes/sand-signika.css +17 -0
  7. package/es-modules/indicators/momentum.src.js +1 -1
  8. package/es-modules/indicators/pivot-points.src.js +6 -1
  9. package/es-modules/masters/highcharts-gantt.src.js +11 -0
  10. package/es-modules/masters/modules/annotations.src.js +1 -1
  11. package/es-modules/masters/modules/arrow-symbols.src.js +12 -0
  12. package/es-modules/masters/modules/broken-axis.src.js +1 -1
  13. package/es-modules/masters/modules/current-date-indicator.src.js +12 -0
  14. package/es-modules/masters/modules/data.src.js +1 -1
  15. package/es-modules/masters/modules/draggable-points.src.js +9 -0
  16. package/es-modules/masters/modules/export-data.src.js +1 -1
  17. package/es-modules/masters/modules/exporting.src.js +1 -1
  18. package/es-modules/masters/modules/funnel.src.js +1 -1
  19. package/es-modules/masters/modules/gantt.src.js +2 -1
  20. package/es-modules/masters/modules/grid-axis.src.js +1 -1
  21. package/es-modules/masters/modules/heatmap.src.js +1 -1
  22. package/es-modules/masters/modules/item-series.src.js +1 -1
  23. package/es-modules/masters/modules/map.src.js +1 -1
  24. package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
  25. package/es-modules/masters/modules/pathfinder.src.js +12 -0
  26. package/es-modules/masters/modules/sankey.src.js +1 -1
  27. package/es-modules/masters/modules/series-label.src.js +1 -1
  28. package/es-modules/masters/modules/solid-gauge.src.js +1 -1
  29. package/es-modules/masters/modules/stock.src.js +1 -1
  30. package/es-modules/masters/modules/streamgraph.src.js +1 -1
  31. package/es-modules/masters/modules/treegrid.src.js +12 -0
  32. package/es-modules/masters/modules/variwide.src.js +1 -1
  33. package/es-modules/masters/modules/vector.src.js +1 -1
  34. package/es-modules/masters/modules/windbarb.src.js +1 -1
  35. package/es-modules/masters/modules/xrange.src.js +1 -1
  36. package/es-modules/masters/themes/dark-blue.src.js +1 -1
  37. package/es-modules/masters/themes/dark-green.src.js +1 -1
  38. package/es-modules/masters/themes/dark-unica.src.js +1 -1
  39. package/es-modules/masters/themes/gray.src.js +1 -1
  40. package/es-modules/masters/themes/grid-light.src.js +1 -1
  41. package/es-modules/masters/themes/grid.src.js +1 -1
  42. package/es-modules/masters/themes/sand-signika.src.js +1 -1
  43. package/es-modules/masters/themes/skies.src.js +1 -1
  44. package/es-modules/mixins/centered-series.js +1 -1
  45. package/es-modules/mixins/on-series.js +1 -1
  46. package/es-modules/modules/boost.src.js +22 -14
  47. package/es-modules/modules/broken-axis.src.js +169 -134
  48. package/es-modules/modules/data.src.js +2 -2
  49. package/es-modules/modules/draggable-points.src.js +2257 -0
  50. package/es-modules/modules/drilldown.src.js +1 -0
  51. package/es-modules/modules/export-data.src.js +1 -1
  52. package/es-modules/modules/exporting.src.js +1 -1
  53. package/es-modules/modules/funnel.src.js +1 -1
  54. package/es-modules/modules/item-series.src.js +1 -1
  55. package/es-modules/modules/no-data-to-display.src.js +5 -5
  56. package/es-modules/modules/oldie.src.js +1 -1
  57. package/es-modules/modules/overlapping-datalabels.src.js +38 -22
  58. package/es-modules/modules/parallel-coordinates.src.js +3 -2
  59. package/es-modules/modules/sankey.src.js +1 -1
  60. package/es-modules/modules/series-label.src.js +2 -2
  61. package/es-modules/modules/solid-gauge.src.js +1 -1
  62. package/es-modules/modules/static-scale.src.js +67 -28
  63. package/es-modules/modules/streamgraph.src.js +1 -1
  64. package/es-modules/modules/tilemap.src.js +231 -134
  65. package/es-modules/modules/variwide.src.js +1 -1
  66. package/es-modules/modules/vector.src.js +92 -22
  67. package/es-modules/modules/windbarb.src.js +1 -1
  68. package/es-modules/modules/xrange.src.js +257 -77
  69. package/es-modules/parts/AreaSeries.js +77 -77
  70. package/es-modules/parts/AreaSplineSeries.js +64 -27
  71. package/es-modules/parts/Axis.js +160 -67
  72. package/es-modules/parts/BarSeries.js +68 -51
  73. package/es-modules/parts/CandlestickSeries.js +1 -1
  74. package/es-modules/parts/Chart.js +31 -55
  75. package/es-modules/parts/Color.js +29 -18
  76. package/es-modules/parts/ColumnSeries.js +264 -142
  77. package/es-modules/parts/DataGrouping.js +9 -6
  78. package/es-modules/parts/DataLabels.js +261 -210
  79. package/es-modules/parts/DateTimeAxis.js +26 -7
  80. package/es-modules/parts/Dynamics.js +5 -2
  81. package/es-modules/parts/FlagsSeries.js +1 -1
  82. package/es-modules/parts/Globals.js +1 -1
  83. package/es-modules/parts/Html.js +64 -12
  84. package/es-modules/parts/Interaction.js +187 -63
  85. package/es-modules/parts/Legend.js +7 -3
  86. package/es-modules/parts/LogarithmicAxis.js +35 -4
  87. package/es-modules/parts/MSPointer.js +1 -1
  88. package/es-modules/parts/Navigator.js +27 -5
  89. package/es-modules/parts/OHLCSeries.js +1 -1
  90. package/es-modules/parts/Options.js +15 -13
  91. package/es-modules/parts/OrdinalAxis.js +1 -1
  92. package/es-modules/parts/PieSeries.js +256 -140
  93. package/es-modules/parts/PlotBandSeries.experimental.js +1 -1
  94. package/es-modules/parts/PlotLineOrBand.js +7 -40
  95. package/es-modules/parts/Point.js +28 -4
  96. package/es-modules/parts/Pointer.js +8 -6
  97. package/es-modules/parts/RangeSelector.js +1 -1
  98. package/es-modules/parts/Responsive.js +82 -36
  99. package/es-modules/parts/ScatterSeries.js +57 -25
  100. package/es-modules/parts/ScrollablePlotArea.js +17 -7
  101. package/es-modules/parts/Scrollbar.js +9 -2
  102. package/es-modules/parts/Series.js +22 -9
  103. package/es-modules/parts/SplineSeries.js +51 -29
  104. package/es-modules/parts/Stacking.js +100 -6
  105. package/es-modules/parts/StockChart.js +9 -3
  106. package/es-modules/parts/SvgRenderer.js +15 -10
  107. package/es-modules/parts/Tick.js +150 -30
  108. package/es-modules/parts/Time.js +23 -5
  109. package/es-modules/parts/Tooltip.js +2 -2
  110. package/es-modules/parts/TouchPointer.js +1 -1
  111. package/es-modules/parts/Utilities.js +16 -1
  112. package/es-modules/parts-3d/Axis.js +1 -1
  113. package/es-modules/parts-3d/Chart.js +1 -1
  114. package/es-modules/parts-3d/Column.js +1 -1
  115. package/es-modules/parts-3d/Math.js +1 -1
  116. package/es-modules/parts-3d/Pie.js +1 -1
  117. package/es-modules/parts-3d/SVGRenderer.js +1 -1
  118. package/es-modules/parts-3d/Scatter.js +1 -1
  119. package/es-modules/parts-3d/Series.js +1 -1
  120. package/es-modules/parts-3d/VMLRenderer.js +1 -1
  121. package/es-modules/parts-gantt/ArrowSymbols.js +110 -0
  122. package/es-modules/parts-gantt/CurrentDateIndicator.js +92 -0
  123. package/es-modules/parts-gantt/GanttChart.js +111 -0
  124. package/es-modules/parts-gantt/GanttSeries.js +376 -0
  125. package/es-modules/parts-gantt/GridAxis.js +965 -0
  126. package/es-modules/parts-gantt/Pathfinder.js +1247 -0
  127. package/es-modules/parts-gantt/PathfinderAlgorithms.js +746 -0
  128. package/es-modules/parts-gantt/Tree.js +146 -0
  129. package/es-modules/parts-gantt/TreeGrid.js +917 -0
  130. package/es-modules/parts-map/ColorAxis.js +1 -1
  131. package/es-modules/parts-map/ColorSeriesMixin.js +1 -1
  132. package/es-modules/parts-map/GeoJSON.js +1 -1
  133. package/es-modules/parts-map/HeatmapSeries.js +124 -53
  134. package/es-modules/parts-map/Map.js +1 -1
  135. package/es-modules/parts-map/MapAxis.js +1 -1
  136. package/es-modules/parts-map/MapBubbleSeries.js +1 -1
  137. package/es-modules/parts-map/MapLineSeries.js +1 -1
  138. package/es-modules/parts-map/MapNavigation.js +1 -1
  139. package/es-modules/parts-map/MapPointSeries.js +1 -1
  140. package/es-modules/parts-map/MapPointer.js +1 -1
  141. package/es-modules/parts-map/MapSeries.js +2 -2
  142. package/es-modules/parts-more/AreaRangeSeries.js +80 -38
  143. package/es-modules/parts-more/AreaSplineRangeSeries.js +1 -1
  144. package/es-modules/parts-more/BoxPlotSeries.js +1 -1
  145. package/es-modules/parts-more/BubbleSeries.js +1 -1
  146. package/es-modules/parts-more/ColumnRangeSeries.js +1 -1
  147. package/es-modules/parts-more/ErrorBarSeries.js +1 -1
  148. package/es-modules/parts-more/GaugeSeries.js +1 -1
  149. package/es-modules/parts-more/Pane.js +2 -1
  150. package/es-modules/parts-more/Polar.js +1 -1
  151. package/es-modules/parts-more/PolygonSeries.js +1 -1
  152. package/es-modules/parts-more/RadialAxis.js +5 -4
  153. package/es-modules/parts-more/WaterfallSeries.js +1 -1
  154. package/es-modules/supplemental.docs.js +0 -1955
  155. package/es-modules/themes/dark-blue.js +1 -1
  156. package/es-modules/themes/dark-green.js +1 -1
  157. package/es-modules/themes/dark-unica.js +1 -1
  158. package/es-modules/themes/gray.js +1 -1
  159. package/es-modules/themes/grid-light.js +1 -1
  160. package/es-modules/themes/grid.js +1 -1
  161. package/es-modules/themes/sand-signika.js +1 -1
  162. package/es-modules/themes/skies.js +1 -1
  163. package/highcharts-3d.js +1 -1
  164. package/highcharts-3d.src.js +10 -10
  165. package/highcharts-gantt.js +503 -0
  166. package/highcharts-gantt.js.map +1 -0
  167. package/highcharts-gantt.src.js +49289 -0
  168. package/highcharts-more.js +65 -64
  169. package/highcharts-more.js.map +1 -1
  170. package/highcharts-more.src.js +97 -53
  171. package/highcharts.js +415 -410
  172. package/highcharts.js.map +1 -1
  173. package/highcharts.src.js +2170 -1128
  174. package/highmaps.js +443 -438
  175. package/highmaps.js.map +1 -1
  176. package/highmaps.src.js +1647 -849
  177. package/highstock.js +553 -548
  178. package/highstock.js.map +1 -1
  179. package/highstock.src.js +2398 -1283
  180. package/indicators/accumulation-distribution.js +1 -1
  181. package/indicators/accumulation-distribution.src.js +1 -1
  182. package/indicators/atr.js +1 -1
  183. package/indicators/atr.src.js +1 -1
  184. package/indicators/bollinger-bands.js +1 -1
  185. package/indicators/bollinger-bands.src.js +1 -1
  186. package/indicators/cci.js +1 -1
  187. package/indicators/cci.src.js +1 -1
  188. package/indicators/cmf.js +1 -1
  189. package/indicators/cmf.src.js +1 -1
  190. package/indicators/ema.js +1 -1
  191. package/indicators/ema.src.js +1 -1
  192. package/indicators/ichimoku-kinko-hyo.js +1 -1
  193. package/indicators/ichimoku-kinko-hyo.src.js +1 -1
  194. package/indicators/indicators.js +1 -1
  195. package/indicators/indicators.src.js +1 -1
  196. package/indicators/macd.js +1 -1
  197. package/indicators/macd.src.js +1 -1
  198. package/indicators/mfi.js +1 -1
  199. package/indicators/mfi.src.js +1 -1
  200. package/indicators/momentum.js +1 -1
  201. package/indicators/momentum.src.js +2 -2
  202. package/indicators/pivot-points.js +4 -4
  203. package/indicators/pivot-points.js.map +1 -1
  204. package/indicators/pivot-points.src.js +7 -2
  205. package/indicators/price-envelopes.js +1 -1
  206. package/indicators/price-envelopes.src.js +1 -1
  207. package/indicators/psar.js +1 -1
  208. package/indicators/psar.src.js +1 -1
  209. package/indicators/roc.js +1 -1
  210. package/indicators/roc.src.js +1 -1
  211. package/indicators/rsi.js +1 -1
  212. package/indicators/rsi.src.js +1 -1
  213. package/indicators/stochastic.js +1 -1
  214. package/indicators/stochastic.src.js +1 -1
  215. package/indicators/volume-by-price.js +1 -1
  216. package/indicators/volume-by-price.src.js +1 -1
  217. package/indicators/vwap.js +1 -1
  218. package/indicators/vwap.src.js +1 -1
  219. package/indicators/wma.js +1 -1
  220. package/indicators/wma.src.js +1 -1
  221. package/indicators/zigzag.js +1 -1
  222. package/indicators/zigzag.src.js +1 -1
  223. package/js/es-modules/indicators/momentum.src.js +1 -1
  224. package/js/es-modules/indicators/pivot-points.src.js +6 -1
  225. package/js/es-modules/masters/highcharts-gantt.src.js +11 -0
  226. package/js/es-modules/masters/modules/annotations.src.js +1 -1
  227. package/js/es-modules/masters/modules/arrow-symbols.src.js +12 -0
  228. package/js/es-modules/masters/modules/broken-axis.src.js +1 -1
  229. package/js/es-modules/masters/modules/current-date-indicator.src.js +12 -0
  230. package/js/es-modules/masters/modules/data.src.js +1 -1
  231. package/js/es-modules/masters/modules/draggable-points.src.js +9 -0
  232. package/js/es-modules/masters/modules/export-data.src.js +1 -1
  233. package/js/es-modules/masters/modules/exporting.src.js +1 -1
  234. package/js/es-modules/masters/modules/funnel.src.js +1 -1
  235. package/js/es-modules/masters/modules/gantt.src.js +2 -1
  236. package/js/es-modules/masters/modules/grid-axis.src.js +1 -1
  237. package/js/es-modules/masters/modules/heatmap.src.js +1 -1
  238. package/js/es-modules/masters/modules/item-series.src.js +1 -1
  239. package/js/es-modules/masters/modules/map.src.js +1 -1
  240. package/js/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
  241. package/js/es-modules/masters/modules/pathfinder.src.js +12 -0
  242. package/js/es-modules/masters/modules/sankey.src.js +1 -1
  243. package/js/es-modules/masters/modules/series-label.src.js +1 -1
  244. package/js/es-modules/masters/modules/solid-gauge.src.js +1 -1
  245. package/js/es-modules/masters/modules/stock.src.js +1 -1
  246. package/js/es-modules/masters/modules/streamgraph.src.js +1 -1
  247. package/js/es-modules/masters/modules/treegrid.src.js +12 -0
  248. package/js/es-modules/masters/modules/variwide.src.js +1 -1
  249. package/js/es-modules/masters/modules/vector.src.js +1 -1
  250. package/js/es-modules/masters/modules/windbarb.src.js +1 -1
  251. package/js/es-modules/masters/modules/xrange.src.js +1 -1
  252. package/js/es-modules/masters/themes/dark-blue.src.js +1 -1
  253. package/js/es-modules/masters/themes/dark-green.src.js +1 -1
  254. package/js/es-modules/masters/themes/dark-unica.src.js +1 -1
  255. package/js/es-modules/masters/themes/gray.src.js +1 -1
  256. package/js/es-modules/masters/themes/grid-light.src.js +1 -1
  257. package/js/es-modules/masters/themes/grid.src.js +1 -1
  258. package/js/es-modules/masters/themes/sand-signika.src.js +1 -1
  259. package/js/es-modules/masters/themes/skies.src.js +1 -1
  260. package/js/es-modules/mixins/centered-series.js +1 -1
  261. package/js/es-modules/mixins/on-series.js +1 -1
  262. package/js/es-modules/modules/boost.src.js +22 -14
  263. package/js/es-modules/modules/broken-axis.src.js +169 -134
  264. package/js/es-modules/modules/data.src.js +2 -2
  265. package/js/es-modules/modules/draggable-points.src.js +2257 -0
  266. package/js/es-modules/modules/drilldown.src.js +1 -0
  267. package/js/es-modules/modules/export-data.src.js +1 -1
  268. package/js/es-modules/modules/exporting.src.js +1 -1
  269. package/js/es-modules/modules/funnel.src.js +1 -1
  270. package/js/es-modules/modules/item-series.src.js +1 -1
  271. package/js/es-modules/modules/no-data-to-display.src.js +5 -5
  272. package/js/es-modules/modules/oldie.src.js +1 -1
  273. package/js/es-modules/modules/overlapping-datalabels.src.js +38 -22
  274. package/js/es-modules/modules/parallel-coordinates.src.js +3 -2
  275. package/js/es-modules/modules/sankey.src.js +1 -1
  276. package/js/es-modules/modules/series-label.src.js +2 -2
  277. package/js/es-modules/modules/solid-gauge.src.js +1 -1
  278. package/js/es-modules/modules/static-scale.src.js +67 -28
  279. package/js/es-modules/modules/streamgraph.src.js +1 -1
  280. package/js/es-modules/modules/tilemap.src.js +231 -134
  281. package/js/es-modules/modules/variwide.src.js +1 -1
  282. package/js/es-modules/modules/vector.src.js +92 -22
  283. package/js/es-modules/modules/windbarb.src.js +1 -1
  284. package/js/es-modules/modules/xrange.src.js +255 -68
  285. package/js/es-modules/parts/AreaSeries.js +77 -77
  286. package/js/es-modules/parts/AreaSplineSeries.js +64 -27
  287. package/js/es-modules/parts/Axis.js +160 -67
  288. package/js/es-modules/parts/BarSeries.js +68 -51
  289. package/js/es-modules/parts/CandlestickSeries.js +1 -1
  290. package/js/es-modules/parts/Chart.js +31 -55
  291. package/js/es-modules/parts/Color.js +29 -18
  292. package/js/es-modules/parts/ColumnSeries.js +231 -123
  293. package/js/es-modules/parts/DataGrouping.js +9 -6
  294. package/js/es-modules/parts/DataLabels.js +230 -182
  295. package/js/es-modules/parts/DateTimeAxis.js +26 -7
  296. package/js/es-modules/parts/Dynamics.js +5 -2
  297. package/js/es-modules/parts/FlagsSeries.js +1 -1
  298. package/js/es-modules/parts/Globals.js +1 -1
  299. package/js/es-modules/parts/Html.js +64 -12
  300. package/js/es-modules/parts/Interaction.js +178 -61
  301. package/js/es-modules/parts/Legend.js +7 -3
  302. package/js/es-modules/parts/LogarithmicAxis.js +35 -4
  303. package/js/es-modules/parts/MSPointer.js +1 -1
  304. package/js/es-modules/parts/Navigator.js +27 -5
  305. package/js/es-modules/parts/OHLCSeries.js +1 -1
  306. package/js/es-modules/parts/Options.js +13 -12
  307. package/js/es-modules/parts/OrdinalAxis.js +1 -1
  308. package/js/es-modules/parts/PieSeries.js +245 -132
  309. package/js/es-modules/parts/PlotBandSeries.experimental.js +1 -1
  310. package/js/es-modules/parts/PlotLineOrBand.js +7 -40
  311. package/js/es-modules/parts/Point.js +28 -4
  312. package/js/es-modules/parts/Pointer.js +8 -6
  313. package/js/es-modules/parts/RangeSelector.js +1 -1
  314. package/js/es-modules/parts/Responsive.js +82 -36
  315. package/js/es-modules/parts/ScatterSeries.js +56 -25
  316. package/js/es-modules/parts/ScrollablePlotArea.js +17 -7
  317. package/js/es-modules/parts/Scrollbar.js +9 -2
  318. package/js/es-modules/parts/Series.js +22 -9
  319. package/js/es-modules/parts/SplineSeries.js +51 -29
  320. package/js/es-modules/parts/Stacking.js +100 -6
  321. package/js/es-modules/parts/StockChart.js +9 -3
  322. package/js/es-modules/parts/SvgRenderer.js +15 -10
  323. package/js/es-modules/parts/Tick.js +150 -30
  324. package/js/es-modules/parts/Time.js +23 -5
  325. package/js/es-modules/parts/Tooltip.js +2 -2
  326. package/js/es-modules/parts/TouchPointer.js +1 -1
  327. package/js/es-modules/parts/Utilities.js +16 -1
  328. package/js/es-modules/parts-3d/Axis.js +1 -1
  329. package/js/es-modules/parts-3d/Chart.js +1 -1
  330. package/js/es-modules/parts-3d/Column.js +1 -1
  331. package/js/es-modules/parts-3d/Math.js +1 -1
  332. package/js/es-modules/parts-3d/Pie.js +1 -1
  333. package/js/es-modules/parts-3d/SVGRenderer.js +1 -1
  334. package/js/es-modules/parts-3d/Scatter.js +1 -1
  335. package/js/es-modules/parts-3d/Series.js +1 -1
  336. package/js/es-modules/parts-3d/VMLRenderer.js +1 -1
  337. package/js/es-modules/parts-gantt/ArrowSymbols.js +110 -0
  338. package/js/es-modules/parts-gantt/CurrentDateIndicator.js +92 -0
  339. package/js/es-modules/parts-gantt/GanttChart.js +111 -0
  340. package/js/es-modules/parts-gantt/GanttSeries.js +371 -0
  341. package/js/es-modules/parts-gantt/GridAxis.js +962 -0
  342. package/js/es-modules/parts-gantt/Pathfinder.js +1225 -0
  343. package/js/es-modules/parts-gantt/PathfinderAlgorithms.js +746 -0
  344. package/js/es-modules/parts-gantt/Tree.js +146 -0
  345. package/js/es-modules/parts-gantt/TreeGrid.js +891 -0
  346. package/js/es-modules/parts-map/ColorAxis.js +1 -1
  347. package/js/es-modules/parts-map/ColorSeriesMixin.js +1 -1
  348. package/js/es-modules/parts-map/GeoJSON.js +1 -1
  349. package/js/es-modules/parts-map/HeatmapSeries.js +122 -52
  350. package/js/es-modules/parts-map/Map.js +1 -1
  351. package/js/es-modules/parts-map/MapAxis.js +1 -1
  352. package/js/es-modules/parts-map/MapBubbleSeries.js +1 -1
  353. package/js/es-modules/parts-map/MapLineSeries.js +1 -1
  354. package/js/es-modules/parts-map/MapNavigation.js +1 -1
  355. package/js/es-modules/parts-map/MapPointSeries.js +1 -1
  356. package/js/es-modules/parts-map/MapPointer.js +1 -1
  357. package/js/es-modules/parts-map/MapSeries.js +2 -2
  358. package/js/es-modules/parts-more/AreaRangeSeries.js +80 -38
  359. package/js/es-modules/parts-more/AreaSplineRangeSeries.js +1 -1
  360. package/js/es-modules/parts-more/BoxPlotSeries.js +1 -1
  361. package/js/es-modules/parts-more/BubbleSeries.js +1 -1
  362. package/js/es-modules/parts-more/ColumnRangeSeries.js +1 -1
  363. package/js/es-modules/parts-more/ErrorBarSeries.js +1 -1
  364. package/js/es-modules/parts-more/GaugeSeries.js +1 -1
  365. package/js/es-modules/parts-more/Pane.js +2 -1
  366. package/js/es-modules/parts-more/Polar.js +1 -1
  367. package/js/es-modules/parts-more/PolygonSeries.js +1 -1
  368. package/js/es-modules/parts-more/RadialAxis.js +5 -4
  369. package/js/es-modules/parts-more/WaterfallSeries.js +1 -1
  370. package/js/es-modules/supplemental.docs.js +0 -1955
  371. package/js/es-modules/themes/dark-blue.js +1 -1
  372. package/js/es-modules/themes/dark-green.js +1 -1
  373. package/js/es-modules/themes/dark-unica.js +1 -1
  374. package/js/es-modules/themes/gray.js +1 -1
  375. package/js/es-modules/themes/grid-light.js +1 -1
  376. package/js/es-modules/themes/grid.js +1 -1
  377. package/js/es-modules/themes/sand-signika.js +1 -1
  378. package/js/es-modules/themes/skies.js +1 -1
  379. package/js/highcharts-3d.js +1 -1
  380. package/js/highcharts-3d.src.js +10 -10
  381. package/js/highcharts-gantt.js +480 -0
  382. package/js/highcharts-gantt.js.map +1 -0
  383. package/js/highcharts-gantt.src.js +47011 -0
  384. package/js/highcharts-more.js +62 -61
  385. package/js/highcharts-more.js.map +1 -1
  386. package/js/highcharts-more.src.js +97 -53
  387. package/js/highcharts.js +394 -390
  388. package/js/highcharts.js.map +1 -1
  389. package/js/highcharts.src.js +2083 -1070
  390. package/js/highmaps.js +420 -416
  391. package/js/highmaps.js.map +1 -1
  392. package/js/highmaps.src.js +1569 -798
  393. package/js/highstock.js +526 -520
  394. package/js/highstock.js.map +1 -1
  395. package/js/highstock.src.js +2311 -1225
  396. package/js/indicators/accumulation-distribution.js +1 -1
  397. package/js/indicators/accumulation-distribution.src.js +1 -1
  398. package/js/indicators/atr.js +1 -1
  399. package/js/indicators/atr.src.js +1 -1
  400. package/js/indicators/bollinger-bands.js +1 -1
  401. package/js/indicators/bollinger-bands.src.js +1 -1
  402. package/js/indicators/cci.js +1 -1
  403. package/js/indicators/cci.src.js +1 -1
  404. package/js/indicators/cmf.js +1 -1
  405. package/js/indicators/cmf.src.js +1 -1
  406. package/js/indicators/ema.js +1 -1
  407. package/js/indicators/ema.src.js +1 -1
  408. package/js/indicators/ichimoku-kinko-hyo.js +1 -1
  409. package/js/indicators/ichimoku-kinko-hyo.src.js +1 -1
  410. package/js/indicators/indicators.js +1 -1
  411. package/js/indicators/indicators.src.js +1 -1
  412. package/js/indicators/macd.js +1 -1
  413. package/js/indicators/macd.src.js +1 -1
  414. package/js/indicators/mfi.js +1 -1
  415. package/js/indicators/mfi.src.js +1 -1
  416. package/js/indicators/momentum.js +1 -1
  417. package/js/indicators/momentum.src.js +2 -2
  418. package/js/indicators/pivot-points.js +4 -4
  419. package/js/indicators/pivot-points.js.map +1 -1
  420. package/js/indicators/pivot-points.src.js +7 -2
  421. package/js/indicators/price-envelopes.js +1 -1
  422. package/js/indicators/price-envelopes.src.js +1 -1
  423. package/js/indicators/psar.js +1 -1
  424. package/js/indicators/psar.src.js +1 -1
  425. package/js/indicators/roc.js +1 -1
  426. package/js/indicators/roc.src.js +1 -1
  427. package/js/indicators/rsi.js +1 -1
  428. package/js/indicators/rsi.src.js +1 -1
  429. package/js/indicators/stochastic.js +1 -1
  430. package/js/indicators/stochastic.src.js +1 -1
  431. package/js/indicators/volume-by-price.js +1 -1
  432. package/js/indicators/volume-by-price.src.js +1 -1
  433. package/js/indicators/vwap.js +1 -1
  434. package/js/indicators/vwap.src.js +1 -1
  435. package/js/indicators/wma.js +1 -1
  436. package/js/indicators/wma.src.js +1 -1
  437. package/js/indicators/zigzag.js +1 -1
  438. package/js/indicators/zigzag.src.js +1 -1
  439. package/js/modules/accessibility.js +1 -1
  440. package/js/modules/accessibility.src.js +1 -1
  441. package/js/modules/annotations.js +2 -2
  442. package/js/modules/annotations.src.js +2 -2
  443. package/js/modules/arrow-symbols.js +13 -0
  444. package/js/modules/arrow-symbols.js.map +1 -0
  445. package/js/modules/arrow-symbols.src.js +138 -0
  446. package/js/modules/boost-canvas.js +1 -1
  447. package/js/modules/boost-canvas.src.js +1 -1
  448. package/js/modules/boost.js +43 -43
  449. package/js/modules/boost.js.map +1 -1
  450. package/js/modules/boost.src.js +23 -15
  451. package/js/modules/broken-axis.js +11 -10
  452. package/js/modules/broken-axis.js.map +1 -1
  453. package/js/modules/broken-axis.src.js +171 -136
  454. package/js/modules/bullet.js +1 -1
  455. package/js/modules/bullet.src.js +1 -1
  456. package/js/modules/current-date-indicator.js +13 -0
  457. package/js/modules/current-date-indicator.js.map +1 -0
  458. package/js/modules/current-date-indicator.src.js +120 -0
  459. package/js/modules/data.js +2 -2
  460. package/js/modules/data.src.js +4 -4
  461. package/js/modules/drag-panes.js +1 -1
  462. package/js/modules/drag-panes.src.js +1 -1
  463. package/js/modules/draggable-points.js +38 -0
  464. package/js/modules/draggable-points.js.map +1 -0
  465. package/js/modules/draggable-points.src.js +2281 -0
  466. package/js/modules/drilldown.js +1 -1
  467. package/js/modules/drilldown.js.map +1 -1
  468. package/js/modules/drilldown.src.js +2 -1
  469. package/js/modules/export-data.js +2 -2
  470. package/js/modules/export-data.src.js +3 -3
  471. package/js/modules/exporting.js +2 -2
  472. package/js/modules/exporting.src.js +3 -3
  473. package/js/modules/funnel.js +2 -2
  474. package/js/modules/funnel.src.js +3 -3
  475. package/js/modules/gantt.js +80 -18
  476. package/js/modules/gantt.js.map +1 -1
  477. package/js/modules/gantt.src.js +5490 -372
  478. package/js/modules/grid-axis.js +15 -11
  479. package/js/modules/grid-axis.js.map +1 -1
  480. package/js/modules/grid-axis.src.js +731 -293
  481. package/js/modules/heatmap.js +2 -2
  482. package/js/modules/heatmap.js.map +1 -1
  483. package/js/modules/heatmap.src.js +126 -56
  484. package/js/modules/histogram-bellcurve.js +1 -1
  485. package/js/modules/histogram-bellcurve.src.js +1 -1
  486. package/js/modules/item-series.js +2 -2
  487. package/js/modules/item-series.src.js +3 -3
  488. package/js/modules/map.js +2 -2
  489. package/js/modules/map.js.map +1 -1
  490. package/js/modules/map.src.js +137 -67
  491. package/js/modules/no-data-to-display.js +1 -1
  492. package/js/modules/no-data-to-display.src.js +6 -6
  493. package/js/modules/offline-exporting.js +2 -2
  494. package/js/modules/offline-exporting.src.js +2 -2
  495. package/js/modules/oldie.js +2 -2
  496. package/js/modules/oldie.src.js +3 -3
  497. package/js/modules/overlapping-datalabels.js +2 -2
  498. package/js/modules/overlapping-datalabels.src.js +2 -2
  499. package/js/modules/parallel-coordinates.js +9 -9
  500. package/js/modules/parallel-coordinates.js.map +1 -1
  501. package/js/modules/parallel-coordinates.src.js +4 -3
  502. package/js/modules/pareto.js +1 -1
  503. package/js/modules/pareto.src.js +1 -1
  504. package/js/modules/pathfinder.js +34 -0
  505. package/js/modules/pathfinder.js.map +1 -0
  506. package/js/modules/pathfinder.src.js +2106 -0
  507. package/js/modules/pattern-fill.js +1 -1
  508. package/js/modules/pattern-fill.src.js +1 -1
  509. package/js/modules/sankey.js +2 -2
  510. package/js/modules/sankey.src.js +3 -3
  511. package/js/modules/series-label.js +2 -2
  512. package/js/modules/series-label.src.js +4 -4
  513. package/js/modules/solid-gauge.js +2 -2
  514. package/js/modules/solid-gauge.src.js +3 -3
  515. package/js/modules/static-scale.js +3 -3
  516. package/js/modules/static-scale.js.map +1 -1
  517. package/js/modules/static-scale.src.js +65 -26
  518. package/js/modules/stock.js +135 -134
  519. package/js/modules/stock.js.map +1 -1
  520. package/js/modules/stock.src.js +230 -157
  521. package/js/modules/streamgraph.js +2 -2
  522. package/js/modules/streamgraph.src.js +3 -3
  523. package/js/modules/sunburst.js +1 -1
  524. package/js/modules/sunburst.src.js +1 -1
  525. package/js/modules/tilemap.js +1 -1
  526. package/js/modules/tilemap.js.map +1 -1
  527. package/js/modules/tilemap.src.js +355 -188
  528. package/js/modules/treegrid.js +51 -0
  529. package/js/modules/treegrid.js.map +1 -0
  530. package/js/modules/treegrid.src.js +2759 -0
  531. package/js/modules/treemap.js +1 -1
  532. package/js/modules/treemap.src.js +1 -1
  533. package/js/modules/variable-pie.js +1 -1
  534. package/js/modules/variable-pie.src.js +1 -1
  535. package/js/modules/variwide.js +2 -2
  536. package/js/modules/variwide.src.js +3 -3
  537. package/js/modules/vector.js +2 -2
  538. package/js/modules/vector.js.map +1 -1
  539. package/js/modules/vector.src.js +94 -24
  540. package/js/modules/windbarb.js +2 -2
  541. package/js/modules/windbarb.src.js +4 -4
  542. package/js/modules/wordcloud.js +1 -1
  543. package/js/modules/wordcloud.src.js +1 -1
  544. package/js/modules/xrange.js +11 -10
  545. package/js/modules/xrange.js.map +1 -1
  546. package/js/modules/xrange.src.js +257 -70
  547. package/js/themes/avocado.js +1 -1
  548. package/js/themes/avocado.src.js +1 -1
  549. package/js/themes/dark-blue.js +2 -2
  550. package/js/themes/dark-blue.src.js +3 -3
  551. package/js/themes/dark-green.js +2 -2
  552. package/js/themes/dark-green.src.js +3 -3
  553. package/js/themes/dark-unica.js +2 -2
  554. package/js/themes/dark-unica.src.js +3 -3
  555. package/js/themes/gray.js +2 -2
  556. package/js/themes/gray.src.js +3 -3
  557. package/js/themes/grid-light.js +2 -2
  558. package/js/themes/grid-light.src.js +3 -3
  559. package/js/themes/grid.js +2 -2
  560. package/js/themes/grid.src.js +3 -3
  561. package/js/themes/sand-signika.js +2 -2
  562. package/js/themes/sand-signika.src.js +3 -3
  563. package/js/themes/skies.js +2 -2
  564. package/js/themes/skies.src.js +3 -3
  565. package/js/themes/sunset.js +1 -1
  566. package/js/themes/sunset.src.js +1 -1
  567. package/modules/accessibility.js +1 -1
  568. package/modules/accessibility.src.js +1 -1
  569. package/modules/annotations.js +2 -2
  570. package/modules/annotations.src.js +2 -2
  571. package/modules/arrow-symbols.js +13 -0
  572. package/modules/arrow-symbols.js.map +1 -0
  573. package/modules/arrow-symbols.src.js +138 -0
  574. package/modules/boost-canvas.js +1 -1
  575. package/modules/boost-canvas.src.js +1 -1
  576. package/modules/boost.js +36 -36
  577. package/modules/boost.js.map +1 -1
  578. package/modules/boost.src.js +23 -15
  579. package/modules/broken-axis.js +11 -10
  580. package/modules/broken-axis.js.map +1 -1
  581. package/modules/broken-axis.src.js +171 -136
  582. package/modules/bullet.js +1 -1
  583. package/modules/bullet.src.js +1 -1
  584. package/modules/current-date-indicator.js +13 -0
  585. package/modules/current-date-indicator.js.map +1 -0
  586. package/modules/current-date-indicator.src.js +120 -0
  587. package/modules/data.js +2 -2
  588. package/modules/data.src.js +4 -4
  589. package/modules/drag-panes.js +1 -1
  590. package/modules/drag-panes.src.js +1 -1
  591. package/modules/draggable-points.js +38 -0
  592. package/modules/draggable-points.js.map +1 -0
  593. package/modules/draggable-points.src.js +2281 -0
  594. package/modules/drilldown.js +1 -1
  595. package/modules/drilldown.js.map +1 -1
  596. package/modules/drilldown.src.js +2 -1
  597. package/modules/export-data.js +2 -2
  598. package/modules/export-data.src.js +3 -3
  599. package/modules/exporting.js +2 -2
  600. package/modules/exporting.src.js +3 -3
  601. package/modules/funnel.js +2 -2
  602. package/modules/funnel.src.js +3 -3
  603. package/modules/gantt.js +83 -19
  604. package/modules/gantt.js.map +1 -1
  605. package/modules/gantt.src.js +5553 -379
  606. package/modules/grid-axis.js +16 -11
  607. package/modules/grid-axis.js.map +1 -1
  608. package/modules/grid-axis.src.js +732 -293
  609. package/modules/heatmap.js +2 -2
  610. package/modules/heatmap.js.map +1 -1
  611. package/modules/heatmap.src.js +128 -57
  612. package/modules/histogram-bellcurve.js +1 -1
  613. package/modules/histogram-bellcurve.src.js +1 -1
  614. package/modules/item-series.js +2 -2
  615. package/modules/item-series.src.js +3 -3
  616. package/modules/map.js +2 -2
  617. package/modules/map.js.map +1 -1
  618. package/modules/map.src.js +139 -68
  619. package/modules/no-data-to-display.js +1 -1
  620. package/modules/no-data-to-display.src.js +6 -6
  621. package/modules/offline-exporting.js +2 -2
  622. package/modules/offline-exporting.src.js +2 -2
  623. package/modules/oldie.js +2 -2
  624. package/modules/oldie.src.js +3 -3
  625. package/modules/overlapping-datalabels.js +2 -2
  626. package/modules/overlapping-datalabels.src.js +2 -2
  627. package/modules/parallel-coordinates.js +8 -8
  628. package/modules/parallel-coordinates.js.map +1 -1
  629. package/modules/parallel-coordinates.src.js +4 -3
  630. package/modules/pareto.js +1 -1
  631. package/modules/pareto.src.js +1 -1
  632. package/modules/pathfinder.js +35 -0
  633. package/modules/pathfinder.js.map +1 -0
  634. package/modules/pathfinder.src.js +2128 -0
  635. package/modules/pattern-fill.js +1 -1
  636. package/modules/pattern-fill.src.js +1 -1
  637. package/modules/sankey.js +2 -2
  638. package/modules/sankey.src.js +3 -3
  639. package/modules/series-label.js +2 -2
  640. package/modules/series-label.src.js +4 -4
  641. package/modules/solid-gauge.js +2 -2
  642. package/modules/solid-gauge.src.js +3 -3
  643. package/modules/static-scale.js +3 -3
  644. package/modules/static-scale.js.map +1 -1
  645. package/modules/static-scale.src.js +65 -26
  646. package/modules/stock.js +142 -142
  647. package/modules/stock.js.map +1 -1
  648. package/modules/stock.src.js +230 -157
  649. package/modules/streamgraph.js +2 -2
  650. package/modules/streamgraph.src.js +3 -3
  651. package/modules/sunburst.js +1 -1
  652. package/modules/sunburst.src.js +1 -1
  653. package/modules/tilemap.js +1 -1
  654. package/modules/tilemap.js.map +1 -1
  655. package/modules/tilemap.src.js +357 -189
  656. package/modules/treegrid.js +52 -0
  657. package/modules/treegrid.js.map +1 -0
  658. package/modules/treegrid.src.js +2797 -0
  659. package/modules/treemap.js +1 -1
  660. package/modules/treemap.src.js +1 -1
  661. package/modules/variable-pie.js +1 -1
  662. package/modules/variable-pie.src.js +1 -1
  663. package/modules/variwide.js +2 -2
  664. package/modules/variwide.src.js +3 -3
  665. package/modules/vector.js +2 -2
  666. package/modules/vector.js.map +1 -1
  667. package/modules/vector.src.js +94 -24
  668. package/modules/windbarb.js +2 -2
  669. package/modules/windbarb.src.js +4 -4
  670. package/modules/wordcloud.js +1 -1
  671. package/modules/wordcloud.src.js +1 -1
  672. package/modules/xrange.js +12 -11
  673. package/modules/xrange.js.map +1 -1
  674. package/modules/xrange.src.js +259 -79
  675. package/package.json +1 -1
  676. package/themes/avocado.js +1 -1
  677. package/themes/avocado.src.js +1 -1
  678. package/themes/dark-blue.js +2 -2
  679. package/themes/dark-blue.src.js +3 -3
  680. package/themes/dark-green.js +2 -2
  681. package/themes/dark-green.src.js +3 -3
  682. package/themes/dark-unica.js +2 -2
  683. package/themes/dark-unica.src.js +3 -3
  684. package/themes/gray.js +2 -2
  685. package/themes/gray.src.js +3 -3
  686. package/themes/grid-light.js +2 -2
  687. package/themes/grid-light.src.js +3 -3
  688. package/themes/grid.js +2 -2
  689. package/themes/grid.src.js +3 -3
  690. package/themes/sand-signika.js +2 -2
  691. package/themes/sand-signika.src.js +3 -3
  692. package/themes/skies.js +2 -2
  693. package/themes/skies.src.js +3 -3
  694. package/themes/sunset.js +1 -1
  695. package/themes/sunset.src.js +1 -1
@@ -0,0 +1,2281 @@
1
+ /**
2
+ * @license Highcharts JS v6.2.0 (2018-10-17)
3
+ *
4
+ * (c) 2009-2018 Torstein Honsi
5
+ *
6
+ * License: www.highcharts.com/license
7
+ */
8
+ 'use strict';
9
+ (function (factory) {
10
+ if (typeof module === 'object' && module.exports) {
11
+ module.exports = factory;
12
+ } else if (typeof define === 'function' && define.amd) {
13
+ define(function () {
14
+ return factory;
15
+ });
16
+ } else {
17
+ factory(Highcharts);
18
+ }
19
+ }(function (Highcharts) {
20
+ (function (H) {
21
+ /**
22
+ * (c) 2009-2018 Highsoft AS
23
+ * Authors: Øystein Moseng, Torstein Hønsi, Jon A. Nygård
24
+ *
25
+ * License: www.highcharts.com/license
26
+ */
27
+
28
+ var addEvent = H.addEvent,
29
+ each = H.each,
30
+ objectEach = H.objectEach,
31
+ pick = H.pick,
32
+ filter = H.grep,
33
+ merge = H.merge,
34
+ seriesTypes = H.seriesTypes;
35
+
36
+
37
+ /*
38
+ Add drag/drop support to specific data props for different series types.
39
+
40
+ The dragDrop.draggableX/Y user options on series enable/disable all of these
41
+ per direction unless they are specifically set in options using
42
+ dragDrop.{optionName}. If the prop does not specify an optionName here, it
43
+ can only be enabled/disabled by the user with draggableX/Y.
44
+
45
+ Supported options for each prop:
46
+ optionName: User option in series.dragDrop that enables/disables
47
+ dragging this prop.
48
+ axis: Can be 'x' or 'y'. Whether this prop is linked to x or y axis.
49
+ move: Whether or not this prop should be updated when moving points.
50
+ resize: Whether or not to draw a drag handle and allow user to drag and
51
+ update this prop by itself.
52
+ beforeResize: Hook to perform tasks before a resize is made. Gets
53
+ the guide box, the new points values, and the point as args.
54
+ resizeSide: Which side of the guide box to resize when dragging the
55
+ handle. Can be "left", "right", "top", "bottom". Chart.inverted is
56
+ handled automatically. Can also be a function, taking the new point
57
+ values as parameter, as well as the point, and returning a string
58
+ with the side.
59
+ propValidate: Function that takes the prop value and the point as
60
+ arguments, and returns true if the prop value is valid, false if
61
+ not. It is used to prevent e.g. resizing "low" above "high".
62
+ handlePositioner: For resizeable props, return 0,0 in SVG plot coords of
63
+ where to place the dragHandle. Gets point as argument. Should return
64
+ object with x and y properties.
65
+ handleFormatter: For resizeable props, return the path of the drag
66
+ handle as an SVG path array. Gets the point as argument. The handle
67
+ is translated according to handlePositioner.
68
+ handleOptions: Options to merge with the default handle options.
69
+
70
+ TODO:
71
+ - It makes sense to have support for resizing the size of bubbles and
72
+ e.g variwide columns. This requires us to support dragging along a
73
+ z-axis, somehow computing a relative value from old to new pixel
74
+ size.
75
+ - Moving maps could be useful, although we would have to compute new
76
+ point.path values in order to do it properly (using SVG translate
77
+ is easier, but won't update the data).
78
+ */
79
+
80
+ // 90deg rotated column handle path, used in multiple series types
81
+ var horizHandleFormatter = function (point) {
82
+ var shapeArgs = point.shapeArgs || point.graphic.getBBox(),
83
+ top = shapeArgs.r || 0, // Rounding of bar corners
84
+ bottom = shapeArgs.height - top,
85
+ centerY = shapeArgs.height / 2;
86
+ return [
87
+ // Top wick
88
+ 'M', 0, top,
89
+ 'L', 0, centerY - 5,
90
+ // Circle
91
+ 'A', 1, 1, 0, 0, 0, 0, centerY + 5,
92
+ 'A', 1, 1, 0, 0, 0, 0, centerY - 5,
93
+ // Bottom wick
94
+ 'M', 0, centerY + 5,
95
+ 'L', 0, bottom
96
+ ];
97
+ };
98
+
99
+ // Line series - only draggableX/Y, no drag handles
100
+ var lineDragDropProps = seriesTypes.line.prototype.dragDropProps = {
101
+ x: {
102
+ axis: 'x',
103
+ move: true
104
+ },
105
+ y: {
106
+ axis: 'y',
107
+ move: true
108
+ }
109
+ };
110
+
111
+ // Flag series - same as line/scatter
112
+ if (seriesTypes.flags) {
113
+ seriesTypes.flags.prototype.dragDropProps = lineDragDropProps;
114
+ }
115
+
116
+ // Column series - x can be moved, y can only be resized. Note extra
117
+ // functionality for handling upside down columns (below threshold).
118
+ var columnDragDropProps = seriesTypes.column.prototype.dragDropProps = {
119
+ x: {
120
+ axis: 'x',
121
+ move: true
122
+ },
123
+ y: {
124
+ axis: 'y',
125
+ move: false,
126
+ resize: true,
127
+ // Force guideBox start coordinates
128
+ beforeResize: function (guideBox, pointVals, point) {
129
+ // We need to ensure that guideBox always starts at threshold.
130
+ // We flip whether or not we update the top or bottom of the guide
131
+ // box at threshold, but if we drag the mouse fast, the top has not
132
+ // reached threshold before we cross over and update the bottom.
133
+ var threshold = point.series.translatedThreshold,
134
+ y = guideBox.attr('y'),
135
+ height,
136
+ diff;
137
+ if (pointVals.y >= point.series.options.threshold || 0) {
138
+ // Above threshold - always set height to hit the threshold
139
+ height = guideBox.attr('height');
140
+ diff = threshold ? threshold - (y + height) : 0;
141
+ guideBox.attr({
142
+ height: Math.max(0, Math.round(height + diff))
143
+ });
144
+ } else {
145
+ // Below - always set y to start at threshold
146
+ guideBox.attr({
147
+ y: Math.round(y + (threshold ? threshold - y : 0))
148
+ });
149
+ }
150
+ },
151
+ // Flip the side of the resize handle if column is below threshold
152
+ resizeSide: function (pointVals, point) {
153
+ return pointVals.y >= (point.series.options.threshold || 0) ?
154
+ 'top' : 'bottom';
155
+ },
156
+ // Position handle at bottom if column is below threshold
157
+ handlePositioner: function (point) {
158
+ var bBox = point.shapeArgs || point.graphic.getBBox();
159
+ return {
160
+ x: bBox.x,
161
+ y: point.y >= (point.series.options.threshold || 0) ?
162
+ bBox.y : bBox.y + bBox.height
163
+ };
164
+ },
165
+ // Horizontal handle
166
+ handleFormatter: function (point) {
167
+ var shapeArgs = point.shapeArgs,
168
+ radius = shapeArgs.r || 0, // Rounding of bar corners
169
+ centerX = shapeArgs.width / 2;
170
+ return [
171
+ // Left wick
172
+ 'M', radius, 0,
173
+ 'L', centerX - 5, 0,
174
+ // Circle
175
+ 'A', 1, 1, 0, 0, 0, centerX + 5, 0,
176
+ 'A', 1, 1, 0, 0, 0, centerX - 5, 0,
177
+ // Right wick
178
+ 'M', centerX + 5, 0,
179
+ 'L', shapeArgs.width - radius, 0
180
+ ];
181
+ }
182
+ }
183
+ };
184
+
185
+ // Bullet graph, x/y same as column, but also allow target to be dragged.
186
+ if (seriesTypes.bullet) {
187
+ seriesTypes.bullet.prototype.dragDropProps = {
188
+ x: columnDragDropProps.x,
189
+ y: columnDragDropProps.y,
190
+ target: {
191
+ /**
192
+ * Allow target value to be dragged individually. Requires
193
+ * `draggable-points` module.
194
+ *
195
+ * @type {boolean}
196
+ * @default true
197
+ * @apioption plotOptions.bullet.dragDrop.draggableTarget
198
+ */
199
+ optionName: 'draggableTarget',
200
+ axis: 'y',
201
+ move: true,
202
+ resize: true,
203
+ resizeSide: 'top',
204
+ handlePositioner: function (point) {
205
+ var bBox = point.targetGraphic.getBBox();
206
+ return {
207
+ x: point.barX,
208
+ y: bBox.y + bBox.height / 2
209
+ };
210
+ },
211
+ handleFormatter: columnDragDropProps.y.handleFormatter
212
+ }
213
+ };
214
+ }
215
+
216
+ // Columnrange series - move x, resize or move low/high
217
+ if (seriesTypes.columnrange) {
218
+ seriesTypes.columnrange.prototype.dragDropProps = {
219
+ x: {
220
+ axis: 'x',
221
+ move: true
222
+ },
223
+ low: {
224
+ /**
225
+ * Allow low value to be dragged individually. Requires
226
+ * `draggable-points` module.
227
+ *
228
+ * @type {boolean}
229
+ * @default true
230
+ * @apioption plotOptions.columnrange.dragDrop.draggableLow
231
+ */
232
+ optionName: 'draggableLow',
233
+ axis: 'y',
234
+ move: true,
235
+ resize: true,
236
+ resizeSide: 'bottom',
237
+ handlePositioner: function (point) {
238
+ var bBox = point.shapeArgs || point.graphic.getBBox();
239
+ return {
240
+ x: bBox.x,
241
+ y: bBox.y + bBox.height
242
+ };
243
+ },
244
+ handleFormatter: columnDragDropProps.y.handleFormatter,
245
+ propValidate: function (val, point) {
246
+ return val <= point.high;
247
+ }
248
+ },
249
+ high: {
250
+ /**
251
+ * Allow high value to be dragged individually. Requires
252
+ * `draggable-points` module.
253
+ *
254
+ * @type {boolean}
255
+ * @default true
256
+ * @apioption plotOptions.columnrange.dragDrop.draggableHigh
257
+ */
258
+ optionName: 'draggableHigh',
259
+ axis: 'y',
260
+ move: true,
261
+ resize: true,
262
+ resizeSide: 'top',
263
+ handlePositioner: function (point) {
264
+ var bBox = point.shapeArgs || point.graphic.getBBox();
265
+ return {
266
+ x: bBox.x,
267
+ y: bBox.y
268
+ };
269
+ },
270
+ handleFormatter: columnDragDropProps.y.handleFormatter,
271
+ propValidate: function (val, point) {
272
+ return val >= point.low;
273
+ }
274
+ }
275
+ };
276
+ }
277
+
278
+ // Boxplot series - move x, resize or move low/q1/q3/high
279
+ if (seriesTypes.boxplot) {
280
+ seriesTypes.boxplot.prototype.dragDropProps = {
281
+ x: columnDragDropProps.x,
282
+ low: {
283
+ /**
284
+ * Allow low value to be dragged individually. Requires
285
+ * `draggable-points` module.
286
+ *
287
+ * @type {boolean}
288
+ * @default true
289
+ * @apioption plotOptions.boxplot.dragDrop.draggableLow
290
+ */
291
+ optionName: 'draggableLow',
292
+ axis: 'y',
293
+ move: true,
294
+ resize: true,
295
+ resizeSide: 'bottom',
296
+ handlePositioner: function (point) {
297
+ return {
298
+ x: point.shapeArgs.x,
299
+ y: point.lowPlot
300
+ };
301
+ },
302
+ handleFormatter: columnDragDropProps.y.handleFormatter,
303
+ propValidate: function (val, point) {
304
+ return val <= point.q1;
305
+ }
306
+ },
307
+ q1: {
308
+ /**
309
+ * Allow Q1 value to be dragged individually. Requires
310
+ * `draggable-points` module.
311
+ *
312
+ * @type {boolean}
313
+ * @default true
314
+ * @apioption plotOptions.boxplot.dragDrop.draggableQ1
315
+ */
316
+ optionName: 'draggableQ1',
317
+ axis: 'y',
318
+ move: true,
319
+ resize: true,
320
+ resizeSide: 'bottom',
321
+ handlePositioner: function (point) {
322
+ return {
323
+ x: point.shapeArgs.x,
324
+ y: point.q1Plot
325
+ };
326
+ },
327
+ handleFormatter: columnDragDropProps.y.handleFormatter,
328
+ propValidate: function (val, point) {
329
+ return val <= point.median && val >= point.low;
330
+ }
331
+ },
332
+ median: {
333
+ // Median can not be dragged individually, just move the whole
334
+ // point for this.
335
+ axis: 'y',
336
+ move: true
337
+ },
338
+ q3: {
339
+ /**
340
+ * Allow Q3 value to be dragged individually. Requires
341
+ * `draggable-points` module.
342
+ *
343
+ * @type {boolean}
344
+ * @default true
345
+ * @apioption plotOptions.boxplot.dragDrop.draggableQ3
346
+ */
347
+ optionName: 'draggableQ3',
348
+ axis: 'y',
349
+ move: true,
350
+ resize: true,
351
+ resizeSide: 'top',
352
+ handlePositioner: function (point) {
353
+ return {
354
+ x: point.shapeArgs.x,
355
+ y: point.q3Plot
356
+ };
357
+ },
358
+ handleFormatter: columnDragDropProps.y.handleFormatter,
359
+ propValidate: function (val, point) {
360
+ return val <= point.high && val >= point.median;
361
+ }
362
+ },
363
+ /**
364
+ * Allow high value to be dragged individually. Requires
365
+ * `draggable-points` module.
366
+ *
367
+ * @type {boolean}
368
+ * @default true
369
+ * @apioption plotOptions.boxplot.dragDrop.draggableHigh
370
+ */
371
+ high: {
372
+ optionName: 'draggableHigh',
373
+ axis: 'y',
374
+ move: true,
375
+ resize: true,
376
+ resizeSide: 'top',
377
+ handlePositioner: function (point) {
378
+ return {
379
+ x: point.shapeArgs.x,
380
+ y: point.highPlot
381
+ };
382
+ },
383
+ handleFormatter: columnDragDropProps.y.handleFormatter,
384
+ propValidate: function (val, point) {
385
+ return val >= point.q3;
386
+ }
387
+ }
388
+ };
389
+ }
390
+
391
+
392
+ // OHLC series - move x, resize or move open/high/low/close
393
+ if (seriesTypes.ohlc) {
394
+ seriesTypes.ohlc.prototype.dragDropProps = {
395
+ x: columnDragDropProps.x,
396
+ low: {
397
+ /**
398
+ * Allow low value to be dragged individually. Requires
399
+ * `draggable-points` module.
400
+ *
401
+ * @type {boolean}
402
+ * @default true
403
+ * @apioption plotOptions.ohlc.dragDrop.draggableLow
404
+ */
405
+ optionName: 'draggableLow',
406
+ axis: 'y',
407
+ move: true,
408
+ resize: true,
409
+ resizeSide: 'bottom',
410
+ handlePositioner: function (point) {
411
+ return {
412
+ x: point.shapeArgs.x,
413
+ y: point.plotLow
414
+ };
415
+ },
416
+ handleFormatter: columnDragDropProps.y.handleFormatter,
417
+ propValidate: function (val, point) {
418
+ return val <= point.open && val <= point.close;
419
+ }
420
+ },
421
+ high: {
422
+ /**
423
+ * Allow high value to be dragged individually. Requires
424
+ * `draggable-points` module.
425
+ *
426
+ * @type {boolean}
427
+ * @default true
428
+ * @apioption plotOptions.ohlc.dragDrop.draggableHigh
429
+ */
430
+ optionName: 'draggableHigh',
431
+ axis: 'y',
432
+ move: true,
433
+ resize: true,
434
+ resizeSide: 'top',
435
+ handlePositioner: function (point) {
436
+ return {
437
+ x: point.shapeArgs.x,
438
+ y: point.plotHigh
439
+ };
440
+ },
441
+ handleFormatter: columnDragDropProps.y.handleFormatter,
442
+ propValidate: function (val, point) {
443
+ return val >= point.open && val >= point.close;
444
+ }
445
+ },
446
+ open: {
447
+ /**
448
+ * Allow open value to be dragged individually. Requires
449
+ * `draggable-points` module.
450
+ *
451
+ * @type {boolean}
452
+ * @default true
453
+ * @apioption plotOptions.ohlc.dragDrop.draggableOpen
454
+ */
455
+ optionName: 'draggableOpen',
456
+ axis: 'y',
457
+ move: true,
458
+ resize: true,
459
+ resizeSide: function (point) {
460
+ return point.open >= point.close ? 'top' : 'bottom';
461
+ },
462
+ handlePositioner: function (point) {
463
+ return {
464
+ x: point.shapeArgs.x,
465
+ y: point.plotOpen
466
+ };
467
+ },
468
+ handleFormatter: columnDragDropProps.y.handleFormatter,
469
+ propValidate: function (val, point) {
470
+ return val <= point.high && val >= point.low;
471
+ }
472
+ },
473
+ close: {
474
+ /**
475
+ * Allow close value to be dragged individually. Requires
476
+ * `draggable-points` module.
477
+ *
478
+ * @type {boolean}
479
+ * @default true
480
+ * @apioption plotOptions.ohlc.dragDrop.draggableClose
481
+ */
482
+ optionName: 'draggableClose',
483
+ axis: 'y',
484
+ move: true,
485
+ resize: true,
486
+ resizeSide: function (point) {
487
+ return point.open >= point.close ? 'bottom' : 'top';
488
+ },
489
+ handlePositioner: function (point) {
490
+ return {
491
+ x: point.shapeArgs.x,
492
+ y: point.plotClose
493
+ };
494
+ },
495
+ handleFormatter: columnDragDropProps.y.handleFormatter,
496
+ propValidate: function (val, point) {
497
+ return val <= point.high && val >= point.low;
498
+ }
499
+ }
500
+ };
501
+ }
502
+
503
+ // Arearange series - move x, resize or move low/high
504
+ if (seriesTypes.arearange) {
505
+ var columnrangeDragDropProps = seriesTypes.columnrange
506
+ .prototype.dragDropProps,
507
+ // Use a circle covering the marker as drag handle
508
+ arearangeHandleFormatter = function (point) {
509
+ var radius = point.graphic ?
510
+ point.graphic.getBBox().width / 2 + 1 :
511
+ 4;
512
+ return [
513
+ 'M', 0 - radius, 0,
514
+ 'a', radius, radius, 0, 1, 0, radius * 2, 0,
515
+ 'a', radius, radius, 0, 1, 0, radius * -2, 0
516
+ ];
517
+ };
518
+ seriesTypes.arearange.prototype.dragDropProps = {
519
+ x: columnrangeDragDropProps.x,
520
+ low: {
521
+ /**
522
+ * Allow low value to be dragged individually. Requires
523
+ * `draggable-points` module.
524
+ *
525
+ * @type {boolean}
526
+ * @default true
527
+ * @apioption plotOptions.arearange.dragDrop.draggableLow
528
+ */
529
+ optionName: 'draggableLow',
530
+ axis: 'y',
531
+ move: true,
532
+ resize: true,
533
+ resizeSide: 'bottom',
534
+ handlePositioner: function (point) {
535
+ var bBox = point.lowerGraphic && point.lowerGraphic.getBBox();
536
+ return bBox ? {
537
+ x: bBox.x + bBox.width / 2,
538
+ y: bBox.y + bBox.height / 2
539
+ } : { x: -999, y: -999 };
540
+ },
541
+ handleFormatter: arearangeHandleFormatter,
542
+ propValidate: columnrangeDragDropProps.low.propValidate
543
+ },
544
+ high: {
545
+ /**
546
+ * Allow high value to be dragged individually. Requires
547
+ * `draggable-points` module.
548
+ *
549
+ * @type {boolean}
550
+ * @default true
551
+ * @apioption plotOptions.arearange.dragDrop.draggableHigh
552
+ */
553
+ optionName: 'draggableHigh',
554
+ axis: 'y',
555
+ move: true,
556
+ resize: true,
557
+ resizeSide: 'top',
558
+ handlePositioner: function (point) {
559
+ var bBox = point.upperGraphic && point.upperGraphic.getBBox();
560
+ return bBox ? {
561
+ x: bBox.x + bBox.width / 2,
562
+ y: bBox.y + bBox.height / 2
563
+ } : { x: -999, y: -999 };
564
+ },
565
+ handleFormatter: arearangeHandleFormatter,
566
+ propValidate: columnrangeDragDropProps.high.propValidate
567
+ }
568
+ };
569
+ }
570
+
571
+ // Waterfall - mostly as column, but don't show drag handles for sum points
572
+ if (seriesTypes.waterfall) {
573
+ seriesTypes.waterfall.prototype.dragDropProps = {
574
+ x: columnDragDropProps.x,
575
+ y: merge(columnDragDropProps.y, {
576
+ handleFormatter: function (point) {
577
+ return point.isSum || point.isIntermediateSum ? null :
578
+ columnDragDropProps.y.handleFormatter(point);
579
+ }
580
+ })
581
+ };
582
+ }
583
+
584
+ // Xrange - resize/move x/x2, and move y
585
+ if (seriesTypes.xrange) {
586
+ // Handle positioner logic is the same for x and x2 apart from the
587
+ // x value. shapeArgs does not take yAxis reversed etc into account, so we
588
+ // use axis.toPixels to handle positioning.
589
+ var xrangeHandlePositioner = function (point, xProp) {
590
+ var series = point.series,
591
+ xAxis = series.xAxis,
592
+ yAxis = series.yAxis,
593
+ inverted = series.chart.inverted,
594
+ // Using toPixels handles axis.reversed, but doesn't take
595
+ // chart.inverted into account.
596
+ newX = xAxis.toPixels(point[xProp], true),
597
+ newY = yAxis.toPixels(point.y, true);
598
+
599
+ // Handle chart inverted
600
+ if (inverted) {
601
+ newX = xAxis.len - newX;
602
+ newY = yAxis.len - newY -
603
+ point.shapeArgs.height / 2;
604
+ } else {
605
+ newY -= point.shapeArgs.height / 2;
606
+ }
607
+
608
+ return {
609
+ x: Math.round(newX),
610
+ y: Math.round(newY)
611
+ };
612
+ },
613
+ xrangeDragDropProps = seriesTypes.xrange.prototype.dragDropProps = {
614
+ y: {
615
+ axis: 'y',
616
+ move: true
617
+ },
618
+ x: {
619
+ /**
620
+ * Allow x value to be dragged individually. Requires
621
+ * `draggable-points` module.
622
+ *
623
+ * @type {boolean}
624
+ * @default true
625
+ * @apioption plotOptions.xrange.dragDrop.draggableX1
626
+ */
627
+ optionName: 'draggableX1',
628
+ axis: 'x',
629
+ move: true,
630
+ resize: true,
631
+ resizeSide: 'left',
632
+ handlePositioner: function (point) {
633
+ return xrangeHandlePositioner(point, 'x');
634
+ },
635
+ handleFormatter: horizHandleFormatter,
636
+ propValidate: function (val, point) {
637
+ return val <= point.x2;
638
+ }
639
+ },
640
+ x2: {
641
+ /**
642
+ * Allow x2 value to be dragged individually. Requires
643
+ * `draggable-points` module.
644
+ *
645
+ * @type {boolean}
646
+ * @default true
647
+ * @apioption plotOptions.xrange.dragDrop.draggableX2
648
+ */
649
+ optionName: 'draggableX2',
650
+ axis: 'x',
651
+ move: true,
652
+ resize: true,
653
+ resizeSide: 'right',
654
+ handlePositioner: function (point) {
655
+ return xrangeHandlePositioner(point, 'x2');
656
+ },
657
+ handleFormatter: horizHandleFormatter,
658
+ propValidate: function (val, point) {
659
+ return val >= point.x;
660
+ }
661
+ }
662
+ };
663
+ }
664
+
665
+ // Gantt - same as xrange, but with aliases
666
+ if (seriesTypes.gantt) {
667
+ seriesTypes.gantt.prototype.dragDropProps = {
668
+ y: xrangeDragDropProps.y,
669
+ start: merge(xrangeDragDropProps.x, {
670
+ /**
671
+ * Allow start value to be dragged individually. Requires
672
+ * `draggable-points` module.
673
+ *
674
+ * @type {boolean}
675
+ * @default true
676
+ * @apioption plotOptions.gantt.dragDrop.draggableStart
677
+ */
678
+ optionName: 'draggableStart',
679
+
680
+ // Do not allow individual drag handles for milestones
681
+ validateIndividualDrag: function (point) {
682
+ return !point.milestone;
683
+ }
684
+ }),
685
+ end: merge(xrangeDragDropProps.x2, {
686
+ /**
687
+ * Allow end value to be dragged individually. Requires
688
+ * `draggable-points` module.
689
+ *
690
+ * @type {boolean}
691
+ * @default true
692
+ * @apioption plotOptions.gantt.dragDrop.draggableEnd
693
+ */
694
+ optionName: 'draggableEnd',
695
+
696
+ // Do not allow individual drag handles for milestones
697
+ validateIndividualDrag: function (point) {
698
+ return !point.milestone;
699
+ }
700
+ })
701
+ };
702
+ }
703
+
704
+ // Don't support certain series types
705
+ each(
706
+ ['gauge', 'pie', 'sunburst', 'wordcloud', 'sankey', 'histogram', 'pareto',
707
+ 'vector', 'windbarb', 'treemap', 'bellcurve', 'sma', 'map', 'mapline'],
708
+ function (type) {
709
+ if (seriesTypes[type]) {
710
+ seriesTypes[type].prototype.dragDropProps = null;
711
+ }
712
+ }
713
+ );
714
+
715
+ /**
716
+ * The draggable-points module allows points to be moved around or modified
717
+ * in the chart. In addition to the options mentioned under the `dragDrop`
718
+ * API structure, the module fires three events,
719
+ * [point.dragStart](series.line.point.events.dragStart),
720
+ * [point.drag](series.line.point.events.drag) and
721
+ * [point.drop](series.line.point.events.drop).
722
+ *
723
+ * It requires the `modules/draggable-points.js` file to be loaded.
724
+ *
725
+ * @type {object}
726
+ * @since 6.2.0
727
+ *
728
+ * @sample highcharts/dragdrop/resize-column Draggable column and line series
729
+ *
730
+ * @sample highcharts/dragdrop/drag-bubble Draggable bubbles
731
+ *
732
+ * @sample highcharts/dragdrop/drag-xrang Draggable X range series
733
+ *
734
+ * @apioption plotOptions.series.dragDrop
735
+ */
736
+
737
+ /**
738
+ * The amount of pixels to drag the pointer before it counts as a drag
739
+ * operation. This prevents drag/drop to fire when just clicking or selecting
740
+ * points.
741
+ *
742
+ * @type {number}
743
+ * @default 2
744
+ * @since 6.2.0
745
+ * @apioption plotOptions.series.dragDrop.dragSensitivity
746
+ */
747
+ var defaultDragSensitivity = 2;
748
+
749
+ /**
750
+ * Style options for the guide box. The guide box has one state by default,
751
+ * the "default" state.
752
+ *
753
+ * @type {object}
754
+ * @since 6.2.0
755
+ * @apioption plotOptions.series.dragDrop.guideBox
756
+ */
757
+ var defaultGuideBoxOptions = {
758
+ /**
759
+ * Style options for the guide box default state.
760
+ *
761
+ * @type {object}
762
+ * @since 6.2.0
763
+ * @apioption plotOptions.series.dragDrop.guideBox.default
764
+ */
765
+ default: {
766
+ /**
767
+ * CSS class name of the guide box in this state. Defaults to
768
+ * `highcharts-drag-box-default`.
769
+ *
770
+ * @type {String}
771
+ * @since 6.2.0
772
+ * @apioption plotOptions.series.dragDrop.guideBox.default.className
773
+ */
774
+ className: 'highcharts-drag-box-default',
775
+
776
+ /**
777
+ * Width of the line around the guide box.
778
+ *
779
+ * @type {number}
780
+ * @default 1
781
+ * @since 6.2.0
782
+ * @apioption plotOptions.series.dragDrop.guideBox.default.lineWidth
783
+ */
784
+ lineWidth: 1,
785
+
786
+ /**
787
+ * Color of the border around the guide box.
788
+ *
789
+ * @type {Color}
790
+ * @since 6.2.0
791
+ * @default #888
792
+ * @apioption plotOptions.series.dragDrop.guideBox.default.lineColor
793
+ */
794
+ lineColor: '#888',
795
+
796
+ /**
797
+ * Guide box fill color.
798
+ *
799
+ * @type {Color}
800
+ * @since 6.2.0
801
+ * @default rgba(0, 0, 0, 0.1)
802
+ * @apioption plotOptions.series.dragDrop.guideBox.default.color
803
+ */
804
+ color: 'rgba(0, 0, 0, 0.1)',
805
+
806
+ /**
807
+ * Guide box cursor.
808
+ *
809
+ * @type {string}
810
+ * @default move
811
+ * @since 6.2.0
812
+ * @apioption plotOptions.series.dragDrop.guideBox.default.cursor
813
+ */
814
+ cursor: 'move',
815
+
816
+ /**
817
+ * Guide box zIndex.
818
+ *
819
+ * @type {number}
820
+ * @since 6.2.0
821
+ * @default 900
822
+ * @apioption plotOptions.series.dragDrop.guideBox.default.zIndex
823
+ */
824
+ zIndex: 900
825
+ }
826
+ };
827
+
828
+
829
+ /**
830
+ * Options for the drag handles.
831
+ *
832
+ * @type {Object}
833
+ * @since 6.2.0
834
+ * @apioption plotOptions.series.dragDrop.dragHandle
835
+ */
836
+ var defaultDragHandleOptions = {
837
+
838
+ /**
839
+ * Function to define the SVG path to use for the drag handles. Takes
840
+ * the point as argument. Should return an SVG path in array format. The
841
+ * SVG path is automatically positioned on the point.
842
+ *
843
+ * @type {Function}
844
+ * @since 6.2.0
845
+ * @apioption plotOptions.series.dragDrop.dragHandle.pathFormatter
846
+ */
847
+ // pathFormatter: null,
848
+
849
+ /**
850
+ * The mouse cursor to use for the drag handles. By default this is
851
+ * intelligently switching between `ew-resize` and `ns-resize` depending
852
+ * on the direction the point is being dragged.
853
+ *
854
+ * @type {String}
855
+ * @since 6.2.0
856
+ * @apioption plotOptions.series.dragDrop.dragHandle.cursor
857
+ */
858
+ // cursor: null,
859
+
860
+ /**
861
+ * The class name of the drag handles. Defaults to `highcharts-drag-handle`.
862
+ *
863
+ * @type {String}
864
+ * @since 6.2.0
865
+ * @apioption plotOptions.series.dragDrop.dragHandle.className
866
+ */
867
+ className: 'highcharts-drag-handle',
868
+
869
+ /**
870
+ * The fill color of the drag handles.
871
+ *
872
+ * @type {Color}
873
+ * @since 6.2.0
874
+ * @default #fff
875
+ * @apioption plotOptions.series.dragDrop.dragHandle.color
876
+ */
877
+ color: '#fff',
878
+
879
+ /**
880
+ * The line color of the drag handles.
881
+ *
882
+ * @type {Color}
883
+ * @since 6.2.0
884
+ * @default rgba(0, 0, 0, 0.6)
885
+ * @apioption plotOptions.series.dragDrop.dragHandle.lineColor
886
+ */
887
+ lineColor: 'rgba(0, 0, 0, 0.6)',
888
+
889
+ /**
890
+ * The line width for the drag handles.
891
+ *
892
+ * @type {number}
893
+ * @default 2
894
+ * @since 6.2.0
895
+ * @apioption plotOptions.series.dragDrop.dragHandle.lineWidth
896
+ */
897
+ lineWidth: 1,
898
+
899
+ /**
900
+ * The z index for the drag handles.
901
+ *
902
+ * @type {number}
903
+ * @since 6.2.0
904
+ * @default 901
905
+ * @apioption plotOptions.series.dragDrop.dragHandle.zIndex
906
+ */
907
+ zIndex: 901
908
+ };
909
+
910
+ /**
911
+ * Set the minimum X value the points can be moved to.
912
+ *
913
+ * @type {number}
914
+ * @since 6.2.0
915
+ * @apioption plotOptions.series.dragDrop.dragMinX
916
+ */
917
+
918
+ /**
919
+ * Set the maximum X value the points can be moved to.
920
+ *
921
+ * @type {number}
922
+ * @since 6.2.0
923
+ * @apioption plotOptions.series.dragDrop.dragMaxX
924
+ */
925
+
926
+ /**
927
+ * Set the minimum Y value the points can be moved to.
928
+ *
929
+ * @type {number}
930
+ * @since 6.2.0
931
+ * @apioption plotOptions.series.dragDrop.dragMinY
932
+ */
933
+
934
+ /**
935
+ * Set the maximum Y value the points can be moved to.
936
+ *
937
+ * @type {number}
938
+ * @since 6.2.0
939
+ * @apioption plotOptions.series.dragDrop.dragMaxY
940
+ */
941
+
942
+ /**
943
+ * The X precision value to drag to for this series. Set to 0 to disable. By
944
+ * default this is disabled, except for category axes, where the default is 1.
945
+ *
946
+ * @type {number}
947
+ * @default 0
948
+ * @since 6.2.0
949
+ * @apioption plotOptions.series.dragDrop.dragPrecisionX
950
+ */
951
+
952
+ /**
953
+ * The Y precision value to drag to for this series. Set to 0 to disable. By
954
+ * default this is disabled, except for category axes, where the default is 1.
955
+ *
956
+ * @type {number}
957
+ * @default 0
958
+ * @since 6.2.0
959
+ * @apioption plotOptions.series.dragDrop.dragPrecisionY
960
+ */
961
+
962
+ /**
963
+ * Enable dragging in the X dimension.
964
+ *
965
+ * @type {boolean}
966
+ * @since 6.2.0
967
+ * @apioption plotOptions.series.dragDrop.draggableX
968
+ */
969
+
970
+ /**
971
+ * Enable dragging in the Y dimension. Note that this is not supported for
972
+ * TreeGrid axes (the default axis type in Gantt charts).
973
+ *
974
+ * @type {boolean}
975
+ * @since 6.2.0
976
+ * @apioption plotOptions.series.dragDrop.draggableY
977
+ */
978
+
979
+ /**
980
+ * Group the points by a property. Points with the same property value will be
981
+ * grouped together when moving.
982
+ *
983
+ * @type {String}
984
+ * @since 6.2.0
985
+ * @apioption plotOptions.series.dragDrop.groupBy
986
+ */
987
+
988
+ /**
989
+ * Update points as they are dragged. If false, a guide box is drawn to
990
+ * illustrate the new point size.
991
+ *
992
+ * @type {boolean}
993
+ * @default true
994
+ * @since 6.2.0
995
+ * @apioption plotOptions.series.dragDrop.liveRedraw
996
+ */
997
+
998
+ /**
999
+ * Set a key to hold when dragging to zoom the chart. Requires the
1000
+ * draggable-points module. This is useful to avoid zooming while moving points.
1001
+ * Should be set different than [chart.panKey](#chart.panKey).
1002
+ *
1003
+ * @type {String}
1004
+ * @validvalue ["alt", "ctrl", "meta", "shift"]
1005
+ * @since 6.2.0
1006
+ * @apioption chart.zoomKey
1007
+ */
1008
+
1009
+ /**
1010
+ * Callback that fires when starting to drag a point. The mouse event object is
1011
+ * passed in as an argument. See [drag and drop options](series.line.dragDrop).
1012
+ *
1013
+ * Requires the draggable-points module.
1014
+ *
1015
+ * @type {Function}
1016
+ * @since 6.2.0
1017
+ * @apioption plotOptions.series.point.events.dragStart
1018
+ */
1019
+
1020
+ /**
1021
+ * Callback that fires while dragging a point. The mouse event is passed in as
1022
+ * parameter. The original data can be accessed from `e.origin`, and the new
1023
+ * point values can be accessed from `e.newPoints`. If there is only a single
1024
+ * point being updated, it can be accessed from `e.newPoint` for simplicity. To
1025
+ * stop the default drag action, return `false`. See
1026
+ * [drag and drop options](series.line.dragDrop).
1027
+ *
1028
+ * Requires the draggable-points module.
1029
+ *
1030
+ * @type {Function}
1031
+ * @since 6.2.0
1032
+ * @apioption plotOptions.series.point.events.drag
1033
+ */
1034
+
1035
+ /**
1036
+ * Callback that fires when the point is dropped. The mouse event is passed in
1037
+ * as parameter. The original data can be accessed from `e.origin`, and the new
1038
+ * point values can be accessed from `e.newPoints`. If there is only a single
1039
+ * point being updated, it can be accessed from `e.newPoint` for simplicity. To
1040
+ * stop the default drop action, return `false`. See
1041
+ * [drag and drop options](series.line.dragDrop).
1042
+ *
1043
+ * Requires the draggable-points module.
1044
+ *
1045
+ * @type {Function}
1046
+ * @since 6.2.0
1047
+ * @apioption plotOptions.series.point.events.drop
1048
+ */
1049
+
1050
+ /**
1051
+ * Point specific options for the draggable-points module. Overrides options on
1052
+ * `series.dragDrop`.
1053
+ *
1054
+ * Requires the draggable-points module.
1055
+ *
1056
+ * @extends plotOptions.series.dragDrop
1057
+ * @since 6.2.0
1058
+ * @apioption series.line.data.dragDrop
1059
+ */
1060
+
1061
+
1062
+ /**
1063
+ * Utility function to test if a series is using drag/drop, looking at its
1064
+ * options.
1065
+ *
1066
+ * @private
1067
+ * @param {Highcharts.Series} series
1068
+ * The series to test.
1069
+ *
1070
+ * @return {boolean}
1071
+ * True if the series is using drag/drop.
1072
+ */
1073
+ function isSeriesDraggable(series) {
1074
+ var props = ['draggableX', 'draggableY'],
1075
+ i;
1076
+
1077
+ // Add optionNames from dragDropProps to the array of props to check for
1078
+ objectEach(series.dragDropProps, function (val) {
1079
+ if (val.optionName) {
1080
+ props.push(val.optionName);
1081
+ }
1082
+ });
1083
+
1084
+ // Loop over all options we have that could enable dragDrop for this
1085
+ // series. If any of them are truthy, this series is draggable.
1086
+ i = props.length;
1087
+ while (i--) {
1088
+ if (series.options.dragDrop[props[i]]) {
1089
+ return true;
1090
+ }
1091
+ }
1092
+ }
1093
+
1094
+
1095
+ /**
1096
+ * Utility function to test if a chart should have drag/drop enabled, looking
1097
+ * at its options.
1098
+ *
1099
+ * @private
1100
+ * @param {Highcharts.Chart} chart
1101
+ * The chart to test.
1102
+ *
1103
+ * @return {boolean}
1104
+ * True if the chart is drag/droppable.
1105
+ */
1106
+ function isChartDraggable(chart) {
1107
+ var i = chart.series.length;
1108
+ if (chart.hasCartesianSeries && !chart.polar) {
1109
+ while (i--) {
1110
+ if (
1111
+ chart.series[i].options.dragDrop &&
1112
+ isSeriesDraggable(chart.series[i])
1113
+ ) {
1114
+ return true;
1115
+ }
1116
+ }
1117
+ }
1118
+ }
1119
+
1120
+
1121
+ /**
1122
+ * Utility function to test if a point is movable (any of its props can be
1123
+ * dragged by a move, not just individually).
1124
+ *
1125
+ * @private
1126
+ * @param {Highcharts.Point} point
1127
+ * The point to test.
1128
+ *
1129
+ * @return {boolean}
1130
+ * True if the point is movable.
1131
+ */
1132
+ function isPointMovable(point) {
1133
+ var series = point.series,
1134
+ seriesDragDropOptions = series.options.dragDrop,
1135
+ pointDragDropOptions = point.options && point.options.dragDrop,
1136
+ updateProps = series.dragDropProps,
1137
+ hasMovableX,
1138
+ hasMovableY;
1139
+
1140
+ objectEach(updateProps, function (p) {
1141
+ if (p.axis === 'x' && p.move) {
1142
+ hasMovableX = true;
1143
+ } else if (p.axis === 'y' && p.move) {
1144
+ hasMovableY = true;
1145
+ }
1146
+ });
1147
+
1148
+ // We can only move the point if draggableX/Y is set, even if all the
1149
+ // individual prop options are set.
1150
+ return (
1151
+ seriesDragDropOptions.draggableX && hasMovableX ||
1152
+ seriesDragDropOptions.draggableY && hasMovableY
1153
+ ) &&
1154
+ !(
1155
+ pointDragDropOptions &&
1156
+ pointDragDropOptions.draggableX === false &&
1157
+ pointDragDropOptions.draggableY === false
1158
+ ) &&
1159
+ series.yAxis &&
1160
+ series.xAxis;
1161
+ }
1162
+
1163
+
1164
+ /**
1165
+ * In mousemove events, check that we have dragged mouse further than the
1166
+ * dragSensitivity before we call mouseMove handler.
1167
+ *
1168
+ * @private
1169
+ * @param {global.Event} e
1170
+ * Mouse move event to test.
1171
+ *
1172
+ * @param {Highcharts.Chart} chart
1173
+ * Chart that has started dragging.
1174
+ *
1175
+ * @param {number} sensitivity
1176
+ * Pixel sensitivity to test against.
1177
+ *
1178
+ * @return {boolean}
1179
+ * True if the event is moved past sensitivity relative to the chart's
1180
+ * drag origin.
1181
+ */
1182
+ function hasDraggedPastSensitivity(e, chart, sensitivity) {
1183
+ var orig = chart.dragDropData.origin,
1184
+ oldX = orig.pageX,
1185
+ oldY = orig.pageY,
1186
+ newX = e.pageX,
1187
+ newY = e.pageY,
1188
+ distance = Math.sqrt(
1189
+ (newX - oldX) * (newX - oldX) +
1190
+ (newY - oldY) * (newY - oldY)
1191
+ );
1192
+ return distance > sensitivity;
1193
+ }
1194
+
1195
+
1196
+ /**
1197
+ * Get a snapshot of points, mouse position, and guide box dimensions
1198
+ *
1199
+ * @private
1200
+ * @param {global.Event} e
1201
+ * Mouse event with mouse position to snapshot.
1202
+ *
1203
+ * @param {Array<Highcharts.Point>} points
1204
+ * Points to take snapshot of. We store the value of the data properties
1205
+ * defined in each series' dragDropProps.
1206
+ *
1207
+ * @param {Highcharts.SVGElement} [guideBox]
1208
+ * The guide box to take snapshot of.
1209
+ *
1210
+ * @return {object}
1211
+ * Snapshot object. Point properties are placed in a hashmap with IDs as
1212
+ * keys.
1213
+ */
1214
+ function getPositionSnapshot(e, points, guideBox) {
1215
+ var res = {
1216
+ pageX: e.pageX,
1217
+ pageY: e.pageY,
1218
+ guideBox: guideBox && {
1219
+ x: guideBox.attr('x'),
1220
+ y: guideBox.attr('y'),
1221
+ width: guideBox.attr('width'),
1222
+ height: guideBox.attr('height')
1223
+ },
1224
+ points: {}
1225
+ };
1226
+
1227
+ // Loop over the points and add their props
1228
+ each(points, function (point) {
1229
+ var pointProps = {};
1230
+ // Add all of the props defined in the series' dragDropProps to the
1231
+ // snapshot
1232
+ objectEach(point.series.dragDropProps, function (val, key) {
1233
+ pointProps[key] = point[key];
1234
+ });
1235
+ pointProps.point = point; // Store reference to point
1236
+ res.points[point.id] = pointProps;
1237
+ });
1238
+
1239
+ return res;
1240
+ }
1241
+
1242
+
1243
+ /**
1244
+ * Get a list of points that are grouped with this point. If only one point is
1245
+ * in the group, that point is returned by itself in an array.
1246
+ *
1247
+ * @private
1248
+ * @param {Highcharts.Point} point
1249
+ * Point to find group from.
1250
+ *
1251
+ * @return {Array<Highcharts.Point>}
1252
+ * Array of points in this group.
1253
+ */
1254
+ function getGroupedPoints(point) {
1255
+ var series = point.series,
1256
+ groupKey = series.options.dragDrop.groupBy;
1257
+ return point.options[groupKey] ?
1258
+ // If we have a grouping option, filter the points by that
1259
+ filter(series.points, function (comparePoint) {
1260
+ return comparePoint.options[groupKey] === point.options[groupKey];
1261
+ }) :
1262
+ // Otherwise return the point by itself only
1263
+ [point];
1264
+ }
1265
+
1266
+
1267
+ /**
1268
+ * Resize a rect element on one side. The element is modified.
1269
+ *
1270
+ * @private
1271
+ * @param {Highcharts.SVGElement} rect
1272
+ * Rect element to resize.
1273
+ *
1274
+ * @param {string} updateSide
1275
+ * Which side of the rect to update. Can be `left`, `right`, `top` or
1276
+ * `bottom`.
1277
+ *
1278
+ * @param {object} update
1279
+ * Object with x and y properties, detailing how much to resize each
1280
+ * dimension.
1281
+ *
1282
+ * @return {Highcharts.SVGElement}
1283
+ * The modified rect.
1284
+ */
1285
+ function resizeRect(rect, updateSide, update) {
1286
+ var resizeAttrs;
1287
+ switch (updateSide) {
1288
+ case 'left':
1289
+ resizeAttrs = {
1290
+ x: rect.attr('x') + update.x,
1291
+ width: Math.max(1, rect.attr('width') - update.x)
1292
+ };
1293
+ break;
1294
+ case 'right':
1295
+ resizeAttrs = {
1296
+ width: Math.max(1, rect.attr('width') + update.x)
1297
+ };
1298
+ break;
1299
+ case 'top':
1300
+ resizeAttrs = {
1301
+ y: rect.attr('y') + update.y,
1302
+ height: Math.max(1, rect.attr('height') - update.y)
1303
+ };
1304
+ break;
1305
+ case 'bottom':
1306
+ resizeAttrs = {
1307
+ height: Math.max(1, rect.attr('height') + update.y)
1308
+ };
1309
+ break;
1310
+ default:
1311
+ }
1312
+ rect.attr(resizeAttrs);
1313
+ }
1314
+
1315
+
1316
+ /**
1317
+ * Flip a side property, used with resizeRect. If input side is "left", return
1318
+ * "right" etc.
1319
+ *
1320
+ * @private
1321
+ * @param {string} side
1322
+ * Side prop to flip. Can be `left`, `right`, `top` or `bottom`.
1323
+ *
1324
+ * @return {string}
1325
+ * The flipped side.
1326
+ */
1327
+ function flipResizeSide(side) {
1328
+ return {
1329
+ left: 'right',
1330
+ right: 'left',
1331
+ top: 'bottom',
1332
+ bottom: 'top'
1333
+ }[side];
1334
+ }
1335
+
1336
+
1337
+ /**
1338
+ * Prepare chart.dragDropData with origin info, and show the guide box.
1339
+ *
1340
+ * @private
1341
+ * @param {global.Event} e
1342
+ * Mouse event with original mouse position.
1343
+ *
1344
+ * @param {Highcharts.Point} point
1345
+ * The point the dragging started on.
1346
+ */
1347
+ function initDragDrop(e, point) {
1348
+ var groupedPoints = getGroupedPoints(point),
1349
+ series = point.series,
1350
+ chart = series.chart,
1351
+ guideBox;
1352
+
1353
+ // If liveRedraw is disabled, show the guide box with the default state
1354
+ if (!pick(
1355
+ series.options.dragDrop && series.options.dragDrop.liveRedraw,
1356
+ true
1357
+ )) {
1358
+ chart.dragGuideBox = guideBox = series.getGuideBox(groupedPoints);
1359
+ chart.setGuideBoxState('default', series.options.dragDrop.guideBox)
1360
+ .add(series.group);
1361
+ }
1362
+
1363
+ // Store some data on the chart to pick up later
1364
+ chart.dragDropData = {
1365
+ origin: getPositionSnapshot(e, groupedPoints, guideBox),
1366
+ point: point,
1367
+ groupedPoints: groupedPoints
1368
+ };
1369
+
1370
+ // Set drag state
1371
+ chart.isDragging = true;
1372
+ }
1373
+
1374
+
1375
+ /**
1376
+ * Calculate new point options from points being dragged.
1377
+ *
1378
+ * @private
1379
+ * @param {object} dragDropData
1380
+ * A chart's dragDropData with drag/drop origin information, and info on
1381
+ * which points are being dragged.
1382
+ *
1383
+ * @param {global.Event} newPos
1384
+ * Event with the new position of the mouse (pageX/Y properties).
1385
+ *
1386
+ * @return {Array<object>}
1387
+ * Hashmap with point.id mapped to an object with the original point
1388
+ * reference, as well as the new data values.
1389
+ */
1390
+ function getNewPoints(dragDropData, newPos) {
1391
+ var point = dragDropData.point,
1392
+ series = point.series,
1393
+ options = merge(series.options.dragDrop, point.options.dragDrop),
1394
+ updateProps = {},
1395
+ resizeProp = dragDropData.updateProp,
1396
+ hashmap = {};
1397
+
1398
+ // Go through the data props that can be updated on this series and find out
1399
+ // which ones we want to update.
1400
+ objectEach(point.series.dragDropProps, function (val, key) {
1401
+ // If we are resizing, skip if this key is not the correct one or it
1402
+ // is not resizable.
1403
+ if (
1404
+ resizeProp && (
1405
+ resizeProp !== key ||
1406
+ !val.resize ||
1407
+ val.optionName && options[val.optionName] === false
1408
+ )
1409
+ ) {
1410
+ return;
1411
+ }
1412
+
1413
+ // If we are resizing, we now know it is good. If we are moving, check
1414
+ // that moving along this axis is enabled, and the prop is movable.
1415
+ // If this prop is enabled, add it to be updated.
1416
+ if (
1417
+ resizeProp || (
1418
+ val.move &&
1419
+ (
1420
+ val.axis === 'x' && options.draggableX ||
1421
+ val.axis === 'y' && options.draggableY
1422
+ )
1423
+ )
1424
+ ) {
1425
+ updateProps[key] = val;
1426
+ }
1427
+ });
1428
+
1429
+ // Go through the points to be updated and get new options for each of them
1430
+ each(
1431
+ resizeProp ? // If resizing, only update the point we are resizing
1432
+ [point] :
1433
+ dragDropData.groupedPoints,
1434
+ function (p) {
1435
+ hashmap[p.id] = {
1436
+ point: p,
1437
+ newValues: p.getDropValues(dragDropData.origin, newPos, updateProps)
1438
+ };
1439
+ });
1440
+ return hashmap;
1441
+ }
1442
+
1443
+
1444
+ /**
1445
+ * Update the points in a chart from dragDropData.newPoints.
1446
+ *
1447
+ * @private
1448
+ * @param {Highcharts.Chart} chart
1449
+ * A chart with dragDropData.newPoints.
1450
+ *
1451
+ * @param {boolean} [animate=true]
1452
+ * Animate updating points?
1453
+ */
1454
+ function updatePoints(chart, animate) {
1455
+ var newPoints = chart.dragDropData.newPoints,
1456
+ animOptions = animate === false ? false : merge({
1457
+ duration: 400 // 400 is the default in H.animate
1458
+ }, chart.options.animation);
1459
+
1460
+ chart.isDragDropAnimating = true;
1461
+
1462
+ // Update the points
1463
+ objectEach(newPoints, function (newPoint) {
1464
+ newPoint.point.update(newPoint.newValues, false);
1465
+ });
1466
+
1467
+ chart.redraw(animOptions);
1468
+
1469
+ // Clear the isAnimating flag after animation duration is complete.
1470
+ // The complete handler for animation seems to have bugs at this time, so
1471
+ // we have to use a timeout instead.
1472
+ setTimeout(function () {
1473
+ delete chart.isDragDropAnimating;
1474
+ if (chart.hoverPoint && !chart.dragHandles) {
1475
+ chart.hoverPoint.showDragHandles();
1476
+ }
1477
+ }, animOptions.duration);
1478
+ }
1479
+
1480
+
1481
+ /**
1482
+ * Resize the guide box according to point options and a difference in mouse
1483
+ * positions. Handles reversed axes.
1484
+ *
1485
+ * @private
1486
+ * @param {Highcharts.Point} point
1487
+ * The point that is being resized.
1488
+ *
1489
+ * @param {number} dX
1490
+ * Difference in X position.
1491
+ *
1492
+ * @param {number} dY
1493
+ * Difference in Y position.
1494
+ */
1495
+ function resizeGuideBox(point, dX, dY) {
1496
+ var series = point.series,
1497
+ chart = series.chart,
1498
+ dragDropData = chart.dragDropData,
1499
+ resizeSide,
1500
+ newPoint,
1501
+ resizeProp = series.dragDropProps[dragDropData.updateProp];
1502
+
1503
+ // dragDropProp.resizeSide holds info on which side to resize.
1504
+ newPoint = dragDropData.newPoints[point.id].newValues;
1505
+ resizeSide = typeof resizeProp.resizeSide === 'function' ?
1506
+ resizeProp.resizeSide(newPoint, point) : resizeProp.resizeSide;
1507
+
1508
+ // Call resize hook if it is defined
1509
+ if (resizeProp.beforeResize) {
1510
+ resizeProp.beforeResize(chart.dragGuideBox, newPoint, point);
1511
+ }
1512
+
1513
+ // Do the resize
1514
+ resizeRect(
1515
+ chart.dragGuideBox,
1516
+ resizeProp.axis === 'x' && series.xAxis.reversed ||
1517
+ resizeProp.axis === 'y' && series.yAxis.reversed ?
1518
+ flipResizeSide(resizeSide) : resizeSide,
1519
+ {
1520
+ x: resizeProp.axis === 'x' ?
1521
+ dX - (dragDropData.origin.prevdX || 0) : 0,
1522
+ y: resizeProp.axis === 'y' ?
1523
+ dY - (dragDropData.origin.prevdY || 0) : 0
1524
+ }
1525
+ );
1526
+ }
1527
+
1528
+
1529
+ /**
1530
+ * Default mouse move handler while dragging. Handles updating points or guide
1531
+ * box.
1532
+ *
1533
+ * @private
1534
+ * @param {global.Event} e
1535
+ * The mouse move event.
1536
+ *
1537
+ * @param {Highcharts.Point} point
1538
+ * The point that is dragged.
1539
+ */
1540
+ function dragMove(e, point) {
1541
+ var series = point.series,
1542
+ chart = series.chart,
1543
+ data = chart.dragDropData,
1544
+ options = merge(series.options.dragDrop, point.options.dragDrop),
1545
+ draggableX = options.draggableX,
1546
+ draggableY = options.draggableY,
1547
+ origin = data.origin,
1548
+ dX = e.pageX - origin.pageX,
1549
+ dY = e.pageY - origin.pageY,
1550
+ oldDx = dX,
1551
+ updateProp = data.updateProp;
1552
+
1553
+ // Handle inverted
1554
+ if (chart.inverted) {
1555
+ dX = -dY;
1556
+ dY = -oldDx;
1557
+ }
1558
+
1559
+ // If we have liveRedraw enabled, update the points immediately. Otherwise
1560
+ // update the guideBox.
1561
+ if (pick(options.liveRedraw, true)) {
1562
+ updatePoints(chart, false);
1563
+
1564
+ // Update drag handles
1565
+ if (chart.dragHandles) {
1566
+ chart.hideDragHandles();
1567
+ }
1568
+ point.showDragHandles();
1569
+
1570
+ } else {
1571
+ // No live redraw, update guide box
1572
+ if (updateProp) {
1573
+ // We are resizing, so resize the guide box
1574
+ resizeGuideBox(point, dX, dY);
1575
+ } else {
1576
+ // We are moving, so move the guide box
1577
+ chart.dragGuideBox.translate(
1578
+ draggableX ? dX : 0, draggableY ? dY : 0
1579
+ );
1580
+ }
1581
+ }
1582
+
1583
+ // Update stored previous dX/Y
1584
+ origin.prevdX = dX;
1585
+ origin.prevdY = dY;
1586
+ }
1587
+
1588
+
1589
+ /**
1590
+ * Set the state of the guide box.
1591
+ *
1592
+ * @private
1593
+ * @param {string} state
1594
+ * The state to set the guide box to.
1595
+ *
1596
+ * @param {object} options
1597
+ * Additional overall guideBox options to consider.
1598
+ *
1599
+ * @return {Highcharts.SVGElement}
1600
+ * The modified guide box.
1601
+ */
1602
+ H.Chart.prototype.setGuideBoxState = function (state, options) {
1603
+ var guideBox = this.dragGuideBox,
1604
+ guideBoxOptions = merge(defaultGuideBoxOptions, options),
1605
+ stateOptions = merge(guideBoxOptions.default, guideBoxOptions[state]);
1606
+ return guideBox.attr({
1607
+ className: stateOptions.className,
1608
+ stroke: stateOptions.lineColor,
1609
+ strokeWidth: stateOptions.lineWidth,
1610
+ fill: stateOptions.color,
1611
+ cursor: stateOptions.cursor,
1612
+ zIndex: stateOptions.zIndex
1613
+ });
1614
+ };
1615
+
1616
+
1617
+ /**
1618
+ * Get updated point values when dragging a point.
1619
+ *
1620
+ * @private
1621
+ * @param {object} origin Mouse position (pageX/Y) and point props at current
1622
+ * data values. Point props should be organized per point.id in a hashmap.
1623
+ *
1624
+ * @param {global.Event} newPos New mouse position (pageX/Y).
1625
+ *
1626
+ * @param {object} updateProps Point props to modify. Map of prop objects where
1627
+ * each key refers to the prop, and the value is an object with an axis
1628
+ * property. Example:
1629
+ * {
1630
+ * x: {
1631
+ * axis: 'x'
1632
+ * },
1633
+ * x2: {
1634
+ * axis: 'x'
1635
+ * }
1636
+ * }
1637
+ *
1638
+ * @returns {object}
1639
+ * An object with updated data values.
1640
+ */
1641
+ H.Point.prototype.getDropValues = function (origin, newPos, updateProps) {
1642
+ var point = this,
1643
+ series = point.series,
1644
+ options = merge(series.options.dragDrop, point.options.dragDrop),
1645
+ yAxis = series.yAxis,
1646
+ xAxis = series.xAxis,
1647
+ dX = newPos.pageX - origin.pageX,
1648
+ dY = newPos.pageY - origin.pageY,
1649
+ oldX = pick(origin.x, point.x),
1650
+ oldY = pick(origin.y, point.y),
1651
+ dXValue = xAxis.toValue(
1652
+ xAxis.toPixels(oldX, true) +
1653
+ (xAxis.horiz ? dX : dY),
1654
+ true
1655
+ ) - oldX,
1656
+ dYValue = yAxis.toValue(
1657
+ yAxis.toPixels(oldY, true) +
1658
+ (yAxis.horiz ? dX : dY),
1659
+ true
1660
+ ) - oldY,
1661
+ result = {},
1662
+ updateSingleProp,
1663
+ pointOrigin = origin.points[point.id];
1664
+
1665
+ // Find out if we only have one prop to update
1666
+ for (var key in updateProps) {
1667
+ if (updateProps.hasOwnProperty(key)) {
1668
+ if (updateSingleProp !== undefined) {
1669
+ updateSingleProp = false;
1670
+ break;
1671
+ }
1672
+ updateSingleProp = true;
1673
+ }
1674
+ }
1675
+
1676
+ // Utility function to apply precision and limit a value within the
1677
+ // draggable range
1678
+ function limitToRange(val, direction) {
1679
+ var defaultPrecision = series[direction.toLowerCase() + 'Axis']
1680
+ .categories ? 1 : 0,
1681
+ precision = pick(
1682
+ options['dragPrecision' + direction], defaultPrecision
1683
+ ),
1684
+ min = pick(options['dragMin' + direction], -Infinity),
1685
+ max = pick(options['dragMax' + direction], Infinity),
1686
+ res = val;
1687
+ if (precision) {
1688
+ res = Math.round(res / precision) * precision;
1689
+ }
1690
+ return Math.max(min, Math.min(max, res));
1691
+ }
1692
+
1693
+ // Assign new value to property. Adds dX/YValue to the old value, limiting
1694
+ // it within min/max ranges.
1695
+ objectEach(updateProps, function (val, key) {
1696
+ var oldVal = pointOrigin[key],
1697
+ newVal = limitToRange(
1698
+ oldVal + (val.axis === 'x' ? dXValue : dYValue),
1699
+ val.axis.toUpperCase()
1700
+ );
1701
+ // If we are updating a single prop, and it has a validation function
1702
+ // for the prop, run it. If it fails, don't update the value.
1703
+ if (
1704
+ !(
1705
+ updateSingleProp &&
1706
+ val.propValidate &&
1707
+ !val.propValidate(newVal, point)
1708
+ ) &&
1709
+ oldVal !== undefined
1710
+ ) {
1711
+ result[key] = newVal;
1712
+ }
1713
+ });
1714
+
1715
+ return result;
1716
+ };
1717
+
1718
+
1719
+ /**
1720
+ * Returns an SVGElement to use as the guide box for a set of points.
1721
+ *
1722
+ * @private
1723
+ * @param {Array<Highcharts.Point>} points
1724
+ * The state to set the guide box to.
1725
+ *
1726
+ * @return {Highcharts.SVGElement}
1727
+ * An SVG element for the guide box, not added to DOM.
1728
+ */
1729
+ H.Series.prototype.getGuideBox = function (points) {
1730
+ var chart = this.chart,
1731
+ minX = Infinity,
1732
+ maxX = -Infinity,
1733
+ minY = Infinity,
1734
+ maxY = -Infinity,
1735
+ changed;
1736
+
1737
+ // Find bounding box of all points
1738
+ each(points, function (point) {
1739
+ var bBox = point.graphic && point.graphic.getBBox() || point.shapeArgs;
1740
+ if (bBox && (bBox.width || bBox.height || bBox.x || bBox.y)) {
1741
+ changed = true;
1742
+ minX = Math.min(bBox.x, minX);
1743
+ maxX = Math.max(bBox.x + bBox.width, maxX);
1744
+ minY = Math.min(bBox.y, minY);
1745
+ maxY = Math.max(bBox.y + bBox.height, maxY);
1746
+ }
1747
+ });
1748
+
1749
+ return changed ? chart.renderer.rect(
1750
+ minX,
1751
+ minY,
1752
+ maxX - minX,
1753
+ maxY - minY
1754
+ ) : chart.renderer.g();
1755
+ };
1756
+
1757
+
1758
+ /**
1759
+ * On point mouse out. Hide drag handles, depending on state.
1760
+ *
1761
+ * @private
1762
+ * @param {Highcharts.Point} point
1763
+ * The point mousing out of.
1764
+ */
1765
+ function mouseOut(point) {
1766
+ var chart = point.series && point.series.chart;
1767
+ if (
1768
+ chart &&
1769
+ chart.dragHandles &&
1770
+ !(
1771
+ chart.dragDropData &&
1772
+ (
1773
+ chart.dragDropData.isDragging ||
1774
+ chart.dragDropData.isHoveringHandle === point.id
1775
+ )
1776
+ )
1777
+ ) {
1778
+ chart.hideDragHandles();
1779
+ }
1780
+ }
1781
+
1782
+
1783
+ /**
1784
+ * Mouseout on resize handle. Handle states, and possibly run mouseOut on point.
1785
+ *
1786
+ * @private
1787
+ * @param {Highcharts.Point} point
1788
+ * The point mousing out of.
1789
+ */
1790
+ function onResizeHandleMouseOut(point) {
1791
+ var chart = point.series.chart;
1792
+ if (
1793
+ chart.dragDropData &&
1794
+ point.id === chart.dragDropData.isHoveringHandle
1795
+ ) {
1796
+ delete chart.dragDropData.isHoveringHandle;
1797
+ }
1798
+ if (!chart.hoverPoint) {
1799
+ mouseOut(point);
1800
+ }
1801
+ }
1802
+
1803
+
1804
+ /**
1805
+ * Mousedown on resize handle. Init a drag if the conditions are right.
1806
+ *
1807
+ * @private
1808
+ * @param {global.Event} e
1809
+ * The mousedown event.
1810
+ *
1811
+ * @param {Highcharts.Point} point
1812
+ * The point mousing down on.
1813
+ *
1814
+ * @param {string} updateProp
1815
+ * The data property this resize handle is attached to for this point.
1816
+ */
1817
+ function onResizeHandleMouseDown(e, point, updateProp) {
1818
+ var chart = point.series.chart;
1819
+
1820
+ // Ignore if zoom/pan key is pressed
1821
+ if (chart.zoomOrPanKeyPressed(e)) {
1822
+ return;
1823
+ }
1824
+
1825
+ // Prevent zooming
1826
+ chart.mouseIsDown = false;
1827
+
1828
+ initDragDrop(e, point);
1829
+ chart.dragDropData.isDragging = true;
1830
+ chart.dragDropData.updateProp = e.updateProp = updateProp;
1831
+ point.firePointEvent('dragStart', e);
1832
+
1833
+ // Prevent default to avoid point click for dragging too
1834
+ e.stopPropagation();
1835
+ e.preventDefault();
1836
+ }
1837
+
1838
+
1839
+ /**
1840
+ * Render drag handles on a point - depending on which handles are enabled - and
1841
+ * attach events to them.
1842
+ * @private
1843
+ */
1844
+ H.Point.prototype.showDragHandles = function () {
1845
+ var point = this,
1846
+ series = point.series,
1847
+ chart = series.chart,
1848
+ renderer = chart.renderer,
1849
+ options = merge(series.options.dragDrop, point.options.dragDrop);
1850
+
1851
+ // Go through each updateProp and see if we are supposed to create a handle
1852
+ // for it.
1853
+ objectEach(series.dragDropProps, function (val, key) {
1854
+ var handleOptions = merge(
1855
+ defaultDragHandleOptions,
1856
+ val.handleOptions,
1857
+ options.dragHandle
1858
+ ),
1859
+ handleAttrs = {
1860
+ className: handleOptions.className,
1861
+ 'stroke-width': handleOptions.lineWidth,
1862
+ fill: handleOptions.color,
1863
+ stroke: handleOptions.lineColor
1864
+ },
1865
+ pathFormatter = handleOptions.pathFormatter || val.handleFormatter,
1866
+ positioner = val.handlePositioner,
1867
+ pos,
1868
+ handle,
1869
+ path,
1870
+ // Run validation function on whether or not we allow individual
1871
+ // updating of this prop.
1872
+ validate = val.validateIndividualDrag ?
1873
+ val.validateIndividualDrag(point) : true;
1874
+ if (
1875
+ val.resize &&
1876
+ validate &&
1877
+ val.resizeSide &&
1878
+ pathFormatter &&
1879
+ (
1880
+ options['draggable' + val.axis.toUpperCase()] ||
1881
+ options[val.optionName]
1882
+ ) &&
1883
+ options[val.optionName] !== false
1884
+ ) {
1885
+
1886
+ // Create group if it doesn't exist
1887
+ if (!chart.dragHandles) {
1888
+ chart.dragHandles = {
1889
+ group: renderer.g('drag-drop-handles')
1890
+ .add(series.markerGroup || series.group)
1891
+ };
1892
+ }
1893
+
1894
+ // Find position and path of handle
1895
+ pos = positioner(point);
1896
+ path = pathFormatter(point);
1897
+ if (!path || pos.x < 0 || pos.y < 0) {
1898
+ return;
1899
+ }
1900
+
1901
+ // If cursor is not set explicitly, use axis direction
1902
+ handleAttrs.cursor = handleOptions.cursor ||
1903
+ (val.axis === 'x') !== !!chart.inverted ?
1904
+ 'ew-resize' : 'ns-resize';
1905
+
1906
+ // Create and add the handle element
1907
+ chart.dragHandles[
1908
+ typeof val.resizeSide === 'function' ?
1909
+ val.resizeSide(point.options, point) : val.resizeSide
1910
+ ] = handle = renderer
1911
+ .path(path)
1912
+ .translate(pos.x, pos.y)
1913
+ .attr(handleAttrs)
1914
+ .add(chart.dragHandles.group);
1915
+
1916
+ // Add events
1917
+ addEvent(handle.element, 'mousedown', function (e) {
1918
+ onResizeHandleMouseDown(e, point, key);
1919
+ });
1920
+ addEvent(chart.dragHandles.group.element, 'mouseover', function () {
1921
+ chart.dragDropData = chart.dragDropData || {};
1922
+ chart.dragDropData.isHoveringHandle = point.id;
1923
+ });
1924
+ addEvent(chart.dragHandles.group.element, 'mouseout', function () {
1925
+ onResizeHandleMouseOut(point);
1926
+ });
1927
+ }
1928
+ });
1929
+ };
1930
+
1931
+
1932
+ /**
1933
+ * Remove the chart's drag handles if they exist.
1934
+ * @private
1935
+ */
1936
+ H.Chart.prototype.hideDragHandles = function () {
1937
+ var chart = this;
1938
+ if (chart.dragHandles) {
1939
+ objectEach(chart.dragHandles, function (val, key) {
1940
+ if (key !== 'group' && val.destroy) {
1941
+ val.destroy();
1942
+ }
1943
+ });
1944
+ if (chart.dragHandles.group && chart.dragHandles.group.destroy) {
1945
+ chart.dragHandles.group.destroy();
1946
+ }
1947
+ delete chart.dragHandles;
1948
+ }
1949
+ };
1950
+
1951
+
1952
+ /**
1953
+ * Utility function to count the number of props in an object.
1954
+ *
1955
+ * @private
1956
+ * @param {object} object
1957
+ * The object to count.
1958
+ *
1959
+ * @return {number}
1960
+ * Number of own properties on the object.
1961
+ */
1962
+ function countProps(object) {
1963
+ var count = 0;
1964
+ for (var p in object) {
1965
+ if (object.hasOwnProperty(p)) {
1966
+ count++;
1967
+ }
1968
+ }
1969
+ return count;
1970
+ }
1971
+
1972
+
1973
+ /**
1974
+ * Utility function to get the value of the first prop of an object. (Note that
1975
+ * the order of keys in an object is usually not guaranteed.)
1976
+ *
1977
+ * @private
1978
+ * @param {object} object
1979
+ * The object to count.
1980
+ *
1981
+ * @return {*}
1982
+ * Value of the first prop in the object.
1983
+ */
1984
+ function getFirstProp(object) {
1985
+ for (var p in object) {
1986
+ if (object.hasOwnProperty(p)) {
1987
+ return object[p];
1988
+ }
1989
+ }
1990
+ }
1991
+
1992
+
1993
+ /**
1994
+ * Mouseover on a point. Show drag handles if the conditions are right.
1995
+ *
1996
+ * @private
1997
+ * @param {Highcharts.Point} point
1998
+ * The point mousing over.
1999
+ */
2000
+ function mouseOver(point) {
2001
+ var series = point.series,
2002
+ chart = series && series.chart;
2003
+ if (
2004
+ chart &&
2005
+ !(chart.dragDropData && chart.dragDropData.isDragging) &&
2006
+ !chart.isDragDropAnimating &&
2007
+ series.options.dragDrop &&
2008
+ !(
2009
+ chart.options &&
2010
+ chart.options.chart &&
2011
+ chart.options.chart.options3d
2012
+ )
2013
+ ) {
2014
+ // Hide the handles if they exist on another point already
2015
+ if (chart.dragHandles) {
2016
+ chart.hideDragHandles();
2017
+ }
2018
+ point.showDragHandles();
2019
+ }
2020
+ }
2021
+
2022
+
2023
+ /**
2024
+ * On container mouse move. Handle drag sensitivity and fire drag event.
2025
+ *
2026
+ * @private
2027
+ * @param {global.Event} e
2028
+ * The mouse move event.
2029
+ *
2030
+ * @param {Highcharts.Chart} chart
2031
+ * The chart we are moving across.
2032
+ */
2033
+ function mouseMove(e, chart) {
2034
+ // Ignore if zoom/pan key is pressed
2035
+ if (chart.zoomOrPanKeyPressed(e)) {
2036
+ return;
2037
+ }
2038
+
2039
+ var dragDropData = chart.dragDropData,
2040
+ point,
2041
+ seriesDragDropOpts,
2042
+ newPoints,
2043
+ numNewPoints = 0,
2044
+ newPoint;
2045
+
2046
+ if (dragDropData && dragDropData.isDragging) {
2047
+ point = dragDropData.point;
2048
+ seriesDragDropOpts = point.series.options.dragDrop;
2049
+
2050
+ // No tooltip for dragging
2051
+ e.preventDefault();
2052
+
2053
+ // Update sensitivity test if not passed yet
2054
+ if (!dragDropData.draggedPastSensitivity) {
2055
+ dragDropData.draggedPastSensitivity = hasDraggedPastSensitivity(
2056
+ e, chart, pick(
2057
+ point.options.dragDrop &&
2058
+ point.options.dragDrop.dragSensitivity,
2059
+ seriesDragDropOpts &&
2060
+ seriesDragDropOpts.dragSensitivity,
2061
+ defaultDragSensitivity
2062
+ )
2063
+ );
2064
+ }
2065
+
2066
+ // If we have dragged past dragSensitivity, run the mousemove handler
2067
+ // for dragging
2068
+ if (dragDropData.draggedPastSensitivity) {
2069
+ // Find the new point values from the moving
2070
+ dragDropData.newPoints = getNewPoints(dragDropData, e);
2071
+
2072
+ // If we are only dragging one point, add it to the event
2073
+ newPoints = dragDropData.newPoints;
2074
+ numNewPoints = countProps(newPoints);
2075
+ newPoint = numNewPoints === 1 ?
2076
+ getFirstProp(newPoints) :
2077
+ null;
2078
+
2079
+ // Run the handler
2080
+ point.firePointEvent('drag', {
2081
+ origin: dragDropData.origin,
2082
+ newPoints: dragDropData.newPoints,
2083
+ newPoint: newPoint && newPoint.newValues,
2084
+ newPointId: newPoint && newPoint.point.id,
2085
+ numNewPoints: numNewPoints,
2086
+ pageX: e.pageX,
2087
+ pageY: e.pageY
2088
+ }, function () {
2089
+ dragMove(e, point);
2090
+ });
2091
+ }
2092
+ }
2093
+ }
2094
+
2095
+
2096
+ /**
2097
+ * On container mouse up. Fire drop event and reset state.
2098
+ *
2099
+ * @private
2100
+ * @param {global.Event} e
2101
+ * The mouse up event.
2102
+ *
2103
+ * @param {Highcharts.Chart} chart
2104
+ * The chart we were dragging in.
2105
+ */
2106
+ function mouseUp(e, chart) {
2107
+ var dragDropData = chart.dragDropData;
2108
+ if (
2109
+ dragDropData &&
2110
+ dragDropData.isDragging &&
2111
+ dragDropData.draggedPastSensitivity
2112
+ ) {
2113
+ var point = dragDropData.point,
2114
+ newPoints = dragDropData.newPoints,
2115
+ numNewPoints = countProps(newPoints),
2116
+ newPoint = numNewPoints === 1 ?
2117
+ getFirstProp(newPoints) :
2118
+ null;
2119
+
2120
+ // Hide the drag handles
2121
+ if (chart.dragHandles) {
2122
+ chart.hideDragHandles();
2123
+ }
2124
+
2125
+ // Prevent default action
2126
+ e.preventDefault();
2127
+ chart.cancelClick = true;
2128
+
2129
+ // Fire the event, with a default handler that updates the points
2130
+ point.firePointEvent('drop', {
2131
+ origin: dragDropData.origin,
2132
+ pageX: e.pageX,
2133
+ pageY: e.pageY,
2134
+ newPoints: newPoints,
2135
+ numNewPoints: numNewPoints,
2136
+ newPoint: newPoint && newPoint.newValues,
2137
+ newPointId: newPoint && newPoint.point.id
2138
+ }, function () {
2139
+ updatePoints(chart);
2140
+ });
2141
+ }
2142
+
2143
+ // Reset
2144
+ delete chart.dragDropData;
2145
+
2146
+ // Clean up the drag guide box if it exists. This is always added on
2147
+ // drag start, even if user is overriding events.
2148
+ if (chart.dragGuideBox) {
2149
+ chart.dragGuideBox.destroy();
2150
+ delete chart.dragGuideBox;
2151
+ }
2152
+ }
2153
+
2154
+
2155
+ /**
2156
+ * On container mouse down. Init dragdrop if conditions are right.
2157
+ *
2158
+ * @private
2159
+ * @param {global.Event} e
2160
+ * The mouse down event.
2161
+ *
2162
+ * @param {Highcharts.Chart} chart
2163
+ * The chart we are clicking.
2164
+ */
2165
+ function mouseDown(e, chart) {
2166
+ var dragPoint = chart.hoverPoint;
2167
+
2168
+ // Reset cancel click
2169
+ chart.cancelClick = false;
2170
+
2171
+ // Ignore if zoom/pan key is pressed
2172
+ if (chart.zoomOrPanKeyPressed(e)) {
2173
+ return;
2174
+ }
2175
+
2176
+ // Prevent zooming
2177
+ chart.mouseIsDown = false;
2178
+
2179
+ // If we somehow get a mousedown event while we are dragging, cancel
2180
+ if (chart.dragDropData && chart.dragDropData.isDragging) {
2181
+ mouseUp(e, chart);
2182
+ return;
2183
+ }
2184
+
2185
+ // If this point is movable, start dragging it
2186
+ if (dragPoint && isPointMovable(dragPoint)) {
2187
+ initDragDrop(e, dragPoint);
2188
+ chart.dragDropData.isDragging = true;
2189
+ dragPoint.firePointEvent('dragStart', e);
2190
+ }
2191
+ }
2192
+
2193
+
2194
+ // Point hover event. We use a short timeout due to issues with coordinating
2195
+ // point mouseover/out events on dragHandles and points. Particularly arearange
2196
+ // series are finicky since the markers are not individual points. This logic
2197
+ // should preferably be improved in the future. Notice that the mouseOut event
2198
+ // below must have a shorter timeout to ensure event order.
2199
+ addEvent(H.Point, 'mouseOver', function () {
2200
+ var point = this;
2201
+ setTimeout(function () {
2202
+ mouseOver(point);
2203
+ }, 12);
2204
+ });
2205
+
2206
+
2207
+ // Point mouseleave event. See above function for explanation of the timeout.
2208
+ addEvent(H.Point, 'mouseOut', function () {
2209
+ var point = this;
2210
+ setTimeout(function () {
2211
+ mouseOut(point);
2212
+ }, 10);
2213
+ });
2214
+
2215
+
2216
+ /**
2217
+ * Check whether the zoomKey or panKey is pressed.
2218
+ *
2219
+ * @private
2220
+ * @param {global.Event} e
2221
+ * A mouse event.
2222
+ *
2223
+ * @return {boolean}
2224
+ * True if the zoom or pan keys are pressed. False otherwise.
2225
+ */
2226
+ H.Chart.prototype.zoomOrPanKeyPressed = function (e) {
2227
+ // Check whether the panKey and zoomKey are set in chart.userOptions
2228
+ var chartOptions = this.userOptions.chart || {},
2229
+ panKey = chartOptions.panKey && chartOptions.panKey + 'Key',
2230
+ zoomKey = chartOptions.zoomKey && chartOptions.zoomKey + 'Key';
2231
+ return (e[zoomKey] || e[panKey]);
2232
+ };
2233
+
2234
+
2235
+ // Add events to document and chart after chart has been created
2236
+ H.Chart.prototype.callbacks.push(function (chart) {
2237
+ var container = chart.container,
2238
+ doc = H.doc;
2239
+
2240
+ // Only enable if we have a draggable chart
2241
+ if (isChartDraggable(chart)) {
2242
+ addEvent(container, 'mousemove', function (e) {
2243
+ mouseMove(e, chart);
2244
+ });
2245
+ addEvent(container, 'touchmove', function (e) {
2246
+ mouseMove(e, chart);
2247
+ });
2248
+ addEvent(container, 'mousedown', function (e) {
2249
+ mouseDown(e, chart);
2250
+ });
2251
+ addEvent(container, 'touchstart', function (e) {
2252
+ mouseDown(e, chart);
2253
+ });
2254
+ addEvent(container, 'mouseleave', function (e) {
2255
+ mouseUp(e, chart);
2256
+ });
2257
+ chart.unbindDragDropMouseUp = addEvent(doc, 'mouseup', function (e) {
2258
+ mouseUp(e, chart);
2259
+ });
2260
+ chart.unbindDragDropTouchEnd = addEvent(doc, 'touchend', function (e) {
2261
+ mouseUp(e, chart);
2262
+ });
2263
+
2264
+ // Add cleanup to make sure we don't pollute document
2265
+ addEvent(chart, 'destroy', function () {
2266
+ if (chart.unbindDragDropMouseUp) {
2267
+ chart.unbindDragDropMouseUp();
2268
+ }
2269
+ if (chart.unbindDragDropTouchEnd) {
2270
+ chart.unbindDragDropTouchEnd();
2271
+ }
2272
+ });
2273
+ }
2274
+ });
2275
+
2276
+ }(Highcharts));
2277
+ return (function () {
2278
+
2279
+
2280
+ }());
2281
+ }));