feat: unify recovery, updates, and schedules under Maintenance

This commit is contained in:
2026-09-27 16:00:18 -04:00
parent 8ea696417f
commit fc46cb9da4
42 changed files with 1256 additions and 833 deletions
@@ -0,0 +1,18 @@
<script lang="ts">
import type { PlutoniumVersion } from '$lib/plutonium.js';
import { uiNow } from '$ui/stores/servers.js';
let { name, version, after, ready = true }: { name: string; version?: PlutoniumVersion; after?: string | null; ready?: boolean } = $props();
const fresh = $derived(ready && version?.checked_at && $uiNow - Date.parse(version.checked_at) < 3_600_000 && (!after || version.checked_at > after));
const revision = $derived(fresh ? version?.revision : null);
const outdated = $derived(fresh && version?.update_status === 'outdated');
</script>
<a class:outdated href={`/maintenance?kind=updates&server=${encodeURIComponent(name)}`} title="View Plutonium updates and verification">
Plutonium {revision ? `r${revision}` : 'unverified'}{outdated ? ' · Update available' : ''}
</a>
<style>
a { font-size: var(--text-xs); color: var(--text-secondary); text-decoration: none; }
a:hover { color: var(--accent-primary-hover); text-decoration: underline; }
.outdated { color: var(--state-warning); }
</style>