Skip to content

Administration: Update site icon and media control button styling #8724

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

Open
wants to merge 3 commits into
base: trunk
Choose a base branch
from

Conversation

Infinite-Null
Copy link

@Infinite-Null Infinite-Null commented Apr 23, 2025

This PR updates the appearance of the Site Icon and media upload buttons to match their functionality. The previous styling made these elements look like drop areas, confusing when users attempted to drag and drop files onto them, as they only function as clickable buttons.

Trac ticket: #47579

Before

Screenshot 2025-04-23 at 12 36 02 PM Screenshot 2025-04-23 at 12 35 39 PM

image

After

image

Screenshot 2025-04-23 at 12 35 12 PM image

Copy link

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

  • The Plugin and Theme Directories cannot be accessed within Playground.
  • 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.

@Infinite-Null Infinite-Null marked this pull request as ready for review April 23, 2025 07:13
Copy link

github-actions bot commented Apr 23, 2025

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 ankitkumarshah, joedolson.

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

@joedolson joedolson self-requested a review May 20, 2025 15:15
Copy link
Contributor

@joedolson joedolson left a comment

Choose a reason for hiding this comment

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

These changes look good. Have you checked whether the button-add-site-icon class is still in use? If that was the only use of that class, then we should be able to remove the related CSS.

((We can't remove button-add-media, as that's widely used by plugins and themes.)

I'd also like to see more of a compromise design: use the upload button styles, but keep the full width layout and padding.

@Infinite-Null
Copy link
Author

Hi @joedolson, Thank you for the feedback. I have made the necessary changes and updated the PR please review it at your convenience.

Screenshot:

image

@Infinite-Null Infinite-Null requested a review from joedolson May 21, 2025 08:50
@joedolson
Copy link
Contributor

Some additional changes that I think would help make things more consistent:

  1. When an image is selected, e.g. for the background image, you end up with a small 'Remove' button and a large 'Change Image' button. I think it would be good if those were the same size, either both large or both small. I suggest small; I think that the Change Image button is different from the UPload Image button.

  2. The Add Header image interface still uses the dashed outline design, but with a separate upload button. I think it would be good to make those all the same: eliminate the dashed placeholder space and use a large upload button.

These changes are otherwise good!

Copy link
Contributor

@joedolson joedolson left a comment

Choose a reason for hiding this comment

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

Requested changes are noted in a comment; they're less changes to the existing code and more additions that would be helpful.

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.

2 participants