Fix keepScrollPosition on condensed messages

This commit is contained in:
Pavel Djundik 2018-09-23 20:51:43 +03:00
parent 893d59e7c4
commit 7d7005c8af

View File

@ -5,7 +5,7 @@
<span class="from" />
<span
class="content"
@click="isCollapsed = !isCollapsed">{{ condensedText }}<button
@click="onCollapseClick">{{ condensedText }}<button
class="toggle-button"
aria-label="Toggle status messages" /></span>
</div>
@ -29,6 +29,7 @@ export default {
props: {
network: Object,
messages: Array,
keepScrollPosition: Function,
},
data() {
return {
@ -91,5 +92,11 @@ export default {
return text;
},
},
methods: {
onCollapseClick() {
this.isCollapsed = !this.isCollapsed;
this.keepScrollPosition();
},
},
};
</script>