From 8178fa9d397ef9204c1a96036f42972dc9dbd439 Mon Sep 17 00:00:00 2001 From: InsanusMokrassar Date: Sun, 5 Mar 2023 18:50:59 +0600 Subject: [PATCH] value in StandardInput is nullable --- src/jsMain/kotlin/dev/inmo/jsuikit/elements/StandardInput.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/jsMain/kotlin/dev/inmo/jsuikit/elements/StandardInput.kt b/src/jsMain/kotlin/dev/inmo/jsuikit/elements/StandardInput.kt index 320c642..3361d99 100644 --- a/src/jsMain/kotlin/dev/inmo/jsuikit/elements/StandardInput.kt +++ b/src/jsMain/kotlin/dev/inmo/jsuikit/elements/StandardInput.kt @@ -11,7 +11,7 @@ import org.w3c.dom.HTMLInputElement @Composable fun StandardInput( type: InputType, - value: T, + value: T? = null, vararg modifiers: UIKitModifier, disabled: Boolean = false, placeholder: String? = null, @@ -24,7 +24,7 @@ fun StandardInput( placeholder ?.let(::placeholder) - value.let { + value ?.let { when (it) { is String -> value(it) is Number -> value(it)