Jump to content

Targeting the last external link in navigation?

Go to solution Solved by Ziggy,

Recommended Posts

I've finally figured out how to make external links in my navigation become italic. But now I'd like to figure out how to only target the last external link (maybe using "child"? new to css haha) 

Here is the code I have working now:

.header-nav-item--external a {
    font-style: italic;
  }

Any ideas on what to add to make it so only the word "STUDIO" is italic in my nav?
Site is forhomeandharvest.com

Thanks for any help!!!

Link to comment
  • Solution

This would work, but be wary of adding or removing navigation items.

.header-nav-item:nth-child(4) {
  font-style:italic;
  font-weight:900;
}
  

Hope that helps!

Please like and upvote if my comments were helpful to you. Cheers!

Zygmunt Spray
Squarespace Website Designer
Contact me: 
https://squarefortytwo.com 
Hire me on Upwork!

🔌 Ghost Squarespace Plugins (Referral link)
📈 SEO Space (Referral link)
 SquareWebsites Plugins (Referral link)
 🔲 SQSP Themes (Referral link) 
Spark Plugin (Referral link) 

 Did I help? Buy me a coffee?

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.