purityselect/resources/js/views/pages/questionere/anxiety-form.js
2024-10-25 01:05:27 +05:00

581 lines
12 KiB
JavaScript

export default {
steps: {
page0: {
elements: [
'h1',
'h2',
'anxiety_level',
],
buttons: {
previous: false,
},
},
page1: {
elements: [
'h3',
'h4',
'anxiety_duration',
],
},
page2: {
elements: [
'h5',
'h6',
'anxiety_triggers',
],
},
page3: {
elements: [
'h7',
'h8',
'diagnosed_anxiety',
],
},
page4: {
elements: [
'h9',
'h10',
'anxiety_symptoms',
],
},
page5: {
elements: [
'h11',
'h12',
'anxiety_medication',
],
},
page6: {
elements: [
'h13',
'h14',
'anxiety_supplements',
],
},
page7: {
elements: [
'h15',
'h16',
'stress_level',
],
},
page8: {
elements: [
'h17',
'h18',
'seeing_therapist',
],
},
page9: {
elements: [
'h19',
'h20',
'other_conditions',
],
},
page10: {
elements: [
'h21',
'h22',
'adverse_reactions',
],
},
page11: {
elements: [
'h23',
'h24',
'history_mental_health',
],
},
page12: {
elements: [
'h25',
'h26',
'pregnant',
],
},
},
schema: {
h1: {
type: 'static',
tag: 'h2',
content: 'Anxiety Assessment',
align: 'left',
},
h2: {
type: 'static',
tag: 'h4',
content: 'How would you rate your current level of anxiety?',
},
anxiety_level: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Mild',
label: 'Mild',
},
{
value: 'Moderate',
label: 'Moderate',
},
{
value: 'Severe',
label: 'Severe',
},
],
},
h3: {
type: 'static',
tag: 'h4',
content: 'How long have you experienced symptoms of anxiety?',
},
h4: {
type: 'static',
tag: 'h5',
content: 'Select one:',
},
anxiety_duration: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Weeks',
label: 'Weeks',
},
{
value: 'Months',
label: 'Months',
},
{
value: 'Years',
label: 'Years',
},
],
},
h5: {
type: 'static',
tag: 'h4',
content: 'What are the main triggers or situations that cause your anxiety?',
},
h6: {
type: 'static',
tag: 'h5',
content: 'Check all that apply:',
},
anxiety_triggers: {
type: 'checkboxgroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Social situations',
label: 'Social situations',
},
{
value: 'Work-related stress',
label: 'Work-related stress',
},
{
value: 'Family or relationship issues',
label: 'Family or relationship issues',
},
{
value: 'Health concerns',
label: 'Health concerns',
},
{
value: 'Financial problems',
label: 'Financial problems',
},
{
value: 'Other',
label: 'Other',
},
],
},
h7: {
type: 'static',
tag: 'h4',
content: 'Have you been diagnosed with an anxiety disorder?',
},
h8: {
type: 'static',
tag: 'h5',
content: '(e.g., generalized anxiety disorder, panic disorder, social anxiety)',
},
diagnosed_anxiety: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
h9: {
type: 'static',
tag: 'h4',
content: 'If yes, please specify the condition.',
},
specified_condition: {
type: 'text',
inputType: 'text',
rules: [
'required',
],
conditions: [
[
'diagnosed_anxiety',
'in',
[
'Yes',
],
],
],
},
h10: {
type: 'static',
tag: 'h4',
content: 'Do you experience the following symptoms?',
},
h11: {
type: 'static',
tag: 'h5',
content: 'Check all that apply:',
},
anxiety_symptoms: {
type: 'checkboxgroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Restlessness or nervousness',
label: 'Restlessness or nervousness',
},
{
value: 'Trouble concentrating',
label: 'Trouble concentrating',
},
{
value: 'Rapid heart rate',
label: 'Rapid heart rate',
},
{
value: 'Sweating',
label: 'Sweating',
},
{
value: 'Difficulty breathing',
label: 'Difficulty breathing',
},
{
value: 'Irritability',
label: 'Irritability',
},
{
value: 'Insomnia or sleep disturbances',
label: 'Insomnia or sleep disturbances',
},
{
value: 'Muscle tension',
label: 'Muscle tension',
},
{
value: 'Nausea or digestive issues',
label: 'Nausea or digestive issues',
},
{
value: 'Other',
label: 'Other',
},
],
},
h12: {
type: 'static',
tag: 'h4',
content: 'Are you currently taking any medications for anxiety?',
},
anxiety_medication: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
medication_details: {
type: 'text',
inputType: 'text',
rules: [
'required',
],
conditions: [
[
'anxiety_medication',
'in',
[
'Yes',
],
],
],
},
h13: {
type: 'static',
tag: 'h4',
content: 'Have you used natural supplements or other therapies for anxiety?',
},
anxiety_supplements: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
supplement_details: {
type: 'text',
inputType: 'text',
rules: [
'required',
],
conditions: [
[
'anxiety_supplements',
'in',
[
'Yes',
],
],
],
},
h14: {
type: 'static',
tag: 'h4',
content: 'How would you rate your current stress levels?',
},
stress_level: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Low',
label: 'Low',
},
{
value: 'Moderate',
label: 'Moderate',
},
{
value: 'High',
label: 'High',
},
{
value: 'Very High',
label: 'Very High',
},
],
},
h15: {
type: 'static',
tag: 'h4',
content: 'Are you currently seeing a therapist or mental health professional for your anxiety?',
},
seeing_therapist: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
h16: {
type: 'static',
tag: 'h4',
content: 'Do you have any of the following conditions that may affect your anxiety treatment?',
},
other_conditions: {
type: 'checkboxgroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Heart disease',
label: 'Heart disease',
},
{
value: 'Hypertension',
label: 'Hypertension',
},
{
value: 'Asthma or respiratory conditions',
label: 'Asthma or respiratory conditions',
},
{
value: 'Thyroid disorders',
label: 'Thyroid disorders',
},
{
value: 'Autoimmune conditions',
label: 'Autoimmune conditions',
},
{
value: 'Chronic pain',
label: 'Chronic pain',
},
{
value: 'Other',
label: 'Other',
},
],
},
h17: {
type: 'static',
tag: 'h4',
content: 'Have you experienced any adverse reactions to medications or treatments for anxiety in the past?',
},
adverse_reactions: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
reaction_details: {
type: 'text',
inputType: 'text',
rules: [
'required',
],
conditions: [
[
'adverse_reactions',
'in',
[
'Yes',
],
],
],
},
h18: {
type: 'static',
tag: 'h4',
content: 'Do you have a history of depression, PTSD, or other mental health conditions in addition to anxiety?',
},
history_mental_health: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
mental_health_details: {
type: 'text',
inputType: 'text',
rules: [
'required',
],
conditions: [
[
'history_mental_health',
'in',
[
'Yes',
],
],
],
},
h19: {
type: 'static',
tag: 'h4',
content: 'Are you Pregnant? (Female Specific)',
},
pregnant: {
type: 'radiogroup',
rules: [
'required',
],
view: 'blocks',
items: [
{
value: 'Yes',
label: 'Yes',
},
{
value: 'No',
label: 'No',
},
],
},
},
};