46 lines
1.1 KiB
JavaScript
46 lines
1.1 KiB
JavaScript
|
|
// src/app/layout.jsx
|
|
import { Geist, Geist_Mono } from "next/font/google"
|
|
import "@/app/globals.css";
|
|
import Sidebar from "@/components/Sidebar"
|
|
import styled from 'styled-components'
|
|
|
|
|
|
const geistSans = Geist({
|
|
variable: "--font-geist-sans",
|
|
subsets: ["latin"],
|
|
})
|
|
const geistMono = Geist_Mono({
|
|
variable: "--font-geist-mono",
|
|
subsets: ["latin"],
|
|
})
|
|
|
|
export const metadata = {
|
|
title: "Create Next App",
|
|
description: "Generated by create next app",
|
|
}
|
|
|
|
|
|
|
|
export default function RootLayout({ children }) {
|
|
return (
|
|
<html lang="en" className="h-full">
|
|
<body
|
|
className={`
|
|
${geistSans.variable} ${geistMono.variable}
|
|
flex h-full
|
|
`}
|
|
style={{flexDirection: 'row',display: 'flex'}}
|
|
>
|
|
{/* Sidebar слева */}
|
|
<Sidebar />
|
|
|
|
{/* Основной контент справа */}
|
|
<main style={{display:'flex',alignItems: 'center',justifyContent: 'center',width:'auto',flex:'1'}} className="overflow-auto p-6">
|
|
{children}
|
|
</main>
|
|
</body>
|
|
</html>
|
|
)
|
|
}
|