@sheerid/jslib 2.230.0 → 2.231.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/_mysheerid-preview.css +4 -4
- package/_mysheerid-preview.js +24 -24
- package/chunk/{ActiveDutyStartDateComponent-CLjp2D9z.js → ActiveDutyStartDateComponent-BNwC2c3Y.js} +5 -5
- package/chunk/{ActiveDutyStartDateComponent-CLjp2D9z.js.map → ActiveDutyStartDateComponent-BNwC2c3Y.js.map} +1 -1
- package/chunk/{ActiveDutyStartDateComponent-D7Q8AKCS.js → ActiveDutyStartDateComponent-CF9c-0bL.js} +5 -5
- package/chunk/{ActiveDutyStartDateComponent-D7Q8AKCS.js.map → ActiveDutyStartDateComponent-CF9c-0bL.js.map} +1 -1
- package/chunk/AddressComponent-AiyIPiCz.js +4 -4
- package/chunk/AddressComponent-DV2Wsw6k.js +4 -4
- package/chunk/{CaptchaComponent-CKP3wfXl.js → CaptchaComponent-CnWyxiTy.js} +154 -154
- package/chunk/CaptchaComponent-CnWyxiTy.js.map +1 -0
- package/chunk/{CaptchaComponent-CR32xDg8.js → CaptchaComponent-SmUa6m52.js} +154 -154
- package/chunk/CaptchaComponent-SmUa6m52.js.map +1 -0
- package/chunk/ChangeLocaleComponent-Cu2DR-Q3.js +4 -4
- package/chunk/ChangeLocaleComponent-DUnfgQuX.js +4 -4
- package/chunk/City-BmrJpnS6.js +4 -4
- package/chunk/City-yVVnZQTP.js +4 -4
- package/chunk/CollegeNameComponent-DaTimEqC.js +4 -4
- package/chunk/CollegeNameComponent-DtKPZHb-.js +4 -4
- package/chunk/CopyToClipboardComponent-9hyfSMC0.js +4 -4
- package/chunk/CopyToClipboardComponent-H3bJGcOM.js +4 -4
- package/chunk/CountryComponentWrapper--2UQ7mXP.js +4 -4
- package/chunk/CountryComponentWrapper-Ceq-eink.js +4 -4
- package/chunk/DriverLicenseNumberComponent-D9cakdvU.js +4 -4
- package/chunk/DriverLicenseNumberComponent-ziLNYB8e.js +4 -4
- package/chunk/EBTCardNumberComponent-B1kv4R4G.js +4 -4
- package/chunk/EBTCardNumberComponent-oYQJ_tP7.js +4 -4
- package/chunk/EmailLoopPending-In0FH-Ap.js +4 -4
- package/chunk/EmailLoopPending-lxRF0bx8.js +4 -4
- package/chunk/FirstResponderOrganizationComponent-Bru1a0U7.js +4 -4
- package/chunk/FirstResponderOrganizationComponent-fPxZFdpO.js +4 -4
- package/chunk/FormFieldInputSelect-CjWY_ush.js +4 -4
- package/chunk/FormFieldInputSelect-o7QZaYhS.js +4 -4
- package/chunk/FormFieldLayout-DDEEmlGC.js +4 -4
- package/chunk/FormFieldLayout-DEVPpEyA.js +4 -4
- package/chunk/FormFieldText-CJ-GVpZE.js +4 -4
- package/chunk/FormFieldText-CaWtYVur.js +4 -4
- package/chunk/FormFieldTypeahead-C6eS7yJg.js +4 -4
- package/chunk/FormFieldTypeahead-CyKKVK89.js +4 -4
- package/chunk/FormSelectChoice-BahCx4wG.js +4 -4
- package/chunk/FormSelectChoice-C-rIlDKl.js +4 -4
- package/chunk/InputText-CCNbZmMe.js +4 -4
- package/chunk/InputText-PEiatRRJ.js +4 -4
- package/chunk/LicensedProfessionalOrganizationComponent-C5pc7hVJ.js +4 -4
- package/chunk/LicensedProfessionalOrganizationComponent-CnR_qF3r.js +4 -4
- package/chunk/MedicalProfessionalOrganizationComponent-CXHX25GN.js +4 -4
- package/chunk/MedicalProfessionalOrganizationComponent-DBf6V49M.js +4 -4
- package/chunk/MemberIdComponent-C8mVSo9m.js +4 -4
- package/chunk/MemberIdComponent-oanWSvQh.js +4 -4
- package/chunk/MembershipOrganizationComponent-CN6_d_Fk.js +4 -4
- package/chunk/MembershipOrganizationComponent-yu-UNXIK.js +4 -4
- package/chunk/Onfido-BG8cDEVW.js +4 -4
- package/chunk/PersonalInfoStepSubmitButton-j44RdZDq.js +4 -4
- package/chunk/PersonalInfoStepSubmitButton-v_kWLmEw.js +4 -4
- package/chunk/PersonalInfoStepWrapper-BOBNCgik.js +4 -4
- package/chunk/PersonalInfoStepWrapper-PV06WMKL.js +4 -4
- package/chunk/PostalCodeComponent-DrCcV90W.js +4 -4
- package/chunk/PostalCodeComponent-KXVfZkLx.js +4 -4
- package/chunk/SSN-B_z2R4Bx.js +4 -4
- package/chunk/SSN-Hb1lTx8A.js +4 -4
- package/chunk/StateSelectComponent-CChSqKXz.js +4 -4
- package/chunk/StateSelectComponent-CIpB-Rh1.js +4 -4
- package/chunk/StatusComponent-C6J1B7Tl.js +4 -4
- package/chunk/StatusComponent-pmuIhuXi.js +4 -4
- package/chunk/StepCard-CIfaQVu-.js +4 -4
- package/chunk/StepCard-dcwCtPrW.js +4 -4
- package/chunk/{StepCollectMilitaryStatusComponent-BFw6xXZ_.js → StepCollectMilitaryStatusComponent-7aKgQ9Sj.js} +7 -7
- package/chunk/{StepCollectMilitaryStatusComponent-BFw6xXZ_.js.map → StepCollectMilitaryStatusComponent-7aKgQ9Sj.js.map} +1 -1
- package/chunk/{StepCollectMilitaryStatusComponent-D8Cg_PCr.js → StepCollectMilitaryStatusComponent-BRimaaXv.js} +7 -7
- package/chunk/{StepCollectMilitaryStatusComponent-D8Cg_PCr.js.map → StepCollectMilitaryStatusComponent-BRimaaXv.js.map} +1 -1
- package/chunk/{StepDriverLicensePersonalInfoComponent-CufQozWB.js → StepDriverLicensePersonalInfoComponent-2TPYKvF4.js} +5 -5
- package/chunk/{StepDriverLicensePersonalInfoComponent-CUy3hSOh.js.map → StepDriverLicensePersonalInfoComponent-2TPYKvF4.js.map} +1 -1
- package/chunk/{StepDriverLicensePersonalInfoComponent-CUy3hSOh.js → StepDriverLicensePersonalInfoComponent-BwVtnrmJ.js} +5 -5
- package/chunk/{StepDriverLicensePersonalInfoComponent-CufQozWB.js.map → StepDriverLicensePersonalInfoComponent-BwVtnrmJ.js.map} +1 -1
- package/chunk/{StepGeneralIdentityPersonalInfoComponent--e85H1gm.js → StepGeneralIdentityPersonalInfoComponent-B_GAU5ZU.js} +6 -6
- package/chunk/{StepGeneralIdentityPersonalInfoComponent--e85H1gm.js.map → StepGeneralIdentityPersonalInfoComponent-B_GAU5ZU.js.map} +1 -1
- package/chunk/{StepGeneralIdentityPersonalInfoComponent-Bdj5NErb.js → StepGeneralIdentityPersonalInfoComponent-D51YIuCd.js} +6 -6
- package/chunk/{StepGeneralIdentityPersonalInfoComponent-Bdj5NErb.js.map → StepGeneralIdentityPersonalInfoComponent-D51YIuCd.js.map} +1 -1
- package/chunk/{StepHybridIdentityPersonalInfoComponent-Dh2YNjdy.js → StepHybridIdentityPersonalInfoComponent-kap6IZbx.js} +6 -6
- package/chunk/{StepHybridIdentityPersonalInfoComponent-Dh2YNjdy.js.map → StepHybridIdentityPersonalInfoComponent-kap6IZbx.js.map} +1 -1
- package/chunk/{StepHybridIdentityPersonalInfoComponent-DvK9EwQi.js → StepHybridIdentityPersonalInfoComponent-zAjPWGNG.js} +6 -6
- package/chunk/{StepHybridIdentityPersonalInfoComponent-DvK9EwQi.js.map → StepHybridIdentityPersonalInfoComponent-zAjPWGNG.js.map} +1 -1
- package/chunk/StepIDCheckLoopOnfido-Sg4a19wV.js +4 -4
- package/chunk/StepIDCheckLoopOnfido-djTS20UT.js +4 -4
- package/chunk/StepIDCheckLoopRegula-B5I-ojjy.js +4 -4
- package/chunk/StepIDCheckLoopRegula-DZA5G1Z6.js +4 -4
- package/chunk/{StepInactiveMilitaryPersonalInfoComponent-DOOVtWps.js → StepInactiveMilitaryPersonalInfoComponent-Bieu_7kd.js} +7 -7
- package/chunk/{StepInactiveMilitaryPersonalInfoComponent-DOOVtWps.js.map → StepInactiveMilitaryPersonalInfoComponent-Bieu_7kd.js.map} +1 -1
- package/chunk/{StepInactiveMilitaryPersonalInfoComponent-DaF0OIw-.js → StepInactiveMilitaryPersonalInfoComponent-Czd3ecq6.js} +7 -7
- package/chunk/{StepInactiveMilitaryPersonalInfoComponent-DaF0OIw-.js.map → StepInactiveMilitaryPersonalInfoComponent-Czd3ecq6.js.map} +1 -1
- package/chunk/TeacherSchoolComponent-BSHPjiwQ.js +4 -4
- package/chunk/TeacherSchoolComponent-Bf3ZhJ_c.js +4 -4
- package/chunk/ar-DRRl0F7-.js +4 -4
- package/chunk/bg-F0WsRCx8.js +4 -4
- package/chunk/bn-IN-CMjQj55J.js +4 -4
- package/chunk/cs-fNk_NoQI.js +4 -4
- package/chunk/da-KMILteCO.js +4 -4
- package/chunk/de-CWVNPgGa.js +4 -4
- package/chunk/downshift.esm-CtrbqQGL.js +4 -4
- package/chunk/downshift.esm-huKBwB2d.js +4 -4
- package/chunk/el-Cwv4peel.js +4 -4
- package/chunk/en-GB-Dqonxi7-.js +4 -4
- package/chunk/es-ES-C4H8ciVZ.js +4 -4
- package/chunk/es-hn_UHPBI.js +4 -4
- package/chunk/fi-CYcXXvjq.js +4 -4
- package/chunk/fr-CA-CGAQ-6AP.js +4 -4
- package/chunk/fr-D_IYCyUP.js +4 -4
- package/chunk/ga-45LsHAEB.js +4 -4
- package/chunk/hi-IN-ChuePzRc.js +4 -4
- package/chunk/hr-CX75fSnP.js +4 -4
- package/chunk/hu-BaLNR_Fx.js +4 -4
- package/chunk/id-BuJILOHQ.js +4 -4
- package/chunk/{index-DIp12ukz.js → index-4SoX7nBO.js} +5 -5
- package/chunk/{index-DIp12ukz.js.map → index-4SoX7nBO.js.map} +1 -1
- package/chunk/index-B0SBEWOf.js +4 -4
- package/chunk/{index-rViqil74.js → index-B0gkU4sD.js} +6 -6
- package/chunk/{index-Cjs5VMjq.js.map → index-B0gkU4sD.js.map} +1 -1
- package/chunk/index-B4FcNhzB.js +4 -4
- package/chunk/{index-C6Zi9YN5.js → index-B6DSPaeb.js} +6 -6
- package/chunk/{index-C6Zi9YN5.js.map → index-B6DSPaeb.js.map} +1 -1
- package/chunk/index-BA3bE-f-.js +4 -4
- package/chunk/{index-C6hAAbwq.js → index-BDfHyxH2.js} +6 -6
- package/chunk/{index-C6hAAbwq.js.map → index-BDfHyxH2.js.map} +1 -1
- package/chunk/{index-exPL5Yp5.js → index-BKpiJJJ9.js} +6 -6
- package/chunk/{index-BKJJkl7e.js.map → index-BKpiJJJ9.js.map} +1 -1
- package/chunk/index-BZ1nv-sB.js +4 -4
- package/chunk/index-BbOCWcRK.js +4 -4
- package/chunk/{index-B92WlzWU.js → index-Blxi9-p3.js} +5 -5
- package/chunk/{index-B92WlzWU.js.map → index-Blxi9-p3.js.map} +1 -1
- package/chunk/index-Bn00xQJF.js +4 -4
- package/chunk/index-Brpm5gN6.js +4 -4
- package/chunk/index-CHDBBfsg.js +4 -4
- package/chunk/{index-DluA07xU.js → index-CMYxhs0t.js} +6 -6
- package/chunk/{index-Ci9xfdh_.js.map → index-CMYxhs0t.js.map} +1 -1
- package/chunk/{index-Cjs5VMjq.js → index-CMwYcIy7.js} +6 -6
- package/chunk/{index-rViqil74.js.map → index-CMwYcIy7.js.map} +1 -1
- package/chunk/{index-7FgFM0BB.js → index-CO75J-sD.js} +7 -7
- package/chunk/{index-7FgFM0BB.js.map → index-CO75J-sD.js.map} +1 -1
- package/chunk/index-CR19uOwz.js +4 -4
- package/chunk/index-CTGY1a4m.js +4 -4
- package/chunk/{index-Boz8OGs2.js → index-CTjvQpKK.js} +6 -6
- package/chunk/{index-7yjIdl5b.js.map → index-CTjvQpKK.js.map} +1 -1
- package/chunk/index-CaBrLsal.js +4 -4
- package/chunk/{index-CVNb00ji.js → index-Ccp2Exqo.js} +6 -6
- package/chunk/{index-BwYlPjg-.js.map → index-Ccp2Exqo.js.map} +1 -1
- package/chunk/{index-DeYLtsQg.js → index-CfHHbJNm.js} +6 -6
- package/chunk/{index-DeYLtsQg.js.map → index-CfHHbJNm.js.map} +1 -1
- package/chunk/{index-CHA5YjcZ.js → index-Cgw-oCXC.js} +5 -5
- package/chunk/{index-CHA5YjcZ.js.map → index-Cgw-oCXC.js.map} +1 -1
- package/chunk/index-CrPc1exn.js +4 -4
- package/chunk/index-CwaTj-69.js +4 -4
- package/chunk/index-D2d6x5LN.js +4 -4
- package/chunk/{index-BestrDUg.js → index-D62LImgf.js} +6 -6
- package/chunk/{index-BestrDUg.js.map → index-D62LImgf.js.map} +1 -1
- package/chunk/index-D7Mqx5na.js +4 -4
- package/chunk/index-DFoMYB8K.js +4 -4
- package/chunk/{index-BwYlPjg-.js → index-DGCqI3ez.js} +6 -6
- package/chunk/{index-CVNb00ji.js.map → index-DGCqI3ez.js.map} +1 -1
- package/chunk/index-DIkWpujR.js +4 -4
- package/chunk/{index-DRzWEvzt.js → index-DM6d_MOp.js} +5 -5
- package/chunk/{index-DRzWEvzt.js.map → index-DM6d_MOp.js.map} +1 -1
- package/chunk/{index-BKJJkl7e.js → index-Di4VOQ0c.js} +6 -6
- package/chunk/{index-exPL5Yp5.js.map → index-Di4VOQ0c.js.map} +1 -1
- package/chunk/{index-CLCadcyZ.js → index-DsIG7oZ5.js} +7 -7
- package/chunk/{index-CLCadcyZ.js.map → index-DsIG7oZ5.js.map} +1 -1
- package/chunk/index-EUJqfdiJ.js +4 -4
- package/chunk/{index-Ci9xfdh_.js → index-Tt8XFCKg.js} +6 -6
- package/chunk/{index-DluA07xU.js.map → index-Tt8XFCKg.js.map} +1 -1
- package/chunk/{index-7yjIdl5b.js → index-XxwXcW8j.js} +6 -6
- package/chunk/{index-Boz8OGs2.js.map → index-XxwXcW8j.js.map} +1 -1
- package/chunk/{index-C_5U0d5a.js → index-brtM2eoI.js} +6 -6
- package/chunk/{index-C_5U0d5a.js.map → index-brtM2eoI.js.map} +1 -1
- package/chunk/index-dTu4ORna.js +4 -4
- package/chunk/{index-Zi6lCz6u.js → index-yLck7gVG.js} +6 -6
- package/chunk/{index-Zi6lCz6u.js.map → index-yLck7gVG.js.map} +1 -1
- package/chunk/is-B3D8NTKa.js +4 -4
- package/chunk/it-CzAy2lzA.js +4 -4
- package/chunk/iw-C9nimuXe.js +4 -4
- package/chunk/ja-BEXgm7zu.js +4 -4
- package/chunk/ko-Ct-zPR2E.js +4 -4
- package/chunk/lo-Di9C_kLP.js +4 -4
- package/chunk/lt-CEBQxuWT.js +4 -4
- package/chunk/{militaryStepHelpers-CLn6PXMu.js → militaryStepHelpers-0OUuQpBw.js} +5 -5
- package/chunk/{militaryStepHelpers-CLn6PXMu.js.map → militaryStepHelpers-0OUuQpBw.js.map} +1 -1
- package/chunk/{militaryStepHelpers-pEvqlKjI.js → militaryStepHelpers-jW2_4c1l.js} +5 -5
- package/chunk/{militaryStepHelpers-pEvqlKjI.js.map → militaryStepHelpers-jW2_4c1l.js.map} +1 -1
- package/chunk/mocks-CeAm-JFs.js +4 -4
- package/chunk/mocks-ClJ0M6QH.js +4 -4
- package/chunk/ms-CxGIGN7C.js +4 -4
- package/chunk/nl-BE-DPBUnfk6.js +4 -4
- package/chunk/nl-BIm7MF9X.js +4 -4
- package/chunk/no-BmBisNVx.js +4 -4
- package/chunk/pl-BOGNzi_o.js +4 -4
- package/chunk/pt-BR-uABX_syI.js +4 -4
- package/chunk/pt-MSESKPWr.js +4 -4
- package/chunk/ro-DoSzUhte.js +4 -4
- package/chunk/ru-_re-OOAp.js +4 -4
- package/chunk/sk-BS3zToE5.js +4 -4
- package/chunk/sl-CVBUMpyN.js +4 -4
- package/chunk/sr-Cmqfavur.js +4 -4
- package/chunk/sv-BzRp9aoC.js +4 -4
- package/chunk/sw-C4I4Ivyc.js +4 -4
- package/chunk/th-SsMlrFQN.js +4 -4
- package/chunk/tr-i4hcCWIF.js +4 -4
- package/chunk/uk-CLl1S03h.js +4 -4
- package/chunk/ur-CfVN1Pr2.js +4 -4
- package/chunk/useCollectFieldsEndpoint-Cd6d_u47.js +4 -4
- package/chunk/useCollectFieldsEndpoint-DqTjyVEr.js +4 -4
- package/chunk/useMetrics-D2fG6cgw.js +4 -4
- package/chunk/useMetrics-wq7yrL0b.js +4 -4
- package/chunk/vi-STS0AV-q.js +4 -4
- package/chunk/zh-HK-DGm6tmJZ.js +4 -4
- package/chunk/zh-rPW1DJOh.js +4 -4
- package/chunk/zu-D7Vc6viT.js +4 -4
- package/package.json +1 -1
- package/sheerid-install.css +4 -4
- package/sheerid-install.js +4 -4
- package/sheerid.css +4 -4
- package/sheerid.js +24 -24
- package/chunk/CaptchaComponent-CKP3wfXl.js.map +0 -1
- package/chunk/CaptchaComponent-CR32xDg8.js.map +0 -1
|
@@ -4,16 +4,16 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
import { i as I, m as f, R as N, j as s, P as E, g as t, o as n, a6 as j, a2 as y, _ as P, F as m, n as F, U as T, V as D, x as V, e as R, a7 as k } from "../_mysheerid-preview.js";
|
|
13
13
|
import { u as K } from "./useCollectFieldsEndpoint-Cd6d_u47.js";
|
|
14
|
-
import { F as L, L as c, P as B, a as w, M as z, C as O } from "./CaptchaComponent-
|
|
14
|
+
import { F as L, L as c, P as B, a as w, M as z, C as O } from "./CaptchaComponent-CnWyxiTy.js";
|
|
15
15
|
import { E as q, P as A } from "./PersonalInfoStepSubmitButton-v_kWLmEw.js";
|
|
16
|
-
import { B as H } from "./militaryStepHelpers-
|
|
16
|
+
import { B as H } from "./militaryStepHelpers-jW2_4c1l.js";
|
|
17
17
|
import { P as W } from "./PostalCodeComponent-KXVfZkLx.js";
|
|
18
18
|
import { S as U } from "./StatusComponent-pmuIhuXi.js";
|
|
19
19
|
import { M as $ } from "./MedicalProfessionalOrganizationComponent-CXHX25GN.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-DluA07xU.js","sources":["../../src/components/StepMedicalProfessionalPersonalInfo/StepMedicalProfessionalPersonalInfoComponent.tsx"],"sourcesContent":["/**\n * TODO - preamble\n */\nimport React from \"react\";\nimport { FormattedHTMLMessage, injectIntl } from \"react-intl\";\n\nimport { useCollectFieldsEndpoint } from \"@/lib/ServerApi/useCollectFieldsEndpoint\";\n\nimport {\n VerificationStepsEnum,\n MedicalProfessionalStatusDefaultMessagesEnum,\n} from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type FormSelectChoice,\n type Organization,\n type MedicalProfessionalPersonalInfoViewModel,\n type MedicalProfessionalPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n produceDraftViewModel,\n getStatusLabel,\n getAvailableMedicalStatuses,\n getFieldConfigByFieldId,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MarketConsentWrapperComponent as MarketConsentWrapper } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { PostalCodeComponent as PostalCode } from \"../FormFields/PostalCode/PostalCodeComponent\";\nimport { StatusComponent as MedicalStatus } from \"../FormFields/Status/StatusComponent\";\nimport { MedicalProfessionalOrganizationComponent as MedicalProfessionalOrganization } from \"../FormFields/MedicalProfessionalOrganization/MedicalProfessionalOrganizationComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMedicalProfessionalPersonalInfoComponentProps {\n verificationService: VerificationService;\n intl: any;\n}\n\ntype MemberIdFieldType =\n | \"registrationNumber\"\n | \"numeroColegiado\"\n | \"autorisationsId\"\n | \"globalLocationNumber\"\n | \"gbrNummer\";\n\nconst memberIdMessageKeysByCountry: Record<string, MemberIdFieldType> = {\n AT: \"gbrNummer\",\n ES: \"numeroColegiado\",\n DK: \"autorisationsId\",\n CH: \"globalLocationNumber\",\n IE: \"registrationNumber\",\n GB: \"registrationNumber\",\n};\n\nconst getMemberIdMessageKeys = (country: string) => {\n const memberIdFieldType: MemberIdFieldType =\n memberIdMessageKeysByCountry[country] || \"registrationNumber\";\n return {\n labelKey: `step.collectMedicalPersonalInfo.${memberIdFieldType}Label`,\n explanationKey: `step.collectMedicalPersonalInfo.${memberIdFieldType}Explanation`,\n };\n};\n\nexport const StepMedicalProfessionalPersonalInfo = ({\n intl,\n verificationService,\n}: StepMedicalProfessionalPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MedicalProfessionalPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MedicalProfessionalPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n\n const locale = viewModel.localeChoice.value;\n\n const updateMedicalProfessionalViewModel = (\n key: keyof MedicalProfessionalPersonalInfoViewModel,\n value: any,\n ) => {\n const nextState = produceDraftViewModel(viewModel, key, value);\n verificationService.updateViewModel(nextState);\n };\n\n const { isFieldOptional } = useCollectFieldsEndpoint({\n verificationId: verificationResponse.verificationId,\n currentStep: verificationResponse.currentStep,\n viewModel,\n });\n const shouldRenderMemberId = isFieldOptional(\"memberId\");\n\n React.useEffect(() => {\n // If the memberId field is not rendered, we shouldn't validate it\n // partially update to avoid clobbering the rest of the viewModel\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (shouldRenderMemberId) {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n } else {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n }\n }, [shouldRenderMemberId]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"medical-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n <MedicalStatus\n segmentId=\"medical\"\n value={{\n value: viewModel.status,\n label: getStatusLabel(\n intl,\n viewModel.status,\n MedicalProfessionalStatusDefaultMessagesEnum,\n ),\n }}\n isErrored={!!fieldValidationErrors.status}\n options={getAvailableMedicalStatuses(intl, verificationResponse.availableStatuses)}\n disabled={getFieldConfigByFieldId(\"status\")?.disabled}\n onChange={(status: FormSelectChoice) => {\n updateMedicalProfessionalViewModel(\"status\", status ? (status.value as string) : \"\");\n updateFieldValidationErrorsByFieldId(\n \"status\",\n status ? (status.value as string) : \"\",\n verificationService,\n );\n }}\n />\n <MedicalProfessionalOrganization\n isErrored={!!fieldValidationErrors.organization}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n value={\n (verificationService.viewModel as MedicalProfessionalPersonalInfoViewModel).organization\n }\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n />\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n />\n <PostalCode\n isErrored={!!fieldValidationErrors.postalCode}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"postalCode\", newValue);\n updateFieldValidationErrorsByFieldId(\"postalCode\", newValue, verificationService);\n }}\n value={viewModel.postalCode}\n disabled={getFieldConfigByFieldId(\"postalCode\")?.disabled}\n explanation={\n <FormattedHTMLMessage\n id=\"postalCodeExplanation\"\n defaultMessage=\"Use the location on file with your licensing body\"\n />\n }\n />\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={\n <FormattedHTMLMessage\n id=\"emailExplanation\"\n defaultMessage=\"Needed to send you your unique code\"\n />\n }\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n {shouldRenderMemberId && (\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={getFieldConfigByFieldId(\"memberId\")?.requireIfOptional}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n explanation={\n <FormattedHTMLMessage\n id={getMemberIdMessageKeys(viewModel.country).explanationKey}\n defaultMessage=\"Your Professional Membership Registration Number\"\n />\n }\n label={\n <FormattedHTMLMessage\n id={getMemberIdMessageKeys(viewModel.country).labelKey}\n defaultMessage=\"Registration Number\"\n />\n }\n />\n )}\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n <MarketConsentWrapper\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMedicalProfessionalPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Medical Professional Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMedicalProfessionalPersonalInfoComponent = injectIntl(\n StepMedicalProfessionalPersonalInfo,\n);\n"],"names":["memberIdMessageKeysByCountry","getMemberIdMessageKeys","country","memberIdFieldType","StepMedicalProfessionalPersonalInfo","intl","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","locale","updateMedicalProfessionalViewModel","key","value","nextState","produceDraftViewModel","isFieldOptional","useCollectFieldsEndpoint","shouldRenderMemberId","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","getFieldConfigByFieldId","MedicalStatus","getStatusLabel","MedicalProfessionalStatusDefaultMessagesEnum","getAvailableMedicalStatuses","status","updateFieldValidationErrorsByFieldId","MedicalProfessionalOrganization","choice","updateViewModelOrganization","FirstName","newValue","LastName","BirthDate","PostalCode","FormattedHTMLMessage","Email","event","handleEmailOnKeyDown","PhoneNumber","MemberId","config","FormFieldCustom","MarketConsentWrapper","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMedicalProfessionalPersonalInfoComponent","injectIntl"],"mappings":";;;;;;;;;;;;AA8DA,MAAMA,IAAkE;AAAA,EACtE,IAAI;AAAA,EACJ,IAA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AAAA,UAAA;AAAA,QAAA;AAAA,QAGrCoB,gBAAAA,EAAAA;AAAAA,UAAC8B;AAAA,UAAA;AAAA,YACC,MAAMC,EAAsB;AAAA,YAC5B,qBAAArD;AAAA,YACA,WAAAC;AAAA,YACA,oBAAAG;AAAA,YACA,YACEkB,gBAAAA,EAAAA;AAAAA,cAACmB;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,KAA+CC;AAAA,EAC1DzD;AACF;"}
|
|
1
|
+
{"version":3,"file":"index-Tt8XFCKg.js","sources":["../../src/components/StepMedicalProfessionalPersonalInfo/StepMedicalProfessionalPersonalInfoComponent.tsx"],"sourcesContent":["/**\n * TODO - preamble\n */\nimport React from \"react\";\nimport { FormattedHTMLMessage, injectIntl } from \"react-intl\";\n\nimport { useCollectFieldsEndpoint } from \"@/lib/ServerApi/useCollectFieldsEndpoint\";\n\nimport {\n VerificationStepsEnum,\n MedicalProfessionalStatusDefaultMessagesEnum,\n} from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type FormSelectChoice,\n type Organization,\n type MedicalProfessionalPersonalInfoViewModel,\n type MedicalProfessionalPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n produceDraftViewModel,\n getStatusLabel,\n getAvailableMedicalStatuses,\n getFieldConfigByFieldId,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MarketConsentWrapperComponent as MarketConsentWrapper } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { PostalCodeComponent as PostalCode } from \"../FormFields/PostalCode/PostalCodeComponent\";\nimport { StatusComponent as MedicalStatus } from \"../FormFields/Status/StatusComponent\";\nimport { MedicalProfessionalOrganizationComponent as MedicalProfessionalOrganization } from \"../FormFields/MedicalProfessionalOrganization/MedicalProfessionalOrganizationComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMedicalProfessionalPersonalInfoComponentProps {\n verificationService: VerificationService;\n intl: any;\n}\n\ntype MemberIdFieldType =\n | \"registrationNumber\"\n | \"numeroColegiado\"\n | \"autorisationsId\"\n | \"globalLocationNumber\"\n | \"gbrNummer\";\n\nconst memberIdMessageKeysByCountry: Record<string, MemberIdFieldType> = {\n AT: \"gbrNummer\",\n ES: \"numeroColegiado\",\n DK: \"autorisationsId\",\n CH: \"globalLocationNumber\",\n IE: \"registrationNumber\",\n GB: \"registrationNumber\",\n};\n\nconst getMemberIdMessageKeys = (country: string) => {\n const memberIdFieldType: MemberIdFieldType =\n memberIdMessageKeysByCountry[country] || \"registrationNumber\";\n return {\n labelKey: `step.collectMedicalPersonalInfo.${memberIdFieldType}Label`,\n explanationKey: `step.collectMedicalPersonalInfo.${memberIdFieldType}Explanation`,\n };\n};\n\nexport const StepMedicalProfessionalPersonalInfo = ({\n intl,\n verificationService,\n}: StepMedicalProfessionalPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MedicalProfessionalPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MedicalProfessionalPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n\n const locale = viewModel.localeChoice.value;\n\n const updateMedicalProfessionalViewModel = (\n key: keyof MedicalProfessionalPersonalInfoViewModel,\n value: any,\n ) => {\n const nextState = produceDraftViewModel(viewModel, key, value);\n verificationService.updateViewModel(nextState);\n };\n\n const { isFieldOptional } = useCollectFieldsEndpoint({\n verificationId: verificationResponse.verificationId,\n currentStep: verificationResponse.currentStep,\n viewModel,\n });\n const shouldRenderMemberId = isFieldOptional(\"memberId\");\n\n React.useEffect(() => {\n // If the memberId field is not rendered, we shouldn't validate it\n // partially update to avoid clobbering the rest of the viewModel\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (shouldRenderMemberId) {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n } else {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n }\n }, [shouldRenderMemberId]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"medical-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n <MedicalStatus\n segmentId=\"medical\"\n value={{\n value: viewModel.status,\n label: getStatusLabel(\n intl,\n viewModel.status,\n MedicalProfessionalStatusDefaultMessagesEnum,\n ),\n }}\n isErrored={!!fieldValidationErrors.status}\n options={getAvailableMedicalStatuses(intl, verificationResponse.availableStatuses)}\n disabled={getFieldConfigByFieldId(\"status\")?.disabled}\n onChange={(status: FormSelectChoice) => {\n updateMedicalProfessionalViewModel(\"status\", status ? (status.value as string) : \"\");\n updateFieldValidationErrorsByFieldId(\n \"status\",\n status ? (status.value as string) : \"\",\n verificationService,\n );\n }}\n />\n <MedicalProfessionalOrganization\n isErrored={!!fieldValidationErrors.organization}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n value={\n (verificationService.viewModel as MedicalProfessionalPersonalInfoViewModel).organization\n }\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n />\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n />\n <PostalCode\n isErrored={!!fieldValidationErrors.postalCode}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"postalCode\", newValue);\n updateFieldValidationErrorsByFieldId(\"postalCode\", newValue, verificationService);\n }}\n value={viewModel.postalCode}\n disabled={getFieldConfigByFieldId(\"postalCode\")?.disabled}\n explanation={\n <FormattedHTMLMessage\n id=\"postalCodeExplanation\"\n defaultMessage=\"Use the location on file with your licensing body\"\n />\n }\n />\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={\n <FormattedHTMLMessage\n id=\"emailExplanation\"\n defaultMessage=\"Needed to send you your unique code\"\n />\n }\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n {shouldRenderMemberId && (\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={getFieldConfigByFieldId(\"memberId\")?.requireIfOptional}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n explanation={\n <FormattedHTMLMessage\n id={getMemberIdMessageKeys(viewModel.country).explanationKey}\n defaultMessage=\"Your Professional Membership Registration Number\"\n />\n }\n label={\n <FormattedHTMLMessage\n id={getMemberIdMessageKeys(viewModel.country).labelKey}\n defaultMessage=\"Registration Number\"\n />\n }\n />\n )}\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n <MarketConsentWrapper\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMedicalProfessionalViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMedicalProfessionalPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Medical Professional Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMedicalProfessionalPersonalInfoComponent = injectIntl(\n StepMedicalProfessionalPersonalInfo,\n);\n"],"names":["memberIdMessageKeysByCountry","getMemberIdMessageKeys","country","memberIdFieldType","StepMedicalProfessionalPersonalInfo","intl","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","locale","updateMedicalProfessionalViewModel","key","value","nextState","produceDraftViewModel","isFieldOptional","useCollectFieldsEndpoint","shouldRenderMemberId","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","getFieldConfigByFieldId","MedicalStatus","getStatusLabel","MedicalProfessionalStatusDefaultMessagesEnum","getAvailableMedicalStatuses","status","updateFieldValidationErrorsByFieldId","MedicalProfessionalOrganization","choice","updateViewModelOrganization","FirstName","newValue","LastName","BirthDate","PostalCode","FormattedHTMLMessage","Email","event","handleEmailOnKeyDown","PhoneNumber","MemberId","config","FormFieldCustom","MarketConsentWrapper","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMedicalProfessionalPersonalInfoComponent","injectIntl"],"mappings":";;;;;;;;;;;;AA8DA,MAAMA,IAAkE;AAAA,EACtE,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN,GAEMC,IAAyB,CAACC,MAAoB;AAClD,QAAMC,IACJH,EAA6BE,CAAO,KAAK;AAC3C,SAAO;AAAA,IACL,UAAU,mCAAmCC,CAAiB;AAAA,IAC9D,gBAAgB,mCAAmCA,CAAiB;AAAA,EAAA;AAExE,GAEaC,IAAsC,CAAC;AAAA,EAClD,MAAAC;AAAA,EACA,qBAAAC;AACF,MAAyD;AACvD,QAAMC,IAAYD,EAAoB,WAChC,EAAE,uBAAAE,MAA0BF,GAC5BG,IACJH,EAAoB,sBAChBI,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAUC,EAAA,GAEVC,IAASP,EAAU,aAAa,OAEhCQ,IAAqC,CACzCC,GACAC,MACG;AACH,UAAMC,IAAYC,EAAsBZ,GAAWS,GAAKC,CAAK;AAC7D,IAAAX,EAAoB,gBAAgBY,CAAS;AAAA,EAC/C,GAEM,EAAE,iBAAAE,EAAA,IAAoBC,EAAyB;AAAA,IACnD,gBAAgBZ,EAAqB;AAAA,IACrC,aAAaA,EAAqB;AAAA,IAClC,WAAAF;AAAA,EAAA,CACD,GACKe,IAAuBF,EAAgB,UAAU;AAEvD,SAAAG,EAAM,UAAU,MAAM;AAGpB,UAAMC,KAAYlB,EAAoB,W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AoB,UAAU;AAAA,gBACjC,oBAAoBqC;AAAA,cAAA,CACrB,GACDL,EAAqC,sBAAsBK,GAAUrC,CAAmB;AAAA,YAC1F;AAAA,YACA,WAAAC;AAAA,YACA,UAAUyB,EAAwB,oBAAoB,GAAG;AAAA,UAAA;AAAA,QAAA;AAAA,QAE3DJ,gBAAAA,EAAAA,IAAC4B,GAAA,EAAa,qBAAAlD,GAA0C,QAAO,qBAAA,CAAqB;AAAA,QAEpFsB,gBAAAA,EAAAA;AAAAA,UAAC6B;AAAA,UAAA;AAAA,YACC,qBAAAnD;AAAA,YACA,WAAW,CAAC,CAACE,EAAsB;AAAA,UAAA;AAAA,QAAA;AAAA,QAGrCoB,gBAAAA,EAAAA;AAAAA,UAAC8B;AAAA,UAAA;AAAA,YACC,MAAMC,EAAsB;AAAA,YAC5B,qBAAArD;AAAA,YACA,WAAAC;AAAA,YACA,oBAAAG;AAAA,YACA,YACEkB,gBAAAA,EAAAA;AAAAA,cAACmB;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,KAA+CC;AAAA,EAC1DzD;AACF;"}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
|
|
2
2
|
/**
|
|
3
|
-
* VERSION: 2.
|
|
4
|
-
* BUILD_TIMESTAMP:
|
|
5
|
-
* BUILD_DATE:
|
|
6
|
-
* BUILD_COMMIT:
|
|
3
|
+
* VERSION: 2.231.0
|
|
4
|
+
* BUILD_TIMESTAMP: 1778866812284
|
|
5
|
+
* BUILD_DATE: Fri May 15 2026 17:40:12 GMT+0000 (Coordinated Universal Time)
|
|
6
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
7
7
|
*/
|
|
8
8
|
import { i as I, m as F, $ as P, a0 as M, h as c, R, o as d, j as o, P as D, g as r, n as A, F as u, U as T, V, x as k, e as q } from "../sheerid.js";
|
|
9
9
|
import { u as B } from "./useCollectFieldsEndpoint-DqTjyVEr.js";
|
|
10
|
-
import { F as L, L as U, P as W, a as w, M as H, C as K } from "./CaptchaComponent-
|
|
10
|
+
import { F as L, L as U, P as W, a as w, M as H, C as K } from "./CaptchaComponent-SmUa6m52.js";
|
|
11
11
|
import { E as O, P as $ } from "./PersonalInfoStepSubmitButton-j44RdZDq.js";
|
|
12
|
-
import { B as z } from "./militaryStepHelpers-
|
|
12
|
+
import { B as z } from "./militaryStepHelpers-0OUuQpBw.js";
|
|
13
13
|
import { P as G } from "./PostalCodeComponent-DrCcV90W.js";
|
|
14
14
|
import { C as J } from "./CountryComponentWrapper-Ceq-eink.js";
|
|
15
15
|
import { C as Q } from "./City-yVVnZQTP.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-Boz8OGs2.js","sources":["../../src/components/StepAgePersonalInfo/StepAgePersonalInfoComponent.tsx"],"sourcesContent":["/**\n * TODO - preamble\n */\nimport React from \"react\";\nimport { FormattedHTMLMessage, type InjectedIntl, injectIntl } from \"react-intl\";\n\nimport { getSafe } from \"@jslib/shared/utils/getSafe\";\n\nimport { useCollectFieldsEndpoint } from \"@/lib/ServerApi/useCollectFieldsEndpoint\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type AgePersonalInfoViewModel,\n type AgePersonalInfoResponse,\n type FormSelectChoice,\n type Country,\n type FieldDescription,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n getAvailableCountryChoices,\n getDefaultCountryChoice,\n produceDraftViewModel,\n getFieldConfigByFieldId,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { MarketConsentWrapperComponent as MarketConsentWrapper } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { PostalCodeComponent as PostalCode } from \"../FormFields/PostalCode/PostalCodeComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { CityComponent } from \"../FormFields/City/City\";\nimport { AddressComponent } from \"../FormFields/Address/AddressComponent\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepAgePersonalInfoComponentProps {\n intl: InjectedIntl;\n verificationService: VerificationService;\n}\n\nconst StepAgePersonalInfo = ({ verificationService, intl }: StepAgePersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as AgePersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse = verificationService.verificationResponse as AgePersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const countryChoices: FormSelectChoice<Country, string>[] = getAvailableCountryChoices(\n verificationService.programTheme,\n intl,\n );\n const defaultCountryChoice: FormSelectChoice<Country, string> =\n getDefaultCountryChoice(countryChoices);\n const safeCountryValue = getSafe(() => viewModel.countryChoice.value, defaultCountryChoice.value);\n const defaultRequiredFields: FieldDescription[] =\n safeCountryValue === \"US\" ? [{ key: \"postalCode\" }] : [];\n\n // PhoneNumber is required for all non-US age programs and if smsLoop is enabled.\n const showPhoneNumber =\n safeCountryValue !== \"US\" ||\n verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled;\n const phoneNumberRequired =\n safeCountryValue !== \"US\" || verificationService.programTheme.smsLoopEnabled;\n\n const locale = viewModel.localeChoice.value;\n const options = getOptions();\n\n if (\n !fieldValidationErrors.phoneNumber &&\n verificationResponse.errorIds &&\n verificationResponse.errorIds.includes(\"invalidPhoneNumber\")\n ) {\n verificationService.updateFieldValidationErrors({\n ...fieldValidationErrors,\n phoneNumber: \"invalidPhoneNumber\",\n });\n }\n\n const updateAgeViewModel = (key: keyof AgePersonalInfoViewModel, value: any) => {\n const nextState: AgePersonalInfoViewModel = produceDraftViewModel(viewModel, key, value);\n verificationService.updateViewModel(nextState);\n };\n\n const { isFieldRequired } = useCollectFieldsEndpoint({\n verificationId: verificationResponse.verificationId,\n currentStep: verificationResponse.currentStep,\n viewModel,\n defaultRequiredFields,\n });\n\n React.useEffect(() => {\n // When country changes re-check the phone number validation\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", viewModel.phoneNumber, verificationService);\n }, [viewModel.country]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader verificationService={verificationService} classNameIdentifier=\"age\" />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateAgeViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateAgeViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n onChange={(newValue) => {\n updateAgeViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n {isFieldRequired(\"city\") && (\n <CityComponent\n value={viewModel.city}\n isRequired\n isErrored={!!fieldValidationErrors.city}\n errorId={fieldValidationErrors.city}\n disabled={getFieldConfigByFieldId(\"city\")?.disabled}\n onChange={(value) => {\n updateAgeViewModel(\"city\", value);\n updateFieldValidationErrorsByFieldId(\"city\", value, verificationService);\n }}\n />\n )}\n {isFieldRequired(\"address1\") && (\n <AddressComponent\n value={viewModel.address1}\n isRequired\n isErrored={!!fieldValidationErrors.address1}\n errorId={fieldValidationErrors.address1}\n onChange={(value) => {\n updateAgeViewModel(\"address1\", value);\n updateFieldValidationErrorsByFieldId(\"address1\", value, verificationService);\n }}\n />\n )}\n {isFieldRequired(\"postalCode\") && (\n <PostalCode\n isErrored={!!fieldValidationErrors.postalCode}\n onChange={(newValue) => {\n updateAgeViewModel(\"postalCode\", newValue);\n updateFieldValidationErrorsByFieldId(\"postalCode\", newValue, verificationService);\n }}\n value={viewModel.postalCode}\n disabled={getFieldConfigByFieldId(\"postalCode\")?.disabled}\n />\n )}\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateAgeViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n {showPhoneNumber ? (\n <PhoneNumber\n isRequired={phoneNumberRequired}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateAgeViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapper\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateAgeViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectAgePersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify and continue\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepAgePersonalInfoComponent = injectIntl(StepAgePersonalInfo);\n"],"names":["StepAgePersonalInfo","verificationService","intl","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","countryChoices","getAvailableCountryChoices","defaultCountryChoice","getDefaultCountryChoice","safeCountryValue","getSafe","defaultRequiredFields","showPhoneNumber","phoneNumberRequired","locale","options","getOptions","updateAgeViewModel","key","value","nextState","produceDraftViewModel","isFieldRequired","useCollectFieldsEndpoint","React","updateFieldValidationErrorsByFieldId","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","getFieldConfigByFieldId","FirstName","newValue","LastName","BirthDate","CityComponent","AddressComponent","PostalCode","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","PhoneNumber","config","FormFieldCustom","MarketConsentWrapper","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepAgePersonalInfoComponent","injectIntl"],"mappings":";;;;;;;;;;;AAqDA,MAAMA,IAAsB,CAAC,EAAE,qBAAAC,GAAqB,MAAAC,QAA8C;AAChG,QAAMC,IAAYF,EAAoB,WAChC,EAAE,uBAAAG,MAA0BH,GAC5BI,IAAuBJ,EAAoB,sBAC3CK,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAsDC;AAAA,IAC1DR,EAAoB;AAAA,IACpBC;AAAA,EAAA,GAEIQ,IACJC,EAAwBH,CAAc,GAClCI,IAAmBC,EAAQ,MAAMV,EAAU,cAAc,OAAOO,EAAqB,KAAK,GAC1FI,IACJF,MAAqB,OAAO,CAAC,EAAE,KAAK,aAAA,CAAc,IAAI,CAAA,GAGlDG,IACJH,MAAqB,QACrBX,EAAoB,aAAa,2BACjCA,EAAoB,aAAa,gBAC7Be,IACJJ,MAAqB,QAAQX,EAAoB,aAAa,gBAE1DgB,IAASd,EAAU,aAAa,OAChCe,IAAUC,EAAA;AAEhB,EACE,CAACf,EAAsB,eACvBC,EAAqB,YACrBA,EAAqB,SAAS,SAAS,oBAAoB,KAE3DJ,EAAoB,4BAA4B;AAAA,IAC9C,GAAGG;AAAA,IACH,aAAa;AAAA,EAAA,CACd;AAGH,QAAMgB,IAAqB,CAACC,G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C,EAAA,CAA0C,CAC5E;AAAA,QAED8B,gBAAAA,EAAAA;AAAAA,UAACmB;AAAAA,UAAA;AAAA,YACC,qBAAAjD;AAAA,YACA,WAAW,CAAC,CAACG,EAAsB;AAAA,YACnC,UAAU,CAACiC,MAAa;AACtB,cAAAjB,EAAmB,YAAY;AAAA,gBAC7B,GAAGnB,EAAoB,UAAU;AAAA,gBACjC,oBAAoBoC;AAAA,cAAA,CACrB,GACDT,EAAqC,sBAAsBS,GAAUpC,CAAmB;AAAA,YAC1F;AAAA,YACA,WAAAE;AAAA,YACA,UAAUgC,EAAwB,oBAAoB,GAAG;AAAA,UAAA;AAAA,QAAA;AAAA,QAG3DJ,gBAAAA,EAAAA,IAACoB,GAAA,EAAa,qBAAAlD,GAA0C,QAAO,qBAAA,CAAqB;AAAA,QAEpF8B,gBAAAA,EAAAA;AAAAA,UAACqB;AAAA,UAAA;AAAA,YACC,qBAAAnD;AAAA,YACA,WAAW,CAAC,CAACG,EAAsB;AAAA,UAAA;AAAA,QAAA;AAAA,QAErC2B,gBAAAA,EAAAA;AAAAA,UAACsB;AAAA,UAAA;AAAA,YACC,MAAMC,EAAsB;AAAA,YAC5B,qBAAArD;AAAA,YACA,WAAAE;AAAA,YACA,oBAAAG;AAAA,YACA,YACEyB,gBAAAA,EAAAA;AAAAA,cAACa;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaW,KAA+BC,EAAWxD,CAAmB;"}
|
|
1
|
+
{"version":3,"file":"index-XxwXcW8j.js","sources":["../../src/components/StepAgePersonalInfo/StepAgePersonalInfoComponent.tsx"],"sourcesContent":["/**\n * TODO - preamble\n */\nimport React from \"react\";\nimport { FormattedHTMLMessage, type InjectedIntl, injectIntl } from \"react-intl\";\n\nimport { getSafe } from \"@jslib/shared/utils/getSafe\";\n\nimport { useCollectFieldsEndpoint } from \"@/lib/ServerApi/useCollectFieldsEndpoint\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type AgePersonalInfoViewModel,\n type AgePersonalInfoResponse,\n type FormSelectChoice,\n type Country,\n type FieldDescription,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n getAvailableCountryChoices,\n getDefaultCountryChoice,\n produceDraftViewModel,\n getFieldConfigByFieldId,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { MarketConsentWrapperComponent as MarketConsentWrapper } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { PostalCodeComponent as PostalCode } from \"../FormFields/PostalCode/PostalCodeComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { CityComponent } from \"../FormFields/City/City\";\nimport { AddressComponent } from \"../FormFields/Address/AddressComponent\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepAgePersonalInfoComponentProps {\n intl: InjectedIntl;\n verificationService: VerificationService;\n}\n\nconst StepAgePersonalInfo = ({ verificationService, intl }: StepAgePersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as AgePersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse = verificationService.verificationResponse as AgePersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const countryChoices: FormSelectChoice<Country, string>[] = getAvailableCountryChoices(\n verificationService.programTheme,\n intl,\n );\n const defaultCountryChoice: FormSelectChoice<Country, string> =\n getDefaultCountryChoice(countryChoices);\n const safeCountryValue = getSafe(() => viewModel.countryChoice.value, defaultCountryChoice.value);\n const defaultRequiredFields: FieldDescription[] =\n safeCountryValue === \"US\" ? [{ key: \"postalCode\" }] : [];\n\n // PhoneNumber is required for all non-US age programs and if smsLoop is enabled.\n const showPhoneNumber =\n safeCountryValue !== \"US\" ||\n verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled;\n const phoneNumberRequired =\n safeCountryValue !== \"US\" || verificationService.programTheme.smsLoopEnabled;\n\n const locale = viewModel.localeChoice.value;\n const options = getOptions();\n\n if (\n !fieldValidationErrors.phoneNumber &&\n verificationResponse.errorIds &&\n verificationResponse.errorIds.includes(\"invalidPhoneNumber\")\n ) {\n verificationService.updateFieldValidationErrors({\n ...fieldValidationErrors,\n phoneNumber: \"invalidPhoneNumber\",\n });\n }\n\n const updateAgeViewModel = (key: keyof AgePersonalInfoViewModel, value: any) => {\n const nextState: AgePersonalInfoViewModel = produceDraftViewModel(viewModel, key, value);\n verificationService.updateViewModel(nextState);\n };\n\n const { isFieldRequired } = useCollectFieldsEndpoint({\n verificationId: verificationResponse.verificationId,\n currentStep: verificationResponse.currentStep,\n viewModel,\n defaultRequiredFields,\n });\n\n React.useEffect(() => {\n // When country changes re-check the phone number validation\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", viewModel.phoneNumber, verificationService);\n }, [viewModel.country]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader verificationService={verificationService} classNameIdentifier=\"age\" />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateAgeViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateAgeViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n onChange={(newValue) => {\n updateAgeViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n {isFieldRequired(\"city\") && (\n <CityComponent\n value={viewModel.city}\n isRequired\n isErrored={!!fieldValidationErrors.city}\n errorId={fieldValidationErrors.city}\n disabled={getFieldConfigByFieldId(\"city\")?.disabled}\n onChange={(value) => {\n updateAgeViewModel(\"city\", value);\n updateFieldValidationErrorsByFieldId(\"city\", value, verificationService);\n }}\n />\n )}\n {isFieldRequired(\"address1\") && (\n <AddressComponent\n value={viewModel.address1}\n isRequired\n isErrored={!!fieldValidationErrors.address1}\n errorId={fieldValidationErrors.address1}\n onChange={(value) => {\n updateAgeViewModel(\"address1\", value);\n updateFieldValidationErrorsByFieldId(\"address1\", value, verificationService);\n }}\n />\n )}\n {isFieldRequired(\"postalCode\") && (\n <PostalCode\n isErrored={!!fieldValidationErrors.postalCode}\n onChange={(newValue) => {\n updateAgeViewModel(\"postalCode\", newValue);\n updateFieldValidationErrorsByFieldId(\"postalCode\", newValue, verificationService);\n }}\n value={viewModel.postalCode}\n disabled={getFieldConfigByFieldId(\"postalCode\")?.disabled}\n />\n )}\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateAgeViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n {showPhoneNumber ? (\n <PhoneNumber\n isRequired={phoneNumberRequired}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateAgeViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapper\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateAgeViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectAgePersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify and continue\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepAgePersonalInfoComponent = injectIntl(StepAgePersonalInfo);\n"],"names":["StepAgePersonalInfo","verificationService","intl","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","countryChoices","getAvailableCountryChoices","defaultCountryChoice","getDefaultCountryChoice","safeCountryValue","getSafe","defaultRequiredFields","showPhoneNumber","phoneNumberRequired","locale","options","getOptions","updateAgeViewModel","key","value","nextState","produceDraftViewModel","isFieldRequired","useCollectFieldsEndpoint","React","updateFieldValidationErrorsByFieldId","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","getFieldConfigByFieldId","FirstName","newValue","LastName","BirthDate","CityComponent","AddressComponent","PostalCode","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","PhoneNumber","config","FormFieldCustom","MarketConsentWrapper","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepAgePersonalInfoComponent","injectIntl"],"mappings":";;;;;;;;;;;AAqDA,MAAMA,IAAsB,CAAC,EAAE,qBAAAC,GAAqB,MAAAC,QAA8C;AAChG,QAAMC,IAAYF,EAAoB,WAChC,EAAE,uBAAAG,MAA0BH,GAC5BI,IAAuBJ,EAAoB,sBAC3CK,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAsDC;AAAA,IAC1DR,EAAoB;AAAA,IACpBC;AAAA,EAAA,GAEIQ,IACJC,EAAwBH,CAAc,GAClCI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,oBAAAG;AAAA,YACA,YACEyB,gBAAAA,EAAAA;AAAAA,cAACa;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaW,KAA+BC,EAAWxD,CAAmB;"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
|
|
2
2
|
/**
|
|
3
|
-
* VERSION: 2.
|
|
4
|
-
* BUILD_TIMESTAMP:
|
|
5
|
-
* BUILD_DATE:
|
|
6
|
-
* BUILD_COMMIT:
|
|
3
|
+
* VERSION: 2.231.0
|
|
4
|
+
* BUILD_TIMESTAMP: 1778866812284
|
|
5
|
+
* BUILD_DATE: Fri May 15 2026 17:40:12 GMT+0000 (Coordinated Universal Time)
|
|
6
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
7
7
|
*/
|
|
8
8
|
import { m as M, g as t, R as g, j as a, P as I, _ as j, o as n, n as N, F as b, U as E, V as f, p as F, e as y } from "../sheerid.js";
|
|
9
|
-
import { F as P, L as V, P as T, a as k, M as D, C as R } from "./CaptchaComponent-
|
|
9
|
+
import { F as P, L as V, P as T, a as k, M as D, C as R } from "./CaptchaComponent-SmUa6m52.js";
|
|
10
10
|
import { E as q, P as z } from "./PersonalInfoStepSubmitButton-j44RdZDq.js";
|
|
11
|
-
import { B } from "./militaryStepHelpers-
|
|
11
|
+
import { B } from "./militaryStepHelpers-0OUuQpBw.js";
|
|
12
12
|
import { M as L } from "./MemberIdComponent-C8mVSo9m.js";
|
|
13
13
|
import { C as O } from "./ChangeLocaleComponent-DUnfgQuX.js";
|
|
14
14
|
import { M as w } from "./MembershipOrganizationComponent-CN6_d_Fk.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-C_5U0d5a.js","sources":["../../src/components/StepMemberPersonalInfo/StepMemberPersonalInfoComponent.tsx"],"sourcesContent":["import React from \"react\";\nimport { FormattedHTMLMessage } from \"react-intl\";\nimport { produce } from \"immer\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type Organization,\n type MemberPersonalInfoViewModel,\n type MemberPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n getFieldConfigByFieldId,\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { MembershipOrganizationComponent } from \"../FormFields/MembershipOrganization/MembershipOrganizationComponent\";\nimport { MarketConsentWrapperComponent } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMemberPersonalInfoComponentProps {\n verificationService: VerificationService;\n}\n\nconst StepMemberPersonalInfo = ({ verificationService }: StepMemberPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MemberPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MemberPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n const isMemberIdRequired = getFieldConfigByFieldId(\"memberId\")?.requireIfOptional;\n\n const locale = viewModel.localeChoice.value;\n\n const updateMemberViewModel = (key: keyof MemberPersonalInfoViewModel, value: any) => {\n const nextState: MemberPersonalInfoViewModel = produce(\n viewModel,\n (draft: MemberPersonalInfoViewModel) => {\n (draft[key] as any) = value;\n },\n );\n verificationService.updateViewModel(nextState);\n };\n\n React.useEffect(() => {\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (!isMemberIdRequired) {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n } else {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n }\n }, [isMemberIdRequired]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"member-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <MembershipOrganizationComponent\n value={(verificationService.viewModel as MemberPersonalInfoViewModel).organization}\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.organization}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateMemberViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n isRequired={getFieldConfigByFieldId(\"birthDate\")?.requireIfOptional}\n onChange={(newValue) => {\n updateMemberViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={isMemberIdRequired}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n />\n\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMemberViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapperComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMemberViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMemberPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Membership Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMemberPersonalInfoComponent = StepMemberPersonalInfo;\n"],"names":["StepMemberPersonalInfo","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","isMemberIdRequired","getFieldConfigByFieldId","locale","updateMemberViewModel","key","value","nextState","produce","draft","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","MembershipOrganizationComponent","choice","updateViewModelOrganization","updateFieldValidationErrorsByFieldId","FirstName","newValue","LastName","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","BirthDate","MemberId","PhoneNumber","config","FormFieldCustom","MarketConsentWrapperComponent","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMemberPersonalInfoComponent"],"mappings":";;;;;;;;;AAyCA,MAAMA,IAAyB,CAAC,EAAE,qBAAAC,QAAgE;AAChG,QAAMC,IAAYD,EAAoB,WAChC,EAAE,uBAAAE,MAA0BF,GAC5BG,IACJH,EAAoB,sBAChBI,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAUC,EAAA,GACVC,IAAqBC,EAAwB,UAAU,GAAG,mBAE1DC,IAAST,EAAU,aAAa,OAEhCU,IAAwB,CAACC,GAAwCC,MAAe;AACpF,UAAMC,IAAyCC;AAAAA,MAC7Cd;AAAA,MACA,CAACe,MAAuC;AACrC,QAAAA,EAAMJ,CAAG,IAAYC;AAAA,MACxB;AAAA,IAAA;AAEF,IAAAb,EAAoB,gBAAgBc,CAAS;AAAA,EAC/C;AAEA,SAAAG,EAAM,UAAU,MAAM;AACpB,UAAMC,KAAYlB,EAAoB,WAAW,0BAA0B,CAAA,GAAI;AAAA,MAC7E,CAACmB,MAAOA,MAAO;AAAA,IAAA;AAEjB,IAAKX,IAMHR,EAAoB,gBAAgB,EAAE,wBAAwBkB,EAAA,GAAY,EAAE,SAAS,IAAM,IAL3FlB,EAAoB;AAAA,MAClB,EAAE,wBAAwB,CAAC,GAAGkB,GAAU,UAAU,EAAA;AAAA,MAClD,EAAE,SAAS,GAAA;AAAA,IAAK;AAAA,EAKtB,GAAG,CAACV,CAAkB,CAAC,GAGrBY,gBAAAA,EAAAA;AAAAA,IAACC;AAAA,IAAA;AAAA,MACC,qBAAArB;AAAA,MACA,MAAMG,EAAqB;AAAA,MAE3B,UAAA;AAAA,QAAAmB,gBAAAA,EAAAA;AAAAA,UAACC;AAAA,UAAA;AAAA,YACC,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B,gBAAAA,EAAAA;AAAAA,cAACY;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,IAAkChD;"}
|
|
1
|
+
{"version":3,"file":"index-brtM2eoI.js","sources":["../../src/components/StepMemberPersonalInfo/StepMemberPersonalInfoComponent.tsx"],"sourcesContent":["import React from \"react\";\nimport { FormattedHTMLMessage } from \"react-intl\";\nimport { produce } from \"immer\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type Organization,\n type MemberPersonalInfoViewModel,\n type MemberPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n getFieldConfigByFieldId,\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { MembershipOrganizationComponent } from \"../FormFields/MembershipOrganization/MembershipOrganizationComponent\";\nimport { MarketConsentWrapperComponent } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMemberPersonalInfoComponentProps {\n verificationService: VerificationService;\n}\n\nconst StepMemberPersonalInfo = ({ verificationService }: StepMemberPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MemberPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MemberPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n const isMemberIdRequired = getFieldConfigByFieldId(\"memberId\")?.requireIfOptional;\n\n const locale = viewModel.localeChoice.value;\n\n const updateMemberViewModel = (key: keyof MemberPersonalInfoViewModel, value: any) => {\n const nextState: MemberPersonalInfoViewModel = produce(\n viewModel,\n (draft: MemberPersonalInfoViewModel) => {\n (draft[key] as any) = value;\n },\n );\n verificationService.updateViewModel(nextState);\n };\n\n React.useEffect(() => {\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (!isMemberIdRequired) {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n } else {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n }\n }, [isMemberIdRequired]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"member-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <MembershipOrganizationComponent\n value={(verificationService.viewModel as MemberPersonalInfoViewModel).organization}\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.organization}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateMemberViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n isRequired={getFieldConfigByFieldId(\"birthDate\")?.requireIfOptional}\n onChange={(newValue) => {\n updateMemberViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={isMemberIdRequired}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n />\n\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMemberViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapperComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMemberViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMemberPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Membership Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMemberPersonalInfoComponent = StepMemberPersonalInfo;\n"],"names":["StepMemberPersonalInfo","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","isMemberIdRequired","getFieldConfigByFieldId","locale","updateMemberViewModel","key","value","nextState","produce","draft","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","MembershipOrganizationComponent","choice","updateViewModelOrganization","updateFieldValidationErrorsByFieldId","FirstName","newValue","LastName","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","BirthDate","MemberId","PhoneNumber","config","FormFieldCustom","MarketConsentWrapperComponent","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMemberPersonalInfoComponent"],"mappings":";;;;;;;;;AAyCA,MAAMA,IAAyB,CAAC,EAAE,qBAAAC,QAAgE;AAChG,QAAMC,IAAYD,EAAoB,WAChC,EAAE,uBAAAE,MAA0BF,GAC5BG,IACJH,EAAoB,sBAChBI,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAUC,EAAA,GACVC,IAAqBC,EAAwB,UAAU,GAAG,mBAE1DC,IAAST,EAAU,aAAa,OAEhCU,IAAwB,CAACC,GAAwCC,MAAe;AACpF,UAAMC,IAAyCC;AAAAA,MAC7Cd;AAAA,MACA,CAACe,MAAuC;AACrC,QAAAA,EAAMJ,CAAG,IAAYC;AAAA,MACxB;AAAA,IAAA;AAEF,IAAAb,EAAoB,gBAAgBc,CAAS;AAAA,EAC/C;AAEA,SAAAG,EAAM,UAAU,MAAM;AACpB,UAAMC,KAAYlB,EAAoB,WAAW,0BAA0B,CAAA,GAAI;AAAA,MAC7E,CAACmB,MAAOA,MAAO;AAAA,IAAA;AAEjB,IAAKX,IAMHR,EAAoB,gBAAgB,EAAE,wBAAwBkB,EAAA,GAAY,EAAE,SAAS,IAAM,IAL3FlB,EAAoB;AAAA,MAClB,EAAE,wBAAwB,CAAC,GAAGkB,GAAU,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AAAA;AAAAA,UAACsB;AAAA,UAAA;AAAA,YACC,qBAAA5C;AAAA,YACA,WAAW,CAAC,CAACE,EAAsB;AAAA,UAAA;AAAA,QAAA;AAAA,QAGrCoB,gBAAAA,EAAAA;AAAAA,UAACuB;AAAA,UAAA;AAAA,YACC,MAAMC,EAAsB;AAAA,YAC5B,qBAAA9C;AAAA,YACA,WAAAC;AAAA,YACA,oBAAAG;AAAA,YACA,YACEkB,gBAAAA,EAAAA;AAAAA,cAACY;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,IAAkChD;"}
|
package/chunk/index-dTu4ORna.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
import { m, j as e, P as u, n as x, o as f, F as o, V as I, a as j, p as E } from "../_mysheerid-preview.js";
|
|
13
13
|
import { E as M, P as h } from "./PersonalInfoStepSubmitButton-v_kWLmEw.js";
|
|
@@ -4,15 +4,15 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
import { m as M, g as t, R as g, j as a, P as I, _ as j, o as n, n as N, F as b, U as E, V as f, p as F, e as y } from "../_mysheerid-preview.js";
|
|
13
|
-
import { F as P, L as V, P as T, a as k, M as D, C as R } from "./CaptchaComponent-
|
|
13
|
+
import { F as P, L as V, P as T, a as k, M as D, C as R } from "./CaptchaComponent-CnWyxiTy.js";
|
|
14
14
|
import { E as q, P as z } from "./PersonalInfoStepSubmitButton-v_kWLmEw.js";
|
|
15
|
-
import { B } from "./militaryStepHelpers-
|
|
15
|
+
import { B } from "./militaryStepHelpers-jW2_4c1l.js";
|
|
16
16
|
import { M as L } from "./MemberIdComponent-oanWSvQh.js";
|
|
17
17
|
import { C as O } from "./ChangeLocaleComponent-Cu2DR-Q3.js";
|
|
18
18
|
import { M as w } from "./MembershipOrganizationComponent-yu-UNXIK.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index-Zi6lCz6u.js","sources":["../../src/components/StepMemberPersonalInfo/StepMemberPersonalInfoComponent.tsx"],"sourcesContent":["import React from \"react\";\nimport { FormattedHTMLMessage } from \"react-intl\";\nimport { produce } from \"immer\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type Organization,\n type MemberPersonalInfoViewModel,\n type MemberPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n getFieldConfigByFieldId,\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { MembershipOrganizationComponent } from \"../FormFields/MembershipOrganization/MembershipOrganizationComponent\";\nimport { MarketConsentWrapperComponent } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMemberPersonalInfoComponentProps {\n verificationService: VerificationService;\n}\n\nconst StepMemberPersonalInfo = ({ verificationService }: StepMemberPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MemberPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MemberPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n const isMemberIdRequired = getFieldConfigByFieldId(\"memberId\")?.requireIfOptional;\n\n const locale = viewModel.localeChoice.value;\n\n const updateMemberViewModel = (key: keyof MemberPersonalInfoViewModel, value: any) => {\n const nextState: MemberPersonalInfoViewModel = produce(\n viewModel,\n (draft: MemberPersonalInfoViewModel) => {\n (draft[key] as any) = value;\n },\n );\n verificationService.updateViewModel(nextState);\n };\n\n React.useEffect(() => {\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (!isMemberIdRequired) {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n } else {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n }\n }, [isMemberIdRequired]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"member-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <MembershipOrganizationComponent\n value={(verificationService.viewModel as MemberPersonalInfoViewModel).organization}\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.organization}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateMemberViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n isRequired={getFieldConfigByFieldId(\"birthDate\")?.requireIfOptional}\n onChange={(newValue) => {\n updateMemberViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={isMemberIdRequired}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n />\n\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMemberViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapperComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMemberViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMemberPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Membership Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMemberPersonalInfoComponent = StepMemberPersonalInfo;\n"],"names":["StepMemberPersonalInfo","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","isMemberIdRequired","getFieldConfigByFieldId","locale","updateMemberViewModel","key","value","nextState","produce","draft","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","MembershipOrganizationComponent","choice","updateViewModelOrganization","updateFieldValidationErrorsByFieldId","FirstName","newValue","LastName","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","BirthDate","MemberId","PhoneNumber","config","FormFieldCustom","MarketConsentWrapperComponent","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMemberPersonalInfoComponent"],"mappings":";;;;;;;;;AAyCA,MAAMA,IAAyB,CAAC,EAAE,qBAAAC,QAAgE;AAChG,QAAMC,IAAYD,EAAoB,WAChC,EAAE,uBAAAE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A,QAAA,IAElD;AAAA,QAEHH,EAAQ,iBAAiB,IAAI,CAACkC,MAC7BlB,gBAAAA,MAACmB,GAAA,EAAgB,QAAAD,GAAgB,qBAAAxC,EAAA,CAA0C,CAC5E;AAAA,QAEDsB,gBAAAA,EAAAA;AAAAA,UAACoB;AAAA,UAAA;AAAA,YACC,qBAAA1C;AAAA,YACA,WAAW,CAAC,CAACE,EAAsB;AAAA,YACnC,UAAU,CAAC6B,MAAa;AACtB,cAAApB,EAAsB,YAAY;AAAA,gBAChC,GAAGX,EAAoB,UAAU;AAAA,gBACjC,oBAAoB+B;AAAA,cAAA,CACrB,GACDF,EAAqC,sBAAsBE,GAAU/B,CAAmB;AAAA,YAC1F;AAAA,YACA,WAAAC;AAAA,YACA,UAAUQ,EAAwB,oBAAoB,GAAG;AAAA,UAAA;AAAA,QAAA;AAAA,QAG3Da,gBAAAA,EAAAA,IAACqB,GAAA,EAAa,qBAAA3C,GAA0C,QAAO,qBAAA,CAAqB;AAAA,QAEpFsB,gBAAAA,EAAAA;AAAAA,UAACsB;AAAA,UAAA;AAAA,YACC,qBAAA5C;AAAA,YACA,WAAW,CAAC,CAACE,EAAsB;AAAA,UAAA;AAAA,QAAA;AAAA,QAGrCoB,gBAAAA,EAAAA;AAAAA,UAACuB;AAAA,UAAA;AAAA,YACC,MAAMC,EAAsB;AAAA,YAC5B,qBAAA9C;AAAA,YACA,WAAAC;AAAA,YACA,oBAAAG;AAAA,YACA,YACEkB,gBAAAA,EAAAA;AAAAA,cAACY;AAAA,cAAA;AAAA,gBACC,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,IAAkChD;"}
|
|
1
|
+
{"version":3,"file":"index-yLck7gVG.js","sources":["../../src/components/StepMemberPersonalInfo/StepMemberPersonalInfoComponent.tsx"],"sourcesContent":["import React from \"react\";\nimport { FormattedHTMLMessage } from \"react-intl\";\nimport { produce } from \"immer\";\n\nimport { VerificationStepsEnum } from \"../../lib/types/runtimeTypes\";\nimport { hasFailedInstantMatch } from \"../../lib/VerificationService/VerificationServiceHelpers\";\nimport {\n type VerificationService,\n type Organization,\n type MemberPersonalInfoViewModel,\n type MemberPersonalInfoResponse,\n type CustomFormFieldConfig,\n} from \"../../lib/types/types\";\nimport {\n getFieldConfigByFieldId,\n handleEmailOnKeyDown,\n updateFieldValidationErrorsByFieldId,\n updateViewModelOrganization,\n} from \"../../lib/utils/stepComponentHelpers/stepComponentHelpers\";\nimport { PhoneNumberComponent as PhoneNumber } from \"../FormFields/PhoneNumber/PhoneNumberComponent\";\nimport { FirstNameComponent as FirstName } from \"../FormFields/FirstName/FirstNameComponent\";\nimport { LastNameComponent as LastName } from \"../FormFields/LastName/LastNameComponent\";\nimport { EmailComponent as Email } from \"../FormFields/Email/EmailComponent\";\nimport { BirthDateComponent as BirthDate } from \"../FormFields/BirthDate/BirthDateComponent\";\nimport { MemberIdComponent as MemberId } from \"../FormFields/MemberId/MemberIdComponent\";\nimport { ChangeLocaleV2Component } from \"../FormFields/ChangeLocale/ChangeLocaleComponent\";\nimport { MembershipOrganizationComponent } from \"../FormFields/MembershipOrganization/MembershipOrganizationComponent\";\nimport { MarketConsentWrapperComponent } from \"../FormFields/MarketConsentWrapper/MarketConsentWrapperComponent\";\nimport { CountryComponentWrapper } from \"../FormFields/Country/CountryComponentWrapper\";\nimport { getOptions } from \"../../options/options\";\nimport { FormFieldCustom } from \"../FormFields/FormFieldCustom/FormFieldCustom\";\nimport { ExtraMessage } from \"../ExtraMessage\";\nimport { PersonalInfoWrapper } from \"../PersonalInfoStepWrapper/PersonalInfoStepWrapper\";\nimport { PersonalInfoStepSubmitButton } from \"../PersonalInfoStepSubmitButton/PersonalInfoStepSubmitButton\";\nimport { PersonalInfoHeader } from \"../FormHeader/StepHeaders/PersonalInfoHeaderComponent\";\nimport { CaptchaComponent } from \"../FormFields/Captcha/CaptchaComponent\";\n\ninterface StepMemberPersonalInfoComponentProps {\n verificationService: VerificationService;\n}\n\nconst StepMemberPersonalInfo = ({ verificationService }: StepMemberPersonalInfoComponentProps) => {\n const viewModel = verificationService.viewModel as MemberPersonalInfoViewModel;\n const { fieldValidationErrors } = verificationService;\n const verificationResponse =\n verificationService.verificationResponse as MemberPersonalInfoResponse;\n const failedInstantMatch = hasFailedInstantMatch(verificationResponse);\n const options = getOptions();\n const isMemberIdRequired = getFieldConfigByFieldId(\"memberId\")?.requireIfOptional;\n\n const locale = viewModel.localeChoice.value;\n\n const updateMemberViewModel = (key: keyof MemberPersonalInfoViewModel, value: any) => {\n const nextState: MemberPersonalInfoViewModel = produce(\n viewModel,\n (draft: MemberPersonalInfoViewModel) => {\n (draft[key] as any) = value;\n },\n );\n verificationService.updateViewModel(nextState);\n };\n\n React.useEffect(() => {\n const existing = (verificationService.viewModel?.fieldsToSkipValidation || []).filter(\n (id) => id !== \"memberId\",\n );\n if (!isMemberIdRequired) {\n verificationService.updateViewModel(\n { fieldsToSkipValidation: [...existing, \"memberId\"] },\n { partial: true },\n );\n } else {\n verificationService.updateViewModel({ fieldsToSkipValidation: existing }, { partial: true });\n }\n }, [isMemberIdRequired]);\n\n return (\n <PersonalInfoWrapper\n verificationService={verificationService}\n step={verificationResponse.currentStep}\n >\n <PersonalInfoHeader\n verificationService={verificationService}\n classNameIdentifier=\"member-personal-info\"\n />\n\n <ChangeLocaleV2Component verificationService={verificationService} />\n <CountryComponentWrapper\n verificationService={verificationService}\n disabled={getFieldConfigByFieldId(\"country\")?.disabled}\n />\n\n <MembershipOrganizationComponent\n value={(verificationService.viewModel as MemberPersonalInfoViewModel).organization}\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.organization}\n disabled={getFieldConfigByFieldId(\"organization\")?.disabled}\n onChange={(choice: Organization) => {\n updateViewModelOrganization(choice, verificationService);\n updateFieldValidationErrorsByFieldId(\"organization\", choice, verificationService);\n }}\n />\n\n <div className=\"sid-names\">\n <FirstName\n value={viewModel.firstName}\n isErrored={!!fieldValidationErrors.firstName}\n disabled={getFieldConfigByFieldId(\"firstName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"firstName\", newValue);\n updateFieldValidationErrorsByFieldId(\"firstName\", newValue, verificationService);\n }}\n />\n\n <LastName\n value={viewModel.lastName}\n isErrored={!!fieldValidationErrors.lastName}\n disabled={getFieldConfigByFieldId(\"lastName\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"lastName\", newValue);\n updateFieldValidationErrorsByFieldId(\"lastName\", newValue, verificationService);\n }}\n />\n </div>\n\n <Email\n value={viewModel.email}\n isErrored={!!fieldValidationErrors.email}\n explanation={<FormattedHTMLMessage id=\"emailExplanation\" defaultMessage=\" \" />}\n onChange={(newValue) => {\n updateMemberViewModel(\"email\", newValue);\n updateFieldValidationErrorsByFieldId(\"email\", newValue, verificationService);\n }}\n onKeyDown={(event) => handleEmailOnKeyDown(event)}\n disabled={getFieldConfigByFieldId(\"email\")?.disabled}\n />\n\n <BirthDate\n errorId={fieldValidationErrors.birthDate}\n locale={locale}\n isRequired={getFieldConfigByFieldId(\"birthDate\")?.requireIfOptional}\n onChange={(newValue) => {\n updateMemberViewModel(\"birthDate\", newValue);\n updateFieldValidationErrorsByFieldId(\"birthDate\", newValue, verificationService);\n }}\n value={viewModel.birthDate}\n disabled={getFieldConfigByFieldId(\"birthDate\")?.disabled}\n />\n\n <MemberId\n value={viewModel.memberId}\n isErrored={!!fieldValidationErrors.memberId}\n isRequired={isMemberIdRequired}\n disabled={getFieldConfigByFieldId(\"memberId\")?.disabled}\n onChange={(newValue) => {\n updateMemberViewModel(\"memberId\", newValue);\n updateFieldValidationErrorsByFieldId(\"memberId\", newValue, verificationService);\n }}\n />\n\n {verificationService.programTheme.isSmsNotifierConfigured ||\n verificationService.programTheme.smsLoopEnabled ? (\n <PhoneNumber\n isRequired={!!verificationService.programTheme.smsLoopEnabled}\n value={viewModel.phoneNumber}\n isErrored={!!fieldValidationErrors.phoneNumber}\n onChange={(newValue) => {\n updateMemberViewModel(\"phoneNumber\", newValue);\n updateFieldValidationErrorsByFieldId(\"phoneNumber\", newValue, verificationService);\n }}\n selectedCountryCode={viewModel.countryChoice && viewModel.countryChoice.value}\n disabled={getFieldConfigByFieldId(\"phoneNumber\")?.disabled}\n />\n ) : null}\n\n {options.customFormFields.map((config: CustomFormFieldConfig) => (\n <FormFieldCustom config={config} verificationService={verificationService} />\n ))}\n\n <MarketConsentWrapperComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.marketConsentValue}\n onChange={(newValue) => {\n updateMemberViewModel(\"metadata\", {\n ...verificationService.viewModel.metadata,\n marketConsentValue: newValue,\n });\n updateFieldValidationErrorsByFieldId(\"marketConsentValue\", newValue, verificationService);\n }}\n viewModel={viewModel}\n disabled={getFieldConfigByFieldId(\"marketConsentValue\")?.disabled}\n />\n\n <ExtraMessage verificationService={verificationService} suffix=\"CollectAboveSubmit\" />\n\n <CaptchaComponent\n verificationService={verificationService}\n isErrored={!!fieldValidationErrors.captchaToken}\n />\n\n <PersonalInfoStepSubmitButton\n step={VerificationStepsEnum.collectMemberPersonalInfo}\n verificationService={verificationService}\n viewModel={viewModel}\n failedInstantMatch={failedInstantMatch}\n buttonText={\n <FormattedHTMLMessage\n id=\"step.personalInfo.submitButtonText\"\n defaultMessage=\"Verify My Membership Status\"\n />\n }\n />\n </PersonalInfoWrapper>\n );\n};\n\nexport const StepMemberPersonalInfoComponent = StepMemberPersonalInfo;\n"],"names":["StepMemberPersonalInfo","verificationService","viewModel","fieldValidationErrors","verificationResponse","failedInstantMatch","hasFailedInstantMatch","options","getOptions","isMemberIdRequired","getFieldConfigByFieldId","locale","updateMemberViewModel","key","value","nextState","produce","draft","React","existing","id","jsxs","PersonalInfoWrapper","jsx","PersonalInfoHeader","ChangeLocaleV2Component","CountryComponentWrapper","MembershipOrganizationComponent","choice","updateViewModelOrganization","updateFieldValidationErrorsByFieldId","FirstName","newValue","LastName","Email","FormattedHTMLMessage","event","handleEmailOnKeyDown","BirthDate","MemberId","PhoneNumber","config","FormFieldCustom","MarketConsentWrapperComponent","ExtraMessage","CaptchaComponent","PersonalInfoStepSubmitButton","VerificationStepsEnum","StepMemberPersonalInfoComponent"],"mappings":";;;;;;;;;AAyCA,MAAMA,IAAyB,CAAC,EAAE,qBAAAC,QAAgE;AAChG,QAAMC,IAAYD,EAAoB,WAChC,EAAE,uBAAAE,MAA0BF,GAC5BG,IACJH,EAAoB,sBAChBI,IAAqBC,EAAsBF,CAAoB,GAC/DG,IAAUC,EAAA,GACVC,IAAqBC,EAAwB,UAAU,GAAG,mBAE1DC,IAAST,EAAU,aAAa,OAEhCU,IAAwB,CAACC,GAAwCC,MAAe;AACpF,UAAMC,IAAyCC;AAAAA,MAC7Cd;AAAA,MACA,CAACe,MAAuC;AACrC,QAAAA,EAAMJ,CAAG,IAAYC;AAAA,MACxB;AAAA,IAAA;AAEF,IAAAb,EAAoB,gBAAgBc,CAAS;AAAA,EAC/C;AAEA,SAAAG,EAAM,UAAU,MAAM;AACpB,UAAMC,KAAYlB,EAAoB,WAAW,0BAA0B,CAAA,GAAI;AAAA,MAC7E,CAACmB,MAAOA,MAAO;AAAA,IAAA;AAEjB,IAAKX,IAMHR,EAAoB,gBAAgB,EAAE,wBAAwBkB,EAAA,GAAY,EAAE,SAAS,IAAM,IAL3FlB,EAAoB;AAAA,MAClB,EAAE,wBAAwB,CAAC,GAAGkB,GAAU,UAAU,EAAA;AAAA,MAClD,EAAE,SAAS,GAAA;AAAA,IAAK;AAAA,EAKtB,GAAG,CAACV,CAAkB,CAAC,GAGrBY,gBAAAA,EAAAA;AAAAA,IAACC;AAAA,IAAA;AAAA,MACC,qBAAArB;AAAA,MACA,MAAMG,EAAqB;AAAA,MAE3B,UAAA;AAAA,QAAAmB,gBAAAA,EAAAA;AAAAA,UAACC;AAAA,UAAA;AAAA,YACC,qBAAAvB;AAAA,YACA,qBAAoB;AAAA,UAAA;AAAA,QAAA;A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,IAAG;AAAA,gBACH,gBAAe;AAAA,cAAA;AAAA,YAAA;AAAA,UACjB;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAAA;AAGN,GAEaa,IAAkChD;"}
|
package/chunk/is-B3D8NTKa.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "Virk herskylda",
|
package/chunk/it-CzAy2lzA.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "Servizio Attivo",
|
package/chunk/iw-C9nimuXe.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "שירות פעיל",
|
package/chunk/ja-BEXgm7zu.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "現役軍人",
|
package/chunk/ko-Ct-zPR2E.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "현역 군인",
|
package/chunk/lo-Di9C_kLP.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "ໜ້າທີ່",
|
package/chunk/lt-CEBQxuWT.js
CHANGED
|
@@ -4,10 +4,10 @@
|
|
|
4
4
|
* This file is not intended for use in other contexts and there are no guarantees about its behavior outside of MySheerID.
|
|
5
5
|
*/
|
|
6
6
|
/**
|
|
7
|
-
* VERSION: 2.
|
|
8
|
-
* BUILD_TIMESTAMP:
|
|
9
|
-
* BUILD_DATE:
|
|
10
|
-
* BUILD_COMMIT:
|
|
7
|
+
* VERSION: 2.231.0
|
|
8
|
+
* BUILD_TIMESTAMP: 1778866828678
|
|
9
|
+
* BUILD_DATE: Fri May 15 2026 17:40:28 GMT+0000 (Coordinated Universal Time)
|
|
10
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
11
11
|
*/
|
|
12
12
|
const e = {
|
|
13
13
|
"defaultMessages.ACTIVE_DUTY": "Aktyvus pareigūnas",
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
|
|
2
2
|
/**
|
|
3
|
-
* VERSION: 2.
|
|
4
|
-
* BUILD_TIMESTAMP:
|
|
5
|
-
* BUILD_DATE:
|
|
6
|
-
* BUILD_COMMIT:
|
|
3
|
+
* VERSION: 2.231.0
|
|
4
|
+
* BUILD_TIMESTAMP: 1778866812284
|
|
5
|
+
* BUILD_DATE: Fri May 15 2026 17:40:12 GMT+0000 (Coordinated Universal Time)
|
|
6
|
+
* BUILD_COMMIT: e2c23e54ba6fc3b35cb24b5b0cb59bd07dbdc3a1
|
|
7
7
|
*/
|
|
8
8
|
import { g as u, j as a, H as f, F as l, p as m } from "../sheerid.js";
|
|
9
|
-
import { D as g } from "./CaptchaComponent-
|
|
9
|
+
import { D as g } from "./CaptchaComponent-SmUa6m52.js";
|
|
10
10
|
const c = ({
|
|
11
11
|
onChange: t,
|
|
12
12
|
isRequired: s = !0,
|