This is beta documentation for Stream Chat React Native SDK v9. For the latest stable version, see the latest version (v8) .

OnlineIndicator

OnlineIndicator renders a small circular dot indicating a user's online or offline presence status. It is used internally by UserAvatar and UserAvatarGroup to overlay presence information on avatars.

The indicator color is green when online and grey when offline, both sourced from the theme's semantic tokens.

Usage

import { OnlineIndicator } from "stream-chat-react-native";

<OnlineIndicator online={true} size="md" />;

Props

online (required)

Whether the user is currently online. Controls the background color of the indicator.

Type
boolean

size (required)

The size of the indicator dot.

TypeValues
string'xl' | 'lg' | 'md' | 'sm'

Size mapping:

SizeDimensionsBorder Width
xl16 × 162
lg14 × 142
md12 × 122
sm8 × 81