mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
UI improvement for low number of pool shares (#1476)
* UI iprovement for low number of pool shares * Fixing comparison logic Co-authored-by: Matthias Kretschmann <m@kretschmann.io> Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
This commit is contained in:
parent
fc2aa5bf0e
commit
ec7dc4fccd
@ -53,9 +53,10 @@ export default function Migration(): ReactElement {
|
||||
const content = data.content.edges[0].node.childContentJson
|
||||
|
||||
function getNoLockedSharesMessage() {
|
||||
const poolSharesRounded = isNaN(Number(poolShares))
|
||||
? 0
|
||||
: Number(poolShares).toFixed(3)
|
||||
const poolSharesRounded =
|
||||
Number(poolShares) <= 0.001
|
||||
? 'less than 0.001'
|
||||
: Number(poolShares).toFixed(3)
|
||||
return `\n\nYou currently have ${poolSharesRounded} pool shares\n\nYou have locked 0 shares`
|
||||
}
|
||||
function getLockedSharesMessage(lockedShares: number) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user