Skip to content

Commit

Permalink
Navbar Z-index and navbar handler issue is solved, Issue number #715
Browse files Browse the repository at this point in the history
  • Loading branch information
Hemraj-7 committed Nov 2, 2024
1 parent 51707b6 commit 70b23a9
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
10 changes: 5 additions & 5 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,11 @@

<nav>
<ul id="menuList">
<li><a href="#controller">Game Controllers</a></li>
<li><a href="#vrsection">VR Accessories</a></li>
<li><a href="#keyboard">Gaming Keyboard</a></li>
<li><a href="#others">Others</a></li>
<li class="login"><a href="login/login.html">Login</a></li>
<li><a href="#controller" onclick="closeNav()">Game Controllers</a></li>
<li><a href="#vrsection" onclick="closeNav()">VR Accessories</a></li>
<li><a href="#keyboard" onclick="closeNav()">Gaming Keyboard</a></li>
<li><a href="#others" onclick="closeNav()">Others</a></li>
<li class="login"><a href="login/login.html" onclick="closeNav()">Login</a></li>
<!-- Theme Toggle -->
<li><label class="switch">
<input type="checkbox" id="theme-toggle" onchange="toggleTheme()">
Expand Down
5 changes: 5 additions & 0 deletions script.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ function toggleMenu() {
}
}

function closeNav(){
menuList.style.height = "0px";
menuList.style.paddingTop = "0px";
}

window.onscroll = function() {
updateProgressBar();
};
Expand Down
1 change: 1 addition & 0 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -1284,6 +1284,7 @@ button {
#menuList {
overflow: hidden;
transition: 0.5s;
z-index: 99;
}

.row {
Expand Down

0 comments on commit 70b23a9

Please sign in to comment.