diff --git a/src/components/ConversationView.vue b/src/components/ConversationView.vue index c2ac51e..e02ceaa 100644 --- a/src/components/ConversationView.vue +++ b/src/components/ConversationView.vue @@ -4,7 +4,7 @@ import { Plus, Search, Trash2, Send, User, Type, ChevronDown, Check, MessageSquare, Loader2, Copy, X, Sparkles, Languages, Venus, Mars, CircleSlash, - ShieldCheck + ShieldCheck, RotateCcw } from 'lucide-vue-next'; import { useSettingsStore, @@ -218,7 +218,7 @@ const translateMessage = async (sender: 'me' | 'partner') => { } }; -const evaluateMessage = async (messageId: string) => { +const evaluateMessage = async (messageId: string, force = false) => { if (!activeSession.value) return; const msg = activeSession.value.messages.find(m => m.id === messageId); if (!msg) return; @@ -229,9 +229,9 @@ const evaluateMessage = async (messageId: string) => { await nextTick(); isAuditModalOpen.value = true; - if (msg.evaluation || msg.isEvaluating) return; + if (!force && (msg.evaluation || msg.isEvaluating)) return; - settings.updateChatMessage(activeSession.value.id, messageId, { isEvaluating: true }); + settings.updateChatMessage(activeSession.value.id, messageId, { isEvaluating: true, evaluation: undefined }); const historyLimit = 10; const recentMessages = activeSession.value.messages.filter(m => m.id !== messageId).slice(-historyLimit); @@ -953,6 +953,15 @@ onUnmounted(() => window.removeEventListener('click', handleGlobalClick));