mirror of
https://github.com/InsanusMokrassar/JSUIKitKBindings.git
synced 2024-12-22 00:27:25 +00:00
DefaultInput -> StandardInput
This commit is contained in:
parent
443043cff5
commit
6502e0923e
@ -2,6 +2,7 @@
|
||||
|
||||
## 0.6.1
|
||||
|
||||
* `DefaultInput` has been renamed to `StandardInput`
|
||||
* `Compose`: `1.3.1-rc02`
|
||||
|
||||
## 0.6.0
|
||||
|
@ -9,12 +9,12 @@ import org.jetbrains.compose.web.dom.Input
|
||||
import org.w3c.dom.HTMLInputElement
|
||||
|
||||
@Composable
|
||||
fun <T> DefaultInput(
|
||||
fun <T> StandardInput(
|
||||
type: InputType<T>,
|
||||
value: T,
|
||||
vararg modifiers: UIKitModifier,
|
||||
disabled: Boolean = false,
|
||||
placeholder: String? = null,
|
||||
vararg modifiers: UIKitModifier,
|
||||
attributesCustomizer: AttrBuilderContext<HTMLInputElement> = {},
|
||||
onChange: (T) -> Unit
|
||||
) {
|
||||
@ -41,6 +41,18 @@ fun <T> DefaultInput(
|
||||
}
|
||||
}
|
||||
|
||||
@Deprecated("Renamed", ReplaceWith("StandardInput(type, value, *modifiers, disabled, placeholder, attributesCustomizer, onChange)"))
|
||||
@Composable
|
||||
fun <T> DefaultInput(
|
||||
type: InputType<T>,
|
||||
value: T,
|
||||
disabled: Boolean = false,
|
||||
placeholder: String? = null,
|
||||
vararg modifiers: UIKitModifier,
|
||||
attributesCustomizer: AttrBuilderContext<HTMLInputElement> = {},
|
||||
onChange: (T) -> Unit
|
||||
) = StandardInput(type, value, modifiers = modifiers, disabled, placeholder, attributesCustomizer, onChange)
|
||||
|
||||
@Composable
|
||||
fun <T> StandardInput(
|
||||
type: InputType<T>,
|
||||
@ -49,12 +61,12 @@ fun <T> StandardInput(
|
||||
placeholder: String? = null,
|
||||
vararg modifiers: UIKitModifier,
|
||||
attributesCustomizer: AttrBuilderContext<HTMLInputElement> = {},
|
||||
) = DefaultInput(
|
||||
) = StandardInput(
|
||||
type,
|
||||
state.value,
|
||||
modifiers = modifiers,
|
||||
disabledState ?.value == true,
|
||||
placeholder,
|
||||
modifiers = modifiers,
|
||||
attributesCustomizer = attributesCustomizer
|
||||
) {
|
||||
state.value = it
|
||||
|
Loading…
Reference in New Issue
Block a user