UNPKG

644 BTypeScriptView Raw
1import { View } from '../chart';
2import { LooseObject } from '../interface';
3export declare type InteractionConstructor = new (view: View, cfg: LooseObject) => Interaction;
4/**
5 * 交互的基类。
6 */
7export default class Interaction {
8 /** view 或者 chart */
9 protected view: View;
10 /** 配置项 */
11 protected cfg: LooseObject;
12 constructor(view: View, cfg: LooseObject);
13 /**
14 * 初始化。
15 */
16 init(): void;
17 /**
18 * 绑定事件
19 */
20 protected initEvents(): void;
21 /**
22 * 销毁事件
23 */
24 protected clearEvents(): void;
25 /**
26 * 销毁。
27 */
28 destroy(): void;
29}