-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Remove gutenberg_should_block_use_interactivity_api
and the old implementation of interactive blocks
#54297
Remove gutenberg_should_block_use_interactivity_api
and the old implementation of interactive blocks
#54297
Conversation
This pull request has changed or added PHP files. Please confirm whether these changes need to be synced to WordPress Core, and therefore featured in the next release of WordPress. If so, it is recommended to create a new Trac ticket and submit a pull request to the WordPress Core Github repository soon after this pull request is merged. If you're unsure, you can always ask for help in the #core-editor channel in WordPress Slack. Thank you! ❤️ View changed files❔ lib/experimental/blocks.php |
Size Change: -3.69 kB (0%) Total Size: 1.52 MB
ℹ️ View Unchanged
|
Flaky tests detected in 9a1eb73. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/6122352352
|
An additional disclaimer for anyone seeing this PR: the version of the Interactivity API that we plan to merge with 6.4 will be private to Core blocks and still subject to change (or even be reverted if necessary). More info here: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, Mario! I've tested it and everything seems to work great 🙂
BTW, I removed the directives example in the comment because it's a bit cumbersome to keep it up to date and I think that the Tag Processor code can be read easily enough.
@westonruter: now that we plan to proceed with this plan for the Interactivity API in WP 6.4, we are removing the |
I just merged this pull request because it is blocking the package sync settings. @westonruter if you have any concerns I'm happy to revert these changes or work on an alternative. Just let me know 🙂 |
I guess the only problem is that any minor releases between now and 6.4 won't be able to update the |
I thought those minor releases didn't use |
What?
Remove the
gutenberg_should_block_use_interactivity_api
function and the conditionals using it. Additionally, I took the opportunity to remove the old implementation of blocks using the Interactivity API.Why?
Now that we are planning on using the Interactivity API in both WordPress 6.4 and Gutenberg, we don't need to keep supporting the old versions.
How?
I just removed the function that was checking if it was in Gutenberg and I removed the conditionals to ensure they work the same way in WordPress and Gutenberg.
Additionally, I reverted the changes made here to only have the Interactivity API version.
Testing Instructions
view.js
file with the Interactivity API code, and check that the overlay menu and the submenu work as expected.view.js
file with the Interactivity API, and check it shows the preview when the setting is activated.