From 5350c2483f7bb89102e53a3e18f3cacfe35dac47 Mon Sep 17 00:00:00 2001 From: James Lyne Date: Wed, 1 Sep 2021 02:15:51 +0100 Subject: [PATCH] Reset splash screen on show instead of hide --- src/util/splash.ts | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/util/splash.ts b/src/util/splash.ts index a2f0a44..f356e6a 100644 --- a/src/util/splash.ts +++ b/src/util/splash.ts @@ -26,6 +26,18 @@ export const showSplash = function() { return; } + if(splashError) { + splashError.setAttribute('aria-hidden', 'true'); + } + + if(splashSpinner) { + splashSpinner.style.visibility = 'visible'; + } + + if(splashRetry) { + splashRetry.hidden = true; + } + splash.hidden = false; app.setAttribute('aria-hidden', 'true'); @@ -39,18 +51,6 @@ export const hideSplash = () => { return; } - if(splashError) { - splashError.setAttribute('aria-hidden', 'true'); - } - - if(splashSpinner) { - splashSpinner.style.visibility = 'visible'; - } - - if(splashRetry) { - splashRetry.hidden = true; - } - requestAnimationFrame(() => { splash.style.opacity = '0'; app.removeAttribute('aria-hidden');