128 lines
3.5 KiB
HTML
128 lines
3.5 KiB
HTML
![]() |
<!doctype html>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta charset="UTF-8" />
|
||
|
<meta name="generator" content="pandoc" />
|
||
|
<meta
|
||
|
name="viewport"
|
||
|
content="width=device-width, initial-scale=1.0, user-scalable=yes"
|
||
|
/>
|
||
|
$for(author-meta)$
|
||
|
<meta name="author" content="$author-meta$" />
|
||
|
$endfor$ $if(date-meta)$
|
||
|
<meta name="dcterms.date" content="$date-meta$" />
|
||
|
$endif$ $if(keywords)$
|
||
|
<meta
|
||
|
name="keywords"
|
||
|
content="$for(keywords)$$keywords$$sep$, $endfor$"
|
||
|
/>
|
||
|
$endif$ $if(description-meta)$
|
||
|
<meta name="description" content="$description-meta$" />
|
||
|
$endif$
|
||
|
<title>$title$</title>
|
||
|
<style>
|
||
|
$styles.html()$
|
||
|
</style>
|
||
|
$for(css)$
|
||
|
<link rel="stylesheet" href="$css$" />
|
||
|
$endfor$
|
||
|
<!-- Begin Google Fonts import -->
|
||
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
||
|
<link
|
||
|
href="https://fonts.googleapis.com/css2?family=Courier+Prime:ital,wght@0,400;0,700;1,400;1,700&family=Roboto+Slab:wght@100..900&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"
|
||
|
rel="stylesheet"
|
||
|
/>
|
||
|
<!-- End Google Fonts import -->
|
||
|
<!-- Begin Lineicons import -->
|
||
|
<!--
|
||
|
<link
|
||
|
rel="stylesheet"
|
||
|
href="https://cdn.lineicons.com/4.0/lineicons.css"
|
||
|
/>
|
||
|
<!-- End Lineicons import-->
|
||
|
<link rel="stylesheet" href="/style.css" />
|
||
|
</head>
|
||
|
<body>
|
||
|
<header>
|
||
|
<nav class="primary-buttons">
|
||
|
<ul>
|
||
|
<li><a class="nav-button" href="/">Index</a></li>
|
||
|
</ul>
|
||
|
</nav>
|
||
|
<nav class="secondary-buttons">
|
||
|
<ul>
|
||
|
<li>
|
||
|
<div class="dropdown">
|
||
|
<button class="nav-button">Posts</button>
|
||
|
<div
|
||
|
class="dropdown-content"
|
||
|
id="dropdown-content"
|
||
|
></div>
|
||
|
</div>
|
||
|
<a class="nav-button" href="/pages/about.html">
|
||
|
About
|
||
|
</a>
|
||
|
<a class="nav-button" href="/pages/privacy.html">
|
||
|
Privacy
|
||
|
</a>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</nav>
|
||
|
</header>
|
||
|
|
||
|
<main>
|
||
|
$if(toc)$
|
||
|
<nav id="$idprefix$TOC" role="doc-toc">
|
||
|
$if(toc-title)$
|
||
|
<h2 id="$idprefix$toc-title">$toc-title$</h2>
|
||
|
$endif$ $table-of-contents$
|
||
|
</nav>
|
||
|
$endif$ $body$ $for(include-after)$ $include-after$ $endfor$
|
||
|
</main>
|
||
|
<footer>
|
||
|
<div class="footer-divider"></div>
|
||
|
<p>© 2024 NotAShelf</p>
|
||
|
<div class="footer-icons">
|
||
|
<a href="https://twitter.com/notashelf">
|
||
|
<i class="lni lni-twitter-original" title="Twitter"></i>
|
||
|
</a>
|
||
|
<a href="https://github.com/notashelf">
|
||
|
<i class="lni lni-github-original" title="GitHub"></i>
|
||
|
</a>
|
||
|
<a href="/feed.json">
|
||
|
<i class="lni lni-rss-feed" title="RSS Feed"></i>
|
||
|
</a>
|
||
|
</div>
|
||
|
</footer>
|
||
|
<script>
|
||
|
// Dropdown post listing
|
||
|
function fetchPosts() {
|
||
|
fetch("/posts/posts.json")
|
||
|
.then((response) => response.json())
|
||
|
.then((data) => {
|
||
|
const dropdownContent =
|
||
|
document.getElementById("dropdown-content");
|
||
|
data.posts.forEach((post) => {
|
||
|
const postLink = document.createElement("a");
|
||
|
postLink.textContent = post.title;
|
||
|
// we could use posts.url here, instead of posts.path
|
||
|
// but it messes with local serving, which prefers `/`
|
||
|
// to the actual URL, as it would point to the live site
|
||
|
// by path
|
||
|
postLink.href = post.path;
|
||
|
dropdownContent.appendChild(postLink);
|
||
|
});
|
||
|
})
|
||
|
.catch((error) =>
|
||
|
console.error("Error fetching posts:", error),
|
||
|
);
|
||
|
}
|
||
|
|
||
|
document.addEventListener("DOMContentLoaded", () => {
|
||
|
fetchPosts();
|
||
|
});
|
||
|
</script>
|
||
|
</body>
|
||
|
</html>
|