Skip to content

Commit 678525e

Browse files
committed
refactor: using aria-label intead of sr-only
1 parent 90a4bd2 commit 678525e

File tree

3 files changed

+2
-5
lines changed

3 files changed

+2
-5
lines changed

src/.vuepress/theme/components/BackToTop.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
:href="anchor"
44
class="fixed bottom-0 right-0 z-10 p-6 mb-10 mr-16"
55
:class="{ 'block': show, 'hidden': !show }"
6+
:aria-label="$themeLocaleConfig.backToTopText"
67
>
7-
<span class="sr-only">{{ $themeLocaleConfig.backToTopText }}</span>
88
<vp-icon
99
name="back-to-top"
1010
size="24"

src/.vuepress/theme/components/TheFooter.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
class="block p-5 border border-solid rounded-full c-border-color bg-main hover:border-accent-primary"
3030
target="_blank"
3131
rel="me noopener"
32+
:aria-label="`${social.name} Vue A11y (${$themeLocaleConfig.externalLinkText})`"
3233
>
33-
<span class="sr-only">{{ social.name }} Vue A11y {{ ($themeLocaleConfig.externalLinkText) }}</span>
3434
<vp-icon
3535
:name="social.icon"
3636
size="1.5rem"

src/.vuepress/theme/components/WebMentions.vue

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@
3636
:aria-label="`Ir para o site do ${like.author.name}`"
3737
rel="nofollow"
3838
>
39-
<span class="sr-only">{{ like.author.name }}</span>
4039
<img
4140
class="rounded-full"
4241
:src="like.author.photo"
@@ -80,7 +79,6 @@
8079
:aria-label="`Ir para o site do ${repost.author.name}`"
8180
rel="nofollow"
8281
>
83-
<span class="sr-only">{{ repost.author.name }}</span>
8482
<img
8583
class="rounded-full"
8684
:src="repost.author.photo"
@@ -135,7 +133,6 @@
135133
rel="nofollow"
136134
itemprop="url"
137135
>
138-
<span class="sr-only">{{ mention.author.name }}</span>
139136
<img
140137
id="author-comment-image"
141138
class="rounded-full"

0 commit comments

Comments
 (0)