import type { WidgetSchema } from '../specs'; import BaseStore from './base-store'; export type WidgetsState = { widgets: Map; }; export type WidgetsStoreInterface = InstanceType; /** * 组件状态管理 */ declare class WidgetsStore extends BaseStore { state: WidgetsState; constructor(); initState(initialState: { widgets: WidgetSchema[]; }): void; setWidgetProperties>(id: string, properties: Partial): void; getWidgetById(id: string): WidgetSchema | undefined; getWidgetProperties>(id: string): O; getWidgets(): Map; getWidgetList(): WidgetSchema[]; } export default WidgetsStore;