Past swaps: show the amount of BTCs that we are waiting for.

This commit is contained in:
infinite-persistence 2021-04-04 15:32:07 +08:00 committed by Sean Yesmunt
parent b2630f6f21
commit d63cb0dc2d
3 changed files with 9 additions and 5 deletions

View file

@ -1741,7 +1741,7 @@
"Processing...": "Processing...",
"View Past Swaps": "View Past Swaps",
"Remove address": "Remove address",
"Waiting for BTC": "Waiting for BTC",
"Waiting %sendAmount% BTC": "Waiting %sendAmount% BTC",
"Waiting to receive your bitcoin.": "Waiting to receive your bitcoin.",
"Sending LBC": "Sending LBC",
"Bitcoin received. Sending your LBC.": "Bitcoin received. Sending your LBC.",

View file

@ -261,8 +261,8 @@ function WalletSwap(props: Props) {
});
}
function getStatusStr(btcAddress) {
const status = statusMap[btcAddress];
function getStatusStr(coinSwap: CoinSwapInfo) {
const status = statusMap[coinSwap.sendAddress];
if (!status) {
return '---';
}
@ -270,7 +270,7 @@ function WalletSwap(props: Props) {
let msg;
switch (status.Status) {
case BTC_API_STATUS_PENDING:
msg = __('Waiting for BTC');
msg = __('Waiting %sendAmount% BTC', { sendAmount: coinSwap.sendAmount });
break;
case BTC_API_STATUS_PROCESSING:
msg = __('Sending LBC');
@ -442,7 +442,7 @@ function WalletSwap(props: Props) {
}}
/>
</td>
<td>{isRefreshingStatus ? '...' : getStatusStr(x.sendAddress)}</td>
<td>{isRefreshingStatus ? '...' : getStatusStr(x)}</td>
<td>
<Button
button="link"

View file

@ -158,6 +158,10 @@ th {
tr {
white-space: nowrap;
}
td:nth-of-type(2) {
font-size: var(--font-small);
}
}
.table--rewards {