diff --git a/static/skin/viewer.js b/static/skin/viewer.js index 0426aea0e..db7bc2ba8 100644 --- a/static/skin/viewer.js +++ b/static/skin/viewer.js @@ -198,7 +198,10 @@ function updateToolbarVisibilityState() { } function handle_visual_viewport_change() { - contentIframe.height = window.visualViewport.height - contentIframe.offsetTop - 4; + const wh = window.visualViewport + ? window.visualViewport.height + : window.innerHeight; + contentIframe.height = wh - contentIframe.offsetTop - 4; } function handle_location_hash_change() { diff --git a/test/server.cpp b/test/server.cpp index 0ec08c821..db34315fc 100644 --- a/test/server.cpp +++ b/test/server.cpp @@ -73,7 +73,7 @@ const ResourceCollection resources200Compressible{ { DYNAMIC_CONTENT, "/ROOT/skin/taskbar.css" }, { STATIC_CONTENT, "/ROOT/skin/taskbar.css?cacheid=2cbac34b" }, { DYNAMIC_CONTENT, "/ROOT/skin/viewer.js" }, - { STATIC_CONTENT, "/ROOT/skin/viewer.js?cacheid=430d45b0" }, + { STATIC_CONTENT, "/ROOT/skin/viewer.js?cacheid=03fd97ee" }, { DYNAMIC_CONTENT, "/ROOT/skin/fonts/Poppins.ttf" }, { STATIC_CONTENT, "/ROOT/skin/fonts/Poppins.ttf?cacheid=af705837" }, { DYNAMIC_CONTENT, "/ROOT/skin/fonts/Roboto.ttf" }, @@ -302,7 +302,7 @@ R"EXPECTEDRESULT( - + const blankPageUrl = root + "/skin/blank.html?cacheid=6b1fa032";