import {
  Card,
  CardContent,
  CardDescription,
  CardHeader,
  CardTitle,
} from '@/components/ui/card';
import { LeaveRequestForm } from '@/components/employee/leave-request-form';
import { getTranslations, getCurrentLocale } from '@/lib/i18n';

export default async function LeaveRequestPage() {
  const locale = await getCurrentLocale();
  const t = getTranslations(locale).LeaveRequest;
  const tGlobal = getTranslations(locale).Global;

  return (
    <div className="mx-auto grid w-full max-w-6xl gap-2">
      <h1 className="text-3xl font-semibold">{t.title}</h1>
      <Card>
        <CardHeader>
          <CardTitle>{t.cardTitle}</CardTitle>
          <CardDescription>
            {t.cardDescription}
          </CardDescription>
        </CardHeader>
        <CardContent>
          <LeaveRequestForm t={t} tGlobal={tGlobal}/>
        </CardContent>
      </Card>
    </div>
  );
}

    
