Controller
Deprecated
Please migrate to the new form implementation. This legacy code will be removed in a future version.
A controller for a form field control.
To minimize the impact of re-composition due to updates in input values, the FieldControl is passed to a Controller, which then connects the actual input component with the Field interface.
Usage:
Form(..) {
..
Controller(control = rememberFirstNameFieldControl()) { field ->
TextField(value = field.value, onValueChange = field.onChange, ...)
}
}
Parameters
The type of the field value.
The field control to be managed.
The content to be displayed.
Deprecated
Please migrate to the new form implementation. This legacy code will be removed in a future version.
A controller for a form submission control.
To minimize the impact of re-composition due to updates in input values, the SubmissionControl is passed to a Controller, which then connects the actual input component with the Submission interface.
Usage:
Form(..) {
..
Controller(control = rememberSubmissionRuleAutoControl()) { submission ->
Button(onClick = submission.onSubmit, enabled = submission.canSubmit, ...)
}
}
Parameters
The type of the submission value.
The submission control to be managed.
The content to be displayed.