How to make a multi-column drop down menu for one section in Dawn theme?

Solved

How to make a multi-column drop down menu for one section in Dawn theme?

joedogfish
Explorer
66 0 12

Hi there,

 

I'm trying to refine this snippet of code that's at the component-list-menu.css from another thread. The coding works great however I only need 1 section of my nav bar 'BRANDS' to be a multi-column drop down and the rest to be as normal.

 

Preview link is https://xi2c77tf8ip94lhr-36045684869.shopifypreview.com

Coding used is :

 

 

@media only screen and (min-width: 750px){
	.header__submenu.list-menu{
		width: 60rem !important;
	}
	.header__submenu.list-menu li {
		width: calc(100%/3);
		display: inline-block;
	}
}

 

 

Screenshot below is example of the only multi-column drop down I need in the nav baronly multi-column drop down neededonly multi-column drop down needed

Thanks!

Accepted Solution (1)

SheetalZadfiya
Explorer
70 15 19

This is an accepted solution.

Hi @joedogfish 

 

I understood your concern and realised that you achieve it using the below code. Those CSS applied all sub menus except the brand's sub menu. I believe this can help you to resolve the issue.

 

Please add below code:

 

 

@media only screen and (min-width: 750px){
	.header__submenu.list-menu{
		width: 60rem !important;
	}
	.header__submenu.list-menu li {
		width: calc(100%/3);
		display: inline-block;
	}
	.header__submenu:not(ul#HeaderMenu-MenuList-4) {
        width: 20rem !important;
    }
    .header__submenu li:not(ul#HeaderMenu-MenuList-4 li) {
        width: 100% !important;
    }
}

 

 

Happy Coding!!

If our answer is helpful then please feel free to Like and Accept it as solution!
Hire our Shopify Developers for all your small & big needs:
New Store Development | Custom Theme Development | Site Speed Optimization
Email: [email protected] | Instagram: @mintyourstore

View solution in original post

Replies 3 (3)

SheetalZadfiya
Explorer
70 15 19

This is an accepted solution.

Hi @joedogfish 

 

I understood your concern and realised that you achieve it using the below code. Those CSS applied all sub menus except the brand's sub menu. I believe this can help you to resolve the issue.

 

Please add below code:

 

 

@media only screen and (min-width: 750px){
	.header__submenu.list-menu{
		width: 60rem !important;
	}
	.header__submenu.list-menu li {
		width: calc(100%/3);
		display: inline-block;
	}
	.header__submenu:not(ul#HeaderMenu-MenuList-4) {
        width: 20rem !important;
    }
    .header__submenu li:not(ul#HeaderMenu-MenuList-4 li) {
        width: 100% !important;
    }
}

 

 

Happy Coding!!

If our answer is helpful then please feel free to Like and Accept it as solution!
Hire our Shopify Developers for all your small & big needs:
New Store Development | Custom Theme Development | Site Speed Optimization
Email: [email protected] | Instagram: @mintyourstore
joedogfish
Explorer
66 0 12

Thank you so much!! liked and accepted as solution!

MattBailey
Tourist
10 0 1

Where do I add the above code to make my brand menu multi-column? Below is an example of what I am aiming to do. Thank you

 

Screenshot 2024-09-24 at 4.03.06 pm.png