lmartins
11/16/2017 - 2:35 PM

Listen for ESC key

// Close modal with ESC key
jQuery(document).keyup( function(e) {
    if ( e.keyCode == 27 && self.active ) {
        // escape key maps to keycode `27`
        self.close();
    }
});