/** * BureauNav — top navigation bar present on every bureau sub-page. * * Solves "I'm stuck on this page, there's no way back" UX. Shows: * - "← Home" (always → /) * - "Bureau" (always → /bureau) * - Breadcrumb trail of current page (passed via props) * - Locale toggle + auth pill on the right * * Visually harmonised with SiteHeader (single gold palette, no cyan); labels * localised. */ import Link from "next/link"; import { ArrowLeft } from "lucide-react"; import { AuthBar } from "./auth-bar"; import { LocaleToggle, type Locale } from "./locale-toggle"; import { MobileNav } from "./mobile-nav"; export interface Crumb { /** Display label. */ label: string; /** When omitted the crumb is rendered as the current page (no link). */ href?: string; } const COPY = { "pt-br": { home: "home", bureau: "casos", aria_home: "Voltar para a home", aria_bureau: "Listagem de casos" }, en: { home: "home", bureau: "case files", aria_home: "Back to home", aria_bureau: "Case file library" }, } as const; export function BureauNav({ crumbs, locale = "pt-br" }: { crumbs: Crumb[]; locale?: Locale }) { const t = COPY[locale]; // Same item list as the SiteHeader on the home — the mobile drawer carries // it so a reader on a case file can still jump to /sightings or /witnesses. const navItems = [ { href: "/sightings", label: locale === "en" ? "Sightings" : "Avistamentos" }, { href: "/witnesses", label: locale === "en" ? "Witnesses" : "Testemunhas" }, { href: "/objects", label: locale === "en" ? "Craft" : "Objetos" }, { href: "/locations", label: locale === "en" ? "Locations" : "Locais" }, { href: "/operations", label: locale === "en" ? "Programs" : "Programas" }, { href: "/bureau", label: locale === "en" ? "Case files" : "Casos" }, { href: "/search", label: locale === "en" ? "Search" : "Busca" }, ]; return ( ); }