Commit ed4ee8d1 authored by Coffee's avatar Coffee

Support optional authorURL in news

Optionally linkify author at the top of his post as well as on the News
overview page, if the 'authorWebsite' key is present.
parent f0fff8f9
......@@ -10,6 +10,9 @@ layout: default
Posted on {{ page.date | date: "%b %-d, %Y" }}
{% if page.author %}
by
{% if page.authorWebsite %}
<a href="{{ page.authorWebsite }}">
{% endif %}
<img
src="{{ site.baseurl }}/assets/{{ page.author }}.jpg"
alt="{{ page.author }}"
......@@ -22,6 +25,9 @@ layout: default
itemprop="name">{{ page.author }}
</span>
</span>
{% if page.authorWebsite %}
</a>
{% endif %}
{% endif %}
</i>
</header>
......
......@@ -16,6 +16,9 @@ redirect_from:
Posted on {{ post.date | date: "%b %-d, %Y" }}
{% if post.author %}
by
{% if post.authorWebsite %}
<a href="{{ post.authorWebsite }}">
{% endif %}
<img
src="{{ site.baseurl }}/assets/{{ post.author }}.jpg"
alt="{{ post.author }}"
......@@ -28,6 +31,9 @@ redirect_from:
itemprop="name">{{ post.author }}
</span>
</span>
{% if post.authorWebsite %}
</a>
{% endif %}
{% endif %}
</i>
<div>
......
......@@ -2,7 +2,7 @@
layout: post
title: "This Week in F-Droid"
author: "Coffee"
authorWebsite: "https://forum.f-droid.org/u/coffee"
---
Hi everyone! This is a little experiment triggered by the [Matrix Project](https://matrix.org/) starting their own [TWIM](https://matrix.org/blog/2018/04/20/this-week-in-matrix-2018-04-20/) (This Week In Matrix), who in turn stole the idea off [TWIR](https://this-week-in-rust.org/) (This Week In Rust). Therefore, we now give you the first trial TWIF!
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment