Sprint 6: Таймлайн X home variant for chronic patients

Fourth home variant alongside Карточки / Лента / Таймлайн,
labeled "Таймлайн X" in Tweaks "Главный экран". Designed for
patients with chronic conditions (not post-op).

data.js: new `chronic` object — condition, stage, doctor,
metrics (days since last flare-up, compliance %, flare-ups this
year), daily + scheduled tasks, lifestyle recommendations, and
5-visit observation history.

HomeTimelineXScreen sections:
- Health status hero with soft gradient primary-100 → warm-100,
  success-tinted stable-state chip (green dot), three narrow-font
  metrics
- Today's tasks card: daily habits with streak + 🔥, scheduled
  procedures with dates
- Ask-a-question promotion: AI card (teal gradient) + doctor
  card (with avatar) side by side
- Vertical observation timeline: 5 past visits with doctor initial,
  color-coded by type (diagnosis/procedure/therapy/flareup/checkup)
- Upcoming appointment, lifestyle recommendations carousel with
  emoji, book CTA, article carousel

Softened hero from dark teal gradient with white text to light
primary-100 → warm-100 gradient with dark text — stable-state
signal, not clinical verdict.

Following Sprint 5 convention: matching entry in src/docs.js under
key `home:timelineX` with title, category, goal, tasks, rationale.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-20 20:01:24 +05:00
parent a9d669e397
commit bf1c78ff14
6 changed files with 302 additions and 5 deletions
+28
View File
@@ -226,6 +226,34 @@ export const CLINIC_DATA = {
],
},
],
chronic: {
condition: 'Хронический тонзиллит',
stage: 'Компенсированная форма',
diagnosed: '2022',
doctorId: 'makarova',
daysSinceLastFlareup: 118,
complianceScore: 87,
flareupsThisYear: 1,
currentTasks: [
{ id: 't1', text: 'Полоскание горла (утро/вечер)', type: 'daily', done: true, streak: 12 },
{ id: 't2', text: 'Витамин D 2000 МЕ', type: 'daily', done: false, streak: 0 },
{ id: 't3', text: 'Промывание миндалин в клинике', type: 'scheduled', nextDate: '23 апр' },
{ id: 't4', text: 'Плановый ЛОР-осмотр', type: 'scheduled', nextDate: 'Июль 2026' },
],
recommendations: [
{ icon: '❄️', title: 'Избегать переохлаждения', sub: 'Особенно горла и шеи' },
{ icon: '💧', title: 'Пить 1.5–2 л воды в день', sub: 'Увлажнение слизистой' },
{ icon: '🏃', title: 'Умеренные физнагрузки', sub: 'Укрепление иммунитета' },
{ icon: '🥦', title: 'Витамин C + цинк', sub: 'В рационе ежедневно' },
],
pastVisits: [
{ id: 'v1', date: '15 окт 2023', title: 'Диагноз подтверждён', doctorId: 'makarova', type: 'diagnosis' },
{ id: 'v2', date: '12 дек 2023', title: 'Первое промывание миндалин', doctorId: 'makarova', type: 'procedure' },
{ id: 'v3', date: '8 мар 2024', title: 'Курс физиотерапии · 10 сеансов', doctorId: 'makarova', type: 'therapy' },
{ id: 'v4', date: '14 дек 2024', title: 'Обострение — курс антибиотиков', doctorId: 'makarova', type: 'flareup' },
{ id: 'v5', date: '8 апр 2026', title: 'Плановый осмотр', doctorId: 'makarova', type: 'checkup' },
],
},
recovery: {
op: 'Септопластика',
surgeon: 'syndaev',