tamaina 2020-05-24 18:41:40 +09:00
parent fe39c8e8c6
commit 357a42f2c1

View File

@ -71,10 +71,11 @@ export default Vue.extend({
methods: {
onNotification(notification) {
// TODO: ()
this.$root.stream.send('readNotification', {
id: notification.id
});
if (document.visibilityState === 'visible') {
this.$root.stream.send('readNotification', {
id: notification.id
});
}
this.prepend(notification);
},