From 7306d0c3a4f7d7302a5a7bbcccc3f25489139ec6 Mon Sep 17 00:00:00 2001 From: Cameron Clough Date: Thu, 23 Jan 2025 01:19:29 +0000 Subject: [PATCH] fix(timeline): prevent page scroll while dragging --- src/components/Timeline.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/Timeline.tsx b/src/components/Timeline.tsx index f79dc317..04079ead 100644 --- a/src/components/Timeline.tsx +++ b/src/components/Timeline.tsx @@ -104,7 +104,7 @@ const Timeline: VoidComponent = (props) => { const [events] = createResource(route, getTimelineEvents) // TODO: align to first camera frame event const [markerOffsetPct, setMarkerOffsetPct] = createSignal(0) - const duration = createMemo(() => + const duration = createMemo(() => route() ? getRouteDuration(route()!)?.asSeconds() ?? 0 : 0, @@ -157,7 +157,7 @@ const Timeline: VoidComponent = (props) => {