Skip to content

develp branch 작업내용 머지 : develop -> main#107

Merged
heeeeyong merged 19 commits intomainfrom
develop
Aug 13, 2025
Merged

develp branch 작업내용 머지 : develop -> main#107
heeeeyong merged 19 commits intomainfrom
develop

Conversation

@heeeeyong
Copy link
Collaborator

@heeeeyong heeeeyong commented Aug 13, 2025

이하동일

Summary by CodeRabbit

  • 신기능

    • 피드 생성/수정 지원: 이미지 업로드(최대 3장), 태그 검증, 성공/실패 스낵바 제공
    • 피드 수정 페이지 및 라우트 추가, 상세 화면에서 수정으로 이동
    • 최근 팔로잉 작가 목록 자동 표시
    • 소셜 로그인 토큰 자동 처리(쿠키 기반)
  • 개선

    • 사진 섹션 읽기 전용/수정 모드 지원, 기존 이미지 삭제·총 개수 표시
    • 책 선택 섹션 읽기 전용 지원, ISBN 처리 개선으로 업로드 성공률 향상
    • 사용자 검색에 확정 여부 필터 추가
    • UI 크기 조정 및 로딩/빈 상태 처리 개선
  • 버그 수정

    • 팔로워 수 미제공 시 0으로 안전 표시

@vercel
Copy link

vercel bot commented Aug 13, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Project Deployment Preview Comments Updated (UTC)
thip Ready Preview Comment Aug 13, 2025 4:01pm

@heeeeyong heeeeyong merged commit 2b262af into main Aug 13, 2025
1 check passed
@coderabbitai
Copy link

coderabbitai bot commented Aug 13, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

쿠키 기반 인증으로 전환하는 apiClient 단순화와 함께, 피드 생성/수정 API·훅·페이지를 신규 도입했다. 이미지 업로드 유틸 추가, OAuth 토큰 처리 훅 연동, 검색/팔로우 관련 API 추가, contentsUrl→contentUrls 및 success→isSuccess 명세 변경을 전역 반영했다. 라우팅과 일부 UI/프롭스가 이에 맞추어 수정되었다.

Changes

Cohort / File(s) Summary
플랫폼/인프라 전환
src/api/index.ts, src/App.tsx
apiClient를 쿠키(withCredentials) 기반으로 단순화하고 기본 헤더/토큰 관리 제거·네임드 익스포트로 변경. App에서 CookiesProvider 제거.
피드 API 스키마 정합성(명세 변경)
src/api/feeds/getFeedDetail.ts, src/api/feeds/getMyFeed.ts, src/api/feeds/getOtherFeed.ts, src/api/feeds/getTotalFeed.ts, src/types/post.ts, src/data/postData.ts, src/mocks/searchBook.mock.ts, src/components/common/Post/PostBody.tsx, src/components/feed/FeedDetailPostBody.tsx
필드명 변경 일괄 반영: contentsUrl→contentUrls, success→isSuccess; getFeedDetail에 alias·isPublic 반영. 컴포넌트/모의데이터/타입 수정.
피드 생성 플로우 추가
src/api/feeds/createFeed.ts, src/hooks/useCreateFeed.ts, src/pages/post/CreatePost.tsx, src/utils/isbn.ts, src/api/images/uploadImage.ts
피드 생성 API/훅 도입, ISBN 유틸 추가, 단일/다중 이미지 업로드 유틸 추가, 작성 페이지에서 후보 ISBN 순차 시도 및 유효성 검증·스낵바 처리.
피드 수정 플로우 추가
src/api/feeds/updateFeed.ts, src/hooks/useUpdateFeed.ts, src/pages/post/UpdatePost.tsx, src/pages/index.tsx, src/pages/feed/FeedDetailPage.tsx, src/components/createpost/PhotoSection.tsx, src/components/creategroup/BookSelectionSection.tsx
피드 수정 API/훅·페이지 추가 및 라우트 등록(post/update/:feedId). 상세에서 편집 네비게이션 연결. 사진 섹션에 기존 이미지 관리/읽기전용/편집모드 프롭스 추가. 책 선택 섹션에 readOnly 도입.
소셜 로그인 토큰 처리
src/hooks/useOAuthToken.ts, src/pages/feed/Feed.tsx, src/pages/signup/SignupNickname.tsx
URL의 loginTokenKey로 /oauth-success 호출하는 훅 추가 및 피드/회원가입 닉네임 페이지에 연동.
검색/팔로우 API 추가
src/api/recentsearch/getRecentSearch.ts, src/api/users/getRecentFollowing.ts, src/api/users/getUsers.ts, src/hooks/useUserSearch.ts, src/pages/feed/UserSearch.tsx, src/components/feed/FollowList.tsx
최근 검색/최근 팔로우 작성자 API 추가 및 사용. 사용자 검색 파라미터에 isFinalized 추가. FollowList를 API 기반으로 전환.
UI 소소한 수정
src/components/feed/BookInfoCard.tsx, src/components/feed/UserProfileItem.tsx, src/pages/signup/SignupGenre.tsx
레이아웃 폭 제약 조정, 팔로워 수 기본값 처리, 회원가입 장르 페이지에서 쿠키/토큰 수동 처리 제거 및 로그/흐름 정리.
기타 데이터 모델 반영
src/components/common/BookSearchBottomSheet/BookSearchBottomSheet.tsx
Book 인터페이스와 모의 데이터에 isbn 필드 추가.

Sequence Diagram(s)

sequenceDiagram
  participant UI as CreatePost
  participant Hook as useCreateFeed
  participant API as createFeed
  participant S as Server

  UI->>Hook: createNewFeed(body, images?)
  Hook->>Hook: 로컬 검증(태그/이미지)
  alt 검증 실패
    Hook-->>UI: { success: false }
  else 통과
    Hook->>API: multipart/form-data 요청
    API->>S: POST /feeds
    S-->>API: CreateFeedResponse
    API-->>Hook: 응답 전달
    Hook-->>UI: { success, feedId? }
  end
Loading
sequenceDiagram
  participant UI as UpdatePost
  participant Hook as useUpdateFeed
  participant API as updateFeed
  participant S as Server

  UI->>Hook: updateExistingFeed(feedId, body)
  Hook->>Hook: 태그 검증(최대/중복)
  alt 통과
    Hook->>API: PATCH /feeds/{id} (JSON)
    alt 실패 시
      API->>API: FormData(request: JSON Blob) 재시도
      API->>S: PATCH /feeds/{id}
    end
    S-->>API: UpdateFeedResponse
    API-->>Hook: 응답
    Hook-->>UI: 결과 및 스낵바
  else 실패
    Hook-->>UI: { success: false }
  end
Loading
sequenceDiagram
  participant Page as Feed/SignupNickname
  participant Hook as useOAuthToken
  participant API as apiClient
  participant S as Server
  participant Nav as Router

  Page->>Hook: useOAuthToken()
  Hook->>Hook: URL에서 loginTokenKey 확인
  alt 존재함 & 미요청
    Hook->>API: POST /oauth-success (withCredentials)
    API->>S: 요청
    S-->>API: 200 응답
    API-->>Hook: 데이터
    Hook->>Nav: URL 쿼리 제거(replace)
  else 없음
    Hook-->>Page: isTokenRequested 상태만 반환
  end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested labels

✨ Feature, 📬 API, 🔨 Refactor

Suggested reviewers

  • ho0010
  • ljh130334

Poem

(\/)

( •
•) 토끼가 깡총, 새 글 쓰러 가네!

/>🍪 api는 쿠키, 토큰은 안녕해~

📚 ISBN을 고르고, 🖼️ 사진은 셋까지!

✍️ 수정도 척척, 길 바뀌어도 가지.

오늘의 립: isSuccess로 맞춰 쓰기!


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7233edc and ecd21f1.

📒 Files selected for processing (36)
  • src/App.tsx (1 hunks)
  • src/api/feeds/createFeed.ts (1 hunks)
  • src/api/feeds/getFeedDetail.ts (2 hunks)
  • src/api/feeds/getMyFeed.ts (1 hunks)
  • src/api/feeds/getOtherFeed.ts (2 hunks)
  • src/api/feeds/getTotalFeed.ts (1 hunks)
  • src/api/feeds/updateFeed.ts (1 hunks)
  • src/api/images/uploadImage.ts (1 hunks)
  • src/api/index.ts (1 hunks)
  • src/api/recentsearch/getRecentSearch.ts (1 hunks)
  • src/api/users/getRecentFollowing.ts (1 hunks)
  • src/api/users/getUsers.ts (2 hunks)
  • src/components/common/BookSearchBottomSheet/BookSearchBottomSheet.tsx (3 hunks)
  • src/components/common/Post/PostBody.tsx (2 hunks)
  • src/components/creategroup/BookSelectionSection.tsx (1 hunks)
  • src/components/createpost/PhotoSection.tsx (2 hunks)
  • src/components/feed/BookInfoCard.tsx (3 hunks)
  • src/components/feed/FeedDetailPostBody.tsx (3 hunks)
  • src/components/feed/FollowList.tsx (2 hunks)
  • src/components/feed/UserProfileItem.tsx (1 hunks)
  • src/data/postData.ts (4 hunks)
  • src/hooks/useCreateFeed.ts (1 hunks)
  • src/hooks/useOAuthToken.ts (1 hunks)
  • src/hooks/useUpdateFeed.ts (1 hunks)
  • src/hooks/useUserSearch.ts (3 hunks)
  • src/mocks/searchBook.mock.ts (2 hunks)
  • src/pages/feed/Feed.tsx (2 hunks)
  • src/pages/feed/FeedDetailPage.tsx (1 hunks)
  • src/pages/feed/UserSearch.tsx (1 hunks)
  • src/pages/index.tsx (2 hunks)
  • src/pages/post/CreatePost.tsx (2 hunks)
  • src/pages/post/UpdatePost.tsx (1 hunks)
  • src/pages/signup/SignupGenre.tsx (2 hunks)
  • src/pages/signup/SignupNickname.tsx (2 hunks)
  • src/types/post.ts (2 hunks)
  • src/utils/isbn.ts (1 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch develop

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants