Refactored settings. Updated sidebar.

This commit is contained in:
Mike Cao 2025-08-15 22:16:28 -07:00
parent d130242a0a
commit 3c5c1e48e9
26 changed files with 144 additions and 129 deletions

View file

@ -20,12 +20,6 @@ export function SettingsLayout({ children }: { children: ReactNode }) {
path: renderUrl('/settings/preferences'),
icon: <Knobs />,
},
{
id: 'teams',
label: formatMessage(labels.teams),
path: renderUrl('/settings/teams'),
icon: <Users />,
},
],
},
{
@ -37,12 +31,18 @@ export function SettingsLayout({ children }: { children: ReactNode }) {
path: renderUrl('/settings/profile'),
icon: <UserCircle />,
},
{
id: 'teams',
label: formatMessage(labels.teams),
path: renderUrl('/settings/teams'),
icon: <Users />,
},
],
},
];
const selectedKey =
items.flatMap(e => e.items)?.find(({ path }) => path && pathname.endsWith(path))?.id ||
items.flatMap(e => e.items)?.find(({ path }) => path && pathname.includes(path))?.id ||
'overview';
return (