aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorMiodec <[email protected]>2023-03-06 15:52:38 +0100
committerMiodec <[email protected]>2023-03-06 15:52:38 +0100
commit8761b59d2f0aa7e497d14bec523ca0af6a3e0d87 (patch)
treed04fc8423e6d6ff9b1981e3e43f128f55f2b433e
parent85606bcb6c73acd3860c8b2025aff897f4aa58c9 (diff)
downloadmonkeytype-8761b59d2f0aa7e497d14bec523ca0af6a3e0d87.tar.gz
monkeytype-8761b59d2f0aa7e497d14bec523ca0af6a3e0d87.zip
fixed scroll to top button not working on all pages
-rw-r--r--frontend/src/ts/elements/scroll-to-top.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/frontend/src/ts/elements/scroll-to-top.ts b/frontend/src/ts/elements/scroll-to-top.ts
index fa3f7866d..795ec14a4 100644
--- a/frontend/src/ts/elements/scroll-to-top.ts
+++ b/frontend/src/ts/elements/scroll-to-top.ts
@@ -2,7 +2,7 @@ import * as ActivePage from "../states/active-page";
let visible = false;
-$(".scrollToTopButton").on("click", () => {
+$(document).on("click", ".scrollToTopButton", () => {
window.scrollTo({ top: 0, behavior: "smooth" });
});