Skip to content

Commit 2b5d3de

Browse files
committed
make pagination component props consistent
1 parent 30a2309 commit 2b5d3de

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

packages/material-react-table/src/toolbar/MRT_TablePagination.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import InputLabel from '@mui/material/InputLabel';
44
import MenuItem from '@mui/material/MenuItem';
55
import Pagination, { type PaginationProps } from '@mui/material/Pagination';
66
import PaginationItem from '@mui/material/PaginationItem';
7-
import Select from '@mui/material/Select';
7+
import Select, { type SelectProps } from '@mui/material/Select';
88
import Tooltip from '@mui/material/Tooltip';
99
import Typography from '@mui/material/Typography';
1010
import { parseFromValuesOrFunc } from '../column.utils';
@@ -15,6 +15,7 @@ const defaultRowsPerPage = [5, 10, 15, 20, 25, 30, 50, 100];
1515
interface Props<TData extends MRT_RowData>
1616
extends Partial<
1717
PaginationProps & {
18+
SelectProps?: Partial<SelectProps>;
1819
disabled?: boolean;
1920
rowsPerPageOptions?: { label: string; value: number }[] | number[];
2021
showRowsPerPage?: boolean;

packages/material-react-table/src/types.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -962,13 +962,15 @@ export type MRT_TableOptions<TData extends MRT_RowData> = Omit<
962962
| ((props: { table: MRT_TableInstance<TData> }) => Partial<
963963
PaginationProps & {
964964
SelectProps?: Partial<SelectProps>;
965+
disabled?: boolean;
965966
rowsPerPageOptions?: { label: string; value: number }[] | number[];
966967
showRowsPerPage?: boolean;
967968
}
968969
>)
969970
| Partial<
970971
PaginationProps & {
971972
SelectProps?: Partial<SelectProps>;
973+
disabled?: boolean;
972974
rowsPerPageOptions?: { label: string; value: number }[] | number[];
973975
showRowsPerPage?: boolean;
974976
}

0 commit comments

Comments
 (0)