forgot password ui added
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 121 KiB |
@@ -22,6 +22,9 @@ class AssetsManager {
|
||||
static const passwordVisibilityOff =
|
||||
'assets/svgs/password_visibility_off.svg';
|
||||
|
||||
//forgot password page
|
||||
static const forgotPasswordImage = 'assets/pngs/forgot_password.png';
|
||||
|
||||
// tenders page
|
||||
static const tenderLogo = 'assets/icons/tenderLogo.png';
|
||||
static const like = 'assets/icons/like.svg';
|
||||
|
||||
@@ -25,6 +25,14 @@ class AppStrings {
|
||||
static const passwordLabel = 'Password';
|
||||
static const loginButton = 'Login';
|
||||
|
||||
//forgot password
|
||||
static const String forgotPasswordTitle = 'Forgot Password';
|
||||
static const String forgotPasswordSubtitle =
|
||||
'Enter your registered email and company ID and submit your request.';
|
||||
static const String emailAddressHint = 'Email Address';
|
||||
static const String backToSignInButton = 'Back to Sign In';
|
||||
static const String resetLink = 'Reset Link';
|
||||
|
||||
//Home
|
||||
static const String home = 'Home';
|
||||
static const String partnership = 'Partnership';
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:tm_app/views/detail/pages/detail_screen.dart';
|
||||
import 'package:tm_app/views/home/pages/home_screen.dart';
|
||||
import 'package:tm_app/views/login/pages/login_screen.dart';
|
||||
|
||||
import '../../views/forgot_password/pages/forgot_password_screen.dart';
|
||||
import '../../views/profile/pages/profile_screen.dart';
|
||||
import '../../views/tenders/pages/tenders_screen.dart';
|
||||
import '../../views/your_tenders/pages/your_tenders_screen.dart';
|
||||
@@ -157,3 +158,14 @@ class TenderDetailRouteData extends GoRouteData with _$TenderDetailRouteData {
|
||||
return TenderDetailScreen(tenderId: tenderId);
|
||||
}
|
||||
}
|
||||
|
||||
@TypedGoRoute<ForgotPasswordRouteData>(path: '/forgot-password')
|
||||
class ForgotPasswordRouteData extends GoRouteData
|
||||
with _$ForgotPasswordRouteData {
|
||||
const ForgotPasswordRouteData();
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context, GoRouterState state) {
|
||||
return ForgotPasswordScreen();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ List<RouteBase> get $appRoutes => [
|
||||
$appShellRouteData,
|
||||
$yourTendersRouteData,
|
||||
$tenderDetailRouteData,
|
||||
$forgotPasswordRouteData,
|
||||
];
|
||||
|
||||
RouteBase get $loginScreenRoute =>
|
||||
@@ -198,3 +199,30 @@ mixin _$TenderDetailRouteData on GoRouteData {
|
||||
@override
|
||||
void replace(BuildContext context) => context.replace(location);
|
||||
}
|
||||
|
||||
RouteBase get $forgotPasswordRouteData => GoRouteData.$route(
|
||||
path: '/forgot-password',
|
||||
|
||||
factory: _$ForgotPasswordRouteData._fromState,
|
||||
);
|
||||
|
||||
mixin _$ForgotPasswordRouteData on GoRouteData {
|
||||
static ForgotPasswordRouteData _fromState(GoRouterState state) =>
|
||||
const ForgotPasswordRouteData();
|
||||
|
||||
@override
|
||||
String get location => GoRouteData.$location('/forgot-password');
|
||||
|
||||
@override
|
||||
void go(BuildContext context) => context.go(location);
|
||||
|
||||
@override
|
||||
Future<T?> push<T>(BuildContext context) => context.push<T>(location);
|
||||
|
||||
@override
|
||||
void pushReplacement(BuildContext context) =>
|
||||
context.pushReplacement(location);
|
||||
|
||||
@override
|
||||
void replace(BuildContext context) => context.replace(location);
|
||||
}
|
||||
|
||||
@@ -17,6 +17,9 @@ class $AssetsIconsGen {
|
||||
/// File path: assets/icons/SE.png
|
||||
AssetGenImage get se => const AssetGenImage('assets/icons/SE.png');
|
||||
|
||||
/// File path: assets/icons/approve.svg
|
||||
String get approve => 'assets/icons/approve.svg';
|
||||
|
||||
/// File path: assets/icons/arrow-circle-left.svg
|
||||
String get arrowCircleLeft => 'assets/icons/arrow-circle-left.svg';
|
||||
|
||||
@@ -59,6 +62,12 @@ class $AssetsIconsGen {
|
||||
/// File path: assets/icons/location.svg
|
||||
String get location => 'assets/icons/location.svg';
|
||||
|
||||
/// File path: assets/icons/logo_big.svg
|
||||
String get logoBig => 'assets/icons/logo_big.svg';
|
||||
|
||||
/// File path: assets/icons/logo_small.svg
|
||||
String get logoSmall => 'assets/icons/logo_small.svg';
|
||||
|
||||
/// File path: assets/icons/menu.svg
|
||||
String get menu => 'assets/icons/menu.svg';
|
||||
|
||||
@@ -96,6 +105,9 @@ class $AssetsIconsGen {
|
||||
/// File path: assets/icons/thumb.svg
|
||||
String get thumb => 'assets/icons/thumb.svg';
|
||||
|
||||
/// File path: assets/icons/thumb_like.svg
|
||||
String get thumbLike => 'assets/icons/thumb_like.svg';
|
||||
|
||||
/// File path: assets/icons/tick-circle.svg
|
||||
String get tickCircle => 'assets/icons/tick-circle.svg';
|
||||
|
||||
@@ -105,6 +117,7 @@ class $AssetsIconsGen {
|
||||
/// List of all assets
|
||||
List<dynamic> get values => [
|
||||
se,
|
||||
approve,
|
||||
arrowCircleLeft,
|
||||
arrowCircleRight,
|
||||
arrowLeftSmall,
|
||||
@@ -119,6 +132,8 @@ class $AssetsIconsGen {
|
||||
homeActive,
|
||||
like,
|
||||
location,
|
||||
logoBig,
|
||||
logoSmall,
|
||||
menu,
|
||||
moon,
|
||||
notification,
|
||||
@@ -131,6 +146,7 @@ class $AssetsIconsGen {
|
||||
tenderLogoPng,
|
||||
tenderLogoSvg,
|
||||
thumb,
|
||||
thumbLike,
|
||||
tickCircle,
|
||||
tick,
|
||||
];
|
||||
|
||||
@@ -19,8 +19,10 @@ class AuthViewModel with ChangeNotifier {
|
||||
|
||||
final TextEditingController usernameController = TextEditingController();
|
||||
final TextEditingController passwordController = TextEditingController();
|
||||
final TextEditingController emailController = TextEditingController();
|
||||
final FocusNode usernameFocus = FocusNode();
|
||||
final FocusNode passwordFocus = FocusNode();
|
||||
final FocusNode emailFocus = FocusNode();
|
||||
|
||||
bool _obscurePassword = true;
|
||||
bool get obscurePassword => _obscurePassword;
|
||||
|
||||
@@ -0,0 +1,116 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/svg.dart';
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:tm_app/core/utils/size_config.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
import '../../../core/constants/strings.dart';
|
||||
import '../../../core/theme/colors.dart';
|
||||
import '../../../view_models/auth_view_model.dart';
|
||||
import '../../login/widgets/login_textfield.dart';
|
||||
import '../../shared/base_button.dart';
|
||||
|
||||
class DesktopForgotPasswordPage extends StatelessWidget {
|
||||
const DesktopForgotPasswordPage({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
backgroundColor: AppColors.backgroundColor,
|
||||
body: Center(
|
||||
child: Consumer<AuthViewModel>(
|
||||
builder: (context, viewModel, _) {
|
||||
return Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 120),
|
||||
child: SizedBox(
|
||||
width: 364,
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 22.0.w()),
|
||||
child: SvgPicture.asset(
|
||||
AssetsManager.logoBig,
|
||||
width: double.infinity,
|
||||
height: 50.0.h(),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 72.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordTitle,
|
||||
style: TextStyle(
|
||||
fontSize: 28.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: AppColors.grey80,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 16.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordSubtitle,
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColors.grey60,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 40.0.h()),
|
||||
LoginTextField(
|
||||
controller: viewModel.emailController,
|
||||
focusNode: viewModel.emailFocus,
|
||||
label: AppStrings.emailAddressHint,
|
||||
isPassword: false,
|
||||
),
|
||||
SizedBox(height: 70.0.h()),
|
||||
BaseButton(
|
||||
isEnabled: false,
|
||||
text: AppStrings.resetLink,
|
||||
onPressed: () async {
|
||||
if (viewModel.isLoginEnabled) {
|
||||
await viewModel.login();
|
||||
}
|
||||
},
|
||||
),
|
||||
SizedBox(height: 12),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
context.pop();
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.backToSignInButton,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(vertical: 20.0.h()),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(32.0),
|
||||
child: Image.asset(
|
||||
AssetsManager.forgotPasswordImage,
|
||||
width: 796.0,
|
||||
height: 944.0,
|
||||
fit: BoxFit.fitWidth,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import '../../shared/responsive_builder.dart';
|
||||
import 'd_forgot_apssword_page.dart';
|
||||
import 'm_forgot_password_page.dart';
|
||||
import 't_forgot_password_page.dart';
|
||||
|
||||
class ForgotPasswordScreen extends StatelessWidget {
|
||||
const ForgotPasswordScreen({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return ResponsiveBuilder(
|
||||
mobile: MobileForgotPasswordPage(),
|
||||
tablet: TabletForgotPasswordPage(),
|
||||
desktop: DesktopForgotPasswordPage(),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/svg.dart';
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:tm_app/core/utils/size_config.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
import '../../../core/constants/strings.dart';
|
||||
import '../../../core/theme/colors.dart';
|
||||
import '../../../view_models/auth_view_model.dart';
|
||||
import '../../login/widgets/login_textfield.dart';
|
||||
import '../../shared/base_button.dart';
|
||||
|
||||
class MobileForgotPasswordPage extends StatelessWidget {
|
||||
const MobileForgotPasswordPage({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
backgroundColor: AppColors.backgroundColor,
|
||||
body: Center(
|
||||
child: SingleChildScrollView(
|
||||
padding: EdgeInsets.symmetric(horizontal: 24.0.w()),
|
||||
child: Consumer<AuthViewModel>(
|
||||
builder: (context, viewModel, _) {
|
||||
return Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 22.0.w()),
|
||||
child: SvgPicture.asset(
|
||||
AssetsManager.logoBig,
|
||||
width: double.infinity,
|
||||
height: 50.0.h(),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 72.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordTitle,
|
||||
style: TextStyle(
|
||||
fontSize: 28.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: AppColors.grey80,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 16.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordSubtitle,
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColors.grey60,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 40.0.h()),
|
||||
LoginTextField(
|
||||
controller: viewModel.emailController,
|
||||
focusNode: viewModel.emailFocus,
|
||||
label: AppStrings.emailAddressHint,
|
||||
isPassword: false,
|
||||
),
|
||||
SizedBox(height: 70.0.h()),
|
||||
BaseButton(
|
||||
isEnabled: false,
|
||||
text: AppStrings.resetLink,
|
||||
onPressed: () async {
|
||||
if (viewModel.isLoginEnabled) {
|
||||
await viewModel.login();
|
||||
}
|
||||
},
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
context.pop();
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.backToSignInButton,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/svg.dart';
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:tm_app/core/utils/size_config.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
import '../../../core/constants/strings.dart';
|
||||
import '../../../core/theme/colors.dart';
|
||||
import '../../../view_models/auth_view_model.dart';
|
||||
import '../../login/widgets/login_textfield.dart';
|
||||
import '../../shared/base_button.dart';
|
||||
|
||||
class TabletForgotPasswordPage extends StatelessWidget {
|
||||
const TabletForgotPasswordPage({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
body: Consumer<AuthViewModel>(
|
||||
builder: (context, viewModel, _) {
|
||||
return Center(
|
||||
child: SizedBox(
|
||||
width: 364,
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 22.0.w()),
|
||||
child: SvgPicture.asset(
|
||||
AssetsManager.logoBig,
|
||||
width: double.infinity,
|
||||
height: 50.0.h(),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 72.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordTitle,
|
||||
style: TextStyle(
|
||||
fontSize: 28.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: AppColors.grey80,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 16.0.h()),
|
||||
Text(
|
||||
AppStrings.forgotPasswordSubtitle,
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColors.grey60,
|
||||
),
|
||||
),
|
||||
SizedBox(height: 40.0.h()),
|
||||
LoginTextField(
|
||||
controller: viewModel.emailController,
|
||||
focusNode: viewModel.emailFocus,
|
||||
label: AppStrings.emailAddressHint,
|
||||
isPassword: false,
|
||||
),
|
||||
SizedBox(height: 70.0.h()),
|
||||
BaseButton(
|
||||
isEnabled: false,
|
||||
text: AppStrings.resetLink,
|
||||
onPressed: () async {
|
||||
if (viewModel.isLoginEnabled) {
|
||||
await viewModel.login();
|
||||
}
|
||||
},
|
||||
),
|
||||
SizedBox(height: 12),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
context.pop();
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.backToSignInButton,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -7,6 +7,7 @@ import 'package:tm_app/core/theme/colors.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
import '../../../core/constants/strings.dart';
|
||||
import '../../../core/routes/app_routes.dart';
|
||||
import '../../../core/utils/size_config.dart';
|
||||
import '../../../view_models/auth_view_model.dart';
|
||||
import '../widgets/widgets.dart';
|
||||
@@ -46,7 +47,6 @@ class _LoginDesktopPageState extends State<LoginDesktopPage> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
SizeConfig.init(context);
|
||||
return Scaffold(
|
||||
backgroundColor: AppColors.backgroundColor,
|
||||
body: Center(
|
||||
@@ -55,7 +55,7 @@ class _LoginDesktopPageState extends State<LoginDesktopPage> {
|
||||
kIsWeb ? MainAxisAlignment.spaceAround : MainAxisAlignment.center,
|
||||
children: [
|
||||
SizedBox(
|
||||
width: 526,
|
||||
width: 536,
|
||||
child: Consumer<AuthViewModel>(
|
||||
builder: (context, viewModel, _) {
|
||||
return Column(
|
||||
@@ -108,6 +108,20 @@ class _LoginDesktopPageState extends State<LoginDesktopPage> {
|
||||
}
|
||||
},
|
||||
),
|
||||
SizedBox(height: 32.0),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
ForgotPasswordRouteData().push(context);
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.forgotPassword,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
|
||||
@@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/svg.dart';
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:tm_app/core/routes/app_routes.dart';
|
||||
import 'package:tm_app/core/theme/colors.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
@@ -103,6 +104,20 @@ class _LoginMobilePageState extends State<LoginMobilePage> {
|
||||
}
|
||||
},
|
||||
),
|
||||
SizedBox(height: 32.0.h()),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
ForgotPasswordRouteData().push(context);
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.forgotPassword,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:tm_app/core/theme/colors.dart';
|
||||
|
||||
import '../../../core/constants/assets.dart';
|
||||
import '../../../core/constants/strings.dart';
|
||||
import '../../../core/routes/app_routes.dart';
|
||||
import '../../../core/utils/size_config.dart';
|
||||
import '../../../view_models/auth_view_model.dart';
|
||||
import '../widgets/widgets.dart';
|
||||
@@ -45,7 +46,6 @@ class _LoginTabletPageState extends State<LoginTabletPage> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
SizeConfig.init(context);
|
||||
return Scaffold(
|
||||
backgroundColor: AppColors.backgroundColor,
|
||||
body: Center(
|
||||
@@ -101,6 +101,20 @@ class _LoginTabletPageState extends State<LoginTabletPage> {
|
||||
}
|
||||
: null,
|
||||
),
|
||||
SizedBox(height: 32.0),
|
||||
TextButton(
|
||||
onPressed: () {
|
||||
ForgotPasswordRouteData().push(context);
|
||||
},
|
||||
child: Text(
|
||||
AppStrings.forgotPassword,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0.sp(),
|
||||
fontWeight: FontWeight.w500,
|
||||
color: AppColors.mainBlue,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
|
||||
@@ -9,7 +9,7 @@ class LoginTextField extends StatelessWidget {
|
||||
final TextEditingController controller;
|
||||
final FocusNode focusNode;
|
||||
final String label;
|
||||
final String iconPath;
|
||||
final String? iconPath;
|
||||
final bool isPassword;
|
||||
final bool obscureText;
|
||||
final double? borderRedus;
|
||||
@@ -21,7 +21,7 @@ class LoginTextField extends StatelessWidget {
|
||||
required this.controller,
|
||||
required this.focusNode,
|
||||
required this.label,
|
||||
required this.iconPath,
|
||||
this.iconPath,
|
||||
super.key,
|
||||
this.isPassword = false,
|
||||
this.obscureText = false,
|
||||
@@ -45,18 +45,23 @@ class LoginTextField extends StatelessWidget {
|
||||
horizontal: 12.0.w(),
|
||||
),
|
||||
labelText: label,
|
||||
prefixIcon: Padding(
|
||||
prefixIcon:
|
||||
iconPath != null
|
||||
? Padding(
|
||||
padding: EdgeInsets.all(prefixIconPadding ?? 12.0.w()),
|
||||
child: SvgPicture.asset(
|
||||
iconPath,
|
||||
iconPath!,
|
||||
width: 24.0.w(),
|
||||
height: 24.0.h(),
|
||||
colorFilter: ColorFilter.mode(
|
||||
focusNode.hasFocus ? AppColors.grey80 : AppColors.grey60,
|
||||
focusNode.hasFocus
|
||||
? AppColors.grey80
|
||||
: AppColors.grey60,
|
||||
BlendMode.srcIn,
|
||||
),
|
||||
),
|
||||
),
|
||||
)
|
||||
: null,
|
||||
suffixIcon:
|
||||
isPassword
|
||||
? IconButton(
|
||||
|
||||
Reference in New Issue
Block a user