mirror of
https://github.com/by-jp/www.byjp.me.git
synced 2025-08-08 17:15:56 +01:00
Fix homepage photo caption
This commit is contained in:
parent
bf0186a315
commit
89c14e2dae
1 changed files with 2 additions and 2 deletions
|
@ -50,8 +50,8 @@
|
|||
{{- $src := index $picPage.Params.Media 0 -}}
|
||||
<a href="{{ .RelPermalink }}"><img src="{{ path.Join .RelPermalink $src.url }}" {{ with $src.alt }}alt="{{ . }}" {{ end }} /></a>
|
||||
<figcaption>
|
||||
{{- $shortSummary := index (split .Summary "\n") 0 -}}
|
||||
{{- $shortSummary | htmlUnescape }}{{ if gt (len .Summary) (len $shortSummary) }} <a href="{{ .RelPermalink }}">→</a>{{ end -}}
|
||||
{{- $shortSummary := index (split .Summary "</p>") 0 -}}
|
||||
{{- $shortSummary | plainify | htmlUnescape | strings.TrimSpace }} <a href="{{ .RelPermalink }}">→</a>
|
||||
</figcaption>
|
||||
</figure>
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue