mirror of
https://github.com/element-plus/element-plus.git
synced 2026-03-13 07:51:17 +08:00
fix: remove popper tabIndex (#486)
This commit is contained in:
@@ -160,13 +160,6 @@ describe('Popper.vue', () => {
|
||||
)
|
||||
})
|
||||
|
||||
test('should add tab index to referrer', async () => {
|
||||
const wrapper = _mount({
|
||||
appendToBody: false,
|
||||
})
|
||||
expect(wrapper.find(`.el-popper`).attributes('tabindex')).toBe('0')
|
||||
})
|
||||
|
||||
test('should initialize a new popper when component mounted', async () => {
|
||||
_mount({
|
||||
appendToBody: false,
|
||||
|
||||
@@ -65,7 +65,6 @@ export default defineComponent({
|
||||
popperId,
|
||||
pure,
|
||||
showArrow,
|
||||
tabIndex,
|
||||
transition,
|
||||
visibility,
|
||||
} = this
|
||||
@@ -82,7 +81,6 @@ export default defineComponent({
|
||||
onMouseLeave: onPopperMouseLeave,
|
||||
onAfterEnter,
|
||||
onAfterLeave,
|
||||
tabindex: tabIndex,
|
||||
visibility,
|
||||
},
|
||||
[
|
||||
|
||||
@@ -13,7 +13,6 @@ interface IRenderPopperProps {
|
||||
popperId: string
|
||||
popperRef?: Ref<HTMLElement>
|
||||
pure: boolean
|
||||
tabindex: number
|
||||
visibility: boolean
|
||||
onMouseEnter: () => void
|
||||
onMouseLeave: () => void
|
||||
@@ -33,7 +32,6 @@ export default function renderPopper(
|
||||
popperRef,
|
||||
pure,
|
||||
popperId,
|
||||
tabindex,
|
||||
visibility,
|
||||
onMouseEnter,
|
||||
onMouseLeave,
|
||||
@@ -73,7 +71,6 @@ export default function renderPopper(
|
||||
id: popperId,
|
||||
ref: popperRef ?? 'popperRef',
|
||||
role: 'tooltip',
|
||||
tabindex,
|
||||
onMouseEnter,
|
||||
onMouseLeave,
|
||||
onClick: stop,
|
||||
@@ -90,7 +87,6 @@ export default function renderPopper(
|
||||
'onMouseup',
|
||||
'onClick',
|
||||
'id',
|
||||
'tabindex',
|
||||
],
|
||||
),
|
||||
[[vShow, visibility]],
|
||||
|
||||
@@ -31,7 +31,6 @@ export type IPopperOptions = {
|
||||
showAfter: number
|
||||
showArrow: boolean
|
||||
strategy: PositioningStrategy
|
||||
tabIndex: string
|
||||
trigger: Trigger
|
||||
visible: boolean
|
||||
}
|
||||
@@ -130,10 +129,6 @@ export default {
|
||||
type: [String, Array] as PropType<Trigger>,
|
||||
default: DEFAULT_TRIGGER,
|
||||
},
|
||||
tabIndex: {
|
||||
type: String,
|
||||
default: '0',
|
||||
},
|
||||
visible: {
|
||||
type: Boolean,
|
||||
default: undefined,
|
||||
|
||||
Reference in New Issue
Block a user