Skip to content

Commit

Permalink
Merge pull request #180 from triptu/patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
chrismwilliams authored Dec 11, 2023
2 parents 891bfd4 + b212f9d commit 102ae52
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/blog/Hero.astro
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,10 @@ const dateTimeOptions: Intl.DateTimeFormatOptions = {
</div>
)
}
<h1 class="title mb-3 sm:mb-1">{data.title}</h1>
{data.draft ? <span class="text-base text-red-500">(Draft)</span> : null}
<h1 class="title mb-3 sm:mb-1">
{data.title}
</h1>
<div class="flex flex-wrap items-center gap-x-3 gap-y-2">
<p class="font-semibold">
<FormattedDate date={data.publishDate} dateTimeOptions={dateTimeOptions} /> /{" "}
Expand Down
1 change: 1 addition & 0 deletions src/components/blog/PostPreview.astro
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ const postDate = post.data.updatedDate ?? post.data.publishDate;

<FormattedDate date={postDate} class="min-w-[120px] text-gray-600 dark:text-gray-400" />
<Tag>
{post.data.draft && <span class="text-red-500">(Draft) </span>}
<a href={`/posts/${post.slug}/`} class="cactus-link" data-astro-prefetch>
{post.data.title}
</a>
Expand Down

0 comments on commit 102ae52

Please sign in to comment.