Forced Submenu Padding When Adding Submenu Background Color
-
I’m having a mysterious issue with submenu padding. In short, if I set a background color for the nav block’s submenu, it also adds a lot of left/right padding which I didn’t set or ask for. I assume that what WP is doing is creating default properties for has-background once it’s demanded by act of my selecting a submenu BG color. The nav block is in my header. I am using WP’s Twenty Twenty-Two theme.
The reason I call this issue mysterious, is because this large padding increase only takes effect on certain pages, or perhaps certain page templates. Any page with the “Project” or “Guide” page templates I created seem to have the increased padding issue, as well as news posts. However, a third template I created doesn’t result in the padding issue – and it’s not on the default page template either. If you check the submenu in the last two links, it will appear as I’m intending. I have to believe that something I set in the Project and Guide templates is causing this, but I don’t understand how a page template would be allowed to manipulate a separate template part (the header) where my nav block resides.
I have attempted multiple additional-CSS solutions from similar posts to no avail thus far. Ultimately, it would be great if submenu padding/margin options were added to submenu blocks, but since those aren’t selectable parameters I’m seeking the community’s guidance. Thanks in advance.
The page I need help with: [log in to see the link]
- The topic ‘Forced Submenu Padding When Adding Submenu Background Color’ is closed to new replies.