Dither Avatar
Each person is printed in a few inks of their own colour (picked from their name, so they keep it): their photo, or their initials on a pale print while it loads or when there isn't one, the photo developing in over them when it arrives. The round edge is a stipple, a status dot sits in a gap cut into it, and under the pointer the print dissolves into the photo's own colours. DitherAvatarGroup overlaps them, each cutting a clean gap into the one beneath, with the rest counted in a +N.
Needs: None. Canvas 2D. Photos must be same-origin or CORS-enabled.
Demo photos by Jurica Koletić, Albert Dera, Jimmy Fermin and Hassan Khan on Unsplash
Customize
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| name | string | required | The person's name: initials when there's no photo, and what screen readers hear. |
| src | string | – | A photo. Same-origin or CORS-enabled. |
| status | "online" | "away" | "busy" | "offline" | – | A dot on the edge. |
| ink | string | – | The ink it's printed in. Picked from the name by default. |
| size | number | 40 | Width and height in px. |
| colourOnHover | boolean | true | Under the pointer, the print dissolves into the photo's colours. |
| className | string | – | Class on the avatar. |
| style | CSSProperties | – | Style on the avatar. |