phase3(critical-path): home page chain null-safe

home.dart + desktop/mobile navigation, carousels, index content widgets,
customers_logo, appbar_menu, navigation_drawer, MobileBottomNav, double_back.
Fixes: Key? params, nullable State fields, Scrollbar thumbVisibility,
ModalRoute.of()?, badges hide Badge, cartInfos local promotion.
This commit is contained in:
2026-07-24 13:42:03 +08:00
parent ae4c4046c3
commit 88dd90ed7c
16 changed files with 60 additions and 58 deletions

View File

@@ -13,7 +13,7 @@ import '../../widgets/mobile/mobile_navigation_drawer_header.dart';
import '../../constants.dart';
class MobileNavigationDrawer extends StatefulWidget {
const MobileNavigationDrawer({Key key}) : super(key: key);
const MobileNavigationDrawer({Key? key}) : super(key: key);
@override
State<StatefulWidget> createState() {
@@ -23,11 +23,11 @@ class MobileNavigationDrawer extends StatefulWidget {
}
class MobileNavigationDrawerState extends State<MobileNavigationDrawer> {
User _user;
User? _user;
@override
Widget build(BuildContext context) {
String currentRoute = ModalRoute.of(context).settings.name;
String currentRoute = ModalRoute.of(context)?.settings.name ?? '';
return Container(
width: 200.0,