Skip to content

Remove sizes attribute when responsive images are disabled #1399

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

Merged
merged 6 commits into from
Jul 26, 2024

Conversation

mukeshpanchal27
Copy link
Member

Summary

Fixes #1389

Check the issue description for testing details.

@mukeshpanchal27 mukeshpanchal27 added [Type] Bug An existing feature is broken [Plugin] Enhanced Responsive Images Issues for the Enhanced Responsive Images plugin (formerly Auto Sizes) skip changelog PRs that should not be mentioned in changelogs labels Jul 25, 2024
@mukeshpanchal27 mukeshpanchal27 added this to the auto-sizes n.e.x.t milestone Jul 25, 2024
@mukeshpanchal27 mukeshpanchal27 self-assigned this Jul 25, 2024
@mukeshpanchal27
Copy link
Member Author

As WordPress core does not add sizes attribute for thumbnail size, In e83ac2d i have to remove it from tests.

Is there any specific reason for it 🤔

@mukeshpanchal27 mukeshpanchal27 marked this pull request as ready for review July 25, 2024 11:37
Copy link

github-actions bot commented Jul 25, 2024

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.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: mukeshpanchal27 <mukesh27@git.wordpress.org>
Co-authored-by: westonruter <westonruter@git.wordpress.org>
Co-authored-by: adamsilverstein <adamsilverstein@git.wordpress.org>

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

@adamsilverstein
Copy link
Member

adamsilverstein commented Jul 25, 2024

As WordPress core does not add sizes attribute for thumbnail size, In e83ac2d i have to remove it from tests.

were tests failing without this change?

Is there any specific reason for it 🤔

I was wondering as well. Maybe for HDPI versions of thumbnails (x2) if that were a thing? For picture element we want srcset for fallbacks, but not sure why we would want sizes.

Copy link
Member

@adamsilverstein adamsilverstein left a comment

Choose a reason for hiding this comment

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

Nice!

@mukeshpanchal27
Copy link
Member Author

@westonruter @adamsilverstein or @swissspidy Could you please review and merge it. Thanks!

@westonruter westonruter merged commit 31abfce into trunk Jul 26, 2024
14 checks passed
@westonruter westonruter deleted the fix/1389-disable-responsive-images branch July 26, 2024 04:11
@westonruter westonruter removed the skip changelog PRs that should not be mentioned in changelogs label Jul 26, 2024
@westonruter westonruter changed the title Remove sizes attribute when the responsive image disabled Remove sizes attribute when responsive images are disabled Aug 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Plugin] Enhanced Responsive Images Issues for the Enhanced Responsive Images plugin (formerly Auto Sizes) [Type] Bug An existing feature is broken
Projects
Status: Done 😃
Development

Successfully merging this pull request may close these issues.

Accurate sizes improvement didn't account for the disable filter for sizes
3 participants