Home Reference Source
import Notifications from '@osjs/client/src/notifications.js'
public class | source

Notifications

Notification Factory

Constructor Summary

Public Constructor
public

constructor(core: Core)

Member Summary

Public Members
public

$element: Element

public

Core instance reference

Method Summary

Public Methods
public

Create a new notification

public

createElementStyles(): {property: string}

Creates a new CSS style object

public

Destroy notification handler

public

init()

Initialize notification handler

public

Sets the element styles

Public Constructors

public constructor(core: Core) source

Params:

NameTypeAttributeDescription
core Core

OS.js Core instance reference

Public Members

public $element: Element source

public core: Core source

Core instance reference

Public Methods

public create(options: NotificationOptions): Notification source

Create a new notification

Params:

NameTypeAttributeDescription
options NotificationOptions

See notification class for options

Return:

Notification

public createElementStyles(): {property: string} source

Creates a new CSS style object

Return:

{property: string}

public destroy() source

Destroy notification handler

public init() source

Initialize notification handler

public setElementStyles() source

Sets the element styles