'use client';

import OrderSummaryStrip from './components/OrderSummaryStrip';
import OrdersTable from './components/OrdersTable';
import { usePageHeader } from '@client/contexts/PageHeaderContext';
import { useLanguage } from '@client/contexts/LanguageContext';

type TFn = (key: string, fallback?: string, vars?: Record<string, string | number>) => string;

export default function OrderManagementPage() {
  const { t, currentLang } = useLanguage();
  const today = new Date()?.toLocaleDateString(currentLang, { weekday: 'long', month: 'long', day: 'numeric', year: 'numeric' });
  usePageHeader(t('nav.orders', 'Order Management'), today);
  return (
    <>
      <OrderSummaryStrip />
      <OrdersTable />
    </>
  );
}
