From bbfd6f486aba0c373e855ef76415d26b7ad66f89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Frenoy?= Date: Sun, 20 Jan 2019 14:49:34 +0100 Subject: [PATCH] Do not prevent defaut action on anchor links below the main level of the sidebar menu (Fixes #17) --- static/js/fresh.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/fresh.js b/static/js/fresh.js index 6cec711..cf63bc6 100644 --- a/static/js/fresh.js +++ b/static/js/fresh.js @@ -33,7 +33,7 @@ $(document).ready(function(){ //Sidebar menu if ($('.sidebar').length) { - $(".sidebar-menu > li.have-children a").on("click", function(i){ + $(".sidebar-menu > li.have-children > a").on("click", function(i){ i.preventDefault(); if( ! $(this).parent().hasClass("active") ){ $(".sidebar-menu li ul").slideUp(); @@ -141,4 +141,4 @@ $(document).ready(function(){ } } }); -}) \ No newline at end of file +})