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

@mantine/dates setting fixOnBlur to DatePicker has no effect on onChange calls #532

Closed
Foohx opened this issue Dec 17, 2021 · 1 comment
Closed

Comments

@Foohx
Copy link

Foohx commented Dec 17, 2021

What package has an issue

@mantine/dates

Describe the bug

When the fixOnBlur prop is set to false on DatePicker component. The onChange method is still called when the field is unfocused.

This can produce random outcomes on complex dynamic forms. In NextJs project, the onChange method is called multiple times causing a lot of bugs.

In which browser did the problem occur

All

If possible, please include a link to a codesandbox with the reproduced problem

React : https://codesandbox.io/s/strange-satoshi-b0uz9?file=/src/App.tsx
NextJs : https://codesandbox.io/s/next-datepicker-cmi67?file=/pages/index.tsx

As you can see, it's randomly impossible to clear the input on a simple Next project.

Do you know how to fix the issue

No

Are you willing to participate in fixing this issue and create a pull request with the fix

No response

Possible fix

No response

@rtivital
Copy link
Member

Fixed in 3.4.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants