Ai textarea

AI textarea with a send button and optional attachment and voice input buttons

Contents

Invalid submissions always keep focus so the user can correct the textarea. With keepKeyboardOpenOnValidSubmit, valid submissions keep focus too.

By default, invalid submissions still keep focus, while valid submissions move focus to the button and close the virtual keyboard.

Inputs in Keep keyboard open on valid submit
buttonText ?: string = ''

Submit expands to a labelled pill once `minCharacters` is reached.

keepKeyboardOpenOnValidSubmit ?: boolean = false

Keeps the virtual keyboard open after a valid submit. Invalid submits always keep it open so the user can correct the textarea or attachments.

Also set in this example
control : FormControl<string>
placeholder ?: string = ''
Outputs
onAttachmentsClick ?: any = new EventEmitter<void>()
onBlur ?: any = new EventEmitter<void>()
onFocus ?: any = new EventEmitter<void>()
onInputHandled ?: any = new EventEmitter<void>()
onSkip ?: any = new EventEmitter<void>()
onSubmit ?: any = new EventEmitter<void>()
onVoiceInputClick ?: any = new EventEmitter<void>()