⚠ This page is served via a proxy. Original site: https://github.com
This service does not collect credentials or authentication data.
Skip to content

Conversation

@taipaise
Copy link
Collaborator

@taipaise taipaise commented Feb 1, 2026

🌁 Background

  • 감정구슬 관련 QA 대응을 진행했습니다!

📱 Screenshot

  • UI 변경사항 없음

👩‍💻 Contents

📬 Reference

Summary by CodeRabbit

릴리즈 노트

  • 새로운 기능

    • 감정 컬렉션 뷰 높이 확대로 더 넓은 표시 영역 제공
    • 스와이프 안내 오버레이 추가하여 사용성 향상
    • 스크롤 중 중앙 항목 인덱스 계산 및 이에 따른 햅틱 피드백 도입
    • 아이템 세트 수 기반의 유동적 페이징 지원
  • 개선 사항

    • 레이아웃 상수 정리로 디자인 일관성 강화
    • 스크롤 스냅 및 제스처 처리 로직 개선

✏️ Tip: You can customize this high-level summary in your review settings.

- 구슬 collectionView 하단의 안내 문구에서도 collectionView의 스크롤이 가능하도록 수정
- 무한 스크롤이 끊기는 현상 개선
- 구슬 스크롤 시 진동 피드백으로 사용자경험 향상
@taipaise taipaise self-assigned this Feb 1, 2026
@coderabbitai
Copy link

coderabbitai bot commented Feb 1, 2026

Caution

Review failed

The pull request is closed.

개요

감정 컬렉션 레이아웃에 Layout 열거형과 fetchcurrentIndex()를 추가하고, EmotionRegistrationViewController에서 컬렉션뷰 높이·아이템 집합 크기 변경(3→7), 제스처 처리 및 햅틱, infoSwipeOverlayView 통합과 스크롤 관련 로직을 갱신했습니다. (≤50단어)

변경 사항

집단 / 파일(s) 요약
레이아웃 상수화 및 인덱스 계산
Projects/Presentation/Sources/EmotionRegister/View/EmotionCollectionViewLayout.swift
중첩된 Layout 열거형(itemWidthRatio, lineSpacing, bottomSpacing) 도입, 기존 상수 참조를 대체, 바닥 여백 반영으로 itemHeight/sectionInset 조정, fetchcurrentIndex() -> Int? 추가.
뷰 컨트롤러 UI·상호작용 업데이트
Projects/Presentation/Sources/EmotionRegister/View/EmotionRegistrationViewController.swift
컬렉션뷰 높이 191→291, itemSetCount 도입으로 아이템 수 계산 변경(3→7 패턴), infoSwipeOverlayView, hapticGenerator, lastMarbleCellIndex 추가, 제스처 핸들러명 변경 및 새 핸들러 handleEmotionCollectionViewPanning, 스크롤 델리게이트(scrollViewDidScroll, 스냅/선택 로직) 및 레이아웃 제약 업데이트.

예상 코드 리뷰 노력

🎯 3 (중간) | ⏱️ ~20분

관련 가능성 있는 PR들

아, 보세요! 감정들의 춤이 더 커졌어요 🐰✨
일곱 개의 마음이 소용돌이치며,
손가락이 스치면 톡톡 터지는 느낌,
반짝이는 오버레이가 길을 밝혀주네요,
감정이라는 보석을 더 예쁘게 담았어요! 💎

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PR 제목이 변경 사항의 핵심을 정확히 반영하고 있습니다. 무한 스크롤 끊김 수정과 스크롤 가능 영역 확장이라는 주요 변경 사항을 명확하게 표현하고 있습니다.

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

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/emotionRegistration

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.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In
`@Projects/Presentation/Sources/EmotionRegister/View/EmotionRegistrationViewController.swift`:
- Around line 515-517: The current recenter condition wrongly uses itemCount /
itemSetCount and triggers for most indices; update the check in
EmotionRegistrationViewController so recentering only happens when the
tapped/visible index is in the very first or very last repeated set: use if
indexPath.row < itemCount || indexPath.row >= itemCount * (itemSetCount - 1) {
scrollToIndex(index: index) } (use the existing index variable and the itemCount
and itemSetCount symbols) so only the first set (indices < itemCount) or the
last set (indices >= itemCount * (itemSetCount - 1)) cause scrollToIndex to be
called.
- Around line 131-134: infoSwipeOverlayView에 대해 중복된 backgroundColor 설정과 사용되지 않는
변수 infoSwipeOverlayViewPanGesturePanGesture를 제거하고, infoSwipeOverlayView의 의도(터치
차단용 오버레이인지 제스처 수신용인지)를 명확히 하여 처리하세요: 만약 터치 차단 목적이면 isUserInteractionEnabled =
true로 두고 실제 터치 처리(예: 빈 UITapGestureRecognizer 또는 hitTest override)를 추가하여 터치를
블록하도록 구현하고, 제스처가 불필요하면 모든 제스처 관련 코드(예:
infoSwipeOverlayViewPanGesturePanGesture)와 isUserInteractionEnabled 설정을 false로
정리하세요; 또한 Layout.infoViewSize가 0으로 되어 있는 점을 주석으로 명시해 의도를 설명하거나 크기 변경 시 동작을
재검증하세요.
🧹 Nitpick comments (1)
Projects/Presentation/Sources/EmotionRegister/View/EmotionRegistrationViewController.swift (1)

287-304: itemSetCount 상수 활용 + 디버그 출력 정리 권장
하드코딩된 7은 상수 변경 시 누락 위험이 있고, print는 릴리즈 로그 노이즈가 됩니다.

♻️ 정리 제안
-                let multipliedEmotions = (0..<7).flatMap { i in
+                let multipliedEmotions = (0..<itemSetCount).flatMap { i in
                     i == centerIndex ? emotions : emotions.map { $0.copy() }
                 }
@@
-                print(lastMarbleCellIndex)

Comment on lines +515 to 517
if indexPath.row < itemCount / itemSetCount || indexPath.row >= itemCount * (itemSetCount / 2 + 1) / itemSetCount {
scrollToIndex(index: index)
}
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

재센터 조건이 대부분의 인덱스에서 항상 참이 됩니다.
itemCount / itemSetCount 기준은 임계값이 너무 작아 대부분의 스크롤에서 scrollToIndex가 호출될 수 있습니다. 총 아이템 수 기준으로 첫/마지막 세트에서만 재센터하도록 조정하는 편이 안전합니다.

🛠️ 수정 제안
-        if indexPath.row < itemCount / itemSetCount || indexPath.row >= itemCount * (itemSetCount / 2 + 1) / itemSetCount {
+        let totalItemCount = itemCount * itemSetCount
+        if indexPath.row < itemCount || indexPath.row >= totalItemCount - itemCount {
             scrollToIndex(index: index)
         }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
if indexPath.row < itemCount / itemSetCount || indexPath.row >= itemCount * (itemSetCount / 2 + 1) / itemSetCount {
scrollToIndex(index: index)
}
let totalItemCount = itemCount * itemSetCount
if indexPath.row < itemCount || indexPath.row >= totalItemCount - itemCount {
scrollToIndex(index: index)
}
🤖 Prompt for AI Agents
In
`@Projects/Presentation/Sources/EmotionRegister/View/EmotionRegistrationViewController.swift`
around lines 515 - 517, The current recenter condition wrongly uses itemCount /
itemSetCount and triggers for most indices; update the check in
EmotionRegistrationViewController so recentering only happens when the
tapped/visible index is in the very first or very last repeated set: use if
indexPath.row < itemCount || indexPath.row >= itemCount * (itemSetCount - 1) {
scrollToIndex(index: index) } (use the existing index variable and the itemCount
and itemSetCount symbols) so only the first set (indices < itemCount) or the
last set (indices >= itemCount * (itemSetCount - 1)) cause scrollToIndex to be
called.

@taipaise taipaise merged commit e1d6541 into develop Feb 1, 2026
1 of 2 checks passed
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