ARIA Widget Roles
ARIA role: menuitemcheckbox
A menu command representing an independently checkable setting. Requires aria-checked, menu context and keyboard activation; synchronize visual and semantic state. Static structure only. Explicit roles do not implement visual presentation, interaction or focus management; verify allowed role/element combinations in ARIA in HTML. Accessibility exposure varies with browser, platform and assistive technology. Test relevant combinations; rendering is not proof of accessibility.
Formal Syntax & Structure
html syntaxhtml
role="menuitemcheckbox"Parameters & Attributes
| Name | Type | Description |
|---|---|---|
| role | token | Explicit role token menuitemcheckbox; use only where allowed. Omit when native semantics match. |
| aria-checked | tristate | Required for this custom role unless equivalent host semantics apply. Reports whether a checkable widget is checked, unchecked, or partially checked. Mixed applies only to roles supporting tri-state behavior; not radio or switch. Keep this in sync with the real state. Native checkbox checked and indeterminate properties are preferable where applicable. Values: true, false, mixed, undefined. |
Working Example
Example Snippethtml
<div role="menu" aria-label="View"> <div role="menuitemcheckbox" aria-checked="false" tabindex="0">Show grid</div></div>