mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-06-11 09:51:40 +00:00
fix: add display: 'swap' for fonts (#21)
This commit is contained in:
@@ -11,6 +11,7 @@ import { ThemeProvider } from "@/components/theme-provider"
|
||||
const fontSans = FontSans({
|
||||
subsets: ["latin"],
|
||||
variable: "--font-sans",
|
||||
display: 'swap',
|
||||
})
|
||||
|
||||
interface RootLayoutProps {
|
||||
|
||||
@@ -8,11 +8,13 @@ import {
|
||||
const fontSans = FontSans({
|
||||
subsets: ["latin"],
|
||||
variable: "--font-sans",
|
||||
display: 'swap',
|
||||
})
|
||||
|
||||
const fontMono = FontMono({
|
||||
subsets: ["latin"],
|
||||
variable: "--font-mono",
|
||||
display: 'swap',
|
||||
})
|
||||
|
||||
export function Fonts() {
|
||||
|
||||
@@ -7,6 +7,7 @@ import "@/styles/globals.css"
|
||||
const fontSans = FontSans({
|
||||
subsets: ["latin"],
|
||||
variable: "--font-sans",
|
||||
display: 'swap',
|
||||
})
|
||||
|
||||
export default function App({ Component, pageProps }: AppProps) {
|
||||
|
||||
Reference in New Issue
Block a user