Skip to content

Allow styling blocks inside template parts with theme.json #43347

@carolinan

Description

@carolinan

What problem does this address?

As contributors are starting to submit style variations for Twenty Twenty-Three, it is becoming more apparent how limiting it is to not be able to style the site header and site footer using theme.json.

Because the template part has no block supports for colors, spacing etc, and all styles are on the inner blocks, these two areas can't be updated with style variations.

What is your proposed solution?

There should be a way to style blocks inside the default template part areas.
Just like we can use styles.blocks.blockname, we should be able to target blocks one "layer" down using
styles.templatePart.templatepart-name.blockname, or perhaps
styles.templatePart.area.footer.blockname.

Metadata

Metadata

Labels

[Feature] ThemesQuestions or issues with incorporating or styling blocks in a theme.[Status] In ProgressTracking issues with work in progress[Type] EnhancementA suggestion for improvement.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions