zhangjian
2023-06-05 0976d2d0f90cff460cedfdc8bd74e98c2c31a58c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
import { DataFormatMixin } from '../../model/mixin/dataFormat.js';
import ComponentModel from '../../model/Component.js';
import SeriesModel from '../../model/Series.js';
import { ComponentOption, AnimationOptionMixin, CommonTooltipOption, ScaleDataValue } from '../../util/types.js';
import Model from '../../model/Model.js';
import GlobalModel from '../../model/Global.js';
import SeriesData from '../../data/SeriesData.js';
export declare type MarkerStatisticType = 'average' | 'min' | 'max' | 'median';
/**
 * Option to specify where to put the marker.
 */
export interface MarkerPositionOption {
    x?: number | string;
    y?: number | string;
    /**
     * Coord on any coordinate system
     */
    coord?: (ScaleDataValue | MarkerStatisticType)[];
    xAxis?: ScaleDataValue;
    yAxis?: ScaleDataValue;
    radiusAxis?: ScaleDataValue;
    angleAxis?: ScaleDataValue;
    type?: MarkerStatisticType;
    /**
     * When using statistic method with type.
     * valueIndex and valueDim can be specify which dim the statistic is used on.
     */
    valueIndex?: number;
    valueDim?: string;
    /**
     * Value to be displayed as label. Totally optional
     */
    value?: string | number;
}
export interface MarkerOption extends ComponentOption, AnimationOptionMixin {
    silent?: boolean;
    data?: unknown[];
    tooltip?: CommonTooltipOption<unknown> & {
        trigger?: 'item' | 'axis' | boolean | 'none';
    };
}
declare abstract class MarkerModel<Opts extends MarkerOption = MarkerOption> extends ComponentModel<Opts> {
    static type: string;
    type: string;
    /**
     * If marker model is created by self from series
     */
    createdBySelf: boolean;
    static readonly dependencies: string[];
    __hostSeries: SeriesModel;
    private _data;
    /**
     * @overrite
     */
    init(option: Opts, parentModel: Model, ecModel: GlobalModel): void;
    isAnimationEnabled(): boolean;
    /**
     * @overrite
     */
    mergeOption(newOpt: Opts, ecModel: GlobalModel): void;
    _mergeOption(newOpt: Opts, ecModel: GlobalModel, createdBySelf?: boolean, isInit?: boolean): void;
    formatTooltip(dataIndex: number, multipleSeries: boolean, dataType: string): import("../tooltip/tooltipMarkup").TooltipMarkupSection;
    getData(): SeriesData<this>;
    setData(data: SeriesData): void;
    /**
     * Create slave marker model from series.
     */
    abstract createMarkerModelFromSeries(markerOpt: Opts, masterMarkerModel: MarkerModel, ecModel: GlobalModel): MarkerModel;
    static getMarkerModelFromSeries(seriesModel: SeriesModel, componentType: 'markLine' | 'markPoint' | 'markArea'): MarkerModel<MarkerOption>;
}
interface MarkerModel<Opts extends MarkerOption = MarkerOption> extends DataFormatMixin {
}
export default MarkerModel;