Material-table: rowStyle height does not work for anything under 49px in height

Created on 10 Jun 2019  路  5Comments  路  Source: mbrn/material-table

Describe the bug
rowStyle={ height: ''} does not work properly. If you set the height to anything under 49 pixels this fails to render properly.

To Reproduce
Steps to reproduce the behavior:

  1. Create a new material table or go to https://material-table.com/#/docs/features/styling
  2. Add options={{ rowStyle: { height: '10px'}} in your table or the example table in the official docs
  3. See that the table row height does not change.

Expected behavior
Previously this was working, if I set the row height to 10px it should apply that style.

Screenshots
materialTableRowHeight

Desktop (please complete the following information):

  • OS: MacOS Mojave 10.14.4
  • Browser: Chrome
  • Version: 74.0.3729.169 (Official Build) (64-bit)
  • Browser: Firefox
  • Version: 66.0.5

Additional context
There is nothing indicating that another style is overriding this rowStyle change, as shown in the screenshot provided.

enhancement wontfix

Most helpful comment

I found a solution for my use, I need to edit this property to change the size of the table header and table body:
.MuiTableCell-root {
height: 10px !important;
padding: 0px !important;
font-size: 0.7rem !important;
}

.MuiButtonBase-root{
height: 10px !important;
}

with this you can adjust for you

All 5 comments

It requires 49px at least. But i will take a look at it to decrease minimum size.

Hi @mbrn,

Thanks for taking up this enhancement. may I knw if there is any update about this issue? :)

@mbrn, do you have some update related to the row height less the 49px ?

I found a solution for my use, I need to edit this property to change the size of the table header and table body:
.MuiTableCell-root {
height: 10px !important;
padding: 0px !important;
font-size: 0.7rem !important;
}

.MuiButtonBase-root{
height: 10px !important;
}

with this you can adjust for you

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. You can reopen it if it required.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

KKrisu picture KKrisu  路  3Comments

VipinJoshi picture VipinJoshi  路  3Comments

behrouz-s picture behrouz-s  路  3Comments

Likurg2010 picture Likurg2010  路  3Comments

kfirshahar picture kfirshahar  路  3Comments