-
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
Use prefix theme_json_
in hooks related to theme.json
#44189
Conversation
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.
LGTM
@c4rl0sbr4v0 @ockham @michalczaplinski I'm waiting for this one to pass before merging. I'm not sure about the timing for 14.1 but I can backport it when merged. |
Cherry-picked to |
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well. This commit backports the original PR from Gutenberg repository: * [WordPress/gutenberg#44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json] Reference: [#3247 #3247 Add hooks to filter theme.json data]. Follow-up to [54118]. Props oandregal, scruffian, bernhard-reiter. See #56467. git-svn-id: https://develop.svn.wordpress.org/trunk@54183 602fd350-edb4-49c9-b593-d223f7449a82
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well. This commit backports the original PR from Gutenberg repository: * [WordPress/gutenberg#44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json] Reference: [WordPress/wordpress-develop#3247 #3247 Add hooks to filter theme.json data]. Follow-up to [54118]. Props oandregal, scruffian, bernhard-reiter. See #56467. Built from https://develop.svn.wordpress.org/trunk@54183 git-svn-id: http://core.svn.wordpress.org/trunk@53742 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well. This commit backports the original PR from Gutenberg repository: * [WordPress/gutenberg#44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json] Reference: [WordPress/wordpress-develop#3247 #3247 Add hooks to filter theme.json data]. Follow-up to [54118]. Props oandregal, scruffian, bernhard-reiter. See #56467. Built from https://develop.svn.wordpress.org/trunk@54183 git-svn-id: https://core.svn.wordpress.org/trunk@53742 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well. This commit backports the original PR from Gutenberg repository: * [WordPress/gutenberg#44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json] Reference: [WordPress/wordpress-develop#3247 #3247 Add hooks to filter theme.json data]. Follow-up to [54118]. Props oandregal, scruffian, bernhard-reiter. See #56467. Built from https://develop.svn.wordpress.org/trunk@54183
I just cherry-picked this PR to the wp/6.1 branch to get it included in the next release: ac50ea8 |
This consolidates the name of a filter introduced earlier in the 6.1 cycle, renaming it from `get_style_nodes` to `theme_json_get_style_nodes` as to be more coherent with the other hooks introduced in 6.1 as well. This commit backports the original PR from Gutenberg repository: * [WordPress/gutenberg#44189 #44189 Use prefix 'theme_json_' in hooks related to theme.json] Reference: [WordPress#3247 WordPress#3247 Add hooks to filter theme.json data]. Follow-up to [54118]. Props oandregal, scruffian, bernhard-reiter. See #56467. git-svn-id: https://develop.svn.wordpress.org/trunk@54183 602fd350-edb4-49c9-b593-d223f7449a82
What?
Renames the filter
get_style_nodes
totheme_json_get_style_nodes
.Why?
We've introduced a number of filters for
theme.json
in this cycle:theme_json_default
,theme_json_blocks
,theme_json_theme
,theme_json_user
. 44015 and 44159get_style_nodes
41160With so many hooks in core, it helps discoverability and devexp that we use a coherent names for things that are related.
How?
Renames the calls to the filter.
Testing Instructions
See #41160