pearpages

Text Field

Forms

About

A single-line text input with a built-in label, description and error message wired for screen readers, plus an optional leading icon and a clear button.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Text Field to your project and fits it to your theme.

Code

How Text Field is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { TextField } from "@/components/ui/text-field";

export default function TextFieldDemo() {
  return (
    <div className="w-full max-w-sm mx-auto p-6 bg-background text-foreground">
      <TextField label="Email address" placeholder="you@example.com" />
    </div>
  );
}

Dependencies

More by pearpages

View all
  • Popover

    Popover

    6
  • Slider

    Slider

  • Switch

    Switch

  • Data Grid

    Data Grid

  • Tabs

    Tabs

More in Forms

View all
  • Premium Auth

    Premium Auth

    577
  • Login 1

    Login 1

    68
  • Contact Card

    Contact Card

    1.1K
  • Form

    Form

    18
  • Login Card

    Login Card

    36
  • Login 2

    Login 2

    15
  • Change Password Form

    Change Password Form

    11
  • Form

    Form

    3