@axos-web-dev/shared-components 1.0.99-dev-2 → 1.0.99-dev-6

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 (53) hide show
  1. package/dist/Calculators/BuyDownCalculator/index.js +1 -1
  2. package/dist/Calculators/Calculator.d.ts +3 -1
  3. package/dist/Calculators/Calculator.js +4 -2
  4. package/dist/Calculators/MonthlyPaymentCalculator/index.d.ts +3 -1
  5. package/dist/Calculators/MonthlyPaymentCalculator/index.js +3 -8
  6. package/dist/Forms/ApplicationStart.d.ts +1 -1
  7. package/dist/Forms/ApplicationStart.js +101 -89
  8. package/dist/Forms/ClearingForm.d.ts +1 -1
  9. package/dist/Forms/ClearingForm.js +174 -162
  10. package/dist/Forms/CommercialDeposits.d.ts +1 -1
  11. package/dist/Forms/CommercialDeposits.js +191 -179
  12. package/dist/Forms/CommercialLending.d.ts +1 -1
  13. package/dist/Forms/CommercialLending.js +268 -256
  14. package/dist/Forms/CommercialPremiumFinance.d.ts +1 -1
  15. package/dist/Forms/CommercialPremiumFinance.js +106 -94
  16. package/dist/Forms/ContactCompany.d.ts +1 -1
  17. package/dist/Forms/ContactCompany.js +103 -91
  18. package/dist/Forms/ContactCompanyTitle.d.ts +1 -1
  19. package/dist/Forms/ContactCompanyTitle.js +117 -105
  20. package/dist/Forms/ContactUs.js +2 -1
  21. package/dist/Forms/ContactUsAAS.d.ts +1 -1
  22. package/dist/Forms/ContactUsAAS.js +170 -158
  23. package/dist/Forms/ContactUsBusiness.d.ts +1 -1
  24. package/dist/Forms/ContactUsBusiness.js +124 -112
  25. package/dist/Forms/ContactUsBusinessNameEmail.d.ts +1 -1
  26. package/dist/Forms/ContactUsBusinessNameEmail.js +93 -81
  27. package/dist/Forms/ContactUsLVF.d.ts +3 -1
  28. package/dist/Forms/ContactUsLVF.js +117 -101
  29. package/dist/Forms/ContactUsNMLSId.d.ts +1 -1
  30. package/dist/Forms/ContactUsNMLSId.js +107 -95
  31. package/dist/Forms/CpraRequest.d.ts +1 -1
  32. package/dist/Forms/CpraRequest.js +630 -618
  33. package/dist/Forms/CraPublicFile.d.ts +1 -1
  34. package/dist/Forms/CraPublicFile.js +99 -87
  35. package/dist/Forms/DealerServices.d.ts +1 -1
  36. package/dist/Forms/DealerServices.js +215 -203
  37. package/dist/Forms/EmailOnly.d.ts +1 -1
  38. package/dist/Forms/EmailOnly.js +46 -34
  39. package/dist/Forms/EmailUs.d.ts +1 -1
  40. package/dist/Forms/EmailUs.js +65 -53
  41. package/dist/Forms/MortgageRate/MortgageRateForm.d.ts +1 -1
  42. package/dist/Forms/MortgageRate/MortgageRateForm.js +363 -343
  43. package/dist/Forms/QuickPricer/QuickPricerForm.d.ts +1 -1
  44. package/dist/Forms/QuickPricer/QuickPricerForm.js +608 -596
  45. package/dist/Forms/ScheduleCall.d.ts +1 -1
  46. package/dist/Forms/ScheduleCall.js +146 -134
  47. package/dist/Forms/ScheduleCallPremier.d.ts +1 -1
  48. package/dist/Forms/ScheduleCallPremier.js +168 -156
  49. package/dist/Forms/VendorQuestionnaire.d.ts +1 -1
  50. package/dist/Forms/VendorQuestionnaire.js +807 -795
  51. package/dist/Forms/WcplSurvey.d.ts +1 -1
  52. package/dist/Forms/WcplSurvey.js +102 -90
  53. package/package.json +133 -133
@@ -46,6 +46,7 @@ const CommercialDeposits = ({
46
46
  description,
47
47
  callToAction,
48
48
  validateEmail,
49
+ onValidate,
49
50
  id
50
51
  }) => {
51
52
  const schema = z.object({
@@ -137,188 +138,199 @@ const CommercialDeposits = ({
137
138
  }
138
139
  )
139
140
  ] }),
140
- /* @__PURE__ */ jsxs("form", { className: form, onSubmit: handleSubmit(submitForm), children: [
141
- /* @__PURE__ */ jsxs("div", { className: clsx(formWrapper({ variant })), children: [
142
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
143
- Input,
144
- {
145
- id: "first_name",
146
- ...register("first_name", {
147
- required: "First Name is required"
148
- }),
149
- label: "First Name",
150
- sizes: "medium",
151
- required: true,
152
- error: !!errors.first_name,
153
- helperText: errors.first_name?.message,
154
- variant
155
- }
156
- ) }),
157
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
158
- Input,
159
- {
160
- id: "last_name",
161
- ...register("last_name", { required: true }),
162
- label: "Last Name",
163
- sizes: "medium",
164
- required: true,
165
- error: !!errors.last_name,
166
- helperText: errors.last_name?.message,
167
- variant
168
- }
169
- ) }),
170
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
171
- Input,
172
- {
173
- id: "company",
174
- ...register("company", { required: true }),
175
- label: "Business Name",
176
- sizes: "medium",
177
- required: true,
178
- error: !!errors.company,
179
- helperText: errors.company?.message,
180
- variant
181
- }
182
- ) }),
183
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
184
- Input,
185
- {
186
- id: "email",
187
- ...register("email", {
188
- required: true,
189
- validate: {
190
- isValid: associatedEmail
141
+ /* @__PURE__ */ jsxs(
142
+ "form",
143
+ {
144
+ className: form,
145
+ onSubmit: async (e) => {
146
+ onValidate && onValidate(e);
147
+ await handleSubmit(submitForm)(e);
148
+ e.preventDefault();
149
+ },
150
+ children: [
151
+ /* @__PURE__ */ jsxs("div", { className: clsx(formWrapper({ variant })), children: [
152
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
153
+ Input,
154
+ {
155
+ id: "first_name",
156
+ ...register("first_name", {
157
+ required: "First Name is required"
158
+ }),
159
+ label: "First Name",
160
+ sizes: "medium",
161
+ required: true,
162
+ error: !!errors.first_name,
163
+ helperText: errors.first_name?.message,
164
+ variant
191
165
  }
192
- }),
193
- label: "Email",
194
- sizes: "medium",
195
- required: true,
196
- error: !!errors.email,
197
- helperText: errors.email?.message,
198
- variant
199
- }
200
- ) }),
201
- /* @__PURE__ */ jsx("div", { className: x_input, children: /* @__PURE__ */ jsx(
202
- InputPhone,
203
- {
204
- id: "phone",
205
- ...register("phone", { required: true, maxLength: 12 }),
206
- label: "Business Phone",
207
- sizes: "medium",
208
- required: true,
209
- error: !!errors.phone,
210
- helperText: errors.phone?.message,
211
- variant
212
- }
213
- ) }),
214
- /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsxs(
215
- Dropdown,
216
- {
217
- id: "Estimated_Gross_Annual_Revenue__c",
218
- ...register("Estimated_Gross_Annual_Revenue__c", {
219
- required: true
220
- }),
221
- label: "Estimated Gross Annual Revenue",
222
- sizes: "medium",
223
- required: true,
224
- error: !!errors.Estimated_Gross_Annual_Revenue__c,
225
- helperText: errors.Estimated_Gross_Annual_Revenue__c?.message,
226
- variant,
227
- defaultValue: "",
228
- children: [
229
- /* @__PURE__ */ jsx("option", { disabled: true, value: "", children: "Select Option" }),
230
- /* @__PURE__ */ jsx("option", { value: "Under $3MM", children: "Under $3MM" }),
231
- /* @__PURE__ */ jsx("option", { value: "$3MM - $10MM", children: "$3MM - $10MM" }),
232
- /* @__PURE__ */ jsx("option", { value: "$10MM - $100MM", children: "$10MM - $100MM" }),
233
- /* @__PURE__ */ jsx("option", { value: "Above $100MM", children: "Above $100MM" })
234
- ]
235
- }
236
- ) }),
237
- /* @__PURE__ */ jsxs("div", { className: `${fullRowForm}`, children: [
238
- /* @__PURE__ */ jsx("div", { className: pl_label, children: "Which products or services apply to your request? Click all that apply." }),
239
- /* @__PURE__ */ jsx(
240
- Checkbox,
241
- {
242
- id: "Banking__c",
243
- ...register("Banking__c"),
244
- sizes: "medium",
245
- variant,
246
- children: "Banking"
247
- }
248
- ),
249
- /* @__PURE__ */ jsx(
250
- Checkbox,
251
- {
252
- id: "Treasury_Management__c",
253
- ...register("Treasury_Management__c"),
254
- sizes: "medium",
255
- variant,
256
- children: "Treasury Management"
257
- }
258
- ),
259
- /* @__PURE__ */ jsx(
260
- Checkbox,
261
- {
262
- id: "Lending__c",
263
- ...register("Lending__c"),
264
- sizes: "medium",
265
- variant,
266
- children: "Lending"
267
- }
268
- ),
269
- /* @__PURE__ */ jsx(
270
- Checkbox,
271
- {
272
- id: "Others__c",
273
- ...register("Others__c"),
274
- sizes: "medium",
275
- variant,
276
- children: "Other"
277
- }
278
- ),
279
- othersChecked && /* @__PURE__ */ jsx(
280
- Input,
166
+ ) }),
167
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
168
+ Input,
169
+ {
170
+ id: "last_name",
171
+ ...register("last_name", { required: true }),
172
+ label: "Last Name",
173
+ sizes: "medium",
174
+ required: true,
175
+ error: !!errors.last_name,
176
+ helperText: errors.last_name?.message,
177
+ variant
178
+ }
179
+ ) }),
180
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
181
+ Input,
182
+ {
183
+ id: "company",
184
+ ...register("company", { required: true }),
185
+ label: "Business Name",
186
+ sizes: "medium",
187
+ required: true,
188
+ error: !!errors.company,
189
+ helperText: errors.company?.message,
190
+ variant
191
+ }
192
+ ) }),
193
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
194
+ Input,
195
+ {
196
+ id: "email",
197
+ ...register("email", {
198
+ required: true,
199
+ validate: {
200
+ isValid: associatedEmail
201
+ }
202
+ }),
203
+ label: "Email",
204
+ sizes: "medium",
205
+ required: true,
206
+ error: !!errors.email,
207
+ helperText: errors.email?.message,
208
+ variant
209
+ }
210
+ ) }),
211
+ /* @__PURE__ */ jsx("div", { className: x_input, children: /* @__PURE__ */ jsx(
212
+ InputPhone,
213
+ {
214
+ id: "phone",
215
+ ...register("phone", { required: true, maxLength: 12 }),
216
+ label: "Business Phone",
217
+ sizes: "medium",
218
+ required: true,
219
+ error: !!errors.phone,
220
+ helperText: errors.phone?.message,
221
+ variant
222
+ }
223
+ ) }),
224
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsxs(
225
+ Dropdown,
226
+ {
227
+ id: "Estimated_Gross_Annual_Revenue__c",
228
+ ...register("Estimated_Gross_Annual_Revenue__c", {
229
+ required: true
230
+ }),
231
+ label: "Estimated Gross Annual Revenue",
232
+ sizes: "medium",
233
+ required: true,
234
+ error: !!errors.Estimated_Gross_Annual_Revenue__c,
235
+ helperText: errors.Estimated_Gross_Annual_Revenue__c?.message,
236
+ variant,
237
+ defaultValue: "",
238
+ children: [
239
+ /* @__PURE__ */ jsx("option", { disabled: true, value: "", children: "Select Option" }),
240
+ /* @__PURE__ */ jsx("option", { value: "Under $3MM", children: "Under $3MM" }),
241
+ /* @__PURE__ */ jsx("option", { value: "$3MM - $10MM", children: "$3MM - $10MM" }),
242
+ /* @__PURE__ */ jsx("option", { value: "$10MM - $100MM", children: "$10MM - $100MM" }),
243
+ /* @__PURE__ */ jsx("option", { value: "Above $100MM", children: "Above $100MM" })
244
+ ]
245
+ }
246
+ ) }),
247
+ /* @__PURE__ */ jsxs("div", { className: `${fullRowForm}`, children: [
248
+ /* @__PURE__ */ jsx("div", { className: pl_label, children: "Which products or services apply to your request? Click all that apply." }),
249
+ /* @__PURE__ */ jsx(
250
+ Checkbox,
251
+ {
252
+ id: "Banking__c",
253
+ ...register("Banking__c"),
254
+ sizes: "medium",
255
+ variant,
256
+ children: "Banking"
257
+ }
258
+ ),
259
+ /* @__PURE__ */ jsx(
260
+ Checkbox,
261
+ {
262
+ id: "Treasury_Management__c",
263
+ ...register("Treasury_Management__c"),
264
+ sizes: "medium",
265
+ variant,
266
+ children: "Treasury Management"
267
+ }
268
+ ),
269
+ /* @__PURE__ */ jsx(
270
+ Checkbox,
271
+ {
272
+ id: "Lending__c",
273
+ ...register("Lending__c"),
274
+ sizes: "medium",
275
+ variant,
276
+ children: "Lending"
277
+ }
278
+ ),
279
+ /* @__PURE__ */ jsx(
280
+ Checkbox,
281
+ {
282
+ id: "Others__c",
283
+ ...register("Others__c"),
284
+ sizes: "medium",
285
+ variant,
286
+ children: "Other"
287
+ }
288
+ ),
289
+ othersChecked && /* @__PURE__ */ jsx(
290
+ Input,
291
+ {
292
+ id: "Others_Detail__c",
293
+ ...register("Others_Detail__c", { required: false }),
294
+ sizes: "medium",
295
+ required: false,
296
+ error: !!errors.Others_Detail__c,
297
+ helperText: errors.Others_Detail__c?.message,
298
+ variant
299
+ }
300
+ )
301
+ ] }),
302
+ /* @__PURE__ */ jsx("div", { className: fullRowForm, children: /* @__PURE__ */ jsx(
303
+ Input,
304
+ {
305
+ id: "Product_and_servicing_needs__c",
306
+ ...register("Product_and_servicing_needs__c", {
307
+ required: false
308
+ }),
309
+ label: "Kindly describe your product and/or servicing needs.",
310
+ sizes: "medium",
311
+ required: false,
312
+ error: !!errors.Product_and_servicing_needs__c,
313
+ helperText: errors.Product_and_servicing_needs__c?.message,
314
+ variant
315
+ }
316
+ ) }),
317
+ /* @__PURE__ */ jsx(HoneyPot, { register, errors, variant })
318
+ ] }),
319
+ children,
320
+ /* @__PURE__ */ jsx("div", { className: disclosureForm({ variant }), children: disclosure }),
321
+ /* @__PURE__ */ jsx("div", { className: actions, children: /* @__PURE__ */ jsx(
322
+ Button,
281
323
  {
282
- id: "Others_Detail__c",
283
- ...register("Others_Detail__c", { required: false }),
284
- sizes: "medium",
285
- required: false,
286
- error: !!errors.Others_Detail__c,
287
- helperText: errors.Others_Detail__c?.message,
288
- variant
324
+ color: getVariant(callToAction?.variant),
325
+ as: "button",
326
+ type: "submit",
327
+ disabled: !isValid || isSubmitting,
328
+ children: callToAction?.displayText
289
329
  }
290
- )
291
- ] }),
292
- /* @__PURE__ */ jsx("div", { className: fullRowForm, children: /* @__PURE__ */ jsx(
293
- Input,
294
- {
295
- id: "Product_and_servicing_needs__c",
296
- ...register("Product_and_servicing_needs__c", {
297
- required: false
298
- }),
299
- label: "Kindly describe your product and/or servicing needs.",
300
- sizes: "medium",
301
- required: false,
302
- error: !!errors.Product_and_servicing_needs__c,
303
- helperText: errors.Product_and_servicing_needs__c?.message,
304
- variant
305
- }
306
- ) }),
307
- /* @__PURE__ */ jsx(HoneyPot, { register, errors, variant })
308
- ] }),
309
- children,
310
- /* @__PURE__ */ jsx("div", { className: disclosureForm({ variant }), children: disclosure }),
311
- /* @__PURE__ */ jsx("div", { className: actions, children: /* @__PURE__ */ jsx(
312
- Button,
313
- {
314
- color: getVariant(callToAction?.variant),
315
- as: "button",
316
- type: "submit",
317
- disabled: !isValid || isSubmitting,
318
- children: callToAction?.displayText
319
- }
320
- ) })
321
- ] })
330
+ ) })
331
+ ]
332
+ }
333
+ )
322
334
  ] }) })
323
335
  },
324
336
  id
@@ -16,4 +16,4 @@ export type CommercialLendingInputs = {
16
16
  Loan__c: string;
17
17
  Requested_loan_amount_and_leverage__c: string;
18
18
  };
19
- export declare const CommercialLending: ({ icon, children, onSubmit, disclosure, variant: fullVariant, headline, callToAction, validateEmail, description, id, }: FormProps) => import("react/jsx-runtime").JSX.Element;
19
+ export declare const CommercialLending: ({ icon, children, onSubmit, disclosure, variant: fullVariant, headline, callToAction, validateEmail, onValidate, description, id, }: FormProps) => import("react/jsx-runtime").JSX.Element;