Skip to content

Commit

Permalink
revert to working version
Browse files Browse the repository at this point in the history
Signed-off-by: Huong Nguyen <huongg1409@gmail>
  • Loading branch information
Huong Nguyen committed Jun 25, 2024
1 parent cc6b57e commit fe41c77
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/kedro_sphinx_theme/theme/kedro-sphinx-theme/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,17 @@
openBtn.classList.add('wy-nav-top-open');
document.querySelector('.wy-nav-top').prepend(openBtn);

// Get the current URL
const currentUrl = window.location.href;

// Select all navigation links within the .wy-main-nav container
var navLinks = document.querySelectorAll('.wy-main-nav .wy-main-nav-link');

// Function to remove 'active' class from all links
function removeActiveClass() {
navLinks.forEach(function(link) {
link.classList.remove('active');
});
}

// Add click event listener to each link
navLinks.forEach(function(link) {
link.addEventListener('click', function(event) {
// Prevent the default link action
Expand Down

0 comments on commit fe41c77

Please sign in to comment.