When typing in a date, UI of the component does not update, but onChange is triggered.
When typing in a date, and not selecting it, the date gets formatted and selected, and it also triggers the onChange event. This all works great, however, the menu that is meant for selecting dates still shows the previous date, and does not update with the typed date.
https://github.com/onesine/react-tailwindcss-datepicker/assets/102895212/d999d527-f3a2-416c-8fa4-3605206bea3d
The onChange() event is also triggered
The only issue being that the UI still shows Jun 13, 2023 for example, even after putting a date from september 2020.
Hi 👋 @generic-glitch
Thanks for the feedback.
We will take a look at it very soon.
Thank you so much!
I'll try to figure out more as to why this happens myself if I have time, and possibly come to a solution.
I have just released a new version which should solve the problem. Can you try and close this issue if it's ok.
Could I see what props you gave to the Datepicker element?
For me it still happens
https://github.com/onesine/react-tailwindcss-datepicker/assets/102895212/cab3dcae-284e-4fb5-86ad-202ea8e9fe43
And I updated react-tailwindcss-datepicker to:
(I tried npm update, uninstalling and reinstalling, etc)
This is my code for the datepicker as well:
I've also noticed that there's still the problem. There seems to be something I'm missing. The local test passes though.
I've also noticed that there's still the problem. There seems to be something I'm missing. The local test passes though.
I think since the onChange event still gets executed, the fix should probably just be some code added in the onChange event to just set the date/update the state of the actual UI of the component.