Refactor #5592 - For Menubar, PanelMenu, Steps, TabMenu, TieredMenu

This commit is contained in:
tugcekucukoglu 2024-04-30 16:03:20 +03:00
parent aec93e5eea
commit 37eb456f9b
20 changed files with 181 additions and 175 deletions

View file

@ -365,7 +365,7 @@ export default {
onEnterKey(event) {
if (this.focusedItemInfo.index !== -1) {
const element = DomHandler.findSingle(this.menubar, `li[id="${`${this.focusedItemId}`}"]`);
const anchorElement = element && DomHandler.findSingle(element, '[data-pc-section="action"]');
const anchorElement = element && DomHandler.findSingle(element, '[data-pc-section="itemlink"]');
anchorElement ? anchorElement.click() : element && element.click();