import { default as React } from 'react'; import { AddressType, AllowedDocumentType, AllowedValueWithCode, AuthParams, CompanyOfficerType, CompanyOfficersDetails, Country, File, FilePayload, ID, User } from '@zeniai/client-epic-state'; import { CountrySelectFieldValue } from '../../../address/addressHelper'; import { AddressValueFieldType } from '../../../formElements/addressValueField/AddressValueField'; import { FormSectionProps } from '../../../formElements/common/formSection'; import { Name } from '../../../formElements/nameField/NameField'; import { SelectDocumentType } from '../../../formElements/selectDocumentField/SelectDocumentField'; import { SingleSelectFieldValue } from '../../../spendManagement/billPay/addOrEditBill/sections/formElements/singleSelect/SingleSelectField'; import { VerificationProductType } from '../commonTypes'; /** * Component & its Props */ export interface CompanyOfficerDetailsSectionProps extends FormSectionProps { allNationalityCountries: Country[]; allOfficers: User[]; authParams: AuthParams; companyOfficerData: Record; companyTitles: AllowedValueWithCode[]; filesEndPoint: string; isRefreshingViewInBackground: boolean; productType: VerificationProductType; /** * Per-officer field-name set populated by Zeni AI doc autofill (passport / * driving license / SSN). When a key appears here, this section pushes the * matching value from `companyOfficerData[selectedOfficer]` into the form * via `setValue`. Sparkle ✦ icons render next to those fields too. * * Pass `companyOfficerLocalData[officerType].autoFilledFields ?? []` from the * screen. Optional — when omitted, autofill is a no-op (back-compat). */ autoFilledFieldsByOfficer?: Partial>; connectedAccountProvider?: string; elementsContainerStyle?: React.CSSProperties; enableOtpVerification?: boolean; /** V3 onboarding hides the "Optional" pill next to the header. */ hideOptionalLabel?: boolean; /** V3 onboarding suppresses the section sub-header line. */ hideSubHeader?: boolean; isCompleted?: boolean; isForTreasury?: boolean; isOverlay?: boolean; isPopupOpen?: boolean; optionalFields?: FormDataKeys[]; /** * File IDs currently being parsed by the AI autofill epic. Drives the * shimmer overlay on `SelectDocumentField`. Pass * `setupViewState.parsingDocumentFileIds` from the screen. */ parsingDocumentFileIds?: ID[]; sectionHeader?: string; sectionSubHeader?: string; showCompletedIcon?: boolean; showInfoTooltip?: boolean; showOfficerSelect?: boolean; showVerificationTag?: boolean; style?: React.CSSProperties; verifiedPhoneNumber?: string; onGetOtp: (phoneNumber: string) => void; onOfficerAddressClick: (addressType: AddressType) => void; onResendOtp: (otpChallenge: string) => void; onVerifyOtp: (code: string, otpChallenge: string) => void; openPopup: (isPhotoPopUpOpen: boolean) => void; onDeleteFile?: (fileId: ID) => void; onEditFileName?: (fileId: ID, name: string) => void; /** * Fired when a new identity document (passport / driving license / SSN card) * is uploaded for the selected officer. Connect to * `parseUploadedKycDocument` action to trigger Zeni AI extraction + * autofill. */ onIdentityDocumentUploadedForAutofill?: (params: { documentType: AllowedDocumentType; fileId: ID; officerType: CompanyOfficerType; }) => void; onPhoneVerified?: (phoneNumber: string) => void; updateFilesEntity?: (files: FilePayload[]) => void; } export declare function CompanyOfficerDetailsSection({ companyOfficerData, isDisabled: isSectionDisabled, allOfficers, allNationalityCountries, isRefreshingViewInBackground, connectedAccountProvider, style, elementsContainerStyle, isPopupOpen, sectionId, filesEndPoint, authParams, showInfoTooltip, isCompleted, showCompletedIcon, showOfficerSelect, showVerificationTag, isForTreasury, isOverlay, productType, companyTitles, sectionHeader, sectionSubHeader, hideOptionalLabel, hideSubHeader, optionalFields, autoFilledFieldsByOfficer, parsingDocumentFileIds, onOfficerAddressClick, onDeleteFile, onEditFileName, onIdentityDocumentUploadedForAutofill, updateFilesEntity, openPopup, onGetOtp, onVerifyOtp, onResendOtp, verifiedPhoneNumber, onPhoneVerified, }: CompanyOfficerDetailsSectionProps): import("react/jsx-runtime").JSX.Element; /** * Form Data Type */ export interface CompanyOfficerDetailsSectionFormData { email: string; fileIds: ID[]; isSelectedForVerification: boolean; name: Name; officerType: CompanyOfficerType; phone: string; role: SingleSelectFieldValue; selectDocument: SelectDocument; dob?: Date; isPhoneVerified?: boolean; nationalityCountryCode?: CountrySelectFieldValue; officerAddress?: AddressValueFieldType; otpChallenge?: string; ownership?: number; ssn?: string; syncToken?: string; treasuryUserVerificationStatus?: AllowedValueWithCode; userId?: ID; userVerificationStatus?: AllowedValueWithCode; } interface SelectDocument { back?: File; front?: File; selectDocumentType?: SelectDocumentType; } type FormDataKeys = keyof CompanyOfficerDetailsSectionFormData; declare const subFieldUniqueName: (sectionId: string, key: FormDataKeys, subKey: "firstName" | "lastName") => `${string}.email` | `${string}.phone` | `${string}.fileIds` | `${string}.isPhoneVerified` | `${string}.syncToken` | `${string}.otpChallenge` | `${string}.name.firstName` | `${string}.name.lastName` | `${string}.ssn` | `${string}.role` | `${string}.userId` | `${string}.nationalityCountryCode` | `${string}.isSelectedForVerification` | `${string}.officerType` | `${string}.selectDocument` | `${string}.dob` | `${string}.officerAddress` | `${string}.ownership` | `${string}.treasuryUserVerificationStatus` | `${string}.userVerificationStatus`; export type FormDataKeyUniqueNames = ReturnType; export {};