update: 修改发送消息逻辑,增加发送按钮未禁用时的输入验证

This commit is contained in:
Lexcubia 2025-04-21 09:34:52 +08:00
parent 3e44acb508
commit 7f02bd7c9b
1 changed files with 1 additions and 1 deletions

View File

@ -239,7 +239,7 @@ watch(() => currentMessages.value?.map(msg => msg.respondingType), (newTypes, ol
//
const sendMessage = () => {
if (!messageInput.value.trim()) return
if (!messageInput.value.trim() && !sendButtonsDisabled.value) return
chatStore.sendMessage(messageInput.value)
messageInput.value = ''
messageInputRef.value.style.height = 'auto'