Conversation
Walkthrough이 PR은 설정/탈퇴 화면의 디자인 QA 항목을 해결합니다. 체크아이콘 크기 및 리소스를 통일하고, 텍스트 정렬과 간격을 조정하며, 버튼 텍스트 크기 자동 조정 기능을 추가합니다. Changes
Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Review rate limit: 0/1 reviews remaining, refill in 60 minutes.Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@presentation/src/main/java/daily/dayo/presentation/view/Button.kt`:
- Around line 122-129: The FilledRoundedCornerButton's Text composable uses
TextAutoSize with maxFontSize = textStyle.fontSize which can be smaller than
safe limits and combined with maxLines=1, softWrap=false and TextOverflow.Clip
may silently cut long locale strings; add defensive logic in the button
(FilledRoundedCornerButton) to compute a safe maxFontSize =
max(textStyle.fontSize, 12.sp) or clamp textStyle.fontSize to a minimum of 12.sp
before passing to TextAutoSize, and fall back to TextOverflow.Ellipsis or relax
width constraints when autosizing cannot prevent truncation; also update the
KDoc for the textStyle parameter to state callers must provide an explicit
fontSize and note recommended minimum (12.sp) and mention the overflow
behaviour.
🪄 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: 87d731fd-da71-4cd4-9887-c92d5526db4e
📒 Files selected for processing (5)
presentation/src/main/java/daily/dayo/presentation/screen/account/WithdrawScreen.ktpresentation/src/main/java/daily/dayo/presentation/screen/settings/SettingsScreen.ktpresentation/src/main/java/daily/dayo/presentation/view/Button.ktpresentation/src/main/java/daily/dayo/presentation/view/dialog/BottomSheetDialog.ktpresentation/src/main/res/drawable/ic_check.xml
| modifier = contentModifier ?: Modifier.fillMaxWidth(), | ||
| maxLines = 1, | ||
| softWrap = false, | ||
| overflow = TextOverflow.Clip, | ||
| autoSize = TextAutoSize.StepBased( | ||
| minFontSize = 12.sp, | ||
| maxFontSize = textStyle.fontSize | ||
| ) |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
# FilledRoundedCornerButton 사용처와 해당 텍스트 스타일의 fontSize 명시 여부를 확인합니다.
rg -n -C 3 'FilledRoundedCornerButton\(' presentation/src/main/java
rg -n -C 3 'fontSize\s*=' presentation/src/main/java/daily/dayo/presentation/theme presentation/src/main/java/daily/dayo/presentation/screenRepository: Daily-DAYO/DAYO_Android
Length of output: 1795
🏁 Script executed:
# Search for FilledRoundedCornerButton usage patterns and fontSize definitions
# Assume repo is available at root
find . -type f -name "*.kt" | head -20Repository: Daily-DAYO/DAYO_Android
Length of output: 1584
🏁 Script executed:
# Search for FilledRoundedCornerButton usage and definition
rg -n "FilledRoundedCornerButton" presentation/src/main/java --type kt -C 3Repository: Daily-DAYO/DAYO_Android
Length of output: 94
🏁 Script executed:
# Search for fontSize definitions in theme/style files
rg -n "fontSize\s*=" presentation/src/main/java/daily/dayo/presentation/theme --type kt -C 2Repository: Daily-DAYO/DAYO_Android
Length of output: 94
🏁 Script executed:
# Locate and read the Button.kt file to understand the implementation
find presentation/src/main/java -name "Button.kt" -type fRepository: Daily-DAYO/DAYO_Android
Length of output: 133
🏁 Script executed:
# Search for FilledRoundedCornerButton usage across the codebase
rg -n "FilledRoundedCornerButton" presentation/src/main/java -C 3Repository: Daily-DAYO/DAYO_Android
Length of output: 23974
🏁 Script executed:
# Search for fontSize definitions in theme
rg -n "fontSize\s*=" presentation/src/main/java/daily/dayo/presentation/theme -C 2Repository: Daily-DAYO/DAYO_Android
Length of output: 8521
🏁 Script executed:
# Read the Button.kt file
cat -n presentation/src/main/java/daily/dayo/presentation/view/Button.ktRepository: Daily-DAYO/DAYO_Android
Length of output: 11449
🏁 Script executed:
# Check if any calls explicitly pass a textStyle that isn't from the theme
rg -n "textStyle\s*=" presentation/src/main/java/daily/dayo/presentation/screen --context 3 | head -50Repository: Daily-DAYO/DAYO_Android
Length of output: 5830
🏁 Script executed:
# Search for any custom TextStyle creations that might be passed to FilledRoundedCornerButton
rg -n "TextStyle\(" presentation/src/main/java/daily/dayo/presentation/screen -C 2 | grep -A 2 -B 2 "fontSize"Repository: Daily-DAYO/DAYO_Android
Length of output: 1151
TextAutoSize 구현의 안전성을 확보하되, 조용한 텍스트 절단 위험에 주의하세요.
현재 모든 FilledRoundedCornerButton 호출처는 테마에서 정의한 스타일(b3, b5 등)을 사용하고 있어 fontSize 제약은 만족하고 있습니다. 다만 TextOverflow.Clip + maxLines=1 + softWrap=false 조합은 긴 로캘 문자열(특히 한글)이 조용히 잘릴 수 있는 구조입니다.
안전성을 강화하기 위해:
- 공용 컴포넌트이므로
maxFontSize에 명시적 하한을 설정하거나, 함수 내에서textStyle.fontSize가 12.sp 이상임을 보증하는 방어 로직을 추가할 것 textStyle파라미터 문서에 "명시적 fontSize를 가져야 함" 요구사항을 명기할 것- 향후 호출처에서 텍스트 절단을 방지하기 위해, 필요시 버튼 너비 제약 또는 타원 부호(
TextOverflow.Ellipsis)로 변경을 검토할 것
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@presentation/src/main/java/daily/dayo/presentation/view/Button.kt` around
lines 122 - 129, The FilledRoundedCornerButton's Text composable uses
TextAutoSize with maxFontSize = textStyle.fontSize which can be smaller than
safe limits and combined with maxLines=1, softWrap=false and TextOverflow.Clip
may silently cut long locale strings; add defensive logic in the button
(FilledRoundedCornerButton) to compute a safe maxFontSize =
max(textStyle.fontSize, 12.sp) or clamp textStyle.fontSize to a minimum of 12.sp
before passing to TextAutoSize, and fall back to TextOverflow.Ellipsis or relax
width constraints when autosizing cannot prevent truncation; also update the
KDoc for the textStyle parameter to state callers must provide an explicit
fontSize and note recommended minimum (12.sp) and mention the overflow
behaviour.
|
@codex review |
|
Codex Review: Didn't find any major issues. More of your lovely PRs please. ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
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". |
작업 내용
참고
모듈별 변경 사항 및 기능적 영향
1. WithdrawScreen.kt (계정 삭제 화면)
기능적 영향:
사용자 대면 변경:
위험도: 낮음 (순수 UI 레이아웃 변경)
2. SettingsScreen.kt (설정 화면)
기능적 영향:
사용자 대면 변경:
위험도: 낮음 (순수 스타일 변경, 상태 관리 영향 없음)
3. Button.kt (FilledRoundedCornerButton)
기능적 영향:
사용자 대면 변경:
위험도: 낮음 (텍스트 렌더링 제약만 추가)
4. BottomSheetDialog.kt (바텀시트 다이얼로그)
기능적 영향:
사용자 대면 변경:
위험도: 낮음 (단순 크기 조정)
5. ic_check.xml (체크 아이콘 리소스)
기능적 영향:
사용자 대면 변경:
위험도: 낮음 (리소스 업데이트)
위험 포인트 분석
네트워크/오류 처리: 없음 (UI 관련 변경만)
스레딩 문제: 없음 (모든 변경이 주 스레드의 Compose UI 레이아웃/스타일)
상태 일관성: 없음 (상태 관리 로직 변경 없음, 기존 조건부 렌더링 유지)
필요한 테스트 및 검증
필수 검증 항목:
설정 화면 계정 삭제 플로우:
프로필 닉네임/이메일 표시:
체크 아이콘 일관성:
레이아웃 호환성:
권장 테스트: