### File

`packages/components/layout/eui-notifications-v2/eui-notification-item.component.ts`

### Description

Enhanced individual notification item component (v2) displaying a single notification with read/unread status and actions. Renders notification content with icon, label, date, and optional mark as read button. Supports internal and external links with visual indicators for unread and important notifications. Emits events for item clicks and mark as read actions to parent notification panel. Improved version with enhanced styling and behavior compared to EuiNotificationItemComponent.

### Metadata

selector | `eui-notification-item-v2`
imports | `NgClass` `DatePipe` `EuiTruncatePipe` `TranslateModule` `EUI_ICON`
templateUrl | `./eui-notification-item.component.html`

### Index

###### Properties

- string
- tooltipSize

###### Methods

- onItemClick
- onItemMarkAsRead

###### Inputs

- dateFormat
- isShowMarkAsRead
- item
- markAsReadLabel

###### Outputs

- itemClick
- itemMarkAsRead

###### HostBindings

- class

###### Accessors

- iconColor

### Inputs

dateFormat
Type : `string`
Default value : `'dd/MM/yyyy'`
Date format string for displaying the notification timestamp. Accepts any valid Angular DatePipe format pattern.

isShowMarkAsRead
Type : `boolean`
Default value : `true`
Shows the mark as read action button on the notification item. When false, hides the mark as read functionality.

item
Type : `UxLinkLegacy<NotificationMetadata>`
Notification item data containing label, metadata, and link information. Must conform to UxLinkLegacy<NotificationMetadata> interface with id, label, and metadata properties. Required for notification display.

markAsReadLabel
Type : `string`
Default value : `null`
Custom label text for the mark as read button. When null, uses default translation key. Optional.

### Outputs

itemClick
Type : `EventEmitter<UxLinkLegacy>`
Emitted when the notification item is clicked. Payload: UxLinkLegacy - the clicked notification item with metadata Triggered when user clicks anywhere on the notification item.

itemMarkAsRead
Type : `EventEmitter<UxLinkLegacy>`
Emitted when the mark as read button is clicked. Payload: UxLinkLegacy - the notification item marked as read Triggered when user clicks the mark as read action button. Automatically sets item.metadata.read to true.

### HostBindings

class
Type : `string`
Default value : `'eui-notification-item'`

### Methods

onItemClick
`onItemClick()`
Returns : `void`

onItemMarkAsRead
`onItemMarkAsRead(event: Event)`

Parameters :

Name | Type | Optional
event | `Event` | No

Returns : `void`

### Properties

string
Type : `string`
Default value : `'eui-notification-item'`
Decorators : `@HostBinding('class')`

tooltipSize
Type : `string`
Default value : `'auto'`

### Accessors

iconColor
get `iconColor()`

# results matching ""

# No results matching ""