Open
Description
First of all: many thanks for this cool library, Flickity really rocks. 🌟
While playing with the fullscreen plugin I encountered a problem with keyboard handling, though.
The Escape key doesn't close the overlay.
Here's the code: https://github.com/metafizzy/flickity-fullscreen/blob/master/fullscreen.js#L92
However, Flickity.keyboardHandlers doesn't expect the number from event.which
, but apparently the string from event.key
: https://github.com/metafizzy/flickity/blob/master/js/core.js#L787
Maybe that behavior changed at some point in the past...
Following fixes it for me:
// ESC key closes full screen
Flickity.keyboardHandlers['Escape'] = function() {
this.exitFullscreen();
};
Is there interest in a pull request, or is this trivial change not worth it, anyway?
Metadata
Metadata
Assignees
Labels
No labels