Fix/custom color#19
Merged
Merged
Conversation
Refactors theme.json color extraction to support different definition structures for both palette and custom colors. This improves compatibility with diverse `theme.json` implementations across WordPress versions and themes.
Removes `vimeo/psalm` and `humanmade/psalm-plugin-wordpress` from `require-dev`, and their configurations from `grumphp.yml` and `psalm.xml.dist`. This streamlines the development tooling and static analysis setup. Also updates `wp-coding-standards/wpcs` to `^3.3.0`.
Removes `composer.lock` from version control and adds it to `.gitignore`. This allows individual development environments to generate and manage their own lock file, preventing merge conflicts and simplifying dependency management across different setups.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 99dd02b. Configure here.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Note
Medium Risk
Changes which theme.json paths and shapes supply ACF color options; themes that only exposed colors via the old fallback files may see different palettes until
theme.jsonis aligned.Overview
Fixes custom and palette color discovery for the ACF theme color field by loading only the active theme’s
theme.jsonviaget_theme_file_path()instead of probing alternate paths likesettings-color.json.Adds extraction/normalization helpers so palette entries can come from
settings.color.palette,settings.palette, orcolor.palette, and custom colors fromsettings.custom.color,custom.color, orsettings.color.custom, including string values and{ color: "..." }objects.Tooling: drops Psalm from dev dependencies and the
lintscript, bumpswp-coding-standards/wpcsto^3.3.0, and ignorescomposer.lockin git.Reviewed by Cursor Bugbot for commit 99dd02b. Bugbot is set up for automated code reviews on this repo. Configure here.