You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
이 PR은 로딩/에러 상태 관리 아키텍처를 대폭 리팩토링하고, 전체 기능 화면의 렌더링 패턴을 일관되게 개선합니다. 기존의 단일 LoadableState 인터페이스를 DefaultLoadableState(최소 계약)와 ContentLoadableState(콘텐츠 로드 추적)로 계층화하여 상태 관리를 단순화합니다. BaseViewModel의 상태 감소 로직도 새로운 인터페이스에 맞게 개선되고, 로딩 상태를 미업데이트하면서 결과를 처리하는 헬퍼가 추가됩니다. 로그인, 목표, 홈, 통계, 알림, 온보딩, 포토로그, 설정 등 거의 모든 기능의 UI 상태가 새 인터페이스로 마이그레이션되며, 각 화면은 초기 로딩, 에러, 오버레이 로딩 상태를 일관되게 렌더링하고 재시도 기능을 지원합니다. 온보딩 기능의 경우 커플 연결, 프로필, 디데이, 마케팅 동의 등 세분화된 로딩 액션을 추적하여 더 정확한 UI 피드백을 제공합니다. 추가로 깊은 링크 도메인이 새 값으로 통일됩니다.
Estimated code review effort
🎯 4 (Complex) | ⏱️ ~60 minutes
주요 리뷰 포인트
✅ 좋은 점
명확한 아키텍처 전환: DefaultLoadableState와 ContentLoadableState의 계층 분리가 상태 관리를 단순하고 재사용 가능하게 만들었습니다. 최소 계약(isLoading, error)과 확장된 계약(hasLoadedContent)을 분리한 설계가 적절합니다.
일관된 화면 렌더링 패턴: 거의 모든 기능 화면이 동일한 분기 패턴(showLoading → TwixLoadingOverlay, showError → ErrorScreen, else → 정상 화면)을 따르도록 개선되어 코드 가독성과 유지보수성이 높아졌습니다.
세분화된 로딩 상태 추적: OnBoarding의 OnBoardingLoadingAction 추가로 커플 연결, 프로필 제출 등 각 단계의 로딩 상태를 독립적으로 추적할 수 있게 되어 사용자 경험이 개선될 것으로 보입니다.
초기 로딩 vs 재조회 로딩 구분: hasLoadedContent 플래그로 초기 로딩(전체 화면 로딩 표시)과 재조회 로딩(오버레이만 표시)을 명확히 구분합니다.
⚠️검토가 필요한 부분
상태 기본값 변경의 영향 범위
많은 UI 상태에서 isLoading의 기본값이 false → true로 변경되었습니다. (예: GoalManageUiState, OnBoardingUiState)
질문: 이렇게 기본값을 true로 설정한 이유는 무엇인가요? 화면 진입 시 항상 로딩 상태로 표시하려는 의도인지, 아니면 초기화 로직과 함께 명시적으로 false로 설정하는 방식이 의도인지 명확히 하면 좋겠습니다.
copyLoadableState → copyState 마이그레이션의 완전성
일부 파일에서는 아직 참조가 남아있을 수 있습니다. 컴파일 타임에 모든 오버라이드가 감지되겠지만, 모든 UI 상태가 일관되게 마이그레이션되었는지 재확인해주세요.
제안: 마이그레이션 후 컴파일 테스트 결과를 첨부하면 리뷰 신뢰도가 높아질 것 같습니다.
BaseViewModel의 handleResultWithoutLoadableStateUpdate의 사용 범위
현재 알림 읽음 처리, 반응 처리 등 "best effort" 작업에만 사용되고 있습니다.
질문: 향후 다른 기능에서 이 헬퍼를 사용할 때 가이드라인이 필요할까요? 언제 로딩 상태를 업데이트하지 말아야 하는지 문서화하는 것도 좋겠습니다.
에러 처리의 조건부 로직
HomeViewModel, StatsViewModel, GoalManageViewModel에서 shouldShowErrorScreen 또는 !hasLoadedContent 기반의 복잡한 에러 토스트 제어가 있습니다.
검토 대상: GoalManageViewModel의 fetchGoalSummaryList(date, showInitialLoading, showToastOnError) 처럼 3개 파라미터 메서드가 추가되었는데, 호출 지점이 많을수록 실수 가능성이 높습니다. 인라인 람다나 명명된 파라미터 사용으로 가독성을 더 높일 수 있을까요?
온보딩 액션 가드의 일관성
connectCouple, profileSetup, anniversarySetup, initNotificationSettings 모두 currentState.loadingAction 존재 여부를 확인하고 있습니다.
제안: 공통 가드 헬퍼(ensureNoLoadingActionInProgress() 같은)로 추상화하면 중복 코드를 줄일 수 있을 것 같습니다.
깊은 링크 도메인 변경의 배포 타이밍
AndroidManifest.xml과 InviteLaunchDispatcher 모두에서 도메인이 변경되었습니다.
질문: 웹서버의 도메인 지원이 먼저 준비되어 있나요? 도메인 변경 후 기존 사용자의 초대 링크가 깨질 수 있으므로, 배포 순서와 폴백 처리를 확인해주세요.
📝 개선 제안
UI 상태 초기값 명시화 isLoading = true 기본값이 있으면, 각 뷰모델의 init 블록에서 명시적으로 isLoading = false로 설정하는 주석을 추가하면 의도가 더 명확해집니다.
에러 처리 표준화 hasLoadedContent가 false일 때와 true일 때의 에러 표시 차이를 일관된 규칙으로 문서화하면, 향후 새로운 기능 추가 시 에러 처리 로직을 쉽게 따를 수 있을 것 같습니다.
온보딩 로딩 액션 확장성 OnBoardingLoadingAction enum이 현재 4개 항목인데, 향후 새로운 온보딩 단계가 추가될 때 이 enum과 동반 변경 필요성이 생길 것 같습니다. Sealed class나 더 유연한 설계를 검토해볼 가치가 있을 것 같습니다.
✨ Finishing Touches📝 Generate docstrings
Create stacked PR
Commit on current branch
🧪 Generate unit tests (beta)
Create PR with unit tests
Commit unit tests in branch feature/#162-onboarding-anniversary-policy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
이슈 번호
#162
작업내용
결과물
리뷰어에게 추가로 요구하는 사항 (선택)