From 512d5822976e612e88d492a8fc3b9e48d83f4d08 Mon Sep 17 00:00:00 2001 From: pwh-pwh Date: Mon, 29 Jul 2024 20:45:42 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0/quit=E5=87=BD=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/Chat.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/frontend/src/components/Chat.vue b/frontend/src/components/Chat.vue index aa01421..fe51b82 100644 --- a/frontend/src/components/Chat.vue +++ b/frontend/src/components/Chat.vue @@ -10,7 +10,8 @@ import Message = types.Message; const inputMsg = ref('') -const helpMsg = ref('/help: 显示帮助信息\n/clear: 清除历史信息\n/loadconf: 重新加载配置文件\n/opconf: 打开配置文件夹') +const helpMsg = ref('/help: 显示帮助信息\n/clear: 清除历史信息\n/loadconf: 重新加载配置文件\n/opconf: 打开配置文件夹\n' + + '/quit: 退出应用') const msgList = reactive([{content: '欢迎使用Ai-Gui,用法介绍如下', userType: 'user', id: 'tool'}, {content: helpMsg.value, userType: 'assistant', id: 'tool'}]) const doChat = () => { @@ -51,6 +52,8 @@ const dispatchMsg = (msg: string): boolean => { showInfoToast('打开配置文件夹成功', '提示', 3000) }) return false + case '/quit': + quitApp() default: return true }