BasicTextField class

Creates a FormField that contains a TextField.

Inheritance

Constructors

BasicTextField({Key? key, String? label, String? placeholder, String? defaultValue, int? maxLength, int? maxLines = 1, int? autoClear, TextInputType? keyboardType, dynamic onChanged(String)?, dynamic onClear()?, String? validator(String?)?, bool isPassword = false, Color? fillColor, Color? textColor, Color? labelColor, Color? borderColor, Color? focusedBorderColor, double? borderWidth, double? borderRadius, EdgeInsetsGeometry? contentPadding, BasicTextVariant? labelVariant, double? textSize, EdgeInsets? margin, bool clearText = false, Icon? prefixIcon, bool hideCounterText = true, TextAlign textAlign = TextAlign.start})
const

Properties

autoClear int?
if not null and not 1, BasicTextField value will cleared.
final
borderColor Color?
Border color.
final
borderRadius double?
Border radius.
final
borderWidth double?
Border width.
final
clearText bool
Set to true to enable clear text button.
final
contentPadding EdgeInsetsGeometry?
The padding for the input decoration's container.
final
defaultValue String?
Default value for BasicTextField
final
fillColor Color?
The base fill color of the decoration's container color.
final
focusedBorderColor Color?
Border color when BasicTextField is focused.
final
hashCode int
The hash code for this object.
no setterinherited
hideCounterText bool
Set to true to hide counter text.
final
isPassword bool
Set this to true to make BasicTextField hide it's value
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
keyboardType TextInputType?
The type of information for which to optimize the text input control.
final
label String?
Text to display as BasicTextField label.
final
labelColor Color?
Label color.
final
labelVariant BasicTextVariant?
The BasicTextVariant for label text.
final
margin EdgeInsets?
Empty space to surround the BasicTextField.
final
maxLength int?
Set max length of BasicTextField value
final
maxLines int?
Set max lines of BasicTextField
final
onChanged → (dynamic Function(String)?)
The callback when BasicTextField value is changed.
final
onClear → (dynamic Function()?)
The callback when clear button is tapped.
final
placeholder String?
Text to display as BasicTextField hint text.
final
prefixIcon Icon?
Icon to show at start of BasicTextField.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
textAlign TextAlign
How the text should be aligned horizontally.
final
textColor Color?
Text color.
final
textSize double?
Text size.
final
validator → (String? Function(String?)?)
The callback when FormField is validated.
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
createElement() → _StatelessHookElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited