import { CalendarClock, Database, HardDrive } from "lucide-react";
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "~/client/components/ui/card";
import type { BackupSchedule } from "~/client/lib/types";
import { BackupStatusDot } from "./backup-status-dot";
import { formatShortDateTime, formatTimeAgo } from "~/client/lib/datetime";
import { Link } from "@tanstack/react-router";
export const BackupCard = ({ schedule }: { schedule: BackupSchedule }) => {
return (
{schedule.volume.name}
→
{schedule.repository.name}
Schedule
{schedule.cronExpression}
Last backup
{formatTimeAgo(schedule.lastBackupAt)}
Next backup
{formatShortDateTime(schedule.nextBackupAt)}
);
};