feat(platform): 기한을 긴급·중간·여유 3단계 색상으로 구분#87
Merged
Conversation
근로자 목록 기한 뱃지와 업무함 rail 색상이 날짜 차이와 무관하게 동일한 색으로 표시되고 있었다. Figma(node-id=935-2)에도 세분화된 기준이 없어 직접 임계값을 정해 공통 유틸 src/utils/urgency.ts를 추가했다. - 긴급(critical): D-day 7일 이내 - 중간(warning): D-day 8~30일 - 여유(success): D-day 31일 이상, 또는 임박한 기한 없음 WorkerListPage의 deadlineHighlighted(boolean)를 deadlineDays 기반 3단계 색상으로 대체하고, WorkListPage의 정적 urgency 필드를 dueDays로부터 파생하도록 바꿔 데이터 불일치 가능성을 없앴다. Closes #86
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.
개요
근로자 목록 기한 뱃지(D-12/D-21/D-35/D-62/정상)와 업무함 rail 색상이 날짜 차이와 무관하게 동일하게 표시되고 있었다. Figma(node-id=935-2, PEOPLE-001/WORK-001)에도 세분화된 기준이 없어 직접 임계값을 정했다.
기준
변경 사항
src/utils/urgency.ts신규:getUrgencyTier,URGENCY_TONE,URGENCY_LABELWorkerListPage:deadlineHighlighted(boolean, 이진 판정) 제거 →deadlineDays기반 3단계 색상으로 대체. 리스트 행 텍스트 색상 + 상세 패널StatusLabel톤 모두 적용 (여유 등급은 뱃지 생략, 기존과 동일하게 시각 노이즈 최소화)WorkListPage: 정적urgency필드 제거 →dueDays로부터 파생.WorkItemRow의 기존 warning/critical/neutral 팔레트에 매핑해 rail 색상 자동 반영urgency.test.ts유닛 테스트, 각 페이지에 색상 클래스 검증 테스트 추가검증
npm run lintnpm run test(전체 100개 통과)npm run buildCloses #86