File

libs/core/dynamic-form/phone-input/src/phone-input.model.ts

Extends

DfInteractiveBaseConfig

Index

Properties

Properties

areaCodeLabel (Optional)
Type string
Description

Set the text at the top of the dropdown and aria-label of area code field. The default value is 'Area Code'.

countryCode (Optional)
Type CountryCode
Description

The default country code for the phone input.

errorMessage (Optional)
Type string
Description

Custom error message for validation

label
Type string
Description

This field's label. It's translatable by default and supports string interpolation.

lineNumberLabel (Optional)
Type string
Description

The aria-label of line number field.

placeholder (Optional)
Type string
Description

Placeholder to be displayed in the field when the input is empty. It's translatable by default and supports string interpolation.

type
Description

Specifies the type of the field as PHONE_INPUT.

import { DfInteractiveBaseConfig } from '@allianz/taly-core/dynamic-form';
import { CountryCode } from 'libphonenumber-js';

export const DfPhoneInputTypeName = 'PHONE_INPUT';
export interface DfPhoneInputConfig extends DfInteractiveBaseConfig {
  /**
   * Specifies the type of the field as `PHONE_INPUT`.
   */
  type: typeof DfPhoneInputTypeName;

  /**
   * This field's label.
   * It's translatable by default and supports string interpolation.
   * @examples ["My label", "My label {$['bb-pgr-simple'].person.firstName}"]
   */
  label: string;

  /**
   * Placeholder to be displayed in the field when the input is empty.
   * It's translatable by default and supports string interpolation.
   * @examples ["Placeholder", "Placeholder with dynamic value {$['bb-pgr-simple'].date}"]
   */
  placeholder?: string;

  /**
   * Set the text at the top of the dropdown and aria-label of area code field. The default value is 'Area Code'.
   */
  areaCodeLabel?: string;

  /**
   * The aria-label of line number field.
   */
  lineNumberLabel?: string;

  /**
   * The default country code for the phone input.
   */
  countryCode?: CountryCode;

  /**
   * Custom error message for validation
   */
  errorMessage?: string;
}

results matching ""

    No results matching ""