FilterSearch
moleculeCollapsible search button that expands to a text input on click and collapses back when blurred empty. Designed for filter bars and toolbars where space is tight.
Default
Click the search icon to expand, blur empty to collapse.
Sizes
Three sizes matching the filter family.
Usage
Installation
API Reference
FilterSearch props — * required
| Prop | Type | Default | Description |
|---|---|---|---|
value | string | — | Controlled search value. |
defaultValue | string | — | Initial value for uncontrolled usage. |
onChange | (value: string) => void | — | Called with the current search string. |
placeholder | string | "Search…" | Input placeholder text. |
variant | "secondary" | "outline" | "secondary" | Button style when collapsed. |
size | "sm" | "md" | "lg" | "md" | Button and input size. |
width | number | 260 | Width of the expanded input in pixels. |
disabled | boolean | false | Disables the button. |
style | React.CSSProperties | — | Inline styles for the wrapper. |