Skip to content

Commit f85fc03

Browse files
committed
fix(seo): improve SEO and accessibility
- Resolve crawlable links in templates - Add aria-labels to navbar icons and dropdowns - Update Twitter branding to X in footer - Fix Lighthouse SEO audit issues Signed-off-by: Daniel Mungai <chegedan699@gmail.com>
1 parent bd7a7ac commit f85fc03

File tree

3 files changed

+26
-17
lines changed

3 files changed

+26
-17
lines changed

hugo.toml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -190,57 +190,57 @@ enable = false
190190
url = "https://layer5.io/subscribe"
191191
icon = "icons/envelope.svg"
192192
desc = "Discussion and help from your fellow users"
193-
alt = "Envelope Icon"
193+
alt = "Subscribe to the Layer5 newsletter"
194194
[[params.links.footer.icons]]
195-
name = "Twitter"
195+
name = "X"
196196
url = "https://twitter.com/layer5"
197197
icon = "icons/twitter.svg"
198-
desc = "Follow us on Twitter to get the latest news!"
198+
desc = "Follow us on X to get the latest news!"
199199
class= "social-icon"
200-
alt = "Twitter Icon"
200+
alt = "Follow Layer5 on X"
201201
[[params.links.footer.icons]]
202202
name = "Discussion Forum"
203203
url = "https://discuss.layer5.io"
204204
icon = "icons/discuss.svg"
205205
desc = "Practical questions and curated answers"
206-
alt = "Discussion Forum Icon"
206+
alt = "Join the Layer5 discussion forum"
207207
[[params.links.footer.icons]]
208208
name = "GitHub"
209209
url = "https://github.com/layer5io"
210210
icon = "icons/github.svg"
211211
desc = "Development takes place here"
212212
class= "social-icon"
213-
alt = "GitHub Icon"
213+
alt = "Visit Layer5 on GitHub"
214214
[[params.links.footer.icons]]
215215
name = "Slack"
216216
url = "https://slack.layer5.io"
217217
icon = "icons/slack.svg"
218218
desc = "Chat with other project developers"
219-
alt = "Slack Icon"
219+
alt = "Join the Layer5 Slack community"
220220
[[params.links.footer.icons]]
221221
name = "LinkedIn"
222222
url = "https://www.linkedin.com/company/layer5"
223223
icon = "icons/linkedin.svg"
224224
desc = "Discuss development issues around the project"
225-
alt = "LinkedIn Icon"
225+
alt = "Follow Layer5 on LinkedIn"
226226
[[params.links.footer.icons]]
227227
name = "YouTube"
228228
url = "https://www.youtube.com/channel/UCFL1af7_wdnhHXL1InzaMvA?sub_confirmation=1"
229229
icon = "icons/youtube.svg"
230230
desc = "Discuss development issues around the project"
231-
alt = "YouTube Icon"
231+
alt = "Watch Layer5 on YouTube"
232232
[[params.links.footer.icons]]
233233
name = "Bluesky"
234234
url = "https://bsky.app/profile/layer5.bsky.social"
235235
icon = "icons/bluesky.svg"
236236
desc = "Follow us on Bluesky for updates"
237-
alt = "Bluesky Icon"
237+
alt = "Follow Layer5 on Bluesky"
238238
[[params.links.footer.icons]]
239239
name = "Docker"
240240
url = "https://hub.docker.com/u/layer5/"
241241
icon = "icons/docker.svg"
242242
desc = "Discuss development issues around the project"
243-
alt = "Docker Icon"
243+
alt = "Explore Layer5 images on Docker Hub"
244244

245245
[[params.links.footer.resources.items]]
246246
name = "Learning Paths"

layouts/partials/footer.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
<!----------------->
55
<div class="row footer-top">
66
<div class="col-lg-6">
7-
<a href="/">
7+
<a href="/" aria-label="Home">
88
{{ $svg := resources.Get "icons/logo.svg" }}
99
<img class="footer-logo" src="{{ $svg.Permalink }}" alt="Footer Logo Layer5" data-modal="false">
1010
</a>
1111
</div>
1212
<div class="col-lg-6 footer-info footer-icons">
1313
{{ range .Site.Params.links.footer.icons }}
14-
<a href="{{ .url }}" class="{{ .class }}" target="_blank" rel="noreferrer">
14+
<a href="{{ .url }}" class="{{ .class }}" target="_blank" rel="noreferrer" aria-label="{{ .alt }}">
1515
{{ $svg1 := resources.Get .icon }}
1616
<img height="30px" src="{{ $svg1.Permalink }}" alt="{{ .alt }}" data-modal="false">
1717
</a>

layouts/partials/navbar.html

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
class="td-navbar navbar-dark js-navbar-scroll td-navbar-cover navbar-bg-onscroll--fade"
44
>
55
<div class="container-fluid flex-column flex-md-row">
6-
<a class="navbar-brand" href="/">
6+
<a class="navbar-brand" href="/" aria-label="Home">
77
<span class="navbar-brand__logo navbar-logo">
88
{{ $svg := resources.Get "icons/logo.svg" }}
99
<img class="footer-logo" src="/images/logo.svg" alt="logo" data-modal="false" />
@@ -41,6 +41,7 @@
4141
class="dropdown-item dropdown-item--row"
4242
href="https://cloud.layer5.io/academy"
4343
target="_blank"
44+
aria-label="Academy"
4445
>
4546
<div class="logo-container">
4647
<img
@@ -54,6 +55,7 @@
5455
<a
5556
class="dropdown-item dropdown-item--row"
5657
href="/videos"
58+
aria-label="Videos"
5759
>
5860
<div class="logo-container">
5961
<img
@@ -89,13 +91,14 @@
8991
data-toggle="dropdown"
9092
style="padding-top:6px"
9193
>
92-
<img width="28px" src="/images/grid-icon.svg" class="grid-icon" data-modal="false" />
94+
<img width="28px" src="/images/grid-icon.svg" alt="Products" class="grid-icon" data-modal="false" />
9395

9496
</div>
9597
<div class="dropdown-menu" aria-labelledby="productsDropdown" style="margin-left:-4.5rem;visibility:hidden;">
9698
<a
9799
class="dropdown-item"
98100
href="https://docs.meshery.io/"
101+
aria-label="Meshery Docs"
99102
target="_blank"
100103
>
101104
<div class="logo-container">
@@ -110,6 +113,7 @@
110113
<a
111114
class="dropdown-item"
112115
href="https://layer5.io/cloud-native-management/kanvas"
116+
aria-label="Kanvas"
113117
target="_blank"
114118
>
115119
<div class="logo-container">
@@ -126,6 +130,7 @@
126130
<a
127131
class="dropdown-item"
128132
href="https://layer5.io/cloud-native-management/catalog"
133+
aria-label="Catalog"
129134
target="_blank"
130135
>
131136
<div class="logo-container">
@@ -141,6 +146,7 @@
141146
<a
142147
class="dropdown-item"
143148
href="https://smp-spec.io/"
149+
aria-label="SMP Spec"
144150
target="_blank"
145151
>
146152
<div class="logo-container">
@@ -156,6 +162,7 @@
156162
<a
157163
class="dropdown-item"
158164
href="https://getnighthawk.dev/"
165+
aria-label="Nighthawk"
159166
target="_blank"
160167
>
161168
<div class="logo-container">
@@ -173,6 +180,7 @@
173180
class="dropdown-item"
174181
href="https://cloud.layer5.io/academy"
175182
target="_blank"
183+
aria-label="Layer5 Academy"
176184
>
177185
<div class="logo-container">
178186
<img
@@ -189,7 +197,7 @@
189197
<a class="nav-link" href="https://cloud.layer5.io/login" target="_blank">Sign In</a>
190198
</li>
191199
<li class="nav-item dropdown" data-bs-theme="dark" id="userlist" style="display: none;">
192-
<a href="" id="user-profile-url">
200+
<a href="https://cloud.layer5.io" id="user-profile-url" aria-label="User Profile">
193201
<div
194202
class="nav-link avatar-container"
195203
id="avatarDropdown"
@@ -257,7 +265,8 @@
257265
cur = document.querySelector("#kanvas");
258266
if (cur) {
259267
cur.classList.add("current");
260-
cur.href = "javascript: void(0)";
268+
cur.style.pointerEvents = "none";
269+
cur.style.cursor = "default";
261270
}
262271

263272
let isUserAuthenticated = false;

0 commit comments

Comments
 (0)