fix: loading not centered

This commit is contained in:
Alzalia 2025-08-08 01:38:49 +02:00
parent 658585b572
commit 7319e5a1a6
2 changed files with 5 additions and 5 deletions

View file

@ -122,10 +122,10 @@ class AddViewModel extends ChangeNotifier {
debugPrint("Oupsie daysie, ${result.error}"); debugPrint("Oupsie daysie, ${result.error}");
} }
notifyListeners(); notifyListeners();
_ownerRepository.liveOwners().listen((Owner owner) { // _ownerRepository.liveOwners().listen((Owner owner) {
_owners.add(owner); // _owners.add(owner);
notifyListeners(); // notifyListeners();
}); // });
return result; return result;
} }
} }

View file

@ -35,7 +35,7 @@ class _AddPageState extends State<AddPage> {
body: ListenableBuilder( body: ListenableBuilder(
listenable: widget.viewModel, listenable: widget.viewModel,
builder: (context, child) => switch (widget.viewModel.isLoaded) { builder: (context, child) => switch (widget.viewModel.isLoaded) {
false => CircularProgressIndicator(), false => Center(child: CircularProgressIndicator()),
true => Stack( true => Stack(
children: [ children: [
ColoredBox(color: Colors.black), ColoredBox(color: Colors.black),