32 lines
833 B
TypeScript
32 lines
833 B
TypeScript
import type { Metadata } from "next";
|
|
import { GeistSans } from "geist/font/sans";
|
|
import { GeistMono } from "geist/font/mono";
|
|
import "./globals.css";
|
|
import { ThemeProvider } from "./providers/ThemeProvider";
|
|
import { themeInitScript } from "./theme-init";
|
|
|
|
const geistSans = GeistSans;
|
|
const geistMono = GeistMono;
|
|
|
|
export const metadata: Metadata = {
|
|
title: "异度星球",
|
|
description: "数字游民社群",
|
|
};
|
|
|
|
export default function RootLayout({
|
|
children,
|
|
}: Readonly<{
|
|
children: React.ReactNode;
|
|
}>) {
|
|
return (
|
|
<html lang="zh-CN" suppressHydrationWarning>
|
|
<body
|
|
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
|
|
>
|
|
<script dangerouslySetInnerHTML={{ __html: themeInitScript }} />
|
|
<ThemeProvider>{children}</ThemeProvider>
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|