refactor: 引入侧边栏重构全局双栏布局
This commit is contained in:
parent
f49f5f4a0d
commit
1da0d3c895
@ -1,5 +1,6 @@
|
||||
---
|
||||
import '../styles/global.css';
|
||||
import Sidebar from '../components/Sidebar.astro';
|
||||
const { title } = Astro.props;
|
||||
---
|
||||
<html lang="zh-CN">
|
||||
@ -8,7 +9,12 @@ const { title } = Astro.props;
|
||||
<title>{title}</title>
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.21/dist/katex.min.css">
|
||||
</head>
|
||||
<body class="bg-white dark:bg-gray-900 text-gray-900 dark:text-gray-100 min-h-screen p-8">
|
||||
<slot />
|
||||
<body class="bg-white dark:bg-[#0a0c10] text-gray-900 min-h-screen selection:bg-blue-200 dark:selection:bg-blue-900">
|
||||
<div class="flex max-w-[1440px] mx-auto">
|
||||
<Sidebar />
|
||||
<main class="flex-1 w-full min-w-0 p-8 md:p-12 overflow-x-hidden">
|
||||
<slot />
|
||||
</main>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user