This commit is contained in:
2026-03-29 15:30:09 +03:00
parent 567a85486b
commit eca3d1f294
3 changed files with 5 additions and 21 deletions
+2 -1
View File
@@ -993,7 +993,8 @@ class _ToAccountDropdownOverlay extends ConsumerWidget {
return Column(
mainAxisSize: MainAxisSize.min,
children: filteredAccounts.map((account) {
final isSelected = account.id == toAccountId;
final isSelected =
toAccountId != null && account.id == toAccountId;
return InkWell(
borderRadius: BorderRadius.circular(12),
onTap: () {
@@ -132,7 +132,6 @@ class AccountDropdownOverlay extends ConsumerWidget {
@override
Widget build(BuildContext context, WidgetRef ref) {
final activeAccount = ref.watch(activeAccountProvider);
final accountsAsync = ref.watch(accountsProvider);
// Calculate position from trigger key
@@ -190,28 +189,12 @@ class AccountDropdownOverlay extends ConsumerWidget {
final txAccountId = ref
.read(addTransactionProvider(initial))
.selectedAccountId;
final Account displayAccount;
if (txAccountId != null) {
displayAccount = accounts.firstWhere(
(a) => a.id == txAccountId,
orElse: () => accounts.firstWhere(
(a) => a.isMain,
orElse: () => accounts.first,
),
);
} else {
displayAccount =
activeAccount ??
accounts.firstWhere(
(a) => a.isMain,
orElse: () => accounts.first,
);
}
return Column(
mainAxisSize: MainAxisSize.min,
children: accounts.map((account) {
final isSelected = account.id == displayAccount.id;
final isSelected =
txAccountId != null && account.id == txAccountId;
return InkWell(
borderRadius: BorderRadius.circular(12),
onTap: () {
@@ -23,7 +23,7 @@ class SubmitButton extends StatelessWidget {
@override
Widget build(BuildContext context) {
final typeColor = type == TransactionType.transfer
? AppColors.accent
? Colors.blueAccent
: type == TransactionType.income
? const Color(0xFF4CAF8C)
: const Color(0xFFE05C6B);