Jump to content

Sticky Category Links for Video Collections code not working with category titles on top

Recommended Posts

In following Becca's tutorial I did a test on my site.  I removed all css code on my site and just pasted the below one at a time to make sure no other code was interfering.

The Sidebar Category titles does not scroll when user scrolls with the first css code provided it stays on the side.  Great.

.lessons .nested-category-tree-wrapper {
position:sticky;
top:1rem
}

But, if I choose to have the sidebar category on the top, the below css code provided does not work. Not sure if the category-children needs another name but the first one works perfectly.  Not sure if this needs a section{data-section-id] to target it but i'm not sure how to tweak this.  I did ignore the background as it wasn't relevant. Can any one provide some insight.  Thanks in advance.

 

.lessons .nested-category-children{

position:sticky!important;

top:0;

z-index:99!important;

background:#FFF!important

}

2024-03-06_20-03-18.png

Link to comment
  • Replies 3
  • Views 1.4k
  • Created
  • Last Reply

Top Posters In This Topic

Posted (edited)

Anyone.  I've now tried to target

section[data-section-id="65dd51a68e3d9b0a3e68567a"] {
.lessons-list .nested-category-children{
position: sticky!important;
top:0;
z-index:9999!important;
 background:#8EB6DC!important
  }
}
and though the background works the titles still don't stick.

I must not have the name of the category right or the list may be named something else that I am not aware of.

Edited by MoeCritiques
added information
Link to comment
  • 3 weeks later...

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.