import type { Children } from "@kitajs/html"; import config from "../config.ts"; import { displayName } from "../lib/users.ts"; import type { SessionUser } from "../middleware/session.ts"; import { Avatar } from "./Avatar.tsx"; interface LayoutProps { user: SessionUser | null; title?: string; children: Children; } export function Layout({ user, title, children }: LayoutProps) { const pageTitle = title ? `${title} — Hearthforge` : "Hearthforge"; return ( {pageTitle}
{children}
); }