From 685d831cb1919e9bc2169cd58a8400689d754419 Mon Sep 17 00:00:00 2001 From: Jeremy Ruston Date: Sun, 28 Jul 2024 14:20:37 +0100 Subject: [PATCH] Fix navigation vertical position when duration is zero Fixes #8428 --- core/modules/storyviews/classic.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/core/modules/storyviews/classic.js b/core/modules/storyviews/classic.js index 044cd97f0..a85e458c5 100644 --- a/core/modules/storyviews/classic.js +++ b/core/modules/storyviews/classic.js @@ -30,12 +30,8 @@ ClassicStoryView.prototype.navigateTo = function(historyInfo) { if(!targetElement || targetElement.nodeType === Node.TEXT_NODE) { return; } - if(duration) { - // Scroll the node into view - this.listWidget.dispatchEvent({type: "tm-scroll", target: targetElement}); - } else { - targetElement.scrollIntoView(); - } + // Scroll the node into view + this.listWidget.dispatchEvent({type: "tm-scroll", target: targetElement}); }; ClassicStoryView.prototype.insert = function(widget) {