How can I allign header items in one row in Shopify?

Solved

How can I allign header items in one row in Shopify?

repharma
Tourist
8 0 1

Hello everybody.

I have added a header in shopify but unfortunetly in spans across two rows. First row is the icon, the second row is the menu and the cart. 
How can I make this on one line on both mobile and desktop?
And also, how can I get rid of the "Menu" label/span on the mobile view?

https://repharma.bg/products/joint-cure

I would really appreciate any suggestions since programming isn't my strongest skill.
Thank you!

P.S I am using BOOM theme. 

repharma_0-1725988855557.png

 

Accepted Solution (1)

Made4uo-Ribe
Shopify Partner
8250 1978 2426

This is an accepted solution.

Hi @repharma 

Check this one. 

From your Shopify admin dashboard, click on "Online Store" and then "Themes"

Find the theme that you want to edit and click on "Actions" and then "Edit code".

In the "theme. Liquid" file. Find the </body> tag and paste the code below before the tag. 

 

<style>
@media only screen and (max-width: 767px) {
header #AccessibleNav {
        display: grid;
        grid-template-columns: 1fr 1fr 0.5fr;
 }
.mobile-nav-container.mobile-nav-offcanvas-right.dt-header-menu {
    grid-column: 3;
    grid-row: 1;
    width: fit-content;
}
.site-header__links.dt-sc-flex {
    grid-column: 3;
    grid-row: 1;
    width: 50%;
    justify-self: end;
}
.logo {
    grid-column: 2;
    grid-row: 1;
}
}
</style>

 

And Save. 

Result:

Made4uoRibe_0-1725995269983.png

 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free.
Need THEME UPDATES but has custom codes? No worries, contact us for affordable price.

View solution in original post

Replies 6 (6)

BSSCommerce-B2B
Shopify Partner
1723 513 577

@repharma,

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid

 

<style>
@media only screen and (max-width: 767px) {
  header .logo-alignment:not(.secondary-menu-enabled) #AccessibleNav {
    display: flex!important;
  }
  .mobile-nav-container .menu-trigger span {
    display: none!important
  }
  #header .row {
    margin: 0!important;
  }
  #AccessibleNav .logo {
    margin-right: 40%!important;
  }
}
</style>

Result:

BSSCommerceB2B_0-1725989757232.png

 

 

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

repharma
Tourist
8 0 1

Thanks for the quick answer.

I added it, but still nothing 😕 

repharma_0-1725990041715.png

 

BSSCommerce-B2B
Shopify Partner
1723 513 577

did you save it yet?

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

repharma
Tourist
8 0 1

Yes

BSSCommerce-B2B
Shopify Partner
1723 513 577

I don't see it appearing on your site. Are you sure you've saved it?

BSSCommerceB2B_0-1725990418851.png

If it still not work try to add that before </html>

 

B2B Wholesale Solution: Streamline your B2B operation with advanced features like wholesale registration forms, custom pricing.


B2B Portal, Quote, Net 30: Speed up purchasing and streamline your quotation process with advanced features like quick order, request for quote.


B2B Lock Password Protect: Easily control access to pages, products, and pricing with robust features.


BSS Commerce - Full-service eCommerce Agency I Use Shopify for 1$ in the first month now

Made4uo-Ribe
Shopify Partner
8250 1978 2426

This is an accepted solution.

Hi @repharma 

Check this one. 

From your Shopify admin dashboard, click on "Online Store" and then "Themes"

Find the theme that you want to edit and click on "Actions" and then "Edit code".

In the "theme. Liquid" file. Find the </body> tag and paste the code below before the tag. 

 

<style>
@media only screen and (max-width: 767px) {
header #AccessibleNav {
        display: grid;
        grid-template-columns: 1fr 1fr 0.5fr;
 }
.mobile-nav-container.mobile-nav-offcanvas-right.dt-header-menu {
    grid-column: 3;
    grid-row: 1;
    width: fit-content;
}
.site-header__links.dt-sc-flex {
    grid-column: 3;
    grid-row: 1;
    width: 50%;
    justify-self: end;
}
.logo {
    grid-column: 2;
    grid-row: 1;
}
}
</style>

 

And Save. 

Result:

Made4uoRibe_0-1725995269983.png

 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free.
Need THEME UPDATES but has custom codes? No worries, contact us for affordable price.