mirror of
https://github.com/oceanprotocol/commons.git
synced 2023-03-15 18:03:00 +01:00
allow adding styles to account status
This commit is contained in:
parent
3a75a00668
commit
855cdc00af
@ -1,15 +1,19 @@
|
|||||||
import React, { PureComponent } from 'react'
|
import React, { PureComponent } from 'react'
|
||||||
// import Blockies from 'react-blockies'
|
import cx from 'classnames'
|
||||||
import Button from '../atoms/Button'
|
// import Button from '../atoms/Button'
|
||||||
import { User } from '../../context/User'
|
import { User } from '../../context/User'
|
||||||
import styles from './AccountStatus.module.scss'
|
import styles from './AccountStatus.module.scss'
|
||||||
|
|
||||||
|
interface AccountStatusProps {
|
||||||
|
className?: string
|
||||||
|
}
|
||||||
|
|
||||||
interface AccountStatusState {
|
interface AccountStatusState {
|
||||||
popoverOpen: boolean
|
popoverOpen: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
export default class AccountStatus extends PureComponent<
|
export default class AccountStatus extends PureComponent<
|
||||||
{},
|
AccountStatusProps,
|
||||||
AccountStatusState
|
AccountStatusState
|
||||||
> {
|
> {
|
||||||
public state = {
|
public state = {
|
||||||
@ -25,7 +29,7 @@ export default class AccountStatus extends PureComponent<
|
|||||||
public render() {
|
public render() {
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
className={styles.status}
|
className={cx(styles.status, this.props.className)}
|
||||||
onMouseEnter={() => this.togglePopover()}
|
onMouseEnter={() => this.togglePopover()}
|
||||||
onMouseLeave={() => this.togglePopover()}
|
onMouseLeave={() => this.togglePopover()}
|
||||||
onTouchStart={() => this.togglePopover()}
|
onTouchStart={() => this.togglePopover()}
|
||||||
@ -68,7 +72,7 @@ const AccountPopover = () => (
|
|||||||
<div className={styles.popoverInfoline}>
|
<div className={styles.popoverInfoline}>
|
||||||
Network: <strong>{''}</strong>
|
Network: <strong>{''}</strong>
|
||||||
</div>
|
</div>
|
||||||
<div className={styles.popoverInfoline}>
|
{/* <div className={styles.popoverInfoline}>
|
||||||
<User.Consumer>
|
<User.Consumer>
|
||||||
{states => (
|
{states => (
|
||||||
<Button link onClick={states.requestFromFaucet}>
|
<Button link onClick={states.requestFromFaucet}>
|
||||||
@ -76,6 +80,6 @@ const AccountPopover = () => (
|
|||||||
</Button>
|
</Button>
|
||||||
)}
|
)}
|
||||||
</User.Consumer>
|
</User.Consumer>
|
||||||
</div>
|
</div> */}
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user