mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-21 04:45:17 +00:00
Use SHOW_ALERT for all type of notifications
This commit is contained in:
@@ -70,11 +70,18 @@ The following properties can be configured:
|
||||
|
||||
|
||||
## Developer notes
|
||||
For notifications use:
|
||||
|
||||
### Display notification
|
||||
```
|
||||
self.sendNotification("SHOW_NOTIFICATION", {title: "Hello", message: "This is a test!"});
|
||||
self.sendNotification("SHOW_ALERT", {type: "notification"});
|
||||
```
|
||||
For alerts use:
|
||||
|
||||
```
|
||||
self.sendNotification("SHOW_ALERT", {type: "alert"});
|
||||
```
|
||||
|
||||
### Notification params
|
||||
<table width="100%">
|
||||
<!-- why, markdown... -->
|
||||
<thead>
|
||||
@@ -99,10 +106,7 @@ self.sendNotification("SHOW_NOTIFICATION", {title: "Hello", message: "This is a
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
### Display alert
|
||||
```
|
||||
self.sendNotification("SHOW_ALERT", {title: "Hello", message: "This is a test!", imageUrl:"url", imageHeight: "30px", timer:2});
|
||||
```
|
||||
### Alert params
|
||||
<table width="100%">
|
||||
<!-- why, markdown... -->
|
||||
<thead>
|
||||
@@ -149,8 +153,6 @@ self.sendNotification("SHOW_ALERT", {title: "Hello", message: "This is a test!",
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
## Open Source Licenses
|
||||
###[NotificationStyles](https://github.com/codrops/NotificationStyles)
|
||||
See [ympanus.net](http://tympanus.net/codrops/licensing/) for license.
|
Reference in New Issue
Block a user