1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-07-21 05:41:17 -04:00

use <time> element for all dates

This commit is contained in:
2022-04-16 15:59:28 -04:00
parent 1648464e0e
commit fa968dbcd2
11 changed files with 217 additions and 202 deletions

View File

@@ -1,8 +1,8 @@
import Link from "next/link";
import Time from "../Time";
import HitCounter from "../HitCounter";
import NoteTitle from "../NoteTitle";
import { DateIcon, TagIcon, EditIcon, ViewsIcon } from "../Icons";
import { formatDateTZ } from "../../lib/helpers/format-date";
import { styled } from "../../lib/styles/stitches.config";
import * as config from "../../lib/config";
import type { NoteType } from "../../types";
@@ -68,11 +68,11 @@ const NoteMeta = ({ slug, date, title, htmlTitle, tags = [] }: NoteMetaProps) =>
}}
passHref={true}
>
<MetaLink title={formatDateTZ(date)}>
<MetaLink>
<span>
<Icon as={DateIcon} />
</span>
<span>{formatDateTZ(date, "MMMM d, yyyy")}</span>
<Time date={date} format="MMMM d, yyyy" />
</MetaLink>
</Link>
</MetaItem>