Skip to main content

foundation-notifications.notifycontainerconfig

Home > @genesislcap/foundation-notifications > NotifyContainerConfig

NotifyContainerConfig interface

Signature:

export interface NotifyContainerConfig 

Properties

Property

Modifiers

Type

Description

allowCloseAll

boolean

Whether to show the Close All button in the header.

allowManualCollapse

boolean

Whether to show the Expand/Collapse button in the header.

designSystemPrefix

string

The design system prefix used to resolve child component tag names (e.g. buttons, icons).

notificationInterval

number

When set, notifications added simultaneously are revealed one-by-one with this delay (in ms) between each. Auto-close timers on individual notifications only begin once they are shown. Setting this to 0 disables queuing.

When NotifyContainerConfig.sortFn is also set, each incoming notification that would not appear at the front of the collapsed stack will briefly peek at the front for half the interval duration before animating to its sorted position, making it visible to the user before it settles.

position

ToastPosition

The corner of the screen where notifications appear. Note: bottom-left and bottom-right are not currently supported.

showCount

boolean

Whether to show the notification count in the header.

sortFn?

(a: HTMLElement, b: HTMLElement) => number

(Optional) An optional comparator function to sort visible notifications. Follows the same signature as Array.sort — return a negative number to sort a before b (i.e. higher in the stack). Re-applied automatically whenever the set of visible notifications changes. See sortNotificationBySeverity() for a ready-made example.

stackThreshold

number

The number of visible notifications that triggers the stack to auto-collapse.