feat: session content sync trigger and newest-season selection
Add seasonRefreshProvider (once-per-session FutureProvider) and activeSeason() helper; HomeScreen listens and invalidates seasonsProvider when new packs arrive; season_map_screen and season_title_screen switch from list.first to activeSeason. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -21,6 +21,11 @@ class HomeScreen extends ConsumerWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context, WidgetRef ref) {
|
||||
ref.listen(seasonRefreshProvider, (_, next) {
|
||||
if (next is AsyncData<bool> && next.value == true) {
|
||||
ref.invalidate(seasonsProvider);
|
||||
}
|
||||
});
|
||||
final l10n = AppLocalizations.of(context)!;
|
||||
final streak = ref.watch(streakProvider);
|
||||
final best = ref.watch(endlessBestProvider);
|
||||
|
||||
Reference in New Issue
Block a user