fix: Replay controls

This commit is contained in:
voltsrage
2026-06-20 14:41:11 +08:00
parent 584d1edd58
commit 7cfc5567fd
9 changed files with 291 additions and 73 deletions
+3 -3
View File
@@ -29,7 +29,7 @@ VITE_API_URL=http://localhost:5270
| `npm run dev` | Vite dev server (port 5173) |
| `npm run build` | Production build |
| `npm run preview` | Preview production build |
| `npm test` | Vitest — 38 tests across 10 files |
| `npm test` | Vitest — 41 tests across 10 files |
## Routes
@@ -48,7 +48,7 @@ VITE_API_URL=http://localhost:5270
| Patient Detail | Vitals, scores, alerts, orders, sepsis bundle; 5 vital charts + NEWS2 history |
| Alert Center | Global alert inbox; acknowledge / resolve; six feedback ratings per alert |
| Alert Reasoning | Plain-language “why it fired” + optional medication context (90 min window) |
| Replay Controls | Local pause/resume/speed scrub through fetched data (not live simulator control) |
| Replay Controls | Local pause/resume/speed scrub; charts/vitals filter by replay clock; **Next Alert →** jumps to each open alert |
| Clinician Feedback | Six ratings + optional notes on every alert; persisted in `localStorage` |
| Feedback Summary | Aggregate stats by alert type; export JSON/CSV for study analysis |
@@ -92,7 +92,7 @@ npm test
| `AlertCard.test.js` | Severity display, acknowledge/resolve, feedback integration |
| `AlertReasoning.test.js` | Reasoning text for sepsis, qSOFA, unknown types |
| `useChartData.test.js` | Chart data transformation |
| `useReplayControls.test.js` | Pause, speed, progress, jump |
| `useReplayControls.test.js` | Scenario bounds, progress, jumpToOffset/Timestamp, isAtOrBefore, instant speed |
| `usePolling.test.js` | Polling interval composable |
| `WardTable.test.js` | Ward table rendering |
| `Badge.test.js` | Severity badge variants |