bhl-forms 0.11.10 → 0.11.12

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 (98) hide show
  1. package/dist/forms/accidentsAndInjuries.es.js +28 -2
  2. package/dist/forms/accidentsAndInjuries.iife.js +1 -1
  3. package/dist/forms/applianceRepairMinimal.es.js +27 -2
  4. package/dist/forms/applianceRepairMinimal.iife.js +1 -1
  5. package/dist/forms/appraisals.es.js +27 -2
  6. package/dist/forms/appraisals.iife.js +1 -1
  7. package/dist/forms/business.es.js +28 -2
  8. package/dist/forms/business.iife.js +1 -1
  9. package/dist/forms/childAndFamily.es.js +28 -2
  10. package/dist/forms/childAndFamily.iife.js +1 -1
  11. package/dist/forms/childAndFamilySingle.es.js +153 -81
  12. package/dist/forms/childAndFamilySingle.iife.js +1 -1
  13. package/dist/forms/childAndFamilySingle.json +1 -1
  14. package/dist/forms/civilLawsuit.es.js +231 -82
  15. package/dist/forms/civilLawsuit.iife.js +1 -1
  16. package/dist/forms/civilLawsuit.json +1 -1
  17. package/dist/forms/civilLawsuit1to1.es.js +2599 -0
  18. package/dist/forms/civilLawsuit1to1.iife.js +1 -0
  19. package/dist/forms/civilLawsuit1to1.json +1 -0
  20. package/dist/forms/coins.es.js +27 -2
  21. package/dist/forms/coins.iife.js +1 -1
  22. package/dist/forms/contracts.es.js +28 -2
  23. package/dist/forms/contracts.iife.js +1 -1
  24. package/dist/forms/criminal.es.js +28 -2
  25. package/dist/forms/criminal.iife.js +1 -1
  26. package/dist/forms/divorce.es.js +28 -2
  27. package/dist/forms/divorce.iife.js +1 -1
  28. package/dist/forms/employmentAndWorkplace.es.js +138 -64
  29. package/dist/forms/employmentAndWorkplace.iife.js +1 -1
  30. package/dist/forms/employmentAndWorkplace.json +1 -1
  31. package/dist/forms/foreclosure.es.js +28 -2
  32. package/dist/forms/foreclosure.iife.js +1 -1
  33. package/dist/forms/generalContractors.es.js +27 -2
  34. package/dist/forms/generalContractors.iife.js +1 -1
  35. package/dist/forms/generalHomeImprovement.es.js +27 -2
  36. package/dist/forms/generalHomeImprovement.iife.js +1 -1
  37. package/dist/forms/generalHomeImprovementThankYou.es.js +27 -2
  38. package/dist/forms/generalHomeImprovementThankYou.iife.js +1 -1
  39. package/dist/forms/generalLegal.es.js +30 -2
  40. package/dist/forms/generalLegal.iife.js +1 -1
  41. package/dist/forms/generalLegal.json +1 -1
  42. package/dist/forms/generalLegalJustAnswer.es.js +166 -91
  43. package/dist/forms/generalLegalJustAnswer.iife.js +1 -1
  44. package/dist/forms/generalLegalJustAnswer.json +1 -1
  45. package/dist/forms/generalLegalPopUnder.es.js +30 -2
  46. package/dist/forms/generalLegalPopUnder.iife.js +1 -1
  47. package/dist/forms/generalLegalPopUnder.json +1 -1
  48. package/dist/forms/generalLegalPopUnderSingle.es.js +166 -91
  49. package/dist/forms/generalLegalPopUnderSingle.iife.js +1 -1
  50. package/dist/forms/generalLegalPopUnderSingle.json +1 -1
  51. package/dist/forms/generalLegalSingle.es.js +166 -91
  52. package/dist/forms/generalLegalSingle.iife.js +1 -1
  53. package/dist/forms/generalLegalSingle.json +1 -1
  54. package/dist/forms/generalLegalSingle1to1.es.js +30 -3
  55. package/dist/forms/generalLegalSingle1to1.iife.js +1 -1
  56. package/dist/forms/generalLegalSingle1to1.json +1 -1
  57. package/dist/forms/generalLegalSingleMinimal.es.js +28 -3
  58. package/dist/forms/generalLegalSingleMinimal.iife.js +1 -1
  59. package/dist/forms/generalLegalSingleMinimal.json +1 -1
  60. package/dist/forms/generalLegalThankYou.es.js +30 -2
  61. package/dist/forms/generalLegalThankYou.iife.js +1 -1
  62. package/dist/forms/generalLegalThankYou.json +1 -1
  63. package/dist/forms/generalLegalThankYouConsultation.es.js +166 -91
  64. package/dist/forms/generalLegalThankYouConsultation.iife.js +1 -1
  65. package/dist/forms/generalLegalThankYouConsultation.json +1 -1
  66. package/dist/forms/harassmentAndDiscrimination.es.js +319 -155
  67. package/dist/forms/harassmentAndDiscrimination.iife.js +1 -1
  68. package/dist/forms/harassmentAndDiscrimination.json +1 -1
  69. package/dist/forms/landlordTenant.es.js +28 -2
  70. package/dist/forms/landlordTenant.iife.js +1 -1
  71. package/dist/forms/malpractice.es.js +28 -2
  72. package/dist/forms/malpractice.iife.js +1 -1
  73. package/dist/forms/mechanics.es.js +27 -2
  74. package/dist/forms/mechanics.iife.js +1 -1
  75. package/dist/forms/patentsAndIP.es.js +29 -3
  76. package/dist/forms/patentsAndIP.iife.js +1 -1
  77. package/dist/forms/patentsAndIP.json +1 -1
  78. package/dist/forms/realEstate.es.js +28 -2
  79. package/dist/forms/realEstate.iife.js +1 -1
  80. package/dist/forms/repossession.es.js +28 -2
  81. package/dist/forms/repossession.iife.js +1 -1
  82. package/dist/forms/ssdi.es.js +28 -2
  83. package/dist/forms/ssdi.iife.js +1 -1
  84. package/dist/forms/testForm.es.js +27 -2
  85. package/dist/forms/testForm.iife.js +1 -1
  86. package/dist/forms/testRedirects.es.js +29 -2
  87. package/dist/forms/testRedirects.iife.js +1 -1
  88. package/dist/forms/testRedirects.json +1 -1
  89. package/dist/forms/vets.es.js +27 -2
  90. package/dist/forms/vets.iife.js +1 -1
  91. package/dist/forms/willsAndTrusts.es.js +382 -161
  92. package/dist/forms/willsAndTrusts.iife.js +1 -1
  93. package/dist/forms/willsAndTrusts.json +1 -1
  94. package/dist/forms/windows.es.js +27 -2
  95. package/dist/forms/windows.iife.js +1 -1
  96. package/dist/forms/workersCompensation.es.js +28 -2
  97. package/dist/forms/workersCompensation.iife.js +1 -1
  98. package/package.json +1 -1
@@ -372,14 +372,11 @@ const verticalDate = (updates) => {
372
372
  return date(updates)
373
373
  };
374
374
 
375
- const email = (scope, vertical, updates = {}) => {
376
- const func = vertical ? verticalText : sbsText;
377
- const label = vertical ? updates.label : "Email Address:";
378
- return func({
379
- $formkit: "email",
375
+ const emailFL = (scope, updates = {}) => {
376
+ return text({
377
+ $formkit: "FloatingLabelText",
380
378
  name: scope ? scope + ":" + "Email" : "Email",
381
- label,
382
- placeholder: "email@domain.com",
379
+ placeholder: "Email Address",
383
380
  autocomplete: "email",
384
381
  "data-tf-sensitive": "false",
385
382
  validation: "required|email",
@@ -387,64 +384,77 @@ const email = (scope, vertical, updates = {}) => {
387
384
  required: "Email is required",
388
385
  email: "Invalid Email",
389
386
  },
387
+ inputClass: "t-text-center",
388
+ wrapperClass: "t-flex t-justify-center",
390
389
  ...updates,
391
390
  })
392
391
  };
393
392
 
394
- const firstName = (scope, vertical, updates = {}) => {
395
- const func = vertical ? verticalText : sbsText;
396
- const label = vertical ? updates.label : "First Name:";
397
- return func({
398
- label,
393
+ const firstNameFL = (scope, updates = {}) => {
394
+ return text({
395
+ $formkit: "FloatingLabelText",
399
396
  placeholder: "First Name",
400
397
  name: scope ? scope + ":" + "First_Name" : "First_Name",
401
398
  autocomplete: "given-name",
402
399
  validationMessages: {
403
400
  required: "First Name is required",
404
401
  },
402
+ inputClass: "t-text-center",
405
403
  ...updates,
406
404
  })
407
405
  };
408
406
 
409
- const lastName = (scope, vertical, updates = {}) => {
410
- const func = vertical ? verticalText : sbsText;
411
- const label = vertical ? updates.label : "Last Name:";
412
- return func({
413
- label,
407
+ const lastNameFL = (scope, updates = {}) => {
408
+ return text({
409
+ $formkit: "FloatingLabelText",
414
410
  placeholder: "Last Name",
415
411
  name: scope ? scope + ":" + "Last_Name" : "Last_Name",
416
412
  autocomplete: "family-name",
417
413
  validationMessages: {
418
414
  required: "Last Name is required",
419
415
  },
416
+ inputClass: "t-text-center",
420
417
  ...updates,
421
418
  })
422
419
  };
423
420
 
424
- const phone = (scope, vertical, updates = {}) => {
425
- const func = vertical ? verticalText : sbsText;
426
- const label = vertical ? updates.label : "Phone Number:";
427
- return func({
428
- $formkit: "tel",
421
+ const fullNameFLMobileCol = (scope, updates = {}) => {
422
+ return {
423
+ $el: "div",
424
+ attrs: {
425
+ class: "t-flex t-flex-col sm:t-flex-row t-flex-wrap t-gap-x-[2%] t-justify-center sm:!t-max-w-[70%]",
426
+ },
427
+ children: [
428
+ firstNameFL(scope, { outerClass: "sm:!t-max-w-[49%]", ...updates }),
429
+ lastNameFL(scope, { outerClass: "sm:!t-max-w-[49%]", ...updates }),
430
+ ],
431
+ }
432
+ };
433
+
434
+ const phoneFL = (scope, updates = {}) => {
435
+ return text({
436
+ $formkit: "FloatingLabelText",
437
+ datatype: "tel",
429
438
  name: scope ? scope + ":" + "Primary_Phone" : "Primary_Phone",
430
- label,
431
- placeholder: updates.placeholder || "###-###-####",
432
- maxlength: 12,
433
- help: updates.help || "10-digit phone number, hyphens optional",
439
+ placeholder: updates.placeholder || "Phone Number",
440
+ maxlength: 14,
441
+ help: updates.help || null,
434
442
  autocomplete: "tel-national",
435
443
  "data-tf-sensitive": "false",
436
- validation: "required|matches:/^[0-9]{3}-?[0-9]{3}-?[0-9]{4}$/|valid_phone",
444
+ validation: "required|matches:/^[0-9]{3}[0-9]{3}[0-9]{4}$/|valid_phone",
437
445
  validationMessages: {
438
446
  required: "Phone Number is required",
439
- matches: "Invalid Phone Format, use ###-###-####",
447
+ matches: "Invalid Phone Format, use (XXX) YYY-ZZZZ",
440
448
  valid_phone: "Invalid Phone Number",
441
449
  },
442
450
  helpClass: "t-mt-2.5 md:t-text-right md:t-mt-[-2px]",
451
+ inputClass: "t-text-center",
452
+ wrapperClass: "t-flex t-justify-center",
443
453
  ...updates,
444
454
  })
445
455
  };
446
456
 
447
- const zipcode = (scope, vertical, updates = {}) => {
457
+ const zipcode$1 = (scope, vertical, updates = {}) => {
448
458
  const func = vertical ? verticalText : sbsText;
449
459
  const label = vertical ? updates.label : "Zip Code:";
450
460
  const help = vertical ? updates.help ?? "We try to match you with local help" : null;
@@ -558,7 +568,7 @@ const causeOfInjury = (scope, vertical, updates = {}) => {
558
568
  )
559
569
  };
560
570
 
561
- const causeOfDeath = (scope, vertical, updates = {}) => {
571
+ const causeOfDeath$1 = (scope, vertical, updates = {}) => {
562
572
  const func = vertical ? col2RadioCenter : sbsSelect;
563
573
  const label = vertical ? updates.label : "What was the Cause of the Victim's Death?";
564
574
  return func(
@@ -647,7 +657,7 @@ const comments = (scope, vertical, updates) =>
647
657
  )
648
658
  );
649
659
 
650
- const criminalChargesFiled = (scope, vertical, updates = {}) => {
660
+ const criminalChargesFiled$1 = (scope, vertical, updates = {}) => {
651
661
  const func = vertical ? verticalRadio : sbsRadio;
652
662
  const label = vertical ? updates.label : "Were Criminal Charges Filed?";
653
663
  return func(
@@ -662,7 +672,7 @@ const criminalChargesFiled = (scope, vertical, updates = {}) => {
662
672
  )
663
673
  };
664
674
 
665
- const degreeOfInterest = (scope, vertical, updates = {}) => {
675
+ const degreeOfInterest$1 = (scope, vertical, updates = {}) => {
666
676
  const func = vertical ? col2RadioCenter : sbsSelect;
667
677
  const label = vertical ? updates.label : "How Likely Are You to Pay if Your Issue Could be Resolved?";
668
678
  const help = vertical ? updates.help : "No payment necessary to speak with lawyers.";
@@ -681,7 +691,7 @@ const degreeOfInterest = (scope, vertical, updates = {}) => {
681
691
  };
682
692
 
683
693
  const degreeOfInterestHelp = (scope, vertical, updates = {}) =>
684
- degreeOfInterest(scope, vertical, merge(updates, { help: "No payment necessary to speak with lawyers." }));
694
+ degreeOfInterest$1(scope, vertical, merge(updates, { help: "No payment necessary to speak with lawyers." }));
685
695
 
686
696
  const disabilityConditionStopWork = (scope, vertical, updates = {}) => {
687
697
  const func = vertical ? verticalYesNoRadio : sbsYesNoRadio;
@@ -727,7 +737,7 @@ const doctorTreatment = (scope, vertical, updates = {}) => {
727
737
  )
728
738
  };
729
739
 
730
- const estateLegalServicesNeeded = (scope, vertical, updates = {}) => {
740
+ const estateLegalServicesNeeded$1 = (scope, vertical, updates = {}) => {
731
741
  const func = vertical ? col2RadioCenter : sbsSelect;
732
742
  const label = vertical ? updates.label : "Legal Services Needed for Your Estate:";
733
743
  return func(
@@ -749,7 +759,7 @@ const estateLegalServicesNeeded = (scope, vertical, updates = {}) => {
749
759
  )
750
760
  };
751
761
 
752
- const haveAttorney = (scope, vertical, updates = {}) => {
762
+ const haveAttorney$1 = (scope, vertical, updates = {}) => {
753
763
  const func = vertical ? verticalYesNoRadio : sbsYesNoRadio;
754
764
  const label = vertical ? updates.label : "Already Working with An Attorney?";
755
765
  return func(
@@ -777,7 +787,7 @@ const haveChildren = (scope, vertical, updates = {}) => {
777
787
  )
778
788
  };
779
789
 
780
- const incidentDate = (scope, vertical, updates = {}) => {
790
+ const incidentDate$1 = (scope, vertical, updates = {}) => {
781
791
  const func = vertical ? verticalDate : sbsDate;
782
792
  const label = vertical ? updates.label : "Date of Incident:";
783
793
  return func(
@@ -917,7 +927,7 @@ const policeReportFiled = (scope, vertical, updates = {}) => {
917
927
  )
918
928
  };
919
929
 
920
- const relationshipToVictim = (scope, vertical, updates = {}) => {
930
+ const relationshipToVictim$1 = (scope, vertical, updates = {}) => {
921
931
  const func = vertical ? col2RadioCenter : sbsSelect;
922
932
  const label = vertical ? updates.label : "Relationship to the Victim:";
923
933
  return func(
@@ -932,7 +942,7 @@ const relationshipToVictim = (scope, vertical, updates = {}) => {
932
942
  )
933
943
  };
934
944
 
935
- const roleInMatterProbate = (scope, vertical, updates = {}) => {
945
+ const roleInMatterProbate$1 = (scope, vertical, updates = {}) => {
936
946
  const func = vertical ? col2RadioCenter : sbsSelect;
937
947
  const label = vertical ? updates.label : "What is Your Role in this Matter?";
938
948
  return func(
@@ -1002,7 +1012,7 @@ const typeOfAlcoholTest = (scope, vertical, updates = {}) => {
1002
1012
  )
1003
1013
  };
1004
1014
 
1005
- const typeOfAssets = (scope, vertical, updates = {}) => {
1015
+ const typeOfAssets$1 = (scope, vertical, updates = {}) => {
1006
1016
  const func = vertical ? verticalCol2Checkbox : col2Checkbox;
1007
1017
  const label = vertical ? updates.label : "Type of Assets:";
1008
1018
  return func(
@@ -1025,7 +1035,7 @@ const typeOfAssets = (scope, vertical, updates = {}) => {
1025
1035
  )
1026
1036
  };
1027
1037
 
1028
- const valueOfAssets = (scope, vertical, updates = {}) => {
1038
+ const valueOfAssets$1 = (scope, vertical, updates = {}) => {
1029
1039
  const func = vertical ? col2RadioCenter : sbsSelect;
1030
1040
  const label = vertical ? updates.label : "Value of Your Assets?";
1031
1041
  return func(
@@ -1040,7 +1050,7 @@ const valueOfAssets = (scope, vertical, updates = {}) => {
1040
1050
  )
1041
1051
  };
1042
1052
 
1043
- const willsAndTrustsTOLP = (scope, vertical, updates = {}) => {
1053
+ const willsAndTrustsTOLP$1 = (scope, vertical, updates = {}) => {
1044
1054
  const func = vertical ? col2RadioCenter : col2Radio;
1045
1055
  const label = vertical ? updates.label : "Type of Help Needed:";
1046
1056
  return func(
@@ -1084,8 +1094,8 @@ const AutoAndCarAccidentsQuestions = (condition, scope) =>
1084
1094
  group("AutoAndCarAccidentsQuestions", {
1085
1095
  if: condition || '$get(Type_Of_Legal_Problem).value == "Auto and Car Accidents"',
1086
1096
  children: [
1087
- haveAttorney(scope),
1088
- incidentDate(scope),
1097
+ haveAttorney$1(scope),
1098
+ incidentDate$1(scope),
1089
1099
  atFault(scope),
1090
1100
  primaryInjury(scope),
1091
1101
  doctorTreatment(scope),
@@ -1097,11 +1107,11 @@ const ChildCustodyQuestions = (condition, scope) =>
1097
1107
  group("ChildCustodyQuestions", {
1098
1108
  if: condition || '$get(Type_Of_Legal_Problem).value == "Child Custody"',
1099
1109
  children: [
1100
- haveAttorney(scope),
1110
+ haveAttorney$1(scope),
1101
1111
  childRelationship(scope),
1102
1112
  childHome(scope),
1103
1113
  childPrimaryCaregiver(scope),
1104
- degreeOfInterest(scope),
1114
+ degreeOfInterest$1(scope),
1105
1115
  lawyerPaymentMethod(scope),
1106
1116
  ],
1107
1117
  });
@@ -1110,10 +1120,10 @@ const DivorceQuestions = (condition, scope) =>
1110
1120
  group("DivorceQuestions", {
1111
1121
  if: condition || '$get(Type_Of_Legal_Problem).value == "Divorce and Separation"',
1112
1122
  children: [
1113
- haveAttorney(scope),
1123
+ haveAttorney$1(scope),
1114
1124
  maritalStatus(scope),
1115
1125
  haveChildren(scope),
1116
- degreeOfInterest(scope),
1126
+ degreeOfInterest$1(scope),
1117
1127
  lawyerPaymentMethod(scope),
1118
1128
  ],
1119
1129
  });
@@ -1122,8 +1132,8 @@ const DUIAndDWIQuestions = (condition, scope) =>
1122
1132
  group("DUIAndDWIQuestions", {
1123
1133
  if: condition || '$get(Type_Of_Legal_Problem).value == "DUI and DWI"',
1124
1134
  children: [
1125
- haveAttorney(scope),
1126
- incidentDate(scope),
1135
+ haveAttorney$1(scope),
1136
+ incidentDate$1(scope),
1127
1137
  priorAlcoholOffenses(scope),
1128
1138
  typeOfAlcoholTest(scope),
1129
1139
  bloodContentAlcoholTest(scope),
@@ -1132,24 +1142,12 @@ const DUIAndDWIQuestions = (condition, scope) =>
1132
1142
  ],
1133
1143
  });
1134
1144
 
1135
- const FamilyIssuesQuestions = (condition, scope) =>
1136
- group("FamilyIssuesQuestions", {
1137
- if: condition || '$get(Type_Of_Legal_Problem).value == "Family Issues"',
1138
- children: [
1139
- haveAttorney(scope),
1140
- maritalStatus(scope),
1141
- haveChildren(scope),
1142
- degreeOfInterest(scope),
1143
- lawyerPaymentMethod(scope),
1144
- ],
1145
- });
1146
-
1147
1145
  const PersonalInjuryQuestions = (condition, scope) =>
1148
1146
  group("PersonalInjuryQuestions", {
1149
1147
  if: condition || '$get(Type_Of_Legal_Problem).value == "Personal Injury"',
1150
1148
  children: [
1151
- haveAttorney(scope),
1152
- incidentDate(scope),
1149
+ haveAttorney$1(scope),
1150
+ incidentDate$1(scope),
1153
1151
  claimStatus(scope),
1154
1152
  atFault(scope),
1155
1153
  primaryInjury(scope),
@@ -1160,27 +1158,14 @@ const PersonalInjuryQuestions = (condition, scope) =>
1160
1158
  const PowerofAttorneyQuestions = (condition, scope) =>
1161
1159
  group("PowerofAttorneyQuestions", {
1162
1160
  if: condition || '$get(Type_Of_Legal_Problem).value == "Power of Attorney"',
1163
- children: [haveAttorney(scope), degreeOfInterestHelp(scope)],
1164
- });
1165
-
1166
- const ProbateAndEstatesQuestions = (condition, scope) =>
1167
- group("ProbateAndEstatesQuestions", {
1168
- if: condition || '$get(Type_Of_Legal_Problem).value == "Probate and Estates"',
1169
- children: [
1170
- haveAttorney(scope),
1171
- valueOfAssets(scope),
1172
- typeOfAssets(scope),
1173
- roleInMatterProbate(scope),
1174
- estateLegalServicesNeeded(scope),
1175
- degreeOfInterestHelp(scope),
1176
- ],
1161
+ children: [haveAttorney$1(scope), degreeOfInterestHelp(scope)],
1177
1162
  });
1178
1163
 
1179
1164
  const SocialSecurityDisabilityAndInsuranceQuestions = (condition, scope) =>
1180
1165
  group("SocialSecurityDisabilityAndInsuranceQuestions", {
1181
1166
  if: condition || '$get(Type_Of_Legal_Problem).value == "Social Security Disability and Insurance"',
1182
1167
  children: [
1183
- haveAttorney(scope),
1168
+ haveAttorney$1(scope),
1184
1169
  applicantAge(scope),
1185
1170
  disabilityConditionStopWork(scope),
1186
1171
  disabilityWorkHistory(scope),
@@ -1193,11 +1178,11 @@ const WillsAndTrustsQuestions = (condition, scope) =>
1193
1178
  group("WillsAndTrustsQuestions", {
1194
1179
  if: condition || '$get(Type_Of_Legal_Problem).value == "Wills and Trusts"',
1195
1180
  children: [
1196
- haveAttorney(scope),
1197
- valueOfAssets(scope),
1198
- typeOfAssets(scope),
1199
- roleInMatterProbate(scope),
1200
- estateLegalServicesNeeded(scope),
1181
+ haveAttorney$1(scope),
1182
+ valueOfAssets$1(scope),
1183
+ typeOfAssets$1(scope),
1184
+ roleInMatterProbate$1(scope),
1185
+ estateLegalServicesNeeded$1(scope),
1201
1186
  degreeOfInterestHelp(scope),
1202
1187
  ],
1203
1188
  });
@@ -1206,8 +1191,8 @@ const WorkersCompensationQuestions = (condition, scope) =>
1206
1191
  group("WorkersCompensationQuestions", {
1207
1192
  if: condition || '$get(Type_Of_Legal_Problem).value == "Workers Compensation"',
1208
1193
  children: [
1209
- haveAttorney(scope),
1210
- incidentDate(scope),
1194
+ haveAttorney$1(scope),
1195
+ incidentDate$1(scope),
1211
1196
  claimStatus(scope),
1212
1197
  primaryInjury(scope),
1213
1198
  causeOfInjury(scope),
@@ -1215,24 +1200,6 @@ const WorkersCompensationQuestions = (condition, scope) =>
1215
1200
  ],
1216
1201
  });
1217
1202
 
1218
- const WrongfulDeathQuestions = (condition, scope) =>
1219
- group("WrongfulDeathQuestions", {
1220
- if: condition || '$get(Type_Of_Legal_Problem).value == "Wrongful Death"',
1221
- children: [
1222
- haveAttorney(scope),
1223
- incidentDate(scope),
1224
- relationshipToVictim(scope),
1225
- criminalChargesFiled(scope),
1226
- causeOfDeath(scope),
1227
- ],
1228
- });
1229
-
1230
- const NotSureOrOtherQuestions = (condition, scope) =>
1231
- group("NotSureOrOtherQuestions", {
1232
- if: condition || '$get(Type_Of_Legal_Problem).value == "Not Sure or Other"',
1233
- children: [haveAttorney(scope), degreeOfInterestHelp(scope)],
1234
- });
1235
-
1236
1203
  const NEXT_ON_ENTER = "$onEnter($setNextStep($fireStepEvent($get(form)), $preStepFunc($get(form))))";
1237
1204
  const NEXT_ON_INPUT = "$onInput($setNextStep($fireStepEvent($get(form)), $preStepFunc($get(form))))";
1238
1205
 
@@ -1294,13 +1261,21 @@ function secureIcon(updates = {}) {
1294
1261
  return merge(secureIconDefault, updates)
1295
1262
  }
1296
1263
 
1297
- function questionsStepHeadline(updates) {
1264
+ function secureIconStandalone(updates = {}) {
1298
1265
  return {
1299
- $el: "h3",
1300
- children: updates.headline || "Tell Us About Your Situation",
1301
- attrs: {
1302
- class: "t-flex t-justify-center t-text-center t-text-2xl t-font-bold t-text-blue-500 t-pb-5 t-pt-0 t-px-1",
1266
+ if: "$activeStep === $lastStep()",
1267
+ style: {
1268
+ if: "$activeStep !== $lastStep()",
1269
+ then: "display: none;",
1303
1270
  },
1271
+ children: [
1272
+ secureIcon({
1273
+ attrs: {
1274
+ class: "t-flex t-justify-center t-items-center t-text-sm t-text-gray-500 t-pb-6 sm:t-pb-8",
1275
+ },
1276
+ ...updates,
1277
+ }),
1278
+ ],
1304
1279
  }
1305
1280
  }
1306
1281
 
@@ -1324,6 +1299,19 @@ function crossSellQuestionsStepSubHeadline(updates) {
1324
1299
  }
1325
1300
  }
1326
1301
 
1302
+ function verticalStepHeadline(updates) {
1303
+ return {
1304
+ $el: "h3",
1305
+ children: updates.headline || "Tell Us About Your Situation",
1306
+ attrs: {
1307
+ class:
1308
+ "t-flex t-justify-center t-text-center t-text-lg sm:t-text-xl t-font-bold t-text-dark t-pb-5 t-pt-0 t-px-1" +
1309
+ " " +
1310
+ (updates.headlineClass || ""),
1311
+ },
1312
+ }
1313
+ }
1314
+
1327
1315
  function commentsStepHeadline(updates) {
1328
1316
  return {
1329
1317
  $el: "h3",
@@ -1466,6 +1454,25 @@ function step(name, inputs, updates = {}) {
1466
1454
  })
1467
1455
  }
1468
1456
 
1457
+ // Single question step
1458
+ function sqstep(name, input, defaultHeadline, updates = {}) {
1459
+ if (typeof updates.nextOnInput === "undefined") {
1460
+ updates.nextOnInput = true;
1461
+ }
1462
+
1463
+ return step(
1464
+ name,
1465
+ [
1466
+ verticalStepHeadline({
1467
+ headline: updates.headline ?? defaultHeadline,
1468
+ headlineClass: updates.headlineClass,
1469
+ }),
1470
+ ...(Array.isArray(input) ? input : [input]),
1471
+ ],
1472
+ updates
1473
+ )
1474
+ }
1475
+
1469
1476
  function commentsWithBankruptcy(updates = {}) {
1470
1477
  return step(
1471
1478
  "commentsWithBankruptcy",
@@ -1474,6 +1481,7 @@ function commentsWithBankruptcy(updates = {}) {
1474
1481
  comments(updates.scope, false, {
1475
1482
  label: typeof updates.label === "undefined" ? DEFAULT_COMMENTS_LABEL_LEGAL : updates.label,
1476
1483
  placeholder: updates.placeholder || DEFAULT_COMMENTS_PLACEHOLDER_DYNAMIC_LEGAL,
1484
+ // TODO: this is a mess
1477
1485
  inputClass: typeof updates.inputClass === "undefined" ? "!t-h-32" : updates.inputClass,
1478
1486
  }),
1479
1487
  // TODO: needs scope support
@@ -1494,30 +1502,63 @@ function commentsWithBankruptcy(updates = {}) {
1494
1502
  )
1495
1503
  }
1496
1504
 
1497
- function contactInfo(updates = {}) {
1505
+ function contactInfoV2(updates = {}) {
1498
1506
  return step(
1499
1507
  "contactInfo",
1500
1508
  [
1501
1509
  contactStepHeadline(updates),
1502
1510
  contactStepSubHeadline(updates),
1503
1511
  trustedFormScript(),
1504
- email(updates.scope),
1505
- phone(updates.scope),
1506
- TCPAConsent(updates.scope),
1507
- secureIcon(),
1512
+ {
1513
+ $el: "div",
1514
+ attrs: {
1515
+ class: "t-flex t-flex-col t-justify-center t-items-center",
1516
+ },
1517
+ children: [
1518
+ emailFL(updates.scope, {
1519
+ outerClass: "!t-max-w-[95%] !t-w-[96%] sm:!t-w-[70%]",
1520
+ innerClass: "!t-w-[98%] !t-max-w-[98%] sm:!t-w-[100%] sm:!t-max-w-[100%]",
1521
+ }),
1522
+ phoneFL(updates.scope, {
1523
+ outerClass: "!t-max-w-[95%] !t-w-[96%] sm:!t-w-[70%]",
1524
+ innerClass: "!t-w-[98%] !t-max-w-[98%] sm:!t-w-[100%] sm:!t-max-w-[100%]",
1525
+ }),
1526
+ ],
1527
+ },
1528
+ TCPAConsent(updates.scope, {
1529
+ outerClass: "!t-flex !t-flex-col !t-justify-center !t-items-center",
1530
+ wrapperClass: "t-w-[95%] sm:t-w-[80%]",
1531
+ messagesClass: "t-w-[95%] sm:t-w-[80%]",
1532
+ }),
1508
1533
  ],
1509
1534
  { nextOnEnter: false }
1510
1535
  )
1511
1536
  }
1512
1537
 
1513
- function firstAndLastV2(updates = {}) {
1538
+ function firstAndLastV4(updates = {}) {
1514
1539
  return step(
1515
1540
  "firstAndLast",
1516
- [firstAndLastStepHeadline(updates), firstName(updates.scope), lastName(updates.scope)],
1541
+ [
1542
+ firstAndLastStepHeadline({
1543
+ headline: updates.headline ?? "Who is looking for help?",
1544
+ headlineClass: updates.headlineClass,
1545
+ }),
1546
+ {
1547
+ $el: "div",
1548
+ attrs: {
1549
+ class: "t-flex t-flex-col t-justify-center t-items-center t-pt-3",
1550
+ },
1551
+ children: [fullNameFLMobileCol(updates.scope)],
1552
+ },
1553
+ ],
1517
1554
  updates
1518
1555
  )
1519
1556
  }
1520
1557
 
1558
+ function zipcode(updates = {}) {
1559
+ return sqstep("zipcode", zipcode$1(updates.scope, true, updates.input), "Please verify your Zip Code", updates)
1560
+ }
1561
+
1521
1562
  function autoAndCarAccidentCrossSellQuestions(updates = {}) {
1522
1563
  return step(
1523
1564
  "autoAndCarAccidentCrossSellQuestions",
@@ -1692,33 +1733,114 @@ function legalCrossSells(updates = {}) {
1692
1733
  return step("legalCrossSells", [legalCrossSellsStepHeadline(updates), legalCrossSells$1()], updates)
1693
1734
  }
1694
1735
 
1695
- function willsAndTrustsTOLPAndZip(updates = {}) {
1696
- return step("willsAndTrustsTOLPAndZip", [willsAndTrustsTOLP(updates.scope), zipcode(updates.scope)], updates)
1736
+ function haveAttorney(updates = {}) {
1737
+ return sqstep(
1738
+ "haveAttorney",
1739
+ haveAttorney$1(updates.scope, true, updates.input),
1740
+ "Already working with an attorney?",
1741
+ updates
1742
+ )
1697
1743
  }
1698
1744
 
1699
- function willsAndTrustsTOLPQuestions(updates = {}) {
1700
- return step(
1701
- "TOLPQuestions",
1702
- [
1703
- questionsStepHeadline(updates),
1704
- WillsAndTrustsQuestions(),
1705
- ProbateAndEstatesQuestions(),
1706
- PowerofAttorneyQuestions(),
1707
- WrongfulDeathQuestions(),
1708
- FamilyIssuesQuestions(),
1709
- NotSureOrOtherQuestions(),
1710
- ],
1745
+ function degreeOfInterest(updates = {}) {
1746
+ return sqstep(
1747
+ "degreeOfInterest",
1748
+ degreeOfInterest$1(updates.scope, true, updates.input),
1749
+ "Could you pay if your issue could be resolved?",
1750
+ updates
1751
+ )
1752
+ }
1753
+
1754
+ function incidentDate(updates = {}) {
1755
+ return sqstep(
1756
+ "incidentDate",
1757
+ incidentDate$1(updates.scope, true, updates.input),
1758
+ "When did the incident occur?",
1759
+ updates
1760
+ )
1761
+ }
1762
+
1763
+ function valueOfAssets(updates = {}) {
1764
+ return sqstep(
1765
+ "valueOfAssets",
1766
+ valueOfAssets$1(updates.scope, true, updates.input),
1767
+ "What is the value of your assets?",
1768
+ updates
1769
+ )
1770
+ }
1771
+
1772
+ function typeOfAssets(updates = {}) {
1773
+ if (typeof updates.nextOnInput === "undefined") {
1774
+ updates.nextOnInput = false;
1775
+ }
1776
+ return sqstep(
1777
+ "typeOfAssets",
1778
+ typeOfAssets$1(updates.scope, true, updates.input),
1779
+ "What type of assets are involved?",
1780
+ updates
1781
+ )
1782
+ }
1783
+
1784
+ function roleInMatterProbate(updates = {}) {
1785
+ return sqstep(
1786
+ "roleInMatterProbate",
1787
+ roleInMatterProbate$1(updates.scope, true, updates.input),
1788
+ "What is your role in this matter?",
1789
+ updates
1790
+ )
1791
+ }
1792
+
1793
+ function estateLegalServicesNeeded(updates = {}) {
1794
+ return sqstep(
1795
+ "estateLegalServicesNeeded",
1796
+ estateLegalServicesNeeded$1(updates.scope, true, updates.input),
1797
+ "What legal services are needed?",
1798
+ updates
1799
+ )
1800
+ }
1801
+
1802
+ function causeOfDeath(updates = {}) {
1803
+ return sqstep(
1804
+ "causeOfDeath",
1805
+ causeOfDeath$1(updates.scope, true, updates.input),
1806
+ "What was the cause of death?",
1807
+ updates
1808
+ )
1809
+ }
1810
+
1811
+ function relationshipToVictim(updates = {}) {
1812
+ return sqstep(
1813
+ "relationshipToVictim",
1814
+ relationshipToVictim$1(updates.scope, true, updates.input),
1815
+ "What is your relationship to the victim?",
1816
+ updates
1817
+ )
1818
+ }
1819
+
1820
+ function criminalChargesFiled(updates = {}) {
1821
+ return sqstep(
1822
+ "criminalChargesFiled",
1823
+ criminalChargesFiled$1(updates.scope, true, updates.input),
1824
+ "Have criminal charges been filed?",
1711
1825
  updates
1712
1826
  )
1713
1827
  }
1714
1828
 
1715
- const formNavigation = (updates = {}) => ({
1829
+ function willsAndTrustsTOLP(updates = {}) {
1830
+ return step("willsAndTrustsTOLP", [willsAndTrustsTOLP$1(updates.scope, true, updates.input)], updates)
1831
+ }
1832
+
1833
+ const formNavigationNoFinalBack = (updates = {}) => ({
1716
1834
  $el: "div",
1717
1835
  attrs: {
1718
1836
  class: {
1719
1837
  if: "$activeStep === $firstStep()",
1720
1838
  then: "step-nav " + (updates.firstStepButtonClass || "!t-justify-center sm:!t-justify-between"),
1721
- else: "step-nav !t-justify-between",
1839
+ else: {
1840
+ if: "$activeStep === $lastStep()",
1841
+ then: "step-nav !t-justify-center ",
1842
+ else: "step-nav !t-justify-between",
1843
+ },
1722
1844
  },
1723
1845
  },
1724
1846
  children: [
@@ -1728,12 +1850,12 @@ const formNavigation = (updates = {}) => ({
1728
1850
  onClick: "$setPreviousStep($prevStepFunc($get(form)))",
1729
1851
  children: "Back",
1730
1852
  outerClass: {
1731
- if: "$activeStep === $firstStep()",
1853
+ if: "$fns.eq($activeStep, $firstStep()) || $fns.eq($activeStep, $lastStep())",
1732
1854
  then: "t-hidden sm:t-block",
1733
1855
  else: "",
1734
1856
  },
1735
1857
  style: {
1736
- if: "$activeStep === $firstStep()",
1858
+ if: "$fns.eq($activeStep, $firstStep()) || $fns.eq($activeStep, $lastStep())",
1737
1859
  then: "display: none;",
1738
1860
  },
1739
1861
  classes: {
@@ -1772,7 +1894,8 @@ const formNavigation = (updates = {}) => ({
1772
1894
  then: "display: none;",
1773
1895
  },
1774
1896
  classes: {
1775
- input: (updates.inputClass || "") + " !t-ml-2 sm:!t-ml-auto f-navigation-input",
1897
+ input: (updates.inputClass || "") + " f-navigation-input !t-w-60",
1898
+ outer: "!t-mt-0 !t-mb-0",
1776
1899
  },
1777
1900
  },
1778
1901
  ],
@@ -1926,6 +2049,58 @@ function formAnchor(updates) {
1926
2049
  return merge(formAnchorDefaults, updates)
1927
2050
  }
1928
2051
 
2052
+ const progressBarDefaults = {
2053
+ $el: "div",
2054
+ attrs: {
2055
+ class: "t-mt-7 t-mb-5 t-w-full t-flex t-flex-col t-justify-center t-items-center",
2056
+ style: {
2057
+ if: "$fns.eq($activeStep, $firstStep()) || $fns.eq($activeStep, $lastStep())",
2058
+ then: "display: none",
2059
+ },
2060
+ },
2061
+ children: [
2062
+ {
2063
+ $el: "div",
2064
+ attrs: {
2065
+ class: "t-flex t-justify-center",
2066
+ },
2067
+ children: [
2068
+ {
2069
+ $el: "span",
2070
+ attrs: {
2071
+ id: "progress-bar-text",
2072
+ class: "t-text-sm t-mb-1",
2073
+ },
2074
+ children: ["0% Complete"],
2075
+ },
2076
+ ],
2077
+ },
2078
+ {
2079
+ $el: "div",
2080
+ attrs: {
2081
+ class: "t-bg-gray-100 t-w-9/12 t-rounded",
2082
+ },
2083
+ children: [
2084
+ {
2085
+ $el: "div",
2086
+ attrs: {
2087
+ id: "progress-bar",
2088
+ class:
2089
+ "t-flex t-flex-col t-justify-center t-text-center t-whitespace-nowrap t-w-[10%] t-h-1.5 t-rounded t-text-white t-bg-[#007bff]",
2090
+ style: {
2091
+ transition: "width 0.5s ease",
2092
+ },
2093
+ },
2094
+ },
2095
+ ],
2096
+ },
2097
+ ],
2098
+ };
2099
+
2100
+ function progressBar(updates) {
2101
+ return merge(progressBarDefaults, updates)
2102
+ }
2103
+
1929
2104
  function headlineDefaults(updates = {}) {
1930
2105
  return {
1931
2106
  $el: "h1",
@@ -2352,7 +2527,7 @@ const nextStepsMapGeneralLegal = {
2352
2527
  "estateLegalServicesNeeded",
2353
2528
  ...nextStepsLegalDefault,
2354
2529
  ],
2355
- "Property Damage": ["realEstateArea", "wouldLikeLawyerTo", ...nextStepsLegalDefault],
2530
+ "Property Damage": ["wouldLikeLawyerTo", ...nextStepsLegalDefault],
2356
2531
  "Real Estate": ["realEstateTOLPDisplay", "realEstateArea", "wouldLikeLawyerTo", ...nextStepsLegalDefault],
2357
2532
  "Social Security Disability and Insurance": [
2358
2533
  "applicantAge",
@@ -2436,12 +2611,6 @@ filterNextStepsMap(nextStepsMapGeneralLegal, ["legalCrossSells"], {
2436
2611
  commentsWithBankruptcy: "comments",
2437
2612
  });
2438
2613
 
2439
- const nextStepsMapLegalLegacy = {
2440
- values: {
2441
- "*": ["TOLPQuestions", "commentsWithBankruptcy", "legalCrossSells", "firstAndLast", "contactInfo"],
2442
- },
2443
- };
2444
-
2445
2614
  const TOLPNextSteps = nextStepsMapGeneralLegal["values"]["Type_Of_Legal_Problem"];
2446
2615
 
2447
2616
  ({
@@ -2491,7 +2660,7 @@ const TOLPNextSteps = nextStepsMapGeneralLegal["values"]["Type_Of_Legal_Problem"
2491
2660
  },
2492
2661
  });
2493
2662
 
2494
- ({
2663
+ const nextStepsMapCivilTolp = {
2495
2664
  values: {
2496
2665
  Type_Of_Legal_Problem: {
2497
2666
  "Defend a Lawsuit": TOLPNextSteps["Defend a Lawsuit"],
@@ -2499,6 +2668,10 @@ const TOLPNextSteps = nextStepsMapGeneralLegal["values"]["Type_Of_Legal_Problem"
2499
2668
  },
2500
2669
  "*": ["lawsuitOtherParty", ...nextStepsLegalDefault],
2501
2670
  },
2671
+ };
2672
+
2673
+ filterNextStepsMap(nextStepsMapCivilTolp, ["legalCrossSells"], {
2674
+ commentsWithBankruptcy: "comments",
2502
2675
  });
2503
2676
 
2504
2677
  const nextStepsMapCivilTOLPDisplay = {
@@ -2570,6 +2743,27 @@ filterNextStepsMap(
2570
2743
  },
2571
2744
  });
2572
2745
 
2746
+ ({
2747
+ values: {
2748
+ Type_Of_Legal_Problem: {
2749
+ "Workplace Harassment": TOLPNextSteps["Workplace Harassment"],
2750
+ "Workplace Discrimination": TOLPNextSteps["Workplace Discrimination"],
2751
+ },
2752
+ "*": [...nextStepsLegalDefault],
2753
+ },
2754
+ });
2755
+
2756
+ const nextStepsMapWillsAndTrusts = {
2757
+ values: {
2758
+ Type_Of_Legal_Problem: {
2759
+ "Probate and Estates": TOLPNextSteps["Probate and Estates"],
2760
+ "Wills and Trusts": TOLPNextSteps["Wills and Trusts"],
2761
+ "Wrongful Death": TOLPNextSteps["Wrongful Death"],
2762
+ },
2763
+ "*": [...nextStepsLegalDefault],
2764
+ },
2765
+ };
2766
+
2573
2767
  ({
2574
2768
  values: {
2575
2769
  Type_Of_Legal_Problem_Display: {
@@ -2630,10 +2824,25 @@ const legalCrossSellOptionMap = CROSS_SELL_OPTION_MAP_LEGAL;
2630
2824
  const meta = defaultMetaPropsLegal();
2631
2825
 
2632
2826
  meta.data.dynamicSchema = [
2633
- willsAndTrustsTOLPQuestions(),
2634
- commentsWithBankruptcy(),
2827
+ valueOfAssets(),
2828
+ typeOfAssets(),
2829
+ roleInMatterProbate(),
2830
+ estateLegalServicesNeeded(),
2831
+ incidentDate({
2832
+ nextOnInput: false,
2833
+ }),
2834
+ relationshipToVictim(),
2835
+ criminalChargesFiled(),
2836
+ causeOfDeath(),
2837
+ degreeOfInterest(),
2838
+ haveAttorney(),
2839
+ commentsWithBankruptcy({
2840
+ label: null,
2841
+ headline: "Please briefly describe your situation:",
2842
+ headlineClass: "!t-text-dark",
2843
+ }),
2635
2844
  legalCrossSells({
2636
- headlineClass: '!t-text-dark',
2845
+ headlineClass: "!t-text-dark",
2637
2846
  nextStepMap: nextStepsMapLegalCrossSells,
2638
2847
  }),
2639
2848
  autoAndCarAccidentCrossSellQuestions(),
@@ -2645,41 +2854,53 @@ meta.data.dynamicSchema = [
2645
2854
  willsAndTrustsCrossSellQuestions(),
2646
2855
  divorceAndSeparationCrossSellQuestions(),
2647
2856
  childCustodyCrossSellQuestions(),
2648
- firstAndLastV2(),
2857
+ firstAndLastV4({
2858
+ headlineClass: "!t-text-dark",
2859
+ }),
2649
2860
  ];
2650
2861
 
2651
2862
  const schema = [
2652
2863
  meta,
2653
2864
  formAnchor(),
2654
2865
  {
2655
- $cmp: 'FormKit',
2866
+ $cmp: "FormKit",
2656
2867
  props: formProps({
2657
- formId: 'willsAndTrusts',
2868
+ formId: "willsAndTrusts",
2658
2869
  redirectMap: legalRedirectMap(),
2659
- crossSellOptionMap: legalCrossSellOptionMap
2660
-
2870
+ crossSellOptionMap: legalCrossSellOptionMap,
2661
2871
  }),
2662
2872
  children: [
2873
+ progressBar(),
2663
2874
  defaultHeadline(),
2664
2875
  defaultSubHeadline(),
2665
2876
  ...hiddenInputsLegal,
2666
2877
  {
2667
- $el: 'div',
2878
+ $el: "div",
2668
2879
  attrs: {
2669
- class: 'form-body'
2880
+ class: "form-body",
2670
2881
  },
2671
2882
  children: [
2672
- willsAndTrustsTOLPAndZip({
2673
- nextStepMap: nextStepsMapLegalLegacy
2883
+ willsAndTrustsTOLP({
2884
+ nextOnInput: false,
2885
+ nextStepMap: nextStepsMapWillsAndTrusts,
2674
2886
  }),
2675
2887
  dynamicSchemaNode(),
2676
- contactInfo(),
2677
- formNavigation(),
2678
- formDetails()
2679
- ]
2680
- }
2681
- ]
2682
- }
2888
+ zipcode(),
2889
+ contactInfoV2({
2890
+ subheadlineClass: "!t-text-base",
2891
+ }),
2892
+ formNavigationNoFinalBack({
2893
+ startText: "Start Now",
2894
+ submitLabel: "Get Help Now",
2895
+ inputClass: "!t-font-extrabold",
2896
+ firstStepButtonClass: "!t-justify-center",
2897
+ }),
2898
+ secureIconStandalone(),
2899
+ formDetails(),
2900
+ ],
2901
+ },
2902
+ ],
2903
+ },
2683
2904
  ];
2684
2905
 
2685
2906
  export { schema as default };