add button in the header to star entry (#1025)

This commit is contained in:
Athou
2024-04-14 11:26:39 +02:00
parent 5d75885352
commit 0d081bc47e
19 changed files with 229 additions and 39 deletions

View File

@@ -1,5 +1,6 @@
import { Trans } from "@lingui/macro"
import { Tooltip } from "@mantine/core"
import { Constants } from "app/constants"
import dayjs from "dayjs"
import { useEffect, useState } from "react"
@@ -13,7 +14,7 @@ export function RelativeDate(props: { date: Date | number | undefined }) {
if (!props.date) return <Trans>N/A</Trans>
const date = dayjs(props.date)
return (
<Tooltip label={date.toDate().toLocaleString()} openDelay={500}>
<Tooltip label={date.toDate().toLocaleString()} openDelay={Constants.tooltip.delay}>
<span>{date.from(dayjs(now))}</span>
</Tooltip>
)