Opened 4 months ago
Last modified 7 weeks ago
#61728 new defect (bug)
Stabilize experimental Typography block support keys
Reported by: | andrewserong | Owned by: | |
---|---|---|---|
Milestone: | Future Release | Priority: | normal |
Severity: | normal | Version: | trunk |
Component: | Editor | Keywords: | has-patch |
Focuses: | Cc: |
Description (last modified by )
For WordPress 6.8, stabilize the experimental Typography block support keys. The current experimental features and mapping to stable keys are:
__experimentalFontFamily
→fontFamily
__experimentalTextDecoration
→textDecoration
__experimentalFontStyle
→fontStyle
__experimentalFontWeight
→fontWeight
__experimentalLetterSpacing
→letterSpacing
__experimentalTextTransform
→textTransform
__experimentalWritingMode
→writingMode
This work is being tracked in the Gutenberg repo in: https://github.com/WordPress/gutenberg/issues/63001
It will require syncing code from Gutenberg, but also a slightly different implementation in core so that we don't need to use filters to apply the transformation from experimental to stable properties.
The overall goal is to stabilize the experimental typography features in block supports, as they have been in use for multiple releases and are ready for wider documentation, and are unlikely to change.
Change History (3)
This ticket was mentioned in PR #7069 on WordPress/wordpress-develop by @andrewserong.
4 months ago
#1
- Keywords has-patch added
@andrewserong commented on PR #7069:
4 months ago
#2
Based on discussion over in https://github.com/WordPress/gutenberg/pull/63401#issuecomment-2249588880, I've updated this to move the stabilization to _after_ the filter is run. This ensures that any opt-outs, etc, performed by plugins are appropriately stabilized before the props are set.
I've also moved the logic into a private method so that set_props
is easier to read.
Trac ticket: https://core.trac.wordpress.org/ticket/61728
🚧 🚧 🚧 WIP: This is currently a work in progress and is not yet ready for review 🚧 🚧 🚧
This PR syncs some of the changes from https://github.com/WordPress/gutenberg/pull/63401, however uses a slightly different approach for applying the transformations so that we do not depend on filters.
More details TBC as this PR is still a work in progress.