Jump to content

Navigation bar appearing over 2 lines on desktop.

Go to solution Solved by creedon,

Recommended Posts

Hello,

 

I'm having trouble getting the navigation bar on this website to appear correctly. On desktop the the navigation bar is running over 2 lines. I used the below code from another thread which resolved the issue on desktop but causes a problem with the mobile layout. Any advice on how to get this working well on desktop and mobile would be greatly appreciated.

Website password is: crawford

 

.header-title-nav-wrapper {
  flex: 1 0 80% !important;
  flex-wrap: nowrap !important;
}
.header-nav {
  width: 100% !important;
  flex: 1 1 100% !important;
}
Link to comment
  • Solution

You just need to restrict the ruleset to the desktop version of the navigation.

// uses LESS syntax

.header-display-desktop {

  .header-title-nav-wrapper {
  
    flex : 1 0 80%;
    flex-wrap : nowrap;
    
    }
    
  .header-nav {
  
    flex : 1 1 100%;
    width : 100%;
    
    }
    
  }

This is for v7.1.

Let us know how it goes.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment
  • 7 months later...

Having nav on one line and ensuring it is still centred!

Hi I am building a client site and have been searching through forums for codes to stop the nav from going onto a second line. However, When I entered the below code it worked. But did not center everything. Please note that all forums are only showing websites where the logo on the left. My logo sits in the centre as well as the navigation.

nav.header-nav-list {
    flex-wrap: nowrap;
}

 

Here is the site: https://spiralockstemp.squarespace.com/

 

Thank you!

Link to comment
On 5/9/2024 at 9:00 AM, AmandaJanedesigner said:

Having nav on one line and ensuring it is still centred!

Hi I am building a client site and have been searching through forums for codes to stop the nav from going onto a second line. However, When I entered the below code it worked. But did not center everything. Please note that all forums are only showing websites where the logo on the left. My logo sits in the centre as well as the navigation.

nav.header-nav-list {
    flex-wrap: nowrap;
}

 

Here is the site: https://spiralockstemp.squarespace.com/

 

Thank you!

The site is private. You can follow this to share site url.

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.