Skip to main content
Version: Next

PasswordField API

import { PasswordField } from '@editora/ui-react';

Props​

PropTypeDescription
autoCompletestring
autofocusboolean
clearableboolean
colorstring
counterboolean
debouncenumber
density'default' | 'compact' | 'comfortable'
descriptionstring
disabledboolean
errorstring
floatingLabelboolean
labelstring
maxlengthnumber
minlengthnumber
namestring
onChange(value: string) => void
onClear() => void
onDebouncedInput(value: string) => void
onInput(value: string) => void
onStrengthChange(detail: { value: string; score: 1 | 2 | 3 | 4; label: string; caption: string }) => void
onVisibilityChange(revealed: boolean) => void
patternstring
placeholderstring
radius'none' | 'large' | 'full' | string
readOnlyboolean
requiredboolean
revealableboolean
shape'default' | 'square' | 'soft'
showStrengthboolean
size'sm' | 'md' | 'lg' | '1' | '2' | '3'
spellCheckboolean
strengthEvaluator(value: string) => { score: 1 | 2 | 3 | 4; label: string; caption: string }
tone'default' | 'brand' | 'success' | 'warning' | 'danger'
validation'error' | 'success' | 'none'
valuestring
variant'classic' | 'surface' | 'soft' | 'outlined' | 'filled' | 'flushed' | 'minimal' | 'contrast' | 'elevated'

Also accepts the standard HTML and React props of the element it renders (className, style, id, aria-*, data-*, event handlers).

Element: <ui-password-field>​

PasswordField renders the ui-password-field custom element from @editora/ui-core, which can also be used without React.

Attributes: aria-describedby, aria-description, aria-label, revealable, show-strength

Events: change, clear, input, strength-change, visibility-change