From 0d2dfc817e2060d4230be1c33ae97c63ef7a27f9 Mon Sep 17 00:00:00 2001 From: Md Asif Date: Mon, 2 Jun 2025 10:42:54 +0530 Subject: [PATCH] Refactor UI components across various screens to use SVG avatars, enhance biometric authentication check, and improve code readability with consistent formatting. --- .../arm64-v8a/configure_fingerprint.bin | 24 ++--- .../armeabi-v7a/configure_fingerprint.bin | 24 ++--- .../y4m3m96g/x86/configure_fingerprint.bin | 24 ++--- .../y4m3m96g/x86_64/configure_fingerprint.bin | 24 ++--- lib/features/auth/screens/mpin_screen.dart | 2 +- .../screens/add_beneficiary_screen.dart | 17 ++-- .../screens/manage_beneficiaries_screen.dart | 43 +++++---- .../card/screens/block_card_screen.dart | 51 +++++++---- .../card/screens/card_management_screen.dart | 58 +++++++----- .../card_pin_change_details_screen.dart | 54 ++++++----- .../card/screens/card_pin_set_screen.dart | 30 ++++--- .../screens/cheque_management_screen.dart | 90 ++++++++++--------- .../enquiry/screens/enquiry_screen.dart | 31 ++++--- .../fund_transfer_beneficiary_screen.dart | 54 +++++++---- .../quick_pay_outside_bank_screen.dart | 14 ++- .../quick_pay/screens/quick_pay_screen.dart | 14 ++- .../screens/quick_pay_within_bank_screen.dart | 23 +++-- 17 files changed, 346 insertions(+), 231 deletions(-) diff --git a/android/app/.cxx/Debug/y4m3m96g/arm64-v8a/configure_fingerprint.bin b/android/app/.cxx/Debug/y4m3m96g/arm64-v8a/configure_fingerprint.bin index 1cade60..b6f275a 100644 --- a/android/app/.cxx/Debug/y4m3m96g/arm64-v8a/configure_fingerprint.bin +++ b/android/app/.cxx/Debug/y4m3m96g/arm64-v8a/configure_fingerprint.bin @@ -2,27 +2,27 @@ C/C++ Structured Log` ^ \D:\development_kits\flutter_sdk\packages\flutter_tools\gradle\src\main\groovy\CMakeLists.txtC A -?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  2 撅2Z +?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  Ͱ2 撅2Z X -VD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\additional_project_files.txt  2  2W +VD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\additional_project_files.txt  Ͱ2  2W U -SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\android_gradle_build.json  2 2\ +SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\android_gradle_build.json  Ͱ2 2\ Z -XD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\android_gradle_build_mini.json  2 2I +XD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\android_gradle_build_mini.json  Ͱ2 2I G -ED:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build.ninja  2 2M +ED:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build.ninja  Ͱ2 2M K -ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build.ninja.txt  2R +ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build.ninja.txt  Ͱ2R P -ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build_file_index.txt  2 \ 2S +ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\build_file_index.txt  Ͱ2 \ 2S Q -OD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\compile_commands.json  2 W +OD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\compile_commands.json  Ͱ2 W U -SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\compile_commands.json.bin  2 +SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\compile_commands.json.bin  Ͱ2 ] [ -YD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\metadata_generation_command.txt  2  2P +YD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\metadata_generation_command.txt  Ͱ2  2P N -LD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\prefab_config.json  2  ( 2U +LD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\prefab_config.json  Ͱ2  ( 2U S -QD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\symbol_folder_index.txt  2  H 2 \ No newline at end of file +QD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\arm64-v8a\symbol_folder_index.txt  Ͱ2  H 2 \ No newline at end of file diff --git a/android/app/.cxx/Debug/y4m3m96g/armeabi-v7a/configure_fingerprint.bin b/android/app/.cxx/Debug/y4m3m96g/armeabi-v7a/configure_fingerprint.bin index 426346e..42ee3d1 100644 --- a/android/app/.cxx/Debug/y4m3m96g/armeabi-v7a/configure_fingerprint.bin +++ b/android/app/.cxx/Debug/y4m3m96g/armeabi-v7a/configure_fingerprint.bin @@ -2,27 +2,27 @@ C/C++ Structured Log` ^ \D:\development_kits\flutter_sdk\packages\flutter_tools\gradle\src\main\groovy\CMakeLists.txtC A -?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  2 撅2\ +?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ΰ2 撅2\ Z -XD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\additional_project_files.txt  2  2Y +XD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\additional_project_files.txt  ΰ2  2Y W -UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\android_gradle_build.json  2 2^ +UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\android_gradle_build.json  ΰ2 2^ \ -ZD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\android_gradle_build_mini.json  2 2K +ZD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\android_gradle_build_mini.json  ΰ2 2K I -GD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build.ninja  2 2O +GD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build.ninja  ΰ2 2O M -KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build.ninja.txt  2T +KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build.ninja.txt  ΰ2T R -PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build_file_index.txt  2 \ 2U +PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\build_file_index.txt  ΰ2 \ 2U S -QD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\compile_commands.json  2 Y +QD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\compile_commands.json  ΰ2 Y W -UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\compile_commands.json.bin  2 +UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\compile_commands.json.bin  ΰ2 _ ] -[D:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\metadata_generation_command.txt  2  2R +[D:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\metadata_generation_command.txt  ΰ2  2R P -ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\prefab_config.json  2  ( 2W +ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\prefab_config.json  ΰ2  ( 2W U -SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\symbol_folder_index.txt  2  J 2 \ No newline at end of file +SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\armeabi-v7a\symbol_folder_index.txt  ΰ2  J 2 \ No newline at end of file diff --git a/android/app/.cxx/Debug/y4m3m96g/x86/configure_fingerprint.bin b/android/app/.cxx/Debug/y4m3m96g/x86/configure_fingerprint.bin index b08caef..8ea7396 100644 --- a/android/app/.cxx/Debug/y4m3m96g/x86/configure_fingerprint.bin +++ b/android/app/.cxx/Debug/y4m3m96g/x86/configure_fingerprint.bin @@ -2,27 +2,27 @@ C/C++ Structured Log` ^ \D:\development_kits\flutter_sdk\packages\flutter_tools\gradle\src\main\groovy\CMakeLists.txtC A -?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  2 撅2T +?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ΰ2 撅2T R -PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\additional_project_files.txt  2  2Q +PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\additional_project_files.txt  ΰ2  2Q O -MD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\android_gradle_build.json  2 2V +MD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\android_gradle_build.json  ΰ2 2V T -RD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\android_gradle_build_mini.json  2 2C +RD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\android_gradle_build_mini.json  ΰ2 2C A -?D:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build.ninja  2 2G +?D:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build.ninja  ΰ2 2G E -CD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build.ninja.txt  2L +CD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build.ninja.txt  ΰ2L J -HD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build_file_index.txt  2 \ 2M +HD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\build_file_index.txt  ΰ2 \ 2M K -ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\compile_commands.json  2 Q +ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\compile_commands.json  ΰ2 Q O -MD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\compile_commands.json.bin  2 +MD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\compile_commands.json.bin  ΰ2 W U -SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\metadata_generation_command.txt  2  2J +SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\metadata_generation_command.txt  ΰ2  2J H -FD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\prefab_config.json  2  ( 2O +FD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\prefab_config.json  ΰ2  ( 2O M -KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\symbol_folder_index.txt  2  B 2 \ No newline at end of file +KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86\symbol_folder_index.txt  ΰ2  B 2 \ No newline at end of file diff --git a/android/app/.cxx/Debug/y4m3m96g/x86_64/configure_fingerprint.bin b/android/app/.cxx/Debug/y4m3m96g/x86_64/configure_fingerprint.bin index 7121237..c713da5 100644 --- a/android/app/.cxx/Debug/y4m3m96g/x86_64/configure_fingerprint.bin +++ b/android/app/.cxx/Debug/y4m3m96g/x86_64/configure_fingerprint.bin @@ -2,27 +2,27 @@ C/C++ Structured Log` ^ \D:\development_kits\flutter_sdk\packages\flutter_tools\gradle\src\main\groovy\CMakeLists.txtC A -?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  2 撅2W +?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ΰ2 撅2W U -SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\additional_project_files.txt  2  ڨ2T +SD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\additional_project_files.txt  ΰ2  ڨ2T R -PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\android_gradle_build.json  2 ۨ2Y +PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\android_gradle_build.json  ΰ2 ۨ2Y W -UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\android_gradle_build_mini.json  2 ި2F +UD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\android_gradle_build_mini.json  ΰ2 ި2F D -BD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build.ninja  2 2J +BD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build.ninja  ΰ2 2J H -FD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build.ninja.txt  2O +FD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build.ninja.txt  ΰ2O M -KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build_file_index.txt  2 \ ߨ2P +KD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\build_file_index.txt  ΰ2 \ ߨ2P N -LD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\compile_commands.json  2 T +LD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\compile_commands.json  ΰ2 T R -PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\compile_commands.json.bin  2 +PD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\compile_commands.json.bin  ΰ2 Z X -VD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\metadata_generation_command.txt  2  ި2M +VD:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\metadata_generation_command.txt  ΰ2  ި2M K -ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\prefab_config.json  2  ( ި2R +ID:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\prefab_config.json  ΰ2  ( ި2R P -ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\symbol_folder_index.txt  2  E ި2 \ No newline at end of file +ND:\work\kmobile\android\app\.cxx\Debug\y4m3m96g\x86_64\symbol_folder_index.txt  ΰ2  E ި2 \ No newline at end of file diff --git a/lib/features/auth/screens/mpin_screen.dart b/lib/features/auth/screens/mpin_screen.dart index d653361..913242d 100644 --- a/lib/features/auth/screens/mpin_screen.dart +++ b/lib/features/auth/screens/mpin_screen.dart @@ -40,7 +40,7 @@ class _MPinScreenState extends State { final storage = getIt(); final enabled = await storage.read('biometric_enabled'); log('biometric_enabled: $enabled'); - if (enabled) { + if (enabled != null && enabled) { final auth = LocalAuthentication(); if (await auth.canCheckBiometrics) { final didAuth = await auth.authenticate( diff --git a/lib/features/beneficiaries/screens/add_beneficiary_screen.dart b/lib/features/beneficiaries/screens/add_beneficiary_screen.dart index b79127a..b0c2ce3 100644 --- a/lib/features/beneficiaries/screens/add_beneficiary_screen.dart +++ b/lib/features/beneficiaries/screens/add_beneficiary_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; class AddBeneficiaryScreen extends StatefulWidget { @@ -71,13 +72,19 @@ class _AddBeneficiaryScreen extends State{ title: const Text('Add Beneficiary', style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500),), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image - radius: 20, - ), + backgroundColor: Colors.grey[200], + radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), + ), ), ], ), diff --git a/lib/features/beneficiaries/screens/manage_beneficiaries_screen.dart b/lib/features/beneficiaries/screens/manage_beneficiaries_screen.dart index 9b0a546..eec1461 100644 --- a/lib/features/beneficiaries/screens/manage_beneficiaries_screen.dart +++ b/lib/features/beneficiaries/screens/manage_beneficiaries_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:kmobile/features/beneficiaries/screens/add_beneficiary_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -6,10 +7,11 @@ class ManageBeneficiariesScreen extends StatefulWidget { const ManageBeneficiariesScreen({super.key}); @override - State createState() => _ManageBeneficiariesScreen(); + State createState() => + _ManageBeneficiariesScreen(); } -class _ManageBeneficiariesScreen extends State{ +class _ManageBeneficiariesScreen extends State { final List> beneficiaries = [ { 'bank': 'State Bank Of India', @@ -33,24 +35,33 @@ class _ManageBeneficiariesScreen extends State{ Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Beneficiaries', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Beneficiaries', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: Padding( padding: const EdgeInsets.all(8.0), child: ListView.builder( @@ -59,8 +70,7 @@ class _ManageBeneficiariesScreen extends State{ final beneficiary = beneficiaries[index]; return ListTile( leading: const CircleAvatar( - backgroundColor: Colors.blue, - child: Text('A')), + backgroundColor: Colors.blue, child: Text('A')), title: Text(beneficiary['name']!), subtitle: Text(beneficiary['bank']!), trailing: IconButton( @@ -77,8 +87,10 @@ class _ManageBeneficiariesScreen extends State{ padding: const EdgeInsets.only(bottom: 8.0), child: FloatingActionButton( onPressed: () { - Navigator.push(context, MaterialPageRoute( - builder: (context) => const AddBeneficiaryScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const AddBeneficiaryScreen())); }, backgroundColor: Colors.grey[300], foregroundColor: Colors.blue[900], @@ -88,5 +100,4 @@ class _ManageBeneficiariesScreen extends State{ ), ); } - -} \ No newline at end of file +} diff --git a/lib/features/card/screens/block_card_screen.dart b/lib/features/card/screens/block_card_screen.dart index 47b27dc..f670640 100644 --- a/lib/features/card/screens/block_card_screen.dart +++ b/lib/features/card/screens/block_card_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:intl/intl.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -9,7 +10,7 @@ class BlockCardScreen extends StatefulWidget { State createState() => _BlockCardScreen(); } -class _BlockCardScreen extends State{ +class _BlockCardScreen extends State { final _formKey = GlobalKey(); final _cardController = TextEditingController(); final _cvvController = TextEditingController(); @@ -54,24 +55,33 @@ class _BlockCardScreen extends State{ Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Block Card', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Block Card', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: Padding( padding: const EdgeInsets.all(10.0), child: Form( @@ -96,8 +106,9 @@ class _BlockCardScreen extends State{ ), keyboardType: TextInputType.number, textInputAction: TextInputAction.next, - validator: (value) => - value != null && value.length == 16 ? null : 'Enter valid card number', + validator: (value) => value != null && value.length == 16 + ? null + : 'Enter valid card number', ), const SizedBox(height: 24), Row( @@ -121,8 +132,9 @@ class _BlockCardScreen extends State{ keyboardType: TextInputType.number, textInputAction: TextInputAction.next, obscureText: true, - validator: (value) => - value != null && value.length == 3 ? null : 'CVV must be 3 digits', + validator: (value) => value != null && value.length == 3 + ? null + : 'CVV must be 3 digits', ), ), const SizedBox(width: 16), @@ -145,8 +157,9 @@ class _BlockCardScreen extends State{ borderSide: BorderSide(color: Colors.black, width: 2), ), ), - validator: (value) => - value != null && value.isNotEmpty ? null : 'Select expiry date', + validator: (value) => value != null && value.isNotEmpty + ? null + : 'Select expiry date', ), ), ], @@ -170,8 +183,9 @@ class _BlockCardScreen extends State{ ), textInputAction: TextInputAction.done, keyboardType: TextInputType.phone, - validator: (value) => - value != null && value.length >= 10 ? null : 'Enter valid phone number', + validator: (value) => value != null && value.length >= 10 + ? null + : 'Enter valid phone number', ), const SizedBox(height: 45), Align( @@ -196,5 +210,4 @@ class _BlockCardScreen extends State{ ), ); } - -} \ No newline at end of file +} diff --git a/lib/features/card/screens/card_management_screen.dart b/lib/features/card/screens/card_management_screen.dart index cfb725a..a9702c3 100644 --- a/lib/features/card/screens/card_management_screen.dart +++ b/lib/features/card/screens/card_management_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:kmobile/features/card/screens/block_card_screen.dart'; import 'package:kmobile/features/card/screens/card_pin_change_details_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -10,60 +11,70 @@ class CardManagementScreen extends StatefulWidget { State createState() => _CardManagementScreen(); } -class _CardManagementScreen extends State{ +class _CardManagementScreen extends State { @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( automaticallyImplyLeading: false, - title: const Text('Card Management', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + title: const Text( + 'Card Management', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: ListView( children: [ CardManagementTile( icon: Symbols.add, label: 'Apply Debit Card', - onTap: () { - - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - CardManagementTile( icon: Symbols.remove_moderator, label: 'Block / Unblock Card', onTap: () { - Navigator.push(context, MaterialPageRoute( - builder: (context) => const BlockCardScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const BlockCardScreen())); }, ), - - const Divider(height: 1,), - + const Divider( + height: 1, + ), CardManagementTile( icon: Symbols.password_2, label: 'Change Card PIN', onTap: () { - Navigator.push(context, MaterialPageRoute( - builder: (context) => const CardPinChangeDetailsScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => + const CardPinChangeDetailsScreen())); }, ), - - const Divider(height: 1,), - + const Divider( + height: 1, + ), ], ), ); @@ -92,4 +103,3 @@ class CardManagementTile extends StatelessWidget { ); } } - diff --git a/lib/features/card/screens/card_pin_change_details_screen.dart b/lib/features/card/screens/card_pin_change_details_screen.dart index 1eb4335..0b8a6a4 100644 --- a/lib/features/card/screens/card_pin_change_details_screen.dart +++ b/lib/features/card/screens/card_pin_change_details_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:intl/intl.dart'; import 'package:kmobile/features/card/screens/card_pin_set_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -7,10 +8,11 @@ class CardPinChangeDetailsScreen extends StatefulWidget { const CardPinChangeDetailsScreen({super.key}); @override - State createState() => _CardPinChangeDetailsScreen(); + State createState() => + _CardPinChangeDetailsScreen(); } -class _CardPinChangeDetailsScreen extends State{ +class _CardPinChangeDetailsScreen extends State { final _formKey = GlobalKey(); final _cardController = TextEditingController(); final _cvvController = TextEditingController(); @@ -43,24 +45,33 @@ class _CardPinChangeDetailsScreen extends State{ Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Card Details', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Card Details', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: Padding( padding: const EdgeInsets.all(10.0), child: Form( @@ -85,8 +96,9 @@ class _CardPinChangeDetailsScreen extends State{ ), keyboardType: TextInputType.number, textInputAction: TextInputAction.next, - validator: (value) => - value != null && value.length == 16 ? null : 'Enter valid card number', + validator: (value) => value != null && value.length == 16 + ? null + : 'Enter valid card number', ), const SizedBox(height: 24), Row( @@ -110,8 +122,9 @@ class _CardPinChangeDetailsScreen extends State{ keyboardType: TextInputType.number, textInputAction: TextInputAction.next, obscureText: true, - validator: (value) => - value != null && value.length == 3 ? null : 'CVV must be 3 digits', + validator: (value) => value != null && value.length == 3 + ? null + : 'CVV must be 3 digits', ), ), const SizedBox(width: 16), @@ -134,8 +147,9 @@ class _CardPinChangeDetailsScreen extends State{ borderSide: BorderSide(color: Colors.black, width: 2), ), ), - validator: (value) => - value != null && value.isNotEmpty ? null : 'Select expiry date', + validator: (value) => value != null && value.isNotEmpty + ? null + : 'Select expiry date', ), ), ], @@ -159,8 +173,9 @@ class _CardPinChangeDetailsScreen extends State{ ), textInputAction: TextInputAction.done, keyboardType: TextInputType.phone, - validator: (value) => - value != null && value.length >= 10 ? null : 'Enter valid phone number', + validator: (value) => value != null && value.length >= 10 + ? null + : 'Enter valid phone number', ), const SizedBox(height: 45), Align( @@ -185,5 +200,4 @@ class _CardPinChangeDetailsScreen extends State{ ), ); } - -} \ No newline at end of file +} diff --git a/lib/features/card/screens/card_pin_set_screen.dart b/lib/features/card/screens/card_pin_set_screen.dart index f31cf5d..80abfd7 100644 --- a/lib/features/card/screens/card_pin_set_screen.dart +++ b/lib/features/card/screens/card_pin_set_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; class CardPinSetScreen extends StatefulWidget { @@ -8,7 +9,7 @@ class CardPinSetScreen extends StatefulWidget { State createState() => _CardPinSetScreen(); } -class _CardPinSetScreen extends State{ +class _CardPinSetScreen extends State { final _formKey = GlobalKey(); final _pinController = TextEditingController(); final _confirmPinController = TextEditingController(); @@ -44,24 +45,33 @@ class _CardPinSetScreen extends State{ Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Card PIN', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Card PIN', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: Padding( padding: const EdgeInsets.all(16.0), child: Form( @@ -145,4 +155,4 @@ class _CardPinSetScreen extends State{ ), ); } -} \ No newline at end of file +} diff --git a/lib/features/cheque/screens/cheque_management_screen.dart b/lib/features/cheque/screens/cheque_management_screen.dart index 3e4467e..082d48a 100644 --- a/lib/features/cheque/screens/cheque_management_screen.dart +++ b/lib/features/cheque/screens/cheque_management_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:kmobile/features/enquiry/screens/enquiry_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -9,95 +10,98 @@ class ChequeManagementScreen extends StatefulWidget { State createState() => _ChequeManagementScreen(); } -class _ChequeManagementScreen extends State{ - +class _ChequeManagementScreen extends State { @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Cheque Management', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Cheque Management', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: ListView( children: [ const SizedBox(height: 15), ChequeManagementTile( icon: Symbols.add, label: 'Request Checkbook', - onTap: () { - - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - ChequeManagementTile( icon: Symbols.data_alert, label: 'Enquiry', onTap: () { - Navigator.push(context, MaterialPageRoute( - builder: (context) => const EnquiryScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const EnquiryScreen())); }, ), - - const Divider(height: 1,), - + const Divider( + height: 1, + ), ChequeManagementTile( icon: Symbols.approval_delegation, label: 'Cheque Deposit', - onTap: () { - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - ChequeManagementTile( icon: Symbols.front_hand, label: 'Stop Cheque', - onTap: () { - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - ChequeManagementTile( icon: Symbols.cancel_presentation, label: 'Revoke Stop', - onTap: () { - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - ChequeManagementTile( icon: Symbols.payments, label: 'Positive Pay', - onTap: () { - }, + onTap: () {}, + ), + const Divider( + height: 1, ), - - const Divider(height: 1,), - ], ), ); } - } class ChequeManagementTile extends StatelessWidget { @@ -121,4 +125,4 @@ class ChequeManagementTile extends StatelessWidget { onTap: onTap, ); } -} \ No newline at end of file +} diff --git a/lib/features/enquiry/screens/enquiry_screen.dart b/lib/features/enquiry/screens/enquiry_screen.dart index 4c0f8ef..d996e59 100644 --- a/lib/features/enquiry/screens/enquiry_screen.dart +++ b/lib/features/enquiry/screens/enquiry_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; import 'package:url_launcher/url_launcher.dart'; @@ -9,7 +10,7 @@ class EnquiryScreen extends StatefulWidget { State createState() => _EnquiryScreen(); } -class _EnquiryScreen extends State{ +class _EnquiryScreen extends State { Future _launchEmail() async { final Uri emailUri = Uri( scheme: 'mailto', @@ -35,24 +36,33 @@ class _EnquiryScreen extends State{ Widget build(BuildContext context) { return Scaffold( appBar: AppBar( - leading: IconButton(icon: const Icon(Symbols.arrow_back_ios_new), + leading: IconButton( + icon: const Icon(Symbols.arrow_back_ios_new), onPressed: () { Navigator.pop(context); - },), - title: const Text('Enquiry', style: TextStyle(color: Colors.black, - fontWeight: FontWeight.w500),), + }, + ), + title: const Text( + 'Enquiry', + style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), + ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], ), - body: Padding( padding: const EdgeInsets.all(16.0), child: Column( @@ -89,5 +99,4 @@ class _EnquiryScreen extends State{ ), ); } - -} \ No newline at end of file +} diff --git a/lib/features/fund_transfer/screens/fund_transfer_beneficiary_screen.dart b/lib/features/fund_transfer/screens/fund_transfer_beneficiary_screen.dart index ab67f60..6f47f40 100644 --- a/lib/features/fund_transfer/screens/fund_transfer_beneficiary_screen.dart +++ b/lib/features/fund_transfer/screens/fund_transfer_beneficiary_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:kmobile/features/beneficiaries/screens/add_beneficiary_screen.dart'; import 'package:kmobile/features/fund_transfer/screens/fund_transfer_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -7,10 +8,12 @@ class FundTransferBeneficiaryScreen extends StatefulWidget { const FundTransferBeneficiaryScreen({super.key}); @override - State createState() => _FundTransferBeneficiaryScreen(); + State createState() => + _FundTransferBeneficiaryScreen(); } -class _FundTransferBeneficiaryScreen extends State{ +class _FundTransferBeneficiaryScreen + extends State { final List> beneficiaries = [ { 'bank': 'State Bank Of India', @@ -34,24 +37,33 @@ class _FundTransferBeneficiaryScreen extends State const FundTransferScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const FundTransferScreen())); }, ); }, @@ -82,8 +98,10 @@ class _FundTransferBeneficiaryScreen extends State const AddBeneficiaryScreen())); + Navigator.push( + context, + MaterialPageRoute( + builder: (context) => const AddBeneficiaryScreen())); }, backgroundColor: Colors.grey[300], foregroundColor: Colors.blue[900], @@ -93,4 +111,4 @@ class _FundTransferBeneficiaryScreen extends State { style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), - // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], diff --git a/lib/features/quick_pay/screens/quick_pay_screen.dart b/lib/features/quick_pay/screens/quick_pay_screen.dart index a1a0bf6..f1764dc 100644 --- a/lib/features/quick_pay/screens/quick_pay_screen.dart +++ b/lib/features/quick_pay/screens/quick_pay_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:kmobile/features/quick_pay/screens/quick_pay_outside_bank_screen.dart'; import 'package:kmobile/features/quick_pay/screens/quick_pay_within_bank_screen.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -26,13 +27,18 @@ class _QuickPayScreen extends State { style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), - // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], diff --git a/lib/features/quick_pay/screens/quick_pay_within_bank_screen.dart b/lib/features/quick_pay/screens/quick_pay_within_bank_screen.dart index e273746..12fea8e 100644 --- a/lib/features/quick_pay/screens/quick_pay_within_bank_screen.dart +++ b/lib/features/quick_pay/screens/quick_pay_within_bank_screen.dart @@ -1,4 +1,5 @@ import 'package:flutter/material.dart'; +import 'package:flutter_svg/svg.dart'; import 'package:flutter_swipe_button/flutter_swipe_button.dart'; import 'package:material_symbols_icons/material_symbols_icons.dart'; @@ -15,7 +16,8 @@ class _QuickPayWithinBankScreen extends State { final _formKey = GlobalKey(); final TextEditingController accountNumberController = TextEditingController(); - final TextEditingController confirmAccountNumberController = TextEditingController(); + final TextEditingController confirmAccountNumberController = + TextEditingController(); final TextEditingController nameController = TextEditingController(); final TextEditingController amountController = TextEditingController(); @@ -34,13 +36,18 @@ class _QuickPayWithinBankScreen extends State { style: TextStyle(color: Colors.black, fontWeight: FontWeight.w500), ), centerTitle: false, - actions: const [ + actions: [ Padding( - padding: EdgeInsets.only(right: 10.0), + padding: const EdgeInsets.only(right: 10.0), child: CircleAvatar( - backgroundImage: AssetImage('assets/images/avatar.jpg'), - // Replace with your image + backgroundColor: Colors.grey[200], radius: 20, + child: SvgPicture.asset( + 'assets/images/avatar_male.svg', + width: 40, + height: 40, + fit: BoxFit.cover, + ), ), ), ], @@ -210,13 +217,13 @@ class _QuickPayWithinBankScreen extends State { if (_formKey.currentState!.validate()) { // Perform payment logic ScaffoldMessenger.of(context).showSnackBar( - const SnackBar( - content: Text('Processing Payment...')), + const SnackBar(content: Text('Processing Payment...')), ); Navigator.push( context, MaterialPageRoute( - builder: (context) => const TransactionPinScreen())); + builder: (context) => + const TransactionPinScreen())); } }, ),