website/templates/index.html

103 lines
3.6 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<!-- Enable responsiveness on mobile devices-->
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Permissions-Policy" content="interest-cohort=()"/>
<title>
{% block title %}
{{ section.title }} &middot; {{ config.title }}
{% endblock title %}
</title>
{% block description %}
<meta name="description" content="{{ config.title }} &middot; {{ config.description }}">
<meta name="keywords" content="{{ config.extra.keywords }}">
{% endblock description %}
{% block meta %}
<meta name="author" content="{{ config.extra.author.name }}">
{% if current_url %}
<link href="{{ current_url }}" rel="canonical">
{% else %}
<link href="/404.html" rel="canonical">
{% endif %}
{% if config.generate_feeds %}{% for feed in config.feed_filenames %}<link rel="alternate" type={% if feed == "atom.xml" %}"application/atom+xml"{% else %}"application/rss+xml"{% endif %} title="RSS" href="{{ get_url(path=feed) | safe }}">{% endfor %}{% endif %}
{% endblock meta %}
{% block og_card %}
<meta property="og:type" content="article">
{% if current_url %}
<meta property="og:url" content="{{ current_url }}">
{% else %}
<meta property="og:site_name" content="{{ config.title }}">
{% endif %}
{% if page.excerpt %}
<meta property="og:description" content="{{ page.excerpt | strip_html }}">
{% else %}
<meta property="og:description" content="{{ config.description }}">
{% endif %}
{% endblock og_card %}
{% block og_image %}
<meta property="og:image" content="/logo.png">
{% endblock og_image %}
{% block default_css %}
<style>{{ load_data(path="./public/default.css") | safe }}</style>
<link rel="stylesheet" href="{{ get_url(path="/style.css") }}" type="text/css" charset="utf-8">
{% endblock default_css %}
</head>
<body>
{% block css %}
{% endblock css %}
{% block header %}
<header class="masthead">
<h3 class="masthead-title">
<a href="/">{{ config.extra.author.name }}</a><br>
<small>{{ config.description }}</small>
</h3>
<nav class="masthead-nav">
{% for node in config.extra.navigation %}
{% if current_url and current_url != get_url(path=node.url, trailing_slash=true) %}
<a href="{{ node.url | replace(from="$BASE_URL", to="" ) }}" class="nav-item">{{ node.name }}</a>
{% endif %}
{% endfor %}
{% if current_url and current_url != get_url(path="/", trailing_slash=true) %}
<a href="/" class="nav-item">Home</a>
{% endif %}
</nav>
</header>
{% endblock header %}
<main class="content">
{% block content %}
<article class="index {% if section.extra.text_center %}text-center{% elif section.extra.text_justify %}text-justify{% endif %}">
{{ section.content | safe }}
</article>
{% endblock content %}
</main>
{% block footer %}
<footer class="footer">
<p>
<small>
This work is licensed under the <a rel="license" href="https://opensource.org/licenses/0BSD">0BSD License</a>.
<br/>
{% if config.generate_feeds %}{% for feed in config.feed_filenames %}<span><a href="{{ get_url(path=feed) | safe }}" rel="noopener" target="_blank" type="application/rss+xml">RSS feed</a></span>{% endfor %}{% endif %}
</small>
</p>
</footer>
{% endblock footer %}
</body>
</html>