Authored by yyq

fix comment scroll

... ... @@ -69,6 +69,7 @@ export default {
},
listTitle: String,
scrollTop: Number,
scrollTo: Function,
share: Boolean,
posId: Number,
},
... ...
... ... @@ -81,6 +81,7 @@ export default {
},
listTitle: String,
scrollTop: Number,
scrollTo: Function,
share: Boolean,
posId: Number,
},
... ... @@ -179,7 +180,7 @@ export default {
this.$refs.commentList && this.$refs.commentList.addComment(comment);
},
toCommentList() {
if (this.data.commentCount) {
if (this.articleState.commentCount) {
if (this.$refs.commentList && this.scrollTo) {
this.scrollTo({scrollTop: this.$refs.commentList.$el.offsetTop - this.$refs.header.$el.offsetHeight});
}
... ...

1.08 KB | W: | H:

1.76 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin