Issue #3217175 by javi-er, mherchel: Olivero: Make IE11 close submenu when ESC key is pressed
parent
630cd36d0f
commit
21c387a614
|
@ -47,7 +47,7 @@
|
|||
|
||||
// Closes any open sub navigation first, then close header navigation.
|
||||
document.addEventListener('keyup', (e) => {
|
||||
if (e.key === 'Escape') {
|
||||
if (e.key === 'Escape' || e.key === 'Esc') {
|
||||
if (props.olivero.areAnySubNavsOpen()) {
|
||||
props.olivero.closeAllSubNav();
|
||||
} else {
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
toggleNav(props, !isNavOpen(props.navWrapper));
|
||||
});
|
||||
document.addEventListener('keyup', function (e) {
|
||||
if (e.key === 'Escape') {
|
||||
if (e.key === 'Escape' || e.key === 'Esc') {
|
||||
if (props.olivero.areAnySubNavsOpen()) {
|
||||
props.olivero.closeAllSubNav();
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue