cupper-hugo-theme/themes/infusion/layouts/shortcodes/principles.html
2017-07-08 12:21:43 +01:00

23 lines
823 B
HTML

{{ $JSON := $.Site.Data.principles }}
{{ $included := replace (.Get "include") ", " "," }}
{{ $included := apply (split $included ",") "lower" "." }}
{{ $descriptions := .Get "descriptions" }}
<ul class="principles {{ if $descriptions }}with-desc{{ end }}">
{{ range $JSON.principles }}
{{ if in $included (lower .title) }}
<li>
<strong>
<a href="https://inclusivedesignprinciples.org#{{ .title | urlize }}">
<svg class="balloon-icon" height="177.17" width="141.73" viewBox="0 0 141.73228 177.16535" aria-hidden="true"><use xlink:href="#balloon"></use></svg>
{{ .title }}
</a>:
</strong>
<em>{{ .strapline }}</em>
{{ if $descriptions }}
<p>{{ .description }}</p>
{{ end }}
</li>
{{ end }}
{{ end }}
</ul>