INotificationsListComponentProps
Props for the NotificationsList component.
export interface INotificationsListComponentProps
Properties
Property | Modifiers | Type | Description |
|---|---|---|---|
(Optional) Loaded notifications relevant to the active view. | |||
Active view of the notifications list. | |||
() => void | Callback function to close the notifications panel. | ||
(Optional) Error to display. | |||
boolean | Whether there is a next page of notifications. | ||
number | Height of the notification item in pixels. | ||
number | Padding of the notification item (from left/right) in pixels. | ||
number | Gap between notification items in pixels. | ||
() => void | Load next page of notifications. | ||
(notificationId: string) => Promise<void> | Callback function to mark notification as read. | ||
number | (Optional) Maximum height of the notifications list in pixels. | ||
ComponentType<INotificationComponentProps> | Component to render each notification. | ||
ComponentType<INotificationSkeletonItemComponentProps> | Component to render each skeleton item. | ||
ComponentType<INotificationsListEmptyStateComponentProps> | Component to render when the notifications list is empty. | ||
ComponentType<INotificationsListErrorStateComponentProps> | Component to render when the notifications list is in error state. | ||
(notification: INotification) => void | (Optional) Callback function to handle notification click. | ||
number | Number of skeleton items to render when loading notifications. | ||
Status of the notifications list. |
Property details
INotificationsListComponentProps.activeNotificationsproperty
Loaded notifications relevant to the active view.
activeNotifications?: INotification[];
INotificationsListComponentProps.activeViewproperty
Active view of the notifications list.
activeView: INotificationsPanelView;
INotificationsListComponentProps.closeNotificationsPanelproperty
Callback function to close the notifications panel.
closeNotificationsPanel: () => void;
INotificationsListComponentProps.errorproperty
Error to display.
error?: GoodDataSdkError;
INotificationsListComponentProps.hasNextPageproperty
Whether there is a next page of notifications.
hasNextPage: boolean;
INotificationsListComponentProps.itemHeightproperty
Height of the notification item in pixels.
itemHeight: number;
INotificationsListComponentProps.itemPaddingproperty
Padding of the notification item (from left/right) in pixels.
itemPadding: number;
INotificationsListComponentProps.itemsGapproperty
Gap between notification items in pixels.
itemsGap: number;
INotificationsListComponentProps.loadNextPageproperty
Load next page of notifications.
loadNextPage: () => void;
INotificationsListComponentProps.markNotificationAsReadproperty
Callback function to mark notification as read.
markNotificationAsRead: (notificationId: string) => Promise<void>;
INotificationsListComponentProps.maxListHeightproperty
Maximum height of the notifications list in pixels.
maxListHeight?: number;
INotificationsListComponentProps.Notificationproperty
Component to render each notification.
Notification: ComponentType<INotificationComponentProps>;
INotificationsListComponentProps.NotificationSkeletonItemproperty
Component to render each skeleton item.
NotificationSkeletonItem: ComponentType<INotificationSkeletonItemComponentProps>;
INotificationsListComponentProps.NotificationsListEmptyStateproperty
Component to render when the notifications list is empty.
NotificationsListEmptyState: ComponentType<INotificationsListEmptyStateComponentProps>;
INotificationsListComponentProps.NotificationsListErrorStateproperty
Component to render when the notifications list is in error state.
NotificationsListErrorState: ComponentType<INotificationsListErrorStateComponentProps>;
INotificationsListComponentProps.onNotificationClickproperty
Callback function to handle notification click.
onNotificationClick?: (notification: INotification) => void;
INotificationsListComponentProps.skeletonItemsCountproperty
Number of skeleton items to render when loading notifications.
skeletonItemsCount: number;
INotificationsListComponentProps.statusproperty
Status of the notifications list.
status: UseCancelablePromiseStatus;