@adyen/kyc-components 4.3.0 → 4.4.0-beta.0
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/{AcceptTermsOfServiceComponent-OMNQzzlt.js → AcceptTermsOfServiceComponent-BNYCiHcM.js} +15 -15
- package/dist/{AccountSetupRejected-BmELqasB.js → AccountSetupRejected-CjBJD3co.js} +2 -2
- package/dist/{ActionBar-CYYTQnyt.js → ActionBar-CNo6TTyu.js} +2 -2
- package/dist/{Address-BuvEwdEz.js → Address-Diyf6D1h.js} +17 -18
- package/dist/{Avatar-6Ijr-U98.js → Avatar-Brfu-Afq.js} +2 -2
- package/dist/{BusinessFinancingComponent-C_dvZWrV.js → BusinessFinancingComponent-CFjqKEuN.js} +6 -6
- package/dist/{BusinessFinancingDropin-CqBXTRew.js → BusinessFinancingDropin-CTIycsy1.js} +30 -30
- package/dist/BusinessFinancingPage-CgjmgSnX.js +43 -0
- package/dist/{BusinessTypeSelectionPage-0ykcbLXM.js → BusinessTypeSelectionPage-B06fk_Rg.js} +9 -9
- package/dist/{Checkbox-CEt2JNWg.js → Checkbox-DNfOluUb.js} +2 -2
- package/dist/{Confirm-tO8eG5lI.js → Confirm-DCXKUVXM.js} +3 -3
- package/dist/{ConstitutionalDocument-BNQrCuoP.js → ConstitutionalDocument-Coj5aMaC.js} +18 -18
- package/dist/{ContactDetails-wRdhpEXl.js → ContactDetails-tXeN2x-X.js} +6 -6
- package/dist/{ContextGuidance-D-wkN66k.js → ContextGuidance-BGYRTngC.js} +2 -2
- package/dist/{CountryField-BfpNTqr6.js → CountryField-pShtGZpv.js} +4 -4
- package/dist/CreateIndividualComponent-abEc0kLX.js +65 -0
- package/dist/{CreateTransferInstrumentComponent-C94kteP5.js → CreateTransferInstrumentComponent-Cg8q2lzu.js} +5 -5
- package/dist/{Currency-CIvge00Z.js → Currency-3KfPJJfd.js} +10 -10
- package/dist/{CustomerSupport-Cn0cURdF.js → CustomerSupport-dXIEfG6m.js} +10 -10
- package/dist/{DebugModal-CPJQfotk.js → DebugModal-xFsjUBKk.js} +9 -9
- package/dist/{DecisionMakerDetailsPage-HY7FMT3F.js → DecisionMakerDetailsPage-BdZAgdo_.js} +8 -8
- package/dist/{DecisionMakers-C9Y6zR4s.js → DecisionMakers-efKmwEH6.js} +21 -22
- package/dist/{Dropzone-B87ivHUX.js → Dropzone-BtwqJU5w.js} +4 -4
- package/dist/{EmbeddedStatus-Qp66N9js.js → EmbeddedStatus-Di3lXGXA.js} +3 -3
- package/dist/{EndStateLayout-BcYjyuoi.js → EndStateLayout-C63kFcwB.js} +2 -2
- package/dist/{EntityAssociation-NEf45gFy.js → EntityAssociation-Cz6ly5Qe.js} +5 -5
- package/dist/{EntityGuidanceStatus-BSe0LbpA.js → EntityGuidanceStatus-BGC_I-s6.js} +4 -4
- package/dist/{ErrorPanel-0defccwj.js → ErrorPanel-Bsb874-e.js} +2 -2
- package/dist/{Field-CS5lBNi-.js → Field-nIoNNk_N.js} +2 -2
- package/dist/{FormNavigation-Ds6Zo4kr.js → FormNavigation-9E9YQaln.js} +3 -3
- package/dist/{FormWrapper-CM27JHcm.js → FormWrapper-HYumfmvK.js} +9 -9
- package/dist/{Individual.rules-BKCZ5pw4.js → Individual.rules-DJfPeca6.js} +10 -7
- package/dist/{IndividualDropin-BEfS_NNT.js → IndividualDropin-FCdKMguU.js} +180 -167
- package/dist/{InputDate-DbPcPUic.js → InputDate-BAWkxli9.js} +2 -2
- package/dist/{InputText-CQMxEarX.js → InputText-DCNTJXjB.js} +2 -2
- package/dist/{Introduction-_K-ioq4w.js → Introduction-zRpWy7HO.js} +4 -4
- package/dist/{JpAddress-8qsY8wnP.js → JpAddress-B8_YLYu7.js} +10 -11
- package/dist/{LandingLayout-Bx0c6vHb.js → LandingLayout-BkwhYMd1.js} +2 -2
- package/dist/{LegalCompanyNameField-BD6Te5c5.js → LegalCompanyNameField-Br-bRib5.js} +6 -6
- package/dist/LegalRepresentativeDetailsPage-DsfDlsBE.js +55 -0
- package/dist/{Link-deXxlSsM.js → Link-B5DpLekJ.js} +2 -2
- package/dist/{ListItem-Dtx0lKaK.js → ListItem-C9ET58aa.js} +3 -3
- package/dist/{LoaderWrapper-Dg9BXOfN.js → LoaderWrapper-BrMjOh8d.js} +2 -2
- package/dist/ManageIndividualComponent-DNe0RWZb.js +46 -0
- package/dist/{ManageTermsOfServiceComponent-rpvf07UO.js → ManageTermsOfServiceComponent-Dca8Fs-a.js} +4 -4
- package/dist/{ManageTransferInstrumentComponent-D_10bdI3.js → ManageTransferInstrumentComponent-EZgfMS-6.js} +12 -13
- package/dist/{MaskedInput-DX9qywO6.js → MaskedInput-BcdqJYu3.js} +5 -5
- package/dist/{MaybeModal-B6Y-CUwt.js → MaybeModal-BndZ-_x7.js} +3 -3
- package/dist/{Modal-CyGRv-gZ.js → Modal-DFCycX68.js} +2 -2
- package/dist/{Name-DB6DpTUy.js → Name-TIfffXgJ.js} +5 -5
- package/dist/{OnboardingDropinComponent-ByCzepLz.js → OnboardingDropinComponent-CvE6pJKz.js} +793 -107
- package/dist/{PayoutDetailsDropin-CHKMEoSE.js → PayoutDetailsDropin-fP0XOKYY.js} +64 -168
- package/dist/PayoutDetailsPage-Bg4jqe0M.js +55 -0
- package/dist/{RadioGroup-Bmyz_UGC.js → RadioGroup-sThBOoyi.js} +2 -2
- package/dist/{RadioGroupCard-DfDec_J3.js → RadioGroupCard-C6sxs8KI.js} +2 -2
- package/dist/{Review-BfeBbmqL.js → Review-EZfLF4rz.js} +6 -6
- package/dist/{RootBusinessDetailsPage-CtRd9HPs.js → RootBusinessDetailsPage-DpdikJPd.js} +5 -5
- package/dist/{RootBusinessLinesPage-Btnsj8r_.js → RootBusinessLinesPage-C-sZv7m1.js} +24 -27
- package/dist/RootIndividualDetailsPage-BY5WbcpR.js +61 -0
- package/dist/{Select-w8VBNvQR.js → Select-C90SXgWt.js} +4 -4
- package/dist/{SignPCIComponent-CA5Ao7_u.js → SignPCIComponent-BM4bM5lG.js} +11 -11
- package/dist/{SingpassSelection-DOUOHu-z.js → SingpassSelection-Bf4TJmNp.js} +6 -6
- package/dist/{SoleProprietorshipPage-4OFUvq_A.js → SoleProprietorshipPage-DuR8s39H.js} +4 -4
- package/dist/{SourceOfFundsPage-B2L2vYO7.js → SourceOfFundsPage-B-4L7Rbi.js} +36 -40
- package/dist/{StepProgressIndicator-BBjfKoHH.js → StepProgressIndicator-DwIkNQ98.js} +2 -2
- package/dist/{StoreProvider-DFR6yFy8.js → StoreProvider-OuIcrYXq.js} +222 -209
- package/dist/{StructuredList-Bh1vlAFE.js → StructuredList-CNha20ka.js} +1 -1
- package/dist/{Summary-SxfPLeM9.js → Summary-BdZCrtmA.js} +11 -9
- package/dist/{TaxInformationField-pIOj5IIN.js → TaxInformationField-CLotsTdy.js} +22 -22
- package/dist/{TaxReportingDropin-BzB8nYXE.js → TaxReportingDropin-CCjRFYko.js} +15 -15
- package/dist/{TextArea-I88bxkOh.js → TextArea-DggFRd6A.js} +2 -2
- package/dist/{TileGroup-PHV4JXvH.js → TileGroup-Chn8t1lL.js} +3 -3
- package/dist/{TrustDetailsPage-Dr6YIRGG.js → TrustDetailsPage-C61KvX6f.js} +33 -33
- package/dist/{TrustMemberCompanyPage-CfUxQni4.js → TrustMemberCompanyPage-CqiLrrtT.js} +6 -6
- package/dist/TrustMemberIndividualPage-DOOv3UCM.js +64 -0
- package/dist/{TrustMemberRoleAndTypePage-BdBKpEha.js → TrustMemberRoleAndTypePage-Cil5oL0H.js} +22 -23
- package/dist/{TrustMembersOverview-Ynu4zahR.js → TrustMembersOverview-5PfCpnLZ.js} +11 -11
- package/dist/UnincorporatedPartnershipIndividualPage-Imr8r98E.js +63 -0
- package/dist/{UnincorporatedPartnershipMemberCompanyPage-BFZ7GGpo.js → UnincorporatedPartnershipMemberCompanyPage-DVn8X5ZA.js} +5 -5
- package/dist/{UnincorporatedPartnershipMemberRoleAndTypePage-6C67QTtR.js → UnincorporatedPartnershipMemberRoleAndTypePage-D1ZiUnfd.js} +15 -15
- package/dist/{UnincorporatedPartnershipMembersOverview-BkAc4tTI.js → UnincorporatedPartnershipMembersOverview-B3hUsoDk.js} +8 -8
- package/dist/{VerificationErrorAlert-CyE2-4NI.js → VerificationErrorAlert-C-FdjLP6.js} +23 -3
- package/dist/{ViewVerificationStatusComponent-0IyRvr_W.js → ViewVerificationStatusComponent-BrH14DRo.js} +3 -3
- package/dist/adyen-business-financing.js +3 -3
- package/dist/adyen-individual-configuration.js +3 -3
- package/dist/adyen-individual-status.js +3 -3
- package/dist/adyen-invited-decision-maker.js +8 -8
- package/dist/adyen-kyc-components.js +15 -16
- package/dist/adyen-onboarding.js +3 -3
- 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 +3 -3
- package/dist/adyen-transfer-instrument-management.js +3 -3
- package/dist/adyen-verification-status.js +3 -3
- package/dist/{bafinUtils-BABg2zgB.js → bafinUtils-IYWLuHfZ.js} +14 -2
- package/dist/bg-BG-CRbKoTLs.js +13 -0
- package/dist/{bg-BG-C6kad3Qr.js → bg-BG-Cj3_UGTi.js} +10 -1
- package/dist/{bg-BG-er0t4jTs.js → bg-BG-Cz7Cuw8v.js} +3 -1
- package/dist/bg-BG-DqRXdvRT.js +13 -0
- package/dist/{commonValidators-BcyFMdFA.js → commonValidators-Bv3KYb4e.js} +2 -2
- package/dist/{cs-CZ-CQNBae2b.js → cs-CZ-BlrV3tkx.js} +3 -1
- package/dist/cs-CZ-CmPmY5GZ.js +13 -0
- package/dist/cs-CZ-DR5Pfj3g.js +13 -0
- package/dist/{cs-CZ-C_GFp3nV.js → cs-CZ-DxfB5dcV.js} +10 -1
- package/dist/{da-DK-C60mLiV1.js → da-DK-BfsYpvel.js} +10 -1
- package/dist/da-DK-CG2NcTvu.js +13 -0
- package/dist/{da-DK-gnPgzwrG.js → da-DK-CM1onr3w.js} +3 -1
- package/dist/{da-DK-Cd5IQPv3.js → da-DK-CMVthpSr.js} +2 -2
- package/dist/da-DK-DaINWU5x.js +13 -0
- package/dist/{de-DE-C9NH2zMh.js → de-DE-B5TOuf7l.js} +2 -2
- package/dist/{de-DE-D3lLuF8z.js → de-DE-CA4mYLwp.js} +3 -1
- package/dist/{de-DE-Cvz1TGdB.js → de-DE-CEsDXBn-.js} +10 -1
- package/dist/de-DE-KqZs1FFF.js +13 -0
- package/dist/de-DE-NMS4xBab.js +13 -0
- package/dist/{dropinUtils-Ds8fesIK.js → dropinUtils-BIMKuwjT.js} +4 -4
- package/dist/{el-GR-DTHQslLc.js → el-GR-BNNlN4l2.js} +2 -2
- package/dist/el-GR-Bn45KMp-.js +13 -0
- package/dist/{el-GR-DSlgFwLb.js → el-GR-CM3bIzr7.js} +10 -1
- package/dist/{el-GR-XRux2Wpv.js → el-GR-D6XimdV5.js} +3 -1
- package/dist/el-GR-DWM1mhuZ.js +13 -0
- package/dist/{en-US-h0JneJJl.js → en-US--1W760fR.js} +2 -2
- package/dist/en-US-CEnwRsyr.js +13 -0
- package/dist/{en-US-B96dpVon.js → en-US-fDACdKtT.js} +3 -1
- package/dist/{en-US.instructions-Ddr7AO05.js → en-US.instructions-CfIM2SRF.js} +1 -2
- package/dist/{es-ES-CXDJLKAI.js → es-ES-BBcx4tvi.js} +3 -1
- package/dist/{es-ES-Dj5-YMmZ.js → es-ES-BWFP5itn.js} +10 -1
- package/dist/es-ES-BWe46jej.js +13 -0
- package/dist/es-ES-DzGJ9DrB.js +13 -0
- package/dist/{es-ES-DK-7qtDf.js → es-ES-Wcpc6fm1.js} +2 -2
- package/dist/{et-EE--cL_YqWe.js → et-EE-B_Wk8564.js} +3 -1
- package/dist/{et-EE-Bij5j-z5.js → et-EE-CcXrAAc7.js} +10 -1
- package/dist/et-EE-CylmXBkF.js +13 -0
- package/dist/et-EE-JKt5dMOQ.js +13 -0
- package/dist/{fi-FI-fArobrt5.js → fi-FI-BKu826v5.js} +3 -1
- package/dist/{fi-FI-B2xHiSHi.js → fi-FI-DenK0WPz.js} +10 -1
- package/dist/fi-FI-larJ5zXy.js +13 -0
- package/dist/fi-FI-n9XAQuIy.js +13 -0
- package/dist/{formUtils-Ctj-XQBQ.js → formUtils-BFUZHoQZ.js} +3 -3
- package/dist/{fr-FR-CNQtWSXx.js → fr-FR-BmTswZU5.js} +10 -1
- package/dist/{fr-FR-CiwkAb3E.js → fr-FR-C7iSS-OS.js} +3 -1
- package/dist/fr-FR-DVqpakkq.js +13 -0
- package/dist/{fr-FR-B2je0smB.js → fr-FR-DodNoPid.js} +2 -2
- package/dist/fr-FR-iD1onxpA.js +13 -0
- package/dist/{getName-VMVSrxGw.js → getName-B38W_qUJ.js} +2 -2
- package/dist/{getProblemsForEntity-B2aPSiz5.js → getProblemsForEntity-1vXQVg7Q.js} +2 -2
- package/dist/hr-HR-C-Hn5lAD.js +13 -0
- package/dist/hr-HR-CAqaI1xJ.js +13 -0
- package/dist/{hr-HR-B6U5Rzzw.js → hr-HR-SDrDZRLV.js} +10 -1
- package/dist/{hr-HR-DtfHQVe0.js → hr-HR-g88yM2q1.js} +3 -1
- package/dist/{hu-HU-I4-KFzvz.js → hu-HU-ByRdd0O_.js} +3 -1
- package/dist/{hu-HU-DU-5ujQK.js → hu-HU-C3ZiFh1F.js} +2 -2
- package/dist/hu-HU-CRpdELm_.js +13 -0
- package/dist/{hu-HU-BLLoj5CX.js → hu-HU-DSVf2zbX.js} +10 -1
- package/dist/hu-HU-DynB7VhD.js +13 -0
- package/dist/{iframeWidget-CJ4GOEBG.js → iframeWidget-CjQFGMKX.js} +4 -4
- package/dist/{isEmpty-BNrK3WJw.js → isEmpty-CsJihz8_.js} +2 -2
- package/dist/{it-IT-DIbH-udG.js → it-IT-CUrn0j1I.js} +3 -1
- package/dist/{it-IT-Dhwa9Ecj.js → it-IT-CZ4aDoVQ.js} +2 -2
- package/dist/{it-IT-Cr20JO4o.js → it-IT-DJe5OflH.js} +10 -1
- package/dist/it-IT-DkiyBNl6.js +13 -0
- package/dist/it-IT-M7AqGzBo.js +13 -0
- package/dist/ja-JP-B0Ox3Ixh.js +13 -0
- package/dist/ja-JP-BcGZdMJa.js +13 -0
- package/dist/{ja-JP-BZb5ndp9.js → ja-JP-BpeNsNhn.js} +2 -2
- package/dist/{ja-JP-CaUe8KW7.js → ja-JP-CbP1sVFP.js} +3 -1
- package/dist/{ja-JP-BeeuQ_LL.js → ja-JP-GGV_-V6p.js} +10 -1
- package/dist/{japanSupportUtils-B1kmKF7K.js → japanSupportUtils-Cr3OSFeT.js} +2 -2
- package/dist/{localizeDateString-DUFhW5fN.js → localizeDateString-aLVQhrrE.js} +2 -2
- package/dist/{lt-LT-0WbfHH_o.js → lt-LT-C9nsCODy.js} +10 -1
- package/dist/{lt-LT-BLsIcCtE.js → lt-LT-CNTNKNlX.js} +3 -1
- package/dist/lt-LT-DWs-lYAv.js +13 -0
- package/dist/lt-LT-SQmafLDX.js +13 -0
- package/dist/lv-LV-B5Os0zqy.js +13 -0
- package/dist/{lv-LV-BZN4-Xat.js → lv-LV-BdPdaVGy.js} +2 -2
- package/dist/{lv-LV-BuuUUumH.js → lv-LV-Bue450PR.js} +10 -1
- package/dist/lv-LV-CdCU8ZaR.js +13 -0
- package/dist/{lv-LV-C7hMdPcY.js → lv-LV-N81Dgdm3.js} +3 -1
- package/dist/{mapExistingFile-BU4Lq435.js → mapExistingFile-CqGVkBAW.js} +4 -4
- package/dist/{mapJpAddressSchemaToAddressLocalizations-BLzSTlhK.js → mapJpAddressSchemaToAddressLocalizations-BDUUUodD.js} +2 -2
- package/dist/{mapLegalEntityToIndividualSchema-DHieAjhC.js → mapLegalEntityToIndividualSchema-CTNNZ_f2.js} +7 -7
- package/dist/{mapTransferInstrumentToPayoutAccount-CBruJcGL.js → mapTransferInstrumentToPayoutAccount-DC5rCBeC.js} +2 -2
- package/dist/{nl-NL-KsfqCp2v.js → nl-NL-4Mv4rnYy.js} +10 -1
- package/dist/{nl-NL-B0fvINJj.js → nl-NL-B2Uku0lw.js} +2 -2
- package/dist/nl-NL-BVRcJEzp.js +13 -0
- package/dist/nl-NL-D7k3hkBl.js +13 -0
- package/dist/{nl-NL-NlkjOSYi.js → nl-NL-Lo8OF_nj.js} +3 -1
- package/dist/{no-NO-Crlsj6HG.js → no-NO-6chPsZZE.js} +3 -1
- package/dist/{no-NO-BdG6WnpB.js → no-NO-ByCZ3mhz.js} +10 -1
- package/dist/no-NO-DOOgOJr1.js +13 -0
- package/dist/{no-NO-Jw7Gae-a.js → no-NO-DjOcJWnC.js} +2 -2
- package/dist/no-NO-DlnsfTwn.js +13 -0
- package/dist/{patternValidators-hk7OKIOW.js → patternValidators-re9oGFvp.js} +2 -2
- package/dist/pl-PL-B-V8iF6C.js +13 -0
- package/dist/pl-PL-Bvnak7w3.js +13 -0
- package/dist/{pl-PL-DYxD6VJ_.js → pl-PL-CbJSQVfe.js} +3 -1
- package/dist/{pl-PL-DW9eaUml.js → pl-PL-DCi5Lf4k.js} +10 -1
- package/dist/{process-field-configurations-CSUAI1_s.js → process-field-configurations-BLwIIYnH.js} +3 -3
- package/dist/{pt-BR-BaTE6BB_.js → pt-BR-BKdT0Bpl.js} +2 -2
- package/dist/pt-BR-BZkPZ0kK.js +13 -0
- package/dist/pt-BR-Bq41lr7C.js +13 -0
- package/dist/{pt-BR-BfxgHKY4.js → pt-BR-DRBFUW-X.js} +3 -1
- package/dist/{pt-BR-BdfWE-a1.js → pt-BR-DRz5cG4o.js} +10 -1
- package/dist/{pt-PT-TKg5FLat.js → pt-PT-BMOUpVLE.js} +3 -1
- package/dist/{pt-PT-c0ap84_F.js → pt-PT-C2li07N1.js} +2 -2
- package/dist/{pt-PT-ej54BPbB.js → pt-PT-ChRbnn0k.js} +10 -1
- package/dist/pt-PT-D-EPzKV-.js +13 -0
- package/dist/pt-PT-DkfqmPrD.js +13 -0
- package/dist/{resolveEnvironment-Dz4WVUeH.js → resolveEnvironment-CfoOtzJq.js} +3 -3
- package/dist/ro-RO-BEVRugNx.js +13 -0
- package/dist/{ro-RO-3rOfS17N.js → ro-RO-BJoL_nyS.js} +3 -1
- package/dist/{ro-RO-1ZFmLikG.js → ro-RO-Dgie5z3m.js} +10 -1
- package/dist/ro-RO-Dt2gs44k.js +13 -0
- package/dist/{ro-RO-BPOHV6Wp.js → ro-RO-iPjOeKwM.js} +2 -2
- package/dist/{roleMetadata-CCCowA5b.js → roleMetadata-DYV3rdBn.js} +3 -3
- package/dist/sk-SK-B6LcEArz.js +13 -0
- package/dist/sk-SK-Bh7WfMNd.js +13 -0
- package/dist/{sk-SK-CjrLvDMx.js → sk-SK-DxdxUonp.js} +3 -1
- package/dist/{sk-SK-Dm-pif_7.js → sk-SK-bMDoNP19.js} +10 -1
- package/dist/sl-SI-CxGdSydw.js +13 -0
- package/dist/{sl-SI-HO7231cu.js → sl-SI-DKSu25rO.js} +10 -1
- package/dist/sl-SI-DNbu8KiE.js +13 -0
- package/dist/{sl-SI-C-C-KJCX.js → sl-SI-UFngWs5n.js} +3 -1
- package/dist/style.css +80 -79
- package/dist/styles-CLV89_hH.js +80 -79
- package/dist/{sv-SE-D_Efxy3s.js → sv-SE-Blw4s8bC.js} +2 -2
- package/dist/sv-SE-CgB54Aa4.js +13 -0
- package/dist/{sv-SE-BcJ8p_Tx.js → sv-SE-Co7Nkd06.js} +10 -1
- package/dist/{sv-SE-BHfydid5.js → sv-SE-Cr0s35EH.js} +3 -1
- package/dist/sv-SE-DgMcRRS8.js +13 -0
- package/dist/{isNewEntity-7Vw_eQBr.js → trusted-fields-provider-BgfIoSNJ.js} +6 -3
- package/dist/types/api/invitedEntity/useInvitedEntityAssociationData.d.ts +7 -5
- package/dist/types/api/queryKeys.d.ts +2 -1
- package/dist/types/api/toggles/useToggles.d.ts +9 -0
- package/dist/types/components/BankAccount/forms/PayoutDetails/rules.d.ts +1 -1
- package/dist/types/components/BankAccount/forms/PayoutDetails/types.d.ts +2 -0
- package/dist/types/components/BankAccount/pages/PayoutDetailsPage.d.ts +0 -1
- package/dist/types/components/BankAccount/tasks/PayoutDetailsDropin/utils.d.ts +1 -1
- package/dist/types/components/Business/forms/rules.d.ts +6 -6
- package/dist/types/components/EFP/mapping/businessFinancingKeyMappings.d.ts +153 -153
- package/dist/types/components/Individual/forms/AdditionalPersonalDetails/validate.d.ts +3 -3
- package/dist/types/components/Individual/forms/DataConflictsModal/ConflictRow.d.ts +2 -2
- package/dist/types/components/Individual/forms/DataConflictsModal/DataConflictsModal.d.ts +6 -6
- package/dist/types/components/Individual/forms/Individual.rules.d.ts +2 -2
- package/dist/types/components/Shared/fields/TaxInformationField/fieldConfig.d.ts +1 -1
- package/dist/types/components/Shared/forms/Address/utils.d.ts +1 -1
- package/dist/types/components/Shared/forms/Address/validate.d.ts +4 -4
- package/dist/types/components/Trust/forms/Trust/rules.d.ts +2 -2
- package/dist/types/components/ui/atoms/Icon/Icon.d.ts +1 -1
- package/dist/types/components/ui/atoms/Svg/Svg.d.ts +1 -4
- package/dist/types/components/ui/atoms/Svg/svgs.d.ts +0 -4
- package/dist/types/context/ExperimentContext/ExperimentsContextProvider.d.ts +1 -1
- package/dist/types/context/ExperimentContext/types.d.ts +4 -5
- package/dist/types/language/utils.d.ts +1 -1
- package/dist/types/utils/entityStatusUtil.d.ts +1 -1
- package/dist/{types-BxMBuuEz.js → types-C-ztKw54.js} +2 -2
- package/dist/{types-D1PsvtzF.js → types-DP1DvIeR.js} +5 -6
- package/dist/{types-CYkhUYV6.js → types-g6JPEyyN.js} +2 -2
- package/dist/{types-DU69aeMN.js → types-uVH7U0h2.js} +2 -2
- package/dist/{Image-kVLn7Cb2.js → unincorporated-partnership-Hoe7PA91.js} +8 -7
- package/dist/{useAssociatedLegalEntity-BORPRBzY.js → useAssociatedLegalEntity-ucvdLTGT.js} +2 -2
- package/dist/{useBusinessDetailsData-SFopK4ma.js → useBusinessDetailsData-CxXKyGeU.js} +68 -57
- package/dist/{useCreateLegalEntity-DC4AmtL1.js → useCreateLegalEntity-Bk61sk7s.js} +2 -2
- package/dist/{useForm-B64f0N0r.js → useForm-DQH4mGUZ.js} +3 -3
- package/dist/{useFormContext-B08W9NV0.js → useFormContext-ZCKflTK_.js} +7 -7
- package/dist/{useGlobalData-CAfs9dkH.js → useGlobalData-Byz86Dwm.js} +2 -2
- package/dist/{useMultiForm-BwoKhXUz.js → useMultiForm-h2cXm0Wp.js} +4 -4
- package/dist/{useOnboardingStatus-DgaMwRGt.js → useOnboardingStatus-CrRySsUj.js} +1 -1
- package/dist/{useScenarios-DfdvyKrI.js → useScenarios-DZTIxRUa.js} +2 -2
- package/dist/{useTermsOfServiceStatus-BlBedFIs.js → useTermsOfServiceStatus-D7U4ZvId.js} +1 -1
- package/dist/{useToastContext-D7Wu9TN_.js → useToastContext-B6kjomhG.js} +2 -2
- package/dist/{useUnincorporatedPartnershipMembers-CRs95EuP.js → useUnincorporatedPartnershipMembers-DFI414tD.js} +5 -5
- package/dist/{useUpdateBusinessLines-B6YZCqOX.js → useUpdateBusinessLines-DwvzXYBi.js} +4 -4
- package/dist/{useUpdateLegalEntity-B1R9qggb.js → useUpdateLegalEntity-C6sJWLoQ.js} +3 -3
- package/dist/{utils-CPRZoX7V.js → utils-B4lHukc_.js} +6 -6
- package/dist/{utils-Drnia92l.js → utils-B_vtlCcH.js} +5 -19
- package/dist/{utils-DTUxA3nO.js → utils-Dc5iJioT.js} +2 -2
- package/dist/{utils-BUyOscpp.js → utils-DppirtL5.js} +2 -2
- package/dist/{utils-CnulHkMn.js → utils-b2XySOaT.js} +2 -2
- package/dist/{validate-DlUk1wzH.js → validate-Bb8eQLcr.js} +2 -2
- package/dist/{validate-DLxn3LIK.js → validate-QeOupYto.js} +3 -3
- package/dist/{validationError-CcsgWg6J.js → validationError-YeKQde9b.js} +2 -2
- package/package.json +6 -6
- package/dist/BusinessFinancingPage-CJXuD19C.js +0 -43
- package/dist/CreateIndividualComponent-BXI_yAXJ.js +0 -65
- package/dist/LegalRepresentativeDetailsPage-C3QWHa7T.js +0 -55
- package/dist/ManageIndividualComponent-DvmShxf5.js +0 -46
- package/dist/RootIndividualDetailsPage-8nUlp7YZ.js +0 -62
- package/dist/TrustMemberIndividualPage-DG9KUe02.js +0 -64
- package/dist/UnincorporatedPartnershipIndividualPage-DKMj8Dwh.js +0 -63
- package/dist/accountHolderUtils-yQ8liitv.js +0 -66
- package/dist/bg-BG-BNRJzjXu.js +0 -13
- package/dist/bg-BG-DAqp35Dx.js +0 -13
- package/dist/company-types-value-D_mKv5PT.js +0 -23
- package/dist/cs-CZ-BMnoWiIi.js +0 -13
- package/dist/cs-CZ-Ke47w0bj.js +0 -13
- package/dist/da-DK-Cx4-hLO1.js +0 -13
- package/dist/da-DK-D17SWJin.js +0 -13
- package/dist/de-DE-CL8D8vKZ.js +0 -13
- package/dist/de-DE-DC90bn2y.js +0 -13
- package/dist/el-GR-B2xt_Hn1.js +0 -13
- package/dist/el-GR-Dvv3-Qib.js +0 -13
- package/dist/en-US-CfIkXJPX.js +0 -13
- package/dist/es-ES-CzG-lilL.js +0 -13
- package/dist/es-ES-Vn4AcK9-.js +0 -13
- package/dist/et-EE-B7OzU-54.js +0 -13
- package/dist/et-EE-BeZJ4Ub1.js +0 -13
- package/dist/fi-FI-CWIaV6Iz.js +0 -13
- package/dist/fi-FI-DooPgPb1.js +0 -13
- package/dist/filterProblemsByTaskForms-Cz7iQtms.js +0 -30
- package/dist/fr-FR-29mQrnro.js +0 -13
- package/dist/fr-FR-CCb4Oux7.js +0 -13
- package/dist/getTrustedFields-C5-mXl-l.js +0 -64
- package/dist/hr-HR-BAI0N9bo.js +0 -13
- package/dist/hr-HR-BFu1_Xrc.js +0 -13
- package/dist/hu-HU-BpNDP1I8.js +0 -13
- package/dist/hu-HU-nf030gFT.js +0 -13
- package/dist/it-IT-BRO0Hf5X.js +0 -13
- package/dist/it-IT-CToDWXlu.js +0 -13
- package/dist/ja-JP-B3Y0VVpN.js +0 -152
- package/dist/ja-JP-BkAEknQ-.js +0 -13
- package/dist/lt-LT-DpszrZ9m.js +0 -13
- package/dist/lt-LT-DxzEdyVV.js +0 -13
- package/dist/lv-LV-B3IqVQos.js +0 -13
- package/dist/lv-LV-D-j-4Dao.js +0 -13
- package/dist/nl-NL-C8CEGqAc.js +0 -13
- package/dist/nl-NL-CnvvqAEg.js +0 -13
- package/dist/no-NO-CIKbQbKT.js +0 -13
- package/dist/no-NO-DbVtqyON.js +0 -13
- package/dist/pl-PL-Bxtudsvi.js +0 -13
- package/dist/pl-PL-CTOkaDMG.js +0 -13
- package/dist/pt-BR-CL4JYBNe.js +0 -13
- package/dist/pt-BR-CLUsrQAl.js +0 -13
- package/dist/pt-PT-BLRgiqFj.js +0 -13
- package/dist/pt-PT-C-OZtnUM.js +0 -13
- package/dist/ro-RO-BeA_YyJ8.js +0 -13
- package/dist/ro-RO-Dq1NTg-A.js +0 -13
- package/dist/sk-SK-CMvUjDgW.js +0 -13
- package/dist/sk-SK-Og9MJXpR.js +0 -13
- package/dist/sl-SI-BslBqaxO.js +0 -13
- package/dist/sl-SI-CoI7iOco.js +0 -13
- package/dist/sv-SE-ChoPzG_G.js +0 -13
- package/dist/sv-SE-Dm_WHV9V.js +0 -13
- package/dist/unincorporated-partnership-D8XzcFAz.js +0 -17
- package/dist/useBusinessLines-ewWROXYV.js +0 -29
- package/dist/useCanSeeIntroduction-BbjNCK9Z.js +0 -48
- package/dist/useDataMissingRemediations-CjxCe3yc.js +0 -41
- package/dist/useDeleteTransferInstrument-HN2BLhyP.js +0 -32
- package/dist/useNavigate-BXyVMJUH.js +0 -265
- package/dist/usePciQuestionnaireList--rMXF8VL.js +0 -29
- package/dist/useSalesChannels-CGESLvW6.js +0 -65
- package/dist/useTaskStatus-CBWvTwlZ.js +0 -51
- package/dist/useTrustMembers-GEABHhkr.js +0 -163
package/dist/{OnboardingDropinComponent-ByCzepLz.js → OnboardingDropinComponent-CvE6pJKz.js}
RENAMED
|
@@ -2,78 +2,99 @@
|
|
|
2
2
|
{
|
|
3
3
|
try {
|
|
4
4
|
let e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
|
|
5
|
-
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "
|
|
5
|
+
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "2de3a18f-5f24-4337-b05c-21c664e51242", e._sentryDebugIdIdentifier = "sentry-dbid-2de3a18f-5f24-4337-b05c-21c664e51242");
|
|
6
6
|
} catch (e) {
|
|
7
7
|
}
|
|
8
8
|
}
|
|
9
9
|
;
|
|
10
|
-
import {
|
|
10
|
+
import { b as useApiContext, h as httpPost, j as httpGet, k as useSettingsContext, m as createLogger, o as TaskStatuses, p as isPartOfTrustFromLegalEntity, q as hasSolePropInLegalEntity, L as LegalEntityTypes, r as hasOwnEntityAssociationOfType, t as isEmptyEntity, v as useAccountHolder, u as useTranslation, w as EntityTypes, x as DATA_MISSING_DECISION_MAKER_ERROR_CODE_MAPPING, y as TaskTypes, z as useAnalyticsContext, B as Icon, C as IconButton, G as Alert, H as TaskVerificationStatus, J as useExperimentsContext, K as isInstantVerifiedAccount, M as getObscuredAccountNumber, N as useGetTaskStatus, O as Typography, P as StackLayout, R as useLegalEntity, U as ROOT_LE, V as Loader, W as Button, X as useGlobalStore, Y as TASK_STATUS_COMPLETED_POLLING_INTERVAL_MS, Z as TASK_STATUS_POLLING_INTERVAL_MS, $ as useSetting, a0 as isPartOfUnincorporatedPartnership, a1 as doesLegalEntityRequiresLegalRepresentative, a2 as getLegalRepresentative, a3 as getOwnSignatories, a4 as getOwnDecisionMakersLegalEntityIds, a5 as getOwnSolePropProblems, a6 as getOwnTrustProblems, a7 as getOwnUnincorporatedPartnershipProblems, a8 as useLocalStorage, a9 as getLegalEntityCountry, aa as CountryCodes, ab as Skeleton, ac as translateTranslatable, ad as getOwnEntityAssociations, ae as TrustMemberTypes, af as hasAllCapabilitiesResolved, ag as hasRejectedCapabilities, ah as objectsDeepEqual, ai as noop, aj as useToggles, a as addResourceBundles, _ as __variableDynamicImportRuntimeHelper } from "./StoreProvider-OuIcrYXq.js";
|
|
11
11
|
import { jsxs, Fragment, jsx } from "preact/jsx-runtime";
|
|
12
12
|
import { useQuery, skipToken } from "@tanstack/preact-query";
|
|
13
13
|
import { lazy, Suspense } from "preact/compat";
|
|
14
|
-
import { useState, useEffect, useReducer,
|
|
15
|
-
import { u as
|
|
16
|
-
import { u as usePciQuestionnaireList, g as getPciQuestionnaireList } from "./usePciQuestionnaireList--rMXF8VL.js";
|
|
17
|
-
import { u as useSalesChannels, a as usePciStatus } from "./useSalesChannels-CGESLvW6.js";
|
|
18
|
-
import { g as getAccountTaskStatus, u as useTaskStatus } from "./useTaskStatus-CBWvTwlZ.js";
|
|
19
|
-
import { u as useTermsOfServiceStatus, a as useTermsOfServiceAcceptanceInfos } from "./useTermsOfServiceStatus-BlBedFIs.js";
|
|
14
|
+
import { useMemo, useState, useEffect, useReducer, useCallback, useContext, useRef } from "preact/hooks";
|
|
15
|
+
import { u as useTermsOfServiceStatus, a as useTermsOfServiceAcceptanceInfos } from "./useTermsOfServiceStatus-D7U4ZvId.js";
|
|
20
16
|
import { C as Card } from "./Card-OQuFzmxm.js";
|
|
21
17
|
import { S as SettingNames } from "./types-CQ2p58-6.js";
|
|
22
|
-
import { u as useToastContext } from "./useToastContext-
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import { u as useDataMissingRemediations } from "./useDataMissingRemediations-CjxCe3yc.js";
|
|
27
|
-
import { u as useCapabilityProblems } from "./getProblemsForEntity-B2aPSiz5.js";
|
|
18
|
+
import { u as useToastContext } from "./useToastContext-B6kjomhG.js";
|
|
19
|
+
import { C as CompanyTypesValues, i as isBafinSignatoryFlow, s as showIdNowModal, a as idNowPostSubmit } from "./bafinUtils-IYWLuHfZ.js";
|
|
20
|
+
import { E as EndStateLayout } from "./EndStateLayout-C63kFcwB.js";
|
|
21
|
+
import { u as useCapabilityProblems } from "./getProblemsForEntity-1vXQVg7Q.js";
|
|
28
22
|
import { d as downloadFile } from "./file-CiG1D0zy.js";
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import { T as TrustedFieldsProviders, I as Image } from "./Image-kVLn7Cb2.js";
|
|
37
|
-
import { g as getTrustedFieldsProvider } from "./getTrustedFields-C5-mXl-l.js";
|
|
38
|
-
import { u as useAssociatedLegalEntity } from "./useAssociatedLegalEntity-BORPRBzY.js";
|
|
23
|
+
import { V as VerificationErrorAlert, u as useDeleteTransferInstrument } from "./VerificationErrorAlert-C-FdjLP6.js";
|
|
24
|
+
import { A as Avatar } from "./Avatar-Brfu-Afq.js";
|
|
25
|
+
import { L as LoaderWrapper } from "./LoaderWrapper-BrMjOh8d.js";
|
|
26
|
+
import { C as Confirm } from "./Confirm-DCXKUVXM.js";
|
|
27
|
+
import { E as ExperimentNames } from "./types-DP1DvIeR.js";
|
|
28
|
+
import { T as TrustedFieldsProviders } from "./trusted-fields-provider-BgfIoSNJ.js";
|
|
29
|
+
import { u as useAssociatedLegalEntity } from "./useAssociatedLegalEntity-ucvdLTGT.js";
|
|
39
30
|
import cx from "classnames";
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import { U as UnincorporatedPartnershipMemberTypes } from "./unincorporated-partnership-D8XzcFAz.js";
|
|
44
|
-
import { Route, Switch, useRouter, useLocation, matchRoute, Router } from "wouter-preact";
|
|
31
|
+
import { I as Image, U as UnincorporatedPartnershipMemberTypes } from "./unincorporated-partnership-Hoe7PA91.js";
|
|
32
|
+
import { g as getLegalEntityNameBasedOnType } from "./getName-B38W_qUJ.js";
|
|
33
|
+
import { matchRoute, useLocation, Route, Switch, useRouter, Router } from "wouter-preact";
|
|
45
34
|
import { memoryLocation } from "wouter-preact/memory-location";
|
|
46
35
|
import { createContext } from "preact";
|
|
47
|
-
|
|
48
|
-
const
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
}
|
|
61
|
-
if (showBusinessFinancingFirst) {
|
|
62
|
-
return TaskTypes.BUSINESS_FINANCING;
|
|
63
|
-
}
|
|
64
|
-
if (canChangeEntityType && canSeeEntitySelection && !hasLegalEntityProgressedBeyondEntitySelection)
|
|
65
|
-
return TaskTypes.BUSINESS_TYPE_SELECTION;
|
|
66
|
-
if (showIntroduction) return TaskTypes.INTRODUCTION;
|
|
67
|
-
if (shouldShowSingpassSelection) return TaskTypes.SINGPASS_SELECTION;
|
|
68
|
-
return TaskTypes.TASKS_OVERVIEW;
|
|
69
|
-
};
|
|
70
|
-
const hasProgressedBeyondEntitySelection$1 = (legalEntity) => {
|
|
71
|
-
const hasOwnEntityAssocation = legalEntity.entityAssociations?.some(
|
|
72
|
-
(ea) => ea.associatorId === legalEntity.id
|
|
36
|
+
const getPciStatus = async (legalEntityId, baseUrl, data) => {
|
|
37
|
+
const filteredData = {
|
|
38
|
+
...data,
|
|
39
|
+
additionalSalesChannels: data.additionalSalesChannels?.filter(
|
|
40
|
+
(channel) => channel !== "payByLink"
|
|
41
|
+
)
|
|
42
|
+
};
|
|
43
|
+
return httpPost(
|
|
44
|
+
{
|
|
45
|
+
baseUrl,
|
|
46
|
+
path: `legalEntities/${legalEntityId}/pci/signingRequired`
|
|
47
|
+
},
|
|
48
|
+
filteredData
|
|
73
49
|
);
|
|
74
|
-
const hasOrganizationType = legalEntity.organization?.type;
|
|
75
|
-
return hasOwnEntityAssocation || !!hasOrganizationType;
|
|
76
50
|
};
|
|
51
|
+
const usePciStatus = (data, options) => {
|
|
52
|
+
const { rootLegalEntityId, baseUrl } = useApiContext();
|
|
53
|
+
return useQuery({
|
|
54
|
+
queryKey: ["pciStatus", data],
|
|
55
|
+
queryFn: () => getPciStatus(rootLegalEntityId.value, baseUrl.value, data),
|
|
56
|
+
staleTime: 0,
|
|
57
|
+
...options
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
const getBusinessLines = async (legalEntityId, baseUrl) => {
|
|
61
|
+
return httpGet({
|
|
62
|
+
baseUrl,
|
|
63
|
+
path: `legalEntities/${legalEntityId}/businessLines`
|
|
64
|
+
});
|
|
65
|
+
};
|
|
66
|
+
const useBusinessLines = (businessLineType, options) => {
|
|
67
|
+
const { rootLegalEntityId, baseUrl } = useApiContext();
|
|
68
|
+
return useQuery({
|
|
69
|
+
queryKey: ["businessLines"],
|
|
70
|
+
queryFn: () => getBusinessLines(rootLegalEntityId.value, baseUrl.value),
|
|
71
|
+
select: (businessLines) => businessLines.filter((businessLine) => businessLineType.includes(businessLine.service)),
|
|
72
|
+
...options
|
|
73
|
+
});
|
|
74
|
+
};
|
|
75
|
+
function useSalesChannels() {
|
|
76
|
+
const { isSettingEnabled } = useSettingsContext();
|
|
77
|
+
const { data: existingBusinessLines } = useBusinessLines(["paymentProcessing"]);
|
|
78
|
+
return useMemo(() => {
|
|
79
|
+
const settings = [];
|
|
80
|
+
const businessLinesSalesChannels = [
|
|
81
|
+
...new Set(existingBusinessLines?.flatMap((item) => item.salesChannels ?? []))
|
|
82
|
+
];
|
|
83
|
+
if (isSettingEnabled(SettingNames.RequirePciSignEcommerce)) {
|
|
84
|
+
settings.push("eCommerce");
|
|
85
|
+
}
|
|
86
|
+
if (isSettingEnabled(SettingNames.RequirePciSignPos)) {
|
|
87
|
+
settings.push("pos");
|
|
88
|
+
}
|
|
89
|
+
if (isSettingEnabled(SettingNames.RequirePciSignEcomMoto)) {
|
|
90
|
+
settings.push("ecomMoto");
|
|
91
|
+
}
|
|
92
|
+
if (isSettingEnabled(SettingNames.RequirePciSignPosMoto)) {
|
|
93
|
+
settings.push("posMoto");
|
|
94
|
+
}
|
|
95
|
+
return isSettingEnabled("allowBusinessLines") ? businessLinesSalesChannels : settings;
|
|
96
|
+
}, [existingBusinessLines, isSettingEnabled]);
|
|
97
|
+
}
|
|
77
98
|
const getTaskTypes = async (id, baseUrl) => {
|
|
78
99
|
return httpGet({
|
|
79
100
|
baseUrl,
|
|
@@ -94,6 +115,141 @@ const getPciQuestionnaire = async (legalEntityId, baseUrl, documentId) => {
|
|
|
94
115
|
path: `legalEntities/${legalEntityId}/pci/questionnaires/${documentId}`
|
|
95
116
|
});
|
|
96
117
|
};
|
|
118
|
+
const getPciQuestionnaireList = async (legalEntityId, baseUrl) => {
|
|
119
|
+
return httpGet({
|
|
120
|
+
baseUrl,
|
|
121
|
+
path: `legalEntities/${legalEntityId}/pci/questionnaires`
|
|
122
|
+
});
|
|
123
|
+
};
|
|
124
|
+
const usePciQuestionnaireList = (options) => {
|
|
125
|
+
const { rootLegalEntityId, baseUrl } = useApiContext();
|
|
126
|
+
return useQuery({
|
|
127
|
+
queryKey: ["pciQuestionnaireList"],
|
|
128
|
+
queryFn: () => getPciQuestionnaireList(rootLegalEntityId.value, baseUrl.value),
|
|
129
|
+
...options
|
|
130
|
+
});
|
|
131
|
+
};
|
|
132
|
+
const logger$2 = createLogger();
|
|
133
|
+
const normalizeTaskStatuses = (taskStatuses) => {
|
|
134
|
+
return taskStatuses?.statuses?.reduce((acc, currentTask) => {
|
|
135
|
+
const status = TaskStatuses[currentTask.status];
|
|
136
|
+
const statusEntries = currentTask.taskStatusEntries;
|
|
137
|
+
acc[currentTask.type] = {
|
|
138
|
+
status: status ?? TaskStatuses.DETAILS_REQUIRED,
|
|
139
|
+
taskStatusEntries: statusEntries
|
|
140
|
+
};
|
|
141
|
+
return acc;
|
|
142
|
+
}, {});
|
|
143
|
+
};
|
|
144
|
+
const getAccountTaskStatus = (accountId, payinPayoutTaskStatus) => {
|
|
145
|
+
const taskStatusEntries = payinPayoutTaskStatus?.taskStatusEntries;
|
|
146
|
+
const taskStatusEntry = taskStatusEntries?.find((entry) => entry.id.includes(accountId));
|
|
147
|
+
if (!taskStatusEntry) {
|
|
148
|
+
logger$2.warn(`No task status for this account: ${accountId}`);
|
|
149
|
+
return payinPayoutTaskStatus?.status ?? TaskStatuses.PROCESSING;
|
|
150
|
+
}
|
|
151
|
+
return TaskStatuses[taskStatusEntry.status];
|
|
152
|
+
};
|
|
153
|
+
const getTaskStatus = async (legalEntityId, baseUrl) => {
|
|
154
|
+
return httpGet({
|
|
155
|
+
baseUrl,
|
|
156
|
+
path: `legalEntities/${legalEntityId}/taskStatus`
|
|
157
|
+
});
|
|
158
|
+
};
|
|
159
|
+
const useTaskStatus = (options) => {
|
|
160
|
+
const { rootLegalEntityId, baseUrl } = useApiContext();
|
|
161
|
+
return useQuery({
|
|
162
|
+
queryKey: ["taskStatus"],
|
|
163
|
+
queryFn: () => getTaskStatus(rootLegalEntityId.value, baseUrl.value),
|
|
164
|
+
select: (data) => normalizeTaskStatuses(data),
|
|
165
|
+
...options
|
|
166
|
+
});
|
|
167
|
+
};
|
|
168
|
+
const useLegalEntityType = ({
|
|
169
|
+
legalEntity
|
|
170
|
+
}) => {
|
|
171
|
+
const isTrust = isPartOfTrustFromLegalEntity(legalEntity);
|
|
172
|
+
const isSoleProprietor = hasSolePropInLegalEntity(legalEntity);
|
|
173
|
+
const hasLegalAssociation = isTrust || isSoleProprietor;
|
|
174
|
+
switch (legalEntity.type) {
|
|
175
|
+
case LegalEntityTypes.INDIVIDUAL:
|
|
176
|
+
case LegalEntityTypes.ORGANIZATION:
|
|
177
|
+
if (!hasLegalAssociation) return legalEntity.type;
|
|
178
|
+
if (isSoleProprietor) return LegalEntityTypes.SOLE_PROPRIETORSHIP;
|
|
179
|
+
if (isTrust) return LegalEntityTypes.TRUST;
|
|
180
|
+
break;
|
|
181
|
+
default:
|
|
182
|
+
return void 0;
|
|
183
|
+
}
|
|
184
|
+
};
|
|
185
|
+
const useCanSeeIntroduction = ({ legalEntity }) => {
|
|
186
|
+
const legalEntityType = useLegalEntityType({ legalEntity });
|
|
187
|
+
const { isSettingEnabled } = useSettingsContext();
|
|
188
|
+
switch (legalEntityType) {
|
|
189
|
+
case LegalEntityTypes.INDIVIDUAL:
|
|
190
|
+
return !isSettingEnabled(SettingNames.HideOnboardingIntroductionIndividual);
|
|
191
|
+
case LegalEntityTypes.ORGANIZATION:
|
|
192
|
+
return !isSettingEnabled(SettingNames.HideOnboardingIntroductionOrganization);
|
|
193
|
+
case LegalEntityTypes.SOLE_PROPRIETORSHIP:
|
|
194
|
+
return !isSettingEnabled(SettingNames.HideOnboardingIntroductionSoleProprietor);
|
|
195
|
+
case LegalEntityTypes.TRUST:
|
|
196
|
+
return !isSettingEnabled(SettingNames.HideOnboardingIntroductionTrust);
|
|
197
|
+
default:
|
|
198
|
+
return false;
|
|
199
|
+
}
|
|
200
|
+
};
|
|
201
|
+
const capabilitiesToPreventTypeChange = [
|
|
202
|
+
"receivePayments",
|
|
203
|
+
"issueCard",
|
|
204
|
+
"useCard",
|
|
205
|
+
"withdrawFromAtm",
|
|
206
|
+
"withdrawFromAtmInRestrictedCountries",
|
|
207
|
+
"useCardInRestrictedCountries",
|
|
208
|
+
"useCardInRestrictedIndustries",
|
|
209
|
+
"issueBankAccount",
|
|
210
|
+
"sendToThirdParty",
|
|
211
|
+
"receiveFromThirdParty",
|
|
212
|
+
"getGrantOffers",
|
|
213
|
+
"receiveGrants"
|
|
214
|
+
];
|
|
215
|
+
const entityTypeToCorrespondingAccountHolderOption = {
|
|
216
|
+
[LegalEntityTypes.INDIVIDUAL]: "myName",
|
|
217
|
+
[LegalEntityTypes.ORGANIZATION]: "theCompanyIWorkFor",
|
|
218
|
+
[LegalEntityTypes.SOLE_PROPRIETORSHIP]: "mySoleProprietorName",
|
|
219
|
+
[LegalEntityTypes.TRUST]: "aTrust",
|
|
220
|
+
[LegalEntityTypes.UNINCORPORATED_PARTNERSHIP]: "anUnincorporatedPartnership"
|
|
221
|
+
};
|
|
222
|
+
const getDefaultAccountHolderType = (legalEntityResponse, isTypeChanging = false, accountHolder) => {
|
|
223
|
+
if (!legalEntityResponse?.type) return void 0;
|
|
224
|
+
if (hasOwnEntityAssociationOfType(
|
|
225
|
+
LegalEntityTypes.SOLE_PROPRIETORSHIP,
|
|
226
|
+
legalEntityResponse.entityAssociations,
|
|
227
|
+
legalEntityResponse.id
|
|
228
|
+
)) {
|
|
229
|
+
return "mySoleProprietorName";
|
|
230
|
+
}
|
|
231
|
+
if (hasOwnEntityAssociationOfType(
|
|
232
|
+
LegalEntityTypes.TRUST,
|
|
233
|
+
legalEntityResponse.entityAssociations,
|
|
234
|
+
legalEntityResponse.id
|
|
235
|
+
)) {
|
|
236
|
+
return "aTrust";
|
|
237
|
+
}
|
|
238
|
+
if (hasOwnEntityAssociationOfType(
|
|
239
|
+
LegalEntityTypes.UNINCORPORATED_PARTNERSHIP,
|
|
240
|
+
legalEntityResponse.entityAssociations,
|
|
241
|
+
legalEntityResponse.id
|
|
242
|
+
)) {
|
|
243
|
+
return "anUnincorporatedPartnership";
|
|
244
|
+
}
|
|
245
|
+
if (accountHolder) {
|
|
246
|
+
return accountHolder;
|
|
247
|
+
}
|
|
248
|
+
if (isTypeChanging || !isEmptyEntity(legalEntityResponse)) {
|
|
249
|
+
return entityTypeToCorrespondingAccountHolderOption[legalEntityResponse.type];
|
|
250
|
+
}
|
|
251
|
+
};
|
|
252
|
+
const allowIndividualWithoutSoleProp = (capabilities) => !capabilities?.map((c) => c.replace("Commercial", "").replace("Consumer", "")).some((c) => capabilitiesToPreventTypeChange.includes(c));
|
|
97
253
|
const BusinessTypes = {
|
|
98
254
|
INDIVIDUAL: "individual",
|
|
99
255
|
COMPANY: "company",
|
|
@@ -140,6 +296,51 @@ const useBusinessSetup = (legalEntityResponse) => {
|
|
|
140
296
|
const businessSetup = accountHolderType === "theCompanyIWorkFor" && organizationType ? companyTypesMapping[organizationType] : businessTypeMapping[accountHolderType]?.[legalEntityResponse.type];
|
|
141
297
|
return businessSetup;
|
|
142
298
|
};
|
|
299
|
+
function useDataMissingRemediations({
|
|
300
|
+
legalEntityId,
|
|
301
|
+
problems
|
|
302
|
+
}) {
|
|
303
|
+
const { t } = useTranslation("common");
|
|
304
|
+
const decisionMakersRemediationMessage = useMemo(() => {
|
|
305
|
+
const remediationCodes = problems[EntityTypes.LEGAL_ENTITY]?.[legalEntityId]?.missingData?.reduce((remediations, error) => {
|
|
306
|
+
const remediation = DATA_MISSING_DECISION_MAKER_ERROR_CODE_MAPPING[error.code];
|
|
307
|
+
return remediation ? [...remediations, remediation] : remediations;
|
|
308
|
+
}, []);
|
|
309
|
+
const uniqueRemediations = [...new Set(remediationCodes)];
|
|
310
|
+
switch (uniqueRemediations?.length) {
|
|
311
|
+
case void 0:
|
|
312
|
+
case 0:
|
|
313
|
+
return void 0;
|
|
314
|
+
case 1:
|
|
315
|
+
return uniqueRemediations[0] ? t(($) => $[`remediationMessage_${uniqueRemediations[0]}`]) : t(($) => $["missingMultipleDecisionMakers"]);
|
|
316
|
+
default:
|
|
317
|
+
return t(($) => $["missingMultipleDecisionMakers"]);
|
|
318
|
+
}
|
|
319
|
+
}, [problems, t, legalEntityId]);
|
|
320
|
+
return {
|
|
321
|
+
remediationMessages: {
|
|
322
|
+
[TaskTypes.DECISION_MAKER]: decisionMakersRemediationMessage
|
|
323
|
+
}
|
|
324
|
+
};
|
|
325
|
+
}
|
|
326
|
+
const filterProblemsByTaskForms = (entityProblems, forms) => {
|
|
327
|
+
if (!entityProblems?.verificationErrors) return entityProblems;
|
|
328
|
+
const filteredEntityProblems = Object.entries(entityProblems.verificationErrors).reduce(
|
|
329
|
+
(acc, [formId, verificationErrors]) => {
|
|
330
|
+
if (!forms.includes(formId)) return acc;
|
|
331
|
+
return {
|
|
332
|
+
...entityProblems,
|
|
333
|
+
verificationErrors: {
|
|
334
|
+
...acc.verificationErrors,
|
|
335
|
+
[formId]: verificationErrors
|
|
336
|
+
}
|
|
337
|
+
};
|
|
338
|
+
},
|
|
339
|
+
{}
|
|
340
|
+
);
|
|
341
|
+
filteredEntityProblems.verificationErrors = Object.keys(filteredEntityProblems.verificationErrors ?? {}).length > 0 ? filteredEntityProblems.verificationErrors : void 0;
|
|
342
|
+
return filteredEntityProblems;
|
|
343
|
+
};
|
|
143
344
|
const businessFormIds = [
|
|
144
345
|
"basicInformation",
|
|
145
346
|
"businessSelection",
|
|
@@ -304,8 +505,8 @@ const PayoutAccountTaskListItem = ({
|
|
|
304
505
|
const { mutateAsync: deleteTransferInstrument } = useDeleteTransferInstrument();
|
|
305
506
|
const isInstantVerificationAccount = isInstantVerifiedAccount(account);
|
|
306
507
|
const obscuredAccountNumber = getObscuredAccountNumber(account);
|
|
307
|
-
const
|
|
308
|
-
const status = isExperimentEnabled("UseTaskStatusApiForPayout") ? getAccountTaskStatus(account.id, payinPayoutTaskStatus) :
|
|
508
|
+
const getTaskStatus2 = useGetTaskStatus();
|
|
509
|
+
const status = isExperimentEnabled("UseTaskStatusApiForPayout") ? getAccountTaskStatus(account.id, payinPayoutTaskStatus) : getTaskStatus2(TaskTypes.PAYOUT, account.id);
|
|
309
510
|
const handleDeleteTransferInstrument = async () => {
|
|
310
511
|
try {
|
|
311
512
|
await deleteTransferInstrument(account.id);
|
|
@@ -341,13 +542,26 @@ const LEGAL_ENTITY_BASE_TASKS = [
|
|
|
341
542
|
const CONTRACT_TASKS = [TaskTypes.SERVICE_AGREEMENT, TaskTypes.PCI_DSS];
|
|
342
543
|
function TaskList({ onNavigateToTask, singpassComponent }) {
|
|
343
544
|
const { data: rootLe, isLoading } = useLegalEntity(ROOT_LE);
|
|
344
|
-
const {
|
|
345
|
-
|
|
346
|
-
|
|
545
|
+
const { t } = useTranslation("common");
|
|
546
|
+
const {
|
|
547
|
+
data: existingBusinessLines,
|
|
548
|
+
isLoading: isLoadingBl,
|
|
549
|
+
error: businessLinesError
|
|
550
|
+
} = useBusinessLines(["paymentProcessing"]);
|
|
347
551
|
const capabilityProblems = useCapabilityProblems() ?? {};
|
|
348
552
|
if (isLoading || !rootLe || isLoadingBl) {
|
|
349
553
|
return /* @__PURE__ */ jsx(Loader, { size: "large" });
|
|
350
554
|
}
|
|
555
|
+
if (businessLinesError) {
|
|
556
|
+
return /* @__PURE__ */ jsx(
|
|
557
|
+
EndStateLayout,
|
|
558
|
+
{
|
|
559
|
+
title: t(($) => $["thisPageIsntLoading"]),
|
|
560
|
+
variant: "error",
|
|
561
|
+
action: /* @__PURE__ */ jsx(Button, { onClick: () => window.location.reload(), fullWidth: true, children: t(($) => $["reloadPage"]) })
|
|
562
|
+
}
|
|
563
|
+
);
|
|
564
|
+
}
|
|
351
565
|
return /* @__PURE__ */ jsx(
|
|
352
566
|
TaskListInner,
|
|
353
567
|
{
|
|
@@ -374,7 +588,7 @@ function TaskListInner({
|
|
|
374
588
|
const { isExperimentEnabled } = useExperimentsContext();
|
|
375
589
|
const { accountHolder } = useAccountHolder();
|
|
376
590
|
const tasks = useGlobalStore().tasks.value;
|
|
377
|
-
const
|
|
591
|
+
const getTaskStatus2 = useGetTaskStatus();
|
|
378
592
|
const businessSetup = useBusinessSetup(legalEntityResponse);
|
|
379
593
|
const canSeeIntroduction = useCanSeeIntroduction({ legalEntity: legalEntityResponse });
|
|
380
594
|
const additionalSalesChannels = useSalesChannels();
|
|
@@ -546,7 +760,7 @@ function TaskListInner({
|
|
|
546
760
|
onNavigateToTask: handleOnNavigateToTaskIndividual,
|
|
547
761
|
icon: "decision-maker",
|
|
548
762
|
titleKey: hasTrust ? "trusteePersonalDetails" : hasUnincorporatedPartnership ? "primaryPartnerDetails" : "personalDetails",
|
|
549
|
-
status:
|
|
763
|
+
status: getTaskStatus2(TaskTypes.INDIVIDUAL),
|
|
550
764
|
problems: filterProblemsByTaskForms(rootLegalEntityProblems, fullIndividualFormIds)
|
|
551
765
|
}
|
|
552
766
|
),
|
|
@@ -567,7 +781,7 @@ function TaskListInner({
|
|
|
567
781
|
onNavigateToTask: handleOnNavigateToSoleProp,
|
|
568
782
|
icon: "company",
|
|
569
783
|
titleKey: canChangeEntityType ? "soleProprietorshipDetails" : "soleProprietorDetails",
|
|
570
|
-
status:
|
|
784
|
+
status: getTaskStatus2(TaskTypes.SOLE_PROPRIETOR_COMPANY),
|
|
571
785
|
problems: getOwnSolePropProblems(legalEntityResponse, capabilityProblems)
|
|
572
786
|
}
|
|
573
787
|
),
|
|
@@ -577,7 +791,7 @@ function TaskListInner({
|
|
|
577
791
|
onNavigateToTask: handleOnNavigateToTaskLegalRepresentative,
|
|
578
792
|
icon: "decision-maker",
|
|
579
793
|
titleKey: "legalRepresentative",
|
|
580
|
-
status:
|
|
794
|
+
status: getTaskStatus2(TaskTypes.LEGAL_REPRESENTATIVE_DETAILS)
|
|
581
795
|
}
|
|
582
796
|
),
|
|
583
797
|
tasks.includes(TaskTypes.DECISION_MAKER_OVERVIEW) && /* @__PURE__ */ jsx(
|
|
@@ -586,7 +800,7 @@ function TaskListInner({
|
|
|
586
800
|
onNavigateToTask: handleOnNavigateToTaskDecisionMaker,
|
|
587
801
|
icon: "decision-maker",
|
|
588
802
|
titleKey: hasUnincorporatedPartnership ? "entityDecisionMakers" : "decisionMakers",
|
|
589
|
-
status:
|
|
803
|
+
status: getTaskStatus2(TaskTypes.DECISION_MAKER_OVERVIEW),
|
|
590
804
|
warningMessage: showDecisionMakersWarning ? remediationMessages[TaskTypes.DECISION_MAKER] : void 0
|
|
591
805
|
}
|
|
592
806
|
),
|
|
@@ -618,7 +832,7 @@ function TaskListInner({
|
|
|
618
832
|
onNavigateToTask: handleOnNavigateToTaskTrust,
|
|
619
833
|
icon: "trust",
|
|
620
834
|
titleKey: "trustDetails",
|
|
621
|
-
status:
|
|
835
|
+
status: getTaskStatus2(TaskTypes.TRUST),
|
|
622
836
|
problems: getOwnTrustProblems(legalEntityResponse, capabilityProblems)
|
|
623
837
|
}
|
|
624
838
|
),
|
|
@@ -628,7 +842,7 @@ function TaskListInner({
|
|
|
628
842
|
onNavigateToTask: handleOnNavigateToTaskTrustMember,
|
|
629
843
|
icon: "decision-maker",
|
|
630
844
|
titleKey: "trustMembers",
|
|
631
|
-
status:
|
|
845
|
+
status: getTaskStatus2(TaskTypes.TRUST_MEMBER_OVERVIEW)
|
|
632
846
|
}
|
|
633
847
|
)
|
|
634
848
|
] }),
|
|
@@ -639,7 +853,7 @@ function TaskListInner({
|
|
|
639
853
|
onNavigateToTask: () => onNavigateToTask(TaskTypes.UNINCORPORATED_PARTNERSHIP),
|
|
640
854
|
icon: "trust",
|
|
641
855
|
titleKey: "unincorporatedDetails",
|
|
642
|
-
status:
|
|
856
|
+
status: getTaskStatus2(TaskTypes.UNINCORPORATED_PARTNERSHIP),
|
|
643
857
|
problems: getOwnUnincorporatedPartnershipProblems(
|
|
644
858
|
legalEntityResponse,
|
|
645
859
|
capabilityProblems
|
|
@@ -658,7 +872,7 @@ function TaskListInner({
|
|
|
658
872
|
},
|
|
659
873
|
icon: "decision-maker",
|
|
660
874
|
titleKey: "unincorporatedPartnershipMembers",
|
|
661
|
-
status:
|
|
875
|
+
status: getTaskStatus2(TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_OVERVIEW)
|
|
662
876
|
}
|
|
663
877
|
)
|
|
664
878
|
] }),
|
|
@@ -812,6 +1026,56 @@ const getOpenIdAuthorizationLink = async (legalEntityId, baseUrl) => {
|
|
|
812
1026
|
})
|
|
813
1027
|
);
|
|
814
1028
|
};
|
|
1029
|
+
function getTrustedFields(rootLegalEntity, apiMapping, provider) {
|
|
1030
|
+
const apiTrustedFields = getApiTrustedFields(rootLegalEntity);
|
|
1031
|
+
return parseTrustedFieldsIntoReadOnlyFields(apiTrustedFields, apiMapping);
|
|
1032
|
+
}
|
|
1033
|
+
function getTrustedEntityAssociations(rootLegalEntity, provider) {
|
|
1034
|
+
const apiTrustedFields = getApiTrustedFields(rootLegalEntity);
|
|
1035
|
+
return parseTrustedEntityAssociationsFromApiFields(apiTrustedFields);
|
|
1036
|
+
}
|
|
1037
|
+
function getTrustedFieldsProvider(rootLegalEntity) {
|
|
1038
|
+
return rootLegalEntity.trustedFields?.[0].provider;
|
|
1039
|
+
}
|
|
1040
|
+
const getApiTrustedFields = (rootLegalEntity, provider) => rootLegalEntity.trustedFields?.find((tf) => true)?.fields ?? [];
|
|
1041
|
+
function parseTrustedFieldsIntoReadOnlyFields(trustedFields, mapping) {
|
|
1042
|
+
const formFieldsMapped = [];
|
|
1043
|
+
trustedFields.forEach((field) => {
|
|
1044
|
+
for (const [key, value] of Object.entries(mapping)) {
|
|
1045
|
+
if (value === field) {
|
|
1046
|
+
formFieldsMapped.push(key);
|
|
1047
|
+
}
|
|
1048
|
+
}
|
|
1049
|
+
});
|
|
1050
|
+
const readOnlyFields = {};
|
|
1051
|
+
formFieldsMapped.forEach((field) => {
|
|
1052
|
+
const tokenizedField = field.split(".");
|
|
1053
|
+
const formField = tokenizedField.pop();
|
|
1054
|
+
const formId = tokenizedField.pop();
|
|
1055
|
+
if (formField && formId) {
|
|
1056
|
+
if (formId in readOnlyFields) {
|
|
1057
|
+
readOnlyFields[formId].push(formField);
|
|
1058
|
+
} else {
|
|
1059
|
+
readOnlyFields[formId] = [formField];
|
|
1060
|
+
}
|
|
1061
|
+
}
|
|
1062
|
+
});
|
|
1063
|
+
return readOnlyFields;
|
|
1064
|
+
}
|
|
1065
|
+
function parseTrustedEntityAssociationsFromApiFields(trustedApiFields) {
|
|
1066
|
+
const rawTrustedEntityAssociations = trustedApiFields.filter((f) => f.startsWith("entityAssociations")) ?? [];
|
|
1067
|
+
const leIdMap = {};
|
|
1068
|
+
rawTrustedEntityAssociations.forEach((rtea) => {
|
|
1069
|
+
const [_, role, leId] = rtea.split(".");
|
|
1070
|
+
const trustedRole = role;
|
|
1071
|
+
if (!leIdMap[leId]) {
|
|
1072
|
+
leIdMap[leId] = { roles: [trustedRole] };
|
|
1073
|
+
} else {
|
|
1074
|
+
leIdMap[leId] = { roles: [...leIdMap[leId].roles, trustedRole] };
|
|
1075
|
+
}
|
|
1076
|
+
});
|
|
1077
|
+
return Object.keys(leIdMap).map((reference) => ({ reference, types: leIdMap[reference].roles }));
|
|
1078
|
+
}
|
|
815
1079
|
const SingpassMyInfoLoginActionTypes = {
|
|
816
1080
|
LOADING: "LOADING",
|
|
817
1081
|
SUCCESS: "SUCCESS",
|
|
@@ -1013,6 +1277,153 @@ const SingpassBanner = ({
|
|
|
1013
1277
|
}
|
|
1014
1278
|
);
|
|
1015
1279
|
};
|
|
1280
|
+
const isNewEntity = /* @__PURE__ */ Symbol("isNewEntity");
|
|
1281
|
+
const useExemptSettlor = ({
|
|
1282
|
+
trust
|
|
1283
|
+
}) => {
|
|
1284
|
+
const matchingAssociation = useMemo(() => {
|
|
1285
|
+
if (!trust) return void 0;
|
|
1286
|
+
return getOwnEntityAssociations(trust).find(
|
|
1287
|
+
(association) => association.type === TrustMemberTypes.SETTLOR && Boolean(association.settlorExemptionReason)
|
|
1288
|
+
);
|
|
1289
|
+
}, [trust]);
|
|
1290
|
+
const { data } = useLegalEntity(matchingAssociation?.legalEntityId ?? skipToken);
|
|
1291
|
+
return data;
|
|
1292
|
+
};
|
|
1293
|
+
const splitAtFirstOccurrence = (str, separator) => {
|
|
1294
|
+
const firstOccurrence = str.indexOf(separator);
|
|
1295
|
+
if (firstOccurrence === -1) return [str];
|
|
1296
|
+
return [str.slice(0, firstOccurrence), str.slice(firstOccurrence + 1)];
|
|
1297
|
+
};
|
|
1298
|
+
const getTrustMemberOwnerId = (trustMemberId, entityAssociations) => entityAssociations.find((association) => association.associatorId === trustMemberId)?.legalEntityId;
|
|
1299
|
+
const getFallbackName = (exemptSettlorAssociation) => {
|
|
1300
|
+
const [firstName, lastName] = splitAtFirstOccurrence(exemptSettlorAssociation.name ?? "", " ");
|
|
1301
|
+
return {
|
|
1302
|
+
firstName,
|
|
1303
|
+
lastName
|
|
1304
|
+
};
|
|
1305
|
+
};
|
|
1306
|
+
const convertEntityAssociationIntoTrustMember = (association, associations, exemptSettlorLE) => {
|
|
1307
|
+
if (association.settlorExemptionReason) {
|
|
1308
|
+
return {
|
|
1309
|
+
trustMemberType: "exemptSettlor",
|
|
1310
|
+
roles: [TrustMemberTypes.SETTLOR],
|
|
1311
|
+
legalEntityType: association.entityType,
|
|
1312
|
+
legalEntityId: association.legalEntityId,
|
|
1313
|
+
settlorExemptionReason: association.settlorExemptionReason,
|
|
1314
|
+
exemptSettlorName: association.entityType === LegalEntityTypes.INDIVIDUAL ? exemptSettlorLE?.individual?.name ?? getFallbackName(association) : void 0,
|
|
1315
|
+
name: association.name
|
|
1316
|
+
};
|
|
1317
|
+
}
|
|
1318
|
+
if (association.entityType === LegalEntityTypes.ORGANIZATION)
|
|
1319
|
+
return {
|
|
1320
|
+
trustMemberType: "company",
|
|
1321
|
+
roles: [],
|
|
1322
|
+
legalEntityType: LegalEntityTypes.ORGANIZATION,
|
|
1323
|
+
legalEntityId: association.legalEntityId,
|
|
1324
|
+
name: association.name,
|
|
1325
|
+
ownerId: getTrustMemberOwnerId(association.legalEntityId, associations)
|
|
1326
|
+
};
|
|
1327
|
+
if (association.entityType === LegalEntityTypes.INDIVIDUAL)
|
|
1328
|
+
return {
|
|
1329
|
+
trustMemberType: "regular",
|
|
1330
|
+
roles: [],
|
|
1331
|
+
legalEntityType: LegalEntityTypes.INDIVIDUAL,
|
|
1332
|
+
legalEntityId: association.legalEntityId,
|
|
1333
|
+
name: association.name
|
|
1334
|
+
};
|
|
1335
|
+
throw new Error(`Not a valid trust member: ${JSON.stringify(association)}`);
|
|
1336
|
+
};
|
|
1337
|
+
const mapEntityAssociationsToTrustMembers = (trustEntityId, entityAssociations, exemptSettlorLE) => {
|
|
1338
|
+
const mappedTrustMembers = entityAssociations.reduce(
|
|
1339
|
+
(acc, entityAssociation) => {
|
|
1340
|
+
if (!Object.values(TrustMemberTypes).includes(entityAssociation.type) || entityAssociation.associatorId !== trustEntityId || !entityAssociation.legalEntityId) {
|
|
1341
|
+
return acc;
|
|
1342
|
+
}
|
|
1343
|
+
const trustMember = acc[entityAssociation.legalEntityId] ?? convertEntityAssociationIntoTrustMember(
|
|
1344
|
+
entityAssociation,
|
|
1345
|
+
entityAssociations,
|
|
1346
|
+
exemptSettlorLE
|
|
1347
|
+
);
|
|
1348
|
+
const trustMemberType = entityAssociation.type;
|
|
1349
|
+
acc[entityAssociation.legalEntityId] = {
|
|
1350
|
+
...trustMember,
|
|
1351
|
+
roles: [.../* @__PURE__ */ new Set([...trustMember.roles, trustMemberType])]
|
|
1352
|
+
};
|
|
1353
|
+
return acc;
|
|
1354
|
+
},
|
|
1355
|
+
{}
|
|
1356
|
+
);
|
|
1357
|
+
return Object.values(mappedTrustMembers);
|
|
1358
|
+
};
|
|
1359
|
+
const mapRootLegalEntityToTrustMember = (rootLegalEntity) => ({
|
|
1360
|
+
trustMemberType: "rootTrustee",
|
|
1361
|
+
roles: [TrustMemberTypes.TRUSTEE],
|
|
1362
|
+
legalEntityType: rootLegalEntity.type,
|
|
1363
|
+
legalEntityId: rootLegalEntity.id,
|
|
1364
|
+
name: getLegalEntityNameBasedOnType(rootLegalEntity)
|
|
1365
|
+
});
|
|
1366
|
+
const mapUndefinedBeneficiaryInfoToTrustMembers = (undefinedBeneficiaryInfo) => undefinedBeneficiaryInfo.map(({ reference, description }) => ({
|
|
1367
|
+
trustMemberType: "undefinedBeneficiary",
|
|
1368
|
+
roles: [TrustMemberTypes.UNDEFINED_BENEFICIARY],
|
|
1369
|
+
reference,
|
|
1370
|
+
description
|
|
1371
|
+
}));
|
|
1372
|
+
const getTrustMembers = (trustLE, rootLegalEntity, exemptSettlorLE) => [
|
|
1373
|
+
mapRootLegalEntityToTrustMember(rootLegalEntity),
|
|
1374
|
+
...mapEntityAssociationsToTrustMembers(
|
|
1375
|
+
trustLE.id,
|
|
1376
|
+
trustLE.entityAssociations ?? [],
|
|
1377
|
+
exemptSettlorLE
|
|
1378
|
+
),
|
|
1379
|
+
...mapUndefinedBeneficiaryInfoToTrustMembers(trustLE.trust?.undefinedBeneficiaryInfo ?? [])
|
|
1380
|
+
];
|
|
1381
|
+
const combineRootLegalEntityWithEntityAssociations = (rootLegalEntity, entityAssociations) => {
|
|
1382
|
+
const allowedRolesForRootLegalEntity = [
|
|
1383
|
+
TrustMemberTypes.SETTLOR,
|
|
1384
|
+
TrustMemberTypes.PROTECTOR,
|
|
1385
|
+
TrustMemberTypes.DEFINED_BENEFICIARY
|
|
1386
|
+
];
|
|
1387
|
+
const roles = entityAssociations.map((entityAssociation) => entityAssociation.type).filter((role) => allowedRolesForRootLegalEntity.includes(role));
|
|
1388
|
+
return {
|
|
1389
|
+
trustMemberType: "rootTrustee",
|
|
1390
|
+
roles: [...roles, TrustMemberTypes.TRUSTEE],
|
|
1391
|
+
legalEntityType: rootLegalEntity.type,
|
|
1392
|
+
legalEntityId: rootLegalEntity.id,
|
|
1393
|
+
name: getLegalEntityNameBasedOnType(rootLegalEntity)
|
|
1394
|
+
};
|
|
1395
|
+
};
|
|
1396
|
+
const getRootTrusteeTrustMembers = (trustLE, rootLegalEntity, exemptSettlorLE) => {
|
|
1397
|
+
const entityAssociations = trustLE.entityAssociations ?? [];
|
|
1398
|
+
const rootLegalEntityAssociations = entityAssociations.filter(
|
|
1399
|
+
(a) => a.legalEntityId === rootLegalEntity.id
|
|
1400
|
+
);
|
|
1401
|
+
const nonRootLegalEntityAssociations = entityAssociations.filter(
|
|
1402
|
+
(a) => a.legalEntityId !== rootLegalEntity.id
|
|
1403
|
+
);
|
|
1404
|
+
return [
|
|
1405
|
+
combineRootLegalEntityWithEntityAssociations(rootLegalEntity, rootLegalEntityAssociations),
|
|
1406
|
+
...mapEntityAssociationsToTrustMembers(
|
|
1407
|
+
trustLE.id,
|
|
1408
|
+
nonRootLegalEntityAssociations ?? [],
|
|
1409
|
+
exemptSettlorLE
|
|
1410
|
+
),
|
|
1411
|
+
...mapUndefinedBeneficiaryInfoToTrustMembers(trustLE.trust?.undefinedBeneficiaryInfo ?? [])
|
|
1412
|
+
];
|
|
1413
|
+
};
|
|
1414
|
+
function useTrustMembers() {
|
|
1415
|
+
const { data: rootLegalEntity } = useLegalEntity(ROOT_LE);
|
|
1416
|
+
const { data: trust } = useAssociatedLegalEntity(rootLegalEntity, LegalEntityTypes.TRUST);
|
|
1417
|
+
const { isExperimentEnabled } = useExperimentsContext();
|
|
1418
|
+
const exemptSettlor = useExemptSettlor({
|
|
1419
|
+
trust
|
|
1420
|
+
});
|
|
1421
|
+
const allowMoreRolesForMainRootTrustee = isExperimentEnabled("AllowMoreRolesForMainRootTrustee");
|
|
1422
|
+
return useMemo(() => {
|
|
1423
|
+
if (!rootLegalEntity || !trust?.trust) return [];
|
|
1424
|
+
return allowMoreRolesForMainRootTrustee ? getRootTrusteeTrustMembers(trust, rootLegalEntity, exemptSettlor) : getTrustMembers(trust, rootLegalEntity, exemptSettlor);
|
|
1425
|
+
}, [rootLegalEntity, trust, exemptSettlor, allowMoreRolesForMainRootTrustee]);
|
|
1426
|
+
}
|
|
1016
1427
|
const useTrustMemberNavigation = ({ navigateTo, trust }) => {
|
|
1017
1428
|
const { t } = useTranslation("trust");
|
|
1018
1429
|
const { showToast } = useToastContext();
|
|
@@ -1119,6 +1530,255 @@ const useShouldShowIntroduction = ({
|
|
|
1119
1530
|
const { hasSeenIntroduction } = useHasSeenIntroduction({ legalEntityId: legalEntity.id });
|
|
1120
1531
|
return canSeeIntroduction && !hasSeenIntroduction;
|
|
1121
1532
|
};
|
|
1533
|
+
const getDefaultTask$1 = ({
|
|
1534
|
+
legalEntity,
|
|
1535
|
+
canSeeEntitySelection,
|
|
1536
|
+
canChangeEntityType,
|
|
1537
|
+
showIntroduction,
|
|
1538
|
+
shouldShowSingpassSelection,
|
|
1539
|
+
showServiceAgreementsFirst,
|
|
1540
|
+
showBusinessFinancingFirst
|
|
1541
|
+
}) => {
|
|
1542
|
+
const hasLegalEntityProgressedBeyondEntitySelection = hasProgressedBeyondEntitySelection$1(legalEntity);
|
|
1543
|
+
if (showServiceAgreementsFirst) {
|
|
1544
|
+
return TaskTypes.SERVICE_AGREEMENT;
|
|
1545
|
+
}
|
|
1546
|
+
if (showBusinessFinancingFirst) {
|
|
1547
|
+
return TaskTypes.BUSINESS_FINANCING;
|
|
1548
|
+
}
|
|
1549
|
+
if (canChangeEntityType && canSeeEntitySelection && !hasLegalEntityProgressedBeyondEntitySelection)
|
|
1550
|
+
return TaskTypes.BUSINESS_TYPE_SELECTION;
|
|
1551
|
+
if (showIntroduction) return TaskTypes.INTRODUCTION;
|
|
1552
|
+
if (shouldShowSingpassSelection) return TaskTypes.SINGPASS_SELECTION;
|
|
1553
|
+
return TaskTypes.TASKS_OVERVIEW;
|
|
1554
|
+
};
|
|
1555
|
+
const hasProgressedBeyondEntitySelection$1 = (legalEntity) => {
|
|
1556
|
+
const hasOwnEntityAssocation = legalEntity.entityAssociations?.some(
|
|
1557
|
+
(ea) => ea.associatorId === legalEntity.id
|
|
1558
|
+
);
|
|
1559
|
+
const hasOrganizationType = legalEntity.organization?.type;
|
|
1560
|
+
return hasOwnEntityAssocation || !!hasOrganizationType;
|
|
1561
|
+
};
|
|
1562
|
+
const Introduction$1 = lazy(
|
|
1563
|
+
async () => (await import("./Introduction-zRpWy7HO.js")).Introduction
|
|
1564
|
+
);
|
|
1565
|
+
const BusinessTypeSelectionPage$1 = lazy(
|
|
1566
|
+
async () => (await import("./BusinessTypeSelectionPage-B06fk_Rg.js")).BusinessTypeSelectionPage
|
|
1567
|
+
);
|
|
1568
|
+
const SingpassSelection$1 = lazy(
|
|
1569
|
+
async () => (await import("./SingpassSelection-Bf4TJmNp.js")).SingpassSelection
|
|
1570
|
+
);
|
|
1571
|
+
const AccountSetupRejected$1 = lazy(
|
|
1572
|
+
async () => (await import("./AccountSetupRejected-CjBJD3co.js")).AccountSetupRejected
|
|
1573
|
+
);
|
|
1574
|
+
const DecisionMakers$1 = lazy(
|
|
1575
|
+
async () => (await import("./DecisionMakers-efKmwEH6.js")).DecisionMakers
|
|
1576
|
+
);
|
|
1577
|
+
const CustomerSupport$1 = lazy(
|
|
1578
|
+
async () => (await import("./CustomerSupport-dXIEfG6m.js")).CustomerSupport
|
|
1579
|
+
);
|
|
1580
|
+
const Review$1 = lazy(async () => (await import("./Review-EZfLF4rz.js")).Review);
|
|
1581
|
+
const SignPCIComponent$1 = lazy(
|
|
1582
|
+
async () => (await import("./SignPCIComponent-BM4bM5lG.js")).SignPCIComponent
|
|
1583
|
+
);
|
|
1584
|
+
const AcceptTermsOfService$1 = lazy(
|
|
1585
|
+
async () => (await import("./AcceptTermsOfServiceComponent-BNYCiHcM.js")).AcceptTermsOfServiceComponent
|
|
1586
|
+
);
|
|
1587
|
+
const TaxReportingDropin$1 = lazy(
|
|
1588
|
+
async () => (await import("./TaxReportingDropin-CCjRFYko.js")).TaxReportingDropin
|
|
1589
|
+
);
|
|
1590
|
+
const PayoutDetailsPage$1 = lazy(
|
|
1591
|
+
async () => (await import("./PayoutDetailsPage-Bg4jqe0M.js")).PayoutDetailsPage
|
|
1592
|
+
);
|
|
1593
|
+
const RootBusinessDetailsPage$1 = lazy(
|
|
1594
|
+
async () => (await import("./RootBusinessDetailsPage-DpdikJPd.js")).RootBusinessDetailsPage
|
|
1595
|
+
);
|
|
1596
|
+
const RootBusinessLinesPage$1 = lazy(
|
|
1597
|
+
async () => (await import("./RootBusinessLinesPage-C-sZv7m1.js")).RootBusinessLinesPage
|
|
1598
|
+
);
|
|
1599
|
+
const SoleProprietorshipPage$1 = lazy(
|
|
1600
|
+
async () => (await import("./SoleProprietorshipPage-DuR8s39H.js")).SoleProprietorshipPage
|
|
1601
|
+
);
|
|
1602
|
+
const TrustMemberCompanyPage$1 = lazy(
|
|
1603
|
+
async () => (await import("./TrustMemberCompanyPage-CqiLrrtT.js")).TrustMemberCompanyPage
|
|
1604
|
+
);
|
|
1605
|
+
const TrustMemberIndividualPage$1 = lazy(
|
|
1606
|
+
async () => (await import("./TrustMemberIndividualPage-DOOv3UCM.js")).TrustMemberIndividualPage
|
|
1607
|
+
);
|
|
1608
|
+
const TrustMemberRoleAndTypePage$1 = lazy(
|
|
1609
|
+
async () => (await import("./TrustMemberRoleAndTypePage-Cil5oL0H.js")).TrustMemberRoleAndTypePage
|
|
1610
|
+
);
|
|
1611
|
+
const TrustMembersOverview$1 = lazy(
|
|
1612
|
+
async () => (await import("./TrustMembersOverview-5PfCpnLZ.js")).TrustMembersOverview
|
|
1613
|
+
);
|
|
1614
|
+
const UnincorporatedPartnershipMemberCompanyPage$1 = lazy(
|
|
1615
|
+
async () => (await import("./UnincorporatedPartnershipMemberCompanyPage-DVn8X5ZA.js")).UnincorporatedPartnershipMemberCompanyPage
|
|
1616
|
+
);
|
|
1617
|
+
const UnincorporatedPartnershipIndividualPage$1 = lazy(
|
|
1618
|
+
async () => (await import("./UnincorporatedPartnershipIndividualPage-Imr8r98E.js")).UnincorporatedPartnershipIndividualPage
|
|
1619
|
+
);
|
|
1620
|
+
const UnincorporatedPartnershipMemberRoleAndTypePage$1 = lazy(
|
|
1621
|
+
async () => (await import("./UnincorporatedPartnershipMemberRoleAndTypePage-D1ZiUnfd.js")).UnincorporatedPartnershipMemberRoleAndTypePage
|
|
1622
|
+
);
|
|
1623
|
+
const UnincorporatedPartnershipMembersOverview$1 = lazy(
|
|
1624
|
+
async () => (await import("./UnincorporatedPartnershipMembersOverview-B3hUsoDk.js")).UnincorporatedPartnershipMembersOverview
|
|
1625
|
+
);
|
|
1626
|
+
const BusinessFinancingPage$1 = lazy(
|
|
1627
|
+
async () => (await import("./BusinessFinancingPage-CgjmgSnX.js")).BusinessFinancingPage
|
|
1628
|
+
);
|
|
1629
|
+
const TrustDetailsPage$1 = lazy(
|
|
1630
|
+
async () => (await import("./TrustDetailsPage-C61KvX6f.js")).TrustDetailsPage
|
|
1631
|
+
);
|
|
1632
|
+
const SourceOfFundsPage$1 = lazy(
|
|
1633
|
+
async () => (await import("./SourceOfFundsPage-B-4L7Rbi.js")).SourceOfFundsPage
|
|
1634
|
+
);
|
|
1635
|
+
const RootIndividualDetailsPage$1 = lazy(
|
|
1636
|
+
async () => (await import("./RootIndividualDetailsPage-BY5WbcpR.js")).RootIndividualDetailsPage
|
|
1637
|
+
);
|
|
1638
|
+
const LegalRepresentativeDetailsPage$1 = lazy(
|
|
1639
|
+
async () => (await import("./LegalRepresentativeDetailsPage-DsfDlsBE.js")).LegalRepresentativeDetailsPage
|
|
1640
|
+
);
|
|
1641
|
+
const DecisionMakerDetailsPage$1 = lazy(
|
|
1642
|
+
async () => (await import("./DecisionMakerDetailsPage-BdZAgdo_.js")).DecisionMakerDetailsPage
|
|
1643
|
+
);
|
|
1644
|
+
const ROUTE_CONFIG = {
|
|
1645
|
+
[TaskTypes.TASKS_OVERVIEW]: { path: "/tasks" },
|
|
1646
|
+
[TaskTypes.INTRODUCTION]: { path: "/introduction", Component: Introduction$1 },
|
|
1647
|
+
[TaskTypes.BUSINESS_TYPE_SELECTION]: {
|
|
1648
|
+
path: "/business-type-selection",
|
|
1649
|
+
Component: BusinessTypeSelectionPage$1
|
|
1650
|
+
},
|
|
1651
|
+
[TaskTypes.SINGPASS_SELECTION]: { path: "/singpass-selection", Component: SingpassSelection$1 },
|
|
1652
|
+
[TaskTypes.INDIVIDUAL]: { path: "/individual", Component: RootIndividualDetailsPage$1 },
|
|
1653
|
+
[TaskTypes.BUSINESS_DETAILS]: { path: "/business", Component: RootBusinessDetailsPage$1 },
|
|
1654
|
+
[TaskTypes.ACQUIRING_BUSINESS_LINE]: {
|
|
1655
|
+
path: "/business-lines",
|
|
1656
|
+
Component: RootBusinessLinesPage$1
|
|
1657
|
+
},
|
|
1658
|
+
[TaskTypes.DECISION_MAKER_OVERVIEW]: { path: "/decision-makers", Component: DecisionMakers$1 },
|
|
1659
|
+
[TaskTypes.DECISION_MAKER]: {
|
|
1660
|
+
path: "/decision-maker/:parentId/:decisionMakerId?",
|
|
1661
|
+
Component: DecisionMakerDetailsPage$1
|
|
1662
|
+
},
|
|
1663
|
+
[TaskTypes.PAYOUT]: { path: "/payout/:transferInstrumentId?", Component: PayoutDetailsPage$1 },
|
|
1664
|
+
[TaskTypes.PAYIN]: { path: "/payin/:transferInstrumentId?", Component: PayoutDetailsPage$1 },
|
|
1665
|
+
[TaskTypes.SERVICE_AGREEMENT]: { path: "/service-agreement", Component: AcceptTermsOfService$1 },
|
|
1666
|
+
[TaskTypes.PCI_DSS]: { path: "/pci-dss", Component: SignPCIComponent$1 },
|
|
1667
|
+
[TaskTypes.REVIEW]: { path: "/review", Component: Review$1 },
|
|
1668
|
+
[TaskTypes.CUSTOMER_SUPPORT]: { path: "/customer-support", Component: CustomerSupport$1 },
|
|
1669
|
+
[TaskTypes.CAPABILITY_REJECTED]: {
|
|
1670
|
+
path: "/capability-rejected",
|
|
1671
|
+
Component: AccountSetupRejected$1
|
|
1672
|
+
},
|
|
1673
|
+
[TaskTypes.LEGAL_REPRESENTATIVE_DETAILS]: {
|
|
1674
|
+
path: "/legal-representative",
|
|
1675
|
+
Component: LegalRepresentativeDetailsPage$1
|
|
1676
|
+
},
|
|
1677
|
+
[TaskTypes.SOURCE_OF_FUNDS]: { path: "/source-of-funds", Component: SourceOfFundsPage$1 },
|
|
1678
|
+
[TaskTypes.BUSINESS_FINANCING]: { path: "/business-financing", Component: BusinessFinancingPage$1 },
|
|
1679
|
+
[TaskTypes.TAX_REPORTING]: { path: "/tax-reporting", Component: TaxReportingDropin$1 },
|
|
1680
|
+
[TaskTypes.SOLE_PROPRIETOR_COMPANY]: {
|
|
1681
|
+
path: "/sole-proprietor",
|
|
1682
|
+
Component: SoleProprietorshipPage$1
|
|
1683
|
+
},
|
|
1684
|
+
[TaskTypes.TRUST]: { path: "/trust", Component: TrustDetailsPage$1 },
|
|
1685
|
+
[TaskTypes.TRUST_MEMBER]: { path: "/trust/member" },
|
|
1686
|
+
[TaskTypes.TRUST_MEMBER_OVERVIEW]: { path: "/trust/members", Component: TrustMembersOverview$1 },
|
|
1687
|
+
[TaskTypes.TRUST_MEMBER_ROLE_AND_TYPE]: {
|
|
1688
|
+
path: "/trust/member/role-and-type/:memberId?",
|
|
1689
|
+
Component: TrustMemberRoleAndTypePage$1
|
|
1690
|
+
},
|
|
1691
|
+
[TaskTypes.TRUST_MEMBER_INDIVIDUAL]: {
|
|
1692
|
+
path: "/trust/member/:memberId/individual",
|
|
1693
|
+
Component: TrustMemberIndividualPage$1
|
|
1694
|
+
},
|
|
1695
|
+
[TaskTypes.TRUST_MEMBER_COMPANY]: {
|
|
1696
|
+
path: "/trust/member/:memberId/company",
|
|
1697
|
+
Component: TrustMemberCompanyPage$1
|
|
1698
|
+
},
|
|
1699
|
+
[TaskTypes.TRUST_MEMBER_COMPANY_OWNER]: {
|
|
1700
|
+
path: "/trust/member/:memberId/company-owner/:parentId/:decisionMakerId?",
|
|
1701
|
+
Component: DecisionMakerDetailsPage$1
|
|
1702
|
+
},
|
|
1703
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP]: {
|
|
1704
|
+
path: "/partnership",
|
|
1705
|
+
Component: TrustDetailsPage$1
|
|
1706
|
+
},
|
|
1707
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_OVERVIEW]: {
|
|
1708
|
+
path: "/partnership/members",
|
|
1709
|
+
Component: UnincorporatedPartnershipMembersOverview$1
|
|
1710
|
+
},
|
|
1711
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_ROLE_AND_TYPE]: {
|
|
1712
|
+
path: "/partnership/member/role-and-type/:memberId?",
|
|
1713
|
+
Component: UnincorporatedPartnershipMemberRoleAndTypePage$1
|
|
1714
|
+
},
|
|
1715
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_INDIVIDUAL]: {
|
|
1716
|
+
path: "/partnership/member/:memberId/individual",
|
|
1717
|
+
Component: UnincorporatedPartnershipIndividualPage$1
|
|
1718
|
+
},
|
|
1719
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_COMPANY]: {
|
|
1720
|
+
path: "/partnership/member/:memberId/company",
|
|
1721
|
+
Component: UnincorporatedPartnershipMemberCompanyPage$1
|
|
1722
|
+
},
|
|
1723
|
+
[TaskTypes.UNINCORPORATED_PARTNERSHIP_MEMBER_COMPANY_OWNER]: {
|
|
1724
|
+
path: "/partnership/member/:memberId/company-owner/:parentId/:decisionMakerId?",
|
|
1725
|
+
Component: DecisionMakerDetailsPage$1
|
|
1726
|
+
}
|
|
1727
|
+
};
|
|
1728
|
+
const ROUTE_PATHS = Object.fromEntries(
|
|
1729
|
+
Object.entries(ROUTE_CONFIG).map(([key, entry]) => [key, entry.path])
|
|
1730
|
+
);
|
|
1731
|
+
const buildPath = (task, params) => {
|
|
1732
|
+
const routePath = ROUTE_PATHS[task];
|
|
1733
|
+
const segments = routePath.split("/").filter(Boolean);
|
|
1734
|
+
const built = segments.map((seg) => {
|
|
1735
|
+
const isOptional = seg.endsWith("?");
|
|
1736
|
+
const isParam = seg.startsWith(":");
|
|
1737
|
+
if (!isParam) return seg;
|
|
1738
|
+
const paramName = seg.slice(1, isOptional ? -1 : void 0);
|
|
1739
|
+
const value = params?.[paramName];
|
|
1740
|
+
if (!value && isOptional) return null;
|
|
1741
|
+
if (!value) throw new Error(`Missing required param "${paramName}" for route "${task}"`);
|
|
1742
|
+
return value;
|
|
1743
|
+
}).filter((s) => s !== null);
|
|
1744
|
+
return "/" + built.join("/");
|
|
1745
|
+
};
|
|
1746
|
+
const detectBasePath = (parser, pathname = window.location.pathname) => {
|
|
1747
|
+
const pathSegments = pathname.split("/").filter(Boolean);
|
|
1748
|
+
const sortedRoutes = Object.values(ROUTE_PATHS).sort(
|
|
1749
|
+
(a, b) => b.split("/").filter(Boolean).length - a.split("/").filter(Boolean).length
|
|
1750
|
+
);
|
|
1751
|
+
for (let i = 0; i < pathSegments.length; i++) {
|
|
1752
|
+
const candidatePath = "/" + pathSegments.slice(i).join("/");
|
|
1753
|
+
for (const routePath of sortedRoutes) {
|
|
1754
|
+
const [match] = matchRoute(parser, routePath, candidatePath);
|
|
1755
|
+
if (match) {
|
|
1756
|
+
const baseSegments = pathSegments.slice(0, i);
|
|
1757
|
+
return baseSegments.length > 0 ? "/" + baseSegments.join("/") : "/";
|
|
1758
|
+
}
|
|
1759
|
+
}
|
|
1760
|
+
}
|
|
1761
|
+
const trimmed = pathname.endsWith("/") ? pathname.slice(0, -1) : pathname;
|
|
1762
|
+
return trimmed || "/";
|
|
1763
|
+
};
|
|
1764
|
+
const useNavigate = () => {
|
|
1765
|
+
const [, setLocation] = useLocation();
|
|
1766
|
+
const withSearch = (path) => path + window.location.search;
|
|
1767
|
+
const to = (task, params) => {
|
|
1768
|
+
if (task === "default") {
|
|
1769
|
+
setLocation(withSearch("/"));
|
|
1770
|
+
return;
|
|
1771
|
+
}
|
|
1772
|
+
setLocation(withSearch(buildPath(task, params)));
|
|
1773
|
+
};
|
|
1774
|
+
const back = (stepCount = 1) => {
|
|
1775
|
+
window.history.go(-stepCount);
|
|
1776
|
+
};
|
|
1777
|
+
const replace = (task, params) => {
|
|
1778
|
+
setLocation(withSearch(buildPath(task, params)), { replace: true });
|
|
1779
|
+
};
|
|
1780
|
+
return { to, back, replace };
|
|
1781
|
+
};
|
|
1122
1782
|
function DefaultRouteRedirect({ legalEntity, children }) {
|
|
1123
1783
|
const navigate = useNavigate();
|
|
1124
1784
|
const { isSettingEnabled } = useSettingsContext();
|
|
@@ -1752,15 +2412,20 @@ function WouterDropinComposerInner({
|
|
|
1752
2412
|
}, [accountHolder, rootLegalEntity]);
|
|
1753
2413
|
useEffect(() => setAccountHolderInGlobalStore(accountHolder), [accountHolder]);
|
|
1754
2414
|
const { rootLegalEntityId } = useApiContext();
|
|
2415
|
+
const { data: toggleData } = useToggles();
|
|
1755
2416
|
rootLegalEntityId.value = rootLegalEntity.id;
|
|
1756
2417
|
useEffect(() => {
|
|
1757
|
-
|
|
1758
|
-
if (
|
|
2418
|
+
let enabledExperimentNames;
|
|
2419
|
+
if (experiments.EnableOnboardingTogglesEndpoint) {
|
|
2420
|
+
enabledExperimentNames = Object.keys(toggleData?.experiments || {});
|
|
2421
|
+
} else {
|
|
2422
|
+
enabledExperimentNames = Object.entries(experiments).filter(([key, value]) => key.includes("_") && value).map(([key]) => key);
|
|
2423
|
+
}
|
|
1759
2424
|
enabledExperimentNames.forEach((experiment) => {
|
|
1760
2425
|
const [name, variant] = experiment.split("_");
|
|
1761
2426
|
userEvents.trackExperiment({ name, variant });
|
|
1762
2427
|
});
|
|
1763
|
-
}, [experiments]);
|
|
2428
|
+
}, [experiments, toggleData?.experiments, userEvents]);
|
|
1764
2429
|
const singpassBanner = isEligibleForSingpass ? /* @__PURE__ */ jsx(
|
|
1765
2430
|
SingpassBanner,
|
|
1766
2431
|
{
|
|
@@ -1956,86 +2621,86 @@ const hasProgressedBeyondEntitySelection = (legalEntity) => {
|
|
|
1956
2621
|
return hasOwnEntityAssocation || !!hasOrganizationType;
|
|
1957
2622
|
};
|
|
1958
2623
|
const Introduction = lazy(
|
|
1959
|
-
async () => (await import("./Introduction-
|
|
2624
|
+
async () => (await import("./Introduction-zRpWy7HO.js")).Introduction
|
|
1960
2625
|
);
|
|
1961
2626
|
const BusinessTypeSelectionPage = lazy(
|
|
1962
|
-
async () => (await import("./BusinessTypeSelectionPage-
|
|
2627
|
+
async () => (await import("./BusinessTypeSelectionPage-B06fk_Rg.js")).BusinessTypeSelectionPage
|
|
1963
2628
|
);
|
|
1964
2629
|
const SingpassSelection = lazy(
|
|
1965
|
-
async () => (await import("./SingpassSelection-
|
|
2630
|
+
async () => (await import("./SingpassSelection-Bf4TJmNp.js")).SingpassSelection
|
|
1966
2631
|
);
|
|
1967
2632
|
const AccountSetupRejected = lazy(
|
|
1968
|
-
async () => (await import("./AccountSetupRejected-
|
|
2633
|
+
async () => (await import("./AccountSetupRejected-CjBJD3co.js")).AccountSetupRejected
|
|
1969
2634
|
);
|
|
1970
2635
|
const DecisionMakers = lazy(
|
|
1971
|
-
async () => (await import("./DecisionMakers-
|
|
2636
|
+
async () => (await import("./DecisionMakers-efKmwEH6.js")).DecisionMakers
|
|
1972
2637
|
);
|
|
1973
2638
|
const CustomerSupport = lazy(
|
|
1974
|
-
async () => (await import("./CustomerSupport-
|
|
2639
|
+
async () => (await import("./CustomerSupport-dXIEfG6m.js")).CustomerSupport
|
|
1975
2640
|
);
|
|
1976
|
-
const Review = lazy(async () => (await import("./Review-
|
|
2641
|
+
const Review = lazy(async () => (await import("./Review-EZfLF4rz.js")).Review);
|
|
1977
2642
|
const SignPCIComponent = lazy(
|
|
1978
|
-
async () => (await import("./SignPCIComponent-
|
|
2643
|
+
async () => (await import("./SignPCIComponent-BM4bM5lG.js")).SignPCIComponent
|
|
1979
2644
|
);
|
|
1980
2645
|
const AcceptTermsOfService = lazy(
|
|
1981
|
-
async () => (await import("./AcceptTermsOfServiceComponent-
|
|
2646
|
+
async () => (await import("./AcceptTermsOfServiceComponent-BNYCiHcM.js")).AcceptTermsOfServiceComponent
|
|
1982
2647
|
);
|
|
1983
2648
|
const TaxReportingDropin = lazy(
|
|
1984
|
-
async () => (await import("./TaxReportingDropin-
|
|
2649
|
+
async () => (await import("./TaxReportingDropin-CCjRFYko.js")).TaxReportingDropin
|
|
1985
2650
|
);
|
|
1986
2651
|
const PayoutDetailsPage = lazy(
|
|
1987
|
-
async () => (await import("./
|
|
2652
|
+
async () => (await import("./PayoutDetailsPage-Bg4jqe0M.js")).PayoutDetailsPage
|
|
1988
2653
|
);
|
|
1989
2654
|
const RootBusinessDetailsPage = lazy(
|
|
1990
|
-
async () => (await import("./RootBusinessDetailsPage-
|
|
2655
|
+
async () => (await import("./RootBusinessDetailsPage-DpdikJPd.js")).RootBusinessDetailsPage
|
|
1991
2656
|
);
|
|
1992
2657
|
const RootBusinessLinesPage = lazy(
|
|
1993
|
-
async () => (await import("./RootBusinessLinesPage-
|
|
2658
|
+
async () => (await import("./RootBusinessLinesPage-C-sZv7m1.js")).RootBusinessLinesPage
|
|
1994
2659
|
);
|
|
1995
2660
|
const SoleProprietorshipPage = lazy(
|
|
1996
|
-
async () => (await import("./SoleProprietorshipPage-
|
|
2661
|
+
async () => (await import("./SoleProprietorshipPage-DuR8s39H.js")).SoleProprietorshipPage
|
|
1997
2662
|
);
|
|
1998
2663
|
const TrustMemberCompanyPage = lazy(
|
|
1999
|
-
async () => (await import("./TrustMemberCompanyPage-
|
|
2664
|
+
async () => (await import("./TrustMemberCompanyPage-CqiLrrtT.js")).TrustMemberCompanyPage
|
|
2000
2665
|
);
|
|
2001
2666
|
const TrustMemberIndividualPage = lazy(
|
|
2002
|
-
async () => (await import("./TrustMemberIndividualPage-
|
|
2667
|
+
async () => (await import("./TrustMemberIndividualPage-DOOv3UCM.js")).TrustMemberIndividualPage
|
|
2003
2668
|
);
|
|
2004
2669
|
const TrustMemberRoleAndTypePage = lazy(
|
|
2005
|
-
async () => (await import("./TrustMemberRoleAndTypePage-
|
|
2670
|
+
async () => (await import("./TrustMemberRoleAndTypePage-Cil5oL0H.js")).TrustMemberRoleAndTypePage
|
|
2006
2671
|
);
|
|
2007
2672
|
const TrustMembersOverview = lazy(
|
|
2008
|
-
async () => (await import("./TrustMembersOverview-
|
|
2673
|
+
async () => (await import("./TrustMembersOverview-5PfCpnLZ.js")).TrustMembersOverview
|
|
2009
2674
|
);
|
|
2010
2675
|
const UnincorporatedPartnershipMemberCompanyPage = lazy(
|
|
2011
|
-
async () => (await import("./UnincorporatedPartnershipMemberCompanyPage-
|
|
2676
|
+
async () => (await import("./UnincorporatedPartnershipMemberCompanyPage-DVn8X5ZA.js")).UnincorporatedPartnershipMemberCompanyPage
|
|
2012
2677
|
);
|
|
2013
2678
|
const UnincorporatedPartnershipIndividualPage = lazy(
|
|
2014
|
-
async () => (await import("./UnincorporatedPartnershipIndividualPage-
|
|
2679
|
+
async () => (await import("./UnincorporatedPartnershipIndividualPage-Imr8r98E.js")).UnincorporatedPartnershipIndividualPage
|
|
2015
2680
|
);
|
|
2016
2681
|
const UnincorporatedPartnershipMemberRoleAndTypePage = lazy(
|
|
2017
|
-
async () => (await import("./UnincorporatedPartnershipMemberRoleAndTypePage-
|
|
2682
|
+
async () => (await import("./UnincorporatedPartnershipMemberRoleAndTypePage-D1ZiUnfd.js")).UnincorporatedPartnershipMemberRoleAndTypePage
|
|
2018
2683
|
);
|
|
2019
2684
|
const UnincorporatedPartnershipMembersOverview = lazy(
|
|
2020
|
-
async () => (await import("./UnincorporatedPartnershipMembersOverview-
|
|
2685
|
+
async () => (await import("./UnincorporatedPartnershipMembersOverview-B3hUsoDk.js")).UnincorporatedPartnershipMembersOverview
|
|
2021
2686
|
);
|
|
2022
2687
|
const BusinessFinancingPage = lazy(
|
|
2023
|
-
async () => (await import("./BusinessFinancingPage-
|
|
2688
|
+
async () => (await import("./BusinessFinancingPage-CgjmgSnX.js")).BusinessFinancingPage
|
|
2024
2689
|
);
|
|
2025
2690
|
const TrustDetailsPage = lazy(
|
|
2026
|
-
async () => (await import("./TrustDetailsPage-
|
|
2691
|
+
async () => (await import("./TrustDetailsPage-C61KvX6f.js")).TrustDetailsPage
|
|
2027
2692
|
);
|
|
2028
2693
|
const SourceOfFundsPage = lazy(
|
|
2029
|
-
async () => (await import("./SourceOfFundsPage-
|
|
2694
|
+
async () => (await import("./SourceOfFundsPage-B-4L7Rbi.js")).SourceOfFundsPage
|
|
2030
2695
|
);
|
|
2031
2696
|
const RootIndividualDetailsPage = lazy(
|
|
2032
|
-
async () => (await import("./RootIndividualDetailsPage-
|
|
2697
|
+
async () => (await import("./RootIndividualDetailsPage-BY5WbcpR.js")).RootIndividualDetailsPage
|
|
2033
2698
|
);
|
|
2034
2699
|
const LegalRepresentativeDetailsPage = lazy(
|
|
2035
|
-
async () => (await import("./LegalRepresentativeDetailsPage-
|
|
2700
|
+
async () => (await import("./LegalRepresentativeDetailsPage-DsfDlsBE.js")).LegalRepresentativeDetailsPage
|
|
2036
2701
|
);
|
|
2037
2702
|
const DecisionMakerDetailsPage = lazy(
|
|
2038
|
-
async () => (await import("./DecisionMakerDetailsPage-
|
|
2703
|
+
async () => (await import("./DecisionMakerDetailsPage-BdZAgdo_.js")).DecisionMakerDetailsPage
|
|
2039
2704
|
);
|
|
2040
2705
|
function isIn(values, x) {
|
|
2041
2706
|
return values.includes(x);
|
|
@@ -2244,15 +2909,20 @@ function LegacyDropinComposer({
|
|
|
2244
2909
|
}, [accountHolder, rootLegalEntity]);
|
|
2245
2910
|
useEffect(() => setAccountHolderInGlobalStore(accountHolder), [accountHolder]);
|
|
2246
2911
|
const { rootLegalEntityId } = useApiContext();
|
|
2912
|
+
const { data: toggleData } = useToggles();
|
|
2247
2913
|
rootLegalEntityId.value = rootLegalEntity.id;
|
|
2248
2914
|
useEffect(() => {
|
|
2249
|
-
|
|
2250
|
-
if (
|
|
2915
|
+
let enabledExperimentNames;
|
|
2916
|
+
if (experiments.EnableOnboardingTogglesEndpoint) {
|
|
2917
|
+
enabledExperimentNames = Object.keys(toggleData?.experiments || {});
|
|
2918
|
+
} else {
|
|
2919
|
+
enabledExperimentNames = Object.entries(experiments).filter(([key, value]) => key.includes("_") && value).map(([key]) => key);
|
|
2920
|
+
}
|
|
2251
2921
|
enabledExperimentNames.forEach((experiment) => {
|
|
2252
2922
|
const [name, variant] = experiment.split("_");
|
|
2253
2923
|
userEvents.trackExperiment({ name, variant });
|
|
2254
2924
|
});
|
|
2255
|
-
}, [experiments]);
|
|
2925
|
+
}, [experiments, toggleData?.experiments, userEvents]);
|
|
2256
2926
|
const singpassBanner = isEligibleForSingpass ? /* @__PURE__ */ jsx(
|
|
2257
2927
|
SingpassBanner,
|
|
2258
2928
|
{
|
|
@@ -2652,7 +3322,7 @@ function OnboardingDropinComponent({
|
|
|
2652
3322
|
}
|
|
2653
3323
|
const { i18n } = useTranslation();
|
|
2654
3324
|
addResourceBundles(i18n, [
|
|
2655
|
-
{ ns: "common", importFn: (lang) => __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "../../../language/locales/bg-BG.json": () => import("./bg-BG-
|
|
3325
|
+
{ ns: "common", importFn: (lang) => __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "../../../language/locales/bg-BG.json": () => import("./bg-BG-DqRXdvRT.js"), "../../../language/locales/cs-CZ.json": () => import("./cs-CZ-CmPmY5GZ.js"), "../../../language/locales/da-DK.json": () => import("./da-DK-DaINWU5x.js"), "../../../language/locales/de-DE.json": () => import("./de-DE-KqZs1FFF.js"), "../../../language/locales/el-GR.json": () => import("./el-GR-Bn45KMp-.js"), "../../../language/locales/en-US.instructions.json": () => import("./en-US.instructions-CfIM2SRF.js"), "../../../language/locales/en-US.json": () => import("./StoreProvider-OuIcrYXq.js").then((n) => n.bT), "../../../language/locales/es-ES.json": () => import("./es-ES-DzGJ9DrB.js"), "../../../language/locales/et-EE.json": () => import("./et-EE-JKt5dMOQ.js"), "../../../language/locales/fi-FI.json": () => import("./fi-FI-n9XAQuIy.js"), "../../../language/locales/fr-FR.json": () => import("./fr-FR-iD1onxpA.js"), "../../../language/locales/hr-HR.json": () => import("./hr-HR-CAqaI1xJ.js"), "../../../language/locales/hu-HU.json": () => import("./hu-HU-CRpdELm_.js"), "../../../language/locales/it-IT.json": () => import("./it-IT-DkiyBNl6.js"), "../../../language/locales/ja-JP.json": () => import("./ja-JP-B0Ox3Ixh.js"), "../../../language/locales/lt-LT.json": () => import("./lt-LT-DWs-lYAv.js"), "../../../language/locales/lv-LV.json": () => import("./lv-LV-CdCU8ZaR.js"), "../../../language/locales/nl-NL.json": () => import("./nl-NL-D7k3hkBl.js"), "../../../language/locales/no-NO.json": () => import("./no-NO-DOOgOJr1.js"), "../../../language/locales/pl-PL.json": () => import("./pl-PL-Bvnak7w3.js"), "../../../language/locales/pt-BR.json": () => import("./pt-BR-BZkPZ0kK.js"), "../../../language/locales/pt-PT.json": () => import("./pt-PT-DkfqmPrD.js"), "../../../language/locales/ro-RO.json": () => import("./ro-RO-BEVRugNx.js"), "../../../language/locales/sk-SK.json": () => import("./sk-SK-Bh7WfMNd.js"), "../../../language/locales/sl-SI.json": () => import("./sl-SI-CxGdSydw.js"), "../../../language/locales/sv-SE.json": () => import("./sv-SE-CgB54Aa4.js") }), `../../../language/locales/${lang}.json`, 6) },
|
|
2656
3326
|
{ ns: "ui", importFn: (lang) => __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "../../ui/language/bg-BG.json": () => import("./bg-BG-zZhDshGi.js"), "../../ui/language/cs-CZ.json": () => import("./cs-CZ-Ck22NTT9.js"), "../../ui/language/da-DK.json": () => import("./da-DK-DQ4ZYSea.js"), "../../ui/language/de-DE.json": () => import("./de-DE-CkbOZ6S_.js"), "../../ui/language/el-GR.json": () => import("./el-GR-DudORw4U.js"), "../../ui/language/en-US.json": () => import("./en-US-CjjPhkB5.js"), "../../ui/language/es-ES.json": () => import("./es-ES-BAolMrZ0.js"), "../../ui/language/et-EE.json": () => import("./et-EE-BOIrYrz9.js"), "../../ui/language/fi-FI.json": () => import("./fi-FI-D8WrLxxq.js"), "../../ui/language/fr-FR.json": () => import("./fr-FR-Beljeilc.js"), "../../ui/language/hr-HR.json": () => import("./hr-HR-lIHN6Yl2.js"), "../../ui/language/hu-HU.json": () => import("./hu-HU-CWdwNCev.js"), "../../ui/language/it-IT.json": () => import("./it-IT-5a7NHVFo.js"), "../../ui/language/ja-JP.json": () => import("./ja-JP-DSvZhFNY.js"), "../../ui/language/lt-LT.json": () => import("./lt-LT-CgalYpUh.js"), "../../ui/language/lv-LV.json": () => import("./lv-LV-aAd9SEqx.js"), "../../ui/language/nl-NL.json": () => import("./nl-NL-CmURERx_.js"), "../../ui/language/no-NO.json": () => import("./no-NO-qyqWODMp.js"), "../../ui/language/pl-PL.json": () => import("./pl-PL-q9azN24o.js"), "../../ui/language/pt-BR.json": () => import("./pt-BR-BxoOF8jB.js"), "../../ui/language/pt-PT.json": () => import("./pt-PT-pIChDwiI.js"), "../../ui/language/ro-RO.json": () => import("./ro-RO-DRsaNX9j.js"), "../../ui/language/sk-SK.json": () => import("./sk-SK-7-enbO1N.js"), "../../ui/language/sl-SI.json": () => import("./sl-SI-DTvJT7fC.js"), "../../ui/language/sv-SE.json": () => import("./sv-SE-N-Hqwcjq.js") }), `../../ui/language/${lang}.json`, 5) }
|
|
2657
3327
|
]);
|
|
2658
3328
|
const { data: legalEntityData } = useLegalEntity(ROOT_LE);
|
|
@@ -2665,5 +3335,21 @@ function OnboardingDropinComponent({
|
|
|
2665
3335
|
);
|
|
2666
3336
|
}
|
|
2667
3337
|
export {
|
|
2668
|
-
OnboardingDropinComponent as O
|
|
3338
|
+
OnboardingDropinComponent as O,
|
|
3339
|
+
usePciStatus as a,
|
|
3340
|
+
useCanSeeIntroduction as b,
|
|
3341
|
+
useLegalEntityType as c,
|
|
3342
|
+
allowIndividualWithoutSoleProp as d,
|
|
3343
|
+
useDataMissingRemediations as e,
|
|
3344
|
+
useTaskStatus as f,
|
|
3345
|
+
getTrustedEntityAssociations as g,
|
|
3346
|
+
useNavigate as h,
|
|
3347
|
+
filterProblemsByTaskForms as i,
|
|
3348
|
+
useBusinessLines as j,
|
|
3349
|
+
usePciQuestionnaireList as k,
|
|
3350
|
+
useTrustMembers as l,
|
|
3351
|
+
isNewEntity as m,
|
|
3352
|
+
getTrustedFieldsProvider as n,
|
|
3353
|
+
getTrustedFields as o,
|
|
3354
|
+
useSalesChannels as u
|
|
2669
3355
|
};
|