--- import { getCollection } from 'astro:content'; interface Props { images: { src: string; alt: string; title?: string }[]; albumTitle?: string; showCategory?: boolean; category?: string; } const { images, albumTitle = '', showCategory = false, category = '' } = Astro.props; const imagesForJS = JSON.stringify(images); // Construire les labels depuis la collection const photoCategories = await getCollection('photoCategories'); const categoryLabels: Record = { 'blog': 'Fil Photo', ...Object.fromEntries(photoCategories.map(cat => [cat.id, cat.data.title])) }; ---