TextFieldWidget constructor

const TextFieldWidget({
  1. Key? key,
  2. required ChampionFormController controller,
  3. required ChampionTextField field,
  4. String fieldId = "",
  5. FieldColorScheme? colorScheme,
  6. required FieldState fieldState,
  7. TextField? fieldOverride,
  8. bool requestFocus = false,
  9. bool password = false,
  10. dynamic onChanged(
    1. FormResults results
    )?,
  11. dynamic onSubmitted(
    1. FormResults results
    )?,
  12. TextInputType keyboardType = TextInputType.text,
  13. dynamic validate(
    1. String value
    )?,
  14. String? initialValue = "",
  15. String? labelText,
  16. String? hintText,
  17. int? maxLines,
  18. Future<void> onDrop({
    1. TextEditingController controller,
    2. required String fieldId,
    3. required String formId,
    })?,
  19. List<DataFormat<Object>>? formats,
  20. bool draggable = true,
  21. Future<void> onPaste({
    1. TextEditingController controller,
    2. required String fieldId,
    3. required String formId,
    })?,
  22. Widget fieldBuilder({
    1. required Widget child,
    })?,
})

Implementation

const TextFieldWidget({
  super.key,
  required this.controller,
  required this.field,
  this.fieldId = "",
  this.colorScheme,
  required this.fieldState,
  this.fieldOverride,
  this.requestFocus = false,
  this.password = false,
  this.onChanged,
  this.onSubmitted,
  this.keyboardType = TextInputType.text,
  this.validate,
  this.initialValue = "",
  this.labelText,
  this.hintText,
  this.maxLines,
  this.onDrop,
  this.formats,
  this.draggable = true,
  this.onPaste,
  Widget Function({required Widget child})? fieldBuilder,
}) : fieldBuilder = fieldBuilder ?? defaultFieldBuilder;