mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
Removing unneccessary code from header.php
Removing unnecessary code from header.php that prevents the dropdown-menus in the nav-bar from closing after another one is opened.
This commit is contained in:
@@ -598,16 +598,3 @@
|
||||
</nav>
|
||||
<div id="clubswitchModal-container"></div>
|
||||
<div id="stopImpersonateModal-container"></div>
|
||||
<script>
|
||||
let headerMenu = document.getElementById('header-menu');
|
||||
let dropdowns = document.querySelectorAll('.dropdown-toggle');
|
||||
|
||||
dropdowns.forEach((dd) => {
|
||||
dd.addEventListener('click', function(e) {
|
||||
if (headerMenu.clientWidth < 992) {
|
||||
var el = this.nextElementSibling;
|
||||
el.style.display = el.style.display === 'block' ? 'none' : 'block';
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user