From 986a0885fea6bfc1d181464cc5c89caadce2ceae Mon Sep 17 00:00:00 2001 From: Erdem Yerebasmaz Date: Fri, 17 May 2024 01:36:38 +0300 Subject: [PATCH] Limit amount of decimals of BTC in amount field --- lib/widgets/amount_form_field.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/widgets/amount_form_field.dart b/lib/widgets/amount_form_field.dart index 271e90419..044f8584c 100644 --- a/lib/widgets/amount_form_field.dart +++ b/lib/widgets/amount_form_field.dart @@ -73,7 +73,7 @@ class AmountFormField extends TextFormField { enabled: enabled, controller: controller, inputFormatters: accountModel.currency != Currency.SAT - ? [FilteringTextInputFormatter.allow(RegExp(r'\d+\.?\d*'))] + ? [FilteringTextInputFormatter.allow(RegExp(r'\d+\.?\d{0,8}'))] : [SatAmountFormFieldFormatter()], onFieldSubmitted: onFieldSubmitted, onSaved: onSaved,