The component that displays your character and animates its mouth as it speaks.
<Avatar /> renders the avatar and keeps it in sync with the session — loading, connection status, and lip-sync are all handled for you. It reads everything it needs from the nearest AvatarProvider, so it takes no required props.
Place <Avatar /> anywhere inside AvatarProvider. Always give it a size — it fills its container, so without an explicit style size or a sized parent it won't be visible.
Always size <Avatar />. Because its root is flex: 1, inside an unsized parent it can collapse to zero height and render nothing. Pass style={{ width, height }} or wrap it in a sized View.
| Prop | Type | Default | Description |
|---|---|---|---|
styleOptional | ViewStyle | No default | Layout styles applied to the avatar's root view. Use to set width and height. |
loaderOptional | React.ReactNode | No default | Custom element shown while the avatar is resolving. Defaults to the SDK's animated connecting loader. |
errorFallbackOptional | React.ReactNode | No default | Custom element shown if the avatar fails to load at all. A session that ends after the avatar is painted keeps the avatar, so it never reaches this. |
captionStyleOptional | ViewStyle | No default | Styling hook for the caption overlay. Shown when transcript.captions is on. |
statusBannerStyleOptional | ViewStyle | No default | Styling hook for the connectivity banner. Shown when statusBanner.enabled is on. |
cameraPreviewCornerOptional | CameraPreviewCorner | "bottom-right" | Which corner the camera self-view sits in. Only applies when perception.camera is enabled. |
hideCameraPreviewOptional | boolean | false | Hide the camera self-view. Discouraged — capture continues regardless (the view stays mounted, invisible), so all this removes is the user's ability to see that it is happening. |
Whether an overlay exists at all is a provider decision (transcript,
statusBanner, perception in the config); how it looks is an Avatar
prop. Styling an overlay you never enabled does nothing.
There is no picture-in-picture layout and no fit override on React Native —
both are web-only. React Native also ships no thinking indicator; read
useAvatar().isResponseSlow and render your own.
There is no className prop on React Native. Style the container with the style prop (a ViewStyle object). To toggle the built-in start/stop buttons, set controls.enabled on <AvatarProvider> — not on <Avatar>.
The Avatar component renders three layers inside a View:
call mode when controls.enabled = true on the provider.Override the default loading indicator with your own element.
Show your own UI if the avatar fails to load (bad avatarId, no connectivity, etc.).