/** * @file components/friends/FriendsHeader.tsx * @description Renders a responsive sub-header with tabs for navigating between all friends, pending requests, and adding a friend. */ "use client"; import { Users, Clock } from "lucide-react"; import { ActionButton } from "../ui/ActionButton"; /** * Available tab types for the friends navigation view. * * @type {TabType} */ export type TabType = "all" | "pending" | "add"; /** * Properties for the FriendsHeader component. * * @interface FriendsHeaderProps * @property {TabType} activeTab - The currently active friends tab identifier. * @property {(tab: TabType) => void} setActiveTab - Callback function to update the active friends tab. * @property {number} [allCount=0] - The total number of friends. * @property {number} [pendingCount=0] - The number of pending friend requests. */ interface FriendsHeaderProps { activeTab: TabType; setActiveTab: (tab: TabType) => void; allCount?: number; pendingCount?: number; } /** * Renders a responsive sub-header with tabs for navigating between all friends, pending requests, and adding a friend. * * @param {FriendsHeaderProps} props - The component props. * @param {TabType} props.activeTab - The currently active tab. * @param {(tab: TabType) => void} props.setActiveTab - Function to change the active tab. * @param {number} [props.allCount=0] - Total count of all friends. * @param {number} [props.pendingCount=0] - Count of pending friend requests. * @returns {JSX.Element} The rendered friends navigation header component. */ export function FriendsHeader({ activeTab, setActiveTab, allCount = 0, pendingCount = 0, }: FriendsHeaderProps) { return ( ); }