Closed Odas0R closed 1 year ago
This issue has been labeled as a bug since it was created using the 🚨 Bug Report Template.
Hi there, thank you so much for the report!
Following our Maintenance Process, we will review your bug report and get back to you next Wednesday. To ensure a smooth review of your issue and avoid unnecessary delays, please make sure your issue includes the following:
package.json
file.If you have identified the cause of the bug described in your report and know how to fix it, you're more than welcome to open a pull request addressing it. Check out our quick start guide for a simple contribution process.
If you think your issue is a question (not a bug) and would like quicker support, please close this issue and forward it to an appropriate section on our community forum: https://community.prismic.io
- The Prismic Open-Source Team
Hey there, thank you so much for contributing. I'm sorry we failed to get back to you in a timely manner.
I tried reproducing without success, those tests pass as expected (committed version: https://github.com/prismicio/prismic-helpers/commit/5ee387a4abbefdb50970cc80585795af11fdd752 /CI results: https://github.com/prismicio/prismic-helpers/actions/runs/5465804619/jobs/9949788226):
expect(
asImageSrc(field, {
w: 250,
h: 250,
q: 75,
fm: "webp",
fit: "crop",
}),
).toBe(`${field.url}&w=250&h=250&q=75&fm=webp&fit=crop`);
expect(
asImageSrc(field, {
width: 250,
height: 250,
q: 75,
fm: "webp",
fit: "crop",
}),
).toBe(`${field.url}&width=250&height=250&q=75&fm=webp&fit=crop`);
Equivalent images appear to be rendered as expected:
width
/height
: https://images.prismic.io/prismicio-docs-v3/72606106-11e9-4da2-8dd1-14f779eda024_Sign-up+form+slice.png?auto=compress%2Cformat&rect=0%2C0%2C1246%2C707&width=250&height=250&q=75&fm=webp&fit=cropw
/h
: https://images.prismic.io/prismicio-docs-v3/72606106-11e9-4da2-8dd1-14f779eda024_Sign-up+form+slice.png?auto=compress%2Cformat&rect=0%2C0%2C1246%2C707&w=250&h=250&q=75&fm=webp&fit=cropI'm confused if I got your issue correctly, maybe this was a regression back then on Imgix's end? Well let me know, I'm closing it for now but happy to reopen~
Versions
Steps to reproduce
What is expected?
Using the param
width
andheight
optimize the imageWhat is actually happening?
The param
width
andheight
have no effect