You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 63774b8
Browse filesBrowse the repository at this point in the historyBrowse files
Behavior-preserving consolidation of dialog accessibility and feedback. No modal
field/validation/save changes; YAML output unchanged (golden baselines byte-identical).
- Add a shared <Modal> primitive (src/components/Modal/) owning ESC close, optional
overlay-click close, body-scroll lock, focus trap, and focus return to the opener;
renders nothing when closed. Add ConfirmDialog built on it. Honors prefers-reduced
-motion; unique per-instance ids via useId().
- Migrate CameraModal and ElectrodeGroupModal onto Modal: lift each form into a child
rendered only while open, so initial state computes once (fixes the prior unstable
init effect). ElectrodeGroupModal now gains a focus trap + focus return it never had,
drops the interim trap, and sources device types from the single canonical
valueList.deviceTypes() (was a hardcoded list missing one entry).
- Rebase AlertModal onto Modal so it inherits the trap/focus-return; keep its public
props and visual classes.
- Replace all blocking native dialogs in the new UI: window.confirm() -> ConfirmDialog
(electrode-group delete, behavioral-event delete); alert() -> AlertModal with titles
(navigating success alerts defer navigation to dismissal) and inline role=alert
regions (channel-map validation errors, calendar day-creation failures). Legacy form
left untouched.
- Correct DataAcqSection's misleading "debounced" docstring (no behavior change).
- Tests: Modal, ConfirmDialog, migrated-modal trap/return, device-source parity, the
delete/alert dialog flows, and a source-scan test asserting zero native dialogs in
the new-UI surfaces.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0 commit comments