Skip to content

[Feat/#57] 챌린지 Todo 미션칩 컴포넌트 구현 #58

Merged
hyeminililo merged 5 commits intodevelopfrom
feat/#57-challenge-chip-component
Jan 15, 2026
Merged

[Feat/#57] 챌린지 Todo 미션칩 컴포넌트 구현 #58
hyeminililo merged 5 commits intodevelopfrom
feat/#57-challenge-chip-component

Conversation

@hyeminililo
Copy link
Copy Markdown
Contributor

@hyeminililo hyeminililo commented Jan 14, 2026

Related issue 🛠

Work Description ✏️

  • 챌린지 미션 카드 Chip 컴포넌트 재구현
  • 선택/미선택 상태에 따라 배경색, 보더, 아이콘이 변경되도록 처리
  • 컴포넌트를 stateless 구조로 변경하고 선택 상태는 외부에서 관리하도록 수정
  • Row 정렬(CenterVertically) 및 아이콘–텍스트 간격(spacedBy) 적용
  • Preview에서 스크롤 가능한 리스트(LazyColumn)로 더미 데이터 렌더링
  • ktLint 실행 및 확인

Screenshot 📸

미션 칩 프리뷰
image

미션 칩s 프리뷰
image

미션칩 활성화
image

Uncompleted Tasks 😅

N/A

To Reviewers 📢

최대한 재사용성이 높을 수 있게 구현해보려고 노력했습니다 ! 파라미터 등등 확인해주시면 감사하겠습니당 ~~!!

Summary by CodeRabbit

  • 새로운 기능
    • 도전 미션용 선택형 칩 UI가 추가되었습니다. 클릭 시 테두리·배경·아이콘·텍스트 색상이 동적으로 바뀌어 선택 상태를 명확히 표시합니다.
    • 칩 목록에서 단일 선택 표시를 지원해 현재 선택 항목을 한눈에 확인할 수 있습니다.
    • 동작 확인용 미리보기를 포함해 UI 동작을 쉽게 확인할 수 있습니다.

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

- Todo 챌린지 컴포넌트 구현
- Todo 챌린지 칩 구현
- Todo 챌린지 칩 열로 구현
@hyeminililo hyeminililo self-assigned this Jan 14, 2026
@hyeminililo hyeminililo requested a review from a team as a code owner January 14, 2026 12:46
@hyeminililo hyeminililo added FEAT✨ 새로운 기능 구현 혜민🍒 혜민 담당 labels Jan 14, 2026
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jan 14, 2026

Walkthrough

새로운 Jetpack Compose UI 컴포넌트 ChallengeMissionCardChip을 추가합니다. 아이콘과 텍스트를 가진 둥근 테두리 칩이며, 선택 상태에 따라 테두리·배경·아이콘·텍스트 색상이 변경되고 클릭 핸들러와 미리보기를 포함합니다.

Changes

Cohort / File(s) 요약
새 컴포저블 컴포넌트
app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt
ChallengeMissionCardChip(text, onClick, modifier, isSelected) 함수 추가. 선택 상태에 따른 스타일(테두리 색, 배경, 아이콘, 텍스트 색) 적용, 클릭 처리(noRippleClickable), 두 개의 Preview 컴포저블 포함.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Suggested reviewers

  • sohee6989
  • nhyeonii

개요

새로운 Jetpack Compose UI 컴포넌트 ChallengeMissionCardChip을 추가합니다. 이 컴포넌트는 아이콘과 텍스트가 있는 둥근 테두리 행을 렌더링하며, 선택 상태에 따라 색상과 아이콘이 변경됩니다.

변경 사항

내용 파일
새로운 미션 카드 칩 컴포넌트
ChallengeMissionCardChip 함수 추가, 선택/미선택 상태에 따른 스타일링 (테두리 색상, 배경, 아이콘, 텍스트 색상), 클릭 핸들러 및 두 개의 Preview 컴포저블 포함
app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt

추정 코드 리뷰 난이도

🎯 2 (Simple) | ⏱️ ~12분

관련 PR

  • TEAM-Cherrish/Cherrish-Android#31: ChallengeMissionCardChip과 동일한 선택 칩 UI 동작 및 아이콘/상태 처리를 구현하는 CherrishSelectionBaseChip/CherrishMissionCard를 다루는 PR
  • TEAM-Cherrish/Cherrish-Android#14: 선택 가능한 칩 컴포넌트를 구현하며 동일한 선택 아이콘 자산과 미션 카드 선택 동작을 사용하는 PR

추천 리뷰어

  • sohee6989
  • nhyeonii
🚥 Pre-merge checks | ✅ 4 | ❌ 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 (4 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목이 실제 변경사항(챌린지 미션칩 컴포넌트 구현)을 명확하게 설명하고 있어 적절합니다.
Description check ✅ Passed PR 설명이 템플릿 구조를 따르고 있으며 관련 이슈, 작업 내용, 스크린샷, 리뷰어 의견을 포함하고 있습니다.
Linked Issues check ✅ Passed PR 변경사항이 #57의 모든 요구사항을 충족합니다: 컴포넌트 재구현, 선택/미선택 상태 처리, 프리뷰 구현(LazyColumn 포함), ktLint 확인 완료.
Out of Scope Changes check ✅ Passed 모든 변경사항이 #57의 범위 내에 있으며, ChallengeMissionCardChip 컴포넌트와 관련된 코드만 추가되었습니다.

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

✨ Finishing touches
  • 📝 Generate docstrings

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
Contributor

@nhyeonii nhyeonii left a comment

Choose a reason for hiding this comment

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

LGTM ~~ 🚀🚀🚀 깔끔하네요잉 고생햇슈

@Composable
private fun ChallengeMissionCardChipsPreview() {
CherrishTheme {
val dummyMissions = listOf(
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
val dummyMissions = listOf(
val dummyMissions = persistentListOf(

P1 : persistentListOf 사용해주셍용 ~~

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

불변리스트라서 이거 사용해야하는군요 !! 넵 !! 수정하겠습니다 :)

- 성능 최적화를 위해 프리뷰 내에서 listOf -> 불변 컬렉션인 persistentListOf로 변경
Copy link
Copy Markdown
Contributor

@sohee6989 sohee6989 left a comment

Choose a reason for hiding this comment

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

수고하셨습니다!
리뷰 한 번만 확인 부탁드립니다~~

.background(
color = if (isSelected) CherrishTheme.colors.red100 else CherrishTheme.colors.gray0
)
.padding(top = 14.dp, start = 14.dp, bottom = 14.dp, end = 44.dp)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

p2:

Suggested change
.padding(top = 14.dp, start = 14.dp, bottom = 14.dp, end = 44.dp)
.padding(vertical = 14.dp)
.padding( start = 14.dp, end = 44.dp)

이렇게 쓰는거 어떠세요??
가독성이 더 좋아보여서 제안 드립니다~!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

오 좋은것 같아요 ~ 수정하겠습니다 !

)
.padding(top = 14.dp, start = 14.dp, bottom = 14.dp, end = 44.dp)
.noRippleClickable(onClick = onClick),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

p2: 공백 지워주세요~!!
55번째줄 공백도요!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

넵 없앨게용 ~~!!

text = text,
style = CherrishTheme.typography.body1R14,
color = if (isSelected) CherrishTheme.colors.gray800 else CherrishTheme.colors.gray700,
modifier = Modifier.fillMaxWidth()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

p3: 이거 안 써도 되지 않나여??

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

오오 그러네용 ~~~!! 지우겠습니다아 ~!

modifier = Modifier.padding(all = 16.dp),
verticalArrangement = Arrangement.spacedBy(space = 8.dp)
) {
itemsIndexed(items = dummyMissions) { index, text ->
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

p3: 나중에 화면에서 쓸때는 key값 활용해도 좋을 듯 합니다!

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

넵 기억하겠습니다 ~! 조립하면서 uiState 만들 때 변경해도록 하겠습니다 :)

Copy link
Copy Markdown
Contributor

@usuuhyn usuuhyn left a comment

Choose a reason for hiding this comment

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

수고하셨습니당 !! 굿~~

.padding(top = 14.dp, start = 14.dp, bottom = 14.dp, end = 44.dp)
.noRippleClickable(onClick = onClick),

horizontalArrangement = Arrangement.spacedBy(space = 6.dp),
Copy link
Copy Markdown
Contributor

@usuuhyn usuuhyn Jan 15, 2026

Choose a reason for hiding this comment

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

P199: 헉 !! 요소가 두 개뿐이라 modifier 패딩 값 따로 줘도 되지 않나 싶었는데 찾아보니 요소 개수와 관계없이 spacedBy로 레이아웃 간격을 조정해주는게 더 좋다네요 ?!?! 오호 배워갑니다옹

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

좋습니당 !!!! 저도 이번에 알았서요 !!!!

- 불필요한 코드 삭제
- ktLint 실행
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

🤖 Fix all issues with AI agents
In
`@app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt`:
- Around line 38-53: The Row modifier chain currently places noRippleClickable
after the padding calls, which restricts the touch target to the inner content;
move noRippleClickable(onClick = onClick) to just after the background(...) call
and before any padding calls so the entire chip including its padded edges is
clickable; update the modifier chain around the Row (the modifier variable
passed into Row and the noRippleClickable usage) accordingly to ensure full-area
touch handling.
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 10c70c7 and acc0c9c.

📒 Files selected for processing (1)
  • app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt
🧰 Additional context used
📓 Path-based instructions (1)
**/*.kt

⚙️ CodeRabbit configuration file

**/*.kt: - Jetpack Compose 구조, 상태 관리, recomposition 최적화에 집중

  • ViewModel, UiState, 단방향 데이터 흐름 패턴 검토
  • 불필요한 recomposition 가능성, remember/derivedStateOf 적절한 사용 확인
  • 네이밍 컨벤션, 가독성, Google 권장 Android 아키텍처 준수 여부

Files:

  • app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt
🧠 Learnings (3)
📓 Common learnings
Learnt from: nhyeonii
Repo: TEAM-Cherrish/Cherrish-Android PR: 14
File: app/src/main/java/com/cherrish/android/core/designsystem/component/chip/CherrishSelction.kt:1-1
Timestamp: 2026-01-09T08:26:00.938Z
Learning: Cherrish Android 프로젝트에서는 Jetpack Compose 컴포저블 파일명과 해당 파일의 메인 컴포저블 함수명이 일치해야 합니다 (예: CherrishBasicChip.kt 파일에는 CherrishBasicChip 컴포저블 함수).
📚 Learning: 2026-01-09T08:26:00.938Z
Learnt from: nhyeonii
Repo: TEAM-Cherrish/Cherrish-Android PR: 14
File: app/src/main/java/com/cherrish/android/core/designsystem/component/chip/CherrishSelction.kt:1-1
Timestamp: 2026-01-09T08:26:00.938Z
Learning: Cherrish Android 프로젝트에서는 Jetpack Compose 컴포저블 파일명과 해당 파일의 메인 컴포저블 함수명이 일치해야 합니다 (예: CherrishBasicChip.kt 파일에는 CherrishBasicChip 컴포저블 함수).

Applied to files:

  • app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt
📚 Learning: 2026-01-12T19:49:27.085Z
Learnt from: nhyeonii
Repo: TEAM-Cherrish/Cherrish-Android PR: 41
File: app/src/main/java/com/cherrish/android/presentation/challenge/ChallengeScreen.kt:30-39
Timestamp: 2026-01-12T19:49:27.085Z
Learning: When a Jetpack Compose screen composable receives a Scaffold paddingValues: PaddingValues parameter (commonly from Scaffold), apply it to the root container's modifier first (e.g., .padding(paddingValues)) before applying any additional padding. This ensures content respects system bars (status/navigation) and avoids layout overlap. This pattern should be followed across presentation screens under app/src/main/java/com/cherrish/android/presentation/ to maintain consistent insets handling.

Applied to files:

  • app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt
🧬 Code graph analysis (1)
app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt (1)
app/src/main/java/com/cherrish/android/core/designsystem/theme/Theme.kt (1)
  • CherrishTheme (38-61)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: PR Build Check
  • GitHub Check: PR Lint Check
🔇 Additional comments (3)
app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt (3)

1-30: LGTM!

패키지 선언과 import 구성이 적절합니다. persistentListOf 사용을 위한 불변 컬렉션 라이브러리 import와 필요한 Compose 의존성들이 잘 정리되어 있습니다.


57-74: LGTM!

Icon과 Text 컴포저블이 isSelected 상태에 따라 적절히 스타일링됩니다. contentDescription = null은 데코레이티브 아이콘에 적합하며, CherrishTheme의 typography와 colors를 일관되게 사용하고 있습니다.


77-118: LGTM!

프리뷰 구현이 적절합니다. persistentListOf를 사용하여 불변 컬렉션을 적용했고, CherrishTheme으로 감싸 실제 테마 환경에서 테스트됩니다. selectedIndexInt? 타입 사용으로 미선택 상태(null)도 표현 가능합니다.

Based on learnings, 파일명(ChallengeMissionCardChip.kt)과 메인 컴포저블 함수명(ChallengeMissionCardChip)이 일치하여 프로젝트 컨벤션을 준수합니다.

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.

Comment on lines +38 to +53
Row(
modifier = modifier
.fillMaxWidth()
.clip(shape = RoundedCornerShape(size = 10.dp))
.border(
width = 1.dp,
color =
if (isSelected) CherrishTheme.colors.red500 else CherrishTheme.colors.gray500,
shape = RoundedCornerShape(size = 10.dp)
)
.background(
color = if (isSelected) CherrishTheme.colors.red100 else CherrishTheme.colors.gray0
)
.padding(vertical = 14.dp)
.padding(start = 14.dp, end = 44.dp)
.noRippleClickable(onClick = onClick),
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 | 🟡 Minor

Modifier 체인에서 noRippleClickable 위치 조정 필요

현재 noRippleClickablepadding 뒤에 위치하여 클릭 가능 영역이 패딩을 제외한 콘텐츠 영역으로 제한됩니다. 사용자가 칩의 가장자리(패딩 영역)를 터치하면 클릭이 동작하지 않아 UX가 저하될 수 있습니다.

noRippleClickablebackground 바로 뒤, padding 앞으로 이동하면 전체 칩 영역이 클릭 가능해집니다.

🔧 권장 수정 사항
         modifier = modifier
             .fillMaxWidth()
             .clip(shape = RoundedCornerShape(size = 10.dp))
             .border(
                 width = 1.dp,
                 color =
                 if (isSelected) CherrishTheme.colors.red500 else CherrishTheme.colors.gray500,
                 shape = RoundedCornerShape(size = 10.dp)
             )
             .background(
                 color = if (isSelected) CherrishTheme.colors.red100 else CherrishTheme.colors.gray0
             )
+            .noRippleClickable(onClick = onClick)
             .padding(vertical = 14.dp)
-            .padding(start = 14.dp, end = 44.dp)
-            .noRippleClickable(onClick = onClick),
+            .padding(start = 14.dp, end = 44.dp),
📝 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
Row(
modifier = modifier
.fillMaxWidth()
.clip(shape = RoundedCornerShape(size = 10.dp))
.border(
width = 1.dp,
color =
if (isSelected) CherrishTheme.colors.red500 else CherrishTheme.colors.gray500,
shape = RoundedCornerShape(size = 10.dp)
)
.background(
color = if (isSelected) CherrishTheme.colors.red100 else CherrishTheme.colors.gray0
)
.padding(vertical = 14.dp)
.padding(start = 14.dp, end = 44.dp)
.noRippleClickable(onClick = onClick),
Row(
modifier = modifier
.fillMaxWidth()
.clip(shape = RoundedCornerShape(size = 10.dp))
.border(
width = 1.dp,
color =
if (isSelected) CherrishTheme.colors.red500 else CherrishTheme.colors.gray500,
shape = RoundedCornerShape(size = 10.dp)
)
.background(
color = if (isSelected) CherrishTheme.colors.red100 else CherrishTheme.colors.gray0
)
.noRippleClickable(onClick = onClick)
.padding(vertical = 14.dp)
.padding(start = 14.dp, end = 44.dp),
🤖 Prompt for AI Agents
In
`@app/src/main/java/com/cherrish/android/presentation/challenge/component/ChallengeMissionCardChip.kt`
around lines 38 - 53, The Row modifier chain currently places noRippleClickable
after the padding calls, which restricts the touch target to the inner content;
move noRippleClickable(onClick = onClick) to just after the background(...) call
and before any padding calls so the entire chip including its padded edges is
clickable; update the modifier chain around the Row (the modifier variable
passed into Row and the noRippleClickable usage) accordingly to ensure full-area
touch handling.

@hyeminililo hyeminililo merged commit 932afeb into develop Jan 15, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

FEAT✨ 새로운 기능 구현 혜민🍒 혜민 담당

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] 챌린지 뷰 Todo 미션카드 컴포넌트 재구현

4 participants