mirror of
https://github.com/maikka39/Personal-Website.git
synced 2026-10-02 14:46:25 +00:00
Remove heading in figcaption when necessary
This commit is contained in:
@@ -14,17 +14,23 @@
|
||||
{{- if .Get "link" }}</a>{{ end -}}
|
||||
{{- if or (or (.Get "title") (.Get "caption")) (.Get "attr") -}}
|
||||
<figcaption>
|
||||
{{ with (.Get "title") -}}
|
||||
{{- if or (.Get "caption") (.Get "attr") -}}
|
||||
{{- with (.Get "title") -}}
|
||||
<h4>{{ . }}</h4>
|
||||
{{- end -}}
|
||||
{{- if or (.Get "caption") (.Get "attr") -}}<p>
|
||||
<p>
|
||||
{{- .Get "caption" | markdownify -}}
|
||||
{{- with .Get "attrlink" }}
|
||||
<a href="{{ . }}">
|
||||
{{- end -}}
|
||||
{{- .Get "attr" | markdownify -}}
|
||||
{{- if .Get "attrlink" }}</a>{{ end }}</p>
|
||||
{{- end }}
|
||||
{{- if .Get "attrlink" }}</a>{{ end }}
|
||||
</p>
|
||||
{{- else -}}
|
||||
{{- with (.Get "title") -}}
|
||||
{{ . }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
</figcaption>
|
||||
{{- end }}
|
||||
</figure>
|
||||
Reference in New Issue
Block a user