fix(admin): drop duplicate card title on single-card pages

`/admin/danger-zone` and `/admin/feedback` are single-card admin
pages where the page-level header already names the section.
The card-level h2 ("Danger Zone" / "Feedback Inbox") was a verbatim
copy of that header taking up vertical space without adding info.
Removed the duplicate headers — the section icon stays so the
card still has a visible affordance.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Marc-André BombeckandClaude Opus 4.7 committed 2026-05-10 13:49:58 +02:00
1 parent 3f6e670894
commit 70ebe32b27
2 files changed
+18 -7

No files matched your search

@@ -92,13 +92,17 @@ describe("admin sections — SSR smoke", () => {
it("<IntegrationsGroupSection> renders all four sub-sections", () => {
const html = render(<IntegrationsGroupSection />);
expect(html).toContain("Umami");
expect(html).toContain("Glitchtip");
expect(html).toContain("GlitchTip");
expect(html).toContain("Web Push");
});
it("<FeedbackInboxSection> renders", () => {
const html = render(<FeedbackInboxSection />);
expect(html).toContain("Feedback");
// F-08 dedupe: card no longer carries a duplicate "Feedback"
// header. Anchor on the empty-state copy + status tabs instead.
expect(html).toContain("All caught up");
expect(html).toContain("Open");
expect(html).toContain("Resolved");
});
it("<RemindersSection> renders", () => {
@@ -132,7 +136,10 @@ describe("admin sections — SSR smoke", () => {
it("<DangerZoneSection> renders", () => {
const html = render(<DangerZoneSection />);
expect(html).toContain("Danger Zone");
// F-08 dedupe: the card no longer carries a "Danger Zone" header
// (the page title already provides it). Assert on the action copy
// instead so the section is still anchored.
expect(html).toContain("Delete all data globally");
});
// v1.4.16 phase B5e — admin AI quality preview. The mocked useQuery
+8 -4
View File
@@ -66,11 +66,15 @@ export function DangerZoneSection() {
return (
<div className="bg-destructive/5 border-destructive/30 rounded-xl border p-6">
{/* v1.4.19 A8 / F-08: page header `admin.section.danger-zone.*`
already names the section, so the card-level title was a
duplicate of the page title. The destructive icon stays so
the card still flags itself as dangerous at a glance. */}
<div className="flex items-center gap-2">
<AlertTriangle className="text-destructive h-5 w-5" />
<div className="text-destructive text-lg font-semibold">
{t("admin.dangerZone")}
</div>
<AlertTriangle
className="text-destructive h-5 w-5"
aria-hidden="true"
/>
</div>
<div className="mt-4">
<p className="text-sm font-medium">{t("admin.deleteAllData")}</p>