Add flexbox layout for academia icons

This commit is contained in:
Thomas A. Christensen II 2022-02-14 20:22:17 -06:00
parent 80ff5ea748
commit b354658c4a
Signed by: millironx
GPG key ID: 139C07724802BC5D

View file

@ -2,26 +2,34 @@
<h2>Selected Presentations</h2> <h2>Selected Presentations</h2>
{{ $featuredpubs := where .Pages ".Params.featured" "==" true }} {{ $featuredpubs := where .Pages ".Params.featured" "==" true }}
{{ range $featuredpubs }} {{ range $featuredpubs }}
<h3> <div class="d-flex py-2">
{{ if eq .Params.type "poster" }}<i class="fad fa-presentation"></i>{{ end }} <div class="px-1">
{{ if eq .Params.type "thesis" }}<i class="fad fa-graduation-cap"></i>{{ end }} <h3>
<a href="{{ .Permalink }}"> {{ if eq .Params.type "poster" }}<i class="fad fa-presentation"></i>{{ end }}
{{ .Title }} {{ if eq .Params.type "thesis" }}<i class="fad fa-graduation-cap"></i>{{ end }}
</a> </h3>
</h3> </div>
{{ $authlist := .Params.authors }} <div class="flex-grow-1 px-1">
{{ range $idx, $auth := .Params.authors }} <h3>
{{ if and (eq $idx (sub (len $authlist) 1)) (gt 1 (len $authlist)) }} <a href="{{ .Permalink }}">
and {{ .Title }}
{{ end }} </a>
{{- if eq $auth "Thomas A. Christensen II" }} </h3>
<strong>{{ $auth }}</strong> {{ $authlist := .Params.authors }}
{{- else }} {{ range $idx, $auth := .Params.authors }}
{{ $auth }} {{ if and (eq $idx (sub (len $authlist) 1)) (gt 1 (len $authlist)) }}
{{- end }} and
{{- if lt $idx (sub (len $authlist) 1) -}} {{ end }}
, {{- if eq $auth "Thomas A. Christensen II" }}
{{- end }} <strong>{{ $auth }}</strong>
{{ end }} {{- else }}
{{ $auth }}
{{- end }}
{{- if lt $idx (sub (len $authlist) 1) -}}
,
{{- end }}
{{ end }}
</div>
</div>
{{ end }} {{ end }}
{{ end }} {{ end }}