Skip to content

[Fix] 루틴 생성 시 달력 component interaction 수정#90

Merged
taipaise merged 1 commit intodevelopfrom
fix/routine
Apr 8, 2026
Merged

[Fix] 루틴 생성 시 달력 component interaction 수정#90
taipaise merged 1 commit intodevelopfrom
fix/routine

Conversation

@taipaise
Copy link
Copy Markdown
Collaborator

@taipaise taipaise commented Apr 8, 2026

🌁 Background

  • 루틴 등록 QA 대응

👩‍💻 Contents

  • 달력 스와이프 시, 년월에 맞게 Label 의 텍스트가 변경되도록 수정
  • 달력 우측 상단의 앞으로가기, 뒤로가기 버튼 활성화

📬 Reference

Summary by CodeRabbit

새로운 기능

  • 달력에서 이전/다음 버튼을 사용한 월간 네비게이션 기능 추가
  • 달력 페이지 변경 시 현재 월과 연도 표시 자동 업데이트

@taipaise taipaise self-assigned this Apr 8, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 8, 2026

Walkthrough

FSCalendar에서 월 네비게이션 기능을 추가했습니다. 이전/다음 버튼의 터치 이벤트를 moveMonth(offset:) 메서드로 연결하여 현재 월을 변경하고, 월 변경 시 날짜 레이블을 자동으로 업데이트하도록 구현했습니다.

Changes

Cohort / File(s) Summary
월 네비게이션 기능 추가
Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift
prevButtonnextButton 터치 핸들러를 moveMonth(offset:) 메서드로 연결하여 월 네비게이션 구현. updateDateLabel(with:) 헬퍼 메서드 추가 및 FSCalendarDelegate.calendarCurrentPageDidChange 델리게이트 메서드에 훅 추가하여 월 변경 시 레이블 자동 업데이트 기능 구현.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 달력 위를 콩콩 뛰며,
이전과 다음 단추를 누르네요.
월이 술술 넘어가고,
레이블도 함께 춤을 춘답니다.
작은 기능이 모여,
큰 즐거움을 만드네! 🌙✨

🚥 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
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/routine

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
Copy Markdown

@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: 1

🧹 Nitpick comments (1)
Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift (1)

168-170: 초기 라벨 설정도 updateDateLabel(with:)로 통일하면 유지보수가 더 좋아집니다.

초기 텍스트 설정 로직과 월 변경 후 로직을 한 경로로 맞추면 포맷 변경 시 누락 가능성을 줄일 수 있습니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift`
around lines 168 - 170, 초기 텍스트 설정을 현재 직접 할당하고 있는 코드 대신 updateDateLabel(with:)로
통일하세요: 찾고 바꿀 대상은 dateLabel의 초기 텍스트를 설정하는 위치(초기화/setup 메서드)이며 그곳에서 dateLabel.text
= ... 대신 updateDateLabel(with: initialDate) 호출을 사용해 초기 라벨 세팅과 월 변경 시 로직이 동일한 경로로
실행되도록 만드세요; 참조 심볼: updateDateLabel(with:), dateLabel.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift`:
- Around line 50-60: The prevButton and nextButton lack accessibility labels,
making them indistinguishable to VoiceOver users; update the
BitnagilCalendarView initialization where prevButton and nextButton are
configured to set meaningful accessibility properties (e.g., set
accessibilityLabel to localized strings like "Previous month" and "Next month",
optionally set accessibilityHint and accessibilityTraits = .button, and/or set
accessibilityIdentifier for testing) so that users can identify the month
navigation actions triggered by moveMonth(offset:).

---

Nitpick comments:
In
`@Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift`:
- Around line 168-170: 초기 텍스트 설정을 현재 직접 할당하고 있는 코드 대신 updateDateLabel(with:)로
통일하세요: 찾고 바꿀 대상은 dateLabel의 초기 텍스트를 설정하는 위치(초기화/setup 메서드)이며 그곳에서 dateLabel.text
= ... 대신 updateDateLabel(with: initialDate) 호출을 사용해 초기 라벨 세팅과 월 변경 시 로직이 동일한 경로로
실행되도록 만드세요; 참조 심볼: updateDateLabel(with:), dateLabel.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: bd2e0314-cbe9-4da1-a2a2-f8ea336c35b8

📥 Commits

Reviewing files that changed from the base of the PR and between 566ade4 and ca23adb.

📒 Files selected for processing (1)
  • Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift

Comment on lines +50 to +60
prevButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: -1)
},
for: .touchUpInside)

nextButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: 1)
},
for: .touchUpInside)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

접근성 레이블이 없어 월 이동 버튼을 식별하기 어렵습니다.

이제 버튼이 실제 동작을 가지므로 VoiceOver 사용자는 기능을 구분할 수 있어야 합니다. prevButton/nextButton에 접근성 레이블을 명시해 주세요.

✅ 제안 수정
         prevButton.addAction(
             UIAction{ [weak self] _ in
                 self?.moveMonth(offset: -1)
             },
             for: .touchUpInside)
+        prevButton.isAccessibilityElement = true
+        prevButton.accessibilityLabel = "이전 달"
+        prevButton.accessibilityTraits = .button

         nextButton.addAction(
             UIAction{ [weak self] _ in
                 self?.moveMonth(offset: 1)
             },
             for: .touchUpInside)
+        nextButton.isAccessibilityElement = true
+        nextButton.accessibilityLabel = "다음 달"
+        nextButton.accessibilityTraits = .button
📝 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
prevButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: -1)
},
for: .touchUpInside)
nextButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: 1)
},
for: .touchUpInside)
prevButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: -1)
},
for: .touchUpInside)
prevButton.isAccessibilityElement = true
prevButton.accessibilityLabel = "이전 달"
prevButton.accessibilityTraits = .button
nextButton.addAction(
UIAction{ [weak self] _ in
self?.moveMonth(offset: 1)
},
for: .touchUpInside)
nextButton.isAccessibilityElement = true
nextButton.accessibilityLabel = "다음 달"
nextButton.accessibilityTraits = .button
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Projects/Presentation/Sources/RoutineCreation/View/Component/BitnagilCalendarView.swift`
around lines 50 - 60, The prevButton and nextButton lack accessibility labels,
making them indistinguishable to VoiceOver users; update the
BitnagilCalendarView initialization where prevButton and nextButton are
configured to set meaningful accessibility properties (e.g., set
accessibilityLabel to localized strings like "Previous month" and "Next month",
optionally set accessibilityHint and accessibilityTraits = .button, and/or set
accessibilityIdentifier for testing) so that users can identify the month
navigation actions triggered by moveMonth(offset:).

@taipaise taipaise merged commit dc37897 into develop Apr 8, 2026
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.

1 participant