Mobile › Display
Avatar
A person's photo, or their initials on a colour picked from their name so each person keeps one colour.
Installation
npx expo install plankui-mobile react-native-safe-area-context expo-hapticsUsage
import { Avatar } from "plankui-mobile";
<Avatar name="Ada Park" />
<Avatar name="Ravi Menon" uri="https://example.com/ravi.jpg" size={56} />iOS and Android
iOS: A circle, as in Contacts.
Android: A circle, as in Material lists.
API reference
| Prop | Type | Default | Description |
|---|---|---|---|
| name | string | Used for initials, colour and the screen-reader label. | |
| uri | string | – | Photo URL. |
| size | number | 40 | Diameter. |