UNPKG

@mui/x-data-grid

Version:

The Community plan edition of the MUI X Data Grid components.

25 lines 908 B
import type { RefObject } from '@mui/x-internals/types'; import type { GridControlledStateReasonLookup } from "../events/gridEventLookup.mjs"; import type { GridApiCommon } from "./gridApiCommon.mjs"; /** * Additional details passed to the callbacks */ export interface GridCallbackDetails<K extends keyof GridControlledStateReasonLookup = any, Api extends GridApiCommon = GridApiCommon> { /** * The reason for this callback to have been called. */ reason?: GridControlledStateReasonLookup[K]; /** * GridApi that let you manipulate the grid. */ api: GridApiCommon; /** * A ref to the GridApi that let you manipulate the grid. * Can be used to call selectors without a separate `useGridApiRef`. * @example * onRowSelectionModelChange={(model, details) => { * const rows = gridRowSelectionIdsSelector(details.apiRef); * }} */ apiRef: Readonly<RefObject<Api>>; }