M components/PostList.tsx => components/PostList.tsx +14 -6
@@ 9,12 9,20 @@ export function PostList({ posts }: Props) {
<ul class="space-y-4">
{posts.map((post) => (
<li class="h-entry border-l-4 border-primary pl-2 w-full">
- <div class="flex flex-wrap-reverse gap-2 justify-between ">
- <Link
- href={`/${post.path}`}
- label={post.title}
- className="p-name u-url"
- />
+ <div class="flex flex-wrap-reverse gap-2 justify-between">
+ <div class="flex gap-2">
+ <Link
+ href={`/${post.path}`}
+ label={post.title}
+ className="p-name u-url"
+ />
+ {post.draft &&
+ (
+ <div class="text-xs border-1 border-green-400 text-green-400 py-0.5 px-2 rounded-full lowercase">
+ Draft
+ </div>
+ )}
+ </div>
{post.date && (
<time
class="dt-published text-gray-400 font-mono"