mirror of
https://github.com/InsanusMokrassar/JSUIKitKBindings.git
synced 2024-12-22 00:27:25 +00:00
value in StandardInput is nullable
This commit is contained in:
parent
1eb14becde
commit
8178fa9d39
@ -11,7 +11,7 @@ import org.w3c.dom.HTMLInputElement
|
|||||||
@Composable
|
@Composable
|
||||||
fun <T> StandardInput(
|
fun <T> StandardInput(
|
||||||
type: InputType<T>,
|
type: InputType<T>,
|
||||||
value: T,
|
value: T? = null,
|
||||||
vararg modifiers: UIKitModifier,
|
vararg modifiers: UIKitModifier,
|
||||||
disabled: Boolean = false,
|
disabled: Boolean = false,
|
||||||
placeholder: String? = null,
|
placeholder: String? = null,
|
||||||
@ -24,7 +24,7 @@ fun <T> StandardInput(
|
|||||||
|
|
||||||
placeholder ?.let(::placeholder)
|
placeholder ?.let(::placeholder)
|
||||||
|
|
||||||
value.let {
|
value ?.let {
|
||||||
when (it) {
|
when (it) {
|
||||||
is String -> value(it)
|
is String -> value(it)
|
||||||
is Number -> value(it)
|
is Number -> value(it)
|
||||||
|
Loading…
Reference in New Issue
Block a user