Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stabilize Typography Block Supports Keys for WP 6.7 #63001

Open
6 tasks
andrewserong opened this issue Jul 1, 2024 · 5 comments
Open
6 tasks

Stabilize Typography Block Supports Keys for WP 6.7 #63001

andrewserong opened this issue Jul 1, 2024 · 5 comments
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Package] Block library /packages/block-library [Type] Iteration Scoped iteration of an effort from a tracking issue or overview issue ideally for a major release.

Comments

@andrewserong
Copy link
Contributor

andrewserong commented Jul 1, 2024

Part of:

This issues tracks progress towards stabilizing the typography block support. Note that in order to provide backwards compatibility for block plugins out in the wild, fallback support for the existing __experimental prefixes should be provided.

Stabilize the following typography block supports:

  • __experimentalFontFamilyfontFamily
  • __experimentalTextDecorationtextDecoration
  • __experimentalFontStylefontStyle
  • __experimentalFontWeightfontWeight
  • __experimentalLetterSpacingletterSpacing
  • __experimentalTextTransformtextTransform
  • __experimentalWritingModewritingMode

Tasks

  • Update PHP block support code in lib/block-supports/typography.php to use the non __experimental prefix, falling back to the __experimental prefix if available.
  • Update the JS implementations of the typography block supports to point to the non __experimental prefix, falling back to the __experimental prefix if available.
  • Update the block.json schema to support the non __experimental prefix, with a note that it is only as of WP 6.7+
  • Update the core blocks' block.json files to use the non __experimental prefixes
  • For WP 6.7, update the supports documentation to include the new non prefixed versions.
  • Once WP 6.7 is released, update the block.json schema to remove the __experimental prefix. Note that the code in WordPress should still support the __experimental prefix, but at this stage, the experimental prefix will be treated as deprecated.

In my opinion, in order to provide the widest possible support for block plugins, I think it could be valuable to provide fallback support for the __experimental in the long-term. In other words, when implementing the fallback ideas above, let's do so in a way that's easy to maintain.

@andrewserong andrewserong added [Package] Block library /packages/block-library [Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Type] Iteration Scoped iteration of an effort from a tracking issue or overview issue ideally for a major release. labels Jul 1, 2024
@carolinan
Copy link
Contributor

@scruffian I am unsure of if writingMode should be stabilized without the text orientation changes? (#60030)

@scruffian
Copy link
Contributor

@scruffian I am unsure of if writingMode should be stabilized without the text orientation changes? (#60030)

I agree

@andrewserong
Copy link
Contributor Author

Oh, thanks for flagging! I'm working on a draft PR over in #63401 — I'll omit writingMode from the stabilisation for now 👍

@ndiego
Copy link
Member

ndiego commented Jul 31, 2024

This is a fantastic initiative @andrewserong . While we are at it, can we also tackle __experimentalBorder and __experimentalDefaultControls? I am happy to open an issue for these, but didn't want to jump the gun if you were already planning on doing so. Just let me know either way.

@andrewserong
Copy link
Contributor Author

I am happy to open an issue for these, but didn't want to jump the gun if you were already planning on doing so. Just let me know either way.

Thanks @ndiego, if you wouldn't mind opening an issue for those, that'd be great! My main focus right now is on the Typography support and this initial stage, so that we can contain the scope of the changes we're rolling out. But my hope is that with #63401 it should make subsequent stabilization a bit easier 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Package] Block library /packages/block-library [Type] Iteration Scoped iteration of an effort from a tracking issue or overview issue ideally for a major release.
4 participants