Class TooltipUtils

java.lang.Object
com.vaadin.featurepack.util.TooltipUtils

public class TooltipUtils extends Object
Utility class for setting and getting tooltip descriptions for components.
  • Constructor Details

    • TooltipUtils

      public TooltipUtils()
  • Method Details

    • hasTooltip

      public static boolean hasTooltip(com.vaadin.flow.component.Component component)
    • setDescription

      public static void setDescription(com.vaadin.flow.component.Component component, String description)
    • setDescription

      public static void setDescription(com.vaadin.flow.component.Component component, String description, ContentMode mode)
    • setTooltip

      public static void setTooltip(com.vaadin.flow.component.Component component, String description, ContentMode mode)
    • setupPopover

      public static void setupPopover(com.vaadin.flow.component.Component component, String description, ContentMode mode)
      Sets up a popover for the component with the given description and mode. Popover works on any component.
      Parameters:
      component - the component to set up the popover for
      description - the description to show in the popover
      mode - the content mode of the description
    • getDescription

      public static String getDescription(com.vaadin.flow.component.Component component)
    • setDescriptionValue

      public static void setDescriptionValue(com.vaadin.flow.component.Component component, String description)
    • getDescriptionContentMode

      public static ContentMode getDescriptionContentMode(com.vaadin.flow.component.Component component)
    • setDescriptionContentMode

      public static void setDescriptionContentMode(com.vaadin.flow.component.Component component, ContentMode descriptionContentMode)
    • getPopover

      public static com.vaadin.flow.component.popover.Popover getPopover(com.vaadin.flow.component.Component component)
    • setPopover

      public static void setPopover(com.vaadin.flow.component.Component component, com.vaadin.flow.component.popover.Popover popover)
    • getFormattedMessage

      public static String getFormattedMessage(String message, ContentMode mode)