Flutter web App home page, App Bar, Tile Grid & Tiles added
This commit is contained in:
48
Frontend/patient_manager/lib/components/homeTile.dart
Normal file
48
Frontend/patient_manager/lib/components/homeTile.dart
Normal file
@@ -0,0 +1,48 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class HomeTile extends StatelessWidget {
|
||||
final String tileName;
|
||||
final String tileDescription;
|
||||
final void Function() onTap;
|
||||
// final Widget tileIcon;
|
||||
|
||||
const HomeTile({
|
||||
super.key,
|
||||
required this.onTap,
|
||||
required this.tileName,
|
||||
required this.tileDescription,
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return GestureDetector(
|
||||
onTap: onTap,
|
||||
child: Card(
|
||||
child: Column(
|
||||
//mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
ListTile(
|
||||
leading: const Icon(Icons.abc),
|
||||
title: Text(
|
||||
tileName,
|
||||
style: const TextStyle(
|
||||
fontWeight: FontWeight.bold,
|
||||
),
|
||||
),
|
||||
subtitle: Text(tileDescription),
|
||||
),
|
||||
const Row(
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 10),
|
||||
child: Icon(Icons.arrow_forward),
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user