import { Camera, Plus } from "lucide-react"; import { NAV_ITEMS } from "./navItems"; import type { AppView } from "../types"; type TopBarProps = { activeView: AppView; busyAction: string | null; onAdd: () => void; onScan: () => void; className?: string; }; export function TopBar({ activeView, busyAction, onAdd, onScan, className = "" }: TopBarProps) { const activeItem = NAV_ITEMS.find((item) => item.id === activeView) ?? NAV_ITEMS[0]; const ActiveIcon = activeItem.icon; const title = activeItem.label; const subtitle = new Intl.DateTimeFormat("en-GB", { weekday: "long", day: "numeric", month: "long", }).format(new Date()); return (

{subtitle}

{title}

); }