update home look and feel

This commit is contained in:
2024-08-29 14:43:18 +02:00
parent 3d263e3083
commit 570e5a6ee5

View File

@@ -402,45 +402,29 @@ class _HomeTileGridState extends State<HomeTileGrid> {
propicFile: widget.propicFile,
),
body: SafeArea(
child: Column(
child: Stack(
children: [
Column(
mainAxisAlignment: MainAxisAlignment.center,
mainAxisSize: MainAxisSize.max,
children: [
const SizedBox(height: 15.0),
const SizedBox(height: 20.0),
Text(
"Mzanzi Innovation Hub",
textAlign: TextAlign.center,
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 25.0,
color:
MzanziInnovationHub.of(context)!.theme.secondaryColor(),
fontSize: 20.0,
color: MzanziInnovationHub.of(context)!
.theme
.secondaryColor(),
),
),
const SizedBox(height: 10),
const SizedBox(height: 20),
Row(
mainAxisAlignment: MainAxisAlignment.center,
mainAxisSize: MainAxisSize.max,
children: [
Flexible(
flex: 1,
child: Builder(
builder: (context) => IconButton(
padding: const EdgeInsets.all(0),
onPressed: () {
setState(() {
appSearch = "";
searchController.clear();
});
Scaffold.of(context).openDrawer();
},
icon: const Icon(
Icons.apps,
size: 50,
),
),
),
),
Flexible(
flex: 4,
child: KeyboardListener(
@@ -469,6 +453,22 @@ class _HomeTileGridState extends State<HomeTileGrid> {
),
),
),
Flexible(
flex: 1,
child: IconButton(
//padding: const EdgeInsets.all(0),
onPressed: () {
setState(() {
appSearch = "";
searchController.clear();
});
},
icon: const Icon(
Icons.filter_alt_off,
size: 30,
),
),
),
],
),
const SizedBox(height: 10),
@@ -484,7 +484,8 @@ class _HomeTileGridState extends State<HomeTileGrid> {
// shrinkWrap: true,
itemCount:
searchApp(pbswitch[_selectedIndex], appSearch).length,
gridDelegate: const SliverGridDelegateWithMaxCrossAxisExtent(
gridDelegate:
const SliverGridDelegateWithMaxCrossAxisExtent(
mainAxisSpacing: 15, maxCrossAxisExtent: 200),
itemBuilder: (context, index) {
return searchApp(
@@ -494,6 +495,30 @@ class _HomeTileGridState extends State<HomeTileGrid> {
),
],
),
Positioned(
top: 10,
left: 5,
width: 50,
height: 50,
child: Builder(
builder: (context) => IconButton(
padding: const EdgeInsets.all(0),
onPressed: () {
setState(() {
appSearch = "";
searchController.clear();
});
Scaffold.of(context).openDrawer();
},
icon: const Icon(
Icons.apps,
size: 50,
),
),
),
),
],
),
),
//),