This commit is contained in:
Felipe
2024-02-19 18:16:51 -05:00
parent 9e6f76e309
commit 997c6047bb
34 changed files with 1235 additions and 594 deletions
+24 -19
View File
@@ -16,29 +16,34 @@ class MyAppView extends StatelessWidget {
title: 'Prosappco',
theme: ThemeData(
colorScheme: const ColorScheme.light(
background: Colors.white,
onBackground: Colors.black,
primary: Color.fromRGBO(66, 164, 239, 1),
onPrimary: Colors.black,
secondary: Color.fromRGBO(35, 108, 244, 1),
onSecondary: Colors.white,
tertiary: Color.fromRGBO(255, 204, 128, 1),
error: Colors.red,
outline: Color(0xFF424242)),
background: Colors.white,
onBackground: Colors.black,
primary: Color.fromRGBO(66, 164, 239, 1),
onPrimary: Colors.black,
secondary: Color.fromRGBO(35, 108, 244, 1),
onSecondary: Colors.white,
tertiary: Color.fromRGBO(214, 244, 255, 1),
error: Colors.red,
outline: Color(0xFF424242),
),
),
home: BlocBuilder<AuthenticationBloc, AuthenticationState>(
builder: (context, state) {
switch (state.status) {
case AuthenticationStatus.authenticated:
return const HomeScreen();
case AuthenticationStatus.unauthenticated:
return const WelcomeScreen();
case AuthenticationStatus.unknown:
return const SplashScreen();
}
return getScreen(state);
}),
);
}
getScreen(AuthenticationState state) {
switch (state.status) {
case AuthenticationStatus.authenticated:
return const HomeScreen();
case AuthenticationStatus.unauthenticated:
return WelcomeScreen();
case AuthenticationStatus.unknown:
return const SplashScreen();
}
}
}