Skip to content

Commit ad6079b

Browse files
committed
login formtypes one,two completed
1 parent 071da60 commit ad6079b

23 files changed

+872
-5
lines changed

assets/icons/close.svg

Lines changed: 4 additions & 0 deletions
Loading

assets/icons/lock.svg

Lines changed: 4 additions & 0 deletions
Loading

assets/icons/mail.svg

Lines changed: 4 additions & 0 deletions
Loading

assets/icons/user.svg

Lines changed: 4 additions & 0 deletions
Loading
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import 'package:flutter/cupertino.dart';
2+
import 'package:flutter/material.dart';
3+
4+
class ButtonPlain extends StatelessWidget {
5+
final Color color;
6+
final Color borderColor;
7+
final Color textColor;
8+
9+
const ButtonPlain({this.color, this.textColor, this.borderColor});
10+
11+
@override
12+
Widget build(BuildContext context) {
13+
return ButtonTheme(
14+
minWidth: MediaQuery.of(context).size.width,
15+
child: RaisedButton(
16+
padding: EdgeInsets.all(16),
17+
color: color,
18+
onPressed: () {
19+
Navigator.pushNamed(context, "/welcome_screen");
20+
},
21+
textColor: textColor,
22+
child: Text(
23+
"Get Started",
24+
style: TextStyle(fontSize: 21.0, fontWeight: FontWeight.bold),
25+
),
26+
shape: RoundedRectangleBorder(
27+
borderRadius: new BorderRadius.circular(16.0)),
28+
),
29+
);
30+
}
31+
}
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
import 'package:contraflutterkit/utils/colors.dart';
2+
import 'package:flutter/cupertino.dart';
3+
import 'package:flutter/material.dart';
4+
5+
class ButtonPlainWithShadow extends StatelessWidget {
6+
final Color borderColor;
7+
final Color shadowColor;
8+
final Color color;
9+
final String text;
10+
final VoidCallback callback;
11+
12+
const ButtonPlainWithShadow(
13+
{this.borderColor,
14+
this.shadowColor,
15+
this.color,
16+
this.text,
17+
this.callback});
18+
19+
@override
20+
Widget build(BuildContext context) {
21+
return GestureDetector(
22+
onTap: callback,
23+
child: ButtonTheme(
24+
child: Container(
25+
width: MediaQuery.of(context).size.width,
26+
child: Text(
27+
text,
28+
textAlign: TextAlign.center,
29+
style: TextStyle(
30+
color: wood_smoke, fontSize: 21, fontWeight: FontWeight.w800),
31+
),
32+
padding: EdgeInsets.all(16),
33+
decoration: ShapeDecoration(
34+
shadows: [
35+
BoxShadow(
36+
color: shadowColor,
37+
offset: Offset(
38+
0.0, // Move to right 10 horizontally
39+
4.0, // Move to bottom 5 Vertically
40+
),
41+
)
42+
],
43+
color: color,
44+
shape: RoundedRectangleBorder(
45+
borderRadius: BorderRadius.all(Radius.circular(16)),
46+
side: BorderSide(color: borderColor, width: 2))),
47+
),
48+
),
49+
);
50+
}
51+
}
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import 'package:flutter/cupertino.dart';
2+
import 'package:flutter_svg/svg.dart';
3+
4+
class ButtonRoundWithShadow extends StatelessWidget {
5+
final Color borderColor;
6+
final Color shadowColor;
7+
final Color color;
8+
final String iconPath;
9+
final VoidCallback callback;
10+
11+
const ButtonRoundWithShadow(
12+
{this.borderColor,
13+
this.shadowColor,
14+
this.color,
15+
this.iconPath,
16+
this.callback});
17+
18+
@override
19+
Widget build(BuildContext context) {
20+
return GestureDetector(
21+
onTap: callback,
22+
child: Container(
23+
padding: EdgeInsets.all(16),
24+
decoration: ShapeDecoration(
25+
shadows: [
26+
BoxShadow(
27+
color: shadowColor,
28+
offset: Offset(
29+
0.0, // Move to right 10 horizontally
30+
4.0, // Move to bottom 5 Vertically
31+
),
32+
)
33+
],
34+
color: color,
35+
shape:
36+
CircleBorder(side: BorderSide(color: borderColor, width: 2))),
37+
child: SvgPicture.asset(iconPath),
38+
),
39+
);
40+
}
41+
}
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
import 'package:contraflutterkit/utils/colors.dart';
2+
import 'package:flutter/cupertino.dart';
3+
import 'package:flutter/material.dart';
4+
import 'package:flutter_svg/svg.dart';
5+
6+
class ButtonSolidWithIcon extends StatelessWidget {
7+
final String text;
8+
final VoidCallback callback;
9+
10+
const ButtonSolidWithIcon({this.text, this.callback});
11+
12+
@override
13+
Widget build(BuildContext context) {
14+
return ButtonTheme(
15+
minWidth: MediaQuery.of(context).size.width,
16+
child: RaisedButton(
17+
padding: EdgeInsets.all(16),
18+
color: wood_smoke,
19+
onPressed: callback,
20+
textColor: white,
21+
child: Row(
22+
mainAxisAlignment: MainAxisAlignment.center,
23+
children: <Widget>[
24+
Text(
25+
text,
26+
style: TextStyle(fontSize: 21.0, fontWeight: FontWeight.bold),
27+
),
28+
Padding(
29+
padding: const EdgeInsets.symmetric(horizontal: 8.0),
30+
child: SvgPicture.asset("assets/icons/arrow_next.svg"),
31+
)
32+
],
33+
),
34+
shape: RoundedRectangleBorder(
35+
borderRadius: new BorderRadius.circular(16.0)),
36+
),
37+
);
38+
}
39+
}

lib/custom_widgets/onboarding_button_round.dart

Whitespace-only changes.

lib/custom_widgets/onboarding_button_solid.dart

Whitespace-only changes.

0 commit comments

Comments
 (0)