Commit 6830e72
committed
fix: 4 bugs — Detail key, ReflectionChecklist data loss, AutoSaveTextarea double-save, scripture-card min-height
- Add key={activeSectionId} to <Detail>: without it React reused the same
component instance across sections, causing ReflectionChecklist/Journal save
effects to fire with stale state + new storageKey, briefly writing the wrong
step's data to another step's localStorage slot
- ReflectionChecklist: replace load useEffect + useState({}) with a lazy
useState initializer that reads localStorage directly. Eliminates the bug
where the save effect fired on initial mount with checked={}, overwriting
real user data before the load effect could restore it
- AutoSaveTextarea: add dedicated handleManualSave for the Save button.
Previously onClick={handleBlur} caused a double-save on every click: textarea
blur fires handleBlur, then the click event fires it again
- styles.css: add min-height: var(--min-tap) to .scripture-card to restore
accessible tap-target size (was on .scripture-card__toggle, now removed)1 parent 591521c commit 6830e72
2 files changed
Lines changed: 16 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
169 | 169 | | |
170 | 170 | | |
171 | 171 | | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
| 172 | + | |
| 173 | + | |
176 | 174 | | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
| 175 | + | |
182 | 176 | | |
183 | | - | |
| 177 | + | |
| 178 | + | |
184 | 179 | | |
185 | 180 | | |
186 | 181 | | |
| |||
327 | 322 | | |
328 | 323 | | |
329 | 324 | | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
330 | 333 | | |
331 | 334 | | |
332 | 335 | | |
| |||
349 | 352 | | |
350 | 353 | | |
351 | 354 | | |
352 | | - | |
| 355 | + | |
353 | 356 | | |
354 | 357 | | |
355 | 358 | | |
| |||
972 | 975 | | |
973 | 976 | | |
974 | 977 | | |
| 978 | + | |
975 | 979 | | |
976 | 980 | | |
977 | 981 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
746 | 746 | | |
747 | 747 | | |
748 | 748 | | |
| 749 | + | |
749 | 750 | | |
750 | 751 | | |
751 | 752 | | |
| |||
0 commit comments