import * as i0 from '@angular/core';
import { OnDestroy, AfterViewInit, QueryList, OnInit, Signal, EventEmitter } from '@angular/core';
import { UserState } from '@eui/core';
import { EuiDropdownComponent } from '@eui/components/eui-dropdown';
import { BehaviorSubject } from 'rxjs';
import * as i1 from '@eui/components/shared';
import { BaseStatesDirective } from '@eui/components/shared';
import { FocusableOption } from '@angular/cdk/a11y';
/**
* @description
* Individual menu item component for user profile menus. Implements FocusableOption
* for keyboard navigation support. Used within eui-user-profile-menu to create
* actionable menu entries.
*
* @usageNotes
* ### Basic Usage
* ```html
*
*
*
* My Profile
*
*
*
*
* Change Password
*
*
*
*
* Logout
*
*
* ```
*
* ### Accessibility
* - Implements ARIA menuitem role
* - Keyboard focusable with proper tabindex management
* - Supports focus() method for programmatic focus
* - Works with parent menu's keyboard navigation
*
* ### Notes
* - Must be used within eui-user-profile-menu
* - Supports any content (text, icons, badges)
* - Click events handled through standard Angular event binding
* - Focus managed by parent menu's FocusKeyManager
*/
declare class EuiUserProfileMenuItemComponent implements FocusableOption {
class: string;
tabindex: string;
role: string;
private element;
focus(): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
}
/**
* @description
* Container component for user profile menu items. Provides keyboard navigation
* and focus management for menu items within a user profile dropdown.
* Uses CDK FocusKeyManager for accessible keyboard interaction.
*
* @usageNotes
* ### Basic Usage
* ```html
*
*
*
* My Profile
*
*
* Settings
*
*
* Logout
*
*
*
* ```
*
* ### Accessibility
* - Implements ARIA menu role for proper semantics
* - Keyboard navigation with arrow keys (up/down)
* - Focus wraps from last to first item
* - Automatically focuses first item when menu opens
* - Integrates with CDK FocusKeyManager for standard behavior
*
* ### Notes
* - Must be used within eui-user-profile component
* - Automatically manages focus state of child menu items
* - Keyboard navigation activates on dropdown open
* - Use eui-user-profile-menu-item for menu entries
*/
declare class EuiUserProfileMenuComponent implements OnDestroy, AfterViewInit {
class: string;
role: string;
items: QueryList;
parent: EuiUserProfileComponent;
private focusKeyManager;
private destroy$;
onKeydown(event: any): void;
ngAfterViewInit(): void;
ngOnDestroy(): void;
subscribeToParent(): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
}
/**
* Represents an extended user profile that includes impersonation capabilities
* and organizational information.
* @extends {UserState}
*
* When using this interface with UserService, specify it as the generic type parameter:
* Example: private userService: UserService
*/
interface UserProfile extends UserState {
/** The profile of another user being impersonated, if applicable */
impersonatingUser?: UserProfile;
/** The user's function or role within the system */
function?: string;
/** The organization details associated with the user */
organisation?: {
/** The unique code identifying the organization */
code: string;
};
}
/**
* @description
* User profile component that displays user information with avatar, name, and optional dropdown menu.
* Integrates with UserService to display current user state and supports impersonation indicators.
* Provides customizable layouts for header, toolbar, or standalone usage.
* Supports avatar display with initials, status indicators, and optional menu with navigation items.
*
* @usageNotes
* ### Basic Usage
* ```html
*
*
*
*
* Profile
*
*
* Logout
*
*
*
*
*
*
* ```
*
* ### Accessibility
* - Avatar has appropriate alt text with user name
* - Dropdown menu is keyboard accessible
* - Status indicators have aria-label describing state
* - Focus management for menu navigation
*
* ### Notes
* - Automatically fetches user data from UserService
* - Supports impersonation mode with visual indicator
* - Avatar initials generated from user name when no image provided
* - Status variants: success, secondary, danger
* - Reverse layout option for right-to-left designs
*/ declare class EuiUserProfileComponent implements OnInit, OnDestroy, AfterViewInit {
get cssClasses(): string;
userState: Signal;
avatarInitials: Signal;
welcomeLabel: string;
impersonateLabel: string;
avatarUrl: string;
subInfos: string;
statusVariant: string;
hasMenu: boolean;
hasWelcomeLabel: boolean;
isShowAvatarInitials: boolean;
hasTabNavigation: boolean;
isReverse: boolean;
hasToggle: boolean;
isHeaderUserProfile: boolean;
isToolbarUserProfile: boolean;
isShowUserInfos: boolean;
isMobileOnly: boolean;
euiStatusSecondary: boolean;
euiStatusSuccess: boolean;
euiStatusDanger: boolean;
dropContentWidth: string;
/**
* If true, the name will be displayed in reverse order (first name, first)
*/
reverseNameOrder: boolean;
dropdown: EuiDropdownComponent;
hasMenuContent: QueryList;
isDropdownOpen: boolean;
baseStatesDirective: BaseStatesDirective;
$isDropdownOpen: BehaviorSubject;
private unsubscribeSubject$;
private elRef;
private cd;
private userService;
ngOnInit(): void;
ngAfterViewInit(): void;
ngOnDestroy(): void;
closeDropdown(): void;
onDropdownExpand(isOpen: boolean): void;
onOpenChange(open: boolean): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
static ngAcceptInputType_hasMenu: unknown;
static ngAcceptInputType_hasWelcomeLabel: unknown;
static ngAcceptInputType_isShowAvatarInitials: unknown;
static ngAcceptInputType_hasTabNavigation: unknown;
static ngAcceptInputType_isReverse: unknown;
static ngAcceptInputType_hasToggle: unknown;
static ngAcceptInputType_isHeaderUserProfile: unknown;
static ngAcceptInputType_isToolbarUserProfile: unknown;
static ngAcceptInputType_isShowUserInfos: unknown;
static ngAcceptInputType_isMobileOnly: unknown;
static ngAcceptInputType_euiStatusSecondary: unknown;
static ngAcceptInputType_euiStatusSuccess: unknown;
static ngAcceptInputType_euiStatusDanger: unknown;
}
/**
* @description
* User profile card component that displays detailed user information including avatar, name,
* function, and organization. Designed for use within dropdown menus or profile panels.
* Automatically fetches user data from UserService and supports impersonation display.
*
* @usageNotes
* ### Basic Usage
* ```html
*
*
*
*
*
* ```
*
* ```typescript
* onShowProfile(): void {
* this.router.navigate(['/profile']);
* }
* ```
*
* ### Accessibility
* - Avatar has semantic meaning with user initials or image
* - Profile details link is keyboard accessible with tabindex
* - User information structured with proper heading hierarchy
* - Impersonation status clearly indicated for screen readers
*
* ### Notes
* - Automatically displays user function and organization if available
* - Impersonation mode shows both impersonated and actual user
* - Avatar initials computed from user name (configurable order)
* - Integrates seamlessly with eui-user-profile dropdown
*/
declare class EuiUserProfileCardComponent implements OnInit {
get cssClasses(): string;
avatarInitials: Signal;
/**
* Holds the full name of the user and the impersonated user
*/
fullName: Signal<{
user: string;
impersonated: string;
}>;
userState: Signal;
/**
* If true, the user is online
* @deprecated This property is not used anymore
*/
isOnline: boolean;
impersonateLabel: string;
showDetailsLabel: string;
avatarUrl: string;
isShowAvatarInitials: boolean;
/**
* If true, the name will be displayed in reverse order (first name, first)
*/
reverseNameOrder: boolean;
showProfileInfo: EventEmitter;
closeProfileMenu: EventEmitter;
ngOnInit(): void;
onShowInfoClick(): void;
onClose(): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
static ngAcceptInputType_isShowAvatarInitials: unknown;
}
declare const EUI_USER_PROFILE: readonly [typeof EuiUserProfileComponent, typeof EuiUserProfileMenuComponent, typeof EuiUserProfileMenuItemComponent, typeof EuiUserProfileCardComponent];
export { EUI_USER_PROFILE, EuiUserProfileCardComponent, EuiUserProfileComponent, EuiUserProfileMenuComponent, EuiUserProfileMenuItemComponent };
export type { UserProfile };
//# sourceMappingURL=eui-components-eui-user-profile.d.ts.map