Skip to content

Drag and Drop Timeline for external events drop without mouseposition

Hey,

I have lot of external items that I want to drag and drop into the group timeline. I want to drop an item with fix time, start and end.

like:

var item = {
     id: new Date(),
     type: itemType,
     content: event.target.innerHTML.trim(),
     start: new Date(2016,11,17,12,0,0,0),
     end: new Date(2016,11,17,22,0,0,0)
   };

But if I drop the item into the timeline they always takes the position of the mouse pointer for the start time.

How can I solve this problem?