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

fix(ui): remove incorrect pool max stake calculations #364

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

drichar
Copy link
Collaborator

@drichar drichar commented Feb 6, 2025

Description

This PR fixes how pool stake maximums are calculated and displayed. Previously, the validator's total stake limit was incorrectly divided evenly between all pools. Now each pool correctly shows its individual maximum based on either the validator's configured limit or the maxAlgoPerPool protocol constraint.

Details

  • Remove logic that divided maxAlgoPerValidator evenly between pools
  • Show each pool's true maximum capacity based on validator config or protocol constraint
  • Maintain validator-wide stake limit using maxAlgoPerValidator
  • Extract stake progress bar display logic into reusable StakeProgressBar component

Remove logic that incorrectly divided validator's hard max stake limit evenly
between pools. Each pool now correctly shows its max capacity based on either
the validator's configured limit or the `maxAlgoPerPool` protocol constraint,
while the validator's total stake remains capped by `maxAlgoPerValidator`
protocol constraint.

Extract progress bar display logic into reusable `StakeProgressBar` component.
Copy link

vercel bot commented Feb 6, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
reti ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 6, 2025 10:39pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant