Files
shihaam 5244caa37e
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 8s
fix white flashbang
2026-08-03 20:21:05 +05:00

41 lines
1.8 KiB
HTML

<!doctype html>
<html lang="en" class="antialiased" suppressHydrationWarning>
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="description" content="Sarlink Portal" />
<title>SAR Link Portal</title>
<script>
// Set theme BEFORE first paint to avoid a flash of white.
// The white flash is the browser's default canvas, shown before CSS
// paints (paint is delayed by the render-blocking font stylesheet).
// `color-scheme` controls that pre-paint canvas, so setting it here —
// synchronously, before the font <link> below can block — fixes it.
// Mirrors next-themes ("theme" key; falls back to system preference).
(function () {
try {
var stored = localStorage.getItem("theme");
var isDark =
stored === "dark" ||
((!stored || stored === "system") &&
window.matchMedia("(prefers-color-scheme: dark)").matches);
var root = document.documentElement;
root.classList.toggle("dark", isDark);
root.style.colorScheme = isDark ? "dark" : "light";
} catch (e) {}
})();
</script>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Barlow:wght@100;300;400;500;600;700;800;900&family=Bokor&family=Geist+Mono:wght@400;500&display=swap"
rel="stylesheet"
/>
</head>
<body class="antialiased font-sans bg-gray-100 dark:bg-black">
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>