-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
onSelectSlot start date is from the start of the day, not where I start the selection (in week view) #2546
Comments
Hey I have been struggling with the same issue, did you find a work around? |
I made some simple changes to the code within the repository, the file onSelectSlot.js which handles this functionality: 2024-03-29.19-46-57.mp4I tried to modify it by changing the const onSelectSlot:
to this:
I considered using a different date library like Luxon or Day.js. These libraries often have simpler APIs and could handle time zones more intuitively than moment. It ends up in this code:
I hope this helps! @IzaanAnwar @MateiMihaiSTEEP |
This issue should only exist in WEEK and DAY. I created a PR. I hope it can help you. |
is this change in the 11.1.3 ? because is the same issue |
the actual problem that I have is in week view, I try to select slots in the same day but it starts always from the beginning go the day not from where I select |
Not yet, this fix has not been merged into the master branch yet |
Hey everyone, anyone knows which older version i can use to get around this issue? Or when will the fix for this issue will be merged? |
try version 1.11.1 |
Have the same error on the 1.11.1 too |
This should now be resolved in v1.11.6 |
Yes updated the version now its fixed, thank you |
Check that this is really a bug
Reproduction link
https://jquense.github.io/react-big-calendar/examples/index.html?path=/docs/props--on-select-slot
Bug description
Expected Behavior
the start of the slot is not from where I placed the mouse(in week view)
Actual Behavior
when I select a slot(in week view), I want to start from where I first stared selecting, not from another place.
react-big-calendar version
1.11.2 and 11.11.0
React version
18.2.0
Platform/Target and Browser Versions
Chrome, Safari - only here I tested
Validations
Would you like to open a PR for this bug?
Screen.Recording.2024-03-25.at.13.31.36.mov
The text was updated successfully, but these errors were encountered: