import { getIntakeById } from '../actions'; import { IntakeHeader } from './components/intake-header'; import { IntakeTabs } from './components/intake-tabs'; import { notFound } from 'next/navigation'; import { ReactNode } from 'react'; interface IntakeLayoutProps { children: ReactNode; params: Promise<{ id: string; intakeId: string }>; } export default async function IntakeLayout({ children, params }: IntakeLayoutProps) { const { id, intakeId } = await params; const intake = await getIntakeById(intakeId); if (!intake) { notFound(); } return (
{children}
); }