fix(mui): stop dark/light oscillation (single data-theme owner) + animated ThemeToggle + white avatars

Removed MuiColorSchemeSync: it called MUI setMode which ALSO wrote data-theme, fighting ThemeContext (the other writer) → theme flip-flop loop. ThemeContext is now the sole owner; MUI's cssVariables CSS (scoped by [data-theme]) applies from the attribute, no JS bridge needed. New animated ThemeToggle kit button (sun/moon crossfade+rotate) replaces the static AppShell toggle. DashAttendanceToday avatars now solid-fill + white initials (matches StatCard/activity badges).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
BOHA
2026-06-07 07:39:14 +02:00
parent ef0bb9f27e
commit 177d3f1902
6 changed files with 62 additions and 55 deletions

View File

@@ -89,8 +89,8 @@ export default function DashAttendanceToday({
height: 36,
fontSize: "0.8rem",
fontWeight: 700,
bgcolor: isDefault ? "action.hover" : `${color}.light`,
color: isDefault ? "text.secondary" : `${color}.main`,
bgcolor: isDefault ? "grey.600" : `${color}.main`,
color: "common.white",
}}
>
{u.initials || "?"}