import { SpreadsheetPlugin, CellInfo, SpreadsheetColumn, CellPosition, SelectionRange, SpreadsheetMode } from '../types'; export interface UsePluginsOptions { plugins: SpreadsheetPlugin[]; data: T[]; columns: SpreadsheetColumn[]; mode: SpreadsheetMode; selectedCell: CellPosition | null; selectionRange: SelectionRange | null; updateCellValue: (rowIndex: number, columnKey: string, value: any) => void; setSelectedCell: (cell: CellPosition | null) => void; forceUpdate: () => void; } export interface UsePluginsResult { /** Call all plugin onCellClick handlers */ handlePluginCellClick: (cell: CellInfo, event: React.MouseEvent) => boolean; /** Call all plugin onCellDoubleClick handlers */ handlePluginCellDoubleClick: (cell: CellInfo, event: React.MouseEvent) => boolean; /** Call all plugin onCellChange handlers */ handlePluginCellChange: (cell: CellInfo, newValue: any, prevValue: any) => any; /** Call all plugin onRowClick handlers */ handlePluginRowClick: (row: T, index: number, event: React.MouseEvent) => boolean; /** Call all plugin onKeyDown handlers */ handlePluginKeyDown: (event: React.KeyboardEvent, cell: CellInfo | null) => boolean; /** Call all plugin onContextMenu handlers */ handlePluginContextMenu: (row: T, index: number, event: React.MouseEvent) => boolean; /** Get transformed data through plugins */ getTransformedData: (data: T[]) => T[]; /** Get transformed columns through plugins */ getTransformedColumns: (columns: SpreadsheetColumn[]) => SpreadsheetColumn[]; /** Render cell overlays from all plugins */ renderCellOverlays: (cell: CellInfo) => React.ReactNode[]; /** Render row overlays from all plugins */ renderRowOverlays: (row: T, index: number) => React.ReactNode[]; /** Render toolbar extensions from all plugins */ renderToolbarExtensions: () => React.ReactNode[]; /** Render footer extensions from all plugins */ renderFooterExtensions: () => React.ReactNode[]; /** Validate cell with all plugins */ validateCell: (cell: CellInfo, newValue: any) => { valid: boolean; message?: string; }; } export declare function usePlugins(options: UsePluginsOptions): UsePluginsResult; /** * Create a simple plugin from partial configuration */ export declare function createPlugin(config: Partial> & { name: string; }): SpreadsheetPlugin; /** * Compose multiple plugins into one */ export declare function composePlugins(...plugins: SpreadsheetPlugin[]): SpreadsheetPlugin; export { createPointagePlugin, POINTAGE_COLUMNS } from './pointagePlugin'; export type { PointagePluginConfig } from './pointagePlugin'; export { createTasksPlugin, TASK_COLUMNS } from './tasksPlugin'; export type { TasksPluginConfig } from './tasksPlugin'; export default usePlugins; //# sourceMappingURL=index.d.ts.map