-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Block Types: Add metadata
global attribute
#5608
Conversation
metadata
global attribute
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.
Thanks for updating the tests. The change required for this update is pretty straightforward.
Co-authored-by: Greg Ziółkowski <grzegorz@gziolo.pl>
Thanks all! I also made sure to test this change with Gutenberg installed and activated, to make sure this change wouldn't commit with code from WordPress/gutenberg#54426 ✅ (Fortunately, the latter has a number of Committed to Core in https://core.trac.wordpress.org/changeset/57068. |
I was very pleased to return to work and find this completed. Thank you so much 🙇 |
For use cases such as allowing the user to assign custom names to blocks or for making Block Hooks work with user-modified templates/parts/patterns (
#59646
), there's a requirement for a new global attribute (i.e. an attribute that can be added to all and any blocks) to hold that sort ofmetadata
.See #2615 for precedent for registering a global attribute.
Spun off from #5523.
Fixes WordPress/gutenberg#55194.
Trac ticket: https://core.trac.wordpress.org/ticket/59797
This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.