Skip to content

Commit 9faf262

Browse files
committed
Improved tab highlighting experience.
1 parent c3d39f3 commit 9faf262

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

_config.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ defaults:
113113
scope:
114114
path: tags
115115
values:
116+
tab_active: Tags
116117
location: Tag
117118
breadcrumb:
118119
-
@@ -125,6 +126,7 @@ defaults:
125126
scope:
126127
path: categories
127128
values:
129+
tab_active: Categories
128130
location: Category
129131
breadcrumb:
130132
-

_includes/sidebar.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,9 @@
4141
{% endif %}
4242

4343
<li class="nav-item d-flex justify-content-center
44-
{% if item.url == page_urls.last or
45-
item.name == "Home" and page.layout == "home" %}active{% endif %}">
44+
{% if item.url == page_urls.last
45+
or item.name == page.tab_active
46+
or item.name == "Home" and page.layout == "home" %}active{% endif %}">
4647
<a href="{{ ref }}" class="nav-link d-flex justify-content-center align-items-center w-100">
4748
<i class="fa-fw {{ item.icon }} ml-3 mr-3 unloaded"></i>
4849
<span>{{ item.name | upcase }}</span>

0 commit comments

Comments
 (0)