Template
1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo synced 2024-11-25 11:16:11 +01:00

Merge pull request 'fix: reset history.scrollRestoration if set to manual and no issue anchor in url' (#5684) from viceice/fix/ui/scroll-restoration into forgejo

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/5684
Reviewed-by: Otto <otto@codeberg.org>
This commit is contained in:
Otto 2024-10-31 02:35:15 +00:00
commit 30838da15e

View file

@ -481,6 +481,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) { $(document).on('click', '.show-outdated', function (e) {