Site logo

Archived topic

Background color of navgation submenu not working

21 replies · Started by Howard on September 15, 2022

Viewing posts 16–22 of 22

There's no Navigation "Block" in GeneratePress. The one you're using is WordPress' Navigation Block.

What Ying is suggesting is to disable the Block Element - Site Header, to use the default Navigation, and then add the Buttons through a Block Element - Hook instead.

Otherwise, the solution provided by David would be a good way to go about it.

Thanks for clarifying - I think I understand. I've gotten the Block Element - Hook to work for adding buttons to the nav menu, but it's incredibly confusing to have to add the Element as a "Block", then set that to "Hook" later, when there's a "Hook" property available when initially creating the Element.

I can't find anything in your documentation that explains the basic concepts of how your products work, and the precise terminology that you use, and how they relate to other jargon in the Wordpress world. This seems to be the norm in the industry, it's not a complaint about GP/GB, specifically. Wordpress itself is incredibly unintuitive, and all the changes now underway with Gutenberg, FSE, and all the related third party products make it exponentially worse.

(Sorry for the rant.)

Also, I must say I'm stunned that there seems to be no easy way to get control of menu and submenu styles and behaviors in the Gutenberg universe - even with other third party plugins, as far as I can tell (haven't looked too hard, though).

In any case, using the classes that David's reply showed, would it be possible for me to style the submenus a little better? For example, it would be nice to have a 1-pixel border between submenu items.

With the current structure you have in your Staging site, here's a CSS you may try:

div#primary-menu > ul > li > ul {
    border: solid 1px #ffffff;
}

If it helps, here is a doc showing how to create some Header designs in GeneratePress: https://docs.generatepress.com/article/header-examples/

I don't see a link to "a doc showing how to create some Header designs in GeneratePress".

But I'd like to!

Thanks!

Sorry about that. I didn't notice it wasn't pasted. I edited my response above.

Thanks for the CSS tip, it's helpful.

-H

You're welcome Howard!

This archived topic is closed to new replies.