-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Closed
Description
Do you want to request a feature or report a bug?
Bug / Regression caused by #1204
What's the current behavior?
https://codesandbox.io/s/react-big-calendar-example-feofz
- Scroll down to current time.
- Notice that the current time indicator is off by 15 minutes (one step size)
See related issue with events here: https://codesandbox.io/s/react-big-calendar-example-e1o2n
Events shorter than step-size minutes are offset.
What's the expected behavior?
The current time indicator should be at current time.
Likely cause
When calculating the time line position we hit the top branch of this ternary if. The timeslot step (ex: 15) is subtracted from the number of minutes since calendar min.
A calendar starting at 00:00, ending at 23:59, with current time 14:00 has rangeStart/End 14*60=840. We should be at 58,33% of the day, but (840-15)/(15*96)*100=57,29. 15 minutes..
dkenul and IharOk
Metadata
Metadata
Assignees
Labels
No labels
