A fully hydrated form of the NotificationOptions.
Event fired whenever the Notification has been clicked.
This will not fire in cases of non-buttons being clicked. See NotificationClickedEvent.
Event fired whenever the Notification has been clicked on.
This will not fire in cases of Notification Buttons being clicked. See NotificationButtonClickedEvent.
Event fired whenever the Notification has been closed.
Clears a specific Notification from the Notification Center.
Returns true if the Notification was successfully cleared. Returns false if the Notification was not cleared, without errors.
import {clear} from 'openfin-notifications';
clear("uniqueNotificationId");
ID of the Notification to clear.
Clears all Notifications which were created by the calling application, including child windows.
Returns the number of successfully cleared Notifications.
import {clearAll} from 'openfin-notifications';
clearAll();
Creates a new Notification.
The Notification will appear in the Notification Center and as a toast if the Center is not visible.
If a Notification is created with an id
of an already existing Notification, the existing Notification will be recreated with the new content.
import {create} from 'openfin-notifications';
create({
id: "uniqueNotificationId",
body: "I'm the Notification body text",
icon: "https://openfin.co/favicon.ico"
});
Notification configuration options.
Retrieves all Notifications which were created by the calling application, including child windows.
import {getAll} from 'openfin-notifications'
getAll()
.then(console.log);
Toggles the visibility of the Notification Center.
import {toggleNotificationCenter} from 'openfin-notifications';
toggleNotificationCenter();
User-defined context data that can be attached to Notifications.