Skip to content

Commit

Permalink
docs: add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
kyubisation authored Mar 21, 2024
1 parent e8a4cd0 commit 2352e73
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/components/menu/menu/menu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,9 @@ export class SbbMenuElement extends SbbNamedSlotListMixin<
const signal = this._abort.signal;
this.addEventListener('click', (e) => this._onClick(e), { signal });
this.addEventListener('keydown', (e) => this._handleKeyDown(e), { signal });
// Due to the fact that menu can both be a list and just a container, we need to check its
// state before the SbbNamedSlotListMixin handles the slotchange event, in order to avoid
// it interpreting the non list case as a list.
this.shadowRoot?.addEventListener('slotchange', (e) => this._checkListCase(e), {
signal,
capture: true,
Expand Down

0 comments on commit 2352e73

Please sign in to comment.