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:
Marcos Paulo
2026-09-05 17:09:40 +00:00
parent 71e4775573
commit 3fdfbe3ae9
+1 -1
View File
@@ -278,7 +278,7 @@ function syncUrl() {
else url.searchParams.delete('render'); else url.searchParams.delete('render');
if (state.diff) url.searchParams.set('compare', 'diff'); if (state.diff) url.searchParams.set('compare', 'diff');
else url.searchParams.delete('compare'); else url.searchParams.delete('compare');
history.pushState({}, '', url); history.replaceState({}, '', url);
} }
function selectFromUrl() { function selectFromUrl() {
const params = new URLSearchParams(window.location.search); const params = new URLSearchParams(window.location.search);