mirror of
https://github.com/nunocoracao/blowfish.git
synced 2025-04-21 02:01:54 +02:00
feat: option to plainify summary
In the release of [Hugo v0.134](https://github.com/gohugoio/hugo/releases/tag/v0.134.0) they changed the way summaries are done. Not plainifying the summaries leads to layout issues in lists, this fixes that Signed-off-by: Vegard Hagen <vegard@stonegarden.dev>
This commit is contained in:
parent
f037da3120
commit
08b692fcb1
4 changed files with 13 additions and 0 deletions
|
@ -90,6 +90,7 @@ forgejoDefaultServer = "https://v8.next.forgejo.org"
|
|||
layoutBackgroundHeaderSpace = true # only used when heroStyle equals background
|
||||
showBreadcrumbs = false
|
||||
showSummary = false
|
||||
plainifySummary = true # only used when showSummary = true
|
||||
showViews = false
|
||||
showLikes = false
|
||||
showTableOfContents = false
|
||||
|
|
|
@ -65,7 +65,11 @@
|
|||
|
||||
{{ if .Params.showSummary | default (.Site.Params.list.showSummary | default false) }}
|
||||
<div class="py-1 prose dark:prose-invert">
|
||||
{{- if .Params.plainifySummary | default (.Site.Params.list.plainifySummary | default true) }}
|
||||
{{ .Summary | plainify }}
|
||||
{{- else }}
|
||||
{{ .Summary }}
|
||||
{{- end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
|
|
@ -66,7 +66,11 @@
|
|||
|
||||
{{ if .Params.showSummary | default (.Site.Params.list.showSummary | default false) }}
|
||||
<div class="py-1 prose dark:prose-invert">
|
||||
{{- if .Params.plainifySummary | default (.Site.Params.list.plainifySummary | default true) }}
|
||||
{{ .Summary | plainify }}
|
||||
{{- else }}
|
||||
{{ .Summary }}
|
||||
{{- end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
|
|
@ -94,7 +94,11 @@
|
|||
</div>
|
||||
{{ if .Params.showSummary | default (.Site.Params.list.showSummary | default false) }}
|
||||
<div class="py-1 max-w-fit prose dark:prose-invert">
|
||||
{{- if .Params.plainifySummary | default (.Site.Params.list.plainifySummary | default true) }}
|
||||
{{ .Summary | plainify }}
|
||||
{{- else }}
|
||||
{{ .Summary }}
|
||||
{{- end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
|
Loading…
Add table
Reference in a new issue