import { Link, useRouterState } from '@tanstack/react-router' import { cn } from '@/lib/utils' const NAV_ITEMS = [ { to: '/', label: 'Home', icon: 'home', matchPrefix: '/', exact: true }, { to: '/toeic', label: 'Luyện đề', icon: 'assignment', matchPrefix: '/toeic', exact: false }, { to: '/writing', label: 'Writing', icon: 'edit_note', matchPrefix: '/writing', exact: false }, { to: '/vocab', label: 'Từ vựng', icon: 'menu_book', matchPrefix: '/vocab', exact: false }, ] function isActive(pathname: string, prefix: string, exact: boolean) { return exact ? pathname === prefix : pathname.startsWith(prefix) } export function MobileNav() { const { location } = useRouterState() const pathname = location.pathname return ( ) }