aboutsummaryrefslogtreecommitdiff
path: root/layouts/partials/index/components.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/partials/index/components.html')
-rw-r--r--layouts/partials/index/components.html13
1 files changed, 9 insertions, 4 deletions
diff --git a/layouts/partials/index/components.html b/layouts/partials/index/components.html
index 392acb7..803c44f 100644
--- a/layouts/partials/index/components.html
+++ b/layouts/partials/index/components.html
@@ -11,12 +11,17 @@
{{ $categories := .Site.Params.categories }}
{{ range $categories }}
- <div class="category">
+ <div class="category {{ if .closed }}category--closed{{ else }}category--open{{ end }}" id="{{ .name | urlize }}">
{{ if not .untitled }}
- <div class="bold" style="margin: 12px 0">
- {{ if .closed }}⯈{{ else }}⯆{{ end }}
+ <div class="bold padding clicky category__head" onclick="this.parentNode.classList.toggle('category--closed'); this.parentNode.classList.toggle('category--open')">
+ <span class="hide-without-js">
+ <span class="category__closed-marker">⯈</span>
+ <span class="category__open-marker">⯆</span>
+ </span>
- <b>{{ .name }}</b>
+ <b>
+ {{ .name }}
+ </b>
{{ with .description }}
<span class="tooltip tooltip--small">