diet-guard/app/lib/widgets
Krzysztof kuhy Rudnicki 3c67cf8c9c Split log_meal_screen into mixins and widget helpers
Twelfth batch of the 250-line sweep (over-cap count 5 -> 4).

  log_meal_screen.dart  431 -> 250

Widget/behaviour extraction only, no route changes: the four app-bar buttons
push exactly the MaterialPageRoutes they did before.

  log_meal_sync_mixin.dart  background sync + app lifecycle observation
  log_meal_nav_mixin.dart   the four app-bar destinations
  log_meal_actions.dart     the app-bar IconButton list
  log_meal_progress.dart    buildTodayProgress + parseMacroField (both pure)

The sync and nav halves are mixins rather than helper classes because the
behaviour is inseparable from the State it drives -- it observes the widget
lifecycle, calls setState, and reads `mounted`. The screen's fields stay
declared on the State; `syncHttpClient` is an abstract getter because `widget`
is typed `T` inside a mixin, so `widget.httpClient` does not resolve there.

Names crossing the new file boundaries became public with doc comments, as
`public_member_api_docs` requires. The macro-filling block moved onto
`MacroControllers.fillFrom`, next to the existing `clear()`, which is where it
belonged anyway.

Verified: flutter test 555 (unchanged), flutter analyze clean, pre-commit
clean.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RA9ynjqXPnexRQnR5oAuCC
2026-08-15 20:59:48 +02:00
..
filters Split food_bank_screen; share the filter widgets with history 2026-08-15 19:43:08 +02:00
food_bank Split food_bank_screen; share the filter widgets with history 2026-08-15 19:43:08 +02:00
history Split food_bank_screen; share the filter widgets with history 2026-08-15 19:43:08 +02:00
autocomplete_suggestion_list.dart Compact LogMealScreen so it fits without scrolling on-screen keyboard 2026-07-04 05:19:23 +02:00
average_summary_row.dart Show weekly and monthly average intake on both devices 2026-08-09 14:59:40 +02:00
day_status_calendar.dart Make the meal gate usable without a pointer on a 1366x768 screen 2026-07-30 16:21:27 +02:00
macro_input_row.dart Split log_meal_screen into mixins and widget helpers 2026-08-15 20:59:48 +02:00
slot_selector_row.dart Remove the Snack chip from the phone's slot selector 2026-08-14 22:31:09 +02:00
streak_summary_row.dart Add budget-adherence calendar, streaks, and freely-editable synced budget 2026-07-13 21:31:45 +02:00
sync_health_banner.dart Make the phone publish on every tick, and fail closed on Firebase errors 2026-08-10 14:35:37 +02:00
today_progress_card.dart Remove unused features; fix reminder false alarms; share all state 2026-07-26 16:39:52 +02:00