Edit User profile

This commit is contained in:
2021-03-31 22:10:42 +02:00
parent 2e4bc65cbb
commit 54fc7e33aa
13 changed files with 480 additions and 98 deletions
+14 -17
View File
@@ -6,29 +6,26 @@ import 'package:le_kiosque_by_gcs/ui/view/main.dart';
import 'package:provider/provider.dart';
class LandingPageView extends StatelessWidget {
@override
Widget build(BuildContext context) {
final auth = Provider.of<Auth>(context, listen: false);
return StreamBuilder<User>(
stream: auth.authStateChanges(),
builder: (context, snapshot) {
if (snapshot.connectionState == ConnectionState.active) {
if (snapshot.data == null) {
return AuthView();
} else {
return MainView();
}
}
else {
return Scaffold(
body: Center(
child: CircularProgressIndicator(),
),
);
stream: auth.authStateChanges(),
builder: (context, snapshot) {
if (snapshot.connectionState == ConnectionState.active) {
if (snapshot.data == null) {
return AuthView();
} else {
return MainView();
}
} else {
return Scaffold(
body: Center(
child: CircularProgressIndicator(),
),
);
}
},
);
}
}