-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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[Feature] Block APIAPI that allows to express the block paradigm.API that allows to express the block paradigm.[Type] Code QualityIssues or PRs that relate to code qualityIssues or PRs that relate to code quality
Description
Part of #45171
What
The __experimentalSelector and __experimentalDuotone for block.json should become stable APIs.
Why
__experimentalSelectorhas been introduced in WordPress 5.8 and evolved since. It covers certain use cases for which there is no other alternative (some blocks don't use thewp-block-<block-name>class for various reasons.__experimentalDuotonehas been introduced in WordPress 5.8 and evolved since. It covers the use case of providing selectors for a specific style property (duotone) and there has been no alternatives considered.
Related docs: architecture of styles.
How
Things to consider:
- The ability to have a general selector for the whole block VS having a selector per style property. Is this fully working as expected?
- They both cover a similar use case, providing a selector for a given style property. Can both coalesce into a single "block selector API"?
- We should evaluate creating a migration from the old mechanisms (
__experimentalSelector,__experimentalDuotone) to the new one, or communicate that we'll support both old (experimental) and new (stable) for a given period of time.
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[Feature] Block APIAPI that allows to express the block paradigm.API that allows to express the block paradigm.[Type] Code QualityIssues or PRs that relate to code qualityIssues or PRs that relate to code quality