refac
This commit is contained in:
@@ -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} />
|
||||||
|
|
||||||
|
|||||||
@@ -594,8 +594,8 @@
|
|||||||
}}
|
}}
|
||||||
onDelete={(id) => {
|
onDelete={(id) => {
|
||||||
if ($chatId === id) {
|
if ($chatId === id) {
|
||||||
|
goto('/');
|
||||||
chatId.set('');
|
chatId.set('');
|
||||||
window.history.replaceState({}, '', '/');
|
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user