scroll fixes

This commit is contained in:
2026-03-07 13:01:08 +11:00
parent 4064c9c557
commit 3b1eeaf12d
4 changed files with 49 additions and 121 deletions

View File

@@ -30,10 +30,10 @@ templ Footer() {
templ backToTopButton() {
<div class="absolute end-4 top-4 sm:end-6 lg:end-8">
<a
<button
class="inline-block rounded-full bg-teal p-2 text-crust
shadow-sm transition hover:bg-teal/75"
href="#main-content"
shadow-sm transition hover:bg-teal/75 hover:cursor-pointer"
onclick="document.getElementById('page-viewport').scrollTo({ top: 0, behavior: 'smooth' })"
>
<span class="sr-only">Back to top</span>
<svg
@@ -50,7 +50,7 @@ templ backToTopButton() {
clip-rule="evenodd"
></path>
</svg>
</a>
</button>
</div>
}