chore: set light theme as default

This commit is contained in:
alireza 2026-08-27 11:34:26 +03:30
parent d55a91d2b8
commit a0a2a6fe97
1 changed files with 2 additions and 4 deletions

View File

@ -9,11 +9,9 @@ const readStoredTheme = (): Theme => {
const saved = localStorage.getItem(STORAGE_KEY); const saved = localStorage.getItem(STORAGE_KEY);
if (saved === 'light' || saved === 'dark') return saved; if (saved === 'light' || saved === 'dark') return saved;
} catch { } catch {
// Private mode / blocked storage — fall through to the system preference. // Private mode / blocked storage — fall through to default.
} }
return window.matchMedia('(prefers-color-scheme: dark)').matches return 'light';
? 'dark'
: 'light';
}; };
const applyTheme = (theme: Theme) => { const applyTheme = (theme: Theme) => {