aaaaaaaa
This commit is contained in:
@@ -71,7 +71,7 @@
|
|||||||
{post.data.author}
|
{post.data.author}
|
||||||
</address>
|
</address>
|
||||||
<div class="inline-block post-meta col-start-3 lg:ml-1">
|
<div class="inline-block post-meta col-start-3 lg:ml-1">
|
||||||
<Time time={parseTime(post.data.pubDate)} />
|
<Time datetime={post.data.pubDate} />
|
||||||
</div>
|
</div>
|
||||||
<div class="col-span-3">{post.data.summary}</div>
|
<div class="col-span-3">{post.data.summary}</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import type { Temporal } from "@js-temporal/polyfill";
|
import type { Temporal } from "@js-temporal/polyfill";
|
||||||
import { printTime } from "../utils/time";
|
import { parseTime, printTime } from "../utils/time";
|
||||||
|
|
||||||
interface Props {
|
interface Props {
|
||||||
time: Temporal.ZonedDateTime
|
datetime: string
|
||||||
}
|
}
|
||||||
|
|
||||||
const { time }: Props = $props();
|
const { datetime }: Props = $props();
|
||||||
|
const time = $derived(parseTime(datetime));
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<time datetime={time.toString()} class="post-meta inline-block col-start-3">
|
<time datetime={time.toString()} class="post-meta inline-block col-start-3">
|
||||||
|
|||||||
@@ -13,11 +13,9 @@ const { title, author, summary, pubDate, updatedDate } = Astro.props;
|
|||||||
<header class="lg:grid grid-cols-[auto_auto_minmax(300px,_1fr)] grid-rows-[auto_auto]">
|
<header class="lg:grid grid-cols-[auto_auto_minmax(300px,_1fr)] grid-rows-[auto_auto]">
|
||||||
<h2 class="font-bold row-span-2 text-2xl m-2 mt-3">{title}</h2>
|
<h2 class="font-bold row-span-2 text-2xl m-2 mt-3">{title}</h2>
|
||||||
<address class="post-meta inline-block col-start-2">{author}</address>
|
<address class="post-meta inline-block col-start-2">{author}</address>
|
||||||
<Time client:load time={parseTime(pubDate)} />
|
<Time client:load time={pubDate} />
|
||||||
<div class="italic tracking-[3px] text-emph-fg col-start-2 col-span-2 m-2 mt-0">{summary}</div>
|
<div class="italic tracking-[3px] text-emph-fg col-start-2 col-span-2 m-2 mt-0">{summary}</div>
|
||||||
{updatedDate && <div>
|
{updatedDate && <div>Amended <Time time={updatedDate} /></div>}
|
||||||
Amended <Time time={parseTime(updatedDate)} />
|
|
||||||
</div>}
|
|
||||||
</header>
|
</header>
|
||||||
<hr class="mb-3">
|
<hr class="mb-3">
|
||||||
<main class="max-w-[100ch] font-prose post-content">
|
<main class="max-w-[100ch] font-prose post-content">
|
||||||
|
|||||||
Reference in New Issue
Block a user