49 lines
1.2 KiB
TypeScript
49 lines
1.2 KiB
TypeScript
import type { Metadata } from "next";
|
|
import { Geist, Geist_Mono } from "next/font/google";
|
|
import { ReactNode } from "react";
|
|
import { NextIntlClientProvider } from "next-intl";
|
|
import { getMessages } from "next-intl/server";
|
|
import "./globals.css";
|
|
|
|
const geistSans = Geist({
|
|
variable: "--font-geist-sans",
|
|
subsets: ["latin"],
|
|
});
|
|
|
|
const geistMono = Geist_Mono({
|
|
variable: "--font-geist-mono",
|
|
subsets: ["latin"],
|
|
});
|
|
|
|
export const metadata: Metadata = {
|
|
title: "Firma - Industrial Equipment & Pumps",
|
|
description:
|
|
"Premium industrial pumps and equipment supplier with 10+ years of experience",
|
|
};
|
|
|
|
async function RootLayout({
|
|
children,
|
|
params,
|
|
}: Readonly<{
|
|
children: ReactNode;
|
|
params: Promise<Record<string, any>>;
|
|
}>) {
|
|
const resolvedParams = await params;
|
|
const locale = resolvedParams.locale || "uz";
|
|
const messages = await getMessages();
|
|
|
|
return (
|
|
<html lang={locale}>
|
|
<body
|
|
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
|
|
>
|
|
<NextIntlClientProvider messages={messages}>
|
|
{children}
|
|
</NextIntlClientProvider>
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|
|
|
|
export default RootLayout;
|