TablePagination

TablePagination

A TableCell based component for placing inside TableFooter for pagination.

Props

Name Type Default Description
ActionsComponent union: string |
 func |
 object
TablePaginationActions The component used for displaying the actions. Either a string to use a DOM element or a component.
backIconButtonProps object   Properties applied to the back arrow IconButton component.
classes object   Override or extend the styles applied to the component. See CSS API below for more details.
component union: string |
 func |
 object
TableCell The component used for the root node. Either a string to use a DOM element or a component.
count * number   The total number of rows.
labelDisplayedRows func ({ from, to, count }) => ${from}-${to} of ${count} Customize the displayed rows label.
labelRowsPerPage node 'Rows per page:' Customize the rows per page label. Invoked with a { from, to, count, page } object.
nextIconButtonProps object   Properties applied to the next arrow IconButton element.
onChangePage * func   Callback fired when the page is changed.

Signature:
function(event: object, page: number) => void
event: The event source of the callback
page: The page selected
onChangeRowsPerPage func   Callback fired when the number of rows per page is changed.

Signature:
function(event: object) => void
event: The event source of the callback
page * number   The zero-based index of the current page.
rowsPerPage * number   The number of rows per page.
rowsPerPageOptions array [5, 10, 25] Customizes the options of the rows per page select field. If less than two options are available, no select field will be displayed.
SelectProps object   Properties applied to the rows per page Select element.

Any other properties supplied will be spread to the root element (TableCell).

CSS API

You can override all the class names injected by Material-UI thanks to the classes property. This property accepts the following keys:

  • root
  • toolbar
  • spacer
  • menuItem
  • caption
  • input
  • selectRoot
  • select
  • selectIcon
  • actions

Have a look at overriding with classes section and the implementation of the component for more detail.

If using the overrides key of the theme as documented here, you need to use the following style sheet name: MuiTablePagination.

Inheritance

The properties of the TableCell component are also available. You can take advantage of this behavior to target nested components.

Demos