fix(SwapModal): Max slippage value remains as set even the custom field is erased

- if the slippage value is invalid, display a "N/A" text in the footer
instead of a partial value

Fixes #16395
This commit is contained in:
Lukáš Tinkl 2024-09-25 12:40:25 +02:00 committed by Lukáš Tinkl
parent 6f80461371
commit fed6f79a66
1 changed files with 2 additions and 1 deletions

View File

@ -355,7 +355,8 @@ StatusDialog {
RowLayout {
StatusBaseText {
objectName: "maxSlippageValue"
text: "%1%".arg(LocaleUtils.numberToLocaleString(root.swapInputParamsForm.selectedSlippage))
text: editSlippagePanel.valid ? "%1%".arg(LocaleUtils.numberToLocaleString(root.swapInputParamsForm.selectedSlippage))
: qsTr("N/A")
color: Theme.palette.directColor4
font.weight: Font.Medium
}