-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Site Logo: Prevent uploading multiple images via drag and drop #68618
Conversation
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 If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Size Change: +33 B (0%) Total Size: 1.84 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
We may need to make the same changes to the featured image panel:
67344b8a5005f5f0e7cb726e41c91ea3.mp4
Thanks, @t-hamano!
Yes, let's update the featured image as well. If we spot more cases, we might want to consider a general solution. cc @swissspidy |
We can add a |
@Mamaduka Hmm this would benefit from an issue to discuss a more generalized solution vs. just changing this one off block. There are many different places:
It's definitely a bit unexpected to upload multiple files when actually only 1 ends up being visible in the respective block/panel. But should this really throw a hard error? Should this just (silently or with a warning) drop the excessive images instead? I think that would be good to define in an issue. |
@swissspidy, thank you for the feedback. I'll create a separate issue, and we can continue the discussion there. |
What?
PR adds a check to the
onFilesDrop
callback and prevents multiple image uploads via drag and drop.Why?
The block can only use a single image as the site logo.
Testing Instructions
Testing Instructions for Keyboard
Same.
Screenshots or screencast