diff --git a/lib/src/screens/receive/widgets/currency_input_field.dart b/lib/src/screens/receive/widgets/currency_input_field.dart index 83c5f9836..048b1d473 100644 --- a/lib/src/screens/receive/widgets/currency_input_field.dart +++ b/lib/src/screens/receive/widgets/currency_input_field.dart @@ -200,8 +200,18 @@ class CurrencyAmountTextField extends StatelessWidget { color: Theme.of(context).colorScheme.onSurfaceVariant, ), validator: isAmountEditable ? currencyValueValidator : null, - onChanged: (value) => amountController.text = - value.replaceAll(',', '.').withMaxDecimals(selectedCurrencyDecimals), + onChanged: (value) { + final sanitized = + value.replaceAll(',', '.').withMaxDecimals(selectedCurrencyDecimals); + if (sanitized != amountController.text) { + // Update text while preserving a sane cursor position to avoid auto-selection + amountController.value = amountController.value.copyWith( + text: sanitized, + selection: TextSelection.collapsed(offset: sanitized.length), + composing: TextRange.empty, + ); + } + }, ), ), ),