32dbf68247
* chore: add description to avoid type error * fix: fix canonical url type in main head component
79 lines
1.7 KiB
Text
79 lines
1.7 KiB
Text
---
|
|
import MainHead from '../components/MainHead.astro';
|
|
import Nav from '../components/Nav.astro';
|
|
import authorData from '../data/authors.json';
|
|
|
|
const { content } = Astro.props;
|
|
let canonicalURL = Astro.request.canonicalURL;
|
|
---
|
|
|
|
<html lang={ content.lang || 'en' }>
|
|
<head>
|
|
<title>{content.title}</title>
|
|
<MainHead title={content.title} description={content.description} image={content.image} canonicalURL={canonicalURL} />
|
|
<style lang="scss">
|
|
.title {
|
|
margin-top: 4rem;
|
|
margin-bottom: 4rem;
|
|
font-size: 3em;
|
|
letter-spacing: -0.04em;
|
|
text-align: center;
|
|
}
|
|
|
|
.description {
|
|
margin-bottom: 4rem;
|
|
font-size: 1.4em;
|
|
font-weight: 400;
|
|
text-align: justify;
|
|
text-transform: uppercase;
|
|
}
|
|
|
|
.img {
|
|
display: block;
|
|
width: 100%;
|
|
height: auto;
|
|
}
|
|
|
|
.article {
|
|
margin-top: 4rem;
|
|
margin-bottom: 6rem;
|
|
|
|
:global(p) {
|
|
font-size: 1.3em;
|
|
line-height: 2;
|
|
margin-top: 2em;
|
|
margin-bottom: 2em;
|
|
}
|
|
}
|
|
|
|
.posts {
|
|
text-transform: uppercase;
|
|
}
|
|
|
|
.footer {
|
|
margin-top: 6rem;
|
|
padding-bottom: 6rem;
|
|
text-align: center;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<Nav />
|
|
|
|
<main class="wrapper">
|
|
<h2 class="title">{content.title}</h2>
|
|
<p class="description">{content.description}</p>
|
|
<img class="img" src={content.image} alt="">
|
|
<article class="article">
|
|
<slot />
|
|
</article>
|
|
<footer class="footer">
|
|
<a class="posts" href="/posts">All Posts</a>
|
|
</footer>
|
|
</main>
|
|
|
|
<footer>
|
|
</footer>
|
|
</body>
|
|
</html>
|