Use history replace when toggling chat diff view

- Add `replace: true` to thread navigation in `ChatView`
- Prevents extra browser history entries when opening/closing diff mode
This commit is contained in:
Julius Marminge committed 2026-02-26 18:52:49 -08:00
1 parent 9b458ef115
commit 2d47508c2c
1 file changed
+1
+1
View File
@@ -623,6 +623,7 @@ export default function ChatView({ threadId }: ChatViewProps) {
void navigate({
to: "/$threadId",
params: { threadId },
replace: true,
search: (previous) => {
const rest = stripDiffSearchParams(previous);
return diffOpen ? rest : { ...rest, diff: "1" };