diff --git a/assets/js/main.js b/assets/js/main.js index 747d67775..bd2129831 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -20,7 +20,7 @@ $(function () { }) // Press Escape key to close menu - $(window).keypress(function (e) { + $(window).keydown(function (e) { if (e.key === 'Escape') { if (flexContainer.hasClass('active')) { flexContainer.removeClass('active')