-
Notifications
You must be signed in to change notification settings - Fork 360
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
feat: add graceful support for max Celo votes #856
feat: add graceful support for max Celo votes #856
Conversation
🦋 Changeset detectedLatest commit: 99d64e2 The changes in this PR will be included in the next version bump. This PR includes changesets to release 5 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@andyhass is attempting to deploy a commit to the LedgerHQ Team on Vercel. A member of the Team first needs to authorize it. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Codecov Report
@@ Coverage Diff @@
## feat/celo #856 +/- ##
=============================================
- Coverage 47.32% 47.11% -0.22%
=============================================
Files 618 626 +8
Lines 27617 28263 +646
Branches 6949 7323 +374
=============================================
+ Hits 13071 13315 +244
+ Misses 14486 13799 -687
- Partials 60 1149 +1089
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
Hey @andyhass,
|
Hey @aelmilligy-ledger - thanks for reviewing. I've added the changelog and fixed up the merge conflicts as requested 😄 |
@@ -45,9 +46,10 @@ const ManageModal = ({ name, account, ...rest }: Props) => { | |||
}, | |||
[dispatch, account], | |||
); | |||
|
|||
const groupsVotedFor = [...new Set(celoResources.votes.map(v => v.validatorGroup))]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe useMemo
would be useful here?...
📝 Description
There are a maximum number of Celo validator groups that can be voted for. Previously, this error was not handled that well. The user would be able to select the option to vote, but would then see this error message when choosing an amount to vote:
With this change, we indicate that the user cannot vote in staking management dashboard and prevent them from getting to the voting flow:
❓ Context
LLD, LLC
✅ Checklist
📸 Demo
See above
🚀 Expectations to reach
Please make sure you follow these Important Steps.
Pull Requests must pass the CI and be internally validated in order to be merged.