Skip to content

Commit 56daec7

Browse files
committed
fix($core): vuejs#2627 Dup ID violates HTML5-4
1 parent 235a4aa commit 56daec7

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

packages/@vuepress/core/lib/client/components/OutboundLink.vue

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
11
<template>
2-
<span
3-
:title="openInNewWindowTitle"
4-
class="sr-only"
5-
>
2+
<span>
63
<svg
74
class="icon outbound"
85
xmlns="http://www.w3.org/2000/svg"
96
aria-hidden="true"
10-
role="img"
117
focusable="false"
128
x="0px"
139
y="0px"
@@ -24,6 +20,7 @@
2420
points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"
2521
/>
2622
</svg>
23+
<span class="sr-only">{{ openInNewWindowTitle }}</span>
2724
</span>
2825
</template>
2926

packages/@vuepress/theme-default/styles/index.styl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,16 @@ th, td
189189
.sidebar
190190
top 0
191191

192+
.sr-only
193+
position absolute
194+
width 1px
195+
height 1px
196+
padding 0
197+
margin -1px
198+
overflow hidden
199+
clip rect(0, 0, 0, 0)
200+
white-space nowrap
201+
border-width 0
192202

193203
@media (min-width: ($MQMobile + 1px))
194204
.theme-container.no-sidebar

0 commit comments

Comments
 (0)