feat: bootstrap foundation application

This commit is contained in:
2026-04-29 00:26:58 -04:00
parent 8e6646499f
commit 4a72e1e030
53 changed files with 4443 additions and 0 deletions

31
apps/web/src/app.tsx Normal file
View File

@@ -0,0 +1,31 @@
export function App() {
return (
<main class="shell">
<section class="hero">
<p class="eyebrow">MD Hub Secure</p>
<h1>Preact foundation for future hydrated features</h1>
<p class="lede">
The Go server is the source of truth for rendering document pages.
This app is the scaffold for search, sync, comments, and design
tooling that will hydrate over time.
</p>
</section>
<section class="grid">
<article class="card">
<h2>Current scope</h2>
<p>
Routing, bundling, TypeScript, and styles are in place for later
feature islands.
</p>
</article>
<article class="card">
<h2>Next milestone</h2>
<p>
Sync protocol UI, offline cache status, and browser-side search.
</p>
</article>
</section>
</main>
);
}

11
apps/web/src/main.tsx Normal file
View File

@@ -0,0 +1,11 @@
import { render } from "preact";
import { LocationProvider, Route, Router } from "preact-iso";
import { App } from "./app";
import "./styles.css";
render(
<LocationProvider>
<Router>{[<Route path="/*" component={App} />]}</Router>
</LocationProvider>,
document.getElementById("app")!,
);

91
apps/web/src/styles.css Normal file
View File

@@ -0,0 +1,91 @@
:root {
color-scheme: light;
--bg: #f4f1ea;
--surface: rgba(255, 255, 255, 0.78);
--surface-strong: #ffffff;
--text: #202227;
--muted: #5f6471;
--accent: #1947e5;
--accent-2: #0f8a6c;
--border: rgba(32, 34, 39, 0.12);
--shadow: 0 20px 60px rgba(25, 71, 229, 0.12);
font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
}
* {
box-sizing: border-box;
}
body {
margin: 0;
min-height: 100vh;
color: var(--text);
background:
radial-gradient(
circle at top left,
rgba(25, 71, 229, 0.16),
transparent 36%
),
radial-gradient(
circle at bottom right,
rgba(15, 138, 108, 0.18),
transparent 30%
),
linear-gradient(180deg, #faf7f2 0%, var(--bg) 100%);
}
.shell {
max-width: 960px;
margin: 0 auto;
padding: 4rem 1.5rem 5rem;
}
.hero {
padding: 2rem;
border: 1px solid var(--border);
border-radius: 28px;
background: var(--surface);
backdrop-filter: blur(10px);
box-shadow: var(--shadow);
}
.eyebrow {
margin: 0 0 0.75rem;
color: var(--accent);
font-family: ui-monospace, SFMono-Regular, monospace;
font-size: 0.82rem;
letter-spacing: 0.18em;
text-transform: uppercase;
}
.hero h1 {
margin: 0;
font-size: clamp(2.25rem, 5vw, 4rem);
line-height: 0.95;
}
.lede {
max-width: 42rem;
margin: 1.5rem 0 0;
font-size: 1.1rem;
line-height: 1.7;
color: var(--muted);
}
.grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
gap: 1rem;
margin-top: 1.5rem;
}
.card {
padding: 1.25rem;
border: 1px solid var(--border);
border-radius: 20px;
background: var(--surface-strong);
}
.card h2 {
margin-top: 0;
}