Submission

interface Submission

A submission represents the submission control of a form.

Properties

Link copied to clipboard
abstract val canSubmit: Boolean

Returns true if the form can be submitted, false otherwise. This is useful when you want to disable the submit button itself until field validation errors are resolved.

Link copied to clipboard
abstract val hasError: Boolean

Returns true if the form has validation error, false otherwise. A form is error if any of its fields has validation error.

Link copied to clipboard
abstract val isDirty: Boolean

Returns true if the field is dirty, false otherwise. A form value is dirty if its value has changed since the initial value.

Link copied to clipboard
abstract val isSubmitted: Boolean

Returns true if the form is submitted, false otherwise.

Link copied to clipboard
abstract val isSubmitting: Boolean

Returns true if the form is submitting, false otherwise. This is useful to prevent duplicate submissions until the submission process is completed.

Link copied to clipboard
abstract val onSubmit: () -> Unit

A callback to notify that the submit button has been clicked.

Link copied to clipboard
abstract val submitCount: Int

Returns the number of times submission process was called.