-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[List] Doesn't meet guidelines #6098
Comments
Only case i am seeing is when there are some custom components in list-item, such as buttons (https://material-ui-1dab0.firebaseapp.com/component-demos/lists#checkbox). Should ListItem force its size even though children are taller than 48/40 px? |
Also, list is missing secondary text line for three-line lists, which is supported in v0.x? |
This problem is hitting me now. I am trying to use a ListItem with a Checkbox, and the list must be I am new to |
I just ran into this. While I'm really excited about v1.0, it's kind of a shame this isn't scheduled to be fixed for the big release! I'm currently using the following wrapper component around Checkbox to resolve this:
I'm only using it inside a non-dense ListItem around a Checkbox currently, and it's pixel perfect for that usecase. Ymmv for other uses but I think it should work for any 48x48 component that has a centered 24x24 thing inside it surrounded by empty space. Using the negative margins is a bit of a hack but it seemed like the least invasive change I could make. |
I am working on a solution, also adding support for three-line items (#9205). I'll open a PR when I feel it is robust and elegant enough. |
I'm confused, do the specs say anything about a dense mode? Now at least, there's nothing in the OP link about dense mode and no image in the specs where the item is 40px tall. |
@jedwards1211 You're commenting on a closed issue from 2017. |
I guess I should have tagged the OP in the new issue that resulted from this? |
Problem description
According to Material guidelines ALL(with controls also) single line list items must be 48px height and 40px when in dense mode. Only exception is when avatar element is present it can be 56px height.
https://material.io/guidelines/components/lists.html#lists-specs
Link to minimally-working code that reproduces the issue
Versions
The text was updated successfully, but these errors were encountered: