vascofg / react-admin-date-inputs

Date Inputs for react-admin
MIT License
67 stars 81 forks source link

Months' days are displayed with year's days' numbers #7

Closed Kaukov closed 5 years ago

Kaukov commented 6 years ago

Hello!

I wanted to try your package, but when I use it with the latest react-admin, I see the year's day numbers instead of the month's day numbers.

Screenshot

Edit:

Upon investigation, it seems this is a problem from using DateFnsUtils. Using Moment works properly

vascofg commented 6 years ago

Can you please confirm this is related to this issue: https://github.com/dmtrKovalenko/material-ui-pickers/issues/424

Kaukov commented 6 years ago

Yes, it's related to this issue. and 414 as well

vascofg commented 6 years ago

But do you have a different version of date-fns-utils installed? I've also encountered this issue while using a @material-ui version later than ~1.0.0. Can you try to install it and see if the problem persists?

Kaukov commented 6 years ago

The version of date-fns is date-fns@2.0.0-alpha.7. A few packages depend on it and I think your package requiers the exact alpha.7 version and this is the one installed.

As for material-ui:
@material-ui/core@1.3.1 @material-ui/icons@1.1.0

And as I said above - the issue is with Material-UI-Pickers and the issue is gone when using MomentUtils instead of DateFnsUtils.

vascofg commented 5 years ago

@Kaukov are you still having this issue? Can't seem to reproduce on my side with:

Kaukov commented 5 years ago

I'm sorry, we moved that project to the backlog since a lot of stuff has come up.

I will close this issue now since I don't have the time to test, but if it works for you, it might be fixed.

If it comes up again, I'll open another issue.

Thanks!