Annotation Interface TextInput


@Target(PARAMETER) @Retention(RUNTIME) public @interface TextInput
Annotation used to add TextInputs to Modals.
See Also:
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    The placeholder of this TextInput
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    The default value of this TextInput.
    The label shown above this text input box
    int
    The maximum length.
    int
    The minimum length.
    boolean
    Whether this TextInput is required.
  • Element Details

    • value

      String value

      The placeholder of this TextInput

      This is the short hint that describes the expected value of the TextInput field.

      Returns:
      Placeholder
    • label

      String label
      The label shown above this text input box
      Returns:
      Label for the input
      Default:
      ""
    • defaultValue

      String defaultValue

      The default value of this TextInput.

      This sets a pre-populated text for this TextInput field

      Returns:
      default value
      Default:
      ""
    • minValue

      int minValue
      The minimum length. This is -1 if none has been set.
      Returns:
      Minimum length or -1
      Default:
      -1
    • maxValue

      int maxValue
      The maximum length. This is -1 if none has been set.
      Returns:
      Maximum length or -1
      Default:
      -1
    • style

      The TextInputStyle. The default value is TextInputStyle.PARAGRAPH.
      Returns:
      The TextInputStyle
      Default:
      PARAGRAPH
    • required

      boolean required

      Whether this TextInput is required.

      If this is True, the user must populate this TextInput field before they can submit the Modal.

      Returns:
      True if this TextInput is required
      See Also:
      Default:
      true