diff --git a/src/api/alerts.ts b/src/api/alerts.ts index d6b34fb..2e39ba5 100644 --- a/src/api/alerts.ts +++ b/src/api/alerts.ts @@ -1,4 +1,3 @@ -// src/api/alerts.ts import axios from '@/lib/axios'; import type { ApiResponse, PaginatedResponse } from '@/types/api'; import type { Notice } from '@/types/notice'; diff --git a/src/components/layout/header/nav.tsx b/src/components/layout/header/nav.tsx index 772c815..d67102d 100644 --- a/src/components/layout/header/nav.tsx +++ b/src/components/layout/header/nav.tsx @@ -52,10 +52,10 @@ const Nav = () => { }); }; - // ✅ role이 초기 undefined일 수 있어 방어 + // role이 초기 undefined일 수 있어 방어 const currentRole: UserRole = (role ?? 'guest') as UserRole; - // ✅ 아이콘은 "패널 열림 상태"로만 토글 + // 아이콘은 "패널 열림 상태"로만 토글 const bellIcon: 'notificationOn' | 'notificationOff' = open ? 'notificationOn' : 'notificationOff'; @@ -69,17 +69,18 @@ const Nav = () => { ))} {isLogin && ( - <> - - + + )} + {role === 'employee' && ( +
{/* 알림 버튼: 토글 */}
)} ); diff --git a/src/components/ui/dropdown/dropdown.stories.tsx b/src/components/ui/dropdown/dropdown.stories.tsx index a70f527..9bf71cf 100644 --- a/src/components/ui/dropdown/dropdown.stories.tsx +++ b/src/components/ui/dropdown/dropdown.stories.tsx @@ -1,4 +1,3 @@ -// src/components/ui/dropdown/dropdown.stories.tsx import { ADDRESS_CODE, CATEGORY_CODE, SORT_CODE } from '@/constants/dropdown'; import type { Meta, StoryObj } from '@storybook/nextjs'; import { useState } from 'react'; diff --git a/src/components/ui/input/input.stories.tsx b/src/components/ui/input/input.stories.tsx index c6b68c4..13aad88 100644 --- a/src/components/ui/input/input.stories.tsx +++ b/src/components/ui/input/input.stories.tsx @@ -1,4 +1,3 @@ -// src/components/ui/input/input.stories.tsx import Button from '@/components/ui/button/button'; import type { Meta, StoryObj } from '@storybook/nextjs'; import { useState } from 'react'; diff --git a/src/components/ui/modal/notification/Notification.tsx b/src/components/ui/modal/notification/Notification.tsx index 0930dfa..78e0674 100644 --- a/src/components/ui/modal/notification/Notification.tsx +++ b/src/components/ui/modal/notification/Notification.tsx @@ -5,6 +5,10 @@ import { Shop } from '@/types/shop'; import { useState } from 'react'; import NotificationMessage from './NotificationMessage'; +const NOTI_STYLE = { + controlled: '', + uncontrolled: '', +}; export interface Alert { id: string; createdAt: string; @@ -49,28 +53,30 @@ export default function Notification({ alerts, onRead, isOpen, onClose }: Notifi )}
-
-
알림 {notificationCount}개
-
- -
+
+
알림 {notificationCount}개
+
-
{SORTED_ALERTS.length === 0 ? (

알림이 없습니다.

) : ( -
+
{SORTED_ALERTS.map(alert => ( ))} diff --git a/src/context/userApplicationsProvider.tsx b/src/context/userApplicationsProvider.tsx index 2d0dad1..a927a83 100644 --- a/src/context/userApplicationsProvider.tsx +++ b/src/context/userApplicationsProvider.tsx @@ -1,4 +1,4 @@ -// context/UserApplicationsProvider.tsx + import { getAllUserApplications, postApplication, putApplication } from '@/api/applications'; import useAuth from '@/hooks/useAuth'; import { ApiResponse } from '@/types/api';