bhl-forms 0.3.1 → 0.3.3

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 (73) hide show
  1. package/dist/bhl-forms.es.js +871 -312
  2. package/dist/bhl-forms.iife.js +7 -7
  3. package/dist/bhl-forms.modern.es.js +2689 -2129
  4. package/dist/bhl-forms.modern.iife.js +9 -9
  5. package/dist/bhl-forms.modern.umd.js +9 -9
  6. package/dist/bhl-forms.umd.js +7 -7
  7. package/dist/forms/accidentsAndInjuries.es.js +9 -68
  8. package/dist/forms/accidentsAndInjuries.iife.js +1 -1
  9. package/dist/forms/accidentsAndInjuries.json +1 -1
  10. package/dist/forms/appraisals.es.js +8 -7
  11. package/dist/forms/appraisals.iife.js +1 -1
  12. package/dist/forms/appraisals.json +1 -1
  13. package/dist/forms/childAndFamily.es.js +8 -67
  14. package/dist/forms/childAndFamily.iife.js +1 -1
  15. package/dist/forms/childAndFamily.json +1 -1
  16. package/dist/forms/civilLawsuit.es.js +9 -68
  17. package/dist/forms/civilLawsuit.iife.js +1 -1
  18. package/dist/forms/civilLawsuit.json +1 -1
  19. package/dist/forms/coins.es.js +8 -7
  20. package/dist/forms/coins.iife.js +1 -1
  21. package/dist/forms/coins.json +1 -1
  22. package/dist/forms/contracts.es.js +8 -67
  23. package/dist/forms/contracts.iife.js +1 -1
  24. package/dist/forms/contracts.json +1 -1
  25. package/dist/forms/criminal.es.js +19 -214
  26. package/dist/forms/criminal.iife.js +1 -1
  27. package/dist/forms/criminal.json +1 -1
  28. package/dist/forms/employmentAndWorkplace.es.js +9 -68
  29. package/dist/forms/employmentAndWorkplace.iife.js +1 -1
  30. package/dist/forms/employmentAndWorkplace.json +1 -1
  31. package/dist/forms/generalLegal.es.js +30 -445
  32. package/dist/forms/generalLegal.iife.js +1 -1
  33. package/dist/forms/generalLegal.json +1 -1
  34. package/dist/forms/generalLegalPopUnder.es.js +19 -217
  35. package/dist/forms/generalLegalPopUnder.iife.js +1 -1
  36. package/dist/forms/generalLegalPopUnder.json +1 -1
  37. package/dist/forms/generalLegalPopUnderTF.es.js +19 -217
  38. package/dist/forms/generalLegalPopUnderTF.iife.js +1 -1
  39. package/dist/forms/generalLegalPopUnderTF.json +1 -1
  40. package/dist/forms/generalLegalThankYou.es.js +19 -217
  41. package/dist/forms/generalLegalThankYou.iife.js +1 -1
  42. package/dist/forms/generalLegalThankYou.json +1 -1
  43. package/dist/forms/harassmentAndDiscrimination.es.js +8 -67
  44. package/dist/forms/harassmentAndDiscrimination.iife.js +1 -1
  45. package/dist/forms/harassmentAndDiscrimination.json +1 -1
  46. package/dist/forms/malpractice.es.js +9 -68
  47. package/dist/forms/malpractice.iife.js +1 -1
  48. package/dist/forms/malpractice.json +1 -1
  49. package/dist/forms/mechanics.es.js +8 -7
  50. package/dist/forms/mechanics.iife.js +1 -1
  51. package/dist/forms/mechanics.json +1 -1
  52. package/dist/forms/realEstate.es.js +19 -214
  53. package/dist/forms/realEstate.iife.js +1 -1
  54. package/dist/forms/realEstate.json +1 -1
  55. package/dist/forms/repossession.es.js +8 -67
  56. package/dist/forms/repossession.iife.js +1 -1
  57. package/dist/forms/repossession.json +1 -1
  58. package/dist/forms/ssdi.es.js +24 -140
  59. package/dist/forms/ssdi.iife.js +1 -1
  60. package/dist/forms/ssdi.json +1 -1
  61. package/dist/forms/testForm.es.js +8 -67
  62. package/dist/forms/testForm.iife.js +1 -1
  63. package/dist/forms/testForm.json +1 -1
  64. package/dist/forms/testRedirects.es.js +8 -11
  65. package/dist/forms/testRedirects.iife.js +1 -1
  66. package/dist/forms/testRedirects.json +1 -1
  67. package/dist/forms/vets.es.js +8 -7
  68. package/dist/forms/vets.iife.js +1 -1
  69. package/dist/forms/vets.json +1 -1
  70. package/dist/forms/willsAndTrusts.es.js +8 -67
  71. package/dist/forms/willsAndTrusts.iife.js +1 -1
  72. package/dist/forms/willsAndTrusts.json +1 -1
  73. package/package.json +3 -2
@@ -23,6 +23,7 @@ const formPropDefaults = {
23
23
  plugins: '$plugins',
24
24
  actions: false,
25
25
  anchorElement: 'form-anchor',
26
+ useLocalStorage: true,
26
27
  prepop: {
27
28
  fromURL: true
28
29
  },
@@ -36,10 +37,14 @@ const formPropDefaults = {
36
37
  };
37
38
 
38
39
  function formProps(updates) {
39
- return merge(
40
+ const props = merge(
40
41
  formPropDefaults,
41
42
  updates
42
- )
43
+ );
44
+ if (props.formId && !props.name) {
45
+ props.name = props.formId;
46
+ }
47
+ return props
43
48
  }
44
49
 
45
50
  const metaDefaults = {
@@ -434,7 +439,6 @@ const TOLPCommentsPlaceholders = {
434
439
  'Lemon Law': 'Example: "I purchased a new vehicle that broke down already and seller will not assist"',
435
440
  'Long Term Disability': 'Example: "I was injured on the job and would like to file for benefits" or "I need help filing for disability benefits"',
436
441
  'Medical Malpractice': 'Example: "A doctor performed surgery on the wrong limb and I would like to file a lawsuit"',
437
- 'Nursing Home Abuse': 'Example: "My mother\'s nursing home is physically abusing her"',
438
442
  'Patents and Intellectual Property': 'Example: "I would like to file for a patent" or "I need to copyright a name"',
439
443
  'Personal Injury': 'Example: "I was bit by the neighbor\'s dog" or "I fell in the icy grocery store parking lot"',
440
444
  'Power of Attorney': 'Example: "I need help with a limited or general power of attorney"',
@@ -446,8 +450,6 @@ const TOLPCommentsPlaceholders = {
446
450
  'Tax and IRS': 'Example: "I need help fighting an IRS tax claim" or "I need audit defense"',
447
451
  'Traffic and Tickets': 'Example: "I need help reinstating a supsended license" or "I would like to fight a traffic ticket"',
448
452
  'Unemployment': 'Example: "I need help filing for unemployment benefits"',
449
- 'Vaccination Injury': 'Example: "I was injured after receiving a vaccine and would like to file a lawsuit"',
450
- 'Veteran\'s Disability': 'Example: "I would like help filing for disability benefits"',
451
453
  'Victim of a Crime': 'Example: "I was assaulted in the store" or "I am being discriminated against at work"',
452
454
  'Wills and Trusts': 'Example: "I need a simple will created" or "I would like guidance on creating a trust fund"',
453
455
  'Workers Compensation': 'Example: "I was injured at work and would like to file for workers compensation benefits"',
@@ -458,59 +460,6 @@ const TOLPCommentsPlaceholders = {
458
460
 
459
461
  const TOLPFinalHeadlines = {
460
462
  // 'Adoption': '',
461
- // 'Asbestos and Mesothelioma': '',
462
- // 'Auto and Car Accidents': '',
463
- // 'Bankruptcy': '',
464
- // 'Birth Certificate and Name Change': '',
465
- // 'Business Lawyers': '',
466
- // 'Child Custody and Support': '',
467
- // 'Civil Rights and Discrimination': '',
468
- // 'Civil Lawsuit': '',
469
- // 'Consumer Lawyers': '',
470
- // 'Copyrights and Trademarks': '',
471
- // 'Criminal and Felony': '',
472
- // 'Debt and Collections': '',
473
- // 'Divorce and Separation': '',
474
- // 'DUI and DWI': '',
475
- // 'Elder Law': '',
476
- // 'Employment and Workplace': '',
477
- // 'Expungement': '',
478
- // 'Family Issues': '',
479
- // 'Foreclosure': '',
480
- // 'Guardianship': '',
481
- // 'Harassment and Discrimination': '',
482
- // 'Identity Theft': '',
483
- // 'Immigration and Visas': '',
484
- // 'Insurance': '',
485
- // 'Landlord and Tenant': '',
486
- // 'Lemon Law': '',
487
- // 'Long Term Disability': '',
488
- // 'Medical Malpractice': '',
489
- // 'Nursing Home Abuse': '',
490
- // 'Patents and Intellectual Property': '',
491
- // 'Personal Injury': '',
492
- // 'Power of Attorney': '',
493
- // 'Probate and Estates': '',
494
- // 'Product Liability': '',
495
- // 'Property Damage': '',
496
- // 'Real Estate': '',
497
- // 'Social Security Disability and Insurance': '',
498
- // 'Tax and IRS': '',
499
- // 'Traffic and Tickets': '',
500
- // 'Unemployment': '',
501
- // 'Vaccination Injury': '',
502
- // 'Veteran\'s Disability': '',
503
- // 'Victim of a Crime': '',
504
- // 'Wills and Trusts': '',
505
- // 'Workers Compensation': '',
506
- // 'Wrongful Death': '',
507
- // 'Wrongful Termination': '',
508
- // 'Not Sure or Other': ''
509
- // 'Sexual Harassment': '',
510
- // 'Workplace Harassment': '',
511
- // 'Non-Workplace Harassment': '',
512
- // 'Workplace Discrimination': '',
513
- // 'Non-Workplace Discrimination': '',
514
463
  };
515
464
 
516
465
  const TOLPFinalSubHeadlines = {
@@ -543,7 +492,6 @@ const TOLPFinalSubHeadlines = {
543
492
  // 'Lemon Law': '',
544
493
  'Long Term Disability': 'You may benefit from speaking with a disability legal professional. Please verify your contact information.',
545
494
  'Medical Malpractice': 'You may benefit from speaking with a malpractice professional. Please verify your contact information.',
546
- // 'Nursing Home Abuse': '',
547
495
  'Patents and Intellectual Property': 'You may benefit from speaking with a patent professional. Please verify your contact information.',
548
496
  'Personal Injury': 'You may benefit from speaking with a personal injury professional. Please verify your contact information.',
549
497
  // 'Power of Attorney': '',
@@ -555,8 +503,6 @@ const TOLPFinalSubHeadlines = {
555
503
  'Tax and IRS': 'You may benefit from speaking with a tax professional. Please verify your contact information.',
556
504
  // 'Traffic and Tickets': '',
557
505
  'Unemployment': 'You may benefit from speaking with an unemployment professional. Please verify your contact information.',
558
- // 'Vaccination Injury': '',
559
- 'Veteran\'s Disability': 'You may benefit from speaking with a disability legal professional. Please verify your contact information.',
560
506
  // 'Victim of a Crime': '',
561
507
  // 'Wills and Trusts': '',
562
508
  'Workers Compensation': 'You may benefit from speaking with a workers compensation professional. Please verify your contact information.',
@@ -676,7 +622,6 @@ const sbsSelect = (updates) => {
676
622
  return select(updates)
677
623
  };
678
624
 
679
-
680
625
  const text = (updates) => {
681
626
  return merge({
682
627
  $formkit: 'text',
@@ -747,59 +692,18 @@ const applicantOccupation = (scope) => sbsText({
747
692
  });
748
693
 
749
694
 
750
- const applicantAge = (scope) => sbsSelect({
695
+ const applicantAge = (scope) => sbsText({
751
696
  name: scope ? scope + ':' + 'Applicant_Age' : 'Applicant_Age',
752
697
  label: 'Age of Applicant?',
753
- options: [
754
- "18",
755
- "19",
756
- "20",
757
- "21",
758
- "22",
759
- "23",
760
- "24",
761
- "25",
762
- "26",
763
- "27",
764
- "28",
765
- "29",
766
- "30",
767
- "31",
768
- "32",
769
- "33",
770
- "34",
771
- "35",
772
- "36",
773
- "37",
774
- "38",
775
- "39",
776
- "40",
777
- "41",
778
- "42",
779
- "43",
780
- "44",
781
- "45",
782
- "46",
783
- "47",
784
- "48",
785
- "49",
786
- "50",
787
- "51",
788
- "52",
789
- "53",
790
- "54",
791
- "55",
792
- "56",
793
- "57",
794
- "58",
795
- "59",
796
- "60",
797
- "61",
798
- "62",
799
- "63",
800
- "64",
801
- "65"
802
- ]
698
+ placeholder: 'Age between 18 and 65',
699
+ maxlength: 2,
700
+ inputmode: "numeric",
701
+ validation: "required|min:18,max:65",
702
+ validationMessages: {
703
+ required: 'Applicant Age is required',
704
+ min: 'Invalid Age - must be between 18 and 65',
705
+ max: 'Invalid Age - must be between 18 and 65',
706
+ }
803
707
  });
804
708
 
805
709
  const applicantDisabilityHowObtain = (scope) => sbsSelect({
@@ -1303,7 +1207,7 @@ const disabilityWorkHistory = () => sbsYesNoRadio({
1303
1207
 
1304
1208
  const doctorTreatment = (scope) => sbsYesNoRadio({
1305
1209
  name: scope ? scope + ':' + 'Doctor_Treatment' : 'Doctor_Treatment',
1306
- label: 'Have You Recently Been Treated by a Doctor, Hospital or Clinic?'
1210
+ label: 'Have You Recently Been Treated by a Doctor, Hospital or Clinic?',
1307
1211
  });
1308
1212
 
1309
1213
  const driversLicenseType = () => sbs2ItemRadio({
@@ -1419,7 +1323,6 @@ const generalTOLP = (updates) => sbsSelect(merge({
1419
1323
  'Medical Malpractice',
1420
1324
  'Non-Workplace Discrimination',
1421
1325
  'Non-Workplace Harassment',
1422
- 'Nursing Home Abuse',
1423
1326
  'Patents and Intellectual Property',
1424
1327
  'Personal Injury',
1425
1328
  'Power of Attorney',
@@ -1432,8 +1335,6 @@ const generalTOLP = (updates) => sbsSelect(merge({
1432
1335
  'Tax and IRS',
1433
1336
  'Traffic and Tickets',
1434
1337
  'Unemployment',
1435
- 'Vaccination Injury',
1436
- "Veteran's Disability",
1437
1338
  'Victim of a Crime',
1438
1339
  'Wills and Trusts',
1439
1340
  'Workers Compensation',
@@ -1649,19 +1550,6 @@ const numEmployeesOfBusiness = () => sbsSelect({
1649
1550
  ]
1650
1551
  });
1651
1552
 
1652
- const nursingHomeStatus = () => sbsSelect({
1653
- label: "The Elderly Person is Currently:",
1654
- name: 'Nursing_Home_Status',
1655
- options: [
1656
- "Living at a nursing home",
1657
- "Living at their own home with medical supervision",
1658
- "Living at their own home without medical supervision ",
1659
- "Living at the home of a child, grandchild or friend",
1660
- "Deceased",
1661
- "Other"
1662
- ]
1663
- });
1664
-
1665
1553
  const ownRealEstate = () => sbsYesNoRadio({
1666
1554
  name: 'Own_Real_Estate',
1667
1555
  label: 'Do You Own Real Estate?'
@@ -1967,49 +1855,6 @@ const valueOfAssets = (scope) => sbsSelect({
1967
1855
  ]
1968
1856
  });
1969
1857
 
1970
- const veteransDisabilityApplied = () => sbsSelect({
1971
- label: 'Has the Applicant Applied for VA Disability Compensation?',
1972
- name: 'Veterans_Disability_Applied',
1973
- options: [
1974
- "Yes, Claim filed and awaiting decision",
1975
- "Yes, Claim denied",
1976
- "Yes, Claim on appeal",
1977
- "Yes, Claim approved",
1978
- "Yes, Benefits awarded",
1979
- "No, Claim has not been filed"
1980
- ]
1981
- });
1982
-
1983
- const veteransDisabilityConditions = () => sbsCheckbox({
1984
- label: 'What Service Connected Conditions Does the Applicant Have? (select all that apply)',
1985
- name: 'Veterans_Disability_Conditions',
1986
- options: [
1987
- "Traumatic Physical Injury (broken bones, loss of limb)",
1988
- "Mental Injury",
1989
- "Occupational Disease",
1990
- "Repeated Trauma Injury",
1991
- "Other"
1992
- ]
1993
- });
1994
-
1995
- const veteransDisabilityRelationship = () => sbsSelect({
1996
- label: 'What is Your Relationship to the Applicant?',
1997
- name: 'Veterans_Disability_Relationship',
1998
- options: [
1999
- "Self, Active Duty",
2000
- "Self, Active Reserve",
2001
- "Self, Discharged from Active Duty",
2002
- "Self, Discharged as Reservist",
2003
- "Surviving Family Member",
2004
- "Other"
2005
- ]
2006
- });
2007
-
2008
- const veteransDisabilityInjured = () => sbsYesNoRadio({
2009
- name: 'Veterans_Disability_Injured',
2010
- label: 'Was the Applicant Hurt While on Duty or is the Condition Related to Military Service?'
2011
- });
2012
-
2013
1858
  const wouldLikeLawyerTo = () => sbsRadio({
2014
1859
  label: 'I Would Like a Lawyer to:',
2015
1860
  name: 'Would_Like_Lawyer_To',
@@ -2558,18 +2403,6 @@ const MedicalMalpracticeQuestions = () => group(
2558
2403
  }
2559
2404
  );
2560
2405
 
2561
- const NursingHomeAbuseQuestions = () => group(
2562
- 'NursingHomeAbuseQuestions',
2563
- {
2564
- if: '$get(Type_Of_Legal_Problem).value == "Nursing Home Abuse"',
2565
- children: [
2566
- haveAttorney(),
2567
- incidentDate(),
2568
- nursingHomeStatus()
2569
- ]
2570
- }
2571
- );
2572
-
2573
2406
  const PatentsAndIntellectualPropertyQuestions = () => group(
2574
2407
  'PatentsAndIntellectualPropertyQuestions',
2575
2408
  {
@@ -2717,30 +2550,6 @@ const UnemploymentQuestions = () => group(
2717
2550
  }
2718
2551
  );
2719
2552
 
2720
- const VaccinationInjuryQuestions = () => group(
2721
- 'VaccinationInjuryQuestions',
2722
- {
2723
- if: '$get(Type_Of_Legal_Problem).value == "Vaccination Injury"',
2724
- children: [
2725
- haveAttorney(),
2726
- incidentDate()
2727
- ]
2728
- }
2729
- );
2730
-
2731
- const VeteransDisabilityQuestions = () => group(
2732
- 'VeteransDisabilityQuestions',
2733
- {
2734
- if: '$get(Type_Of_Legal_Problem).value == "Veteran\'s Disability"',
2735
- children: [
2736
- veteransDisabilityRelationship(),
2737
- veteransDisabilityInjured(),
2738
- veteransDisabilityConditions(),
2739
- veteransDisabilityApplied()
2740
- ]
2741
- }
2742
- );
2743
-
2744
2553
  const VictimOfACrimeQuestions = () => group(
2745
2554
  'VictimOfACrimeQuestions',
2746
2555
  {
@@ -2851,12 +2660,8 @@ const findLastInput = (n) => {
2851
2660
 
2852
2661
  const stepDefaults = (step) => ({
2853
2662
  $el: 'section',
2854
- if: '$stepIsEnabled("' + step + '")',
2855
2663
  attrs: {
2856
- style: {
2857
- if: '$activeStep !== "' + step + '"',
2858
- then: 'display: none;'
2859
- }
2664
+ hidden: '$activeStep !== "' + step + '"'
2860
2665
  }
2861
2666
  });
2862
2667
 
@@ -3066,7 +2871,6 @@ const AllTOLPQuestions = () => {
3066
2871
  LemonLawQuestions(),
3067
2872
  LongTermDisabilityQuestions(),
3068
2873
  MedicalMalpracticeQuestions(),
3069
- NursingHomeAbuseQuestions(),
3070
2874
  PatentsAndIntellectualPropertyQuestions(),
3071
2875
  PersonalInjuryQuestions(),
3072
2876
  PowerofAttorneyQuestions(),
@@ -3078,8 +2882,6 @@ const AllTOLPQuestions = () => {
3078
2882
  TaxAndIRSQuestions(),
3079
2883
  TrafficAndTicketsQuestions(),
3080
2884
  UnemploymentQuestions(),
3081
- VaccinationInjuryQuestions(),
3082
- VeteransDisabilityQuestions(),
3083
2885
  VictimOfACrimeQuestions(),
3084
2886
  WillsAndTrustsQuestions(),
3085
2887
  WorkersCompensationQuestions(),