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

Event shown on top of another Event (hiding the one below) #512

Closed
sobanhameed opened this issue Aug 17, 2017 · 9 comments · Fixed by #677
Closed

Event shown on top of another Event (hiding the one below) #512

sobanhameed opened this issue Aug 17, 2017 · 9 comments · Fixed by #677

Comments

@sobanhameed
Copy link

Version 0.12.3 didn't have this issue. I only see this issue in the latest 0.14.4. Notice that we have are giving events 1-6 (with titles 0 to 5). 4 & 5 are displayed on top of each other. If I do display:none on #5 you will see #4 show up. Attaching the start and end times along with order of events array we are passing. I JSON.stringified it so you guys can easily look at it. Seems like an offset calculation issue.

json.stringify.txt

screen shot 2017-08-17 at 2 28 42 pm

screen shot 2017-08-17 at 2 28 54 pm

screen shot 2017-08-17 at 2 29 17 pm

@sobanhameed
Copy link
Author

We are a bit stuck with this. We can't revert to 0.12.3 as it had other issues. Any help or guidance here will be greatly appreciated.

@jquense
Copy link
Owner

jquense commented Aug 17, 2017

Not sure honestly. We'll get around to looking at it, but the fastest way to get it fixed would be to dig into the code and see what's going one, also css @tobiasandersen

@tobiasandersen
Copy link
Collaborator

tobiasandersen commented Aug 18, 2017

Great catch @sobanhameed, I haven't seen this before. I've narrowed down the problem and have a very rough solution (kind of) working. It'll need a little bit of testing and re-work/cleaning up before we can merge it though. I don't have the time at this moment, but if you can wait, I'll submit a fix in the following days (probably next week).

@sobanhameed
Copy link
Author

Thanks. Appreciate the help. We are putting a hacky fix at our end to add forced margin to events with matching start and end (not sure if it will cause other issues) but it will be great to have a right fix for this issue (and get a build up on NPM).

@sobanhameed
Copy link
Author

@tobiasandersen Need your input on the fix we are doing at our side. Is there any way to detect that this is going to happen to some events on rendering? We would like to add some incremental offset to all such events. We attempted setting the incremental offset to all events that have same start date/time but that causes events to unnecessarily bleed out of the calendar rendering area.

Appreciate the help so we can ublock our users.

@tobiasandersen
Copy link
Collaborator

You can take a look at the changes I've made in this branch, and see if that helps you. I'm currently trying some other ideas as well, but that might take a while (and might not even work out in the end).

@sobanhameed
Copy link
Author

I looked at the changes. If you would like I can test these changes in our own setup to see if they work fine.

We have put a hack at our end to force add incremental margins when times exactly match for the appointments on the day. Obviously, it's bad and is causing contents to bleed out of the calendar. Will be great to get this fix in as soon as it looks complete and we can help test it.

@tobiasandersen
Copy link
Collaborator

I think what's in that branch should make it better than what we currently have. But I think it's a bit outdated at the moment.

I'm still working on a new implementation of this, but I went on vacation and haven't touched it in quite a while, until this week when I picked up on it again. Still not sure if/when I'll have anything ready, so I wouldn't count on it.

tobiasandersen added a commit to tobiasandersen/react-big-calendar that referenced this issue Jan 7, 2018
@tobiasandersen
Copy link
Collaborator

@sobanhameed could you see if #677 fixes your problems?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants