Skip to content

Media: Make the image editor help toggle icon color admin scheme-aware#12131

Open
t-hamano wants to merge 1 commit into
WordPress:trunkfrom
t-hamano:64937-info-icon-color
Open

Media: Make the image editor help toggle icon color admin scheme-aware#12131
t-hamano wants to merge 1 commit into
WordPress:trunkfrom
t-hamano:64937-info-icon-color

Conversation

@t-hamano

@t-hamano t-hamano commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

The help icon color in the image editor was hardcoded with classic colors. By replacing this with a CSS variable, it will default to modern colors. Furthermore, the color will appropriately change according to the user's color scheme.

Trac ticket: https://core.trac.wordpress.org/ticket/64937

Screenshots

Note that the button is intentionally focused to visually display the focus outline.

Header Header
Default image
Fresh image
Light image
Blue image
Coffee image
Ectoplasm image
Midnight image
Ocean image
Sunlinse image

Use of AI Tools

N/A

Replace the hardcoded #2271b1 color on the image editor help toggle (info) icon with the var(--wp-admin-theme-color) custom property, so the icon honors the user's selected admin color scheme instead of always rendering in the default blue.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@t-hamano t-hamano marked this pull request as ready for review June 9, 2026 00:37
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

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.

Core Committers: Use this line as a base for the props when committing in SVN:

Props wildworks.

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

@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

Test using WordPress Playground

The changes in this pull request can previewed and tested using a WordPress Playground instance.

WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser.

Some things to be aware of

  • All changes will be lost when closing a tab with a Playground instance.
  • All changes will be lost when refreshing the page.
  • A fresh instance is created each time the link below is clicked.
  • Every time this pull request is updated, a new ZIP file containing all changes is created. If changes are not reflected in the Playground instance,
    it's possible that the most recent build failed, or has not completed. Check the list of workflow runs to be sure.

For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation.

Test this pull request with WordPress Playground.

@mukeshpanchal27 mukeshpanchal27 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @t-hamano for the PR!

Look good to me.

Screenshot 2026-06-09 at 2 56 18 PM

@Dervish12 Dervish12 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.

Nice fix. Replacing the hardcoded #2271b1 with var(--wp-admin-theme-color) is the right call — this makes the help toggle icon consistent with every admin color scheme instead of being stuck on the classic blue.

The focus state change is also correct — border-color and box-shadow should match the theme color, not a static hex.

One thing I noticed: the box-shadow uses 1px width while most other focus styles in the admin use var(--wp-admin-border-width-focus, 1.5px). Might be worth aligning that too, but it is a pre-existing issue and outside the scope of this ticket.

Looks good to merge.

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.

3 participants