Skip to content

Commit 7aa6cf7

Browse files
committed
Add menu label text to sidebar toggle button
1 parent 85b219c commit 7aa6cf7

File tree

8 files changed

+25
-4
lines changed

8 files changed

+25
-4
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ t:
9696
skip_primary_nav: "Skip to primary navigation"
9797
skip_content: "Skip to content"
9898
skip_footer: "Skip to footer"
99+
menu: "Menu"
99100
home: "Home"
100101
newer: "Newer"
101102
older: "Older"

_data/theme.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ t:
77
skip_primary_nav: "Skip to primary navigation"
88
skip_content: "Skip to content"
99
skip_footer: "Skip to footer"
10+
menu: "Menu"
1011
home: "Home"
1112
newer: "Newer"
1213
older: "Older"

_layouts/default.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
<div class="sidebar-toggle-wrapper">
1616
<a class="toggle navicon-button larr" href="#sidebar">
17-
<span class="screen-reader-text">Menu</span>
17+
<span class="sidebar-toggle-label">{{ site.data.theme.t.menu | default: 'Menu' }}</span>
1818
<div class="navicon"></div>
1919
</a>
2020
</div>

_sass/basically-basic/_global.scss

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,15 @@
2222
a {
2323
display: flex;
2424
align-items: center;
25+
min-height: $site-image-height;
2526
color: $text-color;
2627
text-decoration: none;
2728
}
2829
}
2930

3031
.site-image {
31-
width: 50px;
32-
height: 50px;
32+
width: $site-image-width;
33+
height: $site-image-height;
3334
margin-right: 0.5rem;
3435
border-radius: 50%;
3536
}

_sass/basically-basic/_navicons.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
border-radius: $navicon-width;
6363
background: $navicon-content-bg;
6464
content: '';
65-
z-index: -1;
65+
// z-index: -1;
6666
}
6767

6868
&::before { top: (2 * $navicon-height); }

_sass/basically-basic/_sidebar.scss

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,4 +168,17 @@
168168
right: 0;
169169
cursor: pointer;
170170
z-index: 10000;
171+
172+
.toggle {
173+
display: flex;
174+
align-items: center;
175+
color: inherit;
176+
text-decoration: none;
177+
}
178+
}
179+
180+
.sidebar-toggle-label {
181+
order: 2;
182+
margin-left: 0.5rem;
183+
font-weight: bold;
171184
}

_sass/basically-basic/_variables.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,5 +76,9 @@ $navicon-nav-bg-close: transparent !default;
7676
$navicon-nav-bg-open: transparent !default;
7777
$navicon-content-bg: $text-color !default;
7878

79+
/* Site image */
80+
$site-image-width: 50px !default;
81+
$site-image-height: 50px !default;
82+
7983
/* Susy grid settings */
8084
$susy: (columns: 16, gutters: 0, math: fluid, output: float) !default;

example/_data/theme.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ t:
77
skip_primary_nav: "Skip to primary navigation"
88
skip_content: "Skip to content"
99
skip_footer: "Skip to footer"
10+
menu: "Menu"
1011
home: "Home"
1112
newer: "Newer"
1213
older: "Older"

0 commit comments

Comments
 (0)