pediatric-ai-scribe-v3/shared/clinical
Daniel 10dbabf83b feat(notes): structured ROS + PE + ICD-10 diagnosis pickers (WellVisit, SickVisit)
Ports the vanilla ROS / Physical Exam / ICD-10 diagnosis cards from
public/js/shadess.js (@be14578) — renderRosRows, wireRosContainer,
renderDxComponent — which the earlier React port had collapsed into
plain-text textareas.

Clinical data → shared/clinical/ros-pe-dx.ts:
  • ROS_SYSTEMS (15 systems, each with label + detail hint)
  • PE_SYSTEMS (17 systems)
  • COMMON_DX (28 pediatric quick-pick ICD-10 codes)
  • formatRosForAI / formatDxForAI — byte-identical to vanilla so
    the server-side prompt context is unchanged.
  Tests: ros-pe-dx.test.ts asserts the table counts, ordering, and
  format strings — catches the class of bug where an LLM silently
  drops an entry or re-orders the clinical reference during a port.

New React components:
  client/src/components/RosPeTable.tsx — tri-state row (WNL/Abnormal/
    Not reviewed) with auto-revealed note field on Abnormal.
    rosAllWnl / rosClear helpers mirror the "All WNL" / "Clear"
    buttons from vanilla. Accepts a btnLabels prop so the same
    component renders ROS ("WNL"/"Not reviewed") and PE ("Normal"/
    "Not examined").

  client/src/components/DxPicker.tsx — ICD-10 live search via NLM
    Clinical Tables API (free, no auth, CORS-OK) with 280ms debounce
    + AbortController; chip-style selected tags with × remove;
    28-entry common-diagnosis quick-pick grid. Enter key adds the
    top result.

Wired into WellVisit / VisitNote.tsx and SickVisit.tsx:
  • Submit now sends ros / physicalExam / diagnoses as formatted
    strings to /api/well-visit/note and /api/sick-visit/note.
  • State persists through the Save/Load encounter flow via
    partialData → the rosData/peData/diagnoses round-trip.
2026-04-24 05:24:09 +02:00
..
bilirubin.test.ts feat(client): port Bilirubin + Fenton calculators with captured vectors 2026-04-24 01:49:45 +02:00
bilirubin.ts feat(client): port Bilirubin + Fenton calculators with captured vectors 2026-04-24 01:49:45 +02:00
bmi.test.ts feat(client): port BMI + Vitals + Resus Meds + Equipment calculators 2026-04-24 02:08:05 +02:00
bmi.ts feat(client): port BMI + Vitals + Resus Meds + Equipment calculators 2026-04-24 02:08:05 +02:00
bp.test.ts feat(client): port BP Percentile — all 10 Calculator pills now run in React 2026-04-24 02:15:17 +02:00
bp.ts feat(client): port BP Percentile — all 10 Calculator pills now run in React 2026-04-24 02:15:17 +02:00
calculators.test.ts feat(client): port age→weight + BSA + dose + GCS; shared/clinical module 2026-04-24 01:11:58 +02:00
calculators.ts feat(client): port Bedside Anaphylaxis + Cardiac + Seizure panels 2026-04-24 01:27:29 +02:00
correction-tracker.test.ts feat(notes): editable AI output + automatic correction tracking 2026-04-24 05:24:09 +02:00
correction-tracker.ts feat(notes): editable AI output + automatic correction tracking 2026-04-24 05:24:09 +02:00
fenton.test.ts feat(client): port final 5 Bedside panels — all 15 now run in React 2026-04-24 02:00:50 +02:00
fenton.ts feat(client): port final 5 Bedside panels — all 15 now run in React 2026-04-24 02:00:50 +02:00
ros-pe-dx.test.ts feat(notes): structured ROS + PE + ICD-10 diagnosis pickers (WellVisit, SickVisit) 2026-04-24 05:24:09 +02:00
ros-pe-dx.ts feat(notes): structured ROS + PE + ICD-10 diagnosis pickers (WellVisit, SickVisit) 2026-04-24 05:24:09 +02:00
visit-status.test.ts feat(wellvisit): port the 4 sub-tabs vanilla had — By Visit / Milestones / SSHADESS / Note 2026-04-24 05:24:09 +02:00
visit-status.ts feat(wellvisit): port the 4 sub-tabs vanilla had — By Visit / Milestones / SSHADESS / Note 2026-04-24 05:24:09 +02:00