mirror of
https://github.com/withastro/astro.git
synced 2025-01-06 22:10:10 -05:00
fix(assets): Implement all hooks in the passthrough image service (#9668)
* fix(assets): Implement all hooks in the passthrough image service * chore: changeset
This commit is contained in:
parent
87ede76b3b
commit
74008cc238
2 changed files with 6 additions and 4 deletions
5
.changeset/long-mangos-walk.md
Normal file
5
.changeset/long-mangos-walk.md
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
"astro": patch
|
||||||
|
---
|
||||||
|
|
||||||
|
Fix the passthrough image service not generating `srcset` values properly
|
|
@ -2,11 +2,8 @@ import { baseService, type LocalImageService } from './service.js';
|
||||||
|
|
||||||
// Empty service used for platforms that neither support Squoosh or Sharp.
|
// Empty service used for platforms that neither support Squoosh or Sharp.
|
||||||
const noopService: LocalImageService = {
|
const noopService: LocalImageService = {
|
||||||
|
...baseService,
|
||||||
propertiesToHash: ['src'],
|
propertiesToHash: ['src'],
|
||||||
validateOptions: baseService.validateOptions,
|
|
||||||
getURL: baseService.getURL,
|
|
||||||
parseURL: baseService.parseURL,
|
|
||||||
getHTMLAttributes: baseService.getHTMLAttributes,
|
|
||||||
async transform(inputBuffer, transformOptions) {
|
async transform(inputBuffer, transformOptions) {
|
||||||
return {
|
return {
|
||||||
data: inputBuffer,
|
data: inputBuffer,
|
||||||
|
|
Loading…
Reference in a new issue