增加空白判断

This commit is contained in:
aixianling
2024-06-17 16:35:09 +08:00
parent 8c9db36978
commit fccdcf735f

View File

@@ -48,6 +48,7 @@ export default {
}
},
handleSend() {
if (!this.prompt.trim()) return this.$message.error("无法发送空白信息,请输入资讯的内容")
const concatenateStr = (content, i = 0) => {
this.history.at(-1).content += content.slice(i, i + 1)
if (++i < content.length) setTimeout(() => concatenateStr(content, i), 50)