0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-02-17 22:44:24 -05:00

chore: typo (#9988)

This commit is contained in:
Simon He 2024-02-06 17:28:15 +08:00 committed by GitHub
parent 44c72a4f6f
commit 6e30bef652
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -51,11 +51,11 @@ const fallbackImage = await getImage({
});
const imgAdditionalAttributes: HTMLAttributes<'img'> = {};
const sourceAdditionaAttributes: HTMLAttributes<'source'> = {};
const sourceAdditionalAttributes: HTMLAttributes<'source'> = {};
// Propagate the `sizes` attribute to the `source` elements
if (props.sizes) {
sourceAdditionaAttributes.sizes = props.sizes;
sourceAdditionalAttributes.sizes = props.sizes;
}
if (fallbackImage.srcSet.values.length > 0) {
@ -74,7 +74,7 @@ if (fallbackImage.srcSet.values.length > 0) {
<source
srcset={srcsetAttribute}
type={'image/' + image.options.format}
{...sourceAdditionaAttributes}
{...sourceAdditionalAttributes}
/>
);
})