Skip to content

Commit

Permalink
fix: file upload
Browse files Browse the repository at this point in the history
  • Loading branch information
segunadebayo committed Sep 19, 2024
1 parent 7c160ca commit 7a6b6e7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/slow-lamps-remain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@zag-js/file-upload": patch
---

Fix issue where `directory: true` doesn't work
2 changes: 1 addition & 1 deletion packages/machines/file-upload/src/file-upload.connect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export function connect<T extends PropTypes>(state: State, send: Send, normalize
capture: state.context.capture,
name: state.context.name,
accept: state.context.acceptAttr,
webkitdirectory: state.context.capture ? "" : undefined,
webkitdirectory: state.context.directory ? "" : undefined,
multiple: state.context.multiple || state.context.maxFiles > 1,
onClick(event) {
event.stopPropagation()
Expand Down

0 comments on commit 7a6b6e7

Please sign in to comment.