mirror of
https://github.com/thelounge/thelounge
synced 2024-11-14 16:27:22 +00:00
client: Indicate active context menu item for screen readers
This commit is contained in:
parent
3d33ef8083
commit
4ba16364cc
1 changed files with 2 additions and 0 deletions
|
@ -19,12 +19,14 @@
|
|||
left: style.left + 'px',
|
||||
}"
|
||||
tabindex="-1"
|
||||
:aria-activedescendant="activeItem > -1 ? `context-menu-item-${activeItem}` : undefined"
|
||||
@mouseleave="activeItem = -1"
|
||||
@keydown.enter.prevent="clickActiveItem"
|
||||
>
|
||||
<!-- TODO: type -->
|
||||
<template v-for="(item, id) of (items as any)" :key="item.name">
|
||||
<li
|
||||
:id="`context-menu-item-${id}`"
|
||||
:class="[
|
||||
'context-menu-' + item.type,
|
||||
item.class ? 'context-menu-' + item.class : null,
|
||||
|
|
Loading…
Reference in a new issue