Skip to content
Components64 / 118

Avatar Dock

A round plus that springs open into a column of people. Press it and the plus turns into a minus while a pill springs up out of it and avatars pop in one after another, bottom to top. Glide over them and they swell like a dock, with each person's name sliding out beside them; press again and they leave top first as the pill sinks back into the button.

Expanding buttonAvatarsDock magnifyElasticKeyboardGSAP
Press the plusGlide over the people

Tweak

LIVE

Shape

46px

Names slide out

Colours

#dcdcdc
#8e8e8e
#1a1a1a

Props

10 props
  • people{ name; role?; src; focus? }[]
    The people: name, role, photo, and where their face sits (object-position).
  • sizenumber
    Button diameter, px.default 46
  • surfacestring
    The pill.default "#dcdcdc"
  • buttonstring
    The round button.default "#8e8e8e"
  • inkstring
    The plus / minus.default "#1a1a1a"
  • labelSide"left" | "right"
    Which side the name slides out on.default "right"
  • defaultOpenboolean
    Start open.default false
  • onOpenChange(open) => void
    Called when it opens or closes.
  • onSelect(person, index) => void
    Called when a person is clicked.
  • classNamestring
    Extra classes.