add colors menu

This commit is contained in:
Valentin CZERYBA 2024-06-26 23:10:16 +02:00
parent 4804c8bc01
commit 581512a6da
2 changed files with 27 additions and 16 deletions

View File

@ -84,21 +84,30 @@ class _MyHomePageState extends State<ListItemMenu> {
Widget buildPosts(List<Events> posts) {
// ListView Builder to show data in a list
return Scaffold(
appBar: AppBar(
// Here we take the value from the MyHomePage object that was created by
// the App.build method, and use it to set our appbar title.
title: Text("Item list menu"),
),
body: ListView.separated(
itemCount: posts.length,
itemBuilder: (context, index) {
final post = posts[index];
return ListTile(
title: Text('${post.name!}'), subtitle: Text('${post.place!}'));
},
separatorBuilder: (context, index) {
return Divider();
},
));
appBar: AppBar(
// Here we take the value from the MyHomePage object that was created by
// the App.build method, and use it to set our appbar title.
title: Text("Item list menu"),
backgroundColor: Colors.blue,
foregroundColor: Colors.white,
),
body: ListView.separated(
itemCount: posts.length,
itemBuilder: (context, index) {
final post = posts[index];
return ListTile(
title: Text('${post.name!}'), subtitle: Text('${post.place!}'));
},
separatorBuilder: (context, index) {
return Divider();
},
),
floatingActionButton: FloatingActionButton(
onPressed: () {},
backgroundColor: Colors.blue,
tooltip: 'Recherche',
child: const Icon(Icons.search, color: Colors.white),
),
);
}
}

View File

@ -154,6 +154,8 @@ class _LoginDemoState extends State<LoginDemo> with ShowErrorDialog {
backgroundColor: Colors.white,
appBar: AppBar(
title: Text("Login Page"),
backgroundColor: Colors.blue,
foregroundColor: Colors.white,
),
body: SingleChildScrollView(
child: Column(