diff --git a/static/js/cours.js b/static/js/cours.js index f959d60..6537fad 100644 --- a/static/js/cours.js +++ b/static/js/cours.js @@ -19,11 +19,15 @@ const buildFileTree = (parent, data, location) => { li.classList.add("collapsed"); // Toggle collapsing on click - li.addEventListener("click", function (e) { - if (e.target === li) { - li.classList.toggle("collapsed"); - } - }); + li.addEventListener( + "click", + (e) => { + if (e.target === li) { + li.classList.toggle("collapsed"); + } + }, + { passive: true } + ); } else { // File const url = window.location.href.split("?")[0];