Lock appears, and is enabled, but "Stake" button is also clickable
Expected behavior
Throwing the error is expected if there is a missing approval. However, the Stake button should not be activated until such approval has gone through.
This results in users missing the approval button.
Simple solution: deactivate the button until the approval is done. Replace text with "Allow the Staking contract to use your MTA" or "Allow the Staking contract to use your mBPT"
Probably better solution: Add button above staking to create tx for approval.
See Uniswap example:
Screenshots
Trying to send transactions without approval throws an error.
Non-consistent behaviour throughout the app, in another place e.g. Swap it's handled like this.
We should consolidate the behaviour and make it consistent
.
Describe the bug The button "Stake" is clickable despite needing ERC-20 Approval first.
To Reproduce Steps to reproduce the behavior:
Expected behavior Throwing the error is expected if there is a missing approval. However, the Stake button should not be activated until such approval has gone through. This results in users missing the approval button.
See Uniswap example:
Screenshots
Trying to send transactions without approval throws an error.