Overview
SearchInput supplies a search icon and text input. onValueChange receives the new string; onChange receives the native React change event. Filtering, fetching, and debouncing belong to your application.
Usage
aria-label or aria-labelledby for an accessible name.
Native input props, className, style, and ref apply to the input itself. The shared InputGroup owns the search adornment and focus treatment. The wrapper that lays out the field and its actions takes no props; place SearchInput in your own container to size or position it. Use size="sm" for a compact search field.
Actions
actions renders controls after the search field. Compose a filter popup with a Dropdown whose trigger is an IconButton, and give that button an accessible name.
disabled disables only the text input; disable action controls separately. With size="sm", pass size="sm" to the action controls as well.
Props
Controls rendered after the search field, such as a filter Dropdown. Set their size and accessible names on the controls.
Shows the group focus border. Defaults to false for all search inputs. Set true to opt in. Error styling remains visible.
Native input change event handler.
((value: string, eventDetails: { reason: "none"; event: Event; cancel: () => void; allowPropagation: () => void; isCanceled: boolean; isPropagationAllowed: boolean; trigger: Element | undefined; }) => void)
Called with the new text. The application owns filtering.
Hint shown when the input is empty. Also used as the accessible name if no explicit label is supplied.
ReactElement<unknown, string | JSXElementConstructor<any>> | ComponentRenderFn<HTMLProps, InputState>
Allows you to replace the component’s HTML element
with a different tag, or compose it with another component.Accepts a
ReactElement or a function that returns the element to render.Style applied to the element, or a function that
returns a style object based on the component’s state.