Website Summary Files Commits Branches @commit @diff @stats
path: root / website / layouts / partials / reveal-hugo / slides.html
blob: e578882025568cd6461cb3b545ad9e23e78a653b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<div class="reveal">
  <!-- Any section element inside of this container is displayed as a slide -->
  <div class="slides">
    <!-- Use the array of pages passed as a param -->
    {{ range . -}}
    <!-- Don't process empty content files -->
      {{- if ne (len .Content) 0 -}}
        <!-- Remove the <hr /> tag generated by blackfriday for footnotes -->
        {{- $content := replace .Content "<div class=\"footnotes\">\n\n<hr />" "<div class=\"footnotes\">" -}}
        <!-- Split the processed content by <hr /> tag -->
        {{- range (split $content "<hr />") -}}
          <!-- Only wrap in <section> tag if not already wrapped by shortcode -->
          {{- if in . "data-noprocess" -}}
{{- . | safeHTML -}}
          {{- else }}
<section>
  {{- . | safeHTML }}
</section>
          {{- end -}}
        {{- end -}}
      {{- end -}}
    {{- end }}
  </div>
</div>