From 27d88f0b226a0bb8e07f0bea83f47a9bc4bbff32 Mon Sep 17 00:00:00 2001 From: polo Date: Thu, 10 Jul 2025 18:11:30 +0200 Subject: =?UTF-8?q?sous-menus=20d=C3=A9roulables=20avec=20=C3=A9cran=20tac?= =?UTF-8?q?tile?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/js/main.js | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'public/js/main.js') diff --git a/public/js/main.js b/public/js/main.js index 071a1db..6eb0162 100644 --- a/public/js/main.js +++ b/public/js/main.js @@ -8,6 +8,33 @@ function newPassword(page, id = ''){ }, 0); } +// ouvrir/fermer les sous-menus avec écran tactile +document.addEventListener('DOMContentLoaded', () => { // sinon on ne trouve pas les boutons + document.querySelectorAll('.sub-menu-toggle').forEach(button => { + button.addEventListener('click', e => { + e.preventDefault(); + const li = button.parentElement; //