about summary refs log tree commit diff stats
path: root/templates/index.html
diff options
context:
space:
mode:
authorAlan Pearce2020-11-14 21:17:02 +0100
committerAlan Pearce2020-11-14 21:52:50 +0100
commit5de7de4e64cb20183ebfe86e16578f4abd62a23e (patch)
treed3e24ee322d24c03a5e6563ace11c1c588881368 /templates/index.html
parentd996657be5efda94f4a934d5d78c407ba47bf76c (diff)
downloadwebsite-5de7de4e64cb20183ebfe86e16578f4abd62a23e.tar.lz
website-5de7de4e64cb20183ebfe86e16578f4abd62a23e.tar.zst
website-5de7de4e64cb20183ebfe86e16578f4abd62a23e.zip
Port theme to zola template
Diffstat (limited to 'templates/index.html')
-rw-r--r--templates/index.html36
1 files changed, 36 insertions, 0 deletions
diff --git a/templates/index.html b/templates/index.html
new file mode 100644
index 0000000..23ec4cd
--- /dev/null
+++ b/templates/index.html
@@ -0,0 +1,36 @@
+{% extends "base.html" %}
+
+{% block main %}
+<main class="h-card">
+  <h1 class="p-name">{{ config.title }}</h1>
+  {{ section.content | safe }}
+  <section>
+    <h2>Latest Posts</h2>
+    <ul class="h-feed">
+      {%- for page in section.pages | slice(end=3) %}
+        <li class="h-entry">
+          <time class="dt-published" datetime="{{ page.date | date(format="%+") }}">{{ page.date | date(format="%F") }}</time>
+          <a class="u-url p-name" href="{{ page.path | safe }}">{{ page.title }}</a>
+        </li>
+      {%- endfor %}
+    </ul>
+  </section>
+  <section>
+    <h2>Elsewhere on the Internet</h2>
+    <ul>
+      {%- for item in config.extra.menu.contact %}
+        <li>
+          {%- if item.url is starting_with("mailto:") %}
+            <a href="{{ item.url | safe }}" class="u-email email" rel="me">{{ item.name }}</a>
+          {%- else %}
+            <a href="{{ item.url | safe }}" class="u-url url" rel="me">{{ item.name }}</a>
+          {%- endif %}
+        </li>
+      {%- endfor %}
+    </ul>
+  </section>
+  <footer>
+    GPG Key: <a href="{{ config.extra.gpg_url | safe }}" rel="u-key pgpkey">{{ config.extra.gpg_fingerprint }}</a>
+  </footer>
+</main>
+{% endblock %}