@visactor/vchart-types 1.8.9 → 1.8.10
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 +1 -1
- package/tsconfig.tsbuildinfo +1 -1
- package/types/chart/interface/type.d.ts +1 -1
- package/types/compile/mark/interface.d.ts +0 -9
- package/types/component/axis/cartesian/axis.d.ts +8 -1
- package/types/component/axis/cartesian/interface/spec.d.ts +19 -3
- package/types/component/crosshair/config.d.ts +1 -1
- package/types/component/data-zoom/constant.d.ts +1 -1
- package/types/component/legend/util.d.ts +1 -1
- package/types/component/marker/base-marker.d.ts +5 -1
- package/types/data/transforms/marker-filter.d.ts +5 -0
- package/types/interaction/drill/drillable.d.ts +1 -1
- package/types/interaction/zoom/zoomable.d.ts +1 -1
- package/types/layout/interface.d.ts +0 -1
- package/types/mark/interface/type.d.ts +1 -1
- package/types/series/interface/type.d.ts +1 -2
- package/types/series/range-column/interface.d.ts +2 -2
- package/types/series/word-cloud/interface.d.ts +2 -11
- package/types/typings/shape.d.ts +0 -21
- package/types/typings/space.d.ts +1 -1
- package/types/typings/tooltip/position.d.ts +2 -2
|
@@ -131,15 +131,6 @@ export type STATE_CUSTOM = string;
|
|
|
131
131
|
export type StateValueNot = STATE_HOVER_REVERSE | STATE_CUSTOM;
|
|
132
132
|
export type StateValue = STATE_NORMAL | STATE_HOVER | STATE_CUSTOM;
|
|
133
133
|
export type StateValueType = StateValue | StateValueNot;
|
|
134
|
-
export declare enum STATE_LEVEL {
|
|
135
|
-
NORMAL = 0,
|
|
136
|
-
DIMENSION_SELECTED = 1,
|
|
137
|
-
RELATIONAL_SELECTED = 2,
|
|
138
|
-
SELECTED = 3,
|
|
139
|
-
DIMENSION_HOVER = 4,
|
|
140
|
-
RELATIONAL_HOVER = 5,
|
|
141
|
-
HOVER = 6
|
|
142
|
-
}
|
|
143
134
|
export interface IAttributeOpt {
|
|
144
135
|
element: IElement;
|
|
145
136
|
mark: IElement['mark'];
|
|
@@ -3,7 +3,7 @@ import type { IEffect, IModelInitOption, IModelSpecInfo } from '../../../model/i
|
|
|
3
3
|
import type { ICartesianSeries } from '../../../series/interface';
|
|
4
4
|
import type { IRegion } from '../../../region/interface';
|
|
5
5
|
import type { ICartesianAxisCommonSpec, IAxisHelper } from './interface';
|
|
6
|
-
import type { IOrientType } from '../../../typings/space';
|
|
6
|
+
import type { IOrientType, IRect } from '../../../typings/space';
|
|
7
7
|
import type { IBaseScale } from '@visactor/vscale';
|
|
8
8
|
import type { StringOrNumber } from '../../../typings/common';
|
|
9
9
|
import type { IPoint } from '../../../typings/coordinate';
|
|
@@ -50,6 +50,12 @@ export declare abstract class CartesianAxis<T extends ICartesianAxisCommonSpec =
|
|
|
50
50
|
height: number;
|
|
51
51
|
_lastComputeOutBounds: IBoundsLike;
|
|
52
52
|
};
|
|
53
|
+
protected _innerOffset: {
|
|
54
|
+
top: number;
|
|
55
|
+
bottom: number;
|
|
56
|
+
left: number;
|
|
57
|
+
right: number;
|
|
58
|
+
};
|
|
53
59
|
constructor(spec: T, options: IComponentOption);
|
|
54
60
|
static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
|
|
55
61
|
static createComponent(specInfo: IModelSpecInfo, options: IComponentOption): IAxis;
|
|
@@ -69,6 +75,7 @@ export declare abstract class CartesianAxis<T extends ICartesianAxisCommonSpec =
|
|
|
69
75
|
protected updateScaleRange(): boolean;
|
|
70
76
|
init(option: IModelInitOption): void;
|
|
71
77
|
setAttrFromSpec(): void;
|
|
78
|
+
onLayoutStart(layoutRect: IRect, viewRect: ILayoutRect, ctx: any): void;
|
|
72
79
|
protected getSeriesStatisticsField(s: ICartesianSeries): string[];
|
|
73
80
|
protected _tickTransformOption(coordinateType: CoordinateType): ICartesianTickDataOpt;
|
|
74
81
|
protected _initData(): void;
|
|
@@ -1,10 +1,26 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ILayoutNumber, IRectMarkSpec, StringOrNumber } from '../../../../typings';
|
|
2
2
|
import type { IBandAxisSpec, ILinearAxisSpec, IGrid, ICommonAxisSpec } from '../../interface';
|
|
3
3
|
import type { ICartesianDomainLine, ICartesianLabel, ITimeLayerType, ICartesianTitle, ICartesianAxisUnit } from './common';
|
|
4
4
|
import type { AxisItemStateStyle } from '@visactor/vrender-components';
|
|
5
5
|
export type ICartesianAxisSpec = ICartesianLinearAxisSpec | ICartesianBandAxisSpec | ICartesianTimeAxisSpec | ICartesianLogAxisSpec | ICartesianSymlogAxisSpec;
|
|
6
|
+
export type ICartesianVertical = {
|
|
7
|
+
orient: 'left' | 'right';
|
|
8
|
+
innerOffset?: {
|
|
9
|
+
top?: ILayoutNumber;
|
|
10
|
+
bottom?: ILayoutNumber;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export type ICartesianHorizontal = {
|
|
14
|
+
orient: 'top' | 'bottom';
|
|
15
|
+
innerOffset?: {
|
|
16
|
+
left?: ILayoutNumber;
|
|
17
|
+
right?: ILayoutNumber;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export type ICartesianZ = {
|
|
21
|
+
orient: 'z';
|
|
22
|
+
};
|
|
6
23
|
export type ICartesianAxisCommonSpec = ICommonAxisSpec & {
|
|
7
|
-
orient: IOrientType;
|
|
8
24
|
grid?: IGrid;
|
|
9
25
|
subGrid?: IGrid;
|
|
10
26
|
domainLine?: ICartesianDomainLine;
|
|
@@ -19,7 +35,7 @@ export type ICartesianAxisCommonSpec = ICommonAxisSpec & {
|
|
|
19
35
|
mode?: '2d' | '3d';
|
|
20
36
|
depth?: number;
|
|
21
37
|
unit?: ICartesianAxisUnit;
|
|
22
|
-
};
|
|
38
|
+
} & (ICartesianVertical | ICartesianHorizontal | ICartesianZ);
|
|
23
39
|
export interface ILinearAxisSync {
|
|
24
40
|
axisId: StringOrNumber;
|
|
25
41
|
zeroAlign?: boolean;
|
|
@@ -15,7 +15,7 @@ export declare function transformLegendTitleAttributes(title: ITitle): {
|
|
|
15
15
|
visible?: boolean;
|
|
16
16
|
style?: Omit<import("./interface").NoVisibleMarkStyle<import("../..").IRectMarkSpec>, "visible" | "width" | "height">;
|
|
17
17
|
};
|
|
18
|
-
text?: string | number |
|
|
18
|
+
text?: string | number | number[] | string[];
|
|
19
19
|
visible?: boolean;
|
|
20
20
|
padding?: import("@visactor/vrender-components/es/core/type").Padding;
|
|
21
21
|
maxWidth?: number;
|
|
@@ -18,7 +18,11 @@ export declare abstract class BaseMarker<T extends IMarkerSpec> extends BaseComp
|
|
|
18
18
|
protected _layoutOffsetY: number;
|
|
19
19
|
private _firstSeries;
|
|
20
20
|
created(): void;
|
|
21
|
-
|
|
21
|
+
protected _getAllRelativeSeries(): {
|
|
22
|
+
getRelativeSeries: () => ICartesianSeries;
|
|
23
|
+
getStartRelativeSeries: () => ICartesianSeries;
|
|
24
|
+
getEndRelativeSeries: () => ICartesianSeries;
|
|
25
|
+
};
|
|
22
26
|
private _getFieldInfoFromSpec;
|
|
23
27
|
protected _processSpecX(specX: IDataPos | IDataPosCallback): {
|
|
24
28
|
getRelativeSeries: () => ICartesianSeries;
|
|
@@ -17,7 +17,7 @@ export interface IDrillable {
|
|
|
17
17
|
export declare class Drillable implements IDrillable {
|
|
18
18
|
private _drillParams;
|
|
19
19
|
private _drillInfo;
|
|
20
|
-
private
|
|
20
|
+
private _getDrillTriggerEvent;
|
|
21
21
|
private _hideTooltip;
|
|
22
22
|
initDrillable(params: DrillParams): void;
|
|
23
23
|
initDrillableData(dataSet: DataSet): void;
|
|
@@ -53,7 +53,7 @@ export declare class Zoomable implements IZoomable {
|
|
|
53
53
|
private _gestureController;
|
|
54
54
|
private _isGestureListener;
|
|
55
55
|
initZoomable(evt: IEvent, mode?: RenderMode): void;
|
|
56
|
-
private
|
|
56
|
+
private _getZoomTriggerEvent;
|
|
57
57
|
private _zoomEventDispatch;
|
|
58
58
|
private _getRegionOrSeriesLayout;
|
|
59
59
|
private _bindZoomEventAsRegion;
|
|
@@ -33,7 +33,7 @@ export declare enum SeriesTypeEnum {
|
|
|
33
33
|
heatmap = "heatmap",
|
|
34
34
|
correlation = "correlation"
|
|
35
35
|
}
|
|
36
|
-
export declare enum SeriesMarkNameEnum {
|
|
36
|
+
export declare const enum SeriesMarkNameEnum {
|
|
37
37
|
label = "label",
|
|
38
38
|
point = "point",
|
|
39
39
|
line = "line",
|
|
@@ -90,4 +90,3 @@ export declare enum SeriesMarkNameEnum {
|
|
|
90
90
|
lineLabel = "lineLabel",
|
|
91
91
|
areaLabel = "areaLabel"
|
|
92
92
|
}
|
|
93
|
-
export declare const seriesMarkNameSet: Set<string>;
|
|
@@ -6,13 +6,13 @@ import type { IAnimationSpec } from '../../animation/spec';
|
|
|
6
6
|
import type { RangeColumnAppearPreset } from './animation';
|
|
7
7
|
import type { ILabelSpec } from '../../component/label';
|
|
8
8
|
import type { SeriesMarkNameEnum } from '../interface/type';
|
|
9
|
-
export declare enum PositionEnum {
|
|
9
|
+
export declare const enum PositionEnum {
|
|
10
10
|
middle = "middle",
|
|
11
11
|
start = "start",
|
|
12
12
|
end = "end",
|
|
13
13
|
bothEnd = "bothEnd"
|
|
14
14
|
}
|
|
15
|
-
export declare enum minMaxPositionEnum {
|
|
15
|
+
export declare const enum minMaxPositionEnum {
|
|
16
16
|
middle = "middle",
|
|
17
17
|
start = "start",
|
|
18
18
|
end = "end"
|
|
@@ -2,17 +2,8 @@ import type { ITextMarkSpec, IMarkSpec, ISeriesSpec } from '../../typings';
|
|
|
2
2
|
import type { IAnimationSpec, IMarkAnimateSpec, IStateAnimateSpec } from '../../animation/spec';
|
|
3
3
|
import type { SeriesMarkNameEnum } from '../interface/type';
|
|
4
4
|
import type { WordcloudAppearPreset } from './animation';
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
triangle = "triangle",
|
|
8
|
-
diamond = "diamond",
|
|
9
|
-
square = "square",
|
|
10
|
-
star = "star",
|
|
11
|
-
cardioid = "cardioid",
|
|
12
|
-
circle = "circle",
|
|
13
|
-
pentagon = "pentagon"
|
|
14
|
-
}
|
|
15
|
-
export type WordCloudShapeType = keyof typeof WordCloudShapeEnum;
|
|
5
|
+
import type { shapes } from '@visactor/vgrammar-wordcloud';
|
|
6
|
+
export type WordCloudShapeType = keyof typeof shapes;
|
|
16
7
|
export type EllipsisType = {
|
|
17
8
|
string?: string;
|
|
18
9
|
limitLength?: number;
|
package/types/typings/shape.d.ts
CHANGED
|
@@ -1,26 +1,5 @@
|
|
|
1
1
|
import type { SymbolType } from '@visactor/vrender-core';
|
|
2
|
-
export declare enum ShapeTypeEnum {
|
|
3
|
-
circle = "circle",
|
|
4
|
-
triangle = "triangle",
|
|
5
|
-
triangleUp = "triangleUp",
|
|
6
|
-
triangleLeft = "triangleLeft",
|
|
7
|
-
triangleRight = "triangleRight",
|
|
8
|
-
triangleDown = "triangleDown",
|
|
9
|
-
thinTriangle = "thinTriangle",
|
|
10
|
-
rect = "rect",
|
|
11
|
-
diamond = "diamond",
|
|
12
|
-
square = "square",
|
|
13
|
-
arrowLeft = "arrowLeft",
|
|
14
|
-
arrow2Left = "arrow2Left",
|
|
15
|
-
arrowRight = "arrowRight",
|
|
16
|
-
arrow2Right = "arrow2Right",
|
|
17
|
-
cross = "cross",
|
|
18
|
-
wedge = "wedge",
|
|
19
|
-
star = "star",
|
|
20
|
-
wye = "wye"
|
|
21
|
-
}
|
|
22
2
|
export type ShapeType = SymbolType;
|
|
23
|
-
export declare const ShapeTypes: string[];
|
|
24
3
|
export interface IShapeStyle {
|
|
25
4
|
shape?: ShapeType;
|
|
26
5
|
size?: number;
|
package/types/typings/space.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export interface ITooltipPositionPattern {
|
|
|
5
5
|
top?: number | ITooltipPositionCallback;
|
|
6
6
|
bottom?: number | ITooltipPositionCallback;
|
|
7
7
|
}
|
|
8
|
-
export declare enum TooltipFixedPosition {
|
|
8
|
+
export declare const enum TooltipFixedPosition {
|
|
9
9
|
top = "top",
|
|
10
10
|
bottom = "bottom",
|
|
11
11
|
left = "left",
|
|
@@ -20,7 +20,7 @@ export declare enum TooltipFixedPosition {
|
|
|
20
20
|
rb = "rb",
|
|
21
21
|
inside = "inside"
|
|
22
22
|
}
|
|
23
|
-
export declare enum TooltipPositionMode {
|
|
23
|
+
export declare const enum TooltipPositionMode {
|
|
24
24
|
pointer = "pointer",
|
|
25
25
|
mark = "mark"
|
|
26
26
|
}
|