From f6c5d6d9b737961c8d57410566eb4ddec4acaf7c Mon Sep 17 00:00:00 2001 From: wangdan-fit2cloud Date: Wed, 25 Jun 2025 18:57:06 +0800 Subject: [PATCH] feat: bugs --- ui/src/components/card-box/index.vue | 4 +- .../folder-tree/CreateFolderDialog.vue | 1 + ui/src/components/folder-tree/index.vue | 196 +++++++++--------- ui/src/components/loading/DownloadLoading.vue | 93 +++++++++ ui/src/locales/lang/en-US/components.ts | 6 +- ui/src/locales/lang/zh-CN/components.ts | 2 + ui/src/locales/lang/zh-Hant/components.ts | 2 + ui/src/styles/component.scss | 23 ++ ui/src/styles/element-plus.scss | 3 + ui/src/views/application-overview/index.vue | 2 +- .../XPackDisplaySettingDialog.vue | 6 +- ui/src/views/application-workflow/index.vue | 2 +- .../component/AddKnowledgeDialog.vue | 48 ++--- ui/src/views/application/index.vue | 13 +- ui/src/views/chat/embed/index.vue | 2 +- ui/src/views/chat/mobile/index.vue | 2 +- ui/src/views/chat/pc/index.vue | 6 +- .../component/SelectKnowledgeDialog.vue | 15 +- .../component/KnowledgeListContainer.vue | 13 +- ui/src/views/model/component/ModelCard.vue | 18 +- .../component/PermissionSetting.vue | 7 +- .../tool/component/ToolListContainer.vue | 12 +- .../workflow/icons/application-node-icon.vue | 2 +- 23 files changed, 294 insertions(+), 184 deletions(-) create mode 100644 ui/src/components/loading/DownloadLoading.vue diff --git a/ui/src/components/card-box/index.vue b/ui/src/components/card-box/index.vue index 2acb49633..32a1961b1 100644 --- a/ui/src/components/card-box/index.vue +++ b/ui/src/components/card-box/index.vue @@ -12,9 +12,9 @@
-
+ {{ title }} -
+
diff --git a/ui/src/components/folder-tree/CreateFolderDialog.vue b/ui/src/components/folder-tree/CreateFolderDialog.vue index 375082aea..416cc85a7 100644 --- a/ui/src/components/folder-tree/CreateFolderDialog.vue +++ b/ui/src/components/folder-tree/CreateFolderDialog.vue @@ -13,6 +13,7 @@ :model="folderForm" label-position="top" require-asterisk-position="right" + @submit.prevent > - + {{ shareTitle }} - - + + + @@ -108,10 +112,6 @@ const props = defineProps({ type: Boolean, default: false, }, - iconName: { - type: String, - default: 'app-folder-share-active', - }, shareTitle: { type: String, default: '', @@ -120,6 +120,10 @@ const props = defineProps({ type: Boolean, default: true, }, + treeStyle: { + type: Object, + default: () => ({}), + }, }) const { folder } = useStore() @@ -184,11 +188,11 @@ function deleteFolder(row: Tree) { const CreateFolderDialogRef = ref() function openCreateFolder(row: Tree) { - title.value = '添加子文件夹' + title.value = t('components.folder.addChildFolder') CreateFolderDialogRef.value.open(props.source, row.id) } function openEditFolder(row: Tree) { - title.value = '编辑文件夹' + title.value = t('components.folder.editFolder') CreateFolderDialogRef.value.open(props.source, row.id, row) } @@ -197,39 +201,35 @@ function refreshFolder() { } diff --git a/ui/src/components/loading/DownloadLoading.vue b/ui/src/components/loading/DownloadLoading.vue new file mode 100644 index 000000000..83332c8c5 --- /dev/null +++ b/ui/src/components/loading/DownloadLoading.vue @@ -0,0 +1,93 @@ + + + diff --git a/ui/src/locales/lang/en-US/components.ts b/ui/src/locales/lang/en-US/components.ts index d35e5eddc..855ffd32f 100644 --- a/ui/src/locales/lang/en-US/components.ts +++ b/ui/src/locales/lang/en-US/components.ts @@ -7,12 +7,14 @@ export default { selectParagraph: { title: 'Select Segments', error: 'Process only the failed segments', - all: 'All Segments' + all: 'All Segments', }, folder: { addFolder: 'Add Folder', + addChildFolder: 'Add Child Folder', + editFolder: 'Edit Folder', folderNamePlaceholder: 'Please enter a name', description: 'Description', descriptionPlaceholder: 'Please enter a description', - } + }, } diff --git a/ui/src/locales/lang/zh-CN/components.ts b/ui/src/locales/lang/zh-CN/components.ts index 14c13c110..4901c2edb 100644 --- a/ui/src/locales/lang/zh-CN/components.ts +++ b/ui/src/locales/lang/zh-CN/components.ts @@ -11,6 +11,8 @@ export default { }, folder: { addFolder: '添加文件夹', + addChildFolder: '添加子文件夹', + editFolder: '编辑文件夹', folderNamePlaceholder: '请输入名称', description: '描述', descriptionPlaceholder: '请输入描述', diff --git a/ui/src/locales/lang/zh-Hant/components.ts b/ui/src/locales/lang/zh-Hant/components.ts index f4be4bf2b..a63db6a68 100644 --- a/ui/src/locales/lang/zh-Hant/components.ts +++ b/ui/src/locales/lang/zh-Hant/components.ts @@ -11,6 +11,8 @@ export default { }, folder: { addFolder: '添加文件夾', + addChildFolder: '添加子文件夾', + editFolder: '編輯文件夾', folderNamePlaceholder: '請輸入名稱', description: '描述', descriptionPlaceholder: '請輸入描述', diff --git a/ui/src/styles/component.scss b/ui/src/styles/component.scss index b14b76728..55e463ea2 100644 --- a/ui/src/styles/component.scss +++ b/ui/src/styles/component.scss @@ -179,3 +179,26 @@ display: block !important; } } + +// 下载中 +.dotting { + display: inline-block; + width: 10px; + min-height: 2px; + padding-right: 2px; + margin-left: 2px; + padding-left: 2px; + border-left: 2px solid currentColor; + border-right: 2px solid currentColor; + background-color: currentColor; + background-clip: content-box; + box-sizing: border-box; + -webkit-animation: dot 0.8s infinite step-start both; + animation: dot 0.8s infinite step-start both; + &:before { + content: '...'; + } + &::before { + content: ''; + } +} diff --git a/ui/src/styles/element-plus.scss b/ui/src/styles/element-plus.scss index 6c31336db..6953d5a23 100644 --- a/ui/src/styles/element-plus.scss +++ b/ui/src/styles/element-plus.scss @@ -203,6 +203,9 @@ .el-dialog { --el-dialog-padding-primary: 24px; --el-dialog-border-radius: 8px; + .el-dialog__body { + color: var(--el-text-color-primary); + } } .el-dialog__headerbtn { top: 8px; diff --git a/ui/src/views/application-overview/index.vue b/ui/src/views/application-overview/index.vue index 9da132443..ce383af2f 100644 --- a/ui/src/views/application-overview/index.vue +++ b/ui/src/views/application-overview/index.vue @@ -23,7 +23,7 @@ - + - +

diff --git a/ui/src/views/application-workflow/index.vue b/ui/src/views/application-workflow/index.vue index 7d94d48b2..34fb98429 100644 --- a/ui/src/views/application-workflow/index.vue +++ b/ui/src/views/application-workflow/index.vue @@ -92,7 +92,7 @@ > - +

diff --git a/ui/src/views/application/component/AddKnowledgeDialog.vue b/ui/src/views/application/component/AddKnowledgeDialog.vue index 67e3c0e60..27db08c4f 100644 --- a/ui/src/views/application/component/AddKnowledgeDialog.vue +++ b/ui/src/views/application/component/AddKnowledgeDialog.vue @@ -45,29 +45,33 @@ v-loading="folderLoading" :canOperation="false" showShared + :shareTitle="$t('views.system.shared.shared_knowledge')" + :treeStyle="{ height: 'calc(100vh - 320px)' }" /> - -
- - - + +
+ + - {{ item.name }} - - - -
-
+ + {{ item.name }} + +
+
+
+
+