From 2e1a9aee10140d3161be3e5d334a88d9d8352b78 Mon Sep 17 00:00:00 2001 From: wangdan-fit2cloud Date: Thu, 30 May 2024 18:27:23 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=B7=A5=E4=BD=9C=E7=BC=96=E6=8E=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ui/src/components/app-avatar/index.vue | 1 + ui/src/directives/clickoutside.ts | 7 +++ ui/src/styles/app.scss | 3 ++ ui/src/views/application-workflow/index.vue | 43 ++++++++++++++++++- ui/src/views/chat/embed/index.vue | 13 ++---- .../dataset/component/UploadComponent.vue | 4 +- ui/src/views/dataset/step/ResultSuccess.vue | 8 ++-- .../team/component/PermissionSetting.vue | 9 +--- 8 files changed, 64 insertions(+), 24 deletions(-) create mode 100644 ui/src/directives/clickoutside.ts diff --git a/ui/src/components/app-avatar/index.vue b/ui/src/components/app-avatar/index.vue index b267d404a..0df1cbbc2 100644 --- a/ui/src/components/app-avatar/index.vue +++ b/ui/src/components/app-avatar/index.vue @@ -2,6 +2,7 @@ {{ firstUserName }} diff --git a/ui/src/directives/clickoutside.ts b/ui/src/directives/clickoutside.ts new file mode 100644 index 000000000..0e93cf7a9 --- /dev/null +++ b/ui/src/directives/clickoutside.ts @@ -0,0 +1,7 @@ +import type { App } from 'vue' +import { ClickOutside as vClickOutside } from 'element-plus' +export default { + install: (app: App) => { + app.directive('click-outside', vClickOutside) + } +} diff --git a/ui/src/styles/app.scss b/ui/src/styles/app.scss index 0e15126dc..b8277844e 100644 --- a/ui/src/styles/app.scss +++ b/ui/src/styles/app.scss @@ -111,6 +111,9 @@ h4 { .w-240 { width: 240px; } +.w-280 { + width: 280px; +} .w-500 { width: 500px; } diff --git a/ui/src/views/application-workflow/index.vue b/ui/src/views/application-workflow/index.vue index e640729a2..ea3fe0ab3 100644 --- a/ui/src/views/application-workflow/index.vue +++ b/ui/src/views/application-workflow/index.vue @@ -6,11 +6,28 @@

创建应用

- 添加组件 + + 添加组件 + 调试 保存
+ + +
+

基础组件

+
+ + + +
+
通用型
+ 可以通过上传文件或手动录入方式构建知识库 +
+
+
+
@@ -21,11 +38,17 @@ import { ref, onMounted, onBeforeUnmount, computed } from 'vue' import Workflow from '@/components/workflow/index.vue' +const showPopover = ref(false) + +function clickoutside() { + showPopover.value = false +} + onMounted(() => {}) onBeforeUnmount(() => {}) - diff --git a/ui/src/views/chat/embed/index.vue b/ui/src/views/chat/embed/index.vue index 572a2a916..35c1941aa 100644 --- a/ui/src/views/chat/embed/index.vue +++ b/ui/src/views/chat/embed/index.vue @@ -1,5 +1,5 @@