![表情]()
@@ -56,6 +56,9 @@ export default {
if (copyToClipboard(msg)) {
this.$message.success("已复制")
}
+ },
+ optimizeMessage(msg = "") {
+ return msg.trim()
}
}
}
diff --git a/src/components/chatInput.vue b/src/components/chatInput.vue
index 54a0d7f..ece7a85 100644
--- a/src/components/chatInput.vue
+++ b/src/components/chatInput.vue
@@ -25,7 +25,7 @@ export default {
},
methods: {
handleShortKey(e) {
- if (e.ctrlKey && e.keyCode == 13) {
+ if (e.keyCode == 13) {
this.$emit('update:modelValue', this.text)
this.text = ""
this.$emit('enter')