fosrl.pangolin/src/app/layout.tsx

47 lines
1.5 KiB
TypeScript
Raw Normal View History

2024-09-27 19:48:49 -04:00
import type { Metadata } from "next";
import "./globals.css";
import { Figtree } from "next/font/google";
2024-10-14 12:10:02 -04:00
import { Toaster } from "@/components/ui/toaster";
2024-10-14 18:26:07 -04:00
import { ThemeProvider } from "@app/providers/ThemeProvider";
import EnvProvider from "@app/providers/EnvProvider";
2024-09-27 19:48:49 -04:00
export const metadata: Metadata = {
2024-10-26 17:24:31 -04:00
title: `Dashboard - Pangolin`,
description: ""
2024-09-27 19:48:49 -04:00
};
2024-11-23 11:42:22 -05:00
const font = Figtree({ subsets: ["latin"] });
2024-10-06 11:13:50 -04:00
export default async function RootLayout({
children
2024-09-27 19:48:49 -04:00
}: Readonly<{
2024-09-27 21:39:03 -04:00
children: React.ReactNode;
2024-09-27 19:48:49 -04:00
}>) {
2024-09-27 21:39:03 -04:00
return (
2024-10-14 18:26:07 -04:00
<html suppressHydrationWarning>
2024-12-16 22:49:16 -05:00
<body className={`${font.className}`}>
2024-10-14 18:26:07 -04:00
<ThemeProvider
attribute="class"
defaultTheme="system"
enableSystem
disableTransitionOnChange
>
<EnvProvider
// it's import not to pass all of process.env here in case of secrets
// select only the necessary ones
env={{
NEXT_PORT: process.env.NEXT_PORT as string,
SERVER_EXTERNAL_PORT: process.env
.SERVER_EXTERNAL_PORT as string,
ENVIRONMENT: process.env.ENVIRONMENT as string
}}
>
{children}
</EnvProvider>
2024-10-14 18:26:07 -04:00
<Toaster />
</ThemeProvider>
2024-10-06 11:13:50 -04:00
</body>
2024-09-27 21:39:03 -04:00
</html>
);
2024-09-27 19:48:49 -04:00
}