com.vaadin.flow.component.applayout.
Class DrawerToggle
All Implemented Interfaces:
AttachNotifier
, BlurNotifier<Button>
, ClickNotifier<Button>
, DetachNotifier
, Focusable<Button>
, FocusNotifier<Button>
, HasAriaLabel
, HasElement
, HasEnabled
, HasSize
, HasStyle
, HasText
, HasTheme
, HasPrefix
, HasSuffix
, HasThemeVariant<ButtonVariant>
, HasTooltip
, Serializable
Server-side component for the <vaadin-drawer-toggle>
element. It is a
button that allows the user to open and close the drawer. To use it, add it
to the AppLayout
, typically in the navbar slot.
AppLayout layout = new AppLayout();
layout.addToNavbar(new DrawerToggle());
See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier
BlurNotifier.BlurEvent<C extends Component>
Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier
FocusNotifier.FocusEvent<C extends Component>
Nested classes/interfaces inherited from interface com.vaadin.flow.component.HasText
HasText.WhiteSpace
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class com.vaadin.flow.component.button.Button
click, clickInClient, getIcon, isAutofocus, isDisableOnClick, isIconAfterText, remove, setAutofocus, setDisableOnClick, setEnabled, setIconAfterText, setText
Methods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getListeners, getLocale, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onAttach, onDetach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisible
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListener
Methods inherited from interface com.vaadin.flow.component.BlurNotifier
addBlurListener
Methods inherited from interface com.vaadin.flow.component.ClickNotifier
addClickListener, addClickShortcut, addDoubleClickListener, addSingleClickListener
Methods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListener
Methods inherited from interface com.vaadin.flow.component.Focusable
addFocusShortcut, blur, focus, getTabIndex, setTabIndex
Methods inherited from interface com.vaadin.flow.component.FocusNotifier
addFocusListener
Methods inherited from interface com.vaadin.flow.component.HasAriaLabel
getAriaLabel, getAriaLabelledBy, setAriaLabel, setAriaLabelledBy
Methods inherited from interface com.vaadin.flow.component.HasElement
getElement
Methods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled
Methods inherited from interface com.vaadin.flow.component.shared.HasPrefix
getPrefixComponent, setPrefixComponent
Methods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFull
Methods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
Methods inherited from interface com.vaadin.flow.component.shared.HasSuffix
getSuffixComponent, setSuffixComponent
Methods inherited from interface com.vaadin.flow.component.HasText
getText, getWhiteSpace, setWhiteSpace
Methods inherited from interface com.vaadin.flow.component.HasTheme
addThemeName, addThemeNames, getThemeName, getThemeNames, hasThemeName, removeThemeName, removeThemeNames, setThemeName, setThemeName
Methods inherited from interface com.vaadin.flow.component.shared.HasThemeVariant
addThemeVariants, removeThemeVariants
Methods inherited from interface com.vaadin.flow.component.shared.HasTooltip
getTooltip, setTooltipText
-
Constructor Details
-
DrawerToggle
public DrawerToggle()
-
-
Method Details
-
setIcon
Description copied from class:
Button
Sets the given component as the icon of this button.
Even though you can use almost any component as an icon, some good options are
Icon
andImage
.Use
Button.setIconAfterText(boolean)
to change the icon's position relative to the button's text content.This method also sets or removes this button's
theme=icon
attribute based on whether this button contains only an icon after this operation or not.
-