Site logo

Archived topic

Adaptting primary subnavigation block width to subitems width

5 replies · Started by Mildmac SA (ESA78960895) on July 30, 2017

Viewing posts 1–6 of 6

Hi,
i added this CSS to increase primary subnavigation block width, but in a fixed way (to, let´s say, 340px)

.main-navigation ul ul {
width: 340px;
padding-top: 0px;
}

But the subitems width is different in each main menu item. How can I adapt the block width to the maximum text subitem width?

Thanks Leo, but doesn´t work, because with 100% it inherits the parent item width, but from main menu. I want to adapt the width of the dropdown block to the width of the longest subitem in that block. I send you a capture to show:
http://sibcont.com/wp-content/uploads/2017/07/capture.jpg
I don´t know if it is possible...
Thanks
Rafael

Great!!!! That´s it!!! Thanks a lot Tom

You're welcome :)

This archived topic is closed to new replies.