View as Markdown

API reference: @salmonui/data-grid

DataGridRowContextinterface

import type { DataGridRowContext } from '@salmonui/data-grid';
interface DataGridRowContext<Row> {
    row: Row;
    rowId: RowId;
    rowIndex: number;
    defaultRow: ReactElement;
    rowProps: DataGridRowElementProps;
    cells: ReactNode;
}
DataGridRowContext members (6)
NameSignatureDescription
rowrow: Row;
rowIdrowId: RowId;
rowIndexrowIndex: number;
defaultRowdefaultRow: ReactElement;

The default row element; return it, wrap its cells, or render rowProps + cells yourself.

rowPropsrowProps: DataGridRowElementProps;
cellscells: ReactNode;

The row's cells (pinned zones included), to place inside a custom row element.