Skip to content

user-overrides for P block not winning specificity over theme.json block style #71313

@jhmonroe

Description

@jhmonroe

Description

As I understand it, specificity in block theme.json world is that it's core > global styles > block styles > user overrides (aka database) in the specificity war

See issue discovered while suggesting a UI enhancement : #71312

Now posting as an issue since I can't change the tag on the other ticket

Step-by-step reproduction instructions

  • define the block style for paragraphs as center in theme.json
  • override a paragraph to left-align on any page or post

also detailed in enhancement outline since the two things are co-related issues

Screenshots, screen recording, code snippet

Image Image

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

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

No one assigned

    Labels

    Global StylesAnything related to the broader Global Styles efforts, including Styles Engine and theme.json[Feature] Block APIAPI that allows to express the block paradigm.[Type] BugAn existing feature does not function as intended

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions