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

feat: Amount type that allows separating numbers with _s #1758

Merged
merged 2 commits into from
Nov 29, 2024

Conversation

willemneal
Copy link
Member

What

New type which parses strings that include _ as i64s.

Why

When entering amounts users will want to use _s to better read what they are typing. Also with this approach we could add more complex parsing for example 1 XLM.

Known limitations

Allows for any number of _s as long as they don't start or end the string.We might want to be stricter. e.g. only allow them where a , would go e.g. 10_000_000

When entering amounts users will want to use `_`s to better read what they are typing. Also with this approach we could add more complex parsing for example `1 XLM`.
Copy link
Member

@fnando fnando left a comment

Choose a reason for hiding this comment

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

lgtm

@leighmcculloch leighmcculloch removed their request for review November 27, 2024 22:54
@willemneal willemneal enabled auto-merge (squash) November 29, 2024 15:58
@willemneal willemneal merged commit 390c220 into main Nov 29, 2024
30 checks passed
@willemneal willemneal deleted the feat/builder_amount branch November 29, 2024 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants