API reference
Reference for the tng-menu component and [tngMenuTriggerFor] wiring from @tailng-ui/components, with primitives projected into the menu host.
Wrapper APIs
| Element / Directive | Input / Output | Type | Description |
|---|---|---|---|
<tng-menu> | ariaLabel | string | Accessible label for the menu panel. |
<tng-menu> | loop, disabled, closeOnSelect | boolean | Controls focus traversal, interaction lock, and auto-close behavior. |
<tng-menu> | dismissOnOutsideClick, dismissOnFocusout | boolean | Dismiss policy for pointer and focus transitions. |
<tng-menu> | tngMenuOpened, tngMenuClosed, tngMenuSelect | EventEmitter | Menu lifecycle and selection outputs. |
[tngMenuTriggerFor] | tngMenuTriggerFor | TngMenu | Connects a trigger element to a wrapper menu instance. |
Projected directives
| Directive | Used on | Purpose |
|---|---|---|
tngMenuItem | Projected command button | Selectable command item. Combine with tngMenuItemValue for emitted values, or [tngMenuItemSubmenu] for cascaded menus. |
tngMenuGroupLabel | Projected label element | Optional section label for grouped command sets inside a wrapper menu. |
tngMenuSeparator | Projected separator element | Visual break between clusters of commands inside the same wrapper menu. |
Keyboard contract (high level)
ArrowDown/ArrowUpmoves active item through enabled options.Home/Endjumps to first and last item.Enter/Spaceselects active option.Escapecloses current menu and returns focus to trigger.ArrowRight/ArrowLefttraverses submenu levels or menubar-owned menu handoff.