Scaffold basic page layout and site generation
Set up the basic layout of the site and greybox its content based on statically generated pages. Content pages uses general base layouts defined centrally to avoid duplicating code.
This commit is contained in:
parent
51b458103b
commit
8fb809fa95
10 changed files with 268 additions and 21 deletions
32
content/updates.tsx
Normal file
32
content/updates.tsx
Normal file
|
@ -0,0 +1,32 @@
|
|||
import { BasePage } from "./bases.js";
|
||||
import type { Page } from "./types.js";
|
||||
|
||||
export const updates: Page[] = [
|
||||
{
|
||||
published: "2025-xx-xx",
|
||||
title: "Website Launch",
|
||||
ref: "updates/site-launch.html",
|
||||
}
|
||||
].map(page => ({
|
||||
title: page.title,
|
||||
ref: page.ref,
|
||||
content: <BasePage title={page.title}>
|
||||
<h1>{page.title}</h1>
|
||||
<p>Published: {page.published}</p>
|
||||
<p>Placeholder content</p>
|
||||
</BasePage>
|
||||
}));
|
||||
|
||||
const title = "Website Updates";
|
||||
export const updatesIndex: Page = {
|
||||
title,
|
||||
ref: "updates.html",
|
||||
content: <BasePage title={title}>
|
||||
<main>
|
||||
<h1>{title}</h1>
|
||||
<ul>
|
||||
{ updates.map(update => <li><a href={"./" + update.ref}>{update.title}</a></li>)}
|
||||
</ul>
|
||||
</main>
|
||||
</BasePage>
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue