64 lines
1.8 KiB
TypeScript
64 lines
1.8 KiB
TypeScript
import OrderPage from '@/features/cart/ui/OrderPage';
|
||
import { Metadata } from 'next';
|
||
import { Suspense } from 'react';
|
||
|
||
interface Props {
|
||
params: { locale: 'uz' | 'ru' };
|
||
}
|
||
|
||
export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
||
const { locale } = await params;
|
||
|
||
const titles = {
|
||
uz: 'Buyurtma | GASTRO',
|
||
ru: 'Оформление заказа | Магазин товаров',
|
||
};
|
||
|
||
const descriptions = {
|
||
uz: 'Buyurtma sahifasi orqali xaridingizni tasdiqlang, yetkazib berish manzilini belgilang va to‘lov usulini tanlang. Tez va qulay xarid tajribasi.',
|
||
ru: 'Страница оформления заказа. Подтверждайте покупки, указывайте адрес доставки и выбирайте способ оплаты. Быстрый и удобный процесс покупки.',
|
||
};
|
||
|
||
const keywords = {
|
||
uz: 'buyurtma, xarid, yetkazib berish, mahsulotlar, online do‘kon, to‘lov',
|
||
ru: 'заказ, покупки, доставка, товары, онлайн-магазин, оплата',
|
||
};
|
||
|
||
return {
|
||
title: titles[locale],
|
||
description: descriptions[locale],
|
||
keywords: keywords[locale],
|
||
openGraph: {
|
||
title: titles[locale],
|
||
description: descriptions[locale],
|
||
siteName: 'GASTRO',
|
||
images: [
|
||
{
|
||
url: '/logos/logo.png', // public papkadan rasm
|
||
width: 1200,
|
||
height: 1200,
|
||
alt: titles[locale],
|
||
},
|
||
],
|
||
locale: locale === 'uz' ? 'uz_UZ' : 'ru_RU',
|
||
type: 'website',
|
||
},
|
||
twitter: {
|
||
card: 'summary_large_image',
|
||
title: titles[locale],
|
||
description: descriptions[locale],
|
||
images: ['/logos/logo.png'],
|
||
},
|
||
};
|
||
}
|
||
|
||
const Page = () => {
|
||
return (
|
||
<Suspense>
|
||
<OrderPage />
|
||
</Suspense>
|
||
);
|
||
};
|
||
|
||
export default Page;
|