aboutsummaryrefslogtreecommitdiff
path: root/lib/pages
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2020-06-03 14:39:52 +0530
committerAkshay Nair <phenax5@gmail.com>2020-06-03 14:39:52 +0530
commit871706b606c77eeac13bfcea67c3ce1d71203d2c (patch)
tree82d3ca8b51cc001606f5412a20730a813b7d9e2d /lib/pages
parentc745b90dfdc97a2e04582051b01fde83883d8e3e (diff)
downloaddaft-launcher-871706b606c77eeac13bfcea67c3ce1d71203d2c.tar.gz
daft-launcher-871706b606c77eeac13bfcea67c3ce1d71203d2c.zip
Adds shared preferences for config/theme storage + refactors a streamstate
Diffstat (limited to '')
-rw-r--r--lib/pages/Home.dart9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/pages/Home.dart b/lib/pages/Home.dart
index 1f4b473..8efa86e 100644
--- a/lib/pages/Home.dart
+++ b/lib/pages/Home.dart
@@ -3,6 +3,7 @@ import 'package:flutter/material.dart';
import 'package:intl/intl.dart';
import '../components/FixedContainer.dart';
+import '../data/config.dart';
class StatusInfoCard extends StatelessWidget {
Stream<DateTime> time$;
@@ -10,7 +11,7 @@ class StatusInfoCard extends StatelessWidget {
StatusInfoCard(this.time$, { this.defaultTime }): super();
- final timeFormat = DateFormat('h:m a'); // H fr 24 hrs
+ final timeFormat = DateFormat('h:mm a'); // H fr 24 hrs
final dateFormat = DateFormat('EEEE, d MMM');
@override
@@ -42,12 +43,16 @@ class StatusInfoCard extends StatelessWidget {
fontWeight: FontWeight.w300,
),
),
+ FlatButton(
+ child: Text('Theme'),
+ onPressed: () { toggleTheme(); }
+ ),
]
);
}
return Container(
- height: 80,
+ height: 300,
padding: EdgeInsets.symmetric(vertical: 8.0),
child: Align(alignment: Alignment.topLeft, child: child),
);