Set up template inheritance
All checks were successful
Build / build (push) Successful in 2m30s

This commit is contained in:
Frederik Ring 2023-09-03 18:46:44 +02:00
parent 12761b809c
commit 04413b58b7
4 changed files with 17 additions and 9 deletions

View File

@ -9,6 +9,7 @@ services:
- 9001:80 - 9001:80
website: website:
restart: always
build: build:
context: '.' context: '.'
dockerfile: ./Dockerfile.python dockerfile: ./Dockerfile.python

View File

@ -1,7 +1,7 @@
title: offen.software title: offen.software
description: TBD description: TBD
save_as: index.html save_as: index.html
template: index template: page
sitemap_priority: 1.0 sitemap_priority: 1.0
# offen.software website # offen.software website

View File

@ -3,7 +3,7 @@
{% block head %} {% block head %}
<head> <head>
<title> <title>
{% block title %}{{ page.title }}{% endblock %} {% block title %}{{ title }}{% endblock %}
</title> </title>
<meta charset="UTF-8"> <meta charset="UTF-8">
<meta http-equiv="Content-Security-Policy" content="default-src 'self'"> <meta http-equiv="Content-Security-Policy" content="default-src 'self'">
@ -12,22 +12,20 @@
<meta name="description" content="{{ description }}"> <meta name="description" content="{{ description }}">
<meta property="og:site_name" content="{{ SITENAME }}"> <meta property="og:site_name" content="{{ SITENAME }}">
<meta property="og:locale" content="{{ DEFAULT_LANG }}"> <meta property="og:locale" content="{{ DEFAULT_LANG }}">
<meta property="og:title" content="{{ page.title }}"> <meta property="og:title" content="{{ title }}">
<meta property="og:description" content="{{ page.description }}"> <meta property="og:description" content="{{ description }}">
<meta property="og:type" content="website"> <meta property="og:type" content="website">
<meta property="og:url" content="{{ SITEURL }}/{{ page.href }}"> <meta property="og:url" content="{{ SITEURL }}/{{ href }}">
<link rel="canonical" href="{{ SITEURL }}/{{ page.href }}"> <link rel="canonical" href="{{ SITEURL }}/{{ href }}">
{% assets filters="postcss", output="css/style.min.css", "css/tachyons.min.css", "css/styles.css" %} {% assets filters="postcss", output="css/style.min.css", "css/tachyons.min.css", "css/styles.css" %}
<link rel="stylesheet" href="/{{ ASSET_URL }}"> <link rel="stylesheet" href="/{{ ASSET_URL }}">
{% endassets %} {% endassets %}
</head> </head>
{% endblock %} {% endblock %}
<body class="no-js"> <body class="no-js">
{% block body %}{% endblock %}
<script> <script>
document.body.classList.remove('no-js'); document.body.classList.remove('no-js');
</script> </script>
{% block content %}
{{ page.content }}
{% endblock %}
</body> </body>
</html> </html>

View File

@ -0,0 +1,9 @@
{% extends "_layout.html" %}
{% set href = page.href %}
{% set title = page.title %}
{% set description = page.description %}
{% block body %}
{{ page.content }}
{% endblock %}