Skip to content

Commit

Permalink
fix #1149 (#1150)
Browse files Browse the repository at this point in the history
  • Loading branch information
tmax22 authored Jun 7, 2024
1 parent 92c40b0 commit dac97f8
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
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

0 comments on commit dac97f8

Please sign in to comment.