@progress/kendo-charts 2.7.2-dev.202502101310 → 2.7.2-develop.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/js/kendo-charts.js +1 -1
- package/dist/cdn/main.js +1 -1
- package/dist/es/barcode/barcode-validator.js +10 -12
- package/dist/es/barcode/barcode.js +84 -96
- package/dist/es/barcode/encodings/code11.js +41 -57
- package/dist/es/barcode/encodings/code128.js +222 -354
- package/dist/es/barcode/encodings/code39-extended.js +20 -34
- package/dist/es/barcode/encodings/code39.js +49 -75
- package/dist/es/barcode/encodings/code93-extended.js +12 -24
- package/dist/es/barcode/encodings/code93.js +52 -70
- package/dist/es/barcode/encodings/ean13.js +28 -42
- package/dist/es/barcode/encodings/ean8.js +8 -18
- package/dist/es/barcode/encodings/encoding.js +18 -24
- package/dist/es/barcode/encodings/main.js +13 -10
- package/dist/es/barcode/encodings/msi.js +56 -112
- package/dist/es/barcode/encodings/postnet.js +31 -45
- package/dist/es/barcode/surface-size.js +2 -2
- package/dist/es/chart/aggregates/aggregates.js +23 -23
- package/dist/es/chart/aggregates/default-aggregates.js +10 -18
- package/dist/es/chart/aggregates/series-aggregator.js +42 -54
- package/dist/es/chart/animations/bar-chart-animation.js +15 -26
- package/dist/es/chart/animations/bubble-animation.js +7 -17
- package/dist/es/chart/animations/clip-animation.js +13 -23
- package/dist/es/chart/animations/fade-in-animation.js +6 -16
- package/dist/es/chart/animations/pie-animation.js +6 -16
- package/dist/es/chart/api-elements/chart-axis.js +14 -22
- package/dist/es/chart/api-elements/chart-pane.js +10 -8
- package/dist/es/chart/api-elements/chart-plotarea.js +4 -10
- package/dist/es/chart/api-elements/find-axis-by-name.js +1 -1
- package/dist/es/chart/area-chart/area-chart.js +46 -60
- package/dist/es/chart/area-chart/area-segment.js +46 -52
- package/dist/es/chart/area-chart/spline-area-segment.js +12 -21
- package/dist/es/chart/area-chart/step-area-segment.js +6 -15
- package/dist/es/chart/axis-group-range-tracker.js +14 -20
- package/dist/es/chart/bar-chart/bar-chart.js +65 -80
- package/dist/es/chart/bar-chart/bar-label.js +25 -32
- package/dist/es/chart/bar-chart/bar.js +76 -91
- package/dist/es/chart/box-plot-chart/box-plot-chart.js +33 -48
- package/dist/es/chart/box-plot-chart/box-plot.js +55 -68
- package/dist/es/chart/box-plot-chart/vertical-box-plot.js +13 -23
- package/dist/es/chart/bubble-chart/bubble-chart.js +51 -64
- package/dist/es/chart/bubble-chart/bubble.js +21 -27
- package/dist/es/chart/bullet-chart/bullet-chart.js +45 -57
- package/dist/es/chart/bullet-chart/bullet.js +48 -57
- package/dist/es/chart/bullet-chart/target.js +1 -11
- package/dist/es/chart/candlestick-chart/candlestick-chart.js +41 -55
- package/dist/es/chart/candlestick-chart/candlestick.js +60 -69
- package/dist/es/chart/categorical-chart.js +178 -206
- package/dist/es/chart/chart-container.js +30 -39
- package/dist/es/chart/chart.js +641 -701
- package/dist/es/chart/constants.js +103 -103
- package/dist/es/chart/crosshair/crosshair-tooltip.js +22 -34
- package/dist/es/chart/crosshair/crosshair.js +39 -47
- package/dist/es/chart/donut-chart/donut-chart.js +36 -48
- package/dist/es/chart/donut-chart/donut-segment.js +12 -24
- package/dist/es/chart/error-bars/categorical-error-bar.js +5 -15
- package/dist/es/chart/error-bars/error-bar-base.js +37 -49
- package/dist/es/chart/error-bars/error-range-calculator.js +46 -56
- package/dist/es/chart/error-bars/scatter-error-bar.js +6 -16
- package/dist/es/chart/funnel-chart/funnel-chart.js +86 -103
- package/dist/es/chart/funnel-chart/funnel-segment.js +46 -54
- package/dist/es/chart/funnel-chart/pyramid-chart.js +5 -11
- package/dist/es/chart/heatmap-chart/color-scale.js +7 -9
- package/dist/es/chart/heatmap-chart/heatmap-chart.js +87 -110
- package/dist/es/chart/heatmap-chart/heatmap-point.js +72 -78
- package/dist/es/chart/highlight.js +26 -36
- package/dist/es/chart/layout/cluster-layout.js +16 -25
- package/dist/es/chart/layout/radar-cluster-layout.js +15 -24
- package/dist/es/chart/layout/radar-stack-layout.js +10 -22
- package/dist/es/chart/layout/stack-wrap.js +12 -24
- package/dist/es/chart/layout/utils.js +2 -2
- package/dist/es/chart/legend/legend-item-line-area.js +8 -19
- package/dist/es/chart/legend/legend-item-line.js +21 -31
- package/dist/es/chart/legend/legend-item-marker.js +18 -28
- package/dist/es/chart/legend/legend-item-square.js +8 -18
- package/dist/es/chart/legend/legend-item.js +91 -105
- package/dist/es/chart/legend/legend-layout.js +18 -25
- package/dist/es/chart/legend/legend.js +68 -92
- package/dist/es/chart/line-chart/line-chart.js +35 -48
- package/dist/es/chart/line-chart/line-point.js +90 -103
- package/dist/es/chart/line-chart/line-segment.js +23 -34
- package/dist/es/chart/line-chart/spline-segment.js +10 -20
- package/dist/es/chart/line-chart/step-line-mixin.js +14 -17
- package/dist/es/chart/line-chart/step-line-segment.js +4 -14
- package/dist/es/chart/mixins/accessibility-attributes-mixin.js +7 -7
- package/dist/es/chart/mixins/clip-animation-mixin.js +7 -7
- package/dist/es/chart/mixins/line-chart-mixin.js +27 -31
- package/dist/es/chart/mixins/note-mixin.js +3 -3
- package/dist/es/chart/mixins/pie-chart-mixin.js +9 -9
- package/dist/es/chart/mixins/plotarea-events-mixin.js +1 -1
- package/dist/es/chart/mixins/point-events-mixin.js +1 -1
- package/dist/es/chart/ohlc-chart/ohlc-chart.js +4 -14
- package/dist/es/chart/ohlc-chart/ohlc-point.js +15 -28
- package/dist/es/chart/pan-and-zoom/accept-key.js +3 -3
- package/dist/es/chart/pan-and-zoom/mousewheel-zoom.js +25 -33
- package/dist/es/chart/pan-and-zoom/pannable.js +29 -37
- package/dist/es/chart/pan-and-zoom/to-chart-axis-ranges.js +3 -3
- package/dist/es/chart/pan-and-zoom/zoom-selection.js +61 -70
- package/dist/es/chart/pane.js +71 -79
- package/dist/es/chart/pie-chart/pie-chart.js +153 -183
- package/dist/es/chart/pie-chart/pie-segment.js +82 -98
- package/dist/es/chart/plotarea/categorical-plotarea.js +285 -318
- package/dist/es/chart/plotarea/donut-plotarea.js +12 -22
- package/dist/es/chart/plotarea/funnel-plotarea.js +17 -27
- package/dist/es/chart/plotarea/heatmap-plotarea.js +139 -167
- package/dist/es/chart/plotarea/pie-plotarea.js +15 -25
- package/dist/es/chart/plotarea/plotarea-base.js +423 -462
- package/dist/es/chart/plotarea/plotarea-factory.js +15 -20
- package/dist/es/chart/plotarea/polar-plotarea-base.js +37 -51
- package/dist/es/chart/plotarea/polar-plotarea.js +39 -49
- package/dist/es/chart/plotarea/radar-plotarea.js +55 -65
- package/dist/es/chart/plotarea/xy-plotarea.js +111 -128
- package/dist/es/chart/polar-area-chart/polar-area-chart.js +22 -36
- package/dist/es/chart/polar-area-chart/polar-area-segment.js +7 -17
- package/dist/es/chart/polar-area-chart/spline-polar-area-segment.js +15 -25
- package/dist/es/chart/polar-line-chart/polar-line-chart.js +2 -11
- package/dist/es/chart/polar-scatter-chart/polar-scatter-chart.js +6 -16
- package/dist/es/chart/radar-area-chart/radar-area-chart.js +11 -21
- package/dist/es/chart/radar-area-chart/radar-area-segment.js +3 -13
- package/dist/es/chart/radar-area-chart/spline-radar-area-segment.js +3 -13
- package/dist/es/chart/radar-bar-chart/radar-bar-chart.js +19 -29
- package/dist/es/chart/radar-bar-chart/radar-segment.js +6 -12
- package/dist/es/chart/radar-line-chart/radar-line-chart.js +26 -35
- package/dist/es/chart/range-area-chart/range-area-chart.js +46 -58
- package/dist/es/chart/range-area-chart/range-area-point.js +55 -66
- package/dist/es/chart/range-area-chart/range-area-segment.js +19 -28
- package/dist/es/chart/range-area-chart/range-line-point.js +4 -14
- package/dist/es/chart/range-area-chart/spline-range-area-segment.js +11 -18
- package/dist/es/chart/range-area-chart/step-range-area-segment.js +7 -16
- package/dist/es/chart/range-bar-chart/range-bar-chart.js +18 -29
- package/dist/es/chart/range-bar-chart/range-bar.js +10 -23
- package/dist/es/chart/register-charts.js +20 -16
- package/dist/es/chart/scatter-charts/scatter-chart.js +100 -122
- package/dist/es/chart/scatter-charts/scatter-line-chart.js +15 -25
- package/dist/es/chart/selection.js +176 -201
- package/dist/es/chart/series-binder.js +55 -66
- package/dist/es/chart/theme/base-theme.js +75 -79
- package/dist/es/chart/theme/load-theme.js +52 -52
- package/dist/es/chart/tooltip/base-tooltip.js +17 -24
- package/dist/es/chart/tooltip/shared-tooltip.js +25 -31
- package/dist/es/chart/tooltip/tooltip.js +10 -20
- package/dist/es/chart/trendlines/calculate-moving-average.js +11 -13
- package/dist/es/chart/trendlines/calculate-polynomial.js +24 -26
- package/dist/es/chart/trendlines/calculate-slope.js +12 -14
- package/dist/es/chart/trendlines/check-all-positive.js +2 -5
- package/dist/es/chart/trendlines/exponential-trendline.js +15 -24
- package/dist/es/chart/trendlines/get-scatter-trendline-data.js +6 -7
- package/dist/es/chart/trendlines/get-trendline-data.js +6 -6
- package/dist/es/chart/trendlines/linear-trendline.js +12 -21
- package/dist/es/chart/trendlines/logarithmic-trendline.js +14 -23
- package/dist/es/chart/trendlines/moving-average.js +15 -26
- package/dist/es/chart/trendlines/polynomial-trendline.js +13 -21
- package/dist/es/chart/trendlines/power-trendline.js +15 -24
- package/dist/es/chart/trendlines/scatter-exponential-trendline.js +15 -24
- package/dist/es/chart/trendlines/scatter-linear-trendline.js +10 -16
- package/dist/es/chart/trendlines/scatter-logarithmic-trendline.js +17 -27
- package/dist/es/chart/trendlines/scatter-moving-average.js +7 -10
- package/dist/es/chart/trendlines/scatter-polynomial-trendline.js +11 -16
- package/dist/es/chart/trendlines/scatter-power-trendline.js +15 -22
- package/dist/es/chart/trendlines/scatter-trendline-registry.js +1 -1
- package/dist/es/chart/trendlines/scatter-value-getter.js +2 -5
- package/dist/es/chart/trendlines/trendline-factory.js +1 -1
- package/dist/es/chart/trendlines/trendline-registry.js +1 -1
- package/dist/es/chart/trendlines/x-value-limits.js +6 -8
- package/dist/es/chart/utils/any-has-z-index.js +1 -1
- package/dist/es/chart/utils/bind-segments.js +8 -8
- package/dist/es/chart/utils/categories-count.js +3 -3
- package/dist/es/chart/utils/count-numbers.js +4 -4
- package/dist/es/chart/utils/create-out-of-range-points.js +13 -22
- package/dist/es/chart/utils/eval-options.js +7 -10
- package/dist/es/chart/utils/filter-series-by-type.js +4 -4
- package/dist/es/chart/utils/get-field.js +1 -1
- package/dist/es/chart/utils/has-gradient-overlay.js +1 -1
- package/dist/es/chart/utils/is-date-axis.js +2 -2
- package/dist/es/chart/utils/parse-date-category.js +2 -2
- package/dist/es/chart/utils/segment-visible.js +2 -2
- package/dist/es/chart/waterfall-chart/waterfall-chart.js +41 -55
- package/dist/es/chart/waterfall-chart/waterfall-segment.js +16 -24
- package/dist/es/chart-wizard/get-wizard-data-from-data-rows.js +5 -6
- package/dist/es/chart-wizard/messages.js +1 -1
- package/dist/es/chart-wizard/state.js +145 -137
- package/dist/es/chart-wizard.js +12 -12
- package/dist/es/common/add-class.js +3 -3
- package/dist/es/common/align-path-to-pixel.js +2 -2
- package/dist/es/common/auto-text-color.js +1 -1
- package/dist/es/common/constants.js +53 -53
- package/dist/es/common/create-hash-set.js +59 -65
- package/dist/es/common/cycleDown.js +1 -1
- package/dist/es/common/deep-extend.js +10 -12
- package/dist/es/common/element-scale.js +9 -9
- package/dist/es/common/element-styles.js +8 -8
- package/dist/es/common/event-map.js +4 -4
- package/dist/es/common/event-utils.js +13 -13
- package/dist/es/common/find.js +2 -2
- package/dist/es/common/font-loader.js +42 -44
- package/dist/es/common/get-aria-template.js +2 -4
- package/dist/es/common/get-spacing.js +2 -4
- package/dist/es/common/get-supported-features.js +7 -7
- package/dist/es/common/get-template.js +2 -4
- package/dist/es/common/getter.js +5 -5
- package/dist/es/common/grep.js +3 -3
- package/dist/es/common/has-classes.js +2 -2
- package/dist/es/common/hash-map.js +11 -11
- package/dist/es/common/instance-observer.js +28 -33
- package/dist/es/common/keys.js +1 -1
- package/dist/es/common/map.js +4 -4
- package/dist/es/common/matrix.js +142 -150
- package/dist/es/common/mousewheel-delta.js +2 -2
- package/dist/es/common/observable.js +40 -52
- package/dist/es/common/remove-class.js +1 -1
- package/dist/es/common/render-icon.js +50 -60
- package/dist/es/common/set-default-options.js +1 -1
- package/dist/es/common/sparse-array-limits.js +4 -4
- package/dist/es/common/user-events.js +124 -150
- package/dist/es/core/axis-label.js +38 -43
- package/dist/es/core/axis.js +293 -345
- package/dist/es/core/box-element.js +36 -46
- package/dist/es/core/box.js +75 -83
- package/dist/es/core/category-axis.js +265 -314
- package/dist/es/core/chart-element.js +98 -109
- package/dist/es/core/constants.js +3 -3
- package/dist/es/core/curve-processor.js +86 -93
- package/dist/es/core/date-category-axis.js +381 -413
- package/dist/es/core/date-value-axis.js +108 -118
- package/dist/es/core/float-element.js +54 -78
- package/dist/es/core/gradients.js +3 -3
- package/dist/es/core/logarithmic-axis.js +134 -186
- package/dist/es/core/mixins/grid-lines-mixin.js +18 -20
- package/dist/es/core/mixins/radar-numeric-axis-mixin.js +46 -51
- package/dist/es/core/note.js +58 -73
- package/dist/es/core/numeric-axis.js +111 -133
- package/dist/es/core/pattern.js +4 -8
- package/dist/es/core/point.js +25 -34
- package/dist/es/core/polar-axis.js +73 -91
- package/dist/es/core/radar-category-axis.js +90 -114
- package/dist/es/core/radar-logarithmic-axis.js +10 -20
- package/dist/es/core/radar-numeric-axis.js +10 -20
- package/dist/es/core/ring.js +61 -68
- package/dist/es/core/root-element.js +40 -48
- package/dist/es/core/sector.js +11 -17
- package/dist/es/core/shape-builder.js +13 -23
- package/dist/es/core/shape-element.js +27 -37
- package/dist/es/core/text-box.js +50 -59
- package/dist/es/core/text.js +13 -24
- package/dist/es/core/title.js +19 -25
- package/dist/es/core/utils/auto-axis-max.js +3 -3
- package/dist/es/core/utils/auto-axis-min.js +3 -3
- package/dist/es/core/utils/auto-major-unit.js +4 -4
- package/dist/es/core/utils/box-diff.js +9 -9
- package/dist/es/core/utils/create-axis-grid-line.js +2 -4
- package/dist/es/core/utils/create-axis-tick.js +2 -4
- package/dist/es/core/utils/guid.js +3 -3
- package/dist/es/core/utils/rect-to-box.js +2 -2
- package/dist/es/date-utils/absolute-date-diff.js +2 -2
- package/dist/es/date-utils/add-duration.js +5 -5
- package/dist/es/date-utils/ceil-date.js +1 -1
- package/dist/es/date-utils/constants.js +17 -17
- package/dist/es/date-utils/date-index.js +3 -3
- package/dist/es/date-utils/duration.js +1 -1
- package/dist/es/date-utils/lte-date-index.js +4 -4
- package/dist/es/date-utils/parse-date.js +1 -1
- package/dist/es/date-utils/parse-dates.js +2 -2
- package/dist/es/date-utils/start-of-week.js +3 -5
- package/dist/es/date-utils/to-date.js +1 -1
- package/dist/es/date-utils/to-time.js +2 -2
- package/dist/es/drawing-utils.js +18 -17
- package/dist/es/gauges/arc/arc-gauge.js +29 -38
- package/dist/es/gauges/arc/arc-scale.js +16 -29
- package/dist/es/gauges/arc/range-pointer-animation.js +16 -25
- package/dist/es/gauges/arc/range-pointer.js +25 -46
- package/dist/es/gauges/circular/circular-gauge.js +7 -17
- package/dist/es/gauges/constants.js +14 -14
- package/dist/es/gauges/gauge.js +84 -96
- package/dist/es/gauges/linear/arrow-linear-pointer-animation.js +13 -25
- package/dist/es/gauges/linear/arrow-linear-pointer.js +23 -35
- package/dist/es/gauges/linear/bar-linear-pointer-animation.js +15 -24
- package/dist/es/gauges/linear/bar-linear-pointer.js +38 -51
- package/dist/es/gauges/linear/linear-gauge.js +61 -83
- package/dist/es/gauges/linear/linear-pointer.js +25 -39
- package/dist/es/gauges/linear/linear-scale.js +57 -74
- package/dist/es/gauges/pointer.js +11 -21
- package/dist/es/gauges/radial/radial-gauge.js +58 -81
- package/dist/es/gauges/radial/radial-pointer-animation.js +9 -15
- package/dist/es/gauges/radial/radial-pointer.js +33 -48
- package/dist/es/gauges/radial/radial-scale.js +154 -186
- package/dist/es/gauges/utils/build-label-element.js +10 -12
- package/dist/es/gauges/utils/get-range.js +2 -2
- package/dist/es/gauges/utils/pad.js +3 -3
- package/dist/es/gauges/utils/unpad.js +1 -1
- package/dist/es/map/attribution.js +42 -52
- package/dist/es/map/constants.js +5 -5
- package/dist/es/map/crs.js +68 -112
- package/dist/es/map/datums.js +3 -3
- package/dist/es/map/extent.js +40 -54
- package/dist/es/map/layers/bubble.js +52 -70
- package/dist/es/map/layers/layer.js +50 -56
- package/dist/es/map/layers/marker.js +109 -129
- package/dist/es/map/layers/shape.js +111 -133
- package/dist/es/map/layers/tile.js +144 -170
- package/dist/es/map/location.js +70 -78
- package/dist/es/map/map.js +261 -291
- package/dist/es/map/navigator.js +33 -39
- package/dist/es/map/scroller/draggable.js +98 -134
- package/dist/es/map/scroller/fx.js +39 -46
- package/dist/es/map/scroller/scroller.js +144 -174
- package/dist/es/map/tooltip/tooltip.js +15 -25
- package/dist/es/map/utils.js +25 -26
- package/dist/es/map/zoom.js +30 -36
- package/dist/es/qrcode/encodings/data-modes/alpha-numeric-data-mode.js +14 -26
- package/dist/es/qrcode/encodings/data-modes/byte-data-mode.js +15 -25
- package/dist/es/qrcode/encodings/data-modes/data-mode-instances.js +8 -7
- package/dist/es/qrcode/encodings/data-modes/numeric-data-mode.js +14 -24
- package/dist/es/qrcode/encodings/data-modes/qr-data-mode.js +15 -21
- package/dist/es/qrcode/encodings/encoders/iso-encoder.js +6 -16
- package/dist/es/qrcode/encodings/encoders/utf8-encoder.js +28 -36
- package/dist/es/qrcode/encodings/encoding-result.js +4 -10
- package/dist/es/qrcode/encodings/encoding.js +68 -192
- package/dist/es/qrcode/encodings/free-cell-visitor.js +16 -24
- package/dist/es/qrcode/encodings/utils/choose-mode.js +44 -0
- package/dist/es/qrcode/encodings/utils/get-data-codewords-count.js +13 -0
- package/dist/es/qrcode/encodings/utils/get-data-string.js +13 -0
- package/dist/es/qrcode/encodings/utils/get-modes.js +35 -0
- package/dist/es/qrcode/encodings/utils/get-version.js +23 -0
- package/dist/es/qrcode/encodings/utils/index.js +5 -0
- package/dist/es/qrcode/encodings/version-codewords.js +1 -1
- package/dist/es/qrcode/qrcode-validator.js +3 -5
- package/dist/es/qrcode/qrcode.js +104 -114
- package/dist/es/qrcode/utils.js +4 -4
- package/dist/es/sankey/calculation.js +286 -307
- package/dist/es/sankey/element.js +15 -23
- package/dist/es/sankey/label.js +29 -44
- package/dist/es/sankey/legend.js +15 -29
- package/dist/es/sankey/link.js +80 -98
- package/dist/es/sankey/node.js +26 -37
- package/dist/es/sankey/sankey.js +318 -385
- package/dist/es/sankey/title.js +9 -20
- package/dist/es/sankey/utils.js +18 -23
- package/dist/es/services/chart-service.js +24 -28
- package/dist/es/services/dom-events-builder.js +15 -15
- package/dist/es/services/format-service.js +30 -35
- package/dist/es/services/intl-service.js +14 -18
- package/dist/es/services/map-service.js +11 -11
- package/dist/es/services/template-service.js +9 -9
- package/dist/es/sparkline/shared-tooltip.js +11 -21
- package/dist/es/sparkline/sparkline.js +50 -60
- package/dist/es/stock/constants.js +3 -3
- package/dist/es/stock/fade-out-animation.js +12 -21
- package/dist/es/stock/navigator-hint.js +37 -49
- package/dist/es/stock/navigator.js +130 -161
- package/dist/es/stock/stock-chart.js +58 -67
- package/dist/es2015/chart/legend/legend-item.js +1 -1
- package/dist/es2015/qrcode/encodings/encoders/iso-encoder.js +1 -1
- package/dist/es2015/qrcode/encodings/encoders/utf8-encoder.js +1 -1
- package/dist/es2015/qrcode/encodings/encoding.js +3 -127
- package/dist/es2015/qrcode/encodings/utils/choose-mode.js +44 -0
- package/dist/es2015/qrcode/encodings/utils/get-data-codewords-count.js +13 -0
- package/dist/es2015/qrcode/encodings/utils/get-data-string.js +13 -0
- package/dist/es2015/qrcode/encodings/utils/get-modes.js +35 -0
- package/dist/es2015/qrcode/encodings/utils/get-version.js +23 -0
- package/dist/es2015/qrcode/encodings/utils/index.js +5 -0
- package/dist/npm/main.js +3222 -3589
- package/dist/systemjs/kendo-charts.js +1 -1
- package/package.json +19 -57
|
@@ -1,22 +1,14 @@
|
|
|
1
1
|
import PiePlotArea from './pie-plotarea';
|
|
2
2
|
import DonutChart from '../donut-chart/donut-chart';
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
PiePlotArea.apply(this, arguments);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
if ( PiePlotArea ) DonutPlotArea.__proto__ = PiePlotArea;
|
|
10
|
-
DonutPlotArea.prototype = Object.create( PiePlotArea && PiePlotArea.prototype );
|
|
11
|
-
DonutPlotArea.prototype.constructor = DonutPlotArea;
|
|
12
|
-
|
|
13
|
-
DonutPlotArea.prototype.render = function render () {
|
|
4
|
+
class DonutPlotArea extends PiePlotArea {
|
|
5
|
+
render() {
|
|
14
6
|
this.createDonutChart(this.series);
|
|
15
|
-
}
|
|
7
|
+
}
|
|
16
8
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
9
|
+
createDonutChart(series) {
|
|
10
|
+
const firstSeries = series[0];
|
|
11
|
+
const donutChart = new DonutChart(this, {
|
|
20
12
|
series: series,
|
|
21
13
|
padding: firstSeries.padding,
|
|
22
14
|
connectors: firstSeries.connectors,
|
|
@@ -24,18 +16,16 @@ var DonutPlotArea = (function (PiePlotArea) {
|
|
|
24
16
|
});
|
|
25
17
|
|
|
26
18
|
this.appendChart(donutChart);
|
|
27
|
-
}
|
|
19
|
+
}
|
|
28
20
|
|
|
29
21
|
// These were overriden in the Pie, so revert to original behavior
|
|
30
|
-
|
|
22
|
+
getPointBelow(point) {
|
|
31
23
|
return this._getNextPoint(point, this._pointsByVertical, -1);
|
|
32
|
-
}
|
|
24
|
+
}
|
|
33
25
|
|
|
34
|
-
|
|
26
|
+
getPointAbove(point) {
|
|
35
27
|
return this._getNextPoint(point, this._pointsByVertical, 1);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
return DonutPlotArea;
|
|
39
|
-
}(PiePlotArea));
|
|
28
|
+
}
|
|
29
|
+
}
|
|
40
30
|
|
|
41
31
|
export default DonutPlotArea;
|
|
@@ -7,27 +7,19 @@ import { filterSeriesByType } from '../utils';
|
|
|
7
7
|
|
|
8
8
|
import { FUNNEL, PYRAMID } from '../constants';
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
PlotAreaBase.apply(this, arguments);
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
if ( PlotAreaBase ) FunnelPlotArea.__proto__ = PlotAreaBase;
|
|
16
|
-
FunnelPlotArea.prototype = Object.create( PlotAreaBase && PlotAreaBase.prototype );
|
|
17
|
-
FunnelPlotArea.prototype.constructor = FunnelPlotArea;
|
|
18
|
-
|
|
19
|
-
FunnelPlotArea.prototype.render = function render () {
|
|
10
|
+
class FunnelPlotArea extends PlotAreaBase {
|
|
11
|
+
render() {
|
|
20
12
|
this.createChart(FunnelChart, filterSeriesByType(this.series, [ FUNNEL ]));
|
|
21
13
|
this.createChart(PyramidChart, filterSeriesByType(this.series, [ PYRAMID ]));
|
|
22
|
-
}
|
|
14
|
+
}
|
|
23
15
|
|
|
24
|
-
|
|
25
|
-
|
|
16
|
+
createChart(chartType, series) {
|
|
17
|
+
const firstSeries = series[0];
|
|
26
18
|
if (!firstSeries) {
|
|
27
19
|
return;
|
|
28
20
|
}
|
|
29
21
|
|
|
30
|
-
|
|
22
|
+
const chart = new chartType(this, {
|
|
31
23
|
series: series,
|
|
32
24
|
legend: this.options.legend,
|
|
33
25
|
neckRatio: firstSeries.neckRatio,
|
|
@@ -38,26 +30,24 @@ var FunnelPlotArea = (function (PlotAreaBase) {
|
|
|
38
30
|
});
|
|
39
31
|
|
|
40
32
|
this.appendChart(chart);
|
|
41
|
-
}
|
|
33
|
+
}
|
|
42
34
|
|
|
43
|
-
|
|
44
|
-
|
|
35
|
+
appendChart(chart, pane) {
|
|
36
|
+
super.appendChart(chart, pane);
|
|
45
37
|
append(this.options.legend.data, chart.legendItems);
|
|
46
|
-
}
|
|
38
|
+
}
|
|
47
39
|
|
|
48
|
-
|
|
40
|
+
_pointsByVertical(basePoint) {
|
|
49
41
|
return this.pointsBySeriesIndex(basePoint.series.index);
|
|
50
|
-
}
|
|
42
|
+
}
|
|
51
43
|
|
|
52
|
-
|
|
44
|
+
getPointToTheRight(point) {
|
|
53
45
|
return this.getPointBelow(point);
|
|
54
|
-
}
|
|
46
|
+
}
|
|
55
47
|
|
|
56
|
-
|
|
48
|
+
getPointToTheLeft(point) {
|
|
57
49
|
return this.getPointAbove(point);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
return FunnelPlotArea;
|
|
61
|
-
}(PlotAreaBase));
|
|
50
|
+
}
|
|
51
|
+
}
|
|
62
52
|
|
|
63
53
|
export default FunnelPlotArea;
|
|
@@ -10,48 +10,32 @@ import { appendIfNotNull, equalsIgnoreCase, filterSeriesByType, singleItemOrArra
|
|
|
10
10
|
import PlotAreaBase from './plotarea-base';
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
PlotAreaBase.apply(this, arguments);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
if ( PlotAreaBase ) HeatmapPlotArea.__proto__ = PlotAreaBase;
|
|
19
|
-
HeatmapPlotArea.prototype = Object.create( PlotAreaBase && PlotAreaBase.prototype );
|
|
20
|
-
HeatmapPlotArea.prototype.constructor = HeatmapPlotArea;
|
|
21
|
-
|
|
22
|
-
HeatmapPlotArea.prototype.initFields = function initFields () {
|
|
13
|
+
class HeatmapPlotArea extends PlotAreaBase {
|
|
14
|
+
initFields() {
|
|
23
15
|
this.namedXAxes = {};
|
|
24
16
|
this.namedYAxes = {};
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
HeatmapPlotArea.prototype.render = function render (panes) {
|
|
28
|
-
if ( panes === void 0 ) panes = this.panes;
|
|
17
|
+
}
|
|
29
18
|
|
|
19
|
+
render(panes = this.panes) {
|
|
30
20
|
this.bindCategories();
|
|
31
21
|
this.createAxes(panes);
|
|
32
22
|
this.createCharts(panes);
|
|
33
23
|
this.createAxisLabels();
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
HeatmapPlotArea.prototype.bindCategories = function bindCategories () {
|
|
37
|
-
var this$1 = this;
|
|
24
|
+
}
|
|
38
25
|
|
|
39
|
-
|
|
26
|
+
bindCategories() {
|
|
27
|
+
const series = this.srcSeries || this.series;
|
|
40
28
|
|
|
41
|
-
for (
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
var xAxis = ref.xAxis;
|
|
46
|
-
var yAxis = ref.yAxis;
|
|
29
|
+
for (let i = 0; i < series.length; i++) {
|
|
30
|
+
const currentSeries = series[i];
|
|
31
|
+
const data = currentSeries.data || [];
|
|
32
|
+
const { xAxis, yAxis } = this.seriesAxes(currentSeries);
|
|
47
33
|
|
|
48
|
-
|
|
49
|
-
|
|
34
|
+
const xCategories = createHashSet(xAxis.categories || []);
|
|
35
|
+
const yCategories = createHashSet(yAxis.categories || []);
|
|
50
36
|
|
|
51
|
-
for (
|
|
52
|
-
|
|
53
|
-
var x = ref$1.x;
|
|
54
|
-
var y = ref$1.y;
|
|
37
|
+
for (let pointIndex = 0; pointIndex < data.length; pointIndex++) {
|
|
38
|
+
const { x, y } = SeriesBinder.current.bindPoint(currentSeries, pointIndex).valueFields;
|
|
55
39
|
|
|
56
40
|
if (!xCategories.has(x)) {
|
|
57
41
|
xCategories.add(x);
|
|
@@ -65,71 +49,69 @@ var HeatmapPlotArea = (function (PlotAreaBase) {
|
|
|
65
49
|
xAxis.categories = xCategories.values();
|
|
66
50
|
yAxis.categories = yCategories.values();
|
|
67
51
|
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
HeatmapPlotArea.prototype.createCharts = function createCharts (panes) {
|
|
71
|
-
var this$1 = this;
|
|
52
|
+
}
|
|
72
53
|
|
|
73
|
-
|
|
54
|
+
createCharts(panes) {
|
|
55
|
+
const seriesByPane = this.groupSeriesByPane();
|
|
74
56
|
|
|
75
|
-
for (
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
this
|
|
79
|
-
|
|
57
|
+
for (let i = 0; i < panes.length; i++) {
|
|
58
|
+
const pane = panes[i];
|
|
59
|
+
const paneSeries = seriesByPane[pane.options.name || "default"] || [];
|
|
60
|
+
this.addToLegend(paneSeries);
|
|
61
|
+
const filteredSeries = this.filterVisibleSeries(paneSeries);
|
|
80
62
|
|
|
81
63
|
if (!filteredSeries) {
|
|
82
64
|
continue;
|
|
83
65
|
}
|
|
84
66
|
|
|
85
|
-
this
|
|
67
|
+
this.createHeatmapChart(
|
|
86
68
|
filterSeriesByType(filteredSeries, [ HEATMAP ]),
|
|
87
69
|
pane
|
|
88
70
|
);
|
|
89
71
|
}
|
|
90
|
-
}
|
|
72
|
+
}
|
|
91
73
|
|
|
92
|
-
|
|
93
|
-
|
|
74
|
+
createHeatmapChart(series, pane) {
|
|
75
|
+
const chart = new HeatmapChart(this, {
|
|
94
76
|
series: series
|
|
95
77
|
});
|
|
96
78
|
|
|
97
79
|
this.appendChart(chart, pane);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
seriesPaneName(series) {
|
|
83
|
+
const options = this.options;
|
|
84
|
+
const xAxisName = series.xAxis;
|
|
85
|
+
const xAxisOptions = [].concat(options.xAxis);
|
|
86
|
+
const xAxis = grep(xAxisOptions, function(a) { return a.name === xAxisName; })[0];
|
|
87
|
+
const yAxisName = series.yAxis;
|
|
88
|
+
const yAxisOptions = [].concat(options.yAxis);
|
|
89
|
+
const yAxis = grep(yAxisOptions, function(a) { return a.name === yAxisName; })[0];
|
|
90
|
+
const panes = options.panes || [ {} ];
|
|
91
|
+
const defaultPaneName = panes[0].name || "default";
|
|
92
|
+
const paneName = (xAxis || {}).pane || (yAxis || {}).pane || defaultPaneName;
|
|
111
93
|
|
|
112
94
|
return paneName;
|
|
113
|
-
}
|
|
95
|
+
}
|
|
114
96
|
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
97
|
+
seriesAxes(series) {
|
|
98
|
+
let xAxis;
|
|
99
|
+
let yAxis;
|
|
118
100
|
|
|
119
|
-
|
|
101
|
+
const options = this.options;
|
|
120
102
|
|
|
121
|
-
|
|
122
|
-
|
|
103
|
+
const xAxisOptions = [].concat(options.xAxis);
|
|
104
|
+
const xAxisName = series.xAxis;
|
|
123
105
|
if (xAxisName) {
|
|
124
|
-
xAxis = xAxisOptions.find(
|
|
106
|
+
xAxis = xAxisOptions.find(axis => axis.name === xAxisName);
|
|
125
107
|
} else {
|
|
126
108
|
xAxis = xAxisOptions[0];
|
|
127
109
|
}
|
|
128
110
|
|
|
129
|
-
|
|
130
|
-
|
|
111
|
+
const yAxisOptions = [].concat(options.yAxis);
|
|
112
|
+
const yAxisName = series.yAxis;
|
|
131
113
|
if (yAxisName) {
|
|
132
|
-
yAxis = yAxisOptions.find(
|
|
114
|
+
yAxis = yAxisOptions.find(axis => axis.name === yAxisName);
|
|
133
115
|
} else {
|
|
134
116
|
yAxis = yAxisOptions[0];
|
|
135
117
|
}
|
|
@@ -142,63 +124,63 @@ var HeatmapPlotArea = (function (PlotAreaBase) {
|
|
|
142
124
|
throw new Error("Unable to locate Y axis with name " + yAxisName);
|
|
143
125
|
}
|
|
144
126
|
|
|
145
|
-
return { xAxis
|
|
146
|
-
}
|
|
127
|
+
return { xAxis, yAxis };
|
|
128
|
+
}
|
|
147
129
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
for (
|
|
130
|
+
createAxisLabels() {
|
|
131
|
+
const axes = this.axes;
|
|
132
|
+
for (let i = 0; i < axes.length; i++) {
|
|
151
133
|
axes[i].createLabels();
|
|
152
134
|
}
|
|
153
|
-
}
|
|
135
|
+
}
|
|
154
136
|
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
137
|
+
createXYAxis(options, vertical, axisIndex) {
|
|
138
|
+
const axisName = options.name;
|
|
139
|
+
const namedAxes = vertical ? this.namedYAxes : this.namedXAxes;
|
|
140
|
+
const axisOptions = Object.assign({
|
|
159
141
|
axisCrossingValue: 0
|
|
160
142
|
}, options, {
|
|
161
143
|
vertical: vertical,
|
|
162
144
|
reverse: (vertical || this.chartService.rtl) ? !options.reverse : options.reverse,
|
|
163
145
|
justified: false
|
|
164
146
|
});
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
147
|
+
const firstCategory = axisOptions.categories ? axisOptions.categories[0] : null;
|
|
148
|
+
const typeSamples = [ axisOptions.min, axisOptions.max, firstCategory ];
|
|
149
|
+
const series = this.series;
|
|
168
150
|
|
|
169
|
-
for (
|
|
170
|
-
|
|
171
|
-
|
|
151
|
+
for (let seriesIx = 0; seriesIx < series.length; seriesIx++) {
|
|
152
|
+
const currentSeries = series[seriesIx];
|
|
153
|
+
const seriesAxisName = currentSeries[vertical ? "yAxis" : "xAxis"];
|
|
172
154
|
if ((seriesAxisName === axisOptions.name) || (axisIndex === 0 && !seriesAxisName)) {
|
|
173
|
-
|
|
155
|
+
const firstPointValue = SeriesBinder.current.bindPoint(currentSeries, 0).valueFields;
|
|
174
156
|
typeSamples.push(firstPointValue[vertical ? "y" : "x"]);
|
|
175
157
|
|
|
176
158
|
break;
|
|
177
159
|
}
|
|
178
160
|
}
|
|
179
161
|
|
|
180
|
-
|
|
162
|
+
let inferredDate;
|
|
181
163
|
|
|
182
|
-
for (
|
|
164
|
+
for (let i = 0; i < typeSamples.length; i++) {
|
|
183
165
|
if (typeSamples[i] instanceof Date) {
|
|
184
166
|
inferredDate = true;
|
|
185
167
|
break;
|
|
186
168
|
}
|
|
187
169
|
}
|
|
188
170
|
|
|
189
|
-
|
|
171
|
+
let axisType;
|
|
190
172
|
if (equalsIgnoreCase(axisOptions.type, DATE) || (!axisOptions.type && inferredDate)) {
|
|
191
173
|
axisType = DateCategoryAxis;
|
|
192
174
|
} else {
|
|
193
175
|
axisType = CategoryAxis;
|
|
194
176
|
}
|
|
195
177
|
|
|
196
|
-
|
|
178
|
+
const axis = new axisType(axisOptions, this.chartService);
|
|
197
179
|
axis.axisIndex = axisIndex;
|
|
198
180
|
|
|
199
181
|
if (axisName) {
|
|
200
182
|
if (namedAxes[axisName]) {
|
|
201
|
-
throw new Error(
|
|
183
|
+
throw new Error(`${ vertical ? "Y" : "X" } axis with name ${ axisName } is already defined`);
|
|
202
184
|
}
|
|
203
185
|
namedAxes[axisName] = axis;
|
|
204
186
|
}
|
|
@@ -207,39 +189,37 @@ var HeatmapPlotArea = (function (PlotAreaBase) {
|
|
|
207
189
|
axis.indexCategories();
|
|
208
190
|
|
|
209
191
|
return axis;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
HeatmapPlotArea.prototype.createAxes = function createAxes (panes) {
|
|
213
|
-
var this$1 = this;
|
|
192
|
+
}
|
|
214
193
|
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
194
|
+
createAxes(panes) {
|
|
195
|
+
const options = this.options;
|
|
196
|
+
const xAxesOptions = [].concat(options.xAxis);
|
|
197
|
+
const xAxes = [];
|
|
198
|
+
const yAxesOptions = [].concat(options.yAxis);
|
|
199
|
+
const yAxes = [];
|
|
220
200
|
|
|
221
|
-
for (
|
|
222
|
-
|
|
201
|
+
for (let idx = 0; idx < xAxesOptions.length; idx++) {
|
|
202
|
+
const axisPane = this.findPane(xAxesOptions[idx].pane);
|
|
223
203
|
if (inArray(axisPane, panes)) {
|
|
224
|
-
xAxes.push(this
|
|
204
|
+
xAxes.push(this.createXYAxis(xAxesOptions[idx], false, idx));
|
|
225
205
|
}
|
|
226
206
|
}
|
|
227
207
|
|
|
228
|
-
for (
|
|
229
|
-
|
|
230
|
-
if (inArray(axisPane
|
|
231
|
-
yAxes.push(this
|
|
208
|
+
for (let idx = 0; idx < yAxesOptions.length; idx++) {
|
|
209
|
+
const axisPane = this.findPane(yAxesOptions[idx].pane);
|
|
210
|
+
if (inArray(axisPane, panes)) {
|
|
211
|
+
yAxes.push(this.createXYAxis(yAxesOptions[idx], true, idx));
|
|
232
212
|
}
|
|
233
213
|
}
|
|
234
214
|
|
|
235
215
|
this.axisX = this.axisX || xAxes[0];
|
|
236
216
|
this.axisY = this.axisY || yAxes[0];
|
|
237
|
-
}
|
|
217
|
+
}
|
|
238
218
|
|
|
239
|
-
|
|
240
|
-
|
|
219
|
+
removeAxis(axis) {
|
|
220
|
+
const axisName = axis.options.name;
|
|
241
221
|
|
|
242
|
-
|
|
222
|
+
super.removeAxis(axis);
|
|
243
223
|
|
|
244
224
|
if (axis.options.vertical) {
|
|
245
225
|
delete this.namedYAxes[axisName];
|
|
@@ -254,19 +234,19 @@ var HeatmapPlotArea = (function (PlotAreaBase) {
|
|
|
254
234
|
if (axis === this.axisY) {
|
|
255
235
|
delete this.axisY;
|
|
256
236
|
}
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
for (
|
|
268
|
-
|
|
269
|
-
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
_dispatchEvent(chart, e, eventType) {
|
|
240
|
+
const coords = chart._eventCoordinates(e);
|
|
241
|
+
const point = new Point(coords.x, coords.y);
|
|
242
|
+
const allAxes = this.axes;
|
|
243
|
+
const length = allAxes.length;
|
|
244
|
+
const xValues = [];
|
|
245
|
+
const yValues = [];
|
|
246
|
+
|
|
247
|
+
for (let i = 0; i < length; i++) {
|
|
248
|
+
const axis = allAxes[i];
|
|
249
|
+
const values = axis.options.vertical ? yValues : xValues;
|
|
270
250
|
appendIfNotNull(values, axis.getCategory(point));
|
|
271
251
|
}
|
|
272
252
|
|
|
@@ -278,80 +258,72 @@ var HeatmapPlotArea = (function (PlotAreaBase) {
|
|
|
278
258
|
y: singleItemOrArray(yValues)
|
|
279
259
|
});
|
|
280
260
|
}
|
|
281
|
-
}
|
|
261
|
+
}
|
|
282
262
|
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
263
|
+
updateAxisOptions(axis, options) {
|
|
264
|
+
const vertical = axis.options.vertical;
|
|
265
|
+
const axes = this.groupAxes(this.panes);
|
|
266
|
+
const index = (vertical ? axes.y : axes.x).indexOf(axis);
|
|
287
267
|
|
|
288
268
|
updateAxisOptions(this.options, index, vertical, options);
|
|
289
269
|
updateAxisOptions(this.originalOptions, index, vertical, options);
|
|
290
|
-
}
|
|
270
|
+
}
|
|
291
271
|
|
|
292
|
-
|
|
272
|
+
crosshairOptions(axis) {
|
|
293
273
|
// Stack the crosshair above the series points.
|
|
294
274
|
return Object.assign({}, axis.options.crosshair, { zIndex: 0 });
|
|
295
|
-
}
|
|
296
|
-
|
|
297
|
-
HeatmapPlotArea.prototype._pointsByVertical = function _pointsByVertical (basePoint, offset) {
|
|
298
|
-
var this$1 = this;
|
|
299
|
-
if ( offset === void 0 ) offset = 0;
|
|
275
|
+
}
|
|
300
276
|
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
277
|
+
_pointsByVertical(basePoint, offset = 0) {
|
|
278
|
+
const normalizedOffset = this.axisX.options.reverse ? offset * -1 : offset;
|
|
279
|
+
const axisXItems = this.axisX.children;
|
|
280
|
+
let xIndex = this._getPointAxisXIndex(basePoint) + normalizedOffset;
|
|
304
281
|
|
|
305
282
|
xIndex = cycleIndex(xIndex, axisXItems.length);
|
|
306
|
-
|
|
283
|
+
const targetXValue = axisXItems[xIndex].value;
|
|
307
284
|
|
|
308
|
-
|
|
309
|
-
.filterPoints(
|
|
310
|
-
.sort(
|
|
285
|
+
const points = this
|
|
286
|
+
.filterPoints(point => compareValues(point.pointData().x, targetXValue))
|
|
287
|
+
.sort((a, b) => this._getPointAxisYIndex(a) - this._getPointAxisYIndex(b));
|
|
311
288
|
|
|
312
289
|
if (this.axisY.options.reverse) {
|
|
313
290
|
return points.reverse();
|
|
314
291
|
}
|
|
315
292
|
|
|
316
293
|
return points;
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
HeatmapPlotArea.prototype._pointsByHorizontal = function _pointsByHorizontal (basePoint, offset) {
|
|
320
|
-
var this$1 = this;
|
|
321
|
-
if ( offset === void 0 ) offset = 0;
|
|
294
|
+
}
|
|
322
295
|
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
296
|
+
_pointsByHorizontal(basePoint, offset = 0) {
|
|
297
|
+
const normalizedOffset = this.axisY.options.reverse ? offset * -1 : offset;
|
|
298
|
+
const axisYItems = this.axisY.children;
|
|
299
|
+
let yIndex = this._getPointAxisYIndex(basePoint) + normalizedOffset;
|
|
326
300
|
|
|
327
301
|
yIndex = cycleIndex(yIndex, axisYItems.length);
|
|
328
|
-
|
|
302
|
+
const targetYValue = axisYItems[yIndex].value;
|
|
329
303
|
|
|
330
|
-
|
|
331
|
-
.filterPoints(
|
|
332
|
-
.sort(
|
|
304
|
+
const points = this
|
|
305
|
+
.filterPoints(point => compareValues(point.pointData().y, targetYValue))
|
|
306
|
+
.sort((a, b) => this._getPointAxisXIndex(a) - this._getPointAxisXIndex(b));
|
|
333
307
|
|
|
334
308
|
if (this.axisX.options.reverse) {
|
|
335
309
|
return points.reverse();
|
|
336
310
|
}
|
|
337
311
|
|
|
338
312
|
return points;
|
|
339
|
-
}
|
|
313
|
+
}
|
|
340
314
|
|
|
341
|
-
|
|
315
|
+
_getPointAxisXIndex(point) {
|
|
342
316
|
return this._getPointAxisIndex(this.axisX, point.pointData().x);
|
|
343
|
-
}
|
|
317
|
+
}
|
|
344
318
|
|
|
345
|
-
|
|
319
|
+
_getPointAxisYIndex(point) {
|
|
346
320
|
return this._getPointAxisIndex(this.axisY, point.pointData().y);
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
HeatmapPlotArea.prototype._getPointAxisIndex = function _getPointAxisIndex (axis, pointValue) {
|
|
350
|
-
return axis.children.findIndex(function (axisItem) { return compareValues(pointValue, axisItem.value); });
|
|
351
|
-
};
|
|
321
|
+
}
|
|
352
322
|
|
|
353
|
-
|
|
354
|
-
|
|
323
|
+
_getPointAxisIndex(axis, pointValue) {
|
|
324
|
+
return axis.children.findIndex(axisItem => compareValues(pointValue, axisItem.value));
|
|
325
|
+
}
|
|
326
|
+
}
|
|
355
327
|
|
|
356
328
|
function compareValues(a, b) {
|
|
357
329
|
if (a instanceof Date && b instanceof Date) {
|
|
@@ -362,7 +334,7 @@ function compareValues(a, b) {
|
|
|
362
334
|
}
|
|
363
335
|
|
|
364
336
|
function updateAxisOptions(targetOptions, axisIndex, vertical, options) {
|
|
365
|
-
|
|
337
|
+
const axisOptions = ([].concat(vertical ? targetOptions.yAxis : targetOptions.xAxis))[axisIndex];
|
|
366
338
|
deepExtend(axisOptions, options);
|
|
367
339
|
}
|
|
368
340
|
|
|
@@ -3,22 +3,14 @@ import PieChart from '../pie-chart/pie-chart';
|
|
|
3
3
|
|
|
4
4
|
import { append } from '../../common';
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
PlotAreaBase.apply(this, arguments);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
if ( PlotAreaBase ) PiePlotArea.__proto__ = PlotAreaBase;
|
|
12
|
-
PiePlotArea.prototype = Object.create( PlotAreaBase && PlotAreaBase.prototype );
|
|
13
|
-
PiePlotArea.prototype.constructor = PiePlotArea;
|
|
14
|
-
|
|
15
|
-
PiePlotArea.prototype.render = function render () {
|
|
6
|
+
class PiePlotArea extends PlotAreaBase {
|
|
7
|
+
render() {
|
|
16
8
|
this.createPieChart(this.series);
|
|
17
|
-
}
|
|
9
|
+
}
|
|
18
10
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
createPieChart(series) {
|
|
12
|
+
const firstSeries = series[0];
|
|
13
|
+
const pieChart = new PieChart(this, {
|
|
22
14
|
series: series,
|
|
23
15
|
padding: firstSeries.padding,
|
|
24
16
|
startAngle: firstSeries.startAngle,
|
|
@@ -27,22 +19,20 @@ var PiePlotArea = (function (PlotAreaBase) {
|
|
|
27
19
|
});
|
|
28
20
|
|
|
29
21
|
this.appendChart(pieChart);
|
|
30
|
-
}
|
|
22
|
+
}
|
|
31
23
|
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
appendChart(chart, pane) {
|
|
25
|
+
super.appendChart(chart, pane);
|
|
34
26
|
append(this.options.legend.data, chart.legendItems);
|
|
35
|
-
}
|
|
27
|
+
}
|
|
36
28
|
|
|
37
|
-
|
|
29
|
+
getPointBelow(point) {
|
|
38
30
|
return this.getPointToTheRight(point);
|
|
39
|
-
}
|
|
31
|
+
}
|
|
40
32
|
|
|
41
|
-
|
|
33
|
+
getPointAbove(point) {
|
|
42
34
|
return this.getPointToTheLeft(point);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
return PiePlotArea;
|
|
46
|
-
}(PlotAreaBase));
|
|
35
|
+
}
|
|
36
|
+
}
|
|
47
37
|
|
|
48
38
|
export default PiePlotArea;
|