Ember Notification Center is an Ember addon for managing and displaying notification messages.
ember install ember-notification-center
git clone
this repositorynpm install
bower install
This addon provides an Ember Data notification model and a component for rendering such models.
The component can be used as follows, assuming that notifications
is bound to
an array of notification
model instances:
This will render a button that displays a list of notifications when clicked. A message and creation date is displayed for each message.
Notifications with the important
property set to true
receive the
class important
, while unseen notifications receive the additional
class new
.
The notifications are ordered by date, but important notifications are
listed before ordinary ones. The maximum number of notifications to
show is determined by the property numNotifications
, which is 3 by
default.
Below is an example of how the notification list can look when styled.
You can also specify the header property which will add a header to the notifications list.
npm test
(Runsember try:testall
to test the addon against multiple Ember versions)ember test
ember test --server
ember build
For more information on using ember-cli, visit http://www.ember-cli.com/.