Skip to content

Fix/custom color#19

Merged
firestar300 merged 3 commits into
developfrom
fix/custom-color
Jul 8, 2026
Merged

Fix/custom color#19
firestar300 merged 3 commits into
developfrom
fix/custom-color

Conversation

@firestar300

@firestar300 firestar300 commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

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.json is aligned.

Overview
Fixes custom and palette color discovery for the ACF theme color field by loading only the active theme’s theme.json via get_theme_file_path() instead of probing alternate paths like settings-color.json.

Adds extraction/normalization helpers so palette entries can come from settings.color.palette, settings.palette, or color.palette, and custom colors from settings.custom.color, custom.color, or settings.color.custom, including string values and { color: "..." } objects.

Tooling: drops Psalm from dev dependencies and the lint script, bumps wp-coding-standards/wpcs to ^3.3.0, and ignores composer.lock in git.

Reviewed by Cursor Bugbot for commit 99dd02b. Bugbot is set up for automated code reviews on this repo. Configure here.

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.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ 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.

Comment thread classes/Theme_Color_Field.php
@firestar300 firestar300 merged commit dca92c8 into develop Jul 8, 2026
2 checks passed
@firestar300 firestar300 deleted the fix/custom-color branch July 8, 2026 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant