From 9d508170eeb0aa64ee0a45b22805d828bc45105a Mon Sep 17 00:00:00 2001 From: Helen Chong <119173961+helenclx@users.noreply.github.com> Date: Tue, 16 Apr 2024 00:55:42 +0800 Subject: [PATCH] Use desc instead of intro variable for description in the heading --- src/_includes/main/content.njk | 4 ++-- src/index.njk | 3 +-- src/pages/about.njk | 3 +-- src/pages/articles.md | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/src/_includes/main/content.njk b/src/_includes/main/content.njk index 72e27f19..f04a6a35 100644 --- a/src/_includes/main/content.njk +++ b/src/_includes/main/content.njk @@ -4,8 +4,8 @@ layout: main/base

{{ pageTitle or title }}

- {% if intro %} -

{{ intro }}

+ {% if desc %} +

{{ desc }}

{% endif %}
diff --git a/src/index.njk b/src/index.njk index 0d8f7772..34d8bb84 100644 --- a/src/index.njk +++ b/src/index.njk @@ -2,10 +2,9 @@ layout: main/content tags: pages pageTitle: Welcome! -intro: Home page of Leilukin's Hub. +desc: Home page of Leilukin's Hub. metadata: title: Home - desc: Home page of Leilukin's Hub. date: 2023-01-01 isContentDivided: true --- diff --git a/src/pages/about.njk b/src/pages/about.njk index d70e04ce..12adf5d8 100644 --- a/src/pages/about.njk +++ b/src/pages/about.njk @@ -1,11 +1,10 @@ --- layout: main/content title: About +desc: About this website and its owner. metadata: - desc: About this website and its owner. type: article date: 2023-01-02 -intro: Learn more about this website and its owner. isContentDivided: true --- diff --git a/src/pages/articles.md b/src/pages/articles.md index 2b0a0377..a1df08ce 100644 --- a/src/pages/articles.md +++ b/src/pages/articles.md @@ -1,8 +1,8 @@ --- layout: main/content title: Articles +desc: List of articles published on my website. metadata: - desc: List of articles published on my website. type: article date: 2023-01-04 templateEngineOverride: njk, md