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

[Pool Simulator] Add validation in new form #171

Merged
merged 28 commits into from
Jul 31, 2023

Conversation

luizakp
Copy link
Contributor

@luizakp luizakp commented Jul 28, 2023

This PR:

  • Closes BAL-533;
  • Add GyroE Form validation
  • Add pool Params visualization after clicking on Next Step
  • Return react-hook-form to version 7.43.9 and @hookform/resolvers to 3.1.0 due to unexpected form behavior
    • When displaying the pool params after clicking on Next Step it was expected to show the data that the user defined on the forms. But when importing a pool and changing those parameters the data displayed was the imported. E.g. Import a pool with swap fee of 0.001 and changed this value to 9. The expected value on pool Params visualization is 9, but rendered value was 0.001.

https://www.loom.com/share/b0a63d9f67234169b307f7f7b325d692?sid=ad4e37f3-70ff-49f3-aa76-118377744a51

Commits regarding this PR:

@linear
Copy link

linear bot commented Jul 28, 2023

BAL-527 Add validation in new Form

image.png

Requirements:

  • Show old error messages (metastable)
  • Show error messages of E-CLP (image above — tokens number not included yet)

@luizakp luizakp had a problem deploying to bleu-balancer-tools-pr-171-preview July 28, 2023 13:22 — with GitHub Actions Failure
ribeirojose
ribeirojose previously approved these changes Jul 28, 2023
Copy link
Contributor

@ribeirojose ribeirojose left a comment

Choose a reason for hiding this comment

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

👌 great refactors

* Remove AMM convertions

* Add tokens on Pool Params form

* show tokens on analysis page

* solve luiza comments

---------

Co-authored-by: luizakp <[email protected]>
@yvesfracari yvesfracari dismissed stale reviews from ribeirojose and themself via e010189 July 28, 2023 13:56
@yvesfracari yvesfracari had a problem deploying to bleu-balancer-tools-pr-171-preview July 28, 2023 13:57 — with GitHub Actions Failure
@linear
Copy link

linear bot commented Jul 28, 2023

@yvesfracari yvesfracari had a problem deploying to bleu-balancer-tools-pr-171-preview July 28, 2023 14:48 — with GitHub Actions Failure
@luizakp luizakp temporarily deployed to bleu-balancer-tools-pr-171-preview July 28, 2023 17:40 — with GitHub Actions Inactive
@@ -169,6 +182,18 @@ export function PoolParamsForm() {
</span>
</div>
))}
<div className="flex flex-col">
<label className="mb-2 block text-sm text-slate12">Tokens</label>
{errors?.tokens?.message && (
Copy link
Contributor

@ribeirojose ribeirojose Jul 28, 2023

Choose a reason for hiding this comment

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

👍 good strategy. think this was not in the video though, was it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, this is from PYC's PR

@luizakp luizakp had a problem deploying to bleu-balancer-tools-pr-171-preview July 31, 2023 12:54 — with GitHub Actions Error
@luizakp luizakp merged commit 704e76e into main Jul 31, 2023
1 of 2 checks passed
@luizakp luizakp deleted the luiza/bal-527-add-validation-in-new-form branch July 31, 2023 12:55
@luizakp luizakp had a problem deploying to bleu-balancer-tools-pr-171-preview July 31, 2023 12:55 — with GitHub Actions Failure
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.

3 participants