Input

A standard text input field for form data.

Installation

Import the component from the passport-ui package.

components/example.tsx
1import { Input } from "passport-ui";
2import { Label } from "passport-ui";

Usage

Basic example showing how to use the component.

components/example.tsx
1<div className="w-sm">
2 <div className="meta-container">
3 <Label htmlFor="email">Email Address</Label>
4 <Input
5 id="email"
6 type="email"
7 placeholder="hello@example.com"
8 />
9 </div>
10</div>
11
12{/* Different input types */}
13<Input type="password" placeholder="Enter password" />
14<Input type="number" placeholder="Enter number" />
15<Input type="search" placeholder="Search..." />
16
17{/* Disabled state */}
18<Input disabled placeholder="Disabled input" />

Additional resources

Documentation and examples are available in Storybook.