未読の通知がある場合アイコンを表示するように

This commit is contained in:
syuilo 2017-10-30 22:12:10 +09:00
parent 9aed3d21c9
commit caa47cb38c
18 changed files with 525 additions and 392 deletions

View file

@ -252,6 +252,12 @@
});
this.onNotification = notification => {
// TODO: ユーザーが画面を見てないと思われるとき(ブラウザやタブがアクティブじゃないなど)は送信しない
this.stream.send({
type: 'read_notification',
id: notification.id
});
this.notifications.unshift(notification);
this.update();
};