Site logo

Archived topic

How to Adjust Spacing for Submenu

5 replies · Started by Tom on January 15, 2021

Viewing posts 1–6 of 6

Thanks Leo, seems to work (I changed from 10px to 20px).

Is the entire CSS code that David wrote there required to get this to work? Just don't want to put something that will cause a different issue later.

Code I'm using:

@media(min-width: 768px) {
.main-navigation .main-nav ul li.menu-item-has-children:before
{
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 80px; /* height of nav plus space below */
}
.main-navigation .main-nav ul ul {
margin-top: 20px;
}
}

Hi Tom,

If you are using Hover to open the submenu, you'll need the full CSS.

If you are not, then only this CSS is enough:

@media(min-width: 768px) {
    .main-navigation .main-nav ul ul {
        margin-top: 20px;
    }
}

Let me know :)

Gotcha, yes I am using Hover. Okay thanks!

No problem :)

This archived topic is closed to new replies.