From 70ba7af2261c8bc16ad20e6a117a037d5beedbd1 Mon Sep 17 00:00:00 2001 From: omagdy7 Date: Mon, 20 Nov 2023 17:25:29 +0200 Subject: Added an extra dummy route data --- lib/routes.dart | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'lib') diff --git a/lib/routes.dart b/lib/routes.dart index a1136c9..2bedc8d 100644 --- a/lib/routes.dart +++ b/lib/routes.dart @@ -19,6 +19,10 @@ class RoutesPage extends StatelessWidget { name: 'Morning Ride - Gate 3 to Abdu-Basha', startLocation: 'Abassyia', endLocation: 'Abdu-Basha Gate-3'), + Route( + name: 'Morning Ride - Abdu-Basha to 5th Settlement', + startLocation: 'Abdu-Basha', + endLocation: '5th Settlement'), Route( name: 'Afternoon Ride - Abdu-Basha to Gate 3', startLocation: 'Hadayek Elkoba', @@ -28,7 +32,7 @@ class RoutesPage extends StatelessWidget { @override Widget build(BuildContext context) { return Scaffold( - appBar: AppBar(title: Text('Routes')), + appBar: AppBar(title: const Text('Routes')), body: ListView.builder( itemCount: dummyRoutes.length, itemBuilder: (BuildContext context, int index) { @@ -53,14 +57,14 @@ class RoutesPage extends StatelessWidget { }, child: Card( elevation: 3, - margin: EdgeInsets.symmetric(vertical: 8, horizontal: 16), + margin: const EdgeInsets.symmetric(vertical: 8, horizontal: 16), shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(12), ), child: ListTile( title: Text( route.name, - style: TextStyle( + style: const TextStyle( fontWeight: FontWeight.bold, fontSize: 16, ), @@ -70,21 +74,21 @@ class RoutesPage extends StatelessWidget { children: [ Row( children: [ - Icon(Icons.location_on, color: Colors.blue), - SizedBox(width: 4), + const Icon(Icons.location_on, color: Colors.blue), + const SizedBox(width: 4), Flexible(child: Text(route.startLocation)), ], ), Row( children: [ - Icon(Icons.arrow_forward, color: Colors.blue), - SizedBox(width: 4), + const Icon(Icons.arrow_forward, color: Colors.blue), + const SizedBox(width: 4), Flexible(child: Text(route.endLocation)), ], ), ], ), - leading: Icon(Icons.directions_car), + leading: const Icon(Icons.directions_car), ), ), ); -- cgit v1.2.3