Files
vidconf/frontend/index.html
Max Ronzhin 8757bec8ac
Some checks failed
CI / backend (push) Has been cancelled
CI / frontend (push) Has been cancelled
first commit
2026-07-23 02:38:05 +03:00

33 lines
1.5 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!doctype html>
<html lang="ru">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>VidConf</title>
<script>
/*
* Тема оболочки — применяется ДО первого рендера React, чтобы избежать
* мигания светлой темой (FOUC) при явном выборе «тёмная» пользователем
* (см. frontend/src/hooks/useTheme.ts — ключ localStorage там ДОЛЖЕН
* совпадать с этим скриптом). Если явного выбора нет — атрибут не
* проставляется, и работает системный автодетект из tokens.css
* (@media prefers-color-scheme: dark), см. design/DESIGN_SYSTEM.md §0.1.
*/
try {
var vidconfTheme = localStorage.getItem('vidconf-theme')
if (vidconfTheme === 'light' || vidconfTheme === 'dark') {
document.documentElement.setAttribute('data-theme', vidconfTheme)
}
} catch (e) {
// localStorage недоступен (приватный режим/политики браузера) — тема
// определится системным prefers-color-scheme, без сохранённого выбора.
}
</script>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>