import React, { useState } from "react"; import { Card, CardContent } from "@/components/ui/card"; import { Button } from "@/components/ui/button"; import { motion } from "framer-motion"; export default function SeniorFitApp() { const [step, setStep] = useState(1); const [form, setForm] = useState({ age: "", goal: "", pain: "", condition: "", surgery: "", }); const handleChange = (e) => { setForm({ ...form, [e.target.name]: e.target.value }); }; const analyzeUser = () => { let risk = "low"; let priority = "운동 시작 가능"; let expert = "기초 체력 코치"; if (form.pain.includes("무릎") || form.pain.includes("허리")) { risk = "medium"; expert = "재활 전문 물리치료사"; priority = "통증 관리 후 운동"; } if (form.surgery === "yes") { risk = "high"; expert = "재활 전문 물리치료사"; priority = "병원/재활 상담 우선"; } if (form.goal.includes("근력")) { expert = "시니어 전문 퍼스널 트레이너"; } return { risk, priority, expert }; }; const result = analyzeUser(); return (
위험도: {result.risk}
우선순위: {result.priority}
{result.expert}
현재 상태를 고려하면 무리한 운동보다는 단계적인 접근이 필요합니다.