• Hello. The theme’s great. But I have a question about the submenu. As you can see in the picture, some menu items are wrapped. Can I change the width of the submenu? To make it fit the longest menu item?

    Image Submenu

Viewing 5 replies - 1 through 5 (of 5 total)
  • Theme Author Ben Sibley

    (@bensibley)

    Thanks for using Tracks!

    Please add this CSS to your site and let me know what you think:

    .menu-primary ul ul li {
      white-space: nowrap;
    }
    .menu-primary ul ul {
      max-width: none;
      left: -100%;
      right: -100%;
    }

    You can copy & paste the code above into the “Additional CSS” section in the Customizer (Appearance > Customize), and it will take effect right away.

    Thread Starter anti78

    (@anti78)

    Hello, Ben. Thanks for your answer. Unfortunately, it’s not really working yet.
    The first submenu is getting wider. But one entry is too wide. And the other submenus are way too wide.

    See pictures.

    Submenu 2

    Submenu 3

    • This reply was modified 4 years, 9 months ago by anti78.
    Theme Author Ben Sibley

    (@bensibley)

    Got it. Try swapping out the previous code for this CSS instead:

    .menu-primary ul ul li {
    	white-space: nowrap;
    }
    .menu-primary ul ul {
    	max-width: none;
    	width: auto;
    	left: 50%;
    	right: auto;
    	transform: translateX(-50%) !important;
    }
    Thread Starter anti78

    (@anti78)

    It’s working great. Thanks for your help.

    Theme Author Ben Sibley

    (@bensibley)

    Happy to help ??

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Submenu Width’ is closed to new replies.