From 5403f142aee3279324aa8d87afd97f539c5eb564 Mon Sep 17 00:00:00 2001 From: chanx <1243304602@qq.com> Date: Mon, 16 Mar 2026 20:15:49 +0800 Subject: [PATCH] Feat: Add chunk also supports uploading image. (#13628) ### What problem does this PR solve? Feat: Add chunk also supports uploading image. ### Type of change - [x] New Feature (non-breaking change which adds functionality) --- web/src/components/file-uploader.tsx | 2 +- .../components/chunk-creating-modal/index.tsx | 7 +------ 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/web/src/components/file-uploader.tsx b/web/src/components/file-uploader.tsx index 813787a7ca..0f6318e252 100644 --- a/web/src/components/file-uploader.tsx +++ b/web/src/components/file-uploader.tsx @@ -382,7 +382,7 @@ export function FileUploader(props: FileUploaderProps) {
{!(hideDropzoneOnMaxFileCount && reachesMaxFileCount) && ( - + {t('fileManager.files', 'Files')} diff --git a/web/src/pages/chunk/parsed-result/add-knowledge/components/knowledge-chunk/components/chunk-creating-modal/index.tsx b/web/src/pages/chunk/parsed-result/add-knowledge/components/knowledge-chunk/components/chunk-creating-modal/index.tsx index 94e771ce22..5b3d65e67e 100644 --- a/web/src/pages/chunk/parsed-result/add-knowledge/components/knowledge-chunk/components/chunk-creating-modal/index.tsx +++ b/web/src/pages/chunk/parsed-result/add-knowledge/components/knowledge-chunk/components/chunk-creating-modal/index.tsx @@ -146,7 +146,6 @@ const ChunkCreatingModal: React.FC & kFProps> = ({ )} /> - {/* Do not display the type field in create mode */} {isEditMode && ( & kFProps> = ({ /> )} - {isEditMode && form.getValues('doc_type_kwd') === 'image' && ( + {(!isEditMode || form.getValues('doc_type_kwd') + '' === 'image') && ( & kFProps> = ({ )} /> )} - & kFProps> = ({ )} /> - & kFProps> = ({ )} /> - {isTagParser && ( & kFProps> = ({ )} /> )} - {!isTagParser && (