Replies: 1 comment
-
I'm not sure what type your |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have defined BasicTextField Widget
schema
@widget(9)
data class BasicTextField (
@Property(1) val value: String,
@Property(2) val onValueChange: ((String) -> Unit)? = null,
@children(1) val decorationBox: (() -> Unit) = {}
)
Compose UI implementation -
BasicTextField (
modifier = androidModifier.focusRequester(FocusRequester()),
value = textFieldValue.copy(
text = state.text,
selection = TextRange(state.selectionStart, state.selectionEnd),
),
onValueChange = { newValue :TextFieldValue ->
textFieldValue = newValue
stateChanged(newValue)
},
when i pass decorationBox as Children , it wont take input while writing same code in Compose UI works.
param- decorationBox: @composable (innerTextField: @composable () -> Unit) -> Unit
am i doing some wrong thing here?
Beta Was this translation helpful? Give feedback.
All reactions