You can add this to your xb_body template:

Code:
<script src="https://cdnjs.cloudflare.com/ajax/libs/headroom/0.12.0/headroom.min.js" integrity="sha512-9UsrKTYzS9smDm2E58MLs0ACtOki+UC4bBq4iK5wi7lJycwqcaiHxr1bdEsIVoK0l5STEzLUdYyDdFQ5OEjczw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<script>
var myElement = document.querySelector('.p-navSticky');
    
// construct an instance of Headroom, passing the element
var options = {
    // vertical offset in px before element is first unpinned
    offset : 800
};
var headroom = new Headroom(myElement, options);
// initialise
headroom.init();
</script>

And this to your extra.less:

Code:
.headroom {
    will-change: transform;
    transition: transform 200ms linear;
}
.headroom--pinned {
    transform: translateY(0%);
}
.headroom--unpinned {
    transform: translateY(-100%);
}

It'll add the headroom script on there.
 
Okay it works a dream! However, when I use the mobile bottom bar, it floats up when the top menu disappears.

(See photos)

Do you know if there’s a way to fix this?
 

Attachments

  • IMG_1661.png
    IMG_1661.png
    275 KB · Views: 14
  • IMG_1662.png
    IMG_1662.png
    296 KB · Views: 12

Pre-Sale Questions

If you have any questions or concerns you want to ask before you make a purchase don't hesitate to use one of our multiple support channels for your convenience.

Back