'use client'; import React from 'react'; import { Box } from '@/ui/Box'; import { Stack } from '@/ui/Stack'; import { Link } from '@/ui/Link'; interface Tab { label: string; href: string; exact?: boolean; } interface LeagueNavTabsProps { tabs: Tab[]; currentPathname: string; } export function LeagueNavTabs({ tabs, currentPathname }: LeagueNavTabsProps) { return ( {tabs.map((tab) => { const isActive = tab.exact ? currentPathname === tab.href : currentPathname.startsWith(tab.href); return ( {tab.label} {isActive && ( )} ); })} ); }