feat : use same size as admin for nav bar

This commit is contained in:
2026-10-08 22:34:49 +07:00 Unverified
parent 065099b2b1
commit 36063fc214
6 changed files with 66 additions and 62 deletions
+9 -9
View File
@@ -10,10 +10,10 @@ import { navigationIconPath } from "@/lib/navigation";
import { cn } from "@/lib/utils";
const sections = [
{ slug: "weapon", label: "อาวุธ" },
{ slug: "artifact", label: "อาร์ติแฟกต์และค่าสถานะ" },
{ slug: "constellations", label: "กลุ่มดาว" },
{ slug: "team", label: "คำนวณทีม" },
{ slug: "weapon", label: "Weapons" },
{ slug: "artifact", label: "Artifacts & Stats" },
{ slug: "constellations", label: "Constellations" },
{ slug: "team", label: "Team Calc" },
] as const;
export function GuideSectionNav({
@@ -36,7 +36,7 @@ export function GuideSectionNav({
};
return (
<ScrollableNav
ariaLabel="เมนูแก้ไข Guide"
ariaLabel="Guide editor navigation"
activeKey={current}
className="w-full rounded-xl border bg-card p-2"
>
@@ -46,12 +46,12 @@ export function GuideSectionNav({
onClick={confirmNavigation}
aria-current={current === "overview" ? "page" : undefined}
className={cn(
"flex min-h-8 shrink-0 items-center gap-2 rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
"flex min-h-8 shrink-0 items-center gap-2 whitespace-nowrap rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
current === "overview" ? "bg-muted text-foreground" : "text-muted-foreground hover:bg-muted hover:text-foreground",
)}
>
<Image src={navigationIconPath("overview")!} alt="" width={20} height={20} className="size-5 object-contain" />
ภาพรวม
Overview
</Link>
{sections.map((section) => {
const iconPath = navigationIconPath(section.slug);
@@ -63,7 +63,7 @@ export function GuideSectionNav({
onClick={confirmNavigation}
aria-current={current === section.slug ? "page" : undefined}
className={cn(
"flex min-h-8 shrink-0 items-center gap-2 rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
"flex min-h-8 shrink-0 items-center gap-2 whitespace-nowrap rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
current === section.slug ? "bg-muted text-foreground" : "text-muted-foreground hover:bg-muted hover:text-foreground",
)}
>
@@ -80,7 +80,7 @@ export function GuideSectionNav({
onClick={confirmNavigation}
aria-current={current === extra.slug ? "page" : undefined}
className={cn(
"flex min-h-8 shrink-0 items-center gap-2 rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
"flex min-h-8 shrink-0 items-center gap-2 whitespace-nowrap rounded-md px-3 text-sm outline-none focus-visible:ring-2 focus-visible:ring-ring",
current === extra.slug ? "bg-muted text-foreground" : "text-muted-foreground hover:bg-muted hover:text-foreground",
)}
>