[feat] 신규 UI ViewModel 연결 (#111)#112
Merged
Merged
Conversation
8개 알림 토글(푸시/소리/진동/수강신청/과제마감/성적발표/채플/마케팅)을 VM 내부 StateFlow로 관리하도록 구현 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
hiltViewModel() 기반 stateful 오버로드 추가, uiState를 기존 stateless 컴포저블에 위임 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
알림 데이터 소스가 없어 VM 내부 StateFlow로 탭 선택/알림목록/ 미읽음 수를 관리. 탭별 필터와 읽음 처리 로직 포함 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
hiltViewModel() 래퍼 추가, 미읽음 수/탭 선택 상태를 VM에서 받아 표시. 탭 클릭으로 선택 전환 가능하도록 변경 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
성적 알림은 기존 UserDataRepository.notificationEnabled에 영속화, 캠퍼스 알림은 대응 필드가 없어 VM 상태로 관리. 로그아웃은 기존 SettingViewModel과 동일하게 전 Repository clear (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
로컬 remember 상태를 MyPageViewModel로 이관. 로그아웃 행에 핸들러 연결(viewModel.logout + onLogoutClick), 성적/캠퍼스 알림 토글을 VM 상태에 바인딩. 프리뷰는 stateless content로 분리 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ReportCardRepository.semesterWithLectures를 조합해 학기 탭, GPA 추이, 선택 학기의 강의 목록/평점/학점/석차를 산출. gradeStyle()로 성적 색상 매핑, 선택 학기 상태 관리 및 init 시 자동 fetch (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
하드코딩 기본값을 stateless 오버로드 + 프리뷰로 분리하고, hiltViewModel() 기반 entry에서 GradeViewModel.uiState를 바인딩. 학기 탭 클릭을 viewModel.onTabClick으로 연결 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
StudentData/ReportCardSummary/학기별 GPA/Chapel을 조합한 대시보드 상태. 프로필, GPA 히어로, 학기별 GPA 막대(높이 환산), 채플 출석(출석 수 집계) 산출. init 시 학생/성적/채플 자동 fetch (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
하드코딩 프리뷰 데이터 대신 MainViewModel.uiState를 MainPageScreen에 바인딩. 차트/채플 상세 콜백 파라미터 추가, 프리뷰는 별도 분리 (#111) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
스크롤 콘텐츠 bottom 패딩을 16dp→110dp로 늘려 오버레이 TabBar에 가려지던 채플 카드까지 스크롤되도록 함 (MyPage와 동일 컨벤션) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
TabItem 내부 Column 세로 패딩 6dp→4dp로 줄여 아이콘+라벨이 탭바 높이 안에서 잘리지 않도록 함 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
탭 진입 화면이라 뒤로가기 화살표와 우측 info 아이콘이 불필요해 '채플' 타이틀만 남김 (함수 시그니처는 호출부 호환 위해 유지) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
QR 출석 인증 기능 구현 전까지 AttendanceCta 호출을 비활성화 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
한 학기 채플 이수는 최대 7회이므로 AttendanceGauge에서 total을 7로 clamp하고 남은 횟수를 음수 방지 처리. 기본값도 7회 기준으로 조정 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
StudentDataRepository를 주입해 학적 상태가 '휴학'이면 true인 isOnLeave StateFlow 추가 (휴학생 채플 안내용) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ChapelViewModel.isOnLeave를 구독해 휴학 중이면 좌석/출석 게이지 대신 '휴학 중이라 수강할 채플이 없어요' 안내 화면을 표시 (#111 연계) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ChapelHeader 타이틀 18sp→22sp, letterSpacing도 알림과 동일하게 맞춤 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
SettingsHeader 타이틀 24sp→22sp (lineHeight 28sp) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
학기별 GPA가 담긴 Semester 테이블을 즉시 전체 조회하는 semesters Flow 추가. 강의 적재를 기다리는 semesterWithLectures와 달리 차트가 한 번에 렌더되도록 하기 위함 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- 차트 데이터를 semesterWithLectures(점진 로드)→semesters(즉시 전체)로 변경 해 과거 학기 GPA가 한 번에 실제값으로 표시되도록 함 - 막대 높이를 GPA 0 기준 비례로 변경(floor 6dp)해 바닥 정렬 시 비교 가능 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
값 라벨(GPA) 영역을 고정 높이(16dp)로 예약하고 막대를 하단 고정 플롯 영역에 배치해, 현재 학기 막대만 아래로 밀려 바닥선이 어긋나던 문제 수정. 모든 막대가 같은 바닥선을 공유해 높이 비교 가능 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
학기 탭과 GPA 추이를 semesters(즉시 전체 로드)에서 산출하고, 강의 목록만 semesterWithLectures에서 year/semester 매칭으로 가져오도록 변경. 과거 학기가 천천히 채워지던 문제 해소 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
긴 제목이 교수/학점/성적 배지를 밀어내 UI가 깨지던 문제 수정. 좌측 정보 Row를 weight로 제약하고 제목에 maxLines=1 + Ellipsis 적용, 배지가 항상 보이도록 함 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
좌석 상세 화면을 ChapelScreen에서 호출할 수 있도록 가시성 공개 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- ChapelViewModel.chapelUiState의 chapelCard에서 실제 출석/지각 일수와 좌석번호/층/장소를 가져와 표시(하드코딩 제거), 남은 출석은 7회 기준 - '좌석 위치 보기' 탭 시 MySeatLocationScreen으로 전환, 뒤로가기로 복귀 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
가장 최근 학기의 평점/취득학점/과목수/강의목록을 산출. 해당 학기에 강의(성적)가 적재되지 않았으면 미등록으로 보고 모든 값을 '?'로 노출. 차트는 semesters, 강의 목록은 semesterWithLectures를 함께 결합 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
이번 학기 성적/취득/과목/강의목록을 인자로 받아 렌더하고, 미등록이면 평점·취득·과목을 '?'로, 강의 목록 대신 '아직 등록된 성적이 없어요' 안내를 표시. onDismissRequest로 닫기 처리 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
GpaHeroCard '이번 학기 성적보기'는 GradeBottomSheet를 띄우고, GpaChartCard '자세히'는 onChartDetailClick(성적 상세)로 연결 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
MainScreen 호출 시 navigateToGradeDetail를 onChartDetailClick에 연결 (이번 학기 성적보기는 바텀시트로 처리되므로 onGradeDetailClick 미사용) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
GradeBottomSheet(ModalBottomSheet) 호출을 위한 opt-in Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- 전체 학기 추이(bar)에서 휴학(시도·취득 0학점) 학기 제외 - P/F 전용 학기(평점 0, 이수학점>0)는 직전 성적을 유지(carry-forward) - 이번 학기가 휴학이면 currentSemesterOnLeave=true 노출 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
성적 상세의 성적 추이(gpaPoints)에서 휴학(미수강) 학기를 제외하고, P/F 전용 학기는 직전 성적을 유지(carry-forward)해 추이가 0으로 떨어지지 않도록 함. 탭 목록은 전체 학기 유지 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
onLeave=true면 '이번 학기는 휴학이에요', 아니면 '아직 등록된 성적이 없어요'를 표시 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
MainViewModel.currentSemesterOnLeave를 GradeBottomSheet onLeave로 연결 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
DB 최신 학기 행 대신 GetCurrentSemesterUseCase로 현재 학기를 판별. 현재 학기가 아직 DB에 없어 25-2 등으로 잘못 표시되던 문제 수정. 성적 미등록 시 학기명은 유지하고 평점/취득/과목만 ?로 표시 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
선택 학기의 강의(성적)가 적재되었는지 여부를 노출. 성적 미공개 학기에 '아직 등록된 성적이 없어요' 안내를 위한 플래그 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
선택 학기 성적이 공개되지 않았으면(registered=false) GPA 카드/강의목록 대신 안내 문구를 표시하고 성적 추이는 유지 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
#️⃣ 연관된 이슈
Close #111
📝 작업 내용
PR #110에서 새로 추가된 UI(Screen)들에 대해 선언만 되어있고 비어있던 ViewModel들을 구현하고 Screen에 연결했습니다. 기존 Repository / DataStore를 우선 재사용했습니다.
이슈 명시 ViewModel 구현
NotificationSettingViewModel상태 구현 + Screen 연결 래퍼PushNotificationsViewModel상태 구현 + Screen 연결MyPageViewModel구현 + Screen 연결GradeViewModel구현 + GradeDetailScreen 연결MainViewModel구현 + MainScreen 연결채플 탭
ChapelViewModel에 실제 출석/좌석 데이터 연결 + 좌석 상세 화면 진입isOnLeave) 노출 → 휴학생에게 "수강할 채플 없음" 안내성적 / 홈
ReportCardRepository에 전체 학기 목록(semesters) Flow 추가?, 휴학 안내기타 UI 수정
MainScreenExperimentalMaterial3Apiopt-in,GpaChartCardimport 누락 수정 등