Jump to content

Custom NavBar Line Using an Icon

Recommended Posts

Posted

I want to add a custom "line" under the navbar page. In stead if a basic line when you are on each page, I'dd like to replace it with an icon. See attached. I figured out how to add an icon to the side oof each link, but not underneath when you click on the page.

Site isn't live yet.

Screen Shot 2022-06-02 at 8.21.33 AM.png

  • Replies 6
  • Views 358
  • Created
  • Last Reply

Top Posters In This Topic

Posted
On 6/3/2022 at 10:08 PM, NICOLELEIGH9 said:

Try adding to Design > Custom CSS. Replace with new image url

div.header-nav-item--active>a:after {
    content: "";
    background-image: url(https://cdn.pixabay.com/photo/2022/03/08/07/08/water-7055153__480.jpg);
    background-size: cover;
    width: 100%;
    height: 5px;
    display: block;
}

 

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!)

Posted
On 6/10/2022 at 12:15 AM, tuanphan said:

Try adding to Design > Custom CSS. Replace with new image url

div.header-nav-item--active>a:after {
    content: "";
    background-image: url(https://cdn.pixabay.com/photo/2022/03/08/07/08/water-7055153__480.jpg);
    background-size: cover;
    width: 100%;
    height: 5px;
    display: block;
}

 

Thank you! The original solid line also shows up with the image548776920_ScreenShot2022-06-13at10_19_39AM.thumb.png.fd16445796fb13d95927b17e10726a56.png. Is there a way to replace that single line with only the image? See what appears when I added your code.

Posted
15 hours ago, NICOLELEIGH9 said:

Thank you! The original solid line also shows up with the image548776920_ScreenShot2022-06-13at10_19_39AM.thumb.png.fd16445796fb13d95927b17e10726a56.png. Is there a way to replace that single line with only the image? See what appears when I added your code.

Add this code under

.header-nav-item a {
    background-image: none !important;
}

 

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!)

Posted
On 6/10/2022 at 12:15 AM, tuanphan said:

Try adding to Design > Custom CSS. Replace with new image url

div.header-nav-item--active>a:after {
    content: "";
    background-image: url(https://cdn.pixabay.com/photo/2022/03/08/07/08/water-7055153__480.jpg);
    background-size: cover;
    width: 100%;
    height: 5px;
    display: block;
}

 

Fantastic, thank you!

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.