Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>
This commit is contained in:
parent
1b9b78bc3a
commit
4678a3f358
2 changed files with 6 additions and 1 deletions
5
.changeset/empty-sheep-march.md
Normal file
5
.changeset/empty-sheep-march.md
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
'@astrojs/image': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
Added support for GIF to Animated WEBP images
|
|
@ -82,7 +82,7 @@ class SharpService implements SSRImageService {
|
||||||
}
|
}
|
||||||
|
|
||||||
async transform(inputBuffer: Buffer, transform: TransformOptions) {
|
async transform(inputBuffer: Buffer, transform: TransformOptions) {
|
||||||
const sharpImage = sharp(inputBuffer, { failOnError: false });
|
const sharpImage = sharp(inputBuffer, { failOnError: false, pages: -1 });
|
||||||
|
|
||||||
// always call rotate to adjust for EXIF data orientation
|
// always call rotate to adjust for EXIF data orientation
|
||||||
sharpImage.rotate();
|
sharpImage.rotate();
|
||||||
|
|
Loading…
Add table
Reference in a new issue