Docs
Password Input Primitive

Password Input Primitive

Password Input provides a way for the user to securely enter a password, with the ability to toggle the visibility of the password.

Installation

pnpm dlx cross-env REGISTRY_URL=https://ui-x.junwen-k.dev/r pnpm dlx shadcn@latest add password-input-primitive

Anatomy

import * as PasswordInputPrimitive from "@/components/ui/password-input-primitive"
 
export default () => (
  <PasswordInputPrimitive.Root>
    <PasswordInputPrimitive.Input />
    <PasswordInputPrimitive.Toggle />
    <PasswordInputPrimitive.Indicator />
  </PasswordInputPrimitive.Root>
)

Examples

Default

Checkbox