disclosure-bureau/web/app/layout.tsx

29 lines
1.1 KiB
TypeScript
Raw Normal View History

import type { Metadata } from "next";
import { JetBrains_Mono, Inter } from "next/font/google";
import "./globals.css";
import { CommandPalette } from "@/components/command-palette";
import { LocaleToggle, getLocale } from "@/components/locale-toggle";
const inter = Inter({ subsets: ["latin"], variable: "--font-sans" });
const mono = JetBrains_Mono({ subsets: ["latin"], variable: "--font-mono" });
export const metadata: Metadata = {
title: "The Disclosure Bureau",
description: "Investigative wiki of the US Department of War UAP/UFO archive (war.gov/ufo)",
};
export default async function RootLayout({ children }: { children: React.ReactNode }) {
const locale = await getLocale();
return (
<html lang={locale === "en" ? "en" : "pt-BR"} className="dark" data-locale={locale}>
<body className={`${inter.variable} ${mono.variable}`}>
{children}
<CommandPalette />
<div className="fixed bottom-3 left-3 z-40 opacity-70 hover:opacity-100 transition">
<LocaleToggle current={locale} />
</div>
</body>
</html>
);
}