aboutsummaryrefslogtreecommitdiff
path: root/src/layouts/Layout.astro
blob: 988f096c79b9941bea90600e6499c153d615b90b (plain)
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
---
import "@fontsource/beiruti";
import "@fontsource-variable/sen";
import Header from "../partials/Header.astro";
import Footer from "../partials/Footer.astro";

interface Props {
	title: string;
	description: string;
}

const { title, description } = Astro.props;
---

<!doctype html>
<html lang="es">
	<head>
		<meta charset="UTF-8" />
		<meta name="description" content={description} />
		<meta name="viewport" content="width=device-width" />

		<link rel="canonical" href={Astro.url} />
		<link rel="alternate" type="application/rss+xml" href="/blog.xml" />
		<link rel="sitemap" type="application/xml" href="/sitemap-index.xml" />

		<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
		<link rel="icon" type="image/png" href="/favicon.png" />
		<link rel="apple-touch-icon" href="/favicon.png" />

		<meta property="og:title" content={title} />
		<meta property="og:description" content={description} />
		<meta property="og:type" content="website" />
		<meta property="og:url" content={Astro.url} />
		<meta property="og:image" content="/favicon.png" />

		<meta name="twitter:card" content="summary" />
		<meta name="twitter:title" content={title} />
		<meta name="twitter:description" content={description} />
		<meta name="twitter:image" content="/favicon.png" />

		<title>{title} - Ariel Costas</title>

		<slot name="head-jsonld" />
	</head>
	<body>
		<Header />
		<main>
			<slot />
		</main>
		<Footer />
	</body>
</html>

<style is:global lang="scss">
	@import "../../styles/shared.scss";

	html,
	body {
		margin: 0;
		padding: 0;
		box-sizing: border-box;
	}

	body {
		min-height: 100vh;
		max-width: 100vw;

		display: flex;
		flex-direction: column;
		gap: 1.5rem;

		background-color: $background;
		color: $dark;
	}

	a {
		color: $accent;
	}

	*::selection {
		background-color: transparentize($accent, 0.85);
	}

	li > time {
		font-family: $monoFontStack;
	}

	main {
		box-sizing: border-box;
		margin-bottom: auto;

		align-self: center;

		max-width: 82ch;
		font-size: 1.2rem;
		
		padding-block-end: 3rem;

		a {
			color: $accentDark;
			transition: color 0.2s ease-in-out;

			&:hover {
				color: $accent;
			}
		}

		> p > code {
			word-break: break-word;
			font-family: $monoFontStack;

			color: $accentDark;
			background-color: #f6f6f6;
		}

		p.meta {
			display: block;
			font-size: 0.85rem;
			margin-bottom: 1rem;
		}

		pre {
			overflow: scroll;
		}
	}
</style>