Represents a text slot.

interface ITextSlot {
    autoFocus?: boolean;
    description?: string;
    dirty: boolean;
    disabled: boolean;
    groupRef?: (element?: null | HTMLDivElement) => void;
    incorrect: null | string;
    inputAutocomplete?: "new-password" | "on" | "off" | "false";
    inputFormatter?: (input: string) => string;
    inputFormatterAllowed?: RegExp | (char: string, idx: number) => boolean;
    inputFormatterReplace?: (char: string) => null | string;
    inputFormatterSymbol?: string;
    inputFormatterTemplate?: string;
    inputMode?:
        | "search"
        | "text"
        | "email"
        | "tel"
        | "url"
        | "none"
        | "numeric"
        | "decimal";
    inputPattern?: string;
    inputRef?: (element?: null | HTMLInputElement) => void;
    inputRows?: number;
    inputType?:
        | "number"
        | "color"
        | "search"
        | "text"
        | "date"
        | "email"
        | "month"
        | "password"
        | "tel"
        | "time"
        | "url"
        | "week";
    invalid: null
    | string;
    labelShrink?: boolean;
    leadingIcon?: any;
    leadingIconClick?: (
        value: Value,
        data: any,
        payload: any,
        onValueChange: (v: Value) => void,
        onChange: (data: any) => void,
    ) => void;
    leadingIconRipple?: boolean;
    leadingIconTabIndex?: number;
    loading: boolean;
    name: string;
    onChange: (v: any, config?: { skipReadonly?: boolean }) => void;
    outlined?: boolean;
    placeholder?: string;
    readonly?: boolean;
    title?: string;
    trailingIcon?: any;
    trailingIconClick?: (
        value: Value,
        data: any,
        payload: any,
        onValueChange: (v: Value) => void,
        onChange: (data: any) => void,
    ) => void;
    trailingIconRipple?: boolean;
    trailingIconTabIndex?: number;
    validation?: IValidation;
    value: any;
}

Hierarchy

  • ITextBase
    • ITextSlot

Properties

autoFocus?: boolean

Specifies if the field should be automatically focused.

description?: string

Returns the "description" property value of the given field object.

The type of the field object.

The type of the data associated with the field.

The type of the payload object associated with the field.

The field object from which to retrieve the "description" property.

The value of the "description" property.

dirty: boolean
disabled: boolean

Represents the disabled property of a field in a form.

groupRef?: (element?: null | HTMLDivElement) => void

Represents the reference to a group in a field.

incorrect: null | string
inputAutocomplete?: "new-password" | "on" | "off" | "false"

Represents an optional input autocomplete feature for a field.

The type of data associated with the field.

The type of payload associated with the field.

inputFormatter?: (input: string) => string

Represents the input formatter function for a specific field in the Data object.

inputFormatterAllowed?: RegExp | (char: string, idx: number) => boolean

Represents the allowed input formatters for a field.

inputFormatterReplace?: (char: string) => null | string

Defines the input formatter replace configuration for a field.

inputFormatterSymbol?: string

Specifies the input formatter symbol for a given field.

inputFormatterTemplate?: string

Represents an input formatter template used in a field.

inputMode?:
    | "search"
    | "text"
    | "email"
    | "tel"
    | "url"
    | "none"
    | "numeric"
    | "decimal"

The inputMode variable is an optional property that represents the input mode of a field in a form.

inputPattern?: string

Represents the input pattern for a field in a data payload.

inputRef?: (element?: null | HTMLInputElement) => void

Represents the input reference property of a field.

inputRows?: number

Represents the number of input rows required for a field.

inputType?:
    | "number"
    | "color"
    | "search"
    | "text"
    | "date"
    | "email"
    | "month"
    | "password"
    | "tel"
    | "time"
    | "url"
    | "week"

Represents the input type of a field.

The type of data being handled by the field.

The type of payload associated with the field.

invalid: null | string
labelShrink?: boolean

Shrink option for labels.

leadingIcon?: any

The leadingIcon property represents the leading icon of a field.

leadingIconClick?: (
    value: Value,
    data: any,
    payload: any,
    onValueChange: (v: Value) => void,
    onChange: (data: any) => void,
) => void

Represents the leading icon click event handler for a field in a form.

Type declaration

    • (
          value: Value,
          data: any,
          payload: any,
          onValueChange: (v: Value) => void,
          onChange: (data: any) => void,
      ): void
    • Parameters

      • value: Value
      • data: any
      • payload: any
      • onValueChange: (v: Value) => void
      • onChange: (data: any) => void

      Returns void

      • Nothing is returned from this function.
leadingIconRipple?: boolean

Represents the configuration for the leading icon ripple effect.

leadingIconTabIndex?: number
loading: boolean
name: string
onChange: (v: any, config?: { skipReadonly?: boolean }) => void
outlined?: boolean

Type definition to pick the outlined property from a given IField type.

The type of the IField object.

The property to be picked from IField.

placeholder?: string

A type definition representing the placeholder property of a given field.

The type of the field data.

The type of the payload for the field.

The type of the field.

readonly?: boolean

Gets the value of the "readonly" property from the provided object.

The type of the object that contains the "readonly" property.

The type of the "readonly" property.

The object to get the "readonly" property from.

  • The value of the "readonly" property.
title?: string

Type definition for the title property of an object.

The type of the object from which to pick the property.

The literal type of the property name to pick.

T - The type of the object from which to pick the property.

K - The literal type of the property name to pick.

The object from which to pick the property.

the value of the picked property.

trailingIcon?: any

Represents the trailing icon configuration for a field.

trailingIconClick?: (
    value: Value,
    data: any,
    payload: any,
    onValueChange: (v: Value) => void,
    onChange: (data: any) => void,
) => void

The trailingIconClick property is an optional property that represents a callback function to be executed when the trailing icon of a field is clicked.

This property is of type PickProp<IField<Data, Payload>, "trailingIconClick">, where IField<Data, Payload> is a generic type representing a field with Data and Payload types.

Type declaration

    • (
          value: Value,
          data: any,
          payload: any,
          onValueChange: (v: Value) => void,
          onChange: (data: any) => void,
      ): void
    • Parameters

      • value: Value
      • data: any
      • payload: any
      • onValueChange: (v: Value) => void
      • onChange: (data: any) => void

      Returns void

trailingIconRipple?: boolean

Represents the option to enable or disable the trailing icon ripple effect.

trailingIconTabIndex?: number
validation?: IValidation

Validation factory config

Type representing the field object.

Type representing the data object.

Type representing the payload object.

The value of the "validation" property.

value: any