We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 938d082 commit 9734526Copy full SHA for 9734526
src/skip-to.vue
@@ -1,5 +1,5 @@
1
<template>
2
- <a class="vue-skip-to" :href="to" :tabindex="tabindex">
+ <a class="vue-skip-to" :href="to">
3
<slot>{{ text }}</slot>
4
</a>
5
</template>
@@ -16,10 +16,6 @@ export default {
16
to: {
17
type: String,
18
default: '#main'
19
- },
20
- tabindex: {
21
- type: [Number, null],
22
- default: null
23
}
24
},
25
@@ -40,7 +36,7 @@ export default {
40
36
41
37
focusElement (id) {
42
38
if (!id) return
43
- let element = window.document.getElementById(id)
39
+ const element = window.document.getElementById(id)
44
if (element) {
45
if (!/^(a|select|input|button|textarea)/i.test(element.tagName.toLowerCase())) {
46
element.setAttribute('tabindex', -1)
0 commit comments