diff --git a/src/app/(root)/[teamid]/_domain/components/Kanban/KanbanItem.tsx b/src/app/(root)/[teamid]/_domain/components/Kanban/KanbanItem.tsx
index b34c9a8..01a9809 100644
--- a/src/app/(root)/[teamid]/_domain/components/Kanban/KanbanItem.tsx
+++ b/src/app/(root)/[teamid]/_domain/components/Kanban/KanbanItem.tsx
@@ -19,7 +19,6 @@ interface KanbanItemProps {
function KanbanItem({
task,
onItemCheckedChange,
- onCardClick,
onDeleteTask,
onEditTask,
onUpdateTask,
diff --git a/src/app/(root)/[teamid]/_domain/components/Team/TeamNavClient.tsx b/src/app/(root)/[teamid]/_domain/components/Team/TeamNavClient.tsx
index 6ed8eb0..96cf5eb 100644
--- a/src/app/(root)/[teamid]/_domain/components/Team/TeamNavClient.tsx
+++ b/src/app/(root)/[teamid]/_domain/components/Team/TeamNavClient.tsx
@@ -1,6 +1,7 @@
'use client';
import { useState } from 'react';
+import { useRouter } from 'next/navigation';
import { MobileHeader, MobileDrawer } from '@/components/sidebar';
import ProfileImage from '@/components/profile-img/ProfileImage';
@@ -12,15 +13,17 @@ import styles from './TeamNavClient.module.css';
export default function TeamNavClient() {
const [isDrawerOpen, setIsDrawerOpen] = useState(false);
const { data: currentUser } = useCurrentUserQuery();
+ const router = useRouter();
const openDrawer = () => setIsDrawerOpen(true);
const closeDrawer = () => setIsDrawerOpen(false);
+ const handleProfileClick = () => router.push('/mypage');
return (
<>
{/* 태블릿 헤더 */}
-
+
{/* 모바일 헤더 */}
@@ -31,6 +34,7 @@ export default function TeamNavClient() {
}
onMenuClick={openDrawer}
+ onProfileClick={handleProfileClick}
/>
diff --git a/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.module.css b/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.module.css
index 808d86d..b9c1a73 100644
--- a/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.module.css
+++ b/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.module.css
@@ -27,4 +27,8 @@
.profileArea {
display: flex;
align-items: center;
+ background: none;
+ border: none;
+ padding: 0;
+ cursor: pointer;
}
diff --git a/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.tsx b/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.tsx
index 03d540a..f2d92d7 100644
--- a/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.tsx
+++ b/src/app/(root)/[teamid]/_domain/components/Team/TeamTabletHeader.tsx
@@ -10,9 +10,10 @@ import styles from './TeamTabletHeader.module.css';
type Props = {
onMenuClick?: () => void;
+ onProfileClick?: () => void;
};
-export default function TeamTabletHeader({ onMenuClick }: Props) {
+export default function TeamTabletHeader({ onMenuClick, onProfileClick }: Props) {
const { data: currentUser } = useCurrentUserQuery();
return (
@@ -28,9 +29,14 @@ export default function TeamTabletHeader({ onMenuClick }: Props) {
-
+
);
}
diff --git a/src/app/(root)/addteam/_domain/components/AddTeamSidebarWrapper.tsx b/src/app/(root)/addteam/_domain/components/AddTeamSidebarWrapper.tsx
index ffa80de..35227aa 100644
--- a/src/app/(root)/addteam/_domain/components/AddTeamSidebarWrapper.tsx
+++ b/src/app/(root)/addteam/_domain/components/AddTeamSidebarWrapper.tsx
@@ -2,9 +2,22 @@
import { useRouter } from 'next/navigation';
import { Sidebar } from '@/components/sidebar';
+import ProfileImage from '@/components/profile-img/ProfileImage';
+import { useCurrentUserQuery } from '@/shared/queries/user/useCurrentUserQuery';
export default function AddTeamSidebarWrapper() {
+ const { data: currentUser } = useCurrentUserQuery();
const router = useRouter();
- return router.push('/mypage')} />;
+ return (
+
+ }
+ profileName={currentUser?.nickname}
+ profileTeam={currentUser?.email}
+ onProfileClick={() => router.push('/mypage')}
+ />
+ );
}
diff --git a/src/app/(root)/layout.tsx b/src/app/(root)/layout.tsx
index 97d1595..36a3238 100644
--- a/src/app/(root)/layout.tsx
+++ b/src/app/(root)/layout.tsx
@@ -32,6 +32,10 @@ export default function RootLayout({ children }: { children: React.ReactNode })
const isLanding = pathname === '/';
const firstGroup = user?.memberships?.[0]?.group;
+ // [teamid] 페이지는 자체 모바일 헤더(TeamNavClient)를 사용하므로 root layout의 MobileHeader를 숨김
+ const knownPaths = ['/', '/addteam', '/boards', '/mypage', '/history', '/list'];
+ const isTeamIdPage = !knownPaths.some((p) => pathname === p || pathname.startsWith(p + '/'));
+
const handleProfileClick = () => {
if (isLoggedIn) {
router.push('/mypage');
@@ -139,33 +143,35 @@ export default function RootLayout({ children }: { children: React.ReactNode })
: undefined
}
/>
- router.push('/addteam')}
- profileImage={
- user?.image ? (
-
+
+ ) : undefined
+ }
+ onMenuClick={() => setIsDrawerOpen(true)}
+ onProfileClick={handleProfileClick}
+ />
+ setIsDrawerOpen(false)}>
+ }
+ label="자유게시판"
+ isActive
+ href="/boards"
+ onClick={() => setIsDrawerOpen(false)}
/>
- ) : undefined
- }
- onMenuClick={() => setIsDrawerOpen(true)}
- onProfileClick={handleProfileClick}
- onLogout={handleLogout}
- />
- setIsDrawerOpen(false)}>
- }
- label="자유게시판"
- isActive
- href="/boards"
- onClick={() => setIsDrawerOpen(false)}
- />
-
+
+ >
+ )}
{children}
);