diff --git a/docs/pages/material-ui/api/pagination.json b/docs/pages/material-ui/api/pagination.json index a59b2a71efc024..b07c43f7fada33 100644 --- a/docs/pages/material-ui/api/pagination.json +++ b/docs/pages/material-ui/api/pagination.json @@ -15,7 +15,7 @@ "getItemAriaLabel": { "type": { "name": "func" }, "signature": { - "type": "function(type: string, page: number, selected: bool) => string", + "type": "function(type: string, page: number | null, selected: boolean) => string", "describedArgs": ["type", "page", "selected"] } }, diff --git a/packages/mui-material/src/Pagination/Pagination.d.ts b/packages/mui-material/src/Pagination/Pagination.d.ts index 50d83916d37f9c..752661d0c34015 100644 --- a/packages/mui-material/src/Pagination/Pagination.d.ts +++ b/packages/mui-material/src/Pagination/Pagination.d.ts @@ -42,14 +42,14 @@ export interface PaginationProps * * For localization purposes, you can use the provided [translations](/material-ui/guides/localization/). * @param {string} type The link or button type to format ('page' | 'first' | 'last' | 'next' | 'previous' | 'start-ellipsis' | 'end-ellipsis'). Defaults to 'page'. - * @param {number} page The page number to format. - * @param {bool} selected If true, the current page is selected. + * @param {number | null} page The page number to format. + * @param {boolean} selected If true, the current page is selected. * @returns {string} */ getItemAriaLabel?: ( type: UsePaginationItem['type'], page: UsePaginationItem['page'], - selected: boolean, + selected: UsePaginationItem['selected'], ) => string; /** diff --git a/packages/mui-material/src/Pagination/Pagination.js b/packages/mui-material/src/Pagination/Pagination.js index 56e2610ee2b4e9..97fd340dad5f1a 100644 --- a/packages/mui-material/src/Pagination/Pagination.js +++ b/packages/mui-material/src/Pagination/Pagination.js @@ -176,8 +176,8 @@ Pagination.propTypes /* remove-proptypes */ = { * * For localization purposes, you can use the provided [translations](/material-ui/guides/localization/). * @param {string} type The link or button type to format ('page' | 'first' | 'last' | 'next' | 'previous' | 'start-ellipsis' | 'end-ellipsis'). Defaults to 'page'. - * @param {number} page The page number to format. - * @param {bool} selected If true, the current page is selected. + * @param {number | null} page The page number to format. + * @param {boolean} selected If true, the current page is selected. * @returns {string} */ getItemAriaLabel: PropTypes.func,