@axos-web-dev/shared-components 1.0.99-honeypot.1 → 1.0.99-leadpriority.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (119) hide show
  1. package/dist/Auth/ErrorAlert.js +2 -2
  2. package/dist/Button/Button.js +2 -2
  3. package/dist/Calculators/BuyDownCalculator/index.js +1 -1
  4. package/dist/Calculators/Calculator.js +14 -2
  5. package/dist/Calculators/MarineLoanMonthlyPaymentCalculator/index.d.ts +9 -0
  6. package/dist/Calculators/MarineLoanMonthlyPaymentCalculator/index.js +219 -0
  7. package/dist/Calculators/MaxLoanCalculator/index.js +22 -5
  8. package/dist/Calculators/MonthlyPaymentCalculator/MonthlyPaymentCalculator.css.d.ts +1 -0
  9. package/dist/Calculators/MonthlyPaymentCalculator/MonthlyPaymentCalculator.css.js +2 -0
  10. package/dist/Calculators/MonthlyPaymentCalculator/index.js +15 -5
  11. package/dist/Calculators/index.d.ts +2 -1
  12. package/dist/Calculators/index.js +3 -1
  13. package/dist/Carousel/index.js +2 -2
  14. package/dist/Chevron/index.js +2 -2
  15. package/dist/Comparison/Comparison.js +2 -2
  16. package/dist/ExecutiveBio/ExecutiveBio.js +2 -2
  17. package/dist/FaqAccordion/index.js +2 -2
  18. package/dist/FooterSiteMap/AxosBank/FooterSiteMap.js +2 -2
  19. package/dist/Forms/ApplicationStart.d.ts +1 -1
  20. package/dist/Forms/ApplicationStart.js +101 -89
  21. package/dist/Forms/ApplyNow.d.ts +2 -2
  22. package/dist/Forms/ApplyNow.js +170 -145
  23. package/dist/Forms/ClearingForm.d.ts +1 -1
  24. package/dist/Forms/ClearingForm.js +174 -162
  25. package/dist/Forms/CommercialDeposits.d.ts +1 -1
  26. package/dist/Forms/CommercialDeposits.js +191 -179
  27. package/dist/Forms/CommercialLending.d.ts +1 -1
  28. package/dist/Forms/CommercialLending.js +268 -256
  29. package/dist/Forms/CommercialPremiumFinance.d.ts +1 -1
  30. package/dist/Forms/CommercialPremiumFinance.js +106 -94
  31. package/dist/Forms/ContactCompany.d.ts +1 -1
  32. package/dist/Forms/ContactCompany.js +103 -91
  33. package/dist/Forms/ContactCompanyTitle.d.ts +1 -1
  34. package/dist/Forms/ContactCompanyTitle.js +117 -105
  35. package/dist/Forms/ContactUs.d.ts +1 -1
  36. package/dist/Forms/ContactUs.js +90 -79
  37. package/dist/Forms/ContactUsAAS.d.ts +1 -1
  38. package/dist/Forms/ContactUsAAS.js +170 -158
  39. package/dist/Forms/ContactUsBusiness.d.ts +1 -1
  40. package/dist/Forms/ContactUsBusiness.js +126 -114
  41. package/dist/Forms/ContactUsBusinessNameEmail.d.ts +1 -1
  42. package/dist/Forms/ContactUsBusinessNameEmail.js +95 -83
  43. package/dist/Forms/ContactUsLVF.d.ts +3 -1
  44. package/dist/Forms/ContactUsLVF.js +117 -101
  45. package/dist/Forms/ContactUsNMLSId.d.ts +1 -1
  46. package/dist/Forms/ContactUsNMLSId.js +109 -97
  47. package/dist/Forms/ContactUsNewTest.d.ts +3 -0
  48. package/dist/Forms/ContactUsNewTest.js +206 -0
  49. package/dist/Forms/CpraRequest.d.ts +1 -1
  50. package/dist/Forms/CpraRequest.js +630 -618
  51. package/dist/Forms/CraPublicFile.d.ts +1 -1
  52. package/dist/Forms/CraPublicFile.js +101 -89
  53. package/dist/Forms/DealerServices.d.ts +1 -1
  54. package/dist/Forms/DealerServices.js +215 -203
  55. package/dist/Forms/EmailOnly.d.ts +1 -1
  56. package/dist/Forms/EmailOnly.js +48 -36
  57. package/dist/Forms/EmailUs.d.ts +1 -1
  58. package/dist/Forms/EmailUs.js +65 -53
  59. package/dist/Forms/FormProps.d.ts +3 -0
  60. package/dist/Forms/Forms.css.d.ts +18 -0
  61. package/dist/Forms/Forms.css.js +44 -38
  62. package/dist/Forms/HoneyPot/HoneyPot.css.d.ts +1 -1
  63. package/dist/Forms/HoneyPot/HoneyPot.css.js +2 -2
  64. package/dist/Forms/HoneyPot/index.d.ts +10 -11
  65. package/dist/Forms/HoneyPot/index.js +21 -24
  66. package/dist/Forms/MortgageRate/MortgageRateForm.d.ts +1 -1
  67. package/dist/Forms/MortgageRate/MortgageRateForm.js +369 -348
  68. package/dist/Forms/MortgageRate/MortgageRateWatch.js +2 -2
  69. package/dist/Forms/MortgageWarehouseLending.d.ts +11 -0
  70. package/dist/Forms/MortgageWarehouseLending.js +337 -0
  71. package/dist/Forms/QuickPricer/QuickPricerForm.d.ts +1 -1
  72. package/dist/Forms/QuickPricer/QuickPricerForm.js +608 -596
  73. package/dist/Forms/SalesforceFieldsForm.d.ts +5 -0
  74. package/dist/Forms/SalesforceFieldsForm.js +11 -1
  75. package/dist/Forms/ScheduleCall.d.ts +1 -1
  76. package/dist/Forms/ScheduleCall.js +146 -134
  77. package/dist/Forms/ScheduleCallPremier.d.ts +1 -1
  78. package/dist/Forms/ScheduleCallPremier.js +168 -156
  79. package/dist/Forms/SuccesForm.js +5 -5
  80. package/dist/Forms/VendorQuestionnaire.d.ts +1 -1
  81. package/dist/Forms/VendorQuestionnaire.js +807 -795
  82. package/dist/Forms/WcplSurvey.d.ts +1 -1
  83. package/dist/Forms/WcplSurvey.js +102 -90
  84. package/dist/Forms/applynow-utils.d.ts +1 -0
  85. package/dist/Forms/applynow-utils.js +48 -0
  86. package/dist/Forms/index.d.ts +3 -0
  87. package/dist/Forms/index.js +10 -2
  88. package/dist/HeroBanner/HeroBanner.js +38 -1
  89. package/dist/Hyperlink/index.js +2 -2
  90. package/dist/IconBillboard/sections/CallToActionSection.js +2 -1
  91. package/dist/ImageBillboard/ExitIntentModal/useExitIntentModal.js +6 -1
  92. package/dist/ImageLink/ImageLink.js +2 -2
  93. package/dist/ImageLink/ImageLinkSet.js +2 -2
  94. package/dist/ImageLink/index.js +2 -2
  95. package/dist/Insight/Featured/CategorySelector.js +2 -2
  96. package/dist/Insight/Featured/Featured.js +2 -2
  97. package/dist/Insight/Featured/Header.js +2 -2
  98. package/dist/Modal/Modal.js +2 -2
  99. package/dist/NavigationMenu/AxosALTS/NavData.js +2 -2
  100. package/dist/NavigationMenu/AxosALTS/index.js +2 -2
  101. package/dist/NavigationMenu/AxosBank/MobileMenu/MobileNavData.js +14 -6
  102. package/dist/NavigationMenu/AxosBank/NavData.js +2 -2
  103. package/dist/NavigationMenu/AxosBank/SubNavBar.js +15 -7
  104. package/dist/NavigationMenu/AxosBank/index.js +2 -2
  105. package/dist/NavigationMenu/LaVictoire/NavData.js +2 -2
  106. package/dist/NavigationMenu/LaVictoire/index.js +2 -2
  107. package/dist/NavigationMenu/NavDataJson.js +2 -2
  108. package/dist/NavigationMenu/Navbar.js +2 -2
  109. package/dist/NavigationMenu/SignInNavButton.js +2 -2
  110. package/dist/SetContainer/SetContainer.js +2 -2
  111. package/dist/SocialMediaBar/iconsRepository.js +2 -2
  112. package/dist/VideoTile/VideoTile.js +2 -2
  113. package/dist/VideoWrapper/index.js +2 -2
  114. package/dist/assets/Calculators/MonthlyPaymentCalculator/MonthlyPaymentCalculator.css +3 -0
  115. package/dist/assets/Forms/Forms.css +135 -105
  116. package/dist/assets/Forms/HoneyPot/HoneyPot.css +4 -0
  117. package/dist/main.js +13 -3
  118. package/dist/utils/allowedAxosDomains.js +2 -1
  119. package/package.json +1 -1
@@ -41,8 +41,10 @@ import "../Calculators/ApyCalculator/ApyCalculator.css.js";
41
41
  import "../Table/Table.css.js";
42
42
  import "../Calculators/AxosOneCalculator/BalanceAPYCalculator.css.js";
43
43
  import "../Calculators/BalanceAPYCalculator/BalanceAPYCalculator.css.js";
44
+ import "../Input/PercentageInput.js";
44
45
  import { useForm, FormProvider } from "react-hook-form";
45
46
  import { z } from "zod";
47
+ import "../Calculators/BuyDownCalculator/BuyDownCalculator.css.js";
46
48
  import { iconForm, headerContainer, headerForm, form, descriptionField, formWrapper, disclosureForm, actions, formContainer } from "./Forms.css.js";
47
49
  import { honeyPotSchema, isValidHoneyPot, HoneyPot } from "./HoneyPot/index.js";
48
50
  import { SalesforceSchema } from "./SalesforceFieldsForm.js";
@@ -63,8 +65,6 @@ import "iframe-resizer";
63
65
  import "../Calculators/MonthlyPaymentCalculator/MonthlyPaymentCalculator.css.js";
64
66
  import "../Calculators/MonthlyPaymentLVFCalculator/MonthlyPaymentCalculator.css.js";
65
67
  import "../Calculators/SummitApyCalculator/BalanceAPYCalculator.css.js";
66
- import "../Input/PercentageInput.js";
67
- import "../Calculators/BuyDownCalculator/BuyDownCalculator.css.js";
68
68
  /* empty css */
69
69
  import "react-dom";
70
70
  /* empty css */
@@ -139,6 +139,7 @@ const ContactUsNMLSId = ({
139
139
  description,
140
140
  callToAction,
141
141
  validateEmail,
142
+ onValidate,
142
143
  id
143
144
  }) => {
144
145
  const schema = z.object({
@@ -212,101 +213,112 @@ const ContactUsNMLSId = ({
212
213
  }
213
214
  )
214
215
  ] }),
215
- /* @__PURE__ */ jsxs("form", { className: form, onSubmit: handleSubmit(submitForm), children: [
216
- /* @__PURE__ */ jsxs("div", { className: clsx(formWrapper({ variant })), children: [
217
- /* @__PURE__ */ jsx("div", { className: "", children: /* @__PURE__ */ jsx(
218
- Input,
219
- {
220
- id: "first_name",
221
- ...register("first_name", { required: true }),
222
- label: "First Name",
223
- sizes: "medium",
224
- placeholder: "First Name",
225
- required: true,
226
- error: !!errors.first_name,
227
- helperText: errors.first_name?.message,
228
- variant
229
- }
230
- ) }),
231
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
232
- Input,
233
- {
234
- id: "last_name",
235
- ...register("last_name", { required: true }),
236
- label: "Last Name",
237
- sizes: "medium",
238
- placeholder: "Last Name",
239
- required: true,
240
- error: !!errors.last_name,
241
- helperText: errors.last_name?.message,
242
- variant
243
- }
244
- ) }),
245
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
246
- Input,
247
- {
248
- id: "email",
249
- ...register("email", {
250
- required: true
251
- }),
252
- type: "email",
253
- label: "Email",
254
- sizes: "medium",
255
- placeholder: "Email",
256
- required: true,
257
- error: !!errors.email,
258
- helperText: errors.email?.message,
259
- variant
260
- }
261
- ) }),
262
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
263
- InputPhone,
264
- {
265
- id: "phone",
266
- ...register("phone", { required: true, maxLength: 12 }),
267
- label: "Phone",
268
- sizes: "medium",
269
- placeholder: "Phone",
270
- type: "tel",
271
- required: true,
272
- error: !!errors.phone,
273
- helperText: errors.phone?.message,
274
- variant
275
- }
276
- ) }),
277
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
278
- Input,
279
- {
280
- id: "NMLS_ID__c",
281
- ...register("NMLS_ID__c", {
282
- required: true,
283
- min: 6,
284
- max: 7
285
- }),
286
- label: "Company NMLS ID",
287
- placeholder: "Company NMLS ID",
288
- sizes: "medium",
289
- required: true,
290
- error: !!errors.NMLS_ID__c,
291
- helperText: errors.NMLS_ID__c?.message,
292
- variant
293
- }
294
- ) }),
295
- /* @__PURE__ */ jsx(HoneyPot, { register, errors, variant })
296
- ] }),
297
- children,
298
- /* @__PURE__ */ jsx("div", { className: disclosureForm({ variant }), children: disclosure }),
299
- /* @__PURE__ */ jsx("div", { className: actions, children: /* @__PURE__ */ jsx(
300
- Button,
301
- {
302
- color: getVariant(callToAction?.variant),
303
- as: "button",
304
- type: "submit",
305
- disabled: !isValid || isSubmitting,
306
- children: callToAction?.displayText
307
- }
308
- ) })
309
- ] })
216
+ /* @__PURE__ */ jsxs(
217
+ "form",
218
+ {
219
+ className: form,
220
+ onSubmit: async (e) => {
221
+ onValidate && onValidate(e);
222
+ await handleSubmit(submitForm)(e);
223
+ e.preventDefault();
224
+ },
225
+ children: [
226
+ /* @__PURE__ */ jsxs("div", { className: clsx(formWrapper({ variant })), children: [
227
+ /* @__PURE__ */ jsx("div", { className: "", children: /* @__PURE__ */ jsx(
228
+ Input,
229
+ {
230
+ id: "first_name",
231
+ ...register("first_name", { required: true }),
232
+ label: "First Name",
233
+ sizes: "medium",
234
+ placeholder: "First Name",
235
+ required: true,
236
+ error: !!errors.first_name,
237
+ helperText: errors.first_name?.message,
238
+ variant
239
+ }
240
+ ) }),
241
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
242
+ Input,
243
+ {
244
+ id: "last_name",
245
+ ...register("last_name", { required: true }),
246
+ label: "Last Name",
247
+ sizes: "medium",
248
+ placeholder: "Last Name",
249
+ required: true,
250
+ error: !!errors.last_name,
251
+ helperText: errors.last_name?.message,
252
+ variant
253
+ }
254
+ ) }),
255
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
256
+ Input,
257
+ {
258
+ id: "email",
259
+ ...register("email", {
260
+ required: true
261
+ }),
262
+ type: "email",
263
+ label: "Email",
264
+ sizes: "medium",
265
+ placeholder: "Email",
266
+ required: true,
267
+ error: !!errors.email,
268
+ helperText: errors.email?.message,
269
+ variant
270
+ }
271
+ ) }),
272
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
273
+ InputPhone,
274
+ {
275
+ id: "phone",
276
+ ...register("phone", { required: true, maxLength: 12 }),
277
+ label: "Phone",
278
+ sizes: "medium",
279
+ placeholder: "Phone",
280
+ type: "tel",
281
+ required: true,
282
+ error: !!errors.phone,
283
+ helperText: errors.phone?.message,
284
+ variant
285
+ }
286
+ ) }),
287
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
288
+ Input,
289
+ {
290
+ id: "NMLS_ID__c",
291
+ ...register("NMLS_ID__c", {
292
+ required: true,
293
+ min: 6,
294
+ max: 7
295
+ }),
296
+ label: "Company NMLS ID",
297
+ placeholder: "Company NMLS ID",
298
+ sizes: "medium",
299
+ required: true,
300
+ error: !!errors.NMLS_ID__c,
301
+ helperText: errors.NMLS_ID__c?.message,
302
+ variant
303
+ }
304
+ ) }),
305
+ /* @__PURE__ */ jsx(HoneyPot, { register, variant })
306
+ ] }),
307
+ children,
308
+ /* @__PURE__ */ jsx("div", { className: disclosureForm({ variant }), children: disclosure }),
309
+ /* @__PURE__ */ jsx("div", { className: actions, children: /* @__PURE__ */ jsx(
310
+ Button,
311
+ {
312
+ color: getVariant(callToAction?.variant),
313
+ as: "button",
314
+ type: "submit",
315
+ disabled: !isValid || isSubmitting,
316
+ children: callToAction?.displayText
317
+ }
318
+ ) })
319
+ ]
320
+ }
321
+ )
310
322
  ] }) }) }, id);
311
323
  };
312
324
  export {
@@ -0,0 +1,3 @@
1
+ import { FormProps } from './FormProps';
2
+
3
+ export declare const ContactUsNewTest: ({ icon, children, onSubmit, disclosure, variant: fullVariant, headline, description, callToAction, validateEmail, onValidate, id, }: FormProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,206 @@
1
+ "use client";
2
+ import { jsx, jsxs } from "react/jsx-runtime";
3
+ import { zodResolver } from "@hookform/resolvers/zod";
4
+ import { Button } from "../Button/Button.js";
5
+ import "../Button/Button.css.js";
6
+ import "react";
7
+ import "react-use";
8
+ import "../Input/Checkbox.js";
9
+ import "../Input/CurrencyInput.js";
10
+ import "../Input/Dropdown.js";
11
+ import "../Input/Dropdown.css.js";
12
+ import { Input } from "../Input/Input.js";
13
+ import "../Input/Input.css.js";
14
+ import "../Input/InputAmount.js";
15
+ import { InputPhone } from "../Input/InputPhone.js";
16
+ import "../Input/InputTextArea.js";
17
+ import "../Input/DownPaymentInput.js";
18
+ import "../Input/RadioButton.js";
19
+ import "../icons/ArrowIcon/ArrowIcon.css.js";
20
+ import SvgAxosX from "../icons/AxosX/index.js";
21
+ import SvgComponent from "../icons/AxosX/Blue.js";
22
+ import "../icons/CheckIcon/CheckIcon.css.js";
23
+ import '../assets/icons/FollowIcon/FollowIcon.css';import '../assets/icons/DownloadIcon/DownloadIcon.css';import '../assets/themes/victorie.css';import '../assets/themes/premier.css';import '../assets/themes/axos.css';/* empty css */
24
+ /* empty css */
25
+ /* empty css */
26
+ /* empty css */
27
+ /* empty css */
28
+ import "../utils/allowedAxosDomains.js";
29
+ import { associatedEmail } from "../utils/EverestValidity.js";
30
+ import { getVariant } from "../utils/getVariant.js";
31
+ import clsx from "clsx";
32
+ import { useForm, FormProvider } from "react-hook-form";
33
+ import * as z from "zod";
34
+ import { iconForm, headerContainer, headerForm, form, descriptionField, formWrapper, disclosureForm, actions, formContainer } from "./Forms.css.js";
35
+ import { honeyPotSchema, isValidHoneyPot, HoneyPot } from "./HoneyPot/index.js";
36
+ import { SalesforceSchema } from "./SalesforceFieldsForm.js";
37
+ const ContactUsNewTest = ({
38
+ icon = false,
39
+ children,
40
+ onSubmit = (values) => {
41
+ console.log(values);
42
+ },
43
+ disclosure,
44
+ variant: fullVariant = "primary",
45
+ headline,
46
+ description,
47
+ callToAction,
48
+ validateEmail,
49
+ onValidate,
50
+ id
51
+ }) => {
52
+ const schema = z.object({
53
+ first_name: z.string().regex(/^[A-Za-z][^0-9_!¡?÷?¿/\\+=@#$%ˆ&*,.^(){}|~<>;:[\]]{1,}$/g).trim().min(1, { message: "First Name is required." }),
54
+ last_name: z.string().regex(/^[A-Za-z][^0-9_!¡?÷?¿/\\+=@#$%ˆ&*,.^(){}|~<>;:[\]]{1,}$/g).trim().min(1, { message: "Last Name is required." }),
55
+ email: z.string().email({ message: "Email is required." }).refine(async (val) => await validateEmail(val)),
56
+ phone: z.string({ message: "Phone is required." }).regex(/[\d-]{10}/, "Invalid phone number.").min(10, { message: "Phone is required." }).max(12, { message: "Phone is required." }).transform((val, ctx) => {
57
+ const removeDashes = val.replace(/-/gi, "");
58
+ if (removeDashes.length !== 10) {
59
+ ctx.addIssue({
60
+ code: z.ZodIssueCode.custom,
61
+ message: "Phone must have at least 10 and no more than 10 characters."
62
+ });
63
+ return z.NEVER;
64
+ }
65
+ if (removeDashes.endsWith("00000") || removeDashes.startsWith("999") || removeDashes.length === 10 && /^[01]/.test(removeDashes)) {
66
+ ctx.addIssue({
67
+ code: z.ZodIssueCode.custom,
68
+ message: "Invalid phone number."
69
+ });
70
+ return z.NEVER;
71
+ }
72
+ return removeDashes;
73
+ })
74
+ });
75
+ const gen_schema = schema.merge(SalesforceSchema).merge(honeyPotSchema).superRefine((data, ctx) => {
76
+ if (!isValidHoneyPot(data)) {
77
+ ctx.addIssue({
78
+ code: z.ZodIssueCode.custom,
79
+ message: "fields are not valid."
80
+ });
81
+ }
82
+ });
83
+ const methods = useForm({
84
+ resolver: zodResolver(gen_schema, {
85
+ async: true
86
+ }),
87
+ mode: "all",
88
+ defaultValues: {
89
+ email: ""
90
+ }
91
+ });
92
+ const {
93
+ handleSubmit,
94
+ register,
95
+ formState: { errors, isValid, isSubmitting }
96
+ } = methods;
97
+ const submitForm = async (data) => {
98
+ await onSubmit(data);
99
+ };
100
+ const variant = getVariant(fullVariant);
101
+ return /* @__PURE__ */ jsx("section", { id, className: clsx(formContainer({ variant })), children: /* @__PURE__ */ jsx("div", { className: clsx("containment"), children: /* @__PURE__ */ jsxs(FormProvider, { ...methods, children: [
102
+ icon && /* @__PURE__ */ jsx("div", { className: clsx("text_center", iconForm), children: ["primary", "secondary"].includes(variant) ? /* @__PURE__ */ jsx(SvgComponent, {}) : /* @__PURE__ */ jsx(SvgAxosX, {}) }),
103
+ /* @__PURE__ */ jsxs("div", { className: `${headerContainer} text_center`, children: [
104
+ /* @__PURE__ */ jsx("h2", { className: clsx("header_2", headerForm({ variant })), children: headline }),
105
+ description && /* @__PURE__ */ jsx(
106
+ "div",
107
+ {
108
+ className: `${form} ${descriptionField({ variant })} text_center`,
109
+ children: description
110
+ }
111
+ )
112
+ ] }),
113
+ /* @__PURE__ */ jsxs(
114
+ "form",
115
+ {
116
+ className: form,
117
+ onSubmit: async (e) => {
118
+ onValidate && onValidate(e);
119
+ await handleSubmit(submitForm)(e);
120
+ e.preventDefault();
121
+ },
122
+ children: [
123
+ /* @__PURE__ */ jsxs("div", { className: clsx(formWrapper({ variant })), children: [
124
+ /* @__PURE__ */ jsx("div", { className: "", children: /* @__PURE__ */ jsx(
125
+ Input,
126
+ {
127
+ id: "first_name",
128
+ ...register("first_name", { required: true }),
129
+ label: "First Name",
130
+ sizes: "medium",
131
+ placeholder: "First Name",
132
+ required: true,
133
+ error: !!errors.first_name,
134
+ helperText: errors.first_name?.message,
135
+ variant
136
+ }
137
+ ) }),
138
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
139
+ Input,
140
+ {
141
+ id: "last_name",
142
+ ...register("last_name", { required: true }),
143
+ label: "Last Name",
144
+ sizes: "medium",
145
+ placeholder: "Last Name",
146
+ required: true,
147
+ error: !!errors.last_name,
148
+ helperText: errors.last_name?.message,
149
+ variant
150
+ }
151
+ ) }),
152
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
153
+ Input,
154
+ {
155
+ id: "email",
156
+ ...register("email", {
157
+ required: true,
158
+ validate: {
159
+ isValid: associatedEmail
160
+ }
161
+ }),
162
+ label: "Email",
163
+ sizes: "medium",
164
+ placeholder: "Email",
165
+ required: true,
166
+ error: !!errors.email,
167
+ helperText: errors.email?.message,
168
+ variant
169
+ }
170
+ ) }),
171
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
172
+ InputPhone,
173
+ {
174
+ id: "phone",
175
+ ...register("phone", { required: true, maxLength: 12 }),
176
+ label: "Phone",
177
+ sizes: "medium",
178
+ placeholder: "Phone",
179
+ required: true,
180
+ error: !!errors.phone,
181
+ helperText: errors.phone?.message,
182
+ variant
183
+ }
184
+ ) }),
185
+ /* @__PURE__ */ jsx(HoneyPot, { register, variant })
186
+ ] }),
187
+ children,
188
+ /* @__PURE__ */ jsx("div", { className: disclosureForm({ variant }), children: disclosure }),
189
+ /* @__PURE__ */ jsx("div", { className: actions, children: /* @__PURE__ */ jsx(
190
+ Button,
191
+ {
192
+ color: getVariant(callToAction?.variant),
193
+ as: "button",
194
+ type: "submit",
195
+ disabled: !isValid || isSubmitting,
196
+ children: callToAction?.displayText
197
+ }
198
+ ) })
199
+ ]
200
+ }
201
+ )
202
+ ] }) }) }, id);
203
+ };
204
+ export {
205
+ ContactUsNewTest
206
+ };
@@ -24,4 +24,4 @@ export type CpraInputs = {
24
24
  Zip_Code: string;
25
25
  Contact_Method: "Email" | "Postal Mail";
26
26
  };
27
- export declare const CpraRequest: ({ icon, children, onSubmit, disclosure, variant: fullVariant, headline, description, callToAction, id, }: FormProps) => import("react/jsx-runtime").JSX.Element;
27
+ export declare const CpraRequest: ({ icon, children, onSubmit, disclosure, variant: fullVariant, headline, description, callToAction, onValidate, id, }: FormProps) => import("react/jsx-runtime").JSX.Element;