From 308f05ca076758426850660025866e3db5ff205e Mon Sep 17 00:00:00 2001 From: kjs Date: Wed, 11 Feb 2026 09:47:59 +0900 Subject: [PATCH] fix: Correct file upload configuration handling in FileUploadComponent - Updated the file upload configuration to ensure that the safeComponentConfig is properly merged into fileConfig. - This change enhances the reliability of file upload settings by ensuring that default values are applied correctly, improving the overall functionality of the file upload feature. --- .../components/v2-file-upload/FileUploadComponent.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/lib/registry/components/v2-file-upload/FileUploadComponent.tsx b/frontend/lib/registry/components/v2-file-upload/FileUploadComponent.tsx index 9af1a58a..42b81edd 100644 --- a/frontend/lib/registry/components/v2-file-upload/FileUploadComponent.tsx +++ b/frontend/lib/registry/components/v2-file-upload/FileUploadComponent.tsx @@ -492,11 +492,11 @@ const FileUploadComponent: React.FC = ({ // 파일 업로드 설정 - componentConfig가 undefined일 수 있으므로 안전하게 처리 const safeComponentConfig = componentConfig || {}; const fileConfig = { + ...safeComponentConfig, accept: safeComponentConfig.accept || "*/*", multiple: safeComponentConfig.multiple || false, maxSize: safeComponentConfig.maxSize || 10 * 1024 * 1024, // 10MB maxFiles: safeComponentConfig.maxFiles || 5, - ...safeComponentConfig, } as FileUploadConfig; // 파일 선택 핸들러 @@ -1117,7 +1117,7 @@ const FileUploadComponent: React.FC = ({ onFileDelete={handleFileDelete} onFileView={handleFileView} onSetRepresentative={handleSetRepresentative} - config={safeComponentConfig} + config={fileConfig} isDesignMode={isDesignMode} />