Skip to content

Commit

Permalink
display date and time (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hirushan272 committed Feb 1, 2021
1 parent b9720b5 commit 5df565b
Showing 1 changed file with 26 additions and 18 deletions.
44 changes: 26 additions & 18 deletions lib/screens/home/notify_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,12 @@ class NotifyCard extends StatelessWidget {
elevation: 4.0,
shadowColor: Colors.black,
child: Container(
width: size.width * 0.95,
padding: EdgeInsets.fromLTRB(5, 10, 5, 10),
padding: EdgeInsets.fromLTRB(10, 10, 5, 10),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Column(
crossAxisAlignment: CrossAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
notifyList[index].nid != null
? Text(
Expand All @@ -41,25 +40,34 @@ class NotifyCard extends StatelessWidget {
),
SizedBox(height: 10),
notifyList[index].nid != null
? Text("${notifyList[index].description}")
? Container(
width: size.width * 0.75,
child: Text("${notifyList[index].description}"))
: Text(
"This Is the description of dummy notify card",
"This Is the description",
style: TextStyle(fontSize: 15),
),
SizedBox(height: 10),
// Row(
// mainAxisAlignment: MainAxisAlignment.spaceEvenly,
// children: [
// data.notifyList[index].nid != null
// ? Text(
// "Date: ${formateDate(data.notifyList[index].startedDay)}")
// : Text("Date: 2021-05-23"),
// data.notifyList[index].nid != null
// ? Text(
// "Time: ${formatTimeOfDay(data.notifyList[index].startedTime)}")
// : Text("Time: 09:00"),
// ],
// ),
Container(
width: size.width * 0.8,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Container(
child: data.notifyList[index].nid != null
? Text(
"Date: ${formateDate(data.notifyList[index].startedDay)}")
: Text("Date: 2021-05-23"),
),
Container(
child: data.notifyList[index].nid != null
? Text(
"Time: ${formateToTime(data.notifyList[index].startedTime)}")
: Text("Time: 09:00"),
),
],
),
),
],
),
IconButton(
Expand Down

0 comments on commit 5df565b

Please sign in to comment.