import { LaboratoryContextProps } from '../components/laboratory/context'; import { LaboratoryTabCustom } from './tabs'; export interface LaboratoryPluginTab> { type: string; name: string | ((laboratory: LaboratoryContextProps, state: State) => string); icon?: React.ReactNode | ((laboratory: LaboratoryContextProps, state: State) => React.ReactNode); component: (tab: LaboratoryTabCustom, laboratory: LaboratoryContextProps, state: State, setState: (state: State) => void) => React.ReactNode; } export interface LaboratoryPlugin> { id: string; name: string; description?: string; icon?: React.ReactNode; defaultState?: State; onStateChange?: (state: State) => void; tabs?: LaboratoryPluginTab[]; commands?: { name: string | ((laboratory: LaboratoryContextProps, state: State) => string); icon?: React.ReactNode | ((laboratory: LaboratoryContextProps, state: State) => React.ReactNode); onClick: (laboratory: LaboratoryContextProps, state: State) => void; }[]; preflight?: { lab?: { definition?: string; props?: Record; object: (props: Record, state: State, setState: (state: State) => void) => Record; }; }; } export interface LaboratoryPluginsState { plugins: LaboratoryPlugin[]; pluginsState: Record; } export interface LaboratoryPluginsActions { setPluginsState: (state: Record) => void; } export declare const usePlugins: (props: { plugins?: LaboratoryPlugin[]; defaultPluginsState?: Record; onPluginsStateChange?: (state: Record) => void; }) => LaboratoryPluginsState & LaboratoryPluginsActions;