mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-10 09:22:34 +00:00
Fixed #5288 - Menu components: track focus with also mousemove
This commit is contained in:
parent
266d5019af
commit
e67efa2d8c
10 changed files with 91 additions and 29 deletions
|
@ -27,6 +27,7 @@
|
|||
@keydown="onKeyDown"
|
||||
@item-click="onItemClick"
|
||||
@item-mouseenter="onItemMouseEnter"
|
||||
@item-mousemove="onItemMouseMove"
|
||||
/>
|
||||
</div>
|
||||
</transition>
|
||||
|
@ -247,6 +248,11 @@ export default {
|
|||
onItemMouseEnter(event) {
|
||||
this.onItemChange(event);
|
||||
},
|
||||
onItemMouseMove(event) {
|
||||
if (this.focused) {
|
||||
this.changeFocusedItemIndex(event, event.processedItem.index);
|
||||
}
|
||||
},
|
||||
onArrowDownKey(event) {
|
||||
const itemIndex = this.focusedItemInfo.index !== -1 ? this.findNextItemIndex(this.focusedItemInfo.index) : this.findFirstFocusedItemIndex();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue