@ -79,6 +79,7 @@ export default Vue.extend({
|
||||
|
||||
this.connection.on('message', this.onMessage);
|
||||
this.connection.on('read', this.onRead);
|
||||
this.connection.on('deleted', this.onDeleted);
|
||||
|
||||
if (this.isNaked) {
|
||||
window.addEventListener('scroll', this.onScroll, { passive: true });
|
||||
@ -204,6 +205,13 @@ export default Vue.extend({
|
||||
}
|
||||
},
|
||||
|
||||
onDeleted(id) {
|
||||
const msg = this.messages.find(m => m.id === id);
|
||||
if (msg) {
|
||||
this.messages = this.messages.filter(m => m.id !== msg.id);
|
||||
}
|
||||
},
|
||||
|
||||
isBottom() {
|
||||
const asobi = 64;
|
||||
const current = this.isNaked
|
||||
|
Reference in New Issue
Block a user