|
|
@@ -22,8 +22,8 @@
|
|
|
|
|
|
(() => {
|
|
|
|
|
|
- const SCROLL_LENGTH = 100;
|
|
|
- const SCROLL_DELAY = 50;
|
|
|
+ const SCROLL_LENGTH = 200;
|
|
|
+ const SCROLL_DELAY = 100;
|
|
|
|
|
|
window._singleFile_getBoundingClientRect = Element.prototype.getBoundingClientRect;
|
|
|
Element.prototype.getBoundingClientRect = function () {
|
|
|
@@ -43,7 +43,7 @@
|
|
|
function scroll(offsetY, maxOffsetY) {
|
|
|
document.documentElement.__defineGetter__("scrollTop", () => offsetY);
|
|
|
document.documentElement.__defineGetter__("scrollY", () => offsetY);
|
|
|
- document.documentElement.__defineGetter__("pageYOffset", () => offsetY);
|
|
|
+ window.__defineGetter__("pageYOffset", () => offsetY);
|
|
|
dispatchEvent(new UIEvent("scroll"));
|
|
|
if (offsetY < maxOffsetY) {
|
|
|
window._singleFile_timeoutScroll = setTimeout(() => scroll(offsetY + SCROLL_LENGTH, maxOffsetY), SCROLL_DELAY);
|