42 lines
1.1 KiB
Plaintext
42 lines
1.1 KiB
Plaintext
|
---
|
||
|
import LanguagePicker from "../components/LanguagePicker.astro";
|
||
|
import Nav from "../components/Nav.astro";
|
||
|
interface Props {
|
||
|
title: string;
|
||
|
}
|
||
|
|
||
|
const { title } = Astro.props;
|
||
|
---
|
||
|
|
||
|
<!doctype html>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta charset="UTF-8" />
|
||
|
<meta name="description" content="Astro description" />
|
||
|
<meta name="viewport" content="width=device-width" />
|
||
|
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
||
|
<link rel="stylesheet" href="/app.css" />
|
||
|
<meta name="generator" content={Astro.generator} />
|
||
|
<!-- <meta http-equiv="refresh" content="0;url=/" /> -->
|
||
|
<title>{title}</title>
|
||
|
<script>
|
||
|
(function () {
|
||
|
try {
|
||
|
var mode = localStorage.getItem("mode");
|
||
|
var supportDarkMode =
|
||
|
window.matchMedia("(prefers-color-scheme: dark)").matches === true;
|
||
|
if (!mode && supportDarkMode)
|
||
|
document.body.classList.add("theme-dark");
|
||
|
if (!mode) return;
|
||
|
document.body.classList.add("theme-" + mode);
|
||
|
} catch (e) {}
|
||
|
})();
|
||
|
</script>
|
||
|
</head>
|
||
|
<body>
|
||
|
<Nav />
|
||
|
<slot />
|
||
|
<LanguagePicker />
|
||
|
</body>
|
||
|
</html>
|