Skip to content

fix(web): 멘토 채팅 이미지 로딩 재시도#521

Merged
manNomi merged 1 commit into
mainfrom
fix/mentor-chat-image-placeholder
May 19, 2026
Merged

fix(web): 멘토 채팅 이미지 로딩 재시도#521
manNomi merged 1 commit into
mainfrom
fix/mentor-chat-image-placeholder

Conversation

@manNomi
Copy link
Copy Markdown
Contributor

@manNomi manNomi commented May 19, 2026

Summary

  • 멘토 채팅 이미지 렌더링에서 thumbnailUrl을 우선 사용하도록 수정
  • FallbackImage에 opt-in 재시도 옵션을 추가해 전송 직후 CDN 반영 지연 시 자동 재로드
  • 채팅 첨부 thumbnailUrl 타입과 normalize 결과를 서버 응답에 맞춰 null 허용으로 정리

Test

  • pnpm --filter @solid-connect/web typecheck
  • pnpm --filter @solid-connect/web lint:check
  • push hook CI parity checks: lint:check, typecheck:ci, build

Notes

  • lint:check는 기존 useChatListHandler exhaustive-deps warning 1개를 출력하지만 exit 0으로 통과합니다.
  • 현재 로컬 Node는 v23.10.0이라 repo 요구 Node 22.x 엔진 경고가 출력됩니다.

@manNomi manNomi requested review from enunsnv and wibaek as code owners May 19, 2026 06:24
@vercel
Copy link
Copy Markdown

vercel Bot commented May 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
solid-connection-web Ready Ready Preview, Comment May 19, 2026 6:27am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
solid-connect-web-admin Skipped Skipped May 19, 2026 6:27am

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 19, 2026

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 22c56c3e-1d8a-4ea6-8a80-5de6e0c9b6cc

📥 Commits

Reviewing files that changed from the base of the PR and between 1fcf0ef and f76707b.

📒 Files selected for processing (4)
  • apps/web/src/apis/chat/normalize.ts
  • apps/web/src/app/mentor/chat/[chatId]/_ui/ChatContent/_ui/ChatMessageBox/index.tsx
  • apps/web/src/components/ui/FallbackImage.tsx
  • apps/web/src/types/chat.ts

Walkthrough

이 PR은 메시지 첨부 이미지의 로딩 안정성을 높이기 위해 재시도 메커니즘을 도입합니다. 타입 정의부터 컴포넌트 통합까지 다음과 같이 진행됩니다:

  1. 타입 정의 확장ChatAttachment.thumbnailUrl 타입을 string | null로 변경하여 썸네일 부재를 타입 수준에서 명시합니다.
  2. 정규화 로직 조정 — undefined 썸네일을 빈 문자열 대신 null로 반환하도록 정규화 함수를 수정합니다.
  3. FallbackImage 재시도 기능 — 새로운 props(retryOnError, retryLimit, retryDelayMs)를 받아 이미지 로드 실패 시 설정된 한도 내에서 지연 후 자동 재시도하며, 컴포넌트 언마운트 시 타이머를 정리합니다.
  4. ChatMessageBox 통합 — 메시지 박스의 이미지 렌더링에 재시도 상수를 적용하여 기능을 활성화합니다.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Suggested reviewers

  • wibaek
  • enunsnv
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive PR 설명이 '작업 내용'과 '테스트' 섹션은 포함하고 있으나, 필수 섹션인 '관련 이슈'는 누락되어 있습니다. 관련 이슈 번호를 추가해주세요. (예: resolves: #123) 또한 '특이 사항'과 '리뷰 요구사항'도 추가하면 검토를 더 용이하게 할 수 있습니다.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목은 주요 변경사항인 '멘토 채팅 이미지 로딩 재시도' 기능을 명확하게 요약하고 있으며, 모든 파일 변경사항과 일관성 있게 연결됩니다.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/mentor-chat-image-placeholder

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint skipped: no ESLint configuration detected in root package.json. To enable, add eslint to devDependencies.


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 github-actions Bot added the web label May 19, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f76707b241

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

<div className="relative overflow-hidden rounded-lg">
<Image
src={attachment.url}
src={attachment.thumbnailUrl || attachment.url}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Fall back to the original image when thumbnail fails

When a chat attachment has a non-empty thumbnailUrl, this now passes only that URL into FallbackImage; if the thumbnail object is missing or remains unavailable after the retry window while attachment.url is already valid, the component can only switch to the generic placeholder and never tries the original image URL. This regresses the previous behavior for those messages by hiding an otherwise loadable attachment, so the chat image path should fall back from thumbnailUrl to url before showing the placeholder.

Useful? React with 👍 / 👎.

@manNomi manNomi merged commit 08ec85f into main May 19, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant