yearn / seafood

Seafood
https://seafood.yearn.watch
13 stars 21 forks source link

Bug: Fix tiny token amounts #169

Open murderteeth opened 1 year ago

murderteeth commented 1 year ago

When showing token amounts Seafood currently rounds out tokens that are very small against usd. For example Seafood shows 0.00 assets for this USDR vault when the correct value us 0.00000806.

https://seafood.yearn.watch/vault/0x531fDb1C8429F404116932226D487db94471C4b7 image

Update Seafood to work like this instead: image

Tasks

heysourin commented 1 year ago

Hi, I see here are two different tasks added inside one single issue.

  1. Fix the decimals
  2. Fix update and hover Am I right?
murderteeth commented 1 year ago

Hi @heysourin! Yes, you are correct

udhaykumarbala commented 1 year ago

Hi @murderteeth, The formatNumber function already uses "m" to represent million. now the "milli" also has same character. can we change the million to "M"?

murderteeth commented 1 year ago

Good catch @udhaykumarbala. Yes, lets change the logic so that numbers greater than zero all use uppercase and all numbers less than zero use lowercase. And let me know if you'd like me to assign this to you, thank you!

Hari-Bombon commented 1 year ago

@murderteeth Hello! I'm excited to start my journey in open source contribution as a beginner and learn from experienced developers while making meaningful contributions to projects. Tech stack - reactjs , solidity, javascript