FormControlScope class

Publishes the current form-field registration to one control subtree.

Used by FormField and custom form hosts. A control only participates when it is below this scope; being below a Form alone does not alter its behavior.

Inheritance
Available extensions

Constructors

FormControlScope({Key? key, required FormControlRegistration registration, required String? error, required Widget child})
const

Properties

child → Widget
finalinherited
error → String?
The field's current validation error. Carried here so a change rebuilds the control below even though the registration is the same.
final
hashCode → int
The hash code for this object.
no setterinherited
key → Key?
finalinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

animate({Duration? duration, Curve? curve, Object? trigger, bool repeat = false}) → Animate

Available on Widget, provided by the AnimateExtension extension

Starts an Animate chain over this widget. duration / curve apply to the whole chain. With no trigger it plays on mount; with a non-null trigger it rests on mount and replays whenever the token changes.
createElement() → ScopeElement<FormControlRegistration>
Creates the Element that will mount this widget into the tree.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited
updateShouldNotify(covariant FormControlScope oldWidget) → bool
Whether replacement of this widget should rebuild its readers.
override

Operators

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

Static Methods

maybeOf(BuildContext context) → FormControlRegistration?