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
Use original
image to generate all additional image format sub-sizes
#207
Conversation
For all the generated sub-sizes use the original image instead of the attached image in order to accurate replicate the same process that WordPress uses to create each sub-size.
The removal of the `preg_replace` as is not required due we are using the original image, and the original image does not have a custom suffix.
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.
@mitogh Mostly looks good, I left a few comments.
The one critical thing we need to add here is about considering the orientation and applying the rotation as needed, similar to how WP core does.
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.
Great work @mitogh!
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.
Excellent! Left one tiny typo correction.
original
image to generate all subsizesoriginal
image to generate all additional image format sub-sizes
Summary
Fixes #204
Relevant technical choices
When creating all the sub-sizes for additional mime types, using the original image instead of the attached image would ensure that all additional sub-sizes have the same size as the original images.
Checklist
[Focus]
orInfrastructure
label.[Type]
label.no milestone
label.