This commit is contained in:
Timothy Jaeryang Baek
2026-03-25 02:20:33 -05:00
parent debcc3a652
commit 08ff3bd30f
2 changed files with 8 additions and 2 deletions
@@ -3,6 +3,7 @@
const { saveAs } = fileSaver; const { saveAs } = fileSaver;
import { import {
chatId,
chats, chats,
user, user,
settings, settings,
@@ -139,7 +140,12 @@
}; };
</script> </script>
<ArchivedChatsModal bind:show={showArchivedChatsModal} onUpdate={handleArchivedChatsChange} /> <ArchivedChatsModal bind:show={showArchivedChatsModal} onUpdate={handleArchivedChatsChange} onDelete={(id) => {
if ($chatId === id) {
goto('/');
chatId.set('');
}
}} />
<SharedChatsModal bind:show={showSharedChatsModal} /> <SharedChatsModal bind:show={showSharedChatsModal} />
<FilesModal bind:show={showFilesModal} /> <FilesModal bind:show={showFilesModal} />
+1 -1
View File
@@ -594,8 +594,8 @@
}} }}
onDelete={(id) => { onDelete={(id) => {
if ($chatId === id) { if ($chatId === id) {
goto('/');
chatId.set(''); chatId.set('');
window.history.replaceState({}, '', '/');
} }
}} }}
/> />