Password Input
A password input field with a toggle button to show or hide the entered text.
Install
npx @vultra/cli add password-input
Usage
<script>
import { PasswordInput } from '@vultra/ui';
let password = $state('');
</script>
<PasswordInput bind:value={password} placeholder="Enter password" />
Props
| Prop | Type | Default | Description |
|---|
| value | string | ” | Current password value |
| placeholder | string | - | Input placeholder |
| disabled | boolean | false | Disable input |
| class | string | - | Additional CSS classes |
Events
| Event | Detail | Description |
|---|
| change | string | Fires when value changes |
Notes
- Toggle button switches between
type="password" and type="text". - Use eye/eye-off icons in the toggle for clear affordance.