Archived topic
submenu fixed
5 replies · Started by Sebastien on October 29, 2019
Hi,
At the moment I my submenus of services are hidden.
1) I would like these submenus alsways displayed under the sticky menu only when the current page is one of the submenu link pages.
2) the submenu is displayed vertically but I would like it horizontaly alligned under the main menu.
How can I do ?
thanks
Hi there,
Give this CSS a shot:
.dropdown-hover .main-navigation:not(.toggled) ul li[class*="current-menu-"] > ul {
left: auto;
opacity: 1;
transition-delay: 150ms;
pointer-events: auto;
height: auto;
overflow: visible;
}
body .sf-menu > li {
position: static;
}
body .main-navigation ul.menu > li > ul {
width: 100%;
left: 0 !important;
}
body .main-navigation ul.menu > li > ul > li {
width: auto;
}
body .main-navigation ul.menu > li > ul > li ul {
left: 0;
top: 100%;
}
Let me know :)
Hi Tom,
thanks you so much, it almost works perfectly.
But at the moment, the first line of this submenu is composed of 4 elements and the second line composed of 2 elements..
If each line could get 3 elements each or every elements onto the same line, that would suite better.
Thanks for your help !
Hi there,
in Tom's code, edit this:
body .main-navigation ul.menu>li>ul>li {
width: auto;
}
to:
body .main-navigation ul.menu>li>ul>li {
width: auto;
min-width: 33%;
}
Hello David,
Somehow the menu is not fixed even though using same css which was used before.
Thanks
Sorry, wrong window