BasicInputDropdown<T> constructor
const
BasicInputDropdown<T> ({
- Key? key,
- String? name,
- bool haveSearch = false,
- List<
BasicInputDropdownItemModel< filterOption()?,T> > - dynamic onSelected()?,
- Offset? offset,
- double? maxHeightPopup,
- double? minHeightPopup,
- double? maxWidthPopup,
- double? minWidthPopup,
- BasicInputSize? size,
- double? width,
- BasicInputDropdownItemModel<
T> ? initialValue, - TextEditingController? controller,
- FocusNode? focusNode,
- dynamic onFocusChange()?,
- TextAlign textAlign = TextAlign.start,
- TextAlignVertical? textAlignVertical,
- TextInputAction? textInputAction,
- TextInputType? keyboardType,
- int maxLines = 1,
- int? minLines,
- int? maxLength,
- bool enabled = true,
- bool obscureText = false,
- EdgeInsets? scrollPadding,
- Color? cursorColor,
- AutovalidateMode? autoValidateMode,
- FormFieldValidator<
String> ? validator, - List<
TextInputFormatter> ? inputFormatters, - ValueTransformer<
BasicInputDropdownItemModel< ? valueTransformer,T> ?> - ValueChanged<
String?> ? onChanged, - GestureTapCallback? onTap,
- VoidCallback? onEditingComplete,
- FormFieldSetter? onSaved,
- bool? isDense,
- bool? filled,
- Widget? prefixIcon,
- EdgeInsets? contentPadding,
- InputBorder? focusedBorder,
- InputBorder? enabledBorder,
- InputBorder? disabledBorder,
- InputBorder? errorBorder,
- InputBorder? focusedErrorBorder,
- Color? fillColor,
- Color? hoverColor,
- String? labelText,
- TextStyle? labelStyle,
- TextStyle? floatingLabelStyle,
- FloatingLabelBehavior? floatingLabelBehavior,
- String? hintText,
- TextStyle? hintStyle,
- String? errorText,
- int? errorMaxLines,
- TextStyle? errorStyle,
Implementation
const BasicInputDropdown({
Key? key,
this.name,
this.haveSearch = false,
this.filterOption,
required this.menuChildren,
this.onSelected,
this.offset,
this.maxHeightPopup,
this.minHeightPopup,
this.maxWidthPopup,
this.minWidthPopup,
this.size,
this.width,
this.initialValue,
this.controller,
this.focusNode,
this.onFocusChange,
this.textAlign = TextAlign.start,
this.textAlignVertical,
this.textInputAction,
this.keyboardType,
this.maxLines = 1,
this.minLines,
this.maxLength,
this.enabled = true,
this.obscureText = false,
this.scrollPadding,
this.cursorColor,
this.autoValidateMode,
this.validator,
this.inputFormatters,
this.valueTransformer,
this.onChanged,
this.onTap,
this.onEditingComplete,
this.onSaved,
this.isDense,
this.filled,
this.prefixIcon,
this.contentPadding,
this.focusedBorder,
this.enabledBorder,
this.disabledBorder,
this.errorBorder,
this.focusedErrorBorder,
this.fillColor,
this.hoverColor,
this.labelText,
this.labelStyle,
this.floatingLabelStyle,
this.floatingLabelBehavior,
this.hintText,
this.hintStyle,
this.errorText,
this.errorMaxLines,
this.errorStyle,
}) : assert(
!(haveSearch == true && filterOption == null),
'If haveSearch is true, filterOption must not be null',
),
super(key: key);