|
|
@ -1726,6 +1726,16 @@ export class AppImManager { |
|
|
|
bubble = document.createElement('div'); |
|
|
|
bubble = document.createElement('div'); |
|
|
|
bubble.classList.add('bubble'); |
|
|
|
bubble.classList.add('bubble'); |
|
|
|
bubble.appendChild(bubbleContainer); |
|
|
|
bubble.appendChild(bubbleContainer); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(!our) { |
|
|
|
|
|
|
|
//this.log('not our message', message, message.pFlags.unread);
|
|
|
|
|
|
|
|
if(message.pFlags.unread) { |
|
|
|
|
|
|
|
this.unreadedObserver.observe(bubble); |
|
|
|
|
|
|
|
if(!this.unreaded.indexOf(message.mid)) { |
|
|
|
|
|
|
|
this.unreaded.push(message.mid); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
const save = ['is-highlighted']; |
|
|
|
const save = ['is-highlighted']; |
|
|
|
const wasClassNames = bubble.className.split(' '); |
|
|
|
const wasClassNames = bubble.className.split(' '); |
|
|
@ -1778,16 +1788,6 @@ export class AppImManager { |
|
|
|
this.renderMessagesQueue(message, bubble, reverse); |
|
|
|
this.renderMessagesQueue(message, bubble, reverse); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if(!our) { |
|
|
|
|
|
|
|
//this.log('not our message', message, message.pFlags.unread);
|
|
|
|
|
|
|
|
if(message.pFlags.unread) { |
|
|
|
|
|
|
|
this.unreadedObserver.observe(bubble); |
|
|
|
|
|
|
|
if(!this.unreaded.indexOf(message.mid)) { |
|
|
|
|
|
|
|
this.unreaded.push(message.mid); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return bubble; |
|
|
|
return bubble; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|