mirror of
https://github.com/kuhyx/todo-app.git
synced 2026-11-10 20:27:01 +01:00
739 -> 249 lines. As with note_editor, the ~600-line State class needed
decomposing rather than moving:
capture_draft.dart the note being captured and its write-through
to storage -- the model behind "every keystroke
is already persisted". Lazy row creation stays
here; the screen just logs that it happened.
capture_sync_runner.dart one sync pass, with no BuildContext. This also
de-duplicates the two callers: the manual button
and the background tick ran byte-identical
runSync blocks differing only in the snackbar
and the 'auto' log flag.
capture_status.dart SyncStatusStore (the persisted last outcome) and
describeSyncResult.
capture_app_bar.dart the app bar.
capture_meta_row.dart the priority/status pickers.
capture_status_footer.dart the two status lines.
capture_screen_{widget,sync}.dart
parts, for the same reason as note_editor's.
The mounted checks are preserved exactly, including the one in
SyncStatusStore.restore that must fire AFTER its await rather than before
(writing the notifier post-dispose is the bug it exists to prevent), which
is why it takes a stillLive callback instead of a bool.
Verified: 313 tests pass, analyze clean, every capture file at 100%
coverage. lib/ and bin/ are now down to three files over the cap.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| capture_app_bar.dart | ||
| capture_draft.dart | ||
| capture_meta_row.dart | ||
| capture_screen_sync.dart | ||
| capture_screen_widget.dart | ||
| capture_screen.dart | ||
| capture_status_footer.dart | ||
| capture_status.dart | ||
| capture_sync_runner.dart | ||
| confirm.dart | ||
| github_mirror_screen.dart | ||
| markdown_view.dart | ||
| note_actions_sheet.dart | ||
| note_date_range_field.dart | ||
| note_detail_screen.dart | ||
| note_editor_chrome.dart | ||
| note_editor_document.dart | ||
| note_editor_mode.dart | ||
| note_editor_raw_field.dart | ||
| note_editor_step_page.dart | ||
| note_editor_views.dart | ||
| note_editor_widget.dart | ||
| note_editor_wizard.dart | ||
| note_editor.dart | ||
| note_tile.dart | ||
| notes_filter_sheet.dart | ||
| notes_list_navigation.dart | ||
| notes_list_screen.dart | ||
| settings_screen.dart | ||
| theme.dart | ||