commit merge linkView and master
continuous-integration/drone/push Build is failing Details

messagerie_lucas_test
Lucas Delanier 3 years ago
parent cbbbfbfa95
commit eb9aea416c

@ -4,6 +4,7 @@ import './w_settings.dart';
import './w_spot.dart'; import './w_spot.dart';
import './w_discovery.dart'; import './w_discovery.dart';
import './w_profile.dart'; import './w_profile.dart';
import './w_messages.dart';
class MainPage extends StatefulWidget { class MainPage extends StatefulWidget {
const MainPage({Key? key}) : super(key: key); const MainPage({Key? key}) : super(key: key);
@ -21,43 +22,44 @@ class _MainPageState extends State<MainPage> {
new DiscoveryWidget(), new DiscoveryWidget(),
SpotsWidget(), SpotsWidget(),
Center(child: Text('Tops'),), Center(child: Text('Tops'),),
Center(child: Text('Messages'),), MessagesWidget(),
SettingsWidget(), SettingsWidget(),
]; ];
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
double height = MediaQuery.of(context).size.height; double height = MediaQuery.of(context).size.height;
return Scaffold( return Scaffold(
resizeToAvoidBottomInset: false,
body: screens[_index], body: screens[_index],
bottomNavigationBar: NavigationBarTheme( bottomNavigationBar: NavigationBarTheme(
data: NavigationBarThemeData( data: NavigationBarThemeData(
indicatorColor: Color(0xFF5C1DC3), indicatorColor: Color(0xFF5C1DC3),
labelTextStyle: MaterialStateProperty.all( labelTextStyle: MaterialStateProperty.all(
TextStyle(fontSize: 12, fontWeight: FontWeight.w400, color: Colors.grey) TextStyle(fontSize: 12, fontWeight: FontWeight.w400, color: Colors.grey)
), ),
), ),
child: ConstrainedBox( child: ConstrainedBox(
constraints: BoxConstraints( constraints: BoxConstraints(
minHeight: height*0.1, minHeight: height*0.1,
maxHeight: 100, maxHeight: 100,
), ),
child: NavigationBar( child: NavigationBar(
animationDuration: Duration(seconds: 1), animationDuration: Duration(seconds: 1),
selectedIndex: index, selectedIndex: index,
height: height*0.1, height: height*0.1,
onDestinationSelected: (index) => onDestinationSelected: (index) =>
setState(() => _index = index), setState(() => _index = index),
backgroundColor: Color(0xFF232123), backgroundColor: Color(0xFF232123),
destinations: [ destinations: [
NavigationDestination(icon: Icon(Icons.person_outline, color: Colors.grey,), label: 'Profil', selectedIcon: Icon(Icons.person, color: Colors.white,),), NavigationDestination(icon: Icon(Icons.person_outline, color: Colors.grey,), label: 'Profil', selectedIcon: Icon(Icons.person, color: Colors.white,),),
NavigationDestination(icon: Icon(Icons.bookmark_border, color: Colors.grey,), selectedIcon: Icon(Icons.bookmark, color: Colors.white,), label: 'Discovery'), NavigationDestination(icon: Icon(Icons.bookmark_border, color: Colors.grey,), selectedIcon: Icon(Icons.bookmark, color: Colors.white,), label: 'Discovery'),
NavigationDestination(icon: Icon(CustomIcons.spot, color: Colors.grey), selectedIcon: Icon(CustomIcons.spot_outline, color: Colors.white), label: 'Spots',), NavigationDestination(icon: Icon(CustomIcons.spot, color: Colors.grey), selectedIcon: Icon(CustomIcons.spot_outline, color: Colors.white), label: 'Spots',),
NavigationDestination(icon: Icon(CustomIcons.podium_outline, color: Colors.grey,), label: 'Tops', selectedIcon: Icon(CustomIcons.podium, color: Colors.white,),), NavigationDestination(icon: Icon(CustomIcons.podium_outline, color: Colors.grey,), label: 'Tops', selectedIcon: Icon(CustomIcons.podium, color: Colors.white,),),
NavigationDestination(icon: Icon(Icons.mail_outline, color: Colors.grey,), label: 'Messages', selectedIcon: Icon(Icons.email, color: Colors.white,),), NavigationDestination(icon: Icon(Icons.mail_outline, color: Colors.grey,), label: 'Messages', selectedIcon: Icon(Icons.email, color: Colors.white,),),
], ],
), ),
), ),
), ),
); );
} }
} }
Loading…
Cancel
Save