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

[Feature]: Input validation and formatting for Bitcoin Calculator widget #2447

Closed
catch-21 opened this issue Jan 30, 2025 · 1 comment · Fixed by #2457
Closed

[Feature]: Input validation and formatting for Bitcoin Calculator widget #2447

catch-21 opened this issue Jan 30, 2025 · 1 comment · Fixed by #2457
Assignees
Labels
enhancement New feature or request feature request A user has an idea for the app

Comments

@catch-21
Copy link
Contributor

Describe the problem

Beyond use of numeric, there's no other input validation for the two fields on the Bitcoin Calculator widget. There are also some formatting improvements we could make to polish this widget.

Image Image Image Image

Describe the solution

I suggest the following:

  1. Do not allow 0 before any positive value for any currency
  2. Use consistent number of decimal places for fiat currencies. This is always 2 except for the exceptions , as far as I can tell, of KWD and BHD that use 3.
  3. Make it easier to read larger numbers by putting a gap between each group of 3 digits, as we do for balances.
  4. Cap the maximum input for bitcoin to 2_100_000_000_000_000. We could do the same for the fiat value if it results in a bitcoin value higher than this, or display something else, easter egg?
  5. Prevent engineering numbers from being displayed. I think this may be resolved by addressing 4.

Additional context

v1.0.9 (145)

@catch-21 catch-21 added enhancement New feature or request feature request A user has an idea for the app labels Jan 30, 2025
@pwltr pwltr self-assigned this Feb 3, 2025
@pwltr pwltr mentioned this issue Feb 3, 2025
7 tasks
@pwltr pwltr linked a pull request Feb 3, 2025 that will close this issue
7 tasks
@catch-21
Copy link
Contributor Author

verified in v109 (147)

we should allow 3 decimal places for some currencies: #2477

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature request A user has an idea for the app
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants