Skip to content

Commit

Permalink
Repo updates
Browse files Browse the repository at this point in the history
  • Loading branch information
HossamElghamry committed Jun 24, 2019
1 parent a58ba0f commit 3ce61ee
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 6 deletions.
Binary file added Medicine_reminder_1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Medicine_reminder_2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Medicine_reminder_3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Medicine_reminder_4.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Medicine_reminder_5.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 9 additions & 2 deletions lib/src/ui/homepage/homepage.dart
Original file line number Diff line number Diff line change
Expand Up @@ -205,10 +205,17 @@ class BottomContainer extends StatelessWidget {
return StreamBuilder<List<Medicine>>(
stream: _globalBloc.medicineList$,
builder: (context, snapshot) {
if (!snapshot.hasData) {
if (snapshot.data.length == 0) {
return Container(
child: Center(
child: Text("Please insert desired medicines"),
child: Text(
"Press + to add a reminder",
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 24,
color: Color(0xFFC9C9C9),
fontWeight: FontWeight.bold),
),
),
);
} else {
Expand Down
9 changes: 5 additions & 4 deletions lib/src/ui/medicine_details/medicine_details.dart
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ class MedicineDetails extends StatelessWidget {
ExtendedSection(medicine: medicine),
Padding(
padding: EdgeInsets.only(
left: MediaQuery.of(context).size.height * 0.06,
right: MediaQuery.of(context).size.height * 0.06,
top: 25),
left: MediaQuery.of(context).size.height * 0.06,
right: MediaQuery.of(context).size.height * 0.06,
top: 25,
),
child: Container(
width: 280,
height: 70,
Expand Down Expand Up @@ -191,7 +192,7 @@ class ExtendedSection extends StatelessWidget {
fieldTitle: "Dose",
fieldInfo: "Every " +
medicine.interval.toString() +
" hour(s) | " +
" hour(s) | " +
(24 / medicine.interval).floor().toString() +
" time(s) a day",
),
Expand Down

0 comments on commit 3ce61ee

Please sign in to comment.