"use client";
import Link from "next/link";
import { useSelectedLayoutSegment } from "next/navigation";
// Settings | Charts | Search aliases | Tags | Reports | Publish.
//
// A CLIENT component on purpose. Next 16 layouts are cached during navigation
// and DO NOT RERENDER — they cannot read the pathname and would not re-evaluate
// an active-tab check on a client-side move between two tabs.
// useSelectedLayoutSegment is the supported way to ask "which child segment is
// rendered"; it is null on the index page, which is the Settings tab.
export function SiteTabs({ siteId }: { siteId: string }) {
const segment = useSelectedLayoutSegment();
return (
);
}
function Tab({
href,
active,
label,
}: {
href: string;
active: boolean;
label: string;
}) {
return (
{label}
);
}