website refactor
This commit is contained in:
@@ -1,37 +1,5 @@
|
||||
'use client';
|
||||
import { CreateTeamPageClient } from '@/client-wrapper/CreateTeamPageClient';
|
||||
|
||||
import { CreateTeamForm } from '@/components/teams/CreateTeamForm';
|
||||
import { routes } from '@/lib/routing/RouteConfig';
|
||||
import { Container } from '@/ui/Container';
|
||||
import { Heading } from '@/ui/Heading';
|
||||
import { Stack } from '@/ui/Stack';
|
||||
import { Section } from '@/ui/Section';
|
||||
import { useRouter } from 'next/navigation';
|
||||
|
||||
export default function CreateTeamPage() {
|
||||
const router = useRouter();
|
||||
|
||||
const handleNavigate = (teamId: string) => {
|
||||
router.push(routes.team.detail(teamId));
|
||||
};
|
||||
|
||||
const handleCancel = () => {
|
||||
router.back();
|
||||
};
|
||||
|
||||
return (
|
||||
<Section>
|
||||
<Container size="sm">
|
||||
<Stack gap={8}>
|
||||
<Stack gap={2}>
|
||||
<Heading level={1}>Create a Team</Heading>
|
||||
</Stack>
|
||||
<CreateTeamForm
|
||||
onNavigate={handleNavigate}
|
||||
onCancel={handleCancel}
|
||||
/>
|
||||
</Stack>
|
||||
</Container>
|
||||
</Section>
|
||||
);
|
||||
export default async function CreateTeamPage() {
|
||||
return <CreateTeamPageClient />;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user