import React from 'react'; import { StyleProp, TextStyle, ViewStyle } from 'react-native'; import { Ux4gInputFieldSize, Ux4gInputFieldStatus } from '../input-field/InputField'; /** * Static utility to validate Aadhaar number using Verhoeff algorithm and UIDAI rules. */ export declare const validateAadhaar: (aadhaar: string) => boolean; /** * Utility to format Aadhaar digits with 4-4-4 spacing and optional 'X' masking. */ export declare const formatAadhaar: (digits: string, masked?: boolean, maskAll?: boolean) => string; export interface Ux4gAadhaarInputFieldProps { /** * Current formatted Aadhaar string (`XXXX XXXX XXXX`). */ value: string; /** * Callback triggered when the formatted text inside the field changes. */ onValueChange: (value: string) => void; /** * Size of the input field (`small`, `medium`, `large`). * @default 'medium' */ size?: Ux4gInputFieldSize; /** * Validation status (`defaultStatus`, `error`, `warning`, `success`). * @default 'defaultStatus' */ status?: Ux4gInputFieldStatus; /** * Optional label displayed above the input box. * @default 'Aadhaar Number' */ label?: string; /** * Whether the field is required (displays red `*`). * @default false */ required?: boolean; /** * Placeholder hint text inside the input box when empty. * @default 'XXXX XXXX XXXX' */ placeholder?: string; /** * Caption or validation helper text displayed below the input box. * @default 'Enter your 12-digit Aadhaar number' */ caption?: string; /** * Optional leading widget/icon inside the left side of the input box. */ leadingIcon?: React.ReactNode; /** * Optional trailing widget/icon inside the right side of the input box. */ trailingIcon?: React.ReactNode; /** * Callback triggered when `trailingIcon` is pressed. */ onTrailingIconPressed?: () => void; /** * Whether to display the eye toggle icon for masking / unmasking the Aadhaar number with 'X'. * @default false */ showMaskToggle?: boolean; /** * Whether the Aadhaar number is currently masked (controlled mode). */ isMasked?: boolean; /** * Initial masked state when uncontrolled and `showMaskToggle` is enabled. * @default false */ defaultMasked?: boolean; /** * Callback triggered when the mask eye toggle is pressed. */ onMaskToggle?: (isMasked: boolean) => void; /** * Whether to mask all digits (`XXXX XXXX XXXX`) instead of only first 8 digits. * @default true */ maskAll?: boolean; /** * Whether the input field is interactive (`true`) or disabled (`false`). * @default true */ enabled?: boolean; /** * Whether the input field is read-only (`true`) or editable (`false`). * @default false */ readOnly?: boolean; /** * Optional override for the input value text style. */ style?: StyleProp; /** * Optional override for the label text style. */ labelStyle?: StyleProp; /** * Optional override for the placeholder text style. */ placeholderStyle?: StyleProp; /** * Optional override for the caption text style. */ captionStyle?: StyleProp; /** * Optional style for the outermost container wrapper. */ containerStyle?: StyleProp; /** * Test identifier. */ testID?: string; } /** * **Ux4gAadhaarInputField** * * A specialized input field for Aadhaar numbers (12 digits), mirroring the Flutter * `Ux4gAadhaarInputField` (`aadhaar_input_field.dart`). * * Features: * - Auto-formatting (`XXXX XXXX XXXX`) up to 12 digits (14 characters with spaces). * - Numeric-only input restriction with 'X' cross character masking support. * - Built-in verification against UIDAI rules (no `0` or `1` leading digit) and Verhoeff checksum algorithm. * - Automatically transitions to `success` ("Valid Aadhaar number") or `error` ("Please enter a valid Aadhaar number") when 12 digits are completed if `status === 'defaultStatus'`. * - Optional eye toggle for masking/unmasking (`showMaskToggle`) with cross 'X' display. */ export declare const Ux4gAadhaarInputField: React.FC & { validateAadhaar: (aadhaar: string) => boolean; formatAadhaar: (digits: string, masked?: boolean, maskAll?: boolean) => string; }; //# sourceMappingURL=AadhaarInputField.d.ts.map