forked from codechefPesuecc/CodeChef-PESUECC-Chapter
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlayout.tsx
More file actions
70 lines (65 loc) · 2.13 KB
/
Copy pathlayout.tsx
File metadata and controls
70 lines (65 loc) · 2.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
import type { Metadata } from "next";
import { Space_Grotesk, Inter, JetBrains_Mono } from "next/font/google";
import "./globals.css";
import Navbar from "@/components/Navbar";
import Footer from "@/components/Footer";
import HudFrame from "@/components/HudFrame";
import SmoothScroll from "@/components/SmoothScroll";
import ScrollProgress from "@/components/ScrollProgress";
import MotionProvider from "@/components/MotionProvider";
const spaceGrotesk = Space_Grotesk({
variable: "--font-space-grotesk",
subsets: ["latin"],
});
const inter = Inter({
variable: "--font-inter",
subsets: ["latin"],
});
const jetBrainsMono = JetBrains_Mono({
variable: "--font-jetbrains-mono",
subsets: ["latin"],
});
export const metadata: Metadata = {
title: {
default: "CodeChef PESUECC Chapter",
template: "%s · CodeChef PESUECC Chapter",
},
description:
"The official portal and competitive programming ecosystem of the CodeChef PESUECC Chapter — a daily arena, technical initiatives, and the team building it in the open.",
};
export default function RootLayout({
children,
}: Readonly<{
children: React.ReactNode;
}>) {
return (
<html
lang="en"
suppressHydrationWarning
className={`${spaceGrotesk.variable} ${inter.variable} ${jetBrainsMono.variable} h-full antialiased`}
>
<head>
{/*
* Apply the persisted theme before first paint so there is no flash of
* the wrong mode on load. Runs synchronously during HTML parsing and
* sets `.dark` on <html>; the Navbar toggle keeps it in sync afterwards.
*/}
<script
dangerouslySetInnerHTML={{
__html: `(function(){try{if(localStorage.getItem("theme")==="dark")document.documentElement.classList.add("dark")}catch(e){}})()`,
}}
/>
</head>
<body className="flex min-h-full flex-col font-sans">
<MotionProvider>
<SmoothScroll />
<ScrollProgress />
<Navbar />
<HudFrame />
<div className="flex flex-1 flex-col pt-24">{children}</div>
<Footer />
</MotionProvider>
</body>
</html>
);
}