Improved images

This commit is contained in:
2025-01-30 23:17:41 +00:00
parent 16bc996103
commit 8f63b56619
4 changed files with 22 additions and 10 deletions

View File

@@ -1,4 +1,5 @@
---
import { Image } from "astro:assets";
import Main from "../layouts/Main.astro";
---
@@ -8,7 +9,8 @@ import Main from "../layouts/Main.astro";
description="Lawrence Bethlenfalvy, software engineer"
>
<div class="max-w-[80ch] m-5">
<img src='https://github.com/lbfalvy.png'
<Image src='https://github.com/lbfalvy.png' loading="eager"
alt="My face" width="120" height="120"
class="rounded-full h-30 float-right m-3 [shape-outside:_ellipse()]" />
<p>
My name is Lawrence Bethlenfalvy, I make websites and web-based applications primarily

View File

@@ -1,6 +1,7 @@
---
import { getCollection, render } from "astro:content";
import Main from "../layouts/Main.astro";
import { Image } from "astro:assets";
const projects = await getCollection("projects");
const projReady = await Promise.all(
@@ -14,9 +15,10 @@ const projReady = await Promise.all(
projReady.map(([proj, Content]) => (
<a href={proj.data.url}>
<article class="emph-bg m-3 p-2 text-sm rounded-2xl">
{proj.data.image && <img
{proj.data.image && <Image
src={proj.data.image}
alt=""
loading="eager"
width="100" height="60"
class="object-center aspect-[16/9] w-full"
/>}