104 lines
3.5 KiB
TypeScript
104 lines
3.5 KiB
TypeScript
import type { Metadata } from "next";
|
|
import { Suspense } from "react";
|
|
import { Geist, Geist_Mono, Lora, Bricolage_Grotesque } from "next/font/google";
|
|
import { ogDefault } from "@/lib/og";
|
|
import { ThemeProvider } from "@/components/theme-provider";
|
|
import { TooltipProvider } from "@/components/ui/tooltip";
|
|
import { SiteHeader } from "@/components/site-header";
|
|
import { SiteSidebar } from "@/components/site-sidebar";
|
|
import { SiteBottomNav } from "@/components/site-bottom-nav";
|
|
import { SiteFooter } from "@/components/site-footer";
|
|
import { TextSelectionToolbar } from "@/components/text-selection-toolbar";
|
|
import { TextHighlighter } from "@/components/text-highlighter";
|
|
import { AudioPlayerProvider, FloatingPlayer } from "@/components/audio-player";
|
|
import { AuthProvider } from "@/components/auth/auth-provider";
|
|
import { AuthGateProvider } from "@/components/auth/auth-gate";
|
|
import { VerifyEmailBanner } from "@/components/auth/verify-email-banner";
|
|
import { PageBookmarks } from "@/components/social/page-bookmarks";
|
|
import { Toaster } from "@/components/ui/toaster";
|
|
import "./globals.css";
|
|
|
|
const geistSans = Geist({
|
|
variable: "--font-sans",
|
|
subsets: ["latin"],
|
|
});
|
|
|
|
const geistMono = Geist_Mono({
|
|
variable: "--font-geist-mono",
|
|
subsets: ["latin"],
|
|
});
|
|
|
|
// Editorial serif — used for verse text always, and for site titles when
|
|
// the user enables "Serif Font" in reading settings.
|
|
const lora = Lora({
|
|
variable: "--font-serif",
|
|
weight: ["400", "500", "600", "700"],
|
|
style: ["normal", "italic"],
|
|
subsets: ["latin", "latin-ext"],
|
|
display: "swap",
|
|
});
|
|
|
|
// Display sans — used for site titles when Serif Font is OFF (the default).
|
|
// Bricolage Grotesque has slight humanist warmth so it pairs well with the
|
|
// reverent aesthetic without feeling cold or generic.
|
|
const bricolage = Bricolage_Grotesque({
|
|
variable: "--font-display",
|
|
weight: ["400", "500", "600", "700"],
|
|
subsets: ["latin"],
|
|
display: "swap",
|
|
});
|
|
|
|
export const metadata: Metadata = {
|
|
title: "Prabhupāda Says",
|
|
description:
|
|
"Browse the books and teachings of His Divine Grace A.C. Bhaktivedanta Swami Prabhupāda",
|
|
...ogDefault(),
|
|
};
|
|
|
|
export default function RootLayout({
|
|
children,
|
|
}: Readonly<{
|
|
children: React.ReactNode;
|
|
}>) {
|
|
return (
|
|
<html
|
|
lang="en"
|
|
suppressHydrationWarning
|
|
className={`${geistSans.variable} ${geistMono.variable} ${lora.variable} ${bricolage.variable} h-full antialiased`}
|
|
>
|
|
<body className="min-h-full flex flex-col">
|
|
<ThemeProvider
|
|
attribute="class"
|
|
defaultTheme="system"
|
|
enableSystem
|
|
disableTransitionOnChange
|
|
>
|
|
<AuthProvider>
|
|
<AuthGateProvider>
|
|
<AudioPlayerProvider>
|
|
<TooltipProvider>
|
|
<VerifyEmailBanner />
|
|
<SiteSidebar />
|
|
<div className="flex-1 flex flex-col md:pl-16 pb-16 md:pb-0">
|
|
<SiteHeader />
|
|
{children}
|
|
<SiteFooter />
|
|
</div>
|
|
<SiteBottomNav />
|
|
<TextSelectionToolbar />
|
|
<Suspense fallback={null}>
|
|
<TextHighlighter />
|
|
</Suspense>
|
|
<FloatingPlayer />
|
|
<PageBookmarks />
|
|
<Toaster />
|
|
</TooltipProvider>
|
|
</AudioPlayerProvider>
|
|
</AuthGateProvider>
|
|
</AuthProvider>
|
|
</ThemeProvider>
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|