From 83858d496dd1d0d6e42a447db866c2642b28d31f Mon Sep 17 00:00:00 2001 From: Cohee <18619528+Cohee1207@users.noreply.github.com> Date: Sun, 28 Jul 2024 14:08:25 +0300 Subject: [PATCH] Fix iOS Firefox viewport position when navigating from login --- public/script.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/public/script.js b/public/script.js index 232280ffc..63df33019 100644 --- a/public/script.js +++ b/public/script.js @@ -930,10 +930,17 @@ async function firstLoadInit() { initCfg(); initLogprobs(); doDailyExtensionUpdatesCheck(); - hideLoader(); + await hideLoader(); + await fixViewport(); await eventSource.emit(event_types.APP_READY); } +async function fixViewport() { + document.body.style.position = 'absolute'; + await delay(1); + document.body.style.position = ''; +} + function cancelStatusCheck() { abortStatusCheck?.abort(); abortStatusCheck = new AbortController();