Skip to main content

Examples

Default

Props

FilterMenu

A menu of options under a trigger you supply, where several can be ticked. Each tick calls onValueChange at once and the menu stays open, so several can be ticked in one go. It holds no state: pass value back in. The ref goes to the menu content. Keyboard support comes from the menu: arrow keys move, Space or Enter ticks, typing jumps to a label, Escape closes.
ReactElement<unknown, string | JSXElementConstructor<any>>
required
The trigger element, e.g. a TableToolbarAction. It must forward its ref and spread props.
(value: V[]) => void
required
Called with the new ticked values each time an option is ticked or unticked.
readonly FilterMenuOption<V>[]
required
The choices, in display order.
readonly V[]
required
The ticked values.
Omit<DropdownMenuContentProps, "children">
default:"{ align: \"start\" }"
Props for the menu content, such as align or aria-label.

Exported types

Also exported from @fanvue/ui: FilterMenuOption, FilterMenuProps.
Setup: Installation · Theming