---
import { Image } from 'astro:assets'
import Base from '../layouts/Base.astro'

const photos = import.meta.glob('../assets/galleria/*')

// @ts-ignore
const images = (await Promise.all(Object.values(photos).map(imgModule => imgModule()))).map(img => img.default)
---

<Base>
    <h1>
        Foto
        <img src="/~misuraca/foto.png" alt="foto" />
    </h1>
    <div class="photo-grid">
        {images.map((img, index) => <img src={img.src} alt="una foto" style={`--seed: ${index}`} />)}
    </div>
</Base>
