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 am getting the same error. The issues seems to be because these currencies are 0 decimal currencies Zero-decimal currencies and the behavior for decimalScale is wrong. Zero-decimal currencies should not have any decimal scale since they don't have fractions so the intlConfig of these should be zero. Now where the bug exists is that for some reason it assumes every value after the first is a decimal so if ur decimalScale is 2 then 123456 => result: 120. however, even if you change your decimal scale to 0, the result will be 123456 => result: 1 because the code is incorrectly interpreting that 23456 are decimal values
Describe the bug
When entering amounts in JPY or KRW, we lose all but the first two digits on blur. Then padRight(3, '0')
e.g.:
enter:
123456
=> result:120
enter:
1
=> result:100
To Reproduce
Steps to reproduce the behavior:
value={value1}
decimalScale={2}
onValueChange={handleOnValue1Change}
intlConfig={{ locale: "ja-JP", currency: "JPY" }}
disableAbbreviations
Expected behavior
See 12,345 in field
Code Sandbox
If applicable, please fork this CodeSandbox template and customise it to replicate your issue.
Additional context
The text was updated successfully, but these errors were encountered: