Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DDW-605] Display rewards address #2475

Merged
merged 31 commits into from Mar 31, 2021

Conversation

nikolaglumac
Copy link
Contributor

@nikolaglumac nikolaglumac commented Mar 24, 2021

This PR adds a display of wallet rewards address.

Todos

  • Add CHANGELOG
  • Add screenshots
  • Add translations ("Rewards address" column)
  • Update table headers on "Rewards" screen ("Reward (ADA)" should be updated to match the design: https://zpl.io/VOBk15Y)
  • Implement table sorting based on stake key value (sorting icon is added but the functionality is missing)
  • Implement rewards address copy feature (copy icon and copy action are missing)
  • Improve "syncing" spinner display
    on the "Rewards" screen:

Screenshots

image (8)
image (7)

Screen Shot 2021-03-31 at 11 47 00 AM

Screen Shot 2021-03-31 at 11 47 14 AM

Screen Shot 2021-03-31 at 11 47 42 AM

Screen Shot 2021-03-31 at 11 47 31 AM


Testing Checklist


Test Cases

Given that I have restored a wallet in Daedalus
When I navigate to the rewards tab in delegation centre
Then I can see the staking address for the wallet

Given that I have restored a wallet in Daedalus
And it is still currently loading 
When I navigate to the rewards tab in delegation centre
Then I can see the staking address for the wallet
And I should see. Loading spinner in the  Total rewards earned(ADA) column

Review Checklist

Basics

  • PR has been assigned and has appropriate labels (feature/bug/chore, release-x.x.x)
  • PR is updated to the most recent version of the target branch (and there are no conflicts)
  • PR has a good description that summarizes all changes
  • PR has default-sized Daedalus window screenshots or animated GIFs of important UI changes:
    • In English
    • In Japanese
  • CHANGELOG entry has been added to the top of the appropriate section (Features, Fixes, Chores) and is linked to the correct PR on GitHub
  • Automated tests: All acceptance and unit tests are passing (yarn test)
  • Manual tests (minimum tests should cover newly added feature/fix): App works correctly in development build (yarn dev)
  • Manual tests (minimum tests should cover newly added feature/fix): App works correctly in production build (yarn package / CI builds)
  • There are no flow errors or warnings (yarn flow:test)
  • There are no lint errors or warnings (yarn lint)
  • There are no prettier errors or warnings (yarn prettier:check)
  • There are no missing translations (running yarn manage:translations produces no changes)
  • Text changes are proofread and approved (Jane Wild / Amy Reeve)
  • Japanese text changes are proofread and approved (Junko Oda)
  • UI changes look good in all themes (Alexander Rukin)
  • Storybook works and no stories are broken (yarn storybook)
  • In case of dependency changes yarn.lock file is updated

Code Quality

  • Important parts of the code are properly commented and documented
  • Code is properly typed with flow
  • React components are split-up enough to avoid unnecessary re-renderings
  • Any code that only works in main process is neatly separated from components

Testing

  • New feature/change is covered by acceptance tests
  • New feature/change is manually tested and approved by QA team
  • All existing acceptance tests are still up-to-date
  • New feature/change is covered by Daedalus Testing scenario
  • All existing Daedalus Testing scenarios are still up-to-date

After Review

  • Merge the PR
  • Delete the source branch
  • Move the ticket to done column on the YouTrack board
  • Update Slack QA thread by marking it with a green checkmark

@DeeJayElly DeeJayElly removed the WIP label Mar 30, 2021
@DeeJayElly DeeJayElly requested review from a team and thedanheller March 30, 2021 08:04
…address' into feature/ddw-605-display-rewards-address
@ManusMcCole
Copy link

ManusMcCole commented Mar 31, 2021

Hi @aleksandardjordjeviciohk. Implementation looks good. I just have one question/recommendation. Would it look better if the spinner would be aligned to the left like Wallet and Total rewards earned(ADA) columns when address field is blank. What do you think @nikolaglumac ? In Zepelin it shows the loading spinner next to the address but it seems both dont exist at the same time as address only pops up after its fully loaded Screenshot

Copy link
Contributor Author

@nikolaglumac nikolaglumac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aleksandardjordjeviciohk please see my change requests 🙏

{isRestoring && (
</td>
<td className={styles.rewardsAddress}>
{isRestoring ? (
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aleksandardjordjeviciohk please make sure we show the rewards address during restoration too.
cc @ManusMcCole

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aleksandardjordjeviciohk please post screenshots once this is fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ManusMcCole @gabriela-ponce @miorsufianiohk @aleksandardjordjeviciohk we want this screen to look like this:

staking-rewards

The rewards address column is to be in the middle!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screen Shot 2021-03-31 at 5 35 41 AM

@ManusMcCole ManusMcCole self-requested a review March 31, 2021 11:31
Copy link

@ManusMcCole ManusMcCole left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good @aleksandardjordjeviciohk 👍

@ManusMcCole
Copy link

ManusMcCole commented Mar 31, 2021

Hi @aleksandardjordjeviciohk. When downloaded to the .csv now the headers are in the right place but the values for Rewards Address and Total Rewards Earned(ADA) are mixed up. See Screenshot

@DeeJayElly
Copy link
Contributor

Hi @aleksandardjordjeviciohk. When downloaded to the .csv now the headers are in the right place but the values for Rewards Address and Total Rewards Earned(ADA) are mixed up. See Screenshot

Fixed @ManusMcCole

@alexander-rukin alexander-rukin self-requested a review March 31, 2021 18:40
@nikolaglumac nikolaglumac merged commit dfeaafe into develop Mar 31, 2021
@iohk-bors iohk-bors bot deleted the feature/ddw-605-display-rewards-address branch March 31, 2021 18:55
@nikolaglumac nikolaglumac added release-4.0.4 Daedalus Mainnet and removed ⏳release-vNext labels Apr 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature release-4.0.4 Daedalus Mainnet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants