-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Calendar: I double-click outside to close the calendar after selecting the range. #6920
Comments
@melloware I'm still seeing this issue as of 10.7.1, and it looks like it was introduced as of 10.5.1: <Calendar value={dates} onChange={(e) => setDates(e.value)} selectionMode="range" hideOnRangeSelection={false} />
I was able to get around this by reverting to 10.5.0. I suspected it was to do with this change, but can't see why that would be an issue: #5971 |
@KumJungMin care to investigate? |
Sure, I’m interested in looking into it :) (I will check it by October 14th at the latest.) |
First of all, Thank you for re-verifying the bug and my code doesn't work as you expected. Why the Issue Occurred in v10.5.2?
Problematic code snippet (Calendar.js) The Issue Resolved?
Related code snippet (Calendar.js) If I misunderstood something or if you have further questions, feel free to leave a comment! :) @lkuich |
I can confirm this is now working for us as of |
@KumJungMin I think there was a side-effect of this change, in our project we use the Here's a working example on Stackblitz: https://stackblitz.com/edit/vitejs-vite-d6qwad?file=src%2FApp.tsx Let me know if I should raise this as a separate issue! |
@lkuich yes please open a new issue with your reproducer. |
Describe the bug
I selected a range on the calendar and the calendar will automatically close.
In this state, open the calendar again.
And In order to close the calendar, i tried to click outside the calendar once.
However, contrary to expectations, i need to double-click to close the calendar.
This issue occurs only once after selecting a range on the calendar.
2024-07-24.9.18.54.mov
Reproducer
https://stackblitz.com/run?file=src%2FApp.jsx
PrimeReact version
master
React version
17.x
Language
TypeScript
Build / Runtime
Create React App (CRA)
Browser(s)
Chrome
Steps to reproduce the behavior
Expected behavior
Assume that a range has been selected on the calendar.
Then, when you open the calendar again and click outside of it, the calendar should be close immediately.
The text was updated successfully, but these errors were encountered: