From 01e03dedbfad766772aa2de316c003b25beca10c Mon Sep 17 00:00:00 2001 From: dohyeons Date: Tue, 4 Nov 2025 16:26:53 +0900 Subject: [PATCH] =?UTF-8?q?=ED=8C=8C=EC=9D=BC=20=EC=97=85=EB=A1=9C?= =?UTF-8?q?=EB=93=9C=20=EC=BB=B4=ED=8F=AC=EB=84=8C=ED=8A=B8=20=EB=86=92?= =?UTF-8?q?=EC=9D=B4=20=EC=A1=B0=EC=A0=88=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/screen/RealtimePreviewDynamic.tsx | 15 ++++++++++++--- .../file-upload/FileUploadComponent.tsx | 3 ++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/frontend/components/screen/RealtimePreviewDynamic.tsx b/frontend/components/screen/RealtimePreviewDynamic.tsx index 72739e71..129d2487 100644 --- a/frontend/components/screen/RealtimePreviewDynamic.tsx +++ b/frontend/components/screen/RealtimePreviewDynamic.tsx @@ -222,9 +222,11 @@ export const RealtimePreviewDynamic: React.FC = ({ return `${actualHeight}px`; } - // 1순위: style.height가 있으면 우선 사용 + // 1순위: style.height가 있으면 우선 사용 (문자열 그대로 또는 숫자+px) if (componentStyle?.height) { - return componentStyle.height; + return typeof componentStyle.height === 'number' + ? `${componentStyle.height}px` + : componentStyle.height; } // 2순위: size.height (픽셀) @@ -232,7 +234,14 @@ export const RealtimePreviewDynamic: React.FC = ({ return `${Math.max(size?.height || 200, 200)}px`; } - return `${size?.height || 40}px`; + // 3순위: size.height가 있으면 사용 + if (size?.height) { + return typeof size.height === 'number' + ? `${size.height}px` + : size.height; + } + + return "40px"; }; const baseStyle = { diff --git a/frontend/lib/registry/components/file-upload/FileUploadComponent.tsx b/frontend/lib/registry/components/file-upload/FileUploadComponent.tsx index 1af4b869..5eea6d60 100644 --- a/frontend/lib/registry/components/file-upload/FileUploadComponent.tsx +++ b/frontend/lib/registry/components/file-upload/FileUploadComponent.tsx @@ -901,6 +901,8 @@ const FileUploadComponent: React.FC = ({
= ({
{/* 파일 업로드 영역 - 주석처리 */} {/* {!isDesignMode && (