import { Network } from "lucide-react"; import Link from "next/link"; import { Avatar } from "@/components/ui/Avatar"; import { LINK_BUTTON_CLASS } from "@/components/ui/Button"; type MiniEmployee = { id: string; first_name: string; last_name: string; job_title: string; status?: string }; type OrganisationTabProps = { employeeId: string; manager: MiniEmployee | null; directReports: MiniEmployee[]; breadcrumb: string; }; export function OrganisationTab({ employeeId, manager, directReports, breadcrumb }: OrganisationTabProps) { return (

Organisationseinheit

{breadcrumb}

{/* ?focus= drives the same highlight/auto-expand path the org chart search already uses, so the person is unfolded and centred on arrival instead of the user hunting for them. */} Im Organigramm anzeigen

Führungskraft

{manager ? (
{manager.first_name} {manager.last_name}
{manager.job_title}
) : (

Keine Führungskraft (Geschäftsführung)

)}

Direkte Berichte ({directReports.length})

{directReports.length > 0 ? (
{directReports.map((r) => (
{r.first_name} {r.last_name}
{r.job_title}
))}
) : (

Keine direkten Berichte.

)}
); }