@hhgtech/hhg-components
Version:
Hello Health Group common components
22 lines (21 loc) • 966 B
TypeScript
import React, { DetailedHTMLProps, InputHTMLAttributes } from 'react';
import type * as PhoneInputUtilsType from 'react-phone-number-input';
export type PhoneProps = Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, 'onChange'> & {
inputId?: string;
isError?: boolean;
placeholder?: string;
countries?: PhoneInputUtilsType.Country[];
selectedCountry?: PhoneInputUtilsType.Country;
defaultCountry?: PhoneInputUtilsType.Country;
countryCallingCodeEditable?: boolean;
defaultValue?: string;
label?: string;
name?: string;
value?: string;
error?: string;
withFloatingLabel?: boolean;
onChange?: (v: string) => void;
arrowComponent?: () => JSX.Element;
flagComponent?: (props: PhoneInputUtilsType.FlagProps) => JSX.Element;
};
export declare const Phone: React.ForwardRefExoticComponent<Omit<PhoneProps, "ref"> & React.RefAttributes<React.Ref<unknown>>>;