Interface describing an action linked to a notification.

interface IAction {
    callback: (event: MouseEvent) => void;
    caption?: string;
    displayType?: ActionDisplayType;
    label: string;
}

Properties

callback: (event: MouseEvent) => void

Callback function to trigger

By default execution of the callback will close the toast and dismiss the notification. You can prevent this by calling event.preventDefault() in the callback.

caption?: string

The action caption.

This can be a longer description of the action.

displayType?: ActionDisplayType

The action display type.

This will be used to modify the action button style.

label: string

The action label.

This should be a short description.