Branchwell

Jotley / website / src / app / components / LegalShell.tsx

1'use client';
2
3import './home/home.css';
4import type { ReactNode } from 'react';
5import SiteHeader from './SiteHeader';
6import SiteFooter from './SiteFooter';
7
8/**
9 * Page shell for long-form content pages (Terms, Privacy) on the redesigned
10 * (D3) site. Renders the shared sticky nav + footer and a centered article
11 * styled by the `.legal` typography system in home.css.
12 */
13export default function LegalShell({
14 title,
15 accent,
16 intro,
17 children,
18}: {
19 title: string;
20 accent?: string;
21 intro?: string;
22 children: ReactNode;
23}) {
24 return (
25 <div className="jt-home flex min-h-screen flex-col" data-testid="page-surface">
26 <SiteHeader />
27 <main className="page-main">
28 <div className="page-wrap">
29 <header className="page-hero">
30 <h1>
31 {accent ? (
32 <>
33 <span className="accent">{accent}</span> {title}
34 </>
35 ) : (
36 title
37 )}
38 </h1>
39 {intro ? <p className="sub">{intro}</p> : null}
40 </header>
41 <article className="legal">{children}</article>
42 </div>
43 </main>
44 <SiteFooter />
45 </div>
46 );
47}