highcharts 9.3.2 → 10.1.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 +19 -2
- package/css/highcharts.scss +17 -2
- package/css/themes/dark-unica.css +19 -2
- package/css/themes/grid-light.css +19 -2
- package/css/themes/sand-signika.css +19 -2
- package/es-modules/Accessibility/A11yI18n.js +4 -4
- package/es-modules/Accessibility/Accessibility.js +1 -1
- package/es-modules/Accessibility/Components/ContainerComponent.js +8 -9
- package/es-modules/Accessibility/Components/InfoRegionsComponent.js +14 -9
- package/es-modules/Accessibility/Components/LegendComponent.js +31 -23
- package/es-modules/Accessibility/Components/MenuComponent.js +15 -5
- package/es-modules/Accessibility/Components/RangeSelectorComponent.js +2 -2
- package/es-modules/Accessibility/Components/SeriesComponent/ForcedMarkers.js +7 -6
- package/es-modules/Accessibility/Components/SeriesComponent/NewDataAnnouncer.js +1 -1
- package/es-modules/Accessibility/Components/SeriesComponent/SeriesComponent.js +0 -1
- package/es-modules/Accessibility/Components/SeriesComponent/SeriesDescriber.js +34 -18
- package/es-modules/Accessibility/Components/SeriesComponent/SeriesKeyboardNavigation.js +84 -33
- package/es-modules/Accessibility/Components/ZoomComponent.js +13 -10
- package/es-modules/Accessibility/FocusBorder.js +6 -5
- package/es-modules/Accessibility/HighContrastMode.js +2 -2
- package/es-modules/Accessibility/KeyboardNavigation.js +113 -98
- package/es-modules/Accessibility/Options/LangOptions.js +36 -31
- package/es-modules/Accessibility/Options/Options.js +66 -3
- package/es-modules/Accessibility/ProxyElement.js +14 -6
- package/es-modules/Accessibility/ProxyProvider.js +10 -2
- package/es-modules/Accessibility/Utils/ChartUtilities.js +9 -4
- package/es-modules/Core/Axis/Axis.js +180 -73
- package/es-modules/Core/Axis/Color/ColorAxis.js +22 -5
- package/es-modules/Core/Axis/GridAxis.js +15 -11
- package/es-modules/Core/Axis/LogarithmicAxis.js +1 -1
- package/es-modules/Core/Axis/OrdinalAxis.js +3 -2
- package/es-modules/Core/Axis/PlotLineOrBand/PlotLineOrBand.js +1 -1
- package/es-modules/Core/Axis/StackingAxis.js +0 -1
- package/es-modules/Core/Axis/Tick.js +2 -2
- package/es-modules/Core/Axis/TreeGridTick.js +11 -0
- package/es-modules/Core/Chart/Chart.js +21 -3
- package/es-modules/Core/Chart/Chart3D.js +1 -11
- package/es-modules/Core/Chart/ChartDefaults.js +43 -11
- package/es-modules/Core/Chart/MapChart.js +1 -6
- package/es-modules/Core/Chart/StockChart.js +1 -1
- package/es-modules/Core/DefaultOptions.js +8 -4
- package/es-modules/Core/Geometry/PolygonClip.js +84 -0
- package/es-modules/Core/Globals.js +4 -18
- package/es-modules/Core/HttpUtilities.js +13 -8
- package/es-modules/Core/Legend/Legend.js +11 -9
- package/es-modules/Core/Navigator.js +10 -7
- package/es-modules/Core/Pointer.js +15 -11
- package/es-modules/Core/Renderer/HTML/AST.js +68 -8
- package/es-modules/Core/Renderer/SVG/SVGElement.js +47 -63
- package/es-modules/Core/Renderer/SVG/SVGElement3D.js +17 -5
- package/es-modules/Core/Renderer/SVG/SVGRenderer.js +31 -28
- package/es-modules/Core/Renderer/SVG/SVGRenderer3D.js +1 -1
- package/es-modules/Core/Renderer/SVG/TextBuilder.js +12 -10
- package/es-modules/Core/Scrollbar.js +9 -5
- package/es-modules/Core/Series/DataLabel.js +65 -36
- package/es-modules/Core/Series/Point.js +2 -2
- package/es-modules/Core/Series/Series.js +52 -22
- package/es-modules/Core/Series/SeriesDefaults.js +4 -1
- package/es-modules/Core/Tooltip.js +14 -31
- package/es-modules/Core/Utilities.js +29 -29
- package/es-modules/Extensions/Annotations/Annotations.js +9 -2
- package/es-modules/Extensions/Annotations/ControlPoint.js +1 -1
- package/es-modules/Extensions/Annotations/MockPoint.js +1 -1
- package/es-modules/Extensions/Annotations/NavigationBindings.js +9 -1
- package/es-modules/Extensions/Annotations/Popup.js +1 -1
- package/es-modules/Extensions/Annotations/Types/BasicAnnotation.js +5 -3
- package/es-modules/Extensions/Boost/BoostInit.js +6 -1
- package/es-modules/Extensions/Boost/BoostOptions.js +26 -0
- package/es-modules/Extensions/Boost/Boostables.js +1 -0
- package/es-modules/Extensions/Boost/WGLRenderer.js +48 -37
- package/es-modules/Extensions/Boost/WGLShader.js +4 -3
- package/es-modules/Extensions/Breadcrumbs.js +873 -0
- package/es-modules/Extensions/Data.js +26 -14
- package/es-modules/Extensions/DataGrouping.js +8 -3
- package/es-modules/Extensions/Debugger/ErrorMessages.js +4 -0
- package/es-modules/Extensions/DraggablePoints.js +9 -7
- package/es-modules/Extensions/Drilldown.js +150 -95
- package/es-modules/Extensions/ExportData.js +1 -2
- package/es-modules/Extensions/Exporting/Exporting.js +31 -20
- package/es-modules/Extensions/Exporting/ExportingDefaults.js +49 -1
- package/es-modules/Extensions/FullScreen.js +121 -54
- package/es-modules/Extensions/GeoJSON.js +151 -125
- package/es-modules/Extensions/MarkerClusters.js +34 -20
- package/es-modules/Extensions/OfflineExporting/OfflineExporting.js +110 -22
- package/es-modules/Extensions/OfflineExporting/OfflineExportingDefaults.js +1 -1
- package/es-modules/Extensions/Oldie/Oldie.js +1 -1
- package/es-modules/Extensions/OverlappingDataLabels.js +5 -4
- package/es-modules/Extensions/Polar.js +4 -1
- package/es-modules/Extensions/ScrollablePlotArea.js +5 -1
- package/es-modules/Extensions/Stacking.js +4 -3
- package/es-modules/Extensions/Themes/HighContrastDark.js +10 -10
- package/es-modules/Extensions/Themes/HighContrastLight.js +10 -10
- package/es-modules/Maps/MapNavigation.js +50 -13
- package/es-modules/Maps/MapPointer.js +16 -0
- package/es-modules/Maps/MapUtilities.js +56 -0
- package/es-modules/Maps/MapView.js +611 -136
- package/es-modules/Maps/MapViewInsetsOptionsDefault.js +148 -0
- package/es-modules/Maps/MapViewOptionsDefault.js +60 -20
- package/es-modules/Maps/Projection.js +169 -77
- package/es-modules/Maps/Projections/EqualEarth.js +15 -6
- package/es-modules/Maps/Projections/LambertConformalConic.js +27 -19
- package/es-modules/Maps/Projections/Miller.js +23 -10
- package/es-modules/Maps/Projections/Orthographic.js +21 -10
- package/es-modules/Maps/Projections/WebMercator.js +25 -13
- package/es-modules/Series/ArcDiagram/ArcDiagramPoint.js +77 -0
- package/es-modules/Series/ArcDiagram/ArcDiagramSeries.js +589 -0
- package/es-modules/Series/CenteredUtilities.js +6 -1
- package/es-modules/Series/Column/ColumnSeries.js +4 -3
- package/es-modules/Series/DataModifyComposition.js +1 -0
- package/es-modules/Series/DependencyWheel/DependencyWheelSeries.js +2 -2
- package/es-modules/Series/DrawPointComposition.js +7 -4
- package/es-modules/Series/Flags/FlagsSeries.js +7 -12
- package/es-modules/Series/Gauge/GaugeSeries.js +1 -1
- package/es-modules/Series/Heatmap/HeatmapSeries.js +13 -20
- package/es-modules/Series/Lollipop/LollipopSeries.js +1 -1
- package/es-modules/Series/Map/MapPoint.js +24 -1
- package/es-modules/Series/Map/MapSeries.js +206 -169
- package/es-modules/Series/MapBubble/MapBubblePoint.js +16 -24
- package/es-modules/Series/MapBubble/MapBubbleSeries.js +58 -1
- package/es-modules/Series/MapPoint/MapPointPoint.js +2 -8
- package/es-modules/Series/MapPoint/MapPointSeries.js +40 -14
- package/es-modules/Series/NodesComposition.js +60 -13
- package/es-modules/Series/OHLC/OHLCSeries.js +7 -0
- package/es-modules/Series/Organization/OrganizationPoint.js +68 -2
- package/es-modules/Series/Organization/OrganizationSeries.js +79 -25
- package/es-modules/Series/Pie/PieDataLabel.js +3 -1
- package/es-modules/Series/Pie/PiePoint.js +12 -5
- package/es-modules/Series/Pie/PieSeries.js +12 -1
- package/es-modules/Series/Pie3D/Pie3DSeries.js +19 -0
- package/es-modules/Series/Sankey/SankeyColumnComposition.js +193 -0
- package/es-modules/Series/Sankey/SankeyPoint.js +37 -1
- package/es-modules/Series/Sankey/SankeySeries.js +13 -128
- package/es-modules/Series/Scatter/ScatterSeries.js +1 -1
- package/es-modules/Series/Sunburst/SunburstSeries.js +14 -3
- package/es-modules/Series/Treemap/TreemapSeries.js +88 -80
- package/es-modules/Series/Waterfall/WaterfallSeries.js +2 -0
- package/es-modules/Series/Wordcloud/WordcloudSeries.js +4 -4
- package/es-modules/Stock/Indicators/SMA/SMAIndicator.js +9 -2
- package/es-modules/Stock/StockToolsBindings.js +31 -24
- package/es-modules/Stock/StockToolsGui.js +1 -1
- package/es-modules/masters/highcharts-3d.src.js +1 -1
- package/es-modules/masters/highcharts-gantt.src.js +1 -1
- package/es-modules/masters/highcharts-more.src.js +1 -1
- package/es-modules/masters/highcharts.src.js +1 -1
- package/es-modules/masters/highmaps.src.js +1 -1
- package/es-modules/masters/highstock.src.js +1 -1
- package/es-modules/masters/indicators/acceleration-bands.src.js +1 -1
- package/es-modules/masters/indicators/accumulation-distribution.src.js +1 -1
- package/es-modules/masters/indicators/ao.src.js +1 -1
- package/es-modules/masters/indicators/apo.src.js +1 -1
- package/es-modules/masters/indicators/aroon-oscillator.src.js +1 -1
- package/es-modules/masters/indicators/aroon.src.js +1 -1
- package/es-modules/masters/indicators/atr.src.js +1 -1
- package/es-modules/masters/indicators/bollinger-bands.src.js +1 -1
- package/es-modules/masters/indicators/cci.src.js +1 -1
- package/es-modules/masters/indicators/chaikin.src.js +1 -1
- package/es-modules/masters/indicators/cmf.src.js +1 -1
- package/es-modules/masters/indicators/cmo.src.js +1 -1
- package/es-modules/masters/indicators/dema.src.js +1 -1
- package/es-modules/masters/indicators/disparity-index.src.js +1 -1
- package/es-modules/masters/indicators/dmi.src.js +1 -1
- package/es-modules/masters/indicators/dpo.src.js +1 -1
- package/es-modules/masters/indicators/ichimoku-kinko-hyo.src.js +1 -1
- package/es-modules/masters/indicators/indicators-all.src.js +1 -1
- package/es-modules/masters/indicators/indicators.src.js +1 -1
- package/es-modules/masters/indicators/keltner-channels.src.js +1 -1
- package/es-modules/masters/indicators/klinger.src.js +1 -1
- package/es-modules/masters/indicators/macd.src.js +1 -1
- package/es-modules/masters/indicators/mfi.src.js +1 -1
- package/es-modules/masters/indicators/momentum.src.js +1 -1
- package/es-modules/masters/indicators/natr.src.js +1 -1
- package/es-modules/masters/indicators/obv.src.js +1 -1
- package/es-modules/masters/indicators/pivot-points.src.js +1 -1
- package/es-modules/masters/indicators/ppo.src.js +1 -1
- package/es-modules/masters/indicators/price-channel.src.js +1 -1
- package/es-modules/masters/indicators/price-envelopes.src.js +1 -1
- package/es-modules/masters/indicators/psar.src.js +1 -1
- package/es-modules/masters/indicators/regressions.src.js +1 -1
- package/es-modules/masters/indicators/roc.src.js +1 -1
- package/es-modules/masters/indicators/rsi.src.js +1 -1
- package/es-modules/masters/indicators/slow-stochastic.src.js +1 -1
- package/es-modules/masters/indicators/stochastic.src.js +1 -1
- package/es-modules/masters/indicators/supertrend.src.js +1 -1
- package/es-modules/masters/indicators/tema.src.js +1 -1
- package/es-modules/masters/indicators/trendline.src.js +1 -1
- package/es-modules/masters/indicators/trix.src.js +1 -1
- package/es-modules/masters/indicators/volume-by-price.src.js +1 -1
- package/es-modules/masters/indicators/vwap.src.js +1 -1
- package/es-modules/masters/indicators/williams-r.src.js +1 -1
- package/es-modules/masters/indicators/wma.src.js +1 -1
- package/es-modules/masters/indicators/zigzag.src.js +1 -1
- package/es-modules/masters/modules/accessibility.src.js +1 -1
- package/es-modules/masters/modules/annotations-advanced.src.js +1 -1
- package/es-modules/masters/modules/annotations.src.js +1 -1
- package/es-modules/masters/modules/arc-diagram.src.js +14 -0
- package/es-modules/masters/modules/arrow-symbols.src.js +1 -1
- package/es-modules/masters/modules/boost-canvas.src.js +1 -1
- package/es-modules/masters/modules/boost.src.js +1 -1
- package/es-modules/masters/modules/broken-axis.src.js +1 -1
- package/es-modules/masters/modules/bullet.src.js +1 -1
- package/es-modules/masters/modules/coloraxis.src.js +1 -1
- package/es-modules/masters/modules/current-date-indicator.src.js +1 -1
- package/es-modules/masters/modules/cylinder.src.js +1 -1
- package/es-modules/masters/modules/data.src.js +1 -1
- package/es-modules/masters/modules/datagrouping.src.js +1 -1
- package/es-modules/masters/modules/debugger.src.js +1 -1
- package/es-modules/masters/modules/dependency-wheel.src.js +1 -1
- package/es-modules/masters/modules/dotplot.src.js +1 -1
- package/es-modules/masters/modules/drag-panes.src.js +1 -1
- package/es-modules/masters/modules/draggable-points.src.js +1 -1
- package/es-modules/masters/modules/drilldown.src.js +2 -1
- package/es-modules/masters/modules/dumbbell.src.js +1 -1
- 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/full-screen.src.js +1 -1
- package/es-modules/masters/modules/funnel.src.js +1 -1
- package/es-modules/masters/modules/funnel3d.src.js +1 -1
- package/es-modules/masters/modules/gantt.src.js +1 -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/heikinashi.src.js +1 -1
- package/es-modules/masters/modules/histogram-bellcurve.src.js +1 -1
- package/es-modules/masters/modules/hollowcandlestick.src.js +1 -1
- package/es-modules/masters/modules/item-series.src.js +1 -1
- package/es-modules/masters/modules/lollipop.src.js +1 -1
- package/es-modules/masters/modules/map.src.js +5 -1
- package/es-modules/masters/modules/marker-clusters.src.js +1 -1
- package/es-modules/masters/modules/networkgraph.src.js +1 -1
- package/es-modules/masters/modules/no-data-to-display.src.js +1 -1
- package/es-modules/masters/modules/offline-exporting.src.js +1 -1
- package/es-modules/masters/modules/oldie-polyfills.src.js +1 -1
- package/es-modules/masters/modules/oldie.src.js +1 -1
- package/es-modules/masters/modules/organization.src.js +1 -1
- package/es-modules/masters/modules/overlapping-datalabels.src.js +1 -1
- package/es-modules/masters/modules/parallel-coordinates.src.js +1 -1
- package/es-modules/masters/modules/pareto.src.js +1 -1
- package/es-modules/masters/modules/pathfinder.src.js +1 -1
- package/es-modules/masters/modules/pattern-fill.src.js +1 -1
- package/es-modules/masters/modules/price-indicator.src.js +1 -1
- package/es-modules/masters/modules/pyramid3d.src.js +1 -1
- 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/sonification.src.js +1 -1
- package/es-modules/masters/modules/static-scale.src.js +1 -1
- package/es-modules/masters/modules/stock-tools.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/sunburst.src.js +1 -1
- package/es-modules/masters/modules/tilemap.src.js +1 -1
- package/es-modules/masters/modules/timeline.src.js +1 -1
- package/es-modules/masters/modules/treegrid.src.js +1 -1
- package/es-modules/masters/modules/treemap.src.js +5 -1
- package/es-modules/masters/modules/variable-pie.src.js +1 -1
- 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/venn.src.js +1 -1
- package/es-modules/masters/modules/windbarb.src.js +1 -1
- package/es-modules/masters/modules/wordcloud.src.js +1 -1
- package/es-modules/masters/modules/xrange.src.js +1 -1
- package/es-modules/masters/themes/avocado.src.js +1 -1
- package/es-modules/masters/themes/brand-dark.src.js +1 -1
- package/es-modules/masters/themes/brand-light.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/high-contrast-dark.src.js +1 -1
- package/es-modules/masters/themes/high-contrast-light.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/masters/themes/sunset.src.js +1 -1
- package/highcharts-3d.js +99 -98
- package/highcharts-3d.js.map +1 -1
- package/highcharts-3d.src.js +51 -21
- package/highcharts-gantt.js +808 -800
- package/highcharts-gantt.js.map +1 -1
- package/highcharts-gantt.src.js +781 -426
- package/highcharts-more.js +195 -194
- package/highcharts-more.js.map +1 -1
- package/highcharts-more.src.js +18 -4
- package/highcharts.d.ts +3224 -542
- package/highcharts.js +592 -584
- package/highcharts.js.map +1 -1
- package/highcharts.src.d.ts +3224 -542
- package/highcharts.src.js +732 -400
- package/highmaps.js +760 -728
- package/highmaps.js.map +1 -1
- package/highmaps.src.js +3840 -2189
- package/highstock.js +793 -786
- package/highstock.js.map +1 -1
- package/highstock.src.js +783 -432
- package/indicators/acceleration-bands.js +12 -11
- package/indicators/acceleration-bands.js.map +1 -1
- package/indicators/acceleration-bands.src.js +11 -2
- package/indicators/accumulation-distribution.js +5 -5
- package/indicators/accumulation-distribution.js.map +1 -1
- package/indicators/accumulation-distribution.src.js +11 -2
- package/indicators/ao.js +6 -6
- package/indicators/ao.js.map +1 -1
- package/indicators/ao.src.js +11 -2
- package/indicators/apo.js +5 -5
- package/indicators/apo.js.map +1 -1
- package/indicators/apo.src.js +11 -2
- package/indicators/aroon-oscillator.js +10 -10
- package/indicators/aroon-oscillator.js.map +1 -1
- package/indicators/aroon-oscillator.src.js +11 -2
- package/indicators/aroon.js +11 -11
- package/indicators/aroon.js.map +1 -1
- package/indicators/aroon.src.js +11 -2
- package/indicators/atr.js +5 -5
- package/indicators/atr.js.map +1 -1
- package/indicators/atr.src.js +11 -2
- package/indicators/bollinger-bands.js +12 -12
- package/indicators/bollinger-bands.js.map +1 -1
- package/indicators/bollinger-bands.src.js +11 -2
- package/indicators/cci.js +5 -5
- package/indicators/cci.js.map +1 -1
- package/indicators/cci.src.js +11 -2
- package/indicators/chaikin.js +8 -8
- package/indicators/chaikin.js.map +1 -1
- package/indicators/chaikin.src.js +11 -2
- package/indicators/cmf.js +6 -6
- package/indicators/cmf.js.map +1 -1
- package/indicators/cmf.src.js +11 -2
- package/indicators/cmo.js +5 -5
- package/indicators/cmo.js.map +1 -1
- package/indicators/cmo.src.js +11 -2
- package/indicators/dema.js +5 -5
- package/indicators/dema.js.map +1 -1
- package/indicators/dema.src.js +11 -2
- package/indicators/disparity-index.js +6 -6
- package/indicators/disparity-index.js.map +1 -1
- package/indicators/disparity-index.src.js +11 -2
- package/indicators/dmi.js +12 -12
- package/indicators/dmi.js.map +1 -1
- package/indicators/dmi.src.js +11 -2
- package/indicators/dpo.js +5 -5
- package/indicators/dpo.js.map +1 -1
- package/indicators/dpo.src.js +11 -2
- package/indicators/ema.js +2 -1
- package/indicators/ema.js.map +1 -1
- package/indicators/ema.src.js +10 -1
- package/indicators/ichimoku-kinko-hyo.js +16 -16
- package/indicators/ichimoku-kinko-hyo.js.map +1 -1
- package/indicators/ichimoku-kinko-hyo.src.js +11 -2
- package/indicators/indicators-all.js +195 -194
- package/indicators/indicators-all.js.map +1 -1
- package/indicators/indicators-all.src.js +21 -5
- package/indicators/indicators.js +13 -12
- package/indicators/indicators.js.map +1 -1
- package/indicators/indicators.src.js +21 -5
- package/indicators/keltner-channels.js +12 -11
- package/indicators/keltner-channels.js.map +1 -1
- package/indicators/keltner-channels.src.js +11 -2
- package/indicators/klinger.js +13 -13
- package/indicators/klinger.js.map +1 -1
- package/indicators/klinger.src.js +11 -2
- package/indicators/macd.js +12 -11
- package/indicators/macd.js.map +1 -1
- package/indicators/macd.src.js +11 -2
- package/indicators/mfi.js +6 -6
- package/indicators/mfi.js.map +1 -1
- package/indicators/mfi.src.js +11 -2
- package/indicators/momentum.js +5 -5
- package/indicators/momentum.js.map +1 -1
- package/indicators/momentum.src.js +11 -2
- package/indicators/natr.js +5 -4
- package/indicators/natr.js.map +1 -1
- package/indicators/natr.src.js +11 -2
- package/indicators/obv.js +5 -5
- package/indicators/obv.js.map +1 -1
- package/indicators/obv.src.js +11 -2
- package/indicators/pivot-points.js +11 -11
- package/indicators/pivot-points.js.map +1 -1
- package/indicators/pivot-points.src.js +11 -2
- package/indicators/ppo.js +5 -5
- package/indicators/ppo.js.map +1 -1
- package/indicators/ppo.src.js +11 -2
- package/indicators/price-channel.js +11 -11
- package/indicators/price-channel.js.map +1 -1
- package/indicators/price-channel.src.js +11 -2
- package/indicators/price-envelopes.js +8 -8
- package/indicators/price-envelopes.js.map +1 -1
- package/indicators/price-envelopes.src.js +11 -2
- package/indicators/psar.js +7 -6
- package/indicators/psar.js.map +1 -1
- package/indicators/psar.src.js +11 -2
- package/indicators/regressions.js +12 -12
- package/indicators/regressions.js.map +1 -1
- package/indicators/regressions.src.js +11 -2
- package/indicators/roc.js +5 -5
- package/indicators/roc.js.map +1 -1
- package/indicators/roc.src.js +11 -2
- package/indicators/rsi.js +6 -5
- package/indicators/rsi.js.map +1 -1
- package/indicators/rsi.src.js +11 -2
- package/indicators/slow-stochastic.js +5 -5
- package/indicators/slow-stochastic.js.map +1 -1
- package/indicators/slow-stochastic.src.js +11 -2
- package/indicators/stochastic.js +12 -12
- package/indicators/stochastic.js.map +1 -1
- package/indicators/stochastic.src.js +11 -2
- package/indicators/supertrend.js +10 -10
- package/indicators/supertrend.js.map +1 -1
- package/indicators/supertrend.src.js +11 -2
- package/indicators/tema.js +6 -6
- package/indicators/tema.js.map +1 -1
- package/indicators/tema.src.js +11 -2
- package/indicators/trendline.js +5 -5
- package/indicators/trendline.js.map +1 -1
- package/indicators/trendline.src.js +11 -2
- package/indicators/trix.js +4 -4
- package/indicators/trix.js.map +1 -1
- package/indicators/trix.src.js +11 -2
- package/indicators/volume-by-price.js +17 -17
- package/indicators/volume-by-price.js.map +1 -1
- package/indicators/volume-by-price.src.js +11 -2
- package/indicators/vwap.js +5 -5
- package/indicators/vwap.js.map +1 -1
- package/indicators/vwap.src.js +11 -2
- package/indicators/williams-r.js +6 -5
- package/indicators/williams-r.js.map +1 -1
- package/indicators/williams-r.src.js +11 -2
- package/indicators/wma.js +5 -5
- package/indicators/wma.js.map +1 -1
- package/indicators/wma.src.js +11 -2
- package/indicators/zigzag.js +6 -6
- package/indicators/zigzag.js.map +1 -1
- package/indicators/zigzag.src.js +11 -2
- package/lib/jspdf.js +299 -184
- package/lib/jspdf.src.js +25266 -18067
- package/lib/svg2pdf.js +35 -31
- package/lib/svg2pdf.src.js +5721 -4179
- package/modules/accessibility.js +245 -240
- package/modules/accessibility.js.map +1 -1
- package/modules/accessibility.src.js +510 -283
- package/modules/annotations-advanced.js +144 -144
- package/modules/annotations-advanced.js.map +1 -1
- package/modules/annotations-advanced.src.js +37 -11
- package/modules/annotations.js +79 -79
- package/modules/annotations.js.map +1 -1
- package/modules/annotations.src.js +32 -8
- package/modules/arc-diagram.js +25 -0
- package/modules/arc-diagram.js.map +1 -0
- package/modules/arc-diagram.src.js +778 -0
- package/modules/arrow-symbols.js +4 -3
- package/modules/arrow-symbols.js.map +1 -1
- package/modules/arrow-symbols.src.js +11 -2
- package/modules/boost-canvas.js +15 -15
- package/modules/boost-canvas.js.map +1 -1
- package/modules/boost-canvas.src.js +11 -2
- package/modules/boost.js +80 -79
- package/modules/boost.js.map +1 -1
- package/modules/boost.src.js +71 -43
- package/modules/broken-axis.js +13 -13
- package/modules/broken-axis.js.map +1 -1
- package/modules/broken-axis.src.js +11 -2
- package/modules/bullet.js +9 -9
- package/modules/bullet.js.map +1 -1
- package/modules/bullet.src.js +11 -2
- package/modules/coloraxis.js +24 -24
- package/modules/coloraxis.js.map +1 -1
- package/modules/coloraxis.src.js +33 -7
- package/modules/current-date-indicator.js +5 -4
- package/modules/current-date-indicator.js.map +1 -1
- package/modules/current-date-indicator.src.js +11 -2
- package/modules/cylinder.js +11 -11
- package/modules/cylinder.js.map +1 -1
- package/modules/cylinder.src.js +11 -2
- package/modules/data.js +34 -33
- package/modules/data.js.map +1 -1
- package/modules/data.src.js +59 -32
- package/modules/datagrouping.js +21 -20
- package/modules/datagrouping.js.map +1 -1
- package/modules/datagrouping.src.js +19 -5
- package/modules/debugger.js +8 -7
- package/modules/debugger.js.map +1 -1
- package/modules/debugger.src.js +15 -2
- package/modules/dependency-wheel.js +12 -11
- package/modules/dependency-wheel.js.map +1 -1
- package/modules/dependency-wheel.src.js +14 -5
- package/modules/dotplot.js +6 -6
- package/modules/dotplot.js.map +1 -1
- package/modules/dotplot.src.js +11 -2
- package/modules/drag-panes.js +10 -10
- package/modules/drag-panes.js.map +1 -1
- package/modules/drag-panes.src.js +11 -2
- package/modules/draggable-points.js +35 -34
- package/modules/draggable-points.js.map +1 -1
- package/modules/draggable-points.src.js +20 -9
- package/modules/drilldown.d.ts +19 -0
- package/modules/drilldown.js +36 -25
- package/modules/drilldown.js.map +1 -1
- package/modules/drilldown.src.d.ts +19 -0
- package/modules/drilldown.src.js +1091 -106
- package/modules/dumbbell.js +17 -17
- package/modules/dumbbell.js.map +1 -1
- package/modules/dumbbell.src.js +11 -2
- package/modules/export-data.js +21 -20
- package/modules/export-data.js.map +1 -1
- package/modules/export-data.src.js +12 -4
- package/modules/exporting.js +39 -39
- package/modules/exporting.js.map +1 -1
- package/modules/exporting.src.js +227 -92
- package/modules/full-screen.js +8 -7
- package/modules/full-screen.js.map +1 -1
- package/modules/full-screen.src.js +135 -58
- package/modules/funnel.js +12 -12
- package/modules/funnel.js.map +1 -1
- package/modules/funnel.src.js +11 -2
- package/modules/funnel3d.js +21 -21
- package/modules/funnel3d.js.map +1 -1
- package/modules/funnel3d.src.js +11 -2
- package/modules/gantt.js +216 -215
- package/modules/gantt.js.map +1 -1
- package/modules/gantt.src.js +60 -28
- package/modules/grid-axis.js +23 -23
- package/modules/grid-axis.js.map +1 -1
- package/modules/grid-axis.src.js +27 -13
- package/modules/heatmap.js +40 -39
- package/modules/heatmap.js.map +1 -1
- package/modules/heatmap.src.js +46 -27
- package/modules/heikinashi.js +8 -8
- package/modules/heikinashi.js.map +1 -1
- package/modules/heikinashi.src.js +11 -2
- package/modules/histogram-bellcurve.js +13 -13
- package/modules/histogram-bellcurve.js.map +1 -1
- package/modules/histogram-bellcurve.src.js +11 -2
- package/modules/hollowcandlestick.js +9 -9
- package/modules/hollowcandlestick.js.map +1 -1
- package/modules/hollowcandlestick.src.js +11 -2
- package/modules/item-series.js +12 -12
- package/modules/item-series.js.map +1 -1
- package/modules/item-series.src.js +11 -2
- package/modules/lollipop.js +7 -7
- package/modules/lollipop.js.map +1 -1
- package/modules/lollipop.src.js +12 -3
- package/modules/map.d.ts +80 -43
- package/modules/map.js +169 -144
- package/modules/map.js.map +1 -1
- package/modules/map.src.d.ts +80 -43
- package/modules/map.src.js +8024 -6696
- package/modules/marker-clusters.js +36 -36
- package/modules/marker-clusters.js.map +1 -1
- package/modules/marker-clusters.src.js +47 -23
- package/modules/networkgraph.d.ts +5 -0
- package/modules/networkgraph.js +49 -48
- package/modules/networkgraph.js.map +1 -1
- package/modules/networkgraph.src.d.ts +5 -0
- package/modules/networkgraph.src.js +77 -15
- package/modules/no-data-to-display.js +5 -5
- package/modules/no-data-to-display.js.map +1 -1
- package/modules/no-data-to-display.src.js +11 -2
- package/modules/offline-exporting.js +20 -18
- package/modules/offline-exporting.js.map +1 -1
- package/modules/offline-exporting.src.js +126 -25
- package/modules/oldie-polyfills.js +7 -7
- package/modules/oldie-polyfills.js.map +1 -1
- package/modules/oldie-polyfills.src.js +11 -2
- package/modules/oldie.js +30 -30
- package/modules/oldie.js.map +1 -1
- package/modules/oldie.src.js +12 -3
- package/modules/organization.js +16 -14
- package/modules/organization.js.map +1 -1
- package/modules/organization.src.js +166 -32
- package/modules/overlapping-datalabels.js +3 -2
- package/modules/overlapping-datalabels.js.map +1 -1
- package/modules/overlapping-datalabels.src.js +11 -2
- package/modules/parallel-coordinates.js +11 -11
- package/modules/parallel-coordinates.js.map +1 -1
- package/modules/parallel-coordinates.src.js +11 -2
- package/modules/pareto.js +7 -7
- package/modules/pareto.js.map +1 -1
- package/modules/pareto.src.js +11 -2
- package/modules/pathfinder.js +31 -31
- package/modules/pathfinder.js.map +1 -1
- package/modules/pathfinder.src.js +11 -2
- package/modules/pattern-fill.js +14 -14
- package/modules/pattern-fill.js.map +1 -1
- package/modules/pattern-fill.src.js +11 -2
- package/modules/price-indicator.js +5 -5
- package/modules/price-indicator.js.map +1 -1
- package/modules/price-indicator.src.js +11 -2
- package/modules/pyramid3d.js +4 -4
- package/modules/pyramid3d.js.map +1 -1
- package/modules/pyramid3d.src.js +11 -2
- package/modules/sankey.d.ts +5 -0
- package/modules/sankey.js +32 -29
- package/modules/sankey.js.map +1 -1
- package/modules/sankey.src.d.ts +5 -0
- package/modules/sankey.src.js +341 -157
- package/modules/series-label.js +18 -17
- package/modules/series-label.js.map +1 -1
- package/modules/series-label.src.js +11 -2
- package/modules/solid-gauge.js +10 -10
- package/modules/solid-gauge.js.map +1 -1
- package/modules/solid-gauge.src.js +11 -2
- package/modules/sonification.js +59 -59
- package/modules/sonification.js.map +1 -1
- package/modules/sonification.src.js +11 -2
- package/modules/static-scale.js +5 -4
- package/modules/static-scale.js.map +1 -1
- package/modules/static-scale.src.js +11 -2
- package/modules/stock-tools.js +145 -145
- package/modules/stock-tools.js.map +1 -1
- package/modules/stock-tools.src.js +64 -32
- package/modules/stock.js +204 -204
- package/modules/stock.js.map +1 -1
- package/modules/stock.src.js +62 -34
- package/modules/streamgraph.js +5 -4
- package/modules/streamgraph.js.map +1 -1
- package/modules/streamgraph.src.js +11 -2
- package/modules/sunburst.d.ts +3 -0
- package/modules/sunburst.js +73 -60
- package/modules/sunburst.js.map +1 -1
- package/modules/sunburst.src.d.ts +3 -0
- package/modules/sunburst.src.js +1048 -97
- package/modules/tilemap.js +17 -17
- package/modules/tilemap.js.map +1 -1
- package/modules/tilemap.src.js +11 -2
- package/modules/timeline.js +18 -18
- package/modules/timeline.js.map +1 -1
- package/modules/timeline.src.js +11 -2
- package/modules/treegrid.js +57 -56
- package/modules/treegrid.js.map +1 -1
- package/modules/treegrid.src.js +38 -13
- package/modules/treemap.d.ts +3 -0
- package/modules/treemap.js +53 -41
- package/modules/treemap.js.map +1 -1
- package/modules/treemap.src.d.ts +3 -0
- package/modules/treemap.src.js +1037 -95
- package/modules/variable-pie.js +9 -9
- package/modules/variable-pie.js.map +1 -1
- package/modules/variable-pie.src.js +11 -2
- package/modules/variwide.js +12 -12
- package/modules/variwide.js.map +1 -1
- package/modules/variwide.src.js +11 -2
- package/modules/vector.js +8 -7
- package/modules/vector.js.map +1 -1
- package/modules/vector.src.js +11 -2
- package/modules/venn.js +31 -31
- package/modules/venn.js.map +1 -1
- package/modules/venn.src.js +18 -6
- package/modules/windbarb.js +15 -15
- package/modules/windbarb.js.map +1 -1
- package/modules/windbarb.src.js +11 -2
- package/modules/wordcloud.js +24 -23
- package/modules/wordcloud.js.map +1 -1
- package/modules/wordcloud.src.js +22 -10
- package/modules/xrange.js +16 -16
- package/modules/xrange.js.map +1 -1
- package/modules/xrange.src.js +11 -2
- package/package.json +1 -1
- package/themes/avocado.js +4 -3
- package/themes/avocado.js.map +1 -1
- package/themes/avocado.src.js +11 -2
- package/themes/brand-dark.js +9 -8
- package/themes/brand-dark.js.map +1 -1
- package/themes/brand-dark.src.js +11 -2
- package/themes/brand-light.js +8 -8
- package/themes/brand-light.js.map +1 -1
- package/themes/brand-light.src.js +11 -2
- package/themes/dark-blue.js +9 -8
- package/themes/dark-blue.js.map +1 -1
- package/themes/dark-blue.src.js +11 -2
- package/themes/dark-green.js +9 -8
- package/themes/dark-green.js.map +1 -1
- package/themes/dark-green.src.js +11 -2
- package/themes/dark-unica.js +8 -7
- package/themes/dark-unica.js.map +1 -1
- package/themes/dark-unica.src.js +11 -2
- package/themes/gray.js +9 -8
- package/themes/gray.js.map +1 -1
- package/themes/gray.src.js +11 -2
- package/themes/grid-light.js +5 -4
- package/themes/grid-light.js.map +1 -1
- package/themes/grid-light.src.js +11 -2
- package/themes/grid.js +5 -5
- package/themes/grid.js.map +1 -1
- package/themes/grid.src.js +11 -2
- package/themes/high-contrast-dark.js +7 -7
- package/themes/high-contrast-dark.js.map +1 -1
- package/themes/high-contrast-dark.src.js +21 -12
- package/themes/high-contrast-light.js +3 -3
- package/themes/high-contrast-light.js.map +1 -1
- package/themes/high-contrast-light.src.js +21 -12
- package/themes/sand-signika.js +5 -5
- package/themes/sand-signika.js.map +1 -1
- package/themes/sand-signika.src.js +11 -2
- package/themes/skies.js +5 -5
- package/themes/skies.js.map +1 -1
- package/themes/skies.src.js +11 -2
- package/themes/sunset.js +3 -3
- package/themes/sunset.js.map +1 -1
- package/themes/sunset.src.js +11 -2
- package/es-modules/Maps/ProjectionDefinition.js +0 -9
package/highstock.src.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Highstock JS
|
|
2
|
+
* @license Highstock JS v10.1.0 (2022-04-29)
|
|
3
3
|
*
|
|
4
4
|
* (c) 2009-2021 Torstein Honsi
|
|
5
5
|
*
|
|
6
6
|
* License: www.highcharts.com/license
|
|
7
7
|
*/
|
|
8
|
-
'use strict';
|
|
9
8
|
(function (root, factory) {
|
|
10
9
|
if (typeof module === 'object' && module.exports) {
|
|
11
10
|
factory['default'] = factory;
|
|
@@ -22,11 +21,21 @@
|
|
|
22
21
|
}
|
|
23
22
|
root.Highcharts = factory(root);
|
|
24
23
|
}
|
|
25
|
-
}(typeof window !== 'undefined' ? window : this, function (
|
|
24
|
+
}(typeof window !== 'undefined' ? window : this, function (window) {
|
|
25
|
+
'use strict';
|
|
26
26
|
var _modules = {};
|
|
27
27
|
function _registerModule(obj, path, args, fn) {
|
|
28
28
|
if (!obj.hasOwnProperty(path)) {
|
|
29
29
|
obj[path] = fn.apply(null, args);
|
|
30
|
+
|
|
31
|
+
if (typeof CustomEvent === 'function') {
|
|
32
|
+
window.dispatchEvent(
|
|
33
|
+
new CustomEvent(
|
|
34
|
+
'HighchartsModuleLoaded',
|
|
35
|
+
{ detail: { path: path, module: obj[path] }
|
|
36
|
+
})
|
|
37
|
+
);
|
|
38
|
+
}
|
|
30
39
|
}
|
|
31
40
|
}
|
|
32
41
|
_registerModule(_modules, 'Core/Globals.js', [], function () {
|
|
@@ -39,23 +48,6 @@
|
|
|
39
48
|
* !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
|
|
40
49
|
*
|
|
41
50
|
* */
|
|
42
|
-
/* *
|
|
43
|
-
*
|
|
44
|
-
* Constants
|
|
45
|
-
*
|
|
46
|
-
* */
|
|
47
|
-
/**
|
|
48
|
-
* @private
|
|
49
|
-
* @deprecated
|
|
50
|
-
* @todo Rename UMD argument `win` to `window`; move code to `Globals.win`
|
|
51
|
-
*/
|
|
52
|
-
var w = (typeof win !== 'undefined' ?
|
|
53
|
-
win :
|
|
54
|
-
typeof window !== 'undefined' ?
|
|
55
|
-
window :
|
|
56
|
-
{}
|
|
57
|
-
// eslint-disable-next-line node/no-unsupported-features/es-builtins
|
|
58
|
-
);
|
|
59
51
|
/* *
|
|
60
52
|
*
|
|
61
53
|
* Namespace
|
|
@@ -71,7 +63,10 @@
|
|
|
71
63
|
* Constants
|
|
72
64
|
*
|
|
73
65
|
* */
|
|
74
|
-
Globals.SVG_NS = 'http://www.w3.org/2000/svg', Globals.product = 'Highcharts', Globals.version = '
|
|
66
|
+
Globals.SVG_NS = 'http://www.w3.org/2000/svg', Globals.product = 'Highcharts', Globals.version = '10.1.0', Globals.win = (typeof window !== 'undefined' ?
|
|
67
|
+
window :
|
|
68
|
+
{}), // eslint-disable-line node/no-unsupported-features/es-builtins
|
|
69
|
+
Globals.doc = Globals.win.document, Globals.svg = (Globals.doc &&
|
|
75
70
|
Globals.doc.createElementNS &&
|
|
76
71
|
!!Globals.doc.createElementNS(Globals.SVG_NS, 'svg').createSVGRect), Globals.userAgent = (Globals.win.navigator && Globals.win.navigator.userAgent) || '', Globals.isChrome = Globals.userAgent.indexOf('Chrome') !== -1, Globals.isFirefox = Globals.userAgent.indexOf('Firefox') !== -1, Globals.isMS = /(edge|msie|trident)/i.test(Globals.userAgent) && !Globals.win.opera, Globals.isSafari = !Globals.isChrome && Globals.userAgent.indexOf('Safari') !== -1, Globals.isTouchDevice = /(Mobile|Android|Windows Phone)/.test(Globals.userAgent), Globals.isWebKit = Globals.userAgent.indexOf('AppleWebKit') !== -1, Globals.deg2rad = Math.PI * 2 / 360, Globals.hasBidiBug = (Globals.isFirefox &&
|
|
77
72
|
parseInt(Globals.userAgent.split('Firefox/')[1], 10) < 4 // issue #38
|
|
@@ -365,7 +360,9 @@
|
|
|
365
360
|
// Arrays, primitives and DOM nodes are copied directly
|
|
366
361
|
}
|
|
367
362
|
else if (isObject(newer[key]) ||
|
|
368
|
-
newer[key] !== older[key]
|
|
363
|
+
newer[key] !== older[key] ||
|
|
364
|
+
// If the newer key is explicitly undefined, keep it (#10525)
|
|
365
|
+
(key in newer && !(key in older))) {
|
|
369
366
|
result[key] = newer[key];
|
|
370
367
|
}
|
|
371
368
|
});
|
|
@@ -533,7 +530,7 @@
|
|
|
533
530
|
* @param {Highcharts.HTMLDOMElement|Highcharts.SVGDOMElement} elem
|
|
534
531
|
* The DOM element to receive the attribute(s).
|
|
535
532
|
*
|
|
536
|
-
* @param {string|Highcharts.HTMLAttributes|Highcharts.SVGAttributes} [
|
|
533
|
+
* @param {string|Highcharts.HTMLAttributes|Highcharts.SVGAttributes} [keyOrAttribs]
|
|
537
534
|
* The property or an object of key-value pairs.
|
|
538
535
|
*
|
|
539
536
|
* @param {number|string} [value]
|
|
@@ -542,33 +539,36 @@
|
|
|
542
539
|
* @return {string|null|undefined}
|
|
543
540
|
* When used as a getter, return the value.
|
|
544
541
|
*/
|
|
545
|
-
function attr(elem,
|
|
542
|
+
function attr(elem, keyOrAttribs, value) {
|
|
543
|
+
var isGetter = isString(keyOrAttribs) && !defined(value);
|
|
546
544
|
var ret;
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
545
|
+
var attrSingle = function (value,
|
|
546
|
+
key) {
|
|
547
|
+
// Set the value
|
|
548
|
+
if (defined(value)) {
|
|
549
|
+
elem.setAttribute(key,
|
|
550
|
+
value);
|
|
551
|
+
// Get the value
|
|
552
|
+
}
|
|
553
|
+
else if (isGetter) {
|
|
554
|
+
ret = elem.getAttribute(key);
|
|
556
555
|
// IE7 and below cannot get class through getAttribute (#7850)
|
|
557
|
-
if (!ret &&
|
|
558
|
-
ret = elem.getAttribute(
|
|
556
|
+
if (!ret && key === 'class') {
|
|
557
|
+
ret = elem.getAttribute(key + 'Name');
|
|
559
558
|
}
|
|
559
|
+
// Remove the value
|
|
560
560
|
}
|
|
561
|
-
|
|
561
|
+
else {
|
|
562
|
+
elem.removeAttribute(key);
|
|
563
|
+
}
|
|
564
|
+
};
|
|
565
|
+
// If keyOrAttribs is a string
|
|
566
|
+
if (isString(keyOrAttribs)) {
|
|
567
|
+
attrSingle(value, keyOrAttribs);
|
|
568
|
+
// Else if keyOrAttribs is defined, it is a hash of key/value pairs
|
|
562
569
|
}
|
|
563
570
|
else {
|
|
564
|
-
objectEach(
|
|
565
|
-
if (defined(val)) {
|
|
566
|
-
elem.setAttribute(key, val);
|
|
567
|
-
}
|
|
568
|
-
else {
|
|
569
|
-
elem.removeAttribute(key);
|
|
570
|
-
}
|
|
571
|
-
});
|
|
571
|
+
objectEach(keyOrAttribs, attrSingle);
|
|
572
572
|
}
|
|
573
573
|
return ret;
|
|
574
574
|
}
|
|
@@ -619,10 +619,8 @@
|
|
|
619
619
|
*
|
|
620
620
|
* @function Highcharts.clearTimeout
|
|
621
621
|
*
|
|
622
|
-
* @param {number} id
|
|
623
|
-
*
|
|
624
|
-
*
|
|
625
|
-
* @return {void}
|
|
622
|
+
* @param {number|undefined} id
|
|
623
|
+
* Id of a timeout.
|
|
626
624
|
*/
|
|
627
625
|
function internalClearTimeout(id) {
|
|
628
626
|
if (defined(id)) {
|
|
@@ -692,9 +690,8 @@
|
|
|
692
690
|
*/
|
|
693
691
|
function css(el, styles) {
|
|
694
692
|
if (H.isMS && !H.svg) { // #2686
|
|
695
|
-
if (styles &&
|
|
696
|
-
styles.filter =
|
|
697
|
-
'alpha(opacity=' + (styles.opacity * 100) + ')';
|
|
693
|
+
if (styles && defined(styles.opacity)) {
|
|
694
|
+
styles.filter = "alpha(opacity=" + styles.opacity * 100 + ")";
|
|
698
695
|
}
|
|
699
696
|
}
|
|
700
697
|
extend(el.style, styles);
|
|
@@ -887,7 +884,7 @@
|
|
|
887
884
|
var i,
|
|
888
885
|
retInterval = interval;
|
|
889
886
|
// round to a tenfold of 1, 2, 2.5 or 5
|
|
890
|
-
magnitude = pick(magnitude,
|
|
887
|
+
magnitude = pick(magnitude, getMagnitude(interval));
|
|
891
888
|
var normalized = interval / magnitude;
|
|
892
889
|
// multiples for a linear scale
|
|
893
890
|
if (!multiples) {
|
|
@@ -2173,19 +2170,22 @@
|
|
|
2173
2170
|
*/
|
|
2174
2171
|
var ChartDefaults = {
|
|
2175
2172
|
/**
|
|
2176
|
-
* Default `mapData` for all series
|
|
2177
|
-
|
|
2178
|
-
*
|
|
2179
|
-
|
|
2173
|
+
* Default `mapData` for all series,
|
|
2174
|
+
in terms of a GeoJSON or TopoJSON
|
|
2175
|
+
* object. If set to a string,
|
|
2176
|
+
it functions as an index into the
|
|
2177
|
+
* `Highcharts.maps` array.
|
|
2180
2178
|
*
|
|
2181
|
-
*
|
|
2179
|
+
* For picking out individual shapes and geometries to use for each series
|
|
2180
|
+
* of the map,
|
|
2181
|
+
see [series.mapData](#series.map.mapData).
|
|
2182
2182
|
*
|
|
2183
2183
|
* @sample maps/demo/geojson
|
|
2184
|
-
* Loading
|
|
2184
|
+
* Loading GeoJSON data
|
|
2185
2185
|
* @sample maps/chart/topojson
|
|
2186
|
-
* Loading
|
|
2186
|
+
* Loading TopoJSON data
|
|
2187
2187
|
*
|
|
2188
|
-
* @type {string|Array<*>|Highcharts.GeoJSON}
|
|
2188
|
+
* @type {string|Array<*>|Highcharts.GeoJSON|Highcharts.TopoJSON}
|
|
2189
2189
|
* @since 5.0.0
|
|
2190
2190
|
* @product highmaps
|
|
2191
2191
|
* @apioption chart.map
|
|
@@ -2200,7 +2200,7 @@
|
|
|
2200
2200
|
* @apioption chart.mapTransforms
|
|
2201
2201
|
*/
|
|
2202
2202
|
/**
|
|
2203
|
-
* When using multiple
|
|
2203
|
+
* When using multiple axes,
|
|
2204
2204
|
the ticks of two or more opposite axes
|
|
2205
2205
|
* will automatically be aligned by adding ticks to the axis or axes
|
|
2206
2206
|
* with the least ticks,
|
|
@@ -2211,8 +2211,8 @@
|
|
|
2211
2211
|
it's a good idea to hide them for the secondary
|
|
2212
2212
|
* axis by setting `gridLineWidth` to 0.
|
|
2213
2213
|
*
|
|
2214
|
-
* If `startOnTick` or `endOnTick` in
|
|
2215
|
-
* then the `alignTicks ` will be disabled for the
|
|
2214
|
+
* If `startOnTick` or `endOnTick` in the axis options are set to false,
|
|
2215
|
+
* then the `alignTicks ` will be disabled for the axis.
|
|
2216
2216
|
*
|
|
2217
2217
|
* Disabled for logarithmic axes.
|
|
2218
2218
|
*
|
|
@@ -2230,6 +2230,31 @@
|
|
|
2230
2230
|
* @product highcharts highstock gantt
|
|
2231
2231
|
* @apioption chart.alignTicks
|
|
2232
2232
|
*/
|
|
2233
|
+
/**
|
|
2234
|
+
* When using multiple axes,
|
|
2235
|
+
align the thresholds. When this is true,
|
|
2236
|
+
other
|
|
2237
|
+
* ticks will also be aligned.
|
|
2238
|
+
*
|
|
2239
|
+
* Note that for line series and some other series types,
|
|
2240
|
+
the `threshold`
|
|
2241
|
+
* option is set to `null` by default. This will in turn cause their y-axis
|
|
2242
|
+
* to not have a threshold. In order to avoid that,
|
|
2243
|
+
set the series
|
|
2244
|
+
* `threshold` to 0 or another number.
|
|
2245
|
+
*
|
|
2246
|
+
* If `startOnTick` or `endOnTick` in the axis options are set to false,
|
|
2247
|
+
or
|
|
2248
|
+
* if the axis is logarithmic,
|
|
2249
|
+
the threshold will not be aligned.
|
|
2250
|
+
*
|
|
2251
|
+
* @sample {highcharts} highcharts/chart/alignthresholds/ Set to true
|
|
2252
|
+
*
|
|
2253
|
+
* @since 10.0.0
|
|
2254
|
+
* @product highcharts highstock gantt
|
|
2255
|
+
* @apioption chart.alignThresholds
|
|
2256
|
+
*/
|
|
2257
|
+
alignThresholds: false,
|
|
2233
2258
|
/**
|
|
2234
2259
|
* Set the overall animation for all chart updating. Animation can be
|
|
2235
2260
|
* disabled throughout the chart by setting it to false here. It can
|
|
@@ -2654,6 +2679,17 @@
|
|
|
2654
2679
|
* @since 5.0.0
|
|
2655
2680
|
*/
|
|
2656
2681
|
colorCount: 10,
|
|
2682
|
+
/**
|
|
2683
|
+
* By default, (because of memory and performance reasons) the chart does
|
|
2684
|
+
* not copy the data but keeps it as a reference. In some cases, this might
|
|
2685
|
+
* result in mutating the original data source. In order to prevent that,
|
|
2686
|
+
* set that property to false. Please note that changing that might decrease
|
|
2687
|
+
* performance, especially with bigger sets of data.
|
|
2688
|
+
*
|
|
2689
|
+
* @type {boolean}
|
|
2690
|
+
* @since 10.1.0
|
|
2691
|
+
*/
|
|
2692
|
+
allowMutatingData: true,
|
|
2657
2693
|
/**
|
|
2658
2694
|
* Alias of `type`.
|
|
2659
2695
|
*
|
|
@@ -3066,9 +3102,10 @@
|
|
|
3066
3102
|
* Y
|
|
3067
3103
|
* @sample {highstock} stock/chart/zoomtype-xy/
|
|
3068
3104
|
* Xy
|
|
3105
|
+
* @sample {highmaps} maps/chart/zoomtype-xy/
|
|
3106
|
+
* Map with selection zoom
|
|
3069
3107
|
*
|
|
3070
3108
|
* @type {string}
|
|
3071
|
-
* @product highcharts highstock gantt
|
|
3072
3109
|
* @validvalue ["x", "y", "xy"]
|
|
3073
3110
|
* @apioption chart.zoomType
|
|
3074
3111
|
*/
|
|
@@ -6376,18 +6413,20 @@
|
|
|
6376
6413
|
* @apioption tooltip.pointFormatter
|
|
6377
6414
|
*/
|
|
6378
6415
|
/**
|
|
6379
|
-
* A callback function to place the tooltip in a
|
|
6416
|
+
* A callback function to place the tooltip in a custom position. The
|
|
6380
6417
|
* callback receives three parameters: `labelWidth`, `labelHeight` and
|
|
6381
6418
|
* `point`, where point contains values for `plotX` and `plotY` telling
|
|
6382
6419
|
* where the reference point is in the plot area. Add `chart.plotLeft`
|
|
6383
6420
|
* and `chart.plotTop` to get the full coordinates.
|
|
6384
6421
|
*
|
|
6422
|
+
* To find the actual hovered `Point` instance, use
|
|
6423
|
+
* `this.chart.hoverPoint`. For shared or split tooltips, all the hover
|
|
6424
|
+
* points are available in `this.chart.hoverPoints`.
|
|
6425
|
+
*
|
|
6385
6426
|
* Since v7, when [tooltip.split](#tooltip.split) option is enabled,
|
|
6386
6427
|
* positioner is called for each of the boxes separately, including
|
|
6387
6428
|
* xAxis header. xAxis header is not a point, instead `point` argument
|
|
6388
|
-
* contains info:
|
|
6389
|
-
* `{ plotX: Number, plotY: Number, isHeader: Boolean }`
|
|
6390
|
-
*
|
|
6429
|
+
* contains info: `{ plotX: Number, plotY: Number, isHeader: Boolean }`
|
|
6391
6430
|
*
|
|
6392
6431
|
* The return should be an object containing x and y values, for example
|
|
6393
6432
|
* `{ x: 100, y: 100 }`.
|
|
@@ -6730,6 +6769,8 @@
|
|
|
6730
6769
|
*
|
|
6731
6770
|
* @sample {highcharts} highcharts/tooltip/pointformat/
|
|
6732
6771
|
* A different point format with value suffix
|
|
6772
|
+
* @sample {highcharts|highstock} highcharts/tooltip/pointformat-extra-information/
|
|
6773
|
+
* Show extra information about points in the tooltip
|
|
6733
6774
|
* @sample {highmaps} maps/tooltip/format/
|
|
6734
6775
|
* Format demo
|
|
6735
6776
|
*
|
|
@@ -7841,6 +7882,7 @@
|
|
|
7841
7882
|
win = H.win;
|
|
7842
7883
|
var attr = U.attr,
|
|
7843
7884
|
createElement = U.createElement,
|
|
7885
|
+
css = U.css,
|
|
7844
7886
|
error = U.error,
|
|
7845
7887
|
isFunction = U.isFunction,
|
|
7846
7888
|
isString = U.isString,
|
|
@@ -7925,12 +7967,26 @@
|
|
|
7925
7967
|
valid = isString(val) && AST.allowedReferences.some(function (ref) { return val.indexOf(ref) === 0; });
|
|
7926
7968
|
}
|
|
7927
7969
|
if (!valid) {
|
|
7928
|
-
error(
|
|
7970
|
+
error(33, false, void 0, {
|
|
7971
|
+
'Invalid attribute in config': "" + key
|
|
7972
|
+
});
|
|
7929
7973
|
delete attributes[key];
|
|
7930
7974
|
}
|
|
7931
7975
|
});
|
|
7932
7976
|
return attributes;
|
|
7933
7977
|
};
|
|
7978
|
+
AST.parseStyle = function (style) {
|
|
7979
|
+
return style
|
|
7980
|
+
.split(';')
|
|
7981
|
+
.reduce(function (styles, line) {
|
|
7982
|
+
var pair = line.split(':').map(function (s) { return s.trim(); }),
|
|
7983
|
+
key = pair.shift();
|
|
7984
|
+
if (key && pair.length) {
|
|
7985
|
+
styles[key.replace(/-([a-z])/g, function (g) { return g[1].toUpperCase(); })] = pair.join(':'); // #17146
|
|
7986
|
+
}
|
|
7987
|
+
return styles;
|
|
7988
|
+
}, {});
|
|
7989
|
+
};
|
|
7934
7990
|
/**
|
|
7935
7991
|
* Utility function to set html content for an element by passing in a
|
|
7936
7992
|
* markup string. The markup is safely parsed by the AST class to avoid
|
|
@@ -7986,12 +8042,15 @@
|
|
|
7986
8042
|
var textNode = item.textContent ?
|
|
7987
8043
|
H.doc.createTextNode(item.textContent) :
|
|
7988
8044
|
void 0;
|
|
8045
|
+
// Whether to ignore the AST filtering totally, #15345
|
|
8046
|
+
var bypassHTMLFiltering = AST.bypassHTMLFiltering;
|
|
7989
8047
|
var node;
|
|
7990
8048
|
if (tagName) {
|
|
7991
8049
|
if (tagName === '#text') {
|
|
7992
8050
|
node = textNode;
|
|
7993
8051
|
}
|
|
7994
|
-
else if (AST.allowedTags.indexOf(tagName) !== -1
|
|
8052
|
+
else if (AST.allowedTags.indexOf(tagName) !== -1 ||
|
|
8053
|
+
bypassHTMLFiltering) {
|
|
7995
8054
|
var NS = tagName === 'svg' ?
|
|
7996
8055
|
SVG_NS :
|
|
7997
8056
|
(subParent.namespaceURI || SVG_NS);
|
|
@@ -8004,11 +8063,17 @@
|
|
|
8004
8063
|
if (key !== 'tagName' &&
|
|
8005
8064
|
key !== 'attributes' &&
|
|
8006
8065
|
key !== 'children' &&
|
|
8066
|
+
key !== 'style' &&
|
|
8007
8067
|
key !== 'textContent') {
|
|
8008
8068
|
attributes_1[key] = val;
|
|
8009
8069
|
}
|
|
8010
8070
|
});
|
|
8011
|
-
attr(element,
|
|
8071
|
+
attr(element, bypassHTMLFiltering ?
|
|
8072
|
+
attributes_1 :
|
|
8073
|
+
AST.filterUserAttributes(attributes_1));
|
|
8074
|
+
if (item.style) {
|
|
8075
|
+
css(element, item.style);
|
|
8076
|
+
}
|
|
8012
8077
|
// Add text content
|
|
8013
8078
|
if (textNode) {
|
|
8014
8079
|
element.appendChild(textNode);
|
|
@@ -8018,8 +8083,9 @@
|
|
|
8018
8083
|
node = element;
|
|
8019
8084
|
}
|
|
8020
8085
|
else {
|
|
8021
|
-
error(
|
|
8022
|
-
tagName
|
|
8086
|
+
error(33, false, void 0, {
|
|
8087
|
+
'Invalid tagName in config': tagName
|
|
8088
|
+
});
|
|
8023
8089
|
}
|
|
8024
8090
|
}
|
|
8025
8091
|
// Add to the tree
|
|
@@ -8047,7 +8113,11 @@
|
|
|
8047
8113
|
*/
|
|
8048
8114
|
AST.prototype.parseMarkup = function (markup) {
|
|
8049
8115
|
var nodes = [];
|
|
8050
|
-
markup = markup
|
|
8116
|
+
markup = markup
|
|
8117
|
+
.trim()
|
|
8118
|
+
// The style attribute throws a warning when parsing when CSP is
|
|
8119
|
+
// enabled (#6884), so use an alias and pick it up below
|
|
8120
|
+
.replace(/ style="/g, ' data-style="');
|
|
8051
8121
|
var doc;
|
|
8052
8122
|
if (hasValidDOMParser) {
|
|
8053
8123
|
doc = new DOMParser().parseFromString(trustedTypesPolicy ?
|
|
@@ -8074,7 +8144,12 @@
|
|
|
8074
8144
|
if (parsedAttributes) {
|
|
8075
8145
|
var attributes_2 = {};
|
|
8076
8146
|
[].forEach.call(parsedAttributes, function (attrib) {
|
|
8077
|
-
|
|
8147
|
+
if (attrib.name === 'data-style') {
|
|
8148
|
+
astNode.style = AST.parseStyle(attrib.value);
|
|
8149
|
+
}
|
|
8150
|
+
else {
|
|
8151
|
+
attributes_2[attrib.name] = attrib.value;
|
|
8152
|
+
}
|
|
8078
8153
|
});
|
|
8079
8154
|
astNode.attributes = attributes_2;
|
|
8080
8155
|
}
|
|
@@ -8278,6 +8353,34 @@
|
|
|
8278
8353
|
'#text'
|
|
8279
8354
|
];
|
|
8280
8355
|
AST.emptyHTML = emptyHTML;
|
|
8356
|
+
/**
|
|
8357
|
+
* Allow all custom SVG and HTML attributes, references and tags (together
|
|
8358
|
+
* with potentially harmful ones) to be added to the DOM from the chart
|
|
8359
|
+
* configuration. In other words, disable the the allow-listing which is the
|
|
8360
|
+
* primary functionality of the AST.
|
|
8361
|
+
*
|
|
8362
|
+
* WARNING: Setting this property to `true` while allowing untrusted user
|
|
8363
|
+
* data in the chart configuration will expose your application to XSS
|
|
8364
|
+
* security risks!
|
|
8365
|
+
*
|
|
8366
|
+
* Note that in case you want to allow a known set of tags or attributes,
|
|
8367
|
+
* you should allow-list them instead of disabling the filtering totally.
|
|
8368
|
+
* See [allowedAttributes](Highcharts.AST#.allowedAttributes),
|
|
8369
|
+
* [allowedReferences](Highcharts.AST#.allowedReferences) and
|
|
8370
|
+
* [allowedTags](Highcharts.AST#.allowedTags). The `bypassHTMLFiltering`
|
|
8371
|
+
* setting is intended only for those cases where allow-listing is not
|
|
8372
|
+
* practical, and the chart configuration already comes from a secure
|
|
8373
|
+
* source.
|
|
8374
|
+
*
|
|
8375
|
+
* @example
|
|
8376
|
+
* // Allow all custom attributes, references and tags (disable DOM XSS
|
|
8377
|
+
* // filtering)
|
|
8378
|
+
* Highcharts.AST.bypassHTMLFiltering = true;
|
|
8379
|
+
*
|
|
8380
|
+
* @name Highcharts.AST.bypassHTMLFiltering
|
|
8381
|
+
* @static
|
|
8382
|
+
*/
|
|
8383
|
+
AST.bypassHTMLFiltering = false;
|
|
8281
8384
|
return AST;
|
|
8282
8385
|
}());
|
|
8283
8386
|
/* *
|
|
@@ -9121,7 +9224,7 @@
|
|
|
9121
9224
|
}, deferTime);
|
|
9122
9225
|
}
|
|
9123
9226
|
else {
|
|
9124
|
-
this.attr(params, void 0, complete);
|
|
9227
|
+
this.attr(params, void 0, complete || animOptions.complete);
|
|
9125
9228
|
// Call the end step synchronously
|
|
9126
9229
|
objectEach(params, function (val, prop) {
|
|
9127
9230
|
if (animOptions.step) {
|
|
@@ -9519,25 +9622,20 @@
|
|
|
9519
9622
|
* Return the SVG element for chaining.
|
|
9520
9623
|
*/
|
|
9521
9624
|
SVGElement.prototype.css = function (styles) {
|
|
9522
|
-
var oldStyles = this.styles,
|
|
9523
|
-
|
|
9524
|
-
|
|
9525
|
-
// the DOM. In styled mode, no CSS should find its way to the DOM
|
|
9526
|
-
// whatsoever (#6173, #6474).
|
|
9527
|
-
svgPseudoProps = ['textOutline', 'textOverflow', 'width'];
|
|
9625
|
+
var oldStyles = this.styles,
|
|
9626
|
+
newStyles = {},
|
|
9627
|
+
elem = this.element;
|
|
9528
9628
|
var textWidth,
|
|
9529
|
-
serializedCss = '',
|
|
9530
|
-
hyphenate,
|
|
9531
9629
|
hasNew = !oldStyles;
|
|
9532
9630
|
// convert legacy
|
|
9533
|
-
if (styles
|
|
9631
|
+
if (styles.color) {
|
|
9534
9632
|
styles.fill = styles.color;
|
|
9535
9633
|
}
|
|
9536
9634
|
// Filter out existing styles to increase performance (#2640)
|
|
9537
9635
|
if (oldStyles) {
|
|
9538
|
-
objectEach(styles, function (
|
|
9539
|
-
if (oldStyles && oldStyles[n] !==
|
|
9540
|
-
newStyles[n] =
|
|
9636
|
+
objectEach(styles, function (value, n) {
|
|
9637
|
+
if (oldStyles && oldStyles[n] !== value) {
|
|
9638
|
+
newStyles[n] = value;
|
|
9541
9639
|
hasNew = true;
|
|
9542
9640
|
}
|
|
9543
9641
|
});
|
|
@@ -9548,41 +9646,30 @@
|
|
|
9548
9646
|
styles = extend(oldStyles, newStyles);
|
|
9549
9647
|
}
|
|
9550
9648
|
// Get the text width from style
|
|
9551
|
-
|
|
9552
|
-
|
|
9553
|
-
|
|
9554
|
-
|
|
9555
|
-
|
|
9556
|
-
|
|
9557
|
-
|
|
9558
|
-
|
|
9559
|
-
textWidth = this.textWidth = pInt(styles.width);
|
|
9560
|
-
}
|
|
9649
|
+
// Previously set, unset it (#8234)
|
|
9650
|
+
if (styles.width === null || styles.width === 'auto') {
|
|
9651
|
+
delete this.textWidth;
|
|
9652
|
+
// Apply new
|
|
9653
|
+
}
|
|
9654
|
+
else if (elem.nodeName.toLowerCase() === 'text' &&
|
|
9655
|
+
styles.width) {
|
|
9656
|
+
textWidth = this.textWidth = pInt(styles.width);
|
|
9561
9657
|
}
|
|
9562
9658
|
// store object
|
|
9563
9659
|
this.styles = styles;
|
|
9564
9660
|
if (textWidth && (!svg && this.renderer.forExport)) {
|
|
9565
9661
|
delete styles.width;
|
|
9566
9662
|
}
|
|
9567
|
-
|
|
9568
|
-
if (elem.namespaceURI === this.SVG_NS) {
|
|
9569
|
-
|
|
9570
|
-
|
|
9571
|
-
|
|
9572
|
-
|
|
9573
|
-
|
|
9574
|
-
|
|
9575
|
-
n.replace(/([A-Z])/g, hyphenate) + ':' +
|
|
9576
|
-
style + ';';
|
|
9577
|
-
}
|
|
9578
|
-
});
|
|
9579
|
-
if (serializedCss) {
|
|
9580
|
-
attr(elem, 'style', serializedCss); // #1881
|
|
9581
|
-
}
|
|
9582
|
-
}
|
|
9583
|
-
else {
|
|
9584
|
-
css(elem, styles);
|
|
9663
|
+
var stylesToApply_1 = merge(styles);
|
|
9664
|
+
if (elem.namespaceURI === this.SVG_NS) {
|
|
9665
|
+
// These CSS properties are interpreted internally by the SVG
|
|
9666
|
+
// renderer, but are not supported by SVG and should not be
|
|
9667
|
+
// added to the DOM. In styled mode, no CSS should find its way
|
|
9668
|
+
// to the DOM whatsoever (#6173, #6474).
|
|
9669
|
+
['textOutline', 'textOverflow', 'width'].forEach(function (key) { return (stylesToApply_1 &&
|
|
9670
|
+
delete stylesToApply_1[key]); });
|
|
9585
9671
|
}
|
|
9672
|
+
css(elem, stylesToApply_1);
|
|
9586
9673
|
if (this.added) {
|
|
9587
9674
|
// Rebuild text after added. Cache mechanisms in the buildText
|
|
9588
9675
|
// will prevent building if there are no significant changes.
|
|
@@ -9590,7 +9677,7 @@
|
|
|
9590
9677
|
this.renderer.buildText(this);
|
|
9591
9678
|
}
|
|
9592
9679
|
// Apply text outline after added
|
|
9593
|
-
if (styles
|
|
9680
|
+
if (styles.textOutline) {
|
|
9594
9681
|
this.applyTextOutline(styles.textOutline);
|
|
9595
9682
|
}
|
|
9596
9683
|
}
|
|
@@ -9846,8 +9933,9 @@
|
|
|
9846
9933
|
*/
|
|
9847
9934
|
SVGElement.prototype.getBBox = function (reload, rot) {
|
|
9848
9935
|
var wrapper = this,
|
|
9849
|
-
|
|
9936
|
+
alignValue = wrapper.alignValue,
|
|
9850
9937
|
element = wrapper.element,
|
|
9938
|
+
renderer = wrapper.renderer,
|
|
9851
9939
|
styles = wrapper.styles,
|
|
9852
9940
|
textStr = wrapper.textStr,
|
|
9853
9941
|
cache = renderer.cache,
|
|
@@ -9857,7 +9945,7 @@
|
|
|
9857
9945
|
wrapper.rotation, 0),
|
|
9858
9946
|
fontSize = renderer.styledMode ? (element &&
|
|
9859
9947
|
SVGElement.prototype.getStyle.call(element, 'font-size')) : (styles && styles.fontSize);
|
|
9860
|
-
var bBox,
|
|
9948
|
+
var bBox,
|
|
9861
9949
|
width,
|
|
9862
9950
|
height,
|
|
9863
9951
|
toggleTextShadowShim,
|
|
@@ -9878,6 +9966,7 @@
|
|
|
9878
9966
|
rotation,
|
|
9879
9967
|
fontSize,
|
|
9880
9968
|
wrapper.textWidth,
|
|
9969
|
+
alignValue,
|
|
9881
9970
|
styles && styles.textOverflow,
|
|
9882
9971
|
styles && styles.fontWeight // #12163
|
|
9883
9972
|
].join(',');
|
|
@@ -9923,7 +10012,7 @@
|
|
|
9923
10012
|
// other condition is for Opera that returns a width of
|
|
9924
10013
|
// -Infinity on hidden elements.
|
|
9925
10014
|
if (!bBox || bBox.width < 0) {
|
|
9926
|
-
bBox = { width: 0, height: 0 };
|
|
10015
|
+
bBox = { x: 0, y: 0, width: 0, height: 0 };
|
|
9927
10016
|
}
|
|
9928
10017
|
// VML Renderer or useHTML within SVG
|
|
9929
10018
|
}
|
|
@@ -9952,11 +10041,35 @@
|
|
|
9952
10041
|
}
|
|
9953
10042
|
// Adjust for rotated text
|
|
9954
10043
|
if (rotation) {
|
|
9955
|
-
var
|
|
9956
|
-
|
|
9957
|
-
|
|
9958
|
-
|
|
9959
|
-
|
|
10044
|
+
var baseline = Number(element.getAttribute('y') || 0) - bBox.y,
|
|
10045
|
+
alignFactor = {
|
|
10046
|
+
'right': 1,
|
|
10047
|
+
'center': 0.5
|
|
10048
|
+
}[alignValue || 0] || 0,
|
|
10049
|
+
rad = rotation * deg2rad,
|
|
10050
|
+
rad90 = (rotation - 90) * deg2rad,
|
|
10051
|
+
wCosRad = width * Math.cos(rad),
|
|
10052
|
+
wSinRad = width * Math.sin(rad),
|
|
10053
|
+
cosRad90 = Math.cos(rad90),
|
|
10054
|
+
sinRad90 = Math.sin(rad90),
|
|
10055
|
+
// Find the starting point on the left side baseline of
|
|
10056
|
+
// the text
|
|
10057
|
+
pX = bBox.x + alignFactor * (width - wCosRad),
|
|
10058
|
+
pY = bBox.y + baseline - alignFactor * wSinRad,
|
|
10059
|
+
// Find all corners
|
|
10060
|
+
aX = pX + baseline * cosRad90,
|
|
10061
|
+
bX = aX + wCosRad,
|
|
10062
|
+
cX = bX - height * cosRad90,
|
|
10063
|
+
dX = cX - wCosRad,
|
|
10064
|
+
aY = pY + baseline * sinRad90,
|
|
10065
|
+
bY = aY + wSinRad,
|
|
10066
|
+
cY = bY - height * sinRad90,
|
|
10067
|
+
dY = cY - wSinRad;
|
|
10068
|
+
// Deduct the bounding box from the corners
|
|
10069
|
+
bBox.x = Math.min(aX, bX, cX, dX);
|
|
10070
|
+
bBox.y = Math.min(aY, bY, cY, dY);
|
|
10071
|
+
bBox.width = Math.max(aX, bX, cX, dX) - bBox.x;
|
|
10072
|
+
bBox.height = Math.max(aY, bY, cY, dY) - bBox.y;
|
|
9960
10073
|
}
|
|
9961
10074
|
}
|
|
9962
10075
|
// Cache it. When loading a chart in a hidden iframe in Firefox and
|
|
@@ -10015,21 +10128,11 @@
|
|
|
10015
10128
|
*
|
|
10016
10129
|
* @function Highcharts.SVGElement#hide
|
|
10017
10130
|
*
|
|
10018
|
-
* @param {boolean} [hideByTranslation=false]
|
|
10019
|
-
* The flag to determine if element should be hidden by moving out
|
|
10020
|
-
* of the viewport. Used for example for dataLabels.
|
|
10021
|
-
*
|
|
10022
10131
|
* @return {Highcharts.SVGElement}
|
|
10023
10132
|
* Returns the SVGElement for chaining.
|
|
10024
10133
|
*/
|
|
10025
|
-
SVGElement.prototype.hide = function (
|
|
10026
|
-
|
|
10027
|
-
this.attr({ y: -9999 });
|
|
10028
|
-
}
|
|
10029
|
-
else {
|
|
10030
|
-
this.attr({ visibility: 'hidden' });
|
|
10031
|
-
}
|
|
10032
|
-
return this;
|
|
10134
|
+
SVGElement.prototype.hide = function () {
|
|
10135
|
+
return this.attr({ visibility: 'hidden' });
|
|
10033
10136
|
};
|
|
10034
10137
|
/**
|
|
10035
10138
|
* @private
|
|
@@ -10444,7 +10547,7 @@
|
|
|
10444
10547
|
*
|
|
10445
10548
|
* @function Highcharts.SVGElement#show
|
|
10446
10549
|
*
|
|
10447
|
-
* @param {boolean} [inherit=
|
|
10550
|
+
* @param {boolean} [inherit=true]
|
|
10448
10551
|
* Set the visibility attribute to `inherit` rather than `visible`.
|
|
10449
10552
|
* The difference is that an element with `visibility="visible"`
|
|
10450
10553
|
* will be visible even if the parent is hidden.
|
|
@@ -10453,6 +10556,7 @@
|
|
|
10453
10556
|
* Returns the SVGElement for chaining.
|
|
10454
10557
|
*/
|
|
10455
10558
|
SVGElement.prototype.show = function (inherit) {
|
|
10559
|
+
if (inherit === void 0) { inherit = true; }
|
|
10456
10560
|
return this.attr({ visibility: inherit ? 'inherit' : 'visible' });
|
|
10457
10561
|
};
|
|
10458
10562
|
/**
|
|
@@ -11759,6 +11863,7 @@
|
|
|
11759
11863
|
SVG_NS = H.SVG_NS,
|
|
11760
11864
|
win = H.win;
|
|
11761
11865
|
var attr = U.attr,
|
|
11866
|
+
extend = U.extend,
|
|
11762
11867
|
isString = U.isString,
|
|
11763
11868
|
objectEach = U.objectEach,
|
|
11764
11869
|
pick = U.pick;
|
|
@@ -12034,28 +12139,32 @@
|
|
|
12034
12139
|
var _a = node.attributes,
|
|
12035
12140
|
attributes = _a === void 0 ? {} : _a,
|
|
12036
12141
|
children = node.children,
|
|
12142
|
+
_b = node.style,
|
|
12143
|
+
style = _b === void 0 ? {} : _b,
|
|
12037
12144
|
tagName = node.tagName,
|
|
12038
12145
|
styledMode = _this.renderer.styledMode;
|
|
12039
12146
|
// Apply styling to text tags
|
|
12040
12147
|
if (tagName === 'b' || tagName === 'strong') {
|
|
12041
12148
|
if (styledMode) {
|
|
12042
|
-
|
|
12149
|
+
// eslint-disable-next-line dot-notation
|
|
12150
|
+
attributes['class'] = 'highcharts-strong';
|
|
12043
12151
|
}
|
|
12044
12152
|
else {
|
|
12045
|
-
|
|
12153
|
+
style.fontWeight = 'bold';
|
|
12046
12154
|
}
|
|
12047
12155
|
}
|
|
12048
12156
|
else if (tagName === 'i' || tagName === 'em') {
|
|
12049
12157
|
if (styledMode) {
|
|
12050
|
-
|
|
12158
|
+
// eslint-disable-next-line dot-notation
|
|
12159
|
+
attributes['class'] = 'highcharts-emphasized';
|
|
12051
12160
|
}
|
|
12052
12161
|
else {
|
|
12053
|
-
|
|
12162
|
+
style.fontStyle = 'italic';
|
|
12054
12163
|
}
|
|
12055
12164
|
}
|
|
12056
|
-
// Modify
|
|
12057
|
-
if (
|
|
12058
|
-
|
|
12165
|
+
// Modify styling
|
|
12166
|
+
if (style && style.color) {
|
|
12167
|
+
style.fill = style.color;
|
|
12059
12168
|
}
|
|
12060
12169
|
// Handle breaks
|
|
12061
12170
|
if (tagName === 'br') {
|
|
@@ -12080,7 +12189,7 @@
|
|
|
12080
12189
|
if (tagName !== '#text' && tagName !== 'a') {
|
|
12081
12190
|
node.tagName = 'tspan';
|
|
12082
12191
|
}
|
|
12083
|
-
node
|
|
12192
|
+
extend(node, { attributes: attributes, style: style });
|
|
12084
12193
|
// Recurse
|
|
12085
12194
|
if (children) {
|
|
12086
12195
|
children
|
|
@@ -12420,7 +12529,7 @@
|
|
|
12420
12529
|
this.url = this.getReferenceURL();
|
|
12421
12530
|
// Add description
|
|
12422
12531
|
var desc = this.createElement('desc').add();
|
|
12423
|
-
desc.element.appendChild(doc.createTextNode('Created with Highcharts
|
|
12532
|
+
desc.element.appendChild(doc.createTextNode('Created with Highcharts 10.1.0'));
|
|
12424
12533
|
renderer.defs = this.createElement('defs').add();
|
|
12425
12534
|
renderer.allowHTML = allowHTML;
|
|
12426
12535
|
renderer.forExport = forExport;
|
|
@@ -12731,7 +12840,7 @@
|
|
|
12731
12840
|
* @param {Highcharts.SVGAttributes} [hoverState]
|
|
12732
12841
|
* SVG attributes for the hover state.
|
|
12733
12842
|
*
|
|
12734
|
-
* @param {Highcharts.SVGAttributes} [
|
|
12843
|
+
* @param {Highcharts.SVGAttributes} [selectState]
|
|
12735
12844
|
* SVG attributes for the pressed state.
|
|
12736
12845
|
*
|
|
12737
12846
|
* @param {Highcharts.SVGAttributes} [disabledState]
|
|
@@ -12746,7 +12855,7 @@
|
|
|
12746
12855
|
* @return {Highcharts.SVGElement}
|
|
12747
12856
|
* The button element.
|
|
12748
12857
|
*/
|
|
12749
|
-
SVGRenderer.prototype.button = function (text, x, y, callback, theme, hoverState,
|
|
12858
|
+
SVGRenderer.prototype.button = function (text, x, y, callback, theme, hoverState, selectState, disabledState, shape, useHTML) {
|
|
12750
12859
|
var label = this.label(text,
|
|
12751
12860
|
x,
|
|
12752
12861
|
y,
|
|
@@ -12755,59 +12864,60 @@
|
|
|
12755
12864
|
void 0,
|
|
12756
12865
|
useHTML,
|
|
12757
12866
|
void 0, 'button'),
|
|
12758
|
-
styledMode = this.styledMode
|
|
12867
|
+
styledMode = this.styledMode,
|
|
12868
|
+
states = (theme && theme.states) || {};
|
|
12869
|
+
if (theme) {
|
|
12870
|
+
delete theme.states;
|
|
12871
|
+
}
|
|
12759
12872
|
var curState = 0,
|
|
12760
12873
|
// Make a copy of normalState (#13798)
|
|
12761
12874
|
// (reference to options.rangeSelector.buttonTheme)
|
|
12762
12875
|
normalState = theme ? merge(theme) : {};
|
|
12763
|
-
var
|
|
12876
|
+
var normalStyle = merge({
|
|
12877
|
+
color: "#333333" /* neutralColor80 */,
|
|
12878
|
+
cursor: 'pointer',
|
|
12879
|
+
fontWeight: 'normal'
|
|
12880
|
+
},
|
|
12881
|
+
normalState.style);
|
|
12882
|
+
delete normalState.style;
|
|
12764
12883
|
// Remove stylable attributes
|
|
12765
12884
|
normalState = AST.filterUserAttributes(normalState);
|
|
12766
12885
|
// Default, non-stylable attributes
|
|
12767
12886
|
label.attr(merge({ padding: 8, r: 2 }, normalState));
|
|
12768
|
-
// Presentational
|
|
12769
|
-
|
|
12770
|
-
|
|
12771
|
-
|
|
12887
|
+
// Presentational. The string type is a mistake, it is just for
|
|
12888
|
+
// compliance with SVGAttribute and is not used in button theme.
|
|
12889
|
+
var hoverStyle,
|
|
12890
|
+
selectStyle,
|
|
12772
12891
|
disabledStyle;
|
|
12773
12892
|
if (!styledMode) {
|
|
12774
12893
|
// Normal state - prepare the attributes
|
|
12775
12894
|
normalState = merge({
|
|
12776
12895
|
fill: "#f7f7f7" /* neutralColor3 */,
|
|
12777
12896
|
stroke: "#cccccc" /* neutralColor20 */,
|
|
12778
|
-
'stroke-width': 1
|
|
12779
|
-
style: {
|
|
12780
|
-
color: "#333333" /* neutralColor80 */,
|
|
12781
|
-
cursor: 'pointer',
|
|
12782
|
-
fontWeight: 'normal'
|
|
12783
|
-
}
|
|
12784
|
-
}, {
|
|
12785
|
-
style: userNormalStyle
|
|
12897
|
+
'stroke-width': 1
|
|
12786
12898
|
}, normalState);
|
|
12787
|
-
normalStyle = normalState.style;
|
|
12788
|
-
delete normalState.style;
|
|
12789
12899
|
// Hover state
|
|
12790
12900
|
hoverState = merge(normalState, {
|
|
12791
12901
|
fill: "#e6e6e6" /* neutralColor10 */
|
|
12792
|
-
}, AST.filterUserAttributes(hoverState || {}));
|
|
12902
|
+
}, AST.filterUserAttributes(hoverState || states.hover || {}));
|
|
12793
12903
|
hoverStyle = hoverState.style;
|
|
12794
12904
|
delete hoverState.style;
|
|
12795
12905
|
// Pressed state
|
|
12796
|
-
|
|
12906
|
+
selectState = merge(normalState, {
|
|
12797
12907
|
fill: "#e6ebf5" /* highlightColor10 */,
|
|
12798
12908
|
style: {
|
|
12799
12909
|
color: "#000000" /* neutralColor100 */,
|
|
12800
12910
|
fontWeight: 'bold'
|
|
12801
12911
|
}
|
|
12802
|
-
}, AST.filterUserAttributes(
|
|
12803
|
-
|
|
12804
|
-
delete
|
|
12912
|
+
}, AST.filterUserAttributes(selectState || states.select || {}));
|
|
12913
|
+
selectStyle = selectState.style;
|
|
12914
|
+
delete selectState.style;
|
|
12805
12915
|
// Disabled state
|
|
12806
12916
|
disabledState = merge(normalState, {
|
|
12807
12917
|
style: {
|
|
12808
12918
|
color: "#cccccc" /* neutralColor20 */
|
|
12809
12919
|
}
|
|
12810
|
-
}, AST.filterUserAttributes(disabledState || {}));
|
|
12920
|
+
}, AST.filterUserAttributes(disabledState || states.disabled || {}));
|
|
12811
12921
|
disabledStyle = disabledState.style;
|
|
12812
12922
|
delete disabledState.style;
|
|
12813
12923
|
}
|
|
@@ -12838,15 +12948,18 @@
|
|
|
12838
12948
|
.attr([
|
|
12839
12949
|
normalState,
|
|
12840
12950
|
hoverState,
|
|
12841
|
-
|
|
12951
|
+
selectState,
|
|
12842
12952
|
disabledState
|
|
12843
|
-
][state || 0])
|
|
12844
|
-
.css([
|
|
12845
|
-
normalStyle,
|
|
12846
|
-
hoverStyle,
|
|
12847
|
-
pressedStyle,
|
|
12848
|
-
disabledStyle
|
|
12849
12953
|
][state || 0]);
|
|
12954
|
+
var css_1 = [
|
|
12955
|
+
normalStyle,
|
|
12956
|
+
hoverStyle,
|
|
12957
|
+
selectStyle,
|
|
12958
|
+
disabledStyle
|
|
12959
|
+
][state || 0];
|
|
12960
|
+
if (isObject(css_1)) {
|
|
12961
|
+
label.css(css_1);
|
|
12962
|
+
}
|
|
12850
12963
|
}
|
|
12851
12964
|
};
|
|
12852
12965
|
// Presentational attributes
|
|
@@ -18486,11 +18599,11 @@
|
|
|
18486
18599
|
// Set the new position, and show or hide
|
|
18487
18600
|
if (show && isNumber(xy.y)) {
|
|
18488
18601
|
xy.opacity = opacity;
|
|
18489
|
-
label[tick.isNewLabel ? 'attr' : 'animate'](xy);
|
|
18602
|
+
label[tick.isNewLabel ? 'attr' : 'animate'](xy).show(true);
|
|
18490
18603
|
tick.isNewLabel = false;
|
|
18491
18604
|
}
|
|
18492
18605
|
else {
|
|
18493
|
-
label.
|
|
18606
|
+
label.hide(); // #1338, #15863
|
|
18494
18607
|
tick.isNewLabel = true;
|
|
18495
18608
|
}
|
|
18496
18609
|
}
|
|
@@ -18590,7 +18703,6 @@
|
|
|
18590
18703
|
error = U.error,
|
|
18591
18704
|
extend = U.extend,
|
|
18592
18705
|
fireEvent = U.fireEvent,
|
|
18593
|
-
getMagnitude = U.getMagnitude,
|
|
18594
18706
|
isArray = U.isArray,
|
|
18595
18707
|
isNumber = U.isNumber,
|
|
18596
18708
|
isString = U.isString,
|
|
@@ -18602,6 +18714,16 @@
|
|
|
18602
18714
|
removeEvent = U.removeEvent,
|
|
18603
18715
|
splat = U.splat,
|
|
18604
18716
|
syncTimeout = U.syncTimeout;
|
|
18717
|
+
var getNormalizedTickInterval = function (axis,
|
|
18718
|
+
tickInterval) { return normalizeTickInterval(tickInterval,
|
|
18719
|
+
void 0,
|
|
18720
|
+
void 0,
|
|
18721
|
+
pick(axis.options.allowDecimals,
|
|
18722
|
+
// If the tick interval is greather than 0.5, avoid decimals, as
|
|
18723
|
+
// linear axes are often used to render discrete values (#3363). If
|
|
18724
|
+
// a tick amount is set, allow decimals by default, as it increases
|
|
18725
|
+
// the chances for a good fit.
|
|
18726
|
+
tickInterval < 0.5 || axis.tickAmount !== void 0), !!axis.tickAmount); };
|
|
18605
18727
|
/* *
|
|
18606
18728
|
*
|
|
18607
18729
|
* Class
|
|
@@ -18648,7 +18770,6 @@
|
|
|
18648
18770
|
function Axis(chart, userOptions) {
|
|
18649
18771
|
this.alternateBands = void 0;
|
|
18650
18772
|
this.bottom = void 0;
|
|
18651
|
-
this.categories = void 0;
|
|
18652
18773
|
this.chart = void 0;
|
|
18653
18774
|
this.closestPointRange = void 0;
|
|
18654
18775
|
this.coll = void 0;
|
|
@@ -18812,7 +18933,7 @@
|
|
|
18812
18933
|
* @type {Array<string>}
|
|
18813
18934
|
* @readonly
|
|
18814
18935
|
*/
|
|
18815
|
-
axis.categories = options.categories || axis.hasNames;
|
|
18936
|
+
axis.categories = options.categories || (axis.hasNames ? [] : void 0);
|
|
18816
18937
|
if (!axis.names) { // Preserve on update (#3830)
|
|
18817
18938
|
axis.names = [];
|
|
18818
18939
|
axis.names.keys = {};
|
|
@@ -19151,8 +19272,9 @@
|
|
|
19151
19272
|
if (doPostTranslate) { // log, ordinal and broken axis
|
|
19152
19273
|
val = axis.val2lin(val);
|
|
19153
19274
|
}
|
|
19275
|
+
var value = sign * (val - localMin) * localA;
|
|
19154
19276
|
returnValue = isNumber(localMin) ?
|
|
19155
|
-
(
|
|
19277
|
+
((!axis.isRadial ? correctFloat(value) : value) +
|
|
19156
19278
|
cvsOffset +
|
|
19157
19279
|
(sign * minPixelPadding) +
|
|
19158
19280
|
(isNumber(pointPlacement) ?
|
|
@@ -19546,20 +19668,20 @@
|
|
|
19546
19668
|
* The X value that the point is given.
|
|
19547
19669
|
*/
|
|
19548
19670
|
Axis.prototype.nameToX = function (point) {
|
|
19549
|
-
var explicitCategories = isArray(this.categories),
|
|
19671
|
+
var explicitCategories = isArray(this.options.categories),
|
|
19550
19672
|
names = explicitCategories ? this.categories : this.names;
|
|
19551
19673
|
var nameX = point.options.x,
|
|
19552
19674
|
x;
|
|
19553
19675
|
point.series.requireSorting = false;
|
|
19554
19676
|
if (!defined(nameX)) {
|
|
19555
|
-
nameX = this.options.uniqueNames ?
|
|
19677
|
+
nameX = this.options.uniqueNames && names ?
|
|
19556
19678
|
(explicitCategories ?
|
|
19557
19679
|
names.indexOf(point.name) :
|
|
19558
19680
|
pick(names.keys[point.name], -1)) :
|
|
19559
19681
|
point.series.autoIncrement();
|
|
19560
19682
|
}
|
|
19561
19683
|
if (nameX === -1) { // Not found in currenct categories
|
|
19562
|
-
if (!explicitCategories) {
|
|
19684
|
+
if (!explicitCategories && names) {
|
|
19563
19685
|
x = names.length;
|
|
19564
19686
|
}
|
|
19565
19687
|
}
|
|
@@ -19954,15 +20076,9 @@
|
|
|
19954
20076
|
if (!tickIntervalOption && axis.tickInterval < minTickInterval) {
|
|
19955
20077
|
axis.tickInterval = minTickInterval;
|
|
19956
20078
|
}
|
|
19957
|
-
//
|
|
20079
|
+
// For linear axes, normalize the interval
|
|
19958
20080
|
if (!axis.dateTime && !axis.logarithmic && !tickIntervalOption) {
|
|
19959
|
-
axis.tickInterval =
|
|
19960
|
-
// If the tick interval is greather than 0.5, avoid
|
|
19961
|
-
// decimals, as linear axes are often used to render
|
|
19962
|
-
// discrete values. #3363. If a tick amount is set, allow
|
|
19963
|
-
// decimals by default, as it increases the chances for a
|
|
19964
|
-
// good fit.
|
|
19965
|
-
axis.tickInterval < 0.5 || this.tickAmount !== void 0), !!this.tickAmount);
|
|
20081
|
+
axis.tickInterval = getNormalizedTickInterval(axis, axis.tickInterval);
|
|
19966
20082
|
}
|
|
19967
20083
|
// Prevent ticks from getting so close that we can't draw the labels
|
|
19968
20084
|
if (!this.tickAmount) {
|
|
@@ -20047,7 +20163,21 @@
|
|
|
20047
20163
|
tickPositions = axis.logarithmic.getLogTickPositions(this.tickInterval, this.min, this.max);
|
|
20048
20164
|
}
|
|
20049
20165
|
else {
|
|
20050
|
-
|
|
20166
|
+
var startingTickInterval = this.tickInterval;
|
|
20167
|
+
var adjustedTickInterval = startingTickInterval;
|
|
20168
|
+
while (adjustedTickInterval <= startingTickInterval * 2) {
|
|
20169
|
+
tickPositions = this.getLinearTickPositions(this.tickInterval, this.min, this.max);
|
|
20170
|
+
// If there are more tick positions than the set tickAmount,
|
|
20171
|
+
// increase the tickInterval and continue until it fits.
|
|
20172
|
+
// (#17100)
|
|
20173
|
+
if (this.tickAmount &&
|
|
20174
|
+
tickPositions.length > this.tickAmount) {
|
|
20175
|
+
this.tickInterval = getNormalizedTickInterval(this, adjustedTickInterval *= 1.1);
|
|
20176
|
+
}
|
|
20177
|
+
else {
|
|
20178
|
+
break;
|
|
20179
|
+
}
|
|
20180
|
+
}
|
|
20051
20181
|
}
|
|
20052
20182
|
// Too dense ticks, keep only the first and last (#4477)
|
|
20053
20183
|
if (tickPositions.length > this.len) {
|
|
@@ -20146,39 +20276,92 @@
|
|
|
20146
20276
|
*/
|
|
20147
20277
|
Axis.prototype.alignToOthers = function () {
|
|
20148
20278
|
var axis = this,
|
|
20149
|
-
|
|
20150
|
-
|
|
20151
|
-
|
|
20279
|
+
alignedAxes = [this],
|
|
20280
|
+
options = axis.options,
|
|
20281
|
+
alignThresholds = (this.coll === 'yAxis' &&
|
|
20282
|
+
this.chart.options.chart.alignThresholds),
|
|
20283
|
+
thresholdAlignments = [];
|
|
20152
20284
|
var hasOther;
|
|
20153
|
-
|
|
20154
|
-
|
|
20155
|
-
|
|
20156
|
-
|
|
20285
|
+
axis.thresholdAlignment = void 0;
|
|
20286
|
+
if ((
|
|
20287
|
+
// Only if alignTicks or alignThresholds is true
|
|
20288
|
+
(this.chart.options.chart.alignTicks !== false &&
|
|
20289
|
+
options.alignTicks) || (alignThresholds)) &&
|
|
20157
20290
|
// Disabled when startOnTick or endOnTick are false (#7604)
|
|
20158
20291
|
options.startOnTick !== false &&
|
|
20159
20292
|
options.endOnTick !== false &&
|
|
20160
20293
|
// Don't try to align ticks on a log axis, they are not evenly
|
|
20161
20294
|
// spaced (#6021)
|
|
20162
20295
|
!axis.logarithmic) {
|
|
20163
|
-
|
|
20164
|
-
|
|
20165
|
-
|
|
20166
|
-
|
|
20167
|
-
|
|
20168
|
-
|
|
20169
|
-
|
|
20170
|
-
|
|
20171
|
-
|
|
20172
|
-
|
|
20173
|
-
|
|
20174
|
-
|
|
20175
|
-
|
|
20176
|
-
|
|
20296
|
+
// Get a key identifying which pane the axis belongs to
|
|
20297
|
+
var getKey_1 = function (axis) {
|
|
20298
|
+
var horiz = axis.horiz,
|
|
20299
|
+
options = axis.options;
|
|
20300
|
+
return [
|
|
20301
|
+
horiz ? options.left : options.top,
|
|
20302
|
+
options.width,
|
|
20303
|
+
options.height,
|
|
20304
|
+
options.pane
|
|
20305
|
+
].join(',');
|
|
20306
|
+
};
|
|
20307
|
+
var thisKey_1 = getKey_1(this);
|
|
20308
|
+
this.chart[this.coll].forEach(function (otherAxis) {
|
|
20309
|
+
var series = otherAxis.series;
|
|
20310
|
+
if (
|
|
20311
|
+
// #4442
|
|
20312
|
+
series.length &&
|
|
20313
|
+
series.some(function (s) { return s.visible; }) &&
|
|
20314
|
+
otherAxis !== axis &&
|
|
20315
|
+
getKey_1(otherAxis) === thisKey_1) {
|
|
20316
|
+
hasOther = true; // #4201
|
|
20317
|
+
alignedAxes.push(otherAxis);
|
|
20177
20318
|
}
|
|
20178
20319
|
});
|
|
20179
20320
|
}
|
|
20321
|
+
if (hasOther && alignThresholds) {
|
|
20322
|
+
// Handle alignThresholds. The `thresholdAlignments` array keeps
|
|
20323
|
+
// records of where each axis in the group wants its threshold, from
|
|
20324
|
+
// 0 which is on `axis.min`, to 1 which is on `axis.max`.
|
|
20325
|
+
alignedAxes.forEach(function (otherAxis) {
|
|
20326
|
+
var threshAlign = otherAxis.getThresholdAlignment(axis);
|
|
20327
|
+
if (isNumber(threshAlign)) {
|
|
20328
|
+
thresholdAlignments.push(threshAlign);
|
|
20329
|
+
}
|
|
20330
|
+
});
|
|
20331
|
+
// For each of the axes in the group, record the average
|
|
20332
|
+
// `thresholdAlignment`.
|
|
20333
|
+
var thresholdAlignment_1 = thresholdAlignments.length > 1 ?
|
|
20334
|
+
thresholdAlignments.reduce(function (sum,
|
|
20335
|
+
n) { return (sum += n); }, 0) / thresholdAlignments.length :
|
|
20336
|
+
void 0;
|
|
20337
|
+
alignedAxes.forEach(function (axis) {
|
|
20338
|
+
axis.thresholdAlignment = thresholdAlignment_1;
|
|
20339
|
+
});
|
|
20340
|
+
}
|
|
20180
20341
|
return hasOther;
|
|
20181
20342
|
};
|
|
20343
|
+
/**
|
|
20344
|
+
* Where the axis wants its threshold, from 0 which is on `axis.min`, to 1 which
|
|
20345
|
+
* is on `axis.max`.
|
|
20346
|
+
*
|
|
20347
|
+
* @private
|
|
20348
|
+
* @function Highcharts.Axis#getThresholdAlignment
|
|
20349
|
+
*/
|
|
20350
|
+
Axis.prototype.getThresholdAlignment = function (callerAxis) {
|
|
20351
|
+
if (!isNumber(this.dataMin) ||
|
|
20352
|
+
(this !== callerAxis &&
|
|
20353
|
+
this.series.some(function (s) { return (s.isDirty || s.isDirtyData); }))) {
|
|
20354
|
+
this.getSeriesExtremes();
|
|
20355
|
+
}
|
|
20356
|
+
if (isNumber(this.threshold)) {
|
|
20357
|
+
var thresholdAlignment = clamp(((this.threshold - (this.dataMin || 0)) /
|
|
20358
|
+
((this.dataMax || 0) - (this.dataMin || 0))), 0, 1);
|
|
20359
|
+
if (this.options.reversed) {
|
|
20360
|
+
thresholdAlignment = 1 - thresholdAlignment;
|
|
20361
|
+
}
|
|
20362
|
+
return thresholdAlignment;
|
|
20363
|
+
}
|
|
20364
|
+
};
|
|
20182
20365
|
/**
|
|
20183
20366
|
* Find the max ticks of either the x and y axis collection, and record it
|
|
20184
20367
|
* in `this.tickAmount`.
|
|
@@ -20223,47 +20406,101 @@
|
|
|
20223
20406
|
*/
|
|
20224
20407
|
Axis.prototype.adjustTickAmount = function () {
|
|
20225
20408
|
var axis = this,
|
|
20226
|
-
|
|
20227
|
-
|
|
20409
|
+
finalTickAmt = axis.finalTickAmt,
|
|
20410
|
+
max = axis.max,
|
|
20411
|
+
min = axis.min,
|
|
20412
|
+
options = axis.options,
|
|
20228
20413
|
tickPositions = axis.tickPositions,
|
|
20229
20414
|
tickAmount = axis.tickAmount,
|
|
20230
|
-
|
|
20415
|
+
thresholdAlignment = axis.thresholdAlignment,
|
|
20231
20416
|
currentTickAmount = tickPositions && tickPositions.length,
|
|
20232
20417
|
threshold = pick(axis.threshold,
|
|
20233
20418
|
axis.softThreshold ? 0 : null);
|
|
20234
20419
|
var len,
|
|
20235
|
-
i
|
|
20236
|
-
|
|
20237
|
-
|
|
20238
|
-
|
|
20239
|
-
|
|
20420
|
+
i,
|
|
20421
|
+
tickInterval = axis.tickInterval,
|
|
20422
|
+
thresholdTickIndex;
|
|
20423
|
+
var
|
|
20424
|
+
// Extend the tickPositions by appending a position
|
|
20425
|
+
append = function () { return tickPositions.push(correctFloat(tickPositions[tickPositions.length - 1] +
|
|
20426
|
+
tickInterval)); },
|
|
20427
|
+
// Extend the tickPositions by prepending a position
|
|
20428
|
+
prepend = function () { return tickPositions.unshift(correctFloat(tickPositions[0] - tickInterval)); };
|
|
20429
|
+
// If `thresholdAlignment` is a number, it means the `alignThresholds`
|
|
20430
|
+
// option is true. The `thresholdAlignment` is a scalar value between 0
|
|
20431
|
+
// and 1 for where the threshold should be relative to `axis.min` and
|
|
20432
|
+
// `axis.max`. Now that we know the tick amount, convert this to the
|
|
20433
|
+
// tick index. Unless `thresholdAlignment` is exactly 0 or 1, avoid the
|
|
20434
|
+
// first or last tick because that would lead to series being clipped.
|
|
20435
|
+
if (isNumber(thresholdAlignment)) {
|
|
20436
|
+
thresholdTickIndex = thresholdAlignment < 0.5 ?
|
|
20437
|
+
Math.ceil(thresholdAlignment * (tickAmount - 1)) :
|
|
20438
|
+
Math.floor(thresholdAlignment * (tickAmount - 1));
|
|
20439
|
+
if (options.reversed) {
|
|
20440
|
+
thresholdTickIndex = tickAmount - 1 - thresholdTickIndex;
|
|
20441
|
+
}
|
|
20442
|
+
}
|
|
20443
|
+
if (axis.hasData() && isNumber(min) && isNumber(max)) { // #14769
|
|
20444
|
+
// Adjust extremes and translation to the modified tick positions
|
|
20445
|
+
var adjustExtremes = function () {
|
|
20446
|
+
axis.transA *= (currentTickAmount - 1) / (tickAmount - 1);
|
|
20447
|
+
// Do not crop when ticks are not extremes (#9841)
|
|
20448
|
+
axis.min = options.startOnTick ?
|
|
20449
|
+
tickPositions[0] :
|
|
20450
|
+
Math.min(min, tickPositions[0]);
|
|
20451
|
+
axis.max = options.endOnTick ?
|
|
20452
|
+
tickPositions[tickPositions.length - 1] :
|
|
20453
|
+
Math.max(max, tickPositions[tickPositions.length - 1]);
|
|
20454
|
+
};
|
|
20455
|
+
// When the axis is subject to the alignThresholds option. Use
|
|
20456
|
+
// axis.threshold because the local threshold includes the
|
|
20457
|
+
// `softThreshold`.
|
|
20458
|
+
if (isNumber(thresholdTickIndex) && isNumber(axis.threshold)) {
|
|
20459
|
+
// Throw away the previously computed tickPositions and start
|
|
20460
|
+
// from scratch with only the threshold itself, then add ticks
|
|
20461
|
+
// below the threshold first, then fill up above the threshold.
|
|
20462
|
+
// If we are not able to fill up to axis.max, double the
|
|
20463
|
+
// tickInterval and run again.
|
|
20464
|
+
while (tickPositions[thresholdTickIndex] !== threshold ||
|
|
20465
|
+
tickPositions.length !== tickAmount ||
|
|
20466
|
+
tickPositions[0] > min ||
|
|
20467
|
+
tickPositions[tickPositions.length - 1] < max) {
|
|
20468
|
+
tickPositions.length = 0;
|
|
20469
|
+
tickPositions.push(axis.threshold);
|
|
20470
|
+
while (tickPositions.length < tickAmount) {
|
|
20471
|
+
if (
|
|
20472
|
+
// Start by prepending positions until the threshold
|
|
20473
|
+
// is at the required index...
|
|
20474
|
+
tickPositions[thresholdTickIndex] === void 0 ||
|
|
20475
|
+
tickPositions[thresholdTickIndex] > axis.threshold) {
|
|
20476
|
+
prepend();
|
|
20477
|
+
}
|
|
20478
|
+
else {
|
|
20479
|
+
// ... then append positions until we have the
|
|
20480
|
+
// required length
|
|
20481
|
+
append();
|
|
20482
|
+
}
|
|
20483
|
+
}
|
|
20484
|
+
// Safety vent
|
|
20485
|
+
if (tickInterval > axis.tickInterval * 8) {
|
|
20486
|
+
break;
|
|
20487
|
+
}
|
|
20488
|
+
tickInterval *= 2;
|
|
20489
|
+
}
|
|
20490
|
+
adjustExtremes();
|
|
20491
|
+
}
|
|
20492
|
+
else if (currentTickAmount < tickAmount) {
|
|
20240
20493
|
while (tickPositions.length < tickAmount) {
|
|
20241
20494
|
// Extend evenly for both sides unless we're on the
|
|
20242
20495
|
// threshold (#3965)
|
|
20243
|
-
if (tickPositions.length % 2 ||
|
|
20244
|
-
|
|
20245
|
-
// to the end
|
|
20246
|
-
tickPositions.push(correctFloat(tickPositions[tickPositions.length - 1] +
|
|
20247
|
-
tickInterval));
|
|
20496
|
+
if (tickPositions.length % 2 || min === threshold) {
|
|
20497
|
+
append();
|
|
20248
20498
|
}
|
|
20249
20499
|
else {
|
|
20250
|
-
|
|
20251
|
-
tickPositions.unshift(correctFloat(tickPositions[0] - tickInterval));
|
|
20500
|
+
prepend();
|
|
20252
20501
|
}
|
|
20253
20502
|
}
|
|
20254
|
-
|
|
20255
|
-
// Do not crop when ticks are not extremes (#9841)
|
|
20256
|
-
axis.min = axisOptions.startOnTick ?
|
|
20257
|
-
tickPositions[0] :
|
|
20258
|
-
Math.min(axis.min, tickPositions[0]);
|
|
20259
|
-
axis.max = axisOptions.endOnTick ?
|
|
20260
|
-
tickPositions[tickPositions.length - 1] :
|
|
20261
|
-
Math.max(axis.max, tickPositions[tickPositions.length - 1]);
|
|
20262
|
-
// We have too many ticks, run second pass to try to reduce ticks
|
|
20263
|
-
}
|
|
20264
|
-
else if (currentTickAmount > tickAmount) {
|
|
20265
|
-
axis.tickInterval *= 2;
|
|
20266
|
-
axis.setTickPositions();
|
|
20503
|
+
adjustExtremes();
|
|
20267
20504
|
}
|
|
20268
20505
|
// The finalTickAmt property is set in getTickAmount
|
|
20269
20506
|
if (defined(finalTickAmt)) {
|
|
@@ -21219,18 +21456,18 @@
|
|
|
21219
21456
|
// The part of a multiline text that is below the baseline of the
|
|
21220
21457
|
// first line. Subtract 1 to preserve pixel-perfectness from the
|
|
21221
21458
|
// old behaviour (v5.0.12), where only one line was allowed.
|
|
21222
|
-
textHeightOvershoot = Math.max(axisTitle.getBBox(
|
|
21459
|
+
textHeightOvershoot = axisTitle ? Math.max(axisTitle.getBBox(false, 0).height - fontMetrics.h - 1, 0) : 0,
|
|
21223
21460
|
// the position in the length direction of the axis
|
|
21224
|
-
alongAxis = {
|
|
21461
|
+
alongAxis = ({
|
|
21225
21462
|
low: margin + (horiz ? 0 : axisLength),
|
|
21226
21463
|
middle: margin + axisLength / 2,
|
|
21227
21464
|
high: margin + (horiz ? axisLength : 0)
|
|
21228
|
-
}[axisTitleOptions.align],
|
|
21465
|
+
})[axisTitleOptions.align],
|
|
21229
21466
|
// the position in the perpendicular direction of the axis
|
|
21230
21467
|
offAxis = (horiz ? axisTop + this.height : axisLeft) +
|
|
21231
21468
|
(horiz ? 1 : -1) * // horizontal axis reverses the margin
|
|
21232
21469
|
(opposite ? -1 : 1) * // so does opposite axes
|
|
21233
|
-
this.axisTitleMargin +
|
|
21470
|
+
(this.axisTitleMargin || 0) +
|
|
21234
21471
|
[
|
|
21235
21472
|
-textHeightOvershoot,
|
|
21236
21473
|
textHeightOvershoot,
|
|
@@ -21454,14 +21691,8 @@
|
|
|
21454
21691
|
}
|
|
21455
21692
|
if (axisTitle && showAxis) {
|
|
21456
21693
|
var titleXy = axis.getTitlePosition();
|
|
21457
|
-
|
|
21458
|
-
|
|
21459
|
-
axisTitle.isNew = false;
|
|
21460
|
-
}
|
|
21461
|
-
else {
|
|
21462
|
-
axisTitle.attr('y', -9999);
|
|
21463
|
-
axisTitle.isNew = true;
|
|
21464
|
-
}
|
|
21694
|
+
axisTitle[axisTitle.isNew ? 'attr' : 'animate'](titleXy);
|
|
21695
|
+
axisTitle.isNew = false;
|
|
21465
21696
|
}
|
|
21466
21697
|
// Stacked totals:
|
|
21467
21698
|
if (stackLabelOptions && stackLabelOptions.enabled && axis.stacking) {
|
|
@@ -22469,7 +22700,7 @@
|
|
|
22469
22700
|
axisLength;
|
|
22470
22701
|
interval = pick(filteredTickIntervalOption, log.minorAutoInterval, (realMax - realMin) *
|
|
22471
22702
|
tickPixelIntervalOption / (totalPixelLength || 1));
|
|
22472
|
-
interval = normalizeTickInterval(interval
|
|
22703
|
+
interval = normalizeTickInterval(interval);
|
|
22473
22704
|
positions = axis.getLinearTickPositions(interval, realMin, realMax).map(log.log2lin);
|
|
22474
22705
|
if (!minor) {
|
|
22475
22706
|
log.minorAutoInterval = interval / 5;
|
|
@@ -22969,7 +23200,7 @@
|
|
|
22969
23200
|
}
|
|
22970
23201
|
else if (svgElem) {
|
|
22971
23202
|
if (path) {
|
|
22972
|
-
svgElem.show(
|
|
23203
|
+
svgElem.show();
|
|
22973
23204
|
svgElem.animate({ d: path });
|
|
22974
23205
|
}
|
|
22975
23206
|
else if (svgElem.d) {
|
|
@@ -23869,6 +24100,12 @@
|
|
|
23869
24100
|
* the context here is an object holding point, series, x, y etc.
|
|
23870
24101
|
*
|
|
23871
24102
|
* @function Highcharts.Tooltip#defaultFormatter
|
|
24103
|
+
*
|
|
24104
|
+
* @param {Highcharts.Tooltip} tooltip
|
|
24105
|
+
*
|
|
24106
|
+
* @return {string|Array<string>}
|
|
24107
|
+
* Returns a string (single tooltip and shared)
|
|
24108
|
+
* or an array of strings (split tooltip)
|
|
23872
24109
|
*/
|
|
23873
24110
|
Tooltip.prototype.defaultFormatter = function (tooltip) {
|
|
23874
24111
|
var items = this.points || splat(this);
|
|
@@ -24471,7 +24708,7 @@
|
|
|
24471
24708
|
shared = tooltip.shared,
|
|
24472
24709
|
styledMode = chart.styledMode;
|
|
24473
24710
|
var textConfig = {};
|
|
24474
|
-
if (!options.enabled) {
|
|
24711
|
+
if (!options.enabled || !point.series) { // #16820
|
|
24475
24712
|
return;
|
|
24476
24713
|
}
|
|
24477
24714
|
U.clearTimeout(this.hideTimer);
|
|
@@ -25127,46 +25364,23 @@
|
|
|
25127
25364
|
* @callback Highcharts.TooltipFormatterCallbackFunction
|
|
25128
25365
|
*
|
|
25129
25366
|
* @param {Highcharts.TooltipFormatterContextObject} this
|
|
25130
|
-
*
|
|
25367
|
+
* Context to format
|
|
25131
25368
|
*
|
|
25132
25369
|
* @param {Highcharts.Tooltip} tooltip
|
|
25133
|
-
*
|
|
25370
|
+
* The tooltip instance
|
|
25134
25371
|
*
|
|
25135
25372
|
* @return {false|string|Array<(string|null|undefined)>|null|undefined}
|
|
25136
|
-
*
|
|
25373
|
+
* Formatted text or false
|
|
25137
25374
|
*/
|
|
25138
25375
|
/**
|
|
25376
|
+
* Configuration for the tooltip formatters.
|
|
25377
|
+
*
|
|
25139
25378
|
* @interface Highcharts.TooltipFormatterContextObject
|
|
25379
|
+
* @extends Highcharts.PointLabelObject
|
|
25140
25380
|
*/ /**
|
|
25141
|
-
*
|
|
25142
|
-
* @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
|
|
25143
|
-
*/ /**
|
|
25144
|
-
* @name Highcharts.TooltipFormatterContextObject#colorIndex
|
|
25145
|
-
* @type {number|undefined}
|
|
25146
|
-
*/ /**
|
|
25147
|
-
* @name Highcharts.TooltipFormatterContextObject#key
|
|
25148
|
-
* @type {number}
|
|
25149
|
-
*/ /**
|
|
25150
|
-
* @name Highcharts.TooltipFormatterContextObject#percentage
|
|
25151
|
-
* @type {number|undefined}
|
|
25152
|
-
*/ /**
|
|
25153
|
-
* @name Highcharts.TooltipFormatterContextObject#point
|
|
25154
|
-
* @type {Highcharts.Point}
|
|
25155
|
-
*/ /**
|
|
25381
|
+
* Array of points in shared tooltips.
|
|
25156
25382
|
* @name Highcharts.TooltipFormatterContextObject#points
|
|
25157
25383
|
* @type {Array<Highcharts.TooltipFormatterContextObject>|undefined}
|
|
25158
|
-
*/ /**
|
|
25159
|
-
* @name Highcharts.TooltipFormatterContextObject#series
|
|
25160
|
-
* @type {Highcharts.Series}
|
|
25161
|
-
*/ /**
|
|
25162
|
-
* @name Highcharts.TooltipFormatterContextObject#total
|
|
25163
|
-
* @type {number|undefined}
|
|
25164
|
-
*/ /**
|
|
25165
|
-
* @name Highcharts.TooltipFormatterContextObject#x
|
|
25166
|
-
* @type {number}
|
|
25167
|
-
*/ /**
|
|
25168
|
-
* @name Highcharts.TooltipFormatterContextObject#y
|
|
25169
|
-
* @type {number}
|
|
25170
25384
|
*/
|
|
25171
25385
|
/**
|
|
25172
25386
|
* A callback function to place the tooltip in a specific position.
|
|
@@ -26422,7 +26636,7 @@
|
|
|
26422
26636
|
* @type {Highcharts.Point}
|
|
26423
26637
|
*/
|
|
26424
26638
|
/**
|
|
26425
|
-
* Configuration
|
|
26639
|
+
* Configuration for the data label and tooltip formatters.
|
|
26426
26640
|
*
|
|
26427
26641
|
* @interface Highcharts.PointLabelObject
|
|
26428
26642
|
*/ /**
|
|
@@ -26464,7 +26678,7 @@
|
|
|
26464
26678
|
*/ /**
|
|
26465
26679
|
* The y value of the point.
|
|
26466
26680
|
* @name Highcharts.PointLabelObject#y
|
|
26467
|
-
* @type {number|undefined}
|
|
26681
|
+
* @type {number|null|undefined}
|
|
26468
26682
|
*/
|
|
26469
26683
|
/**
|
|
26470
26684
|
* Gets fired when the mouse leaves the area close to the point.
|
|
@@ -27244,9 +27458,10 @@
|
|
|
27244
27458
|
* name.
|
|
27245
27459
|
*/
|
|
27246
27460
|
Pointer.prototype.inClass = function (element, className) {
|
|
27247
|
-
var
|
|
27248
|
-
|
|
27249
|
-
|
|
27461
|
+
var elem = element,
|
|
27462
|
+
elemClassName;
|
|
27463
|
+
while (elem) {
|
|
27464
|
+
elemClassName = attr(elem, 'class');
|
|
27250
27465
|
if (elemClassName) {
|
|
27251
27466
|
if (elemClassName.indexOf(className) !== -1) {
|
|
27252
27467
|
return true;
|
|
@@ -27255,7 +27470,7 @@
|
|
|
27255
27470
|
return false;
|
|
27256
27471
|
}
|
|
27257
27472
|
}
|
|
27258
|
-
|
|
27473
|
+
elem = elem.parentElement;
|
|
27259
27474
|
}
|
|
27260
27475
|
};
|
|
27261
27476
|
/**
|
|
@@ -27296,6 +27511,9 @@
|
|
|
27296
27511
|
* properties `chartX` and `chartY` in order to work on the internal
|
|
27297
27512
|
* coordinate system.
|
|
27298
27513
|
*
|
|
27514
|
+
* On map charts, the properties `lon` and `lat` are added to the event
|
|
27515
|
+
* object given that the chart has projection information.
|
|
27516
|
+
*
|
|
27299
27517
|
* @function Highcharts.Pointer#normalize
|
|
27300
27518
|
*
|
|
27301
27519
|
* @param {global.MouseEvent|global.PointerEvent|global.TouchEvent} e
|
|
@@ -27891,11 +28109,12 @@
|
|
|
27891
28109
|
* The mouseOver event should be triggered when hoverPoint
|
|
27892
28110
|
* is correct.
|
|
27893
28111
|
*/
|
|
27894
|
-
hoverPoint.firePointEvent('mouseOver')
|
|
27895
|
-
|
|
27896
|
-
|
|
27897
|
-
|
|
27898
|
-
|
|
28112
|
+
hoverPoint.firePointEvent('mouseOver', void 0, function () {
|
|
28113
|
+
// Draw tooltip if necessary
|
|
28114
|
+
if (tooltip && hoverPoint) {
|
|
28115
|
+
tooltip.refresh(useSharedTooltip ? points : hoverPoint, e);
|
|
28116
|
+
}
|
|
28117
|
+
});
|
|
27899
28118
|
// Update positions (regardless of kdpoint or hoverPoint)
|
|
27900
28119
|
}
|
|
27901
28120
|
else if (followPointer && tooltip && !tooltip.isHidden) {
|
|
@@ -27926,7 +28145,7 @@
|
|
|
27926
28145
|
point = chart.hoverPoint; // #13002
|
|
27927
28146
|
if (!point || point.series[axis.coll] !== axis) {
|
|
27928
28147
|
point = find(points, function (p) {
|
|
27929
|
-
return p.series[axis.coll] === axis;
|
|
28148
|
+
return p.series && p.series[axis.coll] === axis;
|
|
27930
28149
|
});
|
|
27931
28150
|
}
|
|
27932
28151
|
}
|
|
@@ -28015,7 +28234,7 @@
|
|
|
28015
28234
|
var hoverChart = H.charts[pick(Pointer.hoverChartIndex, -1)];
|
|
28016
28235
|
if (hoverChart &&
|
|
28017
28236
|
hoverChart !== chart) {
|
|
28018
|
-
hoverChart.pointer.onContainerMouseLeave({ relatedTarget:
|
|
28237
|
+
hoverChart.pointer.onContainerMouseLeave({ relatedTarget: chart.container });
|
|
28019
28238
|
}
|
|
28020
28239
|
if (!hoverChart ||
|
|
28021
28240
|
!hoverChart.mouseIsDown) {
|
|
@@ -28477,7 +28696,7 @@
|
|
|
28477
28696
|
this.maxItemWidth = 0;
|
|
28478
28697
|
this.maxLegendWidth = 0;
|
|
28479
28698
|
this.offsetWidth = 0;
|
|
28480
|
-
this.options =
|
|
28699
|
+
this.options = void 0;
|
|
28481
28700
|
this.padding = 0;
|
|
28482
28701
|
this.pages = [];
|
|
28483
28702
|
this.proximate = false;
|
|
@@ -28808,7 +29027,7 @@
|
|
|
28808
29027
|
* @name Highcharts.Legend#title
|
|
28809
29028
|
* @type {Highcharts.SVGElement}
|
|
28810
29029
|
*/
|
|
28811
|
-
this.title = this.chart.renderer.label(titleOptions.text, padding - 3, padding - 4,
|
|
29030
|
+
this.title = this.chart.renderer.label(titleOptions.text, padding - 3, padding - 4, void 0, void 0, void 0, options.useHTML, void 0, 'legend-title')
|
|
28812
29031
|
.attr({ zIndex: 1 });
|
|
28813
29032
|
if (!this.chart.styledMode) {
|
|
28814
29033
|
this.title.css(titleOptions.style);
|
|
@@ -29175,8 +29394,7 @@
|
|
|
29175
29394
|
legend.lastItemY = 0;
|
|
29176
29395
|
legend.widthOption = relativeLength(options.width, chart.spacingBox.width - padding);
|
|
29177
29396
|
// Compute how wide the legend is allowed to be
|
|
29178
|
-
allowedWidth =
|
|
29179
|
-
chart.spacingBox.width - 2 * padding - options.x;
|
|
29397
|
+
allowedWidth = chart.spacingBox.width - 2 * padding - options.x;
|
|
29180
29398
|
if (['rm', 'lm'].indexOf(legend.getAlignment().substring(0, 2)) > -1) {
|
|
29181
29399
|
allowedWidth /= 2;
|
|
29182
29400
|
}
|
|
@@ -29249,7 +29467,6 @@
|
|
|
29249
29467
|
r: options.borderRadius
|
|
29250
29468
|
})
|
|
29251
29469
|
.add(legendGroup);
|
|
29252
|
-
box.isNew = true;
|
|
29253
29470
|
}
|
|
29254
29471
|
// Presentational
|
|
29255
29472
|
if (!chart.styledMode) {
|
|
@@ -29262,13 +29479,12 @@
|
|
|
29262
29479
|
.shadow(options.shadow);
|
|
29263
29480
|
}
|
|
29264
29481
|
if (legendWidth > 0 && legendHeight > 0) {
|
|
29265
|
-
box[box.
|
|
29482
|
+
box[box.placed ? 'animate' : 'attr'](box.crisp.call({}, {
|
|
29266
29483
|
x: 0,
|
|
29267
29484
|
y: 0,
|
|
29268
29485
|
width: legendWidth,
|
|
29269
29486
|
height: legendHeight
|
|
29270
29487
|
}, box.strokeWidth()));
|
|
29271
|
-
box.isNew = false;
|
|
29272
29488
|
}
|
|
29273
29489
|
// hide the border if no items
|
|
29274
29490
|
box[display ? 'show' : 'hide']();
|
|
@@ -29311,6 +29527,11 @@
|
|
|
29311
29527
|
if (y !== alignTo.y) {
|
|
29312
29528
|
alignTo = merge(alignTo, { y: y });
|
|
29313
29529
|
}
|
|
29530
|
+
if (!chart.hasRendered) {
|
|
29531
|
+
// Avoid animation when adjusting alignment for responsiveness and
|
|
29532
|
+
// colorAxis label layout
|
|
29533
|
+
this.group.placed = false;
|
|
29534
|
+
}
|
|
29314
29535
|
this.group.align(merge(options, {
|
|
29315
29536
|
width: this.legendWidth,
|
|
29316
29537
|
height: this.legendHeight,
|
|
@@ -29444,7 +29665,7 @@
|
|
|
29444
29665
|
});
|
|
29445
29666
|
this.pager = renderer.text('', 15, 10)
|
|
29446
29667
|
.addClass('highcharts-legend-navigation');
|
|
29447
|
-
if (!chart.styledMode) {
|
|
29668
|
+
if (!chart.styledMode && navOptions.style) {
|
|
29448
29669
|
this.pager.css(navOptions.style);
|
|
29449
29670
|
}
|
|
29450
29671
|
this.pager.add(nav);
|
|
@@ -29505,7 +29726,7 @@
|
|
|
29505
29726
|
this.nav.attr({
|
|
29506
29727
|
translateX: padding,
|
|
29507
29728
|
translateY: clipHeight + this.padding + 7 + this.titleHeight,
|
|
29508
|
-
visibility: '
|
|
29729
|
+
visibility: 'inherit'
|
|
29509
29730
|
});
|
|
29510
29731
|
[this.up, this.upTracker].forEach(function (elem) {
|
|
29511
29732
|
elem.attr({
|
|
@@ -29957,7 +30178,6 @@
|
|
|
29957
30178
|
fireEvent = U.fireEvent,
|
|
29958
30179
|
getStyle = U.getStyle,
|
|
29959
30180
|
isArray = U.isArray,
|
|
29960
|
-
isFunction = U.isFunction,
|
|
29961
30181
|
isNumber = U.isNumber,
|
|
29962
30182
|
isObject = U.isObject,
|
|
29963
30183
|
isString = U.isString,
|
|
@@ -32003,9 +32223,27 @@
|
|
|
32003
32223
|
if (defined(this.index)) {
|
|
32004
32224
|
this.setReflow(this.options.chart.reflow);
|
|
32005
32225
|
}
|
|
32226
|
+
this.warnIfA11yModuleNotLoaded();
|
|
32006
32227
|
// Don't run again
|
|
32007
32228
|
this.hasLoaded = true;
|
|
32008
32229
|
};
|
|
32230
|
+
/**
|
|
32231
|
+
* Emit console warning if the a11y module is not loaded.
|
|
32232
|
+
*/
|
|
32233
|
+
Chart.prototype.warnIfA11yModuleNotLoaded = function () {
|
|
32234
|
+
var _this = this;
|
|
32235
|
+
setTimeout(function () {
|
|
32236
|
+
var opts = _this && _this.options;
|
|
32237
|
+
if (opts && !_this.accessibility &&
|
|
32238
|
+
!(opts.accessibility && opts.accessibility.enabled === false)) {
|
|
32239
|
+
error('Highcharts warning: Consider including the ' +
|
|
32240
|
+
'"accessibility.js" module to make your chart more ' +
|
|
32241
|
+
'usable for people with disabilities. Set the ' +
|
|
32242
|
+
'"accessibility.enabled" option to false to remove this ' +
|
|
32243
|
+
'warning. See https://www.highcharts.com/docs/accessibility/accessibility-module.', false, _this);
|
|
32244
|
+
}
|
|
32245
|
+
}, 100);
|
|
32246
|
+
};
|
|
32009
32247
|
/**
|
|
32010
32248
|
* Add a series to the chart after render time. Note that this method should
|
|
32011
32249
|
* never be used when adding data synchronously at chart render time, as it
|
|
@@ -32570,7 +32808,6 @@
|
|
|
32570
32808
|
lang = defaultOptions.lang,
|
|
32571
32809
|
btnOptions = chart.options.chart.resetZoomButton,
|
|
32572
32810
|
theme = btnOptions.theme,
|
|
32573
|
-
states = theme.states,
|
|
32574
32811
|
alignTo = (btnOptions.relativeTo === 'chart' ||
|
|
32575
32812
|
btnOptions.relativeTo === 'spacingBox' ?
|
|
32576
32813
|
null :
|
|
@@ -32583,7 +32820,7 @@
|
|
|
32583
32820
|
}
|
|
32584
32821
|
fireEvent(this, 'beforeShowResetZoom', null, function () {
|
|
32585
32822
|
chart.resetZoomButton = chart.renderer
|
|
32586
|
-
.button(lang.resetZoom, null, null, zoomOut, theme
|
|
32823
|
+
.button(lang.resetZoom, null, null, zoomOut, theme)
|
|
32587
32824
|
.attr({
|
|
32588
32825
|
align: btnOptions.position.align,
|
|
32589
32826
|
title: lang.resetZoomTitle
|
|
@@ -34381,6 +34618,9 @@
|
|
|
34381
34618
|
* parameter, `event`, is passed to the function, containing common
|
|
34382
34619
|
* event information.
|
|
34383
34620
|
*
|
|
34621
|
+
* Returning `false` cancels the default behavior, which is to show a
|
|
34622
|
+
* tooltip for the point.
|
|
34623
|
+
*
|
|
34384
34624
|
* @sample {highcharts} highcharts/plotoptions/series-point-events-mouseover/
|
|
34385
34625
|
* Show values in the chart's corner on mouse over
|
|
34386
34626
|
*
|
|
@@ -35103,7 +35343,7 @@
|
|
|
35103
35343
|
* @deprecated
|
|
35104
35344
|
*
|
|
35105
35345
|
* @extends plotOptions.series.marker
|
|
35106
|
-
* @excluding states
|
|
35346
|
+
* @excluding states, symbol
|
|
35107
35347
|
* @product highcharts highstock
|
|
35108
35348
|
*/
|
|
35109
35349
|
marker: {
|
|
@@ -36319,8 +36559,19 @@
|
|
|
36319
36559
|
updatedData,
|
|
36320
36560
|
indexOfX = 0,
|
|
36321
36561
|
indexOfY = 1,
|
|
36322
|
-
firstPoint = null
|
|
36323
|
-
|
|
36562
|
+
firstPoint = null,
|
|
36563
|
+
copiedData;
|
|
36564
|
+
if (!chart.options.chart.allowMutatingData) { // #4259
|
|
36565
|
+
// Remove old reference
|
|
36566
|
+
if (options.data) {
|
|
36567
|
+
delete series.options.data;
|
|
36568
|
+
}
|
|
36569
|
+
if (series.userOptions.data) {
|
|
36570
|
+
delete series.userOptions.data;
|
|
36571
|
+
}
|
|
36572
|
+
copiedData = merge(true, data);
|
|
36573
|
+
}
|
|
36574
|
+
data = copiedData || data || [];
|
|
36324
36575
|
var dataLength = data.length;
|
|
36325
36576
|
redraw = pick(redraw, true);
|
|
36326
36577
|
if (dataSorting && dataSorting.enabled) {
|
|
@@ -36328,7 +36579,8 @@
|
|
|
36328
36579
|
}
|
|
36329
36580
|
// First try to run Point.update which is cheaper, allows animation,
|
|
36330
36581
|
// and keeps references to points.
|
|
36331
|
-
if (
|
|
36582
|
+
if (chart.options.chart.allowMutatingData &&
|
|
36583
|
+
updatePoints !== false &&
|
|
36332
36584
|
dataLength &&
|
|
36333
36585
|
oldDataLength &&
|
|
36334
36586
|
!series.cropped &&
|
|
@@ -36553,7 +36805,7 @@
|
|
|
36553
36805
|
xExtremes = xAxis.getExtremes();
|
|
36554
36806
|
min = xExtremes.min;
|
|
36555
36807
|
max = xExtremes.max;
|
|
36556
|
-
updatingNames = xAxis.categories && !xAxis.names.length;
|
|
36808
|
+
updatingNames = !!(xAxis.categories && !xAxis.names.length);
|
|
36557
36809
|
}
|
|
36558
36810
|
// optionally filter out points outside the plot area
|
|
36559
36811
|
if (isCartesian &&
|
|
@@ -36687,7 +36939,7 @@
|
|
|
36687
36939
|
Series.prototype.generatePoints = function () {
|
|
36688
36940
|
var series = this,
|
|
36689
36941
|
options = series.options,
|
|
36690
|
-
dataOptions = options.data,
|
|
36942
|
+
dataOptions = (series.processedData || options.data),
|
|
36691
36943
|
processedXData = series.processedXData,
|
|
36692
36944
|
processedYData = series.processedYData,
|
|
36693
36945
|
PointClass = series.pointClass,
|
|
@@ -37020,8 +37272,16 @@
|
|
|
37020
37272
|
!xAxis.validatePositiveValue(xValue)) {
|
|
37021
37273
|
point.isNull = true;
|
|
37022
37274
|
}
|
|
37023
|
-
|
|
37275
|
+
/**
|
|
37276
|
+
* The translated X value for the point in terms of pixels. Relative
|
|
37277
|
+
* to the X axis position if the series has one, otherwise relative
|
|
37278
|
+
* to the plot area. Depending on the series type this value might
|
|
37279
|
+
* not be defined.
|
|
37280
|
+
* @name Highcharts.Point#plotX
|
|
37281
|
+
* @type {number|undefined}
|
|
37282
|
+
*/
|
|
37024
37283
|
point.plotX = plotX = correctFloat(// #5236
|
|
37284
|
+
// Get the plotX translation
|
|
37025
37285
|
limitedRange(xAxis.translate(// #3923
|
|
37026
37286
|
xValue, 0, 0, 0, 1, pointPlacement, this.type === 'flags')) // #3923
|
|
37027
37287
|
);
|
|
@@ -37082,6 +37342,14 @@
|
|
|
37082
37342
|
false,
|
|
37083
37343
|
true);
|
|
37084
37344
|
if (typeof translated !== 'undefined') {
|
|
37345
|
+
/**
|
|
37346
|
+
* The translated Y value for the point in terms of pixels.
|
|
37347
|
+
* Relative to the Y axis position if the series has one,
|
|
37348
|
+
* otherwise relative to the plot area. Depending on the
|
|
37349
|
+
* series type this value might not be defined.
|
|
37350
|
+
* @name Highcharts.Point#plotY
|
|
37351
|
+
* @type {number|undefined}
|
|
37352
|
+
*/
|
|
37085
37353
|
point.plotY = limitedRange(translated);
|
|
37086
37354
|
}
|
|
37087
37355
|
}
|
|
@@ -37096,10 +37364,7 @@
|
|
|
37096
37364
|
threshold ||
|
|
37097
37365
|
0);
|
|
37098
37366
|
// some API data
|
|
37099
|
-
point.category = (categories &&
|
|
37100
|
-
typeof categories[point.x] !== 'undefined' ?
|
|
37101
|
-
categories[point.x] :
|
|
37102
|
-
point.x);
|
|
37367
|
+
point.category = pick(categories && categories[point.x], point.x);
|
|
37103
37368
|
// Determine auto enabling of markers (#3635, #5099)
|
|
37104
37369
|
if (!point.isNull && point.visible !== false) {
|
|
37105
37370
|
if (typeof lastPlotX !== 'undefined') {
|
|
@@ -37450,26 +37715,26 @@
|
|
|
37450
37715
|
var seriesStateOptions,
|
|
37451
37716
|
pointStateOptions,
|
|
37452
37717
|
radius = pick(pointMarkerOptions.radius,
|
|
37453
|
-
seriesMarkerOptions.radius);
|
|
37718
|
+
seriesMarkerOptions && seriesMarkerOptions.radius);
|
|
37454
37719
|
// Handle hover and select states
|
|
37455
37720
|
if (state) {
|
|
37456
37721
|
seriesStateOptions = seriesMarkerOptions.states[state];
|
|
37457
37722
|
pointStateOptions = pointMarkerOptions.states &&
|
|
37458
37723
|
pointMarkerOptions.states[state];
|
|
37459
|
-
radius = pick(pointStateOptions && pointStateOptions.radius, seriesStateOptions && seriesStateOptions.radius, radius + (seriesStateOptions && seriesStateOptions.radiusPlus ||
|
|
37724
|
+
radius = pick(pointStateOptions && pointStateOptions.radius, seriesStateOptions && seriesStateOptions.radius, radius && radius + (seriesStateOptions && seriesStateOptions.radiusPlus ||
|
|
37460
37725
|
0));
|
|
37461
37726
|
}
|
|
37462
37727
|
point.hasImage = symbol && symbol.indexOf('url') === 0;
|
|
37463
37728
|
if (point.hasImage) {
|
|
37464
37729
|
radius = 0; // and subsequently width and height is not set
|
|
37465
37730
|
}
|
|
37466
|
-
var attribs = {
|
|
37731
|
+
var attribs = isNumber(radius) ? {
|
|
37467
37732
|
// Math.floor for #1843:
|
|
37468
37733
|
x: seriesOptions.crisp ?
|
|
37469
37734
|
Math.floor(point.plotX - radius) :
|
|
37470
37735
|
point.plotX - radius,
|
|
37471
37736
|
y: point.plotY - radius
|
|
37472
|
-
};
|
|
37737
|
+
} : {};
|
|
37473
37738
|
if (radius) {
|
|
37474
37739
|
attribs.width = attribs.height = 2 * radius;
|
|
37475
37740
|
}
|
|
@@ -37559,7 +37824,7 @@
|
|
|
37559
37824
|
point,
|
|
37560
37825
|
axis;
|
|
37561
37826
|
// add event hook
|
|
37562
|
-
fireEvent(series, 'destroy');
|
|
37827
|
+
fireEvent(series, 'destroy', { keepEventsForUpdate: keepEventsForUpdate });
|
|
37563
37828
|
// remove events
|
|
37564
37829
|
this.removeEvents(keepEventsForUpdate);
|
|
37565
37830
|
// erase from axes
|
|
@@ -37746,10 +38011,10 @@
|
|
|
37746
38011
|
else if (series.visible) {
|
|
37747
38012
|
// If zones were removed, restore graph and area
|
|
37748
38013
|
if (graph) {
|
|
37749
|
-
graph.show(
|
|
38014
|
+
graph.show();
|
|
37750
38015
|
}
|
|
37751
38016
|
if (area) {
|
|
37752
|
-
area.show(
|
|
38017
|
+
area.show();
|
|
37753
38018
|
}
|
|
37754
38019
|
}
|
|
37755
38020
|
};
|
|
@@ -38243,7 +38508,7 @@
|
|
|
38243
38508
|
else if (series.graph) { // create
|
|
38244
38509
|
series.tracker = renderer.path(trackerPath)
|
|
38245
38510
|
.attr({
|
|
38246
|
-
visibility: series.visible ? '
|
|
38511
|
+
visibility: series.visible ? 'inherit' : 'hidden',
|
|
38247
38512
|
zIndex: 2
|
|
38248
38513
|
})
|
|
38249
38514
|
.addClass(trackByArea ?
|
|
@@ -38369,7 +38634,10 @@
|
|
|
38369
38634
|
names[x] = point.name;
|
|
38370
38635
|
}
|
|
38371
38636
|
dataOptions.splice(i, 0, options);
|
|
38372
|
-
if (isInTheMiddle
|
|
38637
|
+
if (isInTheMiddle ||
|
|
38638
|
+
// When processedData is present we need to splice an empty slot
|
|
38639
|
+
// into series.data, otherwise generatePoints won't pick it up.
|
|
38640
|
+
series.processedData) {
|
|
38373
38641
|
series.data.splice(i, 0, null);
|
|
38374
38642
|
series.processData();
|
|
38375
38643
|
}
|
|
@@ -38574,6 +38842,8 @@
|
|
|
38574
38842
|
typeof options.pointStart !== 'undefined' ||
|
|
38575
38843
|
typeof options.pointInterval !== 'undefined' ||
|
|
38576
38844
|
typeof options.relativeXValue !== 'undefined' ||
|
|
38845
|
+
options.joinBy ||
|
|
38846
|
+
options.mapData || // #11636
|
|
38577
38847
|
// Changes to data grouping requires new points in new group
|
|
38578
38848
|
series.hasOptionChanged('dataGrouping') ||
|
|
38579
38849
|
series.hasOptionChanged('pointStart') ||
|
|
@@ -38582,9 +38852,12 @@
|
|
|
38582
38852
|
series.hasOptionChanged('keys'));
|
|
38583
38853
|
newType = newType || initialType;
|
|
38584
38854
|
if (keepPoints) {
|
|
38585
|
-
preserve.push('data', 'isDirtyData', 'points', '
|
|
38855
|
+
preserve.push('data', 'isDirtyData', 'points', 'processedData', // #17057
|
|
38856
|
+
'processedXData', 'processedYData', 'xIncrement', 'cropped', '_hasPointMarkers', '_hasPointLabels', 'clips', // #15420
|
|
38586
38857
|
// Networkgraph (#14397)
|
|
38587
38858
|
'nodes', 'layout',
|
|
38859
|
+
// Treemap
|
|
38860
|
+
'level',
|
|
38588
38861
|
// Map specific, consider moving it to series-specific preserve-
|
|
38589
38862
|
// properties (#10617)
|
|
38590
38863
|
'mapMap', 'mapData', 'minY', 'maxY', 'minX', 'maxX');
|
|
@@ -38636,8 +38909,6 @@
|
|
|
38636
38909
|
series.remove(false, false, false, true);
|
|
38637
38910
|
if (casting) {
|
|
38638
38911
|
// Modern browsers including IE11
|
|
38639
|
-
// @todo slow, consider alternatives mentioned:
|
|
38640
|
-
// https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/setPrototypeOf
|
|
38641
38912
|
if (Object.setPrototypeOf) {
|
|
38642
38913
|
Object.setPrototypeOf(series, seriesTypes[newType].prototype);
|
|
38643
38914
|
// Legacy (IE < 11)
|
|
@@ -39696,7 +39967,7 @@
|
|
|
39696
39967
|
.addClass('highcharts-scrollable-mask')
|
|
39697
39968
|
.add();
|
|
39698
39969
|
addEvent(this, 'afterShowResetZoom', this.moveFixedElements);
|
|
39699
|
-
addEvent(this, '
|
|
39970
|
+
addEvent(this, 'afterApplyDrilldown', this.moveFixedElements);
|
|
39700
39971
|
addEvent(this, 'afterLayOutTitles', this.moveFixedElements);
|
|
39701
39972
|
}
|
|
39702
39973
|
else {
|
|
@@ -39824,6 +40095,7 @@
|
|
|
39824
40095
|
* area will become scrollable.
|
|
39825
40096
|
*
|
|
39826
40097
|
* @type {number}
|
|
40098
|
+
* @since 7.1.2
|
|
39827
40099
|
* @apioption chart.scrollablePlotArea.minHeight
|
|
39828
40100
|
*/
|
|
39829
40101
|
/**
|
|
@@ -39831,6 +40103,7 @@
|
|
|
39831
40103
|
* area will become scrollable.
|
|
39832
40104
|
*
|
|
39833
40105
|
* @type {number}
|
|
40106
|
+
* @since 6.1.0
|
|
39834
40107
|
* @apioption chart.scrollablePlotArea.minWidth
|
|
39835
40108
|
*/
|
|
39836
40109
|
/**
|
|
@@ -39839,6 +40112,7 @@
|
|
|
39839
40112
|
* Typically we would use 1 if the chart has right aligned Y axes.
|
|
39840
40113
|
*
|
|
39841
40114
|
* @type {number}
|
|
40115
|
+
* @since 6.1.0
|
|
39842
40116
|
* @apioption chart.scrollablePlotArea.scrollPositionX
|
|
39843
40117
|
*/
|
|
39844
40118
|
/**
|
|
@@ -39846,6 +40120,7 @@
|
|
|
39846
40120
|
* 1, where 0 aligns the plot area to the top and 1 aligns it to the bottom.
|
|
39847
40121
|
*
|
|
39848
40122
|
* @type {number}
|
|
40123
|
+
* @since 7.1.2
|
|
39849
40124
|
* @apioption chart.scrollablePlotArea.scrollPositionY
|
|
39850
40125
|
*/
|
|
39851
40126
|
/**
|
|
@@ -40063,7 +40338,6 @@
|
|
|
40063
40338
|
renderer
|
|
40064
40339
|
.g('stack-labels')
|
|
40065
40340
|
.attr({
|
|
40066
|
-
visibility: 'visible',
|
|
40067
40341
|
zIndex: 6,
|
|
40068
40342
|
opacity: 0
|
|
40069
40343
|
})
|
|
@@ -40299,7 +40573,7 @@
|
|
|
40299
40573
|
}
|
|
40300
40574
|
else {
|
|
40301
40575
|
// Move label away to avoid the overlapping issues
|
|
40302
|
-
label.
|
|
40576
|
+
label.hide();
|
|
40303
40577
|
isJustify = false;
|
|
40304
40578
|
}
|
|
40305
40579
|
if (isJustify) {
|
|
@@ -40586,11 +40860,12 @@
|
|
|
40586
40860
|
// changed:
|
|
40587
40861
|
if (!defined(stackIndicator) ||
|
|
40588
40862
|
stackIndicator.x !== x ||
|
|
40589
|
-
(key && stackIndicator.
|
|
40863
|
+
(key && stackIndicator.stackKey !== key)) {
|
|
40590
40864
|
stackIndicator = {
|
|
40591
40865
|
x: x,
|
|
40592
40866
|
index: 0,
|
|
40593
|
-
key: key
|
|
40867
|
+
key: key,
|
|
40868
|
+
stackKey: key
|
|
40594
40869
|
};
|
|
40595
40870
|
}
|
|
40596
40871
|
else {
|
|
@@ -42600,8 +42875,9 @@
|
|
|
42600
42875
|
var _this = this;
|
|
42601
42876
|
var stacking = this.options.stacking;
|
|
42602
42877
|
if (!point.isNull && metrics.columnCount > 1) {
|
|
42603
|
-
var
|
|
42604
|
-
var
|
|
42878
|
+
var reversedStacks_1 = this.yAxis.options.reversedStacks;
|
|
42879
|
+
var indexInCategory_1 = 0,
|
|
42880
|
+
totalInCategory_1 = reversedStacks_1 ? 0 : -metrics.columnCount;
|
|
42605
42881
|
// Loop over all the stacks on the Y axis. When stacking is enabled,
|
|
42606
42882
|
// these are real point stacks. When stacking is not enabled, but
|
|
42607
42883
|
// `centerInCategory` is true, there is one stack handling the
|
|
@@ -42622,7 +42898,8 @@
|
|
|
42622
42898
|
indexInCategory_1 = totalInCategory_1;
|
|
42623
42899
|
}
|
|
42624
42900
|
if (stackItem.hasValidPoints) {
|
|
42625
|
-
|
|
42901
|
+
reversedStacks_1 ? // #16169
|
|
42902
|
+
totalInCategory_1++ : totalInCategory_1--;
|
|
42626
42903
|
}
|
|
42627
42904
|
// If `stacking` is not enabled, look for the index
|
|
42628
42905
|
// and total of the `group` stack.
|
|
@@ -43602,17 +43879,18 @@
|
|
|
43602
43879
|
inverted = this.isCartesian && chart.inverted,
|
|
43603
43880
|
enabledDataSorting = this.enabledDataSorting,
|
|
43604
43881
|
plotX = pick(point.dlBox && point.dlBox.centerX,
|
|
43605
|
-
point.plotX
|
|
43606
|
-
plotY =
|
|
43607
|
-
bBox = dataLabel.getBBox(),
|
|
43882
|
+
point.plotX),
|
|
43883
|
+
plotY = point.plotY,
|
|
43608
43884
|
rotation = options.rotation,
|
|
43609
43885
|
align = options.align,
|
|
43610
|
-
isInsidePlot =
|
|
43886
|
+
isInsidePlot = defined(plotX) &&
|
|
43887
|
+
defined(plotY) &&
|
|
43888
|
+
chart.isInsidePlot(plotX,
|
|
43611
43889
|
Math.round(plotY), {
|
|
43612
|
-
|
|
43613
|
-
|
|
43614
|
-
|
|
43615
|
-
|
|
43890
|
+
inverted: inverted,
|
|
43891
|
+
paneCoordinates: true,
|
|
43892
|
+
series: series
|
|
43893
|
+
}),
|
|
43616
43894
|
setStartPos = function (alignOptions) {
|
|
43617
43895
|
if (enabledDataSorting && series.xAxis && !justify) {
|
|
43618
43896
|
series.setDataLabelStartPos(point,
|
|
@@ -43623,8 +43901,6 @@
|
|
|
43623
43901
|
}
|
|
43624
43902
|
};
|
|
43625
43903
|
var baseline,
|
|
43626
|
-
normRotation,
|
|
43627
|
-
negRotation,
|
|
43628
43904
|
rotCorr, // rotation correction
|
|
43629
43905
|
// Math.round for rounding errors (#2683), alignTo to allow column
|
|
43630
43906
|
// labels (#2700)
|
|
@@ -43648,7 +43924,12 @@
|
|
|
43648
43924
|
paneCoordinates: true,
|
|
43649
43925
|
series: series
|
|
43650
43926
|
})));
|
|
43651
|
-
if (visible) {
|
|
43927
|
+
if (visible && defined(plotX) && defined(plotY)) {
|
|
43928
|
+
if (rotation) {
|
|
43929
|
+
dataLabel.attr({ align: align });
|
|
43930
|
+
}
|
|
43931
|
+
var bBox = dataLabel.getBBox(true),
|
|
43932
|
+
bBoxCorrection = [0, 0];
|
|
43652
43933
|
baseline = chart.renderer.fontMetrics(chart.styledMode ? void 0 : options.style.fontSize, dataLabel).b;
|
|
43653
43934
|
// The alignment box is a singular point
|
|
43654
43935
|
alignTo = extend({
|
|
@@ -43677,27 +43958,12 @@
|
|
|
43677
43958
|
{ top: 0, middle: 0.5, bottom: 1 }[options.verticalAlign] *
|
|
43678
43959
|
alignTo.height)
|
|
43679
43960
|
};
|
|
43961
|
+
bBoxCorrection = [
|
|
43962
|
+
bBox.x - Number(dataLabel.attr('x')),
|
|
43963
|
+
bBox.y - Number(dataLabel.attr('y'))
|
|
43964
|
+
];
|
|
43680
43965
|
setStartPos(alignAttr); // data sorting
|
|
43681
|
-
dataLabel[isNew ? 'attr' : 'animate'](alignAttr)
|
|
43682
|
-
.attr({
|
|
43683
|
-
align: align
|
|
43684
|
-
});
|
|
43685
|
-
// Compensate for the rotated label sticking out on the sides
|
|
43686
|
-
normRotation = (rotation + 720) % 360;
|
|
43687
|
-
negRotation = normRotation > 180 && normRotation < 360;
|
|
43688
|
-
if (align === 'left') {
|
|
43689
|
-
alignAttr.y -= negRotation ? bBox.height : 0;
|
|
43690
|
-
}
|
|
43691
|
-
else if (align === 'center') {
|
|
43692
|
-
alignAttr.x -= bBox.width / 2;
|
|
43693
|
-
alignAttr.y -= bBox.height / 2;
|
|
43694
|
-
}
|
|
43695
|
-
else if (align === 'right') {
|
|
43696
|
-
alignAttr.x -= bBox.width;
|
|
43697
|
-
alignAttr.y -= negRotation ? 0 : bBox.height;
|
|
43698
|
-
}
|
|
43699
|
-
dataLabel.placed = true;
|
|
43700
|
-
dataLabel.alignAttr = alignAttr;
|
|
43966
|
+
dataLabel[isNew ? 'attr' : 'animate'](alignAttr);
|
|
43701
43967
|
}
|
|
43702
43968
|
else {
|
|
43703
43969
|
setStartPos(alignTo); // data sorting
|
|
@@ -43710,12 +43976,37 @@
|
|
|
43710
43976
|
// Now check that the data label is within the plot area
|
|
43711
43977
|
}
|
|
43712
43978
|
else if (pick(options.crop, true)) {
|
|
43979
|
+
var x = alignAttr.x,
|
|
43980
|
+
y = alignAttr.y;
|
|
43981
|
+
x += bBoxCorrection[0];
|
|
43982
|
+
y += bBoxCorrection[1];
|
|
43983
|
+
// Uncomment this block to visualize the bounding boxes used for
|
|
43984
|
+
// determining visibility
|
|
43985
|
+
/*
|
|
43986
|
+
chart.renderer.rect(
|
|
43987
|
+
chart.plotLeft + alignAttr.x + bBox.x,
|
|
43988
|
+
chart.plotTop + alignAttr.y + bBox.y + 9999,
|
|
43989
|
+
bBox.width,
|
|
43990
|
+
bBox.height
|
|
43991
|
+
).attr({
|
|
43992
|
+
stroke: 'rgba(0, 0, 0, 0.3)',
|
|
43993
|
+
'stroke-width': 0.5
|
|
43994
|
+
}).add();
|
|
43995
|
+
chart.renderer.circle(
|
|
43996
|
+
chart.plotLeft + alignAttr.x,
|
|
43997
|
+
chart.plotTop + alignAttr.y,
|
|
43998
|
+
2
|
|
43999
|
+
).attr({
|
|
44000
|
+
fill: 'red',
|
|
44001
|
+
zIndex: 20
|
|
44002
|
+
}).add();
|
|
44003
|
+
// */
|
|
43713
44004
|
visible =
|
|
43714
|
-
chart.isInsidePlot(
|
|
44005
|
+
chart.isInsidePlot(x, y, {
|
|
43715
44006
|
paneCoordinates: true,
|
|
43716
44007
|
series: series
|
|
43717
44008
|
}) &&
|
|
43718
|
-
chart.isInsidePlot(
|
|
44009
|
+
chart.isInsidePlot(x + bBox.width, y + bBox.height, {
|
|
43719
44010
|
paneCoordinates: true,
|
|
43720
44011
|
series: series
|
|
43721
44012
|
});
|
|
@@ -43739,9 +44030,12 @@
|
|
|
43739
44030
|
}
|
|
43740
44031
|
// Show or hide based on the final aligned position
|
|
43741
44032
|
if (!visible && (!enabledDataSorting || justify)) {
|
|
43742
|
-
dataLabel.hide(
|
|
44033
|
+
dataLabel.hide();
|
|
43743
44034
|
dataLabel.placed = false; // don't animate back in
|
|
43744
44035
|
}
|
|
44036
|
+
else {
|
|
44037
|
+
dataLabel.show();
|
|
44038
|
+
}
|
|
43745
44039
|
}
|
|
43746
44040
|
/**
|
|
43747
44041
|
* Handle the dataLabels.filter option.
|
|
@@ -43818,7 +44112,7 @@
|
|
|
43818
44112
|
var group = series.dataLabelsGroup;
|
|
43819
44113
|
if (group) {
|
|
43820
44114
|
if (series.visible) { // #2597, #3023, #3024
|
|
43821
|
-
dataLabelsGroup.show(
|
|
44115
|
+
dataLabelsGroup.show();
|
|
43822
44116
|
}
|
|
43823
44117
|
group[seriesOptions.animation ? 'animate' : 'attr']({ opacity: 1 }, animationConfig);
|
|
43824
44118
|
}
|
|
@@ -43850,10 +44144,10 @@
|
|
|
43850
44144
|
rotation,
|
|
43851
44145
|
attr,
|
|
43852
44146
|
dataLabel = point.dataLabels ?
|
|
43853
|
-
point.dataLabels[i] : point.dataLabel
|
|
43854
|
-
var labelDistance = pick(labelOptions.distance,
|
|
43855
|
-
point.labelDistance),
|
|
44147
|
+
point.dataLabels[i] : point.dataLabel,
|
|
43856
44148
|
isNew = !dataLabel;
|
|
44149
|
+
var labelDistance = pick(labelOptions.distance,
|
|
44150
|
+
point.labelDistance);
|
|
43857
44151
|
if (labelEnabled) {
|
|
43858
44152
|
// Create individual options structure that can be
|
|
43859
44153
|
// extended without affecting others
|
|
@@ -43907,7 +44201,15 @@
|
|
|
43907
44201
|
// #820
|
|
43908
44202
|
if (dataLabel && (!labelEnabled ||
|
|
43909
44203
|
!defined(labelText) ||
|
|
43910
|
-
!!dataLabel.div !== !!labelOptions.useHTML
|
|
44204
|
+
!!dataLabel.div !== !!labelOptions.useHTML ||
|
|
44205
|
+
(
|
|
44206
|
+
// Change from no rotation to rotation and
|
|
44207
|
+
// vice versa. Don't use defined() because
|
|
44208
|
+
// rotation = 0 means also rotation = undefined
|
|
44209
|
+
(!dataLabel.rotation ||
|
|
44210
|
+
!labelOptions.rotation) &&
|
|
44211
|
+
dataLabel.rotation !== labelOptions.rotation))) {
|
|
44212
|
+
isNew = true;
|
|
43911
44213
|
point.dataLabel = dataLabel =
|
|
43912
44214
|
point.dataLabel && point.dataLabel.destroy();
|
|
43913
44215
|
if (point.dataLabels) {
|
|
@@ -43945,10 +44247,10 @@
|
|
|
43945
44247
|
point.dataLabels = point.dataLabels || [];
|
|
43946
44248
|
dataLabel = point.dataLabels[i] = rotation ?
|
|
43947
44249
|
// Labels don't rotate, use text element
|
|
43948
|
-
renderer.text(labelText, 0,
|
|
44250
|
+
renderer.text(labelText, 0, 0, labelOptions.useHTML)
|
|
43949
44251
|
.addClass('highcharts-data-label') :
|
|
43950
44252
|
// We can use label
|
|
43951
|
-
renderer.label(labelText, 0,
|
|
44253
|
+
renderer.label(labelText, 0, 0, labelOptions.shape, null, null, labelOptions.useHTML, null, 'data-label');
|
|
43952
44254
|
// Store for backwards compatibility
|
|
43953
44255
|
if (!i) {
|
|
43954
44256
|
point.dataLabel = dataLabel;
|
|
@@ -43989,6 +44291,9 @@
|
|
|
43989
44291
|
// we need to align it
|
|
43990
44292
|
series.alignDataLabel(point, dataLabel, labelOptions, null, isNew);
|
|
43991
44293
|
}
|
|
44294
|
+
else if (dataLabel) {
|
|
44295
|
+
dataLabel.hide();
|
|
44296
|
+
}
|
|
43992
44297
|
});
|
|
43993
44298
|
});
|
|
43994
44299
|
}
|
|
@@ -44661,7 +44966,7 @@
|
|
|
44661
44966
|
*
|
|
44662
44967
|
* @type {boolean}
|
|
44663
44968
|
* @default false
|
|
44664
|
-
* @product highcharts highstock
|
|
44969
|
+
* @product highcharts highstock highmaps
|
|
44665
44970
|
* @apioption plotOptions.scatter.stickyTracking
|
|
44666
44971
|
*/
|
|
44667
44972
|
/**
|
|
@@ -44827,7 +45132,8 @@
|
|
|
44827
45132
|
plotHeight = chart.plotHeight - 2 * slicingRoom,
|
|
44828
45133
|
centerOption = options.center,
|
|
44829
45134
|
smallestSize = Math.min(plotWidth,
|
|
44830
|
-
plotHeight)
|
|
45135
|
+
plotHeight),
|
|
45136
|
+
thickness = options.thickness;
|
|
44831
45137
|
var handleSlicingRoom,
|
|
44832
45138
|
size = options.size,
|
|
44833
45139
|
innerSize = options.innerSize || 0,
|
|
@@ -44864,6 +45170,11 @@
|
|
|
44864
45170
|
if (positions[3] > positions[2]) {
|
|
44865
45171
|
positions[3] = positions[2];
|
|
44866
45172
|
}
|
|
45173
|
+
// thickness overrides innerSize, need to be less than pie size (#6647)
|
|
45174
|
+
if (isNumber(thickness) &&
|
|
45175
|
+
thickness * 2 < positions[2] && thickness > 0) {
|
|
45176
|
+
positions[3] = positions[2] - thickness * 2;
|
|
45177
|
+
}
|
|
44867
45178
|
return positions;
|
|
44868
45179
|
}
|
|
44869
45180
|
CenteredUtilities.getCenter = getCenter;
|
|
@@ -45051,12 +45362,19 @@
|
|
|
45051
45362
|
return isNumber(this.y) && this.y >= 0;
|
|
45052
45363
|
};
|
|
45053
45364
|
/**
|
|
45054
|
-
* Toggle the visibility of
|
|
45055
|
-
*
|
|
45365
|
+
* Toggle the visibility of a pie slice or other data point. Note that this
|
|
45366
|
+
* method is available only for some series, like pie, treemap and sunburst.
|
|
45367
|
+
*
|
|
45368
|
+
* @function Highcharts.Point#setVisible
|
|
45369
|
+
*
|
|
45370
|
+
* @param {boolean} [vis]
|
|
45371
|
+
* True to show the pie slice or other data point, false to hide. If
|
|
45372
|
+
* undefined, the visibility is toggled.
|
|
45373
|
+
*
|
|
45374
|
+
* @param {boolean} [redraw] Whether to redraw the chart after the point is
|
|
45375
|
+
* altered. If doing more operations on the chart, it is a good idea to set
|
|
45376
|
+
* redraw to false and call {@link Chart#redraw|chart.redraw()} after.
|
|
45056
45377
|
*
|
|
45057
|
-
* @param {boolean} vis
|
|
45058
|
-
* Whether to show the slice or not. If undefined, the visibility is
|
|
45059
|
-
* toggled.
|
|
45060
45378
|
*/
|
|
45061
45379
|
PiePoint.prototype.setVisible = function (vis, redraw) {
|
|
45062
45380
|
var _this = this;
|
|
@@ -46000,6 +46318,17 @@
|
|
|
46000
46318
|
* @product highcharts
|
|
46001
46319
|
* @apioption plotOptions.pie.endAngle
|
|
46002
46320
|
*/
|
|
46321
|
+
/**
|
|
46322
|
+
* Thickness describing the ring size for a donut type chart,
|
|
46323
|
+
* overriding [innerSize](#plotOptions.pie.innerSize).
|
|
46324
|
+
*
|
|
46325
|
+
* @type {number}
|
|
46326
|
+
* @default undefined
|
|
46327
|
+
* @product highcharts
|
|
46328
|
+
* @since 10.1.0
|
|
46329
|
+
* @apioption plotOptions.pie.thickness
|
|
46330
|
+
* @private
|
|
46331
|
+
*/
|
|
46003
46332
|
/**
|
|
46004
46333
|
* Equivalent to [chart.ignoreHiddenSeries](#chart.ignoreHiddenSeries),
|
|
46005
46334
|
* this option tells whether the series shall be redrawn as if the
|
|
@@ -46027,7 +46356,7 @@
|
|
|
46027
46356
|
* The size of the inner diameter for the pie. A size greater than 0
|
|
46028
46357
|
* renders a donut chart. Can be a percentage or pixel value.
|
|
46029
46358
|
* Percentages are relative to the pie size. Pixel values are given as
|
|
46030
|
-
* integers.
|
|
46359
|
+
* integers. Setting overridden by thickness.
|
|
46031
46360
|
*
|
|
46032
46361
|
*
|
|
46033
46362
|
* Note: in Highcharts < 4.1.2, the percentage was relative to the plot
|
|
@@ -46789,7 +47118,9 @@
|
|
|
46789
47118
|
if (newSize < center[2]) {
|
|
46790
47119
|
center[2] = newSize;
|
|
46791
47120
|
center[3] = Math.min(// #3632
|
|
46792
|
-
|
|
47121
|
+
options.thickness ?
|
|
47122
|
+
Math.max(0, newSize - options.thickness * 2) :
|
|
47123
|
+
Math.max(0, relativeLength(options.innerSize || 0, newSize)), newSize); // #6647
|
|
46793
47124
|
this.translate(center);
|
|
46794
47125
|
if (this.drawDataLabels) {
|
|
46795
47126
|
this.drawDataLabels();
|
|
@@ -46852,9 +47183,7 @@
|
|
|
46852
47183
|
!yAxis.options.stackLabels.allowOverlap) {
|
|
46853
47184
|
objectEach(yAxis.stacking.stacks, function (stack) {
|
|
46854
47185
|
objectEach(stack, function (stackItem) {
|
|
46855
|
-
if (stackItem.label
|
|
46856
|
-
stackItem.label.visibility !== 'hidden' // #15607
|
|
46857
|
-
) {
|
|
47186
|
+
if (stackItem.label) {
|
|
46858
47187
|
labels.push(stackItem.label);
|
|
46859
47188
|
}
|
|
46860
47189
|
});
|
|
@@ -46998,7 +47327,10 @@
|
|
|
46998
47327
|
box2 &&
|
|
46999
47328
|
label1 !== label2 && // #6465, polar chart with connectEnds
|
|
47000
47329
|
label1.newOpacity !== 0 &&
|
|
47001
|
-
label2.newOpacity !== 0
|
|
47330
|
+
label2.newOpacity !== 0 &&
|
|
47331
|
+
// #15863 dataLabels are no longer hidden by translation
|
|
47332
|
+
label1.visibility !== 'hidden' &&
|
|
47333
|
+
label2.visibility !== 'hidden') {
|
|
47002
47334
|
if (isIntersectRect(box1, box2)) {
|
|
47003
47335
|
(label1.labelrank < label2.labelrank ? label1 : label2)
|
|
47004
47336
|
.newOpacity = 0;
|
|
@@ -47967,9 +48299,11 @@
|
|
|
47967
48299
|
// how many ordinal units did we move?
|
|
47968
48300
|
movedUnits = (mouseDownX - chartX) / pointPixelWidth,
|
|
47969
48301
|
// get index of all the chart's points
|
|
48302
|
+
extendedOrdinalPositions = xAxis.ordinal.getExtendedPositions(),
|
|
47970
48303
|
extendedAxis = {
|
|
47971
48304
|
ordinal: {
|
|
47972
|
-
positions:
|
|
48305
|
+
positions: extendedOrdinalPositions,
|
|
48306
|
+
extendedOrdinalPositions: extendedOrdinalPositions
|
|
47973
48307
|
}
|
|
47974
48308
|
},
|
|
47975
48309
|
index2val_1 = xAxis.index2val,
|
|
@@ -49100,6 +49434,7 @@
|
|
|
49100
49434
|
* @type {string}
|
|
49101
49435
|
* @since 1.0.1
|
|
49102
49436
|
* @product highstock
|
|
49437
|
+
* @validvalue ["percent", "value"]
|
|
49103
49438
|
* @apioption plotOptions.series.compare
|
|
49104
49439
|
*/
|
|
49105
49440
|
/**
|
|
@@ -50542,9 +50877,11 @@
|
|
|
50542
50877
|
Axis.prototype.applyGrouping = function (e) {
|
|
50543
50878
|
var axis = this,
|
|
50544
50879
|
series = axis.series;
|
|
50880
|
+
// Reset the groupPixelWidth for all series, #17141.
|
|
50545
50881
|
series.forEach(function (series) {
|
|
50546
|
-
// Reset the groupPixelWidth, then calculate if needed.
|
|
50547
50882
|
series.groupPixelWidth = void 0; // #2110
|
|
50883
|
+
});
|
|
50884
|
+
series.forEach(function (series) {
|
|
50548
50885
|
series.groupPixelWidth = (axis.getGroupPixelWidth &&
|
|
50549
50886
|
axis.getGroupPixelWidth());
|
|
50550
50887
|
if (series.groupPixelWidth) {
|
|
@@ -50631,8 +50968,11 @@
|
|
|
50631
50968
|
}
|
|
50632
50969
|
else {
|
|
50633
50970
|
this.chart.options.series.forEach(function (seriesOptions) {
|
|
50634
|
-
|
|
50635
|
-
|
|
50971
|
+
// Merging dataGrouping options with already defined options #16759
|
|
50972
|
+
seriesOptions.dataGrouping = typeof dataGrouping === 'boolean' ?
|
|
50973
|
+
dataGrouping :
|
|
50974
|
+
merge(dataGrouping, seriesOptions.dataGrouping);
|
|
50975
|
+
});
|
|
50636
50976
|
}
|
|
50637
50977
|
// Clear ordinal slope, so we won't accidentaly use the old one (#7827)
|
|
50638
50978
|
if (axis.ordinal) {
|
|
@@ -51883,6 +52223,13 @@
|
|
|
51883
52223
|
* @product highstock
|
|
51884
52224
|
* @apioption series.ohlc.data
|
|
51885
52225
|
*/
|
|
52226
|
+
/**
|
|
52227
|
+
* The closing value of each data point.
|
|
52228
|
+
*
|
|
52229
|
+
* @type {number}
|
|
52230
|
+
* @product highstock
|
|
52231
|
+
* @apioption series.ohlc.data.close
|
|
52232
|
+
*/
|
|
51886
52233
|
/**
|
|
51887
52234
|
* The opening value of each data point.
|
|
51888
52235
|
*
|
|
@@ -52827,23 +53174,20 @@
|
|
|
52827
53174
|
// depending on the label width or a hardcoded value, #16041.
|
|
52828
53175
|
distribute(boxes, inverted ? yAxis.len : this.xAxis.len, maxDistance_1);
|
|
52829
53176
|
points.forEach(function (point) {
|
|
52830
|
-
var
|
|
52831
|
-
|
|
52832
|
-
|
|
52833
|
-
|
|
52834
|
-
anchorX: point.anchorX
|
|
52835
|
-
});
|
|
53177
|
+
var plotX = point.plotX,
|
|
53178
|
+
graphic = point.graphic,
|
|
53179
|
+
box = graphic && boxesMap[plotX];
|
|
53180
|
+
if (box && graphic) {
|
|
52836
53181
|
// Hide flag when its box position is not specified
|
|
52837
53182
|
// (#8573, #9299)
|
|
52838
53183
|
if (!defined(box.pos)) {
|
|
52839
|
-
|
|
52840
|
-
x: -9999,
|
|
52841
|
-
anchorX: -9999
|
|
52842
|
-
});
|
|
52843
|
-
point.graphic.isNew = true;
|
|
53184
|
+
graphic.hide().isNew = true;
|
|
52844
53185
|
}
|
|
52845
53186
|
else {
|
|
52846
|
-
|
|
53187
|
+
graphic[graphic.isNew ? 'attr' : 'animate']({
|
|
53188
|
+
x: box.pos + (box.align || 0) * box.size,
|
|
53189
|
+
anchorX: point.anchorX
|
|
53190
|
+
}).show().isNew = false;
|
|
52847
53191
|
}
|
|
52848
53192
|
}
|
|
52849
53193
|
});
|
|
@@ -54095,6 +54439,8 @@
|
|
|
54095
54439
|
method = scroller.rendered ? 'animate' : 'attr';
|
|
54096
54440
|
var xOffset = height,
|
|
54097
54441
|
yOffset = 0;
|
|
54442
|
+
// Make the scrollbar visible when it is repositioned, #15763.
|
|
54443
|
+
scroller.group.show();
|
|
54098
54444
|
scroller.x = x;
|
|
54099
54445
|
scroller.y = y + this.trackBorderWidth;
|
|
54100
54446
|
scroller.width = width; // width with buttons
|
|
@@ -54154,10 +54500,12 @@
|
|
|
54154
54500
|
options = scroller.options,
|
|
54155
54501
|
size = scroller.size,
|
|
54156
54502
|
styledMode = scroller.chart.styledMode,
|
|
54157
|
-
group = renderer.g('scrollbar')
|
|
54158
|
-
|
|
54159
|
-
|
|
54160
|
-
})
|
|
54503
|
+
group = renderer.g('scrollbar')
|
|
54504
|
+
.attr({
|
|
54505
|
+
zIndex: options.zIndex
|
|
54506
|
+
})
|
|
54507
|
+
.hide() // initially hide the scrollbar #15863
|
|
54508
|
+
.add();
|
|
54161
54509
|
// Draw the scrollbar group
|
|
54162
54510
|
scroller.group = group;
|
|
54163
54511
|
// Draw the scrollbar track:
|
|
@@ -54285,7 +54633,7 @@
|
|
|
54285
54633
|
scroller.scrollbarRifles.hide();
|
|
54286
54634
|
}
|
|
54287
54635
|
else {
|
|
54288
|
-
scroller.scrollbarRifles.show(
|
|
54636
|
+
scroller.scrollbarRifles.show();
|
|
54289
54637
|
}
|
|
54290
54638
|
// Show or hide the scrollbar based on the showFull setting
|
|
54291
54639
|
if (options.showFull === false) {
|
|
@@ -55339,19 +55687,21 @@
|
|
|
55339
55687
|
maskInside,
|
|
55340
55688
|
!maskInside
|
|
55341
55689
|
].forEach(function (hasMask, index) {
|
|
55342
|
-
|
|
55343
|
-
|
|
55344
|
-
|
|
55345
|
-
|
|
55690
|
+
var shade = renderer.rect()
|
|
55691
|
+
.addClass('highcharts-navigator-mask' +
|
|
55692
|
+
(index === 1 ? '-inside' : '-outside'))
|
|
55693
|
+
.add(navigatorGroup);
|
|
55346
55694
|
if (!chart.styledMode) {
|
|
55347
|
-
|
|
55348
|
-
.attr({
|
|
55695
|
+
shade.attr({
|
|
55349
55696
|
fill: hasMask ?
|
|
55350
55697
|
navigatorOptions.maskFill :
|
|
55351
55698
|
'rgba(0,0,0,0)'
|
|
55352
|
-
})
|
|
55353
|
-
|
|
55699
|
+
});
|
|
55700
|
+
if (index === 1) {
|
|
55701
|
+
shade.css(mouseCursor);
|
|
55702
|
+
}
|
|
55354
55703
|
}
|
|
55704
|
+
navigator.shades[index] = shade;
|
|
55355
55705
|
});
|
|
55356
55706
|
// Create the outline:
|
|
55357
55707
|
navigator.outline = renderer.path()
|
|
@@ -55514,7 +55864,7 @@
|
|
|
55514
55864
|
zoomedMin = Math.round(navigator.zoomedMin);
|
|
55515
55865
|
if (navigatorEnabled) {
|
|
55516
55866
|
navigator.navigatorGroup.attr({
|
|
55517
|
-
visibility: '
|
|
55867
|
+
visibility: 'inherit'
|
|
55518
55868
|
});
|
|
55519
55869
|
// Place elements
|
|
55520
55870
|
verb = rendered && !navigator.hasDragged ? 'animate' : 'attr';
|
|
@@ -56319,7 +56669,8 @@
|
|
|
56319
56669
|
Navigator.prototype.getBaseSeriesMin = function (currentSeriesMin) {
|
|
56320
56670
|
return this.baseSeries.reduce(function (min, series) {
|
|
56321
56671
|
// (#10193)
|
|
56322
|
-
return Math.min(min, series.xData
|
|
56672
|
+
return Math.min(min, series.xData && series.xData.length ?
|
|
56673
|
+
series.xData[0] : min);
|
|
56323
56674
|
}, currentSeriesMin);
|
|
56324
56675
|
};
|
|
56325
56676
|
/**
|
|
@@ -59622,7 +59973,7 @@
|
|
|
59622
59973
|
text: text,
|
|
59623
59974
|
x: posx,
|
|
59624
59975
|
y: posy,
|
|
59625
|
-
visibility: isInside ? '
|
|
59976
|
+
visibility: isInside ? 'inherit' : 'hidden'
|
|
59626
59977
|
});
|
|
59627
59978
|
crossBox = crossLabel.getBBox();
|
|
59628
59979
|
// now it is placed we can correct its position
|