From 1e3eb8649526555c86d5a216a424826e5d13c93f Mon Sep 17 00:00:00 2001 From: simoleo89 Date: Wed, 15 Jul 2026 21:32:05 +0200 Subject: [PATCH] Add dark/light toggle to admin sidebar and topbar. Reuse ThemeSwitcher with an admin variant (Sun/Moon) next to the staff profile and in the housekeeping header. Co-authored-by: Cursor --- src/app/admin/layout.tsx | 3 +++ src/components/theme-switcher.tsx | 32 +++++++++++++++++++++++++++---- 2 files changed, 31 insertions(+), 4 deletions(-) diff --git a/src/app/admin/layout.tsx b/src/app/admin/layout.tsx index 9531db03..4335d293 100644 --- a/src/app/admin/layout.tsx +++ b/src/app/admin/layout.tsx @@ -6,6 +6,7 @@ import type { ReactNode } from "react"; import { AdminHubChrome } from "@/components/admin/admin-hub-chrome"; import { AdminMobileWrapper } from "@/components/admin/admin-mobile-wrapper"; import { AdminNavLink } from "@/components/admin/admin-nav-link"; +import { ThemeSwitcher } from "@/components/theme-switcher"; import { requireStaff } from "@/lib/admin/guard"; import { ADMIN_NAV_GROUPS } from "@/lib/admin-nav"; import { prisma } from "@/lib/prisma"; @@ -73,6 +74,7 @@ async function Sidebar({ {t("rankLabel", { rank: staff.rank })} +