fix: types errors

This commit is contained in:
DIYgod 2022-11-21 20:42:17 +00:00
parent bb02ae8ae9
commit c43d2e4733
No known key found for this signature in database
GPG Key ID: D159328F47A80DCA
1 changed files with 14 additions and 12 deletions

View File

@ -93,18 +93,20 @@ export const CharacterCard: React.FC<{
<span className="block">
<FollowingCount siteId={siteId} disableList={true} />
</span>
<span className="block text-gray-500">
Joined{" "}
<time dateTime={formatToISO(site?.date_created)}>
{dayjs
.duration(
dayjs(site?.date_created).diff(dayjs(), "minute"),
"minute",
)
.humanize()}{" "}
ago
</time>
</span>
{site?.date_created && (
<span className="block text-gray-500">
Joined{" "}
<time dateTime={formatToISO(site.date_created)}>
{dayjs
.duration(
dayjs(site.date_created).diff(dayjs(), "minute"),
"minute",
)
.humanize()}{" "}
ago
</time>
</span>
)}
</>
) : (
"Loading..."