feat: reference geist from google fonts (#876)
This commit is contained in:
parent
d26e0d9ac4
commit
1a8cd993f4
10 changed files with 73 additions and 75 deletions
|
|
@ -38,7 +38,7 @@ export default function Page() {
|
|||
setIsSuccessful(true);
|
||||
router.refresh();
|
||||
}
|
||||
}, [state.status, router]);
|
||||
}, [state.status]);
|
||||
|
||||
const handleSubmit = (formData: FormData) => {
|
||||
setEmail(formData.get('email') as string);
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ export default function Page() {
|
|||
setIsSuccessful(true);
|
||||
router.refresh();
|
||||
}
|
||||
}, [state, router]);
|
||||
}, [state]);
|
||||
|
||||
const handleSubmit = (formData: FormData) => {
|
||||
setEmail(formData.get('email') as string);
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@ import { cookies } from 'next/headers';
|
|||
|
||||
import { AppSidebar } from '@/components/app-sidebar';
|
||||
import { SidebarInset, SidebarProvider } from '@/components/ui/sidebar';
|
||||
|
||||
import { auth } from '../(auth)/auth';
|
||||
import Script from 'next/script';
|
||||
|
||||
|
|
|
|||
|
|
@ -102,20 +102,6 @@
|
|||
body {
|
||||
@apply bg-background text-foreground;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: "geist";
|
||||
font-style: normal;
|
||||
font-weight: 100 900;
|
||||
src: url(/fonts/geist.woff2) format("woff2");
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: "geist-mono";
|
||||
font-style: normal;
|
||||
font-weight: 100 900;
|
||||
src: url(/fonts/geist-mono.woff2) format("woff2");
|
||||
}
|
||||
}
|
||||
|
||||
.skeleton {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import type { Metadata } from 'next';
|
||||
import { Toaster } from 'sonner';
|
||||
|
||||
import type { Metadata } from 'next';
|
||||
import { Geist, Geist_Mono } from 'next/font/google';
|
||||
import { ThemeProvider } from '@/components/theme-provider';
|
||||
|
||||
import './globals.css';
|
||||
|
|
@ -15,6 +15,18 @@ export const viewport = {
|
|||
maximumScale: 1, // Disable auto-zoom on mobile Safari
|
||||
};
|
||||
|
||||
const geist = Geist({
|
||||
subsets: ['latin'],
|
||||
display: 'swap',
|
||||
variable: '--font-geist',
|
||||
});
|
||||
|
||||
const geistMono = Geist_Mono({
|
||||
subsets: ['latin'],
|
||||
display: 'swap',
|
||||
variable: '--font-geist-mono',
|
||||
});
|
||||
|
||||
const LIGHT_THEME_COLOR = 'hsl(0 0% 100%)';
|
||||
const DARK_THEME_COLOR = 'hsl(240deg 10% 3.92%)';
|
||||
const THEME_COLOR_SCRIPT = `\
|
||||
|
|
@ -48,6 +60,7 @@ export default async function RootLayout({
|
|||
// prop is necessary to avoid the React hydration mismatch warning.
|
||||
// https://github.com/pacocoursey/next-themes?tab=readme-ov-file#with-app
|
||||
suppressHydrationWarning
|
||||
className={`${geist.variable} ${geistMono.variable}`}
|
||||
>
|
||||
<head>
|
||||
<script
|
||||
|
|
@ -56,7 +69,7 @@ export default async function RootLayout({
|
|||
}}
|
||||
/>
|
||||
</head>
|
||||
<body className="">
|
||||
<body className="antialiased">
|
||||
<ThemeProvider
|
||||
attribute="class"
|
||||
defaultTheme="system"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue