TextFieldWidget constructor

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

Implementation

const TextFieldWidget({
  super.key,
  required this.id,
  required this.field,
  this.fieldId = "",
  this.formId = "",
  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;