highcharts 6.1.1 → 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.
- package/bower.json +1 -1
- package/css/highcharts.css +29 -0
- package/css/highcharts.scss +25 -1
- package/css/themes/dark-unica.css +29 -0
- package/css/themes/grid-light.css +29 -0
- package/css/themes/sand-signika.css +29 -0
- package/es-modules/indicators/accumulation-distribution.src.js +1 -1
- package/es-modules/indicators/atr.src.js +1 -1
- package/es-modules/indicators/bollinger-bands.src.js +2 -2
- package/es-modules/indicators/cci.src.js +1 -1
- package/es-modules/indicators/cmf.src.js +1 -1
- package/es-modules/indicators/ema.src.js +1 -1
- package/es-modules/indicators/ichimoku-kinko-hyo.src.js +1 -1
- package/es-modules/indicators/indicators.src.js +29 -14
- package/es-modules/indicators/macd.src.js +4 -4
- package/es-modules/indicators/mfi.src.js +1 -1
- package/es-modules/indicators/momentum.src.js +2 -2
- package/es-modules/indicators/pivot-points.src.js +7 -2
- package/es-modules/indicators/price-envelopes.src.js +2 -2
- package/es-modules/indicators/psar.src.js +1 -1
- package/es-modules/indicators/roc.src.js +1 -1
- package/es-modules/indicators/rsi.src.js +1 -1
- package/es-modules/indicators/stochastic.src.js +9 -7
- package/es-modules/indicators/volume-by-price.src.js +1 -1
- package/es-modules/indicators/vwap.src.js +1 -1
- package/es-modules/indicators/wma.src.js +1 -1
- package/es-modules/indicators/zigzag.src.js +1 -1
- package/es-modules/masters/highcharts-gantt.src.js +11 -0
- package/es-modules/masters/modules/annotations.src.js +1 -1
- package/es-modules/masters/modules/arrow-symbols.src.js +12 -0
- package/es-modules/masters/modules/broken-axis.src.js +1 -1
- package/es-modules/masters/modules/current-date-indicator.src.js +12 -0
- package/es-modules/masters/modules/data.src.js +1 -1
- package/es-modules/masters/modules/draggable-points.src.js +9 -0
- package/es-modules/masters/modules/export-data.src.js +1 -1
- package/es-modules/masters/modules/exporting.src.js +1 -1
- package/es-modules/masters/modules/funnel.src.js +1 -1
- package/es-modules/masters/modules/gantt.src.js +2 -1
- package/es-modules/masters/modules/grid-axis.src.js +1 -1
- package/es-modules/masters/modules/heatmap.src.js +1 -1
- package/es-modules/masters/modules/item-series.src.js +1 -1
- package/es-modules/masters/modules/map.src.js +1 -1
- package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
- package/es-modules/masters/modules/pathfinder.src.js +12 -0
- package/es-modules/masters/modules/sankey.src.js +1 -1
- package/es-modules/masters/modules/series-label.src.js +1 -1
- package/es-modules/masters/modules/solid-gauge.src.js +1 -1
- package/es-modules/masters/modules/stock.src.js +1 -1
- package/es-modules/masters/modules/streamgraph.src.js +1 -1
- package/es-modules/masters/modules/treegrid.src.js +12 -0
- package/es-modules/masters/modules/variwide.src.js +1 -1
- package/es-modules/masters/modules/vector.src.js +1 -1
- package/es-modules/masters/modules/windbarb.src.js +1 -1
- package/es-modules/masters/modules/xrange.src.js +1 -1
- package/es-modules/masters/themes/dark-blue.src.js +1 -1
- package/es-modules/masters/themes/dark-green.src.js +1 -1
- package/es-modules/masters/themes/dark-unica.src.js +1 -1
- package/es-modules/masters/themes/gray.src.js +1 -1
- package/es-modules/masters/themes/grid-light.src.js +1 -1
- package/es-modules/masters/themes/grid.src.js +1 -1
- package/es-modules/masters/themes/sand-signika.src.js +1 -1
- package/es-modules/masters/themes/skies.src.js +1 -1
- package/es-modules/mixins/centered-series.js +36 -5
- package/es-modules/mixins/on-series.js +1 -1
- package/es-modules/mixins/polygon.js +4 -4
- package/es-modules/modules/annotations.src.js +2 -2
- package/es-modules/modules/boost-canvas.src.js +19 -8
- package/es-modules/modules/boost.src.js +300 -137
- package/es-modules/modules/broken-axis.src.js +169 -134
- package/es-modules/modules/bullet.src.js +2 -2
- package/es-modules/modules/data.src.js +8 -6
- package/es-modules/modules/draggable-points.src.js +2257 -0
- package/es-modules/modules/drilldown.src.js +4 -2
- package/es-modules/modules/export-data.src.js +11 -1
- package/es-modules/modules/exporting.src.js +62 -36
- package/es-modules/modules/funnel.src.js +5 -5
- package/es-modules/modules/histogram.src.js +30 -28
- package/es-modules/modules/item-series.src.js +36 -11
- package/es-modules/modules/keyboard-navigation.src.js +81 -44
- package/es-modules/modules/no-data-to-display.src.js +5 -5
- package/es-modules/modules/oldie.src.js +14 -9
- package/es-modules/modules/overlapping-datalabels.src.js +45 -21
- package/es-modules/modules/parallel-coordinates.src.js +4 -3
- package/es-modules/modules/pareto.src.js +1 -1
- package/es-modules/modules/sankey.src.js +28 -10
- package/es-modules/modules/series-label.src.js +6 -6
- package/es-modules/modules/solid-gauge.src.js +10 -7
- package/es-modules/modules/static-scale.src.js +67 -28
- package/es-modules/modules/streamgraph.src.js +4 -4
- package/es-modules/modules/sunburst.src.js +4 -4
- package/es-modules/modules/tilemap.src.js +231 -134
- package/es-modules/modules/treemap.src.js +30 -27
- package/es-modules/modules/variable-pie.src.js +3 -3
- package/es-modules/modules/variwide.src.js +36 -24
- package/es-modules/modules/vector.src.js +98 -28
- package/es-modules/modules/windbarb.src.js +4 -4
- package/es-modules/modules/wordcloud.src.js +133 -48
- package/es-modules/modules/xrange.src.js +258 -78
- package/es-modules/parts/AreaSeries.js +83 -50
- package/es-modules/parts/AreaSplineSeries.js +66 -29
- package/es-modules/parts/Axis.js +2184 -745
- package/es-modules/parts/BarSeries.js +70 -53
- package/es-modules/parts/CandlestickSeries.js +20 -10
- package/es-modules/parts/Chart.js +349 -157
- package/es-modules/parts/Color.js +74 -25
- package/es-modules/parts/ColumnSeries.js +274 -147
- package/es-modules/parts/DataGrouping.js +36 -3
- package/es-modules/parts/DataLabels.js +318 -144
- package/es-modules/parts/DateTimeAxis.js +27 -5
- package/es-modules/parts/Dynamics.js +236 -144
- package/es-modules/parts/FlagsSeries.js +49 -7
- package/es-modules/parts/Globals.js +4 -3
- package/es-modules/parts/Html.js +82 -16
- package/es-modules/parts/Interaction.js +198 -65
- package/es-modules/parts/Legend.js +181 -31
- package/es-modules/parts/LogarithmicAxis.js +36 -3
- package/es-modules/parts/MSPointer.js +31 -4
- package/es-modules/parts/Navigator.js +479 -187
- package/es-modules/parts/OHLCSeries.js +11 -5
- package/es-modules/parts/Options.js +1052 -686
- package/es-modules/parts/OrdinalAxis.js +20 -6
- package/es-modules/parts/PieSeries.js +258 -142
- package/es-modules/parts/PlotBandSeries.experimental.js +2 -2
- package/es-modules/parts/PlotLineOrBand.js +671 -35
- package/es-modules/parts/Point.js +189 -73
- package/es-modules/parts/Pointer.js +263 -62
- package/es-modules/parts/RangeSelector.js +601 -91
- package/es-modules/parts/Responsive.js +82 -36
- package/es-modules/parts/ScatterSeries.js +59 -27
- package/es-modules/parts/ScrollablePlotArea.js +30 -9
- package/es-modules/parts/Scrollbar.js +284 -113
- package/es-modules/parts/Series.js +1105 -836
- package/es-modules/parts/SplineSeries.js +53 -31
- package/es-modules/parts/Stacking.js +108 -7
- package/es-modules/parts/StockChart.js +26 -8
- package/es-modules/parts/SvgRenderer.js +1251 -613
- package/es-modules/parts/Tick.js +164 -30
- package/es-modules/parts/Time.js +171 -71
- package/es-modules/parts/Tooltip.js +271 -49
- package/es-modules/parts/TouchPointer.js +70 -3
- package/es-modules/parts/Utilities.js +1024 -429
- package/es-modules/parts-3d/Axis.js +4 -3
- package/es-modules/parts-3d/Chart.js +8 -9
- package/es-modules/parts-3d/Column.js +1 -1
- package/es-modules/parts-3d/Math.js +1 -1
- package/es-modules/parts-3d/Pie.js +1 -1
- package/es-modules/parts-3d/SVGRenderer.js +13 -10
- package/es-modules/parts-3d/Scatter.js +4 -4
- package/es-modules/parts-3d/Series.js +1 -1
- package/es-modules/parts-3d/VMLRenderer.js +1 -1
- package/es-modules/parts-gantt/ArrowSymbols.js +110 -0
- package/es-modules/parts-gantt/CurrentDateIndicator.js +92 -0
- package/es-modules/parts-gantt/GanttChart.js +111 -0
- package/es-modules/parts-gantt/GanttSeries.js +376 -0
- package/es-modules/parts-gantt/GridAxis.js +965 -0
- package/es-modules/parts-gantt/Pathfinder.js +1247 -0
- package/es-modules/parts-gantt/PathfinderAlgorithms.js +746 -0
- package/es-modules/parts-gantt/Tree.js +146 -0
- package/es-modules/parts-gantt/TreeGrid.js +917 -0
- package/es-modules/parts-map/ColorAxis.js +4 -5
- package/es-modules/parts-map/ColorSeriesMixin.js +3 -1
- package/es-modules/parts-map/GeoJSON.js +1 -1
- package/es-modules/parts-map/HeatmapSeries.js +126 -55
- package/es-modules/parts-map/Map.js +144 -51
- package/es-modules/parts-map/MapAxis.js +1 -1
- package/es-modules/parts-map/MapBubbleSeries.js +6 -5
- package/es-modules/parts-map/MapLineSeries.js +4 -4
- package/es-modules/parts-map/MapNavigation.js +50 -12
- package/es-modules/parts-map/MapPointSeries.js +3 -3
- package/es-modules/parts-map/MapPointer.js +1 -1
- package/es-modules/parts-map/MapSeries.js +7 -7
- package/es-modules/parts-more/AreaRangeSeries.js +82 -40
- package/es-modules/parts-more/AreaSplineRangeSeries.js +3 -3
- package/es-modules/parts-more/BoxPlotSeries.js +3 -3
- package/es-modules/parts-more/BubbleSeries.js +9 -4
- package/es-modules/parts-more/ColumnRangeSeries.js +3 -3
- package/es-modules/parts-more/ErrorBarSeries.js +6 -4
- package/es-modules/parts-more/GaugeSeries.js +3 -3
- package/es-modules/parts-more/Pane.js +3 -2
- package/es-modules/parts-more/Polar.js +1 -1
- package/es-modules/parts-more/PolygonSeries.js +3 -3
- package/es-modules/parts-more/RadialAxis.js +5 -4
- package/es-modules/parts-more/WaterfallSeries.js +9 -4
- package/es-modules/supplemental.docs.js +0 -1955
- package/es-modules/themes/dark-blue.js +1 -1
- package/es-modules/themes/dark-green.js +1 -1
- package/es-modules/themes/dark-unica.js +1 -1
- package/es-modules/themes/gray.js +1 -1
- package/es-modules/themes/grid-light.js +1 -1
- package/es-modules/themes/grid.js +1 -1
- package/es-modules/themes/sand-signika.js +1 -1
- package/es-modules/themes/skies.js +1 -1
- package/highcharts-3d.js +77 -75
- package/highcharts-3d.js.map +1 -8
- package/highcharts-3d.src.js +39 -32
- package/highcharts-gantt.js +503 -0
- package/highcharts-gantt.js.map +1 -0
- package/highcharts-gantt.src.js +49289 -0
- package/highcharts-more.js +66 -64
- package/highcharts-more.js.map +1 -8
- package/highcharts-more.src.js +135 -75
- package/highcharts.js +413 -403
- package/highcharts.js.map +1 -8
- package/highcharts.src.js +11114 -4781
- package/highmaps.js +442 -433
- package/highmaps.js.map +1 -8
- package/highmaps.src.js +10740 -4598
- package/highstock.js +553 -540
- package/highstock.js.map +1 -8
- package/highstock.src.js +12807 -5343
- package/indicators/accumulation-distribution.js +4 -3
- package/indicators/accumulation-distribution.js.map +1 -8
- package/indicators/accumulation-distribution.src.js +6 -2
- package/indicators/atr.js +4 -3
- package/indicators/atr.js.map +1 -8
- package/indicators/atr.src.js +6 -2
- package/indicators/bollinger-bands.js +7 -6
- package/indicators/bollinger-bands.js.map +1 -8
- package/indicators/bollinger-bands.src.js +7 -3
- package/indicators/cci.js +4 -3
- package/indicators/cci.js.map +1 -8
- package/indicators/cci.src.js +6 -2
- package/indicators/cmf.js +5 -4
- package/indicators/cmf.js.map +1 -8
- package/indicators/cmf.src.js +6 -2
- package/indicators/ema.js +4 -3
- package/indicators/ema.js.map +1 -8
- package/indicators/ema.src.js +6 -2
- package/indicators/ichimoku-kinko-hyo.js +10 -9
- package/indicators/ichimoku-kinko-hyo.js.map +1 -8
- package/indicators/ichimoku-kinko-hyo.src.js +6 -2
- package/indicators/indicators.js +6 -5
- package/indicators/indicators.js.map +1 -8
- package/indicators/indicators.src.js +34 -15
- package/indicators/macd.js +11 -10
- package/indicators/macd.js.map +1 -8
- package/indicators/macd.src.js +10 -6
- package/indicators/mfi.js +5 -3
- package/indicators/mfi.js.map +1 -8
- package/indicators/mfi.src.js +6 -2
- package/indicators/momentum.js +4 -3
- package/indicators/momentum.js.map +1 -8
- package/indicators/momentum.src.js +7 -3
- package/indicators/pivot-points.js +8 -7
- package/indicators/pivot-points.js.map +1 -8
- package/indicators/pivot-points.src.js +12 -3
- package/indicators/price-envelopes.js +7 -6
- package/indicators/price-envelopes.js.map +1 -8
- package/indicators/price-envelopes.src.js +7 -3
- package/indicators/psar.js +5 -4
- package/indicators/psar.js.map +1 -8
- package/indicators/psar.src.js +6 -2
- package/indicators/roc.js +4 -3
- package/indicators/roc.js.map +1 -8
- package/indicators/roc.src.js +6 -2
- package/indicators/rsi.js +4 -3
- package/indicators/rsi.js.map +1 -8
- package/indicators/rsi.src.js +6 -2
- package/indicators/stochastic.js +7 -5
- package/indicators/stochastic.js.map +1 -8
- package/indicators/stochastic.src.js +14 -8
- package/indicators/volume-by-price.js +13 -12
- package/indicators/volume-by-price.js.map +1 -8
- package/indicators/volume-by-price.src.js +6 -2
- package/indicators/vwap.js +4 -3
- package/indicators/vwap.js.map +1 -8
- package/indicators/vwap.src.js +6 -2
- package/indicators/wma.js +4 -3
- package/indicators/wma.js.map +1 -8
- package/indicators/wma.src.js +6 -2
- package/indicators/zigzag.js +5 -3
- package/indicators/zigzag.js.map +1 -8
- package/indicators/zigzag.src.js +6 -2
- package/js/es-modules/indicators/accumulation-distribution.src.js +1 -1
- package/js/es-modules/indicators/atr.src.js +1 -1
- package/js/es-modules/indicators/bollinger-bands.src.js +2 -2
- package/js/es-modules/indicators/cci.src.js +1 -1
- package/js/es-modules/indicators/cmf.src.js +1 -1
- package/js/es-modules/indicators/ema.src.js +1 -1
- package/js/es-modules/indicators/ichimoku-kinko-hyo.src.js +1 -1
- package/js/es-modules/indicators/indicators.src.js +29 -14
- package/js/es-modules/indicators/macd.src.js +4 -4
- package/js/es-modules/indicators/mfi.src.js +1 -1
- package/js/es-modules/indicators/momentum.src.js +2 -2
- package/js/es-modules/indicators/pivot-points.src.js +7 -2
- package/js/es-modules/indicators/price-envelopes.src.js +2 -2
- package/js/es-modules/indicators/psar.src.js +1 -1
- package/js/es-modules/indicators/roc.src.js +1 -1
- package/js/es-modules/indicators/rsi.src.js +1 -1
- package/js/es-modules/indicators/stochastic.src.js +9 -7
- package/js/es-modules/indicators/volume-by-price.src.js +1 -1
- package/js/es-modules/indicators/vwap.src.js +1 -1
- package/js/es-modules/indicators/wma.src.js +1 -1
- package/js/es-modules/indicators/zigzag.src.js +1 -1
- package/js/es-modules/masters/highcharts-gantt.src.js +11 -0
- package/js/es-modules/masters/modules/annotations.src.js +1 -1
- package/js/es-modules/masters/modules/arrow-symbols.src.js +12 -0
- package/js/es-modules/masters/modules/broken-axis.src.js +1 -1
- package/js/es-modules/masters/modules/current-date-indicator.src.js +12 -0
- package/js/es-modules/masters/modules/data.src.js +1 -1
- package/js/es-modules/masters/modules/draggable-points.src.js +9 -0
- package/js/es-modules/masters/modules/export-data.src.js +1 -1
- package/js/es-modules/masters/modules/exporting.src.js +1 -1
- package/js/es-modules/masters/modules/funnel.src.js +1 -1
- package/js/es-modules/masters/modules/gantt.src.js +2 -1
- package/js/es-modules/masters/modules/grid-axis.src.js +1 -1
- package/js/es-modules/masters/modules/heatmap.src.js +1 -1
- package/js/es-modules/masters/modules/item-series.src.js +1 -1
- package/js/es-modules/masters/modules/map.src.js +1 -1
- package/js/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
- package/js/es-modules/masters/modules/pathfinder.src.js +12 -0
- package/js/es-modules/masters/modules/sankey.src.js +1 -1
- package/js/es-modules/masters/modules/series-label.src.js +1 -1
- package/js/es-modules/masters/modules/solid-gauge.src.js +1 -1
- package/js/es-modules/masters/modules/stock.src.js +1 -1
- package/js/es-modules/masters/modules/streamgraph.src.js +1 -1
- package/js/es-modules/masters/modules/treegrid.src.js +12 -0
- package/js/es-modules/masters/modules/variwide.src.js +1 -1
- package/js/es-modules/masters/modules/vector.src.js +1 -1
- package/js/es-modules/masters/modules/windbarb.src.js +1 -1
- package/js/es-modules/masters/modules/xrange.src.js +1 -1
- package/js/es-modules/masters/themes/dark-blue.src.js +1 -1
- package/js/es-modules/masters/themes/dark-green.src.js +1 -1
- package/js/es-modules/masters/themes/dark-unica.src.js +1 -1
- package/js/es-modules/masters/themes/gray.src.js +1 -1
- package/js/es-modules/masters/themes/grid-light.src.js +1 -1
- package/js/es-modules/masters/themes/grid.src.js +1 -1
- package/js/es-modules/masters/themes/sand-signika.src.js +1 -1
- package/js/es-modules/masters/themes/skies.src.js +1 -1
- package/js/es-modules/mixins/centered-series.js +36 -5
- package/js/es-modules/mixins/on-series.js +1 -1
- package/js/es-modules/mixins/polygon.js +4 -4
- package/js/es-modules/modules/annotations.src.js +2 -2
- package/js/es-modules/modules/boost-canvas.src.js +19 -8
- package/js/es-modules/modules/boost.src.js +300 -137
- package/js/es-modules/modules/broken-axis.src.js +169 -134
- package/js/es-modules/modules/bullet.src.js +2 -2
- package/js/es-modules/modules/data.src.js +8 -6
- package/js/es-modules/modules/draggable-points.src.js +2257 -0
- package/js/es-modules/modules/drilldown.src.js +4 -2
- package/js/es-modules/modules/export-data.src.js +11 -1
- package/js/es-modules/modules/exporting.src.js +62 -36
- package/js/es-modules/modules/funnel.src.js +5 -5
- package/js/es-modules/modules/histogram.src.js +30 -28
- package/js/es-modules/modules/item-series.src.js +36 -11
- package/js/es-modules/modules/keyboard-navigation.src.js +81 -44
- package/js/es-modules/modules/no-data-to-display.src.js +5 -5
- package/js/es-modules/modules/oldie.src.js +14 -9
- package/js/es-modules/modules/overlapping-datalabels.src.js +45 -21
- package/js/es-modules/modules/parallel-coordinates.src.js +4 -3
- package/js/es-modules/modules/pareto.src.js +1 -1
- package/js/es-modules/modules/sankey.src.js +23 -7
- package/js/es-modules/modules/series-label.src.js +6 -6
- package/js/es-modules/modules/solid-gauge.src.js +8 -5
- package/js/es-modules/modules/static-scale.src.js +67 -28
- package/js/es-modules/modules/streamgraph.src.js +4 -4
- package/js/es-modules/modules/sunburst.src.js +4 -4
- package/js/es-modules/modules/tilemap.src.js +231 -134
- package/js/es-modules/modules/treemap.src.js +29 -26
- package/js/es-modules/modules/variable-pie.src.js +3 -3
- package/js/es-modules/modules/variwide.src.js +36 -24
- package/js/es-modules/modules/vector.src.js +98 -28
- package/js/es-modules/modules/windbarb.src.js +4 -4
- package/js/es-modules/modules/wordcloud.src.js +133 -48
- package/js/es-modules/modules/xrange.src.js +256 -69
- package/js/es-modules/parts/AreaSeries.js +83 -50
- package/js/es-modules/parts/AreaSplineSeries.js +66 -29
- package/js/es-modules/parts/Axis.js +2089 -694
- package/js/es-modules/parts/BarSeries.js +70 -53
- package/js/es-modules/parts/CandlestickSeries.js +20 -10
- package/js/es-modules/parts/Chart.js +349 -157
- package/js/es-modules/parts/Color.js +74 -25
- package/js/es-modules/parts/ColumnSeries.js +241 -128
- package/js/es-modules/parts/DataGrouping.js +36 -3
- package/js/es-modules/parts/DataLabels.js +287 -116
- package/js/es-modules/parts/DateTimeAxis.js +27 -5
- package/js/es-modules/parts/Dynamics.js +236 -144
- package/js/es-modules/parts/FlagsSeries.js +49 -7
- package/js/es-modules/parts/Globals.js +4 -3
- package/js/es-modules/parts/Html.js +82 -16
- package/js/es-modules/parts/Interaction.js +187 -67
- package/js/es-modules/parts/Legend.js +181 -31
- package/js/es-modules/parts/LogarithmicAxis.js +36 -3
- package/js/es-modules/parts/MSPointer.js +31 -4
- package/js/es-modules/parts/Navigator.js +432 -162
- package/js/es-modules/parts/OHLCSeries.js +5 -5
- package/js/es-modules/parts/Options.js +855 -592
- package/js/es-modules/parts/OrdinalAxis.js +20 -6
- package/js/es-modules/parts/PieSeries.js +247 -134
- package/js/es-modules/parts/PlotBandSeries.experimental.js +2 -2
- package/js/es-modules/parts/PlotLineOrBand.js +671 -35
- package/js/es-modules/parts/Point.js +182 -70
- package/js/es-modules/parts/Pointer.js +263 -62
- package/js/es-modules/parts/RangeSelector.js +579 -91
- package/js/es-modules/parts/Responsive.js +82 -36
- package/js/es-modules/parts/ScatterSeries.js +58 -27
- package/js/es-modules/parts/ScrollablePlotArea.js +30 -9
- package/js/es-modules/parts/Scrollbar.js +201 -71
- package/js/es-modules/parts/Series.js +995 -745
- package/js/es-modules/parts/SplineSeries.js +53 -31
- package/js/es-modules/parts/Stacking.js +108 -7
- package/js/es-modules/parts/StockChart.js +26 -8
- package/js/es-modules/parts/SvgRenderer.js +1208 -598
- package/js/es-modules/parts/Tick.js +164 -30
- package/js/es-modules/parts/Time.js +171 -71
- package/js/es-modules/parts/Tooltip.js +276 -49
- package/js/es-modules/parts/TouchPointer.js +70 -3
- package/js/es-modules/parts/Utilities.js +1024 -429
- package/js/es-modules/parts-3d/Axis.js +4 -3
- package/js/es-modules/parts-3d/Chart.js +8 -9
- package/js/es-modules/parts-3d/Column.js +1 -1
- package/js/es-modules/parts-3d/Math.js +1 -1
- package/js/es-modules/parts-3d/Pie.js +1 -1
- package/js/es-modules/parts-3d/SVGRenderer.js +13 -10
- package/js/es-modules/parts-3d/Scatter.js +4 -4
- package/js/es-modules/parts-3d/Series.js +1 -1
- package/js/es-modules/parts-3d/VMLRenderer.js +1 -1
- package/js/es-modules/parts-gantt/ArrowSymbols.js +110 -0
- package/js/es-modules/parts-gantt/CurrentDateIndicator.js +92 -0
- package/js/es-modules/parts-gantt/GanttChart.js +111 -0
- package/js/es-modules/parts-gantt/GanttSeries.js +371 -0
- package/js/es-modules/parts-gantt/GridAxis.js +962 -0
- package/js/es-modules/parts-gantt/Pathfinder.js +1225 -0
- package/js/es-modules/parts-gantt/PathfinderAlgorithms.js +746 -0
- package/js/es-modules/parts-gantt/Tree.js +146 -0
- package/js/es-modules/parts-gantt/TreeGrid.js +891 -0
- package/js/es-modules/parts-map/ColorAxis.js +4 -5
- package/js/es-modules/parts-map/ColorSeriesMixin.js +3 -1
- package/js/es-modules/parts-map/GeoJSON.js +1 -1
- package/js/es-modules/parts-map/HeatmapSeries.js +124 -54
- package/js/es-modules/parts-map/Map.js +136 -47
- package/js/es-modules/parts-map/MapAxis.js +1 -1
- package/js/es-modules/parts-map/MapBubbleSeries.js +6 -5
- package/js/es-modules/parts-map/MapLineSeries.js +4 -4
- package/js/es-modules/parts-map/MapNavigation.js +50 -12
- package/js/es-modules/parts-map/MapPointSeries.js +3 -3
- package/js/es-modules/parts-map/MapPointer.js +1 -1
- package/js/es-modules/parts-map/MapSeries.js +5 -5
- package/js/es-modules/parts-more/AreaRangeSeries.js +82 -40
- package/js/es-modules/parts-more/AreaSplineRangeSeries.js +3 -3
- package/js/es-modules/parts-more/BoxPlotSeries.js +3 -3
- package/js/es-modules/parts-more/BubbleSeries.js +9 -4
- package/js/es-modules/parts-more/ColumnRangeSeries.js +3 -3
- package/js/es-modules/parts-more/ErrorBarSeries.js +6 -4
- package/js/es-modules/parts-more/GaugeSeries.js +3 -3
- package/js/es-modules/parts-more/Pane.js +3 -2
- package/js/es-modules/parts-more/Polar.js +1 -1
- package/js/es-modules/parts-more/PolygonSeries.js +3 -3
- package/js/es-modules/parts-more/RadialAxis.js +5 -4
- package/js/es-modules/parts-more/WaterfallSeries.js +9 -4
- package/js/es-modules/supplemental.docs.js +0 -1955
- package/js/es-modules/themes/dark-blue.js +1 -1
- package/js/es-modules/themes/dark-green.js +1 -1
- package/js/es-modules/themes/dark-unica.js +1 -1
- package/js/es-modules/themes/gray.js +1 -1
- package/js/es-modules/themes/grid-light.js +1 -1
- package/js/es-modules/themes/grid.js +1 -1
- package/js/es-modules/themes/sand-signika.js +1 -1
- package/js/es-modules/themes/skies.js +1 -1
- package/js/highcharts-3d.js +75 -74
- package/js/highcharts-3d.js.map +1 -8
- package/js/highcharts-3d.src.js +39 -32
- package/js/highcharts-gantt.js +480 -0
- package/js/highcharts-gantt.js.map +1 -0
- package/js/highcharts-gantt.src.js +47011 -0
- package/js/highcharts-more.js +63 -61
- package/js/highcharts-more.js.map +1 -8
- package/js/highcharts-more.src.js +135 -75
- package/js/highcharts.js +396 -387
- package/js/highcharts.js.map +1 -8
- package/js/highcharts.src.js +10765 -4659
- package/js/highmaps.js +419 -411
- package/js/highmaps.js.map +1 -8
- package/js/highmaps.src.js +10198 -4285
- package/js/highstock.js +529 -516
- package/js/highstock.js.map +1 -8
- package/js/highstock.src.js +12108 -4962
- package/js/indicators/accumulation-distribution.js +4 -3
- package/js/indicators/accumulation-distribution.js.map +1 -8
- package/js/indicators/accumulation-distribution.src.js +6 -2
- package/js/indicators/atr.js +4 -3
- package/js/indicators/atr.js.map +1 -8
- package/js/indicators/atr.src.js +6 -2
- package/js/indicators/bollinger-bands.js +7 -6
- package/js/indicators/bollinger-bands.js.map +1 -8
- package/js/indicators/bollinger-bands.src.js +7 -3
- package/js/indicators/cci.js +4 -3
- package/js/indicators/cci.js.map +1 -8
- package/js/indicators/cci.src.js +6 -2
- package/js/indicators/cmf.js +5 -4
- package/js/indicators/cmf.js.map +1 -8
- package/js/indicators/cmf.src.js +6 -2
- package/js/indicators/ema.js +4 -3
- package/js/indicators/ema.js.map +1 -8
- package/js/indicators/ema.src.js +6 -2
- package/js/indicators/ichimoku-kinko-hyo.js +10 -9
- package/js/indicators/ichimoku-kinko-hyo.js.map +1 -8
- package/js/indicators/ichimoku-kinko-hyo.src.js +6 -2
- package/js/indicators/indicators.js +6 -5
- package/js/indicators/indicators.js.map +1 -8
- package/js/indicators/indicators.src.js +34 -15
- package/js/indicators/macd.js +11 -10
- package/js/indicators/macd.js.map +1 -8
- package/js/indicators/macd.src.js +10 -6
- package/js/indicators/mfi.js +5 -3
- package/js/indicators/mfi.js.map +1 -8
- package/js/indicators/mfi.src.js +6 -2
- package/js/indicators/momentum.js +4 -3
- package/js/indicators/momentum.js.map +1 -8
- package/js/indicators/momentum.src.js +7 -3
- package/js/indicators/pivot-points.js +8 -7
- package/js/indicators/pivot-points.js.map +1 -8
- package/js/indicators/pivot-points.src.js +12 -3
- package/js/indicators/price-envelopes.js +7 -6
- package/js/indicators/price-envelopes.js.map +1 -8
- package/js/indicators/price-envelopes.src.js +7 -3
- package/js/indicators/psar.js +5 -4
- package/js/indicators/psar.js.map +1 -8
- package/js/indicators/psar.src.js +6 -2
- package/js/indicators/roc.js +4 -3
- package/js/indicators/roc.js.map +1 -8
- package/js/indicators/roc.src.js +6 -2
- package/js/indicators/rsi.js +4 -3
- package/js/indicators/rsi.js.map +1 -8
- package/js/indicators/rsi.src.js +6 -2
- package/js/indicators/stochastic.js +7 -5
- package/js/indicators/stochastic.js.map +1 -8
- package/js/indicators/stochastic.src.js +14 -8
- package/js/indicators/volume-by-price.js +13 -12
- package/js/indicators/volume-by-price.js.map +1 -8
- package/js/indicators/volume-by-price.src.js +6 -2
- package/js/indicators/vwap.js +4 -3
- package/js/indicators/vwap.js.map +1 -8
- package/js/indicators/vwap.src.js +6 -2
- package/js/indicators/wma.js +4 -3
- package/js/indicators/wma.js.map +1 -8
- package/js/indicators/wma.src.js +6 -2
- package/js/indicators/zigzag.js +5 -3
- package/js/indicators/zigzag.js.map +1 -8
- package/js/indicators/zigzag.src.js +6 -2
- package/js/modules/accessibility.js +52 -51
- package/js/modules/accessibility.js.map +1 -8
- package/js/modules/accessibility.src.js +86 -45
- package/js/modules/annotations.js +22 -21
- package/js/modules/annotations.js.map +1 -8
- package/js/modules/annotations.src.js +8 -4
- package/js/modules/arrow-symbols.js +13 -0
- package/js/modules/arrow-symbols.js.map +1 -0
- package/js/modules/arrow-symbols.src.js +138 -0
- package/js/modules/boost-canvas.js +15 -13
- package/js/modules/boost-canvas.js.map +1 -8
- package/js/modules/boost-canvas.src.js +24 -9
- package/js/modules/boost.js +57 -52
- package/js/modules/boost.js.map +1 -8
- package/js/modules/boost.src.js +305 -138
- package/js/modules/broken-axis.js +12 -10
- package/js/modules/broken-axis.js.map +1 -8
- package/js/modules/broken-axis.src.js +175 -136
- package/js/modules/bullet.js +3 -2
- package/js/modules/bullet.js.map +1 -8
- package/js/modules/bullet.src.js +7 -3
- package/js/modules/current-date-indicator.js +13 -0
- package/js/modules/current-date-indicator.js.map +1 -0
- package/js/modules/current-date-indicator.src.js +120 -0
- package/js/modules/data.js +25 -24
- package/js/modules/data.js.map +1 -8
- package/js/modules/data.src.js +14 -8
- package/js/modules/drag-panes.js +9 -8
- package/js/modules/drag-panes.js.map +1 -8
- package/js/modules/drag-panes.src.js +5 -1
- package/js/modules/draggable-points.js +38 -0
- package/js/modules/draggable-points.js.map +1 -0
- package/js/modules/draggable-points.src.js +2281 -0
- package/js/modules/drilldown.js +20 -19
- package/js/modules/drilldown.js.map +1 -8
- package/js/modules/drilldown.src.js +9 -3
- package/js/modules/export-data.js +20 -19
- package/js/modules/export-data.js.map +1 -8
- package/js/modules/export-data.src.js +17 -3
- package/js/modules/exporting.js +24 -23
- package/js/modules/exporting.js.map +1 -8
- package/js/modules/exporting.src.js +68 -38
- package/js/modules/funnel.js +8 -6
- package/js/modules/funnel.js.map +1 -8
- package/js/modules/funnel.src.js +11 -7
- package/js/modules/gantt.js +81 -18
- package/js/modules/gantt.js.map +1 -8
- package/js/modules/gantt.src.js +5494 -372
- package/js/modules/grid-axis.js +16 -10
- package/js/modules/grid-axis.js.map +1 -8
- package/js/modules/grid-axis.src.js +735 -293
- package/js/modules/heatmap.js +22 -21
- package/js/modules/heatmap.js.map +1 -8
- package/js/modules/heatmap.src.js +137 -62
- package/js/modules/histogram-bellcurve.js +9 -8
- package/js/modules/histogram-bellcurve.js.map +1 -8
- package/js/modules/histogram-bellcurve.src.js +35 -29
- package/js/modules/item-series.js +6 -4
- package/js/modules/item-series.js.map +1 -8
- package/js/modules/item-series.src.js +42 -13
- package/js/modules/map.js +63 -62
- package/js/modules/map.js.map +1 -8
- package/js/modules/map.src.js +353 -145
- package/js/modules/no-data-to-display.js +5 -4
- package/js/modules/no-data-to-display.js.map +1 -8
- package/js/modules/no-data-to-display.src.js +10 -6
- package/js/modules/offline-exporting.js +14 -13
- package/js/modules/offline-exporting.js.map +1 -8
- package/js/modules/offline-exporting.src.js +6 -2
- package/js/modules/oldie.js +29 -27
- package/js/modules/oldie.js.map +1 -8
- package/js/modules/oldie.src.js +20 -11
- package/js/modules/overlapping-datalabels.js +4 -3
- package/js/modules/overlapping-datalabels.js.map +1 -8
- package/js/modules/overlapping-datalabels.src.js +6 -2
- package/js/modules/parallel-coordinates.js +10 -9
- package/js/modules/parallel-coordinates.js.map +1 -8
- package/js/modules/parallel-coordinates.src.js +9 -4
- package/js/modules/pareto.js +5 -4
- package/js/modules/pareto.js.map +1 -8
- package/js/modules/pareto.src.js +6 -2
- package/js/modules/pathfinder.js +34 -0
- package/js/modules/pathfinder.js.map +1 -0
- package/js/modules/pathfinder.src.js +2106 -0
- package/js/modules/pattern-fill.js +13 -12
- package/js/modules/pattern-fill.js.map +1 -8
- package/js/modules/pattern-fill.src.js +5 -1
- package/js/modules/sankey.js +13 -12
- package/js/modules/sankey.js.map +1 -8
- package/js/modules/sankey.src.js +29 -9
- package/js/modules/series-label.js +17 -15
- package/js/modules/series-label.js.map +1 -8
- package/js/modules/series-label.src.js +12 -8
- package/js/modules/solid-gauge.js +9 -8
- package/js/modules/solid-gauge.js.map +1 -8
- package/js/modules/solid-gauge.src.js +14 -7
- package/js/modules/static-scale.js +4 -3
- package/js/modules/static-scale.js.map +1 -8
- package/js/modules/static-scale.src.js +69 -26
- package/js/modules/stock.js +136 -132
- package/js/modules/stock.js.map +1 -8
- package/js/modules/stock.src.js +1543 -499
- package/js/modules/streamgraph.js +4 -3
- package/js/modules/streamgraph.js.map +1 -8
- package/js/modules/streamgraph.src.js +10 -6
- package/js/modules/sunburst.js +40 -39
- package/js/modules/sunburst.js.map +1 -8
- package/js/modules/sunburst.src.js +38 -31
- package/js/modules/tilemap.js +19 -18
- package/js/modules/tilemap.js.map +1 -8
- package/js/modules/tilemap.src.js +363 -190
- package/js/modules/treegrid.js +51 -0
- package/js/modules/treegrid.js.map +1 -0
- package/js/modules/treegrid.src.js +2759 -0
- package/js/modules/treemap.js +27 -26
- package/js/modules/treemap.js.map +1 -8
- package/js/modules/treemap.src.js +34 -27
- package/js/modules/variable-pie.js +8 -7
- package/js/modules/variable-pie.js.map +1 -8
- package/js/modules/variable-pie.src.js +8 -4
- package/js/modules/variwide.js +8 -7
- package/js/modules/variwide.js.map +1 -8
- package/js/modules/variwide.src.js +42 -26
- package/js/modules/vector.js +7 -6
- package/js/modules/vector.js.map +1 -8
- package/js/modules/vector.src.js +104 -30
- package/js/modules/windbarb.js +11 -10
- package/js/modules/windbarb.js.map +1 -8
- package/js/modules/windbarb.src.js +11 -7
- package/js/modules/wordcloud.js +18 -15
- package/js/modules/wordcloud.js.map +1 -8
- package/js/modules/wordcloud.src.js +142 -53
- package/js/modules/xrange.js +12 -10
- package/js/modules/xrange.js.map +1 -8
- package/js/modules/xrange.src.js +262 -71
- package/js/themes/avocado.js +3 -2
- package/js/themes/avocado.js.map +1 -8
- package/js/themes/avocado.src.js +5 -1
- package/js/themes/dark-blue.js +9 -8
- package/js/themes/dark-blue.js.map +1 -8
- package/js/themes/dark-blue.src.js +7 -3
- package/js/themes/dark-green.js +9 -8
- package/js/themes/dark-green.js.map +1 -8
- package/js/themes/dark-green.src.js +7 -3
- package/js/themes/dark-unica.js +9 -7
- package/js/themes/dark-unica.js.map +1 -8
- package/js/themes/dark-unica.src.js +7 -3
- package/js/themes/gray.js +10 -8
- package/js/themes/gray.js.map +1 -8
- package/js/themes/gray.src.js +7 -3
- package/js/themes/grid-light.js +5 -4
- package/js/themes/grid-light.js.map +1 -8
- package/js/themes/grid-light.src.js +7 -3
- package/js/themes/grid.js +6 -5
- package/js/themes/grid.js.map +1 -8
- package/js/themes/grid.src.js +7 -3
- package/js/themes/sand-signika.js +6 -5
- package/js/themes/sand-signika.js.map +1 -8
- package/js/themes/sand-signika.src.js +7 -3
- package/js/themes/skies.js +6 -5
- package/js/themes/skies.js.map +1 -8
- package/js/themes/skies.src.js +7 -3
- package/js/themes/sunset.js +3 -2
- package/js/themes/sunset.js.map +1 -8
- package/js/themes/sunset.src.js +5 -1
- package/modules/accessibility.js +53 -51
- package/modules/accessibility.js.map +1 -8
- package/modules/accessibility.src.js +86 -45
- package/modules/annotations.js +24 -22
- package/modules/annotations.js.map +1 -8
- package/modules/annotations.src.js +8 -4
- package/modules/arrow-symbols.js +13 -0
- package/modules/arrow-symbols.js.map +1 -0
- package/modules/arrow-symbols.src.js +138 -0
- package/modules/boost-canvas.js +15 -13
- package/modules/boost-canvas.js.map +1 -8
- package/modules/boost-canvas.src.js +24 -9
- package/modules/boost.js +57 -52
- package/modules/boost.js.map +1 -8
- package/modules/boost.src.js +305 -138
- package/modules/broken-axis.js +12 -10
- package/modules/broken-axis.js.map +1 -8
- package/modules/broken-axis.src.js +175 -136
- package/modules/bullet.js +6 -5
- package/modules/bullet.js.map +1 -8
- package/modules/bullet.src.js +7 -3
- package/modules/current-date-indicator.js +13 -0
- package/modules/current-date-indicator.js.map +1 -0
- package/modules/current-date-indicator.src.js +120 -0
- package/modules/data.js +25 -24
- package/modules/data.js.map +1 -8
- package/modules/data.src.js +14 -8
- package/modules/drag-panes.js +9 -8
- package/modules/drag-panes.js.map +1 -8
- package/modules/drag-panes.src.js +5 -1
- package/modules/draggable-points.js +38 -0
- package/modules/draggable-points.js.map +1 -0
- package/modules/draggable-points.src.js +2281 -0
- package/modules/drilldown.js +16 -15
- package/modules/drilldown.js.map +1 -8
- package/modules/drilldown.src.js +9 -3
- package/modules/export-data.js +20 -19
- package/modules/export-data.js.map +1 -8
- package/modules/export-data.src.js +17 -3
- package/modules/exporting.js +23 -21
- package/modules/exporting.js.map +1 -8
- package/modules/exporting.src.js +68 -38
- package/modules/funnel.js +8 -7
- package/modules/funnel.js.map +1 -8
- package/modules/funnel.src.js +11 -7
- package/modules/gantt.js +84 -19
- package/modules/gantt.js.map +1 -8
- package/modules/gantt.src.js +5557 -379
- package/modules/grid-axis.js +17 -10
- package/modules/grid-axis.js.map +1 -8
- package/modules/grid-axis.src.js +736 -293
- package/modules/heatmap.js +22 -21
- package/modules/heatmap.js.map +1 -8
- package/modules/heatmap.src.js +139 -63
- package/modules/histogram-bellcurve.js +9 -8
- package/modules/histogram-bellcurve.js.map +1 -8
- package/modules/histogram-bellcurve.src.js +35 -29
- package/modules/item-series.js +6 -4
- package/modules/item-series.js.map +1 -8
- package/modules/item-series.src.js +42 -13
- package/modules/map.js +65 -64
- package/modules/map.js.map +1 -8
- package/modules/map.src.js +365 -152
- package/modules/no-data-to-display.js +5 -4
- package/modules/no-data-to-display.js.map +1 -8
- package/modules/no-data-to-display.src.js +10 -6
- package/modules/offline-exporting.js +14 -12
- package/modules/offline-exporting.js.map +1 -8
- package/modules/offline-exporting.src.js +6 -2
- package/modules/oldie.js +29 -27
- package/modules/oldie.js.map +1 -8
- package/modules/oldie.src.js +20 -11
- package/modules/overlapping-datalabels.js +4 -3
- package/modules/overlapping-datalabels.js.map +1 -8
- package/modules/overlapping-datalabels.src.js +6 -2
- package/modules/parallel-coordinates.js +10 -9
- package/modules/parallel-coordinates.js.map +1 -8
- package/modules/parallel-coordinates.src.js +9 -4
- package/modules/pareto.js +5 -4
- package/modules/pareto.js.map +1 -8
- package/modules/pareto.src.js +6 -2
- package/modules/pathfinder.js +35 -0
- package/modules/pathfinder.js.map +1 -0
- package/modules/pathfinder.src.js +2128 -0
- package/modules/pattern-fill.js +13 -12
- package/modules/pattern-fill.js.map +1 -8
- package/modules/pattern-fill.src.js +5 -1
- package/modules/sankey.js +13 -12
- package/modules/sankey.js.map +1 -8
- package/modules/sankey.src.js +34 -12
- package/modules/series-label.js +17 -15
- package/modules/series-label.js.map +1 -8
- package/modules/series-label.src.js +12 -8
- package/modules/solid-gauge.js +9 -8
- package/modules/solid-gauge.js.map +1 -8
- package/modules/solid-gauge.src.js +16 -9
- package/modules/static-scale.js +4 -3
- package/modules/static-scale.js.map +1 -8
- package/modules/static-scale.src.js +69 -26
- package/modules/stock.js +143 -139
- package/modules/stock.js.map +1 -8
- package/modules/stock.src.js +1701 -566
- package/modules/streamgraph.js +4 -3
- package/modules/streamgraph.js.map +1 -8
- package/modules/streamgraph.src.js +10 -6
- package/modules/sunburst.js +42 -41
- package/modules/sunburst.js.map +1 -8
- package/modules/sunburst.src.js +39 -32
- package/modules/tilemap.js +18 -17
- package/modules/tilemap.js.map +1 -8
- package/modules/tilemap.src.js +365 -191
- package/modules/treegrid.js +52 -0
- package/modules/treegrid.js.map +1 -0
- package/modules/treegrid.src.js +2797 -0
- package/modules/treemap.js +29 -28
- package/modules/treemap.js.map +1 -8
- package/modules/treemap.src.js +35 -28
- package/modules/variable-pie.js +8 -7
- package/modules/variable-pie.js.map +1 -8
- package/modules/variable-pie.src.js +8 -4
- package/modules/variwide.js +8 -7
- package/modules/variwide.js.map +1 -8
- package/modules/variwide.src.js +42 -26
- package/modules/vector.js +7 -6
- package/modules/vector.js.map +1 -8
- package/modules/vector.src.js +104 -30
- package/modules/windbarb.js +11 -10
- package/modules/windbarb.js.map +1 -8
- package/modules/windbarb.src.js +11 -7
- package/modules/wordcloud.js +18 -15
- package/modules/wordcloud.js.map +1 -8
- package/modules/wordcloud.src.js +142 -53
- package/modules/xrange.js +13 -11
- package/modules/xrange.js.map +1 -8
- package/modules/xrange.src.js +264 -80
- package/package.json +1 -1
- package/themes/avocado.js +3 -2
- package/themes/avocado.js.map +1 -8
- package/themes/avocado.src.js +5 -1
- package/themes/dark-blue.js +9 -8
- package/themes/dark-blue.js.map +1 -8
- package/themes/dark-blue.src.js +7 -3
- package/themes/dark-green.js +9 -8
- package/themes/dark-green.js.map +1 -8
- package/themes/dark-green.src.js +7 -3
- package/themes/dark-unica.js +9 -7
- package/themes/dark-unica.js.map +1 -8
- package/themes/dark-unica.src.js +7 -3
- package/themes/gray.js +10 -8
- package/themes/gray.js.map +1 -8
- package/themes/gray.src.js +7 -3
- package/themes/grid-light.js +5 -4
- package/themes/grid-light.js.map +1 -8
- package/themes/grid-light.src.js +7 -3
- package/themes/grid.js +6 -5
- package/themes/grid.js.map +1 -8
- package/themes/grid.src.js +7 -3
- package/themes/sand-signika.js +6 -5
- package/themes/sand-signika.js.map +1 -8
- package/themes/sand-signika.src.js +7 -3
- package/themes/skies.js +6 -5
- package/themes/skies.js.map +1 -8
- package/themes/skies.src.js +7 -3
- package/themes/sunset.js +3 -2
- package/themes/sunset.js.map +1 -8
- package/themes/sunset.src.js +5 -1
package/js/modules/stock.src.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Highcharts JS v6.
|
|
2
|
+
* @license Highcharts JS v6.2.0 (2018-10-17)
|
|
3
3
|
* Highstock as a plugin for Highcharts
|
|
4
4
|
*
|
|
5
|
-
* (c)
|
|
5
|
+
* (c) 2018 Torstein Honsi
|
|
6
6
|
*
|
|
7
7
|
* License: www.highcharts.com/license
|
|
8
8
|
*/
|
|
@@ -10,13 +10,17 @@
|
|
|
10
10
|
(function (factory) {
|
|
11
11
|
if (typeof module === 'object' && module.exports) {
|
|
12
12
|
module.exports = factory;
|
|
13
|
+
} else if (typeof define === 'function' && define.amd) {
|
|
14
|
+
define(function () {
|
|
15
|
+
return factory;
|
|
16
|
+
});
|
|
13
17
|
} else {
|
|
14
18
|
factory(Highcharts);
|
|
15
19
|
}
|
|
16
20
|
}(function (Highcharts) {
|
|
17
21
|
(function (H) {
|
|
18
22
|
/**
|
|
19
|
-
* (c) 2010-
|
|
23
|
+
* (c) 2010-2018 Torstein Honsi
|
|
20
24
|
*
|
|
21
25
|
* License: www.highcharts.com/license
|
|
22
26
|
*/
|
|
@@ -78,9 +82,14 @@
|
|
|
78
82
|
tickPixelIntervalOption = this.options.tickPixelInterval,
|
|
79
83
|
time = this.chart.time;
|
|
80
84
|
|
|
81
|
-
// The positions are not always defined, for example for ordinal positions
|
|
82
|
-
// has regular interval (#1557, #2090)
|
|
83
|
-
if (
|
|
85
|
+
// The positions are not always defined, for example for ordinal positions
|
|
86
|
+
// when data has regular interval (#1557, #2090)
|
|
87
|
+
if (
|
|
88
|
+
(!this.options.ordinal && !this.options.breaks) ||
|
|
89
|
+
!positions ||
|
|
90
|
+
positions.length < 3 ||
|
|
91
|
+
min === undefined
|
|
92
|
+
) {
|
|
84
93
|
return proceed.call(this, normalizedInterval, min, max, startOfWeek);
|
|
85
94
|
}
|
|
86
95
|
|
|
@@ -247,7 +256,8 @@
|
|
|
247
256
|
overscrollPointsRange = Number.MAX_VALUE,
|
|
248
257
|
ignoreHiddenSeries = axis.chart.options.chart.ignoreHiddenSeries,
|
|
249
258
|
isNavigatorAxis = axis.options.className === 'highcharts-navigator-xaxis',
|
|
250
|
-
i
|
|
259
|
+
i,
|
|
260
|
+
hasBoostedSeries;
|
|
251
261
|
|
|
252
262
|
if (
|
|
253
263
|
axis.options.overscroll &&
|
|
@@ -327,8 +337,16 @@
|
|
|
327
337
|
}
|
|
328
338
|
}
|
|
329
339
|
|
|
340
|
+
if (series.isSeriesBoosting) {
|
|
341
|
+
hasBoostedSeries = true;
|
|
342
|
+
}
|
|
343
|
+
|
|
330
344
|
});
|
|
331
345
|
|
|
346
|
+
if (hasBoostedSeries) {
|
|
347
|
+
ordinalPositions.length = 0;
|
|
348
|
+
}
|
|
349
|
+
|
|
332
350
|
// cache the length
|
|
333
351
|
len = ordinalPositions.length;
|
|
334
352
|
|
|
@@ -687,7 +705,7 @@
|
|
|
687
705
|
* Make the tick intervals closer because the ordinal gaps make the ticks spread out or cluster
|
|
688
706
|
*/
|
|
689
707
|
postProcessTickInterval: function (tickInterval) {
|
|
690
|
-
// Problem:
|
|
708
|
+
// Problem: https://jsfiddle.net/highcharts/FQm4E/1/
|
|
691
709
|
// This is a case where this algorithm doesn't work optimally. In this case, the
|
|
692
710
|
// tick labels are spread out per week, but all the gaps reside within weeks. So
|
|
693
711
|
// we have a situation where the labels are courser than the ordinal gaps, and
|
|
@@ -816,7 +834,7 @@
|
|
|
816
834
|
}(Highcharts));
|
|
817
835
|
(function (H) {
|
|
818
836
|
/**
|
|
819
|
-
* (c) 2009-
|
|
837
|
+
* (c) 2009-2018 Torstein Honsi
|
|
820
838
|
*
|
|
821
839
|
* License: www.highcharts.com/license
|
|
822
840
|
*/
|
|
@@ -888,8 +906,14 @@
|
|
|
888
906
|
}
|
|
889
907
|
});
|
|
890
908
|
|
|
909
|
+
addEvent(Axis, 'afterInit', function () {
|
|
910
|
+
if (typeof this.setBreaks === 'function') {
|
|
911
|
+
this.setBreaks(this.options.breaks, false);
|
|
912
|
+
}
|
|
913
|
+
});
|
|
914
|
+
|
|
891
915
|
addEvent(Axis, 'afterSetTickPositions', function () {
|
|
892
|
-
if (this.
|
|
916
|
+
if (this.isBroken) {
|
|
893
917
|
var axis = this,
|
|
894
918
|
tickPositions = this.tickPositions,
|
|
895
919
|
info = this.tickPositions.info,
|
|
@@ -909,55 +933,77 @@
|
|
|
909
933
|
|
|
910
934
|
// Force Axis to be not-ordinal when breaks are defined
|
|
911
935
|
addEvent(Axis, 'afterSetOptions', function () {
|
|
912
|
-
if (this.
|
|
936
|
+
if (this.isBroken) {
|
|
913
937
|
this.options.ordinal = false;
|
|
914
938
|
}
|
|
915
939
|
});
|
|
916
940
|
|
|
917
|
-
|
|
941
|
+
/**
|
|
942
|
+
* Dynamically set or unset breaks in an axis. This function in lighter than
|
|
943
|
+
* usin Axis.update, and it also preserves animation.
|
|
944
|
+
* @param {Array} [breaks]
|
|
945
|
+
* The breaks to add. When `undefined` it removes existing breaks.
|
|
946
|
+
* @param {Boolean} [redraw=true]
|
|
947
|
+
* Whether to redraw the chart immediately.
|
|
948
|
+
*/
|
|
949
|
+
Axis.prototype.setBreaks = function (breaks, redraw) {
|
|
918
950
|
var axis = this,
|
|
919
|
-
breaks;
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
} else if (axis.isInBreak(brk, val)) {
|
|
936
|
-
nval -= (val - brk.from);
|
|
937
|
-
break;
|
|
938
|
-
}
|
|
951
|
+
isBroken = (isArray(breaks) && !!breaks.length);
|
|
952
|
+
|
|
953
|
+
function breakVal2Lin(val) {
|
|
954
|
+
var nval = val,
|
|
955
|
+
brk,
|
|
956
|
+
i;
|
|
957
|
+
|
|
958
|
+
for (i = 0; i < axis.breakArray.length; i++) {
|
|
959
|
+
brk = axis.breakArray[i];
|
|
960
|
+
if (brk.to <= val) {
|
|
961
|
+
nval -= brk.len;
|
|
962
|
+
} else if (brk.from >= val) {
|
|
963
|
+
break;
|
|
964
|
+
} else if (axis.isInBreak(brk, val)) {
|
|
965
|
+
nval -= (val - brk.from);
|
|
966
|
+
break;
|
|
939
967
|
}
|
|
968
|
+
}
|
|
940
969
|
|
|
941
|
-
|
|
942
|
-
|
|
970
|
+
return nval;
|
|
971
|
+
}
|
|
943
972
|
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
973
|
+
function breakLin2Val(val) {
|
|
974
|
+
var nval = val,
|
|
975
|
+
brk,
|
|
976
|
+
i;
|
|
948
977
|
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
}
|
|
978
|
+
for (i = 0; i < axis.breakArray.length; i++) {
|
|
979
|
+
brk = axis.breakArray[i];
|
|
980
|
+
if (brk.from >= nval) {
|
|
981
|
+
break;
|
|
982
|
+
} else if (brk.to < nval) {
|
|
983
|
+
nval += brk.len;
|
|
984
|
+
} else if (axis.isInBreak(brk, nval)) {
|
|
985
|
+
nval += brk.len;
|
|
958
986
|
}
|
|
959
|
-
|
|
960
|
-
|
|
987
|
+
}
|
|
988
|
+
return nval;
|
|
989
|
+
}
|
|
990
|
+
|
|
991
|
+
|
|
992
|
+
axis.isDirty = axis.isBroken !== isBroken;
|
|
993
|
+
axis.isBroken = isBroken;
|
|
994
|
+
axis.options.breaks = axis.userOptions.breaks = breaks;
|
|
995
|
+
axis.forceRedraw = true; // Force recalculation in setScale
|
|
996
|
+
|
|
997
|
+
if (!isBroken && axis.val2lin === breakVal2Lin) {
|
|
998
|
+
// Revert to prototype functions
|
|
999
|
+
delete axis.val2lin;
|
|
1000
|
+
delete axis.lin2val;
|
|
1001
|
+
}
|
|
1002
|
+
|
|
1003
|
+
if (isBroken) {
|
|
1004
|
+
axis.userOptions.ordinal = false;
|
|
1005
|
+
axis.val2lin = breakVal2Lin;
|
|
1006
|
+
axis.lin2val = breakLin2Val;
|
|
961
1007
|
|
|
962
1008
|
axis.setExtremes = function (
|
|
963
1009
|
newMin,
|
|
@@ -968,11 +1014,13 @@
|
|
|
968
1014
|
) {
|
|
969
1015
|
// If trying to set extremes inside a break, extend it to before and
|
|
970
1016
|
// after the break ( #3857 )
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
1017
|
+
if (this.isBroken) {
|
|
1018
|
+
while (this.isInAnyBreak(newMin)) {
|
|
1019
|
+
newMin -= this.closestPointRange;
|
|
1020
|
+
}
|
|
1021
|
+
while (this.isInAnyBreak(newMax)) {
|
|
1022
|
+
newMax -= this.closestPointRange;
|
|
1023
|
+
}
|
|
976
1024
|
}
|
|
977
1025
|
Axis.prototype.setExtremes.call(
|
|
978
1026
|
this,
|
|
@@ -987,108 +1035,113 @@
|
|
|
987
1035
|
axis.setAxisTranslation = function (saveOld) {
|
|
988
1036
|
Axis.prototype.setAxisTranslation.call(this, saveOld);
|
|
989
1037
|
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1038
|
+
this.unitLength = null;
|
|
1039
|
+
if (this.isBroken) {
|
|
1040
|
+
var breaks = axis.options.breaks,
|
|
1041
|
+
breakArrayT = [], // Temporary one
|
|
1042
|
+
breakArray = [],
|
|
1043
|
+
length = 0,
|
|
1044
|
+
inBrk,
|
|
1045
|
+
repeat,
|
|
1046
|
+
min = axis.userMin || axis.min,
|
|
1047
|
+
max = axis.userMax || axis.max,
|
|
1048
|
+
pointRangePadding = pick(axis.pointRangePadding, 0),
|
|
1049
|
+
start,
|
|
1050
|
+
i;
|
|
1051
|
+
|
|
1052
|
+
// Min & max check (#4247)
|
|
1053
|
+
each(breaks, function (brk) {
|
|
1054
|
+
repeat = brk.repeat || Infinity;
|
|
1055
|
+
if (axis.isInBreak(brk, min)) {
|
|
1056
|
+
min += (brk.to % repeat) - (min % repeat);
|
|
1057
|
+
}
|
|
1058
|
+
if (axis.isInBreak(brk, max)) {
|
|
1059
|
+
max -= (max % repeat) - (brk.from % repeat);
|
|
1060
|
+
}
|
|
1061
|
+
});
|
|
1012
1062
|
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1063
|
+
// Construct an array holding all breaks in the axis
|
|
1064
|
+
each(breaks, function (brk) {
|
|
1065
|
+
start = brk.from;
|
|
1066
|
+
repeat = brk.repeat || Infinity;
|
|
1017
1067
|
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1068
|
+
while (start - repeat > min) {
|
|
1069
|
+
start -= repeat;
|
|
1070
|
+
}
|
|
1071
|
+
while (start < min) {
|
|
1072
|
+
start += repeat;
|
|
1073
|
+
}
|
|
1024
1074
|
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1075
|
+
for (i = start; i < max; i += repeat) {
|
|
1076
|
+
breakArrayT.push({
|
|
1077
|
+
value: i,
|
|
1078
|
+
move: 'in'
|
|
1079
|
+
});
|
|
1080
|
+
breakArrayT.push({
|
|
1081
|
+
value: i + (brk.to - brk.from),
|
|
1082
|
+
move: 'out',
|
|
1083
|
+
size: brk.breakSize
|
|
1084
|
+
});
|
|
1085
|
+
}
|
|
1086
|
+
});
|
|
1037
1087
|
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
}
|
|
1045
|
-
return ret;
|
|
1046
|
-
});
|
|
1088
|
+
breakArrayT.sort(function (a, b) {
|
|
1089
|
+
return (
|
|
1090
|
+
(a.value === b.value) ?
|
|
1091
|
+
(a.move === 'in' ? 0 : 1) - (b.move === 'in' ? 0 : 1) :
|
|
1092
|
+
a.value - b.value
|
|
1093
|
+
);
|
|
1094
|
+
});
|
|
1047
1095
|
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1096
|
+
// Simplify the breaks
|
|
1097
|
+
inBrk = 0;
|
|
1098
|
+
start = min;
|
|
1051
1099
|
|
|
1052
|
-
|
|
1053
|
-
|
|
1100
|
+
each(breakArrayT, function (brk) {
|
|
1101
|
+
inBrk += (brk.move === 'in' ? 1 : -1);
|
|
1054
1102
|
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1103
|
+
if (inBrk === 1 && brk.move === 'in') {
|
|
1104
|
+
start = brk.value;
|
|
1105
|
+
}
|
|
1106
|
+
if (inBrk === 0) {
|
|
1107
|
+
breakArray.push({
|
|
1108
|
+
from: start,
|
|
1109
|
+
to: brk.value,
|
|
1110
|
+
len: brk.value - start - (brk.size || 0)
|
|
1111
|
+
});
|
|
1112
|
+
length += brk.value - start - (brk.size || 0);
|
|
1113
|
+
}
|
|
1114
|
+
});
|
|
1067
1115
|
|
|
1068
|
-
|
|
1116
|
+
axis.breakArray = breakArray;
|
|
1069
1117
|
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1118
|
+
// Used with staticScale, and below, the actual axis length when
|
|
1119
|
+
// breaks are substracted.
|
|
1120
|
+
axis.unitLength = max - min - length + pointRangePadding;
|
|
1073
1121
|
|
|
1074
|
-
|
|
1122
|
+
fireEvent(axis, 'afterBreaks');
|
|
1075
1123
|
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1124
|
+
if (axis.staticScale) {
|
|
1125
|
+
axis.transA = axis.staticScale;
|
|
1126
|
+
} else if (axis.unitLength) {
|
|
1127
|
+
axis.transA *= (max - axis.min + pointRangePadding) /
|
|
1128
|
+
axis.unitLength;
|
|
1129
|
+
}
|
|
1082
1130
|
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1131
|
+
if (pointRangePadding) {
|
|
1132
|
+
axis.minPixelPadding = axis.transA * axis.minPointOffset;
|
|
1133
|
+
}
|
|
1086
1134
|
|
|
1087
|
-
|
|
1088
|
-
|
|
1135
|
+
axis.min = min;
|
|
1136
|
+
axis.max = max;
|
|
1137
|
+
}
|
|
1089
1138
|
};
|
|
1090
1139
|
}
|
|
1091
|
-
|
|
1140
|
+
|
|
1141
|
+
if (pick(redraw, true)) {
|
|
1142
|
+
this.chart.redraw();
|
|
1143
|
+
}
|
|
1144
|
+
};
|
|
1092
1145
|
|
|
1093
1146
|
wrap(Series.prototype, 'generatePoints', function (proceed) {
|
|
1094
1147
|
|
|
@@ -1295,7 +1348,7 @@
|
|
|
1295
1348
|
}());
|
|
1296
1349
|
(function (H) {
|
|
1297
1350
|
/**
|
|
1298
|
-
* (c) 2010-
|
|
1351
|
+
* (c) 2010-2018 Torstein Honsi
|
|
1299
1352
|
*
|
|
1300
1353
|
* License: www.highcharts.com/license
|
|
1301
1354
|
*/
|
|
@@ -1330,7 +1383,11 @@
|
|
|
1330
1383
|
*
|
|
1331
1384
|
* If data grouping is applied, the grouping information of grouped
|
|
1332
1385
|
* points can be read from the [Point.dataGroup](
|
|
1333
|
-
* /class-reference/Highcharts.Point#.dataGroup).
|
|
1386
|
+
* /class-reference/Highcharts.Point#.dataGroup). If point options other than
|
|
1387
|
+
* the data itself are set, for example `name` or `color` or custom properties,
|
|
1388
|
+
* the grouping logic doesn't know how to group it. In this case the options of
|
|
1389
|
+
* the first point instance are copied over to the group point. This can be
|
|
1390
|
+
* altered through a custom `approximation` callback function.
|
|
1334
1391
|
*
|
|
1335
1392
|
* @product highstock
|
|
1336
1393
|
* @apioption plotOptions.series.dataGrouping
|
|
@@ -1778,6 +1835,7 @@
|
|
|
1778
1835
|
) || approximations[commonOptions.approximation],
|
|
1779
1836
|
pointArrayMap = series.pointArrayMap,
|
|
1780
1837
|
pointArrayMapLength = pointArrayMap && pointArrayMap.length,
|
|
1838
|
+
extendedPointArrayMap = ['x'].concat(pointArrayMap || ['y']),
|
|
1781
1839
|
pos = 0,
|
|
1782
1840
|
start = 0,
|
|
1783
1841
|
valuesLen,
|
|
@@ -1814,6 +1872,28 @@
|
|
|
1814
1872
|
series.dataGroupInfo = { start: start, length: values[0].length };
|
|
1815
1873
|
groupedY = approximationFn.apply(series, values);
|
|
1816
1874
|
|
|
1875
|
+
// By default, let options of the first grouped point be passed over
|
|
1876
|
+
// to the grouped point. This allows preserving properties like
|
|
1877
|
+
// `name` and `color` or custom properties. Implementers can
|
|
1878
|
+
// override this from the approximation function, where they can
|
|
1879
|
+
// write custom options to `this.dataGroupInfo.options`.
|
|
1880
|
+
if (!defined(series.dataGroupInfo.options)) {
|
|
1881
|
+
// Convert numbers and arrays into objects
|
|
1882
|
+
series.dataGroupInfo.options = merge(
|
|
1883
|
+
series.pointClass.prototype
|
|
1884
|
+
.optionsToObject.call(
|
|
1885
|
+
{ series: series },
|
|
1886
|
+
series.options.data[start]
|
|
1887
|
+
)
|
|
1888
|
+
);
|
|
1889
|
+
|
|
1890
|
+
// Make sure the raw data (x, y, open, high etc) is not copied
|
|
1891
|
+
// over and overwriting approximated data.
|
|
1892
|
+
each(extendedPointArrayMap, function (key) {
|
|
1893
|
+
delete series.dataGroupInfo.options[key];
|
|
1894
|
+
});
|
|
1895
|
+
}
|
|
1896
|
+
|
|
1817
1897
|
// push the grouped data
|
|
1818
1898
|
if (groupedY !== undefined) {
|
|
1819
1899
|
groupedXData.push(pointX);
|
|
@@ -1984,7 +2064,13 @@
|
|
|
1984
2064
|
groupedXData[0] < xAxis.dataMin &&
|
|
1985
2065
|
visible
|
|
1986
2066
|
) {
|
|
1987
|
-
if (
|
|
2067
|
+
if (
|
|
2068
|
+
(
|
|
2069
|
+
!defined(xAxis.options.min) &&
|
|
2070
|
+
xAxis.min <= xAxis.dataMin
|
|
2071
|
+
) ||
|
|
2072
|
+
xAxis.min === xAxis.dataMin
|
|
2073
|
+
) {
|
|
1988
2074
|
xAxis.min = groupedXData[0];
|
|
1989
2075
|
}
|
|
1990
2076
|
xAxis.dataMin = groupedXData[0];
|
|
@@ -2298,7 +2384,7 @@
|
|
|
2298
2384
|
}(Highcharts));
|
|
2299
2385
|
(function (H) {
|
|
2300
2386
|
/**
|
|
2301
|
-
* (c) 2010-
|
|
2387
|
+
* (c) 2010-2018 Torstein Honsi
|
|
2302
2388
|
*
|
|
2303
2389
|
* License: www.highcharts.com/license
|
|
2304
2390
|
*/
|
|
@@ -2319,8 +2405,8 @@
|
|
|
2319
2405
|
* point.
|
|
2320
2406
|
*
|
|
2321
2407
|
* @sample stock/demo/ohlc/ OHLC chart
|
|
2322
|
-
* @extends
|
|
2323
|
-
* @excluding borderColor,borderRadius,borderWidth,crisp
|
|
2408
|
+
* @extends plotOptions.column
|
|
2409
|
+
* @excluding borderColor,borderRadius,borderWidth,crisp,stacking,stack
|
|
2324
2410
|
* @product highstock
|
|
2325
2411
|
* @optionparent plotOptions.ohlc
|
|
2326
2412
|
*/
|
|
@@ -2538,8 +2624,8 @@
|
|
|
2538
2624
|
* ]
|
|
2539
2625
|
* ```
|
|
2540
2626
|
*
|
|
2541
|
-
* 2. An array of objects with named values. The
|
|
2542
|
-
*
|
|
2627
|
+
* 2. An array of objects with named values. The following snippet shows only a
|
|
2628
|
+
* few settings, see the complete options set below. If the total number of data
|
|
2543
2629
|
* points exceeds the series' [turboThreshold](#series.ohlc.turboThreshold),
|
|
2544
2630
|
* this option is not available.
|
|
2545
2631
|
*
|
|
@@ -2589,7 +2675,7 @@
|
|
|
2589
2675
|
}(Highcharts));
|
|
2590
2676
|
(function (H) {
|
|
2591
2677
|
/**
|
|
2592
|
-
* (c) 2010-
|
|
2678
|
+
* (c) 2010-2018 Torstein Honsi
|
|
2593
2679
|
*
|
|
2594
2680
|
* License: www.highcharts.com/license
|
|
2595
2681
|
*/
|
|
@@ -2605,7 +2691,7 @@
|
|
|
2605
2691
|
*
|
|
2606
2692
|
* @sample stock/demo/candlestick/ Candlestick chart
|
|
2607
2693
|
*
|
|
2608
|
-
* @extends
|
|
2694
|
+
* @extends plotOptions.ohlc
|
|
2609
2695
|
* @excluding borderColor,borderRadius,borderWidth
|
|
2610
2696
|
* @product highstock
|
|
2611
2697
|
* @optionparent plotOptions.candlestick
|
|
@@ -2650,7 +2736,7 @@
|
|
|
2650
2736
|
},
|
|
2651
2737
|
|
|
2652
2738
|
/**
|
|
2653
|
-
* @extends
|
|
2739
|
+
* @extends plotOptions.ohlc.tooltip
|
|
2654
2740
|
*/
|
|
2655
2741
|
tooltip: defaultPlotOptions.ohlc.tooltip,
|
|
2656
2742
|
|
|
@@ -2678,7 +2764,8 @@
|
|
|
2678
2764
|
drawPoints: function () {
|
|
2679
2765
|
var series = this,
|
|
2680
2766
|
points = series.points,
|
|
2681
|
-
chart = series.chart
|
|
2767
|
+
chart = series.chart,
|
|
2768
|
+
reversedYAxis = series.yAxis.reversed;
|
|
2682
2769
|
|
|
2683
2770
|
|
|
2684
2771
|
each(points, function (point) {
|
|
@@ -2713,9 +2800,12 @@
|
|
|
2713
2800
|
topBox = Math.min(plotOpen, plotClose);
|
|
2714
2801
|
bottomBox = Math.max(plotOpen, plotClose);
|
|
2715
2802
|
halfWidth = Math.round(point.shapeArgs.width / 2);
|
|
2716
|
-
hasTopWhisker =
|
|
2803
|
+
hasTopWhisker = reversedYAxis ?
|
|
2804
|
+
bottomBox !== point.yBottom :
|
|
2717
2805
|
Math.round(topBox) !== Math.round(point.plotHigh);
|
|
2718
|
-
hasBottomWhisker =
|
|
2806
|
+
hasBottomWhisker = reversedYAxis ?
|
|
2807
|
+
Math.round(topBox) !== Math.round(point.plotHigh) :
|
|
2808
|
+
bottomBox !== point.yBottom;
|
|
2719
2809
|
topBox = Math.round(topBox) + crispCorr;
|
|
2720
2810
|
bottomBox = Math.round(bottomBox) + crispCorr;
|
|
2721
2811
|
|
|
@@ -2739,13 +2829,19 @@
|
|
|
2739
2829
|
crispX, topBox,
|
|
2740
2830
|
'L',
|
|
2741
2831
|
// #460, #2094
|
|
2742
|
-
crispX, hasTopWhisker ?
|
|
2832
|
+
crispX, hasTopWhisker ?
|
|
2833
|
+
Math.round(
|
|
2834
|
+
reversedYAxis ? point.yBottom : point.plotHigh
|
|
2835
|
+
) :
|
|
2836
|
+
topBox,
|
|
2743
2837
|
'M',
|
|
2744
2838
|
crispX, bottomBox,
|
|
2745
2839
|
'L',
|
|
2746
2840
|
// #460, #2094
|
|
2747
2841
|
crispX, hasBottomWhisker ?
|
|
2748
|
-
Math.round(
|
|
2842
|
+
Math.round(
|
|
2843
|
+
reversedYAxis ? point.plotHigh : point.yBottom
|
|
2844
|
+
) :
|
|
2749
2845
|
bottomBox
|
|
2750
2846
|
);
|
|
2751
2847
|
|
|
@@ -2792,8 +2888,8 @@
|
|
|
2792
2888
|
* ]
|
|
2793
2889
|
* ```
|
|
2794
2890
|
*
|
|
2795
|
-
* 2. An array of objects with named values. The
|
|
2796
|
-
*
|
|
2891
|
+
* 2. An array of objects with named values. The following snippet shows only a
|
|
2892
|
+
* few settings, see the complete options set below. If the total number of data
|
|
2797
2893
|
* points exceeds the series' [turboThreshold](
|
|
2798
2894
|
* #series.candlestick.turboThreshold), this option is not available.
|
|
2799
2895
|
*
|
|
@@ -2827,7 +2923,7 @@
|
|
|
2827
2923
|
}(Highcharts));
|
|
2828
2924
|
var onSeriesMixin = (function (H) {
|
|
2829
2925
|
/**
|
|
2830
|
-
* (c) 2010-
|
|
2926
|
+
* (c) 2010-2018 Torstein Honsi
|
|
2831
2927
|
*
|
|
2832
2928
|
* License: www.highcharts.com/license
|
|
2833
2929
|
*/
|
|
@@ -2982,7 +3078,7 @@
|
|
|
2982
3078
|
}(Highcharts));
|
|
2983
3079
|
(function (H, onSeriesMixin) {
|
|
2984
3080
|
/**
|
|
2985
|
-
* (c) 2010-
|
|
3081
|
+
* (c) 2010-2018 Torstein Honsi
|
|
2986
3082
|
*
|
|
2987
3083
|
* License: www.highcharts.com/license
|
|
2988
3084
|
*/
|
|
@@ -3060,7 +3156,7 @@
|
|
|
3060
3156
|
|
|
3061
3157
|
/**
|
|
3062
3158
|
* The shape of the marker. Can be one of "flag", "circlepin", "squarepin",
|
|
3063
|
-
* or an image
|
|
3159
|
+
* or an image of the format `url(/path-to-image.jpg)`. Individual
|
|
3064
3160
|
* shapes can also be set for each point.
|
|
3065
3161
|
*
|
|
3066
3162
|
* @validvalue ["flag", "circlepin", "squarepin"]
|
|
@@ -3137,6 +3233,27 @@
|
|
|
3137
3233
|
* @apioption plotOptions.flags.useHTML
|
|
3138
3234
|
*/
|
|
3139
3235
|
|
|
3236
|
+
/**
|
|
3237
|
+
* Fixed width of the flag's shape. By default, width is autocalculated
|
|
3238
|
+
* according to the flag's title.
|
|
3239
|
+
*
|
|
3240
|
+
* @type {Number}
|
|
3241
|
+
* @default undefined
|
|
3242
|
+
* @product highstock
|
|
3243
|
+
* @sample {highstock} stock/demo/flags-shapes/ Flags with fixed width
|
|
3244
|
+
* @apioption plotOptions.flags.width
|
|
3245
|
+
*/
|
|
3246
|
+
|
|
3247
|
+
/**
|
|
3248
|
+
* Fixed height of the flag's shape. By default, height is autocalculated
|
|
3249
|
+
* according to the flag's title.
|
|
3250
|
+
*
|
|
3251
|
+
* @type {Number}
|
|
3252
|
+
* @default undefined
|
|
3253
|
+
* @product highstock
|
|
3254
|
+
* @apioption plotOptions.flags.height
|
|
3255
|
+
*/
|
|
3256
|
+
|
|
3140
3257
|
|
|
3141
3258
|
|
|
3142
3259
|
}, /** @lends seriesTypes.flags.prototype */ {
|
|
@@ -3300,7 +3417,16 @@
|
|
|
3300
3417
|
x: box.pos,
|
|
3301
3418
|
anchorX: point.anchorX
|
|
3302
3419
|
});
|
|
3303
|
-
|
|
3420
|
+
// Hide flag when its box position is not specified (#8573)
|
|
3421
|
+
if (!box.pos) {
|
|
3422
|
+
point.graphic.attr({
|
|
3423
|
+
x: -9999,
|
|
3424
|
+
anchorX: -9999
|
|
3425
|
+
});
|
|
3426
|
+
point.graphic.isNew = true;
|
|
3427
|
+
} else {
|
|
3428
|
+
point.graphic.isNew = false;
|
|
3429
|
+
}
|
|
3304
3430
|
}
|
|
3305
3431
|
});
|
|
3306
3432
|
}
|
|
@@ -3364,9 +3490,21 @@
|
|
|
3364
3490
|
});
|
|
3365
3491
|
},
|
|
3366
3492
|
|
|
3367
|
-
|
|
3493
|
+
// Disable animation, but keep clipping (#8546):
|
|
3494
|
+
animate: function (init) {
|
|
3495
|
+
if (init) {
|
|
3496
|
+
this.setClip();
|
|
3497
|
+
} else {
|
|
3498
|
+
this.animate = null;
|
|
3499
|
+
}
|
|
3500
|
+
},
|
|
3501
|
+
setClip: function () {
|
|
3502
|
+
Series.prototype.setClip.apply(this, arguments);
|
|
3503
|
+
if (this.options.clip !== false && this.sharedClipKey) {
|
|
3504
|
+
this.markerGroup.clip(this.chart[this.sharedClipKey]);
|
|
3505
|
+
}
|
|
3506
|
+
},
|
|
3368
3507
|
buildKDTree: noop,
|
|
3369
|
-
setClip: noop,
|
|
3370
3508
|
/**
|
|
3371
3509
|
* Don't invert the flag marker group (#4960)
|
|
3372
3510
|
*/
|
|
@@ -3455,8 +3593,8 @@
|
|
|
3455
3593
|
* An array of data points for the series. For the `flags` series type,
|
|
3456
3594
|
* points can be given in the following ways:
|
|
3457
3595
|
*
|
|
3458
|
-
* 1. An array of objects with named values. The
|
|
3459
|
-
*
|
|
3596
|
+
* 1. An array of objects with named values. The following snippet shows only a
|
|
3597
|
+
* few settings, see the complete options set below. If the total number of data
|
|
3460
3598
|
* points exceeds the series' [turboThreshold](#series.flags.turboThreshold),
|
|
3461
3599
|
* this option is not available.
|
|
3462
3600
|
*
|
|
@@ -3506,7 +3644,7 @@
|
|
|
3506
3644
|
}(Highcharts, onSeriesMixin));
|
|
3507
3645
|
(function (H) {
|
|
3508
3646
|
/**
|
|
3509
|
-
* (c) 2010-
|
|
3647
|
+
* (c) 2010-2018 Torstein Honsi
|
|
3510
3648
|
*
|
|
3511
3649
|
* License: www.highcharts.com/license
|
|
3512
3650
|
*/
|
|
@@ -3523,8 +3661,6 @@
|
|
|
3523
3661
|
merge = H.merge,
|
|
3524
3662
|
pick = H.pick,
|
|
3525
3663
|
removeEvent = H.removeEvent,
|
|
3526
|
-
svg = H.svg,
|
|
3527
|
-
wrap = H.wrap,
|
|
3528
3664
|
swapXY;
|
|
3529
3665
|
|
|
3530
3666
|
/**
|
|
@@ -3554,65 +3690,115 @@
|
|
|
3554
3690
|
* of the scroll arrows so that they are always squares. Defaults to
|
|
3555
3691
|
* 20 for touch devices and 14 for mouse devices.
|
|
3556
3692
|
*
|
|
3557
|
-
* @
|
|
3558
|
-
*
|
|
3559
|
-
*
|
|
3693
|
+
* @sample {highstock} stock/scrollbar/height/
|
|
3694
|
+
* A 30px scrollbar
|
|
3695
|
+
*
|
|
3696
|
+
* @type {number}
|
|
3697
|
+
* @default 20/14
|
|
3698
|
+
* @product highstock
|
|
3699
|
+
* @apioption scrollbar.height
|
|
3560
3700
|
*/
|
|
3561
3701
|
height: isTouchDevice ? 20 : 14,
|
|
3562
3702
|
|
|
3563
3703
|
/**
|
|
3564
3704
|
* The border rounding radius of the bar.
|
|
3565
3705
|
*
|
|
3566
|
-
* @
|
|
3567
|
-
*
|
|
3568
|
-
*
|
|
3569
|
-
* @
|
|
3706
|
+
* @sample {highstock} stock/scrollbar/style/
|
|
3707
|
+
* Scrollbar styling
|
|
3708
|
+
*
|
|
3709
|
+
* @type {number}
|
|
3710
|
+
* @default 0
|
|
3711
|
+
* @product highstock
|
|
3712
|
+
* @apioption scrollbar.barBorderRadius
|
|
3570
3713
|
*/
|
|
3571
3714
|
barBorderRadius: 0,
|
|
3572
3715
|
|
|
3573
3716
|
/**
|
|
3574
3717
|
* The corner radius of the scrollbar buttons.
|
|
3575
3718
|
*
|
|
3576
|
-
* @
|
|
3577
|
-
*
|
|
3578
|
-
*
|
|
3579
|
-
* @
|
|
3719
|
+
* @sample {highstock} stock/scrollbar/style/
|
|
3720
|
+
* Scrollbar styling
|
|
3721
|
+
*
|
|
3722
|
+
* @type {number}
|
|
3723
|
+
* @default 0
|
|
3724
|
+
* @product highstock
|
|
3725
|
+
* @apioption scrollbar.buttonBorderRadius
|
|
3580
3726
|
*/
|
|
3581
3727
|
buttonBorderRadius: 0,
|
|
3582
3728
|
|
|
3729
|
+
/**
|
|
3730
|
+
* Enable or disable the scrollbar.
|
|
3731
|
+
*
|
|
3732
|
+
* @type {boolean}
|
|
3733
|
+
* @sample {highstock} stock/scrollbar/enabled/
|
|
3734
|
+
* Disable the scrollbar, only use navigator
|
|
3735
|
+
* @default true
|
|
3736
|
+
* @product highstock
|
|
3737
|
+
* @apioption scrollbar.enabled
|
|
3738
|
+
*/
|
|
3739
|
+
|
|
3583
3740
|
/**
|
|
3584
3741
|
* Whether to redraw the main chart as the scrollbar or the navigator
|
|
3585
3742
|
* zoomed window is moved. Defaults to `true` for modern browsers and
|
|
3586
3743
|
* `false` for legacy IE browsers as well as mobile devices.
|
|
3587
3744
|
*
|
|
3588
|
-
* @type
|
|
3589
|
-
* @since
|
|
3590
|
-
* @product
|
|
3745
|
+
* @type {boolean}
|
|
3746
|
+
* @since 1.3
|
|
3747
|
+
* @product highstock
|
|
3748
|
+
*
|
|
3749
|
+
* @sample stock/scrollbar/liveredraw Setting live redraw to false
|
|
3750
|
+
*
|
|
3751
|
+
* @apioption scrollbar.liveRedraw
|
|
3591
3752
|
*/
|
|
3592
|
-
liveRedraw:
|
|
3753
|
+
liveRedraw: undefined,
|
|
3593
3754
|
|
|
3594
3755
|
/**
|
|
3595
3756
|
* The margin between the scrollbar and its axis when the scrollbar is
|
|
3596
3757
|
* applied directly to an axis.
|
|
3758
|
+
*
|
|
3759
|
+
* @type {number}
|
|
3760
|
+
* @default 10
|
|
3761
|
+
* @apioption scrollbar.margin
|
|
3597
3762
|
*/
|
|
3598
3763
|
margin: 10,
|
|
3599
3764
|
|
|
3600
3765
|
/**
|
|
3601
3766
|
* The minimum width of the scrollbar.
|
|
3602
3767
|
*
|
|
3603
|
-
* @type
|
|
3604
|
-
* @default
|
|
3605
|
-
* @since
|
|
3606
|
-
* @product
|
|
3768
|
+
* @type {number}
|
|
3769
|
+
* @default 6
|
|
3770
|
+
* @since 1.2.5
|
|
3771
|
+
* @product highstock
|
|
3772
|
+
* @apioption scrollbar.minWidth
|
|
3607
3773
|
*/
|
|
3608
3774
|
minWidth: 6,
|
|
3609
3775
|
|
|
3776
|
+
/**
|
|
3777
|
+
* Whether to show or hide the scrollbar when the scrolled content is
|
|
3778
|
+
* zoomed out to it full extent.
|
|
3779
|
+
*
|
|
3780
|
+
* @type {boolean}
|
|
3781
|
+
* @default true
|
|
3782
|
+
* @product highstock
|
|
3783
|
+
* @apioption scrollbar.showFull
|
|
3784
|
+
*/
|
|
3785
|
+
|
|
3786
|
+
/**
|
|
3787
|
+
* @type {number}
|
|
3788
|
+
* @default 0.2
|
|
3789
|
+
* @apioption scrollbar.step
|
|
3790
|
+
*/
|
|
3610
3791
|
step: 0.2,
|
|
3611
3792
|
|
|
3612
3793
|
/**
|
|
3613
3794
|
* The z index of the scrollbar group.
|
|
3795
|
+
*
|
|
3796
|
+
* @type {number}
|
|
3797
|
+
* @default 3
|
|
3798
|
+
* @apioption scrollbar.zIndex
|
|
3614
3799
|
*/
|
|
3615
3800
|
zIndex: 3
|
|
3801
|
+
|
|
3616
3802
|
|
|
3617
3803
|
};
|
|
3618
3804
|
|
|
@@ -3623,11 +3809,19 @@
|
|
|
3623
3809
|
);
|
|
3624
3810
|
|
|
3625
3811
|
/**
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
|
|
3630
|
-
|
|
3812
|
+
* When we have vertical scrollbar, rifles and arrow in buttons should be
|
|
3813
|
+
* rotated. The same method is used in Navigator's handles, to rotate them.
|
|
3814
|
+
*
|
|
3815
|
+
* @function Highcharts.swapXY
|
|
3816
|
+
*
|
|
3817
|
+
* @param {Array<number|string>} path
|
|
3818
|
+
* Path to be rotated.
|
|
3819
|
+
*
|
|
3820
|
+
* @param {boolean} vertical
|
|
3821
|
+
* If vertical scrollbar, swap x-y values.
|
|
3822
|
+
*
|
|
3823
|
+
* @return {Array<number|string>}
|
|
3824
|
+
*/
|
|
3631
3825
|
H.swapXY = swapXY = function (path, vertical) {
|
|
3632
3826
|
var i,
|
|
3633
3827
|
len = path.length,
|
|
@@ -3648,10 +3842,13 @@
|
|
|
3648
3842
|
* A reusable scrollbar, internally used in Highstock's navigator and optionally
|
|
3649
3843
|
* on individual axes.
|
|
3650
3844
|
*
|
|
3651
|
-
* @class
|
|
3652
|
-
*
|
|
3653
|
-
* @param {
|
|
3654
|
-
*
|
|
3845
|
+
* @class Highcharts.Scrollbar
|
|
3846
|
+
*
|
|
3847
|
+
* @param {Highcharts.SVGRenderer} renderer
|
|
3848
|
+
*
|
|
3849
|
+
* @param {Highcharts.ScrollbarOptions} options
|
|
3850
|
+
*
|
|
3851
|
+
* @param {Highcharts.Chart} chart
|
|
3655
3852
|
*/
|
|
3656
3853
|
function Scrollbar(renderer, options, chart) { // docs
|
|
3657
3854
|
this.init(renderer, options, chart);
|
|
@@ -3659,6 +3856,17 @@
|
|
|
3659
3856
|
|
|
3660
3857
|
Scrollbar.prototype = {
|
|
3661
3858
|
|
|
3859
|
+
/**
|
|
3860
|
+
* @function Highcharts.Scrollbar#init
|
|
3861
|
+
*
|
|
3862
|
+
* @param {Highcharts.SVGRenderer} renderer
|
|
3863
|
+
*
|
|
3864
|
+
* @param {Highcharts.ScrollbarOptions} options
|
|
3865
|
+
*
|
|
3866
|
+
* @param {Highcharts.Chart} chart
|
|
3867
|
+
*
|
|
3868
|
+
* @return {void}
|
|
3869
|
+
*/
|
|
3662
3870
|
init: function (renderer, options, chart) {
|
|
3663
3871
|
|
|
3664
3872
|
this.scrollbarButtons = [];
|
|
@@ -3683,6 +3891,10 @@
|
|
|
3683
3891
|
|
|
3684
3892
|
/**
|
|
3685
3893
|
* Render scrollbar with all required items.
|
|
3894
|
+
*
|
|
3895
|
+
* @function Highcharts.Scrollbar#render
|
|
3896
|
+
*
|
|
3897
|
+
* @return {void}
|
|
3686
3898
|
*/
|
|
3687
3899
|
render: function () {
|
|
3688
3900
|
var scroller = this,
|
|
@@ -3758,10 +3970,22 @@
|
|
|
3758
3970
|
/**
|
|
3759
3971
|
* Position the scrollbar, method called from a parent with defined
|
|
3760
3972
|
* dimensions.
|
|
3761
|
-
*
|
|
3762
|
-
* @
|
|
3763
|
-
*
|
|
3764
|
-
* @param
|
|
3973
|
+
*
|
|
3974
|
+
* @function Highcharts.Scrollbar#position
|
|
3975
|
+
*
|
|
3976
|
+
* @param {number} x
|
|
3977
|
+
* x-position on the chart
|
|
3978
|
+
*
|
|
3979
|
+
* @param {number} y
|
|
3980
|
+
* y-position on the chart
|
|
3981
|
+
*
|
|
3982
|
+
* @param {number} width
|
|
3983
|
+
* width of the scrollbar
|
|
3984
|
+
*
|
|
3985
|
+
* @param {number} height
|
|
3986
|
+
* height of the scorllbar
|
|
3987
|
+
*
|
|
3988
|
+
* @return {void}
|
|
3765
3989
|
*/
|
|
3766
3990
|
position: function (x, y, width, height) {
|
|
3767
3991
|
var scroller = this,
|
|
@@ -3812,7 +4036,13 @@
|
|
|
3812
4036
|
|
|
3813
4037
|
/**
|
|
3814
4038
|
* Draw the scrollbar buttons with arrows
|
|
3815
|
-
*
|
|
4039
|
+
*
|
|
4040
|
+
* @function Highcharts.Scrollbar#drawScrollbarButton
|
|
4041
|
+
*
|
|
4042
|
+
* @param {number} index
|
|
4043
|
+
* 0 is left, 1 is right
|
|
4044
|
+
*
|
|
4045
|
+
* @return {void}
|
|
3816
4046
|
*/
|
|
3817
4047
|
drawScrollbarButton: function (index) {
|
|
3818
4048
|
var scroller = this,
|
|
@@ -3863,8 +4093,16 @@
|
|
|
3863
4093
|
|
|
3864
4094
|
/**
|
|
3865
4095
|
* Set scrollbar size, with a given scale.
|
|
3866
|
-
*
|
|
3867
|
-
* @
|
|
4096
|
+
*
|
|
4097
|
+
* @function Highcharts.Scrollbar#setRange
|
|
4098
|
+
*
|
|
4099
|
+
* @param {number} from
|
|
4100
|
+
* scale (0-1) where bar should start
|
|
4101
|
+
*
|
|
4102
|
+
* @param {number} to
|
|
4103
|
+
* scale (0-1) where bar should end
|
|
4104
|
+
*
|
|
4105
|
+
* @return {void}
|
|
3868
4106
|
*/
|
|
3869
4107
|
setRange: function (from, to) {
|
|
3870
4108
|
var scroller = this,
|
|
@@ -3877,7 +4115,11 @@
|
|
|
3877
4115
|
newPos,
|
|
3878
4116
|
newSize,
|
|
3879
4117
|
newRiflesPos,
|
|
3880
|
-
method =
|
|
4118
|
+
method = (
|
|
4119
|
+
this.rendered &&
|
|
4120
|
+
!this.hasDragged &&
|
|
4121
|
+
!(this.chart.navigator && this.chart.navigator.hasDragged)
|
|
4122
|
+
) ? 'animate' : 'attr';
|
|
3881
4123
|
|
|
3882
4124
|
if (!defined(fullWidth)) {
|
|
3883
4125
|
return;
|
|
@@ -3946,6 +4188,13 @@
|
|
|
3946
4188
|
|
|
3947
4189
|
/**
|
|
3948
4190
|
* Init events methods, so we have an access to the Scrollbar itself
|
|
4191
|
+
*
|
|
4192
|
+
* @function Highcharts.Scrollbar#initEvents
|
|
4193
|
+
*
|
|
4194
|
+
* @return {void}
|
|
4195
|
+
*
|
|
4196
|
+
* @todo
|
|
4197
|
+
* Make events official: Fires the event `changed`.
|
|
3949
4198
|
*/
|
|
3950
4199
|
initEvents: function () {
|
|
3951
4200
|
var scroller = this;
|
|
@@ -4086,9 +4335,14 @@
|
|
|
4086
4335
|
|
|
4087
4336
|
/**
|
|
4088
4337
|
* Get normalized (0-1) cursor position over the scrollbar
|
|
4089
|
-
*
|
|
4090
|
-
*
|
|
4091
|
-
*
|
|
4338
|
+
*
|
|
4339
|
+
* @function Highcharts.Scrollbar#cursorToScrollbarPosition
|
|
4340
|
+
*
|
|
4341
|
+
* @param {*} normalizedEvent
|
|
4342
|
+
* normalized event, with chartX and chartY values
|
|
4343
|
+
*
|
|
4344
|
+
* @return {*}
|
|
4345
|
+
* Local position {chartX, chartY}
|
|
4092
4346
|
*/
|
|
4093
4347
|
cursorToScrollbarPosition: function (normalizedEvent) {
|
|
4094
4348
|
var scroller = this,
|
|
@@ -4107,6 +4361,14 @@
|
|
|
4107
4361
|
|
|
4108
4362
|
/**
|
|
4109
4363
|
* Update position option in the Scrollbar, with normalized 0-1 scale
|
|
4364
|
+
*
|
|
4365
|
+
* @function Highcharts.Scrollbar#updatePosition
|
|
4366
|
+
*
|
|
4367
|
+
* @param {number} from
|
|
4368
|
+
*
|
|
4369
|
+
* @param {number} to
|
|
4370
|
+
*
|
|
4371
|
+
* @return {void}
|
|
4110
4372
|
*/
|
|
4111
4373
|
updatePosition: function (from, to) {
|
|
4112
4374
|
if (to > 1) {
|
|
@@ -4125,6 +4387,12 @@
|
|
|
4125
4387
|
|
|
4126
4388
|
/**
|
|
4127
4389
|
* Update the scrollbar with new options
|
|
4390
|
+
*
|
|
4391
|
+
* @function Highcharts.Scrollbar#update
|
|
4392
|
+
*
|
|
4393
|
+
* @param {Highcharts.ScrollbarOptions} options
|
|
4394
|
+
*
|
|
4395
|
+
* @return {void}
|
|
4128
4396
|
*/
|
|
4129
4397
|
update: function (options) {
|
|
4130
4398
|
this.destroy();
|
|
@@ -4137,6 +4405,10 @@
|
|
|
4137
4405
|
|
|
4138
4406
|
/**
|
|
4139
4407
|
* Set up the mouse and touch events for the Scrollbar
|
|
4408
|
+
*
|
|
4409
|
+
* @function Highcharts.Scrollbar#addEvents
|
|
4410
|
+
*
|
|
4411
|
+
* @return {void}
|
|
4140
4412
|
*/
|
|
4141
4413
|
addEvents: function () {
|
|
4142
4414
|
var buttonsOrder = this.options.inverted ? [1, 0] : [0, 1],
|
|
@@ -4176,6 +4448,10 @@
|
|
|
4176
4448
|
|
|
4177
4449
|
/**
|
|
4178
4450
|
* Removes the event handlers attached previously with addEvents.
|
|
4451
|
+
*
|
|
4452
|
+
* @function Highcharts.Scrollbar#removeEvents
|
|
4453
|
+
*
|
|
4454
|
+
* @return {void}
|
|
4179
4455
|
*/
|
|
4180
4456
|
removeEvents: function () {
|
|
4181
4457
|
each(this._events, function (args) {
|
|
@@ -4186,6 +4462,10 @@
|
|
|
4186
4462
|
|
|
4187
4463
|
/**
|
|
4188
4464
|
* Destroys allocated elements.
|
|
4465
|
+
*
|
|
4466
|
+
* @function Highcharts.Scrollbar#destroy
|
|
4467
|
+
*
|
|
4468
|
+
* @return {void}
|
|
4189
4469
|
*/
|
|
4190
4470
|
destroy: function () {
|
|
4191
4471
|
|
|
@@ -4221,14 +4501,17 @@
|
|
|
4221
4501
|
}
|
|
4222
4502
|
};
|
|
4223
4503
|
|
|
4224
|
-
|
|
4225
|
-
|
|
4226
|
-
|
|
4227
|
-
|
|
4504
|
+
/*
|
|
4505
|
+
* Wrap axis initialization and create scrollbar if enabled:
|
|
4506
|
+
*/
|
|
4507
|
+
addEvent(Axis, 'afterInit', function () {
|
|
4228
4508
|
var axis = this;
|
|
4229
|
-
proceed.apply(axis, Array.prototype.slice.call(arguments, 1));
|
|
4230
4509
|
|
|
4231
|
-
if (
|
|
4510
|
+
if (
|
|
4511
|
+
axis.options &&
|
|
4512
|
+
axis.options.scrollbar &&
|
|
4513
|
+
axis.options.scrollbar.enabled
|
|
4514
|
+
) {
|
|
4232
4515
|
// Predefined options:
|
|
4233
4516
|
axis.options.scrollbar.vertical = !axis.horiz;
|
|
4234
4517
|
axis.options.startOnTick = axis.options.endOnTick = false;
|
|
@@ -4272,10 +4555,10 @@
|
|
|
4272
4555
|
}
|
|
4273
4556
|
});
|
|
4274
4557
|
|
|
4275
|
-
|
|
4276
|
-
|
|
4277
|
-
|
|
4278
|
-
|
|
4558
|
+
/*
|
|
4559
|
+
* Wrap rendering axis, and update scrollbar if one is created:
|
|
4560
|
+
*/
|
|
4561
|
+
addEvent(Axis, 'afterRender', function () {
|
|
4279
4562
|
var axis = this,
|
|
4280
4563
|
scrollMin = Math.min(
|
|
4281
4564
|
pick(axis.options.min, axis.min),
|
|
@@ -4293,8 +4576,6 @@
|
|
|
4293
4576
|
from,
|
|
4294
4577
|
to;
|
|
4295
4578
|
|
|
4296
|
-
proceed.apply(axis, Array.prototype.slice.call(arguments, 1));
|
|
4297
|
-
|
|
4298
4579
|
if (scrollbar) {
|
|
4299
4580
|
|
|
4300
4581
|
if (axis.horiz) {
|
|
@@ -4353,16 +4634,14 @@
|
|
|
4353
4634
|
}
|
|
4354
4635
|
});
|
|
4355
4636
|
|
|
4356
|
-
|
|
4357
|
-
|
|
4358
|
-
|
|
4359
|
-
|
|
4637
|
+
/*
|
|
4638
|
+
* Make space for a scrollbar
|
|
4639
|
+
*/
|
|
4640
|
+
addEvent(Axis, 'afterGetOffset', function () {
|
|
4360
4641
|
var axis = this,
|
|
4361
4642
|
index = axis.horiz ? 2 : 1,
|
|
4362
4643
|
scrollbar = axis.scrollbar;
|
|
4363
4644
|
|
|
4364
|
-
proceed.apply(axis, Array.prototype.slice.call(arguments, 1));
|
|
4365
|
-
|
|
4366
4645
|
if (scrollbar) {
|
|
4367
4646
|
axis.chart.scrollbarsOffsets = [0, 0]; // reset scrollbars offsets
|
|
4368
4647
|
axis.chart.axisOffset[index] +=
|
|
@@ -4370,58 +4649,17 @@
|
|
|
4370
4649
|
}
|
|
4371
4650
|
});
|
|
4372
4651
|
|
|
4373
|
-
/**
|
|
4374
|
-
* Destroy scrollbar when connected to the specific axis
|
|
4375
|
-
*/
|
|
4376
|
-
wrap(Axis.prototype, 'destroy', function (proceed) {
|
|
4377
|
-
if (this.scrollbar) {
|
|
4378
|
-
this.scrollbar = this.scrollbar.destroy();
|
|
4379
|
-
}
|
|
4380
|
-
|
|
4381
|
-
proceed.apply(this, Array.prototype.slice.call(arguments, 1));
|
|
4382
|
-
});
|
|
4383
|
-
|
|
4384
4652
|
H.Scrollbar = Scrollbar;
|
|
4385
4653
|
|
|
4386
4654
|
}(Highcharts));
|
|
4387
4655
|
(function (H) {
|
|
4388
4656
|
/**
|
|
4389
|
-
* (c) 2010-
|
|
4657
|
+
* (c) 2010-2018 Torstein Honsi
|
|
4390
4658
|
*
|
|
4391
4659
|
* License: www.highcharts.com/license
|
|
4392
4660
|
*/
|
|
4393
4661
|
|
|
4394
4662
|
|
|
4395
|
-
/**
|
|
4396
|
-
* Options for the corresponding navigator series if `showInNavigator`
|
|
4397
|
-
* is `true` for this series. Available options are the same as any
|
|
4398
|
-
* series, documented at [plotOptions](#plotOptions.series) and
|
|
4399
|
-
* [series](#series).
|
|
4400
|
-
*
|
|
4401
|
-
*
|
|
4402
|
-
* These options are merged with options in [navigator.series](
|
|
4403
|
-
* #navigator.series), and will take precedence if the same option is defined
|
|
4404
|
-
* both places.
|
|
4405
|
-
*
|
|
4406
|
-
* @type {Object}
|
|
4407
|
-
* @see [navigator.series](#navigator.series)
|
|
4408
|
-
* @default undefined
|
|
4409
|
-
* @since 5.0.0
|
|
4410
|
-
* @product highstock
|
|
4411
|
-
* @apioption plotOptions.series.navigatorOptions
|
|
4412
|
-
*/
|
|
4413
|
-
|
|
4414
|
-
/**
|
|
4415
|
-
* Whether or not to show the series in the navigator. Takes precedence
|
|
4416
|
-
* over [navigator.baseSeries](#navigator.baseSeries) if defined.
|
|
4417
|
-
*
|
|
4418
|
-
* @type {Boolean}
|
|
4419
|
-
* @default undefined
|
|
4420
|
-
* @since 5.0.0
|
|
4421
|
-
* @product highstock
|
|
4422
|
-
* @apioption plotOptions.series.showInNavigator
|
|
4423
|
-
*/
|
|
4424
|
-
|
|
4425
4663
|
var addEvent = H.addEvent,
|
|
4426
4664
|
Axis = H.Axis,
|
|
4427
4665
|
Chart = H.Chart,
|
|
@@ -4480,24 +4718,85 @@
|
|
|
4480
4718
|
* @optionparent navigator
|
|
4481
4719
|
*/
|
|
4482
4720
|
navigator: {
|
|
4721
|
+
|
|
4722
|
+
/**
|
|
4723
|
+
* Whether the navigator and scrollbar should adapt to updated data
|
|
4724
|
+
* in the base X axis. When loading data async, as in the demo below,
|
|
4725
|
+
* this should be `false`. Otherwise new data will trigger navigator
|
|
4726
|
+
* redraw, which will cause unwanted looping. In the demo below, the
|
|
4727
|
+
* data in the navigator is set only once. On navigating, only the main
|
|
4728
|
+
* chart content is updated.
|
|
4729
|
+
*
|
|
4730
|
+
* @sample {highstock} stock/demo/lazy-loading/
|
|
4731
|
+
* Set to false with async data loading
|
|
4732
|
+
*
|
|
4733
|
+
* @type {boolean}
|
|
4734
|
+
* @default true
|
|
4735
|
+
* @product highstock
|
|
4736
|
+
* @apioption navigator.adaptToUpdatedData
|
|
4737
|
+
*/
|
|
4738
|
+
|
|
4739
|
+
/**
|
|
4740
|
+
* An integer identifying the index to use for the base series, or a
|
|
4741
|
+
* string representing the id of the series.
|
|
4742
|
+
*
|
|
4743
|
+
* **Note**: As of Highcharts 5.0, this is now a deprecated option.
|
|
4744
|
+
* Prefer [series.showInNavigator](#plotOptions.series.showInNavigator).
|
|
4745
|
+
*
|
|
4746
|
+
* @see [series.showInNavigator](#plotOptions.series.showInNavigator)
|
|
4747
|
+
*
|
|
4748
|
+
* @deprecated
|
|
4749
|
+
* @type {*}
|
|
4750
|
+
* @default 0
|
|
4751
|
+
* @product highstock
|
|
4752
|
+
* @apioption navigator.baseSeries
|
|
4753
|
+
*/
|
|
4754
|
+
|
|
4755
|
+
/**
|
|
4756
|
+
* Enable or disable the navigator.
|
|
4757
|
+
*
|
|
4758
|
+
* @sample {highstock} stock/navigator/enabled/ Disable the navigator
|
|
4759
|
+
*
|
|
4760
|
+
* @type {boolean}
|
|
4761
|
+
* @default true
|
|
4762
|
+
* @product highstock
|
|
4763
|
+
* @apioption navigator.enabled
|
|
4764
|
+
*/
|
|
4765
|
+
|
|
4766
|
+
/**
|
|
4767
|
+
* When the chart is inverted, whether to draw the navigator on the
|
|
4768
|
+
* opposite side.
|
|
4769
|
+
*
|
|
4770
|
+
* @type {boolean}
|
|
4771
|
+
* @default false
|
|
4772
|
+
* @since 5.0.8
|
|
4773
|
+
* @product highstock
|
|
4774
|
+
* @apioption navigator.opposite
|
|
4775
|
+
*/
|
|
4776
|
+
|
|
4483
4777
|
/**
|
|
4484
4778
|
* The height of the navigator.
|
|
4485
4779
|
*
|
|
4486
|
-
* @
|
|
4487
|
-
*
|
|
4488
|
-
*
|
|
4489
|
-
* @
|
|
4780
|
+
* @sample {highstock} stock/navigator/height/
|
|
4781
|
+
* A higher navigator
|
|
4782
|
+
*
|
|
4783
|
+
* @type {number}
|
|
4784
|
+
* @default 40
|
|
4785
|
+
* @product highstock
|
|
4786
|
+
* @apioption navigator.height
|
|
4490
4787
|
*/
|
|
4491
4788
|
height: 40,
|
|
4492
4789
|
|
|
4493
4790
|
/**
|
|
4494
4791
|
* The distance from the nearest element, the X axis or X axis labels.
|
|
4495
4792
|
*
|
|
4496
|
-
* @type {Number}
|
|
4497
4793
|
* @sample {highstock} stock/navigator/margin/
|
|
4498
4794
|
* A margin of 2 draws the navigator closer to the X axis labels
|
|
4499
|
-
*
|
|
4500
|
-
* @
|
|
4795
|
+
*
|
|
4796
|
+
* @type {number}
|
|
4797
|
+
* @default 25
|
|
4798
|
+
* @product highstock
|
|
4799
|
+
* @apioption navigator.margin
|
|
4501
4800
|
*/
|
|
4502
4801
|
margin: 25,
|
|
4503
4802
|
|
|
@@ -4505,44 +4804,53 @@
|
|
|
4505
4804
|
* Whether the mask should be inside the range marking the zoomed
|
|
4506
4805
|
* range, or outside. In Highstock 1.x it was always `false`.
|
|
4507
4806
|
*
|
|
4508
|
-
* @type {Boolean}
|
|
4509
4807
|
* @sample {highstock} stock/navigator/maskinside-false/
|
|
4510
4808
|
* False, mask outside
|
|
4511
|
-
*
|
|
4512
|
-
* @
|
|
4513
|
-
* @
|
|
4809
|
+
*
|
|
4810
|
+
* @type {boolean}
|
|
4811
|
+
* @default true
|
|
4812
|
+
* @since 2.0
|
|
4813
|
+
* @product highstock
|
|
4814
|
+
* @apioption navigator.maskInside
|
|
4514
4815
|
*/
|
|
4515
4816
|
maskInside: true,
|
|
4516
4817
|
|
|
4517
4818
|
/**
|
|
4518
4819
|
* Options for the handles for dragging the zoomed area.
|
|
4519
4820
|
*
|
|
4520
|
-
* @
|
|
4521
|
-
*
|
|
4522
|
-
*
|
|
4821
|
+
* @sample {highstock} stock/navigator/handles/
|
|
4822
|
+
* Colored handles
|
|
4823
|
+
*
|
|
4824
|
+
* @type {*}
|
|
4825
|
+
* @product highstock
|
|
4826
|
+
* @apioption navigator.handles
|
|
4523
4827
|
*/
|
|
4524
4828
|
handles: {
|
|
4525
4829
|
/**
|
|
4526
4830
|
* Width for handles.
|
|
4527
4831
|
*
|
|
4528
|
-
* @type {Number}
|
|
4529
|
-
* @default 7
|
|
4530
|
-
* @product highstock
|
|
4531
4832
|
* @sample {highstock} stock/navigator/styled-handles/
|
|
4532
4833
|
* Styled handles
|
|
4533
|
-
*
|
|
4834
|
+
*
|
|
4835
|
+
* @type {number}
|
|
4836
|
+
* @default 7
|
|
4837
|
+
* @since 6.0.0
|
|
4838
|
+
* @product highstock
|
|
4839
|
+
* @apioption navigator.handles.width
|
|
4534
4840
|
*/
|
|
4535
4841
|
width: 7,
|
|
4536
4842
|
|
|
4537
4843
|
/**
|
|
4538
4844
|
* Height for handles.
|
|
4539
4845
|
*
|
|
4540
|
-
* @type {Number}
|
|
4541
|
-
* @default 15
|
|
4542
|
-
* @product highstock
|
|
4543
4846
|
* @sample {highstock} stock/navigator/styled-handles/
|
|
4544
4847
|
* Styled handles
|
|
4545
|
-
*
|
|
4848
|
+
*
|
|
4849
|
+
* @type {number}
|
|
4850
|
+
* @default 15
|
|
4851
|
+
* @since 6.0.0
|
|
4852
|
+
* @product highstock
|
|
4853
|
+
* @apioption navigator.handles.height
|
|
4546
4854
|
*/
|
|
4547
4855
|
height: 15,
|
|
4548
4856
|
|
|
@@ -4559,22 +4867,25 @@
|
|
|
4559
4867
|
* `Highcharts.SVGRenderer.prototype.symbols`. The callback is then
|
|
4560
4868
|
* used by its method name, as shown in the demo.
|
|
4561
4869
|
*
|
|
4562
|
-
* @type {Array}
|
|
4563
|
-
* @default ['navigator-handle', 'navigator-handle']
|
|
4564
|
-
* @product highstock
|
|
4565
4870
|
* @sample {highstock} stock/navigator/styled-handles/
|
|
4566
4871
|
* Styled handles
|
|
4567
|
-
*
|
|
4872
|
+
*
|
|
4873
|
+
* @type {Array<string>}
|
|
4874
|
+
* @default ['navigator-handle', 'navigator-handle']
|
|
4875
|
+
* @since 6.0.0
|
|
4876
|
+
* @product highstock
|
|
4877
|
+
* @apioption navigator.handles.symbols
|
|
4568
4878
|
*/
|
|
4569
4879
|
symbols: ['navigator-handle', 'navigator-handle'],
|
|
4570
4880
|
|
|
4571
4881
|
/**
|
|
4572
4882
|
* Allows to enable/disable handles.
|
|
4573
4883
|
*
|
|
4574
|
-
* @type
|
|
4575
|
-
* @default
|
|
4576
|
-
* @
|
|
4577
|
-
* @
|
|
4884
|
+
* @type {boolean}
|
|
4885
|
+
* @default true
|
|
4886
|
+
* @since 6.0.0
|
|
4887
|
+
* @product highstock
|
|
4888
|
+
* @apioption navigator.handles.enabled
|
|
4578
4889
|
*/
|
|
4579
4890
|
enabled: true
|
|
4580
4891
|
|
|
@@ -4605,14 +4916,17 @@
|
|
|
4605
4916
|
* }
|
|
4606
4917
|
* }</pre>
|
|
4607
4918
|
*
|
|
4608
|
-
* @type {Object}
|
|
4609
4919
|
* @see In styled mode, the navigator series is styled with the
|
|
4610
4920
|
* `.highcharts-navigator-series` class.
|
|
4921
|
+
*
|
|
4611
4922
|
* @sample {highstock} stock/navigator/series-data/
|
|
4612
4923
|
* Using a separate data set for the navigator
|
|
4613
4924
|
* @sample {highstock} stock/navigator/series/
|
|
4614
4925
|
* A green navigator series
|
|
4615
|
-
*
|
|
4926
|
+
*
|
|
4927
|
+
* @type {*}
|
|
4928
|
+
* @product highstock
|
|
4929
|
+
* @apioption navigator.series
|
|
4616
4930
|
*/
|
|
4617
4931
|
series: {
|
|
4618
4932
|
|
|
@@ -4620,7 +4934,9 @@
|
|
|
4620
4934
|
* The type of the navigator series. Defaults to `areaspline` if
|
|
4621
4935
|
* defined, otherwise `line`.
|
|
4622
4936
|
*
|
|
4623
|
-
* @type
|
|
4937
|
+
* @type {string}
|
|
4938
|
+
* @default areaspline
|
|
4939
|
+
* @apioption navigator.series.type
|
|
4624
4940
|
*/
|
|
4625
4941
|
type: defaultSeriesType,
|
|
4626
4942
|
|
|
@@ -4633,7 +4949,9 @@
|
|
|
4633
4949
|
/**
|
|
4634
4950
|
* Data grouping options for the navigator series.
|
|
4635
4951
|
*
|
|
4636
|
-
* @
|
|
4952
|
+
* @type {*}
|
|
4953
|
+
* @extends plotOptions.series.dataGrouping
|
|
4954
|
+
* @apioption navigator.series.dataGrouping
|
|
4637
4955
|
*/
|
|
4638
4956
|
dataGrouping: {
|
|
4639
4957
|
approximation: 'average',
|
|
@@ -4647,7 +4965,9 @@
|
|
|
4647
4965
|
* Data label options for the navigator series. Data labels are
|
|
4648
4966
|
* disabled by default on the navigator series.
|
|
4649
4967
|
*
|
|
4650
|
-
* @
|
|
4968
|
+
* @type {*}
|
|
4969
|
+
* @extends plotOptions.series.dataLabels
|
|
4970
|
+
* @apioption navigator.series.dataLabels
|
|
4651
4971
|
*/
|
|
4652
4972
|
dataLabels: {
|
|
4653
4973
|
enabled: false,
|
|
@@ -4661,7 +4981,9 @@
|
|
|
4661
4981
|
* Line color for the navigator series. Allows setting the color
|
|
4662
4982
|
* while disallowing the default candlestick setting.
|
|
4663
4983
|
*
|
|
4664
|
-
* @type
|
|
4984
|
+
* @type {Highcharts.ColorString|null}
|
|
4985
|
+
* @default null
|
|
4986
|
+
* @apioption navigator.series.lineColor
|
|
4665
4987
|
*/
|
|
4666
4988
|
lineColor: null, // #4602
|
|
4667
4989
|
|
|
@@ -4673,7 +4995,10 @@
|
|
|
4673
4995
|
/**
|
|
4674
4996
|
* The threshold option. Setting it to 0 will make the default
|
|
4675
4997
|
* navigator area series draw its area from the 0 value and up.
|
|
4676
|
-
*
|
|
4998
|
+
*
|
|
4999
|
+
* @type {number|null}
|
|
5000
|
+
* @default null
|
|
5001
|
+
* @apioption navigator.series.threshold
|
|
4677
5002
|
*/
|
|
4678
5003
|
threshold: null
|
|
4679
5004
|
},
|
|
@@ -4697,11 +5022,12 @@
|
|
|
4697
5022
|
* }
|
|
4698
5023
|
* }</pre>
|
|
4699
5024
|
*
|
|
4700
|
-
* @type
|
|
4701
|
-
* @extends
|
|
4702
|
-
* @excluding
|
|
4703
|
-
*
|
|
4704
|
-
* @product
|
|
5025
|
+
* @type {*}
|
|
5026
|
+
* @extends xAxis
|
|
5027
|
+
* @excluding linkedTo,maxZoom,minRange,opposite,range,scrollbar,
|
|
5028
|
+
* showEmpty,maxRange
|
|
5029
|
+
* @product highstock
|
|
5030
|
+
* @apioption navigator.xAxis
|
|
4705
5031
|
*/
|
|
4706
5032
|
xAxis: {
|
|
4707
5033
|
/**
|
|
@@ -4709,11 +5035,11 @@
|
|
|
4709
5035
|
* xAxis.maxPadding, but value is set in milliseconds.
|
|
4710
5036
|
* Can be set for both, main xAxis and navigator's xAxis.
|
|
4711
5037
|
*
|
|
4712
|
-
* @type
|
|
4713
|
-
* @default
|
|
4714
|
-
* @since
|
|
4715
|
-
* @product
|
|
4716
|
-
* @apioption
|
|
5038
|
+
* @type {number}
|
|
5039
|
+
* @default 0
|
|
5040
|
+
* @since 6.0.0
|
|
5041
|
+
* @product highstock
|
|
5042
|
+
* @apioption navigator.xAxis.overscroll
|
|
4717
5043
|
*/
|
|
4718
5044
|
overscroll: 0,
|
|
4719
5045
|
|
|
@@ -4755,11 +5081,12 @@
|
|
|
4755
5081
|
* tickWidth: 0
|
|
4756
5082
|
* }</pre>
|
|
4757
5083
|
*
|
|
4758
|
-
* @type
|
|
4759
|
-
* @extends
|
|
4760
|
-
* @excluding
|
|
4761
|
-
*
|
|
4762
|
-
* @product
|
|
5084
|
+
* @type {*}
|
|
5085
|
+
* @extends yAxis
|
|
5086
|
+
* @excluding height,linkedTo,maxZoom,minRange,ordinal,range,showEmpty,
|
|
5087
|
+
* scrollbar,top,units,maxRange,minLength,maxLength,resize
|
|
5088
|
+
* @product highstock
|
|
5089
|
+
* @apioption navigator.yAxis
|
|
4763
5090
|
*/
|
|
4764
5091
|
yAxis: {
|
|
4765
5092
|
|
|
@@ -4786,8 +5113,14 @@
|
|
|
4786
5113
|
|
|
4787
5114
|
/**
|
|
4788
5115
|
* Draw one of the handles on the side of the zoomed range in the navigator
|
|
4789
|
-
*
|
|
4790
|
-
* @
|
|
5116
|
+
*
|
|
5117
|
+
* @function Highcharts.Renderer#symbols.navigator-handle
|
|
5118
|
+
*
|
|
5119
|
+
* @param {boolean} inverted
|
|
5120
|
+
* flag for chart.inverted
|
|
5121
|
+
*
|
|
5122
|
+
* @return {Array<number|string>}
|
|
5123
|
+
* Path to be used in a handle
|
|
4791
5124
|
*/
|
|
4792
5125
|
H.Renderer.prototype.symbols['navigator-handle'] = function (
|
|
4793
5126
|
x,
|
|
@@ -4824,8 +5157,11 @@
|
|
|
4824
5157
|
|
|
4825
5158
|
/**
|
|
4826
5159
|
* The Navigator class
|
|
4827
|
-
*
|
|
4828
|
-
* @class
|
|
5160
|
+
*
|
|
5161
|
+
* @class Highcharts.Navigator
|
|
5162
|
+
*
|
|
5163
|
+
* @param {Highcharts.Chart} chart
|
|
5164
|
+
* Chart object
|
|
4829
5165
|
*/
|
|
4830
5166
|
function Navigator(chart) {
|
|
4831
5167
|
this.init(chart);
|
|
@@ -4834,10 +5170,20 @@
|
|
|
4834
5170
|
Navigator.prototype = {
|
|
4835
5171
|
/**
|
|
4836
5172
|
* Draw one of the handles on the side of the zoomed range in the navigator
|
|
4837
|
-
*
|
|
4838
|
-
* @
|
|
4839
|
-
*
|
|
4840
|
-
* @param
|
|
5173
|
+
*
|
|
5174
|
+
* @function Highcharts.Navigator#drawHandle
|
|
5175
|
+
*
|
|
5176
|
+
* @param {number} x
|
|
5177
|
+
* The x center for the handle
|
|
5178
|
+
*
|
|
5179
|
+
* @param {number} index
|
|
5180
|
+
* 0 for left and 1 for right
|
|
5181
|
+
* @param {boolean} inverted
|
|
5182
|
+
* flag for chart.inverted
|
|
5183
|
+
* @param {string} verb
|
|
5184
|
+
* use 'animate' or 'attr'
|
|
5185
|
+
*
|
|
5186
|
+
* @return {void}
|
|
4841
5187
|
*/
|
|
4842
5188
|
drawHandle: function (x, index, inverted, verb) {
|
|
4843
5189
|
var navigator = this,
|
|
@@ -4859,10 +5205,22 @@
|
|
|
4859
5205
|
|
|
4860
5206
|
/**
|
|
4861
5207
|
* Render outline around the zoomed range
|
|
4862
|
-
*
|
|
4863
|
-
* @
|
|
4864
|
-
*
|
|
4865
|
-
* @param
|
|
5208
|
+
*
|
|
5209
|
+
* @function Highcharts.Navigator#drawOutline
|
|
5210
|
+
*
|
|
5211
|
+
* @param {number} zoomedMin
|
|
5212
|
+
* in pixels position where zoomed range starts
|
|
5213
|
+
*
|
|
5214
|
+
* @param {number} zoomedMax
|
|
5215
|
+
* in pixels position where zoomed range ends
|
|
5216
|
+
*
|
|
5217
|
+
* @param {boolean} inverted
|
|
5218
|
+
* flag if chart is inverted
|
|
5219
|
+
*
|
|
5220
|
+
* @param {string} verb
|
|
5221
|
+
* use 'animate' or 'attr'
|
|
5222
|
+
*
|
|
5223
|
+
* @return {void}
|
|
4866
5224
|
*/
|
|
4867
5225
|
drawOutline: function (zoomedMin, zoomedMax, inverted, verb) {
|
|
4868
5226
|
var navigator = this,
|
|
@@ -4950,10 +5308,22 @@
|
|
|
4950
5308
|
|
|
4951
5309
|
/**
|
|
4952
5310
|
* Render outline around the zoomed range
|
|
4953
|
-
*
|
|
4954
|
-
* @
|
|
4955
|
-
*
|
|
4956
|
-
* @param
|
|
5311
|
+
*
|
|
5312
|
+
* @function Highcharts.Navigator#drawMasks
|
|
5313
|
+
*
|
|
5314
|
+
* @param {number} zoomedMin
|
|
5315
|
+
* in pixels position where zoomed range starts
|
|
5316
|
+
*
|
|
5317
|
+
* @param {number} zoomedMax
|
|
5318
|
+
* in pixels position where zoomed range ends
|
|
5319
|
+
*
|
|
5320
|
+
* @param {boolean} inverted
|
|
5321
|
+
* flag if chart is inverted
|
|
5322
|
+
*
|
|
5323
|
+
* @param {string} verb
|
|
5324
|
+
* use 'animate' or 'attr'
|
|
5325
|
+
*
|
|
5326
|
+
* @return {void}
|
|
4957
5327
|
*/
|
|
4958
5328
|
drawMasks: function (zoomedMin, zoomedMax, inverted, verb) {
|
|
4959
5329
|
var navigator = this,
|
|
@@ -5002,6 +5372,10 @@
|
|
|
5002
5372
|
* - all shades
|
|
5003
5373
|
* - outline
|
|
5004
5374
|
* - handles
|
|
5375
|
+
*
|
|
5376
|
+
* @function Highcharts.Navigator#renderElements
|
|
5377
|
+
*
|
|
5378
|
+
* @return {void}
|
|
5005
5379
|
*/
|
|
5006
5380
|
renderElements: function () {
|
|
5007
5381
|
var navigator = this,
|
|
@@ -5066,7 +5440,13 @@
|
|
|
5066
5440
|
|
|
5067
5441
|
/**
|
|
5068
5442
|
* Update navigator
|
|
5069
|
-
*
|
|
5443
|
+
*
|
|
5444
|
+
* @function Highcharts.Navigator#update
|
|
5445
|
+
*
|
|
5446
|
+
* @param {Highcharts.NavigatorOptions} options
|
|
5447
|
+
* Options to merge in when updating navigator
|
|
5448
|
+
*
|
|
5449
|
+
* @return {void}
|
|
5070
5450
|
*/
|
|
5071
5451
|
update: function (options) {
|
|
5072
5452
|
// Remove references to old navigator series in base series
|
|
@@ -5084,10 +5464,22 @@
|
|
|
5084
5464
|
|
|
5085
5465
|
/**
|
|
5086
5466
|
* Render the navigator
|
|
5087
|
-
*
|
|
5088
|
-
* @
|
|
5089
|
-
*
|
|
5090
|
-
* @param
|
|
5467
|
+
*
|
|
5468
|
+
* @function Highcharts.Navigator#render
|
|
5469
|
+
*
|
|
5470
|
+
* @param {number} min
|
|
5471
|
+
* X axis value minimum
|
|
5472
|
+
*
|
|
5473
|
+
* @param {number} max
|
|
5474
|
+
* X axis value maximum
|
|
5475
|
+
*
|
|
5476
|
+
* @param {number} pxMin
|
|
5477
|
+
* Pixel value minimum
|
|
5478
|
+
*
|
|
5479
|
+
* @param {number} pxMax
|
|
5480
|
+
* Pixel value maximum
|
|
5481
|
+
*
|
|
5482
|
+
* @return {void}
|
|
5091
5483
|
*/
|
|
5092
5484
|
render: function (min, max, pxMin, pxMax) {
|
|
5093
5485
|
|
|
@@ -5247,8 +5639,8 @@
|
|
|
5247
5639
|
navigator.scrollbar.setRange(
|
|
5248
5640
|
// Use real value, not rounded because range can be very small
|
|
5249
5641
|
// (#1716)
|
|
5250
|
-
navigator.zoomedMin / navigatorSize,
|
|
5251
|
-
navigator.zoomedMax / navigatorSize
|
|
5642
|
+
navigator.zoomedMin / (navigatorSize || 1),
|
|
5643
|
+
navigator.zoomedMax / (navigatorSize || 1)
|
|
5252
5644
|
);
|
|
5253
5645
|
}
|
|
5254
5646
|
navigator.rendered = true;
|
|
@@ -5256,6 +5648,10 @@
|
|
|
5256
5648
|
|
|
5257
5649
|
/**
|
|
5258
5650
|
* Set up the mouse and touch events for the navigator
|
|
5651
|
+
*
|
|
5652
|
+
* @function Highcharts.Navigator#addMouseEvents
|
|
5653
|
+
*
|
|
5654
|
+
* @return {void}
|
|
5259
5655
|
*/
|
|
5260
5656
|
addMouseEvents: function () {
|
|
5261
5657
|
var navigator = this,
|
|
@@ -5313,8 +5709,14 @@
|
|
|
5313
5709
|
|
|
5314
5710
|
/**
|
|
5315
5711
|
* Generate events for handles and masks
|
|
5316
|
-
*
|
|
5317
|
-
* @
|
|
5712
|
+
*
|
|
5713
|
+
* @function Highcharts.Navigator#getPartsEvents
|
|
5714
|
+
*
|
|
5715
|
+
* @param {string} eventName
|
|
5716
|
+
* Event name handler, 'mousedown' or 'touchstart'
|
|
5717
|
+
*
|
|
5718
|
+
* @return {Array<*>}
|
|
5719
|
+
* An array of arrays: [DOMElement, eventName, callback].
|
|
5318
5720
|
*/
|
|
5319
5721
|
getPartsEvents: function (eventName) {
|
|
5320
5722
|
var navigator = this,
|
|
@@ -5340,8 +5742,15 @@
|
|
|
5340
5742
|
* - will be stored for future drag&drop
|
|
5341
5743
|
* - will directly shift to a new range
|
|
5342
5744
|
*
|
|
5343
|
-
* @
|
|
5344
|
-
*
|
|
5745
|
+
* @function Highcharts.Navigator#shadesMousedown
|
|
5746
|
+
*
|
|
5747
|
+
* @param {*} e
|
|
5748
|
+
* Mouse event
|
|
5749
|
+
*
|
|
5750
|
+
* @param {number} index
|
|
5751
|
+
* Index of a mask in Navigator.shades array
|
|
5752
|
+
*
|
|
5753
|
+
* @return {void}
|
|
5345
5754
|
*/
|
|
5346
5755
|
shadesMousedown: function (e, index) {
|
|
5347
5756
|
e = this.chart.pointer.normalize(e);
|
|
@@ -5377,7 +5786,7 @@
|
|
|
5377
5786
|
left = Math.max(0, left);
|
|
5378
5787
|
} else if (index === 2 && left + range >= navigatorSize) {
|
|
5379
5788
|
left = navigatorSize - range;
|
|
5380
|
-
if (
|
|
5789
|
+
if (navigator.reversedExtremes) {
|
|
5381
5790
|
// #7713
|
|
5382
5791
|
left -= range;
|
|
5383
5792
|
fixedMin = navigator.getUnionExtremes().dataMin;
|
|
@@ -5412,8 +5821,15 @@
|
|
|
5412
5821
|
* Mousedown on a handle mask.
|
|
5413
5822
|
* Will store necessary information for drag&drop.
|
|
5414
5823
|
*
|
|
5415
|
-
* @
|
|
5416
|
-
*
|
|
5824
|
+
* @function Highcharts.Navigator#handlesMousedown
|
|
5825
|
+
*
|
|
5826
|
+
* @param {*} e
|
|
5827
|
+
* Mouse event
|
|
5828
|
+
*
|
|
5829
|
+
* @param {number} index
|
|
5830
|
+
* Index of a handle in Navigator.handles array
|
|
5831
|
+
*
|
|
5832
|
+
* @return {void}
|
|
5417
5833
|
*/
|
|
5418
5834
|
handlesMousedown: function (e, index) {
|
|
5419
5835
|
e = this.chart.pointer.normalize(e);
|
|
@@ -5421,10 +5837,9 @@
|
|
|
5421
5837
|
var navigator = this,
|
|
5422
5838
|
chart = navigator.chart,
|
|
5423
5839
|
baseXAxis = chart.xAxis[0],
|
|
5424
|
-
// For reversed axes, min and max are
|
|
5840
|
+
// For reversed axes, min and max are changed,
|
|
5425
5841
|
// so the other extreme should be stored
|
|
5426
|
-
reverse =
|
|
5427
|
-
(!chart.inverted && baseXAxis.reversed);
|
|
5842
|
+
reverse = navigator.reversedExtremes;
|
|
5428
5843
|
|
|
5429
5844
|
if (index === 0) {
|
|
5430
5845
|
// Grab the left handle
|
|
@@ -5442,7 +5857,13 @@
|
|
|
5442
5857
|
},
|
|
5443
5858
|
/**
|
|
5444
5859
|
* Mouse move event based on x/y mouse position.
|
|
5445
|
-
*
|
|
5860
|
+
*
|
|
5861
|
+
* @function Highcharts.Navigator#onMouseMove
|
|
5862
|
+
*
|
|
5863
|
+
* @param {*} e
|
|
5864
|
+
* Mouse event
|
|
5865
|
+
*
|
|
5866
|
+
* @return {void}
|
|
5446
5867
|
*/
|
|
5447
5868
|
onMouseMove: function (e) {
|
|
5448
5869
|
var navigator = this,
|
|
@@ -5507,7 +5928,13 @@
|
|
|
5507
5928
|
if (
|
|
5508
5929
|
navigator.hasDragged &&
|
|
5509
5930
|
navigator.scrollbar &&
|
|
5510
|
-
|
|
5931
|
+
pick(
|
|
5932
|
+
navigator.scrollbar.options.liveRedraw,
|
|
5933
|
+
|
|
5934
|
+
// By default, don't run live redraw on VML, on touch
|
|
5935
|
+
// devices or if the chart is in boost.
|
|
5936
|
+
H.svg && !isTouchDevice && !this.chart.isBoosting
|
|
5937
|
+
)
|
|
5511
5938
|
) {
|
|
5512
5939
|
e.DOMType = e.type; // DOMType is for IE8
|
|
5513
5940
|
setTimeout(function () {
|
|
@@ -5519,13 +5946,18 @@
|
|
|
5519
5946
|
|
|
5520
5947
|
/**
|
|
5521
5948
|
* Mouse up event based on x/y mouse position.
|
|
5522
|
-
*
|
|
5949
|
+
*
|
|
5950
|
+
* @function Highcharts.Navigator#onMouseUp
|
|
5951
|
+
*
|
|
5952
|
+
* @param {*} e
|
|
5953
|
+
* Mouse event
|
|
5954
|
+
*
|
|
5955
|
+
* @return {void}
|
|
5523
5956
|
*/
|
|
5524
5957
|
onMouseUp: function (e) {
|
|
5525
5958
|
var navigator = this,
|
|
5526
5959
|
chart = navigator.chart,
|
|
5527
5960
|
xAxis = navigator.xAxis,
|
|
5528
|
-
reversed = xAxis && xAxis.reversed,
|
|
5529
5961
|
scrollbar = navigator.scrollbar,
|
|
5530
5962
|
unionExtremes,
|
|
5531
5963
|
fixedMin,
|
|
@@ -5550,13 +5982,13 @@
|
|
|
5550
5982
|
}
|
|
5551
5983
|
// Snap to right edge (#4076)
|
|
5552
5984
|
if (navigator.zoomedMax === navigator.size) {
|
|
5553
|
-
fixedMax =
|
|
5985
|
+
fixedMax = navigator.reversedExtremes ?
|
|
5554
5986
|
unionExtremes.dataMin : unionExtremes.dataMax;
|
|
5555
5987
|
}
|
|
5556
5988
|
|
|
5557
5989
|
// Snap to left edge (#7576)
|
|
5558
5990
|
if (navigator.zoomedMin === 0) {
|
|
5559
|
-
fixedMin =
|
|
5991
|
+
fixedMin = navigator.reversedExtremes ?
|
|
5560
5992
|
unionExtremes.dataMax : unionExtremes.dataMin;
|
|
5561
5993
|
}
|
|
5562
5994
|
|
|
@@ -5594,6 +6026,10 @@
|
|
|
5594
6026
|
|
|
5595
6027
|
/**
|
|
5596
6028
|
* Removes the event handlers attached previously with addEvents.
|
|
6029
|
+
*
|
|
6030
|
+
* @function Highcharts.Navigator#removeEvents
|
|
6031
|
+
*
|
|
6032
|
+
* @return {void}
|
|
5597
6033
|
*/
|
|
5598
6034
|
removeEvents: function () {
|
|
5599
6035
|
if (this.eventsToUnbind) {
|
|
@@ -5607,6 +6043,10 @@
|
|
|
5607
6043
|
|
|
5608
6044
|
/**
|
|
5609
6045
|
* Remove data events.
|
|
6046
|
+
*
|
|
6047
|
+
* @function Highcharts.Navigator#removeBaseSeriesEvents
|
|
6048
|
+
*
|
|
6049
|
+
* @return {void}
|
|
5610
6050
|
*/
|
|
5611
6051
|
removeBaseSeriesEvents: function () {
|
|
5612
6052
|
var baseSeries = this.baseSeries || [];
|
|
@@ -5630,6 +6070,12 @@
|
|
|
5630
6070
|
|
|
5631
6071
|
/**
|
|
5632
6072
|
* Initiate the Navigator object
|
|
6073
|
+
*
|
|
6074
|
+
* @function Highcharts.Navigator#init
|
|
6075
|
+
*
|
|
6076
|
+
* @param {Highcharts.Chart} chart
|
|
6077
|
+
*
|
|
6078
|
+
* @return {void}
|
|
5633
6079
|
*/
|
|
5634
6080
|
init: function (chart) {
|
|
5635
6081
|
var chartOptions = chart.options,
|
|
@@ -5666,22 +6112,6 @@
|
|
|
5666
6112
|
baseXaxis = baseSeries && baseSeries[0] && baseSeries[0].xAxis ||
|
|
5667
6113
|
chart.xAxis[0] || { options: {} };
|
|
5668
6114
|
|
|
5669
|
-
|
|
5670
|
-
// Make room for the navigator, can be placed around the chart:
|
|
5671
|
-
addEvent(chart, 'getMargins', function () {
|
|
5672
|
-
var marginName = navigator.opposite ? 'plotTop' : 'marginBottom';
|
|
5673
|
-
if (chart.inverted) {
|
|
5674
|
-
marginName = navigator.opposite ? 'marginRight' : 'plotLeft';
|
|
5675
|
-
}
|
|
5676
|
-
|
|
5677
|
-
chart[marginName] = (chart[marginName] || 0) + (
|
|
5678
|
-
navigatorEnabled || !chart.inverted ?
|
|
5679
|
-
navigator.outlineHeight :
|
|
5680
|
-
0
|
|
5681
|
-
) + navigatorOptions.margin;
|
|
5682
|
-
|
|
5683
|
-
});
|
|
5684
|
-
|
|
5685
6115
|
chart.isDirtyBox = true;
|
|
5686
6116
|
|
|
5687
6117
|
if (navigator.navigatorEnabled) {
|
|
@@ -5696,6 +6126,7 @@
|
|
|
5696
6126
|
isX: true,
|
|
5697
6127
|
type: 'datetime',
|
|
5698
6128
|
index: xAxisIndex,
|
|
6129
|
+
isInternal: true,
|
|
5699
6130
|
offset: 0,
|
|
5700
6131
|
keepOrdinalPadding: true, // #2436
|
|
5701
6132
|
startOnTick: false,
|
|
@@ -5716,6 +6147,7 @@
|
|
|
5716
6147
|
alignTicks: false,
|
|
5717
6148
|
offset: 0,
|
|
5718
6149
|
index: yAxisIndex,
|
|
6150
|
+
isInternal: true,
|
|
5719
6151
|
zoomEnabled: false
|
|
5720
6152
|
}, chart.inverted ? {
|
|
5721
6153
|
width: height
|
|
@@ -5743,6 +6175,12 @@
|
|
|
5743
6175
|
);
|
|
5744
6176
|
}
|
|
5745
6177
|
|
|
6178
|
+
navigator.reversedExtremes = (
|
|
6179
|
+
chart.inverted && !navigator.xAxis.reversed
|
|
6180
|
+
) || (
|
|
6181
|
+
!chart.inverted && navigator.xAxis.reversed
|
|
6182
|
+
);
|
|
6183
|
+
|
|
5746
6184
|
// Render items, so we can bind events to them:
|
|
5747
6185
|
navigator.renderElements();
|
|
5748
6186
|
// Add mouse events
|
|
@@ -5821,7 +6259,13 @@
|
|
|
5821
6259
|
/**
|
|
5822
6260
|
* Get the union data extremes of the chart - the outer data extremes of the
|
|
5823
6261
|
* base X axis and the navigator axis.
|
|
5824
|
-
*
|
|
6262
|
+
*
|
|
6263
|
+
* @function Highcharts.Navigator#getUnionExtremes
|
|
6264
|
+
*
|
|
6265
|
+
* @param {boolean} returnFalseOnNoBaseSeries
|
|
6266
|
+
* as the param says.
|
|
6267
|
+
*
|
|
6268
|
+
* @return {*}
|
|
5825
6269
|
*/
|
|
5826
6270
|
getUnionExtremes: function (returnFalseOnNoBaseSeries) {
|
|
5827
6271
|
var baseAxis = this.chart.xAxis[0],
|
|
@@ -5861,10 +6305,16 @@
|
|
|
5861
6305
|
* Set the base series and update the navigator series from this. With a bit
|
|
5862
6306
|
* of modification we should be able to make this an API method to be called
|
|
5863
6307
|
* from the outside
|
|
5864
|
-
*
|
|
6308
|
+
*
|
|
6309
|
+
* @function Highcharts.Navigator#setBaseSeries
|
|
6310
|
+
*
|
|
6311
|
+
* @param {*} baseSeriesOptions
|
|
5865
6312
|
* Additional series options for a navigator
|
|
5866
|
-
*
|
|
6313
|
+
*
|
|
6314
|
+
* @param {boolean} [redraw]
|
|
5867
6315
|
* Whether to redraw after update.
|
|
6316
|
+
*
|
|
6317
|
+
* @return {void}
|
|
5868
6318
|
*/
|
|
5869
6319
|
setBaseSeries: function (baseSeriesOptions, redraw) {
|
|
5870
6320
|
var chart = this.chart,
|
|
@@ -5901,9 +6351,17 @@
|
|
|
5901
6351
|
}
|
|
5902
6352
|
},
|
|
5903
6353
|
|
|
5904
|
-
|
|
6354
|
+
/**
|
|
5905
6355
|
* Update series in the navigator from baseSeries, adding new if does not
|
|
5906
6356
|
* exist.
|
|
6357
|
+
*
|
|
6358
|
+
* @function Highcharts.Navigator.updateNavigatorSeries
|
|
6359
|
+
*
|
|
6360
|
+
* @param {boolean} addEvents
|
|
6361
|
+
*
|
|
6362
|
+
* @param {boolean} redraw
|
|
6363
|
+
*
|
|
6364
|
+
* @return {void}
|
|
5907
6365
|
*/
|
|
5908
6366
|
updateNavigatorSeries: function (addEvents, redraw) {
|
|
5909
6367
|
var navigator = this,
|
|
@@ -5940,8 +6398,11 @@
|
|
|
5940
6398
|
);
|
|
5941
6399
|
delete base.navigatorSeries;
|
|
5942
6400
|
}
|
|
5943
|
-
// Kill the nav series
|
|
5944
|
-
|
|
6401
|
+
// Kill the nav series. It may already have been
|
|
6402
|
+
// destroyed (#8715).
|
|
6403
|
+
if (navSeries.chart) {
|
|
6404
|
+
navSeries.destroy();
|
|
6405
|
+
}
|
|
5945
6406
|
return false;
|
|
5946
6407
|
}
|
|
5947
6408
|
return true;
|
|
@@ -6057,6 +6518,10 @@
|
|
|
6057
6518
|
/**
|
|
6058
6519
|
* Add data events.
|
|
6059
6520
|
* For example when main series is updated we need to recalculate extremes
|
|
6521
|
+
*
|
|
6522
|
+
* @function Highcharts.Navigator#addBaseSeriesEvent
|
|
6523
|
+
*
|
|
6524
|
+
* @return {void}
|
|
6060
6525
|
*/
|
|
6061
6526
|
addBaseSeriesEvents: function () {
|
|
6062
6527
|
var navigator = this,
|
|
@@ -6108,10 +6573,32 @@
|
|
|
6108
6573
|
}, this);
|
|
6109
6574
|
},
|
|
6110
6575
|
|
|
6576
|
+
/**
|
|
6577
|
+
* Get minimum from all base series connected to the navigator
|
|
6578
|
+
*
|
|
6579
|
+
* @param {number} currentSeriesMin
|
|
6580
|
+
* Minium from the current series
|
|
6581
|
+
*
|
|
6582
|
+
* @return {number} Minimum from all series
|
|
6583
|
+
*/
|
|
6584
|
+
getBaseSeriesMin: function (currentSeriesMin) {
|
|
6585
|
+
return H.reduce(
|
|
6586
|
+
this.baseSeries,
|
|
6587
|
+
function (min, series) {
|
|
6588
|
+
return Math.min(min, series.xData[0]);
|
|
6589
|
+
},
|
|
6590
|
+
currentSeriesMin
|
|
6591
|
+
);
|
|
6592
|
+
},
|
|
6593
|
+
|
|
6111
6594
|
/**
|
|
6112
6595
|
* Set the navigator x axis extremes to reflect the total. The navigator
|
|
6113
6596
|
* extremes should always be the extremes of the union of all series in the
|
|
6114
6597
|
* chart as well as the navigator series.
|
|
6598
|
+
*
|
|
6599
|
+
* @function Highcharts.Navigator#modifyNavigatorAxisExtremes
|
|
6600
|
+
*
|
|
6601
|
+
* @return {void}
|
|
6115
6602
|
*/
|
|
6116
6603
|
modifyNavigatorAxisExtremes: function () {
|
|
6117
6604
|
var xAxis = this.xAxis,
|
|
@@ -6134,6 +6621,10 @@
|
|
|
6134
6621
|
|
|
6135
6622
|
/**
|
|
6136
6623
|
* Hook to modify the base axis extremes with information from the Navigator
|
|
6624
|
+
*
|
|
6625
|
+
* @function Highcharts.Navigator#modifyBaseAxisExtremes
|
|
6626
|
+
*
|
|
6627
|
+
* @return {void}
|
|
6137
6628
|
*/
|
|
6138
6629
|
modifyBaseAxisExtremes: function () {
|
|
6139
6630
|
var baseXAxis = this,
|
|
@@ -6176,8 +6667,11 @@
|
|
|
6176
6667
|
if (!stickToMin) {
|
|
6177
6668
|
newMin = Math.max(
|
|
6178
6669
|
newMax - range,
|
|
6179
|
-
|
|
6180
|
-
navigatorSeries.xData
|
|
6670
|
+
navigator.getBaseSeriesMin(
|
|
6671
|
+
navigatorSeries && navigatorSeries.xData ?
|
|
6672
|
+
navigatorSeries.xData[0] :
|
|
6673
|
+
-Number.MAX_VALUE
|
|
6674
|
+
)
|
|
6181
6675
|
);
|
|
6182
6676
|
}
|
|
6183
6677
|
}
|
|
@@ -6199,15 +6693,20 @@
|
|
|
6199
6693
|
* Handler for updated data on the base series. When data is modified, the
|
|
6200
6694
|
* navigator series must reflect it. This is called from the Chart.redraw
|
|
6201
6695
|
* function before axis and series extremes are computed.
|
|
6696
|
+
*
|
|
6697
|
+
* @function Highcharts.Navigator#updateDataHandler
|
|
6698
|
+
*
|
|
6699
|
+
* @return {void}
|
|
6202
6700
|
*/
|
|
6203
6701
|
updatedDataHandler: function () {
|
|
6204
6702
|
var navigator = this.chart.navigator,
|
|
6205
6703
|
baseSeries = this,
|
|
6206
|
-
navigatorSeries = this.navigatorSeries
|
|
6704
|
+
navigatorSeries = this.navigatorSeries,
|
|
6705
|
+
xDataMin = navigator.getBaseSeriesMin(baseSeries.xData[0]);
|
|
6207
6706
|
|
|
6208
6707
|
// If the scrollbar is scrolled all the way to the right, keep right as
|
|
6209
6708
|
// new data comes in.
|
|
6210
|
-
navigator.stickToMax = navigator.
|
|
6709
|
+
navigator.stickToMax = navigator.reversedExtremes ?
|
|
6211
6710
|
Math.round(navigator.zoomedMin) === 0 :
|
|
6212
6711
|
Math.round(navigator.zoomedMax) >= Math.round(navigator.size);
|
|
6213
6712
|
|
|
@@ -6215,7 +6714,7 @@
|
|
|
6215
6714
|
// maximum. If the current axis minimum falls outside the new updated
|
|
6216
6715
|
// dataset, we must adjust.
|
|
6217
6716
|
navigator.stickToMin = isNumber(baseSeries.xAxis.min) &&
|
|
6218
|
-
(baseSeries.xAxis.min <=
|
|
6717
|
+
(baseSeries.xAxis.min <= xDataMin) &&
|
|
6219
6718
|
(!this.chart.fixedRange || !navigator.stickToMax);
|
|
6220
6719
|
|
|
6221
6720
|
// Set the navigator series data to the new data of the base series
|
|
@@ -6232,27 +6731,66 @@
|
|
|
6232
6731
|
|
|
6233
6732
|
/**
|
|
6234
6733
|
* Add chart events, like redrawing navigator, when chart requires that.
|
|
6734
|
+
*
|
|
6735
|
+
* @function Highcharts.Navigator#addChartEvents
|
|
6736
|
+
*
|
|
6737
|
+
* @return {void}
|
|
6235
6738
|
*/
|
|
6236
6739
|
addChartEvents: function () {
|
|
6237
|
-
|
|
6740
|
+
if (!this.eventsToUnbind) {
|
|
6741
|
+
this.eventsToUnbind = [];
|
|
6742
|
+
}
|
|
6743
|
+
|
|
6744
|
+
this.eventsToUnbind.push(
|
|
6238
6745
|
// Move the scrollbar after redraw, like after data updata even if
|
|
6239
6746
|
// axes don't redraw
|
|
6240
|
-
|
|
6241
|
-
|
|
6242
|
-
|
|
6243
|
-
|
|
6244
|
-
navigator.
|
|
6245
|
-
|
|
6246
|
-
|
|
6247
|
-
|
|
6248
|
-
|
|
6249
|
-
|
|
6250
|
-
|
|
6251
|
-
|
|
6747
|
+
addEvent(
|
|
6748
|
+
this.chart,
|
|
6749
|
+
'redraw',
|
|
6750
|
+
function () {
|
|
6751
|
+
var navigator = this.navigator,
|
|
6752
|
+
xAxis = navigator && (
|
|
6753
|
+
navigator.baseSeries &&
|
|
6754
|
+
navigator.baseSeries[0] &&
|
|
6755
|
+
navigator.baseSeries[0].xAxis ||
|
|
6756
|
+
navigator.scrollbar && this.xAxis[0]
|
|
6757
|
+
); // #5709
|
|
6758
|
+
|
|
6759
|
+
if (xAxis) {
|
|
6760
|
+
navigator.render(xAxis.min, xAxis.max);
|
|
6761
|
+
}
|
|
6762
|
+
}
|
|
6763
|
+
),
|
|
6764
|
+
// Make room for the navigator, can be placed around the chart:
|
|
6765
|
+
addEvent(
|
|
6766
|
+
this.chart,
|
|
6767
|
+
'getMargins',
|
|
6768
|
+
function () {
|
|
6769
|
+
var chart = this,
|
|
6770
|
+
navigator = chart.navigator,
|
|
6771
|
+
marginName = navigator.opposite ?
|
|
6772
|
+
'plotTop' : 'marginBottom';
|
|
6773
|
+
if (chart.inverted) {
|
|
6774
|
+
marginName = navigator.opposite ?
|
|
6775
|
+
'marginRight' : 'plotLeft';
|
|
6776
|
+
}
|
|
6777
|
+
|
|
6778
|
+
chart[marginName] = (chart[marginName] || 0) + (
|
|
6779
|
+
navigator.navigatorEnabled || !chart.inverted ?
|
|
6780
|
+
navigator.outlineHeight :
|
|
6781
|
+
0
|
|
6782
|
+
) + navigator.navigatorOptions.margin;
|
|
6783
|
+
}
|
|
6784
|
+
)
|
|
6785
|
+
);
|
|
6252
6786
|
},
|
|
6253
6787
|
|
|
6254
6788
|
/**
|
|
6255
6789
|
* Destroys allocated elements.
|
|
6790
|
+
*
|
|
6791
|
+
* @function Highcharts.Navigator#destroy
|
|
6792
|
+
*
|
|
6793
|
+
* @return {void}
|
|
6256
6794
|
*/
|
|
6257
6795
|
destroy: function () {
|
|
6258
6796
|
|
|
@@ -6501,7 +7039,7 @@
|
|
|
6501
7039
|
}(Highcharts));
|
|
6502
7040
|
(function (H) {
|
|
6503
7041
|
/**
|
|
6504
|
-
* (c) 2010-
|
|
7042
|
+
* (c) 2010-2018 Torstein Honsi
|
|
6505
7043
|
*
|
|
6506
7044
|
* License: www.highcharts.com/license
|
|
6507
7045
|
*/
|
|
@@ -6539,20 +7077,201 @@
|
|
|
6539
7077
|
* @optionparent rangeSelector
|
|
6540
7078
|
*/
|
|
6541
7079
|
rangeSelector: {
|
|
6542
|
-
|
|
6543
|
-
|
|
6544
|
-
|
|
6545
|
-
|
|
7080
|
+
|
|
7081
|
+
/**
|
|
7082
|
+
* Whether to enable all buttons from the start. By default buttons are
|
|
7083
|
+
* only enabled if the corresponding time range exists on the X axis,
|
|
7084
|
+
* but enabling all buttons allows for dynamically loading different
|
|
7085
|
+
* time ranges.
|
|
7086
|
+
*
|
|
7087
|
+
* @sample {highstock} stock/rangeselector/allbuttonsenabled-true/
|
|
7088
|
+
* All buttons enabled
|
|
7089
|
+
*
|
|
7090
|
+
* @type {boolean}
|
|
7091
|
+
* @default false
|
|
7092
|
+
* @since 2.0.3
|
|
7093
|
+
* @product highstock
|
|
7094
|
+
* @apioption rangeSelector.allButtonsEnabled
|
|
7095
|
+
*/
|
|
7096
|
+
|
|
7097
|
+
/**
|
|
7098
|
+
* An array of configuration objects for the buttons.
|
|
7099
|
+
*
|
|
7100
|
+
* Defaults to
|
|
7101
|
+
*
|
|
7102
|
+
* <pre>buttons: [{
|
|
7103
|
+
* type: 'month',
|
|
7104
|
+
* count: 1,
|
|
7105
|
+
* text: '1m'
|
|
7106
|
+
* }, {
|
|
7107
|
+
* type: 'month',
|
|
7108
|
+
* count: 3,
|
|
7109
|
+
* text: '3m'
|
|
7110
|
+
* }, {
|
|
7111
|
+
* type: 'month',
|
|
7112
|
+
* count: 6,
|
|
7113
|
+
* text: '6m'
|
|
7114
|
+
* }, {
|
|
7115
|
+
* type: 'ytd',
|
|
7116
|
+
* text: 'YTD'
|
|
7117
|
+
* }, {
|
|
7118
|
+
* type: 'year',
|
|
7119
|
+
* count: 1,
|
|
7120
|
+
* text: '1y'
|
|
7121
|
+
* }, {
|
|
7122
|
+
* type: 'all',
|
|
7123
|
+
* text: 'All'
|
|
7124
|
+
* }]</pre>
|
|
7125
|
+
*
|
|
7126
|
+
* @sample {highstock} stock/rangeselector/datagrouping/
|
|
7127
|
+
* Data grouping by buttons
|
|
7128
|
+
*
|
|
7129
|
+
* @type {Array<*>}
|
|
7130
|
+
* @product highstock
|
|
7131
|
+
* @apioption rangeSelector.buttons
|
|
7132
|
+
*/
|
|
7133
|
+
|
|
7134
|
+
/**
|
|
7135
|
+
* How many units of the defined type the button should span. If `type`
|
|
7136
|
+
* is "month" and `count` is 3, the button spans three months.
|
|
7137
|
+
*
|
|
7138
|
+
* @type {number}
|
|
7139
|
+
* @default 1
|
|
7140
|
+
* @product highstock
|
|
7141
|
+
* @apioption rangeSelector.buttons.count
|
|
7142
|
+
*/
|
|
7143
|
+
|
|
7144
|
+
/**
|
|
7145
|
+
* Fires when clicking on the rangeSelector button. One parameter,
|
|
7146
|
+
* event, is passed to the function, containing common event
|
|
7147
|
+
* information.
|
|
7148
|
+
*
|
|
7149
|
+
* <pre>
|
|
7150
|
+
* click: function(e) {
|
|
7151
|
+
* console.log(this);
|
|
7152
|
+
* }
|
|
7153
|
+
* </pre>
|
|
7154
|
+
*
|
|
7155
|
+
* Return false to stop default button's click action.
|
|
7156
|
+
*
|
|
7157
|
+
* @sample {highstock} stock/rangeselector/button-click/
|
|
7158
|
+
* Click event on the button
|
|
7159
|
+
*
|
|
7160
|
+
* @type {Function}
|
|
7161
|
+
* @product highstock
|
|
7162
|
+
* @apioption rangeSelector.buttons.events.click
|
|
7163
|
+
*/
|
|
7164
|
+
|
|
7165
|
+
/**
|
|
7166
|
+
* Additional range (in milliseconds) added to the end of the calculated
|
|
7167
|
+
* time span.
|
|
7168
|
+
*
|
|
7169
|
+
* @sample {highstock} stock/rangeselector/min-max-offsets/
|
|
7170
|
+
* Button offsets
|
|
7171
|
+
*
|
|
7172
|
+
* @type {number}
|
|
7173
|
+
* @default 0
|
|
7174
|
+
* @since 6.0.0
|
|
7175
|
+
* @product highstock
|
|
7176
|
+
* @apioption rangeSelector.buttons.offsetMax
|
|
7177
|
+
*/
|
|
7178
|
+
|
|
7179
|
+
/**
|
|
7180
|
+
* Additional range (in milliseconds) added to the start of the
|
|
7181
|
+
* calculated time span.
|
|
7182
|
+
*
|
|
7183
|
+
* @sample {highstock} stock/rangeselector/min-max-offsets/
|
|
7184
|
+
* Button offsets
|
|
7185
|
+
*
|
|
7186
|
+
* @type {number}
|
|
7187
|
+
* @default 0
|
|
7188
|
+
* @since 6.0.0
|
|
7189
|
+
* @product highstock
|
|
7190
|
+
* @apioption rangeSelector.buttons.offsetMin
|
|
7191
|
+
*/
|
|
7192
|
+
|
|
7193
|
+
/**
|
|
7194
|
+
* When buttons apply dataGrouping on a series, by default zooming
|
|
7195
|
+
* in/out will deselect buttons and unset dataGrouping. Enable this
|
|
7196
|
+
* option to keep buttons selected when extremes change.
|
|
7197
|
+
*
|
|
7198
|
+
* @sample {highstock} stock/rangeselector/preserve-datagrouping/
|
|
7199
|
+
* Different preserveDataGrouping settings
|
|
7200
|
+
*
|
|
7201
|
+
* @type {boolean}
|
|
7202
|
+
* @since 6.1.2
|
|
7203
|
+
* @default false
|
|
7204
|
+
* @product highstock
|
|
7205
|
+
* @apioption rangeSelector.buttons.preserveDataGrouping
|
|
7206
|
+
*/
|
|
7207
|
+
|
|
7208
|
+
/**
|
|
7209
|
+
* A custom data grouping object for each button.
|
|
7210
|
+
*
|
|
7211
|
+
* @see [series.dataGrouping](#plotOptions.series.dataGrouping)
|
|
7212
|
+
*
|
|
7213
|
+
* @sample {highstock} stock/rangeselector/datagrouping/
|
|
7214
|
+
* Data grouping by range selector buttons
|
|
7215
|
+
*
|
|
7216
|
+
* @type {*}
|
|
7217
|
+
* @extends plotOptions.series.dataGrouping
|
|
7218
|
+
* @product highstock
|
|
7219
|
+
* @apioption rangeSelector.buttons.dataGrouping
|
|
7220
|
+
*/
|
|
7221
|
+
|
|
7222
|
+
/**
|
|
7223
|
+
* The text for the button itself.
|
|
7224
|
+
*
|
|
7225
|
+
* @type {string}
|
|
7226
|
+
* @product highstock
|
|
7227
|
+
* @apioption rangeSelector.buttons.text
|
|
7228
|
+
*/
|
|
7229
|
+
|
|
7230
|
+
/**
|
|
7231
|
+
* Defined the time span for the button. Can be one of `millisecond`,
|
|
7232
|
+
* `second`, `minute`, `hour`, `day`, `week`, `month`, `ytd`, `all`.
|
|
7233
|
+
*
|
|
7234
|
+
* @type {string}
|
|
7235
|
+
* @product highstock
|
|
7236
|
+
* @validvalue ["millisecond", "second", "minute", "day", "week", "month", "ytd", "all"]
|
|
7237
|
+
* @apioption rangeSelector.buttons.type
|
|
7238
|
+
*/
|
|
7239
|
+
|
|
7240
|
+
/**
|
|
7241
|
+
* The space in pixels between the buttons in the range selector.
|
|
7242
|
+
*
|
|
7243
|
+
* @type {number}
|
|
7244
|
+
* @default 0
|
|
7245
|
+
* @product highstock
|
|
7246
|
+
* @apioption rangeSelector.buttonSpacing
|
|
7247
|
+
*/
|
|
7248
|
+
|
|
7249
|
+
/**
|
|
7250
|
+
* Enable or disable the range selector.
|
|
7251
|
+
*
|
|
7252
|
+
* @sample {highstock} stock/rangeselector/enabled/
|
|
7253
|
+
* Disable the range selector
|
|
7254
|
+
*
|
|
7255
|
+
* @type {boolean}
|
|
7256
|
+
* @default true
|
|
7257
|
+
* @product highstock
|
|
7258
|
+
* @apioption rangeSelector.enabled
|
|
7259
|
+
*/
|
|
6546
7260
|
|
|
6547
7261
|
/**
|
|
6548
7262
|
* The vertical alignment of the rangeselector box. Allowed properties
|
|
6549
7263
|
* are `top`, `middle`, `bottom`.
|
|
6550
7264
|
*
|
|
6551
|
-
* @
|
|
6552
|
-
*
|
|
6553
|
-
* @sample {highstock} stock/rangeselector/vertical-align-
|
|
7265
|
+
* @sample {highstock} stock/rangeselector/vertical-align-middle/
|
|
7266
|
+
* Middle
|
|
7267
|
+
* @sample {highstock} stock/rangeselector/vertical-align-bottom/
|
|
7268
|
+
* Bottom
|
|
6554
7269
|
*
|
|
6555
|
-
* @
|
|
7270
|
+
* @type {string}
|
|
7271
|
+
* @default top
|
|
7272
|
+
* @since 6.0.0
|
|
7273
|
+
* @validvalue ["top", "middle", "bottom"]
|
|
7274
|
+
* @apioption rangeSelector.verticalAlign
|
|
6556
7275
|
*/
|
|
6557
7276
|
verticalAlign: 'top',
|
|
6558
7277
|
|
|
@@ -6571,13 +7290,15 @@
|
|
|
6571
7290
|
* `.highcharts-range-selector-buttons .highcharts-button` rule with its
|
|
6572
7291
|
* different states.
|
|
6573
7292
|
*
|
|
6574
|
-
* @type {Object}
|
|
6575
7293
|
* @sample {highstock} stock/rangeselector/styling/
|
|
6576
7294
|
* Styling the buttons and inputs
|
|
6577
|
-
*
|
|
7295
|
+
*
|
|
7296
|
+
* @type {Highcharts.CSSObject}
|
|
7297
|
+
* @product highstock
|
|
7298
|
+
* @apioption rangeSelector.buttonTheme
|
|
6578
7299
|
*/
|
|
6579
7300
|
buttonTheme: {
|
|
6580
|
-
|
|
7301
|
+
|
|
6581
7302
|
width: 28,
|
|
6582
7303
|
height: 18,
|
|
6583
7304
|
padding: 2,
|
|
@@ -6591,8 +7312,12 @@
|
|
|
6591
7312
|
* @sample {highstock} stock/rangeselector/floating/
|
|
6592
7313
|
* Placing the range selector between the plot area and the
|
|
6593
7314
|
* navigator
|
|
6594
|
-
*
|
|
6595
|
-
* @
|
|
7315
|
+
*
|
|
7316
|
+
* @type {boolean}
|
|
7317
|
+
* @default false
|
|
7318
|
+
* @since 6.0.0
|
|
7319
|
+
* @product highstock
|
|
7320
|
+
* @apioption rangeSelector.floating
|
|
6596
7321
|
*/
|
|
6597
7322
|
floating: false,
|
|
6598
7323
|
|
|
@@ -6600,8 +7325,11 @@
|
|
|
6600
7325
|
* The x offset of the range selector relative to its horizontal
|
|
6601
7326
|
* alignment within `chart.spacingLeft` and `chart.spacingRight`.
|
|
6602
7327
|
*
|
|
6603
|
-
* @
|
|
6604
|
-
* @
|
|
7328
|
+
* @type {number}
|
|
7329
|
+
* @default 0
|
|
7330
|
+
* @since 6.0.0
|
|
7331
|
+
* @product highstock
|
|
7332
|
+
* @apioption rangeSelector.x
|
|
6605
7333
|
*/
|
|
6606
7334
|
x: 0,
|
|
6607
7335
|
|
|
@@ -6609,8 +7337,11 @@
|
|
|
6609
7337
|
* The y offset of the range selector relative to its horizontal
|
|
6610
7338
|
* alignment within `chart.spacingLeft` and `chart.spacingRight`.
|
|
6611
7339
|
*
|
|
6612
|
-
* @
|
|
6613
|
-
* @
|
|
7340
|
+
* @type {number}
|
|
7341
|
+
* @default 0
|
|
7342
|
+
* @since 6.0.0
|
|
7343
|
+
* @product highstock
|
|
7344
|
+
* @apioption rangeSelector.y
|
|
6614
7345
|
*/
|
|
6615
7346
|
y: 0,
|
|
6616
7347
|
|
|
@@ -6618,67 +7349,216 @@
|
|
|
6618
7349
|
* Deprecated. The height of the range selector. Currently it is
|
|
6619
7350
|
* calculated dynamically.
|
|
6620
7351
|
*
|
|
6621
|
-
* @
|
|
6622
|
-
* @
|
|
6623
|
-
* @
|
|
6624
|
-
* @
|
|
6625
|
-
* @
|
|
7352
|
+
* @deprecated
|
|
7353
|
+
* @type {number}
|
|
7354
|
+
* @default undefined
|
|
7355
|
+
* @since 2.1.9
|
|
7356
|
+
* @product highstock
|
|
7357
|
+
* @apioption rangeSelector.height
|
|
6626
7358
|
*/
|
|
6627
7359
|
height: undefined, // reserved space for buttons and input
|
|
6628
7360
|
|
|
7361
|
+
/**
|
|
7362
|
+
* The border color of the date input boxes.
|
|
7363
|
+
*
|
|
7364
|
+
* @sample {highstock} stock/rangeselector/styling/
|
|
7365
|
+
* Styling the buttons and inputs
|
|
7366
|
+
*
|
|
7367
|
+
* @type {Highcharts.ColorString}
|
|
7368
|
+
* @default #cccccc
|
|
7369
|
+
* @since 1.3.7
|
|
7370
|
+
* @product highstock
|
|
7371
|
+
* @apioption rangeSelector.inputBoxBorderColor
|
|
7372
|
+
*/
|
|
7373
|
+
|
|
7374
|
+
/**
|
|
7375
|
+
* The pixel height of the date input boxes.
|
|
7376
|
+
*
|
|
7377
|
+
* @sample {highstock} stock/rangeselector/styling/
|
|
7378
|
+
* Styling the buttons and inputs
|
|
7379
|
+
*
|
|
7380
|
+
* @type {number}
|
|
7381
|
+
* @default 17
|
|
7382
|
+
* @since 1.3.7
|
|
7383
|
+
* @product highstock
|
|
7384
|
+
* @apioption rangeSelector.inputBoxHeight
|
|
7385
|
+
*/
|
|
7386
|
+
|
|
7387
|
+
/**
|
|
7388
|
+
* CSS for the container DIV holding the input boxes. Deprecated as
|
|
7389
|
+
* of 1.2.5\. Use [inputPosition](#rangeSelector.inputPosition) instead.
|
|
7390
|
+
*
|
|
7391
|
+
* @sample {highstock} stock/rangeselector/styling/
|
|
7392
|
+
* Styling the buttons and inputs
|
|
7393
|
+
*
|
|
7394
|
+
* @deprecated
|
|
7395
|
+
* @type {Highcharts.CSSObject}
|
|
7396
|
+
* @product highstock
|
|
7397
|
+
* @apioption rangeSelector.inputBoxStyle
|
|
7398
|
+
*/
|
|
7399
|
+
|
|
7400
|
+
/**
|
|
7401
|
+
* The pixel width of the date input boxes.
|
|
7402
|
+
*
|
|
7403
|
+
* @sample {highstock} stock/rangeselector/styling/
|
|
7404
|
+
* Styling the buttons and inputs
|
|
7405
|
+
*
|
|
7406
|
+
* @type {number}
|
|
7407
|
+
* @default 90
|
|
7408
|
+
* @since 1.3.7
|
|
7409
|
+
* @product highstock
|
|
7410
|
+
* @apioption rangeSelector.inputBoxWidth
|
|
7411
|
+
*/
|
|
7412
|
+
|
|
7413
|
+
/**
|
|
7414
|
+
* The date format in the input boxes when not selected for editing.
|
|
7415
|
+
* Defaults to `%b %e, %Y`.
|
|
7416
|
+
*
|
|
7417
|
+
* @sample {highstock} stock/rangeselector/input-format/
|
|
7418
|
+
* Milliseconds in the range selector
|
|
7419
|
+
*
|
|
7420
|
+
* @type {string}
|
|
7421
|
+
* @default %b %e %Y,
|
|
7422
|
+
* @product highstock
|
|
7423
|
+
* @apioption rangeSelector.inputDateFormat
|
|
7424
|
+
*/
|
|
7425
|
+
|
|
7426
|
+
/**
|
|
7427
|
+
* A custom callback function to parse values entered in the input boxes
|
|
7428
|
+
* and return a valid JavaScript time as milliseconds since 1970.
|
|
7429
|
+
*
|
|
7430
|
+
* @sample {highstock} stock/rangeselector/input-format/
|
|
7431
|
+
* Milliseconds in the range selector
|
|
7432
|
+
*
|
|
7433
|
+
* @type {Function}
|
|
7434
|
+
* @since 1.3.3
|
|
7435
|
+
* @product highstock
|
|
7436
|
+
* @apioption rangeSelector.inputDateParser
|
|
7437
|
+
*/
|
|
7438
|
+
|
|
7439
|
+
/**
|
|
7440
|
+
* The date format in the input boxes when they are selected for
|
|
7441
|
+
* editing. This must be a format that is recognized by JavaScript
|
|
7442
|
+
* Date.parse.
|
|
7443
|
+
*
|
|
7444
|
+
* @sample {highstock} stock/rangeselector/input-format/
|
|
7445
|
+
* Milliseconds in the range selector
|
|
7446
|
+
*
|
|
7447
|
+
* @type {string}
|
|
7448
|
+
* @default %Y-%m-%d
|
|
7449
|
+
* @product highstock
|
|
7450
|
+
* @apioption rangeSelector.inputEditDateFormat
|
|
7451
|
+
*/
|
|
7452
|
+
|
|
7453
|
+
/**
|
|
7454
|
+
* Enable or disable the date input boxes. Defaults to enabled when
|
|
7455
|
+
* there is enough space, disabled if not (typically mobile).
|
|
7456
|
+
*
|
|
7457
|
+
* @sample {highstock} stock/rangeselector/input-datepicker/
|
|
7458
|
+
* Extending the input with a jQuery UI datepicker
|
|
7459
|
+
*
|
|
7460
|
+
* @type {boolean}
|
|
7461
|
+
* @default true
|
|
7462
|
+
* @product highstock
|
|
7463
|
+
* @apioption rangeSelector.inputEnabled
|
|
7464
|
+
*/
|
|
7465
|
+
|
|
6629
7466
|
/**
|
|
6630
7467
|
* Positioning for the input boxes. Allowed properties are `align`,
|
|
6631
7468
|
* `x` and `y`.
|
|
6632
7469
|
*
|
|
6633
|
-
* @type
|
|
6634
|
-
* @
|
|
6635
|
-
* @
|
|
6636
|
-
* @
|
|
7470
|
+
* @type {*}
|
|
7471
|
+
* @since 1.2.4
|
|
7472
|
+
* @product highstock
|
|
7473
|
+
* @apioption rangeSelector.inputPosition
|
|
6637
7474
|
*/
|
|
6638
7475
|
inputPosition: {
|
|
6639
7476
|
/**
|
|
6640
7477
|
* The alignment of the input box. Allowed properties are `left`,
|
|
6641
7478
|
* `center`, `right`.
|
|
6642
|
-
|
|
6643
|
-
|
|
6644
|
-
|
|
6645
|
-
|
|
7479
|
+
*
|
|
7480
|
+
* @sample {highstock} stock/rangeselector/input-button-position/
|
|
7481
|
+
* Alignment
|
|
7482
|
+
*
|
|
7483
|
+
* @type {string}
|
|
7484
|
+
* @default right
|
|
7485
|
+
* @since 6.0.0
|
|
7486
|
+
* @validvalue ["left", "center", "right"]
|
|
7487
|
+
* @apioption rangeSelector.inputPosition.align
|
|
6646
7488
|
*/
|
|
6647
7489
|
align: 'right',
|
|
7490
|
+
|
|
7491
|
+
/**
|
|
7492
|
+
* X offset of the input row.
|
|
7493
|
+
*
|
|
7494
|
+
* @type {number}
|
|
7495
|
+
* @default 0
|
|
7496
|
+
* @apioption rangeSelector.inputPosition.x
|
|
7497
|
+
*/
|
|
6648
7498
|
x: 0,
|
|
7499
|
+
|
|
7500
|
+
/**
|
|
7501
|
+
* Y offset of the input row.
|
|
7502
|
+
*
|
|
7503
|
+
* @type {number}
|
|
7504
|
+
* @default 0
|
|
7505
|
+
* @apioption rangeSelector.inputPosition.y
|
|
7506
|
+
*/
|
|
6649
7507
|
y: 0
|
|
6650
7508
|
},
|
|
6651
7509
|
|
|
7510
|
+
/**
|
|
7511
|
+
* The index of the button to appear pre-selected.
|
|
7512
|
+
*
|
|
7513
|
+
* @type {number}
|
|
7514
|
+
* @product highstock
|
|
7515
|
+
* @apioption rangeSelector.selected
|
|
7516
|
+
*/
|
|
7517
|
+
|
|
6652
7518
|
/**
|
|
6653
7519
|
* Positioning for the button row.
|
|
6654
7520
|
*
|
|
6655
|
-
* @
|
|
6656
|
-
* @
|
|
7521
|
+
* @type {*}
|
|
7522
|
+
* @since 1.2.4
|
|
7523
|
+
* @product highstock
|
|
7524
|
+
* @apioption rangeSelector.buttonPosition
|
|
6657
7525
|
*/
|
|
6658
7526
|
buttonPosition: {
|
|
7527
|
+
|
|
6659
7528
|
/**
|
|
6660
7529
|
* The alignment of the input box. Allowed properties are `left`,
|
|
6661
7530
|
* `center`, `right`.
|
|
6662
|
-
|
|
6663
|
-
|
|
6664
|
-
|
|
6665
|
-
|
|
6666
|
-
|
|
7531
|
+
*
|
|
7532
|
+
* @sample {highstock} stock/rangeselector/input-button-position/
|
|
7533
|
+
* Alignment
|
|
7534
|
+
*
|
|
7535
|
+
* @type {string}
|
|
7536
|
+
* @default left
|
|
7537
|
+
* @since 6.0.0
|
|
7538
|
+
* @validvalue ["left", "center", "right"]
|
|
7539
|
+
* @apioption rangeSelector.buttonPosition.align
|
|
6667
7540
|
*/
|
|
6668
7541
|
align: 'left',
|
|
7542
|
+
|
|
6669
7543
|
/**
|
|
6670
7544
|
* X offset of the button row.
|
|
7545
|
+
*
|
|
7546
|
+
* @type {number}
|
|
7547
|
+
* @default 0
|
|
7548
|
+
* @apioption rangeSelector.buttonPosition.x
|
|
6671
7549
|
*/
|
|
6672
7550
|
x: 0,
|
|
7551
|
+
|
|
6673
7552
|
/**
|
|
6674
7553
|
* Y offset of the button row.
|
|
7554
|
+
*
|
|
7555
|
+
* @type {number}
|
|
7556
|
+
* @default 0
|
|
7557
|
+
* @apioption rangeSelector.buttonPosition.y
|
|
6675
7558
|
*/
|
|
6676
7559
|
y: 0
|
|
6677
|
-
}
|
|
6678
|
-
|
|
6679
|
-
// inputEditDateFormat: '%Y-%m-%d',
|
|
6680
|
-
// inputEnabled: true,
|
|
6681
|
-
// selected: undefined
|
|
7560
|
+
}
|
|
7561
|
+
|
|
6682
7562
|
|
|
6683
7563
|
}
|
|
6684
7564
|
});
|
|
@@ -6712,9 +7592,10 @@
|
|
|
6712
7592
|
/**
|
|
6713
7593
|
* The text for the label for the range selector buttons.
|
|
6714
7594
|
*
|
|
6715
|
-
* @type
|
|
6716
|
-
* @default
|
|
6717
|
-
* @product
|
|
7595
|
+
* @type {string}
|
|
7596
|
+
* @default Zoom
|
|
7597
|
+
* @product highstock
|
|
7598
|
+
* @apioption lang.rangeSelectorZoom
|
|
6718
7599
|
*/
|
|
6719
7600
|
rangeSelectorZoom: 'Zoom',
|
|
6720
7601
|
|
|
@@ -6722,18 +7603,20 @@
|
|
|
6722
7603
|
* The text for the label for the "from" input box in the range
|
|
6723
7604
|
* selector.
|
|
6724
7605
|
*
|
|
6725
|
-
* @type
|
|
6726
|
-
* @default
|
|
6727
|
-
* @product
|
|
7606
|
+
* @type {string}
|
|
7607
|
+
* @default From
|
|
7608
|
+
* @product highstock
|
|
7609
|
+
* @apioption lang.rangeSelectorFrom
|
|
6728
7610
|
*/
|
|
6729
7611
|
rangeSelectorFrom: 'From',
|
|
6730
7612
|
|
|
6731
7613
|
/**
|
|
6732
7614
|
* The text for the label for the "to" input box in the range selector.
|
|
6733
7615
|
*
|
|
6734
|
-
* @type
|
|
6735
|
-
* @default
|
|
6736
|
-
* @product
|
|
7616
|
+
* @type {string}
|
|
7617
|
+
* @default To
|
|
7618
|
+
* @product highstock
|
|
7619
|
+
* @apioption lang.rangeSelectorTo
|
|
6737
7620
|
*/
|
|
6738
7621
|
rangeSelectorTo: 'To'
|
|
6739
7622
|
}
|
|
@@ -6741,8 +7624,10 @@
|
|
|
6741
7624
|
|
|
6742
7625
|
/**
|
|
6743
7626
|
* The range selector.
|
|
6744
|
-
*
|
|
6745
|
-
* @
|
|
7627
|
+
*
|
|
7628
|
+
* @class Highcharts.RangeSelector
|
|
7629
|
+
*
|
|
7630
|
+
* @param {Highcharts.Chart} chart
|
|
6746
7631
|
*/
|
|
6747
7632
|
function RangeSelector(chart) {
|
|
6748
7633
|
|
|
@@ -6754,9 +7639,15 @@
|
|
|
6754
7639
|
/**
|
|
6755
7640
|
* The method to run when one of the buttons in the range selectors is
|
|
6756
7641
|
* clicked
|
|
6757
|
-
*
|
|
6758
|
-
* @
|
|
6759
|
-
*
|
|
7642
|
+
*
|
|
7643
|
+
* @function Highcharts.RangeSelector#clickButton
|
|
7644
|
+
*
|
|
7645
|
+
* @param {number} i
|
|
7646
|
+
* The index of the button
|
|
7647
|
+
*
|
|
7648
|
+
* @param {boolean} redraw
|
|
7649
|
+
*
|
|
7650
|
+
* @return {void}
|
|
6760
7651
|
*/
|
|
6761
7652
|
clickButton: function (i, redraw) {
|
|
6762
7653
|
var rangeSelector = this,
|
|
@@ -6798,6 +7689,8 @@
|
|
|
6798
7689
|
dataGrouping,
|
|
6799
7690
|
false
|
|
6800
7691
|
);
|
|
7692
|
+
|
|
7693
|
+
this.frozenStates = rangeOptions.preserveDataGrouping;
|
|
6801
7694
|
}
|
|
6802
7695
|
|
|
6803
7696
|
// Apply range
|
|
@@ -6904,6 +7797,12 @@
|
|
|
6904
7797
|
/**
|
|
6905
7798
|
* Set the selected option. This method only sets the internal flag, it
|
|
6906
7799
|
* doesn't update the buttons or the actual zoomed range.
|
|
7800
|
+
*
|
|
7801
|
+
* @function Highcharts.RangeSelector#setSelected
|
|
7802
|
+
*
|
|
7803
|
+
* @param {boolean} selected
|
|
7804
|
+
*
|
|
7805
|
+
* @return {void}
|
|
6907
7806
|
*/
|
|
6908
7807
|
setSelected: function (selected) {
|
|
6909
7808
|
this.selected = this.options.selected = selected;
|
|
@@ -6938,6 +7837,12 @@
|
|
|
6938
7837
|
|
|
6939
7838
|
/**
|
|
6940
7839
|
* Initialize the range selector
|
|
7840
|
+
*
|
|
7841
|
+
* @function Highcharts.RangeSelector#init
|
|
7842
|
+
*
|
|
7843
|
+
* @param {Highcharts.Chart} chart
|
|
7844
|
+
*
|
|
7845
|
+
* @return {void}
|
|
6941
7846
|
*/
|
|
6942
7847
|
init: function (chart) {
|
|
6943
7848
|
var rangeSelector = this,
|
|
@@ -6986,7 +7891,8 @@
|
|
|
6986
7891
|
this.max - this.min !== chart.fixedRange &&
|
|
6987
7892
|
e.trigger !== 'rangeSelectorButton' &&
|
|
6988
7893
|
e.trigger !== 'updatedData' &&
|
|
6989
|
-
rangeSelector.forcedDataGrouping
|
|
7894
|
+
rangeSelector.forcedDataGrouping &&
|
|
7895
|
+
!rangeSelector.frozenStates
|
|
6990
7896
|
) {
|
|
6991
7897
|
this.setDataGrouping(false, false);
|
|
6992
7898
|
}
|
|
@@ -6998,6 +7904,10 @@
|
|
|
6998
7904
|
/**
|
|
6999
7905
|
* Dynamically update the range selector buttons after a new range has been
|
|
7000
7906
|
* set
|
|
7907
|
+
*
|
|
7908
|
+
* @function Highcharts.RangeSelector#updateButtonStates
|
|
7909
|
+
*
|
|
7910
|
+
* @return {void}
|
|
7001
7911
|
*/
|
|
7002
7912
|
updateButtonStates: function () {
|
|
7003
7913
|
var rangeSelector = this,
|
|
@@ -7085,7 +7995,8 @@
|
|
|
7085
7995
|
);
|
|
7086
7996
|
select = (
|
|
7087
7997
|
(isSelected && isSameRange) ||
|
|
7088
|
-
(isSameRange && !selectedExists && !isYTDButNotSelected)
|
|
7998
|
+
(isSameRange && !selectedExists && !isYTDButNotSelected) ||
|
|
7999
|
+
(isSelected && rangeSelector.frozenStates)
|
|
7089
8000
|
);
|
|
7090
8001
|
|
|
7091
8002
|
if (disable) {
|
|
@@ -7104,6 +8015,12 @@
|
|
|
7104
8015
|
|
|
7105
8016
|
/**
|
|
7106
8017
|
* Compute and cache the range for an individual button
|
|
8018
|
+
*
|
|
8019
|
+
* @function Highcharts.RangeSelector#computeButtonRange
|
|
8020
|
+
*
|
|
8021
|
+
* @param {Highcharts.RangeSelectorOptions} rangeOptions
|
|
8022
|
+
*
|
|
8023
|
+
* @return {void}
|
|
7107
8024
|
*/
|
|
7108
8025
|
computeButtonRange: function (rangeOptions) {
|
|
7109
8026
|
var type = rangeOptions.type,
|
|
@@ -7136,8 +8053,14 @@
|
|
|
7136
8053
|
|
|
7137
8054
|
/**
|
|
7138
8055
|
* Set the internal and displayed value of a HTML input for the dates
|
|
7139
|
-
*
|
|
7140
|
-
* @
|
|
8056
|
+
*
|
|
8057
|
+
* @function Highcharts.RangeSelector#setInputValue
|
|
8058
|
+
*
|
|
8059
|
+
* @param {string} name
|
|
8060
|
+
*
|
|
8061
|
+
* @param {number} inputTime
|
|
8062
|
+
*
|
|
8063
|
+
* @return {void}
|
|
7141
8064
|
*/
|
|
7142
8065
|
setInputValue: function (name, inputTime) {
|
|
7143
8066
|
var options = this.chart.options.rangeSelector,
|
|
@@ -7161,6 +8084,13 @@
|
|
|
7161
8084
|
});
|
|
7162
8085
|
},
|
|
7163
8086
|
|
|
8087
|
+
/**
|
|
8088
|
+
* @function Highcharts.RangeSelector#showInput
|
|
8089
|
+
*
|
|
8090
|
+
* @param {string} name
|
|
8091
|
+
*
|
|
8092
|
+
* @return {void}
|
|
8093
|
+
*/
|
|
7164
8094
|
showInput: function (name) {
|
|
7165
8095
|
var inputGroup = this.inputGroup,
|
|
7166
8096
|
dateBox = this[name + 'DateBox'];
|
|
@@ -7174,6 +8104,13 @@
|
|
|
7174
8104
|
});
|
|
7175
8105
|
},
|
|
7176
8106
|
|
|
8107
|
+
/**
|
|
8108
|
+
* @function Highcharts.RangeSelector#hideInput
|
|
8109
|
+
*
|
|
8110
|
+
* @param {string} name
|
|
8111
|
+
*
|
|
8112
|
+
* @return {void}
|
|
8113
|
+
*/
|
|
7177
8114
|
hideInput: function (name) {
|
|
7178
8115
|
css(this[name + 'Input'], {
|
|
7179
8116
|
border: 0,
|
|
@@ -7185,7 +8122,12 @@
|
|
|
7185
8122
|
|
|
7186
8123
|
/**
|
|
7187
8124
|
* Draw either the 'from' or the 'to' HTML input box of the range selector
|
|
7188
|
-
*
|
|
8125
|
+
*
|
|
8126
|
+
* @function Highcharts.RangeSelector#drawInput
|
|
8127
|
+
*
|
|
8128
|
+
* @param {string} name
|
|
8129
|
+
*
|
|
8130
|
+
* @return {void}
|
|
7189
8131
|
*/
|
|
7190
8132
|
drawInput: function (name) {
|
|
7191
8133
|
var rangeSelector = this,
|
|
@@ -7282,10 +8224,8 @@
|
|
|
7282
8224
|
padding: 2,
|
|
7283
8225
|
width: options.inputBoxWidth || 90,
|
|
7284
8226
|
height: options.inputBoxHeight || 17,
|
|
7285
|
-
stroke:
|
|
7286
|
-
options.inputBoxBorderColor || '#cccccc',
|
|
7287
|
-
'stroke-width': 1,
|
|
7288
8227
|
'text-align': 'center'
|
|
8228
|
+
|
|
7289
8229
|
})
|
|
7290
8230
|
.on('click', function () {
|
|
7291
8231
|
// If it is already focused, the onfocus event doesn't fire
|
|
@@ -7332,6 +8272,10 @@
|
|
|
7332
8272
|
/**
|
|
7333
8273
|
* Get the position of the range selector buttons and inputs. This can be
|
|
7334
8274
|
* overridden from outside for custom positioning.
|
|
8275
|
+
*
|
|
8276
|
+
* @function Highcharts.RangeSelector#getPosition
|
|
8277
|
+
*
|
|
8278
|
+
* @return {Highcharts.Dictionary<number>}
|
|
7335
8279
|
*/
|
|
7336
8280
|
getPosition: function () {
|
|
7337
8281
|
var chart = this.chart,
|
|
@@ -7346,13 +8290,18 @@
|
|
|
7346
8290
|
};
|
|
7347
8291
|
},
|
|
7348
8292
|
/**
|
|
7349
|
-
* Get the extremes of YTD.
|
|
7350
|
-
* Will choose
|
|
7351
|
-
*
|
|
7352
|
-
*
|
|
8293
|
+
* Get the extremes of YTD. Will choose dataMax if its value is lower than
|
|
8294
|
+
* the current timestamp. Will choose dataMin if its value is higher than
|
|
8295
|
+
* the timestamp for the start of current year.
|
|
8296
|
+
*
|
|
8297
|
+
* @function Highcharts.RangeSelector#getYTDExtremes
|
|
8298
|
+
*
|
|
7353
8299
|
* @param {number} dataMax
|
|
8300
|
+
*
|
|
7354
8301
|
* @param {number} dataMin
|
|
7355
|
-
*
|
|
8302
|
+
*
|
|
8303
|
+
* @return {*}
|
|
8304
|
+
* Returns min and max for the YTD
|
|
7356
8305
|
*/
|
|
7357
8306
|
getYTDExtremes: function (dataMax, dataMin, useUTC) {
|
|
7358
8307
|
var time = this.chart.time,
|
|
@@ -7374,8 +8323,16 @@
|
|
|
7374
8323
|
* Render the range selector including the buttons and the inputs. The first
|
|
7375
8324
|
* time render is called, the elements are created and positioned. On
|
|
7376
8325
|
* subsequent calls, they are moved and updated.
|
|
7377
|
-
*
|
|
7378
|
-
* @
|
|
8326
|
+
*
|
|
8327
|
+
* @function Highcharts.RangeSelector#render
|
|
8328
|
+
*
|
|
8329
|
+
* @param {number} min
|
|
8330
|
+
* X axis minimum
|
|
8331
|
+
*
|
|
8332
|
+
* @param {number} max
|
|
8333
|
+
* X axis maximum
|
|
8334
|
+
*
|
|
8335
|
+
* @return {void}
|
|
7379
8336
|
*/
|
|
7380
8337
|
render: function (min, max) {
|
|
7381
8338
|
|
|
@@ -7393,6 +8350,12 @@
|
|
|
7393
8350
|
lang = defaultOptions.lang,
|
|
7394
8351
|
div = rangeSelector.div,
|
|
7395
8352
|
options = chartOptions.rangeSelector,
|
|
8353
|
+
// Place inputs above the container
|
|
8354
|
+
inputsZIndex = pick(
|
|
8355
|
+
chartOptions.chart.style &&
|
|
8356
|
+
chartOptions.chart.style.zIndex,
|
|
8357
|
+
0
|
|
8358
|
+
) + 1,
|
|
7396
8359
|
floating = options.floating,
|
|
7397
8360
|
buttons = rangeSelector.buttons,
|
|
7398
8361
|
inputGroup = rangeSelector.inputGroup,
|
|
@@ -7413,6 +8376,7 @@
|
|
|
7413
8376
|
buttonPositionY = buttonPosition.y,
|
|
7414
8377
|
inputPositionY = inputPosition.y,
|
|
7415
8378
|
animate = rendered || false,
|
|
8379
|
+
verb = animate ? 'animate' : 'attr',
|
|
7416
8380
|
exportingX = 0,
|
|
7417
8381
|
alignTranslateY,
|
|
7418
8382
|
legendHeight,
|
|
@@ -7438,20 +8402,17 @@
|
|
|
7438
8402
|
|
|
7439
8403
|
rangeSelector.zoomText = renderer.text(
|
|
7440
8404
|
lang.rangeSelectorZoom,
|
|
7441
|
-
|
|
8405
|
+
0,
|
|
8406
|
+
15
|
|
7442
8407
|
)
|
|
7443
8408
|
.css(options.labelStyle)
|
|
7444
8409
|
.add(buttonGroup);
|
|
7445
8410
|
|
|
7446
|
-
// button start position
|
|
7447
|
-
buttonLeft = pick(plotLeft + buttonPosition.x, plotLeft) +
|
|
7448
|
-
rangeSelector.zoomText.getBBox().width + 5;
|
|
7449
|
-
|
|
7450
8411
|
each(rangeSelector.buttonOptions, function (rangeOptions, i) {
|
|
7451
8412
|
|
|
7452
8413
|
buttons[i] = renderer.button(
|
|
7453
8414
|
rangeOptions.text,
|
|
7454
|
-
|
|
8415
|
+
0,
|
|
7455
8416
|
0,
|
|
7456
8417
|
function () {
|
|
7457
8418
|
|
|
@@ -7482,9 +8443,6 @@
|
|
|
7482
8443
|
'text-align': 'center'
|
|
7483
8444
|
})
|
|
7484
8445
|
.add(buttonGroup);
|
|
7485
|
-
|
|
7486
|
-
// increase button position for the next button
|
|
7487
|
-
buttonLeft += buttons[i].width + pick(options.buttonSpacing, 5);
|
|
7488
8446
|
});
|
|
7489
8447
|
|
|
7490
8448
|
// first create a wrapper outside the container in order to make
|
|
@@ -7493,7 +8451,7 @@
|
|
|
7493
8451
|
rangeSelector.div = div = createElement('div', null, {
|
|
7494
8452
|
position: 'relative',
|
|
7495
8453
|
height: 0,
|
|
7496
|
-
zIndex:
|
|
8454
|
+
zIndex: inputsZIndex
|
|
7497
8455
|
});
|
|
7498
8456
|
|
|
7499
8457
|
container.parentNode.insertBefore(div, container);
|
|
@@ -7508,6 +8466,22 @@
|
|
|
7508
8466
|
}
|
|
7509
8467
|
}
|
|
7510
8468
|
|
|
8469
|
+
// #8769, allow dynamically updating margins
|
|
8470
|
+
rangeSelector.zoomText[verb]({
|
|
8471
|
+
x: pick(plotLeft + buttonPosition.x, plotLeft)
|
|
8472
|
+
});
|
|
8473
|
+
// button start position
|
|
8474
|
+
buttonLeft = pick(plotLeft + buttonPosition.x, plotLeft) +
|
|
8475
|
+
rangeSelector.zoomText.getBBox().width + 5;
|
|
8476
|
+
each(rangeSelector.buttonOptions, function (rangeOptions, i) {
|
|
8477
|
+
|
|
8478
|
+
buttons[i][verb]({ x: buttonLeft });
|
|
8479
|
+
|
|
8480
|
+
// increase button position for the next button
|
|
8481
|
+
buttonLeft += buttons[i].width + pick(options.buttonSpacing, 5);
|
|
8482
|
+
});
|
|
8483
|
+
|
|
8484
|
+
|
|
7511
8485
|
plotLeft = chart.plotLeft - chart.spacing[3];
|
|
7512
8486
|
rangeSelector.updateButtonStates();
|
|
7513
8487
|
|
|
@@ -7709,7 +8683,11 @@
|
|
|
7709
8683
|
|
|
7710
8684
|
/**
|
|
7711
8685
|
* Extracts height of range selector
|
|
7712
|
-
*
|
|
8686
|
+
*
|
|
8687
|
+
* @function Highcharts.RangeSelector#getHeight
|
|
8688
|
+
*
|
|
8689
|
+
* @return {number}
|
|
8690
|
+
* Returns rangeSelector height
|
|
7713
8691
|
*/
|
|
7714
8692
|
getHeight: function () {
|
|
7715
8693
|
var rangeSelector = this,
|
|
@@ -7742,8 +8720,13 @@
|
|
|
7742
8720
|
|
|
7743
8721
|
/**
|
|
7744
8722
|
* Detect collision with title or subtitle
|
|
7745
|
-
*
|
|
7746
|
-
* @
|
|
8723
|
+
*
|
|
8724
|
+
* @function Highcharts.RangeSelector#titleCollision
|
|
8725
|
+
*
|
|
8726
|
+
* @param {Highcharts.Chart} chart
|
|
8727
|
+
*
|
|
8728
|
+
* @return {boolean}
|
|
8729
|
+
* Returns collision status
|
|
7747
8730
|
*/
|
|
7748
8731
|
titleCollision: function (chart) {
|
|
7749
8732
|
return !(chart.options.title.text || chart.options.subtitle.text);
|
|
@@ -7751,7 +8734,12 @@
|
|
|
7751
8734
|
|
|
7752
8735
|
/**
|
|
7753
8736
|
* Update the range selector with new options
|
|
7754
|
-
*
|
|
8737
|
+
*
|
|
8738
|
+
* @function Highcharts.RangeSelector#update
|
|
8739
|
+
*
|
|
8740
|
+
* @param {Highcharts.RangeSelectorOptions} options
|
|
8741
|
+
*
|
|
8742
|
+
* @return {void}
|
|
7755
8743
|
*/
|
|
7756
8744
|
update: function (options) {
|
|
7757
8745
|
var chart = this.chart;
|
|
@@ -7764,6 +8752,10 @@
|
|
|
7764
8752
|
|
|
7765
8753
|
/**
|
|
7766
8754
|
* Destroys allocated elements.
|
|
8755
|
+
*
|
|
8756
|
+
* @function Highcharts.RangeSelector#destroy
|
|
8757
|
+
*
|
|
8758
|
+
* @return {void}
|
|
7767
8759
|
*/
|
|
7768
8760
|
destroy: function () {
|
|
7769
8761
|
var rSelector = this,
|
|
@@ -7803,6 +8795,18 @@
|
|
|
7803
8795
|
/**
|
|
7804
8796
|
* Add logic to normalize the zoomed range in order to preserve the pressed
|
|
7805
8797
|
* state of range selector buttons
|
|
8798
|
+
*
|
|
8799
|
+
* @function Highcharts.Axis#toFixedRange
|
|
8800
|
+
*
|
|
8801
|
+
* @param {number} pxMin
|
|
8802
|
+
*
|
|
8803
|
+
* @param {number} pxMax
|
|
8804
|
+
*
|
|
8805
|
+
* @param {number} fixedMin
|
|
8806
|
+
*
|
|
8807
|
+
* @param {number} fixedMax
|
|
8808
|
+
*
|
|
8809
|
+
* @return {*}
|
|
7806
8810
|
*/
|
|
7807
8811
|
Axis.prototype.toFixedRange = function (pxMin, pxMax, fixedMin, fixedMax) {
|
|
7808
8812
|
var fixedRange = this.chart && this.chart.fixedRange,
|
|
@@ -7836,7 +8840,10 @@
|
|
|
7836
8840
|
* selected range is a multiple of months or years, it is compensated for
|
|
7837
8841
|
* various month lengths.
|
|
7838
8842
|
*
|
|
7839
|
-
* @
|
|
8843
|
+
* @function Highcharts.Axis#minFromRange
|
|
8844
|
+
*
|
|
8845
|
+
* @return {number}
|
|
8846
|
+
* The new minimum value.
|
|
7840
8847
|
*/
|
|
7841
8848
|
Axis.prototype.minFromRange = function () {
|
|
7842
8849
|
var rangeOptions = this.range,
|
|
@@ -7933,20 +8940,32 @@
|
|
|
7933
8940
|
|
|
7934
8941
|
var chart = this,
|
|
7935
8942
|
options = e.options,
|
|
8943
|
+
optionsRangeSelector = options.rangeSelector,
|
|
7936
8944
|
rangeSelector = chart.rangeSelector,
|
|
7937
|
-
verticalAlign
|
|
8945
|
+
verticalAlign,
|
|
8946
|
+
extraBottomMarginWas = this.extraBottomMargin,
|
|
8947
|
+
extraTopMarginWas = this.extraTopMargin;
|
|
8948
|
+
|
|
8949
|
+
if (
|
|
8950
|
+
optionsRangeSelector &&
|
|
8951
|
+
optionsRangeSelector.enabled &&
|
|
8952
|
+
!defined(rangeSelector)
|
|
8953
|
+
) {
|
|
8954
|
+
this.options.rangeSelector.enabled = true;
|
|
8955
|
+
this.rangeSelector = new RangeSelector(this);
|
|
8956
|
+
}
|
|
8957
|
+
|
|
7938
8958
|
|
|
7939
8959
|
this.extraBottomMargin = false;
|
|
7940
8960
|
this.extraTopMargin = false;
|
|
7941
|
-
this.isDirtyBox = true; // #7684 - ignored spacingBottom after update
|
|
7942
8961
|
|
|
7943
8962
|
if (rangeSelector) {
|
|
7944
8963
|
|
|
7945
8964
|
rangeSelector.render();
|
|
7946
8965
|
|
|
7947
8966
|
verticalAlign = (
|
|
7948
|
-
|
|
7949
|
-
|
|
8967
|
+
optionsRangeSelector &&
|
|
8968
|
+
optionsRangeSelector.verticalAlign
|
|
7950
8969
|
) || (
|
|
7951
8970
|
rangeSelector.options && rangeSelector.options.verticalAlign
|
|
7952
8971
|
);
|
|
@@ -7959,6 +8978,13 @@
|
|
|
7959
8978
|
}
|
|
7960
8979
|
}
|
|
7961
8980
|
|
|
8981
|
+
if (
|
|
8982
|
+
this.extraBottomMargin !== extraBottomMarginWas ||
|
|
8983
|
+
this.extraTopMargin !== extraTopMarginWas
|
|
8984
|
+
) {
|
|
8985
|
+
this.isDirtyBox = true;
|
|
8986
|
+
}
|
|
8987
|
+
|
|
7962
8988
|
}
|
|
7963
8989
|
|
|
7964
8990
|
});
|
|
@@ -8049,7 +9075,7 @@
|
|
|
8049
9075
|
}(Highcharts));
|
|
8050
9076
|
(function (H) {
|
|
8051
9077
|
/**
|
|
8052
|
-
* (c) 2010-
|
|
9078
|
+
* (c) 2010-2018 Torstein Honsi
|
|
8053
9079
|
*
|
|
8054
9080
|
* License: www.highcharts.com/license
|
|
8055
9081
|
*/
|
|
@@ -8089,7 +9115,8 @@
|
|
|
8089
9115
|
* zero value in the visible range. The y axis will show percentage
|
|
8090
9116
|
* or absolute change depending on whether `compare` is set to `"percent"`
|
|
8091
9117
|
* or `"value"`. When this is applied to multiple series, it allows
|
|
8092
|
-
* comparing the development of the series against each other.
|
|
9118
|
+
* comparing the development of the series against each other. Adds
|
|
9119
|
+
* a `change` field to every point object.
|
|
8093
9120
|
*
|
|
8094
9121
|
* @type {String}
|
|
8095
9122
|
* @see [compareBase](#plotOptions.series.compareBase),
|
|
@@ -8103,7 +9130,7 @@
|
|
|
8103
9130
|
*/
|
|
8104
9131
|
|
|
8105
9132
|
/**
|
|
8106
|
-
* Defines if
|
|
9133
|
+
* Defines if comparison should start from the first point within the visible
|
|
8107
9134
|
* range or should start from the first point <b>before</b> the range.
|
|
8108
9135
|
* In other words, this flag determines if first point within the visible range
|
|
8109
9136
|
* will have 0% (`compareStart=true`) or should have been already calculated
|
|
@@ -8442,7 +9469,7 @@
|
|
|
8442
9469
|
inArray(axis2, uniqueAxes) === -1 &&
|
|
8443
9470
|
// Do not draw on axis which overlap completely. #5424
|
|
8444
9471
|
!H.find(uniqueAxes, function (unique) {
|
|
8445
|
-
return unique.pos === axis2.pos && unique.len
|
|
9472
|
+
return unique.pos === axis2.pos && unique.len === axis2.len;
|
|
8446
9473
|
})
|
|
8447
9474
|
) {
|
|
8448
9475
|
uniqueAxes.push(axis2);
|
|
@@ -8460,7 +9487,10 @@
|
|
|
8460
9487
|
x1 = x2 = Math.round(transVal + axis.transB);
|
|
8461
9488
|
|
|
8462
9489
|
// outside plot area
|
|
8463
|
-
if (
|
|
9490
|
+
if (
|
|
9491
|
+
force !== 'pass' &&
|
|
9492
|
+
(x1 < axisLeft || x1 > axisLeft + axis.width)
|
|
9493
|
+
) {
|
|
8464
9494
|
if (force) {
|
|
8465
9495
|
x1 = x2 = Math.min(
|
|
8466
9496
|
Math.max(axisLeft, x1),
|
|
@@ -8483,7 +9513,10 @@
|
|
|
8483
9513
|
y1 = y2 = Math.round(axisTop + axis.height - transVal);
|
|
8484
9514
|
|
|
8485
9515
|
// outside plot area
|
|
8486
|
-
if (
|
|
9516
|
+
if (
|
|
9517
|
+
force !== 'pass' &&
|
|
9518
|
+
(y1 < axisTop || y1 > axisTop + axis.height)
|
|
9519
|
+
) {
|
|
8487
9520
|
if (force) {
|
|
8488
9521
|
y1 = y2 = Math.min(
|
|
8489
9522
|
Math.max(axisTop, y1),
|
|
@@ -8567,7 +9600,18 @@
|
|
|
8567
9600
|
offset = 0,
|
|
8568
9601
|
// Use last available event (#5287)
|
|
8569
9602
|
e = event.e || (this.cross && this.cross.e),
|
|
8570
|
-
point = event.point
|
|
9603
|
+
point = event.point,
|
|
9604
|
+
lin2log = this.lin2log,
|
|
9605
|
+
min,
|
|
9606
|
+
max;
|
|
9607
|
+
|
|
9608
|
+
if (this.isLog) {
|
|
9609
|
+
min = lin2log(this.min);
|
|
9610
|
+
max = lin2log(this.max);
|
|
9611
|
+
} else {
|
|
9612
|
+
min = this.min;
|
|
9613
|
+
max = this.max;
|
|
9614
|
+
}
|
|
8571
9615
|
|
|
8572
9616
|
align = (horiz ? 'center' : opposite ?
|
|
8573
9617
|
(this.labelAlign === 'right' ? 'right' : 'left') :
|
|
@@ -8624,7 +9668,7 @@
|
|
|
8624
9668
|
x: posx,
|
|
8625
9669
|
y: posy,
|
|
8626
9670
|
// Crosshair should be rendered within Axis range (#7219)
|
|
8627
|
-
visibility: value <
|
|
9671
|
+
visibility: value < min || value > max ? 'hidden' : 'visible'
|
|
8628
9672
|
});
|
|
8629
9673
|
|
|
8630
9674
|
crossBox = crossLabel.getBBox();
|