From fed6f79a66cf9b5d51aa9051f02418a2a1dcc8ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Tinkl?= Date: Wed, 25 Sep 2024 12:40:25 +0200 Subject: [PATCH] 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 --- ui/app/AppLayouts/Wallet/popups/swap/SwapModal.qml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui/app/AppLayouts/Wallet/popups/swap/SwapModal.qml b/ui/app/AppLayouts/Wallet/popups/swap/SwapModal.qml index 29bc1e14ad..9d46100aa1 100644 --- a/ui/app/AppLayouts/Wallet/popups/swap/SwapModal.qml +++ b/ui/app/AppLayouts/Wallet/popups/swap/SwapModal.qml @@ -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 }