-
-
Notifications
You must be signed in to change notification settings - Fork 79.1k
Grid mess up when using responsive typography #17397
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
Comments
I thought so too but in fact em breakpoints are based on a bowser setting (which is default to 16px but can be changed by the user). So the breakpoints value doesn't change according to font size you put in your css. The |
So the reason for the grid not working properly is that max-width is set in rems and not pixels? |
Unless there's a typo or mistake somewhere, all our media queries are currently in ems, not rems. |
I believe we'll be moving back to pixels for media queries, so closing this out for now. |
For posterity: Moved back to pixels in #17403. |
I have played around with using responsive typography (see #17095).
When you add responsive font-size on the body element, the container (of properly other things) gets messed up because of the reliance on ems/rems.
Explained: The grid breakpoint in .container is relative to the font-size, so if you increase the font size on bigger screens, then you also increase the breakpoints.
Is this undesired behavior (bug) or should one manually correct the breakpoints to fit with the different font-sizes based on the same breakpoints 😖 ?
The text was updated successfully, but these errors were encountered: