aboutsummaryrefslogtreecommitdiff
path: root/layouts
diff options
context:
space:
mode:
Diffstat (limited to 'layouts')
-rw-r--r--layouts/partials/index/components.html13
-rw-r--r--layouts/partials/index/summary.html2
-rw-r--r--layouts/partials/meta.html29
3 files changed, 32 insertions, 12 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">
diff --git a/layouts/partials/index/summary.html b/layouts/partials/index/summary.html
index d8e3108..de6bceb 100644
--- a/layouts/partials/index/summary.html
+++ b/layouts/partials/index/summary.html
@@ -20,5 +20,5 @@
{{ end }}{{ end }}{{ end }}
</strong>
- <span class="summary__date float-right" onclick="location.reload()"></span>
+ <div class="summary__date clicky float-right" onclick="location.reload()"></div>
</div> \ No newline at end of file
diff --git a/layouts/partials/meta.html b/layouts/partials/meta.html
index ad4655a..1acf474 100644
--- a/layouts/partials/meta.html
+++ b/layouts/partials/meta.html
@@ -20,6 +20,8 @@
var themeNoticeColor = '#{{ .Site.Params.notice }}';
var themeDisruptedColor = '#{{ .Site.Params.disrupted }}';
var themeDownColor = '#{{ .Site.Params.down }}';
+
+
</script>
<!-- Sources -->
<style>
@@ -109,6 +111,24 @@
.right { text-align: right; }
.padding-s { padding: 6px; }
.padding { padding: 12px; }
+ .clicky { cursor: pointer; }
+
+
+ /**
+ * Categories
+ */
+
+ /* Categories themselves */
+ .js .category--open .category__closed-marker { display: none; }
+ .js .category--closed .components { display: none; }
+ .js .category--closed .category__open-marker { display: none; }
+
+ /* Markers */
+ .js .hidden-with-js { display: none; }
+ .hide-without-js { display: none; }
+ .js span.hide-without-js { display: inline; }
+ .js div.hide-without-js { display: block; }
+
/**
* UI elements
@@ -182,11 +202,6 @@
color: #fff;
}
- .summary__date {
- display: block;
- cursor: pointer;
- }
-
.summary__date:hover {
color: #ccc;
}
@@ -268,8 +283,8 @@
*/
.issue { display: block; padding: 14px 24px; }
- .issue:hover { background: #f5f5f5; }
- .issue:active { background: #eee; }
+ .issue:hover, .category__head:hover { background: #f5f5f5; }
+ .issue:active, .category__head:active { background: #eee; }
.issue h3 { line-height: 1.25; }