@adyen/kyc-components 4.26.1 → 4.27.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AcceptTermsOfServiceWorkflow-DXSq3XzA.js → AcceptTermsOfServiceWorkflow-CO6qEeAD.js} +4 -4
- package/dist/{Accordion-BAdwrgCR.js → Accordion-CTQfC17W.js} +1 -1
- package/dist/{AccountSetupRejected-BLEWjmc8.js → AccountSetupRejected-CFvogFuo.js} +2 -2
- package/dist/{AdaptiveWorkflow-DwdMyu1A.js → AdaptiveWorkflow-CTKpyw02.js} +22 -22
- package/dist/{AdaptiveWorkflowComponent-DPv1YHos.js → AdaptiveWorkflowComponent-CvTwsWi3.js} +5 -5
- package/dist/{AddressFields-B0QVYM-e.js → AddressFields-vl2AeVHz.js} +33 -72
- package/dist/{Avatar-C2zeqSSB.js → Avatar-yJfk9A6l.js} +1 -1
- package/dist/{BusinessFinancingDropin-evYHYnXE.js → BusinessFinancingDropin-tSylhmJS.js} +123 -55
- package/dist/{BusinessFinancingPage-C_agz96E.js → BusinessFinancingPage-9AcfHWyP.js} +6 -6
- package/dist/{BusinessRegistrationNumberField-DeYcZlQS.js → BusinessRegistrationNumberField-B6w6LvSZ.js} +6 -6
- package/dist/{BusinessRegistrationNumberFieldGroup-D9D0BPdp.js → BusinessRegistrationNumberFieldGroup-CICYxSyn.js} +6 -6
- package/dist/{BusinessTypeSelectionPage-DmgeZsex.js → BusinessTypeSelectionPage-lLt_PL1z.js} +13 -13
- package/dist/{Button-Dwr6jvJZ.js → Button-BYafPrZH.js} +1 -1
- package/dist/{Checkbox-BLyyDG9b.js → Checkbox-DXF-eRBj.js} +8 -8
- package/dist/{ComponentGroup-BLvYZoxp.js → ComponentGroup-DNspJrHk.js} +3 -3
- package/dist/{ConstitutionalDocument-B3o3NLMO.js → ConstitutionalDocument-Dg3dmkpH.js} +19 -26
- package/dist/{ContactDetails-7zYbKJtH.js → ContactDetails-5W0oQVYG.js} +5 -5
- package/dist/{ContextGuidance-C2AXK9Ep.js → ContextGuidance-BrbPzdaI.js} +3 -3
- package/dist/{CountryField-Bl8gp3wu.js → CountryField-DlMYQYfd.js} +4 -4
- package/dist/{Currency-Be6zg8XM.js → Currency-BCJuV60i.js} +16 -10
- package/dist/{CustomerSupport-lUVh_sWN.js → CustomerSupport-Bdg11WcM.js} +29 -16
- package/dist/{DateField-CO2CodgD.js → DateField-DfnBDOVl.js} +4 -4
- package/dist/{DebugModal-l52lDfKB.js → DebugModal-D1RMhAfR.js} +228 -10
- package/dist/{DecisionMakerDetails-9y6Fm96G.js → DecisionMakerDetails-Cv_NdD0z.js} +79 -174
- package/dist/{DecisionMakerDetailsPage-9kRW2Zh8.js → DecisionMakerDetailsPage-dTsh8vkz.js} +9 -9
- package/dist/{DecisionMakers-CYjKftby.js → DecisionMakers-DAhjhaMS.js} +17 -18
- package/dist/{Dropzone-QRtCFpVT.js → Dropzone-rk15b_Tb.js} +7 -7
- package/dist/{EmailField-D-Ndm0JS.js → EmailField-BOX8HtRe.js} +4 -4
- package/dist/{EmbeddedStatus-4YjyzkcD.js → EmbeddedStatus-mdQsQfof.js} +2 -2
- package/dist/{EndStateLayout-C5Pqler-.js → EndStateLayout-B-M90Rnh.js} +2 -2
- package/dist/{EntityAssociation-CS8XqKk-.js → EntityAssociation-B5Zq7_F6.js} +6 -6
- package/dist/{ErrorPanel-DaipnVsu.js → ErrorPanel-BLvDkiVa.js} +10 -17
- package/dist/{GlobalEntryModal-COOjZvh7.js → GlobalEntryModal-DZsHeRPL.js} +439 -298
- package/dist/{GlobalEntryPage-C9SGXXJk.js → GlobalEntryPage-RyQIoaWL.js} +7 -8
- package/dist/{Icon-_YUEZg1p.js → Icon-jVvV1zXc.js} +1 -1
- package/dist/{IdentityNumber-D_cOLEsP.js → IdentityNumber-C8CMJtgD.js} +5 -5
- package/dist/{IdentityNumberFieldGroup-CoLugvku.js → IdentityNumberFieldGroup-Cj5U1Onz.js} +2 -2
- package/dist/{IdentityScreeningWorkflow-B_nLC0Ru.js → IdentityScreeningWorkflow-BCDn25Or.js} +12 -13
- package/dist/{IndividualDropin-CRKk-szG.js → IndividualDropin-B6dY0iN3.js} +149 -231
- package/dist/{IndustryCodeFieldGroup-0vRXN8GP.js → IndustryCodeFieldGroup-B649faYk.js} +5 -5
- package/dist/{InputDate-Cxk_f6Us.js → InputDate-3rYzWzXX.js} +8 -4
- package/dist/{InputText-CObXfKKh.js → InputText-OCbzlaaN.js} +2 -2
- package/dist/{Introduction-CmhxGGzY.js → Introduction-Duow8A7U.js} +6 -6
- package/dist/{InvitedDecisionMakerComponent-BkHurym6.js → InvitedDecisionMakerComponent-BVQ37JLZ.js} +13 -14
- package/dist/{JpAddressFields-CuvfbjX6.js → JpAddressFields-Bh7Bvw__.js} +9 -10
- package/dist/{LegalCompanyNameField-CkINYTFB.js → LegalCompanyNameField-Yj5Fa3-I.js} +5 -5
- package/dist/{LegalRepresentativeDetailsPage-mlE80SrL.js → LegalRepresentativeDetailsPage-C10ojT9w.js} +4 -4
- package/dist/{Link-D0Yqc2r0.js → Link-DwPkGikd.js} +1 -1
- package/dist/{ListItem-DY-qq1lS.js → ListItem-n927geYb.js} +2 -2
- package/dist/{Modal-DnDjAzqZ.js → Modal-jjSjdW5W.js} +3 -3
- package/dist/{Name-Dhj905G8.js → Name-D-A5XBTb.js} +4 -4
- package/dist/{NumberField-BlDjTB0U.js → NumberField-D291GWYR.js} +4 -4
- package/dist/{PatriotActDisclosure-jNLKR-RM.js → PatriotActDisclosure-DMjKJEKH.js} +10 -10
- package/dist/{PayoutDetailsDropin-DO1CtLRd.js → PayoutDetailsDropin-B5MNHR3S.js} +41 -43
- package/dist/{PayoutDetailsPage-C-W1PCRf.js → PayoutDetailsPage-DMAxzS2V.js} +5 -5
- package/dist/{Review-BLcoVl6O.js → Review-BDontauk.js} +6 -6
- package/dist/{RootBusinessDetailsPage-DNZi9Zgj.js → RootBusinessDetailsPage-INMIQvN4.js} +4 -4
- package/dist/{RootBusinessLinesPage-D2IPigk5.js → RootBusinessLinesPage-BiIb7UVU.js} +22 -23
- package/dist/{RootIndividualDetailsPage-Cfa9R28c.js → RootIndividualDetailsPage-BS5BgowF.js} +6 -6
- package/dist/{Select-C0Pp8Jeb.js → Select-BRK2a2V5.js} +92 -92
- package/dist/{SignPCIComponent-I3asF5GE.js → SignPCIComponent-B5JmN8BT.js} +14 -14
- package/dist/{SingpassSelection-C4Ptdwzb.js → SingpassSelection-B84oJmvG.js} +5 -5
- package/dist/{SoleProprietorshipPage-CiI2VKw_.js → SoleProprietorshipPage-C-jxJkmQ.js} +4 -4
- package/dist/{SourceOfFundsPage-DrJqgPMf.js → SourceOfFundsPage-C27vODL5.js} +24 -24
- package/dist/{SourceOfFundsWorkflow-tE06S4__.js → SourceOfFundsWorkflow-DOqaH_wk.js} +4 -4
- package/dist/StateField-CRLgYS1X.js +364 -0
- package/dist/{Step-CLZTcCEQ.js → Step-BTVKO9gW.js} +5 -5
- package/dist/Summary-C9Nr0dot.js +21 -0
- package/dist/{SummarySection-v-mSwYL0.js → SummarySection-D67yguze.js} +5 -19
- package/dist/{Task-CUr-Zb5N.js → Task-BaQ6wqz5.js} +7 -7
- package/dist/{TaskGroup-BGUboNOL.js → TaskGroup-C7lBWbYp.js} +3 -3
- package/dist/{TaskListItem-DMkmZn3B.js → TaskListItem-Cu3fSvOJ.js} +10 -10
- package/dist/{TaskStepperContextProvider-9wlnwii7.js → TaskStepperContextProvider-DiMf4UV6.js} +1 -1
- package/dist/{TaskVerificationStatus-zoxTZ2mt.js → TaskVerificationStatus-C1CllzL1.js} +17 -17
- package/dist/{TaxInformationFieldGroup-CraKcKMs.js → TaxInformationFieldGroup-vQoQHydJ.js} +7 -7
- package/dist/{TaxReportingDropin-B-ywMdBt.js → TaxReportingDropin-CTnL6VMm.js} +13 -15
- package/dist/{TaxReportingWorkflow-BmUdyOKl.js → TaxReportingWorkflow-5_eG0AcD.js} +4 -4
- package/dist/{TermsOfServiceManagement-D1Yv4Z5p.js → TermsOfServiceManagement-xL-xisqE.js} +46 -43
- package/dist/{TextArea-CyFcFhHo.js → TextArea-CcaUENX2.js} +4 -4
- package/dist/{TextField-D61xVlV2.js → TextField-fhhAQSKg.js} +5 -5
- package/dist/{TrustDetailsPage-D2FS-As0.js → TrustDetailsPage-DcNS-XWz.js} +61 -54
- package/dist/{TrustMemberCompanyPage-DDcSOUi2.js → TrustMemberCompanyPage-xtxgO6d4.js} +5 -5
- package/dist/{TrustMemberIndividualPage-CJBz1p3R.js → TrustMemberIndividualPage-BMWAg_eS.js} +4 -4
- package/dist/{TrustMemberRoleAndTypePage-OeN1HW_E.js → TrustMemberRoleAndTypePage-DR3pLJf9.js} +43 -36
- package/dist/{TrustMembersOverview-DkrEZL6_.js → TrustMembersOverview-D-jTaw37.js} +13 -13
- package/dist/{UboTaskItem-Dc6ExVuW.js → UboTaskItem-DsoetWEU.js} +7 -7
- package/dist/{UnincorporatedPartnershipIndividualPage-D0ZYvh8k.js → UnincorporatedPartnershipIndividualPage-3sSr2dCv.js} +4 -4
- package/dist/{UnincorporatedPartnershipMemberCompanyPage-BtapkuO6.js → UnincorporatedPartnershipMemberCompanyPage-s6NiptRo.js} +5 -5
- package/dist/{UnincorporatedPartnershipMemberRoleAndTypePage-CbdYYTQT.js → UnincorporatedPartnershipMemberRoleAndTypePage-Cr6UEryR.js} +9 -9
- package/dist/{UnincorporatedPartnershipMembersOverview-Cs1DHVNP.js → UnincorporatedPartnershipMembersOverview-CbwWOxQs.js} +6 -6
- package/dist/{VerificationErrorAlert-D9sBE-Tj.js → VerificationErrorAlert-Bm7-u85-.js} +3 -3
- package/dist/{WebsiteField-BCoO-m_7.js → WebsiteField-DTlbxzaa.js} +5 -5
- package/dist/{Workflow-driWy_eJ.js → Workflow-DT43cTzE.js} +6 -6
- package/dist/{accountHolderUtils-BAbeRIOy.js → accountHolderUtils-D0E9se-W.js} +1 -1
- package/dist/adyen-business-financing.js +7 -7
- package/dist/adyen-individual-configuration.js +6 -6
- package/dist/adyen-individual-status.js +5 -5
- package/dist/adyen-invited-decision-maker.js +3 -3
- package/dist/adyen-onboarding.js +30 -30
- package/dist/adyen-terms-of-service-management.js +3 -3
- package/dist/adyen-terms-of-service-status.js +3 -3
- package/dist/adyen-transfer-instrument-configuration.js +5 -5
- package/dist/adyen-transfer-instrument-management.js +13 -13
- package/dist/adyen-verification-status.js +3 -3
- package/dist/{bafinUtils-COyCy9xG.js → bafinUtils-CvQzDDfD.js} +519 -531
- package/dist/{constants-fGRziJEH.js → constants-BOu8Hnt9.js} +6 -6
- package/dist/{dropinUtils-cIGIoJvF.js → dropinUtils-DfyQ8xFE.js} +165 -364
- package/dist/en-US-8KLaHQaT.js +7 -0
- package/dist/{en-US-Cz4JoU20.js → en-US-BMMx67Za.js} +16 -2
- package/dist/{en-US-nYL_eSJ-.js → en-US-BfRvYdHX.js} +8 -2
- package/dist/en-US-DGdFfmUC.js +136 -0
- package/dist/{en-US.instructions-BVNIyLRs.js → en-US.instructions-myDXMUbk.js} +2 -1
- package/dist/{error-B9rHWK9Q.js → error-CUHwmdwD.js} +2 -2
- package/dist/formatDataForSummary-BMFPIUER.js +498 -0
- package/dist/{formatValidationError-BJqU7LCU.js → formatValidationError-B5GNhAeh.js} +2 -2
- package/dist/{getDefaultRegistrationNumberType-BcV1GDOs.js → getDefaultRegistrationNumberType-CyaKz1Fj.js} +4 -4
- package/dist/{getProblemsForEntity-mdb3Bfpj.js → getProblemsForEntity-FHk416BA.js} +1 -1
- package/dist/{getTrustedDecisionMakers-D89oYOLp.js → getTrustedDecisionMakers-DByctgob.js} +1 -1
- package/dist/{getValidationError-dcpAlebZ.js → getValidationError-B4YX_EgR.js} +2 -2
- package/dist/{legalArrangementUtils-Crgt_L7h.js → legalArrangementUtils-CHlmmcB8.js} +11 -2
- package/dist/{mapAddressLocalizationToJpAddressSchema-B9pzYF3B.js → mapAddressLocalizationToJpAddressSchema-BrQMDBLX.js} +2 -2
- package/dist/{mapExistingFile-BXfeQxev.js → mapExistingFile-CqbTLZ6i.js} +1 -1
- package/dist/mapJpAddressSchemaToAddressLocalizations-BL4eAlDH.js +19 -0
- package/dist/{mapTransferInstrumentToPayoutAccount-Ba_L9EEB.js → mapTransferInstrumentToPayoutAccount-DhwdciyT.js} +2 -2
- package/dist/{processCapabilities-FL4-KAbd.js → processCapabilities-B75YIdXZ.js} +11 -4
- package/dist/{processValidationErrors-DWdgik5u.js → processValidationErrors-Dtt1FnM2.js} +4 -4
- package/dist/{resolveEnvironment-BnKqnU98.js → resolveEnvironment-CpWP_8og.js} +53 -16
- package/dist/roleMetadata-BW4HRw1l.js +57 -0
- package/dist/style.css +218 -230
- package/dist/styles-DYaAeu4q.js +218 -230
- package/dist/trustMemberType-Ix2sf6e_.js +13 -0
- package/dist/types/api/address/useAddressCleanse.d.ts +2 -0
- package/dist/types/api/address/useRetrieveAddress.d.ts +1 -0
- package/dist/types/api/address/useRetrieveFromPostcodeJp.d.ts +1 -0
- package/dist/types/components/BankAccount/tasks/PayoutDetailsDropin/utils.d.ts +7 -2
- package/dist/types/components/Business/forms/FinancialInformation/mapping/mapFinancialInformationToFinancialReport.d.ts +1 -1
- package/dist/types/components/Business/forms/rules.d.ts +3 -1
- package/dist/types/components/Business/utils/formatDataForSummary.d.ts +2 -1
- package/dist/types/components/EFP/mapping/businessFinancingKeyMappings.d.ts +78 -0
- package/dist/types/components/EFP/tasks/BusinessFinancingDropin/BusinessFinancingFinancialInformation.d.ts +3 -0
- package/dist/types/components/EFP/tasks/BusinessFinancingDropin/types.d.ts +2 -1
- package/dist/types/components/EFP/tasks/BusinessFinancingDropin/utils.d.ts +6 -3
- package/dist/types/components/EFP/tasks/BusinessFinancingDropin/validate.d.ts +3 -0
- package/dist/types/components/GlobalEntry/fields/DbaQuestionnaire/DbaQuestionnaire.d.ts +3 -0
- package/dist/types/components/GlobalEntry/fields/DbaQuestionnaire/types.d.ts +5 -0
- package/dist/types/components/GlobalEntry/fields/LlcQuestionnaire/LlcQuestionnaire.d.ts +3 -0
- package/dist/types/components/GlobalEntry/fields/LlcQuestionnaire/types.d.ts +5 -0
- package/dist/types/components/GlobalEntry/fields/PaperworkQuestionnaire/PaperworkQuestionnaire.d.ts +1 -6
- package/dist/types/components/GlobalEntry/fields/PaperworkQuestionnaire/fieldConfig.d.ts +11 -0
- package/dist/types/components/GlobalEntry/fields/PaperworkQuestionnaire/types.d.ts +6 -1
- package/dist/types/components/GlobalEntry/fields/Questionnaire/Questionnaire.d.ts +2 -0
- package/dist/types/components/GlobalEntry/fields/Questionnaire/types.d.ts +17 -0
- package/dist/types/components/GlobalEntry/fields/TrustQuestionnaire/TrustQuestionnaire.d.ts +3 -0
- package/dist/types/components/GlobalEntry/fields/TrustQuestionnaire/types.d.ts +5 -0
- package/dist/types/components/GlobalEntry/forms/EntityInformation/EntityInformation.d.ts +1 -3
- package/dist/types/components/GlobalEntry/forms/EntityInformation/types.d.ts +1 -2
- package/dist/types/components/GlobalEntry/forms/RegistrationInformation/types.d.ts +5 -1
- package/dist/types/components/GlobalEntry/mapping/globalEntryKeyMapping.d.ts +0 -3
- package/dist/types/components/GlobalEntry/mapping/mapGlobalEntrySchemaToLegalEntity.d.ts +2 -3
- package/dist/types/components/GlobalEntry/mapping/mapLegalEntityToGlobalEntrySchema.d.ts +1 -6
- package/dist/types/components/GlobalEntry/rules.d.ts +5 -2
- package/dist/types/components/GlobalEntry/utils/getAvailableCompanyStructures.d.ts +2 -1
- package/dist/types/components/GlobalEntry/utils/submitGlobalEntry.d.ts +1 -4
- package/dist/types/components/GlobalEntry/utils/utils.d.ts +7 -4
- package/dist/types/components/Individual/forms/AdditionalPersonalDetails/AdditionalPersonalDetails.types.d.ts +1 -2
- package/dist/types/components/Individual/forms/Individual.rules.d.ts +7 -6
- package/dist/types/components/Individual/helpers/findRelevantTaxInformation.d.ts +8 -2
- package/dist/types/components/Individual/helpers/getSubmittableTaxInformation.d.ts +20 -0
- package/dist/types/components/Individual/mapping/mapIndividualSchemaToLegalEntity.d.ts +5 -3
- package/dist/types/components/Individual/tasks/DecisionMakers/DecisionMakerDetails/utils.d.ts +6 -67
- package/dist/types/components/Individual/tasks/IndividualDropin/IndividualSummary.d.ts +27 -0
- package/dist/types/components/Individual/utils/formatDataForSummary.d.ts +49 -0
- package/dist/types/components/Shared/FormFlow/FormFlow.d.ts +1 -1
- package/dist/types/components/Shared/FormFlow/FormFlow.types.d.ts +0 -5
- package/dist/types/components/Shared/Summary/Summary.d.ts +10 -7
- package/dist/types/components/Shared/Summary/types.d.ts +3 -21
- package/dist/types/components/Shared/SummarySection/SummaryBulletList.d.ts +8 -0
- package/dist/types/components/Shared/devex/DebugListener/DebugTheme.d.ts +2 -0
- package/dist/types/components/Shared/devex/DebugListener/customTheme.d.ts +49 -0
- package/dist/types/components/Shared/fields/RegistrationAndOperationalAddressFields/types.d.ts +2 -0
- package/dist/types/components/Shared/fields/RegistrationAndOperationalAddressFields/utils.d.ts +2 -4
- package/dist/types/components/Shared/fields/ReportedValueOptionField/types.d.ts +3 -0
- package/dist/types/components/Shared/forms/Address/constants.d.ts +2 -0
- package/dist/types/components/Shared/forms/Address/localized/jp/JpAddressFields.d.ts +2 -9
- package/dist/types/components/Shared/forms/Address/localized/jp/mapAddressLocalizationToJpAddressSchema.d.ts +2 -2
- package/dist/types/components/Shared/forms/Address/localized/jp/mapJpAddressSchemaToAddressLocalizations.d.ts +2 -2
- package/dist/types/components/Shared/forms/Address/localized/jp/mapJpAddressSummary.d.ts +2 -4
- package/dist/types/components/Shared/forms/Address/rules.d.ts +13 -0
- package/dist/types/components/Shared/forms/Address/types.d.ts +7 -1
- package/dist/types/components/Shared/forms/Address/utils.d.ts +5 -11
- package/dist/types/components/Trust/forms/Trust/rules.d.ts +3 -1
- package/dist/types/components/Trust/tasks/RoleAndTypeDropin/formatRoleAndEntityTypeSummary.d.ts +2 -3
- package/dist/types/components/Trust/utils/formatDataForSummary.d.ts +2 -1
- package/dist/types/core/EmbedShell/EmbedShell.d.ts +4 -1
- package/dist/types/core/EmbedShell/useTheme.d.ts +9 -0
- package/dist/types/embeds/onboarding/adyen-onboarding.d.ts +1 -1
- package/dist/types/embeds/onboarding/adyen-onboarding.types.d.ts +8 -0
- package/dist/types/hooks/useStoredStateOrProvince.d.ts +9 -0
- package/dist/types/types/datasets/state-code.d.ts +36 -1
- package/dist/types/types/form-rules.d.ts +2 -2
- package/dist/types/utils/analytics/getPrefilledDetails.d.ts +3 -0
- package/dist/types/utils/entityStatusUtil.d.ts +1 -1
- package/dist/types/utils/fieldConfigurations.d.ts +1 -1
- package/dist/types/utils/legalArrangementUtils.d.ts +2 -0
- package/dist/{types-BymnGWO9.js → types-DVMWWwBT.js} +1 -1
- package/dist/{form-rules-CZbkNMEw.js → unincorporatedPartnership-CiU2fnqv.js} +38 -4
- package/dist/{useBusinessDetailsData-BJau7oMt.js → useBusinessDetailsData-BtEHoBoN.js} +100 -90
- package/dist/{useCanSeeIntroduction-BQuCt-eO.js → useCanSeeIntroduction-kxOGIxnh.js} +2 -2
- package/dist/useCreateLegalEntity-CgzVD39K.js +24 -0
- package/dist/{useDataMissingRemediations-DKjYzfe2.js → useDataMissingRemediations-BfC7ECSn.js} +1 -1
- package/dist/{useForm-VDjedfk9.js → useForm-CiHfxEX0.js} +3 -3
- package/dist/{useHideTaskStepper-BgCN--mG.js → useHideTaskStepper-Betx9MGy.js} +1 -1
- package/dist/{useId-Cs-bSalH.js → useId-ChrmzN7R.js} +2 -2
- package/dist/{useNavigate-CKp2oemi.js → useNavigate-xbrKpFCu.js} +33 -33
- package/dist/{useSalesChannels-D0q-Vat7.js → useSalesChannels-C2qQmPGf.js} +1 -1
- package/dist/{useTaskLandedEvent-QBmeEeS6.js → useTaskLandedEvent-Brv74FDb.js} +1 -1
- package/dist/{useTrustMembers-COumqoMC.js → useTrustMembers-BA5fCul_.js} +3 -3
- package/dist/{useUnincorporatedPartnershipMembers-DcfQJdVZ.js → useUnincorporatedPartnershipMembers-J6rxK5Ie.js} +2 -2
- package/dist/{utils-BFxg3gPM.js → utils-ChZNfG5_.js} +1 -1
- package/dist/{utils-BiPEtEaV.js → utils-ClAXyRqf.js} +4 -5
- package/dist/{utils-B6TRzLRs.js → utils-Do6-kryk.js} +3 -3
- package/dist/utils-VV2acmQG.js +49 -0
- package/dist/{validate-Dt3Xmp_L.js → validate-BHOzYoxU.js} +26 -2
- package/dist/{validate-BN38Qq-w.js → validate-D5990ODb.js} +20 -9
- package/dist/{validate-D3JIeysp.js → validate-Dtiozjlb.js} +4 -4
- package/dist/{validate-_7WKym8c.js → validate-NJNmUaTh.js} +11 -5
- package/dist/{validateExtractionResult-IRRMwcNi.js → validateExtractionResult-D3AuQo5-.js} +3 -3
- package/package.json +6 -5
- package/dist/Image-CxnjHtP1.js +0 -33
- package/dist/List-qvNxW9lm.js +0 -72
- package/dist/StateField-BBGSo1NG.js +0 -296
- package/dist/en-US-U0d3NI20.js +0 -7
- package/dist/mapJpAddressSchemaToAddressLocalizations-kHaGv8kC.js +0 -75
- package/dist/mapLegalEntityToIndividualSchema-D6qGKj-2.js +0 -254
- package/dist/trustMemberGuidance-BpeDHAJP.js +0 -27
- package/dist/types/components/Shared/NewSummary/NewSummary.d.ts +0 -10
- package/dist/types/components/Shared/Summary/summaryItem.d.ts +0 -17
- package/dist/types/components/Shared/forms/Address/localized/jp/jpAddressSchema.d.ts +0 -17
- package/dist/unincorporatedPartnership-BbNowjM2.js +0 -11
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
try {
|
|
2
2
|
let e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
|
|
3
|
-
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "
|
|
3
|
+
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "704916a4-f992-4cc0-9e7d-dd2ecda40c7e", e._sentryDebugIdIdentifier = "sentry-dbid-704916a4-f992-4cc0-9e7d-dd2ecda40c7e");
|
|
4
4
|
} catch (e) {}
|
|
5
5
|
import { r as useTranslation } from "./translation-CpH8D2NK.js";
|
|
6
|
-
import {
|
|
7
|
-
import { n as IconButton } from "./Button-
|
|
8
|
-
import { i as useToggleContext } from "./Checkbox-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
6
|
+
import { ot as isEmpty } from "./resolveEnvironment-CpWP_8og.js";
|
|
7
|
+
import { n as IconButton } from "./Button-BYafPrZH.js";
|
|
8
|
+
import { i as useToggleContext } from "./Checkbox-DXF-eRBj.js";
|
|
9
|
+
import { o as Field, t as Select } from "./Select-BRK2a2V5.js";
|
|
10
|
+
import { c as List } from "./dropinUtils-DfyQ8xFE.js";
|
|
11
11
|
import { useEffect, useMemo, useRef, useState } from "preact/hooks";
|
|
12
12
|
import { Fragment, jsx, jsxs } from "preact/jsx-runtime";
|
|
13
13
|
import { signal } from "@preact/signals";
|
|
@@ -1,29 +1,23 @@
|
|
|
1
1
|
try {
|
|
2
2
|
let e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
|
|
3
|
-
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "
|
|
3
|
+
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "87cfa28e-bdd3-4513-8219-8ef1e3b10808", e._sentryDebugIdIdentifier = "sentry-dbid-87cfa28e-bdd3-4513-8219-8ef1e3b10808");
|
|
4
4
|
} catch (e) {}
|
|
5
5
|
import { r as useTranslation } from "./translation-CpH8D2NK.js";
|
|
6
|
-
import {
|
|
6
|
+
import { E as datasetIdentifier, G as NO_ALPHABET_REGEX, T as useDataset, V as EMOJI_REGEX, W as LATIN_SPACE_MARK_PUNCTUATION_NUMBERS_REGEX, ct as isInvalidName, dt as matchesRegex, ft as standardKanjiValidator, it as hasText, ot as isEmpty, pt as standardKatakanaValidator, q as OTHER_ENTITIES_VALID_CHAR_REGEX, rt as hasRepeatedCharacters, ut as isValidMinLength } from "./resolveEnvironment-CpWP_8og.js";
|
|
7
7
|
import { t as createLogger } from "./logger-Z8AeTE4x.js";
|
|
8
|
-
import { t as Icon } from "./Icon-
|
|
9
|
-
import {
|
|
8
|
+
import { t as Icon } from "./Icon-jVvV1zXc.js";
|
|
9
|
+
import { t as Button } from "./Button-BYafPrZH.js";
|
|
10
10
|
import { a as objectsDeepEqual, o as entriesOf, t as cloneObject } from "./genUtils-nphCwt1A.js";
|
|
11
|
-
import {
|
|
12
|
-
import { n as
|
|
13
|
-
import {
|
|
14
|
-
import { i as
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import { o as StructuredList, s as Confirm } from "./utils-B6TRzLRs.js";
|
|
18
|
-
import { t as Image } from "./Image-CxnjHtP1.js";
|
|
19
|
-
import { t as List } from "./List-qvNxW9lm.js";
|
|
20
|
-
import { i as getFieldNameFromPath, r as FormRouterContext, t as ErrorPanel } from "./ErrorPanel-DaipnVsu.js";
|
|
21
|
-
import { t as UnincorporatedPartnershipMemberTypes } from "./unincorporatedPartnership-BbNowjM2.js";
|
|
22
|
-
import { forwardRef, lazy } from "preact/compat";
|
|
11
|
+
import { i as useAnalyticsContext, r as KEYBOARD_KEYS } from "./Modal-jjSjdW5W.js";
|
|
12
|
+
import { i as formDebugInfo, n as useForwardedRef, r as InputBase, t as InputText } from "./InputText-OCbzlaaN.js";
|
|
13
|
+
import { t as useId } from "./useId-ChrmzN7R.js";
|
|
14
|
+
import { a as translateTranslatable, c as MaybeModal, d as omitKeys, f as ValidationResult, i as isTranslationObject, l as addKeys, o as Field, p as LoaderWrapper, s as ProgressBar, t as Select, u as getDataByFields } from "./Select-BRK2a2V5.js";
|
|
15
|
+
import { s as Confirm } from "./utils-Do6-kryk.js";
|
|
16
|
+
import { forwardRef } from "preact/compat";
|
|
23
17
|
import { useCallback as useCallback$1, useContext as useContext$1, useEffect as useEffect$1, useLayoutEffect, useMemo as useMemo$1, useReducer, useRef as useRef$1, useState as useState$1 } from "preact/hooks";
|
|
24
18
|
import cx from "classnames";
|
|
25
19
|
import { Fragment as Fragment$1, jsx, jsxs } from "preact/jsx-runtime";
|
|
26
|
-
import { createContext as createContext$1 } from "preact";
|
|
20
|
+
import { createContext as createContext$1, toChildArray } from "preact";
|
|
27
21
|
//#region src/context/FormContext/FormContext.ts
|
|
28
22
|
var FormContext = createContext$1(null);
|
|
29
23
|
//#endregion
|
|
@@ -52,6 +46,12 @@ var usePageLandedEvent = (formName) => {
|
|
|
52
46
|
}
|
|
53
47
|
};
|
|
54
48
|
//#endregion
|
|
49
|
+
//#region src/components/Shared/Summary/types.ts
|
|
50
|
+
var summaryStep = {
|
|
51
|
+
formId: "summary",
|
|
52
|
+
formName: "summary"
|
|
53
|
+
};
|
|
54
|
+
//#endregion
|
|
55
55
|
//#region src/utils/analytics/trackNavigation.ts
|
|
56
56
|
var trackNavigation = ({ userEvents, actionType, toForm, label, returnValue, additionalTrackingParams }) => {
|
|
57
57
|
userEvents.addPageEvent("Clicked button", {
|
|
@@ -63,346 +63,6 @@ var trackNavigation = ({ userEvents, actionType, toForm, label, returnValue, add
|
|
|
63
63
|
});
|
|
64
64
|
};
|
|
65
65
|
//#endregion
|
|
66
|
-
//#region src/utils/formUtils.ts
|
|
67
|
-
var createFormUtils = (props, t) => ({
|
|
68
|
-
getLabel: (field, fallbackLabelKey) => {
|
|
69
|
-
let translationKey = props.labels?.[field] ?? fallbackLabelKey ?? field;
|
|
70
|
-
if (props.labels && !props.labels?.[field] && Object.keys(props.labels).length) {
|
|
71
|
-
const parentKey = Object.keys(props.labels).find((fieldKey) => typeof props.labels?.[fieldKey] === "object");
|
|
72
|
-
if (parentKey) translationKey = props.labels[parentKey][field] ?? translationKey;
|
|
73
|
-
}
|
|
74
|
-
return t(($) => $[translationKey]);
|
|
75
|
-
},
|
|
76
|
-
getMask: (field) => props.masks?.[field],
|
|
77
|
-
isRequiredField: (field, showIfNotInRequiredFields = true) => props.requiredFields ? props.requiredFields.includes(field) && (field !== "role" || field === "role" && props.taskType !== "individual") : showIfNotInRequiredFields,
|
|
78
|
-
isOptionalField: (field) => props.optionalFields?.includes(field) ?? false,
|
|
79
|
-
isVisibleField(field, showIfNotInRequiredFields = true) {
|
|
80
|
-
return this.isRequiredField(field, showIfNotInRequiredFields) || this.isOptionalField(field);
|
|
81
|
-
},
|
|
82
|
-
isReadOnly: (field) => props.readOnly || (props.readOnlyFields ? props.readOnlyFields.includes(field) : false),
|
|
83
|
-
isObscured: (field) => props.obscuredFields ? props.obscuredFields.includes(field) : false,
|
|
84
|
-
isTrusted: (field) => props.trustedFields ? props.trustedFields.includes(field) : false,
|
|
85
|
-
getErrorMessage: (field, errors, fieldProblems) => {
|
|
86
|
-
const errorMessage = errors?.[field]?.errorMessage;
|
|
87
|
-
if (!(!!errorMessage || Boolean(fieldProblems?.[field]))) return;
|
|
88
|
-
return {
|
|
89
|
-
key: (isTranslationObject(errorMessage) ? errorMessage.key : errorMessage) || "invalid",
|
|
90
|
-
message: translateTranslatable(t, errorMessage)
|
|
91
|
-
};
|
|
92
|
-
},
|
|
93
|
-
getFieldData: (formData, fieldKeys) => getDataByFields(formData, fieldKeys),
|
|
94
|
-
getFieldValid: (formValid, fieldKeys) => entriesOf(formValid).reduce((acc, [key, val]) => fieldKeys.includes(key) ? {
|
|
95
|
-
...acc,
|
|
96
|
-
[key]: val
|
|
97
|
-
} : acc, {}),
|
|
98
|
-
getFieldErrors: (formErrors, fieldProblems, fieldKeys) => Object.keys(formErrors).reduce((acc, key) => {
|
|
99
|
-
if (!fieldKeys.includes(key)) return acc;
|
|
100
|
-
const error = formErrors?.[key]?.errorMessage;
|
|
101
|
-
if (!(!!error || Boolean(fieldProblems?.[key]))) return acc;
|
|
102
|
-
const errorKey = isTranslationObject(error) ? error.key : error;
|
|
103
|
-
return {
|
|
104
|
-
...acc,
|
|
105
|
-
[key]: {
|
|
106
|
-
key: errorKey || "invalid",
|
|
107
|
-
message: translateTranslatable(t, error)
|
|
108
|
-
}
|
|
109
|
-
};
|
|
110
|
-
}, {}),
|
|
111
|
-
getFieldLabels: (fieldKeys, fallbackLabelKeys) => fieldKeys.reduce((acc, field) => {
|
|
112
|
-
let translationKey = props.labels?.[field] ?? fallbackLabelKeys?.[field] ?? field;
|
|
113
|
-
if (props.labels && !props.labels?.[field] && Object.keys(props.labels).length) {
|
|
114
|
-
const parentKey = Object.keys(props.labels).find((fieldKey) => typeof props.labels?.[fieldKey] === "object");
|
|
115
|
-
if (parentKey) translationKey = props.labels[parentKey][field] ?? translationKey;
|
|
116
|
-
}
|
|
117
|
-
return {
|
|
118
|
-
...acc,
|
|
119
|
-
[field]: t(($) => $[translationKey])
|
|
120
|
-
};
|
|
121
|
-
}, {})
|
|
122
|
-
});
|
|
123
|
-
var mergeFieldMetadataIntoProps = (fieldName, metadata, otherProps) => {
|
|
124
|
-
const existingProps = otherProps ?? {};
|
|
125
|
-
return {
|
|
126
|
-
...existingProps,
|
|
127
|
-
labels: {
|
|
128
|
-
...existingProps.labels,
|
|
129
|
-
[fieldName]: metadata.label
|
|
130
|
-
},
|
|
131
|
-
masks: {
|
|
132
|
-
...existingProps.masks,
|
|
133
|
-
[fieldName]: metadata.mask
|
|
134
|
-
},
|
|
135
|
-
validators: {
|
|
136
|
-
...existingProps.validators,
|
|
137
|
-
[fieldName]: metadata.validators
|
|
138
|
-
}
|
|
139
|
-
};
|
|
140
|
-
};
|
|
141
|
-
//#endregion
|
|
142
|
-
//#region src/utils/roleMetadata.ts
|
|
143
|
-
var roleMetadata = {
|
|
144
|
-
[DecisionMakerTypes.CONTROLLING_PERSON]: {
|
|
145
|
-
name: "controllingPerson",
|
|
146
|
-
description: "controllingPersonDescription"
|
|
147
|
-
},
|
|
148
|
-
[DecisionMakerTypes.OWNER]: {
|
|
149
|
-
name: "owner",
|
|
150
|
-
description: "ownerDescription"
|
|
151
|
-
},
|
|
152
|
-
[DecisionMakerTypes.SIGNATORY]: {
|
|
153
|
-
name: "signatory",
|
|
154
|
-
description: "signatoryDescription"
|
|
155
|
-
},
|
|
156
|
-
[DecisionMakerTypes.DIRECTOR]: {
|
|
157
|
-
name: "director",
|
|
158
|
-
description: "directorDescription"
|
|
159
|
-
},
|
|
160
|
-
[TrustMemberTypes.DEFINED_BENEFICIARY]: {
|
|
161
|
-
name: "definedBeneficiary",
|
|
162
|
-
description: "definedBeneficiaryDescription"
|
|
163
|
-
},
|
|
164
|
-
[TrustMemberTypes.UNDEFINED_BENEFICIARY]: {
|
|
165
|
-
name: "undefinedBeneficiary",
|
|
166
|
-
description: "undefinedBeneficiaryDescription"
|
|
167
|
-
},
|
|
168
|
-
[TrustMemberTypes.PROTECTOR]: {
|
|
169
|
-
name: "protector",
|
|
170
|
-
description: "personAppointmentUnderTrustInstrument"
|
|
171
|
-
},
|
|
172
|
-
[TrustMemberTypes.TRUSTEE]: {
|
|
173
|
-
name: "trustee",
|
|
174
|
-
description: "legalOwnerOfProperty"
|
|
175
|
-
},
|
|
176
|
-
[TrustMemberTypes.SETTLOR]: {
|
|
177
|
-
name: "settlor",
|
|
178
|
-
description: "entityEstablishingTrust"
|
|
179
|
-
},
|
|
180
|
-
[TrustMemberGuidanceLabels.BENEFICIARY]: { name: TrustMemberGuidanceLabels.BENEFICIARY },
|
|
181
|
-
[TrustMemberGuidanceLabels.TRUSTEE]: { name: TrustMemberGuidanceLabels.TRUSTEE },
|
|
182
|
-
[UnincorporatedPartnershipMemberTypes.SECONDARY_PARTNER]: {
|
|
183
|
-
name: UnincorporatedPartnershipMemberTypes.SECONDARY_PARTNER,
|
|
184
|
-
description: "secondaryPartnerGuideDescription"
|
|
185
|
-
}
|
|
186
|
-
};
|
|
187
|
-
var getRoleTagVariant = (role) => roleMetadata[role]?.variant ?? "blue";
|
|
188
|
-
var getRoleName = (role) => roleMetadata[role]?.name ?? role;
|
|
189
|
-
var Summary_module_default = {
|
|
190
|
-
summary: "_summary_1op7a_1",
|
|
191
|
-
"summary-content": "_summary-content_1op7a_7",
|
|
192
|
-
summaryContent: "_summary-content_1op7a_7",
|
|
193
|
-
"summary-list": "_summary-list_1op7a_13",
|
|
194
|
-
summaryList: "_summary-list_1op7a_13",
|
|
195
|
-
"summary-list-header": "_summary-list-header_1op7a_27",
|
|
196
|
-
summaryListHeader: "_summary-list-header_1op7a_27",
|
|
197
|
-
"summary-list-header-title": "_summary-list-header-title_1op7a_32",
|
|
198
|
-
summaryListHeaderTitle: "_summary-list-header-title_1op7a_32",
|
|
199
|
-
"summary-list-item": "_summary-list-item_1op7a_41",
|
|
200
|
-
summaryListItem: "_summary-list-item_1op7a_41",
|
|
201
|
-
"summary-list-item-key": "_summary-list-item-key_1op7a_55",
|
|
202
|
-
summaryListItemKey: "_summary-list-item-key_1op7a_55",
|
|
203
|
-
"summary-list-item-value": "_summary-list-item-value_1op7a_67",
|
|
204
|
-
summaryListItemValue: "_summary-list-item-value_1op7a_67",
|
|
205
|
-
"summary-content-legal-caption": "_summary-content-legal-caption_1op7a_73",
|
|
206
|
-
summaryContentLegalCaption: "_summary-content-legal-caption_1op7a_73",
|
|
207
|
-
"summary-content-list": "_summary-content-list_1op7a_88",
|
|
208
|
-
summaryContentList: "_summary-content-list_1op7a_88",
|
|
209
|
-
"summary-content-logo": "_summary-content-logo_1op7a_92",
|
|
210
|
-
summaryContentLogo: "_summary-content-logo_1op7a_92"
|
|
211
|
-
};
|
|
212
|
-
//#endregion
|
|
213
|
-
//#region src/components/Shared/Summary/summaryItem.ts
|
|
214
|
-
var isSummaryItem = (val) => typeof val === "object" && val !== null && "summaryLabel" in val && "summaryValue" in val;
|
|
215
|
-
var summaryItem = (summaryLabel, summaryValue) => ({
|
|
216
|
-
summaryLabel,
|
|
217
|
-
summaryValue
|
|
218
|
-
});
|
|
219
|
-
var preTranslatedSummaryItem = (summaryLabel, summaryValue) => ({
|
|
220
|
-
summaryLabel,
|
|
221
|
-
summaryValue,
|
|
222
|
-
preTranslated: true
|
|
223
|
-
});
|
|
224
|
-
//#endregion
|
|
225
|
-
//#region src/components/Shared/Summary/Summary.tsx
|
|
226
|
-
var onfidoLogo = lazy(() => import("./onfido-logo-CMRuSr8M.js"));
|
|
227
|
-
var summaryStep = {
|
|
228
|
-
formId: "summary",
|
|
229
|
-
formName: "summary"
|
|
230
|
-
};
|
|
231
|
-
/** @deprecated, use NewSummary */
|
|
232
|
-
function Summary({ data, forms, gotoForm, labels, problems, omitted = {}, showFormHeader = true, showSectionHeader = true, showLegalCaption = false, showTaxExemptedLegalCaption = false, useStructuredList = false }) {
|
|
233
|
-
const { t } = useTranslation("common");
|
|
234
|
-
const userEvents = useAnalyticsContext();
|
|
235
|
-
const editForm = (formId) => {
|
|
236
|
-
const formIndex = forms.findIndex((form) => form.formId === formId);
|
|
237
|
-
if (formIndex >= 0) gotoForm(formIndex);
|
|
238
|
-
};
|
|
239
|
-
const allValidationErrors = problems?.validationErrors && Object.values(problems.validationErrors)?.reduce((acc, validError) => ({
|
|
240
|
-
...acc,
|
|
241
|
-
...validError
|
|
242
|
-
}), {});
|
|
243
|
-
const allVerificationErrors = problems?.verificationErrors && Object.values(problems.verificationErrors)?.reduce((acc, verifError) => ({
|
|
244
|
-
...acc,
|
|
245
|
-
...verifError
|
|
246
|
-
}), {});
|
|
247
|
-
const formUtils = createFormUtils({ labels }, t);
|
|
248
|
-
const summarySectionHeader = (formName, formId) => /* @__PURE__ */ jsxs("header", {
|
|
249
|
-
className: Summary_module_default.summaryListHeader,
|
|
250
|
-
children: [/* @__PURE__ */ jsx("h2", {
|
|
251
|
-
className: Summary_module_default.summaryListHeaderTitle,
|
|
252
|
-
children: formName
|
|
253
|
-
}), !omitted.summaryEditButton?.includes(formId) && /* @__PURE__ */ jsx(IconButton, {
|
|
254
|
-
variant: "tertiary",
|
|
255
|
-
icon: "edit",
|
|
256
|
-
onClick: () => {
|
|
257
|
-
trackNavigation({
|
|
258
|
-
userEvents,
|
|
259
|
-
actionType: "edit",
|
|
260
|
-
toForm: formName,
|
|
261
|
-
label: "Pencil icon"
|
|
262
|
-
});
|
|
263
|
-
editForm(formId);
|
|
264
|
-
},
|
|
265
|
-
ariaLabel: t(($) => $["editForm"], { formName })
|
|
266
|
-
})]
|
|
267
|
-
});
|
|
268
|
-
const renderSummarySection = (fieldData, labelData = {}, formName, formId, useStructuredList) => {
|
|
269
|
-
const structuredListItems = Object.entries(fieldData).map(([key, value]) => {
|
|
270
|
-
return {
|
|
271
|
-
term: t(($) => $[labelData[key] || key]),
|
|
272
|
-
details: value
|
|
273
|
-
};
|
|
274
|
-
});
|
|
275
|
-
return !useStructuredList ? /* @__PURE__ */ jsxs(List, {
|
|
276
|
-
variant: "grouped-secondary",
|
|
277
|
-
children: [showSectionHeader && summarySectionHeader(formName, formId), /* @__PURE__ */ jsx("dl", {
|
|
278
|
-
className: Summary_module_default.summaryList,
|
|
279
|
-
children: Array.isArray(fieldData) ? fieldData.map((item) => renderBulletedListField(item)) : renderSummaryItems(fieldData, labelData)
|
|
280
|
-
})]
|
|
281
|
-
}) : /* @__PURE__ */ jsxs(List, {
|
|
282
|
-
variant: "grouped-secondary",
|
|
283
|
-
children: [showSectionHeader && summarySectionHeader(formName, formId), /* @__PURE__ */ jsx(StructuredList, { items: structuredListItems })]
|
|
284
|
-
});
|
|
285
|
-
};
|
|
286
|
-
const renderSummaryContent = (summaryData, useStructuredList) => {
|
|
287
|
-
const summaryList = [];
|
|
288
|
-
forms.forEach(({ formId, formName }) => {
|
|
289
|
-
const currentFormData = summaryData[formId];
|
|
290
|
-
if (!currentFormData || Object.values(currentFormData).every((value) => isEmpty(value)) || formId === summaryStep.formId || omitted.forms?.includes(formId)) return;
|
|
291
|
-
const summaryItems = currentFormData.hasInnerForms ? renderInnerForms(labels?.[formId], formId, currentFormData) : renderSummarySection(currentFormData, labels?.[formId], t(($) => $[typeof labels?.[formId] === "string" ? labels[formId] : formName]), formId, useStructuredList);
|
|
292
|
-
summaryList.push(summaryItems);
|
|
293
|
-
});
|
|
294
|
-
return summaryList;
|
|
295
|
-
};
|
|
296
|
-
const renderInnerForms = (labelData, parentFormId, innerForms = {}) => {
|
|
297
|
-
if (!innerForms) return [];
|
|
298
|
-
const dataList = [];
|
|
299
|
-
Object.entries(innerForms).forEach(([innerFormName, innerFormFieldData]) => {
|
|
300
|
-
const formName = t(($) => $[labelData?.[innerFormName] || innerFormName]);
|
|
301
|
-
if (typeof innerFormFieldData === "object" && innerFormFieldData !== null) {
|
|
302
|
-
if (Object.values(innerFormFieldData).every((value) => isEmpty(value))) return;
|
|
303
|
-
dataList.push(renderSummarySection(innerFormFieldData, labelData, formName, parentFormId));
|
|
304
|
-
}
|
|
305
|
-
});
|
|
306
|
-
return dataList;
|
|
307
|
-
};
|
|
308
|
-
/**
|
|
309
|
-
* Renders a single label-value pair as a field in the summary section.
|
|
310
|
-
*
|
|
311
|
-
* This helper function creates the markup for a single piece of data,
|
|
312
|
-
* displaying a label and its corresponding value using a definition list
|
|
313
|
-
* for semantic correctness (`<dt>` for label, `<dd>` for data).
|
|
314
|
-
*
|
|
315
|
-
* @param label The translated label to display for the field.
|
|
316
|
-
* @param value The value of the field, which can be a simple string or a JSX element for more complex rendering.
|
|
317
|
-
* @returns A JSX element representing the summary field.
|
|
318
|
-
*/
|
|
319
|
-
const renderField = (label, value) => /* @__PURE__ */ jsxs("div", {
|
|
320
|
-
className: Summary_module_default.summaryListItem,
|
|
321
|
-
children: [/* @__PURE__ */ jsx("dt", {
|
|
322
|
-
className: Summary_module_default.summaryListItemKey,
|
|
323
|
-
children: label
|
|
324
|
-
}), /* @__PURE__ */ jsx("dd", {
|
|
325
|
-
className: Summary_module_default.summaryListItemValue,
|
|
326
|
-
children: value
|
|
327
|
-
})]
|
|
328
|
-
});
|
|
329
|
-
const renderBulletedListField = (item) => /* @__PURE__ */ jsx("ul", {
|
|
330
|
-
className: Summary_module_default.summaryContentList,
|
|
331
|
-
children: /* @__PURE__ */ jsx("li", { children: item })
|
|
332
|
-
});
|
|
333
|
-
/**
|
|
334
|
-
* Recursively renders the data fields for a summary section.
|
|
335
|
-
*
|
|
336
|
-
* This function iterates through the properties of the `formData` object.
|
|
337
|
-
* It handles different data types by:
|
|
338
|
-
* - Displaying simple string or number values with their corresponding labels.
|
|
339
|
-
* - Handling 'role' arrays specifically to show a comma-separated list of roles.
|
|
340
|
-
* - Recognizing and rendering `SummaryItem` objects with their custom labels and values.
|
|
341
|
-
* - Recursively calling itself for nested objects to render their properties.
|
|
342
|
-
*
|
|
343
|
-
* Fields listed in the `omitted.keys` prop are skipped.
|
|
344
|
-
*
|
|
345
|
-
* @param formData The data object for the current section, containing key-value pairs to be rendered.
|
|
346
|
-
* @param labelData A map of field keys to their corresponding translation keys for fetching display labels.
|
|
347
|
-
* @returns An array of JSX elements representing the rendered summary fields for the section.
|
|
348
|
-
*/
|
|
349
|
-
const renderSummaryItems = (formData = {}, labelData = {}) => {
|
|
350
|
-
if (!formData) return [];
|
|
351
|
-
if (formData?.idVerificationMethod === "instantVerification") return [renderField(t(($) => $["verificationMethod"]), /* @__PURE__ */ jsx(Image, {
|
|
352
|
-
lazyLoadedImage: onfidoLogo,
|
|
353
|
-
className: Summary_module_default.summaryContentLogo,
|
|
354
|
-
alt: "onfido-logo"
|
|
355
|
-
}))];
|
|
356
|
-
const dataList = [];
|
|
357
|
-
Object.entries(formData).forEach(([field, fieldData]) => {
|
|
358
|
-
if (omitted.keys?.includes(field) || !fieldData) return;
|
|
359
|
-
const fieldName = t(($) => $[labelData[field] || field]);
|
|
360
|
-
if (field === "role" && Array.isArray(fieldData)) {
|
|
361
|
-
const label = fieldData.length > 1 ? t(($) => $["roles"]) : fieldName;
|
|
362
|
-
const roles = fieldData.map((role) => t(($) => $[getRoleName(role)])).join(", ");
|
|
363
|
-
dataList.push(renderField(label, roles));
|
|
364
|
-
} else if (isSummaryItem(fieldData)) {
|
|
365
|
-
const { summaryLabel, summaryValue, preTranslated } = fieldData;
|
|
366
|
-
if (preTranslated) dataList.push(renderField(summaryLabel, summaryValue));
|
|
367
|
-
else dataList.push(renderField(translateTranslatable(t, summaryLabel) ?? "", summaryValue));
|
|
368
|
-
} else if (typeof fieldData === "object") dataList.push(renderSummaryItems(fieldData, labelData));
|
|
369
|
-
else if (["string", "number"].includes(typeof fieldData)) dataList.push(renderField(fieldName, fieldData));
|
|
370
|
-
});
|
|
371
|
-
return dataList;
|
|
372
|
-
};
|
|
373
|
-
return /* @__PURE__ */ jsxs("div", {
|
|
374
|
-
role: "region",
|
|
375
|
-
className: Summary_module_default.summary,
|
|
376
|
-
children: [showFormHeader && /* @__PURE__ */ jsx(Header, {
|
|
377
|
-
title: t(($) => $["summary"]),
|
|
378
|
-
description: t(($) => $["summaryDescription"])
|
|
379
|
-
}), /* @__PURE__ */ jsxs("div", {
|
|
380
|
-
className: Summary_module_default.summaryContent,
|
|
381
|
-
children: [
|
|
382
|
-
/* @__PURE__ */ jsx(ErrorPanel, {
|
|
383
|
-
validationErrors: allValidationErrors,
|
|
384
|
-
verificationErrors: allVerificationErrors,
|
|
385
|
-
formUtils,
|
|
386
|
-
id: "ariaErrorField"
|
|
387
|
-
}),
|
|
388
|
-
renderSummaryContent(data, useStructuredList),
|
|
389
|
-
showLegalCaption && /* @__PURE__ */ jsx("div", {
|
|
390
|
-
className: Summary_module_default.summaryContentLegalCaption,
|
|
391
|
-
children: t(($) => $["summaryLegalCaption"])
|
|
392
|
-
}),
|
|
393
|
-
showTaxExemptedLegalCaption && /* @__PURE__ */ jsxs("div", {
|
|
394
|
-
className: Summary_module_default.summaryContentLegalCaption,
|
|
395
|
-
children: [/* @__PURE__ */ jsx("p", { children: t(($) => $["summaryTaxExemptionLegalCaptionTitle"]) }), /* @__PURE__ */ jsxs("ul", { children: [
|
|
396
|
-
/* @__PURE__ */ jsx("li", { children: t(($) => $["summaryTaxExemptionLegalCaption_1"]) }),
|
|
397
|
-
/* @__PURE__ */ jsx("li", { children: t(($) => $["summaryTaxExemptionLegalCaption_2"]) }),
|
|
398
|
-
/* @__PURE__ */ jsx("li", { children: t(($) => $["summaryTaxExemptionLegalCaption_3"]) })
|
|
399
|
-
] })]
|
|
400
|
-
})
|
|
401
|
-
]
|
|
402
|
-
})]
|
|
403
|
-
});
|
|
404
|
-
}
|
|
405
|
-
//#endregion
|
|
406
66
|
//#region src/utils/scrollToInvalidField.ts
|
|
407
67
|
var INVALID_FIELD_SELECTOR = ".adyen-kyc-field--error, .adyen-kyc-label__text--error";
|
|
408
68
|
var SCROLLABLE_OVERFLOW_VALUES = /* @__PURE__ */ new Set([
|
|
@@ -1592,6 +1252,9 @@ var validatePatternOnBlur = (pattern) => ({
|
|
|
1592
1252
|
validate: (val) => !!val && pattern.test(val)
|
|
1593
1253
|
});
|
|
1594
1254
|
//#endregion
|
|
1255
|
+
//#region src/context/FormRouterContext/FormRouterContext.ts
|
|
1256
|
+
var FormRouterContext = createContext$1(null);
|
|
1257
|
+
//#endregion
|
|
1595
1258
|
//#region src/context/FormRouterContext/FormRouterContextProvider.tsx
|
|
1596
1259
|
var logger = createLogger();
|
|
1597
1260
|
function FormRouterContextProvider({ children, forms, setFormIndex, goToFormByFormId }) {
|
|
@@ -1646,7 +1309,7 @@ var FormFlow_module_default = {
|
|
|
1646
1309
|
};
|
|
1647
1310
|
//#endregion
|
|
1648
1311
|
//#region src/components/Shared/FormFlow/FormFlow.tsx
|
|
1649
|
-
var FormFlow = ({ asModal = false, children, currentStep = 0, disableBackButton, disableNextButton, nextButtonLoading = false, forms, activeForm, gotoFormByFormIndex, gotoFormByFormId, handleBackClick, handleCancelClick, handleNextClick, loadingStatus,
|
|
1312
|
+
var FormFlow = ({ asModal = false, children, currentStep = 0, disableBackButton, disableNextButton, nextButtonLoading = false, forms, activeForm, gotoFormByFormIndex, gotoFormByFormId, handleBackClick, handleCancelClick, handleNextClick, loadingStatus, summaryComponent, totalSteps = 1, isGlobalEntry = false }) => {
|
|
1650
1313
|
const contentRef = useRef$1(null);
|
|
1651
1314
|
const userEvents = useAnalyticsContext();
|
|
1652
1315
|
const { t } = useTranslation("common");
|
|
@@ -1720,11 +1383,7 @@ var FormFlow = ({ asModal = false, children, currentStep = 0, disableBackButton,
|
|
|
1720
1383
|
forms,
|
|
1721
1384
|
setFormIndex: gotoFormByFormIndex,
|
|
1722
1385
|
goToFormByFormId: gotoFormByFormId,
|
|
1723
|
-
children: isLastStep
|
|
1724
|
-
...summary,
|
|
1725
|
-
forms,
|
|
1726
|
-
gotoForm: gotoFormByFormIndex
|
|
1727
|
-
}) : children : children
|
|
1386
|
+
children: isLastStep && summaryComponent ? summaryComponent : children
|
|
1728
1387
|
})
|
|
1729
1388
|
})
|
|
1730
1389
|
}), /* @__PURE__ */ jsxs("div", {
|
|
@@ -1779,6 +1438,85 @@ function useFormContext() {
|
|
|
1779
1438
|
return useContext$1(FormContext);
|
|
1780
1439
|
}
|
|
1781
1440
|
//#endregion
|
|
1441
|
+
//#region src/utils/formUtils.ts
|
|
1442
|
+
var createFormUtils = (props, t) => ({
|
|
1443
|
+
getLabel: (field, fallbackLabelKey) => {
|
|
1444
|
+
let translationKey = props.labels?.[field] ?? fallbackLabelKey ?? field;
|
|
1445
|
+
if (props.labels && !props.labels?.[field] && Object.keys(props.labels).length) {
|
|
1446
|
+
const parentKey = Object.keys(props.labels).find((fieldKey) => typeof props.labels?.[fieldKey] === "object");
|
|
1447
|
+
if (parentKey) translationKey = props.labels[parentKey][field] ?? translationKey;
|
|
1448
|
+
}
|
|
1449
|
+
return t(($) => $[translationKey]);
|
|
1450
|
+
},
|
|
1451
|
+
getMask: (field) => props.masks?.[field],
|
|
1452
|
+
isRequiredField: (field, showIfNotInRequiredFields = true) => props.requiredFields ? props.requiredFields.includes(field) && (field !== "role" || field === "role" && props.taskType !== "individual") : showIfNotInRequiredFields,
|
|
1453
|
+
isOptionalField: (field) => props.optionalFields?.includes(field) ?? false,
|
|
1454
|
+
isVisibleField(field, showIfNotInRequiredFields = true) {
|
|
1455
|
+
return this.isRequiredField(field, showIfNotInRequiredFields) || this.isOptionalField(field);
|
|
1456
|
+
},
|
|
1457
|
+
isReadOnly: (field) => props.readOnly || (props.readOnlyFields ? props.readOnlyFields.includes(field) : false),
|
|
1458
|
+
isObscured: (field) => props.obscuredFields ? props.obscuredFields.includes(field) : false,
|
|
1459
|
+
isTrusted: (field) => props.trustedFields ? props.trustedFields.includes(field) : false,
|
|
1460
|
+
getErrorMessage: (field, errors, fieldProblems) => {
|
|
1461
|
+
const errorMessage = errors?.[field]?.errorMessage;
|
|
1462
|
+
if (!(!!errorMessage || Boolean(fieldProblems?.[field]))) return;
|
|
1463
|
+
return {
|
|
1464
|
+
key: (isTranslationObject(errorMessage) ? errorMessage.key : errorMessage) || "invalid",
|
|
1465
|
+
message: translateTranslatable(t, errorMessage)
|
|
1466
|
+
};
|
|
1467
|
+
},
|
|
1468
|
+
getFieldData: (formData, fieldKeys) => getDataByFields(formData, fieldKeys),
|
|
1469
|
+
getFieldValid: (formValid, fieldKeys) => entriesOf(formValid).reduce((acc, [key, val]) => fieldKeys.includes(key) ? {
|
|
1470
|
+
...acc,
|
|
1471
|
+
[key]: val
|
|
1472
|
+
} : acc, {}),
|
|
1473
|
+
getFieldErrors: (formErrors, fieldProblems, fieldKeys) => Object.keys(formErrors).reduce((acc, key) => {
|
|
1474
|
+
if (!fieldKeys.includes(key)) return acc;
|
|
1475
|
+
const error = formErrors?.[key]?.errorMessage;
|
|
1476
|
+
if (!(!!error || Boolean(fieldProblems?.[key]))) return acc;
|
|
1477
|
+
const errorKey = isTranslationObject(error) ? error.key : error;
|
|
1478
|
+
return {
|
|
1479
|
+
...acc,
|
|
1480
|
+
[key]: {
|
|
1481
|
+
key: errorKey || "invalid",
|
|
1482
|
+
message: translateTranslatable(t, error)
|
|
1483
|
+
}
|
|
1484
|
+
};
|
|
1485
|
+
}, {}),
|
|
1486
|
+
getFieldLabels: (fieldKeys, fallbackLabelKeys) => fieldKeys.reduce((acc, field) => {
|
|
1487
|
+
let translationKey = props.labels?.[field] ?? fallbackLabelKeys?.[field] ?? field;
|
|
1488
|
+
if (props.labels && !props.labels?.[field] && Object.keys(props.labels).length) {
|
|
1489
|
+
const parentKey = Object.keys(props.labels).find((fieldKey) => typeof props.labels?.[fieldKey] === "object");
|
|
1490
|
+
if (parentKey) translationKey = props.labels[parentKey][field] ?? translationKey;
|
|
1491
|
+
}
|
|
1492
|
+
return {
|
|
1493
|
+
...acc,
|
|
1494
|
+
[field]: t(($) => $[translationKey])
|
|
1495
|
+
};
|
|
1496
|
+
}, {})
|
|
1497
|
+
});
|
|
1498
|
+
var mergeFieldMetadataIntoProps = (fieldName, metadata, otherProps) => {
|
|
1499
|
+
const existingProps = otherProps ?? {};
|
|
1500
|
+
return {
|
|
1501
|
+
...existingProps,
|
|
1502
|
+
labels: {
|
|
1503
|
+
...existingProps.labels,
|
|
1504
|
+
[fieldName]: metadata.label
|
|
1505
|
+
},
|
|
1506
|
+
masks: {
|
|
1507
|
+
...existingProps.masks,
|
|
1508
|
+
[fieldName]: metadata.mask
|
|
1509
|
+
},
|
|
1510
|
+
validators: {
|
|
1511
|
+
...existingProps.validators,
|
|
1512
|
+
[fieldName]: metadata.validators
|
|
1513
|
+
}
|
|
1514
|
+
};
|
|
1515
|
+
};
|
|
1516
|
+
//#endregion
|
|
1517
|
+
//#region src/utils/getFieldNameFromPath.ts
|
|
1518
|
+
var getFieldNameFromPath = (fieldPath) => fieldPath.split(".").at(-1);
|
|
1519
|
+
//#endregion
|
|
1782
1520
|
//#region src/utils/validationError.ts
|
|
1783
1521
|
var API_VALIDATION_ERROR_CODE = "30_102";
|
|
1784
1522
|
var ID_DOCUMENT_UPLOAD_ERROR_CODE = "30_105";
|
|
@@ -1853,6 +1591,69 @@ function CountryField({ name = "country", data, valid, errors, labels, readonly,
|
|
|
1853
1591
|
})
|
|
1854
1592
|
});
|
|
1855
1593
|
}
|
|
1594
|
+
var List_module_default = {
|
|
1595
|
+
list: "_list_s1vme_1",
|
|
1596
|
+
"list-header": "_list-header_s1vme_8",
|
|
1597
|
+
listHeader: "_list-header_s1vme_8",
|
|
1598
|
+
"list-footer": "_list-footer_s1vme_15",
|
|
1599
|
+
listFooter: "_list-footer_s1vme_15",
|
|
1600
|
+
"list-items": "_list-items_s1vme_22",
|
|
1601
|
+
listItems: "_list-items_s1vme_22",
|
|
1602
|
+
"list-items-plain": "_list-items-plain_s1vme_27",
|
|
1603
|
+
listItemsPlain: "_list-items-plain_s1vme_27",
|
|
1604
|
+
"list-items-grouped-primary": "_list-items-grouped-primary_s1vme_31",
|
|
1605
|
+
listItemsGroupedPrimary: "_list-items-grouped-primary_s1vme_31",
|
|
1606
|
+
"list-items-grouped-secondary": "_list-items-grouped-secondary_s1vme_37",
|
|
1607
|
+
listItemsGroupedSecondary: "_list-items-grouped-secondary_s1vme_37",
|
|
1608
|
+
"list-items-padding-none": "_list-items-padding-none_s1vme_42",
|
|
1609
|
+
listItemsPaddingNone: "_list-items-padding-none_s1vme_42",
|
|
1610
|
+
"list-items-padding-small": "_list-items-padding-small_s1vme_46",
|
|
1611
|
+
listItemsPaddingSmall: "_list-items-padding-small_s1vme_46",
|
|
1612
|
+
"list-items-padding-medium": "_list-items-padding-medium_s1vme_50",
|
|
1613
|
+
listItemsPaddingMedium: "_list-items-padding-medium_s1vme_50",
|
|
1614
|
+
"list-items-padding-large": "_list-items-padding-large_s1vme_54",
|
|
1615
|
+
listItemsPaddingLarge: "_list-items-padding-large_s1vme_54",
|
|
1616
|
+
"list-item-row-separator": "_list-item-row-separator_s1vme_58",
|
|
1617
|
+
listItemRowSeparator: "_list-item-row-separator_s1vme_58"
|
|
1618
|
+
};
|
|
1619
|
+
//#endregion
|
|
1620
|
+
//#region src/components/ui/atoms/List/List.tsx
|
|
1621
|
+
var List = ({ children, dividers = true, footer, header, padding = "medium", variant = "plain" }) => {
|
|
1622
|
+
const childrenArray = toChildArray(children);
|
|
1623
|
+
const listVariantStyles = {
|
|
1624
|
+
plain: List_module_default.listItemsPlain,
|
|
1625
|
+
"grouped-primary": List_module_default.listItemsGroupedPrimary,
|
|
1626
|
+
"grouped-secondary": List_module_default.listItemsGroupedSecondary
|
|
1627
|
+
};
|
|
1628
|
+
const listClassName = cx(List_module_default.listItems, listVariantStyles[variant], variant !== "plain" && {
|
|
1629
|
+
[List_module_default.listItemsPaddingSmall]: padding === "small",
|
|
1630
|
+
[List_module_default.listItemsPaddingMedium]: padding === "medium",
|
|
1631
|
+
[List_module_default.listItemsPaddingLarge]: padding === "large"
|
|
1632
|
+
}, { [List_module_default.listItemsPaddingNone]: padding === "none" });
|
|
1633
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
1634
|
+
className: List_module_default.list,
|
|
1635
|
+
children: [
|
|
1636
|
+
header && /* @__PURE__ */ jsx("div", {
|
|
1637
|
+
className: List_module_default.listHeader,
|
|
1638
|
+
children: header
|
|
1639
|
+
}),
|
|
1640
|
+
/* @__PURE__ */ jsx("ul", {
|
|
1641
|
+
className: listClassName,
|
|
1642
|
+
children: childrenArray.map((item) => {
|
|
1643
|
+
const itemClassname = cx(List_module_default.listItem, { [List_module_default.listItemRowSeparator]: dividers });
|
|
1644
|
+
return /* @__PURE__ */ jsx("li", {
|
|
1645
|
+
className: itemClassname,
|
|
1646
|
+
children: item
|
|
1647
|
+
});
|
|
1648
|
+
})
|
|
1649
|
+
}),
|
|
1650
|
+
footer && /* @__PURE__ */ jsx("div", {
|
|
1651
|
+
className: List_module_default.listFooter,
|
|
1652
|
+
children: footer
|
|
1653
|
+
})
|
|
1654
|
+
]
|
|
1655
|
+
});
|
|
1656
|
+
};
|
|
1856
1657
|
//#endregion
|
|
1857
1658
|
//#region src/utils/masking/displayValueToPureValue.ts
|
|
1858
1659
|
var cachedStripPatterns = /* @__PURE__ */ new Map();
|
|
@@ -2569,4 +2370,4 @@ var addValidityToForms = (forms, formValidity, problems) => forms.map(({ formId,
|
|
|
2569
2370
|
hasServerValidationErrors: Boolean(problems?.validationErrors?.[formId])
|
|
2570
2371
|
}));
|
|
2571
2372
|
//#endregion
|
|
2572
|
-
export {
|
|
2373
|
+
export { uppercase as A, isTruthyValidator as B, FormRouterContext as C, validateLegalCompanyName as D, validateLatinSpaceMarkPunctuationNumbersOnlyOnBlur as E, nonInputs as F, trackNavigation as H, numericInputs as I, spacer as L, alphanumericInputs as M, customInputs as N, validateNotEmptyOnBlur as O, makeMask as P, useMultiForm as R, FormFlow_module_default as S, validateJaKanaLegalCompanyName as T, summaryStep as U, useFormComposer as V, FormContextProvider as W, getFieldNameFromPath as _, MaskedInput as a, useFormContext as b, List as c, getValidationErrorDisplayMessages as d, isBankStatementUploadError as f, mapCreateOrUpdateTransferInstrumentErrorMessageToTranslatable as g, isValidationError as h, RadioWithLabel as i, alphaInputs as j, validatePatternOnBlur as k, COUNTRY_FIELD as l, isIdDocumentUploadError as m, getRequiredForms as n, InputEmail as o, isBusinessSelectionLegalArrangementError as p, RadioGroup as r, isValueObscured as s, addValidityToForms as t, CountryField as u, createFormUtils as v, validateJaHaniLegalCompanyName as w, FormFlow as x, mergeFieldMetadataIntoProps as y, isNotEmptyValidator as z };
|