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

[bug]: react-day-picker 9.0.0 release screws up Calendar component #4366

Open
2 tasks done
gregpr07 opened this issue Jul 21, 2024 · 18 comments · May be fixed by #4371
Open
2 tasks done

[bug]: react-day-picker 9.0.0 release screws up Calendar component #4366

gregpr07 opened this issue Jul 21, 2024 · 18 comments · May be fixed by #4371
Labels
bug Something isn't working

Comments

@gregpr07
Copy link

Describe the bug

CleanShot 2024-07-21 at 17 46 51@2x

Currently, the component looks like this.

Fix:
You can currently fix this by downgrading react-day-picker to version 8.^

Affected component/components

Calendar, Date Picker, ...

How to reproduce

  1. Install Calendar component

Codesandbox/StackBlitz link

No response

Logs

No response

System Info

Browsers

Before submitting

  • I've made research efforts and searched the documentation
  • I've searched for existing issues
@gregpr07 gregpr07 added the bug Something isn't working label Jul 21, 2024
@Cheveniko
Copy link

Easiest solution right now is to downgrade to 8.10.1.
The react-day-picker team has already been notified of this issue in the v9.0.0 release announcement

@grzegorzpokorski
Copy link

grzegorzpokorski commented Jul 21, 2024

Here are my adjusted styles for the Calendar component:
https://github.com/grzegorzpokorski/calendar-shadcnnui/blob/main/src/components/ui/calendar.tsx.
Maybe someone will have more time to review them and improve.

The most intriguing aspect is the change in the structure of this component, particularly the navigation between months. I am not sure if the current design is appropriate (playing with z-index).

@efgomes
Copy link

efgomes commented Jul 21, 2024

Here are my adjusted styles for the Calendar component: https://github.com/grzegorzpokorski/calendar-shadcnnui/blob/main/src/components/ui/calendar.tsx. Maybe someone will have more time to review them and improve.

The most intriguing aspect is the change in the structure of this component, particularly the navigation between months. I am not sure if the current design is appropriate (playing with z-index).

OK, I'm using your code. When making adjustments to my code and not finding another solution for positioning the navigation buttons, I used the z-index

@NamorAgro
Copy link

same bug ((

@NamorAgro
Copy link

Easiest solution right now is to downgrade to 8.10.1. The react-day-picker team has already been notified of this issue in the v9.0.0 release announcement

npx shadcn-ui@8.10.1 add calendar
gives error, no such version matching

@olsio
Copy link
Contributor

olsio commented Jul 23, 2024

Easiest solution right now is to downgrade to 8.10.1. The react-day-picker team has already been notified of this issue in the v9.0.0 release announcement

npx shadcn-ui@8.10.1 add calendar gives error, no such version matching

The dependency is on react-day-picker. Go to your package.json and set the 8.10.1 there and then run npm install

@AhmedBaset AhmedBaset linked a pull request Jul 23, 2024 that will close this issue
1 task
@flixlix
Copy link
Contributor

flixlix commented Jul 26, 2024

fixed here #4421

@huybuidac
Copy link

huybuidac commented Oct 18, 2024

While waiting for the update, you can try this.

https://shadcn-datetime-picker-pro.vercel.app/
https://github.com/huybuidac/shadcn-datetime-picker

image

@kamami
Copy link

kamami commented Oct 29, 2024

Any update when the latest version of react-day-picker will be supported?

@kulterryan
Copy link

any update on this?

@olsio
Copy link
Contributor

olsio commented Jan 27, 2025

It will never get fixed. There are 850 open PRs with zero movement on maintenance. So you can only fix it for your own project and move on. I stopped contributing a while back. Nothing gets accepted.

@AnatoliiCubex
Copy link

AnatoliiCubex commented Jan 30, 2025

Half a year and 9.*.* still mess styles of 8.*.*

@junwen-k
Copy link

junwen-k commented Feb 3, 2025

Hi everyone! 👋

I’m excited to share an extension library I’ve built for shadcn/ui, which includes a DatePicker reusable component. The calendar styling is updated and fixed, supporting "react-day-picker": ^9. It also supports additional features like Dropdown Layout.

You can check out the DatePicker component here: https://ui-x.junwen-k.dev/docs/components/date-picker

It also supports segmented date inputs using timescape. 🚀

The library also includes other handy components designed to enhance developer productivity. If you find it helpful, I’d be thrilled if you could leave a star—it really helps others discover the project. I’d love to hear your feedback or suggestions, so feel free to share your thoughts! 😊

@rylder
Copy link

rylder commented Feb 4, 2025

I found something here: https://date-picker.luca-felix.com/
The guy did a beautiful job.
I hope it helps you too.

@huybuidac
Copy link

I found something here: https://date-picker.luca-felix.com/ The guy did a beautiful job. I hope it helps you too.

Have you try this one https://shadcn-datetime-picker-pro.vercel.app?

@rylder
Copy link

rylder commented Feb 5, 2025

I found something here: https://date-picker.luca-felix.com/ The guy did a beautiful job. I hope it helps you too.

Have you try this one https://shadcn-datetime-picker-pro.vercel.app?

I took a look, but I just needed the calendar styles corrected.
I already have my DatePicker component and just wanted to fix the style compatibility issue.
At another time, I will certainly test your component in my applications.

@tylerbecks
Copy link

I found something here: https://date-picker.luca-felix.com/ The guy did a beautiful job. I hope it helps you too.

This is also the recommendation in the docs.

@olsio
Copy link
Contributor

olsio commented Feb 15, 2025

I think we might get lucky and get an official fix as collateral. I think they are working on a tailwind 4 migration and will touch all the components.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.