Merge branch 'dev' into upgrade_to_custom_component

This commit is contained in:
pangxie1991 2018-03-23 10:35:51 +08:00
commit 0d74dcc2a6

View File

@ -28,6 +28,8 @@ const ZanNoticeBar = {
return;
}
clearTimeout(this.data[componentId].setTimeoutId)
currentComponent.wrapWidth = rect.width;
if (currentComponent.wrapWidth < currentComponent.width) {
var mstime = currentComponent.width / 40 * 1000;
@ -60,9 +62,12 @@ const ZanNoticeBar = {
});
}, 100);
setTimeout(() => {
const setTimeoutId = setTimeout(() => {
this.scrollZanNoticeBar(componentId, mstime);
}, mstime);
this.setData({
[`${componentId}.setTimeoutId`]: setTimeoutId
})
}
};