Skip to content

In 12.1, blockGap appears partially enabled when it shouldn't be #37232

@ndiego

Description

@ndiego

Description

In 12.1, something changed (still trying to locate) that enables blockGap related CSS even if blockGap is not enabled in theme.json. I can also confirm that this issue exists in 5.9 Beta 2 without the Gutenberg plugin active.

In Gutenberg 12.0.2, I have a Group block with a Paragraph and Buttons block inside. It looks something like this:
image

Now in 12.1, the same collection of blocks looks like this.
image

Notice all the additional CSS applied to the paragraph block. In theme.json, blockGap is not enabled on this theme.

Step-by-step reproduction instructions

  1. Install Twenty Twenty-Two and disable blockGap in theme.json
  2. Install Gutenberg 12.0.2
  3. Create a Group block and place a few paragraph blocks inside.
  4. View the markup on the frontend.
  5. Upgrade Gutenberg to 12.1
  6. Review the markup again and see all the additional blockGap related CSS added to the frontend.

Screenshots, screen recording, code snippet

No response

Environment info

WordPress 5.9 Beta 2, Gutenberg 12.1

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

Metadata

Metadata

Assignees

Labels

CSS StylingRelated to editor and front end styles, CSS-specific issues.[Status] In ProgressTracking issues with work in progress[Type] BugAn existing feature does not function as intended[Type] RegressionRelated to a regression in the latest release

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions