1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-12-21 12:44:49 -05:00

fix: reset history.scrollRestoration if set to manual and no issue anchor in url

(cherry picked from commit ec4a0e1b6e)
This commit is contained in:
Michael Kriese 2024-10-24 15:13:58 +02:00 committed by forgejo-backport-action
parent 1dc03cc1c3
commit 8e4536fd98

View file

@ -478,6 +478,9 @@ export function initRepoPullRequestReview() {
});
}
}
} else if (window.history.scrollRestoration === 'manual') {
// reset scrollRestoration to 'auto' if there is no hash in url and we set it to 'manual' before
window.history.scrollRestoration = 'auto';
}
$(document).on('click', '.show-outdated', function (e) {