filePicker<T> static method

TFormField<List<TFile>> filePicker<T>(
  1. TFieldProp<List<TFile>> prop,
  2. String? label, {
  3. String? tag,
  4. String? placeholder,
  5. String? helperText,
  6. bool isRequired = false,
  7. bool disabled = false,
  8. bool autoFocus = false,
  9. TFilePickerTheme? theme,
  10. FocusNode? focusNode,
  11. VoidCallback? onTap,
  12. List<String? Function(List<TFile>?)>? rules,
  13. bool allowMultiple = false,
  14. List<String>? allowedExtensions,
  15. TFileType fileType = TFileType.any,
})

Implementation

static TFormField<List<TFile>> filePicker<T>(
  TFieldProp<List<TFile>> prop,
  String? label, {
  String? tag,
  String? placeholder,
  String? helperText,
  bool isRequired = false,
  bool disabled = false,
  bool autoFocus = false,
  TFilePickerTheme? theme,
  FocusNode? focusNode,
  VoidCallback? onTap,
  List<String? Function(List<TFile>?)>? rules,
  bool allowMultiple = false,
  List<String>? allowedExtensions,
  TFileType fileType = TFileType.any,
}) {
  return TFormField<List<TFile>>(
    prop: prop,
    builder: (onValueChanged) => TFilePicker(
      label: label,
      tag: tag,
      placeholder: placeholder,
      helperText: helperText,
      isRequired: isRequired,
      disabled: disabled,
      autoFocus: autoFocus,
      theme: theme,
      focusNode: focusNode,
      onTap: onTap,
      rules: rules,
      allowMultiple: allowMultiple,
      allowedExtensions: allowedExtensions,
      fileType: fileType,
      value: prop.value,
      valueNotifier: prop.valueNotifier,
      onValueChanged: onValueChanged,
    ),
  );
}