-
Notifications
You must be signed in to change notification settings - Fork 212
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
Finance, Token Manager: Forms MAX button #1130
Finance, Token Manager: Forms MAX button #1130
Conversation
Thanks for opening this pull request! Someone will review it soon 🔍 |
Move the TextInput + “Max” button into its own component, AmountInput. Other changes (“Max” button): - Add a pressed state. - Tweak the interactive area to make it fill the input field. - Add a radius on the focus ring.
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.
Hey @JuanCarlosFrutos, thank you for this, it’s feels so much better now! 😍
I added a few changes, nothing big:
- Move the TextInput + “Max” button into its own component, AmountInput (making it ready to move to aragonUI later 🙌).
- “Max” button:
- Add a pressed state.
- Tweak the interactive area to make it fill the input field.
- Add a radius on the focus ring.
About your concerns:
I can't input for selecting an amount on the agent app (according to the description of the issue, there should be).
Ah yes this is a mistake, there is no panel in the Agent app.
I'm not sure about test strategy on this repo so PR hasn't tested.
I tested it manually on a few browsers and it’s working well. 👍
Thanks again, and sorry for having taken so long to review this!
Just noticed this:
For the "add tokens" feature I'm not sure it makes sense to have a "max" button because in our templates there is either a max of 1 or no maximum (and in the latter case I'm not sure what pressing the "Max" button would do). Thoughts? |
@john-light Nice catch! 🙏 I opened a PR to only display it on remove: #1150 |
A new component has been added locally: AmountInput. It uses TextInput internally, and can optionally display a “Max” button.
Closes aragon/client#1301
It adds 'MAX' button for selecting max amount available. The button is added on these sections:
Concerns
According to the description of the issue, there should be).