-
Notifications
You must be signed in to change notification settings - Fork 78
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
Datagrid: Placeholder sets to NaN.000 after clicking in the empty field #5395
Comments
@Jah25 Maybe should have pointed you in the right place as datagrid is a bit crazy. But i think the problem is that we are using: formatter: placeholder and editor:input on numbers here: Since this is a first issue i think its maybe a little complex to start with (sorry on my part). But i can see a fix which would be in https://github.com/infor-design/enterprise/blob/main/src/components/datagrid/datagrid.js#L10434 The coerveValue function is trying to put the data back in the source format fx (number in this case). I think it would be safe to exclude NaN here. So maybe NaN it just shows blank
Something along those lines. But just a hint. Im noticing this example is a little odd as well so maybe we just fix this quick and move on. HTH |
@tmcconechy Hey Tim I just saw this. Yeah it took a little chasing to find it but I also found the coercion was the issue though I ran across it here where the coercion is checking against the oldValue to determine the datatype it should force too https://github.com/infor-design/enterprise/blob/main/src/components/datagrid/datagrid.js#L10372 my fix was going to be something like this I don't think it's perfect protection but it covers a few more edge cases, do you want to move forward with a change or the example fix? |
@Jah25 that sounds like it should work. Lets give it a try |
This issue is now resolved. |
Describe the bug
Datagrid: Palaceholder sets to NaN.000 after clicking in the empty field
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Placeholder should show
Version
4.530 - beta - IDS
Screenshots
Platform
All major browsers & OS
Additional context
N/a
The text was updated successfully, but these errors were encountered: