mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
unify TokenList styles
This commit is contained in:
parent
8b3f16fac9
commit
08e2a3f22d
@ -3,7 +3,7 @@
|
||||
margin-right: -2rem;
|
||||
padding-left: var(--spacer);
|
||||
padding-right: var(--spacer);
|
||||
margin-top: calc(var(--spacer) / 2);
|
||||
margin-top: calc(var(--spacer) / 4);
|
||||
padding-top: calc(var(--spacer) / 1.5);
|
||||
border-top: 1px solid var(--brand-grey-lighter);
|
||||
text-align: center;
|
||||
|
@ -1,5 +1,13 @@
|
||||
.tokeninfo {
|
||||
padding-top: calc(var(--spacer) / 1.5);
|
||||
.tokenlist {
|
||||
margin-left: -2rem;
|
||||
margin-right: -2rem;
|
||||
padding: calc(var(--spacer) / 1.5) var(--spacer) calc(var(--spacer) / 2)
|
||||
var(--spacer);
|
||||
border-top: 1px solid var(--brand-grey-lighter);
|
||||
}
|
||||
|
||||
.tokenlist.highlight {
|
||||
background: var(--brand-grey-dimmed);
|
||||
}
|
||||
|
||||
.tokens {
|
||||
@ -22,15 +30,6 @@
|
||||
color: var(--color-secondary);
|
||||
}
|
||||
|
||||
.highlight {
|
||||
background: var(--brand-grey-dimmed);
|
||||
padding: calc(var(--spacer) / 1.5) var(--spacer) calc(var(--spacer) / 2)
|
||||
var(--spacer);
|
||||
border-bottom: 1px solid var(--brand-grey-lighter);
|
||||
margin-left: -2rem;
|
||||
margin-right: -2rem;
|
||||
}
|
||||
|
||||
.totalLiquidity {
|
||||
composes: token from './Token.module.css';
|
||||
margin-bottom: 0;
|
||||
|
@ -23,7 +23,7 @@ export default function TokenList({
|
||||
highlight?: boolean
|
||||
}): ReactElement {
|
||||
return (
|
||||
<div className={`${styles.tokeninfo} ${highlight ? styles.highlight : ''}`}>
|
||||
<div className={`${styles.tokenlist} ${highlight ? styles.highlight : ''}`}>
|
||||
<h3 className={styles.title}>{title}</h3>
|
||||
<div className={styles.tokens}>
|
||||
<Token symbol="OCEAN" balance={ocean} />
|
||||
|
@ -1,7 +1,6 @@
|
||||
.dataToken {
|
||||
padding-bottom: calc(var(--spacer) / 1.5);
|
||||
font-size: var(--font-size-large);
|
||||
border-bottom: 1px solid var(--brand-grey-lighter);
|
||||
margin-left: -2rem;
|
||||
margin-right: -2rem;
|
||||
padding-left: calc(var(--spacer) / 1.5);
|
||||
|
@ -8,7 +8,6 @@ import Button from '../../../atoms/Button'
|
||||
import Add from './Add'
|
||||
import Remove from './Remove'
|
||||
import Tooltip from '../../../atoms/Tooltip'
|
||||
import Conversion from '../../../atoms/Price/Conversion'
|
||||
import EtherscanLink from '../../../atoms/EtherscanLink'
|
||||
import Token from './Token'
|
||||
import TokenList from './TokenList'
|
||||
@ -87,7 +86,7 @@ export default function Pool({ ddo }: { ddo: DDO }): ReactElement {
|
||||
|
||||
const totalLiquidityInOcean = price?.ocean + price?.datatoken * price?.value
|
||||
setTotalLiquidityInOcean(totalLiquidityInOcean)
|
||||
}, [userLiquidity, price])
|
||||
}, [userLiquidity, price, poolTokens, totalPoolTokens])
|
||||
|
||||
useEffect(() => {
|
||||
if (!ocean || !accountId || !price) return
|
||||
@ -171,7 +170,7 @@ export default function Pool({ ddo }: { ddo: DDO }): ReactElement {
|
||||
}
|
||||
}
|
||||
init()
|
||||
}, [ocean, accountId, price, ddo.dataToken, refreshPool])
|
||||
}, [ocean, accountId, price, ddo.dataToken, refreshPool, ddo.publicKey])
|
||||
|
||||
const refreshInfo = async () => {
|
||||
setRefreshPool(!refreshPool)
|
||||
|
Loading…
Reference in New Issue
Block a user