ka215 / jquery.timeline

You can easily create the horizontal timeline with two types by using this jQuery plugin.
MIT License
240 stars 43 forks source link

hoverEvent #84

Open etalla opened 3 years ago

etalla commented 3 years ago

The docs mention a "hoverEvent" that can be set to true/false in Effects.

Can an action (such as opening a popup with the event details) be tied to that and if so how?

ka215 commented 3 years ago

Hi there, The Effects.hoverEvent option allows you to change the component style of an event node on the pointer type only. Therefore, it is incorrect to use this option to handle other events. If you want to handle all event nodes with custom actions, it is best to use the "openEvent" method. Alternatively, the following approach can be considered.

$(document).on('mouseenter', '.jqtl-event-node', function(e){
  console.log('This event node is hovering now!')
})

Thank you,