@visactor/vchart-types 2.0.0-alpha.3 → 2.0.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.
Files changed (38) hide show
  1. package/package.json +3 -3
  2. package/tsconfig.tsbuildinfo +1 -1
  3. package/types/animation/interface.d.ts +1 -0
  4. package/types/chart/base/base-chart.d.ts +1 -2
  5. package/types/chart/interface/chart.d.ts +1 -2
  6. package/types/component/axis/base-axis.d.ts +0 -1
  7. package/types/component/axis/cartesian/axis.d.ts +0 -5
  8. package/types/component/axis/polar/axis.d.ts +0 -2
  9. package/types/component/base/base-component.d.ts +1 -3
  10. package/types/component/brush/brush.d.ts +2 -4
  11. package/types/component/crosshair/base.d.ts +0 -4
  12. package/types/component/crosshair/interface/common.d.ts +3 -1
  13. package/types/component/crosshair/interface/spec.d.ts +1 -0
  14. package/types/component/crosshair/interface/theme.d.ts +2 -0
  15. package/types/component/custom-mark/custom-mark.d.ts +0 -6
  16. package/types/component/data-zoom/data-filter-base-component.d.ts +0 -4
  17. package/types/component/data-zoom/util.d.ts +1 -0
  18. package/types/component/geo/geo-coordinate.d.ts +2 -6
  19. package/types/component/indicator/indicator.d.ts +0 -3
  20. package/types/component/interface/common.d.ts +0 -1
  21. package/types/component/label/base-label.d.ts +2 -6
  22. package/types/component/label/label.d.ts +0 -1
  23. package/types/component/label/total-label.d.ts +0 -1
  24. package/types/component/legend/base-legend.d.ts +0 -3
  25. package/types/component/marker/base-marker.d.ts +1 -4
  26. package/types/component/player/player.d.ts +0 -4
  27. package/types/component/title/title.d.ts +0 -5
  28. package/types/component/tooltip/interface/theme.d.ts +3 -0
  29. package/types/component/tooltip/tooltip.d.ts +0 -6
  30. package/types/mark/base/base-mark.d.ts +1 -0
  31. package/types/mark/group.d.ts +1 -1
  32. package/types/mark/interface/common.d.ts +1 -0
  33. package/types/model/base-model.d.ts +1 -2
  34. package/types/model/interface.d.ts +0 -1
  35. package/types/region/region.d.ts +0 -1
  36. package/types/series/bar/bar.d.ts +3 -0
  37. package/types/series/bar/interface.d.ts +1 -0
  38. package/types/series/base/base-series.d.ts +1 -2
@@ -58,6 +58,7 @@ export interface CommonAnimationConfigItem {
58
58
  loop?: boolean | number;
59
59
  options?: GraphicFunctionValueType<any>;
60
60
  controlOptions?: IAnimationControlOptions;
61
+ selfOnly?: boolean;
61
62
  }
62
63
  export interface TypeAnimationConfig extends CommonAnimationConfigItem {
63
64
  type: string;
@@ -3,7 +3,7 @@ import { ChartData } from '../chart-meta/data';
3
3
  import type { Datum, IMarkStateSpec, IRegionQuerier, MaybeArray, IPadding, IRect, StringOrNumber, IChartSpec, IDataValues, ILayoutRect, ILayoutOrientPadding } from '../../typings';
4
4
  import type { ILayoutItem, LayoutCallBack } from '../../layout/interface';
5
5
  import type { ILayoutModelState, IModel, IModelOption, IModelSpecInfo, IUpdateSpecResult } from '../../model/interface';
6
- import type { IChart, IChartRenderOption, IChartOption, IChartEvaluateOption, DimensionIndexOption, IChartSpecTransformerOption, IChartSpecTransformer } from '../interface';
6
+ import type { IChart, IChartOption, IChartEvaluateOption, DimensionIndexOption, IChartSpecTransformerOption, IChartSpecTransformer } from '../interface';
7
7
  import type { ISeries, ISeriesConstructor } from '../../series/interface';
8
8
  import type { IRegion } from '../../region/interface';
9
9
  import type { IComponent, IComponentConstructor } from '../../component/interface';
@@ -106,7 +106,6 @@ export declare class BaseChart<T extends IChartSpec> extends CompilableBase impl
106
106
  getMarkByUserName(name: string): IMark[];
107
107
  updateData(id: StringOrNumber, data: unknown, updateGlobalScale?: boolean, options?: IParserOptions): void;
108
108
  updateFullData(data: IDataValues | IDataValues[], updateGlobalScale?: boolean): void;
109
- onRender(option: IChartRenderOption): void;
110
109
  setCanvasRect(width: number, height: number): void;
111
110
  getCanvasRect(): Omit<IRect, 'x' | 'y'>;
112
111
  getSeriesData(id: StringOrNumber | undefined, index: number | undefined): DataView | undefined;
@@ -6,7 +6,7 @@ import type { IMark } from '../../mark/interface';
6
6
  import type { IModel, IModelConstructor, IModelOption, IModelSpecInfo, IUpdateSpecResult } from '../../model/interface';
7
7
  import type { IRegion, IRegionConstructor } from '../../region/interface';
8
8
  import type { ISeries, ISeriesConstructor } from '../../series/interface';
9
- import type { IChartEvaluateOption, IChartLayoutOption, IChartOption, IChartRenderOption, IChartSpecInfo, IChartSpecTransformerOption } from './common';
9
+ import type { IChartEvaluateOption, IChartLayoutOption, IChartOption, IChartSpecInfo, IChartSpecTransformerOption } from './common';
10
10
  import type { IBoundsLike, IPadding, Maybe } from '@visactor/vutils';
11
11
  import type { ICompilable } from '../../compile/interface';
12
12
  import type { IRegionQuerier, MaybeArray, Datum, IMarkStateSpec, StringOrNumber, IShowTooltipOption, IDataValues, ILayoutRect, IData } from '../../typings';
@@ -53,7 +53,6 @@ export interface IChart extends ICompilable {
53
53
  onLayoutStart: (ctx: IChartLayoutOption) => void;
54
54
  onLayoutEnd: (ctx: IChartLayoutOption) => void;
55
55
  onEvaluateEnd: (ctx: IChartEvaluateOption) => void;
56
- onRender: (ctx: IChartRenderOption) => void;
57
56
  onResize: (width: number, height: number, reRender: boolean) => void;
58
57
  onLayout: () => void;
59
58
  reInit: () => void;
@@ -51,7 +51,6 @@ export declare abstract class AxisComponent<T extends ICommonAxisSpec & Record<s
51
51
  protected _coordinateType: CoordinateType;
52
52
  getCoordinateType(): CoordinateType;
53
53
  constructor(spec: T, options: IComponentOption);
54
- protected _getNeedClearVRenderComponents(): IGraphic[];
55
54
  getVRenderComponents(): import("@visactor/vrender-core").IGroup[];
56
55
  created(): void;
57
56
  protected _shouldComputeTickData(): boolean;
@@ -1,7 +1,6 @@
1
1
  import { type IBoundsLike, type Maybe } from '@visactor/vutils';
2
2
  import type { IEffect, IModelInitOption, IModelSpecInfo } from '../../../model/interface';
3
3
  import type { ICartesianSeries } from '../../../series/interface';
4
- import type { IRegion } from '../../../region/interface';
5
4
  import type { ICartesianAxisCommonSpec, IAxisHelper } from './interface';
6
5
  import type { IOrientType, IPadding, IRect } from '../../../typings/space';
7
6
  import type { IBaseScale } from '@visactor/vscale';
@@ -73,10 +72,6 @@ export declare abstract class CartesianAxis<T extends ICartesianAxisCommonSpec =
73
72
  protected _tickTransformOption(): ICartesianTickDataOpt;
74
73
  protected axisHelper(): IAxisHelper;
75
74
  afterCompile(): void;
76
- onRender(ctx: any): void;
77
- changeRegions(regions: IRegion[]): void;
78
- update(ctx: IComponentOption): void;
79
- resize(ctx: IComponentOption): void;
80
75
  protected collectScale(): IBaseScale[];
81
76
  protected collectSeriesField(depth: number, series: ICartesianSeries): string | string[];
82
77
  protected updateSeriesScale(): void;
@@ -45,8 +45,6 @@ export declare abstract class PolarAxis<T extends IPolarAxisCommonSpec = IPolarA
45
45
  effect: IEffect;
46
46
  setAttrFromSpec(): void;
47
47
  _transformLayoutPosition: (pos: Partial<IPoint>) => Partial<IPoint>;
48
- onRender(ctx: any): void;
49
- changeRegions(): void;
50
48
  protected _tickTransformOption(): IPolarTickDataOpt;
51
49
  protected updateScaleRange(): boolean;
52
50
  protected collectSeriesField(depth: number, series: IPolarSeries): string | string[];
@@ -7,7 +7,7 @@ import type { Datum, ILayoutRect } from '../../typings';
7
7
  import type { IComponentSpec } from './interface';
8
8
  import { LayoutModel } from '../../model/layout-model';
9
9
  import { BaseComponentSpecTransformer } from './base-component-transformer';
10
- import type { IModelRenderOption, IModelSpecInfo } from '../../model/interface';
10
+ import type { IModelSpecInfo } from '../../model/interface';
11
11
  export declare class BaseComponent<T extends IComponentSpec = IComponentSpec> extends LayoutModel<T> implements IComponent {
12
12
  static transformerConstructor: typeof BaseComponentSpecTransformer;
13
13
  name: string;
@@ -21,9 +21,7 @@ export declare class BaseComponent<T extends IComponentSpec = IComponentSpec> ex
21
21
  protected _container: IGroup;
22
22
  created(): void;
23
23
  initLayout(): void;
24
- changeRegions(regions: IRegion[]): void;
25
24
  protected _getNeedClearVRenderComponents(): IGraphic[];
26
- onRender(ctx: IModelRenderOption): void;
27
25
  getVRenderComponents(): IGraphic<Partial<IGraphicAttribute>>[];
28
26
  protected callPlugin(cb: (plugin: IComponentPlugin) => void): void;
29
27
  protected getContainer(): IGroup;
@@ -2,7 +2,7 @@ import { BaseComponent } from '../base/base-component';
2
2
  import { ComponentTypeEnum } from '../interface/type';
3
3
  import { Brush as BrushComponent } from '@visactor/vrender-components';
4
4
  import type { Maybe } from '@visactor/vutils';
5
- import type { IModelRenderOption, IModelSpecInfo } from '../../model/interface';
5
+ import type { IModelSpecInfo } from '../../model/interface';
6
6
  import type { IRegion } from '../../region/interface';
7
7
  import type { IGraphic } from '@visactor/vrender-core';
8
8
  import type { ISeries } from '../../series/interface';
@@ -41,7 +41,6 @@ export declare class Brush<T extends IBrushSpec = IBrushSpec> extends BaseCompon
41
41
  [elementKey: string]: IMarkGraphic;
42
42
  };
43
43
  private _cacheInteractiveRangeAttrs;
44
- private _needDisablePickable;
45
44
  private _releatedAxes;
46
45
  private _regionAxisMap;
47
46
  private _axisDataZoomMap;
@@ -55,8 +54,6 @@ export declare class Brush<T extends IBrushSpec = IBrushSpec> extends BaseCompon
55
54
  private _initRegionAxisMap;
56
55
  private _initAxisDataZoomMap;
57
56
  protected initEvent(): void;
58
- onRender(ctx: IModelRenderOption): void;
59
- changeRegions(regions: IRegion[]): void;
60
57
  _compareSpec(spec: T, prevSpec: T): {
61
58
  change: boolean;
62
59
  reMake: boolean;
@@ -86,6 +83,7 @@ export declare class Brush<T extends IBrushSpec = IBrushSpec> extends BaseCompon
86
83
  private _isBrushContainItem;
87
84
  protected _initItemMap(itemMap: Record<string, IMark[]>, elementMap: Record<string, IMarkGraphic>, stateName: string): void;
88
85
  protected _initMarkBrushState(componentIndex: number, stateName: string): void;
86
+ private _setRegionMarkPickable;
89
87
  private _stateClamp;
90
88
  private _setAxisAndDataZoom;
91
89
  protected _getNeedClearVRenderComponents(): IGraphic[];
@@ -1,8 +1,6 @@
1
1
  import type { IBoundsLike } from '@visactor/vutils';
2
2
  import { Tag } from '@visactor/vrender-components';
3
3
  import type { IGraphic } from '@visactor/vrender-core';
4
- import type { IModelRenderOption } from '../../model/interface';
5
- import type { IRegion } from '../../region/interface';
6
4
  import { BaseComponent } from '../base/base-component';
7
5
  import type { IPoint, StringOrNumber, TooltipActiveType, TooltipData } from '../../typings';
8
6
  import type { IComponentOption } from '../interface';
@@ -67,9 +65,7 @@ export declare abstract class BaseCrossHair<T extends ICartesianCrosshairSpec |
67
65
  private _handleTooltipShow;
68
66
  private _handleTooltipHideOrRelease;
69
67
  protected _getAxisInfoByField<T = IAxis>(field: 'x' | 'y' | 'category' | 'value'): IAxisInfo<T>;
70
- changeRegions(regions: IRegion[]): void;
71
68
  onLayoutEnd(): void;
72
- onRender(ctx: IModelRenderOption): void;
73
69
  protected _releaseEvent(): void;
74
70
  protected _parseFieldInfo(): void;
75
71
  protected _parseCrosshairSpec(): void;
@@ -2,7 +2,7 @@ import type { Dict } from '@visactor/vutils';
2
2
  import type { IPadding, StringOrNumber } from '../../../typings';
3
3
  import type { IAxis } from '../../axis/interface';
4
4
  import type { LineCrosshair, RectCrosshair, Tag } from '@visactor/vrender-components';
5
- import type { IGroup, IRichTextGraphicAttribute, ITextGraphicAttribute } from '@visactor/vrender-core';
5
+ import type { IGroup, IRichTextGraphicAttribute, IText, ITextGraphicAttribute } from '@visactor/vrender-core';
6
6
  export type AxisCurrentValueMap = Map<number, {
7
7
  datum: StringOrNumber;
8
8
  axis: IAxis;
@@ -31,6 +31,7 @@ export interface IHair {
31
31
  padding?: IPadding | number | number[];
32
32
  panel?: Dict<any>;
33
33
  zIndex?: number;
34
+ syncAxisLabelAngle?: boolean;
34
35
  };
35
36
  smooth?: boolean;
36
37
  }
@@ -56,6 +57,7 @@ export interface ICrosshairInfo {
56
57
  visible: boolean;
57
58
  _isCache?: boolean;
58
59
  axis: IAxis;
60
+ axisLabel?: IText;
59
61
  sides?: number;
60
62
  }
61
63
  export interface CrossHairStateItem {
@@ -65,6 +65,7 @@ export interface ICrosshairLabelSpec {
65
65
  formatter?: string | string[];
66
66
  style?: Partial<ITextMarkSpec>;
67
67
  labelBackground?: ICrosshairLabelBackgroundSpec;
68
+ syncAxisLabelAngle?: boolean;
68
69
  }
69
70
  export interface ICrosshairLabelBackgroundSpec {
70
71
  visible?: boolean;
@@ -6,4 +6,6 @@ export interface ICrosshairTheme extends ICommonCrosshairSpec {
6
6
  yField?: Partial<ICartesianCrosshairSpec['yField']>;
7
7
  categoryField?: Partial<IPolarCrosshairSpec['categoryField']>;
8
8
  valueField?: Partial<IPolarCrosshairSpec['valueField']>;
9
+ trigger?: ICommonCrosshairSpec['trigger'];
10
+ triggerOff?: ICommonCrosshairSpec['triggerOff'];
9
11
  }
@@ -1,9 +1,6 @@
1
1
  import { BaseComponent } from '../base/base-component';
2
2
  import { ComponentTypeEnum } from '../interface/type';
3
- import type { IRegion } from '../../region/interface';
4
- import type { IModelRenderOption } from '../../model/interface';
5
3
  import type { EnableMarkType, ICustomMarkGroupSpec, ICustomMarkSpec, ILayoutRect } from '../../typings';
6
- import type { IGraphic } from '@visactor/vrender-core';
7
4
  import type { IModelMarkAttributeContext } from '../../compile/mark/interface';
8
5
  export declare class CustomMark extends BaseComponent<ICustomMarkSpec<EnableMarkType>> {
9
6
  static type: ComponentTypeEnum;
@@ -28,9 +25,6 @@ export declare class CustomMark extends BaseComponent<ICustomMarkSpec<EnableMark
28
25
  reSize: boolean;
29
26
  reCompile: boolean;
30
27
  };
31
- changeRegions(regions: IRegion[]): void;
32
- protected _getNeedClearVRenderComponents(): IGraphic[];
33
- onRender(ctx: IModelRenderOption): void;
34
28
  private _getMarkAttributeContext;
35
29
  private _getLayoutRect;
36
30
  getBoundsInRect(rect: ILayoutRect): {
@@ -87,7 +87,6 @@ export declare abstract class DataFilterBaseComponent<T extends IDataFilterCompo
87
87
  protected _initStateScale(): void;
88
88
  init(option: IModelInitOption): void;
89
89
  protected _addTransformToSeries(): void;
90
- onRender(ctx: any): void;
91
90
  _compareSpec(spec: AdaptiveSpec<T, 'width' | 'height'>, prevSpec: AdaptiveSpec<T, 'width' | 'height'>): {
92
91
  change: boolean;
93
92
  reMake: boolean;
@@ -96,9 +95,6 @@ export declare abstract class DataFilterBaseComponent<T extends IDataFilterCompo
96
95
  reCompile: boolean;
97
96
  };
98
97
  reInit(spec?: AdaptiveSpec<T, 'width' | 'height'>): void;
99
- changeRegions(): void;
100
- protected update(ctx: IComponentOption): void;
101
- protected resize(ctx: IComponentOption): void;
102
98
  protected _parseDomainFromState(startValue: number | string, endValue: number | string): any;
103
99
  protected _handleStateChange: (startValue: number, endValue: number, tag?: string) => boolean;
104
100
  protected _handleChartZoom: (params: {
@@ -12,6 +12,7 @@ export interface IDataFilterComputeDomainOption {
12
12
  dataCollection: any[];
13
13
  stateFields: string[];
14
14
  valueFields: string[];
15
+ isCategoryState?: boolean;
15
16
  method: 'sum';
16
17
  };
17
18
  output: {
@@ -1,13 +1,12 @@
1
1
  import type { IPoint } from '../../typings/coordinate';
2
2
  import { Projection } from './projection';
3
- import type { IEffect, IModelRenderOption, IModelSpecInfo } from '../../model/interface';
3
+ import type { IEffect, IModelSpecInfo } from '../../model/interface';
4
4
  import { ComponentTypeEnum } from '../interface/type';
5
5
  import { BaseComponent } from '../base/base-component';
6
- import type { IGeoRegionSpec, IRegion } from '../../region/interface';
6
+ import type { IGeoRegionSpec } from '../../region/interface';
7
7
  import type { IGeoCoordinate, IGeoCoordinateSpec, IProjectionSpec } from './interface';
8
8
  import type { StringOrNumber } from '../../typings';
9
9
  import type { Maybe } from '@visactor/vutils';
10
- import type { IGraphic } from '@visactor/vrender-core';
11
10
  export declare function projectionName(key: string, id: number): string;
12
11
  export declare class GeoCoordinate extends BaseComponent<IGeoRegionSpec> implements IGeoCoordinate {
13
12
  static type: ComponentTypeEnum;
@@ -43,9 +42,6 @@ export declare class GeoCoordinate extends BaseComponent<IGeoRegionSpec> impleme
43
42
  initProjection(): void;
44
43
  coordinateHelper(): void;
45
44
  onLayoutEnd(): void;
46
- onRender(ctx: IModelRenderOption): void;
47
- changeRegions(regions: IRegion[]): void;
48
- protected _getNeedClearVRenderComponents(): IGraphic[];
49
45
  protected collectFeatures(): any[];
50
46
  dataToPosition(values?: number[]): IPoint;
51
47
  dataToLatitude(lat: number): number;
@@ -1,6 +1,5 @@
1
1
  import { ComponentTypeEnum } from '../interface/type';
2
2
  import { BaseComponent } from '../base/base-component';
3
- import type { IRegion } from '../../region/interface';
4
3
  import type { IIndicator, IIndicatorSpec } from './interface';
5
4
  import type { Maybe } from '../../typings';
6
5
  import type { IModelSpecInfo } from '../../model/interface';
@@ -28,8 +27,6 @@ export declare class Indicator<T extends IIndicatorSpec> extends BaseComponent<T
28
27
  static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
29
28
  created(): void;
30
29
  setAttrFromSpec(): void;
31
- onRender(ctx: any): void;
32
- changeRegions(regions: IRegion[]): void;
33
30
  protected initEvent(): void;
34
31
  updateDatum(datum: any): void;
35
32
  private initData;
@@ -24,7 +24,6 @@ export interface IComponent extends ILayoutModel {
24
24
  readonly name: string;
25
25
  getRegions: () => IRegion[];
26
26
  getBindSeriesFilter?: () => ISeriesFilter;
27
- changeRegions: (regions: IRegion[]) => void;
28
27
  getVRenderComponents: () => IGraphic[];
29
28
  clear: () => void;
30
29
  getDatum: (childGraphic?: IGraphic) => any | undefined;
@@ -1,10 +1,7 @@
1
1
  import { BaseComponent } from '../base/base-component';
2
2
  import type { IComponentOption } from '../interface';
3
3
  import { ComponentTypeEnum } from '../interface/type';
4
- import type { IRegion } from '../../region/interface';
5
- import type { IModelRenderOption } from '../../model/interface';
6
4
  import type { ILabelSpec } from './interface';
7
- import type { IGraphic } from '@visactor/vrender-core';
8
5
  import type { IComponentMark } from '../../mark/interface/mark';
9
6
  import type { ICompilableMark } from '../../compile/mark/interface';
10
7
  import type { IMark } from '../../mark/interface/common';
@@ -34,7 +31,6 @@ export declare abstract class BaseLabelComponent<T = any> extends BaseComponent<
34
31
  };
35
32
  _getDataLabelType(baseMark: ICompilableMark, type?: string): string;
36
33
  _setTransformOfComponent(labelComponent: IComponentMark, baseMark: IMark | IMark[]): void;
37
- onRender(ctx: IModelRenderOption): void;
38
- changeRegions(regions: IRegion[]): void;
39
- protected _getNeedClearVRenderComponents(): IGraphic[];
34
+ getVRenderComponents(): any[];
35
+ clear(): void;
40
36
  }
@@ -36,7 +36,6 @@ export declare class Label<T extends IChartSpec = any> extends BaseLabelComponen
36
36
  protected _updateSingleLabelAttribute(labelInfo: ILabelInfo, labelComponent: IComponentMark): void;
37
37
  protected _updateLabelComponentAttribute(labelComponent: IComponentMark, baseMark: IMark | IMark[], labelInfos: ILabelInfo[]): void;
38
38
  compileMarks(): void;
39
- getVRenderComponents(): any[];
40
39
  getLabelInfoByTextGraphic(text: IGraphic): ILabelInfo;
41
40
  }
42
41
  export declare const registerLabel: () => void;
@@ -25,7 +25,6 @@ export declare class TotalLabel extends BaseLabelComponent {
25
25
  protected _initLabelComponent(): void;
26
26
  updateLayoutAttribute(): void;
27
27
  compileMarks(): void;
28
- getVRenderComponents(): any[];
29
28
  protected _getSeries(): ISeries;
30
29
  }
31
30
  export declare function totalLabelPosition(series: ISeries, type: MarkType, position?: 'top' | 'bottom'): string;
@@ -1,5 +1,4 @@
1
1
  import type { DataView } from '@visactor/vdataset';
2
- import type { IRegion } from '../../region/interface';
3
2
  import { BaseComponent } from '../base/base-component';
4
3
  import type { IEffect } from '../../model/interface';
5
4
  import type { ILayoutRect, ILayoutType, IOrientType, IPoint, StringOrNumber } from '../../typings';
@@ -32,7 +31,6 @@ export declare abstract class BaseLegend<T extends ILegendCommonSpec> extends Ba
32
31
  protected _regionUserIndex?: number[];
33
32
  setAttrFromSpec(): void;
34
33
  created(): void;
35
- onRender(ctx: any): void;
36
34
  _compareSpec(spec: T, prevSpec: T): {
37
35
  change: boolean;
38
36
  reMake: boolean;
@@ -40,7 +38,6 @@ export declare abstract class BaseLegend<T extends ILegendCommonSpec> extends Ba
40
38
  reSize: boolean;
41
39
  reCompile: boolean;
42
40
  };
43
- changeRegions(regions: IRegion[]): void;
44
41
  protected abstract _initLegendData(): DataView;
45
42
  protected abstract _initSelectedData(): void;
46
43
  protected abstract _getLegendAttributes(rect: ILayoutRect): any;
@@ -1,7 +1,6 @@
1
1
  import { DataView } from '@visactor/vdataset';
2
2
  import type { Maybe } from '@visactor/vutils';
3
- import type { IModelRenderOption, IModelSpecInfo } from '../../model/interface';
4
- import type { IRegion } from '../../region/interface';
3
+ import type { IModelSpecInfo } from '../../model/interface';
5
4
  import type { CoordinateType, ILayoutRect, ILayoutType, IRect } from '../../typings';
6
5
  import { BaseComponent } from '../base/base-component';
7
6
  import type { IDataPos, IDataPosCallback, IMarkerAttributeContext, IMarkerSpec, IMarkerSupportSeries, IMarkProcessOptions } from './interface';
@@ -54,8 +53,6 @@ export declare abstract class BaseMarker<T extends IMarkerSpec> extends BaseComp
54
53
  private _getSeriesByIdOrIndex;
55
54
  protected _bindSeries(): void;
56
55
  protected initEvent(): void;
57
- onRender(ctx: IModelRenderOption): void;
58
- changeRegions(regions: IRegion[]): void;
59
56
  clear(): void;
60
57
  private _getFirstSeries;
61
58
  protected _getNeedClearVRenderComponents(): IGraphic[];
@@ -1,6 +1,4 @@
1
1
  import type { IGraphic } from '@visactor/vrender-core';
2
- import type { IModelRenderOption } from '../../model/interface';
3
- import type { IRegion } from '../../region/interface';
4
2
  import type { IPlayer } from './interface';
5
3
  import type { IComponent } from '../interface';
6
4
  import type { IPoint, IOrientType, ILayoutRect } from '../../typings';
@@ -38,8 +36,6 @@ export declare class Player extends BaseComponent<IPlayer> implements IComponent
38
36
  y1: number;
39
37
  y2: number;
40
38
  };
41
- changeRegions(regions: IRegion[]): void;
42
- onRender(ctx: IModelRenderOption): void;
43
39
  protected _getNeedClearVRenderComponents(): IGraphic[];
44
40
  private _getPlayerAttrs;
45
41
  private _createOrUpdatePlayerComponent;
@@ -1,5 +1,4 @@
1
1
  import type { IModelSpecInfo } from '../../model/interface';
2
- import type { IRegion } from '../../region/interface';
3
2
  import type { IPoint, IOrientType, ILayoutType, ILayoutRect } from '../../typings';
4
3
  import { BaseComponent } from '../base/base-component';
5
4
  import type { IComponentOption } from '../interface';
@@ -25,7 +24,6 @@ export declare class Title<T extends ITitleSpec = ITitleSpec> extends BaseCompon
25
24
  constructor(spec: T, options: IComponentOption);
26
25
  initLayout(): void;
27
26
  static getSpecInfo(chartSpec: any): Maybe<IModelSpecInfo[]>;
28
- onRender(ctx: any): void;
29
27
  _compareSpec(spec: T, prevSpec: T): {
30
28
  change: boolean;
31
29
  reMake: boolean;
@@ -33,9 +31,6 @@ export declare class Title<T extends ITitleSpec = ITitleSpec> extends BaseCompon
33
31
  reSize: boolean;
34
32
  reCompile: boolean;
35
33
  };
36
- changeRegions(regions: IRegion[]): void;
37
- update(ctx: IComponentOption): void;
38
- resize(ctx: IComponentOption): void;
39
34
  afterSetLayoutStartPoint(pos: IPoint): void;
40
35
  getBoundsInRect(rect: ILayoutRect): {
41
36
  x1: number;
@@ -2,6 +2,7 @@ import type { ITextAttribute } from '@visactor/vrender-core';
2
2
  import type { ILayoutNumber, ITooltipShapePattern, StringOrNumber, TextAlign, TextBaseLine } from '../../../typings';
3
3
  import type { Padding } from '@visactor/vrender-components';
4
4
  import type { ITokenKey } from '../../../theme/token/interface';
5
+ import type { ITooltipSpec } from './spec';
5
6
  export interface ITooltipTextTheme<ColorType = string> {
6
7
  fontFamily?: string;
7
8
  fontSize?: number | ITokenKey;
@@ -49,4 +50,6 @@ export interface ITooltipTheme<ColorType = string> {
49
50
  };
50
51
  transitionDuration?: number;
51
52
  align?: 'left' | 'right';
53
+ trigger?: ITooltipSpec['trigger'];
54
+ triggerOff?: ITooltipSpec['triggerOff'];
52
55
  }
@@ -1,6 +1,4 @@
1
1
  import { ComponentTypeEnum } from '../interface/type';
2
- import type { IModelRenderOption } from '../../model/interface';
3
- import type { IRegion } from '../../region/interface';
4
2
  import { BaseComponent } from '../base/base-component';
5
3
  import type { BaseEventParams, EventCallback, EventQuery, EventType } from '../../event/interface';
6
4
  import type { ITooltipHandler, TooltipActiveType } from '../../typings/tooltip';
@@ -8,7 +6,6 @@ import type { Datum, IShowTooltipOption } from '../../typings';
8
6
  import type { ITooltip, ITooltipActiveTypeAsKeys, ITooltipSpec, TooltipHandlerParams, TotalMouseEventData } from './interface';
9
7
  import { TooltipResult } from './interface/common';
10
8
  import type { DimensionTooltipInfo, GroupTooltipInfo, ITooltipProcessor, MarkTooltipInfo } from './processor/interface';
11
- import type { IGraphic } from '@visactor/vrender-core';
12
9
  import { TooltipSpecTransformer } from './tooltip-transformer';
13
10
  export declare class Tooltip extends BaseComponent<any> implements ITooltip {
14
11
  protected layoutZIndex: number;
@@ -43,12 +40,9 @@ export declare class Tooltip extends BaseComponent<any> implements ITooltip {
43
40
  protected _clickLock: boolean;
44
41
  private _handleMouseMove;
45
42
  isTooltipShown(): boolean;
46
- changeRegions(regions: IRegion[]): void;
47
- protected _getNeedClearVRenderComponents(): IGraphic[];
48
43
  protected _registerEvent(): void;
49
44
  protected _releaseEvent(): void;
50
45
  onLayoutEnd(): void;
51
- onRender(ctx: IModelRenderOption): void;
52
46
  created(): void;
53
47
  release(): void;
54
48
  beforeRelease(): void;
@@ -112,6 +112,7 @@ export declare class BaseMark<T extends ICommonSpec> extends GrammarItem impleme
112
112
  protected _prevDataByKey: GroupedData<Datum>;
113
113
  protected _graphicMap: Map<string, IMarkGraphic>;
114
114
  protected _graphics: IMarkGraphic[];
115
+ needClear?: boolean;
115
116
  protected _keyGetter: (datum: Datum) => string;
116
117
  protected _groupKeyGetter: (datum: Datum) => string;
117
118
  protected renderContext?: {
@@ -22,7 +22,7 @@ export declare class GroupMark extends BaseMark<IGroupMarkSpec> implements IGrou
22
22
  protected _compileProduct(option?: IMarkCompileOption): void;
23
23
  protected _getAttrsFromConfig(attrs?: IGroupGraphicAttribute): IGroupGraphicAttribute;
24
24
  getGraphics(): IMarkGraphic[];
25
- protected _renderSelf(): void;
25
+ renderInner(): void;
26
26
  render(): void;
27
27
  updateAnimationState(callback: (g: IMarkGraphic) => AnimationStateValues): void;
28
28
  release(): void;
@@ -94,6 +94,7 @@ export interface IMarkRaw<T extends ICommonSpec> extends ICompilableMark {
94
94
  canAnimateAfterProgressive: () => boolean;
95
95
  updateAnimationState: (callback: (graphic: IMarkGraphic) => AnimationStateValues) => void;
96
96
  runAnimation: () => void;
97
+ needClear?: boolean;
97
98
  }
98
99
  export type IMark = IMarkRaw<ICommonSpec>;
99
100
  export interface ICompileMarkConfig extends IMarkConfig {
@@ -1,5 +1,5 @@
1
1
  import type { IEvent } from '../event/interface';
2
- import type { IEffect, IModel, IModelInitOption, IModelOption, IModelRenderOption, IModelEvaluateOption, IModelSpec, IModelMarkInfo, IModelSpecInfo } from './interface';
2
+ import type { IEffect, IModel, IModelInitOption, IModelOption, IModelEvaluateOption, IModelSpec, IModelMarkInfo, IModelSpecInfo } from './interface';
3
3
  import type { CoordinateType } from '../typings/coordinate';
4
4
  import type { ICompileMarkConfig, IMark, IMarkOption, IMarkRaw, IMarkStyle } from '../mark/interface';
5
5
  import type { Datum, StateValueType, ConvertToMarkStyleSpec, ICommonSpec, StringOrNumber, IRect, ILayoutRect } from '../typings';
@@ -45,7 +45,6 @@ export declare abstract class BaseModel<T extends IModelSpec> extends Compilable
45
45
  onLayoutStart(layoutRect: IRect, viewRect: ILayoutRect): void;
46
46
  onLayoutEnd(): void;
47
47
  onEvaluateEnd(ctx: IModelEvaluateOption): void;
48
- abstract onRender(ctx: IModelRenderOption): void;
49
48
  onDataUpdate(): void;
50
49
  beforeRelease(): void;
51
50
  clear(): void;
@@ -75,7 +75,6 @@ export interface IModel extends ICompilable {
75
75
  reInit: (spec?: any) => void;
76
76
  beforeRelease: () => void;
77
77
  onEvaluateEnd: (ctx: IModelEvaluateOption) => void;
78
- onRender: (ctx: IModelRenderOption) => void;
79
78
  onDataUpdate: () => void;
80
79
  updateSpec: (spec: any, totalSpec?: any) => IUpdateSpecResult;
81
80
  getSpec?: () => any;
@@ -64,7 +64,6 @@ export declare class Region<T extends IRegionSpec = IRegionSpec> extends LayoutM
64
64
  getSeriesInType(type: string): ISeries[];
65
65
  getSeriesInCoordinateType(coordinateType: CoordinateType): ISeries[];
66
66
  getSeriesInDataName(dataName: string): ISeries[];
67
- onRender(ctx: any): void;
68
67
  initSeriesDataflow(): void;
69
68
  seriesDataFilterOver: () => void;
70
69
  release(): void;
@@ -38,10 +38,13 @@ export declare class BarSeries<T extends IBarSeriesSpec = IBarSeriesSpec> extend
38
38
  protected _dataToPosX1(datum: Datum): number;
39
39
  protected _dataToPosY(datum: Datum): number;
40
40
  protected _dataToPosY1(datum: Datum): number;
41
+ protected _getLinearBarRange: (start: number, end: number) => number[];
41
42
  protected _getBarXStart: (datum: Datum, scale: IBaseScale, useWholeRange?: boolean) => any;
42
43
  protected _getBarXEnd: (datum: Datum, scale: IBaseScale, useWholeRange?: boolean) => any;
44
+ protected _getLinearBarXRange: (datum: Datum, scale: IBaseScale, useWholeRange?: boolean) => number[];
43
45
  protected _getBarYStart: (datum: Datum, scale: IBaseScale) => any;
44
46
  protected _getBarYEnd: (datum: Datum, scale: IBaseScale) => any;
47
+ protected _getLinearBarYRange: (datum: Datum, scale: IBaseScale, useWholeRange?: boolean) => number[];
45
48
  initBandRectMarkStyle(): void;
46
49
  protected _initStackBarMarkStyle(): void;
47
50
  initLinearRectMarkStyle(): void;
@@ -33,6 +33,7 @@ export interface IBarSeriesSpec extends ICartesianSeriesSpec, IAnimationSpec<Bar
33
33
  barGapInGroup?: number | string | (number | string)[];
34
34
  barMinHeight?: number;
35
35
  stackCornerRadius?: number | number[] | IStackCornerRadiusCallback;
36
+ barGap?: number;
36
37
  }
37
38
  export interface IBarBackgroundSpec {
38
39
  fieldLevel?: number;
@@ -5,7 +5,7 @@ import type { ICompileMarkConfig, IGroupMark, IMark } from '../../mark/interface
5
5
  import type { CoordinateType, IInvalidType, IPoint, DataKeyType, Datum, Maybe, ISeriesSpec, IExtensionMarkSpec, IExtensionGroupMarkSpec, EnableMarkType, IGroup, ILayoutType, ILayoutPoint, ILayoutRect } from '../../typings';
6
6
  import { BaseModel } from '../../model/base-model';
7
7
  import type { ISeriesOption, ISeries, ISeriesMarkInitOption, ISeriesStackData, ISeriesTooltipHelper, SeriesMarkMap, ISeriesMarkInfo, ISeriesSpecInfo, ISeriesStackDataLeaf, ISeriesStackDataMeta, ISeriesSeriesInfo } from '../interface';
8
- import type { IModelEvaluateOption, IModelRenderOption, IUpdateSpecResult } from '../../model/interface';
8
+ import type { IModelEvaluateOption, IUpdateSpecResult } from '../../model/interface';
9
9
  import type { AddVChartPropertyContext } from '../../data/transforms/add-property';
10
10
  import type { IHoverSpec, ISelectSpec } from '../../interaction/interface/spec';
11
11
  import type { ISeriesMarkAttributeContext } from '../../compile/mark';
@@ -180,7 +180,6 @@ export declare abstract class BaseSeries<T extends ISeriesSpec> extends BaseMode
180
180
  _updateSpecData(): void;
181
181
  reInit(spec?: T): void;
182
182
  onEvaluateEnd(ctx: IModelEvaluateOption): void;
183
- onRender(ctx: IModelRenderOption): void;
184
183
  release(): void;
185
184
  setLayoutStartPosition(pos: Partial<IPoint>): void;
186
185
  setLayoutRect({ width, height }: Partial<ILayoutRect>, levelMap?: Partial<ILayoutRect>): void;