Fix button menu overlay again
This commit is contained in:
parent
8f5438a323
commit
c70731ba83
@ -17,12 +17,11 @@ const ButtonMenuToggleHandler = (el: HTMLElement) => {
|
|||||||
if(!el.classList.contains('btn-menu-toggle')) return false;
|
if(!el.classList.contains('btn-menu-toggle')) return false;
|
||||||
|
|
||||||
//window.removeEventListener('mousemove', onMouseMove);
|
//window.removeEventListener('mousemove', onMouseMove);
|
||||||
let openedMenu = el.querySelector('.btn-menu') as HTMLDivElement;
|
const openedMenu = el.querySelector('.btn-menu') as HTMLDivElement;
|
||||||
e.cancelBubble = true;
|
e.cancelBubble = true;
|
||||||
//cancelEvent(e);
|
//cancelEvent(e);
|
||||||
|
|
||||||
if(el.classList.contains('menu-open')) {
|
if(el.classList.contains('menu-open')) {
|
||||||
el.classList.remove('menu-open');
|
|
||||||
closeBtnMenu();
|
closeBtnMenu();
|
||||||
} else {
|
} else {
|
||||||
openBtnMenu(openedMenu);
|
openBtnMenu(openedMenu);
|
||||||
|
@ -148,13 +148,20 @@
|
|||||||
} */
|
} */
|
||||||
&-overlay {
|
&-overlay {
|
||||||
position: fixed !important;
|
position: fixed !important;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
top: 0;
|
||||||
|
bottom: 0;
|
||||||
|
z-index: 1;
|
||||||
|
cursor: default;
|
||||||
|
//background-color: rgba(0, 0, 0, .2);
|
||||||
|
}
|
||||||
|
|
||||||
|
&-toggle &-overlay {
|
||||||
left: -100vw;
|
left: -100vw;
|
||||||
right: -100vw;
|
right: -100vw;
|
||||||
top: -100vh;
|
top: -100vh;
|
||||||
bottom: -100vh;
|
bottom: -100vh;
|
||||||
z-index: 1;
|
|
||||||
cursor: default;
|
|
||||||
//background-color: rgba(0, 0, 0, .2);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user