From 85b68fd55c968a7c658f45e76929bc92dd4139d3 Mon Sep 17 00:00:00 2001 From: Leilukin Date: Fri, 19 Apr 2024 06:41:26 +0800 Subject: [PATCH] Use article heading if the content is an article --- src/_includes/main/content.njk | 47 +++++++++++++++++++++++++++++++--- 1 file changed, 43 insertions(+), 4 deletions(-) diff --git a/src/_includes/main/content.njk b/src/_includes/main/content.njk index af35b99b..100b67f4 100644 --- a/src/_includes/main/content.njk +++ b/src/_includes/main/content.njk @@ -3,9 +3,37 @@ layout: main/base ---
-

{{ pageTitle or title }}

- {% if desc %} -

{{ desc }}

+ {% if isArticle %} + + +

{{ articleTitle }}

+ + {% else %} +

{{ pageTitle or title }}

+ {% if desc %} +

{{ desc }}

+ {% endif %} {% endif %}
@@ -27,4 +55,15 @@ layout: main/base {% if isArticle or title === "Articles" or tags and tags.includes("blog pages") %} {% include "main/content-nav.njk" %} {% endif %} - \ No newline at end of file + + + \ No newline at end of file