Text input component with icon, affix, label and hint text

Hierarchy

  • FormFieldInterface<this> & LitElement<this> & SizeInterface<this> & ContourableInterface<this> & InteractiveInterface<this>
    • ZetaTextInput

Other

checked?: boolean
disabled: boolean
error: boolean = false

Whether text field is in error state.

errorText: string = ""

Error hint text

Shown if error, replaces hintText.

hintText: string = ""

Hint text shown below text field.

if error, then errorText is shown instead.

indeterminate: boolean
input: HTMLInputElement
internals: ElementInternals
label: string = ""

Label shown above text field.

leadingIcon?: ZetaIconName

Leading icon name.

name: string
prefix: string = ""

Prefix text.

required: boolean
rounded: boolean
size: "small" | "medium" | "large"
suffix: string = ""

Suffix text.

trailingIcon?: ZetaIconName

Trailing icon name.

type:
    | "text"
    | "textarea"
    | "password"
    | "time"
    | "date" = "text"

Type of field

value: string
shadowRootOptions: ShadowRootInit = ...
styles: CSSResultGroup[] = ...

rendering

  • Invoked on each update to perform rendering tasks. This method may return any value renderable by lit-html's ChildPart - typically a TemplateResult. Setting properties inside this method will not trigger the element to update.

    Returns TemplateResult<1>