Skip to content

Commit 3f5835a

Browse files
committed
settings 3
1 parent 5b55293 commit 3f5835a

File tree

4 files changed

+130
-1
lines changed

4 files changed

+130
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ The code for Springy Widget is taken and refactored from (https://github.com/mat
145145
<img height="480px" src="screenshots/auth3-1.png"> <img height="480px" src="screenshots/auth3-2.png"> <img height="480px" src="screenshots/login7.png"> <img height="480px" src="screenshots/signup2.png"> <img height="480px" src="screenshots/login6.png"> <img height="480px" src="screenshots/auth2.png"> <img height="480px" src="screenshots/login5.png"> <img height="480px" src="screenshots/auth1.png"> <img height="480px" src="screenshots/login4.png"> <img height="480px" src="screenshots/login1.png"> <img height="480px" src="screenshots/login2.png"> <img height="480px" src="screenshots/login3.gif"> <img height="480px" src="screenshots/signup1.png">
146146

147147
## Settings UIs
148-
<img height="480px" src="screenshots/settings1.png"> <img height="480px" src="screenshots/settings2.png">
148+
<img height="480px" src="screenshots/settings1.png"> <img height="480px" src="screenshots/settings2.png"> <img height="480px" src="screenshots/settings3.png">
149149

150150
## Dashboard UIs
151151
<img height="480px" src="screenshots/dash1.png"> <img height="480px" src="screenshots/dash2.png"> <img height="480px" src="screenshots/dash3.png">

lib/core/presentation/routes.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ import 'package:flutter_ui_challenges/src/pages/misc/musicplayer.dart';
1717
import 'package:flutter_ui_challenges/src/pages/onboarding/intro6.dart';
1818
import 'package:flutter_ui_challenges/src/pages/settings/settings1.dart';
1919
import 'package:flutter_ui_challenges/src/pages/settings/settings2.dart';
20+
import 'package:flutter_ui_challenges/src/pages/settings/settings3.dart';
2021
import 'package:flutter_ui_challenges/src/pages/todo/todo_home3.dart';
2122
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
2223
import 'package:flutter_ui_challenges/src/pages/todo/todo2.dart';
@@ -141,6 +142,8 @@ final List<dynamic> pages = [
141142
path: SettingsOnePage.path),
142143
SubMenuItem("Settings Two", SettingsTwoPage(),
143144
path: SettingsTwoPage.path),
145+
SubMenuItem("Settings Three", SettingsThreePage(),
146+
path: SettingsThreePage.path),
144147
]),
145148
MenuItem(title: "Motorbike App", icon: Icons.list, items: [
146149
SubMenuItem("Home Page", BikeHomePage(), path: BikeHomePage.path),

lib/src/pages/settings/settings3.dart

Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
import 'package:cached_network_image/cached_network_image.dart';
2+
/**
3+
* Author: Damodar Lohani
4+
* profile: https://github.com/lohanidamodar
5+
*/
6+
7+
import 'package:flutter/material.dart';
8+
import 'package:flutter_ui_challenges/core/presentation/res/assets.dart';
9+
10+
class SettingsThreePage extends StatelessWidget {
11+
static final String path = "lib/src/pages/settings/settings3.dart";
12+
final TextStyle headerStyle = TextStyle(
13+
color: Colors.grey.shade800,
14+
fontWeight: FontWeight.bold,
15+
fontSize: 20.0,
16+
);
17+
@override
18+
Widget build(BuildContext context) {
19+
return Scaffold(
20+
backgroundColor: Colors.grey.shade200,
21+
appBar: AppBar(
22+
backgroundColor: Colors.green,
23+
title: Text(
24+
'Settings',
25+
),
26+
),
27+
body: SingleChildScrollView(
28+
padding: const EdgeInsets.all(16.0),
29+
child: Column(
30+
crossAxisAlignment: CrossAxisAlignment.start,
31+
children: <Widget>[
32+
Text(
33+
"ACCOUNT",
34+
style: headerStyle,
35+
),
36+
const SizedBox(height: 10.0),
37+
Card(
38+
elevation: 0.5,
39+
margin: const EdgeInsets.symmetric(
40+
vertical: 4.0,
41+
horizontal: 0,
42+
),
43+
child: Column(
44+
children: <Widget>[
45+
ListTile(
46+
leading: CircleAvatar(
47+
backgroundImage: NetworkImage(avatars[4]),
48+
),
49+
title: Text("Damodar Lohani"),
50+
onTap: () {},
51+
),
52+
_buildDivider(),
53+
SwitchListTile(
54+
activeColor: Colors.purple,
55+
value: true,
56+
title: Text("Private Account"),
57+
onChanged: (val) {},
58+
),
59+
],
60+
),
61+
),
62+
const SizedBox(height: 20.0),
63+
Text(
64+
"PUSH NOTIFICATIONS",
65+
style: headerStyle,
66+
),
67+
Card(
68+
margin: const EdgeInsets.symmetric(vertical: 8.0, horizontal: 0,),
69+
child: Column(
70+
children: <Widget>[
71+
SwitchListTile(
72+
activeColor: Colors.purple,
73+
value: true,
74+
title: Text("Received notification"),
75+
onChanged: (val) {},
76+
),
77+
_buildDivider(),
78+
SwitchListTile(
79+
activeColor: Colors.purple,
80+
value: false,
81+
title: Text("Received newsletter"),
82+
onChanged: null,
83+
),
84+
_buildDivider(),
85+
SwitchListTile(
86+
activeColor: Colors.purple,
87+
value: true,
88+
title: Text("Received Offer Notification"),
89+
onChanged: (val) {},
90+
),
91+
_buildDivider(),
92+
SwitchListTile(
93+
activeColor: Colors.purple,
94+
value: true,
95+
title: Text("Received App Updates"),
96+
onChanged: null,
97+
),
98+
],
99+
),
100+
),
101+
Card(
102+
margin: const EdgeInsets.symmetric(vertical: 8.0, horizontal: 0,),
103+
child: ListTile(
104+
leading: Icon(Icons.exit_to_app),
105+
title: Text("Logout"),
106+
onTap: (){},
107+
),
108+
),
109+
const SizedBox(height: 60.0),
110+
],
111+
),
112+
),
113+
);
114+
}
115+
116+
Container _buildDivider() {
117+
return Container(
118+
margin: const EdgeInsets.symmetric(
119+
horizontal: 8.0,
120+
),
121+
width: double.infinity,
122+
height: 1.0,
123+
color: Colors.grey.shade300,
124+
);
125+
}
126+
}

screenshots/settings3.png

144 KB
Loading

0 commit comments

Comments
 (0)