mirror of
https://github.com/docmost/docmost.git
synced 2026-05-07 06:23:06 +08:00
Migrate to Mantine UI framework
This commit is contained in:
+20
-22
@@ -1,12 +1,9 @@
|
||||
import './globals.css'
|
||||
import type { Metadata } from 'next'
|
||||
import { Inter } from 'next/font/google'
|
||||
import { cn } from "@/lib/utils";
|
||||
import { ThemeProvider } from "@/components/providers/theme-provider";
|
||||
import { TanstackProvider } from "@/components/providers/tanstack-provider";
|
||||
import CustomToaster from "@/components/ui/custom-toaster";
|
||||
|
||||
const inter = Inter({ subsets: ['latin'] })
|
||||
import '@mantine/core/styles.css';
|
||||
import type { Metadata } from 'next';
|
||||
import { TanstackProvider } from '@/components/providers/tanstack-provider';
|
||||
import CustomToaster from '@/components/ui/custom-toaster';
|
||||
import { theme } from '@/app/theme';
|
||||
import { ColorSchemeScript, MantineProvider } from '@mantine/core';
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: 'Create Next App',
|
||||
@@ -16,25 +13,26 @@ export const metadata: Metadata = {
|
||||
initialScale: 1,
|
||||
maximumScale: 1,
|
||||
},
|
||||
}
|
||||
};
|
||||
|
||||
export default function RootLayout({
|
||||
children,
|
||||
}: {
|
||||
children: React.ReactNode
|
||||
children: React.ReactNode;
|
||||
}) {
|
||||
|
||||
return (
|
||||
<html lang="en" suppressHydrationWarning>
|
||||
<body className={cn("min-h-screen bg-background antialiased", inter.className)}>
|
||||
<ThemeProvider attribute="class" defaultTheme="system" enableSystem>
|
||||
<TanstackProvider>
|
||||
{children}
|
||||
<CustomToaster />
|
||||
</TanstackProvider>
|
||||
</ThemeProvider>
|
||||
</body>
|
||||
<head>
|
||||
<ColorSchemeScript />
|
||||
</head>
|
||||
<body>
|
||||
<MantineProvider theme={theme}>
|
||||
<TanstackProvider>
|
||||
{children}
|
||||
<CustomToaster />
|
||||
</TanstackProvider>
|
||||
</MantineProvider>
|
||||
</body>
|
||||
</html>
|
||||
)
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user