mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-07-09 06:55:07 +00:00
27 lines
612 B
TypeScript
27 lines
612 B
TypeScript
import type { AppProps } from "next/app"
|
|
import { Inter as FontSans } from "@next/font/google"
|
|
import { ThemeProvider } from "next-themes"
|
|
|
|
import "@/styles/globals.css"
|
|
|
|
const fontSans = FontSans({
|
|
subsets: ["latin"],
|
|
variable: "--font-sans",
|
|
display: 'swap',
|
|
})
|
|
|
|
export default function App({ Component, pageProps }: AppProps) {
|
|
return (
|
|
<>
|
|
<style jsx global>{`
|
|
:root {
|
|
--font-sans: ${fontSans.style.fontFamily};
|
|
}
|
|
}`}</style>
|
|
<ThemeProvider attribute="class" defaultTheme="system" enableSystem>
|
|
<Component {...pageProps} />
|
|
</ThemeProvider>
|
|
</>
|
|
)
|
|
}
|