| 1 | const SPLASH_FLAG = "reasonix.splash.shown"; |
| 2 | |
| 3 | export function shouldShowStartupSplash(): boolean { |
| 4 | try { |
| 5 | return window.sessionStorage.getItem(SPLASH_FLAG) !== "1"; |
| 6 | } catch { |
| 7 | return true; |
| 8 | } |
| 9 | } |
| 10 | |
| 11 | export function markSplashShown(): void { |
| 12 | try { |
| 13 | window.sessionStorage.setItem(SPLASH_FLAG, "1"); |
| 14 | } catch { |
| 15 | // Session storage is optional in restricted hosts. |
| 16 | } |
| 17 | } |
| 18 |