1
0
mirror of https://github.com/oceanprotocol/commons.git synced 2023-03-15 18:03:00 +01:00

show message to non-Web3 users

This commit is contained in:
Matthias Kretschmann 2019-04-05 15:45:44 +02:00
parent 1e1dac4f8f
commit ec91010604
Signed by: m
GPG Key ID: 606EEEF3C479A91F

View File

@ -7,7 +7,7 @@ export default class Popover extends PureComponent<{
style: React.CSSProperties
}> {
public render() {
const { account, balance, network } = this.context
const { account, balance, network, isWeb3 } = this.context
return (
<div
className={styles.popover}
@ -31,15 +31,22 @@ export default class Popover extends PureComponent<{
</div>
)}
<div className={styles.popoverInfoline}>
{account ? (
<span className={styles.address} title={account}>
{account}
</span>
) : (
<em>No account selected</em>
)}
</div>
{!isWeb3 ? (
<div className={styles.popoverInfoline}>
No Web3 detected. Use a browser with MetaMask installed
to publish assets.
</div>
) : (
<div className={styles.popoverInfoline}>
{account ? (
<span className={styles.address} title={account}>
{account}
</span>
) : (
<em>No account selected</em>
)}
</div>
)}
<div className={styles.popoverInfoline}>
{network && network}