@sheerid/jslib 1.104.0 → 1.107.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/README.md +104 -0
- package/__tests__/__helpers__/renderers.d.ts +7 -0
- package/es5/Tmetrix.bundle.js +5 -5
- package/es5/messages_ar.bundle.js +5 -5
- package/es5/messages_bg.bundle.js +5 -5
- package/es5/messages_cs.bundle.js +5 -5
- package/es5/messages_da.bundle.js +5 -5
- package/es5/messages_de.bundle.js +5 -5
- package/es5/messages_el.bundle.js +5 -5
- package/es5/messages_en-GB.bundle.js +5 -5
- package/es5/messages_es-ES.bundle.js +5 -5
- package/es5/messages_es.bundle.js +5 -5
- package/es5/messages_fi.bundle.js +5 -5
- package/es5/messages_fr-CA.bundle.js +5 -5
- package/es5/messages_fr.bundle.js +5 -5
- package/es5/messages_ga.bundle.js +5 -5
- package/es5/messages_hr.bundle.js +5 -5
- package/es5/messages_hu.bundle.js +5 -5
- package/es5/messages_id.bundle.js +5 -5
- package/es5/messages_it.bundle.js +5 -5
- package/es5/messages_iw.bundle.js +5 -5
- package/es5/messages_ja.bundle.js +5 -5
- package/es5/messages_ko.bundle.js +5 -5
- package/es5/messages_lo.bundle.js +5 -5
- package/es5/messages_lt.bundle.js +5 -5
- package/es5/messages_ms.bundle.js +5 -5
- package/es5/messages_nl.bundle.js +5 -5
- package/es5/messages_no.bundle.js +5 -5
- package/es5/messages_pl.bundle.js +5 -5
- package/es5/messages_pt-BR.bundle.js +5 -5
- package/es5/messages_pt.bundle.js +5 -5
- package/es5/messages_ru.bundle.js +5 -5
- package/es5/messages_sk.bundle.js +5 -5
- package/es5/messages_sl.bundle.js +5 -5
- package/es5/messages_sr.bundle.js +5 -5
- package/es5/messages_sv.bundle.js +5 -5
- package/es5/messages_th.bundle.js +5 -5
- package/es5/messages_tr.bundle.js +5 -5
- package/es5/messages_zh-HK.bundle.js +5 -5
- package/es5/messages_zh.bundle.js +5 -5
- package/es6/{en-GB-5eb8e845.es.js → en-GB-52e5c64c.es.js} +3 -3
- package/es6/{en-GB-5eb8e845.es.js.map → en-GB-52e5c64c.es.js.map} +1 -1
- package/localized-messages/en-GB.json +2 -2
- package/localized-messages/en-US.json +2 -2
- package/manifest.json +46 -46
- package/package.json +1 -1
- package/sheerid-requestOrg.css +4 -4
- package/sheerid-requestOrg.js +15 -15
- package/sheerid-requestOrg.js.map +1 -1
- package/sheerid-utils.js +9 -9
- package/sheerid-utils.js.map +1 -1
- package/sheerid.css +4 -4
- package/sheerid.js +18 -18
- package/sheerid.js.map +1 -1
- package/sheerides6.js +211 -128
- package/sheerides6.js.map +1 -1
- package/src/components/FieldLabel.d.ts +2 -2
- package/src/components/FormFields/Address/AddressComponent.d.ts +3 -7
- package/src/components/FormFields/BirthDate/BirthDateComponent.d.ts +1 -1
- package/src/components/FormFields/BranchOfService/BranchOfServiceComponent.d.ts +1 -1
- package/src/components/FormFields/ChangeLocale/ChangeLocaleComponent.d.ts +1 -1
- package/src/components/FormFields/City/City.d.ts +2 -2
- package/src/components/FormFields/CollegeName/CollegeNameComponent.d.ts +1 -1
- package/src/components/FormFields/Company/CompanyComponent.d.ts +1 -1
- package/src/components/FormFields/Country/CountryComponent.d.ts +1 -1
- package/src/components/FormFields/DischargeDate/DischargeDateComponent.d.ts +1 -1
- package/src/components/FormFields/DriverLicenseNumber/DriverLicenseNumberComponent.d.ts +1 -1
- package/src/components/FormFields/Email/EmailComponent.d.ts +1 -1
- package/src/components/FormFields/FirstName/FirstNameComponent.d.ts +1 -1
- package/src/components/FormFields/FirstResponderOrganization/FirstResponderOrganizationComponent.d.ts +1 -1
- package/src/components/FormFields/FirstResponderStatus/FirstResponderStatusComponent.d.ts +1 -1
- package/src/components/FormFields/FormFieldCustom/FormFieldCustom.d.ts +18 -0
- package/src/components/FormFields/FormFieldCustom/FormFieldCustom.test.d.ts +1 -0
- package/src/components/FormFields/FormFieldLayout/FormFieldLayout.d.ts +14 -0
- package/src/components/FormFields/FormFieldText/FormFieldText.d.ts +17 -0
- package/src/components/FormFields/FormFieldText/FormFieldText.test.d.ts +1 -0
- package/src/components/FormFields/LastName/LastNameComponent.d.ts +1 -1
- package/src/components/FormFields/LicensedProfessionalOrganization/LicensedProfessionalOrganizationComponent.d.ts +1 -1
- package/src/components/FormFields/LowIncomeOrganization/LowIncomeOrganizationComponent.d.ts +1 -1
- package/src/components/FormFields/MedicalProfessionalOrganization/MedicalProfessionalOrganizationComponent.d.ts +1 -1
- package/src/components/FormFields/MedicalStatus/MedicalStatusComponent.d.ts +1 -1
- package/src/components/FormFields/MemberId/MemberIdComponent.d.ts +1 -1
- package/src/components/FormFields/MembershipOrganization/MembershipOrganizationComponent.d.ts +1 -1
- package/src/components/FormFields/MilitaryStatus/MilitaryStatusComponent.d.ts +1 -1
- package/src/components/FormFields/PhoneNumber/PhoneNumberComponent.d.ts +1 -1
- package/src/components/FormFields/SMSCode/SMSCodeComponent.d.ts +1 -1
- package/src/components/FormFields/SSN/SSN.d.ts +8 -3
- package/src/components/FormFields/State/State.d.ts +1 -1
- package/src/components/FormFields/State/StateSelectComponent.d.ts +1 -1
- package/src/components/FormFields/Status/StatusComponent.d.ts +1 -1
- package/src/components/FormFields/TeacherSchool/TeacherSchoolComponent.d.ts +1 -1
- package/src/components/FormInputs/InputText/InputText.d.ts +3 -19
- package/src/components/StepMemberPersonalInfo/StepMemberPersonalInfoComponent.d.ts +0 -1
- package/src/components/StepMilitaryPersonalInfo/StepCollectMilitaryStatusComponent.d.ts +1 -1
- package/src/components/StepPending/ReviewPendingComponent.d.ts +1 -1
- package/src/es6.d.ts +3 -0
- package/src/lib/VerificationService/VerificationServiceActions.d.ts +5 -0
- package/src/lib/VerificationService/VerificationServiceHelpers.d.ts +1 -1
- package/src/lib/installScript/modal.d.ts +3 -3
- package/src/lib/types/types.d.ts +13 -1
- package/src/lib/utils/strings.d.ts +1 -0
- package/src/lib/utils/strings.test.d.ts +1 -0
- package/types-reference.zip +0 -0
package/sheerides6.js
CHANGED
|
@@ -1190,6 +1190,7 @@ const defaultOptions = {
|
|
|
1190
1190
|
httpRequestTimeout: HTTP_REQUEST_TIMEOUT,
|
|
1191
1191
|
hideTestModeFlag: false,
|
|
1192
1192
|
hideMilitaryFamilyAcceptableUploads: true,
|
|
1193
|
+
customFormFields: [],
|
|
1193
1194
|
};
|
|
1194
1195
|
let options$1 = { ...defaultOptions };
|
|
1195
1196
|
const getOptions = () => options$1;
|
|
@@ -1358,6 +1359,10 @@ const setOptions = (newOptions) => {
|
|
|
1358
1359
|
options$1.hideMilitaryFamilyAcceptableUploads = newOptions.hideMilitaryFamilyAcceptableUploads;
|
|
1359
1360
|
logger.info('option "hideMilitaryFamilyAcceptableUploads" set to', options$1.hideMilitaryFamilyAcceptableUploads);
|
|
1360
1361
|
}
|
|
1362
|
+
if (newOptions.hasOwnProperty("customFormFields")) {
|
|
1363
|
+
options$1.customFormFields = newOptions.customFormFields;
|
|
1364
|
+
logger.info('option "customFormFields" set to', options$1.customFormFields);
|
|
1365
|
+
}
|
|
1361
1366
|
};
|
|
1362
1367
|
|
|
1363
1368
|
class ResponseTimeLogger {
|
|
@@ -2624,7 +2629,7 @@ var enUSMessages = {
|
|
|
2624
2629
|
"segmentMessages.lowIncome.step.success.subtitle": "Here is your personal coupon code. It is unique to you and can only be used once.",
|
|
2625
2630
|
"segmentMessages.lowIncome.step.success.title": "You've been verified",
|
|
2626
2631
|
"segmentMessages.medical.emailExplanation": "Use your work email if you have one",
|
|
2627
|
-
"segmentMessages.medical.step.docUpload.howDoesVerifyingWorkDetails": "Document review is handled by SheerID, a trusted partner who specializes in verifying\n medical professionals.<br><br>Documents are used only for verifying your medical professional status is\n current and will be permanently deleted after review is finalized. They will not be shared with {companyName}
|
|
2632
|
+
"segmentMessages.medical.step.docUpload.howDoesVerifyingWorkDetails": "Document review is handled by SheerID, a trusted partner who specializes in verifying\n medical professionals.<br><br>Documents are used only for verifying your medical professional status is\n current and will be permanently deleted after review is finalized. They will not be shared with {companyName}",
|
|
2628
2633
|
"segmentMessages.medical.step.docUpload.subtitle": "Documents will be reviewed in {estimatedWaitTime} by staff at SheerID, a trusted partner.",
|
|
2629
2634
|
"segmentMessages.medical.step.docUpload.title": "We need more information",
|
|
2630
2635
|
"segmentMessages.medical.step.docUpload.uploadInstructions": "Upload an official document that shows",
|
|
@@ -2669,7 +2674,7 @@ var enUSMessages = {
|
|
|
2669
2674
|
"segmentMessages.military.step.success.subtitle": "Here is your personal coupon code. It is unique to you and can only be used once.",
|
|
2670
2675
|
"segmentMessages.military.step.success.title": "You've been verified",
|
|
2671
2676
|
"segmentMessages.recentMover.emailExplanation": "Needed to send you your unique code",
|
|
2672
|
-
"segmentMessages.recentMover.step.docUpload.howDoesVerifyingWorkDetails": "Document review is handled by SheerID, a trusted partner who specializes in verifying recent movers.\n <br/><br/>\n Documents are used only for verifying that you've recently moved and will will be permanently deleted after review is finalized. They will not be shared with {companyName}
|
|
2677
|
+
"segmentMessages.recentMover.step.docUpload.howDoesVerifyingWorkDetails": "Document review is handled by SheerID, a trusted partner who specializes in verifying recent movers.\n <br/><br/>\n Documents are used only for verifying that you've recently moved and will will be permanently deleted after review is finalized. They will not be shared with {companyName}",
|
|
2673
2678
|
"segmentMessages.recentMover.step.docUpload.subtitle": "Documents will be reviewed in {estimatedWaitTime} by staff at SheerID, a trusted partner.",
|
|
2674
2679
|
"segmentMessages.recentMover.step.docUpload.title": "We need some more info",
|
|
2675
2680
|
"segmentMessages.recentMover.step.docUpload.uploadInstructions": "Upload an official document that shows",
|
|
@@ -2774,7 +2779,7 @@ const getMessagesModuleByLocale = async (locale) => {
|
|
|
2774
2779
|
break;
|
|
2775
2780
|
case "en-GB":
|
|
2776
2781
|
localizedMessages = await import(
|
|
2777
|
-
/* webpackChunkName: "messages_en-GB" */ './es6/en-GB-
|
|
2782
|
+
/* webpackChunkName: "messages_en-GB" */ './es6/en-GB-52e5c64c.es.js').then((m) => m.default);
|
|
2778
2783
|
break;
|
|
2779
2784
|
case "en-US":
|
|
2780
2785
|
localizedMessages = enUSMessages;
|
|
@@ -4217,6 +4222,24 @@ const getFieldValidationErrors = (viewModel, formValidationOptions) => {
|
|
|
4217
4222
|
fieldValidationErrors[fieldId] = validateFieldById(fieldId, fieldValue, formValidationOptions);
|
|
4218
4223
|
}
|
|
4219
4224
|
}
|
|
4225
|
+
const { customFormFields } = getOptions();
|
|
4226
|
+
if (customFormFields) {
|
|
4227
|
+
customFormFields.forEach((customField) => {
|
|
4228
|
+
let errorId;
|
|
4229
|
+
try {
|
|
4230
|
+
errorId = customField.validate(viewModel.metadata[customField.fieldId]);
|
|
4231
|
+
}
|
|
4232
|
+
catch (e) {
|
|
4233
|
+
logger.warn(`Error validating custom field ${customField.fieldId}`, e);
|
|
4234
|
+
}
|
|
4235
|
+
if (errorId) {
|
|
4236
|
+
fieldValidationErrors[customField.fieldId] = errorId;
|
|
4237
|
+
}
|
|
4238
|
+
else {
|
|
4239
|
+
delete fieldValidationErrors[customField.fieldId];
|
|
4240
|
+
}
|
|
4241
|
+
});
|
|
4242
|
+
}
|
|
4220
4243
|
return fieldValidationErrors;
|
|
4221
4244
|
};
|
|
4222
4245
|
const isFormFilled = (viewModel, formValidationOptions) => {
|
|
@@ -4959,18 +4982,7 @@ const produceDraftViewModel = (previousModel, key, value) => fn(previousModel, (
|
|
|
4959
4982
|
draft[key] = value;
|
|
4960
4983
|
});
|
|
4961
4984
|
|
|
4962
|
-
const
|
|
4963
|
-
React.createElement("div", { id: id, className: `sid-field__label sid-l-space-btm-sm ${displayClasses}` },
|
|
4964
|
-
React.createElement("span", { className: "sid-field__label-name", "aria-hidden": "true" },
|
|
4965
|
-
text,
|
|
4966
|
-
isRequired && (React.createElement("span", { "aria-hidden": "true", className: "sid-field__label--required" }, "*"))),
|
|
4967
|
-
children && React.createElement("div", { className: "sid-field__label-explanation" }, children))));
|
|
4968
|
-
FieldLabel.defaultProps = {
|
|
4969
|
-
id: "",
|
|
4970
|
-
displayClasses: "",
|
|
4971
|
-
isRequired: true,
|
|
4972
|
-
children: null,
|
|
4973
|
-
};
|
|
4985
|
+
const dashed = (camel) => camel.replace(/[A-Z]/g, (m) => `-${m.toLowerCase()}`);
|
|
4974
4986
|
|
|
4975
4987
|
const InputText = ({ id, isErrored, className = undefined, hidePlaceholder = true, refId, required = false, type = "text", ariaDescribedBy, ariaLabel, ...props // forward any remaining props to the input
|
|
4976
4988
|
}) => {
|
|
@@ -4987,25 +4999,53 @@ const InputText = ({ id, isErrored, className = undefined, hidePlaceholder = tru
|
|
|
4987
4999
|
const finalRefId = refId || id;
|
|
4988
5000
|
return (React.createElement("input", Object.assign({ className: internalClassName, id: `sid-${id}`, name: `sid-${id}`, type: type, "aria-describedby": ariaDescribedBy, "aria-label": ariaLabel, "aria-required": required, "aria-invalid": isErrored, ref: (input) => setRef(finalRefId, input) }, props)));
|
|
4989
5001
|
};
|
|
4990
|
-
//
|
|
4991
|
-
const InputTextComponent =
|
|
5002
|
+
// DO NOT INJECT INTL. Localize your strings pass them down as props
|
|
5003
|
+
const InputTextComponent = InputText;
|
|
4992
5004
|
|
|
4993
|
-
const
|
|
4994
|
-
React.createElement("div", { className:
|
|
4995
|
-
|
|
4996
|
-
|
|
4997
|
-
|
|
4998
|
-
|
|
4999
|
-
|
|
5005
|
+
const FieldLabel = ({ text, htmlForLabel, id, displayClasses, isRequired, children, }) => (React.createElement("label", { htmlFor: htmlForLabel },
|
|
5006
|
+
React.createElement("div", { id: id, className: `sid-field__label sid-l-space-btm-sm ${displayClasses}` },
|
|
5007
|
+
React.createElement("span", { className: "sid-field__label-name", "aria-hidden": "true" },
|
|
5008
|
+
text,
|
|
5009
|
+
isRequired && (React.createElement("span", { "aria-hidden": "true", className: "sid-field__label--required" }, "*"))),
|
|
5010
|
+
children && React.createElement("div", { className: "sid-field__label-explanation" }, children))));
|
|
5011
|
+
FieldLabel.defaultProps = {
|
|
5012
|
+
id: "",
|
|
5013
|
+
displayClasses: "",
|
|
5014
|
+
isRequired: true,
|
|
5015
|
+
children: null,
|
|
5016
|
+
};
|
|
5017
|
+
|
|
5018
|
+
/**
|
|
5019
|
+
* In the JSLIB, a FormField has a label, inline error message, and children like a text input
|
|
5020
|
+
* This component provides consistent structure, classnames and some accessibility considerations for all FormFields
|
|
5021
|
+
*/
|
|
5022
|
+
const FormFieldLayout = ({ fieldId, label, errorMessage, isRequired, showPlaceholderAndHideLabel = false, children, }) => {
|
|
5023
|
+
const labelIntlId = `${fieldId}Label`;
|
|
5024
|
+
const labelHtmlId = `sid-${dashed(labelIntlId)}`;
|
|
5025
|
+
return (React.createElement("div", { className: `sid-field sid-${dashed(fieldId)}` },
|
|
5026
|
+
React.createElement("div", { className: "sid-l-space-top-md" }),
|
|
5027
|
+
React.createElement(FieldLabel, { text: label, isRequired: isRequired, htmlForLabel: `sid-${dashed(fieldId)}`, id: labelHtmlId, displayClasses: showPlaceholderAndHideLabel ? "sid-h-screen-reader-only" : "" }),
|
|
5028
|
+
children,
|
|
5029
|
+
errorMessage && React.createElement("div", { className: "sid-field-error" }, errorMessage)));
|
|
5030
|
+
};
|
|
5031
|
+
|
|
5032
|
+
/**
|
|
5033
|
+
* Generic text field component.
|
|
5034
|
+
* In the JSLIB, a field has a label, inline error message, and an input of some kind.
|
|
5035
|
+
*/
|
|
5036
|
+
const FormFieldText = ({ fieldId, value, onChange, placeholder, label, errorMessage, showPlaceholderAndHideLabel = false, required = true, ...inputTextProps }) => {
|
|
5037
|
+
const labelIntlId = `${fieldId}Label`;
|
|
5038
|
+
const labelHtmlId = `sid-${dashed(labelIntlId)}`;
|
|
5039
|
+
return (React.createElement(FormFieldLayout, { fieldId: fieldId, label: label, errorMessage: errorMessage, showPlaceholderAndHideLabel: showPlaceholderAndHideLabel, isRequired: required },
|
|
5040
|
+
React.createElement(InputTextComponent, Object.assign({ id: dashed(fieldId), value: value, onChange: (e) => onChange(e.target.value), placeholder: placeholder, hidePlaceholder: !showPlaceholderAndHideLabel, "aria-labelledby": labelHtmlId, refId: fieldId, isErrored: !!errorMessage, required: required }, inputTextProps))));
|
|
5041
|
+
};
|
|
5042
|
+
|
|
5043
|
+
const FirstName = ({ value, isErrored, onChange, intl, placeholder = "", }) => (React.createElement(FormFieldText, { fieldId: "firstName", value: value, onChange: onChange, placeholder: placeholder ||
|
|
5044
|
+
intl.formatHTMLMessage({ id: "firstNamePlaceholder", defaultMessage: "First Name" }), label: React.createElement(FormattedHTMLMessage, { id: "firstName", defaultMessage: "First name" }), errorMessage: isErrored && (React.createElement(FormattedHTMLMessage, { id: "errorId.invalidFirstName", defaultMessage: "Invalid first name" })), showPlaceholderAndHideLabel: !!placeholder }));
|
|
5000
5045
|
const FirstNameComponent = injectIntl(FirstName);
|
|
5001
5046
|
|
|
5002
|
-
const LastName = ({ value, isErrored, onChange, intl, placeholder = "", }) => (React.createElement(
|
|
5003
|
-
|
|
5004
|
-
React.createElement(FieldLabel, { text: React.createElement(FormattedHTMLMessage, { id: "lastName", defaultMessage: "Last name" }), htmlForLabel: "sid-last-name", id: "sid-last-name-label", displayClasses: placeholder && "sid-h-screen-reader-only" }),
|
|
5005
|
-
React.createElement(InputTextComponent, { id: "last-name", isErrored: isErrored, onChange: (event) => onChange(event.target.value), placeholder: placeholder ||
|
|
5006
|
-
intl.formatHTMLMessage({ id: "lastNamePlaceholder", defaultMessage: "Last Name" }), refId: "lastName", value: value, required: true, "aria-labelledby": "sid-last-name-label" }),
|
|
5007
|
-
isErrored ? (React.createElement("div", { className: "sid-field-error" },
|
|
5008
|
-
React.createElement(FormattedHTMLMessage, { id: "errorId.invalidLastName", defaultMessage: "Invalid last name" }))) : null));
|
|
5047
|
+
const LastName = ({ value, isErrored, onChange, intl, placeholder = "", }) => (React.createElement(FormFieldText, { fieldId: "lastName", value: value, onChange: onChange, placeholder: placeholder ||
|
|
5048
|
+
intl.formatHTMLMessage({ id: "lastNamePlaceholder", defaultMessage: "Last Name" }), label: React.createElement(FormattedHTMLMessage, { id: "lastName", defaultMessage: "Last name" }), errorMessage: isErrored && (React.createElement(FormattedHTMLMessage, { id: "errorId.invalidLastName", defaultMessage: "Invalid last name" })), showPlaceholderAndHideLabel: !!placeholder }));
|
|
5009
5049
|
const LastNameComponent = injectIntl(LastName);
|
|
5010
5050
|
|
|
5011
5051
|
const Email = ({ value, isErrored, onChange, explanation, intl, onKeyDown = undefined, placeholder = "", }) => (React.createElement("div", { className: "sid-field sid-email" },
|
|
@@ -10296,7 +10336,7 @@ const medicalMessages = {
|
|
|
10296
10336
|
subtitle: "Documents will be reviewed in {estimatedWaitTime} by staff at SheerID, a trusted partner.",
|
|
10297
10337
|
howDoesVerifyingWorkDetails: `Document review is handled by SheerID, a trusted partner who specializes in verifying
|
|
10298
10338
|
medical professionals.<br><br>Documents are used only for verifying your medical professional status is
|
|
10299
|
-
current and will be permanently deleted after review is finalized. They will not be shared with {companyName}
|
|
10339
|
+
current and will be permanently deleted after review is finalized. They will not be shared with {companyName}`,
|
|
10300
10340
|
uploadInstructions: "Upload an official document that shows",
|
|
10301
10341
|
},
|
|
10302
10342
|
sso: {
|
|
@@ -10439,7 +10479,7 @@ const moverMessages = {
|
|
|
10439
10479
|
subtitle: "Documents will be reviewed in {estimatedWaitTime} by staff at SheerID, a trusted partner.",
|
|
10440
10480
|
howDoesVerifyingWorkDetails: `Document review is handled by SheerID, a trusted partner who specializes in verifying recent movers.
|
|
10441
10481
|
<br/><br/>
|
|
10442
|
-
Documents are used only for verifying that you've recently moved and will will be permanently deleted after review is finalized. They will not be shared with {companyName}
|
|
10482
|
+
Documents are used only for verifying that you've recently moved and will will be permanently deleted after review is finalized. They will not be shared with {companyName}`,
|
|
10443
10483
|
uploadInstructions: "Upload an official document that shows",
|
|
10444
10484
|
},
|
|
10445
10485
|
success: {
|
|
@@ -11509,6 +11549,7 @@ const memberViewModelToRequest = (viewModel) => ({
|
|
|
11509
11549
|
city: viewModel.city,
|
|
11510
11550
|
state: viewModel.state,
|
|
11511
11551
|
postalCode: viewModel.postalCode,
|
|
11552
|
+
country: viewModel.countryChoice ? viewModel.countryChoice.value : undefined,
|
|
11512
11553
|
});
|
|
11513
11554
|
const seniorViewModelToRequest = (viewModel) => ({
|
|
11514
11555
|
firstName: viewModel.firstName,
|
|
@@ -11565,6 +11606,7 @@ const inactiveMilitaryViewModelToRequest = (viewModel) => ({
|
|
|
11565
11606
|
locale: viewModel.localeChoice.value,
|
|
11566
11607
|
country: viewModel.countryChoice ? viewModel.countryChoice.value : undefined,
|
|
11567
11608
|
metadata: viewModel.metadata,
|
|
11609
|
+
socialSecurityNumber: viewModel.socialSecurityNumber,
|
|
11568
11610
|
});
|
|
11569
11611
|
const firstResponderViewModelToRequest = (viewModel) => {
|
|
11570
11612
|
const request = {
|
|
@@ -11619,6 +11661,7 @@ const employmentViewModelToRequest = (viewModel) => ({
|
|
|
11619
11661
|
deviceFingerprintHash: viewModel.deviceFingerprintHash,
|
|
11620
11662
|
locale: viewModel.localeChoice.value,
|
|
11621
11663
|
metadata: viewModel.metadata,
|
|
11664
|
+
country: viewModel.countryChoice ? viewModel.countryChoice.value : undefined,
|
|
11622
11665
|
});
|
|
11623
11666
|
const driverLicenseViewModelToRequest = (viewModel) => ({
|
|
11624
11667
|
firstName: viewModel.firstName,
|
|
@@ -12081,11 +12124,13 @@ const initViewModel = ({ previousViewModel, currentStep, locale, fingerprint, co
|
|
|
12081
12124
|
};
|
|
12082
12125
|
const clearUploadedFiles = (viewModel) => {
|
|
12083
12126
|
if (viewModel) {
|
|
12084
|
-
|
|
12085
|
-
|
|
12086
|
-
|
|
12087
|
-
|
|
12127
|
+
return fn(viewModel, (draft) => {
|
|
12128
|
+
for (let i = 1; i <= MAX_DOC_UPLOAD_DOCS_ALLOWED; i += 1) {
|
|
12129
|
+
draft[`${UPLOAD_FILE_PREFIX}${i}`] = undefined;
|
|
12130
|
+
}
|
|
12131
|
+
});
|
|
12088
12132
|
}
|
|
12133
|
+
return undefined;
|
|
12089
12134
|
};
|
|
12090
12135
|
const collectThreatMetrixProfile = async (verificationId) => {
|
|
12091
12136
|
import(/* webpackChunkName: "Tmetrix" */ './es6/index-1839f844.es.js')
|
|
@@ -13820,8 +13865,7 @@ const createFetchVerificationRequest = async ({ dispatch, verificationResponsePr
|
|
|
13820
13865
|
orgList = await orgListPromise;
|
|
13821
13866
|
logger.info("orgList received: ", orgList);
|
|
13822
13867
|
}
|
|
13823
|
-
clearUploadedFiles(previousViewModel); // Need to remove the file elements from state since deepClone cannot clone them
|
|
13824
|
-
let updatedPreviousViewModel = deepClone(previousViewModel);
|
|
13868
|
+
let updatedPreviousViewModel = clearUploadedFiles(previousViewModel); // Need to remove the file elements from state since deepClone cannot clone them
|
|
13825
13869
|
const previousSegment = previousVerificationResponse
|
|
13826
13870
|
? previousVerificationResponse.segment
|
|
13827
13871
|
: segment;
|
|
@@ -13907,6 +13951,11 @@ const createUpdateLocale = (dispatch, programId) => async (viewModel, programThe
|
|
|
13907
13951
|
* @param dispatch
|
|
13908
13952
|
*/
|
|
13909
13953
|
const createUpdateProgramTheme = (dispatch) => async (programTheme) => dispatch({ programTheme, type: "PROGRAM_THEME" });
|
|
13954
|
+
/**
|
|
13955
|
+
* @description Perform a full reset of the in-memory state
|
|
13956
|
+
* Useful to fully reset the form and start over again, similar to a page refresh.
|
|
13957
|
+
*/
|
|
13958
|
+
const createResetState = (dispatch) => async () => dispatch({ type: "RESET_STATE" });
|
|
13910
13959
|
/**
|
|
13911
13960
|
* @description Action creator to update the field validation errors, which are those that are shown to a user as they fill-in the HTML form.
|
|
13912
13961
|
* @param dispatch
|
|
@@ -18287,7 +18336,7 @@ const FaqLinkComponent = ({ verificationService, linkText }) => {
|
|
|
18287
18336
|
};
|
|
18288
18337
|
|
|
18289
18338
|
const FormFooterComponent = ({ verificationService, children }) => {
|
|
18290
|
-
const { viewModel
|
|
18339
|
+
const { viewModel } = verificationService;
|
|
18291
18340
|
const countryChoice = getSafe(() => viewModel.countryChoice.value, undefined);
|
|
18292
18341
|
const locale = getLocaleSafely(viewModel);
|
|
18293
18342
|
const privacyPolicyRef = React.useRef({});
|
|
@@ -18298,13 +18347,8 @@ const FormFooterComponent = ({ verificationService, children }) => {
|
|
|
18298
18347
|
return;
|
|
18299
18348
|
}
|
|
18300
18349
|
const privacyPolicyText = privacyPolicyRef.current.innerHTML.replace(cleanupCommonTags, "");
|
|
18301
|
-
const updatedViewModel =
|
|
18302
|
-
|
|
18303
|
-
draft.metadata = {};
|
|
18304
|
-
}
|
|
18305
|
-
draft.metadata.submissionOptIn = privacyPolicyText;
|
|
18306
|
-
});
|
|
18307
|
-
updateViewModel(updatedViewModel);
|
|
18350
|
+
const updatedViewModel = { metadata: { submissionOptIn: privacyPolicyText } };
|
|
18351
|
+
setViewModel(updatedViewModel, { partial: true });
|
|
18308
18352
|
}, [privacyPolicyRef, locale]);
|
|
18309
18353
|
return (React.createElement("div", { className: "sid-footer sid-h-small-text sid-l-space-top-md" },
|
|
18310
18354
|
!children && (React.createElement("div", { className: "sid-footer__shield" },
|
|
@@ -18442,10 +18486,11 @@ const BaseCountryComponentWrapper = ({ verificationService, viewModel, intl, vie
|
|
|
18442
18486
|
}
|
|
18443
18487
|
}, [firstRender]);
|
|
18444
18488
|
React.useEffect(() => {
|
|
18445
|
-
|
|
18489
|
+
const includesUS = countryChoices.some((choice) => choice.value === "US");
|
|
18490
|
+
if (!hasMultipleCountries && !includesUS) {
|
|
18446
18491
|
const fieldsToSkip = viewModel.fieldsToSkipValidation
|
|
18447
18492
|
? [...viewModel.fieldsToSkipValidation, "country"]
|
|
18448
|
-
: ["country"];
|
|
18493
|
+
: ["country", "address1", "postalCode", "state", "city"];
|
|
18449
18494
|
verificationService.updateViewModel(produceDraftViewModel(viewModel, "fieldsToSkipValidation", fieldsToSkip));
|
|
18450
18495
|
}
|
|
18451
18496
|
}, [hasMultipleCountries]);
|
|
@@ -18482,6 +18527,33 @@ const RewardsRemainingComponent = ({ verificationService, }) => {
|
|
|
18482
18527
|
return null;
|
|
18483
18528
|
};
|
|
18484
18529
|
|
|
18530
|
+
/**
|
|
18531
|
+
* Custom form field component.
|
|
18532
|
+
* Implementors can render a form field passing in config using setOptions, rather than
|
|
18533
|
+
* having to create an entire React project and override component(s).
|
|
18534
|
+
*/
|
|
18535
|
+
const FormFieldCustom = injectIntl(({ config, verificationService, intl }) => {
|
|
18536
|
+
const currentValue = getSafe(() => verificationService.viewModel.metadata[config.fieldId]) || "";
|
|
18537
|
+
const errorId = getSafe(() => verificationService.fieldValidationErrors[config.fieldId]);
|
|
18538
|
+
const onChange = (value) => {
|
|
18539
|
+
verificationService.updateViewModel(fn(verificationService.viewModel, (draft) => {
|
|
18540
|
+
draft.metadata = draft.metadata || {};
|
|
18541
|
+
draft.metadata[config.fieldId] = value;
|
|
18542
|
+
}));
|
|
18543
|
+
verificationService.updateFieldValidationErrors(fn(verificationService.fieldValidationErrors, (draft) => {
|
|
18544
|
+
const errorId = config.validate(value);
|
|
18545
|
+
if (errorId === undefined) {
|
|
18546
|
+
delete draft[config.fieldId];
|
|
18547
|
+
}
|
|
18548
|
+
// Don't set error. Only do that when submit is clicked, same as jslib's built-in fields
|
|
18549
|
+
}));
|
|
18550
|
+
};
|
|
18551
|
+
return (React.createElement(FormFieldText, { fieldId: config.fieldId, value: `${currentValue}`, onChange: onChange, placeholder: intl.formatHTMLMessage({
|
|
18552
|
+
id: `${config.fieldId}Placeholder`,
|
|
18553
|
+
defaultMessage: config.fieldId,
|
|
18554
|
+
}), label: React.createElement(FormattedHTMLMessage, { id: `${config.fieldId}Label`, defaultMessage: config.fieldId }), errorMessage: errorId && (React.createElement(FormattedHTMLMessage, { id: `errorId.${errorId}`, defaultMessage: `Invalid ${config.fieldId}` })), showPlaceholderAndHideLabel: config.showPlaceholderAndHideLabel, required: config.required }));
|
|
18555
|
+
});
|
|
18556
|
+
|
|
18485
18557
|
/**
|
|
18486
18558
|
* TODO - preamble
|
|
18487
18559
|
*/
|
|
@@ -18552,6 +18624,7 @@ const StepStudentPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
18552
18624
|
updateStudentViewModel("phoneNumber", newValue);
|
|
18553
18625
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
18554
18626
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
18627
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
18555
18628
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
18556
18629
|
updateStudentViewModel("metadata", {
|
|
18557
18630
|
...verificationService.viewModel.metadata,
|
|
@@ -18640,6 +18713,7 @@ const StepSeniorPersonalInfo = ({ verificationService }) => {
|
|
|
18640
18713
|
updateSeniorViewModel("phoneNumber", newValue);
|
|
18641
18714
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
18642
18715
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
18716
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
18643
18717
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
18644
18718
|
updateSeniorViewModel("metadata", {
|
|
18645
18719
|
...verificationService.viewModel.metadata,
|
|
@@ -18677,21 +18751,10 @@ const carrierConsentValueValidator = (countryChoiceValue) => (value, programThem
|
|
|
18677
18751
|
}
|
|
18678
18752
|
};
|
|
18679
18753
|
|
|
18680
|
-
const City = ({ value, isErrored, onChange, intl, onKeyDown = undefined, placeholder = "", }) => (React.createElement("
|
|
18681
|
-
React.createElement("div", { className: "sid-l-space-top-md" }),
|
|
18682
|
-
React.createElement(FieldLabel, { text: React.createElement(FormattedHTMLMessage, { id: "city", defaultMessage: "City" }), htmlForLabel: "sid-city", id: "sid-city-label", displayClasses: placeholder && "sid-h-screen-reader-only" }),
|
|
18683
|
-
React.createElement(InputTextComponent, { id: "city", isErrored: isErrored, onChange: (e) => onChange(e.target.value), onKeyDown: typeof onKeyDown === "function" ? (e) => onKeyDown(e) : undefined, placeholder: placeholder || intl.formatHTMLMessage({ id: "cityPlaceholder", defaultMessage: "City" }), value: value, "aria-labelledby": "sid-city-label" }),
|
|
18684
|
-
isErrored ? (React.createElement("div", { className: "sid-field-error" },
|
|
18685
|
-
React.createElement(FormattedHTMLMessage, { id: "errorId.invalidCity", defaultMessage: "Invalid city" }))) : null));
|
|
18754
|
+
const City = ({ value, isErrored, onChange, intl, isRequired = false, onKeyDown = undefined, placeholder = "", }) => (React.createElement(FormFieldText, { fieldId: "city", value: value, onChange: onChange, placeholder: placeholder || intl.formatHTMLMessage({ id: "cityPlaceholder", defaultMessage: "City" }), label: React.createElement(FormattedHTMLMessage, { id: "city", defaultMessage: "City" }), errorMessage: isErrored && React.createElement(FormattedHTMLMessage, { id: "errorId.invalidCity", defaultMessage: "Invalid city" }), showPlaceholderAndHideLabel: !!placeholder, required: isRequired, onKeyDown: typeof onKeyDown === "function" ? (e) => onKeyDown(e) : undefined }));
|
|
18686
18755
|
const CityComponent = injectIntl(City);
|
|
18687
18756
|
|
|
18688
|
-
const Address = ({ value, isErrored, onChange, intl, onKeyDown = undefined, placeholder = "", }) => (React.createElement("
|
|
18689
|
-
React.createElement("div", { className: "sid-l-space-top-md" }),
|
|
18690
|
-
React.createElement(FieldLabel, { text: React.createElement(FormattedHTMLMessage, { id: "address", defaultMessage: "Address" }), htmlForLabel: "sid-address", id: "sid-address-label", displayClasses: placeholder && "sid-h-screen-reader-only" }),
|
|
18691
|
-
React.createElement(InputTextComponent, { id: "address", isErrored: isErrored, onChange: (e) => onChange(e.target.value), onKeyDown: typeof onKeyDown === "function" ? (e) => onKeyDown(e) : undefined, placeholder: placeholder ||
|
|
18692
|
-
intl.formatHTMLMessage({ id: "addressPlaceholder", defaultMessage: "Address" }), value: value, "aria-labelledby": "sid-address-label" }),
|
|
18693
|
-
isErrored ? (React.createElement("div", { className: "sid-field-error" },
|
|
18694
|
-
React.createElement(FormattedHTMLMessage, { id: "errorId.invalidAddress", defaultMessage: "Invalid address" }))) : null));
|
|
18757
|
+
const Address = ({ value, isErrored, onChange, intl, isRequired = false, onKeyDown = undefined, placeholder = "", }) => (React.createElement(FormFieldText, { fieldId: "address", value: value, onChange: onChange, placeholder: placeholder || intl.formatHTMLMessage({ id: "addressPlaceholder", defaultMessage: "Address" }), label: React.createElement(FormattedHTMLMessage, { id: "address", defaultMessage: "Address" }), errorMessage: isErrored && (React.createElement(FormattedHTMLMessage, { id: "errorId.invalidAddress", defaultMessage: "Invalid address" })), showPlaceholderAndHideLabel: !!placeholder, required: isRequired, onKeyDown: typeof onKeyDown === "function" ? (e) => onKeyDown(e) : undefined }));
|
|
18695
18758
|
const AddressComponent = injectIntl(Address);
|
|
18696
18759
|
|
|
18697
18760
|
/**
|
|
@@ -18812,6 +18875,7 @@ const StepAgePersonalInfo = ({ verificationService, intl }) => {
|
|
|
18812
18875
|
updateAgeViewModel("phoneNumber", value);
|
|
18813
18876
|
updateFieldValidationErrorsByFieldId("phoneNumber", value, verificationService);
|
|
18814
18877
|
}, errorId: fieldValidationErrors.phoneNumber, requireCarrierConsent: verificationService.programTheme.smsLoopEnabled || safeCountryValue !== "US", onCarrierConsentChange: onCarrierConsentChange, carrierConsent: Boolean(viewModel.metadata && viewModel.metadata.carrierConsentValue), selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })),
|
|
18878
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
18815
18879
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
18816
18880
|
updateAgeViewModel("metadata", {
|
|
18817
18881
|
...verificationService.viewModel.metadata,
|
|
@@ -18938,6 +19002,7 @@ const StepTeacherPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
18938
19002
|
updateTeacherViewModel("postalCode", newValue);
|
|
18939
19003
|
updateFieldValidationErrorsByFieldId("postalCode", newValue, verificationService);
|
|
18940
19004
|
}, value: viewModel.postalCode })) : null,
|
|
19005
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
18941
19006
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
18942
19007
|
updateTeacherViewModel("metadata", {
|
|
18943
19008
|
...verificationService.viewModel.metadata,
|
|
@@ -18984,7 +19049,6 @@ const MembershipOrganizationComponent = injectIntl(MembershipOrganization);
|
|
|
18984
19049
|
|
|
18985
19050
|
/**
|
|
18986
19051
|
* Step Member Personal Info Component
|
|
18987
|
-
* TODO - We need to import more from es6
|
|
18988
19052
|
*/
|
|
18989
19053
|
const StepMemberPersonalInfo = ({ intl, verificationService, }) => {
|
|
18990
19054
|
const viewModel = verificationService.viewModel;
|
|
@@ -19057,6 +19121,7 @@ const StepMemberPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
19057
19121
|
updateMemberViewModel("phoneNumber", newValue);
|
|
19058
19122
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
19059
19123
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
19124
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19060
19125
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19061
19126
|
updateMemberViewModel("metadata", {
|
|
19062
19127
|
...verificationService.viewModel.metadata,
|
|
@@ -19256,6 +19321,7 @@ const StepActiveMilitaryPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
19256
19321
|
updateActiveMilitaryViewModel("phoneNumber", newValue);
|
|
19257
19322
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
19258
19323
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
19324
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19259
19325
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19260
19326
|
updateActiveMilitaryViewModel("metadata", {
|
|
19261
19327
|
...verificationService.viewModel.metadata,
|
|
@@ -19380,6 +19446,50 @@ DischargeDate.defaultProps = {
|
|
|
19380
19446
|
};
|
|
19381
19447
|
const DischargeDateComponent = injectIntl(DischargeDate);
|
|
19382
19448
|
|
|
19449
|
+
/**
|
|
19450
|
+
* Insert `newPart` into a string
|
|
19451
|
+
* Use:
|
|
19452
|
+
* "Hi !".insertAt(3, "world"); // "Hi world!"
|
|
19453
|
+
*/
|
|
19454
|
+
String.prototype.insertAt = function (index, newPart) {
|
|
19455
|
+
if (index > this.length) {
|
|
19456
|
+
return this;
|
|
19457
|
+
}
|
|
19458
|
+
return `${this.slice(0, index)}${newPart}${this.slice(index)}`;
|
|
19459
|
+
};
|
|
19460
|
+
|
|
19461
|
+
const displaySSN = (value) => {
|
|
19462
|
+
let stringValue;
|
|
19463
|
+
try {
|
|
19464
|
+
stringValue = value.toString();
|
|
19465
|
+
if (!stringValue)
|
|
19466
|
+
throw new Error();
|
|
19467
|
+
}
|
|
19468
|
+
catch (e) {
|
|
19469
|
+
return "";
|
|
19470
|
+
}
|
|
19471
|
+
return stringValue
|
|
19472
|
+
.replace(/[^\d]/g, "") // replce non-digit chars
|
|
19473
|
+
.insertAt(3, "-") // for display
|
|
19474
|
+
.insertAt(6, "-")
|
|
19475
|
+
.replace("--", "") // just in case
|
|
19476
|
+
.replace(/-$/, ""); // don't add trailing hyphen, breaks backspace
|
|
19477
|
+
};
|
|
19478
|
+
// The viewModel and API don't include hyphens. Also enforces max length, prior to setting viewModel, avoiding off-by-one error.
|
|
19479
|
+
const unDisplaySSN = (value) => value.replace(/-/g, "").slice(0, SSN_STRING_LENGTH);
|
|
19480
|
+
|
|
19481
|
+
const SocialSecurity = ({ value, isErrored, onChange, intl, explanation, placeholder = "", isRequired = false, label, }) => {
|
|
19482
|
+
const getDefaultExplanation = () => (!isRequired ? explanation : "");
|
|
19483
|
+
return (React.createElement("div", { className: "sid-field sid-ssn" },
|
|
19484
|
+
React.createElement("div", { className: "sid-l-space-top-md" }),
|
|
19485
|
+
React.createElement(FieldLabel, { text: label, htmlForLabel: "sid-ssn", id: "sid-ssn-label", displayClasses: "sid-field__label-with-explanation", isRequired: isRequired }, getDefaultExplanation()),
|
|
19486
|
+
React.createElement(InputTextComponent, { id: "ssn", refId: FieldIdEnum.socialSecurityNumber, className: "sid-ssn__input", isErrored: isErrored, required: true, placeholder: placeholder ||
|
|
19487
|
+
intl.formatHTMLMessage({ id: "ssnPlaceholder", defaultMessage: "000-00-0000" }), value: displaySSN(value), hidePlaceholder: false, onChange: (e) => onChange(unDisplaySSN(e.target.value)), "aria-labelledby": "sid-ssn-label" }),
|
|
19488
|
+
isErrored ? (React.createElement("div", { className: "sid-field-error" },
|
|
19489
|
+
React.createElement(FormattedHTMLMessage, { id: "errorId.invalidSocialSecurityNumber", defaultMessage: "Invalid SSN" }))) : null));
|
|
19490
|
+
};
|
|
19491
|
+
const SocialSecurityNumber = injectIntl(SocialSecurity);
|
|
19492
|
+
|
|
19383
19493
|
/**
|
|
19384
19494
|
* TODO - preamble
|
|
19385
19495
|
*/
|
|
@@ -19466,6 +19576,11 @@ const StepInactiveMilitaryPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
19466
19576
|
updateInactiveMilitaryViewModel("phoneNumber", newValue);
|
|
19467
19577
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
19468
19578
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
19579
|
+
React.createElement(SocialSecurity, { value: viewModel.socialSecurityNumber, onChange: (value) => {
|
|
19580
|
+
updateInactiveMilitaryViewModel("socialSecurityNumber", value);
|
|
19581
|
+
updateFieldValidationErrorsByFieldId("socialSecurityNumber", value, verificationService);
|
|
19582
|
+
}, isRequired: false, isErrored: !!fieldValidationErrors[FieldIdEnum.socialSecurityNumber], placeholder: "000-00-0000", label: React.createElement(FormattedHTMLMessage, { id: "ssn", defaultMessage: "Social Security Number" }), explanation: React.createElement(FormattedHTMLMessage, { id: "optional", defaultMessage: "Optional" }) }),
|
|
19583
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19469
19584
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19470
19585
|
updateInactiveMilitaryViewModel("metadata", {
|
|
19471
19586
|
...verificationService.viewModel.metadata,
|
|
@@ -19598,6 +19713,7 @@ const StepFirstResponderPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
19598
19713
|
updateFirstResponderViewModel("postalCode", newValue);
|
|
19599
19714
|
updateFieldValidationErrorsByFieldId("postalCode", newValue, verificationService);
|
|
19600
19715
|
}, value: viewModel.postalCode })) : null,
|
|
19716
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19601
19717
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19602
19718
|
updateFirstResponderViewModel("metadata", {
|
|
19603
19719
|
...verificationService.viewModel.metadata,
|
|
@@ -19755,6 +19871,7 @@ const StepMedicalProfessionalPersonalInfo = ({ intl, verificationService, }) =>
|
|
|
19755
19871
|
updateMedicalProfessionalViewModel("memberId", newValue);
|
|
19756
19872
|
updateFieldValidationErrorsByFieldId("memberId", newValue, verificationService);
|
|
19757
19873
|
}, explanation: memberIdMessageKeys && (React.createElement(FormattedHTMLMessage, { id: memberIdMessageKeys.explanationKey, defaultMessage: "Your Professional Membership Registration Number" })), label: memberIdMessageKeys && (React.createElement(FormattedHTMLMessage, { id: memberIdMessageKeys.labelKey, defaultMessage: "Registration Number" })) })),
|
|
19874
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19758
19875
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19759
19876
|
updateMedicalProfessionalViewModel("metadata", {
|
|
19760
19877
|
...verificationService.viewModel.metadata,
|
|
@@ -19845,12 +19962,12 @@ const StepEmploymentPersonalInfo = ({ verificationService, }) => {
|
|
|
19845
19962
|
shouldCollectAddressFields(viewModel.countryChoice, verificationService.programTheme.config.countries) ? (React.createElement(AddressComponent, { isErrored: !!fieldValidationErrors.address1, errorId: fieldValidationErrors.address1, onChange: (newValue) => {
|
|
19846
19963
|
updateEmploymentViewModel("address1", newValue);
|
|
19847
19964
|
updateFieldValidationErrorsByFieldId("address1", newValue, verificationService);
|
|
19848
|
-
}, value: viewModel.address1 })) : null,
|
|
19965
|
+
}, isRequired: true, value: viewModel.address1 })) : null,
|
|
19849
19966
|
shouldCollectAddressFields(viewModel.countryChoice, verificationService.programTheme.config.countries) ? (React.createElement("div", { className: "sid-thirds" },
|
|
19850
19967
|
React.createElement(CityComponent, { isErrored: !!fieldValidationErrors.city, errorId: fieldValidationErrors.city, onChange: (newValue) => {
|
|
19851
19968
|
updateEmploymentViewModel("city", newValue);
|
|
19852
19969
|
updateFieldValidationErrorsByFieldId("city", newValue, verificationService);
|
|
19853
|
-
}, value: viewModel.city }),
|
|
19970
|
+
}, value: viewModel.city, isRequired: true }),
|
|
19854
19971
|
React.createElement(StateComponent, { isErrored: !!fieldValidationErrors.state, errorId: fieldValidationErrors.state, onChange: (newValue) => {
|
|
19855
19972
|
updateEmploymentViewModel("state", newValue);
|
|
19856
19973
|
updateFieldValidationErrorsByFieldId("state", newValue, verificationService);
|
|
@@ -19868,6 +19985,7 @@ const StepEmploymentPersonalInfo = ({ verificationService, }) => {
|
|
|
19868
19985
|
updateEmploymentViewModel("phoneNumber", newValue);
|
|
19869
19986
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
19870
19987
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
19988
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19871
19989
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19872
19990
|
updateEmploymentViewModel("metadata", {
|
|
19873
19991
|
...verificationService.viewModel.metadata,
|
|
@@ -19985,6 +20103,7 @@ const StepDriverLicensePersonalInfo = ({ intl, verificationService, }) => {
|
|
|
19985
20103
|
updateIdentityViewModel("driverLicenseNumber", newValue);
|
|
19986
20104
|
updateFieldValidationErrorsByFieldId("driverLicenseNumber", newValue, verificationService);
|
|
19987
20105
|
} }),
|
|
20106
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
19988
20107
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
19989
20108
|
updateIdentityViewModel("metadata", {
|
|
19990
20109
|
...verificationService.viewModel.metadata,
|
|
@@ -20060,12 +20179,12 @@ const StepGeneralIdentityPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
20060
20179
|
React.createElement(AddressComponent, { isErrored: !!fieldValidationErrors.address1, errorId: fieldValidationErrors.address1, onChange: (newValue) => {
|
|
20061
20180
|
updateIdentityViewModel("address1", newValue);
|
|
20062
20181
|
updateFieldValidationErrorsByFieldId("address1", newValue, verificationService);
|
|
20063
|
-
}, value: viewModel.address1 }),
|
|
20182
|
+
}, value: viewModel.address1, isRequired: true }),
|
|
20064
20183
|
React.createElement("div", { className: "sid-thirds" },
|
|
20065
20184
|
React.createElement(CityComponent, { isErrored: !!fieldValidationErrors.city, errorId: fieldValidationErrors.city, onChange: (newValue) => {
|
|
20066
20185
|
updateIdentityViewModel("city", newValue);
|
|
20067
20186
|
updateFieldValidationErrorsByFieldId("city", newValue, verificationService);
|
|
20068
|
-
}, value: viewModel.city }),
|
|
20187
|
+
}, value: viewModel.city, isRequired: true }),
|
|
20069
20188
|
React.createElement(StateSelectComponent, { isRequired: true, options: getAvailableStateChoices(verificationService.programTheme, intl), value: viewModel.state || undefined, isErrored: Boolean(fieldValidationErrors.state), onChange: async (stateChoice) => {
|
|
20070
20189
|
const stateValue = stateChoice ? stateChoice.value : undefined;
|
|
20071
20190
|
updateIdentityViewModel("state", stateValue);
|
|
@@ -20074,7 +20193,8 @@ const StepGeneralIdentityPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
20074
20193
|
React.createElement(PostalCodeComponent, { isErrored: !!fieldValidationErrors.postalCode, onChange: (newValue) => {
|
|
20075
20194
|
updateIdentityViewModel("postalCode", newValue);
|
|
20076
20195
|
updateFieldValidationErrorsByFieldId("postalCode", newValue, verificationService);
|
|
20077
|
-
}, value: viewModel.postalCode })),
|
|
20196
|
+
}, value: viewModel.postalCode, isRequired: true })),
|
|
20197
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
20078
20198
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
20079
20199
|
updateIdentityViewModel("metadata", {
|
|
20080
20200
|
...verificationService.viewModel.metadata,
|
|
@@ -20150,12 +20270,12 @@ const StepHybridIdentityPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
20150
20270
|
React.createElement(AddressComponent, { isErrored: !!fieldValidationErrors.address1, errorId: fieldValidationErrors.address1, onChange: (newValue) => {
|
|
20151
20271
|
updateIdentityViewModel("address1", newValue);
|
|
20152
20272
|
updateFieldValidationErrorsByFieldId("address1", newValue, verificationService);
|
|
20153
|
-
}, value: viewModel.address1 }),
|
|
20273
|
+
}, value: viewModel.address1, isRequired: true }),
|
|
20154
20274
|
React.createElement("div", { className: "sid-thirds" },
|
|
20155
20275
|
React.createElement(CityComponent, { isErrored: !!fieldValidationErrors.city, errorId: fieldValidationErrors.city, onChange: (newValue) => {
|
|
20156
20276
|
updateIdentityViewModel("city", newValue);
|
|
20157
20277
|
updateFieldValidationErrorsByFieldId("city", newValue, verificationService);
|
|
20158
|
-
}, value: viewModel.city }),
|
|
20278
|
+
}, value: viewModel.city, isRequired: true }),
|
|
20159
20279
|
React.createElement(StateSelectComponent, { isRequired: true, options: getAvailableStateChoices(verificationService.programTheme, intl), value: viewModel.state || undefined, isErrored: Boolean(fieldValidationErrors.state), onChange: async (stateChoice) => {
|
|
20160
20280
|
const stateValue = stateChoice ? stateChoice.value : undefined;
|
|
20161
20281
|
updateIdentityViewModel("state", stateValue);
|
|
@@ -20169,6 +20289,7 @@ const StepHybridIdentityPersonalInfo = ({ intl, verificationService, }) => {
|
|
|
20169
20289
|
updateIdentityViewModel("driverLicenseNumber", newValue);
|
|
20170
20290
|
updateFieldValidationErrorsByFieldId("driverLicenseNumber", newValue, verificationService);
|
|
20171
20291
|
} }),
|
|
20292
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
20172
20293
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
20173
20294
|
updateIdentityViewModel("metadata", {
|
|
20174
20295
|
...verificationService.viewModel.metadata,
|
|
@@ -20294,6 +20415,12 @@ const StepLicensedProfessionalPersonalInfo = ({ intl, verificationService, }) =>
|
|
|
20294
20415
|
updateLicensedProfessionalViewModel("email", newValue);
|
|
20295
20416
|
updateFieldValidationErrorsByFieldId("email", newValue, verificationService);
|
|
20296
20417
|
}, onKeyDown: (event) => handleEmailOnKeyDown(event) }),
|
|
20418
|
+
verificationService.programTheme.isSmsNotifierConfigured ||
|
|
20419
|
+
verificationService.programTheme.smsLoopEnabled ? (React.createElement(PhoneNumberComponent, { isRequired: !!verificationService.programTheme.smsLoopEnabled, value: viewModel.phoneNumber, isErrored: !!fieldValidationErrors.phoneNumber, onChange: (newValue) => {
|
|
20420
|
+
updateLicensedProfessionalViewModel("phoneNumber", newValue);
|
|
20421
|
+
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
20422
|
+
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
20423
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
20297
20424
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
20298
20425
|
updateLicensedProfessionalViewModel("metadata", {
|
|
20299
20426
|
...verificationService.viewModel.metadata,
|
|
@@ -20355,7 +20482,7 @@ const StepMoverPersonalInfo = ({ verificationService }) => {
|
|
|
20355
20482
|
React.createElement(AddressComponent, { value: viewModel.address1, isErrored: !!fieldValidationErrors.address1, errorId: fieldValidationErrors.address1, onChange: (newValue) => {
|
|
20356
20483
|
updateMoverViewModel("address1", newValue);
|
|
20357
20484
|
updateFieldValidationErrorsByFieldId("address1", newValue, verificationService);
|
|
20358
|
-
} }),
|
|
20485
|
+
}, isRequired: true }),
|
|
20359
20486
|
React.createElement(PostalCodeComponent, { value: viewModel.postalCode, isErrored: !!fieldValidationErrors.postalCode, onChange: (newValue) => {
|
|
20360
20487
|
updateMoverViewModel("postalCode", newValue);
|
|
20361
20488
|
updateFieldValidationErrorsByFieldId("postalCode", newValue, verificationService);
|
|
@@ -20369,6 +20496,7 @@ const StepMoverPersonalInfo = ({ verificationService }) => {
|
|
|
20369
20496
|
updateMoverViewModel("phoneNumber", newValue);
|
|
20370
20497
|
updateFieldValidationErrorsByFieldId("phoneNumber", newValue, verificationService);
|
|
20371
20498
|
}, selectedCountryCode: viewModel.countryChoice && viewModel.countryChoice.value })) : null,
|
|
20499
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
20372
20500
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
20373
20501
|
updateMoverViewModel("metadata", {
|
|
20374
20502
|
...verificationService.viewModel.metadata,
|
|
@@ -20467,6 +20595,7 @@ const StepLowIncomePersonalInfo = ({ intl, verificationService, }) => {
|
|
|
20467
20595
|
updateLowIncomeViewModel("email", newValue);
|
|
20468
20596
|
updateFieldValidationErrorsByFieldId("email", newValue, verificationService);
|
|
20469
20597
|
}, onKeyDown: (event) => handleEmailOnKeyDown(event) }),
|
|
20598
|
+
getOptions().customFormFields.map((config) => (React.createElement(FormFieldCustom, { config: config, verificationService: verificationService }))),
|
|
20470
20599
|
React.createElement(MarketConsentWrapperComponent, { verificationService: verificationService, isErrored: !!fieldValidationErrors.marketConsentValue, onChange: (newValue) => {
|
|
20471
20600
|
updateLowIncomeViewModel("metadata", {
|
|
20472
20601
|
...verificationService.viewModel.metadata,
|
|
@@ -20487,52 +20616,6 @@ const StepLowIncomePersonalInfoComponent = injectIntl(StepLowIncomePersonalInfo)
|
|
|
20487
20616
|
// Collect status is identical to Active at this time.
|
|
20488
20617
|
const StepCollectMilitaryStatusComponent = ({ verificationService, }) => (React.createElement(StepActiveMilitaryPersonalInfoComponent, { verificationService: verificationService }));
|
|
20489
20618
|
|
|
20490
|
-
/**
|
|
20491
|
-
* Insert `newPart` into a string
|
|
20492
|
-
* Use:
|
|
20493
|
-
* "Hi !".insertAt(3, "world"); // "Hi world!"
|
|
20494
|
-
*/
|
|
20495
|
-
String.prototype.insertAt = function (index, newPart) {
|
|
20496
|
-
if (index > this.length) {
|
|
20497
|
-
return this;
|
|
20498
|
-
}
|
|
20499
|
-
return `${this.slice(0, index)}${newPart}${this.slice(index)}`;
|
|
20500
|
-
};
|
|
20501
|
-
|
|
20502
|
-
const displaySSN = (value) => {
|
|
20503
|
-
let stringValue;
|
|
20504
|
-
try {
|
|
20505
|
-
stringValue = value.toString();
|
|
20506
|
-
if (!stringValue)
|
|
20507
|
-
throw new Error();
|
|
20508
|
-
}
|
|
20509
|
-
catch (e) {
|
|
20510
|
-
return "";
|
|
20511
|
-
}
|
|
20512
|
-
return stringValue
|
|
20513
|
-
.replace(/[^\d]/g, "") // replce non-digit chars
|
|
20514
|
-
.insertAt(3, "-") // for display
|
|
20515
|
-
.insertAt(6, "-")
|
|
20516
|
-
.replace("--", "") // just in case
|
|
20517
|
-
.replace(/-$/, ""); // don't add trailing hyphen, breaks backspace
|
|
20518
|
-
};
|
|
20519
|
-
// The viewModel and API don't include hyphens. Also enforces max length, prior to setting viewModel, avoiding off-by-one error.
|
|
20520
|
-
const unDisplaySSN = (value) => value.replace(/-/g, "").slice(0, SSN_STRING_LENGTH);
|
|
20521
|
-
|
|
20522
|
-
const SocialSecurity = ({ value, isErrored, onChange, intl, placeholder = "", }) => {
|
|
20523
|
-
const changeSsn = (value) => {
|
|
20524
|
-
onChange(value);
|
|
20525
|
-
};
|
|
20526
|
-
return (React.createElement("div", { className: "sid-field sid-ssn" },
|
|
20527
|
-
React.createElement("div", { className: "sid-l-space-top-md" }),
|
|
20528
|
-
React.createElement(FieldLabel, { text: React.createElement(FormattedHTMLMessage, { id: "ssn", defaultMessage: "Social Security Number" }), htmlForLabel: "sid-ssn", id: "sid-ssn-label", displayClasses: placeholder && "sid-h-screen-reader-only" }),
|
|
20529
|
-
React.createElement(InputTextComponent, { id: "ssn", refId: FieldIdEnum.socialSecurityNumber, className: "sid-ssn__input", isErrored: isErrored, required: true, placeholder: placeholder ||
|
|
20530
|
-
intl.formatHTMLMessage({ id: "ssnPlaceholder", defaultMessage: "000-00-0000" }), value: displaySSN(value), hidePlaceholder: false, onChange: (e) => changeSsn(unDisplaySSN(e.target.value)), "aria-labelledby": "sid-ssn-label" }),
|
|
20531
|
-
isErrored ? (React.createElement("div", { className: "sid-field-error" },
|
|
20532
|
-
React.createElement(FormattedHTMLMessage, { id: "errorId.invalidSocialSecurityNumber", defaultMessage: "Invalid SSN" }))) : null));
|
|
20533
|
-
};
|
|
20534
|
-
const SocialSecurityNumber = injectIntl(SocialSecurity);
|
|
20535
|
-
|
|
20536
20619
|
const Step$1 = ({ useSsn, useDocUpload, verificationService }) => (React.createElement("div", { id: "sid-ssn-choice", className: "sid-l-container sid-l-horz-center" },
|
|
20537
20620
|
React.createElement("div", { className: "sid-header" },
|
|
20538
20621
|
React.createElement("div", { className: "sid-l-horz-center" },
|
|
@@ -20599,10 +20682,13 @@ const PoweredByComponent = ({ verificationService, isCentered }) => (React.creat
|
|
|
20599
20682
|
const TryAgainButtonComponent = ({ verificationService }) => {
|
|
20600
20683
|
const currentSegment = getSafe(() => verificationService.verificationResponse.segment);
|
|
20601
20684
|
const fetchNewVerificationRequest = React.useCallback(() => {
|
|
20602
|
-
|
|
20603
|
-
|
|
20604
|
-
|
|
20605
|
-
|
|
20685
|
+
(async () => {
|
|
20686
|
+
const trackingId = undefined;
|
|
20687
|
+
const forceNewVerificationRequest = true;
|
|
20688
|
+
await verificationService.resetState();
|
|
20689
|
+
verificationService.fetchNewVerificationRequest(verificationService.programId, currentSegment, undefined, trackingId, forceNewVerificationRequest);
|
|
20690
|
+
})();
|
|
20691
|
+
}, [verificationService.programId, currentSegment]);
|
|
20606
20692
|
return (React.createElement("button", { type: "button", className: "sid-btn sid-btn-light", "aria-label": "submit", onClick: fetchNewVerificationRequest, onKeyPress: fetchNewVerificationRequest, tabIndex: 0 },
|
|
20607
20693
|
React.createElement(FormattedHTMLMessage, { id: "tryAgain", defaultMessage: "Try again" })));
|
|
20608
20694
|
};
|
|
@@ -23210,6 +23296,7 @@ const mapDispatchToProps = (dispatch, ownProps) => ({
|
|
|
23210
23296
|
updateProgramTheme: createUpdateProgramTheme(dispatch),
|
|
23211
23297
|
updateFieldValidationErrors: createUpdateFieldValidationErrors(dispatch),
|
|
23212
23298
|
submitStep: createSubmitStep(dispatch),
|
|
23299
|
+
resetState: createResetState(dispatch),
|
|
23213
23300
|
});
|
|
23214
23301
|
// Return a VerificationService
|
|
23215
23302
|
const mergeProps = (propsFromState, propsFromDispatch, ownProps) => ({
|
|
@@ -23391,7 +23478,7 @@ class Iframe {
|
|
|
23391
23478
|
|
|
23392
23479
|
class Modal {
|
|
23393
23480
|
constructor(url, userConfig) {
|
|
23394
|
-
this.popStateEventHandler = () => this.closeModal(
|
|
23481
|
+
this.popStateEventHandler = () => this.closeModal();
|
|
23395
23482
|
const thresholdConfig = userConfig.mobileThreshold
|
|
23396
23483
|
? userConfig.mobileThreshold
|
|
23397
23484
|
: iframeConstants.DEFAULT_MOBILE_THRESHOLD_WIDTH;
|
|
@@ -23428,14 +23515,11 @@ class Modal {
|
|
|
23428
23515
|
});
|
|
23429
23516
|
return this.closeButton;
|
|
23430
23517
|
}
|
|
23431
|
-
closeModal(
|
|
23518
|
+
closeModal() {
|
|
23432
23519
|
window.removeEventListener("popstate", this.popStateEventHandler);
|
|
23433
23520
|
const transitionTimeout = iframeConstants.MODAL_OPACITY_TRANSITION_PERIOD;
|
|
23434
23521
|
removeElement(this.overlay, transitionTimeout);
|
|
23435
23522
|
removeElement(this.wrapper, transitionTimeout);
|
|
23436
|
-
if (!historyEventTrigger) {
|
|
23437
|
-
window.history.back();
|
|
23438
|
-
}
|
|
23439
23523
|
}
|
|
23440
23524
|
static createOverlay() {
|
|
23441
23525
|
const overlay = document.createElement("div");
|
|
@@ -23488,7 +23572,6 @@ class Modal {
|
|
|
23488
23572
|
});
|
|
23489
23573
|
document.body.appendChild(this.overlay);
|
|
23490
23574
|
document.body.appendChild(this.wrapper);
|
|
23491
|
-
window.history.pushState({}, document.title);
|
|
23492
23575
|
this.addPopStateListener();
|
|
23493
23576
|
}
|
|
23494
23577
|
init() {
|
|
@@ -23547,5 +23630,5 @@ const collectDeviceProfile = async (verificationId, programId) => {
|
|
|
23547
23630
|
includeIPQSDeviceFingerprintScript(programTheme, verificationId);
|
|
23548
23631
|
};
|
|
23549
23632
|
|
|
23550
|
-
export { ACCEPTED_DOC_MIME_TYPES, AcceptableUploadsComponent, AddressComponent, BirthDateComponent, BranchOfServiceComponent, ChangeLocaleComponent, CityComponent, CollegeNameComponent, CompanyComponent, CopyToClipboard, CountDownComponent, CountryComponent, CountryComponentWrapper, DEFAULT_LOCALE, DEFAULT_MINIMUM_ORG_SEARCH_VALUE_LENGTH, DEFAULT_PRIVACY_POLICY_URL, DeleteJson, DischargeDateComponent, DriverLicenseNumberComponent, EmailComponent, FaqLinkComponent, FetchOrganizationsComponent, FieldIdEnum, FieldIds, FieldLabel, FirstNameComponent, FirstResponderOrganizationComponent, FirstResponderStatusComponent, FirstResponderStatusDefaultMessagesEnum, FormFooterComponent, GetEmptyTheme, GetJson, GetResponse, HTTP_REQUEST_TIMEOUT, HookNameEnum, HookNames, HowDoesVerifyingWorkComponent, InputSelectButtonComponent, InputSelectComponent, InputSelectListComponent, InputTextComponent, LastNameComponent, LinkExternal, LoadingSpinnerComponent, Locales, LogoComponent, LowIncomeOrganizationComponent, LowIncomeStatusDefaultMessagesEnum, MAX_DOC_UPLOAD_DOCS_ALLOWED, MarketConsentWrapperComponent as MarketConsentWrapper, MedicalProfessionalOrganizationComponent, MedicalProfessionalStatusDefaultMessagesEnum, MedicalStatusComponent, MemberIdComponent, MembershipOrganizationComponent, MilitaryStatusComponent, MilitaryStatusDefaultMessagesEnum, MockSteps, MockStepsEnum, OptInComponent, OptInInputComponent, OrganizationListComponent, OrganizationResultComponent, PhoneNumberComponent, PostFiles, PostJson, PostalCodeComponent, PostalCodeInputComponent, PoweredByComponent, PrivacyPolicyLinkComponent, QUERY_STRING_ERRORID_OVERRIDE, QUERY_STRING_INSTALL_PAGE_URL, QUERY_STRING_REDIRECT_URL_OVERRIDE, QUERY_STRING_REWARD_CODE_OVERRIDE, QUERY_STRING_SEGMENT_OVERRIDE, QUERY_STRING_STEP_OVERRIDE, QUERY_STRING_SUBSEGMENT_OVERRIDE, RequestOrganizationContext, RequestOrganizationErrorComponent, RequestOrganizationForm, RequestOrganizationFormFooterComponent, RequestOrganizationSearchComponent, RequestOrganizationSearchResultComponent, RequestOrganizationSuccessComponent, ReviewPendingComponent, RewardsRemainingComponent, SHEERID, SMSCodeComponent, SSN_STRING_LENGTH, SSOPendingComponent, SearchFieldComponent, SegmentEnum, Segments, SelectButtonComponent, SelectComponent, SelectListComponent, SocialSecurityNumber, SortByLabel, SsnChoice, StateComponent, StateEnum, StateSelectComponent, StatusComponent, StepActiveMilitaryPersonalInfoComponent, StepDriverLicensePersonalInfoComponent, StepGeneralIdentityPersonalInfoComponent, StepHybridIdentityPersonalInfoComponent, StepLowIncomePersonalInfoComponent, SubSegmentEnum, TeacherSchoolComponent, TryAgainButtonComponent, TryAgainSteps, TypeaheadComponent, UPLOAD_FILE_PREFIX, UploadInfoComponent, VerificationApiClient, VerificationForm, VerificationSteps, VerificationStepsEnum, addFiles, addHook, allMockedResponses, arrayUnique, assertValidConversionRequest, assertValidDatabaseId, assertValidFieldId, assertValidFunction, assertValidHook, assertValidHookName, assertValidHtmlElement, assertValidLocale, assertValidMockStepName, assertValidProgramId, assertValidSegmentName, assertValidTrackingId, assertValidTryAgainStep, assertValidVerificationStepName, carrierConsentValueValidator, closeTabRef, collectDeviceProfile, conversion, convertByTrackingId, convertByVerificationId, customValidatorExists$1 as customValidatorExists, deepClone, deepMerge, displaySSN, employmentPInfoReqEmpty, ensureMaxMetadataKeyValueLengths, ensureTrailingSlash, fetchExistingVerificationRequest, fetchProgramOrganizations, fetchRequestOrganizations, formatTwoDigitValues, getAddSchoolRequestUrl, getAllEmptyViewModels, getAvailableCountryChoices, getAvailableLocaleChoices, getAvailableLocales, getAvailableMilitaryStatuses, getAvailableStateChoices, getCompanyName, getConfiguredCountries, getConfiguredStates, getCustomValidator, getCustomValidatorFields, getDefaultCountryChoice, getDomainFromUrl, getEmptyViewModel, getEstAndMaxReviewTimes, getEstimatedReviewTime, getExtendedFieldValidationErrorsEmpty, getFaqLink, getFieldDisplayOrderFromRefs, getFieldValidationErrors, getFieldValidationErrorsEmpty, getFingerprint, getFirstErroredFieldId, getHook, getLocaleSafely, getLogoUrl, getMarketConsent, getMaxReviewTime, getMessages, getMetadata, getNewEmailCodeResendUrl, getNewSmsCodeResendUrl, getNewVerificationRequestUrl, getOptions, getOrgSearchCountryTags, getOverriddenMock, getOverridenValidator, getPhoneNumberValidationError, getPrivacyPolicyCompanyName, getPrivacyPolicyUrl, getProgramThemeUrl, getQueryParamsFromUrl, getRefByFieldId, getRefs, getRouteOverride, getSafe, getSheerIdScriptBasePath, getStatusLabel, getTabRef, getTrackingIdFromQueryString, getVerificationIdFromQueryString, getVerificationStatusUrl, handleCountryOnKeyDown, handleEmailOnKeyDown, handleStateChange, hasFailedInstantMatch, howDoesVerifyingWorkMessages, isFormErrored, isFormFilled, isTestEmailDomains, isValidLocale, isValidUsPostalCode, listenToSheerIdFrame, loadInModal, loadInlineIframe, logger, orgToOption, orgsInStatus, overrideComponent, overrideValidator, phoneNumberValidator, populateViewModelFromQueryParams, postVerificationSizeUpdates, postalCodeMatchers, postalCodeValidator, produceDraftViewModel, produceDraftViewModelWithRequiredFields, recordEvent, recordVerificationResponse, recordViewModelChange, refreshStore, registerAdditionalLocales, removeAllFiles, removeCustomValidator, removeFile, requestOrganizationConstants, resetCustomValidators, resetHooks, resetMetadata, resetOptions, resetOverriddenComponents, resetOverriddenValidators, resetRefs, resetStore, resetTabRef, resetViewModel, resolveTrackingId, setCustomValidator, setDimension, setFocus, setGaDimensionIsTest, setMetadata, setOptions, setRef, setTabRef, setViewModel, shouldCollectAddressFields, shouldCollectPostalCode, socialSecurityEmpty, speakToOuterFrame, submitAddSchoolRequest, submitForm, unDisplaySSN, updateFieldValidationErrors, updateFieldValidationErrorsByFieldId, updateMilitaryViewModel, updateViewModelOrganization, usePollingInterval, validateFieldById, validateMetadata };
|
|
23633
|
+
export { ACCEPTED_DOC_MIME_TYPES, AcceptableUploadsComponent, AddressComponent, BirthDateComponent, BranchOfServiceComponent, ChangeLocaleComponent, CityComponent, CollegeNameComponent, CompanyComponent, CopyToClipboard, CountDownComponent, CountryComponent, CountryComponentWrapper, DEFAULT_LOCALE, DEFAULT_MINIMUM_ORG_SEARCH_VALUE_LENGTH, DEFAULT_PRIVACY_POLICY_URL, DeleteJson, DischargeDateComponent, DriverLicenseNumberComponent, EmailComponent, FaqLinkComponent, FetchOrganizationsComponent, FieldIdEnum, FieldIds, FieldLabel, FirstNameComponent, FirstResponderOrganizationComponent, FirstResponderStatusComponent, FirstResponderStatusDefaultMessagesEnum, FormFieldCustom, FormFieldLayout, FormFieldText, FormFooterComponent, GetEmptyTheme, GetJson, GetResponse, HTTP_REQUEST_TIMEOUT, HookNameEnum, HookNames, HowDoesVerifyingWorkComponent, InputSelectButtonComponent, InputSelectComponent, InputSelectListComponent, InputTextComponent, LastNameComponent, LinkExternal, LoadingSpinnerComponent, Locales, LogoComponent, LowIncomeOrganizationComponent, LowIncomeStatusDefaultMessagesEnum, MAX_DOC_UPLOAD_DOCS_ALLOWED, MarketConsentWrapperComponent as MarketConsentWrapper, MedicalProfessionalOrganizationComponent, MedicalProfessionalStatusDefaultMessagesEnum, MedicalStatusComponent, MemberIdComponent, MembershipOrganizationComponent, MilitaryStatusComponent, MilitaryStatusDefaultMessagesEnum, MockSteps, MockStepsEnum, OptInComponent, OptInInputComponent, OrganizationListComponent, OrganizationResultComponent, PhoneNumberComponent, PostFiles, PostJson, PostalCodeComponent, PostalCodeInputComponent, PoweredByComponent, PrivacyPolicyLinkComponent, QUERY_STRING_ERRORID_OVERRIDE, QUERY_STRING_INSTALL_PAGE_URL, QUERY_STRING_REDIRECT_URL_OVERRIDE, QUERY_STRING_REWARD_CODE_OVERRIDE, QUERY_STRING_SEGMENT_OVERRIDE, QUERY_STRING_STEP_OVERRIDE, QUERY_STRING_SUBSEGMENT_OVERRIDE, RequestOrganizationContext, RequestOrganizationErrorComponent, RequestOrganizationForm, RequestOrganizationFormFooterComponent, RequestOrganizationSearchComponent, RequestOrganizationSearchResultComponent, RequestOrganizationSuccessComponent, ReviewPendingComponent, RewardsRemainingComponent, SHEERID, SMSCodeComponent, SSN_STRING_LENGTH, SSOPendingComponent, SearchFieldComponent, SegmentEnum, Segments, SelectButtonComponent, SelectComponent, SelectListComponent, SocialSecurityNumber, SortByLabel, SsnChoice, StateComponent, StateEnum, StateSelectComponent, StatusComponent, StepActiveMilitaryPersonalInfoComponent, StepDriverLicensePersonalInfoComponent, StepGeneralIdentityPersonalInfoComponent, StepHybridIdentityPersonalInfoComponent, StepLowIncomePersonalInfoComponent, SubSegmentEnum, TeacherSchoolComponent, TryAgainButtonComponent, TryAgainSteps, TypeaheadComponent, UPLOAD_FILE_PREFIX, UploadInfoComponent, VerificationApiClient, VerificationForm, VerificationSteps, VerificationStepsEnum, addFiles, addHook, allMockedResponses, arrayUnique, assertValidConversionRequest, assertValidDatabaseId, assertValidFieldId, assertValidFunction, assertValidHook, assertValidHookName, assertValidHtmlElement, assertValidLocale, assertValidMockStepName, assertValidProgramId, assertValidSegmentName, assertValidTrackingId, assertValidTryAgainStep, assertValidVerificationStepName, carrierConsentValueValidator, closeTabRef, collectDeviceProfile, conversion, convertByTrackingId, convertByVerificationId, customValidatorExists$1 as customValidatorExists, deepClone, deepMerge, displaySSN, employmentPInfoReqEmpty, ensureMaxMetadataKeyValueLengths, ensureTrailingSlash, fetchExistingVerificationRequest, fetchProgramOrganizations, fetchRequestOrganizations, formatTwoDigitValues, getAddSchoolRequestUrl, getAllEmptyViewModels, getAvailableCountryChoices, getAvailableLocaleChoices, getAvailableLocales, getAvailableMilitaryStatuses, getAvailableStateChoices, getCompanyName, getConfiguredCountries, getConfiguredStates, getCustomValidator, getCustomValidatorFields, getDefaultCountryChoice, getDomainFromUrl, getEmptyViewModel, getEstAndMaxReviewTimes, getEstimatedReviewTime, getExtendedFieldValidationErrorsEmpty, getFaqLink, getFieldDisplayOrderFromRefs, getFieldValidationErrors, getFieldValidationErrorsEmpty, getFingerprint, getFirstErroredFieldId, getHook, getLocaleSafely, getLogoUrl, getMarketConsent, getMaxReviewTime, getMessages, getMetadata, getNewEmailCodeResendUrl, getNewSmsCodeResendUrl, getNewVerificationRequestUrl, getOptions, getOrgSearchCountryTags, getOverriddenMock, getOverridenValidator, getPhoneNumberValidationError, getPrivacyPolicyCompanyName, getPrivacyPolicyUrl, getProgramThemeUrl, getQueryParamsFromUrl, getRefByFieldId, getRefs, getRouteOverride, getSafe, getSheerIdScriptBasePath, getStatusLabel, getTabRef, getTrackingIdFromQueryString, getVerificationIdFromQueryString, getVerificationStatusUrl, handleCountryOnKeyDown, handleEmailOnKeyDown, handleStateChange, hasFailedInstantMatch, howDoesVerifyingWorkMessages, isFormErrored, isFormFilled, isTestEmailDomains, isValidLocale, isValidUsPostalCode, listenToSheerIdFrame, loadInModal, loadInlineIframe, logger, orgToOption, orgsInStatus, overrideComponent, overrideValidator, phoneNumberValidator, populateViewModelFromQueryParams, postVerificationSizeUpdates, postalCodeMatchers, postalCodeValidator, produceDraftViewModel, produceDraftViewModelWithRequiredFields, recordEvent, recordVerificationResponse, recordViewModelChange, refreshStore, registerAdditionalLocales, removeAllFiles, removeCustomValidator, removeFile, requestOrganizationConstants, resetCustomValidators, resetHooks, resetMetadata, resetOptions, resetOverriddenComponents, resetOverriddenValidators, resetRefs, resetStore, resetTabRef, resetViewModel, resolveTrackingId, setCustomValidator, setDimension, setFocus, setGaDimensionIsTest, setMetadata, setOptions, setRef, setTabRef, setViewModel, shouldCollectAddressFields, shouldCollectPostalCode, socialSecurityEmpty, speakToOuterFrame, submitAddSchoolRequest, submitForm, unDisplaySSN, updateFieldValidationErrors, updateFieldValidationErrorsByFieldId, updateMilitaryViewModel, updateViewModelOrganization, usePollingInterval, validateFieldById, validateMetadata };
|
|
23551
23634
|
//# sourceMappingURL=sheerides6.js.map
|