feat: introduce new components for improved structure and functionality
This commit is contained in:
parent
2e511b5e00
commit
c5e26d83c1
10 changed files with 101 additions and 62 deletions
|
|
@ -4,10 +4,9 @@ interface Props {
|
|||
date: Date;
|
||||
title: string;
|
||||
description: string;
|
||||
tags?: string[];
|
||||
}
|
||||
|
||||
const { id, date, title, description, tags } = Astro.props;
|
||||
const { id, date, title, description } = Astro.props;
|
||||
---
|
||||
|
||||
<a href={`/posts/${id}`}>
|
||||
|
|
@ -22,13 +21,6 @@ const { id, date, title, description, tags } = Astro.props;
|
|||
}
|
||||
</div>
|
||||
<h2 class="text-2xl font-semibold mb-1">{title}</h2>
|
||||
<p class="text-sm mb-3">{description}</p>
|
||||
<div class="flex flex-wrap gap-2">
|
||||
{
|
||||
tags?.map((tag) => (
|
||||
<span class="text-xs text-zinc-400 font-semibold">#{tag}</span>
|
||||
))
|
||||
}
|
||||
</div>
|
||||
<p class="text-base text-zinc-400">{description}</p>
|
||||
</div>
|
||||
</a>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue