Skip to content

Commit

Permalink
[TablePagination] Allow the MenuItem customization (#11200)
Browse files Browse the repository at this point in the history
  • Loading branch information
oliviertassinari authored May 1, 2018
1 parent 690bc0a commit 2ac22c9
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions packages/material-ui/src/Table/TablePagination.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export type TablePaginationClassKey =
| 'root'
| 'toolbar'
| 'spacer'
| 'menuItem'
| 'caption'
| 'input'
| 'selectRoot'
Expand Down
7 changes: 6 additions & 1 deletion packages/material-ui/src/Table/TablePagination.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export const styles = theme => ({
spacer: {
flex: '1 1 100%',
},
menuItem: {},
caption: {
flexShrink: 0,
},
Expand Down Expand Up @@ -115,7 +116,11 @@ class TablePagination extends React.Component {
{...SelectProps}
>
{rowsPerPageOptions.map(rowsPerPageOption => (
<MenuItem key={rowsPerPageOption} value={rowsPerPageOption}>
<MenuItem
className={classes.menuItem}
key={rowsPerPageOption}
value={rowsPerPageOption}
>
{rowsPerPageOption}
</MenuItem>
))}
Expand Down
1 change: 1 addition & 0 deletions pages/api/table-pagination.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ This property accepts the following keys:
- `root`
- `toolbar`
- `spacer`
- `menuItem`
- `caption`
- `input`
- `selectRoot`
Expand Down

0 comments on commit 2ac22c9

Please sign in to comment.