@visactor/vchart-types 1.15.5-alpha.8 → 2.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/tsconfig.tsbuildinfo +1 -1
- package/types/animation/animate-manager.d.ts +2 -4
- package/types/animation/interface.d.ts +86 -2
- package/types/animation/spec.d.ts +27 -3
- package/types/animation/utils.d.ts +3 -4
- package/types/chart/base/base-chart.d.ts +10 -7
- package/types/chart/funnel/util.d.ts +2 -0
- package/types/chart/interface/chart.d.ts +3 -4
- package/types/chart/interface/common.d.ts +2 -9
- package/types/chart/sankey/sankey.d.ts +1 -1
- package/types/compile/compilable-base.d.ts +1 -1
- package/types/compile/compiler.d.ts +35 -25
- package/types/compile/data/compilable-data.d.ts +7 -7
- package/types/compile/data/interface.d.ts +4 -1
- package/types/compile/grammar-item.d.ts +7 -13
- package/types/compile/interface/compilable-item.d.ts +22 -28
- package/types/compile/interface/compiler.d.ts +13 -4
- package/types/compile/mark/index.d.ts +0 -1
- package/types/compile/mark/interface.d.ts +42 -33
- package/types/compile/mark/mark-state-manager.d.ts +11 -13
- package/types/compile/mark/util.d.ts +1 -1
- package/types/compile/state-manager.d.ts +11 -0
- package/types/compile/util.d.ts +14 -0
- package/types/component/axis/base-axis.d.ts +5 -3
- package/types/component/axis/cartesian/axis.d.ts +1 -1
- package/types/component/axis/cartesian/time-axis.d.ts +1 -0
- package/types/component/axis/interface/common.d.ts +8 -0
- package/types/component/base/base-component.d.ts +1 -2
- package/types/component/brush/brush.d.ts +12 -10
- package/types/component/crosshair/base.d.ts +25 -36
- package/types/component/crosshair/cartesian.d.ts +5 -28
- package/types/component/crosshair/interface/common.d.ts +67 -2
- package/types/component/crosshair/interface/index.d.ts +0 -2
- package/types/component/crosshair/interface/spec.d.ts +8 -4
- package/types/component/crosshair/polar.d.ts +6 -22
- package/types/component/crosshair/utils/cartesian.d.ts +5 -26
- package/types/component/crosshair/utils/polar.d.ts +18 -11
- package/types/component/data-zoom/data-filter-base-component.d.ts +4 -4
- package/types/component/data-zoom/data-zoom/data-zoom.d.ts +1 -1
- package/types/component/data-zoom/interface.d.ts +11 -0
- package/types/component/data-zoom/scroll-bar/scroll-bar.d.ts +1 -2
- package/types/component/geo/geo-coordinate.d.ts +2 -2
- package/types/component/geo/interface.d.ts +1 -1
- package/types/component/label/base-label.d.ts +5 -0
- package/types/component/label/interface.d.ts +4 -3
- package/types/component/label/label.d.ts +5 -3
- package/types/component/label/util.d.ts +9 -10
- package/types/component/legend/util.d.ts +3 -3
- package/types/component/marker/base-marker.d.ts +1 -1
- package/types/component/tooltip/processor/interface.d.ts +1 -1
- package/types/component/tooltip/processor/util.d.ts +1 -1
- package/types/component/tooltip/tooltip.d.ts +3 -3
- package/types/constant/data.d.ts +1 -0
- package/types/constant/event.d.ts +53 -2
- package/types/core/factory.d.ts +28 -3
- package/types/core/index.d.ts +2 -1
- package/types/core/interface.d.ts +13 -4
- package/types/core/vchart.d.ts +6 -6
- package/types/data/transforms/treemap.d.ts +5 -6
- package/types/data/transforms/venn.d.ts +10 -0
- package/types/data/transforms/waterfall.d.ts +1 -0
- package/types/event/events/base.d.ts +1 -2
- package/types/event/index.d.ts +1 -0
- package/types/event/interface.d.ts +6 -9
- package/types/index-harmony-simple.d.ts +2 -1
- package/types/index.d.ts +0 -1
- package/types/interaction/config.d.ts +13 -0
- package/types/interaction/index.d.ts +9 -1
- package/types/interaction/interaction.d.ts +17 -25
- package/types/interaction/interface/common.d.ts +22 -0
- package/types/interaction/interface/spec.d.ts +53 -0
- package/types/interaction/interface/trigger.d.ts +87 -0
- package/types/interaction/triggers/base.d.ts +28 -0
- package/types/interaction/triggers/dimension-hover.d.ts +22 -0
- package/types/interaction/triggers/element-active-by-legend.d.ts +21 -0
- package/types/interaction/triggers/element-active.d.ts +20 -0
- package/types/interaction/triggers/element-highlight-by-graphic-name.d.ts +13 -0
- package/types/interaction/triggers/element-highlight-by-group.d.ts +23 -0
- package/types/interaction/triggers/element-highlight-by-key.d.ts +9 -0
- package/types/interaction/triggers/element-highlight-by-legend.d.ts +22 -0
- package/types/interaction/triggers/element-highlight-by-name.d.ts +24 -0
- package/types/interaction/triggers/element-highlight.d.ts +25 -0
- package/types/interaction/triggers/element-select-by-graphic-name.d.ts +8 -0
- package/types/interaction/triggers/element-select.d.ts +24 -0
- package/types/interaction/triggers/enum.d.ts +8 -0
- package/types/interaction/triggers/util.d.ts +12 -0
- package/types/interaction/zoom/zoomable.d.ts +1 -0
- package/types/layout/interface.d.ts +2 -2
- package/types/layout/layout-item.d.ts +2 -3
- package/types/mark/arc.d.ts +2 -2
- package/types/mark/area.d.ts +2 -0
- package/types/mark/base/base-line.d.ts +16 -2
- package/types/mark/base/base-mark.d.ts +131 -13
- package/types/mark/box-plot.d.ts +11 -5
- package/types/mark/cell.d.ts +5 -2
- package/types/mark/component.d.ts +11 -3
- package/types/mark/glyph.d.ts +29 -0
- package/types/mark/group.d.ts +10 -6
- package/types/mark/index.d.ts +3 -1
- package/types/mark/interface/common.d.ts +61 -9
- package/types/mark/interface/enum.d.ts +6 -0
- package/types/mark/interface/index.d.ts +1 -0
- package/types/mark/interface/mark.d.ts +18 -1
- package/types/mark/interface/type.d.ts +1 -0
- package/types/mark/label.d.ts +4 -3
- package/types/mark/link-path.d.ts +35 -5
- package/types/mark/liquid.d.ts +47 -5
- package/types/mark/ripple.d.ts +39 -4
- package/types/mark/rule.d.ts +3 -0
- package/types/mark/symbol.d.ts +4 -4
- package/types/mark/text.d.ts +4 -2
- package/types/mark/transform/data-sampling.d.ts +10 -0
- package/types/mark/transform/filter.d.ts +1 -0
- package/types/mark/transform/map.d.ts +1 -0
- package/types/mark/transform/symbol-overlap.d.ts +14 -0
- package/types/mark/utils/common.d.ts +4 -0
- package/types/mark/utils/glyph.d.ts +2 -0
- package/types/mark/utils/index.d.ts +2 -0
- package/types/mark/utils/line.d.ts +3 -0
- package/types/model/base-model.d.ts +8 -8
- package/types/model/interface.d.ts +4 -8
- package/types/model/layout-model.d.ts +2 -2
- package/types/plugin/components/tooltip-handler/base.d.ts +2 -2
- package/types/plugin/components/tooltip-handler/utils/position.d.ts +2 -4
- package/types/plugin/other.d.ts +3 -3
- package/types/region/interface.d.ts +0 -2
- package/types/region/region.d.ts +3 -9
- package/types/series/area/animation.d.ts +1 -1
- package/types/series/area/area.d.ts +1 -1
- package/types/series/bar/animation.d.ts +1 -1
- package/types/series/bar/bar.d.ts +3 -3
- package/types/series/base/base-series.d.ts +26 -42
- package/types/series/base/tooltip-helper.d.ts +1 -2
- package/types/series/box-plot/box-plot.d.ts +3 -3
- package/types/series/cartesian/cartesian.d.ts +1 -1
- package/types/series/circle-packing/animation.d.ts +1 -1
- package/types/series/circle-packing/circle-packing.d.ts +1 -1
- package/types/series/correlation/animation.d.ts +1 -1
- package/types/series/correlation/correlation.d.ts +3 -4
- package/types/series/dot/dot.d.ts +2 -2
- package/types/series/funnel/funnel.d.ts +3 -2
- package/types/series/funnel/tooltip-helper.d.ts +1 -1
- package/types/series/gauge/animation.d.ts +1 -1
- package/types/series/gauge/gauge-pointer.d.ts +4 -1
- package/types/series/gauge/gauge.d.ts +2 -2
- package/types/series/geo/geo.d.ts +2 -2
- package/types/series/heatmap/animation.d.ts +1 -1
- package/types/series/heatmap/heatmap.d.ts +4 -1
- package/types/series/interface/common.d.ts +1 -4
- package/types/series/interface/series.d.ts +6 -1
- package/types/series/line/animation.d.ts +1 -1
- package/types/series/line/line.d.ts +1 -1
- package/types/series/link/link.d.ts +5 -2
- package/types/series/liquid/animation.d.ts +1 -1
- package/types/series/liquid/liquid.d.ts +4 -1
- package/types/series/map/interface.d.ts +10 -0
- package/types/series/mixin/line-mixin.d.ts +5 -5
- package/types/series/pictogram/pictogram.d.ts +15 -19
- package/types/series/pie/animation/animation.d.ts +4 -3
- package/types/series/pie/animation/centerOffset.d.ts +1 -1
- package/types/series/pie/interface.d.ts +2 -2
- package/types/series/pie/pie.d.ts +8 -6
- package/types/series/polar/progress-like/animation.d.ts +1 -1
- package/types/series/polar/progress-like/progress-like.d.ts +1 -2
- package/types/series/progress/circular/circular.d.ts +4 -1
- package/types/series/progress/linear/animation.d.ts +1 -1
- package/types/series/progress/linear/linear.d.ts +4 -1
- package/types/series/radar/animation.d.ts +11 -9
- package/types/series/radar/radar.d.ts +2 -2
- package/types/series/range-column/animation.d.ts +1 -1
- package/types/series/rose/animation.d.ts +1 -1
- package/types/series/sankey/animation.d.ts +1 -1
- package/types/series/sankey/sankey.d.ts +11 -12
- package/types/series/sankey/tooltip-helper.d.ts +1 -1
- package/types/series/scatter/animation.d.ts +1 -1
- package/types/series/sunburst/animation/enter.d.ts +1 -1
- package/types/series/sunburst/animation/exit.d.ts +1 -1
- package/types/series/sunburst/animation/preset.d.ts +1 -1
- package/types/series/sunburst/animation/utils.d.ts +2 -2
- package/types/series/sunburst/sunburst.d.ts +1 -1
- package/types/series/treemap/animation.d.ts +1 -1
- package/types/series/treemap/treemap.d.ts +1 -2
- package/types/series/venn/animation.d.ts +1 -1
- package/types/series/venn/venn.d.ts +2 -1
- package/types/series/waterfall/animation.d.ts +1 -1
- package/types/series/waterfall/waterfall.d.ts +2 -2
- package/types/series/word-cloud/animation.d.ts +1 -1
- package/types/series/word-cloud/base.d.ts +1 -1
- package/types/series/word-cloud/interface.d.ts +1 -1
- package/types/typings/common.d.ts +13 -0
- package/types/typings/spec/common.d.ts +37 -36
- package/types/typings/visual.d.ts +9 -2
- package/types/util/array.d.ts +1 -0
- package/types/util/index.d.ts +1 -0
- package/types/util/mark.d.ts +5 -0
- package/types/util/math.d.ts +1 -1
|
@@ -1,20 +1,19 @@
|
|
|
1
1
|
import type { IPoint, Datum, StateValueType } from '../../typings';
|
|
2
|
-
import type { IModelLayoutOption } from '../../model/interface';
|
|
3
2
|
import { PolarSeries } from '../polar/polar';
|
|
4
3
|
import type { IArcMark, IMark, IPathMark, ITextMark } from '../../mark/interface';
|
|
5
4
|
import { MarkTypeEnum } from '../../mark/interface/type';
|
|
6
5
|
import type { IArcSeries, SeriesMarkMap } from '../interface';
|
|
7
6
|
import { SeriesMarkNameEnum, SeriesTypeEnum } from '../interface/type';
|
|
8
7
|
import type { IBasePieSeriesSpec, IPieSeriesSpec } from './interface';
|
|
9
|
-
import { SeriesData } from '../base/series-data';
|
|
10
8
|
import { PieSeriesSpecTransformer } from './pie-transformer';
|
|
9
|
+
import type { ICompilableData } from '../../compile/data';
|
|
11
10
|
export declare class BasePieSeries<T extends IBasePieSeriesSpec> extends PolarSeries<T> implements IArcSeries {
|
|
12
11
|
static readonly transformerConstructor: any;
|
|
13
12
|
readonly transformerConstructor: typeof PieSeriesSpecTransformer;
|
|
14
13
|
protected _pieMarkName: SeriesMarkNameEnum;
|
|
15
14
|
protected _pieMarkType: MarkTypeEnum;
|
|
16
15
|
static readonly mark: SeriesMarkMap;
|
|
17
|
-
protected _viewDataLabel:
|
|
16
|
+
protected _viewDataLabel: ICompilableData;
|
|
18
17
|
getCenter: () => IPoint;
|
|
19
18
|
protected _centerOffset: number;
|
|
20
19
|
protected _cornerRadius: number;
|
|
@@ -37,14 +36,17 @@ export declare class BasePieSeries<T extends IBasePieSeriesSpec> extends PolarSe
|
|
|
37
36
|
private endAngleScale;
|
|
38
37
|
protected _computeLayoutRadius(): number;
|
|
39
38
|
initMarkStyle(): void;
|
|
40
|
-
|
|
39
|
+
getInteractionTriggers(): {
|
|
40
|
+
trigger: Partial<import("../../interaction/interface/trigger").IBaseTriggerOptions>;
|
|
41
|
+
marks: IMark[];
|
|
42
|
+
}[];
|
|
41
43
|
protected initTooltip(): void;
|
|
42
|
-
initMarkStyleWithSpec(mark?: IMark, spec?: any
|
|
44
|
+
initMarkStyleWithSpec(mark?: IMark, spec?: any): void;
|
|
43
45
|
initLabelMarkStyle(textMark: ITextMark): void;
|
|
44
46
|
afterInitMark(): void;
|
|
45
47
|
initEvent(): void;
|
|
46
48
|
initGroups(): void;
|
|
47
|
-
onLayoutEnd(
|
|
49
|
+
onLayoutEnd(): void;
|
|
48
50
|
getDimensionField(): string[];
|
|
49
51
|
getMeasureField(): string[];
|
|
50
52
|
private viewDataLabelUpdate;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '
|
|
1
|
+
import type { IAnimationTypeConfig } from '../../../animation/interface';
|
|
2
2
|
import type { IProgressLikeAnimationParams, ProgressLikeAppearPreset } from './interface';
|
|
3
3
|
export declare function progressLikePresetAnimation(params: IProgressLikeAnimationParams, preset: ProgressLikeAppearPreset): IAnimationTypeConfig;
|
|
4
4
|
export declare const registerProgressLikeAnimation: () => void;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type { Datum } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { IGroupMark, IMarkStyle } from '../../../mark/interface';
|
|
3
|
-
import type { ConvertToMarkStyleSpec, ICommonSpec } from '../../../typings';
|
|
2
|
+
import type { ConvertToMarkStyleSpec, Datum, ICommonSpec } from '../../../typings';
|
|
4
3
|
import { PolarSeries } from '../polar';
|
|
5
4
|
import type { IContinuousTickData, IProgressLikeSeriesSpec } from './interface';
|
|
6
5
|
import type { IPolarAxis } from '../../../component/axis';
|
|
@@ -19,7 +19,10 @@ export declare class CircularProgressSeries<T extends ICircularProgressSeriesSpe
|
|
|
19
19
|
initMarkStyle(): void;
|
|
20
20
|
private _initProgressMark;
|
|
21
21
|
private _initProgressMarkStyle;
|
|
22
|
-
|
|
22
|
+
getInteractionTriggers(): {
|
|
23
|
+
trigger: Partial<import("../../../interaction/interface/trigger").IBaseTriggerOptions>;
|
|
24
|
+
marks: IMark[];
|
|
25
|
+
}[];
|
|
23
26
|
protected initTooltip(): void;
|
|
24
27
|
private _initTrackMark;
|
|
25
28
|
private _initTrackMarkStyle;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { ILinearProgressAnimationParams, LinearProgressAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../../animation/interface';
|
|
3
3
|
export declare const linearProgressDisappear: (params: ILinearProgressAnimationParams) => IAnimationTypeConfig;
|
|
4
4
|
export declare const Appear_FadeIn: IAnimationTypeConfig;
|
|
5
5
|
export declare function linearProgressPresetAnimation(params: ILinearProgressAnimationParams, preset: LinearProgressAppearPreset | boolean): IAnimationTypeConfig;
|
|
@@ -16,7 +16,10 @@ export declare class LinearProgressSeries<T extends ILinearProgressSeriesSpec =
|
|
|
16
16
|
private _defaultProgressCustomShape;
|
|
17
17
|
private _initTrackMark;
|
|
18
18
|
private _initTrackMarkStyle;
|
|
19
|
-
|
|
19
|
+
getInteractionTriggers(): {
|
|
20
|
+
trigger: Partial<import("../../../interaction/interface/trigger").IBaseTriggerOptions>;
|
|
21
|
+
marks: IMark[];
|
|
22
|
+
}[];
|
|
20
23
|
initAnimation(): void;
|
|
21
24
|
protected initTooltip(): void;
|
|
22
25
|
getActiveMarks(): IMark[];
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { IGraphic } from '@visactor/vrender-core';
|
|
2
2
|
import type { IRadarAnimationParams, RadarAppearPreset } from './interface';
|
|
3
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
4
|
+
import type { Datum } from '../../typings/common';
|
|
3
5
|
export declare const radarFadeAnimation: (animationType: 'in' | 'out') => {
|
|
4
6
|
type: string;
|
|
5
7
|
};
|
|
@@ -16,21 +18,21 @@ export declare const radarSymbolMoveAnimation: (params: IRadarAnimationParams, a
|
|
|
16
18
|
channel: {
|
|
17
19
|
x: {
|
|
18
20
|
from: () => number;
|
|
19
|
-
to: (datum: Datum, element:
|
|
21
|
+
to: (datum: Datum, element: IGraphic) => any;
|
|
20
22
|
};
|
|
21
23
|
y: {
|
|
22
24
|
from: () => number;
|
|
23
|
-
to: (datum: Datum, element:
|
|
25
|
+
to: (datum: Datum, element: IGraphic) => any;
|
|
24
26
|
};
|
|
25
27
|
};
|
|
26
28
|
} | {
|
|
27
29
|
channel: {
|
|
28
30
|
x: {
|
|
29
|
-
from: (datum: Datum, element:
|
|
31
|
+
from: (datum: Datum, element: IGraphic) => any;
|
|
30
32
|
to: () => number;
|
|
31
33
|
};
|
|
32
34
|
y: {
|
|
33
|
-
from: (datum: Datum, element:
|
|
35
|
+
from: (datum: Datum, element: IGraphic) => any;
|
|
34
36
|
to: () => number;
|
|
35
37
|
};
|
|
36
38
|
};
|
|
@@ -41,21 +43,21 @@ export declare function radarSymbolPresetAnimation(params: IRadarAnimationParams
|
|
|
41
43
|
channel: {
|
|
42
44
|
x: {
|
|
43
45
|
from: () => number;
|
|
44
|
-
to: (datum:
|
|
46
|
+
to: (datum: Datum, element: IGraphic<Partial<import("@visactor/vrender-core").IGraphicAttribute>>) => any;
|
|
45
47
|
};
|
|
46
48
|
y: {
|
|
47
49
|
from: () => number;
|
|
48
|
-
to: (datum:
|
|
50
|
+
to: (datum: Datum, element: IGraphic<Partial<import("@visactor/vrender-core").IGraphicAttribute>>) => any;
|
|
49
51
|
};
|
|
50
52
|
};
|
|
51
53
|
} | {
|
|
52
54
|
channel: {
|
|
53
55
|
x: {
|
|
54
|
-
from: (datum:
|
|
56
|
+
from: (datum: Datum, element: IGraphic<Partial<import("@visactor/vrender-core").IGraphicAttribute>>) => any;
|
|
55
57
|
to: () => number;
|
|
56
58
|
};
|
|
57
59
|
y: {
|
|
58
|
-
from: (datum:
|
|
60
|
+
from: (datum: Datum, element: IGraphic<Partial<import("@visactor/vrender-core").IGraphicAttribute>>) => any;
|
|
59
61
|
to: () => number;
|
|
60
62
|
};
|
|
61
63
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { LineLikeSeriesMixin } from '../mixin/line-mixin';
|
|
2
|
-
import type { IMark
|
|
2
|
+
import type { IMark } from '../../mark/interface';
|
|
3
3
|
import type { Datum } from '../../typings';
|
|
4
4
|
import type { SeriesMarkMap } from '../interface';
|
|
5
5
|
import { SeriesTypeEnum } from '../interface/type';
|
|
@@ -20,7 +20,7 @@ export declare class RadarSeries<T extends IRadarSeriesSpec = IRadarSeriesSpec>
|
|
|
20
20
|
compile(): void;
|
|
21
21
|
initMark(): void;
|
|
22
22
|
initMarkStyle(): void;
|
|
23
|
-
initAreaMark(
|
|
23
|
+
initAreaMark(isSeriesMark: boolean): void;
|
|
24
24
|
initAreaMarkStyle(): void;
|
|
25
25
|
protected initTooltip(): void;
|
|
26
26
|
initAnimation(): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '
|
|
1
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
2
2
|
import type { IRangeColumnAnimationParams, RangeColumnAppearPreset } from './interface';
|
|
3
3
|
export declare const rangeColumnGrowIn: (params: IRangeColumnAnimationParams) => IAnimationTypeConfig;
|
|
4
4
|
export declare const rangeColumnGrowOut: (params: IRangeColumnAnimationParams) => IAnimationTypeConfig;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { IRoseAnimationParams, RoseAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
3
3
|
export declare const Appear_Grow: (params: IRoseAnimationParams) => IAnimationTypeConfig;
|
|
4
4
|
export declare const Appear_FadeIn: IAnimationTypeConfig;
|
|
5
5
|
export declare const roseEnter: (params: IRoseAnimationParams) => IAnimationTypeConfig;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { ISankeyAnimationParams, SankeyAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
3
3
|
export declare const sankeyGrowIn: (params: ISankeyAnimationParams, isOverall?: boolean) => IAnimationTypeConfig;
|
|
4
4
|
export declare const sankeyGrowOut: (params: ISankeyAnimationParams, isOverall?: boolean) => IAnimationTypeConfig;
|
|
5
5
|
export declare const sankeyNodePresetAnimation: (params: ISankeyAnimationParams, preset: SankeyAppearPreset) => IAnimationTypeConfig;
|
|
@@ -2,11 +2,10 @@ import { CartesianSeries } from '../cartesian/cartesian';
|
|
|
2
2
|
import type { SeriesMarkMap } from '../interface';
|
|
3
3
|
import { SeriesTypeEnum } from '../interface/type';
|
|
4
4
|
import type { Datum, StringOrNumber } from '../../typings';
|
|
5
|
-
import {
|
|
5
|
+
import { DataView } from '@visactor/vdataset';
|
|
6
6
|
import type { ISankeySeriesSpec } from './interface';
|
|
7
7
|
import type { ExtendEventParam } from '../../event/interface';
|
|
8
|
-
import type {
|
|
9
|
-
import type { IMark, ITextMark } from '../../mark/interface';
|
|
8
|
+
import type { IMark, IMarkGraphic, ITextMark } from '../../mark/interface';
|
|
10
9
|
import { SankeySeriesSpecTransformer } from './sankey-transformer';
|
|
11
10
|
import type { ILabelSpec } from '../../component';
|
|
12
11
|
export declare class SankeySeries<T extends ISankeySeriesSpec = ISankeySeriesSpec> extends CartesianSeries<T> {
|
|
@@ -19,14 +18,14 @@ export declare class SankeySeries<T extends ISankeySeriesSpec = ISankeySeriesSpe
|
|
|
19
18
|
private _linkMark;
|
|
20
19
|
private _nodeLayoutZIndex;
|
|
21
20
|
private _labelLayoutZIndex;
|
|
22
|
-
protected _nodesSeriesData?:
|
|
23
|
-
protected _linksSeriesData?:
|
|
21
|
+
protected _nodesSeriesData?: DataView;
|
|
22
|
+
protected _linksSeriesData?: DataView;
|
|
24
23
|
private _viewBox;
|
|
25
24
|
protected _categoryField: string;
|
|
26
25
|
private _colorScale;
|
|
27
26
|
private _nodeList;
|
|
28
27
|
private _needClear;
|
|
29
|
-
get direction(): "
|
|
28
|
+
get direction(): "horizontal" | "vertical";
|
|
30
29
|
getCategoryField(): string;
|
|
31
30
|
setCategoryField(f: string): string;
|
|
32
31
|
protected _valueField: string;
|
|
@@ -54,11 +53,11 @@ export declare class SankeySeries<T extends ISankeySeriesSpec = ISankeySeriesSpe
|
|
|
54
53
|
private linksSeriesDataUpdate;
|
|
55
54
|
protected _handleEmphasisElement: (params: ExtendEventParam) => void;
|
|
56
55
|
protected _handleClearEmpty: () => void;
|
|
57
|
-
protected _handleNodeAdjacencyClick: (
|
|
58
|
-
protected _handleLinkAdjacencyClick: (
|
|
59
|
-
protected _handleNodeRelatedClick: (
|
|
60
|
-
protected _handleLinkRelatedClick: (
|
|
61
|
-
protected _highLightElements(
|
|
56
|
+
protected _handleNodeAdjacencyClick: (graphic: IMarkGraphic) => void;
|
|
57
|
+
protected _handleLinkAdjacencyClick: (graphic: IMarkGraphic) => void;
|
|
58
|
+
protected _handleNodeRelatedClick: (graphic: IMarkGraphic) => void;
|
|
59
|
+
protected _handleLinkRelatedClick: (graphic: IMarkGraphic) => void;
|
|
60
|
+
protected _highLightElements(graphics: IMarkGraphic[], highlightNodes: string[]): void;
|
|
62
61
|
protected initTooltip(): void;
|
|
63
62
|
_setNodeOrdinalColorScale(): void;
|
|
64
63
|
getNodeList(): any;
|
|
@@ -73,7 +72,7 @@ export declare class SankeySeries<T extends ISankeySeriesSpec = ISankeySeriesSpe
|
|
|
73
72
|
max?: number;
|
|
74
73
|
};
|
|
75
74
|
private _collectByField;
|
|
76
|
-
onLayoutEnd(
|
|
75
|
+
onLayoutEnd(): void;
|
|
77
76
|
getDefaultShapeType(): string;
|
|
78
77
|
protected _noAnimationDataKey(datum: Datum, index: number): unknown | undefined;
|
|
79
78
|
getActiveMarks(): IMark[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ISeriesTooltipHelper } from '../interface';
|
|
2
2
|
import { BaseSeriesTooltipHelper } from '../base/tooltip-helper';
|
|
3
|
-
import type { Datum } from '
|
|
3
|
+
import type { Datum } from '../../typings/common';
|
|
4
4
|
export declare class SankeySeriesTooltipHelper extends BaseSeriesTooltipHelper implements ISeriesTooltipHelper {
|
|
5
5
|
protected _getDimensionData: (datum: any) => any;
|
|
6
6
|
markTooltipValueCallback: (datum: Datum) => string | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { IScatterAnimationParams, ScatterAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
3
3
|
export declare const scatterPresetAnimation: (_params: IScatterAnimationParams, preset: ScatterAppearPreset) => IAnimationTypeConfig;
|
|
4
4
|
export declare const registerScatterAnimation: () => void;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { ISunburstAnimationParams } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../../animation/interface';
|
|
3
3
|
export declare const sunburstEnter: (params: ISunburstAnimationParams) => IAnimationTypeConfig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { ISunburstAnimationParams } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../../animation/interface';
|
|
3
3
|
export declare const sunburstExit: (params: ISunburstAnimationParams) => IAnimationTypeConfig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '
|
|
1
|
+
import type { IAnimationTypeConfig } from '../../../animation/interface';
|
|
2
2
|
import type { ISunburstAnimationParams, SunburstAppearPreset } from './interface';
|
|
3
3
|
export declare const sunburstPresetAnimation: (_params: ISunburstAnimationParams, preset: SunburstAppearPreset) => IAnimationTypeConfig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { IMarkGraphic } from '../../../mark/interface/common';
|
|
2
2
|
export declare const computeRatio: (angle: number, range: [number, number]) => number;
|
|
3
|
-
export declare const getInnerMostElements: (
|
|
3
|
+
export declare const getInnerMostElements: (graphics: IMarkGraphic[]) => IMarkGraphic[];
|
|
@@ -48,7 +48,7 @@ export declare class SunburstSeries extends PolarSeries<any> {
|
|
|
48
48
|
protected initTooltip(): void;
|
|
49
49
|
initAnimation(): void;
|
|
50
50
|
initEvent(): void;
|
|
51
|
-
onLayoutEnd(
|
|
51
|
+
onLayoutEnd(): void;
|
|
52
52
|
private _computeRadius;
|
|
53
53
|
private _computeLevel;
|
|
54
54
|
getGroupFields(): string[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '
|
|
1
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
2
2
|
import type { TreemapAppearPreset } from './interface';
|
|
3
3
|
export declare const treemapPresetAnimation: (preset: TreemapAppearPreset) => IAnimationTypeConfig;
|
|
4
4
|
export declare const registerTreemapAnimation: () => void;
|
|
@@ -30,7 +30,6 @@ export declare class TreemapSeries extends CartesianSeries<any> {
|
|
|
30
30
|
private _enableAnimationHook;
|
|
31
31
|
setAttrFromSpec(): void;
|
|
32
32
|
initData(): void;
|
|
33
|
-
compile(): void;
|
|
34
33
|
protected _runTreemapTransform(render?: boolean): void;
|
|
35
34
|
protected _addDataIndexAndKey(): void;
|
|
36
35
|
getRawDataStatisticsByField(field: string, isNumeric?: boolean): {
|
|
@@ -59,7 +58,7 @@ export declare class TreemapSeries extends CartesianSeries<any> {
|
|
|
59
58
|
handleZoom(event: ZoomEventParam): void;
|
|
60
59
|
getDimensionField(): string[];
|
|
61
60
|
getMeasureField(): string[];
|
|
62
|
-
onLayoutEnd(
|
|
61
|
+
onLayoutEnd(): void;
|
|
63
62
|
protected enableMarkAnimation(): void;
|
|
64
63
|
protected disableMarkAnimation(): void;
|
|
65
64
|
getDefaultShapeType(): string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { VennAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
3
3
|
export declare const vennCirclePresetAnimation: (preset: VennAppearPreset) => IAnimationTypeConfig;
|
|
4
4
|
export declare const vennOverlapPresetAnimation: (preset: VennAppearPreset) => IAnimationTypeConfig;
|
|
5
5
|
export declare const registerVennAnimation: () => void;
|
|
@@ -24,6 +24,7 @@ export declare class VennSeries<T extends IVennSeriesSpec = IVennSeriesSpec> ext
|
|
|
24
24
|
getValueField(): string;
|
|
25
25
|
setValueField(f: string): string;
|
|
26
26
|
setAttrFromSpec(): void;
|
|
27
|
+
initData(): void;
|
|
27
28
|
compile(): void;
|
|
28
29
|
protected _runVennTransform(render?: boolean): void;
|
|
29
30
|
initMark(): void;
|
|
@@ -35,7 +36,7 @@ export declare class VennSeries<T extends IVennSeriesSpec = IVennSeriesSpec> ext
|
|
|
35
36
|
protected initTooltip(): void;
|
|
36
37
|
getDimensionField(): string[];
|
|
37
38
|
getMeasureField(): string[];
|
|
38
|
-
onLayoutEnd(
|
|
39
|
+
onLayoutEnd(): void;
|
|
39
40
|
getDefaultShapeType(): string;
|
|
40
41
|
getActiveMarks(): IMark[];
|
|
41
42
|
getStatisticFields(): {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { IBarAnimationParams } from '../bar/interface';
|
|
3
2
|
import type { WaterfallAppearPreset } from './interface';
|
|
3
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
4
4
|
export declare function waterfallPresetAnimation(params: IBarAnimationParams, preset: WaterfallAppearPreset): IAnimationTypeConfig;
|
|
5
5
|
export declare const registerWaterfallAnimation: () => void;
|
|
@@ -3,11 +3,11 @@ import type { IWaterfallSeriesSpec } from './interface';
|
|
|
3
3
|
import type { SeriesMarkMap } from '../interface';
|
|
4
4
|
import { SeriesTypeEnum } from '../interface/type';
|
|
5
5
|
import type { ITransformOptions, DataView } from '@visactor/vdataset';
|
|
6
|
-
import { SeriesData } from '../base/series-data';
|
|
7
6
|
import type { IModelEvaluateOption } from '../../model/interface';
|
|
8
7
|
import type { Datum } from '../../typings';
|
|
9
8
|
import type { ILabelMark, IRuleMark, ITextMark } from '../../mark/interface';
|
|
10
9
|
import type { ILabelInfo } from '../../component/label/interface';
|
|
10
|
+
import { type ICompilableData } from '../../compile/data';
|
|
11
11
|
export declare const DefaultBandWidth = 6;
|
|
12
12
|
export declare class WaterfallSeries<T extends IWaterfallSeriesSpec = IWaterfallSeriesSpec> extends BarSeries<any> {
|
|
13
13
|
static readonly type: string;
|
|
@@ -15,7 +15,7 @@ export declare class WaterfallSeries<T extends IWaterfallSeriesSpec = IWaterfall
|
|
|
15
15
|
static readonly mark: SeriesMarkMap;
|
|
16
16
|
static readonly transformerConstructor: any;
|
|
17
17
|
readonly transformerConstructor: any;
|
|
18
|
-
protected _totalData?:
|
|
18
|
+
protected _totalData?: ICompilableData;
|
|
19
19
|
getTotalData(): any;
|
|
20
20
|
protected _spec: T;
|
|
21
21
|
protected _leaderLineMark: IRuleMark;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { IAnimationTypeConfig } from '@visactor/vgrammar-core';
|
|
2
1
|
import type { IWordcloud3dAnimationParams, IWordcloudAnimationParams, WordcloudAppearPreset } from './interface';
|
|
2
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
3
3
|
export declare const WordCloud3dAnimation: (params: IWordcloud3dAnimationParams | (() => any)) => IAnimationTypeConfig;
|
|
4
4
|
export declare const WordCloudScaleInAnimation: (params: IWordcloudAnimationParams) => IAnimationTypeConfig;
|
|
5
5
|
export declare function wordcloudPresetAnimation(params: IWordcloudAnimationParams, preset: WordcloudAppearPreset | boolean): IAnimationTypeConfig;
|
|
@@ -60,7 +60,7 @@ export declare class BaseWordCloudSeries<T extends IBaseWordCloudSeriesSpec = IB
|
|
|
60
60
|
getGroupFields(): string[];
|
|
61
61
|
getStackGroupFields(): string[];
|
|
62
62
|
getStackValueField(): string;
|
|
63
|
-
onLayoutEnd(
|
|
63
|
+
onLayoutEnd(): void;
|
|
64
64
|
getActiveMarks(): IMark[];
|
|
65
65
|
reInit(): void;
|
|
66
66
|
}
|
|
@@ -3,7 +3,7 @@ import type { IAnimationSpec, IMarkAnimateSpec, IStateAnimateSpec } from '../../
|
|
|
3
3
|
import type { SeriesMarkNameEnum } from '../interface/type';
|
|
4
4
|
import type { shapes } from '@visactor/vgrammar-wordcloud';
|
|
5
5
|
import type { GeometricMaskShape, TextShapeMask } from '@visactor/vgrammar-util';
|
|
6
|
-
import type { IAnimationTypeConfig } from '
|
|
6
|
+
import type { IAnimationTypeConfig } from '../../animation/interface';
|
|
7
7
|
export interface IWordcloud3dAnimationParams {
|
|
8
8
|
radius: number;
|
|
9
9
|
depth_3d: number;
|
|
@@ -5,3 +5,16 @@ export type StringOrNumber = string | number;
|
|
|
5
5
|
export type MaybeArray<T> = T | Array<T>;
|
|
6
6
|
export type Maybe<T> = T | undefined | null;
|
|
7
7
|
export type Quadrant = 1 | 2 | 3 | 4;
|
|
8
|
+
export type ValueOf<T, K extends keyof T = keyof T> = T[K];
|
|
9
|
+
export type DiffResult<Prev, Next> = {
|
|
10
|
+
enter: {
|
|
11
|
+
next: Next;
|
|
12
|
+
}[];
|
|
13
|
+
update: {
|
|
14
|
+
prev: Prev;
|
|
15
|
+
next: Next;
|
|
16
|
+
}[];
|
|
17
|
+
exit: {
|
|
18
|
+
prev: Prev;
|
|
19
|
+
}[];
|
|
20
|
+
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import type { IVChart } from './../../core/interface';
|
|
2
2
|
import type { IImageMarkSpec } from '../visual';
|
|
3
3
|
import type { LayoutCallBack } from '../../layout/interface';
|
|
4
|
-
import type { IElement, srIOption3DType } from '@visactor/vgrammar-core';
|
|
5
4
|
import type { DataSet, DataView, ISimplifyOptions, IFieldsOptions, IFilterOptions, IFoldOptions, IDsvParserOptions } from '@visactor/vdataset';
|
|
6
5
|
import type { RegionSpec } from '../../region/interface';
|
|
7
|
-
import type { IHoverSpec, ISelectSpec, IInteractionSpec } from '../../interaction/interface';
|
|
6
|
+
import type { IHoverSpec, ISelectSpec, IInteractionSpec } from '../../interaction/interface/spec';
|
|
8
7
|
import type { IRenderOption } from '../../compile/interface';
|
|
9
8
|
import type { ISeriesTooltipSpec, ITooltipSpec } from '../../component/tooltip/interface';
|
|
10
9
|
import type { ILayoutSpec } from '../../layout/interface';
|
|
@@ -14,7 +13,7 @@ import type { Datum, StringOrNumber } from '../common';
|
|
|
14
13
|
import type { IInvalidType } from '../data';
|
|
15
14
|
import type { IAnimationSpec, IMorphSeriesSpec } from '../../animation/spec';
|
|
16
15
|
import type { IPlayer } from '../../component/player/interface';
|
|
17
|
-
import type { IMarkProgressiveConfig, MarkTypeEnum } from '../../mark/interface';
|
|
16
|
+
import type { IMark, IMarkProgressiveConfig, MarkTypeEnum } from '../../mark/interface';
|
|
18
17
|
import type { IDataZoomSpec } from '../../component/data-zoom/data-zoom/interface';
|
|
19
18
|
import type { IScrollBarSpec } from '../../component/data-zoom/scroll-bar/interface';
|
|
20
19
|
import type { ICrosshairSpec } from '../../component/crosshair/interface';
|
|
@@ -24,7 +23,7 @@ import type { IBrushSpec } from '../../component/brush/interface';
|
|
|
24
23
|
import type { ITotalLabelSpec } from '../../component/label/interface';
|
|
25
24
|
import type { ILegendSpec } from '../../component/legend/interface';
|
|
26
25
|
import type { ILayoutOrientPadding, ILayoutPaddingSpec } from '../layout';
|
|
27
|
-
import type { IColor, ICustomPath2D, IRichTextCharacter } from '@visactor/vrender-core';
|
|
26
|
+
import type { IColor, ICustomPath2D, IGraphic, IRichTextCharacter } from '@visactor/vrender-core';
|
|
28
27
|
import type { ICommonAxisSpec } from '../../component/axis/interface';
|
|
29
28
|
import type { IMediaQuerySpec } from './media-query';
|
|
30
29
|
import type { IModelSpec } from '../../model/interface';
|
|
@@ -34,9 +33,7 @@ export interface IInitOption extends Omit<IRenderOption, 'pluginList'> {
|
|
|
34
33
|
renderCanvas?: string | HTMLCanvasElement;
|
|
35
34
|
dataSet?: DataSet;
|
|
36
35
|
autoFit?: boolean;
|
|
37
|
-
performanceHook?: IPerformanceHook;
|
|
38
36
|
animation?: boolean;
|
|
39
|
-
options3d?: srIOption3DType;
|
|
40
37
|
layout?: LayoutCallBack;
|
|
41
38
|
poptip?: boolean;
|
|
42
39
|
onError?: (...args: any[]) => void;
|
|
@@ -199,8 +196,12 @@ export type IMarkStateFilter = {
|
|
|
199
196
|
datums: Datum[];
|
|
200
197
|
datumKeys: string[];
|
|
201
198
|
} | {
|
|
202
|
-
items:
|
|
203
|
-
} | ((datum: Datum, options:
|
|
199
|
+
items: IGraphic[];
|
|
200
|
+
} | ((datum: Datum, options: {
|
|
201
|
+
mark?: IMark;
|
|
202
|
+
type?: string;
|
|
203
|
+
renderNode?: IGraphic;
|
|
204
|
+
}) => boolean);
|
|
204
205
|
export interface IMarkStateSpec<T> {
|
|
205
206
|
filter?: IMarkStateFilter;
|
|
206
207
|
level?: number | undefined;
|
|
@@ -224,35 +225,35 @@ export interface IPerformanceHook {
|
|
|
224
225
|
afterCreateVChart?: (vchart?: IVChart) => void;
|
|
225
226
|
beforeInitializeChart?: (vchart?: IVChart) => void;
|
|
226
227
|
afterInitializeChart?: (vchart?: IVChart) => void;
|
|
227
|
-
beforeCompileToVGrammar?: () => void;
|
|
228
|
-
afterCompileToVGrammar?: () => void;
|
|
229
|
-
beforeRegionCompile?: () => void;
|
|
230
|
-
afterRegionCompile?: () => void;
|
|
231
|
-
beforeSeriesCompile?: () => void;
|
|
232
|
-
afterSeriesCompile?: () => void;
|
|
233
|
-
beforeComponentCompile?: () => void;
|
|
234
|
-
afterComponentCompile?: () => void;
|
|
235
|
-
beforeResizeWithUpdate?: () => void;
|
|
236
|
-
afterResizeWithUpdate?: () => void;
|
|
237
|
-
beforeLayoutWithSceneGraph?: () => void;
|
|
238
|
-
afterLayoutWithSceneGraph?: () => void;
|
|
239
|
-
beforeParseView?: () => void;
|
|
240
|
-
afterParseView?: () => void;
|
|
241
|
-
beforeCreateRuntime?: () => void;
|
|
242
|
-
afterCreateRuntime?: () => void;
|
|
243
|
-
beforeSrViewEvaluateAsync?: () => void;
|
|
244
|
-
afterSrViewEvaluateAsync?: () => void;
|
|
245
|
-
beforeSrViewRunAsync?: () => void;
|
|
246
|
-
afterSrViewRunAsync?: () => void;
|
|
247
|
-
beforeTransform?: (name: string) => void;
|
|
248
|
-
afterTransform?: (name: string) => void;
|
|
249
|
-
beforeCreateVRenderStage?: () => void;
|
|
250
|
-
afterCreateVRenderStage?: () => void;
|
|
251
|
-
beforeCreateVRenderMark?: () => void;
|
|
252
|
-
afterCreateVRenderMark?: () => void;
|
|
228
|
+
beforeCompileToVGrammar?: (vchart?: IVChart) => void;
|
|
229
|
+
afterCompileToVGrammar?: (vchart?: IVChart) => void;
|
|
230
|
+
beforeRegionCompile?: (vchart?: IVChart) => void;
|
|
231
|
+
afterRegionCompile?: (vchart?: IVChart) => void;
|
|
232
|
+
beforeSeriesCompile?: (vchart?: IVChart) => void;
|
|
233
|
+
afterSeriesCompile?: (vchart?: IVChart) => void;
|
|
234
|
+
beforeComponentCompile?: (vchart?: IVChart) => void;
|
|
235
|
+
afterComponentCompile?: (vchart?: IVChart) => void;
|
|
236
|
+
beforeResizeWithUpdate?: (vchart?: IVChart) => void;
|
|
237
|
+
afterResizeWithUpdate?: (vchart?: IVChart) => void;
|
|
238
|
+
beforeLayoutWithSceneGraph?: (vchart?: IVChart) => void;
|
|
239
|
+
afterLayoutWithSceneGraph?: (vchart?: IVChart) => void;
|
|
240
|
+
beforeParseView?: (vchart?: IVChart) => void;
|
|
241
|
+
afterParseView?: (vchart?: IVChart) => void;
|
|
242
|
+
beforeCreateRuntime?: (vchart?: IVChart) => void;
|
|
243
|
+
afterCreateRuntime?: (vchart?: IVChart) => void;
|
|
244
|
+
beforeSrViewEvaluateAsync?: (vchart?: IVChart) => void;
|
|
245
|
+
afterSrViewEvaluateAsync?: (vchart?: IVChart) => void;
|
|
246
|
+
beforeSrViewRunAsync?: (vchart?: IVChart) => void;
|
|
247
|
+
afterSrViewRunAsync?: (vchart?: IVChart) => void;
|
|
248
|
+
beforeTransform?: (name: string, vchart?: IVChart) => void;
|
|
249
|
+
afterTransform?: (name: string, vchart?: IVChart) => void;
|
|
250
|
+
beforeCreateVRenderStage?: (vchart?: IVChart) => void;
|
|
251
|
+
afterCreateVRenderStage?: (vchart?: IVChart) => void;
|
|
252
|
+
beforeCreateVRenderMark?: (vchart?: IVChart) => void;
|
|
253
|
+
afterCreateVRenderMark?: (vchart?: IVChart) => void;
|
|
253
254
|
beforeDoRender?: (vchart?: IVChart) => void;
|
|
254
|
-
beforeVRenderDraw?: () => void;
|
|
255
|
-
afterVRenderDraw?: () => void;
|
|
255
|
+
beforeVRenderDraw?: (vchart?: IVChart) => void;
|
|
256
|
+
afterVRenderDraw?: (vchart?: IVChart) => void;
|
|
256
257
|
}
|
|
257
258
|
export type IBuildinMarkSpec = {
|
|
258
259
|
group: IGroupMarkSpec;
|
|
@@ -5,7 +5,7 @@ import type { InterpolateType } from './interpolate';
|
|
|
5
5
|
import type { ScaleType } from './scale';
|
|
6
6
|
import type { ShapeType } from './shape';
|
|
7
7
|
import type { IPoint } from './coordinate';
|
|
8
|
-
import type {
|
|
8
|
+
import type { IModelMarkAttributeContext } from '../compile/mark/interface';
|
|
9
9
|
import type { Datum } from './common';
|
|
10
10
|
import type { IPadding } from '@visactor/vutils';
|
|
11
11
|
import type { IColorKey } from '../theme/color-scheme/interface';
|
|
@@ -18,6 +18,7 @@ export interface IVisualSpecBase<D, T> {
|
|
|
18
18
|
specified?: {
|
|
19
19
|
[key: string]: unknown;
|
|
20
20
|
};
|
|
21
|
+
clamp?: boolean;
|
|
21
22
|
}
|
|
22
23
|
export interface IVisualSpecStyle<D, T> extends IVisualSpecBase<D, T> {
|
|
23
24
|
field?: string;
|
|
@@ -36,7 +37,7 @@ export interface IVisualScale {
|
|
|
36
37
|
field?: string;
|
|
37
38
|
changeDomain?: 'none' | 'replace' | 'expand';
|
|
38
39
|
}
|
|
39
|
-
export type FunctionType<T> = (datum: Datum, context: IModelMarkAttributeContext,
|
|
40
|
+
export type FunctionType<T> = (datum: Datum, context: IModelMarkAttributeContext, source?: DataView) => T;
|
|
40
41
|
export type ValueType<T> = T;
|
|
41
42
|
export type VisualType<T> = ValueType<T> | FunctionType<T> | IVisual<unknown, T>;
|
|
42
43
|
export type TextureType = 'circle' | 'dimond' | 'rect' | 'vertical-line' | 'horizontal-line' | 'bias-lr' | 'bias-rl' | 'grid';
|
|
@@ -132,10 +133,16 @@ export interface ITextMarkSpec extends IFillMarkSpec {
|
|
|
132
133
|
ellipsis?: string;
|
|
133
134
|
suffixPosition?: 'start' | 'end' | 'middle';
|
|
134
135
|
underline?: boolean;
|
|
136
|
+
underlineDash?: number[];
|
|
137
|
+
underlineOffset?: number;
|
|
135
138
|
lineThrough?: boolean;
|
|
136
139
|
lineHeight?: number | string | ITokenKey;
|
|
137
140
|
poptip?: PopTipAttributes;
|
|
138
141
|
direction?: 'horizontal' | 'vertical';
|
|
142
|
+
wordBreak?: 'break-word' | 'break-all' | 'keep-all';
|
|
143
|
+
heightLimit?: number;
|
|
144
|
+
lineClamp?: number;
|
|
145
|
+
whiteSpace?: 'normal' | 'no-wrap';
|
|
139
146
|
}
|
|
140
147
|
export type IRichTextMarkSpec = IRichTextAttribute & IFillMarkSpec & {
|
|
141
148
|
type: 'rich';
|
package/types/util/array.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { array, last as peek, maxInArray as maxInArr, minInArray as minInArr } from '@visactor/vutils';
|
|
2
2
|
export declare function shallowCompare<T, U>(arrA: T | T[], arrB: U | U[]): boolean;
|
|
3
3
|
export declare function combineDomains(domains: number[][]): number[];
|
|
4
|
+
export declare function moveAfterInArray<T>(array: T[], target: T, ref: T): void;
|
|
4
5
|
export { array, peek, maxInArr, minInArr };
|
package/types/util/index.d.ts
CHANGED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { IGraphic } from '@visactor/vrender-core';
|
|
2
|
+
import type { IMarkGraphic } from '../mark/interface/common';
|
|
3
|
+
export declare const isCollectionMark: (type: string) => boolean;
|
|
4
|
+
export declare const getDatumOfGraphic: (g: IMarkGraphic) => import("../typings").Datum;
|
|
5
|
+
export declare const findMarkGraphic: (rootGroup: IGraphic, target: IGraphic) => IGraphic<Partial<import("@visactor/vrender-core").IGraphicAttribute>>;
|
package/types/util/math.d.ts
CHANGED
|
@@ -23,5 +23,5 @@ export declare function radiusLabelOrientAttribute(angle: number): {
|
|
|
23
23
|
};
|
|
24
24
|
export declare function vectorAngle(v1: IPoint, v2: IPoint): number;
|
|
25
25
|
export declare function distance(p1: IPoint, p2?: IPoint): number;
|
|
26
|
-
export declare function getPercentValue(valueList: number[], precision?: number): number[]
|
|
26
|
+
export declare function getPercentValue(valueList: number[], precision?: number): 0 | number[];
|
|
27
27
|
export declare function isValidPoint(p: IPoint): boolean;
|