website/templates/index.html

42 lines
1.8 KiB
HTML
Raw Normal View History

2020-03-29 17:26:12 +02:00
{% import "widgets.html" as widgets %}
{% set lang = section.lang | default(value=page.lang) %}
2020-03-31 00:16:36 +02:00
{% set translations = section.translations | default(value=page.translations) %}
2020-03-29 17:26:12 +02:00
<!DOCTYPE html>
<html class="no-js" lang="{{ lang | default(value=config.default_language)}}">
2020-03-29 17:26:12 +02:00
<head>
<meta charset="utf8">
2020-03-30 20:35:04 +02:00
<title>{% block title %}{{ section.title }}{% endblock %}</title>
<link rel="alternate" type="application/rss+xml" href="{{ widgets::i18n_url(path="rss.xml") }}">
2020-03-29 17:26:12 +02:00
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="{{ get_url(path="style.css") }}" type="text/css">
<link rel="stylesheet" href="{{ get_url(path="water.css") }}" type="text/css">
2020-03-29 17:26:12 +02:00
</head>
<body>
<header>
{% set header = get_page(path="_common/header.md") %}
{{ header.content | markdown | safe }}
2020-03-31 00:16:36 +02:00
{% if translations %}
{{ widgets::bubble(content=widgets::translations(translations=translations), v="top", h="right") }}
{% endif %}
{{ widgets::menu(content="_common/menu.md") }}
2020-03-29 17:26:12 +02:00
</header>
<main>
2020-03-29 17:26:12 +02:00
{% block main %}
2020-04-01 16:35:37 +02:00
{{ section.content | markdown | safe }}
2020-03-29 17:26:12 +02:00
{% endblock %}
</main>
<footer>
{% if config.extra.forge %}
<aside class="source">
2020-03-30 01:50:24 +02:00
{% set translated = trans(key="source", lang=lang) %}
{% if section %}
<a href="{{ config.extra.forge.browse }}content/{{ section.path }}_index.md">{{ translated }}</a>
{% else %}
<a href="{{ config.extra.forge.browse }}content/{{ page.path }}index.md">{{ translated }}</a>
{% endif %}
</aside>
{% endif %}
2020-03-29 17:26:12 +02:00
</footer>
</body>
</html>