Skip to main content

Notification

Namespace: Wisej.Web.Ext.Notification

Assembly: Wisej.Web.Ext.Notification

Adds support for the Notification API: notification.

public class Notification : Component

Constructors

Instance memberNotification()

Initializes a new instance of the Notification class.

Instance memberNotification(container)

Initializes a new instance of the Notification class together with the specified container.

NameTypeDescription
containerIContainerA IContainer that represents the container for the component.

Properties

Static memberIsSupported

Boolean: Returns whether the client browser supports desktop notifications.

Methods

Instance memberShow(title, body, icon, showOnClick, image, id, requireInteraction)

Displays a new desktop notification.

ParameterTypeDescription
titleStringThe title of the notification.
bodyStringThe optional body string of the notification.
iconStringThe URL of the image used as an icon of the notification.
showOnClickBooleanIndicates whether to activate the browser when the user clicks the notification.
imageStringURL of an image to show at the top of the notification window.
idStringOptional unique id, returned in NotificationClickEventArgs.
requireInteractionBooleanIndicates that a notification should remain active until the user clicks or dismisses it, rather than closing automatically.

Events

Instance memberClick

NotificationClickEventHandler Fired when the user clicks on a desktop notification.