mirror of
https://github.com/oceanprotocol/market.git
synced 2024-11-16 02:04:54 +01:00
wallet tweaks
This commit is contained in:
parent
cea8c7883a
commit
03204e0965
6
package-lock.json
generated
6
package-lock.json
generated
@ -3741,9 +3741,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@oceanprotocol/react": {
|
"@oceanprotocol/react": {
|
||||||
"version": "0.0.21",
|
"version": "0.0.23",
|
||||||
"resolved": "https://registry.npmjs.org/@oceanprotocol/react/-/react-0.0.21.tgz",
|
"resolved": "https://registry.npmjs.org/@oceanprotocol/react/-/react-0.0.23.tgz",
|
||||||
"integrity": "sha512-y5KSrNqfVUXyrkvh97A0WIhPNtQ8t1oLVVtQi1fE1bSb2H/N5VMxQIfdoBIZO0VltoMq+9emDUoS3a5VH155JA==",
|
"integrity": "sha512-DnCoBtz5Z+3JGChDgLI3n9NhexdNHhO1sQD5mIr6uxEGq5D8E7QDNJAnrLn33MsHWZdATmUNi+KUe81qTVrAyA==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"@oceanprotocol/contracts": "^0.2.3",
|
"@oceanprotocol/contracts": "^0.2.3",
|
||||||
"@oceanprotocol/lib": "^0.1.6",
|
"@oceanprotocol/lib": "^0.1.6",
|
||||||
|
@ -21,7 +21,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@loadable/component": "^5.13.1",
|
"@loadable/component": "^5.13.1",
|
||||||
"@oceanprotocol/art": "^3.0.0",
|
"@oceanprotocol/art": "^3.0.0",
|
||||||
"@oceanprotocol/react": "^0.0.21",
|
"@oceanprotocol/react": "^0.0.23",
|
||||||
"@oceanprotocol/typographies": "^0.1.0",
|
"@oceanprotocol/typographies": "^0.1.0",
|
||||||
"@sindresorhus/slugify": "^1.0.0",
|
"@sindresorhus/slugify": "^1.0.0",
|
||||||
"@tippyjs/react": "^4.1.0",
|
"@tippyjs/react": "^4.1.0",
|
||||||
|
@ -5,6 +5,7 @@ import { useOcean } from '@oceanprotocol/react'
|
|||||||
import Web3Feedback from './Feedback'
|
import Web3Feedback from './Feedback'
|
||||||
import { connectWallet, getNetworkName } from '../../../utils/wallet'
|
import { connectWallet, getNetworkName } from '../../../utils/wallet'
|
||||||
import { getInjectedProviderName } from 'web3modal'
|
import { getInjectedProviderName } from 'web3modal'
|
||||||
|
import Conversion from '../../atoms/Price/Conversion'
|
||||||
|
|
||||||
export default function Details({ attrs }: { attrs: any }): ReactElement {
|
export default function Details({ attrs }: { attrs: any }): ReactElement {
|
||||||
const { balance, connect, logout, chainId } = useOcean()
|
const { balance, connect, logout, chainId } = useOcean()
|
||||||
@ -12,10 +13,10 @@ export default function Details({ attrs }: { attrs: any }): ReactElement {
|
|||||||
return (
|
return (
|
||||||
<div className={styles.details} {...attrs}>
|
<div className={styles.details} {...attrs}>
|
||||||
<ul>
|
<ul>
|
||||||
{balance &&
|
{Object.entries(balance).map(([key, value]) => (
|
||||||
Object.entries(balance).map(([key, value]) => (
|
|
||||||
<li className={styles.balance} key={key}>
|
<li className={styles.balance} key={key}>
|
||||||
<span>{key.toUpperCase()}</span> {value}
|
<span>{key.toUpperCase()}</span> {value}
|
||||||
|
{key === 'ocean' && <Conversion price={value} />}
|
||||||
</li>
|
</li>
|
||||||
))}
|
))}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user