Skip to main content

Common Examples

To use the PromptBar, pass controlled value and onChange. The Send button stays disabled until onSend is wired. Sending is allowed when the draft has trimmed text, unless you override canSend.
The editor grows until maxRows (default 8), then it scrolls.

Stop

While isSending is true, sending is withheld. Wire onStop to surface Stop instead of Send.

Voice

The kit does not record or transcribe. Wire onStartVoice to show a mic. Drive voiceState ("idle", "listening", "transcribing") from the host. Pass audioLevel (0–1) while listening and transcript while transcribing. Wire onAcceptVoice and onCancelVoice to show those listening-row controls.
Attachments and the web waveform are not part of the React Native surface yet.

Disclaimer

Pass a plain-string disclaimer to show fine print under the bar. Omit it to hide the line. Rich-text and link support are not ported.

Disabled

disabled disables the editor, send, and mic.Built-in action labels (sendLabel, stopLabel, startVoiceLabel, and the voice-row labels) default to English. Override them for localized copy.

Accessibility

  • placeholder is the editor’s accessible name.
  • While listening, listeningLabel is announced through a polite live region because the level meter is decorative.
  • While transcribing, transcribingLabel names the row until transcript arrives.
  • Send, Stop, mic, accept, and cancel use the corresponding label props as accessible names.
Last modified on September 1, 2026