StringInput constructor

const StringInput({
  1. String title = '',
  2. String hint = '',
  3. required void onChanged(
    1. String
    ),
  4. void onSaved(
    1. String
    )?,
  5. TextInputType keyboardType = TextInputType.text,
  6. dynamic validator(
    1. String
    )?,
  7. List<TextInputFormatter> inputFormatters = const [],
  8. StringInputType type = StringInputType.normal,
  9. TextInputAction inputAction = TextInputAction.done,
  10. bool obscureText = false,
  11. EdgeInsets padding = EdgeInsets.zero,
  12. EdgeInsets margin = EdgeInsets.zero,
  13. String initialValue = '',
  14. StringInputStyle style = const StringInputStyle.neutral(),
  15. Key? key,
})

Implementation

const StringInput({
  this.title = '',
  this.hint = '',
  required this.onChanged,
  void Function(String)? onSaved,
  this.keyboardType = TextInputType.text,
  this.validator,
  this.inputFormatters = const [],
  this.type = StringInputType.normal,
  this.inputAction = TextInputAction.done,
  this.obscureText = false,
  this.padding = EdgeInsets.zero,
  this.margin = EdgeInsets.zero,
  this.initialValue = '',
  this.style = const StringInputStyle.neutral(),
  Key? key,
})  : onSaved = onSaved ?? onChanged,
      super(key: key);