[bugfix] List: visibility check (#1345)

This commit is contained in:
neverland 2018-06-28 17:30:13 +08:00 committed by GitHub
parent 8139eb5479
commit 19d1c45121
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,7 +78,7 @@ export default create({
const scrollerHeight = utils.getVisibleHeight(scroller);
/* istanbul ignore next */
if (!scrollerHeight || utils.getComputedStyle(el).display === 'none') {
if (!scrollerHeight || utils.getComputedStyle(el).display === 'none' || el.offsetParent === null) {
return;
}