+ {pageError && (
+
+ {pageError instanceof Error ? pageError.message : 'Request failed'}
+
+ )}
+
+
+
+
+
+
+ {projectId && (
+ <>
+
+
+
+
+
+
+
+
+
+ >
+ )}
+
+
+ {projectId && metrics && (
+
+
+
+
+
+
+ )}
+
+ {projectId && (
+
+
+
+
Findings
+
+ {vulnsQuery.isLoading ? (
+
Loading…
+ ) : vulns.length === 0 ? (
+
No open findings.
+ ) : (
+
+ {vulns.map((v) => (
+
+
+
+
+ {v.severity}
+
+
{v.title}
+
+
{v.description}
+
+ {v.type} · {v.status} · found {v.found_at ? formatRelative(v.found_at) : '—'}
+
+
+ {v.status === 'open' && v.id && (
+
+
+
+
+ )}
+
+ ))}
+
+ )}
+
+ )}
+
+ {projectId && (
+
+
+
+
Scan history
+
+ {historyQuery.isLoading ? (
+
Loading…
+ ) : (historyQuery.data ?? []).length === 0 ? (
+
No scans yet.
+ ) : (
+
+ {(historyQuery.data ?? []).map((scan) => (
+
+
+
+ {scan.scan_type} · {scan.findings_count ?? 0} findings
+
+
+ {scan.started_at ? formatRelative(scan.started_at) : '—'}
+
+
+
+ {scan.status}
+
+
+ ))}
+
+ )}
+
+ )}
+