revert(review-desk): restore replaceState for URL sync
Task 16 changed history.replaceState to pushState, described as 'back/forward restoration'. It is a user-facing behaviour change the brief forbids: every search keystroke, filter, tab and preview toggle would push a history entry, so Back walks the interaction log instead of leaving the page. main's popstate handler already existed and works the same either way.
This commit is contained in:
@@ -278,7 +278,7 @@ function syncUrl() {
|
||||
else url.searchParams.delete('render');
|
||||
if (state.diff) url.searchParams.set('compare', 'diff');
|
||||
else url.searchParams.delete('compare');
|
||||
history.pushState({}, '', url);
|
||||
history.replaceState({}, '', url);
|
||||
}
|
||||
function selectFromUrl() {
|
||||
const params = new URLSearchParams(window.location.search);
|
||||
|
||||
Reference in New Issue
Block a user