email added to profile view adnd custom text field changes

This commit is contained in:
2024-08-14 15:40:06 +05:30
parent cd83375b98
commit 17c100a035
5 changed files with 141 additions and 120 deletions

View File

@@ -1,3 +1,4 @@
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:ftc_mobile_app/ftc_mobile_app.dart';
import 'package:get/get.dart';
@@ -36,52 +37,62 @@ class _SignInScreenState extends State<SignInScreen> {
height: 132.h,
width: 203.w,
),
CustomTextWidget(
text: ConstantText.kWelcomeBack,
fontColor: CustomAppColors.kIconColor,
fontWeight: FontWeight.w700,
fontSize: 24.sp,
),
CustomTextWidget(
text: ConstantText.kPleaseLoginToContinue,
fontColor: CustomAppColors.kIconColor,
fontWeight: FontWeight.w400,
fontSize: 14.sp,
),
Padding(
padding: EdgeInsets.only(top: 30.0.h),
child: CustomTextFieldWidget(
controller: _controller.emailController,
hintText: ConstantText.kPleaseInputEmail,
heading: ConstantText.kEmailHeading,
onChange: (_){
onChange: (_) {
_controller.validateEmail();
},
),
),
Obx((){
Obx(() {
return CustomErrorMsg(
message: _controller.emailErrorMsg.value,
);
}),
Padding(
padding: EdgeInsets.only(top: 15.0.h),
child: CustomTextFieldWidget(
controller: _controller.passwordController,
hintText: "******",
heading: ConstantText.kPasswordHeading,
onChange: (_){
_controller.validatePassword();
},
isObscure: true,
maxLines: 1,
),
child: Obx(() {
return CustomTextFieldWidget(
controller: _controller.passwordController,
hintText: "******",
heading: ConstantText.kPasswordHeading,
onChange: (_) {
_controller.validatePassword();
},
isObscure: _controller.obsecure(),
maxLines: 1,
suffix: IconButton(
onPressed: _controller.obsecure.toggle,
icon: Icon(
_controller.obsecure.isTrue
? CupertinoIcons.eye_slash
: CupertinoIcons.eye,
color: _controller.obsecure.isTrue
? CustomAppColors.kLightGreyColor
: Get.theme.colorScheme.primary,
size: 24.r,
),
),
);
}),
),
Obx((){
Obx(() {
return CustomErrorMsg(
message: _controller.passwordErrorMsg.value,
);
@@ -110,7 +121,7 @@ class _SignInScreenState extends State<SignInScreen> {
GestureDetector(
onTap: _controller.onForgotButton,
child: CustomTextWidget(
text: ConstantText.kForgotPassword,
text: ConstantText.kForgotPassword,
isExpanded: false,
fontSize: 12.sp,
fontWeight: FontWeight.w500,
@@ -119,14 +130,13 @@ class _SignInScreenState extends State<SignInScreen> {
],
),
),
Padding(
padding: EdgeInsets.only(bottom: 8.0.h),
child: Obx((){
child: Obx(() {
return CustomAppButton(
isLoading: _controller.isLoading.value,
buttonText: ConstantText.kLogIn.toUpperCase(),
onTap: _controller.onLogInButton,
onTap: _controller.onLogInButton,
);
}),
),
@@ -151,7 +161,6 @@ class _SignInScreenState extends State<SignInScreen> {
);
}
@override
void dispose() {
_controller.dispose();