import { ErrorBadge } from "stream-chat-react-native";
<ErrorBadge size="md" />;This is beta documentation for Stream Chat React Native SDK v9. For the latest stable version, see the latest version (v8)
.
ErrorBadge
ErrorBadge renders a small circular error indicator with an exclamation mark icon. It is used to signal error states on messages, uploads, or other UI elements that need visual error feedback.
The badge uses the badgeBgError semantic token for its background color, ensuring consistent error styling across the SDK.
Usage
Props
size (required)
The size of the error badge.
| Type | Default | Values |
|---|---|---|
| string | 'md' | 'xs' | 'sm' | 'md' |
Size mapping:
| Size | Dimensions | Icon Size (w × h) |
|---|---|---|
xs | 16 × 16 | 2 × 8 |
sm | 20 × 20 | 2 × 9 |
md | 24 × 24 | 3 × 11 |
style
Additional style applied to the badge container.
| Type |
|---|
StyleProp<ViewStyle> |
ErrorBadge also accepts all standard React Native ViewProps which are spread onto the outer View container.