Skip to contents

Create a MenuItem component

Usage

calcite_menu_item(...)

Arguments

...

named attributes passed to htmltools::tag()

Value

an object of class calcite_component which is a subclass of shiny.tag

Details

Properties

The following properties are provided by this component:

NameAttributeDescriptionValuesReflects to Attribute
activeactiveWhen true, the component is highlighted.booleanTRUE
breadcrumbbreadcrumbWhen true, the component displays a breadcrumb trail for use as a navigational aid.booleanTRUE
hrefhrefSpecifies the URL destination of the component, which can be set as an absolute or relative path.stringFALSE
iconEndicon-endSpecifies an icon to display at the end of the component.stringTRUE
iconFlipRtlicon-flip-rtlDisplays the iconStart and/or iconEnd as flipped when the element direction is right-to-left ("rtl")."both" | "end" | "start"TRUE
iconStarticon-startSpecifies an icon to display at the start of the component.stringTRUE
labellabelAccessible name for the component.stringFALSE
messageOverridesNAUse this property to override individual strings used by the component.Check API referenceFALSE
openopenWhen true, the component will display any slotted calcite-menu-item in an open overflow menu.booleanTRUE
relrelDefines the relationship between the href value and the current document.stringTRUE
targettargetSpecifies where to open the linked document defined in the href property.stringTRUE
texttextSpecifies the text to display.stringFALSE

Events

The following events are observed by shiny:

EventDescription
calciteMenuItemSelectEmits when the component is selected.

Slots

The following slots are provided by this component:

SlotDescription
submenu-itemA slot for adding calcite-menu-items in a submenu.

Examples

calcite_menu_item()
#> <calcite-menu-item></calcite-menu-item>