MessageInput

fun MessageInput(messageComposerState: MessageComposerState, onValueChange: (String) -> Unit, onAttachmentRemoved: (Attachment) -> Unit, modifier: Modifier = Modifier, maxLines: Int = DefaultMessageInputMaxLines, keyboardOptions: KeyboardOptions = KeyboardOptions(capitalization = KeyboardCapitalization.Sentences), label: @Composable (MessageComposerState) -> Unit = { DefaultComposerLabel(ownCapabilities = messageComposerState.ownCapabilities) }, innerLeadingContent: @Composable RowScope.() -> Unit = {}, innerTrailingContent: @Composable RowScope.() -> Unit = {})

Input field for the Messages/Conversation screen. Allows label customization, as well as handlers when the input changes.

Parameters

messageComposerState

The state of the input.

onValueChange

Handler when the value changes.

onAttachmentRemoved

Handler when the user removes a selected attachment.

modifier

Modifier for styling.

maxLines

The number of lines that are allowed in the input.

keyboardOptions

The KeyboardOptions to be applied to the input.

label

Composable that represents the label UI, when there's no input.

innerLeadingContent

Composable that represents the persistent inner leading content.

innerTrailingContent

Composable that represents the persistent inner trailing content.