From 7d2b5b6c07821dc2c0b7de82ae4bb38d4d31e8c9 Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Fri, 9 Mar 2018 23:14:07 +0100 Subject: [PATCH] =?UTF-8?q?Add=20a=20=E2=80=9Cnews=E2=80=9D=20category?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- blog/content/news/_index.md | 4 ++++ blog/templates/news-page.html | 28 ++++++++++++++++++++++++++++ blog/templates/news-section.html | 28 ++++++++++++++++++++++++++++ 3 files changed, 60 insertions(+) create mode 100644 blog/content/news/_index.md create mode 100644 blog/templates/news-page.html create mode 100644 blog/templates/news-section.html diff --git a/blog/content/news/_index.md b/blog/content/news/_index.md new file mode 100644 index 00000000..69703970 --- /dev/null +++ b/blog/content/news/_index.md @@ -0,0 +1,4 @@ ++++ +title = "News" +template = "news-section.html" ++++ diff --git a/blog/templates/news-page.html b/blog/templates/news-page.html new file mode 100644 index 00000000..7f5f9a4c --- /dev/null +++ b/blog/templates/news-page.html @@ -0,0 +1,28 @@ +{% extends "base.html" %} + +{% block title %}{{ page.title }} | {{ config.title }}{% endblock title %} + +{% block main %} +

{{ page.title }}

+ + {{ page.content | safe }} +{% endblock main %} + +{% block after_main %} +
+
+

Comments

+ +
+ +{% endblock after_main %} + + diff --git a/blog/templates/news-section.html b/blog/templates/news-section.html new file mode 100644 index 00000000..4126e35b --- /dev/null +++ b/blog/templates/news-section.html @@ -0,0 +1,28 @@ +{% extends "base.html" %} + +{% import "macros.html" as macros %} + +{% block title %}{{ section.title }} | {{ config.title }}{% endblock title %} + +{% block main %} + +

{{ section.title }}

+ +{% block introduction %}{% endblock introduction %} + +
+ {% for page in section.pages|reverse %} + + {% endfor %} +
+ +{% endblock main %}