diff --git a/TODO.md b/TODO.md index 17ea36f..2ce199d 100644 --- a/TODO.md +++ b/TODO.md @@ -50,6 +50,19 @@ - Test: `shared/tests/turn.characterization.test.js` 'addParticipant rejects duplicate id' — GREEN. +### BUG-4: hide-player-HP breaks display view (preexisting) +- Toggle "hide player HP" in admin → display view flips to "Game Session Paused". +- Toggling back does NOT recover. Must re-activate encounter in encounters + panel to restore display. +- Expected: hide-HP toggle updates one field on activeDisplay/status doc, + display stays live on current encounter. +- Likely cause: toggle writes to wrong path, or clobbers activeCampaignId/ + activeEncounterId with null (setDoc replace vs updateDoc patch). +- Fix: use updateDoc (patch) not setDoc (replace); or include all existing + fields when writing. +- Test: render App + DisplayView, toggle hide-HP, assert display still shows + encounter (not paused). + ## Pipeline - [ ] Red test: dead participant still in turnOrderIds, turn still advances to them - [ ] Fix `shared/turn.js`: don't drop dead from turn order