From ea887ad7554cfc90ff981d77ed504774440b738a Mon Sep 17 00:00:00 2001 From: Void Date: Sat, 18 Feb 2023 09:56:13 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BE=93=E5=85=A5=E6=A1=86=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E5=AF=8C=E6=96=87=E6=9C=AC,=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E6=8D=A2=E8=A1=8C=20(#53)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add Dockerfile * update Readme.md * Fixed : Docker log file * Update vite.config.ts * chore: code merge, update README.md * chore: update GitHub workflow * fix: 输入框修改为富文本,支持换行 * chore: 更新.gitignore * Update index.vue --------- Co-authored-by: Redon <790348264@qq.com> --- src/components/business/Chat/index.vue | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/components/business/Chat/index.vue b/src/components/business/Chat/index.vue index 98fe80c..69b80c9 100644 --- a/src/components/business/Chat/index.vue +++ b/src/components/business/Chat/index.vue @@ -78,8 +78,10 @@ async function handleSubmit() { } function handleEnter(event: KeyboardEvent) { - if (event.key === 'Enter') + if (event.key === 'Enter' && !event.shiftKey) { + event.preventDefault() handleSubmit() + } } function addMessage( @@ -189,7 +191,9 @@ watch(