new SystemBanner()
SystemBanner displays a type of notification to the user in certain cases.
SystemBanner displays a type of notification to the user in certain cases. It is a type of temporary notification that does not live in the notifications tray. Examples of the SystemBanner implementation include application installation, crash reporter, and low storage notices.
- Source:
Members
_banner :Element
A reference to the SystemBanner element
.A reference to the SystemBanner element
Type:
- Element
- Source:
_clickCallback :function
Callback when the user clicks on the system banner button.
Callback when the user clicks on the system banner button.
Type:
- function
- Source:
_clicked :Boolean
Set when the clicked callback called.
Set when the clicked callback called. Bypasses dismiss.
Type:
- Boolean
- Source:
banner :function
Generates and returns the banner if it does not exist
.Generates and returns the banner if it does not exist
Type:
- function
- Source:
Methods
show(message, buttonParams)
Shows a banner with a given message.
Shows a banner with a given message. Optionally shows a button with a given label/callback/dismiss. 'dismiss' is called when the banner is dismissed and button has not been clicked. It is optional.
Parameters:
Name | Type | Description |
---|---|---|
message |
String | Array | The message to display |
buttonParams |
Object | { label: l10nAttrs, callback: ..., dismiss: ... } |
- Source: