[FEAT/#94] 채팅방 UI 구현#99
Conversation
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
|
Thanks for the contribution! Please review the labels and make any necessary changes. |
There was a problem hiding this comment.
Code Review
This pull request implements a comprehensive chat system for admin and partner roles, including room lists, messaging interfaces, and features for blocking users and leaving rooms. The implementation introduces several new components, widgets, and utilities, such as ChatRoomList, ChatMessageComposer, and formatChatTime. Review feedback suggests improving code consistency by using the getProfileImageUri utility, optimizing list performance with useCallback, leveraging the date-fns library for time formatting, and utilizing safe area insets for UI positioning. Additionally, defensive logic is recommended to handle cases where room data is not found.
| index, | ||
| })} | ||
| renderItem={({ item }) => ( | ||
| <ChatRoomItem {...item} onPress={() => onPressRoom?.(item.id)} /> |
| > | ||
| <Pressable className="flex-1" onPress={() => setMenuVisible(false)}> | ||
| <View | ||
| className="absolute top-[30px] right-6 rounded-[8px] bg-canvas px-4 py-3" |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
ahcgnoej
left a comment
There was a problem hiding this comment.
고생많으셨습니다!👏👏 개선 위주 코멘트라서 반영해도 되고 안 해도 될 것 같아요!
There was a problem hiding this comment.
FSD의 취지를 살린다면, 이 위젯은 메뉴를 열고 닫는 UI 정도의 역할만 수행하고, 실제로 차단이나 나가기 버튼을 눌렀을 때의 비즈니스 상태는 상위 레이어인 page에서 props로 내려주는 방식도 좋았을 것 같네요!
There was a problem hiding this comment.
좋은 의견인 거 같네요! 확인해보고 수정할게요
| import { ChatHeader } from "./ChatHeader"; | ||
| import { ChatMessageList } from "./ChatMessageList"; | ||
|
|
||
| interface ChatMessagesProps { |
There was a problem hiding this comment.
widgets/chat/chat-room/model/types.ts 요기 파일에 ChatRoomWidgetProps가 만들어져있는거 같은데 아래 내용 ChatRoomWidgetProps 요기에 보완하고 해당 타입 써두 될거같네요
There was a problem hiding this comment.
PartnerChatRoomPage.tsx 랑 내용이 거의 비슷한 거 같은데 공통 model 훅 만들고 role별 의존성 주입해주어도 좋을 것 같아요!
There was a problem hiding this comment.
맞습니다. 그 부분은 나중에 UI랑 로직 완벽히 완성하고 난 뒤에 뽑을려고 했습니다!
📝 요약
⚙️ 작업 내용
채팅방 UI 전체를 파트너/관리자 역할 기준으로 구현했습니다.
1. entities/chat
2. features
3. widgets/chat/chat-room
4. pages / 라우트
🔗 관련 이슈
✅ 체크리스트
💬 리뷰어에게
Screen_Recording_20260427_162705_Expo.Go.mp4