import { Stack, Group, Text, NavLink, ThemeIcon, Button, Box } from '@mantine/core'; import { IconLayoutDashboard, IconUsers, IconShieldCheck, IconLifebuoy, } from '@tabler/icons-react'; import { useNavigate, useLocation } from 'react-router-dom'; const NAV_ITEMS = [ { label: 'Dashboard', icon: IconLayoutDashboard, path: '/dashboard' }, { label: 'User Management', icon: IconUsers, path: '/um/user-management/dashboard' }, ]; export function AppSidebar() { const navigate = useNavigate(); const { pathname } = useLocation(); return ( {/* brand */}
EMA Admin Control Center
{/* menu */}
MENU {NAV_ITEMS.map(({ label, icon: Icon, path }) => ( } active={pathname.startsWith(path)} onClick={() => navigate(path)} variant="light" color="blue" styles={{ root: { borderRadius: 10 }, label: { fontWeight: 500 } }} /> ))}
{/* help card */} Need help? Browse guides or contact support.
); }