Class FieldMarkerI18n

java.lang.Object
com.vaadin.flow.component.ai.form.FieldMarkerI18n
All Implemented Interfaces:
Serializable

public class FieldMarkerI18n extends Object implements Serializable
The texts shown by the marker the FormAIController applies to the fields the AI filled: the "AI" badge, its tooltip, and the popover that explains the AI fill and offers a revert control. Use to localize the marker; any text left null falls back to the built-in English default.
Since:
25.3
Author:
Vaadin Ltd
See Also:
  • Constructor Details

    • FieldMarkerI18n

      public FieldMarkerI18n()
  • Method Details

    • getMessage

      public String getMessage()
      Gets the message shown in the popover explaining the AI fill.
      Returns:
      the popover message, or null when the built-in default is used
    • setMessage

      public FieldMarkerI18n setMessage(String message)
      Sets the message shown in the popover explaining the AI fill. The message is also announced to screen readers when a field is marked.
      Parameters:
      message - the popover message, or null to use the built-in default
      Returns:
      this instance, for chaining
    • getRevert

      public String getRevert()
      Gets the label of the revert control in the popover.
      Returns:
      the revert control label, or null when the built-in default is used
    • setRevert

      public FieldMarkerI18n setRevert(String revert)
      Sets the label of the revert control in the popover.
      Parameters:
      revert - the revert control label, or null to use the built-in default
      Returns:
      this instance, for chaining
    • getBadgeLabel

      public String getBadgeLabel()
      Gets the accessible label of the badge button and the popover dialog.
      Returns:
      the badge label, or null when the built-in default is used
    • setBadgeLabel

      public FieldMarkerI18n setBadgeLabel(String badgeLabel)
      Sets the accessible label of the badge button and the popover dialog.
      Parameters:
      badgeLabel - the badge label, or null to use the built-in default
      Returns:
      this instance, for chaining
    • getBadgeTooltip

      public String getBadgeTooltip()
      Gets the tooltip text of the badge button.
      Returns:
      the badge tooltip text, or null when the built-in default is used
    • setBadgeTooltip

      public FieldMarkerI18n setBadgeTooltip(String badgeTooltip)
      Sets the tooltip text of the badge button.
      Parameters:
      badgeTooltip - the badge tooltip text, or null to use the built-in default
      Returns:
      this instance, for chaining