From f990e999090b07a026efec7e991cce6808bd7637 Mon Sep 17 00:00:00 2001 From: muli Date: Sun, 21 Jan 2024 21:50:20 +0100 Subject: [PATCH] =?UTF-8?q?feat:=20DropDown=20jetzt=20mit=20mehr=20h=C3=BC?= =?UTF-8?q?bsch.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/css/style.css | 8 ++++---- assets/js/nav_toggle.js | 2 +- templates/blocks/navigation.html | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/assets/css/style.css b/assets/css/style.css index 885f3be..eb90b99 100644 --- a/assets/css/style.css +++ b/assets/css/style.css @@ -122,11 +122,11 @@ body { .primary_nav__sub_navlink { color: var(--wtf-nearly-white); + text-decoration: underline; } -.primary_nav__navlink:hover { - color: var(--wtf-mid-grey); - text-decoration: underline; +.primary_nav__sub_navlink:hover { + text-decoration: none; } .primary_nav__sub_navlist.-closed { @@ -162,7 +162,7 @@ body { } /* Malt bei vorhandenem Submenü den Pfeil */ -.primary_nav__navlist li a:first-child:nth-last-child(2):after { +.primary_nav__navlist li span:first-child:nth-last-child(2):after { content: ""; position: relative; top: -0.125rem; diff --git a/assets/js/nav_toggle.js b/assets/js/nav_toggle.js index 9242ba1..31d693d 100644 --- a/assets/js/nav_toggle.js +++ b/assets/js/nav_toggle.js @@ -10,7 +10,7 @@ document.getElementsByClassName('primary_nav__toggle')[0].addEventListener('clic let primary_menu_items = document.getElementsByClassName('primary_nav__navitem'); for (let i = 0; i < primary_menu_items.length; i++) { primary_menu_items[i].addEventListener('click', function(event) { - let dropdown = event.currentTarget.firstElementChild; + let dropdown = event.currentTarget.children[1]; if (dropdown.classList.contains('-closed')) { dropdown.classList.remove('-closed'); dropdown.classList.add('-open'); diff --git a/templates/blocks/navigation.html b/templates/blocks/navigation.html index 4ef61d9..3bc3de8 100644 --- a/templates/blocks/navigation.html +++ b/templates/blocks/navigation.html @@ -13,11 +13,11 @@ {% for title, mapping in bag("navigation").items() %} {% if mapping.visible|default(true) %}
  • - {{ title }} + {{ title }} {% if mapping.list_childs %}