UFilePicker constructor

const UFilePicker({
  1. required ValueChanged<List<FileData>> onFilesChanged,
  2. Key? key,
  3. List<FileData> initialFiles = const <FileData>[],
  4. bool allowMultipleSelection = true,
  5. String selectFileTitle = "Select Files",
  6. List<String> imageTypes = const <String>["jpg", "jpeg", "png", "gif", "bmp", "webp"],
  7. List<String> videoTypes = const <String>["mp4", "mov", "avi", "mkv", "webm"],
  8. List<String> documentTypes = const <String>["pdf", "doc", "docx", "xls", "xlsx", "ppt", "pptx", "txt"],
  9. FileType fileType = FileType.custom,
})

Implementation

const UFilePicker({
  required this.onFilesChanged,
  super.key,
  this.initialFiles = const <FileData>[],
  this.allowMultipleSelection = true,
  this.selectFileTitle = "Select Files",
  this.imageTypes = const <String>["jpg", "jpeg", "png", "gif", "bmp", "webp"],
  this.videoTypes = const <String>["mp4", "mov", "avi", "mkv", "webm"],
  this.documentTypes = const <String>["pdf", "doc", "docx", "xls", "xlsx", "ppt", "pptx", "txt"],
  this.fileType = FileType.custom,
});