mirror of
https://github.com/kuhyx/todo-app.git
synced 2026-11-10 19: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_test.dart | ||
| confirm_test.dart | ||
| fake_note_repository.dart | ||
| fake_secure_storage.dart | ||
| github_device_auth_test.dart | ||
| local_backup_test.dart | ||
| markdown_view_test.dart | ||
| note_detail_screen_test.dart | ||
| note_editor_test.dart | ||
| note_repository_test.dart | ||
| note_template_test.dart | ||
| note_test.dart | ||
| notes_list_screen_test.dart | ||
| notes_markdown_test.dart | ||
| settings_screen_test.dart | ||
| sync_service_test.dart | ||
| sync_settings_test.dart | ||
| theme_test.dart | ||
| wrapper_server_test.dart | ||