-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Closed
Labels
Global StylesAnything related to the broader Global Styles efforts, including Styles Engine and theme.jsonAnything related to the broader Global Styles efforts, including Styles Engine and theme.json[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
Group block padding (with background color) can't be configured through theme.json.
Step-by-step reproduction instructions
- Create
theme.json:
{
"version": 1,
"styles": {
"blocks": {
"core/group": {
"spacing": {
"padding": "1rem"
}
}
}
}
}
- Insert Group block and assign any background colour
- Check block padding – should be
1remfollowingtheme.jsonbut is actually1.25em 2.375em. The1remrule is output in the stylesheet (for.wp-block-group) but is overridden.
Expected behaviour
Padding should be 1rem – and it should only apply to group blocks with a background. Maybe this requires a different syntax in theme.json but this seems to be undocumented.
Actual behaviour
Group block padding is set indiscriminately 1.25em 2.375em, overriding any theme.json setting, and not specific to group blocks with background colour set.
WordPress information
- WordPress version: 5.8 RC3
- Gutenberg version: 11.0.0
- Are all plugins except Gutenberg deactivated? Yes
- Are you using a default theme (e.g. Twenty Twenty-One)? Yes, have tried with Twenty-Twenty One but it adds loads of its own CSS which obscures the problem. It's better exposed by a more minimal theme.
Device information
- Device: MacBook Pro
- Operating system: Mac OS 11.4
- Browser: Chrome 92
Metadata
Metadata
Assignees
Labels
Global StylesAnything related to the broader Global Styles efforts, including Styles Engine and theme.jsonAnything related to the broader Global Styles efforts, including Styles Engine and theme.json[Status] In ProgressTracking issues with work in progressTracking issues with work in progress[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended