Skip to content

Commit

Permalink
Fixed #13702 - Menu | Throws error on tab
Browse files Browse the repository at this point in the history
  • Loading branch information
cetincakiroglu committed Sep 19, 2023
1 parent 452fdbb commit 458014d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/app/components/menu/menu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,8 @@ export class Menu implements OnDestroy {
}
}

menuitemId(id: string, index?: string, childIndex?: string) {
menuitemId(item: MenuItem, id: string, index?: string, childIndex?: string) {
// let itemId = item.id ?? id;
return `${id}_${index}${typeof childIndex !== 'undefined' ? '_' + childIndex : ''}`;
}

Expand Down Expand Up @@ -501,8 +502,8 @@ export class Menu implements OnDestroy {
onListBlur(event: FocusEvent | MouseEvent) {
this.focused = false;
this.changeFocusedOptionIndex(-1);
this.selectedOptionIndex.set(null);
this.focusedOptionIndex.set(null);
this.selectedOptionIndex.set(-1);
this.focusedOptionIndex.set(-1);
this.onBlur.emit(event);
}

Expand Down

1 comment on commit 458014d

@vercel
Copy link

@vercel vercel bot commented on 458014d Sep 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.