Added catalog generation, need to bug fix
This commit is contained in:
+18
-16
@@ -1,8 +1,14 @@
|
||||
import { FreshContext } from "$fresh/server.ts";
|
||||
import { Partial } from "$fresh/runtime.ts";
|
||||
import { State } from "./_middleware.ts";
|
||||
import Header from "./(_components)/Header.tsx";
|
||||
import Footer from "./(_components)/Footer.tsx";
|
||||
|
||||
|
||||
export default async function App(request: Request, context: FreshContext) {
|
||||
// deno-lint-ignore require-await
|
||||
export default async function App(
|
||||
_request: Request,
|
||||
context: FreshContext<State>,
|
||||
) {
|
||||
const link = context.state.isAuthenticated ? "out" : "in";
|
||||
|
||||
return (
|
||||
@@ -11,23 +17,19 @@ export default async function App(request: Request, context: FreshContext) {
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>PolyMPR</title>
|
||||
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&display=swap" />
|
||||
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@24,400,0,0&icon_names=school" />
|
||||
<link rel="stylesheet" href="/styles/main.css" />
|
||||
</head>
|
||||
<body f-client-nav>
|
||||
<header>
|
||||
<h1>PolyMPR</h1>
|
||||
<nav>
|
||||
<a href="/modules" f-partial="/partials/modules">Modules</a>
|
||||
<a href={`/log${link}`} f-client-nav={false}>Log {link}</a>
|
||||
</nav>
|
||||
</header>
|
||||
<Partial name="body">
|
||||
<context.Component />
|
||||
</Partial>
|
||||
<footer>
|
||||
<p>© 2025 PolyMPR - <a href="/about" f-partial="/partials/about">About</a></p>
|
||||
</footer>
|
||||
<Header link={link} />
|
||||
<section>
|
||||
<Partial name="body">
|
||||
<context.Component />
|
||||
</Partial>
|
||||
</section>
|
||||
<Footer />
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user