diff --git a/pages/Transfer.qml b/pages/Transfer.qml index c398eaf8..657a033c 100644 --- a/pages/Transfer.qml +++ b/pages/Transfer.qml @@ -162,7 +162,7 @@ Rectangle { inlineButton.onClicked: amountLine.text = "(all)" validator: RegExpValidator { - regExp: /(\d{1,8})([.]\d{1,12})?$/ + regExp: /(.|)(\d{1,8})([.]\d{1,12})?$/ } } } @@ -337,7 +337,12 @@ Rectangle { if(parseFloat(amountLine.text) > parseFloat(unlockedBalanceText)){ return false; } - + + // The amount does not start with a period (example: `.4`) + if(amountLine.text.startsWith('.')){ + return false; + } + return true; } onClicked: {