feat(block2): global 'you're offline' banner (network state)
Feedback: offline, the social layer stops working with no clear reason. A slim amber strip now shows above every screen when there's no network (connectivity_ plus), so it's obvious WHY sharing is paused — the inventory keeps working. Wrapped once via the MaterialApp builder; connectivity check is guarded so it no-ops where the plugin is absent (tests/unsupported platforms). i18n en/es/pt. Analyzer clean.
This commit is contained in:
parent
5741d6bde8
commit
1ac954a09e
11 changed files with 135 additions and 5 deletions
|
|
@ -26,6 +26,7 @@ import 'ui/home_screen.dart';
|
|||
import 'ui/intro_screen.dart';
|
||||
import 'ui/inventory_list_screen.dart';
|
||||
import 'ui/market_screen.dart';
|
||||
import 'ui/offline_banner.dart';
|
||||
import 'ui/profile_screen.dart';
|
||||
import 'ui/settings_screen.dart';
|
||||
import 'ui/theme.dart';
|
||||
|
|
@ -212,6 +213,10 @@ class TaneApp extends StatelessWidget {
|
|||
GlobalWidgetsLocalizations.delegate,
|
||||
GlobalCupertinoLocalizations.delegate,
|
||||
],
|
||||
// A global "you're offline" strip above every screen — makes it clear
|
||||
// why the social layer is paused (the inventory still works).
|
||||
builder: (context, child) =>
|
||||
OfflineBanner(child: child ?? const SizedBox.shrink()),
|
||||
routerConfig: _router,
|
||||
),
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue