Global styles don't support multi-value shorthand padding #40132
Labels
[Feature] Themes
Questions or issues with incorporating or styling blocks in a theme.
Global Styles
Anything related to the broader Global Styles efforts, including Styles Engine and theme.json
[Type] Bug
An existing feature does not function as intended
Description
If a theme sets root padding in
theme.json
as a multi-value shorthand declaration, like so:it gets added to the
body
as expected:padding: 68px 32px;
.But if a user then sets root padding in global styles, and if they don't provide a value for all sides (say they only want to change the left/right padding, and keep the theme's top/bottom value), the shorthand is interpreted as a single value and results in incorrect CSS:
Step-by-step reproduction instructions
theme.json
with:.editor-styles-wrapper
in the editor, andbody
in the front end.Screenshots, screen recording, code snippet
No response
Environment info
No response
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
The text was updated successfully, but these errors were encountered: