bhl-forms 0.0.15 → 0.0.16
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.
- package/dist/bhl-forms.es.js +34 -34
- package/dist/bhl-forms.iife.js +10 -10
- package/dist/bhl-forms.umd.js +10 -10
- package/dist/forms/childAndFamily.es.js +75 -60
- package/dist/forms/childAndFamily.iife.js +1 -654
- package/dist/forms/childAndFamily.json +1 -1
- package/dist/forms/testForm.es.js +89 -54
- package/dist/forms/testForm.iife.js +1 -363
- package/dist/forms/testForm.json +1 -1
- package/dist/main.css +1 -1
- package/package.json +3 -2
|
@@ -1,654 +1 @@
|
|
|
1
|
-
var childAndFamily = (function () {
|
|
2
|
-
'use strict';
|
|
3
|
-
|
|
4
|
-
function merge() {
|
|
5
|
-
return Object.assign({}, ...arguments)
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
// ------ Common Base Settings
|
|
9
|
-
|
|
10
|
-
const radio = (updates) => {
|
|
11
|
-
return merge({
|
|
12
|
-
$formkit: 'radio',
|
|
13
|
-
validation: 'required',
|
|
14
|
-
validationMessages: {
|
|
15
|
-
required: 'Field is required',
|
|
16
|
-
},
|
|
17
|
-
optionsClass: 'pt-3 pl-1',
|
|
18
|
-
legendClass: 'required'
|
|
19
|
-
}, updates)
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
const sbs2ColRadio = (updates) => {
|
|
23
|
-
updates.legendClass = 'legend-left required';
|
|
24
|
-
updates.fieldsetClass = '$reset side-by-side';
|
|
25
|
-
updates.optionsClass = 'grid grid-cols-1 md:grid-cols-2';
|
|
26
|
-
updates.innerClass = 'flex items-start';
|
|
27
|
-
updates.wrapperClass = '$reset flex cursor-pointer mb-3';
|
|
28
|
-
return radio(updates)
|
|
29
|
-
};
|
|
30
|
-
|
|
31
|
-
const sbsYesNoRadio = (updates) => {
|
|
32
|
-
updates.options = ['Yes', 'No'];
|
|
33
|
-
updates.legendClass = 'legend-left required';
|
|
34
|
-
updates.fieldsetClass = '$reset side-by-side items-center';
|
|
35
|
-
updates.optionsClass = 'pl-1 side-by-side items-center';
|
|
36
|
-
updates.innerClass = 'flex items-center';
|
|
37
|
-
return radio(updates)
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
const select = (updates) => {
|
|
41
|
-
return merge({
|
|
42
|
-
$formkit: 'select',
|
|
43
|
-
placeholder: "Please Select",
|
|
44
|
-
validation: 'required',
|
|
45
|
-
validationMessages: {
|
|
46
|
-
required: 'Field is required',
|
|
47
|
-
},
|
|
48
|
-
inputClass: 'bg-white',
|
|
49
|
-
labelClass: 'required'
|
|
50
|
-
}, updates)
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
const sbsSelect = (updates) => {
|
|
54
|
-
updates.labelClass = 'required';
|
|
55
|
-
updates.wrapperClass = 'side-by-side items-center';
|
|
56
|
-
updates.innerClass = 'select-height-content';
|
|
57
|
-
return select(updates)
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
const text = (updates) => {
|
|
61
|
-
return merge({
|
|
62
|
-
$formkit: 'text',
|
|
63
|
-
validation: 'required',
|
|
64
|
-
validationMessages: {
|
|
65
|
-
required: 'Field is required',
|
|
66
|
-
},
|
|
67
|
-
labelClass: 'required'
|
|
68
|
-
}, updates)
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
const sbsText = (updates) => {
|
|
72
|
-
updates.labelClass = 'required';
|
|
73
|
-
updates.wrapperClass = 'side-by-side items-center';
|
|
74
|
-
return text(updates)
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
const childAndFamilyTOLP = () => sbs2ColRadio({
|
|
78
|
-
label: 'Type of Help Needed:',
|
|
79
|
-
name: 'Type_Of_Legal_Problem',
|
|
80
|
-
id: 'Type_Of_Legal_Problem',
|
|
81
|
-
options: [
|
|
82
|
-
'Adoption',
|
|
83
|
-
'Child Custody and Support',
|
|
84
|
-
'Family Issues',
|
|
85
|
-
'Guardianship',
|
|
86
|
-
'Divorce and Separation',
|
|
87
|
-
'Not Sure or Other'
|
|
88
|
-
]
|
|
89
|
-
});
|
|
90
|
-
|
|
91
|
-
const childHome = () => sbsSelect({
|
|
92
|
-
label: 'With Whom Do the Children Currently Live?',
|
|
93
|
-
name: 'Child_Home',
|
|
94
|
-
options: [
|
|
95
|
-
'Mother',
|
|
96
|
-
'Father',
|
|
97
|
-
'Grandparents',
|
|
98
|
-
'Other'
|
|
99
|
-
]
|
|
100
|
-
});
|
|
101
|
-
|
|
102
|
-
const childPrimaryCaregiver = () => sbsSelect({
|
|
103
|
-
label: 'Who is the Primary Caregiver?',
|
|
104
|
-
name: 'Child_Primary_Caregiver',
|
|
105
|
-
options: [
|
|
106
|
-
'Mother',
|
|
107
|
-
'Father',
|
|
108
|
-
'Other'
|
|
109
|
-
]
|
|
110
|
-
});
|
|
111
|
-
|
|
112
|
-
const childRelationship = () => sbsSelect({
|
|
113
|
-
label: 'Your Relationship to Child(ren):',
|
|
114
|
-
name: 'Child_Relationship',
|
|
115
|
-
options: [
|
|
116
|
-
'Father',
|
|
117
|
-
'Mother',
|
|
118
|
-
'Grandparent',
|
|
119
|
-
'Aunt/Uncle',
|
|
120
|
-
'Other'
|
|
121
|
-
]
|
|
122
|
-
});
|
|
123
|
-
|
|
124
|
-
const comments$1 = () => ({
|
|
125
|
-
$formkit: 'textarea',
|
|
126
|
-
label: 'Please provide a brief description of your situation:',
|
|
127
|
-
name: 'Comments',
|
|
128
|
-
placeholder: 'For Example: "I would like help with child support payments" or "I need help with visitation rights"',
|
|
129
|
-
rows: 1,
|
|
130
|
-
validation: 'required',
|
|
131
|
-
maxlength: 1000,
|
|
132
|
-
labelClass: 'required',
|
|
133
|
-
validationMessages: {
|
|
134
|
-
required: 'Description is required',
|
|
135
|
-
},
|
|
136
|
-
});
|
|
137
|
-
|
|
138
|
-
const degreeOfInterest = () => sbsSelect({
|
|
139
|
-
label: 'How Likely Are You to Pay if Your Issue Could be Resolved?',
|
|
140
|
-
name: 'Degree_Of_Interest',
|
|
141
|
-
// help: 'No payment necessary to speak with lawyers.',
|
|
142
|
-
options: [
|
|
143
|
-
'Definitely',
|
|
144
|
-
'Probably',
|
|
145
|
-
'Maybe',
|
|
146
|
-
"Absolutely Can't Afford"
|
|
147
|
-
]
|
|
148
|
-
});
|
|
149
|
-
|
|
150
|
-
const firstName = () => sbsText({
|
|
151
|
-
$formkit: 'text',
|
|
152
|
-
label: 'First Name:',
|
|
153
|
-
name: 'First_Name',
|
|
154
|
-
validation: 'required',
|
|
155
|
-
validationMessages: {
|
|
156
|
-
required: 'First Name is required'
|
|
157
|
-
},
|
|
158
|
-
});
|
|
159
|
-
|
|
160
|
-
const email = () => sbsText({
|
|
161
|
-
$formkit: 'email',
|
|
162
|
-
name: 'Email',
|
|
163
|
-
label: 'Email Address:',
|
|
164
|
-
placeholder: 'email@domain.com',
|
|
165
|
-
validation: 'required|email',
|
|
166
|
-
validationMessages: {
|
|
167
|
-
required: 'Email is required',
|
|
168
|
-
email: 'Invalid Email',
|
|
169
|
-
},
|
|
170
|
-
});
|
|
171
|
-
|
|
172
|
-
const haveAttorney = () => sbsYesNoRadio({
|
|
173
|
-
name: 'Have_Attorney',
|
|
174
|
-
label: 'Are You Currently Working with An Attorney?',
|
|
175
|
-
});
|
|
176
|
-
|
|
177
|
-
const haveChildren = () => sbsYesNoRadio({
|
|
178
|
-
name: 'Have_Children',
|
|
179
|
-
label: 'Do You Have Children?',
|
|
180
|
-
});
|
|
181
|
-
|
|
182
|
-
const lastName = () => sbsText({
|
|
183
|
-
$formkit: 'text',
|
|
184
|
-
label: 'Last Name:',
|
|
185
|
-
name: 'Last_Name',
|
|
186
|
-
validation: 'required',
|
|
187
|
-
validationMessages: {
|
|
188
|
-
required: 'Last Name is required'
|
|
189
|
-
},
|
|
190
|
-
});
|
|
191
|
-
|
|
192
|
-
const lawyerPaymentMethod = () => sbsSelect({
|
|
193
|
-
label: 'How Will You Pay for Legal Fees if You Hire a Lawyer?',
|
|
194
|
-
name: 'Lawyer_Payment_Method',
|
|
195
|
-
help: 'No payment necessary to speak with lawyers.',
|
|
196
|
-
options: [
|
|
197
|
-
'Cash',
|
|
198
|
-
'Check',
|
|
199
|
-
'Credit Card',
|
|
200
|
-
'Friend',
|
|
201
|
-
'Family',
|
|
202
|
-
'Other'
|
|
203
|
-
]
|
|
204
|
-
});
|
|
205
|
-
|
|
206
|
-
const maritalStatus = () => sbsSelect({
|
|
207
|
-
label: 'Marital Status:',
|
|
208
|
-
name: 'Marital_Status',
|
|
209
|
-
options: [
|
|
210
|
-
'Unmarried, Living Together',
|
|
211
|
-
'Unmarried, Do Not Live Together',
|
|
212
|
-
'Married, Living Together',
|
|
213
|
-
'Separated',
|
|
214
|
-
'Divorced',
|
|
215
|
-
'Other',
|
|
216
|
-
]
|
|
217
|
-
});
|
|
218
|
-
|
|
219
|
-
const phone = () => sbsText({
|
|
220
|
-
$formkit: 'tel',
|
|
221
|
-
name: 'Primary_Phone',
|
|
222
|
-
label: 'Phone Number:',
|
|
223
|
-
placeholder: 'xxx-xxx-xxxx',
|
|
224
|
-
maxlength: 12,
|
|
225
|
-
// help: '10-digit US phone number, hyphens optional.',
|
|
226
|
-
validation: 'required|matches:/^[0-9]{3}-?[0-9]{3}-?[0-9]{4}$/',
|
|
227
|
-
validationMessages: {
|
|
228
|
-
required: 'Phone Number is required',
|
|
229
|
-
matches: 'Invalid Phone Number',
|
|
230
|
-
},
|
|
231
|
-
});
|
|
232
|
-
|
|
233
|
-
const TCPAConsent = () => ({
|
|
234
|
-
$formkit: 'checkbox',
|
|
235
|
-
label: '$meta.tcpaLanguage',
|
|
236
|
-
name: 'TCPA_Opt_In',
|
|
237
|
-
validation: 'required|accepted',
|
|
238
|
-
validationMessages: {
|
|
239
|
-
required: 'Consent is required',
|
|
240
|
-
accepted: 'Consent is required',
|
|
241
|
-
},
|
|
242
|
-
classes: {
|
|
243
|
-
label: "text-xs text-slate-500 font-normal"
|
|
244
|
-
}
|
|
245
|
-
});
|
|
246
|
-
|
|
247
|
-
const zipcode = () => sbsText({
|
|
248
|
-
label: 'Zip Code:',
|
|
249
|
-
placeholder: '90210',
|
|
250
|
-
name: 'Zip',
|
|
251
|
-
maxlength: 5,
|
|
252
|
-
validation: 'required|matches:/^[0-9]{5}$/',
|
|
253
|
-
validationMessages: {
|
|
254
|
-
required: 'Zip Code is required',
|
|
255
|
-
matches: 'Invalid Zip Code',
|
|
256
|
-
},
|
|
257
|
-
});
|
|
258
|
-
|
|
259
|
-
// ------ Question Groups
|
|
260
|
-
|
|
261
|
-
// NOTE: name must be unique!
|
|
262
|
-
const group = (name, updates) => {
|
|
263
|
-
return merge({
|
|
264
|
-
$cmp: 'FormKit',
|
|
265
|
-
props: {
|
|
266
|
-
type: 'group',
|
|
267
|
-
key: name,
|
|
268
|
-
id: name,
|
|
269
|
-
name: name
|
|
270
|
-
},
|
|
271
|
-
}, updates)
|
|
272
|
-
};
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
const AdoptionQuestions = () => group(
|
|
276
|
-
'AdoptionQuestions',
|
|
277
|
-
{
|
|
278
|
-
if: '$get(Type_Of_Legal_Problem).value == "Adoption"',
|
|
279
|
-
children: [
|
|
280
|
-
haveAttorney(),
|
|
281
|
-
maritalStatus(),
|
|
282
|
-
haveChildren(),
|
|
283
|
-
degreeOfInterest(),
|
|
284
|
-
lawyerPaymentMethod()
|
|
285
|
-
]
|
|
286
|
-
}
|
|
287
|
-
);
|
|
288
|
-
|
|
289
|
-
const ChildCustodyAndSupportQuestions = () => group(
|
|
290
|
-
'ChildCustodyAndSupportQuestions',
|
|
291
|
-
{
|
|
292
|
-
if: '$get(Type_Of_Legal_Problem).value == "Child Custody and Support"',
|
|
293
|
-
children: [
|
|
294
|
-
haveAttorney(),
|
|
295
|
-
childRelationship(),
|
|
296
|
-
childHome(),
|
|
297
|
-
childPrimaryCaregiver(),
|
|
298
|
-
degreeOfInterest(),
|
|
299
|
-
lawyerPaymentMethod()
|
|
300
|
-
]
|
|
301
|
-
}
|
|
302
|
-
);
|
|
303
|
-
|
|
304
|
-
const FamilyIssuesQuestions = () => group(
|
|
305
|
-
'FamilyIssuesQuestions',
|
|
306
|
-
{
|
|
307
|
-
if: '$get(Type_Of_Legal_Problem).value == "Family Issues"',
|
|
308
|
-
children: [
|
|
309
|
-
haveAttorney(),
|
|
310
|
-
maritalStatus(),
|
|
311
|
-
haveChildren(),
|
|
312
|
-
degreeOfInterest(),
|
|
313
|
-
lawyerPaymentMethod()
|
|
314
|
-
]
|
|
315
|
-
}
|
|
316
|
-
);
|
|
317
|
-
|
|
318
|
-
const GuardianshipQuestions = () => group(
|
|
319
|
-
'GuardianshipQuestions',
|
|
320
|
-
{
|
|
321
|
-
if: '$get(Type_Of_Legal_Problem).value == "Guardianship"',
|
|
322
|
-
children: [
|
|
323
|
-
haveAttorney(),
|
|
324
|
-
maritalStatus(),
|
|
325
|
-
haveChildren(),
|
|
326
|
-
degreeOfInterest(),
|
|
327
|
-
lawyerPaymentMethod()
|
|
328
|
-
]
|
|
329
|
-
}
|
|
330
|
-
);
|
|
331
|
-
|
|
332
|
-
const DivorceQuestions = () => group(
|
|
333
|
-
'DivorceQuestions',
|
|
334
|
-
{
|
|
335
|
-
if: '$get(Type_Of_Legal_Problem).value == "Divorce and Separation"',
|
|
336
|
-
children: [
|
|
337
|
-
haveAttorney(),
|
|
338
|
-
maritalStatus(),
|
|
339
|
-
haveChildren(),
|
|
340
|
-
degreeOfInterest(),
|
|
341
|
-
lawyerPaymentMethod()
|
|
342
|
-
]
|
|
343
|
-
}
|
|
344
|
-
);
|
|
345
|
-
|
|
346
|
-
const NotSureOrOtherQuestions = () => group(
|
|
347
|
-
'NotSureOrOtherQuestions',
|
|
348
|
-
{
|
|
349
|
-
if: '$get(Type_Of_Legal_Problem).value == "Not Sure or Other"',
|
|
350
|
-
children: [
|
|
351
|
-
haveAttorney(),
|
|
352
|
-
lawyerPaymentMethod()
|
|
353
|
-
]
|
|
354
|
-
}
|
|
355
|
-
);
|
|
356
|
-
|
|
357
|
-
const stepDefaults = (step) => ({
|
|
358
|
-
$el: 'section',
|
|
359
|
-
if: '$stepIsEnabled("' + step + '")',
|
|
360
|
-
attrs: {
|
|
361
|
-
style: {
|
|
362
|
-
if: '$activeStep !== "' + step + '"',
|
|
363
|
-
then: 'display: none;'
|
|
364
|
-
}
|
|
365
|
-
}
|
|
366
|
-
});
|
|
367
|
-
|
|
368
|
-
// ...args get merged onto the group since the 'section' node basically
|
|
369
|
-
// disappears in the formkit hierarchy
|
|
370
|
-
function step(name, inputs, ...args) {
|
|
371
|
-
return merge(
|
|
372
|
-
stepDefaults(name),
|
|
373
|
-
{
|
|
374
|
-
children: [
|
|
375
|
-
merge({
|
|
376
|
-
$formkit: 'group',
|
|
377
|
-
id: name,
|
|
378
|
-
name: name,
|
|
379
|
-
children: inputs
|
|
380
|
-
}, ...args)
|
|
381
|
-
],
|
|
382
|
-
}
|
|
383
|
-
)
|
|
384
|
-
}
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
function childAndFamilyTOLPAndZip() {
|
|
388
|
-
return step(
|
|
389
|
-
'childAndFamilyTOLPAndZip',
|
|
390
|
-
[
|
|
391
|
-
childAndFamilyTOLP(),
|
|
392
|
-
zipcode(),
|
|
393
|
-
],
|
|
394
|
-
...arguments
|
|
395
|
-
)
|
|
396
|
-
}
|
|
397
|
-
|
|
398
|
-
function comments() {
|
|
399
|
-
return step(
|
|
400
|
-
'comments',
|
|
401
|
-
[
|
|
402
|
-
comments$1(),
|
|
403
|
-
],
|
|
404
|
-
...arguments
|
|
405
|
-
)
|
|
406
|
-
}
|
|
407
|
-
|
|
408
|
-
function contactInfo() {
|
|
409
|
-
return step(
|
|
410
|
-
'contactInfo',
|
|
411
|
-
[
|
|
412
|
-
{
|
|
413
|
-
$el: 'h3',
|
|
414
|
-
children: 'Based on your input, you may benefit from speaking with a family lawyer. Please verify your contact information:',
|
|
415
|
-
attrs: {
|
|
416
|
-
class: 'flex justify-center text-center text-lg font-bold pb-5 pt-0 px-3'
|
|
417
|
-
}
|
|
418
|
-
},
|
|
419
|
-
email(),
|
|
420
|
-
phone(),
|
|
421
|
-
TCPAConsent(),
|
|
422
|
-
{
|
|
423
|
-
$el: 'div',
|
|
424
|
-
if: '$activeStep === $lastStep()',
|
|
425
|
-
attrs: {
|
|
426
|
-
class: 'flex justify-center'
|
|
427
|
-
},
|
|
428
|
-
children: [
|
|
429
|
-
{
|
|
430
|
-
$el: 'img',
|
|
431
|
-
attrs: {
|
|
432
|
-
loading: 'lazy',
|
|
433
|
-
alt: '',
|
|
434
|
-
style: { border: 0 },
|
|
435
|
-
src: 'https://d27hmee62k45vz.cloudfront.net/form-secure-privacy.png',
|
|
436
|
-
width: '320',
|
|
437
|
-
height: '100'
|
|
438
|
-
}
|
|
439
|
-
}
|
|
440
|
-
]
|
|
441
|
-
}
|
|
442
|
-
],
|
|
443
|
-
...arguments
|
|
444
|
-
)
|
|
445
|
-
}
|
|
446
|
-
|
|
447
|
-
function firstAndLast() {
|
|
448
|
-
return step(
|
|
449
|
-
'firstAndLast',
|
|
450
|
-
[
|
|
451
|
-
firstName(),
|
|
452
|
-
lastName(),
|
|
453
|
-
],
|
|
454
|
-
...arguments
|
|
455
|
-
)
|
|
456
|
-
}
|
|
457
|
-
|
|
458
|
-
function TOLPQuestions() {
|
|
459
|
-
return step(
|
|
460
|
-
'TOLPQuestions',
|
|
461
|
-
[
|
|
462
|
-
{
|
|
463
|
-
$el: 'h3',
|
|
464
|
-
children: 'Please Complete the Following:',
|
|
465
|
-
attrs: {
|
|
466
|
-
class: 'flex justify-center text-center text-2xl font-bold text-blue-500 pb-5 pt-0 px-3'
|
|
467
|
-
}
|
|
468
|
-
},
|
|
469
|
-
AdoptionQuestions(),
|
|
470
|
-
ChildCustodyAndSupportQuestions(),
|
|
471
|
-
FamilyIssuesQuestions(),
|
|
472
|
-
GuardianshipQuestions(),
|
|
473
|
-
DivorceQuestions(),
|
|
474
|
-
NotSureOrOtherQuestions()
|
|
475
|
-
],
|
|
476
|
-
...arguments
|
|
477
|
-
)
|
|
478
|
-
}
|
|
479
|
-
|
|
480
|
-
// ------ Utilities
|
|
481
|
-
|
|
482
|
-
const formNavigation = () => ({
|
|
483
|
-
$el: 'div',
|
|
484
|
-
attrs: {
|
|
485
|
-
class: 'step-nav'
|
|
486
|
-
},
|
|
487
|
-
children: [
|
|
488
|
-
{
|
|
489
|
-
$formkit: 'button',
|
|
490
|
-
onClick: '$setPreviousStep()',
|
|
491
|
-
children: 'Back',
|
|
492
|
-
style: {
|
|
493
|
-
if: '$activeStep === $firstStep()',
|
|
494
|
-
then: 'visibility: hidden;'
|
|
495
|
-
}
|
|
496
|
-
},
|
|
497
|
-
{
|
|
498
|
-
$formkit: 'button',
|
|
499
|
-
onClick: '$setNextStep($fireStepEvent($get(form)))',
|
|
500
|
-
children: 'Next',
|
|
501
|
-
style: {
|
|
502
|
-
if: '$activeStep === $lastStep()',
|
|
503
|
-
then: 'display: none;'
|
|
504
|
-
}
|
|
505
|
-
},
|
|
506
|
-
{
|
|
507
|
-
$formkit: 'submit',
|
|
508
|
-
label: 'Submit',
|
|
509
|
-
if: '$activeStep === $lastStep()',
|
|
510
|
-
style: {
|
|
511
|
-
if: '$activeStep !== $lastStep()',
|
|
512
|
-
then: 'display: none;'
|
|
513
|
-
}
|
|
514
|
-
}
|
|
515
|
-
]
|
|
516
|
-
});
|
|
517
|
-
|
|
518
|
-
const formDetails = () => ({
|
|
519
|
-
$el: 'pre',
|
|
520
|
-
if: '$urlParam("fdbg", "") == 1',
|
|
521
|
-
children: [
|
|
522
|
-
{
|
|
523
|
-
$el: 'pre',
|
|
524
|
-
children: '$stringify( $get(form).value )',
|
|
525
|
-
attrs: {
|
|
526
|
-
class: 'text-xs',
|
|
527
|
-
style: 'overflow: scroll'
|
|
528
|
-
}
|
|
529
|
-
},
|
|
530
|
-
{
|
|
531
|
-
$el: 'pre',
|
|
532
|
-
children: ['activeStep: ', '$activeStep'],
|
|
533
|
-
attrs: {
|
|
534
|
-
class: 'text-xs',
|
|
535
|
-
style: 'overflow: scroll'
|
|
536
|
-
}
|
|
537
|
-
},
|
|
538
|
-
{
|
|
539
|
-
$el: 'pre',
|
|
540
|
-
children: ['stepHistory: ', '$stepHistory'],
|
|
541
|
-
attrs: {
|
|
542
|
-
class: 'text-xs',
|
|
543
|
-
style: 'overflow: scroll'
|
|
544
|
-
}
|
|
545
|
-
},
|
|
546
|
-
{
|
|
547
|
-
$el: 'pre',
|
|
548
|
-
children: ['stepQueue: ', '$stepQueue'],
|
|
549
|
-
attrs: {
|
|
550
|
-
class: 'text-xs',
|
|
551
|
-
style: 'overflow: scroll'
|
|
552
|
-
}
|
|
553
|
-
}
|
|
554
|
-
]
|
|
555
|
-
});
|
|
556
|
-
|
|
557
|
-
const schema = [
|
|
558
|
-
{
|
|
559
|
-
type: 'meta',
|
|
560
|
-
data: {
|
|
561
|
-
tcpaLanguage: "By checking this box, I a) agree to the Terms of Use, and b) consent to be contacted by lawyers, lawyer networks, and partners of this website using live, autodialed, pre-recorded, or artificial voice calls, as well as text messages. Your consent is not required as a condition of purchasing any goods or services. To submit this request without this consent, call 855-506-0847."
|
|
562
|
-
}
|
|
563
|
-
},
|
|
564
|
-
{
|
|
565
|
-
$cmp: 'FormKit',
|
|
566
|
-
props: {
|
|
567
|
-
type: 'form',
|
|
568
|
-
id: 'form',
|
|
569
|
-
formId: 'childAndFamily',
|
|
570
|
-
onSubmit: '$submit("https://httpbin.org/post", $prepData, $getRedirect)',
|
|
571
|
-
// onSubmit: '$submit("http://localhost:8080/api/v1/form_leads_ext", $prepData, $getRedirect)',
|
|
572
|
-
plugins: '$plugins',
|
|
573
|
-
actions: false,
|
|
574
|
-
prepop: {
|
|
575
|
-
fromURL: true
|
|
576
|
-
},
|
|
577
|
-
errorCodes: {
|
|
578
|
-
403: "An Error Occurred",
|
|
579
|
-
409: { abort: false },
|
|
580
|
-
429: "An Error Occurred"
|
|
581
|
-
},
|
|
582
|
-
redirectMap: {
|
|
583
|
-
'Adoption': 'https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}',
|
|
584
|
-
'Child Custody and Support': 'https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}',
|
|
585
|
-
'Divorce and Separation': 'https://justanswer.9pctbx.net/c/2880795/966410/9320?sharedid=${properties.vid}',
|
|
586
|
-
'Guardianship': 'https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}',
|
|
587
|
-
'*': 'https://justanswer.9pctbx.net/c/2880795/808601/9320?sharedid=${properties.vid}'
|
|
588
|
-
},
|
|
589
|
-
formClass: '!max-w-xl'
|
|
590
|
-
},
|
|
591
|
-
children: [
|
|
592
|
-
{
|
|
593
|
-
$el: 'h1',
|
|
594
|
-
if: '$activeStep === $firstStep()',
|
|
595
|
-
children: 'Get Child & Family Help Today',
|
|
596
|
-
attrs: {
|
|
597
|
-
class: 'flex justify-center text-center text-3xl font-bold pt-5 px-3'
|
|
598
|
-
}
|
|
599
|
-
},
|
|
600
|
-
{
|
|
601
|
-
$el: 'h3',
|
|
602
|
-
if: '$activeStep === $firstStep()',
|
|
603
|
-
children: 'Contact Us Now for Child Support, Custody and Family Issues',
|
|
604
|
-
attrs: {
|
|
605
|
-
class: 'flex justify-center text-center text-md font-medium text-blue-500 px-3'
|
|
606
|
-
}
|
|
607
|
-
},
|
|
608
|
-
{
|
|
609
|
-
$formkit: 'hidden',
|
|
610
|
-
name: "vertical",
|
|
611
|
-
value: "Legal"
|
|
612
|
-
},
|
|
613
|
-
{
|
|
614
|
-
$formkit: 'hidden',
|
|
615
|
-
name: "TCPA_Language",
|
|
616
|
-
value: "$meta.tcpaLanguage"
|
|
617
|
-
},
|
|
618
|
-
{
|
|
619
|
-
$formkit: 'hidden',
|
|
620
|
-
name: "gclid",
|
|
621
|
-
value: null,
|
|
622
|
-
},
|
|
623
|
-
{
|
|
624
|
-
$formkit: 'hidden',
|
|
625
|
-
name: "campaignid",
|
|
626
|
-
value: null,
|
|
627
|
-
},
|
|
628
|
-
{
|
|
629
|
-
$formkit: 'hidden',
|
|
630
|
-
name: "s",
|
|
631
|
-
value: null,
|
|
632
|
-
},
|
|
633
|
-
{
|
|
634
|
-
$el: 'div',
|
|
635
|
-
attrs: {
|
|
636
|
-
class: 'form-body'
|
|
637
|
-
},
|
|
638
|
-
children: [
|
|
639
|
-
childAndFamilyTOLPAndZip(),
|
|
640
|
-
TOLPQuestions(),
|
|
641
|
-
comments(),
|
|
642
|
-
firstAndLast(),
|
|
643
|
-
contactInfo(),
|
|
644
|
-
formNavigation(),
|
|
645
|
-
formDetails(),
|
|
646
|
-
]
|
|
647
|
-
},
|
|
648
|
-
]
|
|
649
|
-
}
|
|
650
|
-
];
|
|
651
|
-
|
|
652
|
-
return schema;
|
|
653
|
-
|
|
654
|
-
})();
|
|
1
|
+
var childAndFamily=function(){"use strict";function e(){return Object.assign({},...arguments)}const t=t=>e({$formkit:"radio",validation:"required",validationMessages:{required:"Field is required"},optionsClass:"t-pt-3 t-pl-1",legendClass:"required"},t),i=e=>(e.options=["Yes","No"],e.legendClass="legend-left required",e.fieldsetClass="$reset side-by-side t-items-center",e.optionsClass="t-pl-1 side-by-side t-items-center",e.innerClass="t-flex t-items-center",t(e)),r=t=>(t.labelClass="required",t.wrapperClass="side-by-side t-items-center",t.innerClass="select-height-content",(t=>e({$formkit:"select",placeholder:"Please Select",validation:"required",validationMessages:{required:"Field is required"},inputClass:"t-bg-white",labelClass:"required"},t))(t)),a=t=>(t.labelClass="required",t.wrapperClass="side-by-side t-items-center",(t=>e({$formkit:"text",validation:"required",validationMessages:{required:"Field is required"},labelClass:"required"},t))(t)),s=()=>{return(e={label:"Type of Help Needed:",name:"Type_Of_Legal_Problem",id:"Type_Of_Legal_Problem",options:["Adoption","Child Custody and Support","Family Issues","Guardianship","Divorce and Separation","Not Sure or Other"]}).legendClass="legend-left required",e.fieldsetClass="$reset side-by-side",e.optionsClass="t-grid t-grid-cols-1 md:t-grid-cols-2",e.innerClass="t-flex t-items-start",e.wrapperClass="$reset t-flex t-cursor-pointer t-mb-3",t(e);var e},l=()=>r({label:"How Likely Are You to Pay if Your Issue Could be Resolved?",name:"Degree_Of_Interest",options:["Definitely","Probably","Maybe","Absolutely Can't Afford"]}),n=()=>a({$formkit:"text",label:"First Name:",name:"First_Name",validation:"required",validationMessages:{required:"First Name is required"}}),o=()=>a({$formkit:"email",name:"Email",label:"Email Address:",placeholder:"email@domain.com",validation:"required|email",validationMessages:{required:"Email is required",email:"Invalid Email"}}),d=()=>i({name:"Have_Attorney",label:"Are You Currently Working with An Attorney?"}),p=()=>i({name:"Have_Children",label:"Do You Have Children?"}),u=()=>a({$formkit:"text",label:"Last Name:",name:"Last_Name",validation:"required",validationMessages:{required:"Last Name is required"}}),c=()=>r({label:"How Will You Pay for Legal Fees if You Hire a Lawyer?",name:"Lawyer_Payment_Method",help:"No payment necessary to speak with lawyers.",options:["Cash","Check","Credit Card","Friend","Family","Other"]}),m=()=>r({label:"Marital Status:",name:"Marital_Status",options:["Unmarried, Living Together","Unmarried, Do Not Live Together","Married, Living Together","Separated","Divorced","Other"]}),h=()=>a({$formkit:"tel",name:"Primary_Phone",label:"Phone Number:",placeholder:"xxx-xxx-xxxx",maxlength:12,validation:"required|matches:/^[0-9]{3}-?[0-9]{3}-?[0-9]{4}$/",validationMessages:{required:"Phone Number is required",matches:"Invalid Phone Number"}}),f=()=>a({label:"Zip Code:",placeholder:"90210",name:"Zip",maxlength:5,validation:"required|matches:/^[0-9]{5}$/",validationMessages:{required:"Zip Code is required",matches:"Invalid Zip Code"}}),y=(t,i)=>e({$cmp:"FormKit",props:{type:"group",key:t,id:t,name:t}},i),v=()=>y("AdoptionQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Adoption"',children:[d(),m(),p(),l(),c()]}),g=()=>y("ChildCustodyAndSupportQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Child Custody and Support"',children:[d(),r({label:"Your Relationship to Child(ren):",name:"Child_Relationship",options:["Father","Mother","Grandparent","Aunt/Uncle","Other"]}),r({label:"With Whom Do the Children Currently Live?",name:"Child_Home",options:["Mother","Father","Grandparents","Other"]}),r({label:"Who is the Primary Caregiver?",name:"Child_Primary_Caregiver",options:["Mother","Father","Other"]}),l(),c()]}),$=()=>y("FamilyIssuesQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Family Issues"',children:[d(),m(),p(),l(),c()]}),b=()=>y("GuardianshipQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Guardianship"',children:[d(),m(),p(),l(),c()]}),x=()=>y("DivorceQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Divorce and Separation"',children:[d(),m(),p(),l(),c()]}),C=()=>y("NotSureOrOtherQuestions",{if:'$get(Type_Of_Legal_Problem).value == "Not Sure or Other"',children:[d(),c()]});function q(t,i,...r){return e((e=>({$el:"section",if:'$stepIsEnabled("'+e+'")',attrs:{style:{if:'$activeStep !== "'+e+'"',then:"display: none;"}}}))(t),{children:[e({$formkit:"group",id:t,name:t,children:i},...r)]})}const _=[{type:"meta",data:{tcpaLanguage:"By checking this box, I a) agree to the Terms of Use, and b) consent to be contacted by lawyers, lawyer networks, and partners of this website using live, autodialed, pre-recorded, or artificial voice calls, as well as text messages. Your consent is not required as a condition of purchasing any goods or services. To submit this request without this consent, call 855-506-0847."}},{$cmp:"FormKit",props:(S={formId:"childAndFamily",onSubmit:'$submit("https://httpbin.org/post", $prepData, $getRedirect)',redirectMap:{Adoption:"https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}","Child Custody and Support":"https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}","Divorce and Separation":"https://justanswer.9pctbx.net/c/2880795/966410/9320?sharedid=${properties.vid}",Guardianship:"https://justanswer.9pctbx.net/c/2880795/565949/9320?sharedid=${properties.vid}","*":"https://justanswer.9pctbx.net/c/2880795/808601/9320?sharedid=${properties.vid}"}},e({type:"form",id:"form",onSubmit:'$submit("https://httpbin.org/post", $prepData, $getRedirect)',plugins:"$plugins",actions:!1,prepop:{fromURL:!0},errorCodes:{403:"An Error Occurred",409:{abort:!1},429:"An Error Occurred"},formClass:"!t-max-w-xl"},S)),children:[{$el:"h1",if:"$activeStep === $firstStep()",children:"Get Child & Family Help Today",attrs:{class:"t-flex t-justify-center t-text-center t-text-3xl t-font-bold t-pt-5 t-px-3"}},{$el:"h3",if:"$activeStep === $firstStep()",children:"Contact Us Now for Child Support, Custody and Family Issues",attrs:{class:"t-flex t-justify-center t-text-center t-text-md t-font-medium t-text-blue-500 t-px-3"}},{$formkit:"hidden",name:"vertical",value:"Legal"},{$formkit:"hidden",name:"TCPA_Language",value:"$meta.tcpaLanguage"},{$formkit:"hidden",name:"gclid",value:null},{$formkit:"hidden",name:"campaignid",value:null},{$formkit:"hidden",name:"s",value:null},{$el:"div",attrs:{class:"form-body"},children:[function(){return q("childAndFamilyTOLPAndZip",[s(),f()],...arguments)}(),function(){return q("TOLPQuestions",[{$el:"h3",children:"Please Complete the Following:",attrs:{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-3"}},v(),g(),$(),b(),x(),C()],...arguments)}(),function(){return q("comments",[{$formkit:"textarea",label:"Please provide a brief description of your situation:",name:"Comments",placeholder:'For Example: "I would like help with child support payments" or "I need help with visitation rights"',rows:1,validation:"required",maxlength:1e3,labelClass:"required",validationMessages:{required:"Description is required"}}],...arguments)}(),function(){return q("firstAndLast",[n(),u()],...arguments)}(),function(){return q("contactInfo",[{$el:"h3",children:"Based on your input, you may benefit from speaking with a family lawyer. Please verify your contact information:",attrs:{class:"t-flex t-justify-center t-text-center t-text-lg t-font-bold t-pb-5 t-pt-0 t-px-3"}},o(),h(),{$formkit:"checkbox",label:"$meta.tcpaLanguage",name:"TCPA_Opt_In",validation:"required|accepted",validationMessages:{required:"Consent is required",accepted:"Consent is required"},classes:{label:"t-text-xs t-text-slate-500 t-font-normal"}},{$el:"div",if:"$activeStep === $lastStep()",attrs:{class:"t-flex t-justify-center"},children:[{$el:"img",attrs:{loading:"lazy",alt:"",style:{border:0},src:"https://d27hmee62k45vz.cloudfront.net/form-secure-privacy.png",width:"320",height:"100"}}]}],...arguments)}(),{$el:"div",attrs:{class:"step-nav"},children:[{$formkit:"button",onClick:"$setPreviousStep()",children:"Back",style:{if:"$activeStep === $firstStep()",then:"visibility: hidden;"}},{$formkit:"button",onClick:"$setNextStep($fireStepEvent($get(form)))",children:"Next",style:{if:"$activeStep === $lastStep()",then:"display: none;"}},{$formkit:"submit",label:"Submit",if:"$activeStep === $lastStep()",style:{if:"$activeStep !== $lastStep()",then:"display: none;"}}]},{$el:"pre",if:'$urlParam("fdbg", "") == 1',children:[{$el:"pre",children:"$stringify( $get(form).value )",attrs:{class:"t-text-xs",style:"overflow: scroll"}},{$el:"pre",children:["activeStep: ","$activeStep"],attrs:{class:"t-text-xs",style:"overflow: scroll"}},{$el:"pre",children:["stepHistory: ","$stepHistory"],attrs:{class:"t-text-xs",style:"overflow: scroll"}},{$el:"pre",children:["stepQueue: ","$stepQueue"],attrs:{class:"t-text-xs",style:"overflow: scroll"}}]}]}]}];var S;return _}();
|