"use client"; /** * What a backup pass is doing now, and which accounts a run died under. * * A pass whose process died (a restart, or a container out of memory) used * to leave nothing on this page: the job sat `active` until its expiry and * the last finished run still read fine. The run in progress and the * accounts whose last attempt started and never finished are both recorded * now (`backup-pass-attempts.ts`), so the page says so while it matters. */ import { AlertTriangle } from "lucide-react"; import { useFormatters, useTranslations } from "@/lib/i18n/context"; import type { BackupPassActivity } from "@/lib/jobs/backup-pass-attempts"; export function BackupPassActivityNotice({ activity, }: { activity: BackupPassActivity; }) { const { t } = useTranslations(); const fmt = useFormatters(); if (activity.runningSince === null && activity.interrupted.length === 0) { return null; } return (
{t("admin.section.backups.activity.running", { when: fmt.dateTime(activity.runningSince), })}
) : null} {activity.interrupted.length > 0 ? ({t("admin.section.backups.activity.interruptedTitle")}
{t("admin.section.backups.activity.interruptedRemedy")}