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 = {
@@ -441,7 +446,6 @@ const TOLPCommentsPlaceholders = {
441
446
  'Lemon Law': 'Example: "I purchased a new vehicle that broke down already and seller will not assist"',
442
447
  '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"',
443
448
  'Medical Malpractice': 'Example: "A doctor performed surgery on the wrong limb and I would like to file a lawsuit"',
444
- 'Nursing Home Abuse': 'Example: "My mother\'s nursing home is physically abusing her"',
445
449
  'Patents and Intellectual Property': 'Example: "I would like to file for a patent" or "I need to copyright a name"',
446
450
  'Personal Injury': 'Example: "I was bit by the neighbor\'s dog" or "I fell in the icy grocery store parking lot"',
447
451
  'Power of Attorney': 'Example: "I need help with a limited or general power of attorney"',
@@ -453,8 +457,6 @@ const TOLPCommentsPlaceholders = {
453
457
  'Tax and IRS': 'Example: "I need help fighting an IRS tax claim" or "I need audit defense"',
454
458
  'Traffic and Tickets': 'Example: "I need help reinstating a supsended license" or "I would like to fight a traffic ticket"',
455
459
  'Unemployment': 'Example: "I need help filing for unemployment benefits"',
456
- 'Vaccination Injury': 'Example: "I was injured after receiving a vaccine and would like to file a lawsuit"',
457
- 'Veteran\'s Disability': 'Example: "I would like help filing for disability benefits"',
458
460
  'Victim of a Crime': 'Example: "I was assaulted in the store" or "I am being discriminated against at work"',
459
461
  'Wills and Trusts': 'Example: "I need a simple will created" or "I would like guidance on creating a trust fund"',
460
462
  'Workers Compensation': 'Example: "I was injured at work and would like to file for workers compensation benefits"',
@@ -465,59 +467,6 @@ const TOLPCommentsPlaceholders = {
465
467
 
466
468
  const TOLPFinalHeadlines = {
467
469
  // 'Adoption': '',
468
- // 'Asbestos and Mesothelioma': '',
469
- // 'Auto and Car Accidents': '',
470
- // 'Bankruptcy': '',
471
- // 'Birth Certificate and Name Change': '',
472
- // 'Business Lawyers': '',
473
- // 'Child Custody and Support': '',
474
- // 'Civil Rights and Discrimination': '',
475
- // 'Civil Lawsuit': '',
476
- // 'Consumer Lawyers': '',
477
- // 'Copyrights and Trademarks': '',
478
- // 'Criminal and Felony': '',
479
- // 'Debt and Collections': '',
480
- // 'Divorce and Separation': '',
481
- // 'DUI and DWI': '',
482
- // 'Elder Law': '',
483
- // 'Employment and Workplace': '',
484
- // 'Expungement': '',
485
- // 'Family Issues': '',
486
- // 'Foreclosure': '',
487
- // 'Guardianship': '',
488
- // 'Harassment and Discrimination': '',
489
- // 'Identity Theft': '',
490
- // 'Immigration and Visas': '',
491
- // 'Insurance': '',
492
- // 'Landlord and Tenant': '',
493
- // 'Lemon Law': '',
494
- // 'Long Term Disability': '',
495
- // 'Medical Malpractice': '',
496
- // 'Nursing Home Abuse': '',
497
- // 'Patents and Intellectual Property': '',
498
- // 'Personal Injury': '',
499
- // 'Power of Attorney': '',
500
- // 'Probate and Estates': '',
501
- // 'Product Liability': '',
502
- // 'Property Damage': '',
503
- // 'Real Estate': '',
504
- // 'Social Security Disability and Insurance': '',
505
- // 'Tax and IRS': '',
506
- // 'Traffic and Tickets': '',
507
- // 'Unemployment': '',
508
- // 'Vaccination Injury': '',
509
- // 'Veteran\'s Disability': '',
510
- // 'Victim of a Crime': '',
511
- // 'Wills and Trusts': '',
512
- // 'Workers Compensation': '',
513
- // 'Wrongful Death': '',
514
- // 'Wrongful Termination': '',
515
- // 'Not Sure or Other': ''
516
- // 'Sexual Harassment': '',
517
- // 'Workplace Harassment': '',
518
- // 'Non-Workplace Harassment': '',
519
- // 'Workplace Discrimination': '',
520
- // 'Non-Workplace Discrimination': '',
521
470
  };
522
471
 
523
472
  const TOLPFinalSubHeadlines = {
@@ -550,7 +499,6 @@ const TOLPFinalSubHeadlines = {
550
499
  // 'Lemon Law': '',
551
500
  'Long Term Disability': 'You may benefit from speaking with a disability legal professional. Please verify your contact information.',
552
501
  'Medical Malpractice': 'You may benefit from speaking with a malpractice professional. Please verify your contact information.',
553
- // 'Nursing Home Abuse': '',
554
502
  'Patents and Intellectual Property': 'You may benefit from speaking with a patent professional. Please verify your contact information.',
555
503
  'Personal Injury': 'You may benefit from speaking with a personal injury professional. Please verify your contact information.',
556
504
  // 'Power of Attorney': '',
@@ -562,8 +510,6 @@ const TOLPFinalSubHeadlines = {
562
510
  'Tax and IRS': 'You may benefit from speaking with a tax professional. Please verify your contact information.',
563
511
  // 'Traffic and Tickets': '',
564
512
  'Unemployment': 'You may benefit from speaking with an unemployment professional. Please verify your contact information.',
565
- // 'Vaccination Injury': '',
566
- 'Veteran\'s Disability': 'You may benefit from speaking with a disability legal professional. Please verify your contact information.',
567
513
  // 'Victim of a Crime': '',
568
514
  // 'Wills and Trusts': '',
569
515
  'Workers Compensation': 'You may benefit from speaking with a workers compensation professional. Please verify your contact information.',
@@ -683,7 +629,6 @@ const sbsSelect = (updates) => {
683
629
  return select(updates)
684
630
  };
685
631
 
686
-
687
632
  const text = (updates) => {
688
633
  return merge({
689
634
  $formkit: 'text',
@@ -754,59 +699,18 @@ const applicantOccupation = (scope) => sbsText({
754
699
  });
755
700
 
756
701
 
757
- const applicantAge = (scope) => sbsSelect({
702
+ const applicantAge = (scope) => sbsText({
758
703
  name: scope ? scope + ':' + 'Applicant_Age' : 'Applicant_Age',
759
704
  label: 'Age of Applicant?',
760
- options: [
761
- "18",
762
- "19",
763
- "20",
764
- "21",
765
- "22",
766
- "23",
767
- "24",
768
- "25",
769
- "26",
770
- "27",
771
- "28",
772
- "29",
773
- "30",
774
- "31",
775
- "32",
776
- "33",
777
- "34",
778
- "35",
779
- "36",
780
- "37",
781
- "38",
782
- "39",
783
- "40",
784
- "41",
785
- "42",
786
- "43",
787
- "44",
788
- "45",
789
- "46",
790
- "47",
791
- "48",
792
- "49",
793
- "50",
794
- "51",
795
- "52",
796
- "53",
797
- "54",
798
- "55",
799
- "56",
800
- "57",
801
- "58",
802
- "59",
803
- "60",
804
- "61",
805
- "62",
806
- "63",
807
- "64",
808
- "65"
809
- ]
705
+ placeholder: 'Age between 18 and 65',
706
+ maxlength: 2,
707
+ inputmode: "numeric",
708
+ validation: "required|min:18,max:65",
709
+ validationMessages: {
710
+ required: 'Applicant Age is required',
711
+ min: 'Invalid Age - must be between 18 and 65',
712
+ max: 'Invalid Age - must be between 18 and 65',
713
+ }
810
714
  });
811
715
 
812
716
  const applicantDisabilityHowObtain = (scope) => sbsSelect({
@@ -1279,7 +1183,7 @@ const disabilityWorkHistory = () => sbsYesNoRadio({
1279
1183
 
1280
1184
  const doctorTreatment = (scope) => sbsYesNoRadio({
1281
1185
  name: scope ? scope + ':' + 'Doctor_Treatment' : 'Doctor_Treatment',
1282
- label: 'Have You Recently Been Treated by a Doctor, Hospital or Clinic?'
1186
+ label: 'Have You Recently Been Treated by a Doctor, Hospital or Clinic?',
1283
1187
  });
1284
1188
 
1285
1189
  const driversLicenseType = () => sbs2ItemRadio({
@@ -1529,19 +1433,6 @@ const numEmployeesOfBusiness = () => sbsSelect({
1529
1433
  ]
1530
1434
  });
1531
1435
 
1532
- const nursingHomeStatus = () => sbsSelect({
1533
- label: "The Elderly Person is Currently:",
1534
- name: 'Nursing_Home_Status',
1535
- options: [
1536
- "Living at a nursing home",
1537
- "Living at their own home with medical supervision",
1538
- "Living at their own home without medical supervision ",
1539
- "Living at the home of a child, grandchild or friend",
1540
- "Deceased",
1541
- "Other"
1542
- ]
1543
- });
1544
-
1545
1436
  const ownRealEstate = () => sbsYesNoRadio({
1546
1437
  name: 'Own_Real_Estate',
1547
1438
  label: 'Do You Own Real Estate?'
@@ -1847,49 +1738,6 @@ const valueOfAssets = (scope) => sbsSelect({
1847
1738
  ]
1848
1739
  });
1849
1740
 
1850
- const veteransDisabilityApplied = () => sbsSelect({
1851
- label: 'Has the Applicant Applied for VA Disability Compensation?',
1852
- name: 'Veterans_Disability_Applied',
1853
- options: [
1854
- "Yes, Claim filed and awaiting decision",
1855
- "Yes, Claim denied",
1856
- "Yes, Claim on appeal",
1857
- "Yes, Claim approved",
1858
- "Yes, Benefits awarded",
1859
- "No, Claim has not been filed"
1860
- ]
1861
- });
1862
-
1863
- const veteransDisabilityConditions = () => sbsCheckbox({
1864
- label: 'What Service Connected Conditions Does the Applicant Have? (select all that apply)',
1865
- name: 'Veterans_Disability_Conditions',
1866
- options: [
1867
- "Traumatic Physical Injury (broken bones, loss of limb)",
1868
- "Mental Injury",
1869
- "Occupational Disease",
1870
- "Repeated Trauma Injury",
1871
- "Other"
1872
- ]
1873
- });
1874
-
1875
- const veteransDisabilityRelationship = () => sbsSelect({
1876
- label: 'What is Your Relationship to the Applicant?',
1877
- name: 'Veterans_Disability_Relationship',
1878
- options: [
1879
- "Self, Active Duty",
1880
- "Self, Active Reserve",
1881
- "Self, Discharged from Active Duty",
1882
- "Self, Discharged as Reservist",
1883
- "Surviving Family Member",
1884
- "Other"
1885
- ]
1886
- });
1887
-
1888
- const veteransDisabilityInjured = () => sbsYesNoRadio({
1889
- name: 'Veterans_Disability_Injured',
1890
- label: 'Was the Applicant Hurt While on Duty or is the Condition Related to Military Service?'
1891
- });
1892
-
1893
1741
  const wouldLikeLawyerTo = () => sbsRadio({
1894
1742
  label: 'I Would Like a Lawyer to:',
1895
1743
  name: 'Would_Like_Lawyer_To',
@@ -2424,18 +2272,6 @@ const MedicalMalpracticeQuestions = () => group(
2424
2272
  }
2425
2273
  );
2426
2274
 
2427
- const NursingHomeAbuseQuestions = () => group(
2428
- 'NursingHomeAbuseQuestions',
2429
- {
2430
- if: '$get(Type_Of_Legal_Problem).value == "Nursing Home Abuse"',
2431
- children: [
2432
- haveAttorney(),
2433
- incidentDate(),
2434
- nursingHomeStatus()
2435
- ]
2436
- }
2437
- );
2438
-
2439
2275
  const PatentsAndIntellectualPropertyQuestions = () => group(
2440
2276
  'PatentsAndIntellectualPropertyQuestions',
2441
2277
  {
@@ -2583,30 +2419,6 @@ const UnemploymentQuestions = () => group(
2583
2419
  }
2584
2420
  );
2585
2421
 
2586
- const VaccinationInjuryQuestions = () => group(
2587
- 'VaccinationInjuryQuestions',
2588
- {
2589
- if: '$get(Type_Of_Legal_Problem).value == "Vaccination Injury"',
2590
- children: [
2591
- haveAttorney(),
2592
- incidentDate()
2593
- ]
2594
- }
2595
- );
2596
-
2597
- const VeteransDisabilityQuestions = () => group(
2598
- 'VeteransDisabilityQuestions',
2599
- {
2600
- if: '$get(Type_Of_Legal_Problem).value == "Veteran\'s Disability"',
2601
- children: [
2602
- veteransDisabilityRelationship(),
2603
- veteransDisabilityInjured(),
2604
- veteransDisabilityConditions(),
2605
- veteransDisabilityApplied()
2606
- ]
2607
- }
2608
- );
2609
-
2610
2422
  const VictimOfACrimeQuestions = () => group(
2611
2423
  'VictimOfACrimeQuestions',
2612
2424
  {
@@ -2717,12 +2529,8 @@ const findLastInput = (n) => {
2717
2529
 
2718
2530
  const stepDefaults = (step) => ({
2719
2531
  $el: 'section',
2720
- if: '$stepIsEnabled("' + step + '")',
2721
2532
  attrs: {
2722
- style: {
2723
- if: '$activeStep !== "' + step + '"',
2724
- then: 'display: none;'
2725
- }
2533
+ hidden: '$activeStep !== "' + step + '"'
2726
2534
  }
2727
2535
  });
2728
2536
 
@@ -2916,7 +2724,6 @@ const AllTOLPQuestions = () => {
2916
2724
  LemonLawQuestions(),
2917
2725
  LongTermDisabilityQuestions(),
2918
2726
  MedicalMalpracticeQuestions(),
2919
- NursingHomeAbuseQuestions(),
2920
2727
  PatentsAndIntellectualPropertyQuestions(),
2921
2728
  PersonalInjuryQuestions(),
2922
2729
  PowerofAttorneyQuestions(),
@@ -2928,8 +2735,6 @@ const AllTOLPQuestions = () => {
2928
2735
  TaxAndIRSQuestions(),
2929
2736
  TrafficAndTicketsQuestions(),
2930
2737
  UnemploymentQuestions(),
2931
- VaccinationInjuryQuestions(),
2932
- VeteransDisabilityQuestions(),
2933
2738
  VictimOfACrimeQuestions(),
2934
2739
  WillsAndTrustsQuestions(),
2935
2740
  WorkersCompensationQuestions(),