Skip to content

co-menu-item

This content is not available in your language yet.

Row inside a co-menu. Two modes: 1. Leaf — when no nested co-menu-item / co-menu-divider are passed in the default slot, clicking emits coSelect and coMenuSelect (the latter bubbles up to co-menu for auto-close). 2. Submenu trigger — when nested menu items ARE present, the item renders a chevron suffix and on hover/focus opens a co-popover to the right containing those nested items. The trigger itself does NOT emit coSelect — only the leaf items inside do. Submenu nesting is unbounded — submenu items can themselves have submenus.

Ver código
<co-menu-item label="Ejemplo"></co-menu-item>

Props

PropAtributoTipoDefaultDescripción
densedensebooleanfalseTighter row metrics (32px instead of 36px).
disableddisabledbooleanfalseVisually disabled — pointer events ignored, opacity reduced.
iconiconstring | undefinedIcon name (Phosphor) rendered before the label.
labellabelstring | undefinedText shown in the row.
variantvariant"danger" | "default"'default'`danger` shifts text + icon to the destructive color. Use for Delete, etc.

Eventos

EventoDetailBubblesCancelableDescripción
coMenuSelectvoidBubbled to the parent `co-menu` so it can auto-close on leaf selection. Submenu triggers do not emit this.
coSelectvoidFired when this leaf item is selected. Submenu triggers do NOT fire it.

Slots

Este componente no expone slots.

CSS Parts

Este componente no expone CSS parts.

CSS Custom Properties

Este componente no expone CSS custom properties.