/** * DiagnosisCard Component * * Professional diagnosis result card with: * - Light background with professional styling * - Comprehensive Patient Data Report grid * - Responsive mobile design (1 col → 2 col → 4 col) * - Clean, focused layout */ const DiagnosisCard = ({ diagnosis }) => { if (!diagnosis) return null const { prediction_name, explanation, features = {}, } = diagnosis // Feature display labels for the Patient Data Report const featureLabels = { Age: 'Age', Glucose: 'Blood Glucose', HbA1c: 'HbA1c', BMI: 'BMI', Cholesterol: 'Cholesterol', Triglycerides: 'Triglycerides', BloodPressure: 'Blood Pressure', PhysicalActivity: 'Physical Activity', SleepHours: 'Sleep Hours', StressLevel: 'Stress Level', DietScore: 'Diet Score', Smoking: 'Smoking', Alcohol: 'Alcohol', FamilyHistory: 'Family History', LengthOfStay: 'Length of Stay', OxygenSaturation: 'Oxygen Saturation', } return (
Diagnosis
{explanation}
{displayLabel}
{value !== null && value !== undefined ? String(value) : '—'}