Commit 6f5ee41c authored by ziyu's avatar ziyu

improvement: 信息流优化

parent e1c74aad
......@@ -21,7 +21,6 @@
</template>
<script>
import wepy from '@wepy/core';
wepy.component({
props: {
activityList: {
......@@ -39,12 +38,15 @@
activityList(val) {
let list = val || [];
this.list = list;
if(list.length < 3) {
this.onActivityChange();
}
}
},
methods: {
onActivityChange(e) {
const lastIndex = this.list.length - this.activityDisplayItems;
if (e.$wx.detail.current === lastIndex) {
if (!e || e.$wx.detail.current === lastIndex) {
this.isAuto = false;
// 当最后一个出来的时候等一秒再消失
setTimeout(() => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment