You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(First of all: @jdewit, it's the first time I write to you, so let me say that this datepicker plugin is excellent and super-useful!)
Datepicker triggers the "hidden" event under certain circumstances. The problem is that other elements, up in the DOM tree could be listening for that event also and, because datepicker doesn't stop the propagation of the event after handling it, those elements receive the event and could act in unexpected ways.
In my particular case, there was a listener ready to .remove() a popup after the "hidden" event is triggered on the popup. When a datepicker inside that popup is closed, the corresponding "hidden" event gets fired, "climbs" up the DOM tree, gets to my popup and the popup is unwillingly removed.
However, probably this is the way datepicker is supposed to work... I'm not sure. It could be the user's responsibility to check if the event triggered is really the one it's been expecting (like I did: checked if event.target == event.currentTarget before removing the popup... that condition is not met when datepicker closes), or it could be the plugin's responsibility to stop the propagation if the event is ment for it.
Hope this is helpful :-)
The text was updated successfully, but these errors were encountered:
(First of all: @jdewit, it's the first time I write to you, so let me say that this datepicker plugin is excellent and super-useful!)
Datepicker triggers the "hidden" event under certain circumstances. The problem is that other elements, up in the DOM tree could be listening for that event also and, because datepicker doesn't stop the propagation of the event after handling it, those elements receive the event and could act in unexpected ways.
In my particular case, there was a listener ready to .remove() a popup after the "hidden" event is triggered on the popup. When a datepicker inside that popup is closed, the corresponding "hidden" event gets fired, "climbs" up the DOM tree, gets to my popup and the popup is unwillingly removed.
However, probably this is the way datepicker is supposed to work... I'm not sure. It could be the user's responsibility to check if the event triggered is really the one it's been expecting (like I did: checked if event.target == event.currentTarget before removing the popup... that condition is not met when datepicker closes), or it could be the plugin's responsibility to stop the propagation if the event is ment for it.
Hope this is helpful :-)
The text was updated successfully, but these errors were encountered: