-
public final class SearchInputKt
-
-
Method Summary
Modifier and Type Method Description final static UnitSearchInput(String query, Function1<String, Unit> onValueChange, Modifier modifier, Function0<Unit> onSearchStarted, Function1<RowScope, Unit> leadingIcon, Function0<Unit> label, Function1<RowScope, Unit> clearButton)The search component that allows the user to fill in a search query and filter their items. -
-
Method Detail
-
SearchInput
@Composable() final static Unit SearchInput(String query, Function1<String, Unit> onValueChange, Modifier modifier, Function0<Unit> onSearchStarted, Function1<RowScope, Unit> leadingIcon, Function0<Unit> label, Function1<RowScope, Unit> clearButton)
The search component that allows the user to fill in a search query and filter their items.
It also holds a clear action, that is active when the search is in focus and not empty, to clear the input.
- Parameters:
query- Current query value.onValueChange- Handler when the value changes.modifier- Modifier for styling.onSearchStarted- Handler when the search starts, by focusing the input field.leadingIcon- The icon at the start of the search component that's customizable, but shows DefaultSearchLeadingIcon by default.label- The label shown in the search component, when there's no input.clearButton- The clear button shown when the search is focused and not empty.
-
-
-
-