Skip to main content

Common Examples

To use the AgentMessage, pass content and a required timestamp. The row left-aligns the content and reserves an inline-end gutter. The kit forbids children.
content accepts a string or composed React Native nodes. Copy is text-only: pass copyText when content is rich so the copy action stays available. The kit does not write to the clipboard. Provide onCopy to show the copy control.

Feedback

Wire onLike and onDislike to show thumbs. The component reflects currentFeedback; toggling is yours.
Omit both handlers to hide feedback entirely.

Hiding the toolbar

Set showToolbar={false} for a host with no copy/feedback surface of its own — the timestamp and action row are omitted entirely rather than rendering a bare timestamp.

Accessibility

  • Actions are grouped in a toolbar region named “Response actions”. The group renders only when there is at least one action.
  • The timestamp sits outside that group — a toolbar groups controls, and a timestamp is not one.
  • With showToolbar={false}, neither the timestamp nor the action group is present in the accessibility tree.
  • Action buttons are 40x40 for touch.
  • Feedback buttons announce like, dislike, and selected state.
  • Built-in toolbar labels are English until the kit gains an i18n layer.
Last modified on September 8, 2026