mirror of
https://github.com/kuhyx/todo-app.git
synced 2026-11-10 21:27:01 +01:00
Both delete paths -- the per-note actions sheet and the detail screen -- deleted immediately, with no confirmation and no undo. With a pointer that is merely risky: you have to travel to the control and press it. With a keyboard it is one Tab away from a Return you were about to press anyway, and the note is gone with nothing to recover it. The confirmation is built so the SAFE option is what a reflexive keypress hits: Cancel is autofocused, Escape dismisses as "no", and the destructive button is error-coloured but deliberately not the default action. Escape is bound explicitly rather than relying on the barrier, because the desktop surface here is a Chrome --app window where that cannot be assumed -- and a confirmation the keyboard cannot back out of is worse than no confirmation at all. The actions sheet also gains isScrollControlled. Default bottom sheets cap at 9/16 of the viewport, i.e. ~432px on a 768px screen, and this sheet's height grows with the note title and its chip rows -- so Delete could be clipped out of reach on the very screen this app is used on. The two existing delete tests correctly failed once confirmation landed; both now go through the dialog, and each gains a cancel-keeps-the-note counterpart so the negative path is covered too. 204 tests, 100% line coverage held. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| capture_screen.dart | ||
| confirm.dart | ||
| markdown_view.dart | ||
| note_detail_screen.dart | ||
| note_editor.dart | ||
| notes_list_screen.dart | ||
| settings_screen.dart | ||
| theme.dart | ||