Class BaseSearchInput<T extends BaseSearchInput<T>>

All Implemented Interfaces:
ElementAttributeMethods<HTMLElement, T>, ElementClassListMethods<HTMLElement, T>, ElementConsumerMethods<HTMLElement, T>, ElementContainerMethods<HTMLElement, T>, ElementEventMethods<HTMLElement, T>, ElementIdMethods<HTMLElement, T>, ElementQueryMethods<HTMLElement>, HTMLElementAttributeMethods<HTMLElement, T>, HTMLElementDataMethods<HTMLElement, T>, HTMLElementStyleMethods<HTMLElement, T>, HTMLElementVisibilityMethods<HTMLElement, T>, IsElement<HTMLElement>, TypedBuilder<HTMLElement, T>, Component, ComponentIcon<HTMLElement, T>, HasValue<String>, Validatable<HTMLElement, T>, Modifiers.Disabled<HTMLElement, T>, Modifiers.Plain<HTMLElement, T>
Direct Known Subclasses:
BaseFilterInput, SearchInput

public abstract class BaseSearchInput<T extends BaseSearchInput<T>> extends BaseTextInputGroup<T>
  • Method Details

    • noDefaultOnClear

      public T noDefaultOnClear()
      Removes the default behavior when the component is cleared. By default, the clear button clears the input field (w/o firing a change event).
    • showUtilitiesIf

      public T showUtilitiesIf(BiFunction<T,String,Boolean> visibility)
      Sets the visibility condition for the utility button. By default, the button is visible when the input field is not empty. The provided BiFunction determines whether the utility should be visible based on the current SearchInput instance and a String value.
      Parameters:
      visibility - a BiFunction that takes the SearchInput instance and a String value as arguments and returns a Boolean indicating whether the utility should be visible.
    • onClear

      public T onClear(ComponentHandler<T> onClear)
      Adds a handler to be executed when the clear action is pressed.
      Parameters:
      onClear - a ComponentHandler that defines the behavior to execute on a clear action.
    • value

      public T value(String value)
      Description copied from class: BaseTextInputGroup
      Overrides:
      value in class BaseTextInputGroup<T extends BaseSearchInput<T>>
    • value

      public T value(String value, boolean fireEvent)
      Overrides:
      value in class BaseTextInputGroup<T extends BaseSearchInput<T>>