update
This commit is contained in:
parent
57b8bdc067
commit
7e1ad68433
3 changed files with 33 additions and 29 deletions
|
|
@ -109,17 +109,16 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.all(32),
|
padding: EdgeInsets.all(32),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: const Color.fromARGB(219, 38, 17, 46),
|
color: const Color.fromRGBO(38, 17, 46, 0.859),
|
||||||
borderRadius: BorderRadius.all(Radius.circular(16)),
|
borderRadius: BorderRadius.all(Radius.circular(16)),
|
||||||
// boxShadow: [
|
boxShadow: [
|
||||||
// BoxShadow(
|
BoxShadow(
|
||||||
// color: const Color.fromRGBO(0, 0, 0, 1).withOpacity(0.4), // Subtle shadow to give depth
|
color: const Color.fromRGBO(0, 0, 0, 1).withOpacity(0.4), // Subtle shadow to give depth
|
||||||
// spreadRadius: 0,
|
spreadRadius: 0,
|
||||||
// blurRadius: 4,
|
blurRadius: 4,
|
||||||
// offset: Offset(0, 2),
|
offset: Offset(0, 2),
|
||||||
// )
|
)
|
||||||
// ]
|
]),
|
||||||
),
|
|
||||||
child: Form(
|
child: Form(
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
|
|
@ -140,6 +139,9 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
),
|
),
|
||||||
const Gap(24),
|
const Gap(24),
|
||||||
// TextButton(onPressed: () => {_signIn()}, child: const Text('Login'))
|
// TextButton(onPressed: () => {_signIn()}, child: const Text('Login'))
|
||||||
|
if (_isLoading)
|
||||||
|
Center(child: CircularProgressIndicator(color: Colors.white))
|
||||||
|
else
|
||||||
ButtonWidget(text: 'Login', onPressed: _signIn)
|
ButtonWidget(text: 'Login', onPressed: _signIn)
|
||||||
],
|
],
|
||||||
)),
|
)),
|
||||||
|
|
|
||||||
|
|
@ -7,34 +7,36 @@ class MenuWidget extends StatelessWidget {
|
||||||
final String text;
|
final String text;
|
||||||
final IconData? icon;
|
final IconData? icon;
|
||||||
final VoidCallback? onPressed;
|
final VoidCallback? onPressed;
|
||||||
|
final Color? borderColor;
|
||||||
|
|
||||||
const MenuWidget({
|
const MenuWidget({super.key, required this.text, this.icon, this.onPressed, this.borderColor});
|
||||||
super.key,
|
|
||||||
required this.text,
|
|
||||||
this.icon,
|
|
||||||
this.onPressed,
|
|
||||||
});
|
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return GestureDetector(
|
return GestureDetector(
|
||||||
onTap: onPressed,
|
onTap: onPressed,
|
||||||
child: Container(
|
child: Container(
|
||||||
width: MediaQuery.of(context).size.width - 64,
|
width: MediaQuery.of(context).size.width - 96,
|
||||||
height: 80,
|
padding: EdgeInsets.only(top: 16, bottom: 16),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.circular(10),
|
borderRadius: BorderRadius.circular(12),
|
||||||
color: Colors.grey[200],
|
border: Border.all(color: borderColor ?? const Color.fromARGB(255, 255, 255, 255), width: 2),
|
||||||
),
|
),
|
||||||
child: Row(mainAxisAlignment: MainAxisAlignment.start, children: [
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
const Gap(32),
|
const Gap(32),
|
||||||
Icon(icon, size: 32, color: const Color.fromRGBO(34, 51, 69, 1)),
|
Icon(icon, size: 24, color: const Color.fromRGBO(255, 255, 255, 1)),
|
||||||
const Gap(64),
|
const Gap(64),
|
||||||
Text(
|
Text(
|
||||||
text,
|
text,
|
||||||
style: GoogleFonts.outfit(textStyle: const TextStyle(fontSize: 20)),
|
style: GoogleFonts.outfit(
|
||||||
|
color: const Color.fromRGBO(255, 255, 255, 1),
|
||||||
|
textStyle: const TextStyle(fontSize: 16, fontWeight: FontWeight.w500)),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
])),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ class TextWidget extends StatelessWidget {
|
||||||
style: GoogleFonts.outfit(
|
style: GoogleFonts.outfit(
|
||||||
textStyle: TextStyle(
|
textStyle: TextStyle(
|
||||||
color: Color.fromRGBO(255, 255, 255, opacity ?? 1),
|
color: Color.fromRGBO(255, 255, 255, opacity ?? 1),
|
||||||
fontSize: size ?? 32,
|
fontSize: size ?? 28,
|
||||||
fontWeight: bold == true ? FontWeight.bold : FontWeight.normal)));
|
fontWeight: bold == true ? FontWeight.bold : FontWeight.normal)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue