smrt
Open the smrt source on GitHub Switch to dark color scheme
← All UI components

Forms and controls

SearchInput

The search box of a list's filter bar.

Public export

typescript
import { SearchInput } from '@happyvertical/smrt-ui/forms';
Import path
@happyvertical/smrt-ui/forms
Props
8
Props described
8 of 8
Bindable state
0
Callback events
1
Verified release
0.62.10

Props

NameTypeRequiredDescription
valuestringYesThe search the list is showing (from the URL or the page's state).
onsearch(query: string) => void | Promise<void>YesCalled with the trimmed, single-line text (`''` to clear).
placeholderstringNoPlaceholder text: what the search matches.
labelstringNoAccessible name of the field.
clearLabelstringNoAccessible name of the clear button.
debounceMsnumberNoPause after the last key before searching, in milliseconds.
namestringNoForm field name.
classstringNoAdditional CSS class names on the wrapper.

Bindable state

This component has no bindable public state.

Callback events

  • onsearch(query: string) => void | Promise<void>

Examples and explanation