MCPcopy Create free account
hub / github.com/angular/components / open

Method open

src/aria/private/menu/menu.ts:727–735  ·  view source on GitHub ↗

Opens the menu.

(opts?: {first?: boolean; last?: boolean})

Source from the content-addressed store, hash-verified

725
726 /** Opens the menu. */
727 open(opts?: {first?: boolean; last?: boolean}) {
728 this.expanded.set(true);
729
730 if (opts?.first) {
731 this.pendingFocus.set('first');
732 } else if (opts?.last) {
733 this.pendingFocus.set('last');
734 }
735 }
736
737 /** Closes the menu. */
738 close(opts: {refocus?: boolean} = {}) {

Callers 2

MenuTriggerPatternClass · 0.95
onClickMethod · 0.95

Calls 1

setMethod · 0.80

Tested by

no test coverage detected