Summary
Functions
Attributes
src(:string) - hosted avatar URL. Defaults tonil.alt(:string) - alt text for avatar image. Defaults tonil.size(:string) - Defaults to"md". Must be one of"xs","sm","md","lg", or"xl".class(:any) - CSS class. Defaults tonil.name(:string) - name for placeholder initials. Defaults tonil.random_color(:boolean) - generates a random color for placeholder initials avatar. Defaults tofalse.random_gradient(:boolean) - generates a gradient background for placeholder initials, hashed from the name like random_color - same name, same gradient. Wins over random_color when both are set. Defaults tofalse.art(:string) - generative art instead of initials: mesh is a soft multi-hue gradient, dither an ordered-dither blend - both hashed from the name, so the same name always draws the same avatar. Pure art by default; the name still labels the avatar for screen readers, and a photo src wins when present. Defaults tonil. Must be one ofnil,"mesh", or"dither".initials(:boolean) - mesh only: overlay the monogram on the art as a dark hue-tinted monogram (the mesh reads light, so it always contrasts). Ignored for dither - a discrete pixel pattern never lets text sit cleanly, so dither stays pure art. Defaults tofalse.shape(:string) - circle is the convention for people; rounded (proportional soft corners) suits orgs, teams and workspaces. Deliberately independent of the --pc-radius dial - avatars are identity, not surface, and a sharp-cornered theme still wants soft avatars. Defaults to"circle". Must be one of"circle", or"rounded".status(:string) - presence dot on the bottom-right corner, ringed to separate from the image. Defaults tonil. Must be one ofnil,"online","offline","busy", or"away".- Global attributes are accepted.
Attributes
size(:string) - Defaults to"md". Must be one of"xs","sm","md","lg", or"xl".class(:any) - CSS class. Defaults tonil.avatars(:list) - list of your hosted avatar URLs. Defaults to[].max(:integer) - show at most this many avatars, then a +N overflow bubble for the rest. Defaults tonil.shape(:string) - shape passed through to every avatar and the +N bubble. Defaults to"circle". Must be one of"circle", or"rounded".- Global attributes are accepted.