import Link from "next/link"; import ManualSearch from "@/components/ManualSearch"; import ManualToc from "@/components/ManualToc"; import type { ManualBase } from "@/components/ManualView"; import { searchIndex, tree, type Heading } from "@/lib/manual"; /* The manual's frame, the same on the website and inside the app: the search box and the section * tree on the left, the article, and the on-this-page rail on the right. The tree is plain *
, so it opens and closes with no script; the section being read starts open. */ export const GUIDES: [string, string][] = [ ["How to run a uniform stocktake", "/guides/uniform-stocktake"], ["Where the uniforms actually go", "/guides/uniform-loss"], ["Charging uniforms to the right cost centre", "/guides/cost-centre-reporting"], ["Entitlements and manager approvals", "/guides/manager-approvals"], ]; export default function ManualShell({ base, current, headings, children }: { base: ManualBase; current?: { section: string; slug: string }; headings?: Heading[]; children: React.ReactNode; }) { const sections = tree(); const app = base === "/app/help"; return (
{children}
{current && headings && }
); }