From d2658607b749e2b3eab327eb25ef219165d2aadf Mon Sep 17 00:00:00 2001 From: Lars Olesen Date: Tue, 26 May 2020 12:56:19 +0000 Subject: [PATCH] Move page date to own file --- _includes/page__date.html | 5 +++++ _layouts/single.html | 6 +----- 2 files changed, 6 insertions(+), 5 deletions(-) create mode 100644 _includes/page__date.html diff --git a/_includes/page__date.html b/_includes/page__date.html new file mode 100644 index 000000000000..e663f9b9c7f0 --- /dev/null +++ b/_includes/page__date.html @@ -0,0 +1,5 @@ +{% if page.last_modified_at %} +

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

+{% elsif page.date %} +

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

+{% endif %} diff --git a/_layouts/single.html b/_layouts/single.html index d799abed0d05..c58eca02330f 100644 --- a/_layouts/single.html +++ b/_layouts/single.html @@ -51,11 +51,7 @@

{{ site.data.ui-text[site.locale].meta_label }}

{% endif %} {% include page__taxonomy.html %} - {% if page.last_modified_at %} -

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

- {% elsif page.date %} -

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

- {% endif %} + {% include page__date.html %} {% if page.share %}{% include social-share.html %}{% endif %}