import { Cell, WorkbookInstance } from '../../sheet-engine/react'; import { OnboardingHandlerType, DataBlockApiKeyHandlerType } from '../types'; import { LiveQueryData } from '../../sheet-engine/core'; export type SmartContractResponse = { callSignature: unknown[]; }; export type SheetSmartContractApi = { sheetEditorRef: React.RefObject; formulaResponseUiSync: Function; row: number; column: number; newValue: Cell; }; export type SmartContractQueryHandler = (sheetApi: SheetSmartContractApi) => (callSignature: unknown[]) => Promise; /** * Parameters for the afterUpdateCell function */ interface AfterUpdateCellParams { row: number; column: number; oldValue?: Cell; newValue: Cell; sheetEditorRef: React.RefObject; onboardingComplete: boolean | undefined; setFetchingURLData: (fetching: boolean) => void; onboardingHandler: OnboardingHandlerType | undefined; dataBlockApiKeyHandler: DataBlockApiKeyHandlerType | undefined; handleSmartContractQuery?: SmartContractQueryHandler | undefined; handleLiveQueryData?: (subsheetIndex: number, queryData: LiveQueryData) => void; setInputFetchURLDataBlock: React.Dispatch> | undefined; storeApiKey?: (apiKeyName: string) => void; onDataBlockApiResponse?: (dataBlockName: string) => void; setDataBlockCalcFunction?: React.Dispatch>; dataBlockCalcFunction?: { [key: string]: { [key: string]: any; }; }; collabEnabled?: boolean; collabIsOwner?: boolean; remoteUpdateRef?: React.MutableRefObject; localUserEditRef?: React.MutableRefObject; } /** True when data-block formulas (API / smart contract) should run for this edit. */ export declare const shouldExecuteDataBlocks: (params: { collabEnabled?: boolean; collabIsOwner?: boolean; remoteUpdateRef?: React.MutableRefObject; localUserEditRef?: React.MutableRefObject; sheetEditorRef: React.RefObject; }) => boolean; export declare const isDatablockError: (value: any) => boolean; /** * Handles logic after a cell is updated, including processing formula results * * @param params - Object containing all required parameters * @returns Promise that resolves when processing is complete */ export declare const afterUpdateCell: (params: AfterUpdateCellParams) => Promise; export {};