UI Toolbox logoUI Toolbox
Support

AvatarGroup

An AvatarGroup is a row of UserAvatars that overlap. With a maximum, it shows the first avatars and a "+N" count for the rest.

A Your party card with four overlapping avatars (MV, BS, TH, KA), the name Night Owls and the count 4 heroesA Your party card with four overlapping avatars (MV, BS, TH, KA), the name Night Owls and the count 4 heroes

How to show the members of a team:

<tb:AvatarGroup name="team" max-visible="3">
    <tb:UserAvatar display-name="Ada Lovelace" />
    <tb:UserAvatar display-name="Grace Hopper" />
    <tb:UserAvatar display-name="Alan Turing" />
    <tb:UserAvatar display-name="Linus Torvalds" />
    <tb:UserAvatar display-name="Margaret Hamilton" />
</tb:AvatarGroup>
var team = root.Q<AvatarGroup>("team");
team.Add(new UserAvatar { DisplayName = "Katherine Johnson" });
team.Refresh();
Member Description
MaxVisible (max-visible) The most avatars to show. The rest shows as a "+N" count. 0 (the default) shows all avatars.
Refresh() Shows the first MaxVisible avatars and the count again. Call it after you add or remove an avatar from code.

Tips:

In the examples

Styling

Class Element
tb-avatar-group The row. Each child overlaps the child before it by 8 px.
tb-avatar-group__more The count: a circle in --tb-color-surface-alt with bold small text. Hidden when all avatars show.
.tb-avatar-group .tb-avatar__image,
.tb-avatar-group__more { border-color: var(--tb-color-background); }

The AvatarGroupDemo scene shows a party with each hero, a match lobby with a count of the other players, raids that show who signed up, and looks of the group in USS.