Skip to content
This repository has been archived by the owner on Jun 19, 2018. It is now read-only.
This repository has been archived by the owner on Jun 19, 2018. It is now read-only.

Drag calendar event causes messy UI update #209

Closed
bp74 opened this issue Nov 17, 2015 · 4 comments
Closed

Drag calendar event causes messy UI update #209

bp74 opened this issue Nov 17, 2015 · 4 comments

Comments

@bp74
Copy link

bp74 commented Nov 17, 2015

If the user drags a calendar event on the day view, the event will be shown on the previous position for a fraction of a second. Let's say the event starts at 10am and i drag it to 11am, i can see that the event jumps back to 10am and then back to 11am.

my on-event-times-changed handler looks like this:

on-event-times-changed="ctl.onEventTimesChanged(calendarEvent, calendarNewEventStart, calendarNewEventEnd)"

but even if i use the update shown in the documentation, the behavior is the same

on-event-times-changed="calendarEvent.startsAt = calendarNewEventStart; calendarEvent.endsAt = calendarNewEventEnd"

I don't know what i could try to make the ui experience more pleasant. Thanks a lot!

@bp74
Copy link
Author

bp74 commented Nov 17, 2015

btw. the same thing happens if the user does a resize of the calendar event.

@mattlewis92
Copy link
Owner

It's because the calendar resets the position to the original position and then the times are updated in the next digest. I suppose I could change the API to by default alter the event start / end dates, and then instead pass what they used to be and allow you to change them back yourself if you cancelled etc

@bp74
Copy link
Author

bp74 commented Nov 17, 2015

Yes that would be great. If someone allows drag and resize of an calendar events it's likely that the event should be set to the new startAt and endAt times. Or maybe you can wait for the outcome of the event handler?

@bp74
Copy link
Author

bp74 commented Nov 24, 2015

Thanks a lot! That works great and looks much better.

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

No branches or pull requests

2 participants