Photonix

UserMenu

Dropdown menu for user profile and settings.

Preview

J
Jane Cooper@jane
Usage
"use client";

import { Box, UserMenu } from '@photonix/ultimate';
import { ExitOutline, SettingsOutline, UserOutline } from '@photonix/icons';

const actions = [
    { value: 'profile', label: 'Profile', icon: <UserOutline /> },
    { value: 'settings', label: 'Settings', icon: <SettingsOutline />, divider: true },
    { value: 'sign-out', label: 'Sign out', icon: <ExitOutline /> },
];

export default function UserMenuBasicExample() {
    return (
        <Box w={320} maxW="100%">
            <UserMenu userName="Jane Cooper" userHandle="@jane" actions={actions} />
        </Box>
    );
}

Component API

UserMenu

Prop
Type
Default
Description
userName
string
-
User display name
userHandle
string
-
User handle/username (e.g.,
avatarSrc
string
-
URL of user avatar image
actions
UserMenuAction[]
-
Menu action items - same structure as DropdownListItem
onActionSelect
((value: string) => void)
-
Callback when an action is selected
onUserClick
(() => void)
-
Callback when user info section is clicked
className
string
-
Additional CSS class
style
React.CSSProperties
-
Additional inline styles

On this page

Preview
Component API
Photonix UI - React Components, Templates & Figma Design System