FormFieldDef constructor
FormFieldDef({
- required String id,
- Widget? icon,
- FormTheme? theme,
- String? title,
- String? description,
- bool disabled = false,
- bool hideField = false,
- bool requestFocus = false,
- List<
FormBuilderValidator> ? validators, - bool validateLive = false,
- dynamic onSubmit(
- FormResults results
- dynamic onChange(
- FormResults results
- Widget fieldLayout(
- BuildContext context,
- FormFieldDef fieldDetails,
- FieldColorScheme currentColors,
- List<
FormBuilderError> errors, - Widget renderedField,
- Widget fieldBackground(
- BuildContext context,
- FormFieldDef fieldDetails,
- FieldColorScheme currentColors,
- Widget renderedField,
Implementation
FormFieldDef({
required this.id,
this.icon,
this.theme,
this.title,
this.description,
this.disabled = false,
this.hideField = false,
this.requestFocus = false,
this.validators,
this.validateLive = false,
this.onSubmit,
this.onChange,
//this.embeds = const [],
this.fieldLayout = fieldSimpleLayout, // Default to the simple layout
this.fieldBackground =
fieldSimpleBackground, // Default to the simple (no) field background
});