From 23f5709c680de258b6bf63858cf288b180b63854 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20T=C3=A4kker?= Date: Fri, 25 Sep 2026 21:53:34 +0200 Subject: [PATCH] Fixed synced lyrics manual scrolling --- app/components/Player/Fullscreen/LyricsDisplay.vue | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/app/components/Player/Fullscreen/LyricsDisplay.vue b/app/components/Player/Fullscreen/LyricsDisplay.vue index b9440c3..aabff2c 100644 --- a/app/components/Player/Fullscreen/LyricsDisplay.vue +++ b/app/components/Player/Fullscreen/LyricsDisplay.vue @@ -98,6 +98,10 @@ let scrollingTimeout: any = null const onWheel = (event: WheelEvent) => { if (!containerRef.value || !outerRef.value) return + if (!isScrolling.value) { + manualOffset.value = transformY.value + offset + } + isScrolling.value = true clearTimeout(scrollingTimeout) @@ -121,6 +125,12 @@ const onWheel = (event: WheelEvent) => { scrollingTimeout = setTimeout(() => (isScrolling.value = false), 3000) } +const onLyricClick = (time: number) => { + clearTimeout(scrollingTimeout) + isScrolling.value = false + secondsPlayed.value = time +} + const finalTransform = computed(() => { if (isScrolling.value) return manualOffset.value @@ -152,7 +162,7 @@ const finalTransform = computed(() => { :key="lyric.time" :class="{ active: i == scrollActiveIndex }" ref="lyrics" - @click="() => (secondsPlayed = lyric.time)" + @click="onLyricClick(lyric.time)" > {{ lyric.text }}