Eidetic

User Profile Dropdown

Navigation
Block

A complete account menu block built on DropdownMenu — avatar header, plan badge, primary actions, and sign out.

Preview

Default user profile dropdown with primary, secondary, and sign-out sections

JV

Jens van der Berg

jens@example.com

Pro

Plan Tiers

Badge the plan beside the user's name — Pro, Enterprise, or hide entirely for Free

AK

Alex Kim

alex@example.com

JV

Jens van der Berg

jens@example.com

Pro
SJ

Sarah Johnson

sarah@acme.com

Enterprise

With Notification Badges

Menu items can surface counts — useful for notifications or pending actions

JV

Jens van der Berg

jens@example.com

Pro

Custom Items

Override primary and secondary items entirely with your own icons, labels, and handlers

JV

Jens van der Berg

jens@example.com

Pro

Minimal

Hide secondary items and sign-out for a compact account card

JV

Jens van der Berg

jens@example.com

Pro

Props

Component API reference

UserProfileDropdown

PropTypeDefaultDescription
userUserInfoUser information (name, email, avatar, plan)
menuItemsMenuItem[]Primary menu items — Profile, Settings, etc.
secondaryItemsMenuItem[]Secondary items like Help and Docs
showSignOutbooleantrueShow the destructive sign-out row
onSignOut() => voidCallback when sign out is clicked
classNamestringAdditional CSS classes on the container

UserInfo

PropTypeDefaultDescription
name*stringUser's full name
email*stringUser's email address
avatarstringAvatar image URL
initialsstringFallback initials when no avatar
planstringBadge label beside name — e.g. 'Pro'

MenuItem

PropTypeDefaultDescription
icon*LucideIconIcon component rendered at the start
label*stringItem label
badgenumber | stringOptional count or tag rendered at the end
onClick() => voidClick handler

Usage

Import and implementation examples

import { UserProfileDropdown } from '@/blocks/navigation/user-profile-dropdown'
import { User, Settings, CreditCard, Bell } from 'lucide-react'
// Default
<UserProfileDropdown />
// With a Pro user
<UserProfileDropdown
user={{
name: 'Jens van der Berg',
email: 'jens@example.com',
initials: 'JV',
plan: 'Pro',
}}
/>
// With custom menu items and notification badge
const menuItems = [
{ icon: User, label: 'Profile', onClick: () => router.push('/profile') },
{ icon: Settings, label: 'Settings', onClick: () => router.push('/settings') },
{ icon: CreditCard, label: 'Billing', onClick: () => router.push('/billing') },
{ icon: Bell, label: 'Notifications', badge: 12 },
]
<UserProfileDropdown
user={user}
menuItems={menuItems}
onSignOut={() => signOut()}
/>
// Minimal — no secondary items or sign-out
<UserProfileDropdown
user={user}
secondaryItems={[]}
showSignOut={false}
/>

Built With

4 components

This block uses the following UI components from the design system:

Features

Built-in functionality

  • User header: Avatar, name, email, and plan badge
  • Plan badges: Highlight Pro, Enterprise, or custom tiers
  • Primary menu: Profile, Settings, Billing, Notifications
  • Secondary section: Help, docs, or any supporting links
  • Notification badges: Inline counts on any menu item
  • Destructive sign-out: Dedicated danger-styled row
  • Gradient avatar fallback: Initials rendered on indigo-to-teal
  • Dark mode: Full dark mode support

Accessibility

Accessibility considerations

ARIA Attributes

Built on DropdownMenu with role="menu"Each item uses role="menuitem"aria-haspopup on the triggeraria-expanded reflects open state

Keyboard Navigation

KeyAction
Enter/SpaceOpen dropdown / activate item
EscapeClose dropdown
Arrow Up/DownNavigate items
TabMove to next focusable element

Notes

  • Focus is trapped within the open dropdown
  • Screen reader announces user name, email, and plan
  • Badge counts are announced with item labels