Skip to content

Commit 3aa2809

Browse files
committed
fix: the amount display.
1 parent a7794a4 commit 3aa2809

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

src/ui/hooks/useGetBitcoinBalanceList.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ function useGetBtcBalance(address?: string, flag?: boolean) {
7272

7373
useEffect(() => {
7474
fetchBitcoinItem();
75-
}, [flag, address, denomPrice]);
75+
}, [flag, address, denomPrice, btcBalance]);
7676

7777
return {
7878
data,

src/ui/pages/Main/WalletTabScreen/index.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ export default function WalletTabScreen() {
2929

3030
const wallet = useWallet();
3131
const [connected, setConnected] = useState(false);
32+
const [currentTab, setCurrentTab] = useState<CHAINS_ENUM>(CHAINS_ENUM.SIDE);
3233
const dispatch = useAppDispatch();
3334
const accountBalanceByUSD = useGetAccountBalanceByUSD();
3435

@@ -68,8 +69,6 @@ export default function WalletTabScreen() {
6869
run();
6970
}, []);
7071

71-
const [currentTab, setCurrentTab] = useState<CHAINS_ENUM>(CHAINS_ENUM.SIDE);
72-
7372
const [buyBtcModalVisible, setBuyBtcModalVisible] = useState(false);
7473
const [isHoveredMoney, setIsHoveredMoney] = useState(false);
7574
const handleMouseOver = () => {
@@ -120,7 +119,7 @@ export default function WalletTabScreen() {
120119
}}
121120
/>
122121
<Text
123-
text={getTruncate(accountBalanceByUSD.split('.')[0])}
122+
text={getTruncate(accountBalanceByUSD.split('.')[0], 0)}
124123
style={{
125124
fontSize: '38px',
126125
fontWeight: 500,

0 commit comments

Comments
 (0)