@realsee/five
Version:
Realsee Renderer SDK
45 lines (44 loc) • 1.26 kB
TypeScript
import type { BasePlugin } from '@realsee/five/plugins';
export declare enum WarningCodeType {
Warning_1 = "CAN_NOT_DRAW_ZONE"
}
export type Mode = 'Idle' | 'View' | 'Marking' | 'Waiting';
export type Mirror<T extends string> = Record<T, T>;
export type State = {
enabled: boolean;
};
export interface PluginDataItem {
}
export type PluginData = PluginDataItem;
export interface Config {
}
export interface Params {
config?: Partial<Config>;
initialState?: Partial<State>;
}
export interface EventMap extends BasePlugin.EventMap<State, PluginData> {
/**
* @param event - event.userAction是否是用户操作
* @description enabled 从 false 到 true 的回调
*/
enable: (event: {
userAction: boolean;
}) => void;
/**
* @param event - event.userAction是否是用户操作
* @description enabled 从 true 到 false 的回调
*/
disable: (event: {
userAction: boolean;
}) => void;
/**
* @description 插件 dispose
* */
dispose: () => void;
click: (index: number) => void;
/**
* @description 历史堆栈更新
* @param historyStackLength - 历史堆栈当前数量
* */
historyLengthChange: (historyStackLength: number) => void;
}