Skip to content

Avatar items

The DropdownMenu component supports avatar items using the DropdownMenu.AvatarItem component. This allows you to create items with avatars that can be used to represent users or other entities.

Properties

AvatarItem

The AvatarItem component is a specialized item that displays an avatar.

<DropdownMenu.AvatarItem
src="/avatar.png" // avatar image source
title="Item title" // title of the item
rounded // [OPTIONAL] rounded avatar
description="Description" // [OPTIONAL] description text
label="Label" // [OPTIONAL] right-aligned label
shortcut="⌘K" // [OPTIONAL] keyboard shortcut
checkmark // [OPTIONAL] show checkmark icon
className="my-class" // [OPTIONAL] custom class
disabled // [OPTIONAL] disable the item
onSelect={onSelect} // [OPTIONAL] event handler
>
{/* Optional nested items for submenu */}
</DropdownMenu.AvatarItem>
Prop
Required
Default
Type
srcfalsestring
roundedfalsetrueboolean
titletrueReactNode
descriptionfalsestring
labelfalsestring
shortcutfalsestring
checkmarkfalsefalseboolean
tagfalseTagProps
classNamefalsestring
disabledfalsefalseboolean
onSelectfalse(event: Event) => void
childrenfalseReactNode