@angular/cdk 21.0.0-next.0 → 21.0.0-next.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/a11y/index.d.ts +3 -34
  2. package/a11y-module.d.d.ts +1 -7
  3. package/fesm2022/a11y-module.mjs +24 -32
  4. package/fesm2022/a11y-module.mjs.map +1 -1
  5. package/fesm2022/a11y.mjs +13 -31
  6. package/fesm2022/a11y.mjs.map +1 -1
  7. package/fesm2022/accordion.mjs +10 -10
  8. package/fesm2022/accordion.mjs.map +1 -1
  9. package/fesm2022/activedescendant-key-manager.mjs.map +1 -1
  10. package/fesm2022/array.mjs.map +1 -1
  11. package/fesm2022/bidi.mjs +7 -7
  12. package/fesm2022/bidi.mjs.map +1 -1
  13. package/fesm2022/breakpoints-observer.mjs +6 -6
  14. package/fesm2022/breakpoints-observer.mjs.map +1 -1
  15. package/fesm2022/cdk.mjs +1 -1
  16. package/fesm2022/cdk.mjs.map +1 -1
  17. package/fesm2022/clipboard.mjs +10 -10
  18. package/fesm2022/clipboard.mjs.map +1 -1
  19. package/fesm2022/coercion/private.mjs.map +1 -1
  20. package/fesm2022/coercion.mjs.map +1 -1
  21. package/fesm2022/css-pixel-value.mjs.map +1 -1
  22. package/fesm2022/data-source.mjs.map +1 -1
  23. package/fesm2022/dialog.mjs +10 -10
  24. package/fesm2022/dialog.mjs.map +1 -1
  25. package/fesm2022/directionality.mjs +4 -12
  26. package/fesm2022/directionality.mjs.map +1 -1
  27. package/fesm2022/dispose-view-repeater-strategy.mjs.map +1 -1
  28. package/fesm2022/drag-drop.mjs +31 -31
  29. package/fesm2022/drag-drop.mjs.map +1 -1
  30. package/fesm2022/element.mjs.map +1 -1
  31. package/fesm2022/fake-event-detection.mjs.map +1 -1
  32. package/fesm2022/focus-key-manager.mjs.map +1 -1
  33. package/fesm2022/focus-monitor.mjs +9 -9
  34. package/fesm2022/focus-monitor.mjs.map +1 -1
  35. package/fesm2022/id-generator.mjs +3 -3
  36. package/fesm2022/id-generator.mjs.map +1 -1
  37. package/fesm2022/keycodes.mjs.map +1 -1
  38. package/fesm2022/keycodes2.mjs.map +1 -1
  39. package/fesm2022/layout.mjs +4 -4
  40. package/fesm2022/layout.mjs.map +1 -1
  41. package/fesm2022/list-key-manager.mjs.map +1 -1
  42. package/fesm2022/listbox.mjs +10 -10
  43. package/fesm2022/listbox.mjs.map +1 -1
  44. package/fesm2022/menu.mjs +49 -49
  45. package/fesm2022/menu.mjs.map +1 -1
  46. package/fesm2022/observers/private.mjs +3 -3
  47. package/fesm2022/observers/private.mjs.map +1 -1
  48. package/fesm2022/observers.mjs +13 -13
  49. package/fesm2022/observers.mjs.map +1 -1
  50. package/fesm2022/overlay-module.mjs +35 -53
  51. package/fesm2022/overlay-module.mjs.map +1 -1
  52. package/fesm2022/overlay.mjs +3 -3
  53. package/fesm2022/overlay.mjs.map +1 -1
  54. package/fesm2022/passive-listeners.mjs.map +1 -1
  55. package/fesm2022/platform.mjs +4 -4
  56. package/fesm2022/platform.mjs.map +1 -1
  57. package/fesm2022/platform2.mjs +3 -3
  58. package/fesm2022/platform2.mjs.map +1 -1
  59. package/fesm2022/portal.mjs +16 -16
  60. package/fesm2022/portal.mjs.map +1 -1
  61. package/fesm2022/private.mjs +3 -3
  62. package/fesm2022/private.mjs.map +1 -1
  63. package/fesm2022/recycle-view-repeater-strategy.mjs.map +1 -1
  64. package/fesm2022/scrolling.mjs +35 -35
  65. package/fesm2022/scrolling.mjs.map +1 -1
  66. package/fesm2022/scrolling2.mjs.map +1 -1
  67. package/fesm2022/selection-model.mjs.map +1 -1
  68. package/fesm2022/shadow-dom.mjs.map +1 -1
  69. package/fesm2022/stepper.mjs +22 -22
  70. package/fesm2022/stepper.mjs.map +1 -1
  71. package/fesm2022/style-loader.mjs +3 -3
  72. package/fesm2022/style-loader.mjs.map +1 -1
  73. package/fesm2022/table.mjs +73 -73
  74. package/fesm2022/table.mjs.map +1 -1
  75. package/fesm2022/test-environment.mjs.map +1 -1
  76. package/fesm2022/testing/selenium-webdriver.mjs.map +1 -1
  77. package/fesm2022/testing/testbed.mjs.map +1 -1
  78. package/fesm2022/testing.mjs.map +1 -1
  79. package/fesm2022/text-field.mjs +16 -16
  80. package/fesm2022/text-field.mjs.map +1 -1
  81. package/fesm2022/tree-key-manager.mjs +2 -19
  82. package/fesm2022/tree-key-manager.mjs.map +1 -1
  83. package/fesm2022/tree.mjs +30 -25
  84. package/fesm2022/tree.mjs.map +1 -1
  85. package/fesm2022/typeahead.mjs.map +1 -1
  86. package/fesm2022/unique-selection-dispatcher.mjs +3 -3
  87. package/fesm2022/unique-selection-dispatcher.mjs.map +1 -1
  88. package/package.json +1 -1
  89. package/schematics/ng-add/index.js +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"menu.mjs","sources":["../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-group.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-interface.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-stack.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-trigger-base.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-errors.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-aim.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/event-detection.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-trigger.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-item.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/pointer-focus-tracker.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-base.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-bar.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-item-selectable.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-item-radio.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-item-checkbox.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/context-menu-trigger.ts","../../../../../k8-fastbuild-ST-c646aa77115d/bin/src/cdk/menu/menu-module.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive} from '@angular/core';\nimport {UniqueSelectionDispatcher} from '../collections';\n\n/**\n * A grouping container for `CdkMenuItemRadio` instances, similar to a `role=\"radiogroup\"` element.\n */\n@Directive({\n selector: '[cdkMenuGroup]',\n exportAs: 'cdkMenuGroup',\n host: {\n 'role': 'group',\n 'class': 'cdk-menu-group',\n },\n providers: [{provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher}],\n})\nexport class CdkMenuGroup {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {InjectionToken} from '@angular/core';\nimport {MenuStackItem} from './menu-stack';\nimport {FocusOrigin} from '../a11y';\n\n/** Injection token used to return classes implementing the Menu interface */\nexport const CDK_MENU = new InjectionToken<Menu>('cdk-menu');\n\n/** Interface which specifies Menu operations and used to break circular dependency issues */\nexport interface Menu extends MenuStackItem {\n /** The id of the menu's host element. */\n id: string;\n\n /** The menu's native DOM host element. */\n nativeElement: HTMLElement;\n\n /** The direction items in the menu flow. */\n readonly orientation: 'horizontal' | 'vertical';\n\n /** Place focus on the first MenuItem in the menu. */\n focusFirstItem(focusOrigin: FocusOrigin): void;\n\n /** Place focus on the last MenuItem in the menu. */\n focusLastItem(focusOrigin: FocusOrigin): void;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {inject, Inject, Injectable, InjectionToken, Optional, SkipSelf} from '@angular/core';\nimport {_IdGenerator} from '../a11y';\nimport {Observable, Subject} from 'rxjs';\nimport {debounceTime, distinctUntilChanged, startWith} from 'rxjs/operators';\n\n/** The relative item in the inline menu to focus after closing all popup menus. */\nexport enum FocusNext {\n nextItem,\n previousItem,\n currentItem,\n}\n\n/** A single item (menu) in the menu stack. */\nexport interface MenuStackItem {\n /** A reference to the menu stack this menu stack item belongs to. */\n menuStack?: MenuStack;\n}\n\n/** Injection token used for an implementation of MenuStack. */\nexport const MENU_STACK = new InjectionToken<MenuStack>('cdk-menu-stack');\n\n/** Provider that provides the parent menu stack, or a new menu stack if there is no parent one. */\nexport const PARENT_OR_NEW_MENU_STACK_PROVIDER = {\n provide: MENU_STACK,\n deps: [[new Optional(), new SkipSelf(), new Inject(MENU_STACK)]],\n useFactory: (parentMenuStack?: MenuStack) => parentMenuStack || new MenuStack(),\n};\n\n/** Provider that provides the parent menu stack, or a new inline menu stack if there is no parent one. */\nexport const PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER = (\n orientation: 'vertical' | 'horizontal',\n) => ({\n provide: MENU_STACK,\n deps: [[new Optional(), new SkipSelf(), new Inject(MENU_STACK)]],\n useFactory: (parentMenuStack?: MenuStack) => parentMenuStack || MenuStack.inline(orientation),\n});\n\n/** Options that can be provided to the close or closeAll methods. */\nexport interface CloseOptions {\n /** The element to focus next if the close operation causes the menu stack to become empty. */\n focusNextOnEmpty?: FocusNext;\n /** Whether to focus the parent trigger after closing the menu. */\n focusParentTrigger?: boolean;\n}\n\n/** Event dispatched when a menu is closed. */\nexport interface MenuStackCloseEvent {\n /** The menu being closed. */\n item: MenuStackItem;\n /** Whether to focus the parent trigger after closing the menu. */\n focusParentTrigger?: boolean;\n}\n\n/**\n * MenuStack allows subscribers to listen for close events (when a MenuStackItem is popped off\n * of the stack) in order to perform closing actions. Upon the MenuStack being empty it emits\n * from the `empty` observable specifying the next focus action which the listener should perform\n * as requested by the closer.\n */\n@Injectable()\nexport class MenuStack {\n /** The ID of this menu stack. */\n readonly id = inject(_IdGenerator).getId('cdk-menu-stack-');\n\n /** All MenuStackItems tracked by this MenuStack. */\n private readonly _elements: MenuStackItem[] = [];\n\n /** Emits the element which was popped off of the stack when requested by a closer. */\n private readonly _close = new Subject<MenuStackCloseEvent>();\n\n /** Emits once the MenuStack has become empty after popping off elements. */\n private readonly _empty = new Subject<FocusNext | undefined>();\n\n /** Emits whether any menu in the menu stack has focus. */\n private readonly _hasFocus = new Subject<boolean>();\n\n /** Observable which emits the MenuStackItem which has been requested to close. */\n readonly closed: Observable<MenuStackCloseEvent> = this._close;\n\n /** Observable which emits whether any menu in the menu stack has focus. */\n readonly hasFocus: Observable<boolean> = this._hasFocus.pipe(\n startWith(false),\n debounceTime(0),\n distinctUntilChanged(),\n );\n\n /**\n * Observable which emits when the MenuStack is empty after popping off the last element. It\n * emits a FocusNext event which specifies the action the closer has requested the listener\n * perform.\n */\n readonly emptied: Observable<FocusNext | undefined> = this._empty;\n\n /**\n * Whether the inline menu associated with this menu stack is vertical or horizontal.\n * `null` indicates there is no inline menu associated with this menu stack.\n */\n private _inlineMenuOrientation: 'vertical' | 'horizontal' | null = null;\n\n /** Creates a menu stack that originates from an inline menu. */\n static inline(orientation: 'vertical' | 'horizontal') {\n const stack = new MenuStack();\n stack._inlineMenuOrientation = orientation;\n return stack;\n }\n\n /**\n * Adds an item to the menu stack.\n * @param menu the MenuStackItem to put on the stack.\n */\n push(menu: MenuStackItem) {\n this._elements.push(menu);\n }\n\n /**\n * Pop items off of the stack up to and including `lastItem` and emit each on the close\n * observable. If the stack is empty or `lastItem` is not on the stack it does nothing.\n * @param lastItem the last item to pop off the stack.\n * @param options Options that configure behavior on close.\n */\n close(lastItem: MenuStackItem, options?: CloseOptions) {\n const {focusNextOnEmpty, focusParentTrigger} = {...options};\n if (this._elements.indexOf(lastItem) >= 0) {\n let poppedElement;\n do {\n poppedElement = this._elements.pop()!;\n this._close.next({item: poppedElement, focusParentTrigger});\n } while (poppedElement !== lastItem);\n\n if (this.isEmpty()) {\n this._empty.next(focusNextOnEmpty);\n }\n }\n }\n\n /**\n * Pop items off of the stack up to but excluding `lastItem` and emit each on the close\n * observable. If the stack is empty or `lastItem` is not on the stack it does nothing.\n * @param lastItem the element which should be left on the stack\n * @return whether or not an item was removed from the stack\n */\n closeSubMenuOf(lastItem: MenuStackItem) {\n let removed = false;\n if (this._elements.indexOf(lastItem) >= 0) {\n removed = this.peek() !== lastItem;\n while (this.peek() !== lastItem) {\n this._close.next({item: this._elements.pop()!});\n }\n }\n return removed;\n }\n\n /**\n * Pop off all MenuStackItems and emit each one on the `close` observable one by one.\n * @param options Options that configure behavior on close.\n */\n closeAll(options?: CloseOptions) {\n const {focusNextOnEmpty, focusParentTrigger} = {...options};\n if (!this.isEmpty()) {\n while (!this.isEmpty()) {\n const menuStackItem = this._elements.pop();\n if (menuStackItem) {\n this._close.next({item: menuStackItem, focusParentTrigger});\n }\n }\n this._empty.next(focusNextOnEmpty);\n }\n }\n\n /** Return true if this stack is empty. */\n isEmpty() {\n return !this._elements.length;\n }\n\n /** Return the length of the stack. */\n length() {\n return this._elements.length;\n }\n\n /** Get the top most element on the stack. */\n peek(): MenuStackItem | undefined {\n return this._elements[this._elements.length - 1];\n }\n\n /** Whether the menu stack is associated with an inline menu. */\n hasInlineMenu() {\n return this._inlineMenuOrientation != null;\n }\n\n /** The orientation of the associated inline menu. */\n inlineMenuOrientation() {\n return this._inlineMenuOrientation;\n }\n\n /** Sets whether the menu stack contains the focused element. */\n setHasFocus(hasFocus: boolean) {\n this._hasFocus.next(hasFocus);\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n Directive,\n EventEmitter,\n inject,\n Injectable,\n InjectionToken,\n Injector,\n OnDestroy,\n TemplateRef,\n ViewContainerRef,\n} from '@angular/core';\nimport {Menu} from './menu-interface';\nimport {MENU_STACK, MenuStack} from './menu-stack';\nimport {\n ConnectedPosition,\n createRepositionScrollStrategy,\n OverlayRef,\n ScrollStrategy,\n} from '../overlay';\nimport {TemplatePortal} from '../portal';\nimport {merge, Subject} from 'rxjs';\n\n/** Injection token used for an implementation of MenuStack. */\nexport const MENU_TRIGGER = new InjectionToken<CdkMenuTriggerBase>('cdk-menu-trigger');\n\n/** Injection token used to configure the behavior of the menu when the page is scrolled. */\nexport const MENU_SCROLL_STRATEGY = new InjectionToken<() => ScrollStrategy>(\n 'cdk-menu-scroll-strategy',\n {\n providedIn: 'root',\n factory: () => {\n const injector = inject(Injector);\n return () => createRepositionScrollStrategy(injector);\n },\n },\n);\n\n/** Tracks the last open menu trigger across the entire application. */\n@Injectable({providedIn: 'root'})\nexport class MenuTracker {\n /** The last open menu trigger. */\n private static _openMenuTrigger?: CdkMenuTriggerBase;\n\n /**\n * Close the previous open menu and set the given one as being open.\n * @param trigger The trigger for the currently open Menu.\n */\n update(trigger: CdkMenuTriggerBase) {\n if (MenuTracker._openMenuTrigger !== trigger) {\n MenuTracker._openMenuTrigger?.close();\n MenuTracker._openMenuTrigger = trigger;\n }\n }\n}\n\n/**\n * Abstract directive that implements shared logic common to all menu triggers.\n * This class can be extended to create custom menu trigger types.\n */\n@Directive({\n host: {\n '[attr.aria-controls]': 'childMenu?.id',\n '[attr.data-cdk-menu-stack-id]': 'menuStack.id',\n },\n})\nexport abstract class CdkMenuTriggerBase implements OnDestroy {\n /** The DI injector for this component. */\n readonly injector = inject(Injector);\n\n /** The view container ref for this component */\n protected readonly viewContainerRef = inject(ViewContainerRef);\n\n /** The menu stack in which this menu resides. */\n protected readonly menuStack: MenuStack = inject(MENU_STACK);\n\n /** Function used to configure the scroll strategy for the menu. */\n protected readonly menuScrollStrategy = inject(MENU_SCROLL_STRATEGY);\n\n /**\n * A list of preferred menu positions to be used when constructing the\n * `FlexibleConnectedPositionStrategy` for this trigger's menu.\n */\n menuPosition: ConnectedPosition[];\n\n /** Emits when the attached menu is requested to open */\n readonly opened: EventEmitter<void> = new EventEmitter();\n\n /** Emits when the attached menu is requested to close */\n readonly closed: EventEmitter<void> = new EventEmitter();\n\n /** Template reference variable to the menu this trigger opens */\n menuTemplateRef: TemplateRef<unknown> | null;\n\n /** Context data to be passed along to the menu template */\n menuData: unknown;\n\n /** Close the opened menu. */\n abstract close(): void;\n\n /** A reference to the overlay which manages the triggered menu */\n protected overlayRef: OverlayRef | null = null;\n\n /** Emits when this trigger is destroyed. */\n protected readonly destroyed: Subject<void> = new Subject();\n\n /** Emits when the outside pointer events listener on the overlay should be stopped. */\n protected readonly stopOutsideClicksListener = merge(this.closed, this.destroyed);\n\n /** The child menu opened by this trigger. */\n protected childMenu?: Menu;\n\n /** The content of the menu panel opened by this trigger. */\n private _menuPortal: TemplatePortal;\n\n /** The injector to use for the child menu opened by this trigger. */\n private _childMenuInjector?: Injector;\n\n ngOnDestroy() {\n this._destroyOverlay();\n\n this.destroyed.next();\n this.destroyed.complete();\n }\n\n /** Whether the attached menu is open. */\n isOpen() {\n return !!this.overlayRef?.hasAttached();\n }\n\n /** Registers a child menu as having been opened by this trigger. */\n registerChildMenu(child: Menu) {\n this.childMenu = child;\n }\n\n /**\n * Get the portal to be attached to the overlay which contains the menu. Allows for the menu\n * content to change dynamically and be reflected in the application.\n */\n protected getMenuContentPortal() {\n const hasMenuContentChanged = this.menuTemplateRef !== this._menuPortal?.templateRef;\n if (this.menuTemplateRef && (!this._menuPortal || hasMenuContentChanged)) {\n this._menuPortal = new TemplatePortal(\n this.menuTemplateRef,\n this.viewContainerRef,\n this.menuData,\n this._getChildMenuInjector(),\n );\n }\n\n return this._menuPortal;\n }\n\n /**\n * Whether the given element is inside the scope of this trigger's menu stack.\n * @param element The element to check.\n * @return Whether the element is inside the scope of this trigger's menu stack.\n */\n protected isElementInsideMenuStack(element: Element) {\n for (let el: Element | null = element; el; el = el?.parentElement ?? null) {\n if (el.getAttribute('data-cdk-menu-stack-id') === this.menuStack.id) {\n return true;\n }\n }\n return false;\n }\n\n /** Destroy and unset the overlay reference it if exists */\n private _destroyOverlay() {\n if (this.overlayRef) {\n this.overlayRef.dispose();\n this.overlayRef = null;\n }\n }\n\n /** Gets the injector to use when creating a child menu. */\n private _getChildMenuInjector() {\n this._childMenuInjector =\n this._childMenuInjector ||\n Injector.create({\n providers: [\n {provide: MENU_TRIGGER, useValue: this},\n {provide: MENU_STACK, useValue: this.menuStack},\n ],\n parent: this.injector,\n });\n return this._childMenuInjector;\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\n/**\n * Throws an exception when an instance of the PointerFocusTracker is not provided.\n * @docs-private\n */\nexport function throwMissingPointerFocusTracker() {\n throw Error('expected an instance of PointerFocusTracker to be provided');\n}\n\n/**\n * Throws an exception when a reference to the parent menu is not provided.\n * @docs-private\n */\nexport function throwMissingMenuReference() {\n throw Error('expected a reference to the parent menu');\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n Directive,\n inject,\n Injectable,\n InjectionToken,\n NgZone,\n OnDestroy,\n RendererFactory2,\n} from '@angular/core';\nimport {Subject} from 'rxjs';\nimport {FocusableElement, PointerFocusTracker} from './pointer-focus-tracker';\nimport {Menu} from './menu-interface';\nimport {throwMissingMenuReference, throwMissingPointerFocusTracker} from './menu-errors';\n\n/**\n * MenuAim is responsible for determining if a sibling menuitem's menu should be closed when a\n * Toggler item is hovered into. It is up to the hovered in item to call the MenuAim service in\n * order to determine if it may perform its close actions.\n */\nexport interface MenuAim {\n /**\n * Set the Menu and its PointerFocusTracker.\n * @param menu The menu that this menu aim service controls.\n * @param pointerTracker The `PointerFocusTracker` for the given menu.\n */\n initialize(menu: Menu, pointerTracker: PointerFocusTracker<FocusableElement & Toggler>): void;\n\n /**\n * Calls the `doToggle` callback when it is deemed that the user is not moving towards\n * the submenu.\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n toggle(doToggle: () => void): void;\n}\n\n/** Injection token used for an implementation of MenuAim. */\nexport const MENU_AIM = new InjectionToken<MenuAim>('cdk-menu-aim');\n\n/** Capture every nth mouse move event. */\nconst MOUSE_MOVE_SAMPLE_FREQUENCY = 3;\n\n/** The number of mouse move events to track. */\nconst NUM_POINTS = 5;\n\n/**\n * How long to wait before closing a sibling menu if a user stops short of the submenu they were\n * predicted to go into.\n */\nconst CLOSE_DELAY = 300;\n\n/** An element which when hovered over may open or close a menu. */\nexport interface Toggler {\n /** Gets the open menu, or undefined if no menu is open. */\n getMenu(): Menu | undefined;\n}\n\n/** Calculate the slope between point a and b. */\nfunction getSlope(a: Point, b: Point) {\n return (b.y - a.y) / (b.x - a.x);\n}\n\n/** Calculate the y intercept for the given point and slope. */\nfunction getYIntercept(point: Point, slope: number) {\n return point.y - slope * point.x;\n}\n\n/** Represents a coordinate of mouse travel. */\ntype Point = {x: number; y: number};\n\n/**\n * Whether the given mouse trajectory line defined by the slope and y intercept falls within the\n * submenu as defined by `submenuPoints`\n * @param submenuPoints the submenu DOMRect points.\n * @param m the slope of the trajectory line.\n * @param b the y intercept of the trajectory line.\n * @return true if any point on the line falls within the submenu.\n */\nfunction isWithinSubmenu(submenuPoints: DOMRect, m: number, b: number) {\n const {left, right, top, bottom} = submenuPoints;\n\n // Check for intersection with each edge of the submenu (left, right, top, bottom)\n // by fixing one coordinate to that edge's coordinate (either x or y) and checking if the\n // other coordinate is within bounds.\n return (\n (m * left + b >= top && m * left + b <= bottom) ||\n (m * right + b >= top && m * right + b <= bottom) ||\n ((top - b) / m >= left && (top - b) / m <= right) ||\n ((bottom - b) / m >= left && (bottom - b) / m <= right)\n );\n}\n\n/**\n * TargetMenuAim predicts if a user is moving into a submenu. It calculates the\n * trajectory of the user's mouse movement in the current menu to determine if the\n * mouse is moving towards an open submenu.\n *\n * The determination is made by calculating the slope of the users last NUM_POINTS moves where each\n * pair of points determines if the trajectory line points into the submenu. It uses consensus\n * approach by checking if at least NUM_POINTS / 2 pairs determine that the user is moving towards\n * to submenu.\n */\n@Injectable()\nexport class TargetMenuAim implements MenuAim, OnDestroy {\n private readonly _ngZone = inject(NgZone);\n private readonly _renderer = inject(RendererFactory2).createRenderer(null, null);\n private _cleanupMousemove: (() => void) | undefined;\n\n /** The last NUM_POINTS mouse move events. */\n private readonly _points: Point[] = [];\n\n /** Reference to the root menu in which we are tracking mouse moves. */\n private _menu: Menu;\n\n /** Reference to the root menu's mouse manager. */\n private _pointerTracker: PointerFocusTracker<Toggler & FocusableElement>;\n\n /** The id associated with the current timeout call waiting to resolve. */\n private _timeoutId: number | null;\n\n /** Emits when this service is destroyed. */\n private readonly _destroyed: Subject<void> = new Subject();\n\n ngOnDestroy() {\n this._cleanupMousemove?.();\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n /**\n * Set the Menu and its PointerFocusTracker.\n * @param menu The menu that this menu aim service controls.\n * @param pointerTracker The `PointerFocusTracker` for the given menu.\n */\n initialize(menu: Menu, pointerTracker: PointerFocusTracker<FocusableElement & Toggler>) {\n this._menu = menu;\n this._pointerTracker = pointerTracker;\n this._subscribeToMouseMoves();\n }\n\n /**\n * Calls the `doToggle` callback when it is deemed that the user is not moving towards\n * the submenu.\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n toggle(doToggle: () => void) {\n // If the menu is horizontal the sub-menus open below and there is no risk of premature\n // closing of any sub-menus therefore we automatically resolve the callback.\n if (this._menu.orientation === 'horizontal') {\n doToggle();\n }\n\n this._checkConfigured();\n\n const siblingItemIsWaiting = !!this._timeoutId;\n const hasPoints = this._points.length > 1;\n\n if (hasPoints && !siblingItemIsWaiting) {\n if (this._isMovingToSubmenu()) {\n this._startTimeout(doToggle);\n } else {\n doToggle();\n }\n } else if (!siblingItemIsWaiting) {\n doToggle();\n }\n }\n\n /**\n * Start the delayed toggle handler if one isn't running already.\n *\n * The delayed toggle handler executes the `doToggle` callback after some period of time iff the\n * users mouse is on an item in the current menu.\n *\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n private _startTimeout(doToggle: () => void) {\n // If the users mouse is moving towards a submenu we don't want to immediately resolve.\n // Wait for some period of time before determining if the previous menu should close in\n // cases where the user may have moved towards the submenu but stopped on a sibling menu\n // item intentionally.\n const timeoutId = setTimeout(() => {\n // Resolve if the user is currently moused over some element in the root menu\n if (this._pointerTracker!.activeElement && timeoutId === this._timeoutId) {\n doToggle();\n }\n this._timeoutId = null;\n }, CLOSE_DELAY) as any as number;\n\n this._timeoutId = timeoutId;\n }\n\n /** Whether the user is heading towards the open submenu. */\n private _isMovingToSubmenu() {\n const submenuPoints = this._getSubmenuBounds();\n if (!submenuPoints) {\n return false;\n }\n\n let numMoving = 0;\n const currPoint = this._points[this._points.length - 1];\n // start from the second last point and calculate the slope between each point and the last\n // point.\n for (let i = this._points.length - 2; i >= 0; i--) {\n const previous = this._points[i];\n const slope = getSlope(currPoint, previous);\n if (isWithinSubmenu(submenuPoints, slope, getYIntercept(currPoint, slope))) {\n numMoving++;\n }\n }\n return numMoving >= Math.floor(NUM_POINTS / 2);\n }\n\n /** Get the bounding DOMRect for the open submenu. */\n private _getSubmenuBounds(): DOMRect | undefined {\n return this._pointerTracker?.previousElement?.getMenu()?.nativeElement.getBoundingClientRect();\n }\n\n /**\n * Check if a reference to the PointerFocusTracker and menu element is provided.\n * @throws an error if neither reference is provided.\n */\n private _checkConfigured() {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!this._pointerTracker) {\n throwMissingPointerFocusTracker();\n }\n if (!this._menu) {\n throwMissingMenuReference();\n }\n }\n }\n\n /** Subscribe to the root menus mouse move events and update the tracked mouse points. */\n private _subscribeToMouseMoves() {\n this._cleanupMousemove?.();\n\n this._cleanupMousemove = this._ngZone.runOutsideAngular(() => {\n let eventIndex = 0;\n\n return this._renderer.listen(this._menu.nativeElement, 'mousemove', (event: MouseEvent) => {\n if (eventIndex % MOUSE_MOVE_SAMPLE_FREQUENCY === 0) {\n this._points.push({x: event.clientX, y: event.clientY});\n if (this._points.length > NUM_POINTS) {\n this._points.shift();\n }\n }\n eventIndex++;\n });\n });\n }\n}\n\n/**\n * CdkTargetMenuAim is a provider for the TargetMenuAim service. It can be added to an\n * element with either the `cdkMenu` or `cdkMenuBar` directive and child menu items.\n */\n@Directive({\n selector: '[cdkTargetMenuAim]',\n exportAs: 'cdkTargetMenuAim',\n providers: [{provide: MENU_AIM, useClass: TargetMenuAim}],\n})\nexport class CdkTargetMenuAim {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ElementRef} from '@angular/core';\nimport {ENTER, SPACE} from '../keycodes';\n\n/** Checks whether a keyboard event will trigger a native `click` event on an element. */\nexport function eventDispatchesNativeClick(\n elementRef: ElementRef<HTMLElement>,\n event: KeyboardEvent,\n): boolean {\n // Synthetic events won't trigger clicks.\n if (!event.isTrusted) {\n return false;\n }\n\n const el = elementRef.nativeElement;\n const keyCode = event.keyCode;\n\n // Buttons trigger clicks both on space and enter events.\n if (el.nodeName === 'BUTTON' && !(el as HTMLButtonElement).disabled) {\n return keyCode === ENTER || keyCode === SPACE;\n }\n\n // Links only trigger clicks on enter.\n if (el.nodeName === 'A') {\n return keyCode === ENTER;\n }\n\n // Any other elements won't dispatch clicks from keyboard events.\n return false;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n ChangeDetectorRef,\n Directive,\n ElementRef,\n inject,\n Injector,\n NgZone,\n OnChanges,\n OnDestroy,\n Renderer2,\n SimpleChanges,\n} from '@angular/core';\nimport {InputModalityDetector} from '../a11y';\nimport {Directionality} from '../bidi';\nimport {\n ConnectedPosition,\n createFlexibleConnectedPositionStrategy,\n createOverlayRef,\n FlexibleConnectedPositionStrategy,\n OverlayConfig,\n STANDARD_DROPDOWN_ADJACENT_POSITIONS,\n STANDARD_DROPDOWN_BELOW_POSITIONS,\n} from '../overlay';\nimport {\n DOWN_ARROW,\n ENTER,\n hasModifierKey,\n LEFT_ARROW,\n RIGHT_ARROW,\n SPACE,\n UP_ARROW,\n} from '../keycodes';\nimport {_getEventTarget} from '../platform';\nimport {takeUntil} from 'rxjs/operators';\nimport {CDK_MENU, Menu} from './menu-interface';\nimport {PARENT_OR_NEW_MENU_STACK_PROVIDER} from './menu-stack';\nimport {MENU_AIM} from './menu-aim';\nimport {CdkMenuTriggerBase, MENU_TRIGGER, MenuTracker} from './menu-trigger-base';\nimport {eventDispatchesNativeClick} from './event-detection';\n\n/**\n * A directive that turns its host element into a trigger for a popup menu.\n * It can be combined with cdkMenuItem to create sub-menus. If the element is in a top level\n * MenuBar it will open the menu on click, or if a sibling is already opened it will open on hover.\n * If it is inside of a Menu it will open the attached Submenu on hover regardless of its sibling\n * state.\n */\n@Directive({\n selector: '[cdkMenuTriggerFor]',\n exportAs: 'cdkMenuTriggerFor',\n host: {\n 'class': 'cdk-menu-trigger',\n '[attr.aria-haspopup]': 'menuTemplateRef ? \"menu\" : null',\n '[attr.aria-expanded]': 'menuTemplateRef == null ? null : isOpen()',\n '(focusin)': '_setHasFocus(true)',\n '(focusout)': '_setHasFocus(false)',\n '(keydown)': '_toggleOnKeydown($event)',\n '(click)': '_handleClick()',\n },\n inputs: [\n {name: 'menuTemplateRef', alias: 'cdkMenuTriggerFor'},\n {name: 'menuPosition', alias: 'cdkMenuPosition'},\n {name: 'menuData', alias: 'cdkMenuTriggerData'},\n ],\n outputs: ['opened: cdkMenuOpened', 'closed: cdkMenuClosed'],\n providers: [\n {provide: MENU_TRIGGER, useExisting: CdkMenuTrigger},\n PARENT_OR_NEW_MENU_STACK_PROVIDER,\n ],\n})\nexport class CdkMenuTrigger extends CdkMenuTriggerBase implements OnChanges, OnDestroy {\n private readonly _elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n private readonly _ngZone = inject(NgZone);\n private readonly _changeDetectorRef = inject(ChangeDetectorRef);\n private readonly _inputModalityDetector = inject(InputModalityDetector);\n private readonly _directionality = inject(Directionality, {optional: true});\n private readonly _renderer = inject(Renderer2);\n private readonly _injector = inject(Injector);\n private _cleanupMouseenter: () => void;\n\n /** The app's menu tracking registry */\n private readonly _menuTracker = inject(MenuTracker);\n\n /** The parent menu this trigger belongs to. */\n private readonly _parentMenu = inject(CDK_MENU, {optional: true});\n\n /** The menu aim service used by this menu. */\n private readonly _menuAim = inject(MENU_AIM, {optional: true});\n\n constructor() {\n super();\n this._setRole();\n this._registerCloseHandler();\n this._subscribeToMenuStackClosed();\n this._subscribeToMouseEnter();\n this._subscribeToMenuStackHasFocus();\n this._setType();\n }\n\n /** Toggle the attached menu. */\n toggle() {\n this.isOpen() ? this.close() : this.open();\n }\n\n /** Open the attached menu. */\n open() {\n if (!this._parentMenu) {\n this._menuTracker.update(this);\n }\n if (!this.isOpen() && this.menuTemplateRef != null) {\n this.opened.next();\n\n this.overlayRef =\n this.overlayRef || createOverlayRef(this._injector, this._getOverlayConfig());\n this.overlayRef.attach(this.getMenuContentPortal());\n this._changeDetectorRef.markForCheck();\n this._subscribeToOutsideClicks();\n }\n }\n\n /** Close the opened menu. */\n close() {\n if (this.isOpen()) {\n this.closed.next();\n\n this.overlayRef!.detach();\n this._changeDetectorRef.markForCheck();\n }\n this._closeSiblingTriggers();\n }\n\n /**\n * Get a reference to the rendered Menu if the Menu is open and rendered in the DOM.\n */\n getMenu(): Menu | undefined {\n return this.childMenu;\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes['menuPosition'] && this.overlayRef) {\n this.overlayRef.updatePositionStrategy(this._getOverlayPositionStrategy());\n }\n }\n\n override ngOnDestroy(): void {\n this._cleanupMouseenter();\n super.ngOnDestroy();\n }\n\n /**\n * Handles keyboard events for the menu item.\n * @param event The keyboard event to handle\n */\n _toggleOnKeydown(event: KeyboardEvent) {\n const isParentVertical = this._parentMenu?.orientation === 'vertical';\n switch (event.keyCode) {\n case SPACE:\n case ENTER:\n // Skip events that will trigger clicks so the handler doesn't get triggered twice.\n if (!hasModifierKey(event) && !eventDispatchesNativeClick(this._elementRef, event)) {\n this.toggle();\n this.childMenu?.focusFirstItem('keyboard');\n }\n break;\n\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && isParentVertical && this._directionality?.value !== 'rtl') {\n event.preventDefault();\n this.open();\n this.childMenu?.focusFirstItem('keyboard');\n }\n }\n break;\n\n case LEFT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && isParentVertical && this._directionality?.value === 'rtl') {\n event.preventDefault();\n this.open();\n this.childMenu?.focusFirstItem('keyboard');\n }\n }\n break;\n\n case DOWN_ARROW:\n case UP_ARROW:\n if (!hasModifierKey(event)) {\n if (!isParentVertical) {\n event.preventDefault();\n this.open();\n event.keyCode === DOWN_ARROW\n ? this.childMenu?.focusFirstItem('keyboard')\n : this.childMenu?.focusLastItem('keyboard');\n }\n }\n break;\n }\n }\n\n /** Handles clicks on the menu trigger. */\n _handleClick() {\n this.toggle();\n this.childMenu?.focusFirstItem('mouse');\n }\n\n /**\n * Sets whether the trigger's menu stack has focus.\n * @param hasFocus Whether the menu stack has focus.\n */\n _setHasFocus(hasFocus: boolean) {\n if (!this._parentMenu) {\n this.menuStack.setHasFocus(hasFocus);\n }\n }\n\n /**\n * Subscribe to the mouseenter events and close any sibling menu items if this element is moused\n * into.\n */\n private _subscribeToMouseEnter() {\n this._cleanupMouseenter = this._ngZone.runOutsideAngular(() => {\n return this._renderer.listen(this._elementRef.nativeElement, 'mouseenter', () => {\n if (\n // Skip fake `mouseenter` events dispatched by touch devices.\n this._inputModalityDetector.mostRecentModality !== 'touch' &&\n !this.menuStack.isEmpty() &&\n !this.isOpen()\n ) {\n // Closes any sibling menu items and opens the menu associated with this trigger.\n const toggleMenus = () =>\n this._ngZone.run(() => {\n this._closeSiblingTriggers();\n this.open();\n });\n\n if (this._menuAim) {\n this._menuAim.toggle(toggleMenus);\n } else {\n toggleMenus();\n }\n }\n });\n });\n }\n\n /** Close out any sibling menu trigger menus. */\n private _closeSiblingTriggers() {\n if (this._parentMenu) {\n // If nothing was removed from the stack and the last element is not the parent item\n // that means that the parent menu is a menu bar since we don't put the menu bar on the\n // stack\n const isParentMenuBar =\n !this.menuStack.closeSubMenuOf(this._parentMenu) &&\n this.menuStack.peek() !== this._parentMenu;\n\n if (isParentMenuBar) {\n this.menuStack.closeAll();\n }\n } else {\n this.menuStack.closeAll();\n }\n }\n\n /** Get the configuration object used to create the overlay. */\n private _getOverlayConfig() {\n return new OverlayConfig({\n positionStrategy: this._getOverlayPositionStrategy(),\n scrollStrategy: this.menuScrollStrategy(),\n direction: this._directionality || undefined,\n });\n }\n\n /** Build the position strategy for the overlay which specifies where to place the menu. */\n private _getOverlayPositionStrategy(): FlexibleConnectedPositionStrategy {\n return createFlexibleConnectedPositionStrategy(this._injector, this._elementRef)\n .withLockedPosition()\n .withFlexibleDimensions(false)\n .withPositions(this._getOverlayPositions());\n }\n\n /** Get the preferred positions for the opened menu relative to the menu item. */\n private _getOverlayPositions(): ConnectedPosition[] {\n return (\n this.menuPosition ??\n (!this._parentMenu || this._parentMenu.orientation === 'horizontal'\n ? STANDARD_DROPDOWN_BELOW_POSITIONS\n : STANDARD_DROPDOWN_ADJACENT_POSITIONS)\n );\n }\n\n /**\n * Subscribe to the MenuStack close events if this is a standalone trigger and close out the menu\n * this triggers when requested.\n */\n private _registerCloseHandler() {\n if (!this._parentMenu) {\n this.menuStack.closed.pipe(takeUntil(this.destroyed)).subscribe(({item}) => {\n if (item === this.childMenu) {\n this.close();\n }\n });\n }\n }\n\n /**\n * Subscribe to the overlays outside pointer events stream and handle closing out the stack if a\n * click occurs outside the menus.\n */\n private _subscribeToOutsideClicks() {\n if (this.overlayRef) {\n this.overlayRef\n .outsidePointerEvents()\n .pipe(takeUntil(this.stopOutsideClicksListener))\n .subscribe(event => {\n const target = _getEventTarget(event) as Element;\n const element = this._elementRef.nativeElement;\n\n if (target !== element && !element.contains(target)) {\n if (!this.isElementInsideMenuStack(target)) {\n this.menuStack.closeAll();\n } else {\n this._closeSiblingTriggers();\n }\n }\n });\n }\n }\n\n /** Subscribe to the MenuStack hasFocus events. */\n private _subscribeToMenuStackHasFocus() {\n if (!this._parentMenu) {\n this.menuStack.hasFocus.pipe(takeUntil(this.destroyed)).subscribe(hasFocus => {\n if (!hasFocus) {\n this.menuStack.closeAll();\n }\n });\n }\n }\n\n /** Subscribe to the MenuStack closed events. */\n private _subscribeToMenuStackClosed() {\n if (!this._parentMenu) {\n this.menuStack.closed.subscribe(({focusParentTrigger}) => {\n if (focusParentTrigger && !this.menuStack.length()) {\n this._elementRef.nativeElement.focus();\n }\n });\n }\n }\n\n /** Sets the role attribute for this trigger if needed. */\n private _setRole() {\n // If this trigger is part of another menu, the cdkMenuItem directive will handle setting the\n // role, otherwise this is a standalone trigger, and we should ensure it has role=\"button\".\n if (!this._parentMenu) {\n this._elementRef.nativeElement.setAttribute('role', 'button');\n }\n }\n\n /** Sets thte `type` attribute of the trigger. */\n private _setType() {\n const element = this._elementRef.nativeElement;\n\n if (element.nodeName === 'BUTTON' && !element.getAttribute('type')) {\n // Prevents form submissions.\n element.setAttribute('type', 'button');\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n booleanAttribute,\n Directive,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n NgZone,\n OnDestroy,\n Output,\n Renderer2,\n} from '@angular/core';\nimport {FocusableOption, InputModalityDetector} from '../a11y';\nimport {ENTER, hasModifierKey, LEFT_ARROW, RIGHT_ARROW, SPACE} from '../keycodes';\nimport {Directionality} from '../bidi';\nimport {Subject} from 'rxjs';\nimport {CdkMenuTrigger} from './menu-trigger';\nimport {CDK_MENU, Menu} from './menu-interface';\nimport {FocusNext, MENU_STACK} from './menu-stack';\nimport {FocusableElement} from './pointer-focus-tracker';\nimport {MENU_AIM, Toggler} from './menu-aim';\nimport {eventDispatchesNativeClick} from './event-detection';\n\n/**\n * Directive which provides the ability for an element to be focused and navigated to using the\n * keyboard when residing in a CdkMenu, CdkMenuBar, or CdkMenuGroup. It performs user defined\n * behavior when clicked.\n */\n@Directive({\n selector: '[cdkMenuItem]',\n exportAs: 'cdkMenuItem',\n host: {\n 'role': 'menuitem',\n 'class': 'cdk-menu-item',\n '[class.cdk-menu-item-disabled]': 'disabled',\n '[tabindex]': '_tabindex',\n '[attr.aria-disabled]': 'disabled || null',\n '(blur)': '_resetTabIndex()',\n '(focus)': '_setTabIndex()',\n '(click)': '_handleClick($event)',\n '(keydown)': '_onKeydown($event)',\n },\n})\nexport class CdkMenuItem implements FocusableOption, FocusableElement, Toggler, OnDestroy {\n protected readonly _dir = inject(Directionality, {optional: true});\n readonly _elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n protected _ngZone = inject(NgZone);\n private readonly _inputModalityDetector = inject(InputModalityDetector);\n private readonly _renderer = inject(Renderer2);\n private _cleanupMouseEnter: (() => void) | undefined;\n\n /** The menu aim service used by this menu. */\n private readonly _menuAim = inject(MENU_AIM, {optional: true});\n\n /** The stack of menus this menu belongs to. */\n private readonly _menuStack = inject(MENU_STACK);\n\n /** The parent menu in which this menuitem resides. */\n readonly _parentMenu = inject(CDK_MENU, {optional: true});\n\n /** Reference to the CdkMenuItemTrigger directive if one is added to the same element */\n private readonly _menuTrigger = inject(CdkMenuTrigger, {optional: true, self: true});\n\n /** Whether the CdkMenuItem is disabled - defaults to false */\n @Input({alias: 'cdkMenuItemDisabled', transform: booleanAttribute}) disabled: boolean = false;\n\n /**\n * The text used to locate this item during menu typeahead. If not specified,\n * the `textContent` of the item will be used.\n */\n @Input('cdkMenuitemTypeaheadLabel') typeaheadLabel: string | null;\n\n /**\n * If this MenuItem is a regular MenuItem, outputs when it is triggered by a keyboard or mouse\n * event.\n */\n @Output('cdkMenuItemTriggered') readonly triggered: EventEmitter<void> = new EventEmitter();\n\n /** Whether the menu item opens a menu. */\n get hasMenu() {\n return this._menuTrigger?.menuTemplateRef != null;\n }\n\n /**\n * The tabindex for this menu item managed internally and used for implementing roving a\n * tab index.\n */\n _tabindex: 0 | -1 = -1;\n\n /** Whether the item should close the menu if triggered by the spacebar. */\n protected closeOnSpacebarTrigger = true;\n\n /** Emits when the menu item is destroyed. */\n protected readonly destroyed = new Subject<void>();\n\n constructor() {\n this._setupMouseEnter();\n this._setType();\n\n if (this._isStandaloneItem()) {\n this._tabindex = 0;\n }\n }\n\n ngOnDestroy() {\n this._cleanupMouseEnter?.();\n this.destroyed.next();\n this.destroyed.complete();\n }\n\n /** Place focus on the element. */\n focus() {\n this._elementRef.nativeElement.focus();\n }\n\n /**\n * If the menu item is not disabled and the element does not have a menu trigger attached, emit\n * on the cdkMenuItemTriggered emitter and close all open menus.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n trigger(options?: {keepOpen: boolean}) {\n const {keepOpen} = {...options};\n if (!this.disabled && !this.hasMenu) {\n this.triggered.next();\n if (!keepOpen) {\n this._menuStack.closeAll({focusParentTrigger: true});\n }\n }\n }\n\n /** Return true if this MenuItem has an attached menu and it is open. */\n isMenuOpen() {\n return !!this._menuTrigger?.isOpen();\n }\n\n /**\n * Get a reference to the rendered Menu if the Menu is open and it is visible in the DOM.\n * @return the menu if it is open, otherwise undefined.\n */\n getMenu(): Menu | undefined {\n return this._menuTrigger?.getMenu();\n }\n\n /** Get the CdkMenuTrigger associated with this element. */\n getMenuTrigger(): CdkMenuTrigger | null {\n return this._menuTrigger;\n }\n\n /** Get the label for this element which is required by the FocusableOption interface. */\n getLabel(): string {\n return this.typeaheadLabel || this._elementRef.nativeElement.textContent?.trim() || '';\n }\n\n /** Reset the tabindex to -1. */\n _resetTabIndex() {\n if (!this._isStandaloneItem()) {\n this._tabindex = -1;\n }\n }\n\n /**\n * Set the tab index to 0 if not disabled and it's a focus event, or a mouse enter if this element\n * is not in a menu bar.\n */\n _setTabIndex(event?: MouseEvent) {\n if (this.disabled) {\n return;\n }\n\n // don't set the tabindex if there are no open sibling or parent menus\n if (!event || !this._menuStack.isEmpty()) {\n this._tabindex = 0;\n }\n }\n\n /** Handles click events on the item. */\n protected _handleClick(event: MouseEvent) {\n if (this.disabled) {\n event.preventDefault();\n event.stopPropagation();\n } else {\n this.trigger();\n }\n }\n\n /**\n * Handles keyboard events for the menu item, specifically either triggering the user defined\n * callback or opening/closing the current menu based on whether the left or right arrow key was\n * pressed.\n * @param event the keyboard event to handle\n */\n _onKeydown(event: KeyboardEvent) {\n switch (event.keyCode) {\n case SPACE:\n case ENTER:\n // Skip events that will trigger clicks so the handler doesn't get triggered twice.\n if (!hasModifierKey(event) && !eventDispatchesNativeClick(this._elementRef, event)) {\n const nodeName = this._elementRef.nativeElement.nodeName;\n\n // Avoid repeat events on non-native elements (see #30250). Note that we don't do this\n // on the native elements so we don't interfere with their behavior (see #26296).\n if (nodeName !== 'A' && nodeName !== 'BUTTON') {\n event.preventDefault();\n }\n\n this.trigger({keepOpen: event.keyCode === SPACE && !this.closeOnSpacebarTrigger});\n }\n break;\n\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && this._isParentVertical()) {\n if (this._dir?.value !== 'rtl') {\n this._forwardArrowPressed(event);\n } else {\n this._backArrowPressed(event);\n }\n }\n }\n break;\n\n case LEFT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && this._isParentVertical()) {\n if (this._dir?.value !== 'rtl') {\n this._backArrowPressed(event);\n } else {\n this._forwardArrowPressed(event);\n }\n }\n }\n break;\n }\n }\n\n /** Whether this menu item is standalone or within a menu or menu bar. */\n private _isStandaloneItem() {\n return !this._parentMenu;\n }\n\n /**\n * Handles the user pressing the back arrow key.\n * @param event The keyboard event.\n */\n private _backArrowPressed(event: KeyboardEvent) {\n const parentMenu = this._parentMenu!;\n if (this._menuStack.hasInlineMenu() || this._menuStack.length() > 1) {\n event.preventDefault();\n this._menuStack.close(parentMenu, {\n focusNextOnEmpty:\n this._menuStack.inlineMenuOrientation() === 'horizontal'\n ? FocusNext.previousItem\n : FocusNext.currentItem,\n focusParentTrigger: true,\n });\n }\n }\n\n /**\n * Handles the user pressing the forward arrow key.\n * @param event The keyboard event.\n */\n private _forwardArrowPressed(event: KeyboardEvent) {\n if (!this.hasMenu && this._menuStack.inlineMenuOrientation() === 'horizontal') {\n event.preventDefault();\n this._menuStack.closeAll({\n focusNextOnEmpty: FocusNext.nextItem,\n focusParentTrigger: true,\n });\n }\n }\n\n /**\n * Subscribe to the mouseenter events and close any sibling menu items if this element is moused\n * into.\n */\n private _setupMouseEnter() {\n if (!this._isStandaloneItem()) {\n const closeOpenSiblings = () =>\n this._ngZone.run(() => this._menuStack.closeSubMenuOf(this._parentMenu!));\n\n this._cleanupMouseEnter = this._ngZone.runOutsideAngular(() =>\n this._renderer.listen(this._elementRef.nativeElement, 'mouseenter', () => {\n // Skip fake `mouseenter` events dispatched by touch devices.\n if (\n this._inputModalityDetector.mostRecentModality !== 'touch' &&\n !this._menuStack.isEmpty() &&\n !this.hasMenu\n ) {\n if (this._menuAim) {\n this._menuAim.toggle(closeOpenSiblings);\n } else {\n closeOpenSiblings();\n }\n }\n }),\n );\n }\n }\n\n /**\n * Return true if the enclosing parent menu is configured in a horizontal orientation, false\n * otherwise or if no parent.\n */\n private _isParentVertical() {\n return this._parentMenu?.orientation === 'vertical';\n }\n\n /** Sets the `type` attribute of the menu item. */\n private _setType() {\n const element = this._elementRef.nativeElement;\n\n if (element.nodeName === 'BUTTON' && !element.getAttribute('type')) {\n // Prevent form submissions.\n element.setAttribute('type', 'button');\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ElementRef, QueryList, Renderer2} from '@angular/core';\nimport {Observable, Subject, Subscription} from 'rxjs';\nimport {startWith} from 'rxjs/operators';\n\n/** Item to track for mouse focus events. */\nexport interface FocusableElement {\n /** A reference to the element to be tracked. */\n _elementRef: ElementRef<HTMLElement>;\n}\n\n/**\n * PointerFocusTracker keeps track of the currently active item under mouse focus. It also has\n * observables which emit when the users mouse enters and leaves a tracked element.\n */\nexport class PointerFocusTracker<T extends FocusableElement> {\n private _eventCleanups: (() => void)[] | undefined;\n private _itemsSubscription: Subscription | undefined;\n\n /** Emits when an element is moused into. */\n readonly entered: Observable<T> = new Subject<T>();\n\n /** Emits when an element is moused out. */\n readonly exited: Observable<T> = new Subject<T>();\n\n /** The element currently under mouse focus. */\n activeElement?: T;\n\n /** The element previously under mouse focus. */\n previousElement?: T;\n\n constructor(\n private _renderer: Renderer2,\n private readonly _items: QueryList<T>,\n ) {\n this._bindEvents();\n this.entered.subscribe(element => (this.activeElement = element));\n this.exited.subscribe(() => {\n this.previousElement = this.activeElement;\n this.activeElement = undefined;\n });\n }\n\n /** Stop the managers listeners. */\n destroy() {\n this._cleanupEvents();\n this._itemsSubscription?.unsubscribe();\n }\n\n /** Binds the enter/exit events on all the items. */\n private _bindEvents() {\n // TODO(crisbeto): this can probably be simplified by binding a single event on a parent node.\n this._itemsSubscription = this._items.changes.pipe(startWith(this._items)).subscribe(() => {\n this._cleanupEvents();\n this._eventCleanups = [];\n this._items.forEach(item => {\n const element = item._elementRef.nativeElement;\n this._eventCleanups!.push(\n this._renderer.listen(element, 'mouseenter', () => {\n (this.entered as Subject<T>).next(item);\n }),\n this._renderer.listen(element, 'mouseout', () => {\n (this.exited as Subject<T>).next(item);\n }),\n );\n });\n });\n }\n\n /** Cleans up the currently-bound events. */\n private _cleanupEvents() {\n this._eventCleanups?.forEach(cleanup => cleanup());\n this._eventCleanups = undefined;\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {_IdGenerator, FocusKeyManager, FocusMonitor, FocusOrigin} from '../a11y';\nimport {Directionality} from '../bidi';\nimport {\n AfterContentInit,\n ContentChildren,\n Directive,\n ElementRef,\n Input,\n NgZone,\n OnDestroy,\n QueryList,\n Renderer2,\n computed,\n inject,\n signal,\n} from '@angular/core';\nimport {Subject, merge} from 'rxjs';\nimport {mapTo, mergeAll, mergeMap, startWith, switchMap, takeUntil} from 'rxjs/operators';\nimport {MENU_AIM} from './menu-aim';\nimport {CdkMenuGroup} from './menu-group';\nimport {Menu} from './menu-interface';\nimport {CdkMenuItem} from './menu-item';\nimport {MENU_STACK, MenuStack, MenuStackItem} from './menu-stack';\nimport {PointerFocusTracker} from './pointer-focus-tracker';\n\n/**\n * Abstract directive that implements shared logic common to all menus.\n * This class can be extended to create custom menu types.\n */\n@Directive({\n host: {\n 'role': 'menu',\n 'class': '', // reset the css class added by the super-class\n '[tabindex]': '_getTabIndex()',\n '[id]': 'id',\n '[attr.aria-orientation]': 'orientation',\n '[attr.data-cdk-menu-stack-id]': 'menuStack.id',\n '(focusin)': 'menuStack.setHasFocus(true)',\n '(focusout)': 'menuStack.setHasFocus(false)',\n },\n})\nexport abstract class CdkMenuBase\n extends CdkMenuGroup\n implements Menu, AfterContentInit, OnDestroy\n{\n private _focusMonitor = inject(FocusMonitor);\n protected ngZone = inject(NgZone);\n private _renderer = inject(Renderer2);\n\n /** The menu's native DOM host element. */\n readonly nativeElement: HTMLElement = inject(ElementRef).nativeElement;\n\n /** The stack of menus this menu belongs to. */\n readonly menuStack: MenuStack = inject(MENU_STACK);\n\n /** The menu aim service used by this menu. */\n protected readonly menuAim = inject(MENU_AIM, {optional: true, self: true});\n\n /** The directionality (text direction) of the current page. */\n protected readonly dir = inject(Directionality, {optional: true});\n\n /** All items inside the menu, including ones that belong to other menus. */\n @ContentChildren(CdkMenuItem, {descendants: true})\n protected _allItems: QueryList<CdkMenuItem>;\n\n /** The id of the menu's host element. */\n @Input() id: string = inject(_IdGenerator).getId('cdk-menu-');\n\n /** All child MenuItem elements belonging to this Menu. */\n readonly items: QueryList<CdkMenuItem> = new QueryList();\n\n /** The direction items in the menu flow. */\n orientation: 'horizontal' | 'vertical' = 'vertical';\n\n /**\n * Whether the menu is displayed inline (i.e. always present vs a conditional popup that the\n * user triggers with a trigger element).\n */\n isInline = false;\n\n /** Handles keyboard events for the menu. */\n protected keyManager: FocusKeyManager<CdkMenuItem>;\n\n /** Emits when the MenuBar is destroyed. */\n protected readonly destroyed: Subject<void> = new Subject();\n\n /** The Menu Item which triggered the open submenu. */\n protected triggerItem?: CdkMenuItem;\n\n /** Tracks the users mouse movements over the menu. */\n protected pointerTracker?: PointerFocusTracker<CdkMenuItem>;\n\n /** Whether this menu's menu stack has focus. */\n private _menuStackHasFocus = signal(false);\n\n private _tabIndexSignal = computed(() => {\n const tabindexIfInline = this._menuStackHasFocus() ? -1 : 0;\n return this.isInline ? tabindexIfInline : null;\n });\n\n ngAfterContentInit() {\n if (!this.isInline) {\n this.menuStack.push(this);\n }\n this._setItems();\n this._setKeyManager();\n this._handleFocus();\n this._subscribeToMenuStackHasFocus();\n this._subscribeToMenuOpen();\n this._subscribeToMenuStackClosed();\n this._setUpPointerTracker();\n }\n\n ngOnDestroy() {\n this._focusMonitor.stopMonitoring(this.nativeElement);\n this.keyManager?.destroy();\n this.destroyed.next();\n this.destroyed.complete();\n this.pointerTracker?.destroy();\n }\n\n /**\n * Place focus on the first MenuItem in the menu and set the focus origin.\n * @param focusOrigin The origin input mode of the focus event.\n */\n focusFirstItem(focusOrigin: FocusOrigin = 'program') {\n this.keyManager.setFocusOrigin(focusOrigin);\n this.keyManager.setFirstItemActive();\n }\n\n /**\n * Place focus on the last MenuItem in the menu and set the focus origin.\n * @param focusOrigin The origin input mode of the focus event.\n */\n focusLastItem(focusOrigin: FocusOrigin = 'program') {\n this.keyManager.setFocusOrigin(focusOrigin);\n this.keyManager.setLastItemActive();\n }\n\n /**\n * Sets the active item to the item at the specified index and focuses the newly active item.\n * @param item The index of the item to be set as active, or the CdkMenuItem instance.\n */\n setActiveMenuItem(item: number | CdkMenuItem) {\n this.keyManager?.setActiveItem(item);\n }\n\n /** Gets the tabindex for this menu. */\n _getTabIndex() {\n return this._tabIndexSignal();\n }\n\n /**\n * Close the open menu if the current active item opened the requested MenuStackItem.\n * @param menu The menu requested to be closed.\n * @param options Options to configure the behavior on close.\n * - `focusParentTrigger` Whether to focus the parent trigger after closing the menu.\n */\n protected closeOpenMenu(menu: MenuStackItem, options?: {focusParentTrigger?: boolean}) {\n const {focusParentTrigger} = {...options};\n const keyManager = this.keyManager;\n const trigger = this.triggerItem;\n if (menu === trigger?.getMenuTrigger()?.getMenu()) {\n trigger?.getMenuTrigger()?.close();\n // If the user has moused over a sibling item we want to focus the element under mouse focus\n // not the trigger which previously opened the now closed menu.\n if (focusParentTrigger) {\n if (trigger) {\n keyManager.setActiveItem(trigger);\n } else {\n keyManager.setFirstItemActive();\n }\n }\n }\n }\n\n /** Sets up the subscription that keeps the items list in sync. */\n private _setItems() {\n // Since the items query has `descendants: true`, we need\n // to filter out items belonging to a different menu.\n this._allItems.changes\n .pipe(startWith(this._allItems), takeUntil(this.destroyed))\n .subscribe((items: QueryList<CdkMenuItem>) => {\n this.items.reset(items.filter(item => item._parentMenu === this));\n this.items.notifyOnChanges();\n });\n }\n\n /** Setup the FocusKeyManager with the correct orientation for the menu. */\n private _setKeyManager() {\n this.keyManager = new FocusKeyManager(this.items)\n .withWrap()\n .withTypeAhead()\n .withHomeAndEnd()\n .skipPredicate(() => false);\n\n if (this.orientation === 'horizontal') {\n this.keyManager.withHorizontalOrientation(this.dir?.value || 'ltr');\n } else {\n this.keyManager.withVerticalOrientation();\n }\n }\n\n /**\n * Subscribe to the menu trigger's open events in order to track the trigger which opened the menu\n * and stop tracking it when the menu is closed.\n */\n private _subscribeToMenuOpen() {\n const exitCondition = merge(this.items.changes, this.destroyed);\n this.items.changes\n .pipe(\n startWith(this.items),\n mergeMap((list: QueryList<CdkMenuItem>) =>\n list\n .filter(item => item.hasMenu)\n .map(item => item.getMenuTrigger()!.opened.pipe(mapTo(item), takeUntil(exitCondition))),\n ),\n mergeAll(),\n switchMap((item: CdkMenuItem) => {\n this.triggerItem = item;\n return item.getMenuTrigger()!.closed;\n }),\n takeUntil(this.destroyed),\n )\n .subscribe(() => (this.triggerItem = undefined));\n }\n\n /** Subscribe to the MenuStack close events. */\n private _subscribeToMenuStackClosed() {\n this.menuStack.closed\n .pipe(takeUntil(this.destroyed))\n .subscribe(({item, focusParentTrigger}) => this.closeOpenMenu(item, {focusParentTrigger}));\n }\n\n /** Subscribe to the MenuStack hasFocus events. */\n private _subscribeToMenuStackHasFocus() {\n if (this.isInline) {\n this.menuStack.hasFocus.pipe(takeUntil(this.destroyed)).subscribe(hasFocus => {\n this._menuStackHasFocus.set(hasFocus);\n });\n }\n }\n\n /**\n * Set the PointerFocusTracker and ensure that when mouse focus changes the key manager is updated\n * with the latest menu item under mouse focus.\n */\n private _setUpPointerTracker() {\n if (this.menuAim) {\n this.ngZone.runOutsideAngular(() => {\n this.pointerTracker = new PointerFocusTracker(this._renderer, this.items);\n });\n this.menuAim.initialize(this, this.pointerTracker!);\n }\n }\n\n /** Handles focus landing on the host element of the menu. */\n private _handleFocus() {\n this._focusMonitor\n .monitor(this.nativeElement, false)\n .pipe(takeUntil(this.destroyed))\n .subscribe(origin => {\n // Don't forward focus on mouse interactions, because it can\n // mess with the user's scroll position. See #30130.\n if (origin !== null && origin !== 'mouse') {\n this.focusFirstItem(origin);\n }\n });\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {AfterContentInit, Directive, EventEmitter, inject, OnDestroy, Output} from '@angular/core';\nimport {ESCAPE, hasModifierKey, LEFT_ARROW, RIGHT_ARROW, TAB} from '../keycodes';\nimport {takeUntil} from 'rxjs/operators';\nimport {CdkMenuGroup} from './menu-group';\nimport {CDK_MENU} from './menu-interface';\nimport {FocusNext, PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER} from './menu-stack';\nimport {MENU_TRIGGER} from './menu-trigger-base';\nimport {CdkMenuBase} from './menu-base';\n\n/**\n * Directive which configures the element as a Menu which should contain child elements marked as\n * CdkMenuItem or CdkMenuGroup. Sets the appropriate role and aria-attributes for a menu and\n * contains accessible keyboard and mouse handling logic.\n *\n * It also acts as a RadioGroup for elements marked with role `menuitemradio`.\n */\n@Directive({\n selector: '[cdkMenu]',\n exportAs: 'cdkMenu',\n host: {\n 'role': 'menu',\n 'class': 'cdk-menu',\n '[class.cdk-menu-inline]': 'isInline',\n '(keydown)': '_handleKeyEvent($event)',\n },\n providers: [\n {provide: CdkMenuGroup, useExisting: CdkMenu},\n {provide: CDK_MENU, useExisting: CdkMenu},\n PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER('vertical'),\n ],\n})\nexport class CdkMenu extends CdkMenuBase implements AfterContentInit, OnDestroy {\n private _parentTrigger = inject(MENU_TRIGGER, {optional: true});\n\n /** Event emitted when the menu is closed. */\n @Output() readonly closed: EventEmitter<void> = new EventEmitter();\n\n /** The direction items in the menu flow. */\n override readonly orientation = 'vertical';\n\n /** Whether the menu is displayed inline (i.e. always present vs a conditional popup that the user triggers with a trigger element). */\n override readonly isInline = !this._parentTrigger;\n\n constructor() {\n super();\n this.destroyed.subscribe(this.closed);\n this._parentTrigger?.registerChildMenu(this);\n }\n\n override ngAfterContentInit() {\n super.ngAfterContentInit();\n this._subscribeToMenuStackEmptied();\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n this.closed.complete();\n }\n\n /**\n * Handle keyboard events for the Menu.\n * @param event The keyboard event to be handled.\n */\n _handleKeyEvent(event: KeyboardEvent) {\n const keyManager = this.keyManager;\n switch (event.keyCode) {\n case LEFT_ARROW:\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n keyManager.setFocusOrigin('keyboard');\n keyManager.onKeydown(event);\n }\n break;\n\n case ESCAPE:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n this.menuStack.close(this, {\n focusNextOnEmpty: FocusNext.currentItem,\n focusParentTrigger: true,\n });\n }\n break;\n\n case TAB:\n if (!hasModifierKey(event, 'altKey', 'metaKey', 'ctrlKey')) {\n this.menuStack.closeAll({focusParentTrigger: true});\n }\n break;\n\n default:\n keyManager.onKeydown(event);\n }\n }\n\n /**\n * Set focus the either the current, previous or next item based on the FocusNext event.\n * @param focusNext The element to focus.\n */\n private _toggleMenuFocus(focusNext: FocusNext | undefined) {\n const keyManager = this.keyManager;\n switch (focusNext) {\n case FocusNext.nextItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setNextItemActive();\n break;\n\n case FocusNext.previousItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setPreviousItemActive();\n break;\n\n case FocusNext.currentItem:\n if (keyManager.activeItem) {\n keyManager.setFocusOrigin('keyboard');\n keyManager.setActiveItem(keyManager.activeItem);\n }\n break;\n }\n }\n\n /** Subscribe to the MenuStack emptied events. */\n private _subscribeToMenuStackEmptied() {\n this.menuStack.emptied\n .pipe(takeUntil(this.destroyed))\n .subscribe(event => this._toggleMenuFocus(event));\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {AfterContentInit, Directive} from '@angular/core';\nimport {\n DOWN_ARROW,\n ESCAPE,\n hasModifierKey,\n LEFT_ARROW,\n RIGHT_ARROW,\n TAB,\n UP_ARROW,\n} from '../keycodes';\nimport {takeUntil} from 'rxjs/operators';\nimport {CdkMenuGroup} from './menu-group';\nimport {CDK_MENU} from './menu-interface';\nimport {FocusNext, MENU_STACK, MenuStack} from './menu-stack';\nimport {CdkMenuBase} from './menu-base';\n\n/**\n * Directive applied to an element which configures it as a MenuBar by setting the appropriate\n * role, aria attributes, and accessible keyboard and mouse handling logic. The component that\n * this directive is applied to should contain components marked with CdkMenuItem.\n *\n */\n@Directive({\n selector: '[cdkMenuBar]',\n exportAs: 'cdkMenuBar',\n host: {\n 'role': 'menubar',\n 'class': 'cdk-menu-bar',\n '(keydown)': '_handleKeyEvent($event)',\n },\n providers: [\n {provide: CdkMenuGroup, useExisting: CdkMenuBar},\n {provide: CDK_MENU, useExisting: CdkMenuBar},\n {provide: MENU_STACK, useFactory: () => MenuStack.inline('horizontal')},\n ],\n})\nexport class CdkMenuBar extends CdkMenuBase implements AfterContentInit {\n /** The direction items in the menu flow. */\n override readonly orientation = 'horizontal';\n\n /** Whether the menu is displayed inline (i.e. always present vs a conditional popup that the user triggers with a trigger element). */\n override readonly isInline = true;\n\n override ngAfterContentInit() {\n super.ngAfterContentInit();\n this._subscribeToMenuStackEmptied();\n }\n\n /**\n * Handle keyboard events for the Menu.\n * @param event The keyboard event to be handled.\n */\n _handleKeyEvent(event: KeyboardEvent) {\n const keyManager = this.keyManager;\n switch (event.keyCode) {\n case UP_ARROW:\n case DOWN_ARROW:\n case LEFT_ARROW:\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n const horizontalArrows = event.keyCode === LEFT_ARROW || event.keyCode === RIGHT_ARROW;\n // For a horizontal menu if the left/right keys were clicked, or a vertical menu if the\n // up/down keys were clicked: if the current menu is open, close it then focus and open the\n // next menu.\n if (horizontalArrows) {\n event.preventDefault();\n\n const prevIsOpen = keyManager.activeItem?.isMenuOpen();\n keyManager.activeItem?.getMenuTrigger()?.close();\n\n keyManager.setFocusOrigin('keyboard');\n keyManager.onKeydown(event);\n if (prevIsOpen) {\n keyManager.activeItem?.getMenuTrigger()?.open();\n }\n }\n }\n break;\n\n case ESCAPE:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n keyManager.activeItem?.getMenuTrigger()?.close();\n }\n break;\n\n case TAB:\n if (!hasModifierKey(event, 'altKey', 'metaKey', 'ctrlKey')) {\n keyManager.activeItem?.getMenuTrigger()?.close();\n }\n break;\n\n default:\n keyManager.onKeydown(event);\n }\n }\n\n /**\n * Set focus to either the current, previous or next item based on the FocusNext event, then\n * open the previous or next item.\n * @param focusNext The element to focus.\n */\n private _toggleOpenMenu(focusNext: FocusNext | undefined) {\n const keyManager = this.keyManager;\n switch (focusNext) {\n case FocusNext.nextItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setNextItemActive();\n keyManager.activeItem?.getMenuTrigger()?.open();\n break;\n\n case FocusNext.previousItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setPreviousItemActive();\n keyManager.activeItem?.getMenuTrigger()?.open();\n break;\n\n case FocusNext.currentItem:\n if (keyManager.activeItem) {\n keyManager.setFocusOrigin('keyboard');\n keyManager.setActiveItem(keyManager.activeItem);\n }\n break;\n }\n }\n\n /** Subscribe to the MenuStack emptied events. */\n private _subscribeToMenuStackEmptied() {\n this.menuStack?.emptied\n .pipe(takeUntil(this.destroyed))\n .subscribe(event => this._toggleOpenMenu(event));\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive, Input, booleanAttribute} from '@angular/core';\nimport {CdkMenuItem} from './menu-item';\n\n/** Base class providing checked state for selectable MenuItems. */\n@Directive({\n host: {\n '[attr.aria-checked]': '!!checked',\n '[attr.aria-disabled]': 'disabled || null',\n },\n})\nexport abstract class CdkMenuItemSelectable extends CdkMenuItem {\n /** Whether the element is checked */\n @Input({alias: 'cdkMenuItemChecked', transform: booleanAttribute}) checked: boolean = false;\n\n /** Whether the item should close the menu if triggered by the spacebar. */\n protected override closeOnSpacebarTrigger = false;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive, inject, OnDestroy} from '@angular/core';\nimport {UniqueSelectionDispatcher} from '../collections';\nimport {_IdGenerator} from '../a11y';\nimport {CdkMenuItemSelectable} from './menu-item-selectable';\nimport {CdkMenuItem} from './menu-item';\n\n/**\n * A directive providing behavior for the \"menuitemradio\" ARIA role, which behaves similarly to\n * a conventional radio-button. Any sibling `CdkMenuItemRadio` instances within the same `CdkMenu`\n * or `CdkMenuGroup` comprise a radio group with unique selection enforced.\n */\n@Directive({\n selector: '[cdkMenuItemRadio]',\n exportAs: 'cdkMenuItemRadio',\n host: {\n 'role': 'menuitemradio',\n '[class.cdk-menu-item-radio]': 'true',\n },\n providers: [\n {provide: CdkMenuItemSelectable, useExisting: CdkMenuItemRadio},\n {provide: CdkMenuItem, useExisting: CdkMenuItemSelectable},\n ],\n})\nexport class CdkMenuItemRadio extends CdkMenuItemSelectable implements OnDestroy {\n /** The unique selection dispatcher for this radio's `CdkMenuGroup`. */\n private readonly _selectionDispatcher = inject(UniqueSelectionDispatcher);\n\n /** An ID to identify this radio item to the `UniqueSelectionDispatcher`. */\n private _id = inject(_IdGenerator).getId('cdk-menu-item-radio-');\n\n /** Function to unregister the selection dispatcher */\n private _removeDispatcherListener: () => void;\n\n constructor() {\n super();\n this._registerDispatcherListener();\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n\n this._removeDispatcherListener();\n }\n\n /**\n * Toggles the checked state of the radio-button.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n override trigger(options?: {keepOpen: boolean}) {\n super.trigger(options);\n\n if (!this.disabled) {\n this._selectionDispatcher.notify(this._id, '');\n }\n }\n\n /** Configure the unique selection dispatcher listener in order to toggle the checked state */\n private _registerDispatcherListener() {\n this._removeDispatcherListener = this._selectionDispatcher.listen((id: string) => {\n this.checked = this._id === id;\n });\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive} from '@angular/core';\nimport {CdkMenuItemSelectable} from './menu-item-selectable';\nimport {CdkMenuItem} from './menu-item';\n\n/**\n * A directive providing behavior for the \"menuitemcheckbox\" ARIA role, which behaves similarly to a\n * conventional checkbox.\n */\n@Directive({\n selector: '[cdkMenuItemCheckbox]',\n exportAs: 'cdkMenuItemCheckbox',\n host: {\n 'role': 'menuitemcheckbox',\n '[class.cdk-menu-item-checkbox]': 'true',\n },\n providers: [\n {provide: CdkMenuItemSelectable, useExisting: CdkMenuItemCheckbox},\n {provide: CdkMenuItem, useExisting: CdkMenuItemSelectable},\n ],\n})\nexport class CdkMenuItemCheckbox extends CdkMenuItemSelectable {\n /**\n * Toggle the checked state of the checkbox.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n override trigger(options?: {keepOpen: boolean}) {\n super.trigger(options);\n\n if (!this.disabled) {\n this.checked = !this.checked;\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n booleanAttribute,\n ChangeDetectorRef,\n Directive,\n inject,\n Injector,\n Input,\n OnDestroy,\n} from '@angular/core';\nimport {Directionality} from '../bidi';\nimport {\n createFlexibleConnectedPositionStrategy,\n createOverlayRef,\n FlexibleConnectedPositionStrategy,\n OverlayConfig,\n STANDARD_DROPDOWN_BELOW_POSITIONS,\n} from '../overlay';\nimport {_getEventTarget} from '../platform';\nimport {merge, partition} from 'rxjs';\nimport {skip, takeUntil, skipWhile} from 'rxjs/operators';\nimport {MENU_STACK, MenuStack} from './menu-stack';\nimport {CdkMenuTriggerBase, MENU_TRIGGER, MenuTracker} from './menu-trigger-base';\n\n/** The preferred menu positions for the context menu. */\nconst CONTEXT_MENU_POSITIONS = STANDARD_DROPDOWN_BELOW_POSITIONS.map(position => {\n // In cases where the first menu item in the context menu is a trigger the submenu opens on a\n // hover event. We offset the context menu 2px by default to prevent this from occurring.\n const offsetX = position.overlayX === 'start' ? 2 : -2;\n const offsetY = position.overlayY === 'top' ? 2 : -2;\n return {...position, offsetX, offsetY};\n});\n\n/**\n * @deprecated Will be removed. Use `MenuTracker` instead.\n * @breaking-change 22.0.0\n */\nexport {MenuTracker as ContextMenuTracker};\n\n/** The coordinates where the context menu should open. */\nexport type ContextMenuCoordinates = {x: number; y: number};\n\n/**\n * A directive that opens a menu when a user right-clicks within its host element.\n * It is aware of nested context menus and will trigger only the lowest level non-disabled context menu.\n */\n@Directive({\n selector: '[cdkContextMenuTriggerFor]',\n exportAs: 'cdkContextMenuTriggerFor',\n host: {\n '[attr.data-cdk-menu-stack-id]': 'null',\n '(contextmenu)': '_openOnContextMenu($event)',\n },\n inputs: [\n {name: 'menuTemplateRef', alias: 'cdkContextMenuTriggerFor'},\n {name: 'menuPosition', alias: 'cdkContextMenuPosition'},\n {name: 'menuData', alias: 'cdkContextMenuTriggerData'},\n ],\n outputs: ['opened: cdkContextMenuOpened', 'closed: cdkContextMenuClosed'],\n providers: [\n {provide: MENU_TRIGGER, useExisting: CdkContextMenuTrigger},\n {provide: MENU_STACK, useClass: MenuStack},\n ],\n})\nexport class CdkContextMenuTrigger extends CdkMenuTriggerBase implements OnDestroy {\n private readonly _injector = inject(Injector);\n private readonly _directionality = inject(Directionality, {optional: true});\n\n /** The app's menu tracking registry */\n private readonly _menuTracker = inject(MenuTracker);\n\n private readonly _changeDetectorRef = inject(ChangeDetectorRef);\n\n /** Whether the context menu is disabled. */\n @Input({alias: 'cdkContextMenuDisabled', transform: booleanAttribute}) disabled: boolean = false;\n\n constructor() {\n super();\n this._setMenuStackCloseListener();\n }\n\n /**\n * Open the attached menu at the specified location.\n * @param coordinates where to open the context menu\n */\n open(coordinates: ContextMenuCoordinates) {\n this._open(null, coordinates);\n this._changeDetectorRef.markForCheck();\n }\n\n /** Close the currently opened context menu. */\n close() {\n this.menuStack.closeAll();\n }\n\n /**\n * Open the context menu and closes any previously open menus.\n * @param event the mouse event which opens the context menu.\n */\n _openOnContextMenu(event: MouseEvent) {\n if (!this.disabled) {\n // Prevent the native context menu from opening because we're opening a custom one.\n event.preventDefault();\n\n // Stop event propagation to ensure that only the closest enabled context menu opens.\n // Otherwise, any context menus attached to containing elements would *also* open,\n // resulting in multiple stacked context menus being displayed.\n event.stopPropagation();\n\n this._menuTracker.update(this);\n this._open(event, {x: event.clientX, y: event.clientY});\n\n // A context menu can be triggered via a mouse right click or a keyboard shortcut.\n if (event.button === 2) {\n this.childMenu?.focusFirstItem('mouse');\n } else if (event.button === 0) {\n this.childMenu?.focusFirstItem('keyboard');\n } else {\n this.childMenu?.focusFirstItem('program');\n }\n }\n }\n\n /**\n * Get the configuration object used to create the overlay.\n * @param coordinates the location to place the opened menu\n */\n private _getOverlayConfig(coordinates: ContextMenuCoordinates) {\n return new OverlayConfig({\n positionStrategy: this._getOverlayPositionStrategy(coordinates),\n scrollStrategy: this.menuScrollStrategy(),\n direction: this._directionality || undefined,\n });\n }\n\n /**\n * Get the position strategy for the overlay which specifies where to place the menu.\n * @param coordinates the location to place the opened menu\n */\n private _getOverlayPositionStrategy(\n coordinates: ContextMenuCoordinates,\n ): FlexibleConnectedPositionStrategy {\n return createFlexibleConnectedPositionStrategy(this._injector, coordinates)\n .withLockedPosition()\n .withGrowAfterOpen()\n .withPositions(this.menuPosition ?? CONTEXT_MENU_POSITIONS);\n }\n\n /** Subscribe to the menu stack close events and close this menu when requested. */\n private _setMenuStackCloseListener() {\n this.menuStack.closed.pipe(takeUntil(this.destroyed)).subscribe(({item}) => {\n if (item === this.childMenu && this.isOpen()) {\n this.closed.next();\n this.overlayRef!.detach();\n this.childMenu = undefined;\n this._changeDetectorRef.markForCheck();\n }\n });\n }\n\n /**\n * Subscribe to the overlays outside pointer events stream and handle closing out the stack if a\n * click occurs outside the menus.\n * @param userEvent User-generated event that opened the menu.\n */\n private _subscribeToOutsideClicks(userEvent: MouseEvent | null) {\n if (this.overlayRef) {\n let outsideClicks = this.overlayRef.outsidePointerEvents();\n\n if (userEvent) {\n const [auxClicks, nonAuxClicks] = partition(outsideClicks, ({type}) => type === 'auxclick');\n outsideClicks = merge(\n // Using a mouse, the `contextmenu` event can fire either when pressing the right button\n // or left button + control. Most browsers won't dispatch a `click` event right after\n // a `contextmenu` event triggered by left button + control, but Safari will (see #27832).\n // This closes the menu immediately. To work around it, we check that both the triggering\n // event and the current outside click event both had the control key pressed, and that\n // that this is the first outside click event.\n nonAuxClicks.pipe(\n skipWhile((event, index) => userEvent.ctrlKey && index === 0 && event.ctrlKey),\n ),\n\n // If the menu was triggered by the `contextmenu` event, skip the first `auxclick` event\n // because it fires when the mouse is released on the same click that opened the menu.\n auxClicks.pipe(skip(1)),\n );\n }\n\n outsideClicks.pipe(takeUntil(this.stopOutsideClicksListener)).subscribe(event => {\n if (!this.isElementInsideMenuStack(_getEventTarget(event)!)) {\n this.menuStack.closeAll();\n }\n });\n }\n }\n\n /**\n * Open the attached menu at the specified location.\n * @param userEvent User-generated event that opened the menu\n * @param coordinates where to open the context menu\n */\n private _open(userEvent: MouseEvent | null, coordinates: ContextMenuCoordinates) {\n if (this.disabled) {\n return;\n }\n if (this.isOpen()) {\n // since we're moving this menu we need to close any submenus first otherwise they end up\n // disconnected from this one.\n this.menuStack.closeSubMenuOf(this.childMenu!);\n\n (\n this.overlayRef!.getConfig().positionStrategy as FlexibleConnectedPositionStrategy\n ).setOrigin(coordinates);\n this.overlayRef!.updatePosition();\n } else {\n this.opened.next();\n\n if (this.overlayRef) {\n (\n this.overlayRef.getConfig().positionStrategy as FlexibleConnectedPositionStrategy\n ).setOrigin(coordinates);\n this.overlayRef.updatePosition();\n } else {\n this.overlayRef = createOverlayRef(this._injector, this._getOverlayConfig(coordinates));\n }\n\n this.overlayRef.attach(this.getMenuContentPortal());\n this._subscribeToOutsideClicks(userEvent);\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {NgModule} from '@angular/core';\nimport {OverlayModule} from '../overlay';\nimport {CdkMenu} from './menu';\nimport {CdkMenuBar} from './menu-bar';\nimport {CdkMenuItem} from './menu-item';\nimport {CdkMenuGroup} from './menu-group';\nimport {CdkMenuItemRadio} from './menu-item-radio';\nimport {CdkMenuItemCheckbox} from './menu-item-checkbox';\nimport {CdkMenuTrigger} from './menu-trigger';\nimport {CdkContextMenuTrigger} from './context-menu-trigger';\nimport {CdkTargetMenuAim} from './menu-aim';\n\nconst MENU_DIRECTIVES = [\n CdkMenuBar,\n CdkMenu,\n CdkMenuItem,\n CdkMenuItemRadio,\n CdkMenuItemCheckbox,\n CdkMenuTrigger,\n CdkMenuGroup,\n CdkContextMenuTrigger,\n CdkTargetMenuAim,\n];\n\n/** Module that declares components and directives for the CDK menu. */\n@NgModule({\n imports: [OverlayModule, ...MENU_DIRECTIVES],\n exports: MENU_DIRECTIVES,\n})\nexport class CdkMenuModule {}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWA;;AAEG;MAUU,YAAY,CAAA;4GAAZ,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;gGAAZ,YAAY,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,gBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,MAAA,EAAA,OAAA,EAAA,EAAA,cAAA,EAAA,gBAAA,EAAA,EAAA,SAAA,EAFZ,CAAC,EAAC,OAAO,EAAE,yBAAyB,EAAE,QAAQ,EAAE,yBAAyB,EAAC,CAAC,EAAA,QAAA,EAAA,CAAA,cAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;gGAE3E,YAAY,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mBAAmB;YACnB,cAAc;YACd,YAAY;YACZ,qBAAqB;YACrB,gBAAgB,CAAA,EAAA,CAAA;AAQL,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,aAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,YAHd,aAAa,CAAA,EAAA,CAAA;;gGAGZ,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,GAAG,eAAe,CAAC;AAC5C,oBAAA,OAAO,EAAE,eAAe;AACzB,iBAAA;;;;;"}
1
+ {"version":3,"file":"menu.mjs","sources":["../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-group.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-interface.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-stack.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-trigger-base.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-errors.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-aim.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/event-detection.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-trigger.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-item.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/pointer-focus-tracker.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-base.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-bar.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-item-selectable.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-item-radio.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-item-checkbox.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/context-menu-trigger.ts","../../../../../darwin_arm64-fastbuild-ST-199a4f3c4e20/bin/src/cdk/menu/menu-module.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive} from '@angular/core';\nimport {UniqueSelectionDispatcher} from '../collections';\n\n/**\n * A grouping container for `CdkMenuItemRadio` instances, similar to a `role=\"radiogroup\"` element.\n */\n@Directive({\n selector: '[cdkMenuGroup]',\n exportAs: 'cdkMenuGroup',\n host: {\n 'role': 'group',\n 'class': 'cdk-menu-group',\n },\n providers: [{provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher}],\n})\nexport class CdkMenuGroup {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {InjectionToken} from '@angular/core';\nimport {MenuStackItem} from './menu-stack';\nimport {FocusOrigin} from '../a11y';\n\n/** Injection token used to return classes implementing the Menu interface */\nexport const CDK_MENU = new InjectionToken<Menu>('cdk-menu');\n\n/** Interface which specifies Menu operations and used to break circular dependency issues */\nexport interface Menu extends MenuStackItem {\n /** The id of the menu's host element. */\n id: string;\n\n /** The menu's native DOM host element. */\n nativeElement: HTMLElement;\n\n /** The direction items in the menu flow. */\n readonly orientation: 'horizontal' | 'vertical';\n\n /** Place focus on the first MenuItem in the menu. */\n focusFirstItem(focusOrigin: FocusOrigin): void;\n\n /** Place focus on the last MenuItem in the menu. */\n focusLastItem(focusOrigin: FocusOrigin): void;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {inject, Inject, Injectable, InjectionToken, Optional, SkipSelf} from '@angular/core';\nimport {_IdGenerator} from '../a11y';\nimport {Observable, Subject} from 'rxjs';\nimport {debounceTime, distinctUntilChanged, startWith} from 'rxjs/operators';\n\n/** The relative item in the inline menu to focus after closing all popup menus. */\nexport enum FocusNext {\n nextItem,\n previousItem,\n currentItem,\n}\n\n/** A single item (menu) in the menu stack. */\nexport interface MenuStackItem {\n /** A reference to the menu stack this menu stack item belongs to. */\n menuStack?: MenuStack;\n}\n\n/** Injection token used for an implementation of MenuStack. */\nexport const MENU_STACK = new InjectionToken<MenuStack>('cdk-menu-stack');\n\n/** Provider that provides the parent menu stack, or a new menu stack if there is no parent one. */\nexport const PARENT_OR_NEW_MENU_STACK_PROVIDER = {\n provide: MENU_STACK,\n deps: [[new Optional(), new SkipSelf(), new Inject(MENU_STACK)]],\n useFactory: (parentMenuStack?: MenuStack) => parentMenuStack || new MenuStack(),\n};\n\n/** Provider that provides the parent menu stack, or a new inline menu stack if there is no parent one. */\nexport const PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER = (\n orientation: 'vertical' | 'horizontal',\n) => ({\n provide: MENU_STACK,\n deps: [[new Optional(), new SkipSelf(), new Inject(MENU_STACK)]],\n useFactory: (parentMenuStack?: MenuStack) => parentMenuStack || MenuStack.inline(orientation),\n});\n\n/** Options that can be provided to the close or closeAll methods. */\nexport interface CloseOptions {\n /** The element to focus next if the close operation causes the menu stack to become empty. */\n focusNextOnEmpty?: FocusNext;\n /** Whether to focus the parent trigger after closing the menu. */\n focusParentTrigger?: boolean;\n}\n\n/** Event dispatched when a menu is closed. */\nexport interface MenuStackCloseEvent {\n /** The menu being closed. */\n item: MenuStackItem;\n /** Whether to focus the parent trigger after closing the menu. */\n focusParentTrigger?: boolean;\n}\n\n/**\n * MenuStack allows subscribers to listen for close events (when a MenuStackItem is popped off\n * of the stack) in order to perform closing actions. Upon the MenuStack being empty it emits\n * from the `empty` observable specifying the next focus action which the listener should perform\n * as requested by the closer.\n */\n@Injectable()\nexport class MenuStack {\n /** The ID of this menu stack. */\n readonly id = inject(_IdGenerator).getId('cdk-menu-stack-');\n\n /** All MenuStackItems tracked by this MenuStack. */\n private readonly _elements: MenuStackItem[] = [];\n\n /** Emits the element which was popped off of the stack when requested by a closer. */\n private readonly _close = new Subject<MenuStackCloseEvent>();\n\n /** Emits once the MenuStack has become empty after popping off elements. */\n private readonly _empty = new Subject<FocusNext | undefined>();\n\n /** Emits whether any menu in the menu stack has focus. */\n private readonly _hasFocus = new Subject<boolean>();\n\n /** Observable which emits the MenuStackItem which has been requested to close. */\n readonly closed: Observable<MenuStackCloseEvent> = this._close;\n\n /** Observable which emits whether any menu in the menu stack has focus. */\n readonly hasFocus: Observable<boolean> = this._hasFocus.pipe(\n startWith(false),\n debounceTime(0),\n distinctUntilChanged(),\n );\n\n /**\n * Observable which emits when the MenuStack is empty after popping off the last element. It\n * emits a FocusNext event which specifies the action the closer has requested the listener\n * perform.\n */\n readonly emptied: Observable<FocusNext | undefined> = this._empty;\n\n /**\n * Whether the inline menu associated with this menu stack is vertical or horizontal.\n * `null` indicates there is no inline menu associated with this menu stack.\n */\n private _inlineMenuOrientation: 'vertical' | 'horizontal' | null = null;\n\n /** Creates a menu stack that originates from an inline menu. */\n static inline(orientation: 'vertical' | 'horizontal') {\n const stack = new MenuStack();\n stack._inlineMenuOrientation = orientation;\n return stack;\n }\n\n /**\n * Adds an item to the menu stack.\n * @param menu the MenuStackItem to put on the stack.\n */\n push(menu: MenuStackItem) {\n this._elements.push(menu);\n }\n\n /**\n * Pop items off of the stack up to and including `lastItem` and emit each on the close\n * observable. If the stack is empty or `lastItem` is not on the stack it does nothing.\n * @param lastItem the last item to pop off the stack.\n * @param options Options that configure behavior on close.\n */\n close(lastItem: MenuStackItem, options?: CloseOptions) {\n const {focusNextOnEmpty, focusParentTrigger} = {...options};\n if (this._elements.indexOf(lastItem) >= 0) {\n let poppedElement;\n do {\n poppedElement = this._elements.pop()!;\n this._close.next({item: poppedElement, focusParentTrigger});\n } while (poppedElement !== lastItem);\n\n if (this.isEmpty()) {\n this._empty.next(focusNextOnEmpty);\n }\n }\n }\n\n /**\n * Pop items off of the stack up to but excluding `lastItem` and emit each on the close\n * observable. If the stack is empty or `lastItem` is not on the stack it does nothing.\n * @param lastItem the element which should be left on the stack\n * @return whether or not an item was removed from the stack\n */\n closeSubMenuOf(lastItem: MenuStackItem) {\n let removed = false;\n if (this._elements.indexOf(lastItem) >= 0) {\n removed = this.peek() !== lastItem;\n while (this.peek() !== lastItem) {\n this._close.next({item: this._elements.pop()!});\n }\n }\n return removed;\n }\n\n /**\n * Pop off all MenuStackItems and emit each one on the `close` observable one by one.\n * @param options Options that configure behavior on close.\n */\n closeAll(options?: CloseOptions) {\n const {focusNextOnEmpty, focusParentTrigger} = {...options};\n if (!this.isEmpty()) {\n while (!this.isEmpty()) {\n const menuStackItem = this._elements.pop();\n if (menuStackItem) {\n this._close.next({item: menuStackItem, focusParentTrigger});\n }\n }\n this._empty.next(focusNextOnEmpty);\n }\n }\n\n /** Return true if this stack is empty. */\n isEmpty() {\n return !this._elements.length;\n }\n\n /** Return the length of the stack. */\n length() {\n return this._elements.length;\n }\n\n /** Get the top most element on the stack. */\n peek(): MenuStackItem | undefined {\n return this._elements[this._elements.length - 1];\n }\n\n /** Whether the menu stack is associated with an inline menu. */\n hasInlineMenu() {\n return this._inlineMenuOrientation != null;\n }\n\n /** The orientation of the associated inline menu. */\n inlineMenuOrientation() {\n return this._inlineMenuOrientation;\n }\n\n /** Sets whether the menu stack contains the focused element. */\n setHasFocus(hasFocus: boolean) {\n this._hasFocus.next(hasFocus);\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n Directive,\n EventEmitter,\n inject,\n Injectable,\n InjectionToken,\n Injector,\n OnDestroy,\n TemplateRef,\n ViewContainerRef,\n} from '@angular/core';\nimport {Menu} from './menu-interface';\nimport {MENU_STACK, MenuStack} from './menu-stack';\nimport {\n ConnectedPosition,\n createRepositionScrollStrategy,\n OverlayRef,\n ScrollStrategy,\n} from '../overlay';\nimport {TemplatePortal} from '../portal';\nimport {merge, Subject} from 'rxjs';\n\n/** Injection token used for an implementation of MenuStack. */\nexport const MENU_TRIGGER = new InjectionToken<CdkMenuTriggerBase>('cdk-menu-trigger');\n\n/** Injection token used to configure the behavior of the menu when the page is scrolled. */\nexport const MENU_SCROLL_STRATEGY = new InjectionToken<() => ScrollStrategy>(\n 'cdk-menu-scroll-strategy',\n {\n providedIn: 'root',\n factory: () => {\n const injector = inject(Injector);\n return () => createRepositionScrollStrategy(injector);\n },\n },\n);\n\n/** Tracks the last open menu trigger across the entire application. */\n@Injectable({providedIn: 'root'})\nexport class MenuTracker {\n /** The last open menu trigger. */\n private static _openMenuTrigger?: CdkMenuTriggerBase;\n\n /**\n * Close the previous open menu and set the given one as being open.\n * @param trigger The trigger for the currently open Menu.\n */\n update(trigger: CdkMenuTriggerBase) {\n if (MenuTracker._openMenuTrigger !== trigger) {\n MenuTracker._openMenuTrigger?.close();\n MenuTracker._openMenuTrigger = trigger;\n }\n }\n}\n\n/**\n * Abstract directive that implements shared logic common to all menu triggers.\n * This class can be extended to create custom menu trigger types.\n */\n@Directive({\n host: {\n '[attr.aria-controls]': 'childMenu?.id',\n '[attr.data-cdk-menu-stack-id]': 'menuStack.id',\n },\n})\nexport abstract class CdkMenuTriggerBase implements OnDestroy {\n /** The DI injector for this component. */\n readonly injector = inject(Injector);\n\n /** The view container ref for this component */\n protected readonly viewContainerRef = inject(ViewContainerRef);\n\n /** The menu stack in which this menu resides. */\n protected readonly menuStack: MenuStack = inject(MENU_STACK);\n\n /** Function used to configure the scroll strategy for the menu. */\n protected readonly menuScrollStrategy = inject(MENU_SCROLL_STRATEGY);\n\n /**\n * A list of preferred menu positions to be used when constructing the\n * `FlexibleConnectedPositionStrategy` for this trigger's menu.\n */\n menuPosition: ConnectedPosition[];\n\n /** Emits when the attached menu is requested to open */\n readonly opened: EventEmitter<void> = new EventEmitter();\n\n /** Emits when the attached menu is requested to close */\n readonly closed: EventEmitter<void> = new EventEmitter();\n\n /** Template reference variable to the menu this trigger opens */\n menuTemplateRef: TemplateRef<unknown> | null;\n\n /** Context data to be passed along to the menu template */\n menuData: unknown;\n\n /** Close the opened menu. */\n abstract close(): void;\n\n /** A reference to the overlay which manages the triggered menu */\n protected overlayRef: OverlayRef | null = null;\n\n /** Emits when this trigger is destroyed. */\n protected readonly destroyed: Subject<void> = new Subject();\n\n /** Emits when the outside pointer events listener on the overlay should be stopped. */\n protected readonly stopOutsideClicksListener = merge(this.closed, this.destroyed);\n\n /** The child menu opened by this trigger. */\n protected childMenu?: Menu;\n\n /** The content of the menu panel opened by this trigger. */\n private _menuPortal: TemplatePortal;\n\n /** The injector to use for the child menu opened by this trigger. */\n private _childMenuInjector?: Injector;\n\n ngOnDestroy() {\n this._destroyOverlay();\n\n this.destroyed.next();\n this.destroyed.complete();\n }\n\n /** Whether the attached menu is open. */\n isOpen() {\n return !!this.overlayRef?.hasAttached();\n }\n\n /** Registers a child menu as having been opened by this trigger. */\n registerChildMenu(child: Menu) {\n this.childMenu = child;\n }\n\n /**\n * Get the portal to be attached to the overlay which contains the menu. Allows for the menu\n * content to change dynamically and be reflected in the application.\n */\n protected getMenuContentPortal() {\n const hasMenuContentChanged = this.menuTemplateRef !== this._menuPortal?.templateRef;\n if (this.menuTemplateRef && (!this._menuPortal || hasMenuContentChanged)) {\n this._menuPortal = new TemplatePortal(\n this.menuTemplateRef,\n this.viewContainerRef,\n this.menuData,\n this._getChildMenuInjector(),\n );\n }\n\n return this._menuPortal;\n }\n\n /**\n * Whether the given element is inside the scope of this trigger's menu stack.\n * @param element The element to check.\n * @return Whether the element is inside the scope of this trigger's menu stack.\n */\n protected isElementInsideMenuStack(element: Element) {\n for (let el: Element | null = element; el; el = el?.parentElement ?? null) {\n if (el.getAttribute('data-cdk-menu-stack-id') === this.menuStack.id) {\n return true;\n }\n }\n return false;\n }\n\n /** Destroy and unset the overlay reference it if exists */\n private _destroyOverlay() {\n if (this.overlayRef) {\n this.overlayRef.dispose();\n this.overlayRef = null;\n }\n }\n\n /** Gets the injector to use when creating a child menu. */\n private _getChildMenuInjector() {\n this._childMenuInjector =\n this._childMenuInjector ||\n Injector.create({\n providers: [\n {provide: MENU_TRIGGER, useValue: this},\n {provide: MENU_STACK, useValue: this.menuStack},\n ],\n parent: this.injector,\n });\n return this._childMenuInjector;\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\n/**\n * Throws an exception when an instance of the PointerFocusTracker is not provided.\n * @docs-private\n */\nexport function throwMissingPointerFocusTracker() {\n throw Error('expected an instance of PointerFocusTracker to be provided');\n}\n\n/**\n * Throws an exception when a reference to the parent menu is not provided.\n * @docs-private\n */\nexport function throwMissingMenuReference() {\n throw Error('expected a reference to the parent menu');\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n Directive,\n inject,\n Injectable,\n InjectionToken,\n NgZone,\n OnDestroy,\n RendererFactory2,\n} from '@angular/core';\nimport {Subject} from 'rxjs';\nimport {FocusableElement, PointerFocusTracker} from './pointer-focus-tracker';\nimport {Menu} from './menu-interface';\nimport {throwMissingMenuReference, throwMissingPointerFocusTracker} from './menu-errors';\n\n/**\n * MenuAim is responsible for determining if a sibling menuitem's menu should be closed when a\n * Toggler item is hovered into. It is up to the hovered in item to call the MenuAim service in\n * order to determine if it may perform its close actions.\n */\nexport interface MenuAim {\n /**\n * Set the Menu and its PointerFocusTracker.\n * @param menu The menu that this menu aim service controls.\n * @param pointerTracker The `PointerFocusTracker` for the given menu.\n */\n initialize(menu: Menu, pointerTracker: PointerFocusTracker<FocusableElement & Toggler>): void;\n\n /**\n * Calls the `doToggle` callback when it is deemed that the user is not moving towards\n * the submenu.\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n toggle(doToggle: () => void): void;\n}\n\n/** Injection token used for an implementation of MenuAim. */\nexport const MENU_AIM = new InjectionToken<MenuAim>('cdk-menu-aim');\n\n/** Capture every nth mouse move event. */\nconst MOUSE_MOVE_SAMPLE_FREQUENCY = 3;\n\n/** The number of mouse move events to track. */\nconst NUM_POINTS = 5;\n\n/**\n * How long to wait before closing a sibling menu if a user stops short of the submenu they were\n * predicted to go into.\n */\nconst CLOSE_DELAY = 300;\n\n/** An element which when hovered over may open or close a menu. */\nexport interface Toggler {\n /** Gets the open menu, or undefined if no menu is open. */\n getMenu(): Menu | undefined;\n}\n\n/** Calculate the slope between point a and b. */\nfunction getSlope(a: Point, b: Point) {\n return (b.y - a.y) / (b.x - a.x);\n}\n\n/** Calculate the y intercept for the given point and slope. */\nfunction getYIntercept(point: Point, slope: number) {\n return point.y - slope * point.x;\n}\n\n/** Represents a coordinate of mouse travel. */\ntype Point = {x: number; y: number};\n\n/**\n * Whether the given mouse trajectory line defined by the slope and y intercept falls within the\n * submenu as defined by `submenuPoints`\n * @param submenuPoints the submenu DOMRect points.\n * @param m the slope of the trajectory line.\n * @param b the y intercept of the trajectory line.\n * @return true if any point on the line falls within the submenu.\n */\nfunction isWithinSubmenu(submenuPoints: DOMRect, m: number, b: number) {\n const {left, right, top, bottom} = submenuPoints;\n\n // Check for intersection with each edge of the submenu (left, right, top, bottom)\n // by fixing one coordinate to that edge's coordinate (either x or y) and checking if the\n // other coordinate is within bounds.\n return (\n (m * left + b >= top && m * left + b <= bottom) ||\n (m * right + b >= top && m * right + b <= bottom) ||\n ((top - b) / m >= left && (top - b) / m <= right) ||\n ((bottom - b) / m >= left && (bottom - b) / m <= right)\n );\n}\n\n/**\n * TargetMenuAim predicts if a user is moving into a submenu. It calculates the\n * trajectory of the user's mouse movement in the current menu to determine if the\n * mouse is moving towards an open submenu.\n *\n * The determination is made by calculating the slope of the users last NUM_POINTS moves where each\n * pair of points determines if the trajectory line points into the submenu. It uses consensus\n * approach by checking if at least NUM_POINTS / 2 pairs determine that the user is moving towards\n * to submenu.\n */\n@Injectable()\nexport class TargetMenuAim implements MenuAim, OnDestroy {\n private readonly _ngZone = inject(NgZone);\n private readonly _renderer = inject(RendererFactory2).createRenderer(null, null);\n private _cleanupMousemove: (() => void) | undefined;\n\n /** The last NUM_POINTS mouse move events. */\n private readonly _points: Point[] = [];\n\n /** Reference to the root menu in which we are tracking mouse moves. */\n private _menu: Menu;\n\n /** Reference to the root menu's mouse manager. */\n private _pointerTracker: PointerFocusTracker<Toggler & FocusableElement>;\n\n /** The id associated with the current timeout call waiting to resolve. */\n private _timeoutId: number | null;\n\n /** Emits when this service is destroyed. */\n private readonly _destroyed: Subject<void> = new Subject();\n\n ngOnDestroy() {\n this._cleanupMousemove?.();\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n /**\n * Set the Menu and its PointerFocusTracker.\n * @param menu The menu that this menu aim service controls.\n * @param pointerTracker The `PointerFocusTracker` for the given menu.\n */\n initialize(menu: Menu, pointerTracker: PointerFocusTracker<FocusableElement & Toggler>) {\n this._menu = menu;\n this._pointerTracker = pointerTracker;\n this._subscribeToMouseMoves();\n }\n\n /**\n * Calls the `doToggle` callback when it is deemed that the user is not moving towards\n * the submenu.\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n toggle(doToggle: () => void) {\n // If the menu is horizontal the sub-menus open below and there is no risk of premature\n // closing of any sub-menus therefore we automatically resolve the callback.\n if (this._menu.orientation === 'horizontal') {\n doToggle();\n }\n\n this._checkConfigured();\n\n const siblingItemIsWaiting = !!this._timeoutId;\n const hasPoints = this._points.length > 1;\n\n if (hasPoints && !siblingItemIsWaiting) {\n if (this._isMovingToSubmenu()) {\n this._startTimeout(doToggle);\n } else {\n doToggle();\n }\n } else if (!siblingItemIsWaiting) {\n doToggle();\n }\n }\n\n /**\n * Start the delayed toggle handler if one isn't running already.\n *\n * The delayed toggle handler executes the `doToggle` callback after some period of time iff the\n * users mouse is on an item in the current menu.\n *\n * @param doToggle the function called when the user is not moving towards the submenu.\n */\n private _startTimeout(doToggle: () => void) {\n // If the users mouse is moving towards a submenu we don't want to immediately resolve.\n // Wait for some period of time before determining if the previous menu should close in\n // cases where the user may have moved towards the submenu but stopped on a sibling menu\n // item intentionally.\n const timeoutId = setTimeout(() => {\n // Resolve if the user is currently moused over some element in the root menu\n if (this._pointerTracker!.activeElement && timeoutId === this._timeoutId) {\n doToggle();\n }\n this._timeoutId = null;\n }, CLOSE_DELAY) as any as number;\n\n this._timeoutId = timeoutId;\n }\n\n /** Whether the user is heading towards the open submenu. */\n private _isMovingToSubmenu() {\n const submenuPoints = this._getSubmenuBounds();\n if (!submenuPoints) {\n return false;\n }\n\n let numMoving = 0;\n const currPoint = this._points[this._points.length - 1];\n // start from the second last point and calculate the slope between each point and the last\n // point.\n for (let i = this._points.length - 2; i >= 0; i--) {\n const previous = this._points[i];\n const slope = getSlope(currPoint, previous);\n if (isWithinSubmenu(submenuPoints, slope, getYIntercept(currPoint, slope))) {\n numMoving++;\n }\n }\n return numMoving >= Math.floor(NUM_POINTS / 2);\n }\n\n /** Get the bounding DOMRect for the open submenu. */\n private _getSubmenuBounds(): DOMRect | undefined {\n return this._pointerTracker?.previousElement?.getMenu()?.nativeElement.getBoundingClientRect();\n }\n\n /**\n * Check if a reference to the PointerFocusTracker and menu element is provided.\n * @throws an error if neither reference is provided.\n */\n private _checkConfigured() {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!this._pointerTracker) {\n throwMissingPointerFocusTracker();\n }\n if (!this._menu) {\n throwMissingMenuReference();\n }\n }\n }\n\n /** Subscribe to the root menus mouse move events and update the tracked mouse points. */\n private _subscribeToMouseMoves() {\n this._cleanupMousemove?.();\n\n this._cleanupMousemove = this._ngZone.runOutsideAngular(() => {\n let eventIndex = 0;\n\n return this._renderer.listen(this._menu.nativeElement, 'mousemove', (event: MouseEvent) => {\n if (eventIndex % MOUSE_MOVE_SAMPLE_FREQUENCY === 0) {\n this._points.push({x: event.clientX, y: event.clientY});\n if (this._points.length > NUM_POINTS) {\n this._points.shift();\n }\n }\n eventIndex++;\n });\n });\n }\n}\n\n/**\n * CdkTargetMenuAim is a provider for the TargetMenuAim service. It can be added to an\n * element with either the `cdkMenu` or `cdkMenuBar` directive and child menu items.\n */\n@Directive({\n selector: '[cdkTargetMenuAim]',\n exportAs: 'cdkTargetMenuAim',\n providers: [{provide: MENU_AIM, useClass: TargetMenuAim}],\n})\nexport class CdkTargetMenuAim {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ElementRef} from '@angular/core';\nimport {ENTER, SPACE} from '../keycodes';\n\n/** Checks whether a keyboard event will trigger a native `click` event on an element. */\nexport function eventDispatchesNativeClick(\n elementRef: ElementRef<HTMLElement>,\n event: KeyboardEvent,\n): boolean {\n // Synthetic events won't trigger clicks.\n if (!event.isTrusted) {\n return false;\n }\n\n const el = elementRef.nativeElement;\n const keyCode = event.keyCode;\n\n // Buttons trigger clicks both on space and enter events.\n if (el.nodeName === 'BUTTON' && !(el as HTMLButtonElement).disabled) {\n return keyCode === ENTER || keyCode === SPACE;\n }\n\n // Links only trigger clicks on enter.\n if (el.nodeName === 'A') {\n return keyCode === ENTER;\n }\n\n // Any other elements won't dispatch clicks from keyboard events.\n return false;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n ChangeDetectorRef,\n Directive,\n ElementRef,\n inject,\n Injector,\n NgZone,\n OnChanges,\n OnDestroy,\n Renderer2,\n SimpleChanges,\n} from '@angular/core';\nimport {InputModalityDetector} from '../a11y';\nimport {Directionality} from '../bidi';\nimport {\n ConnectedPosition,\n createFlexibleConnectedPositionStrategy,\n createOverlayRef,\n FlexibleConnectedPositionStrategy,\n OverlayConfig,\n STANDARD_DROPDOWN_ADJACENT_POSITIONS,\n STANDARD_DROPDOWN_BELOW_POSITIONS,\n} from '../overlay';\nimport {\n DOWN_ARROW,\n ENTER,\n hasModifierKey,\n LEFT_ARROW,\n RIGHT_ARROW,\n SPACE,\n UP_ARROW,\n} from '../keycodes';\nimport {_getEventTarget} from '../platform';\nimport {takeUntil} from 'rxjs/operators';\nimport {CDK_MENU, Menu} from './menu-interface';\nimport {PARENT_OR_NEW_MENU_STACK_PROVIDER} from './menu-stack';\nimport {MENU_AIM} from './menu-aim';\nimport {CdkMenuTriggerBase, MENU_TRIGGER, MenuTracker} from './menu-trigger-base';\nimport {eventDispatchesNativeClick} from './event-detection';\n\n/**\n * A directive that turns its host element into a trigger for a popup menu.\n * It can be combined with cdkMenuItem to create sub-menus. If the element is in a top level\n * MenuBar it will open the menu on click, or if a sibling is already opened it will open on hover.\n * If it is inside of a Menu it will open the attached Submenu on hover regardless of its sibling\n * state.\n */\n@Directive({\n selector: '[cdkMenuTriggerFor]',\n exportAs: 'cdkMenuTriggerFor',\n host: {\n 'class': 'cdk-menu-trigger',\n '[attr.aria-haspopup]': 'menuTemplateRef ? \"menu\" : null',\n '[attr.aria-expanded]': 'menuTemplateRef == null ? null : isOpen()',\n '(focusin)': '_setHasFocus(true)',\n '(focusout)': '_setHasFocus(false)',\n '(keydown)': '_toggleOnKeydown($event)',\n '(click)': '_handleClick()',\n },\n inputs: [\n {name: 'menuTemplateRef', alias: 'cdkMenuTriggerFor'},\n {name: 'menuPosition', alias: 'cdkMenuPosition'},\n {name: 'menuData', alias: 'cdkMenuTriggerData'},\n ],\n outputs: ['opened: cdkMenuOpened', 'closed: cdkMenuClosed'],\n providers: [\n {provide: MENU_TRIGGER, useExisting: CdkMenuTrigger},\n PARENT_OR_NEW_MENU_STACK_PROVIDER,\n ],\n})\nexport class CdkMenuTrigger extends CdkMenuTriggerBase implements OnChanges, OnDestroy {\n private readonly _elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n private readonly _ngZone = inject(NgZone);\n private readonly _changeDetectorRef = inject(ChangeDetectorRef);\n private readonly _inputModalityDetector = inject(InputModalityDetector);\n private readonly _directionality = inject(Directionality, {optional: true});\n private readonly _renderer = inject(Renderer2);\n private readonly _injector = inject(Injector);\n private _cleanupMouseenter: () => void;\n\n /** The app's menu tracking registry */\n private readonly _menuTracker = inject(MenuTracker);\n\n /** The parent menu this trigger belongs to. */\n private readonly _parentMenu = inject(CDK_MENU, {optional: true});\n\n /** The menu aim service used by this menu. */\n private readonly _menuAim = inject(MENU_AIM, {optional: true});\n\n constructor() {\n super();\n this._setRole();\n this._registerCloseHandler();\n this._subscribeToMenuStackClosed();\n this._subscribeToMouseEnter();\n this._subscribeToMenuStackHasFocus();\n this._setType();\n }\n\n /** Toggle the attached menu. */\n toggle() {\n this.isOpen() ? this.close() : this.open();\n }\n\n /** Open the attached menu. */\n open() {\n if (!this._parentMenu) {\n this._menuTracker.update(this);\n }\n if (!this.isOpen() && this.menuTemplateRef != null) {\n this.opened.next();\n\n this.overlayRef =\n this.overlayRef || createOverlayRef(this._injector, this._getOverlayConfig());\n this.overlayRef.attach(this.getMenuContentPortal());\n this._changeDetectorRef.markForCheck();\n this._subscribeToOutsideClicks();\n }\n }\n\n /** Close the opened menu. */\n close() {\n if (this.isOpen()) {\n this.closed.next();\n\n this.overlayRef!.detach();\n this._changeDetectorRef.markForCheck();\n }\n this._closeSiblingTriggers();\n }\n\n /**\n * Get a reference to the rendered Menu if the Menu is open and rendered in the DOM.\n */\n getMenu(): Menu | undefined {\n return this.childMenu;\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (changes['menuPosition'] && this.overlayRef) {\n this.overlayRef.updatePositionStrategy(this._getOverlayPositionStrategy());\n }\n }\n\n override ngOnDestroy(): void {\n this._cleanupMouseenter();\n super.ngOnDestroy();\n }\n\n /**\n * Handles keyboard events for the menu item.\n * @param event The keyboard event to handle\n */\n _toggleOnKeydown(event: KeyboardEvent) {\n const isParentVertical = this._parentMenu?.orientation === 'vertical';\n switch (event.keyCode) {\n case SPACE:\n case ENTER:\n // Skip events that will trigger clicks so the handler doesn't get triggered twice.\n if (!hasModifierKey(event) && !eventDispatchesNativeClick(this._elementRef, event)) {\n this.toggle();\n this.childMenu?.focusFirstItem('keyboard');\n }\n break;\n\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && isParentVertical && this._directionality?.value !== 'rtl') {\n event.preventDefault();\n this.open();\n this.childMenu?.focusFirstItem('keyboard');\n }\n }\n break;\n\n case LEFT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && isParentVertical && this._directionality?.value === 'rtl') {\n event.preventDefault();\n this.open();\n this.childMenu?.focusFirstItem('keyboard');\n }\n }\n break;\n\n case DOWN_ARROW:\n case UP_ARROW:\n if (!hasModifierKey(event)) {\n if (!isParentVertical) {\n event.preventDefault();\n this.open();\n event.keyCode === DOWN_ARROW\n ? this.childMenu?.focusFirstItem('keyboard')\n : this.childMenu?.focusLastItem('keyboard');\n }\n }\n break;\n }\n }\n\n /** Handles clicks on the menu trigger. */\n _handleClick() {\n this.toggle();\n this.childMenu?.focusFirstItem('mouse');\n }\n\n /**\n * Sets whether the trigger's menu stack has focus.\n * @param hasFocus Whether the menu stack has focus.\n */\n _setHasFocus(hasFocus: boolean) {\n if (!this._parentMenu) {\n this.menuStack.setHasFocus(hasFocus);\n }\n }\n\n /**\n * Subscribe to the mouseenter events and close any sibling menu items if this element is moused\n * into.\n */\n private _subscribeToMouseEnter() {\n this._cleanupMouseenter = this._ngZone.runOutsideAngular(() => {\n return this._renderer.listen(this._elementRef.nativeElement, 'mouseenter', () => {\n if (\n // Skip fake `mouseenter` events dispatched by touch devices.\n this._inputModalityDetector.mostRecentModality !== 'touch' &&\n !this.menuStack.isEmpty() &&\n !this.isOpen()\n ) {\n // Closes any sibling menu items and opens the menu associated with this trigger.\n const toggleMenus = () =>\n this._ngZone.run(() => {\n this._closeSiblingTriggers();\n this.open();\n });\n\n if (this._menuAim) {\n this._menuAim.toggle(toggleMenus);\n } else {\n toggleMenus();\n }\n }\n });\n });\n }\n\n /** Close out any sibling menu trigger menus. */\n private _closeSiblingTriggers() {\n if (this._parentMenu) {\n // If nothing was removed from the stack and the last element is not the parent item\n // that means that the parent menu is a menu bar since we don't put the menu bar on the\n // stack\n const isParentMenuBar =\n !this.menuStack.closeSubMenuOf(this._parentMenu) &&\n this.menuStack.peek() !== this._parentMenu;\n\n if (isParentMenuBar) {\n this.menuStack.closeAll();\n }\n } else {\n this.menuStack.closeAll();\n }\n }\n\n /** Get the configuration object used to create the overlay. */\n private _getOverlayConfig() {\n return new OverlayConfig({\n positionStrategy: this._getOverlayPositionStrategy(),\n scrollStrategy: this.menuScrollStrategy(),\n direction: this._directionality || undefined,\n });\n }\n\n /** Build the position strategy for the overlay which specifies where to place the menu. */\n private _getOverlayPositionStrategy(): FlexibleConnectedPositionStrategy {\n return createFlexibleConnectedPositionStrategy(this._injector, this._elementRef)\n .withLockedPosition()\n .withFlexibleDimensions(false)\n .withPositions(this._getOverlayPositions());\n }\n\n /** Get the preferred positions for the opened menu relative to the menu item. */\n private _getOverlayPositions(): ConnectedPosition[] {\n return (\n this.menuPosition ??\n (!this._parentMenu || this._parentMenu.orientation === 'horizontal'\n ? STANDARD_DROPDOWN_BELOW_POSITIONS\n : STANDARD_DROPDOWN_ADJACENT_POSITIONS)\n );\n }\n\n /**\n * Subscribe to the MenuStack close events if this is a standalone trigger and close out the menu\n * this triggers when requested.\n */\n private _registerCloseHandler() {\n if (!this._parentMenu) {\n this.menuStack.closed.pipe(takeUntil(this.destroyed)).subscribe(({item}) => {\n if (item === this.childMenu) {\n this.close();\n }\n });\n }\n }\n\n /**\n * Subscribe to the overlays outside pointer events stream and handle closing out the stack if a\n * click occurs outside the menus.\n */\n private _subscribeToOutsideClicks() {\n if (this.overlayRef) {\n this.overlayRef\n .outsidePointerEvents()\n .pipe(takeUntil(this.stopOutsideClicksListener))\n .subscribe(event => {\n const target = _getEventTarget(event) as Element;\n const element = this._elementRef.nativeElement;\n\n if (target !== element && !element.contains(target)) {\n if (!this.isElementInsideMenuStack(target)) {\n this.menuStack.closeAll();\n } else {\n this._closeSiblingTriggers();\n }\n }\n });\n }\n }\n\n /** Subscribe to the MenuStack hasFocus events. */\n private _subscribeToMenuStackHasFocus() {\n if (!this._parentMenu) {\n this.menuStack.hasFocus.pipe(takeUntil(this.destroyed)).subscribe(hasFocus => {\n if (!hasFocus) {\n this.menuStack.closeAll();\n }\n });\n }\n }\n\n /** Subscribe to the MenuStack closed events. */\n private _subscribeToMenuStackClosed() {\n if (!this._parentMenu) {\n this.menuStack.closed.subscribe(({focusParentTrigger}) => {\n if (focusParentTrigger && !this.menuStack.length()) {\n this._elementRef.nativeElement.focus();\n }\n });\n }\n }\n\n /** Sets the role attribute for this trigger if needed. */\n private _setRole() {\n // If this trigger is part of another menu, the cdkMenuItem directive will handle setting the\n // role, otherwise this is a standalone trigger, and we should ensure it has role=\"button\".\n if (!this._parentMenu) {\n this._elementRef.nativeElement.setAttribute('role', 'button');\n }\n }\n\n /** Sets thte `type` attribute of the trigger. */\n private _setType() {\n const element = this._elementRef.nativeElement;\n\n if (element.nodeName === 'BUTTON' && !element.getAttribute('type')) {\n // Prevents form submissions.\n element.setAttribute('type', 'button');\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n booleanAttribute,\n Directive,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n NgZone,\n OnDestroy,\n Output,\n Renderer2,\n} from '@angular/core';\nimport {FocusableOption, InputModalityDetector} from '../a11y';\nimport {ENTER, hasModifierKey, LEFT_ARROW, RIGHT_ARROW, SPACE} from '../keycodes';\nimport {Directionality} from '../bidi';\nimport {Subject} from 'rxjs';\nimport {CdkMenuTrigger} from './menu-trigger';\nimport {CDK_MENU, Menu} from './menu-interface';\nimport {FocusNext, MENU_STACK} from './menu-stack';\nimport {FocusableElement} from './pointer-focus-tracker';\nimport {MENU_AIM, Toggler} from './menu-aim';\nimport {eventDispatchesNativeClick} from './event-detection';\n\n/**\n * Directive which provides the ability for an element to be focused and navigated to using the\n * keyboard when residing in a CdkMenu, CdkMenuBar, or CdkMenuGroup. It performs user defined\n * behavior when clicked.\n */\n@Directive({\n selector: '[cdkMenuItem]',\n exportAs: 'cdkMenuItem',\n host: {\n 'role': 'menuitem',\n 'class': 'cdk-menu-item',\n '[class.cdk-menu-item-disabled]': 'disabled',\n '[tabindex]': '_tabindex',\n '[attr.aria-disabled]': 'disabled || null',\n '(blur)': '_resetTabIndex()',\n '(focus)': '_setTabIndex()',\n '(click)': '_handleClick($event)',\n '(keydown)': '_onKeydown($event)',\n },\n})\nexport class CdkMenuItem implements FocusableOption, FocusableElement, Toggler, OnDestroy {\n protected readonly _dir = inject(Directionality, {optional: true});\n readonly _elementRef: ElementRef<HTMLElement> = inject(ElementRef);\n protected _ngZone = inject(NgZone);\n private readonly _inputModalityDetector = inject(InputModalityDetector);\n private readonly _renderer = inject(Renderer2);\n private _cleanupMouseEnter: (() => void) | undefined;\n\n /** The menu aim service used by this menu. */\n private readonly _menuAim = inject(MENU_AIM, {optional: true});\n\n /** The stack of menus this menu belongs to. */\n private readonly _menuStack = inject(MENU_STACK);\n\n /** The parent menu in which this menuitem resides. */\n readonly _parentMenu = inject(CDK_MENU, {optional: true});\n\n /** Reference to the CdkMenuItemTrigger directive if one is added to the same element */\n private readonly _menuTrigger = inject(CdkMenuTrigger, {optional: true, self: true});\n\n /** Whether the CdkMenuItem is disabled - defaults to false */\n @Input({alias: 'cdkMenuItemDisabled', transform: booleanAttribute}) disabled: boolean = false;\n\n /**\n * The text used to locate this item during menu typeahead. If not specified,\n * the `textContent` of the item will be used.\n */\n @Input('cdkMenuitemTypeaheadLabel') typeaheadLabel: string | null;\n\n /**\n * If this MenuItem is a regular MenuItem, outputs when it is triggered by a keyboard or mouse\n * event.\n */\n @Output('cdkMenuItemTriggered') readonly triggered: EventEmitter<void> = new EventEmitter();\n\n /** Whether the menu item opens a menu. */\n get hasMenu() {\n return this._menuTrigger?.menuTemplateRef != null;\n }\n\n /**\n * The tabindex for this menu item managed internally and used for implementing roving a\n * tab index.\n */\n _tabindex: 0 | -1 = -1;\n\n /** Whether the item should close the menu if triggered by the spacebar. */\n protected closeOnSpacebarTrigger = true;\n\n /** Emits when the menu item is destroyed. */\n protected readonly destroyed = new Subject<void>();\n\n constructor() {\n this._setupMouseEnter();\n this._setType();\n\n if (this._isStandaloneItem()) {\n this._tabindex = 0;\n }\n }\n\n ngOnDestroy() {\n this._cleanupMouseEnter?.();\n this.destroyed.next();\n this.destroyed.complete();\n }\n\n /** Place focus on the element. */\n focus() {\n this._elementRef.nativeElement.focus();\n }\n\n /**\n * If the menu item is not disabled and the element does not have a menu trigger attached, emit\n * on the cdkMenuItemTriggered emitter and close all open menus.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n trigger(options?: {keepOpen: boolean}) {\n const {keepOpen} = {...options};\n if (!this.disabled && !this.hasMenu) {\n this.triggered.next();\n if (!keepOpen) {\n this._menuStack.closeAll({focusParentTrigger: true});\n }\n }\n }\n\n /** Return true if this MenuItem has an attached menu and it is open. */\n isMenuOpen() {\n return !!this._menuTrigger?.isOpen();\n }\n\n /**\n * Get a reference to the rendered Menu if the Menu is open and it is visible in the DOM.\n * @return the menu if it is open, otherwise undefined.\n */\n getMenu(): Menu | undefined {\n return this._menuTrigger?.getMenu();\n }\n\n /** Get the CdkMenuTrigger associated with this element. */\n getMenuTrigger(): CdkMenuTrigger | null {\n return this._menuTrigger;\n }\n\n /** Get the label for this element which is required by the FocusableOption interface. */\n getLabel(): string {\n return this.typeaheadLabel || this._elementRef.nativeElement.textContent?.trim() || '';\n }\n\n /** Reset the tabindex to -1. */\n _resetTabIndex() {\n if (!this._isStandaloneItem()) {\n this._tabindex = -1;\n }\n }\n\n /**\n * Set the tab index to 0 if not disabled and it's a focus event, or a mouse enter if this element\n * is not in a menu bar.\n */\n _setTabIndex(event?: MouseEvent) {\n if (this.disabled) {\n return;\n }\n\n // don't set the tabindex if there are no open sibling or parent menus\n if (!event || !this._menuStack.isEmpty()) {\n this._tabindex = 0;\n }\n }\n\n /** Handles click events on the item. */\n protected _handleClick(event: MouseEvent) {\n if (this.disabled) {\n event.preventDefault();\n event.stopPropagation();\n } else {\n this.trigger();\n }\n }\n\n /**\n * Handles keyboard events for the menu item, specifically either triggering the user defined\n * callback or opening/closing the current menu based on whether the left or right arrow key was\n * pressed.\n * @param event the keyboard event to handle\n */\n _onKeydown(event: KeyboardEvent) {\n switch (event.keyCode) {\n case SPACE:\n case ENTER:\n // Skip events that will trigger clicks so the handler doesn't get triggered twice.\n if (!hasModifierKey(event) && !eventDispatchesNativeClick(this._elementRef, event)) {\n const nodeName = this._elementRef.nativeElement.nodeName;\n\n // Avoid repeat events on non-native elements (see #30250). Note that we don't do this\n // on the native elements so we don't interfere with their behavior (see #26296).\n if (nodeName !== 'A' && nodeName !== 'BUTTON') {\n event.preventDefault();\n }\n\n this.trigger({keepOpen: event.keyCode === SPACE && !this.closeOnSpacebarTrigger});\n }\n break;\n\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && this._isParentVertical()) {\n if (this._dir?.value !== 'rtl') {\n this._forwardArrowPressed(event);\n } else {\n this._backArrowPressed(event);\n }\n }\n }\n break;\n\n case LEFT_ARROW:\n if (!hasModifierKey(event)) {\n if (this._parentMenu && this._isParentVertical()) {\n if (this._dir?.value !== 'rtl') {\n this._backArrowPressed(event);\n } else {\n this._forwardArrowPressed(event);\n }\n }\n }\n break;\n }\n }\n\n /** Whether this menu item is standalone or within a menu or menu bar. */\n private _isStandaloneItem() {\n return !this._parentMenu;\n }\n\n /**\n * Handles the user pressing the back arrow key.\n * @param event The keyboard event.\n */\n private _backArrowPressed(event: KeyboardEvent) {\n const parentMenu = this._parentMenu!;\n if (this._menuStack.hasInlineMenu() || this._menuStack.length() > 1) {\n event.preventDefault();\n this._menuStack.close(parentMenu, {\n focusNextOnEmpty:\n this._menuStack.inlineMenuOrientation() === 'horizontal'\n ? FocusNext.previousItem\n : FocusNext.currentItem,\n focusParentTrigger: true,\n });\n }\n }\n\n /**\n * Handles the user pressing the forward arrow key.\n * @param event The keyboard event.\n */\n private _forwardArrowPressed(event: KeyboardEvent) {\n if (!this.hasMenu && this._menuStack.inlineMenuOrientation() === 'horizontal') {\n event.preventDefault();\n this._menuStack.closeAll({\n focusNextOnEmpty: FocusNext.nextItem,\n focusParentTrigger: true,\n });\n }\n }\n\n /**\n * Subscribe to the mouseenter events and close any sibling menu items if this element is moused\n * into.\n */\n private _setupMouseEnter() {\n if (!this._isStandaloneItem()) {\n const closeOpenSiblings = () =>\n this._ngZone.run(() => this._menuStack.closeSubMenuOf(this._parentMenu!));\n\n this._cleanupMouseEnter = this._ngZone.runOutsideAngular(() =>\n this._renderer.listen(this._elementRef.nativeElement, 'mouseenter', () => {\n // Skip fake `mouseenter` events dispatched by touch devices.\n if (\n this._inputModalityDetector.mostRecentModality !== 'touch' &&\n !this._menuStack.isEmpty() &&\n !this.hasMenu\n ) {\n if (this._menuAim) {\n this._menuAim.toggle(closeOpenSiblings);\n } else {\n closeOpenSiblings();\n }\n }\n }),\n );\n }\n }\n\n /**\n * Return true if the enclosing parent menu is configured in a horizontal orientation, false\n * otherwise or if no parent.\n */\n private _isParentVertical() {\n return this._parentMenu?.orientation === 'vertical';\n }\n\n /** Sets the `type` attribute of the menu item. */\n private _setType() {\n const element = this._elementRef.nativeElement;\n\n if (element.nodeName === 'BUTTON' && !element.getAttribute('type')) {\n // Prevent form submissions.\n element.setAttribute('type', 'button');\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ElementRef, QueryList, Renderer2} from '@angular/core';\nimport {Observable, Subject, Subscription} from 'rxjs';\nimport {startWith} from 'rxjs/operators';\n\n/** Item to track for mouse focus events. */\nexport interface FocusableElement {\n /** A reference to the element to be tracked. */\n _elementRef: ElementRef<HTMLElement>;\n}\n\n/**\n * PointerFocusTracker keeps track of the currently active item under mouse focus. It also has\n * observables which emit when the users mouse enters and leaves a tracked element.\n */\nexport class PointerFocusTracker<T extends FocusableElement> {\n private _eventCleanups: (() => void)[] | undefined;\n private _itemsSubscription: Subscription | undefined;\n\n /** Emits when an element is moused into. */\n readonly entered: Observable<T> = new Subject<T>();\n\n /** Emits when an element is moused out. */\n readonly exited: Observable<T> = new Subject<T>();\n\n /** The element currently under mouse focus. */\n activeElement?: T;\n\n /** The element previously under mouse focus. */\n previousElement?: T;\n\n constructor(\n private _renderer: Renderer2,\n private readonly _items: QueryList<T>,\n ) {\n this._bindEvents();\n this.entered.subscribe(element => (this.activeElement = element));\n this.exited.subscribe(() => {\n this.previousElement = this.activeElement;\n this.activeElement = undefined;\n });\n }\n\n /** Stop the managers listeners. */\n destroy() {\n this._cleanupEvents();\n this._itemsSubscription?.unsubscribe();\n }\n\n /** Binds the enter/exit events on all the items. */\n private _bindEvents() {\n // TODO(crisbeto): this can probably be simplified by binding a single event on a parent node.\n this._itemsSubscription = this._items.changes.pipe(startWith(this._items)).subscribe(() => {\n this._cleanupEvents();\n this._eventCleanups = [];\n this._items.forEach(item => {\n const element = item._elementRef.nativeElement;\n this._eventCleanups!.push(\n this._renderer.listen(element, 'mouseenter', () => {\n (this.entered as Subject<T>).next(item);\n }),\n this._renderer.listen(element, 'mouseout', () => {\n (this.exited as Subject<T>).next(item);\n }),\n );\n });\n });\n }\n\n /** Cleans up the currently-bound events. */\n private _cleanupEvents() {\n this._eventCleanups?.forEach(cleanup => cleanup());\n this._eventCleanups = undefined;\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {_IdGenerator, FocusKeyManager, FocusMonitor, FocusOrigin} from '../a11y';\nimport {Directionality} from '../bidi';\nimport {\n AfterContentInit,\n ContentChildren,\n Directive,\n ElementRef,\n Input,\n NgZone,\n OnDestroy,\n QueryList,\n Renderer2,\n computed,\n inject,\n signal,\n} from '@angular/core';\nimport {Subject, merge} from 'rxjs';\nimport {mapTo, mergeAll, mergeMap, startWith, switchMap, takeUntil} from 'rxjs/operators';\nimport {MENU_AIM} from './menu-aim';\nimport {CdkMenuGroup} from './menu-group';\nimport {Menu} from './menu-interface';\nimport {CdkMenuItem} from './menu-item';\nimport {MENU_STACK, MenuStack, MenuStackItem} from './menu-stack';\nimport {PointerFocusTracker} from './pointer-focus-tracker';\n\n/**\n * Abstract directive that implements shared logic common to all menus.\n * This class can be extended to create custom menu types.\n */\n@Directive({\n host: {\n 'role': 'menu',\n 'class': '', // reset the css class added by the super-class\n '[tabindex]': '_getTabIndex()',\n '[id]': 'id',\n '[attr.aria-orientation]': 'orientation',\n '[attr.data-cdk-menu-stack-id]': 'menuStack.id',\n '(focusin)': 'menuStack.setHasFocus(true)',\n '(focusout)': 'menuStack.setHasFocus(false)',\n },\n})\nexport abstract class CdkMenuBase\n extends CdkMenuGroup\n implements Menu, AfterContentInit, OnDestroy\n{\n private _focusMonitor = inject(FocusMonitor);\n protected ngZone = inject(NgZone);\n private _renderer = inject(Renderer2);\n\n /** The menu's native DOM host element. */\n readonly nativeElement: HTMLElement = inject(ElementRef).nativeElement;\n\n /** The stack of menus this menu belongs to. */\n readonly menuStack: MenuStack = inject(MENU_STACK);\n\n /** The menu aim service used by this menu. */\n protected readonly menuAim = inject(MENU_AIM, {optional: true, self: true});\n\n /** The directionality (text direction) of the current page. */\n protected readonly dir = inject(Directionality, {optional: true});\n\n /** All items inside the menu, including ones that belong to other menus. */\n @ContentChildren(CdkMenuItem, {descendants: true})\n protected _allItems: QueryList<CdkMenuItem>;\n\n /** The id of the menu's host element. */\n @Input() id: string = inject(_IdGenerator).getId('cdk-menu-');\n\n /** All child MenuItem elements belonging to this Menu. */\n readonly items: QueryList<CdkMenuItem> = new QueryList();\n\n /** The direction items in the menu flow. */\n orientation: 'horizontal' | 'vertical' = 'vertical';\n\n /**\n * Whether the menu is displayed inline (i.e. always present vs a conditional popup that the\n * user triggers with a trigger element).\n */\n isInline = false;\n\n /** Handles keyboard events for the menu. */\n protected keyManager: FocusKeyManager<CdkMenuItem>;\n\n /** Emits when the MenuBar is destroyed. */\n protected readonly destroyed: Subject<void> = new Subject();\n\n /** The Menu Item which triggered the open submenu. */\n protected triggerItem?: CdkMenuItem;\n\n /** Tracks the users mouse movements over the menu. */\n protected pointerTracker?: PointerFocusTracker<CdkMenuItem>;\n\n /** Whether this menu's menu stack has focus. */\n private _menuStackHasFocus = signal(false);\n\n private _tabIndexSignal = computed(() => {\n const tabindexIfInline = this._menuStackHasFocus() ? -1 : 0;\n return this.isInline ? tabindexIfInline : null;\n });\n\n ngAfterContentInit() {\n if (!this.isInline) {\n this.menuStack.push(this);\n }\n this._setItems();\n this._setKeyManager();\n this._handleFocus();\n this._subscribeToMenuStackHasFocus();\n this._subscribeToMenuOpen();\n this._subscribeToMenuStackClosed();\n this._setUpPointerTracker();\n }\n\n ngOnDestroy() {\n this._focusMonitor.stopMonitoring(this.nativeElement);\n this.keyManager?.destroy();\n this.destroyed.next();\n this.destroyed.complete();\n this.pointerTracker?.destroy();\n }\n\n /**\n * Place focus on the first MenuItem in the menu and set the focus origin.\n * @param focusOrigin The origin input mode of the focus event.\n */\n focusFirstItem(focusOrigin: FocusOrigin = 'program') {\n this.keyManager.setFocusOrigin(focusOrigin);\n this.keyManager.setFirstItemActive();\n }\n\n /**\n * Place focus on the last MenuItem in the menu and set the focus origin.\n * @param focusOrigin The origin input mode of the focus event.\n */\n focusLastItem(focusOrigin: FocusOrigin = 'program') {\n this.keyManager.setFocusOrigin(focusOrigin);\n this.keyManager.setLastItemActive();\n }\n\n /**\n * Sets the active item to the item at the specified index and focuses the newly active item.\n * @param item The index of the item to be set as active, or the CdkMenuItem instance.\n */\n setActiveMenuItem(item: number | CdkMenuItem) {\n this.keyManager?.setActiveItem(item);\n }\n\n /** Gets the tabindex for this menu. */\n _getTabIndex() {\n return this._tabIndexSignal();\n }\n\n /**\n * Close the open menu if the current active item opened the requested MenuStackItem.\n * @param menu The menu requested to be closed.\n * @param options Options to configure the behavior on close.\n * - `focusParentTrigger` Whether to focus the parent trigger after closing the menu.\n */\n protected closeOpenMenu(menu: MenuStackItem, options?: {focusParentTrigger?: boolean}) {\n const {focusParentTrigger} = {...options};\n const keyManager = this.keyManager;\n const trigger = this.triggerItem;\n if (menu === trigger?.getMenuTrigger()?.getMenu()) {\n trigger?.getMenuTrigger()?.close();\n // If the user has moused over a sibling item we want to focus the element under mouse focus\n // not the trigger which previously opened the now closed menu.\n if (focusParentTrigger) {\n if (trigger) {\n keyManager.setActiveItem(trigger);\n } else {\n keyManager.setFirstItemActive();\n }\n }\n }\n }\n\n /** Sets up the subscription that keeps the items list in sync. */\n private _setItems() {\n // Since the items query has `descendants: true`, we need\n // to filter out items belonging to a different menu.\n this._allItems.changes\n .pipe(startWith(this._allItems), takeUntil(this.destroyed))\n .subscribe((items: QueryList<CdkMenuItem>) => {\n this.items.reset(items.filter(item => item._parentMenu === this));\n this.items.notifyOnChanges();\n });\n }\n\n /** Setup the FocusKeyManager with the correct orientation for the menu. */\n private _setKeyManager() {\n this.keyManager = new FocusKeyManager(this.items)\n .withWrap()\n .withTypeAhead()\n .withHomeAndEnd()\n .skipPredicate(() => false);\n\n if (this.orientation === 'horizontal') {\n this.keyManager.withHorizontalOrientation(this.dir?.value || 'ltr');\n } else {\n this.keyManager.withVerticalOrientation();\n }\n }\n\n /**\n * Subscribe to the menu trigger's open events in order to track the trigger which opened the menu\n * and stop tracking it when the menu is closed.\n */\n private _subscribeToMenuOpen() {\n const exitCondition = merge(this.items.changes, this.destroyed);\n this.items.changes\n .pipe(\n startWith(this.items),\n mergeMap((list: QueryList<CdkMenuItem>) =>\n list\n .filter(item => item.hasMenu)\n .map(item => item.getMenuTrigger()!.opened.pipe(mapTo(item), takeUntil(exitCondition))),\n ),\n mergeAll(),\n switchMap((item: CdkMenuItem) => {\n this.triggerItem = item;\n return item.getMenuTrigger()!.closed;\n }),\n takeUntil(this.destroyed),\n )\n .subscribe(() => (this.triggerItem = undefined));\n }\n\n /** Subscribe to the MenuStack close events. */\n private _subscribeToMenuStackClosed() {\n this.menuStack.closed\n .pipe(takeUntil(this.destroyed))\n .subscribe(({item, focusParentTrigger}) => this.closeOpenMenu(item, {focusParentTrigger}));\n }\n\n /** Subscribe to the MenuStack hasFocus events. */\n private _subscribeToMenuStackHasFocus() {\n if (this.isInline) {\n this.menuStack.hasFocus.pipe(takeUntil(this.destroyed)).subscribe(hasFocus => {\n this._menuStackHasFocus.set(hasFocus);\n });\n }\n }\n\n /**\n * Set the PointerFocusTracker and ensure that when mouse focus changes the key manager is updated\n * with the latest menu item under mouse focus.\n */\n private _setUpPointerTracker() {\n if (this.menuAim) {\n this.ngZone.runOutsideAngular(() => {\n this.pointerTracker = new PointerFocusTracker(this._renderer, this.items);\n });\n this.menuAim.initialize(this, this.pointerTracker!);\n }\n }\n\n /** Handles focus landing on the host element of the menu. */\n private _handleFocus() {\n this._focusMonitor\n .monitor(this.nativeElement, false)\n .pipe(takeUntil(this.destroyed))\n .subscribe(origin => {\n // Don't forward focus on mouse interactions, because it can\n // mess with the user's scroll position. See #30130.\n if (origin !== null && origin !== 'mouse') {\n this.focusFirstItem(origin);\n }\n });\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {AfterContentInit, Directive, EventEmitter, inject, OnDestroy, Output} from '@angular/core';\nimport {ESCAPE, hasModifierKey, LEFT_ARROW, RIGHT_ARROW, TAB} from '../keycodes';\nimport {takeUntil} from 'rxjs/operators';\nimport {CdkMenuGroup} from './menu-group';\nimport {CDK_MENU} from './menu-interface';\nimport {FocusNext, PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER} from './menu-stack';\nimport {MENU_TRIGGER} from './menu-trigger-base';\nimport {CdkMenuBase} from './menu-base';\n\n/**\n * Directive which configures the element as a Menu which should contain child elements marked as\n * CdkMenuItem or CdkMenuGroup. Sets the appropriate role and aria-attributes for a menu and\n * contains accessible keyboard and mouse handling logic.\n *\n * It also acts as a RadioGroup for elements marked with role `menuitemradio`.\n */\n@Directive({\n selector: '[cdkMenu]',\n exportAs: 'cdkMenu',\n host: {\n 'role': 'menu',\n 'class': 'cdk-menu',\n '[class.cdk-menu-inline]': 'isInline',\n '(keydown)': '_handleKeyEvent($event)',\n },\n providers: [\n {provide: CdkMenuGroup, useExisting: CdkMenu},\n {provide: CDK_MENU, useExisting: CdkMenu},\n PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER('vertical'),\n ],\n})\nexport class CdkMenu extends CdkMenuBase implements AfterContentInit, OnDestroy {\n private _parentTrigger = inject(MENU_TRIGGER, {optional: true});\n\n /** Event emitted when the menu is closed. */\n @Output() readonly closed: EventEmitter<void> = new EventEmitter();\n\n /** The direction items in the menu flow. */\n override readonly orientation = 'vertical';\n\n /** Whether the menu is displayed inline (i.e. always present vs a conditional popup that the user triggers with a trigger element). */\n override readonly isInline = !this._parentTrigger;\n\n constructor() {\n super();\n this.destroyed.subscribe(this.closed);\n this._parentTrigger?.registerChildMenu(this);\n }\n\n override ngAfterContentInit() {\n super.ngAfterContentInit();\n this._subscribeToMenuStackEmptied();\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n this.closed.complete();\n }\n\n /**\n * Handle keyboard events for the Menu.\n * @param event The keyboard event to be handled.\n */\n _handleKeyEvent(event: KeyboardEvent) {\n const keyManager = this.keyManager;\n switch (event.keyCode) {\n case LEFT_ARROW:\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n keyManager.setFocusOrigin('keyboard');\n keyManager.onKeydown(event);\n }\n break;\n\n case ESCAPE:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n this.menuStack.close(this, {\n focusNextOnEmpty: FocusNext.currentItem,\n focusParentTrigger: true,\n });\n }\n break;\n\n case TAB:\n if (!hasModifierKey(event, 'altKey', 'metaKey', 'ctrlKey')) {\n this.menuStack.closeAll({focusParentTrigger: true});\n }\n break;\n\n default:\n keyManager.onKeydown(event);\n }\n }\n\n /**\n * Set focus the either the current, previous or next item based on the FocusNext event.\n * @param focusNext The element to focus.\n */\n private _toggleMenuFocus(focusNext: FocusNext | undefined) {\n const keyManager = this.keyManager;\n switch (focusNext) {\n case FocusNext.nextItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setNextItemActive();\n break;\n\n case FocusNext.previousItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setPreviousItemActive();\n break;\n\n case FocusNext.currentItem:\n if (keyManager.activeItem) {\n keyManager.setFocusOrigin('keyboard');\n keyManager.setActiveItem(keyManager.activeItem);\n }\n break;\n }\n }\n\n /** Subscribe to the MenuStack emptied events. */\n private _subscribeToMenuStackEmptied() {\n this.menuStack.emptied\n .pipe(takeUntil(this.destroyed))\n .subscribe(event => this._toggleMenuFocus(event));\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {AfterContentInit, Directive} from '@angular/core';\nimport {\n DOWN_ARROW,\n ESCAPE,\n hasModifierKey,\n LEFT_ARROW,\n RIGHT_ARROW,\n TAB,\n UP_ARROW,\n} from '../keycodes';\nimport {takeUntil} from 'rxjs/operators';\nimport {CdkMenuGroup} from './menu-group';\nimport {CDK_MENU} from './menu-interface';\nimport {FocusNext, MENU_STACK, MenuStack} from './menu-stack';\nimport {CdkMenuBase} from './menu-base';\n\n/**\n * Directive applied to an element which configures it as a MenuBar by setting the appropriate\n * role, aria attributes, and accessible keyboard and mouse handling logic. The component that\n * this directive is applied to should contain components marked with CdkMenuItem.\n *\n */\n@Directive({\n selector: '[cdkMenuBar]',\n exportAs: 'cdkMenuBar',\n host: {\n 'role': 'menubar',\n 'class': 'cdk-menu-bar',\n '(keydown)': '_handleKeyEvent($event)',\n },\n providers: [\n {provide: CdkMenuGroup, useExisting: CdkMenuBar},\n {provide: CDK_MENU, useExisting: CdkMenuBar},\n {provide: MENU_STACK, useFactory: () => MenuStack.inline('horizontal')},\n ],\n})\nexport class CdkMenuBar extends CdkMenuBase implements AfterContentInit {\n /** The direction items in the menu flow. */\n override readonly orientation = 'horizontal';\n\n /** Whether the menu is displayed inline (i.e. always present vs a conditional popup that the user triggers with a trigger element). */\n override readonly isInline = true;\n\n override ngAfterContentInit() {\n super.ngAfterContentInit();\n this._subscribeToMenuStackEmptied();\n }\n\n /**\n * Handle keyboard events for the Menu.\n * @param event The keyboard event to be handled.\n */\n _handleKeyEvent(event: KeyboardEvent) {\n const keyManager = this.keyManager;\n switch (event.keyCode) {\n case UP_ARROW:\n case DOWN_ARROW:\n case LEFT_ARROW:\n case RIGHT_ARROW:\n if (!hasModifierKey(event)) {\n const horizontalArrows = event.keyCode === LEFT_ARROW || event.keyCode === RIGHT_ARROW;\n // For a horizontal menu if the left/right keys were clicked, or a vertical menu if the\n // up/down keys were clicked: if the current menu is open, close it then focus and open the\n // next menu.\n if (horizontalArrows) {\n event.preventDefault();\n\n const prevIsOpen = keyManager.activeItem?.isMenuOpen();\n keyManager.activeItem?.getMenuTrigger()?.close();\n\n keyManager.setFocusOrigin('keyboard');\n keyManager.onKeydown(event);\n if (prevIsOpen) {\n keyManager.activeItem?.getMenuTrigger()?.open();\n }\n }\n }\n break;\n\n case ESCAPE:\n if (!hasModifierKey(event)) {\n event.preventDefault();\n keyManager.activeItem?.getMenuTrigger()?.close();\n }\n break;\n\n case TAB:\n if (!hasModifierKey(event, 'altKey', 'metaKey', 'ctrlKey')) {\n keyManager.activeItem?.getMenuTrigger()?.close();\n }\n break;\n\n default:\n keyManager.onKeydown(event);\n }\n }\n\n /**\n * Set focus to either the current, previous or next item based on the FocusNext event, then\n * open the previous or next item.\n * @param focusNext The element to focus.\n */\n private _toggleOpenMenu(focusNext: FocusNext | undefined) {\n const keyManager = this.keyManager;\n switch (focusNext) {\n case FocusNext.nextItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setNextItemActive();\n keyManager.activeItem?.getMenuTrigger()?.open();\n break;\n\n case FocusNext.previousItem:\n keyManager.setFocusOrigin('keyboard');\n keyManager.setPreviousItemActive();\n keyManager.activeItem?.getMenuTrigger()?.open();\n break;\n\n case FocusNext.currentItem:\n if (keyManager.activeItem) {\n keyManager.setFocusOrigin('keyboard');\n keyManager.setActiveItem(keyManager.activeItem);\n }\n break;\n }\n }\n\n /** Subscribe to the MenuStack emptied events. */\n private _subscribeToMenuStackEmptied() {\n this.menuStack?.emptied\n .pipe(takeUntil(this.destroyed))\n .subscribe(event => this._toggleOpenMenu(event));\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive, Input, booleanAttribute} from '@angular/core';\nimport {CdkMenuItem} from './menu-item';\n\n/** Base class providing checked state for selectable MenuItems. */\n@Directive({\n host: {\n '[attr.aria-checked]': '!!checked',\n '[attr.aria-disabled]': 'disabled || null',\n },\n})\nexport abstract class CdkMenuItemSelectable extends CdkMenuItem {\n /** Whether the element is checked */\n @Input({alias: 'cdkMenuItemChecked', transform: booleanAttribute}) checked: boolean = false;\n\n /** Whether the item should close the menu if triggered by the spacebar. */\n protected override closeOnSpacebarTrigger = false;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive, inject, OnDestroy} from '@angular/core';\nimport {UniqueSelectionDispatcher} from '../collections';\nimport {_IdGenerator} from '../a11y';\nimport {CdkMenuItemSelectable} from './menu-item-selectable';\nimport {CdkMenuItem} from './menu-item';\n\n/**\n * A directive providing behavior for the \"menuitemradio\" ARIA role, which behaves similarly to\n * a conventional radio-button. Any sibling `CdkMenuItemRadio` instances within the same `CdkMenu`\n * or `CdkMenuGroup` comprise a radio group with unique selection enforced.\n */\n@Directive({\n selector: '[cdkMenuItemRadio]',\n exportAs: 'cdkMenuItemRadio',\n host: {\n 'role': 'menuitemradio',\n '[class.cdk-menu-item-radio]': 'true',\n },\n providers: [\n {provide: CdkMenuItemSelectable, useExisting: CdkMenuItemRadio},\n {provide: CdkMenuItem, useExisting: CdkMenuItemSelectable},\n ],\n})\nexport class CdkMenuItemRadio extends CdkMenuItemSelectable implements OnDestroy {\n /** The unique selection dispatcher for this radio's `CdkMenuGroup`. */\n private readonly _selectionDispatcher = inject(UniqueSelectionDispatcher);\n\n /** An ID to identify this radio item to the `UniqueSelectionDispatcher`. */\n private _id = inject(_IdGenerator).getId('cdk-menu-item-radio-');\n\n /** Function to unregister the selection dispatcher */\n private _removeDispatcherListener: () => void;\n\n constructor() {\n super();\n this._registerDispatcherListener();\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n\n this._removeDispatcherListener();\n }\n\n /**\n * Toggles the checked state of the radio-button.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n override trigger(options?: {keepOpen: boolean}) {\n super.trigger(options);\n\n if (!this.disabled) {\n this._selectionDispatcher.notify(this._id, '');\n }\n }\n\n /** Configure the unique selection dispatcher listener in order to toggle the checked state */\n private _registerDispatcherListener() {\n this._removeDispatcherListener = this._selectionDispatcher.listen((id: string) => {\n this.checked = this._id === id;\n });\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Directive} from '@angular/core';\nimport {CdkMenuItemSelectable} from './menu-item-selectable';\nimport {CdkMenuItem} from './menu-item';\n\n/**\n * A directive providing behavior for the \"menuitemcheckbox\" ARIA role, which behaves similarly to a\n * conventional checkbox.\n */\n@Directive({\n selector: '[cdkMenuItemCheckbox]',\n exportAs: 'cdkMenuItemCheckbox',\n host: {\n 'role': 'menuitemcheckbox',\n '[class.cdk-menu-item-checkbox]': 'true',\n },\n providers: [\n {provide: CdkMenuItemSelectable, useExisting: CdkMenuItemCheckbox},\n {provide: CdkMenuItem, useExisting: CdkMenuItemSelectable},\n ],\n})\nexport class CdkMenuItemCheckbox extends CdkMenuItemSelectable {\n /**\n * Toggle the checked state of the checkbox.\n * @param options Options the configure how the item is triggered\n * - keepOpen: specifies that the menu should be kept open after triggering the item.\n */\n override trigger(options?: {keepOpen: boolean}) {\n super.trigger(options);\n\n if (!this.disabled) {\n this.checked = !this.checked;\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n booleanAttribute,\n ChangeDetectorRef,\n Directive,\n inject,\n Injector,\n Input,\n OnDestroy,\n} from '@angular/core';\nimport {Directionality} from '../bidi';\nimport {\n createFlexibleConnectedPositionStrategy,\n createOverlayRef,\n FlexibleConnectedPositionStrategy,\n OverlayConfig,\n STANDARD_DROPDOWN_BELOW_POSITIONS,\n} from '../overlay';\nimport {_getEventTarget} from '../platform';\nimport {merge, partition} from 'rxjs';\nimport {skip, takeUntil, skipWhile} from 'rxjs/operators';\nimport {MENU_STACK, MenuStack} from './menu-stack';\nimport {CdkMenuTriggerBase, MENU_TRIGGER, MenuTracker} from './menu-trigger-base';\n\n/** The preferred menu positions for the context menu. */\nconst CONTEXT_MENU_POSITIONS = STANDARD_DROPDOWN_BELOW_POSITIONS.map(position => {\n // In cases where the first menu item in the context menu is a trigger the submenu opens on a\n // hover event. We offset the context menu 2px by default to prevent this from occurring.\n const offsetX = position.overlayX === 'start' ? 2 : -2;\n const offsetY = position.overlayY === 'top' ? 2 : -2;\n return {...position, offsetX, offsetY};\n});\n\n/**\n * @deprecated Will be removed. Use `MenuTracker` instead.\n * @breaking-change 22.0.0\n */\nexport {MenuTracker as ContextMenuTracker};\n\n/** The coordinates where the context menu should open. */\nexport type ContextMenuCoordinates = {x: number; y: number};\n\n/**\n * A directive that opens a menu when a user right-clicks within its host element.\n * It is aware of nested context menus and will trigger only the lowest level non-disabled context menu.\n */\n@Directive({\n selector: '[cdkContextMenuTriggerFor]',\n exportAs: 'cdkContextMenuTriggerFor',\n host: {\n '[attr.data-cdk-menu-stack-id]': 'null',\n '(contextmenu)': '_openOnContextMenu($event)',\n },\n inputs: [\n {name: 'menuTemplateRef', alias: 'cdkContextMenuTriggerFor'},\n {name: 'menuPosition', alias: 'cdkContextMenuPosition'},\n {name: 'menuData', alias: 'cdkContextMenuTriggerData'},\n ],\n outputs: ['opened: cdkContextMenuOpened', 'closed: cdkContextMenuClosed'],\n providers: [\n {provide: MENU_TRIGGER, useExisting: CdkContextMenuTrigger},\n {provide: MENU_STACK, useClass: MenuStack},\n ],\n})\nexport class CdkContextMenuTrigger extends CdkMenuTriggerBase implements OnDestroy {\n private readonly _injector = inject(Injector);\n private readonly _directionality = inject(Directionality, {optional: true});\n\n /** The app's menu tracking registry */\n private readonly _menuTracker = inject(MenuTracker);\n\n private readonly _changeDetectorRef = inject(ChangeDetectorRef);\n\n /** Whether the context menu is disabled. */\n @Input({alias: 'cdkContextMenuDisabled', transform: booleanAttribute}) disabled: boolean = false;\n\n constructor() {\n super();\n this._setMenuStackCloseListener();\n }\n\n /**\n * Open the attached menu at the specified location.\n * @param coordinates where to open the context menu\n */\n open(coordinates: ContextMenuCoordinates) {\n this._open(null, coordinates);\n this._changeDetectorRef.markForCheck();\n }\n\n /** Close the currently opened context menu. */\n close() {\n this.menuStack.closeAll();\n }\n\n /**\n * Open the context menu and closes any previously open menus.\n * @param event the mouse event which opens the context menu.\n */\n _openOnContextMenu(event: MouseEvent) {\n if (!this.disabled) {\n // Prevent the native context menu from opening because we're opening a custom one.\n event.preventDefault();\n\n // Stop event propagation to ensure that only the closest enabled context menu opens.\n // Otherwise, any context menus attached to containing elements would *also* open,\n // resulting in multiple stacked context menus being displayed.\n event.stopPropagation();\n\n this._menuTracker.update(this);\n this._open(event, {x: event.clientX, y: event.clientY});\n\n // A context menu can be triggered via a mouse right click or a keyboard shortcut.\n if (event.button === 2) {\n this.childMenu?.focusFirstItem('mouse');\n } else if (event.button === 0) {\n this.childMenu?.focusFirstItem('keyboard');\n } else {\n this.childMenu?.focusFirstItem('program');\n }\n }\n }\n\n /**\n * Get the configuration object used to create the overlay.\n * @param coordinates the location to place the opened menu\n */\n private _getOverlayConfig(coordinates: ContextMenuCoordinates) {\n return new OverlayConfig({\n positionStrategy: this._getOverlayPositionStrategy(coordinates),\n scrollStrategy: this.menuScrollStrategy(),\n direction: this._directionality || undefined,\n });\n }\n\n /**\n * Get the position strategy for the overlay which specifies where to place the menu.\n * @param coordinates the location to place the opened menu\n */\n private _getOverlayPositionStrategy(\n coordinates: ContextMenuCoordinates,\n ): FlexibleConnectedPositionStrategy {\n return createFlexibleConnectedPositionStrategy(this._injector, coordinates)\n .withLockedPosition()\n .withGrowAfterOpen()\n .withPositions(this.menuPosition ?? CONTEXT_MENU_POSITIONS);\n }\n\n /** Subscribe to the menu stack close events and close this menu when requested. */\n private _setMenuStackCloseListener() {\n this.menuStack.closed.pipe(takeUntil(this.destroyed)).subscribe(({item}) => {\n if (item === this.childMenu && this.isOpen()) {\n this.closed.next();\n this.overlayRef!.detach();\n this.childMenu = undefined;\n this._changeDetectorRef.markForCheck();\n }\n });\n }\n\n /**\n * Subscribe to the overlays outside pointer events stream and handle closing out the stack if a\n * click occurs outside the menus.\n * @param userEvent User-generated event that opened the menu.\n */\n private _subscribeToOutsideClicks(userEvent: MouseEvent | null) {\n if (this.overlayRef) {\n let outsideClicks = this.overlayRef.outsidePointerEvents();\n\n if (userEvent) {\n const [auxClicks, nonAuxClicks] = partition(outsideClicks, ({type}) => type === 'auxclick');\n outsideClicks = merge(\n // Using a mouse, the `contextmenu` event can fire either when pressing the right button\n // or left button + control. Most browsers won't dispatch a `click` event right after\n // a `contextmenu` event triggered by left button + control, but Safari will (see #27832).\n // This closes the menu immediately. To work around it, we check that both the triggering\n // event and the current outside click event both had the control key pressed, and that\n // that this is the first outside click event.\n nonAuxClicks.pipe(\n skipWhile((event, index) => userEvent.ctrlKey && index === 0 && event.ctrlKey),\n ),\n\n // If the menu was triggered by the `contextmenu` event, skip the first `auxclick` event\n // because it fires when the mouse is released on the same click that opened the menu.\n auxClicks.pipe(skip(1)),\n );\n }\n\n outsideClicks.pipe(takeUntil(this.stopOutsideClicksListener)).subscribe(event => {\n if (!this.isElementInsideMenuStack(_getEventTarget(event)!)) {\n this.menuStack.closeAll();\n }\n });\n }\n }\n\n /**\n * Open the attached menu at the specified location.\n * @param userEvent User-generated event that opened the menu\n * @param coordinates where to open the context menu\n */\n private _open(userEvent: MouseEvent | null, coordinates: ContextMenuCoordinates) {\n if (this.disabled) {\n return;\n }\n if (this.isOpen()) {\n // since we're moving this menu we need to close any submenus first otherwise they end up\n // disconnected from this one.\n this.menuStack.closeSubMenuOf(this.childMenu!);\n\n (\n this.overlayRef!.getConfig().positionStrategy as FlexibleConnectedPositionStrategy\n ).setOrigin(coordinates);\n this.overlayRef!.updatePosition();\n } else {\n this.opened.next();\n\n if (this.overlayRef) {\n (\n this.overlayRef.getConfig().positionStrategy as FlexibleConnectedPositionStrategy\n ).setOrigin(coordinates);\n this.overlayRef.updatePosition();\n } else {\n this.overlayRef = createOverlayRef(this._injector, this._getOverlayConfig(coordinates));\n }\n\n this.overlayRef.attach(this.getMenuContentPortal());\n this._subscribeToOutsideClicks(userEvent);\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {NgModule} from '@angular/core';\nimport {OverlayModule} from '../overlay';\nimport {CdkMenu} from './menu';\nimport {CdkMenuBar} from './menu-bar';\nimport {CdkMenuItem} from './menu-item';\nimport {CdkMenuGroup} from './menu-group';\nimport {CdkMenuItemRadio} from './menu-item-radio';\nimport {CdkMenuItemCheckbox} from './menu-item-checkbox';\nimport {CdkMenuTrigger} from './menu-trigger';\nimport {CdkContextMenuTrigger} from './context-menu-trigger';\nimport {CdkTargetMenuAim} from './menu-aim';\n\nconst MENU_DIRECTIVES = [\n CdkMenuBar,\n CdkMenu,\n CdkMenuItem,\n CdkMenuItemRadio,\n CdkMenuItemCheckbox,\n CdkMenuTrigger,\n CdkMenuGroup,\n CdkContextMenuTrigger,\n CdkTargetMenuAim,\n];\n\n/** Module that declares components and directives for the CDK menu. */\n@NgModule({\n imports: [OverlayModule, ...MENU_DIRECTIVES],\n exports: MENU_DIRECTIVES,\n})\nexport class CdkMenuModule {}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWA;;AAEG;MAUU,YAAY,CAAA;8GAAZ,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;kGAAZ,YAAY,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,gBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,MAAA,EAAA,OAAA,EAAA,EAAA,cAAA,EAAA,gBAAA,EAAA,EAAA,SAAA,EAFZ,CAAC,EAAC,OAAO,EAAE,yBAAyB,EAAE,Q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