From e04f0d43896944704dec382b3e8fd32077ecfe18 Mon Sep 17 00:00:00 2001 From: heeyongKim <166043860+heeeeyong@users.noreply.github.com> Date: Thu, 21 Aug 2025 14:38:06 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=EB=8C=93=EA=B8=80=20=EC=9E=91?= =?UTF-8?q?=EC=84=B1=20=EC=8B=9C,=20=EA=B0=AF=EC=88=98=20=EB=B0=98?= =?UTF-8?q?=EC=98=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/feed/FeedDetailPage.tsx | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/pages/feed/FeedDetailPage.tsx b/src/pages/feed/FeedDetailPage.tsx index 5e46e5cc..6e336849 100644 --- a/src/pages/feed/FeedDetailPage.tsx +++ b/src/pages/feed/FeedDetailPage.tsx @@ -33,10 +33,22 @@ const FeedDetailPage = () => { try { const commentsResponse = await getComments(Number(feedId), { postType: 'FEED' }); setCommentList(commentsResponse.data.commentList); + + // 피드 데이터의 댓글 수를 실제 댓글 목록 길이로 업데이트 + if (feedData) { + setFeedData(prev => + prev + ? { + ...prev, + commentCount: commentsResponse.data.commentList.length, + } + : null, + ); + } } catch (err) { console.error('댓글 목록 다시 로드 실패:', err); } - }, [feedId]); + }, [feedId, feedData]); // 페이지를 떠날 때 답글 상태 초기화 useEffect(() => { From 57b4c910843d1d0790056bfc91391818b10b7cb7 Mon Sep 17 00:00:00 2001 From: heeyongKim <166043860+heeeeyong@users.noreply.github.com> Date: Thu, 21 Aug 2025 16:57:33 +0900 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20=EC=A7=84=ED=96=89=EC=A4=91=EC=9D=B8?= =?UTF-8?q?=20=EB=AA=A8=EC=9E=84=EB=B0=A9=20=EC=A0=9C=EB=AA=A9=20=EB=84=98?= =?UTF-8?q?=EC=B9=98=EB=8A=94=ED=98=84=EC=83=81=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/group/GroupCard.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/components/group/GroupCard.tsx b/src/components/group/GroupCard.tsx index 28c4e433..62d59fcf 100644 --- a/src/components/group/GroupCard.tsx +++ b/src/components/group/GroupCard.tsx @@ -110,6 +110,7 @@ const Info = styled.div` flex-direction: column; justify-content: space-between; flex: 1; + min-width: 0; /* flex 아이템이 부모 너비를 넘지 않도록 */ `; const Title = styled.h3<{ isRecommend: boolean }>` @@ -123,6 +124,7 @@ const Title = styled.h3<{ isRecommend: boolean }>` overflow: hidden; text-overflow: ellipsis; white-space: nowrap; + width: 100%; /* 부모 컨테이너의 전체 너비 사용 */ `; const Bottom = styled.div`