textFieldFocusNode method
Retrieves the FocusNode for a given text field.
This is useful for managing focus behavior in the UI, such as moving focus to the next field.
- Parameter
fieldName: The name of the text field to get the focus node for. - Returns: The FocusNode associated with the specified text field.
Implementation
widgets.FocusNode textFieldFocusNode(String fieldName) {
final field = state.textField(fieldName);
_observeTextFieldFocus(fieldName, field.focusNode);
return field.focusNode;
}