-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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.8 #63001
Comments
@scruffian I am unsure of if writingMode should be stabilized without the text orientation changes? (#60030) |
I agree |
Oh, thanks for flagging! I'm working on a draft PR over in #63401 — I'll omit |
This is a fantastic initiative @andrewserong . While we are at it, can we also tackle |
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 🙂 |
Update: the initial PR for stabilizing the Typography supports for WP 6.8 has landed in #63401. That PR updated the JS and PHP implementations so that both the experimental and non-experimental prefixes are handled for the Typography support. Hopefully what's landed can be used as a basis for the parallel work in stabilizing other supports such as border (#64312). I'll be heading off on sabbatical in under two weeks so I likely won't have time to contribute much more to this work. From my perspective, some next steps include (this is partly copy+pasted from the issue description):
FYI: @ndiego, @aaronrobertshaw, @ramonjd |
Nice work progressing this stabilization effort @andrewserong 👍 I have a couple of small questions regarding the proposed task list.
What's the plan for noting that version requirement, just in the property's description? It doesn't look like we added that information when past supports etc were added or stabilized. Do you think it's needed? Or is it conveyed via the schema as it is in the version of Gutenberg or Core in question?
My understanding was that the schema didn't document experimental properties. Quickly glancing at the schema I don't see any reference to experimental block support properties. |
Good catches @aaronrobertshaw! I was copy+pasting from my previous notes, but hadn't gone back to check on the current state of the I'll update the task lists here to be:
And remove the Thanks for double-checking! |
My read of #63591 is that it didn't change anything with regards to the block.json schema and removing WordPress versions. I might still be missing something 🤷
Is it possible you were thinking of the |
No, I don't think it really changed anything in that respect, but it changed my perspective on it 🙂. It removed a reference to
So for consistency it looks like flagging the version in which something is introduced is best done in that doc rather than in schemas. 🤔 But do feel free to make any changes to the approach here! In the end it might not be necessary to flag which version a block support was introduced in, as it might be clear enough from Dev Notes. My main (weakly held) thought was that it could be useful for folks building custom block plugins to be able to see easily enough when a block support was introduced so that they know which |
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:
__experimentalFontFamily
→fontFamily
__experimentalTextDecoration
→textDecoration
__experimentalFontStyle
→fontStyle
__experimentalFontWeight
→fontWeight
__experimentalLetterSpacing
→letterSpacing
__experimentalTextTransform
→textTransform
__experimentalWritingMode
→writingMode
Tasks
lib/block-supports/typography.php
to use the non__experimental
prefix, falling back to the__experimental
prefix if available.__experimental
prefix, falling back to the__experimental
prefix if available.block.json
schema to support the non__experimental
prefixblock.json
files to use the non__experimental
prefixesIn 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.The text was updated successfully, but these errors were encountered: