1. Kikita UI
  2. Components
  3. Actions
  4. Menu
Skip to content
Kikita UI
  • Installation
  • Theming
  • Tokens
  • Typography
  • Density
  • Accessibility
  • AI Support
  • Package Smoke
  • Button
  • Icon Button
  • Menu
  • Command Palette
  • Field
  • Input
  • Color Input
  • Select
  • Combobox
  • Date Picker
  • Calendar
  • File Upload
  • Segmented
  • Slider
  • Number Input
  • Textarea
  • Checkbox
  • Switch
  • Radio
  • Group
  • Badge
  • Loader
  • Skeleton
  • Tooltip
  • Toast
  • Empty State
  • Progress
  • Card
  • Tabs
  • Accordion
  • Breadcrumbs
  • Popover
  • Dialog
  • Drawer
  • Dropdown
  • Separator
  • Stepper
  • Icon
  • Avatar
  • Table
  • Chip
  • Scrollbar
  • Tree
  • Import
  • Usage
  • Content
  • API
  • Accessibility

Actions

Stable - @kikita-labs/ui v1.6.1

Menu

Overlay action menu for commands such as edit, copy, archive, and delete.

Import

Menu composes a panel, trigger directive, menu items, headers, and separators.

menu.ts
import {
  KuiButtonDirective,
  KuiMenuComponent,
  KuiMenuForDirective,
  KuiMenuHeaderDirective,
  KuiMenuItemDirective,
  KuiSeparatorDirective,
} from '@kikita-labs/ui';

Usage

Open in Playground

Use menu for actions, not value selection. Use Select or Dropdown for picking values.

<div class="basic-menu-example">
  <button kuiButton type="button" [kuiMenuFor]="actionsMenu">Actions</button>

  <kui-menu #actionsMenu ariaLabel="Project actions">
    <button type="button" kuiMenuItem>
      <span class="kui-menu-item__label">Edit</span>
    </button>
    <button type="button" kuiMenuItem>
      <span class="kui-menu-item__label">Copy</span>
    </button>
    <hr kuiSeparator spacing="xs" />
    <button type="button" kuiMenuItem appearance="destructive">
      <span class="kui-menu-item__label">Delete</span>
    </button>
  </kui-menu>
</div>

Content

Headers, icons, shortcuts, disabled states, and destructive actions are projected item content.

<div class="menu-content-example">
  <button kuiButton type="button" shape="outline" [kuiMenuFor]="rowMenu">Row actions</button>

  <kui-menu #rowMenu ariaLabel="Row actions" menuAlign="end" minWidth="220px">
    <div kuiMenuHeader>Project</div>
    <button type="button" kuiMenuItem>
      <span class="kui-menu-item__icon" aria-hidden="true">E</span>
      <span class="kui-menu-item__label">Rename</span>
      <span class="kui-menu-item__shortcut">F2</span>
    </button>
    <button type="button" kuiMenuItem>
      <span class="kui-menu-item__icon" aria-hidden="true">C</span>
      <span class="kui-menu-item__label">Copy link</span>
      <span class="kui-menu-item__shortcut">Ctrl C</span>
    </button>
    <hr kuiSeparator spacing="xs" />
    <button type="button" kuiMenuItem disabled>
      <span class="kui-menu-item__label">Archive</span>
    </button>
  </kui-menu>
</div>

API

Inputs verified against @kikita-labs/ui v1.6.1 public typings.

NameTypeDefaultDescription
ariaLabelstring'Actions'Accessible name for the menu panel.
placement'top' | 'bottom' | 'left' | 'right''bottom'Preferred side of the trigger the menu opens on. Auto-flips to the opposite side to fit the viewport.
menuAlign'start' | 'end''start'Alignment along the trigger edge. For top/bottom placement, start is left-aligned and end is right-aligned. For left/right placement, start is top-aligned and end is bottom-aligned.
offsetnumber4Pixel gap between the trigger and the menu panel.
minWidthstring | nullnullOptional overlay minimum width.
[kuiMenuFor]KuiMenuComponent | undefined-Wires a native trigger to a menu instance and manages trigger ARIA state.
kuiMenuHeader--Marks a non-interactive group heading inside the menu panel. Renders with role="presentation".
kuiSeparator--Native hr[kuiSeparator] divider between menu item groups. See the Separator page for spacing and appearance inputs.
kuiMenuItem.appearance'neutral' | 'destructive''neutral'Visual treatment for an action item. Use destructive for dangerous actions.
kuiMenuItem.disabledbooleanfalsePrevents activation and applies disabled/aria-disabled semantics. Disabled items are skipped by keyboard navigation.

Accessibility

Menu owns keyboard navigation while keeping triggers and items native.

  • [kuiMenuFor] sets aria-haspopup="menu" and aria-expanded on the trigger, and adds aria-controls while the panel is open.
  • The panel uses role="menu"; items use role="menuitem".
  • Group headers marked with kuiMenuHeader use role="presentation".
  • Disabled items expose aria-disabled="true" and are skipped by keyboard navigation.
  • ArrowDown and ArrowUp open from the trigger and focus the first or last item.
  • Home, End, and arrow keys move focus inside the menu.
  • Escape closes the menu and returns focus to the trigger.
  • Tab closes the menu and lets focus continue to the next element.
  • Menu covers keyboard navigation and static ARIA review. Screen reader and other assistive-technology verification has not been completed for this primitive yet; see state-coverage.md in the library repository for current review status.

On this page