Draft
Conversation
1 task
Member
|
린트 확인해줘요! |
Member
Author
수정했습니다! |
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.
Related issue 🛠
Work Description ✏️
서버에서 날짜를 ISO 8601(UTC) 형태의 Datetime으로 통일해 내려주는 API 변경에 맞춰 클라이언트 날짜 처리 방식을 전면 개선했습니다.
알림:
publishedAtString →Instant로 변경, 포맷팅을 UiModel 매핑 시점으로 이동알림-상세:
createdAtString →Instant로 변경단어장-상세:
writtenFromString →Instant?+fromFeed: Boolean필드 분리 (API DTO 변경 반영)일기-확인:
writtenDateString →Instant로 변경, 한국어 날짜 문자열 역산 로직(parseKoreanFullDateToIso) 제거DateFormatter:
Instant기반 확장 함수 추가 및 KDoc 정비, 함수 그룹 재정렬각 레이어 경계에서의 포맷팅 책임 명확화 (Domain Model은
Instant보유, 표시용 String 변환은 Presentation Layer에서 수행)날짜 관련 단위 테스트 추가 (
DateFormatterTest,NotificationItemUiModelTest,VocaDetailUiModelTest)[흐름도 예시]
flowchart TD DTO["DTO\nString (ISO 8601)"] Domain["Domain Model\nInstant (timezone-agnostic)"] Mapper["UiModel Mapper / ViewModel\nInstant → 표시용 String\n(시스템 타임존 적용)"] UI["Composable\nString 수신 후 렌더링만"] DTO -->|"toUtcInstant()"| Domain Domain -->|"toKoreanFullDate()\ntoDotDate()\ntoShortYearDotDate()"| Mapper Mapper --> UIScreenshot 📸
Uncompleted Tasks 😅
UTC 기준 날짜 직접 전송 vs 헤더 타임존 + Datetime으로 서버 위임 및 날짜 형식 — 별도 논의 필요
To Reviewers 📢
Instant를 사용했고, 날짜 포맷 기반 변환 로직을 만들었습니다. 홈 캘린더, 일기 작성 쪽은 아직 서버랑 논의가 덜 끝나 LocalDate 로직을 모두 제거하지는 못했습니다.Instant를 보유하고 포맷팅은 전부 Presentation Layer에서 발생하도록 UDF 기준으로 책임을 정리했습니다.VocaDetailModel은writtenFrom: Instant?+fromFeed: Boolean으로 분리되어 기존 서버에서 가공해주던 텍스트("26.04.12 일기에서 저장됨")를 클라에서 직접 조합합니다. DTO 구조 변경이 포함되어 있으니 확인 부탁드립니다.fromFeed = false && writtenFrom = null케이스는 서버 스펙상 정상적으로 발생하지 않아야 하나, 방어 처리(Timber warning + 빈 문자열 반환)가 추가돼 있습니다.UnitTest코드를 따로 작성했는데 같이 올려보면 좋을지 여쭤보고 싶습니다..! 아직 서버에서 응답 변경이 이루어지지 않은 상태라 확인이 한계가 있네요..