Package org.patternfly.component.menu
Class MenuItem
- All Implemented Interfaces:
Attachable,Container<HTMLElement,,MenuItem> Finder<HTMLElement>,HasElement<HTMLElement,,MenuItem> HasHTMLElement<HTMLElement,,MenuItem> IsElement<HTMLElement>,TypedBuilder<HTMLElement,,MenuItem> WithIcon<HTMLElement,,MenuItem> WithIconAndText<HTMLElement,,MenuItem> WithIdentifier<HTMLElement,,MenuItem> WithText<HTMLElement,,MenuItem> ComponentContext<HTMLElement,,MenuItem> Modifiers.Disabled<HTMLElement,MenuItem>
public class MenuItem
extends SubComponent<HTMLElement,MenuItem>
implements ComponentContext<HTMLElement,MenuItem>, Modifiers.Disabled<HTMLElement,MenuItem>, WithIdentifier<HTMLElement,MenuItem>, WithText<HTMLElement,MenuItem>, WithIcon<HTMLElement,MenuItem>, WithIconAndText<HTMLElement,MenuItem>, Attachable
-
Method Summary
Modifier and TypeMethodDescriptionstatic MenuItemactionMenuItem(String identifier, String text) Create a new menu item with typeMenuItemType.action.add(MenuItemAction itemAction) addAction(MenuItemAction itemAction) static MenuItemasyncMenuItem(String identifier, String text, Function<MenuList, elemental2.promise.Promise<List<MenuItem>>> loadItems) voidattach(MutationRecord mutationRecord) static MenuItemcheckboxMenuItem(String identifier, String text) Create a new menu item with typeMenuItemType.link.danger()description(HTMLElement element) description(String description) disabled(boolean disabled) external()<T> TbooleaniconAndText(Element icon, String text, IconPosition iconPosition) static MenuItemlinkMenuItem(String identifier, String text, String href) Create a new menu item with typeMenuItemType.link.static MenuItemmenuItem(String identifier, MenuItemType type) Create a new menu item with the specified type.onClick(ComponentHandler<MenuItem> handler) selected()<T> MenuItemtext()text(HTMLElement element) that()Methods inherited from class org.patternfly.component.SubComponent
elementMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jboss.elemento.Attachable
detachMethods inherited from interface org.patternfly.core.ComponentContext
get, getMethods inherited from interface org.jboss.elemento.Container
add, add, add, addAll, addAll, addAll, addAll, addAll, addAllMethods inherited from interface org.jboss.elemento.HasElement
add, apply, aria, aria, aria, attr, attr, attr, classList, classList, css, id, innerHtml, on, on, on, run, textContent, textNode, toggle, toggle, toggle, uniqueIdMethods inherited from interface org.jboss.elemento.HasHTMLElement
data, hidden, style, style, style, style, style, style, titleMethods inherited from interface org.patternfly.style.Modifiers.Disabled
disabled, isDisabledMethods inherited from interface org.patternfly.component.WithIconAndText
iconAndText, iconAndText
-
Method Details
-
actionMenuItem
Create a new menu item with typeMenuItemType.action. -
linkMenuItem
Create a new menu item with typeMenuItemType.link. -
checkboxMenuItem
Create a new menu item with typeMenuItemType.link. -
asyncMenuItem
-
attach
- Specified by:
attachin interfaceAttachable
-
danger
-
selected
-
disabled
- Specified by:
disabledin interfaceModifiers.Disabled<HTMLElement,MenuItem>
-
text
- Specified by:
textin interfaceWithText<HTMLElement,MenuItem>
-
text
-
href
-
external
-
description
-
description
-
icon
- Specified by:
iconin interfaceWithIcon<HTMLElement,MenuItem>
-
removeIcon
- Specified by:
removeIconin interfaceWithIcon<HTMLElement,MenuItem>
-
iconAndText
- Specified by:
iconAndTextin interfaceWithIconAndText<HTMLElement,MenuItem>
-
store
- Specified by:
storein interfaceComponentContext<HTMLElement,MenuItem>
-
that
- Specified by:
thatin interfaceTypedBuilder<HTMLElement,MenuItem>
-
onClick
-
identifier
- Specified by:
identifierin interfaceWithIdentifier<HTMLElement,MenuItem>
-
text
- Specified by:
textin interfaceWithText<HTMLElement,MenuItem>
-
has
- Specified by:
hasin interfaceComponentContext<HTMLElement,MenuItem>
-
get
- Specified by:
getin interfaceComponentContext<HTMLElement,MenuItem>
-