48 lines
2 KiB
HTML
48 lines
2 KiB
HTML
{{- $team := .team }}
|
|
{{- $pages := .pages}}
|
|
{{- $defaultimage := .defaultimage}}
|
|
{{- $odd := .odd }}
|
|
{{- $id := "team"}}
|
|
{{if $team.id}}
|
|
{{- $id = $team.id}}
|
|
{{else if .id}}
|
|
{{- $id = .id }}
|
|
{{end}}
|
|
{{- $members := where $pages "Params.leaveDate" "==" nil}}
|
|
{{- $first := $team.first | default 4}}
|
|
<div id="{{ $id }}" class="section {{if eq $odd 0}} section-even {{end}}">
|
|
<div class="section-content team">
|
|
{{ partial "components/title.html" $team.title }}
|
|
<div class="list">
|
|
{{- range first $first ($members.ByParam "startDate") }}
|
|
<a href="{{.Permalink}}">
|
|
<div class="member">
|
|
{{ if .Params.image }}
|
|
{{- partial "components/image.html" (dict "style" "avatar" "url" .Params.image "alt" .Params.name) -}}
|
|
{{ else }}
|
|
{{- partial "components/image.html" (dict "style" "avatar" "url" $defaultimage "alt" "Placeholder") -}}
|
|
{{ end }}
|
|
<h1 class="title">{{ .Params.name }}</h1>
|
|
{{- range .Params.jobs }}
|
|
<p>{{ . }}</p>
|
|
{{- end }}
|
|
<div class="social-media">
|
|
<span>
|
|
{{- range .Params.social}}
|
|
{{ partial "components/icon.html" . }}
|
|
{{- end}}
|
|
{{ if .Params.mail }}
|
|
{{ $mailto := "mailto:{{ .Params.mail }}" }}
|
|
{{ partial "components/icon.html" (dict "type" "at" "url" $mailto) }}
|
|
{{ end }}
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</a>
|
|
{{- end }}
|
|
</div>
|
|
{{ if gt $members.Len $first }}
|
|
{{ partial "components/button.html" (dict "type" "text block" "url" $team.id "text" ($team.more | default "More")) }}
|
|
{{ end }}
|
|
</div>
|
|
</div>
|