Site logo

Archived topic

Make menu items the same width

5 replies · Started by xdaniel on November 16, 2018

Viewing posts 1–6 of 6

Hello GPs,

is there a way to make the menu items in primary navigation (on desktop) the same width?

Best, Daniel

Hi there,

there are ways to do it but fixing their size can cause issues on smaller screen sizes.
Can you provide access to the site so i can see if theres a good solution?

Hello David,
You can access, typing "MitMirNicht".
Best, Daniel

Not perfect but try this CSS:

.main-navigation li {
	min-width: 15%;
}
.main-navigation li.search-item {
    min-width: 5% !important;    
    max-width: 60px !important; 
    max-height: 41px; 
    overflow: hidden; 
    float: none;
}

Problem being is the Leichte Sprache menu item is alreadywider than 15% - increasing the min width will force the search icon to a new row.

The other issue is when on smaller screens the menu items will wrap to a new line, so you may need to break to mobile earlier.

Thanks a lot David.

This really helped me! Five stars :-)

Glad i could be of help.

This archived topic is closed to new replies.