Theme studio

Design a theme, preview it live, then export it. Saved in this browser.

Quick picks #10b981
Generated scale
50100200300400500600700800900
Some text is below AA

MenuDivider

  • Stable
  • WCAG 2.2 evidence
  • RTL
  • Web · iOS · Android

Separates groups of items in a Menu or ContextMenu. Built on React Aria Separator, so it takes part in the menu's collection (role separator, skipped by the arrow keys). Put destructive actions last, after a divider; do not place one between every item. It is a client component because React Aria collections only render parts that register with them.

import { MenuDivider } from "@nexera-ui/react";
Loading example…
3
examples
7
props
1
live controls
3
platforms
2
WCAG criteria
2
blocks use it

Try every prop. Copy the code.

Change the props and the code updates. Check light and dark, LTR and RTL, and phone width.

Loading…
platform
Generated code
import { MenuDivider } from "@nexera-ui/react";

<MenuDivider />

Examples 2

The same examples as Storybook, rendered live. Open Code to copy one.

Platforms

Web and Android use the 1 px line; iOS uses the 8 pt group separator of the Figma System menu.

Loading example…

Standalone

Outside a menu it renders a reset <hr> (no UA margin or inset border).

Loading example…

Props 7

Press "Try it" on a card to load that prop into the playground.

7 props shown

platformNexera
"web" | "ios" | "android"

Platform look: a 1 px line on web and Android, the 8 pt group separator on iOS. Defaults to the platform of the enclosing Menu, then of the NexeraProvider.

Default "web"
classNameNexera
string

Extra classes, merged last so they win over the defaults.

Default –
styleNexera
CSSProperties

Inline style.

Default –
idReact Aria
string

The element's unique identifier. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id).

Default –
aria-labelReact Aria
string

Defines a string value that labels the current element.

Default –
aria-labelledbyReact Aria
string

Identifies the element (or elements) that labels the current element.

Default –
aria-describedbyReact Aria
string

Identifies the element (or elements) that describes the object.

Default –

* Required. React Aria props shown are the ones most apps use; the component accepts the rest of its React Aria props too.

Accessible by default.

Built on React Aria, and covered by the WCAG 2.2 evidence generated on every build.

WCAG 2.2 evidence

2 direct · 0 supporting
  • 1.3.1Info and RelationshipsLevel A · tested directly
  • 4.1.2Name, Role, ValueLevel A · tested directly

Fits any width.

Nexera components respond to the space they are given. Drag the corner of the frame, or pick a width.

0 px · drag the corner

Styling hooks

Pass className to add Tailwind classes (merged last). State is exposed as data attributes, so you can style it with variants like data-pressed:.

Usage
<MenuDivider className="shadow-sm" />

Used in blocks

Related components