feat: cron done, admin unfinished

This commit is contained in:
2025-05-31 06:02:48 -04:00
parent b8ce9ded76
commit a91469257b
8 changed files with 81 additions and 11 deletions
+12
View File
@@ -9,6 +9,9 @@ import { useState, useEffect } from "react";
import ReactMarkdown from "react-markdown";
import { BlogViewer } from "./utils/BlogViewer";
import { BlogList } from "./utils/BlogList";
import { RequireAdmin } from "./utils/RouteGuard";
import { AdminPage } from "./utils/AdminPage";
import Unauthorized from "./utils/UnauthorizedPage";
function App() {
const [darkMode, setDarkMode] = useState(true);
@@ -25,6 +28,15 @@ function App() {
<Route path="/blog/:slug" element={<BlogViewer />} />
<Route path="/about" element={<About />} />
<Route path="/contact" element={<Contact />} />
<Route
path="/admin"
element={
<RequireAdmin>
<AdminPage />
</RequireAdmin>
}
/>
<Route path="/unauthorized" element={<Unauthorized />} />
</Routes>
</div>
</div>