Skip to content

Commit da6e9df

Browse files
committed
feat: added bottom navbar to be able to navigate between videos easily
1 parent 992366e commit da6e9df

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

layouts/_default/baseof.html

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,17 @@ <h2>{{ .Params.video_title }}</h2>
165165
<div id="video-container">
166166
<iframe src="https://player.vimeo.com/video/{{ .Params.ext_id }}?title=0&amp;byline=0&amp;portrait=0&amp;color=f14e32" width="635" height="360" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe>
167167
</div>
168+
<div class="bottom-nav" style="display: block;">
169+
{{ $prev := where .Site.RegularPages "Params.episode" (sub .Params.episode 1) }}
170+
{{ with index $prev 0 }}
171+
<a class="previous" href="{{ .RelPermalink }}">← Previous</a>
172+
{{ end }}
173+
{{ $next := where .Site.RegularPages "Params.episode" (add .Params.episode 1) }}
174+
{{ with index $next 0 }}
175+
<a class="next" href="{{ .RelPermalink }}">Next →</a>
176+
{{ end }}
177+
</div>
178+
168179
</div>
169180
{{ else if eq $section "about" }}
170181
<div id="main">

0 commit comments

Comments
 (0)