Skip to content

[Feat] 마이페이지 홈 ViewModel 및 UI 상태 구현 - #51

Open
Moony-H wants to merge 5 commits into
feature/create-fake-repositoryfrom
feature/create-mypage-viewmodel
Open

[Feat] 마이페이지 홈 ViewModel 및 UI 상태 구현#51
Moony-H wants to merge 5 commits into
feature/create-fake-repositoryfrom
feature/create-mypage-viewmodel

Conversation

@Moony-H

@Moony-H Moony-H commented Jul 31, 2026

Copy link
Copy Markdown
Collaborator

관련 이슈

작업 내용

마이페이지 홈 화면의 ViewModel과 UI 상태를 Orbit MVI로 구현했습니다.

변경사항 / 상세

  • feature:mypage 모듈 신설, todakun.feature 컨벤션 플러그인 적용
  • MyPageHomeUiState: Loading/Success/Fail sealed 상태
  • MyPageHomeUiModel: User + SajuPalja를 화면에 필요한 형태로 묶은 UI 모델
  • MyPageHomeSideEffect: 현재 케이스 없는 side effect 마커 (필요 시 확장)
  • MyPageHomeViewModel: GetMyPageInfoUseCase를 호출해 containerrepeatOnSubscription에서 로드하고, 성공/실패를 reduce로 반영
  • reduceIfSuccess: 상태가 Success일 때만 안전하게 부분 업데이트하기 위한 헬퍼 (아직 호출부 없음)

중점 리뷰사항

  • repeatOnSubscription에서 매 구독마다 loadMyPageInfo()가 다시 호출되는데, 이미 Success인 상태에서도 재요청되는 게 의도된 동작인지 (예: 화면 재진입 시 새로고침 vs 캐시 유지)
  • reduceIfSuccess가 아직 미사용이라 추후 실제 intent(새로고침 등)에서 사용 예정

스크린샷 (선택)

N/A (ViewModel/상태 레이어 전용 변경, UI는 별도 작업)

Moony-H added 3 commits July 31, 2026 18:32
* feat: add MyPageHomeViewModel using Orbit MVI
* feat: define MyPageHomeUiState, MyPageHomeUiModel, and MyPageHomeSideEffect
@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 3597fbe7-ddfd-42ea-8d11-733ef802a94f

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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.

Moony-H added 2 commits July 31, 2026 19:35
* chore: feature:mypage 모듈 내 코드 포맷팅 및 임포트 정리
* chore: MyPageHomeViewModel 및 UI State 클래스 스타일 수정
@Moony-H Moony-H self-assigned this Jul 31, 2026
@Moony-H
Moony-H marked this pull request as draft July 31, 2026 10:39
@Moony-H
Moony-H requested a review from oungsi2000 July 31, 2026 10:41
@Moony-H
Moony-H marked this pull request as ready for review July 31, 2026 10:43
Comment on lines +41 to +47
private suspend fun MyPageHomeSyntax.reduceIfSuccess(
reducer: MyPageHomeUiState.Success.() -> MyPageHomeUiState,
) {
reduce {
(state as? MyPageHomeUiState.Success)?.reducer() ?: state
}
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

이건 언제 쓰이나요?

Comment on lines +1 to +3
plugins {
id("todakun.feature")
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

저희 feature는 alias 말고 id로 가나요?

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.

2 participants