Update the padding values on the Card component to align with proposed spacing system#21111
Update the padding values on the Card component to align with proposed spacing system#21111ItsJonQ merged 6 commits intoWordPress:masterfrom
Conversation
"Size" is somewhat ambiguous. "Padding" is more explicit.
|
Thanks for the PR 👍 Unfortunately, renaming |
This reverts commit 25a0ae8.
|
This seems good to me! I assume we can't really use the grid-unit variables here? In that case, ship it! |
I don't believe those have been implemented yet? Also, the padding styles are defined in a .js file, I'm not sure if that would have access to those variables? |
|
Well they're in master: https://github.com/WordPress/gutenberg/blob/master/packages/base-styles/_variables.scss#L22 |
|
Ah, I was looking for the vanilla css vars suggested in the post on make 🤦♂
Do you know if those vars are accessible in |
|
No, I don't think they are, and that's fine. But the values you chose are compatible :) that's a great start. |
ItsJonQ
left a comment
There was a problem hiding this comment.
🚀 from me! This reminds me! In the future, it would be handy to have a js based mixin (maybe something like spacing(3)) to retrieve these values
|
Will merge this when Travis is green and happy |
|
Congratulations on your first merged pull request, @jameskoster! We'd like to credit you for your contribution in the post announcing the next WordPress release, but we can't find a WordPress.org profile associated with your GitHub account. When you have a moment, visit the following URL and click "link your GitHub account" under "GitHub Username" to link your accounts: https://profiles.wordpress.org/me/profile/edit/ And if you don't have a WordPress.org account, you can create one on this page: https://login.wordpress.org/register Kudos! |
Description
This PR updates the padding values on the Card components (header, body, footer) to be multiples of 8, and align more neatly with the "consistent spacing system" proposed here. While multiples of 4 are totally acceptable, being a little stricter and using 8 as a preference creates a greater sense of consistency and robustness.
I also renamed the
sizeprop topaddingwhich is more explicit.Sizefelt a bit too ambiguous.How has this been tested?
Testing required :)
Screenshots
The top row are the current values, the bottom row are the proposed values.
Types of changes
CSS changes and some find / replace.
Checklist: