From e4baedee097e1a8dc63fa0a1115f9f974ccdac66 Mon Sep 17 00:00:00 2001 From: Miodec Date: Tue, 4 Mar 2025 19:15:27 +0100 Subject: [PATCH] fix(leaderboards): bottom go to page button not working --- frontend/src/ts/event-handlers/leaderboards.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/frontend/src/ts/event-handlers/leaderboards.ts b/frontend/src/ts/event-handlers/leaderboards.ts index 5e0fe4caa12a..9faa3a20ef96 100644 --- a/frontend/src/ts/event-handlers/leaderboards.ts +++ b/frontend/src/ts/event-handlers/leaderboards.ts @@ -2,8 +2,10 @@ import { showPopup } from "../modals/simple-modals"; const lb = document.getElementById("pageLeaderboards"); -lb?.querySelector( +for (const button of lb?.querySelectorAll( ".jumpButtons button[data-action='goToPage']" -)?.addEventListener("click", () => { - showPopup("lbGoToPage"); -}); +) ?? []) { + button?.addEventListener("click", () => { + showPopup("lbGoToPage"); + }); +}