feat: simple buttons to show links for media

This commit is contained in:
2026-02-13 00:39:08 +01:00
parent 75f7f22c75
commit bc7ec2915e
6 changed files with 58 additions and 4 deletions

View File

@@ -199,7 +199,7 @@ html, body {
font-size: 18px;
.header-image {
margin-bottom: 1em;
margin-bottom: 0.5em;
img {
width: 100%;
@@ -215,6 +215,10 @@ html, body {
margin-bottom: 0;
}
}
.blog-links {
margin-bottom: 1em;
}
}
/* Metadata */

View File

@@ -51,7 +51,8 @@
<div class="panel panel-default">
<div class="panel-body">
<div class="blogpost">
{{ partial "blog/headerimage" . }}
{{- partial "blog/headerimage" . }}
{{- partial "blog/links" . }}
{{ .Content }}
<!-- only show related posts if param is true, or if it's not a page -->
{{ if or (eq .Params.related true) (ne .Params.page true) }}

View File

@@ -0,0 +1,27 @@
<div class="blog-links">
{{- with .Params.event }}
<a class="btn btn-default button-event" href="{{ .href }}" target="_blank" aria-label="Event Page" role="button">
<i class="fas fa-calendar-alt" aria-hidden="true"></i>&nbsp;&nbsp;{{ .name }}
</a>
{{- end }}
{{- with .Params.audio }}
<a class="btn btn-default button-audio" href="{{ . }}" target="_blank" aria-label="Audio Recording" role="button">
<i class="fas fa-microphone" aria-hidden="true"></i>&nbsp;&nbsp;Listen to Recording
</a>
{{- end }}
{{- with .Params.article }}
<a class="btn btn-default button-article" href="{{ .href }}" target="_blank" aria-label="Related Article" role="button">
<i class="fas fa-newspaper" aria-hidden="true"></i>&nbsp;&nbsp;Read {{ .name }} Article
</a>
{{- end }}
{{- with .Params.video }}
<a class="btn btn-default button-video" href="{{ . }}" target="_blank" aria-label="Video Recording" role="button">
<i class="fas fa-video" aria-hidden="true"></i>&nbsp;&nbsp;Watch Recording
</a>
{{- end }}
{{- with .Params.slides }}
<a class="btn btn-default button-slides" href="{{ . }}" target="_blank" aria-label="Slides" role="button">
<i class="fas fa-desktop" aria-hidden="true"></i>&nbsp;&nbsp;View Slides
</a>
{{- end }}
</div>