refactor(auth-api): 사진 업로드 공통화 및 편집 화면 코드 품질 개선#114
Merged
Conversation
- 기존 `ProfileImageUploadRepository`를 삭제하고, 프로필, 영정 사진 등 다양한 이미지 업로드에 재사용할 수 있는 `PhotoUploadRepository`를 새로 구현했습니다. 이 리포지토리는 Presigned URL을 받아 S3에 이미지를 업로드하는 공통 로직을 담당합니다. - `UploadProfileImageUseCase`는 이제 새로운 `PhotoUploadRepository`를 사용하도록 수정되었습니다. - 애프터노트 '추모 가이드라인'에 영정 사진을 등록하고 수정하는 기능을 추가했습니다. - 사용자가 갤러리에서 영정 사진을 선택하면, 저장 시점에 `PhotoUploadRepository`를 통해 이미지를 업로드하고 반환된 URL을 서버로 전송합니다. - 상세 조회 API 응답에 `memorialPhotoUrl` 필드가 추가되었으며, 수정 시 이 값을 화면에 표시합니다. - 애프터노트 생성 및 수정 요청 DTO(`AfternotePlaylistDto`)에도 `memorialPhotoUrl` 필드를 추가했습니다. - `AfternoteEditViewModel`에서 영정 사진 URI(`content://`)를 실제 URL로 변환하는 로직을 추가하고, 저장 및 수정 관련 파라미터를 데이터 클래스(`SaveAfternoteMemorialMedia`)로 묶어 코드 가독성을 개선했습니다.
- 추모 가이드라인 상세 화면(`MemorialGuidelineDetailScreen`)에 '장례식에 남길 영상'을 표시하는 `VideoCard`를 추가했습니다. - 영상 URL이 없는 경우에는 카드가 표시되지 않습니다. - `VideoCard`는 제목과 썸네일로 구성되며, 썸네일 위에는 어두운 그라데이션 오버레이와 재생 아이콘이 표시됩니다. - 상세 정보 상태(`MemorialGuidelineDetailState`)에 영상 및 썸네일 URL 필드(`memorialVideoUrl`, `memorialThumbnailUrl`)를 추가하고, 내비게이션 시 `playlist` 데이터로부터 이 값들을 전달하도록 수정했습니다.
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.
목적 / 배경
변경 사항 요약
data/upload의PhotoUploadRepository(directory 파라미터)로 통합.UploadProfileImageUseCase,UploadMemorialPhotoUseCase가 동일 구현을 사용.content://상수화(S1192),SaveAfternoteMemorialMedia/MemorialMediaUrls로 파라미터 9개→6개·8개→6개 축소(S107),PhotoUploadRepository를 fun interface로 변경(S6517).주요 수정 파일
data/upload/PhotoUploadRepository.kt,PhotoUploadRepositoryImpl.ktfeature/afternote/presentation/screen/AfternoteEditViewModel.ktfeature/afternote/presentation/navgraph/AfternoteNavgraph.ktfeature/user/domain/usecase/UploadProfileImageUseCase.kt,feature/afternote/domain/usecase/UploadMemorialPhotoUseCase.kt테스트/검증
./gradlew :app:compileDebugKotlin,./gradlew ktlintCheck통과.Made with Cursor