jekyll-theme-miniplex 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_includes/navigation_desktop.html +2 -2
- data/_includes/navigation_mobile.html +4 -4
- data/_layouts/default.html +3 -2
- data/_sass/jekyll-theme-miniplex.sass +26 -4
- data/assets/js/main.coffee +5 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 64e3a3cf4110f8d986903b10c1096034114fd368e2468cf274d93caede776a80
|
4
|
+
data.tar.gz: e3a1e562e779741b1719c3b419a9b46fabd73bd2b0d0a0125c40daaff5170fd0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 84890a8f7a2e6804fd6cf9ac90794e49782c53553b71c2910555073d46cf60e118a082ab166f738fc09250186a4b7c7ef18e78624e0d121e621427d8e156f7e5
|
7
|
+
data.tar.gz: 82db7fe119d23d4d497d35575968c831d40b8359816707a5a9ad74cd49e4bf5de687df9c0b6d47211c1520d14f0c8c5f980705f8f39b3d14813876ff89bbfffc
|
@@ -6,7 +6,7 @@
|
|
6
6
|
{% assign site_pages = site.pages %}
|
7
7
|
{% for listed_page in site_pages %}
|
8
8
|
{% if listed_page.url == page.url %}
|
9
|
-
<li><a href="{{listed_page.url}}" class="active">{{listed_page.title}}</a></li>
|
9
|
+
<li><a href="{{listed_page.url}}" class="active">{{listed_page.title}} <span class="visually-hidden">(Current page)</span></a></li>
|
10
10
|
{% else %}
|
11
11
|
<li><a href="{{listed_page.url}}">{{listed_page.title}}</a></li>
|
12
12
|
{% endif %}
|
@@ -19,7 +19,7 @@
|
|
19
19
|
{% assign site_posts = site.posts %}
|
20
20
|
{% for listed_post in site_posts %}
|
21
21
|
{% if listed_post.url == page.url %}
|
22
|
-
<li><a href="{{listed_post.url}}" class="active">{{listed_post.title}}</a></li>
|
22
|
+
<li><a href="{{listed_post.url}}" class="active">{{listed_post.title}} <span class="visually-hidden">(Current page)</span></a></li>
|
23
23
|
{% else %}
|
24
24
|
<li><a href="{{listed_post.url}}">{{listed_post.title}}</a></li>
|
25
25
|
{% endif %}
|
@@ -1,13 +1,13 @@
|
|
1
1
|
<div id="transparent-nav-close-area">
|
2
2
|
</div>
|
3
|
-
<ul id="navigation-items">
|
3
|
+
<ul id="navigation-items" aria-hidden="true">
|
4
4
|
<li>Pages</li>
|
5
5
|
<li>
|
6
6
|
<ul>
|
7
7
|
{% assign site_pages = site.pages %}
|
8
8
|
{% for listed_page in site_pages %}
|
9
9
|
{% if listed_page.url == page.url %}
|
10
|
-
<li><a href="{{listed_page.url}}" class="active">{{listed_page.title}}</a></li>
|
10
|
+
<li><a href="{{listed_page.url}}" class="active">{{listed_page.title}} <span class="visually-hidden">(Current page)</span></a></li>
|
11
11
|
{% else %}
|
12
12
|
<li><a href="{{listed_page.url}}">{{listed_page.title}}</a></li>
|
13
13
|
{% endif %}
|
@@ -20,7 +20,7 @@
|
|
20
20
|
{% assign site_posts = site.posts %}
|
21
21
|
{% for listed_post in site_posts %}
|
22
22
|
{% if listed_post.url == page.url %}
|
23
|
-
<li><a href="{{listed_post.url}}" class="active">{{listed_post.title}}</a></li>
|
23
|
+
<li><a href="{{listed_post.url}}" class="active">{{listed_post.title}} <span class="visually-hidden">(Current page)</span></a></li>
|
24
24
|
{% else %}
|
25
25
|
<li><a href="{{listed_post.url}}">{{listed_post.title}}</a></li>
|
26
26
|
{% endif %}
|
@@ -31,6 +31,6 @@
|
|
31
31
|
<ul id="navigation-controls">
|
32
32
|
<li id="site-title"><a href="/">{{ site.title | default: "Your site has no title yet. Set it in _config.yml." }}</a></li>
|
33
33
|
<li>
|
34
|
-
<button id="mobile-navigation-toggle">{{ site.miniplex.mobile_nav_menu_title | default: "Menu" }}</button>
|
34
|
+
<button id="mobile-navigation-toggle" aria-label="Open Menu" aria-expanded="false">{{ site.miniplex.mobile_nav_menu_title | default: "Menu" }}</button>
|
35
35
|
</li>
|
36
36
|
</ul>
|
data/_layouts/default.html
CHANGED
@@ -16,16 +16,17 @@
|
|
16
16
|
</head>
|
17
17
|
|
18
18
|
<body>
|
19
|
+
<a href="#content" class="visually-hidden" id="skiplink">Skip to Content</a>
|
19
20
|
<div id="layout">
|
20
21
|
<main id="content">
|
21
22
|
<section>
|
22
23
|
{{ content }}
|
23
24
|
</section>
|
24
25
|
</main>
|
25
|
-
<nav id="navigation-desktop">
|
26
|
+
<nav id="navigation-desktop" role="navigation">
|
26
27
|
{% include navigation_desktop.html %}
|
27
28
|
</nav>
|
28
|
-
<nav id="navigation-mobile" data-state="closed">
|
29
|
+
<nav id="navigation-mobile" data-state="closed" role="navigation">
|
29
30
|
{% include navigation_mobile.html %}
|
30
31
|
</nav>
|
31
32
|
</div>
|
@@ -196,7 +196,6 @@ $group_color_level_2: #dddddd
|
|
196
196
|
font-style: italic
|
197
197
|
src: url("../fonts/IBMPlexSerif-BoldItalic.woff2")
|
198
198
|
|
199
|
-
|
200
199
|
@mixin default_font
|
201
200
|
font-family: IBMPlexSans
|
202
201
|
@include responsive_property(font-size, $xs: 0.875 * $unit, $s: 1 * $unit, $m: 1.125 * $unit, $otherwise: 1.125 * $unit)
|
@@ -220,6 +219,23 @@ $group_color_level_2: #dddddd
|
|
220
219
|
font-style: italic
|
221
220
|
color: $accent_color_1
|
222
221
|
|
222
|
+
// Accessibility
|
223
|
+
.visually-hidden
|
224
|
+
position: absolute
|
225
|
+
left: -10000px
|
226
|
+
top: auto
|
227
|
+
width: 1px
|
228
|
+
height: 1px
|
229
|
+
overflow: hidden
|
230
|
+
|
231
|
+
&:focus
|
232
|
+
color: $primary_foreground_color
|
233
|
+
display: inline-block
|
234
|
+
height: auto
|
235
|
+
width: auto
|
236
|
+
position: static
|
237
|
+
margin: auto
|
238
|
+
|
223
239
|
body
|
224
240
|
@include default_font
|
225
241
|
background: $outer_background_color
|
@@ -317,12 +333,14 @@ body
|
|
317
333
|
h5
|
318
334
|
@include heading_font
|
319
335
|
color: $heading_foreground_color
|
320
|
-
|
321
|
-
|
322
336
|
@include responsive_property(font-size, $xs: 0.75 * $unit, $s: 0.875 * $unit, $m: 1 * $unit, $otherwise: 1 * $unit)
|
323
337
|
@include responsive_property(margin-top, $xs: 0.75 * $unit, $s: 0.875 * $unit, $m: 1 * $unit, $otherwise: 1 * $unit)
|
324
338
|
@include responsive_property(margin-bottom, $xs: 0.75 * $unit, $s: 0.875 * $unit, $m: 1 * $unit, $otherwise: 1 * $unit)
|
325
|
-
|
339
|
+
|
340
|
+
hr
|
341
|
+
border: 0
|
342
|
+
border-top: 1px solid $accent_color_1
|
343
|
+
border-bottom: 1px solid $accent_color_1
|
326
344
|
|
327
345
|
// Ordered lists
|
328
346
|
ol
|
@@ -624,7 +642,11 @@ body
|
|
624
642
|
width: 100vw
|
625
643
|
height: 100vh
|
626
644
|
|
645
|
+
#transparent-nav-close-area
|
646
|
+
display: block
|
647
|
+
|
627
648
|
#navigation-items
|
649
|
+
display: block
|
628
650
|
box-shadow: 0 math.div($unit, 2) math.div($unit, 1) rgba($heading_foreground_color, 0.4)
|
629
651
|
|
630
652
|
#navigation-controls
|
data/assets/js/main.coffee
CHANGED
@@ -14,6 +14,7 @@ document.addEventListener "DOMContentLoaded", (DOMLoadedEvent) ->
|
|
14
14
|
|
15
15
|
# Mobile navigation
|
16
16
|
mobileNavigation = document.querySelector "nav#navigation-mobile"
|
17
|
+
mobileNavigationItems = document.querySelector "nav#navigation-mobilenav#navigation-mobile ul#navigation-items"
|
17
18
|
navigationToggleButton = document.querySelector "button#mobile-navigation-toggle"
|
18
19
|
transparentNavCloseArea = document.querySelector "div#transparent-nav-close-area"
|
19
20
|
body = document.querySelector "body"
|
@@ -22,9 +23,13 @@ document.addEventListener "DOMContentLoaded", (DOMLoadedEvent) ->
|
|
22
23
|
switch mobileNavigation.dataset.state
|
23
24
|
when "closed"
|
24
25
|
mobileNavigation.dataset.state = "open"
|
26
|
+
navigationToggleButton.setAttribute "aria-expanded", "true"
|
27
|
+
mobileNavigationItems.setAttribute "aria-hidden", "false"
|
25
28
|
body.style.overflow = "hidden"
|
26
29
|
when "open"
|
30
|
+
navigationToggleButton.setAttribute "aria-expanded", "false"
|
27
31
|
mobileNavigation.dataset.state = "closed"
|
32
|
+
mobileNavigationItems.setAttribute "aria-hidden", "true"
|
28
33
|
body.style.overflow = "initial"
|
29
34
|
|
30
35
|
navigationToggleButton.addEventListener "click", toggleNavigation
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-theme-miniplex
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Timo Würsch
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-12-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|