formatted the whole codebase

This commit is contained in:
asif
2025-08-18 03:20:05 +05:30
parent e2a809d363
commit e6ea764785
58 changed files with 470 additions and 373 deletions

View File

@@ -142,7 +142,8 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
if (!_isBeneficiaryValidated) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text(AppLocalizations.of(context).plsValidateBeneficiary)),
content:
Text(AppLocalizations.of(context).plsValidateBeneficiary)),
);
return;
}
@@ -189,8 +190,8 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
Navigator.of(pinScreenContext).pushReplacement(
MaterialPageRoute(
builder: (_) =>
PaymentAnimationScreen(paymentResponse: completer.future),
builder: (_) => PaymentAnimationScreen(
paymentResponse: completer.future),
),
);
@@ -229,8 +230,8 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
Navigator.of(pinScreenContext).pushReplacement(
MaterialPageRoute(
builder: (_) =>
PaymentAnimationScreen(paymentResponse: completer.future),
builder: (_) => PaymentAnimationScreen(
paymentResponse: completer.future),
),
);
@@ -273,7 +274,8 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
),
title: Text(
AppLocalizations.of(context).quickPayOutsideBank,
style: const TextStyle(color: Colors.black, fontWeight: FontWeight.w500),
style:
const TextStyle(color: Colors.black, fontWeight: FontWeight.w500),
),
centerTitle: false,
actions: [
@@ -385,9 +387,9 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
Expanded(
child: TextFormField(
maxLength: 11,
inputFormatters: [
LengthLimitingTextInputFormatter(11),
],
inputFormatters: [
LengthLimitingTextInputFormatter(11),
],
decoration: InputDecoration(
labelText: AppLocalizations.of(context).ifscCode,
border: const OutlineInputBorder(),
@@ -446,16 +448,14 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
borderSide: BorderSide(color: Colors.black, width: 2),
),
),
items:
[
AppLocalizations.of(context).savings,
AppLocalizations.of(context).current,
]
.map(
(e) =>
DropdownMenuItem(value: e, child: Text(e)),
)
.toList(),
items: [
AppLocalizations.of(context).savings,
AppLocalizations.of(context).current,
]
.map(
(e) => DropdownMenuItem(value: e, child: Text(e)),
)
.toList(),
onChanged: (value) => setState(() {
accountType = value!;
}),
@@ -463,7 +463,6 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
),
],
),
const SizedBox(height: 25),
TextFormField(
controller: bankNameController,
@@ -516,14 +515,14 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
onPressed: _isValidating
? null
: () {
if (confirmAccountNumberController
.text ==
if (confirmAccountNumberController.text ==
accountNumberController.text) {
_validateBeneficiary();
} else {
setState(() {
_validationError =
AppLocalizations.of(context).accountMismatch;
AppLocalizations.of(context)
.accountMismatch;
});
}
},
@@ -531,10 +530,10 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
? const SizedBox(
width: 20,
height: 20,
child: CircularProgressIndicator(
strokeWidth: 2),
child: CircularProgressIndicator(strokeWidth: 2),
)
: Text(AppLocalizations.of(context).validateBeneficiary),
: Text(
AppLocalizations.of(context).validateBeneficiary),
),
),
),
@@ -559,8 +558,7 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
borderSide: BorderSide(color: Colors.black),
),
focusedBorder: const OutlineInputBorder(
borderSide:
BorderSide(color: Colors.black, width: 2),
borderSide: BorderSide(color: Colors.black, width: 2),
),
),
validator: (value) {
@@ -645,15 +643,18 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
Align(
alignment: Alignment.center,
child: SwipeButton.expand(
thumb: Icon(Icons.arrow_forward, color: Theme.of(context).dialogBackgroundColor),
thumb: Icon(Icons.arrow_forward,
color: Theme.of(context).dialogBackgroundColor),
activeThumbColor: Theme.of(context).primaryColor,
activeTrackColor: Theme.of(context).colorScheme.secondary.withAlpha(100),
activeTrackColor:
Theme.of(context).colorScheme.secondary.withAlpha(100),
borderRadius: BorderRadius.circular(30),
height: 56,
onSwipe: _onProceedToPay,
child: Text(
AppLocalizations.of(context).swipeToPay,
style: const TextStyle(fontSize: 16, fontWeight: FontWeight.bold),
style: const TextStyle(
fontSize: 16, fontWeight: FontWeight.bold),
),
),
),
@@ -679,10 +680,14 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
margin: const EdgeInsets.symmetric(horizontal: 4),
padding: const EdgeInsets.symmetric(vertical: 5),
decoration: BoxDecoration(
color: isSelected ? Theme.of(context).primaryColor : Theme.of(context).scaffoldBackgroundColor,
color: isSelected
? Theme.of(context).primaryColor
: Theme.of(context).scaffoldBackgroundColor,
borderRadius: BorderRadius.circular(5),
border: Border.all(
color: isSelected ? Theme.of(context).primaryColor : Theme.of(context).scaffoldBackgroundColor,
color: isSelected
? Theme.of(context).primaryColor
: Theme.of(context).scaffoldBackgroundColor,
width: isSelected ? 0 : 1.2,
),
),
@@ -698,4 +703,4 @@ class _QuickPayOutsideBankScreen extends State<QuickPayOutsideBankScreen> {
),
);
}
}
}

View File

@@ -212,7 +212,8 @@ class _QuickPayWithinBankScreen extends State<QuickPayWithinBankScreen> {
} else {
setState(() {
_validationError =
AppLocalizations.of(context).accountMismatch;
AppLocalizations.of(context)
.accountMismatch;
});
}
},
@@ -222,7 +223,8 @@ class _QuickPayWithinBankScreen extends State<QuickPayWithinBankScreen> {
height: 20,
child: CircularProgressIndicator(strokeWidth: 2),
)
: Text(AppLocalizations.of(context).validateBeneficiary),
: Text(
AppLocalizations.of(context).validateBeneficiary),
),
),
),
@@ -322,7 +324,8 @@ class _QuickPayWithinBankScreen extends State<QuickPayWithinBankScreen> {
Align(
alignment: Alignment.center,
child: SwipeButton.expand(
thumb: Icon(Icons.arrow_forward, color: Theme.of(context).dialogBackgroundColor),
thumb: Icon(Icons.arrow_forward,
color: Theme.of(context).dialogBackgroundColor),
activeThumbColor: Theme.of(context).primaryColor,
activeTrackColor: Theme.of(
context,
@@ -337,8 +340,8 @@ class _QuickPayWithinBankScreen extends State<QuickPayWithinBankScreen> {
if (_formKey.currentState!.validate()) {
if (!_isBeneficiaryValidated) {
setState(() {
_validationError =
AppLocalizations.of(context).validateBeneficiaryproceeding;
_validationError = AppLocalizations.of(context)
.validateBeneficiaryproceeding;
});
return;
}