Fixed first section in scroll link extension
This commit is contained in:
parent
4e2ad5766b
commit
16169d5382
@ -106,7 +106,7 @@ define([
|
|||||||
// Something wrong in the algorithm...
|
// Something wrong in the algorithm...
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var posInSection = (srcScrollTop - srcSection.startOffset) / srcSection.height;
|
var posInSection = (srcScrollTop - srcSection.startOffset) / (srcSection.height || 1);
|
||||||
var destSection = destSectionList[sectionIndex];
|
var destSection = destSectionList[sectionIndex];
|
||||||
return destSection.startOffset + destSection.height * posInSection;
|
return destSection.startOffset + destSection.height * posInSection;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user