mirror of
https://github.com/mikkelsvartveit/astro-personal-website.git
synced 2025-12-22 11:12:38 +00:00
Optimize image sizes
This commit is contained in:
parent
d46d818e7c
commit
5153e9c6fb
3 changed files with 9 additions and 1 deletions
Binary file not shown.
|
Before Width: | Height: | Size: 2.9 MiB After Width: | Height: | Size: 271 KiB |
|
|
@ -40,6 +40,8 @@ const articles = await getCollection("blog");
|
|||
<Image
|
||||
src={image}
|
||||
alt={title}
|
||||
width={320}
|
||||
densities={[1, 2]}
|
||||
class="col-span-1 h-48 object-cover sm:h-full"
|
||||
/>
|
||||
|
||||
|
|
|
|||
|
|
@ -72,7 +72,13 @@ const latestArticleImage = latestArticle.data.image;
|
|||
<div
|
||||
class="flex items-center overflow-hidden rounded-lg bg-white underline-offset-4 shadow transition hover:underline hover:shadow-md"
|
||||
>
|
||||
<Image src={latestArticleImage} alt="" class="h-16 w-24 object-cover" />
|
||||
<Image
|
||||
src={latestArticleImage}
|
||||
alt=""
|
||||
class="h-16 w-24 object-cover"
|
||||
width={100}
|
||||
densities={[1, 2]}
|
||||
/>
|
||||
<h3 class="mx-3 line-clamp-2 font-serif text-lg leading-snug">
|
||||
{latestArticleTitle}
|
||||
</h3>
|
||||
|
|
|
|||
Loading…
Reference in a new issue