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
In the close function, this code unbinds all keydown events: $(document).off('keydown');
Need to describe a keyDown function:
keyDownEvent: function (e) {
// Close lightbox with ESC
if (e.keyCode === 27) {
plugin.close();
}
// Go to next image pressing the right key
if (e.keyCode === 39) {
plugin.next();
}
// Go to previous image pressing the left key
if (e.keyCode === 37) {
plugin.previous();
}
}
and need to add: $(document).on('keydown', plugin.keyDownEvent);
and to remove only this function: $(document).unbind('keydown', plugin.keyDownEvent);
The text was updated successfully, but these errors were encountered:
In the close function, this code unbinds all keydown events:
$(document).off('keydown');
Need to describe a keyDown function:
and need to add:
$(document).on('keydown', plugin.keyDownEvent);
and to remove only this function:
$(document).unbind('keydown', plugin.keyDownEvent);
The text was updated successfully, but these errors were encountered: