@visactor/vchart 1.5.1-alpha.5 → 1.5.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/build/es5/index.js +1 -1
- package/build/index.js +1598 -590
- package/build/index.min.js +1 -1
- package/build/tsconfig.tsbuildinfo +1 -1
- package/cjs/chart/base-chart.js +4 -1
- package/cjs/chart/base-chart.js.map +1 -1
- package/cjs/chart/common/interface.d.ts +2 -1
- package/cjs/chart/common/interface.js.map +1 -1
- package/cjs/chart/correlation/correlation.d.ts +11 -0
- package/cjs/chart/correlation/correlation.js +53 -0
- package/cjs/chart/correlation/correlation.js.map +1 -0
- package/cjs/chart/correlation/index.d.ts +2 -0
- package/cjs/chart/correlation/index.js +21 -0
- package/cjs/chart/correlation/index.js.map +1 -0
- package/cjs/chart/correlation/interface.d.ts +6 -0
- package/cjs/chart/correlation/interface.js +6 -0
- package/cjs/chart/correlation/interface.js.map +1 -0
- package/cjs/chart/index.d.ts +5 -3
- package/cjs/chart/index.js +16 -2
- package/cjs/chart/index.js.map +1 -1
- package/cjs/chart/interface/type.d.ts +2 -1
- package/cjs/chart/interface/type.js +2 -1
- package/cjs/chart/interface/type.js.map +1 -1
- package/cjs/chart/sequence/sequence.js +0 -1
- package/cjs/chart/sequence/sequence.js.map +1 -1
- package/cjs/chart/waterfall/waterfall.js.map +1 -1
- package/cjs/compile/util.js +2 -1
- package/cjs/component/axis/base-axis.d.ts +2 -2
- package/cjs/component/axis/base-axis.js.map +1 -1
- package/cjs/component/axis/cartesian/axis.d.ts +4 -0
- package/cjs/component/axis/cartesian/axis.js +51 -9
- package/cjs/component/axis/cartesian/axis.js.map +1 -1
- package/cjs/component/axis/cartesian/interface/common.d.ts +6 -1
- package/cjs/component/axis/cartesian/interface/common.js.map +1 -1
- package/cjs/component/axis/cartesian/interface/spec.d.ts +2 -1
- package/cjs/component/axis/cartesian/interface/spec.js.map +1 -1
- package/cjs/component/axis/cartesian/interface/theme.d.ts +2 -1
- package/cjs/component/axis/cartesian/interface/theme.js.map +1 -1
- package/cjs/component/base/base-component.d.ts +1 -1
- package/cjs/component/base/base-component.js.map +1 -1
- package/cjs/component/brush/brush.d.ts +2 -2
- package/cjs/component/brush/brush.js.map +1 -1
- package/cjs/component/brush/interface.d.ts +1 -1
- package/cjs/component/brush/interface.js.map +1 -1
- package/cjs/component/common/trigger/desktop.d.ts +1 -0
- package/cjs/component/common/trigger/desktop.js +1 -0
- package/cjs/component/common/trigger/desktop.js.map +1 -1
- package/cjs/component/common/trigger/mobile.d.ts +1 -0
- package/cjs/component/common/trigger/mobile.js +1 -0
- package/cjs/component/common/trigger/mobile.js.map +1 -1
- package/cjs/component/crosshair/cartesian.d.ts +2 -2
- package/cjs/component/crosshair/cartesian.js.map +1 -1
- package/cjs/component/crosshair/polar.d.ts +2 -2
- package/cjs/component/crosshair/polar.js.map +1 -1
- package/cjs/component/custom-mark/custom-mark.d.ts +2 -2
- package/cjs/component/custom-mark/custom-mark.js.map +1 -1
- package/cjs/component/data-zoom/data-filter-base-component.d.ts +26 -9
- package/cjs/component/data-zoom/data-filter-base-component.js +92 -20
- package/cjs/component/data-zoom/data-filter-base-component.js.map +1 -1
- package/cjs/component/data-zoom/data-zoom/data-zoom.d.ts +2 -3
- package/cjs/component/data-zoom/data-zoom/data-zoom.js +16 -8
- package/cjs/component/data-zoom/data-zoom/data-zoom.js.map +1 -1
- package/cjs/component/data-zoom/interface.d.ts +36 -2
- package/cjs/component/data-zoom/interface.js.map +1 -1
- package/cjs/component/data-zoom/scroll-bar/scroll-bar.d.ts +3 -3
- package/cjs/component/data-zoom/scroll-bar/scroll-bar.js +17 -9
- package/cjs/component/data-zoom/scroll-bar/scroll-bar.js.map +1 -1
- package/cjs/component/geo/geo-coordinate.d.ts +2 -2
- package/cjs/component/geo/geo-coordinate.js.map +1 -1
- package/cjs/component/index.js +1 -2
- package/cjs/component/indicator/indicator.d.ts +2 -2
- package/cjs/component/indicator/indicator.js.map +1 -1
- package/cjs/component/interface/common.d.ts +2 -2
- package/cjs/component/interface/common.js.map +1 -1
- package/cjs/component/label/base-label.d.ts +2 -2
- package/cjs/component/label/base-label.js.map +1 -1
- package/cjs/component/legend/base-legend.d.ts +2 -2
- package/cjs/component/legend/base-legend.js.map +1 -1
- package/cjs/component/legend/continuous/legend.d.ts +1 -1
- package/cjs/component/legend/discrete/legend.d.ts +1 -1
- package/cjs/component/legend/interface.d.ts +3 -0
- package/cjs/component/legend/interface.js.map +1 -1
- package/cjs/component/map-label/component.d.ts +3 -3
- package/cjs/component/map-label/component.js.map +1 -1
- package/cjs/component/marker/base-marker.d.ts +2 -2
- package/cjs/component/marker/base-marker.js.map +1 -1
- package/cjs/component/marker/mark-line/mark-line.js.map +1 -1
- package/cjs/component/marker/mark-point/mark-point.js.map +1 -1
- package/cjs/component/player/player.d.ts +2 -2
- package/cjs/component/player/player.js.map +1 -1
- package/cjs/component/title/title.d.ts +2 -2
- package/cjs/component/title/title.js.map +1 -1
- package/cjs/component/tooltip/handler/base.d.ts +1 -1
- package/cjs/component/tooltip/handler/dom/util.js.map +1 -1
- package/cjs/component/tooltip/handler/utils/common.js.map +1 -1
- package/cjs/component/tooltip/handler/utils/compose.js +2 -1
- package/cjs/component/tooltip/handler/utils/compose.js.map +1 -1
- package/cjs/component/tooltip/tooltip.d.ts +2 -2
- package/cjs/component/tooltip/tooltip.js.map +1 -1
- package/cjs/constant/correlation.d.ts +3 -0
- package/cjs/constant/correlation.js +11 -0
- package/cjs/constant/correlation.js.map +1 -0
- package/cjs/constant/index.d.ts +1 -0
- package/cjs/constant/index.js +2 -1
- package/cjs/constant/index.js.map +1 -1
- package/cjs/constant/word-cloud.js +1 -2
- package/cjs/core/factory.js +2 -1
- package/cjs/core/index.d.ts +1 -1
- package/cjs/core/index.js +1 -1
- package/cjs/core/index.js.map +1 -1
- package/cjs/data/transforms/correlation-center.d.ts +4 -0
- package/cjs/data/transforms/correlation-center.js +18 -0
- package/cjs/data/transforms/correlation-center.js.map +1 -0
- package/cjs/data/transforms/correlation.d.ts +17 -0
- package/cjs/data/transforms/correlation.js +58 -0
- package/cjs/data/transforms/correlation.js.map +1 -0
- package/cjs/interaction/dimension-trigger.js +1 -2
- package/cjs/interaction/interaction.js +2 -1
- package/cjs/interaction/zoom/zoomable.d.ts +20 -12
- package/cjs/interaction/zoom/zoomable.js +94 -74
- package/cjs/interaction/zoom/zoomable.js.map +1 -1
- package/cjs/layout/base-layout.d.ts +7 -1
- package/cjs/layout/base-layout.js +24 -10
- package/cjs/layout/base-layout.js.map +1 -1
- package/cjs/layout/layout3d/index.d.ts +6 -0
- package/cjs/layout/layout3d/index.js +14 -0
- package/cjs/layout/layout3d/index.js.map +1 -1
- package/cjs/mark/arc-3d.js +1 -1
- package/cjs/mark/index.d.ts +3 -2
- package/cjs/mark/index.js +10 -1
- package/cjs/mark/index.js.map +1 -1
- package/cjs/mark/interface/type.d.ts +1 -0
- package/cjs/mark/interface/type.js +1 -1
- package/cjs/mark/interface/type.js.map +1 -1
- package/cjs/mark/ripple.d.ts +12 -0
- package/cjs/mark/ripple.js +29 -0
- package/cjs/mark/ripple.js.map +1 -0
- package/cjs/model/base-model.d.ts +0 -3
- package/cjs/model/base-model.js +0 -3
- package/cjs/model/base-model.js.map +1 -1
- package/cjs/model/interface.d.ts +0 -2
- package/cjs/model/interface.js.map +1 -1
- package/cjs/series/area/area.js +4 -2
- package/cjs/series/area/area.js.map +1 -1
- package/cjs/series/bar/bar.d.ts +1 -0
- package/cjs/series/bar/bar.js +4 -3
- package/cjs/series/bar/bar.js.map +1 -1
- package/cjs/series/base/base-series.js +6 -9
- package/cjs/series/base/base-series.js.map +1 -1
- package/cjs/series/box-plot/box-plot.js +9 -9
- package/cjs/series/box-plot/box-plot.js.map +1 -1
- package/cjs/series/circle-packing/circle-packing.js +7 -6
- package/cjs/series/circle-packing/circle-packing.js.map +1 -1
- package/cjs/series/correlation/animation.d.ts +8 -0
- package/cjs/series/correlation/animation.js +22 -0
- package/cjs/series/correlation/animation.js.map +1 -0
- package/cjs/series/correlation/constant.d.ts +2 -0
- package/cjs/series/correlation/constant.js +27 -0
- package/cjs/series/correlation/constant.js.map +1 -0
- package/cjs/series/correlation/correlation.d.ts +57 -0
- package/cjs/series/correlation/correlation.js +215 -0
- package/cjs/series/correlation/correlation.js.map +1 -0
- package/cjs/series/correlation/interface.d.ts +37 -0
- package/cjs/series/correlation/interface.js +6 -0
- package/cjs/series/correlation/interface.js.map +1 -0
- package/cjs/series/dot/dot.js +2 -4
- package/cjs/series/dot/dot.js.map +1 -1
- package/cjs/series/funnel/funnel.js +4 -6
- package/cjs/series/funnel/funnel.js.map +1 -1
- package/cjs/series/gauge/gauge-pointer.d.ts +1 -0
- package/cjs/series/gauge/gauge-pointer.js +4 -2
- package/cjs/series/gauge/gauge-pointer.js.map +1 -1
- package/cjs/series/gauge/gauge.d.ts +1 -0
- package/cjs/series/gauge/gauge.js +5 -3
- package/cjs/series/gauge/gauge.js.map +1 -1
- package/cjs/series/heatmap/heatmap.js +2 -4
- package/cjs/series/heatmap/heatmap.js.map +1 -1
- package/cjs/series/index.d.ts +4 -2
- package/cjs/series/index.js +11 -2
- package/cjs/series/index.js.map +1 -1
- package/cjs/series/interface/series.d.ts +1 -1
- package/cjs/series/interface/series.js.map +1 -1
- package/cjs/series/interface/theme.d.ts +2 -0
- package/cjs/series/interface/theme.js +3 -2
- package/cjs/series/interface/theme.js.map +1 -1
- package/cjs/series/interface/type.d.ts +7 -2
- package/cjs/series/interface/type.js +4 -2
- package/cjs/series/interface/type.js.map +1 -1
- package/cjs/series/line/line.d.ts +1 -0
- package/cjs/series/line/line.js +4 -0
- package/cjs/series/line/line.js.map +1 -1
- package/cjs/series/link/link.js +6 -7
- package/cjs/series/link/link.js.map +1 -1
- package/cjs/series/map/map.js +2 -4
- package/cjs/series/map/map.js.map +1 -1
- package/cjs/series/mixin/line-mixin.js +2 -5
- package/cjs/series/mixin/line-mixin.js.map +1 -1
- package/cjs/series/pie/interface.d.ts +2 -0
- package/cjs/series/pie/interface.js.map +1 -1
- package/cjs/series/pie/pie-3d.js +6 -6
- package/cjs/series/pie/pie-3d.js.map +1 -1
- package/cjs/series/pie/pie.d.ts +2 -0
- package/cjs/series/pie/pie.js +18 -3
- package/cjs/series/pie/pie.js.map +1 -1
- package/cjs/series/progress/circular/circular.d.ts +1 -0
- package/cjs/series/progress/circular/circular.js +5 -3
- package/cjs/series/progress/circular/circular.js.map +1 -1
- package/cjs/series/progress/linear/linear.js +6 -6
- package/cjs/series/progress/linear/linear.js.map +1 -1
- package/cjs/series/radar/animation.js.map +1 -1
- package/cjs/series/radar/radar.d.ts +1 -0
- package/cjs/series/radar/radar.js +6 -2
- package/cjs/series/radar/radar.js.map +1 -1
- package/cjs/series/range-area/range-area.js +2 -3
- package/cjs/series/range-area/range-area.js.map +1 -1
- package/cjs/series/range-column/range-column.d.ts +1 -0
- package/cjs/series/range-column/range-column.js +11 -11
- package/cjs/series/range-column/range-column.js.map +1 -1
- package/cjs/series/rose/rose.d.ts +1 -0
- package/cjs/series/rose/rose.js +4 -2
- package/cjs/series/rose/rose.js.map +1 -1
- package/cjs/series/sankey/sankey.js +7 -9
- package/cjs/series/sankey/sankey.js.map +1 -1
- package/cjs/series/scatter/scatter.d.ts +1 -0
- package/cjs/series/scatter/scatter.js +4 -3
- package/cjs/series/scatter/scatter.js.map +1 -1
- package/cjs/series/sunburst/sunburst.js +4 -6
- package/cjs/series/sunburst/sunburst.js.map +1 -1
- package/cjs/series/treemap/treemap.js +10 -9
- package/cjs/series/treemap/treemap.js.map +1 -1
- package/cjs/series/word-cloud/base.d.ts +1 -0
- package/cjs/series/word-cloud/base.js +6 -3
- package/cjs/series/word-cloud/base.js.map +1 -1
- package/cjs/series/word-cloud/word-cloud-3d.js +2 -3
- package/cjs/series/word-cloud/word-cloud-3d.js.map +1 -1
- package/cjs/theme/builtin/common/component/axis/cartesian-axis.js +31 -3
- package/cjs/theme/builtin/common/component/axis/cartesian-axis.js.map +1 -1
- package/cjs/theme/builtin/common/component/indicator.js +1 -1
- package/cjs/theme/builtin/common/component/indicator.js.map +1 -1
- package/cjs/theme/builtin/common/component/legend/continuous.js +1 -1
- package/cjs/theme/builtin/common/component/legend/continuous.js.map +1 -1
- package/cjs/theme/builtin/common/component/legend/discrete-legend.js +1 -1
- package/cjs/theme/builtin/common/component/legend/discrete-legend.js.map +1 -1
- package/cjs/theme/builtin/common/component/mark-area.js +12 -10
- package/cjs/theme/builtin/common/component/mark-area.js.map +1 -1
- package/cjs/theme/builtin/common/component/mark-line.js +19 -12
- package/cjs/theme/builtin/common/component/mark-line.js.map +1 -1
- package/cjs/theme/builtin/common/component/mark-point.js +8 -2
- package/cjs/theme/builtin/common/component/mark-point.js.map +1 -1
- package/cjs/theme/builtin/common/component/poptip.js +1 -1
- package/cjs/theme/builtin/common/component/poptip.js.map +1 -1
- package/cjs/theme/builtin/common/component/title.js +1 -1
- package/cjs/theme/builtin/common/component/title.js.map +1 -1
- package/cjs/theme/builtin/common/component/tooltip.js +2 -2
- package/cjs/theme/builtin/common/component/tooltip.js.map +1 -1
- package/cjs/theme/builtin/common/component/total-label.js +1 -1
- package/cjs/theme/builtin/common/component/total-label.js.map +1 -1
- package/cjs/theme/builtin/common/series/area.js +4 -1
- package/cjs/theme/builtin/common/series/area.js.map +1 -1
- package/cjs/theme/builtin/common/series/bar.js +4 -1
- package/cjs/theme/builtin/common/series/bar.js.map +1 -1
- package/cjs/theme/builtin/common/series/circle-packing.js +4 -1
- package/cjs/theme/builtin/common/series/circle-packing.js.map +1 -1
- package/cjs/theme/builtin/common/series/correlation.d.ts +2 -0
- package/cjs/theme/builtin/common/series/correlation.js +22 -0
- package/cjs/theme/builtin/common/series/correlation.js.map +1 -0
- package/cjs/theme/builtin/common/series/funnel.js +12 -3
- package/cjs/theme/builtin/common/series/funnel.js.map +1 -1
- package/cjs/theme/builtin/common/series/index.js +3 -2
- package/cjs/theme/builtin/common/series/index.js.map +1 -1
- package/cjs/theme/builtin/common/series/line.js +4 -1
- package/cjs/theme/builtin/common/series/line.js.map +1 -1
- package/cjs/theme/builtin/common/series/map.js +4 -1
- package/cjs/theme/builtin/common/series/map.js.map +1 -1
- package/cjs/theme/builtin/common/series/pie.js +9 -1
- package/cjs/theme/builtin/common/series/pie.js.map +1 -1
- package/cjs/theme/builtin/common/series/radar.js +4 -1
- package/cjs/theme/builtin/common/series/radar.js.map +1 -1
- package/cjs/theme/builtin/common/series/rose.js +5 -1
- package/cjs/theme/builtin/common/series/rose.js.map +1 -1
- package/cjs/theme/builtin/common/series/scatter.js +4 -1
- package/cjs/theme/builtin/common/series/scatter.js.map +1 -1
- package/cjs/theme/builtin/common/series/treemap.js +4 -1
- package/cjs/theme/builtin/common/series/treemap.js.map +1 -1
- package/cjs/theme/builtin/dark/color-scheme.js +1 -1
- package/cjs/theme/builtin/dark/color-scheme.js.map +1 -1
- package/cjs/theme/builtin/light/color-scheme.js +3 -3
- package/cjs/theme/builtin/light/color-scheme.js.map +1 -1
- package/cjs/theme/color-scheme/builtin/interface.d.ts +1 -1
- package/cjs/theme/color-scheme/builtin/interface.js.map +1 -1
- package/cjs/theme/color-scheme/interface.d.ts +1 -1
- package/cjs/theme/color-scheme/interface.js.map +1 -1
- package/cjs/theme/color-scheme/util.js +3 -7
- package/cjs/theme/color-scheme/util.js.map +1 -1
- package/cjs/typings/event.d.ts +1 -0
- package/cjs/typings/event.js +6 -0
- package/cjs/typings/event.js.map +1 -0
- package/cjs/typings/spec/chart.d.ts +2 -0
- package/cjs/typings/spec/chart.js.map +1 -1
- package/cjs/typings/spec/common.d.ts +8 -6
- package/cjs/typings/spec/common.js.map +1 -1
- package/cjs/typings/tooltip/line.d.ts +1 -0
- package/cjs/typings/tooltip/line.js.map +1 -1
- package/cjs/typings/visual.d.ts +4 -0
- package/cjs/typings/visual.js.map +1 -1
- package/cjs/vchart-all.js +2 -2
- package/cjs/vchart-all.js.map +1 -1
- package/esm/chart/base-chart.js +4 -1
- package/esm/chart/base-chart.js.map +1 -1
- package/esm/chart/common/interface.d.ts +2 -1
- package/esm/chart/common/interface.js.map +1 -1
- package/esm/chart/correlation/correlation.d.ts +11 -0
- package/esm/chart/correlation/correlation.js +52 -0
- package/esm/chart/correlation/correlation.js.map +1 -0
- package/esm/chart/correlation/index.d.ts +2 -0
- package/esm/chart/correlation/index.js +4 -0
- package/esm/chart/correlation/index.js.map +1 -0
- package/esm/chart/correlation/interface.d.ts +6 -0
- package/esm/chart/correlation/interface.js +2 -0
- package/esm/chart/correlation/interface.js.map +1 -0
- package/esm/chart/index.d.ts +5 -3
- package/esm/chart/index.js +4 -2
- package/esm/chart/index.js.map +1 -1
- package/esm/chart/interface/type.d.ts +2 -1
- package/esm/chart/interface/type.js +2 -1
- package/esm/chart/interface/type.js.map +1 -1
- package/esm/chart/sequence/sequence.js +0 -1
- package/esm/chart/sequence/sequence.js.map +1 -1
- package/esm/chart/waterfall/waterfall.js.map +1 -1
- package/esm/compile/util.js +2 -1
- package/esm/component/axis/base-axis.d.ts +2 -2
- package/esm/component/axis/base-axis.js.map +1 -1
- package/esm/component/axis/cartesian/axis.d.ts +4 -0
- package/esm/component/axis/cartesian/axis.js +52 -8
- package/esm/component/axis/cartesian/axis.js.map +1 -1
- package/esm/component/axis/cartesian/interface/common.d.ts +6 -1
- package/esm/component/axis/cartesian/interface/common.js.map +1 -1
- package/esm/component/axis/cartesian/interface/spec.d.ts +2 -1
- package/esm/component/axis/cartesian/interface/spec.js.map +1 -1
- package/esm/component/axis/cartesian/interface/theme.d.ts +2 -1
- package/esm/component/axis/cartesian/interface/theme.js.map +1 -1
- package/esm/component/base/base-component.d.ts +1 -1
- package/esm/component/base/base-component.js.map +1 -1
- package/esm/component/brush/brush.d.ts +2 -2
- package/esm/component/brush/brush.js.map +1 -1
- package/esm/component/brush/interface.d.ts +1 -1
- package/esm/component/brush/interface.js.map +1 -1
- package/esm/component/common/trigger/desktop.d.ts +1 -0
- package/esm/component/common/trigger/desktop.js +1 -0
- package/esm/component/common/trigger/desktop.js.map +1 -1
- package/esm/component/common/trigger/mobile.d.ts +1 -0
- package/esm/component/common/trigger/mobile.js +1 -0
- package/esm/component/common/trigger/mobile.js.map +1 -1
- package/esm/component/crosshair/cartesian.d.ts +2 -2
- package/esm/component/crosshair/cartesian.js.map +1 -1
- package/esm/component/crosshair/polar.d.ts +2 -2
- package/esm/component/crosshair/polar.js.map +1 -1
- package/esm/component/custom-mark/custom-mark.d.ts +2 -2
- package/esm/component/custom-mark/custom-mark.js.map +1 -1
- package/esm/component/data-zoom/data-filter-base-component.d.ts +26 -9
- package/esm/component/data-zoom/data-filter-base-component.js +91 -20
- package/esm/component/data-zoom/data-filter-base-component.js.map +1 -1
- package/esm/component/data-zoom/data-zoom/data-zoom.d.ts +2 -3
- package/esm/component/data-zoom/data-zoom/data-zoom.js +17 -9
- package/esm/component/data-zoom/data-zoom/data-zoom.js.map +1 -1
- package/esm/component/data-zoom/interface.d.ts +36 -2
- package/esm/component/data-zoom/interface.js.map +1 -1
- package/esm/component/data-zoom/scroll-bar/scroll-bar.d.ts +3 -3
- package/esm/component/data-zoom/scroll-bar/scroll-bar.js +18 -10
- package/esm/component/data-zoom/scroll-bar/scroll-bar.js.map +1 -1
- package/esm/component/geo/geo-coordinate.d.ts +2 -2
- package/esm/component/geo/geo-coordinate.js.map +1 -1
- package/esm/component/index.js +1 -2
- package/esm/component/indicator/indicator.d.ts +2 -2
- package/esm/component/indicator/indicator.js.map +1 -1
- package/esm/component/interface/common.d.ts +2 -2
- package/esm/component/interface/common.js.map +1 -1
- package/esm/component/label/base-label.d.ts +2 -2
- package/esm/component/label/base-label.js.map +1 -1
- package/esm/component/legend/base-legend.d.ts +2 -2
- package/esm/component/legend/base-legend.js.map +1 -1
- package/esm/component/legend/continuous/legend.d.ts +1 -1
- package/esm/component/legend/discrete/legend.d.ts +1 -1
- package/esm/component/legend/interface.d.ts +3 -0
- package/esm/component/legend/interface.js.map +1 -1
- package/esm/component/map-label/component.d.ts +3 -3
- package/esm/component/map-label/component.js.map +1 -1
- package/esm/component/marker/base-marker.d.ts +2 -2
- package/esm/component/marker/base-marker.js.map +1 -1
- package/esm/component/marker/mark-line/mark-line.js.map +1 -1
- package/esm/component/marker/mark-point/mark-point.js.map +1 -1
- package/esm/component/player/player.d.ts +2 -2
- package/esm/component/player/player.js.map +1 -1
- package/esm/component/title/title.d.ts +2 -2
- package/esm/component/title/title.js.map +1 -1
- package/esm/component/tooltip/handler/base.d.ts +1 -1
- package/esm/component/tooltip/handler/dom/util.js.map +1 -1
- package/esm/component/tooltip/handler/utils/common.js.map +1 -1
- package/esm/component/tooltip/handler/utils/compose.js +2 -1
- package/esm/component/tooltip/handler/utils/compose.js.map +1 -1
- package/esm/component/tooltip/tooltip.d.ts +2 -2
- package/esm/component/tooltip/tooltip.js.map +1 -1
- package/esm/constant/correlation.d.ts +3 -0
- package/esm/constant/correlation.js +8 -0
- package/esm/constant/correlation.js.map +1 -0
- package/esm/constant/index.d.ts +1 -0
- package/esm/constant/index.js +2 -0
- package/esm/constant/index.js.map +1 -1
- package/esm/constant/word-cloud.js +1 -2
- package/esm/core/factory.js +2 -1
- package/esm/core/index.d.ts +1 -1
- package/esm/core/index.js +1 -1
- package/esm/core/index.js.map +1 -1
- package/esm/data/transforms/correlation-center.d.ts +4 -0
- package/esm/data/transforms/correlation-center.js +14 -0
- package/esm/data/transforms/correlation-center.js.map +1 -0
- package/esm/data/transforms/correlation.d.ts +17 -0
- package/esm/data/transforms/correlation.js +49 -0
- package/esm/data/transforms/correlation.js.map +1 -0
- package/esm/interaction/dimension-trigger.js +1 -2
- package/esm/interaction/interaction.js +2 -1
- package/esm/interaction/zoom/zoomable.d.ts +20 -12
- package/esm/interaction/zoom/zoomable.js +96 -74
- package/esm/interaction/zoom/zoomable.js.map +1 -1
- package/esm/layout/base-layout.d.ts +7 -1
- package/esm/layout/base-layout.js +24 -10
- package/esm/layout/base-layout.js.map +1 -1
- package/esm/layout/layout3d/index.d.ts +6 -0
- package/esm/layout/layout3d/index.js +14 -0
- package/esm/layout/layout3d/index.js.map +1 -1
- package/esm/mark/arc-3d.js +1 -1
- package/esm/mark/index.d.ts +3 -2
- package/esm/mark/index.js +3 -1
- package/esm/mark/index.js.map +1 -1
- package/esm/mark/interface/type.d.ts +1 -0
- package/esm/mark/interface/type.js +1 -1
- package/esm/mark/interface/type.js.map +1 -1
- package/esm/mark/ripple.d.ts +12 -0
- package/esm/mark/ripple.js +27 -0
- package/esm/mark/ripple.js.map +1 -0
- package/esm/model/base-model.d.ts +0 -3
- package/esm/model/base-model.js +0 -3
- package/esm/model/base-model.js.map +1 -1
- package/esm/model/interface.d.ts +0 -2
- package/esm/model/interface.js.map +1 -1
- package/esm/series/area/area.js +4 -3
- package/esm/series/area/area.js.map +1 -1
- package/esm/series/bar/bar.d.ts +1 -0
- package/esm/series/bar/bar.js +4 -2
- package/esm/series/bar/bar.js.map +1 -1
- package/esm/series/base/base-series.js +5 -7
- package/esm/series/base/base-series.js.map +1 -1
- package/esm/series/box-plot/box-plot.js +10 -8
- package/esm/series/box-plot/box-plot.js.map +1 -1
- package/esm/series/circle-packing/circle-packing.js +7 -6
- package/esm/series/circle-packing/circle-packing.js.map +1 -1
- package/esm/series/correlation/animation.d.ts +8 -0
- package/esm/series/correlation/animation.js +16 -0
- package/esm/series/correlation/animation.js.map +1 -0
- package/esm/series/correlation/constant.d.ts +2 -0
- package/esm/series/correlation/constant.js +25 -0
- package/esm/series/correlation/constant.js.map +1 -0
- package/esm/series/correlation/correlation.d.ts +57 -0
- package/esm/series/correlation/correlation.js +237 -0
- package/esm/series/correlation/correlation.js.map +1 -0
- package/esm/series/correlation/interface.d.ts +37 -0
- package/esm/series/correlation/interface.js +2 -0
- package/esm/series/correlation/interface.js.map +1 -0
- package/esm/series/dot/dot.js +2 -3
- package/esm/series/dot/dot.js.map +1 -1
- package/esm/series/funnel/funnel.js +4 -5
- package/esm/series/funnel/funnel.js.map +1 -1
- package/esm/series/gauge/gauge-pointer.d.ts +1 -0
- package/esm/series/gauge/gauge-pointer.js +4 -2
- package/esm/series/gauge/gauge-pointer.js.map +1 -1
- package/esm/series/gauge/gauge.d.ts +1 -0
- package/esm/series/gauge/gauge.js +5 -3
- package/esm/series/gauge/gauge.js.map +1 -1
- package/esm/series/heatmap/heatmap.js +2 -4
- package/esm/series/heatmap/heatmap.js.map +1 -1
- package/esm/series/index.d.ts +4 -2
- package/esm/series/index.js +3 -1
- package/esm/series/index.js.map +1 -1
- package/esm/series/interface/series.d.ts +1 -1
- package/esm/series/interface/series.js.map +1 -1
- package/esm/series/interface/theme.d.ts +2 -0
- package/esm/series/interface/theme.js +4 -1
- package/esm/series/interface/theme.js.map +1 -1
- package/esm/series/interface/type.d.ts +7 -2
- package/esm/series/interface/type.js +4 -2
- package/esm/series/interface/type.js.map +1 -1
- package/esm/series/line/line.d.ts +1 -0
- package/esm/series/line/line.js +4 -0
- package/esm/series/line/line.js.map +1 -1
- package/esm/series/link/link.js +6 -5
- package/esm/series/link/link.js.map +1 -1
- package/esm/series/map/map.js +2 -3
- package/esm/series/map/map.js.map +1 -1
- package/esm/series/mixin/line-mixin.js +3 -5
- package/esm/series/mixin/line-mixin.js.map +1 -1
- package/esm/series/pie/interface.d.ts +2 -0
- package/esm/series/pie/interface.js.map +1 -1
- package/esm/series/pie/pie-3d.js +6 -6
- package/esm/series/pie/pie-3d.js.map +1 -1
- package/esm/series/pie/pie.d.ts +2 -0
- package/esm/series/pie/pie.js +16 -2
- package/esm/series/pie/pie.js.map +1 -1
- package/esm/series/progress/circular/circular.d.ts +1 -0
- package/esm/series/progress/circular/circular.js +5 -2
- package/esm/series/progress/circular/circular.js.map +1 -1
- package/esm/series/progress/linear/linear.js +5 -5
- package/esm/series/progress/linear/linear.js.map +1 -1
- package/esm/series/radar/animation.js.map +1 -1
- package/esm/series/radar/radar.d.ts +1 -0
- package/esm/series/radar/radar.js +6 -2
- package/esm/series/radar/radar.js.map +1 -1
- package/esm/series/range-area/range-area.js +2 -2
- package/esm/series/range-area/range-area.js.map +1 -1
- package/esm/series/range-column/range-column.d.ts +1 -0
- package/esm/series/range-column/range-column.js +10 -11
- package/esm/series/range-column/range-column.js.map +1 -1
- package/esm/series/rose/rose.d.ts +1 -0
- package/esm/series/rose/rose.js +4 -2
- package/esm/series/rose/rose.js.map +1 -1
- package/esm/series/sankey/sankey.js +7 -9
- package/esm/series/sankey/sankey.js.map +1 -1
- package/esm/series/scatter/scatter.d.ts +1 -0
- package/esm/series/scatter/scatter.js +4 -3
- package/esm/series/scatter/scatter.js.map +1 -1
- package/esm/series/sunburst/sunburst.js +4 -6
- package/esm/series/sunburst/sunburst.js.map +1 -1
- package/esm/series/treemap/treemap.js +10 -9
- package/esm/series/treemap/treemap.js.map +1 -1
- package/esm/series/word-cloud/base.d.ts +1 -0
- package/esm/series/word-cloud/base.js +6 -3
- package/esm/series/word-cloud/base.js.map +1 -1
- package/esm/series/word-cloud/word-cloud-3d.js +2 -3
- package/esm/series/word-cloud/word-cloud-3d.js.map +1 -1
- package/esm/theme/builtin/common/component/axis/cartesian-axis.js +28 -2
- package/esm/theme/builtin/common/component/axis/cartesian-axis.js.map +1 -1
- package/esm/theme/builtin/common/component/indicator.js +1 -1
- package/esm/theme/builtin/common/component/indicator.js.map +1 -1
- package/esm/theme/builtin/common/component/legend/continuous.js +1 -1
- package/esm/theme/builtin/common/component/legend/continuous.js.map +1 -1
- package/esm/theme/builtin/common/component/legend/discrete-legend.js +1 -1
- package/esm/theme/builtin/common/component/legend/discrete-legend.js.map +1 -1
- package/esm/theme/builtin/common/component/mark-area.js +12 -10
- package/esm/theme/builtin/common/component/mark-area.js.map +1 -1
- package/esm/theme/builtin/common/component/mark-line.js +19 -12
- package/esm/theme/builtin/common/component/mark-line.js.map +1 -1
- package/esm/theme/builtin/common/component/mark-point.js +8 -2
- package/esm/theme/builtin/common/component/mark-point.js.map +1 -1
- package/esm/theme/builtin/common/component/poptip.js +1 -1
- package/esm/theme/builtin/common/component/poptip.js.map +1 -1
- package/esm/theme/builtin/common/component/title.js +1 -1
- package/esm/theme/builtin/common/component/title.js.map +1 -1
- package/esm/theme/builtin/common/component/tooltip.js +2 -2
- package/esm/theme/builtin/common/component/tooltip.js.map +1 -1
- package/esm/theme/builtin/common/component/total-label.js +1 -1
- package/esm/theme/builtin/common/component/total-label.js.map +1 -1
- package/esm/theme/builtin/common/series/area.js +4 -1
- package/esm/theme/builtin/common/series/area.js.map +1 -1
- package/esm/theme/builtin/common/series/bar.js +4 -1
- package/esm/theme/builtin/common/series/bar.js.map +1 -1
- package/esm/theme/builtin/common/series/circle-packing.js +4 -1
- package/esm/theme/builtin/common/series/circle-packing.js.map +1 -1
- package/esm/theme/builtin/common/series/correlation.d.ts +2 -0
- package/esm/theme/builtin/common/series/correlation.js +18 -0
- package/esm/theme/builtin/common/series/correlation.js.map +1 -0
- package/esm/theme/builtin/common/series/funnel.js +12 -3
- package/esm/theme/builtin/common/series/funnel.js.map +1 -1
- package/esm/theme/builtin/common/series/index.js +4 -1
- package/esm/theme/builtin/common/series/index.js.map +1 -1
- package/esm/theme/builtin/common/series/line.js +4 -1
- package/esm/theme/builtin/common/series/line.js.map +1 -1
- package/esm/theme/builtin/common/series/map.js +4 -1
- package/esm/theme/builtin/common/series/map.js.map +1 -1
- package/esm/theme/builtin/common/series/pie.js +9 -1
- package/esm/theme/builtin/common/series/pie.js.map +1 -1
- package/esm/theme/builtin/common/series/radar.js +4 -1
- package/esm/theme/builtin/common/series/radar.js.map +1 -1
- package/esm/theme/builtin/common/series/rose.js +5 -1
- package/esm/theme/builtin/common/series/rose.js.map +1 -1
- package/esm/theme/builtin/common/series/scatter.js +4 -1
- package/esm/theme/builtin/common/series/scatter.js.map +1 -1
- package/esm/theme/builtin/common/series/treemap.js +4 -1
- package/esm/theme/builtin/common/series/treemap.js.map +1 -1
- package/esm/theme/builtin/dark/color-scheme.js +1 -1
- package/esm/theme/builtin/dark/color-scheme.js.map +1 -1
- package/esm/theme/builtin/light/color-scheme.js +3 -3
- package/esm/theme/builtin/light/color-scheme.js.map +1 -1
- package/esm/theme/color-scheme/builtin/interface.d.ts +1 -1
- package/esm/theme/color-scheme/builtin/interface.js.map +1 -1
- package/esm/theme/color-scheme/interface.d.ts +1 -1
- package/esm/theme/color-scheme/interface.js.map +1 -1
- package/esm/theme/color-scheme/util.js +4 -7
- package/esm/theme/color-scheme/util.js.map +1 -1
- package/esm/typings/event.d.ts +1 -0
- package/esm/typings/event.js +2 -0
- package/esm/typings/event.js.map +1 -0
- package/esm/typings/spec/chart.d.ts +2 -0
- package/esm/typings/spec/chart.js.map +1 -1
- package/esm/typings/spec/common.d.ts +8 -6
- package/esm/typings/spec/common.js.map +1 -1
- package/esm/typings/tooltip/line.d.ts +1 -0
- package/esm/typings/tooltip/line.js.map +1 -1
- package/esm/typings/visual.d.ts +4 -0
- package/esm/typings/visual.js.map +1 -1
- package/esm/vchart-all.js +4 -2
- package/esm/vchart-all.js.map +1 -1
- package/package.json +11 -8
package/build/index.js
CHANGED
|
@@ -6200,7 +6200,7 @@
|
|
|
6200
6200
|
class DataSet {
|
|
6201
6201
|
constructor(options) {
|
|
6202
6202
|
let name;
|
|
6203
|
-
this.options = options, this.isDataSet = !0, this.transformMap = {}, this.parserMap = {}, this.dataViewMap = {}, this.target = new EventEmitter(),
|
|
6203
|
+
this.options = options, this.isDataSet = !0, this.transformMap = {}, this.parserMap = {}, this.dataViewMap = {}, this.target = new EventEmitter(), name = (null == options ? void 0 : options.name) ? options.name : getUUID("dataset"), this.name = name;
|
|
6204
6204
|
}
|
|
6205
6205
|
getDataView(name) {
|
|
6206
6206
|
return this.dataViewMap[name];
|
|
@@ -6231,6 +6231,7 @@
|
|
|
6231
6231
|
return this.transformMap[name];
|
|
6232
6232
|
}
|
|
6233
6233
|
multipleDataViewAddListener(list, event, call) {
|
|
6234
|
+
this._callMap || (this._callMap = new Map());
|
|
6234
6235
|
let callAd = this._callMap.get(call);
|
|
6235
6236
|
callAd || (callAd = () => {
|
|
6236
6237
|
list.some(l => l.isRunning) || call();
|
|
@@ -6242,10 +6243,12 @@
|
|
|
6242
6243
|
this.multipleDataViewAddListener(Object.values(this.dataViewMap), event, call);
|
|
6243
6244
|
}
|
|
6244
6245
|
multipleDataViewRemoveListener(list, event, call) {
|
|
6245
|
-
|
|
6246
|
-
|
|
6247
|
-
|
|
6248
|
-
|
|
6246
|
+
if (this._callMap) {
|
|
6247
|
+
const callAd = this._callMap.get(call);
|
|
6248
|
+
callAd && list.forEach(l => {
|
|
6249
|
+
l.target.removeListener(event, callAd);
|
|
6250
|
+
}), this._callMap.delete(call);
|
|
6251
|
+
}
|
|
6249
6252
|
}
|
|
6250
6253
|
multipleDataViewUpdateInParse(newData) {
|
|
6251
6254
|
newData.forEach(d => {
|
|
@@ -6275,19 +6278,20 @@
|
|
|
6275
6278
|
constructor(dataSet, options) {
|
|
6276
6279
|
var _this = this;
|
|
6277
6280
|
let name;
|
|
6278
|
-
this.dataSet = dataSet, this.options = options, this.isDataView = !0, this.target = new EventEmitter(), this.parseOption = null, this.transformsArr = [], this.isRunning = !1, this.rawData = {}, this.history = !1, this.
|
|
6281
|
+
this.dataSet = dataSet, this.options = options, this.isDataView = !0, this.target = new EventEmitter(), this.parseOption = null, this.transformsArr = [], this.isRunning = !1, this.rawData = {}, this.history = !1, this.parserData = {}, this.latestData = {}, this._fields = null, this.reRunAllTransform = function () {
|
|
6279
6282
|
let opt = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {
|
|
6280
6283
|
pushHistory: !0,
|
|
6281
6284
|
emitMessage: !0
|
|
6282
6285
|
};
|
|
6283
6286
|
return _this.isRunning = !0, _this.resetTransformData(), _this.transformsArr.forEach(t => {
|
|
6284
|
-
_this.executeTransform(t,
|
|
6287
|
+
_this.executeTransform(t, {
|
|
6288
|
+
pushHistory: opt.pushHistory,
|
|
6285
6289
|
emitMessage: !1
|
|
6286
|
-
})
|
|
6287
|
-
}), _this.isRunning = !1, !1 !==
|
|
6290
|
+
}), _this.isLastTransform(t) && _this.diffLastData();
|
|
6291
|
+
}), _this.isRunning = !1, !1 !== opt.emitMessage && _this.target.emit("change", []), _this;
|
|
6288
6292
|
}, this.markRunning = () => {
|
|
6289
6293
|
this.isRunning = !0, this.target.emit("markRunning", []);
|
|
6290
|
-
}, name = (null == options ? void 0 : options.name) ? options.name : getUUID("dataview"), this.name = name, (null == options ? void 0 : options.history) && (this.history = options.history), this.dataSet.setDataView(name, this), this.setFields(null == options ? void 0 : options.fields);
|
|
6294
|
+
}, name = (null == options ? void 0 : options.name) ? options.name : getUUID("dataview"), this.name = name, (null == options ? void 0 : options.history) && (this.history = options.history, this.historyData = []), this.dataSet.setDataView(name, this), this.setFields(null == options ? void 0 : options.fields);
|
|
6291
6295
|
}
|
|
6292
6296
|
parse(data, options) {
|
|
6293
6297
|
let emit = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !1;
|
|
@@ -6295,7 +6299,6 @@
|
|
|
6295
6299
|
this.isRunning = !0, emit && this.target.emit("beforeParse", []), options && (this.parseOption = options);
|
|
6296
6300
|
const cloneData = this.cloneParseData(data, options);
|
|
6297
6301
|
if (null == options ? void 0 : options.type) {
|
|
6298
|
-
options = cloneDeep(options);
|
|
6299
6302
|
const parserData = (null !== (_a = this.dataSet.getParser(options.type)) && void 0 !== _a ? _a : this.dataSet.getParser("bytejson"))(cloneData, options.options, this);
|
|
6300
6303
|
this.rawData = cloneData, this.parserData = parserData, this.history && this.historyData.push(cloneData, parserData), this.latestData = parserData;
|
|
6301
6304
|
} else this.parserData = cloneData, this.rawData = cloneData, this.history && this.historyData.push(cloneData), this.latestData = cloneData;
|
|
@@ -6312,7 +6315,7 @@
|
|
|
6312
6315
|
}
|
|
6313
6316
|
if (pushOption && this.transformsArr.push(options), execute) {
|
|
6314
6317
|
const lastTag = this.isLastTransform(options);
|
|
6315
|
-
|
|
6318
|
+
this.executeTransform(options), lastTag && this.diffLastData();
|
|
6316
6319
|
}
|
|
6317
6320
|
}
|
|
6318
6321
|
return this.sortTransform(), this.isRunning = !1, this;
|
|
@@ -6321,7 +6324,7 @@
|
|
|
6321
6324
|
return this.transformsArr[this.transformsArr.length - 1] === options;
|
|
6322
6325
|
}
|
|
6323
6326
|
sortTransform() {
|
|
6324
|
-
this.transformsArr.sort((a, b) => {
|
|
6327
|
+
this.transformsArr.length >= 2 && this.transformsArr.sort((a, b) => {
|
|
6325
6328
|
var _a, _b;
|
|
6326
6329
|
return (null !== (_a = a.level) && void 0 !== _a ? _a : 0) - (null !== (_b = b.level) && void 0 !== _b ? _b : 0);
|
|
6327
6330
|
});
|
|
@@ -6342,10 +6345,10 @@
|
|
|
6342
6345
|
this.latestData = this.parserData, this.history && (this.historyData.length = 0, this.historyData.push(this.rawData, this.parserData));
|
|
6343
6346
|
}
|
|
6344
6347
|
enableDiff(keys) {
|
|
6345
|
-
this._diffData = !0, this._diffKeys = keys;
|
|
6348
|
+
this._diffData = !0, this._diffKeys = keys, this._diffMap = new Map(), this._diffRank = 0;
|
|
6346
6349
|
}
|
|
6347
6350
|
disableDiff() {
|
|
6348
|
-
this._diffData = !1, this.
|
|
6351
|
+
this._diffData = !1, this._diffMap = null, this._diffRank = null;
|
|
6349
6352
|
}
|
|
6350
6353
|
resetDiff() {
|
|
6351
6354
|
this._diffMap = new Map(), this._diffRank = 0;
|
|
@@ -6403,7 +6406,7 @@
|
|
|
6403
6406
|
}, !1)) : fieldsOption && (fieldsOption.options.fields = this._fields);
|
|
6404
6407
|
}
|
|
6405
6408
|
destroy() {
|
|
6406
|
-
this.dataSet.removeDataView(this.name), this.
|
|
6409
|
+
this.dataSet.removeDataView(this.name), this._diffMap = null, this._diffRank = null, this.latestData = null, this.rawData = null, this.parserData = null, this.transformsArr = null, this.target = null;
|
|
6407
6410
|
}
|
|
6408
6411
|
}
|
|
6409
6412
|
|
|
@@ -14192,6 +14195,11 @@
|
|
|
14192
14195
|
a.onEnd();
|
|
14193
14196
|
});
|
|
14194
14197
|
}
|
|
14198
|
+
onStart() {
|
|
14199
|
+
this.customAnimates.forEach(a => {
|
|
14200
|
+
a.onStart();
|
|
14201
|
+
});
|
|
14202
|
+
}
|
|
14195
14203
|
onUpdate(end, ratio, out) {
|
|
14196
14204
|
this.updating || (this.updating = !0, this.customAnimates.forEach(a => {
|
|
14197
14205
|
const easing = a.easing,
|
|
@@ -16560,12 +16568,13 @@
|
|
|
16560
16568
|
main: !1
|
|
16561
16569
|
};
|
|
16562
16570
|
this.tryInit();
|
|
16563
|
-
|
|
16564
|
-
|
|
16571
|
+
let layerMode = this.getRecommendedLayerType(options.layerMode);
|
|
16572
|
+
layerMode = options.canvasId ? "static" : layerMode;
|
|
16573
|
+
const layerHandler = this.getLayerHandler(layerMode),
|
|
16565
16574
|
layer = new Layer(stage, this.global, stage.window, Object.assign(Object.assign({
|
|
16566
16575
|
main: !1
|
|
16567
16576
|
}, options), {
|
|
16568
|
-
layerMode:
|
|
16577
|
+
layerMode: layerMode,
|
|
16569
16578
|
canvasId: options.canvasId,
|
|
16570
16579
|
layerHandler: layerHandler
|
|
16571
16580
|
})),
|
|
@@ -25472,7 +25481,8 @@
|
|
|
25472
25481
|
createLayer(canvasId, layerMode) {
|
|
25473
25482
|
const layer = this.layerService.createLayer(this, {
|
|
25474
25483
|
main: !1,
|
|
25475
|
-
layerMode: layerMode
|
|
25484
|
+
layerMode: layerMode,
|
|
25485
|
+
canvasId: canvasId
|
|
25476
25486
|
});
|
|
25477
25487
|
return this.appendChild(layer), layer;
|
|
25478
25488
|
}
|
|
@@ -26136,7 +26146,11 @@
|
|
|
26136
26146
|
return result;
|
|
26137
26147
|
}
|
|
26138
26148
|
containsPoint(graphic, point, params) {
|
|
26139
|
-
|
|
26149
|
+
var _a;
|
|
26150
|
+
return !!(null === (_a = this.pickItem(graphic, point, null, null != params ? params : {
|
|
26151
|
+
pickContext: this.pickContext,
|
|
26152
|
+
pickerService: this
|
|
26153
|
+
})) || void 0 === _a ? void 0 : _a.graphic);
|
|
26140
26154
|
}
|
|
26141
26155
|
pickGroup(group, point, parentMatrix, params) {
|
|
26142
26156
|
let result = {
|
|
@@ -26241,7 +26255,7 @@
|
|
|
26241
26255
|
function intersect$1(a, b, sep) {
|
|
26242
26256
|
return sep > Math.max(b.x1 - a.x2, a.x1 - b.x2, b.y1 - a.y2, a.y1 - b.y2);
|
|
26243
26257
|
}
|
|
26244
|
-
function hasOverlap$
|
|
26258
|
+
function hasOverlap$2(items, pad) {
|
|
26245
26259
|
for (let b, i = 1, n = items.length, a = items[0]; i < n; a = b, ++i) if (b = items[i], intersect$1(a.AABBBounds, b.AABBBounds, pad)) return !0;
|
|
26246
26260
|
return !1;
|
|
26247
26261
|
}
|
|
@@ -26357,7 +26371,7 @@
|
|
|
26357
26371
|
AABBBounds: bounds,
|
|
26358
26372
|
value: scaleTicks[i]
|
|
26359
26373
|
}));
|
|
26360
|
-
for (; items.length >= 3 && hasOverlap$
|
|
26374
|
+
for (; items.length >= 3 && hasOverlap$2(items, labelGap);) items = methods$2.parity(items);
|
|
26361
26375
|
const ticks = items.map(item => item.value);
|
|
26362
26376
|
ticks.length < 3 && labelFlush && (ticks.length > 1 && ticks.pop(), last(ticks) !== last(scaleTicks) && ticks.push(last(scaleTicks))), scaleTicks = ticks;
|
|
26363
26377
|
}
|
|
@@ -26836,7 +26850,7 @@
|
|
|
26836
26850
|
return dataScheme;
|
|
26837
26851
|
}
|
|
26838
26852
|
function queryColorFromColorScheme(colorScheme, colorKey, seriesType) {
|
|
26839
|
-
var _a;
|
|
26853
|
+
var _a, _b;
|
|
26840
26854
|
const scheme = !isValid$1(seriesType) ? colorScheme.default : (_a = colorScheme[seriesType]) !== null && _a !== void 0 ? _a : colorScheme.default;
|
|
26841
26855
|
if (!scheme) {
|
|
26842
26856
|
return undefined;
|
|
@@ -26844,15 +26858,7 @@
|
|
|
26844
26858
|
let color;
|
|
26845
26859
|
const { palette } = scheme;
|
|
26846
26860
|
if (isObject$2(palette)) {
|
|
26847
|
-
|
|
26848
|
-
color = palette[key];
|
|
26849
|
-
if (isValid$1(color)) {
|
|
26850
|
-
break;
|
|
26851
|
-
}
|
|
26852
|
-
}
|
|
26853
|
-
if (!color) {
|
|
26854
|
-
color = colorKey.default;
|
|
26855
|
-
}
|
|
26861
|
+
color = (_b = palette[colorKey.key]) !== null && _b !== void 0 ? _b : colorKey.default;
|
|
26856
26862
|
}
|
|
26857
26863
|
if (!color) {
|
|
26858
26864
|
return undefined;
|
|
@@ -27196,15 +27202,15 @@
|
|
|
27196
27202
|
disableFontColor: '#bcc1cb',
|
|
27197
27203
|
labelReverseFontColor: '#ffffff',
|
|
27198
27204
|
axisGridColor: '#f1f2f5',
|
|
27199
|
-
axisDomainColor: '#
|
|
27200
|
-
|
|
27201
|
-
dataZoomHandlerStrokeColor: '#AEB5BE',
|
|
27205
|
+
axisDomainColor: '#d9dde4',
|
|
27206
|
+
dataZoomHandlerStrokeColor: '#aeb5be',
|
|
27202
27207
|
dataZoomHandlerFillColor: '#ffffff',
|
|
27203
27208
|
dataZoomBackgroundColor: '#f1f3f4',
|
|
27204
27209
|
dataZoomChartColor: '#c9ced8',
|
|
27205
27210
|
dataZoomSelectedColor: '#0040ff',
|
|
27206
27211
|
scrollBarSliderColor: '#000000',
|
|
27207
27212
|
tooltipBackgroundColor: '#ffffff',
|
|
27213
|
+
markLabelBackgroundColor: '#ffc528',
|
|
27208
27214
|
titleFontColor: '#21252c',
|
|
27209
27215
|
labelFontColor: '#89909d'
|
|
27210
27216
|
}
|
|
@@ -27217,7 +27223,7 @@
|
|
|
27217
27223
|
offset: 5,
|
|
27218
27224
|
position: 'top',
|
|
27219
27225
|
style: {
|
|
27220
|
-
stroke: '
|
|
27226
|
+
stroke: { type: 'palette', key: 'backgroundColor' },
|
|
27221
27227
|
lineWidth: 2
|
|
27222
27228
|
}
|
|
27223
27229
|
},
|
|
@@ -27235,7 +27241,7 @@
|
|
|
27235
27241
|
offset: 5,
|
|
27236
27242
|
style: {
|
|
27237
27243
|
lineWidth: 2,
|
|
27238
|
-
stroke: '
|
|
27244
|
+
stroke: { type: 'palette', key: 'backgroundColor' }
|
|
27239
27245
|
}
|
|
27240
27246
|
}
|
|
27241
27247
|
};
|
|
@@ -27328,7 +27334,7 @@
|
|
|
27328
27334
|
const funnel$1 = {
|
|
27329
27335
|
transform: {
|
|
27330
27336
|
style: {
|
|
27331
|
-
fill: '
|
|
27337
|
+
fill: { type: 'palette', key: 'axisGridColor' }
|
|
27332
27338
|
}
|
|
27333
27339
|
},
|
|
27334
27340
|
label: {
|
|
@@ -27342,7 +27348,7 @@
|
|
|
27342
27348
|
style: {
|
|
27343
27349
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
27344
27350
|
lineHeight: THEME_CONSTANTS.l4LineHeight,
|
|
27345
|
-
fill: '
|
|
27351
|
+
fill: { type: 'palette', key: 'secondaryFontColor' }
|
|
27346
27352
|
},
|
|
27347
27353
|
line: {
|
|
27348
27354
|
style: {
|
|
@@ -27354,7 +27360,7 @@
|
|
|
27354
27360
|
style: {
|
|
27355
27361
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
27356
27362
|
lineHeight: THEME_CONSTANTS.l4LineHeight,
|
|
27357
|
-
fill: '
|
|
27363
|
+
fill: { type: 'palette', key: 'secondaryFontColor' },
|
|
27358
27364
|
textBaseline: 'middle'
|
|
27359
27365
|
}
|
|
27360
27366
|
}
|
|
@@ -27448,7 +27454,7 @@
|
|
|
27448
27454
|
offset: 5,
|
|
27449
27455
|
style: {
|
|
27450
27456
|
lineWidth: 2,
|
|
27451
|
-
stroke: '
|
|
27457
|
+
stroke: { type: 'palette', key: 'backgroundColor' }
|
|
27452
27458
|
}
|
|
27453
27459
|
},
|
|
27454
27460
|
point: {
|
|
@@ -27498,7 +27504,7 @@
|
|
|
27498
27504
|
lineHeight: THEME_CONSTANTS.l6LineHeight,
|
|
27499
27505
|
textBaseline: 'middle',
|
|
27500
27506
|
fill: { type: 'palette', key: 'secondaryFontColor', default: '#89909d' },
|
|
27501
|
-
stroke: '
|
|
27507
|
+
stroke: { type: 'palette', key: 'backgroundColor' }
|
|
27502
27508
|
}
|
|
27503
27509
|
}
|
|
27504
27510
|
};
|
|
@@ -27515,9 +27521,14 @@
|
|
|
27515
27521
|
position: 'outside',
|
|
27516
27522
|
style: {
|
|
27517
27523
|
fontWeight: 'normal',
|
|
27518
|
-
stroke: '
|
|
27524
|
+
stroke: { type: 'palette', key: 'backgroundColor' },
|
|
27519
27525
|
fillOpacity: 1
|
|
27520
27526
|
}
|
|
27527
|
+
},
|
|
27528
|
+
innerLabel: {
|
|
27529
|
+
style: {
|
|
27530
|
+
lineWidth: 2
|
|
27531
|
+
}
|
|
27521
27532
|
}
|
|
27522
27533
|
};
|
|
27523
27534
|
|
|
@@ -27541,7 +27552,7 @@
|
|
|
27541
27552
|
offset: 5,
|
|
27542
27553
|
style: {
|
|
27543
27554
|
lineWidth: 2,
|
|
27544
|
-
stroke: '
|
|
27555
|
+
stroke: { type: 'palette', key: 'backgroundColor' }
|
|
27545
27556
|
}
|
|
27546
27557
|
},
|
|
27547
27558
|
point: {
|
|
@@ -27566,7 +27577,7 @@
|
|
|
27566
27577
|
position: 'top',
|
|
27567
27578
|
style: {
|
|
27568
27579
|
lineWidth: 2,
|
|
27569
|
-
stroke: '
|
|
27580
|
+
stroke: { type: 'palette', key: 'backgroundColor' }
|
|
27570
27581
|
}
|
|
27571
27582
|
}
|
|
27572
27583
|
};
|
|
@@ -27643,7 +27654,7 @@
|
|
|
27643
27654
|
padding: THEME_CONSTANTS.l5FontSize * 2,
|
|
27644
27655
|
style: {
|
|
27645
27656
|
fill: 'black',
|
|
27646
|
-
stroke: '
|
|
27657
|
+
stroke: { type: 'palette', key: 'backgroundColor' },
|
|
27647
27658
|
lineWidth: 2,
|
|
27648
27659
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
27649
27660
|
lineHeight: THEME_CONSTANTS.l5LineHeight,
|
|
@@ -28695,6 +28706,10 @@
|
|
|
28695
28706
|
}
|
|
28696
28707
|
}
|
|
28697
28708
|
|
|
28709
|
+
const delayMap$3 = {
|
|
28710
|
+
debounce: debounce,
|
|
28711
|
+
throttle: throttle
|
|
28712
|
+
};
|
|
28698
28713
|
let ScrollBar$1 = class ScrollBar extends AbstractComponent {
|
|
28699
28714
|
constructor(attributes) {
|
|
28700
28715
|
super(merge$1({}, ScrollBar.defaultAttributes, attributes)), this.name = "scrollbar", this._onRailPointerDown = e => {
|
|
@@ -28729,29 +28744,44 @@
|
|
|
28729
28744
|
} = this.attribute;
|
|
28730
28745
|
this._prePos = "horizontal" === direction ? e.clientX : e.clientY, "browser" === vglobal.env ? (vglobal.addEventListener("pointermove", this._onSliderPointerMove, {
|
|
28731
28746
|
capture: !0
|
|
28732
|
-
}), vglobal.addEventListener("pointerup", this._onSliderPointerUp)) : (this.
|
|
28747
|
+
}), vglobal.addEventListener("pointerup", this._onSliderPointerUp)) : (this.stage.addEventListener("pointermove", this._onSliderPointerMove, {
|
|
28733
28748
|
capture: !0
|
|
28734
|
-
}), this.
|
|
28735
|
-
}, this.
|
|
28736
|
-
e.stopPropagation();
|
|
28749
|
+
}), this.stage.addEventListener("pointerup", this._onSliderPointerUp), this.stage.addEventListener("pointerupoutside", this._onSliderPointerUp));
|
|
28750
|
+
}, this._computeScrollValue = e => {
|
|
28737
28751
|
const {
|
|
28738
28752
|
direction: direction
|
|
28739
28753
|
} = this.attribute;
|
|
28740
28754
|
let currentScrollValue,
|
|
28741
28755
|
currentPos,
|
|
28742
28756
|
delta = 0;
|
|
28757
|
+
const {
|
|
28758
|
+
width: width,
|
|
28759
|
+
height: height
|
|
28760
|
+
} = this._getSliderRenderBounds();
|
|
28761
|
+
return "vertical" === direction ? (currentPos = e.clientY, delta = currentPos - this._prePos, currentScrollValue = delta / height) : (currentPos = e.clientX, delta = currentPos - this._prePos, currentScrollValue = delta / width), [currentPos, currentScrollValue];
|
|
28762
|
+
}, this._onSliderPointerMove = delayMap$3[this.attribute.delayType](e => {
|
|
28763
|
+
e.stopPropagation();
|
|
28743
28764
|
const preScrollRange = this.getScrollRange(),
|
|
28744
|
-
|
|
28745
|
-
|
|
28746
|
-
|
|
28747
|
-
|
|
28748
|
-
|
|
28749
|
-
|
|
28750
|
-
|
|
28765
|
+
[currentPos, currentScrollValue] = this._computeScrollValue(e);
|
|
28766
|
+
this.setScrollRange([preScrollRange[0] + currentScrollValue, preScrollRange[1] + currentScrollValue], !0), this._prePos = currentPos;
|
|
28767
|
+
}, this.attribute.delayTime), this._onSliderPointerUp = e => {
|
|
28768
|
+
e.preventDefault();
|
|
28769
|
+
const {
|
|
28770
|
+
realTime = !0,
|
|
28771
|
+
range: preRange,
|
|
28772
|
+
limitRange = [0, 1]
|
|
28773
|
+
} = this.attribute,
|
|
28774
|
+
preScrollRange = this.getScrollRange(),
|
|
28775
|
+
[currentPos, currentScrollValue] = this._computeScrollValue(e),
|
|
28776
|
+
range = [preScrollRange[0] + currentScrollValue, preScrollRange[1] + currentScrollValue];
|
|
28777
|
+
realTime || this._onChange({
|
|
28778
|
+
pre: preRange,
|
|
28779
|
+
value: clampRange$1(range, limitRange[0], limitRange[1])
|
|
28780
|
+
}), "browser" === vglobal.env ? (vglobal.removeEventListener("pointermove", this._onSliderPointerMove, {
|
|
28751
28781
|
capture: !0
|
|
28752
|
-
}), vglobal.removeEventListener("pointerup", this._onSliderPointerUp)) : (this.
|
|
28782
|
+
}), vglobal.removeEventListener("pointerup", this._onSliderPointerUp)) : (this.stage.removeEventListener("pointermove", this._onSliderPointerMove, {
|
|
28753
28783
|
capture: !0
|
|
28754
|
-
}), this.
|
|
28784
|
+
}), this.stage.removeEventListener("pointerup", this._onSliderPointerUp), this.stage.removeEventListener("pointerupoutside", this._onSliderPointerUp));
|
|
28755
28785
|
};
|
|
28756
28786
|
}
|
|
28757
28787
|
setScrollRange(range) {
|
|
@@ -28760,14 +28790,15 @@
|
|
|
28760
28790
|
const {
|
|
28761
28791
|
direction = "horizontal",
|
|
28762
28792
|
limitRange = [0, 1],
|
|
28763
|
-
range: preRange
|
|
28793
|
+
range: preRange,
|
|
28794
|
+
realTime = !0
|
|
28764
28795
|
} = this.attribute,
|
|
28765
28796
|
currScrollRange = clampRange$1(range, limitRange[0], limitRange[1]);
|
|
28766
28797
|
if (render) {
|
|
28767
28798
|
const sliderPos = this._getSliderPos(currScrollRange);
|
|
28768
28799
|
this._slider && ("horizontal" === direction ? this._slider.setAttribute("x", sliderPos[0], !0) : this._slider.setAttribute("y", sliderPos[0], !0), (null === (_a = this.stage) || void 0 === _a ? void 0 : _a.autoRender) || null === (_b = this.stage) || void 0 === _b || _b.renderNextFrame());
|
|
28769
28800
|
}
|
|
28770
|
-
this.attribute.range = currScrollRange, this._onChange({
|
|
28801
|
+
this.attribute.range = currScrollRange, realTime && this._onChange({
|
|
28771
28802
|
pre: preRange,
|
|
28772
28803
|
value: currScrollRange
|
|
28773
28804
|
});
|
|
@@ -28776,7 +28807,12 @@
|
|
|
28776
28807
|
return this.attribute.range;
|
|
28777
28808
|
}
|
|
28778
28809
|
bindEvents() {
|
|
28779
|
-
this.attribute.disableTriggerEvent
|
|
28810
|
+
if (this.attribute.disableTriggerEvent) return;
|
|
28811
|
+
const {
|
|
28812
|
+
delayType = "throttle",
|
|
28813
|
+
delayTime = 0
|
|
28814
|
+
} = this.attribute;
|
|
28815
|
+
this._rail && this._rail.addEventListener("pointerdown", delayMap$3[delayType](this._onRailPointerDown, delayTime)), this._slider && this._slider.addEventListener("pointerdown", this._onSliderPointerDown);
|
|
28780
28816
|
}
|
|
28781
28817
|
render() {
|
|
28782
28818
|
this._reset();
|
|
@@ -28906,7 +28942,10 @@
|
|
|
28906
28942
|
fill: "rgba(0, 0, 0, .0)"
|
|
28907
28943
|
},
|
|
28908
28944
|
padding: 2,
|
|
28909
|
-
scrollRange: [0, 1]
|
|
28945
|
+
scrollRange: [0, 1],
|
|
28946
|
+
delayType: "throttle",
|
|
28947
|
+
delayTime: 0,
|
|
28948
|
+
realTime: !0
|
|
28910
28949
|
};
|
|
28911
28950
|
|
|
28912
28951
|
function traverseGroup(group, cb) {
|
|
@@ -30015,6 +30054,178 @@
|
|
|
30015
30054
|
easing: "linear"
|
|
30016
30055
|
};
|
|
30017
30056
|
|
|
30057
|
+
function polarToCartesian(point) {
|
|
30058
|
+
return point.radius ? {
|
|
30059
|
+
x: Math.cos(point.angle) * point.radius,
|
|
30060
|
+
y: Math.sin(point.angle) * point.radius
|
|
30061
|
+
} : {
|
|
30062
|
+
x: 0,
|
|
30063
|
+
y: 0
|
|
30064
|
+
};
|
|
30065
|
+
}
|
|
30066
|
+
function circlePoint(x0, y0, radius, radian) {
|
|
30067
|
+
const offset = polarToCartesian({
|
|
30068
|
+
radius: radius,
|
|
30069
|
+
angle: radian
|
|
30070
|
+
});
|
|
30071
|
+
return {
|
|
30072
|
+
x: x0 + offset.x,
|
|
30073
|
+
y: y0 + offset.y
|
|
30074
|
+
};
|
|
30075
|
+
}
|
|
30076
|
+
function computeQuadrant(angle) {
|
|
30077
|
+
return (angle = normalizeAngle(angle)) > 0 && angle <= Math.PI / 2 ? 2 : angle > Math.PI / 2 && angle <= Math.PI ? 3 : angle > Math.PI && angle <= 3 * Math.PI / 2 ? 4 : 1;
|
|
30078
|
+
}
|
|
30079
|
+
function normalizeAngle(angle) {
|
|
30080
|
+
for (; angle < 0;) angle += 2 * Math.PI;
|
|
30081
|
+
for (; angle >= 2 * Math.PI;) angle -= 2 * Math.PI;
|
|
30082
|
+
return angle;
|
|
30083
|
+
}
|
|
30084
|
+
function isQuadrantLeft(quadrant) {
|
|
30085
|
+
return 3 === quadrant || 4 === quadrant;
|
|
30086
|
+
}
|
|
30087
|
+
function isQuadrantRight(quadrant) {
|
|
30088
|
+
return 1 === quadrant || 2 === quadrant;
|
|
30089
|
+
}
|
|
30090
|
+
function lineCirclePoints(a, b, c, x0, y0, r) {
|
|
30091
|
+
if (0 === a && 0 === b || r <= 0) return [];
|
|
30092
|
+
if (0 === a) {
|
|
30093
|
+
const y1 = -c / b,
|
|
30094
|
+
fd = r ** 2 - (y1 - y0) ** 2;
|
|
30095
|
+
if (fd < 0) return [];
|
|
30096
|
+
if (0 === fd) return [{
|
|
30097
|
+
x: x0,
|
|
30098
|
+
y: y1
|
|
30099
|
+
}];
|
|
30100
|
+
return [{
|
|
30101
|
+
x: Math.sqrt(fd) + x0,
|
|
30102
|
+
y: y1
|
|
30103
|
+
}, {
|
|
30104
|
+
x: -Math.sqrt(fd) + x0,
|
|
30105
|
+
y: y1
|
|
30106
|
+
}];
|
|
30107
|
+
}
|
|
30108
|
+
if (0 === b) {
|
|
30109
|
+
const x1 = -c / a,
|
|
30110
|
+
fd = r ** 2 - (x1 - x0) ** 2;
|
|
30111
|
+
if (fd < 0) return [];
|
|
30112
|
+
if (0 === fd) return [{
|
|
30113
|
+
x: x1,
|
|
30114
|
+
y: y0
|
|
30115
|
+
}];
|
|
30116
|
+
return [{
|
|
30117
|
+
x: x1,
|
|
30118
|
+
y: Math.sqrt(fd) + y0
|
|
30119
|
+
}, {
|
|
30120
|
+
x: x1,
|
|
30121
|
+
y: -Math.sqrt(fd) + y0
|
|
30122
|
+
}];
|
|
30123
|
+
}
|
|
30124
|
+
const fa = (b / a) ** 2 + 1,
|
|
30125
|
+
fb = 2 * ((c / a + x0) * (b / a) - y0),
|
|
30126
|
+
fd = fb ** 2 - 4 * fa * ((c / a + x0) ** 2 + y0 ** 2 - r ** 2);
|
|
30127
|
+
if (fd < 0) return [];
|
|
30128
|
+
const y1 = (-fb + Math.sqrt(fd)) / (2 * fa),
|
|
30129
|
+
y2 = (-fb - Math.sqrt(fd)) / (2 * fa),
|
|
30130
|
+
x1 = -(b * y1 + c) / a;
|
|
30131
|
+
return 0 === fd ? [{
|
|
30132
|
+
x: x1,
|
|
30133
|
+
y: y1
|
|
30134
|
+
}] : [{
|
|
30135
|
+
x: x1,
|
|
30136
|
+
y: y1
|
|
30137
|
+
}, {
|
|
30138
|
+
x: -(b * y2 + c) / a,
|
|
30139
|
+
y: y2
|
|
30140
|
+
}];
|
|
30141
|
+
}
|
|
30142
|
+
function connectLineRadian(radius, length) {
|
|
30143
|
+
return length > 2 * radius ? NaN : 2 * Math.asin(length / 2 / radius);
|
|
30144
|
+
}
|
|
30145
|
+
function checkBoundsOverlap(boundsA, boundsB) {
|
|
30146
|
+
const {
|
|
30147
|
+
x1: ax1,
|
|
30148
|
+
y1: ay1,
|
|
30149
|
+
x2: ax2,
|
|
30150
|
+
y2: ay2
|
|
30151
|
+
} = boundsA,
|
|
30152
|
+
{
|
|
30153
|
+
x1: bx1,
|
|
30154
|
+
y1: by1,
|
|
30155
|
+
x2: bx2,
|
|
30156
|
+
y2: by2
|
|
30157
|
+
} = boundsB;
|
|
30158
|
+
return !(ax1 <= bx1 && ax2 <= bx1 || ax1 >= bx2 && ax2 >= bx2 || ay1 <= by1 && ay2 <= by1 || ay1 >= by2 && ay2 >= by2);
|
|
30159
|
+
}
|
|
30160
|
+
const labelingPoint = function (textBounds, graphicBounds) {
|
|
30161
|
+
let position = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "top";
|
|
30162
|
+
let offset = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 0;
|
|
30163
|
+
if (!textBounds) return;
|
|
30164
|
+
const {
|
|
30165
|
+
x1: x1,
|
|
30166
|
+
y1: y1,
|
|
30167
|
+
x2: x2,
|
|
30168
|
+
y2: y2
|
|
30169
|
+
} = textBounds,
|
|
30170
|
+
width = Math.abs(x2 - x1),
|
|
30171
|
+
height = Math.abs(y2 - y1),
|
|
30172
|
+
anchorX = (graphicBounds.x1 + graphicBounds.x2) / 2,
|
|
30173
|
+
anchorY = (graphicBounds.y1 + graphicBounds.y2) / 2;
|
|
30174
|
+
let sx = 0,
|
|
30175
|
+
sy = 0,
|
|
30176
|
+
offsetX = 0,
|
|
30177
|
+
offsetY = 0;
|
|
30178
|
+
graphicBounds && (offsetX = Math.abs(graphicBounds.x1 - graphicBounds.x2) / 2, offsetY = Math.abs(graphicBounds.y1 - graphicBounds.y2) / 2);
|
|
30179
|
+
const angle = {
|
|
30180
|
+
"top-right": -235,
|
|
30181
|
+
"top-left": 235,
|
|
30182
|
+
"bottom-right": 45,
|
|
30183
|
+
"bottom-left": -45
|
|
30184
|
+
};
|
|
30185
|
+
switch (position) {
|
|
30186
|
+
case "top":
|
|
30187
|
+
sy = -1;
|
|
30188
|
+
break;
|
|
30189
|
+
case "bottom":
|
|
30190
|
+
sy = 1;
|
|
30191
|
+
break;
|
|
30192
|
+
case "left":
|
|
30193
|
+
sx = -1;
|
|
30194
|
+
break;
|
|
30195
|
+
case "right":
|
|
30196
|
+
sx = 1;
|
|
30197
|
+
break;
|
|
30198
|
+
case "bottom-left":
|
|
30199
|
+
case "bottom-right":
|
|
30200
|
+
case "top-left":
|
|
30201
|
+
case "top-right":
|
|
30202
|
+
sx = Math.sin(angle[position] * (Math.PI / 180)), sy = Math.cos(angle[position] * (Math.PI / 180));
|
|
30203
|
+
break;
|
|
30204
|
+
case "center":
|
|
30205
|
+
sx = 0, sy = 0;
|
|
30206
|
+
}
|
|
30207
|
+
return {
|
|
30208
|
+
x: anchorX + sx * (offset + offsetX) + Math.sign(sx) * (width / 2),
|
|
30209
|
+
y: anchorY + sy * (offset + offsetY) + Math.sign(sy) * (height / 2)
|
|
30210
|
+
};
|
|
30211
|
+
};
|
|
30212
|
+
const getPointsOfLineArea = graphic => {
|
|
30213
|
+
if (!graphic || !graphic.attribute) return [];
|
|
30214
|
+
const {
|
|
30215
|
+
points: points,
|
|
30216
|
+
segments: segments
|
|
30217
|
+
} = graphic.attribute;
|
|
30218
|
+
if (segments && segments.length) {
|
|
30219
|
+
const res = [];
|
|
30220
|
+
return segments.forEach(seg => {
|
|
30221
|
+
seg.points.forEach(point => {
|
|
30222
|
+
res.push(point);
|
|
30223
|
+
});
|
|
30224
|
+
}), res;
|
|
30225
|
+
}
|
|
30226
|
+
return points;
|
|
30227
|
+
};
|
|
30228
|
+
|
|
30018
30229
|
class LabelBase extends AbstractComponent {
|
|
30019
30230
|
setBitmap(bitmap) {
|
|
30020
30231
|
this._bitmap = bitmap;
|
|
@@ -30043,16 +30254,17 @@
|
|
|
30043
30254
|
}, this._handleRelatedGraphicSetState = e => {
|
|
30044
30255
|
var _a, _b, _c;
|
|
30045
30256
|
if ((null === (_a = e.detail) || void 0 === _a ? void 0 : _a.type) === AttributeUpdateType.STATE) {
|
|
30046
|
-
const currentStates = null !== (_c = null === (_b = e.target) || void 0 === _b ? void 0 : _b.currentStates) && void 0 !== _c ? _c : []
|
|
30047
|
-
|
|
30048
|
-
|
|
30257
|
+
const currentStates = null !== (_c = null === (_b = e.target) || void 0 === _b ? void 0 : _b.currentStates) && void 0 !== _c ? _c : [];
|
|
30258
|
+
(this._isCollectionBase ? [...this._graphicToText.values()] : [this._graphicToText.get(e.target)]).forEach(label => {
|
|
30259
|
+
label && (label.text && label.text.useStates(currentStates), label.labelLine && label.labelLine.useStates(currentStates));
|
|
30260
|
+
});
|
|
30049
30261
|
}
|
|
30050
30262
|
};
|
|
30051
30263
|
}
|
|
30052
30264
|
labeling(textBounds, graphicBounds, position, offset) {}
|
|
30053
30265
|
_labelLine(text) {}
|
|
30054
30266
|
render() {
|
|
30055
|
-
if (this._prepare(), isNil$1(this._idToGraphic)) return;
|
|
30267
|
+
if (this._prepare(), isNil$1(this._idToGraphic) || this._isCollectionBase && isNil$1(this._idToPoint)) return;
|
|
30056
30268
|
const {
|
|
30057
30269
|
overlap: overlap,
|
|
30058
30270
|
smartInvert: smartInvert,
|
|
@@ -30062,7 +30274,7 @@
|
|
|
30062
30274
|
} = this.attribute;
|
|
30063
30275
|
let labels,
|
|
30064
30276
|
data = this.attribute.data;
|
|
30065
|
-
isFunction$1(dataFilter) && (data = dataFilter(data)), labels = isFunction$1(customLayoutFunc) ? customLayoutFunc(data, d => this.
|
|
30277
|
+
isFunction$1(dataFilter) && (data = dataFilter(data)), labels = isFunction$1(customLayoutFunc) ? customLayoutFunc(data, this.getRelatedGrphic, this._isCollectionBase ? d => this._idToPoint.get(d.id) : null) : this._layout(data), isFunction$1(customOverlapFunc) ? labels = customOverlapFunc(labels, this.getRelatedGrphic, this._isCollectionBase ? d => this._idToPoint.get(d.id) : null) : !1 !== overlap && (labels = this._overlapping(labels)), !1 !== smartInvert && this._smartInvert(labels), this._renderLabels(labels);
|
|
30066
30278
|
}
|
|
30067
30279
|
_bindEvent(target) {
|
|
30068
30280
|
if (this.attribute.disableTriggerEvent) return;
|
|
@@ -30088,24 +30300,35 @@
|
|
|
30088
30300
|
return this._bindEvent(text), this._setStatesOfText(text), text;
|
|
30089
30301
|
}
|
|
30090
30302
|
_prepare() {
|
|
30091
|
-
var _a;
|
|
30303
|
+
var _a, _b, _c, _d;
|
|
30092
30304
|
const currentBaseMarks = [];
|
|
30093
30305
|
let baseMarks;
|
|
30094
30306
|
if (baseMarks = isFunction$1(this.attribute.getBaseMarks) ? this.attribute.getBaseMarks() : getMarksByName(this.getRootNode(), this.attribute.baseMarkGroupName), baseMarks.forEach(mark => {
|
|
30095
30307
|
"willRelease" !== mark.releaseStatus && currentBaseMarks.push(mark);
|
|
30096
|
-
}), null === (_a = this._idToGraphic) || void 0 === _a || _a.clear(), this._baseMarks = currentBaseMarks, !currentBaseMarks || 0 === currentBaseMarks.length) return;
|
|
30308
|
+
}), null === (_a = this._idToGraphic) || void 0 === _a || _a.clear(), null === (_b = this._idToPoint) || void 0 === _b || _b.clear(), this._baseMarks = currentBaseMarks, this._isCollectionBase = "line" === (null === (_c = null == currentBaseMarks ? void 0 : currentBaseMarks[0]) || void 0 === _c ? void 0 : _c.type) || "area" === (null === (_d = null == currentBaseMarks ? void 0 : currentBaseMarks[0]) || void 0 === _d ? void 0 : _d.type), !currentBaseMarks || 0 === currentBaseMarks.length) return;
|
|
30097
30309
|
const {
|
|
30098
30310
|
data: data
|
|
30099
30311
|
} = this.attribute;
|
|
30100
|
-
if (data && 0 !== data.length) {
|
|
30101
|
-
this.
|
|
30312
|
+
if (data && 0 !== data.length) if (this._idToGraphic || (this._idToGraphic = new Map()), this._isCollectionBase) {
|
|
30313
|
+
this._idToPoint || (this._idToPoint = new Map());
|
|
30314
|
+
let cur = 0;
|
|
30102
30315
|
for (let i = 0; i < currentBaseMarks.length; i++) {
|
|
30103
|
-
const
|
|
30104
|
-
|
|
30105
|
-
|
|
30316
|
+
const baseMark = currentBaseMarks[i],
|
|
30317
|
+
points = getPointsOfLineArea(baseMark);
|
|
30318
|
+
if (null == points ? void 0 : points.length) for (let j = 0; j < points.length; j++) {
|
|
30319
|
+
const textData = data[cur];
|
|
30320
|
+
textData && points[j] && (isValid$1(textData.id) || (textData.id = `vrender-component-${this.name}-${cur}`), this._idToPoint.set(textData.id, points[j]), this._idToGraphic.set(textData.id, baseMark)), cur++;
|
|
30321
|
+
}
|
|
30106
30322
|
}
|
|
30323
|
+
} else for (let i = 0; i < currentBaseMarks.length; i++) {
|
|
30324
|
+
const textData = data[i],
|
|
30325
|
+
baseMark = currentBaseMarks[i];
|
|
30326
|
+
textData && baseMark && (isValid$1(textData.id) || (textData.id = `vrender-component-${this.name}-${i}`), this._idToGraphic.set(textData.id, baseMark));
|
|
30107
30327
|
}
|
|
30108
30328
|
}
|
|
30329
|
+
getRelatedGrphic(item) {
|
|
30330
|
+
return this._idToGraphic.get(item.id);
|
|
30331
|
+
}
|
|
30109
30332
|
_layout() {
|
|
30110
30333
|
let data = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
30111
30334
|
const {
|
|
@@ -30116,13 +30339,13 @@
|
|
|
30116
30339
|
labels = [];
|
|
30117
30340
|
for (let i = 0; i < data.length; i++) {
|
|
30118
30341
|
const textData = data[i],
|
|
30119
|
-
baseMark = this.
|
|
30342
|
+
baseMark = this.getRelatedGrphic(textData),
|
|
30120
30343
|
labelAttribute = Object.assign(Object.assign({
|
|
30121
|
-
fill: baseMark.attribute.fill
|
|
30344
|
+
fill: this._isCollectionBase ? isArray$1(baseMark.attribute.stroke) ? baseMark.attribute.stroke.find(entry => !!entry && !0 !== entry) : baseMark.attribute.stroke : baseMark.attribute.fill
|
|
30122
30345
|
}, textStyle), textData),
|
|
30123
30346
|
text = this._createLabelText(labelAttribute),
|
|
30124
30347
|
textBounds = this.getGraphicBounds(text),
|
|
30125
|
-
graphicBounds = this.getGraphicBounds(baseMark, {
|
|
30348
|
+
graphicBounds = this._isCollectionBase ? this.getGraphicBounds(null, this._idToPoint.get(textData.id)) : this.getGraphicBounds(baseMark, {
|
|
30126
30349
|
x: textData.x,
|
|
30127
30350
|
y: textData.y
|
|
30128
30351
|
}),
|
|
@@ -30163,7 +30386,7 @@
|
|
|
30163
30386
|
for (let i = 0; i < labels.length; i++) {
|
|
30164
30387
|
if (!1 === labels[i].visible) continue;
|
|
30165
30388
|
const text = labels[i],
|
|
30166
|
-
baseMark = this.
|
|
30389
|
+
baseMark = this.getRelatedGrphic(text.attribute);
|
|
30167
30390
|
if (text.update(), !isRectIntersect(baseMark.AABBBounds, {
|
|
30168
30391
|
x1: 0,
|
|
30169
30392
|
x2: bmpTool.width,
|
|
@@ -30181,7 +30404,7 @@
|
|
|
30181
30404
|
}
|
|
30182
30405
|
}
|
|
30183
30406
|
let hasPlace = !1;
|
|
30184
|
-
for (let j = 0; j < strategy.length; j++) if (hasPlace = place$2(bmpTool, bitmap, strategy[j], this.attribute, text, this.getGraphicBounds(baseMark, labels[i]), this.labeling), !1 !== hasPlace) {
|
|
30407
|
+
for (let j = 0; j < strategy.length; j++) if (hasPlace = place$2(bmpTool, bitmap, strategy[j], this.attribute, text, this._isCollectionBase ? this.getGraphicBounds(null, this._idToPoint.get(labels[i].attribute.id)) : this.getGraphicBounds(baseMark, labels[i].attribute), this.labeling), !1 !== hasPlace) {
|
|
30185
30408
|
text.setAttributes({
|
|
30186
30409
|
x: hasPlace.x,
|
|
30187
30410
|
y: hasPlace.y
|
|
@@ -30241,10 +30464,12 @@
|
|
|
30241
30464
|
labels.forEach((text, index) => {
|
|
30242
30465
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
30243
30466
|
const labelLine = this._labelLine(text),
|
|
30244
|
-
relatedGraphic = this.
|
|
30245
|
-
|
|
30467
|
+
relatedGraphic = this.getRelatedGrphic(text.attribute),
|
|
30468
|
+
textId = text.attribute.id,
|
|
30469
|
+
textKey = this._isCollectionBase ? textId : relatedGraphic,
|
|
30470
|
+
state = (null == prevTextMap ? void 0 : prevTextMap.get(textKey)) ? "update" : "enter";
|
|
30246
30471
|
if ("enter" === state) {
|
|
30247
|
-
if (texts.push(text), currentTextMap.set(
|
|
30472
|
+
if (texts.push(text), currentTextMap.set(textKey, labelLine ? {
|
|
30248
30473
|
text: text,
|
|
30249
30474
|
labelLine: labelLine
|
|
30250
30475
|
} : {
|
|
@@ -30254,7 +30479,7 @@
|
|
|
30254
30479
|
from: from,
|
|
30255
30480
|
to: to
|
|
30256
30481
|
} = getAnimationAttributes(text.attribute, "fadeIn");
|
|
30257
|
-
this.add(text), labelLine && (this._setStatesOfLabelLine(labelLine), this.add(labelLine)), this._syncStateWithRelatedGraphic(relatedGraphic), relatedGraphic.once("animate-bind",
|
|
30482
|
+
this.add(text), labelLine && (this._setStatesOfLabelLine(labelLine), this.add(labelLine)), this._syncStateWithRelatedGraphic(relatedGraphic), relatedGraphic.once("animate-bind", a => {
|
|
30258
30483
|
text.setAttributes(from);
|
|
30259
30484
|
const listener = this._afterRelatedGraphicAttributeUpdate(text, texts, index, relatedGraphic, {
|
|
30260
30485
|
mode: mode,
|
|
@@ -30267,8 +30492,8 @@
|
|
|
30267
30492
|
});
|
|
30268
30493
|
}
|
|
30269
30494
|
} else if ("update" === state) {
|
|
30270
|
-
const prevLabel = prevTextMap.get(
|
|
30271
|
-
prevTextMap.delete(
|
|
30495
|
+
const prevLabel = prevTextMap.get(textKey);
|
|
30496
|
+
prevTextMap.delete(textKey), currentTextMap.set(textKey, prevLabel);
|
|
30272
30497
|
const prevText = prevLabel.text;
|
|
30273
30498
|
prevText.animate().to(text.attribute, duration, easing), prevLabel.labelLine && prevLabel.labelLine.animate().to(merge$1({}, prevLabel.labelLine.attribute, {
|
|
30274
30499
|
visible: null === (_f = null !== (_d = (null === (_b = null === (_a = text.attribute) || void 0 === _a ? void 0 : _a.line) || void 0 === _b ? void 0 : _b.visible) && (null === (_c = text.attribute) || void 0 === _c ? void 0 : _c.visible)) && void 0 !== _d ? _d : null === (_e = text.attribute) || void 0 === _e ? void 0 : _e.visible) || void 0 === _f || _f,
|
|
@@ -30292,16 +30517,17 @@
|
|
|
30292
30517
|
labels.forEach(text => {
|
|
30293
30518
|
var _a;
|
|
30294
30519
|
const labelLine = this._labelLine(text),
|
|
30295
|
-
relatedGraphic = this.
|
|
30296
|
-
state = (null == prevTextMap ? void 0 : prevTextMap.get(relatedGraphic)) ? "update" : "enter"
|
|
30297
|
-
|
|
30520
|
+
relatedGraphic = this.getRelatedGrphic(text.attribute),
|
|
30521
|
+
state = (null == prevTextMap ? void 0 : prevTextMap.get(relatedGraphic)) ? "update" : "enter",
|
|
30522
|
+
textKey = this._isCollectionBase ? text.attribute.id : relatedGraphic;
|
|
30523
|
+
if ("enter" === state) currentTextMap.set(textKey, labelLine ? {
|
|
30298
30524
|
text: text,
|
|
30299
30525
|
labelLine: labelLine
|
|
30300
30526
|
} : {
|
|
30301
30527
|
text: text
|
|
30302
30528
|
}), this.add(text), labelLine && this.add(labelLine), this._syncStateWithRelatedGraphic(relatedGraphic);else if ("update" === state) {
|
|
30303
|
-
const prevLabel = prevTextMap.get(
|
|
30304
|
-
prevTextMap.delete(
|
|
30529
|
+
const prevLabel = prevTextMap.get(textKey);
|
|
30530
|
+
prevTextMap.delete(textKey), currentTextMap.set(textKey, prevLabel), prevLabel.text.setAttributes(text.attribute), (null == prevLabel ? void 0 : prevLabel.labelLine) && prevLabel.labelLine.setAttributes({
|
|
30305
30531
|
points: null === (_a = text.attribute) || void 0 === _a ? void 0 : _a.points
|
|
30306
30532
|
});
|
|
30307
30533
|
}
|
|
@@ -30321,7 +30547,7 @@
|
|
|
30321
30547
|
delay: delay
|
|
30322
30548
|
} = _ref;
|
|
30323
30549
|
const listener = event => {
|
|
30324
|
-
var _a;
|
|
30550
|
+
var _a, _b;
|
|
30325
30551
|
const {
|
|
30326
30552
|
detail: detail
|
|
30327
30553
|
} = event;
|
|
@@ -30345,7 +30571,12 @@
|
|
|
30345
30571
|
});
|
|
30346
30572
|
break;
|
|
30347
30573
|
default:
|
|
30348
|
-
|
|
30574
|
+
if (this._isCollectionBase) {
|
|
30575
|
+
const point = this._idToPoint.get(text.attribute.id);
|
|
30576
|
+
!point || text.animates && text.animates.has("label-animate") || !this._baseMarks[0].containsPoint(point.x, point.y, IContainPointMode.LOCAL, null === (_b = this.stage) || void 0 === _b ? void 0 : _b.pickerService) || text.animate({
|
|
30577
|
+
onEnd: onEnd
|
|
30578
|
+
}).wait(delay).to(to, duration, easing);
|
|
30579
|
+
} else detail.animationState.isFirstFrameOfStep && text.animate({
|
|
30349
30580
|
onEnd: onEnd
|
|
30350
30581
|
}).wait(delay).to(to, duration, easing);
|
|
30351
30582
|
}
|
|
@@ -30368,7 +30599,7 @@
|
|
|
30368
30599
|
if ("null" !== fillStrategy || "null" !== strokeStrategy) for (let i = 0; i < labels.length; i++) {
|
|
30369
30600
|
const label = labels[i];
|
|
30370
30601
|
if (!label) continue;
|
|
30371
|
-
const baseMark = this.
|
|
30602
|
+
const baseMark = this.getRelatedGrphic(label.attribute),
|
|
30372
30603
|
backgroundColor = baseMark.attribute.fill,
|
|
30373
30604
|
foregroundColor = label.attribute.fill,
|
|
30374
30605
|
baseColor = backgroundColor,
|
|
@@ -30444,54 +30675,7 @@
|
|
|
30444
30675
|
labeling(textBounds, graphicBounds) {
|
|
30445
30676
|
let position = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "top";
|
|
30446
30677
|
let offset = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 0;
|
|
30447
|
-
|
|
30448
|
-
const {
|
|
30449
|
-
x1: x1,
|
|
30450
|
-
y1: y1,
|
|
30451
|
-
x2: x2,
|
|
30452
|
-
y2: y2
|
|
30453
|
-
} = textBounds,
|
|
30454
|
-
width = Math.abs(x2 - x1),
|
|
30455
|
-
height = Math.abs(y2 - y1),
|
|
30456
|
-
anchorX = (graphicBounds.x1 + graphicBounds.x2) / 2,
|
|
30457
|
-
anchorY = (graphicBounds.y1 + graphicBounds.y2) / 2;
|
|
30458
|
-
let sx = 0,
|
|
30459
|
-
sy = 0,
|
|
30460
|
-
offsetX = 0,
|
|
30461
|
-
offsetY = 0;
|
|
30462
|
-
graphicBounds && (offsetX = Math.abs(graphicBounds.x1 - graphicBounds.x2) / 2, offsetY = Math.abs(graphicBounds.y1 - graphicBounds.y2) / 2);
|
|
30463
|
-
const angle = {
|
|
30464
|
-
"top-right": -235,
|
|
30465
|
-
"top-left": 235,
|
|
30466
|
-
"bottom-right": 45,
|
|
30467
|
-
"bottom-left": -45
|
|
30468
|
-
};
|
|
30469
|
-
switch (position) {
|
|
30470
|
-
case "top":
|
|
30471
|
-
sy = -1;
|
|
30472
|
-
break;
|
|
30473
|
-
case "bottom":
|
|
30474
|
-
sy = 1;
|
|
30475
|
-
break;
|
|
30476
|
-
case "left":
|
|
30477
|
-
sx = -1;
|
|
30478
|
-
break;
|
|
30479
|
-
case "right":
|
|
30480
|
-
sx = 1;
|
|
30481
|
-
break;
|
|
30482
|
-
case "bottom-left":
|
|
30483
|
-
case "bottom-right":
|
|
30484
|
-
case "top-left":
|
|
30485
|
-
case "top-right":
|
|
30486
|
-
sx = Math.sin(angle[position] * (Math.PI / 180)), sy = Math.cos(angle[position] * (Math.PI / 180));
|
|
30487
|
-
break;
|
|
30488
|
-
case "center":
|
|
30489
|
-
sx = 0, sy = 0;
|
|
30490
|
-
}
|
|
30491
|
-
return {
|
|
30492
|
-
x: anchorX + sx * (offset + offsetX) + Math.sign(sx) * (width / 2),
|
|
30493
|
-
y: anchorY + sy * (offset + offsetY) + Math.sign(sy) * (height / 2)
|
|
30494
|
-
};
|
|
30678
|
+
return labelingPoint(textBounds, graphicBounds, position, offset);
|
|
30495
30679
|
}
|
|
30496
30680
|
}
|
|
30497
30681
|
SymbolLabel.defaultAttributes = {
|
|
@@ -30570,110 +30754,6 @@
|
|
|
30570
30754
|
pickable: !1
|
|
30571
30755
|
};
|
|
30572
30756
|
|
|
30573
|
-
function polarToCartesian(point) {
|
|
30574
|
-
return point.radius ? {
|
|
30575
|
-
x: Math.cos(point.angle) * point.radius,
|
|
30576
|
-
y: Math.sin(point.angle) * point.radius
|
|
30577
|
-
} : {
|
|
30578
|
-
x: 0,
|
|
30579
|
-
y: 0
|
|
30580
|
-
};
|
|
30581
|
-
}
|
|
30582
|
-
function circlePoint(x0, y0, radius, radian) {
|
|
30583
|
-
const offset = polarToCartesian({
|
|
30584
|
-
radius: radius,
|
|
30585
|
-
angle: radian
|
|
30586
|
-
});
|
|
30587
|
-
return {
|
|
30588
|
-
x: x0 + offset.x,
|
|
30589
|
-
y: y0 + offset.y
|
|
30590
|
-
};
|
|
30591
|
-
}
|
|
30592
|
-
function computeQuadrant(angle) {
|
|
30593
|
-
return (angle = normalizeAngle(angle)) > 0 && angle <= Math.PI / 2 ? 2 : angle > Math.PI / 2 && angle <= Math.PI ? 3 : angle > Math.PI && angle <= 3 * Math.PI / 2 ? 4 : 1;
|
|
30594
|
-
}
|
|
30595
|
-
function normalizeAngle(angle) {
|
|
30596
|
-
for (; angle < 0;) angle += 2 * Math.PI;
|
|
30597
|
-
for (; angle >= 2 * Math.PI;) angle -= 2 * Math.PI;
|
|
30598
|
-
return angle;
|
|
30599
|
-
}
|
|
30600
|
-
function isQuadrantLeft(quadrant) {
|
|
30601
|
-
return 3 === quadrant || 4 === quadrant;
|
|
30602
|
-
}
|
|
30603
|
-
function isQuadrantRight(quadrant) {
|
|
30604
|
-
return 1 === quadrant || 2 === quadrant;
|
|
30605
|
-
}
|
|
30606
|
-
function lineCirclePoints(a, b, c, x0, y0, r) {
|
|
30607
|
-
if (0 === a && 0 === b || r <= 0) return [];
|
|
30608
|
-
if (0 === a) {
|
|
30609
|
-
const y1 = -c / b,
|
|
30610
|
-
fd = r ** 2 - (y1 - y0) ** 2;
|
|
30611
|
-
if (fd < 0) return [];
|
|
30612
|
-
if (0 === fd) return [{
|
|
30613
|
-
x: x0,
|
|
30614
|
-
y: y1
|
|
30615
|
-
}];
|
|
30616
|
-
return [{
|
|
30617
|
-
x: Math.sqrt(fd) + x0,
|
|
30618
|
-
y: y1
|
|
30619
|
-
}, {
|
|
30620
|
-
x: -Math.sqrt(fd) + x0,
|
|
30621
|
-
y: y1
|
|
30622
|
-
}];
|
|
30623
|
-
}
|
|
30624
|
-
if (0 === b) {
|
|
30625
|
-
const x1 = -c / a,
|
|
30626
|
-
fd = r ** 2 - (x1 - x0) ** 2;
|
|
30627
|
-
if (fd < 0) return [];
|
|
30628
|
-
if (0 === fd) return [{
|
|
30629
|
-
x: x1,
|
|
30630
|
-
y: y0
|
|
30631
|
-
}];
|
|
30632
|
-
return [{
|
|
30633
|
-
x: x1,
|
|
30634
|
-
y: Math.sqrt(fd) + y0
|
|
30635
|
-
}, {
|
|
30636
|
-
x: x1,
|
|
30637
|
-
y: -Math.sqrt(fd) + y0
|
|
30638
|
-
}];
|
|
30639
|
-
}
|
|
30640
|
-
const fa = (b / a) ** 2 + 1,
|
|
30641
|
-
fb = 2 * ((c / a + x0) * (b / a) - y0),
|
|
30642
|
-
fd = fb ** 2 - 4 * fa * ((c / a + x0) ** 2 + y0 ** 2 - r ** 2);
|
|
30643
|
-
if (fd < 0) return [];
|
|
30644
|
-
const y1 = (-fb + Math.sqrt(fd)) / (2 * fa),
|
|
30645
|
-
y2 = (-fb - Math.sqrt(fd)) / (2 * fa),
|
|
30646
|
-
x1 = -(b * y1 + c) / a;
|
|
30647
|
-
return 0 === fd ? [{
|
|
30648
|
-
x: x1,
|
|
30649
|
-
y: y1
|
|
30650
|
-
}] : [{
|
|
30651
|
-
x: x1,
|
|
30652
|
-
y: y1
|
|
30653
|
-
}, {
|
|
30654
|
-
x: -(b * y2 + c) / a,
|
|
30655
|
-
y: y2
|
|
30656
|
-
}];
|
|
30657
|
-
}
|
|
30658
|
-
function connectLineRadian(radius, length) {
|
|
30659
|
-
return length > 2 * radius ? NaN : 2 * Math.asin(length / 2 / radius);
|
|
30660
|
-
}
|
|
30661
|
-
function checkBoundsOverlap(boundsA, boundsB) {
|
|
30662
|
-
const {
|
|
30663
|
-
x1: ax1,
|
|
30664
|
-
y1: ay1,
|
|
30665
|
-
x2: ax2,
|
|
30666
|
-
y2: ay2
|
|
30667
|
-
} = boundsA,
|
|
30668
|
-
{
|
|
30669
|
-
x1: bx1,
|
|
30670
|
-
y1: by1,
|
|
30671
|
-
x2: bx2,
|
|
30672
|
-
y2: by2
|
|
30673
|
-
} = boundsB;
|
|
30674
|
-
return !(ax1 <= bx1 && ax2 <= bx1 || ax1 >= bx2 && ax2 >= bx2 || ay1 <= by1 && ay2 <= by1 || ay1 >= by2 && ay2 >= by2);
|
|
30675
|
-
}
|
|
30676
|
-
|
|
30677
30757
|
class ArcInfo {
|
|
30678
30758
|
constructor(refDatum, center, outerCenter, quadrant, radian, middleAngle, innerRadius, outerRadius, circleCenter) {
|
|
30679
30759
|
this.refDatum = refDatum, this.center = center, this.outerCenter = outerCenter, this.quadrant = quadrant, this.radian = radian, this.middleAngle = middleAngle, this.innerRadius = innerRadius, this.outerRadius = outerRadius, this.circleCenter = circleCenter, this.labelVisible = !0, this.labelLimit = 0;
|
|
@@ -31205,10 +31285,34 @@
|
|
|
31205
31285
|
pickable: !1
|
|
31206
31286
|
};
|
|
31207
31287
|
|
|
31288
|
+
class LineDataLabel extends LabelBase {
|
|
31289
|
+
constructor(attributes) {
|
|
31290
|
+
super(merge$1({}, LineDataLabel.defaultAttributes, attributes)), this.name = "line-data-label";
|
|
31291
|
+
}
|
|
31292
|
+
labeling(textBounds, graphicBounds) {
|
|
31293
|
+
let position = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "top";
|
|
31294
|
+
let offset = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 0;
|
|
31295
|
+
return labelingPoint(textBounds, graphicBounds, position, offset);
|
|
31296
|
+
}
|
|
31297
|
+
}
|
|
31298
|
+
LineDataLabel.defaultAttributes = {
|
|
31299
|
+
textStyle: {
|
|
31300
|
+
fontSize: 12,
|
|
31301
|
+
fill: "#000",
|
|
31302
|
+
textAlign: "center",
|
|
31303
|
+
textBaseline: "middle",
|
|
31304
|
+
boundsPadding: [-1, 0, -1, 0]
|
|
31305
|
+
},
|
|
31306
|
+
position: "top",
|
|
31307
|
+
offset: 5,
|
|
31308
|
+
pickable: !1
|
|
31309
|
+
};
|
|
31310
|
+
|
|
31208
31311
|
const labelComponentMap = {
|
|
31209
31312
|
rect: RectLabel,
|
|
31210
31313
|
symbol: SymbolLabel,
|
|
31211
|
-
arc: ArcLabel
|
|
31314
|
+
arc: ArcLabel,
|
|
31315
|
+
"line-data": LineDataLabel
|
|
31212
31316
|
};
|
|
31213
31317
|
class DataLabel extends AbstractComponent {
|
|
31214
31318
|
constructor(attributes) {
|
|
@@ -31831,7 +31935,7 @@
|
|
|
31831
31935
|
function intersect(a, b, sep) {
|
|
31832
31936
|
return sep > Math.max(b.x1 - a.x2, a.x1 - b.x2, b.y1 - a.y2, a.y1 - b.y2);
|
|
31833
31937
|
}
|
|
31834
|
-
function hasOverlap(items, pad) {
|
|
31938
|
+
function hasOverlap$1(items, pad) {
|
|
31835
31939
|
for (let b, i = 1, n = items.length, a = items[0].AABBBounds; i < n; a = b, ++i) if (intersect(a, b = items[i].AABBBounds, pad)) return !0;
|
|
31836
31940
|
}
|
|
31837
31941
|
function hasBounds(item) {
|
|
@@ -31852,10 +31956,10 @@
|
|
|
31852
31956
|
separation: sep = 0
|
|
31853
31957
|
} = config,
|
|
31854
31958
|
reduce = isFunction$1(method) ? method : methods$1[method] || methods$1.parity;
|
|
31855
|
-
if (items.length >= 3 && hasOverlap(items, sep)) {
|
|
31959
|
+
if (items.length >= 3 && hasOverlap$1(items, sep)) {
|
|
31856
31960
|
do {
|
|
31857
31961
|
items = reduce(items, sep);
|
|
31858
|
-
} while (items.length >= 3 && hasOverlap(items, sep));
|
|
31962
|
+
} while (items.length >= 3 && hasOverlap$1(items, sep));
|
|
31859
31963
|
items.length < 3 && !last(source).attribute.opacity && (items.length > 1 && last(items).setAttribute("opacity", 0), last(source).setAttribute("opacity", 1));
|
|
31860
31964
|
}
|
|
31861
31965
|
source.forEach(item => {
|
|
@@ -33051,6 +33155,12 @@
|
|
|
33051
33155
|
orient: "bottom",
|
|
33052
33156
|
showDetail: "auto",
|
|
33053
33157
|
brushSelect: !0,
|
|
33158
|
+
zoomLock: !1,
|
|
33159
|
+
minSpan: 0,
|
|
33160
|
+
maxSpan: 1,
|
|
33161
|
+
delayType: "throttle",
|
|
33162
|
+
delayTime: 0,
|
|
33163
|
+
realTime: !0,
|
|
33054
33164
|
backgroundStyle: {
|
|
33055
33165
|
fill: "white",
|
|
33056
33166
|
stroke: "#D1DBEE",
|
|
@@ -33148,6 +33258,10 @@
|
|
|
33148
33258
|
}
|
|
33149
33259
|
return t;
|
|
33150
33260
|
};
|
|
33261
|
+
const delayMap$2 = {
|
|
33262
|
+
debounce: debounce,
|
|
33263
|
+
throttle: throttle
|
|
33264
|
+
};
|
|
33151
33265
|
let DataZoom$1 = class DataZoom extends AbstractComponent {
|
|
33152
33266
|
constructor(attributes) {
|
|
33153
33267
|
super(merge$1({}, DataZoom.defaultAttributes, attributes)), this.name = "dataZoom", this._previewData = [], this._activeState = !1, this._activeCache = {
|
|
@@ -33171,9 +33285,10 @@
|
|
|
33171
33285
|
}, this._onHandlerPointerMove = e => {
|
|
33172
33286
|
e.stopPropagation();
|
|
33173
33287
|
const {
|
|
33174
|
-
start:
|
|
33175
|
-
end:
|
|
33176
|
-
brushSelect: brushSelect
|
|
33288
|
+
start: startAttr,
|
|
33289
|
+
end: endAttr,
|
|
33290
|
+
brushSelect: brushSelect,
|
|
33291
|
+
realTime = !0
|
|
33177
33292
|
} = this.attribute,
|
|
33178
33293
|
pos = this.eventPosToStagePos(e),
|
|
33179
33294
|
{
|
|
@@ -33181,10 +33296,11 @@
|
|
|
33181
33296
|
max: max
|
|
33182
33297
|
} = this._layoutCache,
|
|
33183
33298
|
dis = (pos[attPos] - this._activeCache.lastPos[attPos]) / max;
|
|
33184
|
-
|
|
33185
|
-
start:
|
|
33186
|
-
end:
|
|
33187
|
-
}
|
|
33299
|
+
let {
|
|
33300
|
+
start: start,
|
|
33301
|
+
end: end
|
|
33302
|
+
} = this.state;
|
|
33303
|
+
this._activeState && (this._activeTag === DataZoomActiveTag.middleHandler ? this.moveZoomWithMiddle((this.state.start + this.state.end) / 2 + dis) : this._activeTag === DataZoomActiveTag.startHandler ? start + dis > end ? (start = end, end = start + dis, this._activeTag = DataZoomActiveTag.endHandler) : start += dis : this._activeTag === DataZoomActiveTag.endHandler && (end + dis < start ? (end = start, start = end + dis, this._activeTag = DataZoomActiveTag.startHandler) : end += dis), this._activeCache.lastPos = pos, brushSelect && this.renderDragMask()), start = Math.min(Math.max(start, 0), 1), end = Math.min(Math.max(end, 0), 1), startAttr === start && endAttr === end || (this.setStateAttr(start, end, !0), realTime && this._updateStateCallback && this._updateStateCallback(start, end), this._dispatchChangeEvent(start, end));
|
|
33188
33304
|
};
|
|
33189
33305
|
const {
|
|
33190
33306
|
start: start,
|
|
@@ -33194,29 +33310,31 @@
|
|
|
33194
33310
|
showDetail: showDetail,
|
|
33195
33311
|
position: position,
|
|
33196
33312
|
previewData: previewData,
|
|
33197
|
-
|
|
33198
|
-
|
|
33199
|
-
|
|
33200
|
-
|
|
33313
|
+
previewPointsX: previewPointsX,
|
|
33314
|
+
previewPointsY: previewPointsY,
|
|
33315
|
+
previewPointsX1: previewPointsX1,
|
|
33316
|
+
previewPointsY1: previewPointsY1,
|
|
33201
33317
|
updateStateCallback: updateStateCallback
|
|
33202
33318
|
} = this.attribute,
|
|
33203
33319
|
{
|
|
33204
33320
|
width: width,
|
|
33205
33321
|
height: height
|
|
33206
33322
|
} = size;
|
|
33207
|
-
start && (this.state.start = start), end && (this.state.end = end), this._isHorizontal = "top" === orient || "bottom" === orient, this._layoutCache.max = this._isHorizontal ? width : height, this._layoutCache.attPos = this._isHorizontal ? "x" : "y", this._layoutCache.attSize = this._isHorizontal ? "width" : "height", this._activeCache.startPos = position, this._activeCache.lastPos = position, this._showText = "auto" !== showDetail && showDetail, previewData && (this._previewData = previewData), isFunction$1(
|
|
33323
|
+
start && (this.state.start = start), end && (this.state.end = end), this._spanCache = this.state.end - this.state.start, this._isHorizontal = "top" === orient || "bottom" === orient, this._layoutCache.max = this._isHorizontal ? width : height, this._layoutCache.attPos = this._isHorizontal ? "x" : "y", this._layoutCache.attSize = this._isHorizontal ? "width" : "height", this._activeCache.startPos = position, this._activeCache.lastPos = position, this._showText = "auto" !== showDetail && showDetail, previewData && (this._previewData = previewData), isFunction$1(previewPointsX) && (this._previewPointsX = previewPointsX), isFunction$1(previewPointsY) && (this._previewPointsY = previewPointsY), isFunction$1(previewPointsX1) && (this._previewPointsX1 = previewPointsX1), isFunction$1(previewPointsY1) && (this._previewPointsY1 = previewPointsY1), isFunction$1(updateStateCallback) && (this._updateStateCallback = updateStateCallback);
|
|
33208
33324
|
}
|
|
33209
33325
|
bindEvents() {
|
|
33210
33326
|
if (this.attribute.disableTriggerEvent) return;
|
|
33211
33327
|
const {
|
|
33212
33328
|
showDetail: showDetail,
|
|
33213
|
-
brushSelect: brushSelect
|
|
33329
|
+
brushSelect: brushSelect,
|
|
33330
|
+
delayType = "throttle",
|
|
33331
|
+
delayTime = 0
|
|
33214
33332
|
} = this.attribute;
|
|
33215
33333
|
this._startHandler && this._startHandler.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "start")), this._endHandler && this._endHandler.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "end")), this._middleHandlerSymbol && this._middleHandlerSymbol.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "middleSymbol")), this._middleHandlerRect && this._middleHandlerRect.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "middleRect"));
|
|
33216
33334
|
const selectedTag = brushSelect ? "background" : "middleRect";
|
|
33217
|
-
this._selectedBackground && this._selectedBackground.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, selectedTag)), brushSelect && this._background && this._background.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "background")), brushSelect && this._previewGroup && this._previewGroup.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "background")), this._selectedPreviewGroup && this._selectedPreviewGroup.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, selectedTag)), "browser" === vglobal.env && (vglobal.addEventListener("pointermove", this._onHandlerPointerMove.bind(this), {
|
|
33335
|
+
this._selectedBackground && this._selectedBackground.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, selectedTag)), brushSelect && this._background && this._background.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "background")), brushSelect && this._previewGroup && this._previewGroup.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, "background")), this._selectedPreviewGroup && this._selectedPreviewGroup.addEventListener("pointerdown", e => this._onHandlerPointerDown(e, selectedTag)), "browser" === vglobal.env && (vglobal.addEventListener("pointermove", delayMap$2[delayType](this._onHandlerPointerMove.bind(this), delayTime), {
|
|
33218
33336
|
capture: !0
|
|
33219
|
-
}), vglobal.addEventListener("pointerup", this._onHandlerPointerUp.bind(this))), this.addEventListener("pointermove", this._onHandlerPointerMove, {
|
|
33337
|
+
}), vglobal.addEventListener("pointerup", this._onHandlerPointerUp.bind(this))), this.addEventListener("pointermove", delayMap$2[delayType](this._onHandlerPointerMove, delayTime), {
|
|
33220
33338
|
capture: !0
|
|
33221
33339
|
}), this.addEventListener("pointerup", this._onHandlerPointerUp), this.addEventListener("pointerupoutside", this._onHandlerPointerUp), "auto" === showDetail && (this.addEventListener("pointerenter", this._onHandlerPointerEnter), this.addEventListener("pointerleave", this._onHandlerPointerLeave));
|
|
33222
33340
|
}
|
|
@@ -33230,6 +33348,18 @@
|
|
|
33230
33348
|
} = this._layoutCache;
|
|
33231
33349
|
return this._activeCache.lastPos[attPos] - position[attPos] > max ? max + position[attPos] - this._activeCache.startPos[attPos] : this._activeCache.lastPos[attPos] - position[attPos] < 0 ? position[attPos] - this._activeCache.startPos[attPos] : this._activeCache.lastPos[attPos] - this._activeCache.startPos[attPos];
|
|
33232
33350
|
}
|
|
33351
|
+
setStateAttr(start, end, shouldRender) {
|
|
33352
|
+
const {
|
|
33353
|
+
zoomLock = !1,
|
|
33354
|
+
minSpan = 0,
|
|
33355
|
+
maxSpan = 1
|
|
33356
|
+
} = this.attribute,
|
|
33357
|
+
span = end - start;
|
|
33358
|
+
span !== this._spanCache && (zoomLock || span < minSpan || span > maxSpan) || (this._spanCache = span, this.state.start = start, this.state.end = end, shouldRender && this.setAttributes({
|
|
33359
|
+
start: start,
|
|
33360
|
+
end: end
|
|
33361
|
+
}));
|
|
33362
|
+
}
|
|
33233
33363
|
eventPosToStagePos(e) {
|
|
33234
33364
|
var _a, _b, _c;
|
|
33235
33365
|
const stagePosition = null === (_a = this.stage) || void 0 === _a ? void 0 : _a.window.getBoundingClientRect();
|
|
@@ -33243,16 +33373,14 @@
|
|
|
33243
33373
|
const {
|
|
33244
33374
|
start: start,
|
|
33245
33375
|
end: end,
|
|
33246
|
-
brushSelect: brushSelect
|
|
33376
|
+
brushSelect: brushSelect,
|
|
33377
|
+
realTime = !0
|
|
33247
33378
|
} = this.attribute;
|
|
33248
33379
|
if (this._activeState && this._activeTag === DataZoomActiveTag.background) {
|
|
33249
33380
|
const pos = this.eventPosToStagePos(e);
|
|
33250
33381
|
this.backgroundDragZoom(this._activeCache.startPos, pos);
|
|
33251
33382
|
}
|
|
33252
|
-
this._activeState = !1, brushSelect && this.renderDragMask(), start === this.state.start && end === this.state.end || (this.
|
|
33253
|
-
start: this.state.start,
|
|
33254
|
-
end: this.state.end
|
|
33255
|
-
}), this._updateStateCallback && this._updateStateCallback(this.state.start, this.state.end), this._dispatchChangeEvent(this.state.start, this.state.end));
|
|
33383
|
+
this._activeState = !1, brushSelect && this.renderDragMask(), realTime && start === this.state.start && end === this.state.end || (this.setStateAttr(this.state.start, this.state.end, !0), this._updateStateCallback && this._updateStateCallback(this.state.start, this.state.end), this._dispatchChangeEvent(this.state.start, this.state.end));
|
|
33256
33384
|
}
|
|
33257
33385
|
_onHandlerPointerEnter(e) {
|
|
33258
33386
|
e.stopPropagation(), this._showText = !0, this.renderText();
|
|
@@ -33272,11 +33400,11 @@
|
|
|
33272
33400
|
endPosInComponent = endPos[attPos] - position[attPos],
|
|
33273
33401
|
start = Math.min(Math.max(Math.min(startPosInComponent, endPosInComponent) / max, 0), 1),
|
|
33274
33402
|
end = Math.min(Math.max(Math.max(startPosInComponent, endPosInComponent) / max, 0), 1);
|
|
33275
|
-
Math.abs(start - end) < .01 ? this.moveZoomWithMiddle(start) :
|
|
33403
|
+
Math.abs(start - end) < .01 ? this.moveZoomWithMiddle(start) : this.setStateAttr(start, end, !1);
|
|
33276
33404
|
}
|
|
33277
33405
|
moveZoomWithMiddle(middle) {
|
|
33278
33406
|
let offset = middle - (this.state.start + this.state.end) / 2;
|
|
33279
|
-
0 !== offset && (offset > 0 ? this.state.end + offset > 1 && (offset = 1 - this.state.end) : offset < 0 && this.state.start + offset < 0 && (offset = -this.state.start), this.
|
|
33407
|
+
0 !== offset && (offset > 0 ? this.state.end + offset > 1 && (offset = 1 - this.state.end) : offset < 0 && this.state.start + offset < 0 && (offset = -this.state.start), this.setStateAttr(this.state.start + offset, this.state.end + offset, !1));
|
|
33280
33408
|
}
|
|
33281
33409
|
renderDragMask() {
|
|
33282
33410
|
const {
|
|
@@ -33547,8 +33675,8 @@
|
|
|
33547
33675
|
}
|
|
33548
33676
|
getPreviewLinePoints() {
|
|
33549
33677
|
const previewPoints = this._previewData.map(d => ({
|
|
33550
|
-
x: this.
|
|
33551
|
-
y: this.
|
|
33678
|
+
x: this._previewPointsX && this._previewPointsX(d),
|
|
33679
|
+
y: this._previewPointsY && this._previewPointsY(d)
|
|
33552
33680
|
}));
|
|
33553
33681
|
if (0 === previewPoints.length) return previewPoints;
|
|
33554
33682
|
const {
|
|
@@ -33559,10 +33687,10 @@
|
|
|
33559
33687
|
}
|
|
33560
33688
|
getPreviewAreaPoints() {
|
|
33561
33689
|
const previewPoints = this._previewData.map(d => ({
|
|
33562
|
-
x: this.
|
|
33563
|
-
y: this.
|
|
33564
|
-
x1: this.
|
|
33565
|
-
y1: this.
|
|
33690
|
+
x: this._previewPointsX && this._previewPointsX(d),
|
|
33691
|
+
y: this._previewPointsY && this._previewPointsY(d),
|
|
33692
|
+
x1: this._previewPointsX1 && this._previewPointsX1(d),
|
|
33693
|
+
y1: this._previewPointsY1 && this._previewPointsY1(d)
|
|
33566
33694
|
}));
|
|
33567
33695
|
if (0 === previewPoints.length) return previewPoints;
|
|
33568
33696
|
const {
|
|
@@ -33648,10 +33776,7 @@
|
|
|
33648
33776
|
start: startAttr,
|
|
33649
33777
|
end: endAttr
|
|
33650
33778
|
} = this.attribute;
|
|
33651
|
-
isValid$1(start) && isValid$1(end) && (start !== this.state.start || end !== this.state.end) && (this.state.start = start, this.state.end = end, startAttr === this.state.start && endAttr === this.state.end || (this.
|
|
33652
|
-
start: start,
|
|
33653
|
-
end: end
|
|
33654
|
-
}), this._updateStateCallback && this._updateStateCallback(start, end), this._dispatchChangeEvent(start, end)));
|
|
33779
|
+
isValid$1(start) && isValid$1(end) && (start !== this.state.start || end !== this.state.end) && (this.state.start = start, this.state.end = end, startAttr === this.state.start && endAttr === this.state.end || (this.setStateAttr(start, end, !0), this._updateStateCallback && this._updateStateCallback(start, end), this._dispatchChangeEvent(start, end)));
|
|
33655
33780
|
}
|
|
33656
33781
|
setPreviewData(data) {
|
|
33657
33782
|
this._previewData = data;
|
|
@@ -33677,17 +33802,17 @@
|
|
|
33677
33802
|
setUpdateStateCallback(callback) {
|
|
33678
33803
|
isFunction$1(callback) && (this._updateStateCallback = callback);
|
|
33679
33804
|
}
|
|
33680
|
-
|
|
33681
|
-
isFunction$1(callback) && (this.
|
|
33805
|
+
setPreviewPointsX(callback) {
|
|
33806
|
+
isFunction$1(callback) && (this._previewPointsX = callback);
|
|
33682
33807
|
}
|
|
33683
|
-
|
|
33684
|
-
isFunction$1(callback) && (this.
|
|
33808
|
+
setPreviewPointsY(callback) {
|
|
33809
|
+
isFunction$1(callback) && (this._previewPointsY = callback);
|
|
33685
33810
|
}
|
|
33686
|
-
|
|
33687
|
-
isFunction$1(callback) && (this.
|
|
33811
|
+
setPreviewPointsX1(callback) {
|
|
33812
|
+
isFunction$1(callback) && (this._previewPointsX1 = callback);
|
|
33688
33813
|
}
|
|
33689
|
-
|
|
33690
|
-
isFunction$1(callback) && (this.
|
|
33814
|
+
setPreviewPointsY1(callback) {
|
|
33815
|
+
isFunction$1(callback) && (this._previewPointsY1 = callback);
|
|
33691
33816
|
}
|
|
33692
33817
|
setStatePointToData(callback) {
|
|
33693
33818
|
isFunction$1(callback) && (this._statePointToData = callback);
|
|
@@ -35084,9 +35209,9 @@
|
|
|
35084
35209
|
super(merge$1({}, Slider.defaultAttributes, attributes)), this.name = "slider", this._isHorizontal = !0, this._startHandler = null, this._endHandler = null, this._startHandlerText = null, this._endHandlerText = null, this._currentHandler = null, this._currentValue = {}, this._onHandlerPointerdown = e => {
|
|
35085
35210
|
e.stopPropagation(), this._currentHandler = e.target, this._prePos = this._isHorizontal ? e.clientX : e.clientY, "browser" === vglobal.env ? (vglobal.addEventListener("pointermove", this._onHandlerPointerMove, {
|
|
35086
35211
|
capture: !0
|
|
35087
|
-
}), vglobal.addEventListener("pointerup", this._onHandlerPointerUp)) : (this.
|
|
35212
|
+
}), vglobal.addEventListener("pointerup", this._onHandlerPointerUp)) : (this.stage.addEventListener("pointermove", this._onHandlerPointerMove, {
|
|
35088
35213
|
capture: !0
|
|
35089
|
-
}), this.
|
|
35214
|
+
}), this.stage.addEventListener("pointerup", this._onHandlerPointerUp), this.stage.addEventListener("pointerupoutside", this._onHandlerPointerUp));
|
|
35090
35215
|
}, this._onHandlerPointerMove = e => {
|
|
35091
35216
|
var _a, _b;
|
|
35092
35217
|
e.stopPropagation();
|
|
@@ -35106,20 +35231,17 @@
|
|
|
35106
35231
|
currentValue = newPos / railLen * (max - min) + min;
|
|
35107
35232
|
"text" === this._currentHandler.type ? this._updateHandlerText(this._currentHandler, newPos, currentValue) : this._updateHandler(this._currentHandler, newPos, currentValue), this._updateTrack(), this._prePos = currentPos, this._dispatchChangeEvent();
|
|
35108
35233
|
}, this._onHandlerPointerUp = e => {
|
|
35109
|
-
|
|
35234
|
+
e.preventDefault(), this._currentHandler = null, "browser" === vglobal.env ? (vglobal.removeEventListener("pointermove", this._onHandlerPointerMove, {
|
|
35110
35235
|
capture: !0
|
|
35111
|
-
}), vglobal.removeEventListener("pointerup", this._onHandlerPointerUp)
|
|
35112
|
-
|
|
35113
|
-
|
|
35114
|
-
capture: !0
|
|
35115
|
-
}), currentTarget.removeEventListener("pointerup", this._onHandlerPointerUp), currentTarget.removeEventListener("pointerupoutside", this._onHandlerPointerUp);
|
|
35116
|
-
}
|
|
35236
|
+
}), vglobal.removeEventListener("pointerup", this._onHandlerPointerUp)) : (this.stage.removeEventListener("pointermove", this._onHandlerPointerMove, {
|
|
35237
|
+
capture: !0
|
|
35238
|
+
}), this.stage.removeEventListener("pointerup", this._onHandlerPointerUp), this.stage.removeEventListener("pointerupoutside", this._onHandlerPointerUp));
|
|
35117
35239
|
}, this._onTrackPointerdown = e => {
|
|
35118
35240
|
e.stopPropagation(), this._prePos = this._isHorizontal ? e.clientX : e.clientY, "browser" === vglobal.env ? (vglobal.addEventListener("pointermove", this._onTrackPointerMove, {
|
|
35119
35241
|
capture: !0
|
|
35120
|
-
}), vglobal.addEventListener("pointerup", this._onTrackPointerUp)) : (this.
|
|
35242
|
+
}), vglobal.addEventListener("pointerup", this._onTrackPointerUp)) : (this.stage.addEventListener("pointermove", this._onTrackPointerMove, {
|
|
35121
35243
|
capture: !0
|
|
35122
|
-
}), this.
|
|
35244
|
+
}), this.stage.addEventListener("pointerup", this._onTrackPointerUp), this.stage.addEventListener("pointerupoutside", this._onTrackPointerUp));
|
|
35123
35245
|
}, this._onTrackPointerMove = e => {
|
|
35124
35246
|
e.stopPropagation();
|
|
35125
35247
|
const {
|
|
@@ -35158,9 +35280,9 @@
|
|
|
35158
35280
|
}, this._onTrackPointerUp = e => {
|
|
35159
35281
|
e.preventDefault(), "browser" === vglobal.env ? (vglobal.removeEventListener("pointermove", this._onTrackPointerMove, {
|
|
35160
35282
|
capture: !0
|
|
35161
|
-
}), vglobal.removeEventListener("pointerup", this._onTrackPointerUp)) : (this.
|
|
35283
|
+
}), vglobal.removeEventListener("pointerup", this._onTrackPointerUp)) : (this.stage.removeEventListener("pointermove", this._onTrackPointerMove, {
|
|
35162
35284
|
capture: !0
|
|
35163
|
-
}), this.
|
|
35285
|
+
}), this.stage.removeEventListener("pointerup", this._onTrackPointerUp), this.stage.removeEventListener("pointerupoutside", this._onTrackPointerUp));
|
|
35164
35286
|
}, this._onRailPointerDown = e => {
|
|
35165
35287
|
e.stopPropagation();
|
|
35166
35288
|
const {
|
|
@@ -36634,7 +36756,7 @@
|
|
|
36634
36756
|
};
|
|
36635
36757
|
const DEFAULT_SIZE_THRESHOLD = 5;
|
|
36636
36758
|
|
|
36637
|
-
const delayMap = {
|
|
36759
|
+
const delayMap$1 = {
|
|
36638
36760
|
debounce: debounce,
|
|
36639
36761
|
throttle: throttle
|
|
36640
36762
|
};
|
|
@@ -36675,7 +36797,7 @@
|
|
|
36675
36797
|
endTrigger = DEFAULT_BRUSH_ATTRIBUTES.endTrigger,
|
|
36676
36798
|
resetTrigger = DEFAULT_BRUSH_ATTRIBUTES.resetTrigger
|
|
36677
36799
|
} = this.attribute;
|
|
36678
|
-
this.stage.addEventListener(trigger, this._onBrushStart), this.stage.addEventListener(updateTrigger, delayMap[delayType](this._onBrushing, delayTime)), this.stage.addEventListener(endTrigger, this._onBrushEnd), this.stage.addEventListener(resetTrigger, this._onBrushEnd);
|
|
36800
|
+
this.stage.addEventListener(trigger, this._onBrushStart), this.stage.addEventListener(updateTrigger, delayMap$1[delayType](this._onBrushing, delayTime)), this.stage.addEventListener(endTrigger, this._onBrushEnd), this.stage.addEventListener(resetTrigger, this._onBrushEnd);
|
|
36679
36801
|
}
|
|
36680
36802
|
_isPosInBrushMask(e) {
|
|
36681
36803
|
const pos = this.eventPosToStagePos(e),
|
|
@@ -36870,7 +36992,7 @@
|
|
|
36870
36992
|
endTrigger = DEFAULT_BRUSH_ATTRIBUTES.endTrigger,
|
|
36871
36993
|
resetTrigger = DEFAULT_BRUSH_ATTRIBUTES.resetTrigger
|
|
36872
36994
|
} = this.attribute;
|
|
36873
|
-
this.stage.removeEventListener(trigger, this._onBrushStart), this.stage.removeEventListener(updateTrigger, delayMap[delayType](this._onBrushing, delayTime)), this.stage.removeEventListener(endTrigger, this._onBrushEnd), this.stage.removeEventListener(resetTrigger, this._onBrushEnd);
|
|
36995
|
+
this.stage.removeEventListener(trigger, this._onBrushStart), this.stage.removeEventListener(updateTrigger, delayMap$1[delayType](this._onBrushing, delayTime)), this.stage.removeEventListener(endTrigger, this._onBrushEnd), this.stage.removeEventListener(resetTrigger, this._onBrushEnd);
|
|
36874
36996
|
}
|
|
36875
36997
|
};
|
|
36876
36998
|
Brush$1.defaultAttributes = DEFAULT_BRUSH_ATTRIBUTES;
|
|
@@ -38657,7 +38779,8 @@
|
|
|
38657
38779
|
getBoundingClientRect: () => ({
|
|
38658
38780
|
height: domref.height,
|
|
38659
38781
|
width: domref.width
|
|
38660
|
-
})
|
|
38782
|
+
}),
|
|
38783
|
+
nativeCanvas: _canvas
|
|
38661
38784
|
};
|
|
38662
38785
|
canvasMap.set(id, canvas), i >= freeCanvasIdx && freeCanvasList.push(canvas);
|
|
38663
38786
|
});
|
|
@@ -41355,6 +41478,10 @@
|
|
|
41355
41478
|
init() {
|
|
41356
41479
|
this._context = new LynxContext2d(this, this._dpr);
|
|
41357
41480
|
}
|
|
41481
|
+
resize(width, height) {
|
|
41482
|
+
this._pixelWidth = width * this._dpr, this._pixelHeight = height * this._dpr, this._displayWidth = width, this._displayHeight = height, this._nativeCanvas.width = this._pixelWidth, this._nativeCanvas.height = this._pixelHeight, this._nativeCanvas.nativeCanvas && (this._nativeCanvas.nativeCanvas.width = this._pixelWidth, this._nativeCanvas.nativeCanvas.height = this._pixelHeight);
|
|
41483
|
+
this._context.dpr = this._dpr;
|
|
41484
|
+
}
|
|
41358
41485
|
release() {}
|
|
41359
41486
|
};
|
|
41360
41487
|
LynxCanvas.env = "lynx", LynxCanvas = __decorate$a([injectable(), __metadata$8("design:paramtypes", [Object])], LynxCanvas);
|
|
@@ -41454,7 +41581,9 @@
|
|
|
41454
41581
|
});
|
|
41455
41582
|
}
|
|
41456
41583
|
releaseWindow() {}
|
|
41457
|
-
resizeWindow(width, height) {
|
|
41584
|
+
resizeWindow(width, height) {
|
|
41585
|
+
this.canvas.resize(width, height);
|
|
41586
|
+
}
|
|
41458
41587
|
setDpr(dpr) {
|
|
41459
41588
|
this.canvas.dpr = dpr;
|
|
41460
41589
|
}
|
|
@@ -47149,6 +47278,44 @@
|
|
|
47149
47278
|
})), Factory$1.registerAnimationType("barBoxplotScaleIn", barBoxplotScaleIn), Factory$1.registerAnimationType("barBoxplotScaleOut", barBoxplotScaleOut);
|
|
47150
47279
|
}
|
|
47151
47280
|
|
|
47281
|
+
const registerRippleGlyph = () => {
|
|
47282
|
+
Factory$1.registerGlyph("ripplePoint", {
|
|
47283
|
+
symbol: "symbol",
|
|
47284
|
+
ripple0: "symbol",
|
|
47285
|
+
ripple1: "symbol",
|
|
47286
|
+
ripple2: "symbol"
|
|
47287
|
+
}).registerFunctionEncoder((encodeValues, datum, element, config) => {
|
|
47288
|
+
var _a;
|
|
47289
|
+
const ripple = Math.max(0, Math.min(encodeValues.ripple, 1)),
|
|
47290
|
+
size = null !== (_a = encodeValues.size) && void 0 !== _a ? _a : element.getGraphicAttribute("size"),
|
|
47291
|
+
rippleSize = .5 * size;
|
|
47292
|
+
return {
|
|
47293
|
+
ripple0: {
|
|
47294
|
+
size: size + rippleSize * ripple,
|
|
47295
|
+
fillOpacity: .75 - .25 * ripple
|
|
47296
|
+
},
|
|
47297
|
+
ripple1: {
|
|
47298
|
+
size: size + rippleSize * (1 + ripple),
|
|
47299
|
+
fillOpacity: .5 - .25 * ripple
|
|
47300
|
+
},
|
|
47301
|
+
ripple2: {
|
|
47302
|
+
size: size + rippleSize * (2 + ripple),
|
|
47303
|
+
fillOpacity: .25 - .25 * ripple
|
|
47304
|
+
}
|
|
47305
|
+
};
|
|
47306
|
+
}).registerDefaultEncoder(() => ({
|
|
47307
|
+
ripple0: {
|
|
47308
|
+
fillOpacity: .75
|
|
47309
|
+
},
|
|
47310
|
+
ripple1: {
|
|
47311
|
+
fillOpacity: .5
|
|
47312
|
+
},
|
|
47313
|
+
ripple2: {
|
|
47314
|
+
fillOpacity: .25
|
|
47315
|
+
}
|
|
47316
|
+
}));
|
|
47317
|
+
};
|
|
47318
|
+
|
|
47152
47319
|
const getHorizontalPath = (options, ratio) => {
|
|
47153
47320
|
var _a;
|
|
47154
47321
|
const curvature = null !== (_a = options.curvature) && void 0 !== _a ? _a : .5,
|
|
@@ -48768,6 +48935,10 @@
|
|
|
48768
48935
|
|
|
48769
48936
|
const WaterfallDefaultSeriesField = `${PREFIX}_waterfall_default_seriesField`;
|
|
48770
48937
|
|
|
48938
|
+
const CORRELATION_X = `${PREFIX}_CORRELATION_X`;
|
|
48939
|
+
const CORRELATION_Y = `${PREFIX}_CORRELATION_Y`;
|
|
48940
|
+
const CORRELATION_SIZE = `${PREFIX}_CORRELATION_SIZE`;
|
|
48941
|
+
|
|
48771
48942
|
const DEFAULT_DATA_INDEX = `${PREFIX}_DEFAULT_DATA_INDEX`;
|
|
48772
48943
|
const DEFAULT_DATA_KEY = `${PREFIX}_DEFAULT_DATA_KEY`;
|
|
48773
48944
|
const DEFAULT_DATA_SERIES_FIELD = `${PREFIX}_DEFAULT_DATA_SERIES_FIELD`;
|
|
@@ -48931,7 +49102,7 @@
|
|
|
48931
49102
|
style: {
|
|
48932
49103
|
cursor: 'pointer',
|
|
48933
49104
|
fill: 'black',
|
|
48934
|
-
stroke: '
|
|
49105
|
+
stroke: { type: 'palette', key: 'backgroundColor' },
|
|
48935
49106
|
lineWidth: 2,
|
|
48936
49107
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
48937
49108
|
lineHeight: THEME_CONSTANTS.l5LineHeight
|
|
@@ -48968,7 +49139,8 @@
|
|
|
48968
49139
|
},
|
|
48969
49140
|
label: {
|
|
48970
49141
|
style: {
|
|
48971
|
-
|
|
49142
|
+
lineWidth: 2,
|
|
49143
|
+
stroke: { type: 'palette', key: 'backgroundColor' },
|
|
48972
49144
|
textAlign: 'center',
|
|
48973
49145
|
textBaseline: 'middle'
|
|
48974
49146
|
}
|
|
@@ -48983,6 +49155,24 @@
|
|
|
48983
49155
|
}
|
|
48984
49156
|
};
|
|
48985
49157
|
|
|
49158
|
+
const correlation$1 = {
|
|
49159
|
+
centerLabel: {
|
|
49160
|
+
visible: true,
|
|
49161
|
+
position: 'center',
|
|
49162
|
+
style: {
|
|
49163
|
+
fill: '#fff',
|
|
49164
|
+
text: ''
|
|
49165
|
+
}
|
|
49166
|
+
},
|
|
49167
|
+
label: {
|
|
49168
|
+
visible: true,
|
|
49169
|
+
position: 'bottom',
|
|
49170
|
+
style: {
|
|
49171
|
+
fill: '#000'
|
|
49172
|
+
}
|
|
49173
|
+
}
|
|
49174
|
+
};
|
|
49175
|
+
|
|
48986
49176
|
const series = {
|
|
48987
49177
|
scatter,
|
|
48988
49178
|
line,
|
|
@@ -49011,7 +49201,8 @@
|
|
|
49011
49201
|
heatmap,
|
|
49012
49202
|
sankey: sankey$1,
|
|
49013
49203
|
rose,
|
|
49014
|
-
boxPlot
|
|
49204
|
+
boxPlot,
|
|
49205
|
+
correlation: correlation$1
|
|
49015
49206
|
};
|
|
49016
49207
|
|
|
49017
49208
|
const markByType = {
|
|
@@ -49106,7 +49297,16 @@
|
|
|
49106
49297
|
title: {
|
|
49107
49298
|
space: 8
|
|
49108
49299
|
},
|
|
49109
|
-
maxHeight: '30%'
|
|
49300
|
+
maxHeight: '30%',
|
|
49301
|
+
unit: {
|
|
49302
|
+
visible: false,
|
|
49303
|
+
style: {
|
|
49304
|
+
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
49305
|
+
fill: { type: 'palette', key: 'axisFontColor' },
|
|
49306
|
+
fontWeight: 'normal',
|
|
49307
|
+
fillOpacity: 1
|
|
49308
|
+
}
|
|
49309
|
+
}
|
|
49110
49310
|
};
|
|
49111
49311
|
const axisY = {
|
|
49112
49312
|
label: {
|
|
@@ -49117,7 +49317,16 @@
|
|
|
49117
49317
|
space: 12,
|
|
49118
49318
|
autoRotate: true
|
|
49119
49319
|
},
|
|
49120
|
-
maxWidth: '30%'
|
|
49320
|
+
maxWidth: '30%',
|
|
49321
|
+
unit: {
|
|
49322
|
+
visible: false,
|
|
49323
|
+
style: {
|
|
49324
|
+
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
49325
|
+
fill: { type: 'palette', key: 'axisFontColor' },
|
|
49326
|
+
fontWeight: 'normal',
|
|
49327
|
+
fillOpacity: 1
|
|
49328
|
+
}
|
|
49329
|
+
}
|
|
49121
49330
|
};
|
|
49122
49331
|
|
|
49123
49332
|
const commonAxis = {
|
|
@@ -49422,7 +49631,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49422
49631
|
autoFit: false,
|
|
49423
49632
|
style: {
|
|
49424
49633
|
fontSize: THEME_CONSTANTS.l1FontSize,
|
|
49425
|
-
fill: { type: 'palette', key:
|
|
49634
|
+
fill: { type: 'palette', key: 'primaryFontColor' },
|
|
49426
49635
|
fontWeight: 'normal',
|
|
49427
49636
|
fillOpacity: 1,
|
|
49428
49637
|
textBaseline: 'top',
|
|
@@ -49453,7 +49662,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49453
49662
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
49454
49663
|
lineHeight: THEME_CONSTANTS.l5LineHeight,
|
|
49455
49664
|
fontWeight: 'normal',
|
|
49456
|
-
fill: { type: 'palette', key:
|
|
49665
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49457
49666
|
},
|
|
49458
49667
|
space: 12
|
|
49459
49668
|
},
|
|
@@ -49531,7 +49740,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49531
49740
|
textStyle: {
|
|
49532
49741
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
49533
49742
|
lineHeight: THEME_CONSTANTS.l5LineHeight,
|
|
49534
|
-
fill: { type: 'palette', key:
|
|
49743
|
+
fill: { type: 'palette', key: 'primaryFontColor' },
|
|
49535
49744
|
fontWeight: 'normal'
|
|
49536
49745
|
},
|
|
49537
49746
|
space: 12
|
|
@@ -49670,7 +49879,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49670
49879
|
const markArea = {
|
|
49671
49880
|
area: {
|
|
49672
49881
|
style: {
|
|
49673
|
-
fill: '
|
|
49882
|
+
fill: { type: 'palette', key: 'axisDomainColor', a: 0.25 }
|
|
49674
49883
|
}
|
|
49675
49884
|
},
|
|
49676
49885
|
label: {
|
|
@@ -49678,9 +49887,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49678
49887
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
49679
49888
|
fontWeight: 'normal',
|
|
49680
49889
|
fontStyle: 'normal',
|
|
49681
|
-
fill: { type: 'palette', key: '
|
|
49682
|
-
stroke: { type: 'palette', key: 'labelReverseFontColor' },
|
|
49683
|
-
lineWidth: 0
|
|
49890
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49684
49891
|
},
|
|
49685
49892
|
labelBackground: {
|
|
49686
49893
|
padding: {
|
|
@@ -49690,8 +49897,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49690
49897
|
left: 4
|
|
49691
49898
|
},
|
|
49692
49899
|
style: {
|
|
49693
|
-
cornerRadius:
|
|
49694
|
-
fill: '
|
|
49900
|
+
cornerRadius: 3,
|
|
49901
|
+
fill: { type: 'palette', key: 'markLabelBackgroundColor' }
|
|
49695
49902
|
}
|
|
49696
49903
|
}
|
|
49697
49904
|
}
|
|
@@ -49701,7 +49908,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49701
49908
|
line: {
|
|
49702
49909
|
style: {
|
|
49703
49910
|
lineDash: [3, 3],
|
|
49704
|
-
stroke: '
|
|
49911
|
+
stroke: { type: 'palette', key: 'primaryFontColor' }
|
|
49705
49912
|
}
|
|
49706
49913
|
},
|
|
49707
49914
|
startSymbol: {
|
|
@@ -49711,7 +49918,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49711
49918
|
style: {
|
|
49712
49919
|
stroke: null,
|
|
49713
49920
|
lineWidth: 0,
|
|
49714
|
-
fill: '
|
|
49921
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49715
49922
|
}
|
|
49716
49923
|
},
|
|
49717
49924
|
endSymbol: {
|
|
@@ -49721,7 +49928,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49721
49928
|
style: {
|
|
49722
49929
|
stroke: null,
|
|
49723
49930
|
lineWidth: 0,
|
|
49724
|
-
fill: '
|
|
49931
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49725
49932
|
}
|
|
49726
49933
|
},
|
|
49727
49934
|
label: {
|
|
@@ -49730,9 +49937,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49730
49937
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
49731
49938
|
fontWeight: 'normal',
|
|
49732
49939
|
fontStyle: 'normal',
|
|
49733
|
-
fill: { type: 'palette', key: '
|
|
49734
|
-
stroke: { type: 'palette', key: 'labelReverseFontColor' },
|
|
49735
|
-
lineWidth: 0
|
|
49940
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49736
49941
|
},
|
|
49737
49942
|
labelBackground: {
|
|
49738
49943
|
padding: {
|
|
@@ -49742,8 +49947,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49742
49947
|
left: 4
|
|
49743
49948
|
},
|
|
49744
49949
|
style: {
|
|
49745
|
-
cornerRadius:
|
|
49746
|
-
fill: '
|
|
49950
|
+
cornerRadius: 3,
|
|
49951
|
+
fill: { type: 'palette', key: 'markLabelBackgroundColor' }
|
|
49747
49952
|
}
|
|
49748
49953
|
}
|
|
49749
49954
|
}
|
|
@@ -49758,12 +49963,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49758
49963
|
size: 5,
|
|
49759
49964
|
visible: true,
|
|
49760
49965
|
style: {
|
|
49761
|
-
fill: '
|
|
49966
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49762
49967
|
}
|
|
49763
49968
|
},
|
|
49764
49969
|
line: {
|
|
49765
49970
|
style: {
|
|
49766
|
-
stroke: '
|
|
49971
|
+
stroke: { type: 'palette', key: 'primaryFontColor' }
|
|
49767
49972
|
}
|
|
49768
49973
|
}
|
|
49769
49974
|
},
|
|
@@ -49845,7 +50050,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49845
50050
|
textStyle: {
|
|
49846
50051
|
fontSize: THEME_CONSTANTS.l3FontSize,
|
|
49847
50052
|
lineHeight: THEME_CONSTANTS.l3LineHeight,
|
|
49848
|
-
fill: { type: 'palette', key:
|
|
50053
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49849
50054
|
},
|
|
49850
50055
|
subtextStyle: {
|
|
49851
50056
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
@@ -49884,7 +50089,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49884
50089
|
titleLabel: {
|
|
49885
50090
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
49886
50091
|
lineHeight: THEME_CONSTANTS.l4LineHeight,
|
|
49887
|
-
fontColor: { type: 'palette', key:
|
|
50092
|
+
fontColor: { type: 'palette', key: 'primaryFontColor' },
|
|
49888
50093
|
fontWeight: 'bold',
|
|
49889
50094
|
textAlign: 'left',
|
|
49890
50095
|
textBaseline: 'middle',
|
|
@@ -49905,7 +50110,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49905
50110
|
valueLabel: {
|
|
49906
50111
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
49907
50112
|
lineHeight: THEME_CONSTANTS.l4LineHeight,
|
|
49908
|
-
fontColor: { type: 'palette', key:
|
|
50113
|
+
fontColor: { type: 'palette', key: 'primaryFontColor' },
|
|
49909
50114
|
fontWeight: 'bold',
|
|
49910
50115
|
textBaseline: 'middle',
|
|
49911
50116
|
spacing: 0
|
|
@@ -49919,7 +50124,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49919
50124
|
titleStyle: {
|
|
49920
50125
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
49921
50126
|
fontWeight: 'bold',
|
|
49922
|
-
fill: { type: 'palette', key:
|
|
50127
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49923
50128
|
},
|
|
49924
50129
|
contentStyle: {
|
|
49925
50130
|
fontSize: THEME_CONSTANTS.l5FontSize,
|
|
@@ -49950,7 +50155,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
49950
50155
|
animation: false,
|
|
49951
50156
|
style: {
|
|
49952
50157
|
fontSize: THEME_CONSTANTS.l4FontSize,
|
|
49953
|
-
fill: { type: 'palette', key:
|
|
50158
|
+
fill: { type: 'palette', key: 'primaryFontColor' }
|
|
49954
50159
|
}
|
|
49955
50160
|
};
|
|
49956
50161
|
|
|
@@ -50141,6 +50346,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50141
50346
|
SeriesTypeEnum["circlePacking"] = "circlePacking";
|
|
50142
50347
|
SeriesTypeEnum["waterfall"] = "waterfall";
|
|
50143
50348
|
SeriesTypeEnum["heatmap"] = "heatmap";
|
|
50349
|
+
SeriesTypeEnum["correlation"] = "correlation";
|
|
50144
50350
|
})(SeriesTypeEnum || (SeriesTypeEnum = {}));
|
|
50145
50351
|
var SeriesMarkNameEnum;
|
|
50146
50352
|
(function (SeriesMarkNameEnum) {
|
|
@@ -50192,6 +50398,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50192
50398
|
SeriesMarkNameEnum["stackLabel"] = "stackLabel";
|
|
50193
50399
|
SeriesMarkNameEnum["word"] = "word";
|
|
50194
50400
|
SeriesMarkNameEnum["fillingWord"] = "fillingWord";
|
|
50401
|
+
SeriesMarkNameEnum["nodePoint"] = "nodePoint";
|
|
50402
|
+
SeriesMarkNameEnum["ripplePoint"] = "ripplePoint";
|
|
50403
|
+
SeriesMarkNameEnum["centerPoint"] = "centerPoint";
|
|
50404
|
+
SeriesMarkNameEnum["centerLabel"] = "centerLabel";
|
|
50195
50405
|
})(SeriesMarkNameEnum || (SeriesMarkNameEnum = {}));
|
|
50196
50406
|
const seriesMarkNameSet = new Set(Object.values(SeriesMarkNameEnum));
|
|
50197
50407
|
|
|
@@ -50215,6 +50425,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50215
50425
|
MarkTypeEnum["linkPath"] = "linkPath";
|
|
50216
50426
|
MarkTypeEnum["progressArc"] = "progressArc";
|
|
50217
50427
|
MarkTypeEnum["cell"] = "cell";
|
|
50428
|
+
MarkTypeEnum["ripple"] = "ripple";
|
|
50218
50429
|
MarkTypeEnum["component"] = "component";
|
|
50219
50430
|
MarkTypeEnum["label"] = "label";
|
|
50220
50431
|
})(MarkTypeEnum || (MarkTypeEnum = {}));
|
|
@@ -50281,6 +50492,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50281
50492
|
|
|
50282
50493
|
const heatmapSeriesMark = Object.assign(Object.assign({}, baseSeriesMark), { [SeriesMarkNameEnum.cell]: { name: SeriesMarkNameEnum.cell, type: MarkTypeEnum.cell }, [SeriesMarkNameEnum.cellBackground]: { name: SeriesMarkNameEnum.cellBackground, type: MarkTypeEnum.cell } });
|
|
50283
50494
|
|
|
50495
|
+
const correlationSeriesMark = Object.assign(Object.assign({}, baseSeriesMark), { [SeriesMarkNameEnum.nodePoint]: { name: SeriesMarkNameEnum.nodePoint, type: MarkTypeEnum.symbol }, [SeriesMarkNameEnum.ripplePoint]: { name: SeriesMarkNameEnum.ripplePoint, type: MarkTypeEnum.ripple }, [SeriesMarkNameEnum.centerPoint]: { name: SeriesMarkNameEnum.centerPoint, type: MarkTypeEnum.symbol }, [SeriesMarkNameEnum.centerLabel]: { name: SeriesMarkNameEnum.centerLabel, type: MarkTypeEnum.text } });
|
|
50496
|
+
|
|
50284
50497
|
const seriesMarkInfoMap = {
|
|
50285
50498
|
[SeriesTypeEnum.bar]: barSeriesMark,
|
|
50286
50499
|
[SeriesTypeEnum.bar3d]: bar3dSeriesMark,
|
|
@@ -50309,7 +50522,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50309
50522
|
[SeriesTypeEnum.sunburst]: sunburstSeriesMark,
|
|
50310
50523
|
[SeriesTypeEnum.rangeColumn]: rangeColumnSeriesMark,
|
|
50311
50524
|
[SeriesTypeEnum.circlePacking]: circlePackingSeriesMark,
|
|
50312
|
-
[SeriesTypeEnum.heatmap]: heatmapSeriesMark
|
|
50525
|
+
[SeriesTypeEnum.heatmap]: heatmapSeriesMark,
|
|
50526
|
+
[SeriesTypeEnum.correlation]: correlationSeriesMark
|
|
50313
50527
|
};
|
|
50314
50528
|
|
|
50315
50529
|
function baseMerge(target, source, shallowArray = false) {
|
|
@@ -50467,7 +50681,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50467
50681
|
labelReverseFontColor: '#202226',
|
|
50468
50682
|
axisGridColor: '#404349',
|
|
50469
50683
|
axisDomainColor: '#4b4f54',
|
|
50470
|
-
axisLabelFontColor: '#bbbdc3',
|
|
50471
50684
|
dataZoomHandlerStrokeColor: '#888c93',
|
|
50472
50685
|
dataZoomHandlerFillColor: '#202226',
|
|
50473
50686
|
dataZoomBackgroundColor: '#404349',
|
|
@@ -50475,6 +50688,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
50475
50688
|
dataZoomSelectedColor: '#4284FF',
|
|
50476
50689
|
scrollBarSliderColor: '#ffffff',
|
|
50477
50690
|
tooltipBackgroundColor: '#404349',
|
|
50691
|
+
markLabelBackgroundColor: '#f0bd30',
|
|
50478
50692
|
titleFontColor: '#fdfdfd',
|
|
50479
50693
|
labelFontColor: '#bbbdc3'
|
|
50480
50694
|
}
|
|
@@ -53512,9 +53726,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
53512
53726
|
getState() {
|
|
53513
53727
|
return this.state._stateMap;
|
|
53514
53728
|
}
|
|
53515
|
-
get tooltipHelper() {
|
|
53516
|
-
return this._tooltipHelper;
|
|
53517
|
-
}
|
|
53518
53729
|
constructor(spec, option) {
|
|
53519
53730
|
var _a, _b, _c;
|
|
53520
53731
|
super(option);
|
|
@@ -54628,21 +54839,21 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
54628
54839
|
this.layoutNormalInlineItems(items.filter(x => x.layoutType === 'normal-inline'));
|
|
54629
54840
|
this.layoutNormalItems(items.filter(x => x.layoutType === 'normal'));
|
|
54630
54841
|
const layoutTemp = {
|
|
54631
|
-
|
|
54632
|
-
|
|
54633
|
-
|
|
54634
|
-
|
|
54842
|
+
left: this.leftCurrent,
|
|
54843
|
+
top: this.topCurrent,
|
|
54844
|
+
right: this.rightCurrent,
|
|
54845
|
+
bottom: this.bottomCurrent
|
|
54635
54846
|
};
|
|
54636
54847
|
const regionItems = items.filter(x => x.layoutType === 'region');
|
|
54637
54848
|
const relativeItems = items.filter(x => x.layoutType === 'region-relative');
|
|
54638
54849
|
this.layoutRegionItems(regionItems, relativeItems);
|
|
54639
54850
|
if (relativeItems.some(i => i.getAutoIndent())) {
|
|
54640
|
-
const { top, bottom, left, right } = this._checkAutoIndent(relativeItems);
|
|
54851
|
+
const { top, bottom, left, right } = this._checkAutoIndent(relativeItems, layoutTemp);
|
|
54641
54852
|
if (top || bottom || left || right) {
|
|
54642
|
-
this.topCurrent = layoutTemp.
|
|
54643
|
-
this.bottomCurrent = layoutTemp.
|
|
54644
|
-
this.leftCurrent = layoutTemp.
|
|
54645
|
-
this.rightCurrent = layoutTemp.
|
|
54853
|
+
this.topCurrent = layoutTemp.top + top;
|
|
54854
|
+
this.bottomCurrent = layoutTemp.bottom - bottom;
|
|
54855
|
+
this.leftCurrent = layoutTemp.left + left;
|
|
54856
|
+
this.rightCurrent = layoutTemp.right - right;
|
|
54646
54857
|
this.layoutRegionItems(regionItems, relativeItems);
|
|
54647
54858
|
}
|
|
54648
54859
|
}
|
|
@@ -54801,32 +55012,42 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
54801
55012
|
};
|
|
54802
55013
|
return result;
|
|
54803
55014
|
}
|
|
54804
|
-
_checkAutoIndent(items) {
|
|
55015
|
+
_checkAutoIndent(items, layoutTemp) {
|
|
54805
55016
|
const result = {
|
|
54806
55017
|
top: 0,
|
|
54807
55018
|
left: 0,
|
|
54808
55019
|
bottom: 0,
|
|
54809
55020
|
right: 0
|
|
54810
55021
|
};
|
|
54811
|
-
const rightCurrent = this._chartViewBox.x2 - this._chartViewBox.x1 - this.rightCurrent;
|
|
54812
|
-
const bottomCurrent = this._chartViewBox.y2 - this._chartViewBox.y1 - this.bottomCurrent;
|
|
54813
55022
|
items.forEach(i => {
|
|
54814
55023
|
if (!i.getVisible() || !i.getAutoIndent()) {
|
|
54815
55024
|
return;
|
|
54816
55025
|
}
|
|
54817
55026
|
const vOrH = i.layoutOrient === 'left' || i.layoutOrient === 'right';
|
|
54818
|
-
const
|
|
55027
|
+
const itemOuter = i.getLastComputeOutBounds();
|
|
55028
|
+
const outer = this._getOutInLayout(itemOuter, i, layoutTemp);
|
|
54819
55029
|
if (vOrH) {
|
|
54820
|
-
result.top = Math.max(result.top, outer.
|
|
54821
|
-
result.bottom = Math.max(result.bottom, outer.
|
|
55030
|
+
result.top = Math.max(result.top, outer.top);
|
|
55031
|
+
result.bottom = Math.max(result.bottom, outer.bottom);
|
|
54822
55032
|
}
|
|
54823
55033
|
else {
|
|
54824
|
-
result.left = Math.max(result.left, outer.
|
|
54825
|
-
result.right = Math.max(result.right, outer.
|
|
55034
|
+
result.left = Math.max(result.left, outer.left);
|
|
55035
|
+
result.right = Math.max(result.right, outer.right);
|
|
54826
55036
|
}
|
|
54827
55037
|
});
|
|
54828
55038
|
return result;
|
|
54829
55039
|
}
|
|
55040
|
+
_getOutInLayout(itemOuter, i, tempBorder) {
|
|
55041
|
+
const { x, y } = i.getLayoutStartPoint();
|
|
55042
|
+
const { width, height } = i.getLayoutRect();
|
|
55043
|
+
const result = {
|
|
55044
|
+
left: tempBorder.left - (x - itemOuter.x1),
|
|
55045
|
+
right: x + width + itemOuter.x2 - tempBorder.right,
|
|
55046
|
+
top: tempBorder.top - (y - itemOuter.y1),
|
|
55047
|
+
bottom: y + height + itemOuter.y2 - tempBorder.bottom
|
|
55048
|
+
};
|
|
55049
|
+
return result;
|
|
55050
|
+
}
|
|
54830
55051
|
}
|
|
54831
55052
|
Layout.type = 'base';
|
|
54832
55053
|
|
|
@@ -55287,6 +55508,32 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
55287
55508
|
};
|
|
55288
55509
|
return result;
|
|
55289
55510
|
}
|
|
55511
|
+
_checkAutoIndent(items) {
|
|
55512
|
+
const result = {
|
|
55513
|
+
top: 0,
|
|
55514
|
+
left: 0,
|
|
55515
|
+
bottom: 0,
|
|
55516
|
+
right: 0
|
|
55517
|
+
};
|
|
55518
|
+
const rightCurrent = this._chartViewBox.x2 - this._chartViewBox.x1 - this.rightCurrent;
|
|
55519
|
+
const bottomCurrent = this._chartViewBox.y2 - this._chartViewBox.y1 - this.bottomCurrent;
|
|
55520
|
+
items.forEach(i => {
|
|
55521
|
+
if (!i.getVisible() || !i.getAutoIndent()) {
|
|
55522
|
+
return;
|
|
55523
|
+
}
|
|
55524
|
+
const vOrH = i.layoutOrient === 'left' || i.layoutOrient === 'right';
|
|
55525
|
+
const outer = i.getLastComputeOutBounds();
|
|
55526
|
+
if (vOrH) {
|
|
55527
|
+
result.top = Math.max(result.top, outer.y1 - this.topCurrent);
|
|
55528
|
+
result.bottom = Math.max(result.bottom, outer.y2 - bottomCurrent);
|
|
55529
|
+
}
|
|
55530
|
+
else {
|
|
55531
|
+
result.left = Math.max(result.left, outer.x1 - this.leftCurrent);
|
|
55532
|
+
result.right = Math.max(result.right, outer.x2 - rightCurrent);
|
|
55533
|
+
}
|
|
55534
|
+
});
|
|
55535
|
+
return result;
|
|
55536
|
+
}
|
|
55290
55537
|
}
|
|
55291
55538
|
Layout3d.type = 'layout3d';
|
|
55292
55539
|
const registerLayout3d = () => {
|
|
@@ -56635,6 +56882,26 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
56635
56882
|
}
|
|
56636
56883
|
LinkPathMark.type = MarkTypeEnum.linkPath;
|
|
56637
56884
|
|
|
56885
|
+
class RippleMark extends BaseMark {
|
|
56886
|
+
constructor() {
|
|
56887
|
+
super(...arguments);
|
|
56888
|
+
this.type = RippleMark.type;
|
|
56889
|
+
}
|
|
56890
|
+
_getDefaultStyle() {
|
|
56891
|
+
const defaultStyle = Object.assign(Object.assign({}, super._getDefaultStyle()), { x: 0, y: 0, ripple: 0 });
|
|
56892
|
+
return defaultStyle;
|
|
56893
|
+
}
|
|
56894
|
+
_initProduct(group) {
|
|
56895
|
+
registerRippleGlyph();
|
|
56896
|
+
const view = this.getVGrammarView();
|
|
56897
|
+
const id = this.getProductId();
|
|
56898
|
+
const glyphType = 'ripplePoint';
|
|
56899
|
+
this._product = view.glyph(glyphType, group !== null && group !== void 0 ? group : view.rootMark).id(id);
|
|
56900
|
+
this._compiledProductId = id;
|
|
56901
|
+
}
|
|
56902
|
+
}
|
|
56903
|
+
RippleMark.type = MarkTypeEnum.ripple;
|
|
56904
|
+
|
|
56638
56905
|
class ProgressArcMark extends BaseArcMark {
|
|
56639
56906
|
constructor() {
|
|
56640
56907
|
super(...arguments);
|
|
@@ -57916,7 +58183,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
57916
58183
|
};
|
|
57917
58184
|
registerVChartCore();
|
|
57918
58185
|
|
|
57919
|
-
const version = "1.5.1
|
|
58186
|
+
const version = "1.5.1";
|
|
57920
58187
|
|
|
57921
58188
|
class ChartData {
|
|
57922
58189
|
get dataList() {
|
|
@@ -58819,6 +59086,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
58819
59086
|
}
|
|
58820
59087
|
else {
|
|
58821
59088
|
const tempSpec = colorSpec;
|
|
59089
|
+
if (tempSpec.range) {
|
|
59090
|
+
tempSpec.range = tempSpec.range.map(color => { var _a; return getActualColor(color, (_a = this._theme) === null || _a === void 0 ? void 0 : _a.colorScheme); });
|
|
59091
|
+
}
|
|
58822
59092
|
Object.prototype.hasOwnProperty.call(tempSpec, 'type') && (colorScaleSpec.type = tempSpec.type);
|
|
58823
59093
|
Object.prototype.hasOwnProperty.call(tempSpec, 'domain') && (colorScaleSpec.domain = tempSpec.domain);
|
|
58824
59094
|
Object.prototype.hasOwnProperty.call(tempSpec, 'range') && (colorScaleSpec.range = tempSpec.range);
|
|
@@ -59440,6 +59710,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
59440
59710
|
ChartTypeEnum["sunburst"] = "sunburst";
|
|
59441
59711
|
ChartTypeEnum["circlePacking"] = "circlePacking";
|
|
59442
59712
|
ChartTypeEnum["heatmap"] = "heatmap";
|
|
59713
|
+
ChartTypeEnum["correlation"] = "correlation";
|
|
59443
59714
|
})(ChartTypeEnum || (ChartTypeEnum = {}));
|
|
59444
59715
|
|
|
59445
59716
|
const addVChartProperty = (data, op) => {
|
|
@@ -60449,6 +60720,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
60449
60720
|
return this._stackOffsetSilhouette;
|
|
60450
60721
|
}
|
|
60451
60722
|
get tooltipHelper() {
|
|
60723
|
+
if (!this._tooltipHelper) {
|
|
60724
|
+
this.initTooltip();
|
|
60725
|
+
}
|
|
60452
60726
|
return this._tooltipHelper;
|
|
60453
60727
|
}
|
|
60454
60728
|
getInvalidType() {
|
|
@@ -60490,7 +60764,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
60490
60764
|
this.initStatisticalData();
|
|
60491
60765
|
this.event.emit(ChartEvent.afterInitData, { model: this });
|
|
60492
60766
|
this.initTrigger();
|
|
60493
|
-
this.initTooltip();
|
|
60494
60767
|
this.initRootMark();
|
|
60495
60768
|
this.initMark();
|
|
60496
60769
|
this._initExtensionMark();
|
|
@@ -60521,7 +60794,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
60521
60794
|
};
|
|
60522
60795
|
}
|
|
60523
60796
|
setAttrFromSpec() {
|
|
60524
|
-
var _a;
|
|
60525
60797
|
super.setAttrFromSpec();
|
|
60526
60798
|
this.setSeriesField(this._spec.seriesField);
|
|
60527
60799
|
if (isBoolean$1(this._spec.stack)) {
|
|
@@ -60541,7 +60813,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
60541
60813
|
if (isValid$1(this._spec.invalidType)) {
|
|
60542
60814
|
this._invalidType = this._spec.invalidType;
|
|
60543
60815
|
}
|
|
60544
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.updateTooltipSpec();
|
|
60545
60816
|
}
|
|
60546
60817
|
initData() {
|
|
60547
60818
|
var _a, _b, _c, _d;
|
|
@@ -61033,6 +61304,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61033
61304
|
});
|
|
61034
61305
|
this._updateExtensionMarkSpec(lastSpec);
|
|
61035
61306
|
this._updateSpecData();
|
|
61307
|
+
if (this._tooltipHelper) {
|
|
61308
|
+
this._tooltipHelper.updateTooltipSpec();
|
|
61309
|
+
}
|
|
61036
61310
|
}
|
|
61037
61311
|
onEvaluateEnd(ctx) {
|
|
61038
61312
|
this._data.updateData();
|
|
@@ -61761,7 +62035,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61761
62035
|
return this._lineMark;
|
|
61762
62036
|
}
|
|
61763
62037
|
initLineMarkStyle(direction, areaCurveType) {
|
|
61764
|
-
var _a, _b
|
|
62038
|
+
var _a, _b;
|
|
61765
62039
|
const lineMark = this._lineMark;
|
|
61766
62040
|
if (lineMark) {
|
|
61767
62041
|
this.setMarkStyle(lineMark, {
|
|
@@ -61800,7 +62074,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61800
62074
|
z: this._fieldZ ? this.dataToPositionZ.bind(this) : null
|
|
61801
62075
|
}, 'normal', AttributeLevel.Series);
|
|
61802
62076
|
this._trigger.registerMark(lineMark);
|
|
61803
|
-
(_c = this._tooltipHelper) === null || _c === void 0 ? void 0 : _c.activeTriggerSet.dimension.add(lineMark);
|
|
61804
62077
|
}
|
|
61805
62078
|
return lineMark;
|
|
61806
62079
|
}
|
|
@@ -61854,7 +62127,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61854
62127
|
return this._symbolMark;
|
|
61855
62128
|
}
|
|
61856
62129
|
initSymbolMarkStyle() {
|
|
61857
|
-
var _a;
|
|
61858
62130
|
const symbolMark = this._symbolMark;
|
|
61859
62131
|
if (!symbolMark) {
|
|
61860
62132
|
return symbolMark;
|
|
@@ -61876,7 +62148,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61876
62148
|
z: this._fieldZ ? this.dataToPositionZ.bind(this) : null
|
|
61877
62149
|
}, 'normal', AttributeLevel.Series);
|
|
61878
62150
|
this._trigger.registerMark(symbolMark);
|
|
61879
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(symbolMark);
|
|
61880
62151
|
if (this._symbolActiveMark && this._symbolMark.stateStyle.dimension_hover) {
|
|
61881
62152
|
this._symbolActiveMark.setVisible(true);
|
|
61882
62153
|
this.event.on(DimensionEventEnum.dimensionHover, this._dimensionTrigger.bind(this));
|
|
@@ -61959,6 +62230,11 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
61959
62230
|
this.initLineMark(progressive, seriesMark === 'line');
|
|
61960
62231
|
this.initSymbolMark(progressive, seriesMark === 'point');
|
|
61961
62232
|
}
|
|
62233
|
+
initTooltip() {
|
|
62234
|
+
super.initTooltip();
|
|
62235
|
+
this._lineMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._lineMark);
|
|
62236
|
+
this._symbolMark && this._tooltipHelper.activeTriggerSet.mark.add(this._symbolMark);
|
|
62237
|
+
}
|
|
61962
62238
|
initMarkStyle() {
|
|
61963
62239
|
this.initLineMarkStyle(this._direction);
|
|
61964
62240
|
this.initSymbolMarkStyle();
|
|
@@ -62202,7 +62478,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62202
62478
|
curveType
|
|
62203
62479
|
}, 'normal', AttributeLevel.Built_In);
|
|
62204
62480
|
this._trigger.registerMark(areaMark);
|
|
62205
|
-
this._tooltipHelper.activeTriggerSet.dimension.add(areaMark);
|
|
62206
62481
|
Object.keys(areaMark.stateStyle).forEach(state => {
|
|
62207
62482
|
if (areaMark.stateStyle[state].stroke) {
|
|
62208
62483
|
areaMark.setPostProcess('stroke', result => {
|
|
@@ -62231,6 +62506,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62231
62506
|
}
|
|
62232
62507
|
initTooltip() {
|
|
62233
62508
|
this._tooltipHelper = new AreaSeriesTooltipHelper(this);
|
|
62509
|
+
this._areaMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._areaMark);
|
|
62510
|
+
this._lineMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._lineMark);
|
|
62511
|
+
this._symbolMark && this._tooltipHelper.activeTriggerSet.mark.add(this._symbolMark);
|
|
62234
62512
|
}
|
|
62235
62513
|
viewDataStatisticsUpdate(d) {
|
|
62236
62514
|
super.viewDataStatisticsUpdate(d);
|
|
@@ -62432,14 +62710,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62432
62710
|
});
|
|
62433
62711
|
}
|
|
62434
62712
|
initMarkStyle() {
|
|
62435
|
-
var _a;
|
|
62436
62713
|
const rectMark = this._rectMark;
|
|
62437
62714
|
if (rectMark) {
|
|
62438
62715
|
this.setMarkStyle(rectMark, {
|
|
62439
62716
|
fill: this.getColorAttribute()
|
|
62440
62717
|
}, 'normal', AttributeLevel.Series);
|
|
62441
62718
|
this._trigger.registerMark(rectMark);
|
|
62442
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(rectMark);
|
|
62443
62719
|
}
|
|
62444
62720
|
}
|
|
62445
62721
|
initLabelMarkStyle(textMark) {
|
|
@@ -62454,6 +62730,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62454
62730
|
z: this._fieldZ ? this.dataToPositionZ.bind(this) : null
|
|
62455
62731
|
});
|
|
62456
62732
|
}
|
|
62733
|
+
initTooltip() {
|
|
62734
|
+
super.initTooltip();
|
|
62735
|
+
this._rectMark && this._tooltipHelper.activeTriggerSet.mark.add(this._rectMark);
|
|
62736
|
+
}
|
|
62457
62737
|
init(option) {
|
|
62458
62738
|
var _a, _b;
|
|
62459
62739
|
super.init(option);
|
|
@@ -62951,7 +63231,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62951
63231
|
this._symbolMark.setAnimationConfig(animationConfig((_c = Factory.getAnimationInKey('scatter')) === null || _c === void 0 ? void 0 : _c({}, appearPreset), userAnimationConfig(SeriesMarkNameEnum.point, this._spec)));
|
|
62952
63232
|
}
|
|
62953
63233
|
initSymbolMarkStyle() {
|
|
62954
|
-
var _a;
|
|
62955
63234
|
const symbolMark = this._symbolMark;
|
|
62956
63235
|
if (!symbolMark) {
|
|
62957
63236
|
return;
|
|
@@ -62980,7 +63259,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
62980
63259
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.User_Mark);
|
|
62981
63260
|
}
|
|
62982
63261
|
this._trigger.registerMark(symbolMark);
|
|
62983
|
-
|
|
63262
|
+
}
|
|
63263
|
+
initTooltip() {
|
|
63264
|
+
super.initTooltip();
|
|
63265
|
+
this._symbolMark && this._tooltipHelper.activeTriggerSet.mark.add(this._symbolMark);
|
|
62984
63266
|
}
|
|
62985
63267
|
viewDataStatisticsUpdate(d) {
|
|
62986
63268
|
super.viewDataStatisticsUpdate(d);
|
|
@@ -63932,6 +64214,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
63932
64214
|
}
|
|
63933
64215
|
clearScroll() {
|
|
63934
64216
|
}
|
|
64217
|
+
clearDrag() {
|
|
64218
|
+
}
|
|
63935
64219
|
parserDragEvent() {
|
|
63936
64220
|
return true;
|
|
63937
64221
|
}
|
|
@@ -63970,6 +64254,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
63970
64254
|
}
|
|
63971
64255
|
clearScroll() {
|
|
63972
64256
|
}
|
|
64257
|
+
clearDrag() {
|
|
64258
|
+
}
|
|
63973
64259
|
}
|
|
63974
64260
|
|
|
63975
64261
|
const defaultTriggerEvent = {
|
|
@@ -64023,6 +64309,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64023
64309
|
}
|
|
64024
64310
|
};
|
|
64025
64311
|
|
|
64312
|
+
const delayMap = {
|
|
64313
|
+
debounce: debounce,
|
|
64314
|
+
throttle: throttle
|
|
64315
|
+
};
|
|
64026
64316
|
class Zoomable {
|
|
64027
64317
|
initZoomable(evt, mode = exports.RenderModeEnum['desktop-browser']) {
|
|
64028
64318
|
this._eventObj = evt;
|
|
@@ -64035,112 +64325,124 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64035
64325
|
_getTriggerEvent(type) {
|
|
64036
64326
|
return defaultTriggerEvent[this._renderMode][type];
|
|
64037
64327
|
}
|
|
64038
|
-
|
|
64039
|
-
|
|
64040
|
-
|
|
64041
|
-
}
|
|
64042
|
-
|
|
64043
|
-
|
|
64044
|
-
|
|
64045
|
-
|
|
64046
|
-
|
|
64047
|
-
|
|
64048
|
-
|
|
64049
|
-
|
|
64050
|
-
|
|
64051
|
-
|
|
64052
|
-
|
|
64053
|
-
|
|
64054
|
-
|
|
64055
|
-
|
|
64056
|
-
|
|
64057
|
-
|
|
64058
|
-
|
|
64059
|
-
|
|
64060
|
-
|
|
64061
|
-
|
|
64062
|
-
this._eventObj.emit('zoom', {
|
|
64063
|
-
scale: event.zoomDelta,
|
|
64064
|
-
scaleCenter: { x: event.zoomX, y: event.zoomY },
|
|
64065
|
-
model: this
|
|
64066
|
-
});
|
|
64328
|
+
_zoomEventDispatch(params, regionOrSeries, callback) {
|
|
64329
|
+
if (!params.event) {
|
|
64330
|
+
return;
|
|
64331
|
+
}
|
|
64332
|
+
const event = params.event.clone();
|
|
64333
|
+
this._zoomableTrigger.parserZoomEvent(event);
|
|
64334
|
+
const { zoomDelta, zoomX, zoomY } = event;
|
|
64335
|
+
if (isNil$1(zoomDelta)) {
|
|
64336
|
+
return;
|
|
64337
|
+
}
|
|
64338
|
+
if (!isPointInRect({
|
|
64339
|
+
x: zoomX,
|
|
64340
|
+
y: zoomY
|
|
64341
|
+
}, Object.assign(Object.assign({}, regionOrSeries.getLayoutRect()), regionOrSeries.getLayoutStartPoint()))) {
|
|
64342
|
+
return;
|
|
64343
|
+
}
|
|
64344
|
+
this._clickEnable = false;
|
|
64345
|
+
if (callback) {
|
|
64346
|
+
callback({ zoomDelta, zoomX, zoomY }, event);
|
|
64347
|
+
}
|
|
64348
|
+
this._eventObj.emit('zoom', {
|
|
64349
|
+
scale: event.zoomDelta,
|
|
64350
|
+
scaleCenter: { x: event.zoomX, y: event.zoomY },
|
|
64351
|
+
model: this
|
|
64067
64352
|
});
|
|
64068
64353
|
}
|
|
64069
|
-
|
|
64354
|
+
_bindZoomEventAsRegion(eventObj, regionOrSeries, callback, option) {
|
|
64355
|
+
var _a, _b;
|
|
64356
|
+
const delayType = (_a = option === null || option === void 0 ? void 0 : option.delayType) !== null && _a !== void 0 ? _a : 'throttle';
|
|
64357
|
+
const delayTime = (_b = option === null || option === void 0 ? void 0 : option.delayTime) !== null && _b !== void 0 ? _b : 0;
|
|
64358
|
+
eventObj.on(this._getTriggerEvent('scrollEnd'), { level: Event_Bubble_Level.chart, consume: false }, delayMap[delayType]((params) => {
|
|
64359
|
+
this._zoomableTrigger.clearZoom();
|
|
64360
|
+
}, delayTime));
|
|
64361
|
+
eventObj.on(this._getTriggerEvent('scroll'), { level: Event_Bubble_Level.chart, consume: true }, delayMap[delayType]((params) => {
|
|
64362
|
+
this._zoomEventDispatch(params, regionOrSeries, callback);
|
|
64363
|
+
}, delayTime));
|
|
64364
|
+
}
|
|
64365
|
+
initZoomEventOfSeries(s, callback, option) {
|
|
64070
64366
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64071
|
-
this._bindZoomEventAsRegion(s.event, s, callback);
|
|
64367
|
+
this._bindZoomEventAsRegion(s.event, s, callback, option);
|
|
64072
64368
|
}
|
|
64073
64369
|
}
|
|
64074
|
-
initZoomEventOfRegions(regions, filter, callback) {
|
|
64370
|
+
initZoomEventOfRegions(regions, filter, callback, option) {
|
|
64075
64371
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64076
64372
|
regions.forEach(r => {
|
|
64077
64373
|
if (filter) {
|
|
64078
64374
|
r.getSeries().forEach(s => {
|
|
64079
64375
|
if (filter(s)) {
|
|
64080
|
-
this._bindZoomEventAsRegion(s.event, s, callback);
|
|
64376
|
+
this._bindZoomEventAsRegion(s.event, s, callback, option);
|
|
64081
64377
|
}
|
|
64082
64378
|
});
|
|
64083
64379
|
}
|
|
64084
64380
|
else {
|
|
64085
|
-
this._bindZoomEventAsRegion(this._eventObj, r, callback);
|
|
64381
|
+
this._bindZoomEventAsRegion(this._eventObj, r, callback, option);
|
|
64086
64382
|
}
|
|
64087
64383
|
});
|
|
64088
64384
|
}
|
|
64089
64385
|
}
|
|
64090
|
-
|
|
64386
|
+
_scrollEventDispatch(params, regionOrSeries, callback) {
|
|
64387
|
+
if (!params.event) {
|
|
64388
|
+
return;
|
|
64389
|
+
}
|
|
64390
|
+
const { event } = params;
|
|
64391
|
+
this._zoomableTrigger.parserScrollEvent(event);
|
|
64392
|
+
const { scrollX, scrollY } = event;
|
|
64393
|
+
if (isNil$1(scrollX) && isNil$1(scrollY)) {
|
|
64394
|
+
return;
|
|
64395
|
+
}
|
|
64396
|
+
if (!isPointInRect({
|
|
64397
|
+
x: event.canvasX,
|
|
64398
|
+
y: event.canvasY
|
|
64399
|
+
}, Object.assign(Object.assign({}, regionOrSeries.getLayoutRect()), regionOrSeries.getLayoutStartPoint()))) {
|
|
64400
|
+
return;
|
|
64401
|
+
}
|
|
64402
|
+
this._clickEnable = false;
|
|
64403
|
+
if (callback) {
|
|
64404
|
+
callback({ scrollX, scrollY }, event);
|
|
64405
|
+
}
|
|
64406
|
+
this._eventObj.emit('scroll', {
|
|
64407
|
+
scrollX,
|
|
64408
|
+
scrollY,
|
|
64409
|
+
model: this
|
|
64410
|
+
});
|
|
64411
|
+
}
|
|
64412
|
+
_bindScrollEventAsRegion(eventObj, regionOrSeries, callback, option) {
|
|
64413
|
+
var _a, _b;
|
|
64414
|
+
const delayType = (_a = option === null || option === void 0 ? void 0 : option.delayType) !== null && _a !== void 0 ? _a : 'throttle';
|
|
64415
|
+
const delayTime = (_b = option === null || option === void 0 ? void 0 : option.delayTime) !== null && _b !== void 0 ? _b : 0;
|
|
64416
|
+
eventObj.on(this._getTriggerEvent('scrollEnd'), { level: Event_Bubble_Level.chart, consume: false }, delayMap[delayType]((params) => {
|
|
64417
|
+
this._zoomableTrigger.clearScroll();
|
|
64418
|
+
}, delayTime));
|
|
64419
|
+
eventObj.on(this._getTriggerEvent('scroll'), { level: Event_Bubble_Level.chart, consume: true }, delayMap[delayType]((params) => {
|
|
64420
|
+
this._scrollEventDispatch(params, regionOrSeries, callback);
|
|
64421
|
+
}, delayTime));
|
|
64422
|
+
}
|
|
64423
|
+
initScrollEventOfSeries(s, callback, option) {
|
|
64091
64424
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64092
|
-
this._bindScrollEventAsRegion(s.event, s, callback);
|
|
64425
|
+
this._bindScrollEventAsRegion(s.event, s, callback, option);
|
|
64093
64426
|
}
|
|
64094
64427
|
}
|
|
64095
|
-
initScrollEventOfRegions(regions, filter, callback) {
|
|
64428
|
+
initScrollEventOfRegions(regions, filter, callback, option) {
|
|
64096
64429
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64097
64430
|
regions.forEach(r => {
|
|
64098
64431
|
if (filter) {
|
|
64099
64432
|
r.getSeries().forEach(s => {
|
|
64100
64433
|
if (filter(s)) {
|
|
64101
|
-
this._bindScrollEventAsRegion(s.event, s, callback);
|
|
64434
|
+
this._bindScrollEventAsRegion(s.event, s, callback, option);
|
|
64102
64435
|
}
|
|
64103
64436
|
});
|
|
64104
64437
|
}
|
|
64105
64438
|
else {
|
|
64106
|
-
this._bindScrollEventAsRegion(this._eventObj, r, callback);
|
|
64439
|
+
this._bindScrollEventAsRegion(this._eventObj, r, callback, option);
|
|
64107
64440
|
}
|
|
64108
64441
|
});
|
|
64109
64442
|
}
|
|
64110
64443
|
}
|
|
64111
|
-
|
|
64112
|
-
eventObj.on(this._getTriggerEvent('
|
|
64113
|
-
this._zoomableTrigger.clearScroll();
|
|
64114
|
-
});
|
|
64115
|
-
eventObj.on(this._getTriggerEvent('scroll'), { level: Event_Bubble_Level.chart, consume: true }, params => {
|
|
64116
|
-
if (!params.event) {
|
|
64117
|
-
return;
|
|
64118
|
-
}
|
|
64119
|
-
const { event } = params;
|
|
64120
|
-
this._zoomableTrigger.parserScrollEvent(event);
|
|
64121
|
-
const { scrollX, scrollY } = event;
|
|
64122
|
-
if (isNil$1(scrollX) && isNil$1(scrollY)) {
|
|
64123
|
-
return;
|
|
64124
|
-
}
|
|
64125
|
-
if (!isPointInRect({
|
|
64126
|
-
x: event.canvasX,
|
|
64127
|
-
y: event.canvasY
|
|
64128
|
-
}, Object.assign(Object.assign({}, regionOrSeries.getLayoutRect()), regionOrSeries.getLayoutStartPoint()))) {
|
|
64129
|
-
return;
|
|
64130
|
-
}
|
|
64131
|
-
this._clickEnable = false;
|
|
64132
|
-
if (callback) {
|
|
64133
|
-
callback({ scrollX, scrollY }, event);
|
|
64134
|
-
}
|
|
64135
|
-
this._eventObj.emit('scroll', {
|
|
64136
|
-
scrollX,
|
|
64137
|
-
scrollY,
|
|
64138
|
-
model: this
|
|
64139
|
-
});
|
|
64140
|
-
});
|
|
64141
|
-
}
|
|
64142
|
-
_bindDragEventAsRegion(eventObj, regionOrSeries, callback) {
|
|
64143
|
-
eventObj.on(this._getTriggerEvent('start'), { level: Event_Bubble_Level.chart }, params => {
|
|
64444
|
+
_bindDragEventAsRegion(eventObj, regionOrSeries, callback, option) {
|
|
64445
|
+
eventObj.on(this._getTriggerEvent('start'), { level: Event_Bubble_Level.chart }, (params) => {
|
|
64144
64446
|
if (!params.event) {
|
|
64145
64447
|
return;
|
|
64146
64448
|
}
|
|
@@ -64150,21 +64452,21 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64150
64452
|
y: event.canvasY
|
|
64151
64453
|
}, Object.assign(Object.assign({}, regionOrSeries.getLayoutRect()), regionOrSeries.getLayoutStartPoint()));
|
|
64152
64454
|
if (shouldTrigger) {
|
|
64153
|
-
this._handleDrag(params, callback);
|
|
64455
|
+
this._handleDrag(params, callback, option);
|
|
64154
64456
|
}
|
|
64155
64457
|
});
|
|
64156
64458
|
eventObj.on('click', { level: Event_Bubble_Level.chart }, () => {
|
|
64157
64459
|
return !this._clickEnable;
|
|
64158
64460
|
});
|
|
64159
64461
|
}
|
|
64160
|
-
initDragEventOfSeries(s, callback) {
|
|
64462
|
+
initDragEventOfSeries(s, callback, option) {
|
|
64161
64463
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64162
64464
|
s.event.on(this._getTriggerEvent('start'), { level: Event_Bubble_Level.model, filter: ({ model }) => (model === null || model === void 0 ? void 0 : model.id) === s.id }, params => {
|
|
64163
|
-
this._handleDrag(params, callback);
|
|
64465
|
+
this._handleDrag(params, callback, option);
|
|
64164
64466
|
});
|
|
64165
64467
|
}
|
|
64166
64468
|
}
|
|
64167
|
-
initDragEventOfRegions(regions, filter, callback) {
|
|
64469
|
+
initDragEventOfRegions(regions, filter, callback, option) {
|
|
64168
64470
|
if (defaultTriggerEvent[this._renderMode]) {
|
|
64169
64471
|
regions.forEach(r => {
|
|
64170
64472
|
if (filter) {
|
|
@@ -64180,45 +64482,65 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64180
64482
|
});
|
|
64181
64483
|
}
|
|
64182
64484
|
else {
|
|
64183
|
-
this._bindDragEventAsRegion(this._eventObj, r, callback);
|
|
64485
|
+
this._bindDragEventAsRegion(this._eventObj, r, callback, option);
|
|
64184
64486
|
}
|
|
64185
64487
|
});
|
|
64186
64488
|
}
|
|
64187
64489
|
}
|
|
64188
|
-
_handleDrag(params, callback) {
|
|
64490
|
+
_handleDrag(params, callback, option) {
|
|
64491
|
+
var _a, _b, _c;
|
|
64189
64492
|
this._clickEnable = true;
|
|
64190
64493
|
if (!this._zoomableTrigger.parserDragEvent(params.event)) {
|
|
64191
64494
|
return;
|
|
64192
64495
|
}
|
|
64496
|
+
const delayType = (_a = option === null || option === void 0 ? void 0 : option.delayType) !== null && _a !== void 0 ? _a : 'throttle';
|
|
64497
|
+
const delayTime = (_b = option === null || option === void 0 ? void 0 : option.delayTime) !== null && _b !== void 0 ? _b : 0;
|
|
64498
|
+
const realTime = (_c = option === null || option === void 0 ? void 0 : option.realTime) !== null && _c !== void 0 ? _c : true;
|
|
64193
64499
|
const move = this._getTriggerEvent('move');
|
|
64194
64500
|
const end = this._getTriggerEvent('end');
|
|
64195
64501
|
const event = params.event;
|
|
64196
|
-
let
|
|
64197
|
-
let
|
|
64198
|
-
|
|
64502
|
+
let moveX = event.canvasX;
|
|
64503
|
+
let moveY = event.canvasY;
|
|
64504
|
+
let upX = event.canvasX;
|
|
64505
|
+
let upY = event.canvasY;
|
|
64506
|
+
const mouseup = delayMap[delayType]((params) => {
|
|
64507
|
+
this._clickEnable = false;
|
|
64508
|
+
const event = params.event;
|
|
64509
|
+
const dx = event.canvasX - upX;
|
|
64510
|
+
const dy = event.canvasY - upY;
|
|
64511
|
+
const delta = [dx, dy];
|
|
64512
|
+
upX = event.canvasX;
|
|
64513
|
+
upY = event.canvasY;
|
|
64514
|
+
if (!realTime && callback) {
|
|
64515
|
+
callback(delta, params.event);
|
|
64516
|
+
}
|
|
64517
|
+
this._eventObj.emit('panend', {
|
|
64518
|
+
delta,
|
|
64519
|
+
model: this
|
|
64520
|
+
});
|
|
64199
64521
|
this._zoomableTrigger.pointerId = null;
|
|
64200
64522
|
this._eventObj.off(move, { level: Event_Bubble_Level.chart, source: Event_Source_Type.chart }, mousemove);
|
|
64201
64523
|
this._eventObj.off(end, { level: Event_Bubble_Level.chart, source: Event_Source_Type.window }, mouseup);
|
|
64202
|
-
};
|
|
64203
|
-
const mousemove = (params) => {
|
|
64524
|
+
}, delayTime);
|
|
64525
|
+
const mousemove = delayMap[delayType]((params) => {
|
|
64204
64526
|
if (!this._zoomableTrigger.parserDragEvent(params.event)) {
|
|
64205
64527
|
return;
|
|
64206
64528
|
}
|
|
64207
64529
|
this._clickEnable = false;
|
|
64208
64530
|
const event = params.event;
|
|
64209
|
-
const dx = event.canvasX -
|
|
64210
|
-
const dy = event.canvasY -
|
|
64531
|
+
const dx = event.canvasX - moveX;
|
|
64532
|
+
const dy = event.canvasY - moveY;
|
|
64211
64533
|
const delta = [dx, dy];
|
|
64212
|
-
|
|
64213
|
-
|
|
64214
|
-
if (callback) {
|
|
64534
|
+
moveX = event.canvasX;
|
|
64535
|
+
moveY = event.canvasY;
|
|
64536
|
+
if (realTime && callback) {
|
|
64215
64537
|
callback(delta, params.event);
|
|
64216
64538
|
}
|
|
64217
64539
|
this._eventObj.emit('panmove', {
|
|
64218
64540
|
delta,
|
|
64219
64541
|
model: this
|
|
64220
64542
|
});
|
|
64221
|
-
};
|
|
64543
|
+
}, delayTime);
|
|
64222
64544
|
this._eventObj.on(move, { level: Event_Bubble_Level.chart, source: Event_Source_Type.chart }, mousemove);
|
|
64223
64545
|
this._eventObj.on(end, { level: Event_Bubble_Level.chart, source: Event_Source_Type.chart }, mouseup);
|
|
64224
64546
|
}
|
|
@@ -64624,7 +64946,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64624
64946
|
});
|
|
64625
64947
|
}
|
|
64626
64948
|
initMarkStyle() {
|
|
64627
|
-
var _a;
|
|
64628
64949
|
const pathMark = this._pathMark;
|
|
64629
64950
|
if (pathMark) {
|
|
64630
64951
|
this.setMarkStyle(pathMark, {
|
|
@@ -64647,7 +64968,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64647
64968
|
smoothScale: true
|
|
64648
64969
|
}, 'normal', AttributeLevel.Built_In);
|
|
64649
64970
|
this._trigger.registerMark(pathMark);
|
|
64650
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(pathMark);
|
|
64651
64971
|
}
|
|
64652
64972
|
}
|
|
64653
64973
|
initLabelMarkStyle(labelMark) {
|
|
@@ -64670,6 +64990,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
64670
64990
|
}
|
|
64671
64991
|
initTooltip() {
|
|
64672
64992
|
this._tooltipHelper = new MapSeriesTooltipHelper(this);
|
|
64993
|
+
this._pathMark && this._tooltipHelper.activeTriggerSet.mark.add(this._pathMark);
|
|
64673
64994
|
}
|
|
64674
64995
|
getPath(datum) {
|
|
64675
64996
|
var _a;
|
|
@@ -65338,7 +65659,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65338
65659
|
});
|
|
65339
65660
|
}
|
|
65340
65661
|
initMarkStyle() {
|
|
65341
|
-
var _a;
|
|
65342
65662
|
const pieMark = this._pieMark;
|
|
65343
65663
|
if (pieMark) {
|
|
65344
65664
|
this.setMarkStyle(pieMark, {
|
|
@@ -65358,9 +65678,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65358
65678
|
centerOffset: this._centerOffset
|
|
65359
65679
|
}, 'normal', AttributeLevel.Series);
|
|
65360
65680
|
this._trigger.registerMark(pieMark);
|
|
65361
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(pieMark);
|
|
65362
65681
|
}
|
|
65363
65682
|
}
|
|
65683
|
+
initTooltip() {
|
|
65684
|
+
super.initTooltip();
|
|
65685
|
+
this._pieMark && this._tooltipHelper.activeTriggerSet.mark.add(this._pieMark);
|
|
65686
|
+
}
|
|
65364
65687
|
initMarkStyleWithSpec(mark, spec, key) {
|
|
65365
65688
|
super.initMarkStyleWithSpec(mark, spec, key);
|
|
65366
65689
|
if (mark.name === this._pieMarkName) {
|
|
@@ -65567,6 +65890,22 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65567
65890
|
getActiveMarks() {
|
|
65568
65891
|
return [this._pieMark];
|
|
65569
65892
|
}
|
|
65893
|
+
_mergeThemeToSpec() {
|
|
65894
|
+
if (this._shouldMergeThemeToSpec()) {
|
|
65895
|
+
const specFromChart = this._getDefaultSpecFromChart(this.getChart().getSpec());
|
|
65896
|
+
const merge = (originalSpec) => {
|
|
65897
|
+
const chartSpec = this._prepareSpecBeforeMergingTheme(specFromChart);
|
|
65898
|
+
const userSpec = this._prepareSpecBeforeMergingTheme(originalSpec);
|
|
65899
|
+
const labelSpec = mergeSpec({}, this._theme.label, chartSpec.label, userSpec.label);
|
|
65900
|
+
const labelTheme = mergeSpec({}, this._theme.label, labelSpec.position === 'inside' ? this._theme.innerLabel : this._theme.outerLabel);
|
|
65901
|
+
const newTheme = Object.assign(Object.assign({}, this._theme), { label: labelTheme });
|
|
65902
|
+
return mergeSpec({}, newTheme, chartSpec, userSpec);
|
|
65903
|
+
};
|
|
65904
|
+
const baseSpec = this._spec;
|
|
65905
|
+
this._spec = merge(baseSpec);
|
|
65906
|
+
}
|
|
65907
|
+
this._prepareSpecAfterMergingTheme();
|
|
65908
|
+
}
|
|
65570
65909
|
}
|
|
65571
65910
|
BasePieSeries.mark = pieSeriesMark;
|
|
65572
65911
|
class PieSeries extends BasePieSeries {
|
|
@@ -65675,7 +66014,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65675
66014
|
this._angle3d = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.angle3d) !== null && _b !== void 0 ? _b : -Math.PI / 3;
|
|
65676
66015
|
}
|
|
65677
66016
|
initMarkStyle() {
|
|
65678
|
-
var _a, _b, _c, _d, _e, _f, _g
|
|
66017
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
65679
66018
|
const pieMark = this._pieMark;
|
|
65680
66019
|
if (pieMark) {
|
|
65681
66020
|
this.setMarkStyle(pieMark, {
|
|
@@ -65698,12 +66037,11 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65698
66037
|
}
|
|
65699
66038
|
}
|
|
65700
66039
|
this._trigger.registerMark(pieMark);
|
|
65701
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(pieMark);
|
|
65702
66040
|
}
|
|
65703
66041
|
const labelMark = this._labelMark;
|
|
65704
66042
|
const spec = this.getSpec();
|
|
65705
66043
|
const params3d = {};
|
|
65706
|
-
if ((
|
|
66044
|
+
if ((_a = spec === null || spec === void 0 ? void 0 : spec.label) === null || _a === void 0 ? void 0 : _a.support3d) {
|
|
65707
66045
|
params3d.beta = -Math.PI / 3;
|
|
65708
66046
|
params3d.anchor3d = (datum) => {
|
|
65709
66047
|
var _a, _b, _c, _d;
|
|
@@ -65715,7 +66053,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65715
66053
|
};
|
|
65716
66054
|
}
|
|
65717
66055
|
if (labelMark) {
|
|
65718
|
-
this.setMarkStyle(labelMark, Object.assign({ visible: field$2(DEFAULT_LABEL_VISIBLE).bind(this), x: field$2(DEFAULT_LABEL_X).bind(this), y: field$2(DEFAULT_LABEL_Y).bind(this), text: field$2(DEFAULT_LABEL_TEXT).bind(this), fill: ((
|
|
66056
|
+
this.setMarkStyle(labelMark, Object.assign({ visible: field$2(DEFAULT_LABEL_VISIBLE).bind(this), x: field$2(DEFAULT_LABEL_X).bind(this), y: field$2(DEFAULT_LABEL_Y).bind(this), text: field$2(DEFAULT_LABEL_TEXT).bind(this), fill: ((_c = (_b = this._spec.label) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.fill) || this.getColorAttribute(), textAlign: field$2(DEFAULT_LABEL_ALIGN).bind(this), textBaseline: ((_d = this._spec.label) === null || _d === void 0 ? void 0 : _d.position) === 'inside' ? 'middle' : 'top', angle: (datum) => {
|
|
65719
66057
|
var _a;
|
|
65720
66058
|
const angle = datum[ARC_MIDDLE_ANGLE];
|
|
65721
66059
|
return ((_a = this._spec.label) === null || _a === void 0 ? void 0 : _a.position) === 'inside' ? radianToDegree(angle) : 0;
|
|
@@ -65724,7 +66062,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65724
66062
|
}
|
|
65725
66063
|
const labelLineMark = this._labelLineMark;
|
|
65726
66064
|
if (labelLineMark) {
|
|
65727
|
-
this.setMarkStyle(labelLineMark, Object.assign(Object.assign(Object.assign({ visible: field$2(DEFAULT_LABEL_VISIBLE).bind(this), stroke: ((
|
|
66065
|
+
this.setMarkStyle(labelLineMark, Object.assign(Object.assign(Object.assign({ visible: field$2(DEFAULT_LABEL_VISIBLE).bind(this), stroke: ((_g = (_f = (_e = this._spec.label) === null || _e === void 0 ? void 0 : _e.line) === null || _f === void 0 ? void 0 : _f.style) === null || _g === void 0 ? void 0 : _g.stroke) || this.getColorAttribute(), lineWidth: 1 }, this.generateLinePath('normal')), params3d), { anchor3d: () => {
|
|
65728
66066
|
var _a, _b, _c, _d;
|
|
65729
66067
|
return [
|
|
65730
66068
|
(_b = (_a = this._center) === null || _a === void 0 ? void 0 : _a.x) !== null && _b !== void 0 ? _b : this._region.getLayoutRect().width / 2,
|
|
@@ -65895,7 +66233,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65895
66233
|
return angleBandWidth;
|
|
65896
66234
|
}
|
|
65897
66235
|
initRoseMarkStyle() {
|
|
65898
|
-
var _a;
|
|
65899
66236
|
const roseMark = this._roseMark;
|
|
65900
66237
|
if (roseMark) {
|
|
65901
66238
|
this.setMarkStyle(roseMark, {
|
|
@@ -65920,9 +66257,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
65920
66257
|
}
|
|
65921
66258
|
});
|
|
65922
66259
|
this._trigger.registerMark(roseMark);
|
|
65923
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(roseMark);
|
|
65924
66260
|
}
|
|
65925
66261
|
}
|
|
66262
|
+
initTooltip() {
|
|
66263
|
+
super.initTooltip();
|
|
66264
|
+
this._roseMark && this._tooltipHelper.activeTriggerSet.mark.add(this._roseMark);
|
|
66265
|
+
}
|
|
65926
66266
|
initLabelMarkStyle(textMark) {
|
|
65927
66267
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
65928
66268
|
if (!textMark) {
|
|
@@ -66275,7 +66615,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66275
66615
|
});
|
|
66276
66616
|
}
|
|
66277
66617
|
initAreaMarkStyle() {
|
|
66278
|
-
var _a;
|
|
66279
66618
|
const areaMark = this._areaMark;
|
|
66280
66619
|
if (areaMark) {
|
|
66281
66620
|
this.setMarkStyle(areaMark, {
|
|
@@ -66308,9 +66647,14 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66308
66647
|
this.encodeDefined(areaMark, 'defined');
|
|
66309
66648
|
});
|
|
66310
66649
|
this._trigger.registerMark(areaMark);
|
|
66311
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.dimension.add(areaMark);
|
|
66312
66650
|
}
|
|
66313
66651
|
}
|
|
66652
|
+
initTooltip() {
|
|
66653
|
+
super.initTooltip();
|
|
66654
|
+
this._lineMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._lineMark);
|
|
66655
|
+
this._symbolMark && this._tooltipHelper.activeTriggerSet.mark.add(this._symbolMark);
|
|
66656
|
+
this._areaMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._areaMark);
|
|
66657
|
+
}
|
|
66314
66658
|
initAnimation() {
|
|
66315
66659
|
var _a, _b, _c, _d;
|
|
66316
66660
|
const animationParams = {
|
|
@@ -66619,7 +66963,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66619
66963
|
});
|
|
66620
66964
|
}
|
|
66621
66965
|
initMarkStyle() {
|
|
66622
|
-
var _a, _b, _c, _d
|
|
66966
|
+
var _a, _b, _c, _d;
|
|
66623
66967
|
const clipMark = this._clipMark;
|
|
66624
66968
|
if (clipMark) {
|
|
66625
66969
|
this.setMarkStyle(clipMark, {
|
|
@@ -66650,11 +66994,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66650
66994
|
y1: this.dataToPositionYTo.bind(this)
|
|
66651
66995
|
}, 'normal', AttributeLevel.Series);
|
|
66652
66996
|
this._trigger.registerMark(linkMark);
|
|
66653
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(linkMark);
|
|
66654
66997
|
}
|
|
66655
66998
|
const arrowMark = this._arrowMark;
|
|
66656
66999
|
if (arrowMark) {
|
|
66657
|
-
const arrowSize = (
|
|
67000
|
+
const arrowSize = (_d = (_c = (_b = (_a = this._theme) === null || _a === void 0 ? void 0 : _a.arrow) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.size) !== null && _d !== void 0 ? _d : 10;
|
|
66658
67001
|
this.setMarkStyle(arrowMark, {
|
|
66659
67002
|
x: this.dataToPositionXTo.bind(this),
|
|
66660
67003
|
y: (datum) => this.dataToPositionArrowYTo(datum, arrowSize),
|
|
@@ -66666,7 +67009,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66666
67009
|
}
|
|
66667
67010
|
}, 'normal', AttributeLevel.Series);
|
|
66668
67011
|
this._trigger.registerMark(arrowMark);
|
|
66669
|
-
(_f = this._tooltipHelper) === null || _f === void 0 ? void 0 : _f.activeTriggerSet.mark.add(arrowMark);
|
|
66670
67012
|
}
|
|
66671
67013
|
}
|
|
66672
67014
|
afterInitMark() {
|
|
@@ -66760,6 +67102,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
66760
67102
|
}
|
|
66761
67103
|
initTooltip() {
|
|
66762
67104
|
this._tooltipHelper = new LinkSeriesTooltipHelper(this);
|
|
67105
|
+
this._linkMark && this._tooltipHelper.activeTriggerSet.mark.add(this._linkMark);
|
|
67106
|
+
this._arrowMark && this._tooltipHelper.activeTriggerSet.mark.add(this._arrowMark);
|
|
66763
67107
|
}
|
|
66764
67108
|
onMarkTreePositionUpdate(marks) {
|
|
66765
67109
|
marks.forEach(m => {
|
|
@@ -67023,7 +67367,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67023
67367
|
});
|
|
67024
67368
|
}
|
|
67025
67369
|
initMarkStyle() {
|
|
67026
|
-
var _a;
|
|
67027
67370
|
const clipMark = this._clipMark;
|
|
67028
67371
|
if (clipMark) {
|
|
67029
67372
|
this.setMarkStyle(clipMark, {
|
|
@@ -67074,7 +67417,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67074
67417
|
fillOpacity: this.dataToOpacity.bind(this)
|
|
67075
67418
|
}, 'normal', AttributeLevel.Series);
|
|
67076
67419
|
this._trigger.registerMark(dotMark);
|
|
67077
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(dotMark);
|
|
67078
67420
|
}
|
|
67079
67421
|
const titleMark = this._titleMark;
|
|
67080
67422
|
if (titleMark) {
|
|
@@ -67196,6 +67538,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67196
67538
|
}
|
|
67197
67539
|
initTooltip() {
|
|
67198
67540
|
this._tooltipHelper = new DotSeriesTooltipHelper(this);
|
|
67541
|
+
this._dotMark && this._tooltipHelper.activeTriggerSet.mark.add(this._dotMark);
|
|
67199
67542
|
}
|
|
67200
67543
|
onEvaluateEnd(ctx) {
|
|
67201
67544
|
super.onEvaluateEnd(ctx);
|
|
@@ -67375,7 +67718,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67375
67718
|
if (dataLength) {
|
|
67376
67719
|
ratio = ((seriesSpec === null || seriesSpec === void 0 ? void 0 : seriesSpec.height) || defaultSeriesRowHeight) / (dataLength * 30);
|
|
67377
67720
|
}
|
|
67378
|
-
scrollBar.push(Object.assign({ orient: 'right', visible: seriesSpec.type === SeriesTypeEnum.dot && ratio < 1, id: `scrollBarRightRow${rowNum}`, start: 0, end: Math.min(ratio, 1),
|
|
67721
|
+
scrollBar.push(Object.assign({ orient: 'right', visible: seriesSpec.type === SeriesTypeEnum.dot && ratio < 1, id: `scrollBarRightRow${rowNum}`, start: 0, end: Math.min(ratio, 1), filterMode: IFilterMode.axis, regionIndex: region.length - 1, axisId: `axesLeftRow${rowNum}` }, array(spec === null || spec === void 0 ? void 0 : spec.scrollBar)[0]));
|
|
67379
67722
|
}
|
|
67380
67723
|
seriesSpec.regionIndex = region.length - 1;
|
|
67381
67724
|
rowNum++;
|
|
@@ -67896,7 +68239,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67896
68239
|
return this._progressMark;
|
|
67897
68240
|
}
|
|
67898
68241
|
_initProgressMarkStyle() {
|
|
67899
|
-
var _a
|
|
68242
|
+
var _a;
|
|
67900
68243
|
const progressMark = this._progressMark;
|
|
67901
68244
|
if (progressMark) {
|
|
67902
68245
|
this.setMarkStyle(progressMark, {
|
|
@@ -67914,9 +68257,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
67914
68257
|
forceShowCap: true
|
|
67915
68258
|
}, 'normal', AttributeLevel.Series);
|
|
67916
68259
|
this._trigger.registerMark(progressMark);
|
|
67917
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(progressMark);
|
|
67918
68260
|
}
|
|
67919
68261
|
}
|
|
68262
|
+
initTooltip() {
|
|
68263
|
+
super.initTooltip();
|
|
68264
|
+
this._progressMark && this._tooltipHelper.activeTriggerSet.mark.add(this._progressMark);
|
|
68265
|
+
}
|
|
67920
68266
|
_initTrackMark() {
|
|
67921
68267
|
this._trackMark = this._createMark(CircularProgressSeries.mark.track, {
|
|
67922
68268
|
parent: this._arcGroupMark
|
|
@@ -68033,7 +68379,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68033
68379
|
initGroups() {
|
|
68034
68380
|
}
|
|
68035
68381
|
initPointerMarkStyle() {
|
|
68036
|
-
var _a;
|
|
68037
68382
|
const pointerMark = this._pointerMark;
|
|
68038
68383
|
const pointerSpec = this._spec.pointer;
|
|
68039
68384
|
if (pointerMark) {
|
|
@@ -68072,9 +68417,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68072
68417
|
});
|
|
68073
68418
|
}
|
|
68074
68419
|
this._trigger.registerMark(pointerMark);
|
|
68075
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(pointerMark);
|
|
68076
68420
|
}
|
|
68077
68421
|
}
|
|
68422
|
+
initTooltip() {
|
|
68423
|
+
super.initTooltip();
|
|
68424
|
+
this._pointerMark && this._tooltipHelper.activeTriggerSet.mark.add(this._pointerMark);
|
|
68425
|
+
}
|
|
68078
68426
|
_getPointerWidth() {
|
|
68079
68427
|
return this._spec.pointer.width * this._computeLayoutRadius();
|
|
68080
68428
|
}
|
|
@@ -68211,7 +68559,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68211
68559
|
this.initSegmentMarkStyle();
|
|
68212
68560
|
}
|
|
68213
68561
|
initSegmentMarkStyle() {
|
|
68214
|
-
var _a
|
|
68562
|
+
var _a;
|
|
68215
68563
|
const segmentMark = this._segmentMark;
|
|
68216
68564
|
if (segmentMark) {
|
|
68217
68565
|
this.setMarkStyle(segmentMark, {
|
|
@@ -68230,9 +68578,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68230
68578
|
});
|
|
68231
68579
|
segmentMark.setLabelSpec(this._preprocessLabelSpec());
|
|
68232
68580
|
this._trigger.registerMark(segmentMark);
|
|
68233
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(segmentMark);
|
|
68234
68581
|
}
|
|
68235
68582
|
}
|
|
68583
|
+
initTooltip() {
|
|
68584
|
+
super.initTooltip();
|
|
68585
|
+
this._segmentMark && this._tooltipHelper.activeTriggerSet.mark.add(this._segmentMark);
|
|
68586
|
+
}
|
|
68236
68587
|
initTrackMarkStyle() {
|
|
68237
68588
|
const trackMark = this._trackMark;
|
|
68238
68589
|
if (trackMark) {
|
|
@@ -68507,7 +68858,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68507
68858
|
}
|
|
68508
68859
|
}
|
|
68509
68860
|
initMarkStyle() {
|
|
68510
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l
|
|
68861
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
68511
68862
|
const wordMark = this._wordMark;
|
|
68512
68863
|
const fillingWordMark = this._fillingWordMark;
|
|
68513
68864
|
const textField = ((_a = this._spec.word) === null || _a === void 0 ? void 0 : _a.formatMethod) ? WORD_CLOUD_TEXT : this._nameField;
|
|
@@ -68550,9 +68901,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
68550
68901
|
}, 'normal', AttributeLevel.User_Mark);
|
|
68551
68902
|
}
|
|
68552
68903
|
this._trigger.registerMark(wordMark);
|
|
68553
|
-
(_m = this._tooltipHelper) === null || _m === void 0 ? void 0 : _m.activeTriggerSet.mark.add(wordMark);
|
|
68554
68904
|
this._trigger.registerMark(fillingWordMark);
|
|
68555
|
-
|
|
68905
|
+
}
|
|
68906
|
+
initTooltip() {
|
|
68907
|
+
super.initTooltip();
|
|
68908
|
+
this._wordMark && this._tooltipHelper.activeTriggerSet.mark.add(this._wordMark);
|
|
68909
|
+
this._fillingWordMark && this._tooltipHelper.activeTriggerSet.mark.add(this._fillingWordMark);
|
|
68556
68910
|
}
|
|
68557
68911
|
initAnimation() {
|
|
68558
68912
|
[this._wordMark, this._fillingWordMark].forEach(mark => {
|
|
@@ -70930,7 +71284,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
70930
71284
|
}
|
|
70931
71285
|
}
|
|
70932
71286
|
initMarkStyle() {
|
|
70933
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
71287
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
70934
71288
|
const wordMark = this._wordMark;
|
|
70935
71289
|
const fillingWordMark = this._fillingWordMark;
|
|
70936
71290
|
if (wordMark) {
|
|
@@ -70974,9 +71328,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
70974
71328
|
}, 'normal', AttributeLevel.User_Mark);
|
|
70975
71329
|
}
|
|
70976
71330
|
this._trigger.registerMark(wordMark);
|
|
70977
|
-
(_l = this._tooltipHelper) === null || _l === void 0 ? void 0 : _l.activeTriggerSet.mark.add(wordMark);
|
|
70978
71331
|
this._trigger.registerMark(fillingWordMark);
|
|
70979
|
-
(_m = this._tooltipHelper) === null || _m === void 0 ? void 0 : _m.activeTriggerSet.mark.add(fillingWordMark);
|
|
70980
71332
|
}
|
|
70981
71333
|
initAnimation() {
|
|
70982
71334
|
var _a, _b;
|
|
@@ -71263,6 +71615,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
71263
71615
|
}
|
|
71264
71616
|
initTooltip() {
|
|
71265
71617
|
this._tooltipHelper = new FunnelSeriesTooltipHelper(this);
|
|
71618
|
+
this._funnelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._funnelMark);
|
|
71619
|
+
this._funnelTransformMark && this._tooltipHelper.activeTriggerSet.mark.add(this._funnelTransformMark);
|
|
71266
71620
|
}
|
|
71267
71621
|
getDimensionField() {
|
|
71268
71622
|
return this._seriesField ? [this._seriesField] : [];
|
|
@@ -71274,7 +71628,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
71274
71628
|
return null;
|
|
71275
71629
|
}
|
|
71276
71630
|
initMarkStyle() {
|
|
71277
|
-
var _a, _b;
|
|
71278
71631
|
const funnelMark = this._funnelMark;
|
|
71279
71632
|
if (funnelMark) {
|
|
71280
71633
|
this.setMarkStyle(funnelMark, {
|
|
@@ -71283,13 +71636,11 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
71283
71636
|
fill: this.getColorAttribute()
|
|
71284
71637
|
}, 'normal', AttributeLevel.Series);
|
|
71285
71638
|
this._trigger.registerMark(funnelMark);
|
|
71286
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(funnelMark);
|
|
71287
71639
|
}
|
|
71288
71640
|
const funnelTransformMark = this._funnelTransformMark;
|
|
71289
71641
|
if (funnelTransformMark) {
|
|
71290
71642
|
this.setMarkStyle(funnelTransformMark, { points: (datum) => this.getPoints(datum) }, 'normal', AttributeLevel.Series);
|
|
71291
71643
|
this._trigger.registerMark(funnelTransformMark);
|
|
71292
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(funnelTransformMark);
|
|
71293
71644
|
}
|
|
71294
71645
|
const outerLabelMark = this._funnelOuterLabelMark.label;
|
|
71295
71646
|
if (outerLabelMark) {
|
|
@@ -71992,7 +72343,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
71992
72343
|
return this._progressMark;
|
|
71993
72344
|
}
|
|
71994
72345
|
_initProgressMarkStyle() {
|
|
71995
|
-
var _a, _b, _c, _d, _e, _f, _g, _h
|
|
72346
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
71996
72347
|
const progressMark = this._progressMark;
|
|
71997
72348
|
if (progressMark) {
|
|
71998
72349
|
if (this._spec.direction === 'vertical') {
|
|
@@ -72034,7 +72385,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72034
72385
|
}, 'normal', AttributeLevel.Series);
|
|
72035
72386
|
}
|
|
72036
72387
|
this._trigger.registerMark(progressMark);
|
|
72037
|
-
(_j = this._tooltipHelper) === null || _j === void 0 ? void 0 : _j.activeTriggerSet.mark.add(progressMark);
|
|
72038
72388
|
}
|
|
72039
72389
|
}
|
|
72040
72390
|
_initTrackMark() {
|
|
@@ -72044,7 +72394,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72044
72394
|
return this._trackMark;
|
|
72045
72395
|
}
|
|
72046
72396
|
_initTrackMarkStyle() {
|
|
72047
|
-
var _a;
|
|
72048
72397
|
const trackMark = this._trackMark;
|
|
72049
72398
|
if (trackMark) {
|
|
72050
72399
|
if (this._spec.direction === 'vertical') {
|
|
@@ -72074,7 +72423,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72074
72423
|
}, 'normal', AttributeLevel.Series);
|
|
72075
72424
|
}
|
|
72076
72425
|
this._trigger.registerMark(trackMark);
|
|
72077
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(trackMark);
|
|
72078
72426
|
}
|
|
72079
72427
|
}
|
|
72080
72428
|
_initProgressGroupMark() {
|
|
@@ -72139,6 +72487,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72139
72487
|
}
|
|
72140
72488
|
initTooltip() {
|
|
72141
72489
|
this._tooltipHelper = new LinearProgressSeriesTooltipHelper(this);
|
|
72490
|
+
this._progressMark && this._tooltipHelper.activeTriggerSet.mark.add(this._progressMark);
|
|
72491
|
+
this._trackMark && this._tooltipHelper.activeTriggerSet.mark.add(this._trackMark);
|
|
72142
72492
|
}
|
|
72143
72493
|
getActiveMarks() {
|
|
72144
72494
|
return [this._progressMark];
|
|
@@ -72502,7 +72852,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72502
72852
|
}
|
|
72503
72853
|
}
|
|
72504
72854
|
initMarkStyle() {
|
|
72505
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k
|
|
72855
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
72506
72856
|
super.initMarkStyle();
|
|
72507
72857
|
const minLabelMark = this._minLabelMark;
|
|
72508
72858
|
const minLabelSpec = (_a = this._spec.label) === null || _a === void 0 ? void 0 : _a.minLabel;
|
|
@@ -72530,13 +72880,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72530
72880
|
: this._rectMark.getAttribute('y', datum) +
|
|
72531
72881
|
this._rectMark.getAttribute('height', datum);
|
|
72532
72882
|
}, () => this._direction);
|
|
72533
|
-
(_f = this._tooltipHelper) === null || _f === void 0 ? void 0 : _f.ignoreTriggerSet.mark.add(minLabelMark);
|
|
72534
72883
|
}
|
|
72535
72884
|
const maxLabelMark = this._maxLabelMark;
|
|
72536
|
-
const maxLabelSpec = (
|
|
72885
|
+
const maxLabelSpec = (_f = this._spec.label) === null || _f === void 0 ? void 0 : _f.maxLabel;
|
|
72537
72886
|
if (maxLabelMark) {
|
|
72538
72887
|
this.setMarkStyle(maxLabelMark, {
|
|
72539
|
-
fill: (
|
|
72888
|
+
fill: (_h = (_g = maxLabelSpec === null || maxLabelSpec === void 0 ? void 0 : maxLabelSpec.style) === null || _g === void 0 ? void 0 : _g.fill) !== null && _h !== void 0 ? _h : this.getColorAttribute(),
|
|
72540
72889
|
text: (datum) => {
|
|
72541
72890
|
const max = this._spec.direction === Direction.horizontal ? datum[this._spec.xField[1]] : datum[this._spec.yField[1]];
|
|
72542
72891
|
if (maxLabelSpec === null || maxLabelSpec === void 0 ? void 0 : maxLabelSpec.formatMethod) {
|
|
@@ -72545,8 +72894,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72545
72894
|
return max;
|
|
72546
72895
|
}
|
|
72547
72896
|
});
|
|
72548
|
-
const position = (
|
|
72549
|
-
const offset = (
|
|
72897
|
+
const position = (_j = maxLabelSpec === null || maxLabelSpec === void 0 ? void 0 : maxLabelSpec.position) !== null && _j !== void 0 ? _j : 'start';
|
|
72898
|
+
const offset = (_k = maxLabelSpec === null || maxLabelSpec === void 0 ? void 0 : maxLabelSpec.offset) !== null && _k !== void 0 ? _k : (this._direction === 'vertical' ? -20 : -25);
|
|
72550
72899
|
setRectLabelPos(this, maxLabelMark, position, offset, (datum) => this._rectMark.getAttribute('x', datum), (datum) => {
|
|
72551
72900
|
return this._direction === 'vertical'
|
|
72552
72901
|
? this._rectMark.getAttribute('x', datum) +
|
|
@@ -72558,11 +72907,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72558
72907
|
: this._rectMark.getAttribute('y', datum) +
|
|
72559
72908
|
this._rectMark.getAttribute('height', datum);
|
|
72560
72909
|
}, () => this._direction);
|
|
72561
|
-
(_m = this._tooltipHelper) === null || _m === void 0 ? void 0 : _m.ignoreTriggerSet.mark.add(maxLabelMark);
|
|
72562
72910
|
}
|
|
72563
72911
|
}
|
|
72564
72912
|
initLabelMarkStyle(labelMark) {
|
|
72565
|
-
var _a;
|
|
72566
72913
|
if (!labelMark) {
|
|
72567
72914
|
return;
|
|
72568
72915
|
}
|
|
@@ -72582,7 +72929,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72582
72929
|
},
|
|
72583
72930
|
z: this._fieldZ ? this.dataToPositionZ.bind(this) : null
|
|
72584
72931
|
});
|
|
72585
|
-
|
|
72932
|
+
this._labelMark = labelMark;
|
|
72586
72933
|
}
|
|
72587
72934
|
initBandRectMarkStyle() {
|
|
72588
72935
|
var _a, _b, _c, _d;
|
|
@@ -72635,6 +72982,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
72635
72982
|
}
|
|
72636
72983
|
initTooltip() {
|
|
72637
72984
|
this._tooltipHelper = new RangeColumnSeriesTooltipHelper(this);
|
|
72985
|
+
this._minLabelMark && this._tooltipHelper.ignoreTriggerSet.mark.add(this._minLabelMark);
|
|
72986
|
+
this._maxLabelMark && this._tooltipHelper.ignoreTriggerSet.mark.add(this._maxLabelMark);
|
|
72987
|
+
this._labelMark && this._tooltipHelper.ignoreTriggerSet.mark.add(this._labelMark);
|
|
72638
72988
|
}
|
|
72639
72989
|
}
|
|
72640
72990
|
RangeColumnSeries.type = SeriesTypeEnum.rangeColumn;
|
|
@@ -73822,7 +74172,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
73822
74172
|
this._initLabelMarkStyle();
|
|
73823
74173
|
}
|
|
73824
74174
|
_initArcMark() {
|
|
73825
|
-
var _a;
|
|
73826
74175
|
if (this._sunburst.visible === false) {
|
|
73827
74176
|
return;
|
|
73828
74177
|
}
|
|
@@ -73831,7 +74180,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
73831
74180
|
});
|
|
73832
74181
|
this._sunburstMark = sunburstMark;
|
|
73833
74182
|
this._trigger.registerMark(this._sunburstMark);
|
|
73834
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(this._sunburstMark);
|
|
73835
74183
|
}
|
|
73836
74184
|
_initArcMarkStyle() {
|
|
73837
74185
|
if (isNil$1(this._sunburstMark)) {
|
|
@@ -73848,7 +74196,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
73848
74196
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
73849
74197
|
}
|
|
73850
74198
|
_initLabelMark() {
|
|
73851
|
-
var _a;
|
|
73852
74199
|
if (this._label.visible !== true) {
|
|
73853
74200
|
return;
|
|
73854
74201
|
}
|
|
@@ -73857,7 +74204,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
73857
74204
|
});
|
|
73858
74205
|
this._labelMark = labelMark;
|
|
73859
74206
|
this._trigger.registerMark(labelMark);
|
|
73860
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(labelMark);
|
|
73861
74207
|
}
|
|
73862
74208
|
_initLabelMarkStyle() {
|
|
73863
74209
|
if (isNil$1(this._labelMark)) {
|
|
@@ -73884,6 +74230,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
73884
74230
|
}
|
|
73885
74231
|
initTooltip() {
|
|
73886
74232
|
this._tooltipHelper = new SunburstTooltipHelper(this);
|
|
74233
|
+
this._sunburstMark && this._tooltipHelper.activeTriggerSet.mark.add(this._sunburstMark);
|
|
74234
|
+
this._labelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._labelMark);
|
|
73887
74235
|
}
|
|
73888
74236
|
initAnimation() {
|
|
73889
74237
|
var _a, _b;
|
|
@@ -74157,7 +74505,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74157
74505
|
this._initLabelMarkStyle();
|
|
74158
74506
|
}
|
|
74159
74507
|
_initCirclePackingMark() {
|
|
74160
|
-
var _a
|
|
74508
|
+
var _a;
|
|
74161
74509
|
if (((_a = this._circlePacking) === null || _a === void 0 ? void 0 : _a.visible) === false) {
|
|
74162
74510
|
return;
|
|
74163
74511
|
}
|
|
@@ -74166,7 +74514,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74166
74514
|
});
|
|
74167
74515
|
this._circlePackingMark = circlePacking;
|
|
74168
74516
|
this._trigger.registerMark(circlePacking);
|
|
74169
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(circlePacking);
|
|
74170
74517
|
}
|
|
74171
74518
|
_initCirclePackingMarkStyle() {
|
|
74172
74519
|
if (isNil$1(this._circlePackingMark)) {
|
|
@@ -74184,7 +74531,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74184
74531
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
74185
74532
|
}
|
|
74186
74533
|
_initLabelMark() {
|
|
74187
|
-
var _a
|
|
74534
|
+
var _a;
|
|
74188
74535
|
if (((_a = this._label) === null || _a === void 0 ? void 0 : _a.visible) === false) {
|
|
74189
74536
|
return;
|
|
74190
74537
|
}
|
|
@@ -74193,7 +74540,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74193
74540
|
});
|
|
74194
74541
|
this._labelMark = labelMark;
|
|
74195
74542
|
this._trigger.registerMark(labelMark);
|
|
74196
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(labelMark);
|
|
74197
74543
|
}
|
|
74198
74544
|
_initLabelMarkStyle() {
|
|
74199
74545
|
if (isNil$1(this._labelMark)) {
|
|
@@ -74231,6 +74577,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74231
74577
|
}
|
|
74232
74578
|
initTooltip() {
|
|
74233
74579
|
this._tooltipHelper = new CirclePackingTooltipHelper(this);
|
|
74580
|
+
this._tooltipHelper.updateTooltipSpec();
|
|
74581
|
+
this._circlePackingMark && this._tooltipHelper.activeTriggerSet.mark.add(this._circlePackingMark);
|
|
74582
|
+
this._labelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._labelMark);
|
|
74234
74583
|
}
|
|
74235
74584
|
initAnimation() {
|
|
74236
74585
|
var _a, _b;
|
|
@@ -74539,7 +74888,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74539
74888
|
]);
|
|
74540
74889
|
}
|
|
74541
74890
|
initMark() {
|
|
74542
|
-
var _a, _b
|
|
74891
|
+
var _a, _b;
|
|
74543
74892
|
const nonLeafMark = this._createMark(TreemapSeries.mark.nonLeaf, { isSeriesMark: true });
|
|
74544
74893
|
if (nonLeafMark) {
|
|
74545
74894
|
nonLeafMark.setTransform([
|
|
@@ -74552,7 +74901,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74552
74901
|
]);
|
|
74553
74902
|
this._trigger.registerMark(nonLeafMark);
|
|
74554
74903
|
this._nonLeafMark = nonLeafMark;
|
|
74555
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(nonLeafMark);
|
|
74556
74904
|
}
|
|
74557
74905
|
const leafMark = this._createMark(TreemapSeries.mark.leaf, { isSeriesMark: true });
|
|
74558
74906
|
if (leafMark) {
|
|
@@ -74566,9 +74914,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74566
74914
|
]);
|
|
74567
74915
|
this._leafMark = leafMark;
|
|
74568
74916
|
this._trigger.registerMark(leafMark);
|
|
74569
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(leafMark);
|
|
74570
74917
|
}
|
|
74571
|
-
if ((
|
|
74918
|
+
if ((_a = this._spec.label) === null || _a === void 0 ? void 0 : _a.visible) {
|
|
74572
74919
|
const textMark = this._createMark(TreemapSeries.mark.label, {
|
|
74573
74920
|
skipBeforeLayouted: false
|
|
74574
74921
|
});
|
|
@@ -74583,10 +74930,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74583
74930
|
]);
|
|
74584
74931
|
this._labelMark = textMark;
|
|
74585
74932
|
this._trigger.registerMark(textMark);
|
|
74586
|
-
(_d = this._tooltipHelper) === null || _d === void 0 ? void 0 : _d.activeTriggerSet.mark.add(textMark);
|
|
74587
74933
|
}
|
|
74588
74934
|
}
|
|
74589
|
-
if ((
|
|
74935
|
+
if ((_b = this._spec.nonLeafLabel) === null || _b === void 0 ? void 0 : _b.visible) {
|
|
74590
74936
|
const textMark = this._createMark(TreemapSeries.mark.nonLeafLabel);
|
|
74591
74937
|
if (textMark) {
|
|
74592
74938
|
textMark.setTransform([
|
|
@@ -74599,7 +74945,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74599
74945
|
]);
|
|
74600
74946
|
this._nonLeafLabelMark = textMark;
|
|
74601
74947
|
this._trigger.registerMark(textMark);
|
|
74602
|
-
(_f = this._tooltipHelper) === null || _f === void 0 ? void 0 : _f.activeTriggerSet.mark.add(textMark);
|
|
74603
74948
|
}
|
|
74604
74949
|
}
|
|
74605
74950
|
}
|
|
@@ -74716,6 +75061,10 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
74716
75061
|
}
|
|
74717
75062
|
initTooltip() {
|
|
74718
75063
|
this._tooltipHelper = new TreemapTooltipHelper(this);
|
|
75064
|
+
this._nonLeafLabelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._nonLeafMark);
|
|
75065
|
+
this._leafMark && this._tooltipHelper.activeTriggerSet.mark.add(this._leafMark);
|
|
75066
|
+
this._labelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._labelMark);
|
|
75067
|
+
this._nonLeafLabelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._nonLeafLabelMark);
|
|
74719
75068
|
}
|
|
74720
75069
|
_shouldFilterElement(datum, nodeType) {
|
|
74721
75070
|
const isLeaf = datum.isLeaf;
|
|
@@ -75518,7 +75867,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
75518
75867
|
transformSpec(spec) {
|
|
75519
75868
|
super.transformSpec(spec);
|
|
75520
75869
|
if (spec.legends) {
|
|
75521
|
-
array(spec.legends).forEach(l => {
|
|
75870
|
+
array(spec.legends).forEach((l) => {
|
|
75522
75871
|
l.select = false;
|
|
75523
75872
|
l.hover = false;
|
|
75524
75873
|
l.filter = false;
|
|
@@ -75825,7 +76174,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
75825
76174
|
});
|
|
75826
76175
|
}
|
|
75827
76176
|
initMarkStyle() {
|
|
75828
|
-
var _a, _b, _c, _d, _e
|
|
76177
|
+
var _a, _b, _c, _d, _e;
|
|
75829
76178
|
const boxPlotMark = this._boxPlotMark;
|
|
75830
76179
|
if (boxPlotMark) {
|
|
75831
76180
|
const commonBoxplotStyles = {
|
|
@@ -75840,17 +76189,15 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
75840
76189
|
? Object.assign(Object.assign({ x: this.dataToPositionX.bind(this) }, commonBoxplotStyles), { boxWidth: () => { var _a; return (_a = this._boxWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, ruleWidth: () => { var _a; return (_a = this._shaftWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, q1q3Width: () => { var _a; return (_a = this._boxWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, minMaxWidth: () => { var _a; return (_a = this._shaftWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); } }) : Object.assign(Object.assign({ y: this.dataToPositionY.bind(this) }, commonBoxplotStyles), { boxHeight: () => { var _a; return (_a = this._boxWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, ruleHeight: () => { var _a; return (_a = this._shaftWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, q1q3Height: () => { var _a; return (_a = this._boxWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); }, minMaxHeight: () => { var _a; return (_a = this._shaftWidth) !== null && _a !== void 0 ? _a : this._getMarkWidth(); } });
|
|
75841
76190
|
this.setMarkStyle(boxPlotMark, boxPlotMarkStyles, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
75842
76191
|
this._trigger.registerMark(boxPlotMark);
|
|
75843
|
-
(_c = this._tooltipHelper) === null || _c === void 0 ? void 0 : _c.activeTriggerSet.mark.add(boxPlotMark);
|
|
75844
76192
|
}
|
|
75845
76193
|
const outlierMark = this._outlierMark;
|
|
75846
76194
|
if (outlierMark) {
|
|
75847
76195
|
this.setMarkStyle(outlierMark, {
|
|
75848
|
-
fill: (
|
|
75849
|
-
size: isNumber$2((
|
|
76196
|
+
fill: (_d = (_c = this._outliersStyle) === null || _c === void 0 ? void 0 : _c.fill) !== null && _d !== void 0 ? _d : this.getColorAttribute(),
|
|
76197
|
+
size: isNumber$2((_e = this._outliersStyle) === null || _e === void 0 ? void 0 : _e.size) ? this._outliersStyle.size : DEFAULT_OUTLIER_SIZE,
|
|
75850
76198
|
symbolType: 'circle'
|
|
75851
76199
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
75852
76200
|
this._trigger.registerMark(outlierMark);
|
|
75853
|
-
(_g = this._tooltipHelper) === null || _g === void 0 ? void 0 : _g.activeTriggerSet.mark.add(outlierMark);
|
|
75854
76201
|
}
|
|
75855
76202
|
}
|
|
75856
76203
|
initBoxPlotMarkStyle() {
|
|
@@ -75946,7 +76293,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
75946
76293
|
this._autoBoxWidth = null;
|
|
75947
76294
|
}
|
|
75948
76295
|
_initAnimationSpec(config = {}) {
|
|
75949
|
-
const newConfig =
|
|
76296
|
+
const newConfig = merge$1({}, config);
|
|
75950
76297
|
['appear', 'enter', 'update', 'exit', 'disappear'].forEach(state => {
|
|
75951
76298
|
if (newConfig[state] && newConfig[state].type === 'scaleIn') {
|
|
75952
76299
|
newConfig[state].type = this._shaftShape === 'line' ? 'boxplotScaleIn' : 'barBoxplotScaleIn';
|
|
@@ -75986,6 +76333,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
75986
76333
|
}
|
|
75987
76334
|
initTooltip() {
|
|
75988
76335
|
this._tooltipHelper = new BoxPlotSeriesTooltipHelper(this);
|
|
76336
|
+
this._boxPlotMark && this._tooltipHelper.activeTriggerSet.mark.add(this._boxPlotMark);
|
|
76337
|
+
this._outlierMark && this._tooltipHelper.activeTriggerSet.mark.add(this._outlierMark);
|
|
75989
76338
|
}
|
|
75990
76339
|
getStatisticFields() {
|
|
75991
76340
|
const fields = super.getStatisticFields();
|
|
@@ -77458,7 +77807,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77458
77807
|
this._initLabelMarkStyle();
|
|
77459
77808
|
}
|
|
77460
77809
|
_initNodeMarkStyle() {
|
|
77461
|
-
var _a;
|
|
77462
77810
|
const nodeMark = this._nodeMark;
|
|
77463
77811
|
if (!nodeMark) {
|
|
77464
77812
|
return;
|
|
@@ -77476,10 +77824,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77476
77824
|
}
|
|
77477
77825
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Mark);
|
|
77478
77826
|
this._trigger.registerMark(nodeMark);
|
|
77479
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(nodeMark);
|
|
77480
77827
|
}
|
|
77481
77828
|
_initLinkMarkStyle() {
|
|
77482
|
-
var _a
|
|
77829
|
+
var _a;
|
|
77483
77830
|
const linkMark = this._linkMark;
|
|
77484
77831
|
if (!linkMark) {
|
|
77485
77832
|
return;
|
|
@@ -77500,10 +77847,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77500
77847
|
direction: (_a = this._spec.direction) !== null && _a !== void 0 ? _a : 'horizontal'
|
|
77501
77848
|
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
77502
77849
|
this._trigger.registerMark(linkMark);
|
|
77503
|
-
(_b = this._tooltipHelper) === null || _b === void 0 ? void 0 : _b.activeTriggerSet.mark.add(linkMark);
|
|
77504
77850
|
}
|
|
77505
77851
|
_initLabelMarkStyle() {
|
|
77506
|
-
var _a;
|
|
77507
77852
|
if (!this._labelMark) {
|
|
77508
77853
|
return;
|
|
77509
77854
|
}
|
|
@@ -77655,7 +78000,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77655
78000
|
}
|
|
77656
78001
|
this._labelMark.setZIndex(this._labelLayoutZIndex);
|
|
77657
78002
|
this._trigger.registerMark(this._labelMark);
|
|
77658
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(this._labelMark);
|
|
77659
78003
|
}
|
|
77660
78004
|
_createText(datum) {
|
|
77661
78005
|
var _a;
|
|
@@ -77722,6 +78066,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77722
78066
|
}
|
|
77723
78067
|
initTooltip() {
|
|
77724
78068
|
this._tooltipHelper = new SankeySeriesTooltipHelper(this);
|
|
78069
|
+
this._nodeMark && this._tooltipHelper.activeTriggerSet.mark.add(this._nodeMark);
|
|
78070
|
+
this._linkMark && this._tooltipHelper.activeTriggerSet.mark.add(this._linkMark);
|
|
78071
|
+
this._labelMark && this._tooltipHelper.activeTriggerSet.mark.add(this._labelMark);
|
|
77725
78072
|
}
|
|
77726
78073
|
getNodeOrdinalColorScale(item) {
|
|
77727
78074
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
@@ -77997,11 +78344,11 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
77997
78344
|
curveType
|
|
77998
78345
|
}, 'normal', AttributeLevel.Built_In);
|
|
77999
78346
|
this._trigger.registerMark(areaMark);
|
|
78000
|
-
this._tooltipHelper.activeTriggerSet.dimension.add(areaMark);
|
|
78001
78347
|
}
|
|
78002
78348
|
}
|
|
78003
78349
|
initTooltip() {
|
|
78004
78350
|
this._tooltipHelper = new RangeAreaSeriesTooltipHelper(this);
|
|
78351
|
+
this._areaMark && this._tooltipHelper.activeTriggerSet.dimension.add(this._areaMark);
|
|
78005
78352
|
}
|
|
78006
78353
|
viewDataStatisticsUpdate(d) {
|
|
78007
78354
|
super.viewDataStatisticsUpdate(d);
|
|
@@ -78120,7 +78467,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
78120
78467
|
});
|
|
78121
78468
|
}
|
|
78122
78469
|
initCellMarkStyle() {
|
|
78123
|
-
var _a;
|
|
78124
78470
|
this.setMarkStyle(this._cellMark, {
|
|
78125
78471
|
x: (datum) => {
|
|
78126
78472
|
const pos = this.dataToPositionX(datum);
|
|
@@ -78136,7 +78482,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
78136
78482
|
fill: this.getColorAttribute()
|
|
78137
78483
|
}, 'normal', AttributeLevel.Series);
|
|
78138
78484
|
this._trigger.registerMark(this._cellMark);
|
|
78139
|
-
(_a = this._tooltipHelper) === null || _a === void 0 ? void 0 : _a.activeTriggerSet.mark.add(this._cellMark);
|
|
78140
78485
|
}
|
|
78141
78486
|
initCellBackgroundMarkStyle() {
|
|
78142
78487
|
var _a, _b, _c;
|
|
@@ -78186,6 +78531,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
78186
78531
|
}
|
|
78187
78532
|
initTooltip() {
|
|
78188
78533
|
this._tooltipHelper = new HeatmapSeriesTooltipHelper(this);
|
|
78534
|
+
this._cellMark && this._tooltipHelper.activeTriggerSet.mark.add(this._cellMark);
|
|
78189
78535
|
}
|
|
78190
78536
|
getDefaultShapeType() {
|
|
78191
78537
|
return 'square';
|
|
@@ -78227,6 +78573,467 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
78227
78573
|
Factory.registerChart(HeatmapChart.type, HeatmapChart);
|
|
78228
78574
|
};
|
|
78229
78575
|
|
|
78576
|
+
const correlation = (data, options) => {
|
|
78577
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
78578
|
+
if (!data || !(options === null || options === void 0 ? void 0 : options.view) || !isArray$1(data)) {
|
|
78579
|
+
return data;
|
|
78580
|
+
}
|
|
78581
|
+
const viewBox = options.view();
|
|
78582
|
+
if (viewBox.x1 - viewBox.x0 === 0 ||
|
|
78583
|
+
viewBox.y1 - viewBox.y0 === 0 ||
|
|
78584
|
+
viewBox.x1 - viewBox.x0 === -Infinity ||
|
|
78585
|
+
viewBox.x1 - viewBox.x0 === Infinity ||
|
|
78586
|
+
viewBox.y1 - viewBox.y0 === -Infinity ||
|
|
78587
|
+
viewBox.y1 - viewBox.y0 === Infinity) {
|
|
78588
|
+
return data;
|
|
78589
|
+
}
|
|
78590
|
+
const startAngle = degreeToRadian((_a = options.startAngle) !== null && _a !== void 0 ? _a : -90);
|
|
78591
|
+
const endAngle = degreeToRadian((_b = options.endAngle) !== null && _b !== void 0 ? _b : 270);
|
|
78592
|
+
const maxRadius = Math.max((viewBox.x1 - viewBox.x0) / 2, (viewBox.y1 - viewBox.y0) / 2);
|
|
78593
|
+
const innerRadius = toPercent((_c = options.innerRadius) !== null && _c !== void 0 ? _c : 0, maxRadius);
|
|
78594
|
+
const outerRadius = toPercent(options.outerRadius, maxRadius);
|
|
78595
|
+
const center = [
|
|
78596
|
+
isNumber$2((_d = options.center) === null || _d === void 0 ? void 0 : _d[0])
|
|
78597
|
+
? options.center[0]
|
|
78598
|
+
: viewBox.x0 + toPercent((_f = (_e = options.center) === null || _e === void 0 ? void 0 : _e[0]) !== null && _f !== void 0 ? _f : '50%', viewBox.x1 - viewBox.x0),
|
|
78599
|
+
isNumber$2((_g = options.center) === null || _g === void 0 ? void 0 : _g[1])
|
|
78600
|
+
? options.center[1]
|
|
78601
|
+
: viewBox.y0 + toPercent((_j = (_h = options.center) === null || _h === void 0 ? void 0 : _h[1]) !== null && _j !== void 0 ? _j : '50%', viewBox.y1 - viewBox.y0)
|
|
78602
|
+
];
|
|
78603
|
+
const fieldAccessor = field$3(options.field);
|
|
78604
|
+
const values = data.map(fieldAccessor);
|
|
78605
|
+
const [min, max] = extent$2(values);
|
|
78606
|
+
const radiusScale = min === max
|
|
78607
|
+
? (val) => (innerRadius + outerRadius) / 2
|
|
78608
|
+
: (val) => innerRadius + ((outerRadius - innerRadius) * (val - min)) / (max - min);
|
|
78609
|
+
const sizeAccessor = !isNil$1(options.radiusField) ? field$3(options.radiusField) : fieldAccessor;
|
|
78610
|
+
const defaultSize = (_l = (_k = options === null || options === void 0 ? void 0 : options.radiusRange) === null || _k === void 0 ? void 0 : _k[1]) !== null && _l !== void 0 ? _l : 5;
|
|
78611
|
+
let sizeScale = (datum) => defaultSize;
|
|
78612
|
+
if (sizeAccessor) {
|
|
78613
|
+
const [minSize, maxSize] = sizeAccessor !== fieldAccessor ? extent$2(data.map(sizeAccessor)) : [min, max];
|
|
78614
|
+
const minR = (_o = (_m = options.radiusRange) === null || _m === void 0 ? void 0 : _m[0]) !== null && _o !== void 0 ? _o : 5;
|
|
78615
|
+
const maxR = (_q = (_p = options.radiusRange) === null || _p === void 0 ? void 0 : _p[1]) !== null && _q !== void 0 ? _q : 5;
|
|
78616
|
+
if (minSize !== maxSize) {
|
|
78617
|
+
sizeScale = (datum) => minR + ((maxR - minR) * (sizeAccessor(datum) - minSize)) / (maxSize - minSize);
|
|
78618
|
+
}
|
|
78619
|
+
}
|
|
78620
|
+
const minAngle = Math.min(startAngle, endAngle);
|
|
78621
|
+
const maxAngle = Math.max(startAngle, endAngle);
|
|
78622
|
+
const angles = getPartialAngles(minAngle, maxAngle, data.length);
|
|
78623
|
+
const res = [];
|
|
78624
|
+
const searchStep = 60;
|
|
78625
|
+
const searchAngle = (maxAngle - minAngle) / searchStep;
|
|
78626
|
+
data.forEach((datum, index) => {
|
|
78627
|
+
const radius = radiusScale(values[index]);
|
|
78628
|
+
const size = sizeScale(datum);
|
|
78629
|
+
let x;
|
|
78630
|
+
let y;
|
|
78631
|
+
let angle = angles[index];
|
|
78632
|
+
for (let i = 0; i < searchStep; i++) {
|
|
78633
|
+
x = center[0] + radius * Math.cos(angle);
|
|
78634
|
+
y = center[1] + radius * Math.sin(angle);
|
|
78635
|
+
if (hasOverlap({ x, y, size }, res) ||
|
|
78636
|
+
x - size < viewBox.x0 ||
|
|
78637
|
+
x + size > viewBox.x1 ||
|
|
78638
|
+
y - size < viewBox.y0 ||
|
|
78639
|
+
y + size > viewBox.y1) {
|
|
78640
|
+
if (i < searchStep - 1) {
|
|
78641
|
+
angle += searchAngle;
|
|
78642
|
+
if (angle > maxAngle) {
|
|
78643
|
+
angle = minAngle;
|
|
78644
|
+
}
|
|
78645
|
+
else if (angle < minAngle) {
|
|
78646
|
+
angle = maxAngle;
|
|
78647
|
+
}
|
|
78648
|
+
}
|
|
78649
|
+
continue;
|
|
78650
|
+
}
|
|
78651
|
+
else {
|
|
78652
|
+
break;
|
|
78653
|
+
}
|
|
78654
|
+
}
|
|
78655
|
+
res.push(Object.assign({ [CORRELATION_X]: x, [CORRELATION_Y]: y, [CORRELATION_SIZE]: size }, datum));
|
|
78656
|
+
});
|
|
78657
|
+
return res;
|
|
78658
|
+
};
|
|
78659
|
+
const getPartialAngles = (minAngle, maxAngle, count) => {
|
|
78660
|
+
let offsetAngle = 0;
|
|
78661
|
+
let stepCount = Math.max(Math.ceil((2 * (maxAngle - minAngle)) / Math.PI), 2);
|
|
78662
|
+
let stepAngle = (maxAngle - minAngle) / stepCount;
|
|
78663
|
+
let stepIndex = 0;
|
|
78664
|
+
let stepSign = 1;
|
|
78665
|
+
let i = 0;
|
|
78666
|
+
let j = 0;
|
|
78667
|
+
const res = [];
|
|
78668
|
+
let startAngle = minAngle;
|
|
78669
|
+
while (i < count) {
|
|
78670
|
+
if (j < stepCount) {
|
|
78671
|
+
res.push(startAngle + (j % 2 ? Math.floor(j / 2) + Math.floor(stepCount / 2) : j / 2) * stepAngle * stepSign);
|
|
78672
|
+
j++;
|
|
78673
|
+
}
|
|
78674
|
+
i++;
|
|
78675
|
+
if (j === stepCount) {
|
|
78676
|
+
j = 0;
|
|
78677
|
+
stepIndex += 1;
|
|
78678
|
+
stepSign *= -1;
|
|
78679
|
+
if (offsetAngle === 0) {
|
|
78680
|
+
offsetAngle = stepAngle / 2;
|
|
78681
|
+
}
|
|
78682
|
+
else {
|
|
78683
|
+
offsetAngle /= 2;
|
|
78684
|
+
}
|
|
78685
|
+
startAngle = stepSign === -1 ? maxAngle - offsetAngle : minAngle + offsetAngle;
|
|
78686
|
+
if (stepIndex >= 2) {
|
|
78687
|
+
stepAngle /= 2;
|
|
78688
|
+
stepCount *= 2;
|
|
78689
|
+
}
|
|
78690
|
+
}
|
|
78691
|
+
}
|
|
78692
|
+
return res;
|
|
78693
|
+
};
|
|
78694
|
+
const hasOverlap = (item, arr) => {
|
|
78695
|
+
if (!arr || !arr.length) {
|
|
78696
|
+
return false;
|
|
78697
|
+
}
|
|
78698
|
+
return arr.some(entry => {
|
|
78699
|
+
return Math.pow(item.x - entry.x, 2) + Math.pow(item.y - entry.y, 2) < Math.pow(item.size + entry.size, 2);
|
|
78700
|
+
});
|
|
78701
|
+
};
|
|
78702
|
+
|
|
78703
|
+
const correlationCenter = (data, options) => {
|
|
78704
|
+
if (!data || !isArray$1(data)) {
|
|
78705
|
+
return [];
|
|
78706
|
+
}
|
|
78707
|
+
const { keyword, categoryField } = options;
|
|
78708
|
+
const nodeInfo = data[0].latestData[0];
|
|
78709
|
+
const centerInfo = {
|
|
78710
|
+
[categoryField]: keyword,
|
|
78711
|
+
[DEFAULT_DATA_INDEX]: nodeInfo === null || nodeInfo === void 0 ? void 0 : nodeInfo[DEFAULT_DATA_INDEX],
|
|
78712
|
+
[DEFAULT_DATA_SERIES_FIELD]: nodeInfo === null || nodeInfo === void 0 ? void 0 : nodeInfo[DEFAULT_DATA_SERIES_FIELD]
|
|
78713
|
+
};
|
|
78714
|
+
return centerInfo;
|
|
78715
|
+
};
|
|
78716
|
+
|
|
78717
|
+
const correlationPresetAnimation = (_params, preset) => {
|
|
78718
|
+
switch (preset) {
|
|
78719
|
+
case 'fadeIn': {
|
|
78720
|
+
return {
|
|
78721
|
+
type: 'fadeIn'
|
|
78722
|
+
};
|
|
78723
|
+
}
|
|
78724
|
+
case 'scaleIn': {
|
|
78725
|
+
return {
|
|
78726
|
+
type: 'scaleIn'
|
|
78727
|
+
};
|
|
78728
|
+
}
|
|
78729
|
+
default: {
|
|
78730
|
+
return {
|
|
78731
|
+
type: 'scaleIn'
|
|
78732
|
+
};
|
|
78733
|
+
}
|
|
78734
|
+
}
|
|
78735
|
+
};
|
|
78736
|
+
const registerCorrelationAnimation = () => {
|
|
78737
|
+
Factory.registerAnimation('correlation', (params, preset) => (Object.assign({ appear: correlationPresetAnimation(params, preset) }, ScaleInOutAnimation)));
|
|
78738
|
+
};
|
|
78739
|
+
|
|
78740
|
+
class CorrelationSeries extends PolarSeries {
|
|
78741
|
+
constructor() {
|
|
78742
|
+
super(...arguments);
|
|
78743
|
+
this.type = SeriesTypeEnum.correlation;
|
|
78744
|
+
this._viewBox = new Bounds();
|
|
78745
|
+
}
|
|
78746
|
+
getCategoryField() {
|
|
78747
|
+
return this._categoryField;
|
|
78748
|
+
}
|
|
78749
|
+
setCategoryField(f) {
|
|
78750
|
+
this._categoryField = f;
|
|
78751
|
+
return this._categoryField;
|
|
78752
|
+
}
|
|
78753
|
+
getValueField() {
|
|
78754
|
+
return this._valueField;
|
|
78755
|
+
}
|
|
78756
|
+
setValueField(f) {
|
|
78757
|
+
this._valueField = f;
|
|
78758
|
+
return this._valueField;
|
|
78759
|
+
}
|
|
78760
|
+
getSeriesField() {
|
|
78761
|
+
return this._seriesField;
|
|
78762
|
+
}
|
|
78763
|
+
setSeriesField(field) {
|
|
78764
|
+
if (isValid$1(field)) {
|
|
78765
|
+
this._seriesField = field;
|
|
78766
|
+
}
|
|
78767
|
+
}
|
|
78768
|
+
getSizeField() {
|
|
78769
|
+
return this._sizeField;
|
|
78770
|
+
}
|
|
78771
|
+
setSizeField(field) {
|
|
78772
|
+
if (isValid$1(field)) {
|
|
78773
|
+
this._sizeField = field;
|
|
78774
|
+
}
|
|
78775
|
+
}
|
|
78776
|
+
getSizeRange() {
|
|
78777
|
+
return this._sizeRange;
|
|
78778
|
+
}
|
|
78779
|
+
setSizeRange(range) {
|
|
78780
|
+
if (isValid$1(range)) {
|
|
78781
|
+
this._sizeRange = range;
|
|
78782
|
+
}
|
|
78783
|
+
}
|
|
78784
|
+
setAttrFromSpec() {
|
|
78785
|
+
super.setAttrFromSpec();
|
|
78786
|
+
this.setCategoryField(this._spec.categoryField);
|
|
78787
|
+
this.setValueField(this._spec.valueField);
|
|
78788
|
+
this.setSeriesField(this._spec.seriesField);
|
|
78789
|
+
this.setSizeField(this._spec.sizeField);
|
|
78790
|
+
this.setSizeRange(this._spec.sizeRange);
|
|
78791
|
+
}
|
|
78792
|
+
initData() {
|
|
78793
|
+
var _a, _b, _c, _d;
|
|
78794
|
+
super.initData();
|
|
78795
|
+
if (!this._data) {
|
|
78796
|
+
return;
|
|
78797
|
+
}
|
|
78798
|
+
registerDataSetInstanceTransform(this._dataSet, 'correlation', correlation);
|
|
78799
|
+
const centerDataSet = new DataSet();
|
|
78800
|
+
registerDataSetInstanceParser(centerDataSet, 'dataview', dataViewParser);
|
|
78801
|
+
registerDataSetInstanceTransform(centerDataSet, 'correlationCenter', correlationCenter);
|
|
78802
|
+
const centerDataView = new DataView(centerDataSet);
|
|
78803
|
+
centerDataView.parse([this.getViewData()], {
|
|
78804
|
+
type: 'dataview'
|
|
78805
|
+
});
|
|
78806
|
+
centerDataView.transform({
|
|
78807
|
+
type: 'correlationCenter',
|
|
78808
|
+
options: {
|
|
78809
|
+
keyword: (_d = (_c = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerLabel) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.text) !== null && _d !== void 0 ? _d : '',
|
|
78810
|
+
categoryField: this._spec.categoryField
|
|
78811
|
+
}
|
|
78812
|
+
});
|
|
78813
|
+
this._centerSeriesData = new SeriesData(this._option, centerDataView);
|
|
78814
|
+
}
|
|
78815
|
+
_statisticViewData() {
|
|
78816
|
+
super._statisticViewData();
|
|
78817
|
+
this._data.getDataView().transform({
|
|
78818
|
+
type: 'correlation',
|
|
78819
|
+
options: {
|
|
78820
|
+
view: () => {
|
|
78821
|
+
return {
|
|
78822
|
+
x0: this._viewBox.x1,
|
|
78823
|
+
x1: this._viewBox.x2,
|
|
78824
|
+
y0: this._viewBox.y1,
|
|
78825
|
+
y1: this._viewBox.y2
|
|
78826
|
+
};
|
|
78827
|
+
},
|
|
78828
|
+
field: this._spec.valueField,
|
|
78829
|
+
radiusRange: this._spec.sizeRange,
|
|
78830
|
+
radiusField: this._spec.sizeField,
|
|
78831
|
+
center: [this._spec.centerX, this._spec.centerY],
|
|
78832
|
+
innerRadius: this._spec.innerRadius,
|
|
78833
|
+
outerRadius: this._spec.outerRadius,
|
|
78834
|
+
startAngle: this._spec.startAngle,
|
|
78835
|
+
endAngle: this._spec.endAngle
|
|
78836
|
+
}
|
|
78837
|
+
});
|
|
78838
|
+
}
|
|
78839
|
+
initMark() {
|
|
78840
|
+
const nodePointMark = this._createMark(CorrelationSeries.mark.nodePoint, {
|
|
78841
|
+
groupKey: this._seriesField,
|
|
78842
|
+
label: mergeSpec({ animation: this._spec.animation }, this._spec.label),
|
|
78843
|
+
isSeriesMark: true,
|
|
78844
|
+
key: DEFAULT_DATA_INDEX
|
|
78845
|
+
});
|
|
78846
|
+
if (nodePointMark) {
|
|
78847
|
+
nodePointMark.setZIndex(LayoutZIndex.Node);
|
|
78848
|
+
this._nodePointMark = nodePointMark;
|
|
78849
|
+
}
|
|
78850
|
+
const ripplePointMark = this._createMark(CorrelationSeries.mark.ripplePoint, {
|
|
78851
|
+
key: DEFAULT_DATA_INDEX,
|
|
78852
|
+
dataView: this._centerSeriesData.getDataView(),
|
|
78853
|
+
dataProductId: this._centerSeriesData.getProductId()
|
|
78854
|
+
});
|
|
78855
|
+
if (ripplePointMark) {
|
|
78856
|
+
this._ripplePointMark = ripplePointMark;
|
|
78857
|
+
}
|
|
78858
|
+
const centerPointMark = this._createMark(CorrelationSeries.mark.centerPoint, {
|
|
78859
|
+
label: mergeSpec({ animation: this._spec.animation }, this._spec.centerLabel),
|
|
78860
|
+
key: DEFAULT_DATA_INDEX,
|
|
78861
|
+
dataView: this._centerSeriesData.getDataView(),
|
|
78862
|
+
dataProductId: this._centerSeriesData.getProductId()
|
|
78863
|
+
});
|
|
78864
|
+
if (centerPointMark) {
|
|
78865
|
+
centerPointMark.setZIndex(LayoutZIndex.Node);
|
|
78866
|
+
this._centerPointMark = centerPointMark;
|
|
78867
|
+
}
|
|
78868
|
+
}
|
|
78869
|
+
initMarkStyle() {
|
|
78870
|
+
this._initNodePointMarkStyle();
|
|
78871
|
+
this._initRipplePointMarkStyle();
|
|
78872
|
+
this._initCenterPointMarkStyle();
|
|
78873
|
+
}
|
|
78874
|
+
_initNodePointMarkStyle() {
|
|
78875
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
78876
|
+
const nodePointMark = this._nodePointMark;
|
|
78877
|
+
if (!nodePointMark) {
|
|
78878
|
+
return;
|
|
78879
|
+
}
|
|
78880
|
+
this.setMarkStyle(nodePointMark, {
|
|
78881
|
+
x: (datum) => datum[CORRELATION_X],
|
|
78882
|
+
y: (datum) => datum[CORRELATION_Y],
|
|
78883
|
+
size: (datum) => datum[CORRELATION_SIZE],
|
|
78884
|
+
fill: (_d = (_c = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.nodePoint) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.fill) !== null && _d !== void 0 ? _d : this.getColorAttribute(),
|
|
78885
|
+
fillOpacity: (_h = (_g = (_f = (_e = this._spec) === null || _e === void 0 ? void 0 : _e.nodePoint) === null || _f === void 0 ? void 0 : _f.style) === null || _g === void 0 ? void 0 : _g.fillOpacity) !== null && _h !== void 0 ? _h : 1,
|
|
78886
|
+
lineWidth: 0
|
|
78887
|
+
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
78888
|
+
this._trigger.registerMark(nodePointMark);
|
|
78889
|
+
}
|
|
78890
|
+
_initRipplePointMarkStyle() {
|
|
78891
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
78892
|
+
const ripplePointMark = this._ripplePointMark;
|
|
78893
|
+
if (!ripplePointMark) {
|
|
78894
|
+
return;
|
|
78895
|
+
}
|
|
78896
|
+
this.setMarkStyle(ripplePointMark, {
|
|
78897
|
+
x: () => {
|
|
78898
|
+
var _a, _b;
|
|
78899
|
+
return (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerX) !== null && _b !== void 0 ? _b : (this._viewBox.x1 + this._viewBox.x2) / 2;
|
|
78900
|
+
},
|
|
78901
|
+
y: () => {
|
|
78902
|
+
var _a, _b;
|
|
78903
|
+
return (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerY) !== null && _b !== void 0 ? _b : (this._viewBox.y1 + this._viewBox.y2) / 2;
|
|
78904
|
+
},
|
|
78905
|
+
size: () => {
|
|
78906
|
+
return Math.max(this._viewBox.x2 - this._viewBox.x1, this._viewBox.y2 - this._viewBox.y1) / 2;
|
|
78907
|
+
},
|
|
78908
|
+
fill: (_d = (_c = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.ripplePoint) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.fill) !== null && _d !== void 0 ? _d : this.getColorAttribute(),
|
|
78909
|
+
opacity: (_h = (_g = (_f = (_e = this._spec) === null || _e === void 0 ? void 0 : _e.ripplePoint) === null || _f === void 0 ? void 0 : _f.style) === null || _g === void 0 ? void 0 : _g.fillOpacity) !== null && _h !== void 0 ? _h : 0.2,
|
|
78910
|
+
ripple: (_m = (_l = (_k = (_j = this._spec) === null || _j === void 0 ? void 0 : _j.ripplePoint) === null || _k === void 0 ? void 0 : _k.style) === null || _l === void 0 ? void 0 : _l.ripple) !== null && _m !== void 0 ? _m : 0
|
|
78911
|
+
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
78912
|
+
}
|
|
78913
|
+
_initCenterPointMarkStyle() {
|
|
78914
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
78915
|
+
const centerPointMark = this._centerPointMark;
|
|
78916
|
+
if (!centerPointMark) {
|
|
78917
|
+
return;
|
|
78918
|
+
}
|
|
78919
|
+
this.setMarkStyle(centerPointMark, {
|
|
78920
|
+
x: () => {
|
|
78921
|
+
var _a, _b;
|
|
78922
|
+
return (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerX) !== null && _b !== void 0 ? _b : (this._viewBox.x1 + this._viewBox.x2) / 2;
|
|
78923
|
+
},
|
|
78924
|
+
y: () => {
|
|
78925
|
+
var _a, _b;
|
|
78926
|
+
return (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerY) !== null && _b !== void 0 ? _b : (this._viewBox.y1 + this._viewBox.y2) / 2;
|
|
78927
|
+
},
|
|
78928
|
+
size: () => {
|
|
78929
|
+
return (0.2 * Math.max(this._viewBox.x2 - this._viewBox.x1, this._viewBox.y2 - this._viewBox.y1)) / 2;
|
|
78930
|
+
},
|
|
78931
|
+
fill: (_d = (_c = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.centerPoint) === null || _b === void 0 ? void 0 : _b.style) === null || _c === void 0 ? void 0 : _c.fill) !== null && _d !== void 0 ? _d : this.getColorAttribute(),
|
|
78932
|
+
fillOpacity: (_h = (_g = (_f = (_e = this._spec) === null || _e === void 0 ? void 0 : _e.centerPoint) === null || _f === void 0 ? void 0 : _f.style) === null || _g === void 0 ? void 0 : _g.fillOpacity) !== null && _h !== void 0 ? _h : 1
|
|
78933
|
+
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
78934
|
+
this._trigger.registerMark(centerPointMark);
|
|
78935
|
+
}
|
|
78936
|
+
initTooltip() {
|
|
78937
|
+
super.initTooltip();
|
|
78938
|
+
this._nodePointMark && this._tooltipHelper.activeTriggerSet.mark.add(this._nodePointMark);
|
|
78939
|
+
}
|
|
78940
|
+
initLabelMarkStyle(labelMark) {
|
|
78941
|
+
if (!labelMark) {
|
|
78942
|
+
return;
|
|
78943
|
+
}
|
|
78944
|
+
this.setMarkStyle(labelMark, {
|
|
78945
|
+
fill: this.getColorAttribute(),
|
|
78946
|
+
text: (datum) => {
|
|
78947
|
+
return datum[this._categoryField];
|
|
78948
|
+
},
|
|
78949
|
+
z: this.dataToPositionZ.bind(this)
|
|
78950
|
+
}, STATE_VALUE_ENUM.STATE_NORMAL, AttributeLevel.Series);
|
|
78951
|
+
}
|
|
78952
|
+
initAnimation() {
|
|
78953
|
+
var _a, _b, _c;
|
|
78954
|
+
const appearPreset = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.animationAppear) === null || _b === void 0 ? void 0 : _b.preset;
|
|
78955
|
+
this._nodePointMark.setAnimationConfig(animationConfig((_c = Factory.getAnimationInKey('correlation')) === null || _c === void 0 ? void 0 : _c({}, appearPreset), userAnimationConfig(SeriesMarkNameEnum.nodePoint, this._spec)));
|
|
78956
|
+
}
|
|
78957
|
+
getGroupFields() {
|
|
78958
|
+
return [];
|
|
78959
|
+
}
|
|
78960
|
+
getStackGroupFields() {
|
|
78961
|
+
return [];
|
|
78962
|
+
}
|
|
78963
|
+
getStackValueField() {
|
|
78964
|
+
return '';
|
|
78965
|
+
}
|
|
78966
|
+
setValueFieldToStack() {
|
|
78967
|
+
return;
|
|
78968
|
+
}
|
|
78969
|
+
setValueFieldToPercent() {
|
|
78970
|
+
return;
|
|
78971
|
+
}
|
|
78972
|
+
getActiveMarks() {
|
|
78973
|
+
return [this._nodePointMark, this._centerPointMark];
|
|
78974
|
+
}
|
|
78975
|
+
getDimensionField() {
|
|
78976
|
+
return [this._categoryField];
|
|
78977
|
+
}
|
|
78978
|
+
getMeasureField() {
|
|
78979
|
+
return [this._valueField];
|
|
78980
|
+
}
|
|
78981
|
+
onLayoutEnd(ctx) {
|
|
78982
|
+
super.onLayoutEnd(ctx);
|
|
78983
|
+
this._viewBox.set(0, 0, this._region.getLayoutRect().width, this._region.getLayoutRect().height);
|
|
78984
|
+
this._rawData.reRunAllTransform();
|
|
78985
|
+
this.getViewData().reRunAllTransform();
|
|
78986
|
+
}
|
|
78987
|
+
}
|
|
78988
|
+
CorrelationSeries.type = SeriesTypeEnum.correlation;
|
|
78989
|
+
CorrelationSeries.mark = correlationSeriesMark;
|
|
78990
|
+
const registerCorrelationSeries = () => {
|
|
78991
|
+
Factory.registerMark(SymbolMark.type, SymbolMark);
|
|
78992
|
+
Factory.registerMark(RippleMark.type, RippleMark);
|
|
78993
|
+
Factory.registerSeries(CorrelationSeries.type, CorrelationSeries);
|
|
78994
|
+
registerCorrelationAnimation();
|
|
78995
|
+
};
|
|
78996
|
+
|
|
78997
|
+
class CorrelationChart extends BaseChart {
|
|
78998
|
+
constructor() {
|
|
78999
|
+
super(...arguments);
|
|
79000
|
+
this.type = ChartTypeEnum.correlation;
|
|
79001
|
+
this.seriesType = SeriesTypeEnum.correlation;
|
|
79002
|
+
}
|
|
79003
|
+
_getDefaultSeriesSpec(spec) {
|
|
79004
|
+
const series = Object.assign(Object.assign({}, super._getDefaultSeriesSpec(spec)), { categoryField: spec.categoryField, valueField: spec.valueField, seriesField: spec.seriesField, sizeField: spec.sizeField, sizeRange: spec.sizeRange, centerX: spec.centerX, centerY: spec.centerY, innerRadius: spec.innerRadius, outerRadius: spec.outerRadius, startAngle: spec.startAngle, endAngle: spec.endAngle, ripplePoint: spec.ripplePoint, centerPoint: spec.centerPoint, centerLabel: spec.centerLabel, nodePoint: spec.nodePoint, label: spec.label });
|
|
79005
|
+
const seriesType = SeriesTypeEnum.correlation;
|
|
79006
|
+
series.type = seriesType;
|
|
79007
|
+
series[seriesType] = spec[seriesType];
|
|
79008
|
+
return series;
|
|
79009
|
+
}
|
|
79010
|
+
transformSpec(spec) {
|
|
79011
|
+
super.transformSpec(spec);
|
|
79012
|
+
const defaultSeriesSpec = this._getDefaultSeriesSpec(spec);
|
|
79013
|
+
if (!spec.series || spec.series.length === 0) {
|
|
79014
|
+
spec.series = [defaultSeriesSpec];
|
|
79015
|
+
}
|
|
79016
|
+
else {
|
|
79017
|
+
spec.series.forEach(s => {
|
|
79018
|
+
if (!this.isValidSeries(s.type)) {
|
|
79019
|
+
return;
|
|
79020
|
+
}
|
|
79021
|
+
Object.keys(defaultSeriesSpec).forEach(k => {
|
|
79022
|
+
if (!(k in s)) {
|
|
79023
|
+
s[k] = defaultSeriesSpec[k];
|
|
79024
|
+
}
|
|
79025
|
+
});
|
|
79026
|
+
});
|
|
79027
|
+
}
|
|
79028
|
+
}
|
|
79029
|
+
}
|
|
79030
|
+
CorrelationChart.type = ChartTypeEnum.correlation;
|
|
79031
|
+
CorrelationChart.view = 'singleDefault';
|
|
79032
|
+
const registerCorrelationChart = () => {
|
|
79033
|
+
registerCorrelationSeries();
|
|
79034
|
+
Factory.registerChart(CorrelationChart.type, CorrelationChart);
|
|
79035
|
+
};
|
|
79036
|
+
|
|
78230
79037
|
function isValidAlignDomain(domain) {
|
|
78231
79038
|
return domain.length === 2 && isValidNumber$1(domain[0]) && isValidNumber$1(domain[1]) && domain[1] >= domain[0];
|
|
78232
79039
|
}
|
|
@@ -79189,6 +79996,19 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
79189
79996
|
});
|
|
79190
79997
|
}
|
|
79191
79998
|
this._delegateAxisContainerEvent(product.getGroupGraphicItem());
|
|
79999
|
+
if (this._unitText) {
|
|
80000
|
+
const bounds = product.graphicItem.AABBBounds;
|
|
80001
|
+
const pos = isXAxis(this._orient)
|
|
80002
|
+
? {
|
|
80003
|
+
x: bounds.x2,
|
|
80004
|
+
y: this.getLayoutStartPoint().y
|
|
80005
|
+
}
|
|
80006
|
+
: {
|
|
80007
|
+
x: this.getLayoutStartPoint().x,
|
|
80008
|
+
y: bounds.y1
|
|
80009
|
+
};
|
|
80010
|
+
this._unitText.setAttributes(pos);
|
|
80011
|
+
}
|
|
79192
80012
|
}
|
|
79193
80013
|
});
|
|
79194
80014
|
}
|
|
@@ -79336,17 +80156,14 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
79336
80156
|
this.setLayoutRect(rect);
|
|
79337
80157
|
this.updateScaleRange();
|
|
79338
80158
|
this.computeData();
|
|
79339
|
-
const isX = isXAxis(this.getOrient());
|
|
79340
80159
|
const context = { skipLayout: false };
|
|
79341
|
-
|
|
79342
|
-
|
|
79343
|
-
|
|
80160
|
+
const isX = isXAxis(this.getOrient());
|
|
80161
|
+
if (this.pluginService) {
|
|
80162
|
+
isX
|
|
80163
|
+
? this.callPlugin(plugin => {
|
|
79344
80164
|
plugin.onWillLayoutHorizontal && plugin.onWillLayoutHorizontal(this.pluginService, context, this);
|
|
79345
|
-
})
|
|
79346
|
-
|
|
79347
|
-
else {
|
|
79348
|
-
this.pluginService &&
|
|
79349
|
-
this.callPlugin(plugin => {
|
|
80165
|
+
})
|
|
80166
|
+
: this.callPlugin(plugin => {
|
|
79350
80167
|
plugin.onWillLayoutVertical && plugin.onWillLayoutVertical(this.pluginService, context, this);
|
|
79351
80168
|
});
|
|
79352
80169
|
}
|
|
@@ -79357,7 +80174,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
79357
80174
|
const axisComponent = product.getGroupGraphicItem();
|
|
79358
80175
|
const updateBounds = axisComponent.getBoundsWithoutRender(mergeSpec(Object.assign({}, this.getLayoutStartPoint()), this._axisStyle, attrs));
|
|
79359
80176
|
if (isFinite(updateBounds.width())) {
|
|
79360
|
-
result = updateBounds;
|
|
80177
|
+
result = this._appendAxisUnit(updateBounds, isX);
|
|
79361
80178
|
this._latestBounds = updateBounds;
|
|
79362
80179
|
}
|
|
79363
80180
|
}
|
|
@@ -79541,6 +80358,56 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
79541
80358
|
const chartSpec = this._option.getChart().getSpec();
|
|
79542
80359
|
this._spec.inverse = transformInverse(this._spec, chartSpec.direction === Direction.horizontal);
|
|
79543
80360
|
}
|
|
80361
|
+
_appendAxisUnit(bounds, isX) {
|
|
80362
|
+
var _a;
|
|
80363
|
+
if (this._spec.unit && this._spec.unit.visible) {
|
|
80364
|
+
const { text, style } = this._spec.unit;
|
|
80365
|
+
let pos;
|
|
80366
|
+
let unitTextStyle;
|
|
80367
|
+
if (isX) {
|
|
80368
|
+
pos = {
|
|
80369
|
+
x: bounds.x2,
|
|
80370
|
+
y: this.getLayoutStartPoint().y
|
|
80371
|
+
};
|
|
80372
|
+
unitTextStyle = {
|
|
80373
|
+
textAlign: 'left',
|
|
80374
|
+
textBaseline: 'middle'
|
|
80375
|
+
};
|
|
80376
|
+
}
|
|
80377
|
+
else {
|
|
80378
|
+
pos = {
|
|
80379
|
+
x: this.getLayoutStartPoint().x,
|
|
80380
|
+
y: bounds.y1
|
|
80381
|
+
};
|
|
80382
|
+
unitTextStyle = {
|
|
80383
|
+
textAlign: this._orient === 'left' ? 'left' : 'right',
|
|
80384
|
+
textBaseline: 'bottom'
|
|
80385
|
+
};
|
|
80386
|
+
}
|
|
80387
|
+
unitTextStyle = Object.assign(Object.assign(Object.assign({}, unitTextStyle), style), { x: pos.x, y: pos.y, text });
|
|
80388
|
+
if (this._unitText) {
|
|
80389
|
+
this._unitText.setAttributes(unitTextStyle);
|
|
80390
|
+
}
|
|
80391
|
+
else {
|
|
80392
|
+
this._unitText = createText(unitTextStyle);
|
|
80393
|
+
this._unitText.name = 'axis-unit';
|
|
80394
|
+
(_a = this.getContainer()) === null || _a === void 0 ? void 0 : _a.add(this._unitText);
|
|
80395
|
+
}
|
|
80396
|
+
const textBounds = this._unitText.AABBBounds;
|
|
80397
|
+
if (!isX) {
|
|
80398
|
+
bounds.x1 += textBounds.x1 < bounds.x1 ? textBounds.x1 - bounds.x1 : 0;
|
|
80399
|
+
bounds.y1 += textBounds.y1 < bounds.y1 ? textBounds.y1 - bounds.y1 : 0;
|
|
80400
|
+
}
|
|
80401
|
+
else {
|
|
80402
|
+
bounds.x2 += textBounds.x2 > bounds.x2 ? textBounds.x2 - bounds.x2 : 0;
|
|
80403
|
+
bounds.y2 += textBounds.y2 > bounds.y2 ? textBounds.y2 - bounds.y2 : 0;
|
|
80404
|
+
}
|
|
80405
|
+
}
|
|
80406
|
+
return bounds;
|
|
80407
|
+
}
|
|
80408
|
+
getVRenderComponents() {
|
|
80409
|
+
return this._unitText ? [this._unitText] : [];
|
|
80410
|
+
}
|
|
79544
80411
|
}
|
|
79545
80412
|
CartesianAxis.type = ComponentTypeEnum.cartesianAxis;
|
|
79546
80413
|
|
|
@@ -81594,7 +82461,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
81594
82461
|
shapeColor,
|
|
81595
82462
|
keyStyle,
|
|
81596
82463
|
valueStyle,
|
|
81597
|
-
spaceRow
|
|
82464
|
+
spaceRow,
|
|
82465
|
+
datum
|
|
81598
82466
|
};
|
|
81599
82467
|
};
|
|
81600
82468
|
|
|
@@ -85152,6 +86020,33 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85152
86020
|
setStartAndEnd(start, end) {
|
|
85153
86021
|
this._handleChange(start, end, true);
|
|
85154
86022
|
}
|
|
86023
|
+
enableInteraction() {
|
|
86024
|
+
this._activeRoam = true;
|
|
86025
|
+
}
|
|
86026
|
+
disableInteraction() {
|
|
86027
|
+
this._activeRoam = false;
|
|
86028
|
+
}
|
|
86029
|
+
zoomIn(location) {
|
|
86030
|
+
this._handleChartZoom({
|
|
86031
|
+
zoomDelta: 1.2,
|
|
86032
|
+
zoomX: location === null || location === void 0 ? void 0 : location.x,
|
|
86033
|
+
zoomY: location === null || location === void 0 ? void 0 : location.y
|
|
86034
|
+
});
|
|
86035
|
+
}
|
|
86036
|
+
zoomOut(location) {
|
|
86037
|
+
this._handleChartZoom({
|
|
86038
|
+
zoomDelta: 0.8,
|
|
86039
|
+
zoomX: location === null || location === void 0 ? void 0 : location.x,
|
|
86040
|
+
zoomY: location === null || location === void 0 ? void 0 : location.y
|
|
86041
|
+
});
|
|
86042
|
+
}
|
|
86043
|
+
_handleChange(start, end, updateComponent) {
|
|
86044
|
+
var _a;
|
|
86045
|
+
const zoomLock = (_a = this._spec.zoomLock) !== null && _a !== void 0 ? _a : false;
|
|
86046
|
+
if (zoomLock || end - start < this._minSpan || end - start > this._maxSpan) {
|
|
86047
|
+
return;
|
|
86048
|
+
}
|
|
86049
|
+
}
|
|
85155
86050
|
get visible() {
|
|
85156
86051
|
return this._visible;
|
|
85157
86052
|
}
|
|
@@ -85160,6 +86055,22 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85160
86055
|
this.layoutType = 'region-relative';
|
|
85161
86056
|
this._orient = 'left';
|
|
85162
86057
|
this._stateField = 'x';
|
|
86058
|
+
this._activeRoam = true;
|
|
86059
|
+
this._zoomAttr = {
|
|
86060
|
+
enable: true,
|
|
86061
|
+
rate: 1,
|
|
86062
|
+
focus: true
|
|
86063
|
+
};
|
|
86064
|
+
this._dragAttr = {
|
|
86065
|
+
enable: true,
|
|
86066
|
+
rate: 1,
|
|
86067
|
+
reverse: true
|
|
86068
|
+
};
|
|
86069
|
+
this._scrollAttr = {
|
|
86070
|
+
enable: true,
|
|
86071
|
+
rate: 1,
|
|
86072
|
+
reverse: true
|
|
86073
|
+
};
|
|
85163
86074
|
this.effect = {
|
|
85164
86075
|
onZoomChange: () => {
|
|
85165
86076
|
var _a;
|
|
@@ -85201,36 +86112,69 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85201
86112
|
(_b = (_a = this.effect).onZoomChange) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
85202
86113
|
return true;
|
|
85203
86114
|
};
|
|
85204
|
-
this.
|
|
85205
|
-
|
|
85206
|
-
|
|
85207
|
-
|
|
85208
|
-
|
|
86115
|
+
this._handleChartZoom = (params) => {
|
|
86116
|
+
var _a, _b;
|
|
86117
|
+
if (!this._activeRoam) {
|
|
86118
|
+
return;
|
|
86119
|
+
}
|
|
86120
|
+
const { zoomDelta, zoomX, zoomY } = params;
|
|
86121
|
+
const { x, y } = this._regions[0].getLayoutStartPoint();
|
|
86122
|
+
const { width, height } = this._regions[0].getLayoutRect();
|
|
85209
86123
|
const delta = Math.abs(this._start - this._end);
|
|
85210
|
-
const
|
|
85211
|
-
if (delta >= 1 && zoomDelta
|
|
86124
|
+
const zoomRate = (_b = (_a = this._spec.roamZoom) === null || _a === void 0 ? void 0 : _a.rate) !== null && _b !== void 0 ? _b : 1;
|
|
86125
|
+
if (delta >= 1 && zoomDelta < 1) {
|
|
85212
86126
|
return;
|
|
85213
86127
|
}
|
|
85214
|
-
if (delta <= 0.01 && zoomDelta
|
|
86128
|
+
if (delta <= 0.01 && zoomDelta > 1) {
|
|
85215
86129
|
return;
|
|
85216
86130
|
}
|
|
85217
|
-
const
|
|
85218
|
-
const
|
|
85219
|
-
|
|
86131
|
+
const focusLoc = this._isHorizontal ? zoomX : zoomY;
|
|
86132
|
+
const totalValue = delta * (zoomDelta - 1) * zoomRate;
|
|
86133
|
+
let startValue = totalValue / 2;
|
|
86134
|
+
let endValue = totalValue / 2;
|
|
86135
|
+
if (focusLoc) {
|
|
86136
|
+
const startLoc = this._isHorizontal ? x : y;
|
|
86137
|
+
const endLoc = this._isHorizontal ? width : height;
|
|
86138
|
+
startValue = (Math.abs(startLoc - focusLoc) / Math.abs(endLoc - startLoc)) * totalValue;
|
|
86139
|
+
endValue = (Math.abs(endLoc - focusLoc) / Math.abs(endLoc - startLoc)) * totalValue;
|
|
86140
|
+
}
|
|
86141
|
+
const start = clamp$1(this._start + startValue, 0, 1);
|
|
86142
|
+
const end = clamp$1(this._end - endValue, 0, 1);
|
|
85220
86143
|
this._handleChange(Math.min(start, end), Math.max(start, end), true);
|
|
85221
86144
|
};
|
|
86145
|
+
this._handleChartScroll = (params, e) => {
|
|
86146
|
+
var _a;
|
|
86147
|
+
if (!this._activeRoam) {
|
|
86148
|
+
return;
|
|
86149
|
+
}
|
|
86150
|
+
const { scrollX, scrollY } = params;
|
|
86151
|
+
let value = this._isHorizontal ? scrollX : scrollY;
|
|
86152
|
+
if (!this._scrollAttr.reverse) {
|
|
86153
|
+
value = -value;
|
|
86154
|
+
}
|
|
86155
|
+
this._handleChartMove(value, (_a = this._scrollAttr.rate) !== null && _a !== void 0 ? _a : 1);
|
|
86156
|
+
};
|
|
85222
86157
|
this._handleChartDrag = (delta, e) => {
|
|
86158
|
+
var _a;
|
|
86159
|
+
if (!this._activeRoam) {
|
|
86160
|
+
return;
|
|
86161
|
+
}
|
|
85223
86162
|
const [dx, dy] = delta;
|
|
85224
|
-
|
|
86163
|
+
let value = this._isHorizontal ? dx : dy;
|
|
86164
|
+
if (this._dragAttr.reverse) {
|
|
86165
|
+
value = -value;
|
|
86166
|
+
}
|
|
86167
|
+
this._handleChartMove(value, (_a = this._dragAttr.rate) !== null && _a !== void 0 ? _a : 1);
|
|
86168
|
+
};
|
|
86169
|
+
this._handleChartMove = (value, rate) => {
|
|
85225
86170
|
const totalValue = this._isHorizontal ? this.getLayoutRect().width : this.getLayoutRect().height;
|
|
85226
|
-
const SCROLL_RATE = 0.02;
|
|
85227
86171
|
if (Math.abs(value) >= 1e-6) {
|
|
85228
86172
|
if (value > 0 && this._end < 1) {
|
|
85229
|
-
const moveDelta = Math.min(1 - this._end, value / totalValue) *
|
|
86173
|
+
const moveDelta = Math.min(1 - this._end, value / totalValue) * rate;
|
|
85230
86174
|
this._handleChange(this._start + moveDelta, this._end + moveDelta, true);
|
|
85231
86175
|
}
|
|
85232
86176
|
else if (value < 0 && this._start > 0) {
|
|
85233
|
-
const moveDelta = Math.max(-this._start, value / totalValue) *
|
|
86177
|
+
const moveDelta = Math.max(-this._start, value / totalValue) * rate;
|
|
85234
86178
|
this._handleChange(this._start + moveDelta, this._end + moveDelta, true);
|
|
85235
86179
|
}
|
|
85236
86180
|
}
|
|
@@ -85244,6 +86188,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85244
86188
|
super.created();
|
|
85245
86189
|
this._setAxisFromSpec();
|
|
85246
86190
|
this._setRegionsFromSpec();
|
|
86191
|
+
this._initEvent();
|
|
85247
86192
|
this._initData();
|
|
85248
86193
|
this._initStateScale();
|
|
85249
86194
|
this._setStateFromSpec();
|
|
@@ -85317,6 +86262,9 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85317
86262
|
}
|
|
85318
86263
|
return domain;
|
|
85319
86264
|
}
|
|
86265
|
+
_initEvent() {
|
|
86266
|
+
this._initCommonEvent();
|
|
86267
|
+
}
|
|
85320
86268
|
_initData() {
|
|
85321
86269
|
const dataCollection = [];
|
|
85322
86270
|
const stateFields = [];
|
|
@@ -85404,8 +86352,23 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85404
86352
|
setAttrFromSpec() {
|
|
85405
86353
|
var _a;
|
|
85406
86354
|
super.setAttrFromSpec();
|
|
85407
|
-
if (this._spec.
|
|
85408
|
-
this.
|
|
86355
|
+
if (this._spec.roamZoom === true || this._spec.roamZoom) {
|
|
86356
|
+
this._zoomAttr = merge$1({}, this._zoomAttr, this._spec.roamZoom);
|
|
86357
|
+
}
|
|
86358
|
+
else {
|
|
86359
|
+
this._zoomAttr.enable = false;
|
|
86360
|
+
}
|
|
86361
|
+
if (this._spec.roamDrag === true || this._spec.roamDrag) {
|
|
86362
|
+
this._dragAttr = merge$1({}, this._dragAttr, this._spec.roamDrag);
|
|
86363
|
+
}
|
|
86364
|
+
else {
|
|
86365
|
+
this._dragAttr.enable = false;
|
|
86366
|
+
}
|
|
86367
|
+
if (this._spec.roamScroll === true || this._spec.roamScroll) {
|
|
86368
|
+
this._scrollAttr = merge$1({}, this._scrollAttr, this._spec.roamScroll);
|
|
86369
|
+
}
|
|
86370
|
+
else {
|
|
86371
|
+
this._scrollAttr.enable = false;
|
|
85409
86372
|
}
|
|
85410
86373
|
this._field = this._spec.field;
|
|
85411
86374
|
this._width = this._computeWidth();
|
|
@@ -85437,6 +86400,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85437
86400
|
return (mode === 'percent' && this._spec.end) || (mode === 'value' && this._spec.endValue);
|
|
85438
86401
|
}
|
|
85439
86402
|
_setStateFromSpec() {
|
|
86403
|
+
var _a, _b;
|
|
85440
86404
|
this._auto = !!this._spec.auto;
|
|
85441
86405
|
let start;
|
|
85442
86406
|
let end;
|
|
@@ -85459,6 +86423,18 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85459
86423
|
this._endValue = this._statePointToData(end);
|
|
85460
86424
|
this._start = start;
|
|
85461
86425
|
this._end = end;
|
|
86426
|
+
this._minSpan = (_a = this._spec.minSpan) !== null && _a !== void 0 ? _a : 0;
|
|
86427
|
+
this._maxSpan = (_b = this._spec.maxSpan) !== null && _b !== void 0 ? _b : 1;
|
|
86428
|
+
if (isContinuous(this._stateScale.type) && this._stateScale.domain[0] !== this._stateScale.domain[1]) {
|
|
86429
|
+
if (this._spec.minValueSpan) {
|
|
86430
|
+
this._minSpan = this._spec.minValueSpan / (this._stateScale.domain()[1] - this._stateScale.domain()[0]);
|
|
86431
|
+
}
|
|
86432
|
+
if (this._spec.maxValueSpan) {
|
|
86433
|
+
this._maxSpan = this._spec.maxValueSpan / (this._stateScale.domain()[1] - this._stateScale.domain()[0]);
|
|
86434
|
+
}
|
|
86435
|
+
}
|
|
86436
|
+
this._minSpan = Math.max(0, this._minSpan);
|
|
86437
|
+
this._maxSpan = Math.min(this._maxSpan, 1);
|
|
85462
86438
|
if ((!this._relatedAxisComponent || this._filterMode !== IFilterMode.axis) &&
|
|
85463
86439
|
(this._start !== 0 || this._end !== 1)) {
|
|
85464
86440
|
this._newDomain = this._parseDomainFromState(this._startValue, this._endValue);
|
|
@@ -85551,18 +86527,25 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85551
86527
|
return allDomain.slice(Math.min(startIndex, endIndex), Math.max(startIndex, endIndex) + 1);
|
|
85552
86528
|
}
|
|
85553
86529
|
_initCommonEvent() {
|
|
85554
|
-
|
|
85555
|
-
|
|
85556
|
-
|
|
85557
|
-
|
|
86530
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
86531
|
+
const delayType = (_b = (_a = this._spec) === null || _a === void 0 ? void 0 : _a.delayType) !== null && _b !== void 0 ? _b : 'throttle';
|
|
86532
|
+
const delayTime = isValid$1((_c = this._spec) === null || _c === void 0 ? void 0 : _c.delayType) ? (_e = (_d = this._spec) === null || _d === void 0 ? void 0 : _d.delayTime) !== null && _e !== void 0 ? _e : 30 : 0;
|
|
86533
|
+
const realTime = (_g = (_f = this._spec) === null || _f === void 0 ? void 0 : _f.realTime) !== null && _g !== void 0 ? _g : false;
|
|
86534
|
+
const option = { delayType, delayTime, realTime };
|
|
86535
|
+
if (this._zoomAttr.enable) {
|
|
86536
|
+
this.initZoomEventOfRegions(this._regions, null, this._handleChartZoom, option);
|
|
86537
|
+
}
|
|
86538
|
+
if (this._scrollAttr.enable) {
|
|
86539
|
+
this.initScrollEventOfRegions(this._regions, null, this._handleChartScroll, option);
|
|
86540
|
+
}
|
|
86541
|
+
if (this._dragAttr.enable) {
|
|
86542
|
+
this.initDragEventOfRegions(this._regions, null, this._handleChartDrag, option);
|
|
85558
86543
|
}
|
|
85559
86544
|
}
|
|
85560
86545
|
updateLayoutAttribute() {
|
|
85561
86546
|
if (this._visible) {
|
|
85562
86547
|
this._createOrUpdateComponent();
|
|
85563
86548
|
}
|
|
85564
|
-
this._initCommonEvent();
|
|
85565
|
-
this._initEvent();
|
|
85566
86549
|
super.updateLayoutAttribute();
|
|
85567
86550
|
}
|
|
85568
86551
|
_boundsInRect(rect) {
|
|
@@ -85728,6 +86711,14 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85728
86711
|
setAttrFromSpec() {
|
|
85729
86712
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
85730
86713
|
super.setAttrFromSpec();
|
|
86714
|
+
if (isBoolean$1(this._spec.roam)) {
|
|
86715
|
+
this._zoomAttr.enable = this._spec.roam;
|
|
86716
|
+
this._dragAttr.enable = this._spec.roam;
|
|
86717
|
+
this._scrollAttr.enable = this._spec.roam;
|
|
86718
|
+
}
|
|
86719
|
+
if (this._zoomAttr.enable || this._dragAttr.enable || this._scrollAttr.enable) {
|
|
86720
|
+
this.initZoomable(this.event, this._option.mode);
|
|
86721
|
+
}
|
|
85731
86722
|
this._backgroundSize = (_b = (_a = this._spec.background) === null || _a === void 0 ? void 0 : _a.size) !== null && _b !== void 0 ? _b : 30;
|
|
85732
86723
|
this._middleHandlerSize = this._computeMiddleHandlerSize();
|
|
85733
86724
|
this._width = this._computeWidth();
|
|
@@ -85737,7 +86728,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85737
86728
|
? this._height - this._middleHandlerSize
|
|
85738
86729
|
: this._width - this._middleHandlerSize;
|
|
85739
86730
|
}
|
|
85740
|
-
if (isNil$1((_h = (_g = (_f = this._originalSpec) === null || _f === void 0 ? void 0 : _f.
|
|
86731
|
+
if (isNil$1((_h = (_g = (_f = this._originalSpec) === null || _f === void 0 ? void 0 : _f.endHandler) === null || _g === void 0 ? void 0 : _g.style) === null || _h === void 0 ? void 0 : _h.size)) {
|
|
85741
86732
|
this._spec.endHandler.style.size = this._isHorizontal
|
|
85742
86733
|
? this._height - this._middleHandlerSize
|
|
85743
86734
|
: this._width - this._middleHandlerSize;
|
|
@@ -85848,7 +86839,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85848
86839
|
return true;
|
|
85849
86840
|
}
|
|
85850
86841
|
_createOrUpdateComponent() {
|
|
85851
|
-
var _a, _b, _c;
|
|
86842
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
85852
86843
|
if (!this._component && this._visible) {
|
|
85853
86844
|
const container = this.getContainer();
|
|
85854
86845
|
const xScale = this._isHorizontal ? this._stateScale : this._valueScale;
|
|
@@ -85860,12 +86851,12 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85860
86851
|
}, orient: this._orient, size: {
|
|
85861
86852
|
width: this.getLayoutRect().width,
|
|
85862
86853
|
height: this.getLayoutRect().height
|
|
85863
|
-
}, showDetail: (_a = this._spec) === null || _a === void 0 ? void 0 : _a.showDetail, brushSelect: (_c = (_b = this._spec) === null || _b === void 0 ? void 0 : _b.brushSelect) !== null && _c !== void 0 ? _c : false, previewData: isNeedPreview && this._data.getLatestData(),
|
|
86854
|
+
}, showDetail: (_a = this._spec) === null || _a === void 0 ? void 0 : _a.showDetail, brushSelect: (_c = (_b = this._spec) === null || _b === void 0 ? void 0 : _b.brushSelect) !== null && _c !== void 0 ? _c : false, zoomLock: (_e = (_d = this._spec) === null || _d === void 0 ? void 0 : _d.zoomLock) !== null && _e !== void 0 ? _e : false, minSpan: this._minSpan, maxSpan: this._maxSpan, delayType: (_f = this._spec) === null || _f === void 0 ? void 0 : _f.delayType, delayTime: isValid$1((_g = this._spec) === null || _g === void 0 ? void 0 : _g.delayType) ? (_j = (_h = this._spec) === null || _h === void 0 ? void 0 : _h.delayTime) !== null && _j !== void 0 ? _j : 30 : 0, realTime: (_l = (_k = this._spec) === null || _k === void 0 ? void 0 : _k.realTime) !== null && _l !== void 0 ? _l : true, previewData: isNeedPreview && this._data.getLatestData(), previewPointsX: isNeedPreview && this._dataToPositionX, previewPointsY: isNeedPreview && this._dataToPositionY }, this._getComponentAttrs()));
|
|
85864
86855
|
if (this._isHorizontal) {
|
|
85865
|
-
isNeedPreview && this._component.
|
|
86856
|
+
isNeedPreview && this._component.setPreviewPointsY1(this._dataToPositionY2);
|
|
85866
86857
|
}
|
|
85867
86858
|
else {
|
|
85868
|
-
isNeedPreview && this._component.
|
|
86859
|
+
isNeedPreview && this._component.setPreviewPointsX1(this._dataToPositionX2);
|
|
85869
86860
|
}
|
|
85870
86861
|
this._component.setStatePointToData((state) => this._statePointToData(state));
|
|
85871
86862
|
this._component.setUpdateStateCallback((start, end) => {
|
|
@@ -85876,6 +86867,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85876
86867
|
}
|
|
85877
86868
|
}
|
|
85878
86869
|
_handleChange(start, end, updateComponent) {
|
|
86870
|
+
super._handleChange(start, end, updateComponent);
|
|
85879
86871
|
if (updateComponent && this._component) {
|
|
85880
86872
|
this._component.setStartAndEnd(start, end);
|
|
85881
86873
|
}
|
|
@@ -85908,8 +86900,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85908
86900
|
}
|
|
85909
86901
|
}
|
|
85910
86902
|
}
|
|
85911
|
-
_initEvent() {
|
|
85912
|
-
}
|
|
85913
86903
|
_getComponentAttrs() {
|
|
85914
86904
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
|
|
85915
86905
|
return {
|
|
@@ -85979,6 +86969,17 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
85979
86969
|
this.layoutLevel = LayoutLevel.DataZoom;
|
|
85980
86970
|
this._filterMode = (_a = spec.filterMode) !== null && _a !== void 0 ? _a : IFilterMode.axis;
|
|
85981
86971
|
}
|
|
86972
|
+
setAttrFromSpec() {
|
|
86973
|
+
super.setAttrFromSpec();
|
|
86974
|
+
if (isBoolean$1(this._spec.roam)) {
|
|
86975
|
+
this._zoomAttr.enable = false;
|
|
86976
|
+
this._dragAttr.enable = this._spec.roam;
|
|
86977
|
+
this._scrollAttr.enable = this._spec.roam;
|
|
86978
|
+
}
|
|
86979
|
+
if (this._zoomAttr.enable || this._dragAttr.enable || this._scrollAttr.enable) {
|
|
86980
|
+
this.initZoomable(this.event, this._option.mode);
|
|
86981
|
+
}
|
|
86982
|
+
}
|
|
85982
86983
|
onLayoutEnd(ctx) {
|
|
85983
86984
|
var _a, _b;
|
|
85984
86985
|
this._updateScaleRange();
|
|
@@ -86014,13 +87015,19 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
86014
87015
|
return SCROLL_BAR_DEFAULT_SIZE;
|
|
86015
87016
|
}
|
|
86016
87017
|
_createOrUpdateComponent() {
|
|
87018
|
+
var _a, _b, _c, _d, _e, _f;
|
|
86017
87019
|
if (!this._component) {
|
|
86018
87020
|
const container = this.getContainer();
|
|
86019
|
-
this._component = new ScrollBar$1(Object.assign({ zIndex: this.layoutZIndex, x: this.getLayoutStartPoint().x, y: this.getLayoutStartPoint().y, width: this.getLayoutRect().width, height: this.getLayoutRect().height, range: [this._start, this._end], direction: this._isHorizontal ? 'horizontal' : 'vertical' }, this._getComponentAttrs()));
|
|
87021
|
+
this._component = new ScrollBar$1(Object.assign({ zIndex: this.layoutZIndex, x: this.getLayoutStartPoint().x, y: this.getLayoutStartPoint().y, width: this.getLayoutRect().width, height: this.getLayoutRect().height, range: [this._start, this._end], direction: this._isHorizontal ? 'horizontal' : 'vertical', delayType: (_a = this._spec) === null || _a === void 0 ? void 0 : _a.delayType, delayTime: isValid$1((_b = this._spec) === null || _b === void 0 ? void 0 : _b.delayType) ? (_d = (_c = this._spec) === null || _c === void 0 ? void 0 : _c.delayTime) !== null && _d !== void 0 ? _d : 30 : 0, realTime: (_f = (_e = this._spec) === null || _e === void 0 ? void 0 : _e.realTime) !== null && _f !== void 0 ? _f : true }, this._getComponentAttrs()));
|
|
87022
|
+
this._component.addEventListener('scroll', (e) => {
|
|
87023
|
+
const value = e.detail.value;
|
|
87024
|
+
this._handleChange(value[0], value[1]);
|
|
87025
|
+
});
|
|
86020
87026
|
container.add(this._component);
|
|
86021
87027
|
}
|
|
86022
87028
|
}
|
|
86023
87029
|
_handleChange(start, end, updateComponent) {
|
|
87030
|
+
super._handleChange(start, end, updateComponent);
|
|
86024
87031
|
if (updateComponent && this._component) {
|
|
86025
87032
|
this._component.setAttribute('range', [start, end]);
|
|
86026
87033
|
}
|
|
@@ -86043,7 +87050,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
86043
87050
|
}
|
|
86044
87051
|
_handleDataCollectionChange() {
|
|
86045
87052
|
}
|
|
86046
|
-
|
|
87053
|
+
_initCommonEvent() {
|
|
87054
|
+
super._initCommonEvent();
|
|
86047
87055
|
if (this._component) {
|
|
86048
87056
|
this._component.on('scroll', (e) => {
|
|
86049
87057
|
const value = e.detail.value;
|
|
@@ -86051,12 +87059,6 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
86051
87059
|
});
|
|
86052
87060
|
}
|
|
86053
87061
|
}
|
|
86054
|
-
_initCommonEvent() {
|
|
86055
|
-
if (this._spec.roam) {
|
|
86056
|
-
this.initScrollEventOfRegions(this._regions, null, this._handleChartScroll);
|
|
86057
|
-
this.initDragEventOfRegions(this._regions, null, this._handleChartDrag);
|
|
86058
|
-
}
|
|
86059
|
-
}
|
|
86060
87062
|
_getComponentAttrs() {
|
|
86061
87063
|
const { rail, slider, innerPadding } = this._spec;
|
|
86062
87064
|
const attrs = {};
|
|
@@ -89093,6 +90095,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
89093
90095
|
registerMapChart,
|
|
89094
90096
|
registerGaugeChart,
|
|
89095
90097
|
registerWordCloudChart,
|
|
90098
|
+
registerWordCloud3dChart,
|
|
89096
90099
|
registerFunnelChart,
|
|
89097
90100
|
registerWaterfallChart,
|
|
89098
90101
|
registerBoxplotChart,
|
|
@@ -89106,6 +90109,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
89106
90109
|
registerSankeyChart,
|
|
89107
90110
|
registerHeatmapChart,
|
|
89108
90111
|
registerSequenceChart,
|
|
90112
|
+
registerCorrelationChart,
|
|
89109
90113
|
registerCommonChart,
|
|
89110
90114
|
registerBar3dChart,
|
|
89111
90115
|
registerPie3dChart,
|
|
@@ -89177,6 +90181,8 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
89177
90181
|
exports.CommonChart = CommonChart;
|
|
89178
90182
|
exports.ComponentMark = ComponentMark;
|
|
89179
90183
|
exports.ContinuousLegend = ContinuousLegend;
|
|
90184
|
+
exports.CorrelationChart = CorrelationChart;
|
|
90185
|
+
exports.CorrelationSeries = CorrelationSeries;
|
|
89180
90186
|
exports.CustomMark = CustomMark;
|
|
89181
90187
|
exports.DataZoom = DataZoom;
|
|
89182
90188
|
exports.DiscreteLegend = DiscreteLegend;
|
|
@@ -89240,6 +90246,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
89240
90246
|
exports.RangeColumnSeries = RangeColumnSeries;
|
|
89241
90247
|
exports.Rect3dMark = Rect3dMark;
|
|
89242
90248
|
exports.RectMark = RectMark;
|
|
90249
|
+
exports.RippleMark = RippleMark;
|
|
89243
90250
|
exports.RoseChart = RoseChart;
|
|
89244
90251
|
exports.RoseLikeChart = RoseLikeChart;
|
|
89245
90252
|
exports.RoseLikeSeries = RoseLikeSeries;
|
|
@@ -89292,6 +90299,7 @@ C0.3-1.4,0.3-1.4,0.3-1.4z;`;
|
|
|
89292
90299
|
exports.registerCircularProgressSeries = registerCircularProgressSeries;
|
|
89293
90300
|
exports.registerCommonChart = registerCommonChart;
|
|
89294
90301
|
exports.registerContinuousLegend = registerContinuousLegend;
|
|
90302
|
+
exports.registerCorrelationChart = registerCorrelationChart;
|
|
89295
90303
|
exports.registerCustomMark = registerCustomMark;
|
|
89296
90304
|
exports.registerDataZoom = registerDataZoom;
|
|
89297
90305
|
exports.registerDiscreteLegend = registerDiscreteLegend;
|