near / near-wallet

Web wallet for NEAR Protocol which stores keys in browser's localStorage
https://wallet.near.org
MIT License
220 stars 176 forks source link

Display of "Rewards earned" #2315

Open RubyJiao opened 2 years ago

RubyJiao commented 2 years ago

Problem After withdrawing all staked near tokens, "Rewards earned" becomes 0. But after re-staking (any amount of tokens), it becomes the value before withdrawing (Actually they are still in the account balance, just displays like that). After a while, "Rewards earned" shows the sum of the previous rewards and the number of rewards this time.

Expected Behavior After re-staking, "Rewards earned" should be displayed from zero. users can know how much their "Rewards earned" is every time.

Steps to reproduce

  1. "Rewards earned" is 25.30868 NEAR
  2. Withdraw all staked near tokens
  3. "Rewards earned" becomes 0 NEAR
  4. Stake some tokens
  5. "Rewards earned" becomes 25.30868 NEAR 1639723592(1)
stefanopepe commented 2 years ago

@MaximusHaximus I'll let you triage this one and assign it to the best person who can take care of it. Given the work that we plan to do with the staking pages (that UI is 15/16 months old already) I'll keep the priority low