@awsui/components-react
Version:
On July 19th, 2022, we launched [Cloudscape Design System](https://cloudscape.design). Cloudscape is an evolution of AWS-UI. It consists of user interface guidelines, front-end components, design resources, and development tools for building intuitive, en
29 lines • 778 B
TypeScript
import { CancelableEventHandler } from '../internal/events';
import { TableProps } from './interfaces';
interface CellId {
row: string;
col: string;
}
interface CellEditingProps {
onCancel?: CancelableEventHandler;
onSubmit?: TableProps.SubmitEditFunction<any>;
}
export declare function useCellEditing({
onCancel,
onSubmit
}: CellEditingProps): {
isLoading: boolean;
startEdit: (cellId: CellId) => void;
cancelEdit: () => void;
checkEditing: ({
row,
col
}: CellId) => boolean;
checkLastSuccessfulEdit: ({
row,
col
}: CellId) => boolean;
completeEdit: (cellId: CellId, editCancelled: boolean) => void;
submitEdit: ((item: any, column: TableProps.ColumnDefinition<any>, newValue: unknown) => Promise<void>) | undefined;
};
export {};