From c0e4f59f498089773508616f0093e9d073b64d9e Mon Sep 17 00:00:00 2001 From: Anthony Date: Thu, 29 Jul 2021 13:48:33 +0200 Subject: [PATCH] about to add a third tab --- ui/component/walletFiatTransactions/view.jsx | 10 +++++++++- ui/page/wallet/view.jsx | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/ui/component/walletFiatTransactions/view.jsx b/ui/component/walletFiatTransactions/view.jsx index ef1baf4aa..bd7447b69 100644 --- a/ui/component/walletFiatTransactions/view.jsx +++ b/ui/component/walletFiatTransactions/view.jsx @@ -54,7 +54,13 @@ const WalletBalance = (props: Props) => { utxoCounts, } = props; - const accountTransactions = props.transactions; + // receive transactions from parent component + let accountTransactions = props.transactions; + + // reverse so most recent payments come first + if(accountTransactions){ + accountTransactions = accountTransactions.reverse(); + } const [detailsExpanded, setDetailsExpanded] = React.useState(false); const [accountStatusResponse, setAccountStatusResponse] = React.useState(); @@ -86,6 +92,8 @@ const WalletBalance = (props: Props) => { } React.useEffect(() => { + + (async function(){ const response = await getAccountStatus(); diff --git a/ui/page/wallet/view.jsx b/ui/page/wallet/view.jsx index 8a470b8ea..6ab10482b 100644 --- a/ui/page/wallet/view.jsx +++ b/ui/page/wallet/view.jsx @@ -108,7 +108,7 @@ const WalletPage = (props: Props) => { document.getElementsByClassName('lbc-tab-switcher')[0].style.textDecoration = 'underline'; document.getElementsByClassName('fiat-tab-switcher')[0].style.textDecoration = 'none'; }} - >LBC Transactions + >LBC Wallet

{ @@ -118,7 +118,7 @@ const WalletPage = (props: Props) => { document.getElementsByClassName('lbc-tab-switcher')[0].style.textDecoration = 'none'; document.getElementsByClassName('fiat-tab-switcher')[0].style.textDecoration = 'underline'; }} - >USD Transactions

+ >Account History
{/* if the transactions are loading */} { loading && (