Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix https://github.com/KevinVandy/material-react-table/issues/1149 #1150

Merged
merged 1 commit into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,8 @@ export const MRT_TableBodyCell = <TData extends MRT_RowData>({
const cellValueProps = {
cell,
table,
staticColumnIndex,
staticRowIndex,
};

const handleDoubleClick = (event: MouseEvent<HTMLTableCellElement>) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ export const MRT_TableBodyCellValue = <TData extends MRT_RowData>({
column,
row,
table,
staticColumnIndex,
staticRowIndex,
})
: row.getIsGrouped() && !cell.getIsGrouped()
? null
Expand All @@ -52,6 +54,8 @@ export const MRT_TableBodyCellValue = <TData extends MRT_RowData>({
column,
row,
table,
staticColumnIndex,
staticRowIndex,
})
: undefined;

Expand Down
4 changes: 4 additions & 0 deletions packages/material-react-table/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,8 @@ export type MRT_ColumnDef<TData extends MRT_RowData, TValue = unknown> = Omit<
column: MRT_Column<TData, TValue>;
row: MRT_Row<TData>;
table: MRT_TableInstance<TData>;
staticColumnIndex?: number;
staticRowIndex?: number;
}) => ReactNode;
Cell?: (props: {
cell: MRT_Cell<TData, TValue>;
Expand Down Expand Up @@ -459,6 +461,8 @@ export type MRT_ColumnDef<TData extends MRT_RowData, TValue = unknown> = Omit<
column: MRT_Column<TData, TValue>;
row: MRT_Row<TData>;
table: MRT_TableInstance<TData>;
staticColumnIndex?: number;
staticRowIndex?: number;
}) => ReactNode;
Header?:
| ((props: {
Expand Down
Loading