InputField.password constructor

InputField.password({
  1. Key? key,
  2. required TextEditingController controller,
  3. String labelText = "Password",
  4. bool passwordVisible = true,
  5. bool obscureText = true,
  6. bool autoFocus = false,
  7. TextInputType keyboardType = TextInputType.text,
  8. TextAlign? textAlign,
  9. int maxLines = 1,
  10. bool validateOnFocusChange = false,
  11. dynamic handleValidationError(
    1. FormValidationResult handleError
    )?,
  12. int? minLines,
  13. bool enableSuggestions = true,
  14. String? hintText,
  15. TextStyle? hintStyle,
  16. FocusNode? focusNode,
  17. FormValidator? formValidator,
  18. String? dummyData,
  19. dynamic onChanged(
    1. String value
    )?,
  20. TextStyle? style,
  21. StrutStyle? strutStyle,
  22. TextInputAction? textInputAction,
  23. bool readOnly = false,
  24. bool? showCursor,
  25. int? maxLength,
  26. bool? enabled,
  27. DragStartBehavior dragStartBehavior = DragStartBehavior.start,
  28. double? cursorHeight,
  29. Radius? cursorRadius,
  30. Color? cursorColor,
  31. GestureTapCallback? onTap,
  32. TapRegionCallback? onTapOutside,
  33. MouseCursor? mouseCursor,
  34. TextCapitalization textCapitalization = TextCapitalization.none,
  35. MaxLengthEnforcement? maxLengthEnforcement,
  36. double cursorWidth = 2.0,
  37. AppPrivateCommandCallback? onAppPrivateCommand,
  38. List<TextInputFormatter>? inputFormatters,
  39. bool expands = false,
  40. TextAlignVertical? textAlignVertical,
  41. TextDirection? textDirection,
  42. String obscuringCharacter = '•',
  43. bool autocorrect = true,
  44. SmartDashesType? smartDashesType,
  45. SmartQuotesType? smartQuotesType,
  46. InputDecoration? decoration,
  47. VoidCallback? onEditingComplete,
  48. Brightness? keyboardAppearance,
  49. EdgeInsets scrollPadding = const EdgeInsets.all(20.0),
  50. TextSelectionControls? selectionControls,
  51. ValueChanged<String>? onSubmitted,
  52. ScrollController? scrollController,
  53. ScrollPhysics? scrollPhysics,
  54. bool? passwordViewable,
  55. Iterable<String>? autofillHints = const <String>[],
  56. Clip clipBehavior = Clip.hardEdge,
  57. Widget? prefixIcon,
  58. Color? backgroundColor,
  59. BorderRadius? borderRadius,
  60. InputBorder? border,
  61. InputBorder? focusedBorder,
  62. InputBorder? enabledBorder,
  63. EdgeInsetsGeometry? contentPadding,
  64. TextStyle? labelStyle,
  65. Widget? header,
  66. Widget? footer,
  67. bool? clearable,
  68. Widget? clearIcon,
  69. String? mask,
  70. String? maskMatch,
  71. bool? maskedReturnValue,
  72. DecoratorTextField? decorator,
  73. String? stateName,
})

Password Text Field - obscured by default with visibility toggle

Implementation

InputField.password({
  Key? key,
  required TextEditingController controller,
  String labelText = "Password",
  bool passwordVisible = true,
  bool obscureText = true,
  bool autoFocus = false,
  TextInputType keyboardType = TextInputType.text,
  TextAlign? textAlign,
  int maxLines = 1,
  bool validateOnFocusChange = false,
  Function(FormValidationResult handleError)? handleValidationError,
  int? minLines,
  bool enableSuggestions = true,
  String? hintText,
  TextStyle? hintStyle,
  FocusNode? focusNode,
  FormValidator? formValidator,
  String? dummyData,
  Function(String value)? onChanged,
  TextStyle? style,
  StrutStyle? strutStyle,
  TextInputAction? textInputAction,
  bool readOnly = false,
  bool? showCursor,
  int? maxLength,
  bool? enabled,
  DragStartBehavior dragStartBehavior = DragStartBehavior.start,
  double? cursorHeight,
  Radius? cursorRadius,
  Color? cursorColor,
  GestureTapCallback? onTap,
  TapRegionCallback? onTapOutside,
  MouseCursor? mouseCursor,
  TextCapitalization textCapitalization = TextCapitalization.none,
  MaxLengthEnforcement? maxLengthEnforcement,
  double cursorWidth = 2.0,
  AppPrivateCommandCallback? onAppPrivateCommand,
  List<TextInputFormatter>? inputFormatters,
  bool expands = false,
  TextAlignVertical? textAlignVertical,
  TextDirection? textDirection,
  String obscuringCharacter = '•',
  bool autocorrect = true,
  SmartDashesType? smartDashesType,
  SmartQuotesType? smartQuotesType,
  InputDecoration? decoration,
  VoidCallback? onEditingComplete,
  Brightness? keyboardAppearance,
  EdgeInsets scrollPadding = const EdgeInsets.all(20.0),
  TextSelectionControls? selectionControls,
  ValueChanged<String>? onSubmitted,
  ScrollController? scrollController,
  ScrollPhysics? scrollPhysics,
  bool? passwordViewable,
  Iterable<String>? autofillHints = const <String>[],
  Clip clipBehavior = Clip.hardEdge,
  Widget? prefixIcon,
  Color? backgroundColor,
  BorderRadius? borderRadius,
  InputBorder? border,
  InputBorder? focusedBorder,
  InputBorder? enabledBorder,
  EdgeInsetsGeometry? contentPadding,
  TextStyle? labelStyle,
  Widget? header,
  Widget? footer,
  bool? clearable,
  Widget? clearIcon,
  String? mask,
  String? maskMatch,
  bool? maskedReturnValue,
  DecoratorTextField? decorator,
  String? stateName,
}) : this(
       key: key,
       controller: controller,
       labelText: labelText,
       passwordVisible: passwordVisible,
       obscureText: obscureText,
       autoFocus: autoFocus,
       keyboardType: keyboardType,
       textAlign: textAlign,
       maxLines: maxLines,
       validateOnFocusChange: validateOnFocusChange,
       handleValidationError: handleValidationError,
       minLines: minLines,
       enableSuggestions: enableSuggestions,
       hintText: hintText,
       hintStyle: hintStyle,
       focusNode: focusNode,
       formValidator: formValidator,
       dummyData: dummyData,
       onChanged: onChanged,
       style: style,
       strutStyle: strutStyle,
       textInputAction: textInputAction,
       readOnly: readOnly,
       showCursor: showCursor,
       maxLength: maxLength,
       enabled: enabled,
       dragStartBehavior: dragStartBehavior,
       cursorHeight: cursorHeight,
       cursorRadius: cursorRadius,
       cursorColor: cursorColor,
       onTap: onTap,
       onTapOutside: onTapOutside,
       mouseCursor: mouseCursor,
       textCapitalization: textCapitalization,
       maxLengthEnforcement: maxLengthEnforcement,
       cursorWidth: cursorWidth,
       onAppPrivateCommand: onAppPrivateCommand,
       inputFormatters: inputFormatters,
       expands: expands,
       textAlignVertical: textAlignVertical,
       textDirection: textDirection,
       obscuringCharacter: obscuringCharacter,
       autocorrect: autocorrect,
       smartDashesType: smartDashesType,
       smartQuotesType: smartQuotesType,
       decoration: decoration,
       onEditingComplete: onEditingComplete,
       keyboardAppearance: keyboardAppearance,
       scrollPadding: scrollPadding,
       selectionControls: selectionControls,
       onSubmitted: onSubmitted,
       scrollController: scrollController,
       scrollPhysics: scrollPhysics,
       passwordViewable: passwordViewable,
       autofillHints: autofillHints,
       clipBehavior: clipBehavior,
       prefixIcon: prefixIcon,
       backgroundColor: backgroundColor,
       borderRadius: borderRadius,
       border: border,
       focusedBorder: focusedBorder,
       enabledBorder: enabledBorder,
       contentPadding: contentPadding,
       labelStyle: labelStyle,
       header: header,
       footer: footer,
       clearable: clearable,
       clearIcon: clearIcon,
       mask: mask,
       maskMatch: maskMatch,
       maskedReturnValue: maskedReturnValue,
       decorator: decorator,
       stateName: stateName,
     );