|
@@ -184,6 +184,7 @@
|
|
|
addEventListener(LOAD_DEFERRED_IMAGES_END_EVENT, () => loadDeferredImagesEnd());
|
|
addEventListener(LOAD_DEFERRED_IMAGES_END_EVENT, () => loadDeferredImagesEnd());
|
|
|
addEventListener(LOAD_DEFERRED_IMAGES_KEEP_ZOOM_LEVEL_END_EVENT, () => loadDeferredImagesEnd(true));
|
|
addEventListener(LOAD_DEFERRED_IMAGES_KEEP_ZOOM_LEVEL_END_EVENT, () => loadDeferredImagesEnd(true));
|
|
|
addEventListener(LOAD_DEFERRED_IMAGES_RESET_ZOOM_LEVEL_END_EVENT, () => {
|
|
addEventListener(LOAD_DEFERRED_IMAGES_RESET_ZOOM_LEVEL_END_EVENT, () => {
|
|
|
|
|
+ const scrollingElement = document.scrollingElement || document.documentElement;
|
|
|
const transform = document.documentElement.style.getPropertyValue("-sf-transform");
|
|
const transform = document.documentElement.style.getPropertyValue("-sf-transform");
|
|
|
const transformPriority = document.documentElement.style.getPropertyPriority("-sf-transform");
|
|
const transformPriority = document.documentElement.style.getPropertyPriority("-sf-transform");
|
|
|
const transformOrigin = document.documentElement.style.getPropertyValue("-sf-transform-origin");
|
|
const transformOrigin = document.documentElement.style.getPropertyValue("-sf-transform-origin");
|
|
@@ -196,6 +197,10 @@
|
|
|
document.documentElement.style.removeProperty("-sf-transform");
|
|
document.documentElement.style.removeProperty("-sf-transform");
|
|
|
document.documentElement.style.removeProperty("-sf-transform-origin");
|
|
document.documentElement.style.removeProperty("-sf-transform-origin");
|
|
|
document.documentElement.style.removeProperty("-sf-min-height");
|
|
document.documentElement.style.removeProperty("-sf-min-height");
|
|
|
|
|
+ delete scrollingElement.clientHeight;
|
|
|
|
|
+ delete scrollingElement.clientWidth;
|
|
|
|
|
+ delete screen.height;
|
|
|
|
|
+ delete screen.width;
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
function loadDeferredImagesEnd(keepZoomLevel) {
|
|
function loadDeferredImagesEnd(keepZoomLevel) {
|
|
@@ -204,11 +209,11 @@
|
|
|
element.loading = "lazy";
|
|
element.loading = "lazy";
|
|
|
element.removeAttribute(LAZY_LOAD_ATTRIBUTE);
|
|
element.removeAttribute(LAZY_LOAD_ATTRIBUTE);
|
|
|
});
|
|
});
|
|
|
- delete scrollingElement.clientHeight;
|
|
|
|
|
- delete scrollingElement.clientWidth;
|
|
|
|
|
- delete screen.height;
|
|
|
|
|
- delete screen.width;
|
|
|
|
|
if (!keepZoomLevel) {
|
|
if (!keepZoomLevel) {
|
|
|
|
|
+ delete scrollingElement.clientHeight;
|
|
|
|
|
+ delete scrollingElement.clientWidth;
|
|
|
|
|
+ delete screen.height;
|
|
|
|
|
+ delete screen.width;
|
|
|
if (window._singleFile_getBoundingClientRect) {
|
|
if (window._singleFile_getBoundingClientRect) {
|
|
|
Element.prototype.getBoundingClientRect = window._singleFile_getBoundingClientRect;
|
|
Element.prototype.getBoundingClientRect = window._singleFile_getBoundingClientRect;
|
|
|
window.innerHeight = window._singleFile_innerHeight;
|
|
window.innerHeight = window._singleFile_innerHeight;
|