mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-25 12:44:39 +02:00
♻️ refactor(chat): simplify chat service and update seed data
- Remove unused code from chat.service.ts - Simplify seed.ts with fewer AI models - Update CLAUDE.md documentation - Update .env.example - Remove unused package dependency - Minor UI fix in chat page
This commit is contained in:
parent
0fa154c7d6
commit
3f9bc5761b
6 changed files with 75 additions and 393 deletions
|
|
@ -28,15 +28,17 @@
|
|||
let showVersionsModal = $state(false);
|
||||
let showDocumentPanel = $state(true);
|
||||
|
||||
// Track current request to prevent race conditions
|
||||
let currentLoadId = $state(0);
|
||||
// Track current request to prevent race conditions (not reactive to avoid effect loops)
|
||||
let currentLoadId = 0;
|
||||
let lastLoadedConversationId = '';
|
||||
|
||||
const conversationId = $derived($page.params.id ?? '');
|
||||
const isDocumentMode = $derived(conversation?.documentMode ?? false);
|
||||
|
||||
// React to conversationId changes with race condition protection
|
||||
$effect(() => {
|
||||
if (conversationId) {
|
||||
if (conversationId && conversationId !== lastLoadedConversationId) {
|
||||
lastLoadedConversationId = conversationId;
|
||||
loadData(conversationId);
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue