+2
-2
lines changedFilter options
+2
-2
lines changed Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
1
1
import looseEqual from '../../utils/loose-equal'
2
-
import { addClass, removeAttr, removeClass, setAttr } from '../../utils/dom'
2
+
import { addClass, hasAttr, removeAttr, removeClass, setAttr } from '../../utils/dom'
3
3
import { isBrowser } from '../../utils/env'
4
4
import { bindTargets, getTargets, unbindTargets } from '../../utils/target'
5
5
@@ -91,7 +91,7 @@ export const VBToggle = {
91
91
setAttr(el, 'aria-controls', el[BV_TOGGLE_CONTROLS])
92
92
setAttr(el, 'aria-expanded', 'false')
93
93
// If element is not a button, we add `role="button"` for accessibility
94
-
if (el.tagName !== 'BUTTON') {
94
+
if (el.tagName !== 'BUTTON' && !hasAttr(el, 'role')) {
95
95
setAttr(el, 'role', 'button')
96
96
}
97
97
You can’t perform that action at this time.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4