mirror of
https://github.com/McShelby/hugo-theme-relearn.git
synced 2025-06-02 06:54:04 +00:00
theme: make content footer configurable #1025
This commit is contained in:
parent
00590db6bb
commit
1ebb5451c3
13 changed files with 103 additions and 15 deletions
docs/content/configuration/content
headings
hidden
linking
meta
|
@ -3,7 +3,7 @@ categories = ["howto"]
|
|||
description = "Configuring heading anchors"
|
||||
options = ["disableAnchorCopy", "disableAnchorScrolling"]
|
||||
title = "Headings"
|
||||
weight = 3
|
||||
weight = 4
|
||||
+++
|
||||
|
||||
Headings can have anchor links that appear when you hover over them.
|
||||
|
|
|
@ -3,6 +3,6 @@ categories = ["howto"]
|
|||
description = "Configuring heading anchors"
|
||||
options = ["disableAnchorCopy", "disableAnchorScrolling"]
|
||||
title = "Headings"
|
||||
weight = 3
|
||||
weight = 4
|
||||
+++
|
||||
{{< piratify >}}
|
|
@ -3,7 +3,7 @@ categories = ["explanation", "howto"]
|
|||
description = "Learn about the hidden pages feature"
|
||||
options = ["disableSearchHiddenPages", "disableSeoHiddenPages", "disableTagHiddenPages"]
|
||||
title = "Hidden Pages"
|
||||
weight = 5
|
||||
weight = 6
|
||||
+++
|
||||
|
||||
This theme allows you to [create hidden pages](authoring/meta#hidden).
|
||||
|
|
|
@ -3,6 +3,6 @@ categories = ["explanation", "howto"]
|
|||
description = "Learn about the hidden pages feature"
|
||||
options = ["disableSearchHiddenPages", "disableSeoHiddenPages", "disableTagHiddenPages"]
|
||||
title = "Hidden Pages"
|
||||
weight = 5
|
||||
weight = 6
|
||||
+++
|
||||
{{< piratify >}}
|
|
@ -3,7 +3,7 @@ categories = ["howto"]
|
|||
description = "What options are available for links and images"
|
||||
options = ["disableDefaultRelref", "disableExplicitIndexURLs"]
|
||||
title = "Linking"
|
||||
weight = 4
|
||||
weight = 5
|
||||
+++
|
||||
|
||||
Further [settings are available](authoring/frontmatter/linking) to be used in your configuration or front matter.
|
||||
|
|
|
@ -3,6 +3,6 @@ categories = ["howto"]
|
|||
description = "What options are available for links and images"
|
||||
options = ["disableDefaultRelref", "disableExplicitIndexURLs"]
|
||||
title = "Linking"
|
||||
weight = 4
|
||||
weight = 5
|
||||
+++
|
||||
{{< piratify >}}
|
49
docs/content/configuration/content/meta/index.en.md
Normal file
49
docs/content/configuration/content/meta/index.en.md
Normal file
|
@ -0,0 +1,49 @@
|
|||
+++
|
||||
categories = ["howto"]
|
||||
description = "Display page meta information with your content"
|
||||
options = ["dateFormat", "hideAuthorName", "hideAuthorEmail", "hideAuthorDate"]
|
||||
title = "Page Meta Information"
|
||||
weight = 3
|
||||
+++
|
||||
|
||||
The theme supports a default display of page meta information in `layouts/partials/content-footer.html`.
|
||||
|
||||
The content footer dynamically pulls information based on the availability of [GitInfo metadata](https://gohugo.io/methods/page/gitinfo/). If Git information is present, it uses the author's name, email, and the date from the Git commit details. This ensures that the displayed information is always up-to-date with the latest modifications.
|
||||
|
||||
In cases where Git information is not available, the theme falls back to `LastModifierDisplayName`, `LastModifierEmail`, and `Date` [defined in the page's front matter](authoring/meta#footer-information).
|
||||
|
||||
## Disable Display of Author's Name
|
||||
|
||||
{{% badge style="cyan" icon="gears" title=" " %}}Option{{% /badge %}} You can disable the output of an author's name and its according email address by setting this parameter to `true`.
|
||||
|
||||
{{< multiconfig file=hugo >}}
|
||||
[params]
|
||||
hideAuthorName = true
|
||||
{{< /multiconfig >}}
|
||||
|
||||
## Disable Display of Author's Email
|
||||
|
||||
{{% badge style="cyan" icon="gears" title=" " %}}Option{{% /badge %}} The author's email, when displayed, is presented as a clickable mailto link, providing a convenient way for readers to reach out. You can disable the output of an author's email address by setting this parameter to `true`.
|
||||
|
||||
{{< multiconfig file=hugo >}}
|
||||
[params]
|
||||
hideAuthorEmail = true
|
||||
{{< /multiconfig >}}
|
||||
|
||||
## Disable Display of Authoring Date
|
||||
|
||||
{{% badge style="cyan" icon="gears" title=" " %}}Option{{% /badge %}} # If the standard content-footer finds an authoring date, you can disable its output by setting this parameter to `true`.
|
||||
|
||||
{{< multiconfig file=hugo >}}
|
||||
[params]
|
||||
hideAuthorEmail = true
|
||||
{{< /multiconfig >}}
|
||||
|
||||
## Adjust the Timestamp Format
|
||||
|
||||
{{% badge style="cyan" icon="gears" title=" " %}}Option{{% /badge %}} You can overwrite the default date format used when displaying a pages meta information. See [the Hugo docs](https://gohugo.io/functions/time/format/#localization) for possible values.
|
||||
|
||||
{{< multiconfig file=hugo >}}
|
||||
[params]
|
||||
dateFormat = ':date_medium'
|
||||
{{< /multiconfig >}}
|
8
docs/content/configuration/content/meta/index.pir.md
Normal file
8
docs/content/configuration/content/meta/index.pir.md
Normal file
|
@ -0,0 +1,8 @@
|
|||
+++
|
||||
categories = ["howto"]
|
||||
description = "Display page meta information with your content"
|
||||
options = ["dateFormat", "hideAuthorName", "hideAuthorEmail", "hideAuthorDate"]
|
||||
title = "Page Meta Information"
|
||||
weight = 3
|
||||
+++
|
||||
{{< piratify >}}
|
Loading…
Add table
Add a link
Reference in a new issue