Label

A text label for form inputs, providing context and improving accessibility.

Installation

Import the component from the passport-ui package.

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

Usage

Basic example showing how to use the component.

components/example.tsx
1
2
3
4
5
6
7
<Label htmlFor="email">Email Address</Label>
{/* With form control */}
<div className="meta-container">
<Label htmlFor="username">Username</Label>
<Input id="username" placeholder="Enter username" />
</div>

Additional resources

Documentation and examples are available in Storybook.