Skip to main content

Avatar

Data Display

Avatar

Circular avatar that falls back to initials or icons when images fail.

Usage

Represent people, organizations, or shared resources in lists and detail views.

Highlights

  • Automatic initials extraction with emoji support
  • Icon fallback for service badges

When to use it

  • User data includes optional profile imagery.
  • You need deterministic placeholders for offline usage.

Examples

Default

Preview (Web)
import { Avatar } from 'react-native-molecules/components/Avatar';

export default function Example() {
  const source = {
      uri: 'https://www.eyerys.com/sites/default/files/mark_zuckerberg.jpg'
  };

  return <Avatar size={60} label="Thet Aung" source={source} />;
}
PropTypeDefaultDescription
sourceImageSourcePropType | undefined
iconNamestring | undefined
iconType"material-community" | "feather" | undefined
iconPropsOmit<IconProps, "ref" | "name" | "type"> | undefined
labelstring | undefined
labelPropsOmit<TextProps, "children"> | undefined
imagePropsOmit<ImageProps, "source"> | undefined
colorstring | undefined
sizestring | number | undefined
Defined in react-native-molecules/components/Avatar