@porsche-design-system/components-react
Version:
Porsche Design System is a component library designed to help developers create the best experience for software or services distributed by Dr. Ing. h.c. F. Porsche AG.
177 lines (176 loc) • 5 kB
TypeScript
import type { BaseProps } from '../../BaseProps';
import type { InputPasswordAutoComplete, BreakpointCustomizable, InputPasswordBlurEventDetail, InputPasswordChangeEventDetail, InputPasswordInputEventDetail, InputPasswordState, Theme } from '../types';
export type PInputPasswordProps = BaseProps & {
/**
* Specifies whether the input can be autofilled by the browser
*/
autoComplete?: InputPasswordAutoComplete;
/**
* Displays as compact version.
*/
compact?: boolean;
/**
* The description text.
*/
description?: string;
/**
* Marks the password input as disabled.
*/
disabled?: boolean;
/**
* The id of a form element the password input should be associated with.
*/
form?: string;
/**
* Show or hide label and description text. For better accessibility it is recommended to show the label.
*/
hideLabel?: BreakpointCustomizable<boolean>;
/**
* The label text.
*/
label?: string;
/**
* The max length of the password input.
*/
maxLength?: number;
/**
* The message styled depending on validation state.
*/
message?: string;
/**
* The min length of the password input.
*/
minLength?: number;
/**
* The name of the password input.
*/
name: string;
/**
* Emitted when the password input has lost focus.
*/
onBlur?: (event: CustomEvent<InputPasswordBlurEventDetail>) => void;
/**
* Emitted when the password input loses focus after its value was changed.
*/
onChange?: (event: CustomEvent<InputPasswordChangeEventDetail>) => void;
/**
* Emitted when the value has been changed as a direct result of a user action.
*/
onInput?: (event: CustomEvent<InputPasswordInputEventDetail>) => void;
/**
* The placeholder text.
*/
placeholder?: string;
/**
* Specifies whether the password input should be read-only.
*/
readOnly?: boolean;
/**
* Marks the password input as required.
*/
required?: boolean;
/**
* The validation state.
*/
state?: InputPasswordState;
/**
* Adapts the color depending on the theme.
*/
theme?: Theme;
/**
* Show or hide password toggle for `input type="password"`.
*/
toggle?: boolean;
/**
* The password input value.
*/
value?: string;
};
export declare const PInputPassword: import("react").ForwardRefExoticComponent<import("react").DOMAttributes<{}> & Pick<import("react").HTMLAttributes<{}>, "suppressHydrationWarning" | "autoFocus" | "className" | "dir" | "hidden" | "id" | "inert" | "lang" | "slot" | "style" | "tabIndex" | "title" | "translate" | "role"> & {
/**
* Specifies whether the input can be autofilled by the browser
*/
autoComplete?: InputPasswordAutoComplete;
/**
* Displays as compact version.
*/
compact?: boolean;
/**
* The description text.
*/
description?: string;
/**
* Marks the password input as disabled.
*/
disabled?: boolean;
/**
* The id of a form element the password input should be associated with.
*/
form?: string;
/**
* Show or hide label and description text. For better accessibility it is recommended to show the label.
*/
hideLabel?: BreakpointCustomizable<boolean>;
/**
* The label text.
*/
label?: string;
/**
* The max length of the password input.
*/
maxLength?: number;
/**
* The message styled depending on validation state.
*/
message?: string;
/**
* The min length of the password input.
*/
minLength?: number;
/**
* The name of the password input.
*/
name: string;
/**
* Emitted when the password input has lost focus.
*/
onBlur?: (event: CustomEvent<InputPasswordBlurEventDetail>) => void;
/**
* Emitted when the password input loses focus after its value was changed.
*/
onChange?: (event: CustomEvent<InputPasswordChangeEventDetail>) => void;
/**
* Emitted when the value has been changed as a direct result of a user action.
*/
onInput?: (event: CustomEvent<InputPasswordInputEventDetail>) => void;
/**
* The placeholder text.
*/
placeholder?: string;
/**
* Specifies whether the password input should be read-only.
*/
readOnly?: boolean;
/**
* Marks the password input as required.
*/
required?: boolean;
/**
* The validation state.
*/
state?: InputPasswordState;
/**
* Adapts the color depending on the theme.
*/
theme?: Theme;
/**
* Show or hide password toggle for `input type="password"`.
*/
toggle?: boolean;
/**
* The password input value.
*/
value?: string;
} & {
children?: import("react").ReactNode | undefined;
} & import("react").RefAttributes<HTMLElement>>;