About
A text search field with a leading magnifier icon and a clear button that appears once there is text, for list filters, tables and site search.
Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Search Input to your project and fits it to your theme.
Code
How Search Input is used: the demo's code. The component's own source comes with a free account.
Usage.tsx
import { SearchInput } from "@/components/ui/search-input";
export default function SearchInputDemo() {
return (
<div className="flex w-full max-w-sm items-center justify-center p-8">
<SearchInput
id="q1"
placeholder="Search components"
aria-label="Search components"
/>
</div>
);
}















![Form [react-aria-components]](https://cdn.21st.dev/cdn-cgi/image/fit=scale-down,width=640,quality=75,format=webp/https://cdn.21st.dev/user_jolbol1/field/814/preview.png)