diff --git a/frontend/src/app/components/HealthReport.tsx b/frontend/src/app/components/HealthReport.tsx index fc32eb0..a13d131 100644 --- a/frontend/src/app/components/HealthReport.tsx +++ b/frontend/src/app/components/HealthReport.tsx @@ -136,10 +136,9 @@ export default function HealthReport() {
{m.label}
diff --git a/frontend/src/app/components/PetProfileScreen.tsx b/frontend/src/app/components/PetProfileScreen.tsx index 2ef7573..748e4ca 100644 --- a/frontend/src/app/components/PetProfileScreen.tsx +++ b/frontend/src/app/components/PetProfileScreen.tsx @@ -1,42 +1,146 @@ +import { useEffect, useRef, useState } from 'react'; import { useNavigate } from 'react-router'; import MobileFrame from './MobileFrame'; import NavHeader from './NavHeader'; import BottomNav from './BottomNav'; -import { Edit2, RefreshCw, Heart, Scale, Syringe, Calendar, ChevronRight, Shield } from 'lucide-react'; +import { Edit2, RefreshCw, Heart, Scale, Calendar, ChevronRight, ChevronDown, Check, X, Camera } from 'lucide-react'; -const petStats = [ - { icon: '🏃', label: '이번 주 산책', value: '3회', sub: '총 85분', color: '#E8F0FA', iconBg: '#C5D8EE' }, - { icon: '🍖', label: '오늘 식사', value: '2회', sub: '권장량 100%', color: '#E8F5E9', iconBg: '#C8E6C9' }, - { icon: '💧', label: '오늘 음수량', value: '420ml', sub: '목표 대비 84%', color: '#E3F2FD', iconBg: '#BBDEFB' }, - { icon: '🏥', label: '최근 진료', value: '2주 전', sub: '피부과 진료', color: '#FFF8E1', iconBg: '#FFE082' }, -]; +type PetType = 'DOG' | 'CAT'; +type PetGender = 'MALE' | 'FEMALE'; +type VaccineCode = 'DHPPL' | 'RABIES' | 'KENNEL_COUGH' | 'CORONA_ENTERITIS' | 'HEARTWORM' | 'PARASITE'; -const vaccineRecords = [ - { name: '광견병', date: '2024.10.15', dNext: '2025.10.15', status: '정상', color: '#2E7D32', bg: '#E8F5E9' }, - { name: '종합백신', date: '2024.10.15', dNext: '2025.10.15', status: '정상', color: '#2E7D32', bg: '#E8F5E9' }, - { name: '심장사상충', date: '2025.03.01', dNext: '2025.04.01', status: '투약 필요', color: '#E65100', bg: '#FFF3E0' }, +const VACCINE_LIST: { code: VaccineCode; label: string }[] = [ + { code: 'DHPPL', label: '종합백신 (DHPPL)' }, + { code: 'RABIES', label: '광견병' }, + { code: 'KENNEL_COUGH', label: '켄넬코프 (기관지염)' }, + { code: 'CORONA_ENTERITIS', label: '코로나 장염' }, + { code: 'HEARTWORM', label: '심장사상충 예방' }, + { code: 'PARASITE', label: '외부기생충 구제' }, ]; +const DOG_BREEDS = ['골든 리트리버', '래브라도 리트리버', '말티즈', '포메라니안', '시츄', '비숑 프리제', '푸들', '진돗개', '프렌치 불독', '웰시 코기', '비글', '사모예드', '기타']; +const CAT_BREEDS = ['아메리칸 숏헤어', '스코티시 폴드', '페르시안', '러시안 블루', '메인쿤', '브리티시 숏헤어', '벵갈', '샴', '코리안 숏헤어', '노르웨이 숲속 고양이', '기타']; + +interface PetForm { + petType: PetType; + name: string; + breed: string; + birthdate: string; + weight: string; + gender: PetGender; + isNeutered: boolean; + vaccines: Record코코
++ {form.name || '반려동물'} +
- 대형견 + {form.petType === 'CAT' ? '고양이' : '대형견'}골든 리트리버
++ {form.breed || '품종 미입력'} +
등록번호 410191-000XXXX
오늘의 건강 현황
-기본 정보
+{stat.label}
-{stat.value}
-{stat.sub}
+ +예방접종 · 투약 현황
-{v.name}
- + + setDraft(f => ({ ...f, birthdate: e.target.value }))} + className="w-full rounded-xl px-4" + style={{ height: '44px', fontSize: '13px', border: '1.5px solid #E0E0E0', backgroundColor: 'white', color: '#1C1C1C', outline: 'none' }} + /> +예방접종 현황
+추가 건강 정보
+기본 정보
+예방접종 현황
+- 최근: {v.date} · 다음: {v.dNext} -
-추가 건강 정보
+