diff --git a/src/components/PostCard/PostCardBasicMissing.tsx b/src/components/PostCard/PostCardBasicMissing.tsx index 0d04cdab..ee21ec84 100644 --- a/src/components/PostCard/PostCardBasicMissing.tsx +++ b/src/components/PostCard/PostCardBasicMissing.tsx @@ -11,7 +11,7 @@ interface PostCardProps { title?: string; subtitle?: string; date?: string; - badgeType?: string; + badgeType?: 'Emergency' | 'New' | 'Default'; cardType: 'Basic' | 'Missing'; size?: Size; profileImg?: string | null; diff --git a/src/pages/notice/component/NoticeContent.tsx b/src/pages/notice/component/NoticeContent.tsx index 373af226..ac74cef0 100644 --- a/src/pages/notice/component/NoticeContent.tsx +++ b/src/pages/notice/component/NoticeContent.tsx @@ -90,10 +90,10 @@ export function NoticeContent({ initPosts, isLoading }: NoticeContentProps) { function RenderCard({ post, size }: RenderCardProps) { const formattedDate = post.date ? formatYYYYMMDD(post.date) : ''; - let status; - if (status === '긴급공지') { + let status: 'Emergency' | 'New' | 'Default'; + if (post.status === '긴급공지') { status = 'Emergency'; - } else if (status === '새로운') { + } else if (post.status === '새로운') { status = 'New'; } else { status = 'Default';