feat: 사이드바 메뉴 클릭 핸들러 작업

This commit is contained in:
2025-03-31 10:40:00 +09:00
parent 84519658c1
commit 7860345e89
3 changed files with 47 additions and 7 deletions
+9 -2
View File
@@ -1,11 +1,18 @@
"use client";
import { usePathname, useRouter } from "next/navigation";
import { BaseLayout } from "@common/components/ui";
export default function WithBaseLayout({
children,
}: {
children: React.ReactNode;
}) {
return <BaseLayout>{children}</BaseLayout>;
const router = useRouter();
const pathname = usePathname();
return (
<BaseLayout currentPath={pathname ?? ""} routeHandler={router.push}>
{children}
</BaseLayout>
);
}