smoothscroll styling


Topic: smoothscroll styling

Castillo pro asked 6 years ago

I want to highlight the current position in my smoothscroll and when I scroll the page manually the smoothscroll change the current position itself. I was trying to use a:active but does't work. I appreciate any help. thank you

// Smooth Scroll
#smooth-scroll {
    position: fixed;
}
#smooth-scroll ul { // work
    list-style-type: none;
}
#smooth-scroll a { //work
    color: navy;
    font-size: 1rem;
}
#smooth-scroll a:hover { //work
    font-weight: bold;
}
#smooth-scroll a:active{ // does'n persist
    color: red;
}
<div id="smooth-scroll">
    <ul>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#intro">Intro</a></h5></li>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#history">History</a></h5></li>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#geography">Geography</a></h5></li>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#climate">Climate</a></h5></li>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#recreation">Recreation</a></h5></li>
        <li><h5><a mdbPageScroll [pageScrollOffset]="112"href="#jurisdiction">Legal jurisdiction</a></h5></li>
    </ul>
</div>

Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Open

Specification of the issue
  • User: Pro
  • Premium support: No
  • Technology: MDB Angular
  • MDB Version: -
  • Device: -
  • Browser: -
  • OS: -
  • Provided sample code: No
  • Provided link: No