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

Token transfer assets elements #502

Merged
merged 16 commits into from
May 19, 2023

Conversation

GhenadieVP
Copy link
Contributor

@GhenadieVP GhenadieVP commented May 18, 2023

Jira ticket: paste link here

Description

Asset elements for the token transfer.

  • Add/remove account.
  • Add/remove/edit fungible resource.
  • Add/remove non fungible resource.
  • Transfer validation:
    • All containers should have an associated account and at least one resource.
    • Fungible resource transferred amount should be greater than zero.
    • Total sum of transferred fungible resource should not go over total sum.

Screenshot

@GhenadieVP GhenadieVP marked this pull request as ready for review May 18, 2023 11:04
@GhenadieVP GhenadieVP changed the title WIP -> Token transfer assets elements oken transfer assets elements May 18, 2023
@GhenadieVP GhenadieVP changed the title oken transfer assets elements Token transfer assets elements May 18, 2023
Copy link
Contributor

@kugel3 kugel3 left a comment

Choose a reason for hiding this comment

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

Not directly related to this PR:
Now with your nice RoundedCorners implementation, we should get rid of the bad old version that Nikola added. I polished it up before, but it's time to get rid of it. The only good thing was that it used UIRectEdge, and we're probably always interested in pairs of corners.

I would extend UIRectCorner with bottom and top, switch the order of the arguments in your modifier, remove the label for corners and then get rid of .bottom- and and .topRoundedCorners. That would put it inline with .padding.

Something like

func roundedCorners(_ corners: UIRectCorner = .allCorners, fillColor: Color = .app.white, strokeColor: Color = .clear) -> some View

Also not sure what self.modifier... does.

@kugel3
Copy link
Contributor

kugel3 commented May 18, 2023

Looks great. I would probably put the total sum error message below the box, and also ideally make the box border red.

Copy link
Contributor

@CyonAlexRDX CyonAlexRDX left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Contributor

@kugel3 kugel3 left a comment

Choose a reason for hiding this comment

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

Excellent overall, just some minor comments, mostly about unifying with views from TransactionReview

@GhenadieVP GhenadieVP merged commit d4f5300 into main May 19, 2023
@GhenadieVP GhenadieVP deleted the fix/ABW-1482-i-os-token-transfer-assets-elements branch May 19, 2023 05:00
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants