Skip to content

Commit d4b2ac6

Browse files
committed
docs: supportDirectory property documentation and note for assignBrowse method
1 parent 0e838b2 commit d4b2ac6

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,13 +123,15 @@ parameter must be adjusted together with `progressCallbacksInterval` parameter.
123123
#### Properties
124124

125125
* `.support` A boolean value indicator whether or not Flow.js is supported by the current browser.
126+
* `.supportDirectory` A boolean value, which indicates if browser supports directory uploads.
126127
* `.opts` A hash object of the configuration of the Flow.js instance.
127128
* `.files` An array of `FlowFile` file objects added by the user (see full docs for this object type below).
128129

129130
#### Methods
130131

131-
* `.assignBrowse(domNodes, isDirectory, singleFile)` Assign a browse action to one or more DOM nodes. Pass in `true` to allow directories to be selected (Chrome only). To prevent multiple file uploads
132-
set singleFile to true.
132+
* `.assignBrowse(domNodes, isDirectory, singleFile)` Assign a browse action to one or more DOM nodes. Pass in `true` to allow directories to be selected (Chrome only, support can be checked with `supportDirectory` property).
133+
To prevent multiple file uploads set singleFile to true.
134+
Note: avoid using `a` and `button` tags as file upload buttons, use span instead.
133135
* `.assignDrop(domNodes)` Assign one or more DOM nodes as a drop target.
134136
* `.on(event, callback)` Listen for event from Flow.js (see below)
135137
* `.upload()` Start or resume uploading.

0 commit comments

Comments
 (0)