my website
1---
2import type { CollectionEntry } from "astro:content";
3import Intro from "./Intro.astro";
4import Tags from "./Tags.astro";
5import PrettyDate from "./PrettyDate.astro";
6
7type Props = Pick<
8 CollectionEntry<"blog">["data"],
9 "title" | "description" | "publish_date" | "tags"
10> & {
11 id: string;
12};
13
14const { title, description, publish_date, tags, id } = Astro.props;
15---
16
17<Intro title={title} transition:name={`post-title-${id}`}>
18 <PrettyDate slot="prefix" class="text-sm" date={publish_date} />
19 <Fragment slot="suffix">
20 <p transition:name={`post-snippet-${id}`} class="text-xl text-fg/80 mb-0">
21 {description}
22 </p>
23 <Tags tags={tags} />
24 </Fragment>
25</Intro>