diff --git a/static/app-strings.json b/static/app-strings.json index c9f9eaa9c..40eea5808 100644 --- a/static/app-strings.json +++ b/static/app-strings.json @@ -1786,7 +1786,7 @@ "Remove %address%?": "Remove %address%?", "This process cannot be reversed.": "This process cannot be reversed.", "View transaction": "View transaction", - "Send (USE COPY BUTTON, ENSURE EXACT AMOUNT IS SENT!)": "Send (USE COPY BUTTON, ENSURE EXACT AMOUNT IS SENT!)", + "Use the copy button to ensure the EXACT amount is sent!": "Use the copy button to ensure the EXACT amount is sent!", "Amount copied.": "Amount copied.", "Copy transaction ID": "Copy transaction ID", "Transaction ID copied.": "Transaction ID copied.", diff --git a/ui/component/walletSwap/view.jsx b/ui/component/walletSwap/view.jsx index c0c8f3416..1f49cd6de 100644 --- a/ui/component/walletSwap/view.jsx +++ b/ui/component/walletSwap/view.jsx @@ -301,16 +301,25 @@ function WalletSwap(props: Props) { const btcAmount = response.Charge.data.pricing['bitcoin'].amount; const rate = response.Exchange.rate; - const swap = { + const timeline = response.Charge.data.timeline; + const lastTimeline = timeline[timeline.length - 1]; + + const newSwap = { chargeCode: response.Exchange.charge_code, coins: Object.keys(response.Charge.data.addresses), sendAddresses: response.Charge.data.addresses, sendAmounts: response.Charge.data.pricing, lbcAmount: (btcAmount * BTC_SATOSHIS) / rate, + status: { + status: lastTimeline.status, + receiptCurrency: lastTimeline.payment.value.currency, + receiptTxid: lastTimeline.payment.transaction_id, + lbcTxid: response.Exchange.lbc_txid || '', + }, }; - setSwap({ ...swap }); - addCoinSwap({ ...swap }); + setSwap({ ...newSwap }); + addCoinSwap({ ...newSwap }); }) .catch((err) => { setNag({ msg: err === INTERNAL_APIS_DOWN ? NAG_SWAP_CALL_FAILED : err.message, type: 'error' }); @@ -532,7 +541,7 @@ function WalletSwap(props: Props) { {getGap()} )} -
{__('Send (USE COPY BUTTON, ENSURE EXACT AMOUNT IS SENT!)')}
+
{__('Send')}
+
{__('Use the copy button to ensure the EXACT amount is sent!')}
{getGap()}
{__('To')}