Skip to content

feat: support accept filters in FileDrop - #1248

Open
ahmedkhan1 wants to merge 1 commit into
widgetti:masterfrom
ahmedkhan1:feat/issue-56-filedrop-accept
Open

ahmedkhan1 wants to merge 1 commit into
widgetti:masterfrom
ahmedkhan1:feat/issue-56-filedrop-accept

Conversation

@ahmedkhan1

Copy link
Copy Markdown

All Submissions:

  • I installed pre-commit prior to committing my changes.
  • My commit messages conform to conventional commits.
  • My PR title conforms to conventional commits.
  • I linked to the relevant issue.

Changes to / New Features:

  • I included API docs for the feature.
  • I wrote tests for the feature.

Description of changes

Adds an optional accept argument to FileDrop and FileDropMultiple. Dropped files are filtered in the browser using standard accept tokens: file extensions, exact MIME types, and wildcard MIME types.

Tests cover extension, exact MIME, wildcard MIME, no filter, and multiple-file filtering on both Flask and Starlette.

Closes #56

This branch has not been deployed

No deployments
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.

FileDrop limit file types with 'accept'

1 participant