Unify workspace dropdowns; Update layouts (#458)
Unified Account and Workspace drop-downs; Layout updates, now header lives within the PageBody component; Sidebars now use floating variant
This commit is contained in:
committed by
GitHub
parent
ca585e09be
commit
4bc8448a1d
39
apps/web/app/[locale]/home/[account]/settings/layout.tsx
Normal file
39
apps/web/app/[locale]/home/[account]/settings/layout.tsx
Normal file
@@ -0,0 +1,39 @@
|
||||
import { AppBreadcrumbs } from '@kit/ui/app-breadcrumbs';
|
||||
import { PageBody } from '@kit/ui/page';
|
||||
import { Trans } from '@kit/ui/trans';
|
||||
|
||||
import featuresFlagConfig from '~/config/feature-flags.config';
|
||||
|
||||
import { TeamAccountLayoutPageHeader } from '../_components/team-account-layout-page-header';
|
||||
import { SettingsSubNavigation } from './_components/settings-sub-navigation';
|
||||
|
||||
interface SettingsLayoutProps {
|
||||
children: React.ReactNode;
|
||||
params: Promise<{ account: string }>;
|
||||
}
|
||||
|
||||
async function SettingsLayout({ children, params }: SettingsLayoutProps) {
|
||||
const { account } = await params;
|
||||
|
||||
return (
|
||||
<PageBody>
|
||||
<div>
|
||||
<TeamAccountLayoutPageHeader
|
||||
account={account}
|
||||
title={<Trans i18nKey={'teams.settings.pageTitle'} />}
|
||||
description={<AppBreadcrumbs />}
|
||||
/>
|
||||
|
||||
{featuresFlagConfig.enableTeamsOnly && (
|
||||
<div className="mb-8">
|
||||
<SettingsSubNavigation account={account} />
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{children}
|
||||
</PageBody>
|
||||
);
|
||||
}
|
||||
|
||||
export default SettingsLayout;
|
||||
Reference in New Issue
Block a user