Skip to content
This repository was archived by the owner on Jul 21, 2019. It is now read-only.

Commit 02322e4

Browse files
authored
Make old-style talks compatible (#191)
Signed-off-by: Matt Stratton <matt.stratton@gmail.com>
1 parent 2db358c commit 02322e4

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

layouts/talk/single.html

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ <h2>Speakers</h2>
6666
<h2>Speaker</h2>
6767
{{- end -}}
6868
{{- end -}}
69-
{{- end -}}
69+
7070

7171
{{ range .Params.speakers }}
7272
{{ $.Scratch.Set "speakername" . }}
@@ -89,6 +89,26 @@ <h2>Speaker</h2>
8989
{{- end -}} <!-- end if eq $talk_slug $event_slug -->
9090
{{- end -}} <!-- end range where $.Site.Pages "Type" "speaker" -->
9191
{{ end }}
92+
{{ else }}<!-- now show the old stuff -->
93+
<h2>Speaker</h2>
94+
{{ range $fname, $s := index .Site.Data.speakers (print (chomp $e.year)) $city_slug }}
95+
{{ if in ($.LinkTitle | urlize) $fname }}
96+
<div class="row">
97+
<div class="col-md-12">
98+
<img alt = "{{ $s.name }}" src = "/events/{{ $event_slug }}/speakers/{{$fname}}.jpg" class="img-responsive" width = "250px">
99+
</div>
100+
</div>
101+
<div class = "row">
102+
<div class= "col-md-8">
103+
<h3>{{ $s.name }}</h3>
104+
{{ if $s.twitter }} <a href="https://twitter.com/{{ $s.twitter }}">@{{ $s.twitter }}</a><br>{{ end }}
105+
<br>
106+
{{ $s.bio | markdownify }}
107+
</div>
108+
</div>
109+
{{ end }}
110+
{{ end }}
111+
{{- end -}} <!-- end check for speakers being set -->
92112
</div>
93113
</div>
94114

0 commit comments

Comments
 (0)