diff --git a/.changeset/purple-zebras-allow.md b/.changeset/purple-zebras-allow.md new file mode 100644 index 000000000000..64649ca6435e --- /dev/null +++ b/.changeset/purple-zebras-allow.md @@ -0,0 +1,5 @@ +--- +'@astrojs/image': patch +--- + +Add `fetchpriority` to allowed `Picture` attributes in `@astrojs/image` diff --git a/packages/integrations/image/components/index.ts b/packages/integrations/image/components/index.ts index 3135e0e21525..6c6d6910aa02 100644 --- a/packages/integrations/image/components/index.ts +++ b/packages/integrations/image/components/index.ts @@ -27,7 +27,7 @@ export interface ImageComponentRemoteImageProps extends TransformOptions, ImgHTM export interface PictureComponentLocalImageProps extends GlobalHTMLAttributes, Omit, - Pick { + Pick { src: ImageMetadata | Promise<{ default: ImageMetadata }>; /** Defines an alternative text description of the image. Set to an empty string (alt="") if the image is not a key part of the content (it's decoration or a tracking pixel). */ alt: string; @@ -39,7 +39,7 @@ export interface PictureComponentLocalImageProps export interface PictureComponentRemoteImageProps extends GlobalHTMLAttributes, TransformOptions, - Pick { + Pick { src: string; /** Defines an alternative text description of the image. Set to an empty string (alt="") if the image is not a key part of the content (it's decoration or a tracking pixel). */ alt: string;