Skip to content

Conversation

@wooktori
Copy link
Contributor

📝 변경 사항

  • 채팅이 20줄 이상 넘어갈 시, 전체 보기 버튼을 이용해 전체 채팅을 모달로 확인할 수 있습니다. (스크린샷 1)

  • input을 textarea로 수정해 줄바꿈을 허용하도록 했습니다.

  • 추가로, 기존 로직에서 스크롤이 맨 아래에 고정되지 않고 살짝 위에 올라와 가장 최근의 채팅이 잘리는 현상을 수정했습니다.

    • 아래 이미지처럼 마지막 이미지가 살짝 잘리는 현상 수정 (스크린샷 2)
  • 모바일 환경에서 줄바꿈이 적용되지 않아 추가 예정입니다.


🔗 관련 이슈

Closes #


🧪 테스트 방법

  • 수동 테스트 검증(로컬 환경)
  • 유닛 테스트 검증
  • 통합 테스트 검증

📸 스크린샷 (선택)

image image ---

📋 체크리스트

  • 관련 문서를 업데이트했습니다 (필요한 경우)
  • 테스트를 추가/수정했습니다 (필요한 경우)
  • Breaking change가 있다면 명시했습니다

💬 추가 코멘트


CodeRabbit Review는 자동으로 실행되지 않습니다.

Review를 실행하려면 comment에 아래와 같이 작성해주세요

@coderabbitai review

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 26, 2025

Important

Review skipped

Auto reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch hwanwook-fix/chat-ui

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Dec 26, 2025

🎭 Playwright Report

E2E Test가 성공적으로 완료되었습니다.

Test 요약 내용을 확인해주세요.

Status Build Log Updated (UTC)
✅ Ready View Build 2025-12-26 14:13:12

📊 Test Summary

  • ✅ Passed: 3
  • ❌ Failed: 0
  • ⏱️ Duration: 24.3s

📜 Test Details

✅ Passed Tests (3)
  • profile.test.ts (3)
    • [chromium] 존재하지 않는 프로필 페이지로 접속 시 404 redirect 되는 지 테스트
    • [firefox] 존재하지 않는 프로필 페이지로 접속 시 404 redirect 되는 지 테스트
    • [webkit] 존재하지 않는 프로필 페이지로 접속 시 404 redirect 되는 지 테스트

@github-actions
Copy link

github-actions bot commented Dec 26, 2025

🎨 Storybook Report

변경 사항이 없습니다

모든 Story가 이전 빌드와 동일합니다.

Status Storybook Build Log Updated (UTC)
✅ Unchanged View Storybook View Build 2025-12-26 14:12:29

@github-actions
Copy link

github-actions bot commented Dec 26, 2025

📊 Coverage Report

Status Build Log Updated (UTC)
✅ Ready View Build 2025-12-26 14:12:12

📉 #257main에 병합하면 coverage가 0.05% 감소합니다.

Coverage 요약

@@             Coverage Diff             @@
##             main     #257       +/-   ##
===========================================
- Coverage   37.76%   37.71%    -0.05%     
===========================================
  Files         186      189        +3     
  Lines        7986     8087      +101     
  Branches      361      361         0     
===========================================
+ Hits         3016     3050       +34     
+ Misses       4970     5037       +67     

영향받은 파일

파일 Coverage 변화
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/components/pages/chat/chat-list/index.tsx 47.67% (+47.67%) ⬆️
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/components/pages/chat/chat-long-text/index.tsx 36.84% (+36.84%) ⬆️
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/components/pages/chat/chat-modal/index.tsx 100.00% (+100.00%) ⬆️
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/components/pages/chat/chat-my-chat/index.tsx 46.15% (-1.67%) ⬇️
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/components/pages/chat/chat-other-chat/index.tsx 36.84% (-2.55%) ⬇️
/home/runner/work/WeGo_FrontEnd/WeGo_FrontEnd/src/hooks/use-chat/use-chat-longText/index.tsx 7.50% (+7.50%) ⬆️

@github-actions
Copy link

github-actions bot commented Dec 26, 2025

🚀 PR Preview Report

Build가 성공적으로 완료되었습니다.

Preview에서 변경사항을 확인하세요.

Status Preview Build Log Updated (UTC)
✅ Ready Visit Preview View Logs 2025-12-26 14:13:17

@wooktori wooktori added the Ready For Review! 리뷰 받을 준비가 되었습니다. label Dec 26, 2025
Copy link
Member

@yoorli yoorli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨습니다

const router = useRouter();
return (
<div className='bg-mono-white flex w-full items-center justify-between border-b border-gray-200 px-5 py-3'>
<div className='bg-mono-white sticky flex w-full items-center justify-between border-b border-gray-200 px-5 py-3'>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이거 top이랑 z-index 지정 안해줘도 잘 고정되나요??
저는 그 두 개 무조건 해야 하는 줄 알았어요.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

헛 제가 이것저것 테스트해보다가 못지웠네요.. 수정하겠습니다!🤓

Comment on lines 8 to 32
useLayoutEffect(() => {
if (!textRef.current) return;

const el = textRef.current;

const originalDisplay = el.style.display;
const originalClamp = el.style.webkitLineClamp;
const originalOverflow = el.style.overflow;

el.style.display = 'block';
el.style.webkitLineClamp = 'unset';
el.style.overflow = 'visible';

const lineHeight = parseFloat(getComputedStyle(el).lineHeight);
const fullHeight = el.scrollHeight;

setIsLongText(fullHeight > lineHeight * maxLines);

el.style.display = originalDisplay;
el.style.webkitLineClamp = originalClamp;
el.style.overflow = originalOverflow;
}, [text, maxLines]);

return { textRef, isLongText };
};
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

측정을 위해 DOM style을 직접 건드는 방식은 깜빡임과 같은 형상이 있진 않나요?
없다면 괘찮지만 클론을 만들어서 오프스크린에서 측정하는 방식도 있어요.
useLayoutEffect가 paint 전에 실행되기는 하지만 렌더 타이밍이나 컨테이너 width 확정 타이밍 같은 요소 때문에 부작용이 있지 않을까 싶고 실제 엘리먼트 스타일을 바꿨다 복구하면서 측정하는게 위험해 보여서 말씀드려요!

  const el = textRef.current;
  if (!el) return;
  
  ...
  const style = getComputedStyle(el);
  ...

  const clone = el.cloneNode(true) as HTMLSpanElement;
  clone.style.position = 'absolute';
  clone.style.visibility = 'hidden';
  clone.style.pointerEvents = 'none';
  clone.style.height = 'auto';
  ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

좋은 지적 감사합니다!
말씀하신대로 DOM을 직접 조작하는건 위험한 것 같아요
오프스크린 적용해서 수정하도록 하겠습니다!!😀

@wooktori wooktori merged commit 4cc9754 into main Dec 26, 2025
7 checks passed
@wooktori wooktori deleted the hwanwook-fix/chat-ui branch December 26, 2025 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ready For Review! 리뷰 받을 준비가 되었습니다.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants