diff options
author | tpart <tpart120@proton.me> | 2024-04-10 19:50:12 +0200 |
---|---|---|
committer | tpart <tpart120@proton.me> | 2024-04-10 19:50:12 +0200 |
commit | 18e23f2454cc6b3a75165eaafebe6c51bbe1f1d0 (patch) | |
tree | 9cedde4fe949101084b66ce6cb8807644580e802 | |
parent | 14530cbab85d1e95995b8965bd11ef38822fd20c (diff) | |
download | jellything-18e23f2454cc6b3a75165eaafebe6c51bbe1f1d0.tar jellything-18e23f2454cc6b3a75165eaafebe6c51bbe1f1d0.tar.bz2 jellything-18e23f2454cc6b3a75165eaafebe6c51bbe1f1d0.tar.zst |
Scroll to top of page when clicking item
-rw-r--r-- | web/script/transition.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/web/script/transition.ts b/web/script/transition.ts index 03338ca..26630ee 100644 --- a/web/script/transition.ts +++ b/web/script/transition.ts @@ -70,6 +70,7 @@ function prepare_load(href: string, back?: boolean) { document.head.innerHTML = head document.body.outerHTML = body globalThis.dispatchEvent(new Event("DOMContentLoaded")) + window.scrollTo({ top: 0 }); fade(true) } } |