-
Notifications
You must be signed in to change notification settings - Fork 6.8k
feat(aria/menu): create the aria menu #32080
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Deployed dev-app for 12f3d89 to: https://ng-dev-previews-comp--pr-angular-components-32080-dev-vqxm81d2.web.app Note: As new commits are pushed to this pull request, this link is updated after the preview is rebuilt. |
6f4e2d4
to
cc443be
Compare
* Adds the initial implementation of the WAI-ARIA menu, menubar, and menuitem patterns. This includes the basic behaviors for keyboard navigation, opening and closing submenus, and typeahead support. * This also introduces a 'focusElement' option to the list navigation behaviors to allow for moving the active item without focusing it.
* Adds the initial implementation of the 'ngMenu', 'ngMenuBar', 'ngMenuItem', and 'ngMenuTrigger' directives built on top of the menu UI patterns.
* Adds four examples for the new ARIA menu directives: - A menubar example demonstrating a typical application menu. - A menu trigger example showing a simple icon button that opens a menu. - A standalone menu example. - A context menu example that opens on right-click. * Also includes a set of simple wrapper directives to apply basic popover styles and behavior to the examples.
46848d7
to
12f3d89
Compare
readonly submenu = input<Menu<V> | undefined>(undefined); | ||
|
||
/** The unique ID of the menu. */ | ||
readonly id = input<string>(Math.random().toString(36).substring(2, 10)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this the new ID strategy?
} | ||
|
||
/** Handles mouseover events for the menu. */ | ||
onMouseOver(event: MouseEvent) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this handles pointer event instead?
ngMenu
,ngMenuBar
,ngMenuItem
, andngMenuTrigger
directives.standalone menu, a context menu, and a menu attached to a trigger.