Back to feed

Go to top Butten

AllanD · 1 year ago · 2 replies · 472

Was just scrolling around and realized there isn't a go to top button or a bottom breadcrumb. Just a thought.

2 replies
Cedric · 1 year ago

We don't have this indeed.

If you want to have one, that is easily achieved with a code that you can add in the "Below the Board" template:

<style>
        #goTopBtn {
            position: fixed;
            bottom: 20px;
            right: 20px;
            display: none;
            background: #1a152c;
            color: white;
            border: none;
            border-radius: 5px;
            padding: 10px;
            font-size: 18px;
            cursor: pointer;
        }
    </style>
    <button id="goTopBtn" onclick="window.scrollTo({ top: 0, behavior: 'smooth' });">Top</button>

<script>
    const goTopBtn = document.getElementById('goTopBtn');
    window.addEventListener('scroll', () => {
        goTopBtn.style.display = window.scrollY > 200 ? 'block' : 'none';
    });
</script>

That said, we can probably implement this soon.

AllanD OP · 1 year ago

Thank you will be using that.

Create a free account to join the conversation.
Sign up free
ForumSpark © 2023 - 2026 · ForumSpark.net · Terms