Dark theme loading screen
This commit is contained in:
parent
af2c884c9f
commit
b30c7f9c46
7 changed files with 114 additions and 18 deletions
|
@ -29,6 +29,7 @@ import type { Receipt } from './types/Receipt';
|
|||
import { getTitleBarVisibility, TitleBarVisibility } from './types/Settings';
|
||||
import { SocketStatus } from './types/SocketStatus';
|
||||
import { DEFAULT_CONVERSATION_COLOR } from './types/Colors';
|
||||
import { ThemeType } from './types/Util';
|
||||
import { ChallengeHandler } from './challenge';
|
||||
import * as durations from './util/durations';
|
||||
import { explodePromise } from './util/explodePromise';
|
||||
|
@ -166,6 +167,13 @@ export async function cleanupSessionResets(): Promise<void> {
|
|||
}
|
||||
|
||||
export async function startApp(): Promise<void> {
|
||||
if (window.initialTheme === ThemeType.light) {
|
||||
document.body.classList.add('light-theme');
|
||||
}
|
||||
if (window.initialTheme === ThemeType.dark) {
|
||||
document.body.classList.add('dark-theme');
|
||||
}
|
||||
|
||||
const idleDetector = new IdleDetector();
|
||||
|
||||
await KeyboardLayout.initialize();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue