From 434880d2c774e4922f06bbd1f547a3da60b0fe50 Mon Sep 17 00:00:00 2001 From: ywlee Date: Thu, 19 Oct 2023 22:28:08 +0900 Subject: [PATCH] =?UTF-8?q?[fix]=20=EB=84=A4=EB=B9=84=EA=B2=8C=EC=9D=B4?= =?UTF-8?q?=EC=85=98=20=EC=95=84=EC=9D=B4=EC=BD=98=20=EC=9E=98=20=EB=82=98?= =?UTF-8?q?=EC=98=A4=EA=B2=8C=20=EC=88=98=EC=A0=95=20=EB=B0=8F=20=EB=94=94?= =?UTF-8?q?=EC=9E=90=EC=9D=B8=20=EB=B0=98=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/Nav/Nav.tsx | 8 ++++---- pages/index.tsx | 2 +- pages/liked/index.tsx | 3 +-- pages/userInfo/index.tsx | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/components/Nav/Nav.tsx b/components/Nav/Nav.tsx index c868403..ff34006 100644 --- a/components/Nav/Nav.tsx +++ b/components/Nav/Nav.tsx @@ -31,12 +31,10 @@ const menus = [ ]; export default function Nav({ initMenu }: NavProps) { - const [activeMenu, setActiveMenu] = useState(initMenu || 0); // 초기 활성 메뉴 인덱스 const [hoverMenu, setHoverMenu] = useState(-1); // 초기화 const router = useRouter(); const handleNavClicked = (index: number) => { - setActiveMenu(index); router.push(menus[index].router); }; @@ -55,12 +53,14 @@ export default function Nav({ initMenu }: NavProps) { >
-
{menu.name}
+
+ {menu.name} +
); })} diff --git a/pages/index.tsx b/pages/index.tsx index 4a59dec..e4bb520 100644 --- a/pages/index.tsx +++ b/pages/index.tsx @@ -194,7 +194,7 @@ function Home() { ))}
-
+
-
+
-
diff --git a/pages/userInfo/index.tsx b/pages/userInfo/index.tsx index 0e272aa..6069ac1 100644 --- a/pages/userInfo/index.tsx +++ b/pages/userInfo/index.tsx @@ -15,7 +15,7 @@ export default function UserProfile({ imgSrc }: UserProfileProps) { return ( <> -
+