This commit is contained in:
zhu
2026-05-11 10:05:33 +08:00
parent bf6b44a950
commit 3d2dc708cc
19 changed files with 4164 additions and 3 deletions

View File

@@ -87,14 +87,16 @@ const NavTabs = () => {
const pathname = usePathname();
const tabs = [
{href: "/dashboard", label: "Dashboard", icon: LayoutGrid},
{href: "/dashboard/settings", label: "Settings", icon: SettingsIcon},
{href: "/dashboard/setting", label: "Settings", icon: SettingsIcon},
{href: "/dashboard/billing", label: "Billing", icon: CreditCard},
];
return (
<nav className="flex items-center gap-0.5" aria-label="Dashboard navigation">
{tabs.map(item => {
const Icon = item.icon;
const isActive = pathname == item.href;
const isActive = item.href === "/dashboard"
? pathname === item.href
: pathname === item.href || pathname.startsWith(`${item.href}/`);
return (
<Link