mirror of
https://github.com/BradNut/boredgame
synced 2025-09-08 17:40:22 +00:00
45 lines
1.4 KiB
HTML
45 lines
1.4 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta name="robots" content="noindex, nofollow" />
|
|
<meta charset="utf-8" />
|
|
<meta name="description" content="Bored? Find a game! Bored Game!" />
|
|
<link rel="icon" href="%sveltekit.assets%/favicon-bored.png" />
|
|
<meta name="viewport" content="width=device-width" />
|
|
<script>
|
|
// const htmlElement = document.documentElement;
|
|
// const userTheme = localStorage.theme;
|
|
// const userFont = localStorage.font;
|
|
|
|
// const prefersDarkMode = window.matchMedia('prefers-color-scheme: dark').matches;
|
|
// const prefersLightMode = window.matchMedia('prefers-color-scheme: light').matches;
|
|
|
|
// // check if the user set a theme
|
|
// if (userTheme) {
|
|
// htmlElement.dataset.theme = userTheme;
|
|
// }
|
|
|
|
// // otherwise check for user preference
|
|
// if (!userTheme && prefersDarkMode) {
|
|
// htmlElement.dataset.theme = '🌛 Night';
|
|
// localStorage.theme = '🌛 Night';
|
|
// }
|
|
|
|
// if (!userTheme && prefersLightMode) {
|
|
// htmlElement.dataset.theme = '☀️ Daylight';
|
|
// localStorage.theme = '☀️ Daylight';
|
|
// }
|
|
|
|
// // if nothing is set default to dark mode
|
|
// if (!userTheme && !prefersDarkMode && !prefersLightMode) {
|
|
// htmlElement.dataset.theme = '🌛 Night';
|
|
// localStorage.theme = '🌛 Night';
|
|
// }
|
|
</script>
|
|
%sveltekit.head%
|
|
</head>
|
|
|
|
<body>
|
|
<div id="svelte">%sveltekit.body%</div>
|
|
</body>
|
|
</html>
|