‘liusuyi’
2023-08-09 161b9318e345c8a0c9cdc133b33a1c759495f323
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
import GlobalModel from '../../model/Global.js';
import ExtensionAPI from '../../core/ExtensionAPI.js';
import { Payload, CommonAxisPointerOption } from '../../util/types.js';
import { AxisPointerOption } from './AxisPointerModel.js';
declare type AxisValue = CommonAxisPointerOption['value'];
interface DataIndex {
    seriesIndex: number;
    dataIndex: number;
    dataIndexInside: number;
}
export interface DataByAxis {
    value: string | number;
    axisIndex: number;
    axisDim: string;
    axisType: string;
    axisId: string;
    seriesDataIndices: DataIndex[];
    valueLabelOpt: {
        precision: AxisPointerOption['label']['precision'];
        formatter: AxisPointerOption['label']['formatter'];
    };
}
export interface DataByCoordSys {
    coordSysId: string;
    coordSysIndex: number;
    coordSysType: string;
    coordSysMainType: string;
    dataByAxis: DataByAxis[];
}
interface AxisTriggerPayload extends Payload {
    currTrigger?: 'click' | 'mousemove' | 'leave';
    /**
     * x and y, which are mandatory, specify a point to trigger axisPointer and tooltip.
     */
    x?: number;
    /**
     * x and y, which are mandatory, specify a point to trigger axisPointer and tooltip.
     */
    y?: number;
    /**
     * finder, optional, restrict target axes.
     */
    seriesIndex?: number;
    dataIndex: number;
    axesInfo?: {
        axisDim?: string;
        axisIndex?: number;
        value?: AxisValue;
    }[];
    dispatchAction: ExtensionAPI['dispatchAction'];
}
/**
 * Basic logic: check all axis, if they do not demand show/highlight,
 * then hide/downplay them.
 *
 * @return content of event obj for echarts.connect.
 */
export default function axisTrigger(payload: AxisTriggerPayload, ecModel: GlobalModel, api: ExtensionAPI): AxisTriggerPayload;
export {};