File tree Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,10 @@ class FormBuilderFilePicker extends FormBuilderField<List<PlatformFile>> {
41
41
/// which can be useful if you are picking it for server upload or similar.
42
42
final bool withData;
43
43
44
+ /// If [withReadStream] is set, picked files will have its byte data available as a [Stream<List<int>>]
45
+ /// which can be useful for uploading and processing large files.
46
+ final bool withReadStream;
47
+
44
48
FormBuilderFilePicker ({
45
49
//From Super
46
50
Key key,
@@ -57,6 +61,7 @@ class FormBuilderFilePicker extends FormBuilderField<List<PlatformFile>> {
57
61
FocusNode focusNode,
58
62
this .maxFiles,
59
63
this .withData = false ,
64
+ this .withReadStream = false ,
60
65
this .allowMultiple = true ,
61
66
this .previewImages = true ,
62
67
this .selector = const Icon (Icons .add_circle),
@@ -155,6 +160,7 @@ class _FormBuilderFilePickerState
155
160
onFileLoading: widget.onFileLoading,
156
161
allowMultiple: widget.allowMultiple,
157
162
withData: widget.withData,
163
+ withReadStream: widget.withReadStream,
158
164
);
159
165
} else {
160
166
throw Exception ('Storage Permission not granted' );
Original file line number Diff line number Diff line change @@ -168,7 +168,7 @@ packages:
168
168
name: file_picker
169
169
url: "https://pub.dartlang.org"
170
170
source: hosted
171
- version: "2.0.13 "
171
+ version: "2.1.0 "
172
172
flutter:
173
173
dependency: "direct main"
174
174
description: flutter
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ dependencies:
18
18
date_range_picker : ^1.0.6
19
19
datetime_picker_formfield : ^1.0.0
20
20
dropdown_search : ^0.4.8
21
- file_picker : ^2.0.13
21
+ file_picker : ^2.1.0
22
22
flutter_colorpicker : ^0.3.4
23
23
flutter_chips_input : ^1.9.4
24
24
flutter_datetime_picker : ^1.4.0
You can’t perform that action at this time.
0 commit comments