Certificates react work

- renewal and download
- table columns rendering
- searching
- deleting
This commit is contained in:
Jamie Curnow committed 2025-10-27 18:08:37 +10:00
1 parent 7b5c70ed35
commit 0de26f2950
16 files changed
+381 -86

No files matched your search

@@ -0,0 +1,15 @@
import cn from "classnames";
import { isPast, parseISO } from "date-fns";
import { DateTimeFormat } from "src/locale";
interface Props {
value: string;
highlightPast?: boolean;
}
export function DateFormatter({ value, highlightPast }: Props) {
const dateIsPast = isPast(parseISO(value));
const cl = cn({
"text-danger": highlightPast && dateIsPast,
});
return <span className={cl}>{DateTimeFormat(value)}</span>;
}