Conversation
DPlayChip.kt 삭제 chip 이미지 추가 iconRes 변수명 drawableRes로 변경
There was a problem hiding this comment.
Pull request overview
이 PR은 2차 QA에서 발견된 디자인 이슈들을 수정하고, 로딩/에러 상태를 처리하는 새로운 화면을 추가합니다.
Changes:
- 검색 결과 없음 텍스트 색상 변경 (gray400)
- 음악 제목 볼드 처리를 위한 DPlayMusicGridItem 스타일 파라미터 추가
- 커뮤니티 가이드 버튼 간격 조정 (8dp → 4dp)
- 모달 라운드 값 수정 (16dp → 12dp)
- 글 등록 버튼 색상 변경 (dplayBlack → gray600)
- DPlayChip 컴포넌트를 Image로 대체하여 그라데이션 칩 구현
- 내 프로필 클릭 시 마이페이지로 이동하는 네비게이션 로직 추가
- LoadingState enum 및 DPlayLoadingScreen, DPlayErrorScreen 컴포넌트 추가
- 알림 문구를 strings.xml로 이동
- 앱 아이콘 업데이트
Reviewed changes
Copilot reviewed 24 out of 44 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| feature/search/SearchScreen.kt | 검색 결과 없음 텍스트 스타일 및 색상 추가 |
| feature/home/HomeScreen.kt | 칩을 Image로 변경, NavigateToMyPage 파라미터 추가 |
| feature/home/HomeViewModel.kt | 프로필 클릭 시 본인인 경우 마이페이지로 이동 로직 추가 |
| feature/home/HomeContract.kt | NavigateToMyPage에 initialTab 파라미터 추가 |
| feature/detail/DetailScreen.kt | 칩을 Image로 변경, 로딩/에러 상태 처리 추가 |
| feature/detail/DetailViewModel.kt | LoadingState 관리 및 프로필 클릭 네비게이션 로직 추가 |
| feature/detail/DetailContract.kt | loadingState 필드 및 NavigateToMyPage 파라미터 추가 |
| feature/otherprofile/OtherProfileScreen.kt | 로딩/에러 상태 처리 추가 |
| feature/otherprofile/OtherProfileViewModel.kt | LoadingState 관리 추가 |
| feature/otherprofile/OtherProfileContract.kt | loadingState 필드 추가 |
| feature/comment/CommentScreen.kt | DPlayMusicGridItem 스타일 커스터마이징 |
| core/domain/LoadingState.kt | 로딩 상태 관리를 위한 enum 추가 |
| core/designsystem/DPlayLoadingScreen.kt | 로딩 화면 컴포넌트 추가 |
| core/designsystem/DPlayErrorScreen.kt | 에러 화면 컴포넌트 추가 |
| core/designsystem/DPlayMusicGridItem.kt | 스타일 및 간격 커스터마이징 파라미터 추가 |
| core/designsystem/DplayGuidelineButton.kt | 간격 조정 (8dp → 4dp) |
| core/designsystem/modal/WarningModal.kt | 라운드 값 변경 (16dp → 12dp) |
| core/designsystem/modal/GraphicModal.kt | 라운드 값 변경 (16dp → 12dp) |
| core/designsystem/chip/type/DPlayChipType.kt | iconRes를 drawableRes로 변경 |
| core/designsystem/chip/DPlayChip.kt | 컴포넌트 삭제 |
| core/designsystem/button/type/CircleButtonType.kt | Plus 버튼 색상 변경 (dplayBlack → gray600) |
| core/designsystem/strings.xml | 에러 메시지 문자열 추가 |
| core/designsystem/drawable/*.png | 그라데이션 칩 이미지 리소스 추가 |
| app/strings.xml | 앱 이름 및 알림 문구 추가 |
| app/DailyQuestionWorker.kt | 알림 텍스트를 strings.xml에서 가져오도록 변경 |
| app/mipmap-/.webp | 앱 아이콘 업데이트 |
| modifier = modifier.fillMaxSize(), | ||
| contentAlignment = Alignment.Center, | ||
| ) { | ||
| CircularProgressIndicator() |
There was a problem hiding this comment.
DPlayLoadingScreen의 CircularProgressIndicator에 색상이 지정되지 않았습니다. Material3의 기본 색상을 사용하는 것이 의도된 것인지 확인이 필요합니다. 다른 컴포넌트들과 일관성을 위해 DPlayTheme.colors를 사용하여 명시적으로 색상을 지정하는 것을 고려해보세요.
예: CircularProgressIndicator(color = DPlayTheme.colors.dplayPink)
| Column( | ||
| modifier = modifier.fillMaxSize(), | ||
| horizontalAlignment = Alignment.CenterHorizontally, | ||
| ) { |
There was a problem hiding this comment.
DPlayErrorScreen의 Column에 verticalArrangement가 설정되지 않았습니다. 현재 구조에서는 상단에 요소들이 밀집되어 있는데, Arrangement.Top을 명시적으로 설정하거나 다른 정렬 방식을 고려해보세요. 또한, 에러 컨텐츠가 화면 중앙에 위치하도록 Box를 사용하거나 weight를 활용하는 것이 더 나은 UX를 제공할 수 있습니다.
| Image( | ||
| painter = painterResource(id = it.drawableRes), | ||
| contentDescription = null, | ||
| modifier = | ||
| Modifier | ||
| .height(height = 32.dp) | ||
| .align(Alignment.TopCenter), | ||
| ) |
There was a problem hiding this comment.
DPlayChip 컴포넌트를 삭제하고 Image로 직접 대체한 구조는 재사용성과 유지보수성 측면에서 개선의 여지가 있습니다.
현재 문제점:
- 동일한 로직(when 문으로 chipType 결정)이 HomeScreen과 DetailScreen에 중복됨
- contentDescription이 null로 설정되어 접근성 저하
- 향후 새로운 배지 타입 추가 시 모든 사용처를 수정해야 함
개선 제안:
재사용 가능한 컴포넌트를 만들어 캡슐화하는 것을 권장합니다:
@Composable
fun DPlayBadgeImage(
badge: BADGE,
modifier: Modifier = Modifier,
) {
val chipType = when (badge) {
BADGE.BEST -> DPlayChipType.BEST
BADGE.EDITOR -> DPlayChipType.EDITOR
BADGE.NEW -> DPlayChipType.NEW
}
Image(
painter = painterResource(id = chipType.drawableRes),
contentDescription = stringResource(id = chipType.stringRes),
modifier = modifier.height(32.dp),
)
}이렇게 하면:
- 중복 코드 제거
- 접근성 개선 (contentDescription 자동 설정)
- 유지보수성 향상
| Image( | ||
| painter = painterResource(id = chipType.drawableRes), | ||
| contentDescription = null, |
There was a problem hiding this comment.
배지 이미지의 contentDescription이 null로 설정되어 있어 접근성이 저하됩니다. 스크린 리더를 사용하는 사용자는 이 배지가 무엇을 의미하는지 알 수 없습니다.
chipType.stringRes를 활용하여 접근성을 개선하세요:
contentDescription = stringResource(id = chipType.stringRes)
| @@ -30,18 +36,18 @@ fun DPlayMusicGridItem( | |||
| Modifier | |||
| .fillMaxWidth(), | |||
| ) | |||
| Spacer(modifier = Modifier.height(5.dp)) | |||
| Spacer(modifier = Modifier.height(spaceBetweenCover)) | |||
| Text( | |||
| text = musicName, | |||
| style = DPlayTheme.typography.bodySemi14, | |||
| style = titleStyle, | |||
| color = DPlayTheme.colors.dplayBlack, | |||
| maxLines = 1, | |||
| overflow = TextOverflow.Ellipsis, | |||
| ) | |||
| Spacer(modifier = Modifier.height(1.dp)) | |||
| Spacer(modifier = Modifier.height(spaceBetweenText)) | |||
| Text( | |||
| text = musicArtistName, | |||
| style = DPlayTheme.typography.capMed12, | |||
| style = artistStyle, | |||
There was a problem hiding this comment.
해당 스타일과 space값 인자로 주입받도록 수정하신 이유가 있나요??
There was a problem hiding this comment.
이 컴포넌트의 타입이 2개 더라고요..
Related issue 🛠
Work Description ✏️
To Reviewers 📢
로딩, 에러 뷰 추가해봤는데 구조 괜찮은 지 봐주시면 좋을 것 같고, 괜찮으면 기록 뷰에도 에러 뷰 달면 좋을 것 같긴 합니다