(Feat) Update Loading screen

This commit is contained in:
2026-07-22 12:55:43 +02:00
parent 54091398a5
commit 77d603f734
5 changed files with 207 additions and 15 deletions
+4 -6
View File
@@ -1,8 +1,7 @@
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'screens/home_shell.dart';
import 'services/produit_repository.dart';
import 'screens/demarrage_screen.dart';
import 'theme.dart';
Future<void> main() async {
@@ -14,9 +13,8 @@ Future<void> main() async {
DeviceOrientation.portraitDown,
]);
// Connexion au serveur (Raspberry Pi) + chargement + temps réel.
await ProduitRepository.instance.initialiser();
// On affiche l'interface tout de suite : la connexion au serveur se fait
// dans DemarrageScreen, loader visible (plus d'écran blanc au lancement).
runApp(const MonApp());
}
@@ -31,7 +29,7 @@ class MonApp extends StatelessWidget {
theme: AppTheme.clair(),
darkTheme: AppTheme.sombre(),
themeMode: ThemeMode.light,
home: const HomeShell(),
home: const DemarrageScreen(),
);
}
}