@visactor/vchart-types 2.1.0-alpha.13 → 2.1.0-alpha.15
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/chart/base/base-chart-transformer.d.ts +0 -3
- package/types/chart/base/base-chart.d.ts +9 -25
- package/types/chart/interface/chart.d.ts +0 -1
- package/types/chart/util.d.ts +1 -4
- package/types/compile/compiler.d.ts +0 -2
- package/types/compile/data/compilable-data.d.ts +1 -1
- package/types/compile/grammar-item.d.ts +1 -1
- package/types/compile/interface/compilable-item.d.ts +1 -1
- package/types/compile/interface/compiler.d.ts +1 -4
- package/types/component/axis/base-axis.d.ts +7 -2
- package/types/component/axis/cartesian/band-axis.d.ts +7 -1
- package/types/component/axis/polar/band-axis.d.ts +0 -2
- package/types/component/base/base-component.d.ts +7 -7
- package/types/component/brush/brush.d.ts +7 -3
- package/types/component/crosshair/base.d.ts +7 -4
- package/types/component/custom-mark/custom-mark.d.ts +7 -4
- package/types/component/data-zoom/data-filter-base-component.d.ts +7 -3
- package/types/component/data-zoom/data-zoom/data-zoom.d.ts +0 -1
- package/types/component/data-zoom/scroll-bar/scroll-bar.d.ts +0 -1
- package/types/component/geo/geo-coordinate.d.ts +7 -1
- package/types/component/indicator/indicator.d.ts +0 -1
- package/types/component/indicator/util.d.ts +3 -4
- package/types/component/label/base-label.d.ts +7 -1
- package/types/component/legend/base-legend.d.ts +7 -2
- package/types/component/marker/base-marker.d.ts +7 -14
- package/types/component/marker/utils.d.ts +4 -4
- package/types/component/player/player.d.ts +0 -1
- package/types/component/title/title.d.ts +7 -1
- package/types/component/tooltip/tooltip.d.ts +0 -1
- package/types/core/vchart.d.ts +1 -5
- package/types/data/transforms/box-plot.d.ts +1 -4
- package/types/data/transforms/correlation-center.d.ts +4 -10
- package/types/data/transforms/correlation.d.ts +15 -18
- package/types/data/transforms/funnel.d.ts +8 -10
- package/types/data/transforms/lookup.d.ts +3 -3
- package/types/data/transforms/map.d.ts +2 -8
- package/types/data/transforms/sankey.d.ts +4 -12
- package/types/data/transforms/stack-split.d.ts +1 -2
- package/types/data/transforms/treemap.d.ts +3 -5
- package/types/data/transforms/venn.d.ts +2 -4
- package/types/data/transforms/waterfall.d.ts +2 -4
- package/types/event/event.d.ts +0 -4
- package/types/mark/base/base-mark.d.ts +2 -13
- package/types/mark/component.d.ts +0 -9
- package/types/mark/interface/mark.d.ts +0 -2
- package/types/model/base-model.d.ts +15 -3
- package/types/model/interface.d.ts +0 -13
- package/types/region/region.d.ts +7 -1
- package/types/scale/color-ordinal-scale.d.ts +0 -1
- package/types/series/area/area.d.ts +0 -2
- package/types/series/bar/bar.d.ts +0 -3
- package/types/series/base/base-series.d.ts +7 -10
- package/types/series/base/constant.d.ts +0 -3
- package/types/series/box-plot/box-plot.d.ts +0 -2
- package/types/series/dot/dot.d.ts +0 -12
- package/types/series/heatmap/heatmap.d.ts +0 -2
- package/types/series/line/line.d.ts +0 -2
- package/types/series/mixin/line-mixin.d.ts +0 -1
- package/types/series/pie/pie.d.ts +7 -3
- package/types/series/polar/progress-like/progress-like.d.ts +0 -2
- package/types/series/polar/rose-like/rose-like.d.ts +0 -2
- package/types/series/progress/circular/circular.d.ts +0 -2
- package/types/series/progress/linear/linear.d.ts +0 -2
- package/types/series/scatter/scatter.d.ts +0 -2
- package/types/series/waterfall/waterfall.d.ts +0 -2
- package/types/compile/stage-app.d.ts +0 -23
- package/types/component/base/release-vrender-component.d.ts +0 -10
- package/types/data/data-view-utils.d.ts +0 -5
- package/types/util/graphic-state.d.ts +0 -4
|
@@ -8,7 +8,6 @@ import type { ICartesianBandAxisSpec } from '../..//component/axis/cartesian/int
|
|
|
8
8
|
export declare class BaseChartSpecTransformer<T extends IChartSpec> implements IChartSpecTransformer {
|
|
9
9
|
readonly type: string;
|
|
10
10
|
readonly seriesType: string;
|
|
11
|
-
protected _seriesRelatedSpecKeys: Record<string, true>;
|
|
12
11
|
protected _option: IChartSpecTransformerOption;
|
|
13
12
|
constructor(option: IChartSpecTransformerOption);
|
|
14
13
|
initChartSpec(chartSpec: T): IChartSpecInfo;
|
|
@@ -17,8 +16,6 @@ export declare class BaseChartSpecTransformer<T extends IChartSpec> implements I
|
|
|
17
16
|
transformModelSpec(chartSpec: T): IChartSpecInfo;
|
|
18
17
|
createSpecInfo(chartSpec: T, transform?: (constructor: IModelConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => void): IChartSpecInfo;
|
|
19
18
|
protected _isValidSeries(seriesType: string): boolean;
|
|
20
|
-
getSeriesRelatedSpecKeys(): Record<string, true>;
|
|
21
|
-
protected _addSeriesRelatedSpecKeys(...keysList: Array<string[] | undefined>): void;
|
|
22
19
|
protected _getDefaultSeriesSpec(chartSpec: any, pickKeys?: string[], pickKeys2?: string[]): any;
|
|
23
20
|
forEachRegionInSpec<K>(chartSpec: T, callbackfn: (constructor: IRegionConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => K, chartSpecInfo?: IChartSpecInfo): K[];
|
|
24
21
|
forEachSeriesInSpec<K>(chartSpec: T, callbackfn: (constructor: ISeriesConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => K, chartSpecInfo?: IChartSpecInfo): K[];
|
|
@@ -30,7 +30,6 @@ export declare class BaseChart<T extends IChartSpec> extends CompilableBase impl
|
|
|
30
30
|
protected _regions: IRegion[];
|
|
31
31
|
protected _series: ISeries[];
|
|
32
32
|
protected _components: IComponent[];
|
|
33
|
-
protected _specTransformer: Maybe<IChartSpecTransformer>;
|
|
34
33
|
protected _layoutFunc: LayoutCallBack;
|
|
35
34
|
protected _layoutRect: IRect;
|
|
36
35
|
getLayoutRect(): IRect;
|
|
@@ -119,32 +118,17 @@ export declare class BaseChart<T extends IChartSpec> extends CompilableBase impl
|
|
|
119
118
|
updateGlobalScale(result: IUpdateSpecResult): void;
|
|
120
119
|
updateGlobalScaleTheme(): void;
|
|
121
120
|
private _getSpecKeys;
|
|
122
|
-
updateSpec(spec: T):
|
|
121
|
+
updateSpec(spec: T): {
|
|
122
|
+
change: boolean;
|
|
123
|
+
reMake: boolean;
|
|
124
|
+
reRender: boolean;
|
|
125
|
+
reSize: boolean;
|
|
126
|
+
reCompile: boolean;
|
|
127
|
+
};
|
|
123
128
|
updateChartConfig(result: IUpdateSpecResult, oldSpec: IChartSpec): void;
|
|
124
129
|
updateDataSpec(): void;
|
|
125
130
|
updateRegionSpec(result: IUpdateSpecResult): void;
|
|
126
|
-
updateComponentSpec(result: IUpdateSpecResult):
|
|
127
|
-
componentOnlyUpdatedComponents: IComponent[];
|
|
128
|
-
hasNonComponentOnlyUpdate: boolean;
|
|
129
|
-
};
|
|
130
|
-
private _canChangeMarkerComponentsWithoutRemake;
|
|
131
|
-
private _canAddMarkerComponentsWithoutRemake;
|
|
132
|
-
private _isMarkerAdditionSpecSafeWithoutRemake;
|
|
133
|
-
private _isAutoRangeMarkerSpec;
|
|
134
|
-
private _canRemoveMarkerComponentsWithoutRemake;
|
|
135
|
-
private _isOnlyMarkerComponentsRemoved;
|
|
136
|
-
private _isComponentSpecKey;
|
|
137
|
-
private _isOnlyComponentSpecsChanged;
|
|
138
|
-
private _isOnlySeriesSpecsChanged;
|
|
139
|
-
private _isOnlyComponentOrSeriesSpecsChanged;
|
|
140
|
-
private _canSkipChartDataStages;
|
|
141
|
-
private _isComponentScaleDomainOnlyUpdate;
|
|
142
|
-
private _reRunStackDataFlow;
|
|
143
|
-
private _getModelSpecIndex;
|
|
144
|
-
private _hasComponentForSpecInfo;
|
|
145
|
-
private _createMissingMarkerComponentsForSpecs;
|
|
146
|
-
private _removeMarkerComponentsForEmptySpecs;
|
|
147
|
-
private _removeComponent;
|
|
131
|
+
updateComponentSpec(result: IUpdateSpecResult): void;
|
|
148
132
|
updateSeriesSpec(result: IUpdateSpecResult): void;
|
|
149
133
|
getCanvas(): HTMLCanvasElement;
|
|
150
134
|
private _updateLayoutRect;
|
|
@@ -158,7 +142,7 @@ export declare class BaseChart<T extends IChartSpec> extends CompilableBase impl
|
|
|
158
142
|
compileRegions(): void;
|
|
159
143
|
compileSeries(): void;
|
|
160
144
|
compileComponents(): void;
|
|
161
|
-
release(
|
|
145
|
+
release(): void;
|
|
162
146
|
onLayout(): void;
|
|
163
147
|
updateState(state: Record<string, Omit<IMarkStateSpec<unknown>, 'style'>>, filter?: (series: ISeries, mark: IMark, stateKey: string) => boolean): void;
|
|
164
148
|
setSelected(datum: MaybeArray<any> | null, filter?: (series: ISeries, mark: IMark) => boolean, region?: IRegionQuerier): void;
|
|
@@ -112,7 +112,6 @@ export interface IChartSpecTransformer {
|
|
|
112
112
|
transformSpec: (spec: any) => void;
|
|
113
113
|
transformModelSpec: (spec: any) => IChartSpecInfo;
|
|
114
114
|
createSpecInfo: (chartSpec: any, transform?: (constructor: IModelConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => void) => IChartSpecInfo;
|
|
115
|
-
getSeriesRelatedSpecKeys: () => Record<string, true>;
|
|
116
115
|
forEachRegionInSpec: <K>(spec: any, callbackfn: (constructor: IRegionConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => K, chartSpecInfo?: IChartSpecInfo) => K[];
|
|
117
116
|
forEachSeriesInSpec: <K>(spec: any, callbackfn: (constructor: ISeriesConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => K, chartSpecInfo?: IChartSpecInfo) => K[];
|
|
118
117
|
forEachComponentInSpec: <K>(spec: any, callbackfn: (constructor: IComponentConstructor, specInfo: IModelSpecInfo, chartSpecInfo?: IChartSpecInfo) => K, chartSpecInfo?: IChartSpecInfo) => K[];
|
package/types/chart/util.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IChartSpec } from '../typings';
|
|
2
2
|
import type { ICartesianChartSpec } from './cartesian/interface';
|
|
3
3
|
import type { IChartOption } from './interface/common';
|
|
4
|
-
import type {
|
|
4
|
+
import type { IUpdateSpecResult } from '../model/interface';
|
|
5
5
|
export declare function setDefaultCrosshairForCartesianChart(spec: ICartesianChartSpec): void;
|
|
6
6
|
export declare function calculateChartSize(spec: {
|
|
7
7
|
width?: number;
|
|
@@ -13,9 +13,6 @@ export declare function calculateChartSize(spec: {
|
|
|
13
13
|
width: number;
|
|
14
14
|
height: number;
|
|
15
15
|
};
|
|
16
|
-
export declare function normalizeUpdateSpecEffects(result: IUpdateSpecResult): IUpdateSpecEffects;
|
|
17
|
-
export declare function isUpdateSpecResultLocalOnly(result: IUpdateSpecResult): boolean;
|
|
18
|
-
export declare function isUpdateSpecResultComponentOnly(result: IUpdateSpecResult): boolean;
|
|
19
16
|
export declare function mergeUpdateResult(target: IUpdateSpecResult, ...sources: IUpdateSpecResult[]): IUpdateSpecResult;
|
|
20
17
|
export declare function getTrimPaddingConfig(chartType: string, spec: IChartSpec): {
|
|
21
18
|
paddingInner: number;
|
|
@@ -20,8 +20,6 @@ export declare class Compiler implements ICompiler {
|
|
|
20
20
|
private _progressiveRafId?;
|
|
21
21
|
protected _rootMarks: IMark[];
|
|
22
22
|
protected _stage: IStage;
|
|
23
|
-
private _isExternalStage;
|
|
24
|
-
private _releaseVRenderAppRef?;
|
|
25
23
|
protected _stateAnimationConfig: Partial<MarkAnimationSpec>;
|
|
26
24
|
get stateAnimationConfig(): Partial<MarkAnimationSpec>;
|
|
27
25
|
protected _rootGroup: IGroup;
|
|
@@ -13,7 +13,7 @@ export declare class CompilableData extends GrammarItem implements ICompilableDa
|
|
|
13
13
|
setDataView(d?: DataView): void;
|
|
14
14
|
getLatestData(): any;
|
|
15
15
|
constructor(option: GrammarItemInitOption, dataView?: DataView);
|
|
16
|
-
removeProduct(
|
|
16
|
+
removeProduct(): void;
|
|
17
17
|
release(): void;
|
|
18
18
|
protected _relatedMarks?: Record<string, ICompilableMark>;
|
|
19
19
|
addRelatedMark(mark: ICompilableMark): void;
|
|
@@ -11,7 +11,7 @@ export declare abstract class GrammarItem extends CompilableBase implements IGra
|
|
|
11
11
|
getProductId(): string;
|
|
12
12
|
compile(option?: GrammarItemCompileOption): void;
|
|
13
13
|
protected abstract _compileProduct(option?: GrammarItemCompileOption): void;
|
|
14
|
-
abstract removeProduct(
|
|
14
|
+
abstract removeProduct(): void;
|
|
15
15
|
protected _transform: ITransformSpec[];
|
|
16
16
|
setTransform(transform: ITransformSpec[]): void;
|
|
17
17
|
runTransforms<T = any>(transforms: ITransformSpec[], data: T): T;
|
|
@@ -85,7 +85,7 @@ export interface IGrammarItem extends ICompilable {
|
|
|
85
85
|
id: number;
|
|
86
86
|
generateProductId: () => string;
|
|
87
87
|
getProductId: () => string;
|
|
88
|
-
removeProduct: (
|
|
88
|
+
removeProduct: () => void;
|
|
89
89
|
setTransform: (transform: ITransformSpec[]) => void;
|
|
90
90
|
}
|
|
91
91
|
export type GrammarItemInitOption = ICompilableInitOption;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { IColor, IStageParams, IStage, ILayer, IOption3D, ITicker } from '@visactor/vrender-core';
|
|
2
2
|
import type { IPerformanceHook, RenderMode } from '../../typings/spec/common';
|
|
3
3
|
import type { IBoundsLike } from '@visactor/vutils';
|
|
4
4
|
import type { StringOrNumber } from '../../typings';
|
|
5
|
-
import type { SharedVRenderAppOption } from '../stage-app';
|
|
6
5
|
export declare enum LayoutState {
|
|
7
6
|
before = "before",
|
|
8
7
|
layouting = "layouting",
|
|
@@ -43,8 +42,6 @@ export interface IRenderOption {
|
|
|
43
42
|
viewBox?: IBoundsLike;
|
|
44
43
|
canvasControled?: boolean;
|
|
45
44
|
stage?: IStage;
|
|
46
|
-
app?: IApp;
|
|
47
|
-
sharedVRenderApp?: SharedVRenderAppOption;
|
|
48
45
|
layer?: ILayer;
|
|
49
46
|
beforeRender?: IStageParams['beforeRender'];
|
|
50
47
|
afterRender?: IStageParams['afterRender'];
|
|
@@ -82,8 +82,13 @@ export declare abstract class AxisComponent<T extends ICommonAxisSpec & Record<s
|
|
|
82
82
|
protected computeData(updateType?: 'domain' | 'range' | 'force'): void;
|
|
83
83
|
protected _updateTickDataMarks(m: ICompilableMark): void;
|
|
84
84
|
protected initScales(): void;
|
|
85
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
86
|
-
|
|
85
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
86
|
+
change: boolean;
|
|
87
|
+
reMake: boolean;
|
|
88
|
+
reRender: boolean;
|
|
89
|
+
reSize: boolean;
|
|
90
|
+
reCompile: boolean;
|
|
91
|
+
};
|
|
87
92
|
protected _getAxisAttributes(): any;
|
|
88
93
|
protected _getGridAttributes(): {
|
|
89
94
|
alternateColor: any;
|
|
@@ -43,7 +43,13 @@ export declare class CartesianBandAxis<T extends ICartesianBandAxisSpec = ICarte
|
|
|
43
43
|
maxBandSize: number;
|
|
44
44
|
minBandSize: number;
|
|
45
45
|
};
|
|
46
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
46
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
47
|
+
change: boolean;
|
|
48
|
+
reMake: boolean;
|
|
49
|
+
reRender: boolean;
|
|
50
|
+
reSize: boolean;
|
|
51
|
+
reCompile: boolean;
|
|
52
|
+
};
|
|
47
53
|
reInit(spec?: T): void;
|
|
48
54
|
}
|
|
49
55
|
export declare const registerCartesianBandAxis: () => void;
|
|
@@ -18,7 +18,6 @@ export declare class PolarBandAxis<T extends IPolarBandAxisSpec = IPolarBandAxis
|
|
|
18
18
|
};
|
|
19
19
|
protected _scale: BandScale;
|
|
20
20
|
protected _scales: BandScale[];
|
|
21
|
-
protected _updateData: () => void;
|
|
22
21
|
protected computeDomain(data: {
|
|
23
22
|
min: number;
|
|
24
23
|
max: number;
|
|
@@ -38,7 +37,6 @@ export declare class PolarBandAxis<T extends IPolarBandAxisSpec = IPolarBandAxis
|
|
|
38
37
|
getSpec: () => T;
|
|
39
38
|
};
|
|
40
39
|
protected initScales(): void;
|
|
41
|
-
reInit(spec?: T): void;
|
|
42
40
|
protected registerTicksTransform(): string;
|
|
43
41
|
transformScaleDomain(): void;
|
|
44
42
|
}
|
|
@@ -19,20 +19,20 @@ export declare class BaseComponent<T extends IComponentSpec = IComponentSpec> ex
|
|
|
19
19
|
protected _regions: IRegion[];
|
|
20
20
|
getRegions(): IRegion[];
|
|
21
21
|
protected _container: IGroup;
|
|
22
|
-
private _exitingVRenderComponents?;
|
|
23
|
-
private _forceReleaseVRenderComponents;
|
|
24
22
|
created(): void;
|
|
25
23
|
initLayout(): void;
|
|
26
24
|
protected _getNeedClearVRenderComponents(): IGraphic[];
|
|
27
25
|
getVRenderComponents(): IGraphic<Partial<IGraphicAttribute>>[];
|
|
28
26
|
protected callPlugin(cb: (plugin: IComponentPlugin) => void): void;
|
|
29
27
|
protected getContainer(): IGroup;
|
|
30
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
31
|
-
|
|
28
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
29
|
+
change: boolean;
|
|
30
|
+
reMake: boolean;
|
|
31
|
+
reRender: boolean;
|
|
32
|
+
reSize: boolean;
|
|
33
|
+
reCompile: boolean;
|
|
34
|
+
};
|
|
32
35
|
release(): void;
|
|
33
|
-
protected _shouldReleaseVRenderComponentsImmediately(): boolean;
|
|
34
|
-
protected _forceReleaseExitingVRenderComponents(): void;
|
|
35
|
-
protected _releaseVRenderComponent(component: IGraphic): void;
|
|
36
36
|
clear(): void;
|
|
37
37
|
compile(): void;
|
|
38
38
|
compileMarks(group?: IGroup): void;
|
|
@@ -48,7 +48,6 @@ export declare class Brush<T extends IBrushSpec = IBrushSpec> extends BaseCompon
|
|
|
48
48
|
private _zoomRecord;
|
|
49
49
|
static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
|
|
50
50
|
init(): void;
|
|
51
|
-
reInit(spec?: T): void;
|
|
52
51
|
private _initNeedOperatedItem;
|
|
53
52
|
created(): void;
|
|
54
53
|
protected _bindRegions(): void;
|
|
@@ -56,8 +55,13 @@ export declare class Brush<T extends IBrushSpec = IBrushSpec> extends BaseCompon
|
|
|
56
55
|
private _initRegionAxisMap;
|
|
57
56
|
private _initAxisDataZoomMap;
|
|
58
57
|
protected initEvent(): void;
|
|
59
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
60
|
-
|
|
58
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
59
|
+
change: boolean;
|
|
60
|
+
reMake: boolean;
|
|
61
|
+
reRender: boolean;
|
|
62
|
+
reSize: boolean;
|
|
63
|
+
reCompile: boolean;
|
|
64
|
+
};
|
|
61
65
|
onLayoutEnd(): void;
|
|
62
66
|
protected _updateBrushComponent(region: IRegion, componentIndex: number): void;
|
|
63
67
|
protected _shouldEnableInteractive(): boolean;
|
|
@@ -41,10 +41,13 @@ export declare abstract class BaseCrossHair<T extends ICartesianCrosshairSpec |
|
|
|
41
41
|
protected _showDefaultCrosshair(): void;
|
|
42
42
|
setAttrFromSpec(): void;
|
|
43
43
|
created(): void;
|
|
44
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
44
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
45
|
+
change: boolean;
|
|
46
|
+
reMake: boolean;
|
|
47
|
+
reRender: boolean;
|
|
48
|
+
reSize: boolean;
|
|
49
|
+
reCompile: boolean;
|
|
50
|
+
};
|
|
48
51
|
protected _initEvent(): void;
|
|
49
52
|
private _registerEvent;
|
|
50
53
|
private _eventOff;
|
|
@@ -18,10 +18,13 @@ export declare class CustomMark extends BaseComponent<ICustomMarkSpec<EnableMark
|
|
|
18
18
|
protected initMarks(): void;
|
|
19
19
|
private _createExtensionMark;
|
|
20
20
|
initEvent(): void;
|
|
21
|
-
_compareSpec(spec: ICustomMarkSpec<EnableMarkType>, prevSpec: ICustomMarkSpec<EnableMarkType>):
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
_compareSpec(spec: ICustomMarkSpec<EnableMarkType>, prevSpec: ICustomMarkSpec<EnableMarkType>): {
|
|
22
|
+
change: boolean;
|
|
23
|
+
reMake: boolean;
|
|
24
|
+
reRender: boolean;
|
|
25
|
+
reSize: boolean;
|
|
26
|
+
reCompile: boolean;
|
|
27
|
+
};
|
|
25
28
|
private _getMarkAttributeContext;
|
|
26
29
|
private _getLayoutRect;
|
|
27
30
|
getBoundsInRect(rect: ILayoutRect): {
|
|
@@ -76,9 +76,13 @@ export declare abstract class DataFilterBaseComponent<T extends IDataFilterCompo
|
|
|
76
76
|
created(): void;
|
|
77
77
|
initLayout(): void;
|
|
78
78
|
init(option: IModelInitOption): void;
|
|
79
|
-
_compareSpec(spec: AdaptiveSpec<T, 'width' | 'height'>, prevSpec: AdaptiveSpec<T, 'width' | 'height'>):
|
|
80
|
-
|
|
81
|
-
|
|
79
|
+
_compareSpec(spec: AdaptiveSpec<T, 'width' | 'height'>, prevSpec: AdaptiveSpec<T, 'width' | 'height'>): {
|
|
80
|
+
change: boolean;
|
|
81
|
+
reMake: boolean;
|
|
82
|
+
reRender: boolean;
|
|
83
|
+
reSize: boolean;
|
|
84
|
+
reCompile: boolean;
|
|
85
|
+
};
|
|
82
86
|
reInit(spec?: AdaptiveSpec<T, 'width' | 'height'>): void;
|
|
83
87
|
onLayoutStart(layoutRect: IRect, viewRect: ILayoutRect): void;
|
|
84
88
|
updateLayoutAttribute(): void;
|
|
@@ -36,7 +36,6 @@ export declare class DataZoom<T extends IDataZoomSpec = IDataZoomSpec> extends D
|
|
|
36
36
|
created(): void;
|
|
37
37
|
updateLayoutAttribute(): void;
|
|
38
38
|
protected _beforeLayoutEnd(): void;
|
|
39
|
-
protected _getComponentOnlySpecKeys(): Record<string, boolean>;
|
|
40
39
|
clear(): void;
|
|
41
40
|
getBoundsInRect(rect: ILayoutRect): IBoundsLike;
|
|
42
41
|
setAttrFromSpec(): void;
|
|
@@ -22,7 +22,6 @@ export declare class ScrollBar<T extends IScrollBarSpec = IScrollBarSpec> extend
|
|
|
22
22
|
constructor(spec: T, options: IComponentOption);
|
|
23
23
|
protected _handleChange(start: number, end: number, updateComponent?: boolean): void;
|
|
24
24
|
protected _handleDataCollectionChange(): void;
|
|
25
|
-
protected _getComponentOnlySpecKeys(): Record<string, boolean>;
|
|
26
25
|
protected _beforeLayoutEnd(): void;
|
|
27
26
|
onLayoutEnd(): void;
|
|
28
27
|
protected _updateScaleRange(): void;
|
|
@@ -52,7 +52,13 @@ export declare class GeoCoordinate extends BaseComponent<IGeoRegionSpec> impleme
|
|
|
52
52
|
invert(point: [number, number]): any;
|
|
53
53
|
private evaluateProjection;
|
|
54
54
|
protected _initCenterCache(): void;
|
|
55
|
-
_compareSpec(spec: IGeoRegionSpec, prevSpec: IGeoRegionSpec):
|
|
55
|
+
_compareSpec(spec: IGeoRegionSpec, prevSpec: IGeoRegionSpec): {
|
|
56
|
+
change: boolean;
|
|
57
|
+
reMake: boolean;
|
|
58
|
+
reRender: boolean;
|
|
59
|
+
reSize: boolean;
|
|
60
|
+
reCompile: boolean;
|
|
61
|
+
};
|
|
56
62
|
release(): void;
|
|
57
63
|
}
|
|
58
64
|
export declare const registerGeoCoordinate: () => void;
|
|
@@ -27,7 +27,6 @@ export declare class Indicator<T extends IIndicatorSpec> extends BaseComponent<T
|
|
|
27
27
|
static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
|
|
28
28
|
created(): void;
|
|
29
29
|
setAttrFromSpec(): void;
|
|
30
|
-
_compareSpec(spec: T, prevSpec: T): import("../../model/interface").IUpdateSpecResult;
|
|
31
30
|
protected initEvent(): void;
|
|
32
31
|
updateDatum(datum: any): void;
|
|
33
32
|
private initData;
|
|
@@ -2,13 +2,12 @@ import type { IIndicatorItemSpec } from './interface';
|
|
|
2
2
|
export interface IIndicatorDatum {
|
|
3
3
|
type: 'title' | 'content';
|
|
4
4
|
index: number;
|
|
5
|
-
datum:
|
|
5
|
+
datum: any;
|
|
6
6
|
spec: IIndicatorItemSpec;
|
|
7
7
|
}
|
|
8
8
|
export interface IIndicatorMapper {
|
|
9
9
|
title: IIndicatorItemSpec;
|
|
10
10
|
content: IIndicatorItemSpec[];
|
|
11
|
-
datum: () =>
|
|
11
|
+
datum: () => any;
|
|
12
12
|
}
|
|
13
|
-
export
|
|
14
|
-
export declare const indicatorMapper: (data: Array<unknown>, op: IndicatorMapperOption) => IIndicatorDatum[];
|
|
13
|
+
export declare const indicatorMapper: (data: Array<any>, op: IIndicatorMapper) => any[];
|
|
@@ -22,7 +22,13 @@ export declare abstract class BaseLabelComponent<T = any> extends BaseComponent<
|
|
|
22
22
|
selected_reverse?: Partial<import("../../core").IComposedTextMarkSpec>;
|
|
23
23
|
};
|
|
24
24
|
};
|
|
25
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
25
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
26
|
+
change: boolean;
|
|
27
|
+
reMake: boolean;
|
|
28
|
+
reRender: boolean;
|
|
29
|
+
reSize: boolean;
|
|
30
|
+
reCompile: boolean;
|
|
31
|
+
};
|
|
26
32
|
_getDataLabelType(baseMark: ICompilableMark, type?: string): string;
|
|
27
33
|
_setTransformOfComponent(labelComponent: IComponentMark, baseMark: IMark | IMark[]): void;
|
|
28
34
|
getVRenderComponents(): any[];
|
|
@@ -31,8 +31,13 @@ export declare abstract class BaseLegend<T extends ILegendCommonSpec> extends Ba
|
|
|
31
31
|
protected _regionUserIndex?: number[];
|
|
32
32
|
setAttrFromSpec(): void;
|
|
33
33
|
created(): void;
|
|
34
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
35
|
-
|
|
34
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
35
|
+
change: boolean;
|
|
36
|
+
reMake: boolean;
|
|
37
|
+
reRender: boolean;
|
|
38
|
+
reSize: boolean;
|
|
39
|
+
reCompile: boolean;
|
|
40
|
+
};
|
|
36
41
|
protected abstract _initLegendData(): DataView;
|
|
37
42
|
protected abstract _initSelectedData(): void;
|
|
38
43
|
protected abstract _getLegendAttributes(rect: ILayoutRect): any;
|
|
@@ -19,8 +19,6 @@ export declare abstract class BaseMarker<T extends IMarkerSpec> extends BaseComp
|
|
|
19
19
|
getRelativeSeries(): IMarkerSupportSeries;
|
|
20
20
|
protected _markerData: DataView;
|
|
21
21
|
getMarkerData(): DataView;
|
|
22
|
-
private _markerDataChangeHandler;
|
|
23
|
-
private _markerDataOwned;
|
|
24
22
|
protected _markerComponent: any;
|
|
25
23
|
protected _layoutOffsetX: number;
|
|
26
24
|
protected _layoutOffsetY: number;
|
|
@@ -40,10 +38,6 @@ export declare abstract class BaseMarker<T extends IMarkerSpec> extends BaseComp
|
|
|
40
38
|
getStartRelativeSeries: () => IMarkerSupportSeries;
|
|
41
39
|
getEndRelativeSeries: () => IMarkerSupportSeries;
|
|
42
40
|
};
|
|
43
|
-
protected _getAutoRangeExtendDomainKeyPrefix(): string;
|
|
44
|
-
private _getAutoRangeExtendDomainKey;
|
|
45
|
-
private _clearAutoRangeExtendDomain;
|
|
46
|
-
private _updateMarkerLayout;
|
|
47
41
|
private _getFieldInfoFromSpec;
|
|
48
42
|
protected _processSpecByDims(dimSpec: {
|
|
49
43
|
dim: 'x' | 'y' | 'angle' | 'radius' | 'areaName';
|
|
@@ -55,21 +49,20 @@ export declare abstract class BaseMarker<T extends IMarkerSpec> extends BaseComp
|
|
|
55
49
|
};
|
|
56
50
|
protected _processSpecCoo(spec: any): IOptionWithCoordinates;
|
|
57
51
|
protected _getRelativeDataView(): DataView;
|
|
58
|
-
protected _setMarkerData(data: DataView, owned?: boolean): void;
|
|
59
|
-
protected _bindMarkerDataChange(): void;
|
|
60
|
-
private _releaseMarkerData;
|
|
61
52
|
updateLayoutAttribute(): void;
|
|
62
53
|
private _getSeriesByIdOrIndex;
|
|
63
54
|
protected _bindSeries(): void;
|
|
64
55
|
protected initEvent(): void;
|
|
65
56
|
clear(): void;
|
|
66
|
-
release(): void;
|
|
67
57
|
private _getFirstSeries;
|
|
68
58
|
protected _getNeedClearVRenderComponents(): IGraphic[];
|
|
69
59
|
onLayoutStart(layoutRect: IRect, chartViewRect: ILayoutRect): void;
|
|
70
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
60
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
61
|
+
change: boolean;
|
|
62
|
+
reMake: boolean;
|
|
63
|
+
reRender: boolean;
|
|
64
|
+
reSize: boolean;
|
|
65
|
+
reCompile: boolean;
|
|
66
|
+
};
|
|
74
67
|
_initCommonDataView(): void;
|
|
75
68
|
}
|
|
@@ -5,11 +5,11 @@ import type { IDataPos, IMarkerAttributeContext, IMarkerLabelSpec, IMarkerState,
|
|
|
5
5
|
import type { IRegion } from '../../region/interface';
|
|
6
6
|
import type { OffsetPoint } from './interface';
|
|
7
7
|
export declare function isAggrSpec(spec: IDataPos): boolean;
|
|
8
|
-
export declare function xyLayout(data: DataView, startRelativeSeries: IMarkerSupportSeries, endRelativeSeries: IMarkerSupportSeries, relativeSeries: IMarkerSupportSeries, autoRange: boolean, includeFullBand?: boolean
|
|
9
|
-
export declare function polarLayout(data: DataView, startRelativeSeries: IMarkerSupportSeries, endRelativeSeries: IMarkerSupportSeries, relativeSeries: IMarkerSupportSeries, autoRange: boolean
|
|
8
|
+
export declare function xyLayout(data: DataView, startRelativeSeries: IMarkerSupportSeries, endRelativeSeries: IMarkerSupportSeries, relativeSeries: IMarkerSupportSeries, autoRange: boolean, includeFullBand?: boolean): IPoint[][];
|
|
9
|
+
export declare function polarLayout(data: DataView, startRelativeSeries: IMarkerSupportSeries, endRelativeSeries: IMarkerSupportSeries, relativeSeries: IMarkerSupportSeries, autoRange: boolean): IPolarPoint[][];
|
|
10
10
|
export declare function geoLayout(data: DataView, relativeSeries: IMarkerSupportSeries): IPoint[][];
|
|
11
|
-
export declare function cartesianCoordinateLayout(data: DataView, relativeSeries: IMarkerSupportSeries, autoRange: boolean, coordinatesOffset: OffsetPoint[] | OffsetPoint
|
|
12
|
-
export declare function polarCoordinateLayout(data: DataView, relativeSeries: IMarkerSupportSeries, autoRange: boolean
|
|
11
|
+
export declare function cartesianCoordinateLayout(data: DataView, relativeSeries: IMarkerSupportSeries, autoRange: boolean, coordinatesOffset: OffsetPoint[] | OffsetPoint): IPoint[];
|
|
12
|
+
export declare function polarCoordinateLayout(data: DataView, relativeSeries: IMarkerSupportSeries, autoRange: boolean): IPolarPoint[];
|
|
13
13
|
export declare function positionLayout(positions: MarkerPositionPoint | MarkerPositionPoint[] | ((seriesData: Datum[], relativeSeries: IMarkerSupportSeries) => MarkerPositionPoint) | ((seriesData: Datum[], relativeSeries: IMarkerSupportSeries) => MarkerPositionPoint[]), series: IMarkerSupportSeries, regionRelative: boolean): IPoint[];
|
|
14
14
|
export declare function computeClipRange(regions: IRegion[]): {
|
|
15
15
|
minX: number;
|
|
@@ -29,7 +29,6 @@ export declare class Player extends BaseComponent<IPlayer> implements IComponent
|
|
|
29
29
|
get orient(): IOrientType;
|
|
30
30
|
set layoutOrient(v: IOrientType);
|
|
31
31
|
setAttrFromSpec(): void;
|
|
32
|
-
_compareSpec(spec: IPlayer, prevSpec: IPlayer): import("../../model/interface").IUpdateSpecResult;
|
|
33
32
|
afterSetLayoutStartPoint(pos: IPoint): void;
|
|
34
33
|
getBoundsInRect(rect: ILayoutRect, fullSpace: ILayoutRect): {
|
|
35
34
|
x1: number;
|
|
@@ -24,7 +24,13 @@ export declare class Title<T extends ITitleSpec = ITitleSpec> extends BaseCompon
|
|
|
24
24
|
constructor(spec: T, options: IComponentOption);
|
|
25
25
|
initLayout(): void;
|
|
26
26
|
static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
|
|
27
|
-
_compareSpec(spec: T, prevSpec: T):
|
|
27
|
+
_compareSpec(spec: T, prevSpec: T): {
|
|
28
|
+
change: boolean;
|
|
29
|
+
reMake: boolean;
|
|
30
|
+
reRender: boolean;
|
|
31
|
+
reSize: boolean;
|
|
32
|
+
reCompile: boolean;
|
|
33
|
+
};
|
|
28
34
|
afterSetLayoutStartPoint(pos: IPoint): void;
|
|
29
35
|
getBoundsInRect(rect: ILayoutRect): {
|
|
30
36
|
x1: number;
|
|
@@ -45,7 +45,6 @@ export declare class Tooltip extends BaseComponent<any> implements ITooltip {
|
|
|
45
45
|
protected _releaseEvent(): void;
|
|
46
46
|
onLayoutEnd(): void;
|
|
47
47
|
created(): void;
|
|
48
|
-
_compareSpec(spec: ITooltipSpec, prevSpec: ITooltipSpec): import("../../model/interface").IUpdateSpecResult;
|
|
49
48
|
release(): void;
|
|
50
49
|
beforeRelease(): void;
|
|
51
50
|
protected _initHandler(): void;
|
package/types/core/vchart.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ import type { IComponentConstructor } from '../component/interface';
|
|
|
8
8
|
import type { EventCallback, EventQuery, EventType, ExtendEventParam, IEvent } from '../event/interface';
|
|
9
9
|
import type { IParserOptions, Transform } from '@visactor/vdataset';
|
|
10
10
|
import { DataSet, DataView } from '@visactor/vdataset';
|
|
11
|
-
import type {
|
|
11
|
+
import type { IStage } from '@visactor/vrender-core';
|
|
12
12
|
import type { GeoSourceType } from '../typings/geo';
|
|
13
13
|
import type { GeoSourceOption } from '../series/map/geo-source';
|
|
14
14
|
import type { IMark, MarkConstructor } from '../mark/interface';
|
|
@@ -78,7 +78,6 @@ export declare class VChart implements IVChart {
|
|
|
78
78
|
private _onError?;
|
|
79
79
|
private _context;
|
|
80
80
|
private _isReleased;
|
|
81
|
-
private _exitingVRenderComponents?;
|
|
82
81
|
private _chartPlugin?;
|
|
83
82
|
private _vChartPlugin?;
|
|
84
83
|
private _onResize?;
|
|
@@ -111,9 +110,6 @@ export declare class VChart implements IVChart {
|
|
|
111
110
|
protected _renderAsync(option?: IVChartRenderOption): Promise<IVChart>;
|
|
112
111
|
private _updateAnimateState;
|
|
113
112
|
release(): void;
|
|
114
|
-
_registerExitingVRenderComponent(component: IGraphic): void;
|
|
115
|
-
_unregisterExitingVRenderComponent(component: IGraphic): void;
|
|
116
|
-
private _forceReleaseExitingVRenderComponents;
|
|
117
113
|
updateData(id: StringOrNumber, data: DataView | Datum[] | string, parserOptions?: IParserOptions, userUpdateOptions?: IUpdateDataResult): Promise<IVChart>;
|
|
118
114
|
private _updateDataById;
|
|
119
115
|
updateDataInBatches(list: {
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
import type { DataView } from '@visactor/vdataset';
|
|
2
1
|
export interface IBoxPlotOutlierOpt {
|
|
3
2
|
dimensionField: string[];
|
|
4
3
|
outliersField: string;
|
|
5
4
|
seriesField?: string;
|
|
6
5
|
}
|
|
7
|
-
|
|
8
|
-
export declare const foldOutlierData: (data: Array<DataView>, op: BoxPlotOutlierOption) => Record<string, unknown>[];
|
|
9
|
-
export {};
|
|
6
|
+
export declare const foldOutlierData: (data: Array<DataView>, op: IBoxPlotOutlierOpt) => any;
|
|
@@ -1,10 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
export interface ICorrelationCenterOpt {
|
|
6
|
-
keyword: CorrelationCenterOptionValue<string>;
|
|
7
|
-
categoryField: CorrelationCenterOptionValue<string>;
|
|
8
|
-
}
|
|
9
|
-
export declare const correlationCenter: (data: CorrelationCenterData, options: ICorrelationCenterOpt) => Record<string, unknown> | [];
|
|
10
|
-
export {};
|
|
1
|
+
export declare const correlationCenter: (data: any, options: any) => {
|
|
2
|
+
[x: string]: any;
|
|
3
|
+
[x: number]: any;
|
|
4
|
+
};
|
|
@@ -1,20 +1,17 @@
|
|
|
1
|
-
type CorrelationOptionValue<T> = T | (() => T);
|
|
2
1
|
export interface ICorrelationOpt {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
radiusRange?: CorrelationOptionValue<[number, number] | undefined>;
|
|
12
|
-
center?: CorrelationOptionValue<[string | number, string | number] | undefined>;
|
|
13
|
-
startAngle?: CorrelationOptionValue<number | undefined>;
|
|
14
|
-
endAngle?: CorrelationOptionValue<number | undefined>;
|
|
15
|
-
innerRadius?: CorrelationOptionValue<string | number | undefined>;
|
|
16
|
-
outerRadius?: CorrelationOptionValue<string | number | undefined>;
|
|
2
|
+
field: string;
|
|
3
|
+
radiusField?: string;
|
|
4
|
+
radiusRange?: [number, number];
|
|
5
|
+
center?: [string | number, string | number];
|
|
6
|
+
startAngle?: number;
|
|
7
|
+
endAngle?: number;
|
|
8
|
+
innerRadius?: string | number;
|
|
9
|
+
outerRadius?: string | number;
|
|
17
10
|
}
|
|
18
|
-
export
|
|
19
|
-
|
|
20
|
-
|
|
11
|
+
export interface CircularRelationItem {
|
|
12
|
+
x: number;
|
|
13
|
+
y: number;
|
|
14
|
+
size: number;
|
|
15
|
+
datum: any;
|
|
16
|
+
}
|
|
17
|
+
export declare const correlation: (data: any, options: any) => any;
|