You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I had a number-input with decimal=false and though that does prevent a user from entering a decimal point, if the user instead pastes in a value like 100.32, the decimal point is just removed, leaving 10032, which is obviously way bigger. The expected behavior is that the decimal portion be trimmed off.
It works fine, however, if decimals are allowed and the user pastes in a number with more decimal digits. For example, if they paste in 100.321, with default options, the input will show just 100.32.
I tried setting decimal=0 but that didn't fix it. I'm happy to submit a PR, but I don't know what to change to allow this. I'm guessing an else condition here, but I'm not sure:
I had a
number-input
withdecimal=false
and though that does prevent a user from entering a decimal point, if the user instead pastes in a value like 100.32, the decimal point is just removed, leaving 10032, which is obviously way bigger. The expected behavior is that the decimal portion be trimmed off.It works fine, however, if decimals are allowed and the user pastes in a number with more decimal digits. For example, if they paste in 100.321, with default options, the input will show just 100.32.
I tried setting
decimal=0
but that didn't fix it. I'm happy to submit a PR, but I don't know what to change to allow this. I'm guessing anelse
condition here, but I'm not sure:The text was updated successfully, but these errors were encountered: