This commit is contained in:
syuilo 2018-06-02 19:19:58 +09:00
parent 8f50080647
commit 534e43f72d
1 changed files with 14 additions and 3 deletions

View File

@ -66,15 +66,15 @@
</div>
<template v-if="notification.type == 'quote'">
<mk-note :note="notification.note"/>
<mk-note :note="notification.note" @update:note="onNoteUpdated"/>
</template>
<template v-if="notification.type == 'reply'">
<mk-note :note="notification.note"/>
<mk-note :note="notification.note" @update:note="onNoteUpdated"/>
</template>
<template v-if="notification.type == 'mention'">
<mk-note :note="notification.note"/>
<mk-note :note="notification.note" @update:note="onNoteUpdated"/>
</template>
</div>
</template>
@ -89,6 +89,17 @@ export default Vue.extend({
return {
getNoteSummary
};
},
methods: {
onNoteUpdated(note) {
switch (this.notification.type) {
case 'quote':
case 'reply':
case 'mention':
Vue.set(this.notification, 'note', note);
break;
}
}
}
});
</script>