import { default as React } from 'react'; import { FormPage } from '../../types/form-config'; import { KybPersonField } from '../../types/theme'; export interface PersonData { firstName?: string; lastName?: string; middleName?: string; dateOfBirth?: string; nationality?: string; email?: string; phone?: string; mobileCountryCode?: string; street?: string; streetNumber?: string; zip?: string; city?: string; country?: string; shareSize?: string | number; directOwnership?: boolean; indirectOwnership?: boolean; controlVIAVotingRights?: boolean; controlByOtherMeans?: boolean; /** Custom-field bag (paramName → string). Mirrors the company applicantAdditionalDatas pattern. */ additionalData?: Record; } export interface PersonFormPageRendererProps { /** FormPage describing which person fields to render and how. */ page: FormPage; /** Current person data (controlled). */ value: PersonData; /** Fired with the next data shape on every change. */ onChange: (next: PersonData) => void; /** Validation errors keyed by person field name (or paramName for custom fields). */ errors?: Partial>; /** Global label-mode default. Per-field `labelMode` overrides this. */ labelMode?: 'label' | 'placeholder'; /** When set, every input is rendered read-only. */ readOnly?: boolean; /** Per-field read-only override (used when editing a person imported from another role). */ readOnlyFields?: KybPersonField[]; } /** * Convenience helper: build a default FormPage from a flat visibleFields/requiredFields pair. * Used as a backward-compat fallback when a tenant hasn't migrated their KYB config to the * richer FormPage shape yet. */ export declare function buildDefaultPersonFormPage(visibleFields: KybPersonField[], requiredFields?: KybPersonField[]): FormPage; /** * Renders a single FormPage of person fields (representative or UBO/director). * Uses the same FormFieldEntry contract as the company applicant form so admins * can configure label/placeholder mode, ordering, colSpan, helpText, displayText, * required, and countriesType per field. */ export declare const PersonFormPageRenderer: React.FC; /** * Lightweight validator that walks a FormPage and returns errors for missing * required fields. Replaces the previous `validatePerson(visibleFields, requiredFields)` API. */ export declare function validatePersonPage(data: PersonData, page: FormPage, t?: (key: string, params?: any) => string): Record; //# sourceMappingURL=PersonFormPageRenderer.d.ts.map