Getting started

InstallUsageGuidelinesContributeRelease

Foundation

Navigation

Overlay

Confirmation DialogDrawerFilter MenuMenuTooltip

Menu

Menu presents a set of actions to perform on the currently visible or selected resource.

#

#

#

There are use cases when a "More" or "Actions" menu is needed to show contextual actions relevant to the currently visible resource. Usually these menus don't actually say "More" or "Actions", but show an icon with three dots in it.

Hightouch UI offers a convenience component specifically for that use case called MenuActionsButton to replace MenuButton with.

Icon can be vertical too.

If you need to use a custom icon, use MenuIconButton component.

#

Use this variant to achieve a border around the menu button.

#

#

  • When user needs to perform some actions on one or more selected items on the current page.
  • As a replacement for button group, when there are too many buttons inside.

#

  • If menu is used for in-page navigation or replacing part of the page content, use tabs instead.

#

  • Use sentence case.
  • Position dangerous menu items last and add a divider before them.

#

  • Only use icons from Heroicons.
  • Don't override icon size.
  • Prefer outline icons over solid ones.
  • Menus look much better with icons, so try to find an icon that matches each menu item.
  • If menu items are too similar in their meaning and would require repeating the same icon, skip icons altogether.

#

NameDefaultDescription
children

ReactNode

Menu button and list.

NameDefaultDescription
children

ReactNode

Button text.

size"md""sm" | "md" | "lg"

Determines the height of the button.

NameDefaultDescription
aria-label"Actions"string

Button text for screen readers.

orientation"horizontal""horizontal" | "vertical"

Icon orientation.

size"md""sm" | "md" | "lg"

Determines the height of the button.

variant"ghost""secondary" | "ghost"

Button variant, which determines its appearance.

NameDefaultDescription
aria-label

string

Button text for screen readers.

icon

ComponentType<SVGAttributes<SVGElement>>

Icon to show inside of a button.

size"md""sm" | "md" | "lg"

Determines the height of the button.

variant"ghost""secondary" | "ghost"

Button variant, which determines its appearance.

NameDefaultDescription
children

ReactNode

Menu items.

NameDefaultDescription
isDisabled

boolean

Determines if menu item is disabled.

children

ReactNode

Menu item text.

icon

ComponentType<SVGProps<SVGSVGElement>>

Icon.

variant

"normal" | "danger"

Variant. Use `"danger"` for destructive or dangerous actions.

onClick

() => void

Callback for when user clicks a menu item.

NameDefaultDescription

On this page

  • Example
  • Usage
  • With icon button
  • Secondary
  • Guidelines
  • When to use it
  • When not to use it
  • Content
  • Icons
  • Props
  • Menu
  • MenuButton
  • MenuActionsButton
  • MenuIconButton
  • MenuList
  • MenuItem
  • MenuDivider