StringFormControl

Base interface of a form control with a text value.

Inheritors

Properties

Link copied to clipboard
abstract var customValidity: String?

The custom validity of the HTML element.

Link copied to clipboard
abstract val mutableStateFlow: MutableStateFlow<String?>

A mutable state flow view of the component's state

Link copied to clipboard
abstract val required: Boolean?

Determines if the field is required.

Link copied to clipboard
abstract val stateFlow: StateFlow<String?>

A state flow view of the component's state

Link copied to clipboard
abstract override var value: String?

Generic value.

Link copied to clipboard
abstract val visible: Boolean

Determines if the field is visible.

Functions

Link copied to clipboard
abstract fun blur()

Blur the form control.

Link copied to clipboard
@Composable
fun <T> WithStateFlow<T>.collectAsState(context: CoroutineContext = EmptyCoroutineContext): State<T>

Collects values from this component and represents its latest value via State. The StateFlow.value is used as an initial value. Every time there would be new value posted into the StateFlow the returned State will be updated causing recomposition of every State.value usage.

Link copied to clipboard
abstract fun focus()

Focus the form control.

Link copied to clipboard
open fun getValue(): Any?

Returns the value of the form control.

Link copied to clipboard
abstract fun getValueAsString(): String?

Returns the value as a string.

Link copied to clipboard
open fun setValue(value: Any?)

Sets the value of the form control.