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

Theme JSON: Update core theme json resolver class use to Gutenberg version #63981

Merged

Conversation

aaronrobertshaw
Copy link
Contributor

What?

Updates some calls to the core WP_Theme_JSON_Resolver class with its core equivalent: WP_Theme_JSON_Resolver_Gutenberg

Why?

  • Makes sure that the code in Gutenberg is using the Gutenberg resolver class
  • Consistency

How?

Append _Gutenberg to the core class name.

Testing Instructions

  1. Turn on the new post dataviews page experiment
  2. Navigate to Gutenberg > Posts
  3. Ensure that Global Styles are correctly displayed in the post preview
  4. Double check all e2es are passing

@aaronrobertshaw aaronrobertshaw added [Type] Code Quality Issues or PRs that relate to code quality No Core Sync Required Indicates that any changes do not need to be synced to WordPress Core labels Jul 26, 2024
@aaronrobertshaw aaronrobertshaw self-assigned this Jul 26, 2024
Copy link

github-actions bot commented Jul 26, 2024

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: aaronrobertshaw <aaronrobertshaw@git.wordpress.org>
Co-authored-by: mukeshpanchal27 <mukesh27@git.wordpress.org>
Co-authored-by: mikachan <mikachan@git.wordpress.org>
Co-authored-by: andrewserong <andrewserong@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Co-authored-by: Mukesh Panchal <mukeshpanchal27@users.noreply.github.com>
Copy link
Member

@mikachan mikachan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code changes look good to me and everything is testing well. I tested with the dataviews experiment turned on, and Global Styles were correctly displayed in the previews ✅

I also ran the e2e tests locally, and they were all passing and I can see they're passing on this PR (including the font-library.spec.js test!) ✅

Copy link
Contributor

@andrewserong andrewserong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing nicely for me, too!

@andrewserong andrewserong merged commit a528233 into trunk Aug 2, 2024
63 checks passed
@andrewserong andrewserong deleted the fix/inconsistent-uses-of-theme-json-resolver-class branch August 2, 2024 05:33
@github-actions github-actions bot added this to the Gutenberg 19.0 milestone Aug 2, 2024
@aaronrobertshaw
Copy link
Contributor Author

Thanks for the reviews and getting this one merged while I was away. Appreciate it 🙇

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
No Core Sync Required Indicates that any changes do not need to be synced to WordPress Core [Type] Code Quality Issues or PRs that relate to code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants