feat(connect-wallet): justify to end

This commit is contained in:
RadoslavDimchev 2024-02-23 08:32:29 +02:00 committed by Emil Ivanichkov
parent 2cfaf4cdd7
commit 7f401b8690
1 changed files with 10 additions and 2 deletions

View File

@ -6,7 +6,11 @@ import { useEffect } from 'react'
import { setIsWalletConnected } from '../../../redux/ValidatorOnboarding/Deposit/slice' import { setIsWalletConnected } from '../../../redux/ValidatorOnboarding/Deposit/slice'
const ConnectWallet = () => { type ConnectWalletProps = {
isConnectBtnJustifyEnd?: boolean
}
const ConnectWallet = ({ isConnectBtnJustifyEnd }: ConnectWalletProps) => {
const [{ wallet, connecting }, connect, disconnect] = useConnectWallet() const [{ wallet, connecting }, connect, disconnect] = useConnectWallet()
const updateAccountCenter = useAccountCenter() const updateAccountCenter = useAccountCenter()
const dispatch = useDispatch() const dispatch = useDispatch()
@ -29,7 +33,11 @@ const ConnectWallet = () => {
} }
return ( return (
<XStack space={'$2'} alignItems={'center'}> <XStack
space={'$2'}
alignItems={'center'}
justifyContent={isConnectBtnJustifyEnd ? 'space-between' : 'flex-start'}
>
<Avatar <Avatar
type="icon" type="icon"
size={32} size={32}