Skip to content

fix: 감정별 배경/텍스트 색상 매칭 수정#214

Merged
easyhooon merged 6 commits intodevelopfrom
BOOK-417-fix/#213
Nov 5, 2025
Merged

fix: 감정별 배경/텍스트 색상 매칭 수정#214
easyhooon merged 6 commits intodevelopfrom
BOOK-417-fix/#213

Conversation

@easyhooon
Copy link
Copy Markdown
Contributor

@easyhooon easyhooon commented Nov 3, 2025

🔗 관련 이슈

📙 작업 설명

  • 도서 상세화면 - 내가 모은 씨앗 컴포넌트내 슬픔, 깨달음 텍스트, 텍스트 배경색상이 반대로 매핑된 문제 해결

🧪 테스트 내역 (선택)

  • 주요 기능 정상 동작 확인
  • 브라우저/기기에서 동작 확인
  • 엣지 케이스 테스트 완료
  • 기존 기능 영향 없음

📸 스크린샷 또는 시연 영상 (선택)

Before After

💬 추가 설명 or 리뷰 포인트 (선택)

Summary by CodeRabbit

  • 리팩토링
    • 감정 색상·그래픽 매핑을 디자인 시스템으로 통합하고 감정 모델 사용을 일관화했습니다.
    • 기존 감정 태그 구조를 정리해 표현 데이터가 단순화되었습니다.
  • 수정
    • UI 컴포넌트들이 새로운 디자인 시스템 속성(배경·텍스트 색상, 그래픽)을 사용하도록 업데이트되었습니다.
    • 화면·상태 파라미터명 변경에 따라 전달값이 새 이름으로 정렬되었습니다.
  • 잡업(Chore)
    • 디자인 모듈 의존성 추가 및 도구 버전 소폭 업데이트가 반영되었습니다.

슬픔과 깨달음이 반대로 되어있었음...
@github-actions github-actions Bot added the 🐞 fix Something isn't working label Nov 3, 2025
@github-actions github-actions Bot requested a review from seoyoon513 November 3, 2025 06:03
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Nov 3, 2025

Walkthrough

감정 색상 매핑을 공통 확장 함수에서 디자인시스템의 Emotion 확장 속성(bgColor, textColor, graphicRes)으로 이동했고, EmotionTag 열거형과 기존 확장 함수 파일을 제거 및 디자인시스템에 core.model 의존성을 추가했습니다. 여러 UI와 상태에서 emotionTagemotionEmotionTagEmotion로 명칭/타입이 변경되었습니다.

Changes

Cohort / File(s) Summary
디자인시스템: 새 확장 속성
core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/Emotion.kt
Emotion에 val bgColor: Color, val textColor: Color, val graphicRes: Int 확장 속성 추가 (각 감정에 매핑)
공통 확장 제거
core/common/src/main/kotlin/com/ninecraft/booket/core/common/extensions/Emotion.kt
기존 toTextColor()toBackgroundColor() 확장 함수 파일 삭제
EmotionTag 제거/단순화
core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/EmotionTag.kt
감정 태그 관련 색상 필드 제거(파일/열거형 변경 또는 삭제로 보임)
모듈 의존성 추가
core/designsystem/build.gradle.kts
implementation(project(":core.model")) 추가
UI: SeedItem 색상 접근 변경
feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/component/SeedItem.kt
toBackgroundColor()/toTextColor() 호출을 emotion.name.bgColor/emotion.name.textColor로 교체
RecordCard / Screen 파라미터명 변경
feature/detail/.../BookDetailPresenter.kt, feature/detail/.../RecordCardPresenter.kt, feature/detail/.../RecordCardUi.kt, feature/detail/.../RecordCardUiState.kt, feature/detail/.../RecordCard.kt, feature/screens/src/main/kotlin/com/ninecraft/booket/feature/screens/Screens.kt
emotionTag 필드/파라미터명을 emotion으로 변경; 관련 매핑과 호출 업데이트
여러 화면/컴포넌트에서 EmotionTag→Emotion 전환
feature/edit/.../EmotionEditPresenter.kt, EmotionEditUi.kt, EmotionEditUiState.kt; feature/record/.../RecordRegisterPresenter.kt, RecordRegisterUiState.kt, EmotionStep.kt
타입 및 필드명 EmotionTagEmotion, emotionTagsemotions, 선택/이벤트 페이로드 타입 업데이트, 이미지/그래픽 참조를 emotion.graphicRes로 변경
버전 카탈로그 업데이트
gradle/libs.versions.toml
compose-stability-analyzer 버전 0.4.1 → 0.4.2

Sequence Diagram(s)

sequenceDiagram
  participant Model as core.model.Emotion
  participant DS as core.designsystem (확장 속성)
  participant UI as Feature UI

  Note over Model,DS: 색상 매핑 위치 변경
  UI->>Model: 감정(enum) 사용 (예: emotion / emotion.name)
  Model->>DS: 요청 (확장 속성 접근)
  DS-->>UI: `bgColor`, `textColor`, `graphicRes` 반환
  UI->>UI: 색상/이미지 적용
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 분

  • 주의할 파일/영역:
    • 프로젝트 전체에서 삭제된 core/common/.../Emotion.kt의 기존 확장 함수 참조 검색
    • EmotionTag 제거에 따른 외부/테스트 사용처 컴파일 오류 확인
    • emotionTagemotion 이름 변경이 직렬화/네비게이션/스크린 인자 계약에 미치는 영향 검토
    • 디자인시스템의 색상 매핑 값(테마 색상과 일치하는지) 비교 검증

Poem

🐰
감정이 옮겨간 새 둥지, 색이 반짝여
배지는 웃고 말엔 빛이 돌아요
작은 발로 폴짝폴짝 축하해요
당근 한 움큼에 웃음 가득 🥕✨

Pre-merge checks and finishing touches

✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed PR 제목이 주요 변경사항을 명확하게 요약하고 있으며, designsystem 모듈로의 감정별 색상 매칭 로직 이동과 EmotionTag에서 Emotion 모델로의 전환을 잘 반영하고 있습니다.
Linked Issues check ✅ Passed PR이 연결된 이슈 #213의 요구사항을 완벽하게 충족했습니다. 감정 뱃지 컬러를 각 감정에 매칭되는 색상으로 수정했으며, designsystem 모듈에 색상 매핑 로직을 재배치하여 올바른 색상이 적용되도록 구현했습니다.
Out of Scope Changes check ✅ Passed 모든 변경사항이 감정별 색상 매칭 수정과 관련된 범위 내에 있습니다. EmotionTag 제거, Emotion 모델 통합, 확장 함수 재배치, gradle 버전 업데이트 등이 포함되어 있으나, 이는 모두 색상 매칭 문제 해결을 위한 구조적 개선으로 볼 수 있습니다.
✨ 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 BOOK-417-fix/#213

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

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3d04ed5 and cd7107c.

📒 Files selected for processing (1)
  • gradle/libs.versions.toml (1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: easyhooon
Repo: YAPP-Github/Reed-Android PR: 88
File: feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/component/RecordItem.kt:29-37
Timestamp: 2025-07-31T23:17:40.054Z
Learning: Reed-Android 프로젝트에서는 API가 준비되지 않은 상황에서 UI를 먼저 구현하고, API 연동 시점에 하드코딩된 데이터를 실제 데이터로 교체하는 개발 방식을 사용한다. RecordItem 컴포넌트의 emotionTags 매개변수도 API 연동 시점에 `text = emotionTags.joinToString(separator = "·") { "#$it" }`로 적용될 예정이다.

Comment thread gradle/libs.versions.toml
compose-effects = "0.1.1"
compose-shadow = "2.0.4"
compose-stability-analyzer = "0.4.1"
compose-stability-analyzer = "0.4.2"
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 | 🔴 Critical

🧩 Analysis chain

compose-stability-analyzer 버전 업그레이드의 필요성 검증 필요

compose-stability-analyzer가 0.4.1에서 0.4.2로 패치 버전 업그레이드되었습니다. 이는 일반적으로 안전한 마이너 변경이지만, PR의 주요 변경사항(감정 색상 매핑 리팩토링)과의 연관성이 명확하지 않습니다.


🌐 Web query:

compose-stability-analyzer 0.4.2 변경사항 및 주요 업데이트 내용

💡 Result:

요청하신 버전(0.4.2)은 공식 릴리스에서 확인되지 않습니다. 현재 GitHub 릴리스의 최신 태그는 0.4.1(2025‑11‑02)이며, 해당 릴리스의 주요 변경사항은 아래와 같습니다: IntelliJ 플러그인 및 모듈 테스트 추가, Kotlin 컴파일러 플러그인 지원 관련 클래스(KotlinCompilerPluginSupportPlugin) 도입 및 StabilityInferred 어노테이션 검사 조정, 배포 준비 등. 자세한 로그는 GitHub 릴리스 노트를 확인하세요. [1]

원하시면 0.4.2 릴리스 여부를 계속 모니터링하거나(발행 시 알림) 0.4.1의 전체 변경내역(커밋/PR 링크 포함)을 내려받아 요약해 드리겠습니다.

출처: GitHub Releases — skydoves/compose-stability-analyzer. [1]

[1] https://github.com/skydoves/compose-stability-analyzer/releases


존재하지 않는 버전 0.4.2로 인한 빌드 실패 위험

compose-stability-analyzer의 최신 공식 릴리스는 0.4.1(Kotlin 2.2.21과 함께)이며, 0.4.2 버전은 공식 릴리스에서 확인되지 않습니다. 버전 카탈로그에 존재하지 않는 버전을 지정하면 Gradle 빌드가 실패할 가능성이 높습니다.

필수 조치:

  • 버전을 0.4.1로 수정하거나, 0.4.2가 실제로 필요한 경우 해당 버전의 공식 릴리스 일정 확인 필요
  • 감정 색상 매핑 리팩토링과 이 도구의 버전 업그레이드 간 연관성 검토
🤖 Prompt for AI Agents
gradle/libs.versions.toml lines 27-27: 현재 compose-stability-analyzer = "0.4.2"로
지정되어 있으나 공식 릴리스는 0.4.1까지 확인되므로 빌드 실패 위험이 있습니다; 버전을 "0.4.1"로 롤백하거나 0.4.2가 실제로
존재하고 필요한 경우 공식 릴리스/요구사항을 확인해 정식 버전으로 업데이트하고, 감정 색상 매핑 리팩토링과 버전 업그레이드 사이의 연관성을
검토해 호환성 문제가 없는지 확인하세요.

@easyhooon
Copy link
Copy Markdown
Contributor Author

easyhooon commented Nov 4, 2025

@seoyoon513 Emotion 확장 함수들 designsystem 모듈로 옮겨서 designsystem 모듈에 정의해둔 color 변수들 사용하는 방식으로 변경 하였습니다. 생각해보니 확장 함수를 꼭 common 모듈내에 extensions 패키지에만 정의해야만 사용할 필요는 없을 것 같더라구요.

확장 함수의 성격이 각 Emotion에 따라 color를 지정하는 것이므로 designsystem 모듈의 역할과도 맞닿아 있는 것 같습니다.

@seoyoon513
Copy link
Copy Markdown
Contributor

@easyhooon 동의합니다! designsystem 모듈에 EmotionTag 이넘 클래스를 만든 이유가 Emotion과 관련된 모든 디자인 리소스를 통합 관리하면 좋겠다 라는 이유에서였는데요. model 모듈에 서버 모델을 따로 두고 디자인 리소스는 확장 함수로 접근하는 방식(지훈님 설계)으로 통일시키는 게 좋을 것 같습니다 ㅎㅎ

  • model: 서버 문자열 ↔ enum 변환 담당
  • designsystem: ui 리소스 관리

2차 서비스 고도화 때 해당 부분 변경이 반드시 있을 텐데 수정 포인트가 흩어져 있어서요. EmotionTag 의존하는 부분은 제가 수정했습니다~

Copy link
Copy Markdown
Contributor

@seoyoon513 seoyoon513 left a comment

Choose a reason for hiding this comment

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

LGTM

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: 0

🧹 Nitpick comments (1)
feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/component/RecordCard.kt (1)

30-30: 타입 안정성 개선을 고려해보세요.

현재 emotion: String 파라미터를 받고 displayName과 문자열 비교를 하고 있습니다. emotion: Emotion 타입을 직접 받도록 변경하면 타입 안정성이 향상되고, when 표현식에서 enum 값을 직접 비교할 수 있습니다.

예시:

 internal fun RecordCard(
     quote: String,
     bookTitle: String,
-    emotion: String,
+    emotion: Emotion,
     modifier: Modifier = Modifier,
 ) {
 
-private fun getEmotionCardImage(emotion: String): Int {
+private fun getEmotionCardImage(emotion: Emotion): Int {
     return when (emotion) {
-        Emotion.WARM.displayName -> R.drawable.img_record_card_warm
-        Emotion.JOY.displayName -> R.drawable.img_record_card_joy
-        Emotion.SAD.displayName -> R.drawable.img_record_card_sad
-        Emotion.INSIGHT.displayName -> R.drawable.img_record_card_insight
-        else -> R.drawable.img_record_card_warm
+        Emotion.WARM -> R.drawable.img_record_card_warm
+        Emotion.JOY -> R.drawable.img_record_card_joy
+        Emotion.SAD -> R.drawable.img_record_card_sad
+        Emotion.INSIGHT -> R.drawable.img_record_card_insight
     }
 }
 
 private fun RecordCardPreview() {
     ReedTheme {
         RecordCard(
             quote = "...",
             bookTitle = "샤이닝",
-            emotion = Emotion.WARM.displayName,
+            emotion = Emotion.WARM,
         )
     }
 }

Also applies to: 77-84

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cd7107c and a8b5f54.

📒 Files selected for processing (15)
  • core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/Emotion.kt (1 hunks)
  • core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/EmotionTag.kt (0 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/BookDetailPresenter.kt (1 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardPresenter.kt (1 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUi.kt (1 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUiState.kt (1 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/component/RecordCard.kt (3 hunks)
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/record/RecordDetailPresenter.kt (1 hunks)
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditPresenter.kt (3 hunks)
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUi.kt (5 hunks)
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUiState.kt (2 hunks)
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterPresenter.kt (4 hunks)
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterUiState.kt (3 hunks)
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/step/EmotionStep.kt (6 hunks)
  • feature/screens/src/main/kotlin/com/ninecraft/booket/feature/screens/Screens.kt (1 hunks)
💤 Files with no reviewable changes (1)
  • core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/EmotionTag.kt
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: easyhooon
Repo: YAPP-Github/Reed-Android PR: 88
File: feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/component/RecordItem.kt:29-37
Timestamp: 2025-07-31T23:17:40.054Z
Learning: Reed-Android 프로젝트에서는 API가 준비되지 않은 상황에서 UI를 먼저 구현하고, API 연동 시점에 하드코딩된 데이터를 실제 데이터로 교체하는 개발 방식을 사용한다. RecordItem 컴포넌트의 emotionTags 매개변수도 API 연동 시점에 `text = emotionTags.joinToString(separator = "·") { "#$it" }`로 적용될 예정이다.
📚 Learning: 2025-07-31T23:17:40.054Z
Learnt from: easyhooon
Repo: YAPP-Github/Reed-Android PR: 88
File: feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/component/RecordItem.kt:29-37
Timestamp: 2025-07-31T23:17:40.054Z
Learning: Reed-Android 프로젝트에서는 API가 준비되지 않은 상황에서 UI를 먼저 구현하고, API 연동 시점에 하드코딩된 데이터를 실제 데이터로 교체하는 개발 방식을 사용한다. RecordItem 컴포넌트의 emotionTags 매개변수도 API 연동 시점에 `text = emotionTags.joinToString(separator = "·") { "#$it" }`로 적용될 예정이다.

Applied to files:

  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUiState.kt
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/record/RecordDetailPresenter.kt
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUiState.kt
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterUiState.kt
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardPresenter.kt
  • feature/screens/src/main/kotlin/com/ninecraft/booket/feature/screens/Screens.kt
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/BookDetailPresenter.kt
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUi.kt
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUi.kt
  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/component/RecordCard.kt
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/step/EmotionStep.kt
  • feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditPresenter.kt
  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterPresenter.kt
📚 Learning: 2025-07-31T23:30:37.547Z
Learnt from: easyhooon
Repo: YAPP-Github/Reed-Android PR: 88
File: feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/record/RecordDetailPresenter.kt:18-47
Timestamp: 2025-07-31T23:30:37.547Z
Learning: In Circuit architecture, presenters receive the Screen object directly as a constructor parameter (e.g., Assisted private val screen: RecordDetailScreen), and screen parameters are accessed through this screen object (e.g., screen.recordId). Screen parameters should not be added as separate constructor parameters.

Applied to files:

  • feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/BookDetailPresenter.kt
📚 Learning: 2025-08-28T12:25:54.058Z
Learnt from: easyhooon
Repo: YAPP-Github/Reed-Android PR: 174
File: feature/search/src/main/kotlin/com/ninecraft/booket/feature/search/book/BookSearchPresenter.kt:128-133
Timestamp: 2025-08-28T12:25:54.058Z
Learning: In BookSearchPresenter.kt, when a guest user tries to register a book and is redirected to login, the bottom sheet (isBookRegisterBottomSheetVisible) and selection state (selectedBookIsbn, selectedBookStatus) are intentionally kept open/preserved so that when the user returns from login, they can continue from where they left off without losing context.

Applied to files:

  • feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterPresenter.kt
🧬 Code graph analysis (2)
feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUi.kt (1)
feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/step/EmotionStep.kt (1)
  • EmotionItem (123-158)
feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/step/EmotionStep.kt (1)
core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/theme/Theme.kt (1)
  • ReedTheme (14-21)
⏰ 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: Compose Stability Check
  • GitHub Check: ci-build
🔇 Additional comments (13)
feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUiState.kt (1)

3-3: LGTM! 감정 모델 마이그레이션이 올바르게 적용되었습니다.

EmotionTag 타입에서 Emotion 모델로의 전환이 깔끔하게 처리되었습니다. 필드명도 emotionTags에서 emotions로 일관성 있게 변경되었습니다.

Also applies to: 12-12

feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditUi.kt (1)

32-35: LGTM! UI 컴포넌트가 새로운 Emotion 모델을 올바르게 사용하고 있습니다.

모든 변경사항이 일관성 있게 적용되었습니다:

  • emotion.displayName을 통한 감정명 접근
  • emotion.graphicRes를 통한 리소스 참조
  • Preview 코드도 Emotion.entries 사용으로 업데이트

Also applies to: 104-110, 133-133, 160-160, 172-176

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/record/RecordDetailPresenter.kt (1)

130-130: LGTM! RecordCardScreen 파라미터명이 올바르게 업데이트되었습니다.

emotionTag에서 emotion으로의 파라미터명 변경이 일관성 있게 적용되었습니다.

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardPresenter.kt (1)

77-77: LGTM! UI 상태 매핑이 올바르게 업데이트되었습니다.

Screen 객체의 emotion 필드를 UI 상태로 전달하는 로직이 정확하게 반영되었습니다.

feature/screens/src/main/kotlin/com/ninecraft/booket/feature/screens/Screens.kt (1)

82-82: LGTM! Screen 파라미터명이 일관성 있게 변경되었습니다.

RecordCardScreen의 파라미터명이 emotionTag에서 emotion으로 명확하게 업데이트되어 전체 리팩토링과 일치합니다.

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUiState.kt (1)

14-14: LGTM! UI 상태 필드가 올바르게 리네이밍되었습니다.

emotionTag에서 emotion으로의 필드명 변경이 깔끔하게 처리되었습니다.

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/card/RecordCardUi.kt (1)

86-86: LGTM! RecordCard 컴포넌트 호출이 올바르게 업데이트되었습니다.

state.emotion 값을 emotion 파라미터로 전달하는 로직이 정확하게 반영되었습니다.

feature/detail/src/main/kotlin/com/ninecraft/booket/feature/detail/book/BookDetailPresenter.kt (1)

309-309: LGTM! RecordCardScreen 생성 로직이 올바르게 업데이트되었습니다.

감정 정보를 emotion 파라미터로 전달하는 부분이 정확하게 반영되어 전체 리팩토링과 일치합니다.

feature/edit/src/main/kotlin/com/ninecraft/booket/feature/edit/emotion/EmotionEditPresenter.kt (1)

9-9: 타입 마이그레이션이 올바르게 적용되었습니다.

EmotionTag에서 Emotion으로의 변경이 일관되게 적용되었으며, import, entries 사용, 그리고 UI 상태 전달 모두 정확합니다.

Also applies to: 28-28, 53-53

feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterPresenter.kt (1)

17-17: Emotion 타입으로의 마이그레이션이 정확합니다.

API 호출 시 selectedEmotion?.displayName을 사용하여 서버와 통신하는 부분이 적절하며, 상태 관리에서도 Emotion 타입이 일관되게 사용되고 있습니다.

Also applies to: 76-77, 257-257, 295-295

core/designsystem/src/main/kotlin/com/ninecraft/booket/core/designsystem/Emotion.kt (1)

14-36: 확장 속성을 통한 색상 매핑이 잘 구현되었습니다.

감정별 배경색, 텍스트 색상, 그래픽 리소스를 Emotion 확장 속성으로 designsystem 모듈에 통합한 것은 좋은 설계 결정입니다. 순환 참조 문제를 해결하면서도 하드코딩을 제거하여 유지보수성이 향상되었습니다. when 표현식이 모든 Emotion 값을 처리하므로 타입 안전성도 보장됩니다.

Based on PR objectives

feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/register/RecordRegisterUiState.kt (1)

6-6: UI 상태와 이벤트의 타입 변경이 일관되게 적용되었습니다.

emotions, selectedEmotion, 그리고 OnSelectEmotion 이벤트 페이로드가 모두 Emotion 타입을 사용하도록 올바르게 업데이트되었습니다.

Also applies to: 19-20, 49-49

feature/record/src/main/kotlin/com/ninecraft/booket/feature/record/step/EmotionStep.kt (1)

32-32: 감정 선택 UI가 새로운 Emotion 타입과 확장 속성을 올바르게 활용하고 있습니다.

emotion.graphicRes 확장 속성을 사용하여 그래픽 리소스를 가져오는 부분이 깔끔하게 구현되었으며, UI 상태와 프리뷰 모두 일관되게 업데이트되었습니다.

Also applies to: 35-35, 48-48, 89-89, 125-125, 152-152, 163-163, 168-168

@easyhooon
Copy link
Copy Markdown
Contributor Author

2차 서비스 고도화 때 해당 부분 변경이 반드시 있을 텐데 수정 포인트가 흩어져 있어서요. EmotionTag 의존하는 부분은 제가 수정했습니다~

오우 emotionTag 쓰는 부분이 제법 많아서 emotion으로의 완전 대체가 살짝 조심스러웠는데, 속이 다 시원하네여~

@easyhooon easyhooon merged commit a41d39c into develop Nov 5, 2025
4 checks passed
@easyhooon easyhooon deleted the BOOK-417-fix/#213 branch November 5, 2025 06:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞 fix Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BOOK-417/fix] 도서 상세 화면 감정 뱃지 컬러 수정

2 participants