From 59b23586bc5e5e62b644e719d0209ab1bc5ba719 Mon Sep 17 00:00:00 2001 From: code002lover Date: Fri, 5 Dec 2025 15:15:19 +0100 Subject: [PATCH] feat: Enhance existing games anchor scrolling with a delay and add heading scroll margin. --- frontend/src/GameList.tsx | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/frontend/src/GameList.tsx b/frontend/src/GameList.tsx index 3121ac7..5ff1cff 100644 --- a/frontend/src/GameList.tsx +++ b/frontend/src/GameList.tsx @@ -60,7 +60,11 @@ export function GameList() { if (location.hash === "#existing-games") { const el = document.getElementById("existing-games"); if (el) { - el.scrollIntoView({ behavior: "smooth", block: "start" }); + setTimeout(() => { + el.scrollIntoView({ behavior: "smooth", block: "start" }); + }, 100); + } else { + console.error("Element not found"); } } }, [location]); @@ -466,7 +470,14 @@ export function GameList() {
-

Existing Games

+

+ Existing Games +