mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
use logout
This commit is contained in:
parent
9680468943
commit
3e0473e8f7
@ -6,7 +6,7 @@ import Web3Feedback from './Feedback'
|
|||||||
import { formatNumber } from '../../../utils'
|
import { formatNumber } from '../../../utils'
|
||||||
|
|
||||||
export default function Details({ attrs }: { attrs: any }): ReactElement {
|
export default function Details({ attrs }: { attrs: any }): ReactElement {
|
||||||
const { balance, web3Modal } = useOcean()
|
const { balance, web3Modal, logout } = useOcean()
|
||||||
const ethBalanceText = 'hello test'
|
const ethBalanceText = 'hello test'
|
||||||
// || formatNumber(Number(balance.eth))
|
// || formatNumber(Number(balance.eth))
|
||||||
const oceanBalanceText = 'hello test'
|
const oceanBalanceText = 'hello test'
|
||||||
@ -25,7 +25,10 @@ export default function Details({ attrs }: { attrs: any }): ReactElement {
|
|||||||
<Button
|
<Button
|
||||||
style="text"
|
style="text"
|
||||||
size="small"
|
size="small"
|
||||||
onClick={() => web3Modal.toggleModal()}
|
onClick={async () => {
|
||||||
|
logout()
|
||||||
|
await web3Modal.toggleModal()
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
Switch Wallet
|
Switch Wallet
|
||||||
</Button>
|
</Button>
|
||||||
|
Loading…
Reference in New Issue
Block a user