diff --git a/packages/frontend/src/shell/AppLayout.tsx b/packages/frontend/src/shell/AppLayout.tsx index fdc1086..ad84589 100644 --- a/packages/frontend/src/shell/AppLayout.tsx +++ b/packages/frontend/src/shell/AppLayout.tsx @@ -1,5 +1,5 @@ import { useState, useEffect, useCallback } from 'react'; -import { Outlet, NavLink, useNavigate } from 'react-router-dom'; +import { Outlet, NavLink, useNavigate, useLocation } from 'react-router-dom'; import { useQuery } from '@tanstack/react-query'; import { useAuth } from '../auth/AuthContext'; import { UserAvatar } from '../components/UserAvatar'; @@ -113,7 +113,11 @@ const THEME_OPTIONS = [ export function AppLayout() { const { user, logout } = useAuth(); const navigate = useNavigate(); + const location = useLocation(); const { mode, setMode } = useTheme(); + + // Auf der Dashboard-Seite hat die Tab-Leiste bereits das Profil – kein Topbar nötig + const isDashboard = location.pathname === '/'; const { isModuleEnabled } = useCrmSettings(); // Silently sync INSIGHT profile from O365 once per browser session @@ -584,8 +588,8 @@ export function AppLayout() { marginLeft: collapsed ? 60 : (branding?.sidebarWidth ?? undefined), }} > - {/* Topbar: Profil + Logout + Modiwahl oben rechts */} -
+ {/* Topbar: Profil + Logout + Modiwahl oben rechts (nicht auf Dashboard) */} +
{/* Theme-Schalter (☀ ☾ ⚙) */}
{THEME_OPTIONS.map((opt) => (