question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Some parallel events jump to next day in multi-day view

See original GitHub issue

There seems to be one or more formatting bugs which sets the left: css property incorrectly on parallel events. This results in some parallel events showing up on the wrong day lane in the multi-day calendar.

Looking in the source code, this issue seems related to how the events prop is parsed and in particular how these variables that are used for the css positioning are determined: thisEvent.numberOfOverlaps, thisEvent.overlapIteration, and thisEvent.overlapSegment.

quasar-cal-bug

I’ve gotten as far as having three and four side-by-side events showing properly by hacking the calculateDayEventStyle method like this:

if (thisEvent.numberOfOverlaps == 2 && thisEvent.overlapIteration != 1 && thisEvent.overlapSegment == 1) {
  style['left'] = (thisShift - 66.66) + '%'
} else if (thisEvent.numberOfOverlaps == 2 && thisEvent.overlapIteration == 1 && thisEvent.overlapSegment == 1) {
  style['left'] = (thisShift + 33.33) + '%'
} else if (thisEvent.numberOfOverlaps == 3) {
  style['left'] = (thisShift - 25) + '%'
} else {
  style['left'] = thisShift + '%'
}

I was hoping to see a pattern and derive a generalised fix, but so far I haven’t found it. Any suggestions or explanation of these variables would be very helpful in debugging further. Thanks

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:17

github_iconTop GitHub Comments

4reactions
sirbeaglecommented, Feb 21, 2019

Version v0.3.4 has a slightly different overlap algorithm that, with any luck, should address @msinkgraven test case and an additional test case I caught causing problems. Mostly the same with a couple more checks.

2reactions
sirbeaglecommented, Feb 15, 2019

Okay, v0.3.3 has been pushed which uses a very different overlap algorithm. I’m hoping it fixes everything above, but I’d love some feedback to see if it works for everyone!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Some parallel events jump to next day in multi-day view #33
This results in some parallel events showing up on the wrong day lane in the multi-day calendar. Looking in the source code, this...
Read more >
Tech Tip of the Week #64-Creating Multi-day Events in Google ...
This video will show you how you can create an all day event that spans over multiple days directly from your main calendar...
Read more >
multi day event - - The Events Calendar
Probably the easiest solution would be setting up a recurring event: Event on day one from 1pm to 5pm. And a recurrence rule,...
Read more >
multi_day Scheduler Docs - DHTMLX Documentation
On our side multi day events are only shown in monthly version? ... first "chunk") behaves in a weird way jumping to full...
Read more >
Office 365: Multi-Day Calendar View in Outlook - Help Guides
Press ALT + [number] to show how many consecutive days you want, e.g., ALT + 2 to show two days; ALT + 3...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found