-
-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathBaseLayout.astro
More file actions
46 lines (42 loc) · 1.6 KB
/
BaseLayout.astro
File metadata and controls
46 lines (42 loc) · 1.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
---
import '../styles/global.css';
import ConditionalSnow from '../components/ConditionalSnow.tsx';
import ConditionalChristmas from '../components/ConditionalChristmas.tsx';
import ConditionalOcean from '../components/ConditionalOcean.tsx';
import { baseUrl } from '../lib/utils';
interface Props {
title: string;
description?: string;
}
const { title, description = 'IPython - Productive Interactive Computing' } = Astro.props;
---
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width" />
<link rel="icon" type="image/png" href={baseUrl('ipython-logo.png')} />
<link rel="apple-touch-icon" href={baseUrl('ipython-logo.png')} />
<title>{title} | IPython</title>
<meta name="description" content={description} />
<script is:inline>
// Prevent flash of wrong theme
const theme = localStorage.getItem('theme') || 'light';
if (theme === 'dark') {
document.documentElement.classList.add('dark');
}
</script>
<!-- Privacy-friendly analytics by Plausible -->
<script async src="https://plausible.io/js/pa-_AAqKpTKNctdmTbfTzLPM.js"></script>
<script is:inline>
window.plausible=window.plausible||function(){(plausible.q=plausible.q||[]).push(arguments)},plausible.init=plausible.init||function(i){plausible.o=i||{}};
plausible.init()
</script>
</head>
<body class="bg-white dark:bg-ipython-dark text-gray-900 dark:text-gray-50">
<slot />
<ConditionalSnow client:load />
<ConditionalChristmas client:load />
<ConditionalOcean client:load />
</body>
</html>