bunteshaus.de/themes/buha/layouts/partials/single/article.html

38 lines
995 B
HTML
Raw Normal View History

2022-04-03 01:27:41 +02:00
<div id="articletitle">
<h1>{{- .Title -}}</h1>
</div>
2022-04-04 05:39:34 +02:00
{{- $pic := index (.Resources.ByType "image") 0 -}}
2022-04-03 01:27:41 +02:00
<article>
<div id="articlecontent">
2022-04-04 11:21:48 +02:00
{{ partial "structure/article_meta" (dict "context" . "visible" "all") }}
{{ $small := "solo" }}
{{ $big := "solo" }}
{{- if and (.Resources.ByType "image") (.Content) -}}
{{ $small = "multiple_small" }}
{{ $big = "multiple_big" }}
{{ else }}
{{ $small = "multiple_big"}}
{{ end }}
2022-04-03 01:27:41 +02:00
<div id="articleinner">
2022-04-04 11:21:48 +02:00
{{- if .Resources.ByType "image" -}}
{{- $pic := index (.Resources.ByType "image") 0 -}}
{{- $thumb := $pic.Resize "2048x" }}
{{ if ne .Content "" }}
{{- $thumb = $pic.Resize "1024x" }}
{{ end }}
<div id="articlepicture" class="{{ $small }} borderrad25">
<img src="{{- $thumb.Permalink -}}" class="borderrad25" />
2022-04-03 01:27:41 +02:00
</div>
2022-04-04 11:21:48 +02:00
{{ end }}
{{- if .Content -}}
<div id="articletext" class="{{ $big }}">
{{- .Content -}}
</div>
{{- end }}
2022-04-03 01:27:41 +02:00
</div>
</div>
2022-04-03 02:33:46 +02:00
</article>
2022-04-03 21:08:42 +02:00