Skip to content

feat: use multi-select for file upload accept attribute#36

Open
sketchp1ane wants to merge 2 commits into
Ali-Hussein-dev:mainfrom
sketchp1ane:fix/file-upload-accept-multiselect
Open

feat: use multi-select for file upload accept attribute#36
sketchp1ane wants to merge 2 commits into
Ali-Hussein-dev:mainfrom
sketchp1ane:fix/file-upload-accept-multiselect

Conversation

@sketchp1ane
Copy link
Copy Markdown

Summary

Closes #26.

Replaces the FileUpload customization drawer's manual "Accept attribute" text input with a MultiSelect of common MIME types and file extensions.

Changes

  • Adds common accept presets such as image/*, .pdf, .docx, audio/*, and video/*
  • Keeps the stored accept value as a comma-separated HTML accept string
  • Preserves existing custom accept values by rendering them as selected options
  • Leaves shared RenderFormElement MultiSelect behavior unchanged

Validation

  • bunx biome check src/form-builder/components/edit/field-edit.tsx
    • Fails on an existing unrelated Logo image alt-text diagnostic
  • bun run build
    • Passes
  • Manually verified the FileUpload drawer shows a MultiSelect, saves selected accept values, restores them after reopening, and keeps the FileUpload preview working

@vercel
Copy link
Copy Markdown

vercel Bot commented May 18, 2026

Someone is attempting to deploy a commit to the AH's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

use multi-select for accept input in Upload Field (better UX)

1 participant