Skip to content

Bluring component causes certain currencies to lose most of input #310

Closed
@willyls-VG

Description

@willyls-VG

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:

  1. Create component with this setup:
    value={value1}
    decimalScale={2}
    onValueChange={handleOnValue1Change}
    intlConfig={{ locale: "ja-JP", currency: "JPY" }}
    disableAbbreviations
  2. Enter amount in first input
  3. Enter 12345
  4. Blur from

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

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions