Files
temetro/frontend/lib/nav.ts
T
Khalid Abdi a4fc9a4fe9 Add command palette, footer clinic menu, patient Sheet, Analysis page, favicon
Several navigation/UX additions:

- Command palette (⌘K): components/command-palette.tsx wraps the app shell
  (mounted in app/(app)/layout.tsx) with a controlled COSS CommandDialog listing
  the nav pages; a "Quick nav" Kbd button in the sidebar footer also opens it.
  Installed @coss/kbd. Extracted the nav list into lib/nav.ts so the sidebar and
  palette share one source of truth.
- Clinic switcher moved from the sidebar body into the footer; its menu now
  opens a read-only "Clinic info" dialog and a "Create clinic" dialog instead of
  routing to /onboarding. Shared CreateClinicForm (components/clinic/) is reused
  by onboarding.
- Patients: clicking a row opens a right-side Sheet with the full record
  (components/patients/patient-detail-sheet.tsx) instead of navigating to the
  chat; PatientResult gained a vertical "column" layout for the Sheet.
- New Analysis page (app/(app)/analysis/) — a mock dashboard (revenue/profit,
  patient volume, appointments, operations) reusing Sparkline + Card + Badge.
- Logo: set metadata.icons so the new mark appears as the browser-tab favicon.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-04 19:40:11 +03:00

31 lines
821 B
TypeScript

import {
BarChart3,
type LucideIcon,
Plus,
Settings,
Users,
} from "lucide-react";
export type NavItem = {
id: string;
// i18n key resolved with t() at render time.
labelKey: string;
icon: LucideIcon;
link: string;
};
// Single source of truth for the primary navigation. Consumed by the sidebar
// (components/sidebar-02/app-sidebar.tsx) and the command palette
// (components/command-palette.tsx) so the two never drift.
export const navItems: NavItem[] = [
{ id: "new-chat", labelKey: "nav.newChat", icon: Plus, link: "/" },
{ id: "patients", labelKey: "nav.patients", icon: Users, link: "/patients" },
{
id: "analysis",
labelKey: "nav.analysis",
icon: BarChart3,
link: "/analysis",
},
{ id: "settings", labelKey: "nav.settings", icon: Settings, link: "/settings" },
];