reopt design
DocsExploreTemplatesCanvasToolsPricing
Login
opt-uiopt-chartsopt-datagridopt-editoropt-calendaropt-filemanageropt-chatopt-shellbrandapp-ui
Overview205Core74Shells99Blocks32
FileUploadForm
reopt designreopt design

A design system for the AI era

  • Docs
  • Pricing
  • Releases
  • About
  • Contact
  • Terms of Service
  • Privacy Policy

reopt Inc.Business registration no. 217-88-02453contact@reopt.ai

© 2026 reopt Inc. All rights reserved.

FileUploadForm

Shell

Select files with metadata, image previews, size limits, and description input.

form
Related docs
bun add @reopt-ai/opt-ui
Install and import
bash
bun add @reopt-ai/opt-ui
tsx
import { FileUploadForm } from "@reopt-ai/opt-ui";

Live preview

Change the width and theme, then interact with the components.

100%

파일 업로드 폼

FileUploadForm

PropTypeDefaultDescription
acceptstring"image/*,.pdf,.doc,.docx"허용 파일 타입
showPreviewbooleantrue이미지 미리보기 표시
showFileInfobooleantrue파일 정보 표시
showDescriptionbooleantrue설명 텍스트영역 표시
maxFileSizenumber—최대 파일 크기 (bytes)
onSubmit(values: { title: string; description: string; file: File | null }) => void | Promise<void>—제출 핸들러
labelsFileUploadFormLabels—i18n용 라벨 오버라이드
onPreview(file: File) => void—파일 선택 후 프리뷰 콜백
columnMappingReactNode—CSV 컬럼 매핑 UI 슬롯 (파일 선택 후 표시)

컴포넌트 의존 관계

깊이
▼ USES (1)FileUploadFormform
View test results

테스트 커버리지

2026년 7월 9일8/8 통과
8성공
0실패
8전체
  • 폼을 렌더링한다
  • 제목 필드를 렌더링한다
  • 설명 필드를 렌더링한다
  • showDescription=false면 설명을 숨긴다
  • 파일 선택 영역을 렌더링한다
  • 업로드 버튼을 렌더링한다
  • labels로 텍스트를 커스텀한다
  • 필수 제목이 비어 있으면 제출을 차단한다

Related components

opt-ui

Form

Core

Build accessible forms with opt-ui-primitives Form APIs, field validation, specialized inputs, and shared form store hooks.

opt-ui

SettingsForm

Shells

Build settings forms from data with validation, radio buttons, and checkboxes.

opt-ui

AuthForm

Shells

Switch between sign-in and sign-up forms with email and password validation and a remember-me option.

opt-ui

WizardForm

Shells

Guide sequential input with field definitions, per-step validation, an associated progress indicator, and a review step.

opt-ui

DynamicFieldForm

Shells

Add and remove fields at runtime with count limits, individual validation, and dynamic store updates.

opt-ui

KeyValueEditor

Shells

Edit key-value pairs with dynamic rows, secret-value visibility, and validation.

PreviousDynamicFieldFormNextEventIcon